SimpleTextField
A PCI-compliant simple text input component for handling generic text input.
This component provides a secure and flexible input field that can be used for any type of text input in PCI-compliant contexts. It wraps the base PCITextField with a simplified event interface while maintaining all the security features.
The component integrates with PCIFieldState for secure input management and provides events through SimpleTextFieldEvent for handling focus changes and value changes.
Features:
PCI-compliant input handling
Flexible for any text input use case
Real-time input state feedback
Customizable appearance and behavior
Example usage:
val state = rememberPCIFieldState()
SimpleTextField(
state = state,
onEvent = { event ->
when (event) {
is SimpleTextFieldEvent.OnValueChanged -> {
// Handle value change
}
is SimpleTextFieldEvent.OnFocusChanged -> {
// Handle focus change
}
}
},
textStyle = MaterialTheme.typography.bodyLarge
)Parameters
Modifier to customize the style and behavior of the field
A PCIFieldState object that manages the secure input data
Callback triggered for field events (focus changes, value changes)
Controls whether the field is interactive
Controls whether the field is editable
Composable for adding decorative elements around the text field
Text style applied to the input content
Configuration for the software keyboard
Callbacks for keyboard action events
Brush applied to customize the cursor appearance
Visual transformations applied to the input text