@dxs-ts/eveli-ide 0.0.173 → 0.0.174

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.
@@ -43,6 +43,10 @@ export declare namespace HdesApi {
43
43
  interface ProgramMessage {
44
44
  id: string;
45
45
  msg: string;
46
+ exception?: {
47
+ column?: number;
48
+ row?: number;
49
+ };
46
50
  }
47
51
  interface AstCommand {
48
52
  id?: string;
package/build/index.js CHANGED
@@ -65984,17 +65984,19 @@ const F8n = ({ builder: n, onChange: i }) => /* @__PURE__ */ b(
65984
65984
  ) : null
65985
65985
  ] });
65986
65986
  }, $8n = ({ decision: n, onChange: i }) => {
65987
- const o = [...n.headers.acceptDefs, ...n.headers.returnDefs];
65987
+ const o = [...n.headers.acceptDefs, ...n.headers.returnDefs], [c, u] = be.useState("");
65988
65988
  return /* @__PURE__ */ b(
65989
65989
  va,
65990
65990
  {
65991
65991
  label: "decisions.toolbar.organize.action.deleteColumn",
65992
65992
  helperText: "decisions.toolbar.organize.action.deleteColumn.helper",
65993
- onChange: (c) => i({ id: c, type: "DELETE_HEADER" }),
65994
- selected: "",
65995
- items: o.map((c) => ({
65996
- id: c.id,
65997
- value: /* @__PURE__ */ b(qo, { primary: c.name })
65993
+ onChange: (m) => {
65994
+ u(m), i({ id: m, type: "DELETE_HEADER" });
65995
+ },
65996
+ selected: c,
65997
+ items: o.map((m) => ({
65998
+ id: m.id,
65999
+ value: /* @__PURE__ */ b(qo, { primary: m.name })
65998
66000
  }))
65999
66001
  }
66000
66002
  );
@@ -108206,19 +108208,27 @@ const mBn = ({ locale: n }) => /* @__PURE__ */ b("div", { style: { fontWeight: "
108206
108208
  }, children: /* @__PURE__ */ b(ve, { id: "buttons.apply" }) })
108207
108209
  ] })
108208
108210
  ] });
