Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(ui): properly reflects hook changes in ui #10268

Merged
merged 2 commits into from
Jan 3, 2025

Conversation

jmikrut
Copy link
Member

@jmikrut jmikrut commented Dec 30, 2024

Fixes #9882 and #9691

In 2.0, we would accept data coming back from an update operation and then reflect those changes in UI.

However, in 3.0, we did not do that anymore - meaning you could change a document with hooks in beforeChange or afterChange, but then not see the changes made on the server.

This PR updates the way that mergeServerFormState works, and adds a property to optionally allow values from server form state - which can then be used in the onSuccess form handler which may need to define new field values.

@jacobsfletch jacobsfletch changed the title fix: properly reflects hook changes in ui fix(ui): properly reflects hook changes in ui Jan 2, 2025
@jmikrut jmikrut merged commit 3ea1d39 into main Jan 3, 2025
70 checks passed
@jmikrut jmikrut deleted the fix/accept-hook-changes-in-ui branch January 3, 2025 19:55
Copy link
Contributor

github-actions bot commented Jan 7, 2025

🚀 This is included in version v3.15.0

@franciscolourenco
Copy link
Contributor

Also fixed #10039 🙏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Payload requires page refresh on BeforeChange hook
3 participants