mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2024-12-22 19:49:22 +00:00
Add current route to router. Add yat contacts to support screen.
This commit is contained in:
parent
fe3d00f1a8
commit
cf20123ede
6 changed files with 25 additions and 5 deletions
4
.gitignore
vendored
4
.gitignore
vendored
|
@ -105,3 +105,7 @@ ios/Flutter/.last_build_id
|
||||||
|
|
||||||
\#*\#
|
\#*\#
|
||||||
.\#*
|
.\#*
|
||||||
|
|
||||||
|
ios/build
|
||||||
|
*.sublime-workspace
|
||||||
|
*.sublime-project
|
||||||
|
|
BIN
assets/images/yat_mini_logo.png
Normal file
BIN
assets/images/yat_mini_logo.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 5.9 KiB |
|
@ -68,7 +68,11 @@ import 'package:cake_wallet/src/screens/exchange_trade/exchange_trade_page.dart'
|
||||||
import 'package:flutter/services.dart';
|
import 'package:flutter/services.dart';
|
||||||
import 'package:hive/hive.dart';
|
import 'package:hive/hive.dart';
|
||||||
|
|
||||||
|
RouteSettings currentRouteSettings;
|
||||||
|
|
||||||
Route<dynamic> createRoute(RouteSettings settings) {
|
Route<dynamic> createRoute(RouteSettings settings) {
|
||||||
|
currentRouteSettings = settings;
|
||||||
|
|
||||||
switch (settings.name) {
|
switch (settings.name) {
|
||||||
case Routes.welcome:
|
case Routes.welcome:
|
||||||
return MaterialPageRoute<void>(builder: (_) => createWelcomePage());
|
return MaterialPageRoute<void>(builder: (_) => createWelcomePage());
|
||||||
|
|
|
@ -23,6 +23,7 @@ import 'package:mobx/mobx.dart';
|
||||||
import 'package:smooth_page_indicator/smooth_page_indicator.dart';
|
import 'package:smooth_page_indicator/smooth_page_indicator.dart';
|
||||||
import 'package:flutter_spinkit/flutter_spinkit.dart';
|
import 'package:flutter_spinkit/flutter_spinkit.dart';
|
||||||
import 'package:cake_wallet/main.dart';
|
import 'package:cake_wallet/main.dart';
|
||||||
|
import 'package:cake_wallet/router.dart';
|
||||||
|
|
||||||
class DashboardPage extends BasePage {
|
class DashboardPage extends BasePage {
|
||||||
DashboardPage({
|
DashboardPage({
|
||||||
|
@ -159,11 +160,16 @@ class DashboardPage extends BasePage {
|
||||||
walletViewModel: walletViewModel));
|
walletViewModel: walletViewModel));
|
||||||
pages.add(BalancePage(dashboardViewModel: walletViewModel));
|
pages.add(BalancePage(dashboardViewModel: walletViewModel));
|
||||||
pages.add(TransactionsPage(dashboardViewModel: walletViewModel));
|
pages.add(TransactionsPage(dashboardViewModel: walletViewModel));
|
||||||
|
|
||||||
_isEffectsInstalled = true;
|
_isEffectsInstalled = true;
|
||||||
|
|
||||||
if (walletViewModel.shouldShowYatPopup) {
|
if (walletViewModel.shouldShowYatPopup) {
|
||||||
await Future<void>.delayed(Duration(seconds: 1));
|
await Future<void>.delayed(Duration(seconds: 1));
|
||||||
|
|
||||||
|
if (currentRouteSettings.name == Routes.preSeed
|
||||||
|
|| currentRouteSettings.name == Routes.seed) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
await showPopUp<void>(
|
await showPopUp<void>(
|
||||||
context: context,
|
context: context,
|
||||||
builder: (BuildContext context) {
|
builder: (BuildContext context) {
|
||||||
|
|
|
@ -19,7 +19,7 @@ class SettingsLinkProviderCell extends StandardListRow {
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget buildLeading(BuildContext context) =>
|
Widget buildLeading(BuildContext context) =>
|
||||||
icon != null ? Image.asset(icon, color: iconColor) : null;
|
icon != null ? Image.asset(icon, color: iconColor, height: 30, width: 30) : null;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget buildTrailing(BuildContext context) => Text(linkTitle,
|
Widget buildTrailing(BuildContext context) => Text(linkTitle,
|
||||||
|
|
|
@ -59,7 +59,13 @@ abstract class SupportViewModelBase with Store {
|
||||||
icon: 'assets/images/moonpay.png',
|
icon: 'assets/images/moonpay.png',
|
||||||
hasIconColor: true,
|
hasIconColor: true,
|
||||||
linkTitle: S.current.submit_request,
|
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: 'Yat',
|
||||||
|
icon: 'assets/images/yat_mini_logo.png',
|
||||||
|
hasIconColor: true,
|
||||||
|
linkTitle: 'support@y.at',
|
||||||
|
link: 'mailto:support@y.at')
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
static const url = 'https://cakewallet.com/guide/';
|
static const url = 'https://cakewallet.com/guide/';
|
||||||
|
|
Loading…
Reference in a new issue