@ai-matrx/design-system 0.18.19 → 0.18.21

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/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.18.21
4
+
5
+ Automatic changed-only republish (docs/metadata drift since the last tag — see
6
+ `git diff npm/design-system/v0.18.20..npm/design-system/v0.18.21 -- apps/shared/design-system`).
7
+ No source changes intended and no consumer action required.
8
+
9
+ ## 0.18.20
10
+
11
+ Automatic changed-only republish (docs/metadata drift since the last tag — see
12
+ `git diff npm/design-system/v0.18.19..npm/design-system/v0.18.20 -- apps/shared/design-system`).
13
+ No source changes intended and no consumer action required.
14
+
3
15
  ## 0.18.19
4
16
 
5
17
  Automatic changed-only republish (docs/metadata drift since the last tag — see
@@ -924,7 +924,7 @@ function TableTitleRow({
924
924
  {
925
925
  "data-matrx-table-toolbar": true,
926
926
  className: cn(
927
- "flex min-w-0 shrink-0 flex-wrap items-center gap-2 border-t border-border pt-2",
927
+ "flex min-w-0 shrink-0 flex-wrap items-center gap-2",
928
928
  className
929
929
  ),
930
930
  children: [
@@ -951,7 +951,7 @@ function TableTitleRow({
951
951
  "div",
952
952
  {
953
953
  "data-matrx-table-actions": true,
954
- className: "ml-auto flex min-w-0 flex-wrap items-center gap-2",
954
+ className: "ml-auto flex min-w-0 flex-wrap items-center gap-0",
955
955
  children: actions
956
956
  }
957
957
  ) : null
@@ -7265,7 +7265,10 @@ function MatrxDataTableCore({
7265
7265
  ...appendQuery?.scroll
7266
7266
  });
7267
7267
  const rootRef = (0, import_react13.useRef)(null);
7268
+ const actionDiagnosticObserver = (0, import_react13.useRef)(null);
7268
7269
  const setDiagnosticBoundaryRef = (0, import_react13.useCallback)((node) => {
7270
+ actionDiagnosticObserver.current?.disconnect();
7271
+ actionDiagnosticObserver.current = null;
7269
7272
  rootRef.current = node;
7270
7273
  if (!node) return;
7271
7274
  node.style.setProperty("outline", "2px solid #2563eb", "important");
@@ -7283,6 +7286,22 @@ function MatrxDataTableCore({
7283
7286
  boundary.style.setProperty("z-index", "2147483647", "important");
7284
7287
  boundary.style.setProperty("box-sizing", "border-box", "important");
7285
7288
  boundary.style.setProperty("border", "2px solid #2563eb", "important");
7289
+ const paintActionDiagnostics = () => {
7290
+ const paint = (selector, color) => {
7291
+ for (const element of Array.from(node.querySelectorAll(selector))) {
7292
+ if (element.closest("[data-matrx-table]") !== node) continue;
7293
+ element.style.setProperty("outline", `1px solid ${color}`, "important");
7294
+ element.style.setProperty("outline-offset", "-1px", "important");
7295
+ }
7296
+ };
7297
+ paint("[data-matrx-table-row-action-cell], [data-matrx-table-row-actions]", "#16a34a");
7298
+ paint("[data-matrx-table-row-actions] :is(button, a)", "#f97316");
7299
+ paint("[data-matrx-table-row-actions] .matrx-tap-pill", "#a855f7");
7300
+ paint("[data-matrx-table-row-actions] svg", "#ef4444");
7301
+ };
7302
+ paintActionDiagnostics();
7303
+ actionDiagnosticObserver.current = new MutationObserver(paintActionDiagnostics);
7304
+ actionDiagnosticObserver.current.observe(node, { childList: true, subtree: true });
7286
7305
  }, []);
7287
7306
  useClippedContentGuard(rootRef, {
7288
7307
  label: typeof copy === "object" && copy.listLabel ? `Table: ${copy.listLabel}` : "MatrxDataTable"
@@ -8162,7 +8181,7 @@ function MatrxDataTableCore({
8162
8181
  // where every row read as an empty text input rather than a selection
8163
8182
  // control. The control keeps its own size and gains the 44px tap area
8164
8183
  // as an invisible ::before below.
8165
- "flex h-full min-h-0 flex-col gap-2 max-lg:[&_button:not([role=checkbox]):not([role=radio]):not([role=switch])]:min-h-11 max-lg:[&_button:not([role=checkbox]):not([role=radio]):not([role=switch])]:min-w-11 max-lg:[&_input]:min-h-11 max-lg:[&_table_a]:inline-flex max-lg:[&_table_a]:min-h-11 max-lg:[&_table_a]:items-center",
8184
+ "flex h-full min-h-0 flex-col p-2 max-lg:[&_button:not([role=checkbox]):not([role=radio]):not([role=switch])]:min-h-11 max-lg:[&_button:not([role=checkbox]):not([role=radio]):not([role=switch])]:min-w-11 max-lg:[&_input]:min-h-11 max-lg:[&_table_a]:inline-flex max-lg:[&_table_a]:min-h-11 max-lg:[&_table_a]:items-center",
8166
8185
  className
8167
8186
  ),
8168
8187
  children: [
@@ -8288,7 +8307,7 @@ function MatrxDataTableCore({
8288
8307
  "div",
8289
8308
  {
8290
8309
  "data-matrx-table-actions": true,
8291
- className: "ml-auto flex min-w-0 flex-wrap items-center gap-2",
8310
+ className: "ml-auto flex min-w-0 flex-wrap items-center gap-0",
8292
8311
  children: [
8293
8312
  sourceTotal !== void 0 ? /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(
8294
8313
  "span",
@@ -8540,7 +8559,8 @@ function MatrxDataTableCore({
8540
8559
  actions: showRowCopy || rowActions ? /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(
8541
8560
  "div",
8542
8561
  {
8543
- className: "inline-flex items-center gap-0",
8562
+ "data-matrx-table-row-actions": true,
8563
+ className: "inline-flex items-center justify-end gap-0",
8544
8564
  onClick: (event) => event.stopPropagation(),
8545
8565
  children: [
8546
8566
  showRowCopy && effectiveCopy ? /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
@@ -8715,7 +8735,7 @@ function MatrxDataTableCore({
8715
8735
  id
8716
8736
  );
8717
8737
  }),
8718
- showActionsCol && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("th", { className: "h-9 w-28 px-2 text-right align-middle text-xs font-semibold uppercase tracking-wide text-muted-foreground", children: "Actions" })
8738
+ showActionsCol && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("th", { className: "h-9 w-px text-right align-middle text-xs font-semibold uppercase tracking-wide text-muted-foreground", children: "Actions" })
8719
8739
  ] }) }),
8720
8740
  /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)("tbody", { children: [
8721
8741
  isLoading ? Array.from({ length: 6 }).map((_, i) => /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)("tr", { className: "border-b border-border/60", children: [
@@ -8732,7 +8752,7 @@ function MatrxDataTableCore({
8732
8752
  },
8733
8753
  columnId(col)
8734
8754
  )),
8735
- showActionsCol && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("td", { className: "px-2 py-2", children: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(Skeleton, { className: "ml-auto h-5 w-10" }) })
8755
+ showActionsCol && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("td", { className: "text-right align-middle", children: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(Skeleton, { className: "ml-auto h-5 w-10" }) })
8736
8756
  ] }, `sk-${i}`)) : paginated.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("tr", { children: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(
8737
8757
  "td",
8738
8758
  {
@@ -8840,9 +8860,10 @@ function MatrxDataTableCore({
8840
8860
  columnId(col)
8841
8861
  );
8842
8862
  }),
8843
- showActionsCol && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("td", { className: "px-2 py-1.5 text-right align-middle lg:py-0.5", children: /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(
8863
+ showActionsCol && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("td", { "data-matrx-table-row-action-cell": true, className: "text-right align-middle", children: /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(
8844
8864
  "div",
8845
8865
  {
8866
+ "data-matrx-table-row-actions": true,
8846
8867
  className: "inline-flex items-center justify-end gap-0",
8847
8868
  onClick: (e) => e.stopPropagation(),
8848
8869
  children: [
@@ -8947,7 +8968,7 @@ function MatrxDataTableCore({
8947
8968
  },
8948
8969
  columnId(column)
8949
8970
  )),
8950
- showActionsCol ? /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("td", { className: "px-2 py-2" }) : null
8971
+ showActionsCol ? /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("td", {}) : null
8951
8972
  ] }, `footer-${index}`)) }) : null
8952
8973
  ] })
8953
8974
  ]
@@ -8990,7 +9011,7 @@ function MatrxDataTableCore({
8990
9011
  "div",
8991
9012
  {
8992
9013
  "data-matrx-table-footer": true,
8993
- className: "flex min-h-16 shrink-0 flex-wrap items-center justify-between gap-3 border-t border-border px-3 py-2",
9014
+ className: "flex min-h-16 shrink-0 flex-wrap items-center justify-between gap-3 border-t border-border",
8994
9015
  "aria-busy": isLoading || isFetching,
8995
9016
  children: [
8996
9017
  /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(