@blastlauncher/runtime 1.0.1 → 3.0.0-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -0
- package/dist/api/action-panel.d.ts +134 -0
- package/dist/api/action-panel.js +36 -0
- package/dist/api/action.d.ts +386 -0
- package/dist/api/action.js +260 -0
- package/dist/api/ai-browser.d.ts +423 -0
- package/dist/api/ai-browser.js +113 -0
- package/dist/api/ai-decide.d.ts +41 -0
- package/dist/api/ai-decide.js +62 -0
- package/dist/api/applications.d.ts +13 -0
- package/dist/api/applications.js +48 -0
- package/dist/api/cache.d.ts +27 -0
- package/dist/api/cache.js +126 -0
- package/dist/api/capability.d.ts +14 -0
- package/dist/api/capability.js +30 -0
- package/dist/api/clipboard.d.ts +57 -0
- package/dist/api/clipboard.js +83 -0
- package/dist/api/detail.d.ts +33 -0
- package/dist/api/detail.js +11 -0
- package/dist/api/diagnostics.d.ts +16 -0
- package/dist/api/diagnostics.js +26 -0
- package/dist/api/dropdown.d.ts +17 -0
- package/dist/api/dropdown.js +48 -0
- package/dist/api/enums.generated.d.ts +750 -0
- package/dist/api/enums.generated.js +719 -0
- package/dist/api/environment.d.ts +44 -0
- package/dist/api/environment.js +61 -0
- package/dist/api/feedback.d.ts +94 -0
- package/dist/api/feedback.js +228 -0
- package/dist/api/form.d.ts +162 -0
- package/dist/api/form.js +345 -0
- package/dist/api/grid.d.ts +293 -0
- package/dist/api/grid.js +36 -0
- package/dist/api/implemented.d.ts +53 -0
- package/dist/api/implemented.js +43 -0
- package/dist/api/index.d.ts +612 -0
- package/dist/api/index.js +82 -0
- package/dist/api/keyboard.d.ts +182 -0
- package/dist/api/keyboard.js +107 -0
- package/dist/api/launch.d.ts +40 -0
- package/dist/api/launch.js +27 -0
- package/dist/api/legacy.d.ts +9 -0
- package/dist/api/legacy.js +25 -0
- package/dist/api/list.d.ts +291 -0
- package/dist/api/list.js +28 -0
- package/dist/api/menu-bar.d.ts +54 -0
- package/dist/api/menu-bar.js +30 -0
- package/dist/api/metadata.d.ts +62 -0
- package/dist/api/metadata.js +33 -0
- package/dist/api/navigation.d.ts +36 -0
- package/dist/api/navigation.js +99 -0
- package/dist/api/oauth.d.ts +84 -0
- package/dist/api/oauth.js +125 -0
- package/dist/api/open.d.ts +18 -0
- package/dist/api/open.js +36 -0
- package/dist/api/preferences.d.ts +43 -0
- package/dist/api/preferences.js +41 -0
- package/dist/api/selection.d.ts +10 -0
- package/dist/api/selection.js +31 -0
- package/dist/api/slot.d.ts +7 -0
- package/dist/api/slot.js +11 -0
- package/dist/api/storage.d.ts +24 -0
- package/dist/api/storage.js +45 -0
- package/dist/api/types.d.ts +46 -0
- package/dist/api/types.js +5 -0
- package/dist/api/unsupported.d.ts +18 -0
- package/dist/api/unsupported.generated.d.ts +1255 -0
- package/dist/api/unsupported.generated.js +56 -0
- package/dist/api/unsupported.js +65 -0
- package/dist/api/window-management.d.ts +97 -0
- package/dist/api/window-management.js +164 -0
- package/dist/api/window.d.ts +16 -0
- package/dist/api/window.js +32 -0
- package/dist/main.d.ts +1 -0
- package/dist/main.js +339 -0
- package/dist/provider.d.ts +8 -0
- package/dist/provider.js +107 -0
- package/dist/reconciler/index.d.ts +9 -0
- package/dist/reconciler/index.js +186 -0
- package/dist/reconciler/serialize.d.ts +3 -0
- package/dist/reconciler/serialize.js +53 -0
- package/dist/reconciler/types.d.ts +8 -0
- package/dist/reconciler/types.js +1 -0
- package/package.json +32 -23
- package/.eslintrc.js +0 -6
- package/CHANGELOG.md +0 -10
- package/dist/App.d.ts +0 -5
- package/dist/App.js +0 -10
- package/dist/components/CommandList/index.d.ts +0 -1
- package/dist/components/CommandList/index.js +0 -20
- package/dist/components/CommandList/utils.d.ts +0 -1
- package/dist/components/CommandList/utils.js +0 -24
- package/dist/index.d.ts +0 -1
- package/dist/index.js +0 -11
- package/dist/utils/connectDevtools.d.ts +0 -1
- package/dist/utils/connectDevtools.js +0 -11
- package/dist/utils/run.d.ts +0 -4
- package/dist/utils/run.js +0 -12
- package/dist/utils/window.d.ts +0 -0
- package/dist/utils/window.js +0 -2
- package/src/@types/raycast.d.ts +0 -4
- package/src/@types/react-devtools-core.d.ts +0 -19
- package/src/App.tsx +0 -18
- package/src/components/CommandList/index.tsx +0 -27
- package/src/components/CommandList/utils.ts +0 -26
- package/src/index.ts +0 -13
- package/src/utils/connectDevtools.ts +0 -8
- package/src/utils/run.ts +0 -7
- package/src/utils/window.js +0 -1
- package/tsconfig.json +0 -10
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
export * from "./unsupported.generated.js";
|
|
2
|
+
export { CopyToClipboard } from "./action.js";
|
|
3
|
+
export { Image } from "./enums.generated.js";
|
|
4
|
+
import { Image } from "./enums.generated.js";
|
|
5
|
+
// Keep the stub-backed value while exposing the provider's erased type surface.
|
|
6
|
+
import { AI as aiWithStubs } from "./unsupported.generated.js";
|
|
7
|
+
export const AI = aiWithStubs;
|
|
8
|
+
// Bind aliases to the public values, which include unsupported-member proxies.
|
|
9
|
+
import { Action, ActionPanel as actionPanelWithStubs, Alert, Clipboard, Form as formWithStubs, List, LocalStorage, Toast, } from "./unsupported.generated.js";
|
|
10
|
+
// Keep aliases on public facades without mutating the underlying implementations.
|
|
11
|
+
export const ActionPanel = new Proxy(actionPanelWithStubs, {
|
|
12
|
+
get(target, key, receiver) {
|
|
13
|
+
return key === "Item" ? Action : Reflect.get(target, key, receiver);
|
|
14
|
+
},
|
|
15
|
+
});
|
|
16
|
+
const formAliases = {
|
|
17
|
+
DropdownItem: formWithStubs.Dropdown.Item,
|
|
18
|
+
DropdownSection: formWithStubs.Dropdown.Section,
|
|
19
|
+
TagPickerItem: formWithStubs.TagPicker.Item,
|
|
20
|
+
};
|
|
21
|
+
export const Form = new Proxy(formWithStubs, {
|
|
22
|
+
get(target, key, receiver) {
|
|
23
|
+
return Object.hasOwn(formAliases, key)
|
|
24
|
+
? Reflect.get(formAliases, key)
|
|
25
|
+
: Reflect.get(target, key, receiver);
|
|
26
|
+
},
|
|
27
|
+
});
|
|
28
|
+
export const ActionPanelItem = Action;
|
|
29
|
+
export const ActionPanelSection = ActionPanel.Section;
|
|
30
|
+
export const ActionPanelSubmenu = ActionPanel.Submenu;
|
|
31
|
+
export const AlertActionStyle = Alert.ActionStyle;
|
|
32
|
+
export const CopyToClipboardAction = Action.CopyToClipboard;
|
|
33
|
+
export const FormCheckbox = Form.Checkbox;
|
|
34
|
+
export const FormDatePicker = Form.DatePicker;
|
|
35
|
+
export const FormDropdown = Form.Dropdown;
|
|
36
|
+
export const FormDropdownItem = Form.Dropdown.Item;
|
|
37
|
+
export const FormDropdownSection = Form.Dropdown.Section;
|
|
38
|
+
export const FormSeparator = Form.Separator;
|
|
39
|
+
export const FormTagPicker = Form.TagPicker;
|
|
40
|
+
export const FormTagPickerItem = Form.TagPicker.Item;
|
|
41
|
+
export const FormTextArea = Form.TextArea;
|
|
42
|
+
export const FormTextField = Form.TextField;
|
|
43
|
+
export const ImageMask = Image.Mask;
|
|
44
|
+
export const ListItem = List.Item;
|
|
45
|
+
export const ListSection = List.Section;
|
|
46
|
+
export const OpenAction = Action.Open;
|
|
47
|
+
export const OpenInBrowserAction = Action.OpenInBrowser;
|
|
48
|
+
export const OpenWithAction = Action.OpenWith;
|
|
49
|
+
export const PasteAction = Action.Paste;
|
|
50
|
+
export const PushAction = Action.Push;
|
|
51
|
+
export const ShowInFinderAction = Action.ShowInFinder;
|
|
52
|
+
export const SubmitFormAction = Action.SubmitForm;
|
|
53
|
+
export const ToastStyle = Toast.Style;
|
|
54
|
+
export const TrashAction = Action.Trash;
|
|
55
|
+
export const allLocalStorageItems = LocalStorage.allItems;
|
|
56
|
+
export const clearClipboard = Clipboard.clear;
|
|
57
|
+
export const clearLocalStorage = LocalStorage.clear;
|
|
58
|
+
export const copyTextToClipboard = Clipboard.copy;
|
|
59
|
+
export const getLocalStorageItem = LocalStorage.getItem;
|
|
60
|
+
export const pasteText = Clipboard.paste;
|
|
61
|
+
export const removeLocalStorageItem = LocalStorage.removeItem;
|
|
62
|
+
export const setLocalStorageItem = LocalStorage.setItem;
|
|
63
|
+
export const unstable_AI = AI;
|
|
64
|
+
/** @deprecated Use the key string directly. */
|
|
65
|
+
export const specialKeys = Object.fromEntries([
|
|
66
|
+
"return",
|
|
67
|
+
"delete",
|
|
68
|
+
"deleteForward",
|
|
69
|
+
"tab",
|
|
70
|
+
"arrowUp",
|
|
71
|
+
"arrowDown",
|
|
72
|
+
"arrowLeft",
|
|
73
|
+
"arrowRight",
|
|
74
|
+
"pageUp",
|
|
75
|
+
"pageDown",
|
|
76
|
+
"home",
|
|
77
|
+
"end",
|
|
78
|
+
"space",
|
|
79
|
+
"escape",
|
|
80
|
+
"enter",
|
|
81
|
+
"backspace",
|
|
82
|
+
].map((key) => [key, key]));
|
|
@@ -0,0 +1,182 @@
|
|
|
1
|
+
/** `Keyboard.KeyModifier`: the modifiers a shortcut may use. */
|
|
2
|
+
export declare const KEY_MODIFIERS: readonly ["cmd", "ctrl", "opt", "shift", "alt", "windows"];
|
|
3
|
+
export type KeyModifier = (typeof KEY_MODIFIERS)[number];
|
|
4
|
+
/** `Keyboard.KeyEquivalent`: the keys a shortcut may use. */
|
|
5
|
+
export declare const KEY_EQUIVALENTS: readonly ["a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", ".", ",", ";", "=", "+", "-", "[", "]", "{", "}", "«", "»", "(", ")", "/", "\\", "'", "`", "§", "^", "@", "$", "return", "delete", "deleteForward", "tab", "arrowUp", "arrowDown", "arrowLeft", "arrowRight", "pageUp", "pageDown", "home", "end", "space", "escape", "enter", "backspace"];
|
|
6
|
+
export type KeyEquivalent = (typeof KEY_EQUIVALENTS)[number];
|
|
7
|
+
export declare const Keyboard: {
|
|
8
|
+
Shortcut: {
|
|
9
|
+
Common: {
|
|
10
|
+
Copy: {
|
|
11
|
+
macOS: {
|
|
12
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
13
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
14
|
+
};
|
|
15
|
+
Windows: {
|
|
16
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
17
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
18
|
+
};
|
|
19
|
+
};
|
|
20
|
+
CopyDeeplink: {
|
|
21
|
+
macOS: {
|
|
22
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
23
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
24
|
+
};
|
|
25
|
+
Windows: {
|
|
26
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
27
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
28
|
+
};
|
|
29
|
+
};
|
|
30
|
+
CopyName: {
|
|
31
|
+
macOS: {
|
|
32
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
33
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
34
|
+
};
|
|
35
|
+
Windows: {
|
|
36
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
37
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
38
|
+
};
|
|
39
|
+
};
|
|
40
|
+
CopyPath: {
|
|
41
|
+
macOS: {
|
|
42
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
43
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
44
|
+
};
|
|
45
|
+
Windows: {
|
|
46
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
47
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
48
|
+
};
|
|
49
|
+
};
|
|
50
|
+
Save: {
|
|
51
|
+
macOS: {
|
|
52
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
53
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
54
|
+
};
|
|
55
|
+
Windows: {
|
|
56
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
57
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
58
|
+
};
|
|
59
|
+
};
|
|
60
|
+
Duplicate: {
|
|
61
|
+
macOS: {
|
|
62
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
63
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
64
|
+
};
|
|
65
|
+
Windows: {
|
|
66
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
67
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
68
|
+
};
|
|
69
|
+
};
|
|
70
|
+
Edit: {
|
|
71
|
+
macOS: {
|
|
72
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
73
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
74
|
+
};
|
|
75
|
+
Windows: {
|
|
76
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
77
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
78
|
+
};
|
|
79
|
+
};
|
|
80
|
+
MoveDown: {
|
|
81
|
+
macOS: {
|
|
82
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
83
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
84
|
+
};
|
|
85
|
+
Windows: {
|
|
86
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
87
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
88
|
+
};
|
|
89
|
+
};
|
|
90
|
+
MoveUp: {
|
|
91
|
+
macOS: {
|
|
92
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
93
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
94
|
+
};
|
|
95
|
+
Windows: {
|
|
96
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
97
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
98
|
+
};
|
|
99
|
+
};
|
|
100
|
+
New: {
|
|
101
|
+
macOS: {
|
|
102
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
103
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
104
|
+
};
|
|
105
|
+
Windows: {
|
|
106
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
107
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
108
|
+
};
|
|
109
|
+
};
|
|
110
|
+
Open: {
|
|
111
|
+
macOS: {
|
|
112
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
113
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
114
|
+
};
|
|
115
|
+
Windows: {
|
|
116
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
117
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
118
|
+
};
|
|
119
|
+
};
|
|
120
|
+
OpenWith: {
|
|
121
|
+
macOS: {
|
|
122
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
123
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
124
|
+
};
|
|
125
|
+
Windows: {
|
|
126
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
127
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
128
|
+
};
|
|
129
|
+
};
|
|
130
|
+
Pin: {
|
|
131
|
+
macOS: {
|
|
132
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
133
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
134
|
+
};
|
|
135
|
+
Windows: {
|
|
136
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
137
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
138
|
+
};
|
|
139
|
+
};
|
|
140
|
+
Refresh: {
|
|
141
|
+
macOS: {
|
|
142
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
143
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
144
|
+
};
|
|
145
|
+
Windows: {
|
|
146
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
147
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
148
|
+
};
|
|
149
|
+
};
|
|
150
|
+
Remove: {
|
|
151
|
+
macOS: {
|
|
152
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
153
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
154
|
+
};
|
|
155
|
+
Windows: {
|
|
156
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
157
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
158
|
+
};
|
|
159
|
+
};
|
|
160
|
+
RemoveAll: {
|
|
161
|
+
macOS: {
|
|
162
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
163
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
164
|
+
};
|
|
165
|
+
Windows: {
|
|
166
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
167
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
168
|
+
};
|
|
169
|
+
};
|
|
170
|
+
ToggleQuickLook: {
|
|
171
|
+
macOS: {
|
|
172
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
173
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
174
|
+
};
|
|
175
|
+
Windows: {
|
|
176
|
+
modifiers: ("alt" | "cmd" | "ctrl" | "opt" | "shift" | "windows")[];
|
|
177
|
+
key: "$" | "'" | "(" | ")" | "+" | "," | "-" | "." | "/" | "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | ";" | "=" | "@" | "[" | "\\" | "]" | "^" | "`" | "a" | "arrowDown" | "arrowLeft" | "arrowRight" | "arrowUp" | "b" | "backspace" | "c" | "d" | "delete" | "deleteForward" | "e" | "end" | "enter" | "escape" | "f" | "g" | "h" | "home" | "i" | "j" | "k" | "l" | "m" | "n" | "o" | "p" | "pageDown" | "pageUp" | "q" | "r" | "return" | "s" | "space" | "t" | "tab" | "u" | "v" | "w" | "x" | "y" | "z" | "{" | "}" | "§" | "«" | "»";
|
|
178
|
+
};
|
|
179
|
+
};
|
|
180
|
+
};
|
|
181
|
+
};
|
|
182
|
+
};
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
/** `Keyboard.KeyModifier`: the modifiers a shortcut may use. */
|
|
2
|
+
export const KEY_MODIFIERS = ["cmd", "ctrl", "opt", "shift", "alt", "windows"];
|
|
3
|
+
/** `Keyboard.KeyEquivalent`: the keys a shortcut may use. */
|
|
4
|
+
export const KEY_EQUIVALENTS = [
|
|
5
|
+
"a",
|
|
6
|
+
"b",
|
|
7
|
+
"c",
|
|
8
|
+
"d",
|
|
9
|
+
"e",
|
|
10
|
+
"f",
|
|
11
|
+
"g",
|
|
12
|
+
"h",
|
|
13
|
+
"i",
|
|
14
|
+
"j",
|
|
15
|
+
"k",
|
|
16
|
+
"l",
|
|
17
|
+
"m",
|
|
18
|
+
"n",
|
|
19
|
+
"o",
|
|
20
|
+
"p",
|
|
21
|
+
"q",
|
|
22
|
+
"r",
|
|
23
|
+
"s",
|
|
24
|
+
"t",
|
|
25
|
+
"u",
|
|
26
|
+
"v",
|
|
27
|
+
"w",
|
|
28
|
+
"x",
|
|
29
|
+
"y",
|
|
30
|
+
"z",
|
|
31
|
+
"0",
|
|
32
|
+
"1",
|
|
33
|
+
"2",
|
|
34
|
+
"3",
|
|
35
|
+
"4",
|
|
36
|
+
"5",
|
|
37
|
+
"6",
|
|
38
|
+
"7",
|
|
39
|
+
"8",
|
|
40
|
+
"9",
|
|
41
|
+
".",
|
|
42
|
+
",",
|
|
43
|
+
";",
|
|
44
|
+
"=",
|
|
45
|
+
"+",
|
|
46
|
+
"-",
|
|
47
|
+
"[",
|
|
48
|
+
"]",
|
|
49
|
+
"{",
|
|
50
|
+
"}",
|
|
51
|
+
"«",
|
|
52
|
+
"»",
|
|
53
|
+
"(",
|
|
54
|
+
")",
|
|
55
|
+
"/",
|
|
56
|
+
"\\",
|
|
57
|
+
"'",
|
|
58
|
+
"`",
|
|
59
|
+
"§",
|
|
60
|
+
"^",
|
|
61
|
+
"@",
|
|
62
|
+
"$",
|
|
63
|
+
"return",
|
|
64
|
+
"delete",
|
|
65
|
+
"deleteForward",
|
|
66
|
+
"tab",
|
|
67
|
+
"arrowUp",
|
|
68
|
+
"arrowDown",
|
|
69
|
+
"arrowLeft",
|
|
70
|
+
"arrowRight",
|
|
71
|
+
"pageUp",
|
|
72
|
+
"pageDown",
|
|
73
|
+
"home",
|
|
74
|
+
"end",
|
|
75
|
+
"space",
|
|
76
|
+
"escape",
|
|
77
|
+
"enter",
|
|
78
|
+
"backspace",
|
|
79
|
+
];
|
|
80
|
+
function shortcut(key, macOS, Windows, windowsKey = key) {
|
|
81
|
+
return { macOS: { modifiers: macOS, key }, Windows: { modifiers: Windows, key: windowsKey } };
|
|
82
|
+
}
|
|
83
|
+
// https://developers.raycast.com/api-reference/keyboard#keyboard.shortcut.common
|
|
84
|
+
// The declarations supply the names; the public docs supply both platform mappings.
|
|
85
|
+
export const Keyboard = {
|
|
86
|
+
Shortcut: {
|
|
87
|
+
Common: {
|
|
88
|
+
Copy: shortcut("c", ["cmd", "shift"], ["ctrl", "shift"]),
|
|
89
|
+
CopyDeeplink: shortcut("c", ["cmd", "shift"], ["ctrl", "shift"]),
|
|
90
|
+
CopyName: shortcut("c", ["cmd", "opt"], ["ctrl", "alt"]),
|
|
91
|
+
CopyPath: shortcut("c", ["cmd", "ctrl"], ["alt", "shift"]),
|
|
92
|
+
Save: shortcut("s", ["cmd"], ["ctrl"]),
|
|
93
|
+
Duplicate: shortcut("d", ["cmd"], ["ctrl", "shift"], "s"),
|
|
94
|
+
Edit: shortcut("e", ["cmd"], ["ctrl"]),
|
|
95
|
+
MoveDown: shortcut("arrowDown", ["cmd", "opt"], ["ctrl", "alt"]),
|
|
96
|
+
MoveUp: shortcut("arrowUp", ["cmd", "opt"], ["ctrl", "alt"]),
|
|
97
|
+
New: shortcut("n", ["cmd"], ["ctrl"]),
|
|
98
|
+
Open: shortcut("o", ["cmd"], ["ctrl"]),
|
|
99
|
+
OpenWith: shortcut("o", ["cmd", "shift"], ["ctrl", "shift"]),
|
|
100
|
+
Pin: shortcut(".", ["cmd"], ["ctrl"]),
|
|
101
|
+
Refresh: shortcut("r", ["cmd"], ["ctrl"]),
|
|
102
|
+
Remove: shortcut("x", ["ctrl"], ["ctrl"], "d"),
|
|
103
|
+
RemoveAll: shortcut("x", ["ctrl", "shift"], ["ctrl", "alt"], "d"),
|
|
104
|
+
ToggleQuickLook: shortcut("y", ["cmd"], ["ctrl"]),
|
|
105
|
+
},
|
|
106
|
+
},
|
|
107
|
+
};
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import type { FormValues } from "./form.js";
|
|
2
|
+
import type { JsonValue } from "../reconciler/index.js";
|
|
3
|
+
import { LaunchType } from "./enums.generated.js";
|
|
4
|
+
export { LaunchType };
|
|
5
|
+
/** `LaunchType`'s value union: the enum type from the declarations. */
|
|
6
|
+
export type LaunchTypeValue = (typeof LaunchType)[keyof typeof LaunchType];
|
|
7
|
+
/** `LaunchContext`: arbitrary JSON passed through `launchCommand({ context })`. */
|
|
8
|
+
export type LaunchContext = Record<string, JsonValue>;
|
|
9
|
+
/** `LaunchProps`: the top-level props a command receives on launch. */
|
|
10
|
+
export type LaunchProps = {
|
|
11
|
+
/** Manifest argument values, keyed by the arguments' names. */
|
|
12
|
+
arguments: Record<string, string>;
|
|
13
|
+
launchType: LaunchTypeValue;
|
|
14
|
+
/** Only present when the command was started by `launchCommand`. */
|
|
15
|
+
launchContext?: LaunchContext;
|
|
16
|
+
draftValues?: FormValues;
|
|
17
|
+
};
|
|
18
|
+
/**
|
|
19
|
+
* `LaunchOptions`: command name and launch type, plus the fields the
|
|
20
|
+
* inter-extension form requires (`extensionName` and `ownerOrAuthorName`).
|
|
21
|
+
*/
|
|
22
|
+
export interface LaunchCommandOptions {
|
|
23
|
+
name: string;
|
|
24
|
+
type: LaunchTypeValue;
|
|
25
|
+
extensionName?: string;
|
|
26
|
+
ownerOrAuthorName?: string;
|
|
27
|
+
arguments?: Record<string, string> | null;
|
|
28
|
+
context?: LaunchContext | null;
|
|
29
|
+
fallbackText?: string | null;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Launches another command. Blast records the request and the host decides: a
|
|
33
|
+
* granted `command.launch` accepts it, a denial rejects it, and nothing starts
|
|
34
|
+
* a second session yet.
|
|
35
|
+
*/
|
|
36
|
+
export declare function launchCommand(options: LaunchCommandOptions): Promise<void>;
|
|
37
|
+
/** Updates the current command's metadata in the host's own UI. */
|
|
38
|
+
export declare function updateCommandMetadata(metadata: {
|
|
39
|
+
subtitle?: string | null;
|
|
40
|
+
}): Promise<void>;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { requestCapability } from "./capability.js";
|
|
2
|
+
import { LaunchType } from "./enums.generated.js";
|
|
3
|
+
export { LaunchType };
|
|
4
|
+
/**
|
|
5
|
+
* Launches another command. Blast records the request and the host decides: a
|
|
6
|
+
* granted `command.launch` accepts it, a denial rejects it, and nothing starts
|
|
7
|
+
* a second session yet.
|
|
8
|
+
*/
|
|
9
|
+
export async function launchCommand(options) {
|
|
10
|
+
const params = { name: options.name, type: options.type };
|
|
11
|
+
if (options.extensionName !== undefined)
|
|
12
|
+
params["extensionName"] = options.extensionName;
|
|
13
|
+
if (options.ownerOrAuthorName !== undefined) {
|
|
14
|
+
params["ownerOrAuthorName"] = options.ownerOrAuthorName;
|
|
15
|
+
}
|
|
16
|
+
if (options.arguments != null)
|
|
17
|
+
params["arguments"] = options.arguments;
|
|
18
|
+
if (options.context != null)
|
|
19
|
+
params["context"] = options.context;
|
|
20
|
+
if (options.fallbackText != null)
|
|
21
|
+
params["fallbackText"] = options.fallbackText;
|
|
22
|
+
await requestCapability("command.launch", params);
|
|
23
|
+
}
|
|
24
|
+
/** Updates the current command's metadata in the host's own UI. */
|
|
25
|
+
export async function updateCommandMetadata(metadata) {
|
|
26
|
+
await requestCapability("command.metadata", metadata.subtitle === undefined ? {} : { subtitle: metadata.subtitle });
|
|
27
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { type ReactNode } from "react";
|
|
2
|
+
/** @deprecated Add `nanoid` as a dependency and use it instead. */
|
|
3
|
+
export declare function randomId(): string;
|
|
4
|
+
/** @deprecated Use `useRef` with `nanoid`. */
|
|
5
|
+
export declare function useId(): string;
|
|
6
|
+
/** Installs the command-root renderer before the runtime imports an extension. */
|
|
7
|
+
export declare function setRenderMount(next: ((element: ReactNode) => void) | undefined): void;
|
|
8
|
+
/** @deprecated Use `export default function Command() { ... }` instead. */
|
|
9
|
+
export declare function render(element: ReactNode): void;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
// Deprecated top-level helpers from `@raycast/api`: id generation and the
|
|
2
|
+
// legacy `render` entry point that mounted a command's root element itself.
|
|
3
|
+
import { useRef } from "react";
|
|
4
|
+
/** @deprecated Add `nanoid` as a dependency and use it instead. */
|
|
5
|
+
export function randomId() {
|
|
6
|
+
return crypto.randomUUID();
|
|
7
|
+
}
|
|
8
|
+
/** @deprecated Use `useRef` with `nanoid`. */
|
|
9
|
+
export function useId() {
|
|
10
|
+
// One id per component instance, stable across re-renders.
|
|
11
|
+
const id = useRef(undefined);
|
|
12
|
+
id.current ??= randomId();
|
|
13
|
+
return id.current;
|
|
14
|
+
}
|
|
15
|
+
let mount;
|
|
16
|
+
/** Installs the command-root renderer before the runtime imports an extension. */
|
|
17
|
+
export function setRenderMount(next) {
|
|
18
|
+
mount = next;
|
|
19
|
+
}
|
|
20
|
+
/** @deprecated Use `export default function Command() { ... }` instead. */
|
|
21
|
+
export function render(element) {
|
|
22
|
+
if (!mount)
|
|
23
|
+
throw new Error("render: no command root is mounted");
|
|
24
|
+
mount(element);
|
|
25
|
+
}
|