Skip to content

Commit

Permalink
feat: move language settings into their own category
Browse files Browse the repository at this point in the history
  • Loading branch information
Rexogamer committed Nov 12, 2023
1 parent e5d318c commit 582220a
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/Generic.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ export const app = {
{
key: 'app.language',
name: 'Language',
category: 'functionality',
category: 'i18n',
default: 'en',
type: 'string',
options: Object.keys(languages),
Expand Down
22 changes: 22 additions & 0 deletions src/components/sheets/SettingsSheet.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,21 @@ export const SettingsSheet = observer(({setState}: {setState: Function}) => {
</View>
<Text>Features</Text>
</ContextButton>
<ContextButton
style={{flex: 1, marginBottom: 10}}
backgroundColor={currentTheme.backgroundSecondary}
onPress={() => {
setSection('i18n');
}}>
<View style={styles.iconContainer}>
<MaterialIcon
name={'translate'}
color={currentTheme.foregroundPrimary}
size={20}
/>
</View>
<Text>Language</Text>
</ContextButton>
<Text type={'header'}>Advanced</Text>
<ContextButton
style={{flex: 1, marginBottom: 10}}
Expand Down Expand Up @@ -248,6 +263,13 @@ export const SettingsSheet = observer(({setState}: {setState: Function}) => {
renderCount={renderCount}
rerender={rerender}
/>
) : section === 'i18n' ? (
<SettingsCategory
category={'i18n'}
friendlyName={'Language'}
renderCount={renderCount}
rerender={rerender}
/>
) : section === 'account' ? (
<View>
<Text type={'header'}>Account</Text>
Expand Down

0 comments on commit 582220a

Please sign in to comment.