master-components-react 4.2.39 → 4.2.41

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.
@@ -72370,76 +72370,77 @@ const jle = "ColumnConfigure-module__configureWrapper", qle = "ColumnConfigure-m
72370
72370
  d: "M13.367 2.517L6.8 9.083c-.25.25-.5.742-.55 1.1l-.358 2.509c-.134.908.508 1.541 1.416 1.416l2.509-.358c.35-.05.841-.3 1.1-.55l6.566-6.567c1.134-1.133 1.667-2.45 0-4.116-1.666-1.667-2.983-1.134-4.116 0zM12.425 3.458a5.954 5.954 0 004.117 4.117"
72371
72371
  }
72372
72372
  )
72373
- ] }), sue = ({ actions: e, onExpand: t, rowID: i, visible: n, rowData: r, theme: a }) => {
72374
- const o = Xe(null), s = Xe(null), l = Xe({
72373
+ ] }), sue = ({ actions: e, onExpand: t, rowID: i, visible: n, rowData: r, hiddenActionTypes: a, theme: o }) => {
72374
+ const s = Xe(null), l = Xe(null), u = Xe({
72375
72375
  top: 0,
72376
72376
  left: 0
72377
- }), u = (p) => {
72378
- t && typeof t == "function" && (t(!n), d());
72379
- }, d = () => {
72380
- const p = o.current.getBoundingClientRect(), v = s.current.getBoundingClientRect();
72381
- l.current.top = p.top + v.height + 20, l.current.left = p.left - v.width / 1.5;
72382
- }, c = (p, v) => {
72383
- r[v.disableKey] || v.event && typeof v.event == "function" && v.event(v.type, r);
72384
- }, h = (p) => {
72385
- let v;
72386
- const g = ["delete", "edit"];
72387
- if (p.type && g.includes(p.type))
72388
- switch (p.type === "delete" && (p.style = { color: "#D92D20" }), String(p.type)) {
72377
+ }), d = (v) => {
72378
+ t && typeof t == "function" && (t(!n), c());
72379
+ }, c = () => {
72380
+ const v = s.current.getBoundingClientRect(), g = l.current.getBoundingClientRect();
72381
+ u.current.top = v.top + g.height + 20, u.current.left = v.left - g.width / 1.5;
72382
+ }, h = (v, g) => {
72383
+ r[g.disableKey] || g.event && typeof g.event == "function" && g.event(g.type, r);
72384
+ }, f = (v) => {
72385
+ let g;
72386
+ const C = ["delete", "edit"];
72387
+ if (v.type && C.includes(v.type))
72388
+ switch (v.type === "delete" && (v.style = { color: "#D92D20" }), String(v.type)) {
72389
72389
  case "delete": {
72390
- v = /* @__PURE__ */ E.jsx(Km, {});
72390
+ g = /* @__PURE__ */ E.jsx(Km, {});
72391
72391
  break;
72392
72392
  }
72393
72393
  case "edit": {
72394
- v = /* @__PURE__ */ E.jsx(Qk, {});
72394
+ g = /* @__PURE__ */ E.jsx(Qk, {});
72395
72395
  break;
72396
72396
  }
72397
72397
  }
72398
- else v = "no_icon";
72399
- return v;
72400
- }, f = (p) => p.labelIcon && typeof p.labelIcon == "function" ? p.labelIcon() : null;
72398
+ else g = "no_icon";
72399
+ return g;
72400
+ }, p = (v) => v.labelIcon && typeof v.labelIcon == "function" ? v.labelIcon() : null;
72401
72401
  return /* @__PURE__ */ E.jsxs(
72402
72402
  "div",
72403
72403
  {
72404
72404
  id: `datagrid_action_data_id_${i}`,
72405
- className: `${a === "dark" ? no.dark : ""}${no.actionsWrapper} datagrid_action_data_controller`,
72406
- onClick: (p) => p.stopPropagation(),
72405
+ className: `${o === "dark" ? no.dark : ""}${no.actionsWrapper} datagrid_action_data_controller`,
72406
+ onClick: (v) => v.stopPropagation(),
72407
72407
  children: [
72408
- /* @__PURE__ */ E.jsxs("div", { className: no.moreActionsButton, onClick: (p) => u(), ref: o, children: [
72408
+ /* @__PURE__ */ E.jsxs("div", { className: no.moreActionsButton, onClick: (v) => d(), ref: s, children: [
72409
72409
  /* @__PURE__ */ E.jsx("div", {}),
72410
72410
  /* @__PURE__ */ E.jsx("div", {}),
72411
72411
  /* @__PURE__ */ E.jsx("div", {})
72412
72412
  ] }),
72413
- /* @__PURE__ */ E.jsx("ul", { ref: s, children: e && e.map((p, v) => p.hiddenActionTypes && Array.isArray(p.hiddenActionTypes) && p.hiddenActionTypes.includes(i) ? null : /* @__PURE__ */ E.jsxs(
72413
+ /* @__PURE__ */ E.jsx("ul", { ref: l, children: e && e.map((v, g) => v.hiddenActionRows && Array.isArray(v.hiddenActionRows) && v.hiddenActionRows.includes(i) ? null : /* @__PURE__ */ E.jsxs(
72414
72414
  "li",
72415
72415
  {
72416
- onClick: (C) => c(C, p),
72416
+ onClick: (x) => h(x, v),
72417
72417
  style: {
72418
- cursor: r[p.disableKey] ? "not-allowed" : "pointer"
72418
+ display: a && a.includes(v.type) ? "none" : "flex",
72419
+ cursor: r[v.disableKey] ? "not-allowed" : "pointer"
72419
72420
  },
72420
72421
  children: [
72421
72422
  /* @__PURE__ */ E.jsx(
72422
72423
  "div",
72423
72424
  {
72424
72425
  className: `
72425
- ${["delete"].includes(p.type) ? no.staticColor : ""}
72426
+ ${["delete"].includes(v.type) ? no.staticColor : ""}
72426
72427
  ${no.actionIcon}
72427
- ${h(p) && h(p) !== "no_icon" ? no.defaultIcons : ""}
72428
+ ${f(v) && f(v) !== "no_icon" ? no.defaultIcons : ""}
72428
72429
  `,
72429
72430
  style: {
72430
- opacity: r[p.disableKey] ? 0.5 : 1
72431
+ opacity: r[v.disableKey] ? 0.5 : 1
72431
72432
  },
72432
- children: h(p) && h(p) !== "no_icon" ? h(p) : p == null ? void 0 : p.icon()
72433
+ children: f(v) && f(v) !== "no_icon" ? f(v) : v == null ? void 0 : v.icon()
72433
72434
  }
72434
72435
  ),
72435
72436
  /* @__PURE__ */ E.jsxs("div", { className: no.actionLabel, children: [
72436
- /* @__PURE__ */ E.jsx("p", { style: { ...p == null ? void 0 : p.style, opacity: r[p.disableKey] ? 0.5 : 1 }, children: p == null ? void 0 : p.label }),
72437
+ /* @__PURE__ */ E.jsx("p", { style: { ...v == null ? void 0 : v.style, opacity: r[v.disableKey] ? 0.5 : 1 }, children: v == null ? void 0 : v.label }),
72437
72438
  " ",
72438
- f(p)
72439
+ p(v)
72439
72440
  ] })
72440
72441
  ]
72441
72442
  },
72442
- v
72443
+ g
72443
72444
  )) })
72444
72445
  ]
72445
72446
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "master-components-react",
3
3
  "private": false,
4
- "version": "4.2.39",
4
+ "version": "4.2.41",
5
5
  "type": "module",
6
6
  "main": "dist/master-components-react.cjs.js",
7
7
  "module": "dist/master-components-react.es.js",