@arbor-education/design-system.components 4.5.0 → 4.7.0-alpha.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 (312) hide show
  1. package/.changeset/twenty-groups-wonder.md +5 -0
  2. package/.changeset/yellow-falcons-search.md +5 -0
  3. package/CHANGELOG.md +12 -0
  4. package/dist/components/avatar/Avatar.js +2 -2
  5. package/dist/components/avatar/Avatar.js.map +1 -1
  6. package/dist/components/badge/Badge.stories.d.ts +0 -1
  7. package/dist/components/badge/Badge.stories.d.ts.map +1 -1
  8. package/dist/components/badge/Badge.stories.js +0 -69
  9. package/dist/components/badge/Badge.stories.js.map +1 -1
  10. package/dist/components/button/Button.story.d.ts +47 -0
  11. package/dist/components/button/Button.story.d.ts.map +1 -0
  12. package/dist/components/button/Button.story.js +123 -0
  13. package/dist/components/button/Button.story.js.map +1 -0
  14. package/dist/components/button/ButtonUsageExample.d.ts +2 -0
  15. package/dist/components/button/ButtonUsageExample.d.ts.map +1 -0
  16. package/dist/components/button/ButtonUsageExample.js +11 -0
  17. package/dist/components/button/ButtonUsageExample.js.map +1 -0
  18. package/dist/components/combobox/useElementWidth.d.ts +2 -0
  19. package/dist/components/combobox/useElementWidth.d.ts.map +1 -0
  20. package/dist/components/combobox/useElementWidth.js +31 -0
  21. package/dist/components/combobox/useElementWidth.js.map +1 -0
  22. package/dist/components/combobox/useVisibleChips.d.ts +21 -0
  23. package/dist/components/combobox/useVisibleChips.d.ts.map +1 -0
  24. package/dist/components/combobox/useVisibleChips.js +59 -0
  25. package/dist/components/combobox/useVisibleChips.js.map +1 -0
  26. package/dist/components/combobox/useVisibleChips.test.d.ts +2 -0
  27. package/dist/components/combobox/useVisibleChips.test.d.ts.map +1 -0
  28. package/dist/components/combobox/useVisibleChips.test.js +81 -0
  29. package/dist/components/combobox/useVisibleChips.test.js.map +1 -0
  30. package/dist/components/dot/Dot.d.ts.map +1 -1
  31. package/dist/components/dot/Dot.js +1 -1
  32. package/dist/components/dot/Dot.js.map +1 -1
  33. package/dist/components/formField/inputs/checkbox/CheckboxInput.d.ts +2 -2
  34. package/dist/components/formField/inputs/checkbox/CheckboxInput.d.ts.map +1 -1
  35. package/dist/components/formField/inputs/checkbox/CheckboxInput.js +1 -1
  36. package/dist/components/formField/inputs/checkbox/CheckboxInput.js.map +1 -1
  37. package/dist/components/formField/inputs/checkbox/CheckboxInput.stories.d.ts +2 -0
  38. package/dist/components/formField/inputs/checkbox/CheckboxInput.stories.d.ts.map +1 -1
  39. package/dist/components/formField/inputs/checkbox/CheckboxInput.stories.js +100 -0
  40. package/dist/components/formField/inputs/checkbox/CheckboxInput.stories.js.map +1 -1
  41. package/dist/components/formField/inputs/checkbox/CheckboxInput.test.js +17 -1
  42. package/dist/components/formField/inputs/checkbox/CheckboxInput.test.js.map +1 -1
  43. package/dist/components/heading/HeadingInnerContainer.d.ts +5 -0
  44. package/dist/components/heading/HeadingInnerContainer.d.ts.map +1 -0
  45. package/dist/components/heading/HeadingInnerContainer.js +7 -0
  46. package/dist/components/heading/HeadingInnerContainer.js.map +1 -0
  47. package/dist/components/icoText/IcoText.d.ts +37 -0
  48. package/dist/components/icoText/IcoText.d.ts.map +1 -0
  49. package/dist/components/icoText/IcoText.js +29 -0
  50. package/dist/components/icoText/IcoText.js.map +1 -0
  51. package/dist/components/icoText/IcoText.stories.d.ts +60 -0
  52. package/dist/components/icoText/IcoText.stories.d.ts.map +1 -0
  53. package/dist/components/icoText/IcoText.stories.js +319 -0
  54. package/dist/components/icoText/IcoText.stories.js.map +1 -0
  55. package/dist/components/icoText/IcoText.test.d.ts +2 -0
  56. package/dist/components/icoText/IcoText.test.d.ts.map +1 -0
  57. package/dist/components/icoText/IcoText.test.js +27 -0
  58. package/dist/components/icoText/IcoText.test.js.map +1 -0
  59. package/dist/components/pill/Pill.d.ts.map +1 -1
  60. package/dist/components/pill/Pill.js +1 -1
  61. package/dist/components/pill/Pill.js.map +1 -1
  62. package/dist/components/searchBar/SearchBar.d.ts.map +1 -1
  63. package/dist/components/searchBar/SearchBar.js +1 -1
  64. package/dist/components/searchBar/SearchBar.js.map +1 -1
  65. package/dist/components/searchBar/SearchBar.test.js +3 -3
  66. package/dist/components/searchBar/SearchBar.test.js.map +1 -1
  67. package/dist/components/sidebarNav/SidebarNav.d.ts +46 -0
  68. package/dist/components/sidebarNav/SidebarNav.d.ts.map +1 -0
  69. package/dist/components/sidebarNav/SidebarNav.js +102 -0
  70. package/dist/components/sidebarNav/SidebarNav.js.map +1 -0
  71. package/dist/components/sidebarNav/SidebarNav.stories.d.ts +61 -0
  72. package/dist/components/sidebarNav/SidebarNav.stories.d.ts.map +1 -0
  73. package/dist/components/sidebarNav/SidebarNav.stories.js +253 -0
  74. package/dist/components/sidebarNav/SidebarNav.stories.js.map +1 -0
  75. package/dist/components/sidebarNav/SidebarNav.test.d.ts +2 -0
  76. package/dist/components/sidebarNav/SidebarNav.test.d.ts.map +1 -0
  77. package/dist/components/sidebarNav/SidebarNav.test.js +240 -0
  78. package/dist/components/sidebarNav/SidebarNav.test.js.map +1 -0
  79. package/dist/components/sidebarNav/SidebarNavContext.d.ts +13 -0
  80. package/dist/components/sidebarNav/SidebarNavContext.d.ts.map +1 -0
  81. package/dist/components/sidebarNav/SidebarNavContext.js +15 -0
  82. package/dist/components/sidebarNav/SidebarNavContext.js.map +1 -0
  83. package/dist/components/sidebarNav/SidebarNavGroup.d.ts +10 -0
  84. package/dist/components/sidebarNav/SidebarNavGroup.d.ts.map +1 -0
  85. package/dist/components/sidebarNav/SidebarNavGroup.js +16 -0
  86. package/dist/components/sidebarNav/SidebarNavGroup.js.map +1 -0
  87. package/dist/components/sidebarNav/SidebarNavItem.d.ts +32 -0
  88. package/dist/components/sidebarNav/SidebarNavItem.d.ts.map +1 -0
  89. package/dist/components/sidebarNav/SidebarNavItem.js +44 -0
  90. package/dist/components/sidebarNav/SidebarNavItem.js.map +1 -0
  91. package/dist/components/sidebarNav/SidebarNavItemFavourite.d.ts +8 -0
  92. package/dist/components/sidebarNav/SidebarNavItemFavourite.d.ts.map +1 -0
  93. package/dist/components/sidebarNav/SidebarNavItemFavourite.js +14 -0
  94. package/dist/components/sidebarNav/SidebarNavItemFavourite.js.map +1 -0
  95. package/dist/components/sidebarNav/SidebarNavPanel.d.ts +4 -0
  96. package/dist/components/sidebarNav/SidebarNavPanel.d.ts.map +1 -0
  97. package/dist/components/sidebarNav/SidebarNavPanel.js +9 -0
  98. package/dist/components/sidebarNav/SidebarNavPanel.js.map +1 -0
  99. package/dist/components/sidebarNav/SidebarNavPanelNav.d.ts +10 -0
  100. package/dist/components/sidebarNav/SidebarNavPanelNav.d.ts.map +1 -0
  101. package/dist/components/sidebarNav/SidebarNavPanelNav.js +21 -0
  102. package/dist/components/sidebarNav/SidebarNavPanelNav.js.map +1 -0
  103. package/dist/components/sidebarNav/SidebarNavRail.d.ts +6 -0
  104. package/dist/components/sidebarNav/SidebarNavRail.d.ts.map +1 -0
  105. package/dist/components/sidebarNav/SidebarNavRail.js +7 -0
  106. package/dist/components/sidebarNav/SidebarNavRail.js.map +1 -0
  107. package/dist/components/sidebarNav/SidebarNavRailItem.d.ts +10 -0
  108. package/dist/components/sidebarNav/SidebarNavRailItem.d.ts.map +1 -0
  109. package/dist/components/sidebarNav/SidebarNavRailItem.js +25 -0
  110. package/dist/components/sidebarNav/SidebarNavRailItem.js.map +1 -0
  111. package/dist/components/sidebarNav/SidebarNavRailList.d.ts +4 -0
  112. package/dist/components/sidebarNav/SidebarNavRailList.d.ts.map +1 -0
  113. package/dist/components/sidebarNav/SidebarNavRailList.js +7 -0
  114. package/dist/components/sidebarNav/SidebarNavRailList.js.map +1 -0
  115. package/dist/components/sidebarNav/SidebarNavRailSlot.d.ts +6 -0
  116. package/dist/components/sidebarNav/SidebarNavRailSlot.d.ts.map +1 -0
  117. package/dist/components/sidebarNav/SidebarNavRailSlot.js +7 -0
  118. package/dist/components/sidebarNav/SidebarNavRailSlot.js.map +1 -0
  119. package/dist/components/sidebarNav/SidebarNavSeparator.d.ts +6 -0
  120. package/dist/components/sidebarNav/SidebarNavSeparator.d.ts.map +1 -0
  121. package/dist/components/sidebarNav/SidebarNavSeparator.js +8 -0
  122. package/dist/components/sidebarNav/SidebarNavSeparator.js.map +1 -0
  123. package/dist/components/sidebarNav/SidebarNavTitle.d.ts +4 -0
  124. package/dist/components/sidebarNav/SidebarNavTitle.d.ts.map +1 -0
  125. package/dist/components/sidebarNav/SidebarNavTitle.js +7 -0
  126. package/dist/components/sidebarNav/SidebarNavTitle.js.map +1 -0
  127. package/dist/components/sidebarNav/SidebarNavTooltip.d.ts +7 -0
  128. package/dist/components/sidebarNav/SidebarNavTooltip.d.ts.map +1 -0
  129. package/dist/components/sidebarNav/SidebarNavTooltip.js +9 -0
  130. package/dist/components/sidebarNav/SidebarNavTooltip.js.map +1 -0
  131. package/dist/components/sidebarNav/SidebarNavTrigger.d.ts +8 -0
  132. package/dist/components/sidebarNav/SidebarNavTrigger.d.ts.map +1 -0
  133. package/dist/components/sidebarNav/SidebarNavTrigger.js +15 -0
  134. package/dist/components/sidebarNav/SidebarNavTrigger.js.map +1 -0
  135. package/dist/components/sidebarNav/index.d.ts +4 -0
  136. package/dist/components/sidebarNav/index.d.ts.map +1 -0
  137. package/dist/components/sidebarNav/index.js +3 -0
  138. package/dist/components/sidebarNav/index.js.map +1 -0
  139. package/dist/components/sidebarNav/resolvePanelItemProps.d.ts +4 -0
  140. package/dist/components/sidebarNav/resolvePanelItemProps.d.ts.map +1 -0
  141. package/dist/components/sidebarNav/resolvePanelItemProps.js +43 -0
  142. package/dist/components/sidebarNav/resolvePanelItemProps.js.map +1 -0
  143. package/dist/components/sidebarNav/resolvePanelItemProps.test.d.ts +2 -0
  144. package/dist/components/sidebarNav/resolvePanelItemProps.test.d.ts.map +1 -0
  145. package/dist/components/sidebarNav/resolvePanelItemProps.test.js +52 -0
  146. package/dist/components/sidebarNav/resolvePanelItemProps.test.js.map +1 -0
  147. package/dist/components/sidebarNav/types.d.ts +100 -0
  148. package/dist/components/sidebarNav/types.d.ts.map +1 -0
  149. package/dist/components/sidebarNav/types.js +4 -0
  150. package/dist/components/sidebarNav/types.js.map +1 -0
  151. package/dist/components/sidebarNav/useControllableBoolean.d.ts +9 -0
  152. package/dist/components/sidebarNav/useControllableBoolean.d.ts.map +1 -0
  153. package/dist/components/sidebarNav/useControllableBoolean.js +15 -0
  154. package/dist/components/sidebarNav/useControllableBoolean.js.map +1 -0
  155. package/dist/components/slideover/Slideover.stories.d.ts +10 -0
  156. package/dist/components/slideover/Slideover.stories.d.ts.map +1 -0
  157. package/dist/components/slideover/Slideover.stories.js +12 -0
  158. package/dist/components/slideover/Slideover.stories.js.map +1 -0
  159. package/dist/components/table/BulkActionsDropdown.d.ts +12 -0
  160. package/dist/components/table/BulkActionsDropdown.d.ts.map +1 -0
  161. package/dist/components/table/BulkActionsDropdown.js +11 -0
  162. package/dist/components/table/BulkActionsDropdown.js.map +1 -0
  163. package/dist/components/table/HideColumnsDropdown.d.ts +9 -0
  164. package/dist/components/table/HideColumnsDropdown.d.ts.map +1 -0
  165. package/dist/components/table/HideColumnsDropdown.js +33 -0
  166. package/dist/components/table/HideColumnsDropdown.js.map +1 -0
  167. package/dist/components/table/Table.d.ts +1 -1
  168. package/dist/components/table/Table.stories.d.ts.map +1 -1
  169. package/dist/components/table/Table.stories.js +0 -5
  170. package/dist/components/table/Table.stories.js.map +1 -1
  171. package/dist/components/table/Table.test.js +0 -5
  172. package/dist/components/table/Table.test.js.map +1 -1
  173. package/dist/components/table/cellRenderers/SelectDropdownCellEditor.d.ts +8 -0
  174. package/dist/components/table/cellRenderers/SelectDropdownCellEditor.d.ts.map +1 -0
  175. package/dist/components/table/cellRenderers/SelectDropdownCellEditor.js +19 -0
  176. package/dist/components/table/cellRenderers/SelectDropdownCellEditor.js.map +1 -0
  177. package/dist/components/table/hooks/useHistory.d.ts +20 -0
  178. package/dist/components/table/hooks/useHistory.d.ts.map +1 -0
  179. package/dist/components/table/hooks/useHistory.js +73 -0
  180. package/dist/components/table/hooks/useHistory.js.map +1 -0
  181. package/dist/components/table/hooks/useTableHistory.d.ts +21 -0
  182. package/dist/components/table/hooks/useTableHistory.d.ts.map +1 -0
  183. package/dist/components/table/hooks/useTableHistory.js +88 -0
  184. package/dist/components/table/hooks/useTableHistory.js.map +1 -0
  185. package/dist/components/table/pagination/TableSettingsDropdown.d.ts +2 -0
  186. package/dist/components/table/pagination/TableSettingsDropdown.d.ts.map +1 -0
  187. package/dist/components/table/pagination/TableSettingsDropdown.js +42 -0
  188. package/dist/components/table/pagination/TableSettingsDropdown.js.map +1 -0
  189. package/dist/components/table/tableHeader/TableHeader.d.ts +14 -0
  190. package/dist/components/table/tableHeader/TableHeader.d.ts.map +1 -0
  191. package/dist/components/table/tableHeader/TableHeader.js +55 -0
  192. package/dist/components/table/tableHeader/TableHeader.js.map +1 -0
  193. package/dist/components/table/tableHeader/index.d.ts +2 -0
  194. package/dist/components/table/tableHeader/index.d.ts.map +1 -0
  195. package/dist/components/table/tableHeader/index.js +2 -0
  196. package/dist/components/table/tableHeader/index.js.map +1 -0
  197. package/dist/components/table/tableTheme.d.ts +2 -0
  198. package/dist/components/table/tableTheme.d.ts.map +1 -0
  199. package/dist/components/table/tableTheme.js +18 -0
  200. package/dist/components/table/tableTheme.js.map +1 -0
  201. package/dist/components/table/types.d.ts +169 -0
  202. package/dist/components/table/types.d.ts.map +1 -0
  203. package/dist/components/table/types.js +11 -0
  204. package/dist/components/table/types.js.map +1 -0
  205. package/dist/components/table/utils/setAgGridLicenseKey.d.ts +2 -0
  206. package/dist/components/table/utils/setAgGridLicenseKey.d.ts.map +1 -0
  207. package/dist/components/table/utils/setAgGridLicenseKey.js +11 -0
  208. package/dist/components/table/utils/setAgGridLicenseKey.js.map +1 -0
  209. package/dist/layoutTest.stories.d.ts +6 -0
  210. package/dist/layoutTest.stories.d.ts.map +1 -0
  211. package/dist/layoutTest.stories.js +9 -0
  212. package/dist/layoutTest.stories.js.map +1 -0
  213. package/dist/pages/assessmentBuilderPage/AssessmentBuilderPage.d.ts +39 -0
  214. package/dist/pages/assessmentBuilderPage/AssessmentBuilderPage.d.ts.map +1 -0
  215. package/dist/pages/assessmentBuilderPage/AssessmentBuilderPage.js +112 -0
  216. package/dist/pages/assessmentBuilderPage/AssessmentBuilderPage.js.map +1 -0
  217. package/dist/pages/assessmentBuilderPage/AssessmentBuilderPage.stories.d.ts +184 -0
  218. package/dist/pages/assessmentBuilderPage/AssessmentBuilderPage.stories.d.ts.map +1 -0
  219. package/dist/pages/assessmentBuilderPage/AssessmentBuilderPage.stories.js +317 -0
  220. package/dist/pages/assessmentBuilderPage/AssessmentBuilderPage.stories.js.map +1 -0
  221. package/dist/pages/assessmentBuilderPage/AssessmentBuilderPage.test.d.ts +2 -0
  222. package/dist/pages/assessmentBuilderPage/AssessmentBuilderPage.test.d.ts.map +1 -0
  223. package/dist/pages/assessmentBuilderPage/AssessmentBuilderPage.test.js +160 -0
  224. package/dist/pages/assessmentBuilderPage/AssessmentBuilderPage.test.js.map +1 -0
  225. package/dist/pages/assessmentSettingsPage/AssessmentSettingsPage.d.ts +11 -0
  226. package/dist/pages/assessmentSettingsPage/AssessmentSettingsPage.d.ts.map +1 -0
  227. package/dist/pages/assessmentSettingsPage/AssessmentSettingsPage.js +13 -0
  228. package/dist/pages/assessmentSettingsPage/AssessmentSettingsPage.js.map +1 -0
  229. package/dist/pages/assessmentSettingsPage/AssessmentSettingsPage.stories.d.ts +174 -0
  230. package/dist/pages/assessmentSettingsPage/AssessmentSettingsPage.stories.d.ts.map +1 -0
  231. package/dist/pages/assessmentSettingsPage/AssessmentSettingsPage.stories.js +212 -0
  232. package/dist/pages/assessmentSettingsPage/AssessmentSettingsPage.stories.js.map +1 -0
  233. package/dist/pages/assessmentSettingsPage/AssessmentSettingsPage.test.d.ts +2 -0
  234. package/dist/pages/assessmentSettingsPage/AssessmentSettingsPage.test.d.ts.map +1 -0
  235. package/dist/pages/assessmentSettingsPage/AssessmentSettingsPage.test.js +84 -0
  236. package/dist/pages/assessmentSettingsPage/AssessmentSettingsPage.test.js.map +1 -0
  237. package/dist/pages/assessmentsPage/AssessmentsPage.d.ts +16 -0
  238. package/dist/pages/assessmentsPage/AssessmentsPage.d.ts.map +1 -0
  239. package/dist/pages/assessmentsPage/AssessmentsPage.js +31 -0
  240. package/dist/pages/assessmentsPage/AssessmentsPage.js.map +1 -0
  241. package/dist/pages/assessmentsPage/AssessmentsPage.stories.d.ts +162 -0
  242. package/dist/pages/assessmentsPage/AssessmentsPage.stories.d.ts.map +1 -0
  243. package/dist/pages/assessmentsPage/AssessmentsPage.stories.js +290 -0
  244. package/dist/pages/assessmentsPage/AssessmentsPage.stories.js.map +1 -0
  245. package/dist/pages/assessmentsPage/AssessmentsPage.test.d.ts +2 -0
  246. package/dist/pages/assessmentsPage/AssessmentsPage.test.d.ts.map +1 -0
  247. package/dist/pages/assessmentsPage/AssessmentsPage.test.js +109 -0
  248. package/dist/pages/assessmentsPage/AssessmentsPage.test.js.map +1 -0
  249. package/dist/pages/customReportWriterPage/CustomReportWriterPage.d.ts +40 -0
  250. package/dist/pages/customReportWriterPage/CustomReportWriterPage.d.ts.map +1 -0
  251. package/dist/pages/customReportWriterPage/CustomReportWriterPage.js +156 -0
  252. package/dist/pages/customReportWriterPage/CustomReportWriterPage.js.map +1 -0
  253. package/dist/pages/customReportWriterPage/CustomReportWriterPage.stories.d.ts +239 -0
  254. package/dist/pages/customReportWriterPage/CustomReportWriterPage.stories.d.ts.map +1 -0
  255. package/dist/pages/customReportWriterPage/CustomReportWriterPage.stories.js +318 -0
  256. package/dist/pages/customReportWriterPage/CustomReportWriterPage.stories.js.map +1 -0
  257. package/dist/pages/customReportWriterPage/CustomReportWriterPage.test.d.ts +2 -0
  258. package/dist/pages/customReportWriterPage/CustomReportWriterPage.test.d.ts.map +1 -0
  259. package/dist/pages/customReportWriterPage/CustomReportWriterPage.test.js +183 -0
  260. package/dist/pages/customReportWriterPage/CustomReportWriterPage.test.js.map +1 -0
  261. package/dist/pages/gradeSetsPage/GradeSetsPage.d.ts +26 -0
  262. package/dist/pages/gradeSetsPage/GradeSetsPage.d.ts.map +1 -0
  263. package/dist/pages/gradeSetsPage/GradeSetsPage.js +33 -0
  264. package/dist/pages/gradeSetsPage/GradeSetsPage.js.map +1 -0
  265. package/dist/pages/gradeSetsPage/GradeSetsPage.stories.d.ts +176 -0
  266. package/dist/pages/gradeSetsPage/GradeSetsPage.stories.d.ts.map +1 -0
  267. package/dist/pages/gradeSetsPage/GradeSetsPage.stories.js +237 -0
  268. package/dist/pages/gradeSetsPage/GradeSetsPage.stories.js.map +1 -0
  269. package/dist/pages/gradeSetsPage/GradeSetsPage.test.d.ts +2 -0
  270. package/dist/pages/gradeSetsPage/GradeSetsPage.test.d.ts.map +1 -0
  271. package/dist/pages/gradeSetsPage/GradeSetsPage.test.js +91 -0
  272. package/dist/pages/gradeSetsPage/GradeSetsPage.test.js.map +1 -0
  273. package/dist/pages/studentProfilePage/StudentProfilePage.d.ts +48 -0
  274. package/dist/pages/studentProfilePage/StudentProfilePage.d.ts.map +1 -0
  275. package/dist/pages/studentProfilePage/StudentProfilePage.js +52 -0
  276. package/dist/pages/studentProfilePage/StudentProfilePage.js.map +1 -0
  277. package/dist/pages/studentProfilePage/StudentProfilePage.stories.d.ts +218 -0
  278. package/dist/pages/studentProfilePage/StudentProfilePage.stories.d.ts.map +1 -0
  279. package/dist/pages/studentProfilePage/StudentProfilePage.stories.js +273 -0
  280. package/dist/pages/studentProfilePage/StudentProfilePage.stories.js.map +1 -0
  281. package/dist/pages/studentProfilePage/StudentProfilePage.test.d.ts +2 -0
  282. package/dist/pages/studentProfilePage/StudentProfilePage.test.d.ts.map +1 -0
  283. package/dist/pages/studentProfilePage/StudentProfilePage.test.js +197 -0
  284. package/dist/pages/studentProfilePage/StudentProfilePage.test.js.map +1 -0
  285. package/dist/utils/PopupParentContext.d.ts +3 -0
  286. package/dist/utils/PopupParentContext.d.ts.map +1 -0
  287. package/dist/utils/PopupParentContext.js +6 -0
  288. package/dist/utils/PopupParentContext.js.map +1 -0
  289. package/dist/utils/PopupParentContext.stories.d.ts +17 -0
  290. package/dist/utils/PopupParentContext.stories.d.ts.map +1 -0
  291. package/dist/utils/PopupParentContext.stories.js +266 -0
  292. package/dist/utils/PopupParentContext.stories.js.map +1 -0
  293. package/dist/utils/getDefaultPopupParent.d.ts +2 -0
  294. package/dist/utils/getDefaultPopupParent.d.ts.map +1 -0
  295. package/dist/utils/getDefaultPopupParent.js +19 -0
  296. package/dist/utils/getDefaultPopupParent.js.map +1 -0
  297. package/dist/utils/popupParent/PopupParentContext.stories.d.ts.map +1 -1
  298. package/dist/utils/popupParent/PopupParentContext.stories.js +1 -1
  299. package/dist/utils/popupParent/PopupParentContext.stories.js.map +1 -1
  300. package/package.json +4 -4
  301. package/src/components/avatar/Avatar.tsx +2 -2
  302. package/src/components/badge/Badge.stories.tsx +0 -103
  303. package/src/components/dot/Dot.tsx +1 -0
  304. package/src/components/formField/inputs/checkbox/CheckboxInput.stories.tsx +178 -1
  305. package/src/components/formField/inputs/checkbox/CheckboxInput.test.tsx +58 -0
  306. package/src/components/formField/inputs/checkbox/CheckboxInput.tsx +3 -3
  307. package/src/components/pill/Pill.tsx +1 -0
  308. package/src/components/searchBar/SearchBar.test.tsx +3 -3
  309. package/src/components/searchBar/SearchBar.tsx +1 -0
  310. package/src/components/table/Table.stories.tsx +0 -5
  311. package/src/components/table/Table.test.tsx +0 -5
  312. package/src/utils/popupParent/PopupParentContext.stories.tsx +1 -0
