Hex Core JS
    Preparing search index...

    Type Alias RadioInputProps<T>

    RadioInputProps: {
        autoFocus?: boolean;
        disabled?: boolean;
        displayOption?: (props: RadioInputOption<T>) => React.ReactNode;
        id?: string;
        invalid?: boolean;
        isLoading?: boolean;
        name?: string;
        onBlur?: () => void;
        onFocus?: () => void;
        Option?: (props: RadioOptionProps<T>) => JSX.Element | null;
        optionClassName?: string;
        options: RadioInputOption<T>[];
        OptionsContainer?: (
            props: RadioInputOptionsContainerProps,
        ) => JSX.Element | null;
        selectedOptionClassName?: string;
        setValue: (value: T) => void;
        sideEffect?: (v: T) => void;
        value: T;
    } & Partial<ClassNameProps & StyleProps>

    Type Parameters

    Type Declaration

    • OptionalautoFocus?: boolean

      Indicates if the input should be auto-focused.

    • Optionaldisabled?: boolean

      Indicates if the input is disabled.

    • OptionaldisplayOption?: (props: RadioInputOption<T>) => React.ReactNode

      Controls the display of rendered options.

    • Optionalid?: string

      The ID of the input.

    • Optionalinvalid?: boolean

      Indicates if the input is invalid.

    • OptionalisLoading?: boolean

      Indicates if the options are currently loading.

    • Optionalname?: string

      The name of the input.

    • OptionalonBlur?: () => void

      A callback function to call when focus is removed from the input.

    • OptionalonFocus?: () => void

      A callback function to call when the input becomes focused.

    • OptionalOption?: (props: RadioOptionProps<T>) => JSX.Element | null

      Component for each option.

    • OptionaloptionClassName?: string

      CSS class name to give to each option.

    • options: RadioInputOption<T>[]

      The options for the value.

    • OptionalOptionsContainer?: (props: RadioInputOptionsContainerProps) => JSX.Element | null

      Container component for options.

    • OptionalselectedOptionClassName?: string

      CSS class name to give to the selected option.

    • setValue: (value: T) => void

      A callback function to update the input value when a change happens.

    • OptionalsideEffect?: (v: T) => void

      A side effect function to call when the value changes as a result of user interaction with this input, and not external updates to the field value.

    • value: T

      The value of the input.