Skip to content

Commit

Permalink
fix:bugs & change i10n content
Browse files Browse the repository at this point in the history
  • Loading branch information
amazingCoding committed Apr 13, 2023
1 parent bd96cd5 commit ddc561e
Show file tree
Hide file tree
Showing 61 changed files with 608 additions and 669 deletions.
12 changes: 3 additions & 9 deletions ios/Runner.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -384,18 +384,16 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
DEVELOPMENT_TEAM = 8LQTZ965C8;
ENABLE_BITCODE = NO;
INFOPLIST_FILE = Runner/Info.plist;
INFOPLIST_KEY_CFBundleDisplayName = XDAG;
INFOPLIST_KEY_CFBundleDisplayName = "XDAG-Pro";
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.business";
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.0.0;
PRODUCT_BUNDLE_IDENTIFIER = com.xdag.io;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
Expand Down Expand Up @@ -521,18 +519,16 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
DEVELOPMENT_TEAM = 8LQTZ965C8;
ENABLE_BITCODE = NO;
INFOPLIST_FILE = Runner/Info.plist;
INFOPLIST_KEY_CFBundleDisplayName = XDAG;
INFOPLIST_KEY_CFBundleDisplayName = "XDAG-Pro";
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.business";
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.0.0;
PRODUCT_BUNDLE_IDENTIFIER = com.xdag.io;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
Expand All @@ -548,18 +544,16 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
DEVELOPMENT_TEAM = 8LQTZ965C8;
ENABLE_BITCODE = NO;
INFOPLIST_FILE = Runner/Info.plist;
INFOPLIST_KEY_CFBundleDisplayName = XDAG;
INFOPLIST_KEY_CFBundleDisplayName = "XDAG-Pro";
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.business";
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.0.0;
PRODUCT_BUNDLE_IDENTIFIER = com.xdag.io;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
Expand Down
18 changes: 9 additions & 9 deletions legals/privacy_policy.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,21 +7,21 @@
</head>

<body>
<h1>XDAG App Privacy Policy</h1>
<p>When you use our XDAG application, we take your privacy and security very seriously. This Privacy Policy is
<h1>XDAG-Pro App Privacy Policy</h1>
<p>When you use our XDAG-Pro application, we take your privacy and security very seriously. This Privacy Policy is
designed to explain when and how we collect, use, protect, and disclose your personal information.</p>
<h2>1. Information Collection</h2>
<p>We only collect necessary information to provide the services and features of the XDAG application. We may collect
<p>We only collect necessary information to provide the services and features of the XDAG-Pro application. We may collect
the following information:</p>
<ul>
<li>Device Information: We may collect device information, such as your device model, operating system version, and
device identifier, when you use the XDAG application.</li>
<li>Application Usage Data: We may collect information about how you use the XDAG application, such as the pages you
device identifier, when you use the XDAG-Pro application.</li>
<li>Application Usage Data: We may collect information about how you use the XDAG-Pro application, such as the pages you
open, the features you use, and your transaction history.</li>
<li>Wallet Address: We may collect your wallet address used for transactions.</li>
</ul>
<h2>2. Information Use</h2>
<p>We only use the collected information to provide the services and features of the XDAG application, such as:</p>
<p>We only use the collected information to provide the services and features of the XDAG-Pro application, such as:</p>
<ul>
<li>Provide you with transaction history and balance information.</li>
<li>Optimize application performance and stability.</li>
Expand All @@ -43,17 +43,17 @@ <h2>4. Information Disclosure</h2>
<li>Necessary disclosure to protect our rights or property, user safety, or public interest.</li>
</ul>
<h2>5. Third-Party Services</h2>
<p>Our XDAG application may link to third-party services or websites. We cannot control the privacy policies or
<p>Our XDAG-Pro application may link to third-party services or websites. We cannot control the privacy policies or
security measures of these third-party services or websites. Therefore, we recommend that you review the privacy
policies of these third-party services or websites.</p>
<h2>6. Changes to Privacy Policy</h2>
<p>We may update this Privacy Policy from time to time. If we make any material changes, we will notify you through
the XDAG application or other appropriate means. Please check this Privacy Policy regularly for updates.</p>
the XDAG-Pro application or other appropriate means. Please check this Privacy Policy regularly for updates.</p>
<h2>7. Contact Us</h2>
<p>If you have any questions or comments about our Privacy Policy, please contact us. Our contact information is as
follows:</p>
<ul>
<li>Email: communitymanager@xdag.io</li>
<li>Email: communitymanager@XDAG-Pro.io</li>
</ul>
</body>

Expand Down
38 changes: 19 additions & 19 deletions legals/terms_of_use.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,46 +3,46 @@

