Minor changes on tags filtering for short URLs

This commit is contained in:
Alejandro Celaya
2021-11-07 11:03:31 +01:00
parent 303900756d
commit 109baef828
12 changed files with 19 additions and 68 deletions

View File

@@ -12,10 +12,11 @@ interface SearchFieldProps {
className?: string;
large?: boolean;
noBorder?: boolean;
initialValue?: string;
}
const SearchField = ({ onChange, className, large = true, noBorder = false }: SearchFieldProps) => {
const [ searchTerm, setSearchTerm ] = useState('');
const SearchField = ({ onChange, className, large = true, noBorder = false, initialValue = '' }: SearchFieldProps) => {
const [ searchTerm, setSearchTerm ] = useState(initialValue);
const resetTimer = () => {
timer && clearTimeout(timer);