@persona/design-system 0.10.14 → 0.10.15

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 (381) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/dist/{Action-CHWYwpYR.d.mts → Action-sLO73eKq.d.mts} +2 -2
  3. package/dist/Action.d.mts +1 -1
  4. package/dist/AdvancedFilterRuleRow.d.mts +2 -2
  5. package/dist/AdvancedFilterRulesPopover.d.mts +2 -2
  6. package/dist/ArrayValueControl.d.mts +1 -1
  7. package/dist/Attribute.d.mts +2 -2
  8. package/dist/{Badge-B2AJMf3d.mjs → Badge-DZq6ByIU.mjs} +2 -2
  9. package/dist/{Badge-B2AJMf3d.mjs.map → Badge-DZq6ByIU.mjs.map} +1 -1
  10. package/dist/BooleanValueControl.d.mts +1 -1
  11. package/dist/{Breadcrumbs-DRs9eo1o.mjs → Breadcrumbs-I4VWR3NE.mjs} +9 -9
  12. package/dist/{Breadcrumbs-DRs9eo1o.mjs.map → Breadcrumbs-I4VWR3NE.mjs.map} +1 -1
  13. package/dist/{Button-DjD8QxcY.d.mts → Button-C4a4BTjL.d.mts} +2 -2
  14. package/dist/Button.d.mts +1 -1
  15. package/dist/CalendarBase.d.mts +1 -1
  16. package/dist/{Card-DiUHtYg_.d.mts → Card-CPV4_mHk.d.mts} +4 -4
  17. package/dist/Card.d.mts +1 -1
  18. package/dist/Card2.d.mts +3 -3
  19. package/dist/CardGrouping.d.mts +1 -1
  20. package/dist/{CardV2-DO-8COfu.mjs → CardV2-CGwm01p7.mjs} +13 -13
  21. package/dist/{CardV2-DO-8COfu.mjs.map → CardV2-CGwm01p7.mjs.map} +1 -1
  22. package/dist/{Checkbox-BAh-wF_F.mjs → Checkbox-C0uefDLS.mjs} +6 -6
  23. package/dist/{Checkbox-BAh-wF_F.mjs.map → Checkbox-C0uefDLS.mjs.map} +1 -1
  24. package/dist/{CheckboxGroupField-tBvP22Bo.d.mts → CheckboxGroupField-NZ2-Y5KV.d.mts} +2 -2
  25. package/dist/CheckboxGroupField.d.mts +1 -1
  26. package/dist/ChoicesValueControl.d.mts +1 -1
  27. package/dist/{Combobox-RX4DfO5L.d.mts → Combobox-CHpJVaXK.d.mts} +3 -3
  28. package/dist/{Combobox-DmFQ5cAy.mjs → Combobox-DPhX1GIR.mjs} +34 -23
  29. package/dist/Combobox-DPhX1GIR.mjs.map +1 -0
  30. package/dist/Combobox.d.mts +2 -2
  31. package/dist/{ComboboxBase-VIGR58Uc.d.mts → ComboboxBase-D2X8exFX.d.mts} +8 -6
  32. package/dist/ComboboxBase.d.mts +1 -1
  33. package/dist/{ComboboxMultiSelect-D5TWGGKZ.d.mts → ComboboxMultiSelect-O4awZnXr.d.mts} +2 -2
  34. package/dist/ComboboxMultiSelect.d.mts +1 -1
  35. package/dist/{ComboboxSingleSelect-D9It8t6W.d.mts → ComboboxSingleSelect-Ck-xBJqU.d.mts} +3 -3
  36. package/dist/ComboboxSingleSelect.d.mts +1 -1
  37. package/dist/{CompactBar-tNtY2EhN.d.mts → CompactBar-DdlHPalF.d.mts} +3 -3
  38. package/dist/CompactBar.d.mts +1 -1
  39. package/dist/{ConfigFormGroup-BCTWCws5.mjs → ConfigFormGroup-gOg83LzL.mjs} +3 -3
  40. package/dist/{ConfigFormGroup-BCTWCws5.mjs.map → ConfigFormGroup-gOg83LzL.mjs.map} +1 -1
  41. package/dist/{ControlBar-CDb6b1_6.d.mts → ControlBar-Z_GGxMpa.d.mts} +4 -2
  42. package/dist/ControlBar.d.mts +1 -1
  43. package/dist/{DataTable-6t5ryaEq.mjs → DataTable-D2iX3Ua6.mjs} +18 -18
  44. package/dist/{DataTable-6t5ryaEq.mjs.map → DataTable-D2iX3Ua6.mjs.map} +1 -1
  45. package/dist/{DataTable-0nhT5_Fe.d.mts → DataTable-Xt9cBYlh.d.mts} +6 -6
  46. package/dist/DataTable.d.mts +1 -1
  47. package/dist/{DatePicker-CHVYVKB-.mjs → DatePicker-CZsjaBO2.mjs} +11 -11
  48. package/dist/{DatePicker-CHVYVKB-.mjs.map → DatePicker-CZsjaBO2.mjs.map} +1 -1
  49. package/dist/DateRangeValueControl.d.mts +1 -1
  50. package/dist/DateValueControl.d.mts +1 -1
  51. package/dist/{DropdownButton-BxZ5hn0X.mjs → DropdownButton-ILgsmuFy.mjs} +3 -3
  52. package/dist/{DropdownButton-BxZ5hn0X.mjs.map → DropdownButton-ILgsmuFy.mjs.map} +1 -1
  53. package/dist/DropdownButton.d.mts +2 -2
  54. package/dist/{DropdownMenu-Db6N6ZNB.d.mts → DropdownMenu-BK-AmDAC.d.mts} +3 -3
  55. package/dist/{DropdownMenu-Ip75l4Th.mjs → DropdownMenu-CYZTQS02.mjs} +3 -3
  56. package/dist/{DropdownMenu-Ip75l4Th.mjs.map → DropdownMenu-CYZTQS02.mjs.map} +1 -1
  57. package/dist/DropdownMenu.d.mts +1 -1
  58. package/dist/{FieldRegistry-CJwGpUVK.d.mts → FieldRegistry-CD8fjf9Z.d.mts} +2 -2
  59. package/dist/FieldRegistry.d.mts +1 -1
  60. package/dist/{FilterBar-CA4mDAXK.d.mts → FilterBar-B1fwBKuZ.d.mts} +4 -4
  61. package/dist/FilterBar.d.mts +1 -1
  62. package/dist/FilterPanelSlot.d.mts +30 -0
  63. package/dist/FilterPanelVisibilityContext.d.mts +9 -0
  64. package/dist/FilterPickerMenu.d.mts +2 -2
  65. package/dist/FilterPill.d.mts +1 -1
  66. package/dist/FilterPopover.d.mts +1 -14
  67. package/dist/FloatValueControl.d.mts +1 -1
  68. package/dist/{FloatingToolbar-BA8Fqmrz.mjs → FloatingToolbar-Do5PMF_v.mjs} +4 -4
  69. package/dist/{FloatingToolbar-BA8Fqmrz.mjs.map → FloatingToolbar-Do5PMF_v.mjs.map} +1 -1
  70. package/dist/{FormControl-BoKGiWdQ.mjs → FormControl--iW9afGv.mjs} +5 -5
  71. package/dist/{FormControl-BoKGiWdQ.mjs.map → FormControl--iW9afGv.mjs.map} +1 -1
  72. package/dist/{FormControl-BQe3GRhi.d.mts → FormControl-DPYbLcBK.d.mts} +2 -2
  73. package/dist/FormControl.d.mts +1 -1
  74. package/dist/FormControlLabel.d.mts +2 -2
  75. package/dist/{FormField-BW5uMzId.d.mts → FormField-CYNGm2bJ.d.mts} +2 -2
  76. package/dist/{FormField-BfVrDOY0.mjs → FormField-C_rAxIPH.mjs} +16 -16
  77. package/dist/{FormField-BfVrDOY0.mjs.map → FormField-C_rAxIPH.mjs.map} +1 -1
  78. package/dist/FormField.d.mts +1 -1
  79. package/dist/{Grid-CYpOqTUu.mjs → Grid-DVC0SSEZ.mjs} +2 -2
  80. package/dist/{Grid-CYpOqTUu.mjs.map → Grid-DVC0SSEZ.mjs.map} +1 -1
  81. package/dist/{Header-CV0Lcf0C.d.mts → Header-DaaUprCL.d.mts} +2 -2
  82. package/dist/Header.d.mts +1 -1
  83. package/dist/{HelperTooltip-BNM3pTM-.d.mts → HelperTooltip-C5BDdJSI.d.mts} +2 -2
  84. package/dist/HelperTooltip.d.mts +1 -1
  85. package/dist/HighlightedText.d.mts +1 -1
  86. package/dist/{HoverCopyableField-CJ_p3llp.mjs → HoverCopyableField-Dy_lE6Wg.mjs} +5 -5
  87. package/dist/{HoverCopyableField-CJ_p3llp.mjs.map → HoverCopyableField-Dy_lE6Wg.mjs.map} +1 -1
  88. package/dist/{IconButton-C_ReZm8v.d.mts → IconButton-7k-wjvH3.d.mts} +2 -2
  89. package/dist/{IconButton-Bj1fry_K.mjs → IconButton-kSjnfhWt.mjs} +8 -8
  90. package/dist/{IconButton-Bj1fry_K.mjs.map → IconButton-kSjnfhWt.mjs.map} +1 -1
  91. package/dist/IconButton.d.mts +1 -1
  92. package/dist/ImageTile.d.mts +1 -1
  93. package/dist/IndexTableLayout.d.mts +4 -4
  94. package/dist/InlineCombobox.d.mts +1 -1
  95. package/dist/InlineInput.d.mts +1 -1
  96. package/dist/{Input-DcbzPaax.mjs → Input-BIHbRmmU.mjs} +6 -6
  97. package/dist/{Input-DcbzPaax.mjs.map → Input-BIHbRmmU.mjs.map} +1 -1
  98. package/dist/{Input-DH-5dKor.d.mts → Input-CwvrBsiS.d.mts} +3 -3
  99. package/dist/Input.d.mts +1 -1
  100. package/dist/IntegerValueControl.d.mts +1 -1
  101. package/dist/{Link-Df3zJrj2.mjs → Link-CnT85JqA.mjs} +4 -4
  102. package/dist/{Link-Df3zJrj2.mjs.map → Link-CnT85JqA.mjs.map} +1 -1
  103. package/dist/{ListBox-l47zUDj4.d.mts → ListBox-Cu-NLNRF.d.mts} +3 -3
  104. package/dist/{ListBox-BRgjgUSp.mjs → ListBox-CwC9YztW.mjs} +13 -13
  105. package/dist/{ListBox-BRgjgUSp.mjs.map → ListBox-CwC9YztW.mjs.map} +1 -1
  106. package/dist/ListBox.d.mts +1 -1
  107. package/dist/{ListBoxField-Di_6uD3S.d.mts → ListBoxField-Vetrl4r5.d.mts} +4 -4
  108. package/dist/ListBoxField.d.mts +1 -1
  109. package/dist/{LoadingShimmer-BVVdBeN-.mjs → LoadingShimmer-BypAGgyP.mjs} +1 -1
  110. package/dist/{LoadingShimmer-BVVdBeN-.mjs.map → LoadingShimmer-BypAGgyP.mjs.map} +1 -1
  111. package/dist/LoadingShimmer.d.mts +1 -1
  112. package/dist/{LogicRow-7f17CKrW.d.mts → LogicRow-D4YL4C6U.d.mts} +2 -2
  113. package/dist/LogicRow.d.mts +1 -1
  114. package/dist/MaskedInput.d.mts +2 -2
  115. package/dist/MatchHighlight.d.mts +1 -1
  116. package/dist/{Menu-DvzoR8e7.d.mts → Menu-DNJMfxfw.d.mts} +4 -4
  117. package/dist/{Menu-BVn1jh46.mjs → Menu-DQPxDJ11.mjs} +5 -5
  118. package/dist/{Menu-BVn1jh46.mjs.map → Menu-DQPxDJ11.mjs.map} +1 -1
  119. package/dist/Menu.d.mts +1 -1
  120. package/dist/{MiddleTruncatedText-DicQsLDG.mjs → MiddleTruncatedText--jzGTD00.mjs} +2 -2
  121. package/dist/{MiddleTruncatedText-DicQsLDG.mjs.map → MiddleTruncatedText--jzGTD00.mjs.map} +1 -1
  122. package/dist/{Modal-IVXc4p8Y.d.mts → Modal-7ZHanMzZ.d.mts} +3 -3
  123. package/dist/{Modal-C_vSgqgl.mjs → Modal-bsjGJxTM.mjs} +6 -6
  124. package/dist/{Modal-C_vSgqgl.mjs.map → Modal-bsjGJxTM.mjs.map} +1 -1
  125. package/dist/Modal.d.mts +1 -1
  126. package/dist/{PageHeader-UPiqJpIF.d.mts → PageHeader-BeBmYmUX.d.mts} +2 -2
  127. package/dist/{PageHeader-6KvtGED-.mjs → PageHeader-jvLx6GUu.mjs} +2 -2
  128. package/dist/{PageHeader-6KvtGED-.mjs.map → PageHeader-jvLx6GUu.mjs.map} +1 -1
  129. package/dist/PageHeader.d.mts +1 -1
  130. package/dist/{PageLayout-BdVM37bV.d.mts → PageLayout-BXM_pyrU.d.mts} +2 -2
  131. package/dist/{PageLayout-CPiVnS_r.mjs → PageLayout-D_NZNEit.mjs} +3 -3
  132. package/dist/{PageLayout-CPiVnS_r.mjs.map → PageLayout-D_NZNEit.mjs.map} +1 -1
  133. package/dist/PageLayout.d.mts +1 -1
  134. package/dist/{PageSelector-B5CcAzss.d.mts → PageSelector-C14ABZVL.d.mts} +2 -2
  135. package/dist/PageSelector.d.mts +1 -1
  136. package/dist/{Pagination-CqFvnlXc.mjs → Pagination-CgT2eQrk.mjs} +5 -5
  137. package/dist/{Pagination-CqFvnlXc.mjs.map → Pagination-CgT2eQrk.mjs.map} +1 -1
  138. package/dist/{Pii-BYPkrBuT.mjs → Pii-x1UInvWe.mjs} +2 -2
  139. package/dist/{Pii-BYPkrBuT.mjs.map → Pii-x1UInvWe.mjs.map} +1 -1
  140. package/dist/{PillShell-Bkyu5FXB.d.mts → PillShell-DuTRfsS1.d.mts} +2 -2
  141. package/dist/PillShell.d.mts +1 -1
  142. package/dist/{Popover-DP9DXReH.mjs → Popover-BMX-ff3L.mjs} +3 -3
  143. package/dist/{Popover-DP9DXReH.mjs.map → Popover-BMX-ff3L.mjs.map} +1 -1
  144. package/dist/Popover.d.mts +1 -1
  145. package/dist/ProgressBar.d.mts +1 -1
  146. package/dist/{ProgressIndicator-zt3ndT9U.mjs → ProgressIndicator-hy1P-RG1.mjs} +3 -3
  147. package/dist/{ProgressIndicator-zt3ndT9U.mjs.map → ProgressIndicator-hy1P-RG1.mjs.map} +1 -1
  148. package/dist/{Radio-B1H_S-Qj.mjs → Radio-D6Vydkx-.mjs} +5 -5
  149. package/dist/{Radio-B1H_S-Qj.mjs.map → Radio-D6Vydkx-.mjs.map} +1 -1
  150. package/dist/{RadioGroup-7hdcVhsp.mjs → RadioGroup-C04h3el1.mjs} +3 -3
  151. package/dist/{RadioGroup-7hdcVhsp.mjs.map → RadioGroup-C04h3el1.mjs.map} +1 -1
  152. package/dist/RichTextEditor.d.mts +1 -1
  153. package/dist/RuleEditorFields.d.mts +2 -2
  154. package/dist/RulesPill.d.mts +1 -1
  155. package/dist/SectionHeading.d.mts +1 -1
  156. package/dist/{SegmentedControl-BNOJ1FYQ.mjs → SegmentedControl-CaQ2DJsa.mjs} +4 -4
  157. package/dist/{SegmentedControl-BNOJ1FYQ.mjs.map → SegmentedControl-CaQ2DJsa.mjs.map} +1 -1
  158. package/dist/{Select-DbWEgH5c.mjs → Select-Bicuj8VD.mjs} +10 -10
  159. package/dist/{Select-DbWEgH5c.mjs.map → Select-Bicuj8VD.mjs.map} +1 -1
  160. package/dist/{Select-boZ6XP8k.d.mts → Select-O4aTrBuF.d.mts} +2 -2
  161. package/dist/Select.d.mts +1 -1
  162. package/dist/SmartTextInput.d.mts +1 -1
  163. package/dist/SmartTextInputField.d.mts +2 -2
  164. package/dist/SmartTextInputFunctionDialog.d.mts +1 -1
  165. package/dist/SmartTextInputPopover.d.mts +1 -1
  166. package/dist/{Spinner-k9ZiOdTr.mjs → Spinner-B8KWWUWy.mjs} +2 -2
  167. package/dist/{Spinner-k9ZiOdTr.mjs.map → Spinner-B8KWWUWy.mjs.map} +1 -1
  168. package/dist/{Stack-CODxfzhl.d.mts → Stack-B6MrjJeW.d.mts} +2 -2
  169. package/dist/Stack.d.mts +1 -1
  170. package/dist/{StatusIndicator-CzRaEFSz.mjs → StatusIndicator-lwt35J6B.mjs} +3 -3
  171. package/dist/{StatusIndicator-CzRaEFSz.mjs.map → StatusIndicator-lwt35J6B.mjs.map} +1 -1
  172. package/dist/{Sticker-CLvRB8V5.d.mts → Sticker-C7Wv3Obx.d.mts} +4 -4
  173. package/dist/{Sticker-4VdGEFAu.mjs → Sticker-jfOM4Yi6.mjs} +5 -5
  174. package/dist/{Sticker-4VdGEFAu.mjs.map → Sticker-jfOM4Yi6.mjs.map} +1 -1
  175. package/dist/Sticker.d.mts +1 -1
  176. package/dist/StringValueControl.d.mts +1 -1
  177. package/dist/Tab.d.mts +2 -2
  178. package/dist/{TabBar-d4sdknti.mjs → TabBar-B7U2uVD3.mjs} +6 -6
  179. package/dist/{TabBar-d4sdknti.mjs.map → TabBar-B7U2uVD3.mjs.map} +1 -1
  180. package/dist/{Table-9mNn8Q-d.mjs → Table-BsDubdR2.mjs} +10 -10
  181. package/dist/{Table-9mNn8Q-d.mjs.map → Table-BsDubdR2.mjs.map} +1 -1
  182. package/dist/{TableBox-RxpwflEb.mjs → TableBox-DmEfPlTG.mjs} +15 -15
  183. package/dist/{TableBox-RxpwflEb.mjs.map → TableBox-DmEfPlTG.mjs.map} +1 -1
  184. package/dist/TableBox.d.mts +1 -1
  185. package/dist/{TableBoxCell-B6Z23mby.d.mts → TableBoxCell-DiKY6wne.d.mts} +6 -6
  186. package/dist/TableBoxCell.d.mts +1 -1
  187. package/dist/{TableBoxField-6qAOW8t9.d.mts → TableBoxField-DPq_rueS.d.mts} +5 -5
  188. package/dist/TableBoxField.d.mts +1 -1
  189. package/dist/{TableBoxRow-CpgNWdLS.d.mts → TableBoxRow-B3DdXy6r.d.mts} +2 -2
  190. package/dist/TableBoxRow.d.mts +1 -1
  191. package/dist/{TableBoxRowActions-BDx5naRj.d.mts → TableBoxRowActions-BYXYa9s5.d.mts} +2 -2
  192. package/dist/TableBoxRowActions.d.mts +1 -1
  193. package/dist/{TableCell-CQsF7t4e.d.mts → TableCell-uv_jqT5e.d.mts} +2 -2
  194. package/dist/TableCell.d.mts +1 -1
  195. package/dist/{TableControls-BGKL7_zF.d.mts → TableControls-C4tMGBao.d.mts} +5 -5
  196. package/dist/{TableControls-BwZl4TjJ.mjs → TableControls-fuaMJFA6.mjs} +115 -41
  197. package/dist/TableControls-fuaMJFA6.mjs.map +1 -0
  198. package/dist/TableControls.d.mts +1 -1
  199. package/dist/{TableControlsContext-DhABbtVY.d.mts → TableControlsContext-D8UNXFkq.d.mts} +2 -2
  200. package/dist/TableControlsContext.d.mts +1 -1
  201. package/dist/{TableViewConfigurationDropdown-D76ApJ_-.d.mts → TableViewConfigurationDropdown-BlQj0RyT.d.mts} +2 -2
  202. package/dist/TableViewConfigurationDropdown.d.mts +1 -1
  203. package/dist/{TechnicalSticker-DtV7Gawf.mjs → TechnicalSticker--98wizQK.mjs} +7 -7
  204. package/dist/{TechnicalSticker-DtV7Gawf.mjs.map → TechnicalSticker--98wizQK.mjs.map} +1 -1
  205. package/dist/{Text-CvaqognH.d.mts → Text-CdHeSHCc.d.mts} +2 -2
  206. package/dist/Text.d.mts +1 -1
  207. package/dist/{TextArea-CQ1YNi2b.mjs → TextArea-BoVqMk8l.mjs} +2 -2
  208. package/dist/{TextArea-CQ1YNi2b.mjs.map → TextArea-BoVqMk8l.mjs.map} +1 -1
  209. package/dist/{TextUnderlineTooltip-Bd5e8KH3.d.mts → TextUnderlineTooltip-By1VVsSs.d.mts} +3 -3
  210. package/dist/TextUnderlineTooltip.d.mts +1 -1
  211. package/dist/Tile.d.mts +1 -1
  212. package/dist/{Toggle-CzHoIR-n.mjs → Toggle-BU7Faaud.mjs} +7 -7
  213. package/dist/{Toggle-CzHoIR-n.mjs.map → Toggle-BU7Faaud.mjs.map} +1 -1
  214. package/dist/{Tooltip-CVBxc1yf.mjs → Tooltip-C2VB8I6y.mjs} +4 -4
  215. package/dist/{Tooltip-CVBxc1yf.mjs.map → Tooltip-C2VB8I6y.mjs.map} +1 -1
  216. package/dist/{Tooltip-Ddy2Jq0K.d.mts → Tooltip-OxVvOfn8.d.mts} +3 -3
  217. package/dist/Tooltip.d.mts +1 -1
  218. package/dist/{TruncatedText-sr9Fhm3N.d.mts → TruncatedText-Dqj94BFK.d.mts} +2 -2
  219. package/dist/WizardModal.d.mts +1 -1
  220. package/dist/{clientFilterUtils-WH_Dqtv4.d.mts → clientFilterUtils-CI85xKUy.d.mts} +2 -2
  221. package/dist/clientFilterUtils.d.mts +1 -1
  222. package/dist/components/Accordion/index.mjs +5 -5
  223. package/dist/components/Attribute/index.mjs +6 -6
  224. package/dist/components/Badge/index.mjs +1 -1
  225. package/dist/components/Banner/index.mjs +3 -3
  226. package/dist/components/BottomPanel/index.mjs +7 -7
  227. package/dist/components/Breadcrumbs/index.mjs +1 -1
  228. package/dist/components/Button/index.d.mts +2 -2
  229. package/dist/components/Button/index.mjs +1 -1
  230. package/dist/components/ButtonGroup/index.mjs +3 -3
  231. package/dist/components/Card/index.d.mts +2 -2
  232. package/dist/components/CardV2/index.d.mts +1 -1
  233. package/dist/components/CardV2/index.mjs +1 -1
  234. package/dist/components/Checkbox/index.mjs +1 -1
  235. package/dist/components/CodeHighlight/index.mjs +4 -4
  236. package/dist/components/Combobox/index.d.mts +4 -4
  237. package/dist/components/Combobox/index.mjs +1 -1
  238. package/dist/components/ConfigFormGroup/index.mjs +2 -2
  239. package/dist/components/DataTable/TableControls/index.d.mts +20 -20
  240. package/dist/components/DataTable/TableControls/index.mjs +1 -1
  241. package/dist/components/DataTable/index.d.mts +5 -5
  242. package/dist/components/DataTable/index.mjs +1 -1
  243. package/dist/components/DataTable/types.d.mts +1 -1
  244. package/dist/components/DatePicker/index.mjs +1 -1
  245. package/dist/components/DropdownButton/index.mjs +1 -1
  246. package/dist/components/DropdownMenu/index.d.mts +1 -1
  247. package/dist/components/DropdownMenu/index.mjs +1 -1
  248. package/dist/components/FloatingPanel/index.mjs +7 -7
  249. package/dist/components/FloatingToolbar/index.mjs +1 -1
  250. package/dist/components/FormControl/index.d.mts +1 -1
  251. package/dist/components/FormControl/index.mjs +2 -2
  252. package/dist/components/FormField/index.d.mts +5 -5
  253. package/dist/components/FormField/index.mjs +1 -1
  254. package/dist/components/Grid/index.mjs +1 -1
  255. package/dist/components/HoverCopyableField/index.mjs +1 -1
  256. package/dist/components/ImageTile/index.mjs +8 -8
  257. package/dist/components/Input/index.d.mts +1 -1
  258. package/dist/components/Input/index.mjs +1 -1
  259. package/dist/components/Link/index.mjs +1 -1
  260. package/dist/components/ListBox/index.d.mts +3 -3
  261. package/dist/components/ListBox/index.mjs +1 -1
  262. package/dist/components/LoadingShimmer/index.mjs +1 -1
  263. package/dist/components/MaskedInput/index.mjs +1 -1
  264. package/dist/components/Menu/index.d.mts +1 -1
  265. package/dist/components/Menu/index.mjs +1 -1
  266. package/dist/components/Modal/index.d.mts +1 -1
  267. package/dist/components/Modal/index.mjs +1 -1
  268. package/dist/components/PageHeader/index.d.mts +1 -1
  269. package/dist/components/PageHeader/index.mjs +1 -1
  270. package/dist/components/Pagination/index.d.mts +1 -1
  271. package/dist/components/Pagination/index.mjs +1 -1
  272. package/dist/components/Pii/index.mjs +1 -1
  273. package/dist/components/Popover/index.mjs +1 -1
  274. package/dist/components/ProgressBar/index.mjs +2 -2
  275. package/dist/components/ProgressIndicator/index.mjs +1 -1
  276. package/dist/components/Radio/index.mjs +1 -1
  277. package/dist/components/RadioGroup/index.mjs +1 -1
  278. package/dist/components/RichTextEditor/index.mjs +10 -10
  279. package/dist/components/RightPanel/index.mjs +4 -4
  280. package/dist/components/SegmentedControl/index.mjs +1 -1
  281. package/dist/components/Select/index.d.mts +1 -1
  282. package/dist/components/Select/index.mjs +1 -1
  283. package/dist/components/SelectionCard/index.mjs +6 -6
  284. package/dist/components/Slider/index.mjs +4 -4
  285. package/dist/components/SmartTextInput/index.mjs +18 -14
  286. package/dist/components/SmartTextInput/index.mjs.map +1 -1
  287. package/dist/components/Spinner/index.mjs +1 -1
  288. package/dist/components/Stack/index.d.mts +1 -1
  289. package/dist/components/StatusIndicator/index.mjs +1 -1
  290. package/dist/components/Sticker/index.d.mts +1 -1
  291. package/dist/components/Sticker/index.mjs +1 -1
  292. package/dist/components/SwatchPicker/index.mjs +1 -1
  293. package/dist/components/TabBar/index.mjs +1 -1
  294. package/dist/components/Table/index.d.mts +1 -1
  295. package/dist/components/Table/index.mjs +1 -1
  296. package/dist/components/TableBox/index.d.mts +1 -1
  297. package/dist/components/TableBox/index.mjs +1 -1
  298. package/dist/components/TechnicalSticker/index.mjs +1 -1
  299. package/dist/components/Text/index.d.mts +1 -1
  300. package/dist/components/TextArea/index.mjs +1 -1
  301. package/dist/components/Tile/index.mjs +2 -2
  302. package/dist/components/Toast/index.mjs +4 -4
  303. package/dist/components/Toggle/index.mjs +1 -1
  304. package/dist/components/Tooltip/index.d.mts +3 -3
  305. package/dist/components/Tooltip/index.mjs +1 -1
  306. package/dist/components/VersionHistory/index.mjs +8 -8
  307. package/dist/compound-expression.d.mts +1 -1
  308. package/dist/{date-range-rule-value-DyLlMtjr.d.mts → date-range-rule-value-DY14Qlan.d.mts} +2 -2
  309. package/dist/date-range-rule-value.d.mts +1 -1
  310. package/dist/display.d.mts +1 -1
  311. package/dist/fieldPickerOptions.d.mts +2 -2
  312. package/dist/{filter-size-context-DVnjmuhk.d.mts → filter-size-context-BaFrCH_G.d.mts} +2 -2
  313. package/dist/filter-size-context.d.mts +1 -1
  314. package/dist/{filters-BXtKuft3.d.mts → filters-oNzv_Y5o.d.mts} +3 -3
  315. package/dist/filters.d.mts +1 -1
  316. package/dist/{helpers-gpO42h8t.d.mts → helpers-Cvy93JmP.d.mts} +2 -2
  317. package/dist/helpers.d.mts +1 -1
  318. package/dist/{index-DTM_t7OG.d.mts → index-Dh3UpnW5.d.mts} +2 -2
  319. package/dist/{index-bkzLg85W.d.mts → index-_ubFQdZK.d.mts} +3 -3
  320. package/dist/index2.d.mts +1 -1
  321. package/dist/index4.d.mts +3 -3
  322. package/dist/index5.d.mts +1 -1
  323. package/dist/index6.d.mts +13 -13
  324. package/dist/{inputFields-B7parF2l.d.mts → inputFields-CxgQOm9E.d.mts} +6 -6
  325. package/dist/inputFields.d.mts +1 -1
  326. package/dist/{intersperse-DvJsBw5D.mjs → intersperse--nD7mQCo.mjs} +1 -1
  327. package/dist/{intersperse-DvJsBw5D.mjs.map → intersperse--nD7mQCo.mjs.map} +1 -1
  328. package/dist/lib/MiddleTruncatedText.mjs +1 -1
  329. package/dist/lib/TruncatedText.d.mts +1 -1
  330. package/dist/lib/TruncatedTextWithTooltip.d.mts +1 -1
  331. package/dist/lib/TruncatedTextWithTooltip.mjs +1 -1
  332. package/dist/lib/colorMode.d.mts +1 -1
  333. package/dist/lib/useChain.d.mts +1 -1
  334. package/dist/mixins/focus.mjs +1 -1
  335. package/dist/mixins/hoverable.mjs +1 -1
  336. package/dist/mixins/input.mjs +2 -2
  337. package/dist/mixins/motion.mjs +1 -1
  338. package/dist/{operators-B8_k3r69.d.mts → operators-B8fgw6F_.d.mts} +2 -2
  339. package/dist/operators.d.mts +1 -1
  340. package/dist/patterns/CardGrouping/index.mjs +8 -8
  341. package/dist/patterns/IndexTableLayout/index.mjs +3 -3
  342. package/dist/patterns/LayoutLoadingShimmer/index.mjs +4 -4
  343. package/dist/patterns/LayoutLoadingSpinner/index.mjs +1 -1
  344. package/dist/patterns/PageLayout/index.d.mts +1 -1
  345. package/dist/patterns/PageLayout/index.mjs +1 -1
  346. package/dist/patterns/WizardModal/index.mjs +4 -4
  347. package/dist/relative-date-label.d.mts +1 -1
  348. package/dist/tone.d.mts +1 -1
  349. package/dist/{types-BvaXqjUm.d.mts → types-BwbQx3-v.d.mts} +2 -2
  350. package/dist/{types-BJqmRXFV.d.mts → types-CnqmdPXi.d.mts} +3 -2
  351. package/dist/{types-BOsCi-kZ.d.mts → types-Dl-tYxwE.d.mts} +2 -2
  352. package/dist/{types-CuH-sUJ2.d.mts → types-hhfBHo97.d.mts} +3 -3
  353. package/dist/types4.d.mts +1 -1
  354. package/dist/types5.d.mts +1 -1
  355. package/dist/types6.d.mts +1 -1
  356. package/dist/{url-state-CXPmXzIZ.d.mts → url-state-B5TJ9RJF.d.mts} +2 -2
  357. package/dist/url-state.d.mts +1 -1
  358. package/dist/{useChain-B--KAtdN.d.mts → useChain-x9fd9Fyq.d.mts} +2 -2
  359. package/dist/useChainAtCursor.d.mts +1 -1
  360. package/dist/useColumnConfiguration.d.mts +2 -2
  361. package/dist/useComboboxFooterAction.d.mts +1 -1
  362. package/dist/{useFilterStateV2-DiTS9DTg.d.mts → useFilterStateV2-Bo5NcLC9.d.mts} +3 -3
  363. package/dist/useFilterStateV2.d.mts +1 -1
  364. package/dist/{useFormField-pOVkb5BK.mjs → useFormField-Cd9sH-HM.mjs} +2 -2
  365. package/dist/{useFormField-pOVkb5BK.mjs.map → useFormField-Cd9sH-HM.mjs.map} +1 -1
  366. package/dist/{useFormGroup-DSQkoWLh.mjs → useFormGroup-CerJGY6Y.mjs} +1 -1
  367. package/dist/{useFormGroup-DSQkoWLh.mjs.map → useFormGroup-CerJGY6Y.mjs.map} +1 -1
  368. package/dist/{useTableColumns-I7StvoRs.d.mts → useTableColumns-D80uOKnT.d.mts} +2 -2
  369. package/dist/useTableColumns.d.mts +1 -1
  370. package/dist/useTruncation.d.mts +1 -1
  371. package/dist/utils.d.mts +1 -1
  372. package/dist/{validation-BDQdQ1cY.d.mts → validation-lepFD1Fr.d.mts} +3 -3
  373. package/dist/validation.d.mts +1 -1
  374. package/dist/{value-control-resolver-BFJZEWDn.d.mts → value-control-resolver-Dhmspfw-.d.mts} +2 -2
  375. package/dist/value-control-resolver.d.mts +1 -1
  376. package/dist/value-labels.d.mts +1 -1
  377. package/llms.txt +1 -1
  378. package/package.json +1 -1
  379. package/skills/ui-authoring/COMPONENTS.md +4 -1
  380. package/dist/Combobox-DmFQ5cAy.mjs.map +0 -1
  381. package/dist/TableControls-BwZl4TjJ.mjs.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"Pii-BYPkrBuT.mjs","names":[],"sources":["../src/components/Pii/Pii.tsx","../src/components/Pii/index.ts"],"sourcesContent":["import type { ReactNode } from 'react';\n\nimport Sticker from '@persona/design-system/components/Sticker';\n\ninterface PiiProps {\n children?: ReactNode;\n isRedacted: boolean;\n hideOnRedacted?: boolean;\n}\n\nconst Pii = ({ children, isRedacted, hideOnRedacted }: PiiProps) => {\n if (isRedacted) {\n return hideOnRedacted ? null : <Sticker data-test='pii__redacted'>Redacted</Sticker>;\n }\n\n if (children == null || children === '') {\n return null;\n }\n\n // There used to be code inserting a classname here in certain cases. There's\n // no other reason for this to be conditionally wrapped in a span, but\n // removing it breaks a lot of tests. Someday, the tests will be fixed...\n // hopefully.\n if (['string', 'number'].includes(typeof children)) {\n return <span>{children}</span>;\n }\n\n return <>{children}</>;\n};\n\nexport default Pii;\n","import Pii from './Pii';\n\nexport default Pii;\n"],"mappings":";;;AAUA,MAAM,OAAO,EAAE,UAAU,YAAY,qBAA+B;AAClE,KAAI,WACF,QAAO,iBAAiB,OAAO,oBAAC,SAAD;EAAS,aAAU;YAAgB;EAAkB,CAAA;AAGtF,KAAI,YAAY,QAAQ,aAAa,GACnC,QAAO;AAOT,KAAI,CAAC,UAAU,SAAS,CAAC,SAAS,OAAO,SAAS,CAChD,QAAO,oBAAC,QAAD,EAAO,UAAgB,CAAA;AAGhC,QAAO,oBAAA,UAAA,EAAG,UAAY,CAAA;;;;ACzBxB,IAAA,cAAe"}
