Open frederikheld opened 2 weeks ago
I'm not able to reproduce this. Also it seems weird if #31 would actually cause this. The only thing that that PR takes care of, is making sure that the value won't be less than zero. You could easily test and verify if that's really the case for you by removing the coerceAtLeast(0)
part from within Android Studio
So maybe I had my own fix in place that now causes the overlap. I'll look into it.
But I don't seem to be the only one with the issue: https://github.com/capacitor-community/safe-area/pull/31#issuecomment-2363299936
I can't see any issue on my side. The last version that works properly for me is alpha.5. All other versions have issues with either too much or too little safe area inset bottom.
But one thing I noticed with all versions: when I open the keyboard, the bottom bar jumps up for "keyboard height + safe area inset bottom" pixels and a brief moment later jumps back to "keyboard height" (which it should be because the keyboard already covers the bottom bar). The same happens the other way round when closing the keyboard.
I assume this happens because "safe area inset bottom" takes a noticeable amount of time to be updated updated.
EDIT: in alpha.8, this behavior means, that the app bar jumps up "keyboard height" pixels but then jumps back to "keyboard height - safe are inset bottom" (as showed in the screenshots). Other from that, I feel no difference between .5 and .8 (they are both very slow in updating the values).
Describe the bug
See screenshots.
Left: app without keyboard as reference. App bar aligned with bottom of the viewport plus safe area inset bottom.
Right: open keyboard overlaps app for an amount of pixels that seems to match the safe area inset bottom (see red boxes).
I've tested this with the current
alpha-8
, but it's most probably a regression from PR #31.