govuk_publishing_components 66.4.2 → 66.5.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.
- checksums.yaml +4 -4
- data/app/assets/stylesheets/govuk_publishing_components/components/_layout-super-navigation-header.scss +7 -1
- data/app/views/govuk_publishing_components/components/_cookie_banner.html.erb +14 -32
- data/app/views/govuk_publishing_components/components/_layout_for_public.html.erb +3 -1
- data/app/views/govuk_publishing_components/components/_layout_super_navigation_header.html.erb +231 -221
- data/app/views/govuk_publishing_components/components/_published_dates.html.erb +13 -12
- data/app/views/govuk_publishing_components/components/_signup_link.html.erb +1 -1
- data/app/views/govuk_publishing_components/components/docs/cookie_banner.yml +0 -19
- data/app/views/govuk_publishing_components/components/docs/layout_for_public.yml +12 -23
- data/app/views/govuk_publishing_components/components/docs/published_dates.yml +0 -6
- data/app/views/govuk_publishing_components/components/docs/signup_link.yml +8 -0
- data/config/locales/en.yml +2 -2
- data/lib/govuk_publishing_components/version.rb +1 -1
- data/node_modules/axe-core/axe.d.ts +39 -1
- data/node_modules/axe-core/axe.js +1062 -534
- data/node_modules/axe-core/axe.min.js +2 -2
- data/node_modules/axe-core/gather-internals.js +219 -0
- data/node_modules/axe-core/locales/_template.json +5 -0
- data/node_modules/axe-core/locales/ja.json +1 -0
- data/node_modules/axe-core/locales/{no_NB.json → nb.json} +1 -1
- data/node_modules/axe-core/locales/pt_BR.json +1 -1
- data/node_modules/axe-core/locales/pt_PT.json +1 -1
- data/node_modules/axe-core/locales/zh_CN.json +1 -1
- data/node_modules/axe-core/locales/zh_TW.json +1 -1
- data/node_modules/axe-core/package.json +11 -6
- data/node_modules/axe-core/sri-history.json +4 -0
- metadata +4 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 8b35cf02e5493d19f4dc086cd84551c96a022ccf80c355ab58828b07ea9ffeb1
|
|
4
|
+
data.tar.gz: 62310f2476cee50d461036cd79a15557e334b47f6f5dbcf0dc247c00f3b1a05d
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 21aadbe8c06393846aa67e08d49def3fec910eb57801277cf65d420052017c4e27970dde01efd49d4f6bbc5a699655634be436e5602e721983d310f355913dfb
|
|
7
|
+
data.tar.gz: fb15488f0c38c285c769bd2ab952a6a8f9b0ca44e887a61262f3c14fccfc0d6c5e9115bdb55408677178d0ab5c2cf950ea8ddaa3d4f1435a97c60cc3c6680e52
|
|
@@ -553,7 +553,9 @@ $search-icon-height: 20px;
|
|
|
553
553
|
|
|
554
554
|
// Ensure the dropdown menu background is offset from the menu height and
|
|
555
555
|
// takes up the full screen width
|
|
556
|
-
.govuk-frontend-supported .gem-c-layout-super-navigation-
|
|
556
|
+
.govuk-frontend-supported .gem-c-layout-super-navigation-header__nav-wrapper {
|
|
557
|
+
position: relative;
|
|
558
|
+
|
|
557
559
|
&::before {
|
|
558
560
|
content: "";
|
|
559
561
|
position: absolute;
|
|
@@ -565,6 +567,10 @@ $search-icon-height: 20px;
|
|
|
565
567
|
}
|
|
566
568
|
}
|
|
567
569
|
|
|
570
|
+
.gem-c-phase-banner-wrapper {
|
|
571
|
+
background: govuk-colour("white");
|
|
572
|
+
}
|
|
573
|
+
|
|
568
574
|
// JS available - styles the links in the dropdown menu
|
|
569
575
|
.gem-c-layout-super-navigation-header__dropdown-list-item {
|
|
570
576
|
box-sizing: border-box;
|
|
@@ -20,12 +20,10 @@
|
|
|
20
20
|
cookie_preferences_href,
|
|
21
21
|
class: "govuk-link",
|
|
22
22
|
)))
|
|
23
|
-
services_cookies ||= nil
|
|
24
23
|
|
|
25
24
|
component_helper = GovukPublishingComponents::Presenters::ComponentWrapperHelper.new(local_assigns)
|
|
26
25
|
component_helper.set_id(id)
|
|
27
26
|
component_helper.add_class("gem-c-cookie-banner govuk-clearfix govuk-cookie-banner js-banner-wrapper")
|
|
28
|
-
component_helper.add_class("gem-c-cookie-banner--services") if services_cookies
|
|
29
27
|
|
|
30
28
|
component_helper.add_data_attribute({ module: "cookie-banner", nosnippet: "" })
|
|
31
29
|
component_helper.add_role("region")
|
|
@@ -54,38 +52,22 @@
|
|
|
54
52
|
</div>
|
|
55
53
|
</div>
|
|
56
54
|
<div class="js-confirmation-buttons govuk-button-group">
|
|
57
|
-
|
|
58
|
-
<%= render "govuk_publishing_components/components/button", {
|
|
55
|
+
<%= render "govuk_publishing_components/components/button", {
|
|
59
56
|
name: "cookies",
|
|
60
|
-
text:
|
|
61
|
-
data_attributes: {
|
|
62
|
-
|
|
63
|
-
|
|
57
|
+
text: t("components.cookie_banner.buttons.accept_cookies"),
|
|
58
|
+
data_attributes: {
|
|
59
|
+
"accept-cookies": "true",
|
|
60
|
+
"cookie-types": "all",
|
|
61
|
+
},
|
|
62
|
+
} %>
|
|
63
|
+
<%= render "govuk_publishing_components/components/button", {
|
|
64
64
|
name: "cookies",
|
|
65
|
-
text:
|
|
66
|
-
data_attributes: {
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
<% else %>
|
|
72
|
-
<%= render "govuk_publishing_components/components/button", {
|
|
73
|
-
name: "cookies",
|
|
74
|
-
text: t("components.cookie_banner.buttons.accept_cookies"),
|
|
75
|
-
data_attributes: {
|
|
76
|
-
"accept-cookies": "true",
|
|
77
|
-
"cookie-types": "all",
|
|
78
|
-
},
|
|
79
|
-
} %>
|
|
80
|
-
<%= render "govuk_publishing_components/components/button", {
|
|
81
|
-
name: "cookies",
|
|
82
|
-
text: t("components.cookie_banner.buttons.reject_cookies"),
|
|
83
|
-
data_attributes: {
|
|
84
|
-
"reject-cookies": "true",
|
|
85
|
-
},
|
|
86
|
-
} %>
|
|
87
|
-
<a class="govuk-link" href="<%= cookie_preferences_href %>"><%= t("components.cookie_banner.buttons.view_cookies") %></a>
|
|
88
|
-
<% end %>
|
|
65
|
+
text: t("components.cookie_banner.buttons.reject_cookies"),
|
|
66
|
+
data_attributes: {
|
|
67
|
+
"reject-cookies": "true",
|
|
68
|
+
},
|
|
69
|
+
} %>
|
|
70
|
+
<a class="govuk-link" href="<%= cookie_preferences_href %>"><%= t("components.cookie_banner.buttons.view_cookies") %></a>
|
|
89
71
|
</div>
|
|
90
72
|
<div hidden class="js-hide-button govuk-button-group">
|
|
91
73
|
<%
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
<%
|
|
2
2
|
emergency_banner ||= nil
|
|
3
3
|
global_banner ||= nil
|
|
4
|
+
phase_banner ||= nil
|
|
4
5
|
html_lang ||= "en"
|
|
5
6
|
homepage ||= false
|
|
6
7
|
layout_helper = GovukPublishingComponents::Presenters::PublicLayoutHelper.new(local_assigns)
|
|
@@ -90,7 +91,8 @@
|
|
|
90
91
|
<% I18n.with_locale(:en) do %>
|
|
91
92
|
<%= render "govuk_publishing_components/components/layout_super_navigation_header", {
|
|
92
93
|
homepage:,
|
|
93
|
-
logo_link
|
|
94
|
+
logo_link:,
|
|
95
|
+
phase_banner:,
|
|
94
96
|
} %>
|
|
95
97
|
<% end %>
|
|
96
98
|
<% end %>
|
data/app/views/govuk_publishing_components/components/_layout_super_navigation_header.html.erb
CHANGED
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
logo_link ||= "https://www.gov.uk/"
|
|
3
3
|
logo_link_title ||= t("components.layout_super_navigation_header.logo_link_title")
|
|
4
4
|
|
|
5
|
+
phase_banner ||= nil
|
|
5
6
|
homepage ||= false
|
|
6
7
|
|
|
7
8
|
navigation_links_columns = t("components.layout_super_navigation_header.navigation_links_columns")
|
|
@@ -38,241 +39,250 @@
|
|
|
38
39
|
component_helper.add_data_attribute({ module: "ga4-event-tracker ga4-link-tracker", ga4_expandable: "" })
|
|
39
40
|
%>
|
|
40
41
|
<%= tag.header(**component_helper.all_attributes) do %>
|
|
41
|
-
<div class="gem-c-layout-super-navigation-
|
|
42
|
-
<
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
"
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
42
|
+
<div class="gem-c-layout-super-navigation-header__nav-wrapper">
|
|
43
|
+
<div class="gem-c-layout-super-navigation-header__container govuk-width-container">
|
|
44
|
+
<nav
|
|
45
|
+
aria-labelledby="super-navigation-menu-heading"
|
|
46
|
+
class="gem-c-layout-super-navigation-header__content"
|
|
47
|
+
data-module="super-navigation-mega-menu">
|
|
48
|
+
<%= content_tag(:div, {
|
|
49
|
+
class: header_logo_classes,
|
|
50
|
+
}) do %>
|
|
51
|
+
<%= link_to logo_link, {
|
|
52
|
+
class: header_link_classes,
|
|
53
|
+
data: {
|
|
54
|
+
"ga4-link": {
|
|
55
|
+
"event_name": "navigation",
|
|
56
|
+
"type": "header menu bar",
|
|
57
|
+
"external": "false",
|
|
58
|
+
"text": "GOV.UK",
|
|
59
|
+
"section": "Logo",
|
|
60
|
+
"index_link": 1,
|
|
61
|
+
"index_section": 0,
|
|
62
|
+
"index_section_count": 2,
|
|
63
|
+
"index_total": 1,
|
|
64
|
+
}.to_json,
|
|
65
|
+
},
|
|
66
|
+
id: "logo",
|
|
67
|
+
aria: {
|
|
68
|
+
label: logo_link_title,
|
|
69
|
+
},
|
|
70
|
+
} do %>
|
|
71
|
+
<%= render "govuk_publishing_components/components/govuk_logo/govuk_logo" %>
|
|
72
|
+
<% end %>
|
|
70
73
|
<% end %>
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
</h2>
|
|
74
|
+
<h2 id="super-navigation-menu-heading" class="govuk-visually-hidden">
|
|
75
|
+
<%= navigation_menu_heading %>
|
|
76
|
+
</h2>
|
|
75
77
|
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
78
|
+
<%
|
|
79
|
+
link = t("components.layout_super_navigation_header.navigation_link")
|
|
80
|
+
show_menu_text = show_navigation_menu_text
|
|
81
|
+
hide_menu_text = hide_navigation_menu_text
|
|
82
|
+
%>
|
|
81
83
|
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
84
|
+
<div class="gem-c-layout-super-navigation-header__navigation-item">
|
|
85
|
+
<%= link_to link[:href], {
|
|
86
|
+
class: item_link_classes,
|
|
87
|
+
} do %>
|
|
88
|
+
<% content_tag(:span, {
|
|
89
|
+
class: item_link_inner_classes,
|
|
90
|
+
}) do %>
|
|
91
|
+
<%= link[:label] %>
|
|
92
|
+
<% end %>
|
|
90
93
|
<% end %>
|
|
91
|
-
<% end %>
|
|
92
94
|
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
95
|
+
<%= content_tag(:button, {
|
|
96
|
+
aria: {
|
|
97
|
+
controls: "super-navigation-menu",
|
|
98
|
+
expanded: false,
|
|
99
|
+
label: show_menu_text,
|
|
100
|
+
},
|
|
101
|
+
class: top_toggle_button_classes,
|
|
102
|
+
data: {
|
|
103
|
+
text_for_hide: hide_menu_text,
|
|
104
|
+
text_for_show: show_menu_text,
|
|
105
|
+
toggle_desktop_group: "top",
|
|
106
|
+
toggle_mobile_group: "top",
|
|
107
|
+
ga4_event: {
|
|
108
|
+
event_name: "select_content",
|
|
109
|
+
type: "header menu bar",
|
|
110
|
+
text: link[:label],
|
|
111
|
+
index_section: 1,
|
|
112
|
+
index_section_count: 2,
|
|
113
|
+
section: link[:label],
|
|
114
|
+
},
|
|
112
115
|
},
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
116
|
+
hidden: true,
|
|
117
|
+
id: "super-navigation-menu-toggle",
|
|
118
|
+
type: "button",
|
|
119
|
+
}) do %>
|
|
120
|
+
<%= tag.span link[:label], class: top_toggle_button_inner_classes %>
|
|
121
|
+
<% end %>
|
|
122
|
+
</div>
|
|
123
|
+
<%= content_tag(:div, {
|
|
124
|
+
id: "super-navigation-menu",
|
|
125
|
+
hidden: "",
|
|
126
|
+
class: dropdown_menu_classes,
|
|
117
127
|
}) do %>
|
|
118
|
-
|
|
119
|
-
<% end %>
|
|
120
|
-
</div>
|
|
121
|
-
<%= content_tag(:div, {
|
|
122
|
-
id: "super-navigation-menu",
|
|
123
|
-
hidden: "",
|
|
124
|
-
class: dropdown_menu_classes,
|
|
125
|
-
}) do %>
|
|
126
|
-
<div class="govuk-grid-row gem-c-layout-super-navigation-header__navigation-items">
|
|
128
|
+
<div class="govuk-grid-row gem-c-layout-super-navigation-header__navigation-items">
|
|
127
129
|
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
130
|
+
<% navigation_links_columns.each_with_index do | column, column_index | %>
|
|
131
|
+
<%
|
|
132
|
+
case column[:size]
|
|
133
|
+
when 2
|
|
134
|
+
width_class = "govuk-grid-column-two-thirds-from-desktop"
|
|
135
|
+
when 3
|
|
136
|
+
width_class = "govuk-grid-column-full-from-desktop"
|
|
137
|
+
else
|
|
138
|
+
width_class = "govuk-grid-column-one-third-from-desktop"
|
|
139
|
+
end
|
|
140
|
+
%>
|
|
139
141
|
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
142
|
+
<div class="<%= width_class %> gem-c-layout-super-navigation-header__column--<%= column[:label].downcase.gsub(" ", "-") %>">
|
|
143
|
+
<h3 class="govuk-heading-m gem-c-layout-super-navigation-header__column-header">
|
|
144
|
+
<%= column[:label] %>
|
|
145
|
+
</h3>
|
|
146
|
+
<ul class="gem-c-layout-super-navigation-header__navigation-second-items gem-c-layout-super-navigation-header__navigation-second-items--<%= column[:label].downcase.gsub(" ", "-") %>">
|
|
147
|
+
<% index_total = column[:menu_contents].length %>
|
|
148
|
+
<% column[:menu_contents].each_with_index do | item, index | %>
|
|
149
|
+
<%
|
|
150
|
+
has_description = item[:description].present?
|
|
151
|
+
link_classes = %w[govuk-link gem-c-layout-super-navigation-header__navigation-second-item-link]
|
|
152
|
+
link_classes << "gem-c-layout-super-navigation-header__navigation-second-item-link--with-description" if has_description
|
|
153
|
+
%>
|
|
154
|
+
<li class="gem-c-layout-super-navigation-header__dropdown-list-item">
|
|
155
|
+
<%= link_to item[:label], item[:href], {
|
|
156
|
+
class: link_classes,
|
|
157
|
+
data: {
|
|
158
|
+
ga4_link: {
|
|
159
|
+
"event_name": "navigation",
|
|
160
|
+
"type": "header menu bar",
|
|
161
|
+
"index_section": column_index + 1,
|
|
162
|
+
"index_link": index + 1,
|
|
163
|
+
"index_section_count": 3,
|
|
164
|
+
"index_total": index_total,
|
|
165
|
+
"section": column[:label],
|
|
166
|
+
},
|
|
164
167
|
},
|
|
165
|
-
}
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
</
|
|
171
|
-
|
|
168
|
+
} %>
|
|
169
|
+
<%= tag.p item[:description], class: "gem-c-layout-super-navigation-header__navigation-second-item-description" if has_description %>
|
|
170
|
+
</li>
|
|
171
|
+
<% end %>
|
|
172
|
+
</ul>
|
|
173
|
+
</div>
|
|
174
|
+
<% end %>
|
|
175
|
+
</div>
|
|
176
|
+
<% end %>
|
|
177
|
+
<div class="gem-c-layout-super-navigation-header__search-item">
|
|
178
|
+
<%= content_tag(:button, {
|
|
179
|
+
id: "super-search-menu-toggle",
|
|
180
|
+
class: search_toggle_button_classes,
|
|
181
|
+
aria: {
|
|
182
|
+
controls: "super-search-menu",
|
|
183
|
+
expanded: "true",
|
|
184
|
+
label: hide_search_menu_text,
|
|
185
|
+
},
|
|
186
|
+
data: {
|
|
187
|
+
"text-for-hide": hide_search_menu_text,
|
|
188
|
+
"text-for-show": show_search_menu_text,
|
|
189
|
+
"toggle-mobile-group": "top",
|
|
190
|
+
"toggle-desktop-group": "top",
|
|
191
|
+
"ga4-event": "#{{
|
|
192
|
+
"event_name": "select_content",
|
|
193
|
+
"type": "header menu bar",
|
|
194
|
+
"text": "Search",
|
|
195
|
+
"index_section": 2,
|
|
196
|
+
"index_section_count": 2,
|
|
197
|
+
"section": "Search",
|
|
198
|
+
}.to_json
|
|
199
|
+
}",
|
|
200
|
+
},
|
|
201
|
+
hidden: true,
|
|
202
|
+
type: "button",
|
|
203
|
+
}) do %>
|
|
204
|
+
<span class="govuk-visually-hidden">
|
|
205
|
+
<%= search_text %>
|
|
206
|
+
</span>
|
|
207
|
+
<%=
|
|
208
|
+
render "govuk_publishing_components/components/search/search_icon", {
|
|
209
|
+
classes: %w[gem-c-layout-super-navigation-header__search-toggle-button-link-icon],
|
|
210
|
+
}
|
|
211
|
+
%>
|
|
212
|
+
<span
|
|
213
|
+
aria-hidden="true"
|
|
214
|
+
class="gem-c-layout-super-navigation-header__navigation-top-toggle-close-icon">
|
|
215
|
+
×
|
|
216
|
+
</span>
|
|
217
|
+
<% end %>
|
|
218
|
+
|
|
219
|
+
<%= link_to "/search", {
|
|
220
|
+
class: search_item_link_classes,
|
|
221
|
+
} do %>
|
|
222
|
+
<span class="govuk-visually-hidden">
|
|
223
|
+
<%= search_text %>
|
|
224
|
+
</span>
|
|
225
|
+
<%=
|
|
226
|
+
render "govuk_publishing_components/components/search/search_icon", {
|
|
227
|
+
classes: %w[gem-c-layout-super-navigation-header__search-item-link-icon],
|
|
228
|
+
}
|
|
229
|
+
%>
|
|
172
230
|
<% end %>
|
|
173
231
|
</div>
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
class: search_toggle_button_classes,
|
|
179
|
-
aria: {
|
|
180
|
-
controls: "super-search-menu",
|
|
181
|
-
expanded: "true",
|
|
182
|
-
label: hide_search_menu_text,
|
|
183
|
-
},
|
|
184
|
-
data: {
|
|
185
|
-
"text-for-hide": hide_search_menu_text,
|
|
186
|
-
"text-for-show": show_search_menu_text,
|
|
187
|
-
"toggle-mobile-group": "top",
|
|
188
|
-
"toggle-desktop-group": "top",
|
|
189
|
-
"ga4-event": "#{{
|
|
190
|
-
"event_name": "select_content",
|
|
191
|
-
"type": "header menu bar",
|
|
192
|
-
"text": "Search",
|
|
193
|
-
"index_section": 2,
|
|
194
|
-
"index_section_count": 2,
|
|
195
|
-
"section": "Search",
|
|
196
|
-
}.to_json
|
|
197
|
-
}",
|
|
198
|
-
},
|
|
199
|
-
hidden: true,
|
|
200
|
-
type: "button",
|
|
232
|
+
<%= content_tag(:div, {
|
|
233
|
+
id: "super-search-menu",
|
|
234
|
+
hidden: "",
|
|
235
|
+
class: dropdown_menu_classes,
|
|
201
236
|
}) do %>
|
|
202
|
-
<
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
<div class="govuk-grid-column-full">
|
|
241
|
-
<%= tag.form(
|
|
242
|
-
class: "gem-c-layout-super-navigation-header__search-form",
|
|
243
|
-
id: "search",
|
|
244
|
-
data: {
|
|
245
|
-
module: "ga4-search-tracker",
|
|
246
|
-
ga4_search_type: "header menu bar",
|
|
247
|
-
ga4_search_url: "/search/all",
|
|
248
|
-
ga4_search_section: "Search GOV.UK",
|
|
249
|
-
ga4_search_index_section: 3,
|
|
250
|
-
ga4_search_index_section_count: 3,
|
|
251
|
-
},
|
|
252
|
-
action: "/search/all",
|
|
253
|
-
method: "get",
|
|
254
|
-
role: "search",
|
|
255
|
-
aria: {
|
|
256
|
-
label: "Site-wide",
|
|
257
|
-
},
|
|
258
|
-
) do %>
|
|
259
|
-
<%= render "govuk_publishing_components/components/search_with_autocomplete", {
|
|
260
|
-
name: "keywords",
|
|
261
|
-
inline_label: false,
|
|
262
|
-
label_size: "m",
|
|
263
|
-
label_text: search_text,
|
|
264
|
-
label_custom_class: "gem-c-layout-super-navigation-header__search-label--large-navbar",
|
|
265
|
-
size: "large",
|
|
266
|
-
margin_bottom: 0,
|
|
267
|
-
disable_corrections: true,
|
|
268
|
-
source_url: [Plek.new.website_root, "/api/search/autocomplete.json"].join,
|
|
269
|
-
source_key: "suggestions",
|
|
270
|
-
} %>
|
|
271
|
-
<% end %>
|
|
237
|
+
<div class="gem-c-layout-super-navigation-header__search-container gem-c-layout-super-navigation-header__search-items">
|
|
238
|
+
<h3 class="govuk-visually-hidden">
|
|
239
|
+
<%= navigation_search_subheading %>
|
|
240
|
+
</h3>
|
|
241
|
+
<div class="govuk-grid-row">
|
|
242
|
+
<div class="govuk-grid-column-full">
|
|
243
|
+
<%= tag.form(
|
|
244
|
+
class: "gem-c-layout-super-navigation-header__search-form",
|
|
245
|
+
id: "search",
|
|
246
|
+
data: {
|
|
247
|
+
module: "ga4-search-tracker",
|
|
248
|
+
ga4_search_type: "header menu bar",
|
|
249
|
+
ga4_search_url: "/search/all",
|
|
250
|
+
ga4_search_section: "Search GOV.UK",
|
|
251
|
+
ga4_search_index_section: 3,
|
|
252
|
+
ga4_search_index_section_count: 3,
|
|
253
|
+
},
|
|
254
|
+
action: "/search/all",
|
|
255
|
+
method: "get",
|
|
256
|
+
role: "search",
|
|
257
|
+
aria: {
|
|
258
|
+
label: "Site-wide",
|
|
259
|
+
},
|
|
260
|
+
) do %>
|
|
261
|
+
<%= render "govuk_publishing_components/components/search_with_autocomplete", {
|
|
262
|
+
name: "keywords",
|
|
263
|
+
inline_label: false,
|
|
264
|
+
label_size: "m",
|
|
265
|
+
label_text: search_text,
|
|
266
|
+
label_custom_class: "gem-c-layout-super-navigation-header__search-label--large-navbar",
|
|
267
|
+
size: "large",
|
|
268
|
+
margin_bottom: 0,
|
|
269
|
+
disable_corrections: true,
|
|
270
|
+
source_url: [Plek.new.website_root, "/api/search/autocomplete.json"].join,
|
|
271
|
+
source_key: "suggestions",
|
|
272
|
+
} %>
|
|
273
|
+
<% end %>
|
|
274
|
+
</div>
|
|
272
275
|
</div>
|
|
273
276
|
</div>
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
</
|
|
277
|
+
<% end %>
|
|
278
|
+
</nav>
|
|
279
|
+
</div>
|
|
277
280
|
</div>
|
|
281
|
+
<% if phase_banner %>
|
|
282
|
+
<div class="gem-c-phase-banner-wrapper">
|
|
283
|
+
<div class="govuk-width-container">
|
|
284
|
+
<%= render "govuk_publishing_components/components/phase_banner", phase_banner %>
|
|
285
|
+
</div>
|
|
286
|
+
</div>
|
|
287
|
+
<% end %>
|
|
278
288
|
<% end %>
|
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
history ||= []
|
|
4
4
|
history = Array(history)
|
|
5
5
|
last_updated ||= false
|
|
6
|
-
link_to_history ||= false
|
|
7
6
|
|
|
8
7
|
component_helper = GovukPublishingComponents::Presenters::ComponentWrapperHelper.new(local_assigns)
|
|
9
8
|
component_helper.add_class("gem-c-published-dates")
|
|
@@ -20,17 +19,19 @@
|
|
|
20
19
|
<% end %>
|
|
21
20
|
<% if last_updated %>
|
|
22
21
|
<%= t("components.published_dates.last_updated", date: last_updated) %>
|
|
23
|
-
<% if
|
|
24
|
-
<span aria-hidden="true"
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
22
|
+
<% if history.any? %>
|
|
23
|
+
<span aria-hidden="true">— </span>
|
|
24
|
+
<a
|
|
25
|
+
href="#full-history"
|
|
26
|
+
class="gem-c-published-dates__toggle govuk-link"
|
|
27
|
+
data-controls="full-history"
|
|
28
|
+
data-expanded="false"
|
|
29
|
+
data-toggled-text='<%= t("components.published_dates.hide_all_updates", locale: :en) %>'
|
|
30
|
+
data-module="ga4-event-tracker"
|
|
31
|
+
data-ga4-event='<%= { event_name: "select_content", type: "content history", section: "Footer" }.to_json %>'
|
|
32
|
+
data-ga4-expandable>
|
|
33
|
+
<%= t("components.published_dates.show_all_updates", locale: :en) %>
|
|
34
|
+
</a>
|
|
34
35
|
<div class="gem-c-published-dates__change-history js-hidden" id="full-history">
|
|
35
36
|
<ol class="gem-c-published-dates__list">
|
|
36
37
|
<% history.each do |change| %>
|