dxw_govuk_frontend_rails 3.8.0 → 3.12.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.
Files changed (66) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +2 -2
  3. data/README.md +61 -40
  4. data/lib/dxw_govuk_frontend_rails/version.rb +1 -1
  5. data/package-lock.json +22 -4
  6. data/package.json +1 -1
  7. data/vendor/assets/javascripts/govuk_frontend_rails.js +84 -33
  8. data/vendor/assets/stylesheets/components/_all.scss +2 -0
  9. data/vendor/assets/stylesheets/components/accordion/_index.scss +7 -17
  10. data/vendor/assets/stylesheets/components/back-link/_index.scss +4 -17
  11. data/vendor/assets/stylesheets/components/breadcrumbs/_index.scss +0 -1
  12. data/vendor/assets/stylesheets/components/button/_index.scss +5 -3
  13. data/vendor/assets/stylesheets/components/character-count/_index.scss +1 -4
  14. data/vendor/assets/stylesheets/components/checkboxes/_index.scss +13 -13
  15. data/vendor/assets/stylesheets/components/cookie-banner/_cookie-banner.scss +2 -0
  16. data/vendor/assets/stylesheets/components/cookie-banner/_index.scss +51 -0
  17. data/vendor/assets/stylesheets/components/details/_index.scss +5 -2
  18. data/vendor/assets/stylesheets/components/error-summary/_index.scss +2 -14
  19. data/vendor/assets/stylesheets/components/fieldset/_index.scss +1 -1
  20. data/vendor/assets/stylesheets/components/file-upload/_index.scss +13 -14
  21. data/vendor/assets/stylesheets/components/footer/_index.scss +14 -20
  22. data/vendor/assets/stylesheets/components/header/_index.scss +41 -26
  23. data/vendor/assets/stylesheets/components/hint/_index.scss +0 -2
  24. data/vendor/assets/stylesheets/components/input/_index.scss +91 -0
  25. data/vendor/assets/stylesheets/components/notification-banner/_index.scss +89 -0
  26. data/vendor/assets/stylesheets/components/notification-banner/_notification-banner.scss +2 -0
  27. data/vendor/assets/stylesheets/components/panel/_index.scss +6 -2
  28. data/vendor/assets/stylesheets/components/phase-banner/_index.scss +1 -1
  29. data/vendor/assets/stylesheets/components/radios/_index.scss +13 -13
  30. data/vendor/assets/stylesheets/components/select/_index.scss +0 -1
  31. data/vendor/assets/stylesheets/components/skip-link/_index.scss +1 -1
  32. data/vendor/assets/stylesheets/components/summary-list/_index.scss +2 -10
  33. data/vendor/assets/stylesheets/components/table/_index.scss +21 -0
  34. data/vendor/assets/stylesheets/components/tabs/_index.scss +4 -12
  35. data/vendor/assets/stylesheets/components/tag/_index.scss +0 -1
  36. data/vendor/assets/stylesheets/components/textarea/_index.scss +0 -1
  37. data/vendor/assets/stylesheets/components/warning-text/_index.scss +10 -1
  38. data/vendor/assets/stylesheets/core/_links.scss +8 -0
  39. data/vendor/assets/stylesheets/helpers/_device-pixels.scss +3 -3
  40. data/vendor/assets/stylesheets/helpers/_font-faces.scss +9 -11
  41. data/vendor/assets/stylesheets/helpers/_links.scss +239 -32
  42. data/vendor/assets/stylesheets/helpers/_media-queries.scss +1 -5
  43. data/vendor/assets/stylesheets/helpers/_spacing.scss +2 -1
  44. data/vendor/assets/stylesheets/helpers/_typography.scss +7 -6
  45. data/vendor/assets/stylesheets/objects/_all.scss +1 -0
  46. data/vendor/assets/stylesheets/objects/_button-group.scss +94 -0
  47. data/vendor/assets/stylesheets/objects/_form-group.scss +0 -1
  48. data/vendor/assets/stylesheets/objects/_grid.scss +2 -3
  49. data/vendor/assets/stylesheets/objects/_main-wrapper.scss +0 -1
  50. data/vendor/assets/stylesheets/overrides/_display.scss +1 -1
  51. data/vendor/assets/stylesheets/overrides/_width.scss +1 -0
  52. data/vendor/assets/stylesheets/settings/_all.scss +2 -0
  53. data/vendor/assets/stylesheets/settings/_colours-applied.scss +9 -3
  54. data/vendor/assets/stylesheets/settings/_colours-organisations.scss +3 -0
  55. data/vendor/assets/stylesheets/settings/_colours-palette.scss +42 -35
  56. data/vendor/assets/stylesheets/settings/_compatibility.scss +0 -1
  57. data/vendor/assets/stylesheets/settings/_links.scss +62 -0
  58. data/vendor/assets/stylesheets/settings/_measurements.scss +0 -4
  59. data/vendor/assets/stylesheets/settings/_typography-font-families.scss +2 -2
  60. data/vendor/assets/stylesheets/settings/_typography-font.scss +14 -5
  61. data/vendor/assets/stylesheets/settings/_typography-responsive.scss +6 -2
  62. data/vendor/assets/stylesheets/tools/_font-url.scss +0 -3
  63. data/vendor/assets/stylesheets/tools/_image-url.scss +0 -3
  64. data/vendor/assets/stylesheets/utilities/_visually-hidden.scss +0 -1
  65. data/vendor/assets/stylesheets/vendor/_sass-mq.scss +0 -4
  66. metadata +9 -3
