Repository URL to install this package:
|
Version:
0.0.15 ▾
|
import React from 'react';
import { SearchItemProps } from './typings';
/**
* @todo Button atom
* @todo !!! observer > state, or update 1 level up
*/
declare class SearchItem extends React.PureComponent<SearchItemProps> {
readonly words: (string & {
[key: string]: any;
}) | {
pre: string;
text: string;
context: string;
contextShort: string;
isContextSameAsSearch: boolean;
} | {
text: string;
context: string;
pre: string;
post: string;
isContextSameAsSearch: boolean;
contextShort: string;
};
static defaultProps: {
text: string;
onClick: undefined;
hasClose: boolean;
};
static fromClosable(text: string): JSX.Element;
static from(text: string): JSX.Element;
state: {
isRemoved: boolean;
};
/**
* @todo smooth animate away like gmail
* @param {ReactClipboardEventHandler}
* @type {React.EventHandler}
*/
handleRemoveRecentItem: (event: React.MouseEvent<Element, MouseEvent>) => void;
render(): "" | JSX.Element;
}
export { SearchItem };
export default SearchItem;