You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
The select widget allows true numbers (not numeric strings) to be stored by passing an array of { label: string, value: number } objects as the options parameter.
However, when an option with a value of 0 is selected in the UI, the field becomes empty, likely due to some bug related to input validation. Since the field becomes empty, if the select is required, the entry cannot be saved, otherwise the value saves as null.
To Reproduce
Create a select widget and add an option which has any label and a value of 0.
Attempt to select that option via the UI
Expected behavior
The option with a value of 0 is selected and its label is displayed
Applicable Versions:
Netlify CMS version: 2.10.192
The text was updated successfully, but these errors were encountered:
Describe the bug
The
select
widget allows true numbers (not numeric strings) to be stored by passing an array of{ label: string, value: number }
objects as theoptions
parameter.However, when an option with a value of
0
is selected in the UI, the field becomes empty, likely due to some bug related to input validation. Since the field becomes empty, if theselect
isrequired
, the entry cannot be saved, otherwise the value saves asnull
.To Reproduce
Create a
select
widget and add an option which has any label and a value of0
.Attempt to select that option via the UI
Expected behavior
The option with a value of
0
is selected and its label is displayedApplicable Versions:
The text was updated successfully, but these errors were encountered: