Class

TextFieldLabelPosition.Attached

Translates to Inside for TextField, and Cutout for OutlinedTextField.

Source set: Common
@Deprecated(
        "Use Inside for the default filled TextField behavior, or Cutout for the " +
            "default OutlinedTextField behavior."
    )
    public class Attached(
        @get:Suppress("GetterSetterNames") public val alwaysMinimize: Boolean = false,
        public val minimizedAlignment: Alignment.Horizontal = Alignment.Start,
        public val expandedAlignment: Alignment.Horizontal = Alignment.Start,
    ) : TextFieldLabelPosition()

Translates to Inside for TextField, and Cutout for OutlinedTextField.

Parameters

alwaysMinimize Whether to always keep the label of the text field minimized. If false, the label will expand to occupy the input area when the text field is unfocused and empty. If true, this allows displaying the placeholder, prefix, and suffix alongside the label when the text field is unfocused and empty.
minimizedAlignment The horizontal alignment of the label when it is minimized.
expandedAlignment The horizontal alignment of the label when it is expanded.
Jetpack Compose beyond MaterialFree components, screens and templates for apps that don’t look like Google’s. Copy them into your app, or let your coding agent add them.Browse for free

Content updated: