govuk_publishing_components 34.12.0 → 34.13.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (151) hide show
  1. checksums.yaml +4 -4
  2. data/app/assets/config/govuk_publishing_components_manifest.js +75 -0
  3. data/app/assets/stylesheets/govuk_publishing_components/_individual_component_support.scss +10 -0
  4. data/app/assets/stylesheets/govuk_publishing_components/components/_accordion.scss +1 -0
  5. data/app/assets/stylesheets/govuk_publishing_components/components/_action-link.scss +2 -0
  6. data/app/assets/stylesheets/govuk_publishing_components/components/_attachment.scss +2 -0
  7. data/app/assets/stylesheets/govuk_publishing_components/components/_back-link.scss +1 -0
  8. data/app/assets/stylesheets/govuk_publishing_components/components/_big-number.scss +2 -0
  9. data/app/assets/stylesheets/govuk_publishing_components/components/_breadcrumbs.scss +1 -0
  10. data/app/assets/stylesheets/govuk_publishing_components/components/_button.scss +1 -0
  11. data/app/assets/stylesheets/govuk_publishing_components/components/_cards.scss +1 -0
  12. data/app/assets/stylesheets/govuk_publishing_components/components/_character-count.scss +1 -0
  13. data/app/assets/stylesheets/govuk_publishing_components/components/_checkboxes.scss +1 -0
  14. data/app/assets/stylesheets/govuk_publishing_components/components/_contents-list.scss +1 -0
  15. data/app/assets/stylesheets/govuk_publishing_components/components/_contextual-guidance.scss +2 -0
  16. data/app/assets/stylesheets/govuk_publishing_components/components/_contextual-sidebar.scss +2 -0
  17. data/app/assets/stylesheets/govuk_publishing_components/components/_cookie-banner.scss +1 -0
  18. data/app/assets/stylesheets/govuk_publishing_components/components/_date-input.scss +1 -0
  19. data/app/assets/stylesheets/govuk_publishing_components/components/_details.scss +1 -0
  20. data/app/assets/stylesheets/govuk_publishing_components/components/_devolved-nations.scss +2 -0
  21. data/app/assets/stylesheets/govuk_publishing_components/components/_document-list.scss +2 -0
  22. data/app/assets/stylesheets/govuk_publishing_components/components/_emergency-banner.scss +2 -0
  23. data/app/assets/stylesheets/govuk_publishing_components/components/_error-alert.scss +2 -0
  24. data/app/assets/stylesheets/govuk_publishing_components/components/_error-message.scss +1 -0
  25. data/app/assets/stylesheets/govuk_publishing_components/components/_error-summary.scss +1 -0
  26. data/app/assets/stylesheets/govuk_publishing_components/components/_feedback.scss +2 -0
  27. data/app/assets/stylesheets/govuk_publishing_components/components/_fieldset.scss +1 -0
  28. data/app/assets/stylesheets/govuk_publishing_components/components/_file-upload.scss +1 -0
  29. data/app/assets/stylesheets/govuk_publishing_components/components/_govspeak-html-publication.scss +2 -0
  30. data/app/assets/stylesheets/govuk_publishing_components/components/_govspeak.scss +2 -0
  31. data/app/assets/stylesheets/govuk_publishing_components/components/_heading.scss +2 -0
  32. data/app/assets/stylesheets/govuk_publishing_components/components/_hint.scss +1 -0
  33. data/app/assets/stylesheets/govuk_publishing_components/components/_image-card.scss +2 -0
  34. data/app/assets/stylesheets/govuk_publishing_components/components/_input.scss +2 -0
  35. data/app/assets/stylesheets/govuk_publishing_components/components/_inset-text.scss +1 -0
  36. data/app/assets/stylesheets/govuk_publishing_components/components/_intervention.scss +2 -0
  37. data/app/assets/stylesheets/govuk_publishing_components/components/_inverse-header.scss +2 -0
  38. data/app/assets/stylesheets/govuk_publishing_components/components/_label.scss +1 -0
  39. data/app/assets/stylesheets/govuk_publishing_components/components/_layout-footer.scss +1 -0
  40. data/app/assets/stylesheets/govuk_publishing_components/components/_layout-for-public.scss +2 -0
  41. data/app/assets/stylesheets/govuk_publishing_components/components/_layout-super-navigation-header.scss +1 -0
  42. data/app/assets/stylesheets/govuk_publishing_components/components/_lead-paragraph.scss +2 -0
  43. data/app/assets/stylesheets/govuk_publishing_components/components/_metadata.scss +2 -0
  44. data/app/assets/stylesheets/govuk_publishing_components/components/_modal-dialogue.scss +2 -0
  45. data/app/assets/stylesheets/govuk_publishing_components/components/_notice.scss +1 -0
  46. data/app/assets/stylesheets/govuk_publishing_components/components/_organisation-logo.scss +2 -0
  47. data/app/assets/stylesheets/govuk_publishing_components/components/_panel.scss +1 -0
  48. data/app/assets/stylesheets/govuk_publishing_components/components/_phase-banner.scss +1 -0
  49. data/app/assets/stylesheets/govuk_publishing_components/components/_previous-and-next-navigation.scss +1 -0
  50. data/app/assets/stylesheets/govuk_publishing_components/components/_print-link.scss +2 -0
  51. data/app/assets/stylesheets/govuk_publishing_components/components/_radio.scss +1 -0
  52. data/app/assets/stylesheets/govuk_publishing_components/components/_related-navigation.scss +2 -0
  53. data/app/assets/stylesheets/govuk_publishing_components/components/_reorderable-list.scss +2 -0
  54. data/app/assets/stylesheets/govuk_publishing_components/components/_search.scss +2 -0
  55. data/app/assets/stylesheets/govuk_publishing_components/components/_select.scss +1 -0
  56. data/app/assets/stylesheets/govuk_publishing_components/components/_share-links.scss +2 -0
  57. data/app/assets/stylesheets/govuk_publishing_components/components/_show-password.scss +2 -0
  58. data/app/assets/stylesheets/govuk_publishing_components/components/_signup-link.scss +2 -0
  59. data/app/assets/stylesheets/govuk_publishing_components/components/_single-page-notification-button.scss +2 -0
  60. data/app/assets/stylesheets/govuk_publishing_components/components/_skip-link.scss +1 -0
  61. data/app/assets/stylesheets/govuk_publishing_components/components/_step-by-step-nav-header.scss +2 -0
  62. data/app/assets/stylesheets/govuk_publishing_components/components/_step-by-step-nav-related.scss +2 -0
  63. data/app/assets/stylesheets/govuk_publishing_components/components/_step-by-step-nav.scss +2 -0
  64. data/app/assets/stylesheets/govuk_publishing_components/components/_subscription-links.scss +2 -0
  65. data/app/assets/stylesheets/govuk_publishing_components/components/_success-alert.scss +1 -0
  66. data/app/assets/stylesheets/govuk_publishing_components/components/_summary-list.scss +1 -0
  67. data/app/assets/stylesheets/govuk_publishing_components/components/_table.scss +1 -0
  68. data/app/assets/stylesheets/govuk_publishing_components/components/_tabs.scss +1 -0
  69. data/app/assets/stylesheets/govuk_publishing_components/components/_textarea.scss +1 -0
  70. data/app/assets/stylesheets/govuk_publishing_components/components/_title.scss +2 -0
  71. data/app/assets/stylesheets/govuk_publishing_components/components/_translation-nav.scss +2 -0
  72. data/app/assets/stylesheets/govuk_publishing_components/components/_warning-text.scss +1 -0
  73. data/app/views/govuk_publishing_components/components/_accordion.html.erb +2 -0
  74. data/app/views/govuk_publishing_components/components/_action_link.html.erb +2 -0
  75. data/app/views/govuk_publishing_components/components/_attachment.html.erb +2 -0
  76. data/app/views/govuk_publishing_components/components/_attachment_link.html.erb +2 -0
  77. data/app/views/govuk_publishing_components/components/_back_link.html.erb +2 -0
  78. data/app/views/govuk_publishing_components/components/_big_number.html.erb +3 -1
  79. data/app/views/govuk_publishing_components/components/_breadcrumbs.html.erb +2 -0
  80. data/app/views/govuk_publishing_components/components/_button.html.erb +2 -0
  81. data/app/views/govuk_publishing_components/components/_cards.html.erb +2 -0
  82. data/app/views/govuk_publishing_components/components/_character_count.html.erb +2 -0
  83. data/app/views/govuk_publishing_components/components/_checkboxes.html.erb +2 -0
  84. data/app/views/govuk_publishing_components/components/_contents_list.html.erb +2 -0
  85. data/app/views/govuk_publishing_components/components/_contextual_guidance.html.erb +2 -0
  86. data/app/views/govuk_publishing_components/components/_contextual_sidebar.html.erb +2 -0
  87. data/app/views/govuk_publishing_components/components/_cookie_banner.html.erb +2 -0
  88. data/app/views/govuk_publishing_components/components/_date_input.html.erb +2 -0
  89. data/app/views/govuk_publishing_components/components/_details.html.erb +2 -0
  90. data/app/views/govuk_publishing_components/components/_devolved_nations.html.erb +2 -0
  91. data/app/views/govuk_publishing_components/components/_document_list.html.erb +2 -0
  92. data/app/views/govuk_publishing_components/components/_emergency_banner.html.erb +2 -0
  93. data/app/views/govuk_publishing_components/components/_error_alert.html.erb +2 -0
  94. data/app/views/govuk_publishing_components/components/_error_message.html.erb +2 -0
  95. data/app/views/govuk_publishing_components/components/_error_summary.html.erb +2 -0
  96. data/app/views/govuk_publishing_components/components/_feedback.html.erb +2 -0
  97. data/app/views/govuk_publishing_components/components/_fieldset.html.erb +2 -0
  98. data/app/views/govuk_publishing_components/components/_file_upload.html.erb +2 -0
  99. data/app/views/govuk_publishing_components/components/_govspeak.html.erb +1 -0
  100. data/app/views/govuk_publishing_components/components/_govspeak_html_publication.html.erb +2 -0
  101. data/app/views/govuk_publishing_components/components/_heading.html.erb +2 -0
  102. data/app/views/govuk_publishing_components/components/_hint.html.erb +2 -0
  103. data/app/views/govuk_publishing_components/components/_image_card.html.erb +5 -3
  104. data/app/views/govuk_publishing_components/components/_input.html.erb +2 -0
  105. data/app/views/govuk_publishing_components/components/_inset_text.html.erb +2 -0
  106. data/app/views/govuk_publishing_components/components/_intervention.html.erb +2 -0
  107. data/app/views/govuk_publishing_components/components/_inverse_header.html.erb +2 -0
  108. data/app/views/govuk_publishing_components/components/_label.html.erb +2 -0
  109. data/app/views/govuk_publishing_components/components/_layout_footer.html.erb +2 -0
  110. data/app/views/govuk_publishing_components/components/_layout_for_admin.html.erb +5 -1
  111. data/app/views/govuk_publishing_components/components/_layout_for_public.html.erb +2 -0
  112. data/app/views/govuk_publishing_components/components/_layout_header.html.erb +2 -0
  113. data/app/views/govuk_publishing_components/components/_layout_super_navigation_header.html.erb +2 -0
  114. data/app/views/govuk_publishing_components/components/_lead_paragraph.html.erb +2 -0
  115. data/app/views/govuk_publishing_components/components/_metadata.html.erb +2 -0
  116. data/app/views/govuk_publishing_components/components/_modal_dialogue.html.erb +2 -0
  117. data/app/views/govuk_publishing_components/components/_notice.html.erb +2 -0
  118. data/app/views/govuk_publishing_components/components/_organisation_logo.html.erb +2 -0
  119. data/app/views/govuk_publishing_components/components/_panel.html.erb +2 -0
  120. data/app/views/govuk_publishing_components/components/_phase_banner.html.erb +2 -0
  121. data/app/views/govuk_publishing_components/components/_previous_and_next_navigation.html.erb +6 -1
  122. data/app/views/govuk_publishing_components/components/_print_link.html.erb +2 -0
  123. data/app/views/govuk_publishing_components/components/_radio.html.erb +2 -0
  124. data/app/views/govuk_publishing_components/components/_related_navigation.html.erb +4 -0
  125. data/app/views/govuk_publishing_components/components/_reorderable_list.html.erb +2 -0
  126. data/app/views/govuk_publishing_components/components/_search.html.erb +2 -0
  127. data/app/views/govuk_publishing_components/components/_select.html.erb +2 -0
  128. data/app/views/govuk_publishing_components/components/_share_links.html.erb +2 -0
  129. data/app/views/govuk_publishing_components/components/_show_password.html.erb +2 -0
  130. data/app/views/govuk_publishing_components/components/_signup_link.html.erb +2 -0
  131. data/app/views/govuk_publishing_components/components/_single_page_notification_button.html.erb +2 -0
  132. data/app/views/govuk_publishing_components/components/_skip_link.html.erb +2 -0
  133. data/app/views/govuk_publishing_components/components/_step_by_step_nav.html.erb +2 -0
  134. data/app/views/govuk_publishing_components/components/_step_by_step_nav_header.html.erb +3 -1
  135. data/app/views/govuk_publishing_components/components/_step_by_step_nav_related.html.erb +2 -0
  136. data/app/views/govuk_publishing_components/components/_subscription_links.html.erb +2 -0
  137. data/app/views/govuk_publishing_components/components/_success_alert.html.erb +2 -0
  138. data/app/views/govuk_publishing_components/components/_summary_list.html.erb +2 -0
  139. data/app/views/govuk_publishing_components/components/_table.html.erb +3 -1
  140. data/app/views/govuk_publishing_components/components/_tabs.html.erb +2 -0
  141. data/app/views/govuk_publishing_components/components/_textarea.html.erb +2 -0
  142. data/app/views/govuk_publishing_components/components/_title.html.erb +2 -0
  143. data/app/views/govuk_publishing_components/components/_translation_nav.html.erb +2 -0
  144. data/app/views/govuk_publishing_components/components/_warning_text.html.erb +2 -0
  145. data/lib/govuk_publishing_components/app_helpers/asset_helper.rb +86 -0
  146. data/lib/govuk_publishing_components/config.rb +3 -0
  147. data/lib/govuk_publishing_components/presenters/related_navigation_helper.rb +1 -1
  148. data/lib/govuk_publishing_components/railtie.rb +7 -0
  149. data/lib/govuk_publishing_components/version.rb +1 -1
  150. data/lib/govuk_publishing_components.rb +3 -0
  151. metadata +5 -2
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("breadcrumbs")
3
+
2
4
  border ||= false
