Some fixes

This commit is contained in:
Gregory Schier
2025-11-26 14:10:02 -08:00
parent d356bac135
commit 1b5ac6fc89
2 changed files with 6 additions and 1 deletions

View File

@@ -15,6 +15,8 @@ export function applyFormInputDefaults(
for (const input of inputs) {
if ('defaultValue' in input && values[input.name] === undefined) {
newValues[input.name] = input.defaultValue;
} else if (input.type === 'checkbox' && values[input.name] === undefined) {
newValues[input.name] = false;
}
// Recurse down to all child inputs
if ('inputs' in input) {