Skip to content

Commit

Permalink
Merge pull request #361 from nowcommunity/radio-selector-puts-default…
Browse files Browse the repository at this point in the history
…Value-to-editData

radio selector now adds its defaultValue to editData
  • Loading branch information
kaarleol authored Oct 18, 2024
2 parents 9123336 + f2b1b40 commit 4a98d37
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ export const RadioSelector = <T extends object>({
defaultValue = getValue(options[0])
}
if (editData[field] === null) {
setEditData({ ...editData, [field]: getValue(options[0]) })
setEditData({ ...editData, [field]: defaultValue })
}
const editingComponent = (
<FormControl>
Expand Down

0 comments on commit 4a98d37

Please sign in to comment.