@nocobase/client 1.6.18 → 1.6.19
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/es/index.mjs +56 -44
- package/lib/index.js +16 -10
- package/package.json +5 -5
package/es/index.mjs
CHANGED
|
@@ -106,7 +106,7 @@ import * as formilyReactiveReact from "@formily/reactive-react";
|
|
|
106
106
|
import { observer } from "@formily/reactive-react";
|
|
107
107
|
import cronstrue from "cronstrue";
|
|
108
108
|
import * as antdStyle from "antd-style";
|
|
109
|
-
import { createStyles, useAntdToken } from "antd-style";
|
|
109
|
+
import { createStyles, createGlobalStyle, useAntdToken } from "antd-style";
|
|
110
110
|
import { createStyles as yn } from "antd-style";
|
|
111
111
|
import JSON5 from "json5";
|
|
112
112
|
import { usePrefixCls as usePrefixCls$1, dayjsable, formatDayjsValue } from "@formily/antd-v5/esm/__builtins__";
|
|
@@ -9184,7 +9184,7 @@ function addAppVersion(e, t) {
|
|
|
9184
9184
|
addAppVersion((o = e.properties) == null ? void 0 : o[n], t);
|
|
9185
9185
|
}), e;
|
|
9186
9186
|
}
|
|
9187
|
-
const name = "@nocobase/client", version = "1.6.
|
|
9187
|
+
const name = "@nocobase/client", version = "1.6.19", license = "AGPL-3.0", main = "lib/index.js", module = "es/index.mjs", types = "es/index.d.ts", dependencies = {
|
|
9188
9188
|
"@ahooksjs/use-url-state": "3.5.1",
|
|
9189
9189
|
"@ant-design/cssinjs": "^1.11.1",
|
|
9190
9190
|
"@ant-design/icons": "^5.6.1",
|
|
@@ -9206,9 +9206,9 @@ const name = "@nocobase/client", version = "1.6.18", license = "AGPL-3.0", main
|
|
|
9206
9206
|
"@formily/reactive-react": "^2.2.27",
|
|
9207
9207
|
"@formily/shared": "^2.2.27",
|
|
9208
9208
|
"@formily/validator": "^2.2.27",
|
|
9209
|
-
"@nocobase/evaluators": "1.6.
|
|
9210
|
-
"@nocobase/sdk": "1.6.
|
|
9211
|
-
"@nocobase/utils": "1.6.
|
|
9209
|
+
"@nocobase/evaluators": "1.6.19",
|
|
9210
|
+
"@nocobase/sdk": "1.6.19",
|
|
9211
|
+
"@nocobase/utils": "1.6.19",
|
|
9212
9212
|
ahooks: "^3.7.2",
|
|
9213
9213
|
antd: "5.12.8",
|
|
9214
9214
|
"antd-style": "3.7.1",
|
|
@@ -13683,13 +13683,16 @@ const setFieldProps$1 = (e, t, n) => {
|
|
|
13683
13683
|
n.componentProps = merge(m, n.componentProps || {}, u || {});
|
|
13684
13684
|
}, [r]), r ? /* @__PURE__ */ jsx(l, x(x({}, e), u)) : null;
|
|
13685
13685
|
}, CollectionFieldInternalField = (e) => {
|
|
13686
|
-
var
|
|
13686
|
+
var l;
|
|
13687
13687
|
const t = useField(), n = useFieldSchema(), { uiSchema: o } = useCollectionFieldUISchema(), r = useComponent(
|
|
13688
|
-
((
|
|
13688
|
+
((l = n["x-component-props"]) == null ? void 0 : l.component) || (o == null ? void 0 : o["x-component"]) || "Input"
|
|
13689
13689
|
), i = useDynamicComponentProps(o == null ? void 0 : o["x-use-component-props"], e);
|
|
13690
|
-
|
|
13690
|
+
if (useEffect(() => {
|
|
13691
13691
|
n["x-read-pretty"] === !0 && !t.readPretty && (t.readPretty = !0), n["x-disabled"] === !0 && (t.disabled = !0);
|
|
13692
|
-
}, [t, n]), o
|
|
13692
|
+
}, [t, n]), !o)
|
|
13693
|
+
return null;
|
|
13694
|
+
const a = x(x({}, e), i);
|
|
13695
|
+
return isVariable$1(a.value) && a.value === n.default && (a.value = void 0), /* @__PURE__ */ jsx(r, x({}, a));
|
|
13693
13696
|
}, CollectionField$1 = connect((e) => {
|
|
13694
13697
|
const t = useFieldSchema(), n = useIsInNocoBaseRecursionFieldContext();
|
|
13695
13698
|
return /* @__PURE__ */ jsx(CollectionFieldProvider, { name: t.name, children: n ? /* @__PURE__ */ jsx(CollectionFieldInternalField, x({}, e)) : /* @__PURE__ */ jsx(CollectionFieldInternalField_deprecated, x({}, e)) });
|
|
@@ -29590,7 +29593,7 @@ const useParseDefaultValue = () => {
|
|
|
29590
29593
|
return;
|
|
29591
29594
|
const y = (...T) => V(void 0, [...T], function* ({ forceUpdate: w = !1 } = {}) {
|
|
29592
29595
|
if (n && e && (isVariable$1(t.default) && e.value == null || e.value === t.default || w)) {
|
|
29593
|
-
|
|
29596
|
+
e.loading = !0;
|
|
29594
29597
|
const D = !t.name.toString().includes(".") && (d == null ? void 0 : d.getField(t.name)), {
|
|
29595
29598
|
value: O,
|
|
29596
29599
|
collectionName: j,
|
|
@@ -29647,13 +29650,15 @@ const formItemWrapCss = css`
|
|
|
29647
29650
|
.ant-description-textarea img {
|
|
29648
29651
|
max-width: 100%;
|
|
29649
29652
|
}
|
|
29650
|
-
&.ant-formily-item-layout-
|
|
29651
|
-
|
|
29652
|
-
.ant-formily-item-label-tooltip-icon {
|
|
29653
|
-
display: inline;
|
|
29654
|
-
}
|
|
29655
|
-
.ant-formily-item-label-content {
|
|
29653
|
+
&.ant-formily-item-layout-horizontal.ant-formily-item-label-wrap {
|
|
29654
|
+
.ant-formily-item-label {
|
|
29656
29655
|
display: inline;
|
|
29656
|
+
padding-right: 5px;
|
|
29657
|
+
|
|
29658
|
+
.ant-formily-item-label-tooltip-icon,
|
|
29659
|
+
.ant-formily-item-label-content {
|
|
29660
|
+
display: inline;
|
|
29661
|
+
}
|
|
29657
29662
|
}
|
|
29658
29663
|
}
|
|
29659
29664
|
`, formItemLabelCss = css`
|
|
@@ -41211,7 +41216,11 @@ const useStyles$6 = genStyleHook("upload", (e) => {
|
|
|
41211
41216
|
}
|
|
41212
41217
|
}
|
|
41213
41218
|
};
|
|
41214
|
-
}), useUploadStyles = useStyles$6
|
|
41219
|
+
}), useUploadStyles = useStyles$6, LightBoxGlobalStyle = createGlobalStyle`
|
|
41220
|
+
.ReactModal__Overlay.ReactModal__Overlay--after-open {
|
|
41221
|
+
z-index: 3000 !important; // 避免预览图片时被遮挡
|
|
41222
|
+
}
|
|
41223
|
+
`;
|
|
41215
41224
|
attachmentFileTypes.add({
|
|
41216
41225
|
match(e) {
|
|
41217
41226
|
return matchMimetype(e, "image/*");
|
|
@@ -41229,33 +41238,36 @@ attachmentFileTypes.add({
|
|
|
41229
41238
|
},
|
|
41230
41239
|
[e, t]
|
|
41231
41240
|
);
|
|
41232
|
-
return /* @__PURE__ */
|
|
41233
|
-
|
|
41234
|
-
|
|
41235
|
-
|
|
41236
|
-
|
|
41237
|
-
|
|
41238
|
-
|
|
41239
|
-
|
|
41240
|
-
|
|
41241
|
-
|
|
41242
|
-
|
|
41243
|
-
|
|
41244
|
-
|
|
41245
|
-
|
|
41246
|
-
|
|
41247
|
-
|
|
41248
|
-
|
|
41249
|
-
|
|
41250
|
-
|
|
41251
|
-
|
|
41252
|
-
|
|
41253
|
-
|
|
41254
|
-
|
|
41255
|
-
|
|
41256
|
-
|
|
41257
|
-
|
|
41258
|
-
|
|
41241
|
+
return /* @__PURE__ */ jsxs(Fragment$1, { children: [
|
|
41242
|
+
/* @__PURE__ */ jsx(LightBoxGlobalStyle, {}),
|
|
41243
|
+
/* @__PURE__ */ jsx(
|
|
41244
|
+
LightBox,
|
|
41245
|
+
{
|
|
41246
|
+
mainSrc: (r = t[e]) == null ? void 0 : r.url,
|
|
41247
|
+
nextSrc: (i = t[(e + 1) % t.length]) == null ? void 0 : i.url,
|
|
41248
|
+
prevSrc: (a = t[(e + t.length - 1) % t.length]) == null ? void 0 : a.url,
|
|
41249
|
+
onCloseRequest: () => n(null),
|
|
41250
|
+
onMovePrevRequest: () => n((e + t.length - 1) % t.length),
|
|
41251
|
+
onMoveNextRequest: () => n((e + 1) % t.length),
|
|
41252
|
+
imageTitle: (l = t[e]) == null ? void 0 : l.title,
|
|
41253
|
+
toolbarButtons: [
|
|
41254
|
+
/* @__PURE__ */ jsx(
|
|
41255
|
+
"button",
|
|
41256
|
+
{
|
|
41257
|
+
style: { fontSize: 22, background: "none", lineHeight: 1 },
|
|
41258
|
+
type: "button",
|
|
41259
|
+
"aria-label": "Download",
|
|
41260
|
+
title: "Download",
|
|
41261
|
+
className: "ril-zoom-in ril__toolbarItemChild ril__builtinButton",
|
|
41262
|
+
onClick: o,
|
|
41263
|
+
children: /* @__PURE__ */ jsx(DownloadOutlined, {})
|
|
41264
|
+
},
|
|
41265
|
+
"preview-img"
|
|
41266
|
+
)
|
|
41267
|
+
]
|
|
41268
|
+
}
|
|
41269
|
+
)
|
|
41270
|
+
] });
|
|
41259
41271
|
}
|
|
41260
41272
|
});
|
|
41261
41273
|
const iframePreviewSupportedTypes = ["application/pdf", "audio/*", "image/*", "video/*", "text/plain"];
|