Skip to content

New Vite SVG logo renders incorrectly in WebKit #23588

Closed as not planned
Closed as not planned

Description

@ChisakaKanako

Describe the bug

The official Vite light and dark SVG logos can render inconsistently in WebKit when displayed at small icon sizes.

Affected official assets:

These assets were introduced by #21339.

In WebKit 27 on macOS 27, rendering either SVG at approximately 24px height can produce:

  • A soft or blurry appearance
  • Color bleeding around the lightning mark
  • Incorrect dark edges or outlines
  • Incorrect interpolation around transparent regions

Chrome 153 renders the same files correctly.

The screenshot below shows the worst-case WebKit rendering: the logo is completely incorrect. In ordinary cases, WebKit is usually not this severe, but it still appears noticeably blurrier than Chrome.

WebKit issue screenshot from the downstream VitePress report:

Vite logo WebKit rendering issue

The official SVG files contain:

  • 15 elements
  • 15 effects
  • 1 element
  • viewBox: 0 0 87 15

These filter and mask effects appear to be rasterized differently by WebKit and Chromium.

This also affects downstream consumers. VitePress documented the same issue and applied a raster fallback in vuejs/vitepress#5466.

Reproduction

https://htmlpreview.github.io/?https://gist.githubusercontent.com/ChisakaKanako/07226c8cc5558efd1ea7c64cfb553236/raw/index.html

Note: htmlpreview.github.io may occasionally fail to render the HTML. The issue can also be tested directly with the official vite-light.svg and vite-dark.svg files at approximately 24px height.

Steps to reproduce

  1. Open the reproduction URL in WebKit 27 on macOS 27.
  2. Display the official Vite light/dark SVG logos at approximately 24px height.
  3. Compare the rendering with Chrome 153 at the same size.
  4. Observe the blur, color bleeding, and incorrect edges in WebKit.

System Info

System:
  OS: macOS 27.0 (26A428)
  CPU: Apple M4
  Memory: 16 GB
  Shell: zsh 5.9

Browsers:
  WebKit: 27.0
  Chrome: 153.0.8010.53

Used Package Manager

npm

Logs

Official Vite logo SVG structure:

  • filters: 15
  • feGaussianBlur: 15
  • masks: 1
  • viewBox: 0 0 87 15

Downstream workaround and screenshots:
vuejs/vitepress#5466

Confirmed solution:

Alternative SVG fix:

  • Flatten or remove the Gaussian Blur filters and mask from the official SVG so it can render consistently without a raster fallback.

Validations

Activity

  1. changed the title [-]Official Vite light/dark SVG logos render incorrectly in Safari at small sizes[/-] [+]New Vite SVG logo renders incorrectly in Safari[/+] on Sep 25, 2026
  2. changed the title [-]New Vite SVG logo renders incorrectly in Safari[/-] [+]New Vite SVG logo renders incorrectly in WebKit[/+] on Sep 25, 2026
  3. neevmodh commented on Sep 26, 2026

    @neevmodh

    A fix is up in #23591.

    Fix: Replaces the filter/mask-heavy source (15 <feGaussianBlur> filters plus an alpha mask) with a single pre-rasterized PNG at 10x the viewBox resolution, embedded via <image>. This is the fallback recommended in this issue and already adopted for the same assets in vuejs/vitepress#5466. File paths, extensions, and viewBox are unchanged, so no downstream consumer needs to update anything.

    Testing: Rendered and visually compared both files before/after — the wordmark and gradient glow are preserved faithfully at the target icon size.

  4. sapphi-red commented on Sep 29, 2026

    @sapphi-red
    Member
    Image (left is Chrome 154, right is Safari 27)

    It looks fine to me. Safari looks slightly blurry, but only slightly. It doesn't look similar to the "WebKit issue screenshot from the downstream VitePress report" image you shared.

  5. ChisakaKanako commented on Sep 29, 2026

    @ChisakaKanako
    Author
    Image (left is Chrome 154, right is Safari 27)

    It looks fine to me. Safari looks slightly blurry, but only slightly. It doesn't look similar to the "WebKit issue screenshot from the downstream VitePress report" image you shared.

    Sometimes, that’s the worst rendering result, which usually happens after the window is resized. Generally, WebKit looks like this:
    image
    It’s not just a little unclear—the entire file is rendered incorrectly. I mean, both situations can trigger this issue, but for this one file, WebKit always displays rendering errors; it doesn’t handle so many SVG effects very well.

  6. sapphi-red commented on Sep 29, 2026

    @sapphi-red
    Member

    ok, I reproduced by opening https://vitepress.dev multiple times.
    Image

    It seems mask="url(#SVGgudELdDz)" part is ignored. This is definitely a bug in Safari / WebKit rather than a difference of rasterization.

  7. bluwy commented on Oct 1, 2026

    @bluwy
    Member

    I'd prefer waiting for WebKit to fix this.

  8. ChisakaKanako commented on Oct 1, 2026

    @ChisakaKanako
    Author

    Sometimes we have to accept that WebKit's support is always a step behind.

  9. TheAlexLichter commented on Oct 1, 2026

    @TheAlexLichter
    Member
  10. locked and limited conversation to collaborators on Oct 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions