- This project is deprecated!
- Use this instead.
An exposed dropdown menu for Jetpack Compose
Add it to your build.gradle with:
allprojects {
repositories {
maven { url "https://jitpack.io" }
}
}
and:
dependencies {
implementation 'com.github.zigellsn:exposeddropdownmenu:{latest version}'
}
and use it like this:
@Composable
fun ShowExposedDropdownMenu() {
// ...
ExposedDropdownMenu(
items = listOf("A", "B", "C"),
label = { Text(text = "Letters") },
selectedItem = { id, text ->
// Do something
}
) { text, _ ->
Text(text = text)
}
// ...
}