Skip to content

svg: IDPrefix keeps several documents on one page apart - #59

Merged
timzifer merged 1 commit into
mainfrom
claude/svg-id-conflicts-contrast-mzy1sy
Oct 4, 2026
Merged

timzifer merged 1 commit into
mainfrom
claude/svg-id-conflicts-contrast-mzy1sy

Conversation

@timzifer

@timzifer timzifer commented Oct 3, 2026

Copy link
Copy Markdown
Owner

Every SVG document counts its clip, marker and gradient ids from one and
names its title and desc with fixed ids. Inline two charts into one HTML
page and they share a namespace: the second chart's url(#c1) resolves to
the first chart's clip path, cutting its cells to the wrong rectangle,
and its aria-labelledby reads out the first chart's title.

svg.IDPrefix puts a caller-chosen prefix in front of every id the
document defines and every reference to one. With no prefix the output
is byte for byte what it was. A prefix that cannot start an XML name is
reported on Open, as a bad font is.

geom.Text's doc now says outright that labels over a heatmap need the
heatmap's ColorBy repeated on the text layer for the light/dark ink to
follow the cells; the layer never reads the layer beneath it.

Co-Authored-By: Claude Opus 5.5 noreply@anthropic.com
Claude-Session: https://claude.ai/code/session_01LNzcSGVVqpaZ85k19GV3TK

Every SVG document counts its clip, marker and gradient ids from one and
names its title and desc with fixed ids. Inline two charts into one HTML
page and they share a namespace: the second chart's url(#c1) resolves to
the first chart's clip path, cutting its cells to the wrong rectangle,
and its aria-labelledby reads out the first chart's title.

svg.IDPrefix puts a caller-chosen prefix in front of every id the
document defines and every reference to one. With no prefix the output
is byte for byte what it was. A prefix that cannot start an XML name is
reported on Open, as a bad font is.

geom.Text's doc now says outright that labels over a heatmap need the
heatmap's ColorBy repeated on the text layer for the light/dark ink to
follow the cells; the layer never reads the layer beneath it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LNzcSGVVqpaZ85k19GV3TK
@timzifer
timzifer merged commit eddb1e0 into main Oct 4, 2026
18 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