@12-apps/ui 6.40.0 → 6.41.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 (650) hide show
  1. package/NATIVE.md +1 -1
  2. package/components-catalog.md +43 -5
  3. package/dist/_internal/components/data-display/Badge/Badge.js +3 -3
  4. package/dist/_internal/components/data-display/Badge/Badge.styles.js +3 -3
  5. package/dist/_internal/components/data-display/Badge/BadgeContent.js +3 -3
  6. package/dist/_internal/components/data-display/CardKit/CardKebab.js +5 -5
  7. package/dist/_internal/components/data-display/CardKit/use-remove-confirm.js +5 -5
  8. package/dist/_internal/components/data-display/CardKit/use-row-confirm.js +5 -5
  9. package/dist/_internal/components/data-display/Carousel/Carousel.chrome.js +3 -3
  10. package/dist/_internal/components/data-display/Carousel/Carousel.js +3 -3
  11. package/dist/_internal/components/data-display/Carousel/Carousel.parts.js +3 -3
  12. package/dist/_internal/components/data-display/Carousel/Carousel.styles.js +3 -3
  13. package/dist/_internal/components/data-display/Chart/Chart.js +3 -3
  14. package/dist/_internal/components/data-display/Chart/SpecChart.js +3 -3
  15. package/dist/_internal/components/data-display/Chart/chart-context.js +3 -3
  16. package/dist/_internal/components/data-display/Chart/chart-internals.js +3 -3
  17. package/dist/_internal/components/data-display/Chart/chart-renderers.js +3 -3
  18. package/dist/_internal/components/data-display/DataViews/DataViewsGrid.js +49 -49
  19. package/dist/_internal/components/data-display/DataViews/DataViewsTableBase.js +64 -64
  20. package/dist/_internal/components/data-display/DataViews/DeleteViewDialog.js +7 -7
  21. package/dist/_internal/components/data-display/DataViews/ManageViewsDialog.js +8 -8
  22. package/dist/_internal/components/data-display/DataViews/SaveViewModal.js +14 -14
  23. package/dist/_internal/components/data-display/DataViews/base-card.js +3 -3
  24. package/dist/_internal/components/data-display/DataViews/base-list-card.js +3 -3
  25. package/dist/_internal/components/data-display/DataViews/data-views-bar-controls.js +3 -3
  26. package/dist/_internal/components/data-display/DataViews/data-views-category-pill.js +18 -18
  27. package/dist/_internal/components/data-display/DataViews/data-views-columns.js +6 -6
  28. package/dist/_internal/components/data-display/DataViews/data-views-day-input.js +3 -3
  29. package/dist/_internal/components/data-display/DataViews/data-views-display-panel.js +6 -6
  30. package/dist/_internal/components/data-display/DataViews/data-views-empty.js +5 -5
  31. package/dist/_internal/components/data-display/DataViews/data-views-export.js +5 -5
  32. package/dist/_internal/components/data-display/DataViews/data-views-filter-panel.js +23 -23
  33. package/dist/_internal/components/data-display/DataViews/data-views-grid-bodies.js +7 -7
  34. package/dist/_internal/components/data-display/DataViews/data-views-grid-helpers.js +5 -5
  35. package/dist/_internal/components/data-display/DataViews/data-views-grid-parts.js +46 -46
  36. package/dist/_internal/components/data-display/DataViews/data-views-inline-bar.js +29 -29
  37. package/dist/_internal/components/data-display/DataViews/data-views-more-fields.js +37 -14
  38. package/dist/_internal/components/data-display/DataViews/data-views-more-filters.js +38 -17
  39. package/dist/_internal/components/data-display/DataViews/data-views-number-input.js +3 -3
  40. package/dist/_internal/components/data-display/DataViews/data-views-overflow.js +1 -1
  41. package/dist/_internal/components/data-display/DataViews/data-views-pagination.js +5 -5
  42. package/dist/_internal/components/data-display/DataViews/data-views-range-pill.js +6 -6
  43. package/dist/_internal/components/data-display/DataViews/data-views-search.js +3 -3
  44. package/dist/_internal/components/data-display/DataViews/data-views-select-all-strip.js +5 -5
  45. package/dist/_internal/components/data-display/DataViews/data-views-shell-toolbar.js +17 -17
  46. package/dist/_internal/components/data-display/DataViews/data-views-table-parts.js +24 -24
  47. package/dist/_internal/components/data-display/DataViews/data-views-toolbar.js +16 -16
  48. package/dist/_internal/components/data-display/DataViews/data-views-view-nav.js +5 -5
  49. package/dist/_internal/components/data-display/DataViews/use-data-views-state.js +7 -7
  50. package/dist/_internal/components/data-display/FleetMap/FleetBody.js +7 -7
  51. package/dist/_internal/components/data-display/FleetMap/FleetCanvas.js +6 -6
  52. package/dist/_internal/components/data-display/FleetMap/FleetMap.fixtures.js +2 -2
  53. package/dist/_internal/components/data-display/FleetMap/FleetMap.js +9 -9
  54. package/dist/_internal/components/data-display/MapPreview/MapLayers.js +4 -4
  55. package/dist/_internal/components/data-display/MapPreview/MapPreview.js +5 -5
  56. package/dist/_internal/components/data-display/MapPreview/MapSearchBar.js +3 -3
  57. package/dist/_internal/components/data-display/Sheet/Sheet.body.js +3 -3
  58. package/dist/_internal/components/data-display/Sheet/Sheet.js +3 -3
  59. package/dist/_internal/components/data-display/Sheet/Sheet.styles.js +3 -3
  60. package/dist/_internal/components/data-display/index.js +9 -9
  61. package/dist/_internal/components/feedback/ConfirmAction/ConfirmButton.js +5 -5
  62. package/dist/_internal/components/feedback/Dialog/Dialog.js +2 -2
  63. package/dist/_internal/components/feedback/NotificationStatusNotice/NotificationStatusNotice.js +5 -5
  64. package/dist/_internal/components/feedback/index.js +8 -8
  65. package/dist/_internal/components/form/AddressAutocomplete/AddressAutocomplete.js +7 -7
  66. package/dist/_internal/components/form/AddressAutocomplete/AddressAutocompleteField.js +5 -5
  67. package/dist/_internal/components/form/AddressAutocomplete/AddressFallbackField.js +4 -4
  68. package/dist/_internal/components/form/AddressAutocomplete/AddressInputField.js +4 -4
  69. package/dist/_internal/components/form/AddressAutocomplete/AddressTextField.js +3 -3
  70. package/dist/_internal/components/form/Autocomplete/Autocomplete.js +5 -5
  71. package/dist/_internal/components/form/Autocomplete/Autocomplete.parts.js +3 -3
  72. package/dist/_internal/components/form/Autocomplete/useAutocomplete.js +1 -1
  73. package/dist/_internal/components/form/Button/Button.js +4 -4
  74. package/dist/_internal/components/form/Button/Button.styles.js +3 -3
  75. package/dist/_internal/components/form/CategorySelect/CategoryPanel.js +8 -8
  76. package/dist/_internal/components/form/CategorySelect/CategoryPanelFoot.js +4 -4
  77. package/dist/_internal/components/form/CategorySelect/CategoryPanelHead.js +4 -4
  78. package/dist/_internal/components/form/CategorySelect/CategoryPanelList.js +5 -5
  79. package/dist/_internal/components/form/CategorySelect/CategoryRows.js +4 -4
  80. package/dist/_internal/components/form/CategorySelect/CategorySelect.js +10 -10
  81. package/dist/_internal/components/form/CategorySelect/CategorySelect.styles.js +3 -3
  82. package/dist/_internal/components/form/CategorySelect/CategoryTrigger.js +4 -4
  83. package/dist/_internal/components/form/CepField/CepField.js +5 -5
  84. package/dist/_internal/components/form/CodeEditor/CodeEditor.js +2 -2
  85. package/dist/_internal/components/form/Command/Command.js +3 -3
  86. package/dist/_internal/components/form/Command/Command.styles.js +3 -3
  87. package/dist/_internal/components/form/CreatableSelect/CreatableSelect.js +3 -3
  88. package/dist/_internal/components/form/DateRangePicker/DateRangePicker.hooks.js +5 -5
  89. package/dist/_internal/components/form/DateRangePicker/DateRangePicker.js +7 -7
  90. package/dist/_internal/components/form/DateRangePicker/DateRangePicker.range.js +4 -4
  91. package/dist/_internal/components/form/DateRangePicker/DateRangePickerFields.js +5 -5
  92. package/dist/_internal/components/form/Input/Input.js +4 -4
  93. package/dist/_internal/components/form/Input/Input.styles.js +3 -3
  94. package/dist/_internal/components/form/InputOTP/InputOTP.js +4 -4
  95. package/dist/_internal/components/form/InputOTP/InputOTP.styles.js +3 -3
  96. package/dist/_internal/components/form/Label/Label.js +3 -3
  97. package/dist/_internal/components/form/Label/Label.styles.js +3 -3
  98. package/dist/_internal/components/form/Menubar/Menubar.item.js +3 -3
  99. package/dist/_internal/components/form/Menubar/Menubar.js +3 -3
  100. package/dist/_internal/components/form/Menubar/Menubar.styles.js +3 -3
  101. package/dist/_internal/components/form/Menubar/Menubar.toolbar.js +3 -3
  102. package/dist/_internal/components/form/NumberField/NumberField.helpers.js +20 -0
  103. package/dist/_internal/components/form/NumberField/NumberField.js +28 -0
  104. package/dist/_internal/components/form/NumberField/NumberField.types.js +1 -0
  105. package/dist/_internal/components/form/NumberField/NumberField.types.js.map +1 -0
  106. package/dist/_internal/components/form/PhoneInput/PhoneInput.js +3 -3
  107. package/dist/_internal/components/form/RadioGroup/RadioGroup.js +5 -5
  108. package/dist/_internal/components/form/RadioGroup/RadioGroup.styles.js +3 -3
  109. package/dist/_internal/components/form/RadioGroup/RadioGroup.variants.js +4 -4
  110. package/dist/_internal/components/form/RichTextEditor/RichTextEditor.js +3 -3
  111. package/dist/_internal/components/form/Select/Select.js +3 -3
  112. package/dist/_internal/components/form/Switch/Switch.js +5 -5
  113. package/dist/_internal/components/form/Switch/Switch.parts.js +3 -3
  114. package/dist/_internal/components/form/Switch/Switch.styles.js +2 -2
  115. package/dist/_internal/components/form/Textarea/Textarea.js +3 -3
  116. package/dist/_internal/components/form/Textarea/TextareaRichEditor.js +4 -4
  117. package/dist/_internal/components/form/Toggle/Toggle.js +4 -4
  118. package/dist/_internal/components/form/Toggle/Toggle.styles.js +3 -3
  119. package/dist/_internal/components/form/ToggleGroup/ToggleGroup.js +3 -3
  120. package/dist/_internal/components/form/index.js +54 -48
  121. package/dist/_internal/components/form/total-form/Fields/CategoryField.js +11 -11
  122. package/dist/_internal/components/form/total-form/Fields/CepField.js +6 -6
  123. package/dist/_internal/components/form/total-form/Fields/SelectField.js +4 -4
  124. package/dist/_internal/components/form/total-form/Fields/TextField.js +5 -5
  125. package/dist/_internal/components/form/total-form/Fields/ToggleField.js +4 -4
  126. package/dist/_internal/components/form/total-form/Fields/index.js +24 -24
  127. package/dist/_internal/components/form/total-form/SubmitButton.js +5 -5
  128. package/dist/_internal/components/index.js +156 -117
  129. package/dist/_internal/components/layout/Box/Box.js +6 -6
  130. package/dist/_internal/components/layout/Card/Card.js +2 -2
  131. package/dist/_internal/components/layout/ContentToolbar/ColumnsMenu.js +3 -3
  132. package/dist/_internal/components/layout/ContentToolbar/FilterTrigger.js +3 -3
  133. package/dist/_internal/components/layout/ContentToolbar/MultiSelectDropdown.js +4 -4
  134. package/dist/_internal/components/layout/ContentToolbar/MultiSelectTriggers.js +3 -3
  135. package/dist/_internal/components/layout/ContentToolbar/SavedViewsMenu.js +3 -3
  136. package/dist/_internal/components/layout/ContentToolbar/SortByDropdown.js +3 -3
  137. package/dist/_internal/components/layout/ContentToolbar/ViewSelector.js +3 -3
  138. package/dist/_internal/components/layout/ScrollArea/ScrollArea.js +2 -2
  139. package/dist/_internal/components/layout/SettingCard/SettingCard.hooks.js +19 -0
  140. package/dist/_internal/components/layout/SettingCard/SettingCard.hooks.js.map +1 -0
  141. package/dist/_internal/components/layout/SettingCard/SettingCard.js +54 -0
  142. package/dist/_internal/components/layout/SettingCard/SettingCard.js.map +1 -0
  143. package/dist/_internal/components/layout/SettingCard/SettingCard.metrics.js +12 -0
  144. package/dist/_internal/components/layout/SettingCard/SettingCard.metrics.js.map +1 -0
  145. package/dist/_internal/components/layout/SettingCard/SettingCard.parts.js +59 -0
  146. package/dist/_internal/components/layout/SettingCard/SettingCard.parts.js.map +1 -0
  147. package/dist/_internal/components/layout/SettingCard/SettingCard.styles.js +37 -0
  148. package/dist/_internal/components/layout/SettingCard/SettingCard.styles.js.map +1 -0
  149. package/dist/_internal/components/layout/SettingCard/SettingCard.types.js +1 -0
  150. package/dist/_internal/components/layout/SettingCard/SettingCard.types.js.map +1 -0
  151. package/dist/_internal/components/layout/SettingCard/SettingGrid.js +56 -0
  152. package/dist/_internal/components/layout/SettingCard/SettingGrid.js.map +1 -0
  153. package/dist/_internal/components/layout/SettingCard/SettingGroup.context.js +10 -0
  154. package/dist/_internal/components/layout/SettingCard/SettingGroup.context.js.map +1 -0
  155. package/dist/_internal/components/layout/SettingCard/SettingGroup.js +65 -0
  156. package/dist/_internal/components/layout/SettingCard/SettingGroup.js.map +1 -0
  157. package/dist/_internal/components/layout/SettingCard/SettingSwitch.js +63 -0
  158. package/dist/_internal/components/layout/SettingCard/SettingSwitch.js.map +1 -0
  159. package/dist/_internal/components/layout/SettingCard/SettingToggle.js +65 -0
  160. package/dist/_internal/components/layout/SettingCard/SettingToggle.js.map +1 -0
  161. package/dist/_internal/components/layout/SettingsLayout/SettingsLayout.js +4 -4
  162. package/dist/_internal/components/layout/SettingsLayout/SettingsPanel.js +3 -3
  163. package/dist/_internal/components/layout/SettingsLayout/SettingsSectionChips.js +2 -2
  164. package/dist/_internal/components/layout/Stack/Stack.js +7 -7
  165. package/dist/_internal/components/layout/TableFilter/TableFilter.js +3 -3
  166. package/dist/_internal/components/layout/index.js +88 -26
  167. package/dist/_internal/components/navigation/AppHeader/AppHeader.details.js +8 -8
  168. package/dist/_internal/components/navigation/AppHeader/AppHeader.identity.js +3 -3
  169. package/dist/_internal/components/navigation/NavigationMenu/NavigationMegaSection.js +2 -2
  170. package/dist/_internal/components/navigation/NavigationMenu/NavigationMenu.js +4 -4
  171. package/dist/_internal/components/navigation/NavigationMenu/NavigationStandardBody.js +2 -2
  172. package/dist/_internal/components/navigation/Pagination/Pagination.js +4 -4
  173. package/dist/_internal/components/navigation/Pagination/PaginationParts.js +3 -3
  174. package/dist/_internal/components/navigation/Tabs/Tabs.js +4 -4
  175. package/dist/_internal/components/navigation/Tabs/Tabs.styles.js +2 -2
  176. package/dist/_internal/components/navigation/index.js +27 -27
  177. package/dist/_internal/components/typography/index.js +4 -4
  178. package/dist/_internal/components/utility/InstallPrompt/InstallPrompt.js +2 -2
  179. package/dist/_internal/components/utility/WorkflowStep/WorkflowStep.helpers.js +3 -3
  180. package/dist/_internal/components/utility/WorkflowStep/WorkflowStep.js +3 -3
  181. package/dist/_internal/components/utility/WorkflowStep/WorkflowStep.parts.js +3 -3
  182. package/dist/_internal/components/utility/WorkflowStep/WorkflowStepRow.js +3 -3
  183. package/dist/_internal/components/utility/index.js +16 -16
  184. package/dist/_internal/en-US.data-display.js +2 -2
  185. package/dist/_internal/en-US.layout.js +5 -1
  186. package/dist/_internal/icons/Icon.js +6 -6
  187. package/dist/_internal/provider/UiProvider.js +5 -5
  188. package/dist/_internal/provider/mui-bridge.js +4 -4
  189. package/dist/_internal/provider/use-ui-theme.js +5 -5
  190. package/dist/_internal/pt-BR.data-display.js +2 -2
  191. package/dist/_internal/pt-BR.layout.js +5 -1
  192. package/dist/_internal/social-login-button/social-login-button.js +7 -7
  193. package/dist/_internal/tokens/density.js +3 -3
  194. package/dist/_internal/tokens/field-height.js +2 -2
  195. package/dist/_internal/user-avatar/user-avatar.js +7 -7
  196. package/dist/charts.js +3 -3
  197. package/dist/chunk-2GTORM5E.js +1 -0
  198. package/dist/chunk-2GTORM5E.js.map +1 -0
  199. package/dist/{chunk-3PGFMBEI.js → chunk-2LKWJV65.js} +5 -5
  200. package/dist/{chunk-IIUB4IOH.js → chunk-2XHIF3M3.js} +4 -4
  201. package/dist/chunk-33L26P4J.js +27 -0
  202. package/dist/chunk-33L26P4J.js.map +1 -0
  203. package/dist/{chunk-CKPFLEOL.js → chunk-3CUWQXTG.js} +3 -3
  204. package/dist/{chunk-GVFPOKJW.js → chunk-3CYTVX4T.js} +5 -5
  205. package/dist/chunk-3DO5AJCG.js +117 -0
  206. package/dist/chunk-3DO5AJCG.js.map +1 -0
  207. package/dist/{chunk-TJPQIFI4.js → chunk-3EPA2A4M.js} +8 -8
  208. package/dist/{chunk-HDELNMZC.js → chunk-3MJHHPRW.js} +2 -2
  209. package/dist/chunk-3U7WKBMH.js +27 -0
  210. package/dist/chunk-3U7WKBMH.js.map +1 -0
  211. package/dist/{chunk-RNC574FS.js → chunk-3UEZ6NUI.js} +2 -2
  212. package/dist/{chunk-OXLOC6TC.js → chunk-3XS37SQT.js} +3 -3
  213. package/dist/{chunk-2Q5QHSU2.js → chunk-44USLRMT.js} +8 -8
  214. package/dist/{chunk-O7OQZJ3D.js → chunk-4GN2RLYL.js} +2 -2
  215. package/dist/{chunk-QUFKPCWD.js → chunk-4S2LWZ7L.js} +2 -2
  216. package/dist/{chunk-LPWIAVGP.js → chunk-4UVFPORR.js} +5 -5
  217. package/dist/{chunk-3B4YMZD5.js → chunk-4Z7GEO2R.js} +2 -2
  218. package/dist/{chunk-XXPEFK4V.js → chunk-53O2TNSR.js} +5 -5
  219. package/dist/{chunk-G3SKAI6S.js → chunk-54HTXJJ2.js} +2 -2
  220. package/dist/{chunk-JE6RZ5L6.js → chunk-5ZOJLYD2.js} +4 -4
  221. package/dist/{chunk-JDUIWHJ3.js → chunk-6H4TPEMO.js} +2 -2
  222. package/dist/{chunk-FYZJEME4.js → chunk-6JGATEOF.js} +3 -3
  223. package/dist/{chunk-ZFUOLLZS.js → chunk-6L2FKTBO.js} +5 -5
  224. package/dist/{chunk-BDBI4W77.js → chunk-6MD5QXXJ.js} +3 -3
  225. package/dist/{chunk-ODW2D5PN.js → chunk-6QYKZMEE.js} +5 -2
  226. package/dist/{chunk-ODW2D5PN.js.map → chunk-6QYKZMEE.js.map} +1 -1
  227. package/dist/{chunk-LJSKF43D.js → chunk-6TPYT3UC.js} +5 -5
  228. package/dist/{chunk-KZT5JC3E.js → chunk-6ZD3FI5P.js} +2 -2
  229. package/dist/{chunk-SBV62CSC.js → chunk-72FPUWD6.js} +2 -2
  230. package/dist/{chunk-L75CZ3SI.js → chunk-72S2RGWD.js} +2 -2
  231. package/dist/{chunk-WUFTDJ2L.js → chunk-77BKKPCI.js} +2 -2
  232. package/dist/{chunk-5A4XPYNK.js → chunk-7FEXRMJE.js} +2 -2
  233. package/dist/{chunk-AW336SO7.js → chunk-7KKMZJFT.js} +2 -2
  234. package/dist/{chunk-4SSWJRC4.js → chunk-7TE4TMS3.js} +3 -3
  235. package/dist/chunk-AEMD6JHZ.js +1 -0
  236. package/dist/chunk-AEMD6JHZ.js.map +1 -0
  237. package/dist/{chunk-5XWCKCHP.js → chunk-ALOUJ3CE.js} +4 -4
  238. package/dist/{chunk-UFUMYNKS.js → chunk-AWG2AJHX.js} +5 -5
  239. package/dist/{chunk-DDVNYVJH.js → chunk-B3QWQG62.js} +2 -2
  240. package/dist/{chunk-CKI33CN2.js → chunk-BA6Z52QN.js} +2 -2
  241. package/dist/{chunk-53TDQYA3.js → chunk-BKZERHNC.js} +4 -4
  242. package/dist/{chunk-RSWHKOUN.js → chunk-BM4KKGL7.js} +2 -2
  243. package/dist/chunk-BOWS4U6W.js +1 -0
  244. package/dist/chunk-BOWS4U6W.js.map +1 -0
  245. package/dist/{chunk-M4P7NS2L.js → chunk-BR2T72JI.js} +23 -15
  246. package/dist/chunk-BR2T72JI.js.map +1 -0
  247. package/dist/{chunk-OZGJ3YCN.js → chunk-BVSSEOLI.js} +2 -2
  248. package/dist/{chunk-FI6BL4UU.js → chunk-C2TERIB4.js} +2 -2
  249. package/dist/{chunk-DUITNU72.js → chunk-C6OVO6AT.js} +2 -2
  250. package/dist/{chunk-WL2S2YB3.js → chunk-CKHFYTIX.js} +4 -4
  251. package/dist/{chunk-GBEHJBYM.js → chunk-CLK67TNH.js} +2 -2
  252. package/dist/{chunk-T2HZ3GVA.js → chunk-CM2Q7IH3.js} +4 -4
  253. package/dist/{chunk-GE26GVHM.js → chunk-CMFJQH6A.js} +2 -2
  254. package/dist/{chunk-6PPHALM3.js → chunk-CMLIWUBW.js} +4 -4
  255. package/dist/{chunk-AU3GV6UL.js → chunk-DH5UJD2I.js} +3 -3
  256. package/dist/{chunk-BKT2KJ56.js → chunk-DH6SL3SY.js} +2 -2
  257. package/dist/{chunk-APPIPQFT.js → chunk-DH77PLFF.js} +8 -8
  258. package/dist/{chunk-TRTX4BDI.js → chunk-DJKVSUXH.js} +2 -2
  259. package/dist/{chunk-VE3P77TV.js → chunk-DLWLIPCP.js} +2 -2
  260. package/dist/{chunk-MWPXKZ7O.js → chunk-ERY6D2OV.js} +4 -4
  261. package/dist/{chunk-TJ7NQG7E.js → chunk-FBUCXTA4.js} +4 -4
  262. package/dist/{chunk-SE6TW72O.js → chunk-FDMQ7H22.js} +2 -2
  263. package/dist/{chunk-E2FMNY6B.js → chunk-FXWXBEOZ.js} +2 -2
  264. package/dist/{chunk-UI5O6J6R.js → chunk-FY6PONLA.js} +4 -4
  265. package/dist/{chunk-QUIHOPOC.js → chunk-G4TKMUOL.js} +2 -2
  266. package/dist/{chunk-6BS2RBW4.js → chunk-G7XHJPLO.js} +3 -3
  267. package/dist/{chunk-4RXPIHJG.js → chunk-GE2CCITY.js} +2 -2
  268. package/dist/{chunk-WRHBXOGN.js → chunk-GG62LKA3.js} +5 -5
  269. package/dist/{chunk-YQCRQHVU.js → chunk-GI63FQEJ.js} +4 -4
  270. package/dist/{chunk-WUQKXAYF.js → chunk-GPHURU2K.js} +5 -5
  271. package/dist/{chunk-GPT673YL.js → chunk-H72YKEGD.js} +2 -2
  272. package/dist/chunk-HALFOXSZ.js +1 -0
  273. package/dist/chunk-HALFOXSZ.js.map +1 -0
  274. package/dist/{chunk-AJVFSUC4.js → chunk-HFVYWHJT.js} +10 -10
  275. package/dist/{chunk-UP6RO2PR.js → chunk-HKBJZX3C.js} +3 -3
  276. package/dist/chunk-IC7GHPMK.js +22 -0
  277. package/dist/chunk-IC7GHPMK.js.map +1 -0
  278. package/dist/{chunk-V3RQFWL6.js → chunk-IUD6N52Q.js} +3 -3
  279. package/dist/{chunk-N4D5V3AA.js → chunk-JAGAFEZL.js} +2 -2
  280. package/dist/{chunk-CLTK76ZF.js → chunk-JE5GEWTG.js} +5 -5
  281. package/dist/{chunk-23XBBGWD.js → chunk-JFLFZLOA.js} +5 -5
  282. package/dist/{chunk-BLUURKCY.js → chunk-K6LNHHSH.js} +2 -2
  283. package/dist/{chunk-HSNOWYEE.js → chunk-K7FSTB2K.js} +2 -2
  284. package/dist/{chunk-SXVCXLKU.js → chunk-K7MQP2KT.js} +3 -3
  285. package/dist/{chunk-QQ46JX5H.js → chunk-KHOAXZW2.js} +4 -4
  286. package/dist/{chunk-SCVBGQFO.js → chunk-KQZGUHYZ.js} +2 -2
  287. package/dist/{chunk-GJ7GIGDS.js → chunk-LCWGNDTH.js} +2 -2
  288. package/dist/{chunk-4D2IVVHR.js → chunk-LF3EVXMF.js} +2 -2
  289. package/dist/{chunk-2XTBGZSR.js → chunk-LGCRL7DK.js} +2 -2
  290. package/dist/{chunk-WY35GCHY.js → chunk-LODMNSLR.js} +3 -3
  291. package/dist/{chunk-EXFX3JRN.js → chunk-M47ZOUGF.js} +4 -4
  292. package/dist/{chunk-AQCQ2USS.js → chunk-M65ZNPLO.js} +2 -2
  293. package/dist/{chunk-COUFRGD6.js → chunk-MEBQKYH4.js} +4 -4
  294. package/dist/{chunk-JZ5IGO5G.js → chunk-NCB4GBRL.js} +2 -2
  295. package/dist/{chunk-SE4WZIKD.js → chunk-NFGIA2ZV.js} +2 -2
  296. package/dist/{chunk-D455V3BW.js → chunk-NOLSQK4J.js} +28 -30
  297. package/dist/chunk-NOLSQK4J.js.map +1 -0
  298. package/dist/{chunk-WTXPGASQ.js → chunk-NPPJ3IJP.js} +4 -4
  299. package/dist/chunk-NPPJ3IJP.js.map +1 -0
  300. package/dist/{chunk-H772ZSAI.js → chunk-NQ7NMCRI.js} +2 -2
  301. package/dist/{chunk-P7JF6XT7.js → chunk-NRSVI23L.js} +2 -2
  302. package/dist/{chunk-FRTEU7ZO.js → chunk-NU55QUMO.js} +2 -2
  303. package/dist/chunk-OJUORFGO.js +87 -0
  304. package/dist/chunk-OJUORFGO.js.map +1 -0
  305. package/dist/{chunk-JB56E4XQ.js → chunk-PAICZOL5.js} +6 -6
  306. package/dist/chunk-PEOOCQ2T.js +140 -0
  307. package/dist/chunk-PEOOCQ2T.js.map +1 -0
  308. package/dist/chunk-PGGGKYWG.js +1 -0
  309. package/dist/chunk-PGGGKYWG.js.map +1 -0
  310. package/dist/{chunk-QX3CXOJ3.js → chunk-PTONBPZL.js} +2 -2
  311. package/dist/chunk-Q4JWWTL4.js +36 -0
  312. package/dist/chunk-Q4JWWTL4.js.map +1 -0
  313. package/dist/{chunk-4UASV6VL.js → chunk-QDELBNL3.js} +2 -2
  314. package/dist/{chunk-ZE56GK5C.js → chunk-QEI5DC6S.js} +5 -5
  315. package/dist/chunk-QGUNUXTT.js +1 -0
  316. package/dist/chunk-QGUNUXTT.js.map +1 -0
  317. package/dist/{chunk-3UXBIUJF.js → chunk-RDFPM2AQ.js} +5 -5
  318. package/dist/chunk-RDZGXJOD.js +74 -0
  319. package/dist/chunk-RDZGXJOD.js.map +1 -0
  320. package/dist/chunk-RN7UJI7S.js +1 -0
  321. package/dist/chunk-RN7UJI7S.js.map +1 -0
  322. package/dist/chunk-RPBGUWNF.js +168 -0
  323. package/dist/chunk-RPBGUWNF.js.map +1 -0
  324. package/dist/{chunk-BKHO4RSF.js → chunk-RZ2VZ7SL.js} +2 -2
  325. package/dist/{chunk-MT7QJRP7.js → chunk-S4IXC2V3.js} +3 -3
  326. package/dist/chunk-SALQ65SM.js +118 -0
  327. package/dist/chunk-SALQ65SM.js.map +1 -0
  328. package/dist/{chunk-XOZYUJQ5.js → chunk-SDKOOVEX.js} +5 -3
  329. package/dist/{chunk-XOZYUJQ5.js.map → chunk-SDKOOVEX.js.map} +1 -1
  330. package/dist/{chunk-5K4G2XYS.js → chunk-SNBAMWI5.js} +2 -2
  331. package/dist/{chunk-MKJHDHLF.js → chunk-TCNTIGMY.js} +2 -2
  332. package/dist/{chunk-EKM7C4X2.js → chunk-TJ3334AJ.js} +3 -3
  333. package/dist/{chunk-RUZVK4FV.js → chunk-TPVSHO75.js} +3 -3
  334. package/dist/{chunk-I72PREY7.js → chunk-TTJTMDLI.js} +2 -2
  335. package/dist/{chunk-TU5EIKJA.js → chunk-U5SH3VRJ.js} +4 -4
  336. package/dist/chunk-U67ZQ6VM.js +82 -0
  337. package/dist/chunk-U67ZQ6VM.js.map +1 -0
  338. package/dist/{chunk-DOLDAAXH.js → chunk-UT73NGRS.js} +3 -3
  339. package/dist/chunk-VYM2GPR6.js +47 -0
  340. package/dist/chunk-VYM2GPR6.js.map +1 -0
  341. package/dist/{chunk-BXEMC4YH.js → chunk-VYV3JOV5.js} +2 -2
  342. package/dist/{chunk-OTWMG7B2.js → chunk-WN5PNP6F.js} +4 -4
  343. package/dist/chunk-X3C3VTYS.js +85 -0
  344. package/dist/chunk-X3C3VTYS.js.map +1 -0
  345. package/dist/{chunk-HZBRXLV7.js → chunk-XB7HYOMM.js} +2 -2
  346. package/dist/{chunk-C6FVXX7Y.js → chunk-XBLFK2FL.js} +2 -2
  347. package/dist/{chunk-EDBVMLNX.js → chunk-XHA2NXLD.js} +2 -2
  348. package/dist/chunk-XJQNSMGA.js +10 -0
  349. package/dist/chunk-XJQNSMGA.js.map +1 -0
  350. package/dist/{chunk-ZO4NO77T.js → chunk-XO4ZUHVH.js} +2 -2
  351. package/dist/{chunk-OPT7X3Y6.js → chunk-XXL4PM4M.js} +2 -2
  352. package/dist/{chunk-3HKUOLPD.js → chunk-XZY7O7JJ.js} +4 -4
  353. package/dist/{chunk-743SY4WQ.js → chunk-YLXQWYOG.js} +5 -5
  354. package/dist/{chunk-Q33JWFSA.js → chunk-YPIVLPXF.js} +2 -2
  355. package/dist/{chunk-T7UUP7VD.js → chunk-YRUX7XMQ.js} +2 -2
  356. package/dist/{chunk-4JEXYOSN.js → chunk-YTXZUTLF.js} +2 -2
  357. package/dist/{chunk-V7A5ZAAF.js → chunk-YWJDUJAR.js} +3 -3
  358. package/dist/{chunk-ZK7YERPQ.js → chunk-Z2NN53E5.js} +2 -2
  359. package/dist/{chunk-CLSC36JS.js → chunk-Z4DKVLYG.js} +3 -3
  360. package/dist/{chunk-NFJ3VVD3.js → chunk-Z6T5SXST.js} +5 -5
  361. package/dist/{chunk-IITZA6U2.js → chunk-ZBVU2YWV.js} +9 -9
  362. package/dist/{chunk-IEWAFD6L.js → chunk-ZC5HDBQO.js} +2 -2
  363. package/dist/{chunk-KQS4ZJGS.js → chunk-ZGCPDA3F.js} +5 -5
  364. package/dist/{chunk-AHDNANID.js → chunk-ZH2SZ6B3.js} +2 -2
  365. package/dist/{chunk-KOX2AEFW.js → chunk-ZKWVCSAB.js} +2 -2
  366. package/dist/{chunk-K2U4BNHQ.js → chunk-ZNBLGS66.js} +2 -2
  367. package/dist/{chunk-WGUY7EIB.js → chunk-ZUME25DS.js} +5 -5
  368. package/dist/data-display/Badge.js +3 -3
  369. package/dist/data-display/CardKit.js +6 -6
  370. package/dist/data-display/Carousel.js +3 -3
  371. package/dist/data-display/Chart.js +3 -3
  372. package/dist/data-display/Chip.js +1 -0
  373. package/dist/data-display/DataViews.js +68 -68
  374. package/dist/data-display/FleetMap.js +9 -9
  375. package/dist/data-display/MapPreview.js +5 -5
  376. package/dist/data-display/Sheet.js +3 -3
  377. package/dist/en-US.js +15 -11
  378. package/dist/feedback/ConfirmAction.js +5 -5
  379. package/dist/feedback/Dialog.js +2 -2
  380. package/dist/feedback/NotificationStatusNotice.js +5 -5
  381. package/dist/form/AddressAutocomplete.js +7 -7
  382. package/dist/form/Autocomplete.js +5 -5
  383. package/dist/form/Button.js +4 -4
  384. package/dist/form/CategorySelect.js +10 -10
  385. package/dist/form/CepField.js +5 -5
  386. package/dist/form/CodeEditor.js +2 -2
  387. package/dist/form/Command.js +3 -3
  388. package/dist/form/CreatableSelect.js +3 -3
  389. package/dist/form/DateRangePicker.js +7 -7
  390. package/dist/form/Input.js +4 -4
  391. package/dist/form/InputOTP.js +4 -4
  392. package/dist/form/Label.js +3 -3
  393. package/dist/form/Menubar.js +3 -3
  394. package/dist/form/NumberField.js +29 -0
  395. package/dist/form/NumberField.js.map +1 -0
  396. package/dist/form/PhoneInput.js +3 -3
  397. package/dist/form/RadioGroup.js +5 -5
  398. package/dist/form/RichTextEditor.js +3 -3
  399. package/dist/form/Select.js +3 -3
  400. package/dist/form/Switch.js +5 -5
  401. package/dist/form/Textarea.js +3 -3
  402. package/dist/form/Toggle.js +4 -4
  403. package/dist/form/ToggleGroup.js +3 -3
  404. package/dist/form/total-form.js +30 -30
  405. package/dist/icons.js +7 -6
  406. package/dist/layout/Box.js +6 -6
  407. package/dist/layout/Card.js +2 -2
  408. package/dist/layout/Collapsible.js +1 -0
  409. package/dist/layout/ContentToolbar.js +13 -13
  410. package/dist/layout/ScrollArea.js +2 -2
  411. package/dist/layout/SettingCard.js +80 -0
  412. package/dist/layout/SettingCard.js.map +1 -0
  413. package/dist/layout/SettingsLayout.js +4 -4
  414. package/dist/layout/Stack.js +7 -7
  415. package/dist/layout/TableFilter.js +3 -3
  416. package/dist/locales.js +37 -23
  417. package/dist/locales.js.map +1 -1
  418. package/dist/navigation/AppHeader.js +12 -12
  419. package/dist/navigation/NavigationMenu.js +4 -4
  420. package/dist/navigation/Pagination.js +4 -4
  421. package/dist/navigation/Tabs.js +4 -4
  422. package/dist/provider.js +6 -6
  423. package/dist/pt-BR.js +12 -8
  424. package/dist/social-login-button.js +7 -7
  425. package/dist/tokens.js +4 -4
  426. package/dist/types/components/data-display/DataViews/data-views-category-pill.d.ts +6 -1
  427. package/dist/types/components/data-display/DataViews/data-views-category-pill.d.ts.map +1 -1
  428. package/dist/types/components/data-display/DataViews/data-views-more-fields.d.ts +0 -11
  429. package/dist/types/components/data-display/DataViews/data-views-more-fields.d.ts.map +1 -1
  430. package/dist/types/components/data-display/DataViews/data-views-overflow.d.ts.map +1 -1
  431. package/dist/types/components/form/Autocomplete/useAutocomplete.d.ts +9 -0
  432. package/dist/types/components/form/Autocomplete/useAutocomplete.d.ts.map +1 -1
  433. package/dist/types/components/form/Input/Input.d.ts.map +1 -1
  434. package/dist/types/components/form/Input/Input.types.d.ts +10 -0
  435. package/dist/types/components/form/Input/Input.types.d.ts.map +1 -1
  436. package/dist/types/components/form/NumberField/NumberField.d.ts +21 -0
  437. package/dist/types/components/form/NumberField/NumberField.d.ts.map +1 -0
  438. package/dist/types/components/form/NumberField/NumberField.helpers.d.ts +48 -0
  439. package/dist/types/components/form/NumberField/NumberField.helpers.d.ts.map +1 -0
  440. package/dist/types/components/form/NumberField/NumberField.types.d.ts +31 -0
  441. package/dist/types/components/form/NumberField/NumberField.types.d.ts.map +1 -0
  442. package/dist/types/components/form/NumberField/index.d.ts +3 -0
  443. package/dist/types/components/form/NumberField/index.d.ts.map +1 -0
  444. package/dist/types/components/form/index.d.ts +1 -0
  445. package/dist/types/components/form/index.d.ts.map +1 -1
  446. package/dist/types/components/layout/SettingCard/SettingCard.d.ts +14 -0
  447. package/dist/types/components/layout/SettingCard/SettingCard.d.ts.map +1 -0
  448. package/dist/types/components/layout/SettingCard/SettingCard.hooks.d.ts +79 -0
  449. package/dist/types/components/layout/SettingCard/SettingCard.hooks.d.ts.map +1 -0
  450. package/dist/types/components/layout/SettingCard/SettingCard.metrics.d.ts +21 -0
  451. package/dist/types/components/layout/SettingCard/SettingCard.metrics.d.ts.map +1 -0
  452. package/dist/types/components/layout/SettingCard/SettingCard.parts.d.ts +49 -0
  453. package/dist/types/components/layout/SettingCard/SettingCard.parts.d.ts.map +1 -0
  454. package/dist/types/components/layout/SettingCard/SettingCard.styles.d.ts +48 -0
  455. package/dist/types/components/layout/SettingCard/SettingCard.styles.d.ts.map +1 -0
  456. package/dist/types/components/layout/SettingCard/SettingCard.types.d.ts +127 -0
  457. package/dist/types/components/layout/SettingCard/SettingCard.types.d.ts.map +1 -0
  458. package/dist/types/components/layout/SettingCard/SettingGrid.d.ts +33 -0
  459. package/dist/types/components/layout/SettingCard/SettingGrid.d.ts.map +1 -0
  460. package/dist/types/components/layout/SettingCard/SettingGroup.context.d.ts +13 -0
  461. package/dist/types/components/layout/SettingCard/SettingGroup.context.d.ts.map +1 -0
  462. package/dist/types/components/layout/SettingCard/SettingGroup.d.ts +18 -0
  463. package/dist/types/components/layout/SettingCard/SettingGroup.d.ts.map +1 -0
  464. package/dist/types/components/layout/SettingCard/SettingSwitch.d.ts +28 -0
  465. package/dist/types/components/layout/SettingCard/SettingSwitch.d.ts.map +1 -0
  466. package/dist/types/components/layout/SettingCard/SettingToggle.d.ts +13 -0
  467. package/dist/types/components/layout/SettingCard/SettingToggle.d.ts.map +1 -0
  468. package/dist/types/components/layout/SettingCard/index.d.ts +6 -0
  469. package/dist/types/components/layout/SettingCard/index.d.ts.map +1 -0
  470. package/dist/types/components/layout/index.d.ts +1 -0
  471. package/dist/types/components/layout/index.d.ts.map +1 -1
  472. package/dist/types/copy/layout.d.ts +27 -0
  473. package/dist/types/copy/layout.d.ts.map +1 -1
  474. package/dist/types/en-US.layout.d.ts +3 -1
  475. package/dist/types/en-US.layout.d.ts.map +1 -1
  476. package/dist/types/locales.d.ts +3 -1
  477. package/dist/types/locales.d.ts.map +1 -1
  478. package/dist/types/pt-BR.layout.d.ts +3 -1
  479. package/dist/types/pt-BR.layout.d.ts.map +1 -1
  480. package/dist/user-avatar.js +7 -7
  481. package/dist/utility/InstallPrompt.js +2 -2
  482. package/dist/utility/WorkflowStep.js +3 -3
  483. package/package.json +9 -1
  484. package/src/components/data-display/DataViews/data-views-category-pill.tsx +6 -1
  485. package/src/components/data-display/DataViews/data-views-more-fields.tsx +43 -37
  486. package/src/components/data-display/DataViews/data-views-overflow.ts +12 -1
  487. package/src/components/form/Autocomplete/useAutocomplete.ts +46 -16
  488. package/src/components/form/Input/Input.tsx +2 -0
  489. package/src/components/form/Input/Input.types.ts +10 -0
  490. package/src/components/form/NumberField/NumberField.helpers.ts +77 -0
  491. package/src/components/form/NumberField/NumberField.md +86 -0
  492. package/src/components/form/NumberField/NumberField.tsx +88 -0
  493. package/src/components/form/NumberField/NumberField.types.ts +43 -0
  494. package/src/components/form/NumberField/index.ts +2 -0
  495. package/src/components/form/NumberField/tests.md +51 -0
  496. package/src/components/form/NumberField/track.md +42 -0
  497. package/src/components/form/index.ts +1 -0
  498. package/src/components/layout/SettingCard/SettingCard.hooks.ts +191 -0
  499. package/src/components/layout/SettingCard/SettingCard.md +121 -0
  500. package/src/components/layout/SettingCard/SettingCard.metrics.ts +22 -0
  501. package/src/components/layout/SettingCard/SettingCard.parts.tsx +162 -0
  502. package/src/components/layout/SettingCard/SettingCard.styles.ts +142 -0
  503. package/src/components/layout/SettingCard/SettingCard.tsx +197 -0
  504. package/src/components/layout/SettingCard/SettingCard.types.ts +140 -0
  505. package/src/components/layout/SettingCard/SettingGrid.md +65 -0
  506. package/src/components/layout/SettingCard/SettingGrid.tsx +105 -0
  507. package/src/components/layout/SettingCard/SettingGroup.context.ts +11 -0
  508. package/src/components/layout/SettingCard/SettingGroup.md +81 -0
  509. package/src/components/layout/SettingCard/SettingGroup.tsx +73 -0
  510. package/src/components/layout/SettingCard/SettingSwitch.tsx +92 -0
  511. package/src/components/layout/SettingCard/SettingToggle.md +61 -0
  512. package/src/components/layout/SettingCard/SettingToggle.tsx +43 -0
  513. package/src/components/layout/SettingCard/index.ts +18 -0
  514. package/src/components/layout/SettingCard/tests.md +68 -0
  515. package/src/components/layout/SettingCard/track.md +54 -0
  516. package/src/components/layout/index.ts +1 -0
  517. package/src/copy/layout.ts +29 -0
  518. package/src/en-US.layout.ts +16 -0
  519. package/src/locales.ts +10 -0
  520. package/src/pt-BR.layout.ts +16 -0
  521. package/dist/chunk-A7RIZOAL.js +0 -13
  522. package/dist/chunk-A7RIZOAL.js.map +0 -1
  523. package/dist/chunk-BY3JEK5T.js +0 -1
  524. package/dist/chunk-D455V3BW.js.map +0 -1
  525. package/dist/chunk-FZJ2FTGE.js +0 -1
  526. package/dist/chunk-GRHECKHU.js +0 -13
  527. package/dist/chunk-GRHECKHU.js.map +0 -1
  528. package/dist/chunk-M4P7NS2L.js.map +0 -1
  529. package/dist/chunk-WTXPGASQ.js.map +0 -1
  530. /package/dist/{chunk-BY3JEK5T.js.map → _internal/components/form/NumberField/NumberField.helpers.js.map} +0 -0
  531. /package/dist/{chunk-FZJ2FTGE.js.map → _internal/components/form/NumberField/NumberField.js.map} +0 -0
  532. /package/dist/{chunk-3PGFMBEI.js.map → chunk-2LKWJV65.js.map} +0 -0
  533. /package/dist/{chunk-IIUB4IOH.js.map → chunk-2XHIF3M3.js.map} +0 -0
  534. /package/dist/{chunk-CKPFLEOL.js.map → chunk-3CUWQXTG.js.map} +0 -0
  535. /package/dist/{chunk-GVFPOKJW.js.map → chunk-3CYTVX4T.js.map} +0 -0
  536. /package/dist/{chunk-TJPQIFI4.js.map → chunk-3EPA2A4M.js.map} +0 -0
  537. /package/dist/{chunk-HDELNMZC.js.map → chunk-3MJHHPRW.js.map} +0 -0
  538. /package/dist/{chunk-RNC574FS.js.map → chunk-3UEZ6NUI.js.map} +0 -0
  539. /package/dist/{chunk-OXLOC6TC.js.map → chunk-3XS37SQT.js.map} +0 -0
  540. /package/dist/{chunk-2Q5QHSU2.js.map → chunk-44USLRMT.js.map} +0 -0
  541. /package/dist/{chunk-O7OQZJ3D.js.map → chunk-4GN2RLYL.js.map} +0 -0
  542. /package/dist/{chunk-QUFKPCWD.js.map → chunk-4S2LWZ7L.js.map} +0 -0
  543. /package/dist/{chunk-LPWIAVGP.js.map → chunk-4UVFPORR.js.map} +0 -0
  544. /package/dist/{chunk-3B4YMZD5.js.map → chunk-4Z7GEO2R.js.map} +0 -0
  545. /package/dist/{chunk-XXPEFK4V.js.map → chunk-53O2TNSR.js.map} +0 -0
  546. /package/dist/{chunk-G3SKAI6S.js.map → chunk-54HTXJJ2.js.map} +0 -0
  547. /package/dist/{chunk-JE6RZ5L6.js.map → chunk-5ZOJLYD2.js.map} +0 -0
  548. /package/dist/{chunk-JDUIWHJ3.js.map → chunk-6H4TPEMO.js.map} +0 -0
  549. /package/dist/{chunk-FYZJEME4.js.map → chunk-6JGATEOF.js.map} +0 -0
  550. /package/dist/{chunk-ZFUOLLZS.js.map → chunk-6L2FKTBO.js.map} +0 -0
  551. /package/dist/{chunk-BDBI4W77.js.map → chunk-6MD5QXXJ.js.map} +0 -0
  552. /package/dist/{chunk-LJSKF43D.js.map → chunk-6TPYT3UC.js.map} +0 -0
  553. /package/dist/{chunk-KZT5JC3E.js.map → chunk-6ZD3FI5P.js.map} +0 -0
  554. /package/dist/{chunk-SBV62CSC.js.map → chunk-72FPUWD6.js.map} +0 -0
  555. /package/dist/{chunk-L75CZ3SI.js.map → chunk-72S2RGWD.js.map} +0 -0
  556. /package/dist/{chunk-WUFTDJ2L.js.map → chunk-77BKKPCI.js.map} +0 -0
  557. /package/dist/{chunk-5A4XPYNK.js.map → chunk-7FEXRMJE.js.map} +0 -0
  558. /package/dist/{chunk-AW336SO7.js.map → chunk-7KKMZJFT.js.map} +0 -0
  559. /package/dist/{chunk-4SSWJRC4.js.map → chunk-7TE4TMS3.js.map} +0 -0
  560. /package/dist/{chunk-5XWCKCHP.js.map → chunk-ALOUJ3CE.js.map} +0 -0
  561. /package/dist/{chunk-UFUMYNKS.js.map → chunk-AWG2AJHX.js.map} +0 -0
  562. /package/dist/{chunk-DDVNYVJH.js.map → chunk-B3QWQG62.js.map} +0 -0
  563. /package/dist/{chunk-CKI33CN2.js.map → chunk-BA6Z52QN.js.map} +0 -0
  564. /package/dist/{chunk-53TDQYA3.js.map → chunk-BKZERHNC.js.map} +0 -0
  565. /package/dist/{chunk-RSWHKOUN.js.map → chunk-BM4KKGL7.js.map} +0 -0
  566. /package/dist/{chunk-OZGJ3YCN.js.map → chunk-BVSSEOLI.js.map} +0 -0
  567. /package/dist/{chunk-FI6BL4UU.js.map → chunk-C2TERIB4.js.map} +0 -0
  568. /package/dist/{chunk-DUITNU72.js.map → chunk-C6OVO6AT.js.map} +0 -0
  569. /package/dist/{chunk-WL2S2YB3.js.map → chunk-CKHFYTIX.js.map} +0 -0
  570. /package/dist/{chunk-GBEHJBYM.js.map → chunk-CLK67TNH.js.map} +0 -0
  571. /package/dist/{chunk-T2HZ3GVA.js.map → chunk-CM2Q7IH3.js.map} +0 -0
  572. /package/dist/{chunk-GE26GVHM.js.map → chunk-CMFJQH6A.js.map} +0 -0
  573. /package/dist/{chunk-6PPHALM3.js.map → chunk-CMLIWUBW.js.map} +0 -0
  574. /package/dist/{chunk-AU3GV6UL.js.map → chunk-DH5UJD2I.js.map} +0 -0
  575. /package/dist/{chunk-BKT2KJ56.js.map → chunk-DH6SL3SY.js.map} +0 -0
  576. /package/dist/{chunk-APPIPQFT.js.map → chunk-DH77PLFF.js.map} +0 -0
  577. /package/dist/{chunk-TRTX4BDI.js.map → chunk-DJKVSUXH.js.map} +0 -0
  578. /package/dist/{chunk-VE3P77TV.js.map → chunk-DLWLIPCP.js.map} +0 -0
  579. /package/dist/{chunk-MWPXKZ7O.js.map → chunk-ERY6D2OV.js.map} +0 -0
  580. /package/dist/{chunk-TJ7NQG7E.js.map → chunk-FBUCXTA4.js.map} +0 -0
  581. /package/dist/{chunk-SE6TW72O.js.map → chunk-FDMQ7H22.js.map} +0 -0
  582. /package/dist/{chunk-E2FMNY6B.js.map → chunk-FXWXBEOZ.js.map} +0 -0
  583. /package/dist/{chunk-UI5O6J6R.js.map → chunk-FY6PONLA.js.map} +0 -0
  584. /package/dist/{chunk-QUIHOPOC.js.map → chunk-G4TKMUOL.js.map} +0 -0
  585. /package/dist/{chunk-6BS2RBW4.js.map → chunk-G7XHJPLO.js.map} +0 -0
  586. /package/dist/{chunk-4RXPIHJG.js.map → chunk-GE2CCITY.js.map} +0 -0
  587. /package/dist/{chunk-WRHBXOGN.js.map → chunk-GG62LKA3.js.map} +0 -0
  588. /package/dist/{chunk-YQCRQHVU.js.map → chunk-GI63FQEJ.js.map} +0 -0
  589. /package/dist/{chunk-WUQKXAYF.js.map → chunk-GPHURU2K.js.map} +0 -0
  590. /package/dist/{chunk-GPT673YL.js.map → chunk-H72YKEGD.js.map} +0 -0
  591. /package/dist/{chunk-AJVFSUC4.js.map → chunk-HFVYWHJT.js.map} +0 -0
  592. /package/dist/{chunk-UP6RO2PR.js.map → chunk-HKBJZX3C.js.map} +0 -0
  593. /package/dist/{chunk-V3RQFWL6.js.map → chunk-IUD6N52Q.js.map} +0 -0
  594. /package/dist/{chunk-N4D5V3AA.js.map → chunk-JAGAFEZL.js.map} +0 -0
  595. /package/dist/{chunk-CLTK76ZF.js.map → chunk-JE5GEWTG.js.map} +0 -0
  596. /package/dist/{chunk-23XBBGWD.js.map → chunk-JFLFZLOA.js.map} +0 -0
  597. /package/dist/{chunk-BLUURKCY.js.map → chunk-K6LNHHSH.js.map} +0 -0
  598. /package/dist/{chunk-HSNOWYEE.js.map → chunk-K7FSTB2K.js.map} +0 -0
  599. /package/dist/{chunk-SXVCXLKU.js.map → chunk-K7MQP2KT.js.map} +0 -0
  600. /package/dist/{chunk-QQ46JX5H.js.map → chunk-KHOAXZW2.js.map} +0 -0
  601. /package/dist/{chunk-SCVBGQFO.js.map → chunk-KQZGUHYZ.js.map} +0 -0
  602. /package/dist/{chunk-GJ7GIGDS.js.map → chunk-LCWGNDTH.js.map} +0 -0
  603. /package/dist/{chunk-4D2IVVHR.js.map → chunk-LF3EVXMF.js.map} +0 -0
  604. /package/dist/{chunk-2XTBGZSR.js.map → chunk-LGCRL7DK.js.map} +0 -0
  605. /package/dist/{chunk-WY35GCHY.js.map → chunk-LODMNSLR.js.map} +0 -0
  606. /package/dist/{chunk-EXFX3JRN.js.map → chunk-M47ZOUGF.js.map} +0 -0
  607. /package/dist/{chunk-AQCQ2USS.js.map → chunk-M65ZNPLO.js.map} +0 -0
  608. /package/dist/{chunk-COUFRGD6.js.map → chunk-MEBQKYH4.js.map} +0 -0
  609. /package/dist/{chunk-JZ5IGO5G.js.map → chunk-NCB4GBRL.js.map} +0 -0
  610. /package/dist/{chunk-SE4WZIKD.js.map → chunk-NFGIA2ZV.js.map} +0 -0
  611. /package/dist/{chunk-H772ZSAI.js.map → chunk-NQ7NMCRI.js.map} +0 -0
  612. /package/dist/{chunk-P7JF6XT7.js.map → chunk-NRSVI23L.js.map} +0 -0
  613. /package/dist/{chunk-FRTEU7ZO.js.map → chunk-NU55QUMO.js.map} +0 -0
  614. /package/dist/{chunk-JB56E4XQ.js.map → chunk-PAICZOL5.js.map} +0 -0
  615. /package/dist/{chunk-QX3CXOJ3.js.map → chunk-PTONBPZL.js.map} +0 -0
  616. /package/dist/{chunk-4UASV6VL.js.map → chunk-QDELBNL3.js.map} +0 -0
  617. /package/dist/{chunk-ZE56GK5C.js.map → chunk-QEI5DC6S.js.map} +0 -0
  618. /package/dist/{chunk-3UXBIUJF.js.map → chunk-RDFPM2AQ.js.map} +0 -0
  619. /package/dist/{chunk-BKHO4RSF.js.map → chunk-RZ2VZ7SL.js.map} +0 -0
  620. /package/dist/{chunk-MT7QJRP7.js.map → chunk-S4IXC2V3.js.map} +0 -0
  621. /package/dist/{chunk-5K4G2XYS.js.map → chunk-SNBAMWI5.js.map} +0 -0
  622. /package/dist/{chunk-MKJHDHLF.js.map → chunk-TCNTIGMY.js.map} +0 -0
  623. /package/dist/{chunk-EKM7C4X2.js.map → chunk-TJ3334AJ.js.map} +0 -0
  624. /package/dist/{chunk-RUZVK4FV.js.map → chunk-TPVSHO75.js.map} +0 -0
  625. /package/dist/{chunk-I72PREY7.js.map → chunk-TTJTMDLI.js.map} +0 -0
  626. /package/dist/{chunk-TU5EIKJA.js.map → chunk-U5SH3VRJ.js.map} +0 -0
  627. /package/dist/{chunk-DOLDAAXH.js.map → chunk-UT73NGRS.js.map} +0 -0
  628. /package/dist/{chunk-BXEMC4YH.js.map → chunk-VYV3JOV5.js.map} +0 -0
  629. /package/dist/{chunk-OTWMG7B2.js.map → chunk-WN5PNP6F.js.map} +0 -0
  630. /package/dist/{chunk-HZBRXLV7.js.map → chunk-XB7HYOMM.js.map} +0 -0
  631. /package/dist/{chunk-C6FVXX7Y.js.map → chunk-XBLFK2FL.js.map} +0 -0
  632. /package/dist/{chunk-EDBVMLNX.js.map → chunk-XHA2NXLD.js.map} +0 -0
  633. /package/dist/{chunk-ZO4NO77T.js.map → chunk-XO4ZUHVH.js.map} +0 -0
  634. /package/dist/{chunk-OPT7X3Y6.js.map → chunk-XXL4PM4M.js.map} +0 -0
  635. /package/dist/{chunk-3HKUOLPD.js.map → chunk-XZY7O7JJ.js.map} +0 -0
  636. /package/dist/{chunk-743SY4WQ.js.map → chunk-YLXQWYOG.js.map} +0 -0
  637. /package/dist/{chunk-Q33JWFSA.js.map → chunk-YPIVLPXF.js.map} +0 -0
  638. /package/dist/{chunk-T7UUP7VD.js.map → chunk-YRUX7XMQ.js.map} +0 -0
  639. /package/dist/{chunk-4JEXYOSN.js.map → chunk-YTXZUTLF.js.map} +0 -0
  640. /package/dist/{chunk-V7A5ZAAF.js.map → chunk-YWJDUJAR.js.map} +0 -0
  641. /package/dist/{chunk-ZK7YERPQ.js.map → chunk-Z2NN53E5.js.map} +0 -0
  642. /package/dist/{chunk-CLSC36JS.js.map → chunk-Z4DKVLYG.js.map} +0 -0
  643. /package/dist/{chunk-NFJ3VVD3.js.map → chunk-Z6T5SXST.js.map} +0 -0
  644. /package/dist/{chunk-IITZA6U2.js.map → chunk-ZBVU2YWV.js.map} +0 -0
  645. /package/dist/{chunk-IEWAFD6L.js.map → chunk-ZC5HDBQO.js.map} +0 -0
  646. /package/dist/{chunk-KQS4ZJGS.js.map → chunk-ZGCPDA3F.js.map} +0 -0
  647. /package/dist/{chunk-AHDNANID.js.map → chunk-ZH2SZ6B3.js.map} +0 -0
  648. /package/dist/{chunk-KOX2AEFW.js.map → chunk-ZKWVCSAB.js.map} +0 -0
  649. /package/dist/{chunk-K2U4BNHQ.js.map → chunk-ZNBLGS66.js.map} +0 -0
  650. /package/dist/{chunk-WGUY7EIB.js.map → chunk-ZUME25DS.js.map} +0 -0
