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

Fix select placeholder configuration #1470

Merged
merged 1 commit into from
Oct 31, 2023

Conversation

lucasnetau
Copy link
Collaborator

@lucasnetau lucasnetau commented Oct 25, 2023

When creating a select field with both a placeholder we set the value to an empty string '' otherwise it will take the value of the option's textContent. If value is not set to an empty string then an check for required validity will return true.

PR also updates disabled and selected to boolean values so they are rendered correctly.

Prev: <option disabled="null" selected="null">Select an option</option>

Now: <option disabled="disabled" selected="selected" value>Select an option</option>

…o an empty string '' to allow for required validation to occur
Copy link
Owner

@kevinchappell kevinchappell left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@kevinchappell kevinchappell merged commit 265c161 into kevinchappell:master Oct 31, 2023
1 check passed
Copy link

🎉 This PR is included in version 3.16.8 🎉

The release is available on:

Your semantic-release bot 📦🚀

@lucasnetau lucasnetau deleted the select branch October 31, 2023 22:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants