Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

'+' not working #270

Open
grant-davidson opened this issue Mar 29, 2021 · 3 comments
Open

'+' not working #270

grant-davidson opened this issue Mar 29, 2021 · 3 comments

Comments

@grant-davidson
Copy link

grant-davidson commented Mar 29, 2021

The documentation shows how to monitor the '+' key:

hotkeys('+', { splitKey: '-' }, function(e){ console.log('you pressed +'); })

but this doesn't seem to work.

https://codepen.io/grantnz/pen/abpmGjz

@oliverh-cf
Copy link

I was able to get this to work by using '=' instead of '+'.

hotkeys("=", function(e) {
  // do something
});

@JohannesKlauss
Copy link

I second that. I have this example where the '+' key doesn't work:

hotkeys("ctrl-a", { splitKey: "-" }, () => alert("This works"));
hotkeys("ctrl-+", { splitKey: "-" }, () => alert("This doesn't work"));

Codesandbox: https://codesandbox.io/s/recursing-sky-4myhh?file=/src/index.js

@maperz
Copy link

maperz commented Jun 4, 2022

Hello! Is there any update on this or a general recommendation / workaround to get CRTL <splitkey> + to work? I am working on an application that relies on zooming controls via Ctrl +/-.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants