[Webkeybinds] Don't override browser keybinds (#2792)
This commit is contained in:
parent
9cada9ad13
commit
904022a2f7
1 changed files with 6 additions and 4 deletions
|
@ -35,6 +35,7 @@ export default definePlugin({
|
||||||
if (hasCtrl) switch (e.key) {
|
if (hasCtrl) switch (e.key) {
|
||||||
case "t":
|
case "t":
|
||||||
case "T":
|
case "T":
|
||||||
|
if (!IS_VESKTOP) return;
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
if (e.shiftKey) {
|
if (e.shiftKey) {
|
||||||
if (SelectedGuildStore.getGuildId()) NavigationRouter.transitionToGuild("@me");
|
if (SelectedGuildStore.getGuildId()) NavigationRouter.transitionToGuild("@me");
|
||||||
|
@ -47,14 +48,15 @@ export default definePlugin({
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
case "Tab":
|
||||||
|
if (!IS_VESKTOP) return;
|
||||||
|
const handler = e.shiftKey ? KeyBinds.SERVER_PREV : KeyBinds.SERVER_NEXT;
|
||||||
|
handler.action(e);
|
||||||
|
break;
|
||||||
case ",":
|
case ",":
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
SettingsRouter.open("My Account");
|
SettingsRouter.open("My Account");
|
||||||
break;
|
break;
|
||||||
case "Tab":
|
|
||||||
const handler = e.shiftKey ? KeyBinds.SERVER_PREV : KeyBinds.SERVER_NEXT;
|
|
||||||
handler.action(e);
|
|
||||||
break;
|
|
||||||
default:
|
default:
|
||||||
if (e.key >= "1" && e.key <= "9") {
|
if (e.key >= "1" && e.key <= "9") {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
|
|
Loading…
Reference in a new issue