Type InputOTPCommand

type InputOTPCommand uint8

InputOTPCommand is a request for the caller-owned one-time-code editor. Printable text and IME input continue through the platform text service.

Constants

const (
	InputOTPCommandNone InputOTPCommand = iota
	InputOTPCommandMovePrevious
	InputOTPCommandMoveNext
	InputOTPCommandMoveFirst
	InputOTPCommandMoveLast
	InputOTPCommandDeleteBackward
	InputOTPCommandDeleteForward
)

Constructors

InputOTPCommandForKey#

func InputOTPCommandForKey(snapshot InputOTPSnapshot, key ui.Key) (InputOTPCommand, bool)

InputOTPCommandForKey maps normalized non-text keys to editor requests. It deliberately does not synthesize digits, paste, selection extension, or IME.