stream-chat-react
Version:
React components to create chat conversations or livestream style chat
8 lines (7 loc) • 638 B
JavaScript
import React from 'react';
import { useTranslationContext } from '../../context/TranslationContext';
export var SearchInput = function (props) {
var disabled = props.disabled, inputRef = props.inputRef, onSearch = props.onSearch, placeholder = props.placeholder, query = props.query;
var t = useTranslationContext('SearchInput').t;
return (React.createElement("input", { className: 'str-chat__channel-search-input', "data-testid": 'search-input', disabled: disabled, onChange: onSearch, placeholder: placeholder !== null && placeholder !== void 0 ? placeholder : t('Search'), ref: inputRef, type: 'text', value: query }));
};