@@ -1,5 +1,8 @@
1
1
  @import "compatibility";
2
2
 
3
+ // stylelint-disable value-list-max-empty-lines -- allow empty lines in lists
4
+ // in this file to allow grouping
5
+
3
6
  ////
4
7
  /// @group settings/colours
5
8
  ////
@@ -13,44 +16,15 @@
13
16
  /// @type Boolean
14
17
  /// @access public
15
18
 
16
- $govuk-use-legacy-palette: if((
19
+ $govuk-use-legacy-palette: if(
20
+ (
17
21
  $govuk-compatibility-govukfrontendtoolkit or
18
22
  $govuk-compatibility-govuktemplate or
19
23
  $govuk-compatibility-govukelements
20
- ), true, false) !default;
21
-
22
- /// Legacy colour palette
23
- ///
24
- /// This exists only because you cannot easily set a !default variable
25
- /// conditionally (thanks to the way scope works in Sass) so we set
26
- /// `$govuk-colour-palette` using the `if` function.
27
- ///
28
- /// @access private
29
-
30
- $_govuk-colour-palette-legacy: (
31
- "purple": #2e358b,
32
- "light-purple": #6f72af,
33
- "bright-purple": #912b88,
34
- "pink": #d53880,
35
- "light-pink": #f499be,
36
- "red": #b10e1e,
37
- "bright-red": #df3034,
38
- "orange": #f47738,
39
- "brown": #b58840,
40
- "yellow": #ffbf47,
41
- "light-green": #85994b,
42
- "green": #006435,
43
- "turquoise": #28a197,
44
- "light-blue": #2b8cc4,
45
- "blue": #005ea5,
46
-
47
- "black": #0b0c0c,
48
- "grey-1": #6f777b,
49
- "grey-2": #bfc1c3,
50
- "grey-3": #dee0e2,
51
- "grey-4": #f8f8f8,
52
- "white": #ffffff
53
- );
24
+ ),
25
+ true,
26
+ false
27
+ ) !default;
54
28
 
55
29
  /// Modern colour palette
56
30
  ///
@@ -85,6 +59,39 @@ $_govuk-colour-palette-modern: (
85
59
  "turquoise": #28a197
86
60
  );
87
61
 
62
+ /// Legacy colour palette
63
+ ///
64
+ /// This exists only because you cannot easily set a !default variable
65
+ /// conditionally (thanks to the way scope works in Sass) so we set
66
+ /// `$govuk-colour-palette` using the `if` function.
67
+ ///
68
+ /// @access private
69
+
70
+ $_govuk-colour-palette-legacy: (
71
+ "purple": #2e358b,
72
+ "light-purple": #6f72af,
73
+ "bright-purple": #912b88,
74
+ "pink": #d53880,
75
+ "light-pink": #f499be,
76
+ "red": #b10e1e,
77
+ "bright-red": #df3034,
78
+ "orange": #f47738,
79
+ "brown": #b58840,
80
+ "yellow": #ffbf47,
81
+ "light-green": #85994b,
82
+ "green": #006435,
83
+ "turquoise": #28a197,
84
+ "light-blue": #2b8cc4,
85
+ "blue": #005ea5,
86
+
87
+ "black": #0b0c0c,
88
+ "grey-1": #6f777b,
89
+ "grey-2": #bfc1c3,
90
+ "grey-3": #dee0e2,
91
+ "grey-4": #f8f8f8,
92
+ "white": #ffffff
93
+ );
94
+
88
95
  /// Colour palette
89
96
  ///
90
97
  /// @type Map
@@ -16,7 +16,6 @@
16
16
  /// @group settings/compatibility
17
17
  ////
18
18
 
19
-
20
19
  /// Compatibility Mode: alphagov/govuk_frontend_toolkit
21
20
  ///
22
21
  /// Set this to true if you are also including alphagov/govuk_frontend_toolkit
@@ -0,0 +1,62 @@
1
+ ////
2
+ /// @group settings/links
3
+ ////
4
+
5
+ /// Enable new link styles
6
+ ///
7
+ /// If enabled, the link styles will change. Underlines will:
8
+ ///
9
+ /// - be consistently thinner and a bit further away from the link text
10
+ /// - have a clearer hover state, where the underline gets thicker to make the
11
+ /// link stand out to users
12
+ ///
13
+ /// You should only enable the new link styles if both:
14
+ ///
15
+ /// - you've made sure your whole service will use the new style consistently
16
+ /// - you do not have links in a multi-column CSS layout - there's [a Chromium
17
+ /// bug that affects links](https://github.com/alphagov/govuk-frontend/issues/2204)
18
+ ///
19
+ /// @type Boolean
20
+ /// @access public
21
+
22
+ $govuk-new-link-styles: false !default;
23
+
24
+ /// Thickness of link underlines
25
+ ///
26
+ /// The default will be either:
27
+ ///
28
+ /// - 1px
29
+ /// - 0.0625rem, if it's thicker than 1px because the user has changed the text
30
+ /// size in their browser
31
+ ///
32
+ /// Set this variable to `false` to avoid setting a thickness.
33
+ ///
34
+ /// @type Number
35
+ /// @access public
36
+
37
+ $govuk-link-underline-thickness: unquote("max(1px, .0625rem)") !default;
38
+
39
+ /// Offset of link underlines from text baseline
40
+ ///
41
+ /// Set this variable to `false` to avoid setting an offset.
42
+ ///
43
+ /// @type Number
44
+ /// @access public
45
+
46
+ $govuk-link-underline-offset: .1em !default;
47
+
48
+ /// Thickness of link underlines in hover state
49
+ ///
50
+ /// The default for each link will be the thickest of the following:
51
+ ///
52
+ /// - 3px
53
+ /// - 0.1875rem, if it's thicker than 3px because the user has changed the text
54
+ /// size in their browser
55
+ /// - 0.12em (relative to the link's text size)
56
+ ///
57
+ /// Set this variable to `false` to avoid setting a thickness.
58
+ ///
59
+ /// @type Number
60
+ /// @access public
61
+
62
+ $govuk-link-hover-underline-thickness: unquote("max(3px, .1875rem, .12em)") !default;
@@ -2,8 +2,6 @@
2
2
  /// @group settings/measurements
3
3
  ////
4
4
 
5
-
6
-
7
5
  // =========================================================
8
6
  // Page layout
9
7
  // =========================================================
@@ -43,8 +41,6 @@ $govuk-gutter: 30px !default;
43
41
 
44
42
  $govuk-gutter-half: $govuk-gutter / 2;
45
43
 
46
-
47
-
48
44
  // =========================================================
49
45
  // Borders
50
46
  // =========================================================
@@ -8,7 +8,7 @@
8
8
  /// @type List
