dxw_govuk_frontend_rails 3.3.1 → 3.8.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CONTRIBUTING.md +1 -0
- data/Gemfile.lock +5 -4
- data/README.md +45 -42
- data/dxw_govuk_frontend_rails.gemspec +1 -1
- data/lib/dxw_govuk_frontend_rails/version.rb +1 -1
- data/package-lock.json +3 -3
- data/package.json +1 -1
- data/vendor/assets/javascripts/govuk_frontend_rails.js +194 -118
- data/vendor/assets/stylesheets/_base.scss +3 -0
- data/vendor/assets/stylesheets/all.scss +1 -3
- data/vendor/assets/stylesheets/components/_all.scss +31 -29
- data/vendor/assets/stylesheets/components/accordion/_accordion.scss +2 -208
- data/vendor/assets/stylesheets/components/accordion/_index.scss +207 -0
- data/vendor/assets/stylesheets/components/back-link/_back-link.scss +2 -62
- data/vendor/assets/stylesheets/components/back-link/_index.scss +112 -0
- data/vendor/assets/stylesheets/components/breadcrumbs/_breadcrumbs.scss +2 -118
- data/vendor/assets/stylesheets/components/breadcrumbs/_index.scss +138 -0
- data/vendor/assets/stylesheets/components/button/_button.scss +2 -290
- data/vendor/assets/stylesheets/components/button/_index.scss +280 -0
- data/vendor/assets/stylesheets/components/character-count/_character-count.scss +2 -31
- data/vendor/assets/stylesheets/components/character-count/_index.scss +28 -0
- data/vendor/assets/stylesheets/components/checkboxes/_checkboxes.scss +2 -308
- data/vendor/assets/stylesheets/components/checkboxes/_index.scss +305 -0
- data/vendor/assets/stylesheets/components/date-input/_date-input.scss +2 -30
- data/vendor/assets/stylesheets/components/date-input/_index.scss +26 -0
- data/vendor/assets/stylesheets/components/details/_details.scss +2 -88
- data/vendor/assets/stylesheets/components/details/_index.scss +84 -0
- data/vendor/assets/stylesheets/components/error-message/_error-message.scss +2 -15
- data/vendor/assets/stylesheets/components/error-message/_index.scss +11 -0
- data/vendor/assets/stylesheets/components/error-summary/_error-summary.scss +2 -59
- data/vendor/assets/stylesheets/components/error-summary/_index.scss +55 -0
- data/vendor/assets/stylesheets/components/fieldset/_fieldset.scss +2 -68
- data/vendor/assets/stylesheets/components/fieldset/_index.scss +64 -0
- data/vendor/assets/stylesheets/components/file-upload/_file-upload.scss +2 -81
- data/vendor/assets/stylesheets/components/file-upload/_index.scss +50 -0
- data/vendor/assets/stylesheets/components/footer/_footer.scss +2 -269
- data/vendor/assets/stylesheets/components/footer/_index.scss +235 -0
- data/vendor/assets/stylesheets/components/header/_header.scss +2 -318
- data/vendor/assets/stylesheets/components/header/_index.scss +312 -0
- data/vendor/assets/stylesheets/components/hint/_hint.scss +2 -50
- data/vendor/assets/stylesheets/components/hint/_index.scss +46 -0
- data/vendor/assets/stylesheets/components/input/_index.scss +96 -0
- data/vendor/assets/stylesheets/components/input/_input.scss +2 -103
- data/vendor/assets/stylesheets/components/inset-text/_index.scss +24 -0
- data/vendor/assets/stylesheets/components/inset-text/_inset-text.scss +2 -28
- data/vendor/assets/stylesheets/components/label/_index.scss +41 -0
- data/vendor/assets/stylesheets/components/label/_label.scss +2 -45
- data/vendor/assets/stylesheets/components/panel/_index.scss +40 -0
- data/vendor/assets/stylesheets/components/panel/_panel.scss +2 -44
- data/vendor/assets/stylesheets/components/phase-banner/_index.scss +27 -0
- data/vendor/assets/stylesheets/components/phase-banner/_phase-banner.scss +2 -31
- data/vendor/assets/stylesheets/components/radios/_index.scss +342 -0
- data/vendor/assets/stylesheets/components/radios/_radios.scss +2 -346
- data/vendor/assets/stylesheets/components/select/_index.scss +50 -0
- data/vendor/assets/stylesheets/components/select/_select.scss +2 -57
- data/vendor/assets/stylesheets/components/skip-link/_index.scss +34 -0
- data/vendor/assets/stylesheets/components/skip-link/_skip-link.scss +2 -31
- data/vendor/assets/stylesheets/components/summary-list/_index.scss +153 -0
- data/vendor/assets/stylesheets/components/summary-list/_summary-list.scss +2 -157
- data/vendor/assets/stylesheets/components/table/_index.scss +50 -0
- data/vendor/assets/stylesheets/components/table/_table.scss +2 -54
- data/vendor/assets/stylesheets/components/tabs/_index.scss +138 -0
- data/vendor/assets/stylesheets/components/tabs/_tabs.scss +2 -142
- data/vendor/assets/stylesheets/components/tag/_index.scss +87 -0
- data/vendor/assets/stylesheets/components/tag/_tag.scss +2 -44
- data/vendor/assets/stylesheets/components/textarea/_index.scss +48 -0
- data/vendor/assets/stylesheets/components/textarea/_textarea.scss +2 -55
- data/vendor/assets/stylesheets/components/warning-text/_index.scss +58 -0
- data/vendor/assets/stylesheets/components/warning-text/_warning-text.scss +2 -60
- data/vendor/assets/stylesheets/core/_global-styles.scss +5 -3
- data/vendor/assets/stylesheets/core/_links.scss +5 -3
- data/vendor/assets/stylesheets/core/_lists.scss +17 -3
- data/vendor/assets/stylesheets/core/_section-break.scss +5 -3
- data/vendor/assets/stylesheets/core/_template.scss +5 -3
- data/vendor/assets/stylesheets/core/_typography.scss +5 -3
- data/vendor/assets/stylesheets/helpers/_clearfix.scss +1 -1
- data/vendor/assets/stylesheets/helpers/_colour.scss +1 -1
- data/vendor/assets/stylesheets/helpers/_focused.scss +1 -1
- data/vendor/assets/stylesheets/helpers/_grid.scss +2 -1
- data/vendor/assets/stylesheets/helpers/_links.scss +1 -1
- data/vendor/assets/stylesheets/helpers/_media-queries.scss +1 -1
- data/vendor/assets/stylesheets/helpers/_shape-arrow.scss +1 -1
- data/vendor/assets/stylesheets/helpers/_spacing.scss +5 -5
- data/vendor/assets/stylesheets/helpers/_typography.scss +6 -6
- data/vendor/assets/stylesheets/helpers/_visually-hidden.scss +30 -30
- data/vendor/assets/stylesheets/objects/_form-group.scss +1 -3
- data/vendor/assets/stylesheets/objects/_grid.scss +1 -3
- data/vendor/assets/stylesheets/objects/_main-wrapper.scss +5 -3
- data/vendor/assets/stylesheets/objects/_width-container.scss +34 -13
- data/vendor/assets/stylesheets/overrides/_display.scss +11 -3
- data/vendor/assets/stylesheets/overrides/_spacing.scss +5 -3
- data/vendor/assets/stylesheets/overrides/_typography.scss +5 -3
- data/vendor/assets/stylesheets/overrides/_width.scss +5 -3
- data/vendor/assets/stylesheets/settings/_colours-applied.scss +2 -2
- data/vendor/assets/stylesheets/settings/_colours-palette.scss +1 -1
- data/vendor/assets/stylesheets/settings/_ie8.scss +1 -1
- data/vendor/assets/stylesheets/settings/_measurements.scss +4 -1
- data/vendor/assets/stylesheets/tools/_compatibility.scss +1 -1
- data/vendor/assets/stylesheets/tools/_font-url.scss +1 -1
- data/vendor/assets/stylesheets/tools/_ie8.scss +1 -1
- data/vendor/assets/stylesheets/tools/_iff.scss +3 -1
- data/vendor/assets/stylesheets/tools/_image-url.scss +1 -1
- data/vendor/assets/stylesheets/tools/_px-to-em.scss +1 -1
- data/vendor/assets/stylesheets/tools/_px-to-rem.scss +1 -1
- metadata +36 -5
@@ -1,13 +1,30 @@
|
|
1
|
-
@import "../
|
2
|
-
@import "../tools/all";
|
3
|
-
@import "../helpers/all";
|
1
|
+
@import "../base";
|
4
2
|
|
5
|
-
|
6
|
-
|
7
|
-
|
3
|
+
////
|
4
|
+
/// @group objects/layout
|
5
|
+
////
|
6
|
+
|
7
|
+
/// Width container mixin
|
8
|
+
///
|
9
|
+
/// Used to create page width and custom width container classes.
|
10
|
+
///
|
11
|
+
/// @param {String} $width [$govuk-page-width] - Width in pixels
|
12
|
+
///
|
13
|
+
/// @example scss - Creating a 1200px wide container class
|
14
|
+
/// .app-width-container--wide {
|
15
|
+
/// @include govuk-width-container(1200px);
|
16
|
+
/// }
|
17
|
+
///
|
18
|
+
/// @access public
|
19
|
+
|
20
|
+
@mixin govuk-width-container($width: $govuk-page-width) {
|
21
|
+
|
22
|
+
// By default, limit the width of the container to the page width
|
23
|
+
max-width: $width;
|
8
24
|
|
9
25
|
// On mobile, add half width gutters
|
10
|
-
margin:
|
26
|
+
margin-right: $govuk-gutter-half;
|
27
|
+
margin-left: $govuk-gutter-half;
|
11
28
|
|
12
29
|
// Respect 'display cutout' safe area (avoids notches and rounded corners)
|
13
30
|
@supports (margin: unquote("max(calc(0px))")) {
|
@@ -22,7 +39,8 @@
|
|
22
39
|
|
23
40
|
// On tablet, add full width gutters
|
24
41
|
@include govuk-media-query($from: tablet) {
|
25
|
-
margin:
|
42
|
+
margin-right: $govuk-gutter;
|
43
|
+
margin-left: $govuk-gutter;
|
26
44
|
|
27
45
|
// Respect 'display cutout' safe area (avoids notches and rounded corners)
|
28
46
|
@supports (margin: unquote("max(calc(0px))")) {
|
@@ -38,21 +56,24 @@
|
|
38
56
|
|
39
57
|
// As soon as the viewport is greater than the width of the page plus the
|
40
58
|
// gutters, just centre the content instead of adding gutters.
|
41
|
-
@include govuk-media-query($and: "(min-width: #{($
|
42
|
-
margin:
|
59
|
+
@include govuk-media-query($and: "(min-width: #{($width + $govuk-gutter * 2)})") {
|
60
|
+
margin-right: auto;
|
61
|
+
margin-left: auto;
|
43
62
|
|
44
63
|
// Since a safe area may have previously been set above,
|
45
64
|
// we need to duplicate this margin that centers the page.
|
46
65
|
@supports (margin: unquote("max(calc(0px))")) {
|
47
|
-
margin:
|
66
|
+
margin-right: auto;
|
67
|
+
margin-left: auto;
|
48
68
|
}
|
49
69
|
}
|
50
70
|
|
51
71
|
@include govuk-if-ie8 {
|
52
|
-
width: $
|
72
|
+
width: $width;
|
53
73
|
// Since media queries are not supported in IE8,
|
54
74
|
// we need to duplicate this margin that centers the page.
|
55
|
-
margin:
|
75
|
+
margin-right: auto;
|
76
|
+
margin-left: auto;
|
56
77
|
}
|
57
78
|
}
|
58
79
|
|
@@ -1,6 +1,8 @@
|
|
1
|
-
@
|
2
|
-
@
|
3
|
-
|
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";
|
4
6
|
|
5
7
|
@include govuk-exports("govuk/overrides/display") {
|
6
8
|
|
@@ -19,4 +21,10 @@
|
|
19
21
|
.govuk-\!-display-none {
|
20
22
|
display: none !important;
|
21
23
|
}
|
24
|
+
|
25
|
+
@include govuk-media-query($media-type: print) {
|
26
|
+
.govuk-\!-display-none-print {
|
27
|
+
display: none !important;
|
28
|
+
}
|
29
|
+
}
|
22
30
|
}
|
@@ -1,6 +1,8 @@
|
|
1
|
-
@
|
2
|
-
@
|
3
|
-
|
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";
|
4
6
|
|
5
7
|
////
|
6
8
|
/// @group overrides
|
@@ -1,6 +1,8 @@
|
|
1
|
-
@
|
2
|
-
@
|
3
|
-
|
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";
|
4
6
|
|
5
7
|
@include govuk-exports("govuk/overrides/typography") {
|
6
8
|
// Font size and line height
|
@@ -1,6 +1,8 @@
|
|
1
|
-
@
|
2
|
-
@
|
3
|
-
|
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";
|
4
6
|
|
5
7
|
@include govuk-exports("govuk/overrides/width") {
|
6
8
|
.govuk-\!-width-full {
|
@@ -52,7 +52,7 @@ $govuk-print-text-colour: #000000 !default;
|
|
52
52
|
|
53
53
|
/// Secondary text colour
|
54
54
|
///
|
55
|
-
/// Used for 'muted' text
|
55
|
+
/// Used in for example 'muted' text and help text.
|
56
56
|
///
|
57
57
|
/// @type Colour
|
58
58
|
/// @access public
|
@@ -90,7 +90,7 @@ $govuk-error-colour: govuk-colour("red") !default;
|
|
90
90
|
|
91
91
|
/// Border colour
|
92
92
|
///
|
93
|
-
/// Used for borders, separators, rules
|
93
|
+
/// Used in for example borders, separators, rules and keylines.
|
94
94
|
///
|
95
95
|
/// @type Colour
|
96
96
|
/// @access public
|
@@ -81,8 +81,11 @@ $govuk-border-width-form-element: 2px !default;
|
|
81
81
|
///
|
82
82
|
/// @type Number
|
83
83
|
/// @access public
|
84
|
+
/// @deprecated Use $govuk-border-width-form-element instead. There should be no
|
85
|
+
/// difference in thickness for inputs in the error state, in order to
|
86
|
+
/// maintain a distinct focus state.
|
84
87
|
|
85
|
-
$govuk-border-width-form-element-error:
|
88
|
+
$govuk-border-width-form-element-error: 2px !default;
|
86
89
|
|
87
90
|
/// Form group border width when in error state
|
88
91
|
///
|
@@ -8,8 +8,10 @@
|
|
8
8
|
/// @param {Boolean} $condition - Whether to return the value of `$if-true`
|
9
9
|
/// @param {Mixed} $if-true - Value to return if `$condition` is truthy
|
10
10
|
/// @return {Mixed} Value of `$if-true` if `$condition` is truthy, else null
|
11
|
-
/// @access
|
11
|
+
/// @access private
|
12
|
+
/// @deprecated We will be removing this function in a future release, use `if($condition, $if-true, null);` instead.
|
12
13
|
|
13
14
|
@function iff($condition, $if-true) {
|
15
|
+
@warn "The `iff` function will be removed in a future release, use `if($condition, $if-true, null);` instead.";
|
14
16
|
@return if($condition, $if-true, null);
|
15
17
|
}
|
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.
|
4
|
+
version: 3.8.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:
|
12
|
+
date: 2020-12-23 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: bundler
|
@@ -31,14 +31,14 @@ dependencies:
|
|
31
31
|
requirements:
|
32
32
|
- - "~>"
|
33
33
|
- !ruby/object:Gem::Version
|
34
|
-
version: '
|
34
|
+
version: '13.0'
|
35
35
|
type: :development
|
36
36
|
prerelease: false
|
37
37
|
version_requirements: !ruby/object:Gem::Requirement
|
38
38
|
requirements:
|
39
39
|
- - "~>"
|
40
40
|
- !ruby/object:Gem::Version
|
41
|
-
version: '
|
41
|
+
version: '13.0'
|
42
42
|
description: Adds the GOVUK frontend to a Rails application that uses the Asset Pipeline.
|
43
43
|
email:
|
44
44
|
executables: []
|
@@ -49,6 +49,7 @@ files:
|
|
49
49
|
- ".github/workflows/test.yml"
|
50
50
|
- ".gitignore"
|
51
51
|
- CODE_OF_CONDUCT.md
|
52
|
+
- CONTRIBUTING.md
|
52
53
|
- Gemfile
|
53
54
|
- Gemfile.lock
|
54
55
|
- LICENSE.txt
|
@@ -76,37 +77,67 @@ files:
|
|
76
77
|
- vendor/assets/images/govuk-mask-icon.svg
|
77
78
|
- vendor/assets/images/govuk-opengraph-image.png
|
78
79
|
- vendor/assets/javascripts/govuk_frontend_rails.js
|
80
|
+
- vendor/assets/stylesheets/_base.scss
|
79
81
|
- vendor/assets/stylesheets/all-ie8.scss
|
80
82
|
- vendor/assets/stylesheets/all.scss
|
81
83
|
- vendor/assets/stylesheets/components/_all.scss
|
82
84
|
- vendor/assets/stylesheets/components/accordion/_accordion.scss
|
85
|
+
- vendor/assets/stylesheets/components/accordion/_index.scss
|
83
86
|
- vendor/assets/stylesheets/components/back-link/_back-link.scss
|
87
|
+
- vendor/assets/stylesheets/components/back-link/_index.scss
|
84
88
|
- vendor/assets/stylesheets/components/breadcrumbs/_breadcrumbs.scss
|
89
|
+
- vendor/assets/stylesheets/components/breadcrumbs/_index.scss
|
85
90
|
- vendor/assets/stylesheets/components/button/_button.scss
|
91
|
+
- vendor/assets/stylesheets/components/button/_index.scss
|
86
92
|
- vendor/assets/stylesheets/components/character-count/_character-count.scss
|
93
|
+
- vendor/assets/stylesheets/components/character-count/_index.scss
|
87
94
|
- vendor/assets/stylesheets/components/checkboxes/_checkboxes.scss
|
95
|
+
- vendor/assets/stylesheets/components/checkboxes/_index.scss
|
88
96
|
- vendor/assets/stylesheets/components/date-input/_date-input.scss
|
97
|
+
- vendor/assets/stylesheets/components/date-input/_index.scss
|
89
98
|
- vendor/assets/stylesheets/components/details/_details.scss
|
99
|
+
- vendor/assets/stylesheets/components/details/_index.scss
|
90
100
|
- vendor/assets/stylesheets/components/error-message/_error-message.scss
|
101
|
+
- vendor/assets/stylesheets/components/error-message/_index.scss
|
91
102
|
- vendor/assets/stylesheets/components/error-summary/_error-summary.scss
|
103
|
+
- vendor/assets/stylesheets/components/error-summary/_index.scss
|
92
104
|
- vendor/assets/stylesheets/components/fieldset/_fieldset.scss
|
105
|
+
- vendor/assets/stylesheets/components/fieldset/_index.scss
|
93
106
|
- vendor/assets/stylesheets/components/file-upload/_file-upload.scss
|
107
|
+
- vendor/assets/stylesheets/components/file-upload/_index.scss
|
94
108
|
- vendor/assets/stylesheets/components/footer/_footer.scss
|
109
|
+
- vendor/assets/stylesheets/components/footer/_index.scss
|
95
110
|
- vendor/assets/stylesheets/components/header/_header.scss
|
111
|
+
- vendor/assets/stylesheets/components/header/_index.scss
|
96
112
|
- vendor/assets/stylesheets/components/hint/_hint.scss
|
113
|
+
- vendor/assets/stylesheets/components/hint/_index.scss
|
114
|
+
- vendor/assets/stylesheets/components/input/_index.scss
|
97
115
|
- vendor/assets/stylesheets/components/input/_input.scss
|
116
|
+
- vendor/assets/stylesheets/components/inset-text/_index.scss
|
98
117
|
- vendor/assets/stylesheets/components/inset-text/_inset-text.scss
|
118
|
+
- vendor/assets/stylesheets/components/label/_index.scss
|
99
119
|
- vendor/assets/stylesheets/components/label/_label.scss
|
120
|
+
- vendor/assets/stylesheets/components/panel/_index.scss
|
100
121
|
- vendor/assets/stylesheets/components/panel/_panel.scss
|
122
|
+
- vendor/assets/stylesheets/components/phase-banner/_index.scss
|
101
123
|
- vendor/assets/stylesheets/components/phase-banner/_phase-banner.scss
|
124
|
+
- vendor/assets/stylesheets/components/radios/_index.scss
|
102
125
|
- vendor/assets/stylesheets/components/radios/_radios.scss
|
126
|
+
- vendor/assets/stylesheets/components/select/_index.scss
|
103
127
|
- vendor/assets/stylesheets/components/select/_select.scss
|
128
|
+
- vendor/assets/stylesheets/components/skip-link/_index.scss
|
104
129
|
- vendor/assets/stylesheets/components/skip-link/_skip-link.scss
|
130
|
+
- vendor/assets/stylesheets/components/summary-list/_index.scss
|
105
131
|
- vendor/assets/stylesheets/components/summary-list/_summary-list.scss
|
132
|
+
- vendor/assets/stylesheets/components/table/_index.scss
|
106
133
|
- vendor/assets/stylesheets/components/table/_table.scss
|
134
|
+
- vendor/assets/stylesheets/components/tabs/_index.scss
|
107
135
|
- vendor/assets/stylesheets/components/tabs/_tabs.scss
|
136
|
+
- vendor/assets/stylesheets/components/tag/_index.scss
|
108
137
|
- vendor/assets/stylesheets/components/tag/_tag.scss
|
138
|
+
- vendor/assets/stylesheets/components/textarea/_index.scss
|
109
139
|
- vendor/assets/stylesheets/components/textarea/_textarea.scss
|
140
|
+
- vendor/assets/stylesheets/components/warning-text/_index.scss
|
110
141
|
- vendor/assets/stylesheets/components/warning-text/_warning-text.scss
|
111
142
|
- vendor/assets/stylesheets/core/_all.scss
|
112
143
|
- vendor/assets/stylesheets/core/_global-styles.scss
|
@@ -185,7 +216,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
185
216
|
- !ruby/object:Gem::Version
|
186
217
|
version: '0'
|
187
218
|
requirements: []
|
188
|
-
rubygems_version: 3.
|
219
|
+
rubygems_version: 3.1.4
|
189
220
|
signing_key:
|
190
221
|
specification_version: 4
|
191
222
|
summary: Adds the GOVUK frontend to a Rails application that uses the Asset Pipeline.
|