@@ -0,0 +1,197 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { render, screen } from '@testing-library/react';
3
+ import userEvent from '@testing-library/user-event';
4
+ import '@testing-library/jest-dom/vitest';
5
+ import { describe, it, expect, vi } from 'vitest';
6
+ import { StudentProfilePage } from './StudentProfilePage.js';
7
+ // AG Grid needs a license key - mock the Table component to avoid license errors in tests
8
+ vi.mock('Components/table/Table', () => ({
9
+ Table: ({ rowData }) => (_jsx("div", { role: "grid", "aria-label": "Education history table", children: rowData.map(row => (_jsxs("div", { role: "row", children: [_jsx("span", { children: row.dateRange }), _jsx("span", { children: row.institution }), _jsx("span", { children: row.type })] }, row.id))) })),
10
+ }));
11
+ describe('StudentProfilePage', () => {
12
+ describe('page structure', () => {
13
+ it('renders the page title', () => {
14
+ render(_jsx(StudentProfilePage, {}));
15
+ expect(screen.getByRole('heading', { name: 'Student Profile' })).toBeInTheDocument();
16
+ });
17
+ it('renders placeholder SVGs for missing components', () => {
18
+ render(_jsx(StudentProfilePage, {}));
19
+ expect(screen.getByRole('img', { name: /TopNav placeholder/i })).toBeInTheDocument();
20
+ expect(screen.getByRole('img', { name: /SideNav icon variant placeholder/i })).toBeInTheDocument();
21
+ expect(screen.getByRole('img', { name: /SideNav text variant placeholder/i })).toBeInTheDocument();
22
+ expect(screen.getByRole('img', { name: /Breadcrumbs placeholder/i })).toBeInTheDocument();
23
+ expect(screen.getByRole('img', { name: /Avatar placeholder/i })).toBeInTheDocument();
24
+ expect(screen.getByRole('img', { name: /WeeklySchedule placeholder/i })).toBeInTheDocument();
25
+ });
26
+ });
27
+ describe('info panel', () => {
28
+ it('renders the student name in the info section heading', () => {
29
+ render(_jsx(StudentProfilePage, {}));
30
+ expect(screen.getByRole('heading', { name: 'Christopher Longbottom' })).toBeInTheDocument();
31
+ });
32
+ it('renders student categorisation tags', () => {
33
+ render(_jsx(StudentProfilePage, {}));
34
+ expect(screen.getByText('Disadvantaged')).toBeInTheDocument();
35
+ expect(screen.getByText('FSM')).toBeInTheDocument();
36
+ expect(screen.getByText('Pupil Premium Eligible')).toBeInTheDocument();
37
+ expect(screen.getByText('EAL')).toBeInTheDocument();
38
+ expect(screen.getByText('Service Child')).toBeInTheDocument();
39
+ expect(screen.getByText('Has Medical Condition')).toBeInTheDocument();
40
+ });
41
+ });
42
+ describe('sections', () => {
43
+ it('renders all main content sections', () => {
44
+ render(_jsx(StudentProfilePage, {}));
45
+ // Section headings include button text (e.g. "+ Add") in their accessible name,
46
+ // so we use regex to match the section title prefix only
47
+ expect(screen.getByRole('heading', { name: /Pinned Items/i })).toBeInTheDocument();
48
+ expect(screen.getByRole('heading', { name: /^Identity/i })).toBeInTheDocument();
49
+ expect(screen.getByRole('heading', { name: /Student Contact Details/i })).toBeInTheDocument();
50
+ expect(screen.getByRole('heading', { name: /Family, Guardians and Contacts/i })).toBeInTheDocument();
51
+ expect(screen.getByRole('heading', { name: /^Legal/i })).toBeInTheDocument();
52
+ expect(screen.getByRole('heading', { name: /Parental Engagement/i })).toBeInTheDocument();
53
+ expect(screen.getByRole('heading', { name: /Admin Functions/i })).toBeInTheDocument();
54
+ });
55
+ it('renders the empty state for the Legal section', () => {
56
+ render(_jsx(StudentProfilePage, {}));
57
+ expect(screen.getByText('No court orders on record')).toBeInTheDocument();
58
+ });
59
+ it('renders emergency contacts in the widget column', () => {
60
+ render(_jsx(StudentProfilePage, {}));
61
+ expect(screen.getByRole('heading', { name: 'Emergency Contacts' })).toBeInTheDocument();
62
+ expect(screen.getByText('07436 890515')).toBeInTheDocument();
63
+ expect(screen.getByText('Mrs Virginia Longbottom, Mother')).toBeInTheDocument();
64
+ });
65
+ });
66
+ describe('identity data', () => {
67
+ it('renders identity label-value rows', () => {
68
+ render(_jsx(StudentProfilePage, {}));
69
+ expect(screen.getByText('Name')).toBeInTheDocument();
70
+ // "Christopher Longbottom" appears in both the section heading and the Name row value
71
+ expect(screen.getAllByText('Christopher Longbottom').length).toBeGreaterThanOrEqual(2);
72
+ expect(screen.getByText('Nationality')).toBeInTheDocument();
73
+ expect(screen.getByText('United Kingdom (Citizen)')).toBeInTheDocument();
74
+ });
75
+ it('renders student contact email as a link', () => {
76
+ render(_jsx(StudentProfilePage, {}));
77
+ const emailLink = screen.getByRole('link', { name: 'christopher.longbottom@gmail.com' });
78
+ expect(emailLink).toBeInTheDocument();
79
+ expect(emailLink).toHaveAttribute('href', 'mailto:christopher.longbottom@gmail.com');
80
+ });
81
+ });
82
+ describe('filter dropdown', () => {
83
+ it('renders the All Sections filter button', () => {
84
+ render(_jsx(StudentProfilePage, {}));
85
+ expect(screen.getByRole('button', { name: /All Sections/i })).toBeInTheDocument();
86
+ });
87
+ });
88
+ describe('action buttons', () => {
89
+ it('renders the Suggest Student Summary button', () => {
90
+ render(_jsx(StudentProfilePage, {}));
91
+ expect(screen.getByRole('button', { name: /Suggest Student Summary/i })).toBeInTheDocument();
92
+ });
93
+ it('calls onSuggestSummary when clicked', async () => {
94
+ const user = userEvent.setup();
95
+ const onSuggestSummary = vi.fn();
96
+ render(_jsx(StudentProfilePage, { onSuggestSummary: onSuggestSummary }));
97
+ await user.click(screen.getByRole('button', { name: /Suggest Student Summary/i }));
98
+ expect(onSuggestSummary).toHaveBeenCalledTimes(1);
99
+ });
100
+ it('renders Previous and Next student navigation buttons', () => {
101
+ render(_jsx(StudentProfilePage, {}));
102
+ expect(screen.getByRole('button', { name: /Previous/i })).toBeInTheDocument();
103
+ expect(screen.getByRole('button', { name: /Next/i })).toBeInTheDocument();
104
+ });
105
+ it('calls onPreviousStudent when Previous is clicked', async () => {
106
+ const user = userEvent.setup();
107
+ const onPreviousStudent = vi.fn();
108
+ render(_jsx(StudentProfilePage, { onPreviousStudent: onPreviousStudent }));
109
+ await user.click(screen.getByRole('button', { name: /Previous/i }));
110
+ expect(onPreviousStudent).toHaveBeenCalledTimes(1);
111
+ });
112
+ it('calls onNextStudent when Next is clicked', async () => {
113
+ const user = userEvent.setup();
114
+ const onNextStudent = vi.fn();
115
+ render(_jsx(StudentProfilePage, { onNextStudent: onNextStudent }));
116
+ await user.click(screen.getByRole('button', { name: /Next/i }));
117
+ expect(onNextStudent).toHaveBeenCalledTimes(1);
118
+ });
119
+ it('renders Record Planned Absence button', () => {
120
+ render(_jsx(StudentProfilePage, {}));
121
+ expect(screen.getByRole('button', { name: /Record Planned Absence/i })).toBeInTheDocument();
122
+ });
123
+ it('calls onRecordPlannedAbsence when clicked', async () => {
124
+ const user = userEvent.setup();
125
+ const onRecordPlannedAbsence = vi.fn();
126
+ render(_jsx(StudentProfilePage, { onRecordPlannedAbsence: onRecordPlannedAbsence }));
127
+ await user.click(screen.getByRole('button', { name: /Record Planned Absence/i }));
128
+ expect(onRecordPlannedAbsence).toHaveBeenCalledTimes(1);
129
+ });
130
+ });
131
+ describe('section add buttons', () => {
132
+ it('renders add buttons for sections that support it', () => {
133
+ render(_jsx(StudentProfilePage, {}));
134
+ const addButtons = screen.getAllByRole('button', { name: /\+ Add/i });
135
+ expect(addButtons.length).toBeGreaterThanOrEqual(5);
136
+ });
137
+ it('calls onAddIdentity when Identity add button is clicked', async () => {
138
+ const user = userEvent.setup();
139
+ const onAddIdentity = vi.fn();
140
+ render(_jsx(StudentProfilePage, { onAddIdentity: onAddIdentity }));
141
+ // Section headings include the button text — heading name is "Identity + Add"
142
+ // The button lives inside the heading element itself
143
+ const identityHeading = screen.getByRole('heading', { name: /^Identity/i });
144
+ const addButton = identityHeading.querySelector('button');
145
+ if (addButton) {
146
+ await user.click(addButton);
147
+ }
148
+ expect(onAddIdentity).toHaveBeenCalledTimes(1);
149
+ });
150
+ });
151
+ describe('education history table', () => {
152
+ it('renders the education history section heading', () => {
153
+ render(_jsx(StudentProfilePage, {}));
154
+ expect(screen.getByRole('heading', { name: /Education & Employment Status History/i })).toBeInTheDocument();
155
+ });
156
+ it('renders the education history table', () => {
157
+ render(_jsx(StudentProfilePage, {}));
158
+ expect(screen.getByRole('grid', { name: /Education history table/i })).toBeInTheDocument();
159
+ });
160
+ it('renders default education history data', () => {
161
+ render(_jsx(StudentProfilePage, {}));
162
+ expect(screen.getByText('01 Sep 2018 - ongoing')).toBeInTheDocument();
163
+ expect(screen.getByText('Sunnyville School of Product Management')).toBeInTheDocument();
164
+ expect(screen.getByText('School')).toBeInTheDocument();
165
+ });
166
+ it('renders custom education history when provided', () => {
167
+ render(_jsx(StudentProfilePage, { educationHistory: [
168
+ { id: '99', dateRange: '01 Jan 2020 - present', institution: 'Test Academy', type: 'College' },
169
+ ] }));
170
+ expect(screen.getByText('Test Academy')).toBeInTheDocument();
171
+ expect(screen.getByText('College')).toBeInTheDocument();
172
+ });
173
+ });
174
+ describe('accessibility', () => {
175
+ it('renders the page with a main landmark', () => {
176
+ render(_jsx(StudentProfilePage, {}));
177
+ expect(screen.getByRole('main')).toBeInTheDocument();
178
+ });
179
+ it('renders the widget column as an aside landmark', () => {
180
+ render(_jsx(StudentProfilePage, {}));
181
+ expect(screen.getByRole('complementary')).toBeInTheDocument();
182
+ });
183
+ it('renders emergency contacts as an unordered list', () => {
184
+ render(_jsx(StudentProfilePage, {}));
185
+ const contactsSection = screen.getByRole('heading', { name: 'Emergency Contacts' }).closest('section');
186
+ const list = contactsSection?.querySelector('ul');
187
+ expect(list).toBeInTheDocument();
188
+ });
189
+ });
190
+ describe('className prop', () => {
191
+ it('applies custom className to the root element', () => {
192
+ const { container } = render(_jsx(StudentProfilePage, { className: "my-custom-class" }));
193
+ expect(container.firstChild).toHaveClass('my-custom-class');
194
+ });
195
+ });
196
+ });
197
+ //# sourceMappingURL=StudentProfilePage.test.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"StudentProfilePage.test.js","sourceRoot":"","sources":["../../../src/pages/studentProfilePage/StudentProfilePage.test.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAC;AACxD,OAAO,SAAS,MAAM,6BAA6B,CAAC;AACpD,OAAO,kCAAkC,CAAC;AAC1C,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,QAAQ,CAAC;AAClD,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE1D,0FAA0F;AAC1F,EAAE,CAAC,IAAI,CAAC,wBAAwB,EAAE,GAAG,EAAE,CAAC,CAAC;IACvC,KAAK,EAAE,CAAC,EAAE,OAAO,EA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AC,CAAC,iBAAiB,EAAE,CAAC;QAChE,CAAC,CAAC,CAAC;QAEH,EAAE,CAAC,iDAAiD,EAAE,GAAG,EAAE;YACzD,MAAM,CAAC,KAAC,kBAAkB,KAAG,CAAC,CAAC;YAC/B,MAAM,eAAe,GAAG,MAAM,CAAC,SAAS,CAAC,SAAS,EAAE,EAAE,IAAI,EAAE,oBAAoB,EAAE,CAAC,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC;YACvG,MAAM,IAAI,GAAG,eAAe,EAAE,aAAa,CAAC,IAAI,CAAC,CAAC;YAClD,MAAM,CAAC,IAAI,CAAC,CAAC,iBAAiB,EAAE,CAAC;QACnC,CAAC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;IAEH,QAAQ,CAAC,gBAAgB,EAAE,GAAG,EAAE;QAC9B,EAAE,CAAC,8CAA8C,EAAE,GAAG,EAAE;YACtD,MAAM,EAAE,SAAS,EAAE,GAAG,MAAM,CAAC,KAAC,kBAAkB,IAAC,SAAS,EAAC,iBAAiB,GAAG,CAAC,CAAC;YACjF,MAAM,CAAC,SAAS,CAAC,UAAU,CAAC,CAAC,WAAW,CAAC,iBAAiB,CAAC,CAAC;QAC9D,CAAC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { type RefObject } from 'react';
2
+ export declare const PopupParentContext: import("react").Context<RefObject<HTMLElement | null>>;
3
+ //# sourceMappingURL=PopupParentContext.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PopupParentContext.d.ts","sourceRoot":"","sources":["../../src/utils/PopupParentContext.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiB,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAGtD,eAAO,MAAM,kBAAkB,wDAE7B,CAAC"}
@@ -0,0 +1,6 @@
1
+ import { createContext } from 'react';
2
+ import { getDefaultPopupParent } from './getDefaultPopupParent.js';
3
+ export const PopupParentContext = createContext({
4
+ current: getDefaultPopupParent(),
5
+ });
6
+ //# sourceMappingURL=PopupParentContext.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PopupParentContext.js","sourceRoot":"","sources":["../../src/utils/PopupParentContext.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAkB,MAAM,OAAO,CAAC;AACtD,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAEhE,MAAM,CAAC,MAAM,kBAAkB,GAAG,aAAa,CAAgC;IAC7E,OAAO,EAAE,qBAAqB,EAAE;CACjC,CAAC,CAAC"}
@@ -0,0 +1,17 @@
1
+ import type { StoryObj } from '@storybook/react-vite';
2
+ declare function PopupParentContextDocsPage(): import("react/jsx-runtime").JSX.Element;
3
+ declare const meta: {
4
+ title: string;
5
+ parameters: {
6
+ layout: string;
7
+ docs: {
8
+ page: typeof PopupParentContextDocsPage;
9
+ };
10
+ };
11
+ tags: string[];
12
+ };
13
+ export default meta;
14
+ type Story = StoryObj;
15
+ export declare const Default: Story;
16
+ export declare const WithCustomContainer: Story;
17
+ //# sourceMappingURL=PopupParentContext.stories.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PopupParentContext.stories.d.ts","sourceRoot":"","sources":["../../src/utils/PopupParentContext.stories.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAQ,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAkI5D,iBAAS,0BAA0B,4CAelC;AAMD,QAAA,MAAM,IAAI;;;;;;;;;CASM,CAAC;AAEjB,eAAe,IAAI,CAAC;AACpB,KAAK,KAAK,GAAG,QAAQ,CAAC;AA4GtB,eAAO,MAAM,OAAO,EAAE,KAuCrB,CAAC;AAEF,eAAO,MAAM,mBAAmB,EAAE,KAqDjC,CAAC"}
@@ -0,0 +1,266 @@
1
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { useRef } from 'react';
3
+ import { Heading as DocHeading, Markdown, Stories, Subtitle, Title, } from '@storybook/addon-docs/blocks';
4
+ import { PopupParentContext } from './PopupParentContext.js';
5
+ import { Button } from '../components/button/Button.js';
6
+ import { Dropdown } from '../components/dropdown/Dropdown.js';
7
+ // ---------------------------------------------------------------------------
8
+ // Docs page content
9
+ // ---------------------------------------------------------------------------
10
+ const DESCRIPTION_INTRO = [
11
+ '`PopupParentContext` is a React context that controls where portalled floating elements',
12
+ '— dropdowns, tooltips, date pickers, comboboxes — are rendered in the DOM.',
13
+ 'In most applications you do **not** need to configure this: the default behaviour portals all floating',
14
+ 'content to a shared `<div id="ds-popup-parent">` appended to `document.body`.',
15
+ ].join(' ');
16
+ const USAGE_GUIDANCE = [
17
+ '### When you need PopupParentContext',
18
+ '',
19
+ '- **Custom virtualised panels** — when your layout clips content with `overflow: hidden` AND you need',
20
+ ' popups to appear inside that container (not body), provide a ref to a container element inside the',
21
+ ' clip boundary',
22
+ '- **Non-Arbor modals and drawers** — if you wrap Arbor components inside a third-party modal, floating',
23
+ ' elements may render beneath the modal overlay due to z-index stacking. Provide a container inside the',
24
+ ' modal to keep popups on top',
25
+ '- **Custom stacking contexts** — when `transform`, `isolation`, or `will-change` creates a stacking',
26
+ ' context above `z-index: 1` (the default popup parent z-index), popups may appear beneath fixed UI',
27
+ ' chrome. Move the container inside the stacking context',
28
+ '',
29
+ '---',
30
+ '',
31
+ '### When you do NOT need PopupParentContext',
32
+ '',
33
+ '| Situation | Why you are safe |',
34
+ '|---|---|',
35
+ '| `Dropdown`, `Tooltip`, `Combobox` in a standard page layout | Default context portals to `document.body` — no clipping |',
36
+ '| Floating elements inside Arbor `Modal` | Modal provides its overlay as the popup parent automatically |',
37
+ '| `Table` column filters | `BooleanFilter` and `TimeFilter` wrap their children in a provider automatically |',
38
+ ].join('\n');
39
+ const DEVELOPER_NOTES = [
40
+ '### Components that consume PopupParentContext',
41
+ '',
42
+ '| Component | What gets portalled |',
43
+ '|---|---|',
44
+ '| `Dropdown` | `Dropdown.Content` panel |',
45
+ '| `Tooltip` | Tooltip bubble |',
46
+ '| `Combobox` | Options listbox |',
47
+ '| `DatePicker` | Calendar popup |',
48
+ '| `DateTimePicker` | Calendar + time popup |',
49
+ '| `Modal` | Modal overlay (also provides itself as parent for any floating elements inside) |',
50
+ '| `SlideoverManager` | Slideover panel |',
51
+ '| `Table` column filters | `BooleanFilter`, `TimeFilter` (wraps automatically) |',
52
+ '',
53
+ '---',
54
+ '',
55
+ '### Usage',
56
+ '',
57
+ '```tsx',
58
+ 'import { useRef } from \'react\';',
59
+ 'import { PopupParentContext, Dropdown } from \'@arbor-education/design-system.components\';',
60
+ '',
61
+ 'function ClippedPanel() {',
62
+ ' // ref points to the container that should receive portalled content',
63
+ ' const popupContainerRef = useRef<HTMLDivElement>(null);',
64
+ '',
65
+ ' return (',
66
+ ' <div style={{ position: \'relative\', overflow: \'hidden\', maxHeight: 300 }}>',
67
+ ' {/*',
68
+ ' This div sits OUTSIDE the overflow:hidden clip boundary.',
69
+ ' Floating elements portal here instead of document.body.',
70
+ ' */}',
71
+ ' <div ref={popupContainerRef} style={{ position: \'fixed\', zIndex: 100 }} />',
72
+ '',
73
+ ' <PopupParentContext.Provider value={popupContainerRef}>',
74
+ ' <Dropdown>',
75
+ ' <Dropdown.Trigger>',
76
+ ' <Button variant="dropdown">Actions</Button>',
77
+ ' </Dropdown.Trigger>',
78
+ ' <Dropdown.Content>',
79
+ ' <Dropdown.Item>Edit record</Dropdown.Item>',
80
+ ' <Dropdown.Item>Delete record</Dropdown.Item>',
81
+ ' </Dropdown.Content>',
82
+ ' </Dropdown>',
83
+ ' </PopupParentContext.Provider>',
84
+ ' </div>',
85
+ ' );',
86
+ '}',
87
+ '```',
88
+ '',
89
+ '---',
90
+ '',
91
+ '### Default behaviour',
92
+ '',
93
+ 'When no provider wraps your component tree, `PopupParentContext` falls back to a ref pointing to',
94
+ '`div#ds-popup-parent`. This element is created once and appended to `document.body` with',
95
+ '`position: fixed; z-index: 1`. All floating elements on the page share it.',
96
+ '',
97
+ 'You can pre-create this element for SSR environments:',
98
+ '```html',
99
+ '<div id="ds-popup-parent" style="position: fixed; z-index: 1;"></div>',
100
+ '```',
101
+ '',
102
+ '---',
103
+ '',
104
+ '### Accessibility',
105
+ '',
106
+ '- Portalling to `document.body` or a fixed container does not break focus management — Radix UI',
107
+ ' and the DS components handle focus trapping and restoration internally',
108
+ '- Ensure the portal container has no `aria-hidden` ancestor — this would hide portalled content from',
109
+ ' assistive technology even if it is visible on screen',
110
+ ].join('\n');
111
+ const RELATED_COMPONENTS = [
112
+ '## Related components',
113
+ '',
114
+ '[Dropdown](?path=/docs/components-dropdown--docs) · [Tooltip](?path=/docs/components-tooltip--docs) · [Combobox](?path=/docs/components-combobox--docs) · [DatePicker](?path=/docs/components-datepicker--docs) · [Modal](?path=/docs/components-modal--docs)',
115
+ ].join('\n');
116
+ // ---------------------------------------------------------------------------
117
+ // Docs page
118
+ // ---------------------------------------------------------------------------
119
+ function PopupParentContextDocsPage() {
120
+ return (_jsxs(_Fragment, { children: [_jsx(Title, {}), _jsx(Subtitle, {}), _jsx(Markdown, { children: DESCRIPTION_INTRO }), _jsx(DocHeading, { children: "Usage guidance" }), _jsx(Markdown, { children: USAGE_GUIDANCE }), _jsx(DocHeading, { children: "Developer notes" }), _jsx(Markdown, { children: DEVELOPER_NOTES }), _jsx(DocHeading, { children: "Examples" }), _jsx(Stories, { title: "" }), _jsx(Markdown, { children: RELATED_COMPONENTS })] }));
121
+ }
122
+ // ---------------------------------------------------------------------------
123
+ // Meta
124
+ // ---------------------------------------------------------------------------
125
+ const meta = {
126
+ title: 'Utils/PopupParentContext',
127
+ parameters: {
128
+ layout: 'padded',
129
+ docs: {
130
+ page: PopupParentContextDocsPage,
131
+ },
132
+ },
133
+ tags: ['autodocs'],
134
+ };
135
+ export default meta;
136
+ // ---------------------------------------------------------------------------
137
+ // Helper
138
+ // ---------------------------------------------------------------------------
139
+ const withDescription = (story, description) => ({
140
+ ...story,
141
+ parameters: {
142
+ ...story.parameters,
143
+ docs: {
144
+ ...story.parameters?.docs,
145
+ description: {
146
+ story: description,
147
+ },
148
+ },
149
+ },
150
+ });
151
+ // ---------------------------------------------------------------------------
152
+ // Templates
153
+ // ---------------------------------------------------------------------------
154
+ const DefaultTemplate = () => (_jsxs("div", { style: {
155
+ border: 'var(--border-weight) solid var(--color-grey-200)',
156
+ borderRadius: 'var(--border-radius-small)',
157
+ padding: 'var(--spacing-medium)',
158
+ overflow: 'hidden',
159
+ maxHeight: '120px',
160
+ display: 'flex',
161
+ flexDirection: 'column',
162
+ gap: 'var(--spacing-small)',
163
+ }, children: [_jsxs("p", { style: { margin: 0, fontSize: 'var(--font-size-2-13)', color: 'var(--color-grey-700)' }, children: ["This panel has", ' ', _jsx("code", { children: "overflow: hidden" }), ' ', "\u2014 yet the dropdown opens correctly."] }), _jsxs(Dropdown, { children: [_jsx(Dropdown.Trigger, { children: _jsx(Button, { variant: "dropdown", children: "Actions" }) }), _jsxs(Dropdown.Content, { children: [_jsx(Dropdown.Item, { children: "View pupil profile" }), _jsx(Dropdown.Item, { children: "Edit enrolment" }), _jsx(Dropdown.Separator, {}), _jsx(Dropdown.Item, { children: "Remove from group" })] })] })] }));
164
+ const WithCustomContainerTemplate = () => {
165
+ const popupContainerRef = useRef(null);
166
+ return (_jsxs("div", { style: { position: 'relative', display: 'flex', flexDirection: 'column', gap: 'var(--spacing-small)' }, children: [_jsxs("p", { style: { margin: 0, fontSize: 'var(--font-size-2-13)', color: 'var(--color-grey-700)' }, children: ["The dropdown portals into", ' ', _jsx("code", { children: "popupContainerRef" }), ' ', "(the pink border below) instead of", ' ', _jsx("code", { children: "document.body" }), "."] }), _jsx("div", { ref: popupContainerRef, style: {
167
+ position: 'relative',
168
+ zIndex: 10,
169
+ border: '2px dashed var(--color-semantic-destructive-300)',
170
+ borderRadius: 'var(--border-radius-small)',
171
+ padding: 'var(--spacing-xsmall)',
172
+ minHeight: '2rem',
173
+ }, "aria-label": "Custom popup container" }), _jsx(PopupParentContext.Provider, { value: popupContainerRef, children: _jsxs(Dropdown, { children: [_jsx(Dropdown.Trigger, { children: _jsx(Button, { variant: "dropdown", children: "Actions" }) }), _jsxs(Dropdown.Content, { children: [_jsx(Dropdown.Item, { children: "View pupil profile" }), _jsx(Dropdown.Item, { children: "Edit enrolment" }), _jsx(Dropdown.Separator, {}), _jsx(Dropdown.Item, { children: "Remove from group" })] })] }) })] }));
174
+ };
175
+ // ---------------------------------------------------------------------------
176
+ // Stories
177
+ // ---------------------------------------------------------------------------
178
+ export const Default = withDescription({
179
+ render: DefaultTemplate,
180
+ parameters: {
181
+ controls: { disable: true },
182
+ docs: {
183
+ source: {
184
+ language: 'tsx',
185
+ code: `
186
+ import { Dropdown, Button } from '@arbor-education/design-system.components';
187
+
188
+ // No PopupParentContext setup needed — the dropdown portals to document.body automatically.
189
+ function PupilActionsDropdown() {
190
+ return (
191
+ <Dropdown>
192
+ <Dropdown.Trigger>
193
+ <Button variant="dropdown">Actions</Button>
194
+ </Dropdown.Trigger>
195
+ <Dropdown.Content>
196
+ <Dropdown.Item>View pupil profile</Dropdown.Item>
197
+ <Dropdown.Item>Edit enrolment</Dropdown.Item>
198
+ <Dropdown.Separator />
199
+ <Dropdown.Item>Remove from group</Dropdown.Item>
200
+ </Dropdown.Content>
201
+ </Dropdown>
202
+ );
203
+ }
204
+ export default PupilActionsDropdown;
205
+ `.trim(),
206
+ },
207
+ },
208
+ },
209
+ }, [
210
+ 'The default behaviour — no `PopupParentContext` setup required.',
211
+ 'The dropdown portals its content to `div#ds-popup-parent` in `document.body` via the context default.',
212
+ 'Even inside an `overflow: hidden` container, the popup appears correctly because it exits the clip',
213
+ 'boundary by rendering in the body.',
214
+ ].join(' '));
215
+ export const WithCustomContainer = withDescription({
216
+ render: WithCustomContainerTemplate,
217
+ parameters: {
218
+ controls: { disable: true },
219
+ docs: {
220
+ source: {
221
+ language: 'tsx',
222
+ code: `
223
+ import { useRef } from 'react';
224
+ import { PopupParentContext, Dropdown, Button } from '@arbor-education/design-system.components';
225
+
226
+ function ClippedPanel() {
227
+ const popupContainerRef = useRef<HTMLDivElement>(null);
228
+
229
+ return (
230
+ <div style={{ position: 'relative' }}>
231
+ {/*
232
+ This container receives portalled popups.
233
+ Place it outside any overflow:hidden ancestor,
234
+ with a z-index high enough to appear above surrounding content.
235
+ */}
236
+ <div ref={popupContainerRef} style={{ position: 'fixed', zIndex: 100 }} />
237
+
238
+ <PopupParentContext.Provider value={popupContainerRef}>
239
+ <Dropdown>
240
+ <Dropdown.Trigger>
241
+ <Button variant="dropdown">Actions</Button>
242
+ </Dropdown.Trigger>
243
+ <Dropdown.Content>
244
+ <Dropdown.Item>View pupil profile</Dropdown.Item>
245
+ <Dropdown.Item>Edit enrolment</Dropdown.Item>
246
+ <Dropdown.Separator />
247
+ <Dropdown.Item>Remove from group</Dropdown.Item>
248
+ </Dropdown.Content>
249
+ </Dropdown>
250
+ </PopupParentContext.Provider>
251
+ </div>
252
+ );
253
+ }
254
+ export default ClippedPanel;
255
+ `.trim(),
256
+ },
257
+ },
258
+ },
259
+ }, [
260
+ 'Override the popup container with `PopupParentContext.Provider`. The `value` prop accepts a',
261
+ '`RefObject<HTMLElement | null>` pointing to the element that should receive portalled content.',
262
+ 'Open the dropdown to see it appear inside the dashed container (highlighted in pink) instead of',
263
+ '`document.body`. In production you would omit the visual indicator and size/position the container',
264
+ 'as needed for your layout.',
265
+ ].join(' '));
266
+ //# sourceMappingURL=PopupParentContext.stories.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PopupParentContext.stories.js","sourceRoot":"","sources":["../../src/utils/PopupParentContext.stories.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAE/B,OAAO,EACL,OAAO,IAAI,UAAU,EACrB,QAAQ,EACR,OAAO,EACP,QAAQ,EACR,KAAK,GACN,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAA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AAE;aACC;SACF;KACF;CACF,EACD;IACE,iEAAiE;IACjE,uGAAuG;IACvG,oGAAoG;IACpG,oCAAoC;CACrC,CAAC,IAAI,CAAC,GAAG,CAAC,CACZ,CAAC;AAEF,MAAM,CAAC,MAAM,mBAAmB,GAAU,eAAe,CACvD;IACE,MAAM,EAAE,2BAA2B;IACnC,UAAU,EAAE;QACV,QAAQ,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE;QAC3B,IAAI,EAAE;YACJ,MAAM,EAAE;gBACN,QAAQ,EAAE,KAAK;gBACf,IAAI,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAiCf,CAAC,IAAI,EAAE;aACC;SACF;KACF;CACF,EACD;IACE,6FAA6F;IAC7F,gGAAgG;IAChG,iGAAiG;IACjG,oGAAoG;IACpG,4BAA4B;CAC7B,CAAC,IAAI,CAAC,GAAG,CAAC,CACZ,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const getDefaultPopupParent: () => HTMLElement;
2
+ //# sourceMappingURL=getDefaultPopupParent.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getDefaultPopupParent.d.ts","sourceRoot":"","sources":["../../src/utils/getDefaultPopupParent.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,qBAAqB,mBAmBjC,CAAC"}
@@ -0,0 +1,19 @@
1
+ export const getDefaultPopupParent = () => {
2
+ const element = document.getElementById('ds-popup-parent');
3
+ if (element) {
4
+ return element;
5
+ }
6
+ const newContainer = document.createElement('div');
7
+ newContainer.id = 'ds-popup-parent';
8
+ newContainer.style.zIndex = '1';
9
+ newContainer.style.position = 'fixed';
10
+ // ag grid has clamping behaviour for floating elements - it clamps the area
11
+ // to whichever has the largest boundingRect between its own main container
12
+ // and whatever is passed to the popupParent prop. without this inset here
13
+ // the container ends up with a height and width of zero so they get clamped
14
+ // to the ag container instead of the viewport (most heinous).
15
+ newContainer.style.inset = '0';
16
+ document.body.appendChild(newContainer);
17
+ return newContainer;
18
+ };
19
+ //# sourceMappingURL=getDefaultPopupParent.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getDefaultPopupParent.js","sourceRoot":"","sources":["../../src/utils/getDefaultPopupParent.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,qBAAqB,GAAG,GAAG,EAAE;IACxC,MAAM,OAAO,GAAG,QAAQ,CAAC,cAAc,CAAC,iBAAiB,CAAC,CAAC;IAC3D,IAAI,OAAO,EAAE,CAAC;QACZ,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,MAAM,YAAY,GAAG,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;IACnD,YAAY,CAAC,EAAE,GAAG,iBAAiB,CAAC;IACpC,YAAY,CAAC,KAAK,CAAC,MAAM,GAAG,GAAG,CAAC;IAChC,YAAY,CAAC,KAAK,CAAC,QAAQ,GAAG,OAAO,CAAC;IACtC,4EAA4E;IAC5E,2EAA2E;IAC3E,0EAA0E;IAC1E,4EAA4E;IAC5E,8DAA8D;IAC9D,YAAY,CAAC,KAAK,CAAC,KAAK,GAAG,GAAG,CAAC;IAC/B,QAAQ,CAAC,IAAI,CAAC,WAAW,CAAC,YAAY,CAAC,CAAC;IAExC,OAAO,YAA2B,CAAC;AACrC,CAAC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"PopupParentContext.stories.d.ts","sourceRoot":"","sources":["../../../src/utils/popupParent/PopupParentContext.stories.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAQ,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAkI5D,iBAAS,0BAA0B,gCAelC;AAMD,QAAA,MAAM,IAAI;;;;;;;;;CASM,CAAC;AAEjB,eAAe,IAAI,CAAC;AACpB,KAAK,KAAK,GAAG,QAAQ,CAAC;AA4GtB,eAAO,MAAM,OAAO,EAAE,KAuCrB,CAAC;AAEF,eAAO,MAAM,mBAAmB,EAAE,KAqDjC,CAAC"}
1
+ {"version":3,"file":"PopupParentContext.stories.d.ts","sourceRoot":"","sources":["../../../src/utils/popupParent/PopupParentContext.stories.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAQ,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAkI5D,iBAAS,0BAA0B,gCAelC;AAMD,QAAA,MAAM,IAAI;;;;;;;;;CASM,CAAC;AAEjB,eAAe,IAAI,CAAC;AACpB,KAAK,KAAK,GAAG,QAAQ,CAAC;AA6GtB,eAAO,MAAM,OAAO,EAAE,KAuCrB,CAAC;AAEF,eAAO,MAAM,mBAAmB,EAAE,KAqDjC,CAAC"}
@@ -170,7 +170,7 @@ const WithCustomContainerTemplate = () => {
170
170
  borderRadius: 'var(--border-radius-small)',
171
171
  padding: 'var(--spacing-xsmall)',
172
172
  minHeight: '2rem',
173
- }, "aria-label": "Custom popup container" }), _jsx(PopupParentContext.Provider, { value: popupContainerRef, children: _jsxs(Dropdown, { children: [_jsx(Dropdown.Trigger, { children: _jsx(Button, { variant: "dropdown", children: "Actions" }) }), _jsxs(Dropdown.Content, { children: [_jsx(Dropdown.Item, { children: "View pupil profile" }), _jsx(Dropdown.Item, { children: "Edit enrolment" }), _jsx(Dropdown.Separator, {}), _jsx(Dropdown.Item, { children: "Remove from group" })] })] }) })] }));
173
+ }, "aria-label": "Custom popup container", "aria-hidden": true }), _jsx(PopupParentContext.Provider, { value: popupContainerRef, children: _jsxs(Dropdown, { children: [_jsx(Dropdown.Trigger, { children: _jsx(Button, { variant: "dropdown", children: "Actions" }) }), _jsxs(Dropdown.Content, { children: [_jsx(Dropdown.Item, { children: "View pupil profile" }), _jsx(Dropdown.Item, { children: "Edit enrolment" }), _jsx(Dropdown.Separator, {}), _jsx(Dropdown.Item, { children: "Remove from group" })] })] }) })] }));
174
174
  };
175
175
  // ---------------------------------------------------------------------------
176
176
  // Stories
@@ -1 +1 @@
1
- {"version":3,"file":"PopupParentContext.stories.js","sourceRoot":"","sources":["../../../src/utils/popupParent/PopupParentContext.stories.tsx"],"names":[],"mappings":";AAA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M,EAAE,eAAe;IACvB,UAAU,EAAE;QACV,QAAQ,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE;QAC3B,IAAI,EAAE;YACJ,MAAM,EAAE;gBACN,QAAQ,EAAE,KAAK;gBACf,IAAI,EAAE;;;;;;;;;;;;;;;;;;;;CAoBf,CAAC,IAAI,EAAE;aACC;SACF;KACF;CACF,EACD;IACE,iEAAiE;IACjE,uGAAuG;IACvG,oGAAoG;IACpG,oCAAoC;CACrC,CAAC,IAAI,CAAC,GAAG,CAAC,CACZ,CAAC;AAEF,MAAM,CAAC,MAAM,mBAAmB,GAAU,eAAe,CACvD;IACE,MAAM,EAAE,2BAA2B;IACnC,UAAU,EAAE;QACV,QAAQ,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE;QAC3B,IAAI,EAAE;YACJ,MAAM,EAAE;gBACN,QAAQ,EAAE,KAAK;gBACf,IAAI,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAiCf,CAAC,IAAI,EAAE;aACC;SACF;KACF;CACF,EACD;IACE,6FAA6F;IAC7F,gGAAgG;IAChG,iGAAiG;IACjG,oGAAoG;IACpG,4BAA4B;CAC7B,CAAC,IAAI,CAAC,GAAG,CAAC,CACZ,CAAC"}
1
+ {"version":3,"file":"PopupParentContext.stories.js","sourceRoot":"","sources":["../../../src/utils/popupParent/PopupParentContext.stories.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAE/B,OAAO,EACL,OAAO,IAAI,UAAU,EACrB,QAAQ,EACR,OAAO,EACP,QAAQ,EACR,KAAK,GACN,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,kBAAkB,EAAE,MAAM,sCAAsC,CAAC;AAC1E,OAAO,EAAE,MAAM,EAAE,MAAM,0BAA0B,CAAC;AAClD,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AAExD,8EAA8E;AAC9E,oBAAoB;AACpB,8EAA8E;AAE9E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