Repository navigation
Conversation
edalzell
force-pushed
the
fix/bard-sync-set-values-in-place
branch
2 times, most recently
from
October 21, 2026 03:00
7100784 to
864a5ad
Compare
edalzell
force-pushed
the
fix/bard-sync-set-values-in-place
branch
from
October 21, 2026 03:00
864a5ad to
112a410
Compare
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When Bard's
valuechanges after a save, the editor was rebuilt withclearContent+setContentunless it was focused and only set values differed. The rebuild destroys every set NodeView, so nested fields lose their state, e.g. a Replicator withcollapse: trueinside a set re-readsmeta.collapsed(which the save response resets) and an expanded set snaps shut. Reproduced by adding a Replicator row inside a Bard set and clicking Save.Two kinds of diff now avoid the rebuild. Set-value-only differences (the response hands values back with keys reordered) are skipped regardless of focus, since sets already sync their own values into the editor. With
remove_empty_nodesthe response also lacks the empty paragraphs the editor still holds, so those are deleted in place with a transaction (mirroringBard::removeEmptyNodes()), keeping a text selection so a set doesn't get node-selected and have its NodeView recreated by the decoration change.Anything else still rebuilds, which keeps the #15440 fix. Persisting single-set collapse state to meta is #15688.
References #15687