From 4c7850f8c48a0cb3f83f33b1701a99066c6b31db Mon Sep 17 00:00:00 2001 From: Ansh Date: Thu, 9 Nov 2023 10:04:16 -0800 Subject: Internationalization & localization (#1822) * install and setup lingui * setup dynamic locale activation and async loading * first pass of automated replacement of text messages * add some more documentaton * fix nits * add `es` and `hi`locales for testing purposes * make accessibilityLabel localized * compile and extract new messages * fix merge conflicts * fix eslint warning * change instructions from sending email to opening PR * fix comments --- src/view/screens/PreferencesThreads.tsx | 31 ++++++++++++++++++++----------- 1 file changed, 20 insertions(+), 11 deletions(-) (limited to 'src/view/screens/PreferencesThreads.tsx') diff --git a/src/view/screens/PreferencesThreads.tsx b/src/view/screens/PreferencesThreads.tsx index af98a1833..8a2db13ce 100644 --- a/src/view/screens/PreferencesThreads.tsx +++ b/src/view/screens/PreferencesThreads.tsx @@ -12,6 +12,8 @@ import {RadioGroup} from 'view/com/util/forms/RadioGroup' import {CommonNavigatorParams, NativeStackScreenProps} from 'lib/routes/types' import {ViewHeader} from 'view/com/util/ViewHeader' import {CenteredView} from 'view/com/util/Views' +import {Trans, msg} from '@lingui/macro' +import {useLingui} from '@lingui/react' type Props = NativeStackScreenProps export const PreferencesThreads = observer(function PreferencesThreadsImpl({ @@ -19,6 +21,7 @@ export const PreferencesThreads = observer(function PreferencesThreadsImpl({ }: Props) { const pal = usePalette('default') const store = useStores() + const {_} = useLingui() const {isTabletOrDesktop} = useWebMediaQueries() return ( @@ -37,7 +40,7 @@ export const PreferencesThreads = observer(function PreferencesThreadsImpl({ isTabletOrDesktop && {paddingTop: 20, paddingBottom: 20}, ]}> - Fine-tune the discussion threads. + Fine-tune the discussion threads. @@ -45,10 +48,10 @@ export const PreferencesThreads = observer(function PreferencesThreadsImpl({ - Sort Replies + Sort Replies - Sort replies to the same post by: + Sort replies to the same post by: - Prioritize Your Follows + Prioritize Your Follows - Show replies by people you follow before all other replies. + + Show replies by people you follow before all other replies. + - Threaded - Mode + {' '} + Threaded Mode - Set this setting to "Yes" to show replies in a threaded view. This - is an experimental feature. + + Set this setting to "Yes" to show replies in a threaded view. + This is an experimental feature. + - Done + + Done + -- cgit 1.4.1