@digigov/ui 0.21.3 → 0.24.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 (598) hide show
  1. package/CHANGELOG.md +41 -1
  2. package/admin/AutoComplete/AccesibleAutoComplete/index.d.ts +5 -0
  3. package/admin/AutoComplete/AccesibleAutoComplete/index.js +106 -0
  4. package/admin/AutoComplete/AutoComplete.stories.d.ts +13 -0
  5. package/admin/AutoComplete/AutoComplete.stories.js +115 -0
  6. package/admin/AutoComplete/Status/index.d.ts +40 -0
  7. package/admin/AutoComplete/Status/index.js +184 -0
  8. package/{app/CopyToClipboard → admin/AutoComplete}/__stories__/Default.d.ts +0 -0
  9. package/admin/AutoComplete/__stories__/Default.js +34 -0
  10. package/admin/AutoComplete/__stories__/WithAutoSelect.d.ts +3 -0
  11. package/admin/AutoComplete/__stories__/WithAutoSelect.js +35 -0
  12. package/admin/AutoComplete/__stories__/WithDefaultValue.d.ts +3 -0
  13. package/admin/AutoComplete/__stories__/WithDefaultValue.js +33 -0
  14. package/admin/AutoComplete/__stories__/WithInLine.d.ts +3 -0
  15. package/admin/AutoComplete/__stories__/WithInLine.js +33 -0
  16. package/admin/AutoComplete/__stories__/WithMinLength.d.ts +3 -0
  17. package/admin/AutoComplete/__stories__/WithMinLength.js +35 -0
  18. package/admin/AutoComplete/__stories__/WithPlaceHolder.d.ts +3 -0
  19. package/admin/AutoComplete/__stories__/WithPlaceHolder.js +33 -0
  20. package/admin/AutoComplete/__stories__/WithShowAllValues.d.ts +3 -0
  21. package/admin/AutoComplete/__stories__/WithShowAllValues.js +33 -0
  22. package/admin/AutoComplete/index.d.ts +101 -0
  23. package/admin/AutoComplete/index.js +744 -0
  24. package/admin/AutoComplete/index.mdx +46 -0
  25. package/admin/AutoComplete/utils.d.ts +1 -0
  26. package/admin/AutoComplete/utils.js +13 -0
  27. package/admin/CopyToClipboard/CopyToClipboard.stories.d.ts +9 -0
  28. package/admin/CopyToClipboard/CopyToClipboard.stories.js +58 -0
  29. package/admin/CopyToClipboard/__stories__/Banner.d.ts +3 -0
  30. package/admin/CopyToClipboard/__stories__/Banner.js +30 -0
  31. package/admin/CopyToClipboard/__stories__/Default.d.ts +3 -0
  32. package/admin/CopyToClipboard/__stories__/Default.js +32 -0
  33. package/admin/CopyToClipboard/__stories__/MultipleCopies.d.ts +3 -0
  34. package/{app/CopyToClipboard/__stories__/Default.js → admin/CopyToClipboard/__stories__/MultipleCopies.js} +20 -18
  35. package/admin/CopyToClipboard/index.d.ts +1 -1
  36. package/admin/CopyToClipboard/index.js +3 -2
  37. package/admin/CopyToClipboard/index.mdx +22 -0
  38. package/admin/Drawer/__stories__/Default.js +1 -1
  39. package/admin/Drawer/index.mdx +12 -0
  40. package/admin/Dropdown/Dropdown.stories.d.ts +9 -0
  41. package/admin/Dropdown/Dropdown.stories.js +60 -0
  42. package/admin/Dropdown/__stories__/AlignRight.d.ts +3 -0
  43. package/admin/Dropdown/__stories__/AlignRight.js +83 -0
  44. package/admin/Dropdown/__stories__/Default.d.ts +3 -0
  45. package/admin/Dropdown/__stories__/Default.js +75 -0
  46. package/admin/Dropdown/__stories__/PlacementTop.d.ts +3 -0
  47. package/admin/Dropdown/__stories__/PlacementTop.js +83 -0
  48. package/admin/Dropdown/index.mdx +29 -0
  49. package/admin/FilterSection/index.d.ts +1 -0
  50. package/admin/FilterSection/index.js +14 -0
  51. package/admin/Modal/Modal.stories.d.ts +8 -0
  52. package/admin/Modal/Modal.stories.js +44 -0
  53. package/admin/Modal/__stories__/AlertDialog.d.ts +3 -0
  54. package/admin/Modal/__stories__/AlertDialog.js +80 -0
  55. package/admin/Modal/__stories__/Default.d.ts +3 -0
  56. package/admin/Modal/__stories__/Default.js +79 -0
  57. package/admin/Modal/index.mdx +26 -0
  58. package/admin/Pagination/__stories__/Default.js +38 -14
  59. package/admin/Pagination/index.mdx +12 -0
  60. package/admin/TaskList/TaskList.stories.d.ts +7 -0
  61. package/{app/CopyToClipboard/CopyToClipboard.stories.js → admin/TaskList/TaskList.stories.js} +4 -4
  62. package/admin/TaskList/__stories__/Default.d.ts +3 -0
  63. package/admin/TaskList/__stories__/Default.js +97 -0
  64. package/admin/TaskList/index.d.ts +7 -0
  65. package/admin/TaskList/index.js +86 -0
  66. package/admin/Timeline/Timeline.stories.d.ts +7 -0
  67. package/admin/Timeline/Timeline.stories.js +30 -0
  68. package/admin/Timeline/__stories__/Default.d.ts +3 -0
  69. package/admin/Timeline/__stories__/Default.js +87 -0
  70. package/admin/Timeline/index.d.ts +7 -0
  71. package/admin/Timeline/index.js +86 -0
  72. package/admin/index.d.ts +4 -1
  73. package/admin/index.js +43 -4
  74. package/api/fetchAPI.js +6 -4
  75. package/api/index.spec.js +18 -19
  76. package/api/useResource.js +6 -4
  77. package/api/useResourceAction.js +6 -4
  78. package/api/useResourceQuery.js +7 -4
  79. package/api/utils.js +8 -6
  80. package/app/Confirmation/Confirmation.mdx +9 -0
  81. package/app/Footer/Footer.mdx +27 -0
  82. package/app/Header/index.mdx +18 -0
  83. package/app/I18nText.js +7 -7
  84. package/app/NotFound/index.mdx +12 -0
  85. package/app/PhaseBannerHeader/index.mdx +12 -0
  86. package/core/Accordion/__stories__/Default.js +17 -1
  87. package/core/Accordion/__stories__/WithHints.js +17 -1
  88. package/core/Accordion/index.mdx +16 -84
  89. package/core/BackLink/index.mdx +16 -0
  90. package/core/Blockquote/index.mdx +17 -2
  91. package/core/Breadcrumbs/__stories__/Default.js +13 -1
  92. package/core/Breadcrumbs/breadcrumbs.mdx +22 -0
  93. package/core/Button/Button.stories.d.ts +5 -0
  94. package/core/Button/Button.stories.js +72 -0
  95. package/core/Button/__stories__/Back.d.ts +4 -0
  96. package/core/Button/__stories__/Back.js +26 -0
  97. package/core/Button/__stories__/ButtonLinkButton.d.ts +6 -0
  98. package/core/Button/__stories__/ButtonLinkButton.js +30 -0
  99. package/core/Button/__stories__/CallToActionButton.d.ts +6 -0
  100. package/core/Button/__stories__/CallToActionButton.js +30 -0
  101. package/core/Button/__stories__/Disabled.d.ts +6 -0
  102. package/core/Button/__stories__/Disabled.js +27 -0
  103. package/core/Button/__stories__/GroupingButtonsAndLinks.js +3 -1
  104. package/core/Button/__stories__/Primary.js +3 -1
  105. package/core/Button/__stories__/Secondary.js +3 -2
  106. package/core/Button/__stories__/Warning.js +2 -1
  107. package/core/Button/__stories__/WithVariantLink.d.ts +6 -0
  108. package/core/Button/__stories__/WithVariantLink.js +29 -0
  109. package/core/Button/index.mdx +97 -0
  110. package/core/Card/Card.stories.d.ts +1 -0
  111. package/core/Card/Card.stories.js +14 -0
  112. package/core/Card/__stories__/WithClickableLink.js +1 -3
  113. package/core/Card/__stories__/WithGroupButton.d.ts +3 -0
  114. package/core/Card/__stories__/WithGroupButton.js +32 -0
  115. package/core/Card/card.mdx +78 -0
  116. package/core/Checkboxes/Checkbox.stories.d.ts +1 -0
  117. package/core/Checkboxes/Checkbox.stories.js +14 -0
  118. package/core/Checkboxes/__stories__/ConditionalReveal.js +5 -1
  119. package/core/Checkboxes/__stories__/Default.js +5 -1
  120. package/core/Checkboxes/__stories__/MultipleQuestions.js +6 -2
  121. package/core/Checkboxes/__stories__/NoneAnswer.js +5 -1
  122. package/core/Checkboxes/__stories__/NoneAnswerWithError.d.ts +3 -0
  123. package/core/Checkboxes/__stories__/NoneAnswerWithError.js +57 -0
  124. package/core/Checkboxes/__stories__/WithErrorMessage.js +7 -1
  125. package/core/Checkboxes/__stories__/WithHint.js +5 -1
  126. package/core/Checkboxes/checkboxes.mdx +54 -0
  127. package/core/Confirmation/confirmation.mdx +19 -0
  128. package/core/DateInput/DateInput.stories.d.ts +1 -0
  129. package/core/DateInput/DateInput.stories.js +14 -0
  130. package/core/DateInput/__stories__/Default.js +3 -1
  131. package/core/DateInput/__stories__/MultipleQuestions.d.ts +3 -0
  132. package/core/DateInput/__stories__/MultipleQuestions.js +41 -0
  133. package/core/DateInput/index.mdx +34 -0
  134. package/core/Details/index.mdx +9 -25
  135. package/core/ErrorMessage/__stories__/Default.js +1 -1
  136. package/core/ErrorMessage/index.mdx +21 -0
  137. package/core/ErrorSummary/__stories__/LinkedToCheckbox.js +1 -1
  138. package/core/ErrorSummary/index.mdx +21 -38
  139. package/core/FileUpload/__stories__/Default.d.ts +1 -0
  140. package/core/FileUpload/__stories__/Default.js +4 -2
  141. package/core/FileUpload/index.mdx +22 -0
  142. package/core/Link/__stories__/DarkBackground.js +4 -2
  143. package/core/Link/__stories__/DarkBackgroundNoUnderline.js +4 -2
  144. package/core/Link/__stories__/Default.js +3 -1
  145. package/core/Link/__stories__/NoUnderline.js +3 -1
  146. package/core/Link/link.mdx +34 -0
  147. package/core/List/index.mdx +22 -3
  148. package/core/Masthead/masthead.mdx +14 -0
  149. package/core/NavList/NavList.d.ts +1 -14
  150. package/core/NavList/NavList.js +14 -71
  151. package/core/NavList/NavList.stories.d.ts +8 -0
  152. package/core/NavList/NavList.stories.js +44 -0
  153. package/core/NavList/NavListBase.d.ts +4 -0
  154. package/core/NavList/NavListBase.js +76 -0
  155. package/core/NavList/NavListItem.d.ts +1 -0
  156. package/core/NavList/NavListItem.js +3 -1
  157. package/core/NavList/NavListItemBase.d.ts +1 -0
  158. package/core/NavList/NavListItemBase.js +7 -3
  159. package/core/NavList/NavListSubMenu.d.ts +1 -1
  160. package/core/NavList/NavListSubMenu.js +2 -2
  161. package/core/NavList/__stories__/Default.d.ts +3 -0
  162. package/core/NavList/__stories__/Default.js +69 -0
  163. package/core/NavList/__stories__/NavHorizontalLayout.d.ts +3 -0
  164. package/core/NavList/__stories__/NavHorizontalLayout.js +67 -0
  165. package/core/NavList/index.mdx +22 -1
  166. package/core/NavList/types.d.ts +14 -0
  167. package/core/NavList/types.js +5 -0
  168. package/core/NotificationBanner/index.mdx +13 -60
  169. package/core/PhaseBanner/PhaseBanner.stories.d.ts +1 -0
  170. package/core/PhaseBanner/PhaseBanner.stories.js +14 -0
  171. package/core/PhaseBanner/__stories__/Underlined.d.ts +3 -0
  172. package/{admin/CopyToClipboardMessage/index.js → core/PhaseBanner/__stories__/Underlined.js} +21 -17
  173. package/core/PhaseBanner/index.mdx +24 -0
  174. package/core/Radios/__stories__/ConditionalReveal.js +5 -1
  175. package/core/Radios/__stories__/Default.js +1 -3
  176. package/core/Radios/__stories__/Inline.js +5 -1
  177. package/core/Radios/__stories__/MultipleQuestions.js +7 -3
  178. package/core/Radios/__stories__/WithErrorMessage.js +7 -1
  179. package/core/Radios/__stories__/WithHints.js +17 -7
  180. package/core/Radios/index.mdx +56 -0
  181. package/core/Select/Select.stories.d.ts +1 -0
  182. package/core/Select/Select.stories.js +14 -0
  183. package/core/Select/__stories__/Default.js +2 -2
  184. package/core/Select/__stories__/DisabledInput.js +3 -1
  185. package/core/Select/__stories__/WithHint.d.ts +3 -0
  186. package/core/Select/__stories__/WithHint.js +45 -0
  187. package/core/Select/index.mdx +42 -0
  188. package/core/SummaryList/SummaryList.stories.d.ts +2 -2
  189. package/core/SummaryList/SummaryList.stories.js +8 -8
  190. package/core/SummaryList/__stories__/Default.js +1 -1
  191. package/core/SummaryList/__stories__/WithActions.d.ts +3 -0
  192. package/core/SummaryList/__stories__/{SummaryListWithActions.js → WithActions.js} +10 -12
  193. package/core/SummaryList/__stories__/WithoutBorders.d.ts +3 -0
  194. package/core/SummaryList/__stories__/{SummaryListWithoutBorders.js → WithoutBorders.js} +5 -5
  195. package/core/SummaryList/index.mdx +17 -65
  196. package/core/Table/Table.stories.d.ts +1 -0
  197. package/core/Table/Table.stories.js +14 -0
  198. package/core/Table/__stories__/DarkVariant.js +1 -1
  199. package/core/Table/__stories__/Default.js +1 -1
  200. package/core/Table/__stories__/NoData.js +3 -1
  201. package/core/Table/__stories__/TableCaptions.d.ts +3 -0
  202. package/core/Table/__stories__/TableCaptions.js +30 -0
  203. package/core/Table/__stories__/WithLoader.js +16 -12
  204. package/core/Table/index.mdx +59 -0
  205. package/core/Tabs/__stories__/Default.d.ts +1 -0
  206. package/core/Tabs/__stories__/Default.js +6 -2
  207. package/core/Tabs/index.mdx +10 -2
  208. package/core/TextArea/index.mdx +50 -0
  209. package/core/TextInput/index.mdx +59 -0
  210. package/core/VisuallyHidden/__stories__/Default.js +14 -2
  211. package/core/VisuallyHidden/index.mdx +17 -0
  212. package/core/WarningText/index.mdx +10 -35
  213. package/es/admin/AutoComplete/AccesibleAutoComplete/index.js +87 -0
  214. package/es/admin/AutoComplete/AutoComplete.stories.js +13 -0
  215. package/es/admin/AutoComplete/Status/index.js +153 -0
  216. package/es/admin/AutoComplete/__stories__/Default.js +19 -0
  217. package/es/admin/AutoComplete/__stories__/WithAutoSelect.js +20 -0
  218. package/es/admin/AutoComplete/__stories__/WithDefaultValue.js +18 -0
  219. package/es/admin/AutoComplete/__stories__/WithInLine.js +18 -0
  220. package/es/admin/AutoComplete/__stories__/WithMinLength.js +19 -0
  221. package/es/admin/AutoComplete/__stories__/WithPlaceHolder.js +18 -0
  222. package/es/admin/AutoComplete/__stories__/WithShowAllValues.js +18 -0
  223. package/es/admin/AutoComplete/index.js +676 -0
  224. package/es/admin/AutoComplete/index.mdx +46 -0
  225. package/es/admin/AutoComplete/utils.js +6 -0
  226. package/es/admin/CopyToClipboard/CopyToClipboard.stories.js +8 -0
  227. package/es/admin/CopyToClipboard/__stories__/Banner.js +16 -0
  228. package/es/admin/CopyToClipboard/__stories__/Default.js +18 -0
  229. package/{esm/app/CopyToClipboard/__stories__/Default.js → es/admin/CopyToClipboard/__stories__/MultipleCopies.js} +10 -8
  230. package/es/admin/CopyToClipboard/index.js +3 -2
  231. package/es/admin/CopyToClipboard/index.mdx +22 -0
  232. package/es/admin/Drawer/__stories__/Default.js +1 -1
  233. package/es/admin/Drawer/index.mdx +12 -0
  234. package/es/admin/Dropdown/Dropdown.stories.js +9 -0
  235. package/es/admin/Dropdown/__stories__/AlignRight.js +56 -0
  236. package/es/admin/Dropdown/__stories__/Default.js +48 -0
  237. package/es/admin/Dropdown/__stories__/PlacementTop.js +56 -0
  238. package/es/admin/Dropdown/index.mdx +29 -0
  239. package/es/admin/FilterSection/index.js +1 -0
  240. package/es/admin/Modal/Modal.stories.js +7 -0
  241. package/es/admin/Modal/__stories__/AlertDialog.js +58 -0
  242. package/es/admin/Modal/__stories__/Default.js +56 -0
  243. package/es/admin/Modal/index.mdx +26 -0
  244. package/es/admin/Pagination/__stories__/Default.js +37 -14
  245. package/es/admin/Pagination/index.mdx +12 -0
  246. package/es/admin/TaskList/TaskList.stories.js +6 -0
  247. package/es/admin/TaskList/__stories__/Default.js +74 -0
  248. package/es/admin/TaskList/index.js +7 -0
  249. package/es/admin/Timeline/Timeline.stories.js +6 -0
  250. package/es/admin/Timeline/__stories__/Default.js +64 -0
  251. package/es/admin/Timeline/index.js +7 -0
  252. package/es/admin/index.js +5 -2
  253. package/es/api/fetchAPI.js +6 -3
  254. package/es/api/index.spec.js +19 -17
  255. package/es/api/useResource.js +6 -3
  256. package/es/api/useResourceAction.js +6 -3
  257. package/es/api/useResourceQuery.js +6 -3
  258. package/es/api/utils.js +8 -5
  259. package/es/app/Confirmation/Confirmation.mdx +9 -0
  260. package/es/app/Footer/Footer.mdx +27 -0
  261. package/es/app/Header/index.mdx +18 -0
  262. package/es/app/I18nText.js +7 -6
  263. package/es/app/NotFound/index.mdx +12 -0
  264. package/es/app/PhaseBannerHeader/index.mdx +12 -0
  265. package/es/core/Accordion/__stories__/Default.js +17 -1
  266. package/es/core/Accordion/__stories__/WithHints.js +17 -1
  267. package/es/core/Accordion/index.mdx +16 -84
  268. package/es/core/BackLink/index.mdx +16 -0
  269. package/es/core/Blockquote/index.mdx +17 -2
  270. package/es/core/Breadcrumbs/__stories__/Default.js +13 -1
  271. package/es/core/Breadcrumbs/breadcrumbs.mdx +22 -0
  272. package/es/core/Button/Button.stories.js +7 -1
  273. package/es/core/Button/__stories__/Back.js +13 -0
  274. package/es/core/Button/__stories__/ButtonLinkButton.js +17 -0
  275. package/es/core/Button/__stories__/CallToActionButton.js +17 -0
  276. package/es/core/Button/__stories__/Disabled.js +14 -0
  277. package/es/core/Button/__stories__/GroupingButtonsAndLinks.js +3 -1
  278. package/es/core/Button/__stories__/Primary.js +3 -1
  279. package/es/core/Button/__stories__/Secondary.js +3 -2
  280. package/es/core/Button/__stories__/Warning.js +2 -1
  281. package/es/core/Button/__stories__/WithVariantLink.js +16 -0
  282. package/es/core/Button/index.mdx +97 -0
  283. package/es/core/Card/Card.stories.js +2 -1
  284. package/es/core/Card/__stories__/WithClickableLink.js +2 -3
  285. package/es/core/Card/__stories__/WithGroupButton.js +11 -0
  286. package/es/core/Card/card.mdx +78 -0
  287. package/es/core/Checkboxes/Checkbox.stories.js +1 -0
  288. package/es/core/Checkboxes/__stories__/ConditionalReveal.js +5 -1
  289. package/es/core/Checkboxes/__stories__/Default.js +5 -1
  290. package/es/core/Checkboxes/__stories__/MultipleQuestions.js +6 -2
  291. package/es/core/Checkboxes/__stories__/NoneAnswer.js +5 -1
  292. package/es/core/Checkboxes/__stories__/NoneAnswerWithError.js +34 -0
  293. package/es/core/Checkboxes/__stories__/WithErrorMessage.js +7 -1
  294. package/es/core/Checkboxes/__stories__/WithHint.js +5 -1
  295. package/es/core/Checkboxes/checkboxes.mdx +54 -0
  296. package/es/core/Confirmation/confirmation.mdx +19 -0
  297. package/es/core/DateInput/DateInput.stories.js +1 -0
  298. package/es/core/DateInput/__stories__/Default.js +3 -1
  299. package/es/core/DateInput/__stories__/MultipleQuestions.js +20 -0
  300. package/es/core/DateInput/index.mdx +34 -0
  301. package/es/core/Details/index.mdx +9 -25
  302. package/es/core/ErrorMessage/__stories__/Default.js +1 -1
  303. package/es/core/ErrorMessage/index.mdx +21 -0
  304. package/es/core/ErrorSummary/__stories__/LinkedToCheckbox.js +1 -1
  305. package/es/core/ErrorSummary/index.mdx +21 -38
  306. package/es/core/FileUpload/__stories__/Default.js +2 -1
  307. package/es/core/FileUpload/index.mdx +22 -0
  308. package/es/core/Link/__stories__/DarkBackground.js +7 -5
  309. package/es/core/Link/__stories__/DarkBackgroundNoUnderline.js +7 -5
  310. package/es/core/Link/__stories__/Default.js +5 -3
  311. package/es/core/Link/__stories__/NoUnderline.js +5 -3
  312. package/es/core/Link/link.mdx +34 -0
  313. package/es/core/List/index.mdx +22 -3
  314. package/es/core/Masthead/masthead.mdx +14 -0
  315. package/es/core/NavList/NavList.js +11 -64
  316. package/es/core/NavList/NavList.stories.js +7 -0
  317. package/es/core/NavList/NavListBase.js +60 -0
  318. package/es/core/NavList/NavListItem.js +3 -1
  319. package/es/core/NavList/NavListItemBase.js +7 -3
  320. package/es/core/NavList/NavListSubMenu.js +1 -1
  321. package/es/core/NavList/__stories__/Default.js +48 -0
  322. package/es/core/NavList/__stories__/NavHorizontalLayout.js +46 -0
  323. package/es/core/NavList/index.mdx +22 -1
  324. package/es/core/NavList/types.js +1 -0
  325. package/es/core/NotificationBanner/index.mdx +13 -60
  326. package/es/core/PhaseBanner/PhaseBanner.stories.js +2 -1
  327. package/es/core/PhaseBanner/__stories__/Underlined.js +14 -0
  328. package/es/core/PhaseBanner/index.mdx +24 -0
  329. package/es/core/Radios/__stories__/ConditionalReveal.js +5 -1
  330. package/es/core/Radios/__stories__/Default.js +1 -2
  331. package/es/core/Radios/__stories__/Inline.js +5 -1
  332. package/es/core/Radios/__stories__/MultipleQuestions.js +7 -3
  333. package/es/core/Radios/__stories__/WithErrorMessage.js +7 -1
  334. package/es/core/Radios/__stories__/WithHints.js +17 -7
  335. package/es/core/Radios/index.mdx +56 -0
  336. package/es/core/Select/Select.stories.js +2 -1
  337. package/es/core/Select/__stories__/Default.js +5 -4
  338. package/es/core/Select/__stories__/DisabledInput.js +5 -3
  339. package/es/core/Select/__stories__/WithHint.js +23 -0
  340. package/es/core/Select/index.mdx +42 -0
  341. package/es/core/SummaryList/SummaryList.stories.js +2 -2
  342. package/es/core/SummaryList/__stories__/Default.js +1 -1
  343. package/es/core/SummaryList/__stories__/WithActions.js +20 -0
  344. package/es/core/SummaryList/__stories__/WithoutBorders.js +11 -0
  345. package/es/core/SummaryList/index.mdx +17 -65
  346. package/es/core/Table/Table.stories.js +1 -0
  347. package/es/core/Table/__stories__/DarkVariant.js +1 -1
  348. package/es/core/Table/__stories__/Default.js +1 -1
  349. package/es/core/Table/__stories__/NoData.js +3 -1
  350. package/es/core/Table/__stories__/TableCaptions.js +17 -0
  351. package/es/core/Table/__stories__/WithLoader.js +12 -10
  352. package/es/core/Table/index.mdx +59 -0
  353. package/es/core/Tabs/__stories__/Default.js +3 -2
  354. package/es/core/Tabs/index.mdx +10 -2
  355. package/es/core/TextArea/index.mdx +50 -0
  356. package/es/core/TextInput/index.mdx +59 -0
  357. package/es/core/VisuallyHidden/__stories__/Default.js +9 -5
  358. package/es/core/VisuallyHidden/index.mdx +17 -0
  359. package/es/core/WarningText/index.mdx +10 -35
  360. package/es/govgr/Footer/index.mdx +4 -4
  361. package/es/introduction.md +4 -1
  362. package/es/layouts/Basic/Content/index.mdx +0 -12
  363. package/es/layouts/Basic/Main/index.mdx +0 -10
  364. package/es/layouts/Basic/Masthead/index.mdx +0 -12
  365. package/es/layouts/Basic/Side/index.mdx +0 -12
  366. package/es/layouts/Basic/Top/index.mdx +0 -12
  367. package/es/layouts/Basic/index.mdx +1 -15
  368. package/es/layouts/Grid/Grid.stories.js +2 -1
  369. package/es/layouts/Grid/__stories__/Default.js +26 -6
  370. package/es/layouts/Grid/__stories__/Inline.js +75 -0
  371. package/es/layouts/Grid/index.js +1 -0
  372. package/es/layouts/index.js +2 -0
  373. package/es/registry.js +66 -30
  374. package/es/test-utils/delay.js +6 -3
  375. package/es/typography/Caption/index.mdx +16 -0
  376. package/es/typography/Hint/index.mdx +16 -0
  377. package/es/typography/NormalText/index.mdx +26 -0
  378. package/es/typography/Paragraph/index.mdx +30 -0
  379. package/es/typography/Title/index.mdx +12 -0
  380. package/esm/admin/AutoComplete/AccesibleAutoComplete/index.js +87 -0
  381. package/esm/admin/AutoComplete/AutoComplete.stories.js +13 -0
  382. package/esm/admin/AutoComplete/Status/index.js +153 -0
  383. package/esm/admin/AutoComplete/__stories__/Default.js +19 -0
  384. package/esm/admin/AutoComplete/__stories__/WithAutoSelect.js +20 -0
  385. package/esm/admin/AutoComplete/__stories__/WithDefaultValue.js +18 -0
  386. package/esm/admin/AutoComplete/__stories__/WithInLine.js +18 -0
  387. package/esm/admin/AutoComplete/__stories__/WithMinLength.js +19 -0
  388. package/esm/admin/AutoComplete/__stories__/WithPlaceHolder.js +18 -0
  389. package/esm/admin/AutoComplete/__stories__/WithShowAllValues.js +18 -0
  390. package/esm/admin/AutoComplete/index.js +676 -0
  391. package/esm/admin/AutoComplete/index.mdx +46 -0
  392. package/esm/admin/AutoComplete/utils.js +6 -0
  393. package/esm/admin/CopyToClipboard/CopyToClipboard.stories.js +8 -0
  394. package/esm/admin/CopyToClipboard/__stories__/Banner.js +16 -0
  395. package/esm/admin/CopyToClipboard/__stories__/Default.js +18 -0
  396. package/{es/app/CopyToClipboard/__stories__/Default.js → esm/admin/CopyToClipboard/__stories__/MultipleCopies.js} +10 -8
  397. package/esm/admin/CopyToClipboard/index.js +3 -2
  398. package/esm/admin/CopyToClipboard/index.mdx +22 -0
  399. package/esm/admin/Drawer/__stories__/Default.js +1 -1
  400. package/esm/admin/Drawer/index.mdx +12 -0
  401. package/esm/admin/Dropdown/Dropdown.stories.js +9 -0
  402. package/esm/admin/Dropdown/__stories__/AlignRight.js +56 -0
  403. package/esm/admin/Dropdown/__stories__/Default.js +48 -0
  404. package/esm/admin/Dropdown/__stories__/PlacementTop.js +56 -0
  405. package/esm/admin/Dropdown/index.mdx +29 -0
  406. package/esm/admin/FilterSection/index.js +1 -0
  407. package/esm/admin/Modal/Modal.stories.js +7 -0
  408. package/esm/admin/Modal/__stories__/AlertDialog.js +58 -0
  409. package/esm/admin/Modal/__stories__/Default.js +56 -0
  410. package/esm/admin/Modal/index.mdx +26 -0
  411. package/esm/admin/Pagination/__stories__/Default.js +37 -14
  412. package/esm/admin/Pagination/index.mdx +12 -0
  413. package/esm/admin/TaskList/TaskList.stories.js +6 -0
  414. package/esm/admin/TaskList/__stories__/Default.js +74 -0
  415. package/esm/admin/TaskList/index.js +7 -0
  416. package/esm/admin/Timeline/Timeline.stories.js +6 -0
  417. package/esm/admin/Timeline/__stories__/Default.js +64 -0
  418. package/esm/admin/Timeline/index.js +7 -0
  419. package/esm/admin/index.js +5 -2
  420. package/esm/api/fetchAPI.js +6 -3
  421. package/esm/api/index.spec.js +19 -17
  422. package/esm/api/useResource.js +6 -3
  423. package/esm/api/useResourceAction.js +6 -3
  424. package/esm/api/useResourceQuery.js +6 -3
  425. package/esm/api/utils.js +8 -5
  426. package/esm/app/Confirmation/Confirmation.mdx +9 -0
  427. package/esm/app/Footer/Footer.mdx +27 -0
  428. package/esm/app/Header/index.mdx +18 -0
  429. package/esm/app/I18nText.js +7 -6
  430. package/esm/app/NotFound/index.mdx +12 -0
  431. package/esm/app/PhaseBannerHeader/index.mdx +12 -0
  432. package/esm/core/Accordion/__stories__/Default.js +17 -1
  433. package/esm/core/Accordion/__stories__/WithHints.js +17 -1
  434. package/esm/core/Accordion/index.mdx +16 -84
  435. package/esm/core/BackLink/index.mdx +16 -0
  436. package/esm/core/Blockquote/index.mdx +17 -2
  437. package/esm/core/Breadcrumbs/__stories__/Default.js +13 -1
  438. package/esm/core/Breadcrumbs/breadcrumbs.mdx +22 -0
  439. package/esm/core/Button/Button.stories.js +7 -1
  440. package/esm/core/Button/__stories__/Back.js +13 -0
  441. package/esm/core/Button/__stories__/ButtonLinkButton.js +17 -0
  442. package/esm/core/Button/__stories__/CallToActionButton.js +17 -0
  443. package/esm/core/Button/__stories__/Disabled.js +14 -0
  444. package/esm/core/Button/__stories__/GroupingButtonsAndLinks.js +3 -1
  445. package/esm/core/Button/__stories__/Primary.js +3 -1
  446. package/esm/core/Button/__stories__/Secondary.js +3 -2
  447. package/esm/core/Button/__stories__/Warning.js +2 -1
  448. package/esm/core/Button/__stories__/WithVariantLink.js +16 -0
  449. package/esm/core/Button/index.mdx +97 -0
  450. package/esm/core/Card/Card.stories.js +2 -1
  451. package/esm/core/Card/__stories__/WithClickableLink.js +2 -3
  452. package/esm/core/Card/__stories__/WithGroupButton.js +11 -0
  453. package/esm/core/Card/card.mdx +78 -0
  454. package/esm/core/Checkboxes/Checkbox.stories.js +1 -0
  455. package/esm/core/Checkboxes/__stories__/ConditionalReveal.js +5 -1
  456. package/esm/core/Checkboxes/__stories__/Default.js +5 -1
  457. package/esm/core/Checkboxes/__stories__/MultipleQuestions.js +6 -2
  458. package/esm/core/Checkboxes/__stories__/NoneAnswer.js +5 -1
  459. package/esm/core/Checkboxes/__stories__/NoneAnswerWithError.js +34 -0
  460. package/esm/core/Checkboxes/__stories__/WithErrorMessage.js +7 -1
  461. package/esm/core/Checkboxes/__stories__/WithHint.js +5 -1
  462. package/esm/core/Checkboxes/checkboxes.mdx +54 -0
  463. package/esm/core/Confirmation/confirmation.mdx +19 -0
  464. package/esm/core/DateInput/DateInput.stories.js +1 -0
  465. package/esm/core/DateInput/__stories__/Default.js +3 -1
  466. package/esm/core/DateInput/__stories__/MultipleQuestions.js +20 -0
  467. package/esm/core/DateInput/index.mdx +34 -0
  468. package/esm/core/Details/index.mdx +9 -25
  469. package/esm/core/ErrorMessage/__stories__/Default.js +1 -1
  470. package/esm/core/ErrorMessage/index.mdx +21 -0
  471. package/esm/core/ErrorSummary/__stories__/LinkedToCheckbox.js +1 -1
  472. package/esm/core/ErrorSummary/index.mdx +21 -38
  473. package/esm/core/FileUpload/__stories__/Default.js +2 -1
  474. package/esm/core/FileUpload/index.mdx +22 -0
  475. package/esm/core/Link/__stories__/DarkBackground.js +7 -5
  476. package/esm/core/Link/__stories__/DarkBackgroundNoUnderline.js +7 -5
  477. package/esm/core/Link/__stories__/Default.js +5 -3
  478. package/esm/core/Link/__stories__/NoUnderline.js +5 -3
  479. package/esm/core/Link/link.mdx +34 -0
  480. package/esm/core/List/index.mdx +22 -3
  481. package/esm/core/Masthead/masthead.mdx +14 -0
  482. package/esm/core/NavList/NavList.js +11 -64
  483. package/esm/core/NavList/NavList.stories.js +7 -0
  484. package/esm/core/NavList/NavListBase.js +60 -0
  485. package/esm/core/NavList/NavListItem.js +3 -1
  486. package/esm/core/NavList/NavListItemBase.js +7 -3
  487. package/esm/core/NavList/NavListSubMenu.js +1 -1
  488. package/esm/core/NavList/__stories__/Default.js +48 -0
  489. package/esm/core/NavList/__stories__/NavHorizontalLayout.js +46 -0
  490. package/esm/core/NavList/index.mdx +22 -1
  491. package/esm/core/NavList/types.js +1 -0
  492. package/esm/core/NotificationBanner/index.mdx +13 -60
  493. package/esm/core/PhaseBanner/PhaseBanner.stories.js +2 -1
  494. package/esm/core/PhaseBanner/__stories__/Underlined.js +14 -0
  495. package/esm/core/PhaseBanner/index.mdx +24 -0
  496. package/esm/core/Radios/__stories__/ConditionalReveal.js +5 -1
  497. package/esm/core/Radios/__stories__/Default.js +1 -2
  498. package/esm/core/Radios/__stories__/Inline.js +5 -1
  499. package/esm/core/Radios/__stories__/MultipleQuestions.js +7 -3
  500. package/esm/core/Radios/__stories__/WithErrorMessage.js +7 -1
  501. package/esm/core/Radios/__stories__/WithHints.js +17 -7
  502. package/esm/core/Radios/index.mdx +56 -0
  503. package/esm/core/Select/Select.stories.js +2 -1
  504. package/esm/core/Select/__stories__/Default.js +5 -4
  505. package/esm/core/Select/__stories__/DisabledInput.js +5 -3
  506. package/esm/core/Select/__stories__/WithHint.js +23 -0
  507. package/esm/core/Select/index.mdx +42 -0
  508. package/esm/core/SummaryList/SummaryList.stories.js +2 -2
  509. package/esm/core/SummaryList/__stories__/Default.js +1 -1
  510. package/esm/core/SummaryList/__stories__/WithActions.js +20 -0
  511. package/esm/core/SummaryList/__stories__/WithoutBorders.js +11 -0
  512. package/esm/core/SummaryList/index.mdx +17 -65
  513. package/esm/core/Table/Table.stories.js +1 -0
  514. package/esm/core/Table/__stories__/DarkVariant.js +1 -1
  515. package/esm/core/Table/__stories__/Default.js +1 -1
  516. package/esm/core/Table/__stories__/NoData.js +3 -1
  517. package/esm/core/Table/__stories__/TableCaptions.js +17 -0
  518. package/esm/core/Table/__stories__/WithLoader.js +12 -10
  519. package/esm/core/Table/index.mdx +59 -0
  520. package/esm/core/Tabs/__stories__/Default.js +3 -2
  521. package/esm/core/Tabs/index.mdx +10 -2
  522. package/esm/core/TextArea/index.mdx +50 -0
  523. package/esm/core/TextInput/index.mdx +59 -0
  524. package/esm/core/VisuallyHidden/__stories__/Default.js +9 -5
  525. package/esm/core/VisuallyHidden/index.mdx +17 -0
  526. package/esm/core/WarningText/index.mdx +10 -35
  527. package/esm/govgr/Footer/index.mdx +4 -4
  528. package/esm/index.js +1 -1
  529. package/esm/introduction.md +4 -1
  530. package/esm/layouts/Basic/Content/index.mdx +0 -12
  531. package/esm/layouts/Basic/Main/index.mdx +0 -10
  532. package/esm/layouts/Basic/Masthead/index.mdx +0 -12
  533. package/esm/layouts/Basic/Side/index.mdx +0 -12
  534. package/esm/layouts/Basic/Top/index.mdx +0 -12
  535. package/esm/layouts/Basic/index.mdx +1 -15
  536. package/esm/layouts/Grid/Grid.stories.js +2 -1
  537. package/esm/layouts/Grid/__stories__/Default.js +26 -6
  538. package/esm/layouts/Grid/__stories__/Inline.js +75 -0
  539. package/esm/layouts/Grid/index.js +1 -0
  540. package/esm/layouts/index.js +2 -0
  541. package/esm/registry.js +66 -30
  542. package/esm/test-utils/delay.js +6 -3
  543. package/esm/typography/Caption/index.mdx +16 -0
  544. package/esm/typography/Hint/index.mdx +16 -0
  545. package/esm/typography/NormalText/index.mdx +26 -0
  546. package/esm/typography/Paragraph/index.mdx +30 -0
  547. package/esm/typography/Title/index.mdx +12 -0
  548. package/govgr/Footer/index.mdx +4 -4
  549. package/introduction.md +4 -1
  550. package/layouts/Basic/Content/index.mdx +0 -12
  551. package/layouts/Basic/Main/index.mdx +0 -10
  552. package/layouts/Basic/Masthead/index.mdx +0 -12
  553. package/layouts/Basic/Side/index.mdx +0 -12
  554. package/layouts/Basic/Top/index.mdx +0 -12
  555. package/layouts/Basic/index.mdx +1 -15
  556. package/layouts/Grid/Grid.stories.d.ts +1 -0
  557. package/layouts/Grid/Grid.stories.js +14 -0
  558. package/layouts/Grid/__stories__/Default.js +26 -6
  559. package/layouts/Grid/__stories__/Inline.d.ts +3 -0
  560. package/layouts/Grid/__stories__/Inline.js +88 -0
  561. package/layouts/Grid/index.d.ts +1 -0
  562. package/layouts/Grid/index.js +6 -0
  563. package/layouts/index.d.ts +2 -0
  564. package/layouts/index.js +22 -1
  565. package/package.json +3 -3
  566. package/registry.d.ts +33 -15
  567. package/registry.js +99 -45
  568. package/test-utils/delay.js +5 -3
  569. package/typography/Caption/index.mdx +16 -0
  570. package/typography/Hint/index.mdx +16 -0
  571. package/typography/NormalText/index.mdx +26 -0
  572. package/typography/Paragraph/index.mdx +30 -0
  573. package/typography/Title/index.mdx +12 -0
  574. package/admin/CopyToClipboardMessage/index.d.ts +0 -3
  575. package/app/CopyToClipboard/CopyToClipboard.stories.d.ts +0 -7
  576. package/app/CopyToClipboard/index.d.ts +0 -9
  577. package/app/CopyToClipboard/index.js +0 -69
  578. package/app/NotFound/NotFound.mdx +0 -5
  579. package/app/QrCodeScanner/index.mdx +0 -7
  580. package/core/Button/Button.mdx +0 -55
  581. package/core/SummaryList/__stories__/SummaryListWithActions.d.ts +0 -3
  582. package/core/SummaryList/__stories__/SummaryListWithoutBorders.d.ts +0 -3
  583. package/es/admin/CopyToClipboardMessage/index.js +0 -3
  584. package/es/app/CopyToClipboard/CopyToClipboard.stories.js +0 -6
  585. package/es/app/CopyToClipboard/index.js +0 -45
  586. package/es/app/NotFound/NotFound.mdx +0 -5
  587. package/es/app/QrCodeScanner/index.mdx +0 -7
  588. package/es/core/Button/Button.mdx +0 -55
  589. package/es/core/SummaryList/__stories__/SummaryListWithActions.js +0 -21
  590. package/es/core/SummaryList/__stories__/SummaryListWithoutBorders.js +0 -11
  591. package/esm/admin/CopyToClipboardMessage/index.js +0 -3
  592. package/esm/app/CopyToClipboard/CopyToClipboard.stories.js +0 -6
  593. package/esm/app/CopyToClipboard/index.js +0 -45
  594. package/esm/app/NotFound/NotFound.mdx +0 -5
  595. package/esm/app/QrCodeScanner/index.mdx +0 -7
  596. package/esm/core/Button/Button.mdx +0 -55
  597. package/esm/core/SummaryList/__stories__/SummaryListWithActions.js +0 -21
  598. package/esm/core/SummaryList/__stories__/SummaryListWithoutBorders.js +0 -11
