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

unsetting the value that is been set is not working #599

Open
kth13 opened this issue Sep 19, 2023 · 1 comment
Open

unsetting the value that is been set is not working #599

kth13 opened this issue Sep 19, 2023 · 1 comment

Comments

@kth13
Copy link

kth13 commented Sep 19, 2023

We are using the accessible auto complete for our application. We are using the js along with Nunjucks. The steps to reproduce the error

  • Type the element you want to select and auto complete picks up the element and sets in the input field
  • select the element you want
  • delete that element
  • submit the form, still the input field has the old value.
  • is there any way to unset the element from the input box
@DavidBiddle
Copy link

We got feedback about a case of this on a service we have which uses the autocomplete. In our case it was noticed when using a 'change your answers' journey - if a user:

  • has previously set a value
  • follows a 'Change' link to go back and change their answers
  • removes the default value
  • presses 'Save and continue'

then their original answer will be saved.

I can see this potentially being confusing in this context, but I'm not sure if there's another behaviour we'd expect. The component is designed to allow a user to pick from a list of predefined values, and an empty value isn't a valid value, so I can see the logic of not allowing a user to unset it.

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

No branches or pull requests

2 participants