govuk_publishing_components 27.10.3 → 27.12.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/javascripts/govuk_publishing_components/analytics/explicit-cross-domain-links.js +1 -1
- data/app/assets/javascripts/govuk_publishing_components/components/cookie-banner.js +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/_all_components.scss +1 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_accordion.scss +6 -4
- data/app/assets/stylesheets/govuk_publishing_components/components/_layout-super-navigation-header.scss +232 -97
- data/app/assets/stylesheets/govuk_publishing_components/components/_single-page-notification-button.scss +30 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/mixins/_prefixed-transform.scss +5 -0
- data/app/models/govuk_publishing_components/shared_accessibility_criteria.rb +17 -0
- data/app/views/govuk_publishing_components/components/_input.html.erb +35 -22
- data/app/views/govuk_publishing_components/components/_layout_super_navigation_header.html.erb +29 -41
- data/app/views/govuk_publishing_components/components/_search.html.erb +2 -1
- data/app/views/govuk_publishing_components/components/_single_page_notification_button.html.erb +23 -0
- data/app/views/govuk_publishing_components/components/contextual_sidebar/_brexit_cta.html.erb +4 -5
- data/app/views/govuk_publishing_components/components/docs/input.yml +10 -0
- data/app/views/govuk_publishing_components/components/docs/single_page_notification_button.yml +32 -0
- data/app/views/govuk_publishing_components/components/search/_search_icon.html.erb +5 -5
- data/config/locales/ar.yml +0 -3
- data/config/locales/az.yml +0 -3
- data/config/locales/be.yml +0 -3
- data/config/locales/bg.yml +0 -3
- data/config/locales/bn.yml +0 -3
- data/config/locales/cs.yml +0 -3
- data/config/locales/cy.yml +0 -3
- data/config/locales/da.yml +0 -3
- data/config/locales/de.yml +0 -3
- data/config/locales/dr.yml +0 -3
- data/config/locales/el.yml +0 -3
- data/config/locales/en.yml +7 -6
- data/config/locales/es-419.yml +0 -3
- data/config/locales/es.yml +0 -3
- data/config/locales/et.yml +0 -3
- data/config/locales/fa.yml +0 -3
- data/config/locales/fi.yml +0 -3
- data/config/locales/fr.yml +0 -3
- data/config/locales/gd.yml +0 -3
- data/config/locales/gu.yml +0 -3
- data/config/locales/he.yml +0 -3
- data/config/locales/hi.yml +0 -3
- data/config/locales/hr.yml +0 -3
- data/config/locales/hu.yml +0 -3
- data/config/locales/hy.yml +0 -3
- data/config/locales/id.yml +0 -3
- data/config/locales/is.yml +0 -3
- data/config/locales/it.yml +0 -3
- data/config/locales/ja.yml +0 -3
- data/config/locales/ka.yml +0 -3
- data/config/locales/kk.yml +0 -3
- data/config/locales/ko.yml +0 -3
- data/config/locales/lt.yml +0 -3
- data/config/locales/lv.yml +0 -3
- data/config/locales/ms.yml +0 -3
- data/config/locales/mt.yml +0 -3
- data/config/locales/nl.yml +0 -3
- data/config/locales/no.yml +0 -3
- data/config/locales/pa-pk.yml +0 -3
- data/config/locales/pa.yml +0 -3
- data/config/locales/pl.yml +0 -3
- data/config/locales/ps.yml +0 -3
- data/config/locales/pt.yml +0 -3
- data/config/locales/ro.yml +0 -3
- data/config/locales/ru.yml +0 -3
- data/config/locales/si.yml +0 -3
- data/config/locales/sk.yml +0 -3
- data/config/locales/sl.yml +0 -3
- data/config/locales/so.yml +0 -3
- data/config/locales/sq.yml +0 -3
- data/config/locales/sr.yml +0 -3
- data/config/locales/sv.yml +0 -3
- data/config/locales/sw.yml +0 -3
- data/config/locales/ta.yml +0 -3
- data/config/locales/th.yml +0 -3
- data/config/locales/tk.yml +0 -3
- data/config/locales/tr.yml +0 -3
- data/config/locales/uk.yml +0 -3
- data/config/locales/ur.yml +0 -3
- data/config/locales/uz.yml +0 -3
- data/config/locales/vi.yml +0 -3
- data/config/locales/zh-hk.yml +0 -3
- data/config/locales/zh-tw.yml +0 -3
- data/config/locales/zh.yml +0 -3
- data/lib/govuk_publishing_components/presenters/contextual_navigation.rb +11 -0
- data/lib/govuk_publishing_components/version.rb +1 -1
- data/lib/govuk_publishing_components.rb +0 -1
- data/node_modules/govuk-frontend/govuk/components/accordion/macro-options.json +2 -2
- data/node_modules/govuk-frontend/govuk/components/back-link/macro-options.json +3 -3
- data/node_modules/govuk-frontend/govuk/components/button/_index.scss +3 -4
- data/node_modules/govuk-frontend/govuk/components/button/fixtures.json +9 -0
- data/node_modules/govuk-frontend/govuk/components/character-count/macro-options.json +6 -6
- data/node_modules/govuk-frontend/govuk/components/checkboxes/_index.scss +14 -0
- data/node_modules/govuk-frontend/govuk/components/checkboxes/macro-options.json +8 -8
- data/node_modules/govuk-frontend/govuk/components/cookie-banner/macro-options.json +1 -1
- data/node_modules/govuk-frontend/govuk/components/date-input/macro-options.json +5 -5
- data/node_modules/govuk-frontend/govuk/components/details/_index.scss +2 -1
- data/node_modules/govuk-frontend/govuk/components/details/macro-options.json +2 -2
- data/node_modules/govuk-frontend/govuk/components/error-message/macro-options.json +3 -3
- data/node_modules/govuk-frontend/govuk/components/fieldset/macro-options.json +1 -1
- data/node_modules/govuk-frontend/govuk/components/file-upload/_index.scss +1 -0
- data/node_modules/govuk-frontend/govuk/components/file-upload/macro-options.json +4 -4
- data/node_modules/govuk-frontend/govuk/components/footer/_index.scss +3 -0
- data/node_modules/govuk-frontend/govuk/components/footer/macro-options.json +2 -2
- data/node_modules/govuk-frontend/govuk/components/header/macro-options.json +6 -6
- data/node_modules/govuk-frontend/govuk/components/hint/macro-options.json +1 -1
- data/node_modules/govuk-frontend/govuk/components/input/macro-options.json +7 -7
- data/node_modules/govuk-frontend/govuk/components/inset-text/macro-options.json +1 -1
- data/node_modules/govuk-frontend/govuk/components/label/macro-options.json +1 -1
- data/node_modules/govuk-frontend/govuk/components/panel/_index.scss +13 -1
- data/node_modules/govuk-frontend/govuk/components/panel/macro-options.json +1 -1
- data/node_modules/govuk-frontend/govuk/components/radios/_index.scss +14 -0
- data/node_modules/govuk-frontend/govuk/components/radios/macro-options.json +8 -8
- data/node_modules/govuk-frontend/govuk/components/select/macro-options.json +3 -3
- data/node_modules/govuk-frontend/govuk/components/summary-list/fixtures.json +2 -2
- data/node_modules/govuk-frontend/govuk/components/summary-list/macro-options.json +7 -7
- data/node_modules/govuk-frontend/govuk/components/tabs/macro-options.json +4 -4
- data/node_modules/govuk-frontend/govuk/components/textarea/macro-options.json +5 -5
- data/node_modules/govuk-frontend/govuk/helpers/_colour.scss +2 -2
- data/node_modules/govuk-frontend/govuk/helpers/_spacing.scss +22 -4
- data/node_modules/govuk-frontend/govuk/overrides/_all.scss +1 -0
- data/node_modules/govuk-frontend/govuk/overrides/_text-align.scss +20 -0
- data/node_modules/govuk-frontend/package.json +1 -1
- metadata +21 -17
- data/lib/govuk_publishing_components/presenters/brexit_cta_helper.rb +0 -33
@@ -9,7 +9,7 @@
|
|
9
9
|
"name": "classes",
|
10
10
|
"type": "string",
|
11
11
|
"required": false,
|
12
|
-
"description": "Classes to add to the row `div
|
12
|
+
"description": "Classes to add to the row `div`."
|
13
13
|
},
|
14
14
|
{
|
15
15
|
"name": "key.text",
|
@@ -26,7 +26,7 @@
|
|
26
26
|
"name": "key.classes",
|
27
27
|
"type": "string",
|
28
28
|
"required": false,
|
29
|
-
"description": "Classes to add to the key wrapper"
|
29
|
+
"description": "Classes to add to the key wrapper."
|
30
30
|
},
|
31
31
|
{
|
32
32
|
"name": "value.text",
|
@@ -44,25 +44,25 @@
|
|
44
44
|
"name": "value.classes",
|
45
45
|
"type": "string",
|
46
46
|
"required": false,
|
47
|
-
"description": "Classes to add to the value wrapper"
|
47
|
+
"description": "Classes to add to the value wrapper."
|
48
48
|
},
|
49
49
|
{
|
50
50
|
"name": "actions.classes",
|
51
51
|
"type": "string",
|
52
52
|
"required": false,
|
53
|
-
"description": "Classes to add to the actions wrapper"
|
53
|
+
"description": "Classes to add to the actions wrapper."
|
54
54
|
},
|
55
55
|
{
|
56
56
|
"name": "actions.items",
|
57
57
|
"type": "array",
|
58
58
|
"required": false,
|
59
|
-
"description": "Array of action item objects",
|
59
|
+
"description": "Array of action item objects.",
|
60
60
|
"params": [
|
61
61
|
{
|
62
62
|
"name": "href",
|
63
63
|
"type": "string",
|
64
64
|
"required": true,
|
65
|
-
"description": "The value of the link href attribute for an action item"
|
65
|
+
"description": "The value of the link's `href` attribute for an action item."
|
66
66
|
},
|
67
67
|
{
|
68
68
|
"name": "text",
|
@@ -80,7 +80,7 @@
|
|
80
80
|
"name": "visuallyHiddenText",
|
81
81
|
"type": "string",
|
82
82
|
"required": false,
|
83
|
-
"description": "Actions rely on context from the surrounding content so may require additional accessible text
|
83
|
+
"description": "Actions rely on context from the surrounding content so may require additional accessible text. Text supplied to this option is appended to the end. Use `html` for more complicated scenarios."
|
84
84
|
},
|
85
85
|
{
|
86
86
|
"name": "classes",
|
@@ -3,19 +3,19 @@
|
|
3
3
|
"name": "id",
|
4
4
|
"type": "string",
|
5
5
|
"required": false,
|
6
|
-
"description": "This is used for the main component and to compose
|
6
|
+
"description": "This is used for the main component and to compose the ID attribute for each item."
|
7
7
|
},
|
8
8
|
{
|
9
9
|
"name": "idPrefix",
|
10
10
|
"type": "string",
|
11
11
|
"required": false,
|
12
|
-
"description": "String to prefix id for each tab item if no id is specified on each item"
|
12
|
+
"description": "String to prefix id for each tab item if no id is specified on each item."
|
13
13
|
},
|
14
14
|
{
|
15
15
|
"name": "title",
|
16
16
|
"type": "string",
|
17
17
|
"required": false,
|
18
|
-
"description": "Title for the tabs table of contents"
|
18
|
+
"description": "Title for the tabs table of contents."
|
19
19
|
},
|
20
20
|
{
|
21
21
|
"name": "items",
|
@@ -27,7 +27,7 @@
|
|
27
27
|
"name": "id",
|
28
28
|
"type": "string",
|
29
29
|
"required": true,
|
30
|
-
"description": "Specific
|
30
|
+
"description": "Specific ID attribute for the tab item. If omitted, then `idPrefix` string is required instead."
|
31
31
|
},
|
32
32
|
{
|
33
33
|
"name": "label",
|
@@ -3,7 +3,7 @@
|
|
3
3
|
"name": "id",
|
4
4
|
"type": "string",
|
5
5
|
"required": true,
|
6
|
-
"description": "The
|
6
|
+
"description": "The ID of the textarea."
|
7
7
|
},
|
8
8
|
{
|
9
9
|
"name": "name",
|
@@ -15,7 +15,7 @@
|
|
15
15
|
"name": "spellcheck",
|
16
16
|
"type": "boolean",
|
17
17
|
"required": false,
|
18
|
-
"description": "Optional field to enable or disable the spellcheck attribute on the textarea."
|
18
|
+
"description": "Optional field to enable or disable the `spellcheck` attribute on the textarea."
|
19
19
|
},
|
20
20
|
{
|
21
21
|
"name": "rows",
|
@@ -60,13 +60,13 @@
|
|
60
60
|
"name": "formGroup",
|
61
61
|
"type": "object",
|
62
62
|
"required": false,
|
63
|
-
"description": "Options for the form-group wrapper",
|
63
|
+
"description": "Options for the form-group wrapper.",
|
64
64
|
"params": [
|
65
65
|
{
|
66
66
|
"name": "classes",
|
67
67
|
"type": "string",
|
68
68
|
"required": false,
|
69
|
-
"description": "Classes to add to the form group (for example to show error state for the whole group)"
|
69
|
+
"description": "Classes to add to the form group (for example to show error state for the whole group)."
|
70
70
|
}
|
71
71
|
]
|
72
72
|
},
|
@@ -80,7 +80,7 @@
|
|
80
80
|
"name": "autocomplete",
|
81
81
|
"type": "string",
|
82
82
|
"required": false,
|
83
|
-
"description": "Attribute to [identify input purpose](https://www.w3.org/WAI/WCAG21/Understanding/identify-input-purpose.html), for
|
83
|
+
"description": "Attribute to [identify input purpose](https://www.w3.org/WAI/WCAG21/Understanding/identify-input-purpose.html), for example `postal-code` or `username`. See [autofill](https://html.spec.whatwg.org/multipage/form-control-infrastructure.html#autofill) for full list of attributes that can be used."
|
84
84
|
},
|
85
85
|
{
|
86
86
|
"name": "attributes",
|
@@ -75,7 +75,7 @@
|
|
75
75
|
/// Make a colour darker by mixing it with black
|
76
76
|
///
|
77
77
|
/// @param {Colour} $colour - colour to shade
|
78
|
-
/// @param {Number} $percentage - percentage of `$colour` in returned
|
78
|
+
/// @param {Number} $percentage - percentage of `$colour` in returned colour
|
79
79
|
/// @return {Colour}
|
80
80
|
/// @access public
|
81
81
|
|
@@ -86,7 +86,7 @@
|
|
86
86
|
/// Make a colour lighter by mixing it with white
|
87
87
|
///
|
88
88
|
/// @param {Colour} $colour - colour to tint
|
89
|
-
/// @param {Number} $percentage - percentage of `$colour` in returned
|
89
|
+
/// @param {Number} $percentage - percentage of `$colour` in returned colour
|
90
90
|
/// @return {Colour}
|
91
91
|
/// @access public
|
92
92
|
|
@@ -8,15 +8,26 @@
|
|
8
8
|
///
|
9
9
|
/// Returns measurement corresponding to the spacing point requested.
|
10
10
|
///
|
11
|
-
/// @param {Number} $spacing-point - Point on the spacing scale
|
11
|
+
/// @param {Number} $spacing-point - Point on the spacing scale
|
12
|
+
/// (set in `settings/_spacing.scss`)
|
12
13
|
///
|
13
|
-
/// @returns {String} Spacing
|
14
|
+
/// @returns {String} Spacing measurement eg. 10px
|
14
15
|
///
|
15
16
|
/// @example scss
|
16
17
|
/// .element {
|
17
18
|
/// padding: govuk-spacing(5);
|
18
|
-
/// top: govuk-spacing(2) !important; // if `!important` is required
|
19
19
|
/// }
|
20
|
+
///
|
21
|
+
/// @example scss Using negative spacing
|
22
|
+
/// .element {
|
23
|
+
/// margin-top: govuk-spacing(-1);
|
24
|
+
/// }
|
25
|
+
///
|
26
|
+
/// @example scss Marking spacing declarations as important
|
27
|
+
/// .element {
|
28
|
+
/// margin-top: govuk-spacing(1) !important;
|
29
|
+
/// }
|
30
|
+
///
|
20
31
|
/// @access public
|
21
32
|
|
22
33
|
@function govuk-spacing($spacing-point) {
|
@@ -27,11 +38,18 @@
|
|
27
38
|
+ "#{$actual-input-type}.";
|
28
39
|
}
|
29
40
|
|
41
|
+
$is-negative: false;
|
42
|
+
@if ($spacing-point < 0) {
|
43
|
+
$is-negative: true;
|
44
|
+
$spacing-point: abs($spacing-point);
|
45
|
+
}
|
46
|
+
|
30
47
|
@if not map-has-key($govuk-spacing-points, $spacing-point) {
|
31
48
|
@error "Unknown spacing variable `#{$spacing-point}`. Make sure you are using a point from the spacing scale in `_settings/spacing.scss`.";
|
32
49
|
}
|
33
50
|
|
34
|
-
|
51
|
+
$value: map-get($govuk-spacing-points, $spacing-point);
|
52
|
+
@return if($is-negative, $value * -1, $value);
|
35
53
|
}
|
36
54
|
|
37
55
|
/// Responsive spacing
|
@@ -0,0 +1,20 @@
|
|
1
|
+
@if not mixin-exists("govuk-exports") {
|
2
|
+
@warn "Importing items from the overrides layer without first importing `base` is deprecated, and will no longer work as of GOV.UK Frontend v4.0.";
|
3
|
+
}
|
4
|
+
|
5
|
+
@import "../base";
|
6
|
+
|
7
|
+
// stylelint-disable declaration-no-important
|
8
|
+
@include govuk-exports("govuk/overrides/text-align") {
|
9
|
+
.govuk-\!-text-align-left {
|
10
|
+
text-align: left !important;
|
11
|
+
}
|
12
|
+
|
13
|
+
.govuk-\!-text-align-centre {
|
14
|
+
text-align: center !important;
|
15
|
+
}
|
16
|
+
|
17
|
+
.govuk-\!-text-align-right {
|
18
|
+
text-align: right !important;
|
19
|
+
}
|
20
|
+
}
|
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "govuk-frontend",
|
3
3
|
"description": "GOV.UK Frontend contains the code you need to start building a user interface for government platforms and services.",
|
4
|
-
"version": "3.
|
4
|
+
"version": "3.14.0",
|
5
5
|
"main": "govuk/all.js",
|
6
6
|
"sass": "govuk/all.scss",
|
7
7
|
"engines": {
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: govuk_publishing_components
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 27.
|
4
|
+
version: 27.12.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- GOV.UK Dev
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-11-
|
11
|
+
date: 2021-11-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: govuk_app_config
|
@@ -192,20 +192,6 @@ dependencies:
|
|
192
192
|
- - ">="
|
193
193
|
- !ruby/object:Gem::Version
|
194
194
|
version: '0'
|
195
|
-
- !ruby/object:Gem::Dependency
|
196
|
-
name: i18n-tasks
|
197
|
-
requirement: !ruby/object:Gem::Requirement
|
198
|
-
requirements:
|
199
|
-
- - ">="
|
200
|
-
- !ruby/object:Gem::Version
|
201
|
-
version: '0'
|
202
|
-
type: :development
|
203
|
-
prerelease: false
|
204
|
-
version_requirements: !ruby/object:Gem::Requirement
|
205
|
-
requirements:
|
206
|
-
- - ">="
|
207
|
-
- !ruby/object:Gem::Version
|
208
|
-
version: '0'
|
209
195
|
- !ruby/object:Gem::Dependency
|
210
196
|
name: jasmine
|
211
197
|
requirement: !ruby/object:Gem::Requirement
|
@@ -268,6 +254,20 @@ dependencies:
|
|
268
254
|
- - ">="
|
269
255
|
- !ruby/object:Gem::Version
|
270
256
|
version: '0'
|
257
|
+
- !ruby/object:Gem::Dependency
|
258
|
+
name: rails_translation_manager
|
259
|
+
requirement: !ruby/object:Gem::Requirement
|
260
|
+
requirements:
|
261
|
+
- - ">="
|
262
|
+
- !ruby/object:Gem::Version
|
263
|
+
version: '0'
|
264
|
+
type: :development
|
265
|
+
prerelease: false
|
266
|
+
version_requirements: !ruby/object:Gem::Requirement
|
267
|
+
requirements:
|
268
|
+
- - ">="
|
269
|
+
- !ruby/object:Gem::Version
|
270
|
+
version: '0'
|
271
271
|
- !ruby/object:Gem::Dependency
|
272
272
|
name: rake
|
273
273
|
requirement: !ruby/object:Gem::Requirement
|
@@ -591,6 +591,7 @@ files:
|
|
591
591
|
- app/assets/stylesheets/govuk_publishing_components/components/_select.scss
|
592
592
|
- app/assets/stylesheets/govuk_publishing_components/components/_share-links.scss
|
593
593
|
- app/assets/stylesheets/govuk_publishing_components/components/_show-password.scss
|
594
|
+
- app/assets/stylesheets/govuk_publishing_components/components/_single-page-notification-button.scss
|
594
595
|
- app/assets/stylesheets/govuk_publishing_components/components/_skip-link.scss
|
595
596
|
- app/assets/stylesheets/govuk_publishing_components/components/_step-by-step-nav-header.scss
|
596
597
|
- app/assets/stylesheets/govuk_publishing_components/components/_step-by-step-nav-related.scss
|
@@ -636,6 +637,7 @@ files:
|
|
636
637
|
- app/assets/stylesheets/govuk_publishing_components/components/mixins/_govuk-template-link-focus-override.scss
|
637
638
|
- app/assets/stylesheets/govuk_publishing_components/components/mixins/_margins.scss
|
638
639
|
- app/assets/stylesheets/govuk_publishing_components/components/mixins/_media-down.scss
|
640
|
+
- app/assets/stylesheets/govuk_publishing_components/components/mixins/_prefixed-transform.scss
|
639
641
|
- app/assets/stylesheets/govuk_publishing_components/components/print/_accordion.scss
|
640
642
|
- app/assets/stylesheets/govuk_publishing_components/components/print/_button.scss
|
641
643
|
- app/assets/stylesheets/govuk_publishing_components/components/print/_contents-list.scss
|
@@ -736,6 +738,7 @@ files:
|
|
736
738
|
- app/views/govuk_publishing_components/components/_select.html.erb
|
737
739
|
- app/views/govuk_publishing_components/components/_share_links.html.erb
|
738
740
|
- app/views/govuk_publishing_components/components/_show_password.html.erb
|
741
|
+
- app/views/govuk_publishing_components/components/_single_page_notification_button.html.erb
|
739
742
|
- app/views/govuk_publishing_components/components/_skip_link.html.erb
|
740
743
|
- app/views/govuk_publishing_components/components/_step_by_step_nav.html.erb
|
741
744
|
- app/views/govuk_publishing_components/components/_step_by_step_nav_header.html.erb
|
@@ -819,6 +822,7 @@ files:
|
|
819
822
|
- app/views/govuk_publishing_components/components/docs/select.yml
|
820
823
|
- app/views/govuk_publishing_components/components/docs/share_links.yml
|
821
824
|
- app/views/govuk_publishing_components/components/docs/show_password.yml
|
825
|
+
- app/views/govuk_publishing_components/components/docs/single_page_notification_button.yml
|
822
826
|
- app/views/govuk_publishing_components/components/docs/skip_link.yml
|
823
827
|
- app/views/govuk_publishing_components/components/docs/step_by_step_nav.yml
|
824
828
|
- app/views/govuk_publishing_components/components/docs/step_by_step_nav_header.yml
|
@@ -928,7 +932,6 @@ files:
|
|
928
932
|
- lib/govuk_publishing_components/presenters/attachment.rb
|
929
933
|
- lib/govuk_publishing_components/presenters/breadcrumb_selector.rb
|
930
934
|
- lib/govuk_publishing_components/presenters/breadcrumbs.rb
|
931
|
-
- lib/govuk_publishing_components/presenters/brexit_cta_helper.rb
|
932
935
|
- lib/govuk_publishing_components/presenters/button_helper.rb
|
933
936
|
- lib/govuk_publishing_components/presenters/checkboxes_helper.rb
|
934
937
|
- lib/govuk_publishing_components/presenters/content_breadcrumbs_based_on_ancestors.rb
|
@@ -1847,6 +1850,7 @@ files:
|
|
1847
1850
|
- node_modules/govuk-frontend/govuk/overrides/_all.scss
|
1848
1851
|
- node_modules/govuk-frontend/govuk/overrides/_display.scss
|
1849
1852
|
- node_modules/govuk-frontend/govuk/overrides/_spacing.scss
|
1853
|
+
- node_modules/govuk-frontend/govuk/overrides/_text-align.scss
|
1850
1854
|
- node_modules/govuk-frontend/govuk/overrides/_typography.scss
|
1851
1855
|
- node_modules/govuk-frontend/govuk/overrides/_width.scss
|
1852
1856
|
- node_modules/govuk-frontend/govuk/settings/_all.scss
|
@@ -1,33 +0,0 @@
|
|
1
|
-
module GovukPublishingComponents
|
2
|
-
module Presenters
|
3
|
-
class BrexitCtaHelper
|
4
|
-
BREXIT_HUB_PAGE_IDS = %w[
|
5
|
-
6555e0bf-c270-4cf9-a0c5-d20b95fab7f1
|
6
|
-
91cd6143-69d5-4f27-99ff-a52fb0d51c78
|
7
|
-
].freeze
|
8
|
-
|
9
|
-
def initialize(content_item)
|
10
|
-
@content_item = content_item
|
11
|
-
end
|
12
|
-
|
13
|
-
def title_key
|
14
|
-
use_brexit_hub_page_navigation? ? "components.related_navigation.transition.hub_page_title" : "components.related_navigation.transition.title"
|
15
|
-
end
|
16
|
-
|
17
|
-
def link_text_key
|
18
|
-
use_brexit_hub_page_navigation? ? "components.related_navigation.transition.hub_page_link_text" : "components.related_navigation.transition.link_text"
|
19
|
-
end
|
20
|
-
|
21
|
-
def link_path_key
|
22
|
-
use_brexit_hub_page_navigation? ? "components.related_navigation.transition.hub_page_link_path" : "components.related_navigation.transition.link_path"
|
23
|
-
end
|
24
|
-
|
25
|
-
private
|
26
|
-
|
27
|
-
def use_brexit_hub_page_navigation?
|
28
|
-
I18n.locale == :en &&
|
29
|
-
BREXIT_HUB_PAGE_IDS.include?(@content_item["content_id"])
|
30
|
-
end
|
31
|
-
end
|
32
|
-
end
|
33
|
-
end
|