@scottish-government/designsystem-react 0.12.1 → 1.0.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 (490) hide show
  1. package/.storybook/main.ts +6 -6
  2. package/.storybook/sgdsArgTypes.ts +107 -43
  3. package/CHANGELOG.md +49 -0
  4. package/LICENSE.txt +21 -0
  5. package/README.md +3 -0
  6. package/dist/common/AbstractNotificationBanner/AbstractNotificationBanner.d.ts +3 -2
  7. package/dist/common/AbstractNotificationBanner/AbstractNotificationBanner.jsx +8 -7
  8. package/dist/common/AbstractNotificationBanner/types.d.ts +13 -0
  9. package/dist/common/AbstractNotificationBanner/types.js +2 -0
  10. package/dist/common/ActionLink/ActionLink.d.ts +2 -1
  11. package/dist/common/ActionLink/types.d.ts +7 -0
  12. package/dist/common/ActionLink/types.js +2 -0
  13. package/dist/common/ConditionalWrapper/ConditionalWrapper.d.ts +2 -1
  14. package/dist/common/ConditionalWrapper/ConditionalWrapper.jsx +4 -2
  15. package/dist/common/ConditionalWrapper/types.d.ts +4 -0
  16. package/dist/common/ConditionalWrapper/types.js +2 -0
  17. package/dist/common/FileIcon/FileIcon.d.ts +2 -1
  18. package/dist/common/FileIcon/types.d.ts +6 -0
  19. package/dist/common/FileIcon/types.js +2 -0
  20. package/dist/common/HintText/HintText.d.ts +2 -1
  21. package/dist/common/HintText/HintText.jsx +3 -3
  22. package/dist/common/HintText/types.d.ts +4 -0
  23. package/dist/common/HintText/types.js +2 -0
  24. package/dist/common/Icon/Icon.d.ts +2 -1
  25. package/dist/common/Icon/Icon.jsx +3 -2
  26. package/dist/common/Icon/types.d.ts +8 -0
  27. package/dist/common/Icon/types.js +2 -0
  28. package/dist/common/ScreenReaderText/ScreenReaderText.d.ts +1 -1
  29. package/dist/common/WrapperTag/WrapperTag.d.ts +385 -1
  30. package/dist/common/WrapperTag/WrapperTag.jsx +5 -2
  31. package/dist/common/WrapperTag/types.d.ts +3 -0
  32. package/dist/common/WrapperTag/types.js +2 -0
  33. package/dist/components/Accordion/Accordion.d.ts +3 -2
  34. package/dist/components/Accordion/Accordion.jsx +12 -11
  35. package/dist/components/Accordion/types.d.ts +11 -0
  36. package/dist/components/Accordion/types.js +2 -0
  37. package/dist/components/AspectBox/AspectBox.d.ts +2 -1
  38. package/dist/components/AspectBox/AspectBox.jsx +3 -9
  39. package/dist/components/AspectBox/types.d.ts +3 -0
  40. package/dist/components/AspectBox/types.js +2 -0
  41. package/dist/components/BackToTop/BackToTop.d.ts +2 -1
  42. package/dist/components/BackToTop/BackToTop.jsx +4 -3
  43. package/dist/components/BackToTop/types.d.ts +3 -0
  44. package/dist/components/BackToTop/types.js +2 -0
  45. package/dist/components/Breadcrumbs/Breadcrumbs.d.ts +3 -2
  46. package/dist/components/Breadcrumbs/Breadcrumbs.jsx +6 -2
  47. package/dist/components/Breadcrumbs/types.d.ts +5 -0
  48. package/dist/components/Breadcrumbs/types.js +2 -0
  49. package/dist/components/Button/Button.d.ts +2 -1
  50. package/dist/components/Button/Button.jsx +4 -3
  51. package/dist/components/Button/ButtonGroup.d.ts +2 -1
  52. package/dist/components/Button/ButtonGroup.jsx +9 -4
  53. package/dist/components/Button/types.d.ts +20 -0
  54. package/dist/components/Button/types.js +2 -0
  55. package/dist/components/Card/Card.d.ts +34 -0
  56. package/dist/components/Card/Card.jsx +118 -0
  57. package/dist/components/Card/index.d.ts +1 -0
  58. package/dist/components/Card/index.js +8 -0
  59. package/dist/components/Card/types.d.ts +26 -0
  60. package/dist/components/Card/types.js +2 -0
  61. package/dist/components/CategoryItem/CategoryItem.d.ts +2 -1
  62. package/dist/components/CategoryItem/CategoryItem.jsx +8 -5
  63. package/dist/components/CategoryItem/types.d.ts +9 -0
  64. package/dist/components/CategoryItem/types.js +2 -0
  65. package/dist/components/CategoryList/CategoryList.d.ts +2 -1
  66. package/dist/components/CategoryList/CategoryList.jsx +3 -2
  67. package/dist/components/CategoryList/types.d.ts +5 -0
  68. package/dist/components/CategoryList/types.js +2 -0
  69. package/dist/components/Checkbox/Checkbox.d.ts +2 -1
  70. package/dist/components/Checkbox/Checkbox.jsx +4 -3
  71. package/dist/components/Checkbox/CheckboxGroup.d.ts +2 -1
  72. package/dist/components/Checkbox/CheckboxGroup.jsx +5 -4
  73. package/dist/components/Checkbox/types.d.ts +7 -0
  74. package/dist/components/Checkbox/types.js +2 -0
  75. package/dist/components/ConfirmationMessage/ConfirmationMessage.d.ts +2 -1
  76. package/dist/components/ConfirmationMessage/ConfirmationMessage.jsx +3 -2
  77. package/dist/components/ConfirmationMessage/types.d.ts +6 -0
  78. package/dist/components/ConfirmationMessage/types.js +2 -0
  79. package/dist/components/ContentsNav/ContentsNav.d.ts +3 -2
  80. package/dist/components/ContentsNav/ContentsNav.jsx +7 -5
  81. package/dist/components/ContentsNav/types.d.ts +9 -0
  82. package/dist/components/ContentsNav/types.js +2 -0
  83. package/dist/components/CookieBanner/CookieBanner.d.ts +3 -2
  84. package/dist/components/CookieBanner/CookieBanner.jsx +13 -3
  85. package/dist/components/DatePicker/DatePicker.d.ts +2 -1
  86. package/dist/components/DatePicker/DatePicker.jsx +7 -7
  87. package/dist/components/DatePicker/types.d.ts +18 -0
  88. package/dist/components/DatePicker/types.js +2 -0
  89. package/dist/components/Details/Details.d.ts +2 -1
  90. package/dist/components/Details/Details.jsx +6 -2
  91. package/dist/components/Details/types.d.ts +4 -0
  92. package/dist/components/Details/types.js +2 -0
  93. package/dist/components/ErrorMessage/ErrorMessage.d.ts +2 -1
  94. package/dist/components/ErrorMessage/ErrorMessage.jsx +6 -2
  95. package/dist/components/ErrorMessage/types.d.ts +3 -0
  96. package/dist/components/ErrorMessage/types.js +2 -0
  97. package/dist/components/ErrorSummary/ErrorSummary.d.ts +3 -2
  98. package/dist/components/ErrorSummary/ErrorSummary.jsx +6 -2
  99. package/dist/components/ErrorSummary/types.d.ts +8 -0
  100. package/dist/components/ErrorSummary/types.js +2 -0
  101. package/dist/components/FeatureHeader/FeatureHeader.d.ts +7 -5
  102. package/dist/components/FeatureHeader/FeatureHeader.jsx +87 -50
  103. package/dist/components/FeatureHeader/types.d.ts +12 -0
  104. package/dist/components/FeatureHeader/types.js +2 -0
  105. package/dist/components/FileDownload/FileDownload.d.ts +2 -1
  106. package/dist/components/FileDownload/FileDownload.jsx +4 -3
  107. package/dist/components/FileDownload/types.d.ts +10 -0
  108. package/dist/components/FileDownload/types.js +2 -0
  109. package/dist/components/HideThisPage/HideThisPage.d.ts +2 -1
  110. package/dist/components/HideThisPage/HideThisPage.jsx +5 -4
  111. package/dist/components/HideThisPage/types.d.ts +3 -0
  112. package/dist/components/HideThisPage/types.js +2 -0
  113. package/dist/components/InsetText/InsetText.d.ts +1 -1
  114. package/dist/components/InsetText/InsetText.jsx +6 -2
  115. package/dist/components/NotificationBanner/NotificationBanner.d.ts +3 -2
  116. package/dist/components/NotificationBanner/NotificationBanner.jsx +5 -4
  117. package/dist/components/NotificationPanel/NotificationPanel.d.ts +2 -1
  118. package/dist/components/NotificationPanel/NotificationPanel.jsx +3 -2
  119. package/dist/components/NotificationPanel/types.d.ts +6 -0
  120. package/dist/components/NotificationPanel/types.js +2 -0
  121. package/dist/components/NotificationTag/NotificationTag.d.ts +6 -0
  122. package/dist/components/NotificationTag/NotificationTag.jsx +20 -0
  123. package/dist/components/NotificationTag/index.d.ts +1 -0
  124. package/dist/components/NotificationTag/index.js +8 -0
  125. package/dist/components/NotificationTag/types.d.ts +5 -0
  126. package/dist/components/NotificationTag/types.js +2 -0
  127. package/dist/components/PageHeader/PageHeader.d.ts +2 -1
  128. package/dist/components/PageHeader/PageHeader.jsx +6 -2
  129. package/dist/components/PageHeader/types.d.ts +5 -0
  130. package/dist/components/PageHeader/types.js +2 -0
  131. package/dist/components/PageMetadata/PageMetadata.d.ts +3 -2
  132. package/dist/components/PageMetadata/PageMetadata.jsx +8 -4
  133. package/dist/components/PageMetadata/types.d.ts +6 -0
  134. package/dist/components/PageMetadata/types.js +2 -0
  135. package/dist/components/Pagination/Pagination.d.ts +3 -2
  136. package/dist/components/Pagination/Pagination.jsx +7 -5
  137. package/dist/components/Pagination/types.d.ts +18 -0
  138. package/dist/components/Pagination/types.js +2 -0
  139. package/dist/components/PhaseBanner/PhaseBanner.d.ts +2 -1
  140. package/dist/components/PhaseBanner/PhaseBanner.jsx +3 -2
  141. package/dist/components/PhaseBanner/types.d.ts +3 -0
  142. package/dist/components/PhaseBanner/types.js +2 -0
  143. package/dist/components/Question/Question.d.ts +2 -1
  144. package/dist/components/Question/Question.jsx +4 -3
  145. package/dist/components/Question/types.d.ts +9 -0
  146. package/dist/components/Question/types.js +2 -0
  147. package/dist/components/RadioButton/RadioButton.d.ts +2 -1
  148. package/dist/components/RadioButton/RadioButton.jsx +4 -3
  149. package/dist/components/RadioButton/RadioGroup.d.ts +2 -1
  150. package/dist/components/RadioButton/RadioGroup.jsx +3 -2
  151. package/dist/components/RadioButton/types.d.ts +10 -0
  152. package/dist/components/RadioButton/types.js +2 -0
  153. package/dist/components/SearchFacets/SearchFacets.d.ts +4 -3
  154. package/dist/components/SearchFacets/SearchFacets.jsx +3 -2
  155. package/dist/components/SearchFacets/types.d.ts +12 -0
  156. package/dist/components/SearchFacets/types.js +2 -0
  157. package/dist/components/SearchFilters/SearchFilters.d.ts +5 -4
  158. package/dist/components/SearchFilters/types.d.ts +12 -0
  159. package/dist/components/SearchFilters/types.js +2 -0
  160. package/dist/components/SearchResult/SearchResult.d.ts +8 -11
  161. package/dist/components/SearchResult/SearchResult.jsx +6 -7
  162. package/dist/components/SearchResult/types.d.ts +11 -0
  163. package/dist/components/SearchResult/types.js +2 -0
  164. package/dist/components/SearchSort/SearchSort.d.ts +2 -1
  165. package/dist/components/SearchSort/SearchSort.jsx +3 -2
  166. package/dist/components/SearchSort/types.d.ts +7 -0
  167. package/dist/components/SearchSort/types.js +2 -0
  168. package/dist/components/Select/Select.d.ts +2 -1
  169. package/dist/components/Select/Select.jsx +4 -3
  170. package/dist/components/Select/types.d.ts +6 -0
  171. package/dist/components/Select/types.js +2 -0
  172. package/dist/components/SequentialNavigation/SequentialNavigation.d.ts +4 -3
  173. package/dist/components/SequentialNavigation/SequentialNavigation.jsx +10 -6
  174. package/dist/components/SequentialNavigation/types.d.ts +10 -0
  175. package/dist/components/SequentialNavigation/types.js +2 -0
  176. package/dist/components/SideNavigation/SideNavigation.d.ts +4 -3
  177. package/dist/components/SideNavigation/SideNavigation.jsx +10 -7
  178. package/dist/components/SideNavigation/types.d.ts +13 -0
  179. package/dist/components/SideNavigation/types.js +2 -0
  180. package/dist/components/SiteFooter/SiteFooter.d.ts +6 -5
  181. package/dist/components/SiteFooter/SiteFooter.jsx +4 -3
  182. package/dist/components/SiteFooter/types.d.ts +16 -0
  183. package/dist/components/SiteFooter/types.js +2 -0
  184. package/dist/components/SiteHeader/SiteHeader.d.ts +6 -5
  185. package/dist/components/SiteHeader/SiteHeader.jsx +1 -1
  186. package/dist/components/SiteHeader/types.d.ts +20 -0
  187. package/dist/components/SiteHeader/types.js +2 -0
  188. package/dist/components/SiteNavigation/SiteNavigation.d.ts +3 -2
  189. package/dist/components/SiteNavigation/SiteNavigation.jsx +12 -4
  190. package/dist/components/SiteNavigation/types.d.ts +9 -0
  191. package/dist/components/SiteNavigation/types.js +2 -0
  192. package/dist/components/SiteSearch/SiteSearch.d.ts +2 -1
  193. package/dist/components/SiteSearch/SiteSearch.jsx +12 -11
  194. package/dist/components/SiteSearch/types.d.ts +17 -0
  195. package/dist/components/SiteSearch/types.js +2 -0
  196. package/dist/components/SkipLinks/SkipLinks.d.ts +3 -2
  197. package/dist/components/SkipLinks/SkipLinks.jsx +4 -4
  198. package/dist/components/SkipLinks/types.d.ts +8 -0
  199. package/dist/components/SkipLinks/types.js +2 -0
  200. package/dist/components/SummaryCard/SummaryCard.d.ts +4 -2
  201. package/dist/components/SummaryCard/SummaryCard.jsx +5 -4
  202. package/dist/components/SummaryCard/types.d.ts +5 -0
  203. package/dist/components/SummaryCard/types.js +2 -0
  204. package/dist/components/SummaryList/SummaryList.d.ts +6 -4
  205. package/dist/components/SummaryList/SummaryList.jsx +5 -4
  206. package/dist/components/SummaryList/types.d.ts +6 -0
  207. package/dist/components/SummaryList/types.js +2 -0
  208. package/dist/components/Table/Table.d.ts +2 -1
  209. package/dist/components/Table/Table.jsx +5 -4
  210. package/dist/components/Table/types.d.ts +6 -0
  211. package/dist/components/Table/types.js +2 -0
  212. package/dist/components/Tabs/Tabs.d.ts +3 -2
  213. package/dist/components/Tabs/Tabs.jsx +6 -5
  214. package/dist/components/Tabs/types.d.ts +16 -0
  215. package/dist/components/Tabs/types.js +2 -0
  216. package/dist/components/Tag/Tag.d.ts +2 -1
  217. package/dist/components/Tag/Tag.jsx +7 -3
  218. package/dist/components/Tag/types.d.ts +4 -0
  219. package/dist/components/Tag/types.js +2 -0
  220. package/dist/components/TaskList/TaskList.d.ts +4 -3
  221. package/dist/components/TaskList/TaskList.jsx +11 -8
  222. package/dist/components/TaskList/types.d.ts +17 -0
  223. package/dist/components/TaskList/types.js +2 -0
  224. package/dist/components/TextInput/TextInput.d.ts +2 -1
  225. package/dist/components/TextInput/TextInput.jsx +10 -9
  226. package/dist/components/TextInput/types.d.ts +11 -0
  227. package/dist/components/TextInput/types.js +2 -0
  228. package/dist/components/Textarea/Textarea.d.ts +2 -1
  229. package/dist/components/Textarea/Textarea.jsx +6 -5
  230. package/dist/components/WarningText/WarningText.d.ts +1 -1
  231. package/dist/components/WarningText/WarningText.jsx +6 -2
  232. package/dist/hooks/useTracking/useTracking.js +0 -1
  233. package/eslint.config.mjs +32 -0
  234. package/package.json +12 -5
  235. package/src/common/AbstractNotificationBanner/AbstractNotificationBanner.tsx +13 -10
  236. package/src/common/AbstractNotificationBanner/types.ts +15 -0
  237. package/src/common/ActionLink/ActionLink.tsx +3 -1
  238. package/src/common/ActionLink/types.ts +8 -0
  239. package/src/common/ConditionalWrapper/ConditionalWrapper.tsx +10 -2
  240. package/src/common/ConditionalWrapper/types.ts +4 -0
  241. package/src/common/FileIcon/FileIcon.tsx +2 -1
  242. package/src/common/FileIcon/types.ts +7 -0
  243. package/src/common/HintText/HintText.test.tsx +3 -15
  244. package/src/common/HintText/HintText.tsx +4 -4
  245. package/src/common/HintText/types.ts +4 -0
  246. package/src/common/Icon/Icon.tsx +5 -3
  247. package/src/common/Icon/types.ts +9 -0
  248. package/src/common/ScreenReaderText/ScreenReaderText.tsx +1 -1
  249. package/src/common/WrapperTag/WrapperTag.tsx +5 -3
  250. package/src/common/WrapperTag/types.ts +3 -0
  251. package/src/components/Accordion/Accordion.Item.stories.tsx +1 -5
  252. package/src/components/Accordion/Accordion.stories.tsx +5 -5
  253. package/src/components/Accordion/Accordion.test.tsx +11 -0
  254. package/src/components/Accordion/Accordion.tsx +15 -13
  255. package/src/components/Accordion/types.ts +13 -0
  256. package/src/components/AspectBox/AspectBox.stories.tsx +1 -2
  257. package/src/components/AspectBox/AspectBox.tsx +8 -14
  258. package/src/components/AspectBox/types.ts +3 -0
  259. package/src/components/BackToTop/BackToTop.test.tsx +21 -1
  260. package/src/components/BackToTop/BackToTop.tsx +6 -4
  261. package/src/components/BackToTop/types.ts +3 -0
  262. package/src/components/Breadcrumbs/Breadcrumbs.tsx +7 -4
  263. package/src/components/Breadcrumbs/types.ts +6 -0
  264. package/src/components/Button/Button.tsx +6 -4
  265. package/src/components/Button/ButtonGroup.stories.tsx +22 -0
  266. package/src/components/Button/ButtonGroup.test.tsx +21 -0
  267. package/src/components/Button/ButtonGroup.tsx +9 -4
  268. package/src/components/Button/types.ts +22 -0
  269. package/src/components/Card/Card.stories.tsx +446 -0
  270. package/src/components/Card/Card.test.tsx +282 -0
  271. package/src/components/Card/Card.tsx +208 -0
  272. package/src/components/Card/index.ts +1 -0
  273. package/src/components/Card/types.ts +30 -0
  274. package/src/components/CategoryItem/CategoryItem.tsx +10 -6
  275. package/src/components/CategoryItem/types.ts +10 -0
  276. package/src/components/CategoryList/CategoryList.tsx +7 -4
  277. package/src/components/CategoryList/types.ts +5 -0
  278. package/src/components/Checkbox/Checkbox.stories.tsx +3 -3
  279. package/src/components/Checkbox/Checkbox.test.tsx +30 -0
  280. package/src/components/Checkbox/Checkbox.tsx +8 -7
  281. package/src/components/Checkbox/CheckboxGroup.test.tsx +10 -0
  282. package/src/components/Checkbox/CheckboxGroup.tsx +7 -6
  283. package/src/components/Checkbox/types.ts +9 -0
  284. package/src/components/ConfirmationMessage/ConfirmationMessage.tsx +5 -3
  285. package/src/components/ConfirmationMessage/types.ts +7 -0
  286. package/src/components/ContentsNav/ContentsNav.stories.tsx +5 -1
  287. package/src/components/ContentsNav/ContentsNav.tsx +11 -7
  288. package/src/components/ContentsNav/types.ts +11 -0
  289. package/src/components/CookieBanner/CookieBanner.Buttons.stories.tsx +3 -3
  290. package/src/components/CookieBanner/CookieBanner.stories.tsx +6 -6
  291. package/src/components/CookieBanner/CookieBanner.test.tsx +24 -1
  292. package/src/components/CookieBanner/CookieBanner.tsx +16 -5
  293. package/src/components/DatePicker/DatePicker.test.tsx +52 -19
  294. package/src/components/DatePicker/DatePicker.tsx +8 -8
  295. package/src/components/DatePicker/types.ts +19 -0
  296. package/src/components/Details/Details.stories.tsx +1 -1
  297. package/src/components/Details/Details.tsx +6 -3
  298. package/src/components/Details/types.ts +4 -0
  299. package/src/components/ErrorMessage/ErrorMessage.tsx +6 -3
  300. package/src/components/ErrorMessage/types.ts +3 -0
  301. package/src/components/ErrorSummary/ErrorSummary.test.tsx +1 -1
  302. package/src/components/ErrorSummary/ErrorSummary.tsx +6 -4
  303. package/src/components/ErrorSummary/types.ts +11 -0
  304. package/src/components/FeatureHeader/FeatureHeader.stories.tsx +186 -23
  305. package/src/components/FeatureHeader/FeatureHeader.test.tsx +298 -0
  306. package/src/components/FeatureHeader/FeatureHeader.tsx +83 -58
  307. package/src/components/FeatureHeader/types.ts +13 -0
  308. package/src/components/FileDownload/FileDownload.test.tsx +1 -5
  309. package/src/components/FileDownload/FileDownload.tsx +6 -4
  310. package/src/components/FileDownload/types.ts +11 -0
  311. package/src/components/HideThisPage/HideThisPage.test.tsx +12 -1
  312. package/src/components/HideThisPage/HideThisPage.tsx +7 -5
  313. package/src/components/HideThisPage/types.ts +3 -0
  314. package/src/components/InsetText/InsetText.tsx +5 -3
  315. package/src/components/NotificationBanner/NotificationBanner.stories.tsx +2 -2
  316. package/src/components/NotificationBanner/NotificationBanner.test.tsx +10 -0
  317. package/src/components/NotificationBanner/NotificationBanner.tsx +8 -6
  318. package/src/components/NotificationPanel/NotificationPanel.tsx +5 -3
  319. package/src/components/NotificationPanel/types.ts +7 -0
  320. package/src/components/NotificationTag/NotificationTag.stories.tsx +68 -0
  321. package/src/components/NotificationTag/NotificationTag.test.tsx +70 -0
  322. package/src/components/NotificationTag/NotificationTag.tsx +32 -0
  323. package/src/components/NotificationTag/index.ts +1 -0
  324. package/src/components/NotificationTag/types.ts +5 -0
  325. package/src/components/PageHeader/PageHeader.tsx +6 -3
  326. package/src/components/PageHeader/types.ts +5 -0
  327. package/src/components/PageMetadata/PageMetadata.stories.tsx +1 -1
  328. package/src/components/PageMetadata/PageMetadata.tsx +10 -7
  329. package/src/components/PageMetadata/types.ts +7 -0
  330. package/src/components/Pagination/Pagination.test.tsx +20 -0
  331. package/src/components/Pagination/Pagination.tsx +12 -8
  332. package/src/components/Pagination/types.ts +20 -0
  333. package/src/components/PhaseBanner/PhaseBanner.stories.tsx +1 -4
  334. package/src/components/PhaseBanner/PhaseBanner.tsx +5 -3
  335. package/src/components/PhaseBanner/types.ts +3 -0
  336. package/src/components/Question/Question.tsx +6 -4
  337. package/src/components/Question/types.ts +9 -0
  338. package/src/components/RadioButton/RadioButton.test.tsx +30 -0
  339. package/src/components/RadioButton/RadioButton.tsx +8 -7
  340. package/src/components/RadioButton/RadioGroup.tsx +5 -3
  341. package/src/components/RadioButton/types.ts +12 -0
  342. package/src/components/SearchFacets/SearchFacets.Group.stories.tsx +2 -3
  343. package/src/components/SearchFacets/SearchFacets.stories.tsx +2 -2
  344. package/src/components/SearchFacets/SearchFacets.tsx +10 -8
  345. package/src/components/SearchFacets/types.ts +14 -0
  346. package/src/components/SearchFilters/SearchFilters.Panel.stories.tsx +18 -7
  347. package/src/components/SearchFilters/SearchFilters.stories.tsx +1 -1
  348. package/src/components/SearchFilters/SearchFilters.tsx +4 -3
  349. package/src/components/SearchFilters/types.ts +14 -0
  350. package/src/components/SearchResult/SearchResult.stories.tsx +23 -23
  351. package/src/components/SearchResult/SearchResult.test.tsx +5 -4
  352. package/src/components/SearchResult/SearchResult.tsx +15 -15
  353. package/src/components/SearchResult/types.ts +13 -0
  354. package/src/components/SearchSort/SearchSort.stories.tsx +2 -1
  355. package/src/components/SearchSort/SearchSort.tsx +5 -3
  356. package/src/components/SearchSort/types.ts +7 -0
  357. package/src/components/Select/Select.test.tsx +42 -0
  358. package/src/components/Select/Select.tsx +8 -6
  359. package/src/components/Select/types.ts +7 -0
  360. package/src/components/SequentialNavigation/SequentialNavigation.tsx +13 -10
  361. package/src/components/SequentialNavigation/types.ts +12 -0
  362. package/src/components/SideNavigation/SideNavigation.test.tsx +24 -0
  363. package/src/components/SideNavigation/SideNavigation.tsx +14 -10
  364. package/src/components/SideNavigation/types.ts +16 -0
  365. package/src/components/SiteFooter/SiteFooter.tsx +10 -8
  366. package/src/components/SiteFooter/types.ts +20 -0
  367. package/src/components/SiteHeader/SiteHeader.stories.tsx +4 -3
  368. package/src/components/SiteHeader/SiteHeader.test.tsx +29 -16
  369. package/src/components/SiteHeader/SiteHeader.tsx +10 -9
  370. package/src/components/SiteHeader/types.ts +22 -0
  371. package/src/components/SiteNavigation/SiteNavigation.test.tsx +16 -1
  372. package/src/components/SiteNavigation/SiteNavigation.tsx +13 -6
  373. package/src/components/SiteNavigation/types.ts +11 -0
  374. package/src/components/SiteSearch/SiteSearch.stories.tsx +4 -2
  375. package/src/components/SiteSearch/SiteSearch.test.tsx +22 -0
  376. package/src/components/SiteSearch/SiteSearch.tsx +15 -13
  377. package/src/components/SiteSearch/types.ts +19 -0
  378. package/src/components/SkipLinks/SkipLinks.stories.tsx +3 -3
  379. package/src/components/SkipLinks/SkipLinks.tsx +7 -7
  380. package/src/components/SkipLinks/types.ts +9 -0
  381. package/src/components/SummaryCard/SummaryCard.test.tsx +0 -11
  382. package/src/components/SummaryCard/SummaryCard.tsx +9 -6
  383. package/src/components/SummaryCard/types.ts +6 -0
  384. package/src/components/SummaryList/SummaryList.Item.stories.tsx +5 -5
  385. package/src/components/SummaryList/SummaryList.stories.tsx +1 -1
  386. package/src/components/SummaryList/SummaryList.test.tsx +1 -6
  387. package/src/components/SummaryList/SummaryList.tsx +11 -9
  388. package/src/components/SummaryList/types.ts +7 -0
  389. package/src/components/Table/Table.test.tsx +36 -0
  390. package/src/components/Table/Table.tsx +7 -5
  391. package/src/components/Table/types.ts +6 -0
  392. package/src/components/Tabs/Tabs.Item.stories.tsx +7 -7
  393. package/src/components/Tabs/Tabs.stories.tsx +3 -3
  394. package/src/components/Tabs/Tabs.test.tsx +14 -0
  395. package/src/components/Tabs/Tabs.tsx +12 -9
  396. package/src/components/Tabs/types.ts +19 -0
  397. package/src/components/Tag/Tag.tsx +7 -4
  398. package/src/components/Tag/types.ts +5 -0
  399. package/src/components/TaskList/TaskList.Group.stories.tsx +0 -5
  400. package/src/components/TaskList/TaskList.stories.tsx +0 -1
  401. package/src/components/TaskList/TaskList.tsx +17 -13
  402. package/src/components/TaskList/types.ts +20 -0
  403. package/src/components/TextInput/TextInput.test.tsx +53 -1
  404. package/src/components/TextInput/TextInput.tsx +17 -12
  405. package/src/components/TextInput/types.ts +12 -0
  406. package/src/components/Textarea/Textarea.test.tsx +53 -1
  407. package/src/components/Textarea/Textarea.tsx +10 -8
  408. package/src/components/WarningText/WarningText.tsx +5 -3
  409. package/src/hooks/useTracking/useTracking.test.tsx +5 -7
  410. package/src/hooks/useTracking/useTracking.ts +0 -1
  411. package/src/images/icons/arrow_upward.tsx +10 -10
  412. package/src/images/icons/calendar_today.tsx +10 -10
  413. package/src/images/icons/cancel.tsx +8 -8
  414. package/src/images/icons/check_circle.tsx +10 -10
  415. package/src/images/icons/chevron_left.tsx +10 -10
  416. package/src/images/icons/chevron_right.tsx +10 -10
  417. package/src/images/icons/close.tsx +10 -10
  418. package/src/images/icons/description.tsx +10 -10
  419. package/src/images/icons/double_chevron_left.tsx +8 -8
  420. package/src/images/icons/double_chevron_right.tsx +8 -8
  421. package/src/images/icons/error.tsx +10 -10
  422. package/src/images/icons/expand_less.tsx +10 -10
  423. package/src/images/icons/expand_more.tsx +10 -10
  424. package/src/images/icons/list.tsx +13 -13
  425. package/src/images/icons/menu.tsx +10 -10
  426. package/src/images/icons/priority_high.tsx +11 -11
  427. package/src/images/icons/search.tsx +10 -10
  428. package/src/shared-types.ts +40 -0
  429. package/static/images/illustration.svg +502 -0
  430. package/tsconfig.json +0 -3
  431. package/vite.config.ts +6 -1
  432. package/@types/common/AbstractNotificationBanner.d.ts +0 -17
  433. package/@types/common/ActionLink.d.ts +0 -8
  434. package/@types/common/ConditionalWrapper.d.ts +0 -6
  435. package/@types/common/FileIcon.d.ts +0 -7
  436. package/@types/common/HintText.d.ts +0 -6
  437. package/@types/common/Icon.d.ts +0 -9
  438. package/@types/common/ScreenReaderText.d.ts +0 -4
  439. package/@types/common/WrapperTag.d.ts +0 -5
  440. package/@types/components/Accordion.d.ts +0 -15
  441. package/@types/components/AspectBox.d.ts +0 -5
  442. package/@types/components/BackToTop.d.ts +0 -5
  443. package/@types/components/Breadcrumbs.d.ts +0 -11
  444. package/@types/components/Button.d.ts +0 -17
  445. package/@types/components/ButtonGroup.d.ts +0 -5
  446. package/@types/components/CategoryItem.d.ts +0 -10
  447. package/@types/components/CategoryList.d.ts +0 -7
  448. package/@types/components/Checkbox.d.ts +0 -11
  449. package/@types/components/ConfirmationMessage.d.ts +0 -7
  450. package/@types/components/ContentsNav.d.ts +0 -13
  451. package/@types/components/DatePicker.d.ts +0 -20
  452. package/@types/components/Details.d.ts +0 -6
  453. package/@types/components/ErrorMessage.d.ts +0 -5
  454. package/@types/components/ErrorSummary.d.ts +0 -12
  455. package/@types/components/FileDownload.d.ts +0 -11
  456. package/@types/components/HideThisPage.d.ts +0 -5
  457. package/@types/components/InsetText.d.ts +0 -5
  458. package/@types/components/Metadata.d.ts +0 -11
  459. package/@types/components/NotificationPanel.d.ts +0 -7
  460. package/@types/components/PageHeader.d.ts +0 -7
  461. package/@types/components/Pagination.d.ts +0 -22
  462. package/@types/components/PhaseBanner.d.ts +0 -5
  463. package/@types/components/Question.d.ts +0 -11
  464. package/@types/components/RadioButton.d.ts +0 -14
  465. package/@types/components/SearchFacets.d.ts +0 -18
  466. package/@types/components/SearchFilters.d.ts +0 -14
  467. package/@types/components/SearchResult.d.ts +0 -30
  468. package/@types/components/SearchSort.d.ts +0 -9
  469. package/@types/components/Select.d.ts +0 -7
  470. package/@types/components/SequentialNavigation.d.ts +0 -14
  471. package/@types/components/SideNavigation.d.ts +0 -18
  472. package/@types/components/SiteFooter.d.ts +0 -25
  473. package/@types/components/SiteHeader.d.ts +0 -20
  474. package/@types/components/SiteNavigation.d.ts +0 -13
  475. package/@types/components/SiteSearch.d.ts +0 -14
  476. package/@types/components/SkipLinks.d.ts +0 -13
  477. package/@types/components/SummaryCard.d.ts +0 -6
  478. package/@types/components/SummaryList.d.ts +0 -14
  479. package/@types/components/Table.d.ts +0 -8
  480. package/@types/components/Tabs.d.ts +0 -21
  481. package/@types/components/Tag.d.ts +0 -5
  482. package/@types/components/TaskList.d.ts +0 -22
  483. package/@types/components/TextInput.d.ts +0 -12
  484. package/@types/components/Textarea.d.ts +0 -4
  485. package/@types/components/WarningText.d.ts +0 -5
  486. package/@types/global.d.ts +0 -1
  487. package/@types/sgds.d.ts +0 -49
  488. package/dist/index.d.ts +0 -4
  489. package/dist/index.js +0 -40
  490. package/dist/tsconfig.tsbuildinfo +0 -1
