Skip to content

Allow language switcher to change language without losing user data #7244

Description

@domoscargin

What

The default language switcher uses links. This has the potential to cause issues when we want to persist form data that a user has entered before switching language.

Explore two options:

  1. Default the language switcher to links, but allow the use of buttons styled as links instead.

Since the action to a user is still to navigate to a different page, we think the consistency of the link style is preferable to ensuring that buttons look like buttons.

This would allow services to submit a page form and have access to the form data without using JavaScript.

  1. Provide a JavaScript hook for clicking a language

Allow users to specify a callback for custom behaviour when they click a language.

Who needs to work on this

Developer
Accessibility specialist

Who needs to review this

Developer
Accessibility specialist

Done when

  • Languages can be selected without navigating away from the page

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Fields

No fields configured for issues without a type.

Projects

Status
In progress 📝

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions