mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2025-01-09 04:19:36 +00:00
Changed tips for ionia.
This commit is contained in:
parent
100bb0f256
commit
f849e96f91
2 changed files with 18 additions and 16 deletions
|
@ -539,21 +539,22 @@ class TipButtonGroup extends StatelessWidget {
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return Row(
|
return Container(
|
||||||
children: [
|
height: 50,
|
||||||
...[
|
child: ListView.builder(
|
||||||
for (var i = 0; i < tipsList.length; i++) ...[
|
scrollDirection: Axis.horizontal,
|
||||||
TipButton(
|
itemCount: tipsList.length,
|
||||||
isSelected: _isSelected(tipsList[i].percentage),
|
itemBuilder: (BuildContext context, int index) {
|
||||||
onTap: () => onSelect(tipsList[i]),
|
final tip = tipsList[index];
|
||||||
caption: '${tipsList[i].percentage}%',
|
return Padding(
|
||||||
subTitle: '\$${tipsList[i].additionalAmount}',
|
padding: EdgeInsets.only(right: 5),
|
||||||
),
|
child: TipButton(
|
||||||
SizedBox(width: 4),
|
isSelected: _isSelected(tip.percentage),
|
||||||
]
|
onTap: () => onSelect(tip),
|
||||||
],
|
caption: '${tip.percentage}%',
|
||||||
],
|
subTitle: '\$${tip.additionalAmount}',
|
||||||
);
|
));
|
||||||
|
}));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -22,7 +22,8 @@ abstract class IoniaMerchPurchaseViewModelBase with Store {
|
||||||
percentage = 0.0;
|
percentage = 0.0;
|
||||||
tips = <IoniaTip>[
|
tips = <IoniaTip>[
|
||||||
IoniaTip(percentage: 0, originalAmount: amount),
|
IoniaTip(percentage: 0, originalAmount: amount),
|
||||||
IoniaTip(percentage: 10, originalAmount: amount),
|
IoniaTip(percentage: 15, originalAmount: amount),
|
||||||
|
IoniaTip(percentage: 18, originalAmount: amount),
|
||||||
IoniaTip(percentage: 20, originalAmount: amount),
|
IoniaTip(percentage: 20, originalAmount: amount),
|
||||||
];
|
];
|
||||||
selectedTip = tips.first;
|
selectedTip = tips.first;
|
||||||
|
|
Loading…
Reference in a new issue