aboutsummaryrefslogtreecommitdiff
path: root/src/components/onboarding/TaggBigInput.tsx
diff options
context:
space:
mode:
authorIvan Chen <ivan@tagg.id>2021-01-22 18:07:16 -0500
committerIvan Chen <ivan@tagg.id>2021-01-22 18:07:16 -0500
commitd31f8c3ad157f4637a37ce83ee16bdba048126f8 (patch)
tree9dfe8b15c69ac9162b360d54fb846ba039a517b1 /src/components/onboarding/TaggBigInput.tsx
parentad321571af78b5ea58a8e3e35820d5c3cf1c607b (diff)
parent8fa77a7e5b73687c9b4f7480dc706498ef8e61ec (diff)
Merge branch 'master' into tma552-adjust-styles-and-sizes
# Conflicts: # src/screens/profile/MomentCommentsScreen.tsx
Diffstat (limited to 'src/components/onboarding/TaggBigInput.tsx')
-rw-r--r--src/components/onboarding/TaggBigInput.tsx16
1 files changed, 12 insertions, 4 deletions
diff --git a/src/components/onboarding/TaggBigInput.tsx b/src/components/onboarding/TaggBigInput.tsx
index 4e8e1ef7..4212afd1 100644
--- a/src/components/onboarding/TaggBigInput.tsx
+++ b/src/components/onboarding/TaggBigInput.tsx
@@ -1,22 +1,30 @@
import React from 'react';
-import {View, TextInput, StyleSheet, TextInputProps} from 'react-native';
+import {
+ View,
+ TextInput,
+ StyleSheet,
+ TextInputProps,
+ ViewStyle,
+} from 'react-native';
import * as Animatable from 'react-native-animatable';
-import {TAGG_LIGHT_PURPLE} from '../../constants';
+import { TAGG_LIGHT_PURPLE } from '../../constants';
interface TaggBigInputProps extends TextInputProps {
valid?: boolean;
invalidWarning?: string;
attemptedSubmit?: boolean;
width?: number | string;
+ containerStyle?: ViewStyle;
}
/**
* An input component that receives all props a normal TextInput component does. TaggInput components grow to 60% of their parent's width by default, but this can be set using the `width` prop.
*/
const TaggBigInput = React.forwardRef((props: TaggBigInputProps, ref: any) => {
return (
- <View style={styles.container}>
+ <View
+ style={props.containerStyle ? props.containerStyle : styles.container}>
<TextInput
- style={[{width: props.width}, styles.input]}
+ style={[{ width: props.width }, styles.input]}
placeholderTextColor="#ddd"
clearButtonMode="while-editing"
ref={ref}