@uva-glass/component-library 3.29.0 → 3.30.0

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 (319) hide show
  1. package/dist/Column-BL3dsYxn.js.map +1 -1
  2. package/dist/Lexical.prod-UwAbgYpF.js.map +1 -1
  3. package/dist/LexicalClipboard.prod-DHIGjydG.js.map +1 -1
  4. package/dist/LexicalLink.prod-Bsa9J7L-.js.map +1 -1
  5. package/dist/LexicalList.prod-jxGuZd4b.js.map +1 -1
  6. package/dist/LexicalSelection.prod-xk5MiZnZ.js.map +1 -1
  7. package/dist/LexicalTable.prod-BSjs04iE.js.map +1 -1
  8. package/dist/LexicalUtils.prod-cQutjKA3.js.map +1 -1
  9. package/dist/MultiSelectItem-DbOdEllV.js.map +1 -1
  10. package/dist/SortableProvider-CwX1lFMa.js.map +1 -1
  11. package/dist/TablePlugin-NmJsn2fm.js.map +1 -1
  12. package/dist/__mocks__/svgrMock.js.map +1 -1
  13. package/dist/{client-EQRlhXX7.js → client-D0KlBcsm.js} +1325 -1325
  14. package/dist/{client-EQRlhXX7.js.map → client-D0KlBcsm.js.map} +1 -1
  15. package/dist/components/Accordion/Accordion.js.map +1 -1
  16. package/dist/components/Accordion/Accordion.stories.d.ts +2 -2
  17. package/dist/components/Accordion/Accordion.stories.js.map +1 -1
  18. package/dist/components/Accordion/Accordion.test.js +3 -3
  19. package/dist/components/Accordion/Accordion.test.js.map +1 -1
  20. package/dist/components/AccordionCard/AccordionCard.js.map +1 -1
  21. package/dist/components/AccordionCard/AccordionCard.stories.d.ts +1 -1
  22. package/dist/components/AccordionCard/AccordionCard.stories.js.map +1 -1
  23. package/dist/components/AccordionCard/AccordionCard.test.js +3 -3
  24. package/dist/components/AccordionCard/AccordionCard.test.js.map +1 -1
  25. package/dist/components/ActionList/ActionList.js.map +1 -1
  26. package/dist/components/ActionList/ActionList.stories.d.ts +1 -1
  27. package/dist/components/ActionList/ActionList.stories.js.map +1 -1
  28. package/dist/components/ActionList/ActionList.test.js +3 -3
  29. package/dist/components/ActionList/ActionList.test.js.map +1 -1
  30. package/dist/components/AppStatusBar/AppStatusBar.js.map +1 -1
  31. package/dist/components/AppStatusBar/AppStatusBar.stories.d.ts +1 -1
  32. package/dist/components/AppStatusBar/AppStatusBar.stories.js.map +1 -1
  33. package/dist/components/AppStatusBar/AppStatusBar.test.js +2 -2
  34. package/dist/components/AppStatusBar/AppStatusBar.test.js.map +1 -1
  35. package/dist/components/Attention/Attention.js.map +1 -1
  36. package/dist/components/Attention/Attention.stories.d.ts +1 -1
  37. package/dist/components/Attention/Attention.stories.js.map +1 -1
  38. package/dist/components/Attention/Attention.test.js +2 -2
  39. package/dist/components/Attention/Attention.test.js.map +1 -1
  40. package/dist/components/Backdrop/Backdrop.js.map +1 -1
  41. package/dist/components/Backdrop/Backdrop.stories.d.ts +1 -1
  42. package/dist/components/Backdrop/Backdrop.stories.js.map +1 -1
  43. package/dist/components/Backdrop/Backdrop.test.js +2 -2
  44. package/dist/components/Backdrop/Backdrop.test.js.map +1 -1
  45. package/dist/components/ButtonGroup/ButtonGroup.js.map +1 -1
  46. package/dist/components/ButtonGroup/ButtonGroup.stories.d.ts +1 -1
  47. package/dist/components/ButtonGroup/ButtonGroup.stories.js.map +1 -1
  48. package/dist/components/Buttons/Button.js.map +1 -1
  49. package/dist/components/Buttons/Button.stories.d.ts +2 -2
  50. package/dist/components/Buttons/Button.stories.js +8 -8
  51. package/dist/components/Buttons/Button.stories.js.map +1 -1
  52. package/dist/components/Buttons/Button.test.js +2 -2
  53. package/dist/components/Buttons/Button.test.js.map +1 -1
  54. package/dist/components/Buttons/LinkButton.js.map +1 -1
  55. package/dist/components/Buttons/LinkButton.stories.d.ts +2 -2
  56. package/dist/components/Buttons/LinkButton.stories.js +10 -10
  57. package/dist/components/Buttons/LinkButton.stories.js.map +1 -1
  58. package/dist/components/Buttons/LinkButton.test.js +2 -2
  59. package/dist/components/Buttons/LinkButton.test.js.map +1 -1
  60. package/dist/components/Buttons/MenuButton.js.map +1 -1
  61. package/dist/components/Buttons/MenuButton.stories.d.ts +3 -3
  62. package/dist/components/Buttons/MenuButton.stories.js +15 -15
  63. package/dist/components/Buttons/MenuButton.stories.js.map +1 -1
  64. package/dist/components/Buttons/MenuButton.test.js +2 -2
  65. package/dist/components/Buttons/MenuButton.test.js.map +1 -1
  66. package/dist/components/Card/Card.js.map +1 -1
  67. package/dist/components/Card/Card.stories.d.ts +3 -3
  68. package/dist/components/Card/Card.stories.js.map +1 -1
  69. package/dist/components/Card/Card.test.js +2 -2
  70. package/dist/components/Card/Card.test.js.map +1 -1
  71. package/dist/components/Checkbox/Checkbox.js.map +1 -1
  72. package/dist/components/Checkbox/Checkbox.stories.d.ts +2 -2
  73. package/dist/components/Checkbox/Checkbox.stories.js +1 -1
  74. package/dist/components/Checkbox/Checkbox.stories.js.map +1 -1
  75. package/dist/components/Checkbox/Checkbox.test.js +3 -3
  76. package/dist/components/Checkbox/Checkbox.test.js.map +1 -1
  77. package/dist/components/CheckboxButtonBar/CheckboxButtonBar.js.map +1 -1
  78. package/dist/components/CheckboxButtonBar/CheckboxButtonBar.stories.d.ts +3 -3
  79. package/dist/components/CheckboxButtonBar/CheckboxButtonBar.stories.js +1 -1
  80. package/dist/components/CheckboxButtonBar/CheckboxButtonBar.stories.js.map +1 -1
  81. package/dist/components/CheckboxButtonBar/CheckboxButtonBar.test.js +2 -2
  82. package/dist/components/CheckboxButtonBar/CheckboxButtonBar.test.js.map +1 -1
  83. package/dist/components/CheckboxTree/CheckboxTree.js.map +1 -1
  84. package/dist/components/CheckboxTree/CheckboxTree.stories.d.ts +1 -1
  85. package/dist/components/CheckboxTree/CheckboxTree.stories.js +108 -123
  86. package/dist/components/CheckboxTree/CheckboxTree.stories.js.map +1 -1
  87. package/dist/components/Chip/Chip.js.map +1 -1
  88. package/dist/components/Chip/Chip.stories.d.ts +2 -2
  89. package/dist/components/Chip/Chip.stories.js +1 -1
  90. package/dist/components/Chip/Chip.stories.js.map +1 -1
  91. package/dist/components/ControlsButton/ControlsButton.js.map +1 -1
  92. package/dist/components/ControlsButton/ControlsButton.stories.d.ts +1 -1
  93. package/dist/components/ControlsButton/ControlsButton.stories.js +4 -4
  94. package/dist/components/ControlsButton/ControlsButton.stories.js.map +1 -1
  95. package/dist/components/Drawer/Drawer.js.map +1 -1
  96. package/dist/components/Drawer/Drawer.stories.d.ts +2 -2
  97. package/dist/components/Drawer/Drawer.stories.js +9 -9
  98. package/dist/components/Drawer/Drawer.stories.js.map +1 -1
  99. package/dist/components/EmptyStateDataDisplay/EmptyStateDataDisplay.js.map +1 -1
  100. package/dist/components/EmptyStateDataDisplay/EmptyStateDataDisplay.stories.d.ts +1 -1
  101. package/dist/components/EmptyStateDataDisplay/EmptyStateDataDisplay.stories.js.map +1 -1
  102. package/dist/components/ExpandableInfoPanel/ExpandableInfoPanel.js.map +1 -1
  103. package/dist/components/ExpandableInfoPanel/ExpandableInfoPanel.stories.d.ts +1 -1
  104. package/dist/components/ExpandableInfoPanel/ExpandableInfoPanel.stories.js.map +1 -1
  105. package/dist/components/FeedbackBar/FeedbackBar.js.map +1 -1
  106. package/dist/components/FeedbackBar/FeedbackBar.stories.d.ts +1 -1
  107. package/dist/components/FeedbackBar/FeedbackBar.stories.js.map +1 -1
  108. package/dist/components/FeedbackBar/FeedbackBar.test.js +2 -2
  109. package/dist/components/FeedbackBar/FeedbackBar.test.js.map +1 -1
  110. package/dist/components/FeedbackBox/FeedbackBox.js.map +1 -1
  111. package/dist/components/FeedbackBox/FeedbackBox.stories.d.ts +2 -2
  112. package/dist/components/FeedbackBox/FeedbackBox.stories.js.map +1 -1
  113. package/dist/components/FieldHint/FieldHint.js.map +1 -1
  114. package/dist/components/FieldHint/FieldHint.stories.d.ts +2 -2
  115. package/dist/components/FieldHint/FieldHint.stories.js.map +1 -1
  116. package/dist/components/Fieldset/Fieldset.js.map +1 -1
  117. package/dist/components/Fieldset/Fieldset.stories.d.ts +2 -2
  118. package/dist/components/Fieldset/Fieldset.stories.js.map +1 -1
  119. package/dist/components/FormField/FormField.stories.d.ts +1 -1
  120. package/dist/components/FormField/FormField.stories.js.map +1 -1
  121. package/dist/components/FormInput/FormInput.js.map +1 -1
  122. package/dist/components/FormInput/FormInput.stories.d.ts +2 -2
  123. package/dist/components/FormInput/FormInput.stories.js +1 -1
  124. package/dist/components/FormInput/FormInput.stories.js.map +1 -1
  125. package/dist/components/GridRow/GridRow.js.map +1 -1
  126. package/dist/components/GridRow/GridRow.stories.d.ts +2 -2
  127. package/dist/components/GridRow/GridRow.stories.js.map +1 -1
  128. package/dist/components/HorizontalList/HorizontalList.js.map +1 -1
  129. package/dist/components/HorizontalList/HorizontalList.stories.d.ts +2 -2
  130. package/dist/components/HorizontalList/HorizontalList.stories.js.map +1 -1
  131. package/dist/components/Icon/Icon.js.map +1 -1
  132. package/dist/components/Icon/Icon.stories.d.ts +1 -1
  133. package/dist/components/Icon/Icon.stories.js.map +1 -1
  134. package/dist/components/Icon/icons/index.js.map +1 -1
  135. package/dist/components/IconButton/IconButton.stories.d.ts +1 -1
  136. package/dist/components/IconButton/IconButton.stories.js +5 -5
  137. package/dist/components/IconButton/IconButton.stories.js.map +1 -1
  138. package/dist/components/InfoBanner/InfoBanner.js.map +1 -1
  139. package/dist/components/InfoBanner/InfoBanner.stories.d.ts +1 -1
  140. package/dist/components/InfoBanner/InfoBanner.stories.js.map +1 -1
  141. package/dist/components/InfoMessage/InfoMessage.js.map +1 -1
  142. package/dist/components/InfoMessage/InfoMessage.stories.d.ts +1 -1
  143. package/dist/components/InfoMessage/InfoMessage.stories.js.map +1 -1
  144. package/dist/components/Input/Input.js.map +1 -1
  145. package/dist/components/Input/Input.stories.d.ts +4 -4
  146. package/dist/components/Input/Input.stories.js.map +1 -1
  147. package/dist/components/InputField/InputField.js.map +1 -1
  148. package/dist/components/InputField/InputField.stories.d.ts +3 -3
  149. package/dist/components/InputField/InputField.stories.js +12 -12
  150. package/dist/components/InputField/InputField.stories.js.map +1 -1
  151. package/dist/components/Label/Label.js.map +1 -1
  152. package/dist/components/Label/Label.stories.d.ts +2 -2
  153. package/dist/components/Label/Label.stories.js.map +1 -1
  154. package/dist/components/Label/Label.test.js +2 -2
  155. package/dist/components/Label/Label.test.js.map +1 -1
  156. package/dist/components/MenuLink/MenuLink.js.map +1 -1
  157. package/dist/components/MenuLink/MenuLink.stories.d.ts +2 -2
  158. package/dist/components/MenuLink/MenuLink.stories.js.map +1 -1
  159. package/dist/components/MetaDataList/MetaDataList.js.map +1 -1
  160. package/dist/components/MetaDataList/MetaDataList.stories.d.ts +1 -1
  161. package/dist/components/MetaDataList/MetaDataList.stories.js.map +1 -1
  162. package/dist/components/ModalDialog/ModalDialog.js.map +1 -1
  163. package/dist/components/ModalDialog/ModalDialog.stories.d.ts +3 -3
  164. package/dist/components/ModalDialog/ModalDialog.stories.js +8 -8
  165. package/dist/components/ModalDialog/ModalDialog.stories.js.map +1 -1
  166. package/dist/components/MultiSelect/MultiSelect.stories.d.ts +3 -3
  167. package/dist/components/MultiSelect/MultiSelect.stories.js +7 -7
  168. package/dist/components/MultiSelect/MultiSelect.stories.js.map +1 -1
  169. package/dist/components/MultiSelectBox/MultiSelectBox.js.map +1 -1
  170. package/dist/components/MultiSelectBox/MultiSelectBox.stories.d.ts +2 -2
  171. package/dist/components/MultiSelectBox/MultiSelectBox.stories.js +5 -5
  172. package/dist/components/MultiSelectBox/MultiSelectBox.stories.js.map +1 -1
  173. package/dist/components/MultiSelectBox/MultiSelectBox.test.js +2 -2
  174. package/dist/components/MultiSelectBox/MultiSelectBox.test.js.map +1 -1
  175. package/dist/components/Notification/Notification.js.map +1 -1
  176. package/dist/components/Notification/Notification.stories.d.ts +2 -2
  177. package/dist/components/Notification/Notification.stories.js +3 -3
  178. package/dist/components/Notification/Notification.stories.js.map +1 -1
  179. package/dist/components/Notification/Notification.test.js +2 -2
  180. package/dist/components/Notification/Notification.test.js.map +1 -1
  181. package/dist/components/OverlayCloseButton/OverlayCloseButton.js.map +1 -1
  182. package/dist/components/OverlayCloseButton/OverlayCloseButton.stories.d.ts +1 -1
  183. package/dist/components/OverlayCloseButton/OverlayCloseButton.stories.js +4 -4
  184. package/dist/components/OverlayCloseButton/OverlayCloseButton.stories.js.map +1 -1
  185. package/dist/components/OverlayStepBar/OverlayStepBar.js.map +1 -1
  186. package/dist/components/OverlayStepBar/OverlayStepBar.stories.d.ts +2 -2
  187. package/dist/components/OverlayStepBar/OverlayStepBar.stories.js.map +1 -1
  188. package/dist/components/PageOverlay/PageOverlay.js.map +1 -1
  189. package/dist/components/PageOverlay/PageOverlay.stories.d.ts +3 -3
  190. package/dist/components/PageOverlay/PageOverlay.stories.js.map +1 -1
  191. package/dist/components/PeriodSelector/PeriodSelector.js.map +1 -1
  192. package/dist/components/PeriodSelector/PeriodSelector.stories.d.ts +1 -1
  193. package/dist/components/PeriodSelector/PeriodSelector.stories.js +1 -1
  194. package/dist/components/PeriodSelector/PeriodSelector.stories.js.map +1 -1
  195. package/dist/components/Periods/Periods.js.map +1 -1
  196. package/dist/components/Periods/Periods.stories.d.ts +1 -1
  197. package/dist/components/Periods/Periods.stories.js.map +1 -1
  198. package/dist/components/ProgrammeCard/ProgrammeCard.js.map +1 -1
  199. package/dist/components/ProgrammeCard/ProgrammeCard.stories.d.ts +3 -3
  200. package/dist/components/ProgrammeCard/ProgrammeCard.stories.js.map +1 -1
  201. package/dist/components/RadioButton/RadioButton.js.map +1 -1
  202. package/dist/components/RadioButton/RadioButton.stories.d.ts +1 -1
  203. package/dist/components/RadioButton/RadioButton.stories.js.map +1 -1
  204. package/dist/components/RadioGroup/RadioGroup.js.map +1 -1
  205. package/dist/components/RadioGroup/RadioGroup.stories.d.ts +1 -1
  206. package/dist/components/RadioGroup/RadioGroup.stories.js +4 -4
  207. package/dist/components/RadioGroup/RadioGroup.stories.js.map +1 -1
  208. package/dist/components/RadioGroup/Radiogroup.test.js +2 -2
  209. package/dist/components/RadioGroup/Radiogroup.test.js.map +1 -1
  210. package/dist/components/RadioTabSelector/RadioTabSelector.js.map +1 -1
  211. package/dist/components/RadioTabSelector/RadioTabSelector.stories.d.ts +1 -1
  212. package/dist/components/RadioTabSelector/RadioTabSelector.stories.js +1 -1
  213. package/dist/components/RadioTabSelector/RadioTabSelector.stories.js.map +1 -1
  214. package/dist/components/Repeater/Repeater.js.map +1 -1
  215. package/dist/components/Repeater/Repeater.stories.d.ts +1 -1
  216. package/dist/components/Repeater/Repeater.stories.js.map +1 -1
  217. package/dist/components/RteEditor/EditorHeader/EditorHeader.js.map +1 -1
  218. package/dist/components/RteEditor/Plugins/BlockFormatPlugin/BlockFormatPlugin.js.map +1 -1
  219. package/dist/components/RteEditor/Plugins/HistoryPlugin/HistoryPlugin.js.map +1 -1
  220. package/dist/components/RteEditor/Plugins/LinkPlugin/LinkContextMenu/LinkContextMenu.js.map +1 -1
  221. package/dist/components/RteEditor/Plugins/LinkPlugin/LinkPlugin.js.map +1 -1
  222. package/dist/components/RteEditor/Plugins/ListPlugin/ListPlugin.js.map +1 -1
  223. package/dist/components/RteEditor/Plugins/PasteHandlerPlugin/PasteHandlerPlugin.js.map +1 -1
  224. package/dist/components/RteEditor/Plugins/TablePlugin/TableCellContextMenu/TableCellContextMenu.js.map +1 -1
  225. package/dist/components/RteEditor/Plugins/TablePlugin/helpers.js.map +1 -1
  226. package/dist/components/RteEditor/Plugins/ToolbarPlugin/ToolbarPlugin.js.map +1 -1
  227. package/dist/components/RteEditor/Providers/LanguageProvider.js.map +1 -1
  228. package/dist/components/RteEditor/RteEditor.js.map +1 -1
  229. package/dist/components/RteEditor/RteEditor.stories.d.ts +1 -1
  230. package/dist/components/RteEditor/RteEditor.stories.js.map +1 -1
  231. package/dist/components/RteEditor/UvaTheme/UvaTheme.js.map +1 -1
  232. package/dist/components/RteEditor/helpers.js.map +1 -1
  233. package/dist/components/RteEditor/hooks/components/Flyout.js.map +1 -1
  234. package/dist/components/RteEditor/hooks/useFlyout.js.map +1 -1
  235. package/dist/components/RteEditor/hooks/useTranslation.js.map +1 -1
  236. package/dist/components/RteEditor/translations.js.map +1 -1
  237. package/dist/components/SectionNotification/SectionNotification.js.map +1 -1
  238. package/dist/components/SectionNotification/SectionNotification.stories.d.ts +1 -1
  239. package/dist/components/SectionNotification/SectionNotification.stories.js.map +1 -1
  240. package/dist/components/SelectListbox/SelectListBox.stories.d.ts +2 -2
  241. package/dist/components/SelectListbox/SelectListBox.stories.js +1 -1
  242. package/dist/components/SelectListbox/SelectListBox.stories.js.map +1 -1
  243. package/dist/components/SelectListbox/SelectListbox.js.map +1 -1
  244. package/dist/components/SelectListbox/SelectProvider.js.map +1 -1
  245. package/dist/components/SelectListbox/components/SelectButton.js.map +1 -1
  246. package/dist/components/SelectListbox/components/SelectContainer.js.map +1 -1
  247. package/dist/components/SelectListbox/components/SelectOption.js.map +1 -1
  248. package/dist/components/SelectListbox/components/SelectOptionBox.js.map +1 -1
  249. package/dist/components/Sortable/Sortable.js.map +1 -1
  250. package/dist/components/Sortable/Sortable.stories.d.ts +3 -3
  251. package/dist/components/Sortable/Sortable.stories.js +13 -13
  252. package/dist/components/Sortable/Sortable.stories.js.map +1 -1
  253. package/dist/components/Sortable/actions.js.map +1 -1
  254. package/dist/components/Sortable/components/SortableHandle.js.map +1 -1
  255. package/dist/components/Sortable/components/SortableItem.js.map +1 -1
  256. package/dist/components/Sortable/sortableReducer.js.map +1 -1
  257. package/dist/components/Spinner/Spinner.js.map +1 -1
  258. package/dist/components/Spinner/Spinner.stories.d.ts +1 -1
  259. package/dist/components/Spinner/Spinner.stories.js.map +1 -1
  260. package/dist/components/StatusBadge/StatusBadge.stories.d.ts +1 -1
  261. package/dist/components/StatusBadge/StatusBadge.stories.js.map +1 -1
  262. package/dist/components/StatusBadge/StatusBadge.test.js +2 -2
  263. package/dist/components/StatusBadge/StatusBadge.test.js.map +1 -1
  264. package/dist/components/StatusBadge/StatusBage.js.map +1 -1
  265. package/dist/components/StatusPill/StatusPill.js.map +1 -1
  266. package/dist/components/StatusPill/StatusPill.stories.d.ts +1 -1
  267. package/dist/components/StatusPill/StatusPill.stories.js.map +1 -1
  268. package/dist/components/TextArea/TextArea.js.map +1 -1
  269. package/dist/components/TextArea/TextArea.stories.d.ts +1 -1
  270. package/dist/components/TextArea/TextArea.stories.js +1 -1
  271. package/dist/components/TextArea/TextArea.stories.js.map +1 -1
  272. package/dist/components/TextArea/TextArea.test.js +9 -9
  273. package/dist/components/TextArea/TextArea.test.js.map +1 -1
  274. package/dist/components/ToggleSwitch/ToggleSwitch.js.map +1 -1
  275. package/dist/components/ToggleSwitch/ToggleSwitch.stories.d.ts +1 -1
  276. package/dist/components/ToggleSwitch/ToggleSwitch.stories.js +5 -5
  277. package/dist/components/ToggleSwitch/ToggleSwitch.stories.js.map +1 -1
  278. package/dist/components/Tooltip/Tooltip.js.map +1 -1
  279. package/dist/components/Tooltip/Tooltip.stories.d.ts +1 -1
  280. package/dist/components/Tooltip/Tooltip.stories.js.map +1 -1
  281. package/dist/components/VarIndicator/VarIndicator.js.map +1 -1
  282. package/dist/components/VarIndicator/VarIndicator.stories.d.ts +1 -1
  283. package/dist/components/VarIndicator/VarIndicator.stories.js +4 -4
  284. package/dist/components/VarIndicator/VarIndicator.stories.js.map +1 -1
  285. package/dist/components/VarIndicator/VarIndicator.test.js +3 -3
  286. package/dist/components/VarIndicator/VarIndicator.test.js.map +1 -1
  287. package/dist/components/hooks/useDebounce.js.map +1 -1
  288. package/dist/components/hooks/useOnClickOutside.js.map +1 -1
  289. package/dist/components/hooks/usePositionedFloaters.js.map +1 -1
  290. package/dist/components/hooks/useResponsive.js.map +1 -1
  291. package/dist/helpers-DZIm3MiJ.js.map +1 -1
  292. package/dist/index-BVAvx58-.js +10648 -0
  293. package/dist/index-BVAvx58-.js.map +1 -0
  294. package/dist/{index-BqLi4tOb.js → index-DV47hRzi.js} +2891 -2818
  295. package/dist/index-DV47hRzi.js.map +1 -0
  296. package/dist/index-Di9WPZUe.js +34752 -0
  297. package/dist/index-Di9WPZUe.js.map +1 -0
  298. package/dist/index-DllfJcv4.js.map +1 -1
  299. package/dist/index-PaHiqSUg.js +3099 -0
  300. package/dist/index-PaHiqSUg.js.map +1 -0
  301. package/dist/{react-18-dpbWrd2-.js → react-18-inmoTCp-.js} +2 -2
  302. package/dist/{react-18-dpbWrd2-.js.map → react-18-inmoTCp-.js.map} +1 -1
  303. package/dist/{react.esm-CsMDid07.js → react.esm-CFMwGdo5.js} +3 -3
  304. package/dist/{react.esm-CsMDid07.js.map → react.esm-CFMwGdo5.js.map} +1 -1
  305. package/dist/setupTests.js +11 -1562
  306. package/dist/setupTests.js.map +1 -1
  307. package/dist/storyComponents/ClipboardButton/ClipboardButton.js.map +1 -1
  308. package/dist/storyComponents/Container/Container.js.map +1 -1
  309. package/dist/storybook__react.d.js +5345 -5766
  310. package/dist/storybook__react.d.js.map +1 -1
  311. package/dist/test-utils-ea_YDVtd.js.map +1 -1
  312. package/package.json +14 -18
  313. package/dist/index-BqLi4tOb.js.map +0 -1
  314. package/dist/index-CUap8sKR.js +0 -2962
  315. package/dist/index-CUap8sKR.js.map +0 -1
  316. package/dist/index-DH9Vbk37.js +0 -9507
  317. package/dist/index-DH9Vbk37.js.map +0 -1
  318. package/dist/index-Dwqes6RH.js +0 -14758
  319. package/dist/index-Dwqes6RH.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"Accordion.js","sources":["../../../src/components/Accordion/Accordion.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport { useId, useState } from 'react';\n\nimport type { KeyboardEvent, ReactNode } from 'react';\n\nimport styles from './Accordion.module.css';\n\nimport { Icon } from 'components/Icon';\n\nexport interface AccordionProps {\n /** Clickable title (always visible). */\n title: ReactNode;\n /** Main content (hidden when expanded is false). */\n content: ReactNode;\n /** Indicator if Accordion should be expanded by default.*/\n expanded?: boolean;\n}\n\n/** A controller for accordion display toggling of content with click on a title. */\nexport const Accordion = ({ title, content, expanded = false }: AccordionProps) => {\n const [isExpanded, setIsExpanded] = useState(expanded);\n const accordionId = useId();\n\n function onKeyUp(event: KeyboardEvent<HTMLDivElement>) {\n const { code } = event;\n\n if (code === 'Enter' || code === 'Space') {\n setIsExpanded(!isExpanded);\n }\n }\n\n return (\n <div className={styles['accordion']}>\n <div\n className={styles['accordion__title']}\n id={accordionId}\n role=\"button\"\n tabIndex={0}\n onClick={() => setIsExpanded(!isExpanded)}\n onKeyUp={onKeyUp}\n aria-expanded={isExpanded}\n >\n {title}\n <Icon\n className={clsx(styles['accordion__title-icon'], { [styles['accordion__title-icon--expanded']]: isExpanded })}\n name=\"CheveronLeft\"\n size={16}\n />\n </div>\n <div\n aria-labelledby={accordionId}\n className={clsx(styles.accordion__content, { [styles['accordion__content--expanded']]: isExpanded })}\n >\n {content}\n </div>\n </div>\n );\n};\n"],"names":["Accordion","title","content","expanded","isExpanded","setIsExpanded","useState","accordionId","useId","onKeyUp","event","code","jsxs","styles","jsx","Icon","clsx"],"mappings":";;;;;;;;;;;GAmBaA,IAAY,CAAC,EAAE,OAAAC,GAAO,SAAAC,GAAS,UAAAC,IAAW,SAA4B;AACjF,QAAM,CAACC,GAAYC,CAAa,IAAIC,EAASH,CAAQ,GAC/CI,IAAcC,EAAM;AAE1B,WAASC,EAAQC,GAAsC;AAC/C,UAAA,EAAE,MAAAC,MAASD;AAEb,KAAAC,MAAS,WAAWA,MAAS,YAC/BN,EAAc,CAACD,CAAU;AAAA,EAC3B;AAGF,SACG,gBAAAQ,EAAA,OAAA,EAAI,WAAWC,EAAO,WACrB,UAAA;AAAA,IAAA,gBAAAD;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,WAAWC,EAAO;AAAA,QAClB,IAAIN;AAAA,QACJ,MAAK;AAAA,QACL,UAAU;AAAA,QACV,SAAS,MAAMF,EAAc,CAACD,CAAU;AAAA,QACxC,SAAAK;AAAA,QACA,iBAAeL;AAAA,QAEd,UAAA;AAAA,UAAAH;AAAA,UACD,gBAAAa;AAAA,YAACC;AAAA,YAAA;AAAA,cACC,WAAWC,EAAKH,EAAO,uBAAuB,GAAG,EAAE,CAACA,EAAO,iCAAiC,CAAC,GAAGT,GAAY;AAAA,cAC5G,MAAK;AAAA,cACL,MAAM;AAAA,YAAA;AAAA,UAAA;AAAA,QACR;AAAA,MAAA;AAAA,IACF;AAAA,IACA,gBAAAU;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,mBAAiBP;AAAA,QACjB,WAAWS,EAAKH,EAAO,oBAAoB,EAAE,CAACA,EAAO,8BAA8B,CAAC,GAAGT,GAAY;AAAA,QAElG,UAAAF;AAAA,MAAA;AAAA,IAAA;AAAA,EACH,GACF;AAEJ;"}
1
+ {"version":3,"file":"Accordion.js","sources":["../../../src/components/Accordion/Accordion.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport { useId, useState } from 'react';\n\nimport type { KeyboardEvent, ReactNode } from 'react';\n\nimport styles from './Accordion.module.css';\n\nimport { Icon } from 'components/Icon';\n\nexport interface AccordionProps {\n /** Clickable title (always visible). */\n title: ReactNode;\n /** Main content (hidden when expanded is false). */\n content: ReactNode;\n /** Indicator if Accordion should be expanded by default.*/\n expanded?: boolean;\n}\n\n/** A controller for accordion display toggling of content with click on a title. */\nexport const Accordion = ({ title, content, expanded = false }: AccordionProps) => {\n const [isExpanded, setIsExpanded] = useState(expanded);\n const accordionId = useId();\n\n function onKeyUp(event: KeyboardEvent<HTMLDivElement>) {\n const { code } = event;\n\n if (code === 'Enter' || code === 'Space') {\n setIsExpanded(!isExpanded);\n }\n }\n\n return (\n <div className={styles['accordion']}>\n <div\n className={styles['accordion__title']}\n id={accordionId}\n role=\"button\"\n tabIndex={0}\n onClick={() => setIsExpanded(!isExpanded)}\n onKeyUp={onKeyUp}\n aria-expanded={isExpanded}\n >\n {title}\n <Icon\n className={clsx(styles['accordion__title-icon'], { [styles['accordion__title-icon--expanded']]: isExpanded })}\n name=\"CheveronLeft\"\n size={16}\n />\n </div>\n <div\n aria-labelledby={accordionId}\n className={clsx(styles.accordion__content, { [styles['accordion__content--expanded']]: isExpanded })}\n >\n {content}\n </div>\n </div>\n );\n};\n"],"names":["Accordion","title","content","expanded","isExpanded","setIsExpanded","useState","accordionId","useId","onKeyUp","event","code","jsxs","styles","jsx","Icon","clsx"],"mappings":";;;;;;;;;;;GAmBaA,IAAY,CAAC,EAAE,OAAAC,GAAO,SAAAC,GAAS,UAAAC,IAAW,SAA4B;AACjF,QAAM,CAACC,GAAYC,CAAa,IAAIC,EAASH,CAAQ,GAC/CI,IAAcC,EAAA;AAEpB,WAASC,EAAQC,GAAsC;AACrD,UAAM,EAAE,MAAAC,MAASD;AAEjB,KAAIC,MAAS,WAAWA,MAAS,YAC/BN,EAAc,CAACD,CAAU;AAAA,EAC3B;AAGF,SACE,gBAAAQ,EAAC,OAAA,EAAI,WAAWC,EAAO,WACrB,UAAA;AAAA,IAAA,gBAAAD;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,WAAWC,EAAO;AAAA,QAClB,IAAIN;AAAA,QACJ,MAAK;AAAA,QACL,UAAU;AAAA,QACV,SAAS,MAAMF,EAAc,CAACD,CAAU;AAAA,QACxC,SAAAK;AAAA,QACA,iBAAeL;AAAA,QAEd,UAAA;AAAA,UAAAH;AAAA,UACD,gBAAAa;AAAA,YAACC;AAAA,YAAA;AAAA,cACC,WAAWC,EAAKH,EAAO,uBAAuB,GAAG,EAAE,CAACA,EAAO,iCAAiC,CAAC,GAAGT,GAAY;AAAA,cAC5G,MAAK;AAAA,cACL,MAAM;AAAA,YAAA;AAAA,UAAA;AAAA,QACR;AAAA,MAAA;AAAA,IAAA;AAAA,IAEF,gBAAAU;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,mBAAiBP;AAAA,QACjB,WAAWS,EAAKH,EAAO,oBAAoB,EAAE,CAACA,EAAO,8BAA8B,CAAC,GAAGT,GAAY;AAAA,QAElG,UAAAF;AAAA,MAAA;AAAA,IAAA;AAAA,EACH,GACF;AAEJ;"}
@@ -2,5 +2,5 @@ import { Meta } from '@storybook/react';
2
2
  import { AccordionProps } from './Accordion';
3
3
  declare const _default: Meta<AccordionProps>;
4
4
  export default _default;
