[Glitch] Ignore alt-key hotkeys in text fields

Port 63770d3aac to glitch-soc

Signed-off-by: Thibaut Girka <thib@sitedethib.com>
This commit is contained in:
ThibG authored and Thibaut Girka committed 2020-10-21 19:34:44 +02:00
1 parent 8071613dd7
commit f7306c7b7c
1 file changed
+1 -1
@@ -385,7 +385,7 @@ class UI extends React.Component {
componentDidMount () {
this.hotkeys.__mousetrap__.stopCallback = (e, element) => {
return ['TEXTAREA', 'SELECT', 'INPUT'].includes(element.tagName) && !e.altKey;
return ['TEXTAREA', 'SELECT', 'INPUT'].includes(element.tagName);
};
if (typeof document.hidden !== 'undefined') { // Opera 12.10 and Firefox 18 and later support