- Flutter Widget Livebook

Card

A material design card. A card has slightly rounded corners and a shadow.

Example

Card(
  child: Column(
    mainAxisSize: MainAxisSize.min,
    children: <Widget>[
      const ListTile(
        leading: Icon(Icons.album),
        title: Text('The Enchanted Nightingale'),
        subtitle: Text('Music by Julie Gable. Lyrics by Sidney Stein.'),
      ),
      ButtonTheme.bar( // make buttons use the appropriate styles for cards
        child: ButtonBar(
          children: <Widget>[
            FlatButton(
              child: const Text('BUY TICKETS'),
              onPressed: () { /* ... */ },
            ),
            FlatButton(
              child: const Text('LISTEN'),
              onPressed: () { /* ... */ },
            ),
          ],
        ),
      ),
    ],
  ),
)

Related Links

  1. Example
  2. Related Links