Skip to content

fix(marketing): header logo iPhone clipping + use shared SVG asset#4

Merged
reecelikesramen merged 2 commits into
mainfrom
fix/header-logo-clipping
May 5, 2026
Merged

fix(marketing): header logo iPhone clipping + use shared SVG asset#4
reecelikesramen merged 2 commits into
mainfrom
fix/header-logo-clipping

Conversation

@reecelikesramen
Copy link
Copy Markdown
Contributor

@reecelikesramen reecelikesramen commented May 5, 2026

Summary

  • Logo.astro now imports the existing src/assets/img/pywire-mark.svg as an Astro SVG component instead of inlining the path again. Single source of truth; the SVG is still inlined into HTML at build time so currentColor theming on Void/Lab keeps working.
  • Glyph viewBox widened from 37 47 133 191 to 35 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-mark CSS switched from width: auto; height: 100% to width: 100%; height: 100%. The SVG also carries explicit width/height attrs now, which iOS Safari needs to compute intrinsic sizing reliably for non-square viewBoxes.

Test plan

  • pnpm exec prettier --check src/components/Logo.astro — clean
  • pnpm exec eslint . — clean
  • pnpm exec astro build — 134 pages built; output dist/index.html contains <svg ... viewBox="35 41 138 202" ...>
  • Smoke-test header rendering on iPhone Safari (manual)

- 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).
@cloudflare-workers-and-pages
Copy link
Copy Markdown

cloudflare-workers-and-pages Bot commented May 5, 2026

Deploying pywire-landing with  Cloudflare Pages  Cloudflare Pages

Latest commit: e938c46
Status: ✅  Deploy successful!
Preview URL: https://87cc06d2.pywire-landing.pages.dev
Branch Preview URL: https://nightly.pywire-landing.pages.dev

View logs

…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.
@reecelikesramen reecelikesramen merged commit 6fef55a into main May 5, 2026
3 checks passed
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