UNPKG

office-ui-fabric-react

Version:

Reusable React components for building experiences for Office 365.

35 lines (34 loc) 1.04 kB
import * as React from 'react'; import { ISearchBoxProps } from './SearchBox.types'; export interface ISearchBoxState { value?: string; hasFocus?: boolean; } export declare class SearchBoxBase extends React.Component<ISearchBoxProps, ISearchBoxState> { static defaultProps: Pick<ISearchBoxProps, 'disableAnimation' | 'clearButtonProps'>; private _rootElement; private _inputElement; private _latestValue; private _fallbackId; private _events; constructor(props: ISearchBoxProps); UNSAFE_componentWillReceiveProps(newProps: ISearchBoxProps): void; UNSAFE_componentWillMount(): void; render(): JSX.Element; /** * Sets focus to the search box input field */ focus(): void; /** * Returns whether or not the SearchBox has focus */ hasFocus(): boolean; private _onClear; private _onClickFocus; private _onFocusCapture; private _onClearClick; private _onKeyDown; private _onBlur; private _onInputChange; private _callOnChange; }