Browse Source

remove app: prefix from translation keys

gre-patch-1
Valentin D. Pinkman 6 years ago
parent
commit
e6e362ccfd
No known key found for this signature in database GPG Key ID: E7D110669FFB8D3E
  1. 50
      scripts/check-wordings.js
  2. 6
      src/components/AccountPage/AccountHeaderActions.js
  3. 6
      src/components/AccountPage/EmptyStateAccount.js
  4. 2
      src/components/AccountPage/index.js
  5. 8
      src/components/AdvancedOptions/BitcoinKind.js
  6. 4
      src/components/AdvancedOptions/EthereumKind.js
  7. 2
      src/components/AdvancedOptions/RippleKind.js
  8. 14
      src/components/BalanceSummary/BalanceInfos.js
  9. 18
      src/components/CurrentAddress/index.js
  10. 2
      src/components/DashboardPage/AccountCardListHeader.js
  11. 4
      src/components/DashboardPage/AccountCardPlaceholder.js
  12. 8
      src/components/DashboardPage/AccountsOrder.js
  13. 6
      src/components/DashboardPage/CurrentGreetings.js
  14. 8
      src/components/DashboardPage/EmptyState.js
  15. 2
      src/components/DashboardPage/SummaryDesc.js
  16. 2
      src/components/DashboardPage/index.js
  17. 4
      src/components/DeviceInteraction/components.js
  18. 4
      src/components/EnsureDeviceApp.js
  19. 4
      src/components/ExchangePage/ExchangeCard.js
  20. 4
      src/components/ExchangePage/index.js
  21. 2
      src/components/ExportLogsBtn.js
  22. 4
      src/components/FeesField/BitcoinKind.js
  23. 2
      src/components/FeesField/GenericContainer.js
  24. 2
      src/components/GenuineCheck.js
  25. 2
      src/components/GenuineCheckModal.js
  26. 2
      src/components/GlobalSearch.js
  27. 16
      src/components/IsUnlocked.js
  28. 23
      src/components/MainSideBar/index.js
  29. 12
      src/components/ManagerPage/AppsList.js
  30. 6
      src/components/ManagerPage/Dashboard.js
  31. 8
      src/components/ManagerPage/FirmwareUpdate.js
  32. 2
      src/components/ManagerPage/ManagerApp.js
  33. 4
      src/components/ManagerPage/ManagerGenuineCheck.js
  34. 6
      src/components/ManagerPage/PlugYourDevice.js
  35. 4
      src/components/ManagerPage/UpdateFirmwareButton.js
  36. 4
      src/components/Onboarding/OnboardingFooter.js
  37. 22
      src/components/Onboarding/steps/Analytics.js
  38. 6
      src/components/Onboarding/steps/Finish.js
  39. 18
      src/components/Onboarding/steps/GenuineCheck/GenuineCheckErrorPage.js
  40. 8
      src/components/Onboarding/steps/GenuineCheck/GenuineCheckUnavailable.js
  41. 20
      src/components/Onboarding/steps/GenuineCheck/index.js
  42. 10
      src/components/Onboarding/steps/Init.js
  43. 10
      src/components/Onboarding/steps/NoDevice.js
  44. 6
      src/components/Onboarding/steps/SelectDevice.js
  45. 12
      src/components/Onboarding/steps/SelectPIN/SelectPINblue.js
  46. 14
      src/components/Onboarding/steps/SelectPIN/SelectPINnano.js
  47. 12
      src/components/Onboarding/steps/SelectPIN/SelectPINrestoreBlue.js
  48. 14
      src/components/Onboarding/steps/SelectPIN/SelectPINrestoreNano.js
  49. 4
      src/components/Onboarding/steps/SelectPIN/index.js
  50. 16
      src/components/Onboarding/steps/SetPassword.js
  51. 4
      src/components/Onboarding/steps/Start.js
  52. 18
      src/components/Onboarding/steps/WriteSeed/WriteSeedBlue.js
  53. 18
      src/components/Onboarding/steps/WriteSeed/WriteSeedNano.js
  54. 26
      src/components/Onboarding/steps/WriteSeed/WriteSeedRestore.js
  55. 2
      src/components/OpenUserDataDirectoryBtn.js
  56. 2
      src/components/OperationsList/ConfirmationCheck.js
  57. 2
      src/components/OperationsList/DateCell.js
  58. 4
      src/components/OperationsList/index.js
  59. 2
      src/components/PillsDaysCount.js
  60. 23
      src/components/RenderError.js
  61. 2
      src/components/RequestAmount/index.js
  62. 4
      src/components/SelectAccount/index.js
  63. 4
      src/components/SelectCurrency/index.js
  64. 6
      src/components/SelectExchange.js
  65. 8
      src/components/SettingsPage/CleanButton.js
  66. 10
      src/components/SettingsPage/DisablePasswordModal.js
  67. 4
      src/components/SettingsPage/LanguageSelect.js
  68. 2
      src/components/SettingsPage/LaunchOnboardingBtn.js
  69. 4
      src/components/SettingsPage/MarketIndicatorRadio.js
  70. 2
      src/components/SettingsPage/PasswordButton.js
  71. 6
      src/components/SettingsPage/PasswordForm.js
  72. 14
      src/components/SettingsPage/PasswordModal.js
  73. 2
      src/components/SettingsPage/ReleaseNotesButton.js
  74. 8
      src/components/SettingsPage/ResetButton.js
  75. 10
      src/components/SettingsPage/index.js
  76. 14
      src/components/SettingsPage/sections/About.js
  77. 4
      src/components/SettingsPage/sections/Currencies.js
  78. 8
      src/components/SettingsPage/sections/CurrencyRows.js
  79. 42
      src/components/SettingsPage/sections/Display.js
  80. 28
      src/components/SettingsPage/sections/Help.js
  81. 2
      src/components/SyncAgo.js
  82. 10
      src/components/TopBar/ActivityIndicator.js
  83. 4
      src/components/TopBar/index.js
  84. 2
      src/components/TranslatedError.js
  85. 4
      src/components/UpdateNotifier/UpdateDownloaded.js
  86. 4
      src/components/base/AccountsList/index.js
  87. 2
      src/components/base/CopyWithFeedback.js
  88. 2
      src/components/base/InputPassword/index.js
  89. 4
      src/components/base/Modal/ConfirmModal.js
  90. 2
      src/components/base/Modal/ModalTitle.js
  91. 2
      src/components/base/RetryButton.js
  92. 26
      src/components/modals/AccountSettingRenderBody.js
  93. 10
      src/components/modals/AddAccounts/index.js
  94. 2
      src/components/modals/AddAccounts/steps/01-step-choose-currency.js
  95. 4
      src/components/modals/AddAccounts/steps/02-step-connect-device.js
  96. 30
      src/components/modals/AddAccounts/steps/03-step-import.js
  97. 6
      src/components/modals/AddAccounts/steps/04-step-finish.js
  98. 8
      src/components/modals/Disclaimer.js
  99. 28
      src/components/modals/OperationDetails.js
  100. 10
      src/components/modals/Receive/index.js

50
scripts/check-wordings.js

@ -5,34 +5,34 @@ const { spawn } = require('child_process')
// those wordings are dynamically created, so they are detected
// as false positive
const WHITELIST = [
'app:operation.type.IN',
'app:operation.type.OUT',
'app:exchange.coinhouse',
'app:exchange.changelly',
'app:exchange.coinmama',
'app:exchange.simplex',
'app:exchange.paybis',
'app:addAccounts.accountToImportSubtitle_plural',
'app:dashboard.summary_plural',
'app:addAccounts.success_plural',
'app:addAccounts.successDescription_plural',
'app:time.since.day',
'app:time.since.week',
'app:time.since.month',
'app:time.since.year',
'app:time.day',
'app:time.week',
'app:time.month',
'app:time.year',
'app:addAccounts.cta.add_plural',
'app:manager.apps.installing',
'app:manager.apps.uninstalling',
'app:manager.apps.installSuccess',
'app:manager.apps.uninstallSuccess',
'operation.type.IN',
'operation.type.OUT',
'exchange.coinhouse',
'exchange.changelly',
'exchange.coinmama',
'exchange.simplex',
'exchange.paybis',
'addAccounts.accountToImportSubtitle_plural',
'dashboard.summary_plural',
'addAccounts.success_plural',
'addAccounts.successDescription_plural',
'time.since.day',
'time.since.week',
'time.since.month',
'time.since.year',
'time.day',
'time.week',
'time.month',
'time.year',
'addAccounts.cta.add_plural',
'manager.apps.installing',
'manager.apps.uninstalling',
'manager.apps.installSuccess',
'manager.apps.uninstallSuccess',
]
const WORDINGS = {
app: require('../static/i18n/en/app.json'),
require('../static/i18n/en/app.json'),
onboarding: require('../static/i18n/en/onboarding.json'),
// errors: require('../static/i18n/en/errors.json'),
// language: require('../static/i18n/en/language.json'),

6
src/components/AccountPage/AccountHeaderActions.js

@ -67,19 +67,19 @@ class AccountHeaderActions extends PureComponent<Props> {
<Button small primary onClick={() => openModal(MODAL_SEND, { account })}>
<Box horizontal flow={1} alignItems="center">
<IconSend size={12} />
<Box>{t('app:send.title')}</Box>
<Box>{t('send.title')}</Box>
</Box>
</Button>
<Button small primary onClick={() => openModal(MODAL_RECEIVE, { account })}>
<Box horizontal flow={1} alignItems="center">
<IconReceive size={12} />
<Box>{t('app:receive.title')}</Box>
<Box>{t('receive.title')}</Box>
</Box>
</Button>
</Fragment>
) : null}
<Tooltip render={() => t('app:account.settings.title')}>
<Tooltip render={() => t('account.settings.title')}>
<ButtonSettings onClick={() => openModal(MODAL_SETTINGS_ACCOUNT, { account })}>
<Box justifyContent="center">
<IconAccountSettings size={16} />

6
src/components/AccountPage/EmptyStateAccount.js

