@godxjp/ui 31.31.6 → 31.31.7

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.
@@ -3,7 +3,7 @@
3
3
  You are about to write code against a design system you did not author. This file is the whole
4
4
  contract. Read it before you write JSX.
5
5
 
6
- **This catalog describes `@godxjp/ui` 31.31.6.** If the project you are editing has a different
6
+ **This catalog describes `@godxjp/ui` 31.31.7.** If the project you are editing has a different
7
7
  version in its `package.json`, read the pinned catalog for THAT version instead
8
8
  (`…/v<their-version>/agent/…`). A catalog newer than the installed package describes props that do
9
9
  not exist yet; older, and it hides props that do. Neither failure announces itself.
package/agent/index.json CHANGED
@@ -48,7 +48,7 @@
48
48
  "note": "Pin to the tag that matches the @godxjp/ui version you installed. A catalog newer than your package describes props you do not have; older, and it hides props you do.",
49
49
  "read": {
50
50
  "live": "https://raw.githubusercontent.com/godx-jp/godxjp-ui/main/agent/index.json",
51
- "pinned": "https://raw.githubusercontent.com/godx-jp/godxjp-ui/v31.31.6/agent/index.json"
51
+ "pinned": "https://raw.githubusercontent.com/godx-jp/godxjp-ui/v31.31.7/agent/index.json"
52
52
  },
53
53
  "source": "mcp/src/data — the same data @godxjp/ui-mcp serves — plus the foundation and semantic token tiers, read from src/tokens/*.css",
54
54
  "start": "https://raw.githubusercontent.com/godx-jp/godxjp-ui/main/agent/START-HERE.md",
@@ -62,5 +62,5 @@
62
62
  "foundation": "the seeds a consumer is invited to set — --primary, --background, --radius",
63
63
  "semantic": "named roles that follow the seeds — --ring, --text-link, --overlay-background"
64
64
  },
65
- "version": "31.31.6"
65
+ "version": "31.31.7"
66
66
  }
package/agent/llms.txt CHANGED
@@ -1,10 +1,10 @@
1
1
  # @godxjp/ui
2
2
 
3
3
  > A Japanese-enterprise React design system: 185 components, 2188 design tokens,
4
- > 50 cardinal rules. This file is the entry point for AI agents. Catalog version 31.31.6.
4
+ > 50 cardinal rules. This file is the entry point for AI agents. Catalog version 31.31.7.
5
5
 
6
6
  If your client can run a process, do not read these files — run the MCP server instead
7
- (`npx @godxjp/ui-mcp@31.31.6`). It is searchable and version-locked. These files exist for agents
7
+ (`npx @godxjp/ui-mcp@31.31.7`). It is searchable and version-locked. These files exist for agents
8
8
  that can only fetch URLs.
9
9
 
10
10
  ## Start
@@ -26,7 +26,7 @@ that can only fetch URLs.
26
26
  ## Pinning
27
27
 
28
28
  Every URL above tracks `main`. To pin to the release a project actually installed, swap `main` for
29
- the tag: `.../godx-jp/godxjp-ui/v31.31.6/agent/...`. A catalog that does not match the installed
29
+ the tag: `.../godx-jp/godxjp-ui/v31.31.7/agent/...`. A catalog that does not match the installed
30
30
  package describes props that are absent, or hides props that are present, and says nothing either way.
31
31
 
32
32
  Pinned catalogs only exist for releases whose tag actually contains `agent/`. If `…/v<version>/agent/index.json` returns 404, that release predates this catalog: read `…/main/…` instead and compare `index.json` → `version` against the package you have, so you at least know which way it drifted.
@@ -9,6 +9,7 @@ function scrollRegionLabel(label, t) {
9
9
  return typeof label === "string" && label.trim() !== "" ? label : t("dataTable.scrollRegion");
10
10
  }
11
11
  const ACTIONS_CONTENT_WIDTH = "--table-action-collection-actions-content-width";
