aut

AutoKeyboard

Automatic Keyboard handling for iOS written in Swift

Showing:

Popularity

Downloads/wk

0

GitHub Stars

56

Maintenance

Last Commit

2mos ago

Contributors

1

Package

Dependencies

0

License

MIT

Categories

Readme

AutoKeyboard for iOS written in Swift

Automatic Keyboard handling with ease. It is fully automatic keyboard handling. Like in android no need to resize views when keyboard appears. It updates constraints which are bounded with bottomLayoutGuide or safeAreaLayoutGuide. Like bottomLayoutGuide or safeAreaLayoutGuide moves UP and DOWN with keyboard. Just need to register and unResgister thats it.

alt tag

Features

  • safeAreaLayoutGuide suppord added.
  • UITabBarController support added.
  • UIViewController extension, no need to extend classes.
  • Device rotation supported.
  • Multiple UIViewController support.
  • Extremely easy integration.
  • Automatic bottom constraints changes with keyboard
  • Resizing with animation.
  • No need to write extra code.
  • Just registerAutoKeyboard and unRegisterAutoKeyboard .
  • Callback support on keyboard willShow, didShow, willHide, didHide, willChangeFrame, didChangeFrame.
  • Example for keeping scroll position of scrollView
  • Ability to Register or Disable other constraints

Runtime Requirements

  • iOS8.0 or later
  • Xcode 8.0 - Swift 3.0 or later

Usage

Basic Usage

Alt text

  • Add constrainsts to bottomLayoutGuide or safeAreaLayoutGuide and they will update when keyboard appears.
  • And Register your specific ViewController, you should also unregister.
override func viewWillAppear(_ animated: Bool) {
registerAutoKeyboard()
}

override func viewWillDisappear(_ animated: Bool) {
unRegisterAutoKeyboard()
}

Advanced Usage

registerAutoKeyboard(enable: [lblBottom], disable: [btnShowScrollBottom]) { (result) in
print("keyboard status \(result.status)")

switch result.status {
case .willShow:
// ...
case .didShow:
// ...
case .willHide:
// ...
case .didHide:
// ...
}
}

If you have custom tabbar, return the height

extension ViewController: AutoKeyboardOptions {
    var customTabbarExtraHeight: CGFloat { 50 }
}

Installing

CocoaPods

To integrate AutoKeyboard into your Xcode project using CocoaPods, specify it in your Podfile and run pod install.

platform :ios, '8.0'
use_frameworks!
pod 'AutoKeyboard'                 // for swift 5.0
pod 'AutoKeyboard', '~> 1.4.3'     // for swift 4.2

And import AutoKeyboard

Carthage

Coming soon

Contributing

Contributions are always welcome!

License

This project is licensed under the MIT License - see the LICENSE.md file for details

Acknowledgments

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100
No reviews found
Be the first to rate

Alternatives

No alternatives found

Tutorials

No tutorials found
Add a tutorial