@lobehub/ui 2.1.6 → 2.1.8
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.
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
|
|
3
3
|
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
4
|
-
var _excluded = ["classNames", "className", "style", "closable", "styles", "allowFullscreen", "title", "afterOpenChange", "width", "onCancel", "centered", "open", "afterClose", "
|
|
4
|
+
var _excluded = ["classNames", "className", "style", "closable", "styles", "allowFullscreen", "title", "afterOpenChange", "width", "onCancel", "centered", "open", "afterClose", "destroyOnHidden", "closeIcon", "paddings", "height", "enableResponsive", "zIndex", "mask", "getContainer", "keyboard", "focusTriggerAfterClose", "forceRender", "loading", "footer", "submitButtonProps", "submitLoading", "onFinish", "submitText", "variant", "gap", "onSubmit", "children", "ref"],
|
|
5
5
|
_excluded2 = ["form", "footer"],
|
|
6
6
|
_excluded3 = ["form"];
|
|
7
7
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
@@ -35,7 +35,7 @@ var FormModal = /*#__PURE__*/memo(function (_ref) {
|
|
|
35
35
|
centered = _ref.centered,
|
|
36
36
|
open = _ref.open,
|
|
37
37
|
afterClose = _ref.afterClose,
|
|
38
|
-
|
|
38
|
+
destroyOnHidden = _ref.destroyOnHidden,
|
|
39
39
|
closeIcon = _ref.closeIcon,
|
|
40
40
|
paddings = _ref.paddings,
|
|
41
41
|
height = _ref.height,
|
|
@@ -79,7 +79,7 @@ var FormModal = /*#__PURE__*/memo(function (_ref) {
|
|
|
79
79
|
closable: closable,
|
|
80
80
|
closeIcon: closeIcon,
|
|
81
81
|
confirmLoading: submitLoading,
|
|
82
|
-
|
|
82
|
+
destroyOnHidden: destroyOnHidden,
|
|
83
83
|
enableResponsive: enableResponsive,
|
|
84
84
|
focusTriggerAfterClose: focusTriggerAfterClose,
|
|
85
85
|
footer: null,
|
|
@@ -103,7 +103,7 @@ var FormModal = /*#__PURE__*/memo(function (_ref) {
|
|
|
103
103
|
zIndex: zIndex,
|
|
104
104
|
children: /*#__PURE__*/_jsx(Form, _objectSpread(_objectSpread({
|
|
105
105
|
className: cx(s.form, formClassName),
|
|
106
|
-
clearOnDestroy:
|
|
106
|
+
clearOnDestroy: destroyOnHidden,
|
|
107
107
|
footer: /*#__PURE__*/_jsx(Flexbox, {
|
|
108
108
|
align: 'center',
|
|
109
109
|
className: cx(s.footer, footerClassName),
|
package/es/FormModal/type.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import type { Ref } from 'react';
|
|
|
2
2
|
import type { ButtonProps } from "../Button";
|
|
3
3
|
import type { FormInstance, FormProps } from "../Form";
|
|
4
4
|
import type { ModalProps } from "../Modal";
|
|
5
|
-
type PickModalProps = Pick<ModalProps, 'style' | 'className' | 'allowFullscreen' | 'title' | 'width' | 'onCancel' | 'open' | 'centered' | '
|
|
5
|
+
type PickModalProps = Pick<ModalProps, 'style' | 'className' | 'allowFullscreen' | 'title' | 'width' | 'onCancel' | 'open' | 'centered' | 'destroyOnHidden' | 'paddings' | 'height' | 'enableResponsive' | 'afterClose' | 'afterOpenChange' | 'zIndex' | 'mask' | 'getContainer' | 'keyboard' | 'forceRender' | 'focusTriggerAfterClose' | 'closable' | 'loading' | 'closeIcon'>;
|
|
6
6
|
type PickFormProps = Omit<FormProps, 'className' | 'style' | 'title'>;
|
|
7
7
|
export interface FormModalProps extends PickModalProps, PickFormProps {
|
|
8
8
|
classNames?: {
|
package/es/Modal/Modal.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
|
|
3
3
|
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
4
|
-
var _excluded = ["panelRef", "allowFullscreen", "children", "title", "className", "classNames", "width", "onCancel", "open", "
|
|
4
|
+
var _excluded = ["panelRef", "allowFullscreen", "children", "title", "className", "classNames", "width", "onCancel", "open", "destroyOnHidden", "paddings", "height", "enableResponsive", "footer", "styles", "okText", "onOk", "cancelText", "okButtonProps", "cancelButtonProps", "confirmLoading"],
|
|
5
5
|
_excluded2 = ["body"];
|
|
6
6
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
7
7
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
@@ -39,7 +39,7 @@ var Modal = /*#__PURE__*/memo(function (_ref) {
|
|
|
39
39
|
width = _ref$width === void 0 ? 700 : _ref$width,
|
|
40
40
|
onCancel = _ref.onCancel,
|
|
41
41
|
open = _ref.open,
|
|
42
|
-
|
|
42
|
+
destroyOnHidden = _ref.destroyOnHidden,
|
|
43
43
|
paddings = _ref.paddings,
|
|
44
44
|
_ref$height = _ref.height,
|
|
45
45
|
height = _ref$height === void 0 ? '75dvh' : _ref$height,
|
|
@@ -82,7 +82,7 @@ var Modal = /*#__PURE__*/memo(function (_ref) {
|
|
|
82
82
|
closeIcon: /*#__PURE__*/_jsx(ActionIcon, {
|
|
83
83
|
icon: X
|
|
84
84
|
}),
|
|
85
|
-
|
|
85
|
+
destroyOnHidden: destroyOnHidden,
|
|
86
86
|
extra: allowFullscreen && /*#__PURE__*/_jsx(ActionIcon, {
|
|
87
87
|
icon: fullscreen ? Minimize2 : Maximize2,
|
|
88
88
|
onClick: function onClick() {
|
|
@@ -145,7 +145,7 @@ var Modal = /*#__PURE__*/memo(function (_ref) {
|
|
|
145
145
|
size: 20
|
|
146
146
|
}),
|
|
147
147
|
confirmLoading: confirmLoading,
|
|
148
|
-
|
|
148
|
+
destroyOnHidden: destroyOnHidden,
|
|
149
149
|
footer: hideFooter ? null : footer,
|
|
150
150
|
maskClosable: true,
|
|
151
151
|
okButtonProps: okButtonProps,
|
|
@@ -79,7 +79,7 @@ var MessageModal = /*#__PURE__*/memo(function (_ref) {
|
|
|
79
79
|
return /*#__PURE__*/_jsx(Modal, {
|
|
80
80
|
allowFullscreen: true,
|
|
81
81
|
cancelText: (text === null || text === void 0 ? void 0 : text.cancel) || 'Cancel',
|
|
82
|
-
|
|
82
|
+
destroyOnHidden: true,
|
|
83
83
|
footer: modalFooter,
|
|
84
84
|
height: height,
|
|
85
85
|
okText: (text === null || text === void 0 ? void 0 : text.edit) || 'Edit',
|
|
@@ -72,7 +72,8 @@ export function preprocessLaTeX(str) {
|
|
|
72
72
|
});
|
|
73
73
|
|
|
74
74
|
// Step 3: Escape dollar signs that are likely currency indicators
|
|
75
|
-
|
|
75
|
+
// Deprecated, as it causes parsing errors for formulas starting with a number, such as `$1$`
|
|
76
|
+
// content = content.replaceAll(/\$(?=\d)/g, '\\$');
|
|
76
77
|
|
|
77
78
|
// Step 4: Restore LaTeX expressions
|
|
78
79
|
content = content.replaceAll(/<<LATEX_(\d+)>>/g, function (_, index) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lobehub/ui",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.8",
|
|
4
4
|
"description": "Lobe UI is an open-source UI component library for building AIGC web apps",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"lobehub",
|
|
@@ -105,7 +105,7 @@
|
|
|
105
105
|
"uuid": "^11.1.0"
|
|
106
106
|
},
|
|
107
107
|
"peerDependencies": {
|
|
108
|
-
"antd": "^5.
|
|
108
|
+
"antd": "^5.25.0",
|
|
109
109
|
"framer-motion": "^12.0.0",
|
|
110
110
|
"react": "^19.0.0",
|
|
111
111
|
"react-dom": "^19.0.0"
|