chart watermark + one-click PNG copy/download button - #1434
Merged
Conversation
…ibution + PNG export)
This was referenced Jul 25, 2026
Flotapponnier
added a commit
that referenced
this pull request
Jul 25, 2026
…rom dev (#1436) * feat: chart watermark + copy/download button (openchainbench.com attribution + PNG export) (#1434) Co-authored-by: Florent Tapponnier <contact@mobula.io> * fix pnpm-lock: sync html-to-image entries so CI frozen-lockfile install passes (#1435) Co-authored-by: Florent Tapponnier <contact@mobula.io> --------- Co-authored-by: Florent Tapponnier <contact@mobula.io>
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.
DefiLlama-style attribution + easy sharing on every chart.
Watermark
Subtle "openchainbench.com" bottom-right of the chart (opacity 0.28 → visible but never competes with data). Renders inside SVG for time-series (
<text>element) and as absolute-positioned HTML for the ranked bar chart. Survives Twitter/Slack recompression and can't be cropped out because it sits inside the chart bounds.Copy/download
Split button in the chart header (icon-only on mobile, "Copy" + download icon on desktop). Click = PNG-to-clipboard via
navigator.clipboard.write(ClipboardItem). Second half = PNG download. Retina 2x pixel ratio for legible zoomed screenshots. Fallbacks: Firefox / insecure contexts / older Safari → download flow, no error surfaced.Impl notes
chart-watermark.tsx(SVG + HTML variants) andchart-export-button.tsxhtml-to-image@1.11.13(12KB, handles SVG + HTML in one pass)openchainbench-<slug>-<range>.pngfor time-series,openchainbench-<slug>-ranking.pngfor ranked bar--color-paperbackground forced during capture so light-mode chat pastes don't get transparency artifactsTest plan
openchainbench-<slug>-<range>.png