@ -40,9 +40,9 @@ class EmptyStateAccount extends PureComponent<Props, *> {
height="89"
/>
<Box mt={5} alignItems="center">
<Title>{t('app:account.emptyState.title')}</Title>
<Title>{t('account.emptyState.title')}</Title>
<Description mt={3} style={{ display: 'block' }}>
<Trans i18nKey="app:account.emptyState.desc">
<Trans i18nKey="account.emptyState.desc">
{'Make sure the'}
<Text ff="Open Sans|SemiBold" color="dark">
{account.currency.managerAppName}
@ -53,7 +53,7 @@ class EmptyStateAccount extends PureComponent<Props, *> {
<Button mt={5} primary onClick={() => openModal(MODAL_RECEIVE, { account })}>
<Box horizontal flow={1} alignItems="center">
<IconReceive size={12} />
<Box>{t('app:account.emptyState.buttons.receiveFunds')}</Box>
<Box>{t('account.emptyState.buttons.receiveFunds')}</Box>
</Box>
</Button>
</Box>

2
src/components/AccountPage/index.js

@ -97,7 +97,7 @@ class AccountPage extends PureComponent<Props> {
/>
</Box>
<OperationsList account={account} title={t('app:account.lastOperations')} />
<OperationsList account={account} title={t('account.lastOperations')} />
<StickyBackToTop />
</Fragment>

8
src/components/AdvancedOptions/BitcoinKind.js

@ -15,12 +15,12 @@ type Props = {
}
export default translate()(({ isRBF, onChangeRBF, t }: Props) => (
<Spoiler title={t('app:send.steps.amount.advancedOptions')}>
<Spoiler title={t('send.steps.amount.advancedOptions')}>
<Box horizontal align="center" flow={5}>
<Box style={{ width: 200 }}>
<Label>
<span>{t('app:send.steps.amount.useRBF')}</span>
<LabelInfoTooltip ml={1} text={t('app:send.steps.amount.useRBF')} />
<span>{t('send.steps.amount.useRBF')}</span>
<LabelInfoTooltip ml={1} text={t('send.steps.amount.useRBF')} />
</Label>
</Box>
<Box grow>
@ -32,7 +32,7 @@ export default translate()(({ isRBF, onChangeRBF, t }: Props) => (
<Box horizontal align="flex-start" flow={5}>
<Box style={{ width: 200 }}>
<Label>
<span>{t('app:send.steps.amount.message')}</span>
<span>{t('send.steps.amount.message')}</span>
</Label>
</Box>
<Box grow>

4
src/components/AdvancedOptions/EthereumKind.js

@ -15,11 +15,11 @@ type Props = {
}
export default translate()(({ gasLimit, onChangeGasLimit, t }: Props) => (
<Spoiler title={t('app:send.steps.amount.advancedOptions')}>
<Spoiler title={t('send.steps.amount.advancedOptions')}>
<Box horizontal align="center" flow={5}>
<Box style={{ width: 200 }}>
<Label>
<span>{t('app:send.steps.amount.ethereumGasLimit')}</span>
<span>{t('send.steps.amount.ethereumGasLimit')}</span>
</Label>
</Box>
<Box grow>

2
src/components/AdvancedOptions/RippleKind.js

@ -33,7 +33,7 @@ class RippleKind extends Component<Props> {
<Box vertical flow={5}>
<Box grow>
<Label>
<span>{t('app:send.steps.amount.rippleTag')}</span>
<span>{t('send.steps.amount.rippleTag')}</span>
</Label>
<Input value={String(tag || '')} onChange={this.onChange} />
</Box>

14
src/components/BalanceSummary/BalanceInfos.js

@ -56,11 +56,7 @@ export function BalanceSincePercent(props: BalanceSinceProps) {
withIcon
/>
)}
{!isAvailable ? (
<PlaceholderLine dark width={60} />
) : (
<Sub>{t(`app:time.since.${since}`)}</Sub>
)}
{!isAvailable ? <PlaceholderLine dark width={60} /> : <Sub>{t(`time.since.${since}`)}</Sub>}
</Box>
)
}
@ -82,11 +78,7 @@ export function BalanceSinceDiff(props: Props) {
withIcon
/>
)}
{!isAvailable ? (
<PlaceholderLine dark width={60} />
) : (
<Sub>{t(`app:time.since.${since}`)}</Sub>
)}
{!isAvailable ? <PlaceholderLine dark width={60} /> : <Sub>{t(`time.since.${since}`)}</Sub>}
</Box>
)
}
@ -127,7 +119,7 @@ function BalanceInfos(props: Props) {
isAvailable={isAvailable}
totalBalance={totalBalance}
>
<Sub>{t('app:dashboard.totalBalance')}</Sub>
<Sub>{t('dashboard.totalBalance')}</Sub>
</BalanceTotal>
<BalanceSincePercent
alignItems="flex-end"

18
src/components/CurrentAddress/index.js

@ -152,7 +152,7 @@ class CurrentAddress extends PureComponent<Props, { copyFeedback: boolean }> {
return (
<FooterButton
icon={<IconCopy size={16} />}
label={t('app:common.copyAddress')}
label={t('common.copyAddress')}
onClick={() => {
this.setState({ copyFeedback: true })
this._timeout = setTimeout(() => this.setState({ copyFeedback: false }), 1e3)
@ -193,17 +193,17 @@ class CurrentAddress extends PureComponent<Props, { copyFeedback: boolean }> {
<Label>
<Box>
{accountName ? (
<Trans i18nKey="app:currentAddress.for" parent="div">
<Trans i18nKey="currentAddress.for" parent="div">
{'Address for '}
<strong>{accountName}</strong>
</Trans>
) : (
t('app:currentAddress.title')
t('currentAddress.title')
)}
</Box>
</Label>
<Address>
{copyFeedback && <CopyFeedback>{t('app:common.addressCopied')}</CopyFeedback>}
{copyFeedback && <CopyFeedback>{t('common.addressCopied')}</CopyFeedback>}
{address}
</Address>
<Box horizontal flow={2} mt={2} alignItems="center" style={{ maxWidth: 320 }}>
@ -217,19 +217,17 @@ class CurrentAddress extends PureComponent<Props, { copyFeedback: boolean }> {
ff="Open Sans"
>
{isAddressVerified === null
? t('app:currentAddress.messageIfUnverified', { currencyName })
? t('currentAddress.messageIfUnverified', { currencyName })
: isAddressVerified
? t('app:currentAddress.messageIfAccepted', { currencyName })
: t('app:currentAddress.messageIfSkipped', { currencyName })}
? t('currentAddress.messageIfAccepted', { currencyName })
: t('currentAddress.messageIfSkipped', { currencyName })}
</Box>
</Box>
<Footer>
{isAddressVerified !== null ? (
<FooterButton
icon={<IconRecheck size={16} />}
label={
isAddressVerified === false ? t('app:common.verify') : t('app:common.reverify')
}
label={isAddressVerified === false ? t('common.verify') : t('common.reverify')}
onClick={onVerify}
/>
) : null}

2
src/components/DashboardPage/AccountCardListHeader.js

@ -20,7 +20,7 @@ class AccountCardListHeader extends PureComponent<Props> {
return (
<Box horizontal alignItems="flex-end">
<Text color="dark" ff="Museo Sans" fontSize={6} data-e2e="dashboard_AccountCount">
{t('app:dashboard.accounts.title', { count: accountsLength })}
{t('dashboard.accounts.title', { count: accountsLength })}
</Text>
<Box ml="auto" horizontal flow={1}>
<AccountsOrder />

4
src/components/DashboardPage/AccountCardPlaceholder.js

@ -44,10 +44,10 @@ class AccountCardPlaceholder extends PureComponent<{
textAlign="center"
style={{ maxWidth: 150 }}
>
{t('app:dashboard.emptyAccountTile.desc')}
{t('dashboard.emptyAccountTile.desc')}
</Box>
<Button primary onClick={this.onAddAccounts}>
{t('app:dashboard.emptyAccountTile.createAccount')}
{t('dashboard.emptyAccountTile.createAccount')}
</Button>
</Wrapper>
)

8
src/components/DashboardPage/AccountsOrder.js

@ -91,11 +91,11 @@ class AccountsOrder extends Component<Props> {
return [
{
key: 'name',
label: t('app:dashboard.accountsOrder.name'),
label: t('dashboard.accountsOrder.name'),
},
{
key: 'balance',
label: t('app:dashboard.accountsOrder.balance'),
label: t('dashboard.accountsOrder.balance'),
},
].map(item => ({
...item,
@ -141,7 +141,7 @@ class AccountsOrder extends Component<Props> {
>
<Track onUpdate event="ChangeSort" orderAccounts={orderAccounts} />
<Text ff="Open Sans|SemiBold" fontSize={4}>
{t('app:common.sortBy')}
{t('common.sortBy')}
</Text>
<Box
alignItems="center"
@ -152,7 +152,7 @@ class AccountsOrder extends Component<Props> {
horizontal
>
<Text color="dark">
{t(`app:dashboard.accountsOrder.${this.getCurrentValue() || 'balance'}`)}
{t(`dashboard.accountsOrder.${this.getCurrentValue() || 'balance'}`)}
</Text>
<IconAngleDown size={16} />
</Box>

6
src/components/DashboardPage/CurrentGreetings.js

@ -10,11 +10,11 @@ const getCurrentGreetings = () => {
const afternoon_breakpoint = 12
const evening_breakpoint = 17
if (localTimeHour >= afternoon_breakpoint && localTimeHour < evening_breakpoint) {
return 'app:dashboard.greeting.afternoon'
return 'dashboard.greeting.afternoon'
} else if (localTimeHour >= evening_breakpoint) {
return 'app:dashboard.greeting.evening'
return 'dashboard.greeting.evening'
}
return 'app:dashboard.greeting.morning'
return 'dashboard.greeting.morning'
}
class CurrentGettings extends PureComponent<{ t: T }> {

8
src/components/DashboardPage/EmptyState.js

@ -45,9 +45,9 @@ class EmptyState extends PureComponent<Props, *> {
height="157"
/>
<Box mt={5} alignItems="center">
<Title data-e2e="dashboard_empty_title">{t('app:emptyState.dashboard.title')}</Title>
<Title data-e2e="dashboard_empty_title">{t('emptyState.dashboard.title')}</Title>
<Description mt={3} style={{ maxWidth: 600 }}>
{t('app:emptyState.dashboard.desc')}
{t('emptyState.dashboard.desc')}
</Description>
<Box mt={5} horizontal style={{ width: 300 }} flow={3} justify="center">
<Button
@ -56,7 +56,7 @@ class EmptyState extends PureComponent<Props, *> {
onClick={this.handleInstallApp}
data-e2e="dashboard_empty_OpenManager"
>
{t('app:emptyState.dashboard.buttons.installApp')}
{t('emptyState.dashboard.buttons.installApp')}
</Button>
<Button
outline
@ -64,7 +64,7 @@ class EmptyState extends PureComponent<Props, *> {
onClick={() => openModal(MODAL_ADD_ACCOUNTS)}
data-e2e="dashboard_empty_AddAccounts"
>
{t('app:emptyState.dashboard.buttons.addAccount')}
{t('emptyState.dashboard.buttons.addAccount')}
</Button>
</Box>
</Box>

2
src/components/DashboardPage/SummaryDesc.js

@ -18,7 +18,7 @@ class SummaryDesc extends PureComponent<{
ff="Museo Sans|Light"
data-e2e="dashboard_accountsSummaryDesc"
>
{t('app:dashboard.summary', { count: totalAccounts })}
{t('dashboard.summary', { count: totalAccounts })}
</Text>
)
}

2
src/components/DashboardPage/index.js

@ -129,7 +129,7 @@ class DashboardPage extends PureComponent<Props> {
<OperationsList
onAccountClick={this.onAccountClick}
accounts={accounts}
title={t('app:dashboard.recentActivity')}
title={t('dashboard.recentActivity')}
withAccount
/>
)}

4
src/components/DeviceInteraction/components.js

@ -144,11 +144,11 @@ export const ErrorDescContainer = translate()(
<Box ml="auto" horizontal flow={2}>
{!!errorHelpURL && (
<FakeLink underline color="alertRed" onClick={() => openURL(errorHelpURL)}>
{t('app:common.help')}
{t('common.help')}
</FakeLink>
)}
<FakeLink underline color="alertRed" onClick={onRetry}>
{t('app:common.retry')}
{t('common.retry')}
</FakeLink>
</Box>
</Box>

4
src/components/EnsureDeviceApp.js

@ -74,7 +74,7 @@ class EnsureDeviceApp extends Component<{
const cur = account ? account.currency : currency
invariant(cur, 'No currency given')
return (
<Trans i18nKey="app:deviceConnect.step2.open" parent="div">
<Trans i18nKey="deviceConnect.step2.open" parent="div">
{'Open the '}
<Bold>{cur.managerAppName}</Bold>
{' app on your device'}
@ -94,7 +94,7 @@ class EnsureDeviceApp extends Component<{
{
id: 'device',
title: (
<Trans i18nKey="app:deviceConnect.step1.connect" parent="div">
<Trans i18nKey="deviceConnect.step1.connect" parent="div">
{'Connect and unlock your '}
<Bold>{'Ledger device'}</Bold>
</Trans>

4
src/components/ExchangePage/ExchangeCard.js

@ -31,9 +31,9 @@ export default class ExchangeCard extends PureComponent<{ t: T, card: CardType }
{logo}
</Box>
<Box shrink ff="Open Sans|Regular" fontSize={4} flow={3}>
<Box>{t(`app:exchange.${id}`)}</Box>
<Box>{t(`exchange.${id}`)}</Box>
<Box horizontal align="center" color="wallet" flow={1}>
<FakeLink onClick={this.onClick}>{t('app:exchange.visitWebsite')}</FakeLink>
<FakeLink onClick={this.onClick}>{t('exchange.visitWebsite')}</FakeLink>
<ExternalLinkIcon size={14} />
</Box>
</Box>

4
src/components/ExchangePage/index.js

@ -86,10 +86,10 @@ class ExchangePage extends PureComponent<Props> {
<Box pb={6} selectable>
<TrackPage category="Exchange" />
<Box ff="Museo Sans|Regular" fontSize={7} color="dark">
{t('app:exchange.title')}
{t('exchange.title')}
</Box>
<Box ff="Museo Sans|Light" fontSize={5} mb={5}>
{t('app:exchange.desc')}
{t('exchange.desc')}
</Box>
<Box flow={3}>{cards.map(card => <ExchangeCard key={card.key} t={t} card={card} />)}</Box>
</Box>

2
src/components/ExportLogsBtn.js

@ -78,7 +78,7 @@ class ExportLogsBtn extends Component<{
<KeyHandler keyValue="e" onKeyHandle={this.onKeyHandle} />
) : (
<Button small primary event="ExportLogs" onClick={this.handleExportLogs}>
{t('app:settings.exportLogs.btn')}
{t('settings.exportLogs.btn')}
</Button>
)
}

4
src/components/FeesField/BitcoinKind.js

@ -148,9 +148,7 @@ class FeesField extends Component<OwnProps, State> {
loading={!feePerByte && !error}
error={!feePerByte && error ? new FeeNotLoaded() : null}
renderRight={
<InputRight>
{t('app:send.steps.amount.unitPerByte', { unit: satoshi.code })}
</InputRight>
<InputRight>{t('send.steps.amount.unitPerByte', { unit: satoshi.code })}</InputRight>
}
allowZero
/>

2
src/components/FeesField/GenericContainer.js

@ -16,7 +16,7 @@ export default translate()(({ children, t }: { children: React$Node, t: * }) =>
openURL(urls.feesMoreInfo)
track('Send Flow Fees Help Requested')
}}
label={t('app:send.steps.amount.fees')}
label={t('send.steps.amount.fees')}
/>
<Box horizontal flow={5}>
{children}

2
src/components/GenuineCheck.js

@ -124,7 +124,7 @@ class GenuineCheck extends PureComponent<Props> {
{
id: 'device',
title: (
<Trans i18nKey="app:deviceConnect.step1.connect" parent="div">
<Trans i18nKey="deviceConnect.step1.connect" parent="div">
{'Connect and unlock your '}
<Bold>{'Ledger device'}</Bold>
</Trans>

2
src/components/GenuineCheckModal.js

@ -20,7 +20,7 @@ class GenuineCheckModal extends PureComponent<Props> {
const { t, onSuccess, onFail, onUnavailable } = this.props
return (
<ModalBody onClose={onClose}>
<ModalTitle>{t('app:genuinecheck.modal.title')}</ModalTitle>
<ModalTitle>{t('genuinecheck.modal.title')}</ModalTitle>
<ModalContent>
<GenuineCheck onSuccess={onSuccess} onFail={onFail} onUnavailable={onUnavailable} />
</ModalContent>

2
src/components/GlobalSearch.js

@ -66,7 +66,7 @@ class GlobalSearch extends PureComponent<Props, State> {
<IconSearch size={16} />
</Box>
<Input
placeholder={t('app:common.search')}
placeholder={t('common.search')}
innerRef={input => (this._input = input)}
onBlur={this.handleBlur}
onFocus={this.handleFocus}

16
src/components/IsUnlocked.js

@ -161,17 +161,17 @@ class IsUnlocked extends Component<Props, State> {
/>
}
/>
<PageTitle>{t('app:common.lockScreen.title')}</PageTitle>
<PageTitle>{t('common.lockScreen.title')}</PageTitle>
<LockScreenDesc>
{t('app:common.lockScreen.subTitle')}
{t('common.lockScreen.subTitle')}
<br />
{t('app:common.lockScreen.description')}
{t('common.lockScreen.description')}
</LockScreenDesc>
<Box horizontal align="center">
<Box style={{ width: 280 }}>
<InputPassword
autoFocus
placeholder={t('app:common.lockScreen.inputPlaceholder')}
placeholder={t('common.lockScreen.inputPlaceholder')}
type="password"
onChange={this.handleChangeInput('password')}
value={inputValue.password}
@ -187,7 +187,7 @@ class IsUnlocked extends Component<Props, State> {
</Box>
</Box>
<Button type="button" mt={3} small onClick={this.handleOpenHardResetModal}>
{t('app:common.lockScreen.lostPassword')}
{t('common.lockScreen.lostPassword')}
</Button>
</Box>
</form>
@ -199,9 +199,9 @@ class IsUnlocked extends Component<Props, State> {
onClose={this.handleCloseHardResetModal}
onReject={this.handleCloseHardResetModal}
onConfirm={this.handleHardReset}
confirmText={t('app:common.reset')}
title={t('app:settings.hardResetModal.title')}
desc={t('app:settings.hardResetModal.desc')}
confirmText={t('common.reset')}
title={t('settings.hardResetModal.title')}
desc={t('settings.hardResetModal.desc')}
renderIcon={this.hardResetIconRender}
/>
</Box>

23
src/components/MainSideBar/index.js

@ -90,7 +90,7 @@ class MainSideBar extends PureComponent<Props> {
ADD_ACCOUNT_EMPTY_STATE = (
<Box relative pr={3}>
<img style={{ position: 'absolute', top: -10, right: 5 }} alt="" src={i('arrow-add.svg')} />
{this.props.t('app:emptyState.sidebar.text')}
{this.props.t('emptyState.sidebar.text')}
</Box>
)
@ -107,10 +107,7 @@ class MainSideBar extends PureComponent<Props> {
const { pathname } = location
const addAccountButton = (
<AddAccountButton
tooltipText={t('app:addAccounts.title')}
onClick={this.handleOpenImportModal}
/>
<AddAccountButton tooltipText={t('addAccounts.title')} onClick={this.handleOpenImportModal} />
)
return (
@ -118,9 +115,9 @@ class MainSideBar extends PureComponent<Props> {
<TopGradient />
<GrowScroll>
<Space of={70} />
<SideBarList title={t('app:sidebar.menu')}>
<SideBarList title={t('sidebar.menu')}>
<SideBarListItem
label={t('app:dashboard.title')}
label={t('dashboard.title')}
icon={IconPieChart}
iconActiveColor="wallet"
onClick={this.handleClickDashboard}
@ -128,28 +125,28 @@ class MainSideBar extends PureComponent<Props> {
hasNotif={updateStatus === 'downloaded'}
/>
<SideBarListItem
label={t('app:send.title')}
label={t('send.title')}
icon={IconSend}
iconActiveColor="wallet"
onClick={this.handleOpenSendModal}
disabled={accounts.length === 0}
/>
<SideBarListItem
label={t('app:receive.title')}
label={t('receive.title')}
icon={IconReceive}
iconActiveColor="wallet"
onClick={this.handleOpenReceiveModal}
disabled={accounts.length === 0}
/>
<SideBarListItem
label={t('app:sidebar.manager')}
label={t('sidebar.manager')}
icon={IconManager}
iconActiveColor="wallet"
onClick={this.handleClickManager}
isActive={pathname === '/manager'}
/>
<SideBarListItem
label={t('app:sidebar.exchange')}
label={t('sidebar.exchange')}
icon={IconExchange}
iconActiveColor="wallet"
onClick={this.handleClickExchange}
@ -158,7 +155,7 @@ class MainSideBar extends PureComponent<Props> {
{developerMode && (
<KeyboardContent sequence="DEVTOOLS">
<SideBarListItem
label={t('app:sidebar.developer')}
label={t('sidebar.developer')}
icon={IconDev}
iconActiveColor="wallet"
onClick={this.handleClickDev}
@ -169,7 +166,7 @@ class MainSideBar extends PureComponent<Props> {
</SideBarList>
<Space of={40} />
<SideBarList
title={t('app:sidebar.accounts', { count: accounts.length })}
title={t('sidebar.accounts', { count: accounts.length })}
titleRight={addAccountButton}
emptyState={this.ADD_ACCOUNT_EMPTY_STATE}
>

12
src/components/ManagerPage/AppsList.js

@ -214,7 +214,7 @@ class AppsList extends PureComponent<Props, State> {
</ModalTitle>
<ModalContent>
<Text ff="Museo Sans|Regular" fontSize={6} color="dark">
{t(`app:manager.apps.${mode}`, { app })}
{t(`manager.apps.${mode}`, { app })}
</Text>
<Box mt={6}>
<Progress style={{ width: '100%' }} infinite />
@ -256,7 +256,7 @@ class AppsList extends PureComponent<Props, State> {
</ModalContent>
<ModalFooter horizontal justifyContent="flex-end" style={{ width: '100%' }}>
<Button primary onClick={this.handleCloseModal}>
{t('app:common.close')}
{t('common.close')}
</Button>
</ModalFooter>
</Fragment>
@ -275,7 +275,7 @@ class AppsList extends PureComponent<Props, State> {
style={{ maxWidth: 350 }}
>
{t(
`app:manager.apps.${
`manager.apps.${
mode === 'installing' ? 'installSuccess' : 'uninstallSuccess'
}`,
{ app },
@ -284,7 +284,7 @@ class AppsList extends PureComponent<Props, State> {
</ModalContent>
<ModalFooter horizontal justifyContent="flex-end" style={{ width: '100%' }}>
<Button primary onClick={this.handleCloseModal}>
{t('app:common.close')}
{t('common.close')}
</Button>
</ModalFooter>
</Fragment>
@ -342,11 +342,11 @@ class AppsList extends PureComponent<Props, State> {
<Box flow={6}>
<Box>
<Box mb={4} color="dark" ff="Museo Sans" fontSize={5} flow={2} horizontal align="center">
<span style={{ lineHeight: 1 }}>{t('app:manager.apps.all')}</span>
<span style={{ lineHeight: 1 }}>{t('manager.apps.all')}</span>
<Tooltip
render={() => (
<Box ff="Open Sans|SemiBold" fontSize={2}>
{t('app:manager.apps.help')}
{t('manager.apps.help')}
</Box>
)}
>

6
src/components/ManagerPage/Dashboard.js

@ -27,14 +27,14 @@ const Dashboard = ({ device, deviceInfo, t, handleHelpRequest }: Props) => (
<TrackPage category="Manager" name="Dashboard" />
<Box>
<Text ff="Museo Sans|Regular" fontSize={7} color="dark">
{t('app:manager.title')}
{t('manager.title')}
</Text>
<Box horizontal>
<Text ff="Museo Sans|Light" fontSize={5}>
{t('app:manager.subtitle')}
{t('manager.subtitle')}
</Text>
<HelpLink onClick={handleHelpRequest}>
<div style={{ textDecoration: 'underline' }}>{t('app:common.needHelp')}</div>
<div style={{ textDecoration: 'underline' }}>{t('common.needHelp')}</div>
<IconExternalLink size={14} />
</HelpLink>
</Box>

8
src/components/ManagerPage/FirmwareUpdate.js

@ -136,17 +136,17 @@ class FirmwareUpdate extends PureComponent<Props, State> {
<Box horizontal align="center">
<Text ff="Open Sans|SemiBold" fontSize={4} color="dark">
{device.product === 'Blue'
? t('app:manager.firmware.titleBlue')
: t('app:manager.firmware.titleNano')}
? t('manager.firmware.titleBlue')
: t('manager.firmware.titleNano')}
</Text>
<Box color="wallet" ml={2}>
<Tooltip render={() => t('app:manager.yourDeviceIsGenuine')}>
<Tooltip render={() => t('manager.yourDeviceIsGenuine')}>
<CheckFull size={13} color="wallet" />
</Tooltip>
</Box>
</Box>
<Text ff="Open Sans|SemiBold" fontSize={2}>
{t('app:manager.firmware.installed', {
{t('manager.firmware.installed', {
version: deviceInfo.fullVersion,
})}
</Text>

2
src/components/ManagerPage/ManagerApp.js

@ -74,7 +74,7 @@ function ManagerApp({ name, version, icon, onInstall, onUninstall, t }: Props) {
appVersion: version,
}}
>
{t('app:manager.apps.install')}
{t('manager.apps.install')}
</Button>
) : null}
<Button

4
src/components/ManagerPage/ManagerGenuineCheck.js

@ -31,10 +31,10 @@ class ManagerGenuineCheck extends PureComponent<Props> {
style={{ marginBottom: 30, maxWidth: 362, width: '100%' }}
/>
<Text ff="Museo Sans|Regular" fontSize={7} color="dark" style={{ marginBottom: 10 }}>
{t('app:manager.device.title')}
{t('manager.device.title')}
</Text>
<Text ff="Museo Sans|Light" fontSize={5} color="grey" align="center">
{t('app:manager.device.desc')}
{t('manager.device.desc')}
</Text>
</Box>
<Space of={40} />

6
src/components/ManagerPage/PlugYourDevice.js

@ -22,12 +22,12 @@ function PlugYourDevice(props: Props) {
<Box align="center" style={{ width: 365 }}>
<Box mb={5}>hey</Box>
<Box textAlign="center" mb={1} ff="Museo Sans|Regular" color="dark" fontSize={6}>
{t('app:manager.device.title')}
{t('manager.device.title')}
</Box>
<Box textAlign="center" mb={5} ff="Open Sans|Regular" color="smoke" fontSize={4}>
{t('app:manager.device.desc')}
{t('manager.device.desc')}
</Box>
<Button primary>{t('app:manager.device.cta')}</Button>
<Button primary>{t('manager.device.cta')}</Button>
</Box>
</Card>
)

4
src/components/ManagerPage/UpdateFirmwareButton.js

@ -23,7 +23,7 @@ const UpdateFirmwareButton = ({ t, firmware, onClick }: Props) =>
firmware ? (
<Fragment>
<Text ff="Open Sans|Regular" fontSize={4} style={{ marginLeft: 'auto', marginRight: 15 }}>
{t('app:manager.firmware.latest', { version: getCleanVersion(firmware.name) })}
{t('manager.firmware.latest', { version: getCleanVersion(firmware.name) })}
</Text>
<Button
primary
@ -33,7 +33,7 @@ const UpdateFirmwareButton = ({ t, firmware, onClick }: Props) =>
firmwareName: firmware.name,
}}
>
{t('app:manager.firmware.update')}
{t('manager.firmware.update')}
</Button>
</Fragment>
) : null

4
src/components/Onboarding/OnboardingFooter.js

@ -24,7 +24,7 @@ const OnboardingFooter = ({
}: Props) => (
<OnboardingFooterWrapper {...props}>
<Button outlineGrey onClick={() => prevStep()}>
{t('app:common.back')}
{t('common.back')}
</Button>
<Button
data-e2e="continue_button"
@ -33,7 +33,7 @@ const OnboardingFooter = ({
onClick={() => nextStep()}
ml="auto"
>
{t('app:common.continue')}
{t('common.continue')}
</Button>
</OnboardingFooterWrapper>
)

22
src/components/Onboarding/steps/Analytics.js

@ -70,14 +70,14 @@ class Analytics extends PureComponent<StepProps, State> {
deviceType={onboarding.isLedgerNano ? 'Nano S' : 'Blue'}
/>
<StepContainerInner>
<Title data-e2e="onboarding_title">{t('app:onboarding.analytics.title')}</Title>
<Description>{t('app:onboarding.analytics.desc')}</Description>
<Title data-e2e="onboarding_title">{t('onboarding.analytics.title')}</Title>
<Description>{t('onboarding.analytics.desc')}</Description>
<Box mt={5}>
<Container>
<Box>
<Box horizontal mb={1}>
<AnalyticsTitle data-e2e="analytics_techData">
{t('app:onboarding.analytics.technicalData.title')}
{t('onboarding.analytics.technicalData.title')}
</AnalyticsTitle>
<LearnMoreWrapper>
<FakeLink
@ -88,14 +88,14 @@ class Analytics extends PureComponent<StepProps, State> {
onClick={this.handleTechnicalDataModal}
data-e2e="analytics_techData_Link"
>
{t('app:common.learnMore')}
{t('common.learnMore')}
</FakeLink>
</LearnMoreWrapper>
</Box>
<TechnicalData />
<AnalyticsText>{t('app:onboarding.analytics.technicalData.desc')}</AnalyticsText>
<AnalyticsText>{t('onboarding.analytics.technicalData.desc')}</AnalyticsText>
<MandatoryText>
{t('app:onboarding.analytics.technicalData.mandatoryText')}
{t('onboarding.analytics.technicalData.mandatoryText')}
</MandatoryText>
</Box>
<Box justifyContent="center">
@ -106,7 +106,7 @@ class Analytics extends PureComponent<StepProps, State> {
<Box>
<Box horizontal mb={1}>
<AnalyticsTitle data-e2e="analytics_shareAnalytics">
{t('app:onboarding.analytics.shareAnalytics.title')}
{t('onboarding.analytics.shareAnalytics.title')}
</AnalyticsTitle>
<LearnMoreWrapper>
<FakeLink
@ -117,12 +117,12 @@ class Analytics extends PureComponent<StepProps, State> {
onClick={this.handleShareAnalyticsModal}
data-e2e="analytics_shareAnalytics_Link"
>
{t('app:common.learnMore')}
{t('common.learnMore')}
</FakeLink>
</LearnMoreWrapper>
<ShareAnalytics />
</Box>
<AnalyticsText>{t('app:onboarding.analytics.shareAnalytics.desc')}</AnalyticsText>
<AnalyticsText>{t('onboarding.analytics.shareAnalytics.desc')}</AnalyticsText>
</Box>
<Box justifyContent="center">
<Track
@ -140,10 +140,10 @@ class Analytics extends PureComponent<StepProps, State> {
<Box>
<Box mb={1}>
<AnalyticsTitle data-e2e="analytics_reportBugs">
{t('app:onboarding.analytics.sentryLogs.title')}
{t('onboarding.analytics.sentryLogs.title')}
</AnalyticsTitle>
</Box>
<AnalyticsText>{t('app:onboarding.analytics.sentryLogs.desc')}</AnalyticsText>
<AnalyticsText>{t('onboarding.analytics.sentryLogs.desc')}</AnalyticsText>
</Box>
<Box justifyContent="center">
<Track

6
src/components/Onboarding/steps/Finish.js

@ -103,12 +103,12 @@ export default class Finish extends Component<StepProps, *> {
</Box>
<Box pt={5} align="center">
<Title data-e2e="finish_title">{t('app:onboarding.finish.title')}</Title>
<Description>{t('app:onboarding.finish.desc')}</Description>
<Title data-e2e="finish_title">{t('onboarding.finish.title')}</Title>
<Description>{t('onboarding.finish.desc')}</Description>
</Box>
<Box p={5}>
<Button primary onClick={() => finish()} data-e2e="continue_button">
{t('app:onboarding.finish.openAppButton')}
{t('onboarding.finish.openAppButton')}
</Button>
</Box>
<Box horizontal mt={3} flow={5} color="grey">

18
src/components/Onboarding/steps/GenuineCheck/GenuineCheckErrorPage.js

@ -40,23 +40,21 @@ class GenuineCheckErrorPage extends PureComponent<Props, *> {
{onboarding.genuine.isGenuineFail ? (
<Fragment>
{this.trackErrorPage('Not Genuine')}
<Title>{t('app:onboarding.genuineCheck.errorPage.title.isGenuineFail')}</Title>
<Description>
{t('app:onboarding.genuineCheck.errorPage.desc.isGenuineFail')}
</Description>
<Title>{t('onboarding.genuineCheck.errorPage.title.isGenuineFail')}</Title>
<Description>{t('onboarding.genuineCheck.errorPage.desc.isGenuineFail')}</Description>
</Fragment>
) : !onboarding.genuine.pinStepPass ? (
<Fragment>
{this.trackErrorPage('PIN Step')}
<Title>{t('app:onboarding.genuineCheck.errorPage.title.pinFailed')}</Title>
<Description>{t('app:onboarding.genuineCheck.errorPage.desc.pinFailed')}</Description>
<Title>{t('onboarding.genuineCheck.errorPage.title.pinFailed')}</Title>
<Description>{t('onboarding.genuineCheck.errorPage.desc.pinFailed')}</Description>
</Fragment>
) : (
<Fragment>
{this.trackErrorPage('Recovery Phase Step')}
<Title>{t('app:onboarding.genuineCheck.errorPage.title.recoveryPhraseFailed')}</Title>
<Title>{t('onboarding.genuineCheck.errorPage.title.recoveryPhraseFailed')}</Title>
<Description>
{t('app:onboarding.genuineCheck.errorPage.desc.recoveryPhraseFailed')}
{t('onboarding.genuineCheck.errorPage.desc.recoveryPhraseFailed')}
</Description>
</Fragment>
)}
@ -80,12 +78,12 @@ class GenuineCheckErrorPage extends PureComponent<Props, *> {
</Box>
<OnboardingFooterWrapper>
<Button outlineGrey onClick={() => redoGenuineCheck()}>
{t('app:common.back')}
{t('common.back')}
</Button>
<ExternalLinkButton
danger
ml="auto"
label={t('app:onboarding.genuineCheck.buttons.contactSupport')}
label={t('onboarding.genuineCheck.buttons.contactSupport')}
url={urls.contactSupport}
/>
</OnboardingFooterWrapper>

8
src/components/Onboarding/steps/GenuineCheck/GenuineCheckUnavailable.js

@ -27,7 +27,7 @@ export function GenuineCheckUnavailableFooter({
return (
<OnboardingFooterWrapper>
<Button outlineGrey onClick={() => prevStep()}>
{t('app:common.back')}
{t('common.back')}
</Button>
<Box horizontal ml="auto">
<Button
@ -36,10 +36,10 @@ export function GenuineCheckUnavailableFooter({
onClick={() => nextStep()}
mx={2}
>
{t('app:common.skipThisStep')}
{t('common.skipThisStep')}
</Button>
<Button onClick={nextStep} disabled primary>
{t('app:common.continue')}
{t('common.continue')}
</Button>
</Box>
</OnboardingFooterWrapper>
@ -81,7 +81,7 @@ export function GenuineCheckUnavailableMessage({
})
}}
>
{t('app:common.retry')}
{t('common.retry')}
</FakeLink>
</Box>
)

20
src/components/Onboarding/steps/GenuineCheck/index.js

@ -59,12 +59,12 @@ class GenuineCheck extends PureComponent<StepProps, State> {
const { t } = this.props
return [
{
label: t('app:common.labelYes'),
label: t('common.labelYes'),
key: 'yes',
pass: true,
},
{
label: t('app:common.labelNo'),
label: t('common.labelNo'),
key: 'no',
pass: false,
},
@ -174,18 +174,18 @@ class GenuineCheck extends PureComponent<StepProps, State> {
deviceType={onboarding.isLedgerNano ? 'Nano S' : 'Blue'}
/>
<StepContainerInner>
<Title>{t('app:onboarding.genuineCheck.title')}</Title>
<Title>{t('onboarding.genuineCheck.title')}</Title>
{onboarding.flowType === 'restoreDevice' ? (
<Description>{t('app:onboarding.genuineCheck.descRestore')}</Description>
<Description>{t('onboarding.genuineCheck.descRestore')}</Description>
) : (
<Description>{t('app:onboarding.genuineCheck.descGeneric')}</Description>
<Description>{t('onboarding.genuineCheck.descGeneric')}</Description>
)}
<Box mt={5}>
<GenuineCheckCardWrapper>
<Box justify="center">
<Box horizontal>
<IconOptionRow>{'1.'}</IconOptionRow>
<CardTitle>{t('app:onboarding.genuineCheck.step1.title')}</CardTitle>
<CardTitle>{t('onboarding.genuineCheck.step1.title')}</CardTitle>
</Box>
</Box>
<Box justify="center">
@ -204,7 +204,7 @@ class GenuineCheck extends PureComponent<StepProps, State> {
<IconOptionRow color={!genuine.pinStepPass ? 'grey' : 'wallet'}>
{'2.'}
</IconOptionRow>
<CardTitle>{t('app:onboarding.genuineCheck.step2.title')}</CardTitle>
<CardTitle>{t('onboarding.genuineCheck.step2.title')}</CardTitle>
</Box>
</Box>
<Box justify="center">
@ -228,7 +228,7 @@ class GenuineCheck extends PureComponent<StepProps, State> {
<IconOptionRow color={!genuine.recoveryStepPass ? 'grey' : 'wallet'}>
{'3.'}
</IconOptionRow>
<CardTitle>{t('app:onboarding.genuineCheck.step3.title')}</CardTitle>
<CardTitle>{t('onboarding.genuineCheck.step3.title')}</CardTitle>
</Box>
</Box>
{genuine.recoveryStepPass && (
@ -237,7 +237,7 @@ class GenuineCheck extends PureComponent<StepProps, State> {
<Box horizontal align="center" flow={1} color={colors.wallet}>
<IconCheck size={16} />
<Box ff="Open Sans|SemiBold" fontSize={4}>
{t('app:onboarding.genuineCheck.isGenuinePassed')}
{t('onboarding.genuineCheck.isGenuinePassed')}
</Box>
</Box>
) : genuine.genuineCheckUnavailable ? (
@ -250,7 +250,7 @@ class GenuineCheck extends PureComponent<StepProps, State> {
disabled={!genuine.recoveryStepPass}
onClick={this.handleOpenGenuineCheckModal}
>
{t('app:onboarding.genuineCheck.buttons.genuineCheck')}
{t('onboarding.genuineCheck.buttons.genuineCheck')}
</Button>
)}
</Box>

10
src/components/Onboarding/steps/Init.js

@ -30,7 +30,7 @@ class Init extends PureComponent<StepProps, *> {
{
key: 'newDevice',
icon: <IconPlus size={20} />,
title: t('app:onboarding.init.newDevice.title'),
title: t('onboarding.init.newDevice.title'),
onClick: () => {
jumpStep('selectDevice')
flowType('newDevice')
@ -39,7 +39,7 @@ class Init extends PureComponent<StepProps, *> {
{
key: 'restoreDevice',
icon: <IconRecover size={20} />,
title: t('app:onboarding.init.restoreDevice.title'),
title: t('onboarding.init.restoreDevice.title'),
onClick: () => {
jumpStep('selectDevice')
flowType('restoreDevice')
@ -48,7 +48,7 @@ class Init extends PureComponent<StepProps, *> {
{
key: 'initializedDevice',
icon: <IconCheck size={20} />,
title: t('app:onboarding.init.initializedDevice.title'),
title: t('onboarding.init.initializedDevice.title'),
onClick: () => {
jumpStep('selectDevice')
flowType('initializedDevice')
@ -57,7 +57,7 @@ class Init extends PureComponent<StepProps, *> {
{
key: 'noDevice',
icon: <IconExternalLink size={20} />,
title: t('app:onboarding.noDevice.title'),
title: t('onboarding.noDevice.title'),
onClick: () => {
jumpStep('noDevice')
flowType('noDevice')
@ -77,7 +77,7 @@ class Init extends PureComponent<StepProps, *> {
}
/>
<Box m={5} style={{ maxWidth: 480 }}>
<Title>{t('app:onboarding.init.title')}</Title>
<Title>{t('onboarding.init.title')}</Title>
</Box>
<Box pt={4} flow={4}>
{optionCards.map(card => <OptionFlowCard key={card.key} card={card} />)}

10
src/components/Onboarding/steps/NoDevice.js

@ -26,7 +26,7 @@ class NoDevice extends PureComponent<StepProps, *> {
{
key: 'buyNew',
icon: <IconCart size={20} />,
title: t('app:onboarding.noDevice.buyNew.title'),
title: t('onboarding.noDevice.buyNew.title'),
onClick: () => {
openURL(urls.noDeviceBuyNew)
},
@ -34,7 +34,7 @@ class NoDevice extends PureComponent<StepProps, *> {
{
key: 'trackOrder',
icon: <IconTruck size={20} />,
title: t('app:onboarding.noDevice.trackOrder.title'),
title: t('onboarding.noDevice.trackOrder.title'),
onClick: () => {
openURL(urls.noDeviceTrackOrder)
},
@ -42,7 +42,7 @@ class NoDevice extends PureComponent<StepProps, *> {
{
key: 'learnMore',
icon: <IconInfoCircle size={20} />,
title: t('app:onboarding.noDevice.learnMore.title'),
title: t('onboarding.noDevice.learnMore.title'),
onClick: () => {
openURL(urls.noDeviceLearnMore)
},
@ -68,7 +68,7 @@ class NoDevice extends PureComponent<StepProps, *> {
}
/>
<Box m={5} style={{ maxWidth: 480 }}>
<Title>{t('app:onboarding.noDevice.title')}</Title>
<Title>{t('onboarding.noDevice.title')}</Title>
</Box>
<Box pt={4} flow={4}>
{optionCards.map(card => <OptionFlowCard key={card.key} card={card} />)}
@ -77,7 +77,7 @@ class NoDevice extends PureComponent<StepProps, *> {
</GrowScroll>
<OnboardingFooterWrapper>
<Button outlineGrey onClick={() => prevStep()} mr="auto">
{t('app:common.back')}
{t('common.back')}
</Button>
</OnboardingFooterWrapper>
</Box>

6
src/components/Onboarding/steps/SelectDevice.js

@ -41,7 +41,7 @@ class SelectDevice extends PureComponent<StepProps, {}> {
<TrackPage category="Onboarding" name="Select Device" flowType={onboarding.flowType} />
<StepContainerInner>
<Box mb={5}>
<Title>{t('app:onboarding.selectDevice.title')}</Title>
<Title>{t('onboarding.selectDevice.title')}</Title>
</Box>
<Box pt={4}>
<Inner>
@ -53,7 +53,7 @@ class SelectDevice extends PureComponent<StepProps, {}> {
<DeviceIcon>
<img alt="" src={i('ledger-nano-onb.svg')} />
</DeviceIcon>
<BlockTitle>{t('app:onboarding.selectDevice.ledgerNanoCard.title')}</BlockTitle>
<BlockTitle>{t('onboarding.selectDevice.ledgerNanoCard.title')}</BlockTitle>
</DeviceContainer>
<DeviceContainer
isActive={!onboarding.isLedgerNano && onboarding.isLedgerNano !== null}
@ -63,7 +63,7 @@ class SelectDevice extends PureComponent<StepProps, {}> {
<DeviceIcon>
<img alt="" src={i('ledger-blue-onb.svg')} />
</DeviceIcon>
<BlockTitle>{t('app:onboarding.selectDevice.ledgerBlueCard.title')}</BlockTitle>
<BlockTitle>{t('onboarding.selectDevice.ledgerBlueCard.title')}</BlockTitle>
</DeviceContainer>
</Inner>
</Box>

12
src/components/Onboarding/steps/SelectPIN/SelectPINblue.js

@ -25,14 +25,14 @@ class SelectPIN extends PureComponent<Props, *> {
{
key: 'step1',
icon: <IconOptionRow>{'1.'}</IconOptionRow>,
desc: t('app:onboarding.selectPIN.initialize.instructions.blue.step1'),
desc: t('onboarding.selectPIN.initialize.instructions.blue.step1'),
},
{
key: 'step2',
icon: <IconOptionRow>{'2.'}</IconOptionRow>,
desc: (
<Box style={{ display: 'block' }}>
<Trans i18nKey="app:onboarding.selectPIN.initialize.instructions.blue.step2">
<Trans i18nKey="onboarding.selectPIN.initialize.instructions.blue.step2">
{'Tap on'}
<Text ff="Open Sans|SemiBold" color="dark">
{'Configure as new device'}
@ -44,7 +44,7 @@ class SelectPIN extends PureComponent<Props, *> {
{
key: 'step3',
icon: <IconOptionRow>{'3.'}</IconOptionRow>,
desc: t('app:onboarding.selectPIN.initialize.instructions.blue.step3'),
desc: t('onboarding.selectPIN.initialize.instructions.blue.step3'),
},
]
@ -52,17 +52,17 @@ class SelectPIN extends PureComponent<Props, *> {
{
key: 'note1',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.selectPIN.disclaimer.note1'),
desc: t('onboarding.selectPIN.disclaimer.note1'),
},
{
key: 'note2',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.selectPIN.disclaimer.note2'),
desc: t('onboarding.selectPIN.disclaimer.note2'),
},
{
key: 'note3',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.selectPIN.disclaimer.note3'),
desc: t('onboarding.selectPIN.disclaimer.note3'),
},
]

14
src/components/Onboarding/steps/SelectPIN/SelectPINnano.js

@ -25,19 +25,19 @@ class SelectPINnano extends PureComponent<Props, *> {
{
key: 'step1',
icon: <IconOptionRow>{'1.'}</IconOptionRow>,
desc: t('app:onboarding.selectPIN.initialize.instructions.nano.step1'),
desc: t('onboarding.selectPIN.initialize.instructions.nano.step1'),
},
{
key: 'step2',
icon: <IconOptionRow>{'2.'}</IconOptionRow>,
desc: t('app:onboarding.selectPIN.initialize.instructions.nano.step2'),
desc: t('onboarding.selectPIN.initialize.instructions.nano.step2'),
},
{
key: 'step3',
icon: <IconOptionRow>{'3.'}</IconOptionRow>,
desc: (
<Box style={{ display: 'block' }}>
<Trans i18nKey="app:onboarding.selectPIN.initialize.instructions.nano.step3">
<Trans i18nKey="onboarding.selectPIN.initialize.instructions.nano.step3">
{'Press the right button to select'}
<Text ff="Open Sans|SemiBold" color="dark">
{'Configure as new device'}
@ -49,24 +49,24 @@ class SelectPINnano extends PureComponent<Props, *> {
{
key: 'step4',
icon: <IconOptionRow>{'4.'}</IconOptionRow>,
desc: t('app:onboarding.selectPIN.initialize.instructions.nano.step4'),
desc: t('onboarding.selectPIN.initialize.instructions.nano.step4'),
},
]
const disclaimerNotes = [
{
key: 'note1',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.selectPIN.disclaimer.note1'),
desc: t('onboarding.selectPIN.disclaimer.note1'),
},
{
key: 'note2',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.selectPIN.disclaimer.note2'),
desc: t('onboarding.selectPIN.disclaimer.note2'),
},
{
key: 'note3',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.selectPIN.disclaimer.note3'),
desc: t('onboarding.selectPIN.disclaimer.note3'),
},
]

12
src/components/Onboarding/steps/SelectPIN/SelectPINrestoreBlue.js

@ -25,14 +25,14 @@ class SelectPINrestoreBlue extends PureComponent<Props, *> {
{
key: 'step1',
icon: <IconOptionRow>{'1.'}</IconOptionRow>,
desc: t('app:onboarding.selectPIN.restore.instructions.blue.step1'),
desc: t('onboarding.selectPIN.restore.instructions.blue.step1'),
},
{
key: 'step2',
icon: <IconOptionRow>{'2.'}</IconOptionRow>,
desc: (
<Box style={{ display: 'block' }}>
<Trans i18nKey="app:onboarding.selectPIN.restore.instructions.blue.step2">
<Trans i18nKey="onboarding.selectPIN.restore.instructions.blue.step2">
{'Tap on'}
<Text ff="Open Sans|SemiBold" color="dark">
{'Restore configuration'}
@ -44,7 +44,7 @@ class SelectPINrestoreBlue extends PureComponent<Props, *> {
{
key: 'step3',
icon: <IconOptionRow>{'3.'}</IconOptionRow>,
desc: t('app:onboarding.selectPIN.restore.instructions.blue.step3'),
desc: t('onboarding.selectPIN.restore.instructions.blue.step3'),
},
]
@ -52,17 +52,17 @@ class SelectPINrestoreBlue extends PureComponent<Props, *> {
{
key: 'note1',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.selectPIN.disclaimer.note1'),
desc: t('onboarding.selectPIN.disclaimer.note1'),
},
{
key: 'note2',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.selectPIN.disclaimer.note2'),
desc: t('onboarding.selectPIN.disclaimer.note2'),
},
{
key: 'note3',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.selectPIN.disclaimer.note3'),
desc: t('onboarding.selectPIN.disclaimer.note3'),
},
]

14
src/components/Onboarding/steps/SelectPIN/SelectPINrestoreNano.js

@ -25,19 +25,19 @@ class SelectPINrestoreNano extends PureComponent<Props, *> {
{
key: 'step1',
icon: <IconOptionRow>{'1.'}</IconOptionRow>,
desc: t('app:onboarding.selectPIN.restore.instructions.nano.step1'),
desc: t('onboarding.selectPIN.restore.instructions.nano.step1'),
},
{
key: 'step2',
icon: <IconOptionRow>{'2.'}</IconOptionRow>,
desc: t('app:onboarding.selectPIN.restore.instructions.nano.step2'),
desc: t('onboarding.selectPIN.restore.instructions.nano.step2'),
},
{
key: 'step3',
icon: <IconOptionRow>{'3.'}</IconOptionRow>,
desc: (
<Box style={{ display: 'block' }}>
<Trans i18nKey="app:onboarding.selectPIN.restore.instructions.nano.step3">
<Trans i18nKey="onboarding.selectPIN.restore.instructions.nano.step3">
{'Press the left button to cancel'}
<Text ff="Open Sans|SemiBold" color="dark">
{'Initialize as new device?'}
@ -53,24 +53,24 @@ class SelectPINrestoreNano extends PureComponent<Props, *> {
{
key: 'step4',
icon: <IconOptionRow>{'4.'}</IconOptionRow>,
desc: t('app:onboarding.selectPIN.restore.instructions.nano.step4'),
desc: t('onboarding.selectPIN.restore.instructions.nano.step4'),
},
]
const disclaimerNotes = [
{
key: 'note1',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.selectPIN.disclaimer.note1'),
desc: t('onboarding.selectPIN.disclaimer.note1'),
},
{
key: 'note2',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.selectPIN.disclaimer.note2'),
desc: t('onboarding.selectPIN.disclaimer.note2'),
},
{
key: 'note3',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.selectPIN.disclaimer.note3'),
desc: t('onboarding.selectPIN.disclaimer.note3'),
},
]

4
src/components/Onboarding/steps/SelectPIN/index.js

@ -29,14 +29,14 @@ export default (props: StepProps) => {
/>
{onboarding.flowType === 'restoreDevice' ? (
<Box grow alignItems="center">
<Title>{t('app:onboarding.selectPIN.restore.title')}</Title>
<Title>{t('onboarding.selectPIN.restore.title')}</Title>
<Box align="center" mt={7}>
{onboarding.isLedgerNano ? <SelectPINrestoreNano /> : <SelectPINrestoreBlue />}
</Box>
</Box>
) : (
<Box grow alignItems="center">
<Title>{t('app:onboarding.selectPIN.initialize.title')}</Title>
<Title>{t('onboarding.selectPIN.initialize.title')}</Title>
<Box align="center" mt={7}>
{onboarding.isLedgerNano ? <SelectPINnano /> : <SelectPINblue />}
</Box>

16
src/components/Onboarding/steps/SetPassword.js

@ -85,17 +85,17 @@ class SetPassword extends PureComponent<Props, State> {
{
key: 'note1',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.setPassword.disclaimer.note1'),
desc: t('onboarding.setPassword.disclaimer.note1'),
},
{
key: 'note2',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.setPassword.disclaimer.note2'),
desc: t('onboarding.setPassword.disclaimer.note2'),
},
{
key: 'note3',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.setPassword.disclaimer.note3'),
desc: t('onboarding.setPassword.disclaimer.note3'),
},
]
@ -110,9 +110,9 @@ class SetPassword extends PureComponent<Props, State> {
<StepContainerInner>
<Fragment>
<Box alignItems="center">
<Title>{t('app:onboarding.setPassword.title')}</Title>
<Title>{t('onboarding.setPassword.title')}</Title>
<Description style={{ maxWidth: 620 }}>
{t('app:onboarding.setPassword.desc')}
{t('onboarding.setPassword.desc')}
</Description>
</Box>
<Box align="center" mt={2}>
@ -134,7 +134,7 @@ class SetPassword extends PureComponent<Props, State> {
<OnboardingFooterWrapper>
<Button outlineGrey onClick={() => prevStep()}>
{t('app:common.back')}
{t('common.back')}
</Button>
<Box horizontal ml="auto">
<Button
@ -143,14 +143,14 @@ class SetPassword extends PureComponent<Props, State> {
disabled={false}
mx={2}
>
{t('app:common.skipThisStep')}
{t('common.skipThisStep')}
</Button>
<Button
onClick={this.handleSave}
disabled={!this.isValid() || !newPassword.length || !confirmPassword.length}
primary
>
{t('app:common.continue')}
{t('common.continue')}
</Button>
</Box>
</OnboardingFooterWrapper>

4
src/components/Onboarding/steps/Start.js

@ -21,10 +21,10 @@ export default (props: StepProps) => {
icon={<img src={i('ledgerlive-logo.svg')} alt="" width={50} height={50} />}
/>
<Box my={5}>
<Title>{t('app:onboarding.start.title')}</Title>
<Title>{t('onboarding.start.title')}</Title>
</Box>
<Button primary onClick={() => jumpStep('init')}>
{t('app:onboarding.start.startBtn')}
{t('onboarding.start.startBtn')}
</Button>
</Box>
</Box>

18
src/components/Onboarding/steps/WriteSeed/WriteSeedBlue.js

@ -31,14 +31,14 @@ class WriteSeedBlue extends PureComponent<Props, *> {
{
key: 'step1',
icon: <IconOptionRow>{'1.'}</IconOptionRow>,
desc: t('app:onboarding.writeSeed.initialize.blue.step1'),
desc: t('onboarding.writeSeed.initialize.blue.step1'),
},
{
key: 'step2',
icon: <IconOptionRow>{'2.'}</IconOptionRow>,
desc: (
<Box style={{ display: 'block' }}>
<Trans i18nKey="app:onboarding.writeSeed.initialize.blue.step2">
<Trans i18nKey="onboarding.writeSeed.initialize.blue.step2">
{'Tap'}
<Text ff="Open Sans|SemiBold" color="dark">
{'Next'}
@ -55,37 +55,37 @@ class WriteSeedBlue extends PureComponent<Props, *> {
{
key: 'step3',
icon: <IconOptionRow>{'3.'}</IconOptionRow>,
desc: t('app:onboarding.writeSeed.initialize.blue.step3'),
desc: t('onboarding.writeSeed.initialize.blue.step3'),
},
]
const disclaimerNotes = [
{
key: 'note1',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.writeSeed.disclaimer.note1'),
desc: t('onboarding.writeSeed.disclaimer.note1'),
},
{
key: 'note2',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.writeSeed.disclaimer.note2'),
desc: t('onboarding.writeSeed.disclaimer.note2'),
},
{
key: 'note3',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.writeSeed.disclaimer.note3'),
desc: t('onboarding.writeSeed.disclaimer.note3'),
},
{
key: 'note4',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.writeSeed.disclaimer.note4'),
desc: t('onboarding.writeSeed.disclaimer.note4'),
},
]
return (
<Fragment>
<Box mb={3}>
<Title>{t('app:onboarding.writeSeed.initialize.title')}</Title>
<Description>{t('app:onboarding.writeSeed.initialize.desc')}</Description>
<Title>{t('onboarding.writeSeed.initialize.title')}</Title>
<Description>{t('onboarding.writeSeed.initialize.desc')}</Description>
</Box>
<Box align="center">
<Inner style={{ width: 760 }}>

18
src/components/Onboarding/steps/WriteSeed/WriteSeedNano.js

@ -33,7 +33,7 @@ class WriteSeedNano extends PureComponent<Props, *> {
icon: <IconOptionRow>{'1.'}</IconOptionRow>,
desc: (
<Box style={{ display: 'block' }}>
<Trans i18nKey="app:onboarding.writeSeed.initialize.nano.step1">
<Trans i18nKey="onboarding.writeSeed.initialize.nano.step1">
{'Copy the word displayed below'}
<Text ff="Open Sans|SemiBold" color="dark">
{'Word #1'}
@ -48,7 +48,7 @@ class WriteSeedNano extends PureComponent<Props, *> {
icon: <IconOptionRow>{'2.'}</IconOptionRow>,
desc: (
<Box style={{ display: 'block' }}>
<Trans i18nKey="app:onboarding.writeSeed.initialize.nano.step2">
<Trans i18nKey="onboarding.writeSeed.initialize.nano.step2">
{'Press the right button to display'}
<Text ff="Open Sans|SemiBold" color="dark">
{'Word #2'}
@ -61,37 +61,37 @@ class WriteSeedNano extends PureComponent<Props, *> {
{
key: 'step3',
icon: <IconOptionRow>{'3.'}</IconOptionRow>,
desc: t('app:onboarding.writeSeed.initialize.nano.step3'),
desc: t('onboarding.writeSeed.initialize.nano.step3'),
},
]
const disclaimerNotes = [
{
key: 'note1',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.writeSeed.disclaimer.note1'),
desc: t('onboarding.writeSeed.disclaimer.note1'),
},
{
key: 'note2',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.writeSeed.disclaimer.note2'),
desc: t('onboarding.writeSeed.disclaimer.note2'),
},
{
key: 'note3',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.writeSeed.disclaimer.note3'),
desc: t('onboarding.writeSeed.disclaimer.note3'),
},
{
key: 'note4',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.writeSeed.disclaimer.note4'),
desc: t('onboarding.writeSeed.disclaimer.note4'),
},
]
return (
<Fragment>
<Box mb={3}>
<Title>{t('app:onboarding.writeSeed.initialize.title')}</Title>
<Description>{t('app:onboarding.writeSeed.initialize.desc')}</Description>
<Title>{t('onboarding.writeSeed.initialize.title')}</Title>
<Description>{t('onboarding.writeSeed.initialize.desc')}</Description>
</Box>
<Box align="center" mt={3}>
<Inner style={{ width: 700 }}>

26
src/components/Onboarding/steps/WriteSeed/WriteSeedRestore.js

@ -34,14 +34,14 @@ class WriteSeedRestore extends PureComponent<Props, *> {
{
key: 'step1',
icon: <IconOptionRow>{'1.'}</IconOptionRow>,
desc: t('app:onboarding.writeSeed.restore.nano.step1'),
desc: t('onboarding.writeSeed.restore.nano.step1'),
},
{
key: 'step2',
icon: <IconOptionRow>{'2.'}</IconOptionRow>,
desc: (
<Box style={{ display: 'block' }}>
<Trans i18nKey="app:onboarding.writeSeed.restore.nano.step2">
<Trans i18nKey="onboarding.writeSeed.restore.nano.step2">
{'Select the first letters of'}
<Text ff="Open Sans|SemiBold" color="dark">
{'Word #1'}
@ -56,7 +56,7 @@ class WriteSeedRestore extends PureComponent<Props, *> {
icon: <IconOptionRow>{'3.'}</IconOptionRow>,
desc: (
<Box style={{ display: 'block' }}>
<Trans i18nKey="app:onboarding.writeSeed.restore.nano.step3">
<Trans i18nKey="onboarding.writeSeed.restore.nano.step3">
{'Select'}
<Text ff="Open Sans|SemiBold" color="dark">
{'Word #1'}
@ -69,54 +69,54 @@ class WriteSeedRestore extends PureComponent<Props, *> {
{
key: 'step4',
icon: <IconOptionRow>{'4.'}</IconOptionRow>,
desc: t('app:onboarding.writeSeed.restore.nano.step4'),
desc: t('onboarding.writeSeed.restore.nano.step4'),
},
]
const stepsBlue = [
{
key: 'step1',
icon: <IconOptionRow>{'1.'}</IconOptionRow>,
desc: t('app:onboarding.writeSeed.restore.blue.step1'),
desc: t('onboarding.writeSeed.restore.blue.step1'),
},
{
key: 'step2',
icon: <IconOptionRow>{'2.'}</IconOptionRow>,
desc: t('app:onboarding.writeSeed.restore.blue.step2'),
desc: t('onboarding.writeSeed.restore.blue.step2'),
},
{
key: 'step3',
icon: <IconOptionRow>{'3.'}</IconOptionRow>,
desc: t('app:onboarding.writeSeed.restore.blue.step3'),
desc: t('onboarding.writeSeed.restore.blue.step3'),
},
]
const disclaimerNotes = [
{
key: 'note1',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.writeSeed.disclaimer.note1'),
desc: t('onboarding.writeSeed.disclaimer.note1'),
},
{
key: 'note2',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.writeSeed.disclaimer.note2'),
desc: t('onboarding.writeSeed.disclaimer.note2'),
},
{
key: 'note3',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.writeSeed.disclaimer.note3'),
desc: t('onboarding.writeSeed.disclaimer.note3'),
},
{
key: 'note4',
icon: <IconChevronRight size={12} style={{ color: colors.smoke }} />,
desc: t('app:onboarding.writeSeed.disclaimer.note4'),
desc: t('onboarding.writeSeed.disclaimer.note4'),
},
]
return (
<Fragment>
<Box mb={3}>
<Title>{t('app:onboarding.writeSeed.restore.title')}</Title>
<Description>{t('app:onboarding.writeSeed.restore.desc')}</Description>
<Title>{t('onboarding.writeSeed.restore.title')}</Title>
<Description>{t('onboarding.writeSeed.restore.desc')}</Description>
</Box>
<Box align="center">
<Inner style={{ width: 760 }}>

2
src/components/OpenUserDataDirectoryBtn.js

@ -21,7 +21,7 @@ class OpenUserDataDirectoryBtn extends Component<{
const { t } = this.props
return (
<Button primary small onClick={this.handleOpenUserDataDirectory}>
{t('app:settings.openUserDataDirectory.btn')}
{t('settings.openUserDataDirectory.btn')}
</Button>
)
}

2
src/components/OperationsList/ConfirmationCheck.js

@ -59,7 +59,7 @@ class ConfirmationCheck extends PureComponent<{
renderTooltip = () => {
const { t, isConfirmed } = this.props
return t(isConfirmed ? 'app:operationDetails.confirmed' : 'app:operationDetails.notConfirmed')
return t(isConfirmed ? 'operationDetails.confirmed' : 'operationDetails.notConfirmed')
}
render() {

2
src/components/OperationsList/DateCell.js

@ -29,7 +29,7 @@ class DateCell extends PureComponent<Props> {
return (
<Cell>
<Box ff="Open Sans|SemiBold" fontSize={3} color="smoke">
{t(`app:operation.type.${operation.type}`)}
{t(`operation.type.${operation.type}`)}
</Box>
<OperationDate date={operation.date} />
</Cell>

4
src/components/OperationsList/index.js

@ -139,13 +139,13 @@ export class OperationsList extends PureComponent<Props, State> {
) : null}
{!groupedOperations.completed ? (
<ShowMore onClick={this.fetchMoreOperations}>
<span>{t('app:common.showMore')}</span>
<span>{t('common.showMore')}</span>
<IconAngleDown size={12} />
</ShowMore>
) : (
<Box p={6} align="center">
<Text ff="Open Sans" fontSize={3}>
{t('app:operationList.noMoreOperations')}
{t('operationList.noMoreOperations')}
</Text>
</Box>
)}

2
src/components/PillsDaysCount.js

@ -24,7 +24,7 @@ class PillsDaysCount extends PureComponent<Props> {
items={Object.keys(timeRangeDaysByKey).map((key: TimeRange) => ({
key,
value: timeRangeDaysByKey[key],
label: t(`app:time.${key}`),
label: t(`time.${key}`),
}))}
activeKey={selected}
onChange={onChange}

23
src/components/RenderError.js

@ -75,7 +75,7 @@ class RenderError extends PureComponent<
<img alt="" src={i('crash-screen.svg')} width={380} />
<Space of={40} />
<Box ff="Museo Sans|Regular" fontSize={7} color="dark">
{t('app:crash.oops')}
{t('crash.oops')}
</Box>
<Space of={15} />
<Box
@ -85,25 +85,20 @@ class RenderError extends PureComponent<
color="smoke"
fontSize={4}
>
{t('app:crash.uselessText')}
{t('crash.uselessText')}
</Box>
<Space of={30} />
<Box horizontal flow={2}>
<Button small primary onClick={this.handleRestart}>
{t('app:crash.restart')}
{t('crash.restart')}
</Button>
<ExportLogsBtn withoutAppData={withoutAppData} />
<ExternalLinkButton
small
primary
label={t('app:crash.support')}
url={urls.contactSupport}
/>
<ExternalLinkButton small primary label={t('crash.support')} url={urls.contactSupport} />
<Button small primary onClick={this.github}>
{t('app:crash.github')}
{t('crash.github')}
</Button>
<Button small danger onClick={this.handleOpenHardResetModal}>
{t('app:common.reset')}
{t('common.reset')}
</Button>
</Box>
<ConfirmModal
@ -114,9 +109,9 @@ class RenderError extends PureComponent<
onClose={this.handleCloseHardResetModal}
onReject={this.handleCloseHardResetModal}
onConfirm={this.handleHardReset}
confirmText={t('app:common.reset')}
title={t('app:settings.hardResetModal.title')}
desc={t('app:settings.hardResetModal.desc')}
confirmText={t('common.reset')}
title={t('settings.hardResetModal.title')}
desc={t('settings.hardResetModal.desc')}
renderIcon={this.hardResetIconRender}
/>
<Box my={6}>

2
src/components/RequestAmount/index.js

@ -180,7 +180,7 @@ export class RequestAmount extends PureComponent<Props> {
{withMax && (
<Box grow justify="flex-end">
<Button primary onClick={this.handleClickMax}>
{t('app:common.max')}
{t('common.max')}
</Button>
</Box>
)}

4
src/components/SelectAccount/index.js

@ -74,9 +74,9 @@ const RawSelectAccount = ({ accounts, onChange, value, t, ...props }: Props) =>
getOptionValue={getOptionValue}
renderValue={renderOption}
renderOption={renderOption}
placeholder={t('app:common.selectAccount')}
placeholder={t('common.selectAccount')}
noOptionsMessage={({ inputValue }) =>
t('app:common.selectAccountNoOption', { accountName: inputValue })
t('common.selectAccountNoOption', { accountName: inputValue })
}
onChange={onChange}
/>

4
src/components/SelectCurrency/index.js

@ -39,10 +39,10 @@ const SelectCurrency = ({ onChange, value, t, placeholder, currencies, ...props
renderOption={renderOption}
renderValue={renderOption}
options={options}
placeholder={placeholder || t('app:common.selectCurrency')}
placeholder={placeholder || t('common.selectCurrency')}
data-e2e="test"
noOptionsMessage={({ inputValue }: { inputValue: string }) =>
t('app:common.selectCurrencyNoOption', { currencyName: inputValue })
t('common.selectCurrencyNoOption', { currencyName: inputValue })
}
onChange={item => onChange(item ? item.currency : null)}
{...props}

6
src/components/SelectExchange.js

@ -127,11 +127,11 @@ class SelectExchange extends Component<
options={options}
onChange={onChange}
isLoading={isLoading}
placeholder={t('app:common.selectExchange')}
placeholder={t('common.selectExchange')}
noOptionsMessage={({ inputValue }) =>
inputValue
? t('app:common.selectExchangeNoOption', { exchangeName: inputValue })
: t('app:common.selectExchangeNoOptionAtAll')
? t('common.selectExchangeNoOption', { exchangeName: inputValue })
: t('common.selectExchangeNoOptionAtAll')
}
{...props}
/>

8
src/components/SettingsPage/CleanButton.js

@ -49,7 +49,7 @@ class CleanButton extends PureComponent<Props, State> {
return (
<Fragment>
<Button small primary onClick={this.open} event="ClearCacheIntent">
{t('app:settings.profile.softReset')}
{t('settings.profile.softReset')}
</Button>
<ConfirmModal
@ -59,9 +59,9 @@ class CleanButton extends PureComponent<Props, State> {
onReject={this.close}
onConfirm={this.action}
isLoading={isLoading}
title={t('app:settings.softResetModal.title')}
subTitle={t('app:common.areYouSure')}
desc={t('app:settings.softResetModal.desc')}
title={t('settings.softResetModal.title')}
subTitle={t('common.areYouSure')}
desc={t('settings.softResetModal.desc')}
/>
</Fragment>
)

10
src/components/SettingsPage/DisablePasswordModal.js

@ -69,15 +69,15 @@ class DisablePasswordModal extends PureComponent<Props, State> {
<form onSubmit={this.disablePassword}>
<ModalBody onClose={onClose}>
<ModalTitle data-e2e="disablePassword_modalTitle">
{t('app:password.disablePassword.title')}
{t('password.disablePassword.title')}
</ModalTitle>
<ModalContent>
<Box ff="Open Sans" color="smoke" fontSize={4} textAlign="center" px={4}>
{t('app:password.disablePassword.desc')}
{t('password.disablePassword.desc')}
<Box px={7} mt={4} flow={3}>
<Box flow={1}>
<Label htmlFor="password">
{t('app:password.inputFields.currentPassword.label')}
{t('password.inputFields.currentPassword.label')}
</Label>
<InputPassword
autoFocus
@ -93,7 +93,7 @@ class DisablePasswordModal extends PureComponent<Props, State> {
</ModalContent>
<ModalFooter horizontal align="center" justify="flex-end" flow={2}>
<Button small type="button" onClick={onClose}>
{t('app:common.cancel')}
{t('common.cancel')}
</Button>
<Button
small
@ -101,7 +101,7 @@ class DisablePasswordModal extends PureComponent<Props, State> {
onClick={this.disablePassword}
disabled={!currentPassword && !incorrectPassword}
>
{t('app:common.save')}
{t('common.save')}
</Button>
</ModalFooter>
</ModalBody>

4
src/components/SettingsPage/LanguageSelect.js

@ -27,8 +27,8 @@ class LanguageSelect extends PureComponent<Props> {
setLanguage(languageKey)
}
languages = [{ value: null, label: this.props.t(`app:language.system`) }].concat(
languageKeys.map(key => ({ value: key, label: this.props.t(`app:language.${key}`) })),
languages = [{ value: null, label: this.props.t(`language.system`) }].concat(
languageKeys.map(key => ({ value: key, label: this.props.t(`language.${key}`) })),
)
render() {

2
src/components/SettingsPage/LaunchOnboardingBtn.js

@ -27,7 +27,7 @@ class LaunchOnboardingBtn extends PureComponent<Props> {
<Fragment>
<Track onUpdate event={'Launch Onboarding from Settings'} />
<Button primary small onClick={this.handleLaunchOnboarding}>
{t('app:common.launch')}
{t('common.launch')}
</Button>
</Fragment>
)

4
src/components/SettingsPage/MarketIndicatorRadio.js

@ -19,11 +19,11 @@ type Props = {
class MarketIndicatorRadio extends PureComponent<Props> {
indicators = [
{
label: this.props.t('app:common.eastern'),
label: this.props.t('common.eastern'),
key: 'eastern',
},
{
label: this.props.t('app:common.western'),
label: this.props.t('common.western'),
key: 'western',
},
]

2
src/components/SettingsPage/PasswordButton.js

@ -85,7 +85,7 @@ class PasswordButton extends PureComponent<Props, State> {
<Box horizontal flow={2} align="center">
{hasPassword && (
<Button small onClick={this.handleOpenPasswordModal}>
{t('app:settings.profile.changePassword')}
{t('settings.profile.changePassword')}
</Button>
)}
<Switch

6
src/components/SettingsPage/PasswordForm.js

@ -42,7 +42,7 @@ class PasswordForm extends PureComponent<Props> {
{hasPassword && (
<Box flow={1} mb={5}>
<Label htmlFor="currentPassword">
{t('app:password.inputFields.currentPassword.label')}
{t('password.inputFields.currentPassword.label')}
</Label>
<InputPassword
autoFocus
@ -54,7 +54,7 @@ class PasswordForm extends PureComponent<Props> {
</Box>
)}
<Box flow={1}>
<Label htmlFor="newPassword">{t('app:password.inputFields.newPassword.label')}</Label>
<Label htmlFor="newPassword">{t('password.inputFields.newPassword.label')}</Label>
<InputPassword
style={{ mt: 4, width: 240 }}
autoFocus={!hasPassword}
@ -66,7 +66,7 @@ class PasswordForm extends PureComponent<Props> {
</Box>
<Box flow={1}>
<Label htmlFor="confirmPassword">
{t('app:password.inputFields.confirmPassword.label')}
{t('password.inputFields.confirmPassword.label')}
</Label>
<InputPassword
style={{ width: 240 }}

14
src/components/SettingsPage/PasswordModal.js

@ -83,10 +83,10 @@ class PasswordModal extends PureComponent<Props, State> {
render={({ onClose }) => (
<ModalBody onClose={onClose}>
{hasPassword ? (
<ModalTitle>{t('app:password.changePassword.title')}</ModalTitle>
<ModalTitle>{t('password.changePassword.title')}</ModalTitle>
) : (
<ModalTitle data-e2e="enablePassword_modal">
{t('app:password.setPassword.title')}
{t('password.setPassword.title')}
</ModalTitle>
)}
<ModalContent>
@ -99,11 +99,11 @@ class PasswordModal extends PureComponent<Props, State> {
data-e2e="setPassword_modalTitle"
>
{hasPassword
? t('app:password.changePassword.subTitle')
: t('app:password.setPassword.subTitle')}
? t('password.changePassword.subTitle')
: t('password.setPassword.subTitle')}
</Box>
<Box ff="Open Sans" color="smoke" fontSize={4} textAlign="center" px={4}>
{t('app:password.setPassword.desc')}
{t('password.setPassword.desc')}
</Box>
<PasswordForm
onSubmit={this.handleSave}
@ -124,7 +124,7 @@ class PasswordModal extends PureComponent<Props, State> {
onClick={onClose}
data-e2e="setPassword_modalCancel_button"
>
{t('app:common.cancel')}
{t('common.cancel')}
</Button>
<Button
small
@ -132,7 +132,7 @@ class PasswordModal extends PureComponent<Props, State> {
onClick={this.handleSave}
disabled={!this.isValid() || !newPassword.length || !confirmPassword.length}
>
{t('app:common.save')}
{t('common.save')}
</Button>
</ModalFooter>
</ModalBody>

2
src/components/SettingsPage/ReleaseNotesButton.js

@ -32,7 +32,7 @@ class ReleaseNotesButton extends PureComponent<Props> {
openModal(MODAL_RELEASES_NOTES, version)
}}
>
{t('app:settings.help.releaseNotesBtn')}
{t('settings.help.releaseNotesBtn')}
</Button>
)
}

8
src/components/SettingsPage/ResetButton.js

@ -45,7 +45,7 @@ class ResetButton extends PureComponent<Props, State> {
return (
<Fragment>
<Button small danger onClick={this.open} event="HardResetIntent">
{t('app:common.reset')}
{t('common.reset')}
</Button>
<ConfirmModal
@ -56,9 +56,9 @@ class ResetButton extends PureComponent<Props, State> {
onClose={this.close}
onReject={this.close}
onConfirm={this.action}
confirmText={t('app:common.reset')}
title={t('app:settings.hardResetModal.title')}
desc={t('app:settings.hardResetModal.desc')}
confirmText={t('common.reset')}
title={t('settings.hardResetModal.title')}
desc={t('settings.hardResetModal.desc')}
renderIcon={() => (
// FIXME why not pass in directly the DOM 🤷🏻
<IconWrapperCircle color="alertRed">

10
src/components/SettingsPage/index.js

@ -40,22 +40,22 @@ class SettingsPage extends PureComponent<Props, State> {
this._items = [
{
key: 'display',
label: props.t('app:settings.tabs.display'),
label: props.t('settings.tabs.display'),
value: SectionDisplay,
},
{
key: 'currencies',
label: props.t('app:settings.tabs.currencies'),
label: props.t('settings.tabs.currencies'),
value: SectionCurrencies,
},
{
key: 'about',
label: props.t('app:settings.tabs.about'),
label: props.t('settings.tabs.about'),
value: SectionAbout,
},
{
key: 'help',
label: props.t('app:settings.tabs.help'),
label: props.t('settings.tabs.help'),
value: SectionHelp,
},
]
@ -107,7 +107,7 @@ class SettingsPage extends PureComponent<Props, State> {
return (
<Box pb={4} selectable>
<Box ff="Museo Sans|Regular" color="dark" fontSize={7} mb={5} data-e2e="settings_title">
{t('app:settings.title')}
{t('settings.title')}
</Box>
<Pills mb={4} items={items} activeKey={tab.key} onChange={this.handleChangeTab} />
<Switch>

14
src/components/SettingsPage/sections/About.js

@ -34,24 +34,24 @@ class SectionHelp extends PureComponent<Props> {
<Header
icon={<IconLoader size={16} />}
title={t('app:settings.tabs.about')}
desc={t('app:settings.about.desc')}
title={t('settings.tabs.about')}
desc={t('settings.about.desc')}
/>
<Body>
<Row title={t('app:settings.help.version')} desc={`Ledger Live ${version}`}>
<Row title={t('settings.help.version')} desc={`Ledger Live ${version}`}>
<ReleaseNotesButton />
</Row>
<AboutRowItem
title={t('app:settings.help.terms')}
desc={t('app:settings.help.termsDesc')}
title={t('settings.help.terms')}
desc={t('settings.help.termsDesc')}
url={urls.terms}
/>
<AboutRowItem
title={t('app:settings.help.privacy')}
desc={t('app:settings.help.privacyDesc')}
title={t('settings.help.privacy')}
desc={t('settings.help.privacyDesc')}
url={urls.privacyPolicy}
/>
</Body>

4
src/components/SettingsPage/sections/Currencies.js

@ -47,8 +47,8 @@ class TabCurrencies extends PureComponent<Props, State> {
<TrackPage category="Settings" name="Currencies" currencyId={currency.id} />
<Header
icon={<IconCurrencies size={16} />}
title={t('app:settings.tabs.currencies')}
desc={t('app:settings.currencies.desc')}
title={t('settings.tabs.currencies')}
desc={t('settings.currencies.desc')}
renderRight={
<SelectCurrency
small

8
src/components/SettingsPage/sections/CurrencyRows.js

@ -63,10 +63,10 @@ class CurrencyRows extends PureComponent<Props> {
<Fragment>
{currency !== intermediaryCurrency ? (
<Row
title={t('app:settings.currencies.exchange', {
title={t('settings.currencies.exchange', {
ticker: currency.ticker,
})}
desc={t('app:settings.currencies.exchangeDesc', {
desc={t('settings.currencies.exchangeDesc', {
currencyName: currency.name,
})}
>
@ -82,8 +82,8 @@ class CurrencyRows extends PureComponent<Props> {
) : null}
{defaults.confirmationsNb ? (
<Row
title={t('app:settings.currencies.confirmationsNb')}
desc={t('app:settings.currencies.confirmationsNbDesc')}
title={t('settings.currencies.confirmationsNb')}
desc={t('settings.currencies.confirmationsNbDesc')}
>
<Track onUpdate event="ConfirmationsNb" confirmationsNb={confirmationsNb} />
<StepperNumber

42
src/components/SettingsPage/sections/Display.js

@ -43,70 +43,58 @@ class TabGeneral extends PureComponent<Props> {
<TrackPage category="Settings" name="Display" />
<Header
icon={<IconDisplay size={16} />}
title={t('app:settings.tabs.display')}
desc={t('app:settings.display.desc')}
title={t('settings.tabs.display')}
desc={t('settings.display.desc')}
/>
<Body>
<Row
title={t('app:settings.display.counterValue')}
desc={t('app:settings.display.counterValueDesc')}
title={t('settings.display.counterValue')}
desc={t('settings.display.counterValueDesc')}
>
<CounterValueSelect />
</Row>
<Row
title={t('app:settings.display.exchange', {
title={t('settings.display.exchange', {
ticker: counterValueCurrency.ticker,
fiat: counterValueCurrency.name,
})}
desc={t('app:settings.display.exchangeDesc', {
desc={t('settings.display.exchangeDesc', {
fiat: counterValueCurrency.name,
ticker: counterValueCurrency.ticker,
})}
>
<CounterValueExchangeSelect />
</Row>
<Row
title={t('app:settings.display.language')}
desc={t('app:settings.display.languageDesc')}
>
<Row title={t('settings.display.language')} desc={t('settings.display.languageDesc')}>
<LanguageSelect />
</Row>
{useSystem ? null : (
<Row
title={t('app:settings.display.region')}
desc={t('app:settings.display.regionDesc')}
>
<Row title={t('settings.display.region')} desc={t('settings.display.regionDesc')}>
<RegionSelect />
</Row>
)}
{EXPERIMENTAL_MARKET_INDICATOR_SETTINGS ? (
<Row title={t('app:settings.display.stock')} desc={t('app:settings.display.stockDesc')}>
<Row title={t('settings.display.stock')} desc={t('settings.display.stockDesc')}>
<MarketIndicatorRadio />
</Row>
) : null}
<Row
title={t('app:settings.profile.password')}
desc={t('app:settings.profile.passwordDesc')}
>
<Row title={t('settings.profile.password')} desc={t('settings.profile.passwordDesc')}>
<PasswordButton />
</Row>
<Row
title={t('app:settings.profile.reportErrors')}
desc={t('app:settings.profile.reportErrorsDesc')}
title={t('settings.profile.reportErrors')}
desc={t('settings.profile.reportErrorsDesc')}
>
<SentryLogsButton />
</Row>
<Row
title={t('app:settings.profile.analytics')}
desc={t('app:settings.profile.analyticsDesc')}
>
<Row title={t('settings.profile.analytics')} desc={t('settings.profile.analyticsDesc')}>
<ShareAnalyticsButton />
</Row>
<Row
title={t('app:settings.profile.developerMode')}
desc={t('app:settings.profile.developerModeDesc')}
title={t('settings.profile.developerMode')}
desc={t('settings.profile.developerModeDesc')}
>
<DevModeButton />
</Row>

28
src/components/SettingsPage/sections/Help.js

@ -36,43 +36,43 @@ class SectionHelp extends PureComponent<Props> {
<Header
icon={<IconHelp size={16} />}
title={t('app:settings.tabs.help')}
desc={t('app:settings.help.desc')}
title={t('settings.tabs.help')}
desc={t('settings.help.desc')}
/>
<Body>
<AboutRowItem
title={t('app:settings.help.faq')}
desc={t('app:settings.help.faqDesc')}
title={t('settings.help.faq')}
desc={t('settings.help.faqDesc')}
url={urls.faq}
/>
<Row
title={t('app:settings.profile.softResetTitle')}
desc={t('app:settings.profile.softResetDesc')}
title={t('settings.profile.softResetTitle')}
desc={t('settings.profile.softResetDesc')}
>
<CleanButton />
</Row>
<Row
title={t('app:settings.exportLogs.title')}
desc={t('app:settings.exportLogs.desc', { logsDirectory: resolveLogsDirectory() })}
title={t('settings.exportLogs.title')}
desc={t('settings.exportLogs.desc', { logsDirectory: resolveLogsDirectory() })}
>
<ExportLogsBtn />
</Row>
<Row
title={t('app:settings.profile.launchOnboarding')}
desc={t('app:settings.profile.launchOnboardingDesc')}
title={t('settings.profile.launchOnboarding')}
desc={t('settings.profile.launchOnboardingDesc')}
>
<LaunchOnboardingBtn />
</Row>
<Row
title={t('app:settings.openUserDataDirectory.title')}
desc={t('app:settings.openUserDataDirectory.desc')}
title={t('settings.openUserDataDirectory.title')}
desc={t('settings.openUserDataDirectory.desc')}
>
<OpenUserDataDirectoryBtn />
</Row>
<Row
title={t('app:settings.profile.hardResetTitle')}
desc={t('app:settings.profile.hardResetDesc')}
title={t('settings.profile.hardResetTitle')}
desc={t('settings.profile.hardResetDesc')}
>
<ResetButton />
</Row>

2
src/components/SyncAgo.js

@ -9,7 +9,7 @@ import Box from './base/Box'
class SyncAgo extends PureComponent<{ t: T, date: Date }> {
render() {
const { t, date } = this.props
return <Box p={4}>{t('app:common.sync.ago', { time: moment(date).fromNow() })}</Box>
return <Box p={4}>{t('common.sync.ago', { time: moment(date).fromNow() })}</Box>
}
}

10
src/components/TopBar/ActivityIndicator.js

@ -85,22 +85,22 @@ class ActivityIndicatorInner extends PureComponent<Props, { lastClickTime: numbe
align="center"
>
{isRotating ? (
t('app:common.sync.syncing')
t('common.sync.syncing')
) : isError ? (
<Fragment>
<Box>{t('app:common.sync.error')}</Box>
<Box>{t('common.sync.error')}</Box>
<Box
ml={2}
style={{ textDecoration: 'underline', pointerEvents: 'all' }}
onClick={this.onClick}
>
{t('app:common.sync.refresh')}
{t('common.sync.refresh')}
</Box>
</Fragment>
) : isUpToDate ? (
t('app:common.sync.upToDate')
t('common.sync.upToDate')
) : (
t('app:common.sync.outdated')
t('common.sync.outdated')
)}
</Box>
</ItemContainer>

4
src/components/TopBar/index.js

@ -109,7 +109,7 @@ class TopBar extends PureComponent<Props> {
</Box>
</Fragment>
)}
<Tooltip render={() => t('app:settings.title')} data-e2e="setting_button">
<Tooltip render={() => t('settings.title')} data-e2e="setting_button">
<ItemContainer isInteractive onClick={this.navigateToSettings}>
<IconSettings size={16} />
</ItemContainer>
@ -119,7 +119,7 @@ class TopBar extends PureComponent<Props> {
<Box justifyContent="center">
<Bar />
</Box>
<Tooltip render={() => t('app:common.lock')}>
<Tooltip render={() => t('common.lock')}>
<ItemContainer isInteractive justifyContent="center" onClick={this.handleLock}>
<IconLock size={16} />
</ItemContainer>

2
src/components/TranslatedError.js

@ -33,7 +33,7 @@ class TranslatedError extends PureComponent<Props> {
// $FlowFixMe
const arg: Object = Object.assign({ message: error.message }, error)
if (error.name) {
const translation = t(`app:errors.${error.name}.${field}`, arg)
const translation = t(`errors.${error.name}.${field}`, arg)
if (translation !== `errors.${error.name}.${field}`) {
// It is translated
return translation

4
src/components/UpdateNotifier/UpdateDownloaded.js

@ -65,14 +65,14 @@ class UpdateDownloaded extends PureComponent<Props> {
<Box horizontal flow={3}>
<UpdateIcon size={16} />
<Box grow>
<NotifText>{t('app:update.newVersionReady')}</NotifText>
<NotifText>{t('update.newVersionReady')}</NotifText>
</Box>
<Box>
<NotifText
style={{ cursor: 'pointer', textDecoration: 'underline' }}
onClick={() => sendEvent('updater', 'quitAndInstall')}
>
{t('app:update.relaunch')}
{t('update.relaunch')}
</NotifText>
</Box>
</Box>

4
src/components/base/AccountsList/index.js

@ -92,8 +92,8 @@ class AccountsList extends Component<
style={{ lineHeight: '10px' }}
>
{isAllSelected
? t('app:addAccounts.unselectAll', { count: accounts.length })
: t('app:addAccounts.selectAll', { count: accounts.length })}
? t('addAccounts.unselectAll', { count: accounts.length })
: t('addAccounts.selectAll', { count: accounts.length })}
</FakeLink>
)}
</Box>

2
src/components/base/CopyWithFeedback.js

@ -53,7 +53,7 @@ class CopyWithFeedback extends PureComponent<Props, State> {
return (
<ClickableWrapper onClick={this.handleCopy}>
<IconCopy size={16} />
<span>{isCopied ? t('app:common.copied') : t('app:common.copy')}</span>
<span>{isCopied ? t('common.copied') : t('common.copy')}</span>
</ClickableWrapper>
)
}

2
src/components/base/InputPassword/index.js

@ -121,7 +121,7 @@ class InputPassword extends PureComponent<Props, State> {
</Box>
{hasValue && (
<Warning passwordStrength={passwordStrength}>
{t(`app:password.warning_${passwordStrength}`)}
{t(`password.warning_${passwordStrength}`)}
</Warning>
)}
</Fragment>

4
src/components/base/Modal/ConfirmModal.js

@ -46,8 +46,8 @@ class ConfirmModal extends PureComponent<Props> {
...props
} = this.props
const realConfirmText = confirmText || t('app:common.confirm')
const realCancelText = cancelText || t('app:common.cancel')
const realConfirmText = confirmText || t('common.confirm')
const realCancelText = cancelText || t('common.cancel')
return (
<Modal
isOpened={isOpened}

2
src/components/base/Modal/ModalTitle.js

@ -64,7 +64,7 @@ function ModalTitle({
{onBack && (
<Back onClick={onBack}>
<IconAngleLeft size={16} />
<span>{t('app:common.back')}</span>
<span>{t('common.back')}</span>
</Back>
)}
{children}

2
src/components/base/RetryButton.js

@ -14,7 +14,7 @@ type Props = {
class RetryButton extends PureComponent<Props> {
render() {
const { t, ...props } = this.props
return <Button {...props}>{t('app:common.retry')}</Button>
return <Button {...props}>{t('common.retry')}</Button>
}
}

26
src/components/modals/AccountSettingRenderBody.js

@ -210,12 +210,12 @@ class HelperComp extends PureComponent<Props, State> {
<ModalBody onClose={onClose}>
<form onSubmit={this.handleSubmit(account, onClose)}>
<TrackPage category="Modal" name="AccountSettings" />
<ModalTitle>{t('app:account.settings.title')}</ModalTitle>
<ModalTitle>{t('account.settings.title')}</ModalTitle>
<ModalContent mb={3}>
<Container>
<Box>
<OptionRowTitle>{t('app:account.settings.accountName.title')}</OptionRowTitle>
<OptionRowDesc>{t('app:account.settings.accountName.desc')}</OptionRowDesc>
<OptionRowTitle>{t('account.settings.accountName.title')}</OptionRowTitle>
<OptionRowDesc>{t('account.settings.accountName.desc')}</OptionRowDesc>
</Box>
<Box>
<Input
@ -231,8 +231,8 @@ class HelperComp extends PureComponent<Props, State> {
</Container>
<Container>
<Box>
<OptionRowTitle>{t('app:account.settings.unit.title')}</OptionRowTitle>
<OptionRowDesc>{t('app:account.settings.unit.desc')}</OptionRowDesc>
<OptionRowTitle>{t('account.settings.unit.title')}</OptionRowTitle>
<OptionRowDesc>{t('account.settings.unit.desc')}</OptionRowDesc>
</Box>
<Box style={{ width: 230 }}>
<Select
@ -248,8 +248,8 @@ class HelperComp extends PureComponent<Props, State> {
{canConfigureEndpointConfig(account) ? (
<Container>
<Box>
<OptionRowTitle>{t('app:account.settings.endpointConfig.title')}</OptionRowTitle>
<OptionRowDesc>{t('app:account.settings.endpointConfig.desc')}</OptionRowDesc>
<OptionRowTitle>{t('account.settings.endpointConfig.title')}</OptionRowTitle>
<OptionRowDesc>{t('account.settings.endpointConfig.desc')}</OptionRowDesc>
</Box>
<Box>
<Input
@ -266,7 +266,7 @@ class HelperComp extends PureComponent<Props, State> {
</Box>
</Container>
) : null}
<Spoiler textTransform title={t('app:account.settings.advancedLogs')}>
<Spoiler textTransform title={t('account.settings.advancedLogs')}>
<SyncAgo date={account.lastSyncDate} />
<textarea
readOnly
@ -292,10 +292,10 @@ class HelperComp extends PureComponent<Props, State> {
type="button"
onClick={this.handleOpenRemoveAccountModal}
>
{t('app:common.delete')}
{t('common.delete')}
</Button>
<Button event="DoneEditingAccount" ml="auto" type="submit" primary>
{t('app:common.apply')}
{t('common.apply')}
</Button>
</ModalFooter>
</form>
@ -306,9 +306,9 @@ class HelperComp extends PureComponent<Props, State> {
onClose={this.handleCloseRemoveAccountModal}
onReject={this.handleCloseRemoveAccountModal}
onConfirm={() => this.handleRemoveAccount(account)}
title={t('app:settings.removeAccountModal.title')}
subTitle={t('app:common.areYouSure')}
desc={t('app:settings.removeAccountModal.desc')}
title={t('settings.removeAccountModal.title')}
subTitle={t('common.areYouSure')}
desc={t('settings.removeAccountModal.desc')}
/>
</ModalBody>
)

10
src/components/modals/AddAccounts/index.js

@ -38,7 +38,7 @@ const createSteps = ({ t }: { t: T }) => {
return [
{
id: 'chooseCurrency',
label: t('app:addAccounts.breadcrumb.informations'),
label: t('addAccounts.breadcrumb.informations'),
component: StepChooseCurrency,
footer: StepChooseCurrencyFooter,
onBack: null,
@ -46,7 +46,7 @@ const createSteps = ({ t }: { t: T }) => {
},
{
id: 'connectDevice',
label: t('app:addAccounts.breadcrumb.connectDevice'),
label: t('addAccounts.breadcrumb.connectDevice'),
component: StepConnectDevice,
footer: StepConnectDeviceFooter,
onBack,
@ -54,7 +54,7 @@ const createSteps = ({ t }: { t: T }) => {
},
{
id: 'import',
label: t('app:addAccounts.breadcrumb.import'),
label: t('addAccounts.breadcrumb.import'),
component: StepImport,
footer: StepImportFooter,
onBack,
@ -62,7 +62,7 @@ const createSteps = ({ t }: { t: T }) => {
},
{
id: 'finish',
label: t('app:addAccounts.breadcrumb.finish'),
label: t('addAccounts.breadcrumb.finish'),
component: StepFinish,
footer: StepFinishFooter,
onBack: null,
@ -247,7 +247,7 @@ class AddAccounts extends PureComponent<Props, State> {
render={({ onClose }) => (
<Stepper
key={reset} // THIS IS A HACK because stepper is not controllable. FIXME
title={t('app:addAccounts.title')}
title={t('addAccounts.title')}
initialStepId="chooseCurrency"
onStepChange={this.handleStepChange}
onClose={onClose}

2
src/components/modals/AddAccounts/steps/01-step-choose-currency.js

@ -19,7 +19,7 @@ export function StepChooseCurrencyFooter({ transitionTo, currency, t }: StepProp
<TrackPage category="AddAccounts" name="Step1" />
{currency && <CurrencyBadge mr="auto" currency={currency} />}
<Button primary disabled={!currency} onClick={() => transitionTo('connectDevice')}>
{t('app:common.continue')}
{t('common.continue')}
</Button>
</Fragment>
)

4
src/components/modals/AddAccounts/steps/02-step-connect-device.js

@ -21,7 +21,7 @@ function StepConnectDevice({ t, currency, device, setAppOpened }: StepProps) {
<Box align="center" mb={6}>
<CurrencyCircleIcon mb={3} size={40} currency={currency} />
<Box ff="Open Sans" fontSize={4} color="dark" textAlign="center" style={{ width: 370 }}>
<Trans i18nKey="app:addAccounts.connectDevice.desc" parent="div">
<Trans i18nKey="addAccounts.connectDevice.desc" parent="div">
{`Follow the steps below to add `}
<strong style={{ fontWeight: 'bold' }}>{`${currency.name} (${
currency.ticker
@ -47,7 +47,7 @@ function StepConnectDevice({ t, currency, device, setAppOpened }: StepProps) {
export function StepConnectDeviceFooter({ t, transitionTo, isAppOpened }: StepProps) {
return (
<Button primary disabled={!isAppOpened} onClick={() => transitionTo('import')}>
{t('app:common.continue')}
{t('common.continue')}
</Button>
)
}

30
src/components/modals/AddAccounts/steps/03-step-import.js

@ -97,17 +97,17 @@ class StepImport extends PureComponent<StepProps> {
const isUnsplit = name.indexOf('unsplit') !== -1
if (name === 'New Account') {
name = t('app:addAccounts.newAccount')
name = t('addAccounts.newAccount')
} else if (isLegacy) {
if (isUnsplit) {
name = t('app:addAccounts.legacyUnsplitAccount', {
name = t('addAccounts.legacyUnsplitAccount', {
accountName: name.replace(' (legacy)', '').replace(' (unsplit)', ''),
})
} else {
name = t('app:addAccounts.legacyAccount', { accountName: name.replace(' (legacy)', '') })
name = t('addAccounts.legacyAccount', { accountName: name.replace(' (legacy)', '') })
}
} else if (isUnsplit) {
name = t('app:addAccounts.unsplitAccount', { accountName: name.replace(' (unsplit)', '') })
name = t('addAccounts.unsplitAccount', { accountName: name.replace(' (unsplit)', '') })
}
return {
@ -243,15 +243,15 @@ class StepImport extends PureComponent<StepProps> {
}
})
const importableAccountsListTitle = t('app:addAccounts.accountToImportSubtitle', {
const importableAccountsListTitle = t('addAccounts.accountToImportSubtitle', {
count: importableAccounts.length,
})
const importedAccountsListTitle = t('app:addAccounts.accountAlreadyImportedSubtitle', {
const importedAccountsListTitle = t('addAccounts.accountAlreadyImportedSubtitle', {
count: importedAccounts.length,
})
const importableAccountsEmpty = t('app:addAccounts.noAccountToImport', { currencyName })
const importableAccountsEmpty = t('addAccounts.noAccountToImport', { currencyName })
const shouldShowNew = scanStatus !== 'scanning'
@ -276,11 +276,11 @@ class StepImport extends PureComponent<StepProps> {
{!shouldShowNew ? null : (
<AccountsList
autoFocusFirstInput={importableAccounts.length === 0}
title={t('app:addAccounts.createNewAccount.title')}
title={t('addAccounts.createNewAccount.title')}
emptyText={
alreadyEmptyAccount ? (
<Trans
i18nKey="app:addAccounts.createNewAccount.noOperationOnLastAccount"
i18nKey="addAccounts.createNewAccount.noOperationOnLastAccount"
parent="div"
>
{' '}
@ -289,7 +289,7 @@ class StepImport extends PureComponent<StepProps> {
</Text>{' '}
</Trans>
) : (
<Trans i18nKey="app:addAccounts.createNewAccount.noAccountToCreate" parent="div">
<Trans i18nKey="addAccounts.createNewAccount.noAccountToCreate" parent="div">
{' '}
<Text ff="Open Sans|SemiBold" color="dark">
{currencyName}
@ -317,7 +317,7 @@ class StepImport extends PureComponent<StepProps> {
<LoadingRow>
<Spinner color="grey" size={16} />
<Box ml={2} ff="Open Sans|Regular" color="grey" fontSize={4}>
{t('app:common.sync.syncing')}
{t('common.sync.syncing')}
</Box>
</LoadingRow>
) : null}
@ -355,9 +355,7 @@ export const StepImportFooter = ({
const count = checkedAccountsIds.length
const ctaWording =
scanStatus === 'scanning'
? t('app:common.sync.syncing')
: t('app:addAccounts.cta.add', { count })
scanStatus === 'scanning' ? t('common.sync.syncing') : t('addAccounts.cta.add', { count })
const willClose = !willCreateAccount && !willAddAccounts
const onClick = willClose
@ -372,13 +370,13 @@ export const StepImportFooter = ({
{currency && <CurrencyBadge mr="auto" currency={currency} />}
{scanStatus === 'error' && (
<Fragment>
<ExternalLinkButton mr={2} label={t('app:common.getSupport')} url={urls.faq} />
<ExternalLinkButton mr={2} label={t('common.getSupport')} url={urls.faq} />
<RetryButton primary onClick={() => setScanStatus('scanning')} />
</Fragment>
)}
{scanStatus === 'scanning' && (
<Button mr={2} onClick={() => setScanStatus('finished')}>
{t('app:common.stop')}
{t('common.stop')}
</Button>
)}
{scanStatus !== 'error' && (

6
src/components/modals/AddAccounts/steps/04-step-finish.js

@ -42,8 +42,8 @@ function StepFinish({ currency, t, checkedAccountsIds }: StepProps) {
<IconCheckFull size={18} style={{ position: 'absolute', top: 0, right: 0 }} />
</Box>
) : null}
<Title>{t('app:addAccounts.success', { count: checkedAccountsIds.length })}</Title>
<Text>{t('app:addAccounts.successDescription', { count: checkedAccountsIds.length })}</Text>
<Title>{t('addAccounts.success', { count: checkedAccountsIds.length })}</Title>
<Text>{t('addAccounts.successDescription', { count: checkedAccountsIds.length })}</Text>
</Box>
)
}
@ -53,7 +53,7 @@ export default StepFinish
export const StepFinishFooter = ({ onGoStep1, t }: StepProps) => (
<Fragment>
<Button primary onClick={onGoStep1}>
{t('app:addAccounts.cta.addMore')}
{t('addAccounts.cta.addMore')}
</Button>
</Fragment>
)

8
src/components/modals/Disclaimer.js

@ -25,17 +25,17 @@ class DisclaimerModal extends PureComponent<Props> {
name={MODAL_DISCLAIMER}
render={({ onClose }) => (
<ModalBody onClose={onClose}>
<ModalTitle>{t('app:disclaimerModal.title')}</ModalTitle>
<ModalTitle>{t('disclaimerModal.title')}</ModalTitle>
<ModalContent flow={4} ff="Open Sans|Regular" fontSize={4} color="smoke">
<Box align="center" mt={4} pb={4}>
<HandShield size={55} />
</Box>
<p>{t('app:disclaimerModal.desc_1')}</p>
<p>{t('app:disclaimerModal.desc_2')}</p>
<p>{t('disclaimerModal.desc_1')}</p>
<p>{t('disclaimerModal.desc_2')}</p>
</ModalContent>
<ModalFooter horizontal justifyContent="flex-end">
<Button data-e2e="continue_button" onClick={onClose} primary>
{t('app:disclaimerModal.cta')}
{t('disclaimerModal.cta')}
</Button>
</ModalFooter>
</ModalBody>

28
src/components/modals/OperationDetails.js

@ -132,7 +132,7 @@ const OperationDetails = connect(mapStateToProps)((props: Props) => {
return (
<ModalBody onClose={onClose}>
<TrackPage category="Modal" name="OperationDetails" />
<ModalTitle>{t('app:operationDetails.title')}</ModalTitle>
<ModalTitle>{t('operationDetails.title')}</ModalTitle>
<ModalContent relative style={{ height: 500 }} px={0} pb={0}>
<GrowScroll px={5} pt={1} pb={8}>
<Box flow={3}>
@ -172,18 +172,18 @@ const OperationDetails = connect(mapStateToProps)((props: Props) => {
</Box>
<Box horizontal flow={2}>
<Box flex={1}>
<OpDetailsTitle>{t('app:operationDetails.account')}</OpDetailsTitle>
<OpDetailsTitle>{t('operationDetails.account')}</OpDetailsTitle>
<OpDetailsData>{name}</OpDetailsData>
</Box>
<Box flex={1}>
<OpDetailsTitle>{t('app:operationDetails.date')}</OpDetailsTitle>
<OpDetailsTitle>{t('operationDetails.date')}</OpDetailsTitle>
<OpDetailsData>{moment(date).format('LLL')}</OpDetailsData>
</Box>
</Box>
<B />
<Box horizontal flow={2}>
<Box flex={1}>
<OpDetailsTitle>{t('app:operationDetails.fees')}</OpDetailsTitle>
<OpDetailsTitle>{t('operationDetails.fees')}</OpDetailsTitle>
{fee ? (
<Fragment>
<OpDetailsData>
@ -191,16 +191,16 @@ const OperationDetails = connect(mapStateToProps)((props: Props) => {
</OpDetailsData>
</Fragment>
) : (
<OpDetailsData>{t('app:operationDetails.noFees')}</OpDetailsData>
<OpDetailsData>{t('operationDetails.noFees')}</OpDetailsData>
)}
</Box>
<Box flex={1}>
<OpDetailsTitle>{t('app:operationDetails.status')}</OpDetailsTitle>
<OpDetailsTitle>{t('operationDetails.status')}</OpDetailsTitle>
<OpDetailsData color={isConfirmed ? 'positiveGreen' : null} horizontal flow={1}>
<Box>
{isConfirmed
? t('app:operationDetails.confirmed')
: t('app:operationDetails.notConfirmed')}
? t('operationDetails.confirmed')
: t('operationDetails.notConfirmed')}
</Box>
<Box>{`(${confirmations})`}</Box>
</OpDetailsData>
@ -208,7 +208,7 @@ const OperationDetails = connect(mapStateToProps)((props: Props) => {
</Box>
<B />
<Box>
<OpDetailsTitle>{t('app:operationDetails.identifier')}</OpDetailsTitle>
<OpDetailsTitle>{t('operationDetails.identifier')}</OpDetailsTitle>
<OpDetailsData>
<Ellipsis canSelect>{hash}</Ellipsis>
<GradientHover>
@ -218,12 +218,12 @@ const OperationDetails = connect(mapStateToProps)((props: Props) => {
</Box>
<B />
<Box>
<OpDetailsTitle>{t('app:operationDetails.from')}</OpDetailsTitle>
<OpDetailsTitle>{t('operationDetails.from')}</OpDetailsTitle>
<DataList lines={uniqueSenders} t={t} />
</Box>
<B />
<Box>
<OpDetailsTitle>{t('app:operationDetails.to')}</OpDetailsTitle>
<OpDetailsTitle>{t('operationDetails.to')}</OpDetailsTitle>
<DataList lines={recipients} t={t} />
</Box>
</Box>
@ -234,7 +234,7 @@ const OperationDetails = connect(mapStateToProps)((props: Props) => {
{url && (
<ModalFooter horizontal justify="flex-end" flow={2}>
<Button primary onClick={() => openURL(url)}>
{t('app:operationDetails.viewOperation')}
{t('operationDetails.viewOperation')}
</Button>
</ModalFooter>
)}
@ -300,7 +300,7 @@ export class DataList extends Component<{ lines: string[], t: T }, *> {
<Box onClick={this.onClick} py={1}>
<More fontSize={4} color="wallet" ff="Open Sans|SemiBold" mt={1}>
<IconChevronRight size={12} style={{ marginRight: 5 }} />
{t('app:operationDetails.showMore', { recipients: lines.length - numToShow })}
{t('operationDetails.showMore', { recipients: lines.length - numToShow })}
</More>
</Box>
)}
@ -311,7 +311,7 @@ export class DataList extends Component<{ lines: string[], t: T }, *> {
<Box onClick={this.onClick} py={1}>
<More fontSize={4} color="wallet" ff="Open Sans|SemiBold" mt={1}>
<IconChevronRight size={12} style={{ marginRight: 5 }} />
{t('app:operationDetails.showLess')}
{t('operationDetails.showLess')}
</More>
</Box>
)}

10
src/components/modals/Receive/index.js

@ -61,20 +61,20 @@ export type StepProps = DefaultStepProps & {
const createSteps = ({ t }: { t: T }) => [
{
id: 'account',
label: t('app:receive.steps.chooseAccount.title'),
label: t('receive.steps.chooseAccount.title'),
component: StepAccount,
footer: StepAccountFooter,
},
{
id: 'device',
label: t('app:receive.steps.connectDevice.title'),
label: t('receive.steps.connectDevice.title'),
component: StepConnectDevice,
footer: StepConnectDeviceFooter,
onBack: ({ transitionTo }: StepProps) => transitionTo('account'),
},
{
id: 'confirm',
label: t('app:receive.steps.confirmAddress.title'),
label: t('receive.steps.confirmAddress.title'),
footer: StepConfirmAddressFooter,
component: StepConfirmAddress,
onBack: ({ transitionTo }: StepProps) => transitionTo('device'),
@ -82,7 +82,7 @@ const createSteps = ({ t }: { t: T }) => [
},
{
id: 'receive',
label: t('app:receive.steps.receiveFunds.title'),
label: t('receive.steps.receiveFunds.title'),
component: StepReceiveFunds,
shouldPreventClose: ({ isAddressVerified }: StepProps) => isAddressVerified === null,
},
@ -199,7 +199,7 @@ class ReceiveModal extends PureComponent<Props, State> {
onBeforeOpen={this.handleBeforeOpenModal}
render={({ onClose }) => (
<Stepper
title={t('app:receive.title')}
title={t('receive.title')}
initialStepId={stepId}
onStepChange={this.handleStepChange}
onClose={onClose}

Some files were not shown because too many files changed in this diff

Loading…
Cancel
Save