aboutsummaryrefslogtreecommitdiff
path: root/ext/js/pages/action-popup-main.js
diff options
context:
space:
mode:
authorKuuuube <61125188+Kuuuube@users.noreply.github.com>2024-05-12 21:54:45 -0400
committerGitHub <noreply@github.com>2024-05-13 01:54:45 +0000
commitfc83365f1f1163fa990d5377f9b20512594631d7 (patch)
tree97cea2c2bea60c4213840c9ad9a8299d98fb39c8 /ext/js/pages/action-popup-main.js
parentd5c28a3b3aee933a6d54ca62877a83e0505cb894 (diff)
Restore shift click behavior for search button opening as a popup (#920)
Diffstat (limited to 'ext/js/pages/action-popup-main.js')
-rw-r--r--ext/js/pages/action-popup-main.js10
1 files changed, 9 insertions, 1 deletions
diff --git a/ext/js/pages/action-popup-main.js b/ext/js/pages/action-popup-main.js
index 4125b2d1..9689e1af 100644
--- a/ext/js/pages/action-popup-main.js
+++ b/ext/js/pages/action-popup-main.js
@@ -114,7 +114,15 @@ class DisplayController {
const result = customHandler(e);
if (typeof result !== 'undefined') { return; }
}
- void this._api.commandExec(command, {mode: e.ctrlKey ? 'newTab' : 'existingOrNewTab'});
+
+ let mode = 'existingOrNewTab';
+ if (e.ctrlKey) {
+ mode = 'newTab';
+ } else if (e.shiftKey) {
+ mode = 'popup';
+ }
+
+ void this._api.commandExec(command, {mode: mode});
e.preventDefault();
};
/**