@@ -0,0 +1,3 @@
1
+ /// <reference types="react" />
2
+ export declare const MultipleQuestions: () => JSX.Element;
3
+ export default MultipleQuestions;
@@ -0,0 +1,41 @@
1
+ "use strict";
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+
5
+ var _typeof = require("@babel/runtime/helpers/typeof");
6
+
7
+ Object.defineProperty(exports, "__esModule", {
8
+ value: true
9
+ });
10
+ exports["default"] = exports.MultipleQuestions = void 0;
11
+
12
+ var _react = _interopRequireDefault(require("react"));
13
+
14
+ var _DateInput = _interopRequireWildcard(require("@digigov/ui/core/DateInput"));
15
+
16
+ var _Field = _interopRequireWildcard(require("@digigov/ui/core/Field"));
17
+
18
+ var _Hint = _interopRequireDefault(require("@digigov/ui/typography/Hint"));
19
+
20
+ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
21
+
22
+ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
23
+
24
+ var _ref = /*#__PURE__*/_react["default"].createElement(_Field["default"], null, /*#__PURE__*/_react["default"].createElement(_Field.Fieldset, null, /*#__PURE__*/_react["default"].createElement(_Field.FieldsetLegend, {
25
+ size: "m"
26
+ }, "\u03A0\u03CC\u03C4\u03B5 \u03B5\u03BA\u03B4\u03CC\u03B8\u03B7\u03BA\u03B5 \u03C4\u03BF \u03B4\u03B9\u03B1\u03B2\u03B1\u03C4\u03AE\u03C1\u03B9\u03BF \u03C3\u03B1\u03C2;"), /*#__PURE__*/_react["default"].createElement(_Hint["default"], null, "\u0393\u03B9\u03B1 \u03C0\u03B1\u03C1\u03AC\u03B4\u03B5\u03B9\u03B3\u03BC\u03B1, 05 11 2020"), /*#__PURE__*/_react["default"].createElement(_DateInput["default"], null, /*#__PURE__*/_react["default"].createElement(_DateInput.DateInputItem, {
27
+ name: "day"
28
+ }, "\u0397\u03BC\u03AD\u03C1\u03B1"), /*#__PURE__*/_react["default"].createElement(_DateInput.DateInputItem, {
29
+ name: "month"
30
+ }, "\u039C\u03AE\u03BD\u03B1\u03C2"), /*#__PURE__*/_react["default"].createElement(_DateInput.DateInputItem, {
31
+ width: 4,
32
+ name: "year"
33
+ }, "\u03A7\u03C1\u03CC\u03BD\u03BF\u03C2"))));
34
+
35
+ var MultipleQuestions = function MultipleQuestions() {
36
+ return _ref;
37
+ };
38
+
39
+ exports.MultipleQuestions = MultipleQuestions;
40
+ var _default = MultipleQuestions;
41
+ exports["default"] = _default;
@@ -0,0 +1,34 @@
1
+ ---
2
+ id: date-input
3
+ title: DateInput
4
+ ---
5
+
6
+
7
+ # DateInput
8
+
9
+
10
+
11
+
12
+
13
+ ```bash
14
+ import DateInput from '@digigov/ui/core/DateInput';
15
+ ```
16
+
17
+ ## How to use
18
+
19
+ <Story packageName="@digigov/ui" component="core/DateInput" story="Default.tsx" />
20
+
21
+ ### If you’re asking more than one question on the page
22
+
23
+ <Story packageName="@digigov/ui" component="core/DateInput" story="MultipleQuestions.tsx" />
24
+
25
+
26
+ ### Error message
27
+
28
+ If you’re highlighting the whole date, style all the fields like this:
29
+
30
+ <Story packageName="@digigov/ui" component="core/DateInput" story="WithErrorMessage.tsx" />
31
+
32
+ If you’re highlighting just one field - either the day, month or year - only style the field that has an error. The error message must say which field has an error, like this:
33
+
34
+ <Story packageName="@digigov/ui" component="core/DateInput" story="WithErrorMessageForSingleField.tsx" />
@@ -1,34 +1,18 @@
1
1
  ---
2
- parent: docs/ui/components
2
+ id: details
3
3
  title: Details
4
4
  ---
5
5
 
6
- ## Example
6
+ # Details
7
7
 
8
- ```jsx live
9
- <Details>
10
- <DetailsSummary>Help with nationality</DetailsSummary>
11
- <DetailsContent>
12
- We need to know your nationality so we can work out which elections you’re
13
- entitled to vote in. If you cannot provide your nationality, you’ll have to
14
- send copies of identity documents through the post.
15
- </DetailsContent>
16
- </Details>
17
- ```
8
+ The details component is a short link that shows more detailed help text when a user clicks on it.
9
+
18
10
 
19
- <br />
20
11
 
21
- ## When to use this component
12
+ ```bash
13
+ import Details from '@digigov/ui/core/Details';
14
+ ```
22
15
 
23
- Use the Details component to make a page easier to scan when it contains
24
- information that only some users will need.
16
+ ## How to use
25
17
 
26
- ## When not to use this component
27
-
28
- Do not use the Details component to hide information that the majority of
29
- your users should see.
30
-
31
- ## How it works
32
-
33
- The Details component is a short link that expands into a text including some
34
- extra information, when a user clicks on it.
18
+ <Story packageName="@digigov/ui" component="core/Details" story="Default.tsx" />
@@ -27,7 +27,7 @@ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj &&
27
27
 