108209
- }, wBn = ({ header: n, cell: i, onClick: o, dt: c, onChange: u }) => {
108210
- const [m, p] = be.useState({ open: !1, locale: "" }), w = $u(), v = w.palette.mode === "light" ? ek(fd(w.palette.divider, 1), 0.88) : UPe(fd(w.palette.divider, 1), 0.68), E = /* @__PURE__ */ b(YD, {});
108211
+ }, wBn = ({ header: n, cell: i, onClick: o, dt: c, onChange: u, errors: m, row: p }) => {
108212
+ const [w, v] = be.useState({ open: !1, locale: "" }), E = $u(), S = E.palette.mode === "light" ? ek(fd(E.palette.divider, 1), 0.88) : UPe(fd(E.palette.divider, 1), 0.68), I = /* @__PURE__ */ b(YD, {});
108211
108213
  if (n.direction === "IN")
108212
- return /* @__PURE__ */ b(Ir, { onClick: () => o(), sx: { cursor: "pointer", borderRight: `1px ${v} solid` }, children: /* @__PURE__ */ b(Ue, { noWrap: !0, display: "flex", children: i != null && i.value ? i.value : /* @__PURE__ */ b(ht, { sx: { fontWeight: "bold" }, component: "span", children: E }) }) }, i.header);
108214
+ return /* @__PURE__ */ b(Ir, { onClick: () => o(), sx: { cursor: "pointer", borderRight: `1px ${S} solid` }, children: /* @__PURE__ */ b(Ue, { noWrap: !0, display: "flex", children: i != null && i.value ? i.value : /* @__PURE__ */ b(ht, { sx: { fontWeight: "bold" }, component: "span", children: I }) }) }, i.header);
108213
108215
  if (n.valueType === "INTL") {
108214
- let S = function() {
108215
- p({ open: !1, locale: "" });
108216
- }, I = function(D) {
108217
- p({ open: !0, locale: D });
108216
+ let D = function() {
108217
+ v({ open: !1, locale: "" });
108218
+ }, M = function(Z) {
108219
+ v({ open: !0, locale: Z });
108218
108220
  };
108219
- return /* @__PURE__ */ _(Ir, { sx: { cursor: "pointer", borderRight: `1px ${v} solid` }, children: [
108220
- m.open && /* @__PURE__ */ b(bBn, { dt: c, cell: i, locale: m.locale, onClose: S, onChange: u }),
108221
- /* @__PURE__ */ b(kPt, { variant: "text", children: (n.valueSet ?? []).map((D) => /* @__PURE__ */ b(Wm, { title: new kq({ value: i.value ?? "{}", header: n }).getLocaleValue(D), children: /* @__PURE__ */ b(Ft, { onClick: () => I(D), children: /* @__PURE__ */ b(Ue, { textTransform: "uppercase", fontWeight: "bold", children: D }) }) }, n.id)) })
108221
+ const P = m.find((Z) => {
108222
+ var Y, X;
108223
+ return ((Y = Z.exception) == null ? void 0 : Y.row) === p.order && ((X = Z.exception) == null ? void 0 : X.column) === n.order;
108224
+ });
108225
+ return /* @__PURE__ */ _(Ir, { sx: {
108226
+ cursor: "pointer",
108227
+ borderRight: `1px ${S} solid`,
108228
+ backgroundColor: P ? E.palette.error.main : void 0
108229
+ }, children: [
108230
+ w.open && /* @__PURE__ */ b(bBn, { dt: c, cell: i, locale: w.locale, onClose: D, onChange: u }),
108231
+ /* @__PURE__ */ b(kPt, { variant: "text", children: (n.valueSet ?? []).map((Z) => /* @__PURE__ */ b(Wm, { title: (P == null ? void 0 : P.msg) ?? new kq({ value: i.value ?? "{}", header: n }).getLocaleValue(Z), children: /* @__PURE__ */ b(Ft, { onClick: () => M(Z), children: /* @__PURE__ */ b(Ue, { textTransform: "uppercase", fontWeight: "bold", children: Z }) }) }, n.id)) })
108222
108232
  ] }, i.header);
108223
108233
  }
108224
108234
  return /* @__PURE__ */ b(
@@ -108227,9 +108237,9 @@ const mBn = ({ locale: n }) => /* @__PURE__ */ b("div", { style: { fontWeight: "
108227
108237
  onClick: () => o(),
108228
108238
  sx: {
108229
108239
  cursor: "pointer",
108230
- borderRight: `1px ${v} solid`
108240
+ borderRight: `1px ${S} solid`
108231
108241
  },
108232
- children: /* @__PURE__ */ b(Ue, { noWrap: !0, children: i != null && i.value ? i == null ? void 0 : i.value : E })
108242
+ children: /* @__PURE__ */ b(Ue, { noWrap: !0, children: i != null && i.value ? i == null ? void 0 : i.value : I })
108233
108243
  },
108234
108244
  i.header
108235
108245
  );
@@ -108356,7 +108366,7 @@ const Gde = Xje, kBn = (n) => {
108356
108366
  /* @__PURE__ */ b(Ft, { variant: "text", onClick: () => E({ rowsColumns: !0 }), children: /* @__PURE__ */ b(ve, { id: "decisions.toolbar.organize.rows.columns" }) })
108357
108367
  ] }),
108358
108368
  renderRow: (M) => /* @__PURE__ */ b(Gde.Row, { ...M }),
108359
- renderCell: (M) => /* @__PURE__ */ b(Gde.Cell, { onChange: I, ...M, dt: p, onClick: () => E({ cell: M.cell }) })
108369
+ renderCell: (M) => /* @__PURE__ */ b(Gde.Cell, { onChange: I, ...M, dt: p, errors: n.errors, onClick: () => E({ cell: M.cell }) })
108360
108370
  }
108361
108371
  )
108362
108372
  ] }) : /* @__PURE__ */ b("span", { children: "loading ..." });
@@ -118585,7 +118595,7 @@ function _Kn(n) {
118585
118595
  unreadTasks: u ?? []
118586
118596
  };
118587
118597
  }
118588
- const EDt = { tag: "eveli-ide-0.0.173", built: "27/03/2025" }, NWt = ls("worker/rest/api/version.GET")({
118598
+ const EDt = { tag: "eveli-ide-0.0.174", built: "28/03/2025" }, NWt = ls("worker/rest/api/version.GET")({
118589
118599
  hook: $Kn
118590
118600
  });
118591
118601
  function $Kn(n) {
@@ -1,6 +1,7 @@
1
1
  import { default as React } from 'react';
2
2
  import { HdesApi } from '../../api-wrench';
3
3
  declare const DecisionTableCell: React.FC<{
4
+ errors: HdesApi.ProgramMessage[];
4
5
  dt: HdesApi.AstDecision;
5
6
  row: HdesApi.AstDecisionRow;
6
7
  header: HdesApi.TypeDef;
@@ -6,6 +6,7 @@ declare namespace Decision {
6
6
  renderCell: (props: import("./DecisionTable").RenderCellProps) => React.ReactNode;
7
7
  }>;
8
8
  const Cell: import("react").FC<{
9
+ errors: import("../..").HdesApi.ProgramMessage[];
9
10
  dt: import("../..").HdesApi.AstDecision;
10
11
  row: import("../..").HdesApi.AstDecisionRow;
11
12
  header: import("../..").HdesApi.TypeDef;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dxs-ts/eveli-ide",
3
- "version": "0.0.173",
3
+ "version": "0.0.174",
4
4
  "homepage": "https://github.com/digiexpress-io/digiexpress-parent",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",