Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to govuk-frontend v4.0.0 with required changes #147

Merged
merged 5 commits into from
Dec 16, 2021
Merged

Conversation

kr8n3r
Copy link
Contributor

@kr8n3r kr8n3r commented Dec 16, 2021

What

How to test

  • check commits for code changes
  • clone branch
  • install updated dependencies (npm install)
  • build the site (npm run build)
  • cd into out folder and serve the page (npx serve)
  • check page on localhost:5000 for any issues

There are expected warnings in CSS compilation coming from govuk-frontend

npm install will output 6 high severity vulnerabilities. Currently no fix available for that.

- move the <button> inside the <nav>, immediately before the <ul>
- move the aria-label attribute from the <ul> to the <nav>
- move the govuk-header__navigation class from the <ul> to the <nav>
- add the govuk-header__navigation-list class to the <ul>

As per https://github.com/alphagov/govuk-frontend/releases/tag/v4.0.0
to improve screen reader announcements
add a data-module="govuk-skip-link" attribute to the component HTML.

Once you've made the changes, check the skip link JavaScript works.
To do this, select the skip link and check the linked element
(usually the <main> element) in the browser has a tabindex attribute.

As per https://github.com/alphagov/govuk-frontend/releases/tag/v4.0.0
Footer should now have grid column classes like
```
<div class="govuk-footer__section govuk-grid-column-two-thirds">...</div>
```
And because offt he dynamic nature, we need to make it configurable in
the json, much like https://github.com/alphagov/govuk-frontend/blob/main/src/govuk/components/footer/template.njk#L7

As per https://github.com/alphagov/govuk-frontend/releases/tag/v4.0.0
@kr8n3r kr8n3r merged commit f428bdf into main Dec 16, 2021
@kr8n3r kr8n3r deleted the govuk-frontend-v4 branch December 16, 2021 12:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants