@eifi1/ui-kit 0.6.1 → 0.7.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 (271) hide show
  1. package/README.md +69 -33
  2. package/dist/chart.d.ts +1 -0
  3. package/dist/components/account-settings.js +3 -2
  4. package/dist/components/account-settings.js.map +1 -1
  5. package/dist/components/amount-input.d.ts +5 -0
  6. package/dist/components/amount-input.js +6 -4
  7. package/dist/components/amount-input.js.map +1 -1
  8. package/dist/components/autocomplete.d.ts +33 -6
  9. package/dist/components/autocomplete.js +62 -16
  10. package/dist/components/autocomplete.js.map +1 -1
  11. package/dist/components/calculator.d.ts +5 -0
  12. package/dist/components/calculator.js +2 -1
  13. package/dist/components/calculator.js.map +1 -1
  14. package/dist/components/chart-zoom.js +2 -1
  15. package/dist/components/chart-zoom.js.map +1 -1
  16. package/dist/components/chart.d.ts +33 -2
  17. package/dist/components/chart.js +20 -8
  18. package/dist/components/chart.js.map +1 -1
  19. package/dist/components/chip.d.ts +34 -14
  20. package/dist/components/chip.js +63 -28
  21. package/dist/components/chip.js.map +1 -1
  22. package/dist/components/choice-card.d.ts +18 -1
  23. package/dist/components/choice-card.js +21 -8
  24. package/dist/components/choice-card.js.map +1 -1
  25. package/dist/components/combobox-core.d.ts +61 -2
  26. package/dist/components/combobox-core.js +68 -17
  27. package/dist/components/combobox-core.js.map +1 -1
  28. package/dist/components/combobox.d.ts +11 -7
  29. package/dist/components/combobox.js +51 -28
  30. package/dist/components/combobox.js.map +1 -1
  31. package/dist/components/currency-select.js +3 -3
  32. package/dist/components/currency-select.js.map +1 -1
  33. package/dist/components/danger-confirm.d.ts +30 -6
  34. package/dist/components/danger-confirm.js +51 -32
  35. package/dist/components/danger-confirm.js.map +1 -1
  36. package/dist/components/data-table-filter-popover.d.ts +1 -1
  37. package/dist/components/data-table-filters.d.ts +1 -1
  38. package/dist/components/data-table-pagination.d.ts +6 -3
  39. package/dist/components/data-table-pagination.js +6 -5
  40. package/dist/components/data-table-pagination.js.map +1 -1
  41. package/dist/components/data-table.d.ts +1 -1
  42. package/dist/components/data-table.js +332 -248
  43. package/dist/components/data-table.js.map +1 -1
  44. package/dist/components/date-picker.js +17 -7
  45. package/dist/components/date-picker.js.map +1 -1
  46. package/dist/components/dialog-frame.d.ts +28 -3
  47. package/dist/components/dialog-frame.js +47 -11
  48. package/dist/components/dialog-frame.js.map +1 -1
  49. package/dist/components/disclosure.d.ts +22 -2
  50. package/dist/components/disclosure.js +41 -8
  51. package/dist/components/disclosure.js.map +1 -1
  52. package/dist/components/dropdown.d.ts +7 -3
  53. package/dist/components/dropdown.js +6 -2
  54. package/dist/components/dropdown.js.map +1 -1
  55. package/dist/components/entity-combobox.d.ts +17 -8
  56. package/dist/components/entity-combobox.js +7 -5
  57. package/dist/components/entity-combobox.js.map +1 -1
  58. package/dist/components/file-button.d.ts +38 -5
  59. package/dist/components/file-button.js +23 -2
  60. package/dist/components/file-button.js.map +1 -1
  61. package/dist/components/file-dropzone.d.ts +11 -5
  62. package/dist/components/file-dropzone.js +14 -19
  63. package/dist/components/file-dropzone.js.map +1 -1
  64. package/dist/components/grouped-picker.js +2 -2
  65. package/dist/components/grouped-picker.js.map +1 -1
  66. package/dist/components/hover-menu.d.ts +8 -3
  67. package/dist/components/hover-menu.js +88 -4
  68. package/dist/components/hover-menu.js.map +1 -1
  69. package/dist/components/icon-picker.d.ts +10 -1
  70. package/dist/components/icon-picker.js +5 -1
  71. package/dist/components/icon-picker.js.map +1 -1
  72. package/dist/components/measured-grid.d.ts +165 -0
  73. package/dist/components/measured-grid.js +559 -0
  74. package/dist/components/measured-grid.js.map +1 -0
  75. package/dist/components/mini-calendar.js +7 -8
  76. package/dist/components/mini-calendar.js.map +1 -1
  77. package/dist/components/month-picker.js +13 -9
  78. package/dist/components/month-picker.js.map +1 -1
  79. package/dist/components/multi-entity-combobox.js +2 -2
  80. package/dist/components/multi-entity-combobox.js.map +1 -1
  81. package/dist/components/multi-select.d.ts +9 -1
  82. package/dist/components/multi-select.js +22 -8
  83. package/dist/components/multi-select.js.map +1 -1
  84. package/dist/components/number-field.d.ts +5 -0
  85. package/dist/components/number-input.d.ts +5 -0
  86. package/dist/components/number-input.js +3 -3
  87. package/dist/components/number-input.js.map +1 -1
  88. package/dist/components/numpad-sheet.d.ts +5 -0
  89. package/dist/components/numpad-sheet.js +3 -3
  90. package/dist/components/numpad-sheet.js.map +1 -1
  91. package/dist/components/picker-sheet.js +1 -1
  92. package/dist/components/picker-sheet.js.map +1 -1
  93. package/dist/components/popover.js +11 -2
  94. package/dist/components/popover.js.map +1 -1
  95. package/dist/components/series-chart-ticks.d.ts +13 -0
  96. package/dist/components/series-chart-ticks.js +29 -0
  97. package/dist/components/series-chart-ticks.js.map +1 -0
  98. package/dist/components/series-chart.js +33 -27
  99. package/dist/components/series-chart.js.map +1 -1
  100. package/dist/components/settings-fields.d.ts +2 -0
  101. package/dist/components/swatch-picker.d.ts +10 -1
  102. package/dist/components/swatch-picker.js +2 -0
  103. package/dist/components/swatch-picker.js.map +1 -1
  104. package/dist/components/swipeable-row.d.ts +11 -2
  105. package/dist/components/swipeable-row.js +5 -3
  106. package/dist/components/swipeable-row.js.map +1 -1
  107. package/dist/components/tile-radio.js +5 -7
  108. package/dist/components/tile-radio.js.map +1 -1
  109. package/dist/components/time-input.d.ts +2 -0
  110. package/dist/components/toggle-group.d.ts +13 -3
  111. package/dist/components/toggle-group.js +21 -1
  112. package/dist/components/toggle-group.js.map +1 -1
  113. package/dist/components/toggle-legend.js +1 -2
  114. package/dist/components/toggle-legend.js.map +1 -1
  115. package/dist/components/tooltip.d.ts +10 -4
  116. package/dist/components/tooltip.js +23 -6
  117. package/dist/components/tooltip.js.map +1 -1
  118. package/dist/components/treemap.d.ts +6 -1
  119. package/dist/components/treemap.js +16 -6
  120. package/dist/components/treemap.js.map +1 -1
  121. package/dist/components/ui.d.ts +36 -8
  122. package/dist/components/ui.js +27 -19
  123. package/dist/components/ui.js.map +1 -1
  124. package/dist/components/use-anchor-dir.d.ts +15 -0
  125. package/dist/components/use-anchor-dir.js +14 -0
  126. package/dist/components/use-anchor-dir.js.map +1 -0
  127. package/dist/components/use-mobile-reveal.d.ts +8 -1
  128. package/dist/components/use-mobile-reveal.js +3 -2
  129. package/dist/components/use-mobile-reveal.js.map +1 -1
  130. package/dist/components/use-table-state.d.ts +4 -4
  131. package/dist/components/use-table-state.js +12 -5
  132. package/dist/components/use-table-state.js.map +1 -1
  133. package/dist/{data-table-filters-DM1auUfH.d.ts → data-table-filters-noy0Abvi.d.ts} +40 -7
  134. package/dist/data-table.d.ts +1 -1
  135. package/dist/data-table.js.map +1 -1
  136. package/dist/feedback/feedback-attachment.d.ts +22 -3
  137. package/dist/feedback/feedback-attachment.js +15 -7
  138. package/dist/feedback/feedback-attachment.js.map +1 -1
  139. package/dist/feedback/feedback-dialog.d.ts +3 -2
  140. package/dist/feedback/feedback-dialog.js.map +1 -1
  141. package/dist/feedback.d.ts +1 -1
  142. package/dist/hooks/use-windowed-rows.d.ts +29 -0
  143. package/dist/hooks/use-windowed-rows.js +31 -0
  144. package/dist/hooks/use-windowed-rows.js.map +1 -0
  145. package/dist/i18n/defaults.d.ts +5 -0
  146. package/dist/i18n/defaults.js +5 -1
  147. package/dist/i18n/defaults.js.map +1 -1
  148. package/dist/i18n/kit-labels.d.ts +7 -0
  149. package/dist/i18n/kit-labels.js.map +1 -1
  150. package/dist/i18n/locales/de-CH.d.ts +45 -0
  151. package/dist/i18n/locales/de-CH.js +21 -0
  152. package/dist/i18n/locales/de-CH.js.map +1 -0
  153. package/dist/i18n/locales/de.d.ts +45 -0
  154. package/dist/i18n/locales/de.js +344 -0
  155. package/dist/i18n/locales/de.js.map +1 -0
  156. package/dist/i18n/locales/es.d.ts +45 -0
  157. package/dist/i18n/locales/es.js +339 -0
  158. package/dist/i18n/locales/es.js.map +1 -0
  159. package/dist/i18n/locales/fr.d.ts +45 -0
  160. package/dist/i18n/locales/fr.js +344 -0
  161. package/dist/i18n/locales/fr.js.map +1 -0
  162. package/dist/i18n/locales/hu.d.ts +45 -0
  163. package/dist/i18n/locales/hu.js +343 -0
  164. package/dist/i18n/locales/hu.js.map +1 -0
  165. package/dist/i18n/locales/it.d.ts +45 -0
  166. package/dist/i18n/locales/it.js +342 -0
  167. package/dist/i18n/locales/it.js.map +1 -0
  168. package/dist/i18n/locales/zh.d.ts +45 -0
  169. package/dist/i18n/locales/zh.js +338 -0
  170. package/dist/i18n/locales/zh.js.map +1 -0
  171. package/dist/index.d.ts +7 -4
  172. package/dist/index.js +4 -1
  173. package/dist/index.js.map +1 -1
  174. package/dist/lib/direction.d.ts +24 -0
  175. package/dist/lib/direction.js +19 -0
  176. package/dist/lib/direction.js.map +1 -0
  177. package/dist/rhf/form.d.ts +2 -0
  178. package/dist/rhf/form.js.map +1 -1
  179. package/dist/rhf.d.ts +2 -0
  180. package/dist/search/command-palette.d.ts +5 -0
  181. package/dist/search/command-palette.js +80 -50
  182. package/dist/search/command-palette.js.map +1 -1
  183. package/dist/shell/app-shell.d.ts +13 -1
  184. package/dist/shell/app-shell.js +134 -85
  185. package/dist/shell/app-shell.js.map +1 -1
  186. package/dist/shell/topbar-action-menu.js +1 -1
  187. package/dist/shell/topbar-action-menu.js.map +1 -1
  188. package/dist/shell/topbar-controls.d.ts +7 -3
  189. package/dist/shell/topbar-controls.js +38 -31
  190. package/dist/shell/topbar-controls.js.map +1 -1
  191. package/dist/theme/chart-palette.d.ts +7 -1
  192. package/dist/theme/chart-palette.js +2 -1
  193. package/dist/theme/chart-palette.js.map +1 -1
  194. package/dist/tour/tour.d.ts +11 -5
  195. package/dist/tour/tour.js +124 -58
  196. package/dist/tour/tour.js.map +1 -1
  197. package/dist/wizard/use-wizard.js +30 -13
  198. package/dist/wizard/use-wizard.js.map +1 -1
  199. package/dist/wizard/wizard-summary.js +1 -1
  200. package/dist/wizard/wizard-summary.js.map +1 -1
  201. package/package.json +12 -2
  202. package/src/components/account-settings.tsx +6 -2
  203. package/src/components/amount-input.tsx +10 -8
  204. package/src/components/autocomplete.tsx +110 -24
  205. package/src/components/calculator.tsx +5 -1
  206. package/src/components/chart-zoom.tsx +8 -1
  207. package/src/components/chart.tsx +68 -7
  208. package/src/components/chip.tsx +131 -49
  209. package/src/components/choice-card.tsx +77 -36
  210. package/src/components/combobox-core.tsx +147 -20
  211. package/src/components/combobox.tsx +100 -44
  212. package/src/components/currency-select.tsx +6 -6
  213. package/src/components/danger-confirm.tsx +90 -36
  214. package/src/components/data-table-pagination.tsx +32 -19
  215. package/src/components/data-table.tsx +198 -36
  216. package/src/components/date-picker.tsx +24 -7
  217. package/src/components/dialog-frame.tsx +97 -22
  218. package/src/components/disclosure.tsx +75 -13
  219. package/src/components/dropdown.tsx +17 -5
  220. package/src/components/entity-combobox.tsx +26 -13
  221. package/src/components/file-button.tsx +74 -5
  222. package/src/components/file-dropzone.tsx +44 -35
  223. package/src/components/grouped-picker.tsx +2 -2
  224. package/src/components/hover-menu.tsx +139 -10
  225. package/src/components/icon-picker.tsx +14 -1
  226. package/src/components/measured-grid.tsx +852 -0
  227. package/src/components/mini-calendar.tsx +11 -8
  228. package/src/components/month-picker.tsx +18 -11
  229. package/src/components/multi-entity-combobox.tsx +2 -2
  230. package/src/components/multi-select.tsx +34 -7
  231. package/src/components/number-input.tsx +4 -4
  232. package/src/components/numpad-sheet.tsx +5 -3
  233. package/src/components/picker-sheet.tsx +1 -1
  234. package/src/components/popover.tsx +18 -3
  235. package/src/components/series-chart-ticks.ts +52 -0
  236. package/src/components/series-chart.tsx +39 -31
  237. package/src/components/swatch-picker.tsx +11 -0
  238. package/src/components/swipeable-row.tsx +21 -6
  239. package/src/components/tile-radio.tsx +5 -7
  240. package/src/components/toggle-group.tsx +39 -3
  241. package/src/components/toggle-legend.tsx +5 -2
  242. package/src/components/tooltip.tsx +40 -12
  243. package/src/components/treemap.tsx +28 -5
  244. package/src/components/ui.tsx +79 -33
  245. package/src/components/use-anchor-dir.ts +20 -0
  246. package/src/components/use-mobile-reveal.ts +10 -2
  247. package/src/components/use-table-state.ts +44 -7
  248. package/src/data-table.ts +1 -0
  249. package/src/feedback/feedback-attachment.tsx +36 -9
  250. package/src/feedback/feedback-dialog.tsx +3 -2
  251. package/src/hooks/use-windowed-rows.ts +69 -0
  252. package/src/i18n/defaults.ts +4 -0
  253. package/src/i18n/kit-labels.tsx +4 -0
  254. package/src/i18n/locales/de-CH.ts +30 -0
  255. package/src/i18n/locales/de.ts +365 -0
  256. package/src/i18n/locales/es.ts +358 -0
  257. package/src/i18n/locales/fr.ts +371 -0
  258. package/src/i18n/locales/hu.ts +359 -0
  259. package/src/i18n/locales/it.ts +360 -0
  260. package/src/i18n/locales/zh.ts +348 -0
  261. package/src/index.ts +10 -1
  262. package/src/lib/direction.ts +37 -0
  263. package/src/rhf/form.tsx +21 -0
  264. package/src/search/command-palette.tsx +77 -19
  265. package/src/shell/app-shell.tsx +201 -130
  266. package/src/shell/topbar-action-menu.tsx +1 -1
  267. package/src/shell/topbar-controls.tsx +19 -8
  268. package/src/theme/chart-palette.ts +9 -2
  269. package/src/tour/tour.tsx +119 -18
  270. package/src/wizard/use-wizard.ts +55 -17
  271. package/src/wizard/wizard-summary.tsx +1 -1