12
+ const ACTIONS_FIT_MIN_INLINE_SIZE = "--table-action-collection-actions-fit-min-inline-size";
12
13
  function useActionsColumnFit(ref, enabled) {
13
14
  React.useLayoutEffect(() => {
14
15
  const box = ref.current;
@@ -17,10 +18,19 @@ function useActionsColumnFit(ref, enabled) {
17
18
  const observedContents = /* @__PURE__ */ new Set();
18
19
  const measure = () => {
19
20
  box.style.removeProperty(ACTIONS_CONTENT_WIDTH);
21
+ box.style.removeProperty(ACTIONS_FIT_MIN_INLINE_SIZE);
22
+ const table = box.querySelector(":scope > table");
23
+ const baseTableWidth = table?.getBoundingClientRect().width ?? 0;
24
+ let actionsCell = null;
25
+ let baseActionsWidth = 0;
20
26
  let needed = 0;
21
27
  box.querySelectorAll(".ui-table-actions-content").forEach((content) => {
22
28
  const cell = content.parentElement;
23
29
  if (!cell) return;
30
+ if (!actionsCell) {
31
+ actionsCell = cell;
32
+ baseActionsWidth = cell.getBoundingClientRect().width;
33
+ }
24
34
  const style = getComputedStyle(cell);
25
35
  const inset = parseFloat(style.paddingInlineStart) + parseFloat(style.paddingInlineEnd);
26
36
  const rect = content.getBoundingClientRect();
@@ -38,7 +48,19 @@ function useActionsColumnFit(ref, enabled) {
38
48
  const edges = style.boxSizing === "border-box" ? inset + parseFloat(style.borderInlineStartWidth) + parseFloat(style.borderInlineEndWidth) : 0;
39
49
  needed = Math.max(needed, Math.ceil(width + edges));
40
50
  });
41
- if (needed > 0) box.style.setProperty(ACTIONS_CONTENT_WIDTH, `${needed}px`);
51
+ if (needed === 0) return;
52
+ box.style.setProperty(ACTIONS_CONTENT_WIDTH, `${needed}px`);
53
+ const fitted = actionsCell;
54
+ if (!table || !fitted) return;
55
+ const baseOthers = baseTableWidth - baseActionsWidth;
56
+ const tableWidth = table.getBoundingClientRect().width;
57
+ const others = tableWidth - fitted.getBoundingClientRect().width;
58
+ if (others > 0 && others < baseOthers - 0.5) {
59
+ box.style.setProperty(
60
+ ACTIONS_FIT_MIN_INLINE_SIZE,
61
+ `${Math.ceil(tableWidth * baseOthers / others)}px`
62
+ );
63
+ }
42
64
  };
43
65
  let frame = 0;
44
66
  let rowsChanged = false;
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "$comment": "AUTO-GENERATED by scripts/gen-measurement-contract.mjs — do not edit. Read this instead of guessing: docs/MEASUREMENT-CONTRACT.md.",
3
- "version": "31.31.6",
3
+ "version": "31.31.7",
4
4
  "targetSize": {
5
5
  "standard": "WCAG 2.2 SC 2.5.8 Target Size (Minimum), level AA — 24×24 CSS px",
6
6
  "min": 24,
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "31.31.6",
2
+ "version": "31.31.7",
3
3
  "generatedBy": "scripts/gen-style-layers.mjs — do not edit by hand; run `pnpm gen:style-layers`",
4
4
  "base": "base.css",
5
5
  "fonts": "fonts.css",
@@ -756,13 +756,9 @@
756
756
  --table-cell-padding-y: var(--table-action-collection-cell-padding-y-compact);
757
757
  font-size: var(--table-action-collection-font-size-compact);
758
758
 
759
- min-inline-size: calc(
760
- var(--table-action-collection-min-inline-size-compact) +
761
- max(
762
- 0px,
763
- var(--table-action-collection-actions-content-width, 0px) -
764
- var(--table-action-collection-actions-width)
765
- )
759
+ min-inline-size: max(
760
+ var(--table-action-collection-min-inline-size-compact),
761
+ var(--table-action-collection-actions-fit-min-inline-size, 0px)
766
762
  );
767
763
  }
768
764
 
@@ -802,13 +798,9 @@
802
798
  --table-cell-padding-y: var(--table-action-collection-cell-padding-y-compact);
803
799
  font-size: var(--table-action-collection-font-size-compact);
804
800
 
805
- min-inline-size: calc(
806
- var(--table-action-collection-min-inline-size-compact) +
807
- max(
808
- 0px,
809
- var(--table-action-collection-actions-content-width, 0px) -
810
- var(--table-action-collection-actions-width)
811
- )
801
+ min-inline-size: max(
802
+ var(--table-action-collection-min-inline-size-compact),
803
+ var(--table-action-collection-actions-fit-min-inline-size, 0px)
812
804
  );
813
805
  }
814
806
 
@@ -848,13 +840,9 @@
848
840
  --table-cell-padding-y: var(--table-action-collection-cell-padding-y-compact);
849
841
  font-size: var(--table-action-collection-font-size-compact);
850
842
 
851
- min-inline-size: calc(
852
- var(--table-action-collection-min-inline-size-compact) +
853
- max(
854
- 0px,
855
- var(--table-action-collection-actions-content-width, 0px) -
856
- var(--table-action-collection-actions-width)
857
- )
843
+ min-inline-size: max(
844
+ var(--table-action-collection-min-inline-size-compact),
845
+ var(--table-action-collection-actions-fit-min-inline-size, 0px)
858
846
  );
859
847
  }
860
848
 
@@ -894,13 +882,9 @@
894
882
  --table-cell-padding-y: var(--table-action-collection-cell-padding-y-compact);
895
883
  font-size: var(--table-action-collection-font-size-compact);
896
884
 
897
- min-inline-size: calc(
898
- var(--table-action-collection-min-inline-size-compact) +
899
- max(
900
- 0px,
901
- var(--table-action-collection-actions-content-width, 0px) -
902
- var(--table-action-collection-actions-width)
903
- )
885
+ min-inline-size: max(
886
+ var(--table-action-collection-min-inline-size-compact),
887
+ var(--table-action-collection-actions-fit-min-inline-size, 0px)
904
888
  );
905
889
  }
906
890
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@godxjp/ui",
3
- "version": "31.31.6",
4
- "godxUiMcp": "31.31.6",
3
+ "version": "31.31.7",
4
+ "godxUiMcp": "31.31.7",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
7
7
  "type": "git",