govuk_publishing_components 34.11.0 → 34.13.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/config/govuk_publishing_components_manifest.js +75 -0
- data/app/assets/javascripts/govuk_publishing_components/analytics-ga4/ga4-form-tracker.js +8 -2
- data/app/assets/stylesheets/govuk_publishing_components/_individual_component_support.scss +10 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_accordion.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_action-link.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_attachment.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_back-link.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_big-number.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_breadcrumbs.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_button.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_cards.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_character-count.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_checkboxes.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_contents-list.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_contextual-guidance.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_contextual-sidebar.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_cookie-banner.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_date-input.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_details.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_devolved-nations.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_document-list.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_emergency-banner.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_error-alert.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_error-message.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_error-summary.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_feedback.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_fieldset.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_file-upload.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_govspeak-html-publication.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_govspeak.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_heading.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_hint.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_image-card.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_input.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_inset-text.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_intervention.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_inverse-header.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_label.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_layout-footer.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_layout-for-public.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_layout-super-navigation-header.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_lead-paragraph.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_metadata.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_modal-dialogue.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_notice.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_organisation-logo.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_panel.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_phase-banner.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_previous-and-next-navigation.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_print-link.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_radio.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_related-navigation.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_reorderable-list.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_search.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_select.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_share-links.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_show-password.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_signup-link.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_single-page-notification-button.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_skip-link.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_step-by-step-nav-header.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_step-by-step-nav-related.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_step-by-step-nav.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_subscription-links.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_success-alert.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_summary-list.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_table.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_tabs.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_textarea.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_title.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_translation-nav.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_warning-text.scss +1 -0
- data/app/models/govuk_publishing_components/audit_components.rb +55 -1
- data/app/views/govuk_publishing_components/audit/_components.html.erb +46 -1
- data/app/views/govuk_publishing_components/components/_accordion.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_action_link.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_attachment.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_attachment_link.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_back_link.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_big_number.html.erb +3 -1
- data/app/views/govuk_publishing_components/components/_breadcrumbs.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_button.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_cards.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_character_count.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_checkboxes.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_contents_list.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_contextual_guidance.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_contextual_sidebar.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_cookie_banner.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_date_input.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_details.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_devolved_nations.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_document_list.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_emergency_banner.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_error_alert.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_error_message.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_error_summary.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_feedback.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_fieldset.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_file_upload.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_govspeak.html.erb +1 -0
- data/app/views/govuk_publishing_components/components/_govspeak_html_publication.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_heading.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_hint.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_image_card.html.erb +5 -3
- data/app/views/govuk_publishing_components/components/_input.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_inset_text.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_intervention.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_inverse_header.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_label.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_layout_footer.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_layout_for_admin.html.erb +5 -1
- data/app/views/govuk_publishing_components/components/_layout_for_public.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_layout_header.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_layout_super_navigation_header.html.erb +5 -0
- data/app/views/govuk_publishing_components/components/_lead_paragraph.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_metadata.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_modal_dialogue.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_notice.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_organisation_logo.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_panel.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_phase_banner.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_previous_and_next_navigation.html.erb +6 -1
- data/app/views/govuk_publishing_components/components/_print_link.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_radio.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_related_navigation.html.erb +4 -0
- data/app/views/govuk_publishing_components/components/_reorderable_list.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_search.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_select.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_share_links.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_show_password.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_signup_link.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_single_page_notification_button.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_skip_link.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_step_by_step_nav.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_step_by_step_nav_header.html.erb +3 -1
- data/app/views/govuk_publishing_components/components/_step_by_step_nav_related.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_subscription_links.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_success_alert.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_summary_list.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_table.html.erb +3 -1
- data/app/views/govuk_publishing_components/components/_tabs.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_textarea.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_title.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_translation_nav.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/_warning_text.html.erb +2 -0
- data/app/views/govuk_publishing_components/components/docs/related_navigation.yml +20 -0
- data/app/views/govuk_publishing_components/components/related_navigation/_section.html.erb +15 -9
- data/config/locales/en.yml +1 -1
- data/lib/govuk_publishing_components/app_helpers/asset_helper.rb +86 -0
- data/lib/govuk_publishing_components/config.rb +3 -0
- data/lib/govuk_publishing_components/presenters/related_navigation_helper.rb +1 -1
- data/lib/govuk_publishing_components/railtie.rb +7 -0
- data/lib/govuk_publishing_components/version.rb +1 -1
- data/lib/govuk_publishing_components.rb +3 -0
- metadata +5 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 21e3ffb5b58dc3b31d794d2582929eac560f6dbf9509bf79164e90718483ef18
|
|
4
|
+
data.tar.gz: 7c003248697419a6c54c6fdeba073fbce724390f266a54ba7e2a3149447f75d2
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 90c9c967e09f36e6c9c8fefed7db444427ff14568e800a6b9255dfb69eab7c6e81f78e6eb939958075645822f9d9ca93875c91a1f83b38be61e4951522a584f0
|
|
7
|
+
data.tar.gz: 5163288eb0c08e404376545724810b3854a5f745f6e4ad0fd1fe23a3ef82fa152ac14b1c2971df6b6f8e04563b0ddac4018ec218f5e6dabe85879481cbd39f28
|
|
@@ -12,3 +12,78 @@
|
|
|
12
12
|
//= link govuk_publishing_components/vendor/lux/lux-reporter.js
|
|
13
13
|
//= link govuk_publishing_components/vendor/lux/lux-measurer.js
|
|
14
14
|
//= link component_guide/application.css
|
|
15
|
+
|
|
16
|
+
// components
|
|
17
|
+
//= link govuk_publishing_components/components/_accordion.css
|
|
18
|
+
//= link govuk_publishing_components/components/_action-link.css
|
|
19
|
+
//= link govuk_publishing_components/components/_attachment.css
|
|
20
|
+
//= link govuk_publishing_components/components/_attachment-link.css
|
|
21
|
+
//= link govuk_publishing_components/components/_back-link.css
|
|
22
|
+
//= link govuk_publishing_components/components/_big-number.css
|
|
23
|
+
//= link govuk_publishing_components/components/_breadcrumbs.css
|
|
24
|
+
//= link govuk_publishing_components/components/_button.css
|
|
25
|
+
//= link govuk_publishing_components/components/_cards.css
|
|
26
|
+
//= link govuk_publishing_components/components/_character-count.css
|
|
27
|
+
//= link govuk_publishing_components/components/_checkboxes.css
|
|
28
|
+
//= link govuk_publishing_components/components/_contents-list.css
|
|
29
|
+
//= link govuk_publishing_components/components/_contextual-guidance.css
|
|
30
|
+
//= link govuk_publishing_components/components/_contextual-sidebar.css
|
|
31
|
+
//= link govuk_publishing_components/components/_cookie-banner.css
|
|
32
|
+
//= link govuk_publishing_components/components/_copy-to-clipboard.css
|
|
33
|
+
//= link govuk_publishing_components/components/_date-input.css
|
|
34
|
+
//= link govuk_publishing_components/components/_details.css
|
|
35
|
+
//= link govuk_publishing_components/components/_devolved-nations.css
|
|
36
|
+
//= link govuk_publishing_components/components/_document-list.css
|
|
37
|
+
//= link govuk_publishing_components/components/_emergency-banner.css
|
|
38
|
+
//= link govuk_publishing_components/components/_error-alert.css
|
|
39
|
+
//= link govuk_publishing_components/components/_error-message.css
|
|
40
|
+
//= link govuk_publishing_components/components/_error-summary.css
|
|
41
|
+
//= link govuk_publishing_components/components/_feedback.css
|
|
42
|
+
//= link govuk_publishing_components/components/_fieldset.css
|
|
43
|
+
//= link govuk_publishing_components/components/_file-upload.css
|
|
44
|
+
//= link govuk_publishing_components/components/_govspeak-html-publication.css
|
|
45
|
+
//= link govuk_publishing_components/components/_govspeak.css
|
|
46
|
+
//= link govuk_publishing_components/components/_heading.css
|
|
47
|
+
//= link govuk_publishing_components/components/_hint.css
|
|
48
|
+
//= link govuk_publishing_components/components/_image-card.css
|
|
49
|
+
//= link govuk_publishing_components/components/_input.css
|
|
50
|
+
//= link govuk_publishing_components/components/_inset-text.css
|
|
51
|
+
//= link govuk_publishing_components/components/_intervention.css
|
|
52
|
+
//= link govuk_publishing_components/components/_inverse-header.css
|
|
53
|
+
//= link govuk_publishing_components/components/_label.css
|
|
54
|
+
//= link govuk_publishing_components/components/_layout-footer.css
|
|
55
|
+
//= link govuk_publishing_components/components/_layout-for-admin.css
|
|
56
|
+
//= link govuk_publishing_components/components/_layout-for-public.css
|
|
57
|
+
//= link govuk_publishing_components/components/_layout-header.css
|
|
58
|
+
//= link govuk_publishing_components/components/_layout-super-navigation-header.css
|
|
59
|
+
//= link govuk_publishing_components/components/_lead-paragraph.css
|
|
60
|
+
//= link govuk_publishing_components/components/_metadata.css
|
|
61
|
+
//= link govuk_publishing_components/components/_modal-dialogue.css
|
|
62
|
+
//= link govuk_publishing_components/components/_notice.css
|
|
63
|
+
//= link govuk_publishing_components/components/_organisation-logo.css
|
|
64
|
+
//= link govuk_publishing_components/components/_panel.css
|
|
65
|
+
//= link govuk_publishing_components/components/_phase-banner.css
|
|
66
|
+
//= link govuk_publishing_components/components/_previous-and-next-navigation.css
|
|
67
|
+
//= link govuk_publishing_components/components/_print-link.css
|
|
68
|
+
//= link govuk_publishing_components/components/_radio.css
|
|
69
|
+
//= link govuk_publishing_components/components/_related-navigation.css
|
|
70
|
+
//= link govuk_publishing_components/components/_reorderable-list.css
|
|
71
|
+
//= link govuk_publishing_components/components/_search.css
|
|
72
|
+
//= link govuk_publishing_components/components/_select.css
|
|
73
|
+
//= link govuk_publishing_components/components/_share-links.css
|
|
74
|
+
//= link govuk_publishing_components/components/_show-password.css
|
|
75
|
+
//= link govuk_publishing_components/components/_signup-link.css
|
|
76
|
+
//= link govuk_publishing_components/components/_single-page-notification-button.css
|
|
77
|
+
//= link govuk_publishing_components/components/_skip-link.css
|
|
78
|
+
//= link govuk_publishing_components/components/_step-by-step-nav-header.css
|
|
79
|
+
//= link govuk_publishing_components/components/_step-by-step-nav-related.css
|
|
80
|
+
//= link govuk_publishing_components/components/_step-by-step-nav.css
|
|
81
|
+
//= link govuk_publishing_components/components/_subscription-links.css
|
|
82
|
+
//= link govuk_publishing_components/components/_success-alert.css
|
|
83
|
+
//= link govuk_publishing_components/components/_summary-list.css
|
|
84
|
+
//= link govuk_publishing_components/components/_tabs.css
|
|
85
|
+
//= link govuk_publishing_components/components/_table.css
|
|
86
|
+
//= link govuk_publishing_components/components/_textarea.css
|
|
87
|
+
//= link govuk_publishing_components/components/_title.css
|
|
88
|
+
//= link govuk_publishing_components/components/_translation-nav.css
|
|
89
|
+
//= link govuk_publishing_components/components/_warning-text.css
|
|
@@ -7,6 +7,7 @@ window.GOVUK.Modules = window.GOVUK.Modules || {};
|
|
|
7
7
|
function Ga4FormTracker (module) {
|
|
8
8
|
this.module = module
|
|
9
9
|
this.trackingTrigger = 'data-ga4-form' // elements with this attribute get tracked
|
|
10
|
+
this.includeTextInputValues = this.module.hasAttribute('data-ga4-form-include-text')
|
|
10
11
|
}
|
|
11
12
|
|
|
12
13
|
Ga4FormTracker.prototype.init = function () {
|
|
@@ -82,8 +83,13 @@ window.GOVUK.Modules = window.GOVUK.Modules || {};
|
|
|
82
83
|
input.answer = labelText
|
|
83
84
|
} else if (inputNodename === 'SELECT' && elem.options[elem.selectedIndex].value) {
|
|
84
85
|
input.answer = elem.options[elem.selectedIndex].text
|
|
85
|
-
} else if (inputType === 'text' && elem.value) {
|
|
86
|
-
|
|
86
|
+
} else if ((inputType === 'text' || inputType === 'search') && elem.value) {
|
|
87
|
+
if (this.includeTextInputValues) {
|
|
88
|
+
var PIIRemover = new window.GOVUK.analyticsGa4.PIIRemover()
|
|
89
|
+
input.answer = PIIRemover.stripPIIWithOverride(elem.value, true, true)
|
|
90
|
+
} else {
|
|
91
|
+
input.answer = '[REDACTED]'
|
|
92
|
+
}
|
|
87
93
|
} else if (inputType === 'radio' && elem.checked) {
|
|
88
94
|
input.answer = labelText
|
|
89
95
|
} else {
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
$govuk-new-link-styles: true;
|
|
2
|
+
|
|
3
|
+
// This flag stops the font from being included in this components's
|
|
4
|
+
// stylesheet - the font is being served by Static across all of GOV.UK, so is
|
|
5
|
+
// not needed here.
|
|
6
|
+
$govuk-include-default-font-face: false;
|
|
7
|
+
|
|
8
|
+
// Each component needs access to the variables, functions, and mixins from
|
|
9
|
+
// GOVUK Frontend.
|
|
10
|
+
@import "govuk_frontend_support";
|