diff --git a/src/lib/components/tablev2/Search.tsx b/src/lib/components/tablev2/Search.tsx index bcd61c89bb..aeb9e21a3f 100644 --- a/src/lib/components/tablev2/Search.tsx +++ b/src/lib/components/tablev2/Search.tsx @@ -79,6 +79,7 @@ export function TableSearch(props: SearchProps) { displayedName, locale = 'en', totalCount, + onReset, ...rest } = props; const { setGlobalFilter, rows, preGlobalFilteredRows } = useTableContext(); @@ -100,6 +101,7 @@ export function TableSearch(props: SearchProps) { placeholder={translations[locale].search} disableToggle size="1" + onReset={onReset} onChange={(evt) => { if (typeof onChange === 'function') { // @ts-ignore diff --git a/src/lib/components/tablev2/SearchWithQueryParams.tsx b/src/lib/components/tablev2/SearchWithQueryParams.tsx index a6f9544497..12890c4ab7 100644 --- a/src/lib/components/tablev2/SearchWithQueryParams.tsx +++ b/src/lib/components/tablev2/SearchWithQueryParams.tsx @@ -32,7 +32,6 @@ export function SearchWithQueryParams(props: SearchWithQueryParamsProps) { value={value} onReset={() => { handleOnChange(''); - params.delete(queryParams); }} {...rest} />