← Compose Multiplatform Component in Compose Foundation
ContextMenuDataProvider
Desktop
Adds items to the hierarchy of context menu items. Can be used, for example, to customize context menu of text fields.
Last updated:
Installation
dependencies {
implementation("androidx.compose.foundation:foundation:1.7.0-beta04")
}
Overloads
@Composable
fun ContextMenuDataProvider(
items: () -> List<ContextMenuItem>,
content: @Composable () -> Unit
)
Parameters
name | description |
---|---|
items | List of context menu items. Final context menu contains all items from descendant [ContextMenuArea] and [ContextMenuDataProvider]. |
content | The content of the [ContextMenuDataProvider]. |