KPInputOTPFieldStyle

A sealed interface defining styles for the OTP (One-Time Password) input field. This interface provides different implementations for various input field styles, such as Outline and Filled, each determining the appearance based on the component's state.

Implementations of this interface use Composable functions to dynamically provide style attributes like border color, text color, background color, and tab indicator color.

Inheritors

Types

Link copied to clipboard
Link copied to clipboard

An object defining the Outline style for the OTP input field. This style typically features a border that changes color based on the focus and error states.

Functions

Link copied to clipboard

Returns the background color for the OTP input field in style based on its state.

Link copied to clipboard
abstract fun getBorderColor(enabled: Boolean, isFocused: Boolean, isError: Boolean): State<Color>

Returns the border color for the OTP input field in style based on its state.

Link copied to clipboard
abstract fun getTabIndicatorColor(enabled: Boolean, isFocused: Boolean, isError: Boolean): State<Color>

Returns the tab indicator color for the OTP input field in style based on its state. The tab indicator is typically used to show the cursor or active input position.

Link copied to clipboard

Returns the text color for the OTP input field in style based on whether it is enabled or disabled.