r/reactnative • u/DJYEEZYWORLDPEACE • Jul 12 '22
I recreated the magnifying glass effect in React Native
21
1
u/hafi51 Jul 13 '22
expo or cli?
1
6
u/Sphism Jul 12 '22
That effect was always called a tsunami, until that big tsunami in Thailand in 2004.
2
2
2
2
2
3
u/beleg_cuth Jul 12 '22
That's pretty cool! Is the code available or how did you do it? The animation is spot on
1
1
u/KyleG Jul 13 '22
Which gesture did you settle on for clicking the expanded icon since your finger is already on the screen to do the drag?
1
u/benjamineruvieru Jul 13 '22
How did you do the video mockup. I have apps I want to show off but I don't know how to do beautiful mock ups like this
1
Aug 23 '22
Hey - looks great! A question regarding implementation detail: Using PanGestureHandler, how do you come to know what has the current selection? The way I'm doing this currently is quite intensive on the JS thread. I have an onLayout function which just stores the position of elements and onActive method of useAnimatedGestureHandler, I run a for loop to check the position which does not scale very well. Any insight would be really helpful! :)
1
-8
u/DJYEEZYWORLDPEACE Jul 12 '22
Follow me on Twitter
2
u/stathisntonas Jul 13 '22
Follow you for what? This has been posted in the past, no source code, just flexing on something useless.
11
18
u/Andrea-Pirlo Jul 12 '22
How does it work in “real life”? ie. On a phone where people don’t use a mouse and use their thumbs to navigate/tap and there’s no such thing as “hover”?
It’s a cool animation, I just can’t see a practical application after a quick look at it at 1am.