1
+ {"version":3,"file":"Pii-x1UInvWe.mjs","names":[],"sources":["../src/components/Pii/Pii.tsx","../src/components/Pii/index.ts"],"sourcesContent":["import type { ReactNode } from 'react';\n\nimport Sticker from '@persona/design-system/components/Sticker';\n\ninterface PiiProps {\n children?: ReactNode;\n isRedacted: boolean;\n hideOnRedacted?: boolean;\n}\n\nconst Pii = ({ children, isRedacted, hideOnRedacted }: PiiProps) => {\n if (isRedacted) {\n return hideOnRedacted ? null : <Sticker data-test='pii__redacted'>Redacted</Sticker>;\n }\n\n if (children == null || children === '') {\n return null;\n }\n\n // There used to be code inserting a classname here in certain cases. There's\n // no other reason for this to be conditionally wrapped in a span, but\n // removing it breaks a lot of tests. Someday, the tests will be fixed...\n // hopefully.\n if (['string', 'number'].includes(typeof children)) {\n return <span>{children}</span>;\n }\n\n return <>{children}</>;\n};\n\nexport default Pii;\n","import Pii from './Pii';\n\nexport default Pii;\n"],"mappings":";;;AAUA,MAAM,OAAO,EAAE,UAAU,YAAY,qBAA+B;AAClE,KAAI,WACF,QAAO,iBAAiB,OAAO,oBAAC,SAAD;EAAS,aAAU;YAAgB;EAAkB,CAAA;AAGtF,KAAI,YAAY,QAAQ,aAAa,GACnC,QAAO;AAOT,KAAI,CAAC,UAAU,SAAS,CAAC,SAAS,OAAO,SAAS,CAChD,QAAO,oBAAC,QAAD,EAAO,UAAgB,CAAA;AAGhC,QAAO,oBAAA,UAAA,EAAG,UAAY,CAAA;;;;ACzBxB,IAAA,cAAe"}
@@ -1,4 +1,4 @@
1
- import { p as FilterSize } from "./types-BJqmRXFV.mjs";
1
+ import { p as FilterSize } from "./types-CnqmdPXi.mjs";
2
2
  import * as _$react from "react";
3
3
  import { HTMLAttributes, ReactNode } from "react";
4
4
 
@@ -82,4 +82,4 @@ interface PillShellProps extends Omit<HTMLAttributes<HTMLSpanElement>, 'onClick'
82
82
  declare const PillShell: _$react.ForwardRefExoticComponent<PillShellProps & _$react.RefAttributes<HTMLSpanElement>>;
83
83
  //#endregion
84
84
  export { PillShellProps as n, PillShell as t };
85
- //# sourceMappingURL=PillShell-Bkyu5FXB.d.mts.map
85
+ //# sourceMappingURL=PillShell-DuTRfsS1.d.mts.map
@@ -1,2 +1,2 @@
1
- import { n as PillShellProps, t as PillShell } from "./PillShell-Bkyu5FXB.mjs";
1
+ import { n as PillShellProps, t as PillShell } from "./PillShell-DuTRfsS1.mjs";
2
2
  export { PillShellProps, PillShell as default };
@@ -1,11 +1,11 @@
1
1
  import { a as styled, r as css } from "./styledComponentsInterop-Cs5CCPRy.mjs";
2
2
  import { semanticOnly } from "./lib/semanticColor.mjs";
3
+ import { popoverMotion } from "./mixins/motion.mjs";
4
+ import { semanticScrollbar } from "./mixins/scrollbar.mjs";
3
5
  import { t as Card_default } from "./Card-DuQHyroh.mjs";
4
6
  import { i as Paragraph } from "./Text-D0vEReED.mjs";
5
7
  import { letPointerDownReachDocument } from "./lib/letPointerDownReachDocument.mjs";
6
8
  import { mergeRefs, useCloseFocus } from "./lib/useCloseFocus.mjs";
7
- import { popoverMotion } from "./mixins/motion.mjs";
8
- import { semanticScrollbar } from "./mixins/scrollbar.mjs";
9
9
  import { Children, cloneElement, createContext, forwardRef, isValidElement, useContext, useMemo, useRef } from "react";
10
10
  import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
11
11
  import { XIcon } from "@persona/icons";