@@ -7,6 +7,8 @@ import '../components/chip.js';
7
7
  import 'lucide-react';
8
8
  import '../components/field-sync.js';
9
9
  import '../components/ui.js';
10
+ import '../components/tooltip.js';
11
+ import '../hooks/use-anchored-rect.js';
10
12
  import '../wizard/types.js';
11
13
  import '../tour/tour.js';
12
14
  import '../search/command-palette.js';
@@ -24,6 +26,9 @@ import '../components/icon-picker.js';
24
26
  import '../components/dialog-frame.js';
25
27
  import '../components/modal.js';
26
28
  import '../components/file-button.js';
29
+ import '../components/measured-grid.js';
30
+ import '../feedback/feedback-attachment.js';
31
+ import '../feedback/feedback-dialog.js';
27
32
 
28
33
  /**
29
34
  * The whole English tree in one object: what a translation is written against, and
@@ -20,6 +20,8 @@ import { DEFAULT_SWATCH_PICKER_LABELS } from "../components/swatch-picker.js";
20
20
  import { DEFAULT_ICON_PICKER_LABELS } from "../components/icon-picker.js";
21
21
  import { DEFAULT_DIALOG_FRAME_LABELS } from "../components/dialog-frame.js";
22
22
  import { DEFAULT_FILE_PICKER_LABELS } from "../components/file-button.js";
23
+ import { DEFAULT_MEASURED_GRID_LABELS } from "../components/measured-grid.js";
24
+ import { DEFAULT_FEEDBACK_ATTACHMENT_LABELS } from "../feedback/feedback-attachment.js";
23
25
  import {
24
26
  DEFAULT_APP_SHELL_LABELS,
25
27
  DEFAULT_CALCULATOR_LABELS,
@@ -66,7 +68,9 @@ const DEFAULT_UI_KIT_LABELS = {
66
68
  swatchPicker: DEFAULT_SWATCH_PICKER_LABELS,
67
69
  iconPicker: DEFAULT_ICON_PICKER_LABELS,
68
70
  dialogFrame: DEFAULT_DIALOG_FRAME_LABELS,
69
- filePicker: DEFAULT_FILE_PICKER_LABELS
71
+ filePicker: DEFAULT_FILE_PICKER_LABELS,
72
+ measuredGrid: DEFAULT_MEASURED_GRID_LABELS,
73
+ feedbackAttachment: DEFAULT_FEEDBACK_ATTACHMENT_LABELS
70
74
  };
71
75
  export {
72
76
  DEFAULT_UI_KIT_LABELS
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/i18n/defaults.ts"],"sourcesContent":["import { DEFAULT_DATA_TABLE_LABELS } from \"../components/data-table-labels\";\nimport { DEFAULT_MINI_CALENDAR_LABELS } from \"../components/mini-calendar\";\nimport { DEFAULT_MONTH_PICKER_LABELS } from \"../components/month-picker\";\nimport { DEFAULT_PAGE_CONTENTS_LABELS } from \"../components/page-contents\";\nimport { DEFAULT_POPOVER_LABELS } from \"../components/popover\";\nimport { DEFAULT_CHIP_INPUT_LABELS } from \"../components/chip\";\nimport { DEFAULT_FIELD_SYNC_LABELS } from \"../components/field-sync\";\nimport { DEFAULT_PASSWORD_REVEAL_LABELS, DEFAULT_TABS_LABELS } from \"../components/ui\";\nimport { DEFAULT_WIZARD_LABELS } from \"../wizard/types\";\nimport { DEFAULT_TOUR_LABELS } from \"../tour/tour\";\nimport { DEFAULT_COMMAND_PALETTE_LABELS } from \"../search/command-palette\";\nimport { DEFAULT_SERIES_CHART_LABELS } from \"../components/series-chart-labels\";\nimport { DEFAULT_SPARKLINE_LABELS } from \"../components/sparkline\";\nimport { DEFAULT_STAT_TILE_LABELS } from \"../components/stat-tile\";\nimport { DEFAULT_SIGNATURE_PAD_LABELS } from \"../components/signature-pad\";\nimport { DEFAULT_PASSWORD_STRENGTH_LABELS } from \"../components/password-strength\";\nimport { DEFAULT_DANGER_CONFIRM_LABELS } from \"../components/danger-confirm\";\nimport { DEFAULT_SWATCH_PICKER_LABELS } from \"../components/swatch-picker\";\nimport { DEFAULT_ICON_PICKER_LABELS } from \"../components/icon-picker\";\nimport { DEFAULT_DIALOG_FRAME_LABELS } from \"../components/dialog-frame\";\nimport { DEFAULT_FILE_PICKER_LABELS } from \"../components/file-button\";\nimport {\n DEFAULT_APP_SHELL_LABELS,\n DEFAULT_CALCULATOR_LABELS,\n DEFAULT_COMBOBOX_LABELS,\n DEFAULT_COMMON_LABELS,\n DEFAULT_CURRENCY_LABELS,\n DEFAULT_DATE_PICKER_LABELS,\n DEFAULT_FILE_LABELS,\n DEFAULT_MULTI_SELECT_LABELS,\n DEFAULT_PICKER_SHEET_LABELS,\n DEFAULT_SWIPEABLE_ROW_LABELS,\n DEFAULT_TOP_BAR_LABELS,\n} from \"./kit-labels\";\nimport type { UiKitLabels } from \"./kit-labels\";\n\n/**\n * The whole English tree in one object: what a translation is written against, and\n * the `reference` for {@link missingKitLabels}.\n *\n * A separate module from the provider on purpose. Components import the provider's\n * hooks; this file imports the components' defaults. Kept together they would be an\n * import cycle through every component in the kit.\n */\nexport const DEFAULT_UI_KIT_LABELS: UiKitLabels = {\n common: DEFAULT_COMMON_LABELS,\n dataTable: DEFAULT_DATA_TABLE_LABELS,\n miniCalendar: DEFAULT_MINI_CALENDAR_LABELS,\n datePicker: DEFAULT_DATE_PICKER_LABELS,\n monthPicker: DEFAULT_MONTH_PICKER_LABELS,\n popover: DEFAULT_POPOVER_LABELS,\n combobox: DEFAULT_COMBOBOX_LABELS,\n multiSelect: DEFAULT_MULTI_SELECT_LABELS,\n calculator: DEFAULT_CALCULATOR_LABELS,\n currency: DEFAULT_CURRENCY_LABELS,\n chipInput: DEFAULT_CHIP_INPUT_LABELS,\n fieldSync: DEFAULT_FIELD_SYNC_LABELS,\n passwordReveal: DEFAULT_PASSWORD_REVEAL_LABELS,\n tabs: DEFAULT_TABS_LABELS,\n appShell: DEFAULT_APP_SHELL_LABELS,\n pageContents: DEFAULT_PAGE_CONTENTS_LABELS,\n topBar: DEFAULT_TOP_BAR_LABELS,\n pickerSheet: DEFAULT_PICKER_SHEET_LABELS,\n swipeableRow: DEFAULT_SWIPEABLE_ROW_LABELS,\n file: DEFAULT_FILE_LABELS,\n wizard: DEFAULT_WIZARD_LABELS,\n tour: DEFAULT_TOUR_LABELS,\n commandPalette: DEFAULT_COMMAND_PALETTE_LABELS,\n seriesChart: DEFAULT_SERIES_CHART_LABELS,\n sparkline: DEFAULT_SPARKLINE_LABELS,\n statTile: DEFAULT_STAT_TILE_LABELS,\n signaturePad: DEFAULT_SIGNATURE_PAD_LABELS,\n passwordStrength: DEFAULT_PASSWORD_STRENGTH_LABELS,\n dangerConfirm: DEFAULT_DANGER_CONFIRM_LABELS,\n swatchPicker: DEFAULT_SWATCH_PICKER_LABELS,\n iconPicker: DEFAULT_ICON_PICKER_LABELS,\n dialogFrame: DEFAULT_DIALOG_FRAME_LABELS,\n filePicker: DEFAULT_FILE_PICKER_LABELS,\n};\n"],"mappings":";AAAA,SAAS,iCAAiC;AAC1C,SAAS,oCAAoC;AAC7C,SAAS,mCAAmC;AAC5C,SAAS,oCAAoC;AAC7C,SAAS,8BAA8B;AACvC,SAAS,iCAAiC;AAC1C,SAAS,iCAAiC;AAC1C,SAAS,gCAAgC,2BAA2B;AACpE,SAAS,6BAA6B;AACtC,SAAS,2BAA2B;AACpC,SAAS,sCAAsC;AAC/C,SAAS,mCAAmC;AAC5C,SAAS,gCAAgC;AACzC,SAAS,gCAAgC;AACzC,SAAS,oCAAoC;AAC7C,SAAS,wCAAwC;AACjD,SAAS,qCAAqC;AAC9C,SAAS,oCAAoC;AAC7C,SAAS,kCAAkC;AAC3C,SAAS,mCAAmC;AAC5C,SAAS,kCAAkC;AAC3C;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAWA,MAAM,wBAAqC;AAAA,EAChD,QAAQ;AAAA,EACR,WAAW;AAAA,EACX,cAAc;AAAA,EACd,YAAY;AAAA,EACZ,aAAa;AAAA,EACb,SAAS;AAAA,EACT,UAAU;AAAA,EACV,aAAa;AAAA,EACb,YAAY;AAAA,EACZ,UAAU;AAAA,EACV,WAAW;AAAA,EACX,WAAW;AAAA,EACX,gBAAgB;AAAA,EAChB,MAAM;AAAA,EACN,UAAU;AAAA,EACV,cAAc;AAAA,EACd,QAAQ;AAAA,EACR,aAAa;AAAA,EACb,cAAc;AAAA,EACd,MAAM;AAAA,EACN,QAAQ;AAAA,EACR,MAAM;AAAA,EACN,gBAAgB;AAAA,EAChB,aAAa;AAAA,EACb,WAAW;AAAA,EACX,UAAU;AAAA,EACV,cAAc;AAAA,EACd,kBAAkB;AAAA,EAClB,eAAe;AAAA,EACf,cAAc;AAAA,EACd,YAAY;AAAA,EACZ,aAAa;AAAA,EACb,YAAY;AACd;","names":[]}
1
+ {"version":3,"sources":["../../src/i18n/defaults.ts"],"sourcesContent":["import { DEFAULT_DATA_TABLE_LABELS } from \"../components/data-table-labels\";\nimport { DEFAULT_MINI_CALENDAR_LABELS } from \"../components/mini-calendar\";\nimport { DEFAULT_MONTH_PICKER_LABELS } from \"../components/month-picker\";\nimport { DEFAULT_PAGE_CONTENTS_LABELS } from \"../components/page-contents\";\nimport { DEFAULT_POPOVER_LABELS } from \"../components/popover\";\nimport { DEFAULT_CHIP_INPUT_LABELS } from \"../components/chip\";\nimport { DEFAULT_FIELD_SYNC_LABELS } from \"../components/field-sync\";\nimport { DEFAULT_PASSWORD_REVEAL_LABELS, DEFAULT_TABS_LABELS } from \"../components/ui\";\nimport { DEFAULT_WIZARD_LABELS } from \"../wizard/types\";\nimport { DEFAULT_TOUR_LABELS } from \"../tour/tour\";\nimport { DEFAULT_COMMAND_PALETTE_LABELS } from \"../search/command-palette\";\nimport { DEFAULT_SERIES_CHART_LABELS } from \"../components/series-chart-labels\";\nimport { DEFAULT_SPARKLINE_LABELS } from \"../components/sparkline\";\nimport { DEFAULT_STAT_TILE_LABELS } from \"../components/stat-tile\";\nimport { DEFAULT_SIGNATURE_PAD_LABELS } from \"../components/signature-pad\";\nimport { DEFAULT_PASSWORD_STRENGTH_LABELS } from \"../components/password-strength\";\nimport { DEFAULT_DANGER_CONFIRM_LABELS } from \"../components/danger-confirm\";\nimport { DEFAULT_SWATCH_PICKER_LABELS } from \"../components/swatch-picker\";\nimport { DEFAULT_ICON_PICKER_LABELS } from \"../components/icon-picker\";\nimport { DEFAULT_DIALOG_FRAME_LABELS } from \"../components/dialog-frame\";\nimport { DEFAULT_FILE_PICKER_LABELS } from \"../components/file-button\";\nimport { DEFAULT_MEASURED_GRID_LABELS } from \"../components/measured-grid\";\nimport { DEFAULT_FEEDBACK_ATTACHMENT_LABELS } from \"../feedback/feedback-attachment\";\nimport {\n DEFAULT_APP_SHELL_LABELS,\n DEFAULT_CALCULATOR_LABELS,\n DEFAULT_COMBOBOX_LABELS,\n DEFAULT_COMMON_LABELS,\n DEFAULT_CURRENCY_LABELS,\n DEFAULT_DATE_PICKER_LABELS,\n DEFAULT_FILE_LABELS,\n DEFAULT_MULTI_SELECT_LABELS,\n DEFAULT_PICKER_SHEET_LABELS,\n DEFAULT_SWIPEABLE_ROW_LABELS,\n DEFAULT_TOP_BAR_LABELS,\n} from \"./kit-labels\";\nimport type { UiKitLabels } from \"./kit-labels\";\n\n/**\n * The whole English tree in one object: what a translation is written against, and\n * the `reference` for {@link missingKitLabels}.\n *\n * A separate module from the provider on purpose. Components import the provider's\n * hooks; this file imports the components' defaults. Kept together they would be an\n * import cycle through every component in the kit.\n */\nexport const DEFAULT_UI_KIT_LABELS: UiKitLabels = {\n common: DEFAULT_COMMON_LABELS,\n dataTable: DEFAULT_DATA_TABLE_LABELS,\n miniCalendar: DEFAULT_MINI_CALENDAR_LABELS,\n datePicker: DEFAULT_DATE_PICKER_LABELS,\n monthPicker: DEFAULT_MONTH_PICKER_LABELS,\n popover: DEFAULT_POPOVER_LABELS,\n combobox: DEFAULT_COMBOBOX_LABELS,\n multiSelect: DEFAULT_MULTI_SELECT_LABELS,\n calculator: DEFAULT_CALCULATOR_LABELS,\n currency: DEFAULT_CURRENCY_LABELS,\n chipInput: DEFAULT_CHIP_INPUT_LABELS,\n fieldSync: DEFAULT_FIELD_SYNC_LABELS,\n passwordReveal: DEFAULT_PASSWORD_REVEAL_LABELS,\n tabs: DEFAULT_TABS_LABELS,\n appShell: DEFAULT_APP_SHELL_LABELS,\n pageContents: DEFAULT_PAGE_CONTENTS_LABELS,\n topBar: DEFAULT_TOP_BAR_LABELS,\n pickerSheet: DEFAULT_PICKER_SHEET_LABELS,\n swipeableRow: DEFAULT_SWIPEABLE_ROW_LABELS,\n file: DEFAULT_FILE_LABELS,\n wizard: DEFAULT_WIZARD_LABELS,\n tour: DEFAULT_TOUR_LABELS,\n commandPalette: DEFAULT_COMMAND_PALETTE_LABELS,\n seriesChart: DEFAULT_SERIES_CHART_LABELS,\n sparkline: DEFAULT_SPARKLINE_LABELS,\n statTile: DEFAULT_STAT_TILE_LABELS,\n signaturePad: DEFAULT_SIGNATURE_PAD_LABELS,\n passwordStrength: DEFAULT_PASSWORD_STRENGTH_LABELS,\n dangerConfirm: DEFAULT_DANGER_CONFIRM_LABELS,\n swatchPicker: DEFAULT_SWATCH_PICKER_LABELS,\n iconPicker: DEFAULT_ICON_PICKER_LABELS,\n dialogFrame: DEFAULT_DIALOG_FRAME_LABELS,\n filePicker: DEFAULT_FILE_PICKER_LABELS,\n measuredGrid: DEFAULT_MEASURED_GRID_LABELS,\n feedbackAttachment: DEFAULT_FEEDBACK_ATTACHMENT_LABELS,\n};\n"],"mappings":";AAAA,SAAS,iCAAiC;AAC1C,SAAS,oCAAoC;AAC7C,SAAS,mCAAmC;AAC5C,SAAS,oCAAoC;AAC7C,SAAS,8BAA8B;AACvC,SAAS,iCAAiC;AAC1C,SAAS,iCAAiC;AAC1C,SAAS,gCAAgC,2BAA2B;AACpE,SAAS,6BAA6B;AACtC,SAAS,2BAA2B;AACpC,SAAS,sCAAsC;AAC/C,SAAS,mCAAmC;AAC5C,SAAS,gCAAgC;AACzC,SAAS,gCAAgC;AACzC,SAAS,oCAAoC;AAC7C,SAAS,wCAAwC;AACjD,SAAS,qCAAqC;AAC9C,SAAS,oCAAoC;AAC7C,SAAS,kCAAkC;AAC3C,SAAS,mCAAmC;AAC5C,SAAS,kCAAkC;AAC3C,SAAS,oCAAoC;AAC7C,SAAS,0CAA0C;AACnD;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAWA,MAAM,wBAAqC;AAAA,EAChD,QAAQ;AAAA,EACR,WAAW;AAAA,EACX,cAAc;AAAA,EACd,YAAY;AAAA,EACZ,aAAa;AAAA,EACb,SAAS;AAAA,EACT,UAAU;AAAA,EACV,aAAa;AAAA,EACb,YAAY;AAAA,EACZ,UAAU;AAAA,EACV,WAAW;AAAA,EACX,WAAW;AAAA,EACX,gBAAgB;AAAA,EAChB,MAAM;AAAA,EACN,UAAU;AAAA,EACV,cAAc;AAAA,EACd,QAAQ;AAAA,EACR,aAAa;AAAA,EACb,cAAc;AAAA,EACd,MAAM;AAAA,EACN,QAAQ;AAAA,EACR,MAAM;AAAA,EACN,gBAAgB;AAAA,EAChB,aAAa;AAAA,EACb,WAAW;AAAA,EACX,UAAU;AAAA,EACV,cAAc;AAAA,EACd,kBAAkB;AAAA,EAClB,eAAe;AAAA,EACf,cAAc;AAAA,EACd,YAAY;AAAA,EACZ,aAAa;AAAA,EACb,YAAY;AAAA,EACZ,cAAc;AAAA,EACd,oBAAoB;AACtB;","names":[]}
@@ -21,9 +21,14 @@ import { SwatchPickerLabels } from '../components/swatch-picker.js';
21
21
  import { IconPickerLabels } from '../components/icon-picker.js';