<head>
<meta charset="UTF-8">
<title>XDAG Terms of Use</title>
<title>XDAG-Pro Terms of Use</title>
</head>

<body>
<h1>XDAG Terms of Use</h1>
<h1>XDAG-Pro Terms of Use</h1>
<h2>1. Service Description</h2>
<p>The XDAG application is a digital wallet application designed to allow users to manage and store digital currencies
<p>The XDAG-Pro application is a digital wallet application designed to allow users to manage and store digital currencies
more conveniently.</p>
<h2>2. User Registration</h2>
<p>Before using the XDAG application, you need to register and create an account. You must provide accurate, true,
<p>Before using the XDAG-Pro application, you need to register and create an account. You must provide accurate, true,
up-to-date, and complete personal information and update it promptly if it changes. If the information you provide
is untrue, inaccurate, incomplete, or out-of-date, XDAG may suspend or terminate your account and refuse your access
to all or part of the XDAG application.</p>
is untrue, inaccurate, incomplete, or out-of-date, XDAG-Pro may suspend or terminate your account and refuse your access
to all or part of the XDAG-Pro application.</p>
<h2>3. User Behavior</h2>
<p>You must comply with local laws and regulations and the rules of the XDAG application. You may not engage in any
illegal, fraudulent, false, obscene, defamatory, infringing, or other harmful behavior using the XDAG application.
<p>You must comply with local laws and regulations and the rules of the XDAG-Pro application. You may not engage in any
illegal, fraudulent, false, obscene, defamatory, infringing, or other harmful behavior using the XDAG-Pro application.
</p>
<h2>4. Privacy Protection</h2>
<p>XDAG is committed to protecting your personal privacy. We will take appropriate measures to protect your personal
<p>XDAG-Pro is committed to protecting your personal privacy. We will take appropriate measures to protect your personal
information from unauthorized access, use, or disclosure. Please read our privacy policy to understand how we
collect, use, and protect your personal information.</p>
<h2>5. Fees and Payment</h2>
<p>The XDAG application may require payment for its services. Before using paid services, you need to understand the
<p>The XDAG-Pro application may require payment for its services. Before using paid services, you need to understand the
relevant fees and payment methods. You are responsible for paying all applicable fees and paying them on time. If
you fail to pay the fees on time, XDAG may suspend or terminate your account.</p>
you fail to pay the fees on time, XDAG-Pro may suspend or terminate your account.</p>
<h2>6. Service Changes and Interruptions</h2>
<p>XDAG may modify, suspend, or terminate part or all of the XDAG application's features. We will try our best to
<p>XDAG-Pro may modify, suspend, or terminate part or all of the XDAG-Pro application's features. We will try our best to
notify you in advance of any modifications, suspensions, or terminations, but we are not liable to you or any third
party for any such actions.</p>
<h2>7. Disclaimer of Liability</h2>
<p>The XDAG application's services are provided on an "as is" and "as available" basis. We do not guarantee that the
XDAG application's services will meet your needs, be secure, reliable, timely, accurate, complete, or uninterrupted.
We are not responsible for any losses or damages resulting from your use of the XDAG application.</p>
<p>The XDAG-Pro application's services are provided on an "as is" and "as available" basis. We do not guarantee that the
XDAG-Pro application's services will meet your needs, be secure, reliable, timely, accurate, complete, or uninterrupted.
We are not responsible for any losses or damages resulting from your use of the XDAG-Pro application.</p>
<h2>8. Intellectual Property</h2>
<p>The XDAG application contains information and content protected by intellectual property laws, including but not
limited to text, images, graphics, photos, audio, video, codes, software, user interface design, and XDAG
trademarks. Without explicit authorization from XDAG, any use or reproduction of such information and content is
<p>The XDAG-Pro application contains information and content protected by intellectual property laws, including but not
limited to text, images, graphics, photos, audio, video, codes, software, user interface design, and XDAG-Pro
trademarks. Without explicit authorization from XDAG-Pro, any use or reproduction of such information and content is
prohibited.</p>
<p>If you have any questions or concerns regarding these terms of use, please contact us at <a
href="mailto:communitymanager@xdag.io">communitymanager@xdag.io</a>.</p>
href="mailto:communitymanager@XDAG-Pro.io">communitymanager@XDAG-Pro.io</a>.</p>
</body>

