Skip to main content
239

Search Lumen

Find components, APIs, guides, and recipes.

GitHub
Themes
Android docs
Data displayAndroid

Tag group

Show removable tags in a wrapping list.

Public APILumenTagGroupAndroid / Compose

Native example

Use Tag group

The host owns the tags and removes them in onRemove (value in React Native/Compose, id in SwiftUI).

Tag group rendered in the Android phone emulator Lumen playground
Captured exampleAndroid phone emulatorView dark appearance
kotlin
import androidx.compose.runtime.*
import com.santi020k.lumen.*

@Composable
fun ProjectFilters() {
    var tags by remember {
        mutableStateOf(listOf(LumenTag("design", "Design"), LumenTag("mobile", "Mobile"), LumenTag("planned", "Planned")))
    }
    LumenTagGroup(
        label = "Project filters",
        tags = tags,
        onRemove = { value -> tags = tags.filterNot { it.value == value } }
    )
}
Android
Removable project filter tags that the host removes from its own list.

Reference

Public API

The primary shared and platform-specific options exposed by LumenTagGroup.

APIValues or typeDefaultDescription
tags / onRemove / removeLabeltags / removal callback / remove button namerequired / none / Remove {label}The host owns the tags and removes them in onRemove (value in React Native/Compose, id in SwiftUI).

Native behavior

Design and accessibility

When to use it

The host owns the tags and removes them in onRemove (value in React Native/Compose, id in SwiftUI).

Accessibility

Named group; remove buttons are named, and focus moves to a remaining removable tag or the group after removal.

Shared component

Available on other platforms

React NativeApple / SwiftUI Web
Android docsCompose module