CreoleTextField 0.1.1

CreoleTextField 0.1.1

TestsTested
LangLanguage SwiftSwift
License MIT
ReleasedLast Release Jun 2017
SwiftSwift Version 3.0
SPMSupports SPM

Maintained by Nirmalsinh Rathod.



  • By
  • NirmalsinhRathod

CreoleTextField

Example

To run the example project, clone the repo, and run pod install from the Example directory first.

Requirements

Swift 3.0 iOS 10 and above

Description

CreoleTextfield is a textfield object which manage to do automatically validation based of type which you have select.

Supported Textfield Type:
1.None
2.Email
3.Password
4.PhoneNumber
5.Postal code
6.Date of birth

Manual Installation

If you don’t want use pod, then you can drag CreoleTextField file into your project and directly use it. Here is Swift Code:

   let yourTextField = CreoleTextField.init(frame: CGRect.init(x: X, y: Y, width: WIDTH, height: HEIGHT))
   yourTextField.TextfieldType = CreoleTextFieldType.email.rawValue// set textfield type like email, none,password,dateofbirth,phone,postalcode
   yourTextField.maxLength = YOUR_MAX_LENGHT 
   yourTextField.setTextFieldView()
   yourTextField.delegateObj = self
   
   //Here is delegate method for CreoleTextField

   extension yourControllername:CreoleTextFieldDelegate{
     func textFieldDidBeginEditing(_ textField: CreoleTextField){
     }
     func textFieldShouldEndEditing(_ textField: CreoleTextField) -> Bool{
            return true
     }
     func textFieldDidEndEditing(_ textField: CreoleTextField){
     }
     func textField(_ textField: CreoleTextField, shouldChangeCharactersIn range: NSRange, replacementString string: String) ->Bool{
           return true
     }
    }

Installation

CreoleTextField is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod "CreoleTextField"

Author

Nirmalsinh Rathod, [email protected] www.creolestudios.com

License

CreoleTextField is available under the MIT license. See the LICENSE file for more info.