@kashifd/jwero-components 0.7.8 → 0.7.10

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/dist/index.es.js CHANGED
@@ -48487,10 +48487,10 @@ const iW = ({
48487
48487
  },
48488
48488
  d.value
48489
48489
  )) }) }),
48490
- /* @__PURE__ */ b.jsx(nv, { children: pn.isArrayWithValues(t) && t.map((d) => /* @__PURE__ */ b.jsx(
48490
+ /* @__PURE__ */ b.jsx(nv, { children: pn.isArrayWithValues(t) && t.map((d, g) => /* @__PURE__ */ b.jsx(
48491
48491
  yd,
48492
48492
  {
48493
- onClick: (g) => s(g, d),
48493
+ onClick: (m) => s(m, d),
48494
48494
  sx: {
48495
48495
  "&:last-child td, &:last-child th": { border: 0 },
48496
48496
  borderBottom: '1px solid "#f5f6f7"',
@@ -48500,18 +48500,18 @@ const iW = ({
48500
48500
  backgroundColor: c.palette.background.default
48501
48501
  }
48502
48502
  },
48503
- children: r.map((g) => /* @__PURE__ */ b.jsx(
48503
+ children: r.map((m) => /* @__PURE__ */ b.jsx(
48504
48504
  xd,
48505
48505
  {
48506
48506
  component: "th",
48507
48507
  scope: "row",
48508
- align: g.align,
48509
- children: a == null ? void 0 : a[g == null ? void 0 : g.value](d)
48508
+ align: m.align,
48509
+ children: a == null ? void 0 : a[m == null ? void 0 : m.value](d)
48510
48510
  },
48511
- g.value
48511
+ m.value
48512
48512
  ))
48513
48513
  },
48514
- d.id
48514
+ `${d.id}_${g}`
48515
48515
  )) })
48516
48516
  ] })
48517
48517
  }
@@ -58728,12 +58728,14 @@ const xz = ({
58728
58728
  isOverdue: !1,
58729
58729
  label: null
58730
58730
  };
58731
- if (!Ym(e) || !Ym(t))
58731
+ if (!Ym(e))
58732
58732
  return {
58733
58733
  showDueDate: !1,
58734
58734
  isOverdue: !1,
58735
58735
  label: null
58736
58736
  };
58737
+ if (r === "completed" && !Ym(t))
58738
+ return { showDueDate: !1, isOverdue: !1, label: null };
58737
58739
  try {
58738
58740
  const a = new Date(e).getTime(), s = new Date(t).getTime(), c = (/* @__PURE__ */ new Date()).getTime();
58739
58741
  if (isNaN(a))
@@ -58869,7 +58871,9 @@ const yz = (e, t = 10) => {
58869
58871
  dueDate: e == null ? void 0 : e.dueDate,
58870
58872
  completedOn: e == null ? void 0 : e.completedOn,
58871
58873
  type: e == null ? void 0 : e.status
58872
- }), M = j ? T.colors.light_red : T.colors.light_green, U = j ? T.colors.negative : T.colors.positive, X = j ? `Overdue ${z}` : `Completed ${z}`, L = g && (e == null ? void 0 : e.status) !== "completed";
58874
+ });
58875
+ console.log(j, R, z);
58876
+ const M = j ? T.colors.light_red : T.colors.light_green, U = j ? T.colors.negative : T.colors.positive, X = j ? `Overdue ${z}` : (e == null ? void 0 : e.status) === "completed" ? `Completed ${z}` : "", L = g && (e == null ? void 0 : e.status) !== "completed";
58873
58877
  return /* @__PURE__ */ b.jsxs(
58874
58878
  Ue,
58875
58879
  {