22
22
  import { DialogFrameLabels } from '../components/dialog-frame.js';
23
23
  import { FilePickerLabels } from '../components/file-button.js';
24
+ import { MeasuredGridLabels } from '../components/measured-grid.js';
25
+ import { FeedbackAttachmentFieldLabels } from '../feedback/feedback-attachment.js';
24
26
  import 'lucide-react';
27
+ import '../components/tooltip.js';
28
+ import '../hooks/use-anchored-rect.js';
25
29
  import '../components/tile-radio.js';
26
30
  import '../components/modal.js';
31
+ import '../feedback/feedback-dialog.js';
27
32
 
28
33
  /**
29
34
  * EVERY string the kit renders, as one typed tree — and an optional provider that
@@ -197,6 +202,8 @@ interface UiKitLabels {
197
202
  iconPicker: IconPickerLabels;
198
203
  dialogFrame: DialogFrameLabels;
199
204
  filePicker: FilePickerLabels;
205
+ measuredGrid: MeasuredGridLabels;
206
+ feedbackAttachment: FeedbackAttachmentFieldLabels;
200
207
  }
201
208
  /** Any subset of the tree, one level deep — each namespace may be partial, and a
202
209
  * namespace that holds a record (`dataTable.presets`) is merged key by key. */
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/i18n/kit-labels.tsx"],"sourcesContent":["import { createContext, useContext, useMemo } from \"react\";\nimport type { ReactNode } from \"react\";\nimport type { DataTableLabels } from \"../components/data-table-labels\";\nimport type { MiniCalendarLabels, WeekDay } from \"../components/mini-calendar\";\nimport type { PopoverLabels } from \"../components/popover\";\nimport type { ChipInputLabels } from \"../components/chip\";\nimport type { FieldSyncLabels } from \"../components/field-sync\";\nimport type { PasswordRevealLabels, TabsLabels } from \"../components/ui\";\nimport type { WizardLabels } from \"../wizard/types\";\nimport type { TourLabels } from \"../tour/tour\";\nimport type { CommandPaletteLabels } from \"../search/command-palette\";\nimport type { MonthPickerLabels } from \"../components/month-picker\";\nimport type { PageContentsLabels } from \"../components/page-contents\";\nimport type { SeriesChartLabels } from \"../components/series-chart-labels\";\nimport type { SparklineLabels } from \"../components/sparkline\";\nimport type { StatTileLabels } from \"../components/stat-tile\";\nimport type { SignaturePadLabels } from \"../components/signature-pad\";\nimport type { PasswordStrengthLabels } from \"../components/password-strength\";\nimport type { DangerConfirmLabels } from \"../components/danger-confirm\";\nimport type { SwatchPickerLabels } from \"../components/swatch-picker\";\nimport type { IconPickerLabels } from \"../components/icon-picker\";\nimport type { DialogFrameLabels } from \"../components/dialog-frame\";\nimport type { FilePickerLabels } from \"../components/file-button\";\n\n/**\n * EVERY string the kit renders, as one typed tree — and an optional provider that\n * hands it to every component at once.\n *\n * WHY THIS EXISTS. The kit ships no catalogue and resolves no strings, and that stays\n * true: the app supplies every word. What was wrong was HOW it had to supply them —\n * one `labels` prop per component instance, under a different prop name per\n * component (`labels`, `calendarLabels`, `passwordLabels`, `clearLabel`,\n * `searchPlaceholder`, `ariaLabel` …). A translated app therefore rendered English\n * wherever one call site forgot one prop, and nothing told it so: a German showcase\n * still said \"Rows per page\", \"Collapse sidebar\" and \"Popover\" in seven languages.\n *\n * Now there is one key per string, addressed by a dot path (`dataTable.pageSize`,\n * `datePicker.today`), and three sources in a fixed order of precedence:\n *\n * the component's own prop > <UiKitProvider labels> > English default\n *\n * A consumer writes its translation ONCE, as a `UiKitLabels` (or a partial of it),\n * mounts `<UiKitProvider labels={…} locale={…}>` at the root, and every kit component\n * below speaks that language — including the ones nested inside other kit components\n * (the calendar inside the data table's date filter, the popover inside the date\n * picker), which no prop at the outer call site could reach before.\n *\n * Messages that carry a value are FUNCTIONS of that value, never a template to fill:\n * a number glued into an English sentence is untranslatable, because the grammar\n * around it moves with it in most languages.\n */\n\n/* ── Namespaces that had no labels type of their own ─────────────────────── */\n\n/** The words several components share. A component's own namespace wins over these\n * where both exist; these are what a new component reaches for first. */\nexport interface CommonLabels {\n close: string;\n clear: string;\n search: string;\n done: string;\n cancel: string;\n save: string;\n back: string;\n next: string;\n remove: string;\n loading: string;\n noResults: string;\n /** \"Name: value\" — how a field's accessible name is composed with its value.\n * A colon-and-space is not universal punctuation (French puts a space before\n * the colon, Chinese uses a full-width one). */\n fieldValue: (field: string, value: string) => string;\n}\n\n/** `DatePicker` / `DateRangePicker` chrome. The calendar inside has its own\n * namespace, `miniCalendar`. */\nexport interface DatePickerLabels {\n /** Accessible name of the popover panel the calendar opens in. */\n panel: string;\n /** The same, for `DateRangePicker`'s panel. */\n rangePanel: string;\n clear: string;\n previousDay: string;\n nextDay: string;\n today: string;\n}\n\n/** The whole combobox family: `Combobox`, `EntityCombobox`,\n * `MultiEntityCombobox`, `InlineEntityCombobox`, `Autocomplete`. */\nexport interface ComboboxLabels {\n search: string;\n noResults: string;\n clear: string;\n loading: string;\n /** The \"add this\" row when free entry is allowed. */\n create: (query: string) => string;\n /** Trigger summary once more than one value is picked. */\n selectedCount: (count: number) => string;\n /** An async lookup (`loadOptions`) failed. */\n loadError: string;\n /** Announced (live region) when the list settles on `count` > 0 rows. */\n resultCount: (count: number) => string;\n /** The query is shorter than the `minChars` a lookup needs. */\n minChars: (count: number) => string;\n}\n\nexport interface MultiSelectLabels {\n search: string;\n selectAll: string;\n clear: string;\n /** Trigger text when nothing is picked, which a multi-select reads as \"all\". */\n all: string;\n /** Trigger summary once some (but not all) values are picked. The English\n * default is the bare count, which is what the trigger has always shown. */\n selectedCount: (count: number) => string;\n}\n\n/** `CalculatorButton` (desktop popover keypad) and `NumberPadSheet` (phone sheet). */\nexport interface CalculatorLabels {\n /** The button that opens the calculator. */\n open: string;\n /** The popover / sheet itself. */\n panel: string;\n calculation: string;\n backspace: string;\n clear: string;\n equals: string;\n /** The primary key of the phone pad — visible text, not an aria-label. */\n done: string;\n /** Names of the operator keys and the decimal key. Their glyphs are not names a\n * screen reader agrees on — \"÷\" is read as \"division sign\", \"divided by\" or\n * nothing at all depending on the reader — so each says what it does. */\n plus: string;\n minus: string;\n times: string;\n divide: string;\n decimal: string;\n}\n\n/** `CurrencySelect` and the currency half of `AmountInput`. */\nexport interface CurrencyLabels {\n currency: string;\n search: string;\n}\n\nexport interface AppShellLabels {\n collapse: string;\n expand: string;\n /** Accessible name of an inline group's disclosure button (`subNav=\"inline\"`). */\n toggleGroup: (groupLabel: string) => string;\n}\n\nexport interface TopBarLabels {\n theme: string;\n palette: string;\n language: string;\n switchRole: string;\n /** The role switcher's tooltip, given the active role's name. */\n role: (value: string) => string;\n}\n\nexport interface PickerSheetLabels {\n close: string;\n}\n\nexport interface SwipeableRowLabels {\n actions: string;\n}\n\nexport interface FileLabels {\n /** A file size for display, given its size in BYTES. The default uses\n * `Intl.NumberFormat`'s unit formatting in the provider's locale. */\n size: (bytes: number) => string;\n}\n\n/** The complete tree. `UiKitProvider` takes any partial of it. */\nexport interface UiKitLabels {\n common: CommonLabels;\n dataTable: DataTableLabels;\n miniCalendar: MiniCalendarLabels;\n datePicker: DatePickerLabels;\n monthPicker: MonthPickerLabels;\n popover: PopoverLabels;\n combobox: ComboboxLabels;\n multiSelect: MultiSelectLabels;\n calculator: CalculatorLabels;\n currency: CurrencyLabels;\n chipInput: ChipInputLabels;\n fieldSync: FieldSyncLabels;\n passwordReveal: PasswordRevealLabels;\n tabs: TabsLabels;\n appShell: AppShellLabels;\n pageContents: PageContentsLabels;\n topBar: TopBarLabels;\n pickerSheet: PickerSheetLabels;\n swipeableRow: SwipeableRowLabels;\n file: FileLabels;\n wizard: WizardLabels;\n tour: TourLabels;\n commandPalette: CommandPaletteLabels;\n seriesChart: SeriesChartLabels;\n sparkline: SparklineLabels;\n statTile: StatTileLabels;\n signaturePad: SignaturePadLabels;\n passwordStrength: PasswordStrengthLabels;\n dangerConfirm: DangerConfirmLabels;\n swatchPicker: SwatchPickerLabels;\n iconPicker: IconPickerLabels;\n dialogFrame: DialogFrameLabels;\n filePicker: FilePickerLabels;\n}\n\n/** Any subset of the tree, one level deep — each namespace may be partial, and a\n * namespace that holds a record (`dataTable.presets`) is merged key by key. */\nexport type UiKitLabelOverrides = { [K in keyof UiKitLabels]?: Partial<UiKitLabels[K]> };\n\n/* ── English defaults for the namespaces defined here ────────────────────── */\n\nexport const DEFAULT_COMMON_LABELS: CommonLabels = {\n close: \"Close\",\n clear: \"Clear\",\n search: \"Search\",\n done: \"Done\",\n cancel: \"Cancel\",\n save: \"Save\",\n back: \"Back\",\n next: \"Next\",\n remove: \"Remove\",\n loading: \"Loading…\",\n noResults: \"No results\",\n fieldValue: (field, value) => `${field}: ${value}`,\n};\n\nexport const DEFAULT_DATE_PICKER_LABELS: DatePickerLabels = {\n panel: \"Choose a date\",\n rangePanel: \"Choose a date range\",\n clear: \"Clear\",\n previousDay: \"Previous day\",\n nextDay: \"Next day\",\n today: \"Today\",\n};\n\nexport const DEFAULT_COMBOBOX_LABELS: ComboboxLabels = {\n search: \"Search\",\n noResults: \"No results\",\n clear: \"Clear\",\n loading: \"Loading…\",\n create: (query) => `Create “${query}”`,\n selectedCount: (count) => `${count} selected`,\n loadError: \"Couldn’t load results\",\n resultCount: (count) => (count === 1 ? \"1 result\" : `${count} results`),\n minChars: (count) =>\n count === 1 ? \"Type at least 1 character\" : `Type at least ${count} characters`,\n};\n\nexport const DEFAULT_MULTI_SELECT_LABELS: MultiSelectLabels = {\n search: \"Search\",\n selectAll: \"Select all\",\n clear: \"Clear\",\n all: \"All\",\n selectedCount: (count) => String(count),\n};\n\nexport const DEFAULT_CALCULATOR_LABELS: CalculatorLabels = {\n open: \"Open calculator\",\n panel: \"Calculator\",\n calculation: \"Calculation\",\n backspace: \"Backspace\",\n clear: \"Clear\",\n equals: \"Equals\",\n done: \"Done\",\n plus: \"Plus\",\n minus: \"Minus\",\n times: \"Times\",\n divide: \"Divide\",\n decimal: \"Decimal point\",\n};\n\nexport const DEFAULT_CURRENCY_LABELS: CurrencyLabels = {\n currency: \"Currency\",\n search: \"Search currency\",\n};\n\nexport const DEFAULT_APP_SHELL_LABELS: AppShellLabels = {\n collapse: \"Collapse sidebar\",\n expand: \"Expand sidebar\",\n toggleGroup: (groupLabel) => `${groupLabel}: pages`,\n};\n\nexport const DEFAULT_TOP_BAR_LABELS: TopBarLabels = {\n theme: \"Toggle theme\",\n palette: \"Appearance preset\",\n language: \"Language\",\n switchRole: \"Switch role\",\n role: (value) => `Role: ${value}`,\n};\n\nexport const DEFAULT_PICKER_SHEET_LABELS: PickerSheetLabels = { close: \"Close\" };\n\nexport const DEFAULT_SWIPEABLE_ROW_LABELS: SwipeableRowLabels = { actions: \"Row actions\" };\n\n/** Formats with the locale the provider was given (see {@link useKitFileLabels}).\n * This static default has no locale to hand and falls back to the runtime's. */\nexport const DEFAULT_FILE_LABELS: FileLabels = {\n size: (bytes) => formatFileSize(bytes),\n};\n\n/** \"12 kB\", \"3.4 MB\" — `Intl`'s unit formatting, so the digits, the decimal mark and\n * the unit's spelling all follow `locale`. */\nexport function formatFileSize(bytes: number, locale?: string): string {\n const units = [\"byte\", \"kilobyte\", \"megabyte\", \"gigabyte\"] as const;\n let value = bytes;\n let i = 0;\n while (value >= 1000 && i < units.length - 1) {\n value /= 1000;\n i += 1;\n }\n return new Intl.NumberFormat(locale, {\n style: \"unit\",\n unit: units[i],\n unitDisplay: i === 0 ? \"long\" : \"short\",\n maximumFractionDigits: value < 10 && i > 0 ? 1 : 0,\n }).format(value);\n}\n\n/* ── The provider ────────────────────────────────────────────────────────── */\n\ninterface KitI18n {\n labels?: UiKitLabelOverrides;\n locale?: string;\n weekStartsOn?: WeekDay;\n}\n\nconst KitI18nContext = createContext<KitI18n>({});\n\nexport interface UiKitProviderProps {\n /** Any part of {@link UiKitLabels}. Missing keys fall back to English. */\n labels?: UiKitLabelOverrides;\n /**\n * BCP 47 tag used by every kit component that formats something — dates, numbers,\n * month and weekday names, file sizes — when it is not handed a `locale` prop of\n * its own. Without a provider, and without a prop, those use the runtime default.\n */\n locale?: string;\n /**\n * The first day of the week (0 = Sunday, 1 = Monday …) for every calendar below —\n * `MiniCalendar` and the pickers built on it — that is not handed a `weekStartsOn`\n * of its own. Without it the week start follows `locale`'s week info.\n *\n * Separate from `locale` because the two are separate decisions: a German-built\n * app running in English (`locale=\"en\"`) would otherwise start its weeks on Sunday,\n * and switching it to `en-GB` to get Monday changes every date and number format.\n */\n weekStartsOn?: WeekDay;\n children: ReactNode;\n}\n\n/**\n * Hand every kit component below this point its strings and its locale.\n *\n * Optional: a component outside any provider behaves exactly as it did before the\n * provider existed. Nesting works as a merge — an inner provider overrides only what\n * it names, so a page can re-label one table's `dataTable.table` without restating\n * the language.\n */\nexport function UiKitProvider({ labels, locale, weekStartsOn, children }: UiKitProviderProps) {\n const outer = useContext(KitI18nContext);\n const value = useMemo<KitI18n>(\n () => ({\n locale: locale ?? outer.locale,\n weekStartsOn: weekStartsOn ?? outer.weekStartsOn,\n labels: mergeOverrides(outer.labels, labels),\n }),\n [outer, labels, locale, weekStartsOn],\n );\n return <KitI18nContext.Provider value={value}>{children}</KitI18nContext.Provider>;\n}\n\nfunction isRecord(v: unknown): v is Record<string, unknown> {\n return typeof v === \"object\" && v !== null && !Array.isArray(v);\n}\n\n/** Two levels: namespaces, and inside a namespace a record-valued key (presets). */\nfunction mergeNamespace<T extends object>(base: T, over: Partial<T> | undefined): T {\n if (!over) return base;\n const out = { ...base } as Record<string, unknown>;\n for (const [k, v] of Object.entries(over)) {\n if (v === undefined) continue;\n const prev = out[k];\n out[k] = isRecord(prev) && isRecord(v) ? { ...prev, ...v } : v;\n }\n return out as T;\n}\n\nfunction mergeOverrides(\n a: UiKitLabelOverrides | undefined,\n b: UiKitLabelOverrides | undefined,\n): UiKitLabelOverrides | undefined {\n if (!a) return b;\n if (!b) return a;\n const out: Record<string, unknown> = { ...a };\n for (const [ns, v] of Object.entries(b)) {\n out[ns] = mergeNamespace((out[ns] as object | undefined) ?? {}, v as object);\n }\n return out as UiKitLabelOverrides;\n}\n\n/** What the nearest provider says about one namespace — `undefined` outside one.\n * For a component whose own resolver does more than a merge (the data table\n * derives `columnsCount` from `columns`): feed `{ ...overrides, ...props }` to it. */\nexport function useKitLabelOverrides<K extends keyof UiKitLabels>(\n ns: K,\n): Partial<UiKitLabels[K]> | undefined {\n return useContext(KitI18nContext).labels?.[ns] as Partial<UiKitLabels[K]> | undefined;\n}\n\n/**\n * One namespace, resolved: `defaults`, then the provider, then the component's own\n * `prop`. Record-valued keys are merged key by key at each step.\n */\nexport function useKitLabels<K extends keyof UiKitLabels>(\n ns: K,\n defaults: UiKitLabels[K],\n prop?: Partial<UiKitLabels[K]>,\n): UiKitLabels[K] {\n const fromProvider = useKitLabelOverrides(ns);\n return useMemo(\n () => mergeNamespace(mergeNamespace(defaults, fromProvider), prop),\n [defaults, fromProvider, prop],\n );\n}\n\n/** The component's own `locale` prop, else the provider's, else `undefined` (which\n * every `Intl` API reads as \"the runtime's default\"). */\nexport function useKitLocale(prop?: string): string | undefined {\n const fromProvider = useContext(KitI18nContext).locale;\n return prop ?? fromProvider;\n}\n\n/** The week start the nearest `<UiKitProvider weekStartsOn>` pins, else `undefined`\n * (the caller then asks the locale). A component's own prop goes first:\n * `prop ?? useKitWeekStart()`. */\nexport function useKitWeekStart(): WeekDay | undefined {\n return useContext(KitI18nContext).weekStartsOn;\n}\n\n/** {@link DEFAULT_FILE_LABELS}, but formatting in the provider's locale. */\nexport function useKitFileLabels(prop?: Partial<FileLabels>): FileLabels {\n const locale = useKitLocale();\n const defaults = useMemo<FileLabels>(\n () => ({ size: (bytes) => formatFileSize(bytes, locale) }),\n [locale],\n );\n return useKitLabels(\"file\", defaults, prop);\n}\n\n/**\n * The dot paths of every key `labels` does NOT supply — the ones a translated app is\n * still showing in English. Assert on it in the app's own test:\n *\n * expect(missingKitLabels(de)).toEqual([]);\n *\n * `reference` is the complete tree to check against — pass\n * {@link DEFAULT_UI_KIT_LABELS} (src/i18n/defaults.ts). It is a parameter rather than an import\n * because the defaults live beside their components, and this module is imported BY\n * those components.\n */\nexport function missingKitLabels(\n labels: UiKitLabelOverrides | undefined,\n reference: UiKitLabels,\n): string[] {\n const missing: string[] = [];\n for (const [ns, keys] of Object.entries(reference)) {\n const given = (labels as Record<string, Record<string, unknown> | undefined> | undefined)?.[ns];\n for (const [key, value] of Object.entries(keys as Record<string, unknown>)) {\n const got = given?.[key];\n if (got === undefined) {\n missing.push(`${ns}.${key}`);\n } else if (isRecord(value) && isRecord(got)) {\n for (const sub of Object.keys(value)) {\n if (got[sub] === undefined) missing.push(`${ns}.${key}.${sub}`);\n }\n }\n }\n }\n return missing;\n}\n"],"mappings":";AAuXS;AAvXT,SAAS,eAAe,YAAY,eAAe;AA0N5C,MAAM,wBAAsC;AAAA,EACjD,OAAO;AAAA,EACP,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,MAAM;AAAA,EACN,QAAQ;AAAA,EACR,MAAM;AAAA,EACN,MAAM;AAAA,EACN,MAAM;AAAA,EACN,QAAQ;AAAA,EACR,SAAS;AAAA,EACT,WAAW;AAAA,EACX,YAAY,CAAC,OAAO,UAAU,GAAG,KAAK,KAAK,KAAK;AAClD;AAEO,MAAM,6BAA+C;AAAA,EAC1D,OAAO;AAAA,EACP,YAAY;AAAA,EACZ,OAAO;AAAA,EACP,aAAa;AAAA,EACb,SAAS;AAAA,EACT,OAAO;AACT;AAEO,MAAM,0BAA0C;AAAA,EACrD,QAAQ;AAAA,EACR,WAAW;AAAA,EACX,OAAO;AAAA,EACP,SAAS;AAAA,EACT,QAAQ,CAAC,UAAU,gBAAW,KAAK;AAAA,EACnC,eAAe,CAAC,UAAU,GAAG,KAAK;AAAA,EAClC,WAAW;AAAA,EACX,aAAa,CAAC,UAAW,UAAU,IAAI,aAAa,GAAG,KAAK;AAAA,EAC5D,UAAU,CAAC,UACT,UAAU,IAAI,8BAA8B,iBA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ACd,IACA,UACA,MACgB;AAChB,QAAM,eAAe,qBAAqB,EAAE;AAC5C,SAAO;AAAA,IACL,MAAM,eAAe,eAAe,UAAU,YAAY,GAAG,IAAI;AAAA,IACjE,CAAC,UAAU,cAAc,IAAI;AAAA,EAC/B;AACF;AAIO,SAAS,aAAa,MAAmC;AAC9D,QAAM,eAAe,WAAW,cAAc,EAAE;AAChD,SAAO,QAAQ;AACjB;AAKO,SAAS,kBAAuC;AACrD,SAAO,WAAW,cAAc,EAAE;AACpC;AAGO,SAAS,iBAAiB,MAAwC;AACvE,QAAM,SAAS,aAAa;AAC5B,QAAM,WAAW;AAAA,IACf,OAAO,EAAE,MAAM,CAAC,UAAU,eAAe,OAAO,MAAM,EAAE;AAAA,IACxD,CAAC,MAAM;AAAA,EACT;AACA,SAAO,aAAa,QAAQ,UAAU,IAAI;AAC5C;AAaO,SAAS,iBACd,QACA,WACU;AACV,QAAM,UAAoB,CAAC;AAC3B,aAAW,CAAC,IAAI,IAAI,KAAK,OAAO,QAAQ,SAAS,GAAG;AAClD,UAAM,QAAS,SAA6E,EAAE;AAC9F,eAAW,CAAC,KAAK,KAAK,KAAK,OAAO,QAAQ,IAA+B,GAAG;AAC1E,YAAM,MAAM,QAAQ,GAAG;AACvB,UAAI,QAAQ,QAAW;AACrB,gBAAQ,KAAK,GAAG,EAAE,IAAI,GAAG,EAAE;AAAA,MAC7B,WAAW,SAAS,KAAK,KAAK,SAAS,GAAG,GAAG;AAC3C,mBAAW,OAAO,OAAO,KAAK,KAAK,GAAG;AACpC,cAAI,IAAI,GAAG,MAAM,OAAW,SAAQ,KAAK,GAAG,EAAE,IAAI,GAAG,IAAI,GAAG,EAAE;AAAA,QAChE;AAAA,MACF;AAAA,IACF;AAAA,EACF;AACA,SAAO;AACT;","names":[]}
1
+ {"version":3,"sources":["../../src/i18n/kit-labels.tsx"],"sourcesContent":["import { createContext, useContext, useMemo } from \"react\";\nimport type { ReactNode } from \"react\";\nimport type { DataTableLabels } from \"../components/data-table-labels\";\nimport type { MiniCalendarLabels, WeekDay } from \"../components/mini-calendar\";\nimport type { PopoverLabels } from \"../components/popover\";\nimport type { ChipInputLabels } from \"../components/chip\";\nimport type { FieldSyncLabels } from \"../components/field-sync\";\nimport type { PasswordRevealLabels, TabsLabels } from \"../components/ui\";\nimport type { WizardLabels } from \"../wizard/types\";\nimport type { TourLabels } from \"../tour/tour\";\nimport type { CommandPaletteLabels } from \"../search/command-palette\";\nimport type { MonthPickerLabels } from \"../components/month-picker\";\nimport type { PageContentsLabels } from \"../components/page-contents\";\nimport type { SeriesChartLabels } from \"../components/series-chart-labels\";\nimport type { SparklineLabels } from \"../components/sparkline\";\nimport type { StatTileLabels } from \"../components/stat-tile\";\nimport type { SignaturePadLabels } from \"../components/signature-pad\";\nimport type { PasswordStrengthLabels } from \"../components/password-strength\";\nimport type { DangerConfirmLabels } from \"../components/danger-confirm\";\nimport type { SwatchPickerLabels } from \"../components/swatch-picker\";\nimport type { IconPickerLabels } from \"../components/icon-picker\";\nimport type { DialogFrameLabels } from \"../components/dialog-frame\";\nimport type { FilePickerLabels } from \"../components/file-button\";\nimport type { MeasuredGridLabels } from \"../components/measured-grid\";\nimport type { FeedbackAttachmentFieldLabels } from \"../feedback/feedback-attachment\";\n\n/**\n * EVERY string the kit renders, as one typed tree — and an optional provider that\n * hands it to every component at once.\n *\n * WHY THIS EXISTS. The kit ships no catalogue and resolves no strings, and that stays\n * true: the app supplies every word. What was wrong was HOW it had to supply them —\n * one `labels` prop per component instance, under a different prop name per\n * component (`labels`, `calendarLabels`, `passwordLabels`, `clearLabel`,\n * `searchPlaceholder`, `ariaLabel` …). A translated app therefore rendered English\n * wherever one call site forgot one prop, and nothing told it so: a German showcase\n * still said \"Rows per page\", \"Collapse sidebar\" and \"Popover\" in seven languages.\n *\n * Now there is one key per string, addressed by a dot path (`dataTable.pageSize`,\n * `datePicker.today`), and three sources in a fixed order of precedence:\n *\n * the component's own prop > <UiKitProvider labels> > English default\n *\n * A consumer writes its translation ONCE, as a `UiKitLabels` (or a partial of it),\n * mounts `<UiKitProvider labels={…} locale={…}>` at the root, and every kit component\n * below speaks that language — including the ones nested inside other kit components\n * (the calendar inside the data table's date filter, the popover inside the date\n * picker), which no prop at the outer call site could reach before.\n *\n * Messages that carry a value are FUNCTIONS of that value, never a template to fill:\n * a number glued into an English sentence is untranslatable, because the grammar\n * around it moves with it in most languages.\n */\n\n/* ── Namespaces that had no labels type of their own ─────────────────────── */\n\n/** The words several components share. A component's own namespace wins over these\n * where both exist; these are what a new component reaches for first. */\nexport interface CommonLabels {\n close: string;\n clear: string;\n search: string;\n done: string;\n cancel: string;\n save: string;\n back: string;\n next: string;\n remove: string;\n loading: string;\n noResults: string;\n /** \"Name: value\" — how a field's accessible name is composed with its value.\n * A colon-and-space is not universal punctuation (French puts a space before\n * the colon, Chinese uses a full-width one). */\n fieldValue: (field: string, value: string) => string;\n}\n\n/** `DatePicker` / `DateRangePicker` chrome. The calendar inside has its own\n * namespace, `miniCalendar`. */\nexport interface DatePickerLabels {\n /** Accessible name of the popover panel the calendar opens in. */\n panel: string;\n /** The same, for `DateRangePicker`'s panel. */\n rangePanel: string;\n clear: string;\n previousDay: string;\n nextDay: string;\n today: string;\n}\n\n/** The whole combobox family: `Combobox`, `EntityCombobox`,\n * `MultiEntityCombobox`, `InlineEntityCombobox`, `Autocomplete`. */\nexport interface ComboboxLabels {\n search: string;\n noResults: string;\n clear: string;\n loading: string;\n /** The \"add this\" row when free entry is allowed. */\n create: (query: string) => string;\n /** Trigger summary once more than one value is picked. */\n selectedCount: (count: number) => string;\n /** An async lookup (`loadOptions`) failed. */\n loadError: string;\n /** Announced (live region) when the list settles on `count` > 0 rows. */\n resultCount: (count: number) => string;\n /** The query is shorter than the `minChars` a lookup needs. */\n minChars: (count: number) => string;\n}\n\nexport interface MultiSelectLabels {\n search: string;\n selectAll: string;\n clear: string;\n /** Trigger text when nothing is picked, which a multi-select reads as \"all\". */\n all: string;\n /** Trigger summary once some (but not all) values are picked. The English\n * default is the bare count, which is what the trigger has always shown. */\n selectedCount: (count: number) => string;\n}\n\n/** `CalculatorButton` (desktop popover keypad) and `NumberPadSheet` (phone sheet). */\nexport interface CalculatorLabels {\n /** The button that opens the calculator. */\n open: string;\n /** The popover / sheet itself. */\n panel: string;\n calculation: string;\n backspace: string;\n clear: string;\n equals: string;\n /** The primary key of the phone pad — visible text, not an aria-label. */\n done: string;\n /** Names of the operator keys and the decimal key. Their glyphs are not names a\n * screen reader agrees on — \"÷\" is read as \"division sign\", \"divided by\" or\n * nothing at all depending on the reader — so each says what it does. */\n plus: string;\n minus: string;\n times: string;\n divide: string;\n decimal: string;\n}\n\n/** `CurrencySelect` and the currency half of `AmountInput`. */\nexport interface CurrencyLabels {\n currency: string;\n search: string;\n}\n\nexport interface AppShellLabels {\n collapse: string;\n expand: string;\n /** Accessible name of an inline group's disclosure button (`subNav=\"inline\"`). */\n toggleGroup: (groupLabel: string) => string;\n}\n\nexport interface TopBarLabels {\n theme: string;\n palette: string;\n language: string;\n switchRole: string;\n /** The role switcher's tooltip, given the active role's name. */\n role: (value: string) => string;\n}\n\nexport interface PickerSheetLabels {\n close: string;\n}\n\nexport interface SwipeableRowLabels {\n actions: string;\n}\n\nexport interface FileLabels {\n /** A file size for display, given its size in BYTES. The default uses\n * `Intl.NumberFormat`'s unit formatting in the provider's locale. */\n size: (bytes: number) => string;\n}\n\n/** The complete tree. `UiKitProvider` takes any partial of it. */\nexport interface UiKitLabels {\n common: CommonLabels;\n dataTable: DataTableLabels;\n miniCalendar: MiniCalendarLabels;\n datePicker: DatePickerLabels;\n monthPicker: MonthPickerLabels;\n popover: PopoverLabels;\n combobox: ComboboxLabels;\n multiSelect: MultiSelectLabels;\n calculator: CalculatorLabels;\n currency: CurrencyLabels;\n chipInput: ChipInputLabels;\n fieldSync: FieldSyncLabels;\n passwordReveal: PasswordRevealLabels;\n tabs: TabsLabels;\n appShell: AppShellLabels;\n pageContents: PageContentsLabels;\n topBar: TopBarLabels;\n pickerSheet: PickerSheetLabels;\n swipeableRow: SwipeableRowLabels;\n file: FileLabels;\n wizard: WizardLabels;\n tour: TourLabels;\n commandPalette: CommandPaletteLabels;\n seriesChart: SeriesChartLabels;\n sparkline: SparklineLabels;\n statTile: StatTileLabels;\n signaturePad: SignaturePadLabels;\n passwordStrength: PasswordStrengthLabels;\n dangerConfirm: DangerConfirmLabels;\n swatchPicker: SwatchPickerLabels;\n iconPicker: IconPickerLabels;\n dialogFrame: DialogFrameLabels;\n filePicker: FilePickerLabels;\n measuredGrid: MeasuredGridLabels;\n feedbackAttachment: FeedbackAttachmentFieldLabels;\n}\n\n/** Any subset of the tree, one level deep — each namespace may be partial, and a\n * namespace that holds a record (`dataTable.presets`) is merged key by key. */\nexport type UiKitLabelOverrides = { [K in keyof UiKitLabels]?: Partial<UiKitLabels[K]> };\n\n/* ── English defaults for the namespaces defined here ────────────────────── */\n\nexport const DEFAULT_COMMON_LABELS: CommonLabels = {\n close: \"Close\",\n clear: \"Clear\",\n search: \"Search\",\n done: \"Done\",\n cancel: \"Cancel\",\n save: \"Save\",\n back: \"Back\",\n next: \"Next\",\n remove: \"Remove\",\n loading: \"Loading…\",\n noResults: \"No results\",\n fieldValue: (field, value) => `${field}: ${value}`,\n};\n\nexport const DEFAULT_DATE_PICKER_LABELS: DatePickerLabels = {\n panel: \"Choose a date\",\n rangePanel: \"Choose a date range\",\n clear: \"Clear\",\n previousDay: \"Previous day\",\n nextDay: \"Next day\",\n today: \"Today\",\n};\n\nexport const DEFAULT_COMBOBOX_LABELS: ComboboxLabels = {\n search: \"Search\",\n noResults: \"No results\",\n clear: \"Clear\",\n loading: \"Loading…\",\n create: (query) => `Create “${query}”`,\n selectedCount: (count) => `${count} selected`,\n loadError: \"Couldn’t load results\",\n resultCount: (count) => (count === 1 ? \"1 result\" : `${count} results`),\n minChars: (count) =>\n count === 1 ? \"Type at least 1 character\" : `Type at least ${count} characters`,\n};\n\nexport const DEFAULT_MULTI_SELECT_LABELS: MultiSelectLabels = {\n search: \"Search\",\n selectAll: \"Select all\",\n clear: \"Clear\",\n all: \"All\",\n selectedCount: (count) => String(count),\n};\n\nexport const DEFAULT_CALCULATOR_LABELS: CalculatorLabels = {\n open: \"Open calculator\",\n panel: \"Calculator\",\n calculation: \"Calculation\",\n backspace: \"Backspace\",\n clear: \"Clear\",\n equals: \"Equals\",\n done: \"Done\",\n plus: \"Plus\",\n minus: \"Minus\",\n times: \"Times\",\n divide: \"Divide\",\n decimal: \"Decimal point\",\n};\n\nexport const DEFAULT_CURRENCY_LABELS: CurrencyLabels = {\n currency: \"Currency\",\n search: \"Search currency\",\n};\n\nexport const DEFAULT_APP_SHELL_LABELS: AppShellLabels = {\n collapse: \"Collapse sidebar\",\n expand: \"Expand sidebar\",\n toggleGroup: (groupLabel) => `${groupLabel}: pages`,\n};\n\nexport const DEFAULT_TOP_BAR_LABELS: TopBarLabels = {\n theme: \"Toggle theme\",\n palette: \"Appearance preset\",\n language: \"Language\",\n switchRole: \"Switch role\",\n role: (value) => `Role: ${value}`,\n};\n\nexport const DEFAULT_PICKER_SHEET_LABELS: PickerSheetLabels = { close: \"Close\" };\n\nexport const DEFAULT_SWIPEABLE_ROW_LABELS: SwipeableRowLabels = { actions: \"Row actions\" };\n\n/** Formats with the locale the provider was given (see {@link useKitFileLabels}).\n * This static default has no locale to hand and falls back to the runtime's. */\nexport const DEFAULT_FILE_LABELS: FileLabels = {\n size: (bytes) => formatFileSize(bytes),\n};\n\n/** \"12 kB\", \"3.4 MB\" — `Intl`'s unit formatting, so the digits, the decimal mark and\n * the unit's spelling all follow `locale`. */\nexport function formatFileSize(bytes: number, locale?: string): string {\n const units = [\"byte\", \"kilobyte\", \"megabyte\", \"gigabyte\"] as const;\n let value = bytes;\n let i = 0;\n while (value >= 1000 && i < units.length - 1) {\n value /= 1000;\n i += 1;\n }\n return new Intl.NumberFormat(locale, {\n style: \"unit\",\n unit: units[i],\n unitDisplay: i === 0 ? \"long\" : \"short\",\n maximumFractionDigits: value < 10 && i > 0 ? 1 : 0,\n }).format(value);\n}\n\n/* ── The provider ────────────────────────────────────────────────────────── */\n\ninterface KitI18n {\n labels?: UiKitLabelOverrides;\n locale?: string;\n weekStartsOn?: WeekDay;\n}\n\nconst KitI18nContext = createContext<KitI18n>({});\n\nexport interface UiKitProviderProps {\n /** Any part of {@link UiKitLabels}. Missing keys fall back to English. */\n labels?: UiKitLabelOverrides;\n /**\n * BCP 47 tag used by every kit component that formats something — dates, numbers,\n * month and weekday names, file sizes — when it is not handed a `locale` prop of\n * its own. Without a provider, and without a prop, those use the runtime default.\n */\n locale?: string;\n /**\n * The first day of the week (0 = Sunday, 1 = Monday …) for every calendar below —\n * `MiniCalendar` and the pickers built on it — that is not handed a `weekStartsOn`\n * of its own. Without it the week start follows `locale`'s week info.\n *\n * Separate from `locale` because the two are separate decisions: a German-built\n * app running in English (`locale=\"en\"`) would otherwise start its weeks on Sunday,\n * and switching it to `en-GB` to get Monday changes every date and number format.\n */\n weekStartsOn?: WeekDay;\n children: ReactNode;\n}\n\n/**\n * Hand every kit component below this point its strings and its locale.\n *\n * Optional: a component outside any provider behaves exactly as it did before the\n * provider existed. Nesting works as a merge — an inner provider overrides only what\n * it names, so a page can re-label one table's `dataTable.table` without restating\n * the language.\n */\nexport function UiKitProvider({ labels, locale, weekStartsOn, children }: UiKitProviderProps) {\n const outer = useContext(KitI18nContext);\n const value = useMemo<KitI18n>(\n () => ({\n locale: locale ?? outer.locale,\n weekStartsOn: weekStartsOn ?? outer.weekStartsOn,\n labels: mergeOverrides(outer.labels, labels),\n }),\n [outer, labels, locale, weekStartsOn],\n );\n return <KitI18nContext.Provider value={value}>{children}</KitI18nContext.Provider>;\n}\n\nfunction isRecord(v: unknown): v is Record<string, unknown> {\n return typeof v === \"object\" && v !== null && !Array.isArray(v);\n}\n\n/** Two levels: namespaces, and inside a namespace a record-valued key (presets). */\nfunction mergeNamespace<T extends object>(base: T, over: Partial<T> | undefined): T {\n if (!over) return base;\n const out = { ...base } as Record<string, unknown>;\n for (const [k, v] of Object.entries(over)) {\n if (v === undefined) continue;\n const prev = out[k];\n out[k] = isRecord(prev) && isRecord(v) ? { ...prev, ...v } : v;\n }\n return out as T;\n}\n\nfunction mergeOverrides(\n a: UiKitLabelOverrides | undefined,\n b: UiKitLabelOverrides | undefined,\n): UiKitLabelOverrides | undefined {\n if (!a) return b;\n if (!b) return a;\n const out: Record<string, unknown> = { ...a };\n for (const [ns, v] of Object.entries(b)) {\n out[ns] = mergeNamespace((out[ns] as object | undefined) ?? {}, v as object);\n }\n return out as UiKitLabelOverrides;\n}\n\n/** What the nearest provider says about one namespace — `undefined` outside one.\n * For a component whose own resolver does more than a merge (the data table\n * derives `columnsCount` from `columns`): feed `{ ...overrides, ...props }` to it. */\nexport function useKitLabelOverrides<K extends keyof UiKitLabels>(\n ns: K,\n): Partial<UiKitLabels[K]> | undefined {\n return useContext(KitI18nContext).labels?.[ns] as Partial<UiKitLabels[K]> | undefined;\n}\n\n/**\n * One namespace, resolved: `defaults`, then the provider, then the component's own\n * `prop`. Record-valued keys are merged key by key at each step.\n */\nexport function useKitLabels<K extends keyof UiKitLabels>(\n ns: K,\n defaults: UiKitLabels[K],\n prop?: Partial<UiKitLabels[K]>,\n): UiKitLabels[K] {\n const fromProvider = useKitLabelOverrides(ns);\n return useMemo(\n () => mergeNamespace(mergeNamespace(defaults, fromProvider), prop),\n [defaults, fromProvider, prop],\n );\n}\n\n/** The component's own `locale` prop, else the provider's, else `undefined` (which\n * every `Intl` API reads as \"the runtime's default\"). */\nexport function useKitLocale(prop?: string): string | undefined {\n const fromProvider = useContext(KitI18nContext).locale;\n return prop ?? fromProvider;\n}\n\n/** The week start the nearest `<UiKitProvider weekStartsOn>` pins, else `undefined`\n * (the caller then asks the locale). A component's own prop goes first:\n * `prop ?? useKitWeekStart()`. */\nexport function useKitWeekStart(): WeekDay | undefined {\n return useContext(KitI18nContext).weekStartsOn;\n}\n\n/** {@link DEFAULT_FILE_LABELS}, but formatting in the provider's locale. */\nexport function useKitFileLabels(prop?: Partial<FileLabels>): FileLabels {\n const locale = useKitLocale();\n const defaults = useMemo<FileLabels>(\n () => ({ size: (bytes) => formatFileSize(bytes, locale) }),\n [locale],\n );\n return useKitLabels(\"file\", defaults, prop);\n}\n\n/**\n * The dot paths of every key `labels` does NOT supply — the ones a translated app is\n * still showing in English. Assert on it in the app's own test:\n *\n * expect(missingKitLabels(de)).toEqual([]);\n *\n * `reference` is the complete tree to check against — pass\n * {@link DEFAULT_UI_KIT_LABELS} (src/i18n/defaults.ts). It is a parameter rather than an import\n * because the defaults live beside their components, and this module is imported BY\n * those components.\n */\nexport function missingKitLabels(\n labels: UiKitLabelOverrides | undefined,\n reference: UiKitLabels,\n): string[] {\n const missing: string[] = [];\n for (const [ns, keys] of Object.entries(reference)) {\n const given = (labels as Record<string, Record<string, unknown> | undefined> | undefined)?.[ns];\n for (const [key, value] of Object.entries(keys as Record<string, unknown>)) {\n const got = given?.[key];\n if (got === undefined) {\n missing.push(`${ns}.${key}`);\n } else if (isRecord(value) && isRecord(got)) {\n for (const sub of Object.keys(value)) {\n if (got[sub] === undefined) missing.push(`${ns}.${key}.${sub}`);\n }\n }\n }\n }\n return missing;\n}\n"],"mappings":";AA2XS;AA3XT,SAAS,eAAe,YAAY,eAAe;AA8N5C,MAAM,wBAAsC;AAAA,EACjD,OAAO;AAAA,EACP,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,MAAM;AAAA,EACN,QAAQ;AAAA,EACR,MAAM;AAAA,EACN,MAAM;AAAA,EACN,MAAM;AAAA,EACN,QAAQ;AAAA,EACR,SAAS;AAAA,EACT,WAAW;AAAA,EACX,YAAY,CAAC,OAAO,UAAU,GAAG,KAAK,KAAK,KAAK;AAClD;AAEO,MAAM,6BAA+C;AAAA,EAC1D,OAAO;AAAA,EACP,YAAY;AAAA,EACZ,OAAO;AAAA,EACP,aAAa;AAAA,EACb,SAAS;AAAA,EACT,OAAO;AACT;AAEO,MAAM,0BAA0C;A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;AACpC,cAAI,IAAI,GAAG,MAAM,OAAW,SAAQ,KAAK,GAAG,EAAE,IAAI,GAAG,IAAI,GAAG,EAAE;AAAA,QAChE;AAAA,MACF;AAAA,IACF;AAAA,EACF;AACA,SAAO;AACT;","names":[]}
@@ -0,0 +1,45 @@
1
+ import { UiKitLabels } from '../kit-labels.js';
2
+ import 'react';
3
+ import '../../components/data-table-labels.js';
4
+ import '../../components/mini-calendar.js';
5
+ import '../../components/popover.js';
6
+ import '../../components/chip.js';
7
+ import 'lucide-react';
8
+ import '../../components/field-sync.js';
9
+ import '../../components/ui.js';
10
+ import '../../components/tooltip.js';
11
+ import '../../hooks/use-anchored-rect.js';
12
+ import '../../wizard/types.js';
13
+ import '../../tour/tour.js';
14
+ import '../../search/command-palette.js';
15
+ import '../../components/month-picker.js';
16
+ import '../../components/page-contents.js';
17
+ import '../../components/series-chart-labels.js';
18
+ import '../../components/sparkline.js';
19
+ import '../../components/stat-tile.js';
20
+ import '../../components/signature-pad.js';
21
+ import '../../components/password-strength.js';
22
+ import '../../components/danger-confirm.js';
23
+ import '../../components/swatch-picker.js';
24
+ import '../../components/tile-radio.js';
25
+ import '../../components/icon-picker.js';
26
+ import '../../components/dialog-frame.js';
27
+ import '../../components/modal.js';
28
+ import '../../components/file-button.js';
29
+ import '../../components/measured-grid.js';
30
+ import '../../feedback/feedback-attachment.js';
31
+ import '../../feedback/feedback-dialog.js';
32
+
33
+ /**
34
+ * Swiss Standard German: the German labels with Swiss spelling — "ss" for every "ß"
35
+ * (Schliessen, Grösse), which is the one systematic difference in UI text — and
36
+ * `de-CH` number formatting (1’234.5).
37
+ *
38
+ * Derived rather than duplicated, so a key added to the German labels is Swiss the
39
+ * moment it lands. Function labels are wrapped: their RESULT is respelled, so an
40
+ * argument the app passes in (a file name, a phrase to type) is respelled too — which
41
+ * is what a Swiss app writing "ss" everywhere wants.
42
+ */
43
+ declare const UI_KIT_LABELS_DE_CH: UiKitLabels;
44
+
45
+ export { UI_KIT_LABELS_DE_CH };
@@ -0,0 +1,21 @@
1
+ "use client";
2
+ import { uiKitLabelsDe } from "./de.js";
3
+ const UI_KIT_LABELS_DE_CH = swiss(uiKitLabelsDe("de-CH"));
4
+ function respell(text) {
5
+ return text.replace(/ß/g, "ss").replace(/ẞ/g, "SS");
6
+ }
7
+ function swiss(value) {
8
+ if (typeof value === "string") return respell(value);
9
+ if (typeof value === "function") {
10
+ const fn = value;
11
+ return ((...args) => swiss(fn(...args)));
12
+ }
13
+ if (value && typeof value === "object") {
14
+ return Object.fromEntries(Object.entries(value).map(([k, v]) => [k, swiss(v)]));
15
+ }
16
+ return value;
17
+ }
18
+ export {
19
+ UI_KIT_LABELS_DE_CH
20
+ };
21
+ //# sourceMappingURL=de-CH.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/i18n/locales/de-CH.ts"],"sourcesContent":["import type { UiKitLabels } from \"../kit-labels\";\nimport { uiKitLabelsDe } from \"./de\";\n\n/**\n * Swiss Standard German: the German labels with Swiss spelling — \"ss\" for every \"ß\"\n * (Schliessen, Grösse), which is the one systematic difference in UI text — and\n * `de-CH` number formatting (1’234.5).\n *\n * Derived rather than duplicated, so a key added to the German labels is Swiss the\n * moment it lands. Function labels are wrapped: their RESULT is respelled, so an\n * argument the app passes in (a file name, a phrase to type) is respelled too — which\n * is what a Swiss app writing \"ss\" everywhere wants.\n */\nexport const UI_KIT_LABELS_DE_CH: UiKitLabels = swiss(uiKitLabelsDe(\"de-CH\"));\n\nfunction respell(text: string): string {\n return text.replace(/ß/g, \"ss\").replace(/ẞ/g, \"SS\");\n}\n\nfunction swiss<T>(value: T): T {\n if (typeof value === \"string\") return respell(value) as T;\n if (typeof value === \"function\") {\n const fn = value as (...args: unknown[]) => unknown;\n return ((...args: unknown[]) => swiss(fn(...args))) as T;\n }\n if (value && typeof value === \"object\") {\n return Object.fromEntries(Object.entries(value).map(([k, v]) => [k, swiss(v)])) as T;\n }\n return value;\n}\n"],"mappings":";AACA,SAAS,qBAAqB;AAYvB,MAAM,sBAAmC,MAAM,cAAc,OAAO,CAAC;AAE5E,SAAS,QAAQ,MAAsB;AACrC,SAAO,KAAK,QAAQ,MAAM,IAAI,EAAE,QAAQ,MAAM,IAAI;AACpD;AAEA,SAAS,MAAS,OAAa;AAC7B,MAAI,OAAO,UAAU,SAAU,QAAO,QAAQ,KAAK;AACnD,MAAI,OAAO,UAAU,YAAY;AAC/B,UAAM,KAAK;AACX,YAAQ,IAAI,SAAoB,MAAM,GAAG,GAAG,IAAI,CAAC;AAAA,EACnD;AACA,MAAI,SAAS,OAAO,UAAU,UAAU;AACtC,WAAO,OAAO,YAAY,OAAO,QAAQ,KAAK,EAAE,IAAI,CAAC,CAAC,GAAG,CAAC,MAAM,CAAC,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC;AAAA,EAChF;AACA,SAAO;AACT;","names":[]}
@@ -0,0 +1,45 @@
1
+ import { UiKitLabels } from '../kit-labels.js';
2
+ import 'react';
3
+ import '../../components/data-table-labels.js';
4
+ import '../../components/mini-calendar.js';
5
+ import '../../components/popover.js';
6
+ import '../../components/chip.js';
7
+ import 'lucide-react';
8
+ import '../../components/field-sync.js';
9
+ import '../../components/ui.js';
10
+ import '../../components/tooltip.js';
11
+ import '../../hooks/use-anchored-rect.js';
12
+ import '../../wizard/types.js';
13
+ import '../../tour/tour.js';
14
+ import '../../search/command-palette.js';
15
+ import '../../components/month-picker.js';
16
+ import '../../components/page-contents.js';
17
+ import '../../components/series-chart-labels.js';
18
+ import '../../components/sparkline.js';
19
+ import '../../components/stat-tile.js';
20
+ import '../../components/signature-pad.js';
21
+ import '../../components/password-strength.js';
22
+ import '../../components/danger-confirm.js';
23
+ import '../../components/swatch-picker.js';
24
+ import '../../components/tile-radio.js';
25
+ import '../../components/icon-picker.js';
26
+ import '../../components/dialog-frame.js';
27
+ import '../../components/modal.js';
28
+ import '../../components/file-button.js';
29
+ import '../../components/measured-grid.js';
30
+ import '../../feedback/feedback-attachment.js';
31
+ import '../../feedback/feedback-dialog.js';
32
+
33
+ /**
34
+ * The kit's words in German: every namespace of {@link UiKitLabels}, for
35
+ * `<UiKitProvider labels={UI_KIT_LABELS_DE}>`.
36
+ *
37
+ * Self-contained on purpose — nothing but the kit's own `formatFileSize` — so it works
38
+ * as a starting point to copy and adjust. Counts and sizes are formatted with
39
+ * `de-DE` digits; {@link uiKitLabelsDe} takes another number locale
40
+ * (e.g. `"de-CH"` for 1’234) without touching the words.
41
+ */
42
+ declare function uiKitLabelsDe(numberLocale?: string): UiKitLabels;
43
+ declare const UI_KIT_LABELS_DE: UiKitLabels;
44
+
45
+ export { UI_KIT_LABELS_DE, uiKitLabelsDe };