Skip to content

Instantly share code, notes, and snippets.

@bronze1man
Created November 30, 2023 13:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bronze1man/7267ce413af1da4e9b67d41406610a81 to your computer and use it in GitHub Desktop.
Save bronze1man/7267ce413af1da4e9b67d41406610a81 to your computer and use it in GitHub Desktop.
Detecting if the Android keyboard is visible or hidden with @composable
@Composable
fun isSoftInputVisibleInComposable():Boolean{
@OptIn(ExperimentalLayoutApi::class)
return WindowInsets.isImeVisible
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment