zmdms-webui 0.0.99 → 0.0.100
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/dist/es/modal/modal.js +1 -17
- package/package.json +1 -1
package/dist/es/modal/modal.js
CHANGED
|
@@ -142,28 +142,12 @@ var Modal = function (_a, ref) {
|
|
|
142
142
|
return (jsx(Modal$1, __assign({ open: open, onCancel: close, className: classes, okText: "\u4FDD\u5B58", onOk: footer ? undefined : onOkHandle, width: "70%", title: title, keyboard: false, maskClosable: false, confirmLoading: loading, cancelButtonProps: { loading: loading }, footer: footer }, resetProps)));
|
|
143
143
|
};
|
|
144
144
|
var ModalComponent = forwardRef(Modal);
|
|
145
|
-
var ModalConfirm = function (modalProps) {
|
|
146
|
-
var onOk = modalProps.onOk, resetModalProps = __rest(modalProps, ["onOk"]);
|
|
147
|
-
var modalConfirm = Modal$1.confirm(__assign(__assign({}, resetModalProps), { onOk: onOk
|
|
148
|
-
? function () {
|
|
149
|
-
setCancelBtnProps(modalConfirm, { loading: true });
|
|
150
|
-
onOk()
|
|
151
|
-
.then(function () {
|
|
152
|
-
setCancelBtnProps(modalConfirm, { loading: false, open: false });
|
|
153
|
-
})
|
|
154
|
-
.catch(function (err) {
|
|
155
|
-
setCancelBtnProps(modalConfirm, { loading: false, open: true });
|
|
156
|
-
});
|
|
157
|
-
}
|
|
158
|
-
: undefined }));
|
|
159
|
-
return modalConfirm;
|
|
160
|
-
};
|
|
161
145
|
ModalComponent.displayName = "ZTXK_WEBUI_ModalComponent";
|
|
162
146
|
ModalComponent.info = Modal$1.info;
|
|
163
147
|
ModalComponent.success = Modal$1.success;
|
|
164
148
|
ModalComponent.error = Modal$1.error;
|
|
165
149
|
ModalComponent.warning = Modal$1.warning;
|
|
166
|
-
ModalComponent.confirm =
|
|
150
|
+
ModalComponent.confirm = Modal$1.confirm;
|
|
167
151
|
ModalComponent.destroyAll = Modal$1.destroyAll;
|
|
168
152
|
|
|
169
153
|
export { ModalComponent as default };
|