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.
Asked
Active
Viewed 108 times
0
ashwintastic
- 2,053
- 3
- 18
- 45
-
post your code please – messerbill Jan 18 '18 at 11:04
-
your question is the answer to your question. – Muhammad Omer Aslam Jan 18 '18 at 22:06
1 Answers
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,002
- 9
- 19