@nocobase/client 2.0.30 → 2.0.31
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 +21 -12
- package/lib/index.js +6 -6
- package/package.json +6 -6
package/es/index.mjs
CHANGED
|
@@ -9964,7 +9964,7 @@ function addAppVersion(e, t) {
|
|
|
9964
9964
|
addAppVersion((n = e.properties) == null ? void 0 : n[o], t);
|
|
9965
9965
|
}), e;
|
|
9966
9966
|
}
|
|
9967
|
-
const name = "@nocobase/client", version = "2.0.
|
|
9967
|
+
const name = "@nocobase/client", version = "2.0.31", license = "Apache-2.0", main = "lib/index.js", module = "es/index.mjs", types = "es/index.d.ts", dependencies = {
|
|
9968
9968
|
"@ahooksjs/use-url-state": "3.5.1",
|
|
9969
9969
|
"@ant-design/cssinjs": "^1.11.1",
|
|
9970
9970
|
"@ant-design/icons": "^5.6.1",
|
|
@@ -9987,10 +9987,10 @@ const name = "@nocobase/client", version = "2.0.30", license = "Apache-2.0", mai
|
|
|
9987
9987
|
"@formily/reactive-react": "^2.2.27",
|
|
9988
9988
|
"@formily/shared": "^2.2.27",
|
|
9989
9989
|
"@formily/validator": "^2.2.27",
|
|
9990
|
-
"@nocobase/evaluators": "2.0.
|
|
9991
|
-
"@nocobase/flow-engine": "2.0.
|
|
9992
|
-
"@nocobase/sdk": "2.0.
|
|
9993
|
-
"@nocobase/utils": "2.0.
|
|
9990
|
+
"@nocobase/evaluators": "2.0.31",
|
|
9991
|
+
"@nocobase/flow-engine": "2.0.31",
|
|
9992
|
+
"@nocobase/sdk": "2.0.31",
|
|
9993
|
+
"@nocobase/utils": "2.0.31",
|
|
9994
9994
|
"@tanstack/react-table": "^8.21.3",
|
|
9995
9995
|
"@types/tabulator-tables": "^6.2.6",
|
|
9996
9996
|
"acorn-jsx": "^5.3.2",
|
|
@@ -30630,7 +30630,7 @@ const useStyles$a = genStyleHook("nb-markdown", (e, { isDarkTheme: t }) => {
|
|
|
30630
30630
|
}, t ? i : r)
|
|
30631
30631
|
};
|
|
30632
30632
|
}), parseMarkdown$1 = _.memoize((e) => L(void 0, null, function* () {
|
|
30633
|
-
return e && (yield import("./md-
|
|
30633
|
+
return e && (yield import("./md-oH2RssNY.mjs")).default.render(e);
|
|
30634
30634
|
}));
|
|
30635
30635
|
function useParseMarkdown$1(e) {
|
|
30636
30636
|
const [t, o] = useState(""), [n, r] = useState(!0);
|
|
@@ -72043,7 +72043,7 @@ BlockGridModel.registerFlow({
|
|
|
72043
72043
|
}
|
|
72044
72044
|
});
|
|
72045
72045
|
const parseMarkdown = _.memoize((e) => L(void 0, null, function* () {
|
|
72046
|
-
return e && (yield import("./md-
|
|
72046
|
+
return e && (yield import("./md-BbvRKckr.mjs")).default.render(e);
|
|
72047
72047
|
}));
|
|
72048
72048
|
function useParseMarkdown(e) {
|
|
72049
72049
|
const [t, o] = useState(""), [n, r] = useState(!0);
|
|
@@ -83703,7 +83703,12 @@ const CustomWidth = ({ setOpen: e, t, handleChange: o, defaultValue: n }) => {
|
|
|
83703
83703
|
] })
|
|
83704
83704
|
}
|
|
83705
83705
|
);
|
|
83706
|
-
}
|
|
83706
|
+
};
|
|
83707
|
+
function getSavedAssociationTitleField(e) {
|
|
83708
|
+
var t, o, n;
|
|
83709
|
+
return ((o = (t = e.getStepParams) == null ? void 0 : t.call(e, "tableColumnSettings", "fieldNames")) == null ? void 0 : o.label) || ((n = e.props) == null ? void 0 : n.titleField);
|
|
83710
|
+
}
|
|
83711
|
+
const Ze = class Ze extends DisplayItemModel {
|
|
83707
83712
|
afterAddAsSubModel() {
|
|
83708
83713
|
return L(this, null, function* () {
|
|
83709
83714
|
yield Ne(Ze.prototype, this, "afterAddAsSubModel").call(this), yield this.dispatchEvent("beforeRender");
|
|
@@ -83865,8 +83870,12 @@ TableColumnModel.registerFlow({
|
|
|
83865
83870
|
init: {
|
|
83866
83871
|
handler(e, t) {
|
|
83867
83872
|
return L(this, null, function* () {
|
|
83873
|
+
var i, a, l, c;
|
|
83868
83874
|
const o = e.model.context.collectionField;
|
|
83869
|
-
|
|
83875
|
+
if (!o)
|
|
83876
|
+
return;
|
|
83877
|
+
const n = getSavedAssociationTitleField(e.model), r = o.isAssociationField() && n ? x(x({}, o.getComponentProps()), (c = (l = (a = (i = o.targetCollection) == null ? void 0 : i.getField) == null ? void 0 : a.call(i, n)) == null ? void 0 : l.getComponentProps) == null ? void 0 : c.call(l)) : o.getComponentProps();
|
|
83878
|
+
e.model.setProps("title", o.title), e.model.setProps("dataIndex", o.name), yield e.model.applySubModelsBeforeRenderFlows("field"), e.model.setProps(x({}, r));
|
|
83870
83879
|
});
|
|
83871
83880
|
}
|
|
83872
83881
|
},
|
|
@@ -84019,7 +84028,7 @@ TableColumnModel.registerFlow({
|
|
|
84019
84028
|
defaultParams: (e) => {
|
|
84020
84029
|
const t = e.model.context.collectionField.targetCollectionTitleFieldName;
|
|
84021
84030
|
return {
|
|
84022
|
-
label: e.model
|
|
84031
|
+
label: getSavedAssociationTitleField(e.model) || t
|
|
84023
84032
|
};
|
|
84024
84033
|
},
|
|
84025
84034
|
handler(e, t) {
|
|
@@ -95954,9 +95963,9 @@ const openView = defineAction({
|
|
|
95954
95963
|
const se = typeof (o == null ? void 0 : o[ne]) != "undefined", re = a.includes(ne);
|
|
95955
95964
|
return se && !re ? o[ne] : typeof (t == null ? void 0 : t[ne]) != "undefined" ? t[ne] : se ? o[ne] : i == null ? void 0 : i[ne];
|
|
95956
95965
|
}, c = (() => {
|
|
95957
|
-
var se;
|
|
95966
|
+
var se, re;
|
|
95958
95967
|
const ne = l("filterByTk");
|
|
95959
|
-
return Array.isArray((
|
|
95968
|
+
return ((se = e.collection) == null ? void 0 : se.template) === "sql" && Array.isArray((re = e.collection) == null ? void 0 : re.filterTargetKey) && e.collection.filterTargetKey.length === 1 && ne != null && typeof ne != "object" ? { [e.collection.filterTargetKey[0]]: ne } : ne;
|
|
95960
95969
|
})(), u = l("sourceId"), d = typeof (o == null ? void 0 : o.dataSourceKey) != "undefined" ? o.dataSourceKey : t == null ? void 0 : t.dataSourceKey, p = typeof (o == null ? void 0 : o.collectionName) != "undefined" ? o.collectionName : t == null ? void 0 : t.collectionName, m = typeof (o == null ? void 0 : o.associationName) != "undefined" ? o.associationName : t == null ? void 0 : t.associationName, h = typeof o.tabUid != "undefined" ? o.tabUid : t.tabUid, g = (z = e.inputArgs) != null && z.isMobileLayout ? "embed" : ((U = e.inputArgs) == null ? void 0 : U.mode) || t.mode || "drawer";
|
|
95961
95970
|
let f = typeof o.navigation != "undefined" ? o.navigation : t.navigation;
|
|
95962
95971
|
if ((n || r) && (f = !1), f !== !1 && e.isNavigationEnabled !== !1 && !e.inputArgs.navigation && (K = e.view) != null && K.navigation) {
|