@orianatech/pire 1.3.0 → 1.4.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.
Files changed (50) hide show
  1. package/dist/components/core/Tag.d.ts.map +1 -1
  2. package/dist/components/core/icon-data.generated.d.ts.map +1 -1
  3. package/dist/components/core/icon-map.d.ts.map +1 -1
  4. package/dist/components/data/BarList.d.cts +30 -0
  5. package/dist/components/data/BarList.d.ts +31 -0
  6. package/dist/components/data/BarList.d.ts.map +1 -0
  7. package/dist/components/data/DataTable.d.cts +45 -3
  8. package/dist/components/data/DataTable.d.ts +45 -3
  9. package/dist/components/data/DataTable.d.ts.map +1 -1
  10. package/dist/components/data/RecordCard.d.cts +28 -0
  11. package/dist/components/data/RecordCard.d.ts +29 -0
  12. package/dist/components/data/RecordCard.d.ts.map +1 -0
  13. package/dist/components/data/ViewSwitcher.d.cts +32 -0
  14. package/dist/components/data/ViewSwitcher.d.ts +33 -0
  15. package/dist/components/data/ViewSwitcher.d.ts.map +1 -0
  16. package/dist/components/feedback/Tooltip.d.cts +18 -0
  17. package/dist/components/feedback/Tooltip.d.ts +18 -0
  18. package/dist/components/feedback/Tooltip.d.ts.map +1 -1
  19. package/dist/components/forms/ChoiceCardGroup.d.cts +50 -0
  20. package/dist/components/forms/ChoiceCardGroup.d.ts +51 -0
  21. package/dist/components/forms/ChoiceCardGroup.d.ts.map +1 -0
  22. package/dist/components/forms/NumberField.d.cts +18 -1
  23. package/dist/components/forms/NumberField.d.ts +18 -1
  24. package/dist/components/forms/NumberField.d.ts.map +1 -1
  25. package/dist/components/forms/QuantityStepper.d.cts +28 -0
  26. package/dist/components/forms/QuantityStepper.d.ts +29 -0
  27. package/dist/components/forms/QuantityStepper.d.ts.map +1 -0
  28. package/dist/components/navigation/Ribbon.d.cts +75 -0
  29. package/dist/components/navigation/Ribbon.d.ts +76 -0
  30. package/dist/components/navigation/Ribbon.d.ts.map +1 -0
  31. package/dist/components/patterns/ConfirmDialog.d.cts +8 -1
  32. package/dist/components/patterns/ConfirmDialog.d.ts +8 -1
  33. package/dist/components/patterns/ConfirmDialog.d.ts.map +1 -1
  34. package/dist/components/patterns/ValueHelpDialog.d.cts +23 -1
  35. package/dist/components/patterns/ValueHelpDialog.d.ts +23 -1
  36. package/dist/components/patterns/ValueHelpDialog.d.ts.map +1 -1
  37. package/dist/components.css +259 -2
  38. package/dist/i18n/messages.d.cts +44 -0
  39. package/dist/i18n/messages.d.ts +44 -0
  40. package/dist/i18n/messages.d.ts.map +1 -1
  41. package/dist/index.cjs +1371 -845
  42. package/dist/index.cjs.map +1 -1
  43. package/dist/index.d.cts +7 -1
  44. package/dist/index.d.ts +7 -1
  45. package/dist/index.d.ts.map +1 -1
  46. package/dist/index.js +1294 -774
  47. package/dist/index.js.map +1 -1
  48. package/dist/tokens/colors.css +7 -0
  49. package/dist/tokens/themes.css +3 -0
  50. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -95,6 +95,7 @@ var ICON_MARKUP = {
95
95
  "percentage": '<path d="M9,14a5,5,0,1,1,5-5A5.0055,5.0055,0,0,1,9,14ZM9,6a3,3,0,1,0,3,3A3.0033,3.0033,0,0,0,9,6Z"/><path d="M.029 15H31.97V17H.029z" transform="rotate(-45 16 16)"/><path d="M23,28a5,5,0,1,1,5-5A5.0055,5.0055,0,0,1,23,28Zm0-8a3,3,0,1,0,3,3A3.0033,3.0033,0,0,0,23,20Z"/>',
96
96
  "phone": '<path d="M26,29h-.17C6.18,27.87,3.39,11.29,3,6.23A3,3,0,0,1,5.76,3h5.51a2,2,0,0,1,1.86,1.26L14.65,8a2,2,0,0,1-.44,2.16l-2.13,2.15a9.37,9.37,0,0,0,7.58,7.6l2.17-2.15A2,2,0,0,1,24,17.35l3.77,1.51A2,2,0,0,1,29,20.72V26A3,3,0,0,1,26,29ZM6,5A1,1,0,0,0,5,6v.08C5.46,12,8.41,26,25.94,27A1,1,0,0,0,27,26.06V20.72l-3.77-1.51-2.87,2.85L19.88,22C11.18,20.91,10,12.21,10,12.12l-.06-.48,2.84-2.87L11.28,5Z"/>',
97
97
  "piggy-bank": '<path d="M16.5,14H20V12H18V11H16v1.0508A2.5,2.5,0,0,0,16.5,17h1a.5.5,0,0,1,0,1H14v2h2v1h2V19.9492A2.5,2.5,0,0,0,17.5,15h-1a.5.5,0,0,1,0-1Z"/><path d="M29,13H26.98A5.7789,5.7789,0,0,0,25,8.8525V5a1,1,0,0,0-1.6-.8L19.6665,7H15c-5.5095,0-9.4634,3.2412-9.9485,8H5a1.0009,1.0009,0,0,1-1-1V12H2v2a3.0033,3.0033,0,0,0,3,3h.07A9.1733,9.1733,0,0,0,9,23.5566V27a1,1,0,0,0,1,1h4a1,1,0,0,0,1-1V25h3v2a1,1,0,0,0,1,1h4a1,1,0,0,0,1-1V23.6372A5.0926,5.0926,0,0,0,26.8188,20H29a1,1,0,0,0,1-1V14A1,1,0,0,0,29,13Zm-1,5H25.124c-.3052,2.7529-.8235,3.4854-3.124,4.3154V26H20V23H13v3H11V22.3779A7.013,7.013,0,0,1,7,16c0-4.8354,4.0181-7,8-7h5.3335L23,7V9.7764c2.4182,1.8593,1.9126,3.186,2.0183,5.2236H28Z"/>',
98
+ "pin": '<path d="M28.59,13.31,30,11.9,20,2,18.69,3.42,19.87,4.6,8.38,14.32,6.66,12.61,5.25,14l5.66,5.68L2,28.58,3.41,30l8.91-8.91L18,26.75l1.39-1.42-1.71-1.71L27.4,12.13ZM16.26,22.2,9.8,15.74,21.29,6,26,10.71Z"/>',
98
99
  "portfolio": '<path d="M28,10H22V6a2,2,0,0,0-2-2H12a2,2,0,0,0-2,2v4H4a2,2,0,0,0-2,2V26a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V12A2,2,0,0,0,28,10ZM12,6h8v4H12ZM4,26V12H28V26Z"/>',
99
100
  "printer": '<path d="M28,9H25V3H7V9H4a2,2,0,0,0-2,2V21a2,2,0,0,0,2,2H7v6H25V23h3a2,2,0,0,0,2-2V11A2,2,0,0,0,28,9ZM9,5H23V9H9ZM23,27H9V17H23Zm5-6H25V15H7v6H4V11H28Z"/>',
100
101
  "purchase": '<path d="M28,6H4A2,2,0,0,0,2,8V24a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V8A2,2,0,0,0,28,6Zm0,2v3H4V8ZM4,24V13H28V24Z"/><path d="M6 20H16V22H6z"/>',
@@ -130,6 +131,7 @@ var ICON_MARKUP = {
130
131
  "time": '<path d="M16,30A14,14,0,1,1,30,16,14,14,0,0,1,16,30ZM16,4A12,12,0,1,0,28,16,12,12,0,0,0,16,4Z"/><path d="M20.59 22 15 16.41 15 7 17 7 17 15.58 22 20.59 20.59 22z"/>',
131
132
  "trash-can": '<path d="M12 12H14V24H12z"/><path d="M18 12H20V24H18z"/><path d="M4,6V8H6V28a2,2,0,0,0,2,2H24a2,2,0,0,0,2-2V8h2V6ZM8,28V8H24V28Z"/><path d="M12 2H20V4H12z"/>',
132
133
  "undo": '<path d="M20,10H7.8149l3.5874-3.5859L10,5,4,11,10,17l1.4023-1.4146L7.8179,12H20a6,6,0,0,1,0,12H12v2h8a8,8,0,0,0,0-16Z"/>',
134
+ "upload": '<path d="M6 18 7.41 19.41 15 11.83 15 30 17 30 17 11.83 24.59 19.41 26 18 16 8 6 18z"/><path d="M6,8V4H26V8h2V4a2,2,0,0,0-2-2H6A2,2,0,0,0,4,4V8Z"/>',
133
135
  "user": '<path d="M16,4a5,5,0,1,1-5,5,5,5,0,0,1,5-5m0-2a7,7,0,1,0,7,7A7,7,0,0,0,16,2Z"/><path d="M26,30H24V25a5,5,0,0,0-5-5H13a5,5,0,0,0-5,5v5H6V25a7,7,0,0,1,7-7h6a7,7,0,0,1,7,7Z"/>',
134
136
  "user--admin": '<path d="M12,4A5,5,0,1,1,7,9a5,5,0,0,1,5-5m0-2a7,7,0,1,0,7,7A7,7,0,0,0,12,2Z"/><path d="M22,30H20V25a5,5,0,0,0-5-5H9a5,5,0,0,0-5,5v5H2V25a7,7,0,0,1,7-7h6a7,7,0,0,1,7,7Z"/><path d="M25 16.18 22.41 13.59 21 15 25 19 32 12 30.59 10.59 25 16.18z"/>',
135
137
  "user--follow": '<path d="M32 14 28 14 28 10 26 10 26 14 22 14 22 16 26 16 26 20 28 20 28 16 32 16 32 14z"/><path d="M12,4A5,5,0,1,1,7,9a5,5,0,0,1,5-5m0-2a7,7,0,1,0,7,7A7,7,0,0,0,12,2Z"/><path d="M22,30H20V25a5,5,0,0,0-5-5H9a5,5,0,0,0-5,5v5H2V25a7,7,0,0,1,7-7h6a7,7,0,0,1,7,7Z"/>',
@@ -155,6 +157,11 @@ var CARBON_MAP = {
155
157
  "file-text": "document",
156
158
  "clipboard-list": "list--checked",
157
159
  "building-2": "building",
160
+ /* Ribbon and import commands. `task--complete` is Carbon's ticked-list glyph; `check-square`
161
+ already points at it, and the generator de-duplicates by slug, so this costs no bytes. */
162
+ "list-checks": "task--complete",
163
+ "pin": "pin",
164
+ "upload": "upload",
158
165
  "boxes": "box",
159
166
  "truck": "delivery-truck",
160
167
  "stamp": "checkmark--outline",
@@ -418,7 +425,9 @@ import * as React2 from "react";
418
425
  import { TooltipTrigger, Tooltip as AriaTooltip, OverlayArrow, Focusable } from "react-aria-components";
419
426
  import { jsx as jsx3, jsxs as jsxs2 } from "react/jsx-runtime";
420
427
  function Tooltip({ label, placement = "top", delay = 500, children }) {
421
- const target = React2.isValidElement(children) ? React2.cloneElement(children, { className: cx(children.props.className, "pire-tooltip-target") }) : /* @__PURE__ */ jsx3("span", { className: "pire-tooltip-target", children });
428
+ const props = React2.isValidElement(children) ? children.props : void 0;
429
+ const isDisabledChild = props?.isDisabled === true || props?.disabled === true;
430
+ const target = React2.isValidElement(children) && !isDisabledChild ? React2.cloneElement(children, { className: cx(children.props.className, "pire-tooltip-target") }) : isDisabledChild ? /* @__PURE__ */ jsx3("span", { className: "pire-tooltip-target", role: "button", "aria-disabled": "true", children }) : /* @__PURE__ */ jsx3("span", { className: "pire-tooltip-target", children });
422
431
  return /* @__PURE__ */ jsxs2(TooltipTrigger, { delay, closeDelay: 0, children: [
423
432
  /* @__PURE__ */ jsx3(Focusable, { children: target }),
424
433
  /* @__PURE__ */ jsxs2(AriaTooltip, { className: "pire-tooltip", placement, offset: 6, children: [
@@ -483,50 +492,244 @@ var Badge = React4.forwardRef(function Badge2({ children, status = "neutral", sh
483
492
  });
484
493
 
485
494
  // src/components/core/Tag.tsx
486
- import * as React5 from "react";
495
+ import * as React6 from "react";
487
496
  import { Button as AriaButton3 } from "react-aria-components";
488
- import { jsx as jsx6, jsxs as jsxs5 } from "react/jsx-runtime";
489
- var Tag = React5.forwardRef(function Tag2({ children, onRemove, isDisabled, category, className, ...rest }, ref) {
497
+
498
+ // src/i18n/PireIntlProvider.tsx
499
+ import * as React5 from "react";
500
+
501
+ // src/i18n/messages.ts
502
+ var enMessages = {
503
+ filterBarLabel: "Filters",
504
+ filterBarGo: "Go",
505
+ filterBarClearAll: "Clear all",
506
+ dataTableSelectAll: "Select all rows",
507
+ dataTableSelectRow: "Select row",
508
+ dataTableSelectionColumn: "Selection",
509
+ dataTableLoading: "Loading records",
510
+ dataTableSummaryRow: "Summary",
511
+ dataTableEmpty: "No records match the current filters.",
512
+ dialogClose: "Close",
513
+ sidePanelClose: "Close panel",
514
+ inlineMessageDismiss: "Dismiss message",
515
+ toastDismiss: "Dismiss",
516
+ toastRegionLabel: "Notifications",
517
+ selectEmpty: "No options available",
518
+ comboBoxShowSuggestions: "Show suggestions",
519
+ comboBoxLoading: "Searching\u2026",
520
+ datePickerOpenCalendar: "Open calendar",
521
+ datePickerPreviousMonth: "Previous month",
522
+ datePickerNextMonth: "Next month",
523
+ dateRangePresetsLabel: "Date range shortcuts",
524
+ numberFieldIncrease: "Increase",
525
+ numberFieldDecrease: "Decrease",
526
+ inputClear: "Clear",
527
+ valueHelpFieldPlaceholder: "Not selected",
528
+ valueHelpFieldClear: "Clear selection",
529
+ valueHelpFieldOpenNamed: "Select {label}",
530
+ valueHelpFieldOpen: "Open value help",
531
+ valueHelpDialogSearch: "Search records",
532
+ valueHelpDialogTitle: "Select a record",
533
+ valueHelpDialogSearchPlaceholder: "Search by ID or name",
534
+ valueHelpDialogEmpty: "No records found",
535
+ valueHelpDialogCancel: "Cancel",
536
+ paginationLabel: "Pagination",
537
+ paginationRange: "{from}\u2013{to} of {total}",
538
+ paginationPageOf: "Page {page} of {pages}",
539
+ paginationPrevious: "Previous page",
540
+ paginationNext: "Next page",
541
+ paginationRowsPerPage: "Rows per page",
542
+ sideNavLabel: "Main navigation",
543
+ shellRailLabel: "Applications",
544
+ appLauncherLabel: "All applications",
545
+ appLauncherTitle: "All applications",
546
+ appLauncherSearch: "Search for an application",
547
+ appLauncherEmpty: "No application matches that search.",
548
+ appLauncherLoading: "Loading applications\u2026",
549
+ splitPaneList: "List",
550
+ splitPaneDetail: "Detail",
551
+ splitPaneBack: "Back to list",
552
+ fileUploadChoose: "Choose files",
553
+ fileUploadRemoveNamed: "Remove {name}",
554
+ fileUploadUploading: "Uploading",
555
+ fileDropZonePrompt: "Drag files here, or choose them",
556
+ shellBarUserMenu: "Account menu for {user}",
557
+ commandPaletteLabel: "Command palette",
558
+ commandPaletteSearchLabel: "Search commands and records",
559
+ commandPalettePlaceholder: "Search for a screen, an action or a record\u2026",
560
+ commandPaletteEmpty: "Nothing matches that",
561
+ commandPaletteLoading: "Searching\u2026",
562
+ commandPaletteHintNavigate: "navigate",
563
+ commandPaletteHintSelect: "open",
564
+ commandPaletteHintClose: "close",
565
+ chartCategoryHeader: "Category",
566
+ chartNoValue: "No data",
567
+ chartEmpty: "No data for this period",
568
+ numPadClear: "Clear",
569
+ numPadBackspace: "Remove last digit",
570
+ viewSwitcherName: "Saved views: {view}",
571
+ viewSwitcherNameModified: "Saved views: {view}, modified",
572
+ viewSwitcherModifiedMark: "\xB7 modified",
573
+ quantityStepperIncrease: "Increase quantity",
574
+ quantityStepperDecrease: "Decrease quantity",
575
+ confirmDialogFactsLabel: "Summary",
576
+ valueHelpSelectAllCount: "Select all ({count})",
577
+ valueHelpClearSelection: "Clear selection",
578
+ valueHelpSelectedCount: "Selected: {count}",
579
+ valueHelpConfirm: "Apply selection",
580
+ tagRemoveNamed: "Remove {name}",
581
+ tagRemove: "Remove",
582
+ ribbonLabel: "Commands",
583
+ ribbonCollapse: "Collapse the ribbon",
584
+ ribbonExpand: "Expand the ribbon"
585
+ };
586
+ var esMessages = {
587
+ filterBarLabel: "Filtros",
588
+ filterBarGo: "Buscar",
589
+ filterBarClearAll: "Limpiar todo",
590
+ dataTableSelectAll: "Seleccionar todas las filas",
591
+ dataTableSelectRow: "Seleccionar fila",
592
+ dataTableSelectionColumn: "Selecci\xF3n",
593
+ dataTableLoading: "Cargando registros",
594
+ dataTableSummaryRow: "Resumen",
595
+ dataTableEmpty: "Ning\xFAn registro coincide con los filtros actuales.",
596
+ dialogClose: "Cerrar",
597
+ sidePanelClose: "Cerrar panel",
598
+ inlineMessageDismiss: "Descartar mensaje",
599
+ toastDismiss: "Descartar",
600
+ toastRegionLabel: "Notificaciones",
601
+ selectEmpty: "Sin opciones disponibles",
602
+ comboBoxShowSuggestions: "Mostrar sugerencias",
603
+ comboBoxLoading: "Buscando\u2026",
604
+ datePickerOpenCalendar: "Abrir calendario",
605
+ datePickerPreviousMonth: "Mes anterior",
606
+ datePickerNextMonth: "Mes siguiente",
607
+ dateRangePresetsLabel: "Atajos de rango de fechas",
608
+ numberFieldIncrease: "Aumentar",
609
+ numberFieldDecrease: "Disminuir",
610
+ inputClear: "Limpiar",
611
+ valueHelpFieldPlaceholder: "Sin seleccionar",
612
+ valueHelpFieldClear: "Limpiar selecci\xF3n",
613
+ valueHelpFieldOpenNamed: "Seleccionar {label}",
614
+ valueHelpFieldOpen: "Abrir ayuda de valores",
615
+ valueHelpDialogSearch: "Buscar registros",
616
+ valueHelpDialogTitle: "Seleccionar un registro",
617
+ valueHelpDialogSearchPlaceholder: "Buscar por c\xF3digo o nombre",
618
+ valueHelpDialogEmpty: "No se encontraron registros",
619
+ valueHelpDialogCancel: "Cancelar",
620
+ paginationLabel: "Paginaci\xF3n",
621
+ paginationRange: "{from}\u2013{to} de {total}",
622
+ paginationPageOf: "P\xE1gina {page} de {pages}",
623
+ paginationPrevious: "P\xE1gina anterior",
624
+ paginationNext: "P\xE1gina siguiente",
625
+ paginationRowsPerPage: "Filas por p\xE1gina",
626
+ sideNavLabel: "Navegaci\xF3n principal",
627
+ shellRailLabel: "Aplicaciones",
628
+ appLauncherLabel: "Todas las aplicaciones",
629
+ appLauncherTitle: "Todas las aplicaciones",
630
+ appLauncherSearch: "Busc\xE1 una aplicaci\xF3n",
631
+ appLauncherEmpty: "Ninguna aplicaci\xF3n coincide con esa b\xFAsqueda.",
632
+ appLauncherLoading: "Cargando aplicaciones\u2026",
633
+ splitPaneList: "Lista",
634
+ splitPaneDetail: "Detalle",
635
+ splitPaneBack: "Volver a la lista",
636
+ fileUploadChoose: "Elegir archivos",
637
+ fileUploadRemoveNamed: "Quitar {name}",
638
+ fileUploadUploading: "Subiendo",
639
+ fileDropZonePrompt: "Arrastr\xE1 archivos ac\xE1, o elegilos",
640
+ shellBarUserMenu: "Men\xFA de cuenta de {user}",
641
+ commandPaletteLabel: "Paleta de comandos",
642
+ commandPaletteSearchLabel: "Buscar comandos y registros",
643
+ commandPalettePlaceholder: "Busc\xE1 una pantalla, una acci\xF3n o un registro\u2026",
644
+ commandPaletteEmpty: "No hay coincidencias",
645
+ commandPaletteLoading: "Buscando\u2026",
646
+ commandPaletteHintNavigate: "navegar",
647
+ commandPaletteHintSelect: "abrir",
648
+ commandPaletteHintClose: "cerrar",
649
+ chartCategoryHeader: "Categor\xEDa",
650
+ chartNoValue: "Sin datos",
651
+ chartEmpty: "Sin datos para este per\xEDodo",
652
+ numPadClear: "Limpiar",
653
+ numPadBackspace: "Borrar \xFAltimo d\xEDgito",
654
+ viewSwitcherName: "Vistas guardadas: {view}",
655
+ viewSwitcherNameModified: "Vistas guardadas: {view}, modificada",
656
+ viewSwitcherModifiedMark: "\xB7 modificada",
657
+ quantityStepperIncrease: "Aumentar cantidad",
658
+ quantityStepperDecrease: "Disminuir cantidad",
659
+ confirmDialogFactsLabel: "Resumen",
660
+ valueHelpSelectAllCount: "Seleccionar todo ({count})",
661
+ valueHelpClearSelection: "Limpiar selecci\xF3n",
662
+ valueHelpSelectedCount: "Seleccionadas: {count}",
663
+ valueHelpConfirm: "Aplicar selecci\xF3n",
664
+ tagRemoveNamed: "Quitar {name}",
665
+ tagRemove: "Quitar",
666
+ ribbonLabel: "Comandos",
667
+ ribbonCollapse: "Contraer la cinta",
668
+ ribbonExpand: "Expandir la cinta"
669
+ };
670
+
671
+ // src/i18n/PireIntlProvider.tsx
672
+ import { jsx as jsx6 } from "react/jsx-runtime";
673
+ var MessagesContext = React5.createContext(enMessages);
674
+ function PireIntlProvider({ messages, children }) {
675
+ const value = React5.useMemo(
676
+ () => messages ? { ...enMessages, ...messages } : enMessages,
677
+ [messages]
678
+ );
679
+ return /* @__PURE__ */ jsx6(MessagesContext.Provider, { value, children });
680
+ }
681
+ function usePireMessages() {
682
+ return React5.useContext(MessagesContext);
683
+ }
684
+ function useMessage(key, override) {
685
+ const messages = React5.useContext(MessagesContext);
686
+ return override ?? messages[key];
687
+ }
688
+
689
+ // src/components/core/Tag.tsx
690
+ import { jsx as jsx7, jsxs as jsxs5 } from "react/jsx-runtime";
691
+ var Tag = React6.forwardRef(function Tag2({ children, onRemove, isDisabled, category, className, ...rest }, ref) {
692
+ const msg = usePireMessages();
490
693
  return /* @__PURE__ */ jsxs5("span", { ref, className: cx("pire-tag", className), "data-disabled": isDisabled ? "true" : void 0, ...rest, children: [
491
- category ? /* @__PURE__ */ jsx6("span", { className: "pire-tag-swatch", "data-category": category, "aria-hidden": "true" }) : null,
694
+ category ? /* @__PURE__ */ jsx7("span", { className: "pire-tag-swatch", "data-category": category, "aria-hidden": "true" }) : null,
492
695
  children,
493
- onRemove ? /* @__PURE__ */ jsx6(
696
+ onRemove ? /* @__PURE__ */ jsx7(
494
697
  AriaButton3,
495
698
  {
496
699
  className: "pire-tag-remove",
497
700
  isDisabled,
498
701
  onPress: onRemove,
499
- "aria-label": `Remove ${typeof children === "string" ? children : "filter"}`,
500
- children: /* @__PURE__ */ jsx6(Icon, { name: "x", size: 12 })
702
+ "aria-label": typeof children === "string" ? msg.tagRemoveNamed.replace("{name}", children) : msg.tagRemove,
703
+ children: /* @__PURE__ */ jsx7(Icon, { name: "x", size: 12 })
501
704
  }
502
705
  ) : null
503
706
  ] });
504
707
  });
505
708
 
506
709
  // src/components/core/Card.tsx
507
- import { jsx as jsx7, jsxs as jsxs6 } from "react/jsx-runtime";
710
+ import { jsx as jsx8, jsxs as jsxs6 } from "react/jsx-runtime";
508
711
  function Card({ title, subtitle, icon, actions, footer, interactive, children, className, ...rest }) {
509
712
  return /* @__PURE__ */ jsxs6("section", { className: cx("pire-card", className), "data-interactive": interactive ? "true" : void 0, ...rest, children: [
510
713
  title || actions ? /* @__PURE__ */ jsxs6("header", { className: "pire-card-head", children: [
511
- icon ? /* @__PURE__ */ jsx7(Icon, { name: icon, size: 20, style: { color: "var(--text-secondary)" } }) : null,
714
+ icon ? /* @__PURE__ */ jsx8(Icon, { name: icon, size: 20, style: { color: "var(--text-secondary)" } }) : null,
512
715
  /* @__PURE__ */ jsxs6("div", { style: { flex: 1, minWidth: 0 }, children: [
513
- /* @__PURE__ */ jsx7("h3", { className: "pire-card-title", children: title }),
514
- subtitle ? /* @__PURE__ */ jsx7("p", { className: "pire-card-sub", style: { margin: 0 }, children: subtitle }) : null
716
+ /* @__PURE__ */ jsx8("h3", { className: "pire-card-title", children: title }),
717
+ subtitle ? /* @__PURE__ */ jsx8("p", { className: "pire-card-sub", style: { margin: 0 }, children: subtitle }) : null
515
718
  ] }),
516
- actions ? /* @__PURE__ */ jsx7("div", { style: { display: "flex", gap: "var(--sp-1)" }, children: actions }) : null
719
+ actions ? /* @__PURE__ */ jsx8("div", { style: { display: "flex", gap: "var(--sp-1)" }, children: actions }) : null
517
720
  ] }) : null,
518
- children ? /* @__PURE__ */ jsx7("div", { className: "pire-card-body", children }) : null,
519
- footer ? /* @__PURE__ */ jsx7("footer", { className: "pire-card-foot", children: footer }) : null
721
+ children ? /* @__PURE__ */ jsx8("div", { className: "pire-card-body", children }) : null,
722
+ footer ? /* @__PURE__ */ jsx8("footer", { className: "pire-card-foot", children: footer }) : null
520
723
  ] });
521
724
  }
522
725
 
523
726
  // src/components/core/Avatar.tsx
524
- import * as React6 from "react";
525
- import { jsx as jsx8 } from "react/jsx-runtime";
727
+ import * as React7 from "react";
728
+ import { jsx as jsx9 } from "react/jsx-runtime";
526
729
  var initials = (name) => name.trim().split(/\s+/).slice(0, 2).map((p) => p[0]).join("").toUpperCase();
527
730
  function Avatar({ name, size = "md", src, className, ...rest }) {
528
- const [failed, setFailed] = React6.useState(false);
529
- return /* @__PURE__ */ jsx8("span", { className: cx("pire-avatar", className), "data-size": size, role: "img", "aria-label": name, ...rest, children: src && !failed ? /* @__PURE__ */ jsx8(
731
+ const [failed, setFailed] = React7.useState(false);
732
+ return /* @__PURE__ */ jsx9("span", { className: cx("pire-avatar", className), "data-size": size, role: "img", "aria-label": name, ...rest, children: src && !failed ? /* @__PURE__ */ jsx9(
530
733
  "img",
531
734
  {
532
735
  src,
@@ -538,9 +741,9 @@ function Avatar({ name, size = "md", src, className, ...rest }) {
538
741
  }
539
742
 
540
743
  // src/components/core/SegmentedControl.tsx
541
- import * as React7 from "react";
744
+ import * as React8 from "react";
542
745
  import { ToggleButtonGroup, ToggleButton } from "react-aria-components";
543
- import { jsx as jsx9, jsxs as jsxs7 } from "react/jsx-runtime";
746
+ import { jsx as jsx10, jsxs as jsxs7 } from "react/jsx-runtime";
544
747
  function SegmentedControl({
545
748
  options,
546
749
  value,
@@ -552,8 +755,8 @@ function SegmentedControl({
552
755
  style,
553
756
  ...rest
554
757
  }) {
555
- const selected = React7.useMemo(() => new Set(value ? [value] : defaultValue ? [defaultValue] : []), [value, defaultValue]);
556
- return /* @__PURE__ */ jsx9(
758
+ const selected = React8.useMemo(() => new Set(value ? [value] : defaultValue ? [defaultValue] : []), [value, defaultValue]);
759
+ return /* @__PURE__ */ jsx10(
557
760
  ToggleButtonGroup,
558
761
  {
559
762
  className: cx("pire-segmented", className),
@@ -575,7 +778,7 @@ function SegmentedControl({
575
778
  isDisabled: option.isDisabled,
576
779
  "aria-label": iconOnly ? option.label : void 0,
577
780
  children: [
578
- option.icon ? /* @__PURE__ */ jsx9(Icon, { name: option.icon, size: 16 }) : null,
781
+ option.icon ? /* @__PURE__ */ jsx10(Icon, { name: option.icon, size: 16 }) : null,
579
782
  iconOnly ? null : option.label
580
783
  ]
581
784
  },
@@ -586,9 +789,9 @@ function SegmentedControl({
586
789
  }
587
790
 
588
791
  // src/components/core/Text.tsx
589
- import * as React8 from "react";
590
- import { jsx as jsx10 } from "react/jsx-runtime";
591
- var Text = React8.forwardRef(function Text2({
792
+ import * as React9 from "react";
793
+ import { jsx as jsx11 } from "react/jsx-runtime";
794
+ var Text = React9.forwardRef(function Text2({
592
795
  size = "body",
593
796
  color = "primary",
594
797
  weight = "regular",
@@ -602,7 +805,7 @@ var Text = React8.forwardRef(function Text2({
602
805
  }, ref) {
603
806
  const lineClamp = typeof truncate === "number" ? truncate : truncate ? 1 : void 0;
604
807
  const clampStyle = lineClamp == null ? style : { ["--pire-text-clamp"]: lineClamp, ...style };
605
- return /* @__PURE__ */ jsx10(
808
+ return /* @__PURE__ */ jsx11(
606
809
  Wrapper,
607
810
  {
608
811
  ref,
@@ -618,13 +821,13 @@ var Text = React8.forwardRef(function Text2({
618
821
  }
619
822
  );
620
823
  });
621
- var Strong = React8.forwardRef(function Strong2({ className, ...rest }, ref) {
622
- return /* @__PURE__ */ jsx10(Text, { ref, elementType: "span", weight: "strong", className, ...rest });
824
+ var Strong = React9.forwardRef(function Strong2({ className, ...rest }, ref) {
825
+ return /* @__PURE__ */ jsx11(Text, { ref, elementType: "span", weight: "strong", className, ...rest });
623
826
  });
624
827
 
625
828
  // src/components/core/Heading.tsx
626
829
  import { Heading as AriaHeading } from "react-aria-components";
627
- import { jsx as jsx11 } from "react/jsx-runtime";
830
+ import { jsx as jsx12 } from "react/jsx-runtime";
628
831
  function Heading({
629
832
  level = 2,
630
833
  size,
@@ -636,7 +839,7 @@ function Heading({
636
839
  }) {
637
840
  const lineClamp = typeof truncate === "number" ? truncate : truncate ? 1 : void 0;
638
841
  const clampStyle = lineClamp == null ? style : { ["--pire-text-clamp"]: lineClamp, ...style };
639
- return /* @__PURE__ */ jsx11(
842
+ return /* @__PURE__ */ jsx12(
640
843
  AriaHeading,
641
844
  {
642
845
  level,
@@ -652,7 +855,7 @@ function Heading({
652
855
 
653
856
  // src/components/core/Link.tsx
654
857
  import { Link as AriaLink } from "react-aria-components";
655
- import { jsx as jsx12, jsxs as jsxs8 } from "react/jsx-runtime";
858
+ import { jsx as jsx13, jsxs as jsxs8 } from "react/jsx-runtime";
656
859
  function Link({ children, size, isExternal, className, rel, ...rest }) {
657
860
  return /* @__PURE__ */ jsxs8(
658
861
  AriaLink,
@@ -664,7 +867,7 @@ function Link({ children, size, isExternal, className, rel, ...rest }) {
664
867
  ...rest,
665
868
  children: [
666
869
  children,
667
- isExternal ? /* @__PURE__ */ jsx12(Icon, { name: "external-link", size: 12, className: "pire-link-external" }) : null
870
+ isExternal ? /* @__PURE__ */ jsx13(Icon, { name: "external-link", size: 12, className: "pire-link-external" }) : null
668
871
  ]
669
872
  }
670
873
  );
@@ -672,7 +875,7 @@ function Link({ children, size, isExternal, className, rel, ...rest }) {
672
875
 
673
876
  // src/components/core/Separator.tsx
674
877
  import { Separator as AriaSeparator } from "react-aria-components";
675
- import { jsx as jsx13 } from "react/jsx-runtime";
878
+ import { jsx as jsx14 } from "react/jsx-runtime";
676
879
  function Separator({
677
880
  orientation = "horizontal",
678
881
  emphasis = "default",
@@ -680,7 +883,7 @@ function Separator({
680
883
  className,
681
884
  ...rest
682
885
  }) {
683
- return /* @__PURE__ */ jsx13(
886
+ return /* @__PURE__ */ jsx14(
684
887
  AriaSeparator,
685
888
  {
686
889
  orientation,
@@ -694,24 +897,24 @@ function Separator({
694
897
  }
695
898
 
696
899
  // src/components/core/Kbd.tsx
697
- import { jsx as jsx14 } from "react/jsx-runtime";
900
+ import { jsx as jsx15 } from "react/jsx-runtime";
698
901
  function Kbd({ children, size = "md", className, ...rest }) {
699
- return /* @__PURE__ */ jsx14("kbd", { className: cx("pire-kbd", className), "data-size": size, ...rest, children });
902
+ return /* @__PURE__ */ jsx15("kbd", { className: cx("pire-kbd", className), "data-size": size, ...rest, children });
700
903
  }
701
904
 
702
905
  // src/components/forms/FormField.tsx
703
- import { jsx as jsx15, jsxs as jsxs9 } from "react/jsx-runtime";
906
+ import { jsx as jsx16, jsxs as jsxs9 } from "react/jsx-runtime";
704
907
  function FormField({ label, htmlFor, isRequired, hint, error, layout = "stacked", children, className, ...rest }) {
705
908
  return /* @__PURE__ */ jsxs9("div", { className: cx("pire-field", className), "data-layout": layout, ...rest, children: [
706
909
  /* @__PURE__ */ jsxs9("label", { className: "pire-field-label", htmlFor, children: [
707
910
  label,
708
- isRequired ? /* @__PURE__ */ jsx15("span", { className: "pire-field-req", "aria-hidden": "true", children: "*" }) : null
911
+ isRequired ? /* @__PURE__ */ jsx16("span", { className: "pire-field-req", "aria-hidden": "true", children: "*" }) : null
709
912
  ] }),
710
913
  children,
711
914
  error ? /* @__PURE__ */ jsxs9("span", { className: "pire-field-error", role: "alert", children: [
712
- /* @__PURE__ */ jsx15(Icon, { name: "alert-circle", size: 12 }),
915
+ /* @__PURE__ */ jsx16(Icon, { name: "alert-circle", size: 12 }),
713
916
  error
714
- ] }) : hint ? /* @__PURE__ */ jsx15("span", { className: "pire-field-hint", children: hint }) : null
917
+ ] }) : hint ? /* @__PURE__ */ jsx16("span", { className: "pire-field-hint", children: hint }) : null
715
918
  ] });
716
919
  }
717
920
 
@@ -727,165 +930,6 @@ import {
727
930
  Button as AriaButton4
728
931
  } from "react-aria-components";
729
932
 
730
- // src/i18n/PireIntlProvider.tsx
731
- import * as React9 from "react";
732
-
733
- // src/i18n/messages.ts
734
- var enMessages = {
735
- filterBarLabel: "Filters",
736
- filterBarGo: "Go",
737
- filterBarClearAll: "Clear all",
738
- dataTableSelectAll: "Select all rows",
739
- dataTableSelectRow: "Select row",
740
- dataTableLoading: "Loading records",
741
- dataTableSummaryRow: "Summary",
742
- dataTableEmpty: "No records match the current filters.",
743
- dialogClose: "Close",
744
- sidePanelClose: "Close panel",
745
- inlineMessageDismiss: "Dismiss message",
746
- toastDismiss: "Dismiss",
747
- toastRegionLabel: "Notifications",
748
- selectEmpty: "No options available",
749
- comboBoxShowSuggestions: "Show suggestions",
750
- comboBoxLoading: "Searching\u2026",
751
- datePickerOpenCalendar: "Open calendar",
752
- datePickerPreviousMonth: "Previous month",
753
- datePickerNextMonth: "Next month",
754
- dateRangePresetsLabel: "Date range shortcuts",
755
- numberFieldIncrease: "Increase",
756
- numberFieldDecrease: "Decrease",
757
- inputClear: "Clear",
758
- valueHelpFieldPlaceholder: "Not selected",
759
- valueHelpFieldClear: "Clear selection",
760
- valueHelpFieldOpenNamed: "Select {label}",
761
- valueHelpFieldOpen: "Open value help",
762
- valueHelpDialogSearch: "Search records",
763
- valueHelpDialogTitle: "Select a record",
764
- valueHelpDialogSearchPlaceholder: "Search by ID or name",
765
- valueHelpDialogEmpty: "No records found",
766
- valueHelpDialogCancel: "Cancel",
767
- paginationLabel: "Pagination",
768
- paginationRange: "{from}\u2013{to} of {total}",
769
- paginationPageOf: "Page {page} of {pages}",
770
- paginationPrevious: "Previous page",
771
- paginationNext: "Next page",
772
- paginationRowsPerPage: "Rows per page",
773
- sideNavLabel: "Main navigation",
774
- shellRailLabel: "Applications",
775
- appLauncherLabel: "All applications",
776
- appLauncherTitle: "All applications",
777
- appLauncherSearch: "Search for an application",
778
- appLauncherEmpty: "No application matches that search.",
779
- appLauncherLoading: "Loading applications\u2026",
780
- splitPaneList: "List",
781
- splitPaneDetail: "Detail",
782
- splitPaneBack: "Back to list",
783
- fileUploadChoose: "Choose files",
784
- fileUploadRemoveNamed: "Remove {name}",
785
- fileUploadUploading: "Uploading",
786
- fileDropZonePrompt: "Drag files here, or choose them",
787
- shellBarUserMenu: "Account menu for {user}",
788
- commandPaletteLabel: "Command palette",
789
- commandPaletteSearchLabel: "Search commands and records",
790
- commandPalettePlaceholder: "Search for a screen, an action or a record\u2026",
791
- commandPaletteEmpty: "Nothing matches that",
792
- commandPaletteLoading: "Searching\u2026",
793
- commandPaletteHintNavigate: "navigate",
794
- commandPaletteHintSelect: "open",
795
- commandPaletteHintClose: "close",
796
- chartCategoryHeader: "Category",
797
- chartNoValue: "No data",
798
- chartEmpty: "No data for this period",
799
- numPadClear: "Clear",
800
- numPadBackspace: "Remove last digit"
801
- };
802
- var esMessages = {
803
- filterBarLabel: "Filtros",
804
- filterBarGo: "Buscar",
805
- filterBarClearAll: "Limpiar todo",
806
- dataTableSelectAll: "Seleccionar todas las filas",
807
- dataTableSelectRow: "Seleccionar fila",
808
- dataTableLoading: "Cargando registros",
809
- dataTableSummaryRow: "Resumen",
810
- dataTableEmpty: "Ning\xFAn registro coincide con los filtros actuales.",
811
- dialogClose: "Cerrar",
812
- sidePanelClose: "Cerrar panel",
813
- inlineMessageDismiss: "Descartar mensaje",
814
- toastDismiss: "Descartar",
815
- toastRegionLabel: "Notificaciones",
816
- selectEmpty: "Sin opciones disponibles",
817
- comboBoxShowSuggestions: "Mostrar sugerencias",
818
- comboBoxLoading: "Buscando\u2026",
819
- datePickerOpenCalendar: "Abrir calendario",
820
- datePickerPreviousMonth: "Mes anterior",
821
- datePickerNextMonth: "Mes siguiente",
822
- dateRangePresetsLabel: "Atajos de rango de fechas",
823
- numberFieldIncrease: "Aumentar",
824
- numberFieldDecrease: "Disminuir",
825
- inputClear: "Limpiar",
826
- valueHelpFieldPlaceholder: "Sin seleccionar",
827
- valueHelpFieldClear: "Limpiar selecci\xF3n",
828
- valueHelpFieldOpenNamed: "Seleccionar {label}",
829
- valueHelpFieldOpen: "Abrir ayuda de valores",
830
- valueHelpDialogSearch: "Buscar registros",
831
- valueHelpDialogTitle: "Seleccionar un registro",
832
- valueHelpDialogSearchPlaceholder: "Buscar por c\xF3digo o nombre",
833
- valueHelpDialogEmpty: "No se encontraron registros",
834
- valueHelpDialogCancel: "Cancelar",
835
- paginationLabel: "Paginaci\xF3n",
836
- paginationRange: "{from}\u2013{to} de {total}",
837
- paginationPageOf: "P\xE1gina {page} de {pages}",
838
- paginationPrevious: "P\xE1gina anterior",
839
- paginationNext: "P\xE1gina siguiente",
840
- paginationRowsPerPage: "Filas por p\xE1gina",
841
- sideNavLabel: "Navegaci\xF3n principal",
842
- shellRailLabel: "Aplicaciones",
843
- appLauncherLabel: "Todas las aplicaciones",
844
- appLauncherTitle: "Todas las aplicaciones",
845
- appLauncherSearch: "Busc\xE1 una aplicaci\xF3n",
846
- appLauncherEmpty: "Ninguna aplicaci\xF3n coincide con esa b\xFAsqueda.",
847
- appLauncherLoading: "Cargando aplicaciones\u2026",
848
- splitPaneList: "Lista",
849
- splitPaneDetail: "Detalle",
850
- splitPaneBack: "Volver a la lista",
851
- fileUploadChoose: "Elegir archivos",
852
- fileUploadRemoveNamed: "Quitar {name}",
853
- fileUploadUploading: "Subiendo",
854
- fileDropZonePrompt: "Arrastr\xE1 archivos ac\xE1, o elegilos",
855
- shellBarUserMenu: "Men\xFA de cuenta de {user}",
856
- commandPaletteLabel: "Paleta de comandos",
857
- commandPaletteSearchLabel: "Buscar comandos y registros",
858
- commandPalettePlaceholder: "Busc\xE1 una pantalla, una acci\xF3n o un registro\u2026",
859
- commandPaletteEmpty: "No hay coincidencias",
860
- commandPaletteLoading: "Buscando\u2026",
861
- commandPaletteHintNavigate: "navegar",
862
- commandPaletteHintSelect: "abrir",
863
- commandPaletteHintClose: "cerrar",
864
- chartCategoryHeader: "Categor\xEDa",
865
- chartNoValue: "Sin datos",
866
- chartEmpty: "Sin datos para este per\xEDodo",
867
- numPadClear: "Limpiar",
868
- numPadBackspace: "Borrar \xFAltimo d\xEDgito"
869
- };
870
-
871
- // src/i18n/PireIntlProvider.tsx
872
- import { jsx as jsx16 } from "react/jsx-runtime";
873
- var MessagesContext = React9.createContext(enMessages);
874
- function PireIntlProvider({ messages, children }) {
875
- const value = React9.useMemo(
876
- () => messages ? { ...enMessages, ...messages } : enMessages,
877
- [messages]
878
- );
879
- return /* @__PURE__ */ jsx16(MessagesContext.Provider, { value, children });
880
- }
881
- function usePireMessages() {
882
- return React9.useContext(MessagesContext);
883
- }
884
- function useMessage(key, override) {
885
- const messages = React9.useContext(MessagesContext);
886
- return override ?? messages[key];
887
- }
888
-
889
933
  // src/components/utils/focusField.ts
890
934
  function focusFieldOf(button) {
891
935
  const control = button?.closest?.(".pire-control");
@@ -1182,21 +1226,69 @@ function Switch({ label, children, className, ...rest }) {
1182
1226
  ] });
1183
1227
  }
1184
1228
 
1229
+ // src/components/forms/ChoiceCardGroup.tsx
1230
+ import { RadioGroup as AriaRadioGroup2, Radio as AriaRadio2, Label as Label5, Text as Text7, FieldError as FieldError5 } from "react-aria-components";
1231
+ import { jsx as jsx23, jsxs as jsxs16 } from "react/jsx-runtime";
1232
+ function ChoiceCardGroup({
1233
+ label,
1234
+ description,
1235
+ errorMessage,
1236
+ options,
1237
+ value,
1238
+ defaultValue,
1239
+ onChange,
1240
+ columns = 2,
1241
+ isDisabled,
1242
+ isRequired,
1243
+ className,
1244
+ style,
1245
+ ...rest
1246
+ }) {
1247
+ return /* @__PURE__ */ jsxs16(
1248
+ AriaRadioGroup2,
1249
+ {
1250
+ className: cx("pire-field", className),
1251
+ style,
1252
+ validationBehavior: "aria",
1253
+ "aria-label": label ? void 0 : rest["aria-label"],
1254
+ value,
1255
+ defaultValue,
1256
+ onChange,
1257
+ isDisabled,
1258
+ isRequired,
1259
+ children: [
1260
+ label ? /* @__PURE__ */ jsxs16(Label5, { className: "pire-field-label", children: [
1261
+ label,
1262
+ isRequired ? /* @__PURE__ */ jsx23("span", { className: "pire-field-req", "aria-hidden": "true", children: "*" }) : null
1263
+ ] }) : null,
1264
+ /* @__PURE__ */ jsx23("div", { className: "pire-choicecards", style: { gridTemplateColumns: `repeat(${columns}, minmax(0, 1fr))` }, children: options.map((option) => /* @__PURE__ */ jsxs16(AriaRadio2, { value: option.id, className: "pire-choicecard", isDisabled: option.isDisabled, children: [
1265
+ option.icon ? /* @__PURE__ */ jsx23(Icon, { name: option.icon, size: 20 }) : null,
1266
+ /* @__PURE__ */ jsx23("span", { className: "pire-choicecard-label", children: option.label }),
1267
+ option.description ? /* @__PURE__ */ jsx23("span", { className: "pire-choicecard-desc", children: option.description }) : null,
1268
+ option.preview ? /* @__PURE__ */ jsx23("span", { className: "pire-choicecard-preview", "aria-hidden": "true", children: option.preview }) : null
1269
+ ] }, option.id)) }),
1270
+ description ? /* @__PURE__ */ jsx23(Text7, { slot: "description", className: "pire-field-hint", children: description }) : null,
1271
+ /* @__PURE__ */ jsx23(FieldError5, { className: "pire-field-error", children: errorMessage })
1272
+ ]
1273
+ }
1274
+ );
1275
+ }
1276
+
1185
1277
  // src/components/forms/ComboBox.tsx
1186
1278
  import * as React12 from "react";
1187
1279
  import {
1188
1280
  ComboBox as AriaComboBox,
1189
- Label as Label5,
1281
+ Label as Label6,
1190
1282
  Input as AriaInput2,
1191
1283
  Button as AriaButton6,
1192
1284
  Group as Group3,
1193
1285
  Popover as Popover2,
1194
1286
  ListBox as ListBox2,
1195
1287
  ListBoxItem as ListBoxItem2,
1196
- Text as Text7,
1197
- FieldError as FieldError5
1288
+ Text as Text8,
1289
+ FieldError as FieldError6
1198
1290
  } from "react-aria-components";
1199
- import { jsx as jsx23, jsxs as jsxs16 } from "react/jsx-runtime";
1291
+ import { jsx as jsx24, jsxs as jsxs17 } from "react/jsx-runtime";
1200
1292
  var norm2 = (o) => typeof o === "string" ? { value: o, label: o } : o;
1201
1293
  function ComboBox({
1202
1294
  label,
@@ -1242,7 +1334,7 @@ function ComboBox({
1242
1334
  };
1243
1335
  const collection = isFilteredExternally ? { items } : { defaultItems: items };
1244
1336
  const showsStatus = isLoading || isFilteredExternally && items.length === 0 && emptyLabel != null;
1245
- return /* @__PURE__ */ jsxs16(
1337
+ return /* @__PURE__ */ jsxs17(
1246
1338
  AriaComboBox,
1247
1339
  {
1248
1340
  className: cx("pire-field", className),
@@ -1263,11 +1355,11 @@ function ComboBox({
1263
1355
  validationBehavior: "aria",
1264
1356
  ...rest,
1265
1357
  children: [
1266
- label ? /* @__PURE__ */ jsxs16(Label5, { className: "pire-field-label", children: [
1358
+ label ? /* @__PURE__ */ jsxs17(Label6, { className: "pire-field-label", children: [
1267
1359
  label,
1268
- rest.isRequired ? /* @__PURE__ */ jsx23("span", { className: "pire-field-req", "aria-hidden": "true", children: "*" }) : null
1360
+ rest.isRequired ? /* @__PURE__ */ jsx24("span", { className: "pire-field-req", "aria-hidden": "true", children: "*" }) : null
1269
1361
  ] }) : null,
1270
- /* @__PURE__ */ jsxs16(
1362
+ /* @__PURE__ */ jsxs17(
1271
1363
  Group3,
1272
1364
  {
1273
1365
  className: "pire-control",
@@ -1275,9 +1367,9 @@ function ComboBox({
1275
1367
  "data-full-width": String(fullWidth),
1276
1368
  "data-invalid": rest.isInvalid ? "true" : void 0,
1277
1369
  children: [
1278
- /* @__PURE__ */ jsx23(Icon, { name: "search", size: 16, className: "pire-leading-icon" }),
1279
- /* @__PURE__ */ jsx23(AriaInput2, { className: "pire-input", placeholder: rest.placeholder }),
1280
- showsClear ? /* @__PURE__ */ jsx23(
1370
+ /* @__PURE__ */ jsx24(Icon, { name: "search", size: 16, className: "pire-leading-icon" }),
1371
+ /* @__PURE__ */ jsx24(AriaInput2, { className: "pire-input", placeholder: rest.placeholder }),
1372
+ showsClear ? /* @__PURE__ */ jsx24(
1281
1373
  AriaButton6,
1282
1374
  {
1283
1375
  className: "pire-input-clear",
@@ -1289,13 +1381,13 @@ function ComboBox({
1289
1381
  children: clearLabel ?? msg.inputClear
1290
1382
  }
1291
1383
  ) : null,
1292
- /* @__PURE__ */ jsx23(AriaButton6, { className: "pire-iconbtn", "data-size": "sm", "aria-label": msg.comboBoxShowSuggestions, style: { width: 20, height: 20 }, children: /* @__PURE__ */ jsx23(Icon, { name: "chevron-down", size: 16 }) })
1384
+ /* @__PURE__ */ jsx24(AriaButton6, { className: "pire-iconbtn", "data-size": "sm", "aria-label": msg.comboBoxShowSuggestions, style: { width: 20, height: 20 }, children: /* @__PURE__ */ jsx24(Icon, { name: "chevron-down", size: 16 }) })
1293
1385
  ]
1294
1386
  }
1295
1387
  ),
1296
- description ? /* @__PURE__ */ jsx23(Text7, { slot: "description", className: "pire-field-hint", children: description }) : null,
1297
- /* @__PURE__ */ jsx23(FieldError5, { className: "pire-field-error", children: errorMessage }),
1298
- /* @__PURE__ */ jsx23(Popover2, { className: "pire-popover", children: /* @__PURE__ */ jsx23(
1388
+ description ? /* @__PURE__ */ jsx24(Text8, { slot: "description", className: "pire-field-hint", children: description }) : null,
1389
+ /* @__PURE__ */ jsx24(FieldError6, { className: "pire-field-error", children: errorMessage }),
1390
+ /* @__PURE__ */ jsx24(Popover2, { className: "pire-popover", children: /* @__PURE__ */ jsx24(
1299
1391
  ListBox2,
1300
1392
  {
1301
1393
  className: "pire-listbox",
@@ -1303,10 +1395,10 @@ function ComboBox({
1303
1395
  const el = e.currentTarget;
1304
1396
  if (el.scrollHeight - el.scrollTop - el.clientHeight < 48) onLoadMore();
1305
1397
  } : void 0,
1306
- renderEmptyState: showsStatus ? () => /* @__PURE__ */ jsx23("div", { className: "pire-listbox-status", role: "status", "aria-live": "polite", children: isLoading ? loadingLabel ?? msg.comboBoxLoading : emptyLabel }) : void 0,
1307
- children: (item) => /* @__PURE__ */ jsxs16(ListBoxItem2, { className: "pire-option", id: item.value, textValue: item.label, isDisabled: item.isDisabled, children: [
1308
- /* @__PURE__ */ jsx23("span", { className: "pire-option-label", children: item.label }),
1309
- item.secondary ? /* @__PURE__ */ jsx23("span", { className: "pire-option-secondary", children: item.secondary }) : null
1398
+ renderEmptyState: showsStatus ? () => /* @__PURE__ */ jsx24("div", { className: "pire-listbox-status", role: "status", "aria-live": "polite", children: isLoading ? loadingLabel ?? msg.comboBoxLoading : emptyLabel }) : void 0,
1399
+ children: (item) => /* @__PURE__ */ jsxs17(ListBoxItem2, { className: "pire-option", id: item.value, textValue: item.label, isDisabled: item.isDisabled, children: [
1400
+ /* @__PURE__ */ jsx24("span", { className: "pire-option-label", children: item.label }),
1401
+ item.secondary ? /* @__PURE__ */ jsx24("span", { className: "pire-option-secondary", children: item.secondary }) : null
1310
1402
  ] })
1311
1403
  }
1312
1404
  ) })
@@ -1319,7 +1411,7 @@ function ComboBox({
1319
1411
  import * as React13 from "react";
1320
1412
  import {
1321
1413
  ComboBox as AriaComboBox2,
1322
- Label as Label6,
1414
+ Label as Label7,
1323
1415
  Input as AriaInput3,
1324
1416
  Button as AriaButton7,
1325
1417
  ButtonContext,
@@ -1327,11 +1419,11 @@ import {
1327
1419
  Popover as Popover3,
1328
1420
  ListBox as ListBox3,
1329
1421
  ListBoxItem as ListBoxItem3,
1330
- Text as Text8,
1331
- FieldError as FieldError6,
1422
+ Text as Text9,
1423
+ FieldError as FieldError7,
1332
1424
  VisuallyHidden
1333
1425
  } from "react-aria-components";
1334
- import { jsx as jsx24, jsxs as jsxs17 } from "react/jsx-runtime";
1426
+ import { jsx as jsx25, jsxs as jsxs18 } from "react/jsx-runtime";
1335
1427
  var norm3 = (o) => typeof o === "string" ? { value: o, label: o } : o;
1336
1428
  function MultiComboBox({
1337
1429
  label,
@@ -1396,7 +1488,7 @@ function MultiComboBox({
1396
1488
  e.stopPropagation();
1397
1489
  if (!values.includes(next)) commit([...values, next]);
1398
1490
  };
1399
- return /* @__PURE__ */ jsxs17(
1491
+ return /* @__PURE__ */ jsxs18(
1400
1492
  AriaComboBox2,
1401
1493
  {
1402
1494
  className: cx("pire-field", className),
@@ -1413,11 +1505,11 @@ function MultiComboBox({
1413
1505
  validationBehavior: "aria",
1414
1506
  ...rest,
1415
1507
  children: [
1416
- label ? /* @__PURE__ */ jsxs17(Label6, { className: "pire-field-label", children: [
1508
+ label ? /* @__PURE__ */ jsxs18(Label7, { className: "pire-field-label", children: [
1417
1509
  label,
1418
- rest.isRequired ? /* @__PURE__ */ jsx24("span", { className: "pire-field-req", "aria-hidden": "true", children: "*" }) : null
1510
+ rest.isRequired ? /* @__PURE__ */ jsx25("span", { className: "pire-field-req", "aria-hidden": "true", children: "*" }) : null
1419
1511
  ] }) : null,
1420
- /* @__PURE__ */ jsxs17(
1512
+ /* @__PURE__ */ jsxs18(
1421
1513
  Group4,
1422
1514
  {
1423
1515
  className: "pire-control",
@@ -1427,14 +1519,14 @@ function MultiComboBox({
1427
1519
  "data-invalid": rest.isInvalid ? "true" : void 0,
1428
1520
  "data-readonly": rest.isReadOnly ? "true" : void 0,
1429
1521
  children: [
1430
- /* @__PURE__ */ jsx24(Icon, { name: "search", size: 16, className: "pire-leading-icon" }),
1431
- /* @__PURE__ */ jsxs17("div", { className: "pire-chipfield", children: [
1432
- /* @__PURE__ */ jsx24(ButtonContext.Provider, { value: null, children: values.map((v) => (
1522
+ /* @__PURE__ */ jsx25(Icon, { name: "search", size: 16, className: "pire-leading-icon" }),
1523
+ /* @__PURE__ */ jsxs18("div", { className: "pire-chipfield", children: [
1524
+ /* @__PURE__ */ jsx25(ButtonContext.Provider, { value: null, children: values.map((v) => (
1433
1525
  /* Disabled follows the field, not `isEditable`: a read-only field's chips are
1434
1526
  real, current values and should read as such — they simply lose the × . */
1435
- /* @__PURE__ */ jsx24(Tag, { isDisabled: rest.isDisabled, onRemove: isEditable ? () => remove(v) : void 0, children: labelOf(v) }, v)
1527
+ /* @__PURE__ */ jsx25(Tag, { isDisabled: rest.isDisabled, onRemove: isEditable ? () => remove(v) : void 0, children: labelOf(v) }, v)
1436
1528
  )) }),
1437
- /* @__PURE__ */ jsx24(
1529
+ /* @__PURE__ */ jsx25(
1438
1530
  AriaInput3,
1439
1531
  {
1440
1532
  ref: inputRef,
@@ -1444,14 +1536,14 @@ function MultiComboBox({
1444
1536
  }
1445
1537
  )
1446
1538
  ] }),
1447
- /* @__PURE__ */ jsx24(AriaButton7, { className: "pire-iconbtn", "data-size": "sm", "aria-label": msg.comboBoxShowSuggestions, style: { width: 20, height: 20 }, children: /* @__PURE__ */ jsx24(Icon, { name: "chevron-down", size: 16 }) })
1539
+ /* @__PURE__ */ jsx25(AriaButton7, { className: "pire-iconbtn", "data-size": "sm", "aria-label": msg.comboBoxShowSuggestions, style: { width: 20, height: 20 }, children: /* @__PURE__ */ jsx25(Icon, { name: "chevron-down", size: 16 }) })
1448
1540
  ]
1449
1541
  }
1450
1542
  ),
1451
- /* @__PURE__ */ jsx24(VisuallyHidden, { children: /* @__PURE__ */ jsx24("span", { "aria-live": "polite", children: announcement }) }),
1452
- description ? /* @__PURE__ */ jsx24(Text8, { slot: "description", className: "pire-field-hint", children: description }) : null,
1453
- /* @__PURE__ */ jsx24(FieldError6, { className: "pire-field-error", children: errorMessage }),
1454
- /* @__PURE__ */ jsx24(Popover3, { className: "pire-popover", children: /* @__PURE__ */ jsx24(
1543
+ /* @__PURE__ */ jsx25(VisuallyHidden, { children: /* @__PURE__ */ jsx25("span", { "aria-live": "polite", children: announcement }) }),
1544
+ description ? /* @__PURE__ */ jsx25(Text9, { slot: "description", className: "pire-field-hint", children: description }) : null,
1545
+ /* @__PURE__ */ jsx25(FieldError7, { className: "pire-field-error", children: errorMessage }),
1546
+ /* @__PURE__ */ jsx25(Popover3, { className: "pire-popover", children: /* @__PURE__ */ jsx25(
1455
1547
  ListBox3,
1456
1548
  {
1457
1549
  className: "pire-listbox",
@@ -1459,10 +1551,10 @@ function MultiComboBox({
1459
1551
  const el = e.currentTarget;
1460
1552
  if (el.scrollHeight - el.scrollTop - el.clientHeight < 48) onLoadMore();
1461
1553
  } : void 0,
1462
- renderEmptyState: showsStatus ? () => /* @__PURE__ */ jsx24("div", { className: "pire-listbox-status", role: "status", "aria-live": "polite", children: isLoading ? loadingLabel ?? msg.comboBoxLoading : emptyLabel }) : void 0,
1463
- children: (item) => /* @__PURE__ */ jsxs17(ListBoxItem3, { className: "pire-option", id: item.value, textValue: item.label, isDisabled: item.isDisabled, children: [
1464
- /* @__PURE__ */ jsx24("span", { className: "pire-option-label", children: item.label }),
1465
- item.secondary ? /* @__PURE__ */ jsx24("span", { className: "pire-option-secondary", children: item.secondary }) : null
1554
+ renderEmptyState: showsStatus ? () => /* @__PURE__ */ jsx25("div", { className: "pire-listbox-status", role: "status", "aria-live": "polite", children: isLoading ? loadingLabel ?? msg.comboBoxLoading : emptyLabel }) : void 0,
1555
+ children: (item) => /* @__PURE__ */ jsxs18(ListBoxItem3, { className: "pire-option", id: item.value, textValue: item.label, isDisabled: item.isDisabled, children: [
1556
+ /* @__PURE__ */ jsx25("span", { className: "pire-option-label", children: item.label }),
1557
+ item.secondary ? /* @__PURE__ */ jsx25("span", { className: "pire-option-secondary", children: item.secondary }) : null
1466
1558
  ] })
1467
1559
  }
1468
1560
  ) })
@@ -1475,16 +1567,16 @@ function MultiComboBox({
1475
1567
  import * as React14 from "react";
1476
1568
  import {
1477
1569
  NumberField as AriaNumberField,
1478
- Label as Label7,
1570
+ Label as Label8,
1479
1571
  Input as AriaInput4,
1480
1572
  Group as Group5,
1481
1573
  Button as AriaButton8,
1482
- Text as Text9,
1483
- FieldError as FieldError7,
1574
+ Text as Text10,
1575
+ FieldError as FieldError8,
1484
1576
  useLocale,
1485
1577
  NumberFieldStateContext
1486
1578
  } from "react-aria-components";
1487
- import { jsx as jsx25, jsxs as jsxs18 } from "react/jsx-runtime";
1579
+ import { jsx as jsx26, jsxs as jsxs19 } from "react/jsx-runtime";
1488
1580
  function decimalSeparatorFor(locale) {
1489
1581
  return new Intl.NumberFormat(locale).formatToParts(1.1).find((part) => part.type === "decimal")?.value ?? ".";
1490
1582
  }
@@ -1522,7 +1614,7 @@ function ClearButton({ label, onClear }) {
1522
1614
  if (!state?.inputValue) {
1523
1615
  return null;
1524
1616
  }
1525
- return /* @__PURE__ */ jsx25(
1617
+ return /* @__PURE__ */ jsx26(
1526
1618
  AriaButton8,
1527
1619
  {
1528
1620
  className: "pire-input-clear",
@@ -1541,6 +1633,9 @@ function NumberField({
1541
1633
  description,
1542
1634
  errorMessage,
1543
1635
  hideStepper,
1636
+ stepperLayout = "stacked",
1637
+ incrementLabel,
1638
+ decrementLabel,
1544
1639
  size = "md",
1545
1640
  fullWidth = true,
1546
1641
  className,
@@ -1606,7 +1701,7 @@ function NumberField({
1606
1701
  event.stopPropagation();
1607
1702
  typeIntoInput(event.currentTarget, localised);
1608
1703
  };
1609
- return /* @__PURE__ */ jsxs18(
1704
+ return /* @__PURE__ */ jsxs19(
1610
1705
  AriaNumberField,
1611
1706
  {
1612
1707
  className: cx("pire-field", className),
@@ -1616,11 +1711,11 @@ function NumberField({
1616
1711
  ...rest,
1617
1712
  ...valueProps,
1618
1713
  children: [
1619
- label ? /* @__PURE__ */ jsxs18(Label7, { className: "pire-field-label", children: [
1714
+ label ? /* @__PURE__ */ jsxs19(Label8, { className: "pire-field-label", children: [
1620
1715
  label,
1621
- rest.isRequired ? /* @__PURE__ */ jsx25("span", { className: "pire-field-req", "aria-hidden": "true", children: "*" }) : null
1716
+ rest.isRequired ? /* @__PURE__ */ jsx26("span", { className: "pire-field-req", "aria-hidden": "true", children: "*" }) : null
1622
1717
  ] }) : null,
1623
- /* @__PURE__ */ jsxs18(
1718
+ /* @__PURE__ */ jsxs19(
1624
1719
  Group5,
1625
1720
  {
1626
1721
  className: "pire-control",
@@ -1628,8 +1723,10 @@ function NumberField({
1628
1723
  "data-full-width": String(fullWidth),
1629
1724
  "data-invalid": rest.isInvalid ? "true" : void 0,
1630
1725
  "data-readonly": rest.isReadOnly ? "true" : void 0,
1726
+ "data-stepper": stepperLayout,
1631
1727
  children: [
1632
- /* @__PURE__ */ jsx25(
1728
+ !hideStepper && stepperLayout === "inline" ? /* @__PURE__ */ jsx26(AriaButton8, { slot: "decrement", className: "pire-qty-btn", "aria-label": decrementLabel ?? msg.numberFieldDecrease, children: /* @__PURE__ */ jsx26(Icon, { name: "minus", size: 16 }) }) : null,
1729
+ /* @__PURE__ */ jsx26(
1633
1730
  AriaInput4,
1634
1731
  {
1635
1732
  className: "pire-input",
@@ -1638,27 +1735,45 @@ function NumberField({
1638
1735
  onPasteCapture: handlePaste
1639
1736
  }
1640
1737
  ),
1641
- suffix ? /* @__PURE__ */ jsx25("span", { className: "pire-affix", children: suffix }) : null,
1642
- showsClear ? /* @__PURE__ */ jsx25(ClearButton, { label: clearLabel ?? msg.inputClear, onClear: () => handleChange(NaN) }) : null,
1643
- hideStepper ? null : /* @__PURE__ */ jsxs18("span", { className: "pire-stepper", children: [
1644
- /* @__PURE__ */ jsx25(AriaButton8, { slot: "increment", className: "pire-stepper-btn", "aria-label": msg.numberFieldIncrease, children: /* @__PURE__ */ jsx25(Icon, { name: "plus", size: 10 }) }),
1645
- /* @__PURE__ */ jsx25(AriaButton8, { slot: "decrement", className: "pire-stepper-btn", "aria-label": msg.numberFieldDecrease, children: /* @__PURE__ */ jsx25(Icon, { name: "minus", size: 10 }) })
1738
+ suffix ? /* @__PURE__ */ jsx26("span", { className: "pire-affix", children: suffix }) : null,
1739
+ showsClear ? /* @__PURE__ */ jsx26(ClearButton, { label: clearLabel ?? msg.inputClear, onClear: () => handleChange(NaN) }) : null,
1740
+ !hideStepper && stepperLayout === "inline" ? /* @__PURE__ */ jsx26(AriaButton8, { slot: "increment", className: "pire-qty-btn", "aria-label": incrementLabel ?? msg.numberFieldIncrease, children: /* @__PURE__ */ jsx26(Icon, { name: "plus", size: 16 }) }) : null,
1741
+ hideStepper ? null : stepperLayout === "inline" ? null : /* @__PURE__ */ jsxs19("span", { className: "pire-stepper", children: [
1742
+ /* @__PURE__ */ jsx26(AriaButton8, { slot: "increment", className: "pire-stepper-btn", "aria-label": incrementLabel ?? msg.numberFieldIncrease, children: /* @__PURE__ */ jsx26(Icon, { name: "plus", size: 10 }) }),
1743
+ /* @__PURE__ */ jsx26(AriaButton8, { slot: "decrement", className: "pire-stepper-btn", "aria-label": decrementLabel ?? msg.numberFieldDecrease, children: /* @__PURE__ */ jsx26(Icon, { name: "minus", size: 10 }) })
1646
1744
  ] })
1647
1745
  ]
1648
1746
  }
1649
1747
  ),
1650
- description ? /* @__PURE__ */ jsx25(Text9, { slot: "description", className: "pire-field-hint", children: description }) : null,
1651
- /* @__PURE__ */ jsx25(FieldError7, { className: "pire-field-error", children: errorMessage })
1748
+ description ? /* @__PURE__ */ jsx26(Text10, { slot: "description", className: "pire-field-hint", children: description }) : null,
1749
+ /* @__PURE__ */ jsx26(FieldError8, { className: "pire-field-error", children: errorMessage })
1652
1750
  ]
1653
1751
  }
1654
1752
  );
1655
1753
  }
1656
1754
 
1755
+ // src/components/forms/QuantityStepper.tsx
1756
+ import { jsx as jsx27 } from "react/jsx-runtime";
1757
+ function QuantityStepper({ size = "md", ...rest }) {
1758
+ const msg = usePireMessages();
1759
+ return /* @__PURE__ */ jsx27(
1760
+ NumberField,
1761
+ {
1762
+ ...rest,
1763
+ size,
1764
+ stepperLayout: "inline",
1765
+ emptyValue: null,
1766
+ incrementLabel: msg.quantityStepperIncrease,
1767
+ decrementLabel: msg.quantityStepperDecrease
1768
+ }
1769
+ );
1770
+ }
1771
+
1657
1772
  // src/components/forms/DatePicker.tsx
1658
1773
  import * as React15 from "react";
1659
1774
  import {
1660
1775
  DatePicker as AriaDatePicker,
1661
- Label as Label8,
1776
+ Label as Label9,
1662
1777
  Group as Group6,
1663
1778
  DateInput,
1664
1779
  DateSegment,
@@ -1672,8 +1787,8 @@ import {
1672
1787
  CalendarGridBody,
1673
1788
  CalendarCell,
1674
1789
  Heading as Heading2,
1675
- Text as Text10,
1676
- FieldError as FieldError8,
1790
+ Text as Text11,
1791
+ FieldError as FieldError9,
1677
1792
  DatePickerStateContext
1678
1793
  } from "react-aria-components";
1679
1794
 
@@ -1705,13 +1820,13 @@ function coerceBound(value) {
1705
1820
  }
1706
1821
 
1707
1822
  // src/components/forms/DatePicker.tsx
1708
- import { jsx as jsx26, jsxs as jsxs19 } from "react/jsx-runtime";
1823
+ import { jsx as jsx28, jsxs as jsxs20 } from "react/jsx-runtime";
1709
1824
  function ClearButton2({ label }) {
1710
1825
  const state = React15.useContext(DatePickerStateContext);
1711
1826
  if (!state?.value) {
1712
1827
  return null;
1713
1828
  }
1714
- return /* @__PURE__ */ jsx26(
1829
+ return /* @__PURE__ */ jsx28(
1715
1830
  AriaButton9,
1716
1831
  {
1717
1832
  className: "pire-input-clear",
@@ -1747,7 +1862,7 @@ function DatePicker({
1747
1862
  const handleChange = (next) => onChange?.(
1748
1863
  valueFormat === "iso" && next ? next.toString() : next
1749
1864
  );
1750
- return /* @__PURE__ */ jsxs19(
1865
+ return /* @__PURE__ */ jsxs20(
1751
1866
  AriaDatePicker,
1752
1867
  {
1753
1868
  className: cx("pire-field", className),
@@ -1760,11 +1875,11 @@ function DatePicker({
1760
1875
  onChange: handleChange,
1761
1876
  ...rest,
1762
1877
  children: [
1763
- label ? /* @__PURE__ */ jsxs19(Label8, { className: "pire-field-label", children: [
1878
+ label ? /* @__PURE__ */ jsxs20(Label9, { className: "pire-field-label", children: [
1764
1879
  label,
1765
- rest.isRequired ? /* @__PURE__ */ jsx26("span", { className: "pire-field-req", "aria-hidden": "true", children: "*" }) : null
1880
+ rest.isRequired ? /* @__PURE__ */ jsx28("span", { className: "pire-field-req", "aria-hidden": "true", children: "*" }) : null
1766
1881
  ] }) : null,
1767
- /* @__PURE__ */ jsxs19(
1882
+ /* @__PURE__ */ jsxs20(
1768
1883
  Group6,
1769
1884
  {
1770
1885
  className: "pire-control",
@@ -1773,23 +1888,23 @@ function DatePicker({
1773
1888
  "data-invalid": rest.isInvalid ? "true" : void 0,
1774
1889
  "data-readonly": rest.isReadOnly ? "true" : void 0,
1775
1890
  children: [
1776
- /* @__PURE__ */ jsx26(DateInput, { className: "pire-datefield", children: (segment) => /* @__PURE__ */ jsx26(DateSegment, { segment, className: "pire-datesegment" }) }),
1777
- showsClear ? /* @__PURE__ */ jsx26(ClearButton2, { label: clearLabel ?? msg.inputClear }) : null,
1778
- /* @__PURE__ */ jsx26(AriaButton9, { className: "pire-iconbtn", "data-size": "sm", "aria-label": msg.datePickerOpenCalendar, style: { width: 24, height: 24 }, children: /* @__PURE__ */ jsx26(Icon, { name: "calendar", size: 16 }) })
1891
+ /* @__PURE__ */ jsx28(DateInput, { className: "pire-datefield", children: (segment) => /* @__PURE__ */ jsx28(DateSegment, { segment, className: "pire-datesegment" }) }),
1892
+ showsClear ? /* @__PURE__ */ jsx28(ClearButton2, { label: clearLabel ?? msg.inputClear }) : null,
1893
+ /* @__PURE__ */ jsx28(AriaButton9, { className: "pire-iconbtn", "data-size": "sm", "aria-label": msg.datePickerOpenCalendar, style: { width: 24, height: 24 }, children: /* @__PURE__ */ jsx28(Icon, { name: "calendar", size: 16 }) })
1779
1894
  ]
1780
1895
  }
1781
1896
  ),
1782
- description ? /* @__PURE__ */ jsx26(Text10, { slot: "description", className: "pire-field-hint", children: description }) : null,
1783
- /* @__PURE__ */ jsx26(FieldError8, { className: "pire-field-error", children: errorMessage }),
1784
- /* @__PURE__ */ jsx26(Popover4, { className: "pire-popover", children: /* @__PURE__ */ jsx26(AriaDialog, { children: /* @__PURE__ */ jsxs19(Calendar, { className: "pire-calendar", children: [
1785
- /* @__PURE__ */ jsxs19("header", { className: "pire-calendar-head", children: [
1786
- /* @__PURE__ */ jsx26(AriaButton9, { slot: "previous", className: "pire-iconbtn", "data-size": "sm", "aria-label": msg.datePickerPreviousMonth, children: /* @__PURE__ */ jsx26(Icon, { name: "chevron-left", size: 16 }) }),
1787
- /* @__PURE__ */ jsx26(Heading2, { className: "pire-calendar-title" }),
1788
- /* @__PURE__ */ jsx26(AriaButton9, { slot: "next", className: "pire-iconbtn", "data-size": "sm", "aria-label": msg.datePickerNextMonth, children: /* @__PURE__ */ jsx26(Icon, { name: "chevron-right", size: 16 }) })
1897
+ description ? /* @__PURE__ */ jsx28(Text11, { slot: "description", className: "pire-field-hint", children: description }) : null,
1898
+ /* @__PURE__ */ jsx28(FieldError9, { className: "pire-field-error", children: errorMessage }),
1899
+ /* @__PURE__ */ jsx28(Popover4, { className: "pire-popover", children: /* @__PURE__ */ jsx28(AriaDialog, { children: /* @__PURE__ */ jsxs20(Calendar, { className: "pire-calendar", children: [
1900
+ /* @__PURE__ */ jsxs20("header", { className: "pire-calendar-head", children: [
1901
+ /* @__PURE__ */ jsx28(AriaButton9, { slot: "previous", className: "pire-iconbtn", "data-size": "sm", "aria-label": msg.datePickerPreviousMonth, children: /* @__PURE__ */ jsx28(Icon, { name: "chevron-left", size: 16 }) }),
1902
+ /* @__PURE__ */ jsx28(Heading2, { className: "pire-calendar-title" }),
1903
+ /* @__PURE__ */ jsx28(AriaButton9, { slot: "next", className: "pire-iconbtn", "data-size": "sm", "aria-label": msg.datePickerNextMonth, children: /* @__PURE__ */ jsx28(Icon, { name: "chevron-right", size: 16 }) })
1789
1904
  ] }),
1790
- /* @__PURE__ */ jsxs19(CalendarGrid, { className: "pire-calendar-grid", children: [
1791
- /* @__PURE__ */ jsx26(CalendarGridHeader, { children: (day) => /* @__PURE__ */ jsx26(CalendarHeaderCell, { children: day }) }),
1792
- /* @__PURE__ */ jsx26(CalendarGridBody, { children: (date) => /* @__PURE__ */ jsx26(CalendarCell, { date, className: "pire-calendar-cell" }) })
1905
+ /* @__PURE__ */ jsxs20(CalendarGrid, { className: "pire-calendar-grid", children: [
1906
+ /* @__PURE__ */ jsx28(CalendarGridHeader, { children: (day) => /* @__PURE__ */ jsx28(CalendarHeaderCell, { children: day }) }),
1907
+ /* @__PURE__ */ jsx28(CalendarGridBody, { children: (date) => /* @__PURE__ */ jsx28(CalendarCell, { date, className: "pire-calendar-cell" }) })
1793
1908
  ] })
1794
1909
  ] }) }) })
1795
1910
  ]
@@ -1801,7 +1916,7 @@ function DatePicker({
1801
1916
  import * as React16 from "react";
1802
1917
  import {
1803
1918
  DateRangePicker as AriaDateRangePicker,
1804
- Label as Label9,
1919
+ Label as Label10,
1805
1920
  Group as Group7,
1806
1921
  DateInput as DateInput2,
1807
1922
  DateSegment as DateSegment2,
@@ -1815,11 +1930,11 @@ import {
1815
1930
  CalendarGridBody as CalendarGridBody2,
1816
1931
  CalendarCell as CalendarCell2,
1817
1932
  Heading as Heading3,
1818
- Text as Text11,
1819
- FieldError as FieldError9,
1933
+ Text as Text12,
1934
+ FieldError as FieldError10,
1820
1935
  DateRangePickerStateContext
1821
1936
  } from "react-aria-components";
1822
- import { jsx as jsx27, jsxs as jsxs20 } from "react/jsx-runtime";
1937
+ import { jsx as jsx29, jsxs as jsxs21 } from "react/jsx-runtime";
1823
1938
  function coerceRange(range) {
1824
1939
  if (range === void 0) {
1825
1940
  return void 0;
@@ -1844,7 +1959,7 @@ function ClearButton3({ label }) {
1844
1959
  if (!state?.value?.start && !state?.value?.end) {
1845
1960
  return null;
1846
1961
  }
1847
- return /* @__PURE__ */ jsx27(
1962
+ return /* @__PURE__ */ jsx29(
1848
1963
  AriaButton10,
1849
1964
  {
1850
1965
  className: "pire-input-clear",
@@ -1893,7 +2008,7 @@ function DateRangePicker({
1893
2008
  }
1894
2009
  onChange(valueFormat === "iso" ? { start: next.start.toString(), end: next.end.toString() } : { start: next.start, end: next.end });
1895
2010
  };
1896
- return /* @__PURE__ */ jsxs20(
2011
+ return /* @__PURE__ */ jsxs21(
1897
2012
  AriaDateRangePicker,
1898
2013
  {
1899
2014
  className: cx("pire-field", className),
@@ -1909,11 +2024,11 @@ function DateRangePicker({
1909
2024
  ...rest,
1910
2025
  isInvalid: rest.isInvalid || tooLong || void 0,
1911
2026
  children: [
1912
- label ? /* @__PURE__ */ jsxs20(Label9, { className: "pire-field-label", children: [
2027
+ label ? /* @__PURE__ */ jsxs21(Label10, { className: "pire-field-label", children: [
1913
2028
  label,
1914
- rest.isRequired ? /* @__PURE__ */ jsx27("span", { className: "pire-field-req", "aria-hidden": "true", children: "*" }) : null
2029
+ rest.isRequired ? /* @__PURE__ */ jsx29("span", { className: "pire-field-req", "aria-hidden": "true", children: "*" }) : null
1915
2030
  ] }) : null,
1916
- /* @__PURE__ */ jsxs20(
2031
+ /* @__PURE__ */ jsxs21(
1917
2032
  Group7,
1918
2033
  {
1919
2034
  className: "pire-control pire-daterange-control",
@@ -1922,30 +2037,30 @@ function DateRangePicker({
1922
2037
  "data-invalid": rest.isInvalid || tooLong ? "true" : void 0,
1923
2038
  "data-readonly": rest.isReadOnly ? "true" : void 0,
1924
2039
  children: [
1925
- /* @__PURE__ */ jsx27(DateInput2, { slot: "start", className: "pire-datefield", children: (segment) => /* @__PURE__ */ jsx27(DateSegment2, { segment, className: "pire-datesegment" }) }),
1926
- /* @__PURE__ */ jsx27("span", { "aria-hidden": "true", className: "pire-daterange-dash", children: "\u2013" }),
1927
- /* @__PURE__ */ jsx27(DateInput2, { slot: "end", className: "pire-datefield", children: (segment) => /* @__PURE__ */ jsx27(DateSegment2, { segment, className: "pire-datesegment" }) }),
1928
- isClearable && !rest.isDisabled && !rest.isReadOnly ? /* @__PURE__ */ jsx27(ClearButton3, { label: clearLabel ?? msg.inputClear }) : null,
1929
- /* @__PURE__ */ jsx27(
2040
+ /* @__PURE__ */ jsx29(DateInput2, { slot: "start", className: "pire-datefield", children: (segment) => /* @__PURE__ */ jsx29(DateSegment2, { segment, className: "pire-datesegment" }) }),
2041
+ /* @__PURE__ */ jsx29("span", { "aria-hidden": "true", className: "pire-daterange-dash", children: "\u2013" }),
2042
+ /* @__PURE__ */ jsx29(DateInput2, { slot: "end", className: "pire-datefield", children: (segment) => /* @__PURE__ */ jsx29(DateSegment2, { segment, className: "pire-datesegment" }) }),
2043
+ isClearable && !rest.isDisabled && !rest.isReadOnly ? /* @__PURE__ */ jsx29(ClearButton3, { label: clearLabel ?? msg.inputClear }) : null,
2044
+ /* @__PURE__ */ jsx29(
1930
2045
  AriaButton10,
1931
2046
  {
1932
2047
  className: "pire-iconbtn",
1933
2048
  "data-size": "sm",
1934
2049
  "aria-label": msg.datePickerOpenCalendar,
1935
2050
  style: { width: 24, height: 24 },
1936
- children: /* @__PURE__ */ jsx27(Icon, { name: "calendar", size: 16 })
2051
+ children: /* @__PURE__ */ jsx29(Icon, { name: "calendar", size: 16 })
1937
2052
  }
1938
2053
  )
1939
2054
  ]
1940
2055
  }
1941
2056
  ),
1942
- description ? /* @__PURE__ */ jsx27(Text11, { slot: "description", className: "pire-field-hint", children: description }) : null,
1943
- /* @__PURE__ */ jsx27(FieldError9, { className: "pire-field-error", children: errorMessage }),
1944
- /* @__PURE__ */ jsx27(Popover5, { className: "pire-popover", children: /* @__PURE__ */ jsxs20(AriaDialog2, { className: "pire-daterange-dialog", children: [
2057
+ description ? /* @__PURE__ */ jsx29(Text12, { slot: "description", className: "pire-field-hint", children: description }) : null,
2058
+ /* @__PURE__ */ jsx29(FieldError10, { className: "pire-field-error", children: errorMessage }),
2059
+ /* @__PURE__ */ jsx29(Popover5, { className: "pire-popover", children: /* @__PURE__ */ jsxs21(AriaDialog2, { className: "pire-daterange-dialog", children: [
1945
2060
  presets?.length ? (
1946
2061
  // Before the calendar in the DOM, so keyboard users reach the shortcut without
1947
2062
  // arrowing through a month first.
1948
- /* @__PURE__ */ jsx27("div", { className: "pire-daterange-presets", role: "group", "aria-label": msg.dateRangePresetsLabel, children: presets.map((preset) => /* @__PURE__ */ jsx27(
2063
+ /* @__PURE__ */ jsx29("div", { className: "pire-daterange-presets", role: "group", "aria-label": msg.dateRangePresetsLabel, children: presets.map((preset) => /* @__PURE__ */ jsx29(
1949
2064
  AriaButton10,
1950
2065
  {
1951
2066
  className: "pire-daterange-preset",
@@ -1955,33 +2070,33 @@ function DateRangePicker({
1955
2070
  preset.id
1956
2071
  )) })
1957
2072
  ) : null,
1958
- /* @__PURE__ */ jsxs20(RangeCalendar, { className: "pire-calendar", children: [
1959
- /* @__PURE__ */ jsxs20("header", { className: "pire-calendar-head", children: [
1960
- /* @__PURE__ */ jsx27(
2073
+ /* @__PURE__ */ jsxs21(RangeCalendar, { className: "pire-calendar", children: [
2074
+ /* @__PURE__ */ jsxs21("header", { className: "pire-calendar-head", children: [
2075
+ /* @__PURE__ */ jsx29(
1961
2076
  AriaButton10,
1962
2077
  {
1963
2078
  slot: "previous",
1964
2079
  className: "pire-iconbtn",
1965
2080
  "data-size": "sm",
1966
2081
  "aria-label": msg.datePickerPreviousMonth,
1967
- children: /* @__PURE__ */ jsx27(Icon, { name: "chevron-left", size: 16 })
2082
+ children: /* @__PURE__ */ jsx29(Icon, { name: "chevron-left", size: 16 })
1968
2083
  }
1969
2084
  ),
1970
- /* @__PURE__ */ jsx27(Heading3, { className: "pire-calendar-title" }),
1971
- /* @__PURE__ */ jsx27(
2085
+ /* @__PURE__ */ jsx29(Heading3, { className: "pire-calendar-title" }),
2086
+ /* @__PURE__ */ jsx29(
1972
2087
  AriaButton10,
1973
2088
  {
1974
2089
  slot: "next",
1975
2090
  className: "pire-iconbtn",
1976
2091
  "data-size": "sm",
1977
2092
  "aria-label": msg.datePickerNextMonth,
1978
- children: /* @__PURE__ */ jsx27(Icon, { name: "chevron-right", size: 16 })
2093
+ children: /* @__PURE__ */ jsx29(Icon, { name: "chevron-right", size: 16 })
1979
2094
  }
1980
2095
  )
1981
2096
  ] }),
1982
- /* @__PURE__ */ jsxs20(CalendarGrid2, { className: "pire-calendar-grid", children: [
1983
- /* @__PURE__ */ jsx27(CalendarGridHeader2, { children: (day) => /* @__PURE__ */ jsx27(CalendarHeaderCell2, { children: day }) }),
1984
- /* @__PURE__ */ jsx27(CalendarGridBody2, { children: (date) => /* @__PURE__ */ jsx27(CalendarCell2, { date, className: "pire-calendar-cell" }) })
2097
+ /* @__PURE__ */ jsxs21(CalendarGrid2, { className: "pire-calendar-grid", children: [
2098
+ /* @__PURE__ */ jsx29(CalendarGridHeader2, { children: (day) => /* @__PURE__ */ jsx29(CalendarHeaderCell2, { children: day }) }),
2099
+ /* @__PURE__ */ jsx29(CalendarGridBody2, { children: (date) => /* @__PURE__ */ jsx29(CalendarCell2, { date, className: "pire-calendar-cell" }) })
1985
2100
  ] })
1986
2101
  ] })
1987
2102
  ] }) })
@@ -1991,26 +2106,26 @@ function DateRangePicker({
1991
2106
  }
1992
2107
 
1993
2108
  // src/components/forms/ValueHelpField.tsx
1994
- import * as React19 from "react";
2109
+ import * as React20 from "react";
1995
2110
 
1996
2111
  // src/components/patterns/ValueHelpDialog.tsx
1997
- import * as React18 from "react";
2112
+ import * as React19 from "react";
1998
2113
 
1999
2114
  // src/components/feedback/Dialog.tsx
2000
2115
  import * as React17 from "react";
2001
2116
  import { ModalOverlay, Modal, Dialog as AriaDialog3, Heading as Heading4 } from "react-aria-components";
2002
- import { jsx as jsx28, jsxs as jsxs21 } from "react/jsx-runtime";
2117
+ import { jsx as jsx30, jsxs as jsxs22 } from "react/jsx-runtime";
2003
2118
  function DialogTitle({ children, className }) {
2004
- return /* @__PURE__ */ jsx28(Heading4, { slot: "title", className: cx("pire-dialog-title", className), children });
2119
+ return /* @__PURE__ */ jsx30(Heading4, { slot: "title", className: cx("pire-dialog-title", className), children });
2005
2120
  }
2006
2121
  function DialogDescription({ children, className }) {
2007
- return /* @__PURE__ */ jsx28("p", { className: cx("pire-dialog-sub", className), style: { margin: 0 }, children });
2122
+ return /* @__PURE__ */ jsx30("p", { className: cx("pire-dialog-sub", className), style: { margin: 0 }, children });
2008
2123
  }
2009
2124
  function DialogBody({ children, className }) {
2010
- return /* @__PURE__ */ jsx28("div", { className: cx("pire-dialog-body", className), children });
2125
+ return /* @__PURE__ */ jsx30("div", { className: cx("pire-dialog-body", className), children });
2011
2126
  }
2012
2127
  function DialogActions({ children, className }) {
2013
- return /* @__PURE__ */ jsx28("footer", { className: cx("pire-dialog-foot", className), children });
2128
+ return /* @__PURE__ */ jsx30("footer", { className: cx("pire-dialog-foot", className), children });
2014
2129
  }
2015
2130
  function Dialog({
2016
2131
  isOpen,
@@ -2039,11 +2154,11 @@ function Dialog({
2039
2154
  const actionsSlot = slotOf(DialogActions);
2040
2155
  const slots = [titleSlot, descriptionSlot, bodySlot, actionsSlot];
2041
2156
  const loose = parts.filter((node) => !slots.includes(node));
2042
- const heading = titleSlot ?? (title ? /* @__PURE__ */ jsx28(Heading4, { slot: "title", className: "pire-dialog-title", children: title }) : null);
2043
- const description = descriptionSlot ?? (subtitle ? /* @__PURE__ */ jsx28("p", { className: "pire-dialog-sub", style: { margin: 0 }, children: subtitle }) : null);
2044
- const actions = actionsSlot ?? (footer ? /* @__PURE__ */ jsx28("footer", { className: "pire-dialog-foot", children: footer }) : null);
2045
- const body = bodySlot ?? (loose.length ? /* @__PURE__ */ jsx28("div", { className: "pire-dialog-body", children: loose }) : null);
2046
- return /* @__PURE__ */ jsx28(
2157
+ const heading = titleSlot ?? (title ? /* @__PURE__ */ jsx30(Heading4, { slot: "title", className: "pire-dialog-title", children: title }) : null);
2158
+ const description = descriptionSlot ?? (subtitle ? /* @__PURE__ */ jsx30("p", { className: "pire-dialog-sub", style: { margin: 0 }, children: subtitle }) : null);
2159
+ const actions = actionsSlot ?? (footer ? /* @__PURE__ */ jsx30("footer", { className: "pire-dialog-foot", children: footer }) : null);
2160
+ const body = bodySlot ?? (loose.length ? /* @__PURE__ */ jsx30("div", { className: "pire-dialog-body", children: loose }) : null);
2161
+ return /* @__PURE__ */ jsx30(
2047
2162
  ModalOverlay,
2048
2163
  {
2049
2164
  className: "pire-modal-overlay",
@@ -2052,13 +2167,13 @@ function Dialog({
2052
2167
  onOpenChange: (o) => {
2053
2168
  if (!o) close();
2054
2169
  },
2055
- children: /* @__PURE__ */ jsx28(Modal, { className: cx("pire-modal", className), "data-size": size, style, children: /* @__PURE__ */ jsxs21(AriaDialog3, { className: "pire-dialog", children: [
2056
- heading || description ? /* @__PURE__ */ jsxs21("header", { className: "pire-dialog-head", children: [
2057
- /* @__PURE__ */ jsxs21("div", { style: { flex: 1, minWidth: 0 }, children: [
2170
+ children: /* @__PURE__ */ jsx30(Modal, { className: cx("pire-modal", className), "data-size": size, style, children: /* @__PURE__ */ jsxs22(AriaDialog3, { className: "pire-dialog", children: [
2171
+ heading || description ? /* @__PURE__ */ jsxs22("header", { className: "pire-dialog-head", children: [
2172
+ /* @__PURE__ */ jsxs22("div", { style: { flex: 1, minWidth: 0 }, children: [
2058
2173
  heading,
2059
2174
  description
2060
2175
  ] }),
2061
- showClose ? /* @__PURE__ */ jsx28(IconButton, { icon: "x", label: msg.dialogClose, size: "sm", onPress: close }) : null
2176
+ showClose ? /* @__PURE__ */ jsx30(IconButton, { icon: "x", label: msg.dialogClose, size: "sm", onPress: close }) : null
2062
2177
  ] }) : null,
2063
2178
  body,
2064
2179
  actions
@@ -2068,6 +2183,7 @@ function Dialog({
2068
2183
  }
2069
2184
 
2070
2185
  // src/components/data/DataTable.tsx
2186
+ import * as React18 from "react";
2071
2187
  import {
2072
2188
  Table,
2073
2189
  TableHeader,
@@ -2079,9 +2195,9 @@ import {
2079
2195
  } from "react-aria-components";
2080
2196
 
2081
2197
  // src/components/feedback/Skeleton.tsx
2082
- import { jsx as jsx29 } from "react/jsx-runtime";
2198
+ import { jsx as jsx31 } from "react/jsx-runtime";
2083
2199
  function Skeleton({ shape = "text", width, height, className, style, ...rest }) {
2084
- return /* @__PURE__ */ jsx29(
2200
+ return /* @__PURE__ */ jsx31(
2085
2201
  "div",
2086
2202
  {
2087
2203
  className: cx("pire-skeleton", className),
@@ -2095,7 +2211,7 @@ function Skeleton({ shape = "text", width, height, className, style, ...rest })
2095
2211
  var BAR_WIDTHS = ["72%", "54%", "86%", "63%"];
2096
2212
  function SkeletonTableRow({ columns, density = "regular", className, style, ...rest }) {
2097
2213
  const cells = typeof columns === "number" ? Array.from({ length: columns }, () => ({})) : columns;
2098
- return /* @__PURE__ */ jsx29(
2214
+ return /* @__PURE__ */ jsx31(
2099
2215
  "div",
2100
2216
  {
2101
2217
  className: cx("pire-skeleton-row", className),
@@ -2107,13 +2223,13 @@ function SkeletonTableRow({ columns, density = "regular", className, style, ...r
2107
2223
  const align = c.numeric ? "right" : c.align ?? "left";
2108
2224
  return (
2109
2225
  // biome-ignore lint/suspicious/noArrayIndexKey: columns are positional and never reordered.
2110
- /* @__PURE__ */ jsx29(
2226
+ /* @__PURE__ */ jsx31(
2111
2227
  "div",
2112
2228
  {
2113
2229
  className: "pire-skeleton-cell",
2114
2230
  "data-align": align,
2115
2231
  style: { width: c.width, flex: c.width ? "0 0 auto" : void 0 },
2116
- children: /* @__PURE__ */ jsx29(Skeleton, { width: BAR_WIDTHS[i % BAR_WIDTHS.length] })
2232
+ children: /* @__PURE__ */ jsx31(Skeleton, { width: BAR_WIDTHS[i % BAR_WIDTHS.length] })
2117
2233
  },
2118
2234
  i
2119
2235
  )
@@ -2124,7 +2240,15 @@ function SkeletonTableRow({ columns, density = "regular", className, style, ...r
2124
2240
  }
2125
2241
 
2126
2242
  // src/components/data/DataTable.tsx
2127
- import { jsx as jsx30, jsxs as jsxs22 } from "react/jsx-runtime";
2243
+ import { jsx as jsx32, jsxs as jsxs23 } from "react/jsx-runtime";
2244
+ var IS_DEV2 = process.env.NODE_ENV !== "production";
2245
+ var warned2 = /* @__PURE__ */ new Set();
2246
+ function warnOnce2(key, message) {
2247
+ if (warned2.has(key)) return;
2248
+ warned2.add(key);
2249
+ console.warn(`[pire] ${message}`);
2250
+ }
2251
+ var CHECKBOX_W = 44;
2128
2252
  function DataTable({
2129
2253
  columns,
2130
2254
  rows,
@@ -2132,6 +2256,7 @@ function DataTable({
2132
2256
  selectable,
2133
2257
  selected,
2134
2258
  onSelectionChange,
2259
+ hideSelectAll,
2135
2260
  sort,
2136
2261
  onSortChange,
2137
2262
  onRowAction,
@@ -2151,14 +2276,53 @@ function DataTable({
2151
2276
  const msg = usePireMessages();
2152
2277
  const selectionMode = selectable === true || selectable === "multiple" ? "multiple" : selectable === "single" ? "single" : "none";
2153
2278
  const hasCheckboxColumn = selectionMode === "multiple";
2279
+ const pinnedGeometry = React18.useMemo(() => {
2280
+ const geometry = /* @__PURE__ */ new Map();
2281
+ let x = hasCheckboxColumn ? CHECKBOX_W : 0;
2282
+ let broke = null;
2283
+ for (const column of columns) {
2284
+ if (!column.pinned) {
2285
+ broke = "unpinned";
2286
+ break;
2287
+ }
2288
+ if (typeof column.width !== "number") {
2289
+ if (IS_DEV2) warnOnce2(
2290
+ `pin-width:${column.key}`,
2291
+ `DataTable column "${column.key}" is pinned but has no numeric width, so its offset cannot be computed. It will scroll.`
2292
+ );
2293
+ broke = "width";
2294
+ break;
2295
+ }
2296
+ geometry.set(column.key, { left: x, width: column.width });
2297
+ x += column.width;
2298
+ }
2299
+ if (IS_DEV2 && broke === "unpinned") {
2300
+ const stranded = columns.slice(geometry.size).find((c) => c.pinned);
2301
+ if (stranded) {
2302
+ warnOnce2(
2303
+ `pin-gap:${stranded.key}`,
2304
+ `DataTable column "${stranded.key}" is pinned but does not sit in the leading run, so it will scroll. Move it before the first unpinned column.`
2305
+ );
2306
+ }
2307
+ }
2308
+ return geometry;
2309
+ }, [columns, hasCheckboxColumn]);
2310
+ const hasPinned = pinnedGeometry.size > 0;
2311
+ const lastPinnedKey = hasPinned ? [...pinnedGeometry.keys()][pinnedGeometry.size - 1] : void 0;
2154
2312
  const sortDescriptor = sort ? { column: sort.key, direction: sort.dir === "asc" ? "ascending" : "descending" } : void 0;
2155
2313
  const handleSelection = (keys) => {
2156
- if (keys === "all") return onSelectionChange?.(rows.map((r) => r.id));
2314
+ if (keys === "all") {
2315
+ const inCollection = new Set(rows.map((r) => r.id));
2316
+ return onSelectionChange?.([
2317
+ ...rows.map((r) => r.id),
2318
+ ...(selected ?? []).filter((id) => !inCollection.has(id))
2319
+ ]);
2320
+ }
2157
2321
  onSelectionChange?.([...keys]);
2158
2322
  };
2159
2323
  const skeletonRows = loadingRowCount ?? (rows.length || 5);
2160
2324
  const skeletonColumns = [
2161
- ...hasCheckboxColumn ? [{ width: 44 }] : [],
2325
+ ...hasCheckboxColumn ? [{ width: CHECKBOX_W }] : [],
2162
2326
  ...columns.map((c) => ({ width: c.width, align: c.align, numeric: c.numeric }))
2163
2327
  ];
2164
2328
  const body = isLoading ? [] : rows;
@@ -2167,19 +2331,30 @@ function DataTable({
2167
2331
  const expanded = new Set((expandedIds ?? []).map(String));
2168
2332
  const spanAll = columns.length + (hasCheckboxColumn ? 1 : 0);
2169
2333
  const expandedKey = (id) => `${id}::__pire_expanded__`;
2170
- return /* @__PURE__ */ jsx30(
2334
+ const pinProps = (key) => {
2335
+ if (!hasPinned) return {};
2336
+ const box = key === null ? { left: 0, width: CHECKBOX_W } : pinnedGeometry.get(key);
2337
+ if (!box) return {};
2338
+ return {
2339
+ "data-pinned": "true",
2340
+ "data-pinned-last": key !== null && key === lastPinnedKey ? "true" : void 0,
2341
+ style: { left: box.left, width: box.width, minWidth: box.width, maxWidth: box.width }
2342
+ };
2343
+ };
2344
+ return /* @__PURE__ */ jsx32(
2171
2345
  "div",
2172
2346
  {
2173
2347
  className: cx("pire-table-wrap", className),
2174
2348
  style,
2175
2349
  "data-loading": isLoading ? "true" : void 0,
2176
2350
  "aria-busy": isLoading ? "true" : void 0,
2177
- children: /* @__PURE__ */ jsxs22(
2351
+ children: /* @__PURE__ */ jsxs23(
2178
2352
  Table,
2179
2353
  {
2180
2354
  className: "pire-table",
2181
2355
  "data-density": density,
2182
2356
  "data-sticky": String(stickyHeader),
2357
+ "data-pinned": hasPinned ? "true" : void 0,
2183
2358
  "aria-label": rest["aria-label"],
2184
2359
  disabledKeys: disabledKeys.length ? new Set(disabledKeys) : void 0,
2185
2360
  selectionMode,
@@ -2192,78 +2367,95 @@ function DataTable({
2192
2367
  if (row) onRowAction(row);
2193
2368
  } : void 0,
2194
2369
  children: [
2195
- /* @__PURE__ */ jsxs22(TableHeader, { className: "pire-thead-row", children: [
2196
- hasCheckboxColumn ? /* @__PURE__ */ jsx30(Column, { className: "pire-th", width: 44, children: /* @__PURE__ */ jsx30(Checkbox, { slot: "selection", "aria-label": msg.dataTableSelectAll }) }) : null,
2197
- columns.map((c, i) => /* @__PURE__ */ jsx30(
2198
- Column,
2199
- {
2200
- id: c.key,
2201
- className: "pire-th",
2202
- isRowHeader: i === 0 && !hasCheckboxColumn,
2203
- allowsSorting: c.sortable,
2204
- width: c.width,
2205
- "data-align": c.numeric || c.align === "right" ? "right" : c.align,
2206
- "data-allows-sorting": c.sortable ? "true" : void 0,
2207
- children: /* @__PURE__ */ jsxs22("span", { className: c.hideLabel ? "pire-sr-only" : "pire-th-inner", children: [
2208
- c.label,
2209
- c.sortable ? /* @__PURE__ */ jsx30(
2210
- Icon,
2211
- {
2212
- size: 12,
2213
- name: sort?.key === c.key ? sort.dir === "asc" ? "arrow-up" : "arrow-down" : "chevrons-up-down",
2214
- style: { color: sort?.key === c.key ? "var(--accent-subtle-fg)" : "var(--text-tertiary)" }
2215
- }
2216
- ) : null
2217
- ] })
2218
- },
2219
- c.key
2370
+ /* @__PURE__ */ jsxs23(TableHeader, { className: "pire-thead-row", children: [
2371
+ hasCheckboxColumn ? /* @__PURE__ */ jsx32(Column, { className: "pire-th", ...pinProps(null), children: hideSelectAll ? /* @__PURE__ */ jsx32("span", { className: "pire-sr-only", children: msg.dataTableSelectionColumn }) : /* @__PURE__ */ jsx32(Checkbox, { slot: "selection", "aria-label": msg.dataTableSelectAll }) }) : null,
2372
+ columns.map((c, i) => (
2373
+ // The checkbox column is never the row header — a selection control does not identify
2374
+ // the record — so the first *data* column carries it regardless of whether a checkbox
2375
+ // column precedes it. Conditioning this on `hasCheckboxColumn` left every selectable
2376
+ // table with no row header at all: invisible on first paint, and a hard crash from
2377
+ // React Aria's own "table must have a row header" invariant the moment `rows` changes
2378
+ // under it (search, sort, a paginated load).
2379
+ /* @__PURE__ */ jsx32(
2380
+ Column,
2381
+ {
2382
+ id: c.key,
2383
+ className: "pire-th",
2384
+ isRowHeader: i === 0,
2385
+ allowsSorting: c.sortable,
2386
+ "data-align": c.numeric || c.align === "right" ? "right" : c.align,
2387
+ "data-allows-sorting": c.sortable ? "true" : void 0,
2388
+ ...pinProps(c.key),
2389
+ children: /* @__PURE__ */ jsxs23("span", { className: c.hideLabel ? "pire-sr-only" : "pire-th-inner", children: [
2390
+ c.label,
2391
+ c.sortable ? /* @__PURE__ */ jsx32(
2392
+ Icon,
2393
+ {
2394
+ size: 12,
2395
+ name: sort?.key === c.key ? sort.dir === "asc" ? "arrow-up" : "arrow-down" : "chevrons-up-down",
2396
+ style: { color: sort?.key === c.key ? "var(--accent-subtle-fg)" : "var(--text-tertiary)" }
2397
+ }
2398
+ ) : null
2399
+ ] })
2400
+ },
2401
+ c.key
2402
+ )
2220
2403
  ))
2221
2404
  ] }),
2222
- /* @__PURE__ */ jsx30(TableBody, { renderEmptyState: () => isLoading ? /* @__PURE__ */ jsxs22("div", { className: "pire-table-loading", role: "status", "aria-live": "polite", children: [
2223
- /* @__PURE__ */ jsx30("span", { className: "pire-sr-only", children: loadingLabel ?? msg.dataTableLoading }),
2405
+ /* @__PURE__ */ jsx32(TableBody, { renderEmptyState: () => isLoading ? /* @__PURE__ */ jsxs23("div", { className: "pire-table-loading", role: "status", "aria-live": "polite", children: [
2406
+ /* @__PURE__ */ jsx32("span", { className: "pire-sr-only", children: loadingLabel ?? msg.dataTableLoading }),
2224
2407
  Array.from({ length: skeletonRows }, (_, i) => (
2225
2408
  // biome-ignore lint/suspicious/noArrayIndexKey: placeholder rows are positional.
2226
- /* @__PURE__ */ jsx30(SkeletonTableRow, { columns: skeletonColumns, density }, i)
2409
+ /* @__PURE__ */ jsx32(SkeletonTableRow, { columns: skeletonColumns, density }, i)
2227
2410
  ))
2228
- ] }) : /* @__PURE__ */ jsx30("div", { className: "pire-table-empty", children: emptyLabel ?? msg.dataTableEmpty }), children: body.flatMap((row) => {
2411
+ ] }) : /* @__PURE__ */ jsx32("div", { className: "pire-table-empty", children: emptyLabel ?? msg.dataTableEmpty }), children: body.flatMap((row) => {
2229
2412
  const rowIsDisabled = presentation.get(row.id)?.isDisabled;
2230
- const record = /* @__PURE__ */ jsxs22(
2413
+ const record = /* @__PURE__ */ jsxs23(
2231
2414
  Row,
2232
2415
  {
2233
2416
  id: row.id,
2234
2417
  className: cx("pire-tr", presentation.get(row.id)?.className),
2235
2418
  "data-pressable": onRowAction && !rowIsDisabled ? "true" : void 0,
2236
2419
  children: [
2237
- hasCheckboxColumn ? /* @__PURE__ */ jsx30(Cell, { className: "pire-td", children: /* @__PURE__ */ jsx30(Checkbox, { slot: "selection", "aria-label": msg.dataTableSelectRow }) }) : null,
2238
- columns.map((c) => /* @__PURE__ */ jsx30(
2239
- Cell,
2240
- {
2241
- className: "pire-td",
2242
- "data-numeric": c.numeric ? "true" : void 0,
2243
- style: { textAlign: c.align && !c.numeric ? c.align : void 0 },
2244
- children: c.render ? c.render(row) : row[c.key]
2245
- },
2246
- c.key
2247
- ))
2420
+ hasCheckboxColumn ? /* @__PURE__ */ jsx32(Cell, { className: "pire-td", ...pinProps(null), children: /* @__PURE__ */ jsx32(Checkbox, { slot: "selection", "aria-label": msg.dataTableSelectRow }) }) : null,
2421
+ columns.map((c) => {
2422
+ const pin = pinProps(c.key);
2423
+ return /* @__PURE__ */ jsx32(
2424
+ Cell,
2425
+ {
2426
+ className: "pire-td",
2427
+ "data-numeric": c.numeric ? "true" : void 0,
2428
+ "data-tone": c.tone?.(row) ?? void 0,
2429
+ ...pin,
2430
+ style: { ...pin.style, textAlign: c.align && !c.numeric ? c.align : void 0 },
2431
+ children: c.render ? c.render(row) : row[c.key]
2432
+ },
2433
+ c.key
2434
+ );
2435
+ })
2248
2436
  ]
2249
2437
  },
2250
2438
  row.id
2251
2439
  );
2252
2440
  if (!renderExpanded || !expanded.has(String(row.id))) return [record];
2253
- return [record, /* @__PURE__ */ jsx30(Row, { id: expandedKey(row.id), className: "pire-tr-expanded", children: /* @__PURE__ */ jsx30(Cell, { className: "pire-td-expanded", colSpan: spanAll, children: renderExpanded(row) }) }, expandedKey(row.id))];
2441
+ return [record, /* @__PURE__ */ jsx32(Row, { id: expandedKey(row.id), className: "pire-tr-expanded", children: /* @__PURE__ */ jsx32(Cell, { className: "pire-td-expanded", colSpan: spanAll, children: renderExpanded(row) }) }, expandedKey(row.id))];
2254
2442
  }) }),
2255
- footer && !isLoading ? /* @__PURE__ */ jsx30(TableFooter, { className: "pire-tfoot", children: /* @__PURE__ */ jsxs22(Row, { id: "__pire_footer__", className: "pire-tr-footer", children: [
2256
- hasCheckboxColumn ? /* @__PURE__ */ jsx30(Cell, { className: "pire-tf" }) : null,
2257
- columns.map((c, i) => /* @__PURE__ */ jsx30(
2258
- Cell,
2259
- {
2260
- className: "pire-tf",
2261
- "data-numeric": c.numeric ? "true" : void 0,
2262
- style: { textAlign: c.align && !c.numeric ? c.align : void 0 },
2263
- children: footer[c.key] ?? (i === 0 && !hasCheckboxColumn ? /* @__PURE__ */ jsx30("span", { className: "pire-sr-only", children: msg.dataTableSummaryRow }) : null)
2264
- },
2265
- c.key
2266
- ))
2443
+ footer && !isLoading ? /* @__PURE__ */ jsx32(TableFooter, { className: "pire-tfoot", children: /* @__PURE__ */ jsxs23(Row, { id: "__pire_footer__", className: "pire-tr-footer", children: [
2444
+ hasCheckboxColumn ? /* @__PURE__ */ jsx32(Cell, { className: "pire-tf", ...pinProps(null) }) : null,
2445
+ columns.map((c, i) => {
2446
+ const pin = pinProps(c.key);
2447
+ return /* @__PURE__ */ jsx32(
2448
+ Cell,
2449
+ {
2450
+ className: "pire-tf",
2451
+ "data-numeric": c.numeric ? "true" : void 0,
2452
+ ...pin,
2453
+ style: { ...pin.style, textAlign: c.align && !c.numeric ? c.align : void 0 },
2454
+ children: footer[c.key] ?? (i === 0 ? /* @__PURE__ */ jsx32("span", { className: "pire-sr-only", children: msg.dataTableSummaryRow }) : null)
2455
+ },
2456
+ c.key
2457
+ );
2458
+ })
2267
2459
  ] }) }) : null
2268
2460
  ]
2269
2461
  }
@@ -2273,7 +2465,7 @@ function DataTable({
2273
2465
  }
2274
2466
 
2275
2467
  // src/components/patterns/ValueHelpDialog.tsx
2276
- import { jsx as jsx31, jsxs as jsxs23 } from "react/jsx-runtime";
2468
+ import { Fragment as Fragment2, jsx as jsx33, jsxs as jsxs24 } from "react/jsx-runtime";
2277
2469
  function ValueHelpDialog({
2278
2470
  isOpen,
2279
2471
  title,
@@ -2286,14 +2478,19 @@ function ValueHelpDialog({
2286
2478
  isLoading,
2287
2479
  onLoadMore,
2288
2480
  onSelect,
2289
- onClose
2481
+ onClose,
2482
+ selectionMode = "single",
2483
+ selectedKeys,
2484
+ onSelectionChange,
2485
+ onConfirm
2290
2486
  }) {
2291
2487
  const msg = usePireMessages();
2292
- const [query, setQuery] = React18.useState("");
2293
- React18.useEffect(() => {
2488
+ const [query, setQuery] = React19.useState("");
2489
+ React19.useEffect(() => {
2294
2490
  if (isOpen) setQuery("");
2295
2491
  }, [isOpen]);
2296
- const filtered = React18.useMemo(() => {
2492
+ const isMultiple = selectionMode === "multiple";
2493
+ const filtered = React19.useMemo(() => {
2297
2494
  if (isFilteredExternally) return rows;
2298
2495
  const q = query.trim().toLowerCase();
2299
2496
  if (!q) return rows;
@@ -2303,16 +2500,22 @@ function ValueHelpDialog({
2303
2500
  setQuery(value);
2304
2501
  onSearch?.(value);
2305
2502
  };
2306
- return /* @__PURE__ */ jsx31(
2503
+ return /* @__PURE__ */ jsx33(
2307
2504
  Dialog,
2308
2505
  {
2309
2506
  isOpen,
2310
2507
  size: "lg",
2311
2508
  title: title ?? msg.valueHelpDialogTitle,
2312
2509
  onClose,
2313
- footer: /* @__PURE__ */ jsx31(Button, { variant: "tertiary", onPress: onClose, children: msg.valueHelpDialogCancel }),
2314
- children: /* @__PURE__ */ jsxs23("div", { style: { display: "flex", flexDirection: "column", gap: "var(--sp-3)" }, children: [
2315
- /* @__PURE__ */ jsx31(
2510
+ footer: /* @__PURE__ */ jsxs24(Fragment2, { children: [
2511
+ /* @__PURE__ */ jsx33(Button, { variant: "tertiary", onPress: onClose, children: msg.valueHelpDialogCancel }),
2512
+ isMultiple ? /* @__PURE__ */ jsx33(Button, { variant: "primary", onPress: () => {
2513
+ onConfirm?.(selectedKeys ?? []);
2514
+ onClose?.();
2515
+ }, children: msg.valueHelpConfirm }) : null
2516
+ ] }),
2517
+ children: /* @__PURE__ */ jsxs24("div", { style: { display: "flex", flexDirection: "column", gap: "var(--sp-3)" }, children: [
2518
+ /* @__PURE__ */ jsx33(
2316
2519
  Input,
2317
2520
  {
2318
2521
  "aria-label": msg.valueHelpDialogSearch,
@@ -2325,10 +2528,15 @@ function ValueHelpDialog({
2325
2528
  autoFocus: true
2326
2529
  }
2327
2530
  ),
2328
- /* @__PURE__ */ jsx31("div", { onScroll: onLoadMore ? (event) => {
2531
+ isMultiple ? /* @__PURE__ */ jsxs24("div", { className: "pire-valuehelp-selectionbar", children: [
2532
+ /* @__PURE__ */ jsx33(Button, { size: "sm", variant: "tertiary", onPress: () => onSelectionChange?.(rows.map((r) => r.id)), children: msg.valueHelpSelectAllCount.replace("{count}", String(rows.length)) }),
2533
+ /* @__PURE__ */ jsx33(Button, { size: "sm", variant: "tertiary", onPress: () => onSelectionChange?.([]), children: msg.valueHelpClearSelection }),
2534
+ /* @__PURE__ */ jsx33("span", { className: "pire-valuehelp-count", children: msg.valueHelpSelectedCount.replace("{count}", String(selectedKeys?.length ?? 0)) })
2535
+ ] }) : null,
2536
+ /* @__PURE__ */ jsx33("div", { onScroll: onLoadMore ? (event) => {
2329
2537
  const el = event.currentTarget;
2330
2538
  if (el.scrollHeight - el.scrollTop - el.clientHeight < 64) onLoadMore();
2331
- } : void 0, style: { overflow: "auto", maxHeight: "48vh" }, children: /* @__PURE__ */ jsx31(
2539
+ } : void 0, style: { overflow: "auto", maxHeight: "48vh" }, children: /* @__PURE__ */ jsx33(
2332
2540
  DataTable,
2333
2541
  {
2334
2542
  "aria-label": typeof title === "string" ? title : msg.valueHelpDialogTitle,
@@ -2337,7 +2545,11 @@ function ValueHelpDialog({
2337
2545
  rows: filtered,
2338
2546
  isLoading,
2339
2547
  emptyLabel: emptyLabel ?? msg.valueHelpDialogEmpty,
2340
- onRowAction: (row) => {
2548
+ selectable: isMultiple ? "multiple" : void 0,
2549
+ hideSelectAll: isMultiple,
2550
+ selected: isMultiple ? selectedKeys : void 0,
2551
+ onSelectionChange: isMultiple ? onSelectionChange : void 0,
2552
+ onRowAction: isMultiple ? void 0 : (row) => {
2341
2553
  onSelect?.(row);
2342
2554
  onClose?.();
2343
2555
  }
@@ -2349,7 +2561,7 @@ function ValueHelpDialog({
2349
2561
  }
2350
2562
 
2351
2563
  // src/components/forms/ValueHelpField.tsx
2352
- import { jsx as jsx32, jsxs as jsxs24 } from "react/jsx-runtime";
2564
+ import { jsx as jsx34, jsxs as jsxs25 } from "react/jsx-runtime";
2353
2565
  var defaultFormat = (row) => [row.id, row.name ?? row.label ?? row.text].filter(Boolean).join(" \u2014 ");
2354
2566
  function ValueHelpField({
2355
2567
  label,
@@ -2375,9 +2587,9 @@ function ValueHelpField({
2375
2587
  style
2376
2588
  }) {
2377
2589
  const msg = usePireMessages();
2378
- const [open, setOpen] = React19.useState(false);
2379
- return /* @__PURE__ */ jsxs24("div", { className: cx(className), style, children: [
2380
- /* @__PURE__ */ jsx32(
2590
+ const [open, setOpen] = React20.useState(false);
2591
+ return /* @__PURE__ */ jsxs25("div", { className: cx(className), style, children: [
2592
+ /* @__PURE__ */ jsx34(
2381
2593
  Input,
2382
2594
  {
2383
2595
  label,
@@ -2389,8 +2601,8 @@ function ValueHelpField({
2389
2601
  placeholder: placeholder ?? msg.valueHelpFieldPlaceholder,
2390
2602
  description,
2391
2603
  errorMessage,
2392
- suffix: /* @__PURE__ */ jsxs24("span", { className: "pire-valuehelp-actions", children: [
2393
- allowsClear && value ? /* @__PURE__ */ jsx32(
2604
+ suffix: /* @__PURE__ */ jsxs25("span", { className: "pire-valuehelp-actions", children: [
2605
+ allowsClear && value ? /* @__PURE__ */ jsx34(
2394
2606
  IconButton,
2395
2607
  {
2396
2608
  icon: "x",
@@ -2399,7 +2611,7 @@ function ValueHelpField({
2399
2611
  onPress: () => onChange?.(null)
2400
2612
  }
2401
2613
  ) : null,
2402
- /* @__PURE__ */ jsx32(
2614
+ /* @__PURE__ */ jsx34(
2403
2615
  IconButton,
2404
2616
  {
2405
2617
  icon: "search",
@@ -2411,7 +2623,7 @@ function ValueHelpField({
2411
2623
  ] })
2412
2624
  }
2413
2625
  ),
2414
- /* @__PURE__ */ jsx32(
2626
+ /* @__PURE__ */ jsx34(
2415
2627
  ValueHelpDialog,
2416
2628
  {
2417
2629
  isOpen: open,
@@ -2431,12 +2643,12 @@ function ValueHelpField({
2431
2643
  }
2432
2644
 
2433
2645
  // src/components/forms/FileUpload.tsx
2434
- import * as React20 from "react";
2435
- import { FileTrigger, Text as Text12 } from "react-aria-components";
2646
+ import * as React21 from "react";
2647
+ import { FileTrigger, Text as Text13 } from "react-aria-components";
2436
2648
 
2437
2649
  // src/components/feedback/ProgressBar.tsx
2438
- import { ProgressBar as AriaProgressBar, Label as Label10 } from "react-aria-components";
2439
- import { Fragment as Fragment2, jsx as jsx33, jsxs as jsxs25 } from "react/jsx-runtime";
2650
+ import { ProgressBar as AriaProgressBar, Label as Label11 } from "react-aria-components";
2651
+ import { Fragment as Fragment3, jsx as jsx35, jsxs as jsxs26 } from "react/jsx-runtime";
2440
2652
  function ProgressBar({
2441
2653
  value = 0,
2442
2654
  minValue = 0,
@@ -2449,7 +2661,7 @@ function ProgressBar({
2449
2661
  className,
2450
2662
  style
2451
2663
  }) {
2452
- return /* @__PURE__ */ jsx33(
2664
+ return /* @__PURE__ */ jsx35(
2453
2665
  AriaProgressBar,
2454
2666
  {
2455
2667
  className: cx("pire-progress", className),
@@ -2460,19 +2672,19 @@ function ProgressBar({
2460
2672
  maxValue,
2461
2673
  isIndeterminate,
2462
2674
  style,
2463
- children: ({ percentage, valueText }) => /* @__PURE__ */ jsxs25(Fragment2, { children: [
2464
- label || showValue ? /* @__PURE__ */ jsxs25("div", { className: "pire-progress-head", children: [
2465
- label ? /* @__PURE__ */ jsx33(Label10, { children: label }) : /* @__PURE__ */ jsx33("span", {}),
2466
- showValue && !isIndeterminate ? /* @__PURE__ */ jsx33("span", { className: "pire-numeric", children: valueText }) : null
2675
+ children: ({ percentage, valueText }) => /* @__PURE__ */ jsxs26(Fragment3, { children: [
2676
+ label || showValue ? /* @__PURE__ */ jsxs26("div", { className: "pire-progress-head", children: [
2677
+ label ? /* @__PURE__ */ jsx35(Label11, { children: label }) : /* @__PURE__ */ jsx35("span", {}),
2678
+ showValue && !isIndeterminate ? /* @__PURE__ */ jsx35("span", { className: "pire-numeric", children: valueText }) : null
2467
2679
  ] }) : null,
2468
- /* @__PURE__ */ jsx33("div", { className: "pire-progress-track", children: /* @__PURE__ */ jsx33("div", { className: "pire-progress-fill", style: { width: `${isIndeterminate ? 40 : percentage}%` } }) })
2680
+ /* @__PURE__ */ jsx35("div", { className: "pire-progress-track", children: /* @__PURE__ */ jsx35("div", { className: "pire-progress-fill", style: { width: `${isIndeterminate ? 40 : percentage}%` } }) })
2469
2681
  ] })
2470
2682
  }
2471
2683
  );
2472
2684
  }
2473
2685
 
2474
2686
  // src/components/forms/FileUpload.tsx
2475
- import { jsx as jsx34, jsxs as jsxs26 } from "react/jsx-runtime";
2687
+ import { jsx as jsx36, jsxs as jsxs27 } from "react/jsx-runtime";
2476
2688
  var isImage = (file) => file.type.startsWith("image/");
2477
2689
  function formatFileSize(bytes) {
2478
2690
  if (bytes < 1024) return `${bytes} B`;
@@ -2522,10 +2734,10 @@ function FileUpload({
2522
2734
  ...rest
2523
2735
  }) {
2524
2736
  const msg = usePireMessages();
2525
- const [uncontrolled, setUncontrolled] = React20.useState(defaultValue ?? []);
2737
+ const [uncontrolled, setUncontrolled] = React21.useState(defaultValue ?? []);
2526
2738
  const files = value ?? uncontrolled;
2527
- const created = React20.useRef([]);
2528
- React20.useEffect(() => () => {
2739
+ const created = React21.useRef([]);
2740
+ React21.useEffect(() => () => {
2529
2741
  for (const url of created.current) URL.revokeObjectURL(url);
2530
2742
  }, []);
2531
2743
  const commit = (next) => {
@@ -2545,7 +2757,7 @@ function FileUpload({
2545
2757
  commit(allowsMultiple ? [...files, ...wrapped] : wrapped.slice(0, 1));
2546
2758
  };
2547
2759
  const remove = (target) => commit(files.filter((f) => f.file !== target));
2548
- return /* @__PURE__ */ jsxs26(
2760
+ return /* @__PURE__ */ jsxs27(
2549
2761
  "div",
2550
2762
  {
2551
2763
  className: cx("pire-field", "pire-fileupload", className),
@@ -2554,24 +2766,24 @@ function FileUpload({
2554
2766
  "data-invalid": isInvalid ? "true" : void 0,
2555
2767
  ...rest,
2556
2768
  children: [
2557
- label ? /* @__PURE__ */ jsxs26("span", { className: "pire-field-label", children: [
2769
+ label ? /* @__PURE__ */ jsxs27("span", { className: "pire-field-label", children: [
2558
2770
  label,
2559
- isRequired ? /* @__PURE__ */ jsx34("span", { className: "pire-field-req", "aria-hidden": "true", children: "*" }) : null
2771
+ isRequired ? /* @__PURE__ */ jsx36("span", { className: "pire-field-req", "aria-hidden": "true", children: "*" }) : null
2560
2772
  ] }) : null,
2561
- /* @__PURE__ */ jsx34(
2773
+ /* @__PURE__ */ jsx36(
2562
2774
  FileTrigger,
2563
2775
  {
2564
2776
  acceptedFileTypes,
2565
2777
  allowsMultiple,
2566
2778
  onSelect: accept,
2567
- children: /* @__PURE__ */ jsx34(Button, { icon: "paperclip", isDisabled: isDisabled || isReadOnly, children: chooseLabel ?? msg.fileUploadChoose })
2779
+ children: /* @__PURE__ */ jsx36(Button, { icon: "paperclip", isDisabled: isDisabled || isReadOnly, children: chooseLabel ?? msg.fileUploadChoose })
2568
2780
  }
2569
2781
  ),
2570
- files.length ? /* @__PURE__ */ jsx34("ul", { className: "pire-fileupload-list", children: files.map(({ file, previewUrl }) => /* @__PURE__ */ jsxs26("li", { className: "pire-fileupload-item", children: [
2571
- previewUrl ? /* @__PURE__ */ jsx34("img", { className: "pire-fileupload-thumb", src: previewUrl, alt: "" }) : /* @__PURE__ */ jsx34(Icon, { name: "file-text", size: 16, className: "pire-fileupload-icon" }),
2572
- /* @__PURE__ */ jsx34("span", { className: "pire-fileupload-name", children: file.name }),
2573
- /* @__PURE__ */ jsx34("span", { className: "pire-fileupload-size", children: formatFileSize(file.size) }),
2574
- isDisabled || isReadOnly ? null : /* @__PURE__ */ jsx34(
2782
+ files.length ? /* @__PURE__ */ jsx36("ul", { className: "pire-fileupload-list", children: files.map(({ file, previewUrl }) => /* @__PURE__ */ jsxs27("li", { className: "pire-fileupload-item", children: [
2783
+ previewUrl ? /* @__PURE__ */ jsx36("img", { className: "pire-fileupload-thumb", src: previewUrl, alt: "" }) : /* @__PURE__ */ jsx36(Icon, { name: "file-text", size: 16, className: "pire-fileupload-icon" }),
2784
+ /* @__PURE__ */ jsx36("span", { className: "pire-fileupload-name", children: file.name }),
2785
+ /* @__PURE__ */ jsx36("span", { className: "pire-fileupload-size", children: formatFileSize(file.size) }),
2786
+ isDisabled || isReadOnly ? null : /* @__PURE__ */ jsx36(
2575
2787
  IconButton,
2576
2788
  {
2577
2789
  icon: "x",
@@ -2581,9 +2793,9 @@ function FileUpload({
2581
2793
  }
2582
2794
  )
2583
2795
  ] }, `${file.name}-${file.size}-${file.lastModified}`)) }) : null,
2584
- uploadProgress != null ? /* @__PURE__ */ jsx34(ProgressBar, { value: uploadProgress, label: msg.fileUploadUploading }) : null,
2585
- description ? /* @__PURE__ */ jsx34(Text12, { slot: "description", className: "pire-field-hint", children: description }) : null,
2586
- isInvalid && errorMessage ? /* @__PURE__ */ jsx34("span", { className: "pire-field-error", children: errorMessage }) : null
2796
+ uploadProgress != null ? /* @__PURE__ */ jsx36(ProgressBar, { value: uploadProgress, label: msg.fileUploadUploading }) : null,
2797
+ description ? /* @__PURE__ */ jsx36(Text13, { slot: "description", className: "pire-field-hint", children: description }) : null,
2798
+ isInvalid && errorMessage ? /* @__PURE__ */ jsx36("span", { className: "pire-field-error", children: errorMessage }) : null
2587
2799
  ]
2588
2800
  }
2589
2801
  );
@@ -2591,7 +2803,7 @@ function FileUpload({
2591
2803
 
2592
2804
  // src/components/navigation/ShellBar.tsx
2593
2805
  import { MenuTrigger, Button as AriaButton11, Popover as Popover6 } from "react-aria-components";
2594
- import { jsx as jsx35, jsxs as jsxs27 } from "react/jsx-runtime";
2806
+ import { jsx as jsx37, jsxs as jsxs28 } from "react/jsx-runtime";
2595
2807
  var initials2 = (name) => name.trim().split(/\s+/).slice(0, 2).map((p) => p[0]).join("").toUpperCase();
2596
2808
  function ShellBar({
2597
2809
  launcher,
@@ -2610,21 +2822,21 @@ function ShellBar({
2610
2822
  ...rest
2611
2823
  }) {
2612
2824
  const msg = usePireMessages();
2613
- return /* @__PURE__ */ jsxs27("header", { className: cx("pire-shellbar", className), ...rest, children: [
2825
+ return /* @__PURE__ */ jsxs28("header", { className: cx("pire-shellbar", className), ...rest, children: [
2614
2826
  launcher,
2615
- onMenu ? /* @__PURE__ */ jsx35(IconButton, { icon: "menu", label: menuLabel, variant: "inverse", size: "sm", onPress: onMenu }) : null,
2616
- monogram ? /* @__PURE__ */ jsx35("span", { className: "pire-shellbar-mono", "aria-hidden": "true", children: monogram }) : null,
2617
- product ? /* @__PURE__ */ jsx35("span", { className: "pire-shellbar-product", children: product }) : null,
2618
- title ? /* @__PURE__ */ jsx35("span", { className: "pire-shellbar-title", children: title }) : null,
2619
- /* @__PURE__ */ jsx35("span", { className: "pire-shellbar-spacer" }),
2620
- onSearch ? /* @__PURE__ */ jsx35(IconButton, { icon: "search", label: searchLabel, variant: "inverse", size: "sm", onPress: onSearch }) : null,
2827
+ onMenu ? /* @__PURE__ */ jsx37(IconButton, { icon: "menu", label: menuLabel, variant: "inverse", size: "sm", onPress: onMenu }) : null,
2828
+ monogram ? /* @__PURE__ */ jsx37("span", { className: "pire-shellbar-mono", "aria-hidden": "true", children: monogram }) : null,
2829
+ product ? /* @__PURE__ */ jsx37("span", { className: "pire-shellbar-product", children: product }) : null,
2830
+ title ? /* @__PURE__ */ jsx37("span", { className: "pire-shellbar-title", children: title }) : null,
2831
+ /* @__PURE__ */ jsx37("span", { className: "pire-shellbar-spacer" }),
2832
+ onSearch ? /* @__PURE__ */ jsx37(IconButton, { icon: "search", label: searchLabel, variant: "inverse", size: "sm", onPress: onSearch }) : null,
2621
2833
  actions,
2622
2834
  user && userMenu ? (
2623
2835
  // A real button, not the img-role span: the avatar is where "my profile", "switch company"
2624
2836
  // and "sign out" live in any ERP, and a span accepts neither focus nor onPress. Popover is
2625
2837
  // rendered here rather than expected from the consumer so the panel keeps shell placement.
2626
- /* @__PURE__ */ jsxs27(MenuTrigger, { children: [
2627
- /* @__PURE__ */ jsx35(
2838
+ /* @__PURE__ */ jsxs28(MenuTrigger, { children: [
2839
+ /* @__PURE__ */ jsx37(
2628
2840
  AriaButton11,
2629
2841
  {
2630
2842
  className: "pire-avatar pire-avatar-trigger",
@@ -2632,14 +2844,14 @@ function ShellBar({
2632
2844
  children: initials2(user)
2633
2845
  }
2634
2846
  ),
2635
- /* @__PURE__ */ jsx35(Popover6, { className: "pire-popover", children: userMenu })
2847
+ /* @__PURE__ */ jsx37(Popover6, { className: "pire-popover", children: userMenu })
2636
2848
  ] })
2637
- ) : user ? /* @__PURE__ */ jsx35("span", { className: "pire-avatar", title: user, "aria-label": user, role: "img", children: initials2(user) }) : null
2849
+ ) : user ? /* @__PURE__ */ jsx37("span", { className: "pire-avatar", title: user, "aria-label": user, role: "img", children: initials2(user) }) : null
2638
2850
  ] });
2639
2851
  }
2640
2852
 
2641
2853
  // src/components/navigation/SideNav.tsx
2642
- import * as React21 from "react";
2854
+ import * as React22 from "react";
2643
2855
  import {
2644
2856
  Button as AriaButton12,
2645
2857
  Disclosure,
@@ -2657,11 +2869,11 @@ import {
2657
2869
  Separator as AriaSeparator2,
2658
2870
  Header
2659
2871
  } from "react-aria-components";
2660
- import { jsx as jsx36, jsxs as jsxs28 } from "react/jsx-runtime";
2872
+ import { jsx as jsx38, jsxs as jsxs29 } from "react/jsx-runtime";
2661
2873
  function Menu({ minWidth, className, style, ...rest }) {
2662
2874
  const width = typeof minWidth === "number" ? `${minWidth}px` : minWidth;
2663
2875
  const menuStyle = width == null ? style : { ["--pire-menu-min-w"]: width, ...style };
2664
- return /* @__PURE__ */ jsx36(
2876
+ return /* @__PURE__ */ jsx38(
2665
2877
  AriaMenu,
2666
2878
  {
2667
2879
  className: cx("pire-menu", className),
@@ -2685,35 +2897,35 @@ function MenuItem({
2685
2897
  ...rest
2686
2898
  }) {
2687
2899
  const keys = shortcutKeys(shortcut);
2688
- return /* @__PURE__ */ jsxs28(
2900
+ return /* @__PURE__ */ jsxs29(
2689
2901
  AriaMenuItem,
2690
2902
  {
2691
2903
  className: cx("pire-menu-item", className),
2692
2904
  "data-tone": tone === "danger" ? "danger" : void 0,
2693
2905
  ...rest,
2694
2906
  children: [
2695
- icon ? /* @__PURE__ */ jsx36(Icon, { name: icon, size: 16, className: "pire-menu-item-icon" }) : null,
2696
- /* @__PURE__ */ jsxs28("span", { className: "pire-menu-item-body", children: [
2697
- /* @__PURE__ */ jsx36("span", { className: "pire-menu-item-label", children }),
2698
- description ? /* @__PURE__ */ jsx36("span", { className: "pire-menu-item-desc", children: description }) : null
2907
+ icon ? /* @__PURE__ */ jsx38(Icon, { name: icon, size: 16, className: "pire-menu-item-icon" }) : null,
2908
+ /* @__PURE__ */ jsxs29("span", { className: "pire-menu-item-body", children: [
2909
+ /* @__PURE__ */ jsx38("span", { className: "pire-menu-item-label", children }),
2910
+ description ? /* @__PURE__ */ jsx38("span", { className: "pire-menu-item-desc", children: description }) : null
2699
2911
  ] }),
2700
- keys.length ? /* @__PURE__ */ jsx36("span", { className: "pire-menu-item-shortcut", children: keys.map((cap, index) => /* @__PURE__ */ jsx36(Kbd, { size: "sm", children: cap }, `${cap}-${index}`)) }) : null
2912
+ keys.length ? /* @__PURE__ */ jsx38("span", { className: "pire-menu-item-shortcut", children: keys.map((cap, index) => /* @__PURE__ */ jsx38(Kbd, { size: "sm", children: cap }, `${cap}-${index}`)) }) : null
2701
2913
  ]
2702
2914
  }
2703
2915
  );
2704
2916
  }
2705
2917
  function MenuSection({ title, children, className, ...rest }) {
2706
- return /* @__PURE__ */ jsxs28(AriaMenuSection, { className: cx("pire-menu-section", className), ...rest, children: [
2707
- title ? /* @__PURE__ */ jsx36(Header, { className: "pire-menu-section-title", children: title }) : null,
2918
+ return /* @__PURE__ */ jsxs29(AriaMenuSection, { className: cx("pire-menu-section", className), ...rest, children: [
2919
+ title ? /* @__PURE__ */ jsx38(Header, { className: "pire-menu-section-title", children: title }) : null,
2708
2920
  children
2709
2921
  ] });
2710
2922
  }
2711
2923
  function MenuSeparator({ className }) {
2712
- return /* @__PURE__ */ jsx36(AriaSeparator2, { className: cx("pire-menu-separator", className) });
2924
+ return /* @__PURE__ */ jsx38(AriaSeparator2, { className: cx("pire-menu-separator", className) });
2713
2925
  }
2714
2926
 
2715
2927
  // src/components/navigation/SideNav.tsx
2716
- import { jsx as jsx37, jsxs as jsxs29 } from "react/jsx-runtime";
2928
+ import { jsx as jsx39, jsxs as jsxs30 } from "react/jsx-runtime";
2717
2929
  function findActiveParent(groups, value) {
2718
2930
  if (value == null) return void 0;
2719
2931
  for (const group of groups) {
@@ -2739,10 +2951,10 @@ function SideNav({
2739
2951
  const msg = usePireMessages();
2740
2952
  const activeParent = findActiveParent(groups, value);
2741
2953
  const isControlled = expandedIds != null;
2742
- const [ownExpanded, setOwnExpanded] = React21.useState(
2954
+ const [ownExpanded, setOwnExpanded] = React22.useState(
2743
2955
  () => new Set(defaultExpandedIds ?? (activeParent ? [activeParent] : []))
2744
2956
  );
2745
- const [lastValue, setLastValue] = React21.useState(value);
2957
+ const [lastValue, setLastValue] = React22.useState(value);
2746
2958
  if (value !== lastValue) {
2747
2959
  setLastValue(value);
2748
2960
  if (!isControlled && activeParent && !ownExpanded.has(activeParent)) {
@@ -2762,7 +2974,7 @@ function SideNav({
2762
2974
  };
2763
2975
  const renderRow = (item, onPress, isGroup) => {
2764
2976
  const selected = !isGroup && item.id === value;
2765
- const button = /* @__PURE__ */ jsxs29(
2977
+ const button = /* @__PURE__ */ jsxs30(
2766
2978
  AriaButton12,
2767
2979
  {
2768
2980
  className: "pire-sidenav-item",
@@ -2772,37 +2984,37 @@ function SideNav({
2772
2984
  "aria-label": collapsed ? item.label : void 0,
2773
2985
  onPress,
2774
2986
  children: [
2775
- item.icon ? /* @__PURE__ */ jsx37(Icon, { name: item.icon, size: 16 }) : null,
2776
- collapsed ? null : /* @__PURE__ */ jsx37("span", { children: item.label }),
2777
- item.count != null && !collapsed ? /* @__PURE__ */ jsx37("span", { className: "pire-sidenav-count", children: item.count }) : null
2987
+ item.icon ? /* @__PURE__ */ jsx39(Icon, { name: item.icon, size: 16 }) : null,
2988
+ collapsed ? null : /* @__PURE__ */ jsx39("span", { children: item.label }),
2989
+ item.count != null && !collapsed ? /* @__PURE__ */ jsx39("span", { className: "pire-sidenav-count", children: item.count }) : null
2778
2990
  ]
2779
2991
  },
2780
2992
  item.id
2781
2993
  );
2782
- return collapsed ? /* @__PURE__ */ jsx37(Tooltip, { label: item.label, placement: "right", children: button }, item.id) : button;
2994
+ return collapsed ? /* @__PURE__ */ jsx39(Tooltip, { label: item.label, placement: "right", children: button }, item.id) : button;
2783
2995
  };
2784
- const renderRailFlyout = (item) => /* @__PURE__ */ jsxs29(MenuTrigger2, { children: [
2785
- /* @__PURE__ */ jsx37(
2996
+ const renderRailFlyout = (item) => /* @__PURE__ */ jsxs30(MenuTrigger2, { children: [
2997
+ /* @__PURE__ */ jsx39(
2786
2998
  AriaButton12,
2787
2999
  {
2788
3000
  className: "pire-sidenav-item",
2789
3001
  "aria-label": item.label,
2790
3002
  "data-active-child": item.id === activeParent ? "true" : void 0,
2791
- children: item.icon ? /* @__PURE__ */ jsx37(Icon, { name: item.icon, size: 16 }) : null
3003
+ children: item.icon ? /* @__PURE__ */ jsx39(Icon, { name: item.icon, size: 16 }) : null
2792
3004
  }
2793
3005
  ),
2794
- /* @__PURE__ */ jsx37(Popover7, { className: "pire-popover", placement: "right top", offset: 4, children: /* @__PURE__ */ jsx37(
3006
+ /* @__PURE__ */ jsx39(Popover7, { className: "pire-popover", placement: "right top", offset: 4, children: /* @__PURE__ */ jsx39(
2795
3007
  Menu,
2796
3008
  {
2797
3009
  "aria-label": item.label,
2798
3010
  className: "pire-sidenav-flyout",
2799
3011
  onAction: (key) => onChange?.(String(key)),
2800
- children: (item.items ?? []).map((child) => /* @__PURE__ */ jsx37(MenuItem, { id: child.id, children: child.label }, child.id))
3012
+ children: (item.items ?? []).map((child) => /* @__PURE__ */ jsx39(MenuItem, { id: child.id, children: child.label }, child.id))
2801
3013
  }
2802
3014
  ) })
2803
3015
  ] }, item.id);
2804
- const renderSection = (item) => /* @__PURE__ */ jsxs29(Disclosure, { id: item.id, className: "pire-sidenav-section", children: [
2805
- /* @__PURE__ */ jsxs29(
3016
+ const renderSection = (item) => /* @__PURE__ */ jsxs30(Disclosure, { id: item.id, className: "pire-sidenav-section", children: [
3017
+ /* @__PURE__ */ jsxs30(
2806
3018
  AriaButton12,
2807
3019
  {
2808
3020
  slot: "trigger",
@@ -2810,16 +3022,16 @@ function SideNav({
2810
3022
  "data-kind": "group",
2811
3023
  "data-active-child": item.id === activeParent ? "true" : void 0,
2812
3024
  children: [
2813
- item.icon ? /* @__PURE__ */ jsx37(Icon, { name: item.icon, size: 16 }) : null,
2814
- /* @__PURE__ */ jsx37("span", { children: item.label }),
2815
- item.count != null ? /* @__PURE__ */ jsx37("span", { className: "pire-sidenav-count", children: item.count }) : null,
2816
- /* @__PURE__ */ jsx37(Icon, { name: "chevron-down", size: 16, className: "pire-sidenav-chevron" })
3025
+ item.icon ? /* @__PURE__ */ jsx39(Icon, { name: item.icon, size: 16 }) : null,
3026
+ /* @__PURE__ */ jsx39("span", { children: item.label }),
3027
+ item.count != null ? /* @__PURE__ */ jsx39("span", { className: "pire-sidenav-count", children: item.count }) : null,
3028
+ /* @__PURE__ */ jsx39(Icon, { name: "chevron-down", size: 16, className: "pire-sidenav-chevron" })
2817
3029
  ]
2818
3030
  }
2819
3031
  ),
2820
- /* @__PURE__ */ jsx37(DisclosurePanel, { className: "pire-sidenav-subnav", children: item.items?.map((child) => {
3032
+ /* @__PURE__ */ jsx39(DisclosurePanel, { className: "pire-sidenav-subnav", children: item.items?.map((child) => {
2821
3033
  const selected = child.id === value;
2822
- return /* @__PURE__ */ jsxs29(
3034
+ return /* @__PURE__ */ jsxs30(
2823
3035
  AriaButton12,
2824
3036
  {
2825
3037
  className: "pire-sidenav-item pire-sidenav-subitem",
@@ -2827,15 +3039,15 @@ function SideNav({
2827
3039
  "aria-current": selected ? "page" : void 0,
2828
3040
  onPress: () => onChange?.(child.id),
2829
3041
  children: [
2830
- /* @__PURE__ */ jsx37("span", { children: child.label }),
2831
- child.count != null ? /* @__PURE__ */ jsx37("span", { className: "pire-sidenav-count", children: child.count }) : null
3042
+ /* @__PURE__ */ jsx39("span", { children: child.label }),
3043
+ child.count != null ? /* @__PURE__ */ jsx39("span", { className: "pire-sidenav-count", children: child.count }) : null
2832
3044
  ]
2833
3045
  },
2834
3046
  child.id
2835
3047
  );
2836
3048
  }) })
2837
3049
  ] }, item.id);
2838
- return /* @__PURE__ */ jsxs29(
3050
+ return /* @__PURE__ */ jsxs30(
2839
3051
  "nav",
2840
3052
  {
2841
3053
  className: cx("pire-sidenav", className),
@@ -2851,9 +3063,9 @@ function SideNav({
2851
3063
  if (isGroup && collapsed && railFlyout) return renderRailFlyout(item);
2852
3064
  return renderRow(item, () => isGroup ? toggleExpanded(item.id) : onChange?.(item.id), isGroup);
2853
3065
  });
2854
- return /* @__PURE__ */ jsxs29("div", { className: "pire-sidenav-group", children: [
2855
- group.label && !collapsed ? /* @__PURE__ */ jsx37("div", { className: "pire-sidenav-label", children: group.label }) : null,
2856
- hasSections ? /* @__PURE__ */ jsx37(
3066
+ return /* @__PURE__ */ jsxs30("div", { className: "pire-sidenav-group", children: [
3067
+ group.label && !collapsed ? /* @__PURE__ */ jsx39("div", { className: "pire-sidenav-label", children: group.label }) : null,
3068
+ hasSections ? /* @__PURE__ */ jsx39(
2857
3069
  DisclosureGroup,
2858
3070
  {
2859
3071
  className: "pire-sidenav-tree",
@@ -2865,24 +3077,24 @@ function SideNav({
2865
3077
  ) : rows
2866
3078
  ] }, group.label ?? gi);
2867
3079
  }),
2868
- footer ? /* @__PURE__ */ jsx37("div", { className: "pire-sidenav-footer", children: footer }) : null
3080
+ footer ? /* @__PURE__ */ jsx39("div", { className: "pire-sidenav-footer", children: footer }) : null
2869
3081
  ]
2870
3082
  }
2871
3083
  );
2872
3084
  }
2873
3085
 
2874
3086
  // src/components/navigation/ShellRail.tsx
2875
- import * as React22 from "react";
3087
+ import * as React23 from "react";
2876
3088
  import { Button as AriaButton13 } from "react-aria-components";
2877
- import { jsx as jsx38, jsxs as jsxs30 } from "react/jsx-runtime";
3089
+ import { jsx as jsx40, jsxs as jsxs31 } from "react/jsx-runtime";
2878
3090
  function ShellRail({ groups, value, onChange, className, ...rest }) {
2879
3091
  const msg = usePireMessages();
2880
- return /* @__PURE__ */ jsx38("nav", { className: cx("pire-shellrail", className), "aria-label": msg.shellRailLabel, ...rest, children: groups.map((group, gi) => (
3092
+ return /* @__PURE__ */ jsx40("nav", { className: cx("pire-shellrail", className), "aria-label": msg.shellRailLabel, ...rest, children: groups.map((group, gi) => (
2881
3093
  // The divider is a sibling of the groups rather than a pseudo-element on one, because the
2882
3094
  // scrolling zone would carry its own rule out of view on the first wheel event.
2883
- /* @__PURE__ */ jsxs30(React22.Fragment, { children: [
2884
- gi > 0 ? /* @__PURE__ */ jsx38("div", { className: "pire-shellrail-divider" }) : null,
2885
- /* @__PURE__ */ jsx38("div", { className: "pire-shellrail-group", "data-scroll": group.isScrollable ? "true" : void 0, children: group.items.map((item) => /* @__PURE__ */ jsx38(Tooltip, { label: item.label, placement: "right", children: /* @__PURE__ */ jsx38(
3095
+ /* @__PURE__ */ jsxs31(React23.Fragment, { children: [
3096
+ gi > 0 ? /* @__PURE__ */ jsx40("div", { className: "pire-shellrail-divider" }) : null,
3097
+ /* @__PURE__ */ jsx40("div", { className: "pire-shellrail-group", "data-scroll": group.isScrollable ? "true" : void 0, children: group.items.map((item) => /* @__PURE__ */ jsx40(Tooltip, { label: item.label, placement: "right", children: /* @__PURE__ */ jsx40(
2886
3098
  AriaButton13,
2887
3099
  {
2888
3100
  className: "pire-shellrail-item",
@@ -2890,7 +3102,7 @@ function ShellRail({ groups, value, onChange, className, ...rest }) {
2890
3102
  "data-selected": item.id === value ? "true" : void 0,
2891
3103
  "aria-current": item.id === value ? "true" : void 0,
2892
3104
  onPress: () => onChange?.(item.id),
2893
- children: /* @__PURE__ */ jsx38("span", { className: "pire-shellrail-tile", children: /* @__PURE__ */ jsx38(Icon, { name: item.icon, size: 20 }) })
3105
+ children: /* @__PURE__ */ jsx40("span", { className: "pire-shellrail-tile", children: /* @__PURE__ */ jsx40(Icon, { name: item.icon, size: 20 }) })
2894
3106
  }
2895
3107
  ) }, item.id)) })
2896
3108
  ] }, group.items[0]?.id ?? gi)
@@ -2899,9 +3111,9 @@ function ShellRail({ groups, value, onChange, className, ...rest }) {
2899
3111
 
2900
3112
  // src/components/navigation/Tabs.tsx
2901
3113
  import { Tabs as AriaTabs, TabList, Tab as AriaTab, TabPanel } from "react-aria-components";
2902
- import { jsx as jsx39, jsxs as jsxs31 } from "react/jsx-runtime";
3114
+ import { jsx as jsx41, jsxs as jsxs32 } from "react/jsx-runtime";
2903
3115
  function Tabs({ items, value, defaultValue, onChange, panels, className, style, ...rest }) {
2904
- return /* @__PURE__ */ jsxs31(
3116
+ return /* @__PURE__ */ jsxs32(
2905
3117
  AriaTabs,
2906
3118
  {
2907
3119
  className,
@@ -2910,12 +3122,12 @@ function Tabs({ items, value, defaultValue, onChange, panels, className, style,
2910
3122
  defaultSelectedKey: defaultValue,
2911
3123
  onSelectionChange: (k) => onChange?.(String(k)),
2912
3124
  children: [
2913
- /* @__PURE__ */ jsx39(TabList, { className: "pire-tablist", items, "aria-label": rest["aria-label"] ?? "Views", children: (item) => /* @__PURE__ */ jsxs31(AriaTab, { className: cx("pire-tab"), id: item.id, isDisabled: item.isDisabled, children: [
2914
- item.icon ? /* @__PURE__ */ jsx39(Icon, { name: item.icon, size: 16 }) : null,
3125
+ /* @__PURE__ */ jsx41(TabList, { className: "pire-tablist", items, "aria-label": rest["aria-label"] ?? "Views", children: (item) => /* @__PURE__ */ jsxs32(AriaTab, { className: cx("pire-tab"), id: item.id, isDisabled: item.isDisabled, children: [
3126
+ item.icon ? /* @__PURE__ */ jsx41(Icon, { name: item.icon, size: 16 }) : null,
2915
3127
  item.label,
2916
- item.count != null ? /* @__PURE__ */ jsx39("span", { className: "pire-tab-count", children: item.count }) : null
3128
+ item.count != null ? /* @__PURE__ */ jsx41("span", { className: "pire-tab-count", children: item.count }) : null
2917
3129
  ] }) }),
2918
- items.map((item) => /* @__PURE__ */ jsx39(TabPanel, { id: item.id, className: panels ? "pire-tabpanel" : void 0, children: panels?.[item.id] }, item.id))
3130
+ items.map((item) => /* @__PURE__ */ jsx41(TabPanel, { id: item.id, className: panels ? "pire-tabpanel" : void 0, children: panels?.[item.id] }, item.id))
2919
3131
  ]
2920
3132
  }
2921
3133
  );
@@ -2923,9 +3135,9 @@ function Tabs({ items, value, defaultValue, onChange, panels, className, style,
2923
3135
 
2924
3136
  // src/components/navigation/Breadcrumb.tsx
2925
3137
  import { Breadcrumbs as AriaBreadcrumbs, Breadcrumb as AriaBreadcrumb, Link as Link2 } from "react-aria-components";
2926
- import { jsx as jsx40, jsxs as jsxs32 } from "react/jsx-runtime";
3138
+ import { jsx as jsx42, jsxs as jsxs33 } from "react/jsx-runtime";
2927
3139
  function Breadcrumb({ items, onNavigate, className, style }) {
2928
- return /* @__PURE__ */ jsx40(
3140
+ return /* @__PURE__ */ jsx42(
2929
3141
  AriaBreadcrumbs,
2930
3142
  {
2931
3143
  className: cx("pire-breadcrumbs", className),
@@ -2934,9 +3146,9 @@ function Breadcrumb({ items, onNavigate, className, style }) {
2934
3146
  onAction: (key) => onNavigate?.(String(key)),
2935
3147
  children: (item) => {
2936
3148
  const last = items[items.length - 1] === item;
2937
- return /* @__PURE__ */ jsxs32(AriaBreadcrumb, { className: "pire-breadcrumb", id: item.id ?? item.label, children: [
2938
- last ? item.label : /* @__PURE__ */ jsx40(Link2, { href: item.href, children: item.label }),
2939
- last ? null : /* @__PURE__ */ jsx40(Icon, { name: "chevron-right", size: 12, style: { color: "var(--text-tertiary)" } })
3149
+ return /* @__PURE__ */ jsxs33(AriaBreadcrumb, { className: "pire-breadcrumb", id: item.id ?? item.label, children: [
3150
+ last ? item.label : /* @__PURE__ */ jsx42(Link2, { href: item.href, children: item.label }),
3151
+ last ? null : /* @__PURE__ */ jsx42(Icon, { name: "chevron-right", size: 12, style: { color: "var(--text-tertiary)" } })
2940
3152
  ] });
2941
3153
  }
2942
3154
  }
@@ -2944,7 +3156,7 @@ function Breadcrumb({ items, onNavigate, className, style }) {
2944
3156
  }
2945
3157
 
2946
3158
  // src/components/navigation/Pagination.tsx
2947
- import { jsx as jsx41, jsxs as jsxs33 } from "react/jsx-runtime";
3159
+ import { jsx as jsx43, jsxs as jsxs34 } from "react/jsx-runtime";
2948
3160
  function Pagination({
2949
3161
  page = 1,
2950
3162
  pageSize = 25,
@@ -2959,9 +3171,9 @@ function Pagination({
2959
3171
  const pages = Math.max(1, Math.ceil(total / pageSize));
2960
3172
  const from = total === 0 ? 0 : (page - 1) * pageSize + 1;
2961
3173
  const to = Math.min(total, page * pageSize);
2962
- return /* @__PURE__ */ jsxs33("nav", { className: cx("pire-pagination", className), style, "aria-label": msg.paginationLabel, children: [
2963
- /* @__PURE__ */ jsx41("span", { className: "pire-pagination-count", children: msg.paginationRange.replace("{from}", from.toLocaleString()).replace("{to}", to.toLocaleString()).replace("{total}", total.toLocaleString()) }),
2964
- /* @__PURE__ */ jsx41(
3174
+ return /* @__PURE__ */ jsxs34("nav", { className: cx("pire-pagination", className), style, "aria-label": msg.paginationLabel, children: [
3175
+ /* @__PURE__ */ jsx43("span", { className: "pire-pagination-count", children: msg.paginationRange.replace("{from}", from.toLocaleString()).replace("{to}", to.toLocaleString()).replace("{total}", total.toLocaleString()) }),
3176
+ /* @__PURE__ */ jsx43(
2965
3177
  IconButton,
2966
3178
  {
2967
3179
  icon: "chevron-left",
@@ -2972,8 +3184,8 @@ function Pagination({
2972
3184
  onPress: () => onPageChange?.(page - 1)
2973
3185
  }
2974
3186
  ),
2975
- /* @__PURE__ */ jsx41("span", { className: "pire-pagination-count", "aria-live": "polite", children: msg.paginationPageOf.replace("{page}", String(page)).replace("{pages}", String(pages)) }),
2976
- /* @__PURE__ */ jsx41(
3187
+ /* @__PURE__ */ jsx43("span", { className: "pire-pagination-count", "aria-live": "polite", children: msg.paginationPageOf.replace("{page}", String(page)).replace("{pages}", String(pages)) }),
3188
+ /* @__PURE__ */ jsx43(
2977
3189
  IconButton,
2978
3190
  {
2979
3191
  icon: "chevron-right",
@@ -2984,7 +3196,7 @@ function Pagination({
2984
3196
  onPress: () => onPageChange?.(page + 1)
2985
3197
  }
2986
3198
  ),
2987
- onPageSizeChange ? /* @__PURE__ */ jsx41(
3199
+ onPageSizeChange ? /* @__PURE__ */ jsx43(
2988
3200
  Select,
2989
3201
  {
2990
3202
  "aria-label": msg.paginationRowsPerPage,
@@ -2999,8 +3211,236 @@ function Pagination({
2999
3211
  ] });
3000
3212
  }
3001
3213
 
3214
+ // src/components/navigation/Ribbon.tsx
3215
+ import * as React24 from "react";
3216
+ import { Tabs as AriaTabs2, TabList as TabList2, Tab as AriaTab2, TabPanel as TabPanel2, Toolbar, Button as Button3 } from "react-aria-components";
3217
+ import { Fragment as Fragment6, jsx as jsx44, jsxs as jsxs35 } from "react/jsx-runtime";
3218
+ var outside = (what, parent) => {
3219
+ const Config = () => {
3220
+ throw new Error(`[pire] ${what} must be a child of ${parent}.`);
3221
+ };
3222
+ Object.defineProperty(Config, "name", { value: what });
3223
+ Config.displayName = what;
3224
+ return Config;
3225
+ };
3226
+ var RibbonTab = outside("Ribbon.Tab", "Ribbon");
3227
+ var RibbonGroup = outside("Ribbon.Group", "Ribbon.Tab");
3228
+ var RibbonCommand = outside("Ribbon.Command", "Ribbon.Group");
3229
+ var CONFIG_ELEMENTS = /* @__PURE__ */ new Set([RibbonTab, RibbonGroup, RibbonCommand]);
3230
+ function describe(child) {
3231
+ if (!React24.isValidElement(child)) return JSON.stringify(child);
3232
+ if (typeof child.type === "string") return `<${child.type}>`;
3233
+ const type = child.type;
3234
+ return type?.displayName || type?.name || "a component";
3235
+ }
3236
+ function childrenOfType(children, type, what, parent) {
3237
+ const out = [];
3238
+ const walk = (nodes, path) => {
3239
+ React24.Children.forEach(nodes, (child, i) => {
3240
+ if (child == null || typeof child === "boolean") return;
3241
+ if (React24.isValidElement(child) && child.type === React24.Fragment) {
3242
+ return walk(child.props.children, `${path}${i}.`);
3243
+ }
3244
+ if (!React24.isValidElement(child) || child.type !== type) {
3245
+ const isWrapper = React24.isValidElement(child) && typeof child.type !== "string" && !CONFIG_ELEMENTS.has(child.type);
3246
+ throw new Error(`[pire] ${parent} accepts only ${what} as children, and got ${describe(child)}.` + (isWrapper ? ` Configuration elements are read, not rendered, so ${parent} cannot see through a wrapper component.` : ""));
3247
+ }
3248
+ out.push({ ...child.props, key: child.key != null ? String(child.key) : `${path}${i}` });
3249
+ });
3250
+ };
3251
+ walk(children, "");
3252
+ return out;
3253
+ }
3254
+ function readTabs(children) {
3255
+ return childrenOfType(children, RibbonTab, "Ribbon.Tab", "Ribbon").map((tab) => ({
3256
+ ...tab,
3257
+ groups: childrenOfType(tab.children, RibbonGroup, "Ribbon.Group", "Ribbon.Tab").map((group) => ({
3258
+ ...group,
3259
+ commands: childrenOfType(group.children, RibbonCommand, "Ribbon.Command", "Ribbon.Group")
3260
+ }))
3261
+ }));
3262
+ }
3263
+ function Command({ command, selectionCount, inBar }) {
3264
+ const size = inBar ? "sm" : command.size ?? "sm";
3265
+ const isDisabled = command.isDisabled || command.requiresSelection === true && selectionCount === 0;
3266
+ return /* @__PURE__ */ jsxs35(
3267
+ Button3,
3268
+ {
3269
+ className: "pire-ribbon-command",
3270
+ "data-size": size,
3271
+ isDisabled,
3272
+ onPress: command.onPress,
3273
+ children: [
3274
+ command.icon ? /* @__PURE__ */ jsx44(Icon, { name: command.icon, size: size === "lg" ? 20 : 16 }) : null,
3275
+ /* @__PURE__ */ jsx44("span", { className: "pire-ribbon-command-label", children: command.label })
3276
+ ]
3277
+ }
3278
+ );
3279
+ }
3280
+ function Group8({ group, selectionCount }) {
3281
+ const large = group.commands.filter((c) => (c.size ?? "sm") === "lg");
3282
+ const small = group.commands.filter((c) => (c.size ?? "sm") !== "lg");
3283
+ return /* @__PURE__ */ jsxs35("div", { className: "pire-ribbon-group", role: "group", "aria-label": group.caption, children: [
3284
+ /* @__PURE__ */ jsxs35("div", { className: "pire-ribbon-group-body", children: [
3285
+ large.map((c) => /* @__PURE__ */ jsx44(Command, { command: c, selectionCount }, c.key)),
3286
+ small.length ? /* @__PURE__ */ jsx44("div", { className: "pire-ribbon-stack", children: small.map((c) => /* @__PURE__ */ jsx44(Command, { command: c, selectionCount }, c.key)) }) : null
3287
+ ] }),
3288
+ /* @__PURE__ */ jsx44("div", { className: "pire-ribbon-caption", "aria-hidden": "true", children: group.caption })
3289
+ ] });
3290
+ }
3291
+ function useTrailingOverflow() {
3292
+ const ref = React24.useRef(null);
3293
+ const [overflow, setOverflow] = React24.useState(false);
3294
+ React24.useEffect(() => {
3295
+ const node = ref.current;
3296
+ if (!node) return;
3297
+ const measure = () => setOverflow(node.scrollLeft + node.clientWidth < node.scrollWidth - 1);
3298
+ measure();
3299
+ node.addEventListener("scroll", measure, { passive: true });
3300
+ const resize = new ResizeObserver(measure);
3301
+ resize.observe(node);
3302
+ for (const child of node.children) resize.observe(child);
3303
+ return () => {
3304
+ node.removeEventListener("scroll", measure);
3305
+ resize.disconnect();
3306
+ };
3307
+ }, []);
3308
+ return [ref, overflow];
3309
+ }
3310
+ function Surface({ className, id, label, trailing, children }) {
3311
+ const [scrollRef, overflow] = useTrailingOverflow();
3312
+ const domId = id ? { id } : {};
3313
+ return /* @__PURE__ */ jsxs35(Toolbar, { ...domId, className, "aria-label": label, children: [
3314
+ /* @__PURE__ */ jsx44("div", { className: "pire-ribbon-scroll", ref: scrollRef, children }),
3315
+ /* @__PURE__ */ jsx44("div", { className: "pire-ribbon-trail", "data-overflow": overflow ? "true" : void 0, children: trailing })
3316
+ ] });
3317
+ }
3318
+ function barBlocks(tabs) {
3319
+ const blocks = [];
3320
+ for (const tab of tabs) {
3321
+ if (tab.isContextual) continue;
3322
+ for (const group of tab.groups) {
3323
+ const commands = group.commands.filter((c) => c.inBar);
3324
+ if (commands.length) blocks.push({ key: `${tab.key}:${group.key}`, commands });
3325
+ }
3326
+ }
3327
+ return blocks;
3328
+ }
3329
+ function Ribbon({
3330
+ children,
3331
+ value,
3332
+ defaultValue,
3333
+ onChange,
3334
+ isCollapsed,
3335
+ onCollapsedChange,
3336
+ leading,
3337
+ actions,
3338
+ selectionCount,
3339
+ className,
3340
+ style,
3341
+ ...rest
3342
+ }) {
3343
+ const msg = usePireMessages();
3344
+ const tabs = readTabs(children);
3345
+ const count = selectionCount ?? 0;
3346
+ const visible = tabs.filter((tab) => !tab.isContextual || count > 0);
3347
+ const fallback = visible[0]?.id;
3348
+ const [ownTab, setOwnTab] = React24.useState(defaultValue);
3349
+ const requested = value ?? ownTab;
3350
+ const selected = visible.some((tab) => tab.id === requested) ? requested : fallback;
3351
+ const select = React24.useCallback((id) => {
3352
+ setOwnTab(id);
3353
+ onChange?.(id);
3354
+ }, [onChange]);
3355
+ const hadSelection = React24.useRef(false);
3356
+ React24.useEffect(() => {
3357
+ const has = count > 0;
3358
+ if (has === hadSelection.current) return;
3359
+ hadSelection.current = has;
3360
+ const contextual = tabs.find((tab) => tab.isContextual);
3361
+ if (!contextual) return;
3362
+ if (has) select(contextual.id);
3363
+ else if (requested === contextual.id) select(tabs.find((tab) => !tab.isContextual)?.id ?? "");
3364
+ }, [count, tabs, requested, select]);
3365
+ const [ownCollapsed, setOwnCollapsed] = React24.useState(false);
3366
+ const collapsed = isCollapsed ?? ownCollapsed;
3367
+ const toggleRef = React24.useRef(null);
3368
+ const restoreFocus = React24.useRef(false);
3369
+ React24.useLayoutEffect(() => {
3370
+ if (!restoreFocus.current) return;
3371
+ restoreFocus.current = false;
3372
+ toggleRef.current?.focus();
3373
+ });
3374
+ const bandId = React24.useId();
3375
+ const toggle = /* @__PURE__ */ jsx44(
3376
+ Button3,
3377
+ {
3378
+ ref: toggleRef,
3379
+ className: "pire-ribbon-toggle",
3380
+ "aria-expanded": !collapsed,
3381
+ "aria-controls": bandId,
3382
+ "aria-label": collapsed ? msg.ribbonExpand : msg.ribbonCollapse,
3383
+ onPress: () => {
3384
+ restoreFocus.current = document.activeElement === toggleRef.current;
3385
+ setOwnCollapsed(!collapsed);
3386
+ onCollapsedChange?.(!collapsed);
3387
+ },
3388
+ children: /* @__PURE__ */ jsx44(Icon, { name: collapsed ? "chevron-down" : "chevron-up", size: 16 })
3389
+ }
3390
+ );
3391
+ if (collapsed) {
3392
+ const blocks = barBlocks(tabs);
3393
+ return /* @__PURE__ */ jsx44("div", { className: cx("pire-ribbon", className), style, children: /* @__PURE__ */ jsxs35(
3394
+ Surface,
3395
+ {
3396
+ className: "pire-ribbon-bar",
3397
+ label: rest["aria-label"],
3398
+ trailing: /* @__PURE__ */ jsxs35(Fragment6, { children: [
3399
+ actions,
3400
+ toggle
3401
+ ] }),
3402
+ children: [
3403
+ leading ? /* @__PURE__ */ jsx44("div", { className: "pire-ribbon-leading", children: leading }) : null,
3404
+ blocks.map((block, i) => /* @__PURE__ */ jsxs35(React24.Fragment, { children: [
3405
+ i > 0 || leading ? /* @__PURE__ */ jsx44("span", { className: "pire-ribbon-bar-sep" }) : null,
3406
+ block.commands.map((c) => /* @__PURE__ */ jsx44(Command, { command: c, selectionCount: count, inBar: true }, c.key))
3407
+ ] }, block.key))
3408
+ ]
3409
+ }
3410
+ ) });
3411
+ }
3412
+ return /* @__PURE__ */ jsx44("div", { className: cx("pire-ribbon", className), style, children: /* @__PURE__ */ jsxs35(AriaTabs2, { selectedKey: selected, onSelectionChange: (k) => select(String(k)), children: [
3413
+ /* @__PURE__ */ jsx44(TabList2, { className: "pire-ribbon-tablist", "aria-label": rest["aria-label"], children: visible.map((tab) => /* @__PURE__ */ jsx44(
3414
+ AriaTab2,
3415
+ {
3416
+ id: tab.id,
3417
+ className: "pire-ribbon-tab",
3418
+ "data-contextual": tab.isContextual ? "true" : void 0,
3419
+ children: tab.label
3420
+ },
3421
+ tab.key
3422
+ )) }),
3423
+ visible.map((tab) => /* @__PURE__ */ jsx44(TabPanel2, { id: tab.id, className: "pire-ribbon-panel", children: /* @__PURE__ */ jsx44(
3424
+ Surface,
3425
+ {
3426
+ id: bandId,
3427
+ className: "pire-ribbon-band",
3428
+ label: msg.ribbonLabel,
3429
+ trailing: /* @__PURE__ */ jsxs35(Fragment6, { children: [
3430
+ actions,
3431
+ toggle
3432
+ ] }),
3433
+ children: tab.groups.map((group) => /* @__PURE__ */ jsx44(Group8, { group, selectionCount: count }, group.key))
3434
+ }
3435
+ ) }, tab.key))
3436
+ ] }) });
3437
+ }
3438
+ Ribbon.Tab = RibbonTab;
3439
+ Ribbon.Group = RibbonGroup;
3440
+ Ribbon.Command = RibbonCommand;
3441
+
3002
3442
  // src/components/feedback/InlineMessage.tsx
3003
- import { jsx as jsx42, jsxs as jsxs34 } from "react/jsx-runtime";
3443
+ import { jsx as jsx45, jsxs as jsxs36 } from "react/jsx-runtime";
3004
3444
  var KIND_ICON = {
3005
3445
  info: "info",
3006
3446
  success: "check-circle-2",
@@ -3010,7 +3450,7 @@ var KIND_ICON = {
3010
3450
  function InlineMessage({ kind = "info", title, action, onClose, children, className, ...rest }) {
3011
3451
  const msg = usePireMessages();
3012
3452
  const assertive = kind === "error" || kind === "warning";
3013
- return /* @__PURE__ */ jsxs34(
3453
+ return /* @__PURE__ */ jsxs36(
3014
3454
  "div",
3015
3455
  {
3016
3456
  className: cx("pire-msg", className),
@@ -3019,21 +3459,21 @@ function InlineMessage({ kind = "info", title, action, onClose, children, classN
3019
3459
  "aria-live": assertive ? "assertive" : "polite",
3020
3460
  ...rest,
3021
3461
  children: [
3022
- /* @__PURE__ */ jsx42(Icon, { name: KIND_ICON[kind], size: 16, style: { marginTop: 2 } }),
3023
- /* @__PURE__ */ jsxs34("div", { style: { flex: 1, display: "flex", flexDirection: "column", gap: "var(--sp-1)" }, children: [
3024
- title ? /* @__PURE__ */ jsx42("span", { className: "pire-msg-title", children: title }) : null,
3025
- children ? /* @__PURE__ */ jsx42("span", { className: "pire-msg-body", children }) : null,
3462
+ /* @__PURE__ */ jsx45(Icon, { name: KIND_ICON[kind], size: 16, style: { marginTop: 2 } }),
3463
+ /* @__PURE__ */ jsxs36("div", { style: { flex: 1, display: "flex", flexDirection: "column", gap: "var(--sp-1)" }, children: [
3464
+ title ? /* @__PURE__ */ jsx45("span", { className: "pire-msg-title", children: title }) : null,
3465
+ children ? /* @__PURE__ */ jsx45("span", { className: "pire-msg-body", children }) : null,
3026
3466
  action
3027
3467
  ] }),
3028
- onClose ? /* @__PURE__ */ jsx42(IconButton, { icon: "x", label: msg.inlineMessageDismiss, size: "sm", onPress: onClose }) : null
3468
+ onClose ? /* @__PURE__ */ jsx45(IconButton, { icon: "x", label: msg.inlineMessageDismiss, size: "sm", onPress: onClose }) : null
3029
3469
  ]
3030
3470
  }
3031
3471
  );
3032
3472
  }
3033
3473
 
3034
3474
  // src/components/feedback/Toast.tsx
3035
- import * as React23 from "react";
3036
- import { jsx as jsx43, jsxs as jsxs35 } from "react/jsx-runtime";
3475
+ import * as React25 from "react";
3476
+ import { jsx as jsx46, jsxs as jsxs37 } from "react/jsx-runtime";
3037
3477
  var KIND_ICON2 = {
3038
3478
  info: "info",
3039
3479
  success: "check-circle-2",
@@ -3042,7 +3482,7 @@ var KIND_ICON2 = {
3042
3482
  };
3043
3483
  function Toast({ kind = "success", onClose, position = "bottom-center", children, className, ...rest }) {
3044
3484
  const msg = usePireMessages();
3045
- return /* @__PURE__ */ jsxs35(
3485
+ return /* @__PURE__ */ jsxs37(
3046
3486
  "div",
3047
3487
  {
3048
3488
  className: cx("pire-toast", className),
@@ -3051,40 +3491,40 @@ function Toast({ kind = "success", onClose, position = "bottom-center", children
3051
3491
  "aria-live": kind === "error" ? "assertive" : "polite",
3052
3492
  ...rest,
3053
3493
  children: [
3054
- /* @__PURE__ */ jsx43(Icon, { name: KIND_ICON2[kind], size: 16 }),
3055
- /* @__PURE__ */ jsx43("span", { style: { flex: 1 }, children }),
3056
- onClose ? /* @__PURE__ */ jsx43(IconButton, { icon: "x", label: msg.toastDismiss, size: "sm", variant: "inverse", onPress: onClose }) : null
3494
+ /* @__PURE__ */ jsx46(Icon, { name: KIND_ICON2[kind], size: 16 }),
3495
+ /* @__PURE__ */ jsx46("span", { style: { flex: 1 }, children }),
3496
+ onClose ? /* @__PURE__ */ jsx46(IconButton, { icon: "x", label: msg.toastDismiss, size: "sm", variant: "inverse", onPress: onClose }) : null
3057
3497
  ]
3058
3498
  }
3059
3499
  );
3060
3500
  }
3061
- var ToastContext = React23.createContext(null);
3501
+ var ToastContext = React25.createContext(null);
3062
3502
  function ToastProvider({ children, timeout = 6e3 }) {
3063
3503
  const msg = usePireMessages();
3064
- const [toasts, setToasts] = React23.useState([]);
3065
- const close = React23.useCallback((id) => setToasts((t) => t.filter((x) => x.id !== id)), []);
3066
- const add = React23.useCallback((toast) => {
3504
+ const [toasts, setToasts] = React25.useState([]);
3505
+ const close = React25.useCallback((id) => setToasts((t) => t.filter((x) => x.id !== id)), []);
3506
+ const add = React25.useCallback((toast) => {
3067
3507
  const id = Math.random().toString(36).slice(2);
3068
3508
  setToasts((t) => [...t, { ...toast, id }]);
3069
3509
  const ms = toast.timeout ?? timeout;
3070
3510
  if (ms > 0) setTimeout(() => close(id), ms);
3071
3511
  return id;
3072
3512
  }, [close, timeout]);
3073
- const value = React23.useMemo(() => ({ add, close }), [add, close]);
3074
- return /* @__PURE__ */ jsxs35(ToastContext.Provider, { value, children: [
3513
+ const value = React25.useMemo(() => ({ add, close }), [add, close]);
3514
+ return /* @__PURE__ */ jsxs37(ToastContext.Provider, { value, children: [
3075
3515
  children,
3076
- /* @__PURE__ */ jsx43("div", { className: "pire-toast-region", role: "region", "aria-label": msg.toastRegionLabel, children: toasts.map((t) => /* @__PURE__ */ jsx43(Toast, { kind: t.kind, onClose: () => close(t.id), style: { position: "static", transform: "none" }, children: t.message }, t.id)) })
3516
+ /* @__PURE__ */ jsx46("div", { className: "pire-toast-region", role: "region", "aria-label": msg.toastRegionLabel, children: toasts.map((t) => /* @__PURE__ */ jsx46(Toast, { kind: t.kind, onClose: () => close(t.id), style: { position: "static", transform: "none" }, children: t.message }, t.id)) })
3077
3517
  ] });
3078
3518
  }
3079
3519
  function useToast() {
3080
- const ctx = React23.useContext(ToastContext);
3520
+ const ctx = React25.useContext(ToastContext);
3081
3521
  if (!ctx) throw new Error("useToast must be used inside <ToastProvider>");
3082
3522
  return ctx;
3083
3523
  }
3084
3524
 
3085
3525
  // src/components/data/KpiTile.tsx
3086
3526
  import { Button as AriaButton14 } from "react-aria-components";
3087
- import { Fragment as Fragment4, jsx as jsx44, jsxs as jsxs36 } from "react/jsx-runtime";
3527
+ import { Fragment as Fragment7, jsx as jsx47, jsxs as jsxs38 } from "react/jsx-runtime";
3088
3528
  function KpiTile({
3089
3529
  label,
3090
3530
  value,
@@ -3100,50 +3540,50 @@ function KpiTile({
3100
3540
  style
3101
3541
  }) {
3102
3542
  const tone = deltaTone ?? (deltaDirection === "down" ? "negative" : "positive");
3103
- const body = /* @__PURE__ */ jsxs36(Fragment4, { children: [
3104
- /* @__PURE__ */ jsxs36("span", { className: "pire-kpi-label", children: [
3105
- icon ? /* @__PURE__ */ jsx44(Icon, { name: icon, size: 16 }) : null,
3543
+ const body = /* @__PURE__ */ jsxs38(Fragment7, { children: [
3544
+ /* @__PURE__ */ jsxs38("span", { className: "pire-kpi-label", children: [
3545
+ icon ? /* @__PURE__ */ jsx47(Icon, { name: icon, size: 16 }) : null,
3106
3546
  label
3107
3547
  ] }),
3108
- /* @__PURE__ */ jsxs36("span", { className: "pire-kpi-value", children: [
3548
+ /* @__PURE__ */ jsxs38("span", { className: "pire-kpi-value", children: [
3109
3549
  value,
3110
- unit ? /* @__PURE__ */ jsx44("span", { className: "pire-kpi-unit", children: unit }) : null
3550
+ unit ? /* @__PURE__ */ jsx47("span", { className: "pire-kpi-unit", children: unit }) : null
3111
3551
  ] }),
3112
- delta ? /* @__PURE__ */ jsxs36("span", { className: "pire-kpi-delta", "data-tone": tone, children: [
3113
- deltaDirection ? /* @__PURE__ */ jsx44(Icon, { name: deltaDirection === "up" ? "trending-up" : "trending-down", size: 12 }) : null,
3552
+ delta ? /* @__PURE__ */ jsxs38("span", { className: "pire-kpi-delta", "data-tone": tone, children: [
3553
+ deltaDirection ? /* @__PURE__ */ jsx47(Icon, { name: deltaDirection === "up" ? "trending-up" : "trending-down", size: 12 }) : null,
3114
3554
  delta
3115
3555
  ] }) : null,
3116
- footnote ? /* @__PURE__ */ jsx44("span", { className: "pire-kpi-foot", children: footnote }) : null
3556
+ footnote ? /* @__PURE__ */ jsx47("span", { className: "pire-kpi-foot", children: footnote }) : null
3117
3557
  ] });
3118
3558
  const props = { className: cx("pire-kpi", className), "data-status": status, style };
3119
- return onPress ? /* @__PURE__ */ jsx44(AriaButton14, { ...props, "data-pressable": "true", onPress, children: body }) : /* @__PURE__ */ jsx44("div", { ...props, children: body });
3559
+ return onPress ? /* @__PURE__ */ jsx47(AriaButton14, { ...props, "data-pressable": "true", onPress, children: body }) : /* @__PURE__ */ jsx47("div", { ...props, children: body });
3120
3560
  }
3121
3561
 
3122
3562
  // src/components/data/ObjectHeader.tsx
3123
- import { jsx as jsx45, jsxs as jsxs37 } from "react/jsx-runtime";
3563
+ import { jsx as jsx48, jsxs as jsxs39 } from "react/jsx-runtime";
3124
3564
  function ObjectHeader({ title, subtitle, id, breadcrumb, badge, facts, actions, className, ...rest }) {
3125
- return /* @__PURE__ */ jsxs37("header", { className: cx("pire-objheader", className), ...rest, children: [
3565
+ return /* @__PURE__ */ jsxs39("header", { className: cx("pire-objheader", className), ...rest, children: [
3126
3566
  breadcrumb,
3127
- /* @__PURE__ */ jsxs37("div", { className: "pire-objheader-row", children: [
3128
- /* @__PURE__ */ jsxs37("div", { style: { minWidth: 0 }, children: [
3129
- /* @__PURE__ */ jsx45("h1", { className: "pire-objheader-title", children: title }),
3130
- subtitle || id ? /* @__PURE__ */ jsxs37("div", { className: "pire-objheader-sub", children: [
3567
+ /* @__PURE__ */ jsxs39("div", { className: "pire-objheader-row", children: [
3568
+ /* @__PURE__ */ jsxs39("div", { style: { minWidth: 0 }, children: [
3569
+ /* @__PURE__ */ jsx48("h1", { className: "pire-objheader-title", children: title }),
3570
+ subtitle || id ? /* @__PURE__ */ jsxs39("div", { className: "pire-objheader-sub", children: [
3131
3571
  subtitle,
3132
- id ? /* @__PURE__ */ jsx45("span", { className: "pire-objheader-id", children: id }) : null
3572
+ id ? /* @__PURE__ */ jsx48("span", { className: "pire-objheader-id", children: id }) : null
3133
3573
  ] }) : null
3134
3574
  ] }),
3135
3575
  badge,
3136
- actions ? /* @__PURE__ */ jsx45("div", { className: "pire-objheader-actions", children: actions }) : null
3576
+ actions ? /* @__PURE__ */ jsx48("div", { className: "pire-objheader-actions", children: actions }) : null
3137
3577
  ] }),
3138
- facts?.length ? /* @__PURE__ */ jsx45("dl", { className: "pire-facts", style: { margin: 0 }, children: facts.map((fact) => /* @__PURE__ */ jsxs37("div", { children: [
3139
- /* @__PURE__ */ jsx45("dt", { className: "pire-fact-label", children: fact.label }),
3140
- /* @__PURE__ */ jsx45("dd", { className: "pire-fact-value", "data-numeric": fact.numeric ? "true" : void 0, style: { margin: 0 }, children: fact.value })
3578
+ facts?.length ? /* @__PURE__ */ jsx48("dl", { className: "pire-facts", style: { margin: 0 }, children: facts.map((fact) => /* @__PURE__ */ jsxs39("div", { children: [
3579
+ /* @__PURE__ */ jsx48("dt", { className: "pire-fact-label", children: fact.label }),
3580
+ /* @__PURE__ */ jsx48("dd", { className: "pire-fact-value", "data-numeric": fact.numeric ? "true" : void 0, style: { margin: 0 }, children: fact.value })
3141
3581
  ] }, fact.label)) }) : null
3142
3582
  ] });
3143
3583
  }
3144
3584
 
3145
3585
  // src/components/data/FilterBar.tsx
3146
- import { jsx as jsx46, jsxs as jsxs38 } from "react/jsx-runtime";
3586
+ import { jsx as jsx49, jsxs as jsxs40 } from "react/jsx-runtime";
3147
3587
  function FilterBar({
3148
3588
  children,
3149
3589
  activeFilters = [],
@@ -3160,49 +3600,49 @@ function FilterBar({
3160
3600
  const label = useMessage("filterBarLabel", rest["aria-label"]);
3161
3601
  const go = useMessage("filterBarGo", goLabel);
3162
3602
  const clearAll = useMessage("filterBarClearAll", clearAllLabel);
3163
- return /* @__PURE__ */ jsxs38("section", { className: cx("pire-filterbar", className), ...rest, "aria-label": label, children: [
3164
- /* @__PURE__ */ jsxs38("div", { className: "pire-filterbar-controls", children: [
3603
+ return /* @__PURE__ */ jsxs40("section", { className: cx("pire-filterbar", className), ...rest, "aria-label": label, children: [
3604
+ /* @__PURE__ */ jsxs40("div", { className: "pire-filterbar-controls", children: [
3165
3605
  children,
3166
- onGo ? /* @__PURE__ */ jsx46(Button, { variant: "primary", onPress: onGo, children: go }) : null
3606
+ onGo ? /* @__PURE__ */ jsx49(Button, { variant: "primary", onPress: onGo, children: go }) : null
3167
3607
  ] }),
3168
- activeFilters.length || resultLabel || actions ? /* @__PURE__ */ jsxs38("div", { className: "pire-filterbar-foot", children: [
3169
- activeFilters.map((filter) => /* @__PURE__ */ jsx46(Tag, { onRemove: onRemoveFilter ? () => onRemoveFilter(filter.id) : void 0, children: filter.label }, filter.id)),
3170
- activeFilters.length && onClear ? /* @__PURE__ */ jsx46(Button, { variant: "tertiary", size: "sm", onPress: onClear, children: clearAll }) : null,
3171
- resultLabel ? /* @__PURE__ */ jsx46("span", { className: "pire-filterbar-result", "aria-live": "polite", children: resultLabel }) : null,
3172
- actions ? /* @__PURE__ */ jsx46("div", { className: "pire-filterbar-actions", children: actions }) : null
3608
+ activeFilters.length || resultLabel || actions ? /* @__PURE__ */ jsxs40("div", { className: "pire-filterbar-foot", children: [
3609
+ activeFilters.map((filter) => /* @__PURE__ */ jsx49(Tag, { onRemove: onRemoveFilter ? () => onRemoveFilter(filter.id) : void 0, children: filter.label }, filter.id)),
3610
+ activeFilters.length && onClear ? /* @__PURE__ */ jsx49(Button, { variant: "tertiary", size: "sm", onPress: onClear, children: clearAll }) : null,
3611
+ resultLabel ? /* @__PURE__ */ jsx49("span", { className: "pire-filterbar-result", "aria-live": "polite", children: resultLabel }) : null,
3612
+ actions ? /* @__PURE__ */ jsx49("div", { className: "pire-filterbar-actions", children: actions }) : null
3173
3613
  ] }) : null
3174
3614
  ] });
3175
3615
  }
3176
3616
 
3177
3617
  // src/components/data/DescriptionList.tsx
3178
- import { jsx as jsx47, jsxs as jsxs39 } from "react/jsx-runtime";
3618
+ import { jsx as jsx50, jsxs as jsxs41 } from "react/jsx-runtime";
3179
3619
  function DescriptionList({ items, layout = "rows", columns = 3, className, style, ...rest }) {
3180
- return /* @__PURE__ */ jsx47(
3620
+ return /* @__PURE__ */ jsx50(
3181
3621
  "dl",
3182
3622
  {
3183
3623
  className: cx("pire-dl", className),
3184
3624
  "data-layout": layout,
3185
3625
  style: { ...layout === "grid" ? { "--pire-dl-cols": columns } : null, ...style },
3186
3626
  ...rest,
3187
- children: items.map((item, i) => /* @__PURE__ */ jsxs39("div", { className: "pire-dl-row", "data-emphasis": item.emphasis ? "true" : void 0, children: [
3188
- /* @__PURE__ */ jsxs39("dt", { className: "pire-dl-term", children: [
3627
+ children: items.map((item, i) => /* @__PURE__ */ jsxs41("div", { className: "pire-dl-row", "data-emphasis": item.emphasis ? "true" : void 0, children: [
3628
+ /* @__PURE__ */ jsxs41("dt", { className: "pire-dl-term", children: [
3189
3629
  item.label,
3190
3630
  item.hint
3191
3631
  ] }),
3192
- /* @__PURE__ */ jsx47("dd", { className: "pire-dl-value", "data-numeric": item.numeric ? "true" : void 0, children: item.value })
3632
+ /* @__PURE__ */ jsx50("dd", { className: "pire-dl-value", "data-numeric": item.numeric ? "true" : void 0, children: item.value })
3193
3633
  ] }, i))
3194
3634
  }
3195
3635
  );
3196
3636
  }
3197
3637
 
3198
3638
  // src/components/data/Timeline.tsx
3199
- import { jsx as jsx48, jsxs as jsxs40 } from "react/jsx-runtime";
3639
+ import { jsx as jsx51, jsxs as jsxs42 } from "react/jsx-runtime";
3200
3640
  function Timeline({ entries, reverse = false, className, ...rest }) {
3201
3641
  const list = reverse ? [...entries].reverse() : entries;
3202
- return /* @__PURE__ */ jsx48("ol", { className: cx("pire-timeline", className), ...rest, children: list.map((entry, i) => /* @__PURE__ */ jsxs40("li", { className: "pire-timeline-item", children: [
3203
- /* @__PURE__ */ jsx48("span", { className: "pire-timeline-time", children: entry.time }),
3204
- /* @__PURE__ */ jsx48("span", { className: "pire-timeline-text", children: entry.event }),
3205
- entry.actor ? /* @__PURE__ */ jsx48("span", { className: "pire-timeline-actor", children: entry.actor }) : null
3642
+ return /* @__PURE__ */ jsx51("ol", { className: cx("pire-timeline", className), ...rest, children: list.map((entry, i) => /* @__PURE__ */ jsxs42("li", { className: "pire-timeline-item", children: [
3643
+ /* @__PURE__ */ jsx51("span", { className: "pire-timeline-time", children: entry.time }),
3644
+ /* @__PURE__ */ jsx51("span", { className: "pire-timeline-text", children: entry.event }),
3645
+ entry.actor ? /* @__PURE__ */ jsx51("span", { className: "pire-timeline-actor", children: entry.actor }) : null
3206
3646
  ] }, entry.id ?? i)) });
3207
3647
  }
3208
3648
 
@@ -3248,10 +3688,10 @@ function seriesColor(series, index) {
3248
3688
  const slot = series.colorIndex ?? index + 1;
3249
3689
  return slot >= 1 && slot <= VIZ_SLOT_COUNT ? `var(--viz-${slot})` : "var(--viz-other)";
3250
3690
  }
3251
- var IS_DEV2 = process.env.NODE_ENV !== "production";
3691
+ var IS_DEV3 = process.env.NODE_ENV !== "production";
3252
3692
  var warnedCharts = /* @__PURE__ */ new Set();
3253
3693
  function warnOnSlotOverflow(series, chartLabel) {
3254
- if (!IS_DEV2 || warnedCharts.has(chartLabel)) return;
3694
+ if (!IS_DEV3 || warnedCharts.has(chartLabel)) return;
3255
3695
  if (series.length <= VIZ_SLOT_COUNT) return;
3256
3696
  warnedCharts.add(chartLabel);
3257
3697
  console.warn(
@@ -3259,7 +3699,7 @@ function warnOnSlotOverflow(series, chartLabel) {
3259
3699
  );
3260
3700
  }
3261
3701
  function warnOnDonutShape(series, categoryCount, chartLabel) {
3262
- if (!IS_DEV2 || warnedCharts.has(`donut:${chartLabel}`)) return;
3702
+ if (!IS_DEV3 || warnedCharts.has(`donut:${chartLabel}`)) return;
3263
3703
  const complaints = [];
3264
3704
  if (series.length > 1) {
3265
3705
  complaints.push(`it has ${series.length} series but a donut draws one \u2014 the rest are ignored`);
@@ -3285,7 +3725,7 @@ function alignToCategories(series, categoryCount) {
3285
3725
  }
3286
3726
 
3287
3727
  // src/components/data/ChartFrame.tsx
3288
- import { jsx as jsx49, jsxs as jsxs41 } from "react/jsx-runtime";
3728
+ import { jsx as jsx52, jsxs as jsxs43 } from "react/jsx-runtime";
3289
3729
  function seriesLegend(series) {
3290
3730
  return series.map((one, index) => ({
3291
3731
  key: one.id,
@@ -3308,29 +3748,29 @@ function ChartFrame({
3308
3748
  children
3309
3749
  }) {
3310
3750
  const msg = usePireMessages();
3311
- return /* @__PURE__ */ jsxs41("figure", { className: cx("pire-chart", className), style, children: [
3312
- title || description ? /* @__PURE__ */ jsxs41("figcaption", { className: "pire-chart-head", children: [
3313
- title ? /* @__PURE__ */ jsx49("span", { className: "pire-chart-title", children: title }) : null,
3314
- description ? /* @__PURE__ */ jsx49("span", { className: "pire-chart-desc", children: description }) : null
3751
+ return /* @__PURE__ */ jsxs43("figure", { className: cx("pire-chart", className), style, children: [
3752
+ title || description ? /* @__PURE__ */ jsxs43("figcaption", { className: "pire-chart-head", children: [
3753
+ title ? /* @__PURE__ */ jsx52("span", { className: "pire-chart-title", children: title }) : null,
3754
+ description ? /* @__PURE__ */ jsx52("span", { className: "pire-chart-desc", children: description }) : null
3315
3755
  ] }) : null,
3316
- legend && legend.length > 1 ? /* @__PURE__ */ jsx49("ul", { className: "pire-chart-legend", children: legend.map((item) => /* @__PURE__ */ jsxs41("li", { className: "pire-chart-legend-item", children: [
3317
- /* @__PURE__ */ jsx49("span", { className: "pire-chart-swatch", style: { background: item.color } }),
3756
+ legend && legend.length > 1 ? /* @__PURE__ */ jsx52("ul", { className: "pire-chart-legend", children: legend.map((item) => /* @__PURE__ */ jsxs43("li", { className: "pire-chart-legend-item", children: [
3757
+ /* @__PURE__ */ jsx52("span", { className: "pire-chart-swatch", style: { background: item.color } }),
3318
3758
  item.label
3319
3759
  ] }, item.key)) }) : null,
3320
- /* @__PURE__ */ jsx49("div", { className: "pire-chart-plot", "aria-hidden": "true", children }),
3321
- /* @__PURE__ */ jsx49("div", { className: showDataTable ? "pire-chart-table" : "pire-sr-only", children: /* @__PURE__ */ jsxs41("table", { children: [
3322
- /* @__PURE__ */ jsx49("caption", { children: label }),
3323
- /* @__PURE__ */ jsx49("thead", { children: /* @__PURE__ */ jsxs41("tr", { children: [
3324
- /* @__PURE__ */ jsx49("th", { scope: "col", children: msg.chartCategoryHeader }),
3325
- series.map((one) => /* @__PURE__ */ jsx49("th", { scope: "col", children: one.label }, one.id))
3760
+ /* @__PURE__ */ jsx52("div", { className: "pire-chart-plot", "aria-hidden": "true", children }),
3761
+ /* @__PURE__ */ jsx52("div", { className: showDataTable ? "pire-chart-table" : "pire-sr-only", children: /* @__PURE__ */ jsxs43("table", { children: [
3762
+ /* @__PURE__ */ jsx52("caption", { children: label }),
3763
+ /* @__PURE__ */ jsx52("thead", { children: /* @__PURE__ */ jsxs43("tr", { children: [
3764
+ /* @__PURE__ */ jsx52("th", { scope: "col", children: msg.chartCategoryHeader }),
3765
+ series.map((one) => /* @__PURE__ */ jsx52("th", { scope: "col", children: one.label }, one.id))
3326
3766
  ] }) }),
3327
- /* @__PURE__ */ jsx49("tbody", { children: categories.map((category, categoryIndex) => (
3767
+ /* @__PURE__ */ jsx52("tbody", { children: categories.map((category, categoryIndex) => (
3328
3768
  // biome-ignore lint/suspicious/noArrayIndexKey: categories are positional and repeat legitimately (two quarters both labelled "Q1").
3329
- /* @__PURE__ */ jsxs41("tr", { children: [
3330
- /* @__PURE__ */ jsx49("th", { scope: "row", children: category }),
3769
+ /* @__PURE__ */ jsxs43("tr", { children: [
3770
+ /* @__PURE__ */ jsx52("th", { scope: "row", children: category }),
3331
3771
  series.map((one) => {
3332
3772
  const value = one.values[categoryIndex];
3333
- return /* @__PURE__ */ jsx49("td", { children: value == null ? msg.chartNoValue : formatValue(value) }, one.id);
3773
+ return /* @__PURE__ */ jsx52("td", { children: value == null ? msg.chartNoValue : formatValue(value) }, one.id);
3334
3774
  })
3335
3775
  ] }, categoryIndex)
3336
3776
  )) })
@@ -3339,7 +3779,7 @@ function ChartFrame({
3339
3779
  }
3340
3780
 
3341
3781
  // src/components/data/BarChart.tsx
3342
- import { jsx as jsx50, jsxs as jsxs42 } from "react/jsx-runtime";
3782
+ import { jsx as jsx53, jsxs as jsxs44 } from "react/jsx-runtime";
3343
3783
  function BarChart({
3344
3784
  categories,
3345
3785
  series: rawSeries,
@@ -3371,7 +3811,7 @@ function BarChart({
3371
3811
  const value = series[0].values[categoryIndex];
3372
3812
  return value == null ? msg.chartNoValue : formatValue(value);
3373
3813
  };
3374
- return /* @__PURE__ */ jsx50(
3814
+ return /* @__PURE__ */ jsx53(
3375
3815
  ChartFrame,
3376
3816
  {
3377
3817
  label,
@@ -3384,7 +3824,7 @@ function BarChart({
3384
3824
  showDataTable,
3385
3825
  className,
3386
3826
  style,
3387
- children: !hasData ? /* @__PURE__ */ jsx50("div", { className: "pire-chart-empty", children: emptyState ?? msg.chartEmpty }) : /* @__PURE__ */ jsx50(
3827
+ children: !hasData ? /* @__PURE__ */ jsx53("div", { className: "pire-chart-empty", children: emptyState ?? msg.chartEmpty }) : /* @__PURE__ */ jsx53(
3388
3828
  "div",
3389
3829
  {
3390
3830
  className: "pire-chart-bars",
@@ -3393,12 +3833,12 @@ function BarChart({
3393
3833
  style: { "--pire-chart-height": `${height}px` },
3394
3834
  children: categories.map((category, categoryIndex) => (
3395
3835
  // biome-ignore lint/suspicious/noArrayIndexKey: categories are positional and repeat legitimately (two quarters both labelled "Q1").
3396
- /* @__PURE__ */ jsxs42("div", { className: "pire-chart-group", children: [
3397
- /* @__PURE__ */ jsx50("span", { className: "pire-chart-cat", children: category }),
3398
- /* @__PURE__ */ jsx50("div", { className: "pire-chart-track", children: series.map((one, seriesIndex) => {
3836
+ /* @__PURE__ */ jsxs44("div", { className: "pire-chart-group", children: [
3837
+ /* @__PURE__ */ jsx53("span", { className: "pire-chart-cat", children: category }),
3838
+ /* @__PURE__ */ jsx53("div", { className: "pire-chart-track", children: series.map((one, seriesIndex) => {
3399
3839
  const value = one.values[categoryIndex];
3400
3840
  if (value == null) return null;
3401
- return /* @__PURE__ */ jsxs42(
3841
+ return /* @__PURE__ */ jsxs44(
3402
3842
  "div",
3403
3843
  {
3404
3844
  className: "pire-chart-bar",
@@ -3407,8 +3847,8 @@ function BarChart({
3407
3847
  "--pire-bar-color": seriesColor(one, seriesIndex)
3408
3848
  },
3409
3849
  children: [
3410
- withValues && orientation === "vertical" ? /* @__PURE__ */ jsx50("span", { className: "pire-chart-barval", children: formatValue(value) }) : null,
3411
- /* @__PURE__ */ jsxs42("span", { className: "pire-chart-tip", role: "presentation", children: [
3850
+ withValues && orientation === "vertical" ? /* @__PURE__ */ jsx53("span", { className: "pire-chart-barval", children: formatValue(value) }) : null,
3851
+ /* @__PURE__ */ jsxs44("span", { className: "pire-chart-tip", role: "presentation", children: [
3412
3852
  series.length > 1 ? `${one.label}: ` : "",
3413
3853
  formatValue(value)
3414
3854
  ] })
@@ -3417,7 +3857,7 @@ function BarChart({
3417
3857
  one.id
3418
3858
  );
3419
3859
  }) }),
3420
- withValues && orientation === "horizontal" ? /* @__PURE__ */ jsx50("span", { className: "pire-chart-val", children: horizontalLabelFor(categoryIndex) }) : null
3860
+ withValues && orientation === "horizontal" ? /* @__PURE__ */ jsx53("span", { className: "pire-chart-val", children: horizontalLabelFor(categoryIndex) }) : null
3421
3861
  ] }, categoryIndex)
3422
3862
  ))
3423
3863
  }
@@ -3427,14 +3867,14 @@ function BarChart({
3427
3867
  }
3428
3868
 
3429
3869
  // src/components/data/LineChart.tsx
3430
- import * as React24 from "react";
3431
- import { jsx as jsx51, jsxs as jsxs43 } from "react/jsx-runtime";
3870
+ import * as React26 from "react";
3871
+ import { jsx as jsx54, jsxs as jsxs45 } from "react/jsx-runtime";
3432
3872
  var PLOT_INSET = { top: 10, right: 14, bottom: 24, left: 58 };
3433
3873
  var MARKER_LIMIT = 20;
3434
- var useIsomorphicLayoutEffect2 = typeof window === "undefined" ? React24.useEffect : React24.useLayoutEffect;
3874
+ var useIsomorphicLayoutEffect2 = typeof window === "undefined" ? React26.useEffect : React26.useLayoutEffect;
3435
3875
  function useMeasuredWidth() {
3436
- const ref = React24.useRef(null);
3437
- const [width, setWidth] = React24.useState(0);
3876
+ const ref = React26.useRef(null);
3877
+ const [width, setWidth] = React26.useState(0);
3438
3878
  useIsomorphicLayoutEffect2(() => {
3439
3879
  const element = ref.current;
3440
3880
  if (!element) return;
@@ -3495,7 +3935,7 @@ function LineChart({
3495
3935
  return `M${xAt(present[0].index)} ${baseline} L${line} L${xAt(last.index)} ${baseline} Z`;
3496
3936
  };
3497
3937
  const labelEvery = Math.max(1, Math.ceil(categories.length / Math.max(2, Math.floor(innerWidth / 64))));
3498
- return /* @__PURE__ */ jsx51(
3938
+ return /* @__PURE__ */ jsx54(
3499
3939
  ChartFrame,
3500
3940
  {
3501
3941
  label,
@@ -3508,8 +3948,8 @@ function LineChart({
3508
3948
  showDataTable,
3509
3949
  className,
3510
3950
  style,
3511
- children: !hasData ? /* @__PURE__ */ jsx51("div", { className: "pire-chart-empty", children: emptyState ?? msg.chartEmpty }) : /* @__PURE__ */ jsxs43("div", { className: "pire-chart-lines", ref: plotRef, style: { height }, children: [
3512
- width > 0 ? /* @__PURE__ */ jsxs43(
3951
+ children: !hasData ? /* @__PURE__ */ jsx54("div", { className: "pire-chart-empty", children: emptyState ?? msg.chartEmpty }) : /* @__PURE__ */ jsxs45("div", { className: "pire-chart-lines", ref: plotRef, style: { height }, children: [
3952
+ width > 0 ? /* @__PURE__ */ jsxs45(
3513
3953
  "svg",
3514
3954
  {
3515
3955
  width,
@@ -3518,7 +3958,7 @@ function LineChart({
3518
3958
  "aria-hidden": "true",
3519
3959
  focusable: "false",
3520
3960
  children: [
3521
- /* @__PURE__ */ jsx51("g", { className: "pire-chart-grid", children: scale.ticks.map((tick) => /* @__PURE__ */ jsx51(
3961
+ /* @__PURE__ */ jsx54("g", { className: "pire-chart-grid", children: scale.ticks.map((tick) => /* @__PURE__ */ jsx54(
3522
3962
  "line",
3523
3963
  {
3524
3964
  x1: PLOT_INSET.left,
@@ -3528,8 +3968,8 @@ function LineChart({
3528
3968
  },
3529
3969
  tick
3530
3970
  )) }),
3531
- /* @__PURE__ */ jsxs43("g", { className: "pire-chart-tick", children: [
3532
- scale.ticks.map((tick) => /* @__PURE__ */ jsx51(
3971
+ /* @__PURE__ */ jsxs45("g", { className: "pire-chart-tick", children: [
3972
+ scale.ticks.map((tick) => /* @__PURE__ */ jsx54(
3533
3973
  "text",
3534
3974
  {
3535
3975
  x: PLOT_INSET.left - 8,
@@ -3542,10 +3982,10 @@ function LineChart({
3542
3982
  )),
3543
3983
  categories.map((category, index) => index % labelEvery === 0 ? (
3544
3984
  // biome-ignore lint/suspicious/noArrayIndexKey: categories are positional and repeat legitimately (two quarters both labelled "Q1").
3545
- /* @__PURE__ */ jsx51("text", { x: xAt(index), y: height - 6, textAnchor: "middle", children: category }, index)
3985
+ /* @__PURE__ */ jsx54("text", { x: xAt(index), y: height - 6, textAnchor: "middle", children: category }, index)
3546
3986
  ) : null)
3547
3987
  ] }),
3548
- showArea && series[0] ? /* @__PURE__ */ jsx51(
3988
+ showArea && series[0] ? /* @__PURE__ */ jsx54(
3549
3989
  "path",
3550
3990
  {
3551
3991
  d: areaFor(series[0].values),
@@ -3553,10 +3993,10 @@ function LineChart({
3553
3993
  style: { fill: seriesColor(series[0], 0) }
3554
3994
  }
3555
3995
  ) : null,
3556
- /* @__PURE__ */ jsx51("g", { className: "pire-chart-line", fill: "none", children: series.map((one, index) => /* @__PURE__ */ jsx51("path", { d: pathFor(one.values), stroke: seriesColor(one, index) }, one.id)) }),
3557
- withMarkers ? /* @__PURE__ */ jsx51("g", { className: "pire-chart-marker", children: series.map((one, seriesIndex) => one.values.map((value, index) => value == null ? null : (
3996
+ /* @__PURE__ */ jsx54("g", { className: "pire-chart-line", fill: "none", children: series.map((one, index) => /* @__PURE__ */ jsx54("path", { d: pathFor(one.values), stroke: seriesColor(one, index) }, one.id)) }),
3997
+ withMarkers ? /* @__PURE__ */ jsx54("g", { className: "pire-chart-marker", children: series.map((one, seriesIndex) => one.values.map((value, index) => value == null ? null : (
3558
3998
  // biome-ignore lint/suspicious/noArrayIndexKey: a series is positional — the index is the point's identity, and category labels repeat.
3559
- /* @__PURE__ */ jsx51(
3999
+ /* @__PURE__ */ jsx54(
3560
4000
  "circle",
3561
4001
  {
3562
4002
  cx: xAt(index),
@@ -3570,18 +4010,18 @@ function LineChart({
3570
4010
  ]
3571
4011
  }
3572
4012
  ) : null,
3573
- /* @__PURE__ */ jsx51(
4013
+ /* @__PURE__ */ jsx54(
3574
4014
  "div",
3575
4015
  {
3576
4016
  className: "pire-chart-hover",
3577
4017
  style: { inset: `${PLOT_INSET.top}px ${PLOT_INSET.right}px ${PLOT_INSET.bottom}px ${PLOT_INSET.left}px` },
3578
4018
  children: categories.map((category, categoryIndex) => (
3579
4019
  // biome-ignore lint/suspicious/noArrayIndexKey: categories are positional and repeat legitimately (two quarters both labelled "Q1").
3580
- /* @__PURE__ */ jsx51("div", { className: "pire-chart-band", children: /* @__PURE__ */ jsxs43("span", { className: "pire-chart-tip", role: "presentation", children: [
3581
- /* @__PURE__ */ jsx51("strong", { children: category }),
4020
+ /* @__PURE__ */ jsx54("div", { className: "pire-chart-band", children: /* @__PURE__ */ jsxs45("span", { className: "pire-chart-tip", role: "presentation", children: [
4021
+ /* @__PURE__ */ jsx54("strong", { children: category }),
3582
4022
  series.map((one) => {
3583
4023
  const value = one.values[categoryIndex];
3584
- return /* @__PURE__ */ jsxs43("span", { className: "pire-chart-tip-row", children: [
4024
+ return /* @__PURE__ */ jsxs45("span", { className: "pire-chart-tip-row", children: [
3585
4025
  one.label,
3586
4026
  ": ",
3587
4027
  value == null ? "No data" : formatValue(value)
@@ -3597,8 +4037,8 @@ function LineChart({
3597
4037
  }
3598
4038
 
3599
4039
  // src/components/data/DonutChart.tsx
3600
- import * as React25 from "react";
3601
- import { jsx as jsx52, jsxs as jsxs44 } from "react/jsx-runtime";
4040
+ import * as React27 from "react";
4041
+ import { jsx as jsx55, jsxs as jsxs46 } from "react/jsx-runtime";
3602
4042
  var SEGMENT_GAP_DEGREES = 1.5;
3603
4043
  function DonutChart({
3604
4044
  categories,
@@ -3618,7 +4058,7 @@ function DonutChart({
3618
4058
  }) {
3619
4059
  const label = rest["aria-label"];
3620
4060
  const msg = usePireMessages();
3621
- const [hoveredIndex, setHoveredIndex] = React25.useState(null);
4061
+ const [hoveredIndex, setHoveredIndex] = React27.useState(null);
3622
4062
  warnOnDonutShape(series, categories.length, label);
3623
4063
  const values = (series[0]?.values ?? []).slice(0, categories.length);
3624
4064
  const segments = categories.map((category, index) => ({ category, index, value: values[index] ?? 0 })).filter((segment) => segment.value > 0);
@@ -3635,7 +4075,7 @@ function DonutChart({
3635
4075
  }));
3636
4076
  const hovered = hoveredIndex == null ? null : segments.find((segment) => segment.index === hoveredIndex) ?? null;
3637
4077
  let arcStart = 0;
3638
- return /* @__PURE__ */ jsx52(
4078
+ return /* @__PURE__ */ jsx55(
3639
4079
  ChartFrame,
3640
4080
  {
3641
4081
  label,
@@ -3648,8 +4088,8 @@ function DonutChart({
3648
4088
  showDataTable,
3649
4089
  className,
3650
4090
  style,
3651
- children: !hasData ? /* @__PURE__ */ jsx52("div", { className: "pire-chart-empty", children: emptyState ?? msg.chartEmpty }) : /* @__PURE__ */ jsxs44("div", { className: "pire-chart-donut", style: { height: size }, children: [
3652
- /* @__PURE__ */ jsx52(
4091
+ children: !hasData ? /* @__PURE__ */ jsx55("div", { className: "pire-chart-empty", children: emptyState ?? msg.chartEmpty }) : /* @__PURE__ */ jsxs46("div", { className: "pire-chart-donut", style: { height: size }, children: [
4092
+ /* @__PURE__ */ jsx55(
3653
4093
  "svg",
3654
4094
  {
3655
4095
  width: size,
@@ -3657,13 +4097,13 @@ function DonutChart({
3657
4097
  "aria-hidden": "true",
3658
4098
  focusable: "false",
3659
4099
  onMouseLeave: () => setHoveredIndex(null),
3660
- children: /* @__PURE__ */ jsx52("g", { transform: `rotate(-90 ${size / 2} ${size / 2})`, children: segments.map((segment) => {
4100
+ children: /* @__PURE__ */ jsx55("g", { transform: `rotate(-90 ${size / 2} ${size / 2})`, children: segments.map((segment) => {
3661
4101
  const arcLength = segment.value / total * circumference;
3662
4102
  const offset = arcStart;
3663
4103
  arcStart += arcLength;
3664
4104
  return (
3665
4105
  // biome-ignore lint/a11y/noStaticElementInteractions: pointer-only enhancement inside an aria-hidden plot — the arcs carry nothing the data table does not, so there is nothing here for a keyboard to reach.
3666
- /* @__PURE__ */ jsx52(
4106
+ /* @__PURE__ */ jsx55(
3667
4107
  "circle",
3668
4108
  {
3669
4109
  className: "pire-chart-arc",
@@ -3683,9 +4123,9 @@ function DonutChart({
3683
4123
  }) })
3684
4124
  }
3685
4125
  ),
3686
- /* @__PURE__ */ jsxs44("div", { className: "pire-chart-donut-center", style: { width: size - thickness * 2 - 8 }, children: [
3687
- /* @__PURE__ */ jsx52("span", { className: "pire-chart-donut-value", children: hovered ? formatValue(hovered.value) : centerLabel ?? formatValue(total) }),
3688
- /* @__PURE__ */ jsx52("span", { className: "pire-chart-donut-caption", children: hovered ? hovered.category : centerCaption })
4126
+ /* @__PURE__ */ jsxs46("div", { className: "pire-chart-donut-center", style: { width: size - thickness * 2 - 8 }, children: [
4127
+ /* @__PURE__ */ jsx55("span", { className: "pire-chart-donut-value", children: hovered ? formatValue(hovered.value) : centerLabel ?? formatValue(total) }),
4128
+ /* @__PURE__ */ jsx55("span", { className: "pire-chart-donut-caption", children: hovered ? hovered.category : centerCaption })
3689
4129
  ] })
3690
4130
  ] })
3691
4131
  }
@@ -3697,14 +4137,14 @@ function colorForSegment(index) {
3697
4137
 
3698
4138
  // src/components/data/LinkList.tsx
3699
4139
  import { Button as AriaButton15 } from "react-aria-components";
3700
- import { jsx as jsx53, jsxs as jsxs45 } from "react/jsx-runtime";
4140
+ import { jsx as jsx56, jsxs as jsxs47 } from "react/jsx-runtime";
3701
4141
  function LinkList({ items, onSelect, emphasis = "key", className, ...rest }) {
3702
- return /* @__PURE__ */ jsx53("div", { className: cx("pire-linklist", className), role: "list", "data-emphasis": emphasis, ...rest, children: items.map((item) => {
3703
- const keySlot = item.key ? /* @__PURE__ */ jsx53("span", { className: "pire-linklist-key", children: item.key }) : null;
3704
- const textSlot = item.text ? /* @__PURE__ */ jsx53("span", { className: "pire-linklist-text", children: item.text }) : null;
4142
+ return /* @__PURE__ */ jsx56("div", { className: cx("pire-linklist", className), role: "list", "data-emphasis": emphasis, ...rest, children: items.map((item) => {
4143
+ const keySlot = item.key ? /* @__PURE__ */ jsx56("span", { className: "pire-linklist-key", children: item.key }) : null;
4144
+ const textSlot = item.text ? /* @__PURE__ */ jsx56("span", { className: "pire-linklist-text", children: item.text }) : null;
3705
4145
  const [first, second] = emphasis === "text" ? [textSlot, keySlot] : [keySlot, textSlot];
3706
- return /* @__PURE__ */ jsx53("div", { role: "listitem", className: "pire-linklist-row", children: /* @__PURE__ */ jsxs45(AriaButton15, { className: "pire-linklist-item", onPress: () => onSelect?.(item.id), children: [
3707
- item.icon ? /* @__PURE__ */ jsx53(Icon, { name: item.icon, size: 16, style: { color: "var(--text-secondary)" } }) : null,
4146
+ return /* @__PURE__ */ jsx56("div", { role: "listitem", className: "pire-linklist-row", children: /* @__PURE__ */ jsxs47(AriaButton15, { className: "pire-linklist-item", onPress: () => onSelect?.(item.id), children: [
4147
+ item.icon ? /* @__PURE__ */ jsx56(Icon, { name: item.icon, size: 16, style: { color: "var(--text-secondary)" } }) : null,
3708
4148
  first,
3709
4149
  second,
3710
4150
  item.trailing
@@ -3712,8 +4152,73 @@ function LinkList({ items, onSelect, emphasis = "key", className, ...rest }) {
3712
4152
  }) });
3713
4153
  }
3714
4154
 
4155
+ // src/components/data/RecordCard.tsx
4156
+ import { jsx as jsx57, jsxs as jsxs48 } from "react/jsx-runtime";
4157
+ function RecordCard({ title, subtitle, icon, action, isDisabled, className, ...rest }) {
4158
+ return /* @__PURE__ */ jsxs48("div", { className: cx("pire-recordcard", className), "data-disabled": isDisabled ? "true" : void 0, ...rest, children: [
4159
+ icon ? /* @__PURE__ */ jsx57("span", { className: "pire-recordcard-tile", "aria-hidden": "true", children: /* @__PURE__ */ jsx57(Icon, { name: icon, size: 20 }) }) : null,
4160
+ /* @__PURE__ */ jsxs48("span", { className: "pire-recordcard-body", children: [
4161
+ /* @__PURE__ */ jsx57("span", { className: "pire-recordcard-title", children: title }),
4162
+ subtitle ? /* @__PURE__ */ jsx57("span", { className: "pire-recordcard-sub", children: subtitle }) : null
4163
+ ] }),
4164
+ action ? /* @__PURE__ */ jsx57("span", { className: "pire-recordcard-action", children: action }) : null
4165
+ ] });
4166
+ }
4167
+
4168
+ // src/components/data/ViewSwitcher.tsx
4169
+ import { Button as AriaButton16 } from "react-aria-components";
4170
+ import { jsx as jsx58, jsxs as jsxs49 } from "react/jsx-runtime";
4171
+ function ViewSwitcher({
4172
+ name,
4173
+ isDirty,
4174
+ icon = "star",
4175
+ onPress,
4176
+ isDisabled,
4177
+ "aria-label": ariaLabel,
4178
+ className,
4179
+ style
4180
+ }) {
4181
+ const msg = usePireMessages();
4182
+ const label = ariaLabel ?? (isDirty ? msg.viewSwitcherNameModified.replace("{view}", name) : msg.viewSwitcherName.replace("{view}", name));
4183
+ return /* @__PURE__ */ jsxs49(
4184
+ AriaButton16,
4185
+ {
4186
+ className: cx("pire-viewswitcher", className),
4187
+ style,
4188
+ "aria-label": label,
4189
+ isDisabled,
4190
+ onPress,
4191
+ children: [
4192
+ /* @__PURE__ */ jsx58(Icon, { name: icon, size: 16 }),
4193
+ /* @__PURE__ */ jsx58("span", { className: "pire-viewswitcher-name", children: name }),
4194
+ isDirty ? /* @__PURE__ */ jsx58("span", { className: "pire-viewswitcher-dirty", "aria-hidden": "true", children: msg.viewSwitcherModifiedMark }) : null,
4195
+ /* @__PURE__ */ jsx58(Icon, { name: "chevron-down", size: 16 })
4196
+ ]
4197
+ }
4198
+ );
4199
+ }
4200
+
4201
+ // src/components/data/BarList.tsx
4202
+ import { jsx as jsx59, jsxs as jsxs50 } from "react/jsx-runtime";
4203
+ function BarList({ items, max, className, ...rest }) {
4204
+ const scale = max ?? Math.max(0, ...items.map((i) => i.value));
4205
+ return /* @__PURE__ */ jsx59("ul", { ...rest, className: cx("pire-barlist", className), children: items.map((item) => {
4206
+ const pct = scale > 0 ? Math.max(0, Math.min(100, item.value / scale * 100)) : 0;
4207
+ return /* @__PURE__ */ jsxs50("li", { className: "pire-barlist-row", "data-tone": item.tone, children: [
4208
+ /* @__PURE__ */ jsxs50("span", { className: "pire-barlist-main", children: [
4209
+ /* @__PURE__ */ jsx59("span", { className: "pire-barlist-label", children: item.label }),
4210
+ /* @__PURE__ */ jsx59("span", { className: "pire-barlist-track", "aria-hidden": "true", children: /* @__PURE__ */ jsx59("span", { className: "pire-barlist-fill", style: { width: `${pct}%` } }) })
4211
+ ] }),
4212
+ /* @__PURE__ */ jsxs50("span", { className: "pire-barlist-figure", children: [
4213
+ /* @__PURE__ */ jsx59("span", { className: "pire-barlist-value", children: item.valueLabel ?? String(item.value) }),
4214
+ item.hint ? /* @__PURE__ */ jsx59("span", { className: "pire-barlist-hint", children: item.hint }) : null
4215
+ ] })
4216
+ ] }, item.id);
4217
+ }) });
4218
+ }
4219
+
3715
4220
  // src/components/layout/PageBand.tsx
3716
- import { jsx as jsx54 } from "react/jsx-runtime";
4221
+ import { jsx as jsx60 } from "react/jsx-runtime";
3717
4222
  function PageBand({
3718
4223
  surface = "card",
3719
4224
  hasBorder = true,
@@ -3721,7 +4226,7 @@ function PageBand({
3721
4226
  className,
3722
4227
  ...rest
3723
4228
  }) {
3724
- return /* @__PURE__ */ jsx54(
4229
+ return /* @__PURE__ */ jsx60(
3725
4230
  "div",
3726
4231
  {
3727
4232
  className: cx("pire-pageband", className),
@@ -3734,56 +4239,56 @@ function PageBand({
3734
4239
  }
3735
4240
 
3736
4241
  // src/components/layout/PageHeader.tsx
3737
- import { jsx as jsx55, jsxs as jsxs46 } from "react/jsx-runtime";
4242
+ import { jsx as jsx61, jsxs as jsxs51 } from "react/jsx-runtime";
3738
4243
  function PageHeader({ title, subtitle, actions, className, ...rest }) {
3739
- return /* @__PURE__ */ jsxs46("header", { className: cx("pire-pageheader", className), ...rest, children: [
3740
- /* @__PURE__ */ jsxs46("div", { style: { minWidth: 0 }, children: [
3741
- /* @__PURE__ */ jsx55("h1", { className: "pire-pageheader-title", children: title }),
3742
- subtitle ? /* @__PURE__ */ jsx55("p", { className: "pire-pageheader-sub", children: subtitle }) : null
4244
+ return /* @__PURE__ */ jsxs51("header", { className: cx("pire-pageheader", className), ...rest, children: [
4245
+ /* @__PURE__ */ jsxs51("div", { style: { minWidth: 0 }, children: [
4246
+ /* @__PURE__ */ jsx61("h1", { className: "pire-pageheader-title", children: title }),
4247
+ subtitle ? /* @__PURE__ */ jsx61("p", { className: "pire-pageheader-sub", children: subtitle }) : null
3743
4248
  ] }),
3744
- actions ? /* @__PURE__ */ jsx55("div", { className: "pire-pageheader-actions", children: actions }) : null
4249
+ actions ? /* @__PURE__ */ jsx61("div", { className: "pire-pageheader-actions", children: actions }) : null
3745
4250
  ] });
3746
4251
  }
3747
4252
 
3748
4253
  // src/components/layout/SectionHeader.tsx
3749
- import { jsx as jsx56, jsxs as jsxs47 } from "react/jsx-runtime";
4254
+ import { jsx as jsx62, jsxs as jsxs52 } from "react/jsx-runtime";
3750
4255
  function SectionHeader({ title, meta, actions, className, ...rest }) {
3751
- return /* @__PURE__ */ jsxs47("div", { className: cx("pire-sectionhead", className), ...rest, children: [
3752
- /* @__PURE__ */ jsx56("span", { className: "pire-eyebrow", children: title }),
3753
- meta ? /* @__PURE__ */ jsx56("span", { style: { font: "var(--type-caption)", color: "var(--text-tertiary)" }, children: meta }) : null,
3754
- actions ? /* @__PURE__ */ jsx56("div", { className: "pire-sectionhead-actions", children: actions }) : null
4256
+ return /* @__PURE__ */ jsxs52("div", { className: cx("pire-sectionhead", className), ...rest, children: [
4257
+ /* @__PURE__ */ jsx62("span", { className: "pire-eyebrow", children: title }),
4258
+ meta ? /* @__PURE__ */ jsx62("span", { style: { font: "var(--type-caption)", color: "var(--text-tertiary)" }, children: meta }) : null,
4259
+ actions ? /* @__PURE__ */ jsx62("div", { className: "pire-sectionhead-actions", children: actions }) : null
3755
4260
  ] });
3756
4261
  }
3757
4262
 
3758
4263
  // src/components/layout/SelectionBar.tsx
3759
- import { jsx as jsx57, jsxs as jsxs48 } from "react/jsx-runtime";
4264
+ import { jsx as jsx63, jsxs as jsxs53 } from "react/jsx-runtime";
3760
4265
  function SelectionBar({ count, noun = "record", children, actions, className, ...rest }) {
3761
4266
  if (!count) return null;
3762
- return /* @__PURE__ */ jsxs48("div", { className: cx("pire-selectionbar", className), role: "status", "aria-live": "polite", ...rest, children: [
3763
- /* @__PURE__ */ jsxs48("span", { className: "pire-selectionbar-count", children: [
4267
+ return /* @__PURE__ */ jsxs53("div", { className: cx("pire-selectionbar", className), role: "status", "aria-live": "polite", ...rest, children: [
4268
+ /* @__PURE__ */ jsxs53("span", { className: "pire-selectionbar-count", children: [
3764
4269
  count.toLocaleString(),
3765
4270
  " ",
3766
4271
  noun,
3767
4272
  count === 1 ? "" : "s",
3768
4273
  " selected"
3769
4274
  ] }),
3770
- children ? /* @__PURE__ */ jsx57("span", { style: { color: "var(--text-secondary)", font: "var(--type-caption)" }, children }) : null,
3771
- actions ? /* @__PURE__ */ jsx57("div", { className: "pire-selectionbar-actions", children: actions }) : null
4275
+ children ? /* @__PURE__ */ jsx63("span", { style: { color: "var(--text-secondary)", font: "var(--type-caption)" }, children }) : null,
4276
+ actions ? /* @__PURE__ */ jsx63("div", { className: "pire-selectionbar-actions", children: actions }) : null
3772
4277
  ] });
3773
4278
  }
3774
4279
 
3775
4280
  // src/components/layout/FooterBar.tsx
3776
- import { jsx as jsx58, jsxs as jsxs49 } from "react/jsx-runtime";
4281
+ import { jsx as jsx64, jsxs as jsxs54 } from "react/jsx-runtime";
3777
4282
  function FooterBar({ note, actions, children, className, ...rest }) {
3778
- return /* @__PURE__ */ jsxs49("footer", { className: cx("pire-footerbar", className), ...rest, children: [
3779
- note ? /* @__PURE__ */ jsx58("span", { className: "pire-footerbar-note", children: note }) : null,
4283
+ return /* @__PURE__ */ jsxs54("footer", { className: cx("pire-footerbar", className), ...rest, children: [
4284
+ note ? /* @__PURE__ */ jsx64("span", { className: "pire-footerbar-note", children: note }) : null,
3780
4285
  children,
3781
- actions ? /* @__PURE__ */ jsx58("div", { className: "pire-footerbar-actions", children: actions }) : null
4286
+ actions ? /* @__PURE__ */ jsx64("div", { className: "pire-footerbar-actions", children: actions }) : null
3782
4287
  ] });
3783
4288
  }
3784
4289
 
3785
4290
  // src/components/layout/SplitPane.tsx
3786
- import { jsx as jsx59, jsxs as jsxs50 } from "react/jsx-runtime";
4291
+ import { jsx as jsx65, jsxs as jsxs55 } from "react/jsx-runtime";
3787
4292
  function SplitPane({
3788
4293
  list,
3789
4294
  detail,
@@ -3799,7 +4304,7 @@ function SplitPane({
3799
4304
  }) {
3800
4305
  const msg = usePireMessages();
3801
4306
  const width = typeof listWidth === "number" ? `${listWidth}px` : listWidth;
3802
- return /* @__PURE__ */ jsxs50(
4307
+ return /* @__PURE__ */ jsxs55(
3803
4308
  "div",
3804
4309
  {
3805
4310
  className: cx("pire-split", className),
@@ -3807,10 +4312,10 @@ function SplitPane({
3807
4312
  style: { ["--pire-split-list-w"]: width, ...style },
3808
4313
  ...rest,
3809
4314
  children: [
3810
- /* @__PURE__ */ jsx59("section", { className: "pire-split-list", "aria-label": listLabel ?? msg.splitPaneList, children: list }),
3811
- /* @__PURE__ */ jsxs50("section", { className: "pire-split-detail", "aria-label": detailLabel ?? msg.splitPaneDetail, children: [
3812
- onBack ? /* @__PURE__ */ jsx59("div", { className: "pire-split-back", children: /* @__PURE__ */ jsx59(Button, { variant: "tertiary", size: "sm", icon: "arrow-left", onPress: onBack, children: backLabel ?? msg.splitPaneBack }) }) : null,
3813
- detail ?? /* @__PURE__ */ jsx59("div", { className: "pire-split-empty", children: emptyDetail })
4315
+ /* @__PURE__ */ jsx65("section", { className: "pire-split-list", "aria-label": listLabel ?? msg.splitPaneList, children: list }),
4316
+ /* @__PURE__ */ jsxs55("section", { className: "pire-split-detail", "aria-label": detailLabel ?? msg.splitPaneDetail, children: [
4317
+ onBack ? /* @__PURE__ */ jsx65("div", { className: "pire-split-back", children: /* @__PURE__ */ jsx65(Button, { variant: "tertiary", size: "sm", icon: "arrow-left", onPress: onBack, children: backLabel ?? msg.splitPaneBack }) }) : null,
4318
+ detail ?? /* @__PURE__ */ jsx65("div", { className: "pire-split-empty", children: emptyDetail })
3814
4319
  ] })
3815
4320
  ]
3816
4321
  }
@@ -3818,11 +4323,12 @@ function SplitPane({
3818
4323
  }
3819
4324
 
3820
4325
  // src/components/patterns/ConfirmDialog.tsx
3821
- import { Fragment as Fragment5, jsx as jsx60, jsxs as jsxs51 } from "react/jsx-runtime";
4326
+ import { Fragment as Fragment8, jsx as jsx66, jsxs as jsxs56 } from "react/jsx-runtime";
3822
4327
  function ConfirmDialog({
3823
4328
  isOpen,
3824
4329
  title,
3825
4330
  subtitle,
4331
+ facts,
3826
4332
  consequence,
3827
4333
  children,
3828
4334
  confirmLabel = "Confirm",
@@ -3832,7 +4338,8 @@ function ConfirmDialog({
3832
4338
  onConfirm,
3833
4339
  onCancel
3834
4340
  }) {
3835
- return /* @__PURE__ */ jsxs51(
4341
+ const msg = usePireMessages();
4342
+ return /* @__PURE__ */ jsxs56(
3836
4343
  Dialog,
3837
4344
  {
3838
4345
  isOpen,
@@ -3842,12 +4349,19 @@ function ConfirmDialog({
3842
4349
  onClose: onCancel,
3843
4350
  isDismissable: !isBusy,
3844
4351
  showClose: false,
3845
- footer: /* @__PURE__ */ jsxs51(Fragment5, { children: [
3846
- /* @__PURE__ */ jsx60(Button, { variant: "tertiary", isDisabled: isBusy, onPress: onCancel, children: cancelLabel }),
3847
- /* @__PURE__ */ jsx60(Button, { variant: tone === "danger" ? "danger" : "primary", isDisabled: isBusy, onPress: onConfirm, children: isBusy ? "Working\u2026" : confirmLabel })
4352
+ footer: /* @__PURE__ */ jsxs56(Fragment8, { children: [
4353
+ /* @__PURE__ */ jsx66(Button, { variant: "tertiary", isDisabled: isBusy, onPress: onCancel, children: cancelLabel }),
4354
+ /* @__PURE__ */ jsx66(Button, { variant: tone === "danger" ? "danger" : "primary", isDisabled: isBusy, onPress: onConfirm, children: isBusy ? "Working\u2026" : confirmLabel })
3848
4355
  ] }),
3849
4356
  children: [
3850
- consequence ? /* @__PURE__ */ jsx60(InlineMessage, { kind: tone === "danger" ? "error" : "warning", style: { marginBottom: children ? "var(--sp-3)" : 0 }, children: consequence }) : null,
4357
+ facts?.length ? (
4358
+ // The role is what makes the name stick. A bare <div> resolves to `generic`, which
4359
+ // *prohibits* `aria-label` — the label named nothing at all, and axe's
4360
+ // `aria-prohibited-attr` fails it on sight. Every other labelled div/span in this library
4361
+ // pairs with an explicit role for the same reason.
4362
+ /* @__PURE__ */ jsx66("div", { className: "pire-confirm-facts", role: "group", "aria-label": msg.confirmDialogFactsLabel, children: /* @__PURE__ */ jsx66(DescriptionList, { layout: "rows", items: facts }) })
4363
+ ) : null,
4364
+ consequence ? /* @__PURE__ */ jsx66(InlineMessage, { kind: tone === "danger" ? "error" : "warning", style: { marginBottom: children ? "var(--sp-3)" : 0 }, children: consequence }) : null,
3851
4365
  children
3852
4366
  ]
3853
4367
  }
@@ -3855,7 +4369,7 @@ function ConfirmDialog({
3855
4369
  }
3856
4370
 
3857
4371
  // src/components/patterns/CommandPalette.tsx
3858
- import * as React26 from "react";
4372
+ import * as React28 from "react";
3859
4373
  import {
3860
4374
  Autocomplete,
3861
4375
  ModalOverlay as ModalOverlay2,
@@ -3868,7 +4382,7 @@ import {
3868
4382
  Header as Header2,
3869
4383
  useFilter
3870
4384
  } from "react-aria-components";
3871
- import { Fragment as Fragment6, jsx as jsx61, jsxs as jsxs52 } from "react/jsx-runtime";
4385
+ import { Fragment as Fragment9, jsx as jsx67, jsxs as jsxs57 } from "react/jsx-runtime";
3872
4386
  var RESULTS_SECTION_KEY = "__pire_results__";
3873
4387
  var searchableText = (item) => [item.label, item.description, item.keywords].filter(Boolean).join(" ");
3874
4388
  function CommandPalette({
@@ -3889,17 +4403,17 @@ function CommandPalette({
3889
4403
  style
3890
4404
  }) {
3891
4405
  const msg = usePireMessages();
3892
- const [query, setQuery] = React26.useState("");
4406
+ const [query, setQuery] = React28.useState("");
3893
4407
  const { contains } = useFilter({ sensitivity: "base" });
3894
- React26.useEffect(() => {
4408
+ React28.useEffect(() => {
3895
4409
  if (isOpen) setQuery("");
3896
4410
  }, [isOpen]);
3897
- const searchableById = React26.useMemo(() => {
4411
+ const searchableById = React28.useMemo(() => {
3898
4412
  const byId = /* @__PURE__ */ new Map();
3899
4413
  for (const group of groups) for (const item of group.items) byId.set(item.id, searchableText(item));
3900
4414
  return byId;
3901
4415
  }, [groups]);
3902
- const filter = React26.useCallback((textValue, inputValue, node) => {
4416
+ const filter = React28.useCallback((textValue, inputValue, node) => {
3903
4417
  if (node.parentKey === RESULTS_SECTION_KEY) return true;
3904
4418
  return contains(searchableById.get(String(node.key)) ?? textValue, inputValue);
3905
4419
  }, [contains, searchableById]);
@@ -3909,7 +4423,7 @@ function CommandPalette({
3909
4423
  };
3910
4424
  const sections = [...groups, ...resultsGroup ? [{ ...resultsGroup, id: RESULTS_SECTION_KEY }] : []];
3911
4425
  const status = isLoading ? loadingLabel ?? msg.commandPaletteLoading : emptyLabel ?? msg.commandPaletteEmpty;
3912
- return /* @__PURE__ */ jsx61(
4426
+ return /* @__PURE__ */ jsx67(
3913
4427
  ModalOverlay2,
3914
4428
  {
3915
4429
  className: "pire-cp-overlay",
@@ -3918,11 +4432,11 @@ function CommandPalette({
3918
4432
  onOpenChange: (open) => {
3919
4433
  if (!open) onOpenChange?.(false);
3920
4434
  },
3921
- children: /* @__PURE__ */ jsx61(Modal2, { className: cx("pire-cp-modal", className), style, children: /* @__PURE__ */ jsxs52(AriaDialog4, { className: "pire-cp-dialog", "aria-label": ariaLabel ?? msg.commandPaletteLabel, children: [
3922
- /* @__PURE__ */ jsxs52(Autocomplete, { filter, inputValue: query, onInputChange: handleInputChange, children: [
3923
- /* @__PURE__ */ jsxs52(SearchField, { className: "pire-cp-search", "aria-label": msg.commandPaletteSearchLabel, children: [
3924
- /* @__PURE__ */ jsx61(Icon, { name: "search", size: 18, className: "pire-cp-search-icon" }),
3925
- /* @__PURE__ */ jsx61(
4435
+ children: /* @__PURE__ */ jsx67(Modal2, { className: cx("pire-cp-modal", className), style, children: /* @__PURE__ */ jsxs57(AriaDialog4, { className: "pire-cp-dialog", "aria-label": ariaLabel ?? msg.commandPaletteLabel, children: [
4436
+ /* @__PURE__ */ jsxs57(Autocomplete, { filter, inputValue: query, onInputChange: handleInputChange, children: [
4437
+ /* @__PURE__ */ jsxs57(SearchField, { className: "pire-cp-search", "aria-label": msg.commandPaletteSearchLabel, children: [
4438
+ /* @__PURE__ */ jsx67(Icon, { name: "search", size: 18, className: "pire-cp-search-icon" }),
4439
+ /* @__PURE__ */ jsx67(
3926
4440
  AriaInput5,
3927
4441
  {
3928
4442
  className: "pire-cp-input",
@@ -3931,16 +4445,16 @@ function CommandPalette({
3931
4445
  }
3932
4446
  )
3933
4447
  ] }),
3934
- isLoading ? /* @__PURE__ */ jsx61("div", { className: "pire-cp-loading", role: "status", "aria-live": "polite", children: loadingLabel ?? msg.commandPaletteLoading }) : null,
3935
- /* @__PURE__ */ jsx61(
4448
+ isLoading ? /* @__PURE__ */ jsx67("div", { className: "pire-cp-loading", role: "status", "aria-live": "polite", children: loadingLabel ?? msg.commandPaletteLoading }) : null,
4449
+ /* @__PURE__ */ jsx67(
3936
4450
  AriaMenu2,
3937
4451
  {
3938
4452
  className: "pire-cp-list",
3939
4453
  onAction: (key) => onAction?.(String(key)),
3940
- renderEmptyState: () => /* @__PURE__ */ jsx61("div", { className: "pire-cp-status", children: status }),
3941
- children: sections.map((section) => /* @__PURE__ */ jsxs52(AriaMenuSection2, { id: section.id, className: "pire-cp-section", children: [
3942
- section.label ? /* @__PURE__ */ jsx61(Header2, { className: "pire-cp-section-title", children: section.label }) : null,
3943
- section.items.map((item) => /* @__PURE__ */ jsx61(
4454
+ renderEmptyState: () => /* @__PURE__ */ jsx67("div", { className: "pire-cp-status", children: status }),
4455
+ children: sections.map((section) => /* @__PURE__ */ jsxs57(AriaMenuSection2, { id: section.id, className: "pire-cp-section", children: [
4456
+ section.label ? /* @__PURE__ */ jsx67(Header2, { className: "pire-cp-section-title", children: section.label }) : null,
4457
+ section.items.map((item) => /* @__PURE__ */ jsx67(
3944
4458
  MenuItem,
3945
4459
  {
3946
4460
  id: item.id,
@@ -3961,18 +4475,18 @@ function CommandPalette({
3961
4475
  // aria-hidden: the glyphs are a sighted affordance for discovering the keys. A screen
3962
4476
  // reader already announces the listbox semantics that make those keys work, so reading
3963
4477
  // "up arrow down arrow navigate" out loud is noise on every open.
3964
- /* @__PURE__ */ jsx61("div", { className: "pire-cp-foot", "aria-hidden": "true", children: footer ?? /* @__PURE__ */ jsxs52(Fragment6, { children: [
3965
- /* @__PURE__ */ jsxs52("span", { className: "pire-cp-hint", children: [
3966
- /* @__PURE__ */ jsx61(Kbd, { children: "\u2191" }),
3967
- /* @__PURE__ */ jsx61(Kbd, { children: "\u2193" }),
4478
+ /* @__PURE__ */ jsx67("div", { className: "pire-cp-foot", "aria-hidden": "true", children: footer ?? /* @__PURE__ */ jsxs57(Fragment9, { children: [
4479
+ /* @__PURE__ */ jsxs57("span", { className: "pire-cp-hint", children: [
4480
+ /* @__PURE__ */ jsx67(Kbd, { children: "\u2191" }),
4481
+ /* @__PURE__ */ jsx67(Kbd, { children: "\u2193" }),
3968
4482
  msg.commandPaletteHintNavigate
3969
4483
  ] }),
3970
- /* @__PURE__ */ jsxs52("span", { className: "pire-cp-hint", children: [
3971
- /* @__PURE__ */ jsx61(Kbd, { children: "\u21B5" }),
4484
+ /* @__PURE__ */ jsxs57("span", { className: "pire-cp-hint", children: [
4485
+ /* @__PURE__ */ jsx67(Kbd, { children: "\u21B5" }),
3972
4486
  msg.commandPaletteHintSelect
3973
4487
  ] }),
3974
- /* @__PURE__ */ jsxs52("span", { className: "pire-cp-hint", children: [
3975
- /* @__PURE__ */ jsx61(Kbd, { children: "esc" }),
4488
+ /* @__PURE__ */ jsxs57("span", { className: "pire-cp-hint", children: [
4489
+ /* @__PURE__ */ jsx67(Kbd, { children: "esc" }),
3976
4490
  msg.commandPaletteHintClose
3977
4491
  ] })
3978
4492
  ] }) })
@@ -3982,9 +4496,9 @@ function CommandPalette({
3982
4496
  );
3983
4497
  }
3984
4498
  function useCommandPaletteShortcut(onTrigger, { key = "k", isDisabled } = {}) {
3985
- const handler = React26.useRef(onTrigger);
4499
+ const handler = React28.useRef(onTrigger);
3986
4500
  handler.current = onTrigger;
3987
- React26.useEffect(() => {
4501
+ React28.useEffect(() => {
3988
4502
  if (isDisabled) return;
3989
4503
  const onKeyDown = (event) => {
3990
4504
  if (!(event.metaKey || event.ctrlKey) || event.altKey) return;
@@ -3998,15 +4512,15 @@ function useCommandPaletteShortcut(onTrigger, { key = "k", isDisabled } = {}) {
3998
4512
  }
3999
4513
 
4000
4514
  // src/components/patterns/AppLauncher.tsx
4001
- import * as React27 from "react";
4515
+ import * as React29 from "react";
4002
4516
  import {
4003
4517
  DialogTrigger,
4004
- Button as AriaButton16,
4518
+ Button as AriaButton17,
4005
4519
  Popover as Popover8,
4006
4520
  Dialog as AriaDialog5,
4007
4521
  useFilter as useFilter2
4008
4522
  } from "react-aria-components";
4009
- import { Fragment as Fragment7, jsx as jsx62, jsxs as jsxs53 } from "react/jsx-runtime";
4523
+ import { Fragment as Fragment10, jsx as jsx68, jsxs as jsxs58 } from "react/jsx-runtime";
4010
4524
  var searchableText2 = (item) => [item.label, item.description, item.keywords].filter(Boolean).join(" ");
4011
4525
  function AppLauncher({
4012
4526
  sections,
@@ -4025,13 +4539,13 @@ function AppLauncher({
4025
4539
  className
4026
4540
  }) {
4027
4541
  const msg = usePireMessages();
4028
- const [query, setQuery] = React27.useState("");
4542
+ const [query, setQuery] = React29.useState("");
4029
4543
  const { contains } = useFilter2({ sensitivity: "base" });
4030
4544
  const handleSearch = (next) => {
4031
4545
  setQuery(next);
4032
4546
  onSearchChange?.(next);
4033
4547
  };
4034
- const visible = React27.useMemo(() => {
4548
+ const visible = React29.useMemo(() => {
4035
4549
  if (isFilteredExternally) return sections;
4036
4550
  const q = query.trim();
4037
4551
  if (!q) return sections;
@@ -4039,9 +4553,9 @@ function AppLauncher({
4039
4553
  }, [sections, query, isFilteredExternally, contains]);
4040
4554
  const isEmpty = !isLoading && visible.length === 0;
4041
4555
  const label = ariaLabel ?? msg.appLauncherLabel;
4042
- return /* @__PURE__ */ jsxs53(DialogTrigger, { children: [
4043
- /* @__PURE__ */ jsx62(AriaButton16, { className: "pire-launcher-trigger", "aria-label": label, children: /* @__PURE__ */ jsx62(Icon, { name: icon, size: 20 }) }),
4044
- /* @__PURE__ */ jsx62(
4556
+ return /* @__PURE__ */ jsxs58(DialogTrigger, { children: [
4557
+ /* @__PURE__ */ jsx68(AriaButton17, { className: "pire-launcher-trigger", "aria-label": label, children: /* @__PURE__ */ jsx68(Icon, { name: icon, size: 20 }) }),
4558
+ /* @__PURE__ */ jsx68(
4045
4559
  Popover8,
4046
4560
  {
4047
4561
  className: cx("pire-launcher-popover", className),
@@ -4049,15 +4563,15 @@ function AppLauncher({
4049
4563
  offset: 0,
4050
4564
  crossOffset: 0,
4051
4565
  containerPadding: 0,
4052
- children: /* @__PURE__ */ jsx62(AriaDialog5, { className: "pire-launcher", "aria-label": label, children: ({ close }) => /* @__PURE__ */ jsxs53(Fragment7, { children: [
4053
- /* @__PURE__ */ jsxs53("div", { className: "pire-launcher-head", children: [
4054
- /* @__PURE__ */ jsx62("span", { className: "pire-launcher-title", children: title ?? msg.appLauncherTitle }),
4055
- meta ? /* @__PURE__ */ jsx62("span", { className: "pire-launcher-meta", children: meta }) : null
4566
+ children: /* @__PURE__ */ jsx68(AriaDialog5, { className: "pire-launcher", "aria-label": label, children: ({ close }) => /* @__PURE__ */ jsxs58(Fragment10, { children: [
4567
+ /* @__PURE__ */ jsxs58("div", { className: "pire-launcher-head", children: [
4568
+ /* @__PURE__ */ jsx68("span", { className: "pire-launcher-title", children: title ?? msg.appLauncherTitle }),
4569
+ meta ? /* @__PURE__ */ jsx68("span", { className: "pire-launcher-meta", children: meta }) : null
4056
4570
  ] }),
4057
4571
  isSearchable ? (
4058
4572
  // autoFocus is right here specifically: the panel exists to be searched, and the
4059
4573
  // user just chose to open it, so taking the caret is what they asked for.
4060
- /* @__PURE__ */ jsx62(
4574
+ /* @__PURE__ */ jsx68(
4061
4575
  Input,
4062
4576
  {
4063
4577
  "aria-label": msg.appLauncherSearch,
@@ -4071,18 +4585,18 @@ function AppLauncher({
4071
4585
  }
4072
4586
  )
4073
4587
  ) : null,
4074
- isLoading ? /* @__PURE__ */ jsx62("div", { className: "pire-launcher-empty", role: "status", "aria-live": "polite", children: msg.appLauncherLoading }) : null,
4075
- isEmpty ? /* @__PURE__ */ jsx62("div", { className: "pire-launcher-empty", children: emptyLabel ?? msg.appLauncherEmpty }) : null,
4588
+ isLoading ? /* @__PURE__ */ jsx68("div", { className: "pire-launcher-empty", role: "status", "aria-live": "polite", children: msg.appLauncherLoading }) : null,
4589
+ isEmpty ? /* @__PURE__ */ jsx68("div", { className: "pire-launcher-empty", children: emptyLabel ?? msg.appLauncherEmpty }) : null,
4076
4590
  visible.map((section, si) => (
4077
4591
  // Sections are positional zones with no record identity, so the heading is the key
4078
4592
  // where there is one. Same reasoning as ShellRail's groups.
4079
- /* @__PURE__ */ jsxs53("div", { className: "pire-launcher-section", children: [
4080
- section.label ? /* @__PURE__ */ jsx62("div", { className: "pire-eyebrow", children: section.label }) : null,
4081
- /* @__PURE__ */ jsx62("div", { className: "pire-launcher-grid", "data-variant": section.variant ?? "tile", children: section.items.map((item) => {
4593
+ /* @__PURE__ */ jsxs58("div", { className: "pire-launcher-section", children: [
4594
+ section.label ? /* @__PURE__ */ jsx68("div", { className: "pire-eyebrow", children: section.label }) : null,
4595
+ /* @__PURE__ */ jsx68("div", { className: "pire-launcher-grid", "data-variant": section.variant ?? "tile", children: section.items.map((item) => {
4082
4596
  const isCurrent = item.id === value;
4083
4597
  const showsDescription = (section.variant ?? "tile") === "tile" && Boolean(item.description);
4084
- return /* @__PURE__ */ jsxs53(
4085
- AriaButton16,
4598
+ return /* @__PURE__ */ jsxs58(
4599
+ AriaButton17,
4086
4600
  {
4087
4601
  className: "pire-launcher-item",
4088
4602
  "data-selected": isCurrent ? "true" : void 0,
@@ -4092,10 +4606,10 @@ function AppLauncher({
4092
4606
  onAction?.(item.id);
4093
4607
  },
4094
4608
  children: [
4095
- item.icon ? /* @__PURE__ */ jsx62("span", { className: "pire-launcher-item-icon", children: /* @__PURE__ */ jsx62(Icon, { name: item.icon, size: (section.variant ?? "tile") === "tile" ? 20 : 16 }) }) : null,
4096
- /* @__PURE__ */ jsxs53("span", { className: "pire-launcher-item-text", children: [
4097
- /* @__PURE__ */ jsx62("span", { className: "pire-launcher-item-label", children: item.label }),
4098
- showsDescription ? /* @__PURE__ */ jsx62("span", { className: "pire-launcher-item-desc", children: item.description }) : null
4609
+ item.icon ? /* @__PURE__ */ jsx68("span", { className: "pire-launcher-item-icon", children: /* @__PURE__ */ jsx68(Icon, { name: item.icon, size: (section.variant ?? "tile") === "tile" ? 20 : 16 }) }) : null,
4610
+ /* @__PURE__ */ jsxs58("span", { className: "pire-launcher-item-text", children: [
4611
+ /* @__PURE__ */ jsx68("span", { className: "pire-launcher-item-label", children: item.label }),
4612
+ showsDescription ? /* @__PURE__ */ jsx68("span", { className: "pire-launcher-item-desc", children: item.description }) : null
4099
4613
  ] })
4100
4614
  ]
4101
4615
  },
@@ -4112,10 +4626,10 @@ function AppLauncher({
4112
4626
 
4113
4627
  // src/components/patterns/SidePanel.tsx
4114
4628
  import { ModalOverlay as ModalOverlay3, Modal as Modal3, Dialog as AriaDialog6, Heading as Heading5 } from "react-aria-components";
4115
- import { jsx as jsx63, jsxs as jsxs54 } from "react/jsx-runtime";
4629
+ import { jsx as jsx69, jsxs as jsxs59 } from "react/jsx-runtime";
4116
4630
  function SidePanel({ isOpen, title, subtitle, width = 400, children, footer, onClose, className }) {
4117
4631
  const msg = usePireMessages();
4118
- return /* @__PURE__ */ jsx63(
4632
+ return /* @__PURE__ */ jsx69(
4119
4633
  ModalOverlay3,
4120
4634
  {
4121
4635
  className: "pire-sidepanel-overlay",
@@ -4124,35 +4638,35 @@ function SidePanel({ isOpen, title, subtitle, width = 400, children, footer, onC
4124
4638
  onOpenChange: (o) => {
4125
4639
  if (!o) onClose?.();
4126
4640
  },
4127
- children: /* @__PURE__ */ jsx63(Modal3, { className: cx("pire-sidepanel", className), style: { width }, children: /* @__PURE__ */ jsxs54(AriaDialog6, { className: "pire-dialog", style: { height: "100%" }, children: [
4128
- /* @__PURE__ */ jsxs54("header", { className: "pire-dialog-head", children: [
4129
- /* @__PURE__ */ jsxs54("div", { style: { flex: 1, minWidth: 0 }, children: [
4130
- /* @__PURE__ */ jsx63(Heading5, { slot: "title", className: "pire-dialog-title", children: title }),
4131
- subtitle ? /* @__PURE__ */ jsx63("p", { className: "pire-dialog-sub", style: { margin: 0 }, children: subtitle }) : null
4641
+ children: /* @__PURE__ */ jsx69(Modal3, { className: cx("pire-sidepanel", className), style: { width }, children: /* @__PURE__ */ jsxs59(AriaDialog6, { className: "pire-dialog", style: { height: "100%" }, children: [
4642
+ /* @__PURE__ */ jsxs59("header", { className: "pire-dialog-head", children: [
4643
+ /* @__PURE__ */ jsxs59("div", { style: { flex: 1, minWidth: 0 }, children: [
4644
+ /* @__PURE__ */ jsx69(Heading5, { slot: "title", className: "pire-dialog-title", children: title }),
4645
+ subtitle ? /* @__PURE__ */ jsx69("p", { className: "pire-dialog-sub", style: { margin: 0 }, children: subtitle }) : null
4132
4646
  ] }),
4133
- /* @__PURE__ */ jsx63(IconButton, { icon: "x", label: msg.sidePanelClose, size: "sm", onPress: onClose })
4647
+ /* @__PURE__ */ jsx69(IconButton, { icon: "x", label: msg.sidePanelClose, size: "sm", onPress: onClose })
4134
4648
  ] }),
4135
- /* @__PURE__ */ jsx63("div", { className: "pire-dialog-body", style: { flex: 1 }, children }),
4136
- footer ? /* @__PURE__ */ jsx63("footer", { className: "pire-dialog-foot", children: footer }) : null
4649
+ /* @__PURE__ */ jsx69("div", { className: "pire-dialog-body", style: { flex: 1 }, children }),
4650
+ footer ? /* @__PURE__ */ jsx69("footer", { className: "pire-dialog-foot", children: footer }) : null
4137
4651
  ] }) })
4138
4652
  }
4139
4653
  );
4140
4654
  }
4141
4655
 
4142
4656
  // src/components/patterns/EmptyState.tsx
4143
- import { jsx as jsx64, jsxs as jsxs55 } from "react/jsx-runtime";
4657
+ import { jsx as jsx70, jsxs as jsxs60 } from "react/jsx-runtime";
4144
4658
  function EmptyState({ icon = "file-text", title, action, compact, children, className, ...rest }) {
4145
- return /* @__PURE__ */ jsxs55("div", { className: cx("pire-empty", className), "data-compact": compact ? "true" : void 0, ...rest, children: [
4146
- /* @__PURE__ */ jsx64(Icon, { name: icon, size: 24, className: "pire-empty-icon" }),
4147
- title ? /* @__PURE__ */ jsx64("p", { className: "pire-empty-title", style: { margin: 0 }, children: title }) : null,
4148
- children ? /* @__PURE__ */ jsx64("p", { className: "pire-empty-body", style: { margin: 0 }, children }) : null,
4659
+ return /* @__PURE__ */ jsxs60("div", { className: cx("pire-empty", className), "data-compact": compact ? "true" : void 0, ...rest, children: [
4660
+ /* @__PURE__ */ jsx70(Icon, { name: icon, size: 24, className: "pire-empty-icon" }),
4661
+ title ? /* @__PURE__ */ jsx70("p", { className: "pire-empty-title", style: { margin: 0 }, children: title }) : null,
4662
+ children ? /* @__PURE__ */ jsx70("p", { className: "pire-empty-body", style: { margin: 0 }, children }) : null,
4149
4663
  action
4150
4664
  ] });
4151
4665
  }
4152
4666
 
4153
4667
  // src/components/patterns/NumPad.tsx
4154
- import * as React28 from "react";
4155
- import { jsx as jsx65, jsxs as jsxs56 } from "react/jsx-runtime";
4668
+ import * as React30 from "react";
4669
+ import { jsx as jsx71, jsxs as jsxs61 } from "react/jsx-runtime";
4156
4670
  var BASE_KEYS = [
4157
4671
  { value: "7" },
4158
4672
  { value: "8" },
@@ -4169,9 +4683,9 @@ var BASE_KEYS = [
4169
4683
  ];
4170
4684
  var isInsertable = (value) => /^[0-9]+$/.test(value);
4171
4685
  function useNumPadKeyboard(onKey, isDisabled, containerRef) {
4172
- const handler = React28.useRef(onKey);
4686
+ const handler = React30.useRef(onKey);
4173
4687
  handler.current = onKey;
4174
- React28.useEffect(() => {
4688
+ React30.useEffect(() => {
4175
4689
  if (isDisabled) return;
4176
4690
  const isEditingElsewhere = () => {
4177
4691
  const el = document.activeElement;
@@ -4213,8 +4727,8 @@ function NumPad({
4213
4727
  style
4214
4728
  }) {
4215
4729
  const msg = usePireMessages();
4216
- const containerRef = React28.useRef(null);
4217
- const applyKey = React28.useCallback((key) => {
4730
+ const containerRef = React30.useRef(null);
4731
+ const applyKey = React30.useCallback((key) => {
4218
4732
  if (isDisabled) return;
4219
4733
  if (key.value === "backspace") {
4220
4734
  onChange(value.slice(0, -1));
@@ -4232,7 +4746,7 @@ function NumPad({
4232
4746
  }, [isDisabled, value, onChange, onAction]);
4233
4747
  useNumPadKeyboard((keyValue) => applyKey({ value: keyValue }), isDisabled, containerRef);
4234
4748
  const keys = [...BASE_KEYS, ...extraKeys];
4235
- return /* @__PURE__ */ jsxs56(
4749
+ return /* @__PURE__ */ jsxs61(
4236
4750
  "div",
4237
4751
  {
4238
4752
  ref: containerRef,
@@ -4241,10 +4755,10 @@ function NumPad({
4241
4755
  "data-size": size,
4242
4756
  "data-disabled": isDisabled ? "true" : void 0,
4243
4757
  children: [
4244
- target !== void 0 ? /* @__PURE__ */ jsx65("div", { className: "pire-numpad-target", role: "status", "aria-live": "polite", children: target }) : null,
4245
- /* @__PURE__ */ jsx65("div", { className: "pire-numpad-grid", role: "group", "aria-label": ariaLabel, children: keys.map((key) => {
4758
+ target !== void 0 ? /* @__PURE__ */ jsx71("div", { className: "pire-numpad-target", role: "status", "aria-live": "polite", children: target }) : null,
4759
+ /* @__PURE__ */ jsx71("div", { className: "pire-numpad-grid", role: "group", "aria-label": ariaLabel, children: keys.map((key) => {
4246
4760
  const accessibleLabel = key.value === "backspace" ? msg.numPadBackspace : key.value === "clear" ? msg.numPadClear : void 0;
4247
- return /* @__PURE__ */ jsx65(
4761
+ return /* @__PURE__ */ jsx71(
4248
4762
  Button,
4249
4763
  {
4250
4764
  variant: "secondary",
@@ -4266,9 +4780,9 @@ function NumPad({
4266
4780
  }
4267
4781
 
4268
4782
  // src/components/patterns/FileDropZone.tsx
4269
- import * as React29 from "react";
4783
+ import * as React31 from "react";
4270
4784
  import { DropZone, FileTrigger as FileTrigger2, isFileDropItem } from "react-aria-components";
4271
- import { jsx as jsx66, jsxs as jsxs57 } from "react/jsx-runtime";
4785
+ import { jsx as jsx72, jsxs as jsxs62 } from "react/jsx-runtime";
4272
4786
  var isImage2 = (file) => file.type.startsWith("image/");
4273
4787
  function FileDropZone({
4274
4788
  label,
@@ -4296,10 +4810,10 @@ function FileDropZone({
4296
4810
  ...rest
4297
4811
  }) {
4298
4812
  const msg = usePireMessages();
4299
- const [uncontrolled, setUncontrolled] = React29.useState(defaultValue ?? []);
4813
+ const [uncontrolled, setUncontrolled] = React31.useState(defaultValue ?? []);
4300
4814
  const files = value ?? uncontrolled;
4301
- const created = React29.useRef([]);
4302
- React29.useEffect(() => () => {
4815
+ const created = React31.useRef([]);
4816
+ React31.useEffect(() => () => {
4303
4817
  for (const url of created.current) URL.revokeObjectURL(url);
4304
4818
  }, []);
4305
4819
  const commit = (next) => {
@@ -4319,12 +4833,12 @@ function FileDropZone({
4319
4833
  commit(allowsMultiple ? [...files, ...wrapped] : wrapped.slice(0, 1));
4320
4834
  };
4321
4835
  const remove = (target) => commit(files.filter((f) => f.file !== target));
4322
- return /* @__PURE__ */ jsxs57("div", { className: cx("pire-field", className), style, "data-full-width": String(fullWidth), ...rest, children: [
4323
- label ? /* @__PURE__ */ jsxs57("span", { className: "pire-field-label", children: [
4836
+ return /* @__PURE__ */ jsxs62("div", { className: cx("pire-field", className), style, "data-full-width": String(fullWidth), ...rest, children: [
4837
+ label ? /* @__PURE__ */ jsxs62("span", { className: "pire-field-label", children: [
4324
4838
  label,
4325
- isRequired ? /* @__PURE__ */ jsx66("span", { className: "pire-field-req", "aria-hidden": "true", children: "*" }) : null
4839
+ isRequired ? /* @__PURE__ */ jsx72("span", { className: "pire-field-req", "aria-hidden": "true", children: "*" }) : null
4326
4840
  ] }) : null,
4327
- /* @__PURE__ */ jsxs57(
4841
+ /* @__PURE__ */ jsxs62(
4328
4842
  DropZone,
4329
4843
  {
4330
4844
  className: "pire-dropzone",
@@ -4338,25 +4852,25 @@ function FileDropZone({
4338
4852
  accept(dropped);
4339
4853
  },
4340
4854
  children: [
4341
- /* @__PURE__ */ jsx66(Icon, { name: "download", size: 24, className: "pire-dropzone-icon" }),
4342
- /* @__PURE__ */ jsx66("span", { className: "pire-dropzone-prompt", children: promptLabel ?? msg.fileDropZonePrompt }),
4343
- /* @__PURE__ */ jsx66(
4855
+ /* @__PURE__ */ jsx72(Icon, { name: "download", size: 24, className: "pire-dropzone-icon" }),
4856
+ /* @__PURE__ */ jsx72("span", { className: "pire-dropzone-prompt", children: promptLabel ?? msg.fileDropZonePrompt }),
4857
+ /* @__PURE__ */ jsx72(
4344
4858
  FileTrigger2,
4345
4859
  {
4346
4860
  acceptedFileTypes,
4347
4861
  allowsMultiple,
4348
4862
  onSelect: (list) => accept(list ? [...list] : []),
4349
- children: /* @__PURE__ */ jsx66(Button, { variant: "secondary", isDisabled: isDisabled || isReadOnly, children: msg.fileUploadChoose })
4863
+ children: /* @__PURE__ */ jsx72(Button, { variant: "secondary", isDisabled: isDisabled || isReadOnly, children: msg.fileUploadChoose })
4350
4864
  }
4351
4865
  )
4352
4866
  ]
4353
4867
  }
4354
4868
  ),
4355
- files.length ? /* @__PURE__ */ jsx66("ul", { className: "pire-fileupload-list", children: files.map(({ file, previewUrl }) => /* @__PURE__ */ jsxs57("li", { className: "pire-fileupload-item", children: [
4356
- previewUrl ? /* @__PURE__ */ jsx66("img", { className: "pire-fileupload-thumb", src: previewUrl, alt: "" }) : /* @__PURE__ */ jsx66(Icon, { name: "file-text", size: 16, className: "pire-fileupload-icon" }),
4357
- /* @__PURE__ */ jsx66("span", { className: "pire-fileupload-name", children: file.name }),
4358
- /* @__PURE__ */ jsx66("span", { className: "pire-fileupload-size", children: formatFileSize(file.size) }),
4359
- isDisabled || isReadOnly ? null : /* @__PURE__ */ jsx66(
4869
+ files.length ? /* @__PURE__ */ jsx72("ul", { className: "pire-fileupload-list", children: files.map(({ file, previewUrl }) => /* @__PURE__ */ jsxs62("li", { className: "pire-fileupload-item", children: [
4870
+ previewUrl ? /* @__PURE__ */ jsx72("img", { className: "pire-fileupload-thumb", src: previewUrl, alt: "" }) : /* @__PURE__ */ jsx72(Icon, { name: "file-text", size: 16, className: "pire-fileupload-icon" }),
4871
+ /* @__PURE__ */ jsx72("span", { className: "pire-fileupload-name", children: file.name }),
4872
+ /* @__PURE__ */ jsx72("span", { className: "pire-fileupload-size", children: formatFileSize(file.size) }),
4873
+ isDisabled || isReadOnly ? null : /* @__PURE__ */ jsx72(
4360
4874
  IconButton,
4361
4875
  {
4362
4876
  icon: "x",
@@ -4366,9 +4880,9 @@ function FileDropZone({
4366
4880
  }
4367
4881
  )
4368
4882
  ] }, `${file.name}-${file.size}-${file.lastModified}`)) }) : null,
4369
- uploadProgress != null ? /* @__PURE__ */ jsx66(ProgressBar, { value: uploadProgress, label: msg.fileUploadUploading }) : null,
4370
- description ? /* @__PURE__ */ jsx66("span", { className: "pire-field-hint", children: description }) : null,
4371
- isInvalid && errorMessage ? /* @__PURE__ */ jsx66("span", { className: "pire-field-error", children: errorMessage }) : null
4883
+ uploadProgress != null ? /* @__PURE__ */ jsx72(ProgressBar, { value: uploadProgress, label: msg.fileUploadUploading }) : null,
4884
+ description ? /* @__PURE__ */ jsx72("span", { className: "pire-field-hint", children: description }) : null,
4885
+ isInvalid && errorMessage ? /* @__PURE__ */ jsx72("span", { className: "pire-field-error", children: errorMessage }) : null
4372
4886
  ] });
4373
4887
  }
4374
4888
 
@@ -4380,10 +4894,12 @@ export {
4380
4894
  Avatar,
4381
4895
  Badge,
4382
4896
  BarChart,
4897
+ BarList,
4383
4898
  Breadcrumb,
4384
4899
  Button,
4385
4900
  Card,
4386
4901
  Checkbox,
4902
+ ChoiceCardGroup,
4387
4903
  ComboBox,
4388
4904
  CommandPalette,
4389
4905
  ConfirmDialog,
@@ -4432,8 +4948,11 @@ export {
4432
4948
  PireIntlProvider,
4433
4949
  Popover9 as Popover,
4434
4950
  ProgressBar,
4951
+ QuantityStepper,
4435
4952
  Radio,
4436
4953
  RadioGroup,
4954
+ RecordCard,
4955
+ Ribbon,
4437
4956
  RouterProvider,
4438
4957
  SectionHeader,
4439
4958
  SegmentedControl,
@@ -4461,6 +4980,7 @@ export {
4461
4980
  VIZ_SLOT_COUNT,
4462
4981
  ValueHelpDialog,
4463
4982
  ValueHelpField,
4983
+ ViewSwitcher,
4464
4984
  configureIcons,
4465
4985
  enMessages,
4466
4986
  esMessages,