From f6782b7290b2a315139c07bb081642b7e482ae0c Mon Sep 17 00:00:00 2001 From: Adrien Hopkins Date: Fri, 19 Aug 2022 12:05:20 -0500 Subject: Extracted all remaining strings to en.json - Changed SATS to SAT, and hours to hr to be more international - Edited conversion fee warning because it was incorrect (you only pay a fee if you're converting between BTC<->Liquid<->Lightning) --- src/locales/en.json | 68 ++++++++++++++++++++++++- src/routes/+error.svelte | 5 +- src/routes/[username]/+page.svelte | 7 +-- src/routes/[username]/dashboard/+page.svelte | 20 ++++---- src/routes/[username]/receive/+page.svelte | 11 ++-- src/routes/[username]/settings/+page.svelte | 57 ++++++++++----------- src/routes/[username]/support/+page.svelte | 11 ++-- src/routes/[username]/transactions/+page.svelte | 15 +++--- 8 files changed, 133 insertions(+), 61 deletions(-) (limited to 'src') diff --git a/src/locales/en.json b/src/locales/en.json index fc276ef2..dd1fac89 100644 --- a/src/locales/en.json +++ b/src/locales/en.json @@ -22,6 +22,10 @@ "familialRelationships": "Husband, father, brother, son" } }, + "error": { + "header": "Error", + "message": "Please try again or contact support." + }, "faq": { "header": "FAQ", "cost": { @@ -114,5 +118,67 @@ "dashboard": "Dashboard", "settings": "Settings", "support": "Support" - } + }, + "user": { + "addressGoesHere": "Address goes here", + "follow": "Follow", + "remove": "Remove", + "scanToPayBTC": "Scan to pay with bitcoin", + "dashboard": { + "ACCOUNT_BALANCE": "ACCOUNT BALANCE", + "bitcoinPrice": "Bitcoin Price:", + "conversionFeeWarning": "You will be charged a 1% conversion fee if you withdraw more of a certain type of Bitcoin than you deposit.", + "dataFromBinance": "Data from Binance.", + "fetchingRate": "fetching rate...", + "optionalNote": "Note (Optional)", + "send": "Send", + "withdraw": "Withdraw" + }, + "receive": { + "lessThan1BTCWarning": "Please enter an amount less than 1 bitcoin.", + "showQR": "Show QR" + }, + "settings": { + "header": "Settings", + "ACCOUNT": "ACCOUNT", + "POINT_OF_SALE": "POINT OF SALE", + "SECURITY": "SECURITY", + "locale": "Language", + "username": "Username", + "newPassword": "New Password", + "businessAddress": "Business Address", + "emailNotifications": "Email Notifications", + "emailNotificationsDescription": "Get notified via email when a change occurs on your account or when people send you payments.", + "smsNotifications": "SMS Notifications", + "smsNotificationsDescription": "CoinOS will send you text notifications when this is enabled.", + "theme": "Color Theme", + "themeDescription": "Select from the default color themes.", + "localCurrency": "Local Currency", + "btcUnit": "Display bitcoin in:", + "securityPIN": "Security PIN", + "securityPINDescription": "Set a security pin that will be used to unlock your settings and to send outgoing payments.", + "setPIN": "Set PIN", + "autoLock": "Auto-Lock Timer", + "autoLockDescription": "Your account will go into a secure mode automatically after a specified time:", + "twofa": "2-Factor Authentication", + "twofaDescription": "Add an extra level of security to your device by enableing 2-factor authentication.", + "twofaSetup": "Set up 2FA" + }, + "support": { + "header": "Support", + "email": "Email", + "accountName": "Account Name", + "message": "Message", + "send": "Send" + }, + "transactions": { + "header": "Transaction History", + "AMOUNT": "AMOUNT", + "TYPE": "TYPE", + "TIME": "TIME", + "sent": "Sent", + "received": "Received", + "empty": "No transactions yet." + } + } } diff --git a/src/routes/+error.svelte b/src/routes/+error.svelte index e555a032..2a8846c3 100644 --- a/src/routes/+error.svelte +++ b/src/routes/+error.svelte @@ -1,6 +1,7 @@ {#if $page.error.message.includes('not found') || $page.status === 404} @@ -14,9 +15,9 @@ -

Error

+

{$_('error.header'), { default: "Error" }}

{$page.error.message.toUpperCase()}

-

Please try again or contact support.

+

{$_('error.message'), { default: "Please try again or contact support." }}

{/if} diff --git a/src/routes/[username]/+page.svelte b/src/routes/[username]/+page.svelte index 973e8798..f22bd218 100644 --- a/src/routes/[username]/+page.svelte +++ b/src/routes/[username]/+page.svelte @@ -4,6 +4,7 @@ import { AppHeader, Icon, PageNotFound } from '$comp'; import { user } from '$lib/store'; import { copy } from '$lib/utils'; + import { _ } from 'svelte-i18n'; export let data; $: ({ username } = data); @@ -43,7 +44,7 @@

{username}

-

Address goes here

+

{$_('user.addressGoesHere')}

@@ -62,7 +63,7 @@ class="w-[292px] md:w-[342px] h-[342px] border border-lightgrey rounded-3xl flex p-5 justify-center items-center relative" /> -

Scan to pay with bitcoin

+

{$_('user.scanToPayBTC')}

{#if !withdrawing} Bitcoin Price: {$rate ? btcPrice : 'fetching rate...'} + >{$_('user.dashboard.bitcoinPrice')} + {$rate ? btcPrice : $_('user.dashboard.fetchingRate')} {$preferredCurrency} Data from Binance. + >{@html $_('user.dashboard.dataFromBinance')}

- ACCOUNT BALANCE + {$_('user.dashboard.ACCOUNT_BALANCE')}

{$rate ? accountBalanceFiat : 'fetching rate...'}{$rate ? accountBalanceFiat : $_('user.dashboard.fetchingRate')} - {accountBalanceSats} SATS + {accountBalanceSats} SAT $_('user.dashboard.withdraw') -

You will be charged a 1% withdrawal fee on the amount.

+

{$_('user.dashboard.conversionFeeWarning')}

{:else}
- +