Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions src/components/Dropdown/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ const DropdownComponent: <T>(
accessibilityLabel,
itemAccessibilityLabelField,
mode = 'default',
keyboardType
} = props;

const ref = useRef<View>(null);
Expand Down Expand Up @@ -490,6 +491,7 @@ const DropdownComponent: <T>(
}}
placeholderTextColor="gray"
iconStyle={[{ tintColor: iconColor }, iconStyle]}
keyboardType={keyboardType}
/>
);
}
Expand All @@ -508,6 +510,7 @@ const DropdownComponent: <T>(
searchPlaceholder,
testID,
searchText,
keyboardType
]);

const _renderList = useCallback(
Expand Down
2 changes: 2 additions & 0 deletions src/components/Dropdown/model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import type {
TextProps,
ImageStyle,
FlatListProps,
KeyboardType
} from 'react-native';

export type IDropdownRef = {
Expand Down Expand Up @@ -66,4 +67,5 @@ export interface DropdownProps<T> {
searchQuery?: (keyword: string, labelValue: string) => boolean;
onChangeText?: (search: string) => void;
onConfirmSelectItem?: (item: T) => void;
keyboardType?: KeyboardType;
}
2 changes: 2 additions & 0 deletions src/components/TextInput/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ const TextInputComponent: CTextInput = (props) => {
onChangeText = (_value: string) => {},
renderLeftIcon,
renderRightIcon,
keyboardType
} = props;

const [text, setText] = useState<string>('');
Expand Down Expand Up @@ -91,6 +92,7 @@ const TextInputComponent: CTextInput = (props) => {
placeholder={placeholder}
placeholderTextColor={placeholderTextColor}
onChangeText={onChange}
keyboardType={keyboardType}
/>
{_renderRightIcon()}
</View>
Expand Down