# A2uiComponent

Artifact: [androidx.a2ui.compose:compose-ui](https://developer.android.com/jetpack/androidx/releases/a2ui-compose) [View Source](https://cs.android.com/search?q=file:androidx/a2ui/compose/ui/A2uiComponent.kt+class:androidx.a2ui.compose.ui.A2uiComponent) Added in [1.0.0-alpha02](https://developer.android.com/jetpack/androidx/releases/a2ui-compose#1.0.0-alpha02)


```
interface A2uiComponent
```

<br />

Known direct subclasses [A2uiBasicCatalogV1.AudioPlayer](https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.AudioPlayer), [A2uiBasicCatalogV1.Button](https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Button), [A2uiBasicCatalogV1.Card](https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Card), [A2uiBasicCatalogV1.CheckBox](https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.CheckBox), [A2uiBasicCatalogV1.ChoicePicker](https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.ChoicePicker), [A2uiBasicCatalogV1.Column](https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Column), [A2uiBasicCatalogV1.DateTimeInput](https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.DateTimeInput), [A2uiBasicCatalogV1.Divider](https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Divider), [A2uiBasicCatalogV1.Icon](https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Icon), [A2uiBasicCatalogV1.Image](https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Image), [A2uiBasicCatalogV1.List](https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.List), [A2uiBasicCatalogV1.Modal](https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Modal), [A2uiBasicCatalogV1.Row](https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Row), [A2uiBasicCatalogV1.Slider](https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Slider), [A2uiBasicCatalogV1.Tabs](https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Tabs), [A2uiBasicCatalogV1.TextField](https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.TextField), [A2uiBasicCatalogV1.Text](https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Text), [A2uiBasicCatalogV1.Video](https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Video)

|---|---|
| `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.AudioPlayer` | The A2UI `"AudioPlayer"` component for playing audio content from a URL. |
| `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Button` | The A2UI `"Button"` component for clickable buttons that dispatch actions. |
| `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Card` | The A2UI `"Card"` component for displaying content in a styled container. |
| `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.CheckBox` | The A2UI `"CheckBox"` component for displaying a checkable control with an associated label. |
| `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.ChoicePicker` | The A2UI `"ChoicePicker"` component for selecting one or more options from a list. |
| `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Column` | The A2UI `"Column"` component for arranging children vertically. |
| `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.DateTimeInput` | The A2UI `"DateTimeInput"` component for selecting date and/or time. |
| `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Divider` | The A2UI `"Divider"` component for displaying a horizontal or vertical dividing line. |
| `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Icon` | The A2UI `"Icon"` component for displaying an icon. |
| `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Image` | The A2UI `"Image"` component for displaying an image from a URL. |
| `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.List` | The A2UI `"List"` component for displaying a scrollable list of components. |
| `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Modal` | The A2UI `"Modal"` component for displaying a dialog window. |
| `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Row` | The A2UI `"Row"` component for displaying content in a horizontal layout. |
| `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Slider` | The A2UI `"Slider"` component for selecting a numeric value within a range. |
| `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Tabs` | The A2UI `"Tabs"` component for displaying a set of tabs. |
| `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.TextField` | The A2UI `"TextField"` component for user text input. |
| `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Text` | The A2UI `"Text"` component for displaying text. |
| `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/catalog/A2uiBasicCatalogV1.Video` | The A2UI `"Video"` component for displaying a video from a URL. |

*** ** * ** ***

Defines the schema and Jetpack Compose rendering implementation for a single A2UI component.

Implementations of this interface bridge the gap between the A2UI protocol and Jetpack Compose UI. They declare the component's structural requirements via `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/A2uiComponent#properties()` (which are communicated to the during capability negotiation) and map the incoming `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/runtime/A2uiComponentProperties` to actual composable UI elements in `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/A2uiComponent#(androidx.a2ui.compose.runtime.A2uiComponentScope).Content(androidx.a2ui.compose.runtime.A2uiComponentProperties,androidx.compose.ui.Modifier)`.

## Summary

| ### Public functions |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `@https://developer.android.com/reference/kotlin/androidx/compose/runtime/Composable https://developer.android.com/reference/kotlin/androidx/a2ui/compose/runtime/A2uiComponentScope.https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/A2uiComponent#(androidx.a2ui.compose.runtime.A2uiComponentScope).Content(androidx.a2ui.compose.runtime.A2uiComponentProperties,androidx.compose.ui.Modifier)( properties: https://developer.android.com/reference/kotlin/androidx/a2ui/compose/runtime/A2uiComponentProperties, modifier: https://developer.android.com/reference/kotlin/androidx/compose/ui/Modifier )` Emits the UI for this component. |
| `open https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `@https://developer.android.com/reference/kotlin/androidx/compose/runtime/Composable https://developer.android.com/reference/kotlin/androidx/a2ui/compose/runtime/A2uiComponentScope.https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/A2uiComponent#(androidx.a2ui.compose.runtime.A2uiComponentScope).isReady(androidx.a2ui.compose.runtime.A2uiComponentProperties)(properties: https://developer.android.com/reference/kotlin/androidx/a2ui/compose/runtime/A2uiComponentProperties)` Determines whether this component is ready to be rendered. |

| ### Public properties |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html` | `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/A2uiComponent#description()` A semantic description of the component's behavior and purpose. |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html` | `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/A2uiComponent#name()` The unique string identifier for this component type (e.g., `"Text"`, `"Button"`). |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-list/index.html<https://developer.android.com/reference/kotlin/androidx/a2ui/compose/runtime/A2uiProperty<*>>` | `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/A2uiComponent#properties()` The list of typed properties expected by this component. |

## Public functions

### A2uiComponentScope.Content

Artifact: [androidx.a2ui.compose:compose-ui](https://developer.android.com/jetpack/androidx/releases/a2ui-compose) [View Source](https://cs.android.com/search?q=file:androidx/a2ui/compose/ui/A2uiComponent.kt+function:Content) Added in [1.0.0-alpha02](https://developer.android.com/jetpack/androidx/releases/a2ui-compose#1.0.0-alpha02)

```
@Composable
fun A2uiComponentScope.Content(
    properties: A2uiComponentProperties,
    modifier: Modifier
): Unit
```

Emits the UI for this component.

This function is invoked within the `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/runtime/A2uiComponentScope`, which provides access to extensions for evaluating reactive data bindings, rendering nested children, dispatching user actions, and reporting runtime errors.

| Parameters |
|---|---|
| `properties: https://developer.android.com/reference/kotlin/androidx/a2ui/compose/runtime/A2uiComponentProperties` | The stable properties wrapper from which to extract static payloads or bind dynamic data paths. |
| `modifier: https://developer.android.com/reference/kotlin/androidx/compose/ui/Modifier` | The `https://developer.android.com/reference/kotlin/androidx/compose/ui/Modifier` applied to the root of this component's layout. |

### A2uiComponentScope.isReady

Artifact: [androidx.a2ui.compose:compose-ui](https://developer.android.com/jetpack/androidx/releases/a2ui-compose) [View Source](https://cs.android.com/search?q=file:androidx/a2ui/compose/ui/A2uiComponent.kt+function:isReady) Added in [1.0.0-alpha02](https://developer.android.com/jetpack/androidx/releases/a2ui-compose#1.0.0-alpha02)

```
@Composable
open fun A2uiComponentScope.isReady(properties: A2uiComponentProperties): Boolean
```

Determines whether this component is ready to be rendered.

This is evaluated during component state resolution to determine if the component should transition from the `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/runtime/A2uiComponentState.Loading` state to the `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/runtime/A2uiComponentState.Success` state. The readiness is automatically re-evaluated when any reactive state read in this composable function changes (such as dynamic data bindings observed via `properties.bind(...)`).

By default, components are considered instantly ready. Override this method to support progressive rendering---for example, returning `false` until a required dynamic data binding (like an image URL or text string) has been successfully resolved from the surface's data model.

| Parameters |
|---|---|
| `properties: https://developer.android.com/reference/kotlin/androidx/a2ui/compose/runtime/A2uiComponentProperties` | The stable properties wrapper provided by the A2UI protocol. |

| Returns |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `true` if the component is fully ready to be composed, `false` if it is still loading. |

## Public properties

### description

Added in [1.0.0-alpha02](https://developer.android.com/jetpack/androidx/releases/a2ui-compose#1.0.0-alpha02)

```
val description: String
```

A semantic description of the component's behavior and purpose.

This is included in the generated schema to help the agent understand when and how it should output this component.

### name

Added in [1.0.0-alpha02](https://developer.android.com/jetpack/androidx/releases/a2ui-compose#1.0.0-alpha02)

```
val name: String
```

The unique string identifier for this component type (e.g., `"Text"`, `"Button"`).

This matches the `"component"` field in the A2UI protocol's component payloads and is used by the framework to route incoming payloads to this specific implementation.

Note: This name must be unique within an `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/ui/A2uiCatalog`.

### properties

Added in [1.0.0-alpha02](https://developer.android.com/jetpack/androidx/releases/a2ui-compose#1.0.0-alpha02)

```
val properties: List<A2uiProperty<*>>
```

The list of typed properties expected by this component.

The properties serve two purposes:

1. To automatically generate the component's JSON schema for the agent.

2. To serve as type-safe tokens for extracting payloads or resolving dynamic data bindings from `https://developer.android.com/reference/kotlin/androidx/a2ui/compose/runtime/A2uiComponentProperties` at runtime.