Skip to content

[6.x] Fix Bard sets picking up wrong values when splitting a list - #15701

Merged
jasonvarga merged 2 commits into
statamic:6.xfrom
o1y:6.x
Oct 22, 2026
Merged

jasonvarga merged 2 commits into
statamic:6.xfrom
o1y:6.x

Conversation

@o1y

@o1y o1y commented Oct 22, 2026

Copy link
Copy Markdown
Contributor

Pressing Enter on an empty list item in Bard (which splits the list) could copy a sets values into the set next to it.

2026-10-22 13 08 48

The cause is the 150 ms update debounce. Splitting a list moves the sets down, but the debounce keeps the stored value stale for a moment. The sets already look up their values at their new position, so a set can pick up its neighbour's values in that window. Moves like this now skip the debounce. Typing is still debounced.

To reproduce: put a list with an empty item above two sets with a paragraph between them, place the cursor in the empty item and press Enter. The first set now shows the second set's values.

Found while working on #15700. The two fixes are independent, but both add tests to the end of BardFieldtype.test.js, so whichever lands second needs a quick rebase :)

o1y and others added 2 commits October 22, 2026 12:52
# Conflicts:
#	resources/js/tests/components/fieldtypes/bard/BardFieldtype.test.js
@jasonvarga
jasonvarga merged commit 5944fec into statamic:6.x Oct 22, 2026
61 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants