ibelick / motion-primitives

UI kit to make beautiful, animated interfaces, faster. Customizable. Open Source.
https://motion-primitives.com
MIT License
3k stars 96 forks source link

Create a 'Tilt' component #54

Open ibelick opened 1 month ago

ibelick commented 1 month ago

We're looking to add 'Tilt' component to motion-primitives! This component would let you add an interactive element that reacts to mouse movements by tilting in the corresponding direction.

Requirements:

Ideal Contribution:

Example Usage:

<Tilt transition={{
  type: "spring",
  stiffness: 900,
  damping: 80,
  mass: 10,
}}>
  <div className="w-[200px] h-[300px] bg-zinc-800">
    <img src="example.jpg" alt="Example" />
    <h2>Interactive Card</h2>
    <p>This card tilts as you hover over it, adding a dynamic interactive element to your UI.</p>
  </div>
</Tilt>

How to Contribute:

If you have a Twitter handle, please provide it so I can tag you in the related announcement demo tweet. You'll also be added to the Credit in the documentation page. Thank you for considering contributing to motion-primitives!

chbg commented 1 month ago

Hi, @ibelick !

Could you please assign this issue to me? I'd love to work on adding the 'Tilt' component to motion-primitives. Thanks!

ibelick commented 1 month ago

Hey @chbg, just assigned the issue to you. Thanks!

gabe-santos commented 2 weeks ago

Any updates to this? I can work on this.