androidx.compose.foundation.text.input
TextObfuscationMode
Value class · from org.jetbrains.compose.foundation:foundation:1.12.2
No hand-written docs yet.
Defines how the text will be obscured in secure text fields.
value class TextObfuscationMode
Used by
Parameters that take a TextObfuscationMode.
BasicSecureTextField(textObfuscationMode)OutlinedSecureTextField(textObfuscationMode)SecureTextField(textObfuscationMode)
Properties
Visible
val Visible: TextObfuscationMode
Do not obscure any content, making all the content visible.
RevealLastTyped
val RevealLastTyped: TextObfuscationMode
Reveals the last typed character for a short amount of time.
Hidden
val Hidden: TextObfuscationMode
All characters are hidden.
SystemSince 1.12
val System: TextObfuscationMode
Gives the choice to the platform to hide or show characters.
value
val value: Int
Library docs
Defines how the text will be obscured in secure text fields.
Text obscuring refers to replacing the original text content with a mask via various methods. It is most common in password fields.
Users are generally accustomed to different default experiences for secure text input on various platforms. On desktop, the convention is to keep the input entirely hidden. Conversely, mobile platforms typically offer a brief reveal of the last typed character. This reveal lasts for a short duration or until another character is entered, aiding users in tracking their input while maintaining privacy by not exposing too much information.