import { type HTMLAttributes, type ReactElement, type Ref } from 'react';
import { type VariantProps } from 'class-variance-authority';
import type { OptionShape } from '../_shared/option';
declare const multiSelectVariants: (props?: ({
size?: "sm" | "md" | "lg" | null | undefined;
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
type HTMLDivAttributes = HTMLAttributes;
export interface MultiSelectHandle {
getSelection: () => string[];
getQuery: () => string;
getIsOpen: () => boolean;
setSelection: (values: string[]) => void;
clearSelection: () => void;
setQuery: (query: string) => void;
open: () => void;
close: () => void;
}
export interface MultiSelectProps extends Omit, VariantProps {
options: OptionShape[];
value?: T[];
defaultValue?: T[];
onChange?: (next: T[]) => void;
onComplete?: (values: T[]) => void;
placeholder?: string;
maxSelections?: number;
allowSelectAll?: boolean;
allowClear?: boolean;
filter?: (query: string, option: OptionShape) => boolean;
size?: 'sm' | 'md' | 'lg';
disabled?: boolean;
/**
* Let a long option label wrap onto a second line instead of ending in an
* ellipsis. Longer still, it is clipped after two lines. Off by default.
* An option's `description` always sits on its own line under the label.
*/
wrapOptionLabels?: boolean;
}
interface MultiSelectComponent {
(props: MultiSelectProps & {
ref?: Ref;
}): ReactElement | null;
displayName?: string;
}
export declare const MultiSelect: MultiSelectComponent;
export { multiSelectVariants };
//# sourceMappingURL=multi-select.d.ts.map