@@ -1,15 +1,15 @@
1
1
  import * as React from "react";
2
2
  import type { SVGProps } from "react";
3
3
  const SvgSearch = (props: SVGProps<SVGSVGElement>) => (
4
- <svg
5
- xmlns="http://www.w3.org/2000/svg"
6
- viewBox="0 0 24 24"
7
- fill="#000000"
8
- role="img"
9
- {...props}
10
- >
11
- <path d="M0 0h24v24H0z" fill="none" />
12
- <path d="M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z" />
13
- </svg>
4
+ <svg
5
+ xmlns="http://www.w3.org/2000/svg"
6
+ viewBox="0 0 24 24"
7
+ fill="#000000"
8
+ role="img"
9
+ {...props}
10
+ >
11
+ <path d="M0 0h24v24H0z" fill="none" />
12
+ <path d="M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z" />
13
+ </svg>
14
14
  );
15
15
  export default SvgSearch;
@@ -0,0 +1,40 @@
1
+ export type HeadingLevel = 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6';
2
+ export type IconName = 'ArrowUpward' | 'CalendarToday' | 'Cancel' | 'CheckCircle' | 'ChevronLeft' | 'ChevronRight' | 'Close' | 'Description' | 'DoubleChevronLeft' | 'DoubleChevronRight' | 'Error' | 'ExpandLess' | 'ExpandMore' | 'List' | 'Menu' | 'PriorityHigh' | 'Search';
3
+ export type DocumentIconName = 'Audio' | 'Csv' | 'Excel' | 'File' | 'Generic' | 'Geodata' | 'Ical' | 'Ico' | 'Image' | 'Odf' | 'Odg' | 'Odp' | 'Ods' | 'Odt' | 'Pdf' | 'Ppt' | 'Rtf' | 'Text' | 'Video' | 'Word' | 'Xml' | 'Zip';
4
+ export type InputWidth = 'fixed-20' | 'fixed-10' | 'fixed-5' | 'fixed-4' | 'fixed-3' | 'fixed-2' | 'fluid-three-quarters' | 'fluid-two-thirds' | 'fluid-half' | 'fluid-one-third' | 'fluid-one-quarter';
5
+ export type TagColour = 'grey' | 'green' | 'teal' | 'blue' | 'purple' | 'pink' | 'red' | 'orange' | 'yellow';
6
+ export type TextInputType = 'date' | 'datetime-local' | 'email' | 'month' | 'number' | 'password' | 'search' | 'tel' | 'text' | 'time' | 'url' | 'week';
7
+
8
+ export type LinkComponentProps = {
9
+ 'aria-label'?: React.AriaAttributes['aria-label'];
10
+ 'aria-current'?: React.AriaAttributes['aria-current'];
11
+ 'aria-describedby'?: React.AriaAttributes['aria-describedby'];
12
+ children?: React.ReactNode;
13
+ className?: string;
14
+ href?: string;
15
+ onClick?: React.EventHandler<React.MouseEvent>;
16
+ }
17
+
18
+ export type LinkComponent = (linkComponent: LinkComponentProps) => React.ReactNode;
19
+
20
+ export interface CheckboxRadioBase<T> extends React.InputHTMLAttributes<T> {
21
+ hintText?: string | React.ReactNode;
22
+ label: string;
23
+ onBlur?: React.FocusEventHandler<T>;
24
+ onChange?: React.ChangeEventHandler<T>;
25
+ isSmall?: boolean;
26
+ }
27
+
28
+ export interface FormFieldBase<T> extends React.AllHTMLAttributes <T> {
29
+ errorMessage?: string | React.ReactNode;
30
+ hasError?: boolean;
31
+ hintText?: string | React.ReactNode;
32
+ label: string;
33
+ onBlur?: React.FocusEventHandler<T>;
34
+ onChange?: React.ChangeEventHandler<T>;
35
+ }
36
+
37
+ export interface TextInputBase<T> extends FormFieldBase<T> {
38
+ countThreshold?: number;
39
+ maxlength?: number;
40
+ }
@@ -0,0 +1,502 @@
1
+ <?xml version="1.0" encoding="UTF-8" standalone="no"?>
2
+ <svg xmlns="http://www.w3.org/2000/svg" id="Final" viewBox="0 0 352 264">
3
+
4
+ <defs>
5
+
6
+ <style>.cls-1{fill:#00437e;}.cls-2,.cls-3{fill:#002d54;}.cls-4{fill:#0065bd;}.cls-5{fill:#0065bc;}.cls-6{fill:#ebebeb;}.cls-7{fill:#fff;}.cls-8{fill:#fdd522;}.cls-9{fill:#b3b3b3;}.cls-10{fill:#428542;}.cls-11{fill:#5eb135;}.cls-3,.cls-12{opacity:.2;}.cls-12{fill:none;}</style>
7
+
8
+ </defs>
9
+
10
+ <rect class="cls-3" height="152" width="208" x="88" y="56"/>
11
+
12
+ <g id="Text">
13
+
14
+ <path class="cls-7" d="m289.5,64.37h-16.2l-3.64,10.11h-5.26l14.77-38.67h4.46l14.8,38.67h-5.23l-3.68-10.11h-.01Zm-14.65-4.18h13.15l-6.59-18.09-6.56,18.09h0Z"/>
15
+
16
+ <path class="cls-7" d="m320.59,74.48c-.29-.56-.52-1.57-.69-3.03-2.28,2.37-5.01,3.55-8.18,3.55-2.83,0-5.16-.79-6.96-2.4-1.82-1.6-2.72-3.63-2.72-6.1,0-2.99,1.14-5.32,3.41-6.96,2.27-1.66,5.48-2.49,9.59-2.49h4.78v-2.25c0-1.72-.52-3.08-1.55-4.1-1.03-1.01-2.54-1.53-4.54-1.53-1.75,0-3.22.45-4.41,1.33s-1.78,1.95-1.78,3.21h-4.94c0-1.43.51-2.82,1.53-4.16,1.03-1.34,2.4-2.4,4.15-3.18,1.75-.78,3.66-1.17,5.75-1.17,3.31,0,5.91.82,7.79,2.49s2.85,3.93,2.92,6.83v13.22c0,2.64.33,4.74,1.01,6.3v.42h-5.16v.03Zm-8.15-3.74c1.55,0,3.01-.4,4.38-1.2,1.39-.79,2.38-1.84,3.01-3.11v-5.9h-3.84c-6.03,0-9.03,1.76-9.03,5.29,0,1.55.52,2.75,1.55,3.61s2.34,1.3,3.96,1.3h-.01Z"/>
17
+
18
+ </g>
19
+
20
+ <g id="Page_nav">
21
+
22
+ <path class="cls-7" d="m140,257c-20.4,0-37-16.6-37-37s16.6-37,37-37,37,16.6,37,37-16.6,37-37,37Zm0-72c-19.3,0-35,15.7-35,35s15.7,35,35,35,35-15.7,35-35-15.7-35-35-35Z"/>
23
+
24
+ <path class="cls-7" d="m135.37,243.04l-7.78-7.78,15.26-15.26-15.26-15.26,7.78-7.78,23.04,23.04-23.04,23.04Zm-4.95-7.78l4.95,4.95,20.21-20.21-20.21-20.21-4.95,4.95,15.26,15.26-15.26,15.26Z"/>
25
+
26
+ </g>
27
+
28
+ <g class="cls-12">
29
+
30
+ <circle class="cls-2" cx="196" cy="220" r="2"/>
31
+
32
+ </g>
33
+
34
+ <g class="cls-12">
35
+
36
+ <circle class="cls-2" cx="204" cy="220" r="2"/>
37
+
38
+ </g>
39
+
40
+ <g class="cls-12">
41
+
42
+ <circle class="cls-2" cx="212" cy="220" r="2"/>
43
+
44
+ </g>
45
+
46
+ <g class="cls-12">
47
+
48
+ <circle class="cls-2" cx="220" cy="220" r="2"/>
49
+
50
+ </g>
51
+
52
+ <g class="cls-12">
53
+
54
+ <circle class="cls-2" cx="228" cy="220" r="2"/>
55
+
56
+ </g>
57
+
58
+ <g class="cls-12">
59
+
60
+ <circle class="cls-2" cx="236" cy="220" r="2"/>
61
+
62
+ </g>
63
+
64
+ <g class="cls-12">
65
+
66
+ <circle class="cls-2" cx="244" cy="220" r="2"/>
67
+
68
+ </g>
69
+
70
+ <g class="cls-12">
71
+
72
+ <circle class="cls-2" cx="252" cy="220" r="2"/>
73
+
74
+ </g>
75
+
76
+ <g class="cls-12">
77
+
78
+ <circle class="cls-2" cx="260" cy="220" r="2"/>
79
+
80
+ </g>
81
+
82
+ <g class="cls-12">
83
+
84
+ <circle class="cls-2" cx="268" cy="220" r="2"/>
85
+
86
+ </g>
87
+
88
+ <g class="cls-12">
89
+
90
+ <circle class="cls-2" cx="276" cy="220" r="2"/>
91
+
92
+ </g>
93
+
94
+ <g class="cls-12">
95
+
96
+ <circle class="cls-2" cx="196" cy="228" r="2"/>
97
+
98
+ </g>
99
+
100
+ <g class="cls-12">
101
+
102
+ <circle class="cls-2" cx="204" cy="228" r="2"/>
103
+
104
+ </g>
105
+
106
+ <g class="cls-12">
107
+
108
+ <circle class="cls-2" cx="212" cy="228" r="2"/>
109
+
110
+ </g>
111
+
112
+ <g class="cls-12">
113
+
114
+ <circle class="cls-2" cx="220" cy="228" r="2"/>
115
+
116
+ </g>
117
+
118
+ <g class="cls-12">
119
+
120
+ <circle class="cls-2" cx="228" cy="228" r="2"/>
121
+
122
+ </g>
123
+
124
+ <g class="cls-12">
125
+
126
+ <circle class="cls-2" cx="236" cy="228" r="2"/>
127
+
128
+ </g>
129
+
130
+ <g class="cls-12">
131
+
132
+ <circle class="cls-2" cx="244" cy="228" r="2"/>
133
+
134
+ </g>
135
+
136
+ <g class="cls-12">
137
+
138
+ <circle class="cls-2" cx="252" cy="228" r="2"/>
139
+
140
+ </g>
141
+
142
+ <g class="cls-12">
143
+
144
+ <circle class="cls-2" cx="260" cy="228" r="2"/>
145
+
146
+ </g>
147
+
148
+ <g class="cls-12">
149
+
150
+ <circle class="cls-2" cx="268" cy="228" r="2"/>
151
+
152
+ </g>
153
+
154
+ <g class="cls-12">
155
+
156
+ <circle class="cls-2" cx="276" cy="228" r="2"/>
157
+
158
+ </g>
159
+
160
+ <g class="cls-12">
161
+
162
+ <circle class="cls-2" cx="196" cy="236" r="2"/>
163
+
164
+ </g>
165
+
166
+ <g class="cls-12">
167
+
168
+ <circle class="cls-2" cx="204" cy="236" r="2"/>
169
+
170
+ </g>
171
+
172
+ <g class="cls-12">
173
+
174
+ <circle class="cls-2" cx="212" cy="236" r="2"/>
175
+
176
+ </g>
177
+
178
+ <g class="cls-12">
179
+
180
+ <circle class="cls-2" cx="220" cy="236" r="2"/>
181
+
182
+ </g>
183
+
184
+ <g class="cls-12">
185
+
186
+ <circle class="cls-2" cx="228" cy="236" r="2"/>
187
+
188
+ </g>
189
+
190
+ <g class="cls-12">
191
+
192
+ <circle class="cls-2" cx="236" cy="236" r="2"/>
193
+
194
+ </g>
195
+
196
+ <g class="cls-12">
197
+
198
+ <circle class="cls-2" cx="244" cy="236" r="2"/>
199
+
200
+ </g>
201
+
202
+ <g class="cls-12">
203
+
204
+ <circle class="cls-2" cx="252" cy="236" r="2"/>
205
+
206
+ </g>
207
+
208
+ <g class="cls-12">
209
+
210
+ <circle class="cls-2" cx="260" cy="236" r="2"/>
211
+
212
+ </g>
213
+
214
+ <g class="cls-12">
215
+
216
+ <circle class="cls-2" cx="268" cy="236" r="2"/>
217
+
218
+ </g>
219
+
220
+ <g class="cls-12">
221
+
222
+ <circle class="cls-2" cx="276" cy="236" r="2"/>
223
+
224
+ </g>
225
+
226
+ <g class="cls-12">
227
+
228
+ <circle class="cls-2" cx="196" cy="244" r="2"/>
229
+
230
+ </g>
231
+
232
+ <g class="cls-12">
233
+
234
+ <circle class="cls-2" cx="204" cy="244" r="2"/>
235
+
236
+ </g>
237
+
238
+ <g class="cls-12">
239
+
240
+ <circle class="cls-2" cx="212" cy="244" r="2"/>
241
+
242
+ </g>
243
+
244
+ <g class="cls-12">
245
+
246
+ <circle class="cls-2" cx="220" cy="244" r="2"/>
247
+
248
+ </g>
249
+
250
+ <g class="cls-12">
251
+
252
+ <circle class="cls-2" cx="228" cy="244" r="2"/>
253
+
254
+ </g>
255
+
256
+ <g class="cls-12">
257
+
258
+ <circle class="cls-2" cx="236" cy="244" r="2"/>
259
+
260
+ </g>
261
+
262
+ <g class="cls-12">
263
+
264
+ <circle class="cls-2" cx="244" cy="244" r="2"/>
265
+
266
+ </g>
267
+
268
+ <g class="cls-12">
269
+
270
+ <circle class="cls-2" cx="252" cy="244" r="2"/>
271
+
272
+ </g>
273
+
274
+ <g class="cls-12">
275
+
276
+ <circle class="cls-2" cx="260" cy="244" r="2"/>
277
+
278
+ </g>
279
+
280
+ <g class="cls-12">
281
+
282
+ <circle class="cls-2" cx="268" cy="244" r="2"/>
283
+
284
+ </g>
285
+
286
+ <g class="cls-12">
287
+
288
+ <circle class="cls-2" cx="276" cy="244" r="2"/>
289
+
290
+ </g>
291
+
292
+ <g class="cls-12">
293
+
294
+ <circle class="cls-2" cx="196" cy="252" r="2"/>
295
+
296
+ </g>
297
+
298
+ <g class="cls-12">
299
+
300
+ <circle class="cls-2" cx="204" cy="252" r="2"/>
301
+
302
+ </g>
303
+
304
+ <g class="cls-12">
305
+
306
+ <circle class="cls-2" cx="212" cy="252" r="2"/>
307
+
308
+ </g>
309
+
310
+ <g class="cls-12">
311
+
312
+ <circle class="cls-2" cx="220" cy="252" r="2"/>
313
+
314
+ </g>
315
+
316
+ <g class="cls-12">
317
+
318
+ <circle class="cls-2" cx="228" cy="252" r="2"/>
319
+
320
+ </g>
321
+
322
+ <g class="cls-12">
323
+
324
+ <circle class="cls-2" cx="236" cy="252" r="2"/>
325
+
326
+ </g>
327
+
328
+ <g class="cls-12">
329
+
330
+ <circle class="cls-2" cx="244" cy="252" r="2"/>
331
+
332
+ </g>
333
+
334
+ <g class="cls-12">
335
+
336
+ <circle class="cls-2" cx="252" cy="252" r="2"/>
337
+
338
+ </g>
339
+
340
+ <g class="cls-12">
341
+
342
+ <circle class="cls-2" cx="260" cy="252" r="2"/>
343
+
344
+ </g>
345
+
346
+ <g class="cls-12">
347
+
348
+ <circle class="cls-2" cx="268" cy="252" r="2"/>
349
+
350
+ </g>
351
+
352
+ <g class="cls-12">
353
+
354
+ <circle class="cls-2" cx="276" cy="252" r="2"/>
355
+
356
+ </g>
357
+
358
+ <circle class="cls-8" cx="256" cy="136" r="16"/>
359
+
360
+ <path class="cls-7" d="m256,149.22c-7.29,0-13.22-5.93-13.22-13.22s5.93-13.22,13.22-13.22,13.22,5.93,13.22,13.22-5.93,13.22-13.22,13.22Z"/>
361
+
362
+ <path class="cls-2" d="m256,123.78c6.74,0,12.22,5.48,12.22,12.22s-5.48,12.22-12.22,12.22-12.22-5.48-12.22-12.22,5.48-12.22,12.22-12.22m0-2c-7.85,0-14.22,6.37-14.22,14.22s6.37,14.22,14.22,14.22,14.22-6.37,14.22-14.22-6.37-14.22-14.22-14.22h0Z"/>
363
+
364
+ <circle class="cls-2" cx="256" cy="136" r="7.11"/>
365
+
366
+ <circle class="cls-7" cx="256" cy="176" r="13.22"/>
367
+
368
+ <path class="cls-2" d="m256,163.78c6.74,0,12.22,5.48,12.22,12.22s-5.48,12.22-12.22,12.22-12.22-5.48-12.22-12.22,5.48-12.22,12.22-12.22m0-2c-7.85,0-14.22,6.37-14.22,14.22s6.37,14.22,14.22,14.22,14.22-6.37,14.22-14.22-6.37-14.22-14.22-14.22h0Z"/>
369
+
370
+ <g id="Desktop">
371
+
372
+ <rect class="cls-6" height="160" rx="5.33" ry="5.33" width="224" x="8" y="8"/>
373
+
374
+ <rect class="cls-7" height="70.67" width="224" x="8" y="22.67"/>
375
+
376
+ <rect class="cls-5" height="10.67" width="32" x="18.67" y="136"/>
377
+
378
+ <rect class="cls-9" height="5.33" width="64" x="18.67" y="104"/>
379
+
380
+ <rect class="cls-9" height="5.33" width="64" x="18.67" y="114.67"/>
381
+
382
+ <rect class="cls-9" height="5.33" width="32" x="18.67" y="125.33"/>
383
+
384
+ <rect class="cls-9" height="10.67" width="106.67" x="114.67" y="34.67"/>
385
+
386
+ <rect class="cls-9" height="5.33" width="106.67" x="114.67" y="50.67"/>
387
+
388
+ <rect class="cls-9" height="5.33" width="53.33" x="114.67" y="61.33"/>
389
+
390
+ <rect class="cls-5" height="48" width="85.33" x="18.67" y="34.67"/>
391
+
392
+ <polygon class="cls-7" points="102.16 86.64 17.21 37.75 20.51 30.69 105.45 79.59 102.16 86.64"/>
393
+
394
+ <path class="cls-1" d="m13.33,8h213.33c2.95,0,5.33,2.39,5.33,5.33v9.33H8v-9.33c0-2.95,2.39-5.33,5.33-5.33Z"/>
395
+
396
+ <polygon class="cls-7" points="20.51 86.64 17.21 79.59 102.16 30.69 105.45 37.75 20.51 86.64"/>
397
+
398
+ <circle class="cls-4" cx="21.33" cy="16" r="2.67"/>
399
+
400
+ <path class="cls-7" d="m226.67,169H13.33c-3.49,0-6.33-2.84-6.33-6.33V13.33c0-3.49,2.84-6.33,6.33-6.33h213.33c3.49,0,6.33,2.84,6.33,6.33v149.33c0,3.49-2.84,6.33-6.33,6.33ZM13.33,9c-2.39,0-4.33,1.94-4.33,4.33v149.33c0,2.39,1.94,4.33,4.33,4.33h213.33c2.39,0,4.33-1.94,4.33-4.33V13.33c0-2.39-1.94-4.33-4.33-4.33H13.33Z"/>
401
+
402
+ <circle class="cls-8" cx="31.87" cy="15.73" r="2.67"/>
403
+
404
+ <circle class="cls-11" cx="42.53" cy="15.73" r="2.67"/>
405
+
406
+ <rect class="cls-7" height="42.67" rx="5.33" ry="5.33" width="128" x="93.33" y="104"/>
407
+
408
+ <rect class="cls-9" height="2.67" width="24" x="189.33" y="114.67"/>
409
+
410
+ <g id="Pie">
411
+
412
+ <path class="cls-11" d="m135.99,124.76c-.05-1.45-.29-2.87-.71-4.19-.43-1.37-1.01-2.67-1.8-3.84-.75-1.23-1.68-2.32-2.75-3.28l-6.29,6.29c.51.43.95.88,1.33,1.4.37.52.68,1.08.91,1.71.23.59.37,1.23.41,1.88.04.2.04.39.04.59,0,.44-.04.89-.12,1.32h0s8.59,2.32,8.59,2.32c.27-1.17.43-2.4.43-3.65,0-.19,0-.37-.01-.56h-.03Z"/>
413
+
414
+ <path class="cls-4" d="m120.61,132.41v8.91h-.63c-8.83,0-15.99-7.16-15.99-16.01,0-5.89,3.19-11.03,7.93-13.8l4.48,7.68c-2.09,1.24-3.52,3.53-3.52,6.13,0,3.93,3.2,7.11,7.11,7.11.21,0,.41-.01.61-.03h0Z"/>
415
+
416
+ <path class="cls-8" d="m126.99,126.67c-.11.64-.32,1.23-.59,1.77-.28.57-.63,1.08-1.01,1.55-.41.47-.87.87-1.39,1.23-.48.33-1.03.6-1.6.8-.55.21-1.13.33-1.75.39h-.04v8.91c1.41-.05,2.77-.29,4.05-.69,1.32-.39,2.6-.97,3.75-1.69,1.19-.73,2.28-1.61,3.23-2.63s1.79-2.16,2.44-3.4c.67-1.23,1.16-2.53,1.48-3.92l-8.59-2.31h.01Z"/>
417
+
418
+ <path class="cls-10" d="m130.72,113.45l-6.29,6.29h0c-.52-.4-1.07-.75-1.69-.99-.59-.25-1.23-.41-1.91-.48-.27-.04-.53-.05-.81-.05-.39,0-.76.03-1.12.08-.88.15-1.72.44-2.47.89l-4.48-7.68c2.08-1.21,4.45-1.97,6.99-2.15.36-.03.72-.04,1.07-.04,1.09,0,2.16.11,3.17.31,1.43.29,2.79.76,4.04,1.41,1.28.64,2.47,1.45,3.52,2.4h-.01Z"/>
419
+
420
+ <path class="cls-7" d="m112.89,125.33c0-3.53,2.61-6.49,5.99-7.03.36-.05.73-.09,1.12-.09.28,0,.55.01.81.05.68.07,1.32.23,1.91.48.63.25,1.17.59,1.69.97.52.43.96.89,1.35,1.43.37.52.68,1.08.91,1.71.23.59.37,1.23.41,1.88.04.2.04.39.04.59,0,.44-.04.89-.12,1.32-.11.64-.32,1.24-.59,1.8-.28.57-.63,1.08-1.01,1.55-.41.47-.87.87-1.39,1.23-.48.33-1.03.6-1.6.8-.55.21-1.13.33-1.75.39-.21.01-.43.04-.65.04-3.91,0-7.11-3.19-7.11-7.11h-.01Z"/>
421
+
422
+ </g>
423
+
424
+ <rect class="cls-10" height="10.67" width="5.33" x="144" y="120"/>
425
+
426
+ <rect class="cls-11" height="16" width="5.33" x="154.67" y="117.33"/>
427
+
428
+ <rect class="cls-8" height="21.33" width="5.33" x="165.33" y="114.67"/>
429
+
430
+ <rect class="cls-4" height="10.67" width="5.33" x="176" y="120"/>
431
+
432
+ <rect class="cls-9" height="2.67" width="24" x="189.33" y="120.89"/>
433
+
434
+ <rect class="cls-9" height="2.67" width="24" x="189.33" y="127.11"/>
435
+
436
+ <rect class="cls-9" height="2.67" width="16" x="189.33" y="133.33"/>
437
+
438
+ </g>
439
+
440
+ <g id="Mobile">
441
+
442
+ <path class="cls-4" d="m343.38,140.92h-62.77v-15.69c0-2.89,2.34-5.23,5.23-5.23h52.31c2.89,0,5.23,2.34,5.23,5.23v15.69Z"/>
443
+
444
+ <path class="cls-6" d="m280.62,140.92h62.77v109.85c0,2.89-2.34,5.23-5.23,5.23h-52.31c-2.89,0-5.23-2.34-5.23-5.23v-109.85h0Z"/>
445
+
446
+ <rect class="cls-11" height="52.31" width="62.77" x="280.62" y="146.15"/>
447
+
448
+ <path class="cls-6" d="m343.38,172.31c0,10.92-5.58,20.54-14.06,26.15h-34.65c-8.47-5.61-14.06-15.23-14.06-26.15s5.58-20.54,14.06-26.15h34.65c8.47,5.61,14.06,15.23,14.06,26.15Z"/>
449
+
450
+ <circle class="cls-1" cx="312" cy="172.31" r="26.15"/>
451
+
452
+ <circle class="cls-6" cx="312" cy="172.31" r="20.92"/>
453
+
454
+ <circle class="cls-6" cx="312" cy="172.31" r="15.69"/>
455
+
456
+ <circle class="cls-4" cx="312" cy="172.31" r="10.46"/>
457
+
458
+ <g id="Outline">
459
+
460
+ <path class="cls-7" d="m338.15,257h-52.31c-3.44,0-6.23-2.79-6.23-6.23v-125.54c0-3.44,2.79-6.23,6.23-6.23h52.31c3.44,0,6.23,2.8,6.23,6.23v125.54c0,3.44-2.79,6.23-6.23,6.23Zm-52.31-136c-2.33,0-4.23,1.9-4.23,4.23v125.54c0,2.33,1.9,4.23,4.23,4.23h52.31c2.33,0,4.23-1.9,4.23-4.23v-125.54c0-2.33-1.9-4.23-4.23-4.23h-52.31Z"/>
461
+
462
+ </g>
463
+
464
+ <rect class="cls-7" height="37.92" width="62.77" x="280.62" y="203.69"/>
465
+
466
+ <rect class="cls-9" height="5.23" width="52.31" x="285.85" y="208.92"/>
467
+
468
+ <rect class="cls-9" height="5.23" width="52.31" x="285.85" y="219.38"/>
469
+
470
+ <rect class="cls-9" height="5.23" width="26.15" x="285.85" y="229.85"/>
471
+
472
+ <rect class="cls-7" height="1.74" width="10.46" x="327.69" y="125.66"/>
473
+
474
+ <rect class="cls-7" height="1.74" width="10.46" x="327.69" y="129.59"/>
475
+
476
+ <rect class="cls-7" height="1.74" width="10.46" x="327.69" y="133.51"/>
477
+
478
+ </g>
479
+
480
+ <circle class="cls-7" cx="12" cy="188" r="4"/>
481
+
482
+ <circle class="cls-8" cx="12" cy="204" r="4"/>
483
+
484
+ <circle class="cls-11" cx="12" cy="220" r="4"/>
485
+
486
+ <circle class="cls-10" cx="12" cy="236" r="4"/>
487
+
488
+ <circle class="cls-1" cx="12" cy="252" r="4"/>
489
+
490
+ <rect class="cls-7" height="4" width="50.69" x="21.31" y="186"/>
491
+
492
+ <rect class="cls-8" height="4" width="50.69" x="21.31" y="202"/>
493
+
494
+ <rect class="cls-11" height="4" width="50.69" x="21.31" y="218"/>
495
+
496
+ <rect class="cls-10" height="4" width="50.69" x="21.31" y="234"/>
497
+
498
+ <rect class="cls-1" height="4" width="50.69" x="21.31" y="250"/>
499
+
500
+ <path class="cls-7" d="m342,10v92h-92V10h92m2-2h-96v96h96V8h0Z"/>
501
+
502
+ </svg>
package/tsconfig.json CHANGED
@@ -12,9 +12,6 @@
12
12
  ],