3
5
  breadcrumbs ||= []
4
6
  collapse_on_mobile ||= false
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("button")
3
+
2
4
  # button_helper.css_classes generates "gem-c-button"
3
5
  shared_helper = GovukPublishingComponents::Presenters::SharedHelper.new(local_assigns)
4
6
  local_assigns[:classes] = shared_helper.classes
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("cards")
3
+
2
4
  heading ||= nil
3
5
  items ||= nil
4
6
  sub_heading_level ||= 3
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("character-count")
3
+
2
4
  id ||= "character-count-#{SecureRandom.hex(4)}"
3
5
  maxlength ||= nil
4
6
  maxwords ||= nil
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("checkboxes")
3
+
2
4
  # cb_helper.css_classes generates "gem-c-checkboxes"
3
5
  cb_helper = GovukPublishingComponents::Presenters::CheckboxesHelper.new(local_assigns)
4
6
  id = cb_helper.id
@@ -1,4 +1,6 @@
1
1
  <%-
2
+ add_gem_component_stylesheet("contents-list")
3
+
2
4
  cl_helper = GovukPublishingComponents::Presenters::ContentsListHelper.new(local_assigns)
3
5
  underline_links ||= false
4
6
  aria_label ||= t("components.contents_list.contents")
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("contextual-guidance")
3
+
2
4
  id ||= nil
