This commit is contained in:
ryleedavis 2023-09-19 14:16:11 -06:00
parent 0ef9759434
commit abd6e6fcca

View file

@ -9,7 +9,7 @@ import 'package:stackwallet/widgets/desktop/desktop_dialog_close_button.dart';
import 'package:stackwallet/widgets/desktop/secondary_button.dart'; import 'package:stackwallet/widgets/desktop/secondary_button.dart';
import 'package:stackwallet/widgets/rounded_container.dart'; import 'package:stackwallet/widgets/rounded_container.dart';
enum CashFustionStatus { waiting, restoring, success, failed } enum CashFusionStatus { waiting, restoring, success, failed }
class FusionDialog extends StatelessWidget { class FusionDialog extends StatelessWidget {
const FusionDialog({ const FusionDialog({
@ -18,25 +18,25 @@ class FusionDialog extends StatelessWidget {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
Widget _getIconForState(CashFustionStatus state) { Widget _getIconForState(CashFusionStatus state) {
switch (state) { switch (state) {
case CashFustionStatus.waiting: case CashFusionStatus.waiting:
return SvgPicture.asset( return SvgPicture.asset(
Assets.svg.loader, Assets.svg.loader,
color: color:
Theme.of(context).extension<StackColors>()!.buttonBackSecondary, Theme.of(context).extension<StackColors>()!.buttonBackSecondary,
); );
case CashFustionStatus.restoring: case CashFusionStatus.restoring:
return SvgPicture.asset( return SvgPicture.asset(
Assets.svg.loader, Assets.svg.loader,
color: Theme.of(context).extension<StackColors>()!.accentColorGreen, color: Theme.of(context).extension<StackColors>()!.accentColorGreen,
); );
case CashFustionStatus.success: case CashFusionStatus.success:
return SvgPicture.asset( return SvgPicture.asset(
Assets.svg.checkCircle, Assets.svg.checkCircle,
color: Theme.of(context).extension<StackColors>()!.accentColorGreen, color: Theme.of(context).extension<StackColors>()!.accentColorGreen,
); );
case CashFustionStatus.failed: case CashFusionStatus.failed:
return SvgPicture.asset( return SvgPicture.asset(
Assets.svg.circleAlert, Assets.svg.circleAlert,
color: Theme.of(context).extension<StackColors>()!.textError, color: Theme.of(context).extension<StackColors>()!.textError,