aboutsummaryrefslogtreecommitdiff
path: root/ext/js/app
diff options
context:
space:
mode:
authorKuuuube <61125188+Kuuuube@users.noreply.github.com>2024-06-14 12:48:09 -0400
committerGitHub <noreply@github.com>2024-06-14 16:48:09 +0000
commite4331ab90ee605e073139e20772d5ec69110ec1e (patch)
tree9cba972a9853d4b8d082873d2511285bc743118b /ext/js/app
parent25bbe3f86a16d6ebece160af435e899f0ba45e44 (diff)
Add web option to profile switching keybinds (#933)
* Add web option to profile switching keybinds * Fix spacing * Refactor * Fix comment on update * Make linter happy --------- Signed-off-by: Kuuuube <61125188+Kuuuube@users.noreply.github.com>
Diffstat (limited to 'ext/js/app')
-rw-r--r--ext/js/app/frontend.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/ext/js/app/frontend.js b/ext/js/app/frontend.js
index bdb8cfc5..71b8d6ef 100644
--- a/ext/js/app/frontend.js
+++ b/ext/js/app/frontend.js
@@ -20,6 +20,7 @@ import {createApiMap, invokeApiMapHandler} from '../core/api-map.js';
import {EventListenerCollection} from '../core/event-listener-collection.js';
import {log} from '../core/log.js';
import {promiseAnimationFrame} from '../core/promise-animation-frame.js';
+import {setProfile} from '../data/profiles-util.js';
import {addFullscreenChangeEventListener, getFullscreenElement} from '../dom/document-util.js';
import {TextSourceElement} from '../dom/text-source-element.js';
import {TextSourceGenerator} from '../dom/text-source-generator.js';
@@ -122,6 +123,8 @@ export class Frontend {
['scanSelectedText', this._onActionScanSelectedText.bind(this)],
['scanTextAtSelection', this._onActionScanTextAtSelection.bind(this)],
['scanTextAtCaret', this._onActionScanTextAtCaret.bind(this)],
+ ['profilePrevious', async () => { await setProfile(-1, this._application); }],
+ ['profileNext', async () => { await setProfile(1, this._application); }],
]);
/* eslint-enable @stylistic/no-multi-spaces */
}