Skip to content

Commit

Permalink
remove unwanted code
Browse files Browse the repository at this point in the history
  • Loading branch information
cp-sidhdhi-p committed Nov 19, 2024
1 parent 9ec10a3 commit b8bef29
Showing 1 changed file with 4 additions and 21 deletions.
25 changes: 4 additions & 21 deletions khelo/lib/ui/flow/profile/profile_screen.dart
Original file line number Diff line number Diff line change
Expand Up @@ -189,21 +189,15 @@ class _ProfileScreenState extends ConsumerState<ProfileScreen>
context,
icon: Assets.images.icPrivacyPolicy,
title: context.l10n.profile_setting_privacy_policy_title,
onTap: () {
final colors = _getWebPageColors(context, ref);
notifier.openUrl(
"https://canopas.github.io/khelo/privacy-policy?bgColor=${colors.background}&textColor=${colors.text}");
},
onTap: () => notifier
.openUrl("https://canopas.github.io/khelo/privacy-policy"),
),
_settingItem(
context,
icon: Assets.images.icTermsConditions,
title: context.l10n.profile_setting_terms_and_condition_title,
onTap: () {
final colors = _getWebPageColors(context, ref);
notifier.openUrl(
"https://canopas.github.io/khelo/terms-and-condition?bgColor=${colors.background}&textColor=${colors.text}");
},
onTap: () => notifier
.openUrl("https://canopas.github.io/khelo/terms-and-condition"),
),
_settingItem(
context,
Expand All @@ -224,17 +218,6 @@ class _ProfileScreenState extends ConsumerState<ProfileScreen>
);
}

({String background, String text}) _getWebPageColors(
BuildContext context,
WidgetRef ref,
) {
final isDark = context.brightness == Brightness.dark;
return (
background: isDark ? "%23000000" : "%23FFFFFF",
text: isDark ? "%23FFFFFF" : "%23000000"
);
}

Widget _settingItem(
BuildContext context, {
required String icon,
Expand Down

0 comments on commit b8bef29

Please sign in to comment.