···
import { Message } from "@/components/Chat/Message";
import { Loading } from "@/components/primitives/Loading";
import { Text } from "@/components/primitives/Text";
4
+
import { useFacet } from "@/lib/facet";
import { useChannel } from "@/lib/hooks/useChannel";
import type { AtUri } from "@/lib/types/atproto";
import { useProfile } from "@/providers/authed/ProfileProvider";
import { useCurrentPalette } from "@/providers/ThemeProvider";
9
+
import { ArrowUp } from "lucide-react-native";
import { useState } from "react";
···
const { messages, sendMessageToChannel, isConnected } =
useChannel(channelAtUri);
const { semantic } = useCurrentPalette();
24
+
const { typography, atoms } = useFacet();
const handleSend = () => {
···
justifyContent: "space-between",
53
-
borderBottomColor: semantic.border,
55
+
borderBottomColor: semantic.borderVariant,
···
65
-
borderRadius: 2000000000,
67
+
borderRadius: atoms.radii.full,
source={{ uri: profile.avatar }}
···
77
-
borderBottomColor: semantic.border,
79
+
borderBottomColor: semantic.borderVariant,
···
94
+
data={messages.toReversed()}
renderItem={({ item }) => <Message message={item} />}
94
-
keyExtractor={(item, index) => index.toString()}
96
+
keyExtractor={(_, index) => index.toString()}
102
+
showsVerticalScrollIndicator={false}
106
-
borderTopColor: semantic.border,
109
+
alignItems: "center",
113
-
borderColor: semantic.border,
115
-
paddingHorizontal: 12,
116
-
paddingVertical: 8,
119
-
color: semantic.text,
117
+
borderColor: semantic.border,
119
+
paddingHorizontal: 12,
120
+
paddingVertical: 10,
122
+
color: semantic.text,
125
+
typography.sizes.base,
onChangeText={setInputText}
placeholderTextColor={semantic.textTertiary}
onSubmitEditing={handleSend}
132
+
// eslint-disable-next-line @typescript-eslint/no-deprecated -- can't get it working with the new prop.
133
+
blurOnSubmit={false}
129
-
backgroundColor: semantic.primary,
130
-
paddingHorizontal: 20,
131
-
paddingVertical: 10,
137
+
backgroundColor: inputText.trim()
140
+
borderRadius: atoms.radii.full,
justifyContent: "center",
144
+
alignItems: "center",
140
-
color: semantic.textInverse,
149
+
<ArrowUp height={20} width={20} />