ammarahm-ed / react-native-actions-sheet

A Cross Platform(Android, iOS & Web) ActionSheet with a flexible api, native performance and zero dependency code for react native. Create anything you want inside ActionSheet.
https://rnas.vercel.app
MIT License
1.49k stars 121 forks source link

onChange doesn't correctly report position for non-100% snap point #307

Open tibbe opened 1 year ago

tibbe commented 1 year ago

Printed out the offsetFromBottom value as indicated in https://rnas.vercel.app/guides/position and for a 55% snap point (of a total height of 600dp) it reports offset as 133dp, which isn't correct. For the 100% point it correctly reports 600dp and for the closed card it reports -449.4401072839744dp, which is also curious.

tibbe commented 1 year ago

Used the same repro case as in https://github.com/ammarahm-ed/react-native-actions-sheet/issues/306. Then I get the following offsetFromBottom numbers:

100%:  550dp
55%: 55.5dp
0%: -495.3001743516593dp

I'd say this is not working as intended. :)