@spaced-out/ui-design-system
Version:
Sense UI components library
79 lines • 2.68 kB
TypeScript
import * as React from 'react';
import type { Flow } from 'flow-to-typescript-codemod';
import type { IconType } from '../../components/Icon';
import type { InputOnChangeParamsType } from '../../components/Input';
import type { MenuOption, MenuProps } from '../../components/Menu';
type InputClassNames = Readonly<{
box?: string;
iconLeft?: string;
iconRight?: string;
wrapper?: string;
}>;
type DropdownClassNames = Readonly<{
wrapper?: string;
box?: string;
iconRight?: string;
}>;
type ClassNames = Readonly<{
wrapper?: string;
box?: string;
input?: InputClassNames;
dropdown?: DropdownClassNames;
}>;
export interface ComboboxProps {
classNames?: ClassNames;
disabled?: boolean;
type?: 'text' | 'tel';
label?: string | React.ReactNode;
size?: 'medium' | 'small';
onContainerClick?: React.MouseEventHandler<HTMLDivElement>;
locked?: boolean;
error?: boolean;
errorText?: string;
helperText?: string | React.ReactNode;
required?: boolean;
readOnly?: boolean;
boxRef?: React.Ref<HTMLDivElement>;
value: {
dropdown?: string;
input?: string;
};
onChange: (arg1: {
input: string;
dropdown: string;
inputChange?: InputOnChangeParamsType;
dropdownOption?: MenuOption;
}) => unknown;
inputPlaceholder?: string;
onInputFocus?: React.FocusEventHandler<HTMLInputElement>;
onInputBlur?: React.FocusEventHandler<HTMLInputElement>;
onInputKeyDown?: React.KeyboardEventHandler<HTMLInputElement>;
onInputContainerClick?: React.MouseEventHandler<HTMLDivElement>;
inputName?: string;
iconLeftName?: string;
iconLeftType?: IconType;
iconRightName?: string;
iconRightType?: IconType;
onIconRightClick?: ((arg1: React.SyntheticEvent<HTMLElement>) => unknown) | null | undefined;
inputBoxRef?: React.Ref<HTMLInputElement>;
minLength?: number;
maxLength?: number;
pattern?: string;
min?: string;
max?: string;
menu?: MenuProps;
onMenuOpen?: () => unknown;
onMenuClose?: () => unknown;
scrollMenuToBottom?: boolean;
onDropdownFocus?: React.FocusEventHandler<HTMLInputElement>;
onDropdownBlur?: React.FocusEventHandler<HTMLInputElement>;
onDropdownKeyDown?: React.KeyboardEventHandler<HTMLInputElement>;
onDropdownContainerClick?: React.MouseEventHandler<HTMLDivElement>;
dropdownName?: string;
dropdownPlaceholder?: string;
dropdownBoxRef?: React.Ref<HTMLDivElement>;
testId?: string;
}
export declare const Combobox: Flow.AbstractComponent<ComboboxProps, HTMLDivElement>;
export {};
//# sourceMappingURL=Combobox.d.ts.map