@pnkx-lib/ui 1.9.287 → 1.9.289
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -46,7 +46,7 @@ const SearchFiltersForm = ({
|
|
|
46
46
|
hideDefaultSubmit,
|
|
47
47
|
hideResetButton
|
|
48
48
|
}) => {
|
|
49
|
-
const { control, handleSubmit, reset, setValue } = useForm({
|
|
49
|
+
const { control, handleSubmit, reset, setValue, watch } = useForm({
|
|
50
50
|
defaultValues: initialValues
|
|
51
51
|
});
|
|
52
52
|
return /* @__PURE__ */ jsxs("form", { className: classNameWrapperForm, onSubmit: handleSubmit(onSubmit), children: [
|
|
@@ -54,7 +54,8 @@ const SearchFiltersForm = ({
|
|
|
54
54
|
control,
|
|
55
55
|
setValue,
|
|
56
56
|
handleSubmit: handleSubmit(onSubmit),
|
|
57
|
-
reset
|
|
57
|
+
reset,
|
|
58
|
+
watch
|
|
58
59
|
}) }),
|
|
59
60
|
!hideDefaultSubmit && /* @__PURE__ */ jsxs("div", { className: "flex justify-end gap-2 mb-3", children: [
|
|
60
61
|
/* @__PURE__ */ jsx(
|
package/package.json
CHANGED
|
@@ -6,6 +6,7 @@ export interface SearchFiltersFormProps<T extends FieldValues> {
|
|
|
6
6
|
setValue?: UseFormSetValue<T>;
|
|
7
7
|
handleSubmit?: FormEventHandler<any>;
|
|
8
8
|
reset?: UseFormReset<T>;
|
|
9
|
+
watch?: UseFormReturn<T>["watch"];
|
|
9
10
|
}) => React.ReactNode;
|
|
10
11
|
onReset?: () => void;
|
|
11
12
|
classNamesContainer?: string;
|