Merge branch 'main' into inherit_system_theme

This commit is contained in:
Jaz 2023-05-30 18:25:29 -07:00 committed by GitHub
commit 09ade363fd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
136 changed files with 5771 additions and 2428 deletions

View file

@ -142,6 +142,11 @@ export const SettingsScreen = withAuthRequired(
store.shell.openModal({name: 'delete-account'})
}, [store])
const onPressResetPreferences = React.useCallback(async () => {
await store.preferences.reset()
Toast.show('Preferences reset')
}, [store])
return (
<View style={[s.hContentRegion]} testID="settingsScreen">
<ViewHeader title="Settings" />
@ -330,6 +335,22 @@ export const SettingsScreen = withAuthRequired(
App passwords
</Text>
</Link>
<Link
testID="savedFeedsBtn"
style={[styles.linkCard, pal.view, isSwitching && styles.dimmed]}
accessibilityHint="Saved Feeds"
accessibilityLabel="Opens screen with all saved feeds"
href="/settings/saved-feeds">
<View style={[styles.iconContainer, pal.btn]}>
<FontAwesomeIcon
icon="satellite-dish"
style={pal.text as FontAwesomeIconStyle}
/>
</View>
<Text type="lg" style={pal.text}>
Saved Feeds
</Text>
</Link>
<TouchableOpacity
testID="contentLanguagesBtn"
style={[styles.linkCard, pal.view, isSwitching && styles.dimmed]}
@ -406,8 +427,18 @@ export const SettingsScreen = withAuthRequired(
Storybook
</Text>
</Link>
{__DEV__ ? (
<Link
style={[pal.view, styles.linkCardNoIcon]}
onPress={onPressResetPreferences}
title="Debug tools">
<Text type="lg" style={pal.text}>
Reset preferences state
</Text>
</Link>
) : null}
<Text type="sm" style={[styles.buildInfo, pal.textLight]}>
Build version {AppInfo.appVersion} ({AppInfo.buildVersion})
Build version {AppInfo.appVersion}
</Text>
<View style={s.footerSpacer} />
</ScrollView>