Skip to content

It is allowing more then one digits in last box #15

@ArisChoice

Description

@ArisChoice

This is my code snippet

OTPTextField(
                                  length: 4,
                                  width: MediaQuery.of(context).size.width,
                                  fieldWidth: ScreenUtil().setWidth(60),
                                  style: TextStyle(
                                    fontSize: ScreenUtil().setSp(18),
                                  ),
                                  keyboardType: TextInputType.number,
                                  textFieldAlignment:
                                      MainAxisAlignment.spaceAround,
                                  fieldStyle: FieldStyle.box,
                                  onCompleted: (pin) {
                                    print("Completed: " + pin);
                                    authController.otp.text = pin;
                                  },
                                )

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions