UNPKG

@kwiz/fluentui

Version:
24 lines (23 loc) 1.16 kB
import { TagPickerOptionProps, TagPickerProps, TagProps } from '@fluentui/react-components'; import { EventData, EventHandler } from '@fluentui/react-utilities'; import * as React from 'react'; declare type TagPickerOnOptionSelectData<keyType extends string = string> = { value: keyType; selectedOptions: keyType[]; } & (EventData<'click', React.MouseEvent<HTMLDivElement>> | EventData<'keydown', React.KeyboardEvent<HTMLDivElement>>); interface iProps<keyType extends string = string> extends Omit<TagPickerProps, "children" | "onOptionSelect"> { selectedTagsTitle?: string; selectTagsTitle?: string; placeholder?: string; getSelectedTagProps?: (key: keyType) => Partial<TagProps>; getTagProps?: (key: keyType) => Partial<TagPickerOptionProps>; selectedOptions?: keyType[]; defaultSelectedOptions?: keyType[]; options: { key: keyType; text: string; }[]; onOptionSelect?: EventHandler<TagPickerOnOptionSelectData<keyType>>; } export declare function TagPickerEx<keyType extends string = string>(props: React.PropsWithChildren<iProps<keyType>>): import("react/jsx-runtime").JSX.Element; export {};