From 55825c4f2637765f690cbc5068c8358e82cd9509 Mon Sep 17 00:00:00 2001 From: Eric Bailey Date: Wed, 21 Jan 2026 21:20:58 -0600 Subject: [PATCH] Fix TODO --- src/lib/hooks/useAppState.ts | 6 ------ src/screens/Messages/ChatList.tsx | 2 +- src/screens/Messages/Inbox.tsx | 2 +- src/screens/PostThread/components/GrowthHack.tsx | 2 +- src/screens/Settings/NotificationSettings/index.tsx | 2 +- src/state/messages/convo/index.tsx | 2 +- src/view/com/composer/Composer.tsx | 2 +- 7 files changed, 6 insertions(+), 12 deletions(-) delete mode 100644 src/lib/hooks/useAppState.ts diff --git a/src/lib/hooks/useAppState.ts b/src/lib/hooks/useAppState.ts deleted file mode 100644 index 58290ca322..0000000000 --- a/src/lib/hooks/useAppState.ts +++ /dev/null @@ -1,6 +0,0 @@ -import {useAppState as useAppStateBase} from '#/lib/appState' - -/** - * @deprecated use `useAppState` from `#/lib/appState` instead - */ -export const useAppState = useAppStateBase diff --git a/src/screens/Messages/ChatList.tsx b/src/screens/Messages/ChatList.tsx index 9231748106..caa8aa552b 100644 --- a/src/screens/Messages/ChatList.tsx +++ b/src/screens/Messages/ChatList.tsx @@ -7,7 +7,7 @@ import {useLingui} from '@lingui/react' import {useFocusEffect, useIsFocused} from '@react-navigation/native' import {type NativeStackScreenProps} from '@react-navigation/native-stack' -import {useAppState} from '#/lib/hooks/useAppState' +import {useAppState} from '#/lib/appState' import {useInitialNumToRender} from '#/lib/hooks/useInitialNumToRender' import {useRequireEmailVerification} from '#/lib/hooks/useRequireEmailVerification' import {type MessagesTabNavigatorParams} from '#/lib/routes/types' diff --git a/src/screens/Messages/Inbox.tsx b/src/screens/Messages/Inbox.tsx index 818ee3d57f..ce4f32686a 100644 --- a/src/screens/Messages/Inbox.tsx +++ b/src/screens/Messages/Inbox.tsx @@ -12,7 +12,7 @@ import { type UseInfiniteQueryResult, } from '@tanstack/react-query' -import {useAppState} from '#/lib/hooks/useAppState' +import {useAppState} from '#/lib/appState' import {useInitialNumToRender} from '#/lib/hooks/useInitialNumToRender' import { type CommonNavigatorParams, diff --git a/src/screens/PostThread/components/GrowthHack.tsx b/src/screens/PostThread/components/GrowthHack.tsx index 4852cb2312..9701c2474d 100644 --- a/src/screens/PostThread/components/GrowthHack.tsx +++ b/src/screens/PostThread/components/GrowthHack.tsx @@ -2,7 +2,7 @@ import {useState} from 'react' import {View} from 'react-native' import {PrivacySensitive} from 'expo-privacy-sensitive' -import {useAppState} from '#/lib/hooks/useAppState' +import {useAppState} from '#/lib/appState' import {atoms as a, useTheme} from '#/alf' import {sizes as iconSizes} from '#/components/icons/common' import {Mark as Logo} from '#/components/icons/Logo' diff --git a/src/screens/Settings/NotificationSettings/index.tsx b/src/screens/Settings/NotificationSettings/index.tsx index 6439fc263a..f6d1c708ba 100644 --- a/src/screens/Settings/NotificationSettings/index.tsx +++ b/src/screens/Settings/NotificationSettings/index.tsx @@ -6,7 +6,7 @@ import {msg, Trans} from '@lingui/macro' import {useLingui} from '@lingui/react' import {useQuery, useQueryClient} from '@tanstack/react-query' -import {useAppState} from '#/lib/hooks/useAppState' +import {useAppState} from '#/lib/appState' import { type AllNavigatorParams, type NativeStackScreenProps, diff --git a/src/state/messages/convo/index.tsx b/src/state/messages/convo/index.tsx index d9ce19fdb3..1d38e037e7 100644 --- a/src/state/messages/convo/index.tsx +++ b/src/state/messages/convo/index.tsx @@ -3,7 +3,7 @@ import {type ChatBskyConvoDefs} from '@atproto/api' import {useFocusEffect} from '@react-navigation/native' import {useQueryClient} from '@tanstack/react-query' -import {useAppState} from '#/lib/hooks/useAppState' +import {useAppState} from '#/lib/appState' import {Convo} from '#/state/messages/convo/agent' import { type ConvoParams, diff --git a/src/view/com/composer/Composer.tsx b/src/view/com/composer/Composer.tsx index e41da9b4e1..f7d76558b3 100644 --- a/src/view/com/composer/Composer.tsx +++ b/src/view/com/composer/Composer.tsx @@ -58,6 +58,7 @@ import {useQueryClient} from '@tanstack/react-query' import * as apilib from '#/lib/api/index' import {EmbeddingDisabledError} from '#/lib/api/resolve' +import {useAppState} from '#/lib/appState' import {retry} from '#/lib/async/retry' import {until} from '#/lib/async/until' import { @@ -65,7 +66,6 @@ import { SUPPORTED_MIME_TYPES, type SupportedMimeTypes, } from '#/lib/constants' -import {useAppState} from '#/lib/hooks/useAppState' import {useIsKeyboardVisible} from '#/lib/hooks/useIsKeyboardVisible' import {useNonReactiveCallback} from '#/lib/hooks/useNonReactiveCallback' import {usePalette} from '#/lib/hooks/usePalette'