react-creative-cursor icon indicating copy to clipboard operation
react-creative-cursor copied to clipboard

Adding sticky cursor and magnetic to the same element causes the element to glitch off the page

Open fantaz-st opened this issue 2 years ago • 1 comments

So i have set the code like this:

const Navbar = () => { return ( <div className={classes.navbar} data-scroll-section> <div className={classes.logo} data-cursor-magnetic> BALENCIAGA. <div className={classes.menu} data-cursor-stick='#stick-item' data-cursor-exclusion data-cursor-size='80px'> <p className={classes["button-text"]}>Menu

<div className={classes["burger-wrapper"]} id='stick-item' data-cursor-magnetic> <div className={classes.burger}> ); }; export default Navbar;

Logo has the magnetic property and is performing as it should, but the burger wrapper isn't. Cursor sticks to the burger element (spans) and if you try hovering over the burger it glitches off the page.

fantaz-st avatar Apr 09 '23 18:04 fantaz-st

Hi! please provide a demo on codesandbox.

ehsan-shv avatar Apr 10 '23 21:04 ehsan-shv