office-ui-fabric-react
Version:
Reusable React components for building experiences for Office 365.
1 lines • 2.01 kB
JavaScript
define([], function() { return "import * as React from 'react';\nimport { ISuggestionModel } from './SuggestionsController';\n\nexport interface ISuggestionsProps<T> extends React.Props<any> {\n /**\n * How the suggestion should look in the suggestion list.\n */\n onRenderSuggestion: (props: any) => JSX.Element;\n /**\n * What should occur when a suggestion is clicked\n */\n onSuggestionClick: (ev?: React.MouseEvent<HTMLElement>, item?: any, index?: number) => void;\n /**\n * The list of Suggestions that will be displayed\n */\n suggestions: ISuggestionModel<T>[];\n /**\n * The text that appears at the top of the suggestions list.\n */\n suggestionsHeaderText?: string;\n /**\n * The text that appears indicating to the user that they can search for more results.\n */\n searchForMoreText?: string;\n /**\n * The callback that should be called when the user attempts to get more results\n */\n onGetMoreResults?: () => void;\n /**\n * The CSS classname of the suggestions list.\n */\n className?: string;\n /**\n * The text that should appear if there is a search error.\n */\n searchErrorText?: string;\n /**\n * The text that should appear if no results are found when searching.\n */\n noResultsFoundText?: string;\n /**\n * the classname of the suggestionitem.\n */\n suggestionsItemClassName?: string;\n /**\n * Used to indicate whether or not the user can request more suggestions.\n * Dictates whether or not the searchForMore button is displayed.\n */\n moreSuggestionsAvailable?: boolean;\n /**\n * Used to indicate whether or not the suggestions are loading.\n */\n isLoading?: boolean;\n /**\n * The text to display while the results are loading.\n */\n loadingText?: string;\n}\n\nexport interface ISuggestionItemProps<T> {\n suggestionModel: ISuggestionModel<T>;\n RenderSuggestion: (item: any) => JSX.Element;\n onClick: (ev: React.MouseEvent<HTMLButtonElement>) => void;\n className?: string;\n}"; });