Update support links (#1595)

* Update support links list, add proper support for light/dark icons, update provider icons

* Update trocador icon

* Update variable

* trial fix for android build

---------

Co-authored-by: OmarHatem <omarh.ismail1@gmail.com>
This commit is contained in:
tuxsudo 2024-08-13 07:15:47 -04:00 committed by GitHub
parent 1ce60d62b3
commit 0491ad9ee2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
12 changed files with 47 additions and 24 deletions

View file

@ -2,7 +2,7 @@ buildscript {
ext.kotlin_version = '1.8.21'
repositories {
google()
jcenter()
mavenCentral()
}
dependencies {
@ -15,7 +15,7 @@ buildscript {
allprojects {
repositories {
google()
jcenter()
mavenCentral()
}
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.4 KiB

After

Width:  |  Height:  |  Size: 9.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.4 KiB

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 23 KiB

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 20 KiB

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 28 KiB

View file

@ -5,7 +5,7 @@ buildscript {
ext.kotlin_version = '1.7.10'
repositories {
google()
jcenter()
mavenCentral()
}
dependencies {
@ -17,7 +17,7 @@ buildscript {
rootProject.allprojects {
repositories {
google()
jcenter()
mavenCentral()
}
}

View file

@ -5,7 +5,7 @@ buildscript {
ext.kotlin_version = '1.7.10'
repositories {
google()
jcenter()
mavenCentral()
}
dependencies {
@ -17,7 +17,7 @@ buildscript {
rootProject.allprojects {
repositories {
google()
jcenter()
mavenCentral()
}
}

View file

@ -7,6 +7,7 @@ import 'package:cake_wallet/view_model/settings/regular_list_item.dart';
import 'package:cake_wallet/view_model/support_view_model.dart';
import 'package:flutter/material.dart';
import 'package:cake_wallet/src/screens/base_page.dart';
import 'package:cake_wallet/themes/extensions/option_tile_theme.dart';
import 'package:cake_wallet/generated/i18n.dart';
class SupportOtherLinksPage extends BasePage {
@ -22,8 +23,11 @@ class SupportOtherLinksPage extends BasePage {
@override
Widget body(BuildContext context) {
final iconColor = Theme.of(context).extension<SupportPageTheme>()!.iconColor;
final isLightMode = Theme.of(context).extension<OptionTileTheme>()?.useDarkImage ?? false;
return Container(
child: Center(
child: ConstrainedBox(
@ -37,16 +41,16 @@ class SupportOtherLinksPage extends BasePage {
if (item is RegularListItem) {
return SettingsCellWithArrow(title: item.title, handler: item.handler);
}
if (item is LinkListItem) {
bool hasLightIcon = false;
if (item.lightIcon != null) hasLightIcon = true;
return SettingsLinkProviderCell(
title: item.title,
icon: item.icon,
icon: isLightMode && hasLightIcon ? item.lightIcon : item.icon,
iconColor: item.hasIconColor ? iconColor : null,
link: item.link,
linkTitle: item.linkTitle);
}
return Container();
}),
),

View file

@ -8,10 +8,12 @@ class LinkListItem extends SettingsListItem {
required this.link,
required this.linkTitle,
this.icon,
this.lightIcon,
this.hasIconColor = false})
: super(title);
final String? icon;
final String? lightIcon;
final String link;
final String linkTitle;
final bool hasIconColor;

View file

@ -33,11 +33,6 @@ abstract class SupportViewModelBase with Store {
icon: 'assets/images/Telegram.png',
linkTitle: '@cakewallet_bot',
link: 'https://t.me/cakewallet_bot'),
LinkListItem(
title: 'Twitter',
icon: 'assets/images/Twitter.png',
linkTitle: '@cakewallet',
link: 'https://twitter.com/cakewallet'),
LinkListItem(
title: 'ChangeNow',
icon: 'assets/images/change_now.png',
@ -46,7 +41,7 @@ abstract class SupportViewModelBase with Store {
LinkListItem(
title: 'SideShift',
icon: 'assets/images/sideshift.png',
linkTitle: S.current.help,
linkTitle: 'help.sideshift.ai',
link: 'https://help.sideshift.ai/en/'),
LinkListItem(
title: 'SimpleSwap',
@ -58,19 +53,41 @@ abstract class SupportViewModelBase with Store {
icon: 'assets/images/exolix.png',
linkTitle: 'support@exolix.com',
link: 'mailto:support@exolix.com'),
LinkListItem(
title: 'Quantex',
icon: 'assets/images/quantex.png',
linkTitle: 'help.myquantex.com',
link: 'mailto:support@exolix.com'),
LinkListItem(
title: 'Trocador',
icon: 'assets/images/trocador.png',
linkTitle: 'mail@trocador.app',
link: 'mailto:mail@trocador.app'),
LinkListItem(
title: 'Onramper',
icon: 'assets/images/onramper_dark.png',
lightIcon: 'assets/images/onramper_light.png',
linkTitle: 'View exchanges',
link: 'https://guides.cakewallet.com/docs/service-support/buy/#onramper'),
LinkListItem(
title: 'DFX',
icon: 'assets/images/dfx_dark.png',
lightIcon: 'assets/images/dfx_light.png',
linkTitle: 'support@dfx.swiss',
link: 'mailto:support@dfx.swiss'),
if (!isMoneroOnly) ... [
LinkListItem(
title: 'Wyre',
icon: 'assets/images/wyre.png',
linkTitle: S.current.submit_request,
link: 'https://wyre-support.zendesk.com/hc/en-us/requests/new'),
LinkListItem(
title: 'MoonPay',
icon: 'assets/images/moonpay.png',
hasIconColor: true,
linkTitle: S.current.submit_request,
link: 'https://support.moonpay.com/hc/en-gb/requests/new')
]
link: 'https://support.moonpay.com/hc/en-gb/requests/new'),
LinkListItem(
title: 'Robinhood Connect',
icon: 'assets/images/robinhood_dark.png',
lightIcon: 'assets/images/robinhood_light.png',
linkTitle: S.current.submit_request,
link: 'https://robinhood.com/contact')
]
//LinkListItem(
// title: 'Yat',
// icon: 'assets/images/yat_mini_logo.png',