hrm_ui_lib 3.2.0 → 3.2.2

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.
@@ -15,7 +15,7 @@ export const FormContainer = (props) => {
15
15
  shouldFocusError: shouldFocusError,
16
16
  shouldUnregister: shouldUnregister
17
17
  });
18
- const { errors, isDirty, isSubmitted, isSubmitting, dirtyFields } = formState;
18
+ const { errors, isDirty, isSubmitted, isSubmitting, dirtyFields, isValid } = formState;
19
19
  const customSubmit = (data) => {
20
20
  if (onSubmit) {
21
21
  onSubmit(data, formState, dirtyFields);
@@ -46,6 +46,7 @@ export const FormContainer = (props) => {
46
46
  dirtyFields,
47
47
  getFieldState,
48
48
  unregister,
49
+ isValid,
49
50
  onSubmit: () => handleSubmit(customSubmit)()
50
51
  }, children: _jsxs(_Fragment, { children: [children, buttonConfigs && (_jsx("div", { className: "form-container__buttons", children: buttonConfigs.map((buttonConfig, index) => {
51
52
  return _createElement(Button, Object.assign({}, buttonConfig, { key: index }));
@@ -8,6 +8,7 @@ export type TFormContextProps = {
8
8
  watch?: UseFormWatch<TFormData>;
9
9
  reset?: UseFormReset<TFormData>;
10
10
  isDirty?: boolean;
11
+ isValid?: boolean;
11
12
  clearErrors?: UseFormClearErrors<TFormData>;
12
13
  setError?: UseFormSetError<TFormData>;
13
14
  isSubmitted: boolean;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hrm_ui_lib",
3
- "version": "3.2.0",
3
+ "version": "3.2.2",
4
4
  "description": "UI library for Dino",
5
5
  "main": "./index.cjs",
6
6
  "module": "./index.js",