@@ -168,4 +168,4 @@ var Popover_default = Object.assign(Popover, {
168
168
  //#endregion
169
169
  export { PopoverPortal as a, PopoverContent as i, PopoverCard as n, PopoverTrigger as o, PopoverClose as r, Popover_default as s, PopoverAnchor as t };
170
170
 
171
- //# sourceMappingURL=Popover-DP9DXReH.mjs.map
171
+ //# sourceMappingURL=Popover-BMX-ff3L.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"Popover-DP9DXReH.mjs","names":["Card"],"sources":["../src/components/Popover/Popover.tsx"],"sourcesContent":["import * as PopoverPrimitive from '@radix-ui/react-popover';\nimport {\n Children,\n cloneElement,\n createContext,\n forwardRef,\n isValidElement,\n type ReactElement,\n type RefObject,\n useContext,\n useMemo,\n useRef,\n} from 'react';\nimport styled, { css } from 'styled-components';\n\nimport type { Spacing } from '@persona/design-tokens';\nimport { XIcon } from '@persona/icons';\n\nimport Card from '#src/components/Card';\nimport { Paragraph } from '#src/components/Text';\nimport { letPointerDownReachDocument } from '#src/lib/letPointerDownReachDocument';\nimport { semanticOnly } from '#src/lib/semanticColor';\nimport { mergeRefs, useCloseFocus } from '#src/lib/useCloseFocus';\nimport { popoverMotion } from '#src/mixins/motion';\nimport { semanticScrollbar } from '#src/mixins/scrollbar';\n\nexport const PopoverTrigger = PopoverPrimitive.Trigger;\nexport const PopoverAnchor = PopoverPrimitive.Anchor;\nexport const PopoverPortal = PopoverPrimitive.Portal;\n\nconst PopoverRootContext = createContext<{\n modal?: boolean;\n triggerRef?: RefObject<HTMLElement | null>;\n}>({});\n\nexport const PopoverContent = forwardRef<\n React.ElementRef<typeof PopoverPrimitive.Content>,\n PopoverPrimitive.PopoverContentProps\n>(function PopoverContent(\n {\n onPointerDownCapture,\n onCloseAutoFocus,\n onOpenAutoFocus,\n onInteractOutside,\n onEscapeKeyDown,\n ...props\n },\n ref,\n) {\n const { modal, triggerRef } = useContext(PopoverRootContext);\n const { ref: closeFocusRef, ...closeFocus } = useCloseFocus({\n onCloseAutoFocus,\n onOpenAutoFocus,\n onInteractOutside,\n onEscapeKeyDown,\n modal,\n triggerRef,\n });\n const mergedRef = useMemo(() => mergeRefs(ref, closeFocusRef), [ref, closeFocusRef]);\n return (\n <PopoverPrimitive.Content\n {...props}\n {...closeFocus}\n onOpenAutoFocus={onOpenAutoFocus}\n ref={mergedRef}\n onPointerDownCapture={(event) => {\n onPointerDownCapture?.(event);\n letPointerDownReachDocument(event);\n }}\n />\n );\n});\n\nconst PopoverContentStyled = styled(PopoverContent)<{ zIndex?: number; $maxHeight?: string }>`\n ${popoverMotion('--radix-popover-content-transform-origin')}\n z-index: ${({ zIndex }) => zIndex || 'inherit'};\n ${({ $maxHeight }) =>\n $maxHeight &&\n css`\n max-height: ${$maxHeight};\n overflow: auto;\n ${semanticScrollbar}\n `}\n`;\n\nconst PopoverCloseButton = styled(PopoverPrimitive.Close)<{ isHeader?: boolean }>`\n ${({ isHeader }) =>\n !isHeader &&\n css`\n position: absolute;\n top: 8px;\n right: 8px;\n `}\n ${({ isHeader }) =>\n isHeader &&\n css`\n height: 16px;\n `}\n background: transparent;\n border: 0;\n cursor: pointer;\n`;\n\nconst PopoverPanel = styled(Card)`\n ${semanticOnly((tokens) => `background-color: ${tokens.SurfaceElevated};`)}\n`;\n\nconst HeadingContainer = styled.div`\n display: flex;\n align-items: center;\n justify-content: space-between;\n`;\n\nexport const PopoverClose = (\n props: PopoverPrimitive.PopoverCloseProps & { isHeader?: boolean },\n) => {\n return (\n <PopoverCloseButton {...props}>\n <XIcon />\n </PopoverCloseButton>\n );\n};\n\nexport interface PopoverCardProps extends PopoverPrimitive.PopoverContentProps {\n /**\n * Display X button to close popover\n */\n showCloseButton?: boolean;\n\n /**\n * Remove padding from Card\n */\n noPadding?: boolean;\n\n padding?: Spacing;\n\n /**\n * Text to display in the header of the card\n */\n heading?: string;\n\n /**\n * Z-index to apply to the popover content\n */\n zIndex?: number;\n\n /**\n * Maximum height for the popover content.\n */\n maxHeight?: string;\n}\n\n/**\n * Card to be used in Popover contexts. Inherits props from Radix UI Popper.Content.\n */\nexport const PopoverCard = forwardRef<\n React.ElementRef<typeof PopoverPrimitive.Content>,\n PopoverCardProps\n>(function PopoverCard(\n { children, showCloseButton, heading, noPadding, padding, zIndex, maxHeight, ...props },\n ref,\n) {\n const header = heading && (\n <HeadingContainer>\n <Paragraph size='md' weight='bold' color='primary'>\n {heading}\n </Paragraph>\n {showCloseButton && <PopoverClose aria-label='Close' isHeader />}\n </HeadingContainer>\n );\n return (\n <PopoverContentStyled\n asChild\n sideOffset={8}\n collisionPadding={8}\n zIndex={zIndex}\n $maxHeight={maxHeight}\n {...props}\n ref={ref}\n >\n <PopoverPanel elevated>\n {!heading && showCloseButton && <PopoverClose aria-label='Close' />}\n {noPadding ? (\n <>\n {heading && header}\n {children}\n </>\n ) : (\n <Card.Body padding={padding}>\n {heading && header}\n {children}\n </Card.Body>\n )}\n </PopoverPanel>\n </PopoverContentStyled>\n );\n});\n\ninterface PopoverProps extends PopoverPrimitive.PopoverProps {\n /**\n * Component to use as trigger. Radix UI trigger component props will be merged with this element.\n */\n trigger?: ReactElement;\n\n /**\n * Props to apply to Popover.Trigger within\n */\n triggerProps?: PopoverPrimitive.PopoverTriggerProps;\n\n /**\n * An optional element to position the Popover.Content against.\n * If this part is not used, the content will position alongside the trigger.\n */\n anchor?: ReactElement<PopoverPrimitive.PopoverAnchorProps>;\n\n /**\n * Props to apply to Popover.Card within\n */\n contentProps?: PopoverCardProps;\n\n /**\n * Render content within a portal\n */\n portal?: boolean;\n\n /**\n * Props applied to Radix UI Portal component\n */\n portalProps?: PopoverPrimitive.PopoverPortalProps;\n}\n\nconst Popover = ({\n children,\n trigger,\n triggerProps,\n contentProps,\n anchor,\n portal = true,\n portalProps,\n ...props\n}: PopoverProps) => {\n let triggerElem;\n let contentElem;\n let anchorElem = anchor;\n\n const renderChildren = Children.toArray(children).filter((child) => {\n if (isValidElement(child)) {\n switch (child.type) {\n case PopoverPrimitive.Trigger:\n triggerElem = child;\n return false;\n case PopoverCard:\n case PopoverContent:\n case PopoverPrimitive.Content:\n contentElem = child;\n break;\n case PopoverPrimitive.Anchor:\n /* @ts-expect-error [strict-migration] The following line is not strict; please fix! */\n anchorElem = child;\n return false;\n }\n }\n\n return true;\n });\n\n const content = contentElem || <PopoverCard {...contentProps}>{renderChildren}</PopoverCard>;\n const triggerRef = useRef<HTMLButtonElement>(null);\n const rootContext = useMemo(() => ({ modal: props.modal, triggerRef }), [props.modal]);\n const ownTrigger: ReactElement | undefined = triggerElem;\n const ownTriggerRef = (ownTrigger as { ref?: React.Ref<HTMLElement> } | undefined)?.ref;\n const ownTriggerMergedRef = useMemo(() => mergeRefs(ownTriggerRef, triggerRef), [ownTriggerRef]);\n const triggerPropsRef = (triggerProps as { ref?: React.Ref<HTMLButtonElement> } | undefined)?.ref;\n const triggerMergedRef = useMemo(() => mergeRefs(triggerPropsRef, triggerRef), [triggerPropsRef]);\n\n return (\n <PopoverRootContext.Provider value={rootContext}>\n <PopoverPrimitive.Root {...props}>\n {ownTrigger\n ? cloneElement(ownTrigger, { ref: ownTriggerMergedRef })\n : trigger && (\n <PopoverTrigger asChild {...triggerProps} ref={triggerMergedRef}>\n {trigger}\n </PopoverTrigger>\n )}\n {anchorElem}\n {portal ? <PopoverPortal {...portalProps}>{content}</PopoverPortal> : content}\n </PopoverPrimitive.Root>\n </PopoverRootContext.Provider>\n );\n};\n\nexport default Object.assign(Popover, {\n Trigger: PopoverTrigger,\n Anchor: PopoverAnchor,\n Portal: PopoverPortal,\n Content: PopoverContent,\n Card: PopoverCard,\n Close: PopoverClose,\n});\n"],"mappings":";;;;;;;;;;;;;AA0BA,MAAa,iBAAiB,iBAAiB;AAC/C,MAAa,gBAAgB,iBAAiB;AAC9C,MAAa,gBAAgB,iBAAiB;AAE9C,MAAM,qBAAqB,cAGxB,EAAE,CAAC;AAEN,MAAa,iBAAiB,WAG5B,SAAS,eACT,EACE,sBACA,kBACA,iBACA,mBACA,iBACA,GAAG,SAEL,KACA;CACA,MAAM,EAAE,OAAO,eAAe,WAAW,mBAAmB;CAC5D,MAAM,EAAE,KAAK,eAAe,GAAG,eAAe,cAAc;EAC1D;EACA;EACA;EACA;EACA;EACA;EACD,CAAC;CACF,MAAM,YAAY,cAAc,UAAU,KAAK,cAAc,EAAE,CAAC,KAAK,cAAc,CAAC;AACpF,QACE,oBAAC,iBAAiB,SAAlB;EACE,GAAI;EACJ,GAAI;EACa;EACjB,KAAK;EACL,uBAAuB,UAAU;AAC/B,0BAAuB,MAAM;AAC7B,+BAA4B,MAAM;;EAEpC,CAAA;EAEJ;AAEF,MAAM,uBAAuB,OAAO,eAAe;IAC/C,cAAc,2CAA2C,CAAC;cAChD,EAAE,aAAa,UAAU,UAAU;KAC5C,EAAE,iBACH,cACA,GAAG;oBACa,WAAW;;QAEvB,kBAAkB;MACpB;;AAGN,MAAM,qBAAqB,OAAO,iBAAiB,MAAM;KACpD,EAAE,eACH,CAAC,YACD,GAAG;;;;MAID;KACD,EAAE,eAC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Ac;AACd;GACF,KAAK,iBAAiB;AAEpB,iBAAa;AACb,WAAO;;AAIb,SAAO;GACP;CAEF,MAAM,UAAU,eAAe,oBAAC,aAAD;EAAa,GAAI;YAAe;EAA6B,CAAA;CAC5F,MAAM,aAAa,OAA0B,KAAK;CAClD,MAAM,cAAc,eAAe;EAAE,OAAO,MAAM;EAAO;EAAY,GAAG,CAAC,MAAM,MAAM,CAAC;CACtF,MAAM,aAAuC;CAC7C,MAAM,gBAAiB,YAA6D;CACpF,MAAM,sBAAsB,cAAc,UAAU,eAAe,WAAW,EAAE,CAAC,cAAc,CAAC;CAChG,MAAM,kBAAmB,cAAqE;CAC9F,MAAM,mBAAmB,cAAc,UAAU,iBAAiB,WAAW,EAAE,CAAC,gBAAgB,CAAC;AAEjG,QACE,oBAAC,mBAAmB,UAApB;EAA6B,OAAO;YAClC,qBAAC,iBAAiB,MAAlB;GAAuB,GAAI;aAA3B;IACG,aACG,aAAa,YAAY,EAAE,KAAK,qBAAqB,CAAC,GACtD,WACE,oBAAC,gBAAD;KAAgB,SAAA;KAAQ,GAAI;KAAc,KAAK;eAC5C;KACc,CAAA;IAEtB;IACA,SAAS,oBAAC,eAAD;KAAe,GAAI;eAAc;KAAwB,CAAA,GAAG;IAChD;;EACI,CAAA;;AAIlC,IAAA,kBAAe,OAAO,OAAO,SAAS;CACpC,SAAS;CACT,QAAQ;CACR,QAAQ;CACR,SAAS;CACT,MAAM;CACN,OAAO;CACR,CAAC"}
1
+ {"version":3,"file":"Popover-BMX-ff3L.mjs","names":["Card"],"sources":["../src/components/Popover/Popover.tsx"],"sourcesContent":["import * as PopoverPrimitive from '@radix-ui/react-popover';\nimport {\n Children,\n cloneElement,\n createContext,\n forwardRef,\n isValidElement,\n type ReactElement,\n type RefObject,\n useContext,\n useMemo,\n useRef,\n} from 'react';\nimport styled, { css } from 'styled-components';\n\nimport type { Spacing } from '@persona/design-tokens';\nimport { XIcon } from '@persona/icons';\n\nimport Card from '#src/components/Card';\nimport { Paragraph } from '#src/components/Text';\nimport { letPointerDownReachDocument } from '#src/lib/letPointerDownReachDocument';\nimport { semanticOnly } from '#src/lib/semanticColor';\nimport { mergeRefs, useCloseFocus } from '#src/lib/useCloseFocus';\nimport { popoverMotion } from '#src/mixins/motion';\nimport { semanticScrollbar } from '#src/mixins/scrollbar';\n\nexport const PopoverTrigger = PopoverPrimitive.Trigger;\nexport const PopoverAnchor = PopoverPrimitive.Anchor;\nexport const PopoverPortal = PopoverPrimitive.Portal;\n\nconst PopoverRootContext = createContext<{\n modal?: boolean;\n triggerRef?: RefObject<HTMLElement | null>;\n}>({});\n\nexport const PopoverContent = forwardRef<\n React.ElementRef<typeof PopoverPrimitive.Content>,\n PopoverPrimitive.PopoverContentProps\n>(function PopoverContent(\n {\n onPointerDownCapture,\n onCloseAutoFocus,\n onOpenAutoFocus,\n onInteractOutside,\n onEscapeKeyDown,\n ...props\n },\n ref,\n) {\n const { modal, triggerRef } = useContext(PopoverRootContext);\n const { ref: closeFocusRef, ...closeFocus } = useCloseFocus({\n onCloseAutoFocus,\n onOpenAutoFocus,\n onInteractOutside,\n onEscapeKeyDown,\n modal,\n triggerRef,\n });\n const mergedRef = useMemo(() => mergeRefs(ref, closeFocusRef), [ref, closeFocusRef]);\n return (\n <PopoverPrimitive.Content\n {...props}\n {...closeFocus}\n onOpenAutoFocus={onOpenAutoFocus}\n ref={mergedRef}\n onPointerDownCapture={(event) => {\n onPointerDownCapture?.(event);\n letPointerDownReachDocument(event);\n }}\n />\n );\n});\n\nconst PopoverContentStyled = styled(PopoverContent)<{ zIndex?: number; $maxHeight?: string }>`\n ${popoverMotion('--radix-popover-content-transform-origin')}\n z-index: ${({ zIndex }) => zIndex || 'inherit'};\n ${({ $maxHeight }) =>\n $maxHeight &&\n css`\n max-height: ${$maxHeight};\n overflow: auto;\n ${semanticScrollbar}\n `}\n`;\n\nconst PopoverCloseButton = styled(PopoverPrimitive.Close)<{ isHeader?: boolean }>`\n ${({ isHeader }) =>\n !isHeader &&\n css`\n position: absolute;\n top: 8px;\n right: 8px;\n `}\n ${({ isHeader }) =>\n isHeader &&\n css`\n height: 16px;\n `}\n background: transparent;\n border: 0;\n cursor: pointer;\n`;\n\nconst PopoverPanel = styled(Card)`\n ${semanticOnly((tokens) => `background-color: ${tokens.SurfaceElevated};`)}\n`;\n\nconst HeadingContainer = styled.div`\n display: flex;\n align-items: center;\n justify-content: space-between;\n`;\n\nexport const PopoverClose = (\n props: PopoverPrimitive.PopoverCloseProps & { isHeader?: boolean },\n) => {\n return (\n <PopoverCloseButton {...props}>\n <XIcon />\n </PopoverCloseButton>\n );\n};\n\nexport interface PopoverCardProps extends PopoverPrimitive.PopoverContentProps {\n /**\n * Display X button to close popover\n */\n showCloseButton?: boolean;\n\n /**\n * Remove padding from Card\n */\n noPadding?: boolean;\n\n padding?: Spacing;\n\n /**\n * Text to display in the header of the card\n */\n heading?: string;\n\n /**\n * Z-index to apply to the popover content\n */\n zIndex?: number;\n\n /**\n * Maximum height for the popover content.\n */\n maxHeight?: string;\n}\n\n/**\n * Card to be used in Popover contexts. Inherits props from Radix UI Popper.Content.\n */\nexport const PopoverCard = forwardRef<\n React.ElementRef<typeof PopoverPrimitive.Content>,\n PopoverCardProps\n>(function PopoverCard(\n { children, showCloseButton, heading, noPadding, padding, zIndex, maxHeight, ...props },\n ref,\n) {\n const header = heading && (\n <HeadingContainer>\n <Paragraph size='md' weight='bold' color='primary'>\n {heading}\n </Paragraph>\n {showCloseButton && <PopoverClose aria-label='Close' isHeader />}\n </HeadingContainer>\n );\n return (\n <PopoverContentStyled\n asChild\n sideOffset={8}\n collisionPadding={8}\n zIndex={zIndex}\n $maxHeight={maxHeight}\n {...props}\n ref={ref}\n >\n <PopoverPanel elevated>\n {!heading && showCloseButton && <PopoverClose aria-label='Close' />}\n {noPadding ? (\n <>\n {heading && header}\n {children}\n </>\n ) : (\n <Card.Body padding={padding}>\n {heading && header}\n {children}\n </Card.Body>\n )}\n </PopoverPanel>\n </PopoverContentStyled>\n );\n});\n\ninterface PopoverProps extends PopoverPrimitive.PopoverProps {\n /**\n * Component to use as trigger. Radix UI trigger component props will be merged with this element.\n */\n trigger?: ReactElement;\n\n /**\n * Props to apply to Popover.Trigger within\n */\n triggerProps?: PopoverPrimitive.PopoverTriggerProps;\n\n /**\n * An optional element to position the Popover.Content against.\n * If this part is not used, the content will position alongside the trigger.\n */\n anchor?: ReactElement<PopoverPrimitive.PopoverAnchorProps>;\n\n /**\n * Props to apply to Popover.Card within\n */\n contentProps?: PopoverCardProps;\n\n /**\n * Render content within a portal\n */\n portal?: boolean;\n\n /**\n * Props applied to Radix UI Portal component\n */\n portalProps?: PopoverPrimitive.PopoverPortalProps;\n}\n\nconst Popover = ({\n children,\n trigger,\n triggerProps,\n contentProps,\n anchor,\n portal = true,\n portalProps,\n ...props\n}: PopoverProps) => {\n let triggerElem;\n let contentElem;\n let anchorElem = anchor;\n\n const renderChildren = Children.toArray(children).filter((child) => {\n if (isValidElement(child)) {\n switch (child.type) {\n case PopoverPrimitive.Trigger:\n triggerElem = child;\n return false;\n case PopoverCard:\n case PopoverContent:\n case PopoverPrimitive.Content:\n contentElem = child;\n break;\n case PopoverPrimitive.Anchor:\n /* @ts-expect-error [strict-migration] The following line is not strict; please fix! */\n anchorElem = child;\n return false;\n }\n }\n\n return true;\n });\n\n const content = contentElem || <PopoverCard {...contentProps}>{renderChildren}</PopoverCard>;\n const triggerRef = useRef<HTMLButtonElement>(null);\n const rootContext = useMemo(() => ({ modal: props.modal, triggerRef }), [props.modal]);\n const ownTrigger: ReactElement | undefined = triggerElem;\n const ownTriggerRef = (ownTrigger as { ref?: React.Ref<HTMLElement> } | undefined)?.ref;\n const ownTriggerMergedRef = useMemo(() => mergeRefs(ownTriggerRef, triggerRef), [ownTriggerRef]);\n const triggerPropsRef = (triggerProps as { ref?: React.Ref<HTMLButtonElement> } | undefined)?.ref;\n const triggerMergedRef = useMemo(() => mergeRefs(triggerPropsRef, triggerRef), [triggerPropsRef]);\n\n return (\n <PopoverRootContext.Provider value={rootContext}>\n <PopoverPrimitive.Root {...props}>\n {ownTrigger\n ? cloneElement(ownTrigger, { ref: ownTriggerMergedRef })\n : trigger && (\n <PopoverTrigger asChild {...triggerProps} ref={triggerMergedRef}>\n {trigger}\n </PopoverTrigger>\n )}\n {anchorElem}\n {portal ? <PopoverPortal {...portalProps}>{content}</PopoverPortal> : content}\n </PopoverPrimitive.Root>\n </PopoverRootContext.Provider>\n );\n};\n\nexport default Object.assign(Popover, {\n Trigger: PopoverTrigger,\n Anchor: PopoverAnchor,\n Portal: PopoverPortal,\n Content: PopoverContent,\n Card: PopoverCard,\n Close: PopoverClose,\n});\n"],"mappings":";;;;;;;;;;;;;AA0BA,MAAa,iBAAiB,iBAAiB;AAC/C,MAAa,gBAAgB,iBAAiB;AAC9C,MAAa,gBAAgB,iBAAiB;AAE9C,MAAM,qBAAqB,cAGxB,EAAE,CAAC;AAEN,MAAa,iBAAiB,WAG5B,SAAS,eACT,EACE,sBACA,kBACA,iBACA,mBACA,iBACA,GAAG,SAEL,KACA;CACA,MAAM,EAAE,OAAO,eAAe,WAAW,mBAAmB;CAC5D,MAAM,EAAE,KAAK,eAAe,GAAG,eAAe,cAAc;EAC1D;EACA;EACA;EACA;EACA;EACA;EACD,CAAC;CACF,MAAM,YAAY,cAAc,UAAU,KAAK,cAAc,EAAE,CAAC,KAAK,cAAc,CAAC;AACpF,QACE,oBAAC,iBAAiB,SAAlB;EACE,GAAI;EACJ,GAAI;EACa;EACjB,KAAK;EACL,uBAAuB,UAAU;AAC/B,0BAAuB,MAAM;AAC7B,+BAA4B,MAAM;;EAEpC,CAAA;EAEJ;AAEF,MAAM,uBAAuB,OAAO,eAAe;IAC/C,cAAc,2CAA2C,CAAC;cAChD,EAAE,aAAa,UAAU,UAAU;KAC5C,EAAE,iBACH,cACA,GAAG;oBACa,WAAW;;QAEvB,kBAAkB;MACpB;;AAGN,MAAM,qBAAqB,OAAO,iBAAiB,MAAM;KACpD,EAAE,eAC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;GACL,KAAK;GACL,KAAK,iBAAiB;AACpB,kBAAc;AACd;GACF,KAAK,iBAAiB;AAEpB,iBAAa;AACb,WAAO;;AAIb,SAAO;GACP;CAEF,MAAM,UAAU,eAAe,oBAAC,aAAD;EAAa,GAAI;YAAe;EAA6B,CAAA;CAC5F,MAAM,aAAa,OAA0B,KAAK;CAClD,MAAM,cAAc,eAAe;EAAE,OAAO,MAAM;EAAO;EAAY,GAAG,CAAC,MAAM,MAAM,CAAC;CACtF,MAAM,aAAuC;CAC7C,MAAM,gBAAiB,YAA6D;CACpF,MAAM,sBAAsB,cAAc,UAAU,eAAe,WAAW,EAAE,CAAC,cAAc,CAAC;CAChG,MAAM,kBAAmB,cAAqE;CAC9F,MAAM,mBAAmB,cAAc,UAAU,iBAAiB,WAAW,EAAE,CAAC,gBAAgB,CAAC;AAEjG,QACE,oBAAC,mBAAmB,UAApB;EAA6B,OAAO;YAClC,qBAAC,iBAAiB,MAAlB;GAAuB,GAAI;aAA3B;IACG,aACG,aAAa,YAAY,EAAE,KAAK,qBAAqB,CAAC,GACtD,WACE,oBAAC,gBAAD;KAAgB,SAAA;KAAQ,GAAI;KAAc,KAAK;eAC5C;KACc,CAAA;IAEtB;IACA,SAAS,oBAAC,eAAD;KAAe,GAAI;eAAc;KAAwB,CAAA,GAAG;IAChD;;EACI,CAAA;;AAIlC,IAAA,kBAAe,OAAO,OAAO,SAAS;CACpC,SAAS;CACT,QAAQ;CACR,QAAQ;CACR,SAAS;CACT,MAAM;CACN,OAAO;CACR,CAAC"}
@@ -1,6 +1,6 @@
1
+ import { Spacing } from "@persona/design-tokens";
1
2
  import * as _$react from "react";
2
3
  import { ReactElement } from "react";
3
- import { Spacing } from "@persona/design-tokens";
4
4
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
5
5
  import * as PopoverPrimitive from "@radix-ui/react-popover";
6
6
 
@@ -1,5 +1,5 @@
1
- import { ComponentPropsWithoutRef } from "react";
2
1
  import { Color } from "@persona/design-tokens";
2
+ import { ComponentPropsWithoutRef } from "react";
3
3
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
4
4
 
5
5
  //#region src/components/ProgressBar/ProgressBar.d.ts
@@ -1,8 +1,8 @@
1
1
  import { a as styled, o as useTheme, r as css } from "./styledComponentsInterop-Cs5CCPRy.mjs";
2
2
  import { semanticColor, semanticTokens } from "./lib/semanticColor.mjs";
3
- import { paragraphMixins } from "./mixins/text.mjs";
4
- import { withAlpha } from "./lib/color.mjs";
5
3
  import { focusOutline } from "./mixins/focus.mjs";
4
+ import { withAlpha } from "./lib/color.mjs";
5
+ import { paragraphMixins } from "./mixins/text.mjs";
6
6
  import { BorderRadius, Color, Spacing } from "@persona/design-tokens";
7
7
  import { jsx, jsxs } from "react/jsx-runtime";
8
8
  import { CircleCheckFillIcon, CircleFillIcon, CircleNullIcon, CircleWarningFillIcon, WarningFillIcon } from "@persona/icons";
@@ -185,4 +185,4 @@ const ProgressIndicator = ({ steps, activeStepId, layout = "vertical", onStepCli
185
185
  //#endregion
186
186
  export { ProgressIndicator as t };
187
187
 
188
- //# sourceMappingURL=ProgressIndicator-zt3ndT9U.mjs.map
188
+ //# sourceMappingURL=ProgressIndicator-hy1P-RG1.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"ProgressIndicator-zt3ndT9U.mjs","names":[],"sources":["../src/components/ProgressIndicator/ProgressIndicator.tsx"],"sourcesContent":["import type { ComponentPropsWithoutRef } from 'react';\nimport styled, { css, useTheme } from 'styled-components';\n\nimport { focusOutline } from '@persona/design-system/mixins/focus';\nimport { paragraphMixins } from '@persona/design-system/mixins/text';\nimport { BorderRadius, Color, Spacing } from '@persona/design-tokens';\nimport {\n CircleCheckFillIcon,\n CircleFillIcon,\n CircleNullIcon,\n CircleWarningFillIcon,\n WarningFillIcon,\n} from '@persona/icons';\nimport type { PDSIconComponent } from '@persona/icons/types';\n\nimport { withAlpha } from '#src/lib/color';\nimport { type MaybeSemanticTheme, semanticColor, semanticTokens } from '#src/lib/semanticColor';\n\nexport type StepStatus = 'uncompleted' | 'completed' | 'warning' | 'error';\n\nexport interface ProgressIndicatorStep {\n id: string;\n label: string;\n /** @default 'uncompleted' */\n status?: StepStatus;\n disabled?: boolean;\n}\n\nexport interface ProgressIndicatorProps extends ComponentPropsWithoutRef<'ol'> {\n steps: ProgressIndicatorStep[];\n /** id of the step that should receive the active visual state */\n activeStepId?: string;\n /** @default 'vertical' */\n layout?: 'vertical' | 'horizontal';\n /**\n * Called when a clickable step is activated via click or keyboard.\n *\n * Clickability rules:\n * - `completed`, `warning`, and `error` steps are clickable (navigate back to review/edit)\n * - The active step is not clickable (user is already there)\n * - Upcoming `uncompleted` steps are not clickable (sequential progression required)\n */\n onStepClick?: (stepId: string) => void;\n}\n\n// ─── Helpers ─────────────────────────────────────────────────────────────────\n\n/**\n * Completed, warning, and error steps can be navigated back to.\n * The current step (first uncompleted or error) is also clickable so the user can\n * return to it after navigating back to an earlier step.\n * Active and upcoming steps (beyond the current) are not clickable.\n */\nfunction resolveClickable(\n status: StepStatus,\n isActive: boolean,\n isDisabled: boolean,\n isCurrent: boolean,\n): boolean {\n if (isDisabled || isActive) {\n return false;\n }\n return status === 'completed' || status === 'warning' || status === 'error' || isCurrent;\n}\n\nfunction resolveIcon(status: StepStatus, isCurrent: boolean): PDSIconComponent {\n if (status === 'completed') {\n return CircleCheckFillIcon;\n }\n if (status === 'warning') {\n return WarningFillIcon;\n }\n if (status === 'error') {\n return CircleWarningFillIcon;\n }\n if (isCurrent) {\n return CircleFillIcon;\n }\n return CircleNullIcon;\n}\n\nfunction resolveIconColor(\n theme: MaybeSemanticTheme,\n status: StepStatus,\n isActive: boolean,\n isDisabled: boolean,\n) {\n if (isDisabled) {\n return semanticColor(theme, 'FgDisabled', Color.BorderIconDisabled);\n }\n if (status === 'completed') {\n return semanticColor(theme, 'StatusSuccess3', Color.BorderIconSuccess);\n }\n if (status === 'warning') {\n return semanticColor(theme, 'FgWarning1', Color.BorderIconWarning);\n }\n if (status === 'error') {\n return semanticColor(theme, 'StatusDanger4', Color.BorderIconDanger);\n }\n return isActive\n ? semanticColor(theme, 'FgAccent', Color.BorderIconActive)\n : semanticColor(theme, 'FgSecondary', Color.BorderIconSecondary);\n}\n\nfunction resolveTextColor(\n theme: MaybeSemanticTheme,\n status: StepStatus,\n isActive: boolean,\n isDisabled: boolean,\n) {\n if (isDisabled) {\n return semanticColor(theme, 'FgDisabled', Color.TextDisabled);\n }\n if (isActive) {\n return semanticColor(theme, 'FgAccent', Color.TextActive);\n }\n if (status === 'uncompleted') {\n return semanticColor(theme, 'FgSecondary', Color.TextSecondary);\n }\n return semanticColor(theme, 'FgPrimary', Color.TextPrimary);\n}\n\n// ─── Styled components ────────────────────────────────────────────────────────\n\nconst StepList = styled.ol<{ $layout: 'vertical' | 'horizontal' }>`\n display: flex;\n flex-direction: ${({ $layout }) => ($layout === 'horizontal' ? 'row' : 'column')};\n gap: ${({ $layout }) => ($layout === 'horizontal' ? Spacing[2] : '0px')};\n list-style: none;\n margin: 0;\n padding: 0;\n`;\n\nconst StepItem = styled.li<{ $layout: 'vertical' | 'horizontal' }>`\n display: flex;\n align-items: center;\n\n ${({ $layout }) =>\n $layout === 'horizontal' &&\n css`\n width: fit-content;\n white-space: nowrap;\n `}\n`;\n\nconst StepContent = styled.button<{\n $isActive: boolean;\n $isClickable: boolean;\n $interactive: boolean;\n}>`\n display: flex;\n align-items: center;\n gap: ${Spacing[2]};\n width: 100%;\n padding: ${Spacing[2]};\n border-radius: ${BorderRadius.Md};\n border: none;\n margin: 0;\n font: inherit;\n color: inherit;\n text-align: left;\n outline: none;\n cursor: ${({ $isClickable, $interactive }) => ($interactive && $isClickable ? 'pointer' : 'default')};\n\n ${({ theme, $isActive, $isClickable, $interactive }) => {\n const tokens = semanticTokens(theme);\n if ($isActive) {\n return css`\n background-color: ${\n tokens\n ? withAlpha(tokens.SurfaceAccent, tokens.Opacity25)\n : Color.BackgroundInteractiveActive\n };\n `;\n }\n if ($interactive && $isClickable) {\n return css`\n background-color: ${tokens ? 'transparent' : Color.BackgroundInteractiveDefault};\n &:hover {\n background-color: ${semanticColor(theme, 'SurfaceSecondary', Color.BackgroundInteractiveHover)};\n }\n `;\n }\n return css`\n background-color: transparent;\n `;\n }}\n\n ${focusOutline}\n\n &:focus-visible {\n position: relative;\n z-index: 1;\n }\n`;\n\nconst IconWrapper = styled.span<{ $color: string }>`\n display: inline-flex;\n flex-shrink: 0;\n width: 16px;\n height: 16px;\n color: ${({ $color }) => $color};\n line-height: 0;\n`;\n\nconst StepLabel = styled.span<{ $isActive: boolean; $color: string }>`\n ${({ $isActive }) => ($isActive ? paragraphMixins.mdBold : paragraphMixins.md)};\n color: ${({ $color }) => $color};\n`;\n\n// ─── Step ─────────────────────────────────────────────────────────────────────\n\ninterface StepProps {\n step: ProgressIndicatorStep;\n isActive: boolean;\n isCurrent: boolean;\n layout: 'vertical' | 'horizontal';\n onStepClick?: (stepId: string) => void;\n}\n\nconst Step = ({ step, isActive, isCurrent, layout, onStepClick }: StepProps) => {\n const { id, label, status = 'uncompleted', disabled = false } = step;\n\n const interactive = Boolean(onStepClick);\n const isClickable = resolveClickable(status, isActive, disabled, isCurrent);\n const isInteractionDisabled = disabled || (!isActive && !isCurrent && status === 'uncompleted');\n const theme = useTheme();\n const iconColor = resolveIconColor(theme, status, isActive, disabled);\n const textColor = resolveTextColor(theme, status, isActive, disabled);\n\n const Icon = resolveIcon(status, isCurrent);\n\n return (\n <StepItem\n $layout={layout}\n aria-current={!interactive && isActive ? 'step' : undefined}\n aria-disabled={!interactive && isInteractionDisabled ? true : undefined}\n >\n <StepContent\n {...(interactive && isClickable\n ? { type: 'button' as const, onClick: () => onStepClick?.(id) }\n : { as: 'div' as const })}\n aria-current={interactive && isActive ? 'step' : undefined}\n aria-disabled={interactive && isInteractionDisabled ? true : undefined}\n $isActive={isActive}\n $isClickable={isClickable}\n $interactive={interactive}\n >\n <IconWrapper $color={iconColor} aria-hidden='true'>\n <Icon />\n </IconWrapper>\n <StepLabel $isActive={isActive} $color={textColor}>\n {label}\n </StepLabel>\n </StepContent>\n </StepItem>\n );\n};\n\n// ─── Component ────────────────────────────────────────────────────────────────\n\n/**\n * ProgressIndicator guides users through a sequence of steps.\n *\n * Interaction rules:\n * - **Completed / warning / error** steps are clickable — navigate back to review or fix.\n * - **Warning** does not block forward progression; later uncompleted steps remain reachable.\n * - **Error** blocks forward progression — treat it as the terminal step in the sequence.\n * - **Active** step is not clickable — the user is already there.\n * - **Upcoming (uncompleted)** steps are not clickable — sequential progression required.\n *\n * Navigation does not clear later steps. If a change on an earlier step\n * invalidates later data, the affected steps should be flagged and require\n * re-confirmation before submission — this logic lives in the consuming component.\n *\n * @example\n * ```tsx\n * <ProgressIndicator\n * steps={[\n * { id: 'identity', label: 'Identity', status: 'completed' },\n * { id: 'address', label: 'Address', status: 'uncompleted' },\n * { id: 'review', label: 'Review', status: 'uncompleted' },\n * ]}\n * activeStepId=\"address\"\n * onStepClick={(id) => navigate(id)}\n * />\n * ```\n */\nexport const ProgressIndicator = ({\n steps,\n activeStepId,\n layout = 'vertical',\n onStepClick,\n 'aria-label': ariaLabel = 'Progress',\n ...rest\n}: ProgressIndicatorProps) => {\n // The \"current\" step is the first uncompleted or error step — where the user should work next.\n // Warning steps are skipped so forward progression is not blocked.\n // This is independent of activeStepId, which only controls the visual highlight.\n const currentStepId = steps.find(\n ({ status = 'uncompleted' }) => status === 'uncompleted' || status === 'error',\n )?.id;\n\n return (\n <StepList $layout={layout} role='list' aria-label={ariaLabel} {...rest}>\n {steps.map((step) => (\n <Step\n key={step.id}\n step={step}\n isActive={step.id === activeStepId}\n isCurrent={step.id === currentStepId}\n layout={layout}\n onStepClick={onStepClick}\n />\n ))}\n </StepList>\n );\n};\n\nexport default ProgressIndicator;\n"],"mappings":";;;;;;;;;;;;;;;AAqDA,SAAS,iBACP,QACA,UACA,YACA,WACS;AACT,KAAI,cAAc,SAChB,QAAO;AAET,QAAO,WAAW,eAAe,WAAW,aAAa,WA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IAAa,QAAQ;IAAW,eAAY;cAC1C,oBAAC,MAAD,EAAQ,CAAA;IACI,CAAA,EACd,oBAAC,WAAD;IAAW,WAAW;IAAU,QAAQ;cACrC;IACS,CAAA,CACA;;EACL,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAiCf,MAAa,qBAAqB,EAChC,OACA,cACA,SAAS,YACT,aACA,cAAc,YAAY,YAC1B,GAAG,WACyB;CAI5B,MAAM,gBAAgB,MAAM,MACzB,EAAE,SAAS,oBAAoB,WAAW,iBAAiB,WAAW,QACxE,EAAE;AAEH,QACE,oBAAC,UAAD;EAAU,SAAS;EAAQ,MAAK;EAAO,cAAY;EAAW,GAAI;YAC/D,MAAM,KAAK,SACV,oBAAC,MAAD;GAEQ;GACN,UAAU,KAAK,OAAO;GACtB,WAAW,KAAK,OAAO;GACf;GACK;GACb,EANK,KAAK,GAMV,CACF;EACO,CAAA"}
1
+ {"version":3,"file":"ProgressIndicator-hy1P-RG1.mjs","names":[],"sources":["../src/components/ProgressIndicator/ProgressIndicator.tsx"],"sourcesContent":["import type { ComponentPropsWithoutRef } from 'react';\nimport styled, { css, useTheme } from 'styled-components';\n\nimport { focusOutline } from '@persona/design-system/mixins/focus';\nimport { paragraphMixins } from '@persona/design-system/mixins/text';\nimport { BorderRadius, Color, Spacing } from '@persona/design-tokens';\nimport {\n CircleCheckFillIcon,\n CircleFillIcon,\n CircleNullIcon,\n CircleWarningFillIcon,\n WarningFillIcon,\n} from '@persona/icons';\nimport type { PDSIconComponent } from '@persona/icons/types';\n\nimport { withAlpha } from '#src/lib/color';\nimport { type MaybeSemanticTheme, semanticColor, semanticTokens } from '#src/lib/semanticColor';\n\nexport type StepStatus = 'uncompleted' | 'completed' | 'warning' | 'error';\n\nexport interface ProgressIndicatorStep {\n id: string;\n label: string;\n /** @default 'uncompleted' */\n status?: StepStatus;\n disabled?: boolean;\n}\n\nexport interface ProgressIndicatorProps extends ComponentPropsWithoutRef<'ol'> {\n steps: ProgressIndicatorStep[];\n /** id of the step that should receive the active visual state */\n activeStepId?: string;\n /** @default 'vertical' */\n layout?: 'vertical' | 'horizontal';\n /**\n * Called when a clickable step is activated via click or keyboard.\n *\n * Clickability rules:\n * - `completed`, `warning`, and `error` steps are clickable (navigate back to review/edit)\n * - The active step is not clickable (user is already there)\n * - Upcoming `uncompleted` steps are not clickable (sequential progression required)\n */\n onStepClick?: (stepId: string) => void;\n}\n\n// ─── Helpers ─────────────────────────────────────────────────────────────────\n\n/**\n * Completed, warning, and error steps can be navigated back to.\n * The current step (first uncompleted or error) is also clickable so the user can\n * return to it after navigating back to an earlier step.\n * Active and upcoming steps (beyond the current) are not clickable.\n */\nfunction resolveClickable(\n status: StepStatus,\n isActive: boolean,\n isDisabled: boolean,\n isCurrent: boolean,\n): boolean {\n if (isDisabled || isActive) {\n return false;\n }\n return status === 'completed' || status === 'warning' || status === 'error' || isCurrent;\n}\n\nfunction resolveIcon(status: StepStatus, isCurrent: boolean): PDSIconComponent {\n if (status === 'completed') {\n return CircleCheckFillIcon;\n }\n if (status === 'warning') {\n return WarningFillIcon;\n }\n if (status === 'error') {\n return CircleWarningFillIcon;\n }\n if (isCurrent) {\n return CircleFillIcon;\n }\n return CircleNullIcon;\n}\n\nfunction resolveIconColor(\n theme: MaybeSemanticTheme,\n status: StepStatus,\n isActive: boolean,\n isDisabled: boolean,\n) {\n if (isDisabled) {\n return semanticColor(theme, 'FgDisabled', Color.BorderIconDisabled);\n }\n if (status === 'completed') {\n return semanticColor(theme, 'StatusSuccess3', Color.BorderIconSuccess);\n }\n if (status === 'warning') {\n return semanticColor(theme, 'FgWarning1', Color.BorderIconWarning);\n }\n if (status === 'error') {\n return semanticColor(theme, 'StatusDanger4', Color.BorderIconDanger);\n }\n return isActive\n ? semanticColor(theme, 'FgAccent', Color.BorderIconActive)\n : semanticColor(theme, 'FgSecondary', Color.BorderIconSecondary);\n}\n\nfunction resolveTextColor(\n theme: MaybeSemanticTheme,\n status: StepStatus,\n isActive: boolean,\n isDisabled: boolean,\n) {\n if (isDisabled) {\n return semanticColor(theme, 'FgDisabled', Color.TextDisabled);\n }\n if (isActive) {\n return semanticColor(theme, 'FgAccent', Color.TextActive);\n }\n if (status === 'uncompleted') {\n return semanticColor(theme, 'FgSecondary', Color.TextSecondary);\n }\n return semanticColor(theme, 'FgPrimary', Color.TextPrimary);\n}\n\n// ─── Styled components ────────────────────────────────────────────────────────\n\nconst StepList = styled.ol<{ $layout: 'vertical' | 'horizontal' }>`\n display: flex;\n flex-direction: ${({ $layout }) => ($layout === 'horizontal' ? 'row' : 'column')};\n gap: ${({ $layout }) => ($layout === 'horizontal' ? Spacing[2] : '0px')};\n list-style: none;\n margin: 0;\n padding: 0;\n`;\n\nconst StepItem = styled.li<{ $layout: 'vertical' | 'horizontal' }>`\n display: flex;\n align-items: center;\n\n ${({ $layout }) =>\n $layout === 'horizontal' &&\n css`\n width: fit-content;\n white-space: nowrap;\n `}\n`;\n\nconst StepContent = styled.button<{\n $isActive: boolean;\n $isClickable: boolean;\n $interactive: boolean;\n}>`\n display: flex;\n align-items: center;\n gap: ${Spacing[2]};\n width: 100%;\n padding: ${Spacing[2]};\n border-radius: ${BorderRadius.Md};\n border: none;\n margin: 0;\n font: inherit;\n color: inherit;\n text-align: left;\n outline: none;\n cursor: ${({ $isClickable, $interactive }) => ($interactive && $isClickable ? 'pointer' : 'default')};\n\n ${({ theme, $isActive, $isClickable, $interactive }) => {\n const tokens = semanticTokens(theme);\n if ($isActive) {\n return css`\n background-color: ${\n tokens\n ? withAlpha(tokens.SurfaceAccent, tokens.Opacity25)\n : Color.BackgroundInteractiveActive\n };\n `;\n }\n if ($interactive && $isClickable) {\n return css`\n background-color: ${tokens ? 'transparent' : Color.BackgroundInteractiveDefault};\n &:hover {\n background-color: ${semanticColor(theme, 'SurfaceSecondary', Color.BackgroundInteractiveHover)};\n }\n `;\n }\n return css`\n background-color: transparent;\n `;\n }}\n\n ${focusOutline}\n\n &:focus-visible {\n position: relative;\n z-index: 1;\n }\n`;\n\nconst IconWrapper = styled.span<{ $color: string }>`\n display: inline-flex;\n flex-shrink: 0;\n width: 16px;\n height: 16px;\n color: ${({ $color }) => $color};\n line-height: 0;\n`;\n\nconst StepLabel = styled.span<{ $isActive: boolean; $color: string }>`\n ${({ $isActive }) => ($isActive ? paragraphMixins.mdBold : paragraphMixins.md)};\n color: ${({ $color }) => $color};\n`;\n\n// ─── Step ─────────────────────────────────────────────────────────────────────\n\ninterface StepProps {\n step: ProgressIndicatorStep;\n isActive: boolean;\n isCurrent: boolean;\n layout: 'vertical' | 'horizontal';\n onStepClick?: (stepId: string) => void;\n}\n\nconst Step = ({ step, isActive, isCurrent, layout, onStepClick }: StepProps) => {\n const { id, label, status = 'uncompleted', disabled = false } = step;\n\n const interactive = Boolean(onStepClick);\n const isClickable = resolveClickable(status, isActive, disabled, isCurrent);\n const isInteractionDisabled = disabled || (!isActive && !isCurrent && status === 'uncompleted');\n const theme = useTheme();\n const iconColor = resolveIconColor(theme, status, isActive, disabled);\n const textColor = resolveTextColor(theme, status, isActive, disabled);\n\n const Icon = resolveIcon(status, isCurrent);\n\n return (\n <StepItem\n $layout={layout}\n aria-current={!interactive && isActive ? 'step' : undefined}\n aria-disabled={!interactive && isInteractionDisabled ? true : undefined}\n >\n <StepContent\n {...(interactive && isClickable\n ? { type: 'button' as const, onClick: () => onStepClick?.(id) }\n : { as: 'div' as const })}\n aria-current={interactive && isActive ? 'step' : undefined}\n aria-disabled={interactive && isInteractionDisabled ? true : undefined}\n $isActive={isActive}\n $isClickable={isClickable}\n $interactive={interactive}\n >\n <IconWrapper $color={iconColor} aria-hidden='true'>\n <Icon />\n </IconWrapper>\n <StepLabel $isActive={isActive} $color={textColor}>\n {label}\n </StepLabel>\n </StepContent>\n </StepItem>\n );\n};\n\n// ─── Component ────────────────────────────────────────────────────────────────\n\n/**\n * ProgressIndicator guides users through a sequence of steps.\n *\n * Interaction rules:\n * - **Completed / warning / error** steps are clickable — navigate back to review or fix.\n * - **Warning** does not block forward progression; later uncompleted steps remain reachable.\n * - **Error** blocks forward progression — treat it as the terminal step in the sequence.\n * - **Active** step is not clickable — the user is already there.\n * - **Upcoming (uncompleted)** steps are not clickable — sequential progression required.\n *\n * Navigation does not clear later steps. If a change on an earlier step\n * invalidates later data, the affected steps should be flagged and require\n * re-confirmation before submission — this logic lives in the consuming component.\n *\n * @example\n * ```tsx\n * <ProgressIndicator\n * steps={[\n * { id: 'identity', label: 'Identity', status: 'completed' },\n * { id: 'address', label: 'Address', status: 'uncompleted' },\n * { id: 'review', label: 'Review', status: 'uncompleted' },\n * ]}\n * activeStepId=\"address\"\n * onStepClick={(id) => navigate(id)}\n * />\n * ```\n */\nexport const ProgressIndicator = ({\n steps,\n activeStepId,\n layout = 'vertical',\n onStepClick,\n 'aria-label': ariaLabel = 'Progress',\n ...rest\n}: ProgressIndicatorProps) => {\n // The \"current\" step is the first uncompleted or error step — where the user should work next.\n // Warning steps are skipped so forward progression is not blocked.\n // This is independent of activeStepId, which only controls the visual highlight.\n const currentStepId = steps.find(\n ({ status = 'uncompleted' }) => status === 'uncompleted' || status === 'error',\n )?.id;\n\n return (\n <StepList $layout={layout} role='list' aria-label={ariaLabel} {...rest}>\n {steps.map((step) => (\n <Step\n key={step.id}\n step={step}\n isActive={step.id === activeStepId}\n isCurrent={step.id === currentStepId}\n layout={layout}\n onStepClick={onStepClick}\n />\n ))}\n </StepList>\n );\n};\n\nexport default ProgressIndicator;\n"],"mappings":";;;;;;;;;;;;;;;AAqDA,SAAS,iBACP,QACA,UACA,YACA,WACS;AACT,KAAI,cAAc,SAChB,QAAO;AAET,QAAO,WAAW,eAAe,WAAW,aAAa,WAAW,WAAW;;AAGjF,SAAS,YAAY,QAAoB,WAAsC;AAC7E,KAAI,WAAW,YACb,QAAO;AAET,KAAI,WAAW,UACb,QAAO;AAET,KAAI,WAAW,QACb,QAAO;AAET,KAAI,UACF,QAAO;AAET,QAAO;;AAGT,SAAS,iBACP,OACA,QACA,UACA,YACA;A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EAChC,OACA,cACA,SAAS,YACT,aACA,cAAc,YAAY,YAC1B,GAAG,WACyB;CAI5B,MAAM,gBAAgB,MAAM,MACzB,EAAE,SAAS,oBAAoB,WAAW,iBAAiB,WAAW,QACxE,EAAE;AAEH,QACE,oBAAC,UAAD;EAAU,SAAS;EAAQ,MAAK;EAAO,cAAY;EAAW,GAAI;YAC/D,MAAM,KAAK,SACV,oBAAC,MAAD;GAEQ;GACN,UAAU,KAAK,OAAO;GACtB,WAAW,KAAK,OAAO;GACf;GACK;GACb,EANK,KAAK,GAMV,CACF;EACO,CAAA"}
@@ -1,12 +1,12 @@
1
1
  import { a as styled, r as css } from "./styledComponentsInterop-Cs5CCPRy.mjs";
2
+ import { isChecked, isDisabled, isFocusedVisible, isHovered, isNotDisabled } from "./lib/pseudoClass.mjs";
2
3
  import { semanticColor, semanticOnly } from "./lib/semanticColor.mjs";
4
+ import { focusStyle } from "./mixins/focus.mjs";
3
5
  import "./variables/transitions.mjs";
4
6
  import { opacityOf } from "./lib/color.mjs";
5
- import { isChecked, isDisabled, isFocusedVisible, isHovered, isNotDisabled } from "./lib/pseudoClass.mjs";
6
- import { focusStyle } from "./mixins/focus.mjs";
7
- import { n as useFormField } from "./useFormField-pOVkb5BK.mjs";
8
- import { forwardRef, useMemo } from "react";
7
+ import { n as useFormField } from "./useFormField-Cd9sH-HM.mjs";
9
8
  import { Color, Spacing, Typography } from "@persona/design-tokens";
9
+ import { forwardRef, useMemo } from "react";
10
10
  import { jsx, jsxs } from "react/jsx-runtime";
11
11
  import { uniqueId } from "lodash-es";
12
12
  //#region src/components/Radio/Radio.tsx
@@ -148,4 +148,4 @@ const Radio = forwardRef(function Radio({ id, label, className, value, disabled,
148
148
  //#endregion
149
149
  export { Radio as t };
150
150
 
151
- //# sourceMappingURL=Radio-B1H_S-Qj.mjs.map
151
+ //# sourceMappingURL=Radio-D6Vydkx-.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"Radio-B1H_S-Qj.mjs","names":[],"sources":["../src/components/Radio/Radio.tsx"],"sourcesContent":["import { uniqueId } from 'lodash-es';\nimport {\n type ChangeEvent,\n type ComponentPropsWithoutRef,\n forwardRef,\n type ReactNode,\n useMemo,\n} from 'react';\nimport styled, { css } from 'styled-components';\n\nimport { Color, Spacing, Typography } from '@persona/design-tokens';\n\nimport useFormField from '#src/components/FormControl/useFormField';\nimport { opacityOf } from '#src/lib/color';\nimport {\n isChecked,\n isDisabled,\n isFocusedVisible,\n isHovered,\n isNotDisabled,\n} from '#src/lib/pseudoClass';\nimport { semanticColor, semanticOnly } from '#src/lib/semanticColor';\nimport { focusStyle } from '#src/mixins/focus';\nimport { TransitionDuration, TransitionEasing } from '#src/variables/transitions';\n\nconst Container = styled.div<{ size: 'md' | 'sm'; disabled?: boolean }>`\n cursor: pointer;\n display: flex;\n align-items: flex-start;\n flex-wrap: nowrap;\n position: relative;\n\n ${({ size }) =>\n size === 'sm' &&\n css`\n align-items: center;\n height: 16px;\n `}\n\n &${isDisabled} {\n cursor: default;\n }\n`;\n\nconst Label = styled.label<{ disabled: boolean; size: 'md' | 'sm' }>`\n cursor: inherit;\n padding: 0 ${Spacing[2]};\n color: ${({ theme }) => semanticColor(theme, 'FgSecondary', Color.TextSecondary)};\n\n ${({ size }) =>\n size === 'sm'\n ? css`\n ${Typography.TextSmall};\n line-height: 16px;\n `\n : css`\n ${Typography.TextMedium};\n `}\n\n ${({ theme, disabled }) =>\n disabled &&\n css`\n cursor: default;\n color: ${semanticColor(theme, 'FgDisabled', theme.color.text.disabled)};\n `}\n`;\n\nconst RadioCircle = styled.div<{ size: 'md' | 'sm' }>`\n cursor: pointer;\n display: flex;\n justify-content: center;\n align-items: center;\n transition: box-shadow ${TransitionDuration.Fast} ${TransitionEasing.Move};\n border-radius: 100%;\n height: ${Spacing[4]};\n width: ${Spacing[4]};\n flex: 0 0 16px;\n box-sizing: border-box;\n margin-top: ${({ size }) => (size === 'sm' ? 0 : '2px')};\n border: 1px solid ${({ theme }) => semanticColor(theme, 'InputBorderStrong', Color.BorderInputCheckbox)};\n background: ${({ theme }) => semanticColor(theme, 'InputSurfaceDefault', Color.PrimaryWhite)};\n`;\n\nconst RadioInput = styled.input<{ $size: 'md' | 'sm' }>`\n cursor: inherit;\n height: ${Spacing[4]};\n width: ${Spacing[4]};\n margin: 0;\n border: 0;\n opacity: 0;\n overflow: hidden;\n position: absolute;\n top: ${({ $size }) => ($size === 'sm' ? 0 : '2px')};\n border-radius: 100%;\n z-index: 10; // this needs to be above the dot in the checked input\n\n &${isHovered}${isNotDisabled} ~ ${RadioCircle} {\n border-color: ${({ theme }) =>\n semanticColor(theme, 'InputBorderHoverStrong', Color.BorderInputCheckboxHover)};\n ${semanticOnly((tokens) => `background: ${tokens.InputSurfaceHover};`)}\n }\n\n &${isChecked}, &:checked {\n &${isHovered}${isNotDisabled} ~ ${RadioCircle} {\n background: ${({ theme }) => semanticColor(theme, 'InputSurfaceAccentHover', Color.BackgroundInputActiveHover)};\n border-color: ${({ theme }) => semanticColor(theme, 'InputSurfaceAccentHover', Color.BackgroundInputActiveHover)};\n }\n }\n\n &${isFocusedVisible}${isNotDisabled} ~ ${RadioCircle} {\n ${focusStyle}\n }\n\n // RadioCircle state styles; Uses pure CSS\n &${isDisabled} + ${RadioCircle} {\n cursor: default;\n background: ${({ theme }) =>\n semanticColor(theme, 'InputSurfaceDisabled', Color.BackgroundInputDisabled)};\n border-color: ${({ theme }) =>\n semanticColor(theme, 'InputBorderDisabled', Color.BorderInputDisabled)};\n ${semanticOnly((tokens) => `opacity: ${opacityOf(tokens.Opacity65)};`)}\n }\n\n &:checked + ${RadioCircle}, &${isChecked} + ${RadioCircle} {\n border-color: ${({ theme }) => semanticColor(theme, 'InputBorderAccent', Color.BackgroundInputActive)};\n background: ${({ theme }) => semanticColor(theme, 'InputSurfaceAccent', Color.BackgroundInputActive)};\n\n &::after {\n background: ${({ theme }) => semanticColor(theme, 'FgInverseStatic', Color.BackgroundInputDefault)};\n height: 6px;\n width: 6px;\n border-radius: 100%;\n content: '';\n position: absolute;\n }\n }\n\n &:checked${isDisabled} + ${RadioCircle}, &${isChecked}${isDisabled} + ${RadioCircle} {\n border-color: ${({ theme }) => semanticColor(theme, 'InputSurfaceAccentDisabled', Color.BackgroundInputActiveDisabled)};\n background: ${({ theme }) => semanticColor(theme, 'InputSurfaceAccentDisabled', Color.BackgroundInputActiveDisabled)};\n }\n`;\n\nexport interface RadioProps extends Omit<ComponentPropsWithoutRef<'input'>, 'size'> {\n /**\n * If not provided, a unique ID will be generated.\n */\n id?: string;\n onChange?: (e: ChangeEvent<HTMLInputElement>) => void;\n label?: ReactNode;\n disabled?: boolean;\n checked?: boolean;\n value: string;\n 'data-test'?: string;\n size?: 'md' | 'sm';\n}\n\nexport const Radio = forwardRef<HTMLInputElement, RadioProps>(function Radio(\n {\n id,\n label,\n className,\n value,\n disabled,\n checked,\n defaultChecked,\n onChange,\n 'data-test': dataTest,\n size = 'md',\n ...elemProps\n },\n ref,\n) {\n const field = useFormField({ disabled });\n const generatedId = useMemo(() => uniqueId('pds_radio__'), []);\n\n return (\n <Container className={className} disabled={disabled} data-test={dataTest} size={size}>\n <RadioInput\n id={id || generatedId}\n disabled={field.disabled}\n onChange={onChange}\n type='radio'\n value={value}\n checked={checked}\n defaultChecked={defaultChecked}\n ref={ref}\n $size={size}\n {...elemProps}\n />\n <RadioCircle size={size} />\n {label && (\n <Label htmlFor={id || generatedId} disabled={disabled ?? false} size={size}>\n {label}\n </Label>\n )}\n </Container>\n );\n});\n\nexport default Radio;\n"],"mappings":";;;;;;;;;;;;AAyBA,MAAM,YAAY,OAAO,GAA8C;;;;;;;KAOlE,EAAE,WACH,SAAS,QACT,GAAG;;;MAGD;;KAED,WAAW;;;;AAKhB,MAAM,QAAQ,OAAO,KAA+C;;eAErD,QAAQ,GAAG;YACd,EAAE,YAAY,cAAc,OAAO,eAAe,MAAM,cAAc,CAAC;;KAE9E,EAAE,WACH,SAAS,OACL,GAAG;YACC,WAAW,UAAU;;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AsB,MAAM,sBAAsB,CAAC;;;qBAGpF,EAAE,YAAY,cAAc,OAAO,mBAAmB,MAAM,uBAAuB,CAAC;;;;;;;;;aAS5F,WAAW,KAAK,YAAY,KAAK,YAAY,WAAW,KAAK,YAAY;qBACjE,EAAE,YAAY,cAAc,OAAO,8BAA8B,MAAM,8BAA8B,CAAC;mBACxG,EAAE,YAAY,cAAc,OAAO,8BAA8B,MAAM,8BAA8B,CAAC;;;AAkBzH,MAAa,QAAQ,WAAyC,SAAS,MACrE,EACE,IACA,OACA,WACA,OACA,UACA,SACA,gBACA,UACA,aAAa,UACb,OAAO,MACP,GAAG,aAEL,KACA;CACA,MAAM,QAAQ,aAAa,EAAE,UAAU,CAAC;CACxC,MAAM,cAAc,cAAc,SAAS,cAAc,EAAE,EAAE,CAAC;AAE9D,QACE,qBAAC,WAAD;EAAsB;EAAqB;EAAU,aAAW;EAAgB;YAAhF;GACE,oBAAC,YAAD;IACE,IAAI,MAAM;IACV,UAAU,MAAM;IACN;IACV,MAAK;IACE;IACE;IACO;IACX;IACL,OAAO;IACP,GAAI;IACJ,CAAA;GACF,oBAAC,aAAD,EAAmB,MAAQ,CAAA;GAC1B,SACC,oBAAC,OAAD;IAAO,SAAS,MAAM;IAAa,UAAU,YAAY;IAAa;cACnE;IACK,CAAA;GAEA;;EAEd"}
1
+ {"version":3,"file":"Radio-D6Vydkx-.mjs","names":[],"sources":["../src/components/Radio/Radio.tsx"],"sourcesContent":["import { uniqueId } from 'lodash-es';\nimport {\n type ChangeEvent,\n type ComponentPropsWithoutRef,\n forwardRef,\n type ReactNode,\n useMemo,\n} from 'react';\nimport styled, { css } from 'styled-components';\n\nimport { Color, Spacing, Typography } from '@persona/design-tokens';\n\nimport useFormField from '#src/components/FormControl/useFormField';\nimport { opacityOf } from '#src/lib/color';\nimport {\n isChecked,\n isDisabled,\n isFocusedVisible,\n isHovered,\n isNotDisabled,\n} from '#src/lib/pseudoClass';\nimport { semanticColor, semanticOnly } from '#src/lib/semanticColor';\nimport { focusStyle } from '#src/mixins/focus';\nimport { TransitionDuration, TransitionEasing } from '#src/variables/transitions';\n\nconst Container = styled.div<{ size: 'md' | 'sm'; disabled?: boolean }>`\n cursor: pointer;\n display: flex;\n align-items: flex-start;\n flex-wrap: nowrap;\n position: relative;\n\n ${({ size }) =>\n size === 'sm' &&\n css`\n align-items: center;\n height: 16px;\n `}\n\n &${isDisabled} {\n cursor: default;\n }\n`;\n\nconst Label = styled.label<{ disabled: boolean; size: 'md' | 'sm' }>`\n cursor: inherit;\n padding: 0 ${Spacing[2]};\n color: ${({ theme }) => semanticColor(theme, 'FgSecondary', Color.TextSecondary)};\n\n ${({ size }) =>\n size === 'sm'\n ? css`\n ${Typography.TextSmall};\n line-height: 16px;\n `\n : css`\n ${Typography.TextMedium};\n `}\n\n ${({ theme, disabled }) =>\n disabled &&\n css`\n cursor: default;\n color: ${semanticColor(theme, 'FgDisabled', theme.color.text.disabled)};\n `}\n`;\n\nconst RadioCircle = styled.div<{ size: 'md' | 'sm' }>`\n cursor: pointer;\n display: flex;\n justify-content: center;\n align-items: center;\n transition: box-shadow ${TransitionDuration.Fast} ${TransitionEasing.Move};\n border-radius: 100%;\n height: ${Spacing[4]};\n width: ${Spacing[4]};\n flex: 0 0 16px;\n box-sizing: border-box;\n margin-top: ${({ size }) => (size === 'sm' ? 0 : '2px')};\n border: 1px solid ${({ theme }) => semanticColor(theme, 'InputBorderStrong', Color.BorderInputCheckbox)};\n background: ${({ theme }) => semanticColor(theme, 'InputSurfaceDefault', Color.PrimaryWhite)};\n`;\n\nconst RadioInput = styled.input<{ $size: 'md' | 'sm' }>`\n cursor: inherit;\n height: ${Spacing[4]};\n width: ${Spacing[4]};\n margin: 0;\n border: 0;\n opacity: 0;\n overflow: hidden;\n position: absolute;\n top: ${({ $size }) => ($size === 'sm' ? 0 : '2px')};\n border-radius: 100%;\n z-index: 10; // this needs to be above the dot in the checked input\n\n &${isHovered}${isNotDisabled} ~ ${RadioCircle} {\n border-color: ${({ theme }) =>\n semanticColor(theme, 'InputBorderHoverStrong', Color.BorderInputCheckboxHover)};\n ${semanticOnly((tokens) => `background: ${tokens.InputSurfaceHover};`)}\n }\n\n &${isChecked}, &:checked {\n &${isHovered}${isNotDisabled} ~ ${RadioCircle} {\n background: ${({ theme }) => semanticColor(theme, 'InputSurfaceAccentHover', Color.BackgroundInputActiveHover)};\n border-color: ${({ theme }) => semanticColor(theme, 'InputSurfaceAccentHover', Color.BackgroundInputActiveHover)};\n }\n }\n\n &${isFocusedVisible}${isNotDisabled} ~ ${RadioCircle} {\n ${focusStyle}\n }\n\n // RadioCircle state styles; Uses pure CSS\n &${isDisabled} + ${RadioCircle} {\n cursor: default;\n background: ${({ theme }) =>\n semanticColor(theme, 'InputSurfaceDisabled', Color.BackgroundInputDisabled)};\n border-color: ${({ theme }) =>\n semanticColor(theme, 'InputBorderDisabled', Color.BorderInputDisabled)};\n ${semanticOnly((tokens) => `opacity: ${opacityOf(tokens.Opacity65)};`)}\n }\n\n &:checked + ${RadioCircle}, &${isChecked} + ${RadioCircle} {\n border-color: ${({ theme }) => semanticColor(theme, 'InputBorderAccent', Color.BackgroundInputActive)};\n background: ${({ theme }) => semanticColor(theme, 'InputSurfaceAccent', Color.BackgroundInputActive)};\n\n &::after {\n background: ${({ theme }) => semanticColor(theme, 'FgInverseStatic', Color.BackgroundInputDefault)};\n height: 6px;\n width: 6px;\n border-radius: 100%;\n content: '';\n position: absolute;\n }\n }\n\n &:checked${isDisabled} + ${RadioCircle}, &${isChecked}${isDisabled} + ${RadioCircle} {\n border-color: ${({ theme }) => semanticColor(theme, 'InputSurfaceAccentDisabled', Color.BackgroundInputActiveDisabled)};\n background: ${({ theme }) => semanticColor(theme, 'InputSurfaceAccentDisabled', Color.BackgroundInputActiveDisabled)};\n }\n`;\n\nexport interface RadioProps extends Omit<ComponentPropsWithoutRef<'input'>, 'size'> {\n /**\n * If not provided, a unique ID will be generated.\n */\n id?: string;\n onChange?: (e: ChangeEvent<HTMLInputElement>) => void;\n label?: ReactNode;\n disabled?: boolean;\n checked?: boolean;\n value: string;\n 'data-test'?: string;\n size?: 'md' | 'sm';\n}\n\nexport const Radio = forwardRef<HTMLInputElement, RadioProps>(function Radio(\n {\n id,\n label,\n className,\n value,\n disabled,\n checked,\n defaultChecked,\n onChange,\n 'data-test': dataTest,\n size = 'md',\n ...elemProps\n },\n ref,\n) {\n const field = useFormField({ disabled });\n const generatedId = useMemo(() => uniqueId('pds_radio__'), []);\n\n return (\n <Container className={className} disabled={disabled} data-test={dataTest} size={size}>\n <RadioInput\n id={id || generatedId}\n disabled={field.disabled}\n onChange={onChange}\n type='radio'\n value={value}\n checked={checked}\n defaultChecked={defaultChecked}\n ref={ref}\n $size={size}\n {...elemProps}\n />\n <RadioCircle size={size} />\n {label && (\n <Label htmlFor={id || generatedId} disabled={disabled ?? false} size={size}>\n {label}\n </Label>\n )}\n </Container>\n );\n});\n\nexport default Radio;\n"],"mappings":";;;;;;;;;;;;AAyBA,MAAM,YAAY,OAAO,GAA8C;;;;;;;KAOlE,EAAE,WACH,SAAS,QACT,GAAG;;;MAGD;;KAED,WAAW;;;;AAKhB,MAAM,QAAQ,OAAO,KAA+C;;eAErD,QAAQ,GAAG;YACd,EAAE,YAAY,cAAc,OAAO,eAAe,MAAM,cAAc,CAAC;;KAE9E,EAAE,WACH,SAAS,OACL,GAAG;YACC,WAAW,UAAU;;YAGzB,GAAG;YACC,WAAW,WAAW;UACxB;;KAEL,EAAE,OAAO,eACV,YACA,GAAG;;eAEQ,cAAc,OAAO,cAAc,MAAM,MAAM,KAAK,SAAS,CAAC;MACvE;;AAGN,MAAM,cAAc,OAAO,GAA0B;;;;;mCAKF,GAAA,+BAAyB;;YAEhE,QAAQ,GAAG;WACZ,QAAQ,GAAG;;;iBAGL,EAAE,WAAY,SAAS,OAAO,IAAI,MAAO;uBACnC,EAAE,YAAY,cAAc,OAAO,qBAAqB,MAAM,oBAAoB,CAAC;iBACzF,EAAE,YAAY,cAAc,OA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,UACb,OAAO,MACP,GAAG,aAEL,KACA;CACA,MAAM,QAAQ,aAAa,EAAE,UAAU,CAAC;CACxC,MAAM,cAAc,cAAc,SAAS,cAAc,EAAE,EAAE,CAAC;AAE9D,QACE,qBAAC,WAAD;EAAsB;EAAqB;EAAU,aAAW;EAAgB;YAAhF;GACE,oBAAC,YAAD;IACE,IAAI,MAAM;IACV,UAAU,MAAM;IACN;IACV,MAAK;IACE;IACE;IACO;IACX;IACL,OAAO;IACP,GAAI;IACJ,CAAA;GACF,oBAAC,aAAD,EAAmB,MAAQ,CAAA;GAC1B,SACC,oBAAC,OAAD;IAAO,SAAS,MAAM;IAAa,UAAU,YAAY;IAAa;cACnE;IACK,CAAA;GAEA;;EAEd"}
@@ -1,8 +1,8 @@
1
1
  import { a as styled, r as css } from "./styledComponentsInterop-Cs5CCPRy.mjs";
2
2
  import useControlled from "./lib/useControlled.mjs";
3
- import { t as Radio } from "./Radio-B1H_S-Qj.mjs";
4
- import { Children, cloneElement } from "react";
3
+ import { t as Radio } from "./Radio-D6Vydkx-.mjs";
5
4
  import { Spacing } from "@persona/design-tokens";
5
+ import { Children, cloneElement } from "react";
6
6
  import { jsx } from "react/jsx-runtime";
7
7
  //#region src/components/RadioGroup/RadioGroup.tsx
8
8
  const Container = styled.div`
@@ -47,4 +47,4 @@ const RadioGroup = ({ children, defaultValue, name, value: valueProp, onChange,
47
47
  //#endregion
48
48
  export { RadioGroup as t };
49
49
 
50
- //# sourceMappingURL=RadioGroup-7hdcVhsp.mjs.map
50
+ //# sourceMappingURL=RadioGroup-C04h3el1.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"RadioGroup-7hdcVhsp.mjs","names":[],"sources":["../src/components/RadioGroup/RadioGroup.tsx"],"sourcesContent":["import {\n type ChangeEvent,\n Children,\n cloneElement,\n type ComponentPropsWithoutRef,\n type ReactElement,\n type VFC,\n} from 'react';\nimport styled, { css } from 'styled-components';\n\nimport { Spacing } from '@persona/design-tokens';\n\nimport Radio, { type RadioProps } from '#src/components/Radio';\nimport useControlled from '#src/lib/useControlled';\n\nconst Container = styled.div<{ size: 'md' | 'sm'; horizontal?: boolean }>`\n & > div {\n margin-bottom: ${Spacing[2]};\n }\n\n ${({ horizontal }) =>\n horizontal &&\n css`\n display: flex;\n align-items: center;\n & > div {\n margin-right: ${Spacing[2]};\n }\n `}\n`;\n\nexport interface RadioGroupProps extends ComponentPropsWithoutRef<'div'> {\n defaultValue?: any;\n name?: string;\n value?: any;\n onChange?: (value: any) => void;\n /**\n * Direction of radio group\n */\n horizontal?: boolean;\n /**\n * Size of radio buttons within the group\n */\n size?: 'md' | 'sm';\n}\n\nexport const RadioGroup: VFC<RadioGroupProps> = ({\n children,\n defaultValue,\n name,\n value: valueProp,\n onChange,\n horizontal = false,\n size = 'md',\n ...elemProps\n}) => {\n const [value, setValue] = useControlled({\n controlledValue: valueProp,\n default: defaultValue,\n });\n\n return (\n <Container role='radiogroup' horizontal={horizontal} size={size} {...elemProps}>\n {/* @ts-expect-error [strict-migration] The following line is not strict; please fix! */}\n {Children.map(children, (child: ReactElement<RadioProps>) => {\n if (child?.type === Radio && (typeof valueProp !== 'undefined' || onChange)) {\n return cloneElement(child, {\n name,\n size,\n checked: child.props.value === value,\n onChange: (e: ChangeEvent<HTMLInputElement>) => {\n const newVal = e.target.value;\n if (typeof valueProp !== 'undefined' && onChange) {\n onChange(newVal);\n } else {\n setValue(newVal);\n }\n },\n });\n }\n\n if (name) {\n return cloneElement(child, { name });\n }\n\n return child;\n })}\n </Container>\n );\n};\n\nexport default RadioGroup;\n"],"mappings":";;;;;;;AAeA,MAAM,YAAY,OAAO,GAAgD;;qBAEpD,QAAQ,GAAG;;;KAG3B,EAAE,iBACH,cACA,GAAG;;;;wBAIiB,QAAQ,GAAG;;MAE7B;;AAkBN,MAAa,cAAoC,EAC/C,UACA,cACA,MACA,OAAO,WACP,UACA,aAAa,OACb,OAAO,MACP,GAAG,gBACC;CACJ,MAAM,CAAC,OAAO,YAAY,cAAc;EACtC,iBAAiB;EACjB,SAAS;EACV,CAAC;AAEF,QACE,oBAAC,WAAD;EAAW,MAAK;EAAyB;EAAkB;EAAM,GAAI;YAElE,SAAS,IAAI,WAAW,UAAoC;AAC3D,OAAI,OAAO,SAAS,UAAU,OAAO,cAAc,eAAe,UAChE,QAAO,aAAa,OAAO;IACzB;IACA;IACA,SAAS,MAAM,MAAM,UAAU;IAC/B,WAAW,MAAqC;KAC9C,MAAM,SAAS,EAAE,OAAO;AACxB,SAAI,OAAO,cAAc,eAAe,SACtC,UAAS,OAAO;SAEhB,UAAS,OAAO;;IAGrB,CAAC;AAGJ,OAAI,KACF,QAAO,aAAa,OAAO,EAAE,MAAM,CAAC;AAGtC,UAAO;IACP;EACQ,CAAA"}
1
+ {"version":3,"file":"RadioGroup-C04h3el1.mjs","names":[],"sources":["../src/components/RadioGroup/RadioGroup.tsx"],"sourcesContent":["import {\n type ChangeEvent,\n Children,\n cloneElement,\n type ComponentPropsWithoutRef,\n type ReactElement,\n type VFC,\n} from 'react';\nimport styled, { css } from 'styled-components';\n\nimport { Spacing } from '@persona/design-tokens';\n\nimport Radio, { type RadioProps } from '#src/components/Radio';\nimport useControlled from '#src/lib/useControlled';\n\nconst Container = styled.div<{ size: 'md' | 'sm'; horizontal?: boolean }>`\n & > div {\n margin-bottom: ${Spacing[2]};\n }\n\n ${({ horizontal }) =>\n horizontal &&\n css`\n display: flex;\n align-items: center;\n & > div {\n margin-right: ${Spacing[2]};\n }\n `}\n`;\n\nexport interface RadioGroupProps extends ComponentPropsWithoutRef<'div'> {\n defaultValue?: any;\n name?: string;\n value?: any;\n onChange?: (value: any) => void;\n /**\n * Direction of radio group\n */\n horizontal?: boolean;\n /**\n * Size of radio buttons within the group\n */\n size?: 'md' | 'sm';\n}\n\nexport const RadioGroup: VFC<RadioGroupProps> = ({\n children,\n defaultValue,\n name,\n value: valueProp,\n onChange,\n horizontal = false,\n size = 'md',\n ...elemProps\n}) => {\n const [value, setValue] = useControlled({\n controlledValue: valueProp,\n default: defaultValue,\n });\n\n return (\n <Container role='radiogroup' horizontal={horizontal} size={size} {...elemProps}>\n {/* @ts-expect-error [strict-migration] The following line is not strict; please fix! */}\n {Children.map(children, (child: ReactElement<RadioProps>) => {\n if (child?.type === Radio && (typeof valueProp !== 'undefined' || onChange)) {\n return cloneElement(child, {\n name,\n size,\n checked: child.props.value === value,\n onChange: (e: ChangeEvent<HTMLInputElement>) => {\n const newVal = e.target.value;\n if (typeof valueProp !== 'undefined' && onChange) {\n onChange(newVal);\n } else {\n setValue(newVal);\n }\n },\n });\n }\n\n if (name) {\n return cloneElement(child, { name });\n }\n\n return child;\n })}\n </Container>\n );\n};\n\nexport default RadioGroup;\n"],"mappings":";;;;;;;AAeA,MAAM,YAAY,OAAO,GAAgD;;qBAEpD,QAAQ,GAAG;;;KAG3B,EAAE,iBACH,cACA,GAAG;;;;wBAIiB,QAAQ,GAAG;;MAE7B;;AAkBN,MAAa,cAAoC,EAC/C,UACA,cACA,MACA,OAAO,WACP,UACA,aAAa,OACb,OAAO,MACP,GAAG,gBACC;CACJ,MAAM,CAAC,OAAO,YAAY,cAAc;EACtC,iBAAiB;EACjB,SAAS;EACV,CAAC;AAEF,QACE,oBAAC,WAAD;EAAW,MAAK;EAAyB;EAAkB;EAAM,GAAI;YAElE,SAAS,IAAI,WAAW,UAAoC;AAC3D,OAAI,OAAO,SAAS,UAAU,OAAO,cAAc,eAAe,UAChE,QAAO,aAAa,OAAO;IACzB;IACA;IACA,SAAS,MAAM,MAAM,UAAU;IAC/B,WAAW,MAAqC;KAC9C,MAAM,SAAS,EAAE,OAAO;AACxB,SAAI,OAAO,cAAc,eAAe,SACtC,UAAS,OAAO;SAEhB,UAAS,OAAO;;IAGrB,CAAC;AAGJ,OAAI,KACF,QAAO,aAAa,OAAO,EAAE,MAAM,CAAC;AAGtC,UAAO;IACP;EACQ,CAAA"}
@@ -1,6 +1,6 @@
1
1
  import { ExtensionWithMenuBar } from "./types7.mjs";
2
- import { FC } from "react";
3
2
  import * as _$styled_components0 from "styled-components";
3
+ import { FC } from "react";
4
4
  import { AnyExtension } from "@tiptap/core";
5
5
 
6
6
  //#region src/components/RichTextEditor/RichTextEditor.d.ts
@@ -1,5 +1,5 @@
1
- import { d as FilterRuleValue, f as FilterRuleValueChange, l as FilterOperator, o as FilterField, p as FilterSize, u as FilterRule } from "./types-BJqmRXFV.mjs";
2
- import { t as FieldRegistry } from "./FieldRegistry-CJwGpUVK.mjs";
1
+ import { d as FilterRuleValue, f as FilterRuleValueChange, l as FilterOperator, o as FilterField, p as FilterSize, u as FilterRule } from "./types-CnqmdPXi.mjs";
2
+ import { t as FieldRegistry } from "./FieldRegistry-CD8fjf9Z.mjs";
3
3
  import { ReactNode } from "react";
4
4
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
5
5
 
@@ -1,4 +1,4 @@
1
- import { n as CompoundExpression, p as FilterSize } from "./types-BJqmRXFV.mjs";
1
+ import { n as CompoundExpression, p as FilterSize } from "./types-CnqmdPXi.mjs";
2
2
  import * as _$react from "react";
3
3
  import { HTMLAttributes } from "react";
4
4
 
@@ -1,4 +1,4 @@
1
- import { i as TextAction, n as IconAction, r as MenuAction } from "./Action-CHWYwpYR.mjs";
1
+ import { i as TextAction, n as IconAction, r as MenuAction } from "./Action-sLO73eKq.mjs";
2
2
  import { ComponentPropsWithoutRef, FC, ReactElement, ReactNode } from "react";
3
3
 
4
4
  //#region src/components/CardV2/SectionHeading.d.ts
@@ -1,10 +1,10 @@
1
1
  import { a as styled } from "./styledComponentsInterop-Cs5CCPRy.mjs";
2
2
  import { semanticColor } from "./lib/semanticColor.mjs";
3
- import { paragraphMixins } from "./mixins/text.mjs";
4
3
  import "./variables/transitions.mjs";
5
- import { n as useFormField } from "./useFormField-pOVkb5BK.mjs";
6
- import { createContext, forwardRef, useContext, useEffect, useImperativeHandle, useRef } from "react";
4
+ import { paragraphMixins } from "./mixins/text.mjs";
5
+ import { n as useFormField } from "./useFormField-Cd9sH-HM.mjs";
7
6
  import { BorderRadius, Spacing } from "@persona/design-tokens";
7
+ import { createContext, forwardRef, useContext, useEffect, useImperativeHandle, useRef } from "react";
8
8
  import { ToggleButton, ToggleButtonGroup } from "react-aria-components";
9
9
  import { jsx } from "react/jsx-runtime";
10
10
  //#region src/components/SegmentedControl/SegmentedControl.tsx
@@ -120,4 +120,4 @@ const SegmentedControlItem = forwardRef(function SegmentedControlItem({ disabled
120
120
  //#endregion
121
121
  export { SegmentedControlItem as n, SegmentedControl as t };
122
122
 
123
- //# sourceMappingURL=SegmentedControl-BNOJ1FYQ.mjs.map
123
+ //# sourceMappingURL=SegmentedControl-CaQ2DJsa.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"SegmentedControl-BNOJ1FYQ.mjs","names":[],"sources":["../src/components/SegmentedControl/SegmentedControl.tsx"],"sourcesContent":["import {\n createContext,\n forwardRef,\n type Key,\n type ReactNode,\n useContext,\n useEffect,\n useImperativeHandle,\n useRef,\n} from 'react';\nimport { ToggleButton, ToggleButtonGroup, type ToggleButtonProps } from 'react-aria-components';\nimport styled from 'styled-components';\n\nimport { BorderRadius, Spacing } from '@persona/design-tokens';\n\nimport useFormField from '#src/components/FormControl/useFormField';\nimport { semanticColor } from '#src/lib/semanticColor';\nimport { paragraphMixins } from '#src/mixins/text';\nimport { TransitionDuration, TransitionEasing } from '#src/variables/transitions';\n\nconst SegmentedControlSizeContext = createContext<'sm' | 'md'>('md');\n\nexport interface SegmentedControlProps {\n id?: string;\n className?: string;\n\n /**\n * Current selected key (controlled)\n */\n selectedKey?: Key;\n\n /**\n * Default selected key (uncontrolled)\n */\n defaultSelectedKey?: Key;\n\n /**\n * Callback when selection changes\n */\n onSelectionChange?: (key: Key) => void;\n\n /**\n * Whether the entire component is disabled\n */\n disabled?: boolean;\n\n /**\n * Whether the component should take full width\n */\n fullWidth?: boolean;\n\n /**\n * Size of the segmented control\n */\n size?: 'sm' | 'md';\n\n /**\n * Accessible label for the group\n */\n 'aria-label'?: string;\n 'aria-required'?: boolean;\n\n /**\n * Segment components\n */\n children: ReactNode;\n}\n\ninterface StyledSegmentedControlProps {\n id?: string;\n $fullWidth?: boolean;\n $size?: 'sm' | 'md';\n}\n\nconst StyledSegmentedControl = styled(ToggleButtonGroup)<StyledSegmentedControlProps>`\n display: inline-flex;\n background-color: ${({ theme }) =>\n semanticColor(theme, 'ActionNeutral', theme.color.variants.basic.default)};\n border-radius: 5px;\n padding: 1px;\n width: ${({ $fullWidth }) => ($fullWidth ? '100%' : 'auto')};\n height: ${({ $size = 'md' }) => ($size === 'sm' ? '20px' : '24px')};\n`;\n\n/**\n * A segmented control component that allows users to select between multiple options.\n * Built with React Aria for accessibility and keyboard navigation.\n */\nexport const SegmentedControl = forwardRef<HTMLDivElement, SegmentedControlProps>(\n function SegmentedControl(\n {\n id,\n selectedKey,\n defaultSelectedKey,\n onSelectionChange,\n disabled,\n fullWidth = false,\n size = 'md',\n className,\n 'aria-label': ariaLabel,\n 'aria-required': ariaRequired,\n children,\n ...props\n },\n ref,\n ) {\n const field = useFormField({ inputId: id, disabled });\n const segmentedControlRef = useRef<HTMLDivElement>(null);\n const isRequired = ariaRequired;\n\n useImperativeHandle(ref, () => segmentedControlRef.current!, []);\n // react-aria-components filters aria-required from DOM props, so it is applied imperatively.\n useEffect(() => {\n if (isRequired) {\n segmentedControlRef.current?.setAttribute('aria-required', 'true');\n } else {\n segmentedControlRef.current?.removeAttribute('aria-required');\n }\n }, [isRequired]);\n\n return (\n <SegmentedControlSizeContext.Provider value={size}>\n <StyledSegmentedControl\n ref={segmentedControlRef}\n className={className}\n selectionMode='single'\n selectedKeys={selectedKey ? [selectedKey] : undefined}\n defaultSelectedKeys={defaultSelectedKey ? [defaultSelectedKey] : undefined}\n onSelectionChange={(keys) => {\n const key = Array.from(keys)[0];\n if (key && onSelectionChange) {\n onSelectionChange(key);\n }\n }}\n isDisabled={field.disabled}\n aria-label={ariaLabel}\n aria-labelledby={field.labelId}\n aria-describedby={field.helperTextId}\n aria-errormessage={field.hasError ? field.helperTextId : undefined}\n aria-invalid={field.hasError}\n $fullWidth={fullWidth}\n $size={size}\n {...props}\n id={field.inputId}\n >\n {children}\n </StyledSegmentedControl>\n </SegmentedControlSizeContext.Provider>\n );\n },\n);\n\nconst StyledSegment = styled(ToggleButton)<{ $size?: 'sm' | 'md' }>`\n ${paragraphMixins.sm};\n display: flex;\n align-items: center;\n justify-content: center;\n background-color: transparent;\n border: none;\n border-radius: ${BorderRadius.Md};\n color: ${({ theme }) => semanticColor(theme, 'FgSecondary', theme.color.text.secondary)};\n cursor: pointer;\n flex: 1;\n line-height: 1;\n\n & * {\n cursor: inherit;\n }\n padding: 0 ${({ $size = 'md' }) => ($size === 'sm' ? Spacing[1] : Spacing[2])};\n position: relative;\n transition-property: background-color, color, border-color, box-shadow;\n transition-duration: ${TransitionDuration.Fast};\n transition-timing-function: ${TransitionEasing.Move};\n white-space: nowrap;\n\n /* Hover state */\n &[data-hovered] {\n background-color: ${({ theme }) => semanticColor(theme, 'ActionNeutralHover', theme.color.variants.basic.hover)};\n }\n\n /* Selected state */\n &[data-selected] {\n background-color: ${({ theme }) => semanticColor(theme, 'SurfacePrimary', theme.color.primary.white)};\n box-shadow: inset 0 0 0 1px ${({ theme }) => semanticColor(theme, 'BorderDefault', theme.color.border.input)};\n color: ${({ theme }) => semanticColor(theme, 'FgPrimary', theme.color.text.primary)};\n }\n\n /* Disabled state */\n &[data-disabled] {\n cursor: not-allowed;\n opacity: 0.5;\n }\n\n /* Remove focus outline unless we're using a keyboard */\n &[data-focused]:not([data-focus-visible]) {\n outline: none;\n }\n`;\n\nexport interface SegmentedControlItemProps extends Omit<\n ToggleButtonProps,\n 'isDisabled' | 'style' | 'isSelected' | 'defaultSelected'\n> {\n /**\n * Whether this control item is disabled\n */\n disabled?: boolean;\n}\n\n/**\n * A segment item component for use within SegmentedControl.\n */\nconst SegmentedControlItem = forwardRef<HTMLButtonElement, SegmentedControlItemProps>(\n function SegmentedControlItem({ disabled, children, ...props }, ref) {\n const size = useContext(SegmentedControlSizeContext);\n return (\n <StyledSegment ref={ref} isDisabled={disabled} $size={size} {...props}>\n {children}\n </StyledSegment>\n );\n },\n);\n\nexport default SegmentedControl;\nexport { SegmentedControlItem };\n"],"mappings":";;;;;;;;;;AAoBA,MAAM,8BAA8B,cAA2B,KAAK;AAsDpE,MAAM,yBAAyB,OAAO,kBAAkB;;uBAEjC,EAAE,YACrB,cAAc,OAAO,iBAAiB,MAAM,MAAM,SAAS,MAAM,QAAQ,CAAC;;;YAGlE,EAAE,iBAAkB,aAAa,SAAS,OAAQ;aACjD,EAAE,QAAQ,WAAY,UAAU,OAAO,SAAS,OAAQ;;;;;;AAOrE,MAAa,mBAAmB,WAC9B,SAAS,iBACP,EACE,IACA,aACA,oBACA,mBACA,UACA,YAAY,OACZ,OAAO,MACP,WACA,cAAc,WACd,iBAAiB,cACjB,UACA,GAAG,SAEL,KACA;CACA,MAAM,QAAQ,aAAa;EAAE,SAAS;EAAI;EAAU,CAAC;CACrD,MAAM,sBAAsB,OAAuB,KAAK;CACxD,MAAM,aAAa;AAEnB,qBAAoB,WAAW,oBAAoB,SAAU,EAAE,CAAC;AAEhE,iBAAgB;AACd,MAAI,WACF,qBAAoB,SAAS,aAAa,iBAAiB,OAAO;MAElE,qBAAoB,SAAS,gBAAgB,gBAAgB;IAE9D,CAAC,WAAW,CAAC;AAEhB,QACE,oBAAC,4BAA4B,UAA7B;EAAsC,OAAO;YAC3C,oBAAC,wBAAD;GACE,KAAK;GACM;GACX,eAAc;GACd,cAAc,cAAc,CAAC,YAAY,GAAG,KAAA;GAC5C,qBAAqB,qBAAqB,CAAC,mBAAmB,GAAG,KAAA;GACjE,oBAAoB,SAAS;IAC3B,MAAM,MAAM,MAAM,KAAK,KAAK,CAAC;AAC7B,QAAI,OAAO,kBACT,mBAAkB,IAAI;;GAG1B,YAAY,MAAM;GAClB,cAAY;GACZ,mBAAiB,MAAM;GACvB,oBAAkB,MAAM;GACxB,qBAAmB,MAAM,WAAW,MAAM,eAAe,KAAA;GACzD,gBAAc,MAAM;GACpB,YAAY;GACZ,OAAO;GACP,GAAI;GACJ,IAAI,MAAM;GAET;GACsB,CAAA;EACY,CAAA;EAG5C;AAED,MAAM,gBAAgB,OAAO,aAAa;IACtC,gBAAgB,GAAG;;;;;;mBAMJ,aAAa,GAAG;YACvB,EAAE,YAAY,cAAc,OAAO,eAAe,MAAM,MAAM,KAAK,UAAU,CAAC;;;;;;;;gBAQ1E,EAAE,QAAQ,WAAY,UAAU,OAAO,QAAQ,KAAK,QAAQ,GAAI;;;iCAG/B;+DACK;;;;;yBAK7B,EAAE,YAAY,cAAc,OAAO,sBAAsB,MAAM,MAAM,SAAS,MAAM,MAAM,CAAC;;;;;yBAK3F,EAAE,YAAY,cAAc,OAAO,kBAAkB,MAAM,MAAM,QAAQ,MAAM,CAAC;mCACtE,EAAE,YAAY,cAAc,OAAO,iBAAiB,MAAM,MAAM,OAAO,MAAM,CAAC;cACnG,EAAE,YAAY,cAAc,OAAO,aAAa,MAAM,MAAM,KAAK,QAAQ,CAAC;;;;;;;;;;;;;;;;;AA4BxF,MAAM,uBAAuB,WAC3B,SAAS,qBAAqB,EAAE,UAAU,UAAU,GAAG,SAAS,KAAK;AAEnE,QACE,oBAAC,eAAD;EAAoB;EAAK,YAAY;EAAU,OAFpC,WAAW,4BAEoC;EAAE,GAAI;EAC7D;EACa,CAAA;EAGrB"}
1
+ {"version":3,"file":"SegmentedControl-CaQ2DJsa.mjs","names":[],"sources":["../src/components/SegmentedControl/SegmentedControl.tsx"],"sourcesContent":["import {\n createContext,\n forwardRef,\n type Key,\n type ReactNode,\n useContext,\n useEffect,\n useImperativeHandle,\n useRef,\n} from 'react';\nimport { ToggleButton, ToggleButtonGroup, type ToggleButtonProps } from 'react-aria-components';\nimport styled from 'styled-components';\n\nimport { BorderRadius, Spacing } from '@persona/design-tokens';\n\nimport useFormField from '#src/components/FormControl/useFormField';\nimport { semanticColor } from '#src/lib/semanticColor';\nimport { paragraphMixins } from '#src/mixins/text';\nimport { TransitionDuration, TransitionEasing } from '#src/variables/transitions';\n\nconst SegmentedControlSizeContext = createContext<'sm' | 'md'>('md');\n\nexport interface SegmentedControlProps {\n id?: string;\n className?: string;\n\n /**\n * Current selected key (controlled)\n */\n selectedKey?: Key;\n\n /**\n * Default selected key (uncontrolled)\n */\n defaultSelectedKey?: Key;\n\n /**\n * Callback when selection changes\n */\n onSelectionChange?: (key: Key) => void;\n\n /**\n * Whether the entire component is disabled\n */\n disabled?: boolean;\n\n /**\n * Whether the component should take full width\n */\n fullWidth?: boolean;\n\n /**\n * Size of the segmented control\n */\n size?: 'sm' | 'md';\n\n /**\n * Accessible label for the group\n */\n 'aria-label'?: string;\n 'aria-required'?: boolean;\n\n /**\n * Segment components\n */\n children: ReactNode;\n}\n\ninterface StyledSegmentedControlProps {\n id?: string;\n $fullWidth?: boolean;\n $size?: 'sm' | 'md';\n}\n\nconst StyledSegmentedControl = styled(ToggleButtonGroup)<StyledSegmentedControlProps>`\n display: inline-flex;\n background-color: ${({ theme }) =>\n semanticColor(theme, 'ActionNeutral', theme.color.variants.basic.default)};\n border-radius: 5px;\n padding: 1px;\n width: ${({ $fullWidth }) => ($fullWidth ? '100%' : 'auto')};\n height: ${({ $size = 'md' }) => ($size === 'sm' ? '20px' : '24px')};\n`;\n\n/**\n * A segmented control component that allows users to select between multiple options.\n * Built with React Aria for accessibility and keyboard navigation.\n */\nexport const SegmentedControl = forwardRef<HTMLDivElement, SegmentedControlProps>(\n function SegmentedControl(\n {\n id,\n selectedKey,\n defaultSelectedKey,\n onSelectionChange,\n disabled,\n fullWidth = false,\n size = 'md',\n className,\n 'aria-label': ariaLabel,\n 'aria-required': ariaRequired,\n children,\n ...props\n },\n ref,\n ) {\n const field = useFormField({ inputId: id, disabled });\n const segmentedControlRef = useRef<HTMLDivElement>(null);\n const isRequired = ariaRequired;\n\n useImperativeHandle(ref, () => segmentedControlRef.current!, []);\n // react-aria-components filters aria-required from DOM props, so it is applied imperatively.\n useEffect(() => {\n if (isRequired) {\n segmentedControlRef.current?.setAttribute('aria-required', 'true');\n } else {\n segmentedControlRef.current?.removeAttribute('aria-required');\n }\n }, [isRequired]);\n\n return (\n <SegmentedControlSizeContext.Provider value={size}>\n <StyledSegmentedControl\n ref={segmentedControlRef}\n className={className}\n selectionMode='single'\n selectedKeys={selectedKey ? [selectedKey] : undefined}\n defaultSelectedKeys={defaultSelectedKey ? [defaultSelectedKey] : undefined}\n onSelectionChange={(keys) => {\n const key = Array.from(keys)[0];\n if (key && onSelectionChange) {\n onSelectionChange(key);\n }\n }}\n isDisabled={field.disabled}\n aria-label={ariaLabel}\n aria-labelledby={field.labelId}\n aria-describedby={field.helperTextId}\n aria-errormessage={field.hasError ? field.helperTextId : undefined}\n aria-invalid={field.hasError}\n $fullWidth={fullWidth}\n $size={size}\n {...props}\n id={field.inputId}\n >\n {children}\n </StyledSegmentedControl>\n </SegmentedControlSizeContext.Provider>\n );\n },\n);\n\nconst StyledSegment = styled(ToggleButton)<{ $size?: 'sm' | 'md' }>`\n ${paragraphMixins.sm};\n display: flex;\n align-items: center;\n justify-content: center;\n background-color: transparent;\n border: none;\n border-radius: ${BorderRadius.Md};\n color: ${({ theme }) => semanticColor(theme, 'FgSecondary', theme.color.text.secondary)};\n cursor: pointer;\n flex: 1;\n line-height: 1;\n\n & * {\n cursor: inherit;\n }\n padding: 0 ${({ $size = 'md' }) => ($size === 'sm' ? Spacing[1] : Spacing[2])};\n position: relative;\n transition-property: background-color, color, border-color, box-shadow;\n transition-duration: ${TransitionDuration.Fast};\n transition-timing-function: ${TransitionEasing.Move};\n white-space: nowrap;\n\n /* Hover state */\n &[data-hovered] {\n background-color: ${({ theme }) => semanticColor(theme, 'ActionNeutralHover', theme.color.variants.basic.hover)};\n }\n\n /* Selected state */\n &[data-selected] {\n background-color: ${({ theme }) => semanticColor(theme, 'SurfacePrimary', theme.color.primary.white)};\n box-shadow: inset 0 0 0 1px ${({ theme }) => semanticColor(theme, 'BorderDefault', theme.color.border.input)};\n color: ${({ theme }) => semanticColor(theme, 'FgPrimary', theme.color.text.primary)};\n }\n\n /* Disabled state */\n &[data-disabled] {\n cursor: not-allowed;\n opacity: 0.5;\n }\n\n /* Remove focus outline unless we're using a keyboard */\n &[data-focused]:not([data-focus-visible]) {\n outline: none;\n }\n`;\n\nexport interface SegmentedControlItemProps extends Omit<\n ToggleButtonProps,\n 'isDisabled' | 'style' | 'isSelected' | 'defaultSelected'\n> {\n /**\n * Whether this control item is disabled\n */\n disabled?: boolean;\n}\n\n/**\n * A segment item component for use within SegmentedControl.\n */\nconst SegmentedControlItem = forwardRef<HTMLButtonElement, SegmentedControlItemProps>(\n function SegmentedControlItem({ disabled, children, ...props }, ref) {\n const size = useContext(SegmentedControlSizeContext);\n return (\n <StyledSegment ref={ref} isDisabled={disabled} $size={size} {...props}>\n {children}\n </StyledSegment>\n );\n },\n);\n\nexport default SegmentedControl;\nexport { SegmentedControlItem };\n"],"mappings":";;;;;;;;;;AAoBA,MAAM,8BAA8B,cAA2B,KAAK;AAsDpE,MAAM,yBAAyB,OAAO,kBAAkB;;uBAEjC,EAAE,YACrB,cAAc,OAAO,iBAAiB,MAAM,MAAM,SAAS,MAAM,QAAQ,CAAC;;;YAGlE,EAAE,iBAAkB,aAAa,SAAS,OAAQ;aACjD,EAAE,QAAQ,WAAY,UAAU,OAAO,SAAS,OAAQ;;;;;;AAOrE,MAAa,mBAAmB,WAC9B,SAAS,iBACP,EACE,IACA,aACA,oBACA,mBACA,UACA,YAAY,OACZ,OAAO,MACP,WACA,cAAc,WACd,iBAAiB,cACjB,UACA,GAAG,SAEL,KACA;CACA,MAAM,QAAQ,aAAa;EAAE,SAAS;EAAI;EAAU,CAAC;CACrD,MAAM,sBAAsB,OAAuB,KAAK;CACxD,MAAM,aAAa;AAEnB,qBAAoB,WAAW,oBAAoB,SAAU,EAAE,CAAC;AAEhE,iBAAgB;AACd,MAAI,WACF,qBAAoB,SAAS,aAAa,iB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ACE,oBAAC,eAAD;EAAoB;EAAK,YAAY;EAAU,OAFpC,WAAW,4BAEoC;EAAE,GAAI;EAC7D;EACa,CAAA;EAGrB"}
@@ -1,19 +1,19 @@
1
1
  import { a as styled, r as css } from "./styledComponentsInterop-Cs5CCPRy.mjs";
2
- import { semanticColor } from "./lib/semanticColor.mjs";
3
- import { paragraphMixins } from "./mixins/text.mjs";
4
- import { i as Paragraph } from "./Text-D0vEReED.mjs";
5
2
  import { isNotDisabled } from "./lib/pseudoClass.mjs";
6
- import { Z_INDICES } from "./lib/zindex.mjs";
3
+ import { semanticColor } from "./lib/semanticColor.mjs";
7
4
  import inputMixin from "./mixins/input.mjs";
8
5
  import { popoverMotion } from "./mixins/motion.mjs";
9
6
  import { semanticScrollbar } from "./mixins/scrollbar.mjs";
7
+ import { paragraphMixins } from "./mixins/text.mjs";
8
+ import { i as Paragraph } from "./Text-D0vEReED.mjs";
9
+ import { Z_INDICES } from "./lib/zindex.mjs";
10
10
  import { t as HStack } from "./Stack-Bzom2BTR.mjs";
11
- import { t as IconButton } from "./IconButton-Bj1fry_K.mjs";
12
- import { n as useFormField } from "./useFormField-pOVkb5BK.mjs";
13
- import { c as MenuList, i as Menu, o as MenuHeading, s as MenuItem } from "./Menu-BVn1jh46.mjs";
14
- import { n as DropdownMenu_default } from "./DropdownMenu-Ip75l4Th.mjs";
15
- import { forwardRef } from "react";
11
+ import { t as IconButton } from "./IconButton-kSjnfhWt.mjs";
12
+ import { n as useFormField } from "./useFormField-Cd9sH-HM.mjs";
13
+ import { c as MenuList, i as Menu, o as MenuHeading, s as MenuItem } from "./Menu-DQPxDJ11.mjs";
14
+ import { n as DropdownMenu_default } from "./DropdownMenu-CYZTQS02.mjs";
16
15
  import { Color, Spacing } from "@persona/design-tokens";
16
+ import { forwardRef } from "react";
17
17
  import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
18
18
  import { CaretDownIcon, MoreIcon } from "@persona/icons";
19
19
  import { useId } from "react-aria";
@@ -246,4 +246,4 @@ const Option = forwardRef(function Option({ children, subtitle, ...props }, forw
246
246
  //#endregion
247
247
  export { Select as n, SelectHeader as r, Option as t };
248
248
 
249
- //# sourceMappingURL=Select-DbWEgH5c.mjs.map
249
+ //# sourceMappingURL=Select-Bicuj8VD.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"Select-DbWEgH5c.mjs","names":["DropdownMenu"],"sources":["../src/components/Select/Select.tsx"],"sourcesContent":["import * as SelectPrimitive from '@radix-ui/react-select';\nimport type { Property } from 'csstype';\nimport { forwardRef, type ReactNode } from 'react';\nimport { useId } from 'react-aria';\nimport styled, { css } from 'styled-components';\n\nimport { Color, Spacing } from '@persona/design-tokens';\nimport { CaretDownIcon, MoreIcon } from '@persona/icons';\n\nimport { IconButton } from '#src/components/Button';\nimport DropdownMenu from '#src/components/DropdownMenu';\nimport useFormField from '#src/components/FormControl/useFormField';\nimport Menu, {\n MenuHeading,\n MenuItem,\n type MenuItemProps,\n MenuList,\n type MenuProps,\n} from '#src/components/Menu';\nimport { HStack } from '#src/components/Stack';\nimport { Paragraph } from '#src/components/Text';\nimport { isNotDisabled } from '#src/lib/pseudoClass';\nimport { semanticColor } from '#src/lib/semanticColor';\nimport { Z_INDICES } from '#src/lib/zindex';\nimport inputMixin, { type InputMixinProps, type InputSizes } from '#src/mixins/input';\nimport { popoverMotion } from '#src/mixins/motion';\nimport { semanticScrollbar } from '#src/mixins/scrollbar';\nimport { paragraphMixins } from '#src/mixins/text';\n\nexport interface SelectProps extends InputMixinProps, Omit<SelectPrimitive.SelectProps, 'value'> {\n 'aria-label'?: string;\n placeholder?: string;\n\n /**\n * id will be applied to trigger\n */\n id?: string;\n\n /**\n * Class name will be applied to trigger\n */\n className?: string;\n\n /**\n * Max height of options menu\n */\n maxHeight?: number;\n\n /**\n * Min width of the select\n */\n minWidth?: number;\n\n /**\n * Width of the selected value container\n */\n valueContainerWidth?: 'auto' | '100%';\n\n /**\n * Render dropdown menu in a portal.\n */\n portal?: boolean;\n\n /**\n * Element the portalled menu renders into. Defaults to `document.body`. Pass a container inside\n * the current dialog so the menu escapes clipping ancestors without leaving the dialog's\n * dismiss scope, which would close it on click. Requires `portal`.\n */\n portalContainer?: HTMLElement | null;\n\n /**\n * Props to apply to Radix Select.Trigger within\n */\n triggerProps?: SelectPrimitive.SelectTriggerProps;\n\n /**\n * Props to apply to Radix Select.Content within\n */\n contentProps?: SelectPrimitive.SelectContentProps;\n\n /**\n * Callback meant for use with `react-hook-form`'s `useForm` (or Persona's `useFormSecurely`)\n */\n onChange?: (event: { target: { value: string } }) => void;\n\n size?: InputSizes;\n\n value?: string | null;\n\n width?: string;\n\n header?: ReactNode;\n\n footer?: ReactNode;\n\n /**\n * z-index of content. Please use sparingly.\n */\n zIndex?: Property.ZIndex;\n}\n\ninterface SelectButtonProps extends InputMixinProps {\n isSelectingPlaceholder: boolean;\n $width?: string;\n $minWidth?: number;\n}\n\nconst SelectButton = styled('button')<SelectButtonProps>`\n ${inputMixin};\n display: inline-flex;\n position: relative;\n align-items: center;\n outline: none;\n appearance: none;\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n padding-right: ${Spacing[6]};\n width: ${({ $width }) => $width ?? '100%'};\n min-width: ${({ $minWidth }) => ($minWidth != null ? `${$minWidth}px` : 'auto')};\n\n &${isNotDisabled} {\n cursor: pointer;\n }\n\n ${({ theme, isSelectingPlaceholder, disabled }) =>\n isSelectingPlaceholder &&\n !disabled &&\n css`\n color: ${semanticColor(theme, 'FgSecondary', theme.color.text.secondary)};\n `}\n`;\n\ninterface SelectValueContainerProps {\n width?: string;\n}\n\nconst SelectValueContainer = styled.span<SelectValueContainerProps>`\n text-overflow: ellipsis;\n min-width: 0px;\n overflow: hidden;\n text-align: start;\n\n ${({ width }) =>\n width &&\n css`\n width: ${width};\n `}\n`;\n\nconst OptionSubtitle = styled.div`\n color: ${({ theme }) => semanticColor(theme, 'FgSecondary', theme.color.text.secondary)};\n font-size: ${({ theme }) => theme.text.paragraph.sm.fontSize};\n margin-top: ${Spacing[1]};\n`;\n\ninterface OptionsMenuProps {\n maxHeight?: number;\n size?: InputSizes;\n}\n\nconst OptionsMenu = styled(Menu)<OptionsMenuProps>`\n width: var(--radix-select-trigger-width);\n max-height: ${({ maxHeight }) => maxHeight ?? '225px !important'};\n overflow-y: auto;\n ${semanticScrollbar}\n margin-bottom: 0;\n\n ${({ size }) => {\n switch (size) {\n case 'md': {\n return css`\n ${MenuList} {\n padding: ${Spacing[2]};\n }\n\n ${OptionItem} {\n ${paragraphMixins.md};\n padding: ${Spacing[2]};\n }\n\n ${MenuHeading} {\n padding: ${Spacing[2]};\n }\n `;\n }\n case 'sm': {\n return css`\n ${MenuList} {\n padding: ${Spacing[1]};\n }\n\n ${OptionItem} {\n ${paragraphMixins.sm};\n padding: ${Spacing[1]};\n }\n\n ${MenuHeading} {\n padding: ${Spacing[1]};\n }\n `;\n }\n }\n }}\n`;\n\nconst SelectContent = styled(SelectPrimitive.Content)<{ $zIndex?: number | string }>`\n ${popoverMotion('--radix-select-content-transform-origin')}\n z-index: ${({ $zIndex }) => $zIndex || Z_INDICES.dropdown};\n`;\n\nconst SelectHeaderContainer = styled(HStack)`\n display: flex;\n justify-content: space-between;\n padding: ${Spacing[1]} ${Spacing[1]} 0 ${Spacing[1]};\n margin-bottom: ${Spacing[1]};\n`;\n\nconst SelectFooter = styled.div`\n padding: ${Spacing[1]} 0;\n margin-top: ${Spacing[1]};\n border-top: 1px solid ${({ theme }) => semanticColor(theme, 'BorderSubtle', Color.BorderDivider)};\n`;\n\nconst SelectMenu = forwardRef<HTMLUListElement, MenuProps & OptionsMenuProps>(function SelectMenu(\n props: MenuProps,\n forwardedRef,\n) {\n return <OptionsMenu listRef={forwardedRef} {...props} />;\n});\n\nconst OptionItem = styled(MenuItem)`\n ${paragraphMixins.md};\n padding: ${Spacing[4]};\n`;\n\nconst SelectItem = forwardRef<HTMLDivElement, MenuItemProps>(function SelectItem(\n props: MenuItemProps,\n forwardedRef,\n) {\n return <OptionItem ref={forwardedRef} {...props} />;\n});\n\nconst StyledIconContainer = styled(SelectPrimitive.Icon)<{ disabled?: boolean }>`\n position: absolute;\n right: ${Spacing[2]};\n display: flex;\n justify-content: center;\n\n ${({ theme, disabled }) => css`\n color: ${\n disabled\n ? semanticColor(theme, 'FgDisabled', Color.BorderIconDisabled)\n : semanticColor(theme, 'FgPrimary', Color.BorderIconPrimary)\n };\n `}\n`;\n\ninterface SelectHeaderProps {\n title?: ReactNode;\n menuItems?: ReactNode;\n menuTriggerLabel?: string;\n}\n\nexport const SelectHeader = ({ title, menuItems, menuTriggerLabel }: SelectHeaderProps) => {\n const uniqueId = useId();\n\n return (\n <SelectHeaderContainer align='center'>\n {title && (\n <Paragraph color='primary' weight='bold' size='md'>\n {title}\n </Paragraph>\n )}\n {menuItems && (\n <DropdownMenu\n portal={true}\n trigger={\n <IconButton>\n <MoreIcon />\n </IconButton>\n }\n triggerProps={{\n 'aria-label': menuTriggerLabel,\n id: `select-header-menu-trigger-${uniqueId}`,\n }}\n side='right'\n align='start'\n zIndex={Z_INDICES.layeredDropdown}\n contentProps={{\n // Fix for Radix UI 2.1.15 upgrade breaking changes:\n // 1. Portal rendering causes pointer-events issues preventing dropdown interaction\n // 2. Portal timing causes onFocusOutside to fire immediately, closing dropdown\n style: {\n pointerEvents: 'auto', // Ensure dropdown items receive mouse events\n },\n onFocusOutside: (event) => event.preventDefault(), // Prevent immediate portal closing\n }}\n >\n {menuItems}\n </DropdownMenu>\n )}\n </SelectHeaderContainer>\n );\n};\n\nexport const Select = forwardRef<HTMLButtonElement, SelectProps>(function Select(\n { portal = false, portalContainer, size = 'md', ...props }: SelectProps,\n forwardedRef,\n) {\n const {\n 'aria-label': ariaLabel,\n hasError,\n hasWarning,\n focused,\n active,\n hovered,\n disabled,\n placeholder,\n maxHeight,\n children,\n triggerProps,\n contentProps,\n id,\n className,\n onChange,\n onValueChange,\n value,\n width,\n header,\n footer,\n minWidth,\n valueContainerWidth,\n zIndex,\n } = props;\n\n const field = useFormField({ inputId: props.id, disabled, hasWarning, hasError });\n\n const content = (\n <SelectContent\n position='popper'\n side='bottom'\n sideOffset={8}\n $zIndex={zIndex}\n {...contentProps}\n >\n <SelectMenu maxHeight={maxHeight} size={size}>\n {header}\n <SelectPrimitive.Viewport>{children}</SelectPrimitive.Viewport>\n {footer && (\n <>\n <SelectFooter>{footer}</SelectFooter>\n </>\n )}\n </SelectMenu>\n </SelectContent>\n );\n\n return (\n <SelectPrimitive.Root\n {...props}\n onValueChange={(value) => {\n onChange?.({ target: { value } });\n onValueChange?.(value);\n }}\n // Custom behavior to consider null as empty value\n value={value === null ? '' : value}\n >\n <SelectPrimitive.Trigger\n ref={forwardedRef}\n asChild\n id={id}\n className={className}\n disabled={field.disabled}\n aria-describedby={field.helperTextId}\n aria-errormessage={field.hasError ? field.helperTextId : undefined}\n aria-invalid={field.hasError}\n aria-label={ariaLabel}\n {...triggerProps}\n >\n <SelectButton\n hasWarning={field.hasWarning}\n hasError={field.hasError}\n hovered={hovered}\n focused={focused}\n active={active}\n disabled={field.disabled}\n placeholder={placeholder}\n isSelectingPlaceholder={props.value === '' || props.value == null}\n $minWidth={minWidth}\n $size={size}\n $width={width}\n >\n <SelectValueContainer width={valueContainerWidth}>\n <SelectPrimitive.Value placeholder={placeholder} />\n </SelectValueContainer>\n <StyledIconContainer disabled={field.disabled}>\n <CaretDownIcon />\n </StyledIconContainer>\n </SelectButton>\n </SelectPrimitive.Trigger>\n {portal ? (\n <SelectPrimitive.Portal container={portalContainer}>{content}</SelectPrimitive.Portal>\n ) : (\n content\n )}\n </SelectPrimitive.Root>\n );\n});\n\nexport default Select;\n\nexport const Option = forwardRef<HTMLDivElement, SelectPrimitive.SelectItemProps & MenuItemProps>(\n function Option({ children, subtitle, ...props }, forwardedRef) {\n return (\n <SelectPrimitive.Item {...props} ref={forwardedRef} asChild>\n <SelectItem {...props}>\n <SelectPrimitive.ItemText>{children}</SelectPrimitive.ItemText>\n {subtit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UAAU,MAAM;eACnC,oBAAC,eAAD,EAAiB,CAAA;KACG,CAAA,CACT;;GACS,CAAA,EACzB,SACC,oBAAC,gBAAgB,QAAjB;GAAwB,WAAW;aAAkB;GAAiC,CAAA,GAEtF,QAEmB;;EAEzB;AAIF,MAAa,SAAS,WACpB,SAAS,OAAO,EAAE,UAAU,UAAU,GAAG,SAAS,cAAc;AAC9D,QACE,oBAAC,gBAAgB,MAAjB;EAAsB,GAAI;EAAO,KAAK;EAAc,SAAA;YAClD,qBAAC,YAAD;GAAY,GAAI;aAAhB,CACE,oBAAC,gBAAgB,UAAjB,EAA2B,UAAoC,CAAA,EAC9D,YAAY,oBAAC,gBAAD,EAAA,UAAiB,UAA0B,CAAA,CAC7C;;EACQ,CAAA;EAG5B"}
1
+ {"version":3,"file":"Select-Bicuj8VD.mjs","names":["DropdownMenu"],"sources":["../src/components/Select/Select.tsx"],"sourcesContent":["import * as SelectPrimitive from '@radix-ui/react-select';\nimport type { Property } from 'csstype';\nimport { forwardRef, type ReactNode } from 'react';\nimport { useId } from 'react-aria';\nimport styled, { css } from 'styled-components';\n\nimport { Color, Spacing } from '@persona/design-tokens';\nimport { CaretDownIcon, MoreIcon } from '@persona/icons';\n\nimport { IconButton } from '#src/components/Button';\nimport DropdownMenu from '#src/components/DropdownMenu';\nimport useFormField from '#src/components/FormControl/useFormField';\nimport Menu, {\n MenuHeading,\n MenuItem,\n type MenuItemProps,\n MenuList,\n type MenuProps,\n} from '#src/components/Menu';\nimport { HStack } from '#src/components/Stack';\nimport { Paragraph } from '#src/components/Text';\nimport { isNotDisabled } from '#src/lib/pseudoClass';\nimport { semanticColor } from '#src/lib/semanticColor';\nimport { Z_INDICES } from '#src/lib/zindex';\nimport inputMixin, { type InputMixinProps, type InputSizes } from '#src/mixins/input';\nimport { popoverMotion } from '#src/mixins/motion';\nimport { semanticScrollbar } from '#src/mixins/scrollbar';\nimport { paragraphMixins } from '#src/mixins/text';\n\nexport interface SelectProps extends InputMixinProps, Omit<SelectPrimitive.SelectProps, 'value'> {\n 'aria-label'?: string;\n placeholder?: string;\n\n /**\n * id will be applied to trigger\n */\n id?: string;\n\n /**\n * Class name will be applied to trigger\n */\n className?: string;\n\n /**\n * Max height of options menu\n */\n maxHeight?: number;\n\n /**\n * Min width of the select\n */\n minWidth?: number;\n\n /**\n * Width of the selected value container\n */\n valueContainerWidth?: 'auto' | '100%';\n\n /**\n * Render dropdown menu in a portal.\n */\n portal?: boolean;\n\n /**\n * Element the portalled menu renders into. Defaults to `document.body`. Pass a container inside\n * the current dialog so the menu escapes clipping ancestors without leaving the dialog's\n * dismiss scope, which would close it on click. Requires `portal`.\n */\n portalContainer?: HTMLElement | null;\n\n /**\n * Props to apply to Radix Select.Trigger within\n */\n triggerProps?: SelectPrimitive.SelectTriggerProps;\n\n /**\n * Props to apply to Radix Select.Content within\n */\n contentProps?: SelectPrimitive.SelectContentProps;\n\n /**\n * Callback meant for use with `react-hook-form`'s `useForm` (or Persona's `useFormSecurely`)\n */\n onChange?: (event: { target: { value: string } }) => void;\n\n size?: InputSizes;\n\n value?: string | null;\n\n width?: string;\n\n header?: ReactNode;\n\n footer?: ReactNode;\n\n /**\n * z-index of content. Please use sparingly.\n */\n zIndex?: Property.ZIndex;\n}\n\ninterface SelectButtonProps extends InputMixinProps {\n isSelectingPlaceholder: boolean;\n $width?: string;\n $minWidth?: number;\n}\n\nconst SelectButton = styled('button')<SelectButtonProps>`\n ${inputMixin};\n display: inline-flex;\n position: relative;\n align-items: center;\n outline: none;\n appearance: none;\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n padding-right: ${Spacing[6]};\n width: ${({ $width }) => $width ?? '100%'};\n min-width: ${({ $minWidth }) => ($minWidth != null ? `${$minWidth}px` : 'auto')};\n\n &${isNotDisabled} {\n cursor: pointer;\n }\n\n ${({ theme, isSelectingPlaceholder, disabled }) =>\n isSelectingPlaceholder &&\n !disabled &&\n css`\n color: ${semanticColor(theme, 'FgSecondary', theme.color.text.secondary)};\n `}\n`;\n\ninterface SelectValueContainerProps {\n width?: string;\n}\n\nconst SelectValueContainer = styled.span<SelectValueContainerProps>`\n text-overflow: ellipsis;\n min-width: 0px;\n overflow: hidden;\n text-align: start;\n\n ${({ width }) =>\n width &&\n css`\n width: ${width};\n `}\n`;\n\nconst OptionSubtitle = styled.div`\n color: ${({ theme }) => semanticColor(theme, 'FgSecondary', theme.color.text.secondary)};\n font-size: ${({ theme }) => theme.text.paragraph.sm.fontSize};\n margin-top: ${Spacing[1]};\n`;\n\ninterface OptionsMenuProps {\n maxHeight?: number;\n size?: InputSizes;\n}\n\nconst OptionsMenu = styled(Menu)<OptionsMenuProps>`\n width: var(--radix-select-trigger-width);\n max-height: ${({ maxHeight }) => maxHeight ?? '225px !important'};\n overflow-y: auto;\n ${semanticScrollbar}\n margin-bottom: 0;\n\n ${({ size }) => {\n switch (size) {\n case 'md': {\n return css`\n ${MenuList} {\n padding: ${Spacing[2]};\n }\n\n ${OptionItem} {\n ${paragraphMixins.md};\n padding: ${Spacing[2]};\n }\n\n ${MenuHeading} {\n padding: ${Spacing[2]};\n }\n `;\n }\n case 'sm': {\n return css`\n ${MenuList} {\n padding: ${Spacing[1]};\n }\n\n ${OptionItem} {\n ${paragraphMixins.sm};\n padding: ${Spacing[1]};\n }\n\n ${MenuHeading} {\n padding: ${Spacing[1]};\n }\n `;\n }\n }\n }}\n`;\n\nconst SelectContent = styled(SelectPrimitive.Content)<{ $zIndex?: number | string }>`\n ${popoverMotion('--radix-select-content-transform-origin')}\n z-index: ${({ $zIndex }) => $zIndex || Z_INDICES.dropdown};\n`;\n\nconst SelectHeaderContainer = styled(HStack)`\n display: flex;\n justify-content: space-between;\n padding: ${Spacing[1]} ${Spacing[1]} 0 ${Spacing[1]};\n margin-bottom: ${Spacing[1]};\n`;\n\nconst SelectFooter = styled.div`\n padding: ${Spacing[1]} 0;\n margin-top: ${Spacing[1]};\n border-top: 1px solid ${({ theme }) => semanticColor(theme, 'BorderSubtle', Color.BorderDivider)};\n`;\n\nconst SelectMenu = forwardRef<HTMLUListElement, MenuProps & OptionsMenuProps>(function SelectMenu(\n props: MenuProps,\n forwardedRef,\n) {\n return <OptionsMenu listRef={forwardedRef} {...props} />;\n});\n\nconst OptionItem = styled(MenuItem)`\n ${paragraphMixins.md};\n padding: ${Spacing[4]};\n`;\n\nconst SelectItem = forwardRef<HTMLDivElement, MenuItemProps>(function SelectItem(\n props: MenuItemProps,\n forwardedRef,\n) {\n return <OptionItem ref={forwardedRef} {...props} />;\n});\n\nconst StyledIconContainer = styled(SelectPrimitive.Icon)<{ disabled?: boolean }>`\n position: absolute;\n right: ${Spacing[2]};\n display: flex;\n justify-content: center;\n\n ${({ theme, disabled }) => css`\n color: ${\n disabled\n ? semanticColor(theme, 'FgDisabled', Color.BorderIconDisabled)\n : semanticColor(theme, 'FgPrimary', Color.BorderIconPrimary)\n };\n `}\n`;\n\ninterface SelectHeaderProps {\n title?: ReactNode;\n menuItems?: ReactNode;\n menuTriggerLabel?: string;\n}\n\nexport const SelectHeader = ({ title, menuItems, menuTriggerLabel }: SelectHeaderProps) => {\n const uniqueId = useId();\n\n return (\n <SelectHeaderContainer align='center'>\n {title && (\n <Paragraph color='primary' weight='bold' size='md'>\n {title}\n </Paragraph>\n )}\n {menuItems && (\n <DropdownMenu\n portal={true}\n trigger={\n <IconButton>\n <MoreIcon />\n </IconButton>\n }\n triggerProps={{\n 'aria-label': menuTriggerLabel,\n id: `select-header-menu-trigger-${uniqueId}`,\n }}\n side='right'\n align='start'\n zIndex={Z_INDICES.layeredDropdown}\n contentProps={{\n // Fix for Radix UI 2.1.15 upgrade breaking changes:\n // 1. Portal rendering causes pointer-events issues preventing dropdown interaction\n // 2. Portal timing causes onFocusOutside to fire immediately, closing dropdown\n style: {\n pointerEvents: 'auto', // Ensure dropdown items receive mouse events\n },\n onFocusOutside: (event) => event.preventDefault(), // Prevent immediate portal closing\n }}\n >\n {menuItems}\n </DropdownMenu>\n )}\n </SelectHeaderContainer>\n );\n};\n\nexport const Select = forwardRef<HTMLButtonElement, SelectProps>(function Select(\n { portal = false, portalContainer, size = 'md', ...props }: SelectProps,\n forwardedRef,\n) {\n const {\n 'aria-label': ariaLabel,\n hasError,\n hasWarning,\n focused,\n active,\n hovered,\n disabled,\n placeholder,\n maxHeight,\n children,\n triggerProps,\n contentProps,\n id,\n className,\n onChange,\n onValueChange,\n value,\n width,\n header,\n footer,\n minWidth,\n valueContainerWidth,\n zIndex,\n } = props;\n\n const field = useFormField({ inputId: props.id, disabled, hasWarning, hasError });\n\n const content = (\n <SelectContent\n position='popper'\n side='bottom'\n sideOffset={8}\n $zIndex={zIndex}\n {...contentProps}\n >\n <SelectMenu maxHeight={maxHeight} size={size}>\n {header}\n <SelectPrimitive.Viewport>{children}</SelectPrimitive.Viewport>\n {footer && (\n <>\n <SelectFooter>{footer}</SelectFooter>\n </>\n )}\n </SelectMenu>\n </SelectContent>\n );\n\n return (\n <SelectPrimitive.Root\n {...props}\n onValueChange={(value) => {\n onChange?.({ target: { value } });\n onValueChange?.(value);\n }}\n // Custom behavior to consider null as empty value\n value={value === null ? '' : value}\n >\n <SelectPrimitive.Trigger\n ref={forwardedRef}\n asChild\n id={id}\n className={className}\n disabled={field.disabled}\n aria-describedby={field.helperTextId}\n aria-errormessage={field.hasError ? field.helperTextId : undefined}\n aria-invalid={field.hasError}\n aria-label={ariaLabel}\n {...triggerProps}\n >\n <SelectButton\n hasWarning={field.hasWarning}\n hasError={field.hasError}\n hovered={hovered}\n focused={focused}\n active={active}\n disabled={field.disabled}\n placeholder={placeholder}\n isSelectingPlaceholder={props.value === '' || props.value == null}\n $minWidth={minWidth}\n $size={size}\n $width={width}\n >\n <SelectValueContainer width={valueContainerWidth}>\n <SelectPrimitive.Value placeholder={placeholder} />\n </SelectValueContainer>\n <StyledIconContainer disabled={field.disabled}>\n <CaretDownIcon />\n </StyledIconContainer>\n </SelectButton>\n </SelectPrimitive.Trigger>\n {portal ? (\n <SelectPrimitive.Portal container={portalContainer}>{content}</SelectPrimitive.Portal>\n ) : (\n content\n )}\n </SelectPrimitive.Root>\n );\n});\n\nexport default Select;\n\nexport const Option = forwardRef<HTMLDivElement, SelectPrimitive.SelectItemProps & MenuItemProps>(\n function Option({ children, subtitle, ...props }, forwardedRef) {\n return (\n <SelectPrimitive.Item {...props} ref={forwardedRef} asChild>\n <SelectItem {...props}>\n <SelectPrimitive.ItemText>{children}</SelectPrimitive.ItemText>\n {subtitle && <OptionSubtitle>{subtitle}</OptionSubtitle>}\n </SelectItem>\n </SelectPrimitive.Item>\n );\n },\n);\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;AA2GA,MAAM,eAAe,OAAO,SAAS;IACjC,WAAW;;;;;;;;;mBASI,QAAQ,GAAG;YAClB,EAAE,aAAa,UAAU,OAAO;gBAC5B,EAAE,gBAAiB,aAAa,OAAO,GAAG,UAAU,MAAM,OAAQ;;KAE7E,cAAc;;;;KAId,EAAE,OAAO,wBAAwB,eAClC,0BACA,CAAC,YACD,GAAG;eACQ,cAAc,OAAO,eAAe,MAAM,MAAM,KAAK,UAAU,CAAC;MACzE;;AAON,MAAM,uBAAuB,OAAO,IAA+B;;;;;;KAM9D,EAAE,YACH,SACA,GAAG;eACQ,MAAM;MACf;;AAGN,MAAM,iBAAiB,OAAO,GAAG;YACrB,EAAE,YAAY,cAAc,OAAO,eAAe,MAAM,MAAM,KAAK,UAAU,CAAC;gBAC1E,EAAE,YAAY,MAAM,KAAK,UAAU,GAAG,SAAS;gBAC/C,QAAQ,GAAG;;AAQ3B,MAAM,cAAc,OAAO,KAAK;;iBAEf,EAAE,gBAAgB,aAAa,mBAAmB;;IAE/D,kBAAkB;;;KAGjB,EAAE,WAAW;AACd,SAAQ,MAAR;EACE,KAAK,KACH,QAAO,GAAG;YACN,SAAS;uBACE,QAAQ,GAAG;;;YAGtB,WAAW;cACT,gBAAgB,GAAG;uBACV,QAAQ,GAAG;;;YAGtB,YAAY;uBACD,QAAQ,GAAG;;;EAI5B,KAA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;IACE,YAAY,MAAM;IAClB,UAAU,MAAM;IACP;IACA;IACD;IACR,UAAU,MAAM;IACH;IACb,wBAAwB,MAAM,UAAU,MAAM,MAAM,SAAS;IAC7D,WAAW;IACX,OAAO;IACP,QAAQ;cAXV,CAaE,oBAAC,sBAAD;KAAsB,OAAO;eAC3B,oBAAC,gBAAgB,OAAjB,EAAoC,aAAe,CAAA;KAC9B,CAAA,EACvB,oBAAC,qBAAD;KAAqB,UAAU,MAAM;eACnC,oBAAC,eAAD,EAAiB,CAAA;KACG,CAAA,CACT;;GACS,CAAA,EACzB,SACC,oBAAC,gBAAgB,QAAjB;GAAwB,WAAW;aAAkB;GAAiC,CAAA,GAEtF,QAEmB;;EAEzB;AAIF,MAAa,SAAS,WACpB,SAAS,OAAO,EAAE,UAAU,UAAU,GAAG,SAAS,cAAc;AAC9D,QACE,oBAAC,gBAAgB,MAAjB;EAAsB,GAAI;EAAO,KAAK;EAAc,SAAA;YAClD,qBAAC,YAAD;GAAY,GAAI;aAAhB,CACE,oBAAC,gBAAgB,UAAjB,EAA2B,UAAoC,CAAA,EAC9D,YAAY,oBAAC,gBAAD,EAAA,UAAiB,UAA0B,CAAA,CAC7C;;EACQ,CAAA;EAG5B"}
@@ -1,4 +1,4 @@
1
- import { l as MenuItemProps } from "./Menu-DvzoR8e7.mjs";
1
+ import { l as MenuItemProps } from "./Menu-DNJMfxfw.mjs";
2
2
  import { n as InputSizes, t as InputMixinProps } from "./input-JDU1Goyr.mjs";
3
3
  import * as _$react from "react";
4
4
  import { ReactNode } from "react";
@@ -80,4 +80,4 @@ declare const Select: _$react.ForwardRefExoticComponent<SelectProps & _$react.Re
80
80
  declare const Option: _$react.ForwardRefExoticComponent<SelectPrimitive.SelectItemProps & MenuItemProps<"div"> & _$react.RefAttributes<HTMLDivElement>>;
81
81
  //#endregion
82
82
  export { SelectProps as i, Select as n, SelectHeader as r, Option as t };
83
- //# sourceMappingURL=Select-boZ6XP8k.d.mts.map
83
+ //# sourceMappingURL=Select-O4aTrBuF.d.mts.map
package/dist/Select.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- import { i as SelectProps, n as Select, r as SelectHeader, t as Option } from "./Select-boZ6XP8k.mjs";
1
+ import { i as SelectProps, n as Select, r as SelectHeader, t as Option } from "./Select-O4aTrBuF.mjs";
2
2
  export { Option, Select, Select as default, SelectHeader, SelectProps };
@@ -2,7 +2,7 @@ import { t as ASTNode } from "./types-DeVO4sCM.mjs";
2
2
  import { dt as ObjectSchemaMap, n as JsonSchema, st as FunctionJsonSchema } from "./jsonSchema-C4lfpDrt.mjs";
3
3
  import { n as PossibleChainSchema, t as ChainRoot } from "./chainTypes-C5mXGz6T.mjs";
4
4
  import { a as Mode, i as FunctionFormRenderProps, n as CustomFunctionDetailRenderProps, s as PopoverFooterRenderer, t as CodeChainFunctionPanelRenderProps, u as ValueType } from "./types-02Ij0dgs.mjs";
5
- import { n as useChain } from "./useChain-B--KAtdN.mjs";
5
+ import { n as useChain } from "./useChain-x9fd9Fyq.mjs";
6
6
  import { t as ContextMenuExamples } from "./listbox-options-CDAOiyUH.mjs";
7
7
  import { ReactNode } from "react";
8
8
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
@@ -1,5 +1,5 @@
1
- import { o as ImplementsFormField } from "./inputFields-B7parF2l.mjs";
2
- import { n as TableBoxField } from "./TableBoxField-6qAOW8t9.mjs";
1
+ import { o as ImplementsFormField } from "./inputFields-CxgQOm9E.mjs";
2
+ import { n as TableBoxField } from "./TableBoxField-DPq_rueS.mjs";
3
3
  import SmartTextInput from "./SmartTextInput.mjs";
4
4
  import { CSSProperties, ComponentProps } from "react";
5
5
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
@@ -1,4 +1,4 @@
1
- import { i as StackProps } from "./Stack-CODxfzhl.mjs";
1
+ import { i as StackProps } from "./Stack-B6MrjJeW.mjs";
2
2
  import { s as MethodChainNode } from "./methodChainTypes-De6sHGyd.mjs";
3
3
  import { n as PossibleChainSchema, t as ChainRoot } from "./chainTypes-C5mXGz6T.mjs";
4
4
  import { i as FunctionFormRenderProps, n as CustomFunctionDetailRenderProps, o as OpenCodeChainFunctionPanel, r as FunctionAtCursor } from "./types-02Ij0dgs.mjs";
@@ -1,6 +1,6 @@
1
1
  import { a as SmartTextInputOption } from "./listbox-options-CDAOiyUH.mjs";
2
- import { ReactNode } from "react";
3
2
  import * as _$styled_components0 from "styled-components";
3
+ import { ReactNode } from "react";
4
4
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
5
5
  import { ComboBoxState } from "react-stately";
6
6