</html>
6 changes: 4 additions & 2 deletions lib/common/global.dart
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ class WalletConfig {
String walletAddress;
bool hasReadLegal;
int network = 1;
bool lockApp = true;

WalletConfig({this.local = 0, this.hasSetPassword = false, this.hasSetBiometrics = false, this.walletAddress = "", this.hasReadLegal = false});
}
Expand All @@ -25,7 +26,7 @@ class Global {
static late WalletConfig walletConfig;
static late Box<Wallet> walletListBox;
static late List<ContactsItem> contactsListBox;
static late int devBiometricsType;
static int devBiometricsType = -1;

static late SharedPreferences _prefs;
static late FlutterSecureStorage _storage;
Expand Down Expand Up @@ -103,6 +104,7 @@ class Global {

static checkPassword(String password) async {
String? savedPassword = await _storage.read(key: _passwordKey);
print("savedPassword: $savedPassword and password: $password");
return savedPassword == password;
}

Expand Down Expand Up @@ -167,7 +169,7 @@ class Global {
if (res != null) {
throw Exception("address exist");
}
Wallet wallet = Wallet(name, "0.00", address, true, !needBackUp);
Wallet wallet = Wallet(name, "0.00", address, true, !needBackUp, false);
await _storage.write(key: address, value: data);
await walletListBox.add(wallet);
return wallet;
Expand Down
13 changes: 12 additions & 1 deletion lib/common/helper.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import 'dart:convert';
import 'dart:io';
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
Expand Down Expand Up @@ -57,6 +56,18 @@ class Helper {
return "${date.year}-${date.month < 10 ? "0${date.month}" : date.month}-${date.day < 10 ? "0${date.day}" : date.day} ${date.hour < 10 ? "0${date.hour}" : date.hour}:${date.minute < 10 ? "0${date.minute}" : date.minute}";
}

static String formatDouble(String num) {
String result;
double number = double.parse(num);
if (number == number.toInt()) {
result = "${number.toInt()}.00";
} else {
// 向下保留两位小数
result = number.toStringAsFixed(2);
}
return result;
}

// show toast
static void showToast(BuildContext context, String msg) {
ScaffoldMessenger.of(context).removeCurrentSnackBar();
Expand Down
1 change: 0 additions & 1 deletion lib/common/transaction.dart
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,6 @@ class TransactionHelper {
}
return true;
} catch (e) {
print(e);
return false;
}
}
Expand Down
13 changes: 8 additions & 5 deletions lib/l10n/app_de.arb
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"repeat_password": "Passwort wiederholen",
"security": "Sicherheit",
"walletName": "Wallet-Name",
"createWalletTips": "Ich verstehe, dass das XDAG Wallet mein Passwort nicht wiederherstellen kann",
"createWalletTips": "Ich verstehe, dass XDAG-Pro mein Passwort nicht wiederherstellen kann",
"continueText": "Fortfahren",
"mnemonic": "Mnemonic",
"privateKey": "Privater Schlüssel",
Expand Down Expand Up @@ -75,8 +75,8 @@
"fee":"Gebühr",
"cancel": "Abbrechen",
"verify_protect_wallet": "Bitte verifizieren Sie, um Ihre Brieftasche zu schützen",
"review_Privacy_Policy": "Bitte lesen Sie die Nutzungsbedingungen und Datenschutzbestimmungen der XDAG Wallet.",
"accepted_Privacy_Policy": "Ich habe die Nutzungsbedingungen und Datenschutzbestimmungen gelesen und akzeptiert.",
"review_Privacy_Policy": "Bitte überprüfen Sie die Datenschutzrichtlinien und Nutzungsbedingungen von XDAG-Pro.",
"accepted_Privacy_Policy":"Ich habe die Datenschutzrichtlinien und Nutzungsbedingungen gelesen und akzeptiert.",
"snapshot": "Snapshot",
"walletAddress": "Wallet-Adresse",
"to": "An",
Expand All @@ -99,7 +99,7 @@
"confirm_Mnemonic":"Mnemonic bestätigen",
"successful":"Erfolgreich",
"backup_test_tips_4":"Sie haben den Wallet-Schutztest bestanden. Bitte denken Sie daran, dass Helferwörter gespeichert werden müssen.",
"backup_test_tips_5":"Wenn Sie sie verlieren, kann die XDAG-Brieftasche Ihre Brieftasche nicht wiederherstellen.",
"backup_test_tips_5":"Wenn Sie es verlieren, kann XDAG-Pro Ihre Brieftasche nicht wiederherstellen.",
"secure_wallet":"Schützen Sie Ihre Geldbörse",
"start":"Starten",
"next":"Weiter",
Expand All @@ -118,5 +118,8 @@
"delete_contact":"Bestätigen Sie das Löschen der Kontakte?",
"contact_name_error":"Kontaktname unterstützt nur Buchstaben, Zahlen und Leerzeichen",
"contact_tips":"Bitte beachten Sie, dass Kontakte nur lokal auf diesem Gerät gespeichert werden. Wenn Sie die App löschen, gehen Ihre Kontakte dauerhaft verloren und können nicht wiederhergestellt werden.",
"no_contacts":"Keine Kontakte"
"no_contacts":"Keine Kontakte",
"tips":"Tipps",
"wallet_tips":"Wischen Sie den Eintrag nach rechts, um das Wallet zu löschen。",
"hide_balance":"Guthaben ausblenden"
}
29 changes: 16 additions & 13 deletions lib/l10n/app_en.arb
Original file line number Diff line number Diff line change
Expand Up @@ -16,21 +16,21 @@
"repeat_password": "Repeat Password",
"security": "Security",
"walletName": "Wallet Name",
"createWalletTips": "I understand that the XDAG wallet can't recover my password",
"createWalletTips": "I understand that XDAG-Pro can't recover my password",
"continueText": "Continue",
"mnemonic": "Mnemonic",
"privateKey":"Private Key",
"skip_for_now": "Skip for now",
"create_biometrics_tips_1": "Click to enable Face ID",
"create_biometrics_tips_2": "Click to enable Touch ID",
"create_biometrics_tips_3": "Click to enable Biometrics",
"create_biometrics_tips_1": "Press here enable Face ID",
"create_biometrics_tips_2": "Press here enable Touch ID",
"create_biometrics_tips_3": "Press here enable Biometrics",
"attention": "Attention",
"reset_password_tips": "Although you have created a password in the previous operation, you can reset it at any time before importing or creating a wallet.",
"reset_password": "Reset Password",
"language": "Language",
"legal_documents": "Legal documents",
"about_us": "About us",
"setting": "Setting",
"setting": "Settings",
"wallet": "Wallet",
"privacy_Policy": "Privacy Policy",
"terms_of_Use": "Terms of Use",
Expand All @@ -46,9 +46,9 @@
"backup":"Backup",
"delete_wallet":"Delete Wallet",
"enter_password":"Enter password",
"use_biometrics_tips_1": "Click to use Face ID",
"use_biometrics_tips_2": "Click to use Touch ID",
"use_biometrics_tips_3": "Click to use Biometrics",
"use_biometrics_tips_1": "Press here use Face ID",
"use_biometrics_tips_2": "Press here use Touch ID",
"use_biometrics_tips_3": "Press here use Biometrics",
"use_password": "Use password",
"use_biometrics_1": "Use Face ID",
"use_biometrics_2": "Use Touch ID",
Expand All @@ -67,16 +67,16 @@
"disenable_biometrics_1": "Disenable Face ID",
"disenable_biometrics_2": "Disenable Touch ID",
"disenable_biometrics_3": "Disenable Biometrics",
"no_transactions":"No transactions",
"no_transactions":"Any transaction",
"send_on":"Send on",
"receive_on":"Receive on",
"receiver":"Receiver",
"sender":"Sender",
"fee":"Fee",
"cancel":"Cancel",
"verify_protect_wallet":"Please verify to protect your wallet",
"review_Privacy_Policy":"Please review the XDAG Wallet Terms of Service and Privacy Policy.",
"accepted_Privacy_Policy":"I have read and accepted the Terms of Service and Privacy Policy.",
"review_Privacy_Policy":"Please review XDAG-Pro Privacy Policy and Terms of Service.",
"accepted_Privacy_Policy":"I have read and accepted the Privacy Policy and Terms of Service.",
"snapshot":"Snapshot",
"walletAddress":"Wallet address",
"to":"To",
Expand All @@ -99,7 +99,7 @@
"confirm_Mnemonic":"Confirm Mnemonic",
"successful":"Successful",
"backup_test_tips_4":"You have passed the wallet protection test, please remember that helper words must be saved.",
"backup_test_tips_5":"If you lose it, the XDAG wallet cannot recover your wallet.",
"backup_test_tips_5":"If you lose it, XDAG-Pro cannot recover your wallet.",
"secure_wallet":"Secure Your Wallet",
"start":"Start",
"next":"Next",
Expand All @@ -118,5 +118,8 @@
"delete_contact":"Do you confirm to delete contacts?",
"contact_name_error":"Contact name only supports letters, numbers, and spaces",
"contact_tips":"Please note that contacts are only stored locally on this device. If you delete the app, your contacts will be permanently lost and cannot be recovered.",
"no_contacts":"No contacts"
"no_contacts":"Any contact",
"tips":"Tips",
"wallet_tips":"Swipe the item to the right to delete the wallet.",
"hide_balance":"Hide Balance"
}
Loading

0 comments on commit ddc561e

Please sign in to comment.