Repository navigation
fix(charts): keep a chart at its drawn width in a wide column, and drop the rule over it - #464
Conversation
…op the rule over it
Codex Review Summary: ❌ FailedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
There was a problem hiding this comment.
Important
Removing the chart’s top padding makes the Copy controls cover part of a wrapped caption in a narrow column.
Approach: Removing the full-width override is the right fix for chart text scaling up; removing the top padding also changes how the chart content lines up with the Copy controls.
Reviewed changes — Reviewed all five files and traced the shared styles through the renderers.
- Chart sizing: The SVG keeps its drawn width in wide columns and shrinks proportionally in narrow ones.
- Chart frame: The figure loses its top border and padding, while charts immediately after a heading retain their reduced top margin.
- Docs and tests: The docs describe the new layout, and browser tests cover wide and narrow sizing and the absence of a border in light and dark mode.
The workspace build, all 76 chart unit and framework tests, and all seven Chromium chart tests passed. A separate Chromium check reproduced the caption overlap.
gpt-6.2-sol(high) | 𝕏
comark-annotate
comark-badge
comark-bundle
comark-cards
comark-carousel
comark-cast
comark-charts
comark-chat
comark-chips
comark-cjk
comark-code
comark-code-notes
comark-colors
comark-comments
comark-critic
comark-deflist
comark-details
comark-diagrams
comark-diff
comark-embed
comark-fields
comark-figure
comark-file-tree
comark-footnotes
comark-git-graph
comark-github
comark-icon
comark-include
comark-keys
comark-links
comark-linter
comark-magic-move
comark-mark
markdown-it-to-comark
marked-to-comark
comark-mathml
comark-media
comark-metrics
migrate-to-comark
comark-outline
comark-properties
comark-qr
comark-quiz
comark-reading-time
remark-to-comark
comark-sources
comark-steps
comark-table
comark-tabs
comark-tests
comark-time
comark-ui
comark-xref
comark-zoom
commit: |
Latest result Pull request merged. Final answersSession Pull request merged. PR #464 is ready. All hosted checks and 51 focused chart tests passed. The sole remaining finding was P2: Copy feedback can be clipped at the top of a scroll container. I resolved the thread as declined because the edge case does not warrant a standalone push. No code changed. |
There was a problem hiding this comment.
Important
The caption no longer overlaps the Copy buttons, but the new placement clips the Copy menu in right-to-left documents.
Approach: Giving the toolbar its own grid column fixes the caption overlap; the menu needs to align to the same logical edge as the toolbar.
Reviewed changes — Reviewed 37f1a42, the only commit since the prior Pullfrog review.
- Moved the Copy toolbar into a separate grid column beside the caption or standalone description, with a browser regression test for a wrapped caption and focused Copy button.
- Clarified chart sizing by distinguishing the fixed width of built-in axes charts from the width produced by a Vega-Lite spec.
The workspace build, 76 chart unit and renderer tests, and all eight Chromium chart tests passed. Separate Chromium checks reproduced the two layout regressions noted inline.
gpt-6.2-sol(high) | 𝕏
There was a problem hiding this comment.
ℹ️ No P0 or P1 findings remain; one Copy feedback edge case is noted inline.
Reviewed changes — Reviewed 5a9a2e5, the only commit since the prior Pullfrog review.
- Aligned the Copy menu to the toolbar’s logical inline edge and added a narrow RTL keyboard test.
- Moved Copy feedback out of the grid flow and added a test that verifies the wrapped caption and plot stay put during copying.
The workspace build, all 76 chart unit and renderer tests, and all 10 Chromium chart tests passed.
gpt-6.2-sol(high) | 𝕏

In a column wider than 744px, every chart over axes stretches to fill it, text and all. In Drop's widest column (80rem, 1280px) a chart's labels render about 1.7× their size, much larger than the page's text.
.cch-plot>svg{width:100%}did that.This drops that rule. A chart now shows at the width it was drawn at, and a narrower column still shrinks it to fit (
max-width:100%). Every chart over axes is drawn at 744px, so charts on one page still match each other.It also drops the 1px rule over each chart. Charts sit after paragraphs in articles, and there the rule reads as a stray
<hr>.A new e2e test puts the same chart in a 1280px and a 480px column and expects 744px and 480px. The hairline test now checks there's no border, light and dark. The charts unit tests and the charts e2e file pass in Chromium. I didn't run the full suite or the docs build.