Repository navigation
fix(chart): show cropped photos on the chart in Firefox - #36
Merged
Merged
Conversation
Firefox lays a CSS clip-path shape out inside the frame's view box, so a CROP away from the image's top left corner clipped the whole portrait away and only the initials showed. The circle is now an SVG clipPath on a group around the frame. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
In Firefox a person whose photo has a CROP away from the image's top left corner showed only initials on the chart, while the card showed the photo.
Cause: the round mask was a CSS `clip-path: circle(50%)` on the nested `` frame. Firefox lays the shape out in the frame's view box coordinates, so with a view box like `192 152 136 176` the circle missed the visible region and clipped everything. Chromium was not affected.
Fix: the circle is an SVG `` (one id per portrait) on a group around the frame. Checked by hand in Firefox on a page with both versions: the old one is empty, the new one shows the face. The photos e2e test now checks the structure.
🤖 Generated with Claude Code