Skip to content

Commit

Permalink
Merge pull request #2430 from saithsab877/Editing-color-does-not-trigger
Browse files Browse the repository at this point in the history
Blueprint] Editing color doesn't trigger `Confirm` button
  • Loading branch information
Rassl authored Nov 8, 2024
2 parents 429ba27 + 416a315 commit 4486153
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -420,6 +420,10 @@ export const Editor = ({
})

useEffect(() => {
if (selectedColor !== selectedSchema?.primary_color) {
setSubmitDisabled(false)
}

const subscription = form.watch((values) => {
const isMatch = compareAttributes(attributes, parsedData)

Expand All @@ -439,7 +443,7 @@ export const Editor = ({
})

return () => subscription.unsubscribe()
}, [form, attributes, parsedData, selectedSchema, loading, displayParentError])
}, [form, attributes, parsedData, selectedSchema, loading, displayParentError, selectedColor])

const resolvedParentValue = () => parentOptions?.find((i) => i.value === parent)

Expand Down

0 comments on commit 4486153

Please sign in to comment.