3
5
  title ||= nil
4
6
  content ||= nil
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("contextual-sidebar")
3
+
2
4
  ga4_tracking ||= false
3
5
  request.query_parameters[:ga4_tracking] = ga4_tracking
4
6
  navigation = GovukPublishingComponents::Presenters::ContextualNavigation.new(content_item, request)
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("cookie-banner")
3
+
2
4
  id ||= 'global-cookie-message'
3
5
  title ||= t("components.cookie_banner.title")
4
6
  text ||= t("components.cookie_banner.text")
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("date-input")
3
+
2
4
  id ||= "input-#{SecureRandom.hex(4)}"
3
5
  name ||= nil
4
6
  items ||= [
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("details")
3
+
2
4
  shared_helper = GovukPublishingComponents::Presenters::SharedHelper.new(local_assigns)
3
5
 
4
6
  open ||= nil
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("devolved-nations")
3
+
2
4
  shared_helper = GovukPublishingComponents::Presenters::SharedHelper.new(local_assigns)
3
5
  devolved_nations_helper = GovukPublishingComponents::Presenters::DevolvedNationsHelper.new(local_assigns)
4
6
 
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("document-list")
3
+
2
4
  items ||= []
3
5
 
4
6
  classes = "gem-c-document-list"
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("emergency-banner")
3
+
2
4
  heading ||= ""
3
5
  short_description ||= nil
4
6
  link ||= nil
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("error-alert")
3
+
2
4
  id ||= nil
3
5
  description ||= nil
4
6
  data_attributes ||= {}
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("error-message")
3
+
2
4
  id ||= "error-message-#{SecureRandom.hex(4)}"
3
5
  classes ||= ''
4
6
  css_classes = %w( gem-c-error-message govuk-error-message )
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("error-summary")
3
+
2
4
  id ||= "error-summary-#{SecureRandom.hex(4)}"
3
5
  title ||= false
4
6
  description ||= false
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("feedback")
3
+
2
4
  def utf_encode(element)
3
5
  element.is_a?(String) ? element.encode : element
4
6
  end
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("fieldset")
3
+
2
4
  shared_helper = GovukPublishingComponents::Presenters::SharedHelper.new(local_assigns)
3
5
 
4
6
  text = text || yield
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("file-upload")
3
+
2
4
  id ||= "file-upload-#{SecureRandom.hex(4)}"
3
5
  value ||= nil
4
6
  accept ||= nil
@@ -1,4 +1,5 @@
1
1
  <%
2
+ add_gem_component_stylesheet("govspeak")
2
3
  inverse ||= false
3
4
  direction_class = "direction-#{direction}" if local_assigns.include?(:direction)
4
5
  disable_youtube_expansions = local_assigns.fetch(:disable_youtube_expansions) if local_assigns.include?(:disable_youtube_expansions)
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("govspeak-html-publication")
3
+
2
4
  govspeak_locals = {}
3
5
  govspeak_locals[:content] = local_assigns.fetch(:content) if local_assigns.include?(:content)
4
6
  govspeak_locals[:direction] = local_assigns.fetch(:direction) if local_assigns.include?(:direction)
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("heading")
3
+
2
4
  brand ||= false
3
5
  lang = local_assigns[:lang].presence
4
6
 
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("hint")
3
+
2
4
  id ||= "hint-#{SecureRandom.hex(4)}"
3
5
  right_to_left ||= false
4
6
  shared_helper = GovukPublishingComponents::Presenters::SharedHelper.new(local_assigns)
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("image-card")
3
+
2
4
  sizes ||= false
3
5
  brand ||= false
4
6
 
@@ -17,7 +19,7 @@
17
19
  heading_link_classes = %w[
18
20
  gem-c-image-card__title-link
19
21
  govuk-link
20
- ]
22
+ ]
21
23
  heading_link_classes << brand_helper.color_class
