Skip to content

fix: avatar mascot visible in Safari dark mode - #42

Merged
zyx1121 merged 1 commit into
mainfrom
fix/avatar-mascot-safari
Oct 7, 2026
Merged

zyx1121 merged 1 commit into
mainfrom
fix/avatar-mascot-safari

Conversation

@zyx1121

@zyx1121 zyx1121 commented Oct 7, 2026

Copy link
Copy Markdown
Member

In Safari dark mode the avatar demo showed an empty circle: Safari does not pass the system color scheme into an SVG loaded by <img>, so the prefers-color-scheme rule inside mascot.svg never switched the lines to white.

  • public/mascot.svg: fixed #0a0a0a lines, no media query
  • Avatar demo: className="dark:invert" on AvatarImage, which follows the page's .dark class

Verified on the sandbox with WebKit: /avatar shows the mascot in both dark and light.

🤖 Generated with Claude Code

Safari does not pass the system color scheme into an SVG loaded by <img>,
so the lines stayed dark on the dark page. The SVG now has fixed dark
lines and the demo inverts it with dark:invert, which follows the page.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@zyx1121
zyx1121 merged commit 077373d into main Oct 7, 2026
2 checks passed
@zyx1121
zyx1121 deleted the fix/avatar-mascot-safari branch October 7, 2026 12:14
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.

1 participant