@digigov/ui 0.28.1 → 0.28.3

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 (704) hide show
  1. package/CHANGELOG.md +16 -1
  2. package/README.md +1 -0
  3. package/admin/AutoComplete/AutoComplete.stories.d.ts +1 -0
  4. package/admin/AutoComplete/AutoComplete.stories.js +2 -1
  5. package/admin/AutoComplete/Status/index.d.ts +2 -2
  6. package/admin/AutoComplete/Status/index.js +4 -4
  7. package/admin/AutoComplete/index.d.ts +2 -2
  8. package/admin/AutoComplete/index.mdx +4 -0
  9. package/admin/CircularProgress/CircularProgress.stories.d.ts +2 -0
  10. package/admin/CircularProgress/CircularProgress.stories.js +3 -2
  11. package/admin/CircularProgress/__stories__/Default.js +1 -3
  12. package/admin/CopyToClipboard/CopyToClipboard.stories.d.ts +1 -1
  13. package/admin/CopyToClipboard/CopyToClipboard.stories.js +2 -15
  14. package/admin/CopyToClipboard/index.mdx +2 -2
  15. package/admin/Drawer/Drawer.stories.d.ts +7 -1
  16. package/admin/Drawer/Drawer.stories.js +25 -3
  17. package/admin/Drawer/__stories__/Default.js +7 -46
  18. package/admin/Drawer/index.mdx +4 -0
  19. package/admin/Dropdown/Dropdown.stories.d.ts +3 -0
  20. package/admin/Dropdown/Dropdown.stories.js +4 -1
  21. package/admin/Dropdown/__stories__/AlignRight.js +4 -3
  22. package/admin/Dropdown/__stories__/Default.js +5 -3
  23. package/admin/Dropdown/__stories__/PlacementTop.js +4 -3
  24. package/admin/Dropdown/index.d.ts +3 -2
  25. package/admin/Dropdown/index.js +12 -4
  26. package/admin/Dropdown/index.mdx +4 -1
  27. package/admin/Modal/Modal.stories.d.ts +3 -0
  28. package/admin/Modal/Modal.stories.js +4 -1
  29. package/admin/Modal/__stories__/AlertDialog.js +11 -31
  30. package/admin/Modal/__stories__/Default.js +10 -26
  31. package/admin/Modal/index.d.ts +2 -2
  32. package/admin/Modal/index.js +5 -5
  33. package/admin/Modal/index.mdx +4 -8
  34. package/admin/Pagination/Pagination.stories.d.ts +4 -0
  35. package/admin/Pagination/Pagination.stories.js +18 -1
  36. package/admin/Pagination/__stories__/Default.js +1 -27
  37. package/admin/Pagination/__stories__/PaginationSmall.d.ts +2 -0
  38. package/admin/Pagination/__stories__/PaginationSmall.js +61 -0
  39. package/admin/Pagination/index.d.ts +3 -2
  40. package/admin/Pagination/index.js +12 -4
  41. package/admin/Pagination/index.mdx +4 -0
  42. package/admin/StepNav/StepNav.stories.d.ts +2 -0
  43. package/admin/StepNav/StepNav.stories.js +3 -1
  44. package/admin/TaskList/TaskList.stories.d.ts +2 -0
  45. package/admin/TaskList/TaskList.stories.js +3 -1
  46. package/admin/TaskList/__stories__/Default.js +2 -2
  47. package/admin/Timeline/Timeline.stories.d.ts +2 -0
  48. package/admin/Timeline/Timeline.stories.js +3 -1
  49. package/admin/Timeline/__stories__/Default.js +3 -1
  50. package/app/Confirmation/Confirmation.mdx +4 -0
  51. package/app/Confirmation/Confirmation.stories.d.ts +5 -1
  52. package/app/Confirmation/Confirmation.stories.js +6 -3
  53. package/app/Confirmation/index.d.ts +3 -3
  54. package/app/Confirmation/index.js +44 -15
  55. package/app/Footer/Footer.mdx +4 -0
  56. package/app/Footer/Footer.stories.d.ts +5 -0
  57. package/app/Footer/Footer.stories.js +6 -2
  58. package/app/Footer/index.d.ts +2 -0
  59. package/app/Footer/index.js +28 -2
  60. package/app/Header/Header.stories.d.ts +4 -0
  61. package/app/Header/Header.stories.js +4 -0
  62. package/app/Header/index.mdx +4 -0
  63. package/app/I18nText.js +1 -0
  64. package/app/NotFound/NotFound.stories.d.ts +1 -0
  65. package/app/NotFound/NotFound.stories.js +2 -1
  66. package/app/NotFound/index.mdx +4 -0
  67. package/app/PageTitle.d.ts +5 -9
  68. package/app/PageTitle.js +57 -61
  69. package/app/PhaseBannerHeader/PhaseBannerHeader.stories.d.ts +2 -0
  70. package/app/PhaseBannerHeader/PhaseBannerHeader.stories.js +3 -2
  71. package/app/PhaseBannerHeader/index.mdx +4 -0
  72. package/app/QrCodeScanner/QrCodeScanner.stories.d.ts +1 -0
  73. package/app/QrCodeScanner/QrCodeScanner.stories.js +2 -1
  74. package/app/QrCodeScanner/index.d.ts +8 -1
  75. package/app/QrCodeScanner/index.js +3 -5
  76. package/app/QrCodeViewer/QRCode.stories.d.ts +1 -0
  77. package/app/QrCodeViewer/QRCode.stories.js +2 -1
  78. package/app/QrCodeViewer/index.d.ts +5 -7
  79. package/app/QrCodeViewer/index.js +2 -70
  80. package/app/QrCodeViewer/index.mdx +4 -0
  81. package/app/QrCodeViewer/types.d.ts +0 -1
  82. package/app/index.d.ts +2 -0
  83. package/app/index.js +26 -0
  84. package/core/Accordion/Accordion.stories.d.ts +5 -0
  85. package/core/Accordion/Accordion.stories.js +6 -2
  86. package/core/Accordion/Accordion.stories.playwright.json +1 -7
  87. package/core/Accordion/__stories__/Default.js +3 -1
  88. package/core/Accordion/__stories__/WithHints.js +3 -1
  89. package/core/Accordion/index.d.ts +6 -0
  90. package/core/Accordion/index.js +85 -6
  91. package/core/Accordion/index.mdx +4 -0
  92. package/core/BackLink/BackLink.stories.d.ts +1 -0
  93. package/core/BackLink/BackLink.stories.js +2 -1
  94. package/core/BackLink/index.mdx +4 -0
  95. package/core/Blockquote/Blockquote.stories.d.ts +3 -0
  96. package/core/Blockquote/Blockquote.stories.js +4 -1
  97. package/core/Blockquote/index.mdx +4 -0
  98. package/core/Breadcrumbs/Breadcrumbs.stories.d.ts +3 -0
  99. package/core/Breadcrumbs/Breadcrumbs.stories.js +4 -1
  100. package/core/Breadcrumbs/breadcrumbs.mdx +4 -0
  101. package/core/Button/Button.stories.d.ts +3 -0
  102. package/core/Button/Button.stories.js +5 -2
  103. package/core/Button/index.mdx +4 -1
  104. package/core/Card/Card.stories.d.ts +4 -0
  105. package/core/Card/Card.stories.js +5 -1
  106. package/core/Card/__stories__/WithClickableContent.js +2 -2
  107. package/core/Card/card.mdx +4 -0
  108. package/core/Checkboxes/Checkbox.stories.d.ts +3 -0
  109. package/core/Checkboxes/Checkbox.stories.js +4 -1
  110. package/core/Checkboxes/__stories__/ConditionalReveal.js +1 -1
  111. package/core/Checkboxes/__stories__/NoneAnswerWithError.js +2 -2
  112. package/core/Checkboxes/checkboxes.mdx +4 -0
  113. package/core/DateInput/DateInput.stories.d.ts +3 -0
  114. package/core/DateInput/DateInput.stories.js +4 -1
  115. package/core/DateInput/index.d.ts +2 -2
  116. package/core/DateInput/index.js +5 -5
  117. package/core/DateInput/index.mdx +5 -0
  118. package/core/Details/Details.stories.d.ts +3 -0
  119. package/core/Details/Details.stories.js +4 -1
  120. package/core/Details/index.d.ts +3 -3
  121. package/core/Details/index.js +44 -21
  122. package/core/Details/index.mdx +4 -0
  123. package/core/Divider/Divider.stories.d.ts +1 -0
  124. package/core/Divider/Divider.stories.js +2 -1
  125. package/core/Divider/index.js +1 -0
  126. package/core/ErrorMessage/ErrorMessage.stories.d.ts +3 -0
  127. package/core/ErrorMessage/ErrorMessage.stories.js +4 -1
  128. package/core/ErrorMessage/index.mdx +4 -0
  129. package/core/ErrorSummary/ErrorSummary.stories.d.ts +3 -0
  130. package/core/ErrorSummary/ErrorSummary.stories.js +4 -1
  131. package/core/ErrorSummary/__stories__/LinkedToInput.js +2 -2
  132. package/core/ErrorSummary/index.d.ts +1 -1
  133. package/core/ErrorSummary/index.js +19 -8
  134. package/core/ErrorSummary/index.mdx +4 -0
  135. package/core/Field/index.d.ts +2 -2
  136. package/core/Field/index.js +5 -5
  137. package/core/FileUpload/FileUpload.stories.d.ts +2 -0
  138. package/core/FileUpload/FileUpload.stories.js +3 -1
  139. package/core/FileUpload/index.mdx +4 -1
  140. package/core/Label/index.d.ts +2 -2
  141. package/core/Label/index.js +5 -5
  142. package/core/Link/Link.stories.d.ts +2 -0
  143. package/core/Link/Link.stories.js +3 -1
  144. package/core/Link/index.d.ts +3 -3
  145. package/core/Link/index.js +15 -6
  146. package/core/Link/link.mdx +4 -0
  147. package/core/List/List.d.ts +1 -1
  148. package/core/List/List.js +19 -8
  149. package/core/List/List.stories.d.ts +4 -0
  150. package/core/List/List.stories.js +5 -2
  151. package/core/List/index.mdx +4 -0
  152. package/core/Masthead/Masthead.stories.d.ts +4 -0
  153. package/core/Masthead/Masthead.stories.js +5 -1
  154. package/core/Masthead/masthead.mdx +4 -0
  155. package/core/NavList/NavList.stories.d.ts +3 -0
  156. package/core/NavList/NavList.stories.js +4 -1
  157. package/core/NavList/index.d.ts +3 -1
  158. package/core/NavList/index.js +26 -8
  159. package/core/NavList/index.mdx +4 -0
  160. package/core/NotificationBanner/NotificationBanner.stories.d.ts +4 -0
  161. package/core/NotificationBanner/NotificationBanner.stories.js +5 -1
  162. package/core/NotificationBanner/index.d.ts +3 -3
  163. package/core/NotificationBanner/index.js +8 -2
  164. package/core/NotificationBanner/index.mdx +4 -0
  165. package/core/PhaseBanner/PhaseBanner.stories.d.ts +3 -0
  166. package/core/PhaseBanner/PhaseBanner.stories.js +4 -1
  167. package/core/PhaseBanner/index.mdx +4 -0
  168. package/core/Radios/Radios.stories.d.ts +3 -0
  169. package/core/Radios/Radios.stories.js +4 -1
  170. package/core/Radios/__stories__/ConditionalReveal.js +1 -1
  171. package/core/Radios/index.d.ts +2 -2
  172. package/core/Radios/index.js +5 -5
  173. package/core/Radios/index.mdx +14 -0
  174. package/core/Select/Select.stories.d.ts +3 -0
  175. package/core/Select/Select.stories.js +4 -1
  176. package/core/Select/__stories__/Default.js +2 -2
  177. package/core/Select/__stories__/DisabledInput.js +2 -2
  178. package/core/Select/__stories__/WithHint.js +2 -2
  179. package/core/Select/index.d.ts +2 -2
  180. package/core/Select/index.js +5 -5
  181. package/core/Select/index.mdx +4 -0
  182. package/core/SummaryList/SummaryList.stories.d.ts +4 -0
  183. package/core/SummaryList/SummaryList.stories.js +5 -2
  184. package/core/SummaryList/index.mdx +4 -0
  185. package/core/Table/Table.stories.d.ts +4 -0
  186. package/core/Table/Table.stories.js +5 -2
  187. package/core/Table/__stories__/WithFloatingScroll.js +1 -27
  188. package/core/Table/index.d.ts +2 -0
  189. package/core/Table/index.js +23 -2
  190. package/core/Table/index.mdx +4 -1
  191. package/core/Tabs/Tabs.stories.d.ts +5 -0
  192. package/core/Tabs/Tabs.stories.js +6 -2
  193. package/core/Tabs/index.d.ts +5 -5
  194. package/core/Tabs/index.js +74 -36
  195. package/core/Tabs/index.mdx +4 -0
  196. package/core/TextArea/TextArea.stories.d.ts +3 -0
  197. package/core/TextArea/TextArea.stories.js +4 -1
  198. package/core/TextArea/__stories__/Default.js +2 -2
  199. package/core/TextArea/__stories__/DisabledInput.js +2 -2
  200. package/core/TextArea/__stories__/LimitedCharacters.js +2 -2
  201. package/core/TextArea/__stories__/MultipleQuestions.js +2 -2
  202. package/core/TextArea/__stories__/WithDeclaredRows.js +2 -2
  203. package/core/TextArea/__stories__/WithErrorMessage.js +2 -2
  204. package/core/TextArea/__stories__/WithHint.js +2 -2
  205. package/core/TextArea/index.mdx +4 -0
  206. package/core/TextInput/TextInput.stories.d.ts +3 -0
  207. package/core/TextInput/TextInput.stories.js +4 -1
  208. package/core/TextInput/__stories__/AskingForNumbers.js +2 -2
  209. package/core/TextInput/__stories__/Default.js +2 -2
  210. package/core/TextInput/__stories__/DisabledInput.js +2 -2
  211. package/core/TextInput/__stories__/FixedWidths.js +7 -7
  212. package/core/TextInput/__stories__/FluidWidths.js +7 -7
  213. package/core/TextInput/__stories__/MultipleQuestions.js +2 -2
  214. package/core/TextInput/__stories__/WithErrorMessage.js +2 -2
  215. package/core/TextInput/__stories__/WithHint.js +2 -2
  216. package/core/TextInput/index.mdx +4 -0
  217. package/core/VisuallyHidden/VisuallyHidden.stories.d.ts +1 -0
  218. package/core/VisuallyHidden/VisuallyHidden.stories.js +2 -1
  219. package/core/VisuallyHidden/index.mdx +4 -1
  220. package/core/WarningText/WarningText.stories.d.ts +4 -0
  221. package/core/WarningText/WarningText.stories.js +5 -2
  222. package/core/WarningText/index.d.ts +1 -1
  223. package/core/WarningText/index.js +19 -8
  224. package/core/WarningText/index.mdx +4 -0
  225. package/core/index.d.ts +8 -5
  226. package/core/index.js +74 -65
  227. package/es/admin/AutoComplete/AutoComplete.stories.js +2 -1
  228. package/es/admin/AutoComplete/Status/index.js +4 -4
  229. package/es/admin/AutoComplete/index.mdx +4 -0
  230. package/es/admin/CircularProgress/CircularProgress.stories.js +3 -2
  231. package/es/admin/CircularProgress/__stories__/Default.js +1 -2
  232. package/es/admin/CopyToClipboard/CopyToClipboard.stories.js +3 -3
  233. package/es/admin/CopyToClipboard/index.mdx +2 -2
  234. package/es/admin/Drawer/Drawer.stories.js +8 -2
  235. package/es/admin/Drawer/__stories__/Default.js +8 -47
  236. package/es/admin/Drawer/index.mdx +4 -0
  237. package/es/admin/Dropdown/Dropdown.stories.js +4 -1
  238. package/es/admin/Dropdown/__stories__/AlignRight.js +4 -3
  239. package/es/admin/Dropdown/__stories__/Default.js +5 -3
  240. package/es/admin/Dropdown/__stories__/PlacementTop.js +4 -3
  241. package/es/admin/Dropdown/index.js +3 -2
  242. package/es/admin/Dropdown/index.mdx +4 -1
  243. package/es/admin/Modal/Modal.stories.js +4 -1
  244. package/es/admin/Modal/__stories__/AlertDialog.js +12 -31
  245. package/es/admin/Modal/__stories__/Default.js +11 -26
  246. package/es/admin/Modal/index.js +2 -2
  247. package/es/admin/Modal/index.mdx +4 -8
  248. package/es/admin/Pagination/Pagination.stories.js +6 -2
  249. package/es/admin/Pagination/__stories__/Default.js +1 -27
  250. package/es/admin/Pagination/__stories__/PaginationSmall.js +38 -0
  251. package/es/admin/Pagination/index.js +3 -2
  252. package/es/admin/Pagination/index.mdx +4 -0
  253. package/es/admin/StepNav/StepNav.stories.js +3 -1
  254. package/es/admin/TaskList/TaskList.stories.js +3 -1
  255. package/es/admin/TaskList/__stories__/Default.js +2 -2
  256. package/es/admin/Timeline/Timeline.stories.js +3 -1
  257. package/es/admin/Timeline/__stories__/Default.js +3 -2
  258. package/es/app/Confirmation/Confirmation.mdx +4 -0
  259. package/es/app/Confirmation/Confirmation.stories.js +6 -3
  260. package/es/app/Confirmation/index.js +4 -4
  261. package/es/app/Footer/Footer.mdx +4 -0
  262. package/es/app/Footer/Footer.stories.js +6 -2
  263. package/es/app/Footer/index.js +3 -1
  264. package/es/app/Header/Header.stories.js +4 -0
  265. package/es/app/Header/index.mdx +4 -0
  266. package/es/app/I18nText.js +1 -0
  267. package/es/app/NotFound/NotFound.stories.js +2 -1
  268. package/es/app/NotFound/index.mdx +4 -0
  269. package/es/app/PageTitle.js +6 -57
  270. package/es/app/PhaseBannerHeader/PhaseBannerHeader.stories.js +3 -2
  271. package/es/app/PhaseBannerHeader/index.mdx +4 -0
  272. package/es/app/QrCodeScanner/QrCodeScanner.stories.js +2 -1
  273. package/es/app/QrCodeScanner/index.js +3 -5
  274. package/es/app/QrCodeViewer/QRCode.stories.js +2 -1
  275. package/es/app/QrCodeViewer/index.js +2 -69
  276. package/es/app/QrCodeViewer/index.mdx +4 -0
  277. package/es/app/index.js +2 -0
  278. package/es/core/Accordion/Accordion.stories.js +6 -2
  279. package/es/core/Accordion/Accordion.stories.playwright.json +1 -7
  280. package/es/core/Accordion/__stories__/Default.js +3 -1
  281. package/es/core/Accordion/__stories__/WithHints.js +3 -1
  282. package/es/core/Accordion/index.js +6 -0
  283. package/es/core/Accordion/index.mdx +4 -0
  284. package/es/core/BackLink/BackLink.stories.js +2 -1
  285. package/es/core/BackLink/index.mdx +4 -0
  286. package/es/core/Blockquote/Blockquote.stories.js +4 -1
  287. package/es/core/Blockquote/index.mdx +4 -0
  288. package/es/core/Breadcrumbs/Breadcrumbs.stories.js +4 -1
  289. package/es/core/Breadcrumbs/breadcrumbs.mdx +4 -0
  290. package/es/core/Button/Button.stories.js +5 -2
  291. package/es/core/Button/index.mdx +4 -1
  292. package/es/core/Card/Card.stories.js +5 -1
  293. package/es/core/Card/__stories__/WithClickableContent.js +2 -2
  294. package/es/core/Card/card.mdx +4 -0
  295. package/es/core/Checkboxes/Checkbox.stories.js +4 -1
  296. package/es/core/Checkboxes/__stories__/ConditionalReveal.js +1 -1
  297. package/es/core/Checkboxes/__stories__/NoneAnswerWithError.js +2 -2
  298. package/es/core/Checkboxes/checkboxes.mdx +4 -0
  299. package/es/core/DateInput/DateInput.stories.js +4 -1
  300. package/es/core/DateInput/index.js +2 -2
  301. package/es/core/DateInput/index.mdx +5 -0
  302. package/es/core/Details/Details.stories.js +4 -1
  303. package/es/core/Details/index.js +3 -3
  304. package/es/core/Details/index.mdx +4 -0
  305. package/es/core/Divider/Divider.stories.js +2 -1
  306. package/es/core/Divider/index.js +1 -0
  307. package/es/core/ErrorMessage/ErrorMessage.stories.js +4 -1
  308. package/es/core/ErrorMessage/index.mdx +4 -0
  309. package/es/core/ErrorSummary/ErrorSummary.stories.js +4 -1
  310. package/es/core/ErrorSummary/__stories__/LinkedToInput.js +4 -4
  311. package/es/core/ErrorSummary/index.js +1 -1
  312. package/es/core/ErrorSummary/index.mdx +4 -0
  313. package/es/core/Field/index.js +2 -2
  314. package/es/core/FileUpload/FileUpload.stories.js +3 -1
  315. package/es/core/FileUpload/index.mdx +4 -1
  316. package/es/core/Label/index.js +2 -2
  317. package/es/core/Link/Link.stories.js +3 -1
  318. package/es/core/Link/index.js +8 -6
  319. package/es/core/Link/link.mdx +4 -0
  320. package/es/core/List/List.js +1 -1
  321. package/es/core/List/List.stories.js +5 -2
  322. package/es/core/List/index.mdx +4 -0
  323. package/es/core/Masthead/Masthead.stories.js +5 -1
  324. package/es/core/Masthead/masthead.mdx +4 -0
  325. package/es/core/NavList/NavList.stories.js +4 -1
  326. package/es/core/NavList/index.js +4 -2
  327. package/es/core/NavList/index.mdx +4 -0
  328. package/es/core/NotificationBanner/NotificationBanner.stories.js +5 -1
  329. package/es/core/NotificationBanner/index.js +3 -3
  330. package/es/core/NotificationBanner/index.mdx +4 -0
  331. package/es/core/PhaseBanner/PhaseBanner.stories.js +4 -1
  332. package/es/core/PhaseBanner/index.mdx +4 -0
  333. package/es/core/Radios/Radios.stories.js +4 -1
  334. package/es/core/Radios/__stories__/ConditionalReveal.js +1 -1
  335. package/es/core/Radios/index.js +2 -2
  336. package/es/core/Radios/index.mdx +14 -0
  337. package/es/core/Select/Select.stories.js +4 -1
  338. package/es/core/Select/__stories__/Default.js +2 -2
  339. package/es/core/Select/__stories__/DisabledInput.js +2 -2
  340. package/es/core/Select/__stories__/WithHint.js +2 -2
  341. package/es/core/Select/index.js +2 -2
  342. package/es/core/Select/index.mdx +4 -0
  343. package/es/core/SummaryList/SummaryList.stories.js +5 -2
  344. package/es/core/SummaryList/index.mdx +4 -0
  345. package/es/core/Table/Table.stories.js +5 -2
  346. package/es/core/Table/__stories__/WithFloatingScroll.js +1 -27
  347. package/es/core/Table/index.js +3 -1
  348. package/es/core/Table/index.mdx +4 -1
  349. package/es/core/Tabs/Tabs.stories.js +6 -2
  350. package/es/core/Tabs/index.js +5 -5
  351. package/es/core/Tabs/index.mdx +4 -0
  352. package/es/core/TextArea/TextArea.stories.js +4 -1
  353. package/es/core/TextArea/__stories__/Default.js +4 -4
  354. package/es/core/TextArea/__stories__/DisabledInput.js +4 -4
  355. package/es/core/TextArea/__stories__/LimitedCharacters.js +4 -4
  356. package/es/core/TextArea/__stories__/MultipleQuestions.js +4 -4
  357. package/es/core/TextArea/__stories__/WithDeclaredRows.js +4 -4
  358. package/es/core/TextArea/__stories__/WithErrorMessage.js +4 -4
  359. package/es/core/TextArea/__stories__/WithHint.js +4 -4
  360. package/es/core/TextArea/index.mdx +4 -0
  361. package/es/core/TextInput/TextInput.stories.js +4 -1
  362. package/es/core/TextInput/__stories__/AskingForNumbers.js +4 -4
  363. package/es/core/TextInput/__stories__/Default.js +4 -4
  364. package/es/core/TextInput/__stories__/DisabledInput.js +4 -4
  365. package/es/core/TextInput/__stories__/FixedWidths.js +9 -9
  366. package/es/core/TextInput/__stories__/FluidWidths.js +9 -9
  367. package/es/core/TextInput/__stories__/MultipleQuestions.js +4 -4
  368. package/es/core/TextInput/__stories__/WithErrorMessage.js +5 -5
  369. package/es/core/TextInput/__stories__/WithHint.js +4 -4
  370. package/es/core/TextInput/index.mdx +4 -0
  371. package/es/core/VisuallyHidden/VisuallyHidden.stories.js +2 -1
  372. package/es/core/VisuallyHidden/index.mdx +4 -1
  373. package/es/core/WarningText/WarningText.stories.js +5 -2
  374. package/es/core/WarningText/index.js +1 -1
  375. package/es/core/WarningText/index.mdx +4 -0
  376. package/es/core/index.js +8 -5
  377. package/es/govgr/Footer/Copyright.js +3 -2
  378. package/es/govgr/Footer/index.mdx +4 -0
  379. package/es/index.js +2 -1
  380. package/es/layouts/Basic/Basic.stories.js +3 -1
  381. package/es/layouts/Basic/Bottom/index.js +1 -1
  382. package/es/layouts/Basic/Bottom/index.mdx +4 -0
  383. package/es/layouts/Basic/Main/index.js +1 -1
  384. package/es/layouts/Basic/Main/index.mdx +4 -0
  385. package/es/layouts/Basic/Masthead/index.js +2 -2
  386. package/es/layouts/Basic/Masthead/index.mdx +4 -0
  387. package/es/layouts/Basic/Top/index.js +2 -10
  388. package/es/layouts/Basic/Top/index.mdx +4 -0
  389. package/es/layouts/Basic/index.js +5 -3
  390. package/es/layouts/Basic/index.mdx +0 -6
  391. package/es/layouts/Grid/Grid.stories.js +3 -2
  392. package/es/layouts/Grid/__stories__/Default.js +2 -6
  393. package/es/registry.js +116 -2
  394. package/es/typography/Heading/Heading.stories.js +2 -1
  395. package/es/typography/Heading/index.js +1 -1
  396. package/es/typography/Heading/index.mdx +4 -0
  397. package/es/typography/HeadingCaption/HeadingCaption.stories.js +2 -1
  398. package/es/typography/HeadingCaption/index.js +1 -1
  399. package/es/typography/HeadingCaption/index.mdx +4 -1
  400. package/es/typography/Hint/Hint.stories.js +2 -1
  401. package/es/typography/Hint/index.mdx +4 -1
  402. package/es/typography/NormalText/NormalText.stories.js +2 -1
  403. package/es/typography/NormalText/index.mdx +4 -1
  404. package/es/typography/Paragraph/Paragraph.stories.js +2 -1
  405. package/es/typography/Paragraph/index.mdx +4 -1
  406. package/es/typography/index.js +2 -4
  407. package/es/utils/Kitchensink/AllComponents.js +11 -0
  408. package/es/utils/Kitchensink/KitchensinkByCategory.js +42 -0
  409. package/es/utils/Kitchensink/KitchensinkByLetter.js +20 -0
  410. package/es/utils/Kitchensink/KitchensinkComponent.js +51 -0
  411. package/es/utils/Kitchensink/KitchensinkDashboard.js +50 -0
  412. package/es/utils/withDeprecation.js +15 -12
  413. package/esm/admin/AutoComplete/AutoComplete.stories.js +2 -1
  414. package/esm/admin/AutoComplete/Status/index.js +4 -4
  415. package/esm/admin/AutoComplete/index.mdx +4 -0
  416. package/esm/admin/CircularProgress/CircularProgress.stories.js +3 -2
  417. package/esm/admin/CircularProgress/__stories__/Default.js +1 -2
  418. package/esm/admin/CopyToClipboard/CopyToClipboard.stories.js +3 -3
  419. package/esm/admin/CopyToClipboard/index.mdx +2 -2
  420. package/esm/admin/Drawer/Drawer.stories.js +8 -2
  421. package/esm/admin/Drawer/__stories__/Default.js +8 -47
  422. package/esm/admin/Drawer/index.mdx +4 -0
  423. package/esm/admin/Dropdown/Dropdown.stories.js +4 -1
  424. package/esm/admin/Dropdown/__stories__/AlignRight.js +4 -3
  425. package/esm/admin/Dropdown/__stories__/Default.js +5 -3
  426. package/esm/admin/Dropdown/__stories__/PlacementTop.js +4 -3
  427. package/esm/admin/Dropdown/index.js +3 -2
  428. package/esm/admin/Dropdown/index.mdx +4 -1
  429. package/esm/admin/Modal/Modal.stories.js +4 -1
  430. package/esm/admin/Modal/__stories__/AlertDialog.js +12 -31
  431. package/esm/admin/Modal/__stories__/Default.js +11 -26
  432. package/esm/admin/Modal/index.js +2 -2
  433. package/esm/admin/Modal/index.mdx +4 -8
  434. package/esm/admin/Pagination/Pagination.stories.js +6 -2
  435. package/esm/admin/Pagination/__stories__/Default.js +1 -27
  436. package/esm/admin/Pagination/__stories__/PaginationSmall.js +38 -0
  437. package/esm/admin/Pagination/index.js +3 -2
  438. package/esm/admin/Pagination/index.mdx +4 -0
  439. package/esm/admin/StepNav/StepNav.stories.js +3 -1
  440. package/esm/admin/TaskList/TaskList.stories.js +3 -1
  441. package/esm/admin/TaskList/__stories__/Default.js +2 -2
  442. package/esm/admin/Timeline/Timeline.stories.js +3 -1
  443. package/esm/admin/Timeline/__stories__/Default.js +3 -2
  444. package/esm/app/Confirmation/Confirmation.mdx +4 -0
  445. package/esm/app/Confirmation/Confirmation.stories.js +6 -3
  446. package/esm/app/Confirmation/index.js +4 -4
  447. package/esm/app/Footer/Footer.mdx +4 -0
  448. package/esm/app/Footer/Footer.stories.js +6 -2
  449. package/esm/app/Footer/index.js +3 -1
  450. package/esm/app/Header/Header.stories.js +4 -0
  451. package/esm/app/Header/index.mdx +4 -0
  452. package/esm/app/I18nText.js +1 -0
  453. package/esm/app/NotFound/NotFound.stories.js +2 -1
  454. package/esm/app/NotFound/index.mdx +4 -0
  455. package/esm/app/PageTitle.js +6 -57
  456. package/esm/app/PhaseBannerHeader/PhaseBannerHeader.stories.js +3 -2
  457. package/esm/app/PhaseBannerHeader/index.mdx +4 -0
  458. package/esm/app/QrCodeScanner/QrCodeScanner.stories.js +2 -1
  459. package/esm/app/QrCodeScanner/index.js +3 -5
  460. package/esm/app/QrCodeViewer/QRCode.stories.js +2 -1
  461. package/esm/app/QrCodeViewer/index.js +2 -69
  462. package/esm/app/QrCodeViewer/index.mdx +4 -0
  463. package/esm/app/index.js +2 -0
  464. package/esm/core/Accordion/Accordion.stories.js +6 -2
  465. package/esm/core/Accordion/Accordion.stories.playwright.json +1 -7
  466. package/esm/core/Accordion/__stories__/Default.js +3 -1
  467. package/esm/core/Accordion/__stories__/WithHints.js +3 -1
  468. package/esm/core/Accordion/index.js +6 -0
  469. package/esm/core/Accordion/index.mdx +4 -0
  470. package/esm/core/BackLink/BackLink.stories.js +2 -1
  471. package/esm/core/BackLink/index.mdx +4 -0
  472. package/esm/core/Blockquote/Blockquote.stories.js +4 -1
  473. package/esm/core/Blockquote/index.mdx +4 -0
  474. package/esm/core/Breadcrumbs/Breadcrumbs.stories.js +4 -1
  475. package/esm/core/Breadcrumbs/breadcrumbs.mdx +4 -0
  476. package/esm/core/Button/Button.stories.js +5 -2
  477. package/esm/core/Button/index.mdx +4 -1
  478. package/esm/core/Card/Card.stories.js +5 -1
  479. package/esm/core/Card/__stories__/WithClickableContent.js +2 -2
  480. package/esm/core/Card/card.mdx +4 -0
  481. package/esm/core/Checkboxes/Checkbox.stories.js +4 -1
  482. package/esm/core/Checkboxes/__stories__/ConditionalReveal.js +1 -1
  483. package/esm/core/Checkboxes/__stories__/NoneAnswerWithError.js +2 -2
  484. package/esm/core/Checkboxes/checkboxes.mdx +4 -0
  485. package/esm/core/DateInput/DateInput.stories.js +4 -1
  486. package/esm/core/DateInput/index.js +2 -2
  487. package/esm/core/DateInput/index.mdx +5 -0
  488. package/esm/core/Details/Details.stories.js +4 -1
  489. package/esm/core/Details/index.js +3 -3
  490. package/esm/core/Details/index.mdx +4 -0
  491. package/esm/core/Divider/Divider.stories.js +2 -1
  492. package/esm/core/Divider/index.js +1 -0
  493. package/esm/core/ErrorMessage/ErrorMessage.stories.js +4 -1
  494. package/esm/core/ErrorMessage/index.mdx +4 -0
  495. package/esm/core/ErrorSummary/ErrorSummary.stories.js +4 -1
  496. package/esm/core/ErrorSummary/__stories__/LinkedToInput.js +4 -4
  497. package/esm/core/ErrorSummary/index.js +1 -1
  498. package/esm/core/ErrorSummary/index.mdx +4 -0
  499. package/esm/core/Field/index.js +2 -2
  500. package/esm/core/FileUpload/FileUpload.stories.js +3 -1
  501. package/esm/core/FileUpload/index.mdx +4 -1
  502. package/esm/core/Label/index.js +2 -2
  503. package/esm/core/Link/Link.stories.js +3 -1
  504. package/esm/core/Link/index.js +8 -6
  505. package/esm/core/Link/link.mdx +4 -0
  506. package/esm/core/List/List.js +1 -1
  507. package/esm/core/List/List.stories.js +5 -2
  508. package/esm/core/List/index.mdx +4 -0
  509. package/esm/core/Masthead/Masthead.stories.js +5 -1
  510. package/esm/core/Masthead/masthead.mdx +4 -0
  511. package/esm/core/NavList/NavList.stories.js +4 -1
  512. package/esm/core/NavList/index.js +4 -2
  513. package/esm/core/NavList/index.mdx +4 -0
  514. package/esm/core/NotificationBanner/NotificationBanner.stories.js +5 -1
  515. package/esm/core/NotificationBanner/index.js +3 -3
  516. package/esm/core/NotificationBanner/index.mdx +4 -0
  517. package/esm/core/PhaseBanner/PhaseBanner.stories.js +4 -1
  518. package/esm/core/PhaseBanner/index.mdx +4 -0
  519. package/esm/core/Radios/Radios.stories.js +4 -1
  520. package/esm/core/Radios/__stories__/ConditionalReveal.js +1 -1
  521. package/esm/core/Radios/index.js +2 -2
  522. package/esm/core/Radios/index.mdx +14 -0
  523. package/esm/core/Select/Select.stories.js +4 -1
  524. package/esm/core/Select/__stories__/Default.js +2 -2
  525. package/esm/core/Select/__stories__/DisabledInput.js +2 -2
  526. package/esm/core/Select/__stories__/WithHint.js +2 -2
  527. package/esm/core/Select/index.js +2 -2
  528. package/esm/core/Select/index.mdx +4 -0
  529. package/esm/core/SummaryList/SummaryList.stories.js +5 -2
  530. package/esm/core/SummaryList/index.mdx +4 -0
  531. package/esm/core/Table/Table.stories.js +5 -2
  532. package/esm/core/Table/__stories__/WithFloatingScroll.js +1 -27
  533. package/esm/core/Table/index.js +3 -1
  534. package/esm/core/Table/index.mdx +4 -1
  535. package/esm/core/Tabs/Tabs.stories.js +6 -2
  536. package/esm/core/Tabs/index.js +5 -5
  537. package/esm/core/Tabs/index.mdx +4 -0
  538. package/esm/core/TextArea/TextArea.stories.js +4 -1
  539. package/esm/core/TextArea/__stories__/Default.js +4 -4
  540. package/esm/core/TextArea/__stories__/DisabledInput.js +4 -4
  541. package/esm/core/TextArea/__stories__/LimitedCharacters.js +4 -4
  542. package/esm/core/TextArea/__stories__/MultipleQuestions.js +4 -4
  543. package/esm/core/TextArea/__stories__/WithDeclaredRows.js +4 -4
  544. package/esm/core/TextArea/__stories__/WithErrorMessage.js +4 -4
  545. package/esm/core/TextArea/__stories__/WithHint.js +4 -4
  546. package/esm/core/TextArea/index.mdx +4 -0
  547. package/esm/core/TextInput/TextInput.stories.js +4 -1
  548. package/esm/core/TextInput/__stories__/AskingForNumbers.js +4 -4
  549. package/esm/core/TextInput/__stories__/Default.js +4 -4
  550. package/esm/core/TextInput/__stories__/DisabledInput.js +4 -4
  551. package/esm/core/TextInput/__stories__/FixedWidths.js +9 -9
  552. package/esm/core/TextInput/__stories__/FluidWidths.js +9 -9
  553. package/esm/core/TextInput/__stories__/MultipleQuestions.js +4 -4
  554. package/esm/core/TextInput/__stories__/WithErrorMessage.js +5 -5
  555. package/esm/core/TextInput/__stories__/WithHint.js +4 -4
  556. package/esm/core/TextInput/index.mdx +4 -0
  557. package/esm/core/VisuallyHidden/VisuallyHidden.stories.js +2 -1
  558. package/esm/core/VisuallyHidden/index.mdx +4 -1
  559. package/esm/core/WarningText/WarningText.stories.js +5 -2
  560. package/esm/core/WarningText/index.js +1 -1
  561. package/esm/core/WarningText/index.mdx +4 -0
  562. package/esm/core/index.js +8 -5
  563. package/esm/govgr/Footer/Copyright.js +3 -2
  564. package/esm/govgr/Footer/index.mdx +4 -0
  565. package/esm/index.js +3 -2
  566. package/esm/layouts/Basic/Basic.stories.js +3 -1
  567. package/esm/layouts/Basic/Bottom/index.js +1 -1
  568. package/esm/layouts/Basic/Bottom/index.mdx +4 -0
  569. package/esm/layouts/Basic/Main/index.js +1 -1
  570. package/esm/layouts/Basic/Main/index.mdx +4 -0
  571. package/esm/layouts/Basic/Masthead/index.js +2 -2
  572. package/esm/layouts/Basic/Masthead/index.mdx +4 -0
  573. package/esm/layouts/Basic/Top/index.js +2 -10
  574. package/esm/layouts/Basic/Top/index.mdx +4 -0
  575. package/esm/layouts/Basic/index.js +5 -3
  576. package/esm/layouts/Basic/index.mdx +0 -6
  577. package/esm/layouts/Grid/Grid.stories.js +3 -2
  578. package/esm/layouts/Grid/__stories__/Default.js +2 -6
  579. package/esm/registry.js +116 -2
  580. package/esm/typography/Heading/Heading.stories.js +2 -1
  581. package/esm/typography/Heading/index.js +1 -1
  582. package/esm/typography/Heading/index.mdx +4 -0
  583. package/esm/typography/HeadingCaption/HeadingCaption.stories.js +2 -1
  584. package/esm/typography/HeadingCaption/index.js +1 -1
  585. package/esm/typography/HeadingCaption/index.mdx +4 -1
  586. package/esm/typography/Hint/Hint.stories.js +2 -1
  587. package/esm/typography/Hint/index.mdx +4 -1
  588. package/esm/typography/NormalText/NormalText.stories.js +2 -1
  589. package/esm/typography/NormalText/index.mdx +4 -1
  590. package/esm/typography/Paragraph/Paragraph.stories.js +2 -1
  591. package/esm/typography/Paragraph/index.mdx +4 -1
  592. package/esm/typography/index.js +2 -4
  593. package/esm/utils/Kitchensink/AllComponents.js +11 -0
  594. package/esm/utils/Kitchensink/KitchensinkByCategory.js +42 -0
  595. package/esm/utils/Kitchensink/KitchensinkByLetter.js +20 -0
  596. package/esm/utils/Kitchensink/KitchensinkComponent.js +51 -0
  597. package/esm/utils/Kitchensink/KitchensinkDashboard.js +50 -0
  598. package/esm/utils/withDeprecation.js +15 -12
  599. package/govgr/Footer/Copyright.d.ts +2 -0
  600. package/govgr/Footer/Copyright.js +10 -3
  601. package/govgr/Footer/index.mdx +4 -0
  602. package/index.d.ts +1 -0
  603. package/index.js +13 -0
  604. package/layouts/Basic/Basic.stories.d.ts +2 -0
  605. package/layouts/Basic/Basic.stories.js +3 -1
  606. package/layouts/Basic/Bottom/index.d.ts +1 -1
  607. package/layouts/Basic/Bottom/index.js +19 -8
  608. package/layouts/Basic/Bottom/index.mdx +4 -0
  609. package/layouts/Basic/Content/index.d.ts +1 -3
  610. package/layouts/Basic/Main/index.d.ts +1 -1
  611. package/layouts/Basic/Main/index.js +19 -8
  612. package/layouts/Basic/Main/index.mdx +4 -0
  613. package/layouts/Basic/Masthead/index.d.ts +2 -2
  614. package/layouts/Basic/Masthead/index.js +31 -14
  615. package/layouts/Basic/Masthead/index.mdx +4 -0
  616. package/layouts/Basic/Top/index.d.ts +2 -2
  617. package/layouts/Basic/Top/index.js +19 -13
  618. package/layouts/Basic/Top/index.mdx +4 -0
  619. package/layouts/Basic/index.d.ts +4 -2
  620. package/layouts/Basic/index.js +48 -11
  621. package/layouts/Basic/index.mdx +0 -6
  622. package/layouts/Grid/Grid.stories.d.ts +2 -0
  623. package/layouts/Grid/Grid.stories.js +3 -2
  624. package/layouts/Grid/__stories__/Default.js +2 -6
  625. package/package.json +5 -5
  626. package/registry.d.ts +111 -1
  627. package/registry.js +176 -5
  628. package/typography/Heading/Heading.stories.d.ts +1 -0
  629. package/typography/Heading/Heading.stories.js +2 -1
  630. package/typography/Heading/index.d.ts +1 -1
  631. package/typography/Heading/index.mdx +4 -0
  632. package/typography/HeadingCaption/HeadingCaption.stories.d.ts +1 -0
  633. package/typography/HeadingCaption/HeadingCaption.stories.js +2 -1
  634. package/typography/HeadingCaption/index.d.ts +1 -1
  635. package/typography/HeadingCaption/index.mdx +4 -1
  636. package/typography/Hint/Hint.stories.d.ts +1 -0
  637. package/typography/Hint/Hint.stories.js +2 -1
  638. package/typography/Hint/index.mdx +4 -1
  639. package/typography/NormalText/NormalText.stories.d.ts +1 -0
  640. package/typography/NormalText/NormalText.stories.js +2 -1
  641. package/typography/NormalText/index.mdx +4 -1
  642. package/typography/Paragraph/Paragraph.stories.d.ts +1 -0
  643. package/typography/Paragraph/Paragraph.stories.js +2 -1
  644. package/typography/Paragraph/index.mdx +4 -1
  645. package/typography/index.d.ts +2 -4
  646. package/typography/index.js +31 -46
  647. package/utils/Kitchensink/AllComponents.d.ts +1 -0
  648. package/utils/Kitchensink/AllComponents.js +24 -0
  649. package/utils/Kitchensink/KitchensinkByCategory.d.ts +6 -0
  650. package/utils/Kitchensink/KitchensinkByCategory.js +56 -0
  651. package/utils/Kitchensink/KitchensinkByLetter.d.ts +5 -0
  652. package/utils/Kitchensink/KitchensinkByLetter.js +34 -0
  653. package/utils/Kitchensink/KitchensinkComponent.d.ts +10 -0
  654. package/utils/Kitchensink/KitchensinkComponent.js +68 -0
  655. package/utils/Kitchensink/KitchensinkDashboard.d.ts +4 -0
  656. package/utils/Kitchensink/KitchensinkDashboard.js +63 -0
  657. package/utils/withDeprecation.js +15 -12
  658. package/admin/CopyToClipboard/__stories__/MultipleCopies.d.ts +0 -2
  659. package/admin/CopyToClipboard/__stories__/MultipleCopies.js +0 -142
  660. package/admin/Dropdown/Dropdown.stories.playwright.json +0 -21
  661. package/admin/Modal/Modal.stories.playwright.json +0 -37
  662. package/admin/Modal/__stories__/AlertDialog.test.d.ts +0 -1
  663. package/admin/Modal/__stories__/AlertDialog.test.js +0 -60
  664. package/core/Confirmation/Confirmation.stories.d.ts +0 -7
  665. package/core/Confirmation/Confirmation.stories.js +0 -30
  666. package/core/Confirmation/__stories__/Default.d.ts +0 -2
  667. package/core/Confirmation/__stories__/Default.js +0 -28
  668. package/core/Confirmation/confirmation.mdx +0 -19
  669. package/core/Confirmation/index.d.ts +0 -5
  670. package/core/Confirmation/index.js +0 -58
  671. package/core/ServiceBadge/index.mdx +0 -42
  672. package/es/admin/CopyToClipboard/__stories__/MultipleCopies.js +0 -120
  673. package/es/admin/Dropdown/Dropdown.stories.playwright.json +0 -21
  674. package/es/admin/Modal/Modal.stories.playwright.json +0 -37
  675. package/es/admin/Modal/__stories__/AlertDialog.test.js +0 -53
  676. package/es/core/Confirmation/Confirmation.stories.js +0 -6
  677. package/es/core/Confirmation/__stories__/Default.js +0 -9
  678. package/es/core/Confirmation/confirmation.mdx +0 -19
  679. package/es/core/Confirmation/index.js +0 -5
  680. package/es/core/ServiceBadge/index.mdx +0 -42
  681. package/es/form/inputs/Input/index.mdx +0 -10
  682. package/es/layouts/Basic/Content/index.mdx +0 -50
  683. package/es/layouts/Basic/Side/index.mdx +0 -57
  684. package/es/router/index.mdx +0 -5
  685. package/es/typography/index.mdx +0 -5
  686. package/esm/admin/CopyToClipboard/__stories__/MultipleCopies.js +0 -120
  687. package/esm/admin/Dropdown/Dropdown.stories.playwright.json +0 -21
  688. package/esm/admin/Modal/Modal.stories.playwright.json +0 -37
  689. package/esm/admin/Modal/__stories__/AlertDialog.test.js +0 -53
  690. package/esm/core/Confirmation/Confirmation.stories.js +0 -6
  691. package/esm/core/Confirmation/__stories__/Default.js +0 -9
  692. package/esm/core/Confirmation/confirmation.mdx +0 -19
  693. package/esm/core/Confirmation/index.js +0 -5
  694. package/esm/core/ServiceBadge/index.mdx +0 -42
  695. package/esm/form/inputs/Input/index.mdx +0 -10
  696. package/esm/layouts/Basic/Content/index.mdx +0 -50
  697. package/esm/layouts/Basic/Side/index.mdx +0 -57
  698. package/esm/router/index.mdx +0 -5
  699. package/esm/typography/index.mdx +0 -5
  700. package/form/inputs/Input/index.mdx +0 -10
  701. package/layouts/Basic/Content/index.mdx +0 -50
  702. package/layouts/Basic/Side/index.mdx +0 -57
  703. package/router/index.mdx +0 -5
  704. package/typography/index.mdx +0 -5