@@ -0,0 +1,197 @@
1
+ import Box from '@mui/material/Box/index.js';
2
+ import React, { forwardRef, useId } from 'react';
3
+
4
+ import { Icon } from '../../../icons';
5
+ import { Button } from '../../form/Button';
6
+
7
+ import { useSettingCard } from './SettingCard.hooks';
8
+ import { LearnMore, PendingSpinner, SaveError, SettingHeader, partTestId } from './SettingCard.parts';
9
+ import { SETTING_CARD_OPEN_ATTR, actionsStyles, summaryStyles, surfaceStyles, withCallerSx } from './SettingCard.styles';
10
+ import type { SettingCardCopy, SettingCardProps } from './SettingCard.types';
11
+
12
+ interface OpenBodyProps {
13
+ bodyRef: React.RefObject<HTMLDivElement | null>;
14
+ titleId: string;
15
+ errorId: string;
16
+ copy: SettingCardCopy;
17
+ learnMore?: React.ReactNode;
18
+ children: React.ReactNode;
19
+ saving: boolean;
20
+ error: string | null;
21
+ saveDisabled: boolean;
22
+ onSave: () => void;
23
+ onCancel: () => void;
24
+ dataTestId?: string;
25
+ }
26
+
27
+ /**
28
+ * The open card: the host's form, the disclosure, the failure line, and the
29
+ * two actions.
30
+ *
31
+ * Save is NOT `disabled` while it saves — it is `aria-disabled` and ignores
32
+ * the click. A disabled button drops the focus it holds, so a keyboard user
33
+ * who pressed Save would land on `<body>` and, if the save then failed, have
34
+ * to find their way back to the form from the top of the page.
35
+ */
36
+ const OpenBody: React.FC<OpenBodyProps> = ({
37
+ bodyRef, titleId, errorId, copy, learnMore, children, saving, error, saveDisabled, onSave, onCancel, dataTestId,
38
+ }) => {
39
+ const onKeyDown = (event: React.KeyboardEvent) => {
40
+ if (event.key !== 'Escape') return;
41
+ event.stopPropagation();
42
+ onCancel();
43
+ };
44
+
45
+ return (
46
+ <Box
47
+ ref={bodyRef}
48
+ role="group"
49
+ aria-labelledby={titleId}
50
+ onKeyDown={onKeyDown}
51
+ sx={{ display: 'flex', flexDirection: 'column', gap: 2, flex: 1 }}
52
+ data-testid={partTestId(dataTestId, 'body')}
53
+ >
54
+ <Box>{children}</Box>
55
+ {learnMore && (
56
+ <LearnMore label={copy.learnMore} dataTestId={dataTestId}>
57
+ {learnMore}
58
+ </LearnMore>
59
+ )}
60
+ <SaveError id={errorId} message={error} dataTestId={dataTestId} />
61
+ <Box sx={(theme) => actionsStyles(theme)}>
62
+ <Button variant="ghost" color="neutral" onClick={onCancel} disabled={saving} dataTestId={partTestId(dataTestId, 'cancel')}>
63
+ {copy.cancel}
64
+ </Button>
65
+ <Button
66
+ variant="solid"
67
+ onClick={onSave}
68
+ disabled={saveDisabled}
69
+ aria-disabled={saving || undefined}
70
+ aria-describedby={error ? errorId : undefined}
71
+ icon={saving ? <PendingSpinner dataTestId={dataTestId} /> : undefined}
72
+ iconPosition="left"
73
+ dataTestId={partTestId(dataTestId, 'save')}
74
+ >
75
+ {saving ? copy.saving : copy.save}
76
+ </Button>
77
+ </Box>
78
+ </Box>
79
+ );
80
+ };
81
+
82
+ /**
83
+ * A setting, summarised while closed and edited in place.
84
+ *
85
+ * Closed: title, status pill, a one-line summary and Edit. Edit opens the card
86
+ * where it is — no dialog, no route — around the host's form, a "learn more"
87
+ * disclosure and Cancel / Save. Save may be async: the card holds its saving
88
+ * state while the promise is pending, closes when it resolves, and stays open
89
+ * with the error when it rejects. Focus moves into the card as it opens and
90
+ * back to Edit as it closes.
91
+ */
92
+ interface EditTriggerProps {
93
+ triggerRef: React.RefObject<HTMLButtonElement | null>;
94
+ id: string;
95
+ titleId: string;
96
+ label: string;
97
+ disabled: boolean;
98
+ onOpen: () => void;
99
+ dataTestId?: string;
100
+ }
101
+
102
+ /** Edit. Its accessible name is "Edit" AND the card's title, so a grid of them is not a list of "Edit, Edit, Edit". */
103
+ const EditTrigger: React.FC<EditTriggerProps> = ({ triggerRef, id, titleId, label, disabled, onOpen, dataTestId }) => (
104
+ <Button
105
+ ref={triggerRef}
106
+ id={id}
107
+ variant="outline"
108
+ color="neutral"
109
+ size="sm"
110
+ icon={<Icon name="Edit" size="xs" />}
111
+ iconPosition="left"
112
+ disabled={disabled}
113
+ aria-labelledby={`${id} ${titleId}`}
114
+ onClick={onOpen}
115
+ dataTestId={partTestId(dataTestId, 'edit')}
116
+ >
117
+ {label}
118
+ </Button>
119
+ );
120
+
121
+ /**
122
+ * A setting, summarised while closed and edited in place.
123
+ *
124
+ * Closed: title, status pill, a one-line summary and Edit. Edit opens the card
125
+ * where it is — no dialog, no route — around the host's form, a "learn more"
126
+ * disclosure and Cancel / Save. Save may be async: the card holds its saving
127
+ * state while the promise is pending, closes when it resolves, and stays open
128
+ * with the error when it rejects. Focus moves into the card as it opens and
129
+ * back to Edit as it closes.
130
+ */
131
+ export const SettingCard = forwardRef<HTMLElement, SettingCardProps>(function SettingCard(props, ref) {
132
+ const { title, headingLevel = 'h3', icon, status, summary, children, learnMore, copy, dataTestId, className, sx } = props;
133
+ const baseId = useId();
134
+ const titleId = `${baseId}-title`;
135
+ const card = useSettingCard(props);
136
+ const { open } = card;
137
+
138
+ return (
139
+ <Box
140
+ component="section"
141
+ ref={ref}
142
+ aria-labelledby={titleId}
143
+ aria-busy={card.saving || undefined}
144
+ data-state={open ? 'open' : 'closed'}
145
+ {...{ [SETTING_CARD_OPEN_ATTR]: open ? '' : undefined }}
146
+ data-testid={dataTestId}
147
+ className={className}
148
+ sx={withCallerSx((theme) => surfaceStyles(theme, open), sx)}
149
+ >
150
+ <SettingHeader
151
+ titleId={titleId}
152
+ title={title}
153
+ headingLevel={headingLevel}
154
+ icon={icon}
155
+ status={status}
156
+ trailing={
157
+ open ? null : (
158
+ <EditTrigger
159
+ triggerRef={card.editRef}
160
+ id={`${baseId}-edit`}
161
+ titleId={titleId}
162
+ label={copy.edit}
163
+ disabled={card.disabled}
164
+ onOpen={card.openCard}
165
+ dataTestId={dataTestId}
166
+ />
167
+ )
168
+ }
169
+ dataTestId={dataTestId}
170
+ />
171
+ {!open && summary != null && (
172
+ <Box component="p" sx={summaryStyles} data-testid={partTestId(dataTestId, 'summary')}>
173
+ {summary}
174
+ </Box>
175
+ )}
176
+ {open && (
177
+ <OpenBody
178
+ bodyRef={card.bodyRef}
179
+ titleId={titleId}
180
+ errorId={`${baseId}-error`}
181
+ copy={copy}
182
+ learnMore={learnMore}
183
+ saving={card.saving}
184
+ error={card.error}
185
+ saveDisabled={card.saveDisabled}
186
+ onSave={card.save}
187
+ onCancel={card.cancel}
188
+ dataTestId={dataTestId}
189
+ >
190
+ {children}
191
+ </OpenBody>
192
+ )}
193
+ </Box>
194
+ );
195
+ });
196
+
197
+ SettingCard.displayName = 'SettingCard';
@@ -0,0 +1,140 @@
1
+ import type { SxProps, Theme } from '@mui/material/styles/index.js';
2
+ import type { ReactNode } from 'react';
3
+
4
+ import type { SettingCardCopy, SettingSwitchCopy } from '../../../copy';
5
+ import type { ColorValue } from '../../../tokens/vocabulary';
6
+
7
+ export type { SettingCardCopy, SettingSwitchCopy } from '../../../copy';
8
+
9
+ /**
10
+ * What a save handler may return. A promise holds the card in its saving
11
+ * state until it settles; a rejection is the failure path. A plain return is
12
+ * a synchronous success.
13
+ */
14
+ export type SettingSaveResult = void | Promise<unknown>;
15
+
16
+ /**
17
+ * Turns whatever a rejected save threw into the sentence the card shows.
18
+ * Return `undefined` to fall back to the copy's `saveFailed`. The card never
19
+ * renders an `Error.message` on its own: that string is usually written for a
20
+ * developer, in the developer's language.
21
+ */
22
+ export type SettingErrorFormatter = (error: unknown) => string | undefined;
23
+
24
+ /** The heading level a card's title renders at, so it fits the page outline. */
25
+ export type SettingHeadingLevel = 'h2' | 'h3' | 'h4' | 'h5' | 'h6';
26
+
27
+ /** The pill beside a closed card's title: the setting's current state, in words. */
28
+ export interface SettingStatus {
29
+ /** What the state IS, in the host's language: "On", "Not configured". */
30
+ label: string;
31
+ /** A house colour. Colour is never the only carrier: `label` is always shown. Defaults to `neutral`. */
32
+ color?: ColorValue;
33
+ }
34
+
35
+ /** What every card in the family shares. */
36
+ interface SettingSurfaceProps {
37
+ /** The setting's name. Also the accessible name of the card's region. */
38
+ title: string;
39
+ /** The heading level of `title`. Defaults to `h3`. */
40
+ headingLevel?: SettingHeadingLevel;
41
+ /** A decorative glyph before the title. */
42
+ icon?: ReactNode;
43
+ /** Maps a rejected save to the sentence shown; see {@link SettingErrorFormatter}. */
44
+ formatError?: SettingErrorFormatter;
45
+ /** Root test id. Parts derive theirs from it (`<id>-edit`, `<id>-save`, …). */
46
+ dataTestId?: string;
47
+ className?: string;
48
+ sx?: SxProps<Theme>;
49
+ }
50
+
51
+ export interface SettingCardProps extends SettingSurfaceProps {
52
+ /** The chrome words (Edit, Cancel, Save, …). REQUIRED — no default copy. */
53
+ copy: SettingCardCopy;
54
+ /** The one line a closed card shows under its title: the setting's current value. */
55
+ summary?: ReactNode;
56
+ /** The pill beside the title. Omit for none. */
57
+ status?: SettingStatus;
58
+ /** The form, rendered only while the card is open (so an uncontrolled draft is discarded on close). */
59
+ children: ReactNode;
60
+ /** Longer explanation behind a "learn more" disclosure in the open card. Omit for no disclosure. */
61
+ learnMore?: ReactNode;
62
+ /**
63
+ * Persist the draft. The card stays in its saving state while a returned
64
+ * promise is pending, closes when it resolves, and STAYS OPEN showing the
65
+ * error when it rejects.
66
+ */
67
+ onSave: () => SettingSaveResult;
68
+ /** The card closed without saving — reset the host's draft here. */
69
+ onCancel?: () => void;
70
+ /** Controlled open state. Pair with `onOpenChange`. */
71
+ open?: boolean;
72
+ /** Uncontrolled initial open state. */
73
+ defaultOpen?: boolean;
74
+ /** Every open/close request: Edit, Cancel, Escape, and a successful save. */
75
+ onOpenChange?: (open: boolean) => void;
76
+ /** Disables Edit on a closed card (the setting cannot be changed from here). */
77
+ disabled?: boolean;
78
+ /** Disables Save — for a draft the host knows is invalid. */
79
+ saveDisabled?: boolean;
80
+ }
81
+
82
+ interface SettingSwitchProps extends SettingSurfaceProps {
83
+ /** The saving and failure words. REQUIRED — no default copy. */
84
+ copy: SettingSwitchCopy;
85
+ /** Explanation under the title. Read to screen readers as the switch's description. */
86
+ summary?: ReactNode;
87
+ /** The persisted value. The switch shows the flip optimistically while it saves, then this again. */
88
+ checked: boolean;
89
+ /**
90
+ * Persist a flip. The switch shows the new value and a saving state while a
91
+ * returned promise is pending; a rejection reverts it and shows the error.
92
+ */
93
+ onChange: (checked: boolean) => SettingSaveResult;
94
+ /** Disables the switch. */
95
+ disabled?: boolean;
96
+ }
97
+
98
+ /**
99
+ * `card` draws the surface; `row` draws the same content flat, for a
100
+ * dependent row inside a `SettingGroup` (a card inside a card reads as two
101
+ * subjects).
102
+ */
103
+ export type SettingToggleVariant = 'card' | 'row';
104
+
105
+ export interface SettingToggleProps extends SettingSwitchProps {
106
+ /** Defaults to `card`. */
107
+ variant?: SettingToggleVariant;
108
+ }
109
+
110
+ export interface SettingGroupProps extends SettingSwitchProps {
111
+ /**
112
+ * Why the dependent rows are inactive while the main switch is off —
113
+ * "Turn on notifications to choose which ones you get". Shown only then.
114
+ */
115
+ inactiveHint: string;
116
+ /** The dependent rows. Stay rendered while the main switch is off, dimmed and inert. */
117
+ children: ReactNode;
118
+ }
119
+
120
+ /** The most columns a `SettingGrid` lays out. */
121
+ export type SettingGridColumns = 1 | 2 | 3;
122
+
123
+ export interface SettingGridProps {
124
+ children: ReactNode;
125
+ /**
126
+ * The narrowest a column may get, in design px (scaled with the type
127
+ * scale). The grid adds a column each time its OWN width fits one more.
128
+ * Defaults to 320.
129
+ */
130
+ minColumnWidth?: number;
131
+ /** Defaults to 3. */
132
+ maxColumns?: SettingGridColumns;
133
+ /** Gap between cards, in theme spacing units. Defaults to 2. */
134
+ gap?: number;
135
+ /** Accessible name. When set the grid renders as a labelled `region`. */
136
+ 'aria-label'?: string;
137
+ dataTestId?: string;
138
+ className?: string;
139
+ sx?: SxProps<Theme>;
140
+ }
@@ -0,0 +1,65 @@
1
+ # SettingGrid
2
+
3
+ ## Purpose
4
+
5
+ Lays setting cards out in **one, two or three columns by the width it is
6
+ given**. Part of the `layout/SettingCard` family.
7
+
8
+ - **Container queries, not media queries.** A settings grid lives beside a
9
+ navigation rail, inside a drawer, in half a split view; the viewport says
10
+ nothing about how wide any of those are. The grid asks its own width.
11
+ - **Equal-height rows, without measuring.** Each row is as tall as its tallest
12
+ card and every card in it stretches to match (`grid-auto-rows: auto` with
13
+ `align-items: stretch`). Not `1fr` rows — those make *every* row as tall as the
14
+ tallest one on the page.
15
+ - **An open card spans the row.** A [`SettingCard`](./SettingCard.md) mid-edit
16
+ takes the whole row, wherever it sat, so its form has room.
17
+
18
+ ## Usage
19
+
20
+ ```tsx
21
+ import { SettingCard, SettingGrid, SettingToggle } from '@12-apps/ui/layout/SettingCard';
22
+
23
+ <SettingGrid aria-label="Security">
24
+ <SettingCard … />
25
+ <SettingToggle … />
26
+ <SettingGroup … />
27
+ </SettingGrid>
28
+ ```
29
+
30
+ ## Props
31
+
32
+ | prop | type | default | effect |
33
+ |---|---|---|---|
34
+ | `children` | `ReactNode` | **required** | The cards. |
35
+ | `minColumnWidth` | `number` | `320` | The narrowest a column may get, in design px (scaled through the type scale). A column is added each time the grid's own width fits one more. |
36
+ | `maxColumns` | `1 \| 2 \| 3` | `3` | The most columns laid out. |
37
+ | `gap` | `number` | `2` | Gap between cards, in theme spacing units. |
38
+ | `aria-label` | `string` | — | When set, the grid is a labelled `region`. |
39
+ | `dataTestId` | `string` | — | On the container; the inner grid is `<id>-grid`. |
40
+ | `className`, `sx` | | | On the container. |
41
+
42
+ ## How the columns are decided
43
+
44
+ The outer element is an `inline-size` container named `setting-grid`
45
+ (`SETTING_GRID_CONTAINER`); the inner element is the grid, because a container
46
+ query is answered by an **ancestor**. `n` columns apply from
47
+
48
+ ```
49
+ calc(n × minColumnWidth + (n − 1) × gap)
50
+ ```
51
+
52
+ so a column is never narrower than `minColumnWidth`. Nested grids each answer
53
+ to their own container.
54
+
55
+ ## The open-card span
56
+
57
+ `SettingCard` sets `grid-column: 1 / -1` on itself while open and carries
58
+ `data-setting-card-open`. The grid also gives the whole row to a direct child
59
+ that **contains** an open card (`:has()`), so a host that wraps each card in an
60
+ element of its own keeps the behaviour.
61
+
62
+ ## Accessibility
63
+
64
+ Layout only: reading and tab order are the children's source order at every
65
+ width — the grid never reorders them.
@@ -0,0 +1,105 @@
1
+ import Box from '@mui/material/Box/index.js';
2
+ import { useTheme, type CSSObject, type Theme } from '@mui/material/styles/index.js';
3
+ import { forwardRef } from 'react';
4
+
5
+ import { rem } from '../../../tokens/relative';
6
+
7
+ import { SETTING_CARD, SETTING_GRID_GAP_UNITS } from './SettingCard.metrics';
8
+ import { partTestId } from './SettingCard.parts';
9
+ import { SETTING_CARD_OPEN_ATTR, withCallerSx } from './SettingCard.styles';
10
+ import type { SettingGridColumns, SettingGridProps } from './SettingCard.types';
11
+
12
+ /** The container the grid's own queries are asked of. Named, so a nested grid answers to its own. */
13
+ export const SETTING_GRID_CONTAINER = 'setting-grid';
14
+
15
+ /** The track list for `n` equal columns. `minmax(0, …)` so a long word cannot widen its column. */
16
+ const tracks = (n: SettingGridColumns): string => `repeat(${n}, minmax(0, 1fr))`;
17
+
18
+ /**
19
+ * The narrowest the container can be and still fit `n` columns of
20
+ * `minColumnWidth` with the gaps between them. A `calc()` because the gap is a
21
+ * spacing unit and the width a type-scale length: two scales, one sum.
22
+ */
23
+ const threshold = (theme: Theme, n: number, minColumnPx: number, gapUnits: number): string =>
24
+ `calc(${n} * ${rem(theme, minColumnPx)} + ${n - 1} * ${theme.spacing(gapUnits)})`;
25
+
26
+ /**
27
+ * The grid itself.
28
+ *
29
+ * - Columns come from CONTAINER queries, not viewport ones: a settings grid
30
+ * lives beside a rail, inside a drawer, in half a split view, and the
31
+ * viewport says nothing about how wide any of those are.
32
+ * - `grid-auto-rows: auto` with `align-items: stretch` is the equal-height
33
+ * rule: each row is as tall as its tallest card and every card in it
34
+ * stretches to match. Not `1fr` rows — those would make EVERY row as tall as
35
+ * the tallest, so one open card would inflate the whole page.
36
+ * - An open card spans the row. The card sets `grid-column` on itself; the
37
+ * `:has()` rule covers a card the host wrapped in an element of its own.
38
+ */
39
+ export interface SettingGridLayout {
40
+ /** The narrowest column, in DESIGN px (drawn through `rem`). */
41
+ minColumnPx: number;
42
+ maxColumns: SettingGridColumns;
43
+ /** The gap, in theme SPACING units. */
44
+ gapUnits: number;
45
+ }
46
+
47
+ export function settingGridStyles(theme: Theme, { minColumnPx, maxColumns, gapUnits }: SettingGridLayout): CSSObject {
48
+ const styles: CSSObject = {
49
+ display: 'grid',
50
+ gap: theme.spacing(gapUnits),
51
+ gridTemplateColumns: tracks(1),
52
+ gridAutoRows: 'auto',
53
+ alignItems: 'stretch',
54
+ [`& > [${SETTING_CARD_OPEN_ATTR}], & > :has([${SETTING_CARD_OPEN_ATTR}])`]: { gridColumn: '1 / -1' },
55
+ };
56
+ for (const n of [2, 3] as const) {
57
+ if (n > maxColumns) break;
58
+ styles[`@container ${SETTING_GRID_CONTAINER} (min-width: ${threshold(theme, n, minColumnPx, gapUnits)})`] = {
59
+ gridTemplateColumns: tracks(n),
60
+ };
61
+ }
62
+ return styles;
63
+ }
64
+
65
+ /**
66
+ * Lays setting cards out in one, two or three columns by the width it is
67
+ * GIVEN — see {@link settingGridStyles}. Two elements, because a container
68
+ * query is answered by an ANCESTOR: the outer one is the container, the inner
69
+ * one the grid.
70
+ */
71
+ export const SettingGrid = forwardRef<HTMLDivElement, SettingGridProps>(function SettingGrid(props, ref) {
72
+ const {
73
+ children,
74
+ minColumnWidth = SETTING_CARD.gridMinColumnWidth,
75
+ maxColumns = 3,
76
+ gap = SETTING_GRID_GAP_UNITS,
77
+ 'aria-label': ariaLabel,
78
+ dataTestId,
79
+ className,
80
+ sx,
81
+ } = props;
82
+ const theme = useTheme();
83
+ const gridStyles = settingGridStyles(theme, { minColumnPx: minColumnWidth, maxColumns, gapUnits: gap });
84
+
85
+ return (
86
+ <Box
87
+ ref={ref}
88
+ role={ariaLabel ? 'region' : undefined}
89
+ aria-label={ariaLabel}
90
+ data-testid={dataTestId}
91
+ className={className}
92
+ sx={withCallerSx({ containerType: 'inline-size', containerName: SETTING_GRID_CONTAINER, minWidth: 0 }, sx)}
93
+ >
94
+ <Box
95
+ sx={gridStyles}
96
+ data-max-columns={maxColumns}
97
+ data-testid={partTestId(dataTestId, 'grid')}
98
+ >
99
+ {children}
100
+ </Box>
101
+ </Box>
102
+ );
103
+ });
104
+
105
+ SettingGrid.displayName = 'SettingGrid';
@@ -0,0 +1,11 @@
1
+ import { createContext, useContext } from 'react';
2
+
3
+ /**
4
+ * What a `SettingGroup` tells the rows inside it: whether its main switch is
5
+ * off. `inert` on the rows' container already makes every descendant
6
+ * unreachable; this is for the family's own rows (`SettingToggle`) to ALSO
7
+ * draw and announce themselves as disabled, which `inert` does not do.
8
+ */
9
+ export const SettingGroupContext = createContext<{ inactive: boolean }>({ inactive: false });
10
+
11
+ export const useSettingGroup = (): { inactive: boolean } => useContext(SettingGroupContext);
@@ -0,0 +1,81 @@
1
+ # SettingGroup
2
+
3
+ ## Purpose
4
+
5
+ **One subject**: a main switch, plus the settings that only mean something
6
+ while it is on, indented beneath it. "Notifications" on or off, and — while on —
7
+ which notifications and when.
8
+
9
+ When the main switch is off the dependent rows **stay where they are**: dimmed,
10
+ disabled, and explained by a short hint. They are not removed. A reader
11
+ deciding whether to turn a feature on is helped by seeing what it would let
12
+ them configure, and a layout that jumps when a switch flips moves the thing
13
+ they were about to press.
14
+
15
+ Part of the `layout/SettingCard` family.
16
+
17
+ ## One group per subject — not a container for a page
18
+
19
+ A `SettingGroup` is for several settings of **the same subject**, where the
20
+ main switch decides whether the others apply at all. It is not a way to put
21
+ several unrelated settings in one box.
22
+
23
+ | these are… | use |
24
+ |---|---|
25
+ | Notifications (main switch) + digest, mentions, quiet hours | **one** `SettingGroup` — the rows mean nothing with notifications off |
26
+ | Session timeout, two-step sign-in, language | **three** cards — a `SettingCard`, a `SettingToggle`, a `SettingCard` — laid out by a `SettingGrid` |
27
+ | Backups (main switch) + frequency, retention | **one** `SettingGroup` |
28
+ | Backups and notifications | **two** groups, never one |
29
+
30
+ The test: if turning the main switch off would **not** make a row meaningless,
31
+ that row is a different subject and belongs in its own card. Squeezing two
32
+ subjects into one group gives one of them a main switch it does not have, and a
33
+ hint ("inactive until X is on") that is false for it.
34
+
35
+ ## Usage
36
+
37
+ ```tsx
38
+ import { SettingGroup, SettingToggle } from '@12-apps/ui/layout/SettingCard';
39
+
40
+ <SettingGroup
41
+ copy={switchCopy}
42
+ title="Notifications"
43
+ summary="What we tell you about, and when."
44
+ inactiveHint="Turn notifications on to choose which ones you get."
45
+ checked={settings.notifications}
46
+ onChange={(next) => api.setNotifications(next)}
47
+ >
48
+ <SettingToggle variant="row" copy={switchCopy} title="Weekly digest" checked={settings.digest} onChange={api.setDigest} />
49
+ <SettingToggle variant="row" copy={switchCopy} title="Mentions" checked={settings.mentions} onChange={api.setMentions} />
50
+ <NumberField label="Quiet hours from" value={quietFrom} onChange={setQuietFrom} min={0} max={23} suffix="h" />
51
+ </SettingGroup>
52
+ ```
53
+
54
+ ## Props
55
+
56
+ | prop | type | default | effect |
57
+ |---|---|---|---|
58
+ | `copy` | `SettingSwitchCopy` | **required** | The main switch's "saving" announcement and fallback error. |
59
+ | `title` | `string` | **required** | The subject. Names the main switch and the dependent rows' group. |
60
+ | `checked` | `boolean` | **required** | The main switch's persisted value. |
61
+ | `onChange` | `(checked: boolean) => void \| Promise<unknown>` | **required** | Persist the main switch — same async contract as [`SettingToggle`](./SettingToggle.md). |
62
+ | `inactiveHint` | `string` | **required** | Why the rows are inactive. Shown only while they are. |
63
+ | `children` | `ReactNode` | **required** | The dependent rows — `SettingToggle variant="row"`, fields, anything. |
64
+ | `summary` | `ReactNode` | — | Explanation under the title. |
65
+ | `disabled` | `boolean` | `false` | Disables the main switch; the rows are then inactive too. |
66
+ | `formatError`, `icon`, `dataTestId`, `className`, `sx` | | | As on `SettingToggle`. Parts add `-dependents` and `-hint`. |
67
+
68
+ ## When the rows are active
69
+
70
+ Only while the main switch is on **and saved**: turning it on lights the rows
71
+ once the save lands (so nobody edits rows a failed save then disables), and
72
+ turning it off dims them at once.
73
+
74
+ ## Accessibility
75
+
76
+ - The dependent rows are a `role="group"` named by the subject.
77
+ - Inactive, the group is `inert` — nothing in it is focusable or clickable,
78
+ whatever the host put there — and `aria-disabled`, described by the hint.
79
+ - The family's own rows (`SettingToggle`) also render `disabled`, so they read
80
+ as disabled rather than merely unreachable.
81
+ - Opacity alone never carries "inactive"; the hint says it in words.
@@ -0,0 +1,73 @@
1
+ import Box from '@mui/material/Box/index.js';
2
+ import { useTheme } from '@mui/material/styles/index.js';
3
+ import { forwardRef, useId, useMemo } from 'react';
4
+
5
+ import { Icon } from '../../../icons';
6
+
7
+ import { useAsyncSwitch } from './SettingCard.hooks';
8
+ import { partTestId } from './SettingCard.parts';
9
+ import { dependentsStyles, hintStyles, surfaceStyles, withCallerSx } from './SettingCard.styles';
10
+ import type { SettingGroupProps } from './SettingCard.types';
11
+ import { SettingGroupContext } from './SettingGroup.context';
12
+ import { SettingSwitchBlock, useSettingSwitchIds } from './SettingSwitch';
13
+
14
+ /**
15
+ * ONE subject: a main switch, and the settings that only mean something while
16
+ * it is on, indented beneath it.
17
+ *
18
+ * With the main switch off the dependent rows stay where they are — dimmed,
19
+ * `inert`, and explained by `inactiveHint` — rather than disappearing. A
20
+ * reader deciding whether to turn a feature on is helped by seeing what it
21
+ * would let them configure, and a layout that jumps when a switch flips moves
22
+ * the thing they were about to press.
23
+ *
24
+ * The rows are active only while the main switch is on AND saved: turning it
25
+ * on lights them once the save lands; turning it off dims them at once.
26
+ *
27
+ * Several subjects are several cards, never one group — see `SettingGroup.md`.
28
+ */
29
+ export const SettingGroup = forwardRef<HTMLElement, SettingGroupProps>(function SettingGroup(props, ref) {
30
+ const {
31
+ checked, onChange, copy, formatError, inactiveHint, children, disabled = false, dataTestId, className, sx,
32
+ } = props;
33
+ const theme = useTheme();
34
+ const ids = useSettingSwitchIds();
35
+ const hintId = `${useId()}-hint`;
36
+ const state = useAsyncSwitch({ checked, onChange, formatError, fallback: copy.saveFailed });
37
+ const active = checked && state.shown && !disabled;
38
+ const context = useMemo(() => ({ inactive: !active }), [active]);
39
+
40
+ return (
41
+ <Box
42
+ component="section"
43
+ ref={ref}
44
+ aria-labelledby={ids.titleId}
45
+ aria-busy={state.saving || undefined}
46
+ data-active={active}
47
+ data-testid={dataTestId}
48
+ className={className}
49
+ sx={withCallerSx((t) => surfaceStyles(t, false), sx)}
50
+ >
51
+ <SettingSwitchBlock {...props} disabled={disabled} ids={ids} state={state} />
52
+ {!active && (
53
+ <Box component="p" id={hintId} sx={hintStyles(theme)} data-testid={partTestId(dataTestId, 'hint')}>
54
+ <Icon name="InfoOutlined" size="xs" />
55
+ <span>{inactiveHint}</span>
56
+ </Box>
57
+ )}
58
+ <Box
59
+ role="group"
60
+ aria-labelledby={ids.titleId}
61
+ aria-describedby={active ? undefined : hintId}
62
+ aria-disabled={active ? undefined : true}
63
+ inert={!active}
64
+ sx={dependentsStyles(theme, active)}
65
+ data-testid={partTestId(dataTestId, 'dependents')}
66
+ >
67
+ <SettingGroupContext.Provider value={context}>{children}</SettingGroupContext.Provider>
68
+ </Box>
69
+ </Box>
70
+ );
71
+ });
72
+
73
+ SettingGroup.displayName = 'SettingGroup';