13
13
  "module": "NodeNext",
14
14
  "moduleResolution": "nodenext",
15
- "noFallthroughCasesInSwitch": true,
16
- "noUnusedLocals": true,
17
- "noUnusedParameters": true,
18
15
  "outDir": "./dist",
19
16
  "paths": {
20
17
  "@/*": [
package/vite.config.ts CHANGED
@@ -1,4 +1,5 @@
1
- /// <reference types="vitest/config" />
1
+ import "vitest/config";
2
+
2
3
  import { defineConfig } from 'vitest/config';
3
4
  import react from "@vitejs/plugin-react-swc";
4
5
  import { playwright } from '@vitest/browser-playwright';
@@ -17,6 +18,10 @@ export default defineConfig({
17
18
  exclude: ["src/images", "**/*.stories.+(tsx|ts)"],
18
19
  include: ["src/**"],
19
20
  reporter: ["text", "lcov"],
21
+ thresholds: {
22
+ branches: 80,
23
+ lines: -10,
24
+ }
20
25
  },
21
26
  projects: [
22
27
  {
@@ -1,17 +0,0 @@
1
- declare namespace SGDS.Common {
2
- namespace AbstractNotificationBanner {
3
- interface Buttons extends React.AllHTMLAttributes<HTMLDivElement> {
4
- children: React.ReactNode
5
- }
6
- }
7
-
8
- interface AbstractNotificationBanner extends React.AllHTMLAttributes<HTMLDivElement> {
9
- hasIcon?: boolean,
10
- hasColourIcon?: boolean,
11
- hasInverseIcon?: boolean,
12
- icon?: IconName,
13
- isDismissable?: boolean,
14
- title: string,
15
- ref?: any
16
- }
17
- }
@@ -1,8 +0,0 @@
1
- declare namespace SGDS.Common {
2
- interface ActionLink extends React.AllHTMLAttributes<HTMLElement> {
3
- describedby?: string,
4
- href?: string,
5
- linkComponent?: SGDS.LinkComponent,
6
- onclick?: React.EventHandler<any>
7
- }
8
- }
@@ -1,6 +0,0 @@
1
- declare namespace SGDS.Common {
2
- interface ConditionalWrapper extends React.AllHTMLAttributes<HTMLElement> {
3
- condition: boolean,
4
- wrapper: any
5
- }
6
- }
@@ -1,7 +0,0 @@
1
- declare namespace SGDS.Common {
2
- interface FileIcon extends React.AllHTMLAttributes<SVGSVGElement> {
3
- ariaLabel?: React.AriaAttributes['aria-label'],
4
- className?: string,
5
- icon: DocumentIconName
6
- }
7
- }
@@ -1,6 +0,0 @@
1
- declare namespace SGDS.Common {
2
- interface HintText extends React.AllHTMLAttributes<HTMLElement> {
3
- id?: string,
4
- text?: string
5
- }
6
- }
@@ -1,9 +0,0 @@
1
- declare namespace SGDS.Common {
2
- interface Icon extends React.AllHTMLAttributes<SVGSVGElement> {
3
- ariaLabel?: React.AriaAttributes['aria-label'],
4
- className?: string,
5
- isFilled?: boolean,
6
- icon: IconName,
7
- iconSize?: string
8
- }
9
- }
@@ -1,4 +0,0 @@
1
- declare namespace SGDS.Common {
2
- interface ScreenReaderText extends React.AllHTMLAttributes<HTMLElement> {
3
- }
4
- }
@@ -1,5 +0,0 @@
1
- declare namespace SGDS.Common {
2
- interface WrapperTag extends React.AllHTMLAttributes<HTMLElement> {
3
- tagName?: string
4
- }
5
- }