about summary refs log tree commit diff
path: root/src/screens/Messages/List/index.tsx
diff options
context:
space:
mode:
Diffstat (limited to 'src/screens/Messages/List/index.tsx')
-rw-r--r--src/screens/Messages/List/index.tsx42
1 files changed, 0 insertions, 42 deletions
diff --git a/src/screens/Messages/List/index.tsx b/src/screens/Messages/List/index.tsx
index 5c9b93fcd..6300a976b 100644
--- a/src/screens/Messages/List/index.tsx
+++ b/src/screens/Messages/List/index.tsx
@@ -4,7 +4,6 @@ import {ChatBskyConvoDefs} from '@atproto/api'
 import {msg, Trans} from '@lingui/macro'
 import {useLingui} from '@lingui/react'
 import {NativeStackScreenProps} from '@react-navigation/native-stack'
-import {sha256} from 'js-sha256'
 
 import {useInitialNumToRender} from '#/lib/hooks/useInitialNumToRender'
 import {MessagesTabNavigatorParams} from '#/lib/routes/types'
@@ -15,12 +14,10 @@ import {useListConvos} from '#/state/queries/messages/list-converations'
 import {List} from '#/view/com/util/List'
 import {ViewHeader} from '#/view/com/util/ViewHeader'
 import {CenteredView} from '#/view/com/util/Views'
-import {ScrollView} from '#/view/com/util/Views'
 import {atoms as a, useBreakpoints, useTheme} from '#/alf'
 import {Button, ButtonIcon, ButtonText} from '#/components/Button'
 import {DialogControlProps, useDialogControl} from '#/components/Dialog'
 import {NewChat} from '#/components/dms/NewChat'
-import * as TextField from '#/components/forms/TextField'
 import {useRefreshOnFocus} from '#/components/hooks/useRefreshOnFocus'
 import {PlusLarge_Stroke2_Corner0_Rounded as Plus} from '#/components/icons/Plus'
 import {SettingsSliderVertical_Stroke2_Corner0_Rounded as SettingsSlider} from '#/components/icons/SettingsSlider'
@@ -28,7 +25,6 @@ import {Link} from '#/components/Link'
 import {ListFooter, ListMaybePlaceholder} from '#/components/Lists'
 import {Text} from '#/components/Typography'
 import {ClipClopGate} from '../gate'
-import {useDmServiceUrlStorage} from '../Temp/useDmServiceUrlStorage'
 import {ChatListItem} from './ChatListItem'
 
 type Props = NativeStackScreenProps<MessagesTabNavigatorParams, 'Messages'>
@@ -54,17 +50,6 @@ export function MessagesScreen({navigation, route}: Props) {
   const {gtMobile} = useBreakpoints()
   const pushToConversation = route.params?.pushToConversation
 
-  // TEMP
-  const {serviceUrl, setServiceUrl} = useDmServiceUrlStorage()
-  const [serviceUrlValue, setServiceUrlValue] = useState(serviceUrl)
-  const hasValidServiceUrl = useMemo(() => {
-    const hash = sha256(serviceUrl)
-    return (
-      hash ===
-      'a32318b49dd3fe6aa6a35c66c13fcc4c1cb6202b24f5a852d9a2279acee4169f'
-    )
-  }, [serviceUrl])
-
   // Whenever we have `pushToConversation` set, it means we pressed a notification for a chat without being on
   // this tab. We should immediately push to the conversation after pressing the notification.
   // After we push, reset with `setParams` so that this effect will fire next time we press a notification, even if
@@ -145,33 +130,6 @@ export function MessagesScreen({navigation, route}: Props) {
   const gate = useGate()
   if (!gate('dms')) return <ClipClopGate />
 
-  if (!hasValidServiceUrl) {
-    return (
-      <ScrollView contentContainerStyle={a.p_lg}>
-        <View>
-          <TextField.LabelText>Service URL</TextField.LabelText>
-          <TextField.Root>
-            <TextField.Input
-              value={serviceUrlValue}
-              onChangeText={text => setServiceUrlValue(text)}
-              autoCapitalize="none"
-              keyboardType="url"
-              label="https://"
-            />
-          </TextField.Root>
-          <Button
-            label="Set Service URL"
-            size="small"
-            variant="solid"
-            color="primary"
-            onPress={() => setServiceUrl(serviceUrlValue)}>
-            <ButtonText>Set</ButtonText>
-          </Button>
-        </View>
-      </ScrollView>
-    )
-  }
-
   if (conversations.length < 1) {
     return (
       <View style={a.flex_1}>