Browse Source

Add settings for change counterValue

master
Loëck Vézien 7 years ago
parent
commit
92ed354b9e
No known key found for this signature in database GPG Key ID: CBCDCE384E853AC4
  1. 15
      src/actions/counterValues.js
  2. 10
      src/components/AccountPage/index.js
  3. 20
      src/components/BalanceSummary/BalanceInfos.js
  4. 5
      src/components/BalanceSummary/index.js
  5. 4
      src/components/CalculateBalance.js
  6. 5
      src/components/DashboardPage/AccountCard.js
  7. 9
      src/components/DashboardPage/index.js
  8. 88
      src/components/SettingsPage/Money.js
  9. 16
      src/components/SettingsPage/index.js
  10. 8
      src/helpers/__tests__/balance.test.js
  11. 12
      src/helpers/balance.js
  12. 17
      src/reducers/settings.js
  13. 5
      src/types/common.js
  14. 1
      static/i18n/en/settings.yml

15
src/actions/counterValues.js

@ -8,21 +8,22 @@ import get from 'lodash/get'
import db from 'helpers/db' import db from 'helpers/db'
type InitCounterValues = () => { type: string, payload: Object } export type InitCounterValues = () => { type: string, payload: Object }
export const initCounterValues: InitCounterValues = () => ({ export const initCounterValues: InitCounterValues = () => ({
type: 'UPDATE_COUNTER_VALUES', type: 'UPDATE_COUNTER_VALUES',
payload: db.get('counterValues'), payload: db.get('counterValues'),
}) })
type UpdateCounterValues = Object => { type: string, payload: Object } export type UpdateCounterValues = Object => { type: string, payload: Object }
export const updateCounterValues: UpdateCounterValues = payload => ({ export const updateCounterValues: UpdateCounterValues = payload => ({
type: 'DB:UPDATE_COUNTER_VALUES', type: 'DB:UPDATE_COUNTER_VALUES',
payload, payload,
}) })
type FetchCounterValues = (?number) => (Dispatch<*>, Function) => Promise<any> export type FetchCounterValues = (?number) => (Dispatch<*>, Function) => Promise<any>
export const fetchCounterValues: FetchCounterValues = coinType => (dispatch, getState) => { export const fetchCounterValues: FetchCounterValues = coinType => (dispatch, getState) => {
const { accounts, counterValues } = getState() const { accounts, counterValues, settings } = getState()
const { counterValue } = settings
let coinTypes = [] let coinTypes = []
@ -36,7 +37,7 @@ export const fetchCounterValues: FetchCounterValues = coinType => (dispatch, get
const fetchCounterValuesByCoinType = coinType => { const fetchCounterValuesByCoinType = coinType => {
const { code } = getDefaultUnitByCoinType(coinType) const { code } = getDefaultUnitByCoinType(coinType)
const todayCounterValues = get(counterValues, `${code}-USD.${today}`, null) const todayCounterValues = get(counterValues, `${code}-${counterValue}.${today}`, null)
if (todayCounterValues !== null) { if (todayCounterValues !== null) {
return null return null
@ -44,10 +45,10 @@ export const fetchCounterValues: FetchCounterValues = coinType => (dispatch, get
return axios return axios
.get( .get(
`https://min-api.cryptocompare.com/data/histoday?&extraParams=ledger-test&fsym=${code}&tsym=USD&allData=1`, `https://min-api.cryptocompare.com/data/histoday?&extraParams=ledger-test&fsym=${code}&tsym=${counterValue}&allData=1`,
) )
.then(({ data }) => ({ .then(({ data }) => ({
symbol: `${code}-USD`, symbol: `${code}-${counterValue}`,
values: data.Data.reduce((result, d) => { values: data.Data.reduce((result, d) => {
const date = moment(d.time * 1000).format('YYYY-MM-DD') const date = moment(d.time * 1000).format('YYYY-MM-DD')
result[date] = d.close result[date] = d.close

10
src/components/AccountPage/index.js

@ -11,6 +11,7 @@ import { MODAL_SEND, MODAL_RECEIVE, MODAL_SETTINGS_ACCOUNT } from 'constants'
import type { T, Account } from 'types/common' import type { T, Account } from 'types/common'
import { getAccountById } from 'reducers/accounts' import { getAccountById } from 'reducers/accounts'
import { getCounterValue } from 'reducers/settings'
import { openModal } from 'reducers/modals' import { openModal } from 'reducers/modals'
import IconControls from 'icons/Controls' import IconControls from 'icons/Controls'
@ -33,6 +34,7 @@ import AccountHeader from './AccountHeader'
const mapStateToProps = (state, props) => ({ const mapStateToProps = (state, props) => ({
account: getAccountById(state, props.match.params.id), account: getAccountById(state, props.match.params.id),
counterValue: getCounterValue(state),
}) })
const mapDispatchToProps = { const mapDispatchToProps = {
@ -40,6 +42,7 @@ const mapDispatchToProps = {
} }
type Props = { type Props = {
counterValue: string,
t: T, t: T,
account?: Account, account?: Account,
openModal: Function, openModal: Function,
@ -63,7 +66,7 @@ class AccountPage extends PureComponent<Props, State> {
}) })
render() { render() {
const { account, openModal, t } = this.props const { account, openModal, t, counterValue } = this.props
const { selectedTime, daysCount } = this.state const { selectedTime, daysCount } = this.state
// Don't even throw if we jumped in wrong account route // Don't even throw if we jumped in wrong account route
@ -100,6 +103,7 @@ class AccountPage extends PureComponent<Props, State> {
</Box> </Box>
<Box mb={7}> <Box mb={7}>
<BalanceSummary <BalanceSummary
counterValue={counterValue}
chartColor={account.currency.color} chartColor={account.currency.color}
chartId={`account-chart-${account.id}`} chartId={`account-chart-${account.id}`}
accounts={[account]} accounts={[account]}
@ -113,7 +117,7 @@ class AccountPage extends PureComponent<Props, State> {
<FormattedVal <FormattedVal
alwaysShowSign={false} alwaysShowSign={false}
color="warmGrey" color="warmGrey"
fiat="USD" fiat={counterValue}
fontSize={6} fontSize={6}
showCode showCode
style={{ lineHeight: 1 }} style={{ lineHeight: 1 }}
@ -139,7 +143,7 @@ class AccountPage extends PureComponent<Props, State> {
/> />
<BalanceSinceDiff <BalanceSinceDiff
t={t} t={t}
fiat="USD" counterValue={counterValue}
alignItems="center" alignItems="center"
totalBalance={totalBalance} totalBalance={totalBalance}
sinceBalance={sinceBalance} sinceBalance={sinceBalance}

20
src/components/BalanceSummary/BalanceInfos.js

@ -28,13 +28,13 @@ type BalanceSinceProps = {
type BalanceTotalProps = { type BalanceTotalProps = {
children?: any, children?: any,
fiat?: string, counterValue?: string,
totalBalance: number, totalBalance: number,
unit?: Unit, unit?: Unit,
} }
type Props = { type Props = {
fiat: string, counterValue: string,
} & BalanceSinceProps } & BalanceSinceProps
export function BalanceSincePercent(props: BalanceSinceProps) { export function BalanceSincePercent(props: BalanceSinceProps) {
@ -53,11 +53,11 @@ export function BalanceSincePercent(props: BalanceSinceProps) {
} }
export function BalanceSinceDiff(props: Props) { export function BalanceSinceDiff(props: Props) {
const { t, totalBalance, sinceBalance, since, fiat, ...otherProps } = props const { t, totalBalance, sinceBalance, since, counterValue, ...otherProps } = props
return ( return (
<Box {...otherProps}> <Box {...otherProps}>
<FormattedVal <FormattedVal
fiat={fiat} fiat={counterValue}
alwaysShowSign alwaysShowSign
showCode showCode
val={totalBalance - sinceBalance} val={totalBalance - sinceBalance}
@ -69,13 +69,13 @@ export function BalanceSinceDiff(props: Props) {
} }
export function BalanceTotal(props: BalanceTotalProps) { export function BalanceTotal(props: BalanceTotalProps) {
const { fiat, totalBalance, children, unit } = props const { counterValue, totalBalance, children, unit } = props
return ( return (
<Box grow> <Box grow>
<FormattedVal <FormattedVal
alwaysShowSign={false} alwaysShowSign={false}
color="dark" color="dark"
fiat={fiat} fiat={counterValue}
fontSize={8} fontSize={8}
showCode showCode
style={{ lineHeight: 1 }} style={{ lineHeight: 1 }}
@ -88,16 +88,16 @@ export function BalanceTotal(props: BalanceTotalProps) {
} }
BalanceTotal.defaultProps = { BalanceTotal.defaultProps = {
fiat: undefined, counterValue: undefined,
children: null, children: null,
unit: undefined, unit: undefined,
} }
function BalanceInfos(props: Props) { function BalanceInfos(props: Props) {
const { t, fiat, totalBalance, since, sinceBalance, refBalance } = props const { t, totalBalance, since, sinceBalance, refBalance, counterValue } = props
return ( return (
<Box horizontal alignItems="flex-end" flow={7}> <Box horizontal alignItems="flex-end" flow={7}>
<BalanceTotal fiat={fiat} totalBalance={totalBalance}> <BalanceTotal counterValue={counterValue} totalBalance={totalBalance}>
<Sub>{t('dashboard:totalBalance')}</Sub> <Sub>{t('dashboard:totalBalance')}</Sub>
</BalanceTotal> </BalanceTotal>
<BalanceSincePercent <BalanceSincePercent
@ -109,7 +109,7 @@ function BalanceInfos(props: Props) {
t={t} t={t}
/> />
<BalanceSinceDiff <BalanceSinceDiff
fiat="USD" counterValue={counterValue}
alignItems="flex-end" alignItems="flex-end"
totalBalance={totalBalance} totalBalance={totalBalance}
sinceBalance={sinceBalance} sinceBalance={sinceBalance}

5
src/components/BalanceSummary/index.js

@ -38,6 +38,7 @@ function renderTickX(selectedTime) {
} }
type Props = { type Props = {
counterValue: string,
chartColor: string, chartColor: string,
chartId: string, chartId: string,
accounts: Accounts, accounts: Accounts,
@ -47,6 +48,7 @@ type Props = {
} }
const BalanceSummary = ({ const BalanceSummary = ({
counterValue,
chartColor, chartColor,
chartId, chartId,
accounts, accounts,
@ -54,10 +56,11 @@ const BalanceSummary = ({
daysCount, daysCount,
renderHeader, renderHeader,
}: Props) => { }: Props) => {
const unit = getFiatUnit('USD') const unit = getFiatUnit(counterValue)
return ( return (
<Card p={0} py={6}> <Card p={0} py={6}>
<CalculateBalance <CalculateBalance
counterValue={counterValue}
accounts={accounts} accounts={accounts}
daysCount={daysCount} daysCount={daysCount}
render={({ allBalances, totalBalance, sinceBalance, refBalance }) => ( render={({ allBalances, totalBalance, sinceBalance, refBalance }) => (

4
src/components/CalculateBalance.js

@ -15,7 +15,7 @@ const mapStateToProps = state => ({
counterValues: state.counterValues, counterValues: state.counterValues,
}) })
function calculateBalance(props) { function calculateBalance(props: Object) {
const interval = { const interval = {
start: moment() start: moment()
.subtract(props.daysCount, 'days') .subtract(props.daysCount, 'days')
@ -24,7 +24,7 @@ function calculateBalance(props) {
} }
const allBalances = getBalanceHistoryForAccounts({ const allBalances = getBalanceHistoryForAccounts({
fiat: 'USD', counterValue: props.counterValue,
accounts: props.accounts, accounts: props.accounts,
counterValues: props.counterValues, counterValues: props.counterValues,
interval, interval,

5
src/components/DashboardPage/AccountCard.js

@ -12,10 +12,12 @@ import CalculateBalance from 'components/CalculateBalance'
import FormattedVal from 'components/base/FormattedVal' import FormattedVal from 'components/base/FormattedVal'
const AccountCard = ({ const AccountCard = ({
counterValue,
account, account,
onClick, onClick,
daysCount, daysCount,
}: { }: {
counterValue: string,
account: Account, account: Account,
onClick: Function, onClick: Function,
daysCount: number, daysCount: number,
@ -57,6 +59,7 @@ const AccountCard = ({
</Box> </Box>
</Box> </Box>
<CalculateBalance <CalculateBalance
counterValue={counterValue}
accounts={[account]} accounts={[account]}
daysCount={daysCount} daysCount={daysCount}
render={({ allBalances, totalBalance, refBalance }) => ( render={({ allBalances, totalBalance, refBalance }) => (
@ -64,7 +67,7 @@ const AccountCard = ({
<Box flow={2} horizontal> <Box flow={2} horizontal>
<Box justifyContent="center"> <Box justifyContent="center">
<FormattedVal <FormattedVal
fiat="USD" fiat={counterValue}
val={totalBalance} val={totalBalance}
alwaysShowSign={false} alwaysShowSign={false}
showCode showCode

9
src/components/DashboardPage/index.js

@ -13,6 +13,7 @@ import sortBy from 'lodash/sortBy'
import type { Account, Accounts, T } from 'types/common' import type { Account, Accounts, T } from 'types/common'
import { getVisibleAccounts } from 'reducers/accounts' import { getVisibleAccounts } from 'reducers/accounts'
import { getCounterValue } from 'reducers/settings'
import { updateOrderAccounts } from 'actions/accounts' import { updateOrderAccounts } from 'actions/accounts'
import { saveSettings } from 'actions/settings' import { saveSettings } from 'actions/settings'
@ -29,6 +30,7 @@ import AccountsOrder from './AccountsOrder'
const mapStateToProps = state => ({ const mapStateToProps = state => ({
accounts: getVisibleAccounts(state), accounts: getVisibleAccounts(state),
counterValue: getCounterValue(state),
}) })
const mapDispatchToProps = { const mapDispatchToProps = {
@ -41,6 +43,7 @@ type Props = {
t: T, t: T,
accounts: Accounts, accounts: Accounts,
push: Function, push: Function,
counterValue: string,
} }
type State = { type State = {
@ -106,7 +109,7 @@ class DashboardPage extends PureComponent<Props, State> {
}) })
render() { render() {
const { push, accounts, t } = this.props const { push, accounts, t, counterValue } = this.props
const { accountsChunk, allTransactions, selectedTime, daysCount } = this.state const { accountsChunk, allTransactions, selectedTime, daysCount } = this.state
const totalAccounts = accounts.length const totalAccounts = accounts.length
@ -131,6 +134,7 @@ class DashboardPage extends PureComponent<Props, State> {
{totalAccounts > 0 && ( {totalAccounts > 0 && (
<Fragment> <Fragment>
<BalanceSummary <BalanceSummary
counterValue={counterValue}
chartId="dashboard-chart" chartId="dashboard-chart"
chartColor="#5286f7" chartColor="#5286f7"
accounts={accounts} accounts={accounts}
@ -139,7 +143,7 @@ class DashboardPage extends PureComponent<Props, State> {
renderHeader={({ totalBalance, selectedTime, sinceBalance, refBalance }) => ( renderHeader={({ totalBalance, selectedTime, sinceBalance, refBalance }) => (
<BalanceInfos <BalanceInfos
t={t} t={t}
fiat="USD" counterValue={counterValue}
totalBalance={totalBalance} totalBalance={totalBalance}
since={selectedTime} since={selectedTime}
sinceBalance={sinceBalance} sinceBalance={sinceBalance}
@ -173,6 +177,7 @@ class DashboardPage extends PureComponent<Props, State> {
/> />
) : ( ) : (
<AccountCard <AccountCard
counterValue={counterValue}
account={account} account={account}
daysCount={daysCount} daysCount={daysCount}
key={account.id} key={account.id}

88
src/components/SettingsPage/Money.js

@ -0,0 +1,88 @@
// @flow
import React, { PureComponent } from 'react'
import { getFiatUnit } from '@ledgerhq/currencies'
import type { SettingsMoney, T } from 'types/common'
import Box, { Card } from 'components/base/Box'
import Button from 'components/base/Button'
import Label from 'components/base/Label'
import Select from 'components/base/Select'
const counterValues = ['USD', 'EUR', 'JPY', 'GBP'].sort().map(c => {
const { name } = getFiatUnit(c)
return {
key: c,
name,
}
})
type InputValue = SettingsMoney
type Props = {
t: T,
settings: SettingsMoney,
onSaveSettings: Function,
}
type State = {
inputValue: InputValue,
}
class TabProfile extends PureComponent<Props, State> {
state = {
inputValue: {
counterValue: this.props.settings.counterValue,
},
}
handleChangeInput = (key: $Keys<InputValue>) => (value: $Values<InputValue>) =>
this.setState(prev => ({
inputValue: {
...prev.inputValue,
[key]: value,
},
}))
handleSubmit = (e: SyntheticEvent<HTMLFormElement>) => {
e.preventDefault()
const { onSaveSettings } = this.props
const { inputValue } = this.state
onSaveSettings({
...inputValue,
})
}
render() {
const { t } = this.props
const { inputValue } = this.state
const currentCounterValues = counterValues.find(l => l.key === inputValue.counterValue)
return (
<form onSubmit={this.handleSubmit}>
<Card flow={3}>
<Box flow={1}>
<Label>{t('settings:display.counterValue')}</Label>
<Select
onChange={item => this.handleChangeInput('counterValue')(item.key)}
renderSelected={item => item && item.name}
value={currentCounterValues}
items={counterValues}
/>
</Box>
<Box horizontal justifyContent="flex-end">
<Button primary type="submit">
{t('common:save')}
</Button>
</Box>
</Card>
</form>
)
}
}
export default TabProfile

16
src/components/SettingsPage/index.js

@ -7,8 +7,10 @@ import { translate } from 'react-i18next'
import type { Settings, T } from 'types/common' import type { Settings, T } from 'types/common'
import type { SaveSettings } from 'actions/settings' import type { SaveSettings } from 'actions/settings'
import type { FetchCounterValues } from 'actions/counterValues'
import { saveSettings } from 'actions/settings' import { saveSettings } from 'actions/settings'
import { fetchCounterValues } from 'actions/counterValues'
import Box from 'components/base/Box' import Box from 'components/base/Box'
import Text from 'components/base/Text' import Text from 'components/base/Text'
@ -16,12 +18,14 @@ import Tabs from 'components/base/Tabs'
import TabDisplay from './Display' import TabDisplay from './Display'
import TabProfile from './Profile' import TabProfile from './Profile'
import TabMoney from './Money'
const mapStateToProps = state => ({ const mapStateToProps = state => ({
settings: state.settings, settings: state.settings,
}) })
const mapDispatchToProps = { const mapDispatchToProps = {
fetchCounterValues,
saveSettings, saveSettings,
} }
@ -29,6 +33,7 @@ type Props = {
i18n: Object, i18n: Object,
saveSettings: SaveSettings, saveSettings: SaveSettings,
settings: Settings, settings: Settings,
fetchCounterValues: FetchCounterValues,
t: T, t: T,
} }
@ -44,13 +49,17 @@ class SettingsPage extends PureComponent<Props, State> {
handleChangeTab = (tab: number) => this.setState({ tab }) handleChangeTab = (tab: number) => this.setState({ tab })
handleSaveSettings = newSettings => { handleSaveSettings = newSettings => {
const { saveSettings, i18n, settings } = this.props const { fetchCounterValues, saveSettings, i18n, settings } = this.props
saveSettings(newSettings)
if (newSettings.language !== settings.language) { if (newSettings.language !== settings.language) {
i18n.changeLanguage(newSettings.language) i18n.changeLanguage(newSettings.language)
} }
saveSettings(newSettings) if (newSettings.counterValue !== settings.counterValue) {
fetchCounterValues()
}
} }
render() { render() {
@ -77,9 +86,8 @@ class SettingsPage extends PureComponent<Props, State> {
}, },
{ {
key: 'money', key: 'money',
isDisabled: true,
title: t('settings:tabs.money'), title: t('settings:tabs.money'),
render: () => <div>{'Monnaie'}</div>, render: () => <TabMoney {...props} />,
}, },
{ {
key: 'material', key: 'material',

8
src/helpers/__tests__/balance.test.js

@ -27,7 +27,7 @@ describe('helpers > balance', () => {
} }
const balances = getBalanceHistoryForAccount({ const balances = getBalanceHistoryForAccount({
fiat: 'USD', counterValue: 'USD',
account, account,
counterValues, counterValues,
interval, interval,
@ -54,7 +54,7 @@ describe('helpers > balance', () => {
} }
const balances = getBalanceHistoryForAccount({ const balances = getBalanceHistoryForAccount({
fiat: 'USD', counterValue: 'USD',
account, account,
counterValues, counterValues,
interval, interval,
@ -81,7 +81,7 @@ describe('helpers > balance', () => {
} }
const balances = getBalanceHistoryForAccount({ const balances = getBalanceHistoryForAccount({
fiat: 'USD', counterValue: 'USD',
account, account,
counterValues, counterValues,
interval, interval,
@ -118,7 +118,7 @@ describe('helpers > balance', () => {
} }
const balances = getBalanceHistoryForAccounts({ const balances = getBalanceHistoryForAccounts({
fiat: 'USD', counterValue: 'USD',
accounts: [account1, account2], accounts: [account1, account2],
counterValues, counterValues,
interval, interval,

12
src/helpers/balance.js

@ -49,17 +49,17 @@ function getBalanceAtIntervalStart(account: Account, interval: DateInterval): nu
export function getBalanceHistoryForAccount({ export function getBalanceHistoryForAccount({
account, account,
fiat, counterValue,
counterValues, counterValues,
interval, interval,
}: { }: {
fiat: string, counterValue: string,
account: Account, account: Account,
counterValues: Object, counterValues: Object,
interval: DateInterval, interval: DateInterval,
}): Array<BalanceHistoryDay> { }): Array<BalanceHistoryDay> {
const unit = getDefaultUnitByCoinType(account.coinType) const unit = getDefaultUnitByCoinType(account.coinType)
const counterVals = counterValues[`${unit.code}-${fiat}`] const counterVals = counterValues[`${unit.code}-${counterValue}`]
let lastBalance = getBalanceAtIntervalStart(account, interval) let lastBalance = getBalanceAtIntervalStart(account, interval)
return mapInterval(interval, date => { return mapInterval(interval, date => {
let balance = 0 let balance = 0
@ -84,11 +84,11 @@ export function getBalanceHistoryForAccount({
export function getBalanceHistoryForAccounts({ export function getBalanceHistoryForAccounts({
accounts, accounts,
fiat, counterValue,
counterValues, counterValues,
interval, interval,
}: { }: {
fiat: string, counterValue: string,
accounts: Accounts, accounts: Accounts,
counterValues: Object, counterValues: Object,
interval: DateInterval, interval: DateInterval,
@ -96,7 +96,7 @@ export function getBalanceHistoryForAccounts({
// calculate balance history for each account on the given interval // calculate balance history for each account on the given interval
const balances = accounts.map(account => const balances = accounts.map(account =>
getBalanceHistoryForAccount({ getBalanceHistoryForAccount({
fiat, counterValue,
account, account,
counterValues, counterValues,
interval, interval,

17
src/reducers/settings.js

@ -8,7 +8,8 @@ import type { Settings } from 'types/common'
export type SettingsState = Object export type SettingsState = Object
const state: SettingsState = { const defaultState: SettingsState = {
counterValue: 'USD',
language: 'en', language: 'en',
orderAccounts: 'balance|desc', orderAccounts: 'balance|desc',
password: { password: {
@ -16,6 +17,10 @@ const state: SettingsState = {
}, },
} }
const state: SettingsState = {
...defaultState,
}
const handlers: Object = { const handlers: Object = {
SAVE_SETTINGS: (state: SettingsState, { payload: settings }: { payload: Settings }) => ({ SAVE_SETTINGS: (state: SettingsState, { payload: settings }: { payload: Settings }) => ({
...state, ...state,
@ -27,8 +32,12 @@ const handlers: Object = {
}), }),
} }
export const hasPassword = (state: Object) => get(state.settings, 'password.state', false) export const hasPassword = (state: Object) =>
export const getLanguage = (state: Object) => get(state.settings, 'language', 'en') get(state.settings, 'password.state', defaultState.password.state)
export const getOrderAccounts = (state: Object) => get(state.settings, 'orderAccounts', 'balance') export const getCounterValue = (state: Object) =>
get(state.settings, 'counterValue', defaultState.counterValue)
export const getLanguage = (state: Object) => get(state.settings, 'language', defaultState.language)
export const getOrderAccounts = (state: Object) =>
get(state.settings, 'orderAccounts', defaultState.orderAccounts)
export default handleActions(handlers, state) export default handleActions(handlers, state)

5
src/types/common.js

@ -60,6 +60,9 @@ export type SettingsProfile = {
export type SettingsDisplay = { export type SettingsDisplay = {
language: string, language: string,
} }
export type Settings = SettingsProfile & SettingsDisplay export type SettingsMoney = {
counterValue: string,
}
export type Settings = SettingsProfile & SettingsDisplay & SettingsMoney
export type T = (string, ?Object) => string export type T = (string, ?Object) => string

1
static/i18n/en/settings.yml

@ -9,6 +9,7 @@ tabs:
profile: Profile profile: Profile
display: display:
language: Language language: Language
counterValue: Counter Value
orderAccounts: Order accounts orderAccounts: Order accounts
profile: profile:
protectWithPassword: Protect local data with a password protectWithPassword: Protect local data with a password

Loading…
Cancel
Save