info: styled tags as buttons

This commit is contained in:
Thibault Deckers 2019-12-28 01:24:57 +09:00
parent d42ad00688
commit b3a21da574

View file

@ -24,11 +24,10 @@ class XmpTagSection extends AnimatedWidget {
children: [
const SectionRow('XMP Tags'),
Wrap(
children: tags
.map((tag) => Padding(
padding: const EdgeInsets.symmetric(horizontal: 4.0),
child: ActionChip(
label: Text(tag),
spacing: 8,
children: tags.map((tag) {
final borderColor = Theme.of(context).accentColor;
return OutlineButton(
onPressed: () => Navigator.push(
context,
MaterialPageRoute(
@ -39,10 +38,15 @@ class XmpTagSection extends AnimatedWidget {
),
),
),
backgroundColor: Theme.of(context).accentColor,
borderSide: BorderSide(
color: borderColor,
),
))
.toList(),
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(42),
),
child: Text(tag),
);
}).toList(),
),
],
);