@@ -1,13 +1,18 @@
1
1
  "use strict";
2
2
 
3
+ var _typeof = require("@babel/runtime/helpers/typeof");
4
+
3
5
  Object.defineProperty(exports, "__esModule", {
4
6
  value: true
5
7
  });
8
+ var _exportNames = {};
9
+ exports["default"] = void 0;
6
10
 
7
- var _Footer = require("@digigov/react-core/Footer");
11
+ var _Footer = _interopRequireWildcard(require("@digigov/react-core/Footer"));
8
12
 
9
13
  Object.keys(_Footer).forEach(function (key) {
10
14
  if (key === "default" || key === "__esModule") return;
15
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
11
16
  if (key in exports && exports[key] === _Footer[key]) return;
12
17
  Object.defineProperty(exports, key, {
13
18
  enumerable: true,
@@ -21,6 +26,7 @@ var _FooterContainer = require("@digigov/react-core/FooterContainer");
21
26
 
22
27
  Object.keys(_FooterContainer).forEach(function (key) {
23
28
  if (key === "default" || key === "__esModule") return;
29
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
24
30
  if (key in exports && exports[key] === _FooterContainer[key]) return;
25
31
  Object.defineProperty(exports, key, {
26
32
  enumerable: true,
@@ -34,6 +40,7 @@ var _FooterContent = require("@digigov/react-core/FooterContent");
34
40
 
35
41
  Object.keys(_FooterContent).forEach(function (key) {
36
42
  if (key === "default" || key === "__esModule") return;
43
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
37
44
  if (key in exports && exports[key] === _FooterContent[key]) return;
38
45
  Object.defineProperty(exports, key, {
39
46
  enumerable: true,
@@ -47,6 +54,7 @@ var _FooterContentLogos = require("@digigov/react-core/FooterContentLogos");
47
54
 
48
55
  Object.keys(_FooterContentLogos).forEach(function (key) {
49
56
  if (key === "default" || key === "__esModule") return;
57
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
50
58
  if (key in exports && exports[key] === _FooterContentLogos[key]) return;
51
59
  Object.defineProperty(exports, key, {
52
60
  enumerable: true,
@@ -60,6 +68,7 @@ var _FooterHeading = require("@digigov/react-core/FooterHeading");
60
68
 
61
69
  Object.keys(_FooterHeading).forEach(function (key) {
62
70
  if (key === "default" || key === "__esModule") return;
71
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
63
72
  if (key in exports && exports[key] === _FooterHeading[key]) return;
64
73
  Object.defineProperty(exports, key, {
65
74
  enumerable: true,
@@ -73,6 +82,7 @@ var _FooterImage = require("@digigov/react-core/FooterImage");
73
82
 
74
83
  Object.keys(_FooterImage).forEach(function (key) {
75
84
  if (key === "default" || key === "__esModule") return;
85
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
76
86
  if (key in exports && exports[key] === _FooterImage[key]) return;
77
87
  Object.defineProperty(exports, key, {
78
88
  enumerable: true,
@@ -86,6 +96,7 @@ var _FooterInlineList = require("@digigov/react-core/FooterInlineList");
86
96
 
87
97
  Object.keys(_FooterInlineList).forEach(function (key) {
88
98
  if (key === "default" || key === "__esModule") return;
99
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
89
100
  if (key in exports && exports[key] === _FooterInlineList[key]) return;
90
101
  Object.defineProperty(exports, key, {
91
102
  enumerable: true,
@@ -99,6 +110,7 @@ var _FooterInlineListItem = require("@digigov/react-core/FooterInlineListItem");
99
110
 
100
111
  Object.keys(_FooterInlineListItem).forEach(function (key) {
101
112
  if (key === "default" || key === "__esModule") return;
113
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
102
114
  if (key in exports && exports[key] === _FooterInlineListItem[key]) return;
103
115
  Object.defineProperty(exports, key, {
104
116
  enumerable: true,
@@ -112,6 +124,7 @@ var _FooterLink = require("@digigov/react-core/FooterLink");
112
124
 
113
125
  Object.keys(_FooterLink).forEach(function (key) {
114
126
  if (key === "default" || key === "__esModule") return;
127
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
115
128
  if (key in exports && exports[key] === _FooterLink[key]) return;
116
129
  Object.defineProperty(exports, key, {
117
130
  enumerable: true,
@@ -125,6 +138,7 @@ var _FooterList = require("@digigov/react-core/FooterList");
125
138
 
126
139
  Object.keys(_FooterList).forEach(function (key) {
127
140
  if (key === "default" || key === "__esModule") return;
141
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
128
142
  if (key in exports && exports[key] === _FooterList[key]) return;
129
143
  Object.defineProperty(exports, key, {
130
144
  enumerable: true,
@@ -138,6 +152,7 @@ var _FooterListItem = require("@digigov/react-core/FooterListItem");
138
152
 
139
153
  Object.keys(_FooterListItem).forEach(function (key) {
140
154
  if (key === "default" || key === "__esModule") return;
155
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
141
156
  if (key in exports && exports[key] === _FooterListItem[key]) return;
142
157
  Object.defineProperty(exports, key, {
143
158
  enumerable: true,
@@ -151,6 +166,7 @@ var _FooterMeta = require("@digigov/react-core/FooterMeta");
151
166
 
152
167
  Object.keys(_FooterMeta).forEach(function (key) {
153
168
  if (key === "default" || key === "__esModule") return;
169
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
154
170
  if (key in exports && exports[key] === _FooterMeta[key]) return;
155
171
  Object.defineProperty(exports, key, {
156
172
  enumerable: true,
@@ -164,6 +180,7 @@ var _FooterMetaItem = require("@digigov/react-core/FooterMetaItem");
164
180
 
165
181
  Object.keys(_FooterMetaItem).forEach(function (key) {
166
182
  if (key === "default" || key === "__esModule") return;
183
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
167
184
  if (key in exports && exports[key] === _FooterMetaItem[key]) return;
168
185
  Object.defineProperty(exports, key, {
169
186
  enumerable: true,
@@ -177,6 +194,7 @@ var _FooterNavigation = require("@digigov/react-core/FooterNavigation");
177
194
 
178
195
  Object.keys(_FooterNavigation).forEach(function (key) {
179
196
  if (key === "default" || key === "__esModule") return;
197
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
180
198
  if (key in exports && exports[key] === _FooterNavigation[key]) return;
181
199
  Object.defineProperty(exports, key, {
182
200
  enumerable: true,
@@ -190,6 +208,7 @@ var _FooterSection = require("@digigov/react-core/FooterSection");
190
208
 
191
209
  Object.keys(_FooterSection).forEach(function (key) {
192
210
  if (key === "default" || key === "__esModule") return;
211
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
193
212
  if (key in exports && exports[key] === _FooterSection[key]) return;
194
213
  Object.defineProperty(exports, key, {
195
214
  enumerable: true,
@@ -197,4 +216,11 @@ Object.keys(_FooterSection).forEach(function (key) {
197
216
  return _FooterSection[key];
198
217
  }
199
218
  });
200
- });
219
+ });
220
+
221
+ 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); }
222
+
223
+ 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; }
224
+
225
+ var _default = _Footer["default"];
226
+ exports["default"] = _default;
@@ -1,6 +1,10 @@
1
1
  declare namespace _default {
2
2
  export const title: string;
3
3
  export { Header as component };
4
+ export const displayName: string;
5
+ export const description: string;
6
+ export const link: string;
7
+ export const defaultWidth: string;
4
8
  export namespace parameters {
5
9
  const layout: string;
6
10
  }
@@ -68,6 +68,10 @@ Object.keys(_WithNavigation).forEach(function (key) {
68
68
  var _default = {
69
69
  title: 'Digigov UI/app/Header',
70
70
  component: _Header["default"],
71
+ displayName: 'Header',
72
+ description: 'You must use the GOV.GR header at the top of every page if your service is being listed in the GOV.GR service catalog.',
73
+ link: 'https://guide.services.gov.gr/docs/components/header',
74
+ defaultWidth: 'l',
71
75
  parameters: {
72
76
  // More on Story layout: https://storybook.js.org/docs/react/configure/story-layout
73
77
  layout: 'fullscreen'
@@ -25,3 +25,7 @@ import Header from '@digigov/ui/app/Header';
25
25
  ### Default header with navigation
26
26
 
27
27
  <Story packageName="@digigov/ui" component="app/Header" story="WithNavigation.tsx" />
28
+
29
+ ## API
30
+
31
+ <PropTypes packageName="@digigov/ui" component="Header" />
package/app/I18nText.js CHANGED
@@ -62,6 +62,7 @@ var recursiveReplace = function recursiveReplace(original, translation) {
62
62
 
63
63
  if (isObject(element)) {
64
64
  original[i] = /*#__PURE__*/_react["default"].cloneElement(original[i], (0, _extends2["default"])({}, original[i].props, {
65
+ key: i,
65
66
  children: recursiveReplace(original[i].props.children, translation[i].childNodes)
66
67
  }));
67
68
  }
@@ -1,6 +1,7 @@
1
1
  declare namespace _default {
2
2
  export const title: string;
3
3
  export { NotFound as component };
4
+ export const displayName: string;
4
5
  }
5
6
  export default _default;
6
7
  export * from "@digigov/ui/app/NotFound/__stories__/Default";
@@ -25,6 +25,7 @@ Object.keys(_Default).forEach(function (key) {
25
25
  });
26
26
  var _default = {
27
27
  title: 'Digigov UI/app/NotFound',
28
- component: _NotFound["default"]
28
+ component: _NotFound["default"],
29
+ displayName: 'NotFound'
29
30
  };
30
31
  exports["default"] = _default;
@@ -10,3 +10,7 @@ import NotFound from '@digigov/ui/app/NotFound';
10
10
  ## How to use
11
11
 
12
12
  <Story packageName="@digigov/ui" component="app/NotFound" story="Default.tsx" />
13
+
14
+ ## API
15
+
16
+ There are no available prop types for this component.
@@ -1,10 +1,6 @@
1
- import React from 'react';
2
- import { CaptionProps } from '@digigov/ui/typography/Caption';
3
- import { TitleProps } from '@digigov/ui/typography/Title';
4
- export declare const PageTitle: React.FC<{}>;
1
+ import PageTitle from '@digigov/react-core/PageTitle';
2
+ export * from '@digigov/react-core/PageTitle';
3
+ export * from '@digigov/react-core/PageTitleCaption';
4
+ export * from '@digigov/react-core/PageTitleHeading';
5
+ export * from '@digigov/react-core/PageTitleSection';
5
6
  export default PageTitle;
6
- export declare const PageTitleSection: React.FC<{}>;
7
- export declare const PageTitleCaption: React.FC<CaptionProps>;
8
- export interface PageTitleHeadingProps extends TitleProps {
9
- }
10
- export declare const PageTitleHeading: React.FC<TitleProps>;
package/app/PageTitle.js CHANGED
@@ -1,76 +1,72 @@
1
1
  "use strict";
2
2
 
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
3
+ var _typeof = require("@babel/runtime/helpers/typeof");
4
4
 
5
5
  Object.defineProperty(exports, "__esModule", {
6
6
  value: true
7
7
  });
8
- exports["default"] = exports.PageTitleSection = exports.PageTitleHeading = exports.PageTitleCaption = exports.PageTitle = void 0;
8
+ var _exportNames = {};
9
+ exports["default"] = void 0;
9
10
 
10
- var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
11
+ var _PageTitle = _interopRequireWildcard(require("@digigov/react-core/PageTitle"));
11
12
 
12
- var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
13
-
14
- var _react = _interopRequireDefault(require("react"));
13
+ Object.keys(_PageTitle).forEach(function (key) {
14
+ if (key === "default" || key === "__esModule") return;
15
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
16
+ if (key in exports && exports[key] === _PageTitle[key]) return;
17
+ Object.defineProperty(exports, key, {
18
+ enumerable: true,
19
+ get: function get() {
20
+ return _PageTitle[key];
21
+ }
22
+ });
23
+ });
15
24
 
16
- var _Caption = _interopRequireDefault(require("@digigov/ui/typography/Caption"));
25
+ var _PageTitleCaption = require("@digigov/react-core/PageTitleCaption");
17
26
 
18
- var _Title = _interopRequireDefault(require("@digigov/ui/typography/Title"));
27
+ Object.keys(_PageTitleCaption).forEach(function (key) {
28
+ if (key === "default" || key === "__esModule") return;
29
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
30
+ if (key in exports && exports[key] === _PageTitleCaption[key]) return;
31
+ Object.defineProperty(exports, key, {
32
+ enumerable: true,
33
+ get: function get() {
34
+ return _PageTitleCaption[key];
35
+ }
36
+ });
37
+ });
19
38
 
20
- var _withDeprecation = _interopRequireDefault(require("@digigov/ui/utils/withDeprecation"));
39
+ var _PageTitleHeading = require("@digigov/react-core/PageTitleHeading");
21
40
 
22
- var _excluded = ["component", "children"];
23
- var PageTitle = (0, _withDeprecation["default"])(function (_ref) {
24
- var children = _ref.children;
25
- return /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, children);
26
- }, {
27
- name: 'PageTitle',
28
- warning: 'There is no need to use PageTitle components anymore. It will be removed in a later version'
29
- });
30
- exports.PageTitle = PageTitle;
31
- var _default = PageTitle;
32
- exports["default"] = _default;
33
- var PageTitleSection = (0, _withDeprecation["default"])(function (_ref2) {
34
- var children = _ref2.children;
35
- return /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, children);
36
- }, {
37
- name: 'PageTitleSection',
38
- warning: 'There is no need to use PageTitleSection components anymore. It will be removed in a later version'
39
- });
40
- exports.PageTitleSection = PageTitleSection;
41
- var PageTitleCaption = (0, _withDeprecation["default"])(_Caption["default"], {
42
- name: 'PageTitleCaption',
43
- rename: 'HeadingCaption'
41
+ Object.keys(_PageTitleHeading).forEach(function (key) {
42
+ if (key === "default" || key === "__esModule") return;
43
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
44
+ if (key in exports && exports[key] === _PageTitleHeading[key]) return;
45
+ Object.defineProperty(exports, key, {
46
+ enumerable: true,
47
+ get: function get() {
48
+ return _PageTitleHeading[key];
49
+ }
50
+ });
44
51
  });
45
- exports.PageTitleCaption = PageTitleCaption;
46
- var PageTitleHeading = (0, _withDeprecation["default"])(function (_ref3) {
47
- var component = _ref3.component,
48
- children = _ref3.children,
49
- props = (0, _objectWithoutProperties2["default"])(_ref3, _excluded);
50
- return /*#__PURE__*/_react["default"].createElement(_Title["default"], (0, _extends2["default"])({
51
- size: "xl",
52
- element: component
53
- }, props), children);
54
- }, {
55
- name: 'PageTitleHeading',
56
- props: {
57
- dense: {
58
- error: true
59
- },
60
- size: {
61
- values: {
62
- xs: {
63
- error: true
64
- }
65
- }
66
- },
67
- component: {
68
- values: {
69
- h5: {
70
- error: true
71
- }
72
- }
52
+
53
+ var _PageTitleSection = require("@digigov/react-core/PageTitleSection");
54
+
55
+ Object.keys(_PageTitleSection).forEach(function (key) {
56
+ if (key === "default" || key === "__esModule") return;
57
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
58
+ if (key in exports && exports[key] === _PageTitleSection[key]) return;
59
+ Object.defineProperty(exports, key, {
60
+ enumerable: true,
61
+ get: function get() {
62
+ return _PageTitleSection[key];
73
63
  }
74
- }
64
+ });
75
65
  });
76
- exports.PageTitleHeading = PageTitleHeading;
66
+
67
+ 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); }
68
+
69
+ 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; }
70
+
71
+ var _default = _PageTitle["default"];
72
+ exports["default"] = _default;
@@ -1,6 +1,8 @@
1
1
  declare namespace _default {
2
2
  export const title: string;
3
3
  export { PhaseBannerHeader as component };
4
+ export const displayName: string;
4
5
  }
5
6
  export default _default;
6
7
  export * from "./__stories__/Default";
8
+ import PhaseBannerHeader from "@digigov/ui/app/PhaseBannerHeader";
@@ -8,7 +8,7 @@ Object.defineProperty(exports, "__esModule", {
8
8
  var _exportNames = {};
9
9
  exports["default"] = void 0;
10
10
 
11
- var _app = _interopRequireDefault(require("@digigov/ui/app"));
11
+ var _PhaseBannerHeader = _interopRequireDefault(require("@digigov/ui/app/PhaseBannerHeader"));
12
12
 
13
13
  var _Default = require("./__stories__/Default");
14
14
 
@@ -25,6 +25,7 @@ Object.keys(_Default).forEach(function (key) {
25
25
  });
26
26
  var _default = {
27
27
  title: 'Digigov UI/app/PhaseBannerHeader',
28
- component: _app["default"]
28
+ component: _PhaseBannerHeader["default"],
29
+ displayName: 'PhaseBannerHeader'
29
30
  };
30
31
  exports["default"] = _default;
@@ -10,3 +10,7 @@ import PhaseBannerHeader from '@digigov/ui/app/PhaseBannerHeader';
10
10
  ## How to use
11
11
 
12
12
  <Story packageName="@digigov/ui" component="app/PhaseBannerHeader" story="Default.tsx" />
13
+
14
+ ## API
15
+
16
+ <PropTypes packageName="@digigov/ui" component="PhaseBannerHeader" />
@@ -1,6 +1,7 @@
1
1
  declare namespace _default {
2
2
  export const title: string;
3
3
  export { QrCodeScanner as component };
4
+ export const displayName: string;
4
5
  }
5
6
  export default _default;
6
7
  export * from "@digigov/ui/app/QrCodeScanner/__stories__/Default";
@@ -25,6 +25,7 @@ Object.keys(_Default).forEach(function (key) {
25
25
  });
26
26
  var _default = {
27
27
  title: 'Digigov UI/app/QrCodeScanner',
28
- component: _QrCodeScanner["default"]
28
+ component: _QrCodeScanner["default"],
29
+ displayName: 'QrCodeScanner'
29
30
  };
30
31
  exports["default"] = _default;
@@ -1,10 +1,17 @@
1
1
  import React from 'react';
2
- export interface QrCodeScannerProps extends QrReader.props {
2
+ export interface QrCodeScannerProps {
3
+ style?: React.CSSProperties;
3
4
  dataType?: 'url' | 'text';
4
5
  legacyMode?: boolean;
5
6
  validate?: (...args: any[]) => boolean;
6
7
  onScan: (...args: any[]) => void;
7
8
  onError: (err: any) => void;
9
+ onLoad?: (...args: any[]) => void;
10
+ onImageLoad?: (...args: any[]) => void;
11
+ delay?: number;
12
+ facingMode?: 'user' | 'environment';
13
+ showViewFinder?: boolean;
14
+ className?: string;
8
15
  }
9
16
  /**
10
17
  * QRCodeScanner assumes that the data provided inside the QR code image,
@@ -15,7 +15,7 @@ var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/h
15
15
 
16
16
  var _react = _interopRequireDefault(require("react"));
17
17
 
18
- var _excluded = ["className", "children", "validate", "onScan", "onError", "dataType", "legacyMode"];
18
+ var _excluded = ["children", "validate", "onScan", "onError", "dataType", "legacyMode"];
19
19
 
20
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
21
 
@@ -23,7 +23,7 @@ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj &&
23
23
 
24
24
  var QrReader = /*#__PURE__*/_react["default"].lazy(function () {
25
25
  return Promise.resolve().then(function () {
26
- return _interopRequireWildcard(require('react-qr-reader'));
26
+ return _interopRequireWildcard(require('@uides/react-qr-reader'));
27
27
  });
28
28
  });
29
29
 
@@ -45,8 +45,7 @@ var QrReader = /*#__PURE__*/_react["default"].lazy(function () {
45
45
  *
46
46
  */
47
47
  var QrCodeScanner = function QrCodeScanner(_ref) {
48
- var className = _ref.className,
49
- children = _ref.children,
48
+ var children = _ref.children,
50
49
  validate = _ref.validate,
51
50
  onScan = _ref.onScan,
52
51
  onError = _ref.onError,
@@ -79,7 +78,6 @@ var QrCodeScanner = function QrCodeScanner(_ref) {
79
78
  };
80
79
 
81
80
  return /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, /*#__PURE__*/_react["default"].createElement(QrReader, (0, _extends2["default"])({
82
- className: className,
83
81
  delay: 100,
84
82
  onError: onError,
85
83
  onScan: handleOnScan,
@@ -1,6 +1,7 @@
1
1
  declare namespace _default {
2
2
  export const title: string;
3
3
  export { QrCodeViewer as component };
4
+ export const displayName: string;
4
5
  }
5
6
  export default _default;
6
7
  export * from "./__stories__/Default";
@@ -41,6 +41,7 @@ Object.keys(_Custom).forEach(function (key) {
41
41
  /* eslint-disable digigov/no-relative-imports */
42
42
  var _default = {
43
43
  title: 'Digigov UI/app/QrCodeViewer',
44
- component: _QrCodeViewer["default"]
44
+ component: _QrCodeViewer["default"],
45
+ displayName: 'QrCodeViewer'
45
46
  };
46
47
  exports["default"] = _default;
@@ -1,8 +1,6 @@
1
- import { QRPropsCanvas, QRPropsSVG } from '@digigov/ui/app/QrCodeViewer/types';
2
- declare type RootProps = (QRPropsSVG & {
3
- renderAs: 'svg';
4
- }) | (QRPropsCanvas & {
5
- renderAs?: 'canvas';
6
- });
7
- export declare const QrCodeViewer: (props: RootProps) => JSX.Element;
1
+ import React from 'react';
2
+ import { QRPropsCanvas } from '@digigov/ui/app/QrCodeViewer/types';
3
+ export interface QrCodeViewerProps extends QRPropsCanvas {
4
+ }
5
+ export declare const QrCodeViewer: (props: QrCodeViewerProps) => React.ReactElement;
8
6
  export default QrCodeViewer;
@@ -21,9 +21,7 @@ var _qrcodegen = _interopRequireDefault(require("@digigov/ui/app/QrCodeViewer/qr
21
21
 
22
22
  var _utils = require("@digigov/ui/app/QrCodeViewer/utils");
23
23
 
24
- var _excluded = ["value", "size", "level", "bgColor", "fgColor", "includeMargin", "style", "imageSettings"],
25
- _excluded2 = ["value", "size", "level", "bgColor", "fgColor", "includeMargin", "imageSettings"],
26
- _excluded3 = ["renderAs"];
24
+ var _excluded = ["value", "size", "level", "bgColor", "fgColor", "includeMargin", "style", "imageSettings"];
27
25
 
28
26
  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); }
29
27
 
@@ -173,74 +171,8 @@ function QrCodeViewerCanvas(props) {
173
171
  }, otherProps)), img);
174
172
  }
175
173
 
176
- function QrCodeViewerSVG(props) {
177
- var value = props.value,
178
- _props$size2 = props.size,
179
- size = _props$size2 === void 0 ? DEFAULT_SIZE : _props$size2,
180
- _props$level2 = props.level,
181
- level = _props$level2 === void 0 ? DEFAULT_LEVEL : _props$level2,
182
- _props$bgColor2 = props.bgColor,
183
- bgColor = _props$bgColor2 === void 0 ? DEFAULT_BGCOLOR : _props$bgColor2,
184
- _props$fgColor2 = props.fgColor,
185
- fgColor = _props$fgColor2 === void 0 ? DEFAULT_FGCOLOR : _props$fgColor2,
186
- _props$includeMargin2 = props.includeMargin,
187
- includeMargin = _props$includeMargin2 === void 0 ? DEFAULT_INCLUDEMARGIN : _props$includeMargin2,
188
- imageSettings = props.imageSettings,
189
- otherProps = (0, _objectWithoutProperties2["default"])(props, _excluded2);
190
-
191
- var cells = _qrcodegen["default"].QrCode.encodeText(value, ERROR_LEVEL_MAP[level]).getModules();
192
-
193
- var margin = includeMargin ? _utils.MARGIN_SIZE : 0;
194
- var numCells = cells.length + margin * 2;
195
- var calculatedImageSettings = (0, _utils.getImageSettings)(cells, size, includeMargin, imageSettings);
196
- var image;
197
-
198
- if (imageSettings != null && calculatedImageSettings != null) {
199
- if (calculatedImageSettings.excavation != null) {
200
- cells = (0, _utils.excavateModules)(cells, calculatedImageSettings.excavation);
201
- }
202
-
203
- image = /*#__PURE__*/_react["default"].createElement("image", {
204
- xlinkHref: imageSettings.src,
205
- height: calculatedImageSettings.h,
206
- width: calculatedImageSettings.w,
207
- x: calculatedImageSettings.x + margin,
208
- y: calculatedImageSettings.y + margin,
209
- preserveAspectRatio: "none"
210
- });
211
- } // Drawing strategy: instead of a rect per module, we're going to create a
212
- // single path for the dark modules and layer that on top of a light rect,
213
- // for a total of 2 DOM nodes. We pay a bit more in string concat but that's
214
- // way faster than DOM ops.
215
- // For level 1, 441 nodes -> 2
216
- // For level 40, 31329 -> 2
217
-
218
-
219
- var fgPath = (0, _utils.generatePath)(cells, margin);
220
- return /*#__PURE__*/_react["default"].createElement("svg", (0, _extends2["default"])({
221
- height: size,
222
- width: size,
223
- viewBox: "0 0 ".concat(numCells, " ").concat(numCells)
224
- }, otherProps), /*#__PURE__*/_react["default"].createElement("path", {
225
- fill: bgColor,
226
- d: "M0,0 h".concat(numCells, "v").concat(numCells, "H0z"),
227
- shapeRendering: "crispEdges"
228
- }), /*#__PURE__*/_react["default"].createElement("path", {
229
- fill: fgColor,
230
- d: fgPath,
231
- shapeRendering: "crispEdges"
232
- }), image);
233
- }
234
-
235
174
  var QrCodeViewer = function QrCodeViewer(props) {
236
- var renderAs = props.renderAs,
237
- otherProps = (0, _objectWithoutProperties2["default"])(props, _excluded3);
238
-
239
- if (renderAs === 'svg') {
240
- return /*#__PURE__*/_react["default"].createElement(QrCodeViewerSVG, otherProps);
241
- }
242
-
243
- return /*#__PURE__*/_react["default"].createElement(QrCodeViewerCanvas, otherProps);
175
+ return /*#__PURE__*/_react["default"].createElement(QrCodeViewerCanvas, props);
244
176
  };
245
177
 
246
178
  exports.QrCodeViewer = QrCodeViewer;
@@ -19,3 +19,7 @@ import QrCodeViewer from '@digigov/ui/app/QrCodeViewer';
19
19
  <Story packageName="@digigov/ui" component="app/QrCodeViewer" story="Custom.tsx" />
20
20
 
21
21
 
22
+
23
+ ## API
24
+
25
+ <PropTypes packageName="@digigov/ui" component="QrCodeViewer" />
@@ -11,7 +11,6 @@ export declare type QRProps = {
11
11
  imageSettings?: ImageSettings;
12
12
  };
13
13
  export declare type QRPropsCanvas = QRProps & React.CanvasHTMLAttributes<HTMLCanvasElement>;
14
- export declare type QRPropsSVG = QRProps & React.SVGProps<SVGSVGElement>;
15
14
  export declare type Modules = ReturnType<qrcodegen.QrCode['getModules']>;
16
15
  export declare type Excavation = {
17
16
  x: number;
package/app/index.d.ts CHANGED
@@ -1,4 +1,6 @@
1
1
  export * from '@digigov/ui/app/App';
2
+ export * from '@digigov/ui/app/Confirmation';
3
+ export * from '@digigov/ui/app/Footer';
2
4
  export * from '@digigov/ui/app/PageTitle';
3
5
  export * from '@digigov/ui/app/QrCodeScanner';
4
6
  export * from '@digigov/ui/app/QrCodeViewer';