-
Notifications
You must be signed in to change notification settings - Fork 8
Open
Description
Given the following code
class CodeInput extends StatelessWidget {
final codeControl = InputCodeControl(
inputRegex: '^[0-9]',
);
final Function onDone;
CodeInput({this.onDone}) {
codeControl.done(_executeDone);
}
void _executeDone() {
onDone(codeControl.value);
}
@override
Widget build(BuildContext context) {
final h5 = Theme.of(context).textTheme.headline5;
final textTheme = h5.copyWith(
color: kTextColor,
);
return InputCodeField(
autofocus: true,
control: codeControl,
count: 4,
spacing: 16,
decoration: InputCodeDecoration(
width: 74,
height: 48,
box: BoxDecoration(
color: Colors.black.withOpacity(0.04),
border: const Border(
bottom: BorderSide(color: Colors.grey),
),
),
focusedBox: BoxDecoration(
color: Colors.black.withOpacity(0.04),
border: const Border(
bottom: BorderSide(color: kPrimaryColor),
),
),
textStyle: textTheme,
),
);
}
}Generating the following UI (part of it)

I'm not able to delete the 1st entered digit, the number 1 as seen in the screenshot.
Expected: I should be able to delete all of the entered digits by either pressing backspace or manually selecting the input.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels