Preparing search index...

    Props for the TextInputWithDropDown component

    type TextInputWithDropDownType = {
        referenceTextArray: string[];
        value?: string;
        label?: string;
        mode?: "flat" | "outlined";
        dense?: boolean;
        onChangeText?: (newText: string) => void;
        onValidate?: (newText: string) => void;
        onSelect?: (selectedText: string) => void;
        testID: string;
        style?: StyleProp<ViewStyle>;
        contentStyle?: StyleProp<TextStyle>;
        textInputStyle?: StyleProp<TextStyle>;
        right?: React.ReactNode;
        onFocus?: () => void;
        renderLayout?: (
            field: React.ReactElement,
            dropdown: React.ReactElement | null,
        ) => React.ReactNode;
        onBlur?: () => void;
    }
    Index
    referenceTextArray: string[]

    Array of reference strings to filter and display as suggestions

    value?: string

    Current value of the text input

    label?: string

    Label text displayed above the input

    mode?: "flat" | "outlined"

    Display mode: outlined or flat (default: 'outlined')

    dense?: boolean

    Whether to use dense styling (default: false)

    onChangeText?: (newText: string) => void

    Live-commit callback fired on every keystroke. Use this to keep an external store (e.g. react-hook-form) in sync with what the user is currently typing, without waiting for blur. Optional — consumers that only need a final "submit/select" event can rely on onValidate.

    onValidate?: (newText: string) => void

    Callback fired when the text is validated (submitted via end-editing or selected from the dropdown). Use this for semantic commit operations (e.g. adding to an array, fuzzy-matching against a DB).

    onSelect?: (selectedText: string) => void

    Callback fired ONLY when an item is picked from the autocomplete dropdown. When provided, the dropdown-select path calls this instead of the onChangeText + onValidate pair — so the consumer can treat an explicit selection differently from typed-then-blurred text (e.g. force a fresh DB resolution rather than relying on a stale name-changed comparison).

    testID: string

    Unique identifier for testing and accessibility

    style?: StyleProp<ViewStyle>

    Custom styles for the container

    contentStyle?: StyleProp<TextStyle>

    Custom styles for the text content

    textInputStyle?: StyleProp<TextStyle>

    Custom styles applied directly to the inner TextInput surface

    right?: React.ReactNode

    Right element (icon or affix) to display inside the input

    onFocus?: () => void

    Optional focus handler called when the inner input gains focus

    renderLayout?: (
        field: React.ReactElement,
        dropdown: React.ReactElement | null,
    ) => React.ReactNode

    When provided, lays out the field and the suggestion bubble (null when hidden) so a parent can place the bubble at another level, e.g. spanning a whole table row. By default the bubble renders right under the field.

    onBlur?: () => void

    Optional blur handler called when the inner input loses focus