28
28
  var _ref = /*#__PURE__*/_react["default"].createElement(_Field["default"], {
29
29
  error: true
30
- }, /*#__PURE__*/_react["default"].createElement(_Field.Fieldset, null, /*#__PURE__*/_react["default"].createElement(_Field.FieldsetLegend, null, "\u0398\u03B1 \u03C4\u03B1\u03BE\u03B9\u03B4\u03AD\u03C8\u03B5\u03C4\u03B5 \u03C3\u03B5 \u03BA\u03AC\u03C0\u03BF\u03B9\u03B1 \u03B1\u03C0\u03CC \u03B1\u03C5\u03C4\u03AD\u03C2 \u03C4\u03B9\u03C2 \u03C7\u03CE\u03C1\u03B5\u03C2;"), /*#__PURE__*/_react["default"].createElement(_Hint["default"], null, "\u0391\u03BD \u03AD\u03C7\u03B5\u03C4\u03B5 \u03C0\u03BF\u03BB\u03BB\u03B1\u03C0\u03BB\u03AE \u03C5\u03C0\u03B7\u03BA\u03BF\u03CC\u03C4\u03B7\u03C4\u03B1, \u03B5\u03C0\u03B9\u03BB\u03AD\u03BE\u03C4\u03B5 \u03CC,\u03C4\u03B9 \u03B9\u03C3\u03C7\u03CD\u03B5\u03B9."), /*#__PURE__*/_react["default"].createElement(_ErrorMessage["default"], null, /*#__PURE__*/_react["default"].createElement(_VisuallyHidden["default"], null, "\u039B\u03AC\u03B8\u03BF\u03C2:"), " \u0395\u03C0\u03B9\u03BB\u03AD\u03BE\u03C4\u03B5 \u03BC\u03AF\u03B1 \u03AE \u03C0\u03B1\u03C1\u03B1\u03C0\u03AC\u03BD\u03C9 \u03C7\u03CE\u03C1\u03B5\u03C2."), /*#__PURE__*/_react["default"].createElement(_Checkboxes["default"], null, /*#__PURE__*/_react["default"].createElement(_Checkboxes.CheckboxItem, {
30
+ }, /*#__PURE__*/_react["default"].createElement(_Field.Fieldset, null, /*#__PURE__*/_react["default"].createElement(_Field.FieldsetLegend, null, "\u0398\u03B1 \u03C4\u03B1\u03BE\u03B9\u03B4\u03AD\u03C8\u03B5\u03C4\u03B5 \u03C3\u03B5 \u03BA\u03AC\u03C0\u03BF\u03B9\u03B1 \u03B1\u03C0\u03CC \u03B1\u03C5\u03C4\u03AD\u03C2 \u03C4\u03B9\u03C2 \u03C7\u03CE\u03C1\u03B5\u03C2;"), /*#__PURE__*/_react["default"].createElement(_Hint["default"], null, "\u0391\u03BD \u03AD\u03C7\u03B5\u03C4\u03B5 \u03C0\u03BF\u03BB\u03BB\u03B1\u03C0\u03BB\u03AE \u03C5\u03C0\u03B7\u03BA\u03BF\u03CC\u03C4\u03B7\u03C4\u03B1, \u03B5\u03C0\u03B9\u03BB\u03AD\u03BE\u03C4\u03B5 \u03CC,\u03C4\u03B9 \u03B9\u03C3\u03C7\u03CD\u03B5\u03B9."), /*#__PURE__*/_react["default"].createElement(_ErrorMessage["default"], null, /*#__PURE__*/_react["default"].createElement(_VisuallyHidden["default"], null, "\u039B\u03AC\u03B8\u03BF\u03C2:"), "\u0395\u03C0\u03B9\u03BB\u03AD\u03BE\u03C4\u03B5 \u03BC\u03AF\u03B1 \u03AE \u03C0\u03B1\u03C1\u03B1\u03C0\u03AC\u03BD\u03C9 \u03C7\u03CE\u03C1\u03B5\u03C2."), /*#__PURE__*/_react["default"].createElement(_Checkboxes["default"], null, /*#__PURE__*/_react["default"].createElement(_Checkboxes.CheckboxItem, {
31
31
  name: "cold",
32
32
  value: "cold"
33
33
  }, "\u0391\u03B3\u03B3\u03BB\u03AF\u03B1"), /*#__PURE__*/_react["default"].createElement(_Checkboxes.CheckboxItem, {
@@ -0,0 +1,21 @@
1
+ ---
2
+ id: error-message
3
+ title: ErrorMessage
4
+ ---
5
+
6
+
7
+ # ErrorMessage
8
+
9
+ Follow the validation pattern and show an error message when there is a validation error.
10
+ In the error message explain what went wrong and how to fix it.
11
+
12
+
13
+
14
+ ```bash
15
+ import ErrorMessage from '@digigov/ui/core/ErrorMessage';
16
+ ```
17
+
18
+ ## How to use
19
+
20
+ <Story packageName="@digigov/ui" component="core/ErrorMessage" story="Default.tsx" />
21
+
@@ -36,7 +36,7 @@ var _ref = /*#__PURE__*/_react["default"].createElement("div", {
36
36
  }, /*#__PURE__*/_react["default"].createElement(_ErrorSummary["default"], null, /*#__PURE__*/_react["default"].createElement(_Title["default"], {
37
37
  size: "sm"
38
38
  }, "\u03A5\u03C0\u03AE\u03C1\u03BE\u03B5 \u03BA\u03AC\u03C0\u03BF\u03B9\u03BF \u03C0\u03C1\u03CC\u03B2\u03BB\u03B7\u03BC\u03B1"), /*#__PURE__*/_react["default"].createElement(_Link["default"], {
39
- href: "#thisone"
39
+ href: "#england"
40
40
  }, "\u0395\u03C0\u03B9\u03BB\u03AD\u03BE\u03C4\u03B5 \u03BC\u03AF\u03B1 \u03AE \u03C0\u03B1\u03C1\u03B1\u03C0\u03AC\u03BD\u03C9 \u03C7\u03CE\u03C1\u03B5\u03C2.")), /*#__PURE__*/_react["default"].createElement(_Field["default"], {
41
41
  error: true
42
42
  }, /*#__PURE__*/_react["default"].createElement(_Field.Fieldset, null, /*#__PURE__*/_react["default"].createElement(_Field.FieldsetLegend, null, "\u0398\u03B1 \u03C4\u03B1\u03BE\u03B9\u03B4\u03AD\u03C8\u03B5\u03C4\u03B5 \u03C3\u03B5 \u03BA\u03AC\u03C0\u03BF\u03B9\u03B1 \u03B1\u03C0\u03CC \u03B1\u03C5\u03C4\u03AD\u03C2 \u03C4\u03B9\u03C2 \u03C7\u03CE\u03C1\u03B5\u03C2;"), /*#__PURE__*/_react["default"].createElement(_Hint["default"], null, "\u0391\u03BD \u03AD\u03C7\u03B5\u03C4\u03B5 \u03C0\u03BF\u03BB\u03BB\u03B1\u03C0\u03BB\u03AE \u03C5\u03C0\u03B7\u03BA\u03BF\u03CC\u03C4\u03B7\u03C4\u03B1, \u03B5\u03C0\u03B9\u03BB\u03AD\u03BE\u03C4\u03B5 \u03CC,\u03C4\u03B9 \u03B9\u03C3\u03C7\u03CD\u03B5\u03B9."), /*#__PURE__*/_react["default"].createElement(_ErrorMessage["default"], null, /*#__PURE__*/_react["default"].createElement(_VisuallyHidden["default"], null, "\u039B\u03AC\u03B8\u03BF\u03C2:"), " \u0395\u03C0\u03B9\u03BB\u03AD\u03BE\u03C4\u03B5 \u03BC\u03AF\u03B1 \u03AE \u03C0\u03B1\u03C1\u03B1\u03C0\u03AC\u03BD\u03C9 \u03C7\u03CE\u03C1\u03B5\u03C2."), /*#__PURE__*/_react["default"].createElement(_Checkboxes["default"], null, /*#__PURE__*/_react["default"].createElement(_Checkboxes.CheckboxItem, {
@@ -1,59 +1,42 @@
1
1
  ---
2
- title: Error Summary
3
- parent: docs/ui/components
2
+ id: error-summary
3
+ title: ErrorSummary
4
4
  ---
5
5
 
6
- # Error Summary
7
6
 
8
- import ErrorSummary from '@digigov/ui/core/ErrorSummary';
7
+ # ErrorSummary
9
8
 
10
- ## Example
9
+ Use this component at the top of a page to summarise any errors a user has made.
11
10
 
12
- ```jsx live path=core/ErrorSummary/index.tsx
13
- import ErrorSummary from '@digigov/ui/core/ErrorSummary';
14
- import Paragraph from '@digigov/ui/typography/Paragraph';
15
- function CustomWarning (props){
16
- return (
17
- <ErrorSummary><Paragraph>Action Label</Paragraph></ErrorSummary>
18
- )
19
- }
20
- export CustomErrorSummary
11
+ When a user makes an error, you must show both an error summary and an error message next to each answer that contains an error.
12
+
21
13
 
22
- ```
23
14
 
24
- <br />
15
+ ```bash
16
+ import ErrorSummary from '@digigov/ui/core/ErrorSummary';
17
+ ```
18
+
19
+ ## How to use
25
20
 
26
- ## When to use this component
21
+ <Story packageName="@digigov/ui" component="core/ErrorSummary" story="Default.tsx" />
27
22
 
28
- Use this component at the top of a page to summarise any errors a user has
29
- made.
30
23
 
31
- When a user makes an error, you must show both an error summary and an error
32
- message next to each answer that contains an error.
24
+ ### Linking from the error summary to each answer
33
25
 
34
- ## How it works
26
+ You must link the errors in the error summary to the answer they relate to.
35
27
 
36
- You must:
28
+ For questions that require a user to answer using a single field, like a file upload, select, textarea, text input or character count, link to the field.
37
29
 
38
- - move keyboard focus to the error summary
39
- - include the heading "There is a problem"
40
- - link to each of the answers that have validation errors
41
- - make sure the error messages in the error summary are worded the same as
42
- those which appear next to the inputs with errors
30
+ <Story packageName="@digigov/ui" component="core/ErrorSummary" story="LinkedToInput.tsx" />
43
31
 
44
- As well as showing an error summary, follow the validation pattern - for
45
- example, by adding "Error: " to the beginning of the page `<title>` so screen
46
- readers read it out as soon as possible.
32
+ When a user has to enter their answer into multiple fields, such as the day, month and year fields in the date input component, link to the first field that contains an error.
47
33
 
48
- And make your error messages clear and concise.
34
+ If you do not know which field contains an error, link to the first field.
49
35
 
50
- ## API
36
+ <Story packageName="@digigov/ui" component="core/ErrorSummary" story="LinkedToField.tsx" />
51
37
 
52
- ### Properties
38
+ For questions that require a user to select one or more options from a list using radios or checkboxes, link to the first radio or checkbox.
53
39
 
54
- <PropsDoc data={ErrorSummary.__doc__} />
55
- <br />
40
+ <Story packageName="@digigov/ui" component="core/ErrorSummary" story="LinkedToCheckbox.tsx" />
56
41
 
57
- ### Styles
58
42
 
59
- <StylesDoc data={ErrorSummary.__doc__} />
@@ -1,2 +1,3 @@
1
1
  /// <reference types="react" />
2
2
  export declare const Default: () => JSX.Element;
3
+ export default Default;
@@ -7,7 +7,7 @@ var _typeof = require("@babel/runtime/helpers/typeof");
7
7
  Object.defineProperty(exports, "__esModule", {
8
8
  value: true
9
9
  });
10
- exports.Default = void 0;
10
+ exports["default"] = exports.Default = void 0;
11
11
 
12
12
  var _react = _interopRequireDefault(require("react"));
13
13
 
@@ -29,4 +29,6 @@ var Default = function Default() {
29
29
  return _ref;
30
30
  };
31
31
 
32
- exports.Default = Default;
32
+ exports.Default = Default;
33
+ var _default = Default;
34
+ exports["default"] = _default;
@@ -0,0 +1,22 @@
1
+ ---
2
+ id: file-upload
3
+ title: FileUpload
4
+ ---
5
+
6
+ # FileUpload
7
+
8
+
9
+
10
+ ```bash
11
+ import FileUpload from '@digigov/ui/core/FileUpload';
12
+ ```
13
+
14
+ ## How to use
15
+
16
+ <Story packageName="@digigov/ui" component="core/FileUpload" story="Default.tsx" />
17
+
18
+ ### Error message
19
+
20
+ Error messages should be styled like this:
21
+
22
+ <Story packageName="@digigov/ui" component="core/FileUpload" story="WithErrorMessage.tsx" />
@@ -13,11 +13,13 @@ var _Link = _interopRequireDefault(require("@digigov/ui/core/Link"));
13
13
 
14
14
  var _layouts = require("@digigov/ui/layouts");
15
15
 
16
- var _Divider = _interopRequireDefault(require("../../Divider"));
16
+ var _Divider = _interopRequireDefault(require("@digigov/ui/core/Divider"));
17
17
 
18
18
  var _ref = /*#__PURE__*/_react["default"].createElement(_layouts.Masthead, null, /*#__PURE__*/_react["default"].createElement(_Divider["default"], null), /*#__PURE__*/_react["default"].createElement(_Link["default"], {
19
+ "aria-label": "\u03C0\u03BB\u03BF\u03B7\u03B3\u03B7\u03B8\u03B5\u03AF\u03C4\u03B5 \u03C3\u03C4\u03B7\u03BD \u03B9\u03C3\u03C4\u03BF\u03C3\u03B5\u03BB\u03AF\u03B4\u03B1 \u03C4\u03BF govgr",
20
+ role: "link",
19
21
  href: "#"
20
- }, " govgr link "), /*#__PURE__*/_react["default"].createElement(_Divider["default"], null));
22
+ }, "govgr link"), /*#__PURE__*/_react["default"].createElement(_Divider["default"], null));
21
23
 
22
24
  var DarkBackground = function DarkBackground() {
23
25
  return _ref;
@@ -13,12 +13,14 @@ var _Link = _interopRequireDefault(require("@digigov/ui/core/Link"));
13
13
 
14
14
  var _layouts = require("@digigov/ui/layouts");
15
15
 
16
- var _Divider = _interopRequireDefault(require("../../Divider"));
16
+ var _Divider = _interopRequireDefault(require("@digigov/ui/core/Divider"));
17
17
 
18
18
  var _ref = /*#__PURE__*/_react["default"].createElement(_layouts.Masthead, null, /*#__PURE__*/_react["default"].createElement(_Divider["default"], null), /*#__PURE__*/_react["default"].createElement(_Link["default"], {
19
+ "aria-label": "\u03C0\u03BB\u03BF\u03B7\u03B3\u03B7\u03B8\u03B5\u03AF\u03C4\u03B5 \u03C3\u03C4\u03B7\u03BD \u03B9\u03C3\u03C4\u03BF\u03C3\u03B5\u03BB\u03AF\u03B4\u03B1 \u03C4\u03BF govgr",
20
+ role: "link",
19
21
  href: "#",
20
22
  underline: false
21
- }, " govgr link"), /*#__PURE__*/_react["default"].createElement(_Divider["default"], null));
23
+ }, "govgr link"), /*#__PURE__*/_react["default"].createElement(_Divider["default"], null));
22
24
 
23
25
  var DarkBackgroundNoUnderline = function DarkBackgroundNoUnderline() {
24
26
  return _ref;
@@ -12,8 +12,10 @@ var _react = _interopRequireDefault(require("react"));
12
12
  var _Link = _interopRequireDefault(require("@digigov/ui/core/Link"));
13
13
 
14
14
  var _ref = /*#__PURE__*/_react["default"].createElement(_Link["default"], {
15
+ "aria-label": "\u03C0\u03BB\u03BF\u03B7\u03B3\u03B7\u03B8\u03B5\u03AF\u03C4\u03B5 \u03C3\u03C4\u03B7\u03BD \u03B9\u03C3\u03C4\u03BF\u03C3\u03B5\u03BB\u03AF\u03B4\u03B1 \u03C4\u03BF govgr",
16
+ role: "link",
15
17
  href: "#"
16
- }, " govgr link ");
18
+ }, "govgr link");
17
19
 
18
20
  var Default = function Default() {
19
21
  return _ref;
@@ -12,9 +12,11 @@ var _react = _interopRequireDefault(require("react"));
12
12
  var _Link = _interopRequireDefault(require("@digigov/ui/core/Link"));
13
13
 
14
14
  var _ref = /*#__PURE__*/_react["default"].createElement(_Link["default"], {
15
+ "aria-label": "\u03C0\u03BB\u03BF\u03B7\u03B3\u03B7\u03B8\u03B5\u03AF\u03C4\u03B5 \u03C3\u03C4\u03B7\u03BD \u03B9\u03C3\u03C4\u03BF\u03C3\u03B5\u03BB\u03AF\u03B4\u03B1 \u03C4\u03BF govgr",
16
+ role: "link",
15
17
  href: "#",
16
18
  underline: false
17
- }, " govgr link ");
19
+ }, "govgr link");
18
20
 
19
21
  var NoUnderline = function NoUnderline() {
20
22
  return _ref;
@@ -0,0 +1,34 @@
1
+ ---
2
+ id: link
3
+ title: Link
4
+ ---
5
+
6
+ ```bash
7
+ import Link from '@digigov/ui/core/Link';
8
+ ```
9
+
10
+ ## How to use
11
+
12
+ ### Default
13
+
14
+ <Story packageName="@digigov/ui" component="core/Link" story="Default.tsx" />
15
+
16
+ ### No Underline
17
+
18
+ <Story packageName="@digigov/ui" component="core/Link" story="NoUnderline.tsx" />
19
+
20
+ ### Opens in a new tab
21
+
22
+ <Story packageName="@digigov/ui" component="core/Link" story="OpensInNewTab.tsx" />
23
+
24
+ ### At dark background
25
+
26
+ <Story packageName="@digigov/ui" component="core/Link" story="DarkBackground.tsx" />
27
+
28
+ ### At dark background and no underline
29
+
30
+ <Story packageName="@digigov/ui" component="core/Link" story="DarkBackgroundNoUnderline.tsx" />
31
+
32
+ You can read more about the accessibility patterns used in our Link
33
+ implementation in the ARIA Authoring Practices Guide (APG) at
34
+ [Link](https://www.w3.org/WAI/ARIA/apg/patterns/link/) section.
@@ -1,8 +1,27 @@
1
1
  ---
2
+ id: list
2
3
  title: List
3
- parent: docs/ui/components
4
4
  ---
5
5
 
6
- import List, { ListItem } from '@digigov/ui/core/List';
7
6
 
8
- ## Examples
7
+ ```bash
8
+ import List from '@digigov/ui/core/List';
9
+ ```
10
+
11
+ ## How to use
12
+
13
+ ### Default
14
+
15
+ <Story packageName="@digigov/ui" component="core/List" story="Default.tsx" />
16
+
17
+ ### List with bullets
18
+
19
+ <Story packageName="@digigov/ui" component="core/List" story="BulletList.tsx" />
20
+
21
+ ### List with numbers
22
+
23
+ <Story packageName="@digigov/ui" component="core/List" story="NumberedList.tsx" />
24
+
25
+ ### List with extra space
26
+
27
+ <Story packageName="@digigov/ui" component="core/List" story="WithExtraSpace.tsx" />
@@ -0,0 +1,14 @@
1
+ ---
2
+ id: masthead
3
+ title: Masthead
4
+ ---
5
+
6
+ # Masthead
7
+
8
+ ```bash
9
+ import Masthead from '@digigov/ui/core/Masthead';
10
+ ```
11
+
12
+ ## How to use
13
+
14
+ <Story packageName="@digigov/ui" component="core/Masthead" story="Default.tsx" />
@@ -1,17 +1,4 @@
1
1
  import React from 'react';
2
- import { NavLinkInterface } from '@digigov/ui/core/NavList/NavListContext';
3
- import { BaseCSSProperties } from '@material-ui/core/styles/withStyles';
4
- export declare const useNavListStyles: (props?: any) => import("@material-ui/core/styles/withStyles").ClassNameMap<"vertical" | "root" | "subMenu" | "floating" | "floatClear">;
5
- export interface NavListProps {
6
- children?: React.ReactNode;
7
- className?: string;
8
- horizontal?: boolean;
9
- openSubMenus?: boolean;
10
- floating?: boolean;
11
- subMenu?: boolean;
12
- links?: NavLinkInterface[];
13
- style?: BaseCSSProperties;
14
- }
15
- export declare const NavListBase: React.FC<NavListProps>;
2
+ import { NavListProps } from '@digigov/ui/core/NavList/types';
16
3
  export declare const NavList: React.FC<NavListProps>;
17
4
  export default NavList;
@@ -5,7 +5,7 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
5
5
  Object.defineProperty(exports, "__esModule", {
6
6
  value: true
7
7
  });
8
- exports.useNavListStyles = exports["default"] = exports.NavListBase = exports.NavList = void 0;
8
+ exports["default"] = exports.NavList = void 0;
9
9
 
10
10
  var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
11
11
 
@@ -13,84 +13,27 @@ var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/h
13
13
 
14
14
  var _react = _interopRequireDefault(require("react"));
15
15
 
16
- var _clsx = _interopRequireDefault(require("clsx"));
17
-
18
- var _styles = require("@material-ui/core/styles");
19
-
20
16
  var _NavListContext = require("@digigov/ui/core/NavList/NavListContext");
21
17
 
22
- var _excluded = ["className", "children", "floating", "horizontal", "subMenu"],
23
- _excluded2 = ["horizontal", "openSubMenus", "links"];
24
- var useNavListStyles = (0, _styles.makeStyles)(function (theme) {
25
- return {
26
- root: {
27
- padding: theme.spacing(0),
28
- margin: theme.spacing(0),
29
- display: 'flex',
30
- '&$vertical': {
31
- flexDirection: 'column'
32
- }
33
- },
34
- subMenu: {
35
- marginLeft: theme.spacing(3)
36
- },
37
- floating: {
38
- left: 0,
39
- zIndex: 99,
40
- position: 'absolute',
41
- background: theme.palette.grey['100'],
42
- borderTop: "1px solid ".concat(theme.palette.grey['500']),
43
- borderRight: "1px solid ".concat(theme.palette.grey['500']),
44
- borderLeft: "1px solid ".concat(theme.palette.grey['500']),
45
- margin: theme.spacing(1.5, 0, 0, 0),
46
- boxShadow: theme.shadows[3],
47
- '& > li': {
48
- width: '100%',
49
- borderBottom: "1px solid ".concat(theme.palette.grey['500']),
50
- margin: 0
51
- }
52
- },
53
- vertical: {},
54
- floatClear: {
55
- clear: 'both'
56
- }
57
- };
58
- }, {
59
- name: 'MuiNavList'
60
- });
61
- exports.useNavListStyles = useNavListStyles;
62
-
63
- var NavListBase = function NavListBase(_ref) {
64
- var className = _ref.className,
65
- children = _ref.children,
66
- floating = _ref.floating,
67
- horizontal = _ref.horizontal,
68
- subMenu = _ref.subMenu,
69
- props = (0, _objectWithoutProperties2["default"])(_ref, _excluded);
70
- var classes = useNavListStyles();
71
- return /*#__PURE__*/_react["default"].createElement("nav", null, /*#__PURE__*/_react["default"].createElement("ul", {
72
- style: props.style,
73
- className: (0, _clsx["default"])(className, classes.root, !horizontal && classes.vertical, floating && classes.floating, subMenu && classes.subMenu)
74
- }, children), /*#__PURE__*/_react["default"].createElement("div", {
75
- className: classes.floatClear
76
- }));
77
- };
18
+ var _NavListBase = require("@digigov/ui/core/NavList/NavListBase");
78
19
 
79
- exports.NavListBase = NavListBase;
20
+ var _excluded = ["horizontal", "openSubMenus", "links", "role"];
80
21
 
81
- var NavList = function NavList(_ref2) {
82
- var horizontal = _ref2.horizontal,
83
- _ref2$openSubMenus = _ref2.openSubMenus,
84
- openSubMenus = _ref2$openSubMenus === void 0 ? false : _ref2$openSubMenus,
85
- _ref2$links = _ref2.links,
86
- links = _ref2$links === void 0 ? [] : _ref2$links,
87
- props = (0, _objectWithoutProperties2["default"])(_ref2, _excluded2);
22
+ var NavList = function NavList(_ref) {
23
+ var horizontal = _ref.horizontal,
24
+ _ref$openSubMenus = _ref.openSubMenus,
25
+ openSubMenus = _ref$openSubMenus === void 0 ? false : _ref$openSubMenus,
26
+ _ref$links = _ref.links,
27
+ links = _ref$links === void 0 ? [] : _ref$links,
28
+ role = _ref.role,
29
+ props = (0, _objectWithoutProperties2["default"])(_ref, _excluded);
88
30
  return /*#__PURE__*/_react["default"].createElement(_NavListContext.NavListProvider, {
89
31
  openSubMenus: openSubMenus,
90
32
  horizontal: horizontal,
91
33
  links: links
92
- }, /*#__PURE__*/_react["default"].createElement(NavListBase, (0, _extends2["default"])({
93
- horizontal: horizontal
34
+ }, /*#__PURE__*/_react["default"].createElement(_NavListBase.NavListBase, (0, _extends2["default"])({
35
+ horizontal: horizontal,
36
+ role: role
94
37
  }, props)));
95
38
  };
96
39
 
@@ -0,0 +1,8 @@
1
+ declare namespace _default {
2
+ export const title: string;
3
+ export { NavList as component };
4
+ }
5
+ export default _default;
6
+ export * from "@digigov/ui/core/NavList/__stories__/Default";
7
+ export * from "@digigov/ui/core/NavList/__stories__/NavHorizontalLayout";
8
+ import NavList from "@digigov/ui/core/NavList";
@@ -0,0 +1,44 @@
1
+ "use strict";
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
7
+ });
8
+ var _exportNames = {};
9
+ exports["default"] = void 0;
10
+
11
+ var _NavList = _interopRequireDefault(require("@digigov/ui/core/NavList"));
12
+
13
+ var _Default = require("@digigov/ui/core/NavList/__stories__/Default");
14
+
15
+ Object.keys(_Default).forEach(function (key) {
16
+ if (key === "default" || key === "__esModule") return;
17
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
18
+ if (key in exports && exports[key] === _Default[key]) return;
19
+ Object.defineProperty(exports, key, {
20
+ enumerable: true,
21
+ get: function get() {
22
+ return _Default[key];
23
+ }
24
+ });
25
+ });
26
+
27
+ var _NavHorizontalLayout = require("@digigov/ui/core/NavList/__stories__/NavHorizontalLayout");
28
+
29
+ Object.keys(_NavHorizontalLayout).forEach(function (key) {
30
+ if (key === "default" || key === "__esModule") return;
31
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
32
+ if (key in exports && exports[key] === _NavHorizontalLayout[key]) return;
33
+ Object.defineProperty(exports, key, {
34
+ enumerable: true,
35
+ get: function get() {
36
+ return _NavHorizontalLayout[key];
37
+ }
38
+ });
39
+ });
40
+ var _default = {
41
+ title: 'Digigov UI/core/NavList',
42
+ component: _NavList["default"]
43
+ };
44
+ exports["default"] = _default;
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ import { NavListProps } from '@digigov/ui/core/NavList/types';
3
+ export declare const useNavListStyles: (props?: any) => import("@material-ui/core/styles/withStyles").ClassNameMap<"vertical" | "root" | "subMenu" | "floating" | "floatClear">;
4
+ export declare const NavListBase: React.FC<NavListProps>;