UNPKG

office-ui-fabric-react

Version:

Reusable React components for building experiences for Office 365.

1 lines 1.48 kB
module.exports = "import { IRenderFunction } from '../../common/IRenderFunction';\r\nexport interface IDropdownProps {\r\n /**\r\n * Descriptive label for the Dropdown\r\n */\r\n label: string;\r\n\r\n /**\r\n * Id of the drop down\r\n */\r\n id?: string;\r\n\r\n /**\r\n * The key of the initially selected option\r\n */\r\n selectedKey?: string | number;\r\n\r\n /**\r\n * Collection of options for this Dropdown\r\n */\r\n options?: IDropdownOption[];\r\n\r\n /**\r\n * Callback issues when the selected option changes\r\n */\r\n onChanged?: (option: IDropdownOption, index?: number) => void;\r\n\r\n /**\r\n * Optional custom renderer for the dropdown item\r\n */\r\n onRenderItem?: IRenderFunction<IDropdownOption>;\r\n\r\n /**\r\n * Whether or not the Dropdown is disabled.\r\n */\r\n disabled?: boolean;\r\n\r\n // @todo: Update version numbers for depriate and removal\r\n /**\r\n * @deprecated\r\n * Deprecated at v0.52.0, to be removed at >= v1.0.0. Use 'disabled' instead.\r\n */\r\n isDisabled?: boolean;\r\n\r\n}\r\n\r\nexport interface IDropdownOption {\r\n /**\r\n * Arbitrary string associated with this option.\r\n */\r\n key: string | number;\r\n\r\n /**\r\n * Text to render for this option\r\n */\r\n text: string;\r\n\r\n /**\r\n * Index for this option\r\n */\r\n index?: number;\r\n\r\n /**\r\n * Whether this option is currently selected.\r\n */\r\n isSelected?: boolean;\r\n}\r\n";