CW-148 cake pay partial redemptions (#490)

* Ionia custom redemption screen

* update ionia gift card remaining amount with custom value

* [NO-TASK] Fix issues with custom redeem

* replace redeem

* update remaining amount

* fixed from code review

* Add localization
This commit is contained in:
Godwin Asuquo
2022-09-02 14:47:45 +01:00
committed by GitHub
parent 0aee6e1b8d
commit bd25d047b2
26 changed files with 446 additions and 32 deletions
+3 -1
View File
@@ -4,11 +4,13 @@ import 'package:cake_wallet/generated/i18n.dart';
class DiscountBadge extends StatelessWidget {
const DiscountBadge({
Key key,
this.isAmount = false,
@required this.percentage,
this.discountBackground,
}) : super(key: key);
final double percentage;
final bool isAmount;
final AssetImage discountBackground;
@override
@@ -16,7 +18,7 @@ class DiscountBadge extends StatelessWidget {
return Container(
padding: EdgeInsets.symmetric(horizontal: 8, vertical: 4),
child: Text(
S.of(context).discount(percentage.toStringAsFixed(2)),
isAmount ? '\$${percentage.toStringAsFixed(2)}' : S.of(context).discount(percentage.toStringAsFixed(2)),
style: TextStyle(
color: Colors.white,
fontSize: 12,