defra_ruby_template 5.11.1 → 6.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (1367) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +187 -9
  3. data/Rakefile +123 -22
  4. data/app/views/layouts/defra_ruby_template.html.erb +108 -60
  5. data/lib/defra_ruby_template/version.rb +1 -1
  6. data/lib/defra_ruby_template.rb +12 -8
  7. data/node_modules/govuk-frontend/README.md +1 -1
  8. data/node_modules/govuk-frontend/dist/govuk/_base.import.scss +6 -0
  9. data/node_modules/govuk-frontend/dist/govuk/_base.scss +4 -4
  10. data/node_modules/govuk-frontend/dist/govuk/all.bundle.js +407 -453
  11. data/node_modules/govuk-frontend/dist/govuk/all.bundle.js.map +1 -1
  12. data/node_modules/govuk-frontend/dist/govuk/all.bundle.mjs +408 -453
  13. data/node_modules/govuk-frontend/dist/govuk/all.bundle.mjs.map +1 -1
  14. data/node_modules/govuk-frontend/dist/govuk/all.mjs +0 -1
  15. data/node_modules/govuk-frontend/dist/govuk/all.mjs.map +1 -1
  16. data/node_modules/govuk-frontend/dist/govuk/assets/images/favicon.ico +0 -0
  17. data/node_modules/govuk-frontend/dist/govuk/assets/images/favicon.svg +1 -1
  18. data/node_modules/govuk-frontend/dist/govuk/assets/images/govuk-icon-180.png +0 -0
  19. data/node_modules/govuk-frontend/dist/govuk/assets/images/govuk-icon-192.png +0 -0
  20. data/node_modules/govuk-frontend/dist/govuk/assets/images/govuk-icon-512.png +0 -0
  21. data/node_modules/govuk-frontend/dist/govuk/assets/images/govuk-opengraph-image.png +0 -0
  22. data/node_modules/govuk-frontend/dist/govuk/common/closest-attribute-value.mjs.map +1 -1
  23. data/node_modules/govuk-frontend/dist/govuk/common/configuration.mjs +34 -3
  24. data/node_modules/govuk-frontend/dist/govuk/common/configuration.mjs.map +1 -1
  25. data/node_modules/govuk-frontend/dist/govuk/common/create-element.mjs +13 -0
  26. data/node_modules/govuk-frontend/dist/govuk/common/create-element.mjs.map +1 -0
  27. data/node_modules/govuk-frontend/dist/govuk/common/govuk-frontend-version.mjs +1 -1
  28. data/node_modules/govuk-frontend/dist/govuk/common/govuk-frontend-version.mjs.map +1 -1
  29. data/node_modules/govuk-frontend/dist/govuk/common/index.mjs +5 -11
  30. data/node_modules/govuk-frontend/dist/govuk/common/index.mjs.map +1 -1
  31. data/node_modules/govuk-frontend/dist/govuk/component.mjs +2 -1
  32. data/node_modules/govuk-frontend/dist/govuk/component.mjs.map +1 -1
  33. data/node_modules/govuk-frontend/dist/govuk/components/_index.import.scss +40 -0
  34. data/node_modules/govuk-frontend/dist/govuk/components/_index.scss +39 -39
  35. data/node_modules/govuk-frontend/dist/govuk/components/accordion/_accordion.import.scss +6 -0
  36. data/node_modules/govuk-frontend/dist/govuk/components/accordion/_index.import.scss +8 -0
  37. data/node_modules/govuk-frontend/dist/govuk/components/accordion/_index.scss +3 -368
  38. data/node_modules/govuk-frontend/dist/govuk/components/accordion/_mixin.scss +375 -0
  39. data/node_modules/govuk-frontend/dist/govuk/components/accordion/accordion.bundle.js +101 -199
  40. data/node_modules/govuk-frontend/dist/govuk/components/accordion/accordion.bundle.js.map +1 -1
  41. data/node_modules/govuk-frontend/dist/govuk/components/accordion/accordion.bundle.mjs +101 -199
  42. data/node_modules/govuk-frontend/dist/govuk/components/accordion/accordion.bundle.mjs.map +1 -1
  43. data/node_modules/govuk-frontend/dist/govuk/components/accordion/accordion.mjs +64 -60
  44. data/node_modules/govuk-frontend/dist/govuk/components/accordion/accordion.mjs.map +1 -1
  45. data/node_modules/govuk-frontend/dist/govuk/components/accordion/fixtures.json +102 -97
  46. data/node_modules/govuk-frontend/dist/govuk/components/back-link/_back-link.import.scss +6 -0
  47. data/node_modules/govuk-frontend/dist/govuk/components/back-link/_index.import.scss +8 -0
  48. data/node_modules/govuk-frontend/dist/govuk/components/back-link/_index.scss +3 -81
  49. data/node_modules/govuk-frontend/dist/govuk/components/back-link/_mixin.scss +87 -0
  50. data/node_modules/govuk-frontend/dist/govuk/components/back-link/fixtures.json +21 -32
  51. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/_breadcrumbs.import.scss +6 -0
  52. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/_index.import.scss +8 -0
  53. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/_index.scss +3 -132
  54. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/_mixin.scss +134 -0
  55. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/fixtures.json +25 -45
  56. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/template-default.html +6 -0
  57. data/node_modules/govuk-frontend/dist/govuk/components/button/_button.import.scss +6 -0
  58. data/node_modules/govuk-frontend/dist/govuk/components/button/_index.import.scss +13 -0
  59. data/node_modules/govuk-frontend/dist/govuk/components/button/_index.scss +9 -260
  60. data/node_modules/govuk-frontend/dist/govuk/components/button/_mixin.scss +233 -0
  61. data/node_modules/govuk-frontend/dist/govuk/components/button/_settings.import.scss +32 -0
  62. data/node_modules/govuk-frontend/dist/govuk/components/button/_settings.scss +34 -0
  63. data/node_modules/govuk-frontend/dist/govuk/components/button/button.bundle.js +24 -11
  64. data/node_modules/govuk-frontend/dist/govuk/components/button/button.bundle.js.map +1 -1
  65. data/node_modules/govuk-frontend/dist/govuk/components/button/button.bundle.mjs +24 -11
  66. data/node_modules/govuk-frontend/dist/govuk/components/button/button.bundle.mjs.map +1 -1
  67. data/node_modules/govuk-frontend/dist/govuk/components/button/button.mjs.map +1 -1
  68. data/node_modules/govuk-frontend/dist/govuk/components/button/fixtures.json +193 -209
  69. data/node_modules/govuk-frontend/dist/govuk/components/button/macro-options.json +12 -19
  70. data/node_modules/govuk-frontend/dist/govuk/components/button/template-default-active-state.html +3 -0
  71. data/node_modules/govuk-frontend/dist/govuk/components/button/template-default-focus-state.html +3 -0
  72. data/node_modules/govuk-frontend/dist/govuk/components/button/template-default-hover-state.html +3 -0
  73. data/node_modules/govuk-frontend/dist/govuk/components/button/template-inverse-active-state.html +3 -0
  74. data/node_modules/govuk-frontend/dist/govuk/components/button/template-inverse-disabled.html +1 -1
  75. data/node_modules/govuk-frontend/dist/govuk/components/button/template-inverse-focus-state.html +3 -0
  76. data/node_modules/govuk-frontend/dist/govuk/components/button/template-inverse-hover-state.html +3 -0
  77. data/node_modules/govuk-frontend/dist/govuk/components/button/template-secondary-active-state.html +3 -0
  78. data/node_modules/govuk-frontend/dist/govuk/components/button/template-secondary-focus-state.html +3 -0
  79. data/node_modules/govuk-frontend/dist/govuk/components/button/template-secondary-hover-state.html +3 -0
  80. data/node_modules/govuk-frontend/dist/govuk/components/button/template-warning-active-state.html +3 -0
  81. data/node_modules/govuk-frontend/dist/govuk/components/button/template-warning-focus-state.html +3 -0
  82. data/node_modules/govuk-frontend/dist/govuk/components/button/template-warning-hover-state.html +3 -0
  83. data/node_modules/govuk-frontend/dist/govuk/components/button/template.njk +20 -20
  84. data/node_modules/govuk-frontend/dist/govuk/components/character-count/_character-count.import.scss +6 -0
  85. data/node_modules/govuk-frontend/dist/govuk/components/character-count/_index.import.scss +12 -0
  86. data/node_modules/govuk-frontend/dist/govuk/components/character-count/_index.scss +7 -42
  87. data/node_modules/govuk-frontend/dist/govuk/components/character-count/_mixin.scss +41 -0
  88. data/node_modules/govuk-frontend/dist/govuk/components/character-count/character-count.bundle.js +119 -174
  89. data/node_modules/govuk-frontend/dist/govuk/components/character-count/character-count.bundle.js.map +1 -1
  90. data/node_modules/govuk-frontend/dist/govuk/components/character-count/character-count.bundle.mjs +119 -174
  91. data/node_modules/govuk-frontend/dist/govuk/components/character-count/character-count.bundle.mjs.map +1 -1
  92. data/node_modules/govuk-frontend/dist/govuk/components/character-count/character-count.mjs +83 -36
  93. data/node_modules/govuk-frontend/dist/govuk/components/character-count/character-count.mjs.map +1 -1
  94. data/node_modules/govuk-frontend/dist/govuk/components/character-count/fixtures.json +245 -92
  95. data/node_modules/govuk-frontend/dist/govuk/components/character-count/macro-options.json +13 -6
  96. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-count-type-characters-and-error-message.html +12 -0
  97. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-count-type-characters-and-threshold.html +9 -0
  98. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-count-type-characters-and-value.html +9 -0
  99. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-count-type-characters.html +9 -0
  100. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-count-type-length.html +9 -0
  101. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-count-type-words-and-error-message.html +12 -0
  102. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-count-type-words-and-threshold.html +9 -0
  103. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-count-type-words-and-value.html +9 -0
  104. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-count-type-words.html +9 -0
  105. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-maxwords.html +9 -0
  106. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template.njk +10 -3
  107. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/_checkboxes.import.scss +6 -0
  108. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/_index.import.scss +12 -0
  109. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/_index.scss +7 -309
  110. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/_mixin.scss +317 -0
  111. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/checkboxes.bundle.js +22 -10
  112. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/checkboxes.bundle.js.map +1 -1
  113. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/checkboxes.bundle.mjs +22 -10
  114. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/checkboxes.bundle.mjs.map +1 -1
  115. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/checkboxes.mjs.map +1 -1
  116. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/fixtures.json +326 -480
  117. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/macro-options.json +1 -1
  118. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-default.html +5 -0
  119. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-small-with-conditional-reveal.html +21 -21
  120. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-small-with-divider-and-none.html +30 -30
  121. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-small-with-error.html +26 -26
  122. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-small-with-hint.html +25 -25
  123. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-small-with-long-text.html +23 -23
  124. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-small.html +23 -23
  125. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-conditional-items.html +35 -35
  126. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-divider-and-none.html +30 -32
  127. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-divider-none-and-conditional-items.html +40 -42
  128. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-error-message.html +32 -23
  129. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-hint.html +30 -0
  130. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-hints-on-items.html +21 -23
  131. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-legend-as-a-page-heading.html +27 -27
  132. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-optional-form-group-classes-showing-group-error.html +36 -36
  133. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-pre-checked-values.html +25 -16
  134. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-very-long-option-text.html +27 -30
  135. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template.njk +1 -1
  136. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/_cookie-banner.import.scss +6 -0
  137. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/_index.import.scss +9 -0
  138. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/_index.scss +4 -56
  139. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/_mixin.scss +62 -0
  140. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/fixtures.json +82 -82
  141. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/template-default.html +2 -2
  142. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/template-with-html.html +2 -2
  143. data/node_modules/govuk-frontend/dist/govuk/components/date-input/_date-input.import.scss +6 -0
  144. data/node_modules/govuk-frontend/dist/govuk/components/date-input/_index.import.scss +13 -0
  145. data/node_modules/govuk-frontend/dist/govuk/components/date-input/_index.scss +8 -26
  146. data/node_modules/govuk-frontend/dist/govuk/components/date-input/_mixin.scss +29 -0
  147. data/node_modules/govuk-frontend/dist/govuk/components/date-input/fixtures.json +780 -150
  148. data/node_modules/govuk-frontend/dist/govuk/components/date-input/macro-options.json +50 -0
  149. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-day-and-month-using-items.html +28 -0
  150. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-default.html +30 -22
  151. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-month-and-year-using-items.html +28 -0
  152. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-error-message-and-hint-using-items.html +39 -0
  153. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-error-message-and-hint.html +39 -0
  154. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-error-on-day-input-using-items.html +39 -0
  155. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-error-on-day-input.html +3 -3
  156. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-error-on-month-input-using-items.html +39 -0
  157. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-error-on-month-input.html +3 -3
  158. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-error-on-year-input-using-items.html +39 -0
  159. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-error-on-year-input.html +3 -3
  160. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-errors-only-using-classes.html +33 -0
  161. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-errors-only-using-items-and-classes.html +33 -0
  162. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-errors-only-using-items.html +33 -0
  163. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-errors-only.html +5 -8
  164. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-translations.html +36 -0
  165. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-values-and-name-prefix.html +36 -0
  166. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-values-name-prefix-and-custom-names.html +36 -0
  167. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-values.html +36 -0
  168. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template.njk +84 -29
  169. data/node_modules/govuk-frontend/dist/govuk/components/details/_details.import.scss +6 -0
  170. data/node_modules/govuk-frontend/dist/govuk/components/details/_index.import.scss +8 -0
  171. data/node_modules/govuk-frontend/dist/govuk/components/details/_index.scss +3 -137
  172. data/node_modules/govuk-frontend/dist/govuk/components/details/_mixin.scss +143 -0
  173. data/node_modules/govuk-frontend/dist/govuk/components/details/fixtures.json +22 -22
  174. data/node_modules/govuk-frontend/dist/govuk/components/error-message/_error-message.import.scss +6 -0
  175. data/node_modules/govuk-frontend/dist/govuk/components/error-message/_index.import.scss +8 -0
  176. data/node_modules/govuk-frontend/dist/govuk/components/error-message/_index.scss +3 -12
  177. data/node_modules/govuk-frontend/dist/govuk/components/error-message/_mixin.scss +16 -0
  178. data/node_modules/govuk-frontend/dist/govuk/components/error-message/fixtures.json +10 -10
  179. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/_error-summary.import.scss +6 -0
  180. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/_index.import.scss +8 -0
  181. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/_index.scss +3 -53
  182. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/_mixin.scss +58 -0
  183. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/error-summary.bundle.js +25 -18
  184. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/error-summary.bundle.js.map +1 -1
  185. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/error-summary.bundle.mjs +25 -18
  186. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/error-summary.bundle.mjs.map +1 -1
  187. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/error-summary.mjs +2 -2
  188. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/error-summary.mjs.map +1 -1
  189. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/fixtures.json +21 -21
  190. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/_exit-this-page.import.scss +6 -0
  191. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/_index.import.scss +9 -0
  192. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/_index.scss +4 -89
  193. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/_mixin.scss +96 -0
  194. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/exit-this-page.bundle.js +53 -151
  195. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/exit-this-page.bundle.js.map +1 -1
  196. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/exit-this-page.bundle.mjs +53 -151
  197. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/exit-this-page.bundle.mjs.map +1 -1
  198. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/exit-this-page.mjs +16 -12
  199. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/exit-this-page.mjs.map +1 -1
  200. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/fixtures.json +19 -19
  201. data/node_modules/govuk-frontend/dist/govuk/components/feedback/README.md +15 -0
  202. data/node_modules/govuk-frontend/dist/govuk/components/feedback/_feedback.import.scss +6 -0
  203. data/node_modules/govuk-frontend/dist/govuk/components/feedback/_index.import.scss +8 -0
  204. data/node_modules/govuk-frontend/dist/govuk/components/feedback/_index.scss +5 -0
  205. data/node_modules/govuk-frontend/dist/govuk/components/feedback/_mixin.scss +48 -0
  206. data/node_modules/govuk-frontend/dist/govuk/components/feedback/fixtures.json +95 -0
  207. data/node_modules/govuk-frontend/dist/govuk/components/feedback/macro-options.json +50 -0
  208. data/node_modules/govuk-frontend/dist/govuk/components/feedback/macro.njk +3 -0
  209. data/node_modules/govuk-frontend/dist/govuk/components/feedback/template-default.html +12 -0
  210. data/node_modules/govuk-frontend/dist/govuk/components/feedback/template-silly-example.html +19 -0
  211. data/node_modules/govuk-frontend/dist/govuk/components/feedback/template.njk +24 -0
  212. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/_fieldset.import.scss +6 -0
  213. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/_index.import.scss +8 -0
  214. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/_index.scss +3 -67
  215. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/_mixin.scss +71 -0
  216. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/fixtures.json +19 -19
  217. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/_file-upload.import.scss +6 -0
  218. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/_index.import.scss +11 -0
  219. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/_index.scss +6 -216
  220. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/_mixin.scss +217 -0
  221. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/file-upload.bundle.js +123 -187
  222. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/file-upload.bundle.js.map +1 -1
  223. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/file-upload.bundle.mjs +123 -187
  224. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/file-upload.bundle.mjs.map +1 -1
  225. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/file-upload.mjs +86 -49
  226. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/file-upload.mjs.map +1 -1
  227. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/fixtures.json +125 -138
  228. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/macro-options.json +15 -10
  229. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template-enhanced-custom-wrapper-classes-and-attributes.html +11 -0
  230. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template-enhanced-multiple-files.html +11 -0
  231. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template-enhanced-with-error-message-and-hint.html +3 -2
  232. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template-enhanced.html +3 -2
  233. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template-translated.html +3 -2
  234. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template.njk +2 -2
  235. data/node_modules/govuk-frontend/dist/govuk/components/footer/_footer.import.scss +6 -0
  236. data/node_modules/govuk-frontend/dist/govuk/components/footer/_index.import.scss +8 -0
  237. data/node_modules/govuk-frontend/dist/govuk/components/footer/_index.scss +3 -192
  238. data/node_modules/govuk-frontend/dist/govuk/components/footer/_mixin.scss +205 -0
  239. data/node_modules/govuk-frontend/dist/govuk/components/footer/fixtures.json +129 -81
  240. data/node_modules/govuk-frontend/dist/govuk/components/footer/macro-options.json +1 -7
  241. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-default.html +45 -24
  242. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-full-gds-example.html +45 -24
  243. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-three-equal-columns.html +45 -24
  244. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-with-custom-html-content-licence-and-copyright-notice.html +40 -19
  245. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-with-custom-meta.html +45 -24
  246. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-with-custom-text-content-licence-and-copyright-notice.html +40 -19
  247. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-with-default-width-navigation-one-column.html +45 -24
  248. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-with-default-width-navigation-two-columns.html +45 -24
  249. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-with-meta-links-and-meta-content.html +45 -24
  250. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-with-navigation.html +45 -24
  251. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-with-no-content-licence.html +37 -0
  252. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-with-only-custom-meta.html +41 -0
  253. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-with-only-meta-links.html +80 -0
  254. data/node_modules/govuk-frontend/dist/govuk/components/footer/template.njk +36 -39
  255. data/node_modules/govuk-frontend/dist/govuk/components/generic-header/README.md +15 -0
  256. data/node_modules/govuk-frontend/dist/govuk/components/generic-header/_generic-header.import.scss +6 -0
  257. data/node_modules/govuk-frontend/dist/govuk/components/generic-header/_index.import.scss +8 -0
  258. data/node_modules/govuk-frontend/dist/govuk/components/generic-header/_index.scss +5 -0
  259. data/node_modules/govuk-frontend/dist/govuk/components/generic-header/_mixin.scss +140 -0
  260. data/node_modules/govuk-frontend/dist/govuk/components/generic-header/fixtures.json +90 -0
  261. data/node_modules/govuk-frontend/dist/govuk/components/generic-header/macro-options.json +38 -0
  262. data/node_modules/govuk-frontend/dist/govuk/components/generic-header/macro.njk +3 -0
  263. data/node_modules/govuk-frontend/dist/govuk/components/generic-header/template-default.html +11 -0
  264. data/node_modules/govuk-frontend/dist/govuk/components/generic-header/template-full-width.html +20 -0
  265. data/node_modules/govuk-frontend/dist/govuk/components/generic-header/template-with-image-logo.html +20 -0
  266. data/node_modules/govuk-frontend/dist/govuk/components/generic-header/template-with-text-and-image-logo.html +20 -0
  267. data/node_modules/govuk-frontend/dist/govuk/components/generic-header/template.njk +14 -0
  268. data/node_modules/govuk-frontend/dist/govuk/components/header/README.md +1 -1
  269. data/node_modules/govuk-frontend/dist/govuk/components/header/_header.import.scss +6 -0
  270. data/node_modules/govuk-frontend/dist/govuk/components/header/_index.import.scss +8 -0
  271. data/node_modules/govuk-frontend/dist/govuk/components/header/_index.scss +3 -546
  272. data/node_modules/govuk-frontend/dist/govuk/components/header/_mixin.scss +119 -0
  273. data/node_modules/govuk-frontend/dist/govuk/components/header/fixtures.json +15 -492
  274. data/node_modules/govuk-frontend/dist/govuk/components/header/macro-options.json +2 -101
  275. data/node_modules/govuk-frontend/dist/govuk/components/header/template-default.html +12 -7
  276. data/node_modules/govuk-frontend/dist/govuk/components/header/template-full-width.html +12 -8
  277. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-product-name.html +11 -7
  278. data/node_modules/govuk-frontend/dist/govuk/components/header/template.njk +20 -63
  279. data/node_modules/govuk-frontend/dist/govuk/components/hint/_hint.import.scss +6 -0
  280. data/node_modules/govuk-frontend/dist/govuk/components/hint/_index.import.scss +8 -0
  281. data/node_modules/govuk-frontend/dist/govuk/components/hint/_index.scss +3 -43
  282. data/node_modules/govuk-frontend/dist/govuk/components/hint/_mixin.scss +47 -0
  283. data/node_modules/govuk-frontend/dist/govuk/components/hint/fixtures.json +7 -7
  284. data/node_modules/govuk-frontend/dist/govuk/components/input/_index.import.scss +11 -0
  285. data/node_modules/govuk-frontend/dist/govuk/components/input/_index.scss +6 -166
  286. data/node_modules/govuk-frontend/dist/govuk/components/input/_input.import.scss +6 -0
  287. data/node_modules/govuk-frontend/dist/govuk/components/input/_mixin.scss +161 -0
  288. data/node_modules/govuk-frontend/dist/govuk/components/input/fixtures.json +161 -180
  289. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-extra-letter-spacing.html +1 -1
  290. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/_index.import.scss +8 -0
  291. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/_index.scss +3 -24
  292. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/_inset-text.import.scss +6 -0
  293. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/_mixin.scss +31 -0
  294. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/fixtures.json +7 -7
  295. data/node_modules/govuk-frontend/dist/govuk/components/label/_index.import.scss +8 -0
  296. data/node_modules/govuk-frontend/dist/govuk/components/label/_index.scss +3 -44
  297. data/node_modules/govuk-frontend/dist/govuk/components/label/_label.import.scss +6 -0
  298. data/node_modules/govuk-frontend/dist/govuk/components/label/_mixin.scss +48 -0
  299. data/node_modules/govuk-frontend/dist/govuk/components/label/fixtures.json +20 -20
  300. data/node_modules/govuk-frontend/dist/govuk/components/language-navigation/README.md +15 -0
  301. data/node_modules/govuk-frontend/dist/govuk/components/language-navigation/_index.import.scss +8 -0
  302. data/node_modules/govuk-frontend/dist/govuk/components/language-navigation/_index.scss +6 -0
  303. data/node_modules/govuk-frontend/dist/govuk/components/language-navigation/_language-navigation.import.scss +6 -0
  304. data/node_modules/govuk-frontend/dist/govuk/components/language-navigation/_mixin.scss +68 -0
  305. data/node_modules/govuk-frontend/dist/govuk/components/language-navigation/fixtures.json +482 -0
  306. data/node_modules/govuk-frontend/dist/govuk/components/language-navigation/macro-options.json +88 -0
  307. data/node_modules/govuk-frontend/dist/govuk/components/language-navigation/macro.njk +3 -0
  308. data/node_modules/govuk-frontend/dist/govuk/components/language-navigation/template-default.html +12 -0
  309. data/node_modules/govuk-frontend/dist/govuk/components/language-navigation/template-inverse.html +12 -0
  310. data/node_modules/govuk-frontend/dist/govuk/components/language-navigation/template-with-language-description.html +12 -0
  311. data/node_modules/govuk-frontend/dist/govuk/components/language-navigation/template-with-large-amount-of-multiple-languages.html +99 -0
  312. data/node_modules/govuk-frontend/dist/govuk/components/language-navigation/template-with-mixed-text-directions.html +12 -0
  313. data/node_modules/govuk-frontend/dist/govuk/components/language-navigation/template-with-multiple-languages.html +24 -0
  314. data/node_modules/govuk-frontend/dist/govuk/components/language-navigation/template-with-translated-navigation-label.html +12 -0
  315. data/node_modules/govuk-frontend/dist/govuk/components/language-navigation/template.njk +33 -0
  316. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/_index.import.scss +8 -0
  317. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/_index.scss +3 -91
  318. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/_mixin.scss +100 -0
  319. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/_notification-banner.import.scss +6 -0
  320. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/fixtures.json +74 -108
  321. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/notification-banner.bundle.js +24 -11
  322. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/notification-banner.bundle.js.map +1 -1
  323. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/notification-banner.bundle.mjs +24 -11
  324. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/notification-banner.bundle.mjs.map +1 -1
  325. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/notification-banner.mjs.map +1 -1
  326. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/template-with-text-as-html.html +7 -1
  327. data/node_modules/govuk-frontend/dist/govuk/components/pagination/_index.import.scss +8 -0
  328. data/node_modules/govuk-frontend/dist/govuk/components/pagination/_index.scss +3 -226
  329. data/node_modules/govuk-frontend/dist/govuk/components/pagination/_mixin.scss +235 -0
  330. data/node_modules/govuk-frontend/dist/govuk/components/pagination/_pagination.import.scss +6 -0
  331. data/node_modules/govuk-frontend/dist/govuk/components/pagination/fixtures.json +109 -105
  332. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template-default.html +3 -3
  333. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template-first-page.html +3 -3
  334. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template-last-page.html +3 -3
  335. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template-with-custom-link-and-item-text.html +3 -3
  336. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template-with-many-pages.html +9 -9
  337. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template.njk +4 -2
  338. data/node_modules/govuk-frontend/dist/govuk/components/panel/_index.import.scss +8 -0
  339. data/node_modules/govuk-frontend/dist/govuk/components/panel/_index.scss +3 -56
  340. data/node_modules/govuk-frontend/dist/govuk/components/panel/_mixin.scss +94 -0
  341. data/node_modules/govuk-frontend/dist/govuk/components/panel/_panel.import.scss +6 -0
  342. data/node_modules/govuk-frontend/dist/govuk/components/panel/fixtures.json +251 -16
  343. data/node_modules/govuk-frontend/dist/govuk/components/panel/macro-options.json +58 -0
  344. data/node_modules/govuk-frontend/dist/govuk/components/panel/template-default.html +1 -1
  345. data/node_modules/govuk-frontend/dist/govuk/components/panel/template-interruption-with-content-with-long-line-length.html +17 -0
  346. data/node_modules/govuk-frontend/dist/govuk/components/panel/template-interruption-with-headings-content-and-lists.html +23 -0
  347. data/node_modules/govuk-frontend/dist/govuk/components/panel/template-interruption.html +14 -0
  348. data/node_modules/govuk-frontend/dist/govuk/components/panel/template.njk +42 -2
  349. data/node_modules/govuk-frontend/dist/govuk/components/password-input/_index.import.scss +10 -0
  350. data/node_modules/govuk-frontend/dist/govuk/components/password-input/_index.scss +5 -54
  351. data/node_modules/govuk-frontend/dist/govuk/components/password-input/_mixin.scss +56 -0
  352. data/node_modules/govuk-frontend/dist/govuk/components/password-input/_password-input.import.scss +6 -0
  353. data/node_modules/govuk-frontend/dist/govuk/components/password-input/fixtures.json +53 -48
  354. data/node_modules/govuk-frontend/dist/govuk/components/password-input/password-input.bundle.js +42 -142
  355. data/node_modules/govuk-frontend/dist/govuk/components/password-input/password-input.bundle.js.map +1 -1
  356. data/node_modules/govuk-frontend/dist/govuk/components/password-input/password-input.bundle.mjs +42 -142
  357. data/node_modules/govuk-frontend/dist/govuk/components/password-input/password-input.bundle.mjs.map +1 -1
  358. data/node_modules/govuk-frontend/dist/govuk/components/password-input/password-input.mjs +5 -3
  359. data/node_modules/govuk-frontend/dist/govuk/components/password-input/password-input.mjs.map +1 -1
  360. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/_index.import.scss +9 -0
  361. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/_index.scss +4 -33
  362. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/_mixin.scss +42 -0
  363. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/_phase-banner.import.scss +6 -0
  364. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/fixtures.json +15 -15
  365. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/template-default.html +1 -1
  366. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/template.njk +1 -1
  367. data/node_modules/govuk-frontend/dist/govuk/components/radios/_index.import.scss +12 -0
  368. data/node_modules/govuk-frontend/dist/govuk/components/radios/_index.scss +7 -325
  369. data/node_modules/govuk-frontend/dist/govuk/components/radios/_mixin.scss +336 -0
  370. data/node_modules/govuk-frontend/dist/govuk/components/radios/_radios.import.scss +6 -0
  371. data/node_modules/govuk-frontend/dist/govuk/components/radios/fixtures.json +244 -354
  372. data/node_modules/govuk-frontend/dist/govuk/components/radios/macro-options.json +3 -3
  373. data/node_modules/govuk-frontend/dist/govuk/components/radios/radios.bundle.js +22 -10
  374. data/node_modules/govuk-frontend/dist/govuk/components/radios/radios.bundle.js.map +1 -1
  375. data/node_modules/govuk-frontend/dist/govuk/components/radios/radios.bundle.mjs +22 -10
  376. data/node_modules/govuk-frontend/dist/govuk/components/radios/radios.bundle.mjs.map +1 -1
  377. data/node_modules/govuk-frontend/dist/govuk/components/radios/radios.mjs.map +1 -1
  378. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-default.html +5 -3
  379. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-inline.html +19 -19
  380. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-small-inline.html +23 -23
  381. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-small-with-a-divider.html +24 -24
  382. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-small-with-conditional-reveal.html +27 -27
  383. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-small-with-error.html +26 -26
  384. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-small-with-hint.html +25 -25
  385. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-small-with-long-text.html +23 -23
  386. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-small.html +23 -23
  387. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-a-divider.html +24 -24
  388. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-conditional-item-checked.html +35 -35
  389. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-conditional-items-and-pre-checked-value.html +35 -35
  390. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-conditional-items.html +35 -35
  391. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-fieldset-and-error-message.html +20 -20
  392. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-hint.html +24 -0
  393. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-hints-on-items.html +23 -23
  394. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-legend-as-page-heading.html +21 -21
  395. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-optional-form-group-classes-showing-group-error.html +36 -36
  396. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-very-long-option-text.html +28 -28
  397. data/node_modules/govuk-frontend/dist/govuk/components/radios/template.njk +1 -1
  398. data/node_modules/govuk-frontend/dist/govuk/components/select/_index.import.scss +11 -0
  399. data/node_modules/govuk-frontend/dist/govuk/components/select/_index.scss +6 -56
  400. data/node_modules/govuk-frontend/dist/govuk/components/select/_mixin.scss +45 -0
  401. data/node_modules/govuk-frontend/dist/govuk/components/select/_select.import.scss +6 -0
  402. data/node_modules/govuk-frontend/dist/govuk/components/select/fixtures.json +99 -115
  403. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/_index.import.scss +8 -0
  404. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/_index.scss +3 -185
  405. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/_mixin.scss +283 -0
  406. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/_service-navigation.import.scss +6 -0
  407. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/fixtures.json +331 -69
  408. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/macro-options.json +26 -0
  409. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/service-navigation.bundle.js +53 -13
  410. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/service-navigation.bundle.js.map +1 -1
  411. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/service-navigation.bundle.mjs +53 -13
  412. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/service-navigation.bundle.mjs.map +1 -1
  413. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/service-navigation.mjs +30 -2
  414. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/service-navigation.mjs.map +1 -1
  415. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-default.html +1 -1
  416. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-inverse-with-language-navigation.html +72 -0
  417. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-inverse.html +63 -0
  418. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-a-single-navigation-item-and-collapsenavigationonmobile-set-to-true.html +38 -0
  419. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-a-single-navigation-item.html +35 -0
  420. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-collapsenavigationonmobile-set-to-false.html +60 -0
  421. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-html-navigation-items.html +1 -1
  422. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-inline-end-slot.html +33 -0
  423. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-language-navigation.html +62 -0
  424. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-large-navigation.html +1 -1
  425. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-navigation-with-a-current-item.html +1 -1
  426. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-non-link-navigation-items.html +1 -1
  427. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-right-aligned-language-navigation.html +62 -0
  428. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-service-name-and-navigation.html +1 -1
  429. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template.njk +12 -4
  430. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/_index.import.scss +8 -0
  431. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/_index.scss +3 -50
  432. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/_mixin.scss +60 -0
  433. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/_skip-link.import.scss +6 -0
  434. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/fixtures.json +10 -10
  435. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/skip-link.bundle.js +26 -25
  436. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/skip-link.bundle.js.map +1 -1
  437. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/skip-link.bundle.mjs +26 -25
  438. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/skip-link.bundle.mjs.map +1 -1
  439. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/skip-link.mjs +5 -10
  440. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/skip-link.mjs.map +1 -1
  441. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/_index.import.scss +8 -0
  442. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/_index.scss +3 -267
  443. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/_mixin.scss +286 -0
  444. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/_summary-list.import.scss +6 -0
  445. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/fixtures.json +282 -518
  446. data/node_modules/govuk-frontend/dist/govuk/components/table/_index.import.scss +8 -0
  447. data/node_modules/govuk-frontend/dist/govuk/components/table/_index.scss +3 -73
  448. data/node_modules/govuk-frontend/dist/govuk/components/table/_mixin.scss +77 -0
  449. data/node_modules/govuk-frontend/dist/govuk/components/table/_table.import.scss +6 -0
  450. data/node_modules/govuk-frontend/dist/govuk/components/table/fixtures.json +75 -75
  451. data/node_modules/govuk-frontend/dist/govuk/components/tabs/_index.import.scss +8 -0
  452. data/node_modules/govuk-frontend/dist/govuk/components/tabs/_index.scss +3 -132
  453. data/node_modules/govuk-frontend/dist/govuk/components/tabs/_mixin.scss +140 -0
  454. data/node_modules/govuk-frontend/dist/govuk/components/tabs/_tabs.import.scss +6 -0
  455. data/node_modules/govuk-frontend/dist/govuk/components/tabs/fixtures.json +44 -39
  456. data/node_modules/govuk-frontend/dist/govuk/components/tabs/tabs.bundle.js +25 -19
  457. data/node_modules/govuk-frontend/dist/govuk/components/tabs/tabs.bundle.js.map +1 -1
  458. data/node_modules/govuk-frontend/dist/govuk/components/tabs/tabs.bundle.mjs +25 -19
  459. data/node_modules/govuk-frontend/dist/govuk/components/tabs/tabs.bundle.mjs.map +1 -1
  460. data/node_modules/govuk-frontend/dist/govuk/components/tabs/tabs.mjs +3 -3
  461. data/node_modules/govuk-frontend/dist/govuk/components/tabs/tabs.mjs.map +1 -1
  462. data/node_modules/govuk-frontend/dist/govuk/components/tag/_index.import.scss +8 -0
  463. data/node_modules/govuk-frontend/dist/govuk/components/tag/_index.scss +3 -94
  464. data/node_modules/govuk-frontend/dist/govuk/components/tag/_mixin.scss +135 -0
  465. data/node_modules/govuk-frontend/dist/govuk/components/tag/_tag.import.scss +6 -0
  466. data/node_modules/govuk-frontend/dist/govuk/components/tag/fixtures.json +19 -43
  467. data/node_modules/govuk-frontend/dist/govuk/components/tag/template-pink.html +2 -2
  468. data/node_modules/govuk-frontend/dist/govuk/components/tag/template-turquoise.html +2 -2
  469. data/node_modules/govuk-frontend/dist/govuk/components/task-list/_index.import.scss +9 -0
  470. data/node_modules/govuk-frontend/dist/govuk/components/task-list/_index.scss +4 -76
  471. data/node_modules/govuk-frontend/dist/govuk/components/task-list/_mixin.scss +83 -0
  472. data/node_modules/govuk-frontend/dist/govuk/components/task-list/_task-list.import.scss +6 -0
  473. data/node_modules/govuk-frontend/dist/govuk/components/task-list/fixtures.json +35 -58
  474. data/node_modules/govuk-frontend/dist/govuk/components/task-list/template-forced-hover-state.html +37 -0
  475. data/node_modules/govuk-frontend/dist/govuk/components/task-list/template-with-all-possible-colours.html +131 -0
  476. data/node_modules/govuk-frontend/dist/govuk/components/task-list/template-with-hint-text-and-additional-states.html +77 -0
  477. data/node_modules/govuk-frontend/dist/govuk/components/textarea/_index.import.scss +11 -0
  478. data/node_modules/govuk-frontend/dist/govuk/components/textarea/_index.scss +6 -47
  479. data/node_modules/govuk-frontend/dist/govuk/components/textarea/_mixin.scss +43 -0
  480. data/node_modules/govuk-frontend/dist/govuk/components/textarea/_textarea.import.scss +6 -0
  481. data/node_modules/govuk-frontend/dist/govuk/components/textarea/fixtures.json +81 -81
  482. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/_index.import.scss +8 -0
  483. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/_index.scss +3 -64
  484. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/_mixin.scss +69 -0
  485. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/_warning-text.import.scss +6 -0
  486. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/fixtures.json +9 -9
  487. data/node_modules/govuk-frontend/dist/govuk/core/_global-styles.import.scss +10 -0
  488. data/node_modules/govuk-frontend/dist/govuk/core/_global-styles.mixin.scss +19 -0
  489. data/node_modules/govuk-frontend/dist/govuk/core/_global-styles.scss +5 -18
  490. data/node_modules/govuk-frontend/dist/govuk/core/_index.import.scss +6 -0
  491. data/node_modules/govuk-frontend/dist/govuk/core/_index.scss +6 -7
  492. data/node_modules/govuk-frontend/dist/govuk/core/_links.import.scss +10 -0
  493. data/node_modules/govuk-frontend/dist/govuk/core/_links.mixin.scss +44 -0
  494. data/node_modules/govuk-frontend/dist/govuk/core/_links.scss +3 -40
  495. data/node_modules/govuk-frontend/dist/govuk/core/_lists.import.scss +14 -0
  496. data/node_modules/govuk-frontend/dist/govuk/core/_lists.mixin.scss +74 -0
  497. data/node_modules/govuk-frontend/dist/govuk/core/_lists.scss +6 -64
  498. data/node_modules/govuk-frontend/dist/govuk/core/_section-break.import.scss +8 -0
  499. data/node_modules/govuk-frontend/dist/govuk/core/_section-break.mixin.scss +54 -0
  500. data/node_modules/govuk-frontend/dist/govuk/core/_section-break.scss +3 -49
  501. data/node_modules/govuk-frontend/dist/govuk/core/_typography.import.scss +8 -0
  502. data/node_modules/govuk-frontend/dist/govuk/core/_typography.mixin.scss +173 -0
  503. data/node_modules/govuk-frontend/dist/govuk/core/_typography.scss +3 -187
  504. data/node_modules/govuk-frontend/dist/govuk/custom-properties/_breakpoints.import.scss +8 -0
  505. data/node_modules/govuk-frontend/dist/govuk/custom-properties/_breakpoints.mixin.scss +15 -0
  506. data/node_modules/govuk-frontend/dist/govuk/custom-properties/_breakpoints.scss +4 -0
  507. data/node_modules/govuk-frontend/dist/govuk/custom-properties/_frontend-version.import.scss +8 -0
  508. data/node_modules/govuk-frontend/dist/govuk/custom-properties/_frontend-version.mixin.scss +13 -0
  509. data/node_modules/govuk-frontend/dist/govuk/custom-properties/_frontend-version.scss +4 -0
  510. data/node_modules/govuk-frontend/dist/govuk/custom-properties/_functional-colours.import.scss +8 -0
  511. data/node_modules/govuk-frontend/dist/govuk/custom-properties/_functional-colours.mixin.scss +22 -0
  512. data/node_modules/govuk-frontend/dist/govuk/custom-properties/_functional-colours.scss +4 -0
  513. data/node_modules/govuk-frontend/dist/govuk/custom-properties/_index.import.scss +4 -0
  514. data/node_modules/govuk-frontend/dist/govuk/custom-properties/_index.scss +4 -0
  515. data/node_modules/govuk-frontend/dist/govuk/errors/index.mjs +12 -7
  516. data/node_modules/govuk-frontend/dist/govuk/errors/index.mjs.map +1 -1
  517. data/node_modules/govuk-frontend/dist/govuk/govuk-frontend.min.css +2 -2
  518. data/node_modules/govuk-frontend/dist/govuk/govuk-frontend.min.css.map +1 -1
  519. data/node_modules/govuk-frontend/dist/govuk/govuk-frontend.min.js +1 -1
  520. data/node_modules/govuk-frontend/dist/govuk/govuk-frontend.min.js.map +1 -1
  521. data/node_modules/govuk-frontend/dist/govuk/helpers/_clearfix.import.scss +2 -0
  522. data/node_modules/govuk-frontend/dist/govuk/helpers/_clearfix.scss +0 -1
  523. data/node_modules/govuk-frontend/dist/govuk/helpers/_colour.import.scss +2 -0
  524. data/node_modules/govuk-frontend/dist/govuk/helpers/_colour.scss +190 -89
  525. data/node_modules/govuk-frontend/dist/govuk/helpers/_device-pixels.import.scss +2 -0
  526. data/node_modules/govuk-frontend/dist/govuk/helpers/_device-pixels.scss +2 -1
  527. data/node_modules/govuk-frontend/dist/govuk/helpers/_focused.import.scss +2 -0
  528. data/node_modules/govuk-frontend/dist/govuk/helpers/_focused.scss +44 -7
  529. data/node_modules/govuk-frontend/dist/govuk/helpers/_font-faces--internal.scss +41 -0
  530. data/node_modules/govuk-frontend/dist/govuk/helpers/_grid.import.scss +2 -0
  531. data/node_modules/govuk-frontend/dist/govuk/helpers/_grid.scss +7 -4
  532. data/node_modules/govuk-frontend/dist/govuk/helpers/_index.import.scss +2 -0
  533. data/node_modules/govuk-frontend/dist/govuk/helpers/_index.scss +12 -13
  534. data/node_modules/govuk-frontend/dist/govuk/helpers/_links.import.scss +2 -0
  535. data/node_modules/govuk-frontend/dist/govuk/helpers/_links.scss +35 -46
  536. data/node_modules/govuk-frontend/dist/govuk/helpers/_media-queries.import.scss +2 -0
  537. data/node_modules/govuk-frontend/dist/govuk/helpers/_media-queries.scss +174 -34
  538. data/node_modules/govuk-frontend/dist/govuk/helpers/_shape-arrow.import.scss +2 -0
  539. data/node_modules/govuk-frontend/dist/govuk/helpers/_shape-arrow.scss +2 -3
  540. data/node_modules/govuk-frontend/dist/govuk/helpers/_spacing--internal.scss +80 -0
  541. data/node_modules/govuk-frontend/dist/govuk/helpers/_spacing.import.scss +2 -0
  542. data/node_modules/govuk-frontend/dist/govuk/helpers/_spacing.scss +27 -82
  543. data/node_modules/govuk-frontend/dist/govuk/helpers/_typography--internal.scss +24 -0
  544. data/node_modules/govuk-frontend/dist/govuk/helpers/_typography.import.scss +2 -0
  545. data/node_modules/govuk-frontend/dist/govuk/helpers/_typography.scss +55 -74
  546. data/node_modules/govuk-frontend/dist/govuk/helpers/_visually-hidden.import.scss +2 -0
  547. data/node_modules/govuk-frontend/dist/govuk/helpers/_visually-hidden.scss +17 -13
  548. data/node_modules/govuk-frontend/dist/govuk/helpers/_width-container.import.scss +2 -0
  549. data/node_modules/govuk-frontend/dist/govuk/helpers/_width-container.scss +73 -0
  550. data/node_modules/govuk-frontend/dist/govuk/i18n.mjs +5 -128
  551. data/node_modules/govuk-frontend/dist/govuk/i18n.mjs.map +1 -1
  552. data/node_modules/govuk-frontend/dist/govuk/index.import.scss +10 -0
  553. data/node_modules/govuk-frontend/dist/govuk/index.scss +6 -7
  554. data/node_modules/govuk-frontend/dist/govuk/init.mjs +61 -53
  555. data/node_modules/govuk-frontend/dist/govuk/init.mjs.map +1 -1
  556. data/node_modules/govuk-frontend/dist/govuk/macros/attributes.njk +30 -14
  557. data/node_modules/govuk-frontend/dist/govuk/macros/logo.njk +7 -29
  558. data/node_modules/govuk-frontend/dist/govuk/objects/_button-group.import.scss +8 -0
  559. data/node_modules/govuk-frontend/dist/govuk/objects/_button-group.mixin.scss +80 -0
  560. data/node_modules/govuk-frontend/dist/govuk/objects/_button-group.scss +3 -78
  561. data/node_modules/govuk-frontend/dist/govuk/objects/_form-group.import.scss +8 -0
  562. data/node_modules/govuk-frontend/dist/govuk/objects/_form-group.mixin.scss +26 -0
  563. data/node_modules/govuk-frontend/dist/govuk/objects/_form-group.scss +3 -23
  564. data/node_modules/govuk-frontend/dist/govuk/objects/_grid.import.scss +8 -0
  565. data/node_modules/govuk-frontend/dist/govuk/objects/_grid.mixin.scss +28 -0
  566. data/node_modules/govuk-frontend/dist/govuk/objects/_grid.scss +3 -24
  567. data/node_modules/govuk-frontend/dist/govuk/objects/_index.import.scss +7 -0
  568. data/node_modules/govuk-frontend/dist/govuk/objects/_index.scss +6 -7
  569. data/node_modules/govuk-frontend/dist/govuk/objects/_main-wrapper.import.scss +8 -0
  570. data/node_modules/govuk-frontend/dist/govuk/objects/_main-wrapper.mixin.scss +55 -0
  571. data/node_modules/govuk-frontend/dist/govuk/objects/_main-wrapper.scss +3 -53
  572. data/node_modules/govuk-frontend/dist/govuk/objects/_template.import.scss +8 -0
  573. data/node_modules/govuk-frontend/dist/govuk/objects/_template.mixin.scss +53 -0
  574. data/node_modules/govuk-frontend/dist/govuk/objects/_template.scss +3 -55
  575. data/node_modules/govuk-frontend/dist/govuk/objects/_width-container.import.scss +8 -0
  576. data/node_modules/govuk-frontend/dist/govuk/objects/_width-container.mixin.scss +9 -0
  577. data/node_modules/govuk-frontend/dist/govuk/objects/_width-container.scss +3 -75
  578. data/node_modules/govuk-frontend/dist/govuk/overrides/_display.import.scss +8 -0
  579. data/node_modules/govuk-frontend/dist/govuk/overrides/_display.mixin.scss +26 -0
  580. data/node_modules/govuk-frontend/dist/govuk/overrides/_display.scss +2 -24
  581. data/node_modules/govuk-frontend/dist/govuk/overrides/_index.import.scss +6 -0
  582. data/node_modules/govuk-frontend/dist/govuk/overrides/_index.scss +5 -6
  583. data/node_modules/govuk-frontend/dist/govuk/overrides/_spacing.import.scss +8 -0
  584. data/node_modules/govuk-frontend/dist/govuk/overrides/_spacing.mixin.scss +89 -0
  585. data/node_modules/govuk-frontend/dist/govuk/overrides/_spacing.scss +2 -84
  586. data/node_modules/govuk-frontend/dist/govuk/overrides/_text-align.import.scss +8 -0
  587. data/node_modules/govuk-frontend/dist/govuk/overrides/_text-align.mixin.scss +16 -0
  588. data/node_modules/govuk-frontend/dist/govuk/overrides/_text-align.scss +2 -14
  589. data/node_modules/govuk-frontend/dist/govuk/overrides/_typography.import.scss +8 -0
  590. data/node_modules/govuk-frontend/dist/govuk/overrides/_typography.mixin.scss +43 -0
  591. data/node_modules/govuk-frontend/dist/govuk/overrides/_typography.scss +2 -40
  592. data/node_modules/govuk-frontend/dist/govuk/overrides/_width.import.scss +8 -0
  593. data/node_modules/govuk-frontend/dist/govuk/overrides/_width.mixin.scss +50 -0
  594. data/node_modules/govuk-frontend/dist/govuk/overrides/_width.scss +2 -46
  595. data/node_modules/govuk-frontend/dist/govuk/settings/_assets.import.scss +13 -0
  596. data/node_modules/govuk-frontend/dist/govuk/settings/_assets.scss +50 -21
  597. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-applied.import.scss +13 -0
  598. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-functional.import.scss +2 -0
  599. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-functional.scss +168 -0
  600. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-legacy-functional.import.scss +2 -0
  601. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-legacy-functional.scss +188 -0
  602. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-organisations.import.scss +2 -0
  603. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-organisations.scss +23 -274
  604. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-palette--internal.scss +128 -0
  605. data/node_modules/govuk-frontend/dist/govuk/settings/_custom-properties.import.scss +2 -0
  606. data/node_modules/govuk-frontend/dist/govuk/settings/_custom-properties.scss +17 -0
  607. data/node_modules/govuk-frontend/dist/govuk/settings/_global-styles.import.scss +2 -0
  608. data/node_modules/govuk-frontend/dist/govuk/settings/_global-styles.scss +0 -1
  609. data/node_modules/govuk-frontend/dist/govuk/settings/_index.import.scss +24 -0
  610. data/node_modules/govuk-frontend/dist/govuk/settings/_index.scss +14 -13
  611. data/node_modules/govuk-frontend/dist/govuk/settings/_links.import.scss +2 -0
  612. data/node_modules/govuk-frontend/dist/govuk/settings/_links.scss +3 -3
  613. data/node_modules/govuk-frontend/dist/govuk/settings/_measurements.import.scss +2 -0
  614. data/node_modules/govuk-frontend/dist/govuk/settings/_measurements.scss +8 -17
  615. data/node_modules/govuk-frontend/dist/govuk/settings/_media-queries.import.scss +2 -0
  616. data/node_modules/govuk-frontend/dist/govuk/settings/_media-queries.scss +0 -10
  617. data/node_modules/govuk-frontend/dist/govuk/settings/_spacing.import.scss +2 -0
  618. data/node_modules/govuk-frontend/dist/govuk/settings/_spacing.scss +0 -1
  619. data/node_modules/govuk-frontend/dist/govuk/settings/_typography-font.import.scss +2 -0
  620. data/node_modules/govuk-frontend/dist/govuk/settings/_typography-font.scss +3 -2
  621. data/node_modules/govuk-frontend/dist/govuk/settings/_typography-responsive.import.scss +2 -0
  622. data/node_modules/govuk-frontend/dist/govuk/settings/_typography-responsive.scss +12 -190
  623. data/node_modules/govuk-frontend/dist/govuk/settings/_warnings--internal.scss +69 -0
  624. data/node_modules/govuk-frontend/dist/govuk/settings/_warnings.import.scss +2 -0
  625. data/node_modules/govuk-frontend/dist/govuk/settings/_warnings.scss +9 -56
  626. data/node_modules/govuk-frontend/dist/govuk/template.njk +61 -23
  627. data/node_modules/govuk-frontend/dist/govuk/tools/_exports.import.scss +2 -0
  628. data/node_modules/govuk-frontend/dist/govuk/tools/_exports.scss +12 -6
  629. data/node_modules/govuk-frontend/dist/govuk/tools/_font-url.import.scss +31 -0
  630. data/node_modules/govuk-frontend/dist/govuk/tools/_font-url.scss +22 -6
  631. data/node_modules/govuk-frontend/dist/govuk/tools/_if.import.scss +2 -0
  632. data/node_modules/govuk-frontend/dist/govuk/tools/_if.scss +23 -0
  633. data/node_modules/govuk-frontend/dist/govuk/tools/_image-url.import.scss +31 -0
  634. data/node_modules/govuk-frontend/dist/govuk/tools/_image-url.scss +22 -6
  635. data/node_modules/govuk-frontend/dist/govuk/tools/_index.import.scss +2 -0
  636. data/node_modules/govuk-frontend/dist/govuk/tools/_index.scss +6 -7
  637. data/node_modules/govuk-frontend/dist/govuk/tools/_px-to-em.import.scss +2 -0
  638. data/node_modules/govuk-frontend/dist/govuk/tools/_px-to-em.scss +9 -6
  639. data/node_modules/govuk-frontend/dist/govuk/tools/_px-to-rem.import.scss +2 -0
  640. data/node_modules/govuk-frontend/dist/govuk/tools/_px-to-rem.scss +6 -3
  641. data/node_modules/govuk-frontend/dist/govuk/utilities/_clearfix.import.scss +8 -0
  642. data/node_modules/govuk-frontend/dist/govuk/utilities/_clearfix.mixin.scss +10 -0
  643. data/node_modules/govuk-frontend/dist/govuk/utilities/_clearfix.scss +3 -6
  644. data/node_modules/govuk-frontend/dist/govuk/utilities/_index.import.scss +3 -0
  645. data/node_modules/govuk-frontend/dist/govuk/utilities/_index.scss +2 -3
  646. data/node_modules/govuk-frontend/dist/govuk/utilities/_visually-hidden.import.scss +8 -0
  647. data/node_modules/govuk-frontend/dist/govuk/utilities/_visually-hidden.mixin.scss +14 -0
  648. data/node_modules/govuk-frontend/dist/govuk/utilities/_visually-hidden.scss +2 -9
  649. data/node_modules/govuk-frontend/dist/govuk-prototype-kit/init.scss +4 -3
  650. data/node_modules/govuk-frontend/govuk-prototype-kit.config.json +13 -4
  651. data/node_modules/govuk-frontend/package.json +29 -22
  652. data/vendor/assets/assets/images/favicon.ico +0 -0
  653. data/vendor/assets/assets/images/favicon.svg +1 -1
  654. data/vendor/assets/assets/images/govuk-icon-180.png +0 -0
  655. data/vendor/assets/assets/images/govuk-icon-192.png +0 -0
  656. data/vendor/assets/assets/images/govuk-icon-512.png +0 -0
  657. data/vendor/assets/assets/images/govuk-opengraph-image.png +0 -0
  658. data/vendor/assets/assets/manifest.json.erb +39 -0
  659. data/vendor/assets/images/favicon.ico +0 -0
  660. data/vendor/assets/images/favicon.svg +1 -1
  661. data/vendor/assets/images/govuk-icon-180.png +0 -0
  662. data/vendor/assets/images/govuk-icon-192.png +0 -0
  663. data/vendor/assets/images/govuk-icon-512.png +0 -0
  664. data/vendor/assets/images/govuk-opengraph-image.png +0 -0
  665. data/vendor/assets/javascripts/defra_ruby_template.js +407 -453
  666. data/vendor/assets/javascripts/defra_ruby_template_supported.js +4 -0
  667. data/vendor/assets/stylesheets/_base.import.scss +6 -0
  668. data/vendor/assets/stylesheets/_base.scss +4 -4
  669. data/vendor/assets/stylesheets/components/_index.import.scss +40 -0
  670. data/vendor/assets/stylesheets/components/_index.scss +39 -39
  671. data/vendor/assets/stylesheets/components/accordion/_accordion.import.scss +6 -0
  672. data/vendor/assets/stylesheets/components/accordion/_index.import.scss +8 -0
  673. data/vendor/assets/stylesheets/components/accordion/_index.scss +3 -368
  674. data/vendor/assets/stylesheets/components/accordion/_mixin.scss +375 -0
  675. data/vendor/assets/stylesheets/components/back-link/_back-link.import.scss +6 -0
  676. data/vendor/assets/stylesheets/components/back-link/_index.import.scss +8 -0
  677. data/vendor/assets/stylesheets/components/back-link/_index.scss +3 -81
  678. data/vendor/assets/stylesheets/components/back-link/_mixin.scss +87 -0
  679. data/vendor/assets/stylesheets/components/breadcrumbs/_breadcrumbs.import.scss +6 -0
  680. data/vendor/assets/stylesheets/components/breadcrumbs/_index.import.scss +8 -0
  681. data/vendor/assets/stylesheets/components/breadcrumbs/_index.scss +3 -132
  682. data/vendor/assets/stylesheets/components/breadcrumbs/_mixin.scss +134 -0
  683. data/vendor/assets/stylesheets/components/button/_button.import.scss +6 -0
  684. data/vendor/assets/stylesheets/components/button/_index.import.scss +13 -0
  685. data/vendor/assets/stylesheets/components/button/_index.scss +9 -260
  686. data/vendor/assets/stylesheets/components/button/_mixin.scss +233 -0
  687. data/vendor/assets/stylesheets/components/button/_settings.import.scss +32 -0
  688. data/vendor/assets/stylesheets/components/button/_settings.scss +34 -0
  689. data/vendor/assets/stylesheets/components/character-count/_character-count.import.scss +6 -0
  690. data/vendor/assets/stylesheets/components/character-count/_index.import.scss +12 -0
  691. data/vendor/assets/stylesheets/components/character-count/_index.scss +7 -42
  692. data/vendor/assets/stylesheets/components/character-count/_mixin.scss +41 -0
  693. data/vendor/assets/stylesheets/components/checkboxes/_checkboxes.import.scss +6 -0
  694. data/vendor/assets/stylesheets/components/checkboxes/_index.import.scss +12 -0
  695. data/vendor/assets/stylesheets/components/checkboxes/_index.scss +7 -309
  696. data/vendor/assets/stylesheets/components/checkboxes/_mixin.scss +317 -0
  697. data/vendor/assets/stylesheets/components/cookie-banner/_cookie-banner.import.scss +6 -0
  698. data/vendor/assets/stylesheets/components/cookie-banner/_index.import.scss +9 -0
  699. data/vendor/assets/stylesheets/components/cookie-banner/_index.scss +4 -56
  700. data/vendor/assets/stylesheets/components/cookie-banner/_mixin.scss +62 -0
  701. data/vendor/assets/stylesheets/components/date-input/_date-input.import.scss +6 -0
  702. data/vendor/assets/stylesheets/components/date-input/_index.import.scss +13 -0
  703. data/vendor/assets/stylesheets/components/date-input/_index.scss +8 -26
  704. data/vendor/assets/stylesheets/components/date-input/_mixin.scss +29 -0
  705. data/vendor/assets/stylesheets/components/details/_details.import.scss +6 -0
  706. data/vendor/assets/stylesheets/components/details/_index.import.scss +8 -0
  707. data/vendor/assets/stylesheets/components/details/_index.scss +3 -137
  708. data/vendor/assets/stylesheets/components/details/_mixin.scss +143 -0
  709. data/vendor/assets/stylesheets/components/error-message/_error-message.import.scss +6 -0
  710. data/vendor/assets/stylesheets/components/error-message/_index.import.scss +8 -0
  711. data/vendor/assets/stylesheets/components/error-message/_index.scss +3 -12
  712. data/vendor/assets/stylesheets/components/error-message/_mixin.scss +16 -0
  713. data/vendor/assets/stylesheets/components/error-summary/_error-summary.import.scss +6 -0
  714. data/vendor/assets/stylesheets/components/error-summary/_index.import.scss +8 -0
  715. data/vendor/assets/stylesheets/components/error-summary/_index.scss +3 -53
  716. data/vendor/assets/stylesheets/components/error-summary/_mixin.scss +58 -0
  717. data/vendor/assets/stylesheets/components/exit-this-page/_exit-this-page.import.scss +6 -0
  718. data/vendor/assets/stylesheets/components/exit-this-page/_index.import.scss +9 -0
  719. data/vendor/assets/stylesheets/components/exit-this-page/_index.scss +4 -89
  720. data/vendor/assets/stylesheets/components/exit-this-page/_mixin.scss +96 -0
  721. data/vendor/assets/stylesheets/components/feedback/_feedback.import.scss +6 -0
  722. data/vendor/assets/stylesheets/components/feedback/_index.import.scss +8 -0
  723. data/vendor/assets/stylesheets/components/feedback/_index.scss +5 -0
  724. data/vendor/assets/stylesheets/components/feedback/_mixin.scss +48 -0
  725. data/vendor/assets/stylesheets/components/fieldset/_fieldset.import.scss +6 -0
  726. data/vendor/assets/stylesheets/components/fieldset/_index.import.scss +8 -0
  727. data/vendor/assets/stylesheets/components/fieldset/_index.scss +3 -67
  728. data/vendor/assets/stylesheets/components/fieldset/_mixin.scss +71 -0
  729. data/vendor/assets/stylesheets/components/file-upload/_file-upload.import.scss +6 -0
  730. data/vendor/assets/stylesheets/components/file-upload/_index.import.scss +11 -0
  731. data/vendor/assets/stylesheets/components/file-upload/_index.scss +6 -216
  732. data/vendor/assets/stylesheets/components/file-upload/_mixin.scss +217 -0
  733. data/vendor/assets/stylesheets/components/footer/_footer.import.scss +6 -0
  734. data/vendor/assets/stylesheets/components/footer/_index.import.scss +8 -0
  735. data/vendor/assets/stylesheets/components/footer/_index.scss +3 -192
  736. data/vendor/assets/stylesheets/components/footer/_mixin.scss +205 -0
  737. data/vendor/assets/stylesheets/components/generic-header/_generic-header.import.scss +6 -0
  738. data/vendor/assets/stylesheets/components/generic-header/_index.import.scss +8 -0
  739. data/vendor/assets/stylesheets/components/generic-header/_index.scss +5 -0
  740. data/vendor/assets/stylesheets/components/generic-header/_mixin.scss +140 -0
  741. data/vendor/assets/stylesheets/components/header/_header.import.scss +6 -0
  742. data/vendor/assets/stylesheets/components/header/_index.import.scss +8 -0
  743. data/vendor/assets/stylesheets/components/header/_index.scss +3 -546
  744. data/vendor/assets/stylesheets/components/header/_mixin.scss +119 -0
  745. data/vendor/assets/stylesheets/components/hint/_hint.import.scss +6 -0
  746. data/vendor/assets/stylesheets/components/hint/_index.import.scss +8 -0
  747. data/vendor/assets/stylesheets/components/hint/_index.scss +3 -43
  748. data/vendor/assets/stylesheets/components/hint/_mixin.scss +47 -0
  749. data/vendor/assets/stylesheets/components/input/_index.import.scss +11 -0
  750. data/vendor/assets/stylesheets/components/input/_index.scss +6 -166
  751. data/vendor/assets/stylesheets/components/input/_input.import.scss +6 -0
  752. data/vendor/assets/stylesheets/components/input/_mixin.scss +161 -0
  753. data/vendor/assets/stylesheets/components/inset-text/_index.import.scss +8 -0
  754. data/vendor/assets/stylesheets/components/inset-text/_index.scss +3 -24
  755. data/vendor/assets/stylesheets/components/inset-text/_inset-text.import.scss +6 -0
  756. data/vendor/assets/stylesheets/components/inset-text/_mixin.scss +31 -0
  757. data/vendor/assets/stylesheets/components/label/_index.import.scss +8 -0
  758. data/vendor/assets/stylesheets/components/label/_index.scss +3 -44
  759. data/vendor/assets/stylesheets/components/label/_label.import.scss +6 -0
  760. data/vendor/assets/stylesheets/components/label/_mixin.scss +48 -0
  761. data/vendor/assets/stylesheets/components/language-navigation/_index.import.scss +8 -0
  762. data/vendor/assets/stylesheets/components/language-navigation/_index.scss +6 -0
  763. data/vendor/assets/stylesheets/components/language-navigation/_language-navigation.import.scss +6 -0
  764. data/vendor/assets/stylesheets/components/language-navigation/_mixin.scss +68 -0
  765. data/vendor/assets/stylesheets/components/notification-banner/_index.import.scss +8 -0
  766. data/vendor/assets/stylesheets/components/notification-banner/_index.scss +3 -91
  767. data/vendor/assets/stylesheets/components/notification-banner/_mixin.scss +100 -0
  768. data/vendor/assets/stylesheets/components/notification-banner/_notification-banner.import.scss +6 -0
  769. data/vendor/assets/stylesheets/components/pagination/_index.import.scss +8 -0
  770. data/vendor/assets/stylesheets/components/pagination/_index.scss +3 -226
  771. data/vendor/assets/stylesheets/components/pagination/_mixin.scss +235 -0
  772. data/vendor/assets/stylesheets/components/pagination/_pagination.import.scss +6 -0
  773. data/vendor/assets/stylesheets/components/panel/_index.import.scss +8 -0
  774. data/vendor/assets/stylesheets/components/panel/_index.scss +3 -56
  775. data/vendor/assets/stylesheets/components/panel/_mixin.scss +94 -0
  776. data/vendor/assets/stylesheets/components/panel/_panel.import.scss +6 -0
  777. data/vendor/assets/stylesheets/components/password-input/_index.import.scss +10 -0
  778. data/vendor/assets/stylesheets/components/password-input/_index.scss +5 -54
  779. data/vendor/assets/stylesheets/components/password-input/_mixin.scss +56 -0
  780. data/vendor/assets/stylesheets/components/password-input/_password-input.import.scss +6 -0
  781. data/vendor/assets/stylesheets/components/phase-banner/_index.import.scss +9 -0
  782. data/vendor/assets/stylesheets/components/phase-banner/_index.scss +4 -33
  783. data/vendor/assets/stylesheets/components/phase-banner/_mixin.scss +42 -0
  784. data/vendor/assets/stylesheets/components/phase-banner/_phase-banner.import.scss +6 -0
  785. data/vendor/assets/stylesheets/components/radios/_index.import.scss +12 -0
  786. data/vendor/assets/stylesheets/components/radios/_index.scss +7 -325
  787. data/vendor/assets/stylesheets/components/radios/_mixin.scss +336 -0
  788. data/vendor/assets/stylesheets/components/radios/_radios.import.scss +6 -0
  789. data/vendor/assets/stylesheets/components/select/_index.import.scss +11 -0
  790. data/vendor/assets/stylesheets/components/select/_index.scss +6 -56
  791. data/vendor/assets/stylesheets/components/select/_mixin.scss +45 -0
  792. data/vendor/assets/stylesheets/components/select/_select.import.scss +6 -0
  793. data/vendor/assets/stylesheets/components/service-navigation/_index.import.scss +8 -0
  794. data/vendor/assets/stylesheets/components/service-navigation/_index.scss +3 -185
  795. data/vendor/assets/stylesheets/components/service-navigation/_mixin.scss +283 -0
  796. data/vendor/assets/stylesheets/components/service-navigation/_service-navigation.import.scss +6 -0
  797. data/vendor/assets/stylesheets/components/skip-link/_index.import.scss +8 -0
  798. data/vendor/assets/stylesheets/components/skip-link/_index.scss +3 -50
  799. data/vendor/assets/stylesheets/components/skip-link/_mixin.scss +60 -0
  800. data/vendor/assets/stylesheets/components/skip-link/_skip-link.import.scss +6 -0
  801. data/vendor/assets/stylesheets/components/summary-list/_index.import.scss +8 -0
  802. data/vendor/assets/stylesheets/components/summary-list/_index.scss +3 -267
  803. data/vendor/assets/stylesheets/components/summary-list/_mixin.scss +286 -0
  804. data/vendor/assets/stylesheets/components/summary-list/_summary-list.import.scss +6 -0
  805. data/vendor/assets/stylesheets/components/table/_index.import.scss +8 -0
  806. data/vendor/assets/stylesheets/components/table/_index.scss +3 -73
  807. data/vendor/assets/stylesheets/components/table/_mixin.scss +77 -0
  808. data/vendor/assets/stylesheets/components/table/_table.import.scss +6 -0
  809. data/vendor/assets/stylesheets/components/tabs/_index.import.scss +8 -0
  810. data/vendor/assets/stylesheets/components/tabs/_index.scss +3 -132
  811. data/vendor/assets/stylesheets/components/tabs/_mixin.scss +140 -0
  812. data/vendor/assets/stylesheets/components/tabs/_tabs.import.scss +6 -0
  813. data/vendor/assets/stylesheets/components/tag/_index.import.scss +8 -0
  814. data/vendor/assets/stylesheets/components/tag/_index.scss +3 -94
  815. data/vendor/assets/stylesheets/components/tag/_mixin.scss +135 -0
  816. data/vendor/assets/stylesheets/components/tag/_tag.import.scss +6 -0
  817. data/vendor/assets/stylesheets/components/task-list/_index.import.scss +9 -0
  818. data/vendor/assets/stylesheets/components/task-list/_index.scss +4 -76
  819. data/vendor/assets/stylesheets/components/task-list/_mixin.scss +83 -0
  820. data/vendor/assets/stylesheets/components/task-list/_task-list.import.scss +6 -0
  821. data/vendor/assets/stylesheets/components/textarea/_index.import.scss +11 -0
  822. data/vendor/assets/stylesheets/components/textarea/_index.scss +6 -47
  823. data/vendor/assets/stylesheets/components/textarea/_mixin.scss +43 -0
  824. data/vendor/assets/stylesheets/components/textarea/_textarea.import.scss +6 -0
  825. data/vendor/assets/stylesheets/components/warning-text/_index.import.scss +8 -0
  826. data/vendor/assets/stylesheets/components/warning-text/_index.scss +3 -64
  827. data/vendor/assets/stylesheets/components/warning-text/_mixin.scss +69 -0
  828. data/vendor/assets/stylesheets/components/warning-text/_warning-text.import.scss +6 -0
  829. data/vendor/assets/stylesheets/core/_global-styles.import.scss +10 -0
  830. data/vendor/assets/stylesheets/core/_global-styles.mixin.scss +19 -0
  831. data/vendor/assets/stylesheets/core/_global-styles.scss +5 -18
  832. data/vendor/assets/stylesheets/core/_index.import.scss +6 -0
  833. data/vendor/assets/stylesheets/core/_index.scss +6 -7
  834. data/vendor/assets/stylesheets/core/_links.import.scss +10 -0
  835. data/vendor/assets/stylesheets/core/_links.mixin.scss +44 -0
  836. data/vendor/assets/stylesheets/core/_links.scss +3 -40
  837. data/vendor/assets/stylesheets/core/_lists.import.scss +14 -0
  838. data/vendor/assets/stylesheets/core/_lists.mixin.scss +74 -0
  839. data/vendor/assets/stylesheets/core/_lists.scss +6 -64
  840. data/vendor/assets/stylesheets/core/_section-break.import.scss +8 -0
  841. data/vendor/assets/stylesheets/core/_section-break.mixin.scss +54 -0
  842. data/vendor/assets/stylesheets/core/_section-break.scss +3 -49
  843. data/vendor/assets/stylesheets/core/_typography.import.scss +8 -0
  844. data/vendor/assets/stylesheets/core/_typography.mixin.scss +173 -0
  845. data/vendor/assets/stylesheets/core/_typography.scss +3 -187
  846. data/vendor/assets/stylesheets/custom-properties/_breakpoints.import.scss +8 -0
  847. data/vendor/assets/stylesheets/custom-properties/_breakpoints.mixin.scss +15 -0
  848. data/vendor/assets/stylesheets/custom-properties/_breakpoints.scss +4 -0
  849. data/vendor/assets/stylesheets/custom-properties/_frontend-version.import.scss +8 -0
  850. data/vendor/assets/stylesheets/custom-properties/_frontend-version.mixin.scss +13 -0
  851. data/vendor/assets/stylesheets/custom-properties/_frontend-version.scss +4 -0
  852. data/vendor/assets/stylesheets/custom-properties/_functional-colours.import.scss +8 -0
  853. data/vendor/assets/stylesheets/custom-properties/_functional-colours.mixin.scss +22 -0
  854. data/vendor/assets/stylesheets/custom-properties/_functional-colours.scss +4 -0
  855. data/vendor/assets/stylesheets/custom-properties/_index.import.scss +4 -0
  856. data/vendor/assets/stylesheets/custom-properties/_index.scss +4 -0
  857. data/vendor/assets/stylesheets/defra_ruby_template.scss +8 -11
  858. data/vendor/assets/stylesheets/govuk-frontend.min.css +2 -2
  859. data/vendor/assets/stylesheets/helpers/_clearfix.import.scss +2 -0
  860. data/vendor/assets/stylesheets/helpers/_clearfix.scss +0 -1
  861. data/vendor/assets/stylesheets/helpers/_colour.import.scss +2 -0
  862. data/vendor/assets/stylesheets/helpers/_colour.scss +190 -89
  863. data/vendor/assets/stylesheets/helpers/_device-pixels.import.scss +2 -0
  864. data/vendor/assets/stylesheets/helpers/_device-pixels.scss +2 -1
  865. data/vendor/assets/stylesheets/helpers/_focused.import.scss +2 -0
  866. data/vendor/assets/stylesheets/helpers/_focused.scss +44 -7
  867. data/vendor/assets/stylesheets/helpers/_font-faces--internal.scss +41 -0
  868. data/vendor/assets/stylesheets/helpers/_grid.import.scss +2 -0
  869. data/vendor/assets/stylesheets/helpers/_grid.scss +7 -4
  870. data/vendor/assets/stylesheets/helpers/_index.import.scss +2 -0
  871. data/vendor/assets/stylesheets/helpers/_index.scss +12 -13
  872. data/vendor/assets/stylesheets/helpers/_links.import.scss +2 -0
  873. data/vendor/assets/stylesheets/helpers/_links.scss +35 -46
  874. data/vendor/assets/stylesheets/helpers/_media-queries.import.scss +2 -0
  875. data/vendor/assets/stylesheets/helpers/_media-queries.scss +174 -34
  876. data/vendor/assets/stylesheets/helpers/_shape-arrow.import.scss +2 -0
  877. data/vendor/assets/stylesheets/helpers/_shape-arrow.scss +2 -3
  878. data/vendor/assets/stylesheets/helpers/_spacing--internal.scss +80 -0
  879. data/vendor/assets/stylesheets/helpers/_spacing.import.scss +2 -0
  880. data/vendor/assets/stylesheets/helpers/_spacing.scss +27 -82
  881. data/vendor/assets/stylesheets/helpers/_typography--internal.scss +24 -0
  882. data/vendor/assets/stylesheets/helpers/_typography.import.scss +2 -0
  883. data/vendor/assets/stylesheets/helpers/_typography.scss +55 -74
  884. data/vendor/assets/stylesheets/helpers/_visually-hidden.import.scss +2 -0
  885. data/vendor/assets/stylesheets/helpers/_visually-hidden.scss +17 -13
  886. data/vendor/assets/stylesheets/helpers/_width-container.import.scss +2 -0
  887. data/vendor/assets/stylesheets/helpers/_width-container.scss +73 -0
  888. data/vendor/assets/stylesheets/index.import.scss +10 -0
  889. data/vendor/assets/stylesheets/index.scss +6 -7
  890. data/vendor/assets/stylesheets/objects/_button-group.import.scss +8 -0
  891. data/vendor/assets/stylesheets/objects/_button-group.mixin.scss +80 -0
  892. data/vendor/assets/stylesheets/objects/_button-group.scss +3 -78
  893. data/vendor/assets/stylesheets/objects/_form-group.import.scss +8 -0
  894. data/vendor/assets/stylesheets/objects/_form-group.mixin.scss +26 -0
  895. data/vendor/assets/stylesheets/objects/_form-group.scss +3 -23
  896. data/vendor/assets/stylesheets/objects/_grid.import.scss +8 -0
  897. data/vendor/assets/stylesheets/objects/_grid.mixin.scss +28 -0
  898. data/vendor/assets/stylesheets/objects/_grid.scss +3 -24
  899. data/vendor/assets/stylesheets/objects/_index.import.scss +7 -0
  900. data/vendor/assets/stylesheets/objects/_index.scss +6 -7
  901. data/vendor/assets/stylesheets/objects/_main-wrapper.import.scss +8 -0
  902. data/vendor/assets/stylesheets/objects/_main-wrapper.mixin.scss +55 -0
  903. data/vendor/assets/stylesheets/objects/_main-wrapper.scss +3 -53
  904. data/vendor/assets/stylesheets/objects/_template.import.scss +8 -0
  905. data/vendor/assets/stylesheets/objects/_template.mixin.scss +53 -0
  906. data/vendor/assets/stylesheets/objects/_template.scss +3 -55
  907. data/vendor/assets/stylesheets/objects/_width-container.import.scss +8 -0
  908. data/vendor/assets/stylesheets/objects/_width-container.mixin.scss +9 -0
  909. data/vendor/assets/stylesheets/objects/_width-container.scss +3 -75
  910. data/vendor/assets/stylesheets/overrides/_display.import.scss +8 -0
  911. data/vendor/assets/stylesheets/overrides/_display.mixin.scss +26 -0
  912. data/vendor/assets/stylesheets/overrides/_display.scss +2 -24
  913. data/vendor/assets/stylesheets/overrides/_index.import.scss +6 -0
  914. data/vendor/assets/stylesheets/overrides/_index.scss +5 -6
  915. data/vendor/assets/stylesheets/overrides/_spacing.import.scss +8 -0
  916. data/vendor/assets/stylesheets/overrides/_spacing.mixin.scss +89 -0
  917. data/vendor/assets/stylesheets/overrides/_spacing.scss +2 -84
  918. data/vendor/assets/stylesheets/overrides/_text-align.import.scss +8 -0
  919. data/vendor/assets/stylesheets/overrides/_text-align.mixin.scss +16 -0
  920. data/vendor/assets/stylesheets/overrides/_text-align.scss +2 -14
  921. data/vendor/assets/stylesheets/overrides/_typography.import.scss +8 -0
  922. data/vendor/assets/stylesheets/overrides/_typography.mixin.scss +43 -0
  923. data/vendor/assets/stylesheets/overrides/_typography.scss +2 -40
  924. data/vendor/assets/stylesheets/overrides/_width.import.scss +8 -0
  925. data/vendor/assets/stylesheets/overrides/_width.mixin.scss +50 -0
  926. data/vendor/assets/stylesheets/overrides/_width.scss +2 -46
  927. data/vendor/assets/stylesheets/settings/_assets.import.scss +13 -0
  928. data/vendor/assets/stylesheets/settings/_assets.scss +50 -21
  929. data/vendor/assets/stylesheets/settings/_colours-applied.import.scss +13 -0
  930. data/vendor/assets/stylesheets/settings/_colours-functional.import.scss +2 -0
  931. data/vendor/assets/stylesheets/settings/_colours-functional.scss +168 -0
  932. data/vendor/assets/stylesheets/settings/_colours-legacy-functional.import.scss +2 -0
  933. data/vendor/assets/stylesheets/settings/_colours-legacy-functional.scss +188 -0
  934. data/vendor/assets/stylesheets/settings/_colours-organisations.import.scss +2 -0
  935. data/vendor/assets/stylesheets/settings/_colours-organisations.scss +23 -274
  936. data/vendor/assets/stylesheets/settings/_colours-palette--internal.scss +128 -0
  937. data/vendor/assets/stylesheets/settings/_custom-properties.import.scss +2 -0
  938. data/vendor/assets/stylesheets/settings/_custom-properties.scss +17 -0
  939. data/vendor/assets/stylesheets/settings/_global-styles.import.scss +2 -0
  940. data/vendor/assets/stylesheets/settings/_global-styles.scss +0 -1
  941. data/vendor/assets/stylesheets/settings/_index.import.scss +24 -0
  942. data/vendor/assets/stylesheets/settings/_index.scss +14 -13
  943. data/vendor/assets/stylesheets/settings/_links.import.scss +2 -0
  944. data/vendor/assets/stylesheets/settings/_links.scss +3 -3
  945. data/vendor/assets/stylesheets/settings/_measurements.import.scss +2 -0
  946. data/vendor/assets/stylesheets/settings/_measurements.scss +8 -17
  947. data/vendor/assets/stylesheets/settings/_media-queries.import.scss +2 -0
  948. data/vendor/assets/stylesheets/settings/_media-queries.scss +0 -10
  949. data/vendor/assets/stylesheets/settings/_spacing.import.scss +2 -0
  950. data/vendor/assets/stylesheets/settings/_spacing.scss +0 -1
  951. data/vendor/assets/stylesheets/settings/_typography-font.import.scss +2 -0
  952. data/vendor/assets/stylesheets/settings/_typography-font.scss +3 -2
  953. data/vendor/assets/stylesheets/settings/_typography-responsive.import.scss +2 -0
  954. data/vendor/assets/stylesheets/settings/_typography-responsive.scss +12 -190
  955. data/vendor/assets/stylesheets/settings/_warnings--internal.scss +69 -0
  956. data/vendor/assets/stylesheets/settings/_warnings.import.scss +2 -0
  957. data/vendor/assets/stylesheets/settings/_warnings.scss +9 -56
  958. data/vendor/assets/stylesheets/tools/_exports.import.scss +2 -0
  959. data/vendor/assets/stylesheets/tools/_exports.scss +12 -6
  960. data/vendor/assets/stylesheets/tools/_font-url.import.scss +31 -0
  961. data/vendor/assets/stylesheets/tools/_font-url.scss +22 -6
  962. data/vendor/assets/stylesheets/tools/_if.import.scss +2 -0
  963. data/vendor/assets/stylesheets/tools/_if.scss +23 -0
  964. data/vendor/assets/stylesheets/tools/_image-url.import.scss +31 -0
  965. data/vendor/assets/stylesheets/tools/_image-url.scss +22 -6
  966. data/vendor/assets/stylesheets/tools/_index.import.scss +2 -0
  967. data/vendor/assets/stylesheets/tools/_index.scss +6 -7
  968. data/vendor/assets/stylesheets/tools/_px-to-em.import.scss +2 -0
  969. data/vendor/assets/stylesheets/tools/_px-to-em.scss +9 -6
  970. data/vendor/assets/stylesheets/tools/_px-to-rem.import.scss +2 -0
  971. data/vendor/assets/stylesheets/tools/_px-to-rem.scss +6 -3
  972. data/vendor/assets/stylesheets/utilities/_clearfix.import.scss +8 -0
  973. data/vendor/assets/stylesheets/utilities/_clearfix.mixin.scss +10 -0
  974. data/vendor/assets/stylesheets/utilities/_clearfix.scss +3 -6
  975. data/vendor/assets/stylesheets/utilities/_index.import.scss +3 -0
  976. data/vendor/assets/stylesheets/utilities/_index.scss +2 -3
  977. data/vendor/assets/stylesheets/utilities/_visually-hidden.import.scss +8 -0
  978. data/vendor/assets/stylesheets/utilities/_visually-hidden.mixin.scss +14 -0
  979. data/vendor/assets/stylesheets/utilities/_visually-hidden.scss +2 -9
  980. metadata +541 -409
  981. data/node_modules/govuk-frontend/dist/govuk/_base.scss.map +0 -1
  982. data/node_modules/govuk-frontend/dist/govuk/all.scss +0 -9
  983. data/node_modules/govuk-frontend/dist/govuk/all.scss.map +0 -1
  984. data/node_modules/govuk-frontend/dist/govuk/assets/rebrand/images/favicon.ico +0 -0
  985. data/node_modules/govuk-frontend/dist/govuk/assets/rebrand/images/favicon.svg +0 -1
  986. data/node_modules/govuk-frontend/dist/govuk/assets/rebrand/images/govuk-crest.svg +0 -1
  987. data/node_modules/govuk-frontend/dist/govuk/assets/rebrand/images/govuk-icon-180.png +0 -0
  988. data/node_modules/govuk-frontend/dist/govuk/assets/rebrand/images/govuk-icon-192.png +0 -0
  989. data/node_modules/govuk-frontend/dist/govuk/assets/rebrand/images/govuk-icon-512.png +0 -0
  990. data/node_modules/govuk-frontend/dist/govuk/assets/rebrand/images/govuk-icon-mask.svg +0 -1
  991. data/node_modules/govuk-frontend/dist/govuk/assets/rebrand/images/govuk-opengraph-image.png +0 -0
  992. data/node_modules/govuk-frontend/dist/govuk/assets/rebrand/manifest.json +0 -39
  993. data/node_modules/govuk-frontend/dist/govuk/components/_all.scss +0 -10
  994. data/node_modules/govuk-frontend/dist/govuk/components/_all.scss.map +0 -1
  995. data/node_modules/govuk-frontend/dist/govuk/components/_index.scss.map +0 -1
  996. data/node_modules/govuk-frontend/dist/govuk/components/accordion/_accordion.scss +0 -4
  997. data/node_modules/govuk-frontend/dist/govuk/components/accordion/_accordion.scss.map +0 -1
  998. data/node_modules/govuk-frontend/dist/govuk/components/accordion/_index.scss.map +0 -1
  999. data/node_modules/govuk-frontend/dist/govuk/components/accordion/template-with-focusable-elements-inside.html +0 -26
  1000. data/node_modules/govuk-frontend/dist/govuk/components/accordion/template-with-one-section-open.html +0 -30
  1001. data/node_modules/govuk-frontend/dist/govuk/components/accordion/template-with-translations.html +0 -30
  1002. data/node_modules/govuk-frontend/dist/govuk/components/back-link/_back-link.scss +0 -4
  1003. data/node_modules/govuk-frontend/dist/govuk/components/back-link/_back-link.scss.map +0 -1
  1004. data/node_modules/govuk-frontend/dist/govuk/components/back-link/_index.scss.map +0 -1
  1005. data/node_modules/govuk-frontend/dist/govuk/components/back-link/template-with-custom-link.html +0 -1
  1006. data/node_modules/govuk-frontend/dist/govuk/components/back-link/template-with-custom-text.html +0 -1
  1007. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/_breadcrumbs.scss +0 -4
  1008. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/_breadcrumbs.scss.map +0 -1
  1009. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/_index.scss.map +0 -1
  1010. data/node_modules/govuk-frontend/dist/govuk/components/breadcrumbs/template-with-multiple-levels.html +0 -16
  1011. data/node_modules/govuk-frontend/dist/govuk/components/button/_button.scss +0 -4
  1012. data/node_modules/govuk-frontend/dist/govuk/components/button/_button.scss.map +0 -1
  1013. data/node_modules/govuk-frontend/dist/govuk/components/button/_index.scss.map +0 -1
  1014. data/node_modules/govuk-frontend/dist/govuk/components/button/template-input-disabled.html +0 -1
  1015. data/node_modules/govuk-frontend/dist/govuk/components/button/template-input.html +0 -1
  1016. data/node_modules/govuk-frontend/dist/govuk/components/button/template-inverse-link.html +0 -3
  1017. data/node_modules/govuk-frontend/dist/govuk/components/button/template-inverse-start.html +0 -6
  1018. data/node_modules/govuk-frontend/dist/govuk/components/button/template-prevent-double-click.html +0 -3
  1019. data/node_modules/govuk-frontend/dist/govuk/components/button/template-secondary-link.html +0 -3
  1020. data/node_modules/govuk-frontend/dist/govuk/components/button/template-start-link.html +0 -6
  1021. data/node_modules/govuk-frontend/dist/govuk/components/button/template-warning-link.html +0 -3
  1022. data/node_modules/govuk-frontend/dist/govuk/components/button/template-with-active-state.html +0 -3
  1023. data/node_modules/govuk-frontend/dist/govuk/components/button/template-with-focus-state.html +0 -3
  1024. data/node_modules/govuk-frontend/dist/govuk/components/button/template-with-hover-state.html +0 -3
  1025. data/node_modules/govuk-frontend/dist/govuk/components/character-count/_character-count.scss +0 -4
  1026. data/node_modules/govuk-frontend/dist/govuk/components/character-count/_character-count.scss.map +0 -1
  1027. data/node_modules/govuk-frontend/dist/govuk/components/character-count/_index.scss.map +0 -1
  1028. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-custom-textarea-description.html +0 -9
  1029. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-error.html +0 -12
  1030. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-translations.html +0 -9
  1031. data/node_modules/govuk-frontend/dist/govuk/components/character-count/template-with-word-count.html +0 -9
  1032. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/_checkboxes.scss +0 -4
  1033. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/_checkboxes.scss.map +0 -1
  1034. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/_index.scss.map +0 -1
  1035. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-small-with-disabled.html +0 -27
  1036. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-a-medium-legend.html +0 -33
  1037. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-conditional-item-checked.html +0 -39
  1038. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-conditional-items-with-special-characters.html +0 -39
  1039. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-disabled-item.html +0 -29
  1040. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-error-message-and-hints-on-items.html +0 -39
  1041. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-fieldset-and-error-message.html +0 -30
  1042. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-id-and-name.html +0 -30
  1043. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-single-option-and-hint-set-aria-describedby-on-input.html +0 -16
  1044. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-with-single-option-set-aria-describedby-on-input.html +0 -13
  1045. data/node_modules/govuk-frontend/dist/govuk/components/checkboxes/template-without-fieldset.html +0 -22
  1046. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/_cookie-banner.scss +0 -4
  1047. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/_cookie-banner.scss.map +0 -1
  1048. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/_index.scss.map +0 -1
  1049. data/node_modules/govuk-frontend/dist/govuk/components/cookie-banner/template-client-side-implementation.html +0 -60
  1050. data/node_modules/govuk-frontend/dist/govuk/components/date-input/_date-input.scss +0 -4
  1051. data/node_modules/govuk-frontend/dist/govuk/components/date-input/_date-input.scss.map +0 -1
  1052. data/node_modules/govuk-frontend/dist/govuk/components/date-input/_index.scss.map +0 -1
  1053. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-autocomplete-values.html +0 -36
  1054. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-default-items.html +0 -36
  1055. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-errors-and-hint.html +0 -39
  1056. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-input-attributes.html +0 -36
  1057. data/node_modules/govuk-frontend/dist/govuk/components/date-input/template-with-optional-form-group-classes.html +0 -36
  1058. data/node_modules/govuk-frontend/dist/govuk/components/details/_details.scss +0 -4
  1059. data/node_modules/govuk-frontend/dist/govuk/components/details/_details.scss.map +0 -1
  1060. data/node_modules/govuk-frontend/dist/govuk/components/details/_index.scss.map +0 -1
  1061. data/node_modules/govuk-frontend/dist/govuk/components/error-message/_error-message.scss +0 -4
  1062. data/node_modules/govuk-frontend/dist/govuk/components/error-message/_error-message.scss.map +0 -1
  1063. data/node_modules/govuk-frontend/dist/govuk/components/error-message/_index.scss.map +0 -1
  1064. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/_error-summary.scss +0 -4
  1065. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/_error-summary.scss.map +0 -1
  1066. data/node_modules/govuk-frontend/dist/govuk/components/error-summary/_index.scss.map +0 -1
  1067. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/_exit-this-page.scss +0 -4
  1068. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/_exit-this-page.scss.map +0 -1
  1069. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/_index.scss.map +0 -1
  1070. data/node_modules/govuk-frontend/dist/govuk/components/exit-this-page/template-translated.html +0 -5
  1071. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/_fieldset.scss +0 -4
  1072. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/_fieldset.scss.map +0 -1
  1073. data/node_modules/govuk-frontend/dist/govuk/components/fieldset/_index.scss.map +0 -1
  1074. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/_file-upload.scss +0 -4
  1075. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/_file-upload.scss.map +0 -1
  1076. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/_index.scss.map +0 -1
  1077. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template-allows-direct-media-capture.html +0 -6
  1078. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template-allows-image-files-only.html +0 -6
  1079. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template-allows-multiple-files.html +0 -6
  1080. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template-disabled.html +0 -6
  1081. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template-enhanced-disabled.html +0 -13
  1082. data/node_modules/govuk-frontend/dist/govuk/components/file-upload/template-with-optional-form-group-classes.html +0 -6
  1083. data/node_modules/govuk-frontend/dist/govuk/components/footer/_footer.scss +0 -4
  1084. data/node_modules/govuk-frontend/dist/govuk/components/footer/_footer.scss.map +0 -1
  1085. data/node_modules/govuk-frontend/dist/govuk/components/footer/_index.scss.map +0 -1
  1086. data/node_modules/govuk-frontend/dist/govuk/components/footer/template-with-meta.html +0 -56
  1087. data/node_modules/govuk-frontend/dist/govuk/components/header/_header.scss +0 -4
  1088. data/node_modules/govuk-frontend/dist/govuk/components/header/_header.scss.map +0 -1
  1089. data/node_modules/govuk-frontend/dist/govuk/components/header/_index.scss.map +0 -1
  1090. data/node_modules/govuk-frontend/dist/govuk/components/header/header.bundle.js +0 -233
  1091. data/node_modules/govuk-frontend/dist/govuk/components/header/header.bundle.js.map +0 -1
  1092. data/node_modules/govuk-frontend/dist/govuk/components/header/header.bundle.mjs +0 -225
  1093. data/node_modules/govuk-frontend/dist/govuk/components/header/header.bundle.mjs.map +0 -1
  1094. data/node_modules/govuk-frontend/dist/govuk/components/header/header.mjs +0 -89
  1095. data/node_modules/govuk-frontend/dist/govuk/components/header/header.mjs.map +0 -1
  1096. data/node_modules/govuk-frontend/dist/govuk/components/header/template-full-width-with-navigation.html +0 -55
  1097. data/node_modules/govuk-frontend/dist/govuk/components/header/template-navigation-item-with-html.html +0 -57
  1098. data/node_modules/govuk-frontend/dist/govuk/components/header/template-navigation-item-with-text-without-link.html +0 -51
  1099. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-custom-menu-button-label.html +0 -59
  1100. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-custom-menu-button-text.html +0 -59
  1101. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-custom-navigation-label.html +0 -59
  1102. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-full-width-border.html +0 -30
  1103. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-large-navigation.html +0 -119
  1104. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-navigation.html +0 -59
  1105. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-service-name-and-navigation.html +0 -62
  1106. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-service-name-but-no-service-url.html +0 -34
  1107. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-service-name.html +0 -34
  1108. data/node_modules/govuk-frontend/dist/govuk/components/header/template-with-st-edwards-crown.html +0 -19
  1109. data/node_modules/govuk-frontend/dist/govuk/components/hint/_hint.scss +0 -4
  1110. data/node_modules/govuk-frontend/dist/govuk/components/hint/_hint.scss.map +0 -1
  1111. data/node_modules/govuk-frontend/dist/govuk/components/hint/_index.scss.map +0 -1
  1112. data/node_modules/govuk-frontend/dist/govuk/components/input/_index.scss.map +0 -1
  1113. data/node_modules/govuk-frontend/dist/govuk/components/input/_input.scss +0 -4
  1114. data/node_modules/govuk-frontend/dist/govuk/components/input/_input.scss.map +0 -1
  1115. data/node_modules/govuk-frontend/dist/govuk/components/input/template-disabled.html +0 -6
  1116. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-autocapitalize-turned-off.html +0 -6
  1117. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-autocomplete-attribute.html +0 -6
  1118. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-optional-form-group-classes.html +0 -6
  1119. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-pattern-attribute.html +0 -6
  1120. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-prefix-and-long-suffix.html +0 -10
  1121. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-spellcheck-disabled.html +0 -6
  1122. data/node_modules/govuk-frontend/dist/govuk/components/input/template-with-spellcheck-enabled.html +0 -6
  1123. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/_index.scss.map +0 -1
  1124. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/_inset-text.scss +0 -4
  1125. data/node_modules/govuk-frontend/dist/govuk/components/inset-text/_inset-text.scss.map +0 -1
  1126. data/node_modules/govuk-frontend/dist/govuk/components/label/_index.scss.map +0 -1
  1127. data/node_modules/govuk-frontend/dist/govuk/components/label/_label.scss +0 -4
  1128. data/node_modules/govuk-frontend/dist/govuk/components/label/_label.scss.map +0 -1
  1129. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/_index.scss.map +0 -1
  1130. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/_notification-banner.scss +0 -4
  1131. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/_notification-banner.scss.map +0 -1
  1132. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/template-auto-focus-disabled-with-type-as-success.html +0 -12
  1133. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/template-auto-focus-explicitly-enabled-with-type-as-success.html +0 -12
  1134. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/template-custom-tabindex.html +0 -12
  1135. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/template-paragraph-as-html-heading.html +0 -10
  1136. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/template-rolealert-overridden-to-roleregion-with-type-as-success.html +0 -12
  1137. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/template-success-with-custom-html.html +0 -16
  1138. data/node_modules/govuk-frontend/dist/govuk/components/notification-banner/template-with-a-list.html +0 -16
  1139. data/node_modules/govuk-frontend/dist/govuk/components/pagination/_index.scss.map +0 -1
  1140. data/node_modules/govuk-frontend/dist/govuk/components/pagination/_pagination.scss +0 -4
  1141. data/node_modules/govuk-frontend/dist/govuk/components/pagination/_pagination.scss.map +0 -1
  1142. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template-with-custom-accessible-labels-on-item-links.html +0 -39
  1143. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template-with-custom-navigation-landmark.html +0 -39
  1144. data/node_modules/govuk-frontend/dist/govuk/components/pagination/template-with-prev-and-next-only-in-a-different-language.html +0 -22
  1145. data/node_modules/govuk-frontend/dist/govuk/components/panel/_index.scss.map +0 -1
  1146. data/node_modules/govuk-frontend/dist/govuk/components/panel/_panel.scss +0 -4
  1147. data/node_modules/govuk-frontend/dist/govuk/components/panel/_panel.scss.map +0 -1
  1148. data/node_modules/govuk-frontend/dist/govuk/components/panel/template-custom-heading-level.html +0 -8
  1149. data/node_modules/govuk-frontend/dist/govuk/components/password-input/_index.scss.map +0 -1
  1150. data/node_modules/govuk-frontend/dist/govuk/components/password-input/_password-input.scss +0 -4
  1151. data/node_modules/govuk-frontend/dist/govuk/components/password-input/_password-input.scss.map +0 -1
  1152. data/node_modules/govuk-frontend/dist/govuk/components/password-input/template-with-new-password-autocomplete.html +0 -11
  1153. data/node_modules/govuk-frontend/dist/govuk/components/password-input/template-with-translations.html +0 -11
  1154. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/_index.scss.map +0 -1
  1155. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/_phase-banner.scss +0 -4
  1156. data/node_modules/govuk-frontend/dist/govuk/components/phase-banner/_phase-banner.scss.map +0 -1
  1157. data/node_modules/govuk-frontend/dist/govuk/components/radios/_index.scss.map +0 -1
  1158. data/node_modules/govuk-frontend/dist/govuk/components/radios/_radios.scss +0 -4
  1159. data/node_modules/govuk-frontend/dist/govuk/components/radios/_radios.scss.map +0 -1
  1160. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-prechecked-using-value.html +0 -16
  1161. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-prechecked.html +0 -19
  1162. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-small-inline-extreme.html +0 -69
  1163. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-small-with-disabled.html +0 -27
  1164. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-a-medium-legend.html +0 -24
  1165. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-conditional-items-with-special-characters.html +0 -39
  1166. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-disabled.html +0 -29
  1167. data/node_modules/govuk-frontend/dist/govuk/components/radios/template-with-idprefix.html +0 -16
  1168. data/node_modules/govuk-frontend/dist/govuk/components/select/_index.scss.map +0 -1
  1169. data/node_modules/govuk-frontend/dist/govuk/components/select/_select.scss +0 -4
  1170. data/node_modules/govuk-frontend/dist/govuk/components/select/_select.scss.map +0 -1
  1171. data/node_modules/govuk-frontend/dist/govuk/components/select/template-id.html +0 -7
  1172. data/node_modules/govuk-frontend/dist/govuk/components/select/template-with-no-items.html +0 -7
  1173. data/node_modules/govuk-frontend/dist/govuk/components/select/template-with-optional-form-group-classes.html +0 -10
  1174. data/node_modules/govuk-frontend/dist/govuk/components/select/template-with-selected-value.html +0 -10
  1175. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/_index.scss.map +0 -1
  1176. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/_service-navigation.scss +0 -4
  1177. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/_service-navigation.scss.map +0 -1
  1178. data/node_modules/govuk-frontend/dist/govuk/components/service-navigation/template-with-navigation-with-an-active-item.html +0 -58
  1179. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/_index.scss.map +0 -1
  1180. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/_skip-link.scss +0 -4
  1181. data/node_modules/govuk-frontend/dist/govuk/components/skip-link/_skip-link.scss.map +0 -1
  1182. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/_index.scss.map +0 -1
  1183. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/_summary-list.scss +0 -4
  1184. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/_summary-list.scss.map +0 -1
  1185. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/template-as-a-summary-card-with-a-custom-header-level.html +0 -28
  1186. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/template-check-your-answers.html +0 -98
  1187. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/template-overridden-widths.html +0 -58
  1188. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/template-translated.html +0 -51
  1189. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/template-with-no-first-action.html +0 -58
  1190. data/node_modules/govuk-frontend/dist/govuk/components/summary-list/template-with-some-actions.html +0 -45
  1191. data/node_modules/govuk-frontend/dist/govuk/components/table/_index.scss.map +0 -1
  1192. data/node_modules/govuk-frontend/dist/govuk/components/table/_table.scss +0 -4
  1193. data/node_modules/govuk-frontend/dist/govuk/components/table/_table.scss.map +0 -1
  1194. data/node_modules/govuk-frontend/dist/govuk/components/table/template-with-small-text-modifier-for-tables-with-a-lot-of-data.html +0 -19
  1195. data/node_modules/govuk-frontend/dist/govuk/components/tabs/_index.scss.map +0 -1
  1196. data/node_modules/govuk-frontend/dist/govuk/components/tabs/_tabs.scss +0 -4
  1197. data/node_modules/govuk-frontend/dist/govuk/components/tabs/_tabs.scss.map +0 -1
  1198. data/node_modules/govuk-frontend/dist/govuk/components/tag/_index.scss.map +0 -1
  1199. data/node_modules/govuk-frontend/dist/govuk/components/tag/_tag.scss +0 -4
  1200. data/node_modules/govuk-frontend/dist/govuk/components/tag/_tag.scss.map +0 -1
  1201. data/node_modules/govuk-frontend/dist/govuk/components/tag/template-blue.html +0 -3
  1202. data/node_modules/govuk-frontend/dist/govuk/components/tag/template-light-blue.html +0 -3
  1203. data/node_modules/govuk-frontend/dist/govuk/components/task-list/_index.scss.map +0 -1
  1204. data/node_modules/govuk-frontend/dist/govuk/components/task-list/_task-list.scss +0 -4
  1205. data/node_modules/govuk-frontend/dist/govuk/components/task-list/_task-list.scss.map +0 -1
  1206. data/node_modules/govuk-frontend/dist/govuk/components/task-list/template-example-with-3-states.html +0 -49
  1207. data/node_modules/govuk-frontend/dist/govuk/components/task-list/template-example-with-all-possible-colours.html +0 -143
  1208. data/node_modules/govuk-frontend/dist/govuk/components/task-list/template-example-with-hint-text-and-additional-states.html +0 -77
  1209. data/node_modules/govuk-frontend/dist/govuk/components/textarea/_index.scss.map +0 -1
  1210. data/node_modules/govuk-frontend/dist/govuk/components/textarea/_textarea.scss +0 -4
  1211. data/node_modules/govuk-frontend/dist/govuk/components/textarea/_textarea.scss.map +0 -1
  1212. data/node_modules/govuk-frontend/dist/govuk/components/textarea/template-with-autocomplete-attribute.html +0 -6
  1213. data/node_modules/govuk-frontend/dist/govuk/components/textarea/template-with-optional-form-group-classes.html +0 -6
  1214. data/node_modules/govuk-frontend/dist/govuk/components/textarea/template-with-spellcheck-disabled.html +0 -6
  1215. data/node_modules/govuk-frontend/dist/govuk/components/textarea/template-with-spellcheck-enabled.html +0 -6
  1216. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/_index.scss.map +0 -1
  1217. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/_warning-text.scss +0 -4
  1218. data/node_modules/govuk-frontend/dist/govuk/components/warning-text/_warning-text.scss.map +0 -1
  1219. data/node_modules/govuk-frontend/dist/govuk/core/_all.scss +0 -10
  1220. data/node_modules/govuk-frontend/dist/govuk/core/_all.scss.map +0 -1
  1221. data/node_modules/govuk-frontend/dist/govuk/core/_global-styles.scss.map +0 -1
  1222. data/node_modules/govuk-frontend/dist/govuk/core/_govuk-frontend-properties.scss +0 -12
  1223. data/node_modules/govuk-frontend/dist/govuk/core/_govuk-frontend-properties.scss.map +0 -1
  1224. data/node_modules/govuk-frontend/dist/govuk/core/_index.scss.map +0 -1
  1225. data/node_modules/govuk-frontend/dist/govuk/core/_links.scss.map +0 -1
  1226. data/node_modules/govuk-frontend/dist/govuk/core/_lists.scss.map +0 -1
  1227. data/node_modules/govuk-frontend/dist/govuk/core/_section-break.scss.map +0 -1
  1228. data/node_modules/govuk-frontend/dist/govuk/core/_typography.scss.map +0 -1
  1229. data/node_modules/govuk-frontend/dist/govuk/helpers/_all.scss +0 -10
  1230. data/node_modules/govuk-frontend/dist/govuk/helpers/_all.scss.map +0 -1
  1231. data/node_modules/govuk-frontend/dist/govuk/helpers/_clearfix.scss.map +0 -1
  1232. data/node_modules/govuk-frontend/dist/govuk/helpers/_colour.scss.map +0 -1
  1233. data/node_modules/govuk-frontend/dist/govuk/helpers/_device-pixels.scss.map +0 -1
  1234. data/node_modules/govuk-frontend/dist/govuk/helpers/_focused.scss.map +0 -1
  1235. data/node_modules/govuk-frontend/dist/govuk/helpers/_font-faces.scss +0 -41
  1236. data/node_modules/govuk-frontend/dist/govuk/helpers/_font-faces.scss.map +0 -1
  1237. data/node_modules/govuk-frontend/dist/govuk/helpers/_grid.scss.map +0 -1
  1238. data/node_modules/govuk-frontend/dist/govuk/helpers/_index.scss.map +0 -1
  1239. data/node_modules/govuk-frontend/dist/govuk/helpers/_links.scss.map +0 -1
  1240. data/node_modules/govuk-frontend/dist/govuk/helpers/_media-queries.scss.map +0 -1
  1241. data/node_modules/govuk-frontend/dist/govuk/helpers/_shape-arrow.scss.map +0 -1
  1242. data/node_modules/govuk-frontend/dist/govuk/helpers/_spacing.scss.map +0 -1
  1243. data/node_modules/govuk-frontend/dist/govuk/helpers/_typography.scss.map +0 -1
  1244. data/node_modules/govuk-frontend/dist/govuk/helpers/_visually-hidden.scss.map +0 -1
  1245. data/node_modules/govuk-frontend/dist/govuk/index.scss.map +0 -1
  1246. data/node_modules/govuk-frontend/dist/govuk/objects/_all.scss +0 -10
  1247. data/node_modules/govuk-frontend/dist/govuk/objects/_all.scss.map +0 -1
  1248. data/node_modules/govuk-frontend/dist/govuk/objects/_button-group.scss.map +0 -1
  1249. data/node_modules/govuk-frontend/dist/govuk/objects/_form-group.scss.map +0 -1
  1250. data/node_modules/govuk-frontend/dist/govuk/objects/_grid.scss.map +0 -1
  1251. data/node_modules/govuk-frontend/dist/govuk/objects/_index.scss.map +0 -1
  1252. data/node_modules/govuk-frontend/dist/govuk/objects/_main-wrapper.scss.map +0 -1
  1253. data/node_modules/govuk-frontend/dist/govuk/objects/_template.scss.map +0 -1
  1254. data/node_modules/govuk-frontend/dist/govuk/objects/_width-container.scss.map +0 -1
  1255. data/node_modules/govuk-frontend/dist/govuk/overrides/_all.scss +0 -9
  1256. data/node_modules/govuk-frontend/dist/govuk/overrides/_all.scss.map +0 -1
  1257. data/node_modules/govuk-frontend/dist/govuk/overrides/_display.scss.map +0 -1
  1258. data/node_modules/govuk-frontend/dist/govuk/overrides/_index.scss.map +0 -1
  1259. data/node_modules/govuk-frontend/dist/govuk/overrides/_spacing.scss.map +0 -1
  1260. data/node_modules/govuk-frontend/dist/govuk/overrides/_text-align.scss.map +0 -1
  1261. data/node_modules/govuk-frontend/dist/govuk/overrides/_typography.scss.map +0 -1
  1262. data/node_modules/govuk-frontend/dist/govuk/overrides/_width.scss.map +0 -1
  1263. data/node_modules/govuk-frontend/dist/govuk/settings/_all.scss +0 -10
  1264. data/node_modules/govuk-frontend/dist/govuk/settings/_all.scss.map +0 -1
  1265. data/node_modules/govuk-frontend/dist/govuk/settings/_assets.scss.map +0 -1
  1266. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-applied.scss +0 -195
  1267. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-applied.scss.map +0 -1
  1268. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-organisations.scss.map +0 -1
  1269. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-palette.scss +0 -37
  1270. data/node_modules/govuk-frontend/dist/govuk/settings/_colours-palette.scss.map +0 -1
  1271. data/node_modules/govuk-frontend/dist/govuk/settings/_global-styles.scss.map +0 -1
  1272. data/node_modules/govuk-frontend/dist/govuk/settings/_index.scss.map +0 -1
  1273. data/node_modules/govuk-frontend/dist/govuk/settings/_links.scss.map +0 -1
  1274. data/node_modules/govuk-frontend/dist/govuk/settings/_measurements.scss.map +0 -1
  1275. data/node_modules/govuk-frontend/dist/govuk/settings/_media-queries.scss.map +0 -1
  1276. data/node_modules/govuk-frontend/dist/govuk/settings/_spacing.scss.map +0 -1
  1277. data/node_modules/govuk-frontend/dist/govuk/settings/_typography-font.scss.map +0 -1
  1278. data/node_modules/govuk-frontend/dist/govuk/settings/_typography-responsive.scss.map +0 -1
  1279. data/node_modules/govuk-frontend/dist/govuk/settings/_warnings.scss.map +0 -1
  1280. data/node_modules/govuk-frontend/dist/govuk/tools/_all.scss +0 -10
  1281. data/node_modules/govuk-frontend/dist/govuk/tools/_all.scss.map +0 -1
  1282. data/node_modules/govuk-frontend/dist/govuk/tools/_exports.scss.map +0 -1
  1283. data/node_modules/govuk-frontend/dist/govuk/tools/_font-url.scss.map +0 -1
  1284. data/node_modules/govuk-frontend/dist/govuk/tools/_image-url.scss.map +0 -1
  1285. data/node_modules/govuk-frontend/dist/govuk/tools/_index.scss.map +0 -1
  1286. data/node_modules/govuk-frontend/dist/govuk/tools/_px-to-em.scss.map +0 -1
  1287. data/node_modules/govuk-frontend/dist/govuk/tools/_px-to-rem.scss.map +0 -1
  1288. data/node_modules/govuk-frontend/dist/govuk/tools/_rebrand.scss +0 -65
  1289. data/node_modules/govuk-frontend/dist/govuk/tools/_rebrand.scss.map +0 -1
  1290. data/node_modules/govuk-frontend/dist/govuk/utilities/_all.scss +0 -10
  1291. data/node_modules/govuk-frontend/dist/govuk/utilities/_all.scss.map +0 -1
  1292. data/node_modules/govuk-frontend/dist/govuk/utilities/_clearfix.scss.map +0 -1
  1293. data/node_modules/govuk-frontend/dist/govuk/utilities/_index.scss.map +0 -1
  1294. data/node_modules/govuk-frontend/dist/govuk/utilities/_visually-hidden.scss.map +0 -1
  1295. data/node_modules/govuk-frontend/dist/govuk/vendor/_sass-mq.scss +0 -349
  1296. data/node_modules/govuk-frontend/dist/govuk/vendor/_sass-mq.scss.map +0 -1
  1297. data/node_modules/govuk-frontend/dist/govuk-prototype-kit/functions.js +0 -25
  1298. data/node_modules/govuk-frontend/dist/govuk-prototype-kit/init.scss.map +0 -1
  1299. data/spec/spec_helper.rb +0 -98
  1300. data/spec/tasks/assets_spec.rb +0 -53
  1301. data/vendor/assets/assets/manifest.json +0 -39
  1302. data/vendor/assets/assets/rebrand/images/favicon.ico +0 -0
  1303. data/vendor/assets/assets/rebrand/images/favicon.svg +0 -1
  1304. data/vendor/assets/assets/rebrand/images/govuk-crest.svg +0 -1
  1305. data/vendor/assets/assets/rebrand/images/govuk-icon-180.png +0 -0
  1306. data/vendor/assets/assets/rebrand/images/govuk-icon-192.png +0 -0
  1307. data/vendor/assets/assets/rebrand/images/govuk-icon-512.png +0 -0
  1308. data/vendor/assets/assets/rebrand/images/govuk-icon-mask.svg +0 -1
  1309. data/vendor/assets/assets/rebrand/images/govuk-opengraph-image.png +0 -0
  1310. data/vendor/assets/assets/rebrand/manifest.json +0 -39
  1311. data/vendor/assets/images/govuk-crest-2x.png +0 -0
  1312. data/vendor/assets/images/govuk-crest.png +0 -0
  1313. data/vendor/assets/stylesheets/all.scss +0 -9
  1314. data/vendor/assets/stylesheets/components/_all.scss +0 -10
  1315. data/vendor/assets/stylesheets/components/accordion/_accordion.scss +0 -4
  1316. data/vendor/assets/stylesheets/components/back-link/_back-link.scss +0 -4
  1317. data/vendor/assets/stylesheets/components/breadcrumbs/_breadcrumbs.scss +0 -4
  1318. data/vendor/assets/stylesheets/components/button/_button.scss +0 -4
  1319. data/vendor/assets/stylesheets/components/character-count/_character-count.scss +0 -4
  1320. data/vendor/assets/stylesheets/components/checkboxes/_checkboxes.scss +0 -4
  1321. data/vendor/assets/stylesheets/components/cookie-banner/_cookie-banner.scss +0 -4
  1322. data/vendor/assets/stylesheets/components/date-input/_date-input.scss +0 -4
  1323. data/vendor/assets/stylesheets/components/details/_details.scss +0 -4
  1324. data/vendor/assets/stylesheets/components/error-message/_error-message.scss +0 -4
  1325. data/vendor/assets/stylesheets/components/error-summary/_error-summary.scss +0 -4
  1326. data/vendor/assets/stylesheets/components/exit-this-page/_exit-this-page.scss +0 -4
  1327. data/vendor/assets/stylesheets/components/fieldset/_fieldset.scss +0 -4
  1328. data/vendor/assets/stylesheets/components/file-upload/_file-upload.scss +0 -4
  1329. data/vendor/assets/stylesheets/components/footer/_footer.scss +0 -4
  1330. data/vendor/assets/stylesheets/components/header/_header.scss +0 -4
  1331. data/vendor/assets/stylesheets/components/hint/_hint.scss +0 -4
  1332. data/vendor/assets/stylesheets/components/input/_input.scss +0 -4
  1333. data/vendor/assets/stylesheets/components/inset-text/_inset-text.scss +0 -4
  1334. data/vendor/assets/stylesheets/components/label/_label.scss +0 -4
  1335. data/vendor/assets/stylesheets/components/notification-banner/_notification-banner.scss +0 -4
  1336. data/vendor/assets/stylesheets/components/pagination/_pagination.scss +0 -4
  1337. data/vendor/assets/stylesheets/components/panel/_panel.scss +0 -4
  1338. data/vendor/assets/stylesheets/components/password-input/_password-input.scss +0 -4
  1339. data/vendor/assets/stylesheets/components/phase-banner/_phase-banner.scss +0 -4
  1340. data/vendor/assets/stylesheets/components/radios/_radios.scss +0 -4
  1341. data/vendor/assets/stylesheets/components/select/_select.scss +0 -4
  1342. data/vendor/assets/stylesheets/components/service-navigation/_service-navigation.scss +0 -4
  1343. data/vendor/assets/stylesheets/components/skip-link/_skip-link.scss +0 -4
  1344. data/vendor/assets/stylesheets/components/summary-list/_summary-list.scss +0 -4
  1345. data/vendor/assets/stylesheets/components/table/_table.scss +0 -4
  1346. data/vendor/assets/stylesheets/components/tabs/_tabs.scss +0 -4
  1347. data/vendor/assets/stylesheets/components/tag/_tag.scss +0 -4
  1348. data/vendor/assets/stylesheets/components/task-list/_task-list.scss +0 -4
  1349. data/vendor/assets/stylesheets/components/textarea/_textarea.scss +0 -4
  1350. data/vendor/assets/stylesheets/components/warning-text/_warning-text.scss +0 -4
  1351. data/vendor/assets/stylesheets/core/_all.scss +0 -10
  1352. data/vendor/assets/stylesheets/core/_govuk-frontend-properties.scss +0 -12
  1353. data/vendor/assets/stylesheets/helpers/_all.scss +0 -10
  1354. data/vendor/assets/stylesheets/helpers/_font-faces.scss +0 -41
  1355. data/vendor/assets/stylesheets/objects/_all.scss +0 -10
  1356. data/vendor/assets/stylesheets/overrides/_all.scss +0 -9
  1357. data/vendor/assets/stylesheets/settings/_all.scss +0 -10
  1358. data/vendor/assets/stylesheets/settings/_colours-applied.scss +0 -195
  1359. data/vendor/assets/stylesheets/settings/_colours-palette.scss +0 -37
  1360. data/vendor/assets/stylesheets/tools/_all.scss +0 -10
  1361. data/vendor/assets/stylesheets/tools/_rebrand.scss +0 -65
  1362. data/vendor/assets/stylesheets/utilities/_all.scss +0 -10
  1363. data/vendor/assets/stylesheets/vendor/_sass-mq.scss +0 -349
  1364. /data/node_modules/govuk-frontend/dist/govuk/components/date-input/{template-complete-question.html → template-with-items.html} +0 -0
  1365. /data/node_modules/govuk-frontend/dist/govuk/components/table/{template-table-with-head-and-caption.html → template-with-head-and-caption.html} +0 -0
  1366. /data/node_modules/govuk-frontend/dist/govuk/components/table/{template-table-with-head.html → template-with-head.html} +0 -0
  1367. /data/node_modules/govuk-frontend/dist/govuk/components/task-list/{template-example-with-very-long-single-word-tags.html → template-with-very-long-single-word-tags.html} +0 -0
