{% setvar book_path %}/reference/androidx/_book.yaml{% endsetvar %} {% include "_shared/_reference-head-tags.html" %}

FocusTargetModifierNode

public sealed interface FocusTargetModifierNode extends DelegatableNode


This modifier node can be used to create a modifier that makes a component focusable.

Summary

Public methods

abstract @NonNull FocusState

The FocusState associated with this FocusTargetModifierNode.

Inherited methods

From androidx.compose.ui.node.DelegatableNode
abstract @NonNull Modifier.Node

A reference of the Modifier.Node that holds this node's position in the node hierarchy.

Public methods

getFocusState

abstract @NonNull FocusState getFocusState()

The FocusState associated with this FocusTargetModifierNode. When you implement a FocusTargetModifierNode, instead of implementing FocusEventModifierNode, you can get the state by accessing this variable.