Repository navigation
fix(xlsx): every copy of a dynamic array formula pasted or filled as a block spills - #36
Open
pierreneter wants to merge 1 commit into
Open
pierreneter wants to merge 1 commit into
pierreneter wants to merge 1 commit into
Conversation
…a block spills (#35) A copied block repeated into a larger selection, or by the fill handle, rebuilt the later copies' cells without the flag that marks a dynamic array formula: only the first copy spilled. The copies are now made by one helper that moves the formula and keeps the rest of the copied cell as it was. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Fixes #35.
When the viewer repeats a copied block into a larger selection (tiled paste) or with the fill handle, it moved the formula of each later copy and rebuilt the copied cell with four fields, dropping the fifth: the flag that marks a dynamic array formula. Only the first copy, which reuses the original tuple, spilled.
Both paths now build the later copies with one helper,
shiftedClipinsrc/core/xlsx/clip.ts, which moves the formula and keeps the rest of the copied cell, the flag with it.Tests:
e2e/xlsx.spec.ts: the issue's reproduction (one=SEQUENCE(3)cell pasted into two) and a two-cell block filled right with the fill handle; every copy spills in the viewer, the saved workbook has the spilled values andcmon each copy. Confirmed failing onmain, separately for the paste path and for the fill path.test/xlsx-dynamic.test.ts: the helper and a worker paste of a repeated block.Run in the Linux test VM (Bun 1.4.4):
bun run typecheckclean,bun test1193 pass / 0 fail,e2e/xlsx.spec.ts42 pass / 0 fail,bun run buildok.🤖 Generated with Claude Code