Anyone else have issues with bottom sheet behavior in their apps? Specifically concerning peek height when using phones which have gesture navigation enabled?
Asked
Active
Viewed 328 times
1 Answers
2
I had the same problem in my app, I solved it with custom insets consuming( Consuming insets manually)
override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
...
ViewCompat.setOnApplyWindowInsetsListener(binding.rootView) { _, insets ->
val systemGestureInsets = insets.systemGestureInsets
WindowInsetsCompat.Builder()
.setSystemWindowInsets(insets.systemWindowInsets)
.setSystemGestureInsets(systemGestureInsets).build()
}
...
}
-
now working in android 11 – Deepanshu Namdeo Nov 24 '21 at 07:01