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

Bump govuk-frontend from 5.8.0 to 5.9.0 #4677

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Mar 5, 2025

Bumps govuk-frontend from 5.8.0 to 5.9.0.

Release notes

Sourced from govuk-frontend's releases.

GOV.UK Frontend v5.9.0

To install this version with npm, run npm install govuk-frontend@5.9.0. You can also find more information about how to stay up to date in our documentation.

New features

Use our improved File upload component

We've added a JavaScript enhancement to the File upload component which:

  • makes the component easier to use for drag and drop
  • allows the text of the component to be translated
  • fixes accessibility issues for users of Dragon, a speech recognition software This improvement is opt-in, as it's a substantial visual change which risks shifting other content on the page.

To enable this improvement for your users, you'll first need to update the markup of your File upload component:

  • if you use our Nunjucks macro, using the new javascript option of govukFileUpload
{{ govukFileUpload({
	id: "file-upload",
	name: "photo",
	label: {
		text: "Upload your photo"
	},
	javascript: true
}) }}
  • if you're using HTML, wrapping the <input type="file"> of the File upload markup in a <div class="govuk-drop-zone" data-module="govuk-file-upload">
<div class="govuk-form-group">
	<label class="govuk-label" for="file-upload-1">
		Upload your photo
	</label>
	<div class="govuk-drop-zone" data-module="govuk-file-upload">
		<input class="govuk-file-upload" id="file-upload" name="photo" type="file">
	</div>
</div>

If you're importing components individually in your JavaScript, which we recommend for better performance, you'll then need to import and initialise the new FileUpload component.

import {FileUpload} from 'govuk-frontend'
createAll(FileUpload)

This change was introduced in [pull request #5305: Add progressively enhanced File Upload component](alphagov/govuk-frontend#5305)

... (truncated)

Changelog

Sourced from govuk-frontend's changelog.

v5.9.0 (Feature release)

To install this version with npm, run npm install govuk-frontend@5.9.0. You can also find more information about how to stay up to date in our documentation.

New features

Use our improved File upload component

We've added a JavaScript enhancement to the File upload component which:

  • makes the component easier to use for drag and drop
  • allows the text of the component to be translated
  • fixes accessibility issues for users of Dragon, a speech recognition software

This improvement is opt-in, as it's a substantial visual change which risks shifting other content on the page.

To enable this improvement for your users, you'll first need to update the markup of your File upload component:

  • if you use our Nunjucks macro, using the new javascript option of govukFileUpload

    {{ govukFileUpload({
      id: "file-upload",
      name: "photo",
      label: {
        text: "Upload your photo"
      },
      javascript: true
    }) }}
  • if you're using HTML, wrapping the <input type="file"> of the File upload markup in a <div class="govuk-drop-zone" data-module="govuk-file-upload">

    <div class="govuk-form-group">
      <label class="govuk-label" for="file-upload-1">
        Upload your photo
      </label>
      <div class="govuk-drop-zone" data-module="govuk-file-upload">
        <input class="govuk-file-upload" id="file-upload" name="photo" type="file">
      </div>
    </div>

If you're importing components individually in your JavaScript, which we recommend for better performance, you'll then need to import and initialise the new FileUpload component.

import {FileUpload} from 'govuk-frontend'
createAll(FileUpload)
</tr></table>

... (truncated)

Commits
  • d75bca5 Merge pull request #5773 from alphagov/release-5.9.0
  • 04a3261 Release 5.9.0
  • 587c99d Merge pull request #5772 from alphagov/bk-changelog-code-example-spacing
  • e8e5c0b Update changelog code example spacing
  • 717fcb1 Merge pull request #5770 from alphagov/release-5.9.0-changelog
  • ecba856 Update CHANGELOG for v5.9.0
  • 364ecec Merge pull request #5750 from alphagov/dependabot/npm_and_yarn/test-1ae1c220d8
  • c524b75 Merge pull request #5768 from alphagov/puppetter-core-test-explanations
  • 4984bfe Merge pull request #5305 from alphagov/spike-enhanced-file-upload
  • a753f46 Merge pull request #5721 from alphagov/bk-deprecation-field
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [govuk-frontend](https://github.com/alphagov/govuk-frontend) from 5.8.0 to 5.9.0.
- [Release notes](https://github.com/alphagov/govuk-frontend/releases)
- [Changelog](https://github.com/alphagov/govuk-frontend/blob/main/CHANGELOG.md)
- [Commits](alphagov/govuk-frontend@v5.8.0...v5.9.0)

---
updated-dependencies:
- dependency-name: govuk-frontend
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot bot added dependencies Pull requests that update a dependency file javascript Pull requests that update Javascript code labels Mar 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file javascript Pull requests that update Javascript code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant