content_block_tools 0.17.0 → 1.0.1

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 (877) hide show
  1. checksums.yaml +4 -4
  2. data/app/assets/stylesheets/blocks/_contact.scss +13 -0
  3. data/app/assets/stylesheets/content_block_tools.scss +24 -0
  4. data/lib/content_block_tools/engine.rb +16 -0
  5. data/lib/content_block_tools/presenters/block_presenters/contact/address_presenter.rb +1 -7
  6. data/lib/content_block_tools/presenters/block_presenters/contact/block_level_contact_item.rb +10 -16
  7. data/lib/content_block_tools/presenters/block_presenters/contact/contact_link_presenter.rb +6 -4
  8. data/lib/content_block_tools/presenters/block_presenters/contact/email_address_presenter.rb +10 -4
  9. data/lib/content_block_tools/presenters/block_presenters/contact/telephone_presenter.rb +9 -26
  10. data/lib/content_block_tools/presenters/contact_presenter.rb +6 -10
  11. data/lib/content_block_tools/version.rb +1 -1
  12. data/lib/content_block_tools.rb +2 -8
  13. data/node_modules/govuk-frontend/README.md +92 -0
  14. data/node_modules/govuk-frontend/dist/govuk/_base.scss +5 -0
  15. data/node_modules/govuk-frontend/dist/govuk/_base.scss.map +1 -0
  16. data/node_modules/govuk-frontend/dist/govuk/all.bundle.js +2847 -0
  17. data/node_modules/govuk-frontend/dist/govuk/all.bundle.js.map +1 -0
  18. data/node_modules/govuk-frontend/dist/govuk/all.bundle.mjs +2820 -0
  19. data/node_modules/govuk-frontend/dist/govuk/all.bundle.mjs.map +1 -0
  20. data/node_modules/govuk-frontend/dist/govuk/all.mjs +20 -0
  21. data/node_modules/govuk-frontend/dist/govuk/all.mjs.map +1 -0
  22. data/node_modules/govuk-frontend/dist/govuk/all.scss +9 -0
  23. data/node_modules/govuk-frontend/dist/govuk/all.scss.map +1 -0
  24. data/node_modules/govuk-frontend/dist/govuk/assets/fonts/bold-affa96571d-v2.woff +0 -0
  25. data/node_modules/govuk-frontend/dist/govuk/assets/fonts/bold-b542beb274-v2.woff2 +0 -0
  26. data/node_modules/govuk-frontend/dist/govuk/assets/fonts/light-94a07e06a1-v2.woff2 +0 -0
  27. data/node_modules/govuk-frontend/dist/govuk/assets/fonts/light-f591b13f7d-v2.woff +0 -0
  28. data/node_modules/govuk-frontend/dist/govuk/assets/images/favicon.ico +0 -0
  29. data/node_modules/govuk-frontend/dist/govuk/assets/images/favicon.svg +1 -0
  30. data/node_modules/govuk-frontend/dist/govuk/assets/images/govuk-crest.svg +1 -0
  31. data/node_modules/govuk-frontend/dist/govuk/assets/images/govuk-icon-180.png +0 -0
  32. data/node_modules/govuk-frontend/dist/govuk/assets/images/govuk-icon-192.png +0 -0
  33. data/node_modules/govuk-frontend/dist/govuk/assets/images/govuk-icon-512.png +0 -0
  34. data/node_modules/govuk-frontend/dist/govuk/assets/images/govuk-icon-mask.svg +1 -0
  35. data/node_modules/govuk-frontend/dist/govuk/assets/images/govuk-opengraph-image.png +0 -0
  36. data/node_modules/govuk-frontend/dist/govuk/assets/manifest.json +39 -0
  37. data/node_modules/govuk-frontend/dist/govuk/assets/rebrand/images/favicon.ico +0 -0
  38. data/node_modules/govuk-frontend/dist/govuk/assets/rebrand/images/favicon.svg +1 -0
  39. data/node_modules/govuk-frontend/dist/govuk/assets/rebrand/images/govuk-crest.svg +1 -0
  40. data/node_modules/govuk-frontend/dist/govuk/assets/rebrand/images/govuk-icon-180.png +0 -0
  41. data/node_modules/govuk-frontend/dist/govuk/assets/rebrand/images/govuk-icon-192.png +0 -0
  42. data/node_modules/govuk-frontend/dist/govuk/assets/rebrand/images/govuk-icon-512.png +0 -0
  43. data/node_modules/govuk-frontend/dist/govuk/assets/rebrand/images/govuk-icon-mask.svg +1 -0
  44. data/node_modules/govuk-frontend/dist/govuk/assets/rebrand/images/govuk-opengraph-image.png +0 -0
  45. data/node_modules/govuk-frontend/dist/govuk/assets/rebrand/manifest.json +39 -0
  46. data/node_modules/govuk-frontend/dist/govuk/common/closest-attribute-value.mjs +7 -0
  47. data/node_modules/govuk-frontend/dist/govuk/common/closest-attribute-value.mjs.map +1 -0
  48. data/node_modules/govuk-frontend/dist/govuk/common/configuration.mjs +169 -0
  49. data/node_modules/govuk-frontend/dist/govuk/common/configuration.mjs.map +1 -0
  50. data/node_modules/govuk-frontend/dist/govuk/common/govuk-frontend-version.mjs +4 -0
  51. data/node_modules/govuk-frontend/dist/govuk/common/govuk-frontend-version.mjs.map +1 -0
  52. data/node_modules/govuk-frontend/dist/govuk/common/index.mjs +76 -0
  53. data/node_modules/govuk-frontend/dist/govuk/common/index.mjs.map +1 -0
  54. data/node_modules/govuk-frontend/dist/govuk/component.mjs +60 -0
  55. data/node_modules/govuk-frontend/dist/govuk/component.mjs.map +1 -0
  56. data/node_modules/govuk-frontend/dist/govuk/components/_all.scss +10 -0
  57. data/node_modules/govuk-frontend/dist/govuk/components/_all.scss.map +1 -0
  58. data/node_modules/govuk-frontend/dist/govuk/components/_index.scss +40 -0
  59. data/node_modules/govuk-frontend/dist/govuk/components/_index.scss.map +1 -0
  60. data/node_modules/govuk-frontend/dist/govuk/components/accordion/README.md +15 -0
  61. data/node_modules/govuk-frontend/dist/govuk/components/accordion/_accordion.scss +4 -0
  62. data/node_modules/govuk-frontend/dist/govuk/components/accordion/_accordion.scss.map +1 -0
  63. data/node_modules/govuk-frontend/dist/govuk/components/accordion/_index.scss +370 -0
  64. data/node_modules/govuk-frontend/dist/govuk/components/accordion/_index.scss.map +1 -0
  65. data/node_modules/govuk-frontend/dist/govuk/components/accordion/accordion.bundle.js +830 -0
  66. data/node_modules/govuk-frontend/dist/govuk/components/accordion/accordion.bundle.js.map +1 -0
  67. data/node_modules/govuk-frontend/dist/govuk/components/accordion/accordion.bundle.mjs +822 -0
  68. data/node_modules/govuk-frontend/dist/govuk/components/accordion/accordion.bundle.mjs.map +1 -0
  69. data/node_modules/govuk-frontend/dist/govuk/components/accordion/accordion.mjs +346 -0
  70. data/node_modules/govuk-frontend/dist/govuk/components/accordion/accordion.mjs.map +1 -0
  71. data/node_modules/govuk-frontend/dist/govuk/components/accordion/fixtures.json +377 -0
  72. data/node_modules/govuk-frontend/dist/govuk/components/accordion/macro-options.json +142 -0
  73. data/node_modules/govuk-frontend/dist/govuk/components/accordion/macro.njk +3 -0
  74. data/node_modules/govuk-frontend/dist/govuk/components/accordion/template-default.html +30 -0
  75. data/node_modules/govuk-frontend/dist/govuk/components/accordion/template-with-additional-descriptions.html +39 -0
  76. data/node_modules/govuk-frontend/dist/govuk/components/accordion/template-with-all-sections-already-open.html +30 -0
  77. data/node_modules/govuk-frontend/dist/govuk/components/accordion/template-with-long-content-and-description.html +36 -0
  78. data/node_modules/govuk-frontend/dist/govuk/components/accordion/template.njk +67 -0
  79. data/node_modules/govuk-frontend/dist/govuk/components/back-link/README.md +15 -0
  80. data/node_modules/govuk-frontend/dist/govuk/components/back-link/_back-link.scss +4 -0
  81. data/node_modules/govuk-frontend/dist/govuk/components/back-link/_back-link.scss.map +1 -0
  82. data/node_modules/govuk-frontend/dist/govuk/components/back-link/_index.scss +83 -0
  83. data/node_modules/govuk-frontend/dist/govuk/components/back-link/_index.scss.map +1 -0
  84. data/node_modules/govuk-frontend/dist/govuk/components/back-link/fixtures.json +86 -0
  85. data/node_modules/govuk-frontend/dist/govuk/components/back-link/macro-options.json +32 -0
  86. data/node_modules/govuk-frontend/dist/govuk/components/back-link/macro.njk +3 -0
  87. data/node_modules/govuk-frontend/dist/govuk/components/back-link/template-default.html +1 -0
  88. data/node_modules/govuk-frontend/dist/govuk/components/back-link/template-inverse.html +1 -0
  89. data/node_modules/govuk-frontend/dist/govuk/components/back-link/template.njk +6 -0
  90. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/README.md +15 -0
  91. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/_breadcrumbs.scss +4 -0
  92. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/_breadcrumbs.scss.map +1 -0
  93. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/_index.scss +134 -0
  94. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/_index.scss.map +1 -0
  95. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/fixtures.json +258 -0
  96. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/macro-options.json +58 -0
  97. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/macro.njk +3 -0
  98. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/template-default.html +16 -0
  99. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/template-inverse.html +11 -0
  100. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/template-with-collapse-on-mobile.html +13 -0
  101. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/template-with-last-breadcrumb-as-current-page.html +11 -0
  102. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/template-with-one-level.html +7 -0
  103. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/template-without-the-home-section.html +10 -0
  104. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/template.njk +30 -0
  105. data/node_modules/govuk-frontend/dist/govuk/components/button/README.md +15 -0
  106. data/node_modules/govuk-frontend/dist/govuk/components/button/_button.scss +4 -0
  107. data/node_modules/govuk-frontend/dist/govuk/components/button/_button.scss.map +1 -0
  108. data/node_modules/govuk-frontend/dist/govuk/components/button/_index.scss +262 -0
  109. data/node_modules/govuk-frontend/dist/govuk/components/button/_index.scss.map +1 -0
  110. data/node_modules/govuk-frontend/dist/govuk/components/button/button.bundle.js +363 -0
  111. data/node_modules/govuk-frontend/dist/govuk/components/button/button.bundle.js.map +1 -0
  112. data/node_modules/govuk-frontend/dist/govuk/components/button/button.bundle.mjs +355 -0
  113. data/node_modules/govuk-frontend/dist/govuk/components/button/button.bundle.mjs.map +1 -0
  114. data/node_modules/govuk-frontend/dist/govuk/components/button/button.mjs +70 -0
  115. data/node_modules/govuk-frontend/dist/govuk/components/button/button.mjs.map +1 -0
  116. data/node_modules/govuk-frontend/dist/govuk/components/button/fixtures.json +368 -0
  117. data/node_modules/govuk-frontend/dist/govuk/components/button/macro-options.json +81 -0
  118. data/node_modules/govuk-frontend/dist/govuk/components/button/macro.njk +3 -0
  119. data/node_modules/govuk-frontend/dist/govuk/components/button/template-default.html +3 -0
  120. data/node_modules/govuk-frontend/dist/govuk/components/button/template-disabled.html +3 -0
  121. data/node_modules/govuk-frontend/dist/govuk/components/button/template-input.html +1 -0
  122. data/node_modules/govuk-frontend/dist/govuk/components/button/template-inverse.html +3 -0
  123. data/node_modules/govuk-frontend/dist/govuk/components/button/template-link.html +3 -0
  124. data/node_modules/govuk-frontend/dist/govuk/components/button/template-secondary.html +3 -0
  125. data/node_modules/govuk-frontend/dist/govuk/components/button/template-start.html +6 -0
  126. data/node_modules/govuk-frontend/dist/govuk/components/button/template-warning.html +3 -0
  127. data/node_modules/govuk-frontend/dist/govuk/components/button/template.njk +58 -0
  128. data/node_modules/govuk-frontend/dist/govuk/components/character-count/README.md +15 -0
  129. data/node_modules/govuk-frontend/dist/govuk/components/character-count/_character-count.scss +4 -0
  130. data/node_modules/govuk-frontend/dist/govuk/components/character-count/_character-count.scss.map +1 -0
  131. data/node_modules/govuk-frontend/dist/govuk/components/character-count/_index.scss +44 -0
  132. data/node_modules/govuk-frontend/dist/govuk/components/character-count/_index.scss.map +1 -0
  133. data/node_modules/govuk-frontend/dist/govuk/components/character-count/character-count.bundle.js +806 -0
  134. data/node_modules/govuk-frontend/dist/govuk/components/character-count/character-count.bundle.js.map +1 -0
  135. data/node_modules/govuk-frontend/dist/govuk/components/character-count/character-count.bundle.mjs +798 -0
  136. data/node_modules/govuk-frontend/dist/govuk/components/character-count/character-count.bundle.mjs.map +1 -0
  137. data/node_modules/govuk-frontend/dist/govuk/components/character-count/character-count.mjs +299 -0
  138. data/node_modules/govuk-frontend/dist/govuk/components/character-count/character-count.mjs.map +1 -0
  139. data/node_modules/govuk-frontend/dist/govuk/components/character-count/fixtures.json +463 -0
  140. data/node_modules/govuk-frontend/dist/govuk/components/character-count/macro-options.json +199 -0
  141. data/node_modules/govuk-frontend/dist/govuk/components/character-count/macro.njk +3 -0
  142. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-default.html +9 -0
  143. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-custom-rows.html +9 -0
  144. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-default-value-exceeding-limit.html +15 -0
  145. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-default-value.html +12 -0
  146. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-hint-and-error.html +15 -0
  147. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-hint.html +12 -0
  148. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-label-as-page-heading.html +11 -0
  149. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-threshold.html +9 -0
  150. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-word-count.html +9 -0
  151. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template.njk +121 -0
  152. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/README.md +15 -0
  153. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/_checkboxes.scss +4 -0
  154. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/_checkboxes.scss.map +1 -0
  155. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/_index.scss +311 -0
  156. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/_index.scss.map +1 -0
  157. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/checkboxes.bundle.js +248 -0
  158. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/checkboxes.bundle.js.map +1 -0
  159. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/checkboxes.bundle.mjs +240 -0
  160. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/checkboxes.bundle.mjs.map +1 -0
  161. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/checkboxes.mjs +111 -0
  162. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/checkboxes.mjs.map +1 -0
  163. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/fixtures.json +1339 -0
  164. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/macro-options.json +229 -0
  165. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/macro.njk +3 -0
  166. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-default.html +27 -0
  167. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-small-with-conditional-reveal.html +25 -0
  168. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-small-with-divider-and-none.html +34 -0
  169. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-small-with-error.html +30 -0
  170. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-small-with-hint.html +30 -0
  171. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-small-with-long-text.html +27 -0
  172. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-small.html +27 -0
  173. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-conditional-items.html +39 -0
  174. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-divider-and-none.html +34 -0
  175. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-divider-none-and-conditional-items.html +44 -0
  176. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-error-message.html +39 -0
  177. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-hint.html +30 -0
  178. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-hints-on-items.html +27 -0
  179. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-legend-as-a-page-heading.html +32 -0
  180. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-optional-form-group-classes-showing-group-error.html +40 -0
  181. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-pre-checked-values.html +39 -0
  182. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-very-long-option-text.html +30 -0
  183. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template.njk +122 -0
  184. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/README.md +15 -0
  185. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/_cookie-banner.scss +4 -0
  186. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/_cookie-banner.scss.map +1 -0
  187. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/_index.scss +59 -0
  188. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/_index.scss.map +1 -0
  189. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/fixtures.json +543 -0
  190. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/macro-options.json +132 -0
  191. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/macro.njk +3 -0
  192. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/template-accepted-confirmation-banner.html +19 -0
  193. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/template-default.html +26 -0
  194. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/template-rejected-confirmation-banner.html +19 -0
  195. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/template-with-html.html +27 -0
  196. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/template.njk +57 -0
  197. data/node_modules/govuk-frontend/dist/govuk/components/date-input/README.md +15 -0
  198. data/node_modules/govuk-frontend/dist/govuk/components/date-input/_date-input.scss +4 -0
  199. data/node_modules/govuk-frontend/dist/govuk/components/date-input/_date-input.scss.map +1 -0
  200. data/node_modules/govuk-frontend/dist/govuk/components/date-input/_index.scss +28 -0
  201. data/node_modules/govuk-frontend/dist/govuk/components/date-input/_index.scss.map +1 -0
  202. data/node_modules/govuk-frontend/dist/govuk/components/date-input/fixtures.json +672 -0
  203. data/node_modules/govuk-frontend/dist/govuk/components/date-input/macro-options.json +163 -0
  204. data/node_modules/govuk-frontend/dist/govuk/components/date-input/macro.njk +3 -0
  205. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-day-and-month.html +28 -0
  206. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-default.html +36 -0
  207. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-month-and-year.html +28 -0
  208. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-error-on-day-input.html +39 -0
  209. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-error-on-month-input.html +39 -0
  210. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-error-on-year-input.html +39 -0
  211. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-errors-and-hint.html +39 -0
  212. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-errors-only.html +36 -0
  213. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-items.html +36 -0
  214. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template.njk +106 -0
  215. data/node_modules/govuk-frontend/dist/govuk/components/details/README.md +15 -0
  216. data/node_modules/govuk-frontend/dist/govuk/components/details/_details.scss +4 -0
  217. data/node_modules/govuk-frontend/dist/govuk/components/details/_details.scss.map +1 -0
  218. data/node_modules/govuk-frontend/dist/govuk/components/details/_index.scss +139 -0
  219. data/node_modules/govuk-frontend/dist/govuk/components/details/_index.scss.map +1 -0
  220. data/node_modules/govuk-frontend/dist/govuk/components/details/fixtures.json +133 -0
  221. data/node_modules/govuk-frontend/dist/govuk/components/details/implementation.md +87 -0
  222. data/node_modules/govuk-frontend/dist/govuk/components/details/macro-options.json +56 -0
  223. data/node_modules/govuk-frontend/dist/govuk/components/details/macro.njk +3 -0
  224. data/node_modules/govuk-frontend/dist/govuk/components/details/template-default.html +10 -0
  225. data/node_modules/govuk-frontend/dist/govuk/components/details/template-expanded.html +10 -0
  226. data/node_modules/govuk-frontend/dist/govuk/components/details/template-with-html.html +18 -0
  227. data/node_modules/govuk-frontend/dist/govuk/components/details/template.njk +14 -0
  228. data/node_modules/govuk-frontend/dist/govuk/components/error-message/README.md +15 -0
  229. data/node_modules/govuk-frontend/dist/govuk/components/error-message/_error-message.scss +4 -0
  230. data/node_modules/govuk-frontend/dist/govuk/components/error-message/_error-message.scss.map +1 -0
  231. data/node_modules/govuk-frontend/dist/govuk/components/error-message/_index.scss +14 -0
  232. data/node_modules/govuk-frontend/dist/govuk/components/error-message/_index.scss.map +1 -0
  233. data/node_modules/govuk-frontend/dist/govuk/components/error-message/fixtures.json +113 -0
  234. data/node_modules/govuk-frontend/dist/govuk/components/error-message/macro-options.json +38 -0
  235. data/node_modules/govuk-frontend/dist/govuk/components/error-message/macro.njk +3 -0
  236. data/node_modules/govuk-frontend/dist/govuk/components/error-message/template-default.html +3 -0
  237. data/node_modules/govuk-frontend/dist/govuk/components/error-message/template-translated.html +3 -0
  238. data/node_modules/govuk-frontend/dist/govuk/components/error-message/template.njk +13 -0
  239. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/README.md +15 -0
  240. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/_error-summary.scss +4 -0
  241. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/_error-summary.scss.map +1 -0
  242. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/_index.scss +56 -0
  243. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/_index.scss.map +1 -0
  244. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/error-summary.bundle.js +423 -0
  245. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/error-summary.bundle.js.map +1 -0
  246. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/error-summary.bundle.mjs +415 -0
  247. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/error-summary.bundle.mjs.map +1 -0
  248. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/error-summary.mjs +101 -0
  249. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/error-summary.mjs.map +1 -0
  250. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/fixtures.json +326 -0
  251. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/macro-options.json +82 -0
  252. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/macro.njk +3 -0
  253. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/template-default.html +17 -0
  254. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/template-mixed-with-and-without-links.html +17 -0
  255. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/template-with-description-only.html +12 -0
  256. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/template-with-everything.html +20 -0
  257. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/template-without-links.html +14 -0
  258. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/template.njk +37 -0
  259. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/README.md +15 -0
  260. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/_exit-this-page.scss +4 -0
  261. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/_exit-this-page.scss.map +1 -0
  262. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/_index.scss +92 -0
  263. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/_index.scss.map +1 -0
  264. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/exit-this-page.bundle.js +707 -0
  265. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/exit-this-page.bundle.js.map +1 -0
  266. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/exit-this-page.bundle.mjs +699 -0
  267. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/exit-this-page.bundle.mjs.map +1 -0
  268. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/exit-this-page.mjs +223 -0
  269. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/exit-this-page.mjs.map +1 -0
  270. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/fixtures.json +62 -0
  271. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/macro-options.json +62 -0
  272. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/macro.njk +3 -0
  273. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/template-default.html +5 -0
  274. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/template.njk +25 -0
  275. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/README.md +15 -0
  276. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/_fieldset.scss +4 -0
  277. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/_fieldset.scss.map +1 -0
  278. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/_index.scss +69 -0
  279. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/_index.scss.map +1 -0
  280. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/fixtures.json +260 -0
  281. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/macro-options.json +70 -0
  282. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/macro.njk +3 -0
  283. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/template-as-page-heading-l.html +7 -0
  284. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/template-as-page-heading-m.html +7 -0
  285. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/template-as-page-heading-s.html +7 -0
  286. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/template-as-page-heading-without-class.html +7 -0
  287. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/template-as-page-heading-xl.html +7 -0
  288. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/template-default.html +5 -0
  289. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/template-styled-as-large-text.html +5 -0
  290. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/template-styled-as-medium-text.html +5 -0
  291. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/template-styled-as-small-text.html +5 -0
  292. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/template-styled-as-xl-text.html +5 -0
  293. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/template.njk +24 -0
  294. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/README.md +15 -0
  295. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/_file-upload.scss +4 -0
  296. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/_file-upload.scss.map +1 -0
  297. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/_index.scss +218 -0
  298. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/_index.scss.map +1 -0
  299. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/file-upload.bundle.js +744 -0
  300. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/file-upload.bundle.js.map +1 -0
  301. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/file-upload.bundle.mjs +736 -0
  302. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/file-upload.bundle.mjs.map +1 -0
  303. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/file-upload.mjs +257 -0
  304. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/file-upload.mjs.map +1 -0
  305. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/fixtures.json +378 -0
  306. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/macro-options.json +174 -0
  307. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/macro.njk +3 -0
  308. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template-default.html +6 -0
  309. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template-enhanced-with-error-message-and-hint.html +16 -0
  310. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template-enhanced.html +10 -0
  311. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template-translated.html +10 -0
  312. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template-with-error-message-and-hint.html +12 -0
  313. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template-with-hint-text.html +9 -0
  314. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template-with-label-as-page-heading.html +8 -0
  315. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template.njk +90 -0
  316. data/node_modules/govuk-frontend/dist/govuk/components/footer/README.md +15 -0
  317. data/node_modules/govuk-frontend/dist/govuk/components/footer/_footer.scss +4 -0
  318. data/node_modules/govuk-frontend/dist/govuk/components/footer/_footer.scss.map +1 -0
  319. data/node_modules/govuk-frontend/dist/govuk/components/footer/_index.scss +194 -0
  320. data/node_modules/govuk-frontend/dist/govuk/components/footer/_index.scss.map +1 -0
  321. data/node_modules/govuk-frontend/dist/govuk/components/footer/fixtures.json +712 -0
  322. data/node_modules/govuk-frontend/dist/govuk/components/footer/macro-options.json +170 -0
  323. data/node_modules/govuk-frontend/dist/govuk/components/footer/macro.njk +3 -0
  324. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-default.html +38 -0
  325. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-full-gds-example.html +212 -0
  326. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-three-equal-columns.html +146 -0
  327. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-with-custom-html-content-licence-and-copyright-notice.html +33 -0
  328. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-with-custom-meta.html +42 -0
  329. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-with-custom-text-content-licence-and-copyright-notice.html +33 -0
  330. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-with-default-width-navigation-one-column.html +76 -0
  331. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-with-default-width-navigation-two-columns.html +76 -0
  332. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-with-meta-links-and-meta-content.html +84 -0
  333. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-with-navigation.html +96 -0
  334. data/node_modules/govuk-frontend/dist/govuk/components/footer/template.njk +107 -0
  335. data/node_modules/govuk-frontend/dist/govuk/components/header/README.md +15 -0
  336. data/node_modules/govuk-frontend/dist/govuk/components/header/_header.scss +4 -0
  337. data/node_modules/govuk-frontend/dist/govuk/components/header/_header.scss.map +1 -0
  338. data/node_modules/govuk-frontend/dist/govuk/components/header/_index.scss +548 -0
  339. data/node_modules/govuk-frontend/dist/govuk/components/header/_index.scss.map +1 -0
  340. data/node_modules/govuk-frontend/dist/govuk/components/header/fixtures.json +602 -0
  341. data/node_modules/govuk-frontend/dist/govuk/components/header/header.bundle.js +233 -0
  342. data/node_modules/govuk-frontend/dist/govuk/components/header/header.bundle.js.map +1 -0
  343. data/node_modules/govuk-frontend/dist/govuk/components/header/header.bundle.mjs +225 -0
  344. data/node_modules/govuk-frontend/dist/govuk/components/header/header.bundle.mjs.map +1 -0
  345. data/node_modules/govuk-frontend/dist/govuk/components/header/header.mjs +89 -0
  346. data/node_modules/govuk-frontend/dist/govuk/components/header/header.mjs.map +1 -0
  347. data/node_modules/govuk-frontend/dist/govuk/components/header/macro-options.json +131 -0
  348. data/node_modules/govuk-frontend/dist/govuk/components/header/macro.njk +3 -0
  349. data/node_modules/govuk-frontend/dist/govuk/components/header/template-default.html +29 -0
  350. data/node_modules/govuk-frontend/dist/govuk/components/header/template-full-width-with-navigation.html +54 -0
  351. data/node_modules/govuk-frontend/dist/govuk/components/header/template-full-width.html +29 -0
  352. data/node_modules/govuk-frontend/dist/govuk/components/header/template-navigation-item-with-html.html +54 -0
  353. data/node_modules/govuk-frontend/dist/govuk/components/header/template-navigation-item-with-text-without-link.html +48 -0
  354. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-custom-menu-button-text.html +59 -0
  355. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-full-width-border.html +29 -0
  356. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-large-navigation.html +119 -0
  357. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-navigation.html +59 -0
  358. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-product-name.html +30 -0
  359. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-service-name-and-navigation.html +62 -0
  360. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-service-name-but-no-service-url.html +34 -0
  361. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-service-name.html +34 -0
  362. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-st-edwards-crown.html +19 -0
  363. data/node_modules/govuk-frontend/dist/govuk/components/header/template.njk +66 -0
  364. data/node_modules/govuk-frontend/dist/govuk/components/hint/README.md +15 -0
  365. data/node_modules/govuk-frontend/dist/govuk/components/hint/_hint.scss +4 -0
  366. data/node_modules/govuk-frontend/dist/govuk/components/hint/_hint.scss.map +1 -0
  367. data/node_modules/govuk-frontend/dist/govuk/components/hint/_index.scss +45 -0
  368. data/node_modules/govuk-frontend/dist/govuk/components/hint/_index.scss.map +1 -0
  369. data/node_modules/govuk-frontend/dist/govuk/components/hint/fixtures.json +77 -0
  370. data/node_modules/govuk-frontend/dist/govuk/components/hint/macro-options.json +32 -0
  371. data/node_modules/govuk-frontend/dist/govuk/components/hint/macro.njk +3 -0
  372. data/node_modules/govuk-frontend/dist/govuk/components/hint/template-default.html +5 -0
  373. data/node_modules/govuk-frontend/dist/govuk/components/hint/template-with-html.html +4 -0
  374. data/node_modules/govuk-frontend/dist/govuk/components/hint/template.njk +6 -0
  375. data/node_modules/govuk-frontend/dist/govuk/components/input/README.md +15 -0
  376. data/node_modules/govuk-frontend/dist/govuk/components/input/_index.scss +168 -0
  377. data/node_modules/govuk-frontend/dist/govuk/components/input/_index.scss.map +1 -0
  378. data/node_modules/govuk-frontend/dist/govuk/components/input/_input.scss +4 -0
  379. data/node_modules/govuk-frontend/dist/govuk/components/input/_input.scss.map +1 -0
  380. data/node_modules/govuk-frontend/dist/govuk/components/input/fixtures.json +830 -0
  381. data/node_modules/govuk-frontend/dist/govuk/components/input/macro-options.json +245 -0
  382. data/node_modules/govuk-frontend/dist/govuk/components/input/macro.njk +3 -0
  383. data/node_modules/govuk-frontend/dist/govuk/components/input/template-default.html +6 -0
  384. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-error-and-hint.html +12 -0
  385. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-error-message.html +9 -0
  386. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-extra-letter-spacing.html +6 -0
  387. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-hint-text.html +9 -0
  388. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-label-as-page-heading.html +8 -0
  389. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-prefix-and-suffix-and-error.html +13 -0
  390. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-prefix-and-suffix-and-width-modifier.html +10 -0
  391. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-prefix-and-suffix.html +10 -0
  392. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-prefix.html +9 -0
  393. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-suffix.html +9 -0
  394. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-width-10-class.html +9 -0
  395. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-width-2-class.html +9 -0
  396. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-width-20-class.html +9 -0
  397. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-width-3-class.html +9 -0
  398. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-width-30-class.html +9 -0
  399. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-width-4-class.html +9 -0
  400. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-width-5-class.html +9 -0
  401. data/node_modules/govuk-frontend/dist/govuk/components/input/template.njk +133 -0
  402. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/README.md +15 -0
  403. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/_index.scss +26 -0
  404. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/_index.scss.map +1 -0
  405. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/_inset-text.scss +4 -0
  406. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/_inset-text.scss.map +1 -0
  407. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/fixtures.json +76 -0
  408. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/macro-options.json +38 -0
  409. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/macro.njk +3 -0
  410. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/template-default.html +3 -0
  411. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/template-with-html.html +11 -0
  412. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/template.njk +6 -0
  413. data/node_modules/govuk-frontend/dist/govuk/components/label/README.md +15 -0
  414. data/node_modules/govuk-frontend/dist/govuk/components/label/_index.scss +46 -0
  415. data/node_modules/govuk-frontend/dist/govuk/components/label/_index.scss.map +1 -0
  416. data/node_modules/govuk-frontend/dist/govuk/components/label/_label.scss +4 -0
  417. data/node_modules/govuk-frontend/dist/govuk/components/label/_label.scss.map +1 -0
  418. data/node_modules/govuk-frontend/dist/govuk/components/label/fixtures.json +210 -0
  419. data/node_modules/govuk-frontend/dist/govuk/components/label/macro-options.json +38 -0
  420. data/node_modules/govuk-frontend/dist/govuk/components/label/macro.njk +3 -0
  421. data/node_modules/govuk-frontend/dist/govuk/components/label/template-as-page-heading-l.html +5 -0
  422. data/node_modules/govuk-frontend/dist/govuk/components/label/template-as-page-heading-m.html +5 -0
  423. data/node_modules/govuk-frontend/dist/govuk/components/label/template-as-page-heading-s.html +5 -0
  424. data/node_modules/govuk-frontend/dist/govuk/components/label/template-as-page-heading-without-class.html +5 -0
  425. data/node_modules/govuk-frontend/dist/govuk/components/label/template-as-page-heading-xl.html +5 -0
  426. data/node_modules/govuk-frontend/dist/govuk/components/label/template-default.html +3 -0
  427. data/node_modules/govuk-frontend/dist/govuk/components/label/template-styled-as-large-text.html +3 -0
  428. data/node_modules/govuk-frontend/dist/govuk/components/label/template-styled-as-medium-text.html +3 -0
  429. data/node_modules/govuk-frontend/dist/govuk/components/label/template-styled-as-small-text.html +3 -0
  430. data/node_modules/govuk-frontend/dist/govuk/components/label/template-styled-as-xl-text.html +3 -0
  431. data/node_modules/govuk-frontend/dist/govuk/components/label/template-with-bold-text.html +3 -0
  432. data/node_modules/govuk-frontend/dist/govuk/components/label/template.njk +19 -0
  433. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/README.md +15 -0
  434. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/_index.scss +93 -0
  435. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/_index.scss.map +1 -0
  436. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/_notification-banner.scss +4 -0
  437. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/_notification-banner.scss.map +1 -0
  438. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/fixtures.json +260 -0
  439. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/macro-options.json +74 -0
  440. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/macro.njk +3 -0
  441. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/notification-banner.bundle.js +365 -0
  442. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/notification-banner.bundle.js.map +1 -0
  443. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/notification-banner.bundle.mjs +357 -0
  444. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/notification-banner.bundle.mjs.map +1 -0
  445. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/notification-banner.mjs +49 -0
  446. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/notification-banner.mjs.map +1 -0
  447. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/template-default.html +12 -0
  448. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/template-with-long-heading.html +12 -0
  449. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/template-with-lots-of-content.html +19 -0
  450. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/template-with-text-as-html.html +21 -0
  451. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/template-with-type-as-success.html +12 -0
  452. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/template.njk +49 -0
  453. data/node_modules/govuk-frontend/dist/govuk/components/pagination/README.md +15 -0
  454. data/node_modules/govuk-frontend/dist/govuk/components/pagination/_index.scss +228 -0
  455. data/node_modules/govuk-frontend/dist/govuk/components/pagination/_index.scss.map +1 -0
  456. data/node_modules/govuk-frontend/dist/govuk/components/pagination/_pagination.scss +4 -0
  457. data/node_modules/govuk-frontend/dist/govuk/components/pagination/_pagination.scss.map +1 -0
  458. data/node_modules/govuk-frontend/dist/govuk/components/pagination/fixtures.json +393 -0
  459. data/node_modules/govuk-frontend/dist/govuk/components/pagination/macro-options.json +140 -0
  460. data/node_modules/govuk-frontend/dist/govuk/components/pagination/macro.njk +3 -0
  461. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template-default.html +39 -0
  462. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template-first-page.html +29 -0
  463. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template-last-page.html +29 -0
  464. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template-with-custom-link-and-item-text.html +39 -0
  465. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template-with-many-pages.html +65 -0
  466. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template-with-next-only.html +12 -0
  467. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template-with-prev-and-next-only-and-labels.html +26 -0
  468. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template-with-prev-and-next-only-and-very-long-labels.html +26 -0
  469. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template-with-prev-and-next-only.html +22 -0
  470. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template-with-previous-only.html +12 -0
  471. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template.njk +85 -0
  472. data/node_modules/govuk-frontend/dist/govuk/components/panel/README.md +15 -0
  473. data/node_modules/govuk-frontend/dist/govuk/components/panel/_index.scss +58 -0
  474. data/node_modules/govuk-frontend/dist/govuk/components/panel/_index.scss.map +1 -0
  475. data/node_modules/govuk-frontend/dist/govuk/components/panel/_panel.scss +4 -0
  476. data/node_modules/govuk-frontend/dist/govuk/components/panel/_panel.scss.map +1 -0
  477. data/node_modules/govuk-frontend/dist/govuk/components/panel/fixtures.json +118 -0
  478. data/node_modules/govuk-frontend/dist/govuk/components/panel/macro-options.json +50 -0
  479. data/node_modules/govuk-frontend/dist/govuk/components/panel/macro.njk +3 -0
  480. data/node_modules/govuk-frontend/dist/govuk/components/panel/template-default.html +8 -0
  481. data/node_modules/govuk-frontend/dist/govuk/components/panel/template.njk +16 -0
  482. data/node_modules/govuk-frontend/dist/govuk/components/password-input/_index.scss +57 -0
  483. data/node_modules/govuk-frontend/dist/govuk/components/password-input/_index.scss.map +1 -0
  484. data/node_modules/govuk-frontend/dist/govuk/components/password-input/_password-input.scss +4 -0
  485. data/node_modules/govuk-frontend/dist/govuk/components/password-input/_password-input.scss.map +1 -0
  486. data/node_modules/govuk-frontend/dist/govuk/components/password-input/fixtures.json +215 -0
  487. data/node_modules/govuk-frontend/dist/govuk/components/password-input/macro-options.json +181 -0
  488. data/node_modules/govuk-frontend/dist/govuk/components/password-input/macro.njk +3 -0
  489. data/node_modules/govuk-frontend/dist/govuk/components/password-input/password-input.bundle.js +638 -0
  490. data/node_modules/govuk-frontend/dist/govuk/components/password-input/password-input.bundle.js.map +1 -0
  491. data/node_modules/govuk-frontend/dist/govuk/components/password-input/password-input.bundle.mjs +630 -0
  492. data/node_modules/govuk-frontend/dist/govuk/components/password-input/password-input.bundle.mjs.map +1 -0
  493. data/node_modules/govuk-frontend/dist/govuk/components/password-input/password-input.mjs +150 -0
  494. data/node_modules/govuk-frontend/dist/govuk/components/password-input/password-input.mjs.map +1 -0
  495. data/node_modules/govuk-frontend/dist/govuk/components/password-input/template-default.html +11 -0
  496. data/node_modules/govuk-frontend/dist/govuk/components/password-input/template-with-error-message.html +17 -0
  497. data/node_modules/govuk-frontend/dist/govuk/components/password-input/template-with-hint-text.html +14 -0
  498. data/node_modules/govuk-frontend/dist/govuk/components/password-input/template-with-input-width-class.html +11 -0
  499. data/node_modules/govuk-frontend/dist/govuk/components/password-input/template-with-label-as-page-heading.html +13 -0
  500. data/node_modules/govuk-frontend/dist/govuk/components/password-input/template.njk +93 -0
  501. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/README.md +15 -0
  502. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/_index.scss +36 -0
  503. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/_index.scss.map +1 -0
  504. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/_phase-banner.scss +4 -0
  505. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/_phase-banner.scss.map +1 -0
  506. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/fixtures.json +97 -0
  507. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/macro-options.json +33 -0
  508. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/macro.njk +3 -0
  509. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/template-default.html +10 -0
  510. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/template.njk +17 -0
  511. data/node_modules/govuk-frontend/dist/govuk/components/radios/README.md +15 -0
  512. data/node_modules/govuk-frontend/dist/govuk/components/radios/_index.scss +328 -0
  513. data/node_modules/govuk-frontend/dist/govuk/components/radios/_index.scss.map +1 -0
  514. data/node_modules/govuk-frontend/dist/govuk/components/radios/_radios.scss +4 -0
  515. data/node_modules/govuk-frontend/dist/govuk/components/radios/_radios.scss.map +1 -0
  516. data/node_modules/govuk-frontend/dist/govuk/components/radios/fixtures.json +1334 -0
  517. data/node_modules/govuk-frontend/dist/govuk/components/radios/macro-options.json +211 -0
  518. data/node_modules/govuk-frontend/dist/govuk/components/radios/macro.njk +3 -0
  519. data/node_modules/govuk-frontend/dist/govuk/components/radios/radios.bundle.js +225 -0
  520. data/node_modules/govuk-frontend/dist/govuk/components/radios/radios.bundle.js.map +1 -0
  521. data/node_modules/govuk-frontend/dist/govuk/components/radios/radios.bundle.mjs +217 -0
  522. data/node_modules/govuk-frontend/dist/govuk/components/radios/radios.bundle.mjs.map +1 -0
  523. data/node_modules/govuk-frontend/dist/govuk/components/radios/radios.mjs +88 -0
  524. data/node_modules/govuk-frontend/dist/govuk/components/radios/radios.mjs.map +1 -0
  525. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-default.html +21 -0
  526. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-inline.html +24 -0
  527. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-small-inline.html +27 -0
  528. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-small-with-a-divider.html +28 -0
  529. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-small-with-conditional-reveal.html +31 -0
  530. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-small-with-error.html +30 -0
  531. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-small-with-hint.html +30 -0
  532. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-small-with-long-text.html +27 -0
  533. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-small.html +27 -0
  534. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-a-divider.html +28 -0
  535. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-conditional-item-checked.html +39 -0
  536. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-conditional-items-and-pre-checked-value.html +39 -0
  537. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-conditional-items.html +39 -0
  538. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-fieldset-and-error-message.html +24 -0
  539. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-hint.html +24 -0
  540. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-hints-on-items.html +29 -0
  541. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-legend-as-page-heading.html +26 -0
  542. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-optional-form-group-classes-showing-group-error.html +40 -0
  543. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-very-long-option-text.html +33 -0
  544. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-without-fieldset.html +22 -0
  545. data/node_modules/govuk-frontend/dist/govuk/components/radios/template.njk +115 -0
  546. data/node_modules/govuk-frontend/dist/govuk/components/select/README.md +15 -0
  547. data/node_modules/govuk-frontend/dist/govuk/components/select/_index.scss +59 -0
  548. data/node_modules/govuk-frontend/dist/govuk/components/select/_index.scss.map +1 -0
  549. data/node_modules/govuk-frontend/dist/govuk/components/select/_select.scss +4 -0
  550. data/node_modules/govuk-frontend/dist/govuk/components/select/_select.scss.map +1 -0
  551. data/node_modules/govuk-frontend/dist/govuk/components/select/fixtures.json +550 -0
  552. data/node_modules/govuk-frontend/dist/govuk/components/select/macro-options.json +163 -0
  553. data/node_modules/govuk-frontend/dist/govuk/components/select/macro.njk +3 -0
  554. data/node_modules/govuk-frontend/dist/govuk/components/select/template-default.html +10 -0
  555. data/node_modules/govuk-frontend/dist/govuk/components/select/template-with-full-width-override.html +10 -0
  556. data/node_modules/govuk-frontend/dist/govuk/components/select/template-with-hint-text-and-error-message.html +16 -0
  557. data/node_modules/govuk-frontend/dist/govuk/components/select/template-with-label-as-page-heading.html +12 -0
  558. data/node_modules/govuk-frontend/dist/govuk/components/select/template.njk +68 -0
  559. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/README.md +15 -0
  560. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/_index.scss +254 -0
  561. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/_index.scss.map +1 -0
  562. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/_service-navigation.scss +4 -0
  563. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/_service-navigation.scss.map +1 -0
  564. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/fixtures.json +651 -0
  565. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/macro-options.json +144 -0
  566. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/macro.njk +3 -0
  567. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/service-navigation.bundle.js +229 -0
  568. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/service-navigation.bundle.js.map +1 -0
  569. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/service-navigation.bundle.mjs +221 -0
  570. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/service-navigation.bundle.mjs.map +1 -0
  571. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/service-navigation.mjs +85 -0
  572. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/service-navigation.mjs.map +1 -0
  573. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-default.html +57 -0
  574. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-inverse.html +63 -0
  575. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-a-single-navigation-item-and-collapsenavigationonmobile-set-to-true.html +38 -0
  576. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-a-single-navigation-item.html +35 -0
  577. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-collapsenavigationonmobile-set-to-false.html +60 -0
  578. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-html-navigation-items.html +49 -0
  579. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-large-navigation.html +153 -0
  580. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-long-service-name.html +20 -0
  581. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-navigation-with-a-current-item.html +58 -0
  582. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-non-link-navigation-items.html +49 -0
  583. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-service-link.html +20 -0
  584. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-service-name-and-navigation.html +63 -0
  585. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-service-name.html +18 -0
  586. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template.njk +106 -0
  587. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/README.md +15 -0
  588. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/_index.scss +52 -0
  589. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/_index.scss.map +1 -0
  590. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/_skip-link.scss +4 -0
  591. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/_skip-link.scss.map +1 -0
  592. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/fixtures.json +113 -0
  593. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/macro-options.json +32 -0
  594. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/macro.njk +3 -0
  595. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/skip-link.bundle.js +224 -0
  596. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/skip-link.bundle.js.map +1 -0
  597. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/skip-link.bundle.mjs +216 -0
  598. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/skip-link.bundle.mjs.map +1 -0
  599. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/skip-link.mjs +58 -0
  600. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/skip-link.mjs.map +1 -0
  601. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/template-default.html +1 -0
  602. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/template-with-focus.html +1 -0
  603. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/template.njk +6 -0
  604. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/README.md +15 -0
  605. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/_index.scss +269 -0
  606. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/_index.scss.map +1 -0
  607. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/_summary-list.scss +4 -0
  608. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/_summary-list.scss.map +1 -0
  609. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/fixtures.json +1528 -0
  610. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/macro-options.json +248 -0
  611. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/macro.njk +3 -0
  612. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/template-as-a-summary-card-extreme.html +106 -0
  613. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/template-as-a-summary-card-with-a-html-header.html +28 -0
  614. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/template-as-a-summary-card-with-a-text-header.html +28 -0
  615. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/template-as-a-summary-card-with-actions-plus-summary-list-actions.html +49 -0
  616. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/template-as-a-summary-card-with-actions.html +36 -0
  617. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/template-default.html +35 -0
  618. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/template-extreme.html +261 -0
  619. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/template-no-border-on-last-row.html +35 -0
  620. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/template-no-border.html +35 -0
  621. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/template-with-actions.html +58 -0
  622. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/template.njk +94 -0
  623. data/node_modules/govuk-frontend/dist/govuk/components/table/README.md +15 -0
  624. data/node_modules/govuk-frontend/dist/govuk/components/table/_index.scss +75 -0
  625. data/node_modules/govuk-frontend/dist/govuk/components/table/_index.scss.map +1 -0
  626. data/node_modules/govuk-frontend/dist/govuk/components/table/_table.scss +4 -0
  627. data/node_modules/govuk-frontend/dist/govuk/components/table/_table.scss.map +1 -0
  628. data/node_modules/govuk-frontend/dist/govuk/components/table/fixtures.json +651 -0
  629. data/node_modules/govuk-frontend/dist/govuk/components/table/macro-options.json +132 -0
  630. data/node_modules/govuk-frontend/dist/govuk/components/table/macro.njk +3 -0
  631. data/node_modules/govuk-frontend/dist/govuk/components/table/template-default.html +19 -0
  632. data/node_modules/govuk-frontend/dist/govuk/components/table/template-with-head-and-caption.html +27 -0
  633. data/node_modules/govuk-frontend/dist/govuk/components/table/template-with-head.html +26 -0
  634. data/node_modules/govuk-frontend/dist/govuk/components/table/template.njk +57 -0
  635. data/node_modules/govuk-frontend/dist/govuk/components/tabs/README.md +15 -0
  636. data/node_modules/govuk-frontend/dist/govuk/components/tabs/_index.scss +134 -0
  637. data/node_modules/govuk-frontend/dist/govuk/components/tabs/_index.scss.map +1 -0
  638. data/node_modules/govuk-frontend/dist/govuk/components/tabs/_tabs.scss +4 -0
  639. data/node_modules/govuk-frontend/dist/govuk/components/tabs/_tabs.scss.map +1 -0
  640. data/node_modules/govuk-frontend/dist/govuk/components/tabs/fixtures.json +333 -0
  641. data/node_modules/govuk-frontend/dist/govuk/components/tabs/macro-options.json +84 -0
  642. data/node_modules/govuk-frontend/dist/govuk/components/tabs/macro.njk +3 -0
  643. data/node_modules/govuk-frontend/dist/govuk/components/tabs/tabs.bundle.js +433 -0
  644. data/node_modules/govuk-frontend/dist/govuk/components/tabs/tabs.bundle.js.map +1 -0
  645. data/node_modules/govuk-frontend/dist/govuk/components/tabs/tabs.bundle.mjs +425 -0
  646. data/node_modules/govuk-frontend/dist/govuk/components/tabs/tabs.bundle.mjs.map +1 -0
  647. data/node_modules/govuk-frontend/dist/govuk/components/tabs/tabs.mjs +283 -0
  648. data/node_modules/govuk-frontend/dist/govuk/components/tabs/tabs.mjs.map +1 -0
  649. data/node_modules/govuk-frontend/dist/govuk/components/tabs/template-default.html +117 -0
  650. data/node_modules/govuk-frontend/dist/govuk/components/tabs/template-tabs-with-anchor-in-panel.html +26 -0
  651. data/node_modules/govuk-frontend/dist/govuk/components/tabs/template.njk +48 -0
  652. data/node_modules/govuk-frontend/dist/govuk/components/tag/README.md +15 -0
  653. data/node_modules/govuk-frontend/dist/govuk/components/tag/_index.scss +97 -0
  654. data/node_modules/govuk-frontend/dist/govuk/components/tag/_index.scss.map +1 -0
  655. data/node_modules/govuk-frontend/dist/govuk/components/tag/_tag.scss +4 -0
  656. data/node_modules/govuk-frontend/dist/govuk/components/tag/_tag.scss.map +1 -0
  657. data/node_modules/govuk-frontend/dist/govuk/components/tag/fixtures.json +161 -0
  658. data/node_modules/govuk-frontend/dist/govuk/components/tag/macro-options.json +26 -0
  659. data/node_modules/govuk-frontend/dist/govuk/components/tag/macro.njk +3 -0
  660. data/node_modules/govuk-frontend/dist/govuk/components/tag/template-default.html +3 -0
  661. data/node_modules/govuk-frontend/dist/govuk/components/tag/template-green.html +3 -0
  662. data/node_modules/govuk-frontend/dist/govuk/components/tag/template-grey.html +3 -0
  663. data/node_modules/govuk-frontend/dist/govuk/components/tag/template-light-blue.html +3 -0
  664. data/node_modules/govuk-frontend/dist/govuk/components/tag/template-orange.html +3 -0
  665. data/node_modules/govuk-frontend/dist/govuk/components/tag/template-pink.html +3 -0
  666. data/node_modules/govuk-frontend/dist/govuk/components/tag/template-purple.html +3 -0
  667. data/node_modules/govuk-frontend/dist/govuk/components/tag/template-red.html +3 -0
  668. data/node_modules/govuk-frontend/dist/govuk/components/tag/template-turquoise.html +3 -0
  669. data/node_modules/govuk-frontend/dist/govuk/components/tag/template-yellow.html +3 -0
  670. data/node_modules/govuk-frontend/dist/govuk/components/tag/template.njk +6 -0
  671. data/node_modules/govuk-frontend/dist/govuk/components/task-list/README.md +15 -0
  672. data/node_modules/govuk-frontend/dist/govuk/components/task-list/_index.scss +79 -0
  673. data/node_modules/govuk-frontend/dist/govuk/components/task-list/_index.scss.map +1 -0
  674. data/node_modules/govuk-frontend/dist/govuk/components/task-list/_task-list.scss +4 -0
  675. data/node_modules/govuk-frontend/dist/govuk/components/task-list/_task-list.scss.map +1 -0
  676. data/node_modules/govuk-frontend/dist/govuk/components/task-list/fixtures.json +529 -0
  677. data/node_modules/govuk-frontend/dist/govuk/components/task-list/macro-options.json +119 -0
  678. data/node_modules/govuk-frontend/dist/govuk/components/task-list/macro.njk +3 -0
  679. data/node_modules/govuk-frontend/dist/govuk/components/task-list/template-default.html +37 -0
  680. data/node_modules/govuk-frontend/dist/govuk/components/task-list/template-with-all-possible-colours.html +143 -0
  681. data/node_modules/govuk-frontend/dist/govuk/components/task-list/template-with-empty-values.html +27 -0
  682. data/node_modules/govuk-frontend/dist/govuk/components/task-list/template-with-hint-text-and-additional-states.html +77 -0
  683. data/node_modules/govuk-frontend/dist/govuk/components/task-list/template-with-very-long-single-word-tags.html +37 -0
  684. data/node_modules/govuk-frontend/dist/govuk/components/task-list/template.njk +41 -0
  685. data/node_modules/govuk-frontend/dist/govuk/components/textarea/README.md +15 -0
  686. data/node_modules/govuk-frontend/dist/govuk/components/textarea/_index.scss +50 -0
  687. data/node_modules/govuk-frontend/dist/govuk/components/textarea/_index.scss.map +1 -0
  688. data/node_modules/govuk-frontend/dist/govuk/components/textarea/_textarea.scss +4 -0
  689. data/node_modules/govuk-frontend/dist/govuk/components/textarea/_textarea.scss.map +1 -0
  690. data/node_modules/govuk-frontend/dist/govuk/components/textarea/fixtures.json +316 -0
  691. data/node_modules/govuk-frontend/dist/govuk/components/textarea/macro-options.json +143 -0
  692. data/node_modules/govuk-frontend/dist/govuk/components/textarea/macro.njk +3 -0
  693. data/node_modules/govuk-frontend/dist/govuk/components/textarea/template-default.html +6 -0
  694. data/node_modules/govuk-frontend/dist/govuk/components/textarea/template-with-custom-rows.html +6 -0
  695. data/node_modules/govuk-frontend/dist/govuk/components/textarea/template-with-default-value.html +9 -0
  696. data/node_modules/govuk-frontend/dist/govuk/components/textarea/template-with-error-message.html +9 -0
  697. data/node_modules/govuk-frontend/dist/govuk/components/textarea/template-with-hint.html +9 -0
  698. data/node_modules/govuk-frontend/dist/govuk/components/textarea/template-with-label-as-page-heading.html +8 -0
  699. data/node_modules/govuk-frontend/dist/govuk/components/textarea/template.njk +56 -0
  700. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/README.md +15 -0
  701. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/_index.scss +66 -0
  702. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/_index.scss.map +1 -0
  703. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/_warning-text.scss +4 -0
  704. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/_warning-text.scss.map +1 -0
  705. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/fixtures.json +101 -0
  706. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/macro-options.json +32 -0
  707. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/macro.njk +3 -0
  708. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/template-default.html +7 -0
  709. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/template-multiple-lines.html +7 -0
  710. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/template.njk +10 -0
  711. data/node_modules/govuk-frontend/dist/govuk/core/_all.scss +10 -0
  712. data/node_modules/govuk-frontend/dist/govuk/core/_all.scss.map +1 -0
  713. data/node_modules/govuk-frontend/dist/govuk/core/_global-styles.scss +20 -0
  714. data/node_modules/govuk-frontend/dist/govuk/core/_global-styles.scss.map +1 -0
  715. data/node_modules/govuk-frontend/dist/govuk/core/_govuk-frontend-properties.scss +15 -0
  716. data/node_modules/govuk-frontend/dist/govuk/core/_govuk-frontend-properties.scss.map +1 -0
  717. data/node_modules/govuk-frontend/dist/govuk/core/_index.scss +8 -0
  718. data/node_modules/govuk-frontend/dist/govuk/core/_index.scss.map +1 -0
  719. data/node_modules/govuk-frontend/dist/govuk/core/_links.scss +42 -0
  720. data/node_modules/govuk-frontend/dist/govuk/core/_links.scss.map +1 -0
  721. data/node_modules/govuk-frontend/dist/govuk/core/_lists.scss +67 -0
  722. data/node_modules/govuk-frontend/dist/govuk/core/_lists.scss.map +1 -0
  723. data/node_modules/govuk-frontend/dist/govuk/core/_section-break.scss +51 -0
  724. data/node_modules/govuk-frontend/dist/govuk/core/_section-break.scss.map +1 -0
  725. data/node_modules/govuk-frontend/dist/govuk/core/_typography.scss +189 -0
  726. data/node_modules/govuk-frontend/dist/govuk/core/_typography.scss.map +1 -0
  727. data/node_modules/govuk-frontend/dist/govuk/errors/index.mjs +57 -0
  728. data/node_modules/govuk-frontend/dist/govuk/errors/index.mjs.map +1 -0
  729. data/node_modules/govuk-frontend/dist/govuk/govuk-frontend.min.css +3 -0
  730. data/node_modules/govuk-frontend/dist/govuk/govuk-frontend.min.css.map +1 -0
  731. data/node_modules/govuk-frontend/dist/govuk/govuk-frontend.min.js +1 -0
  732. data/node_modules/govuk-frontend/dist/govuk/govuk-frontend.min.js.map +1 -0
  733. data/node_modules/govuk-frontend/dist/govuk/helpers/_all.scss +10 -0
  734. data/node_modules/govuk-frontend/dist/govuk/helpers/_all.scss.map +1 -0
  735. data/node_modules/govuk-frontend/dist/govuk/helpers/_clearfix.scss +17 -0
  736. data/node_modules/govuk-frontend/dist/govuk/helpers/_clearfix.scss.map +1 -0
  737. data/node_modules/govuk-frontend/dist/govuk/helpers/_colour.scss +167 -0
  738. data/node_modules/govuk-frontend/dist/govuk/helpers/_colour.scss.map +1 -0
  739. data/node_modules/govuk-frontend/dist/govuk/helpers/_device-pixels.scss +38 -0
  740. data/node_modules/govuk-frontend/dist/govuk/helpers/_device-pixels.scss.map +1 -0
  741. data/node_modules/govuk-frontend/dist/govuk/helpers/_focused.scss +59 -0
  742. data/node_modules/govuk-frontend/dist/govuk/helpers/_focused.scss.map +1 -0
  743. data/node_modules/govuk-frontend/dist/govuk/helpers/_font-faces.scss +41 -0
  744. data/node_modules/govuk-frontend/dist/govuk/helpers/_font-faces.scss.map +1 -0
  745. data/node_modules/govuk-frontend/dist/govuk/helpers/_grid.scss +63 -0
  746. data/node_modules/govuk-frontend/dist/govuk/helpers/_grid.scss.map +1 -0
  747. data/node_modules/govuk-frontend/dist/govuk/helpers/_index.scss +14 -0
  748. data/node_modules/govuk-frontend/dist/govuk/helpers/_index.scss.map +1 -0
  749. data/node_modules/govuk-frontend/dist/govuk/helpers/_links.scss +391 -0
  750. data/node_modules/govuk-frontend/dist/govuk/helpers/_links.scss.map +1 -0
  751. data/node_modules/govuk-frontend/dist/govuk/helpers/_media-queries.scss +82 -0
  752. data/node_modules/govuk-frontend/dist/govuk/helpers/_media-queries.scss.map +1 -0
  753. data/node_modules/govuk-frontend/dist/govuk/helpers/_shape-arrow.scss +82 -0
  754. data/node_modules/govuk-frontend/dist/govuk/helpers/_shape-arrow.scss.map +1 -0
  755. data/node_modules/govuk-frontend/dist/govuk/helpers/_spacing.scss +173 -0
  756. data/node_modules/govuk-frontend/dist/govuk/helpers/_spacing.scss.map +1 -0
  757. data/node_modules/govuk-frontend/dist/govuk/helpers/_typography.scss +288 -0
  758. data/node_modules/govuk-frontend/dist/govuk/helpers/_typography.scss.map +1 -0
  759. data/node_modules/govuk-frontend/dist/govuk/helpers/_visually-hidden.scss +88 -0
  760. data/node_modules/govuk-frontend/dist/govuk/helpers/_visually-hidden.scss.map +1 -0
  761. data/node_modules/govuk-frontend/dist/govuk/i18n.mjs +195 -0
  762. data/node_modules/govuk-frontend/dist/govuk/i18n.mjs.map +1 -0
  763. data/node_modules/govuk-frontend/dist/govuk/index.scss +11 -0
  764. data/node_modules/govuk-frontend/dist/govuk/index.scss.map +1 -0
  765. data/node_modules/govuk-frontend/dist/govuk/init.mjs +166 -0
  766. data/node_modules/govuk-frontend/dist/govuk/init.mjs.map +1 -0
  767. data/node_modules/govuk-frontend/dist/govuk/macros/attributes.njk +94 -0
  768. data/node_modules/govuk-frontend/dist/govuk/macros/i18n.njk +21 -0
  769. data/node_modules/govuk-frontend/dist/govuk/macros/logo.njk +78 -0
  770. data/node_modules/govuk-frontend/dist/govuk/objects/_all.scss +10 -0
  771. data/node_modules/govuk-frontend/dist/govuk/objects/_all.scss.map +1 -0
  772. data/node_modules/govuk-frontend/dist/govuk/objects/_button-group.scss +80 -0
  773. data/node_modules/govuk-frontend/dist/govuk/objects/_button-group.scss.map +1 -0
  774. data/node_modules/govuk-frontend/dist/govuk/objects/_form-group.scss +25 -0
  775. data/node_modules/govuk-frontend/dist/govuk/objects/_form-group.scss.map +1 -0
  776. data/node_modules/govuk-frontend/dist/govuk/objects/_grid.scss +26 -0
  777. data/node_modules/govuk-frontend/dist/govuk/objects/_grid.scss.map +1 -0
  778. data/node_modules/govuk-frontend/dist/govuk/objects/_index.scss +8 -0
  779. data/node_modules/govuk-frontend/dist/govuk/objects/_index.scss.map +1 -0
  780. data/node_modules/govuk-frontend/dist/govuk/objects/_main-wrapper.scss +55 -0
  781. data/node_modules/govuk-frontend/dist/govuk/objects/_main-wrapper.scss.map +1 -0
  782. data/node_modules/govuk-frontend/dist/govuk/objects/_template.scss +57 -0
  783. data/node_modules/govuk-frontend/dist/govuk/objects/_template.scss.map +1 -0
  784. data/node_modules/govuk-frontend/dist/govuk/objects/_width-container.scss +77 -0
  785. data/node_modules/govuk-frontend/dist/govuk/objects/_width-container.scss.map +1 -0
  786. data/node_modules/govuk-frontend/dist/govuk/overrides/_all.scss +9 -0
  787. data/node_modules/govuk-frontend/dist/govuk/overrides/_all.scss.map +1 -0
  788. data/node_modules/govuk-frontend/dist/govuk/overrides/_display.scss +26 -0
  789. data/node_modules/govuk-frontend/dist/govuk/overrides/_display.scss.map +1 -0
  790. data/node_modules/govuk-frontend/dist/govuk/overrides/_index.scss +7 -0
  791. data/node_modules/govuk-frontend/dist/govuk/overrides/_index.scss.map +1 -0
  792. data/node_modules/govuk-frontend/dist/govuk/overrides/_spacing.scss +86 -0
  793. data/node_modules/govuk-frontend/dist/govuk/overrides/_spacing.scss.map +1 -0
  794. data/node_modules/govuk-frontend/dist/govuk/overrides/_text-align.scss +16 -0
  795. data/node_modules/govuk-frontend/dist/govuk/overrides/_text-align.scss.map +1 -0
  796. data/node_modules/govuk-frontend/dist/govuk/overrides/_typography.scss +42 -0
  797. data/node_modules/govuk-frontend/dist/govuk/overrides/_typography.scss.map +1 -0
  798. data/node_modules/govuk-frontend/dist/govuk/overrides/_width.scss +48 -0
  799. data/node_modules/govuk-frontend/dist/govuk/overrides/_width.scss.map +1 -0
  800. data/node_modules/govuk-frontend/dist/govuk/settings/_all.scss +10 -0
  801. data/node_modules/govuk-frontend/dist/govuk/settings/_all.scss.map +1 -0
  802. data/node_modules/govuk-frontend/dist/govuk/settings/_assets.scss +84 -0
  803. data/node_modules/govuk-frontend/dist/govuk/settings/_assets.scss.map +1 -0
  804. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-applied.scss +195 -0
  805. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-applied.scss.map +1 -0
  806. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-organisations.scss +382 -0
  807. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-organisations.scss.map +1 -0
  808. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-palette.scss +37 -0
  809. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-palette.scss.map +1 -0
  810. data/node_modules/govuk-frontend/dist/govuk/settings/_global-styles.scss +15 -0
  811. data/node_modules/govuk-frontend/dist/govuk/settings/_global-styles.scss.map +1 -0
  812. data/node_modules/govuk-frontend/dist/govuk/settings/_index.scss +36 -0
  813. data/node_modules/govuk-frontend/dist/govuk/settings/_index.scss.map +1 -0
  814. data/node_modules/govuk-frontend/dist/govuk/settings/_links.scss +49 -0
  815. data/node_modules/govuk-frontend/dist/govuk/settings/_links.scss.map +1 -0
  816. data/node_modules/govuk-frontend/dist/govuk/settings/_measurements.scss +107 -0
  817. data/node_modules/govuk-frontend/dist/govuk/settings/_measurements.scss.map +1 -0
  818. data/node_modules/govuk-frontend/dist/govuk/settings/_media-queries.scss +25 -0
  819. data/node_modules/govuk-frontend/dist/govuk/settings/_media-queries.scss.map +1 -0
  820. data/node_modules/govuk-frontend/dist/govuk/settings/_spacing.scss +78 -0
  821. data/node_modules/govuk-frontend/dist/govuk/settings/_spacing.scss.map +1 -0
  822. data/node_modules/govuk-frontend/dist/govuk/settings/_typography-font.scss +52 -0
  823. data/node_modules/govuk-frontend/dist/govuk/settings/_typography-font.scss.map +1 -0
  824. data/node_modules/govuk-frontend/dist/govuk/settings/_typography-responsive.scss +317 -0
  825. data/node_modules/govuk-frontend/dist/govuk/settings/_typography-responsive.scss.map +1 -0
  826. data/node_modules/govuk-frontend/dist/govuk/settings/_warnings.scss +78 -0
  827. data/node_modules/govuk-frontend/dist/govuk/settings/_warnings.scss.map +1 -0
  828. data/node_modules/govuk-frontend/dist/govuk/template.njk +69 -0
  829. data/node_modules/govuk-frontend/dist/govuk/tools/_all.scss +10 -0
  830. data/node_modules/govuk-frontend/dist/govuk/tools/_all.scss.map +1 -0
  831. data/node_modules/govuk-frontend/dist/govuk/tools/_exports.scss +35 -0
  832. data/node_modules/govuk-frontend/dist/govuk/tools/_exports.scss.map +1 -0
  833. data/node_modules/govuk-frontend/dist/govuk/tools/_font-url.scss +28 -0
  834. data/node_modules/govuk-frontend/dist/govuk/tools/_font-url.scss.map +1 -0
  835. data/node_modules/govuk-frontend/dist/govuk/tools/_image-url.scss +28 -0
  836. data/node_modules/govuk-frontend/dist/govuk/tools/_image-url.scss.map +1 -0
  837. data/node_modules/govuk-frontend/dist/govuk/tools/_index.scss +8 -0
  838. data/node_modules/govuk-frontend/dist/govuk/tools/_index.scss.map +1 -0
  839. data/node_modules/govuk-frontend/dist/govuk/tools/_px-to-em.scss +22 -0
  840. data/node_modules/govuk-frontend/dist/govuk/tools/_px-to-em.scss.map +1 -0
  841. data/node_modules/govuk-frontend/dist/govuk/tools/_px-to-rem.scss +22 -0
  842. data/node_modules/govuk-frontend/dist/govuk/tools/_px-to-rem.scss.map +1 -0
  843. data/node_modules/govuk-frontend/dist/govuk/tools/_rebrand.scss +65 -0
  844. data/node_modules/govuk-frontend/dist/govuk/tools/_rebrand.scss.map +1 -0
  845. data/node_modules/govuk-frontend/dist/govuk/utilities/_all.scss +10 -0
  846. data/node_modules/govuk-frontend/dist/govuk/utilities/_all.scss.map +1 -0
  847. data/node_modules/govuk-frontend/dist/govuk/utilities/_clearfix.scss +7 -0
  848. data/node_modules/govuk-frontend/dist/govuk/utilities/_clearfix.scss.map +1 -0
  849. data/node_modules/govuk-frontend/dist/govuk/utilities/_index.scss +4 -0
  850. data/node_modules/govuk-frontend/dist/govuk/utilities/_index.scss.map +1 -0
  851. data/node_modules/govuk-frontend/dist/govuk/utilities/_visually-hidden.scss +11 -0
  852. data/node_modules/govuk-frontend/dist/govuk/utilities/_visually-hidden.scss.map +1 -0
  853. data/node_modules/govuk-frontend/dist/govuk/vendor/_sass-mq.scss +349 -0
  854. data/node_modules/govuk-frontend/dist/govuk/vendor/_sass-mq.scss.map +1 -0
  855. data/node_modules/govuk-frontend/dist/govuk-prototype-kit/functions.js +25 -0
  856. data/node_modules/govuk-frontend/dist/govuk-prototype-kit/init.js +15 -0
  857. data/node_modules/govuk-frontend/dist/govuk-prototype-kit/init.scss +13 -0
  858. data/node_modules/govuk-frontend/dist/govuk-prototype-kit/init.scss.map +1 -0
  859. data/node_modules/govuk-frontend/govuk-prototype-kit.config.json +179 -0
  860. data/node_modules/govuk-frontend/package.json +92 -0
  861. metadata +852 -17
  862. data/.github/dependabot.yml +0 -10
  863. data/.github/pull_request_template.md +0 -1
  864. data/.github/workflows/actionlint.yml +0 -12
  865. data/.github/workflows/autorelease.yml +0 -12
  866. data/.github/workflows/ci.yml +0 -55
  867. data/.gitignore +0 -19
  868. data/.rspec +0 -3
  869. data/.rubocop.yml +0 -3
  870. data/.ruby-version +0 -1
  871. data/CHANGELOG.md +0 -163
  872. data/Gemfile +0 -7
  873. data/LICENSE.txt +0 -19
  874. data/Rakefile +0 -10
  875. data/bin/console +0 -15
  876. data/bin/setup +0 -8
  877. data/content_block_tools.gemspec +0 -35