9
9
  /// @access public
10
10
 
11
- $govuk-font-family-gds-transport: "GDS Transport", Arial, sans-serif;
11
+ $govuk-font-family-gds-transport: "GDS Transport", arial, sans-serif;
12
12
 
13
13
  /// List of font families to use if using NTA (old font 'stack' for
14
14
  /// GOV.UK)
@@ -17,7 +17,7 @@ $govuk-font-family-gds-transport: "GDS Transport", Arial, sans-serif;
17
17
  /// @access public
18
18
  /// @deprecated To be removed once support for compatibility mode is dropped
19
19
 
20
- $govuk-font-family-nta: "nta", Arial, sans-serif;
20
+ $govuk-font-family-nta: "nta", arial, sans-serif;
21
21
 
22
22
  /// List of font families to use if using the 'tabular numbers' subset of NTA
23
23
  /// (the default font 'stack' for GOV.UK)
@@ -14,11 +14,15 @@
14
14
  /// @type Boolean
15
15
  /// @access public
16
16
 
17
- $govuk-use-legacy-font: if((
17
+ $govuk-use-legacy-font: if(
18
+ (
18
19
  $govuk-compatibility-govukfrontendtoolkit or
19
20
  $govuk-compatibility-govuktemplate or
20
21
  $govuk-compatibility-govukelements
21
- ), true, false) !default;
22
+ ),
23
+ true,
24
+ false
25
+ ) !default;
22
26
 
23
27
  // =========================================================
24
28
  // Font families
@@ -29,7 +33,8 @@ $govuk-use-legacy-font: if((
29
33
  /// @type List
30
34
  /// @access public
31
35
 
32
- $govuk-font-family: if($govuk-use-legacy-font,
36
+ $govuk-font-family: if(
37
+ $govuk-use-legacy-font,
33
38
  $govuk-font-family-nta,
34
39
  $govuk-font-family-gds-transport
35
40
  ) !default;
@@ -39,13 +44,17 @@ $govuk-font-family: if($govuk-use-legacy-font,
39
44
  /// @type List
40
45
  /// @access public
41
46
 
42
- $govuk-font-family-tabular: if($govuk-use-legacy-font,
47
+ $govuk-font-family-tabular: if(
48
+ $govuk-use-legacy-font,
43
49
  $govuk-font-family-nta-tabular,
44
50
  false
45
51
  ) !default;
46
52
 
47
53
  /// Font families to use for print media
48
54
  ///
55
+ /// We recommend that you use system fonts when printing. This will avoid issues
56
+ /// with some printer drivers and operating systems.
57
+ ///
49
58
  /// @type List
50
59
  /// @access public
51
60
 
@@ -61,7 +70,7 @@ $govuk-font-family-print: sans-serif !default;
61
70
 
62
71
  $govuk-include-default-font-face: (
63
72
  $govuk-font-family == $govuk-font-family-gds-transport
64
- ) !default;
73
+ ) !default;
65
74
 
66
75
  // =========================================================
67
76
  // Font weights
@@ -14,11 +14,15 @@
14
14
  /// @type Boolean
15
15
  /// @access public
16
16
 
17
- $govuk-typography-use-rem: if((
17
+ $govuk-typography-use-rem: if(
18
+ (
18
19
  $govuk-compatibility-govukfrontendtoolkit or
19
20
  $govuk-compatibility-govuktemplate or
20
21
  $govuk-compatibility-govukelements
21
- ), false, true) !default;
22
+ ),
23
+ false,
24
+ true
25
+ ) !default;
22
26
 
23
27
  /// Root font size
24
28
  ///
@@ -2,9 +2,6 @@
2
2
  /// @group tools/assets
3
3
  ////
4
4
 
5
- // Disable indentation linting in this file only
6
- // sass-lint:disable indentation
7
-
8
5
  /// Font URL
9
6
  ///
10
7
  /// If a custom font-url handler is defined ($govuk-font-url-function) then
@@ -2,9 +2,6 @@
2
2
  /// @group tools/assets
3
3
  ////
4
4
 
5
- // Disable indentation linting in this file only
6
- // sass-lint:disable indentation
7
-
8
5
  /// Image URL
9
6
  ///
10
7
  /// If a custom image-url handler is defined ($govuk-image-url-function) then
@@ -6,5 +6,4 @@
6
6
  .govuk-visually-hidden-focusable {
7
7
  @include govuk-visually-hidden-focusable;
8
8
  }
9
-
10
9
  }
@@ -1,8 +1,6 @@
1
1
  // mq() v4.0.2
2
2
  // sass-mq/sass-mq
3
3
 
4
- // sass-lint:disable-all
5
-
6
4
  @charset "UTF-8"; // Fixes an issue where Ruby locale is not set properly
7
5
  // See https://github.com/sass-mq/sass-mq/pull/10
8
6
 
@@ -347,5 +345,3 @@ $mq-media-type: all !default;
347
345
  @if length($mq-show-breakpoints) > 0 {
348
346
  @include mq-show-breakpoints;
349
347
  }
350
-
351
- // sass-lint:enable-all
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dxw_govuk_frontend_rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.8.0
4
+ version: 3.12.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - mec
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2020-12-23 00:00:00.000000000 Z
12
+ date: 2021-11-12 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bundler
@@ -93,6 +93,8 @@ files:
93
93
  - vendor/assets/stylesheets/components/character-count/_index.scss
94
94
  - vendor/assets/stylesheets/components/checkboxes/_checkboxes.scss
95
95
  - vendor/assets/stylesheets/components/checkboxes/_index.scss
96
+ - vendor/assets/stylesheets/components/cookie-banner/_cookie-banner.scss
97
+ - vendor/assets/stylesheets/components/cookie-banner/_index.scss
96
98
  - vendor/assets/stylesheets/components/date-input/_date-input.scss
97
99
  - vendor/assets/stylesheets/components/date-input/_index.scss
98
100
  - vendor/assets/stylesheets/components/details/_details.scss
@@ -117,6 +119,8 @@ files:
117
119
  - vendor/assets/stylesheets/components/inset-text/_inset-text.scss
118
120
  - vendor/assets/stylesheets/components/label/_index.scss
119
121
  - vendor/assets/stylesheets/components/label/_label.scss
122
+ - vendor/assets/stylesheets/components/notification-banner/_index.scss
123
+ - vendor/assets/stylesheets/components/notification-banner/_notification-banner.scss
120
124
  - vendor/assets/stylesheets/components/panel/_index.scss
121
125
  - vendor/assets/stylesheets/components/panel/_panel.scss
122
126
  - vendor/assets/stylesheets/components/phase-banner/_index.scss
@@ -161,6 +165,7 @@ files:
161
165
  - vendor/assets/stylesheets/helpers/_typography.scss
162
166
  - vendor/assets/stylesheets/helpers/_visually-hidden.scss
163
167
  - vendor/assets/stylesheets/objects/_all.scss
168
+ - vendor/assets/stylesheets/objects/_button-group.scss
164
169
  - vendor/assets/stylesheets/objects/_form-group.scss
165
170
  - vendor/assets/stylesheets/objects/_grid.scss
166
171
  - vendor/assets/stylesheets/objects/_main-wrapper.scss
@@ -178,6 +183,7 @@ files:
178
183
  - vendor/assets/stylesheets/settings/_compatibility.scss
179
184
  - vendor/assets/stylesheets/settings/_global-styles.scss
180
185
  - vendor/assets/stylesheets/settings/_ie8.scss
186
+ - vendor/assets/stylesheets/settings/_links.scss
181
187
  - vendor/assets/stylesheets/settings/_measurements.scss
182
188
  - vendor/assets/stylesheets/settings/_media-queries.scss
183
189
  - vendor/assets/stylesheets/settings/_spacing.scss
@@ -216,7 +222,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
216
222
  - !ruby/object:Gem::Version
217
223
  version: '0'
218
224
  requirements: []
219
- rubygems_version: 3.1.4
225
+ rubygems_version: 3.2.22
220
226
  signing_key:
221
227
  specification_version: 4
222
228
  summary: Adds the GOVUK frontend to a Rails application that uses the Asset Pipeline.