Skip to content

Unicorn scroll edits improvement#3084

Merged
drfarrell merged 2 commits into
mainfrom
unicorn-scroll
Jan 21, 2026
Merged

Unicorn scroll edits improvement#3084
drfarrell merged 2 commits into
mainfrom
unicorn-scroll

Conversation

@drfarrell
Copy link
Copy Markdown
Collaborator

@drfarrell drfarrell commented Jan 21, 2026

Description

Fixes broken scrolling

Type of Change

  • Bug fix
  • New feature
  • Documentation
  • Refactor
  • Other (please describe):

Testing

Screenshots (if applicable)

Additional Notes


Important

Fixes scrolling and pointer event issues in hero section and updates global styles for improved scroll behavior.

  • Bug Fixes:
    • In index.tsx, added pointer-events-none and pointer-events-auto classes to manage pointer events in the hero section.
    • In unicorn-background.tsx, added a wheel event listener to handle scrolling while maintaining mouse interactivity.
  • Style:
    • Updated globals.css to set overscroll-behavior to none for html and body, and adjusted overflow properties for better scroll experience.

This description was created by Ellipsis for d9beee4. You can customize this summary. It will automatically update as commits are pushed.


Summary by CodeRabbit

  • Bug Fixes

    • Fixed pointer-event handling in the hero so interactive elements receive clicks/taps reliably and a mobile capture element is centered.
  • Enhancements

    • Improved background interaction by enabling wheel/scroll handling for smoother, more responsive animation scrolling.
  • Style

    • Adjusted global overflow/scrollbar behavior to provide a more consistent vertical scroll experience.

✏️ Tip: You can customize this high-level summary in your review settings.

@vercel
Copy link
Copy Markdown

vercel Bot commented Jan 21, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
web-onlook Ready Ready Preview, Comment Jan 21, 2026 10:56pm
1 Skipped Deployment
Project Deployment Review Updated (UTC)
docs-onlook Skipped Skipped Jan 21, 2026 10:56pm

Request Review

@supabase
Copy link
Copy Markdown

supabase Bot commented Jan 21, 2026

This pull request has been ignored for the connected project wowaemfasoptxrdjhilu because there are no changes detected in apps/backend/supabase directory. You can change this behaviour in Project Integrations Settings ↗︎.


Preview Branches by Supabase.
Learn more about Supabase Branching ↗︎.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Jan 21, 2026

Caution

Review failed

The pull request is closed.

📝 Walkthrough

Walkthrough

Adjusts hero-area pointer-event layering, adds a non-passive wheel listener to the unicorn background to translate wheel deltas into window scroll, and changes global CSS to allow vertical scrolling via body overflow-y.

Changes

Cohort / File(s) Summary
Hero pointer-event adjustments
apps/web/client/src/app/_components/hero/index.tsx
Adds pointer-events-none to outer container and pointer-events-auto to interactive anchor, action bar, and a centered wrapper for MobileEmailCapture to restore interaction on those elements.
Unicorn background wheel handling
apps/web/client/src/app/_components/hero/unicorn-background.tsx
Adds containerRef and a useEffect that attaches a non-passive wheel listener on the container to prevent default and manually scroll window; attaches the ref to the outer motion.div.
Global overflow behavior
apps/web/client/src/styles/globals.css
Makes html selector explicit and adds overflow-y: auto to body while keeping overflow-x: hidden, enabling vertical scrollbar behavior.

Sequence Diagram(s)

(omitted)

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

Poem

🐰 I nudged the hero to let clicks through,
I taught the unicorn to hear the wheel's cue,
Scrolls now glide where they used to hide,
With a twitch of my whiskers, the layers align—hop, slide! 🥕✨

🚥 Pre-merge checks | ✅ 1 | ❌ 2
❌ Failed checks (1 warning, 1 inconclusive)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
Title check ❓ Inconclusive The title 'Unicorn scroll edits improvement' is vague and does not clearly convey the specific fix; it uses generic phrasing that doesn't meaningfully describe the scrolling bug fix. Use a more descriptive title that clearly indicates the fix, such as 'Fix broken scrolling in Hero component by adjusting pointer events' or 'Restore scrolling functionality in Unicorn background'.
✅ Passed checks (1 passed)
Check name Status Explanation
Description check ✅ Passed The description follows the template structure with the required sections filled in, though the Testing, Screenshots, and Additional Notes sections lack details.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Fix all issues with AI agents
In `@apps/web/client/src/app/_components/hero/unicorn-background.tsx`:
- Around line 10-30: The wheel handler is causing double-scrolling because it's
added with { passive: true} so preventDefault can't be used; update the
useEffect to add the existing handleWheel listener with { passive: false } and
call e.preventDefault() at the top of the handleWheel function (referencing
handleWheel and containerRef in the useEffect) so the handler exclusively drives
scrolling, and ensure the same handleWheel function reference is removed in the
cleanup; alternatively, remove the custom handler and rely on Unicorn.Studio SDK
attributes (e.g., data-us-disablemobile) or CSS touch-action to control scroll
behavior.

Comment thread apps/web/client/src/app/_components/hero/unicorn-background.tsx
@vercel vercel Bot temporarily deployed to Preview – docs-onlook January 21, 2026 22:53 Inactive
@drfarrell drfarrell merged commit ab9333d into main Jan 21, 2026
6 of 8 checks passed
@drfarrell drfarrell deleted the unicorn-scroll branch January 21, 2026 23:01
@QweQasd123q
Copy link
Copy Markdown

QweQasd123q commented Jan 24, 2026 via email

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.

2 participants