@ons/design-system 74.0.0-next.1 → 74.0.0-next.10
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.
- package/README.md +15 -3
- package/components/access-code/example-access-code-error.njk +1 -1
- package/components/access-code/example-access-code.njk +1 -1
- package/components/address-input/autosuggest.address.spec.js +23 -0
- package/components/autosuggest/autosuggest.ui.js +3 -0
- package/components/back-to-top/example-full-page-back-to-top.njk +1 -1
- package/components/breadcrumbs/_breadcrumbs.scss +4 -7
- package/components/breadcrumbs/_macro.njk +29 -25
- package/components/breadcrumbs/_macro.spec.js +39 -0
- package/components/breadcrumbs/example-breadcrumbs-wide.njk +52 -0
- package/components/chart/_chart.scss +0 -9
- package/components/chart/_macro.njk +96 -128
- package/components/chart/_macro.spec.js +43 -28
- package/components/chart/example-area-chart-with-axis-min-and-max-values.njk +6 -3
- package/components/chart/example-area-chart.njk +6 -3
- package/components/chart/example-bar-chart-with-annotations.njk +6 -3
- package/components/chart/example-bar-chart-with-axis-min-and-max-values.njk +6 -3
- package/components/chart/example-bar-chart-with-point-range-and-reference-line-annotations.njk +6 -3
- package/components/chart/example-bar-chart.njk +6 -3
- package/components/chart/example-bar-with-confidence-levels.njk +6 -3
- package/components/chart/example-clustered-bar-chart.njk +6 -3
- package/components/chart/example-clustered-column-chart.njk +6 -3
- package/components/chart/example-column-chart-with-annotations.njk +6 -3
- package/components/chart/example-column-chart-with-axis-min-and-max-values.njk +6 -3
- package/components/chart/example-column-chart-with-custom-reference-line-value.njk +6 -3
- package/components/chart/example-column-chart-with-range-annotations.njk +6 -3
- package/components/chart/example-column-chart-with-reference-line-annotations.njk +6 -3
- package/components/chart/example-column-chart.njk +6 -3
- package/components/chart/example-column-with-confidence-levels.njk +6 -3
- package/components/chart/example-column-with-line-chart.njk +6 -3
- package/components/chart/example-iframe-chart.njk +6 -3
- package/components/chart/example-line-chart-with-annotations.njk +6 -3
- package/components/chart/example-line-chart-with-axis-min-and-max-values.njk +6 -3
- package/components/chart/example-line-chart-with-custom-reference-line-value.njk +6 -3
- package/components/chart/example-line-chart-with-label-format.njk +6 -3
- package/components/chart/example-line-chart-with-markers.njk +6 -3
- package/components/chart/example-line-chart-with-range-annotations-inside.njk +6 -3
- package/components/chart/example-line-chart-with-range-annotations-outside-left-right.njk +6 -3
- package/components/chart/example-line-chart-with-range-annotations-outside-top-bottom.njk +6 -3
- package/components/chart/example-line-chart-with-reference-line-annotations.njk +6 -3
- package/components/chart/example-line-chart.njk +6 -3
- package/components/chart/example-scatter-chart-with-axis-min-and-max-values.njk +6 -3
- package/components/chart/example-scatter-chart.njk +6 -3
- package/components/chart/example-stacked-bar-chart.njk +6 -3
- package/components/chart/example-stacked-column-chart.njk +6 -3
- package/components/document-list/_macro.njk +2 -2
- package/components/document-list/_macro.spec.js +55 -0
- package/components/featured-article/_macro.njk +3 -37
- package/components/featured-article/example-featured-article-with-chart.njk +19 -14
- package/components/featured-article/example-featured-article-with-image.njk +12 -7
- package/components/featured-article/featured-article.scss +1 -1
- package/components/featured-article/macro.spec.js +44 -67
- package/components/figure/_figure.scss +31 -0
- package/components/figure/_macro.njk +98 -0
- package/components/figure/_macro.spec.js +520 -0
- package/components/figure/example-figure-heading-level-2.njk +34 -0
- package/components/figure/example-figure-with-div.njk +29 -0
- package/components/figure/example-figure-without-footer.njk +12 -0
- package/components/figure/example-figure-without-header.njk +24 -0
- package/components/figure/example-figure.njk +34 -0
- package/components/header/_header.scss +1 -3
- package/components/header/_macro.njk +8 -4
- package/components/header/_macro.spec.js +48 -0
- package/components/hero/_macro.njk +3 -2
- package/components/hero/_macro.spec.js +36 -0
- package/components/hero/example-hero-dark-wide.njk +17 -0
- package/components/hero/example-hero-dark-with-external-breadcrumbs.njk +17 -21
- package/components/hero/example-hero-default-full-width.njk +16 -0
- package/components/hero/example-hero-default-with-external-breadcrumbs.njk +165 -169
- package/components/hero/example-hero-grey-with-external-breadcrumbs.njk +207 -211
- package/components/hero/example-hero-navy-blue-with-external-breadcrumbs.njk +163 -167
- package/components/hero/example-hero-pale-blue-with-external-breadcrumbs.njk +165 -169
- package/components/image/_image.scss +0 -7
- package/components/image/_macro.njk +25 -14
- package/components/image/_macro.spec.js +122 -7
- package/components/image/example-image-with-figure-fields.njk +25 -0
- package/components/list/_macro.njk +1 -0
- package/components/list/_macro.spec.js +16 -0
- package/components/question/example-question-ccs.njk +1 -1
- package/components/question/example-question-fieldset.njk +1 -1
- package/components/question/example-question-interviewer-note.njk +1 -1
- package/components/question/example-question-no-fieldset.njk +1 -1
- package/components/relationships/example-relationships-error.njk +1 -1
- package/components/relationships/example-relationships-you.njk +1 -1
- package/components/relationships/example-relationships.njk +1 -1
- package/components/table/_macro.njk +138 -111
- package/components/table/_macro.spec.js +175 -16
- package/components/table/_table.scss +6 -1
- package/components/table/example-table-basic-no-caption.njk +46 -0
- package/components/table/example-table-basic-visually-hidden-caption.njk +47 -0
- package/components/table/example-table-with-figure-fields.njk +86 -0
- package/components/table/table.spec.js +2 -0
- package/components/table-of-contents/_macro.njk +6 -4
- package/components/table-of-contents/_macro.spec.js +43 -3
- package/components/table-of-contents/example-table-of-contents-ordered.njk +64 -0
- package/components/table-of-contents/example-table-of-contents-sticky-full-page-ordered.njk +156 -0
- package/components/table-of-contents/example-table-of-contents-sticky-full-page.njk +1 -1
- package/components/table-of-contents/table-of-contents.spec.js +4 -5
- package/css/main.css +1 -1
- package/layout/_template.njk +66 -46
- package/package.json +45 -36
- package/scripts/main.es5.js +3 -3
- package/scripts/main.js +2 -2
- package/scss/base/_global.scss +8 -0
- package/scss/main.scss +1 -0
- package/scss/objects/_page.scss +1 -1
- package/scss/objects/_spacing.scss +0 -4
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
{% from "components/table/_macro.njk" import onsTable %}
|
|
2
|
+
{{
|
|
3
|
+
onsTable({
|
|
4
|
+
"id": "table-with-figure-fields",
|
|
5
|
+
"headingLevel": 3,
|
|
6
|
+
"figureNumber": "Table 1",
|
|
7
|
+
"title": "Population by region, mid-2023",
|
|
8
|
+
"subtitle": "Estimates for England and Wales",
|
|
9
|
+
"caption": "Population estimates by region",
|
|
10
|
+
"sourceNote": "Source: Office for National Statistics – Population estimates for the UK, England and Wales, Scotland and Northern Ireland",
|
|
11
|
+
"ths": [
|
|
12
|
+
{
|
|
13
|
+
"value": "Region"
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
"value": "Population",
|
|
17
|
+
"numeric": true
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
|
+
"value": "Change (%)",
|
|
21
|
+
"numeric": true
|
|
22
|
+
}
|
|
23
|
+
],
|
|
24
|
+
"trs": [
|
|
25
|
+
{
|
|
26
|
+
"tds": [
|
|
27
|
+
{
|
|
28
|
+
"value": "North East"
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
"value": "2,647,000",
|
|
32
|
+
"numeric": true
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"value": "0.3",
|
|
36
|
+
"numeric": true
|
|
37
|
+
}
|
|
38
|
+
]
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
"tds": [
|
|
42
|
+
{
|
|
43
|
+
"value": "North West"
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
"value": "7,417,000",
|
|
47
|
+
"numeric": true
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
"value": "0.5",
|
|
51
|
+
"numeric": true
|
|
52
|
+
}
|
|
53
|
+
]
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
"tds": [
|
|
57
|
+
{
|
|
58
|
+
"value": "South East"
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
"value": "9,294,000",
|
|
62
|
+
"numeric": true
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
"value": "0.7",
|
|
66
|
+
"numeric": true
|
|
67
|
+
}
|
|
68
|
+
]
|
|
69
|
+
}
|
|
70
|
+
],
|
|
71
|
+
"footnotes": {
|
|
72
|
+
"title": "Footnotes",
|
|
73
|
+
"content": "Figures are rounded to the nearest thousand. Percentage change is compared with mid-2022 estimates."
|
|
74
|
+
},
|
|
75
|
+
"download": {
|
|
76
|
+
"title": "Download this table",
|
|
77
|
+
"itemsList": [
|
|
78
|
+
{
|
|
79
|
+
"text": "Population by region (CSV format, 1KB)",
|
|
80
|
+
"url": "/data/population-by-region.csv",
|
|
81
|
+
"download": "file"
|
|
82
|
+
}
|
|
83
|
+
]
|
|
84
|
+
}
|
|
85
|
+
})
|
|
86
|
+
}}
|
|
@@ -5,6 +5,7 @@ describe('script: table', () => {
|
|
|
5
5
|
// Construct a table with 15 columns and 15 rows with long labels.
|
|
6
6
|
const params = {
|
|
7
7
|
variants: ['scrollable'],
|
|
8
|
+
ariaLabel: 'Example table',
|
|
8
9
|
ths: Array.from({ length: 15 }, (_, i) => ({ value: `Column ${i + 1}` })),
|
|
9
10
|
trs: [
|
|
10
11
|
{
|
|
@@ -44,6 +45,7 @@ describe('script: table', () => {
|
|
|
44
45
|
describe('variant: sortable', () => {
|
|
45
46
|
const params = {
|
|
46
47
|
variants: ['sortable'],
|
|
48
|
+
ariaLabel: 'Example table',
|
|
47
49
|
sortBy: 'Sort by',
|
|
48
50
|
ariaAsc: 'ascending',
|
|
49
51
|
ariaDesc: 'descending',
|
|
@@ -15,6 +15,8 @@
|
|
|
15
15
|
|
|
16
16
|
<nav class="ons-table-of-contents" aria-label="{{ params.ariaLabel | default('Table of contents') }}">
|
|
17
17
|
<h2 class="ons-table-of-contents__title ons-u-fs-r--b ons-u-mb-s">{{ params.title }}</h2>
|
|
18
|
+
{% set element = 'ol' if params.ordered else 'ul' %}
|
|
19
|
+
{% set variant = null if params.ordered else 'dashed' %}
|
|
18
20
|
{% if params.lists %}
|
|
19
21
|
{% for list in params.lists %}
|
|
20
22
|
{% if list.listHeading %}
|
|
@@ -24,9 +26,9 @@
|
|
|
24
26
|
{% endif %}
|
|
25
27
|
{{
|
|
26
28
|
onsList({
|
|
27
|
-
"element":
|
|
29
|
+
"element": element,
|
|
28
30
|
"classes": 'ons-u-mb-l',
|
|
29
|
-
"variants":
|
|
31
|
+
"variants": variant,
|
|
30
32
|
"itemsList": list.itemsList
|
|
31
33
|
})
|
|
32
34
|
}}
|
|
@@ -34,9 +36,9 @@
|
|
|
34
36
|
{% elif params.itemsList %}
|
|
35
37
|
{{
|
|
36
38
|
onsList({
|
|
37
|
-
"element":
|
|
39
|
+
"element": element,
|
|
38
40
|
"classes": 'ons-u-mb-l',
|
|
39
|
-
"variants":
|
|
41
|
+
"variants": variant,
|
|
40
42
|
"itemsList": params.itemsList
|
|
41
43
|
})
|
|
42
44
|
}}
|
|
@@ -160,12 +160,29 @@ describe('macro: table-of-contents', () => {
|
|
|
160
160
|
faker.renderComponent('table-of-contents', EXAMPLE_TABLE_OF_CONTENTS_SINGLE);
|
|
161
161
|
|
|
162
162
|
expect(listsSpy.occurrences[0]).toEqual({
|
|
163
|
-
element: '
|
|
163
|
+
element: 'ul',
|
|
164
164
|
classes: 'ons-u-mb-l',
|
|
165
165
|
variants: 'dashed',
|
|
166
166
|
itemsList: EXAMPLE_TABLE_OF_CONTENTS_SINGLE.itemsList,
|
|
167
167
|
});
|
|
168
168
|
});
|
|
169
|
+
|
|
170
|
+
it('outputs `lists` component as an ordered list when `ordered` is `true`', () => {
|
|
171
|
+
const faker = templateFaker();
|
|
172
|
+
const listsSpy = faker.spy('list');
|
|
173
|
+
|
|
174
|
+
faker.renderComponent('table-of-contents', {
|
|
175
|
+
...EXAMPLE_TABLE_OF_CONTENTS_SINGLE,
|
|
176
|
+
ordered: true,
|
|
177
|
+
});
|
|
178
|
+
|
|
179
|
+
expect(listsSpy.occurrences[0]).toEqual({
|
|
180
|
+
element: 'ol',
|
|
181
|
+
classes: 'ons-u-mb-l',
|
|
182
|
+
variants: null,
|
|
183
|
+
itemsList: EXAMPLE_TABLE_OF_CONTENTS_SINGLE.itemsList,
|
|
184
|
+
});
|
|
185
|
+
});
|
|
169
186
|
});
|
|
170
187
|
|
|
171
188
|
describe('multiple lists', () => {
|
|
@@ -199,18 +216,41 @@ describe('macro: table-of-contents', () => {
|
|
|
199
216
|
faker.renderComponent('table-of-contents', EXAMPLE_TABLE_OF_CONTENTS_MULTIPLE);
|
|
200
217
|
|
|
201
218
|
expect(listsSpy.occurrences[0]).toEqual({
|
|
202
|
-
element: '
|
|
219
|
+
element: 'ul',
|
|
203
220
|
classes: 'ons-u-mb-l',
|
|
204
221
|
variants: 'dashed',
|
|
205
222
|
itemsList: EXAMPLE_TABLE_OF_CONTENTS_MULTIPLE.lists[0].itemsList,
|
|
206
223
|
});
|
|
207
224
|
expect(listsSpy.occurrences[1]).toEqual({
|
|
208
|
-
element: '
|
|
225
|
+
element: 'ul',
|
|
209
226
|
classes: 'ons-u-mb-l',
|
|
210
227
|
variants: 'dashed',
|
|
211
228
|
itemsList: EXAMPLE_TABLE_OF_CONTENTS_MULTIPLE.lists[1].itemsList,
|
|
212
229
|
});
|
|
213
230
|
});
|
|
231
|
+
|
|
232
|
+
it('outputs `lists` component for each list as ordered lists when `ordered` is `true`', () => {
|
|
233
|
+
const faker = templateFaker();
|
|
234
|
+
const listsSpy = faker.spy('list');
|
|
235
|
+
|
|
236
|
+
faker.renderComponent('table-of-contents', {
|
|
237
|
+
...EXAMPLE_TABLE_OF_CONTENTS_MULTIPLE,
|
|
238
|
+
ordered: true,
|
|
239
|
+
});
|
|
240
|
+
|
|
241
|
+
expect(listsSpy.occurrences[0]).toEqual({
|
|
242
|
+
element: 'ol',
|
|
243
|
+
classes: 'ons-u-mb-l',
|
|
244
|
+
variants: null,
|
|
245
|
+
itemsList: EXAMPLE_TABLE_OF_CONTENTS_MULTIPLE.lists[0].itemsList,
|
|
246
|
+
});
|
|
247
|
+
expect(listsSpy.occurrences[1]).toEqual({
|
|
248
|
+
element: 'ol',
|
|
249
|
+
classes: 'ons-u-mb-l',
|
|
250
|
+
variants: null,
|
|
251
|
+
itemsList: EXAMPLE_TABLE_OF_CONTENTS_MULTIPLE.lists[1].itemsList,
|
|
252
|
+
});
|
|
253
|
+
});
|
|
214
254
|
});
|
|
215
255
|
|
|
216
256
|
describe('related links and button', () => {
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
{% from "components/table-of-contents/_macro.njk" import onsTableOfContents %}
|
|
2
|
+
|
|
3
|
+
{{-
|
|
4
|
+
onsTableOfContents({
|
|
5
|
+
"title": 'Contents',
|
|
6
|
+
"ariaLabel": 'Pages in this guide',
|
|
7
|
+
"skipLink": {
|
|
8
|
+
"url": "#0",
|
|
9
|
+
"text": 'Skip to guide content'
|
|
10
|
+
},
|
|
11
|
+
"ordered": true,
|
|
12
|
+
"lists": [
|
|
13
|
+
{
|
|
14
|
+
"itemsList": [
|
|
15
|
+
{
|
|
16
|
+
"url": '#0',
|
|
17
|
+
"text": 'Overview',
|
|
18
|
+
"current": true
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
"url": '#0',
|
|
22
|
+
"text": 'Who should take part and why'
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
"url": '#0',
|
|
26
|
+
"text": 'How your information is used'
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"url": '#0',
|
|
30
|
+
"text": 'The 2019 Census Rehearsal'
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
"url": '#0',
|
|
34
|
+
"text": 'Further information'
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
"url": '#0',
|
|
38
|
+
"text": 'Online census'
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
"url": '#0',
|
|
42
|
+
"text": 'Who should take part and why'
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
"url": '#0',
|
|
46
|
+
"text": 'How your information is used'
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
"url": '#0',
|
|
50
|
+
"text": 'The 2019 Census Rehearsal'
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
"url": '#0',
|
|
54
|
+
"text": 'Further information'
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
"url": '#0',
|
|
58
|
+
"text": 'Online census'
|
|
59
|
+
}
|
|
60
|
+
]
|
|
61
|
+
}
|
|
62
|
+
]
|
|
63
|
+
})
|
|
64
|
+
-}}
|
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: 'Example: Table of contents on full page'
|
|
3
|
+
layout: ~
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
{% from "components/table-of-contents/_macro.njk" import onsTableOfContents %}
|
|
7
|
+
{% extends "layout/_template.njk" %}
|
|
8
|
+
{%
|
|
9
|
+
set pageConfig = {
|
|
10
|
+
"header": {
|
|
11
|
+
"title": "What is the census?"
|
|
12
|
+
},
|
|
13
|
+
"breadcrumbs": {
|
|
14
|
+
"ariaLabel": 'Back',
|
|
15
|
+
"itemsList": [
|
|
16
|
+
{
|
|
17
|
+
"url": '/',
|
|
18
|
+
"id": "back-example-feedback-form-error",
|
|
19
|
+
"text": 'Back',
|
|
20
|
+
"attributes": {
|
|
21
|
+
"data-attribute": "Example attribute"
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
]
|
|
25
|
+
},
|
|
26
|
+
"footer": {
|
|
27
|
+
"oglLink": {
|
|
28
|
+
"pre": 'All content is available under the',
|
|
29
|
+
"link": 'Open Government Licence v3.0',
|
|
30
|
+
"url": 'https://www.nationalarchives.gov.uk/doc/open-government-licence/version/3/',
|
|
31
|
+
"post": ', except where otherwise stated'
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
%}
|
|
36
|
+
|
|
37
|
+
{% block mainContent %}
|
|
38
|
+
<div class="ons-page__container ons-container">
|
|
39
|
+
<div class="ons-grid ons-js-table-of-contents-container">
|
|
40
|
+
<div class="ons-grid__col ons-grid__col--sticky@m ons-col-4@m">
|
|
41
|
+
{{
|
|
42
|
+
onsTableOfContents({
|
|
43
|
+
"title": 'Contents',
|
|
44
|
+
"ariaLabel": 'Sections in this page',
|
|
45
|
+
"ordered": true,
|
|
46
|
+
"itemsList": [
|
|
47
|
+
{
|
|
48
|
+
"url": '#section1',
|
|
49
|
+
"text": 'What is the census?'
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
"url": '#section2',
|
|
53
|
+
"text": 'The online census has now closed'
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
"url": '#section3',
|
|
57
|
+
"text": 'What happens after Census Day'
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
"url": '#section4',
|
|
61
|
+
"text": 'The census in Northern Ireland and Scotland'
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
"url": '#section5',
|
|
65
|
+
"text": 'The last census'
|
|
66
|
+
}
|
|
67
|
+
]
|
|
68
|
+
})
|
|
69
|
+
}}
|
|
70
|
+
</div>
|
|
71
|
+
<div class="ons-grid__col ons-col-7@m ons-push-1@m">
|
|
72
|
+
<section id="section1">
|
|
73
|
+
<h2>1. What is the census?</h2>
|
|
74
|
+
<p>
|
|
75
|
+
The census is a survey that happens every 10 years and gives us a picture of all the people and households in
|
|
76
|
+
England and Wales.
|
|
77
|
+
</p>
|
|
78
|
+
|
|
79
|
+
<p>
|
|
80
|
+
Your answers to the census questions will help organisations make decisions on planning and funding public services
|
|
81
|
+
in your area, including transport, education and healthcare.
|
|
82
|
+
</p>
|
|
83
|
+
</section>
|
|
84
|
+
<section id="section2">
|
|
85
|
+
<h2>2. The online census has now closed</h2>
|
|
86
|
+
<p>Census Day was on Sunday 21 March 2021.</p>
|
|
87
|
+
|
|
88
|
+
<p>
|
|
89
|
+
If you still have a paper census questionnaire, fill it in as soon as you can and return it to FREEPOST, Census
|
|
90
|
+
2021.
|
|
91
|
+
</p>
|
|
92
|
+
</section>
|
|
93
|
+
<section id="section3">
|
|
94
|
+
<h2>3. What happens after Census Day</h2>
|
|
95
|
+
<p>
|
|
96
|
+
Two follow-up surveys, the <a href="#0">Census Coverage Survey</a> and the <a href="#0">Census Quality Survey</a>,
|
|
97
|
+
help to improve the quality and accuracy of the census results.
|
|
98
|
+
</p>
|
|
99
|
+
|
|
100
|
+
<p>
|
|
101
|
+
Over the next year, we work hard to process the answers from all the census questionnaires. This is so that we can
|
|
102
|
+
publish the initial Census 2021 findings one year after the census and the main releases two years after the census.
|
|
103
|
+
</p>
|
|
104
|
+
|
|
105
|
+
<p>
|
|
106
|
+
To make sure the Census 2021 statistics we publish meet the needs of those who use them, we also run an outputs
|
|
107
|
+
consultation.
|
|
108
|
+
</p>
|
|
109
|
+
</section>
|
|
110
|
+
<section id="section4">
|
|
111
|
+
<h2>4. The census in Northern Ireland and Scotland</h2>
|
|
112
|
+
<p>The Office for National Statistics (ONS) runs the census in England and Wales.</p>
|
|
113
|
+
|
|
114
|
+
<p>
|
|
115
|
+
If you live in Northern Ireland, visit the Northern Ireland Statistics Agency (NISRA) census website to find out
|
|
116
|
+
about the census for Northern Ireland.
|
|
117
|
+
</p>
|
|
118
|
+
|
|
119
|
+
<p>
|
|
120
|
+
If you live in Scotland, visit the National Records of Scotland census website to find out how to take part in the
|
|
121
|
+
census for Scotland.
|
|
122
|
+
</p>
|
|
123
|
+
</section>
|
|
124
|
+
<section id="section5">
|
|
125
|
+
<h2>5. The last census</h2>
|
|
126
|
+
<p>
|
|
127
|
+
The last census took place in 2011. Many people and organisations used information from the 2011 Census in a variety
|
|
128
|
+
of ways.
|
|
129
|
+
</p>
|
|
130
|
+
|
|
131
|
+
<p>
|
|
132
|
+
For example, Bristol City Council used it to inform decisions on how to fund local housing improvements. It was also
|
|
133
|
+
essential for the charity Redbridge Council for Voluntary Services to help people from ethnic minority groups learn
|
|
134
|
+
more about dementia.
|
|
135
|
+
</p>
|
|
136
|
+
|
|
137
|
+
<p>
|
|
138
|
+
To read more about the benefits that information from the 2011 Census helped to create, visit the Office for
|
|
139
|
+
National Statistics (ONS) website.
|
|
140
|
+
</p>
|
|
141
|
+
<p>
|
|
142
|
+
The Census Coverage Survey (CCS) was a short, separate survey that we at the Office for National Statistics (ONS)
|
|
143
|
+
started six to eight weeks after Census Day.
|
|
144
|
+
</p>
|
|
145
|
+
|
|
146
|
+
<p>
|
|
147
|
+
The CCS helps make sure everyone is counted and our census results are as accurate as possible. It asked similar
|
|
148
|
+
questions to the main census, just fewer of them, at addresses in a selection of postcodes across England and Wales.
|
|
149
|
+
</p>
|
|
150
|
+
|
|
151
|
+
<p>The CCS has now closed.</p>
|
|
152
|
+
</section>
|
|
153
|
+
</div>
|
|
154
|
+
</div>
|
|
155
|
+
</div>
|
|
156
|
+
{% endblock %}
|
|
@@ -6,7 +6,7 @@ describe('script: table-of-contents', () => {
|
|
|
6
6
|
beforeEach(async () => {
|
|
7
7
|
await setTestPage(
|
|
8
8
|
'/test',
|
|
9
|
-
|
|
9
|
+
|
|
10
10
|
`
|
|
11
11
|
<div class="ons-page__container ons-container">
|
|
12
12
|
<div class="ons-grid ons-js-table-of-contents-container">
|
|
@@ -47,7 +47,6 @@ describe('script: table-of-contents', () => {
|
|
|
47
47
|
</div>
|
|
48
48
|
</div>
|
|
49
49
|
`,
|
|
50
|
-
/* eslint-enable indent */
|
|
51
50
|
);
|
|
52
51
|
});
|
|
53
52
|
|
|
@@ -68,7 +67,7 @@ describe('script: table-of-contents-fixed-position', () => {
|
|
|
68
67
|
beforeEach(async () => {
|
|
69
68
|
await setTestPage(
|
|
70
69
|
'/test',
|
|
71
|
-
|
|
70
|
+
|
|
72
71
|
`
|
|
73
72
|
<div class="ons-page__container ons-container">
|
|
74
73
|
<div class="ons-grid ons-js-table-of-contents-container">
|
|
@@ -146,8 +145,8 @@ describe('script: table-of-contents-fixed-position', () => {
|
|
|
146
145
|
</div>
|
|
147
146
|
</div>
|
|
148
147
|
`,
|
|
149
|
-
|
|
150
|
-
'
|
|
148
|
+
|
|
149
|
+
'mainContent',
|
|
151
150
|
);
|
|
152
151
|
});
|
|
153
152
|
|