diff options
author | Hailey <me@haileyok.com> | 2024-04-29 23:34:26 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-04-29 23:34:26 -0700 |
commit | eb8bfd11d14a87983b210bea4a619d2dd7c51cdf (patch) | |
tree | 6f322f86ba92e989570daa1ada94ad5f10258506 /src/screens/Messages/Conversation/index.tsx | |
parent | 5d19f27052ebd3642db58742f7efaaee0b3a6720 (diff) | |
download | voidsky-eb8bfd11d14a87983b210bea4a619d2dd7c51cdf.tar.zst |
[Clipclops] Add screen to view and send clip clops (#3754)
* add new routes with placeholder screens * add clops list * add a clop input * add some better padding to the clops * some more adjustments * add rnkc * implement rnkc * implement rnkc * be a little less weird about it * rename clop stuff * rename more clop * one more * [Clipclops] Temp codegenerated lexicon (#3749) * add codegenerated lexicon * replace hailey's types * use codegen'd types in components * fix error + throw if fetch failed * remove bad imports * update messageslist and messageitem * import useState * add clop service URL hook * add dm service url storage * use context * use context for service url (temp) * remove log * nits --------- Co-authored-by: Samuel Newman <mozzius@protonmail.com>
Diffstat (limited to 'src/screens/Messages/Conversation/index.tsx')
-rw-r--r-- | src/screens/Messages/Conversation/index.tsx | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/screens/Messages/Conversation/index.tsx b/src/screens/Messages/Conversation/index.tsx index 239425a2f..efa64f5f8 100644 --- a/src/screens/Messages/Conversation/index.tsx +++ b/src/screens/Messages/Conversation/index.tsx @@ -1,5 +1,4 @@ import React from 'react' -import {View} from 'react-native' import {msg} from '@lingui/macro' import {useLingui} from '@lingui/react' import {NativeStackScreenProps} from '@react-navigation/native-stack' @@ -7,6 +6,8 @@ import {NativeStackScreenProps} from '@react-navigation/native-stack' import {CommonNavigatorParams} from '#/lib/routes/types' import {useGate} from '#/lib/statsig/statsig' import {ViewHeader} from '#/view/com/util/ViewHeader' +import {CenteredView} from 'view/com/util/Views' +import {MessagesList} from '#/screens/Messages/Conversation/MessagesList' import {ClipClopGate} from '../gate' type Props = NativeStackScreenProps< @@ -16,17 +17,18 @@ type Props = NativeStackScreenProps< export function MessagesConversationScreen({route}: Props) { const chatId = route.params.conversation const {_} = useLingui() - const gate = useGate() + if (!gate('dms')) return <ClipClopGate /> return ( - <View> + <CenteredView style={{flex: 1}} sideBorders> <ViewHeader title={_(msg`Chat with ${chatId}`)} showOnDesktop showBorder /> - </View> + <MessagesList chatId={chatId} /> + </CenteredView> ) } |