Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add initial lift translation as a prop #594

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

matt-peck
Copy link

Summary

  • Replaced -8px initial lifted value with css variable
  • Added default LIFT value using -8px
  • Added --initial-lift variable set in styles
  • Added initialLift to ToasterProps

Reason

Adding this because I noticed in latets version that on computer my mouse can trigger a loop when it hovers at the bottom of a toast container.

This will cause the toasts to expand, lift up above where mouse is hovering, lose focus, collapse, and repeat.

I wasn't exactly sure why the initial lift value was hardcoded, so rather than remove it, just added a way to set that value (in my case to 0).

Guidance

I don't contribute to a lot of OSS, so if there anything minor that's wrong with this, please feel free to let me know.

Copy link

vercel bot commented Feb 25, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
sonner ✅ Ready (Inspect) Visit Preview 💬 Add feedback Feb 25, 2025 8:26pm

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