govuk_publishing_components 12.20.0 → 12.21.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.
- checksums.yaml +4 -4
- data/app/assets/stylesheets/govuk_publishing_components/components/_image-card.scss +2 -2
- data/app/assets/stylesheets/govuk_publishing_components/components/_related-navigation.scss +8 -0
- data/app/views/govuk_publishing_components/components/_contextual_breadcrumbs.html.erb +8 -8
- data/app/views/govuk_publishing_components/components/_contextual_footer.html.erb +10 -0
- data/app/views/govuk_publishing_components/components/_contextual_sidebar.html.erb +5 -14
- data/app/views/govuk_publishing_components/components/_layout_footer.html.erb +5 -3
- data/app/views/govuk_publishing_components/components/_related_navigation.html.erb +10 -6
- data/app/views/govuk_publishing_components/components/docs/contextual_breadcrumbs.yml +3 -2
- data/app/views/govuk_publishing_components/components/docs/contextual_footer.yml +71 -0
- data/app/views/govuk_publishing_components/components/docs/contextual_sidebar.yml +18 -9
- data/app/views/govuk_publishing_components/components/docs/layout_footer.yml +17 -0
- data/app/views/govuk_publishing_components/components/docs/related_navigation.yml +53 -0
- data/app/views/govuk_publishing_components/components/related_navigation/_section.html.erb +10 -5
- data/config/locales/en.yml +5 -6
- data/lib/govuk_publishing_components.rb +0 -2
- data/lib/govuk_publishing_components/presenters/contextual_navigation.rb +0 -4
- data/lib/govuk_publishing_components/presenters/related_navigation_helper.rb +108 -90
- data/lib/govuk_publishing_components/version.rb +1 -1
- data/node_modules/govuk-frontend/components/back-link/README.md +4 -73
- data/node_modules/govuk-frontend/components/breadcrumbs/README.md +4 -238
- data/node_modules/govuk-frontend/components/button/README.md +4 -174
- data/node_modules/govuk-frontend/components/character-count/README.md +4 -340
- data/node_modules/govuk-frontend/components/character-count/template.njk +0 -3
- data/node_modules/govuk-frontend/components/checkboxes/README.md +4 -705
- data/node_modules/govuk-frontend/components/checkboxes/template.njk +1 -0
- data/node_modules/govuk-frontend/components/date-input/README.md +4 -563
- data/node_modules/govuk-frontend/components/date-input/template.njk +1 -0
- data/node_modules/govuk-frontend/components/details/README.md +4 -128
- data/node_modules/govuk-frontend/components/error-message/README.md +4 -58
- data/node_modules/govuk-frontend/components/error-summary/README.md +4 -94
- data/node_modules/govuk-frontend/components/fieldset/README.md +4 -92
- data/node_modules/govuk-frontend/components/file-upload/README.md +4 -199
- data/node_modules/govuk-frontend/components/file-upload/template.njk +1 -0
- data/node_modules/govuk-frontend/components/footer/README.md +4 -91
- data/node_modules/govuk-frontend/components/footer/_footer.scss +22 -13
- data/node_modules/govuk-frontend/components/header/README.md +4 -351
- data/node_modules/govuk-frontend/components/hint/README.md +5 -77
- data/node_modules/govuk-frontend/components/input/README.md +4 -407
- data/node_modules/govuk-frontend/components/input/template.njk +1 -0
- data/node_modules/govuk-frontend/components/inset-text/README.md +4 -76
- data/node_modules/govuk-frontend/components/label/README.md +5 -97
- data/node_modules/govuk-frontend/components/panel/README.md +4 -93
- data/node_modules/govuk-frontend/components/phase-banner/README.md +4 -67
- data/node_modules/govuk-frontend/components/radios/README.md +4 -665
- data/node_modules/govuk-frontend/components/radios/template.njk +1 -0
- data/node_modules/govuk-frontend/components/select/README.md +4 -257
- data/node_modules/govuk-frontend/components/select/template.njk +1 -0
- data/node_modules/govuk-frontend/components/skip-link/README.md +4 -57
- data/node_modules/govuk-frontend/components/table/README.md +4 -368
- data/node_modules/govuk-frontend/components/tabs/README.md +4 -242
- data/node_modules/govuk-frontend/components/tag/README.md +4 -77
- data/node_modules/govuk-frontend/components/textarea/README.md +4 -193
- data/node_modules/govuk-frontend/components/textarea/template.njk +1 -0
- data/node_modules/govuk-frontend/components/warning-text/README.md +4 -63
- data/node_modules/govuk-frontend/components/warning-text/_warning-text.scss +1 -2
- data/node_modules/govuk-frontend/core/_lists.scss +17 -8
- data/node_modules/govuk-frontend/package.json +10 -10
- metadata +4 -5
- data/app/views/govuk_publishing_components/components/_taxonomy_navigation.html.erb +0 -116
- data/app/views/govuk_publishing_components/components/docs/taxonomy_navigation.yml +0 -119
- data/lib/govuk_publishing_components/presenters/taxonomy_navigation.rb +0 -47
@@ -1,74 +1,15 @@
|
|
1
1
|
# Warning text
|
2
2
|
|
3
|
-
##
|
3
|
+
## Installation
|
4
4
|
|
5
|
-
|
5
|
+
See the [main README quick start guide](https://github.com/alphagov/govuk-frontend#quick-start) for how to install this component.
|
6
6
|
|
7
|
-
## Guidance
|
7
|
+
## Guidance and Examples
|
8
8
|
|
9
9
|
Find out when to use the warning text component in your service in the [GOV.UK Design System](https://design-system.service.gov.uk/components/warning-text).
|
10
10
|
|
11
|
-
## Quick start examples
|
12
|
-
|
13
|
-
### Warning text
|
14
|
-
|
15
|
-
[Preview this example in the Frontend review app](http://govuk-frontend-review.herokuapp.com/components/warning-text/preview)
|
16
|
-
|
17
|
-
#### Markup
|
18
|
-
|
19
|
-
<div class="govuk-warning-text">
|
20
|
-
<span class="govuk-warning-text__icon" aria-hidden="true">!</span>
|
21
|
-
<strong class="govuk-warning-text__text">
|
22
|
-
<span class="govuk-warning-text__assistive">Warning</span>
|
23
|
-
You can be fined up to £5,000 if you don’t register.
|
24
|
-
</strong>
|
25
|
-
</div>
|
26
|
-
|
27
|
-
#### Macro
|
28
|
-
|
29
|
-
{% from "warning-text/macro.njk" import govukWarningText %}
|
30
|
-
|
31
|
-
{{ govukWarningText({
|
32
|
-
"text": "You can be fined up to £5,000 if you don’t register.",
|
33
|
-
"iconFallbackText": "Warning"
|
34
|
-
}) }}
|
35
|
-
|
36
|
-
## Requirements
|
37
|
-
|
38
|
-
### Build tool configuration
|
39
|
-
|
40
|
-
When compiling the Sass files you'll need to define includePaths to reference the node_modules directory. Below is a sample configuration using gulp
|
41
|
-
|
42
|
-
.pipe(sass({
|
43
|
-
includePaths: 'node_modules/'
|
44
|
-
}))
|
45
|
-
|
46
|
-
### Static asset path configuration
|
47
|
-
|
48
|
-
In order to include the images used in the components, you need to configure your app to show these assets. Below is a sample configuration using Express js:
|
49
|
-
|
50
|
-
app.use('/assets', express.static(path.join(__dirname, '/node_modules/govuk-frontend/assets')))
|
51
|
-
|
52
11
|
## Component options
|
53
12
|
|
54
13
|
Use options to customise the appearance, content and behaviour of a component when using a macro, for example, changing the text.
|
55
14
|
|
56
|
-
See [options table](https://design-system.service.gov.uk/components/warning-text/#options-example-default) for details.
|
57
|
-
|
58
|
-
### Setting up Nunjucks views and paths
|
59
|
-
|
60
|
-
Below is an example setup using express configure views:
|
61
|
-
|
62
|
-
nunjucks.configure('node_modules/govuk-frontend/components', {
|
63
|
-
autoescape: true,
|
64
|
-
cache: false,
|
65
|
-
express: app
|
66
|
-
})
|
67
|
-
|
68
|
-
## Contribution
|
69
|
-
|
70
|
-
Guidelines can be found at [on our Github repository.](https://github.com/alphagov/govuk-frontend/blob/master/CONTRIBUTING.md "link to contributing guidelines on our github repository")
|
71
|
-
|
72
|
-
## License
|
73
|
-
|
74
|
-
MIT
|
15
|
+
See [options table](https://design-system.service.gov.uk/components/warning-text/#options-example-default) for details.
|
@@ -15,9 +15,10 @@
|
|
15
15
|
}
|
16
16
|
|
17
17
|
%govuk-list > li {
|
18
|
-
|
19
|
-
|
20
|
-
|
18
|
+
// Lists without numbers or bullets should always have extra space between
|
19
|
+
// list items. Lists with numbers or bullets only have this extra space on
|
20
|
+
// tablet and above
|
21
|
+
margin-bottom: govuk-spacing(1);
|
21
22
|
}
|
22
23
|
|
23
24
|
.govuk-list {
|
@@ -26,19 +27,27 @@
|
|
26
27
|
|
27
28
|
%govuk-list--bullet {
|
28
29
|
padding-left: govuk-spacing(4);
|
29
|
-
|
30
30
|
list-style-type: disc;
|
31
31
|
}
|
32
32
|
|
33
|
-
.govuk-list--bullet {
|
34
|
-
@extend %govuk-list--bullet;
|
35
|
-
}
|
36
|
-
|
37
33
|
%govuk-list--number {
|
38
34
|
padding-left: govuk-spacing(4);
|
39
35
|
list-style-type: decimal;
|
40
36
|
}
|
41
37
|
|
38
|
+
%govuk-list--bullet > li,
|
39
|
+
%govuk-list--number > li {
|
40
|
+
margin-bottom: 0;
|
41
|
+
|
42
|
+
@include govuk-media-query($from: tablet) {
|
43
|
+
margin-bottom: govuk-spacing(1);
|
44
|
+
}
|
45
|
+
}
|
46
|
+
|
47
|
+
.govuk-list--bullet {
|
48
|
+
@extend %govuk-list--bullet;
|
49
|
+
}
|
50
|
+
|
42
51
|
.govuk-list--number {
|
43
52
|
@extend %govuk-list--number;
|
44
53
|
}
|
@@ -15,13 +15,13 @@
|
|
15
15
|
],
|
16
16
|
"_from": "govuk-frontend@>=2.4.0 <3.0.0",
|
17
17
|
"_hasShrinkwrap": false,
|
18
|
-
"_id": "govuk-frontend@2.4.
|
18
|
+
"_id": "govuk-frontend@2.4.1",
|
19
19
|
"_inCache": true,
|
20
20
|
"_location": "/govuk-frontend",
|
21
21
|
"_nodeVersion": "8.9.4",
|
22
22
|
"_npmOperationalInternal": {
|
23
23
|
"host": "s3://npm-registry-packages",
|
24
|
-
"tmp": "tmp/govuk-frontend_2.4.
|
24
|
+
"tmp": "tmp/govuk-frontend_2.4.1_1544540702171_0.2508607154492737"
|
25
25
|
},
|
26
26
|
"_npmUser": {
|
27
27
|
"name": "govuk-patterns-and-tools",
|
@@ -41,8 +41,8 @@
|
|
41
41
|
"_requiredBy": [
|
42
42
|
"/"
|
43
43
|
],
|
44
|
-
"_resolved": "https://registry.npmjs.org/govuk-frontend/-/govuk-frontend-2.4.
|
45
|
-
"_shasum": "
|
44
|
+
"_resolved": "https://registry.npmjs.org/govuk-frontend/-/govuk-frontend-2.4.1.tgz",
|
45
|
+
"_shasum": "4e8e3b16aa588a25e6b7f97ab3ac0045df52c60c",
|
46
46
|
"_shrinkwrap": null,
|
47
47
|
"_spec": "govuk-frontend@^2.4.0",
|
48
48
|
"_where": "/var/lib/jenkins/workspace/ublishing_components_master-N4FWJIUY4CIFHKGZOAAEVVXODRY3YBORQOPIBBXWX72VUPSGJRRQ",
|
@@ -59,12 +59,12 @@
|
|
59
59
|
"devDependencies": {},
|
60
60
|
"directories": {},
|
61
61
|
"dist": {
|
62
|
-
"integrity": "sha512-
|
63
|
-
"shasum": "
|
64
|
-
"tarball": "https://registry.npmjs.org/govuk-frontend/-/govuk-frontend-2.4.
|
62
|
+
"integrity": "sha512-6cqX9YxypQfE7gfuexqSll3EAQLW2MDgL2w8LUEnmfW36cadUktZHjzyusOY/ggJxDAiiyEcC+9R8Oj57g90mw==",
|
63
|
+
"shasum": "4e8e3b16aa588a25e6b7f97ab3ac0045df52c60c",
|
64
|
+
"tarball": "https://registry.npmjs.org/govuk-frontend/-/govuk-frontend-2.4.1.tgz",
|
65
65
|
"fileCount": 245,
|
66
|
-
"unpackedSize":
|
67
|
-
"npm-signature": "-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\
|
66
|
+
"unpackedSize": 1272757,
|
67
|
+
"npm-signature": "-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcD9IeCRA9TVsSAnZWagAATyUP/0O0UQpHi0EUxuu08AFu\ncMcs1szsB3CzyD96TOhRYgnGUyqlfKKgHSZ9l7qdLSGpsTq1MueSBGUrR3wT\nLwHU6ILJvG4lPbUg6Lzk/j8BVEZmYVFcNqkwEKaYlOWvgdIdXoCXHtzaXW37\nxezsr5Eu8HLwZrc+SpDGGUN5oloqRssfjAQNOyaIEiZilPJDKNJe08dSdSuZ\nlmqQCLjyYpDtpN7TZo5VDeGD5c0plQPqION24Ppoa7OUaqd9WAjtptiru0NX\njz3HsV2asoeyYSmemvtzdeHBZgNfFYEa1ENYZW+42dGyoNYxOAC62jPI75Yt\nv8yQ1UYkdMtDDfqXiiMJoyL2YOs405v5/MRV2+swrnSfPqXDjpcjLZOFlu1E\nJEXEGfGrrTDp5RUe4b8ELF0tzsGBEJS5F7+Xs5Jn+ZThGaLMycyCpp/9T8a9\nl4NM1obmZAdvlyVV8t61p3gdG8U+zR1MOfw7wkKTxd/MliIM/6pd5ag6K37g\ngmVcAiNIO9tIvBPfU9tGJZ9/fSdEX95ORCeN7Ne5wbRg87P0jLrHaFx0RRWu\n+ZCgJdMJ2GL9gKyuBmcOiqPYThww0hmJJa8C3bIJUEdV7gkzizcIZJLulhev\naeGjp92s51ct4u3QI0qgn7T4qFpiUd3CVKMrXp8PJn4n8vfoo0jq8iLM8zGB\nqleR\r\n=jS0G\r\n-----END PGP SIGNATURE-----\r\n"
|
68
68
|
},
|
69
69
|
"engines": {
|
70
70
|
"node": ">= 4.2.0"
|
@@ -92,5 +92,5 @@
|
|
92
92
|
"url": "git+https://github.com/alphagov/govuk-frontend.git"
|
93
93
|
},
|
94
94
|
"sass": "all.scss",
|
95
|
-
"version": "2.4.
|
95
|
+
"version": "2.4.1"
|
96
96
|
}
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: govuk_publishing_components
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 12.
|
4
|
+
version: 12.21.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- GOV.UK Dev
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-12-
|
11
|
+
date: 2018-12-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: govspeak
|
@@ -446,6 +446,7 @@ files:
|
|
446
446
|
- app/views/govuk_publishing_components/components/_checkboxes.html.erb
|
447
447
|
- app/views/govuk_publishing_components/components/_contents_list.html.erb
|
448
448
|
- app/views/govuk_publishing_components/components/_contextual_breadcrumbs.html.erb
|
449
|
+
- app/views/govuk_publishing_components/components/_contextual_footer.html.erb
|
449
450
|
- app/views/govuk_publishing_components/components/_contextual_sidebar.html.erb
|
450
451
|
- app/views/govuk_publishing_components/components/_copy_to_clipboard.html.erb
|
451
452
|
- app/views/govuk_publishing_components/components/_details.html.erb
|
@@ -494,7 +495,6 @@ files:
|
|
494
495
|
- app/views/govuk_publishing_components/components/_table.html.erb
|
495
496
|
- app/views/govuk_publishing_components/components/_tabs.html.erb
|
496
497
|
- app/views/govuk_publishing_components/components/_taxonomy_list.html.erb
|
497
|
-
- app/views/govuk_publishing_components/components/_taxonomy_navigation.html.erb
|
498
498
|
- app/views/govuk_publishing_components/components/_textarea.html.erb
|
499
499
|
- app/views/govuk_publishing_components/components/_title.html.erb
|
500
500
|
- app/views/govuk_publishing_components/components/_translation-nav.html.erb
|
@@ -509,6 +509,7 @@ files:
|
|
509
509
|
- app/views/govuk_publishing_components/components/docs/checkboxes.yml
|
510
510
|
- app/views/govuk_publishing_components/components/docs/contents_list.yml
|
511
511
|
- app/views/govuk_publishing_components/components/docs/contextual_breadcrumbs.yml
|
512
|
+
- app/views/govuk_publishing_components/components/docs/contextual_footer.yml
|
512
513
|
- app/views/govuk_publishing_components/components/docs/contextual_sidebar.yml
|
513
514
|
- app/views/govuk_publishing_components/components/docs/copy_to_clipboard.yml
|
514
515
|
- app/views/govuk_publishing_components/components/docs/details.yml
|
@@ -557,7 +558,6 @@ files:
|
|
557
558
|
- app/views/govuk_publishing_components/components/docs/table.yml
|
558
559
|
- app/views/govuk_publishing_components/components/docs/tabs.yml
|
559
560
|
- app/views/govuk_publishing_components/components/docs/taxonomy_list.yml
|
560
|
-
- app/views/govuk_publishing_components/components/docs/taxonomy_navigation.yml
|
561
561
|
- app/views/govuk_publishing_components/components/docs/textarea.yml
|
562
562
|
- app/views/govuk_publishing_components/components/docs/title.yml
|
563
563
|
- app/views/govuk_publishing_components/components/docs/translation-nav.yml
|
@@ -611,7 +611,6 @@ files:
|
|
611
611
|
- lib/govuk_publishing_components/presenters/step_by_step_nav_helper.rb
|
612
612
|
- lib/govuk_publishing_components/presenters/subscription_links_helper.rb
|
613
613
|
- lib/govuk_publishing_components/presenters/taxonomy_list_helper.rb
|
614
|
-
- lib/govuk_publishing_components/presenters/taxonomy_navigation.rb
|
615
614
|
- lib/govuk_publishing_components/presenters/translation_nav_helper.rb
|
616
615
|
- lib/govuk_publishing_components/version.rb
|
617
616
|
- lib/tasks/govuk_publishing_components_tasks.rake
|
@@ -1,116 +0,0 @@
|
|
1
|
-
<% if local_assigns[:items] && !items.blank? %>
|
2
|
-
<aside class='gem-c-taxonomy-navigation' data-module='track-click' role='complementary'>
|
3
|
-
<h2 class='gem-c-taxonomy-navigation__heading'><%= t("components.taxonomy_navigation.related_content") %></h2>
|
4
|
-
<% items.each_with_index do |item, item_index| %>
|
5
|
-
<div data-track-count="sidebarTaxonSection">
|
6
|
-
<h3 class='gem-c-taxonomy-navigation__heading'>
|
7
|
-
<%=
|
8
|
-
link_to_if(
|
9
|
-
item[:url],
|
10
|
-
item[:title],
|
11
|
-
item[:url],
|
12
|
-
class: 'gem-c-taxonomy-navigation__link',
|
13
|
-
data: {
|
14
|
-
track_category: 'relatedLinkClicked',
|
15
|
-
track_action: "#{item_index + 1}",
|
16
|
-
track_label: item[:url],
|
17
|
-
track_options: {
|
18
|
-
dimension28: items.length.to_s,
|
19
|
-
dimension29: item[:title],
|
20
|
-
},
|
21
|
-
},
|
22
|
-
)
|
23
|
-
%>
|
24
|
-
</h3>
|
25
|
-
|
26
|
-
<p class='gem-c-taxonomy-navigation__taxon-description'>
|
27
|
-
<%= item[:description] %>
|
28
|
-
</p>
|
29
|
-
|
30
|
-
<% item[:related_content] ||= [] %>
|
31
|
-
<% if item[:related_content].any? %>
|
32
|
-
<nav class='gem-c-taxonomy-navigation__navigation' role='navigation'>
|
33
|
-
<ul class='gem-c-taxonomy-navigation__list'>
|
34
|
-
<% item[:related_content].each_with_index do |related_item, related_content_index| %>
|
35
|
-
<li class='gem-c-taxonomy-navigation__item'>
|
36
|
-
<%=
|
37
|
-
link_to(
|
38
|
-
related_item[:title],
|
39
|
-
related_item[:link],
|
40
|
-
data: {
|
41
|
-
track_category: 'relatedLinkClicked',
|
42
|
-
track_action: "#{item_index + 1}.#{related_content_index + 1}",
|
43
|
-
track_label: related_item[:link],
|
44
|
-
track_options: {
|
45
|
-
dimension28: item[:related_content].length.to_s,
|
46
|
-
dimension29: related_item[:title],
|
47
|
-
}
|
48
|
-
},
|
49
|
-
class: 'related-link gem-c-taxonomy-navigation__link',
|
50
|
-
)
|
51
|
-
%>
|
52
|
-
</li>
|
53
|
-
<% end %>
|
54
|
-
</ul>
|
55
|
-
</nav>
|
56
|
-
<% end %>
|
57
|
-
</div>
|
58
|
-
<% end %>
|
59
|
-
|
60
|
-
<% local_assigns.except(:items).each do |section_name, section| %>
|
61
|
-
<% if section && !section.blank? %>
|
62
|
-
<div>
|
63
|
-
<h3 class='gem-c-taxonomy-navigation__section-heading'>
|
64
|
-
<%= t("components.taxonomy_navigation.#{section_name}") %>
|
65
|
-
</h3>
|
66
|
-
<nav class='gem-c-taxonomy-navigation__navigation' data-module='gem-toggle' role='navigation'>
|
67
|
-
<ul class='gem-c-taxonomy-navigation__list'>
|
68
|
-
<% sidx = 0; hidden_links = [] %>
|
69
|
-
<% section.each_with_index do |item, idx| %>
|
70
|
-
<% if item[:text] && item[:path] %>
|
71
|
-
<% link_element = link_to(
|
72
|
-
item[:text], item[:path],
|
73
|
-
class: "gem-c-taxonomy-navigation__section-link",
|
74
|
-
rel: item[:rel],
|
75
|
-
data: {
|
76
|
-
track_category: 'relatedLinkClicked',
|
77
|
-
track_action: "#{sidx += 1}.#{idx + 1} #{t('components.taxonomy_navigation.related_content')}",
|
78
|
-
track_label: item[:path],
|
79
|
-
track_options: {
|
80
|
-
dimension28: section.length.to_s,
|
81
|
-
dimension29: item[:text]
|
82
|
-
}
|
83
|
-
}
|
84
|
-
) %>
|
85
|
-
<% if idx < 5 %>
|
86
|
-
<li><%= link_element %></li>
|
87
|
-
<% else %>
|
88
|
-
<% hidden_links << link_element %>
|
89
|
-
<% end %>
|
90
|
-
<% end %>
|
91
|
-
<% end %>
|
92
|
-
<% if hidden_links.any? %>
|
93
|
-
<li class="gem-c-taxonomy-navigation__link toggle-wrap">
|
94
|
-
<a href="#"
|
95
|
-
class="gem-c-taxonomy-navigation__toggle"
|
96
|
-
data-controls="toggle_<%= section_name %>"
|
97
|
-
data-expanded="false"
|
98
|
-
data-toggled-text="<%= t("govuk_component.metadata.toggle_less", default: "Show fewer") %>">
|
99
|
-
<%= t("govuk_component.metadata.toggle_more",
|
100
|
-
number: hidden_links.size,
|
101
|
-
default: "+ #{hidden_links.size} more") %>
|
102
|
-
</a>
|
103
|
-
</li>
|
104
|
-
<li class="gem-c-taxonomy-navigation__link">
|
105
|
-
<span id="toggle_<%= section_name %>" class="gem-c-taxonomy-navigation__toggle-more js-hidden">
|
106
|
-
<%= to_sentence(hidden_links) %>
|
107
|
-
</span>
|
108
|
-
</li>
|
109
|
-
<% end %>
|
110
|
-
</ul>
|
111
|
-
</nav>
|
112
|
-
</div>
|
113
|
-
<% end %>
|
114
|
-
<% end %>
|
115
|
-
</aside>
|
116
|
-
<% end %>
|
@@ -1,119 +0,0 @@
|
|
1
|
-
name: "Taxonomy navigation"
|
2
|
-
description: "Sidebar navigation for displaying on pages tagged to the GOV.UK taxonomy."
|
3
|
-
body: |
|
4
|
-
This component should not be used directly, the contextual-sidebar component uses
|
5
|
-
this component for content which should present taxonomy navigation.
|
6
|
-
|
7
|
-
Accepts an array of items. These items are typically the list of taxons the current
|
8
|
-
content page is tagged to.
|
9
|
-
|
10
|
-
Each item is a hash with a title, url, description, and list of related content
|
11
|
-
associated with that item.
|
12
|
-
|
13
|
-
Sections of links appear below the main taxonomy-driven navigation items. These are
|
14
|
-
Collections, Statistical data sets, Topical events and World locations.
|
15
|
-
|
16
|
-
This implementation is very similar to the related-navigation component in that the
|
17
|
-
same sections are appended. The two components should ultimately be merged to form
|
18
|
-
a consolidated sidebar navigation.
|
19
|
-
accessibility_criteria: |
|
20
|
-
- Should have a role of 'complementary' as it complements the main page content
|
21
|
-
- Should have a role of 'navigation' on any navigation elements inside the component
|
22
|
-
shared_accessibility_criteria:
|
23
|
-
- link
|
24
|
-
examples:
|
25
|
-
default:
|
26
|
-
data:
|
27
|
-
items:
|
28
|
-
- title: "School curriculum"
|
29
|
-
url: /education/school-curriculum
|
30
|
-
description: |
|
31
|
-
Early years, key stages 1 to 5, GCSE and AS and A level reforms, tests,
|
32
|
-
exams and assessments, PSHE and SMSC.
|
33
|
-
related_content:
|
34
|
-
- title: "The national curriculum"
|
35
|
-
link: /national-curriculum
|
36
|
-
- title: "Tests (key stage 1)"
|
37
|
-
url: /key-stage-1-tests
|
38
|
-
description: |
|
39
|
-
Key dates, sample and test materials, administration, moderation,
|
40
|
-
assessing and reporting, statistics, frameworks.
|
41
|
-
related_content:
|
42
|
-
- title: "Key stage 1 teacher assessment"
|
43
|
-
link: /government/collections/key-stage-1-teacher-assessment
|
44
|
-
- title: "Primary assessments: information and resources for 2017"
|
45
|
-
link: /government/publications/primary-assessments-information-and-resources-for-2017
|
46
|
-
long_example:
|
47
|
-
data:
|
48
|
-
items:
|
49
|
-
- title: "School curriculum for children ages 16 to 19, and 10 to 14"
|
50
|
-
url: /education/school-curriculum
|
51
|
-
description: |
|
52
|
-
Early years, key stages 1 to 5, GCSE and AS and A level reforms, tests,
|
53
|
-
exams and assessments, PSHE and SMSC. Widening participation, funding
|
54
|
-
for children in deprived areas. Improving attainment in schools for
|
55
|
-
looked-after children.
|
56
|
-
related_content:
|
57
|
-
- title: "Further education financial management and data collection"
|
58
|
-
link: /government/collections/key-stage-1-teacher-assessment
|
59
|
-
- title: "Primary assessments: information and resources for 2017"
|
60
|
-
link: /government/publications/primary-assessments-information-and-resources-for-2017
|
61
|
-
- title: "Slide pack from Phil Beach at the Skills & Employability Summit"
|
62
|
-
link: /government/publications/primary-assessments-information-and-resources-for-2017
|
63
|
-
- title: "Transport to education and training for people aged 16 to 18"
|
64
|
-
link: /government/publications/primary-assessments-information-and-resources-for-2017
|
65
|
-
- title: "Tests (key stage 1, 2 and 3), plus further tests outside of school"
|
66
|
-
url: /key-stage-1-tests
|
67
|
-
description: |
|
68
|
-
Key dates, sample and test materials, administration, moderation,
|
69
|
-
assessing and reporting, statistics, frameworks. University and college
|
70
|
-
qualifications. Apprenticeships, traineeships and internships. Funding
|
71
|
-
for further education providers.
|
72
|
-
related_content:
|
73
|
-
- title: "Key stage 1 teacher assessment"
|
74
|
-
link: /government/collections/key-stage-1-teacher-assessment
|
75
|
-
- title: "Primary assessments: information and resources for 2017"
|
76
|
-
link: /government/publications/primary-assessments-information-and-resources-for-2017
|
77
|
-
collections:
|
78
|
-
- text: "Statistics: outcome based success measures"
|
79
|
-
path: "/government/collections/statistics-outcome-based-success-measures"
|
80
|
-
world_locations:
|
81
|
-
- text: "Afghanistan"
|
82
|
-
path: "/world/afghanistan/news"
|
83
|
-
- text: "Albania"
|
84
|
-
path: "/world/albania/news"
|
85
|
-
- text: "Algeria"
|
86
|
-
path: "/world/algeria/news"
|
87
|
-
- text: "Angola"
|
88
|
-
path: "/world/angola/news"
|
89
|
-
- text: "Anguilla"
|
90
|
-
path: "/world/anguilla/news"
|
91
|
-
- text: "Argentina"
|
92
|
-
path: "/world/argentina/news"
|
93
|
-
no_children:
|
94
|
-
description: |
|
95
|
-
Shows a sidebar with a taxon link but without any child content links.
|
96
|
-
data:
|
97
|
-
items:
|
98
|
-
- title: "School curriculum"
|
99
|
-
url: /education/school-curriculum
|
100
|
-
description: |
|
101
|
-
Early years, key stages 1 to 5, GCSE and AS and A level reforms, tests,
|
102
|
-
exams and assessments, PSHE and SMSC.
|
103
|
-
- title: "Tests (key stage 1)"
|
104
|
-
url: /key-stage-1-tests
|
105
|
-
description: |
|
106
|
-
Key dates, sample and test materials, administration, moderation,
|
107
|
-
assessing and reporting, statistics, frameworks.
|
108
|
-
taxon_with_no_link:
|
109
|
-
data:
|
110
|
-
items:
|
111
|
-
- title: "Taxon without a link"
|
112
|
-
description: |
|
113
|
-
Early years, key stages 1 to 5, GCSE and AS and A level reforms, tests,
|
114
|
-
exams and assessments, PSHE and SMSC.
|
115
|
-
related_content:
|
116
|
-
- title: "Key stage 1 teacher assessment"
|
117
|
-
link: /government/collections/key-stage-1-teacher-assessment
|
118
|
-
- title: "Primary assessments: information and resources for 2017"
|
119
|
-
link: /government/publications/primary-assessments-information-and-resources-for-2017
|