@wallarm-org/design-system 4.19.0 → 4.19.1-rc-fix-table-header-focus-scroll.1

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.
@@ -76,6 +76,9 @@ const StickyGroupParent = ({ tableWidth, headerHeight, windowScrollRoot, headerR
76
76
  stickyRow,
77
77
  containerRef
78
78
  ]);
79
+ useLayoutEffect(()=>{
80
+ for (const el of anchorRef.current?.querySelectorAll('a[href], button, input, select, textarea, [tabindex]') ?? [])el.tabIndex = -1;
81
+ });
79
82
  return /*#__PURE__*/ jsx("div", {
80
83
  ref: anchorRef,
81
84
  className: cn('pointer-events-none', !useWindowScroll && 'sticky z-[21] h-0 overflow-visible'),
@@ -67,10 +67,20 @@ const TableInnerWindow = (t0)=>{
67
67
  if (headerScrollRef.current) headerScrollRef.current.scrollLeft = scrollEl.scrollLeft;
68
68
  if (groupScrollRef.current) groupScrollRef.current.scrollLeft = scrollEl.scrollLeft;
69
69
  };
70
+ const header = headerScrollRef.current;
71
+ const onHeaderScroll = ()=>{
72
+ if (header && scrollEl.scrollLeft !== header.scrollLeft) scrollEl.scrollLeft = header.scrollLeft;
73
+ };
70
74
  scrollEl.addEventListener("scroll", onScroll, {
71
75
  passive: true
72
76
  });
73
- return ()=>scrollEl.removeEventListener("scroll", onScroll);
77
+ header?.addEventListener("scroll", onHeaderScroll, {
78
+ passive: true
79
+ });
80
+ return ()=>{
81
+ scrollEl.removeEventListener("scroll", onScroll);
82
+ header?.removeEventListener("scroll", onHeaderScroll);
83
+ };
74
84
  };
75
85
  t5 = [
76
86
  containerRef,
@@ -137,7 +147,7 @@ const TableInnerWindow = (t0)=>{
137
147
  t12 = /*#__PURE__*/ jsxs("table", {
138
148
  className: "table-fixed border-separate border-spacing-0",
139
149
  style: t9,
140
- "aria-hidden": true,
150
+ role: "presentation",
141
151
  children: [
142
152
  t10,
143
153
  t11
@@ -238,24 +248,23 @@ const TableInnerWindow = (t0)=>{
238
248
  $[56] = t20;
239
249
  } else t20 = $[56];
240
250
  let t21;
241
- if ($[57] !== ariaLabel || $[58] !== t18 || $[59] !== t19 || $[60] !== t20) {
251
+ if ($[57] !== t18 || $[58] !== t19 || $[59] !== t20) {
242
252
  t21 = /*#__PURE__*/ jsxs("table", {
243
253
  className: "table-fixed border-separate border-spacing-0",
244
254
  style: t18,
245
- "aria-label": ariaLabel,
255
+ role: "presentation",
246
256
  children: [
247
257
  t19,
248
258
  t20
249
259
  ]
250
260
  });
251
- $[57] = ariaLabel;
252
- $[58] = t18;
253
- $[59] = t19;
254
- $[60] = t20;
255
- $[61] = t21;
256
- } else t21 = $[61];
261
+ $[57] = t18;
262
+ $[58] = t19;
263
+ $[59] = t20;
264
+ $[60] = t21;
265
+ } else t21 = $[60];
257
266
  let t22;
258
- if ($[62] !== children || $[63] !== containerRef || $[64] !== t21) {
267
+ if ($[61] !== children || $[62] !== containerRef || $[63] !== t21) {
259
268
  t22 = /*#__PURE__*/ jsxs(ScrollAreaViewport, {
260
269
  ref: containerRef,
261
270
  "data-table-scroll-container": true,
@@ -265,20 +274,20 @@ const TableInnerWindow = (t0)=>{
265
274
  children
266
275
  ]
267
276
  });
268
- $[62] = children;
269
- $[63] = containerRef;
270
- $[64] = t21;
271
- $[65] = t22;
272
- } else t22 = $[65];
277
+ $[61] = children;
278
+ $[62] = containerRef;
279
+ $[63] = t21;
280
+ $[64] = t22;
281
+ } else t22 = $[64];
273
282
  let t23;
274
- if ($[66] === Symbol.for("react.memo_cache_sentinel")) {
283
+ if ($[65] === Symbol.for("react.memo_cache_sentinel")) {
275
284
  t23 = /*#__PURE__*/ jsx(ScrollAreaScrollbar, {
276
285
  orientation: "horizontal"
277
286
  });
278
- $[66] = t23;
279
- } else t23 = $[66];
287
+ $[65] = t23;
288
+ } else t23 = $[65];
280
289
  let t24;
281
- if ($[67] !== t16 || $[68] !== t22) {
290
+ if ($[66] !== t16 || $[67] !== t22) {
282
291
  t24 = /*#__PURE__*/ jsxs(ScrollArea, {
283
292
  className: "group/scroll rounded-12 border border-border-primary-light",
284
293
  children: [
@@ -287,18 +296,21 @@ const TableInnerWindow = (t0)=>{
287
296
  t23
288
297
  ]
289
298
  });
290
- $[67] = t16;
291
- $[68] = t22;
292
- $[69] = t24;
293
- } else t24 = $[69];
299
+ $[66] = t16;
300
+ $[67] = t22;
301
+ $[68] = t24;
302
+ } else t24 = $[68];
294
303
  let t25;
295
- if ($[70] !== t24 || $[71] !== testId) {
304
+ if ($[69] !== ariaLabel || $[70] !== t24 || $[71] !== testId) {
296
305
  t25 = /*#__PURE__*/ jsx("div", {
297
306
  ref: rootRef,
298
307
  "data-testid": testId,
308
+ role: "table",
309
+ "aria-label": ariaLabel,
299
310
  className: "group/scroll relative outline-none",
300
311
  children: t24
301
312
  });
313
+ $[69] = ariaLabel;
302
314
  $[70] = t24;
303
315
  $[71] = testId;
304
316
  $[72] = t25;
@@ -27,6 +27,7 @@ const TBody = (t0)=>{
27
27
  if ($[6] !== props || $[7] !== ref || $[8] !== t1) {
28
28
  t2 = /*#__PURE__*/ jsx("tbody", {
29
29
  ref: ref,
30
+ role: "rowgroup",
30
31
  className: t1,
31
32
  ...props
32
33
  });
@@ -27,6 +27,7 @@ const THead = (t0)=>{
27
27
  if ($[6] !== props || $[7] !== ref || $[8] !== t1) {
28
28
  t2 = /*#__PURE__*/ jsx("thead", {
29
29
  ref: ref,
30
+ role: "rowgroup",
30
31
  className: t1,
31
32
  ...props
32
33
  });
@@ -51,6 +51,7 @@ const Td = (t0)=>{
51
51
  if ($[15] !== props || $[16] !== ref || $[17] !== t1) {
52
52
  t2 = /*#__PURE__*/ jsx("td", {
53
53
  ref: ref,
54
+ role: "cell",
54
55
  className: t1,
55
56
  ...props
56
57
  });
@@ -60,6 +60,7 @@ const Th = (t0)=>{
60
60
  t2 = /*#__PURE__*/ jsx("th", {
61
61
  ref: ref,
62
62
  scope: "col",
63
+ role: "columnheader",
63
64
  className: t1,
64
65
  ...props
65
66
  });
@@ -28,6 +28,7 @@ const Tr = (t0)=>{
28
28
  if ($[6] !== props || $[7] !== ref || $[8] !== t1) {
29
29
  t2 = /*#__PURE__*/ jsx("tr", {
30
30
  ref: ref,
31
+ role: "row",
31
32
  className: t1,
32
33
  ...props
33
34
  });
@@ -1,6 +1,6 @@
1
1
  {
2
- "version": "4.18.0",
3
- "generatedAt": "2026-11-16T17:27:24.525Z",
2
+ "version": "4.19.0",
3
+ "generatedAt": "2026-11-17T09:09:25.118Z",
4
4
  "components": [
5
5
  {
6
6
  "name": "Accordion",
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "4.18.0",
2
+ "version": "4.19.0",
3
3
  "rules": "Every numeric utility is in px, not 4px steps: p-16 is 16px, p-4 is 4px. Translate Tailwind habits (p-4 → p-16, gap-6 → gap-24, w-64 → w-256).\n\nBefore composing a screen, call get_guideline for the pattern (app shell, list page, table, drawer, form, dialog, filters, empty state, settings, auth). Wrong → right:\n\n- p-5, gap-3, p-10 → stay on the scale: 1, 2, 4, 6, 8, 12, 16, 20, 24, 28, 32, 40, 48, 64…\n- space-y-4, margins per child → <VStack gap={16}>, <HStack gap={8}>\n- Padded page wrapper → PageHeader / PageToolbar / PageContent own the 24px gutter\n- p-* on Card, DrawerBody, DialogBody, PageToolbar, Table → none; they own their padding\n- className on Text, Heading, Field, Drawer/Dialog Header/Body/Footer → wrap in your own element\n- Raw <h1>, <p>, <label> → <Heading as=\"h2\" size=\"lg\">, <Text size=\"sm\">, Field\n- <Text> default (16px) for body → size=\"sm\"\n- leading-none (0px), leading-5 (5px) → leading-sm, leading-20\n- weight=\"semibold\" → weight is light|regular|medium|bold (medium = 450)\n- bg-primary, text-muted, bg-card, bg-white → bg-bg-primary, text-text-secondary, bg-bg-surface-1\n- text-error, bg-red-500 → danger tokens; categorical color → Badge color\n- dark: variant, setting data-theme → semantic tokens, useTheme().setTheme()\n- rounded-lg, rounded, rounded-[15px] → rounded-8 (controls), rounded-12 (panels)\n- shadow-* on DS components, z-* on overlays → never; they own both\n- focus:ring → focus-visible:ring-3 ring-focus-primary outline-none\n- size, DIALOG/DRAWER_SIZES → width: Dialog 400 confirm, 560 default, 960 picker; Drawer 640 default, 700 Timeline form\n- Dialog, useToast from the root → @wallarm-org/design-system/Dialog, /Toast\n- Field invalid → error on the control + FieldError\n- Table actions column → meta.renderMenuAction on the master column\n- Hand-built side menu → RemoteShell config={NavConfig}\n- ConfirmDialog, FilterBar, Combobox → compose Dialog parts, PageToolbar + FilterDropdown, Select + useSelectSearch\n- data-slot in tests → data-testid\n",
4
4
  "guidelines": [
5
5
  {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wallarm-org/design-system",
3
- "version": "4.19.0",
3
+ "version": "4.19.1-rc-fix-table-header-focus-scroll.1",
4
4
  "description": "Core design system library with React components and Storybook documentation",
5
5
  "publishConfig": {
6
6
  "access": "public",