1

keypress is not get triggered on an overlay, after clicking on the overlay it works. Is there a way to trigger keypress without clicking on the overlay.

ashwintastic
  • 2,262
  • 3
  • 22
  • 49

1 Answers1

0

You need to have focus on the overlay or set the keylistneer closer to the body element.

Just set focus using yourElwment.focus() and it should work.

JGoodgive
  • 1,068
  • 10
  • 20