umbraco/Umbraco.UI

Bug: Validation with Combobox

warrenbuckley opened this issue · 0 comments

Which exact UI Library version are you using? For example: 1.0.1 - don't just write v1.

CDN UUI Bundle Latest aka 1.0.0-rc.1 https://cdn.jsdelivr.net/npm/@umbraco-ui/uui@latest/dist/uui.min.js

Bug summary

When using the required and required-message attributes on the combobox the validation will not show if you use the cross/clear button inside the input to clear your selection, I would have thought

Specifics

Here is a short video showing the problem
https://user-images.githubusercontent.com/1389894/178718148-77c1509b-be19-4ad9-9a34-858d98fbb93a.mp4

Steps to reproduce

See this Stackblitz & attached video
https://stackblitz.com/edit/uui-combobox-bug?file=index.html

  • Click into combobox and away again - Validation message fires
  • Click into combobox and choose an option - validation hides as expected
  • Clear out the chosen item with the X - I expect validation to reappear as its now empty and required
  • Submit form - form does not submit as expected but no way to know there is an error
  • Choose a value and submit - form submits/redirects to Google

Expected result / actual result

No response