govuk_publishing_components 9.5.1 → 9.5.2
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/components/step-by-step-nav.js +11 -6
- data/app/assets/javascripts/govuk_publishing_components/vendor/modernizr.js +3 -0
- data/app/assets/stylesheets/govuk_publishing_components/admin_styles_ie8.scss +2 -0
- data/app/assets/stylesheets/govuk_publishing_components/components/_step-by-step-nav.scss +2 -0
- data/app/views/govuk_publishing_components/components/_layout_for_admin.html.erb +7 -1
- data/app/views/govuk_publishing_components/components/_step_by_step_nav.html.erb +3 -5
- data/app/views/layouts/govuk_publishing_components/application.html.erb +6 -0
- data/config/initializers/assets.rb +2 -0
- data/lib/govuk_publishing_components/version.rb +1 -1
- data/node_modules/govuk-frontend/README.md +1 -1
- data/node_modules/govuk-frontend/all.js +3 -1
- data/node_modules/govuk-frontend/components/back-link/README.md +23 -7
- data/node_modules/govuk-frontend/components/breadcrumbs/README.md +26 -26
- data/node_modules/govuk-frontend/components/button/README.md +22 -22
- data/node_modules/govuk-frontend/components/checkboxes/README.md +115 -27
- data/node_modules/govuk-frontend/components/checkboxes/_checkboxes.scss +7 -1
- data/node_modules/govuk-frontend/components/date-input/README.md +141 -61
- data/node_modules/govuk-frontend/components/date-input/_date-input.scss +0 -5
- data/node_modules/govuk-frontend/components/date-input/template.njk +40 -17
- data/node_modules/govuk-frontend/components/details/README.md +10 -10
- data/node_modules/govuk-frontend/components/error-message/README.md +4 -4
- data/node_modules/govuk-frontend/components/error-summary/README.md +5 -5
- data/node_modules/govuk-frontend/components/fieldset/README.md +7 -7
- data/node_modules/govuk-frontend/components/file-upload/README.md +16 -16
- data/node_modules/govuk-frontend/components/footer/README.md +5 -5
- data/node_modules/govuk-frontend/components/footer/template.njk +1 -1
- data/node_modules/govuk-frontend/components/header/README.md +26 -18
- data/node_modules/govuk-frontend/components/header/_header.scss +3 -2
- data/node_modules/govuk-frontend/components/header/template.njk +5 -3
- data/node_modules/govuk-frontend/components/hint/README.md +14 -10
- data/node_modules/govuk-frontend/components/input/README.md +166 -30
- data/node_modules/govuk-frontend/components/input/_input.scss +20 -3
- data/node_modules/govuk-frontend/components/inset-text/README.md +6 -6
- data/node_modules/govuk-frontend/components/label/README.md +9 -9
- data/node_modules/govuk-frontend/components/panel/README.md +43 -4
- data/node_modules/govuk-frontend/components/panel/template.njk +4 -2
- data/node_modules/govuk-frontend/components/phase-banner/README.md +4 -4
- data/node_modules/govuk-frontend/components/phase-banner/_phase-banner.scss +3 -3
- data/node_modules/govuk-frontend/components/radios/README.md +100 -29
- data/node_modules/govuk-frontend/components/radios/_radios.scss +12 -3
- data/node_modules/govuk-frontend/components/select/README.md +12 -12
- data/node_modules/govuk-frontend/components/skip-link/README.md +4 -4
- data/node_modules/govuk-frontend/components/table/README.md +12 -12
- data/node_modules/govuk-frontend/components/table/_table.scss +2 -2
- data/node_modules/govuk-frontend/components/tabs/README.md +4 -4
- data/node_modules/govuk-frontend/components/tabs/_tabs.scss +1 -0
- data/node_modules/govuk-frontend/components/tag/README.md +7 -7
- data/node_modules/govuk-frontend/components/tag/_tag.scss +6 -0
- data/node_modules/govuk-frontend/components/textarea/README.md +16 -16
- data/node_modules/govuk-frontend/components/warning-text/README.md +4 -4
- data/node_modules/govuk-frontend/components/warning-text/_warning-text.scss +14 -4
- data/node_modules/govuk-frontend/core/_template.scss +7 -3
- data/node_modules/govuk-frontend/helpers/_typography.scss +44 -10
- data/node_modules/govuk-frontend/objects/_main-wrapper.scss +4 -0
- data/node_modules/govuk-frontend/package.json +18 -12
- data/node_modules/govuk-frontend/settings/_typography-responsive.scss +35 -0
- data/node_modules/govuk-frontend/tools/_all.scss +1 -0
- data/node_modules/govuk-frontend/tools/_px-to-rem.scss +20 -0
- data/node_modules/govuk-frontend/utilities/_visually-hidden.scss +6 -0
- metadata +5 -28
- data/node_modules/govuk-frontend/components/back-link/back-link.njk +0 -3
- data/node_modules/govuk-frontend/components/breadcrumbs/breadcrumbs.njk +0 -14
- data/node_modules/govuk-frontend/components/button/button.njk +0 -3
- data/node_modules/govuk-frontend/components/checkboxes/checkboxes.njk +0 -27
- data/node_modules/govuk-frontend/components/date-input/date-input.njk +0 -23
- data/node_modules/govuk-frontend/components/details/details.njk +0 -7
- data/node_modules/govuk-frontend/components/error-message/error-message.njk +0 -7
- data/node_modules/govuk-frontend/components/error-summary/error-summary.njk +0 -17
- data/node_modules/govuk-frontend/components/fieldset/fieldset.njk +0 -13
- data/node_modules/govuk-frontend/components/file-upload/file-upload.njk +0 -9
- data/node_modules/govuk-frontend/components/footer/footer.njk +0 -3
- data/node_modules/govuk-frontend/components/header/header.njk +0 -3
- data/node_modules/govuk-frontend/components/hint/hint.njk +0 -7
- data/node_modules/govuk-frontend/components/input/input.njk +0 -9
- data/node_modules/govuk-frontend/components/inset-text/inset-text.njk +0 -7
- data/node_modules/govuk-frontend/components/label/label.njk +0 -6
- data/node_modules/govuk-frontend/components/panel/panel.njk +0 -7
- data/node_modules/govuk-frontend/components/phase-banner/phase-banner.njk +0 -7
- data/node_modules/govuk-frontend/components/radios/radios.njk +0 -27
- data/node_modules/govuk-frontend/components/select/select.njk +0 -24
- data/node_modules/govuk-frontend/components/skip-link/skip-link.njk +0 -3
- data/node_modules/govuk-frontend/components/table/table.njk +0 -45
- data/node_modules/govuk-frontend/components/tabs/tabs.njk +0 -3
- data/node_modules/govuk-frontend/components/tag/tag.njk +0 -7
- data/node_modules/govuk-frontend/components/textarea/textarea.njk +0 -11
- data/node_modules/govuk-frontend/components/warning-text/warning-text.njk +0 -9
@@ -13,7 +13,6 @@
|
|
13
13
|
}
|
14
14
|
|
15
15
|
.govuk-date-input__item {
|
16
|
-
width: 50px;
|
17
16
|
margin-right: govuk-spacing(4);
|
18
17
|
margin-bottom: 0;
|
19
18
|
float: left;
|
@@ -28,8 +27,4 @@
|
|
28
27
|
.govuk-date-input__input {
|
29
28
|
margin-bottom: 0;
|
30
29
|
}
|
31
|
-
|
32
|
-
.govuk-date-input__item--year {
|
33
|
-
width: 70px;
|
34
|
-
}
|
35
30
|
}
|
@@ -7,11 +7,30 @@
|
|
7
7
|
aria-describedby – for example hints or error messages -#}
|
8
8
|
{% set describedBy = "" %}
|
9
9
|
|
10
|
+
{% if params.items %}
|
11
|
+
{% set dateInputItems = params.items %}
|
12
|
+
{% else %}
|
13
|
+
{% set dateInputItems = [
|
14
|
+
{
|
15
|
+
name: "day",
|
16
|
+
classes: "govuk-input--width-2"
|
17
|
+
},
|
18
|
+
{
|
19
|
+
name: "month",
|
20
|
+
classes: "govuk-input--width-2"
|
21
|
+
},
|
22
|
+
{
|
23
|
+
name: "year",
|
24
|
+
classes: "govuk-input--width-4"
|
25
|
+
}
|
26
|
+
] %}
|
27
|
+
{% endif %}
|
28
|
+
|
10
29
|
{#- Capture the HTML so we can optionally nest it in a fieldset -#}
|
11
30
|
{% set innerHtml %}
|
12
31
|
{% if params.hint %}
|
13
|
-
{% set hintId = params.id +
|
14
|
-
{% set describedBy = describedBy +
|
32
|
+
{% set hintId = params.id + "-hint" %}
|
33
|
+
{% set describedBy = describedBy + " " + hintId if describedBy else hintId %}
|
15
34
|
{{ govukHint({
|
16
35
|
id: hintId,
|
17
36
|
classes: params.hint.classes,
|
@@ -21,8 +40,8 @@
|
|
21
40
|
}) | indent(2) | trim }}
|
22
41
|
{% endif %}
|
23
42
|
{% if params.errorMessage %}
|
24
|
-
{% set errorId = params.id +
|
25
|
-
{% set describedBy = describedBy +
|
43
|
+
{% set errorId = params.id + "-error" %}
|
44
|
+
{% set describedBy = describedBy + " " + errorId if describedBy else errorId %}
|
26
45
|
{{ govukErrorMessage({
|
27
46
|
id: errorId,
|
28
47
|
classes: params.errorMessage.classes,
|
@@ -33,20 +52,24 @@
|
|
33
52
|
<div class="govuk-date-input {%- if params.classes %} {{ params.classes }}{% endif %}"
|
34
53
|
{%- for attribute, value in params.attributes %} {{attribute}}="{{value}}"{% endfor %}
|
35
54
|
{%- if params.id %} id="{{ params.id }}"{% endif %}>
|
36
|
-
{% for item in
|
37
|
-
|
55
|
+
{% for item in dateInputItems %}
|
56
|
+
|
57
|
+
{# @todo Remove this definition and any mentions of it on the next breaking release #}
|
58
|
+
{% set inputWidthClass = 'govuk-input--width-4 ' if item.name == 'year' else 'govuk-input--width-2 ' %}
|
59
|
+
|
60
|
+
<div class="govuk-date-input__item">
|
38
61
|
{{ govukInput({
|
39
|
-
|
40
|
-
|
41
|
-
|
62
|
+
label: {
|
63
|
+
text: item.label if item.label else item.name | capitalize,
|
64
|
+
classes: "govuk-date-input__label"
|
42
65
|
},
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
66
|
+
id: item.id if item.id else (params.id + "-" + item.name),
|
67
|
+
classes: "govuk-date-input__input " + inputWidthClass + item.classes,
|
68
|
+
name: (params.name + "-" + item.name) if params.name else item.name,
|
69
|
+
value: item.value,
|
70
|
+
type: "number",
|
71
|
+
attributes: {
|
72
|
+
pattern: "[0-9]*"
|
50
73
|
}
|
51
74
|
}) | indent(6) | trim }}
|
52
75
|
</div>
|
@@ -64,7 +87,7 @@
|
|
64
87
|
describedBy: describedBy,
|
65
88
|
classes: params.fieldset.classes,
|
66
89
|
attributes: {
|
67
|
-
role:
|
90
|
+
role: "group"
|
68
91
|
},
|
69
92
|
legend: params.fieldset.legend
|
70
93
|
}) %}
|
@@ -6,13 +6,13 @@ Component for conditionally revealing content, using the details HTML element.
|
|
6
6
|
|
7
7
|
## Guidance
|
8
8
|
|
9
|
-
Find out when to use the
|
9
|
+
Find out when to use the details component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/details).
|
10
10
|
|
11
11
|
## Quick start examples
|
12
12
|
|
13
|
-
###
|
13
|
+
### Details
|
14
14
|
|
15
|
-
[Preview the
|
15
|
+
[Preview this example in the Frontend review app](http://govuk-frontend-review.herokuapp.com/components/details/preview)
|
16
16
|
|
17
17
|
#### Markup
|
18
18
|
|
@@ -29,16 +29,16 @@ Find out when to use the Details component in your service in the [GOV.UK Design
|
|
29
29
|
|
30
30
|
#### Macro
|
31
31
|
|
32
|
-
{% from
|
32
|
+
{% from "details/macro.njk" import govukDetails %}
|
33
33
|
|
34
34
|
{{ govukDetails({
|
35
35
|
"summaryText": "Help with nationality",
|
36
36
|
"text": "We need to know your nationality so we can work out which elections you’re entitled to vote in. If you can’t provide your nationality, you’ll have to send copies of identity documents through the post."
|
37
37
|
}) }}
|
38
38
|
|
39
|
-
### Details
|
39
|
+
### Details expanded
|
40
40
|
|
41
|
-
[Preview the
|
41
|
+
[Preview this example in the Frontend review app](http://govuk-frontend-review.herokuapp.com/components/details/expanded/preview)
|
42
42
|
|
43
43
|
#### Markup
|
44
44
|
|
@@ -55,7 +55,7 @@ Find out when to use the Details component in your service in the [GOV.UK Design
|
|
55
55
|
|
56
56
|
#### Macro
|
57
57
|
|
58
|
-
{% from
|
58
|
+
{% from "details/macro.njk" import govukDetails %}
|
59
59
|
|
60
60
|
{{ govukDetails({
|
61
61
|
"id": "help-with-nationality",
|
@@ -64,9 +64,9 @@ Find out when to use the Details component in your service in the [GOV.UK Design
|
|
64
64
|
"open": true
|
65
65
|
}) }}
|
66
66
|
|
67
|
-
### Details
|
67
|
+
### Details with html
|
68
68
|
|
69
|
-
[Preview the
|
69
|
+
[Preview this example in the Frontend review app](http://govuk-frontend-review.herokuapp.com/components/details/with-html/preview)
|
70
70
|
|
71
71
|
#### Markup
|
72
72
|
|
@@ -91,7 +91,7 @@ Find out when to use the Details component in your service in the [GOV.UK Design
|
|
91
91
|
|
92
92
|
#### Macro
|
93
93
|
|
94
|
-
{% from
|
94
|
+
{% from "details/macro.njk" import govukDetails %}
|
95
95
|
|
96
96
|
{{ govukDetails({
|
97
97
|
"summaryText": "Where to find your National Insurance Number",
|
@@ -6,13 +6,13 @@ Component to show a red error message - used for form validation. Use inside a l
|
|
6
6
|
|
7
7
|
## Guidance
|
8
8
|
|
9
|
-
Find out when to use the
|
9
|
+
Find out when to use the error message component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/error-message).
|
10
10
|
|
11
11
|
## Quick start examples
|
12
12
|
|
13
|
-
###
|
13
|
+
### Error message
|
14
14
|
|
15
|
-
[Preview the
|
15
|
+
[Preview this example in the Frontend review app](http://govuk-frontend-review.herokuapp.com/components/error-message/preview)
|
16
16
|
|
17
17
|
#### Markup
|
18
18
|
|
@@ -22,7 +22,7 @@ Find out when to use the Error message component in your service in the [GOV.UK
|
|
22
22
|
|
23
23
|
#### Macro
|
24
24
|
|
25
|
-
{% from
|
25
|
+
{% from "error-message/macro.njk" import govukErrorMessage %}
|
26
26
|
|
27
27
|
{{ govukErrorMessage({
|
28
28
|
"text": "Error message about full name goes here"
|
@@ -6,13 +6,13 @@ Component to show an error summary box - used at the top of the page, to summari
|
|
6
6
|
|
7
7
|
## Guidance
|
8
8
|
|
9
|
-
Find out when to use the
|
9
|
+
Find out when to use the error summary component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/error-summary).
|
10
10
|
|
11
11
|
## Quick start examples
|
12
12
|
|
13
|
-
###
|
13
|
+
### Error summary
|
14
14
|
|
15
|
-
[Preview the
|
15
|
+
[Preview this example in the Frontend review app](http://govuk-frontend-review.herokuapp.com/components/error-summary/preview)
|
16
16
|
|
17
17
|
#### Markup
|
18
18
|
|
@@ -46,7 +46,7 @@ Find out when to use the Error summary component in your service in the [GOV.UK
|
|
46
46
|
|
47
47
|
#### Macro
|
48
48
|
|
49
|
-
{% from
|
49
|
+
{% from "error-summary/macro.njk" import govukErrorSummary %}
|
50
50
|
|
51
51
|
{{ govukErrorSummary({
|
52
52
|
"titleText": "Message to alert the user to a problem goes here",
|
@@ -58,7 +58,7 @@ Find out when to use the Error summary component in your service in the [GOV.UK
|
|
58
58
|
"href": "#example-error-1"
|
59
59
|
},
|
60
60
|
{
|
61
|
-
"
|
61
|
+
"text": "Descriptive link to the question with an error",
|
62
62
|
"href": "#example-error-1"
|
63
63
|
}
|
64
64
|
]
|
@@ -6,13 +6,13 @@ The fieldset element is used to group several controls within a web form. The le
|
|
6
6
|
|
7
7
|
## Guidance
|
8
8
|
|
9
|
-
Find out when to use the
|
9
|
+
Find out when to use the fieldset component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/fieldset).
|
10
10
|
|
11
11
|
## Quick start examples
|
12
12
|
|
13
|
-
###
|
13
|
+
### Fieldset
|
14
14
|
|
15
|
-
[Preview the
|
15
|
+
[Preview this example in the Frontend review app](http://govuk-frontend-review.herokuapp.com/components/fieldset/preview)
|
16
16
|
|
17
17
|
#### Markup
|
18
18
|
|
@@ -26,7 +26,7 @@ Find out when to use the Fieldset component in your service in the [GOV.UK Desig
|
|
26
26
|
|
27
27
|
#### Macro
|
28
28
|
|
29
|
-
{% from
|
29
|
+
{% from "fieldset/macro.njk" import govukFieldset %}
|
30
30
|
|
31
31
|
{{ govukFieldset({
|
32
32
|
"legend": {
|
@@ -34,9 +34,9 @@ Find out when to use the Fieldset component in your service in the [GOV.UK Desig
|
|
34
34
|
}
|
35
35
|
}) }}
|
36
36
|
|
37
|
-
### Fieldset
|
37
|
+
### Fieldset as page heading
|
38
38
|
|
39
|
-
[Preview the
|
39
|
+
[Preview this example in the Frontend review app](http://govuk-frontend-review.herokuapp.com/components/fieldset/as-page-heading/preview)
|
40
40
|
|
41
41
|
#### Markup
|
42
42
|
|
@@ -52,7 +52,7 @@ Find out when to use the Fieldset component in your service in the [GOV.UK Desig
|
|
52
52
|
|
53
53
|
#### Macro
|
54
54
|
|
55
|
-
{% from
|
55
|
+
{% from "fieldset/macro.njk" import govukFieldset %}
|
56
56
|
|
57
57
|
{{ govukFieldset({
|
58
58
|
"legend": {
|
@@ -6,13 +6,13 @@ The HTML `<input>` element with type="file" lets a user pick one or more files,
|
|
6
6
|
|
7
7
|
## Guidance
|
8
8
|
|
9
|
-
Find out when to use the
|
9
|
+
Find out when to use the file upload component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/file-upload).
|
10
10
|
|
11
11
|
## Quick start examples
|
12
12
|
|
13
|
-
###
|
13
|
+
### File upload
|
14
14
|
|
15
|
-
[Preview the
|
15
|
+
[Preview this example in the Frontend review app](http://govuk-frontend-review.herokuapp.com/components/file-upload/preview)
|
16
16
|
|
17
17
|
#### Markup
|
18
18
|
|
@@ -26,7 +26,7 @@ Find out when to use the File upload component in your service in the [GOV.UK De
|
|
26
26
|
|
27
27
|
#### Macro
|
28
28
|
|
29
|
-
{% from
|
29
|
+
{% from "file-upload/macro.njk" import govukFileUpload %}
|
30
30
|
|
31
31
|
{{ govukFileUpload({
|
32
32
|
"id": "file-upload-1",
|
@@ -36,9 +36,9 @@ Find out when to use the File upload component in your service in the [GOV.UK De
|
|
36
36
|
}
|
37
37
|
}) }}
|
38
38
|
|
39
|
-
### File
|
39
|
+
### File upload with hint text
|
40
40
|
|
41
|
-
[Preview the
|
41
|
+
[Preview this example in the Frontend review app](http://govuk-frontend-review.herokuapp.com/components/file-upload/with-hint-text/preview)
|
42
42
|
|
43
43
|
#### Markup
|
44
44
|
|
@@ -56,7 +56,7 @@ Find out when to use the File upload component in your service in the [GOV.UK De
|
|
56
56
|
|
57
57
|
#### Macro
|
58
58
|
|
59
|
-
{% from
|
59
|
+
{% from "file-upload/macro.njk" import govukFileUpload %}
|
60
60
|
|
61
61
|
{{ govukFileUpload({
|
62
62
|
"id": "file-upload-2",
|
@@ -69,9 +69,9 @@ Find out when to use the File upload component in your service in the [GOV.UK De
|
|
69
69
|
}
|
70
70
|
}) }}
|
71
71
|
|
72
|
-
### File
|
72
|
+
### File upload with error message
|
73
73
|
|
74
|
-
[Preview the
|
74
|
+
[Preview this example in the Frontend review app](http://govuk-frontend-review.herokuapp.com/components/file-upload/with-error-message/preview)
|
75
75
|
|
76
76
|
#### Markup
|
77
77
|
|
@@ -93,7 +93,7 @@ Find out when to use the File upload component in your service in the [GOV.UK De
|
|
93
93
|
|
94
94
|
#### Macro
|
95
95
|
|
96
|
-
{% from
|
96
|
+
{% from "file-upload/macro.njk" import govukFileUpload %}
|
97
97
|
|
98
98
|
{{ govukFileUpload({
|
99
99
|
"id": "file-upload-3",
|
@@ -109,9 +109,9 @@ Find out when to use the File upload component in your service in the [GOV.UK De
|
|
109
109
|
}
|
110
110
|
}) }}
|
111
111
|
|
112
|
-
### File
|
112
|
+
### File upload with value and attributes
|
113
113
|
|
114
|
-
[Preview the
|
114
|
+
[Preview this example in the Frontend review app](http://govuk-frontend-review.herokuapp.com/components/file-upload/with-value-and-attributes/preview)
|
115
115
|
|
116
116
|
#### Markup
|
117
117
|
|
@@ -125,7 +125,7 @@ Find out when to use the File upload component in your service in the [GOV.UK De
|
|
125
125
|
|
126
126
|
#### Macro
|
127
127
|
|
128
|
-
{% from
|
128
|
+
{% from "file-upload/macro.njk" import govukFileUpload %}
|
129
129
|
|
130
130
|
{{ govukFileUpload({
|
131
131
|
"id": "file-upload-4",
|
@@ -139,9 +139,9 @@ Find out when to use the File upload component in your service in the [GOV.UK De
|
|
139
139
|
}
|
140
140
|
}) }}
|
141
141
|
|
142
|
-
### File
|
142
|
+
### File upload with label as page heading
|
143
143
|
|
144
|
-
[Preview the
|
144
|
+
[Preview this example in the Frontend review app](http://govuk-frontend-review.herokuapp.com/components/file-upload/with-label-as-page-heading/preview)
|
145
145
|
|
146
146
|
#### Markup
|
147
147
|
|
@@ -158,7 +158,7 @@ Find out when to use the File upload component in your service in the [GOV.UK De
|
|
158
158
|
|
159
159
|
#### Macro
|
160
160
|
|
161
|
-
{% from
|
161
|
+
{% from "file-upload/macro.njk" import govukFileUpload %}
|
162
162
|
|
163
163
|
{{ govukFileUpload({
|
164
164
|
"id": "file-upload-1",
|
@@ -6,13 +6,13 @@ The footer component is used at the bottom of every GOV.UK page, to help users n
|
|
6
6
|
|
7
7
|
## Guidance
|
8
8
|
|
9
|
-
Find out when to use the
|
9
|
+
Find out when to use the footer component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/footer).
|
10
10
|
|
11
11
|
## Quick start examples
|
12
12
|
|
13
|
-
###
|
13
|
+
### Footer
|
14
14
|
|
15
|
-
[Preview the
|
15
|
+
[Preview this example in the Frontend review app](http://govuk-frontend-review.herokuapp.com/components/footer/preview)
|
16
16
|
|
17
17
|
#### Markup
|
18
18
|
|
@@ -48,7 +48,7 @@ Find out when to use the Footer component in your service in the [GOV.UK Design
|
|
48
48
|
<div class="govuk-footer__meta-item">
|
49
49
|
<a
|
50
50
|
class="govuk-footer__link govuk-footer__copyright-logo"
|
51
|
-
href="
|
51
|
+
href="https://www.nationalarchives.gov.uk/information-management/re-using-public-sector-information/uk-government-licensing-framework/crown-copyright/"
|
52
52
|
>© Crown copyright</a>
|
53
53
|
</div>
|
54
54
|
</div>
|
@@ -57,7 +57,7 @@ Find out when to use the Footer component in your service in the [GOV.UK Design
|
|
57
57
|
|
58
58
|
#### Macro
|
59
59
|
|
60
|
-
{% from
|
60
|
+
{% from "footer/macro.njk" import govukFooter %}
|
61
61
|
|
62
62
|
{{ govukFooter({}) }}
|
63
63
|
|
@@ -72,7 +72,7 @@
|
|
72
72
|
<div class="govuk-footer__meta-item">
|
73
73
|
<a
|
74
74
|
class="govuk-footer__link govuk-footer__copyright-logo"
|
75
|
-
href="
|
75
|
+
href="https://www.nationalarchives.gov.uk/information-management/re-using-public-sector-information/uk-government-licensing-framework/crown-copyright/"
|
76
76
|
>© Crown copyright</a>
|
77
77
|
</div>
|
78
78
|
</div>
|
@@ -6,13 +6,13 @@ The header component is used at the top of every GOV.UK page, to help users navi
|
|
6
6
|
|
7
7
|
## Guidance
|
8
8
|
|
9
|
-
Find out when to use the
|
9
|
+
Find out when to use the header component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/header).
|
10
10
|
|
11
11
|
## Quick start examples
|
12
12
|
|
13
|
-
###
|
13
|
+
### Header
|
14
14
|
|
15
|
-
[Preview the
|
15
|
+
[Preview this example in the Frontend review app](http://govuk-frontend-review.herokuapp.com/components/header/preview)
|
16
16
|
|
17
17
|
#### Markup
|
18
18
|
|
@@ -45,21 +45,20 @@ Find out when to use the Header component in your service in the [GOV.UK Design
|
|
45
45
|
</span>
|
46
46
|
|
47
47
|
</a>
|
48
|
-
</div><div class="govuk-header__content">
|
49
|
-
|
50
48
|
</div>
|
49
|
+
|
51
50
|
</div>
|
52
51
|
</header>
|
53
52
|
|
54
53
|
#### Macro
|
55
54
|
|
56
|
-
{% from
|
55
|
+
{% from "header/macro.njk" import govukHeader %}
|
57
56
|
|
58
57
|
{{ govukHeader({}) }}
|
59
58
|
|
60
|
-
### Header
|
59
|
+
### Header with service name
|
61
60
|
|
62
|
-
[Preview the
|
61
|
+
[Preview this example in the Frontend review app](http://govuk-frontend-review.herokuapp.com/components/header/with-service-name/preview)
|
63
62
|
|
64
63
|
#### Markup
|
65
64
|
|
@@ -92,28 +91,31 @@ Find out when to use the Header component in your service in the [GOV.UK Design
|
|
92
91
|
</span>
|
93
92
|
|
94
93
|
</a>
|
95
|
-
</div
|
94
|
+
</div>
|
95
|
+
|
96
|
+
<div class="govuk-header__content">
|
96
97
|
|
97
98
|
<a href="/components/header" class="govuk-header__link govuk-header__link--service-name">
|
98
99
|
Service Name
|
99
100
|
</a>
|
100
101
|
|
101
102
|
</div>
|
103
|
+
|
102
104
|
</div>
|
103
105
|
</header>
|
104
106
|
|
105
107
|
#### Macro
|
106
108
|
|
107
|
-
{% from
|
109
|
+
{% from "header/macro.njk" import govukHeader %}
|
108
110
|
|
109
111
|
{{ govukHeader({
|
110
112
|
"serviceName": "Service Name",
|
111
113
|
"serviceUrl": "/components/header"
|
112
114
|
}) }}
|
113
115
|
|
114
|
-
### Header
|
116
|
+
### Header with navigation
|
115
117
|
|
116
|
-
[Preview the
|
118
|
+
[Preview this example in the Frontend review app](http://govuk-frontend-review.herokuapp.com/components/header/with-navigation/preview)
|
117
119
|
|
118
120
|
#### Markup
|
119
121
|
|
@@ -146,7 +148,9 @@ Find out when to use the Header component in your service in the [GOV.UK Design
|
|
146
148
|
</span>
|
147
149
|
|
148
150
|
</a>
|
149
|
-
</div
|
151
|
+
</div>
|
152
|
+
|
153
|
+
<div class="govuk-header__content">
|
150
154
|
|
151
155
|
<button role="button" class="govuk-header__menu-button js-header-toggle" aria-controls="navigation" aria-label="Show or hide Top Level Navigation">Menu</button>
|
152
156
|
<nav>
|
@@ -180,12 +184,13 @@ Find out when to use the Header component in your service in the [GOV.UK Design
|
|
180
184
|
</nav>
|
181
185
|
|
182
186
|
</div>
|
187
|
+
|
183
188
|
</div>
|
184
189
|
</header>
|
185
190
|
|
186
191
|
#### Macro
|
187
192
|
|
188
|
-
{% from
|
193
|
+
{% from "header/macro.njk" import govukHeader %}
|
189
194
|
|
190
195
|
{{ govukHeader({
|
191
196
|
"navigation": [
|
@@ -209,9 +214,9 @@ Find out when to use the Header component in your service in the [GOV.UK Design
|
|
209
214
|
]
|
210
215
|
}) }}
|
211
216
|
|
212
|
-
### Header
|
217
|
+
### Header with service name and navigation
|
213
218
|
|
214
|
-
[Preview the
|
219
|
+
[Preview this example in the Frontend review app](http://govuk-frontend-review.herokuapp.com/components/header/with-service-name-and-navigation/preview)
|
215
220
|
|
216
221
|
#### Markup
|
217
222
|
|
@@ -244,7 +249,9 @@ Find out when to use the Header component in your service in the [GOV.UK Design
|
|
244
249
|
</span>
|
245
250
|
|
246
251
|
</a>
|
247
|
-
</div
|
252
|
+
</div>
|
253
|
+
|
254
|
+
<div class="govuk-header__content">
|
248
255
|
|
249
256
|
<a href="/components/header" class="govuk-header__link govuk-header__link--service-name">
|
250
257
|
Service Name
|
@@ -282,12 +289,13 @@ Find out when to use the Header component in your service in the [GOV.UK Design
|
|
282
289
|
</nav>
|
283
290
|
|
284
291
|
</div>
|
292
|
+
|
285
293
|
</div>
|
286
294
|
</header>
|
287
295
|
|
288
296
|
#### Macro
|
289
297
|
|
290
|
-
{% from
|
298
|
+
{% from "header/macro.njk" import govukHeader %}
|
291
299
|
|
292
300
|
{{ govukHeader({
|
293
301
|
"serviceName": "Service Name",
|