aboutsummaryrefslogtreecommitdiff
path: root/src/screens/chat
diff options
context:
space:
mode:
authorIvan Chen <ivan@tagg.id>2021-05-21 21:47:43 -0400
committerGitHub <noreply@github.com>2021-05-21 21:47:43 -0400
commit5afdf9208fd3d7498a2595797e6c9fb5f567fc61 (patch)
treeb76d16e06c0fb5f89a3da9ffa44eddec71f9d52c /src/screens/chat
parent83802c3a18b1a1406cb4f1336b91e477161e7340 (diff)
parentdcbe315638f6c5edc98415d6cec2a016bfc601bf (diff)
Merge pull request #436 from shravyaramesh/tma853-tag-selection-screen
[TMA-853] Tag selection screen
Diffstat (limited to 'src/screens/chat')
-rw-r--r--src/screens/chat/ChatScreen.tsx3
-rw-r--r--src/screens/chat/ChatSearchBar.tsx14
-rw-r--r--src/screens/chat/NewChatModal.tsx1
3 files changed, 13 insertions, 5 deletions
diff --git a/src/screens/chat/ChatScreen.tsx b/src/screens/chat/ChatScreen.tsx
index 17618867..8991d65b 100644
--- a/src/screens/chat/ChatScreen.tsx
+++ b/src/screens/chat/ChatScreen.tsx
@@ -21,6 +21,7 @@ import {
MessageFooter,
TypingIndicator,
} from '../../components';
+import {TAGG_LIGHT_BLUE_2} from '../../constants/constants';
import {MainStackParams} from '../../routes';
import {ScreenType} from '../../types';
import {HeaderHeight, normalize, SCREEN_WIDTH} from '../../utils';
@@ -38,7 +39,7 @@ const ChatScreen: React.FC<ChatScreenProps> = ({navigation}) => {
const insets = useSafeAreaInsets();
const chatTheme: DeepPartial<Theme> = {
colors: {
- accent_blue: '#6EE7E7',
+ accent_blue: TAGG_LIGHT_BLUE_2,
},
messageList: {
container: {
diff --git a/src/screens/chat/ChatSearchBar.tsx b/src/screens/chat/ChatSearchBar.tsx
index 91018d4c..1c91f493 100644
--- a/src/screens/chat/ChatSearchBar.tsx
+++ b/src/screens/chat/ChatSearchBar.tsx
@@ -17,6 +17,7 @@ interface SearchBarProps extends TextInputProps {
onCancel: () => void;
searching: boolean;
placeholder: string;
+ label?: string;
}
const ChatSearchBar: React.FC<SearchBarProps> = ({
onFocus,
@@ -26,6 +27,7 @@ const ChatSearchBar: React.FC<SearchBarProps> = ({
onCancel,
onLayout,
placeholder,
+ label,
}) => {
const handleSubmit = (
e: NativeSyntheticEvent<TextInputSubmitEditingEventData>,
@@ -34,14 +36,18 @@ const ChatSearchBar: React.FC<SearchBarProps> = ({
Keyboard.dismiss();
};
+ const extraLabelStyle = {paddingLeft: label ? 0 : 10};
+
return (
<View style={styles.container} onLayout={onLayout}>
<Animated.View style={styles.inputContainer}>
- <Animated.View style={styles.searchTextContainer}>
- <Text style={styles.searchTextStyes}>To:</Text>
- </Animated.View>
+ {label && (
+ <Animated.View style={styles.searchTextContainer}>
+ <Text style={styles.searchTextStyes}>{label}</Text>
+ </Animated.View>
+ )}
<TextInput
- style={styles.input}
+ style={[extraLabelStyle, styles.input]}
placeholderTextColor={'#828282'}
onSubmitEditing={handleSubmit}
clearButtonMode="always"
diff --git a/src/screens/chat/NewChatModal.tsx b/src/screens/chat/NewChatModal.tsx
index 9872dd6f..e57e7f7a 100644
--- a/src/screens/chat/NewChatModal.tsx
+++ b/src/screens/chat/NewChatModal.tsx
@@ -98,6 +98,7 @@ const NewChatModal: React.FC<NewChatModalProps> = ({
value={query}
searching={searching}
placeholder={''}
+ label={'To:'}
/>
{results.length > 0 && (
<View style={styles.headerContainerStyles}>