mirror of
https://github.com/stashapp/stash.git
synced 2025-12-18 12:54:38 +03:00
Filter tweaks (#3772)
* Use debounce hook * Wait until search request complete before refreshing results * Add back null modifiers * Convert old excludes criterion to includes criterion * Display criteria with only excludes items as excludes * Fix depth display * Reset search after selection * Add back is modifier to tag filter * Focus the input dialog after select/unselect * Update unsupported modifiers
This commit is contained in:
@@ -8,15 +8,17 @@ import useFocus from "src/utils/focus";
|
||||
interface IClearableInput {
|
||||
value: string;
|
||||
setValue: (value: string) => void;
|
||||
focus: ReturnType<typeof useFocus>;
|
||||
}
|
||||
|
||||
export const ClearableInput: React.FC<IClearableInput> = ({
|
||||
value,
|
||||
setValue,
|
||||
focus,
|
||||
}) => {
|
||||
const intl = useIntl();
|
||||
|
||||
const [queryRef, setQueryFocus] = useFocus();
|
||||
const [queryRef, setQueryFocus] = focus;
|
||||
const queryClearShowing = !!value;
|
||||
|
||||
function onChangeQuery(event: React.FormEvent<HTMLInputElement>) {
|
||||
|
||||
Reference in New Issue
Block a user