Skip to content

armgit / macro

Public Imported from GitHub
0

Macro is a unified workspace for teams: email, chat, docs, tasks, agents, calls, and CRM — @-linked together with shared AI memory.

feat(soup): add cmd+a hotkey to toggle select all (#2938)

gbirman54f6dc6c5e2d
diff --git a/js/app/packages/app/component/next-soup/soup-view/use-soup-view-hotkeys.ts b/js/app/packages/app/component/next-soup/soup-view/use-soup-view-hotkeys.ts
index f95741eef4..feed6a99c8 100644
--- a/js/app/packages/app/component/next-soup/soup-view/use-soup-view-hotkeys.ts
+++ b/js/app/packages/app/component/next-soup/soup-view/use-soup-view-hotkeys.ts
@@ -231,6 +231,25 @@ export const useSoupViewHotkeys = (options: UseSoupViewHotkeysOptions) => {
displayPriority: 10,
}).withGroup(group);
+ // cmd+a - Toggle select all items
+ registerHotkey({
+ hotkey: ['cmd+a'],
+ scopeId,
+ description: 'Toggle select all',
+ keyDownHandler: (e) => {
+ const items = soup.items.data();
+ if (items.length === 0) return false;
+ e?.preventDefault();
+ if (soup.selection.count() === items.length) {
+ soup.selection.clear();
+ } else {
+ soup.selection.set(items.slice());
+ }
+ return true;
+ },
+ displayPriority: 10,
+ }).withGroup(group);
+
// cmd+k - Open command menu with selection context
// When there's a selection, opens in entity action mode showing only
// selection modification commands with a preview of the selected entities