0.4.2 • Published 3 months ago

makeup-key-emitter v0.4.2

Weekly downloads
64
License
MIT
Repository
-
Last release
3 months ago

makeup-key-emitter

Emits custom events for common accessibility keys (arrowRightKeyDown, escKeyDown, etc).

Experimental

This module is still in an experimental state; until it reaches v1, all minor releases must be considered as breaking changes.

Example

import KeyEmitter from "makeup-key-emitter";

let el = document.getElementById("#widget1");

KeyEmitter.addKeyDown(el);

el.addEventListener("arrowRightKeyDown", function (e) {
  console.log(this, e.type); // outputs (el1, 'arrowRightKeyDown')
});

Methods

  • addKeyDown(el)
  • addKeyUp(el)
  • removeKeyDown(el)
  • removeKeyUp(el)
  • add(el)
  • remove(el)
0.4.2

3 months ago

0.4.1

5 months ago

0.3.2

7 months ago

0.4.0

7 months ago

0.3.1

2 years ago

0.3.0

3 years ago

0.2.0

4 years ago

0.1.3

5 years ago

0.1.2

5 years ago

0.1.1

5 years ago

0.1.0

6 years ago

0.0.3

7 years ago

0.0.2

7 years ago

0.0.1

7 years ago