import type { IRenderFunction, ISelectableOption } from '@fluentui/react'; import type { IPropertyPaneFieldTooltipProps } from '../propertyPaneField/IPropertyPaneField'; /** * PropertyPane drop down component props. * * @public */ export interface IPropertyPaneDropdownProps { /** * Descriptive label for the Dropdown. */ label: string; /** * The key of the initially selected option. */ selectedKey?: string | number; /** * Collection of options for this Dropdown. */ options?: IPropertyPaneDropdownOption[]; /** * Whether the property pane dropdown option is disabled or not. */ disabled?: boolean; /** * A description for the dropdown that includes instructions for the benefit of screen reader users. */ ariaDescription?: string; /** * A label for the dropdown for the benefit of screen reader users. */ ariaLabel?: string; /** * Defines an element's number or position in the current set of controls. * Maps to native aria-posinset attribute. It starts from 1. */ ariaPositionInSet?: number; /** * Defines the number of items in the current set of controls. Maps to native aria-setsize attribute. */ ariaSetSize?: number; /** * Custom properties for Dropdown's Callout used to render options. */ calloutProps?: IPropertyPaneDropdownCalloutProps; /** * If set, this will be displayed as an error message. * * @beta */ errorMessage?: string; /** * Optional data-automation-id. automation id string for Toggle control. * * @internal */ dataAutomationId?: string; /** * Props for dropdown's tooltip button, which appears next to the label. * * @internal */ tooltipProps?: IPropertyPaneDropdownTooltipProps; /** * Optional custom renderer for normal and header options only. * @internal */ onRenderOption?: IRenderFunction; } /** * PropertyPane drop down options. * * @public */ export interface IPropertyPaneDropdownOption { /** * A key to uniquely identify this option. */ key: string | number; /** * Text to render for this option. */ text: string; /** * Index for this option. */ index?: number; /** * The type of option. If omitted, the default is PropertyPaneDropdownMenuItemType.Normal */ type?: PropertyPaneDropdownOptionType; } /** * Specifies the type of option in a dropdown menu rendered by {@link PropertyPaneDropdown}. * * @public */ export declare enum PropertyPaneDropdownOptionType { /** * Render normal menu item. */ Normal = 0, /** * Render a divider. */ Divider = 1, /** * Render menu item as a header. */ Header = 2 } /** * PropertyPane dropdown callout properties. * * @public */ export interface IPropertyPaneDropdownCalloutProps { /** * Set max height of callout * When not set the callout will expand with contents up to the bottom of the screen */ calloutMaxHeight?: number; } /** * Props for tooltip that appears when the info button is clicked. * * @internal */ export interface IPropertyPaneDropdownTooltipProps extends IPropertyPaneFieldTooltipProps { } //# sourceMappingURL=IPropertyPaneDropdown.d.ts.map