dxw_govuk_frontend_rails 3.4.0 → 3.9.1
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 +213 -124
- 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 +206 -0
- data/vendor/assets/stylesheets/components/back-link/_back-link.scss +2 -65
- data/vendor/assets/stylesheets/components/back-link/_index.scss +110 -0
- data/vendor/assets/stylesheets/components/breadcrumbs/_breadcrumbs.scss +2 -118
- data/vendor/assets/stylesheets/components/breadcrumbs/_index.scss +137 -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 +24 -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 +83 -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 +53 -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 +234 -0
- data/vendor/assets/stylesheets/components/header/_header.scss +2 -318
- data/vendor/assets/stylesheets/components/header/_index.scss +309 -0
- data/vendor/assets/stylesheets/components/hint/_hint.scss +2 -50
- data/vendor/assets/stylesheets/components/hint/_index.scss +44 -0
- data/vendor/assets/stylesheets/components/input/_index.scss +187 -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 +44 -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 +49 -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 +145 -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 +135 -0
- data/vendor/assets/stylesheets/components/tabs/_tabs.scss +2 -142
- data/vendor/assets/stylesheets/components/tag/_index.scss +86 -0
- data/vendor/assets/stylesheets/components/tag/_tag.scss +2 -44
- data/vendor/assets/stylesheets/components/textarea/_index.scss +47 -0
- data/vendor/assets/stylesheets/components/textarea/_textarea.scss +2 -55
- data/vendor/assets/stylesheets/components/warning-text/_index.scss +57 -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/_device-pixels.scss +3 -3
- data/vendor/assets/stylesheets/helpers/_focused.scss +1 -1
- data/vendor/assets/stylesheets/helpers/_font-faces.scss +9 -11
- data/vendor/assets/stylesheets/helpers/_grid.scss +2 -1
- data/vendor/assets/stylesheets/helpers/_links.scss +2 -4
- data/vendor/assets/stylesheets/helpers/_media-queries.scss +2 -6
- data/vendor/assets/stylesheets/helpers/_shape-arrow.scss +1 -1
- data/vendor/assets/stylesheets/helpers/_spacing.scss +7 -6
- data/vendor/assets/stylesheets/helpers/_typography.scss +13 -12
- data/vendor/assets/stylesheets/helpers/_visually-hidden.scss +30 -30
- data/vendor/assets/stylesheets/objects/_form-group.scss +1 -4
- data/vendor/assets/stylesheets/objects/_grid.scss +3 -6
- data/vendor/assets/stylesheets/objects/_main-wrapper.scss +5 -4
- data/vendor/assets/stylesheets/objects/_width-container.scss +12 -9
- data/vendor/assets/stylesheets/overrides/_display.scss +12 -4
- 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 +6 -3
- data/vendor/assets/stylesheets/settings/_colours-applied.scss +2 -5
- data/vendor/assets/stylesheets/settings/_colours-organisations.scss +3 -0
- data/vendor/assets/stylesheets/settings/_colours-palette.scss +42 -35
- data/vendor/assets/stylesheets/settings/_compatibility.scss +0 -1
- data/vendor/assets/stylesheets/settings/_ie8.scss +1 -1
- data/vendor/assets/stylesheets/settings/_measurements.scss +4 -5
- data/vendor/assets/stylesheets/settings/_typography-font-families.scss +2 -2
- data/vendor/assets/stylesheets/settings/_typography-font.scss +11 -5
- data/vendor/assets/stylesheets/settings/_typography-responsive.scss +6 -2
- data/vendor/assets/stylesheets/tools/_compatibility.scss +1 -1
- data/vendor/assets/stylesheets/tools/_font-url.scss +1 -4
- 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 -4
- data/vendor/assets/stylesheets/tools/_px-to-em.scss +1 -1
- data/vendor/assets/stylesheets/tools/_px-to-rem.scss +1 -1
- data/vendor/assets/stylesheets/utilities/_visually-hidden.scss +0 -1
- data/vendor/assets/stylesheets/vendor/_sass-mq.scss +0 -4
- metadata +36 -5
@@ -1,50 +1,2 @@
|
|
1
|
-
@import "../../
|
2
|
-
@import "
|
3
|
-
@import "../../helpers/all";
|
4
|
-
|
5
|
-
@include govuk-exports("govuk/component/hint") {
|
6
|
-
.govuk-hint {
|
7
|
-
@include govuk-font($size: 19);
|
8
|
-
|
9
|
-
display: block;
|
10
|
-
|
11
|
-
margin-bottom: govuk-spacing(3);
|
12
|
-
|
13
|
-
color: $govuk-secondary-text-colour;
|
14
|
-
}
|
15
|
-
|
16
|
-
// Reduces margin-bottom of hint when used after the default label (no class)
|
17
|
-
// or govuk-label--s for better vertical alignment.
|
18
|
-
|
19
|
-
// This adjustment will not work when the label is inside the <h1>, however it
|
20
|
-
// is unlikely that the default or govuk-label--s class would be used in this
|
21
|
-
// case.
|
22
|
-
|
23
|
-
// This adjustment will not work in browsers that do not support :not().
|
24
|
-
// Users with these browsers will see the default size margin (5px larger).
|
25
|
-
|
26
|
-
.govuk-label:not(.govuk-label--m):not(.govuk-label--l):not(.govuk-label--xl) + .govuk-hint {
|
27
|
-
margin-bottom: govuk-spacing(2);
|
28
|
-
}
|
29
|
-
|
30
|
-
// Reduces margin-bottom of hint when used after the default legend (no class)
|
31
|
-
// or govuk-fieldset__legend--s for better vertical alignment.
|
32
|
-
|
33
|
-
// This adjustment will not work when the legend is outside the <h1>, however
|
34
|
-
// it is unlikely that the default or govuk-fieldset__legend--s class would be
|
35
|
-
// used in this case.
|
36
|
-
|
37
|
-
// This adjustment will not work in browsers that do not support :not().
|
38
|
-
// Users with these browsers will see the default size margin (5px larger).
|
39
|
-
|
40
|
-
.govuk-fieldset__legend:not(.govuk-fieldset__legend--m):not(.govuk-fieldset__legend--l):not(.govuk-fieldset__legend--xl) + .govuk-hint {
|
41
|
-
margin-bottom: govuk-spacing(2);
|
42
|
-
}
|
43
|
-
|
44
|
-
// Reduces visual spacing of legend when there is a hint
|
45
|
-
|
46
|
-
.govuk-fieldset__legend + .govuk-hint,
|
47
|
-
.govuk-fieldset__legend + .govuk-hint {
|
48
|
-
margin-top: -(govuk-spacing(1));
|
49
|
-
}
|
50
|
-
}
|
1
|
+
@import "../../base";
|
2
|
+
@import "./index";
|
@@ -0,0 +1,44 @@
|
|
1
|
+
@include govuk-exports("govuk/component/hint") {
|
2
|
+
.govuk-hint {
|
3
|
+
@include govuk-font($size: 19);
|
4
|
+
|
5
|
+
display: block;
|
6
|
+
|
7
|
+
margin-bottom: govuk-spacing(3);
|
8
|
+
|
9
|
+
color: $govuk-secondary-text-colour;
|
10
|
+
}
|
11
|
+
|
12
|
+
// Reduces margin-bottom of hint when used after the default label (no class)
|
13
|
+
// or govuk-label--s for better vertical alignment.
|
14
|
+
|
15
|
+
// This adjustment will not work when the label is inside the <h1>, however it
|
16
|
+
// is unlikely that the default or govuk-label--s class would be used in this
|
17
|
+
// case.
|
18
|
+
|
19
|
+
// This adjustment will not work in browsers that do not support :not().
|
20
|
+
// Users with these browsers will see the default size margin (5px larger).
|
21
|
+
|
22
|
+
.govuk-label:not(.govuk-label--m):not(.govuk-label--l):not(.govuk-label--xl) + .govuk-hint {
|
23
|
+
margin-bottom: govuk-spacing(2);
|
24
|
+
}
|
25
|
+
|
26
|
+
// Reduces margin-bottom of hint when used after the default legend (no class)
|
27
|
+
// or govuk-fieldset__legend--s for better vertical alignment.
|
28
|
+
|
29
|
+
// This adjustment will not work when the legend is outside the <h1>, however
|
30
|
+
// it is unlikely that the default or govuk-fieldset__legend--s class would be
|
31
|
+
// used in this case.
|
32
|
+
|
33
|
+
// This adjustment will not work in browsers that do not support :not().
|
34
|
+
// Users with these browsers will see the default size margin (5px larger).
|
35
|
+
|
36
|
+
.govuk-fieldset__legend:not(.govuk-fieldset__legend--m):not(.govuk-fieldset__legend--l):not(.govuk-fieldset__legend--xl) + .govuk-hint {
|
37
|
+
margin-bottom: govuk-spacing(2);
|
38
|
+
}
|
39
|
+
|
40
|
+
// Reduces visual spacing of legend when there is a hint
|
41
|
+
.govuk-fieldset__legend + .govuk-hint {
|
42
|
+
margin-top: -(govuk-spacing(1));
|
43
|
+
}
|
44
|
+
}
|
@@ -0,0 +1,187 @@
|
|
1
|
+
@import "../error-message/index";
|
2
|
+
@import "../hint/index";
|
3
|
+
@import "../label/index";
|
4
|
+
|
5
|
+
@include govuk-exports("govuk/component/input") {
|
6
|
+
.govuk-input {
|
7
|
+
@include govuk-font($size: 19);
|
8
|
+
|
9
|
+
box-sizing: border-box;
|
10
|
+
width: 100%;
|
11
|
+
height: 40px;
|
12
|
+
@if $govuk-typography-use-rem {
|
13
|
+
height: govuk-px-to-rem(40px);
|
14
|
+
}
|
15
|
+
margin-top: 0;
|
16
|
+
|
17
|
+
padding: govuk-spacing(1);
|
18
|
+
// setting any background-color makes text invisible when changing colours to dark backgrounds in Firefox (https://bugzilla.mozilla.org/show_bug.cgi?id=1335476)
|
19
|
+
// as background-color and color need to always be set together, color should not be set either
|
20
|
+
border: $govuk-border-width-form-element solid $govuk-input-border-colour;
|
21
|
+
border-radius: 0;
|
22
|
+
|
23
|
+
// Disable inner shadow and remove rounded corners
|
24
|
+
-webkit-appearance: none;
|
25
|
+
-moz-appearance: none;
|
26
|
+
appearance: none;
|
27
|
+
|
28
|
+
&:focus {
|
29
|
+
outline: $govuk-focus-width solid $govuk-focus-colour;
|
30
|
+
// Ensure outline appears outside of the element
|
31
|
+
outline-offset: 0;
|
32
|
+
// Double the border by adding its width again. Use `box-shadow` for this // instead of changing `border-width` - this is for consistency with
|
33
|
+
// components such as textarea where we avoid changing `border-width` as
|
34
|
+
// it will change the element size. Also, `outline` cannot be utilised
|
35
|
+
// here as it is already used for the yellow focus state.
|
36
|
+
box-shadow: inset 0 0 0 $govuk-border-width-form-element;
|
37
|
+
|
38
|
+
@include govuk-if-ie8 {
|
39
|
+
// IE8 doesn't support `box-shadow` so double the border with
|
40
|
+
// `border-width`.
|
41
|
+
border-width: $govuk-border-width-form-element * 2;
|
42
|
+
}
|
43
|
+
}
|
44
|
+
}
|
45
|
+
|
46
|
+
.govuk-input::-webkit-outer-spin-button,
|
47
|
+
.govuk-input::-webkit-inner-spin-button {
|
48
|
+
margin: 0;
|
49
|
+
-webkit-appearance: none;
|
50
|
+
}
|
51
|
+
|
52
|
+
.govuk-input[type="number"] {
|
53
|
+
-moz-appearance: textfield;
|
54
|
+
}
|
55
|
+
|
56
|
+
.govuk-input--error {
|
57
|
+
border: $govuk-border-width-form-element-error solid $govuk-error-colour;
|
58
|
+
|
59
|
+
&:focus {
|
60
|
+
border-color: $govuk-input-border-colour;
|
61
|
+
}
|
62
|
+
}
|
63
|
+
|
64
|
+
// The ex measurements are based on the number of W's that can fit inside the input
|
65
|
+
// Extra space is left on the right hand side to allow for the Safari prefill icon
|
66
|
+
// Linear regression estimation based on visual tests: y = 1.76 + 1.81x
|
67
|
+
|
68
|
+
.govuk-input--width-30 {
|
69
|
+
max-width: 56ex + 3ex;
|
70
|
+
}
|
71
|
+
|
72
|
+
.govuk-input--width-20 {
|
73
|
+
max-width: 38ex + 3ex;
|
74
|
+
}
|
75
|
+
|
76
|
+
.govuk-input--width-10 {
|
77
|
+
max-width: 20ex + 3ex;
|
78
|
+
}
|
79
|
+
|
80
|
+
.govuk-input--width-5 {
|
81
|
+
max-width: 10.8ex;
|
82
|
+
}
|
83
|
+
|
84
|
+
.govuk-input--width-4 {
|
85
|
+
max-width: 9ex;
|
86
|
+
}
|
87
|
+
|
88
|
+
.govuk-input--width-3 {
|
89
|
+
max-width: 7.2ex;
|
90
|
+
}
|
91
|
+
|
92
|
+
.govuk-input--width-2 {
|
93
|
+
max-width: 5.4ex;
|
94
|
+
}
|
95
|
+
|
96
|
+
.govuk-input__wrapper {
|
97
|
+
display: -webkit-box;
|
98
|
+
display: -ms-flexbox;
|
99
|
+
display: flex;
|
100
|
+
|
101
|
+
.govuk-input {
|
102
|
+
-webkit-box-flex: 0;
|
103
|
+
-ms-flex: 0 1 auto;
|
104
|
+
flex: 0 1 auto;
|
105
|
+
}
|
106
|
+
|
107
|
+
.govuk-input:focus {
|
108
|
+
// Hack to stop focus style being overlapped by the suffix
|
109
|
+
z-index: 1;
|
110
|
+
}
|
111
|
+
|
112
|
+
// Split prefix/suffix onto separate lines on narrow screens
|
113
|
+
@include govuk-media-query($until: mobile) {
|
114
|
+
display: block;
|
115
|
+
|
116
|
+
.govuk-input {
|
117
|
+
// Set max-width to override potential width override class on the input
|
118
|
+
max-width: 100%;
|
119
|
+
}
|
120
|
+
}
|
121
|
+
}
|
122
|
+
|
123
|
+
.govuk-input__prefix,
|
124
|
+
.govuk-input__suffix {
|
125
|
+
@include govuk-font($size: 19);
|
126
|
+
|
127
|
+
box-sizing: border-box;
|
128
|
+
display: inline-block;
|
129
|
+
min-width: 40px;
|
130
|
+
@if $govuk-typography-use-rem {
|
131
|
+
min-width: govuk-px-to-rem(40px);
|
132
|
+
}
|
133
|
+
height: 40px;
|
134
|
+
@if $govuk-typography-use-rem {
|
135
|
+
height: govuk-px-to-rem(40px);
|
136
|
+
}
|
137
|
+
|
138
|
+
padding: govuk-spacing(1);
|
139
|
+
border: $govuk-border-width-form-element solid $govuk-input-border-colour;
|
140
|
+
background-color: govuk-colour("light-grey", $legacy: "grey-3");
|
141
|
+
|
142
|
+
text-align: center;
|
143
|
+
@include govuk-media-query($until: tablet) {
|
144
|
+
line-height: 1.6;
|
145
|
+
}
|
146
|
+
white-space: nowrap;
|
147
|
+
|
148
|
+
// Emphasise non-editable status of prefixes and suffixes
|
149
|
+
cursor: default;
|
150
|
+
|
151
|
+
-webkit-box-flex: 0;
|
152
|
+
|
153
|
+
-ms-flex: 0 0 auto;
|
154
|
+
|
155
|
+
flex: 0 0 auto;
|
156
|
+
|
157
|
+
// Split prefix/suffix onto separate lines on narrow screens
|
158
|
+
@include govuk-media-query($until: mobile) {
|
159
|
+
display: block;
|
160
|
+
height: 100%;
|
161
|
+
white-space: normal;
|
162
|
+
}
|
163
|
+
}
|
164
|
+
|
165
|
+
.govuk-input__prefix {
|
166
|
+
@include govuk-media-query($until: mobile) {
|
167
|
+
border-bottom: 0;
|
168
|
+
}
|
169
|
+
@include govuk-media-query($from: mobile) {
|
170
|
+
@include govuk-not-ie8 {
|
171
|
+
border-right: 0;
|
172
|
+
}
|
173
|
+
}
|
174
|
+
}
|
175
|
+
|
176
|
+
// Split prefix/suffix onto separate lines on narrow screens
|
177
|
+
.govuk-input__suffix {
|
178
|
+
@include govuk-media-query($until: mobile) {
|
179
|
+
border-top: 0;
|
180
|
+
}
|
181
|
+
@include govuk-media-query($from: mobile) {
|
182
|
+
@include govuk-not-ie8 {
|
183
|
+
border-left: 0;
|
184
|
+
}
|
185
|
+
}
|
186
|
+
}
|
187
|
+
}
|
@@ -1,103 +1,2 @@
|
|
1
|
-
@import "../../
|
2
|
-
@import "
|
3
|
-
@import "../../helpers/all";
|
4
|
-
|
5
|
-
@import "../error-message/error-message";
|
6
|
-
@import "../hint/hint";
|
7
|
-
@import "../label/label";
|
8
|
-
|
9
|
-
@include govuk-exports("govuk/component/input") {
|
10
|
-
.govuk-input {
|
11
|
-
@include govuk-font($size: 19);
|
12
|
-
|
13
|
-
box-sizing: border-box;
|
14
|
-
width: 100%;
|
15
|
-
height: 40px;
|
16
|
-
@if $govuk-typography-use-rem {
|
17
|
-
height: govuk-px-to-rem(40px);
|
18
|
-
}
|
19
|
-
margin-top: 0;
|
20
|
-
|
21
|
-
padding: govuk-spacing(1);
|
22
|
-
// setting any background-color makes text invisible when changing colours to dark backgrounds in Firefox (https://bugzilla.mozilla.org/show_bug.cgi?id=1335476)
|
23
|
-
// as background-color and color need to always be set together, color should not be set either
|
24
|
-
border: $govuk-border-width-form-element solid $govuk-input-border-colour;
|
25
|
-
border-radius: 0;
|
26
|
-
|
27
|
-
// Disable inner shadow and remove rounded corners
|
28
|
-
-webkit-appearance: none;
|
29
|
-
-moz-appearance: none;
|
30
|
-
appearance: none;
|
31
|
-
|
32
|
-
&:focus {
|
33
|
-
outline: $govuk-focus-width solid $govuk-focus-colour;
|
34
|
-
// Ensure outline appears outside of the element
|
35
|
-
outline-offset: 0;
|
36
|
-
// Double the border by adding its width again. Use `box-shadow` for this // instead of changing `border-width` - this is for consistency with
|
37
|
-
// components such as textarea where we avoid changing `border-width` as
|
38
|
-
// it will change the element size. Also, `outline` cannot be utilised
|
39
|
-
// here as it is already used for the yellow focus state.
|
40
|
-
box-shadow: inset 0 0 0 $govuk-border-width-form-element;
|
41
|
-
|
42
|
-
@include govuk-if-ie8 {
|
43
|
-
// IE8 doesn't support `box-shadow` so double the border with
|
44
|
-
// `border-width`.
|
45
|
-
border-width: $govuk-border-width-form-element * 2;
|
46
|
-
}
|
47
|
-
}
|
48
|
-
}
|
49
|
-
|
50
|
-
.govuk-input::-webkit-outer-spin-button,
|
51
|
-
.govuk-input::-webkit-inner-spin-button {
|
52
|
-
margin: 0;
|
53
|
-
-webkit-appearance: none;
|
54
|
-
}
|
55
|
-
|
56
|
-
.govuk-input[type="number"] {
|
57
|
-
-moz-appearance: textfield;
|
58
|
-
}
|
59
|
-
|
60
|
-
.govuk-input--error {
|
61
|
-
border: $govuk-border-width-form-element-error solid $govuk-error-colour;
|
62
|
-
|
63
|
-
&:focus {
|
64
|
-
border-color: $govuk-input-border-colour;
|
65
|
-
// Remove `box-shadow` inherited from `:focus` as `input--error`
|
66
|
-
// already has the thicker border.
|
67
|
-
box-shadow: none;
|
68
|
-
}
|
69
|
-
}
|
70
|
-
|
71
|
-
// The ex measurements are based on the number of W's that can fit inside the input
|
72
|
-
// Extra space is left on the right hand side to allow for the Safari prefill icon
|
73
|
-
// Linear regression estimation based on visual tests: y = 1.76 + 1.81x
|
74
|
-
|
75
|
-
.govuk-input--width-30 {
|
76
|
-
max-width: 56ex + 3ex;
|
77
|
-
}
|
78
|
-
|
79
|
-
.govuk-input--width-20 {
|
80
|
-
max-width: 38ex + 3ex;
|
81
|
-
}
|
82
|
-
|
83
|
-
.govuk-input--width-10 {
|
84
|
-
max-width: 20ex + 3ex;
|
85
|
-
}
|
86
|
-
|
87
|
-
.govuk-input--width-5 {
|
88
|
-
max-width: 10.8ex;
|
89
|
-
}
|
90
|
-
|
91
|
-
.govuk-input--width-4 {
|
92
|
-
max-width: 9ex;
|
93
|
-
}
|
94
|
-
|
95
|
-
.govuk-input--width-3 {
|
96
|
-
max-width: 7.2ex;
|
97
|
-
}
|
98
|
-
|
99
|
-
.govuk-input--width-2 {
|
100
|
-
max-width: 5.4ex;
|
101
|
-
}
|
102
|
-
|
103
|
-
}
|
1
|
+
@import "../../base";
|
2
|
+
@import "./index";
|
@@ -0,0 +1,24 @@
|
|
1
|
+
@include govuk-exports("govuk/component/inset-text") {
|
2
|
+
.govuk-inset-text {
|
3
|
+
@include govuk-font($size: 19);
|
4
|
+
@include govuk-text-colour;
|
5
|
+
padding: govuk-spacing(3);
|
6
|
+
// Margin top intended to collapse
|
7
|
+
// This adds an additional 10px to the paragraph above
|
8
|
+
@include govuk-responsive-margin(6, "top");
|
9
|
+
@include govuk-responsive-margin(6, "bottom");
|
10
|
+
|
11
|
+
clear: both;
|
12
|
+
|
13
|
+
border-left: $govuk-border-width-wide solid $govuk-border-colour;
|
14
|
+
|
15
|
+
> :first-child {
|
16
|
+
margin-top: 0;
|
17
|
+
}
|
18
|
+
|
19
|
+
> :only-child,
|
20
|
+
> :last-child {
|
21
|
+
margin-bottom: 0;
|
22
|
+
}
|
23
|
+
}
|
24
|
+
}
|
@@ -1,28 +1,2 @@
|
|
1
|
-
@import "../../
|
2
|
-
@import "
|
3
|
-
@import "../../helpers/all";
|
4
|
-
|
5
|
-
@include govuk-exports("govuk/component/inset-text") {
|
6
|
-
.govuk-inset-text {
|
7
|
-
@include govuk-font($size: 19);
|
8
|
-
@include govuk-text-colour;
|
9
|
-
padding: govuk-spacing(3);
|
10
|
-
// Margin top intended to collapse
|
11
|
-
// This adds an additional 10px to the paragraph above
|
12
|
-
@include govuk-responsive-margin(6, "top");
|
13
|
-
@include govuk-responsive-margin(6, "bottom");
|
14
|
-
|
15
|
-
clear: both;
|
16
|
-
|
17
|
-
border-left: $govuk-border-width-wide solid $govuk-border-colour;
|
18
|
-
|
19
|
-
> :first-child {
|
20
|
-
margin-top: 0;
|
21
|
-
}
|
22
|
-
|
23
|
-
> :only-child,
|
24
|
-
> :last-child {
|
25
|
-
margin-bottom: 0;
|
26
|
-
}
|
27
|
-
}
|
28
|
-
}
|
1
|
+
@import "../../base";
|
2
|
+
@import "./index";
|