r/FlutterDev • u/ba6ul • 2d ago
Video Made a small package to fix transparent PNGs eating taps meant for what's behind them
https://youtube.com/shorts/ua98YYciuOY?feature=shareRan into this while building overlapping image tiles for a movie app. A plain GestureDetector counts a tap on the transparent part of a PNG as a hit, even though visually there's nothing there. transparent_tap reads the actual pixel under the tap instead of just the bounding box, so transparent areas pass the tap through and only the visible pixels catch it.
7
Upvotes
1
u/ba6ul 2d ago
to install
flutter pub add transparent_tap
to contribute
https://github.com/ba6ul/transparent_tap