lkd-web-kit 0.5.4 → 0.5.5

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.
@@ -12,7 +12,7 @@ const withModalManager = (WrappedComponent) => {
12
12
  const onClose = () => {
13
13
  setIsOpen(false);
14
14
  setTimeout(() => removeModal(), 200);
15
- props.modalProps.onClose();
15
+ props.modalProps.onClose?.();
16
16
  };
17
17
  React.useEffect(() => {
18
18
  if (props.modalProps.opened) setTimeout(() => setIsOpen(true), 0);
@@ -8,7 +8,7 @@ const withModalManager = (WrappedComponent) => {
8
8
  const onClose = () => {
9
9
  setIsOpen(false);
10
10
  setTimeout(() => removeModal(), 200);
11
- props.modalProps.onClose();
11
+ props.modalProps.onClose?.();
12
12
  };
13
13
  useEffect(() => {
14
14
  if (props.modalProps.opened) setTimeout(() => setIsOpen(true), 0);
package/dist/index.d.ts CHANGED
@@ -344,7 +344,7 @@ export declare type ModalManagerWrappedComponentProps<T extends object = object>
344
344
  };
345
345
 
346
346
  export declare type ModalManagerWrapperProps<T extends object = object> = T & {
347
- modalProps: ModalProps;
347
+ modalProps: Partial<ModalProps>;
348
348
  removeModal: () => void;
349
349
  };
350
350
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lkd-web-kit",
3
- "version": "0.5.4",
3
+ "version": "0.5.5",
4
4
  "description": "A template for creating React component libraries with Vite.",
5
5
  "author": "LKD",
6
6
  "license": "MIT",