delete method

void delete()

Deletes the last character of Pinput value

Implementation

void delete() {
  if (text.isEmpty) return;
  final pin = this.text.substring(0, this.length - 1);
  this.text = pin;
  this.moveCursorToEnd();
}