5
- export declare const AccordionExample: import('@storybook/core/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, AccordionProps>;
6
- export declare const WithComplexProps: import('@storybook/core/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, AccordionProps>;
5
+ export declare const AccordionExample: import('storybook/internal/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, AccordionProps>;
6
+ export declare const WithComplexProps: import('storybook/internal/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, AccordionProps>;
@@ -1 +1 @@
1
- {"version":3,"file":"Accordion.stories.js","sources":["../../../src/components/Accordion/Accordion.stories.tsx"],"sourcesContent":["import type { Meta, StoryFn } from '@storybook/react';\nimport type { AccordionProps } from './Accordion';\n\nimport { Accordion } from './Accordion';\n\nimport { Container } from 'storyComponents/Container';\n\nconst codeString = '<Accordion title={title} content={content}/>';\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n title: 'Atoms/Accordion',\n component: Accordion,\n argTypes: {\n expanded: {\n // Hide the expanded prop. Changing the value in Storybook doesn't update the state of the component.\n table: {\n disable: true,\n },\n },\n },\n parameters: {\n inspectComponent: Accordion,\n codeString: codeString,\n },\n} as Meta<AccordionProps>;\n\nconst Template: StoryFn<AccordionProps> = (args) => (\n <Container>\n <Accordion {...args} />\n </Container>\n);\n\nexport const AccordionExample = Template.bind({});\nAccordionExample.args = {\n title: 'Example title',\n content: 'Example content',\n};\n\nexport const WithComplexProps = Template.bind({});\nWithComplexProps.args = {\n title: <div style={{ fontWeight: 'bold' }}>Complex sample title</div>,\n content: <div style={{ fontStyle: 'italic' }}>Complex sample content</div>,\n};\n"],"names":["codeString","Accordion_stories","Accordion","Template","args","jsx","Container","AccordionExample","WithComplexProps"],"mappings":";;;AAOA,MAAMA,IAAa,gDAGJC,IAAA;AAAA,EACb,OAAO;AAAA,EACP,WAAWC;AAAA,EACX,UAAU;AAAA,IACR,UAAU;AAAA;AAAA,MAER,OAAO;AAAA,QACL,SAAS;AAAA,MAAA;AAAA,IACX;AAAA,EAEJ;AAAA,EACA,YAAY;AAAA,IACV,kBAAkBA;AAAA,IAClB,YAAAF;AAAA,EAAA;AAEJ,GAEMG,IAAoC,CAACC,MACzC,gBAAAC,EAACC,KACC,UAAC,gBAAAD,EAAAH,GAAA,EAAW,GAAGE,EAAA,CAAM,EACvB,CAAA,GAGWG,IAAmBJ,EAAS,KAAK,CAAE,CAAA;AAChDI,EAAiB,OAAO;AAAA,EACtB,OAAO;AAAA,EACP,SAAS;AACX;AAEO,MAAMC,IAAmBL,EAAS,KAAK,CAAE,CAAA;AAChDK,EAAiB,OAAO;AAAA,EACtB,yBAAQ,OAAI,EAAA,OAAO,EAAE,YAAY,UAAU,UAAoB,wBAAA;AAAA,EAC/D,2BAAU,OAAI,EAAA,OAAO,EAAE,WAAW,SAAA,GAAY,UAAsB,yBAAA,CAAA;AACtE;"}
1
+ {"version":3,"file":"Accordion.stories.js","sources":["../../../src/components/Accordion/Accordion.stories.tsx"],"sourcesContent":["import type { Meta, StoryFn } from '@storybook/react';\nimport type { AccordionProps } from './Accordion';\n\nimport { Accordion } from './Accordion';\n\nimport { Container } from 'storyComponents/Container';\n\nconst codeString = '<Accordion title={title} content={content}/>';\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n title: 'Atoms/Accordion',\n component: Accordion,\n argTypes: {\n expanded: {\n // Hide the expanded prop. Changing the value in Storybook doesn't update the state of the component.\n table: {\n disable: true,\n },\n },\n },\n parameters: {\n inspectComponent: Accordion,\n codeString: codeString,\n },\n} as Meta<AccordionProps>;\n\nconst Template: StoryFn<AccordionProps> = (args) => (\n <Container>\n <Accordion {...args} />\n </Container>\n);\n\nexport const AccordionExample = Template.bind({});\nAccordionExample.args = {\n title: 'Example title',\n content: 'Example content',\n};\n\nexport const WithComplexProps = Template.bind({});\nWithComplexProps.args = {\n title: <div style={{ fontWeight: 'bold' }}>Complex sample title</div>,\n content: <div style={{ fontStyle: 'italic' }}>Complex sample content</div>,\n};\n"],"names":["codeString","Accordion_stories","Accordion","Template","args","jsx","Container","AccordionExample","WithComplexProps"],"mappings":";;;AAOA,MAAMA,IAAa,gDAGnBC,IAAe;AAAA,EACb,OAAO;AAAA,EACP,WAAWC;AAAA,EACX,UAAU;AAAA,IACR,UAAU;AAAA;AAAA,MAER,OAAO;AAAA,QACL,SAAS;AAAA,MAAA;AAAA,IACX;AAAA,EACF;AAAA,EAEF,YAAY;AAAA,IACV,kBAAkBA;AAAA,IAClB,YAAAF;AAAA,EAAA;AAEJ,GAEMG,IAAoC,CAACC,MACzC,gBAAAC,EAACC,KACC,UAAA,gBAAAD,EAACH,GAAA,EAAW,GAAGE,EAAA,CAAM,EAAA,CACvB,GAGWG,IAAmBJ,EAAS,KAAK,CAAA,CAAE;AAChDI,EAAiB,OAAO;AAAA,EACtB,OAAO;AAAA,EACP,SAAS;AACX;AAEO,MAAMC,IAAmBL,EAAS,KAAK,CAAA,CAAE;AAChDK,EAAiB,OAAO;AAAA,EACtB,yBAAQ,OAAA,EAAI,OAAO,EAAE,YAAY,OAAA,GAAU,UAAA,wBAAoB;AAAA,EAC/D,2BAAU,OAAA,EAAI,OAAO,EAAE,WAAW,SAAA,GAAY,UAAA,yBAAA,CAAsB;AACtE;"}
@@ -1,7 +1,7 @@
1
1
  import { jsx as o } from "react/jsx-runtime";
2
- import "../../index-BqLi4tOb.js";
3
- import { r as n, s as a } from "../../react.esm-CsMDid07.js";
4
- import { u as e } from "../../index-CUap8sKR.js";
2
+ import "../../index-DV47hRzi.js";
3
+ import { r as n, s as a } from "../../react.esm-CFMwGdo5.js";
4
+ import { u as e } from "../../index-PaHiqSUg.js";
5
5
  import { Accordion as i } from "./Accordion.js";
6
6
  describe("Accordion", () => {
7
7
  it("should render", () => {
@@ -1 +1 @@
1
- {"version":3,"file":"Accordion.test.js","sources":["../../../src/components/Accordion/Accordion.test.tsx"],"sourcesContent":["import '@testing-library/jest-dom';\nimport { render, screen } from '@testing-library/react';\nimport userEvent from '@testing-library/user-event';\n\nimport { Accordion } from './Accordion';\n\ndescribe('Accordion', () => {\n it('should render', () => {\n render(<Accordion title=\"Test Accordion\" content=\"Test Content\" />);\n const titleElement = screen.getByText('Test Accordion');\n expect(titleElement).toBeInTheDocument();\n expect(titleElement).toHaveAttribute('aria-expanded', 'false');\n });\n\n it('should display content when expanded by default', () => {\n render(<Accordion title=\"Test Accordion\" content=\"Test Content\" expanded />);\n const titleElement = screen.getByText('Test Accordion');\n expect(titleElement).toBeInTheDocument();\n expect(titleElement).toHaveAttribute('aria-expanded', 'true');\n });\n\n it('should toggle content visibility on click', async () => {\n render(<Accordion title=\"Test Accordion\" content=\"Test Content\" />);\n const titleElement = screen.getByText('Test Accordion');\n await userEvent.click(titleElement);\n expect(titleElement).toHaveAttribute('aria-expanded', 'true');\n await userEvent.click(titleElement);\n expect(titleElement).toHaveAttribute('aria-expanded', 'false');\n });\n\n it('should toggle content visibility on Enter key press', async () => {\n render(<Accordion title=\"Test Accordion\" content=\"Test Content\" />);\n const titleElement = screen.getByText('Test Accordion');\n await userEvent.keyboard('[Tab]');\n await userEvent.keyboard('[Enter]');\n expect(titleElement).toHaveAttribute('aria-expanded', 'true');\n await userEvent.keyboard('[Enter]');\n expect(titleElement).toHaveAttribute('aria-expanded', 'false');\n });\n\n it('should toggle content visibility on Space key press', async () => {\n render(<Accordion title=\"Test Accordion\" content=\"Test Content\" />);\n const titleElement = screen.getByText('Test Accordion');\n await userEvent.keyboard('[Tab]');\n await userEvent.keyboard('[Space]');\n expect(titleElement).toHaveAttribute('aria-expanded', 'true');\n await userEvent.keyboard('[Space]');\n expect(titleElement).toHaveAttribute('aria-expanded', 'false');\n });\n});\n"],"names":["render","Accordion","titleElement","screen","jsx","userEvent"],"mappings":";;;;;AAMA,SAAS,aAAa,MAAM;AAC1B,KAAG,iBAAiB,MAAM;AACxB,IAAAA,oBAAQC,GAAU,EA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BAAgB;AAChD,UAAAE,EAAU,SAAS,OAAO,GAC1B,MAAAA,EAAU,SAAS,SAAS,GAClC,OAAOH,CAAY,EAAE,gBAAgB,iBAAiB,MAAM,GACtD,MAAAG,EAAU,SAAS,SAAS,GAClC,OAAOH,CAAY,EAAE,gBAAgB,iBAAiB,OAAO;AAAA,EAAA,CAC9D;AACH,CAAC;"}
1
+ {"version":3,"file":"Accordion.test.js","sources":["../../../src/components/Accordion/Accordion.test.tsx"],"sourcesContent":["import '@testing-library/jest-dom';\nimport { render, screen } from '@testing-library/react';\nimport userEvent from '@testing-library/user-event';\n\nimport { Accordion } from './Accordion';\n\ndescribe('Accordion', () => {\n it('should render', () => {\n render(<Accordion title=\"Test Accordion\" content=\"Test Content\" />);\n const titleElement = screen.getByText('Test Accordion');\n expect(titleElement).toBeInTheDocument();\n expect(titleElement).toHaveAttribute('aria-expanded', 'false');\n });\n\n it('should display content when expanded by default', () => {\n render(<Accordion title=\"Test Accordion\" content=\"Test Content\" expanded />);\n const titleElement = screen.getByText('Test Accordion');\n expect(titleElement).toBeInTheDocument();\n expect(titleElement).toHaveAttribute('aria-expanded', 'true');\n });\n\n it('should toggle content visibility on click', async () => {\n render(<Accordion title=\"Test Accordion\" content=\"Test Content\" />);\n const titleElement = screen.getByText('Test Accordion');\n await userEvent.click(titleElement);\n expect(titleElement).toHaveAttribute('aria-expanded', 'true');\n await userEvent.click(titleElement);\n expect(titleElement).toHaveAttribute('aria-expanded', 'false');\n });\n\n it('should toggle content visibility on Enter key press', async () => {\n render(<Accordion title=\"Test Accordion\" content=\"Test Content\" />);\n const titleElement = screen.getByText('Test Accordion');\n await userEvent.keyboard('[Tab]');\n await userEvent.keyboard('[Enter]');\n expect(titleElement).toHaveAttribute('aria-expanded', 'true');\n await userEvent.keyboard('[Enter]');\n expect(titleElement).toHaveAttribute('aria-expanded', 'false');\n });\n\n it('should toggle content visibility on Space key press', async () => {\n render(<Accordion title=\"Test Accordion\" content=\"Test Content\" />);\n const titleElement = screen.getByText('Test Accordion');\n await userEvent.keyboard('[Tab]');\n await userEvent.keyboard('[Space]');\n expect(titleElement).toHaveAttribute('aria-expanded', 'true');\n await userEvent.keyboard('[Space]');\n expect(titleElement).toHaveAttribute('aria-expanded', 'false');\n });\n});\n"],"names":["render","Accordion","titleElement","screen","jsx","userEvent"],"mappings":";;;;;AAMA,SAAS,aAAa,MAAM;AAC1B,KAAG,iBAAiB,MAAM;AACxB,IAAAA,oBAAQC,GAAA,EAAU,OAAM,kBAAiB,SAAQ,gBAAe,CAAE;AAClE,UAAMC,IAAeC,EAAO,UAAU,gBAAgB;AACtD,WAAOD,CAAY,EAAE,kBAAA,GACrB,OAAOA,CAAY,EAAE,gBAAgB,iBAAiB,OAAO;AAAA,EAAA,CAC9D,GAED,GAAG,mDAAmD,MAAM;AAC1D,IAAAF,EAAO,gBAAAI,EAACH,KAAU,OAAM,kBAAiB,SAAQ,gBAAe,UAAQ,IAAC,CAAE;AAC3E,UAAMC,IAAeC,EAAO,UAAU,gBAAgB;AACtD,WAAOD,CAAY,EAAE,kBAAA,GACrB,OAAOA,CAAY,EAAE,gBAAgB,iBAAiB,MAAM;AAAA,EAAA,CAC7D,GAED,GAAG,6CAA6C,YAAY;AAC1D,IAAAF,oBAAQC,GAAA,EAAU,OAAM,kBAAiB,SAAQ,gBAAe,CAAE;AAClE,UAAMC,IAAeC,EAAO,UAAU,gBAAgB;AACtD,UAAME,EAAU,MAAMH,CAAY,GAClC,OAAOA,CAAY,EAAE,gBAAgB,iBAAiB,MAAM,GAC5D,MAAMG,EAAU,MAAMH,CAAY,GAClC,OAAOA,CAAY,EAAE,gBAAgB,iBAAiB,OAAO;AAAA,EAAA,CAC9D,GAED,GAAG,uDAAuD,YAAY;AACpE,IAAAF,oBAAQC,GAAA,EAAU,OAAM,kBAAiB,SAAQ,gBAAe,CAAE;AAClE,UAAMC,IAAeC,EAAO,UAAU,gBAAgB;AACtD,UAAME,EAAU,SAAS,OAAO,GAChC,MAAMA,EAAU,SAAS,SAAS,GAClC,OAAOH,CAAY,EAAE,gBAAgB,iBAAiB,MAAM,GAC5D,MAAMG,EAAU,SAAS,SAAS,GAClC,OAAOH,CAAY,EAAE,gBAAgB,iBAAiB,OAAO;AAAA,EAAA,CAC9D,GAED,GAAG,uDAAuD,YAAY;AACpE,IAAAF,oBAAQC,GAAA,EAAU,OAAM,kBAAiB,SAAQ,gBAAe,CAAE;AAClE,UAAMC,IAAeC,EAAO,UAAU,gBAAgB;AACtD,UAAME,EAAU,SAAS,OAAO,GAChC,MAAMA,EAAU,SAAS,SAAS,GAClC,OAAOH,CAAY,EAAE,gBAAgB,iBAAiB,MAAM,GAC5D,MAAMG,EAAU,SAAS,SAAS,GAClC,OAAOH,CAAY,EAAE,gBAAgB,iBAAiB,OAAO;AAAA,EAAA,CAC9D;AACH,CAAC;"}
@@ -1 +1 @@
1
- {"version":3,"file":"AccordionCard.js","sources":["../../../src/components/AccordionCard/AccordionCard.tsx"],"sourcesContent":["import clsx from 'clsx';\nimport { useId, useState } from 'react';\n\nimport type { KeyboardEvent, ReactNode } from 'react';\n\nimport styles from './AccordionCard.module.css';\n\nimport { Icon } from 'components/Icon';\n\nexport interface AccordionCardProps {\n /** Clickable title (always visible). */\n title: ReactNode;\n /** Main content (hidden when expanded is false). */\n content: ReactNode;\n /** Indicator if Accordion should be expanded by default.*/\n expanded?: boolean;\n}\n\nexport const AccordionCard = ({ title, content, expanded = false }: AccordionCardProps) => {\n const [isExpanded, setIsExpanded] = useState(expanded);\n const accordionId = useId();\n\n const onKeyUp = (event: KeyboardEvent<HTMLDivElement>) => {\n const { code } = event;\n\n if (code === 'Enter' || code === 'Space') {\n setIsExpanded(!isExpanded);\n }\n };\n\n return (\n <div className={styles['accordion-card']}>\n <div\n className={styles['accordion-card__title']}\n id={accordionId}\n role=\"button\"\n tabIndex={0}\n onClick={() => setIsExpanded(!isExpanded)}\n onKeyUp={onKeyUp}\n aria-expanded={isExpanded}\n >\n <Icon\n className={clsx(styles['accordion-card__title-icon'], {\n [styles['accordion-card__title-icon--expanded']]: isExpanded,\n })}\n name=\"CheveronLeft\"\n size={16}\n />\n <h3>{title}</h3>\n </div>\n <div\n aria-labelledby={accordionId}\n className={clsx(styles['accordion-card__content'], {\n [styles['accordion-card__content--expanded']]: isExpanded,\n })}\n >\n {content}\n </div>\n </div>\n );\n};\n"],"names":["AccordionCard","title","content","expanded","isExpanded","setIsExpanded","useState","accordionId","useId","onKeyUp","event","code","jsxs","styles","jsx","Icon","clsx"],"mappings":";;;;;;;;;;;GAkBaA,IAAgB,CAAC,EAAE,OAAAC,GAAO,SAAAC,GAAS,UAAAC,IAAW,SAAgC;AACzF,QAAM,CAACC,GAAYC,CAAa,IAAIC,EAASH,CAAQ,GAC/CI,IAAcC,EAAM,GAEpBC,IAAU,CAACC,MAAyC;AAClD,UAAA,EAAE,MAAAC,MAASD;AAEb,KAAAC,MAAS,WAAWA,MAAS,YAC/BN,EAAc,CAACD,CAAU;AAAA,EAE7B;AAEA,SACG,gBAAAQ,EAAA,OAAA,EAAI,WAAWC,EAAO,gBAAgB,GACrC,UAAA;AAAA,IAAA,gBAAAD;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,WAAWC,EAAO,uBAAuB;AAAA,QACzC,IAAIN;AAAA,QACJ,MAAK;AAAA,QACL,UAAU;AAAA,QACV,SAAS,MAAMF,EAAc,CAACD,CAAU;AAAA,QACxC,SAAAK;AAAA,QACA,iBAAeL;AAAA,QAEf,UAAA;AAAA,UAAA,gBAAAU;AAAA,YAACC;AAAA,YAAA;AAAA,cACC,WAAWC,EAAKH,EAAO,4BAA4B,GAAG;AAAA,gBACpD,CAACA,EAAO,sCAAsC,CAAC,GAAGT;AAAA,cAAA,CACnD;AAAA,cACD,MAAK;AAAA,cACL,MAAM;AAAA,YAAA;AAAA,UACR;AAAA,UACA,gBAAAU,EAAC,QAAI,UAAMb,EAAA,CAAA;AAAA,QAAA;AAAA,MAAA;AAAA,IACb;AAAA,IACA,gBAAAa;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,mBAAiBP;AAAA,QACjB,WAAWS,EAAKH,EAAO,yBAAyB,GAAG;AAAA,UACjD,CAACA,EAAO,mCAAmC,CAAC,GAAGT;AAAA,QAAA,CAChD;AAAA,QAEA,UAAAF;AAAA,MAAA;AAAA,IAAA;AAAA,EACH,GACF;AAEJ;"}
1
+ {"version":3,"file":"AccordionCard.js","sources":["../../../src/components/AccordionCard/AccordionCard.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport { useId, useState } from 'react';\n\nimport type { KeyboardEvent, ReactNode } from 'react';\n\nimport styles from './AccordionCard.module.css';\n\nimport { Icon } from 'components/Icon';\n\nexport interface AccordionCardProps {\n /** Clickable title (always visible). */\n title: ReactNode;\n /** Main content (hidden when expanded is false). */\n content: ReactNode;\n /** Indicator if Accordion should be expanded by default.*/\n expanded?: boolean;\n}\n\nexport const AccordionCard = ({ title, content, expanded = false }: AccordionCardProps) => {\n const [isExpanded, setIsExpanded] = useState(expanded);\n const accordionId = useId();\n\n const onKeyUp = (event: KeyboardEvent<HTMLDivElement>) => {\n const { code } = event;\n\n if (code === 'Enter' || code === 'Space') {\n setIsExpanded(!isExpanded);\n }\n };\n\n return (\n <div className={styles['accordion-card']}>\n <div\n className={styles['accordion-card__title']}\n id={accordionId}\n role=\"button\"\n tabIndex={0}\n onClick={() => setIsExpanded(!isExpanded)}\n onKeyUp={onKeyUp}\n aria-expanded={isExpanded}\n >\n <Icon\n className={clsx(styles['accordion-card__title-icon'], {\n [styles['accordion-card__title-icon--expanded']]: isExpanded,\n })}\n name=\"CheveronLeft\"\n size={16}\n />\n <h3>{title}</h3>\n </div>\n <div\n aria-labelledby={accordionId}\n className={clsx(styles['accordion-card__content'], {\n [styles['accordion-card__content--expanded']]: isExpanded,\n })}\n >\n {content}\n </div>\n </div>\n );\n};\n"],"names":["AccordionCard","title","content","expanded","isExpanded","setIsExpanded","useState","accordionId","useId","onKeyUp","event","code","jsxs","styles","jsx","Icon","clsx"],"mappings":";;;;;;;;;;;GAkBaA,IAAgB,CAAC,EAAE,OAAAC,GAAO,SAAAC,GAAS,UAAAC,IAAW,SAAgC;AACzF,QAAM,CAACC,GAAYC,CAAa,IAAIC,EAASH,CAAQ,GAC/CI,IAAcC,EAAA,GAEdC,IAAU,CAACC,MAAyC;AACxD,UAAM,EAAE,MAAAC,MAASD;AAEjB,KAAIC,MAAS,WAAWA,MAAS,YAC/BN,EAAc,CAACD,CAAU;AAAA,EAC3B;AAGF,SACE,gBAAAQ,EAAC,OAAA,EAAI,WAAWC,EAAO,gBAAgB,GACrC,UAAA;AAAA,IAAA,gBAAAD;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,WAAWC,EAAO,uBAAuB;AAAA,QACzC,IAAIN;AAAA,QACJ,MAAK;AAAA,QACL,UAAU;AAAA,QACV,SAAS,MAAMF,EAAc,CAACD,CAAU;AAAA,QACxC,SAAAK;AAAA,QACA,iBAAeL;AAAA,QAEf,UAAA;AAAA,UAAA,gBAAAU;AAAA,YAACC;AAAA,YAAA;AAAA,cACC,WAAWC,EAAKH,EAAO,4BAA4B,GAAG;AAAA,gBACpD,CAACA,EAAO,sCAAsC,CAAC,GAAGT;AAAA,cAAA,CACnD;AAAA,cACD,MAAK;AAAA,cACL,MAAM;AAAA,YAAA;AAAA,UAAA;AAAA,UAER,gBAAAU,EAAC,QAAI,UAAAb,EAAA,CAAM;AAAA,QAAA;AAAA,MAAA;AAAA,IAAA;AAAA,IAEb,gBAAAa;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,mBAAiBP;AAAA,QACjB,WAAWS,EAAKH,EAAO,yBAAyB,GAAG;AAAA,UACjD,CAACA,EAAO,mCAAmC,CAAC,GAAGT;AAAA,QAAA,CAChD;AAAA,QAEA,UAAAF;AAAA,MAAA;AAAA,IAAA;AAAA,EACH,GACF;AAEJ;"}
@@ -2,4 +2,4 @@ import { Meta } from '@storybook/react';
2
2
  import { AccordionCardProps } from './AccordionCard';
3
3
  declare const _default: Meta<AccordionCardProps>;
4
4
  export default _default;
5
- export declare const AccordionCardExample: import('@storybook/core/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, AccordionCardProps>;
5
+ export declare const AccordionCardExample: import('storybook/internal/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, AccordionCardProps>;
@@ -1 +1 @@
1
- {"version":3,"file":"AccordionCard.stories.js","sources":["../../../src/components/AccordionCard/AccordionCard.stories.tsx"],"sourcesContent":["import type { Meta, StoryFn } from '@storybook/react';\nimport type { AccordionCardProps } from './AccordionCard';\n\nimport { AccordionCard } from './AccordionCard';\n\nimport { Container } from 'storyComponents/Container';\n\nconst codeString = '<AccordionCard title={title} content={content}/>';\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n title: 'Atoms/AccordionCard',\n component: AccordionCard,\n argTypes: {\n expanded: {\n // Hide the expanded prop. Changing the value in Storybook doesn't update the state of the component.\n table: {\n disable: true,\n },\n },\n },\n parameters: {\n inspectComponent: AccordionCard,\n codeString: codeString,\n },\n} as Meta<AccordionCardProps>;\n\nconst Template: StoryFn<AccordionCardProps> = (args) => (\n <Container size=\"large\">\n <AccordionCard {...args} />\n </Container>\n);\n\nexport const AccordionCardExample = Template.bind({});\nAccordionCardExample.args = {\n title: 'Vakaanbieding 1',\n content: (\n <div>\n <h3 style={{ marginTop: '0' }}>Vakaanmelding: Het Belang van een Goede Start van Je Studiejaar</h3>\n <p>\n Vakaanmelding is een cruciale stap in het studieproces, waarbij studenten zich inschrijven voor de vakken die\n zij tijdens een semester of studiejaar willen volgen. Deze procedure is belangrijk om een gestructureerd en\n succesvol academisch traject te waarborgen. Hieronder bespreken we wat vakaanmelding inhoudt, waarom het\n essentieel is en hoe je je optimaal kunt voorbereiden.\n </p>\n <h3>Wat is vakaanmelding?</h3>\n <p>\n Vakaanmelding is het proces waarbij studenten via een digitaal systeem (zoals Blackboard, Canvas of een\n specifieke universiteitsportal) aangeven welke vakken zij willen volgen. Dit kan variëren van verplichte\n kernvakken tot keuzevakken die aansluiten bij persoonlijke interesses of specialisaties.\n </p>\n </div>\n ),\n};\n"],"names":["codeString","AccordionCard_stories","AccordionCard","Template","args","jsx","Container","AccordionCardExample"],"mappings":";;;AAOA,MAAMA,IAAa,oDAGJC,IAAA;AAAA,EACb,OAAO;AAAA,EACP,WAAWC;AAAA,EACX,UAAU;AAAA,IACR,UAAU;AAAA;AAAA,MAER,OAAO;AAAA,QACL,SAAS;AAAA,MAAA;AAAA,IACX;AAAA,EAEJ;AAAA,EACA,YAAY;AAAA,IACV,kBAAkBA;AAAA,IAClB,YAAAF;AAAA,EAAA;AAEJ,GAEMG,IAAwC,CAACC,MAC5C,gBAAAC,EAAAC,GAAA,EAAU,MAAK,SACd,UAAC,gBAAAD,EAAAH,GAAA,EAAe,GAAGE,EAAA,CAAM,EAC3B,CAAA,GAGWG,IAAuBJ,EAAS,KAAK,CAAE,CAAA;AACpDI,EAAqB,OAAO;AAAA,EAC1B,OAAO;AAAA,EACP,2BACG,OACC,EAAA,UAAA;AAAA,IAAA,gBAAAF,EAAC,QAAG,OAAO,EAAE,WAAW,OAAO,UAA+D,mEAAA;AAAA,IAC9F,gBAAAA,EAAC,OAAE,UAKH,4XAAA,CAAA;AAAA,IACA,gBAAAA,EAAC,QAAG,UAAqB,wBAAA,CAAA;AAAA,IACzB,gBAAAA,EAAC,OAAE,UAIH,4SAAA,CAAA;AAAA,EAAA,EACF,CAAA;AAEJ;"}
1
+ {"version":3,"file":"AccordionCard.stories.js","sources":["../../../src/components/AccordionCard/AccordionCard.stories.tsx"],"sourcesContent":["import type { Meta, StoryFn } from '@storybook/react';\nimport type { AccordionCardProps } from './AccordionCard';\n\nimport { AccordionCard } from './AccordionCard';\n\nimport { Container } from 'storyComponents/Container';\n\nconst codeString = '<AccordionCard title={title} content={content}/>';\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n title: 'Atoms/AccordionCard',\n component: AccordionCard,\n argTypes: {\n expanded: {\n // Hide the expanded prop. Changing the value in Storybook doesn't update the state of the component.\n table: {\n disable: true,\n },\n },\n },\n parameters: {\n inspectComponent: AccordionCard,\n codeString: codeString,\n },\n} as Meta<AccordionCardProps>;\n\nconst Template: StoryFn<AccordionCardProps> = (args) => (\n <Container size=\"large\">\n <AccordionCard {...args} />\n </Container>\n);\n\nexport const AccordionCardExample = Template.bind({});\nAccordionCardExample.args = {\n title: 'Vakaanbieding 1',\n content: (\n <div>\n <h3 style={{ marginTop: '0' }}>Vakaanmelding: Het Belang van een Goede Start van Je Studiejaar</h3>\n <p>\n Vakaanmelding is een cruciale stap in het studieproces, waarbij studenten zich inschrijven voor de vakken die\n zij tijdens een semester of studiejaar willen volgen. Deze procedure is belangrijk om een gestructureerd en\n succesvol academisch traject te waarborgen. Hieronder bespreken we wat vakaanmelding inhoudt, waarom het\n essentieel is en hoe je je optimaal kunt voorbereiden.\n </p>\n <h3>Wat is vakaanmelding?</h3>\n <p>\n Vakaanmelding is het proces waarbij studenten via een digitaal systeem (zoals Blackboard, Canvas of een\n specifieke universiteitsportal) aangeven welke vakken zij willen volgen. Dit kan variëren van verplichte\n kernvakken tot keuzevakken die aansluiten bij persoonlijke interesses of specialisaties.\n </p>\n </div>\n ),\n};\n"],"names":["codeString","AccordionCard_stories","AccordionCard","Template","args","jsx","Container","AccordionCardExample"],"mappings":";;;AAOA,MAAMA,IAAa,oDAGnBC,IAAe;AAAA,EACb,OAAO;AAAA,EACP,WAAWC;AAAA,EACX,UAAU;AAAA,IACR,UAAU;AAAA;AAAA,MAER,OAAO;AAAA,QACL,SAAS;AAAA,MAAA;AAAA,IACX;AAAA,EACF;AAAA,EAEF,YAAY;AAAA,IACV,kBAAkBA;AAAA,IAClB,YAAAF;AAAA,EAAA;AAEJ,GAEMG,IAAwC,CAACC,MAC7C,gBAAAC,EAACC,GAAA,EAAU,MAAK,SACd,UAAA,gBAAAD,EAACH,GAAA,EAAe,GAAGE,EAAA,CAAM,EAAA,CAC3B,GAGWG,IAAuBJ,EAAS,KAAK,CAAA,CAAE;AACpDI,EAAqB,OAAO;AAAA,EAC1B,OAAO;AAAA,EACP,2BACG,OAAA,EACC,UAAA;AAAA,IAAA,gBAAAF,EAAC,QAAG,OAAO,EAAE,WAAW,IAAA,GAAO,UAAA,mEAA+D;AAAA,IAC9F,gBAAAA,EAAC,OAAE,UAAA,4XAAA,CAKH;AAAA,IACA,gBAAAA,EAAC,QAAG,UAAA,wBAAA,CAAqB;AAAA,IACzB,gBAAAA,EAAC,OAAE,UAAA,4SAAA,CAIH;AAAA,EAAA,EAAA,CACF;AAEJ;"}
@@ -1,7 +1,7 @@
1
1
  import { jsx as n } from "react/jsx-runtime";
2
- import "../../index-BqLi4tOb.js";
3
- import { r as c, s as e, f as s, w as d } from "../../react.esm-CsMDid07.js";
4
- import { u as r } from "../../index-CUap8sKR.js";
2
+ import "../../index-DV47hRzi.js";
3
+ import { r as c, s as e, f as s, w as d } from "../../react.esm-CFMwGdo5.js";
4
+ import { u as r } from "../../index-PaHiqSUg.js";
5
5
  import { AccordionCard as a } from "./AccordionCard.js";
6
6
  describe("AccordionCard", () => {
7
7
  it("should render", () => {
@@ -1 +1 @@
1
- {"version":3,"file":"AccordionCard.test.js","sources":["../../../src/components/AccordionCard/AccordionCard.test.tsx"],"sourcesContent":["import '@testing-library/jest-dom';\nimport { fireEvent, render, screen, waitFor } from '@testing-library/react';\nimport userEvent from '@testing-library/user-event';\n\nimport { AccordionCard } from './AccordionCard';\n\ndescribe('AccordionCard', () => {\n it('should render', () => {\n render(<AccordionCard title=\"Test Accordion Card\" content={'TestComponent'} expanded />);\n expect(screen.getByText('Test Accordion Card')).toBeInTheDocument();\n expect(screen.getByText('TestComponent')).toBeInTheDocument();\n });\n\n it('should display content when expanded by default', () => {\n render(<AccordionCard title=\"Test Accordion Card\" content={'TestComponent'} expanded />);\n expect(screen.getByText('Test Accordion Card')).toBeInTheDocument();\n expect(screen.getByText('TestComponent')).toHaveClass('accordion-card__content--expanded');\n });\n\n it('should toggle content visibility on click', () => {\n render(<AccordionCard title=\"Test Accordion Card\" content={'TestComponent'} />);\n const titleElement = screen.getByText('Test Accordion Card');\n const contentElement = screen.getByText('TestComponent');\n expect(titleElement).toBeInTheDocument();\n fireEvent.click(titleElement);\n expect(contentElement).toHaveClass('accordion-card__content--expanded');\n fireEvent.click(titleElement);\n expect(contentElement).not.toHaveClass('accordion-card__content--expanded');\n });\n\n it('should toggle content visibility on Enter key press', async () => {\n render(<AccordionCard title=\"Test Accordion Card\" content={'TestComponent'} />);\n const titleElement = screen.getByRole('button');\n const contentElement = screen.getByText('TestComponent');\n titleElement.focus();\n await userEvent.keyboard('[Enter]');\n await waitFor(() => {\n expect(contentElement).toHaveClass('accordion-card__content--expanded');\n });\n await userEvent.keyboard('[Enter]');\n await waitFor(() => {\n expect(contentElement).not.toHaveClass('accordion-card__content--expanded');\n });\n });\n\n it('should toggle content visibility on Space key press', async () => {\n render(<AccordionCard title=\"Test Accordion Card\" content={'TestComponent'} />);\n const titleElement = screen.getByRole('button');\n const contentElement = screen.getByText('TestComponent');\n titleElement.focus();\n await userEvent.keyboard('[Space]');\n await waitFor(() => {\n expect(contentElement).toHaveClass('accordion-card__content--expanded');\n });\n await userEvent.keyboard('[Space]');\n await waitFor(() => {\n expect(contentElement).not.toHaveClass('accordion-card__content--expanded');\n });\n });\n});\n"],"names":["render","jsx","AccordionCard","screen","titleElement","contentElement","fireEvent","userEvent","waitFor"],"mappings":";;;;;AAMA,SAAS,iBAAiB,MAAM;AAC9B,KAAG,iBAAiB,MAAM;AACjB,IAAAA,EAAA,gBAAAC,EAACC,KAAc,OAAM,uBAAsB,SAAS,iBAAiB,UAAQ,IAAC,CAAE,GACvF,OAAOC,EAAO,UAAU,qBAAqB,CAAC,EAAE,kBAAkB,GAClE,OAAOA,EAAO,UAAU,eAAe,CAAC,EAAE,kBAAkB;AAAA,EAAA,CAC7D,GAED,GAAG,mDAAmD,MAAM;AACnD,IAAAH,EAAA,gBAAAC,EAACC,KAAc,OAAM,uBAAsB,S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Ac,EAAE,YAAY,mCAAmC;AAAA,IAAA,CACvE,GACK,MAAAE,EAAU,SAAS,SAAS,GAClC,MAAMC,EAAQ,MAAM;AAClB,aAAOH,CAAc,EAAE,IAAI,YAAY,mCAAmC;AAAA,IAAA,CAC3E;AAAA,EAAA,CACF;AACH,CAAC;"}
1
+ {"version":3,"file":"AccordionCard.test.js","sources":["../../../src/components/AccordionCard/AccordionCard.test.tsx"],"sourcesContent":["import '@testing-library/jest-dom';\nimport { fireEvent, render, screen, waitFor } from '@testing-library/react';\nimport userEvent from '@testing-library/user-event';\n\nimport { AccordionCard } from './AccordionCard';\n\ndescribe('AccordionCard', () => {\n it('should render', () => {\n render(<AccordionCard title=\"Test Accordion Card\" content={'TestComponent'} expanded />);\n expect(screen.getByText('Test Accordion Card')).toBeInTheDocument();\n expect(screen.getByText('TestComponent')).toBeInTheDocument();\n });\n\n it('should display content when expanded by default', () => {\n render(<AccordionCard title=\"Test Accordion Card\" content={'TestComponent'} expanded />);\n expect(screen.getByText('Test Accordion Card')).toBeInTheDocument();\n expect(screen.getByText('TestComponent')).toHaveClass('accordion-card__content--expanded');\n });\n\n it('should toggle content visibility on click', () => {\n render(<AccordionCard title=\"Test Accordion Card\" content={'TestComponent'} />);\n const titleElement = screen.getByText('Test Accordion Card');\n const contentElement = screen.getByText('TestComponent');\n expect(titleElement).toBeInTheDocument();\n fireEvent.click(titleElement);\n expect(contentElement).toHaveClass('accordion-card__content--expanded');\n fireEvent.click(titleElement);\n expect(contentElement).not.toHaveClass('accordion-card__content--expanded');\n });\n\n it('should toggle content visibility on Enter key press', async () => {\n render(<AccordionCard title=\"Test Accordion Card\" content={'TestComponent'} />);\n const titleElement = screen.getByRole('button');\n const contentElement = screen.getByText('TestComponent');\n titleElement.focus();\n await userEvent.keyboard('[Enter]');\n await waitFor(() => {\n expect(contentElement).toHaveClass('accordion-card__content--expanded');\n });\n await userEvent.keyboard('[Enter]');\n await waitFor(() => {\n expect(contentElement).not.toHaveClass('accordion-card__content--expanded');\n });\n });\n\n it('should toggle content visibility on Space key press', async () => {\n render(<AccordionCard title=\"Test Accordion Card\" content={'TestComponent'} />);\n const titleElement = screen.getByRole('button');\n const contentElement = screen.getByText('TestComponent');\n titleElement.focus();\n await userEvent.keyboard('[Space]');\n await waitFor(() => {\n expect(contentElement).toHaveClass('accordion-card__content--expanded');\n });\n await userEvent.keyboard('[Space]');\n await waitFor(() => {\n expect(contentElement).not.toHaveClass('accordion-card__content--expanded');\n });\n });\n});\n"],"names":["render","jsx","AccordionCard","screen","titleElement","contentElement","fireEvent","userEvent","waitFor"],"mappings":";;;;;AAMA,SAAS,iBAAiB,MAAM;AAC9B,KAAG,iBAAiB,MAAM;AACxB,IAAAA,EAAO,gBAAAC,EAACC,KAAc,OAAM,uBAAsB,SAAS,iBAAiB,UAAQ,IAAC,CAAE,GACvF,OAAOC,EAAO,UAAU,qBAAqB,CAAC,EAAE,kBAAA,GAChD,OAAOA,EAAO,UAAU,eAAe,CAAC,EAAE,kBAAA;AAAA,EAAkB,CAC7D,GAED,GAAG,mDAAmD,MAAM;AAC1D,IAAAH,EAAO,gBAAAC,EAACC,KAAc,OAAM,uBAAsB,SAAS,iBAAiB,UAAQ,IAAC,CAAE,GACvF,OAAOC,EAAO,UAAU,qBAAqB,CAAC,EAAE,kBAAA,GAChD,OAAOA,EAAO,UAAU,eAAe,CAAC,EAAE,YAAY,mCAAmC;AAAA,EAAA,CAC1F,GAED,GAAG,6CAA6C,MAAM;AACpD,IAAAH,oBAAQE,GAAA,EAAc,OAAM,uBAAsB,SAAS,iBAAiB,CAAE;AAC9E,UAAME,IAAeD,EAAO,UAAU,qBAAqB,GACrDE,IAAiBF,EAAO,UAAU,eAAe;AACvD,WAAOC,CAAY,EAAE,kBAAA,GACrBE,EAAU,MAAMF,CAAY,GAC5B,OAAOC,CAAc,EAAE,YAAY,mCAAmC,GACtEC,EAAU,MAAMF,CAAY,GAC5B,OAAOC,CAAc,EAAE,IAAI,YAAY,mCAAmC;AAAA,EAAA,CAC3E,GAED,GAAG,uDAAuD,YAAY;AACpE,IAAAL,oBAAQE,GAAA,EAAc,OAAM,uBAAsB,SAAS,iBAAiB,CAAE;AAC9E,UAAME,IAAeD,EAAO,UAAU,QAAQ,GACxCE,IAAiBF,EAAO,UAAU,eAAe;AACvD,IAAAC,EAAa,MAAA,GACb,MAAMG,EAAU,SAAS,SAAS,GAClC,MAAMC,EAAQ,MAAM;AAClB,aAAOH,CAAc,EAAE,YAAY,mCAAmC;AAAA,IAAA,CACvE,GACD,MAAME,EAAU,SAAS,SAAS,GAClC,MAAMC,EAAQ,MAAM;AAClB,aAAOH,CAAc,EAAE,IAAI,YAAY,mCAAmC;AAAA,IAAA,CAC3E;AAAA,EAAA,CACF,GAED,GAAG,uDAAuD,YAAY;AACpE,IAAAL,oBAAQE,GAAA,EAAc,OAAM,uBAAsB,SAAS,iBAAiB,CAAE;AAC9E,UAAME,IAAeD,EAAO,UAAU,QAAQ,GACxCE,IAAiBF,EAAO,UAAU,eAAe;AACvD,IAAAC,EAAa,MAAA,GACb,MAAMG,EAAU,SAAS,SAAS,GAClC,MAAMC,EAAQ,MAAM;AAClB,aAAOH,CAAc,EAAE,YAAY,mCAAmC;AAAA,IAAA,CACvE,GACD,MAAME,EAAU,SAAS,SAAS,GAClC,MAAMC,EAAQ,MAAM;AAClB,aAAOH,CAAc,EAAE,IAAI,YAAY,mCAAmC;AAAA,IAAA,CAC3E;AAAA,EAAA,CACF;AACH,CAAC;"}
@@ -1 +1 @@
1
- {"version":3,"file":"ActionList.js","sources":["../../../src/components/ActionList/ActionList.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport { Children, useEffect, useId, useRef, useState } from 'react';\n\nimport type { KeyboardEvent, MouseEvent as ReactMouseEvent, ReactElement, RefObject } from 'react';\nimport type { IconProps } from 'components/Icon';\nimport type { UIButtonVariant } from 'types/UserInterface';\n\nimport styles from './ActionList.module.css';\n\nimport { Icon } from 'components/Icon';\nimport { MenuButton } from 'components/Buttons';\n\nexport interface ActionListProps {\n /** The label that is displayed before the icon. */\n label: string;\n /** The icon that is shown in front of the label. */\n prefixIcon?: IconProps['name'];\n /** The icon that is shown to toggle the menu. If none is specified, CheveronUp and CheveronDown is used depending on whether the menu is opened or closed. */\n iconName?: IconProps['name'];\n /** Determines the button variant. */\n variant?: UIButtonVariant;\n /** The child component(s). */\n children: ReactElement | ReactElement[];\n}\n\nconst inactiveIndex = -1;\nconst indexIncrement = 1;\n\n/** A component to show an action list to toggle a menu. */\nexport function ActionList({ label, prefixIcon, iconName, variant = 'secondary', children }: ActionListProps) {\n const listId = useId();\n const triggerRef = useRef<HTMLButtonElement>(null);\n const listRef = useRef<HTMLDivElement>(null);\n const containerRef = useRef<HTMLDivElement>(null);\n\n const numberOfChildren = Children.count(children);\n\n const [activeIndex, setActiveIndex] = useState(inactiveIndex);\n const [isOpen, setIsOpen] = useState(false);\n\n function open() {\n setIsOpen(true);\n\n document.addEventListener('click', onClickOutside, { once: true, capture: true });\n }\n\n function close(event?: ReactMouseEvent<HTMLDivElement>) {\n // When a click occurs on an element that is not an immediate descendant of the action list container\n // (can happen when a modal window is triggered from a button in the action list), the setIsOpen state\n // handler should not be called, because this causes a re-render of the entire component and can lead\n // to undesired effects, like a select element closing immediately after it has been clicked.\n if (event && containerRef.current && !containerRef.current.contains(event.target as Node)) {\n return;\n }\n\n setActiveIndex(inactiveIndex);\n setIsOpen(false);\n\n document.removeEventListener('click', onClickOutside, { capture: true });\n }\n\n function toggle() {\n if (isOpen) close();\n else open();\n }\n\n function onKeyDown(event: KeyboardEvent) {\n if (!isOpen) return;\n\n const eventPreventCodes = ['ArrowUp', 'ArrowDown', 'Home', 'End'];\n\n if (eventPreventCodes.includes(event.code)) {\n // prevent page from scrolling when navigating through items in list\n event.preventDefault();\n }\n\n if (event.code === 'Tab') {\n close();\n }\n }\n\n function onKeyUp(event: KeyboardEvent) {\n if (event.code === 'Space' || event.key === 'Enter') {\n if (event.target === triggerRef.current) {\n toggle();\n } else if (event.key === 'Enter' && event.target !== listRef.current) {\n if ('firstChild' in event.target) {\n const firstChild = event.target.firstChild as HTMLButtonElement;\n\n firstChild.click();\n }\n }\n }\n\n if (event.code === 'Escape') close();\n\n if (event.code === 'ArrowUp') {\n setActiveIndex((prevState) => {\n if (prevState === 0) return numberOfChildren - indexIncrement;\n\n return prevState - indexIncrement;\n });\n }\n\n if (event.code === 'ArrowDown') {\n setActiveIndex((prevState) => {\n if (prevState === numberOfChildren - indexIncrement) return 0;\n\n return prevState + indexIncrement;\n });\n }\n\n if (event.code === 'Home') {\n setActiveIndex(0);\n }\n\n if (event.code === 'End') {\n setActiveIndex(numberOfChildren - indexIncrement);\n }\n }\n\n const onClickOutside = (event: MouseEvent) => {\n const { target } = event;\n\n if (!target || !containerRef.current) return;\n\n if (!containerRef.current.contains(target as Node)) {\n close();\n }\n };\n\n useEffect(() => {\n if (activeIndex < 0 || !listRef.current) return;\n\n const listItem = listRef.current.children.item(activeIndex);\n\n if (listItem) {\n (listItem as HTMLDivElement).focus();\n }\n }, [activeIndex]);\n\n useEffect(() => {\n if (!listRef.current || !listRef.current.hasChildNodes()) return;\n\n Array.from(listRef.current.children)\n .filter((overlayChild) => overlayChild.nodeType === Node.ELEMENT_NODE && overlayChild.hasChildNodes())\n .forEach((overlayChild) => {\n Array.from(overlayChild.children)\n .filter((childOfChild) => childOfChild.nodeType === Node.ELEMENT_NODE)\n .forEach((childOfChild) => {\n // internal children may be buttons and can get focus when tab is pressed; preventing those elements\n // from getting focus so that list can be tabbed over and traversed with arrow keys\n childOfChild.setAttribute('tabIndex', '-1');\n });\n });\n }, [children]);\n\n return (\n <div className={styles['action-list-container']} ref={containerRef}>\n <MenuButton\n onClick={toggle}\n onKeyDown={onKeyDown}\n onKeyUp={onKeyUp}\n buttonRef={triggerRef as RefObject<HTMLButtonElement>}\n variant={variant}\n >\n {prefixIcon && <Icon size={24} name={prefixIcon} />}\n {label}\n {iconName ? (\n <Icon size={24} name={iconName} />\n ) : (\n <Icon size={16} name={isOpen ? 'CheveronUp' : 'CheveronDown'} />\n )}\n </MenuButton>\n <div\n aria-activedescendant={`${listId}-child-${activeIndex}`}\n aria-label={label}\n className={clsx(styles['action-list'], {\n [styles['action-list--open']]: isOpen,\n })}\n onClickCapture={close}\n onKeyDown={onKeyDown}\n onKeyUp={onKeyUp}\n ref={listRef}\n role=\"menu\"\n tabIndex={-1}\n >\n {Children.map(children, (child, index) => (\n <div key={`${listId}-child-${index}`} role=\"menuitem\" tabIndex={-1}>\n {child}\n </div>\n ))}\n </div>\n </div>\n );\n}\n"],"names":["inactiveIndex","indexIncrement","ActionList","label","prefixIcon","iconName","variant","children","listId","useId","triggerRef","useRef","listRef","containerRef","numberOfChildren","Children","activeIndex","setActiveIndex","useState","isOpen","setIsOpen","open","onClickOutside","close","event","toggle","onKeyDown","onKeyUp","prevState","target","useEffect","listItem","overlayChild","childOfChild","styles","jsxs","MenuButton","jsx","Icon","clsx","child","index"],"mappings":";;;;;;;;;;;GAyBMA,IAAgB,IAChBC,IAAiB;AAGP,SAAAC,EAAW,EAAE,OAAAC,GAAO,YAAAC,GAAY,UAAAC,GAAU,SAAAC,IAAU,aAAa,UAAAC,KAA6B;AAC5G,QAAMC,IAASC,EAAM,GACfC,IAAaC,EAA0B,IAAI,GAC3CC,IAAUD,EAAuB,IAAI,GACrCE,IAAeF,EAAuB,IAAI,GAE1CG,IAAmBC,EAAS,MAAMR,CAAQ,GAE1C,CAACS,GAAaC,CAAc,IAAIC,EAASlB,CAAa,GACtD,CAACmB,GAAQC,CAAS,IAAIF,EAAS,EAAK;AAE1C,WAASG,IAAO;AACd,IAAAD,EAAU,EAAI,GAEL,SAAA,iBAAiB,SAASE,GAAgB,EAAE,MAAM,IAAM,SAAS,IAAM;AAAA,EAAA;AAGlF,WAASC,EAAMC,GAAyC;AAKlD,IAAAA,KAASX,EAAa,WAAW,CAACA,EAAa,QAAQ,SAASW,EAAM,MAAc,MAIxFP,EAAejB,CAAa,GAC5BoB,E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,MAAK;AAAA,QACL,UAAU;AAAA,QAET,YAAS,IAAIL,GAAU,CAACiC,GAAOC,wBAC7B,OAAqC,EAAA,MAAK,YAAW,UAAU,IAC7D,UADOD,EAAA,GAAA,GAAGhC,CAAM,UAAUiC,CAAK,EAElC,CACD;AAAA,MAAA;AAAA,IAAA;AAAA,EACH,GACF;AAEJ;"}
1
+ {"version":3,"file":"ActionList.js","sources":["../../../src/components/ActionList/ActionList.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport { Children, useEffect, useId, useRef, useState } from 'react';\n\nimport type { KeyboardEvent, MouseEvent as ReactMouseEvent, ReactElement, RefObject } from 'react';\nimport type { IconProps } from 'components/Icon';\nimport type { UIButtonVariant } from 'types/UserInterface';\n\nimport styles from './ActionList.module.css';\n\nimport { Icon } from 'components/Icon';\nimport { MenuButton } from 'components/Buttons';\n\nexport interface ActionListProps {\n /** The label that is displayed before the icon. */\n label: string;\n /** The icon that is shown in front of the label. */\n prefixIcon?: IconProps['name'];\n /** The icon that is shown to toggle the menu. If none is specified, CheveronUp and CheveronDown is used depending on whether the menu is opened or closed. */\n iconName?: IconProps['name'];\n /** Determines the button variant. */\n variant?: UIButtonVariant;\n /** The child component(s). */\n children: ReactElement | ReactElement[];\n}\n\nconst inactiveIndex = -1;\nconst indexIncrement = 1;\n\n/** A component to show an action list to toggle a menu. */\nexport function ActionList({ label, prefixIcon, iconName, variant = 'secondary', children }: ActionListProps) {\n const listId = useId();\n const triggerRef = useRef<HTMLButtonElement>(null);\n const listRef = useRef<HTMLDivElement>(null);\n const containerRef = useRef<HTMLDivElement>(null);\n\n const numberOfChildren = Children.count(children);\n\n const [activeIndex, setActiveIndex] = useState(inactiveIndex);\n const [isOpen, setIsOpen] = useState(false);\n\n function open() {\n setIsOpen(true);\n\n document.addEventListener('click', onClickOutside, { once: true, capture: true });\n }\n\n function close(event?: ReactMouseEvent<HTMLDivElement>) {\n // When a click occurs on an element that is not an immediate descendant of the action list container\n // (can happen when a modal window is triggered from a button in the action list), the setIsOpen state\n // handler should not be called, because this causes a re-render of the entire component and can lead\n // to undesired effects, like a select element closing immediately after it has been clicked.\n if (event && containerRef.current && !containerRef.current.contains(event.target as Node)) {\n return;\n }\n\n setActiveIndex(inactiveIndex);\n setIsOpen(false);\n\n document.removeEventListener('click', onClickOutside, { capture: true });\n }\n\n function toggle() {\n if (isOpen) close();\n else open();\n }\n\n function onKeyDown(event: KeyboardEvent) {\n if (!isOpen) return;\n\n const eventPreventCodes = ['ArrowUp', 'ArrowDown', 'Home', 'End'];\n\n if (eventPreventCodes.includes(event.code)) {\n // prevent page from scrolling when navigating through items in list\n event.preventDefault();\n }\n\n if (event.code === 'Tab') {\n close();\n }\n }\n\n function onKeyUp(event: KeyboardEvent) {\n if (event.code === 'Space' || event.key === 'Enter') {\n if (event.target === triggerRef.current) {\n toggle();\n } else if (event.key === 'Enter' && event.target !== listRef.current) {\n if ('firstChild' in event.target) {\n const firstChild = event.target.firstChild as HTMLButtonElement;\n\n firstChild.click();\n }\n }\n }\n\n if (event.code === 'Escape') close();\n\n if (event.code === 'ArrowUp') {\n setActiveIndex((prevState) => {\n if (prevState === 0) return numberOfChildren - indexIncrement;\n\n return prevState - indexIncrement;\n });\n }\n\n if (event.code === 'ArrowDown') {\n setActiveIndex((prevState) => {\n if (prevState === numberOfChildren - indexIncrement) return 0;\n\n return prevState + indexIncrement;\n });\n }\n\n if (event.code === 'Home') {\n setActiveIndex(0);\n }\n\n if (event.code === 'End') {\n setActiveIndex(numberOfChildren - indexIncrement);\n }\n }\n\n const onClickOutside = (event: MouseEvent) => {\n const { target } = event;\n\n if (!target || !containerRef.current) return;\n\n if (!containerRef.current.contains(target as Node)) {\n close();\n }\n };\n\n useEffect(() => {\n if (activeIndex < 0 || !listRef.current) return;\n\n const listItem = listRef.current.children.item(activeIndex);\n\n if (listItem) {\n (listItem as HTMLDivElement).focus();\n }\n }, [activeIndex]);\n\n useEffect(() => {\n if (!listRef.current || !listRef.current.hasChildNodes()) return;\n\n Array.from(listRef.current.children)\n .filter((overlayChild) => overlayChild.nodeType === Node.ELEMENT_NODE && overlayChild.hasChildNodes())\n .forEach((overlayChild) => {\n Array.from(overlayChild.children)\n .filter((childOfChild) => childOfChild.nodeType === Node.ELEMENT_NODE)\n .forEach((childOfChild) => {\n // internal children may be buttons and can get focus when tab is pressed; preventing those elements\n // from getting focus so that list can be tabbed over and traversed with arrow keys\n childOfChild.setAttribute('tabIndex', '-1');\n });\n });\n }, [children]);\n\n return (\n <div className={styles['action-list-container']} ref={containerRef}>\n <MenuButton\n onClick={toggle}\n onKeyDown={onKeyDown}\n onKeyUp={onKeyUp}\n buttonRef={triggerRef as RefObject<HTMLButtonElement>}\n variant={variant}\n >\n {prefixIcon && <Icon size={24} name={prefixIcon} />}\n {label}\n {iconName ? (\n <Icon size={24} name={iconName} />\n ) : (\n <Icon size={16} name={isOpen ? 'CheveronUp' : 'CheveronDown'} />\n )}\n </MenuButton>\n <div\n aria-activedescendant={`${listId}-child-${activeIndex}`}\n aria-label={label}\n className={clsx(styles['action-list'], {\n [styles['action-list--open']]: isOpen,\n })}\n onClickCapture={close}\n onKeyDown={onKeyDown}\n onKeyUp={onKeyUp}\n ref={listRef}\n role=\"menu\"\n tabIndex={-1}\n >\n {Children.map(children, (child, index) => (\n <div key={`${listId}-child-${index}`} role=\"menuitem\" tabIndex={-1}>\n {child}\n </div>\n ))}\n </div>\n </div>\n );\n}\n"],"names":["inactiveIndex","indexIncrement","ActionList","label","prefixIcon","iconName","variant","children","listId","useId","triggerRef","useRef","listRef","containerRef","numberOfChildren","Children","activeIndex","setActiveIndex","useState","isOpen","setIsOpen","open","onClickOutside","close","event","toggle","onKeyDown","onKeyUp","prevState","target","useEffect","listItem","overlayChild","childOfChild","styles","jsxs","MenuButton","jsx","Icon","clsx","child","index"],"mappings":";;;;;;;;;;;GAyBMA,IAAgB,IAChBC,IAAiB;AAGhB,SAASC,EAAW,EAAE,OAAAC,GAAO,YAAAC,GAAY,UAAAC,GAA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AI,MAAMlC,GAAY;AAAA,UAChDD;AAAA,UACAE,IACC,gBAAAgC,EAACC,GAAA,EAAK,MAAM,IAAI,MAAMjC,EAAA,CAAU,IAEhC,gBAAAgC,EAACC,KAAK,MAAM,IAAI,MAAMnB,IAAS,eAAe,eAAA,CAAgB;AAAA,QAAA;AAAA,MAAA;AAAA,IAAA;AAAA,IAGlE,gBAAAkB;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,yBAAuB,GAAG7B,CAAM,UAAUQ,CAAW;AAAA,QACrD,cAAYb;AAAA,QACZ,WAAWoC,EAAKL,EAAO,aAAa,GAAG;AAAA,UACrC,CAACA,EAAO,mBAAmB,CAAC,GAAGf;AAAA,QAAA,CAChC;AAAA,QACD,gBAAgBI;AAAA,QAChB,WAAAG;AAAA,QACA,SAAAC;AAAA,QACA,KAAKf;AAAA,QACL,MAAK;AAAA,QACL,UAAU;AAAA,QAET,YAAS,IAAIL,GAAU,CAACiC,GAAOC,wBAC7B,OAAA,EAAqC,MAAK,YAAW,UAAU,IAC7D,UAAAD,EAAA,GADO,GAAGhC,CAAM,UAAUiC,CAAK,EAElC,CACD;AAAA,MAAA;AAAA,IAAA;AAAA,EACH,GACF;AAEJ;"}
@@ -2,4 +2,4 @@ import { Meta } from '@storybook/react';
2
2
  import { ActionListProps } from './ActionList';
3
3
  declare const _default: Meta<ActionListProps>;
4
4
  export default _default;
5
- export declare const ActionListExample: import('@storybook/core/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, ActionListProps>;
5
+ export declare const ActionListExample: import('storybook/internal/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, ActionListProps>;
@@ -1 +1 @@
1
- {"version":3,"file":"ActionList.stories.js","sources":["../../../src/components/ActionList/ActionList.stories.tsx"],"sourcesContent":["import type { Meta, StoryFn } from '@storybook/react';\nimport type { ActionListProps } from './ActionList';\n\nimport { ActionList } from './ActionList';\n\nconst codeString = `\n <ActionList iconName={iconName} variant={variant} label=\"\">\n {mockActions.map(({ action, value }) => (\n <button type=\"button\" onClick={() => onActionClick({ action, id })} key={value}> {action.title} </button>\n ))}\n </ActionList>\n`;\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n title: 'Atoms/ActionList',\n component: ActionList,\n argTypes: {\n variant: {\n options: ['primary', 'secondary', 'destructive-primary', 'destructive-secondary', 'blank', 'blank-icon'],\n control: { type: 'radio' },\n },\n },\n parameters: {\n inspectComponent: ActionList,\n codeString: codeString,\n },\n} as Meta<ActionListProps>;\n\nconst Template: StoryFn<ActionListProps> = (args) => (\n <div style={{ marginLeft: '5rem', width: '40px' }}>\n <ActionList {...args} />\n </div>\n);\n\nconst defaultArgs: Partial<ActionListProps> = {\n label: '',\n variant: 'blank-icon',\n iconName: 'EllipsisVertical',\n children: [\n <button key=\"1\" type=\"button\">\n Action 1\n </button>,\n <button key=\"2\" type=\"button\">\n Action 2\n </button>,\n <button key=\"3\" type=\"button\">\n Action 3\n </button>,\n ],\n};\n\nexport const ActionListExample = Template.bind({});\nActionListExample.args = {\n ...defaultArgs,\n};\n"],"names":["codeString","ActionList_stories","ActionList","Template","args","jsx","defaultArgs","ActionListExample"],"mappings":";;AAKA,MAAMA,IAAa;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,GASJC,IAAA;AAAA,EACb,OAAO;AAAA,EACP,WAAWC;AAAA,EACX,UAAU;AAAA,IACR,SAAS;AAAA,MACP,SAAS,CAAC,WAAW,aAAa,uBAAuB,yBAAyB,SAAS,YAAY;AAAA,MACvG,SAAS,EAAE,MAAM,QAAQ;AAAA,IAAA;AAAA,EAE7B;AAAA,EACA,YAAY;AAAA,IACV,kBAAkBA;AAAA,IAClB,YAAAF;AAAA,EAAA;AAEJ,GAEMG,IAAqC,CAACC,MACzC,gBAAAC,EAAA,OAAA,EAAI,OAAO,EAAE,YAAY,QAAQ,OAAO,UACvC,UAAA,gBAAAA,EAACH,GAAY,EAAA,GAAGE,EAAM,CAAA,GACxB,GAGIE,IAAwC;AAAA,EAC5C,OAAO;AAAA,EACP,SAAS;AAAA,EACT,UAAU;AAAA,EACV,UAAU;AAAA,IACP,gBAAAD,EAAA,UAAA,EAAe,MAAK,UAAS,wBAAlB,GAEZ;AAAA,IACC,gBAAAA,EAAA,UAAA,EAAe,MAAK,UAAS,wBAAlB,GAEZ;AAAA,IACC,gBAAAA,EAAA,UAAA,EAAe,MAAK,UAAS,wBAAlB,GAEZ;AAAA,EAAA;AAEJ,GAEaE,IAAoBJ,EAAS,KAAK,CAAE,CAAA;AACjDI,EAAkB,OAAO;AAAA,EACvB,GAAGD;AACL;"}
1
+ {"version":3,"file":"ActionList.stories.js","sources":["../../../src/components/ActionList/ActionList.stories.tsx"],"sourcesContent":["import type { Meta, StoryFn } from '@storybook/react';\nimport type { ActionListProps } from './ActionList';\n\nimport { ActionList } from './ActionList';\n\nconst codeString = `\n <ActionList iconName={iconName} variant={variant} label=\"\">\n {mockActions.map(({ action, value }) => (\n <button type=\"button\" onClick={() => onActionClick({ action, id })} key={value}> {action.title} </button>\n ))}\n </ActionList>\n`;\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n title: 'Atoms/ActionList',\n component: ActionList,\n argTypes: {\n variant: {\n options: ['primary', 'secondary', 'destructive-primary', 'destructive-secondary', 'blank', 'blank-icon'],\n control: { type: 'radio' },\n },\n },\n parameters: {\n inspectComponent: ActionList,\n codeString: codeString,\n },\n} as Meta<ActionListProps>;\n\nconst Template: StoryFn<ActionListProps> = (args) => (\n <div style={{ marginLeft: '5rem', width: '40px' }}>\n <ActionList {...args} />\n </div>\n);\n\nconst defaultArgs: Partial<ActionListProps> = {\n label: '',\n variant: 'blank-icon',\n iconName: 'EllipsisVertical',\n children: [\n <button key=\"1\" type=\"button\">\n Action 1\n </button>,\n <button key=\"2\" type=\"button\">\n Action 2\n </button>,\n <button key=\"3\" type=\"button\">\n Action 3\n </button>,\n ],\n};\n\nexport const ActionListExample = Template.bind({});\nActionListExample.args = {\n ...defaultArgs,\n};\n"],"names":["codeString","ActionList_stories","ActionList","Template","args","jsx","defaultArgs","ActionListExample"],"mappings":";;AAKA,MAAMA,IAAa;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,GASnBC,IAAe;AAAA,EACb,OAAO;AAAA,EACP,WAAWC;AAAA,EACX,UAAU;AAAA,IACR,SAAS;AAAA,MACP,SAAS,CAAC,WAAW,aAAa,uBAAuB,yBAAyB,SAAS,YAAY;AAAA,MACvG,SAAS,EAAE,MAAM,QAAA;AAAA,IAAQ;AAAA,EAC3B;AAAA,EAEF,YAAY;AAAA,IACV,kBAAkBA;AAAA,IAClB,YAAAF;AAAA,EAAA;AAEJ,GAEMG,IAAqC,CAACC,MAC1C,gBAAAC,EAAC,OAAA,EAAI,OAAO,EAAE,YAAY,QAAQ,OAAO,UACvC,UAAA,gBAAAA,EAACH,GAAA,EAAY,GAAGE,GAAM,GACxB,GAGIE,IAAwC;AAAA,EAC5C,OAAO;AAAA,EACP,SAAS;AAAA,EACT,UAAU;AAAA,EACV,UAAU;AAAA,IACR,gBAAAD,EAAC,UAAA,EAAe,MAAK,UAAS,wBAAlB,GAEZ;AAAA,IACA,gBAAAA,EAAC,UAAA,EAAe,MAAK,UAAS,wBAAlB,GAEZ;AAAA,IACA,gBAAAA,EAAC,UAAA,EAAe,MAAK,UAAS,wBAAlB,GAEZ;AAAA,EAAA;AAEJ,GAEaE,IAAoBJ,EAAS,KAAK,CAAA,CAAE;AACjDI,EAAkB,OAAO;AAAA,EACvB,GAAGD;AACL;"}
@@ -1,7 +1,7 @@
1
1
  import { jsx as i } from "react/jsx-runtime";
2
- import "../../index-BqLi4tOb.js";
3
- import { r as n, s as t, w as a } from "../../react.esm-CsMDid07.js";
4
- import { u as l } from "../../index-CUap8sKR.js";
2
+ import "../../index-DV47hRzi.js";
3
+ import { r as n, s as t, w as a } from "../../react.esm-CFMwGdo5.js";
4
+ import { u as l } from "../../index-PaHiqSUg.js";
5
5
  import { ActionList as o } from "./ActionList.js";
6
6
  const T = jest.fn(), c = [
7
7
  /* @__PURE__ */ i("button", { type: "button", onClick: T, children: "Test Action 1" }, "1"),
@@ -1 +1 @@
1
- {"version":3,"file":"ActionList.test.js","sources":["../../../src/components/ActionList/ActionList.test.tsx"],"sourcesContent":["import '@testing-library/jest-dom';\nimport { render, screen, waitFor } from '@testing-library/react';\nimport userEvent from '@testing-library/user-event';\n\nimport { ActionList } from './ActionList';\n\nconst onClickSpy = jest.fn();\n\nconst BUTTON_LIST = [\n <button key=\"1\" type=\"button\" onClick={onClickSpy}>\n Test Action 1\n </button>,\n <button key=\"2\" type=\"button\">\n Test Action 2\n </button>,\n <button key=\"3\" type=\"button\">\n Test Action 3\n </button>,\n];\n\ndescribe('ActionList', () => {\n it('should render (variant primary)', () => {\n render(\n <ActionList label=\"Test ActionList\" variant=\"primary\" iconName=\"EllipsisVertical\">\n {BUTTON_LIST.map((button) => button)}\n </ActionList>\n );\n expect(screen.getByText('Test ActionList')).toBeInTheDocument();\n expect(screen.getByText('Test ActionList')).toHaveClass('button--primary');\n expect(screen.getByText('Test Action 1')).toBeInTheDocument();\n expect(screen.getByText('Test Action 2')).toBeInTheDocument();\n expect(screen.getByText('Test Action 3')).toBeInTheDocument();\n });\n\n it('should render variant secondary', () => {\n render(\n <ActionList label=\"Test ActionList\" variant=\"secondary\" iconName=\"EllipsisVertical\">\n {BUTTON_LIST.map((button) => button)}\n </ActionList>\n );\n expect(screen.getByText('Test ActionList')).toBeInTheDocument();\n expect(screen.getByText('Test ActionList')).toHaveClass('button--secondary');\n });\n\n it('should render variant destructive-primary', () => {\n render(\n <ActionList label=\"Test ActionList\" variant=\"destructive-primary\" iconName=\"EllipsisVertical\">\n {BUTTON_LIST.map((button) => button)}\n </ActionList>\n );\n expect(screen.getByText('Test ActionList')).toBeInTheDocument();\n expect(screen.getByText('Test ActionList')).toHaveClass('button--destructive-primary');\n });\n\n it('should render variant destructive-secondary', () => {\n render(\n <ActionList label=\"Test ActionList\" variant=\"destructive-secondary\" iconName=\"EllipsisVertical\">\n {BUTTON_LIST.map((button) => button)}\n </ActionList>\n );\n expect(screen.getByText('Test ActionList')).toBeInTheDocument();\n expect(screen.getByText('Test ActionList')).toHaveClass('button--destructive-secondary');\n });\n\n it('should render variant blank', () => {\n render(\n <ActionList label=\"Test ActionList\" variant=\"blank\" iconName=\"EllipsisVertical\">\n {BUTTON_LIST.map((button) => button)}\n </ActionList>\n );\n expect(screen.getByText('Test ActionList')).toBeInTheDocument();\n expect(screen.getByText('Test ActionList')).toHaveClass('button--blank');\n });\n\n it('should render variant blank-icon', () => {\n render(\n <ActionList label=\"Test ActionList\" variant=\"blank-icon\" iconName=\"EllipsisVertical\">\n {BUTTON_LIST.map((button) => button)}\n </ActionList>\n );\n expect(screen.getByText('Test ActionList')).toBeInTheDocument();\n expect(screen.getByText('Test ActionList')).toHaveClass('button--blank-icon');\n });\n\n it('should toggle content visibility on click', async () => {\n render(\n <ActionList label=\"Test ActionList\" variant=\"blank-icon\" iconName=\"EllipsisVertical\">\n {BUTTON_LIST.map((button) => button)}\n </ActionList>\n );\n const triggerElement = screen.getByText('Test ActionList');\n const actionListElement = screen.getByRole('menu');\n expect(triggerElement).toBeInTheDocument();\n expect(actionListElement).toBeInTheDocument();\n await userEvent.click(triggerElement);\n await waitFor(() => {\n expect(actionListElement).toHaveClass('action-list--open');\n });\n await userEvent.click(triggerElement);\n await waitFor(() => {\n expect(actionListElement).not.toHaveClass('action-list--open');\n });\n });\n\n it('should fire action on click on action button', async () => {\n render(\n <ActionList label=\"Test ActionList\" variant=\"blank-icon\" iconName=\"EllipsisVertical\">\n {BUTTON_LIST.map((button) => button)}\n </ActionList>\n );\n const triggerElement = screen.getByText('Test ActionList');\n const actionListElement = screen.getByRole('menu');\n expect(triggerElement).toBeInTheDocument();\n expect(actionListElement).toBeInTheDocument();\n await userEvent.click(triggerElement);\n await waitFor(() => {\n expect(actionListElement).toHaveClass('action-list--open');\n });\n const actionButton = screen.getByText('Test Action 1');\n await userEvent.click(actionButton);\n expect(onClickSpy).toHaveBeenCalledTimes(1);\n await waitFor(() => {\n expect(actionListElement).not.toHaveClass('action-list--open');\n });\n });\n});\n"],"names":["onClickSpy","BUTTON_LIST","jsx","render","ActionList","button","screen","triggerElement","actionListElement","userEvent","waitFor","actionButton"],"mappings":";;;;;AAMA,MAAMA,IAAa,KAAK,GAAG,GAErBC,IAAc;AAAA,oBACjB,UAAe,EAAA,MAAK,UAAS,SAASD,GAAY,6BAAvC,GAEZ;AAAA,EACC,gBAAAE,EAAA,UAAA,EAAe,MAAK,UAAS,6BAAlB,GAEZ;AAAA,EACC,gBAAAA,EAAA,UAAA,EAAe,MAAK,UAAS,6BAAlB,GAEZ;AACF;AAEA,SAAS,cAAc,MAAM;AAC3B,KAAG,mCAAmC,MAAM;AAC1C,IAAAC;AAAA,MACG,gBAAAD,EAAAE,GAAA,EAAW,OAAM,mBAAkB,SAAQ,WAAU,UAAS,oBAC5D,UAAYH,EAAA,IAAI,CAACI,MAAWA,CAAM,EACrC,CAAA;AAAA,IACF,GACA,OAAOC,EAAO,UAAU,iBAAiB,CAAC,EAAE,kBAAkB,GAC9D,OAAOA,EAAO,UAAU,iBAAiB,CAAC,EAAE,YAAY,iBAAiB,GACzE,OAAOA,EAAO,UAAU,eAAe,CAAC,EAAE,kBAAkB,GAC5D,OAAOA,EAAO,UAAU,eAAe,CAAC,EAAE,kBAAkB,GAC5D,OAAOA,EAAO,UAAU,eAAe,CAAC,EAAE,kBAAkB;AAAA,EAAA,CAC7D,GAED,GAAG,mCAAmC,MAAM;AAC1C,IAAAH;AAAA,MACG,gBAAAD,EAAAE,GAAA,EAAW,OAAM,mBAAkB,SAAQ,aAAY,UAAS,oBAC9D,UAAYH,EAAA,IAAI,CAACI,MAAWA,CAAM,EACrC,CAAA;AAAA,IACF,GACA,OAAOC,EAAO,UAAU,iBAAiB,CAAC,EAAE,kBAAkB,GAC9D,OAAOA,EAAO,UAAU,iBAAiB,CAAC,EAAE,YAAY,mBAAmB;AAAA,EAAA,CAC5E,GAED,GA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AAA,IAAA,CAC9D;AAAA,EAAA,CACF;AACH,CAAC;"}
1
+ {"version":3,"file":"ActionList.test.js","sources":["../../../src/components/ActionList/ActionList.test.tsx"],"sourcesContent":["import '@testing-library/jest-dom';\nimport { render, screen, waitFor } from '@testing-library/react';\nimport userEvent from '@testing-library/user-event';\n\nimport { ActionList } from './ActionList';\n\nconst onClickSpy = jest.fn();\n\nconst BUTTON_LIST = [\n <button key=\"1\" type=\"button\" onClick={onClickSpy}>\n Test Action 1\n </button>,\n <button key=\"2\" type=\"button\">\n Test Action 2\n </button>,\n <button key=\"3\" type=\"button\">\n Test Action 3\n </button>,\n];\n\ndescribe('ActionList', () => {\n it('should render (variant primary)', () => {\n render(\n <ActionList label=\"Test ActionList\" variant=\"primary\" iconName=\"EllipsisVertical\">\n {BUTTON_LIST.map((button) => button)}\n </ActionList>\n );\n expect(screen.getByText('Test ActionList')).toBeInTheDocument();\n expect(screen.getByText('Test ActionList')).toHaveClass('button--primary');\n expect(screen.getByText('Test Action 1')).toBeInTheDocument();\n expect(screen.getByText('Test Action 2')).toBeInTheDocument();\n expect(screen.getByText('Test Action 3')).toBeInTheDocument();\n });\n\n it('should render variant secondary', () => {\n render(\n <ActionList label=\"Test ActionList\" variant=\"secondary\" iconName=\"EllipsisVertical\">\n {BUTTON_LIST.map((button) => button)}\n </ActionList>\n );\n expect(screen.getByText('Test ActionList')).toBeInTheDocument();\n expect(screen.getByText('Test ActionList')).toHaveClass('button--secondary');\n });\n\n it('should render variant destructive-primary', () => {\n render(\n <ActionList label=\"Test ActionList\" variant=\"destructive-primary\" iconName=\"EllipsisVertical\">\n {BUTTON_LIST.map((button) => button)}\n </ActionList>\n );\n expect(screen.getByText('Test ActionList')).toBeInTheDocument();\n expect(screen.getByText('Test ActionList')).toHaveClass('button--destructive-primary');\n });\n\n it('should render variant destructive-secondary', () => {\n render(\n <ActionList label=\"Test ActionList\" variant=\"destructive-secondary\" iconName=\"EllipsisVertical\">\n {BUTTON_LIST.map((button) => button)}\n </ActionList>\n );\n expect(screen.getByText('Test ActionList')).toBeInTheDocument();\n expect(screen.getByText('Test ActionList')).toHaveClass('button--destructive-secondary');\n });\n\n it('should render variant blank', () => {\n render(\n <ActionList label=\"Test ActionList\" variant=\"blank\" iconName=\"EllipsisVertical\">\n {BUTTON_LIST.map((button) => button)}\n </ActionList>\n );\n expect(screen.getByText('Test ActionList')).toBeInTheDocument();\n expect(screen.getByText('Test ActionList')).toHaveClass('button--blank');\n });\n\n it('should render variant blank-icon', () => {\n render(\n <ActionList label=\"Test ActionList\" variant=\"blank-icon\" iconName=\"EllipsisVertical\">\n {BUTTON_LIST.map((button) => button)}\n </ActionList>\n );\n expect(screen.getByText('Test ActionList')).toBeInTheDocument();\n expect(screen.getByText('Test ActionList')).toHaveClass('button--blank-icon');\n });\n\n it('should toggle content visibility on click', async () => {\n render(\n <ActionList label=\"Test ActionList\" variant=\"blank-icon\" iconName=\"EllipsisVertical\">\n {BUTTON_LIST.map((button) => button)}\n </ActionList>\n );\n const triggerElement = screen.getByText('Test ActionList');\n const actionListElement = screen.getByRole('menu');\n expect(triggerElement).toBeInTheDocument();\n expect(actionListElement).toBeInTheDocument();\n await userEvent.click(triggerElement);\n await waitFor(() => {\n expect(actionListElement).toHaveClass('action-list--open');\n });\n await userEvent.click(triggerElement);\n await waitFor(() => {\n expect(actionListElement).not.toHaveClass('action-list--open');\n });\n });\n\n it('should fire action on click on action button', async () => {\n render(\n <ActionList label=\"Test ActionList\" variant=\"blank-icon\" iconName=\"EllipsisVertical\">\n {BUTTON_LIST.map((button) => button)}\n </ActionList>\n );\n const triggerElement = screen.getByText('Test ActionList');\n const actionListElement = screen.getByRole('menu');\n expect(triggerElement).toBeInTheDocument();\n expect(actionListElement).toBeInTheDocument();\n await userEvent.click(triggerElement);\n await waitFor(() => {\n expect(actionListElement).toHaveClass('action-list--open');\n });\n const actionButton = screen.getByText('Test Action 1');\n await userEvent.click(actionButton);\n expect(onClickSpy).toHaveBeenCalledTimes(1);\n await waitFor(() => {\n expect(actionListElement).not.toHaveClass('action-list--open');\n });\n });\n});\n"],"names":["onClickSpy","BUTTON_LIST","jsx","render","ActionList","button","screen","triggerElement","actionListElement","userEvent","waitFor","actionButton"],"mappings":";;;;;AAMA,MAAMA,IAAa,KAAK,GAAA,GAElBC,IAAc;AAAA,oBACjB,UAAA,EAAe,MAAK,UAAS,SAASD,GAAY,6BAAvC,GAEZ;AAAA,EACA,gBAAAE,EAAC,UAAA,EAAe,MAAK,UAAS,6BAAlB,GAEZ;AAAA,EACA,gBAAAA,EAAC,UAAA,EAAe,MAAK,UAAS,6BAAlB,GAEZ;AACF;AAEA,SAAS,cAAc,MAAM;AAC3B,KAAG,mCAAmC,MAAM;AAC1C,IAAAC;AAAA,MACE,gBAAAD,EAACE,GAAA,EAAW,OAAM,mBAAkB,SAAQ,WAAU,UAAS,oBAC5D,UAAAH,EAAY,IAAI,CAACI,MAAWA,CAAM,EAAA,CACrC;AAAA,IAAA,GAEF,OAAOC,EAAO,UAAU,iBAAiB,CAAC,EAAE,kBAAA,GAC5C,OAAOA,EAAO,UAAU,iBAAiB,CAAC,EAAE,YAAY,iBAAiB,GACzE,OAAOA,EAAO,UAAU,eAAe,CAAC,EAAE,kBAAA,GAC1C,OAAOA,EAAO,UAAU,eAAe,CAAC,EAAE,kBAAA,GAC1C,OAAOA,EAAO,UAAU,eAAe,CAAC,EAAE,kBAAA;AAAA,EAAkB,CAC7D,GAED,GAAG,mCAAmC,MAAM;AAC1C,IAAAH;AAAA,MACE,gBAAAD,EAACE,GAAA,EAAW,OAAM,mBAAkB,SAAQ,aAAY,UAAS,oBAC9D,UAAAH,EAAY,IAAI,CAACI,MAAWA,CAAM,EAAA,CACrC;AAAA,IAAA,GAEF,OAAOC,EAAO,UAAU,iBAAiB,CAAC,EAAE,kBAAA,GAC5C,OAAOA,EAAO,UAAU,iBAAiB,CAAC,EAAE,YAAY,mBAAmB;AAAA,EAAA,CAC5E,GAED,GAAG,6CAA6C,MAAM;A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EAAA,CACF;AACH,CAAC;"}
@@ -1 +1 @@
1
- {"version":3,"file":"AppStatusBar.js","sources":["../../../src/components/AppStatusBar/AppStatusBar.tsx"],"sourcesContent":["import classNames from 'clsx';\n\nimport styles from './AppStatusBar.module.css';\n\nexport interface AppStatusBarProps {\n /** The message to be displayed in the status bar. */\n message: string;\n /** Determines the color of the bar. */\n severity: 'info' | 'warning' | 'error';\n}\n\n/** A component to display a general status. */\nexport const AppStatusBar = ({ message, severity }: AppStatusBarProps) => (\n <div className={classNames(styles['app-status-bar'], styles[`app-status-bar--${severity.toLowerCase()}`])}>\n <p className={styles['app-status-bar__message']} dangerouslySetInnerHTML={{ __html: message }} />\n </div>\n);\n"],"names":["AppStatusBar","message","severity","jsx","classNames","styles"],"mappings":";;;;;;;;GAYaA,IAAe,CAAC,EAAE,SAAAC,GAAS,UAAAC,QACtC,gBAAAC,EAAC,OAAI,EAAA,WAAWC,EAAWC,EAAO,gBAAgB,GAAGA,EAAO,mBAAmBH,EAAS,YAAY,CAAC,EAAE,CAAC,GACtG,UAAA,gBAAAC,EAAC,OAAE,WAAWE,EAAO,yBAAyB,GAAG,yBAAyB,EAAE,QAAQJ,EAAA,EAAW,CAAA,EACjG,CAAA;"}
1
+ {"version":3,"file":"AppStatusBar.js","sources":["../../../src/components/AppStatusBar/AppStatusBar.tsx"],"sourcesContent":["import classNames from 'clsx';\n\nimport styles from './AppStatusBar.module.css';\n\nexport interface AppStatusBarProps {\n /** The message to be displayed in the status bar. */\n message: string;\n /** Determines the color of the bar. */\n severity: 'info' | 'warning' | 'error';\n}\n\n/** A component to display a general status. */\nexport const AppStatusBar = ({ message, severity }: AppStatusBarProps) => (\n <div className={classNames(styles['app-status-bar'], styles[`app-status-bar--${severity.toLowerCase()}`])}>\n <p className={styles['app-status-bar__message']} dangerouslySetInnerHTML={{ __html: message }} />\n </div>\n);\n"],"names":["AppStatusBar","message","severity","jsx","classNames","styles"],"mappings":";;;;;;;;GAYaA,IAAe,CAAC,EAAE,SAAAC,GAAS,UAAAC,QACtC,gBAAAC,EAAC,OAAA,EAAI,WAAWC,EAAWC,EAAO,gBAAgB,GAAGA,EAAO,mBAAmBH,EAAS,YAAA,CAAa,EAAE,CAAC,GACtG,UAAA,gBAAAC,EAAC,OAAE,WAAWE,EAAO,yBAAyB,GAAG,yBAAyB,EAAE,QAAQJ,EAAA,GAAW,EAAA,CACjG;"}
@@ -2,4 +2,4 @@ import { Meta } from '@storybook/react';
2
2
  import { AppStatusBarProps } from './AppStatusBar';
3
3
  declare const _default: Meta<AppStatusBarProps>;
4
4
  export default _default;
5
- export declare const AppStatusBarExample: import('@storybook/core/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, AppStatusBarProps>;
5
+ export declare const AppStatusBarExample: import('storybook/internal/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, AppStatusBarProps>;
@@ -1 +1 @@
1
- {"version":3,"file":"AppStatusBar.stories.js","sources":["../../../src/components/AppStatusBar/AppStatusBar.stories.tsx"],"sourcesContent":["import type { Meta, StoryFn } from '@storybook/react';\nimport type { AppStatusBarProps } from './AppStatusBar';\n\nimport { AppStatusBar } from './AppStatusBar';\n\nconst codeString = '<AppStatusBar severity={severity} message={message} key={key} />';\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n title: 'Atoms/AppStatusBar',\n component: AppStatusBar,\n argTypes: {\n severity: {\n options: ['info', 'warning', 'error'],\n control: { type: 'radio' },\n },\n },\n parameters: {\n inspectComponent: AppStatusBar,\n codeString: codeString,\n },\n} as Meta<AppStatusBarProps>;\n\nconst Template: StoryFn<AppStatusBarProps> = (args) => <AppStatusBar {...args} />;\n\nconst defaultArgs: Partial<AppStatusBarProps> = {\n message: 'Dit is de ontwikkelomgeving van Storybook. Hier kun je componenten bekijken en testen!.',\n severity: 'warning',\n};\n\nexport const AppStatusBarExample = Template.bind({});\nAppStatusBarExample.args = {\n ...defaultArgs,\n};\n"],"names":["codeString","AppStatusBar_stories","AppStatusBar","Template","args","jsx","defaultArgs","AppStatusBarExample"],"mappings":";;AAKA,MAAMA,IAAa,oEAGJC,IAAA;AAAA,EACb,OAAO;AAAA,EACP,WAAWC;AAAA,EACX,UAAU;AAAA,IACR,UAAU;AAAA,MACR,SAAS,CAAC,QAAQ,WAAW,OAAO;AAAA,MACpC,SAAS,EAAE,MAAM,QAAQ;AAAA,IAAA;AAAA,EAE7B;AAAA,EACA,YAAY;AAAA,IACV,kBAAkBA;AAAA,IAClB,YAAAF;AAAA,EAAA;AAEJ,GAEMG,IAAuC,CAACC,MAAU,gBAAAC,EAAAH,GAAA,EAAc,GAAGE,GAAM,GAEzEE,IAA0C;AAAA,EAC9C,SAAS;AAAA,EACT,UAAU;AACZ,GAEaC,IAAsBJ,EAAS,KAAK,CAAE,CAAA;AACnDI,EAAoB,OAAO;AAAA,EACzB,GAAGD;AACL;"}
1
+ {"version":3,"file":"AppStatusBar.stories.js","sources":["../../../src/components/AppStatusBar/AppStatusBar.stories.tsx"],"sourcesContent":["import type { Meta, StoryFn } from '@storybook/react';\nimport type { AppStatusBarProps } from './AppStatusBar';\n\nimport { AppStatusBar } from './AppStatusBar';\n\nconst codeString = '<AppStatusBar severity={severity} message={message} key={key} />';\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n title: 'Atoms/AppStatusBar',\n component: AppStatusBar,\n argTypes: {\n severity: {\n options: ['info', 'warning', 'error'],\n control: { type: 'radio' },\n },\n },\n parameters: {\n inspectComponent: AppStatusBar,\n codeString: codeString,\n },\n} as Meta<AppStatusBarProps>;\n\nconst Template: StoryFn<AppStatusBarProps> = (args) => <AppStatusBar {...args} />;\n\nconst defaultArgs: Partial<AppStatusBarProps> = {\n message: 'Dit is de ontwikkelomgeving van Storybook. Hier kun je componenten bekijken en testen!.',\n severity: 'warning',\n};\n\nexport const AppStatusBarExample = Template.bind({});\nAppStatusBarExample.args = {\n ...defaultArgs,\n};\n"],"names":["codeString","AppStatusBar_stories","AppStatusBar","Template","args","jsx","defaultArgs","AppStatusBarExample"],"mappings":";;AAKA,MAAMA,IAAa,oEAGnBC,IAAe;AAAA,EACb,OAAO;AAAA,EACP,WAAWC;AAAA,EACX,UAAU;AAAA,IACR,UAAU;AAAA,MACR,SAAS,CAAC,QAAQ,WAAW,OAAO;AAAA,MACpC,SAAS,EAAE,MAAM,QAAA;AAAA,IAAQ;AAAA,EAC3B;AAAA,EAEF,YAAY;AAAA,IACV,kBAAkBA;AAAA,IAClB,YAAAF;AAAA,EAAA;AAEJ,GAEMG,IAAuC,CAACC,MAAS,gBAAAC,EAACH,GAAA,EAAc,GAAGE,GAAM,GAEzEE,IAA0C;AAAA,EAC9C,SAAS;AAAA,EACT,UAAU;AACZ,GAEaC,IAAsBJ,EAAS,KAAK,CAAA,CAAE;AACnDI,EAAoB,OAAO;AAAA,EACzB,GAAGD;AACL;"}
@@ -1,6 +1,6 @@
1
1
  import { jsx as e } from "react/jsx-runtime";
2
- import "../../index-BqLi4tOb.js";
3
- import { r, s as t } from "../../react.esm-CsMDid07.js";
2
+ import "../../index-DV47hRzi.js";
3
+ import { r, s as t } from "../../react.esm-CFMwGdo5.js";
4
4
  import { AppStatusBar as s } from "./AppStatusBar.js";
5
5
  describe("AppStatusBar", () => {
6
6
  it("should render", () => {
@@ -1 +1 @@
1
- {"version":3,"file":"AppStatusBar.test.js","sources":["../../../src/components/AppStatusBar/AppStatusBar.test.tsx"],"sourcesContent":["import '@testing-library/jest-dom';\nimport { render, screen } from '@testing-library/react';\n\nimport { AppStatusBar } from './AppStatusBar';\n\ndescribe('AppStatusBar', () => {\n it('should render', () => {\n render(<AppStatusBar message=\"AppStatusBar message\" severity=\"info\" />);\n expect(screen.getByText('AppStatusBar message')).toBeInTheDocument();\n });\n});\n"],"names":["render","AppStatusBar","screen"],"mappings":";;;;AAKA,SAAS,gBAAgB,MAAM;AAC7B,KAAG,iBAAiB,MAAM;AACxB,IAAAA,oBAAQC,GAAa,EAAA,SAAQ,wBAAuB,UAAS,QAAO,CAAE,GACtE,OAAOC,EAAO,UAAU,sBAAsB,CAAC,EAAE,kBAAkB;AAAA,EAAA,CACpE;AACH,CAAC;"}
1
+ {"version":3,"file":"AppStatusBar.test.js","sources":["../../../src/components/AppStatusBar/AppStatusBar.test.tsx"],"sourcesContent":["import '@testing-library/jest-dom';\nimport { render, screen } from '@testing-library/react';\n\nimport { AppStatusBar } from './AppStatusBar';\n\ndescribe('AppStatusBar', () => {\n it('should render', () => {\n render(<AppStatusBar message=\"AppStatusBar message\" severity=\"info\" />);\n expect(screen.getByText('AppStatusBar message')).toBeInTheDocument();\n });\n});\n"],"names":["render","AppStatusBar","screen"],"mappings":";;;;AAKA,SAAS,gBAAgB,MAAM;AAC7B,KAAG,iBAAiB,MAAM;AACxB,IAAAA,oBAAQC,GAAA,EAAa,SAAQ,wBAAuB,UAAS,QAAO,CAAE,GACtE,OAAOC,EAAO,UAAU,sBAAsB,CAAC,EAAE,kBAAA;AAAA,EAAkB,CACpE;AACH,CAAC;"}
@@ -1 +1 @@
1
- {"version":3,"file":"Attention.js","sources":["../../../src/components/Attention/Attention.tsx"],"sourcesContent":["import type { PropsWithChildren } from 'react';\n\nimport styles from './Attention.module.css';\n\nimport { Icon } from 'components/Icon';\n\n/** Shows the ExclamationCircleFillMini icon with children */\nexport const Attention = ({ children }: PropsWithChildren) => (\n <div className={styles['attention']}>\n <Icon name=\"ExclamationCircleFillMini\" size={24} />\n {children}\n </div>\n);\n"],"names":["Attention","children","styles","jsx","Icon"],"mappings":";;;;GAOaA,IAAY,CAAC,EAAE,UAAAC,EAAS,wBAClC,OAAI,EAAA,WAAWC,EAAO,WACrB,UAAA;AAAA,EAAA,gBAAAC,EAACC,GAAK,EAAA,MAAK,6BAA4B,MAAM,IAAI;AAAA,EAChDH;AAAA,EACH,CAAA;"}
1
+ {"version":3,"file":"Attention.js","sources":["../../../src/components/Attention/Attention.tsx"],"sourcesContent":["import type { PropsWithChildren } from 'react';\n\nimport styles from './Attention.module.css';\n\nimport { Icon } from 'components/Icon';\n\n/** Shows the ExclamationCircleFillMini icon with children */\nexport const Attention = ({ children }: PropsWithChildren) => (\n <div className={styles['attention']}>\n <Icon name=\"ExclamationCircleFillMini\" size={24} />\n {children}\n </div>\n);\n"],"names":["Attention","children","styles","jsx","Icon"],"mappings":";;;;GAOaA,IAAY,CAAC,EAAE,UAAAC,EAAA,wBACzB,OAAA,EAAI,WAAWC,EAAO,WACrB,UAAA;AAAA,EAAA,gBAAAC,EAACC,GAAA,EAAK,MAAK,6BAA4B,MAAM,IAAI;AAAA,EAChDH;AAAA,EAAA,CACH;"}
@@ -2,6 +2,6 @@ import { Meta } from '@storybook/react';
2
2
  import { PropsWithChildren } from 'react';
3
3
  declare const _default: Meta<PropsWithChildren>;
4
4
  export default _default;
5
- export declare const AttentionExample: import('@storybook/core/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, {
5
+ export declare const AttentionExample: import('storybook/internal/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, {
6
6
  children?: import('react').ReactNode | undefined;
7
7
  }>;
@@ -1 +1 @@
1
- {"version":3,"file":"Attention.stories.js","sources":["../../../src/components/Attention/Attention.stories.tsx"],"sourcesContent":["import type { Meta, StoryFn } from '@storybook/react';\nimport type { PropsWithChildren } from 'react';\n\nimport { Attention } from './Attention';\n\nconst codeString = '<Attention>{message}</Attention>';\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n title: 'Atoms/Attention',\n component: Attention,\n parameters: {\n inspectComponent: Attention,\n codeString: codeString,\n },\n} as Meta<PropsWithChildren>;\n\nconst Template: StoryFn<PropsWithChildren> = (args) => <Attention {...args}>Example Attention</Attention>;\n\nexport const AttentionExample = Template.bind({});\nAttentionExample.args = {};\n"],"names":["codeString","Attention_stories","Attention","Template","args","AttentionExample"],"mappings":";;AAKA,MAAMA,IAAa,oCAGJC,IAAA;AAAA,EACb,OAAO;AAAA,EACP,WAAWC;AAAA,EACX,YAAY;AAAA,IACV,kBAAkBA;AAAA,IAClB,YAAAF;AAAA,EAAA;AAEJ,GAEMG,IAAuC,CAACC,wBAAUF,GAAW,EAAA,GAAGE,GAAM,UAAiB,qBAAA,GAEhFC,IAAmBF,EAAS,KAAK,CAAE,CAAA;AAChDE,EAAiB,OAAO,CAAC;"}
1
+ {"version":3,"file":"Attention.stories.js","sources":["../../../src/components/Attention/Attention.stories.tsx"],"sourcesContent":["import type { Meta, StoryFn } from '@storybook/react';\nimport type { PropsWithChildren } from 'react';\n\nimport { Attention } from './Attention';\n\nconst codeString = '<Attention>{message}</Attention>';\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n title: 'Atoms/Attention',\n component: Attention,\n parameters: {\n inspectComponent: Attention,\n codeString: codeString,\n },\n} as Meta<PropsWithChildren>;\n\nconst Template: StoryFn<PropsWithChildren> = (args) => <Attention {...args}>Example Attention</Attention>;\n\nexport const AttentionExample = Template.bind({});\nAttentionExample.args = {};\n"],"names":["codeString","Attention_stories","Attention","Template","args","AttentionExample"],"mappings":";;AAKA,MAAMA,IAAa,oCAGnBC,IAAe;AAAA,EACb,OAAO;AAAA,EACP,WAAWC;AAAA,EACX,YAAY;AAAA,IACV,kBAAkBA;AAAA,IAClB,YAAAF;AAAA,EAAA;AAEJ,GAEMG,IAAuC,CAACC,wBAAUF,GAAA,EAAW,GAAGE,GAAM,UAAA,qBAAiB,GAEhFC,IAAmBF,EAAS,KAAK,CAAA,CAAE;AAChDE,EAAiB,OAAO,CAAA;"}
@@ -1,6 +1,6 @@
1
1
  import { jsx as e } from "react/jsx-runtime";
2
- import "../../index-BqLi4tOb.js";
3
- import { r as t, s as r } from "../../react.esm-CsMDid07.js";
2
+ import "../../index-DV47hRzi.js";
3
+ import { r as t, s as r } from "../../react.esm-CFMwGdo5.js";
4
4
  import { Attention as n } from "./Attention.js";
5
5
  describe("Attention", () => {
6
6
  it("should render (variant primary)", () => {
@@ -1 +1 @@
1
- {"version":3,"file":"Attention.test.js","sources":["../../../src/components/Attention/Attention.test.tsx"],"sourcesContent":["import '@testing-library/jest-dom';\nimport { render, screen } from '@testing-library/react';\n\nimport { Attention } from './Attention';\n\ndescribe('Attention', () => {\n it('should render (variant primary)', () => {\n render(<Attention>Attention message</Attention>);\n expect(screen.getByText('Attention message')).toBeInTheDocument();\n });\n});\n"],"names":["render","jsx","Attention","screen"],"mappings":";;;;AAKA,SAAS,aAAa,MAAM;AAC1B,KAAG,mCAAmC,MAAM;AACnC,IAAAA,EAAA,gBAAAC,EAACC,GAAU,EAAA,UAAA,oBAAiB,CAAA,CAAY,GAC/C,OAAOC,EAAO,UAAU,mBAAmB,CAAC,EAAE,kBAAkB;AAAA,EAAA,CACjE;AACH,CAAC;"}
1
+ {"version":3,"file":"Attention.test.js","sources":["../../../src/components/Attention/Attention.test.tsx"],"sourcesContent":["import '@testing-library/jest-dom';\nimport { render, screen } from '@testing-library/react';\n\nimport { Attention } from './Attention';\n\ndescribe('Attention', () => {\n it('should render (variant primary)', () => {\n render(<Attention>Attention message</Attention>);\n expect(screen.getByText('Attention message')).toBeInTheDocument();\n });\n});\n"],"names":["render","jsx","Attention","screen"],"mappings":";;;;AAKA,SAAS,aAAa,MAAM;AAC1B,KAAG,mCAAmC,MAAM;AAC1C,IAAAA,EAAO,gBAAAC,EAACC,GAAA,EAAU,UAAA,oBAAA,CAAiB,CAAY,GAC/C,OAAOC,EAAO,UAAU,mBAAmB,CAAC,EAAE,kBAAA;AAAA,EAAkB,CACjE;AACH,CAAC;"}
@@ -1 +1 @@
1
- {"version":3,"file":"Backdrop.js","sources":["../../../src/components/Backdrop/Backdrop.tsx"],"sourcesContent":["import type { HTMLAttributes } from 'react';\n\nimport styles from './Backdrop.module.css';\n\nexport type BackdropProps = Omit<HTMLAttributes<HTMLDivElement>, 'className' | 'style'>;\n\n/** Represents a component to dim the screen, used in combination with a modal dialog. Accepts normal HTML attributes, except className and style. */\nexport const Backdrop = ({ children, ...restProps }: BackdropProps) => (\n <div {...restProps} className={styles['backdrop']}>\n {children}\n </div>\n);\n"],"names":["Backdrop","children","restProps","jsx","styles"],"mappings":";;;GAOaA,IAAW,CAAC,EAAE,UAAAC,GAAU,GAAGC,EAAU,MAC/C,gBAAAC,EAAA,OAAA,EAAK,GAAGD,GAAW,WAAWE,EAAO,UACnC,UAAAH,EACH,CAAA;"}
1
+ {"version":3,"file":"Backdrop.js","sources":["../../../src/components/Backdrop/Backdrop.tsx"],"sourcesContent":["import type { HTMLAttributes } from 'react';\n\nimport styles from './Backdrop.module.css';\n\nexport type BackdropProps = Omit<HTMLAttributes<HTMLDivElement>, 'className' | 'style'>;\n\n/** Represents a component to dim the screen, used in combination with a modal dialog. Accepts normal HTML attributes, except className and style. */\nexport const Backdrop = ({ children, ...restProps }: BackdropProps) => (\n <div {...restProps} className={styles['backdrop']}>\n {children}\n </div>\n);\n"],"names":["Backdrop","children","restProps","jsx","styles"],"mappings":";;;GAOaA,IAAW,CAAC,EAAE,UAAAC,GAAU,GAAGC,EAAA,MACtC,gBAAAC,EAAC,OAAA,EAAK,GAAGD,GAAW,WAAWE,EAAO,UACnC,UAAAH,EAAA,CACH;"}
@@ -5,4 +5,4 @@ type BackdropStoryProps = BackdropProps & {
5
5
  };
6
6
  declare const _default: Meta<BackdropStoryProps>;
7
7
  export default _default;
8
- export declare const BackdropExample: import('@storybook/core/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, BackdropStoryProps>;
8
+ export declare const BackdropExample: import('storybook/internal/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, BackdropStoryProps>;
@@ -1 +1 @@
1
- {"version":3,"file":"Backdrop.stories.js","sources":["../../../src/components/Backdrop/Backdrop.stories.tsx"],"sourcesContent":["import type { Meta, StoryFn } from '@storybook/react';\nimport type { BackdropProps } from './Backdrop';\n\nimport { Backdrop } from './Backdrop';\n\nimport { Container } from 'storyComponents/Container';\n\nimport './Backdrop.stories.css';\n\ntype BackdropStoryProps = BackdropProps & { visible: boolean };\n\nconst codeString = '<Backdrop>{children}</Backdrop>';\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n title: 'Atoms/Backdrop',\n component: Backdrop,\n argTypes: {\n children: {\n control: 'text',\n },\n visible: {\n control: 'boolean',\n name: 'Show Backdrop',\n },\n },\n parameters: {\n inspectComponent: Backdrop,\n codeString: codeString,\n },\n} as Meta<BackdropStoryProps>;\n\nconst Template: StoryFn<BackdropStoryProps> = (args) => {\n return (\n <Container visible={args.visible}>\n <Backdrop>\n <div className=\"container\">{args.children}</div>\n </Backdrop>\n </Container>\n );\n};\n\nexport const BackdropExample = Template.bind({});\nBackdropExample.args = {\n visible: true,\n children: 'Dummy Overlay',\n};\n"],"names":["codeString","Backdrop_stories","Backdrop","Template","args","jsx","Container","BackdropExample"],"mappings":";;;AAWA,MAAMA,IAAa,mCAGJC,IAAA;AAAA,EACb,OAAO;AAAA,EACP,WAAWC;AAAA,EACX,UAAU;AAAA,IACR,UAAU;AAAA,MACR,SAAS;AAAA,IACX;AAAA,IACA,SAAS;AAAA,MACP,SAAS;AAAA,MACT,MAAM;AAAA,IAAA;AAAA,EAEV;AAAA,EACA,YAAY;AAAA,IACV,kBAAkBA;AAAA,IAClB,YAAAF;AAAA,EAAA;AAEJ,GAEMG,IAAwC,CAACC,MAE1C,gBAAAC,EAAAC,GAAA,EAAU,SAASF,EAAK,SACvB,UAAC,gBAAAC,EAAAH,GAAA,EACC,UAAC,gBAAAG,EAAA,OAAA,EAAI,WAAU,aAAa,UAAKD,EAAA,SAAA,CAAS,EAC5C,CAAA,GACF,GAISG,IAAkBJ,EAAS,KAAK,CAAE,CAAA;AAC/CI,EAAgB,OAAO;AAAA,EACrB,SAAS;AAAA,EACT,UAAU;AACZ;"}
1
+ {"version":3,"file":"Backdrop.stories.js","sources":["../../../src/components/Backdrop/Backdrop.stories.tsx"],"sourcesContent":["import type { Meta, StoryFn } from '@storybook/react';\nimport type { BackdropProps } from './Backdrop';\n\nimport { Backdrop } from './Backdrop';\n\nimport { Container } from 'storyComponents/Container';\n\nimport './Backdrop.stories.css';\n\ntype BackdropStoryProps = BackdropProps & { visible: boolean };\n\nconst codeString = '<Backdrop>{children}</Backdrop>';\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n title: 'Atoms/Backdrop',\n component: Backdrop,\n argTypes: {\n children: {\n control: 'text',\n },\n visible: {\n control: 'boolean',\n name: 'Show Backdrop',\n },\n },\n parameters: {\n inspectComponent: Backdrop,\n codeString: codeString,\n },\n} as Meta<BackdropStoryProps>;\n\nconst Template: StoryFn<BackdropStoryProps> = (args) => {\n return (\n <Container visible={args.visible}>\n <Backdrop>\n <div className=\"container\">{args.children}</div>\n </Backdrop>\n </Container>\n );\n};\n\nexport const BackdropExample = Template.bind({});\nBackdropExample.args = {\n visible: true,\n children: 'Dummy Overlay',\n};\n"],"names":["codeString","Backdrop_stories","Backdrop","Template","args","jsx","Container","BackdropExample"],"mappings":";;;AAWA,MAAMA,IAAa,mCAGnBC,IAAe;AAAA,EACb,OAAO;AAAA,EACP,WAAWC;AAAA,EACX,UAAU;AAAA,IACR,UAAU;AAAA,MACR,SAAS;AAAA,IAAA;AAAA,IAEX,SAAS;AAAA,MACP,SAAS;AAAA,MACT,MAAM;AAAA,IAAA;AAAA,EACR;AAAA,EAEF,YAAY;AAAA,IACV,kBAAkBA;AAAA,IAClB,YAAAF;AAAA,EAAA;AAEJ,GAEMG,IAAwC,CAACC,MAE3C,gBAAAC,EAACC,GAAA,EAAU,SAASF,EAAK,SACvB,UAAA,gBAAAC,EAACH,GAAA,EACC,UAAA,gBAAAG,EAAC,OAAA,EAAI,WAAU,aAAa,UAAAD,EAAK,SAAA,CAAS,GAC5C,GACF,GAISG,IAAkBJ,EAAS,KAAK,CAAA,CAAE;AAC/CI,EAAgB,OAAO;AAAA,EACrB,SAAS;AAAA,EACT,UAAU;AACZ;"}
@@ -1,6 +1,6 @@
1
1
  import { jsx as r } from "react/jsx-runtime";
2
- import "../../index-BqLi4tOb.js";
3
- import { r as e, s as o } from "../../react.esm-CsMDid07.js";
2
+ import "../../index-DV47hRzi.js";
3
+ import { r as e, s as o } from "../../react.esm-CFMwGdo5.js";
4
4
  import { Backdrop as t } from "./Backdrop.js";
5
5
  describe("Backdrop", () => {
6
6
  it("should render", () => {
@@ -1 +1 @@
1
- {"version":3,"file":"Backdrop.test.js","sources":["../../../src/components/Backdrop/Backdrop.test.tsx"],"sourcesContent":["import '@testing-library/jest-dom';\nimport { render, screen } from '@testing-library/react';\n\nimport { Backdrop } from './Backdrop';\n\ndescribe('Backdrop', () => {\n it('should render', () => {\n render(<Backdrop>Backdrop overlay</Backdrop>);\n expect(screen.getByText('Backdrop overlay')).toBeInTheDocument();\n });\n});\n"],"names":["render","jsx","Backdrop","screen"],"mappings":";;;;AAKA,SAAS,YAAY,MAAM;AACzB,KAAG,iBAAiB,MAAM;AACjB,IAAAA,EAAA,gBAAAC,EAACC,GAAS,EAAA,UAAA,mBAAgB,CAAA,CAAW,GAC5C,OAAOC,EAAO,UAAU,kBAAkB,CAAC,EAAE,kBAAkB;AAAA,EAAA,CAChE;AACH,CAAC;"}
1
+ {"version":3,"file":"Backdrop.test.js","sources":["../../../src/components/Backdrop/Backdrop.test.tsx"],"sourcesContent":["import '@testing-library/jest-dom';\nimport { render, screen } from '@testing-library/react';\n\nimport { Backdrop } from './Backdrop';\n\ndescribe('Backdrop', () => {\n it('should render', () => {\n render(<Backdrop>Backdrop overlay</Backdrop>);\n expect(screen.getByText('Backdrop overlay')).toBeInTheDocument();\n });\n});\n"],"names":["render","jsx","Backdrop","screen"],"mappings":";;;;AAKA,SAAS,YAAY,MAAM;AACzB,KAAG,iBAAiB,MAAM;AACxB,IAAAA,EAAO,gBAAAC,EAACC,GAAA,EAAS,UAAA,mBAAA,CAAgB,CAAW,GAC5C,OAAOC,EAAO,UAAU,kBAAkB,CAAC,EAAE,kBAAA;AAAA,EAAkB,CAChE;AACH,CAAC;"}
@@ -1 +1 @@
1
- {"version":3,"file":"ButtonGroup.js","sources":["../../../src/components/ButtonGroup/ButtonGroup.tsx"],"sourcesContent":["import classNames from 'clsx';\nimport { Children } from 'react';\n\nimport type { PropsWithChildren } from 'react';\n\nimport styles from './ButtonGroup.module.css';\n\nexport interface ButtonGroupProps {\n /** true to render the buttons from top to bottom; otherwise, false. The default is false. */\n stacked?: boolean;\n /** true to render the buttons in reverse order; otherwise, false. The default is false. */\n reversed?: boolean;\n}\n\n/** Represents a component that contains a group of buttons. */\nexport const ButtonGroup = ({ children, stacked, reversed }: PropsWithChildren<ButtonGroupProps>) =>\n // only render a <ButtonGroup> when there are children\n Children.count(children) > 0 ? (\n <div\n className={classNames(styles['button-group'], {\n [styles['button-group--stacked']]: stacked,\n [styles['button-group--reversed']]: reversed,\n [styles['button-group--reversed-stacked']]: stacked && reversed,\n })}\n >\n {children}\n </div>\n ) : null;\n"],"names":["ButtonGroup","children","stacked","reversed","Children","jsx","classNames","styles"],"mappings":";;;;;;;;GAeaA,IAAc,CAAC,EAAE,UAAAC,GAAU,SAAAC,GAAS,UAAAC,EAAS;AAAA;AAAA,EAExDC,EAAS,MAAMH,CAAQ,IAAI,IACzB,gBAAAI;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAWC,EAAWC,EAAO,cAAc,GAAG;AAAA,QAC5C,CAACA,EAAO,uBAAuB,CAAC,GAAGL;AAAA,QACnC,CAACK,EAAO,wBAAwB,CAAC,GAAGJ;AAAA,QACpC,CAACI,EAAO,gCAAgC,CAAC,GAAGL,KAAWC;AAAA,MAAA,CACxD;AAAA,MAEA,UAAAF;AAAA,IAAA;AAAA,EAAA,IAED;AAAA;"}
1
+ {"version":3,"file":"ButtonGroup.js","sources":["../../../src/components/ButtonGroup/ButtonGroup.tsx"],"sourcesContent":["import classNames from 'clsx';\nimport { Children } from 'react';\n\nimport type { PropsWithChildren } from 'react';\n\nimport styles from './ButtonGroup.module.css';\n\nexport interface ButtonGroupProps {\n /** true to render the buttons from top to bottom; otherwise, false. The default is false. */\n stacked?: boolean;\n /** true to render the buttons in reverse order; otherwise, false. The default is false. */\n reversed?: boolean;\n}\n\n/** Represents a component that contains a group of buttons. */\nexport const ButtonGroup = ({ children, stacked, reversed }: PropsWithChildren<ButtonGroupProps>) =>\n // only render a <ButtonGroup> when there are children\n Children.count(children) > 0 ? (\n <div\n className={classNames(styles['button-group'], {\n [styles['button-group--stacked']]: stacked,\n [styles['button-group--reversed']]: reversed,\n [styles['button-group--reversed-stacked']]: stacked && reversed,\n })}\n >\n {children}\n </div>\n ) : null;\n"],"names":["ButtonGroup","children","stacked","reversed","Children","jsx","classNames","styles"],"mappings":";;;;;;;;GAeaA,IAAc,CAAC,EAAE,UAAAC,GAAU,SAAAC,GAAS,UAAAC,EAAA;AAAA;AAAA,EAE/CC,EAAS,MAAMH,CAAQ,IAAI,IACzB,gBAAAI;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAWC,EAAWC,EAAO,cAAc,GAAG;AAAA,QAC5C,CAACA,EAAO,uBAAuB,CAAC,GAAGL;AAAA,QACnC,CAACK,EAAO,wBAAwB,CAAC,GAAGJ;AAAA,QACpC,CAACI,EAAO,gCAAgC,CAAC,GAAGL,KAAWC;AAAA,MAAA,CACxD;AAAA,MAEA,UAAAF;AAAA,IAAA;AAAA,EAAA,IAED;AAAA;"}
@@ -3,4 +3,4 @@ import { PropsWithChildren } from 'react';
3
3
  import { ButtonGroupProps } from './ButtonGroup';
4
4
  declare const _default: Meta<PropsWithChildren<ButtonGroupProps>>;
5
5
  export default _default;
6
- export declare const ButtonGroupExample: import('@storybook/core/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, PropsWithChildren<ButtonGroupProps>>;
6
+ export declare const ButtonGroupExample: import('storybook/internal/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, PropsWithChildren<ButtonGroupProps>>;
@@ -1 +1 @@
1
- {"version":3,"file":"ButtonGroup.stories.js","sources":["../../../src/components/ButtonGroup/ButtonGroup.stories.tsx"],"sourcesContent":["import type { Meta, StoryFn } from '@storybook/react';\nimport type { PropsWithChildren } from 'react';\nimport type { ButtonGroupProps } from './ButtonGroup';\n\nimport { ButtonGroup } from './ButtonGroup';\n\nimport { Button } from 'components/Buttons/Button';\nimport { Container } from 'storyComponents/Container';\n\nconst codeString = `\n <ButtonGroup reversed={reversed} stacked={stacked}>\n <Button variant={variant} onClick={onClickedFunction}>{children}</Button>\n <Button variant={variant} onClick={onClickedFunction}>{children}</Button>\n </ButtonGroup>\n`;\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n title: 'Molecules/ButtonGroup',\n component: ButtonGroup,\n argTypes: {\n children: {\n table: {\n disable: true,\n },\n },\n },\n parameters: {\n inspectComponent: ButtonGroup,\n codeString: codeString,\n },\n} as Meta<PropsWithChildren<ButtonGroupProps>>;\n\nconst Template: StoryFn<PropsWithChildren<ButtonGroupProps>> = (args) => (\n <Container>\n <ButtonGroup {...args} />\n </Container>\n);\n\nconst defaultArgs: Partial<PropsWithChildren<ButtonGroupProps>> = {\n stacked: false,\n reversed: false,\n children: (\n <>\n <Button variant=\"primary\">Primary button</Button>\n <Button variant=\"secondary\">Secondary button</Button>\n </>\n ),\n};\n\nexport const ButtonGroupExample = Template.bind({});\nButtonGroupExample.args = {\n ...defaultArgs,\n};\n"],"names":["codeString","ButtonGroup_stories","ButtonGroup","Template","args","jsx","Container","defaultArgs","jsxs","Fragment","Button","ButtonGroupExample"],"mappings":";;;;AASA,MAAMA,IAAa;AAAA;AAAA;AAAA;AAAA;AAAA,GAQJC,IAAA;AAAA,EACb,OAAO;AAAA,EACP,WAAWC;AAAA,EACX,UAAU;AAAA,IACR,UAAU;AAAA,MACR,OAAO;AAAA,QACL,SAAS;AAAA,MAAA;AAAA,IACX;AAAA,EAEJ;AAAA,EACA,YAAY;AAAA,IACV,kBAAkBA;AAAA,IAClB,YAAAF;AAAA,EAAA;AAEJ,GAEMG,IAAyD,CAACC,MAC9D,gBAAAC,EAACC,KACC,UAAC,gBAAAD,EAAAH,GAAA,EAAa,GAAGE,EAAA,CAAM,EACzB,CAAA,GAGIG,IAA4D;AAAA,EAChE,SAAS;AAAA,EACT,UAAU;AAAA,EACV,UAEI,gBAAAC,EAAAC,GAAA,EAAA,UAAA;AAAA,IAAC,gBAAAJ,EAAAK,GAAA,EAAO,SAAQ,WAAU,UAAc,kBAAA;AAAA,IACvC,gBAAAL,EAAAK,GAAA,EAAO,SAAQ,aAAY,UAAgB,mBAAA,CAAA;AAAA,EAAA,EAC9C,CAAA;AAEJ,GAEaC,IAAqBR,EAAS,KAAK,CAAE,CAAA;AAClDQ,EAAmB,OAAO;AAAA,EACxB,GAAGJ;AACL;"}
1
+ {"version":3,"file":"ButtonGroup.stories.js","sources":["../../../src/components/ButtonGroup/ButtonGroup.stories.tsx"],"sourcesContent":["import type { Meta, StoryFn } from '@storybook/react';\nimport type { PropsWithChildren } from 'react';\nimport type { ButtonGroupProps } from './ButtonGroup';\n\nimport { ButtonGroup } from './ButtonGroup';\n\nimport { Button } from 'components/Buttons/Button';\nimport { Container } from 'storyComponents/Container';\n\nconst codeString = `\n <ButtonGroup reversed={reversed} stacked={stacked}>\n <Button variant={variant} onClick={onClickedFunction}>{children}</Button>\n <Button variant={variant} onClick={onClickedFunction}>{children}</Button>\n </ButtonGroup>\n`;\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n title: 'Molecules/ButtonGroup',\n component: ButtonGroup,\n argTypes: {\n children: {\n table: {\n disable: true,\n },\n },\n },\n parameters: {\n inspectComponent: ButtonGroup,\n codeString: codeString,\n },\n} as Meta<PropsWithChildren<ButtonGroupProps>>;\n\nconst Template: StoryFn<PropsWithChildren<ButtonGroupProps>> = (args) => (\n <Container>\n <ButtonGroup {...args} />\n </Container>\n);\n\nconst defaultArgs: Partial<PropsWithChildren<ButtonGroupProps>> = {\n stacked: false,\n reversed: false,\n children: (\n <>\n <Button variant=\"primary\">Primary button</Button>\n <Button variant=\"secondary\">Secondary button</Button>\n </>\n ),\n};\n\nexport const ButtonGroupExample = Template.bind({});\nButtonGroupExample.args = {\n ...defaultArgs,\n};\n"],"names":["codeString","ButtonGroup_stories","ButtonGroup","Template","args","jsx","Container","defaultArgs","jsxs","Fragment","Button","ButtonGroupExample"],"mappings":";;;;AASA,MAAMA,IAAa;AAAA;AAAA;AAAA;AAAA;AAAA,GAQnBC,IAAe;AAAA,EACb,OAAO;AAAA,EACP,WAAWC;AAAA,EACX,UAAU;AAAA,IACR,UAAU;AAAA,MACR,OAAO;AAAA,QACL,SAAS;AAAA,MAAA;AAAA,IACX;AAAA,EACF;AAAA,EAEF,YAAY;AAAA,IACV,kBAAkBA;AAAA,IAClB,YAAAF;AAAA,EAAA;AAEJ,GAEMG,IAAyD,CAACC,MAC9D,gBAAAC,EAACC,KACC,UAAA,gBAAAD,EAACH,GAAA,EAAa,GAAGE,EAAA,CAAM,EAAA,CACzB,GAGIG,IAA4D;AAAA,EAChE,SAAS;AAAA,EACT,UAAU;AAAA,EACV,UACE,gBAAAC,EAAAC,GAAA,EACE,UAAA;AAAA,IAAA,gBAAAJ,EAACK,GAAA,EAAO,SAAQ,WAAU,UAAA,kBAAc;AAAA,IACxC,gBAAAL,EAACK,GAAA,EAAO,SAAQ,aAAY,UAAA,mBAAA,CAAgB;AAAA,EAAA,EAAA,CAC9C;AAEJ,GAEaC,IAAqBR,EAAS,KAAK,CAAA,CAAE;AAClDQ,EAAmB,OAAO;AAAA,EACxB,GAAGJ;AACL;"}
@@ -1 +1 @@
1
- {"version":3,"file":"Button.js","sources":["../../../src/components/Buttons/Button.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport { forwardRef } from 'react';\n\nimport type { ButtonHTMLAttributes, ReactNode } from 'react';\nimport type { UIButtonVariant } from 'types/UserInterface';\n\nimport styles from './Button.module.css';\n\nexport interface ButtonProps extends Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'className' | 'style'> {\n /** The variant of the button. */\n variant: UIButtonVariant;\n /** The element to show inside the button. */\n children: ReactNode;\n /** Renders the button as a flex column. */\n displayColumn?: boolean;\n}\n\n/** Represents a component for a button. */\nexport const Button = forwardRef<HTMLButtonElement, ButtonProps>(\n ({ children, type = 'button', variant, displayColumn = false, ...restProps }: ButtonProps, forwardedRef) => {\n return (\n <button\n {...restProps}\n type={type}\n ref={forwardedRef}\n className={clsx(styles['button'], styles[`button--${variant}`], {\n [styles['button--wide-column']]: displayColumn,\n })}\n >\n {children}\n </button>\n );\n }\n);\n"],"names":["Button","forwardRef","children","type","variant","displayColumn","restProps","forwardedRef","jsx","clsx","styles"],"mappings":";;;;AAkBO,MAAMA,IAASC;AAAA,EACpB,CAAC,EAAE,UAAAC,GAAU,MAAAC,IAAO,UAAU,SAAAC,GAAS,eAAAC,IAAgB,IAAO,GAAGC,EAAU,GAAgBC,MAEvF,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACE,GAAGF;AAAA,MACJ,MAAAH;AAAA,MACA,KAAKI;AAAA,MACL,WAAWE,EAAKC,EAAO,QAAWA,EAAO,WAAWN,CAAO,EAAE,GAAG;AAAA,QAC9D,CAACM,EAAO,qBAAqB,CAAC,GAAGL;AAAA,MAAA,CAClC;AAAA,MAEA,UAAAH;AAAA,IAAA;AAAA,EACH;AAGN;"}
1
+ {"version":3,"file":"Button.js","sources":["../../../src/components/Buttons/Button.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport { forwardRef } from 'react';\n\nimport type { ButtonHTMLAttributes, ReactNode } from 'react';\nimport type { UIButtonVariant } from 'types/UserInterface';\n\nimport styles from './Button.module.css';\n\nexport interface ButtonProps extends Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'className' | 'style'> {\n /** The variant of the button. */\n variant: UIButtonVariant;\n /** The element to show inside the button. */\n children: ReactNode;\n /** Renders the button as a flex column. */\n displayColumn?: boolean;\n}\n\n/** Represents a component for a button. */\nexport const Button = forwardRef<HTMLButtonElement, ButtonProps>(\n ({ children, type = 'button', variant, displayColumn = false, ...restProps }: ButtonProps, forwardedRef) => {\n return (\n <button\n {...restProps}\n type={type}\n ref={forwardedRef}\n className={clsx(styles['button'], styles[`button--${variant}`], {\n [styles['button--wide-column']]: displayColumn,\n })}\n >\n {children}\n </button>\n );\n }\n);\n"],"names":["Button","forwardRef","children","type","variant","displayColumn","restProps","forwardedRef","jsx","clsx","styles"],"mappings":";;;;AAkBO,MAAMA,IAASC;AAAA,EACpB,CAAC,EAAE,UAAAC,GAAU,MAAAC,IAAO,UAAU,SAAAC,GAAS,eAAAC,IAAgB,IAAO,GAAGC,EAAA,GAA0BC,MAEvF,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACE,GAAGF;AAAA,MACJ,MAAAH;AAAA,MACA,KAAKI;AAAA,MACL,WAAWE,EAAKC,EAAO,QAAWA,EAAO,WAAWN,CAAO,EAAE,GAAG;AAAA,QAC9D,CAACM,EAAO,qBAAqB,CAAC,GAAGL;AAAA,MAAA,CAClC;AAAA,MAEA,UAAAH;AAAA,IAAA;AAAA,EAAA;AAIT;"}
@@ -2,5 +2,5 @@ import { Meta } from '@storybook/react';
2
2
  import { ButtonProps } from './Button';
3
3
  declare const _default: Meta<ButtonProps>;
4
4
  export default _default;
5
- export declare const ButtonExample: import('@storybook/core/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, ButtonProps>;
6
- export declare const WithMultipleChildren: import('@storybook/core/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, ButtonProps>;
5
+ export declare const ButtonExample: import('storybook/internal/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, ButtonProps>;
6
+ export declare const WithMultipleChildren: import('storybook/internal/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, ButtonProps>;
@@ -1,5 +1,5 @@
1
1
  import { jsx as t, jsxs as a, Fragment as s } from "react/jsx-runtime";
2
- import { fn as l } from "../../index-Dwqes6RH.js";
2
+ import { W as l } from "../../index-Di9WPZUe.js";
3
3
  import { Button as n } from "./Button.js";
4
4
  const c = "<Button variant={variant} onClick={onClictFunction}>{children}</Button>", h = {
5
5
  title: "Atoms/Buttons/Button",
@@ -23,26 +23,26 @@ const c = "<Button variant={variant} onClick={onClictFunction}>{children}</Butto
23
23
  inspectComponent: n,
24
24
  codeString: c
25
25
  }
26
- }, e = (o) => /* @__PURE__ */ t(n, { ...o }), i = {
26
+ }, r = (o) => /* @__PURE__ */ t(n, { ...o }), i = {
27
27
  variant: "primary",
28
28
  disabled: !1,
29
29
  displayColumn: !1,
30
30
  onClick: l()
31
- }, d = e.bind({});
31
+ }, d = r.bind({});
32
32
  d.args = {
33
33
  children: "Click me!",
34
34
  ...i
35
35
  };
36
- const r = e.bind({});
37
- r.args = {
36
+ const e = r.bind({});
37
+ e.args = {
38
38
  ...i,
39
39
  children: /* @__PURE__ */ a(s, { children: [
40
40
  /* @__PURE__ */ t("div", { children: "Child 1" }),
41
41
  /* @__PURE__ */ t("div", { children: "Child 2" })
42
42
  ] })
43
43
  };
44
- r.argTypes = {
45
- ...r.argTypes,
44
+ e.argTypes = {
45
+ ...e.argTypes,
46
46
  children: {
47
47
  table: {
48
48
  disable: !0
@@ -52,7 +52,7 @@ r.argTypes = {
52
52
  };
53
53
  export {
54
54
  d as ButtonExample,
55
- r as WithMultipleChildren,
55
+ e as WithMultipleChildren,
56
56
  h as default
57
57
  };
58
58
  //# sourceMappingURL=Button.stories.js.map