TsaiPinInput constructor

const TsaiPinInput({
  1. Key? key,
  2. TextEditingController? controller,
  3. String? initialValue,
  4. int length = 4,
  5. FocusNode? focusNode,
  6. bool enabled = true,
  7. bool autofocus = false,
  8. bool isError = false,
  9. bool isSuccess = false,
  10. ValueChanged<String>? onChanged,
  11. ValueChanged<String>? onCompleted,
  12. ValueChanged<String>? onSubmitted,
  13. ValueChanged<bool>? onFocusChange,
  14. String semanticLabel = 'PIN',
})

Creates a Tsai PIN input.

Implementation

const TsaiPinInput({
  super.key,
  this.controller,
  this.initialValue,
  this.length = 4,
  this.focusNode,
  this.enabled = true,
  this.autofocus = false,
  this.isError = false,
  this.isSuccess = false,
  this.onChanged,
  this.onCompleted,
  this.onSubmitted,
  this.onFocusChange,
  this.semanticLabel = 'PIN',
}) : assert(controller == null || initialValue == null),
     assert(length > 0),
     assert(!isError || !isSuccess);