hotkey

Trigger an action on an element with a keyboard shortcut.

MIT License

Downloads
169.9K
Stars
3.2K
Committers
18

Bot releases are visible (Hide)

hotkey - v3.1.1 Latest Release

Published by dgreif 6 months ago

What's Changed

New Contributors

Full Changelog: https://github.com/github/hotkey/compare/v3.1.0...v3.1.1

hotkey - v3.1.0

Published by iansan5653 10 months ago

What's Changed

Full Changelog: https://github.com/github/hotkey/compare/v3.0.1...v3.1.0

hotkey - v3.0.1

Published by iansan5653 11 months ago

Re-releasing v3.0.0 due to a bad workflow configuration.

hotkey - v3.0.0

Published by iansan5653 11 months ago

Breaking changes

  • When Shift is used to type an uppercase letter, Shift+ will now be included in the hotkey string (https://github.com/github/hotkey/pull/115). This means authors will need to update hotkey strings which contain capital letters to add Shift. For example, A becomes Shift+A, Mod+U because Mod+Shift+U.
  • The behavior of Mod and Meta has been made more consistent: on MacOS, when these keys are used with Shift, the resulting key name is now normalized to uppercase (https://github.com/github/hotkey/pull/116). This allows using the same Mod shortcuts on Windows, Linux, and MacOS, but may require updating some hotkey strings to use uppercase letters. For example, Meta+Shift+a becomes Meta+Shift+A, and Mod+Shift+A will work as expected across all operating systems.
hotkey - v2.3.1

Published by iansan5653 11 months ago

What's Changed

New Contributors

Full Changelog: https://github.com/github/hotkey/compare/v2.3.0...v2.3.1

hotkey - v2.3.0

Published by iansan5653 12 months ago

What's Changed

Full Changelog: https://github.com/github/hotkey/compare/v2.2.0...v2.3.0

hotkey - v2.2.0

Published by iansan5653 12 months ago

What's Changed

Full Changelog: https://github.com/github/hotkey/compare/v2.1.1...v2.2.0

hotkey - v2.1.1

Published by iansan5653 about 1 year ago

What's Changed

Full Changelog: https://github.com/github/hotkey/compare/v2.1.0...v2.1.1

hotkey - v2.1.0

Published by iansan5653 about 1 year ago

New features

Demos / docs

Other changes

New Contributors

Full Changelog: https://github.com/github/hotkey/compare/v2.0.1...v2.1.0

hotkey - v2.0.1

Published by akenneth over 2 years ago

What's Changed

New Contributors

Full Changelog: https://github.com/github/hotkey/compare/v2.0.0...v2.0.1

hotkey - v2.0.0

Published by github-actions[bot] over 2 years ago

What's Changed

New Contributors

Full Changelog: https://github.com/github/hotkey/compare/v1.6.0...v2.0.0

hotkey - v1.6.1

Published by github-actions[bot] almost 3 years ago

What's Changed

Full Changelog: https://github.com/github/hotkey/compare/v1.6.0...v1.6.1

hotkey -

Published by keithamus about 3 years ago

This release adds a hotkey-fire cancelable event which is dispatched before the hotkey is invoked (button clicks, field focussed, etc).

hotkey - v1.5.5

Published by khiga8 about 3 years ago

Before, the last registered element was always returned when multiple elements were registered with the same hotkey.

This PR changes this behavior for scoped hotkeys which were introduced in https://github.com/github/hotkey/pull/49.

When the same hotkey is registered to multiple scoped elements, we can trigger the specific element that matches the criteria.

hotkey - v.1.5.3

Published by manuelpuyol about 3 years ago

This release adds support for scoped hotkeys when the data-hotkey-scope attribute is specified.

hotkey -

Published by keithamus over 3 years ago

This fixes a regression in the eventToHotkeyString function in 1.4.3 which was caused by trying to normalise the event.key toUpperCase. The regression was because on macos the "Meta+Shift" plane is always lowercase, which is contrary to other operating systems. This is a regression because that was expected behavior as part of this package, and the fix in 1.4.3 broke this expectation while trying to fix another bug.

This change respects the event.key spacing, and elides the shift key only when the event.key matches case, returning Meta+Shift+p as a viable shortcut.

hotkey - v1.4.3

Published by keithamus over 3 years ago

This release fixes a bug with how shortcut keys get composed. Now combos like Ctrl+Shift+` should work correctly.

hotkey - v1.4.2

Published by muan over 4 years ago

  • Ensure defaultPrevented events don't trigger hotkeys
hotkey - v1.4.1

Published by muan over 4 years ago

  • Convert to TypeScript/remove Flow type support.
  • Package is now type module. UMD build is removed.
hotkey - 1.4.0

Published by dgraham over 4 years ago

  • Remove syntax transformations in module output #27
Package Rankings
Top 1.93% on Npmjs.org