react-toolkits 2.13.16 → 2.13.18

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # react-toolkits
2
2
 
3
+ ## 2.13.18
4
+
5
+ ### Patch Changes
6
+
7
+ - c95938f: fix: Skelton not work
8
+
9
+ ## 2.13.17
10
+
11
+ ### Patch Changes
12
+
13
+ - 5e18613: feat: add Skelton for modal
14
+
3
15
  ## 2.13.16
4
16
 
5
17
  ### Patch Changes
package/lib/index.d.ts CHANGED
@@ -157,7 +157,7 @@ interface UseModalProps extends Omit<ModalProps, 'open' | 'confirmLoading' | 'on
157
157
  }
158
158
  declare function useModal(props: UseModalProps): {
159
159
  id: number;
160
- show: () => void;
160
+ show: () => Promise<void>;
161
161
  hide: () => void;
162
162
  modal: react_jsx_runtime.JSX.Element;
163
163
  };
package/lib/index.js CHANGED
@@ -1043,9 +1043,9 @@ function useModal(props) {
1043
1043
  const open = isOpen(_id);
1044
1044
  const [confirmLoading, setConfirmLoading] = useState(false);
1045
1045
  const isRenderFunction = typeof content === "function";
1046
- const _show = () => {
1046
+ const _show = async () => {
1047
1047
  show(_id);
1048
- afterOpen?.();
1048
+ await afterOpen?.();
1049
1049
  };
1050
1050
  const _hide = () => {
1051
1051
  hide(_id);