Repository navigation
fix(site): give inline SVG icons and brand images an intrinsic size - #81
Merged
devin-ai-integration[bot] merged 1 commit intoOct 5, 2026
Merged
Conversation
Without width/height attributes an inline <svg viewBox> stretches to the full container width, so any paint before the stylesheet applies (seen in Firefox) flashed a page-wide logo. Tailwind size classes still override the attributes once CSS loads. Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
Contributor
Author
|
I'll fix CI failures and address comments from users with write access. I'll skip comments containing "(aside)".
|
Contributor
Author
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.
Summary
On Firefox the landing briefly flashed a page-wide logo before the page appeared.
LogoMark(and the icons inicons.tsx) render<svg viewBox>with nowidth/height, so their size comes only from Tailwind classes (size-6, …). In any paint that happens before the stylesheet applies, an inline SVG with only aviewBoxstretches to the full container width, and the navbar logo fills the viewport.Fix: add presentation attributes as an unstyled fallback. CSS (
size-*) still overrides them once loaded, so the styled layout is unchanged (checked: navbar logo 24×24, icons 12–16 px, same as production).I couldn't reproduce the flash itself in Firefox 157 on Linux, including with the CSS delayed by 700 ms, because the stylesheet blocked rendering correctly there. To check the fix, I rendered the prerendered page in Firefox with CSS/JS blocked:
npm run lintandnpm run build(prerender + SEO checks) pass.Link to Devin session: https://app.devin.ai/sessions/3c4175a872684c4bb1e8fb5003e997af
Open in Devin Desktop: https://app.devin.ai/desktop/session/3c4175a872684c4bb1e8fb5003e997af?variant=devin
Requested by: @Villoh