-
Notifications
You must be signed in to change notification settings - Fork 4
Description
iam using this in my trail app. I have set it programmatically.
but when i enter the otp number the appears twice. on the first text field and in the centre .
this is my code
lazy var verificationTextField : ActivationCodeTextField = { let textFiled = ActivationCodeTextField() textFiled.maxCodeLength = 6 textFiled.minWidthTextField() textFiled.customPlaceholder = "p"; textFiled.keyboardType = UIKeyboardType.numberPad textFiled.font = UIFont.systemFont(ofSize: 20.0) textFiled.translatesAutoresizingMaskIntoConstraints = false return textFiled }()
this is how i constraints it
verificationTextField.centerXAnchor.constraint(equalTo: view.centerXAnchor).isActive = true verificationTextField.topAnchor.constraint(equalTo: verificationNote.bottomAnchor, constant: 10).isActive = true verificationTextField.widthAnchor.constraint(equalToConstant: 300).isActive = true verificationTextField.heightAnchor.constraint(equalToConstant: 40).isActive = true