Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add light theme #2722 #2730

Merged
merged 3 commits into from
Jun 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions lib/app/shared/enum/status/mnemonic_status.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import 'dart:ui';

import 'package:flutter/material.dart';

enum MnemonicStatus {
unselected,
Expand All @@ -17,14 +18,14 @@ extension MnemonicStatusX on MnemonicStatus {
}
}

Color get color {
Color color(BuildContext context) {
switch (this) {
case MnemonicStatus.unselected:
return const Color(0xff86809D);
return Theme.of(context).colorScheme.secondaryContainer;
case MnemonicStatus.wrongSelection:
return const Color(0xffFF0045);
return Theme.of(context).colorScheme.error;
case MnemonicStatus.selected:
return const Color(0xff6600FF);
return Theme.of(context).colorScheme.primary;
}
}
}
2 changes: 1 addition & 1 deletion lib/app/shared/widget/back_leading_button.dart
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ class BackLeadingButton extends StatelessWidget {

@override
Widget build(BuildContext context) {
final colorValue = color ?? Theme.of(context).colorScheme.onPrimary;
final colorValue = color ?? Theme.of(context).colorScheme.onSurface;
return IconButton(
padding: padding,
onPressed: onPressed ?? () => Navigator.of(context).pop(),
Expand Down
2 changes: 1 addition & 1 deletion lib/app/shared/widget/base/background_card.dart
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class BackgroundCard extends StatelessWidget {
height: height,
width: width,
decoration: BoxDecoration(
color: color ?? Theme.of(context).colorScheme.surfaceBright,
color: color ?? Theme.of(context).colorScheme.secondaryContainer,
borderRadius: const BorderRadius.all(Radius.circular(15)),
),
child: child,
Expand Down
4 changes: 3 additions & 1 deletion lib/app/shared/widget/custom_app_bar.dart
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,9 @@ class CustomAppBar extends PreferredSize {
title ?? '',
maxLines: 2,
textAlign: TextAlign.center,
style: Theme.of(context).textTheme.headlineMedium,
style: Theme.of(context).textTheme.headlineMedium!.copyWith(
fontWeight: FontWeight.bold,
),
),
),
],
Expand Down
46 changes: 27 additions & 19 deletions lib/app/shared/widget/wallet_logo.dart
Original file line number Diff line number Diff line change
Expand Up @@ -43,25 +43,33 @@ class WalletLogo extends StatelessWidget {
return Column(
children: [
Center(
child: SizedBox(
width: width,
height: height,
child: profileModel.profileType == ProfileType.enterprise
? CachedImageFromNetwork(
image,
fit: BoxFit.contain,
width: width,
bgColor: Colors.transparent,
height: height,
errorMessage: '',
showLoading: false,
)
: Image.asset(
image,
fit: BoxFit.contain,
width: width,
height: height,
),
child: ColorFiltered(
colorFilter: ColorFilter.mode(
profileModel.profileType == ProfileType.enterprise
? Colors.transparent
: Theme.of(context).colorScheme.primary,
BlendMode.srcIn,
),
child: SizedBox(
width: width,
height: height,
child: profileModel.profileType == ProfileType.enterprise
? CachedImageFromNetwork(
image,
fit: BoxFit.contain,
width: width,
bgColor: Colors.transparent,
height: height,
errorMessage: '',
showLoading: false,
)
: Image.asset(
image,
fit: BoxFit.contain,
width: width,
height: height,
),
),
),
),
// if (showPoweredBy &&
Expand Down
Loading
Loading