Ensure removing a field from the update flow clears any row value. If not cleared, the field will remain in place.
This commit is contained in:
parent
ec9ff57493
commit
37bfde9c93
|
@ -321,11 +321,15 @@
|
||||||
class:is-selected={Object.hasOwn(editableFields, field)}
|
class:is-selected={Object.hasOwn(editableFields, field)}
|
||||||
on:click={() => {
|
on:click={() => {
|
||||||
if (Object.hasOwn(editableFields, field)) {
|
if (Object.hasOwn(editableFields, field)) {
|
||||||
editableFields[field] = null
|
delete editableFields[field]
|
||||||
|
onChange({
|
||||||
|
meta: { fields: editableFields },
|
||||||
|
row: { [field]: null },
|
||||||
|
})
|
||||||
} else {
|
} else {
|
||||||
editableFields[field] = {}
|
editableFields[field] = {}
|
||||||
|
onChange({ meta: { fields: editableFields } })
|
||||||
}
|
}
|
||||||
onChange({ meta: { fields: editableFields } })
|
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<Icon
|
<Icon
|
||||||
|
|
Loading…
Reference in New Issue