Skip to content

Commit 9eba0af

Browse files
authored
Merge branch 'master' into fix-multipage-nav-toc
2 parents 4fabee6 + 210d3d4 commit 9eba0af

File tree

132 files changed

+3886
-3894
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

132 files changed

+3886
-3894
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,3 +32,4 @@
3232
/example/.sass-cache
3333

3434
Gemfile.lock
35+
node_modules

.nvmrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
10.16.0

.rubocop.yml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
1-
Layout/IndentHeredoc:
1+
inherit_gem:
2+
rubocop-govuk:
3+
- config/default.yml
4+
5+
Layout/HeredocIndentation:
26
Enabled: false
37

48
Naming/HeredocDelimiterNaming:
59
Enabled: false
610

711
Lint/NestedMethodDefinition:
812
Enabled: false
9-
10-
Performance/HashEachMethods:
11-
Enabled: false

.ruby-version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2.4.2
1+
2.6.3

.travis.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,9 @@
11
language: ruby
2+
before_install:
3+
- gem update --system
4+
- gem install bundler
5+
before_script:
6+
- npm install
27
deploy:
38
provider: rubygems
49
gem: govuk_tech_docs

CHANGELOG.md

Lines changed: 115 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,120 @@
11
# Changelog
22

3+
## Unreleased
4+
5+
## 2.1.0
6+
7+
### New features
8+
9+
#### Exclude pages from search engine results
10+
11+
You can now exclude a page from search engine results by including `prevent_indexing: true` in the page's frontmatter.
12+
13+
This was added in [pull request #192: Fixes and improvements to meta tags](https://github.com/alphagov/tech-docs-gem/pull/192).
14+
15+
### Fixes
16+
17+
We’ve made fixes in the following pull requests:
18+
19+
- [#192: Fixes and improvements to meta tags](https://github.com/alphagov/tech-docs-gem/pull/192)
20+
21+
## 2.0.13
22+
23+
- [Pull request #189: Update orange code highlight colour to meet minimum AA colour contrast ratio criterion](https://github.com/alphagov/tech-docs-gem/pull/189)
24+
25+
## 2.0.12
26+
27+
- [Pull request #179: Use current markup for header and footer](https://github.com/alphagov/tech-docs-gem/pull/179)
28+
- [Pull request #178: Update dependencies and fix tests](https://github.com/alphagov/tech-docs-gem/pull/178) – includes updating GOV.UK Frontend to v3.6.0.
29+
- [Pull request #176: Use correct separator for page titles](https://github.com/alphagov/tech-docs-gem/pull/176)
30+
31+
## 2.0.11
32+
33+
### Fixes
34+
35+
- [Pull request #162: Fix line height spacing for multiline code elements](https://github.com/alphagov/tech-docs-gem/pull/162)
36+
- [Pull request #165: Update header alignment to match layout](https://github.com/alphagov/tech-docs-gem/pull/165)
37+
38+
## 2.0.10
39+
40+
### Fixes
41+
42+
- [Pull request #160: Make sure IDs on collapsible navigation are unique](https://github.com/alphagov/tech-docs-gem/pull/160)
43+
44+
## 2.0.9
45+
46+
### Fixes
47+
48+
- [Pull request #154: Fix table columns breaking content](https://github.com/alphagov/tech-docs-gem/pull/154).
49+
- [Pull request #155: Ensure the page can be pinch to zoomed](https://github.com/alphagov/tech-docs-gem/pull/155).
50+
51+
## 2.0.8
52+
53+
Use of `govuk-lint` replaced with `rubocop-govuk` due to the former [becoming deprecated](https://github.com/alphagov/govuk-lint/pull/133).
54+
55+
## 2.0.7
56+
57+
A small release to fix an issue where code blocks font size was too large on some browsers.
58+
59+
See [pull request #131: Improve code font sizing ](https://github.com/alphagov/tech-docs-gem/pull/131) for details.
60+
61+
62+
## 2.0.6
63+
64+
This release contains accessibility fixes:
65+
66+
- anchor header links are now properly hidden to assistive technologies
67+
- side navigation items now have consistent visible focus when tabbing between them
68+
- side navigation items have unique Ids
69+
- code elements now scale properly when you enlarge your text
70+
- links with code elements now look correct
71+
- contribution links are now within a landmark
72+
73+
You can look at the [2.0.6 milestone](https://github.com/alphagov/tech-docs-gem/milestone/2?closed=1) for the closed issues, and [pull request #129: Accessibility improvements](https://github.com/alphagov/tech-docs-gem/pull/129) for details on how these issues were fixed.
74+
75+
## 2.0.5
76+
77+
78+
Adds [new global configuration option](https://github.com/alphagov/tech-docs-gem/pull/122) that controls whether review banners appear or not at the bottom of pages when expiry dates are set in the frontmatter.
79+
80+
[Fixes the hard-coded service link](https://github.com/alphagov/tech-docs-gem/pull/119) in the header.
81+
82+
Selectively include only the CSS for the GOV.UK Frontend components that we are using, to reduce the size of the CSS file served to the user ([#118](https://github.com/alphagov/tech-docs-gem/issues/118))
83+
84+
Fix service name to link to the configured `service_link`, rather than being hardcoded to `/` ([#119](https://github.com/alphagov/tech-docs-gem/issues/119))
85+
86+
Add the `show_review_banner` global configuration option allowing users to hide the page review banner.
87+
88+
## 2.0.4
89+
90+
Adds `footer_links` option for displaying links in the footer and ability to hide pages from left hand navigation.
91+
92+
## 2.0.3
93+
94+
Fixes a couple of styling issues: [#100](https://github.com/alphagov/tech-docs-gem/issues/100) and [#106](https://github.com/alphagov/tech-docs-gem/issues/106).
95+
96+
## 2.0.2
97+
98+
This fixes ensures all assets from govuk-frontend are bundled; we were missing some PNG, SVG and ICO files.
99+
100+
## 2.0.1
101+
102+
This fixes an issue where Travis CI wasn’t packaging up the gem with the govuk-frontend module.
103+
Without this the tech-docs have no css styles.
104+
105+
## 2.0.0
106+
107+
This release adds [GOV.UK Frontend](https://github.com/alphagov/govuk-frontend) (part of the [GOV.UK Design System](https://design-system.service.gov.uk)) and remove the legacy framework [GOV.UK Frontend Toolkit](https://github.com/alphagov/govuk_frontend_toolkit). This required a lot of markup being ported over
108+
to use the design system’s markup and all custom CSS to use new variables and mixins.
109+
110+
Custom components such as the table of contents (toc) were updated to use the WCAG 2.1 AA compliant focus states too.
111+
112+
It was also necessary to upgrade the Ruby version to `2.6.3` so that we could bump the gem versions of `govuk_lint`, `rubocop` and `sprockets`. The new version of sprockets allowed us to pull through assets from `node_modules/govuk-frontend` without having to manually include them as was the case before with govuk_frontend_toolkit.
113+
114+
## 1.8.3
115+
116+
Fixes bug where search results disappear when opening results in a new tab, making it difficult to open several results in a batch (PR #86).
117+
3118
## 1.8.2
4119

5120
Adds a `show_expiry` config option to allow you to choose whether to show the review due date and expired banner from your pages. Find out more about the [page expiry and review feature][expiry].

CONTRIBUTING.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,10 @@
33
Everybody who uses this project is encouraged to contribute to this project. If you're part of the [alphagov GitHub organisation](https://www.github.com/alphagov) you probably have write access to this repo. If you don't, ask a GitHub admin or #tech-docs-format on Slack.
44

55
- Before adding your feature, [check the backlog to see if someone is already talking about it](https://github.com/alphagov/tech-docs-template/issues)
6-
- If you add a new option to `config/tech-docs.yml`, make sure you [document the option in docs/configuration.md](docs/configuration.md)
7-
- If you add a new option to the page frontmatter, make sure you [document the option in docs/frontmatter.md](docs/frontmatter.md)
6+
- If you add a new option to `config/tech-docs.yml`, make sure you [document the new configuration option][configuration]
7+
- If you add a new option to the page frontmatter, make sure you [document the new frontmatter configuration](docs/frontmatter.md)
88
- You can test your contribution using [unit tests](spec/govuk_tech_docs), [javascript tests](spec/javascripts) or [integration tests](spec/features)
99
- If your change is relevant to the users of the gem, add something to [CHANGELOG](CHANGELOG.md). You don't have to do this if it's just refactoring. Make sure that you include any upgrade instructions.
10+
11+
[configuration]: https://github.com/alphagov/tdt-documentation/blob/master/source/amend_project/configuration/index.html.md.erb
12+
[frontmatter]: https://github.com/alphagov/tdt-documentation/blob/master/source/frontmatter.html.md.erb

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,12 @@ Everybody who uses this project is encouraged to contribute.
1515

1616
👉 [See CONTRIBUTING.md](CONTRIBUTING.md) for guidance on making changes.
1717

18+
## GOV.UK frontend
19+
20+
This gem uses [GOV.UK Frontend](https://github.com/alphagov/govuk-frontend), part of the [GOV.UK Design System](https://design-system.service.gov.uk/).
21+
22+
We use `npm` to download the govuk-frontend package. To update to a new version, change the version in [package.json](blob/master/package.json) and run `npm update`.
23+
1824
## Developing locally
1925

2026
There are 2 ways to develop with this gem. You can see your changes on either:

Rakefile

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,15 @@
1-
require 'bundler/gem_tasks'
2-
require 'rspec/core/rake_task'
3-
require 'jasmine'
1+
require "bundler/gem_tasks"
2+
require "rspec/core/rake_task"
3+
require "jasmine"
44

55
RSpec::Core::RakeTask.new(:spec)
66

7-
load 'jasmine/tasks/jasmine.rake'
7+
load "jasmine/tasks/jasmine.rake"
88

9+
desc "Lint Ruby and JavaScript"
910
task :lint do
10-
sh "govuk-lint-ruby example lib spec Rakefile"
11+
sh "rubocop example lib spec Rakefile"
12+
sh "npm run lint --silent"
1113
end
1214

13-
task default: ['lint', 'spec', 'jasmine:ci']
15+
task default: ["lint", "spec", "jasmine:ci"]

0 commit comments

Comments
 (0)