@@ -0,0 +1,433 @@
1
+ (function (global, factory) {
2
+ typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) :
3
+ typeof define === 'function' && define.amd ? define(['exports'], factory) :
4
+ (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global.GOVUKFrontend = global.GOVUKFrontend || {}));
5
+ })(this, (function (exports) { 'use strict';
6
+
7
+ function getFragmentFromUrl(url) {
8
+ if (!url.includes('#')) {
9
+ return undefined;
10
+ }
11
+ return url.split('#').pop();
12
+ }
13
+ function getBreakpoint(name) {
14
+ const property = `--govuk-breakpoint-${name}`;
15
+ const value = window.getComputedStyle(document.documentElement).getPropertyValue(property);
16
+ return {
17
+ property,
18
+ value: value || undefined
19
+ };
20
+ }
21
+ function isInitialised($root, moduleName) {
22
+ return $root instanceof HTMLElement && $root.hasAttribute(`data-${moduleName}-init`);
23
+ }
24
+
25
+ /**
26
+ * Checks if GOV.UK Frontend is supported on this page
27
+ *
28
+ * Some browsers will load and run our JavaScript but GOV.UK Frontend
29
+ * won't be supported.
30
+ *
31
+ * @param {HTMLElement | null} [$scope] - (internal) `<body>` HTML element checked for browser support
32
+ * @returns {boolean} Whether GOV.UK Frontend is supported on this page
33
+ */
34
+ function isSupported($scope = document.body) {
35
+ if (!$scope) {
36
+ return false;
37
+ }
38
+ return $scope.classList.contains('govuk-frontend-supported');
39
+ }
40
+ function formatErrorMessage(Component, message) {
41
+ return `${Component.moduleName}: ${message}`;
42
+ }
43
+ /**
44
+ * @typedef ComponentWithModuleName
45
+ * @property {string} moduleName - Name of the component
46
+ */
47
+ /**
48
+ * @import { ObjectNested } from './configuration.mjs'
49
+ */
50
+
51
+ class GOVUKFrontendError extends Error {
52
+ constructor(...args) {
53
+ super(...args);
54
+ this.name = 'GOVUKFrontendError';
55
+ }
56
+ }
57
+ class SupportError extends GOVUKFrontendError {
58
+ /**
59
+ * Checks if GOV.UK Frontend is supported on this page
60
+ *
61
+ * @param {HTMLElement | null} [$scope] - HTML element `<body>` checked for browser support
62
+ */
63
+ constructor($scope = document.body) {
64
+ const supportMessage = 'noModule' in HTMLScriptElement.prototype ? 'GOV.UK Frontend initialised without `<body class="govuk-frontend-supported">` from template `<script>` snippet' : 'GOV.UK Frontend is not supported in this browser';
65
+ super($scope ? supportMessage : 'GOV.UK Frontend initialised without `<script type="module">`');
66
+ this.name = 'SupportError';
67
+ }
68
+ }
69
+ class ElementError extends GOVUKFrontendError {
70
+ constructor(messageOrOptions) {
71
+ let message = typeof messageOrOptions === 'string' ? messageOrOptions : '';
72
+ if (typeof messageOrOptions === 'object') {
73
+ const {
74
+ component,
75
+ identifier,
76
+ element,
77
+ expectedType
78
+ } = messageOrOptions;
79
+ message = identifier;
80
+ message += element ? ` is not of type ${expectedType != null ? expectedType : 'HTMLElement'}` : ' not found';
81
+ message = formatErrorMessage(component, message);
82
+ }
83
+ super(message);
84
+ this.name = 'ElementError';
85
+ }
86
+ }
87
+ class InitError extends GOVUKFrontendError {
88
+ constructor(componentOrMessage) {
89
+ const message = typeof componentOrMessage === 'string' ? componentOrMessage : formatErrorMessage(componentOrMessage, `Root element (\`$root\`) already initialised`);
90
+ super(message);
91
+ this.name = 'InitError';
92
+ }
93
+ }
94
+ /**
95
+ * @import { ComponentWithModuleName } from '../common/index.mjs'
96
+ */
97
+
98
+ class Component {
99
+ /**
100
+ * Returns the root element of the component
101
+ *
102
+ * @protected
103
+ * @returns {RootElementType} - the root element of component
104
+ */
105
+ get $root() {
106
+ return this._$root;
107
+ }
108
+ constructor($root) {
109
+ this._$root = void 0;
110
+ const childConstructor = this.constructor;
111
+ if (typeof childConstructor.moduleName !== 'string') {
112
+ throw new InitError(`\`moduleName\` not defined in component`);
113
+ }
114
+ if (!($root instanceof childConstructor.elementType)) {
115
+ throw new ElementError({
116
+ element: $root,
117
+ component: childConstructor,
118
+ identifier: 'Root element (`$root`)',
119
+ expectedType: childConstructor.elementType.name
120
+ });
121
+ } else {
122
+ this._$root = $root;
123
+ }
124
+ childConstructor.checkSupport();
125
+ this.checkInitialised();
126
+ const moduleName = childConstructor.moduleName;
127
+ this.$root.setAttribute(`data-${moduleName}-init`, '');
128
+ }
129
+ checkInitialised() {
130
+ const constructor = this.constructor;
131
+ const moduleName = constructor.moduleName;
132
+ if (moduleName && isInitialised(this.$root, moduleName)) {
133
+ throw new InitError(constructor);
134
+ }
135
+ }
136
+ static checkSupport() {
137
+ if (!isSupported()) {
138
+ throw new SupportError();
139
+ }
140
+ }
141
+ }
142
+
143
+ /**
144
+ * @typedef ChildClass
145
+ * @property {string} moduleName - The module name that'll be looked for in the DOM when initialising the component
146
+ */
147
+
148
+ /**
149
+ * @typedef {typeof Component & ChildClass} ChildClassConstructor
150
+ */
151
+ Component.elementType = HTMLElement;
152
+
153
+ /**
154
+ * Tabs component
155
+ *
156
+ * @preserve
157
+ */
158
+ class Tabs extends Component {
159
+ /**
160
+ * @param {Element | null} $root - HTML element to use for tabs
161
+ */
162
+ constructor($root) {
163
+ super($root);
164
+ this.$tabs = void 0;
165
+ this.$tabList = void 0;
166
+ this.$tabListItems = void 0;
167
+ this.jsHiddenClass = 'govuk-tabs__panel--hidden';
168
+ this.changingHash = false;
169
+ this.boundTabClick = void 0;
170
+ this.boundTabKeydown = void 0;
171
+ this.boundOnHashChange = void 0;
172
+ this.mql = null;
173
+ const $tabs = this.$root.querySelectorAll('a.govuk-tabs__tab');
174
+ if (!$tabs.length) {
175
+ throw new ElementError({
176
+ component: Tabs,
177
+ identifier: 'Links (`<a class="govuk-tabs__tab">`)'
178
+ });
179
+ }
180
+ this.$tabs = $tabs;
181
+ this.boundTabClick = this.onTabClick.bind(this);
182
+ this.boundTabKeydown = this.onTabKeydown.bind(this);
183
+ this.boundOnHashChange = this.onHashChange.bind(this);
184
+ const $tabList = this.$root.querySelector('.govuk-tabs__list');
185
+ const $tabListItems = this.$root.querySelectorAll('li.govuk-tabs__list-item');
186
+ if (!$tabList) {
187
+ throw new ElementError({
188
+ component: Tabs,
189
+ identifier: 'List (`<ul class="govuk-tabs__list">`)'
190
+ });
191
+ }
192
+ if (!$tabListItems.length) {
193
+ throw new ElementError({
194
+ component: Tabs,
195
+ identifier: 'List items (`<li class="govuk-tabs__list-item">`)'
196
+ });
197
+ }
198
+ this.$tabList = $tabList;
199
+ this.$tabListItems = $tabListItems;
200
+ this.setupResponsiveChecks();
201
+ }
202
+ setupResponsiveChecks() {
203
+ const breakpoint = getBreakpoint('tablet');
204
+ if (!breakpoint.value) {
205
+ throw new ElementError({
206
+ component: Tabs,
207
+ identifier: `CSS custom property (\`${breakpoint.property}\`) on pseudo-class \`:root\``
208
+ });
209
+ }
210
+ this.mql = window.matchMedia(`(min-width: ${breakpoint.value})`);
211
+ if ('addEventListener' in this.mql) {
212
+ this.mql.addEventListener('change', () => this.checkMode());
213
+ } else {
214
+ this.mql.addListener(() => this.checkMode());
215
+ }
216
+ this.checkMode();
217
+ }
218
+ checkMode() {
219
+ var _this$mql;
220
+ if ((_this$mql = this.mql) != null && _this$mql.matches) {
221
+ this.setup();
222
+ } else {
223
+ this.teardown();
224
+ }
225
+ }
226
+ setup() {
227
+ var _this$getTab;
228
+ this.$tabList.setAttribute('role', 'tablist');
229
+ this.$tabListItems.forEach($item => {
230
+ $item.setAttribute('role', 'presentation');
231
+ });
232
+ this.$tabs.forEach($tab => {
233
+ this.setAttributes($tab);
234
+ $tab.addEventListener('click', this.boundTabClick, true);
235
+ $tab.addEventListener('keydown', this.boundTabKeydown, true);
236
+ this.hideTab($tab);
237
+ });
238
+ const $activeTab = (_this$getTab = this.getTab(window.location.hash)) != null ? _this$getTab : this.$tabs[0];
239
+ this.showTab($activeTab);
240
+ window.addEventListener('hashchange', this.boundOnHashChange, true);
241
+ }
242
+ teardown() {
243
+ this.$tabList.removeAttribute('role');
244
+ this.$tabListItems.forEach($item => {
245
+ $item.removeAttribute('role');
246
+ });
247
+ this.$tabs.forEach($tab => {
248
+ $tab.removeEventListener('click', this.boundTabClick, true);
249
+ $tab.removeEventListener('keydown', this.boundTabKeydown, true);
250
+ this.unsetAttributes($tab);
251
+ });
252
+ window.removeEventListener('hashchange', this.boundOnHashChange, true);
253
+ }
254
+ onHashChange() {
255
+ const hash = window.location.hash;
256
+ const $tabWithHash = this.getTab(hash);
257
+ if (!$tabWithHash) {
258
+ return;
259
+ }
260
+ if (this.changingHash) {
261
+ this.changingHash = false;
262
+ return;
263
+ }
264
+ const $previousTab = this.getCurrentTab();
265
+ if (!$previousTab) {
266
+ return;
267
+ }
268
+ this.hideTab($previousTab);
269
+ this.showTab($tabWithHash);
270
+ $tabWithHash.focus();
271
+ }
272
+ hideTab($tab) {
273
+ this.unhighlightTab($tab);
274
+ this.hidePanel($tab);
275
+ }
276
+ showTab($tab) {
277
+ this.highlightTab($tab);
278
+ this.showPanel($tab);
279
+ }
280
+ getTab(hash) {
281
+ return this.$root.querySelector(`a.govuk-tabs__tab[href="${hash}"]`);
282
+ }
283
+ setAttributes($tab) {
284
+ const panelId = getFragmentFromUrl($tab.href);
285
+ if (!panelId) {
286
+ return;
287
+ }
288
+ $tab.setAttribute('id', `tab_${panelId}`);
289
+ $tab.setAttribute('role', 'tab');
290
+ $tab.setAttribute('aria-controls', panelId);
291
+ $tab.setAttribute('aria-selected', 'false');
292
+ $tab.setAttribute('tabindex', '-1');
293
+ const $panel = this.getPanel($tab);
294
+ if (!$panel) {
295
+ return;
296
+ }
297
+ $panel.setAttribute('role', 'tabpanel');
298
+ $panel.setAttribute('aria-labelledby', $tab.id);
299
+ $panel.classList.add(this.jsHiddenClass);
300
+ }
301
+ unsetAttributes($tab) {
302
+ $tab.removeAttribute('id');
303
+ $tab.removeAttribute('role');
304
+ $tab.removeAttribute('aria-controls');
305
+ $tab.removeAttribute('aria-selected');
306
+ $tab.removeAttribute('tabindex');
307
+ const $panel = this.getPanel($tab);
308
+ if (!$panel) {
309
+ return;
310
+ }
311
+ $panel.removeAttribute('role');
312
+ $panel.removeAttribute('aria-labelledby');
313
+ $panel.classList.remove(this.jsHiddenClass);
314
+ }
315
+ onTabClick(event) {
316
+ const $currentTab = this.getCurrentTab();
317
+ const $nextTab = event.currentTarget;
318
+ if (!$currentTab || !($nextTab instanceof HTMLAnchorElement)) {
319
+ return;
320
+ }
321
+ event.preventDefault();
322
+ this.hideTab($currentTab);
323
+ this.showTab($nextTab);
324
+ this.createHistoryEntry($nextTab);
325
+ }
326
+ createHistoryEntry($tab) {
327
+ const $panel = this.getPanel($tab);
328
+ if (!$panel) {
329
+ return;
330
+ }
331
+ const panelId = $panel.id;
332
+ $panel.id = '';
333
+ this.changingHash = true;
334
+ window.location.hash = panelId;
335
+ $panel.id = panelId;
336
+ }
337
+ onTabKeydown(event) {
338
+ switch (event.key) {
339
+ case 'ArrowLeft':
340
+ case 'Left':
341
+ this.activatePreviousTab();
342
+ event.preventDefault();
343
+ break;
344
+ case 'ArrowRight':
345
+ case 'Right':
346
+ this.activateNextTab();
347
+ event.preventDefault();
348
+ break;
349
+ }
350
+ }
351
+ activateNextTab() {
352
+ const $currentTab = this.getCurrentTab();
353
+ if (!($currentTab != null && $currentTab.parentElement)) {
354
+ return;
355
+ }
356
+ const $nextTabListItem = $currentTab.parentElement.nextElementSibling;
357
+ if (!$nextTabListItem) {
358
+ return;
359
+ }
360
+ const $nextTab = $nextTabListItem.querySelector('a.govuk-tabs__tab');
361
+ if (!$nextTab) {
362
+ return;
363
+ }
364
+ this.hideTab($currentTab);
365
+ this.showTab($nextTab);
366
+ $nextTab.focus();
367
+ this.createHistoryEntry($nextTab);
368
+ }
369
+ activatePreviousTab() {
370
+ const $currentTab = this.getCurrentTab();
371
+ if (!($currentTab != null && $currentTab.parentElement)) {
372
+ return;
373
+ }
374
+ const $previousTabListItem = $currentTab.parentElement.previousElementSibling;
375
+ if (!$previousTabListItem) {
376
+ return;
377
+ }
378
+ const $previousTab = $previousTabListItem.querySelector('a.govuk-tabs__tab');
379
+ if (!$previousTab) {
380
+ return;
381
+ }
382
+ this.hideTab($currentTab);
383
+ this.showTab($previousTab);
384
+ $previousTab.focus();
385
+ this.createHistoryEntry($previousTab);
386
+ }
387
+ getPanel($tab) {
388
+ const panelId = getFragmentFromUrl($tab.href);
389
+ if (!panelId) {
390
+ return null;
391
+ }
392
+ return this.$root.querySelector(`#${panelId}`);
393
+ }
394
+ showPanel($tab) {
395
+ const $panel = this.getPanel($tab);
396
+ if (!$panel) {
397
+ return;
398
+ }
399
+ $panel.classList.remove(this.jsHiddenClass);
400
+ }
401
+ hidePanel($tab) {
402
+ const $panel = this.getPanel($tab);
403
+ if (!$panel) {
404
+ return;
405
+ }
406
+ $panel.classList.add(this.jsHiddenClass);
407
+ }
408
+ unhighlightTab($tab) {
409
+ if (!$tab.parentElement) {
410
+ return;
411
+ }
412
+ $tab.setAttribute('aria-selected', 'false');
413
+ $tab.parentElement.classList.remove('govuk-tabs__list-item--selected');
414
+ $tab.setAttribute('tabindex', '-1');
415
+ }
416
+ highlightTab($tab) {
417
+ if (!$tab.parentElement) {
418
+ return;
419
+ }
420
+ $tab.setAttribute('aria-selected', 'true');
421
+ $tab.parentElement.classList.add('govuk-tabs__list-item--selected');
422
+ $tab.setAttribute('tabindex', '0');
423
+ }
424
+ getCurrentTab() {
425
+ return this.$root.querySelector('.govuk-tabs__list-item--selected a.govuk-tabs__tab');
426
+ }
427
+ }
428
+ Tabs.moduleName = 'govuk-tabs';
429
+
430
+ exports.Tabs = Tabs;
431
+
432
+ }));
433
+ //# sourceMappingURL=tabs.bundle.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tabs.bundle.js","sources":["../../../../src/govuk/common/index.mjs","../../../../src/govuk/errors/index.mjs","../../../../src/govuk/component.mjs","../../../../src/govuk/components/tabs/tabs.mjs"],"sourcesContent":["/**\n * Common helpers which do not require polyfill.\n *\n * IMPORTANT: If a helper require a polyfill, please isolate it in its own module\n * so that the polyfill can be properly tree-shaken and does not burden\n * the components that do not need that helper\n */\n\n/**\n * Get hash fragment from URL\n *\n * Extract the hash fragment (everything after the hash) from a URL,\n * but not including the hash symbol\n *\n * @private\n * @param {string} url - URL\n * @returns {string | undefined} Fragment from URL, without the hash\n */\nexport function getFragmentFromUrl(url) {\n if (!url.includes('#')) {\n return undefined\n }\n\n return url.split('#').pop()\n}\n\n/**\n * Get GOV.UK Frontend breakpoint value from CSS custom property\n *\n * @private\n * @param {string} name - Breakpoint name\n * @returns {{ property: string, value?: string }} Breakpoint object\n */\nexport function getBreakpoint(name) {\n const property = `--govuk-breakpoint-${name}`\n\n // Get value from `<html>` with breakpoints on CSS :root\n const value = window\n .getComputedStyle(document.documentElement)\n .getPropertyValue(property)\n\n return {\n property,\n value: value || undefined\n }\n}\n\n/**\n * Move focus to element\n *\n * Sets tabindex to -1 to make the element programmatically focusable,\n * but removes it on blur as the element doesn't need to be focused again.\n *\n * @private\n * @template {HTMLElement} FocusElement\n * @param {FocusElement} $element - HTML element\n * @param {object} [options] - Handler options\n * @param {function(this: FocusElement): void} [options.onBeforeFocus] - Callback before focus\n * @param {function(this: FocusElement): void} [options.onBlur] - Callback on blur\n */\nexport function setFocus($element, options = {}) {\n const isFocusable = $element.getAttribute('tabindex')\n\n if (!isFocusable) {\n $element.setAttribute('tabindex', '-1')\n }\n\n /**\n * Handle element focus\n */\n function onFocus() {\n $element.addEventListener('blur', onBlur, { once: true })\n }\n\n /**\n * Handle element blur\n */\n function onBlur() {\n options.onBlur?.call($element)\n\n if (!isFocusable) {\n $element.removeAttribute('tabindex')\n }\n }\n\n // Add listener to reset element on blur, after focus\n $element.addEventListener('focus', onFocus, { once: true })\n\n // Focus element\n options.onBeforeFocus?.call($element)\n $element.focus()\n}\n\n/**\n * Checks if component is already initialised\n *\n * @internal\n * @param {Element} $root - HTML element to be checked\n * @param {string} moduleName - name of component module\n * @returns {boolean} Whether component is already initialised\n */\nexport function isInitialised($root, moduleName) {\n return (\n $root instanceof HTMLElement &&\n $root.hasAttribute(`data-${moduleName}-init`)\n )\n}\n\n/**\n * Checks if GOV.UK Frontend is supported on this page\n *\n * Some browsers will load and run our JavaScript but GOV.UK Frontend\n * won't be supported.\n *\n * @param {HTMLElement | null} [$scope] - (internal) `<body>` HTML element checked for browser support\n * @returns {boolean} Whether GOV.UK Frontend is supported on this page\n */\nexport function isSupported($scope = document.body) {\n if (!$scope) {\n return false\n }\n\n return $scope.classList.contains('govuk-frontend-supported')\n}\n\n/**\n * Check for an array\n *\n * @internal\n * @param {unknown} option - Option to check\n * @returns {boolean} Whether the option is an array\n */\nfunction isArray(option) {\n return Array.isArray(option)\n}\n\n/**\n * Check for an object\n *\n * @internal\n * @template {Partial<Record<keyof ObjectType, unknown>>} [ObjectType=ObjectNested]\n * @param {unknown | ObjectType} option - Option to check\n * @returns {option is ObjectType} Whether the option is an object\n */\nexport function isObject(option) {\n return !!option && typeof option === 'object' && !isArray(option)\n}\n\n/**\n * Format error message\n *\n * @internal\n * @param {ComponentWithModuleName} Component - Component that threw the error\n * @param {string} message - Error message\n * @returns {string} - Formatted error message\n */\nexport function formatErrorMessage(Component, message) {\n return `${Component.moduleName}: ${message}`\n}\n\n/* eslint-disable jsdoc/valid-types --\n * `{new(...args: any[] ): object}` is not recognised as valid\n * https://github.com/gajus/eslint-plugin-jsdoc/issues/145#issuecomment-1308722878\n * https://github.com/jsdoc-type-pratt-parser/jsdoc-type-pratt-parser/issues/131\n **/\n\n/**\n * @typedef ComponentWithModuleName\n * @property {string} moduleName - Name of the component\n */\n\n/* eslint-enable jsdoc/valid-types */\n\n/**\n * @import { ObjectNested } from './configuration.mjs'\n */\n","import { formatErrorMessage } from '../common/index.mjs'\n\n/**\n * GOV.UK Frontend error\n *\n * A base class for `Error`s thrown by GOV.UK Frontend.\n *\n * It is meant to be extended into specific types of errors\n * to be thrown by our code.\n *\n * @example\n * ```js\n * class MissingRootError extends GOVUKFrontendError {\n * // Setting an explicit name is important as extending the class will not\n * // set a new `name` on the subclass. The `name` property is important\n * // to ensure intelligible error names even if the class name gets\n * // mangled by a minifier\n * name = \"MissingRootError\"\n * }\n * ```\n * @virtual\n */\nexport class GOVUKFrontendError extends Error {\n name = 'GOVUKFrontendError'\n}\n\n/**\n * Indicates that GOV.UK Frontend is not supported\n */\nexport class SupportError extends GOVUKFrontendError {\n name = 'SupportError'\n\n /**\n * Checks if GOV.UK Frontend is supported on this page\n *\n * @param {HTMLElement | null} [$scope] - HTML element `<body>` checked for browser support\n */\n constructor($scope = document.body) {\n const supportMessage =\n 'noModule' in HTMLScriptElement.prototype\n ? 'GOV.UK Frontend initialised without `<body class=\"govuk-frontend-supported\">` from template `<script>` snippet'\n : 'GOV.UK Frontend is not supported in this browser'\n\n super(\n $scope\n ? supportMessage\n : 'GOV.UK Frontend initialised without `<script type=\"module\">`'\n )\n }\n}\n\n/**\n * Indicates that a component has received an illegal configuration\n */\nexport class ConfigError extends GOVUKFrontendError {\n name = 'ConfigError'\n}\n\n/**\n * Indicates an issue with an element (possibly `null` or `undefined`)\n */\nexport class ElementError extends GOVUKFrontendError {\n name = 'ElementError'\n\n /**\n * @internal\n * @overload\n * @param {string} message - Element error message\n */\n\n /**\n * @internal\n * @overload\n * @param {ElementErrorOptions} options - Element error options\n */\n\n /**\n * @internal\n * @param {string | ElementErrorOptions} messageOrOptions - Element error message or options\n */\n constructor(messageOrOptions) {\n let message = typeof messageOrOptions === 'string' ? messageOrOptions : ''\n\n // Build message from options\n if (typeof messageOrOptions === 'object') {\n const { component, identifier, element, expectedType } = messageOrOptions\n\n message = identifier\n\n // Append reason\n message += element\n ? ` is not of type ${expectedType ?? 'HTMLElement'}`\n : ' not found'\n\n message = formatErrorMessage(component, message)\n }\n\n super(message)\n }\n}\n\n/**\n * Indicates that a component is already initialised\n */\nexport class InitError extends GOVUKFrontendError {\n name = 'InitError'\n\n /**\n * @internal\n * @param {ComponentWithModuleName | string} componentOrMessage - name of the component module\n */\n constructor(componentOrMessage) {\n const message =\n typeof componentOrMessage === 'string'\n ? componentOrMessage\n : formatErrorMessage(\n componentOrMessage,\n `Root element (\\`$root\\`) already initialised`\n )\n\n super(message)\n }\n}\n\n/**\n * Element error options\n *\n * @internal\n * @typedef {object} ElementErrorOptions\n * @property {string} identifier - An identifier that'll let the user understand which element has an error. This is whatever makes the most sense\n * @property {Element | null} [element] - The element in error\n * @property {string} [expectedType] - The type that was expected for the identifier\n * @property {ComponentWithModuleName} component - Component throwing the error\n */\n\n/**\n * @import { ComponentWithModuleName } from '../common/index.mjs'\n */\n","import { isInitialised, isSupported } from './common/index.mjs'\nimport { ElementError, InitError, SupportError } from './errors/index.mjs'\n\n/**\n * Base Component class\n *\n * Centralises the behaviours shared by our components\n *\n * @virtual\n * @template {Element} [RootElementType=HTMLElement]\n */\nexport class Component {\n /**\n * @type {typeof Element}\n */\n static elementType = HTMLElement\n\n // allows Typescript user to work around the lack of types\n // in GOVUKFrontend package, Typescript is not aware of $root\n // in components that extend GOVUKFrontendComponent\n /**\n * Returns the root element of the component\n *\n * @protected\n * @returns {RootElementType} - the root element of component\n */\n get $root() {\n return this._$root\n }\n\n /**\n * @protected\n * @type {RootElementType}\n */\n _$root\n\n /**\n * Constructs a new component, validating that GOV.UK Frontend is supported\n *\n * @internal\n * @param {Element | null} [$root] - HTML element to use for component\n */\n constructor($root) {\n const childConstructor = /** @type {ChildClassConstructor} */ (\n this.constructor\n )\n\n // TypeScript does not enforce that inheriting classes will define a `moduleName`\n // (even if we add a `@virtual` `static moduleName` property to this class).\n // While we trust users to do this correctly, we do a little check to provide them\n // a helpful error message.\n //\n // After this, we'll be sure that `childConstructor` has a `moduleName`\n // as expected of the `ChildClassConstructor` we've cast `this.constructor` to.\n if (typeof childConstructor.moduleName !== 'string') {\n throw new InitError(`\\`moduleName\\` not defined in component`)\n }\n\n if (!($root instanceof childConstructor.elementType)) {\n throw new ElementError({\n element: $root,\n component: childConstructor,\n identifier: 'Root element (`$root`)',\n expectedType: childConstructor.elementType.name\n })\n } else {\n this._$root = /** @type {RootElementType} */ ($root)\n }\n\n childConstructor.checkSupport()\n\n this.checkInitialised()\n\n const moduleName = childConstructor.moduleName\n\n this.$root.setAttribute(`data-${moduleName}-init`, '')\n }\n\n /**\n * Validates whether component is already initialised\n *\n * @private\n * @throws {InitError} when component is already initialised\n */\n checkInitialised() {\n const constructor = /** @type {ChildClassConstructor} */ (this.constructor)\n const moduleName = constructor.moduleName\n\n if (moduleName && isInitialised(this.$root, moduleName)) {\n throw new InitError(constructor)\n }\n }\n\n /**\n * Validates whether components are supported\n *\n * @throws {SupportError} when the components are not supported\n */\n static checkSupport() {\n if (!isSupported()) {\n throw new SupportError()\n }\n }\n}\n\n/**\n * @typedef ChildClass\n * @property {string} moduleName - The module name that'll be looked for in the DOM when initialising the component\n */\n\n/**\n * @typedef {typeof Component & ChildClass} ChildClassConstructor\n */\n","import { getBreakpoint, getFragmentFromUrl } from '../../common/index.mjs'\nimport { Component } from '../../component.mjs'\nimport { ElementError } from '../../errors/index.mjs'\n\n/**\n * Tabs component\n *\n * @preserve\n */\nexport class Tabs extends Component {\n /** @private */\n $tabs\n\n /** @private */\n $tabList\n\n /** @private */\n $tabListItems\n\n /** @private */\n jsHiddenClass = 'govuk-tabs__panel--hidden'\n\n /** @private */\n changingHash = false\n\n /** @private */\n boundTabClick\n\n /** @private */\n boundTabKeydown\n\n /** @private */\n boundOnHashChange\n\n /**\n * @private\n * @type {MediaQueryList | null}\n */\n mql = null\n\n /**\n * @param {Element | null} $root - HTML element to use for tabs\n */\n constructor($root) {\n super($root)\n\n const $tabs = this.$root.querySelectorAll('a.govuk-tabs__tab')\n if (!$tabs.length) {\n throw new ElementError({\n component: Tabs,\n identifier: 'Links (`<a class=\"govuk-tabs__tab\">`)'\n })\n }\n\n this.$tabs = $tabs\n\n // Save bound functions so we can remove event listeners during teardown\n this.boundTabClick = this.onTabClick.bind(this)\n this.boundTabKeydown = this.onTabKeydown.bind(this)\n this.boundOnHashChange = this.onHashChange.bind(this)\n\n const $tabList = this.$root.querySelector('.govuk-tabs__list')\n const $tabListItems = this.$root.querySelectorAll(\n 'li.govuk-tabs__list-item'\n )\n\n if (!$tabList) {\n throw new ElementError({\n component: Tabs,\n identifier: 'List (`<ul class=\"govuk-tabs__list\">`)'\n })\n }\n\n if (!$tabListItems.length) {\n throw new ElementError({\n component: Tabs,\n identifier: 'List items (`<li class=\"govuk-tabs__list-item\">`)'\n })\n }\n\n this.$tabList = $tabList\n this.$tabListItems = $tabListItems\n\n this.setupResponsiveChecks()\n }\n\n /**\n * Setup viewport resize check\n *\n * @private\n */\n setupResponsiveChecks() {\n const breakpoint = getBreakpoint('tablet')\n\n if (!breakpoint.value) {\n throw new ElementError({\n component: Tabs,\n identifier: `CSS custom property (\\`${breakpoint.property}\\`) on pseudo-class \\`:root\\``\n })\n }\n\n // Media query list for GOV.UK Frontend tablet breakpoint\n this.mql = window.matchMedia(`(min-width: ${breakpoint.value})`)\n\n // MediaQueryList.addEventListener isn't supported by Safari < 14 so we need\n // to be able to fall back to the deprecated MediaQueryList.addListener\n if ('addEventListener' in this.mql) {\n this.mql.addEventListener('change', () => this.checkMode())\n } else {\n // @ts-expect-error Property 'addListener' does not exist\n // eslint-disable-next-line @typescript-eslint/no-unsafe-call\n this.mql.addListener(() => this.checkMode())\n }\n\n this.checkMode()\n }\n\n /**\n * Setup or teardown handler for viewport resize check\n *\n * @private\n */\n checkMode() {\n if (this.mql?.matches) {\n this.setup()\n } else {\n this.teardown()\n }\n }\n\n /**\n * Setup tab component\n *\n * @private\n */\n setup() {\n this.$tabList.setAttribute('role', 'tablist')\n\n this.$tabListItems.forEach(($item) => {\n $item.setAttribute('role', 'presentation')\n })\n\n this.$tabs.forEach(($tab) => {\n // Set HTML attributes\n this.setAttributes($tab)\n\n // Handle events\n $tab.addEventListener('click', this.boundTabClick, true)\n $tab.addEventListener('keydown', this.boundTabKeydown, true)\n\n // Remove old active panels\n this.hideTab($tab)\n })\n\n // Show either the active tab according to the URL's hash or the first tab\n const $activeTab = this.getTab(window.location.hash) ?? this.$tabs[0]\n\n this.showTab($activeTab)\n\n // Handle hashchange events\n window.addEventListener('hashchange', this.boundOnHashChange, true)\n }\n\n /**\n * Teardown tab component\n *\n * @private\n */\n teardown() {\n this.$tabList.removeAttribute('role')\n\n this.$tabListItems.forEach(($item) => {\n $item.removeAttribute('role')\n })\n\n this.$tabs.forEach(($tab) => {\n // Remove events\n $tab.removeEventListener('click', this.boundTabClick, true)\n $tab.removeEventListener('keydown', this.boundTabKeydown, true)\n\n // Unset HTML attributes\n this.unsetAttributes($tab)\n })\n\n // Remove hashchange event handler\n window.removeEventListener('hashchange', this.boundOnHashChange, true)\n }\n\n /**\n * Handle hashchange event\n *\n * @private\n * @returns {void | undefined} Returns void, or undefined when prevented\n */\n onHashChange() {\n const hash = window.location.hash\n const $tabWithHash = this.getTab(hash)\n if (!$tabWithHash) {\n return\n }\n\n // Prevent changing the hash\n if (this.changingHash) {\n this.changingHash = false\n return\n }\n\n // Show either the active tab according to the URL's hash or the first tab\n const $previousTab = this.getCurrentTab()\n if (!$previousTab) {\n return\n }\n\n this.hideTab($previousTab)\n this.showTab($tabWithHash)\n $tabWithHash.focus()\n }\n\n /**\n * Hide panel for tab link\n *\n * @private\n * @param {HTMLAnchorElement} $tab - Tab link\n */\n hideTab($tab) {\n this.unhighlightTab($tab)\n this.hidePanel($tab)\n }\n\n /**\n * Show panel for tab link\n *\n * @private\n * @param {HTMLAnchorElement} $tab - Tab link\n */\n showTab($tab) {\n this.highlightTab($tab)\n this.showPanel($tab)\n }\n\n /**\n * Get tab link by hash\n *\n * @private\n * @param {string} hash - Hash fragment including #\n * @returns {HTMLAnchorElement | null} Tab link\n */\n getTab(hash) {\n return this.$root.querySelector(`a.govuk-tabs__tab[href=\"${hash}\"]`)\n }\n\n /**\n * Set tab link and panel attributes\n *\n * @private\n * @param {HTMLAnchorElement} $tab - Tab link\n */\n setAttributes($tab) {\n const panelId = getFragmentFromUrl($tab.href)\n if (!panelId) {\n return\n }\n\n // Set tab attributes\n $tab.setAttribute('id', `tab_${panelId}`)\n $tab.setAttribute('role', 'tab')\n $tab.setAttribute('aria-controls', panelId)\n $tab.setAttribute('aria-selected', 'false')\n $tab.setAttribute('tabindex', '-1')\n\n // Set panel attributes\n const $panel = this.getPanel($tab)\n if (!$panel) {\n return\n }\n\n $panel.setAttribute('role', 'tabpanel')\n $panel.setAttribute('aria-labelledby', $tab.id)\n $panel.classList.add(this.jsHiddenClass)\n }\n\n /**\n * Unset tab link and panel attributes\n *\n * @private\n * @param {HTMLAnchorElement} $tab - Tab link\n */\n unsetAttributes($tab) {\n // unset tab attributes\n $tab.removeAttribute('id')\n $tab.removeAttribute('role')\n $tab.removeAttribute('aria-controls')\n $tab.removeAttribute('aria-selected')\n $tab.removeAttribute('tabindex')\n\n // unset panel attributes\n const $panel = this.getPanel($tab)\n if (!$panel) {\n return\n }\n\n $panel.removeAttribute('role')\n $panel.removeAttribute('aria-labelledby')\n $panel.classList.remove(this.jsHiddenClass)\n }\n\n /**\n * Handle tab link clicks\n *\n * @private\n * @param {MouseEvent} event - Mouse click event\n * @returns {void} Returns void\n */\n onTabClick(event) {\n const $currentTab = this.getCurrentTab()\n const $nextTab = event.currentTarget\n\n if (!$currentTab || !($nextTab instanceof HTMLAnchorElement)) {\n return\n }\n\n event.preventDefault()\n\n this.hideTab($currentTab)\n this.showTab($nextTab)\n this.createHistoryEntry($nextTab)\n }\n\n /**\n * Update browser URL hash fragment for tab\n *\n * - Allows back/forward to navigate tabs\n * - Avoids page jump when hash changes\n *\n * @private\n * @param {HTMLAnchorElement} $tab - Tab link\n */\n createHistoryEntry($tab) {\n const $panel = this.getPanel($tab)\n if (!$panel) {\n return\n }\n\n // Save and restore the id so the page doesn't jump when a user clicks a tab\n // (which changes the hash)\n const panelId = $panel.id\n $panel.id = ''\n this.changingHash = true\n window.location.hash = panelId\n $panel.id = panelId\n }\n\n /**\n * Handle tab keydown event\n *\n * - Press right arrow for next tab\n * - Press left arrow for previous tab\n *\n * @private\n * @param {KeyboardEvent} event - Keydown event\n */\n onTabKeydown(event) {\n switch (event.key) {\n // 'Left' and 'Right' required for Edge 16 support.\n case 'ArrowLeft':\n case 'Left':\n this.activatePreviousTab()\n event.preventDefault()\n break\n case 'ArrowRight':\n case 'Right':\n this.activateNextTab()\n event.preventDefault()\n break\n }\n }\n\n /**\n * Activate next tab\n *\n * @private\n */\n activateNextTab() {\n const $currentTab = this.getCurrentTab()\n if (!$currentTab?.parentElement) {\n return\n }\n\n const $nextTabListItem = $currentTab.parentElement.nextElementSibling\n if (!$nextTabListItem) {\n return\n }\n\n const $nextTab = $nextTabListItem.querySelector('a.govuk-tabs__tab')\n if (!$nextTab) {\n return\n }\n\n this.hideTab($currentTab)\n this.showTab($nextTab)\n $nextTab.focus()\n this.createHistoryEntry($nextTab)\n }\n\n /**\n * Activate previous tab\n *\n * @private\n */\n activatePreviousTab() {\n const $currentTab = this.getCurrentTab()\n if (!$currentTab?.parentElement) {\n return\n }\n\n const $previousTabListItem =\n $currentTab.parentElement.previousElementSibling\n if (!$previousTabListItem) {\n return\n }\n\n const $previousTab = $previousTabListItem.querySelector('a.govuk-tabs__tab')\n if (!$previousTab) {\n return\n }\n\n this.hideTab($currentTab)\n this.showTab($previousTab)\n $previousTab.focus()\n this.createHistoryEntry($previousTab)\n }\n\n /**\n * Get tab panel for tab link\n *\n * @private\n * @param {HTMLAnchorElement} $tab - Tab link\n * @returns {Element | null} Tab panel\n */\n getPanel($tab) {\n const panelId = getFragmentFromUrl($tab.href)\n if (!panelId) {\n return null\n }\n\n return this.$root.querySelector(`#${panelId}`)\n }\n\n /**\n * Show tab panel for tab link\n *\n * @private\n * @param {HTMLAnchorElement} $tab - Tab link\n */\n showPanel($tab) {\n const $panel = this.getPanel($tab)\n if (!$panel) {\n return\n }\n\n $panel.classList.remove(this.jsHiddenClass)\n }\n\n /**\n * Hide tab panel for tab link\n *\n * @private\n * @param {HTMLAnchorElement} $tab - Tab link\n */\n hidePanel($tab) {\n const $panel = this.getPanel($tab)\n if (!$panel) {\n return\n }\n\n $panel.classList.add(this.jsHiddenClass)\n }\n\n /**\n * Unset 'selected' state for tab link\n *\n * @private\n * @param {HTMLAnchorElement} $tab - Tab link\n */\n unhighlightTab($tab) {\n if (!$tab.parentElement) {\n return\n }\n\n $tab.setAttribute('aria-selected', 'false')\n $tab.parentElement.classList.remove('govuk-tabs__list-item--selected')\n $tab.setAttribute('tabindex', '-1')\n }\n\n /**\n * Set 'selected' state for tab link\n *\n * @private\n * @param {HTMLAnchorElement} $tab - Tab link\n */\n highlightTab($tab) {\n if (!$tab.parentElement) {\n return\n }\n\n $tab.setAttribute('aria-selected', 'true')\n $tab.parentElement.classList.add('govuk-tabs__list-item--selected')\n $tab.setAttribute('tabindex', '0')\n }\n\n /**\n * Get current tab link\n *\n * @private\n * @returns {HTMLAnchorElement | null} Tab link\n */\n getCurrentTab() {\n return this.$root.querySelector(\n '.govuk-tabs__list-item--selected a.govuk-tabs__tab'\n )\n }\n\n /**\n * Name for the component used when initialising using data-module attributes.\n */\n static moduleName = 'govuk-tabs'\n}\n"],"names":["getFragmentFromUrl","url","includes","undefined","split","pop","getBreakpoint","name","property","value","window","getComputedStyle","document","documentElement","getPropertyValue","isInitialised","$root","moduleName","HTMLElement","hasAttribute","isSupported","$scope","body","classList","contains","formatErrorMessage","Component","message","GOVUKFrontendError","Error","constructor","args","SupportError","supportMessage","HTMLScriptElement","prototype","ElementError","messageOrOptions","component","identifier","element","expectedType","InitError","componentOrMessage","_$root","childConstructor","elementType","checkSupport","checkInitialised","setAttribute","Tabs","$tabs","$tabList","$tabListItems","jsHiddenClass","changingHash","boundTabClick","boundTabKeydown","boundOnHashChange","mql","querySelectorAll","length","onTabClick","bind","onTabKeydown","onHashChange","querySelector","setupResponsiveChecks","breakpoint","matchMedia","addEventListener","checkMode","addListener","_this$mql","matches","setup","teardown","_this$getTab","forEach","$item","$tab","setAttributes","hideTab","$activeTab","getTab","location","hash","showTab","removeAttribute","removeEventListener","unsetAttributes","$tabWithHash","$previousTab","getCurrentTab","focus","unhighlightTab","hidePanel","highlightTab","showPanel","panelId","href","$panel","getPanel","id","add","remove","event","$currentTab","$nextTab","currentTarget","HTMLAnchorElement","preventDefault","createHistoryEntry","key","activatePreviousTab","activateNextTab","parentElement","$nextTabListItem","nextElementSibling","$previousTabListItem","previousElementSibling"],"mappings":";;;;;;EAkBO,SAASA,kBAAkBA,CAACC,GAAG,EAAE;EACtC,EAAA,IAAI,CAACA,GAAG,CAACC,QAAQ,CAAC,GAAG,CAAC,EAAE;EAC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