Repository navigation
Conversation
A sheet's drawing part (xl/drawings/drawingN.xml) is read for its pictures and charts with their anchors: two cells, one cell and a size, or a position and a size. The new `xlsx.drawings(sheet)` call returns them; the grid lays them over the cells, placed by the row and column axes, so a picture moves and grows with resized or hidden rows and columns, and the sheet extends far enough to reach every drawing. A picture the browser can draw (PNG, JPEG, GIF, SVG, ...) is shown as itself, through the client's media URLs. A chart, and a picture in a format the browser cannot draw (EMF, WMF), is shown as a box of its size naming what is there: the chart's kind (column, bar, line, pie, ...) and title. Shapes and text boxes are left out. Clicks go through to the cells below. 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.
This shows the pictures on a spreadsheet's sheets, and puts a labeled box where a chart is. It is independent of the UI PRs (#4 to #10) and based on
main; whichever lands second needs a small rebase inXlsxView.tsx, which I'll do.A sheet's drawing part (
xl/drawings/drawingN.xml) is read for its pictures and charts with their anchors: two cells, one cell and a size, or a position and a size. The new worker callxlsx.drawings(sheet)returns them, and the grid lays them over the cells, placed by the row and column axes. So a picture moves and grows with resized or hidden rows and columns, and the sheet extends far enough to reach every drawing.A picture the browser can draw (PNG, JPEG, GIF, SVG, ...) is shown as itself, through the client's media URLs. A chart, and a picture in a format the browser cannot draw (EMF, WMF), is shown as a box of its size naming what is there: the chart's kind (column, bar, line, pie, ...) and its title. Shapes and text boxes are left out. Clicks go through to the cells below.
test/xlsx-drawings.test.tschecks that a sheet lists its pictures and charts with their anchors and leaves shapes out, and that a drawing placed by its cells moves and grows with them.bun run typecheck,bun testand the e2e suite pass in CI.A follow-up PR draws the charts themselves as SVG in place of the placeholder.
🤖 Generated with Claude Code