From fb0a4022920892783bb7b5c76889ef2a94b26e00 Mon Sep 17 00:00:00 2001 From: Taso Date: Wed, 6 Jan 2021 03:24:56 -0500 Subject: [PATCH] Feat: Added locales for Settings --- .../apps/settings/components/SettingsApp.tsx | 17 ++++++++++------- phone/src/locale/en.json | 10 +++++++++- 2 files changed, 19 insertions(+), 8 deletions(-) diff --git a/phone/src/apps/settings/components/SettingsApp.tsx b/phone/src/apps/settings/components/SettingsApp.tsx index f8071ca..df6aeef 100644 --- a/phone/src/apps/settings/components/SettingsApp.tsx +++ b/phone/src/apps/settings/components/SettingsApp.tsx @@ -12,6 +12,7 @@ import { List } from '../../../ui/components/List'; import { useSimcard } from '../../../os/simcard/hooks/useSimcard'; import { useApp } from '../../../os/apps/hooks/useApps'; import { SettingItem } from './SettingItem'; +import { useTranslation } from "react-i18next"; import { Brush, @@ -37,6 +38,8 @@ export const SettingsApp = () => { const { setSettings, settings } = useSettings(); const simcard = useSimcard(); + const { t } = useTranslation() + const wallpapers = config.wallpapers.map( MapStringOptions(settings.wallpaper, (val: string) => setSettings('wallpaper', val) @@ -71,12 +74,12 @@ export const SettingsApp = () => { }> } /> { // * Probably want to make it a slider in the future. Ignore hardcoded for the meantime } { }> } /> } /> } />