@@ -1,13 +1,7 @@
1
- const version = '5.10.2';
1
+ const version = '6.6.0';
2
2
 
3
- function getFragmentFromUrl(url) {
4
- if (!url.includes('#')) {
5
- return undefined;
6
- }
7
- return url.split('#').pop();
8
- }
9
3
  function getBreakpoint(name) {
10
- const property = `--govuk-frontend-breakpoint-${name}`;
4
+ const property = `--govuk-breakpoint-${name}`;
11
5
  const value = window.getComputedStyle(document.documentElement).getPropertyValue(property);
12
6
  return {
13
7
  property,
@@ -63,6 +57,9 @@ function isArray(option) {
63
57
  function isObject(option) {
64
58
  return !!option && typeof option === 'object' && !isArray(option);
65
59
  }
60
+ function isScope($scope) {
61
+ return !!$scope && ($scope instanceof Element || $scope instanceof Document);
62
+ }
66
63
  function formatErrorMessage(Component, message) {
67
64
  return `${Component.moduleName}: ${message}`;
68
65
  }
@@ -70,9 +67,6 @@ function formatErrorMessage(Component, message) {
70
67
  * @typedef ComponentWithModuleName
71
68
  * @property {string} moduleName - Name of the component
72
69
  */
73
- /**
74
- * @import { ObjectNested } from './configuration.mjs'
75
- */
76
70
 
77
71
  class GOVUKFrontendError extends Error {
78
72
  constructor(...args) {
@@ -84,11 +78,14 @@ class SupportError extends GOVUKFrontendError {
84
78
  /**
85
79
  * Checks if GOV.UK Frontend is supported on this page
86
80
  *
87
- * @param {HTMLElement | null} [$scope] - HTML element `<body>` checked for browser support
81
+ * @param {Element | Document | null | string} [scopeOrMessage] - HTML element `<body>` checked for browser support or support error message
88
82
  */
89
- constructor($scope = document.body) {
90
- 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';
91
- super($scope ? supportMessage : 'GOV.UK Frontend initialised without `<script type="module">`');
83
+ constructor(scopeOrMessage = document.body) {
84
+ let 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';
85
+ if (!isScope(scopeOrMessage)) {
86
+ supportMessage = 'GOV.UK Frontend initialised without `<script type="module">`';
87
+ }
88
+ super(typeof scopeOrMessage === 'string' ? scopeOrMessage : supportMessage);
92
89
  this.name = 'SupportError';
93
90
  }
94
91
  }
@@ -101,7 +98,7 @@ class ConfigError extends GOVUKFrontendError {
101
98
  class ElementError extends GOVUKFrontendError {
102
99
  constructor(messageOrOptions) {
103
100
  let message = typeof messageOrOptions === 'string' ? messageOrOptions : '';
104
- if (typeof messageOrOptions === 'object') {
101
+ if (isObject(messageOrOptions)) {
105
102
  const {
106
103
  component,
107
104
  identifier,
@@ -110,7 +107,9 @@ class ElementError extends GOVUKFrontendError {
110
107
  } = messageOrOptions;
111
108
  message = identifier;
112
109
  message += element ? ` is not of type ${expectedType != null ? expectedType : 'HTMLElement'}` : ' not found';
113
- message = formatErrorMessage(component, message);
110
+ if (component) {
111
+ message = formatErrorMessage(component, message);
112
+ }
114
113
  }
115
114
  super(message);
116
115
  this.name = 'ElementError';
@@ -127,6 +126,7 @@ class InitError extends GOVUKFrontendError {
127
126
  * @import { ComponentWithModuleName } from '../common/index.mjs'
128
127
  */
129
128
 
129
+ const _self$1 = typeof globalThis !== 'undefined' ? globalThis : self;
130
130
  class Component {
131
131
  /**
132
132
  * Returns the root element of the component
@@ -180,7 +180,7 @@ class Component {
180
180
  /**
181
181
  * @typedef {typeof Component & ChildClass} ChildClassConstructor
182
182
  */
183
- Component.elementType = HTMLElement;
183
+ Component.elementType = _self$1.HTMLElement;
184
184
 
185
185
  const configOverride = Symbol.for('configOverride');
186
186
  class ConfigurableComponent extends Component {
@@ -205,10 +205,14 @@ class ConfigurableComponent extends Component {
205
205
  throw new ConfigError(formatErrorMessage(childConstructor, 'Config passed as parameter into constructor but no defaults defined'));
206
206
  }
207
207
  const datasetConfig = normaliseDataset(childConstructor, this._$root.dataset);
208
- this._config = mergeConfigs(childConstructor.defaults, config != null ? config : {}, this[configOverride](datasetConfig), datasetConfig);
208
+ this._config = mergeConfigs(childConstructor.defaults, config != null ? config : {});
209
+ this._config = mergeConfigs(this._config, this[configOverride](datasetConfig), datasetConfig);
209
210
  }
210
211
  }
211
212
  function normaliseString(value, property) {
213
+ if (property != null && property.type && !['string', 'number', 'boolean'].includes(property.type)) {
214
+ return;
215
+ }
212
216
  const trimmedValue = value ? value.trim() : '';
213
217
  let output;
214
218
  let outputType = property == null ? void 0 : property.type;
@@ -250,6 +254,30 @@ function normaliseDataset(Component, dataset) {
250
254
  }
251
255
  return out;
252
256
  }
257
+ function normaliseOptions(scopeOrOptions) {
258
+ let $scope = document;
259
+ let onError;
260
+ if (isObject(scopeOrOptions)) {
261
+ const options = scopeOrOptions;
262
+ if (isScope(options.scope) || options.scope === null) {
263
+ $scope = options.scope;
264
+ }
265
+ if (typeof options.onError === 'function') {
266
+ onError = options.onError;
267
+ }
268
+ }
269
+ if (isScope(scopeOrOptions)) {
270
+ $scope = scopeOrOptions;
271
+ } else if (scopeOrOptions === null) {
272
+ $scope = null;
273
+ } else if (typeof scopeOrOptions === 'function') {
274
+ onError = scopeOrOptions;
275
+ }
276
+ return {
277
+ scope: $scope,
278
+ onError
279
+ };
280
+ }
253
281
  function mergeConfigs(...configObjects) {
254
282
  const formattedConfigObject = {};
255
283
  for (const configObject of configObjects) {
@@ -344,6 +372,20 @@ function extractConfigByNamespace(schema, dataset, namespace) {
344
372
  * @template {Partial<Record<keyof ConfigurationType, unknown>>} [ConfigurationType=ObjectNested]
345
373
  * @typedef {typeof Component & ChildClass<ConfigurationType>} ChildClassConstructor<ConfigurationType>
346
374
  */
375
+ /**
376
+ * @import { CompatibleClass, Config, CreateAllOptions, OnErrorCallback } from '../init.mjs'
377
+ */
378
+
379
+ function createElement(tagName, attributes = {}, children = []) {
380
+ const $element = document.createElement(tagName);
381
+ Object.entries(attributes).forEach(([name, value]) => {
382
+ $element.setAttribute(name, value);
383
+ });
384
+ for (const child of children) {
385
+ $element.append(child);
386
+ }
387
+ return $element;
388
+ }
347
389
 
348
390
  class I18n {
349
391
  constructor(translations = {}, config = {}) {
@@ -358,7 +400,7 @@ class I18n {
358
400
  throw new Error('i18n: lookup key missing');
359
401
  }
360
402
  let translation = this.translations[lookupKey];
361
- if (typeof (options == null ? void 0 : options.count) === 'number' && typeof translation === 'object') {
403
+ if (typeof (options == null ? void 0 : options.count) === 'number' && isObject(translation)) {
362
404
  const translationPluralForm = translation[this.getPluralSuffix(lookupKey, options.count)];
363
405
  if (translationPluralForm) {
364
406
  translation = translationPluralForm;
@@ -400,8 +442,8 @@ class I18n {
400
442
  return 'other';
401
443
  }
402
444
  const translation = this.translations[lookupKey];
403
- const preferredForm = this.hasIntlPluralRulesSupport() ? new Intl.PluralRules(this.locale).select(count) : this.selectPluralFormUsingFallbackRules(count);
404
- if (typeof translation === 'object') {
445
+ const preferredForm = this.hasIntlPluralRulesSupport() ? new Intl.PluralRules(this.locale).select(count) : 'other';
446
+ if (isObject(translation)) {
405
447
  if (preferredForm in translation) {
406
448
  return preferredForm;
407
449
  } else if ('other' in translation) {
@@ -411,132 +453,7 @@ class I18n {
411
453
  }
412
454
  throw new Error(`i18n: Plural form ".other" is required for "${this.locale}" locale`);
413
455
  }
414
- selectPluralFormUsingFallbackRules(count) {
415
- count = Math.abs(Math.floor(count));
416
- const ruleset = this.getPluralRulesForLocale();
417
- if (ruleset) {
418
- return I18n.pluralRules[ruleset](count);
419
- }
420
- return 'other';
421
- }
422
- getPluralRulesForLocale() {
423
- const localeShort = this.locale.split('-')[0];
424
- for (const pluralRule in I18n.pluralRulesMap) {
425
- const languages = I18n.pluralRulesMap[pluralRule];
426
- if (languages.includes(this.locale) || languages.includes(localeShort)) {
427
- return pluralRule;
428
- }
429
- }
430
- }
431
456
  }
432
- I18n.pluralRulesMap = {
433
- arabic: ['ar'],
434
- chinese: ['my', 'zh', 'id', 'ja', 'jv', 'ko', 'ms', 'th', 'vi'],
435
- french: ['hy', 'bn', 'fr', 'gu', 'hi', 'fa', 'pa', 'zu'],
436
- german: ['af', 'sq', 'az', 'eu', 'bg', 'ca', 'da', 'nl', 'en', 'et', 'fi', 'ka', 'de', 'el', 'hu', 'lb', 'no', 'so', 'sw', 'sv', 'ta', 'te', 'tr', 'ur'],
437
- irish: ['ga'],
438
- russian: ['ru', 'uk'],
439
- scottish: ['gd'],
440
- spanish: ['pt-PT', 'it', 'es'],
441
- welsh: ['cy']
442
- };
443
- I18n.pluralRules = {
444
- arabic(n) {
445
- if (n === 0) {
446
- return 'zero';
447
- }
448
- if (n === 1) {
449
- return 'one';
450
- }
451
- if (n === 2) {
452
- return 'two';
453
- }
454
- if (n % 100 >= 3 && n % 100 <= 10) {
455
- return 'few';
456
- }
457
- if (n % 100 >= 11 && n % 100 <= 99) {
458
- return 'many';
459
- }
460
- return 'other';
461
- },
462
- chinese() {
463
- return 'other';
464
- },
465
- french(n) {
466
- return n === 0 || n === 1 ? 'one' : 'other';
467
- },
468
- german(n) {
469
- return n === 1 ? 'one' : 'other';
470
- },
471
- irish(n) {
472
- if (n === 1) {
473
- return 'one';
474
- }
475
- if (n === 2) {
476
- return 'two';
477
- }
478
- if (n >= 3 && n <= 6) {
479
- return 'few';
480
- }
481
- if (n >= 7 && n <= 10) {
482
- return 'many';
483
- }
484
- return 'other';
485
- },
486
- russian(n) {
487
- const lastTwo = n % 100;
488
- const last = lastTwo % 10;
489
- if (last === 1 && lastTwo !== 11) {
490
- return 'one';
491
- }
492
- if (last >= 2 && last <= 4 && !(lastTwo >= 12 && lastTwo <= 14)) {
493
- return 'few';
494
- }
495
- if (last === 0 || last >= 5 && last <= 9 || lastTwo >= 11 && lastTwo <= 14) {
496
- return 'many';
497
- }
498
- return 'other';
499
- },
500
- scottish(n) {
501
- if (n === 1 || n === 11) {
502
- return 'one';
503
- }
504
- if (n === 2 || n === 12) {
505
- return 'two';
506
- }
507
- if (n >= 3 && n <= 10 || n >= 13 && n <= 19) {
508
- return 'few';
509
- }
510
- return 'other';
511
- },
512
- spanish(n) {
513
- if (n === 1) {
514
- return 'one';
515
- }
516
- if (n % 1000000 === 0 && n !== 0) {
517
- return 'many';
518
- }
519
- return 'other';
520
- },
521
- welsh(n) {
522
- if (n === 0) {
523
- return 'zero';
524
- }
525
- if (n === 1) {
526
- return 'one';
527
- }
528
- if (n === 2) {
529
- return 'two';
530
- }
531
- if (n === 3) {
532
- return 'few';
533
- }
534
- if (n === 6) {
535
- return 'many';
536
- }
537
- return 'other';
538
- }
539
- };
540
457
 
541
458
  /**
542
459
  * Accordion component
@@ -561,24 +478,16 @@ class Accordion extends ConfigurableComponent {
561
478
  constructor($root, config = {}) {
562
479
  super($root, config);
563
480
  this.i18n = void 0;
564
- this.controlsClass = 'govuk-accordion__controls';
565
- this.showAllClass = 'govuk-accordion__show-all';
566
- this.showAllTextClass = 'govuk-accordion__show-all-text';
567
481
  this.sectionClass = 'govuk-accordion__section';
568
- this.sectionExpandedClass = 'govuk-accordion__section--expanded';
482
+ this.sectionExpandedModifier = 'govuk-accordion__section--expanded';
569
483
  this.sectionButtonClass = 'govuk-accordion__section-button';
570
484
  this.sectionHeaderClass = 'govuk-accordion__section-header';
571
485
  this.sectionHeadingClass = 'govuk-accordion__section-heading';
572
- this.sectionHeadingDividerClass = 'govuk-accordion__section-heading-divider';
573
486
  this.sectionHeadingTextClass = 'govuk-accordion__section-heading-text';
574
- this.sectionHeadingTextFocusClass = 'govuk-accordion__section-heading-text-focus';
575
- this.sectionShowHideToggleClass = 'govuk-accordion__section-toggle';
576
- this.sectionShowHideToggleFocusClass = 'govuk-accordion__section-toggle-focus';
577
- this.sectionShowHideTextClass = 'govuk-accordion__section-toggle-text';
578
- this.upChevronIconClass = 'govuk-accordion-nav__chevron';
579
- this.downChevronIconClass = 'govuk-accordion-nav__chevron--down';
487
+ this.sectionToggleTextClass = 'govuk-accordion__section-toggle-text';
488
+ this.iconClass = 'govuk-accordion-nav__chevron';
489
+ this.iconOpenModifier = 'govuk-accordion-nav__chevron--down';
580
490
  this.sectionSummaryClass = 'govuk-accordion__section-summary';
581
- this.sectionSummaryFocusClass = 'govuk-accordion__section-summary-focus';
582
491
  this.sectionContentClass = 'govuk-accordion__section-content';
583
492
  this.$sections = void 0;
584
493
  this.$showAllButton = null;
@@ -598,19 +507,23 @@ class Accordion extends ConfigurableComponent {
598
507
  this.updateShowAllButton(this.areAllSectionsOpen());
599
508
  }
600
509
  initControls() {
601
- this.$showAllButton = document.createElement('button');
602
- this.$showAllButton.setAttribute('type', 'button');
603
- this.$showAllButton.setAttribute('class', this.showAllClass);
604
- this.$showAllButton.setAttribute('aria-expanded', 'false');
605
- this.$showAllIcon = document.createElement('span');
606
- this.$showAllIcon.classList.add(this.upChevronIconClass);
510
+ this.$showAllButton = createElement('button', {
511
+ type: 'button',
512
+ class: 'govuk-accordion__show-all',
513
+ 'aria-expanded': 'false'
514
+ });
515
+ this.$showAllIcon = createElement('span', {
516
+ class: this.iconClass
517
+ });
607
518
  this.$showAllButton.appendChild(this.$showAllIcon);
608
- const $accordionControls = document.createElement('div');
609
- $accordionControls.setAttribute('class', this.controlsClass);
519
+ const $accordionControls = createElement('div', {
520
+ class: 'govuk-accordion__controls'
521
+ });
610
522
  $accordionControls.appendChild(this.$showAllButton);
611
523
  this.$root.insertBefore($accordionControls, this.$root.firstChild);
612
- this.$showAllText = document.createElement('span');
613
- this.$showAllText.classList.add(this.showAllTextClass);
524
+ this.$showAllText = createElement('span', {
525
+ class: 'govuk-accordion__show-all-text'
526
+ });
614
527
  this.$showAllButton.appendChild(this.$showAllText);
615
528
  this.$showAllButton.addEventListener('click', () => this.onShowOrHideAllToggle());
616
529
  if ('onbeforematch' in document) {
@@ -648,39 +561,45 @@ class Accordion extends ConfigurableComponent {
648
561
  identifier: `Section button placeholder (\`<span class="${this.sectionButtonClass}">\`)`
649
562
  });
650
563
  }
651
- const $button = document.createElement('button');
652
- $button.setAttribute('type', 'button');
653
- $button.setAttribute('aria-controls', `${this.$root.id}-content-${index + 1}`);
564
+ const $button = createElement('button', {
565
+ type: 'button',
566
+ 'aria-controls': `${this.$root.id}-content-${index + 1}`
567
+ });
654
568
  for (const attr of Array.from($span.attributes)) {
655
569
  if (attr.name !== 'id') {
656
570
  $button.setAttribute(attr.name, attr.value);
657
571
  }
658
572
  }
659
- const $headingText = document.createElement('span');
660
- $headingText.classList.add(this.sectionHeadingTextClass);
661
- $headingText.id = $span.id;
662
- const $headingTextFocus = document.createElement('span');
663
- $headingTextFocus.classList.add(this.sectionHeadingTextFocusClass);
573
+ const $headingText = createElement('span', {
574
+ class: this.sectionHeadingTextClass,
575
+ id: $span.id
576
+ });
577
+ const $headingTextFocus = createElement('span', {
578
+ class: 'govuk-accordion__section-heading-text-focus'
579
+ });
664
580
  $headingText.appendChild($headingTextFocus);
665
581
  Array.from($span.childNodes).forEach($child => $headingTextFocus.appendChild($child));
666
- const $showHideToggle = document.createElement('span');
667
- $showHideToggle.classList.add(this.sectionShowHideToggleClass);
668
- $showHideToggle.setAttribute('data-nosnippet', '');
669
- const $showHideToggleFocus = document.createElement('span');
670
- $showHideToggleFocus.classList.add(this.sectionShowHideToggleFocusClass);
582
+ const $showHideToggle = createElement('span', {
583
+ class: 'govuk-accordion__section-toggle',
584
+ 'data-nosnippet': ''
585
+ });
586
+ const $showHideToggleFocus = createElement('span', {
587
+ class: 'govuk-accordion__section-toggle-focus'
588
+ });
671
589
  $showHideToggle.appendChild($showHideToggleFocus);
672
- const $showHideText = document.createElement('span');
673
- const $showHideIcon = document.createElement('span');
674
- $showHideIcon.classList.add(this.upChevronIconClass);
675
- $showHideToggleFocus.appendChild($showHideIcon);
676
- $showHideText.classList.add(this.sectionShowHideTextClass);
677
- $showHideToggleFocus.appendChild($showHideText);
590
+ $showHideToggleFocus.appendChild(createElement('span', {
591
+ class: this.iconClass
592
+ }));
593
+ $showHideToggleFocus.appendChild(createElement('span', {
594
+ class: this.sectionToggleTextClass
595
+ }));
678
596
  $button.appendChild($headingText);
679
597
  $button.appendChild(this.getButtonPunctuationEl());
680
598
  if ($summary) {
681
- const $summarySpan = document.createElement('span');
682
- const $summarySpanFocus = document.createElement('span');
683
- $summarySpanFocus.classList.add(this.sectionSummaryFocusClass);
599
+ const $summarySpan = createElement('span');
600
+ const $summarySpanFocus = createElement('span', {
601
+ class: 'govuk-accordion__section-summary-focus'
602
+ });
684
603
  $summarySpan.appendChild($summarySpanFocus);
685
604
  for (const attr of Array.from($summary.attributes)) {
686
605
  $summarySpan.setAttribute(attr.name, attr.value);
@@ -718,8 +637,8 @@ class Accordion extends ConfigurableComponent {
718
637
  this.updateShowAllButton(nowExpanded);
719
638
  }
720
639
  setExpanded(expanded, $section) {
721
- const $showHideIcon = $section.querySelector(`.${this.upChevronIconClass}`);
722
- const $showHideText = $section.querySelector(`.${this.sectionShowHideTextClass}`);
640
+ const $showHideIcon = $section.querySelector(`.${this.iconClass}`);
641
+ const $showHideText = $section.querySelector(`.${this.sectionToggleTextClass}`);
723
642
  const $button = $section.querySelector(`.${this.sectionButtonClass}`);
724
643
  const $content = $section.querySelector(`.${this.sectionContentClass}`);
725
644
  if (!$content) {
@@ -737,28 +656,28 @@ class Accordion extends ConfigurableComponent {
737
656
  const ariaLabelParts = [];
738
657
  const $headingText = $section.querySelector(`.${this.sectionHeadingTextClass}`);
739
658
  if ($headingText) {
740
- ariaLabelParts.push(`${$headingText.textContent}`.trim());
659
+ ariaLabelParts.push($headingText.textContent.trim());
741
660
  }
742
661
  const $summary = $section.querySelector(`.${this.sectionSummaryClass}`);
743
662
  if ($summary) {
744
- ariaLabelParts.push(`${$summary.textContent}`.trim());
663
+ ariaLabelParts.push($summary.textContent.trim());
745
664
  }
746
665
  const ariaLabelMessage = expanded ? this.i18n.t('hideSectionAriaLabel') : this.i18n.t('showSectionAriaLabel');
747
666
  ariaLabelParts.push(ariaLabelMessage);
748
667
  $button.setAttribute('aria-label', ariaLabelParts.join(' , '));
749
668
  if (expanded) {
750
669
  $content.removeAttribute('hidden');
751
- $section.classList.add(this.sectionExpandedClass);
752
- $showHideIcon.classList.remove(this.downChevronIconClass);
670
+ $section.classList.add(this.sectionExpandedModifier);
671
+ $showHideIcon.classList.remove(this.iconOpenModifier);
753
672
  } else {
754
673
  $content.setAttribute('hidden', 'until-found');
755
- $section.classList.remove(this.sectionExpandedClass);
756
- $showHideIcon.classList.add(this.downChevronIconClass);
674
+ $section.classList.remove(this.sectionExpandedModifier);
675
+ $showHideIcon.classList.add(this.iconOpenModifier);
757
676
  }
758
677
  this.updateShowAllButton(this.areAllSectionsOpen());
759
678
  }
760
679
  isExpanded($section) {
761
- return $section.classList.contains(this.sectionExpandedClass);
680
+ return $section.classList.contains(this.sectionExpandedModifier);
762
681
  }
763
682
  areAllSectionsOpen() {
764
683
  return Array.from(this.$sections).every($section => this.isExpanded($section));
@@ -769,7 +688,7 @@ class Accordion extends ConfigurableComponent {
769
688
  }
770
689
  this.$showAllButton.setAttribute('aria-expanded', expanded.toString());
771
690
  this.$showAllText.textContent = expanded ? this.i18n.t('hideAllSections') : this.i18n.t('showAllSections');
772
- this.$showAllIcon.classList.toggle(this.downChevronIconClass, !expanded);
691
+ this.$showAllIcon.classList.toggle(this.iconOpenModifier, !expanded);
773
692
  }
774
693
 
775
694
  /**
@@ -794,7 +713,7 @@ class Accordion extends ConfigurableComponent {
794
713
  if (id) {
795
714
  try {
796
715
  window.sessionStorage.setItem(id, isExpanded.toString());
797
- } catch (exception) {}
716
+ } catch (_unused) {}
798
717
  }
799
718
  }
800
719
  setInitialState($section) {
@@ -808,14 +727,15 @@ class Accordion extends ConfigurableComponent {
808
727
  if (state !== null) {
809
728
  this.setExpanded(state === 'true', $section);
810
729
  }
811
- } catch (exception) {}
730
+ } catch (_unused2) {}
812
731
  }
813
732
  }
814
733
  getButtonPunctuationEl() {
815
- const $punctuationEl = document.createElement('span');
816
- $punctuationEl.classList.add('govuk-visually-hidden', this.sectionHeadingDividerClass);
817
- $punctuationEl.textContent = ', ';
818
- return $punctuationEl;
734
+ const $element = createElement('span', {
735
+ class: 'govuk-visually-hidden govuk-accordion__section-heading-divider'
736
+ });
737
+ $element.textContent = ', ';
738
+ return $element;
819
739
  }
820
740
  }
821
741
 
@@ -971,6 +891,14 @@ class CharacterCount extends ConfigurableComponent {
971
891
  maxwords: undefined
972
892
  };
973
893
  }
894
+ if ('maxwords' in datasetConfig || this.config.maxwords !== undefined) {
895
+ console.warn(formatErrorMessage(CharacterCount, 'Option `maxwords` is deprecated. Use `maxlength` with `countType: "words"` instead.'));
896
+ if (!('maxlength' in datasetConfig)) {
897
+ var _datasetConfig$maxwor;
898
+ configOverrides.maxlength = (_datasetConfig$maxwor = datasetConfig.maxwords) != null ? _datasetConfig$maxwor : this.config.maxwords;
899
+ configOverrides.countType = 'words';
900
+ }
901
+ }
974
902
  return configOverrides;
975
903
  }
976
904
 
@@ -979,9 +907,11 @@ class CharacterCount extends ConfigurableComponent {
979
907
  * @param {CharacterCountConfig} [config] - Character count config
980
908
  */
981
909
  constructor($root, config = {}) {
982
- var _ref, _this$config$maxwords;
910
+ var _this$config$maxlengt;
983
911
  super($root, config);
984
912
  this.$textarea = void 0;
913
+ this.count = 0;
914
+ this.segmenter = null;
985
915
  this.$visibleCountMessage = void 0;
986
916
  this.$screenReaderCountMessage = void 0;
987
917
  this.lastInputTimestamp = null;
@@ -1005,7 +935,15 @@ class CharacterCount extends ConfigurableComponent {
1005
935
  this.i18n = new I18n(this.config.i18n, {
1006
936
  locale: closestAttributeValue(this.$root, 'lang')
1007
937
  });
1008
- this.maxLength = (_ref = (_this$config$maxwords = this.config.maxwords) != null ? _this$config$maxwords : this.config.maxlength) != null ? _ref : Infinity;
938
+ if (this.config.countType === 'characters' || this.config.countType === 'words' && this.config.maxwords === undefined) {
939
+ if (!('Segmenter' in Intl)) {
940
+ throw new SupportError(formatErrorMessage(CharacterCount, 'Support for "Intl.Segmenter" required'));
941
+ }
942
+ this.segmenter = new Intl.Segmenter(this.i18n.locale, {
943
+ granularity: this.config.countType === 'words' ? 'word' : 'grapheme'
944
+ });
945
+ }
946
+ this.maxLength = (_this$config$maxlengt = this.config.maxlength) != null ? _this$config$maxlengt : Infinity;
1009
947
  this.$textarea = $textarea;
1010
948
  const textareaDescriptionId = `${this.$textarea.id}-info`;
1011
949
  const $textareaDescription = document.getElementById(textareaDescriptionId);
@@ -1017,35 +955,43 @@ class CharacterCount extends ConfigurableComponent {
1017
955
  });
1018
956
  }
1019
957
  this.$errorMessage = this.$root.querySelector('.govuk-error-message');
1020
- if (`${$textareaDescription.textContent}`.match(/^\s*$/)) {
958
+ if ($textareaDescription.textContent.match(/^\s*$/)) {
1021
959
  $textareaDescription.textContent = this.i18n.t('textareaDescription', {
1022
960
  count: this.maxLength
1023
961
  });
1024
962
  }
1025
963
  this.$textarea.insertAdjacentElement('afterend', $textareaDescription);
1026
- const $screenReaderCountMessage = document.createElement('div');
1027
- $screenReaderCountMessage.className = 'govuk-character-count__sr-status govuk-visually-hidden';
1028
- $screenReaderCountMessage.setAttribute('aria-live', 'polite');
964
+ const $screenReaderCountMessage = createElement('div', {
965
+ class: 'govuk-character-count__sr-status govuk-visually-hidden',
966
+ 'aria-live': 'polite'
967
+ });
1029
968
  this.$screenReaderCountMessage = $screenReaderCountMessage;
1030
969
  $textareaDescription.insertAdjacentElement('afterend', $screenReaderCountMessage);
1031
- const $visibleCountMessage = document.createElement('div');
1032
- $visibleCountMessage.className = $textareaDescription.className;
1033
- $visibleCountMessage.classList.add('govuk-character-count__status');
1034
- $visibleCountMessage.setAttribute('aria-hidden', 'true');
970
+ const $visibleCountMessage = createElement('div', {
971
+ class: `${$textareaDescription.className} govuk-character-count__status`,
972
+ 'aria-hidden': 'true'
973
+ });
1035
974
  this.$visibleCountMessage = $visibleCountMessage;
1036
975
  $textareaDescription.insertAdjacentElement('afterend', $visibleCountMessage);
1037
976
  $textareaDescription.classList.add('govuk-visually-hidden');
1038
977
  this.$textarea.removeAttribute('maxlength');
1039
978
  this.bindChangeEvents();
1040
- window.addEventListener('pageshow', () => this.updateCountMessage());
979
+ window.addEventListener('pageshow', () => {
980
+ if (this.$textarea.value !== this.$textarea.textContent) {
981
+ this.updateCount();
982
+ this.updateCountMessage();
983
+ }
984
+ });
985
+ this.updateCount();
1041
986
  this.updateCountMessage();
1042
987
  }
1043
988
  bindChangeEvents() {
1044
- this.$textarea.addEventListener('keyup', () => this.handleKeyUp());
989
+ this.$textarea.addEventListener('input', () => this.handleInput());
1045
990
  this.$textarea.addEventListener('focus', () => this.handleFocus());
1046
991
  this.$textarea.addEventListener('blur', () => this.handleBlur());
1047
992
  }
1048
- handleKeyUp() {
993
+ handleInput() {
994
+ this.updateCount();
1049
995
  this.updateVisibleCountMessage();
1050
996
  this.lastInputTimestamp = Date.now();
1051
997
  }
@@ -1072,7 +1018,7 @@ class CharacterCount extends ConfigurableComponent {
1072
1018
  this.updateScreenReaderCountMessage();
1073
1019
  }
1074
1020
  updateVisibleCountMessage() {
1075
- const remainingNumber = this.maxLength - this.count(this.$textarea.value);
1021
+ const remainingNumber = this.maxLength - this.count;
1076
1022
  const isError = remainingNumber < 0;
1077
1023
  this.$visibleCountMessage.classList.toggle('govuk-character-count__message--disabled', !this.isOverThreshold());
1078
1024
  if (!this.$errorMessage) {
@@ -1090,33 +1036,47 @@ class CharacterCount extends ConfigurableComponent {
1090
1036
  }
1091
1037
  this.$screenReaderCountMessage.textContent = this.getCountMessage();
1092
1038
  }
1093
- count(text) {
1094
- if (this.config.maxwords) {
1095
- var _text$match;
1096
- const tokens = (_text$match = text.match(/\S+/g)) != null ? _text$match : [];
1097
- return tokens.length;
1039
+ updateCount() {
1040
+ const text = this.$textarea.value;
1041
+ if (this.config.countType === 'characters') {
1042
+ this.count = this.segmenter ? Array.from(this.segmenter.segment(text)).length : 0;
1043
+ return;
1098
1044
  }
1099
- return text.length;
1045
+ if (this.config.countType === 'words') {
1046
+ if (this.config.maxwords !== undefined) {
1047
+ var _text$match$length, _text$match;
1048
+ this.count = (_text$match$length = (_text$match = text.match(/\S+/g)) == null ? void 0 : _text$match.length) != null ? _text$match$length : 0;
1049
+ return;
1050
+ }
1051
+ const segments = this.segmenter ? Array.from(this.segmenter.segment(text)) : [];
1052
+ this.count = segments.filter(segment => segment.isWordLike).length;
1053
+ return;
1054
+ }
1055
+ this.count = text.length;
1100
1056
  }
1101
1057
  getCountMessage() {
1102
- const remainingNumber = this.maxLength - this.count(this.$textarea.value);
1103
- const countType = this.config.maxwords ? 'words' : 'characters';
1104
- return this.formatCountMessage(remainingNumber, countType);
1058
+ const remainingNumber = this.maxLength - this.count;
1059
+ return this.formatCountMessage(remainingNumber);
1105
1060
  }
1106
1061
  formatCountMessage(remainingNumber, countType) {
1062
+ countType = countType != null ? countType : this.config.countType;
1063
+ let translationKeyPrefix = 'characters';
1064
+ let translationKeySuffix = remainingNumber < 0 ? 'OverLimit' : 'UnderLimit';
1065
+ if (countType === 'words') {
1066
+ translationKeyPrefix = 'words';
1067
+ }
1107
1068
  if (remainingNumber === 0) {
1108
- return this.i18n.t(`${countType}AtLimit`);
1069
+ translationKeySuffix = 'AtLimit';
1109
1070
  }
1110
- const translationKeySuffix = remainingNumber < 0 ? 'OverLimit' : 'UnderLimit';
1111
- return this.i18n.t(`${countType}${translationKeySuffix}`, {
1112
- count: Math.abs(remainingNumber)
1071
+ return this.i18n.t(`${translationKeyPrefix}${translationKeySuffix}`, {
1072
+ count: remainingNumber === 0 ? undefined : Math.abs(remainingNumber)
1113
1073
  });
1114
1074
  }
1115
1075
  isOverThreshold() {
1116
1076
  if (!this.config.threshold) {
1117
1077
  return true;
1118
1078
  }
1119
- const currentLength = this.count(this.$textarea.value);
1079
+ const currentLength = this.count;
1120
1080
  const maxLength = this.maxLength;
1121
1081
  const thresholdValue = maxLength * this.config.threshold / 100;
1122
1082
  return thresholdValue <= currentLength;
@@ -1128,13 +1088,15 @@ class CharacterCount extends ConfigurableComponent {
1128
1088
  *
1129
1089
  * @see {@link CharacterCount.defaults}
1130
1090
  * @typedef {object} CharacterCountConfig
1131
- * @property {number} [maxlength] - The maximum number of characters.
1132
- * If maxwords is provided, the maxlength option will be ignored.
1133
- * @property {number} [maxwords] - The maximum number of words. If maxwords is
1134
- * provided, the maxlength option will be ignored.
1091
+ * @property {number} [maxlength] - The maximum number of characters (or words
1092
+ * if `countType` is set to `"words"`).
1093
+ * @property {number} [maxwords] - Deprecated. Use `maxlength` and
1094
+ * `countType: "words"` instead.
1135
1095
  * @property {number} [threshold=0] - The percentage value of the limit at
1136
1096
  * which point the count message is displayed. If this attribute is set, the
1137
1097
  * count message will be hidden by default.
1098
+ * @property {'characters' | 'length' | 'words'} [countType] - The count type
1099
+ * (`"characters"`, `"length"` or `"words"`) used to count the text.
1138
1100
  * @property {CharacterCountTranslations} [i18n=CharacterCount.defaults.i18n] - Character count translations
1139
1101
  */
1140
1102
 
@@ -1180,9 +1142,9 @@ class CharacterCount extends ConfigurableComponent {
1180
1142
  * @property {TranslationPluralForms} [textareaDescription] - Message made
1181
1143
  * available to assistive technologies, if none is already present in the
1182
1144
  * HTML, to describe that the component accepts only a limited amount of
1183
- * content. It is visible on the page when JavaScript is unavailable. The
1184
- * component will replace the `%{count}` placeholder with the value of the
1185
- * `maxlength` or `maxwords` parameter.
1145
+ * content. It is visible on the page if `countType` is not supported or
1146
+ * JavaScript is unavailable. The component will replace the `%{count}`
1147
+ * placeholder with the value of the `maxlength` parameter.
1186
1148
  */
1187
1149
 
1188
1150
  /**
@@ -1192,6 +1154,7 @@ class CharacterCount extends ConfigurableComponent {
1192
1154
  CharacterCount.moduleName = 'govuk-character-count';
1193
1155
  CharacterCount.defaults = Object.freeze({
1194
1156
  threshold: 0,
1157
+ countType: 'length',
1195
1158
  i18n: {
1196
1159
  charactersUnderLimit: {
1197
1160
  one: 'You have %{count} character remaining',
@@ -1229,6 +1192,9 @@ CharacterCount.schema = Object.freeze({
1229
1192
  },
1230
1193
  threshold: {
1231
1194
  type: 'number'
1195
+ },
1196
+ countType: {
1197
+ type: 'string'
1232
1198
  }
1233
1199
  },
1234
1200
  anyOf: [{
@@ -1377,7 +1343,7 @@ class ErrorSummary extends ConfigurableComponent {
1377
1343
  if (!($target instanceof HTMLAnchorElement)) {
1378
1344
  return false;
1379
1345
  }
1380
- const inputId = getFragmentFromUrl($target.href);
1346
+ const inputId = $target.hash.replace('#', '');
1381
1347
  if (!inputId) {
1382
1348
  return false;
1383
1349
  }
@@ -1491,9 +1457,10 @@ class ExitThisPage extends ConfigurableComponent {
1491
1457
  window.addEventListener('pageshow', this.resetPage.bind(this));
1492
1458
  }
1493
1459
  initUpdateSpan() {
1494
- this.$updateSpan = document.createElement('span');
1495
- this.$updateSpan.setAttribute('role', 'status');
1496
- this.$updateSpan.className = 'govuk-visually-hidden';
1460
+ this.$updateSpan = createElement('span', {
1461
+ role: 'status',
1462
+ class: 'govuk-visually-hidden'
1463
+ });
1497
1464
  this.$root.appendChild(this.$updateSpan);
1498
1465
  }
1499
1466
  initButtonClickHandler() {
@@ -1503,13 +1470,14 @@ class ExitThisPage extends ConfigurableComponent {
1503
1470
  }
1504
1471
  }
1505
1472
  buildIndicator() {
1506
- this.$indicatorContainer = document.createElement('div');
1507
- this.$indicatorContainer.className = 'govuk-exit-this-page__indicator';
1508
- this.$indicatorContainer.setAttribute('aria-hidden', 'true');
1473
+ this.$indicatorContainer = createElement('div', {
1474
+ class: 'govuk-exit-this-page__indicator',
1475
+ 'aria-hidden': 'true'
1476
+ });
1509
1477
  for (let i = 0; i < 3; i++) {
1510
- const $indicator = document.createElement('div');
1511
- $indicator.className = 'govuk-exit-this-page__indicator-light';
1512
- this.$indicatorContainer.appendChild($indicator);
1478
+ this.$indicatorContainer.appendChild(createElement('div', {
1479
+ class: 'govuk-exit-this-page__indicator-light'
1480
+ }));
1513
1481
  }
1514
1482
  this.$button.appendChild(this.$indicatorContainer);
1515
1483
  }
@@ -1529,9 +1497,10 @@ class ExitThisPage extends ConfigurableComponent {
1529
1497
  }
1530
1498
  this.$updateSpan.textContent = '';
1531
1499
  document.body.classList.add('govuk-exit-this-page-hide-content');
1532
- this.$overlay = document.createElement('div');
1533
- this.$overlay.className = 'govuk-exit-this-page-overlay';
1534
- this.$overlay.setAttribute('role', 'alert');
1500
+ this.$overlay = createElement('div', {
1501
+ class: 'govuk-exit-this-page-overlay',
1502
+ role: 'alert'
1503
+ });
1535
1504
  document.body.appendChild(this.$overlay);
1536
1505
  this.$overlay.textContent = this.i18n.t('activated');
1537
1506
  window.location.href = this.$button.href;
@@ -1675,22 +1644,19 @@ class FileUpload extends ConfigurableComponent {
1675
1644
  this.$input = void 0;
1676
1645
  this.$button = void 0;
1677
1646
  this.$status = void 0;
1647
+ this.$label = void 0;
1678
1648
  this.i18n = void 0;
1679
1649
  this.id = void 0;
1680
1650
  this.$announcements = void 0;
1681
1651
  this.enteredAnotherElement = void 0;
1682
- const $input = this.$root.querySelector('input');
1652
+ const $input = this.$root.querySelector('input[type="file"]');
1683
1653
  if ($input === null) {
1684
1654
  throw new ElementError({
1685
1655
  component: FileUpload,
1686
1656
  identifier: 'File inputs (`<input type="file">`)'
1687
1657
  });
1688
1658
  }
1689
- if ($input.type !== 'file') {
1690
- throw new ElementError(formatErrorMessage(FileUpload, 'File input (`<input type="file">`) attribute (`type`) is not `file`'));
1691
- }
1692
1659
  this.$input = $input;
1693
- this.$input.setAttribute('hidden', 'true');
1694
1660
  if (!this.$input.id) {
1695
1661
  throw new ElementError({
1696
1662
  component: FileUpload,
@@ -1705,56 +1671,67 @@ class FileUpload extends ConfigurableComponent {
1705
1671
  if (!$label.id) {
1706
1672
  $label.id = `${this.id}-label`;
1707
1673
  }
1674
+ this.$label = $label;
1708
1675
  this.$input.id = `${this.id}-input`;
1709
- const $button = document.createElement('button');
1710
- $button.classList.add('govuk-file-upload-button');
1711
- $button.type = 'button';
1712
- $button.id = this.id;
1713
- $button.classList.add('govuk-file-upload-button--empty');
1676
+ this.$input.setAttribute('hidden', 'hidden');
1677
+ this.$status = this.createStatus();
1678
+ this.$button = this.createButton();
1679
+ this.$root.insertAdjacentElement('afterbegin', this.$button);
1680
+ this.$input.addEventListener('change', this.onChange.bind(this));
1681
+ this.updateDisabledState();
1682
+ this.observeDisabledState();
1683
+ this.$announcements = createElement('span', {
1684
+ class: 'govuk-file-upload-announcements govuk-visually-hidden',
1685
+ 'aria-live': 'assertive'
1686
+ });
1687
+ this.$root.insertAdjacentElement('afterend', this.$announcements);
1688
+ this.bindDraggingEvents();
1689
+ }
1690
+ createStatus() {
1691
+ const $status = createElement('span', {
1692
+ class: 'govuk-body govuk-file-upload-button__status',
1693
+ 'aria-live': 'polite'
1694
+ });
1695
+ $status.innerText = this.i18n.t('noFileChosen');
1696
+ return $status;
1697
+ }
1698
+ createButton() {
1699
+ const $button = createElement('button', {
1700
+ class: 'govuk-file-upload-button govuk-file-upload-button--empty',
1701
+ type: 'button',
1702
+ id: this.id
1703
+ });
1714
1704
  const ariaDescribedBy = this.$input.getAttribute('aria-describedby');
1715
1705
  if (ariaDescribedBy) {
1716
1706
  $button.setAttribute('aria-describedby', ariaDescribedBy);
1717
1707
  }
1718
- const $status = document.createElement('span');
1719
- $status.className = 'govuk-body govuk-file-upload-button__status';
1720
- $status.setAttribute('aria-live', 'polite');
1721
- $status.innerText = this.i18n.t('noFileChosen');
1722
- $button.appendChild($status);
1723
- const commaSpan = document.createElement('span');
1724
- commaSpan.className = 'govuk-visually-hidden';
1725
- commaSpan.innerText = ', ';
1726
- commaSpan.id = `${this.id}-comma`;
1708
+ $button.appendChild(this.$status);
1709
+ const commaSpan = createElement('span', {
1710
+ class: 'govuk-visually-hidden',
1711
+ id: `${this.id}-comma`
1712
+ }, [', ']);
1727
1713
  $button.appendChild(commaSpan);
1728
- const containerSpan = document.createElement('span');
1729
- containerSpan.className = 'govuk-file-upload-button__pseudo-button-container';
1730
- const buttonSpan = document.createElement('span');
1731
- buttonSpan.className = 'govuk-button govuk-button--secondary govuk-file-upload-button__pseudo-button';
1732
- buttonSpan.innerText = this.i18n.t('chooseFilesButton');
1714
+ const containerSpan = createElement('span', {
1715
+ class: 'govuk-file-upload-button__pseudo-button-container'
1716
+ });
1717
+ const buttonSpan = createElement('span', {
1718
+ class: 'govuk-button govuk-button--secondary govuk-file-upload-button__pseudo-button'
1719
+ }, [this.i18n.t('chooseFilesButton')]);
1733
1720
  containerSpan.appendChild(buttonSpan);
1734
1721
  containerSpan.insertAdjacentText('beforeend', ' ');
1735
- const instructionSpan = document.createElement('span');
1736
- instructionSpan.className = 'govuk-body govuk-file-upload-button__instruction';
1737
- instructionSpan.innerText = this.i18n.t('dropInstruction');
1722
+ const instructionSpan = createElement('span', {
1723
+ class: 'govuk-body govuk-file-upload-button__instruction'
1724
+ }, [this.i18n.t('dropInstruction')]);
1738
1725
  containerSpan.appendChild(instructionSpan);
1739
1726
  $button.appendChild(containerSpan);
1740
- $button.setAttribute('aria-labelledby', `${$label.id} ${commaSpan.id} ${$button.id}`);
1727
+ $button.setAttribute('aria-labelledby', `${this.$label.id} ${commaSpan.id} ${$button.id}`);
1741
1728
  $button.addEventListener('click', this.onClick.bind(this));
1742
1729
  $button.addEventListener('dragover', event => {
1743
1730
  event.preventDefault();
1744
1731
  });
1745
- this.$root.insertAdjacentElement('afterbegin', $button);
1746
- this.$input.setAttribute('tabindex', '-1');
1747
- this.$input.setAttribute('aria-hidden', 'true');
1748
- this.$button = $button;
1749
- this.$status = $status;
1750
- this.$input.addEventListener('change', this.onChange.bind(this));
1751
- this.updateDisabledState();
1752
- this.observeDisabledState();
1753
- this.$announcements = document.createElement('span');
1754
- this.$announcements.classList.add('govuk-file-upload-announcements');
1755
- this.$announcements.classList.add('govuk-visually-hidden');
1756
- this.$announcements.setAttribute('aria-live', 'assertive');
1757
- this.$root.insertAdjacentElement('afterend', this.$announcements);
1732
+ return $button;
1733
+ }
1734
+ bindDraggingEvents() {
1758
1735
  this.$button.addEventListener('drop', this.onDrop.bind(this));
1759
1736
  document.addEventListener('dragenter', this.updateDropzoneVisibility.bind(this));
1760
1737
  document.addEventListener('dragenter', () => {
@@ -1772,7 +1749,7 @@ class FileUpload extends ConfigurableComponent {
1772
1749
  if (this.$button.disabled) return;
1773
1750
  if (event.target instanceof Node) {
1774
1751
  if (this.$root.contains(event.target)) {
1775
- if (event.dataTransfer && isContainingFiles(event.dataTransfer)) {
1752
+ if (event.dataTransfer && this.canDrop(event.dataTransfer)) {
1776
1753
  if (!this.$button.classList.contains('govuk-file-upload-button--dragging')) {
1777
1754
  this.showDraggingState();
1778
1755
  this.$announcements.innerText = this.i18n.t('enteredDropZone');
@@ -1794,12 +1771,30 @@ class FileUpload extends ConfigurableComponent {
1794
1771
  }
1795
1772
  onDrop(event) {
1796
1773
  event.preventDefault();
1797
- if (event.dataTransfer && isContainingFiles(event.dataTransfer)) {
1774
+ if (event.dataTransfer && this.canFillInput(event.dataTransfer)) {
1798
1775
  this.$input.files = event.dataTransfer.files;
1799
1776
  this.$input.dispatchEvent(new CustomEvent('change'));
1800
1777
  this.hideDraggingState();
1801
1778
  }
1802
1779
  }
1780
+ canFillInput(dataTransfer) {
1781
+ return this.matchesInputCapacity(dataTransfer.files.length);
1782
+ }
1783
+ canDrop(dataTransfer) {
1784
+ if (dataTransfer.items.length) {
1785
+ return this.matchesInputCapacity(countFileItems(dataTransfer.items));
1786
+ }
1787
+ if (dataTransfer.types.length) {
1788
+ return dataTransfer.types.includes('Files');
1789
+ }
1790
+ return true;
1791
+ }
1792
+ matchesInputCapacity(numberOfFiles) {
1793
+ if (this.$input.multiple) {
1794
+ return numberOfFiles > 0;
1795
+ }
1796
+ return numberOfFiles === 1;
1797
+ }
1803
1798
  onChange() {
1804
1799
  const fileCount = this.$input.files.length;
1805
1800
  if (fileCount === 0) {
@@ -1843,9 +1838,16 @@ class FileUpload extends ConfigurableComponent {
1843
1838
  }
1844
1839
  updateDisabledState() {
1845
1840
  this.$button.disabled = this.$input.disabled;
1846
- this.$root.classList.toggle('govuk-drop-zone--disabled', this.$button.disabled);
1841
+ this.$root.classList.toggle('govuk-file-upload-wrapper--disabled', this.$button.disabled);
1847
1842
  }
1848
1843
  }
1844
+
1845
+ /**
1846
+ * Counts the number of `DataTransferItem` whose kind is `file`
1847
+ *
1848
+ * @param {DataTransferItemList} list - The list
1849
+ * @returns {number} - The number of items whose kind is `file` in the list
1850
+ */
1849
1851
  FileUpload.moduleName = 'govuk-file-upload';
1850
1852
  FileUpload.defaults = Object.freeze({
1851
1853
  i18n: {
@@ -1867,10 +1869,14 @@ FileUpload.schema = Object.freeze({
1867
1869
  }
1868
1870
  }
1869
1871
  });
1870
- function isContainingFiles(dataTransfer) {
1871
- const hasNoTypesInfo = dataTransfer.types.length === 0;
1872
- const isDraggingFiles = dataTransfer.types.some(type => type === 'Files');
1873
- return hasNoTypesInfo || isDraggingFiles;
1872
+ function countFileItems(list) {
1873
+ let result = 0;
1874
+ for (let i = 0; i < list.length; i++) {
1875
+ if (list[i].kind === 'file') {
1876
+ result++;
1877
+ }
1878
+ }
1879
+ return result;
1874
1880
  }
1875
1881
 
1876
1882
  /**
@@ -1908,89 +1914,6 @@ function isContainingFiles(dataTransfer) {
1908
1914
  * @import { TranslationPluralForms } from '../../i18n.mjs'
1909
1915
  */
1910
1916
 
1911
- /**
1912
- * Header component
1913
- *
1914
- * @preserve
1915
- */
1916
- class Header extends Component {
1917
- /**
1918
- * Apply a matchMedia for desktop which will trigger a state sync if the
1919
- * browser viewport moves between states.
1920
- *
1921
- * @param {Element | null} $root - HTML element to use for header
1922
- */
1923
- constructor($root) {
1924
- super($root);
1925
- this.$menuButton = void 0;
1926
- this.$menu = void 0;
1927
- this.menuIsOpen = false;
1928
- this.mql = null;
1929
- const $menuButton = this.$root.querySelector('.govuk-js-header-toggle');
1930
- if (!$menuButton) {
1931
- return this;
1932
- }
1933
- this.$root.classList.add('govuk-header--with-js-navigation');
1934
- const menuId = $menuButton.getAttribute('aria-controls');
1935
- if (!menuId) {
1936
- throw new ElementError({
1937
- component: Header,
1938
- identifier: 'Navigation button (`<button class="govuk-js-header-toggle">`) attribute (`aria-controls`)'
1939
- });
1940
- }
1941
- const $menu = document.getElementById(menuId);
1942
- if (!$menu) {
1943
- throw new ElementError({
1944
- component: Header,
1945
- element: $menu,
1946
- identifier: `Navigation (\`<ul id="${menuId}">\`)`
1947
- });
1948
- }
1949
- this.$menu = $menu;
1950
- this.$menuButton = $menuButton;
1951
- this.setupResponsiveChecks();
1952
- this.$menuButton.addEventListener('click', () => this.handleMenuButtonClick());
1953
- }
1954
- setupResponsiveChecks() {
1955
- const breakpoint = getBreakpoint('desktop');
1956
- if (!breakpoint.value) {
1957
- throw new ElementError({
1958
- component: Header,
1959
- identifier: `CSS custom property (\`${breakpoint.property}\`) on pseudo-class \`:root\``
1960
- });
1961
- }
1962
- this.mql = window.matchMedia(`(min-width: ${breakpoint.value})`);
1963
- if ('addEventListener' in this.mql) {
1964
- this.mql.addEventListener('change', () => this.checkMode());
1965
- } else {
1966
- this.mql.addListener(() => this.checkMode());
1967
- }
1968
- this.checkMode();
1969
- }
1970
- checkMode() {
1971
- if (!this.mql || !this.$menu || !this.$menuButton) {
1972
- return;
1973
- }
1974
- if (this.mql.matches) {
1975
- this.$menu.removeAttribute('hidden');
1976
- this.$menuButton.setAttribute('hidden', '');
1977
- } else {
1978
- this.$menuButton.removeAttribute('hidden');
1979
- this.$menuButton.setAttribute('aria-expanded', this.menuIsOpen.toString());
1980
- if (this.menuIsOpen) {
1981
- this.$menu.removeAttribute('hidden');
1982
- } else {
1983
- this.$menu.setAttribute('hidden', '');
1984
- }
1985
- }
1986
- }
1987
- handleMenuButtonClick() {
1988
- this.menuIsOpen = !this.menuIsOpen;
1989
- this.checkMode();
1990
- }
1991
- }
1992
- Header.moduleName = 'govuk-header';
1993
-
1994
1917
  /**
1995
1918
  * Notification Banner component
1996
1919
  *
@@ -2082,9 +2005,10 @@ class PasswordInput extends ConfigurableComponent {
2082
2005
  locale: closestAttributeValue(this.$root, 'lang')
2083
2006
  });
2084
2007
  this.$showHideButton.removeAttribute('hidden');
2085
- const $screenReaderStatusMessage = document.createElement('div');
2086
- $screenReaderStatusMessage.className = 'govuk-password-input__sr-status govuk-visually-hidden';
2087
- $screenReaderStatusMessage.setAttribute('aria-live', 'polite');
2008
+ const $screenReaderStatusMessage = createElement('div', {
2009
+ class: 'govuk-password-input__sr-status govuk-visually-hidden',
2010
+ 'aria-live': 'polite'
2011
+ });
2088
2012
  this.$screenReaderStatusMessage = $screenReaderStatusMessage;
2089
2013
  this.$input.insertAdjacentElement('afterend', $screenReaderStatusMessage);
2090
2014
  this.$showHideButton.addEventListener('click', this.toggle.bind(this));
@@ -2322,9 +2246,9 @@ class ServiceNavigation extends Component {
2322
2246
  }
2323
2247
  if (this.mql.matches) {
2324
2248
  this.$menu.removeAttribute('hidden');
2325
- this.$menuButton.setAttribute('hidden', '');
2249
+ setAttributes(this.$menuButton, attributesForHidingButton);
2326
2250
  } else {
2327
- this.$menuButton.removeAttribute('hidden');
2251
+ removeAttributes(this.$menuButton, Object.keys(attributesForHidingButton));
2328
2252
  this.$menuButton.setAttribute('aria-expanded', this.menuIsOpen.toString());
2329
2253
  if (this.menuIsOpen) {
2330
2254
  this.$menu.removeAttribute('hidden');
@@ -2339,7 +2263,36 @@ class ServiceNavigation extends Component {
2339
2263
  }
2340
2264
  }
2341
2265
  ServiceNavigation.moduleName = 'govuk-service-navigation';
2266
+ const attributesForHidingButton = {
2267
+ hidden: '',
2268
+ 'aria-hidden': 'true'
2269
+ };
2342
2270
 
2271
+ /**
2272
+ * Sets a group of attributes on the given element
2273
+ *
2274
+ * @param {Element} $element - The element to set the attribute on
2275
+ * @param {{[attributeName: string]: string}} attributes - The attributes to set
2276
+ */
2277
+ function setAttributes($element, attributes) {
2278
+ for (const attributeName in attributes) {
2279
+ $element.setAttribute(attributeName, attributes[attributeName]);
2280
+ }
2281
+ }
2282
+
2283
+ /**
2284
+ * Removes a list of attributes from the given element
2285
+ *
2286
+ * @param {Element} $element - The element to remove the attributes from
2287
+ * @param {string[]} attributeNames - The names of the attributes to remove
2288
+ */
2289
+ function removeAttributes($element, attributeNames) {
2290
+ for (const attributeName of attributeNames) {
2291
+ $element.removeAttribute(attributeName);
2292
+ }
2293
+ }
2294
+
2295
+ const _self = typeof globalThis !== 'undefined' ? globalThis : self;
2343
2296
  /**
2344
2297
  * Skip link component
2345
2298
  *
@@ -2358,16 +2311,10 @@ class SkipLink extends Component {
2358
2311
  super($root);
2359
2312
  const hash = this.$root.hash;
2360
2313
  const href = (_this$$root$getAttrib = this.$root.getAttribute('href')) != null ? _this$$root$getAttrib : '';
2361
- let url;
2362
- try {
2363
- url = new window.URL(this.$root.href);
2364
- } catch (error) {
2365
- throw new ElementError(`Skip link: Target link (\`href="${href}"\`) is invalid`);
2366
- }
2367
- if (url.origin !== window.location.origin || url.pathname !== window.location.pathname) {
2314
+ if (this.$root.origin !== window.location.origin || this.$root.pathname !== window.location.pathname) {
2368
2315
  return;
2369
2316
  }
2370
- const linkedElementId = getFragmentFromUrl(hash);
2317
+ const linkedElementId = hash.replace('#', '');
2371
2318
  if (!linkedElementId) {
2372
2319
  throw new ElementError(`Skip link: Target link (\`href="${href}"\`) has no hash fragment`);
2373
2320
  }
@@ -2389,7 +2336,7 @@ class SkipLink extends Component {
2389
2336
  }));
2390
2337
  }
2391
2338
  }
2392
- SkipLink.elementType = HTMLAnchorElement;
2339
+ SkipLink.elementType = _self.HTMLAnchorElement;
2393
2340
  SkipLink.moduleName = 'govuk-skip-link';
2394
2341
 
2395
2342
  /**
@@ -2523,7 +2470,7 @@ class Tabs extends Component {
2523
2470
  return this.$root.querySelector(`a.govuk-tabs__tab[href="${hash}"]`);
2524
2471
  }
2525
2472
  setAttributes($tab) {
2526
- const panelId = getFragmentFromUrl($tab.href);
2473
+ const panelId = $tab.hash.replace('#', '');
2527
2474
  if (!panelId) {
2528
2475
  return;
2529
2476
  }
@@ -2627,7 +2574,7 @@ class Tabs extends Component {
2627
2574
  this.createHistoryEntry($previousTab);
2628
2575
  }
2629
2576
  getPanel($tab) {
2630
- const panelId = getFragmentFromUrl($tab.href);
2577
+ const panelId = $tab.hash.replace('#', '');
2631
2578
  if (!panelId) {
2632
2579
  return null;
2633
2580
  }
@@ -2675,28 +2622,34 @@ Tabs.moduleName = 'govuk-tabs';
2675
2622
  * Use the `data-module` attributes to find, instantiate and init all of the
2676
2623
  * components provided as part of GOV.UK Frontend.
2677
2624
  *
2678
- * @param {Config & { scope?: Element, onError?: OnErrorCallback<CompatibleClass> }} [config] - Config for all components (with optional scope)
2625
+ * @param {Config | Element | Document | null} [scopeOrConfig] - Scope of the document to search within or config for all components (with optional scope)
2679
2626
  */
2680
- function initAll(config) {
2681
- var _config$scope;
2682
- config = typeof config !== 'undefined' ? config : {};
2683
- if (!isSupported()) {
2684
- if (config.onError) {
2685
- config.onError(new SupportError(), {
2627
+ function initAll(scopeOrConfig = {}) {
2628
+ const config = isObject(scopeOrConfig) ? scopeOrConfig : {};
2629
+ const options = normaliseOptions(scopeOrConfig);
2630
+ try {
2631
+ if (!isSupported()) {
2632
+ throw new SupportError();
2633
+ }
2634
+ if (options.scope === null) {
2635
+ throw new ElementError({
2636
+ element: options.scope,
2637
+ identifier: 'GOV.UK Frontend scope element (`$scope`)'
2638
+ });
2639
+ }
2640
+ } catch (error) {
2641
+ if (options.onError) {
2642
+ options.onError(error, {
2686
2643
  config
2687
2644
  });
2688
2645
  } else {
2689
- console.log(new SupportError());
2646
+ console.log(error);
2690
2647
  }
2691
2648
  return;
2692
2649
  }
2693
- const components = [[Accordion, config.accordion], [Button, config.button], [CharacterCount, config.characterCount], [Checkboxes], [ErrorSummary, config.errorSummary], [ExitThisPage, config.exitThisPage], [FileUpload, config.fileUpload], [Header], [NotificationBanner, config.notificationBanner], [PasswordInput, config.passwordInput], [Radios], [ServiceNavigation], [SkipLink], [Tabs]];
2694
- const options = {
2695
- scope: (_config$scope = config.scope) != null ? _config$scope : document,
2696
- onError: config.onError
2697
- };
2698
- components.forEach(([Component, config]) => {
2699
- createAll(Component, config, options);
2650
+ const components = [[Accordion, config.accordion], [Button, config.button], [CharacterCount, config.characterCount], [Checkboxes], [ErrorSummary, config.errorSummary], [ExitThisPage, config.exitThisPage], [FileUpload, config.fileUpload], [NotificationBanner, config.notificationBanner], [PasswordInput, config.passwordInput], [Radios], [ServiceNavigation], [SkipLink], [Tabs]];
2651
+ components.forEach(([Component, componentConfig]) => {
2652
+ createAll(Component, componentConfig, options);
2700
2653
  });
2701
2654
  }
2702
2655
 
@@ -2712,42 +2665,42 @@ function initAll(config) {
2712
2665
  * @template {CompatibleClass} ComponentClass
2713
2666
  * @param {ComponentClass} Component - class of the component to create
2714
2667
  * @param {ComponentConfig<ComponentClass>} [config] - Config supplied to component
2715
- * @param {OnErrorCallback<ComponentClass> | Element | Document | CreateAllOptions<ComponentClass> } [createAllOptions] - options for createAll including scope of the document to search within and callback function if error throw by component on init
2668
+ * @param {OnErrorCallback<ComponentClass> | Element | Document | null | CreateAllOptions<ComponentClass>} [scopeOrOptions] - options for createAll including scope of the document to search within and callback function if error throw by component on init
2716
2669
  * @returns {Array<InstanceType<ComponentClass>>} - array of instantiated components
2717
2670
  */
2718
- function createAll(Component, config, createAllOptions) {
2719
- let $scope = document;
2720
- let onError;
2721
- if (typeof createAllOptions === 'object') {
2722
- var _createAllOptions$sco;
2723
- createAllOptions = createAllOptions;
2724
- $scope = (_createAllOptions$sco = createAllOptions.scope) != null ? _createAllOptions$sco : $scope;
2725
- onError = createAllOptions.onError;
2726
- }
2727
- if (typeof createAllOptions === 'function') {
2728
- onError = createAllOptions;
2729
- }
2730
- if (createAllOptions instanceof HTMLElement) {
2731
- $scope = createAllOptions;
2732
- }
2733
- const $elements = $scope.querySelectorAll(`[data-module="${Component.moduleName}"]`);
2734
- if (!isSupported()) {
2735
- if (onError) {
2736
- onError(new SupportError(), {
2671
+ function createAll(Component, config, scopeOrOptions) {
2672
+ let $elements;
2673
+ const options = normaliseOptions(scopeOrOptions);
2674
+ try {
2675
+ var _options$scope;
2676
+ if (!isSupported()) {
2677
+ throw new SupportError();
2678
+ }
2679
+ if (options.scope === null) {
2680
+ throw new ElementError({
2681
+ element: options.scope,
2682
+ component: Component,
2683
+ identifier: 'Scope element (`$scope`)'
2684
+ });
2685
+ }
2686
+ $elements = (_options$scope = options.scope) == null ? void 0 : _options$scope.querySelectorAll(`[data-module="${Component.moduleName}"]`);
2687
+ } catch (error) {
2688
+ if (options.onError) {
2689
+ options.onError(error, {
2737
2690
  component: Component,
2738
2691
  config
2739
2692
  });
2740
2693
  } else {
2741
- console.log(new SupportError());
2694
+ console.log(error);
2742
2695
  }
2743
2696
  return [];
2744
2697
  }
2745
- return Array.from($elements).map($element => {
2698
+ return Array.from($elements != null ? $elements : []).map($element => {
2746
2699
  try {
2747
2700
  return typeof config !== 'undefined' ? new Component($element, config) : new Component($element);
2748
2701
  } catch (error) {
2749
- if (onError) {
2750
- onError(error, {
2702
+ if (options.onError) {
2703
+ options.onError(error, {
2751
2704
  element: $element,
2752
2705
  component: Component,
2753
2706
  config
@@ -2766,14 +2719,16 @@ function createAll(Component, config, createAllOptions) {
2766
2719
  * Config for all components via `initAll()`
2767
2720
  *
2768
2721
  * @typedef {object} Config
2769
- * @property {AccordionConfig} [accordion] - Accordion config
2770
- * @property {ButtonConfig} [button] - Button config
2771
- * @property {CharacterCountConfig} [characterCount] - Character Count config
2772
- * @property {ErrorSummaryConfig} [errorSummary] - Error Summary config
2773
- * @property {ExitThisPageConfig} [exitThisPage] - Exit This Page config
2774
- * @property {FileUploadConfig} [fileUpload] - File Upload config
2775
- * @property {NotificationBannerConfig} [notificationBanner] - Notification Banner config
2776
- * @property {PasswordInputConfig} [passwordInput] - Password input config
2722
+ * @property {Element | Document | null} [scope] - Scope of the document to search within
2723
+ * @property {OnErrorCallback<CompatibleClass>} [onError] - Initialisation error callback
2724
+ * @property {ComponentConfig<typeof Accordion>} [accordion] - Accordion config
2725
+ * @property {ComponentConfig<typeof Button>} [button] - Button config
2726
+ * @property {ComponentConfig<typeof CharacterCount>} [characterCount] - Character Count config
2727
+ * @property {ComponentConfig<typeof ErrorSummary>} [errorSummary] - Error Summary config
2728
+ * @property {ComponentConfig<typeof ExitThisPage>} [exitThisPage] - Exit This Page config
2729
+ * @property {ComponentConfig<typeof FileUpload>} [fileUpload] - File Upload config
2730
+ * @property {ComponentConfig<typeof NotificationBanner>} [notificationBanner] - Notification Banner config
2731
+ * @property {ComponentConfig<typeof PasswordInput>} [passwordInput] - Password input config
2777
2732
  */
2778
2733
  /**
2779
2734
  * Config for individual components
@@ -2790,7 +2745,7 @@ function createAll(Component, config, createAllOptions) {
2790
2745
  /**
2791
2746
  * Component config keys, e.g. `accordion` and `characterCount`
2792
2747
  *
2793
- * @typedef {keyof Config} ConfigKey
2748
+ * @typedef {keyof Omit<Config, 'scope' | 'onError'>} ConfigKey
2794
2749
  */
2795
2750
  /**
2796
2751
  * @template {CompatibleClass} ComponentClass
@@ -2801,7 +2756,7 @@ function createAll(Component, config, createAllOptions) {
2801
2756
  * @typedef {object} ErrorContext
2802
2757
  * @property {Element} [element] - Element used for component module initialisation
2803
2758
  * @property {ComponentClass} [component] - Class of component
2804
- * @property {ComponentConfig<ComponentClass>} config - Config supplied to component
2759
+ * @property {Config | ComponentConfig<ComponentClass>} [config] - Config supplied to components
2805
2760
  */
2806
2761
  /**
2807
2762
  * @template {CompatibleClass} ComponentClass
@@ -2812,9 +2767,9 @@ function createAll(Component, config, createAllOptions) {
2812
2767
  /**
2813
2768
  * @template {CompatibleClass} ComponentClass
2814
2769
  * @typedef {object} CreateAllOptions
2815
- * @property {Element | Document} [scope] - scope of the document to search within
2770
+ * @property {Element | Document | null} [scope] - scope of the document to search within
2816
2771
  * @property {OnErrorCallback<ComponentClass>} [onError] - callback function if error throw by component on init
2817
2772
  */
2818
2773
 
2819
- export { Accordion, Button, CharacterCount, Checkboxes, Component, ConfigurableComponent, ErrorSummary, ExitThisPage, FileUpload, Header, NotificationBanner, PasswordInput, Radios, ServiceNavigation, SkipLink, Tabs, createAll, initAll, isSupported, version };
2774
+ export { Accordion, Button, CharacterCount, Checkboxes, Component, ConfigurableComponent, ErrorSummary, ExitThisPage, FileUpload, NotificationBanner, PasswordInput, Radios, ServiceNavigation, SkipLink, Tabs, createAll, initAll, isSupported, version };
2820
2775
  //# sourceMappingURL=all.bundle.mjs.map