22
24
  extra_link_classes = %w[
23
25
  gem-c-image-card__list-item-link
@@ -59,8 +61,8 @@
59
61
  %>
60
62
  <% else %>
61
63
  <%= link[:text] %>
62
- <% end %>
63
- </li>
64
+ <% end %>
65
+ </li>
64
66
  <% end %>
65
67
  </ul>
66
68
  <% end %>
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("input")
3
+
2
4
  shared_helper = GovukPublishingComponents::Presenters::SharedHelper.new(local_assigns)
3
5
 
4
6
  autocomplete ||= nil
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("inset-text")
3
+
2
4
  id ||= "inset-text-#{SecureRandom.hex(4)}"
3
5
  margin_top ||= 6
4
6
  margin_bottom ||= 6
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("intervention")
3
+
2
4
  dismiss_text ||= false
3
5
  suggestion_link_text ||= false
4
6
  suggestion_link_url ||= false
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("inverse-header")
3
+
2
4
  css_classes = []
3
5
  css_classes << " gem-c-inverse-header--full-width" if local_assigns[:full_width]
4
6
  css_classes << " gem-c-inverse-header--padding-top" unless local_assigns[:padding_top].eql?(false)
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("label")
3
+
2
4
  shared_helper = GovukPublishingComponents::Presenters::SharedHelper.new(local_assigns)
3
5
 
4
6
  hint_text ||= ""
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("layout-footer")
3
+
2
4
  meta ||= []
3
5
  navigation ||= []
4
6
  with_border ||= false
@@ -1,4 +1,8 @@
1
- <% product_name ||= "Publishing" %>
1
+ <%
2
+ add_gem_component_stylesheet("layout-for-admin")
3
+
4
+ product_name ||= "Publishing"
5
+ %>
2
6
 
3
7
  <!DOCTYPE html>
4
8
  <html lang="en" class="govuk-template">
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("layout-for-public")
3
+
2
4
  emergency_banner ||= nil
3
5
  full_width ||= false
4
6
  global_bar ||= nil
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("layout-header")
3
+
2
4
  environment ||= nil
3
5
  full_width ||= false
4
6
  navigation_aria_label ||= t("components.layout_header.top_level")
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("layout-super-navigation-header")
3
+
2
4
  logo_link ||= "https://www.gov.uk/"
3
5
  logo_link_title ||= t("components.layout_super_navigation_header.logo_link_title")
4
6
  logo_text = t("components.layout_super_navigation_header.logo_text")
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("lead-paragraph")
3
+
2
4
  text ||= ""
3
5
  inverse ||= false
4
6
  shared_helper = GovukPublishingComponents::Presenters::SharedHelper.new(local_assigns)
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("metadata")
3
+
2
4
  from ||= []
3
5
  from = Array(from)
4
6
 
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("modal-dialogue")
3
+
2
4
  id ||= "modal-dialogue-#{SecureRandom.hex(4)}"
3
5
  wide ||= false
4
6
  data_attributes = {}
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("notice")
3
+
2
4
  title ||= false
3
5
  description_text ||= false
4
6
  description_govspeak ||= false
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("organisation-logo")
3
+
2
4
  logo_helper = GovukPublishingComponents::Presenters::OrganisationLogoHelper.new(local_assigns)
3
5
  brand_helper = GovukPublishingComponents::AppHelpers::BrandHelper.new(organisation[:brand])
4
6
 
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("panel")
3
+
2
4
  description ||= false
3
5
  prepend ||= false
4
6
  append ||= false
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("phase-banner")
3
+
2
4
  app_name ||= nil
3
5
  phase ||= nil
4
6
  message ||= nil
@@ -1,4 +1,9 @@
1
- <% if local_assigns.include?(:next_page) || local_assigns.include?(:previous_page) %>
1
+ <%
2
+ add_gem_component_stylesheet("previous-and-next-navigation")
3
+
4
+ if local_assigns.include?(:next_page) || local_assigns.include?(:previous_page)
5
+ %>
6
+
2
7
  <nav
3
8
  class="govuk-pagination govuk-pagination--block"
4
9
  role="navigation"
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("print-link")
3
+
2
4
  text ||= t('components.print_link.text')
3
5
  href ||= nil
4
6
  data_attributes ||= {}
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("radio")
3
+
2
4
  local_assigns[:margin_bottom] ||= 6
3
5
  shared_helper = GovukPublishingComponents::Presenters::SharedHelper.new(local_assigns)
4
6
  id ||= nil
@@ -7,6 +7,10 @@
7
7
  data[:module] << " ga4-link-tracker" if ga4_tracking
8
8
  %>
9
9
 
10
+ <%
11
+ add_gem_component_stylesheet("related-navigation")
12
+ %>
13
+
10
14
  <% if related_nav_helper.related_navigation? %>
11
15
  <% random = SecureRandom.hex(4) %>
12
16
  <%= tag.div(class: "gem-c-related-navigation", data: data) do %>
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("reorderable-list")
3
+
2
4
  items ||= []
3
5
  input_name ||= "ordering"
4
6
  data_attributes ||= {}
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("search")
3
+
2
4
  shared_helper = GovukPublishingComponents::Presenters::SharedHelper.new(local_assigns)
3
5
  heading_helper = GovukPublishingComponents::Presenters::HeadingHelper.new(local_assigns)
4
6
 
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("select")
3
+
2
4
  # select_helper.css_classes generates "gem-c-select"
3
5
  id ||= false
4
6
  label ||= false
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("share-links")
3
+
2
4
  links ||= []
3
5
  title ||= false
4
6
  track_as_sharing ||= false
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("show-password")
3
+
2
4
  disable_form_submit_check ||= false
3
5
  label ||= nil
4
6
  value ||= nil
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("signup-link")
3
+
2
4
  local_assigns[:heading_level] ||= 3
3
5
  local_assigns[:margin_bottom] ||= 0
4
6
  link_text ||= false
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("single-page-notification-button")
3
+
2
4
  component_helper = GovukPublishingComponents::Presenters::SinglePageNotificationButtonHelper.new(local_assigns)
3
5
  shared_helper = GovukPublishingComponents::Presenters::SharedHelper.new(local_assigns)
4
6
 
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("skip-link")
3
+
2
4
  href ||= '#main-content'
3
5
  text ||= t('components.skip_link.text')
4
6
  %>
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("step-by-step-nav")
3
+
2
4
  options = {}
3
5
  options[:heading_level] = heading_level ||= 2
4
6
 
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("step-by-step-nav-header")
3
+
2
4
  title ||= false
3
5
  path ||= false
4
6
  breadcrumbs = [
@@ -20,7 +22,7 @@
20
22
  end
21
23
 
22
24
  shared_helper = GovukPublishingComponents::Presenters::SharedHelper.new(local_assigns)
23
- classes = %w(gem-c-step-nav-header)
25
+ classes = %w[gem-c-step-nav-header]
24
26
  classes << shared_helper.get_margin_bottom if local_assigns[:margin_bottom]
25
27
  %>
26
28
  <% if title %>
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("step-by-step-nav-related")
3
+
2
4
  links ||= []
3
5
  pretitle ||= t("components.step_by_step_nav_related.part_of")
4
6
  always_display_as_list ||= false
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("subscription-links")
3
+
2
4
  brand ||= false
3
5
  brand_helper = GovukPublishingComponents::AppHelpers::BrandHelper.new(brand)
4
6
 
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("success-alert")
3
+
2
4
  description ||= nil
3
5
  title_id ||= "govuk-notification-banner-title-#{SecureRandom.hex(4)}"
4
6
  shared_helper = GovukPublishingComponents::Presenters::SharedHelper.new(local_assigns)
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("summary-list")
3
+
2
4
  local_assigns[:heading_level] ||= 3
3
5
  shared_helper = GovukPublishingComponents::Presenters::SharedHelper.new(local_assigns)
4
6
  heading_size = "m" unless shared_helper.valid_heading_size?(heading_size)
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("table")
3
+
2
4
  caption ||= nil
3
5
  head ||= []
4
6
  rows ||= []
@@ -16,7 +18,7 @@
16
18
  <%= GovukPublishingComponents::AppHelpers::TableHelper.helper(self, caption, {
17
19
  sortable: sortable,
18
20
  filterable: filterable,
19
- caption_classes: caption_classes,
21
+ caption_classes: caption_classes,
20
22
  table_id: table_id
21
23
  }) do |t| %>
22
24
 
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("tabs")
3
+
2
4
  tabs ||= []
3
5
  panel_border ||= true unless panel_border == false
4
6
  panel_css_classes = %w(govuk-tabs__panel)
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("textarea")
3
+
2
4
  id ||= "textarea-#{SecureRandom.hex(4)}"
3
5
  value ||= nil
4
6
  rows ||= 5
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("title")
3
+
2
4
  average_title_length ||= false
3
5
 
4
6
  context ||= false
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("translation-nav")
3
+
2
4
  brand ||= false
3
5
  brand_helper = GovukPublishingComponents::AppHelpers::BrandHelper.new(brand)
4
6
  translation_helper = GovukPublishingComponents::Presenters::TranslationNavHelper.new(local_assigns)
@@ -1,4 +1,6 @@
1
1
  <%
2
+ add_gem_component_stylesheet("warning-text")
3
+
2
4
  id ||= "warning-text-#{SecureRandom.hex(4)}"
3
5
  text_assistive ||= 'Warning'
4
6
  text_icon ||= '!'