Product Promotion
0x5a.live
for different kinds of informations and explorations.
GitHub - bonyadmitr/KeyboardHideManager: Codeless manager to hide keyboard by tapping on views for iOS written in Swift
Codeless manager to hide keyboard by tapping on views for iOS written in Swift - bonyadmitr/KeyboardHideManager
Visit SiteGitHub - bonyadmitr/KeyboardHideManager: Codeless manager to hide keyboard by tapping on views for iOS written in Swift
Codeless manager to hide keyboard by tapping on views for iOS written in Swift - bonyadmitr/KeyboardHideManager
Powered by 0x5a.live 💗
KeyboardHideManager
KeyboardHideManager - codeless manager to hide keyboard by tapping on views for iOS written in Swift.
Structure
- Features
- Requirements
- Installation
- Usage
- User Iteraction Enabled
- Code usage
- Xib support
- To do
- License
Features
- 3 simple actions to setup
- Multiple views setup
- Codeless usage
- Xib support
Requirements
- Swift 5.0+
- iOS 12.0+
Installation
CocoaPods
pod 'KeyboardHideManager', '~> 1.0'
CocoaPods is a dependency manager for Cocoa projects. You can install it with the following command:
$ gem install cocoapods
To integrate KeyboardHideManager into your Xcode project using CocoaPods, create file Podfile
with content:
use_frameworks!
target '<Your Target Name>' do
pod 'KeyboardHideManager', '~> 1.0'
end
Then, run the following command:
$ pod install
Close 'Your Target Name'.xcodeproj and open 'Your Target Name'.xcworkspace.
Carthage (not supported)
KeyboardHideManager cannot be used with Carthage in IB due .framework
issue. Use CocoaPods or Manual install.
Manually
If you prefer not to use either of the aforementioned dependency managers, you can integrate KeyboardHideManager into your project manually.
Drag KeyboardHideManager
folder in your project.
Usage
-
- Drag Object from Object library
-
- Setup
KeyboardHideManager
in Class field
- Setup
-
- Connect views with
targets
- Connect views with
User Iteraction Enabled
Target must be UIView
subclass and user iteraction enabled
is on. You can set it in IB in View section: (example for UILabel)
or in code:
someView.isUserInteractionEnabled = true
Xib support
To use with xib you must add strong property to controller:
@IBOutlet var keyboardHideManager: KeyboardHideManager!
Otherwise it will be deinited. It is logic of Objects in xibs.
To do
- Add example
- Add tests
- Add comments
- Add CI
License
KeyboardHideManager is released under the MIT license. See LICENSE for details.
Swift Resources
are all listed below.
Made with ❤️
to provide different kinds of informations and resources.