Repository navigation
fix(website): no sideways scroll on phones; the demo is the phone hero action - #60
Merged
Merged
Conversation
…o action Two phone points from #50; the icon part is in #59. Overflow: the hero mockup is width: 320px in content-box, so with its padding and border it is 354px, and the single 1fr hero track grew to fit it. At 375px that put the page 3px past the viewport. Under the 768px breakpoint the track is now minmax(0, 1fr) and the mockup is border-box with max-width: 100%. Desktop is unchanged. Hero action: a phone cannot install the extension, but it can use the web demo. A "Check a site" link to #try now takes the install button's place in the hero under 768px. It starts hidden and demo.js unhides it together with the demo section, so if data-api is ever empty, phones get the install button back. It carries a demo-link Umami event with placement hero, like the store links. Closes #50 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This branch was successfully deployed
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.
Closes #50. #59 covers the icon part of that issue; this PR covers the two phone points.
Horizontal overflow at 375 px
The hero mockup (
.extension-mockup) iswidth: 320pxin content-box, so with its padding and border it takes 354 px. On phones the hero is one1frgrid track, and a1frtrack never shrinks below its widest item, so the track grew to 354 px and the page ended 3 px past a 375 px viewport.Under the existing 768 px breakpoint:
.herousesminmax(0, 1fr), so the track stays inside the page..extension-mockupgetsbox-sizing: border-box; max-width: 100%, so the mockup stays inside the track (320 px at 375 px, narrower on smaller screens).No new spacing or colour values. Desktop is unchanged: the mockup is still 354 px there.
The first phone action is the demo
A phone cannot install a Chrome extension, but it can use the web demo. Under 768 px the hero now shows a Check a site link to
#trywhere the Install BotLens button was. On desktop nothing changes: the link is hidden and the install button is the hero's action.How it works:
hidden.demo.jsunhides it in the same place it unhides the#trysection, so it shows only when the demo is on.data-apiis ever emptied, the demo and the link stay hidden and phones get the install button back.btn-herostyle and ademo-linkUmami event withplacement: hero, like the store links, so phone use of it can be seen.Design choices for you to judge:
#try; the sticky navbar covers the section's small "Try it" label, but the heading and the form are in view. The site's other anchors behave the same way.Checked
In a local browser (
python3 -m http.serveronwebsite/):scrollWidthequalsclientWidth(375), no element past the right edge; the first hero action is "Check a site", and it lands on the demo form.hidden(demo off) at 375 px: the install button shows.privacy.htmlat 375 px: no horizontal scroll.npm run lint,npm test(79 pass) andnpm run check:faqpass.🤖 Generated with Claude Code