@astryxdesign/core 0.1.6-canary.acd4fe3 → 0.1.6-canary.aeb5ee6

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.
Files changed (60) hide show
  1. package/dist/EmptyState/EmptyState.d.ts +1 -4
  2. package/dist/EmptyState/EmptyState.d.ts.map +1 -1
  3. package/dist/Pagination/Pagination.d.ts +1 -1
  4. package/dist/Pagination/Pagination.d.ts.map +1 -1
  5. package/dist/Pagination/Pagination.js +11 -38
  6. package/dist/Table/plugins/groupedRows/useTableGroupedRows.d.ts +1 -1
  7. package/dist/Table/plugins/groupedRows/useTableGroupedRows.js +1 -1
  8. package/dist/Table/plugins/rowIndex/useTableRowIndex.d.ts +1 -1
  9. package/dist/Table/plugins/rowIndex/useTableRowIndex.js +1 -1
  10. package/dist/astryx.umd.js +55 -57
  11. package/dist/astryx.umd.js.map +4 -4
  12. package/dist/index.d.ts +0 -1
  13. package/dist/index.d.ts.map +1 -1
  14. package/dist/index.js +0 -3
  15. package/package.json +2 -13
  16. package/src/AlertDialog/AlertDialog.doc.mjs +0 -5
  17. package/src/CheckboxList/CheckboxList.doc.mjs +0 -5
  18. package/src/EmptyState/EmptyState.doc.mjs +3 -3
  19. package/src/EmptyState/EmptyState.tsx +1 -4
  20. package/src/Layer/useLayer.doc.mjs +2 -2
  21. package/src/Pagination/Pagination.tsx +12 -35
  22. package/src/PowerSearch/PowerSearch.doc.mjs +0 -5
  23. package/src/Table/plugins/groupedRows/useTableGroupedRows.tsx +1 -1
  24. package/src/Table/plugins/rowIndex/useTableRowIndex.tsx +1 -1
  25. package/src/Table/useTableGroupedRows.doc.mjs +3 -3
  26. package/src/index.ts +0 -3
  27. package/dist/i18n/InternationalizationContext.d.ts +0 -12
  28. package/dist/i18n/InternationalizationContext.d.ts.map +0 -1
  29. package/dist/i18n/InternationalizationContext.js +0 -29
  30. package/dist/i18n/InternationalizationProvider.d.ts +0 -62
  31. package/dist/i18n/InternationalizationProvider.d.ts.map +0 -1
  32. package/dist/i18n/InternationalizationProvider.js +0 -44
  33. package/dist/i18n/index.d.ts +0 -24
  34. package/dist/i18n/index.d.ts.map +0 -1
  35. package/dist/i18n/index.js +0 -21
  36. package/dist/i18n/resolve.d.ts +0 -22
  37. package/dist/i18n/resolve.d.ts.map +0 -1
  38. package/dist/i18n/resolve.js +0 -141
  39. package/dist/i18n/translator.d.ts +0 -25
  40. package/dist/i18n/translator.d.ts.map +0 -1
  41. package/dist/i18n/translator.js +0 -1
  42. package/dist/i18n/types.d.ts +0 -47
  43. package/dist/i18n/types.d.ts.map +0 -1
  44. package/dist/i18n/types.js +0 -1
  45. package/dist/i18n/useTranslator.d.ts +0 -15
  46. package/dist/i18n/useTranslator.d.ts.map +0 -1
  47. package/dist/i18n/useTranslator.js +0 -39
  48. package/locales/en.json +0 -38
  49. package/locales/pseudo.json +0 -29
  50. package/src/i18n/InternationalizationContext.ts +0 -39
  51. package/src/i18n/InternationalizationProvider.doc.mjs +0 -72
  52. package/src/i18n/InternationalizationProvider.tsx +0 -83
  53. package/src/i18n/__tests__/e2e-pagination.test.tsx +0 -172
  54. package/src/i18n/__tests__/resolve.test.ts +0 -284
  55. package/src/i18n/index.ts +0 -32
  56. package/src/i18n/resolve.ts +0 -165
  57. package/src/i18n/translator.ts +0 -31
  58. package/src/i18n/types.ts +0 -53
  59. package/src/i18n/useTranslator.doc.mjs +0 -42
  60. package/src/i18n/useTranslator.ts +0 -50
@@ -36,10 +36,7 @@ export interface EmptyStateProps extends BaseProps<HTMLDivElement> {
36
36
  actions?: ReactNode;
37
37
  /**
38
38
  * Semantic heading level for the title element.
39
- * Controls only the rendered HTML tag (h1–h6) so the title fits the
40
- * document outline. This is a semantic change for accessibility and does
41
- * not change the visual size of the title, which stays fixed regardless
42
- * of level.
39
+ * Controls the rendered HTML tag (h1–h6) to fit the document outline.
43
40
  * @default 3
44
41
  */
45
42
  headingLevel?: 1 | 2 | 3 | 4 | 5 | 6;
@@ -1 +1 @@
1
- {"version":3,"file":"EmptyState.d.ts","sourceRoot":"","sources":["../../src/EmptyState/EmptyState.tsx"],"names":[],"mappings":"AAEA;;;;;;;;;;;;GAYG;AAEH,OAAO,EAAC,KAAK,SAAS,EAAgB,MAAM,OAAO,CAAC;AAQpD,OAAO,KAAK,EAAC,SAAS,EAAC,MAAM,cAAc,CAAC;AA4D5C,MAAM,WAAW,eAAgB,SAAQ,SAAS,CAAC,cAAc,CAAC;IAChE,wCAAwC;IACxC,GAAG,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,cAAc,CAAC,CAAC;IAChC;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;;OAGG;IACH,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB;;;OAGG;IACH,OAAO,CAAC,EAAE,SAAS,CAAC;IACpB;;;;;;;OAOG;IACH,YAAY,CAAC,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;IACrC;;;OAGG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAgB,UAAU,CAAC,EACzB,KAAK,EACL,WAAW,EACX,IAAI,EACJ,OAAO,EACP,YAAgB,EAChB,SAAiB,EACjB,MAAM,EACN,SAAS,EACT,KAAK,EACL,GAAG,EACH,GAAG,KAAK,EACT,EAAE,eAAe,+BA8CjB;yBA1De,UAAU"}
1
+ {"version":3,"file":"EmptyState.d.ts","sourceRoot":"","sources":["../../src/EmptyState/EmptyState.tsx"],"names":[],"mappings":"AAEA;;;;;;;;;;;;GAYG;AAEH,OAAO,EAAC,KAAK,SAAS,EAAgB,MAAM,OAAO,CAAC;AAQpD,OAAO,KAAK,EAAC,SAAS,EAAC,MAAM,cAAc,CAAC;AA4D5C,MAAM,WAAW,eAAgB,SAAQ,SAAS,CAAC,cAAc,CAAC;IAChE,wCAAwC;IACxC,GAAG,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,cAAc,CAAC,CAAC;IAChC;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;;OAGG;IACH,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB;;;OAGG;IACH,OAAO,CAAC,EAAE,SAAS,CAAC;IACpB;;;;OAIG;IACH,YAAY,CAAC,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;IACrC;;;OAGG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAgB,UAAU,CAAC,EACzB,KAAK,EACL,WAAW,EACX,IAAI,EACJ,OAAO,EACP,YAAgB,EAChB,SAAiB,EACjB,MAAM,EACN,SAAS,EACT,KAAK,EACL,GAAG,EACH,GAAG,KAAK,EACT,EAAE,eAAe,+BA8CjB;yBA1De,UAAU"}
@@ -116,7 +116,7 @@ export declare function generatePageRange(currentPage: number, totalPages: numbe
116
116
  * />
117
117
  * ```
118
118
  */
119
- export declare function Pagination({ page, onChange, changeAction, totalItems, totalPages: totalPagesProp, hasMore, pageSize: pageSizeProp, pageSizeOptions, onPageSizeChange, variant, siblingCount, size, isDisabled, label: labelFromProps, 'data-testid': testId, xstyle, className, style, ref, ...rest }: PaginationProps): import("react").JSX.Element | null;
119
+ export declare function Pagination({ page, onChange, changeAction, totalItems, totalPages: totalPagesProp, hasMore, pageSize: pageSizeProp, pageSizeOptions, onPageSizeChange, variant, siblingCount, size, isDisabled, label, 'data-testid': testId, xstyle, className, style, ref, ...rest }: PaginationProps): import("react").JSX.Element | null;
120
120
  export declare namespace Pagination {
121
121
  var displayName: string;
122
122
  }
@@ -1 +1 @@
1
- {"version":3,"file":"Pagination.d.ts","sourceRoot":"","sources":["../../src/Pagination/Pag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AM,GACnB,CAAC,MAAM,GAAG,KAAK,CAAC,EAAE,CA6CpB;AAMD;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,UAAU,CAAC,EACzB,IAAI,EACJ,QAAQ,EACR,YAAY,EACZ,UAAU,EACV,UAAU,EAAE,cAAc,EAC1B,OAAO,EACP,QAAQ,EAAE,YAAiB,EAC3B,eAAe,EACf,gBAAgB,EAChB,OAAiB,EACjB,YAAgB,EAChB,IAAW,EACX,UAAkB,EAClB,KAAoB,EACpB,aAAa,EAAE,MAAM,EACrB,MAAM,EACN,SAAS,EACT,KAAK,EACL,GAAG,EACH,GAAG,IAAI,EACR,EAAE,eAAe,sCAqTjB;yBA1Ue,UAAU"}
@@ -30,7 +30,6 @@ import { useAnnounce } from "../hooks/useAnnounce.js";
30
30
  import { useListFocus } from "../hooks/useListFocus.js";
31
31
  import { mergeProps } from "../utils/index.js";
32
32
  import { themeProps } from "../utils/themeProps.js";
33
- import { useTranslator } from "../i18n/useTranslator.js";
34
33
 
35
34
  // =============================================================================
36
35
  // Types
@@ -169,7 +168,7 @@ export function Pagination({
169
168
  siblingCount = 1,
170
169
  size = 'md',
171
170
  isDisabled = false,
172
- label: labelFromProps,
171
+ label = 'Pagination',
173
172
  'data-testid': testId,
174
173
  xstyle,
175
174
  className,
@@ -179,14 +178,6 @@ export function Pagination({
179
178
  }) {
180
179
  const [, startTransition] = useTransition();
181
180
 
182
- // Resolve system strings once per render. Prop overrides win.
183
- const t = useTranslator();
184
- const label = labelFromProps ?? t('@astryx.pagination.label');
185
- const previousLabel = t('@astryx.pagination.previous');
186
- const nextLabel = t('@astryx.pagination.next');
187
- const pageIndicatorsLabel = t('@astryx.pagination.pageIndicators');
188
- const itemsPerPageLabel = t('@astryx.pagination.itemsPerPage');
189
-
190
181
  // pageSize is typed as number, so 0, NaN, and negatives are valid at the
191
182
  // type level but yield Infinity/NaN page counts, and
192
183
  // Array.from({length: Infinity}) crashes the dots variant. Coerce to a
@@ -241,12 +232,7 @@ export function Pagination({
241
232
  // Keep onChange urgent so controlled page state updates in the same commit
242
233
  // as the click; only the optimistic indicator and changeAction defer.
243
234
  onChange(newPage);
244
- announce(computedTotalPages != null ? t('@astryx.pagination.pageOfTotal', {
245
- current: newPage,
246
- total: computedTotalPages
247
- }) : t('@astryx.pagination.pageAnnounce', {
248
- current: newPage
249
- }));
235
+ announce(computedTotalPages != null ? `Page ${newPage} of ${computedTotalPages}` : `Page ${newPage}`);
250
236
  startTransition(async () => {
251
237
  setOptimisticPage(newPage);
252
238
  await changeAction?.(newPage);
@@ -322,12 +308,8 @@ export function Pagination({
322
308
  }
323
309
  const isActive = item === optimisticPage;
324
310
  return /*#__PURE__*/_jsx(Button, {
325
- label: t('@astryx.pagination.goToPage', {
326
- page: item
327
- }),
328
- "aria-label": t('@astryx.pagination.goToPage', {
329
- page: item
330
- }),
311
+ label: `Go to page ${item}`,
312
+ "aria-label": `Go to page ${item}`,
331
313
  variant: "ghost",
332
314
  size: buttonSize,
333
315
  onClick: () => handlePageChange(item),
@@ -352,11 +334,7 @@ export function Pagination({
352
334
  type: "body",
353
335
  size: "sm",
354
336
  color: "secondary",
355
- children: t('@astryx.pagination.count', {
356
- from: rangeStart,
357
- to: rangeEnd,
358
- total: totalItems
359
- })
337
+ children: `${rangeStart}\u2013${rangeEnd} of ${totalItems}`
360
338
  })
361
339
  });
362
340
  }
@@ -373,10 +351,7 @@ export function Pagination({
373
351
  type: "body",
374
352
  size: "sm",
375
353
  color: "secondary",
376
- children: t('@astryx.pagination.pageOfTotal', {
377
- current: optimisticPage,
378
- total: computedTotalPages
379
- })
354
+ children: `Page ${optimisticPage} of ${computedTotalPages}`
380
355
  })
381
356
  });
382
357
  }
@@ -391,7 +366,7 @@ export function Pagination({
391
366
  className: "x78zum5 x6s0dn4 xzye2dw"
392
367
  },
393
368
  role: "group",
394
- "aria-label": pageIndicatorsLabel,
369
+ "aria-label": "Page indicators",
395
370
  onKeyDown: handleDotsKeyDown,
396
371
  onFocus: handleDotsFocus,
397
372
  children: Array.from({
@@ -401,9 +376,7 @@ export function Pagination({
401
376
  return /*#__PURE__*/_jsx("button", {
402
377
  type: "button",
403
378
  "data-page": i + 1,
404
- "aria-label": t('@astryx.pagination.goToPage', {
405
- page: i + 1
406
- }),
379
+ "aria-label": `Go to page ${i + 1}`,
407
380
  "aria-current": isActive ? 'page' : undefined
408
381
  // The active dot is the single roving tab stop; useListFocus
409
382
  // maintains it as focus and the active page move.
@@ -471,7 +444,7 @@ export function Pagination({
471
444
  className: "x1dmp6jm"
472
445
  },
473
446
  children: /*#__PURE__*/_jsx(Selector, {
474
- label: itemsPerPageLabel,
447
+ label: "Items per page",
475
448
  isLabelHidden: true,
476
449
  options: pageSizeOptions.map(opt => String(opt)),
477
450
  value: String(pageSize),
@@ -485,7 +458,7 @@ export function Pagination({
485
458
  className: "x78zum5 x6s0dn4 xzye2dw"
486
459
  },
487
460
  children: [/*#__PURE__*/_jsx(Button, {
488
- label: previousLabel,
461
+ label: "Go to previous page",
489
462
  variant: "ghost",
490
463
  size: buttonSize,
491
464
  icon: /*#__PURE__*/_jsx(Icon, {
@@ -496,7 +469,7 @@ export function Pagination({
496
469
  isDisabled: isDisabled || !hasPrevious,
497
470
  isIconOnly: true
498
471
  }), renderIndicator(), /*#__PURE__*/_jsx(Button, {
499
- label: nextLabel,
472
+ label: "Go to next page",
500
473
  variant: "ghost",
501
474
  size: buttonSize,
502
475
  icon: /*#__PURE__*/_jsx(Icon, {
@@ -52,7 +52,7 @@ export interface UseTableGroupedRowsResult<T extends Record<string, unknown>> {
52
52
  * pass all three to `<Table>`.
53
53
  *
54
54
  * @example
55
- * ```
55
+ * ```tsx
56
56
  * const [collapsed, setCollapsed] = useState<Set<string>>(new Set());
57
57
  * const grouped = useTableGroupedRows({
58
58
  * data: rows,
@@ -78,7 +78,7 @@ const styles = {
78
78
  * pass all three to `<Table>`.
79
79
  *
80
80
  * @example
81
- * ```
81
+ * ```tsx
82
82
  * const [collapsed, setCollapsed] = useState<Set<string>>(new Set());
83
83
  * const grouped = useTableGroupedRows({
84
84
  * data: rows,
@@ -41,7 +41,7 @@ export interface UseTableRowIndexConfig<T extends Record<string, unknown>> {
41
41
  * so it reflects the current sort / filter / pagination view.
42
42
  *
43
43
  * @example
44
- * ```
44
+ * ```tsx
45
45
  * const rowIndex = useTableRowIndex({data});
46
46
  * <Table data={data} columns={columns} idKey="id" plugins={{rowIndex}} />;
47
47
  * ```
@@ -37,7 +37,7 @@ const INDEX_COLUMN_WIDTH = {
37
37
  * so it reflects the current sort / filter / pagination view.
38
38
  *
39
39
  * @example
40
- * ```
40
+ * ```tsx
41
41
  * const rowIndex = useTableRowIndex({data});
42
42
  * <Table data={data} columns={columns} idKey="id" plugins={{rowIndex}} />;
43
43
  * ```