diff options
author | Samuel Newman <mozzius@protonmail.com> | 2024-05-17 20:24:06 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-05-17 14:24:06 -0500 |
commit | dd0f57e3e3188389bc8ef364e81e4a00405a9a26 (patch) | |
tree | 0d7c2012685185e5a3e3fe942d45058e67e730dc /src/view/screens/Settings/index.tsx | |
parent | 115041f4bfa537579deb4b8aa92ddb200de4d48e (diff) | |
download | voidsky-dd0f57e3e3188389bc8ef364e81e4a00405a9a26.tar.zst |
[🐴] NUX (#4062)
* remove type assertion * DMs NUX * delete button for testing * tweak styles and copy * rm log * style tweaks * reduce amount of words * Fix not showing on first load * Spacing tweaks --------- Co-authored-by: Eric Bailey <git@esb.lol>
Diffstat (limited to 'src/view/screens/Settings/index.tsx')
-rw-r--r-- | src/view/screens/Settings/index.tsx | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/view/screens/Settings/index.tsx b/src/view/screens/Settings/index.tsx index c3864e5a9..b3b937c61 100644 --- a/src/view/screens/Settings/index.tsx +++ b/src/view/screens/Settings/index.tsx @@ -26,6 +26,7 @@ import { useInAppBrowser, useSetInAppBrowser, } from '#/state/preferences/in-app-browser' +import {useDeleteActorDeclaration} from '#/state/queries/messages/actor-declaration' import {useClearPreferencesMutation} from '#/state/queries/preferences' import {RQKEY as RQKEY_PROFILE} from '#/state/queries/profile' import {useProfileQuery} from '#/state/queries/profile' @@ -305,6 +306,8 @@ export function SettingsScreen({}: Props) { Toast.show(_(msg`Legacy storage cleared, you need to restart the app now.`)) }, [_]) + const {mutate: onPressDeleteChatDeclaration} = useDeleteActorDeclaration() + return ( <View style={s.hContentRegion} testID="settingsScreen"> <ExportCarDialog control={exportCarControl} /> @@ -828,6 +831,16 @@ export function SettingsScreen({}: Props) { </TouchableOpacity> <TouchableOpacity style={[pal.view, styles.linkCardNoIcon]} + onPress={() => onPressDeleteChatDeclaration()} + accessibilityRole="button" + accessibilityLabel={_(msg`Delete chat declaration record`)} + accessibilityHint={_(msg`Deletes the chat declaration record`)}> + <Text type="lg" style={pal.text}> + <Trans>Delete chat declaration record</Trans> + </Text> + </TouchableOpacity> + <TouchableOpacity + style={[pal.view, styles.linkCardNoIcon]} onPress={onPressResetOnboarding} accessibilityRole="button" accessibilityLabel={_(msg`Reset onboarding state`)} |