@cosmicdrift/kumiko-renderer-web 0.199.1 → 0.199.2

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cosmicdrift/kumiko-renderer-web",
3
- "version": "0.199.1",
3
+ "version": "0.199.2",
4
4
  "description": "Web-platform bindings for @cosmicdrift/kumiko-renderer. HTML default-primitives, browser history-based navigation, EventSource-backed live events, and a one-call createKumikoApp that mounts the whole stack via react-dom.",
5
5
  "license": "BUSL-1.1",
6
6
  "author": "Marc Frost <marc@cosmicdriftgamestudio.com>",
@@ -16,9 +16,9 @@
16
16
  "./styles.css": "./src/styles.css"
17
17
  },
18
18
  "dependencies": {
19
- "@cosmicdrift/kumiko-dispatcher-live": "0.199.1",
20
- "@cosmicdrift/kumiko-headless": "0.199.1",
21
- "@cosmicdrift/kumiko-renderer": "0.199.1",
19
+ "@cosmicdrift/kumiko-dispatcher-live": "0.199.2",
20
+ "@cosmicdrift/kumiko-headless": "0.199.2",
21
+ "@cosmicdrift/kumiko-renderer": "0.199.2",
22
22
  "@radix-ui/react-dialog": "^1.1.15",
23
23
  "@radix-ui/react-dropdown-menu": "^2.1.16",
24
24
  "@radix-ui/react-label": "^2.1.8",
@@ -738,8 +738,8 @@ describe("EmbeddedListInput — desktop table width (solon#107)", () => {
738
738
 
739
739
  const headers = desktop.querySelectorAll("th");
740
740
  expect(headers[0]?.className).toContain("min-w-[10rem]");
741
- expect(headers[1]?.className).toContain("w-36");
742
- expect(headers[2]?.className).toContain("w-44");
741
+ expect(headers[1]?.className).toContain("min-w-[9rem]");
742
+ expect(headers[2]?.className).toContain("min-w-[13rem]");
743
743
  });
744
744
 
745
745
  test("a money column is wider than a decimal/number column (framework#1880)", () => {
@@ -751,7 +751,7 @@ describe("EmbeddedListInput — desktop table width (solon#107)", () => {
751
751
  renderWithLocale(<EmbeddedListInput {...baseProps({ columns, rows })} />);
752
752
  const desktop = screen.getByTestId("lines-desktop");
753
753
  const headers = desktop.querySelectorAll("th");
754
- expect(headers[0]?.className).toContain("w-36");
755
- expect(headers[1]?.className).toContain("w-44");
754
+ expect(headers[0]?.className).toContain("min-w-[9rem]");
755
+ expect(headers[1]?.className).toContain("min-w-[13rem]");
756
756
  });
757
757
  });
@@ -54,15 +54,24 @@ const FOCUSABLE_SELECTOR = "input:not([type=hidden]), button, [tabindex]";
54
54
 
55
55
  function columnWidthClass(type: EmbeddedListCellType): string {
56
56
  switch (type) {
57
+ // A fixed `w-*` caps the cell at exactly that width — the calendar
58
+ // button and money's stepper padding then eat into the space a
59
+ // locale value needs, clipping a digit or the currency sign. `min-w`
60
+ // sets a floor sized for each control's chrome instead, and still
61
+ // lets the column grow past it like text/select/reference below.
57
62
  case "number":
58
63
  case "decimal":
64
+ return "min-w-[9rem]";
65
+ // A locale-formatted date + calendar-trigger button + gap.
59
66
  case "date":
60
- return "w-36";
61
- // Wider than a bare number: MoneyInput appends stepper buttons, timestamp
62
- // carries a date field plus a time input.
67
+ return "min-w-[11rem]";
68
+ // Currency text (thousands separator, decimals, symbol) + the
69
+ // pr-20 MoneyInput reserves for its +/- stepper buttons.
63
70
  case "money":
71
+ return "min-w-[13rem]";
72
+ // DateField (see "date" above) plus a separate fixed-width time input.
64
73
  case "timestamp":
65
- return "w-44";
74
+ return "min-w-[19rem]";
66
75
  case "boolean":
67
76
  return "w-16";
68
77
  case "text":