File tree Expand file tree Collapse file tree 3 files changed +3
-3
lines changed
chakra/src/components/autoform Expand file tree Collapse file tree 3 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ export const SelectField: React.FC<AutoFormFieldProps> = ({
1414 const options =
1515 field . options ?. map ( ( option ) => ( {
1616 label : option [ 1 ] ,
17- value : option [ 1 ] ,
17+ value : option [ 0 ] ,
1818 } ) ) || [ ] ;
1919 return (
2020 < Select
Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ export const SelectField: React.FC<AutoFormFieldProps> = ({
2222 items :
2323 field . options ?. map ( ( option ) => ( {
2424 label : option [ 1 ] ,
25- value : option [ 1 ] ,
25+ value : option [ 0 ] ,
2626 } ) ) || [ ] ,
2727 } ) ;
2828
Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ export const SelectField: React.FC<AutoFormFieldProps> = ({
1010} ) => (
1111 < Select error = { ! ! error } fullWidth { ...inputProps } >
1212 { ( field . options || [ ] ) . map ( ( [ key , label ] ) => (
13- < MenuItem key = { key } value = { label } >
13+ < MenuItem key = { key } value = { key } >
1414 { label }
1515 </ MenuItem >
1616 ) ) }
You can’t perform that action at this time.
0 commit comments