Skip to content
Snippets Groups Projects
Commit a7af829c authored by Parth Bhattacharya's avatar Parth Bhattacharya
Browse files

issue-3498485: fixed false appearing in input text fields

parent 7ce28dee
No related branches found
No related tags found
No related merge requests found
......@@ -400,12 +400,15 @@ const InputBehaviorsEntityForm = (
const parseNewValue = (e: React.ChangeEvent) => {
const target = e.target as HTMLInputElement;
if (target.value) {
// If the target is an input element, return its value
if (target.value !== undefined) {
return target.value;
}
// If the target is a checkbox or radio button, return its checked
if ('checked' in target) {
return target.checked;
}
// If the target is neither an input element nor a checkbox/radio button, return null
return null;
};
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment