fix(marketing): header logo iPhone clipping + use shared SVG asset#4
Merged
Conversation
- Logo.astro imports the existing pywire-mark.svg as an Astro SVG component instead of duplicating the path inline. Single source of truth; SVG still inlined into HTML at build (currentColor theming preserved). - Glyph viewBox widened from "37 47 133 191" to "35 41 138 202": path coords reach y~43, y~239, x~170.66 — the old viewBox subpixel-clipped the top and bottom of the P on Mobile Safari. - .logo-mark CSS sizing changed to width/height 100% so iOS Safari has explicit dimensions to render against (the old auto+100% combo was unreliable on iOS without explicit width/height attrs on the SVG).
Deploying pywire-landing with
|
| Latest commit: |
e938c46
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://87cc06d2.pywire-landing.pages.dev |
| Branch Preview URL: | https://nightly.pywire-landing.pages.dev |
…s accent
The shared SVG carried a hardcoded color="#1d3df0" attribute, which
sets the element's own currentColor and overrode the parent CSS
.logo-mark { color: var(--accent-color) }. Result: the P glyph rendered
in blue instead of the cyan accent. The previous inline copy didn't have
this attr, so the regression only landed when the component switched to
importing the shared file.
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
Logo.astronow imports the existingsrc/assets/img/pywire-mark.svgas an Astro SVG component instead of inlining the path again. Single source of truth; the SVG is still inlined into HTML at build time socurrentColortheming on Void/Lab keeps working.viewBoxwidened from37 47 133 191to35 41 138 202. Path coords actually reach y≈43, y≈239, x≈170.66 — the old viewBox subpixel-clipped the top/bottom of the P on Mobile Safari (the bug shown on iPhone vs. desktop)..logo-markCSS switched fromwidth: auto; height: 100%towidth: 100%; height: 100%. The SVG also carries explicitwidth/heightattrs now, which iOS Safari needs to compute intrinsic sizing reliably for non-square viewBoxes.Test plan
pnpm exec prettier --check src/components/Logo.astro— cleanpnpm exec eslint .— cleanpnpm exec astro build— 134 pages built; outputdist/index.htmlcontains<svg ... viewBox="35 41 138 202" ...>