@nocobase/client 2.0.0-alpha.41 → 2.0.0-alpha.43

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 CHANGED
@@ -9620,7 +9620,7 @@ function addAppVersion(e, t) {
9620
9620
  addAppVersion((n = e.properties) == null ? void 0 : n[o], t);
9621
9621
  }), e;
9622
9622
  }
9623
- const name = "@nocobase/client", version = "2.0.0-alpha.41", license = "AGPL-3.0", main = "lib/index.js", module = "es/index.mjs", types = "es/index.d.ts", dependencies = {
9623
+ const name = "@nocobase/client", version = "2.0.0-alpha.43", license = "AGPL-3.0", main = "lib/index.js", module = "es/index.mjs", types = "es/index.d.ts", dependencies = {
9624
9624
  "@ahooksjs/use-url-state": "3.5.1",
9625
9625
  "@ant-design/cssinjs": "^1.11.1",
9626
9626
  "@ant-design/icons": "^5.6.1",
@@ -9643,10 +9643,10 @@ const name = "@nocobase/client", version = "2.0.0-alpha.41", license = "AGPL-3.0
9643
9643
  "@formily/reactive-react": "^2.2.27",
9644
9644
  "@formily/shared": "^2.2.27",
9645
9645
  "@formily/validator": "^2.2.27",
9646
- "@nocobase/evaluators": "2.0.0-alpha.41",
9647
- "@nocobase/flow-engine": "2.0.0-alpha.41",
9648
- "@nocobase/sdk": "2.0.0-alpha.41",
9649
- "@nocobase/utils": "2.0.0-alpha.41",
9646
+ "@nocobase/evaluators": "2.0.0-alpha.43",
9647
+ "@nocobase/flow-engine": "2.0.0-alpha.43",
9648
+ "@nocobase/sdk": "2.0.0-alpha.43",
9649
+ "@nocobase/utils": "2.0.0-alpha.43",
9650
9650
  "@tanstack/react-table": "^8.21.3",
9651
9651
  "@types/tabulator-tables": "^6.2.6",
9652
9652
  "acorn-jsx": "^5.3.2",
@@ -29139,6 +29139,13 @@ class Application {
29139
29139
  scope: this.scopes
29140
29140
  }), this.use(AntdAppProvider), this.use(DataSourceApplicationProvider, { dataSourceManager: this.dataSourceManager }), this.use(OpenModeProvider), this.flowEngine.context.defineProperty("app", {
29141
29141
  value: this
29142
+ }), this.flowEngine.context.defineProperty("appInfo", {
29143
+ get: () => O(this, null, function* () {
29144
+ var n;
29145
+ return ((n = (yield this.apiClient.request({
29146
+ url: "app:getInfo"
29147
+ })).data) == null ? void 0 : n.data) || {};
29148
+ })
29142
29149
  }), this.flowEngine.context.defineProperty("api", {
29143
29150
  value: this.apiClient
29144
29151
  }), this.flowEngine.context.defineProperty("i18n", {
@@ -30052,7 +30059,7 @@ const useStyles$a = genStyleHook("nb-markdown", (e, { isDarkTheme: t }) => {
30052
30059
  }, t ? i : r)
30053
30060
  };
30054
30061
  }), parseMarkdown$1 = _.memoize((e) => O(void 0, null, function* () {
30055
- return e && (yield import("./md-BbvRKckr.mjs")).default.render(e);
30062
+ return e && (yield import("./md-oH2RssNY.mjs")).default.render(e);
30056
30063
  }));
30057
30064
  function useParseMarkdown$1(e) {
30058
30065
  const [t, o] = useState(""), [n, r] = useState(!0);
@@ -67661,7 +67668,7 @@ BlockGridModel.registerFlow({
67661
67668
  }
67662
67669
  });
67663
67670
  const parseMarkdown = _.memoize((e) => O(void 0, null, function* () {
67664
- return e && (yield import("./md-oH2RssNY.mjs")).default.render(e);
67671
+ return e && (yield import("./md-BbvRKckr.mjs")).default.render(e);
67665
67672
  }));
67666
67673
  function useParseMarkdown(e) {
67667
67674
  const [t, o] = useState(""), [n, r] = useState(!0);
@@ -75097,7 +75104,11 @@ class JSBlockModel extends BlockModel {
75097
75104
  k(this, "_mountedOnce", !1);
75098
75105
  }
75099
75106
  render() {
75100
- return /* @__PURE__ */ jsx(Card, { id: `model-${this.uid}`, className: "code-block", children: /* @__PURE__ */ jsx("div", { ref: this.context.ref }) });
75107
+ const d = this.decoratorProps || {}, { className: n, id: r, title: i, description: a } = d, l = Y(d, ["className", "id", "title", "description"]), c = ["code-block", n].filter(Boolean).join(" "), u = i || a ? /* @__PURE__ */ jsxs("div", { children: [
75108
+ i && /* @__PURE__ */ jsx("span", { children: i }),
75109
+ a && /* @__PURE__ */ jsx("div", { children: a })
75110
+ ] }) : void 0;
75111
+ return /* @__PURE__ */ jsx(Card, I(f({ id: `model-${this.uid}`, className: c, title: u }, l), { children: /* @__PURE__ */ jsx("div", { ref: this.context.ref }) }));
75101
75112
  }
75102
75113
  onMount() {
75103
75114
  this._mountedOnce && this.context.ref.current && this.rerender(), this._mountedOnce = !0;
@@ -83421,10 +83432,11 @@ const displayFieldComponent = defineAction({
83421
83432
  });
83422
83433
  },
83423
83434
  handler(e, t) {
83424
- return O(this, null, function* () {
83425
- t.pattern && e.model.setProps({
83426
- pattern: t.pattern
83427
- });
83435
+ t.pattern === "readPretty" ? e.model.setProps({
83436
+ pattern: "readPretty"
83437
+ }) : e.model.setProps({
83438
+ disabled: t.pattern === "disabled",
83439
+ pattern: null
83428
83440
  });
83429
83441
  }
83430
83442
  });