govuk_publishing_components 35.15.5 → 35.16.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/app/assets/config/govuk_publishing_components_manifest.js +1 -0
- data/app/assets/images/option-select/input-icon.svg +3 -0
- data/app/assets/javascripts/govuk_publishing_components/analytics-ga4/ga4-page-views.js +37 -15
- data/app/assets/javascripts/govuk_publishing_components/analytics-ga4/ga4-video-tracker.js +7 -1
- data/app/assets/javascripts/govuk_publishing_components/analytics-ga4/pii-remover.js +1 -1
- data/app/assets/javascripts/govuk_publishing_components/components/option-select.js +312 -0
- data/app/assets/stylesheets/component_guide/application.scss +6 -6
- data/app/assets/stylesheets/govuk_publishing_components/_all_components.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_action-link.scss +15 -15
- data/app/assets/stylesheets/govuk_publishing_components/components/_big-number.scss +3 -2
- data/app/assets/stylesheets/govuk_publishing_components/components/_breadcrumbs.scss +3 -3
- data/app/assets/stylesheets/govuk_publishing_components/components/_button.scss +2 -2
- data/app/assets/stylesheets/govuk_publishing_components/components/_cards.scss +5 -5
- data/app/assets/stylesheets/govuk_publishing_components/components/_contents-list.scss +1 -1
- data/app/assets/stylesheets/govuk_publishing_components/components/_contextual-sidebar.scss +1 -1
- data/app/assets/stylesheets/govuk_publishing_components/components/_document-list.scss +2 -2
- data/app/assets/stylesheets/govuk_publishing_components/components/_image-card.scss +31 -5
- data/app/assets/stylesheets/govuk_publishing_components/components/_layout-super-navigation-header.scss +40 -35
- data/app/assets/stylesheets/govuk_publishing_components/components/_option-select.scss +172 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_step-by-step-nav.scss +23 -19
- data/app/assets/stylesheets/govuk_publishing_components/components/_table.scss +6 -6
- data/app/assets/stylesheets/govuk_publishing_components/components/_tabs.scss +2 -1
- data/app/assets/stylesheets/govuk_publishing_components/components/govspeak/_steps.scss +3 -1
- data/app/assets/stylesheets/govuk_publishing_components/components/govspeak/_typography.scss +4 -4
- data/app/assets/stylesheets/govuk_publishing_components/components/mixins/_media-down.scss +2 -2
- data/app/views/govuk_publishing_components/components/_attachment.html.erb +1 -1
- data/app/views/govuk_publishing_components/components/_contents_list.html.erb +20 -10
- data/app/views/govuk_publishing_components/components/_image_card.html.erb +8 -2
- data/app/views/govuk_publishing_components/components/_option_select.html.erb +71 -0
- data/app/views/govuk_publishing_components/components/_previous_and_next_navigation.html.erb +6 -6
- data/app/views/govuk_publishing_components/components/docs/contents_list.yml +1 -0
- data/app/views/govuk_publishing_components/components/docs/image_card.yml +13 -0
- data/app/views/govuk_publishing_components/components/docs/option_select.yml +343 -0
- data/config/locales/ar.yml +5 -0
- data/config/locales/az.yml +5 -0
- data/config/locales/be.yml +5 -0
- data/config/locales/bg.yml +5 -0
- data/config/locales/bn.yml +5 -0
- data/config/locales/cs.yml +5 -0
- data/config/locales/cy.yml +5 -0
- data/config/locales/da.yml +5 -0
- data/config/locales/de.yml +5 -0
- data/config/locales/dr.yml +5 -0
- data/config/locales/el.yml +5 -0
- data/config/locales/en.yml +6 -1
- data/config/locales/es-419.yml +5 -0
- data/config/locales/es.yml +5 -0
- data/config/locales/et.yml +5 -0
- data/config/locales/fa.yml +5 -0
- data/config/locales/fi.yml +5 -0
- data/config/locales/fr.yml +5 -0
- data/config/locales/gd.yml +5 -0
- data/config/locales/gu.yml +5 -0
- data/config/locales/he.yml +5 -0
- data/config/locales/hi.yml +5 -0
- data/config/locales/hr.yml +5 -0
- data/config/locales/hu.yml +5 -0
- data/config/locales/hy.yml +5 -0
- data/config/locales/id.yml +5 -0
- data/config/locales/is.yml +5 -0
- data/config/locales/it.yml +5 -0
- data/config/locales/ja.yml +5 -0
- data/config/locales/ka.yml +5 -0
- data/config/locales/kk.yml +5 -0
- data/config/locales/ko.yml +5 -0
- data/config/locales/lt.yml +5 -0
- data/config/locales/lv.yml +5 -0
- data/config/locales/ms.yml +5 -0
- data/config/locales/mt.yml +5 -0
- data/config/locales/nl.yml +5 -0
- data/config/locales/no.yml +5 -0
- data/config/locales/pa-pk.yml +5 -0
- data/config/locales/pa.yml +5 -0
- data/config/locales/pl.yml +5 -0
- data/config/locales/ps.yml +5 -0
- data/config/locales/pt.yml +5 -0
- data/config/locales/ro.yml +5 -0
- data/config/locales/ru.yml +5 -0
- data/config/locales/si.yml +5 -0
- data/config/locales/sk.yml +5 -0
- data/config/locales/sl.yml +5 -0
- data/config/locales/so.yml +5 -0
- data/config/locales/sq.yml +5 -0
- data/config/locales/sr.yml +5 -0
- data/config/locales/sv.yml +5 -0
- data/config/locales/sw.yml +5 -0
- data/config/locales/ta.yml +5 -0
- data/config/locales/th.yml +5 -0
- data/config/locales/tk.yml +5 -0
- data/config/locales/tr.yml +5 -0
- data/config/locales/uk.yml +5 -0
- data/config/locales/ur.yml +5 -0
- data/config/locales/uz.yml +5 -0
- data/config/locales/vi.yml +5 -0
- data/config/locales/zh-hk.yml +5 -0
- data/config/locales/zh-tw.yml +5 -0
- data/config/locales/zh.yml +5 -0
- data/lib/govuk_publishing_components/presenters/contents_list_helper.rb +8 -0
- data/lib/govuk_publishing_components/presenters/image_card_helper.rb +6 -2
- data/lib/govuk_publishing_components/presenters/meta_tags.rb +3 -0
- data/lib/govuk_publishing_components/version.rb +1 -1
- data/node_modules/axe-core/axe.js +6 -6
- data/node_modules/axe-core/axe.min.js +2 -2
- data/node_modules/axe-core/locales/_template.json +4 -4
- data/node_modules/axe-core/package.json +1 -1
- data/node_modules/axe-core/sri-history.json +4 -0
- metadata +7 -2
data/config/locales/sv.yml
CHANGED
@@ -19,6 +19,7 @@ sv:
|
|
19
19
|
page:
|
20
20
|
one: 1 sida
|
21
21
|
other: "%{count} sidor"
|
22
|
+
preview_aria_label:
|
22
23
|
preview_link:
|
23
24
|
reference: 'Ref: %{reference}'
|
24
25
|
request_format_cta: Begär ett tillgängligt format.
|
@@ -137,6 +138,10 @@ sv:
|
|
137
138
|
close_modal: Stäng den modala dialogen
|
138
139
|
notice:
|
139
140
|
banner_title:
|
141
|
+
option_select:
|
142
|
+
found_single:
|
143
|
+
found_multiple:
|
144
|
+
selected:
|
140
145
|
organisation_schema:
|
141
146
|
all_content_search_description: Hitta allt innehåll från %{organisation}
|
142
147
|
previous_and_next_navigation:
|
data/config/locales/sw.yml
CHANGED
@@ -19,6 +19,7 @@ sw:
|
|
19
19
|
page:
|
20
20
|
one: Ukurasa mmoja (1)
|
21
21
|
other: Kurasa %{count}
|
22
|
+
preview_aria_label:
|
22
23
|
preview_link:
|
23
24
|
reference: 'Marejeleo: %{reference}'
|
24
25
|
request_format_cta: Omba muundo unaoweza kutumika.
|
@@ -137,6 +138,10 @@ sw:
|
|
137
138
|
close_modal: Funga dirisha ibukizi
|
138
139
|
notice:
|
139
140
|
banner_title:
|
141
|
+
option_select:
|
142
|
+
found_single:
|
143
|
+
found_multiple:
|
144
|
+
selected:
|
140
145
|
organisation_schema:
|
141
146
|
all_content_search_description: Tafuta maudhui yote kutoka %{organisation}
|
142
147
|
previous_and_next_navigation:
|
data/config/locales/ta.yml
CHANGED
@@ -19,6 +19,7 @@ ta:
|
|
19
19
|
page:
|
20
20
|
one: 1 பக்கம்
|
21
21
|
other: "%{count} பக்கங்கள்"
|
22
|
+
preview_aria_label:
|
22
23
|
preview_link:
|
23
24
|
reference: 'பார்வை: %{reference}'
|
24
25
|
request_format_cta: அணுகக்கூடிய வடிவத்தைக் கோருக.
|
@@ -138,6 +139,10 @@ ta:
|
|
138
139
|
close_modal: மாதிரி உரையாடலை மூடு
|
139
140
|
notice:
|
140
141
|
banner_title:
|
142
|
+
option_select:
|
143
|
+
found_single:
|
144
|
+
found_multiple:
|
145
|
+
selected:
|
141
146
|
organisation_schema:
|
142
147
|
all_content_search_description: "%{organisation}-லிருந்து அனைத்து உள்ளடக்கத்தையும் கண்டறி"
|
143
148
|
previous_and_next_navigation:
|
data/config/locales/th.yml
CHANGED
@@ -18,6 +18,7 @@ th:
|
|
18
18
|
order_a_copy: สั่งซื้อสำเนา
|
19
19
|
page:
|
20
20
|
other: "%{count} หน้า"
|
21
|
+
preview_aria_label:
|
21
22
|
preview_link:
|
22
23
|
reference: 'อ้างอิง: %{reference}'
|
23
24
|
request_format_cta: ขอรูปแบบไฟล์ที่สามารถเข้าถึงได้
|
@@ -135,6 +136,10 @@ th:
|
|
135
136
|
close_modal: ปิดการสนทนาโมดอล
|
136
137
|
notice:
|
137
138
|
banner_title:
|
139
|
+
option_select:
|
140
|
+
found_single:
|
141
|
+
found_multiple:
|
142
|
+
selected:
|
138
143
|
organisation_schema:
|
139
144
|
all_content_search_description: ค้นหาเนื้อหาทั้งหมดจาก %{organisation}
|
140
145
|
previous_and_next_navigation:
|
data/config/locales/tk.yml
CHANGED
@@ -19,6 +19,7 @@ tk:
|
|
19
19
|
page:
|
20
20
|
one: 1 sahypa
|
21
21
|
other: "%{count} sahypalar"
|
22
|
+
preview_aria_label:
|
22
23
|
preview_link:
|
23
24
|
reference: 'Salgylanma: %{reference}'
|
24
25
|
request_format_cta: Elýeterli formaty talap etmek.
|
@@ -138,6 +139,10 @@ tk:
|
|
138
139
|
close_modal: Modal gepleşikleri tamamlamak
|
139
140
|
notice:
|
140
141
|
banner_title:
|
142
|
+
option_select:
|
143
|
+
found_single:
|
144
|
+
found_multiple:
|
145
|
+
selected:
|
141
146
|
organisation_schema:
|
142
147
|
all_content_search_description: Ähli mazmunyny %{organisation}-dan tapyň
|
143
148
|
previous_and_next_navigation:
|
data/config/locales/tr.yml
CHANGED
@@ -19,6 +19,7 @@ tr:
|
|
19
19
|
page:
|
20
20
|
one: 1 sayfa
|
21
21
|
other: "%{count} sayfa"
|
22
|
+
preview_aria_label:
|
22
23
|
preview_link:
|
23
24
|
reference: 'İlgi: %{reference}'
|
24
25
|
request_format_cta: Erişilebilir bir format talep edin.
|
@@ -138,6 +139,10 @@ tr:
|
|
138
139
|
close_modal: Model diyaloğu kapat
|
139
140
|
notice:
|
140
141
|
banner_title:
|
142
|
+
option_select:
|
143
|
+
found_single:
|
144
|
+
found_multiple:
|
145
|
+
selected:
|
141
146
|
organisation_schema:
|
142
147
|
all_content_search_description: "%{organisation} kaynaklı tüm içeriği bul"
|
143
148
|
previous_and_next_navigation:
|
data/config/locales/uk.yml
CHANGED
@@ -21,6 +21,7 @@ uk:
|
|
21
21
|
many:
|
22
22
|
one: 1 сторінка
|
23
23
|
other: "%{count} сторінок"
|
24
|
+
preview_aria_label:
|
24
25
|
preview_link:
|
25
26
|
reference: 'Посилання: %{reference}'
|
26
27
|
request_format_cta: Надішліть запит на доступний формат.
|
@@ -144,6 +145,10 @@ uk:
|
|
144
145
|
close_modal: Закрити модальний діалог
|
145
146
|
notice:
|
146
147
|
banner_title:
|
148
|
+
option_select:
|
149
|
+
found_single:
|
150
|
+
found_multiple:
|
151
|
+
selected:
|
147
152
|
organisation_schema:
|
148
153
|
all_content_search_description: Знайти весь вміст від %{organization}
|
149
154
|
previous_and_next_navigation:
|
data/config/locales/ur.yml
CHANGED
@@ -19,6 +19,7 @@ ur:
|
|
19
19
|
page:
|
20
20
|
one: 1 صفحہ
|
21
21
|
other: "%{count} صفحات"
|
22
|
+
preview_aria_label:
|
22
23
|
preview_link:
|
23
24
|
reference: 'حوالہ: %{reference}'
|
24
25
|
request_format_cta: قابل رسائی فارمیٹ کی درخواست دیں۔
|
@@ -134,6 +135,10 @@ ur:
|
|
134
135
|
close_modal: محدود موڈل ڈائیلاگ
|
135
136
|
notice:
|
136
137
|
banner_title:
|
138
|
+
option_select:
|
139
|
+
found_single:
|
140
|
+
found_multiple:
|
141
|
+
selected:
|
137
142
|
organisation_schema:
|
138
143
|
all_content_search_description: "%{organisation} کا تمام مواد تلاش کریں"
|
139
144
|
previous_and_next_navigation:
|
data/config/locales/uz.yml
CHANGED
@@ -19,6 +19,7 @@ uz:
|
|
19
19
|
page:
|
20
20
|
one: 1 саҳифа
|
21
21
|
other: "%{count} саҳифа"
|
22
|
+
preview_aria_label:
|
22
23
|
preview_link:
|
23
24
|
reference: 'Ҳавола: %{reference}'
|
24
25
|
request_format_cta: Мақбул форматни олишга сўров.
|
@@ -139,6 +140,10 @@ uz:
|
|
139
140
|
close_modal: Модал мулоқотни ёпиш
|
140
141
|
notice:
|
141
142
|
banner_title:
|
143
|
+
option_select:
|
144
|
+
found_single:
|
145
|
+
found_multiple:
|
146
|
+
selected:
|
142
147
|
organisation_schema:
|
143
148
|
all_content_search_description: "%{organization} дан бутун контентни топиш"
|
144
149
|
previous_and_next_navigation:
|
data/config/locales/vi.yml
CHANGED
@@ -18,6 +18,7 @@ vi:
|
|
18
18
|
order_a_copy: Đặt hàng một bản sao
|
19
19
|
page:
|
20
20
|
other: "%{count} trang"
|
21
|
+
preview_aria_label:
|
21
22
|
preview_link:
|
22
23
|
reference: 'Tham khảo: %{reference}'
|
23
24
|
request_format_cta: Yêu cầu một định dạng có thể truy cập.
|
@@ -136,6 +137,10 @@ vi:
|
|
136
137
|
close_modal: Đóng đối thoại phương thức
|
137
138
|
notice:
|
138
139
|
banner_title:
|
140
|
+
option_select:
|
141
|
+
found_single:
|
142
|
+
found_multiple:
|
143
|
+
selected:
|
139
144
|
organisation_schema:
|
140
145
|
all_content_search_description: Tìm tất cả nội dung từ %{organisation}
|
141
146
|
previous_and_next_navigation:
|
data/config/locales/zh-hk.yml
CHANGED
@@ -18,6 +18,7 @@ zh-hk:
|
|
18
18
|
order_a_copy: 索取副本
|
19
19
|
page:
|
20
20
|
other: "%{count} 頁"
|
21
|
+
preview_aria_label:
|
21
22
|
preview_link:
|
22
23
|
reference: 'Ref: %{reference}'
|
23
24
|
request_format_cta: 索取可讀取之格式。
|
@@ -135,6 +136,10 @@ zh-hk:
|
|
135
136
|
close_modal: 關閉互動視窗對話
|
136
137
|
notice:
|
137
138
|
banner_title:
|
139
|
+
option_select:
|
140
|
+
found_single:
|
141
|
+
found_multiple:
|
142
|
+
selected:
|
138
143
|
organisation_schema:
|
139
144
|
all_content_search_description: 從 %{organisation} 獲得更多內容
|
140
145
|
previous_and_next_navigation:
|
data/config/locales/zh-tw.yml
CHANGED
@@ -18,6 +18,7 @@ zh-tw:
|
|
18
18
|
order_a_copy: 預定副本
|
19
19
|
page:
|
20
20
|
other: "%{count} 頁面"
|
21
|
+
preview_aria_label:
|
21
22
|
preview_link:
|
22
23
|
reference: 參考:%{reference}
|
23
24
|
request_format_cta: 請求可參閱格式。
|
@@ -135,6 +136,10 @@ zh-tw:
|
|
135
136
|
close_modal: 關閉模態對話
|
136
137
|
notice:
|
137
138
|
banner_title:
|
139
|
+
option_select:
|
140
|
+
found_single:
|
141
|
+
found_multiple:
|
142
|
+
selected:
|
138
143
|
organisation_schema:
|
139
144
|
all_content_search_description: 從 %{organisation} 找到所有內容
|
140
145
|
previous_and_next_navigation:
|
data/config/locales/zh.yml
CHANGED
@@ -18,6 +18,7 @@ zh:
|
|
18
18
|
order_a_copy: 订购副本
|
19
19
|
page:
|
20
20
|
other: "%{count} 页"
|
21
|
+
preview_aria_label:
|
21
22
|
preview_link:
|
22
23
|
reference: 参考号:%{reference}
|
23
24
|
request_format_cta: 申请可访问格式。
|
@@ -135,6 +136,10 @@ zh:
|
|
135
136
|
close_modal: 关闭模态对话
|
136
137
|
notice:
|
137
138
|
banner_title:
|
139
|
+
option_select:
|
140
|
+
found_single:
|
141
|
+
found_multiple:
|
142
|
+
selected:
|
138
143
|
organisation_schema:
|
139
144
|
all_content_search_description: 查找 %{organisation} 的全部内容
|
140
145
|
previous_and_next_navigation:
|
@@ -4,7 +4,7 @@ module GovukPublishingComponents
|
|
4
4
|
include ActionView::Helpers
|
5
5
|
include ActionView::Context
|
6
6
|
|
7
|
-
attr_reader :href_data_attributes, :extra_details, :extra_details_no_indent, :heading_text, :metadata, :lang, :image_loading, :youtube_video_id, :image_src
|
7
|
+
attr_reader :href_data_attributes, :extra_details, :extra_details_no_indent, :heading_text, :metadata, :lang, :image_loading, :youtube_video_id, :image_src, :two_thirds
|
8
8
|
|
9
9
|
def initialize(local_assigns, brand_helper)
|
10
10
|
@href = local_assigns[:href]
|
@@ -20,6 +20,7 @@ module GovukPublishingComponents
|
|
20
20
|
@context = local_assigns[:context]
|
21
21
|
@description = local_assigns[:description]
|
22
22
|
@large = local_assigns[:large]
|
23
|
+
@two_thirds = local_assigns[:two_thirds] || false
|
23
24
|
@heading_text = local_assigns[:heading_text]
|
24
25
|
@extra_details_no_indent = local_assigns[:extra_details_no_indent]
|
25
26
|
@metadata = local_assigns[:metadata]
|
@@ -60,8 +61,11 @@ module GovukPublishingComponents
|
|
60
61
|
end
|
61
62
|
|
62
63
|
def image
|
64
|
+
classes = %w[gem-c-image-card__image-wrapper]
|
65
|
+
classes << "gem-c-image-card__image-wrapper--one-third" if @two_thirds
|
66
|
+
|
63
67
|
if @image_src
|
64
|
-
content_tag(:figure, class:
|
68
|
+
content_tag(:figure, class: classes) do
|
65
69
|
image_tag(
|
66
70
|
@image_src,
|
67
71
|
class: "gem-c-image-card__image",
|
@@ -48,6 +48,9 @@ module GovukPublishingComponents
|
|
48
48
|
primary_publisher = content_item.dig(:links, :primary_publishing_organisation)
|
49
49
|
primary_publisher = primary_publisher.first[:title] unless primary_publisher.blank?
|
50
50
|
meta_tags["govuk:primary-publishing-organisation"] = primary_publisher unless primary_publisher.blank?
|
51
|
+
ga4_browse_topic = content_item.dig(:links, :ordered_related_items, 0, :links, :mainstream_browse_pages, 0, :links, :parent, 0, :title)
|
52
|
+
ga4_browse_topic = ga4_browse_topic.downcase if ga4_browse_topic
|
53
|
+
meta_tags["govuk:ga4-browse-topic"] = ga4_browse_topic if ga4_browse_topic
|
51
54
|
|
52
55
|
meta_tags
|
53
56
|
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
/*! axe v4.8.
|
1
|
+
/*! axe v4.8.1
|
2
2
|
* Copyright (c) 2015 - 2023 Deque Systems, Inc.
|
3
3
|
*
|
4
4
|
* Your use of this Source Code Form is subject to the terms of the Mozilla Public
|
@@ -22,7 +22,7 @@
|
|
22
22
|
}, _typeof(obj);
|
23
23
|
}
|
24
24
|
var axe = axe || {};
|
25
|
-
axe.version = '4.8.
|
25
|
+
axe.version = '4.8.1';
|
26
26
|
if (typeof define === 'function' && define.amd) {
|
27
27
|
define('axe-core', [], function() {
|
28
28
|
return axe;
|
@@ -28321,11 +28321,11 @@
|
|
28321
28321
|
'target-offset': {
|
28322
28322
|
impact: 'serious',
|
28323
28323
|
messages: {
|
28324
|
-
pass: 'Target has sufficient space from its closest neighbors
|
28325
|
-
fail: 'Target has insufficient space to its closest neighbors. Safe clickable space has a diameter of {
|
28324
|
+
pass: 'Target has sufficient space from its closest neighbors. Safe clickable space has a diameter of ${data.closestOffset}px which is at least ${data.minOffset}px.',
|
28325
|
+
fail: 'Target has insufficient space to its closest neighbors. Safe clickable space has a diameter of ${data.closestOffset}px instead of at least ${data.minOffset}px.',
|
28326
28326
|
incomplete: {
|
28327
|
-
default: 'Element with negative tabindex has insufficient space to its closest neighbors. Safe clickable space has a diameter of {
|
28328
|
-
nonTabbableNeighbor: 'Target has insufficient space to its closest neighbors. Safe clickable space has a diameter of {
|
28327
|
+
default: 'Element with negative tabindex has insufficient space to its closest neighbors. Safe clickable space has a diameter of ${data.closestOffset}px instead of at least ${data.minOffset}px. Is this a target?',
|
28328
|
+
nonTabbableNeighbor: 'Target has insufficient space to its closest neighbors. Safe clickable space has a diameter of ${data.closestOffset}px instead of at least ${data.minOffset}px. Is the neighbor a target?'
|
28329
28329
|
}
|
28330
28330
|
}
|
28331
28331
|
},
|