DEV Community

sandeshsapkota
sandeshsapkota

Posted on • Updated on

magnet-cursor

Inspired from this website.

Top comments (12)

Collapse
 
vlasin98 profile image
Vlasin98

Hi Sandeshsapkota!

I really appreciate your pen and the fact that you took the time to share it, really nice work.

One thing I would like to mention/ask you. From what I see you hidden the overflow on the pen, but when this gets on an actual page, the moment someone scrolls the custom cursor gets offset from the real one. Any idea how I can fix this issue?

I would like to thank you once again for the work. Let me know further.

Collapse
 
sandeshsapkota profile image
sandeshsapkota

Hello @vlasin98 !

thank you for pointing out. the only reason the custom-cursor was not moving along with the real-cursor was, I had positioned the cursor with absolute . same issue was with the like button.

I have fixed this and have updated the pen.

let me know if I missed anything.
thanks

Collapse
 
vlasin98 profile image
Vlasin98

Amazing. I was scrubbing through it for hours. It is really appreciated.

Thank you

Thread Thread
 
sandeshsapkota profile image
sandeshsapkota

glad to help you !

Thread Thread
 
vlasin98 profile image
Vlasin98

Further down the line, if you are kind enough, how can I make it work if I want multiple items to have the magnet effect?

Thank you from the bottom of my heart

Thread Thread
 
sandeshsapkota profile image
sandeshsapkota

Oh ! want to do that too ? that sounds great !
well, let me give some time to figure out. having a little bit busy time. will come up with the solution or question :)

Thread Thread
 
vlasin98 profile image
Vlasin98

Take your time. You are amazing. Wanna be my best friend? :D

On a serious note, really thankful for helping me here.

Thread Thread
 
sandeshsapkota profile image
sandeshsapkota • Edited

Hi Vlasin98! .. okay.. why not.. haha

I have updated my pen. now it works for multiple elements even it is below the viewport. please have a look at it.

and sorry for the delay.

let me know if you need anything.

Thread Thread
 
vlasin98 profile image
Vlasin98

Thank you so so much. Your approach is so simple yet the results are so extraordinary. Thank you from the bottom of my heart.

:)

Thread Thread
 
sandeshsapkota profile image
sandeshsapkota

my pleasure :)

Thread Thread
 
vlasin98 profile image
Vlasin98

Hi Sandeshsapkota. I've been using your magnetic mouse since you last provided input on it. Amazing stuff you did.

One more thing if you can maybe look into if you want and of course if you have the time.
Is there any way to make the circle that follows the cursor ease when it gets closer to the cursor?

You can see something similar in this example with the orange circle that follows the cursor
-> puntopago.net/

Thank you in advance and really appreciate your help

Thread Thread
 
sandeshsapkota profile image
sandeshsapkota

Hey Vlasin ! thanks . ohh is that your work ? it's amazing ! I will be looking into it a little later. follow me back so we can have conversation.