TestsTested | ✗ |
LangLanguage | SwiftSwift |
License | MIT |
ReleasedLast Release | Aug 2017 |
SwiftSwift Version | 3.0 |
SPMSupports SPM | ✗ |
Maintained by S.M.Moinuddin.
- change font and color of placeholder
- limit textField input
- shake animation
- zoom in/out focus animation
- character range validation
- Hoshi Effect with above feature
- closure callback of character change in textField
- closure callback of textFieldDidBeginEditing
- closure callback of textFieldDidEndEditing
- all other default features of UITextField!!!
To run the example project, clone the repo, and run pod install
from the Example directory first.
import TextFieldWrapper
yourTextField.zoomScale = 1.4 // some value > 1 for zoomIn effect.
yourTextField.addBlurToView = self.view // In which view you want to add transparent blur effect.
yourTextField.maxCharacter = 15
yourTextField.characterChangedEvent = { [weak self] (str, num) in
// your implementation
}
yourTextField.maxCharacter = 15
yourTextField.shouldTrim = false
yourTextField.characterChangedEvent = { [weak self] (str, num) in
// your implementation
}
let flag = yourTextField.isValid
yourTextField.shake()
yourTextField.shake(borderColor: .red, borderWidth: 2.0)
yourTextField.shake(borderColor: .red, borderWidth: 4, completion: {
[weak self] in
//your implementation
})
run the Example project, you will have a clean idea.
iOS 9
Swift 3
Xcode 8
TextFieldWrapper is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod "TextFieldWrapper"
S.M.Moinuddin, [email protected]
TextFieldWrapper is available under the MIT license. See the LICENSE file for more info.