diff --git a/KWVerificationCodeView.podspec b/KWVerificationCodeView.podspec index 7c5d160..7ac63d3 100644 --- a/KWVerificationCodeView.podspec +++ b/KWVerificationCodeView.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'KWVerificationCodeView' - s.version = '0.1.8' + s.version = '0.1.9' s.summary = 'A verification code view with validation.' s.description = 'A customisable verification code view with built in validation. Can be used for one time passwords (OTPs), email verification codes etc.' s.homepage = 'https://github.com/keepworks/kwverificationcodeview' diff --git a/KWVerificationCodeView/Classes/KWVerificationCodeView.swift b/KWVerificationCodeView/Classes/KWVerificationCodeView.swift index 80268ca..4ab23b5 100644 --- a/KWVerificationCodeView/Classes/KWVerificationCodeView.swift +++ b/KWVerificationCodeView/Classes/KWVerificationCodeView.swift @@ -167,6 +167,14 @@ public protocol KWVerificationCodeViewDelegate: class { return true } + public func clear() { + for textFieldView in textFieldViews { + textFieldView.numberTextField.text = "" + } + + textFieldViews[0].activate() + } + // MARK: - Private Methods private func setup() { loadViewFromNib()