Releases: sindresorhus/KeyboardShortcuts
Releases · sindresorhus/KeyboardShortcuts
v1.6.0
- The previous version introduced a
.on()
method. This method has been renamed to.events()
to better reflect Apple's naming of async stream APIs. An automatic "fix-it" is included. 8a2cc91 - Added
View#onKeyboardShortcut()
method to make it nicer to listen to keyboard shortcut events in SwiftUI. 8a2cc91#diff-02bed2a7d5a7f8e2e4644c05f55d36c4c037107a949ef792d8405460f4d0ee3cR1-R38 - Update localization zh-TW to align with Apple's ee60fcf
v1.5.0
- Add support for specifying a label in
KeyboardShortcuts.Recorder
7e251f3- This means you no longer need to wrap it in a
HStack
yourself.
- This means you no longer need to wrap it in a
- Add modern
AsyncStream
-based key listener method 0dcedd5- The benefit of this one over
onKeyUp()
is that you can control its lifecycle. When you cancel the stream, the listening ends.
- The benefit of this one over
- Add Czech localization 954285d
v1.4.0
- Add Hungarian localization
- Add Spanish localization
v1.3.0
- Add Chinese (Traditional, Taiwan) localization 32aef04
v1.2.1
- Don't allow “shift” key without other modifiers or function key 7030a2e
v1.2.0
v1.1.0
- Add Russian localization
v1.0.0
Breaking
- Drop support for CocoaPods and Carthage.
It turned out to be too much of a hassle to support these while also supporting localization. If you use CocoaPods or Carthage, there's nothing stopping you from continuing using CocoaPods/Carthage for other packages while using Swift Package Manager for this package. See install instructions in the readme.
Improvements
- This package is now considered stable.
- Support for localization. 7535969
Currently, only English and Chinese, but pull request welcome for more.