Swiftpack.co - Package - alphatroya/KeyboardManager

Keyboard Manager

Swift 5.0+ Run tests codebeat badge Documentation

Simple wrap up for UIKeyboardNotification events

Usage

The framework introduce a KeyboardManager class with eventClosure property what receive parsed UIKeyboardNotification user data values

let keyboardManager = KeyboardManager(notificationCenter: NotificationCenter.default)
keyboardManager.eventClosure = { event in
    if case let .willShow(data) = event {
        // process KeyboardManager.Data struct
    }
}

There is also a helper method bindToKeyboardNotifications(scrollView: UIScrollView) which simplify inset adjustment after keyboard appear/disappear

Installation

Swift Package Manager (required Xcode 11)

  1. Select File > Swift Packages > Add Package Dependency. Enter https://github.com/alphatroya/KeyboardManager in the "Choose Package Repository" dialog.
  2. In the next page, specify the version resolving rule as "Up to Next Major" with "1.4.0" as its earliest version.
  3. After Xcode checking out the source and resolving the version, you can choose the "KeyboardManager" library and add it to your app target.

Author

Alexey Korolev, alphatroya@gmail.com

Github

link
Stars: 0

Dependencies

Used By

Total: 0

Releases

1.6.0 - 2020-09-28 08:45:29

Remove Carthage support

- 2020-05-05 12:27:30

Changes

  • Adjust scroll indicator insets during scroll view bindings #43

- 2019-10-03 07:28:22

- 2019-09-28 12:31:10

Add SPM integration - 2019-09-28 12:16:10

- 2019-09-28 12:11:03

- 2019-07-12 10:55:47

- 2019-07-10 09:22:05

- 2018-06-26 12:13:16

Swift 4 support - 2017-10-01 15:01:23

Small accessibility fix - 2017-05-12 06:30:02

Resolved #9

See build details and artifacts at buddybuild: https://dashboard.buddybuild.com/apps/5880bf02640dd40100eb3717/build/59155a1714bad90001acd82c

Initial release - 2017-04-15 09:52:07

See build details and artifacts at buddybuild: https://dashboard.buddybuild.com/apps/5880bf02640dd40100eb3717/build/58f243055e69580001de2ab4