deck-plugin-sdk 1.8.0 → 1.9.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/package.json +60 -60
- package/shim/bridge.js +231 -231
- package/shim/p2p.js +16 -16
- package/shim/settings.js +17 -17
- package/shim/terminals.js +100 -97
- package/template/plugin.json +10 -10
- package/types/components/ConfirmDialog.d.ts +1 -1
- package/types/components/ContextMenu.d.ts +1 -1
- package/types/components/NamePrompt.d.ts +1 -1
- package/types/components/dragrow.d.ts +2 -2
- package/types/core/bridge.d.ts +11 -4
- package/types/core/browser.d.ts +2 -0
- package/types/core/portal.d.ts +3 -0
- package/types/core/terminals.d.ts +36 -0
- package/types/core/windows.d.ts +52 -0
- package/types/modules/editor/models.d.ts +6 -0
package/package.json
CHANGED
|
@@ -1,60 +1,60 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "deck-plugin-sdk",
|
|
3
|
-
"version": "1.
|
|
4
|
-
"description": "Build a plugin for Deck, outside the Deck repository.",
|
|
5
|
-
"type": "module",
|
|
6
|
-
"license": "MIT",
|
|
7
|
-
"bin": {
|
|
8
|
-
"deck-plugin": "bin/deck-plugin.mjs"
|
|
9
|
-
},
|
|
10
|
-
"exports": {
|
|
11
|
-
"./build": "./build-plugin.mjs",
|
|
12
|
-
"./*": {
|
|
13
|
-
"types": "./shim/*.d.ts",
|
|
14
|
-
"default": "./shim/*.js"
|
|
15
|
-
},
|
|
16
|
-
"./package.json": "./package.json"
|
|
17
|
-
},
|
|
18
|
-
"files": [
|
|
19
|
-
"bin",
|
|
20
|
-
"shim",
|
|
21
|
-
"types",
|
|
22
|
-
"template",
|
|
23
|
-
"build-plugin.mjs",
|
|
24
|
-
"packages.mjs",
|
|
25
|
-
"README.md",
|
|
26
|
-
"permissions.json",
|
|
27
|
-
"publish.mjs",
|
|
28
|
-
"validate.mjs"
|
|
29
|
-
],
|
|
30
|
-
"dependencies": {
|
|
31
|
-
"esbuild": "^0.28.0"
|
|
32
|
-
},
|
|
33
|
-
"peerDependencies": {
|
|
34
|
-
"@types/react": "^19.0.0",
|
|
35
|
-
"framer-motion": "^13.0.0",
|
|
36
|
-
"lucide-react": "^1.0.0",
|
|
37
|
-
"monaco-editor": "^0.56.0",
|
|
38
|
-
"react": "^19.0.0",
|
|
39
|
-
"typescript": "^5.0.0"
|
|
40
|
-
},
|
|
41
|
-
"peerDependenciesMeta": {
|
|
42
|
-
"framer-motion": {
|
|
43
|
-
"optional": true
|
|
44
|
-
},
|
|
45
|
-
"monaco-editor": {
|
|
46
|
-
"optional": true
|
|
47
|
-
},
|
|
48
|
-
"typescript": {
|
|
49
|
-
"optional": true
|
|
50
|
-
}
|
|
51
|
-
},
|
|
52
|
-
"engines": {
|
|
53
|
-
"node": ">=20"
|
|
54
|
-
},
|
|
55
|
-
"keywords": [
|
|
56
|
-
"deck",
|
|
57
|
-
"plugin",
|
|
58
|
-
"sdk"
|
|
59
|
-
]
|
|
60
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "deck-plugin-sdk",
|
|
3
|
+
"version": "1.9.0",
|
|
4
|
+
"description": "Build a plugin for Deck, outside the Deck repository.",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"license": "MIT",
|
|
7
|
+
"bin": {
|
|
8
|
+
"deck-plugin": "bin/deck-plugin.mjs"
|
|
9
|
+
},
|
|
10
|
+
"exports": {
|
|
11
|
+
"./build": "./build-plugin.mjs",
|
|
12
|
+
"./*": {
|
|
13
|
+
"types": "./shim/*.d.ts",
|
|
14
|
+
"default": "./shim/*.js"
|
|
15
|
+
},
|
|
16
|
+
"./package.json": "./package.json"
|
|
17
|
+
},
|
|
18
|
+
"files": [
|
|
19
|
+
"bin",
|
|
20
|
+
"shim",
|
|
21
|
+
"types",
|
|
22
|
+
"template",
|
|
23
|
+
"build-plugin.mjs",
|
|
24
|
+
"packages.mjs",
|
|
25
|
+
"README.md",
|
|
26
|
+
"permissions.json",
|
|
27
|
+
"publish.mjs",
|
|
28
|
+
"validate.mjs"
|
|
29
|
+
],
|
|
30
|
+
"dependencies": {
|
|
31
|
+
"esbuild": "^0.28.0"
|
|
32
|
+
},
|
|
33
|
+
"peerDependencies": {
|
|
34
|
+
"@types/react": "^19.0.0",
|
|
35
|
+
"framer-motion": "^13.0.0",
|
|
36
|
+
"lucide-react": "^1.0.0",
|
|
37
|
+
"monaco-editor": "^0.56.0",
|
|
38
|
+
"react": "^19.0.0",
|
|
39
|
+
"typescript": "^5.0.0"
|
|
40
|
+
},
|
|
41
|
+
"peerDependenciesMeta": {
|
|
42
|
+
"framer-motion": {
|
|
43
|
+
"optional": true
|
|
44
|
+
},
|
|
45
|
+
"monaco-editor": {
|
|
46
|
+
"optional": true
|
|
47
|
+
},
|
|
48
|
+
"typescript": {
|
|
49
|
+
"optional": true
|
|
50
|
+
}
|
|
51
|
+
},
|
|
52
|
+
"engines": {
|
|
53
|
+
"node": ">=20"
|
|
54
|
+
},
|
|
55
|
+
"keywords": [
|
|
56
|
+
"deck",
|
|
57
|
+
"plugin",
|
|
58
|
+
"sdk"
|
|
59
|
+
]
|
|
60
|
+
}
|
package/shim/bridge.js
CHANGED
|
@@ -1,231 +1,231 @@
|
|
|
1
|
-
// GENERATED by sdk/gen-shim.mjs — do not edit.
|
|
2
|
-
//
|
|
3
|
-
// Deck's bridge. Everything resolves at USE time, never at import time: a plugin module is
|
|
4
|
-
// evaluated during loadPlugins, and a reference copied out then would capture a half-built
|
|
5
|
-
// object. Functions forward their arguments; plain values are proxied.
|
|
6
|
-
import { pluginId, scoped } from "./scope.js";
|
|
7
|
-
// The plugin's own view (Deck 1.8+), which refuses what its permissions do not cover; an older
|
|
8
|
-
// Deck has only the whole bridge.
|
|
9
|
-
const b = () => {
|
|
10
|
-
const x = window.__deck?.forPlugin?.(pluginId)?.bridge ?? window.__deck?.bridge;
|
|
11
|
-
if (!x) throw new Error("window.__deck.bridge is missing — this plugin only runs inside Deck");
|
|
12
|
-
return x;
|
|
13
|
-
};
|
|
14
|
-
|
|
15
|
-
export const adblockConfig = (...a) => b().adblockConfig(...a);
|
|
16
|
-
export const adblockInfo = (...a) => b().adblockInfo(...a);
|
|
17
|
-
export const adblockRebuild = (...a) => b().adblockRebuild(...a);
|
|
18
|
-
export const adblockUpdate = (...a) => b().adblockUpdate(...a);
|
|
19
|
-
export const agentClis = (...a) => b().agentClis(...a);
|
|
20
|
-
export const agentMcpStatus = (...a) => b().agentMcpStatus(...a);
|
|
21
|
-
export const agentStop = (...a) => b().agentStop(...a);
|
|
22
|
-
export const askSudoPassword = (...a) => b().askSudoPassword(...a);
|
|
23
|
-
export const backupExport = (...a) => b().backupExport(...a);
|
|
24
|
-
export const backupInspect = (...a) => b().backupInspect(...a);
|
|
25
|
-
export const backupRestore = (...a) => b().backupRestore(...a);
|
|
26
|
-
export const bookmarksBarMode = (...a) => b().bookmarksBarMode(...a);
|
|
27
|
-
export const browserAgentAnswer = (...a) => b().browserAgentAnswer(...a);
|
|
28
|
-
export const browserAgentConfig = (...a) => b().browserAgentConfig(...a);
|
|
29
|
-
export const browserAgentFillAnswer = (...a) => b().browserAgentFillAnswer(...a);
|
|
30
|
-
export const browserBounds = (...a) => b().browserBounds(...a);
|
|
31
|
-
export const browserCapture = (...a) => b().browserCapture(...a);
|
|
32
|
-
export const browserCdp = (...a) => b().browserCdp(...a);
|
|
33
|
-
export const browserClear = (...a) => b().browserClear(...a);
|
|
34
|
-
export const browserClose = (...a) => b().browserClose(...a);
|
|
35
|
-
export const browserDefaultRegister = (...a) => b().browserDefaultRegister(...a);
|
|
36
|
-
export const browserDefaultStatus = (...a) => b().browserDefaultStatus(...a);
|
|
37
|
-
export const browserDevtools = (...a) => b().browserDevtools(...a);
|
|
38
|
-
export const browserDownload = (...a) => b().browserDownload(...a);
|
|
39
|
-
export const browserFind = (...a) => b().browserFind(...a);
|
|
40
|
-
export const browserHistoryCount = (...a) => b().browserHistoryCount(...a);
|
|
41
|
-
export const browserHistoryForgetRange = (...a) => b().browserHistoryForgetRange(...a);
|
|
42
|
-
export const browserHistoryForgetUrl = (...a) => b().browserHistoryForgetUrl(...a);
|
|
43
|
-
export const browserHistoryList = (...a) => b().browserHistoryList(...a);
|
|
44
|
-
export const browserHistoryRecent = (...a) => b().browserHistoryRecent(...a);
|
|
45
|
-
export const browserHistorySuggest = (...a) => b().browserHistorySuggest(...a);
|
|
46
|
-
export const browserHistoryVisit = (...a) => b().browserHistoryVisit(...a);
|
|
47
|
-
export const browserMute = (...a) => b().browserMute(...a);
|
|
48
|
-
export const browserNav = (...a) => b().browserNav(...a);
|
|
49
|
-
export const browserNotificationClicked = (...a) => b().browserNotificationClicked(...a);
|
|
50
|
-
export const browserOpen = (...a) => b().browserOpen(...a);
|
|
51
|
-
export const browserOpenAppLink = (...a) => b().browserOpenAppLink(...a);
|
|
52
|
-
export const browserPermissionAnswer = (...a) => b().browserPermissionAnswer(...a);
|
|
53
|
-
export const browserPermissionSet = (...a) => b().browserPermissionSet(...a);
|
|
54
|
-
export const browserPermissions = (...a) => b().browserPermissions(...a);
|
|
55
|
-
export const browserPrint = (...a) => b().browserPrint(...a);
|
|
56
|
-
export const browserPrivacy = (...a) => b().browserPrivacy(...a);
|
|
57
|
-
export const browserReloadHung = (...a) => b().browserReloadHung(...a);
|
|
58
|
-
export const browserSetKeys = (...a) => b().browserSetKeys(...a);
|
|
59
|
-
export const browserSite = (...a) => b().browserSite(...a);
|
|
60
|
-
export const browserSiteAnswer = (...a) => b().browserSiteAnswer(...a);
|
|
61
|
-
export const browserSiteClear = (...a) => b().browserSiteClear(...a);
|
|
62
|
-
export const browserSleep = (...a) => b().browserSleep(...a);
|
|
63
|
-
export const browserWindowFullscreen = (...a) => b().browserWindowFullscreen(...a);
|
|
64
|
-
export const browserZoom = (...a) => b().browserZoom(...a);
|
|
65
|
-
export const claudePlanLimits = (...a) => b().claudePlanLimits(...a);
|
|
66
|
-
export const claudeUsage = (...a) => b().claudeUsage(...a);
|
|
67
|
-
export const clearWallpaper = (...a) => b().clearWallpaper(...a);
|
|
68
|
-
export const configDelete = (name, ...a) => b().configDelete(scoped(name), ...a);
|
|
69
|
-
export const configRead = (name, ...a) => b().configRead(scoped(name), ...a);
|
|
70
|
-
export const configWrite = (name, ...a) => b().configWrite(scoped(name), ...a);
|
|
71
|
-
export const convertFileSrc = (...a) => b().convertFileSrc(...a);
|
|
72
|
-
export const dataDir = () => b().dataDir(pluginId);
|
|
73
|
-
export const dbConnect = (...a) => b().dbConnect(...a);
|
|
74
|
-
export const dbDisconnect = (...a) => b().dbDisconnect(...a);
|
|
75
|
-
export const dbQuery = (...a) => b().dbQuery(...a);
|
|
76
|
-
export const dbSchema = (...a) => b().dbSchema(...a);
|
|
77
|
-
export const deckReady = (...a) => b().deckReady(...a);
|
|
78
|
-
export const deleteIconPack = (...a) => b().deleteIconPack(...a);
|
|
79
|
-
export const dirsDownload = (...a) => b().dirsDownload(...a);
|
|
80
|
-
export const exec = (...a) => b().exec(...a);
|
|
81
|
-
export const extensionInstallFolder = (...a) => b().extensionInstallFolder(...a);
|
|
82
|
-
export const extensionInstallStore = (...a) => b().extensionInstallStore(...a);
|
|
83
|
-
export const extensionPopup = (...a) => b().extensionPopup(...a);
|
|
84
|
-
export const extensionPopupClose = (...a) => b().extensionPopupClose(...a);
|
|
85
|
-
export const extensionReload = (...a) => b().extensionReload(...a);
|
|
86
|
-
export const extensionRemove = (...a) => b().extensionRemove(...a);
|
|
87
|
-
export const extensionSetEnabled = (...a) => b().extensionSetEnabled(...a);
|
|
88
|
-
export const extensionsList = (...a) => b().extensionsList(...a);
|
|
89
|
-
export const footerOrder = (...a) => b().footerOrder(...a);
|
|
90
|
-
export const fsCopy = (...a) => b().fsCopy(...a);
|
|
91
|
-
export const fsCreateDir = (...a) => b().fsCreateDir(...a);
|
|
92
|
-
export const fsCreateFile = (...a) => b().fsCreateFile(...a);
|
|
93
|
-
export const fsDelete = (...a) => b().fsDelete(...a);
|
|
94
|
-
export const fsDrives = (...a) => b().fsDrives(...a);
|
|
95
|
-
export const fsFiles = (...a) => b().fsFiles(...a);
|
|
96
|
-
export const fsFind = (...a) => b().fsFind(...a);
|
|
97
|
-
export const fsHash = (...a) => b().fsHash(...a);
|
|
98
|
-
export const fsHomeDir = (...a) => b().fsHomeDir(...a);
|
|
99
|
-
export const fsList = (...a) => b().fsList(...a);
|
|
100
|
-
export const fsMove = (...a) => b().fsMove(...a);
|
|
101
|
-
export const fsOpen = (...a) => b().fsOpen(...a);
|
|
102
|
-
export const fsRead = (...a) => b().fsRead(...a);
|
|
103
|
-
export const fsReadBytes = (...a) => b().fsReadBytes(...a);
|
|
104
|
-
export const fsRename = (...a) => b().fsRename(...a);
|
|
105
|
-
export const fsReplace = (...a) => b().fsReplace(...a);
|
|
106
|
-
export const fsReveal = (...a) => b().fsReveal(...a);
|
|
107
|
-
export const fsSaveUnique = (...a) => b().fsSaveUnique(...a);
|
|
108
|
-
export const fsSearch = (...a) => b().fsSearch(...a);
|
|
109
|
-
export const fsSize = (...a) => b().fsSize(...a);
|
|
110
|
-
export const fsThumbnail = (...a) => b().fsThumbnail(...a);
|
|
111
|
-
export const fsTrash = (...a) => b().fsTrash(...a);
|
|
112
|
-
export const fsWrite = (...a) => b().fsWrite(...a);
|
|
113
|
-
export const fsWriteBytes = (...a) => b().fsWriteBytes(...a);
|
|
114
|
-
export const getAutostart = (...a) => b().getAutostart(...a);
|
|
115
|
-
export const ghPrLineComment = (...a) => b().ghPrLineComment(...a);
|
|
116
|
-
export const ghPrThreads = (...a) => b().ghPrThreads(...a);
|
|
117
|
-
export const ghRun = (...a) => b().ghRun(...a);
|
|
118
|
-
export const ghThreadReply = (...a) => b().ghThreadReply(...a);
|
|
119
|
-
export const ghThreadResolve = (...a) => b().ghThreadResolve(...a);
|
|
120
|
-
export const gitAiCommitMsg = (...a) => b().gitAiCommitMsg(...a);
|
|
121
|
-
export const gitBlameLine = (...a) => b().gitBlameLine(...a);
|
|
122
|
-
export const gitCheckout = (...a) => b().gitCheckout(...a);
|
|
123
|
-
export const gitCheckoutDetach = (...a) => b().gitCheckoutDetach(...a);
|
|
124
|
-
export const gitCheckoutNew = (...a) => b().gitCheckoutNew(...a);
|
|
125
|
-
export const gitCheckoutTrack = (...a) => b().gitCheckoutTrack(...a);
|
|
126
|
-
export const gitCommitFiles = (...a) => b().gitCommitFiles(...a);
|
|
127
|
-
export const gitDiscard = (...a) => b().gitDiscard(...a);
|
|
128
|
-
export const gitFileBytes = (...a) => b().gitFileBytes(...a);
|
|
129
|
-
export const gitFileDiff = (...a) => b().gitFileDiff(...a);
|
|
130
|
-
export const gitInfo = (...a) => b().gitInfo(...a);
|
|
131
|
-
export const gitLogGraph = (...a) => b().gitLogGraph(...a);
|
|
132
|
-
export const gitPoll = (...a) => b().gitPoll(...a);
|
|
133
|
-
export const gitRangeFiles = (...a) => b().gitRangeFiles(...a);
|
|
134
|
-
export const gitRefs = (...a) => b().gitRefs(...a);
|
|
135
|
-
export const gitRepos = (...a) => b().gitRepos(...a);
|
|
136
|
-
export const gitRun = (...a) => b().gitRun(...a);
|
|
137
|
-
export const gitStatus = (...a) => b().gitStatus(...a);
|
|
138
|
-
export const glabApi = (...a) => b().glabApi(...a);
|
|
139
|
-
export const glabRun = (...a) => b().glabRun(...a);
|
|
140
|
-
export const googleAccount = (...a) => b().googleAccount(...a);
|
|
141
|
-
export const googleSignIn = (...a) => b().googleSignIn(...a);
|
|
142
|
-
export const googleSignOut = (...a) => b().googleSignOut(...a);
|
|
143
|
-
export const googleToken = (...a) => b().googleToken(...a);
|
|
144
|
-
export const httpCancel = (...a) => b().httpCancel(...a);
|
|
145
|
-
export const httpSend = (...a) => b().httpSend(...a);
|
|
146
|
-
export const httpSendAs = (...a) => b().httpSendAs(...a);
|
|
147
|
-
export const httpSendReply = (...a) => b().httpSendReply(...a);
|
|
148
|
-
export const importIconPack = (...a) => b().importIconPack(...a);
|
|
149
|
-
export const installAgentHooks = (...a) => b().installAgentHooks(...a);
|
|
150
|
-
export const installAgentMcp = (...a) => b().installAgentMcp(...a);
|
|
151
|
-
export const installAgentSkills = (...a) => b().installAgentSkills(...a);
|
|
152
|
-
export const installFromRegistry = (...a) => b().installFromRegistry(...a);
|
|
153
|
-
export const isFullscreen = (...a) => b().isFullscreen(...a);
|
|
154
|
-
export const languagesDir = (...a) => b().languagesDir(...a);
|
|
155
|
-
export const launchFiles = (...a) => b().launchFiles(...a);
|
|
156
|
-
export const launchUrls = (...a) => b().launchUrls(...a);
|
|
157
|
-
export const listApps = (...a) => b().listApps(...a);
|
|
158
|
-
export const listInstalled = (...a) => b().listInstalled(...a);
|
|
159
|
-
export const logLatest = (...a) => b().logLatest(...a);
|
|
160
|
-
export const mediaMeta = (...a) => b().mediaMeta(...a);
|
|
161
|
-
export const mediaSetNowPlaying = (...a) => b().mediaSetNowPlaying(...a);
|
|
162
|
-
export const mediaSetPlayback = (...a) => b().mediaSetPlayback(...a);
|
|
163
|
-
export const memKill = (...a) => b().memKill(...a);
|
|
164
|
-
export const memUsage = (...a) => b().memUsage(...a);
|
|
165
|
-
export const notifyOs = (...a) => b().notifyOs(...a);
|
|
166
|
-
export const openExternal = (...a) => b().openExternal(...a);
|
|
167
|
-
export const openFile = (...a) => b().openFile(...a);
|
|
168
|
-
export const openTestDeck = (...a) => b().openTestDeck(...a);
|
|
169
|
-
export const pickAnyFile = (...a) => b().pickAnyFile(...a);
|
|
170
|
-
export const pickExe = (...a) => b().pickExe(...a);
|
|
171
|
-
export const pickFile = (...a) => b().pickFile(...a);
|
|
172
|
-
export const pickFolder = (...a) => b().pickFolder(...a);
|
|
173
|
-
export const pickImage = (...a) => b().pickImage(...a);
|
|
174
|
-
export const pickSavePath = (...a) => b().pickSavePath(...a);
|
|
175
|
-
export const pickScript = (...a) => b().pickScript(...a);
|
|
176
|
-
export const pluginsDir = (...a) => b().pluginsDir(...a);
|
|
177
|
-
export const procKill = (...a) => b().procKill(...a);
|
|
178
|
-
export const procStream = (...a) => b().procStream(...a);
|
|
179
|
-
export const procWrite = (...a) => b().procWrite(...a);
|
|
180
|
-
export const readIconPackTheme = (...a) => b().readIconPackTheme(...a);
|
|
181
|
-
export const readTermLayout = (...a) => b().readTermLayout(...a);
|
|
182
|
-
export const readTrackMeta = (...a) => b().readTrackMeta(...a);
|
|
183
|
-
export const remoteHome = (...a) => b().remoteHome(...a);
|
|
184
|
-
export const remoteStat = (...a) => b().remoteStat(...a);
|
|
185
|
-
export const remoteSudoPassword = (...a) => b().remoteSudoPassword(...a);
|
|
186
|
-
export const removeLanguage = (...a) => b().removeLanguage(...a);
|
|
187
|
-
export const restartApp = (...a) => b().restartApp(...a);
|
|
188
|
-
export const revealInFolder = (...a) => b().revealInFolder(...a);
|
|
189
|
-
export const runScriptNow = (...a) => b().runScriptNow(...a);
|
|
190
|
-
export const sessionList = (...a) => b().sessionList(...a);
|
|
191
|
-
export const setAutostart = (...a) => b().setAutostart(...a);
|
|
192
|
-
export const setDebugTargets = (...a) => b().setDebugTargets(...a);
|
|
193
|
-
export const setWallpaper = (...a) => b().setWallpaper(...a);
|
|
194
|
-
export const sshHosts = (...a) => b().sshHosts(...a);
|
|
195
|
-
export const sshTunnelClose = (...a) => b().sshTunnelClose(...a);
|
|
196
|
-
export const sshTunnelOpen = (...a) => b().sshTunnelOpen(...a);
|
|
197
|
-
export const startupMarks = (...a) => b().startupMarks(...a);
|
|
198
|
-
export const toggleFullscreen = (...a) => b().toggleFullscreen(...a);
|
|
199
|
-
export const vaultChangePassword = (...a) => b().vaultChangePassword(...a);
|
|
200
|
-
export const vaultConfig = (...a) => b().vaultConfig(...a);
|
|
201
|
-
export const vaultCreate = (...a) => b().vaultCreate(...a);
|
|
202
|
-
export const vaultDelete = (...a) => b().vaultDelete(...a);
|
|
203
|
-
export const vaultExport = (...a) => b().vaultExport(...a);
|
|
204
|
-
export const vaultFill = (...a) => b().vaultFill(...a);
|
|
205
|
-
export const vaultFillNew = (...a) => b().vaultFillNew(...a);
|
|
206
|
-
export const vaultGenerate = (...a) => b().vaultGenerate(...a);
|
|
207
|
-
export const vaultImport = (...a) => b().vaultImport(...a);
|
|
208
|
-
export const vaultList = (...a) => b().vaultList(...a);
|
|
209
|
-
export const vaultLock = (...a) => b().vaultLock(...a);
|
|
210
|
-
export const vaultMatches = (...a) => b().vaultMatches(...a);
|
|
211
|
-
export const vaultNeverList = (...a) => b().vaultNeverList(...a);
|
|
212
|
-
export const vaultNeverRemove = (...a) => b().vaultNeverRemove(...a);
|
|
213
|
-
export const vaultOfferAnswer = (...a) => b().vaultOfferAnswer(...a);
|
|
214
|
-
export const vaultSave = (...a) => b().vaultSave(...a);
|
|
215
|
-
export const vaultSecret = (...a) => b().vaultSecret(...a);
|
|
216
|
-
export const vaultStatus = (...a) => b().vaultStatus(...a);
|
|
217
|
-
export const vaultTotp = (...a) => b().vaultTotp(...a);
|
|
218
|
-
export const vaultUnlock = (...a) => b().vaultUnlock(...a);
|
|
219
|
-
export const vpsRunsPull = (...a) => b().vpsRunsPull(...a);
|
|
220
|
-
export const watchFiles = (...a) => b().watchFiles(...a);
|
|
221
|
-
|
|
222
|
-
export const DEFAULT_SETTINGS = new Proxy({}, {
|
|
223
|
-
get: (_t, k) => b().DEFAULT_SETTINGS[k],
|
|
224
|
-
ownKeys: () => Reflect.ownKeys(b().DEFAULT_SETTINGS),
|
|
225
|
-
getOwnPropertyDescriptor: (_t, k) => ({ ...Object.getOwnPropertyDescriptor(b().DEFAULT_SETTINGS, k), configurable: true }),
|
|
226
|
-
});
|
|
227
|
-
export const FOOTER_ITEMS = new Proxy({}, {
|
|
228
|
-
get: (_t, k) => b().FOOTER_ITEMS[k],
|
|
229
|
-
ownKeys: () => Reflect.ownKeys(b().FOOTER_ITEMS),
|
|
230
|
-
getOwnPropertyDescriptor: (_t, k) => ({ ...Object.getOwnPropertyDescriptor(b().FOOTER_ITEMS, k), configurable: true }),
|
|
231
|
-
});
|
|
1
|
+
// GENERATED by sdk/gen-shim.mjs — do not edit.
|
|
2
|
+
//
|
|
3
|
+
// Deck's bridge. Everything resolves at USE time, never at import time: a plugin module is
|
|
4
|
+
// evaluated during loadPlugins, and a reference copied out then would capture a half-built
|
|
5
|
+
// object. Functions forward their arguments; plain values are proxied.
|
|
6
|
+
import { pluginId, scoped } from "./scope.js";
|
|
7
|
+
// The plugin's own view (Deck 1.8+), which refuses what its permissions do not cover; an older
|
|
8
|
+
// Deck has only the whole bridge.
|
|
9
|
+
const b = () => {
|
|
10
|
+
const x = window.__deck?.forPlugin?.(pluginId)?.bridge ?? window.__deck?.bridge;
|
|
11
|
+
if (!x) throw new Error("window.__deck.bridge is missing — this plugin only runs inside Deck");
|
|
12
|
+
return x;
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
export const adblockConfig = (...a) => b().adblockConfig(...a);
|
|
16
|
+
export const adblockInfo = (...a) => b().adblockInfo(...a);
|
|
17
|
+
export const adblockRebuild = (...a) => b().adblockRebuild(...a);
|
|
18
|
+
export const adblockUpdate = (...a) => b().adblockUpdate(...a);
|
|
19
|
+
export const agentClis = (...a) => b().agentClis(...a);
|
|
20
|
+
export const agentMcpStatus = (...a) => b().agentMcpStatus(...a);
|
|
21
|
+
export const agentStop = (...a) => b().agentStop(...a);
|
|
22
|
+
export const askSudoPassword = (...a) => b().askSudoPassword(...a);
|
|
23
|
+
export const backupExport = (...a) => b().backupExport(...a);
|
|
24
|
+
export const backupInspect = (...a) => b().backupInspect(...a);
|
|
25
|
+
export const backupRestore = (...a) => b().backupRestore(...a);
|
|
26
|
+
export const bookmarksBarMode = (...a) => b().bookmarksBarMode(...a);
|
|
27
|
+
export const browserAgentAnswer = (...a) => b().browserAgentAnswer(...a);
|
|
28
|
+
export const browserAgentConfig = (...a) => b().browserAgentConfig(...a);
|
|
29
|
+
export const browserAgentFillAnswer = (...a) => b().browserAgentFillAnswer(...a);
|
|
30
|
+
export const browserBounds = (...a) => b().browserBounds(...a);
|
|
31
|
+
export const browserCapture = (...a) => b().browserCapture(...a);
|
|
32
|
+
export const browserCdp = (...a) => b().browserCdp(...a);
|
|
33
|
+
export const browserClear = (...a) => b().browserClear(...a);
|
|
34
|
+
export const browserClose = (...a) => b().browserClose(...a);
|
|
35
|
+
export const browserDefaultRegister = (...a) => b().browserDefaultRegister(...a);
|
|
36
|
+
export const browserDefaultStatus = (...a) => b().browserDefaultStatus(...a);
|
|
37
|
+
export const browserDevtools = (...a) => b().browserDevtools(...a);
|
|
38
|
+
export const browserDownload = (...a) => b().browserDownload(...a);
|
|
39
|
+
export const browserFind = (...a) => b().browserFind(...a);
|
|
40
|
+
export const browserHistoryCount = (...a) => b().browserHistoryCount(...a);
|
|
41
|
+
export const browserHistoryForgetRange = (...a) => b().browserHistoryForgetRange(...a);
|
|
42
|
+
export const browserHistoryForgetUrl = (...a) => b().browserHistoryForgetUrl(...a);
|
|
43
|
+
export const browserHistoryList = (...a) => b().browserHistoryList(...a);
|
|
44
|
+
export const browserHistoryRecent = (...a) => b().browserHistoryRecent(...a);
|
|
45
|
+
export const browserHistorySuggest = (...a) => b().browserHistorySuggest(...a);
|
|
46
|
+
export const browserHistoryVisit = (...a) => b().browserHistoryVisit(...a);
|
|
47
|
+
export const browserMute = (...a) => b().browserMute(...a);
|
|
48
|
+
export const browserNav = (...a) => b().browserNav(...a);
|
|
49
|
+
export const browserNotificationClicked = (...a) => b().browserNotificationClicked(...a);
|
|
50
|
+
export const browserOpen = (...a) => b().browserOpen(...a);
|
|
51
|
+
export const browserOpenAppLink = (...a) => b().browserOpenAppLink(...a);
|
|
52
|
+
export const browserPermissionAnswer = (...a) => b().browserPermissionAnswer(...a);
|
|
53
|
+
export const browserPermissionSet = (...a) => b().browserPermissionSet(...a);
|
|
54
|
+
export const browserPermissions = (...a) => b().browserPermissions(...a);
|
|
55
|
+
export const browserPrint = (...a) => b().browserPrint(...a);
|
|
56
|
+
export const browserPrivacy = (...a) => b().browserPrivacy(...a);
|
|
57
|
+
export const browserReloadHung = (...a) => b().browserReloadHung(...a);
|
|
58
|
+
export const browserSetKeys = (...a) => b().browserSetKeys(...a);
|
|
59
|
+
export const browserSite = (...a) => b().browserSite(...a);
|
|
60
|
+
export const browserSiteAnswer = (...a) => b().browserSiteAnswer(...a);
|
|
61
|
+
export const browserSiteClear = (...a) => b().browserSiteClear(...a);
|
|
62
|
+
export const browserSleep = (...a) => b().browserSleep(...a);
|
|
63
|
+
export const browserWindowFullscreen = (...a) => b().browserWindowFullscreen(...a);
|
|
64
|
+
export const browserZoom = (...a) => b().browserZoom(...a);
|
|
65
|
+
export const claudePlanLimits = (...a) => b().claudePlanLimits(...a);
|
|
66
|
+
export const claudeUsage = (...a) => b().claudeUsage(...a);
|
|
67
|
+
export const clearWallpaper = (...a) => b().clearWallpaper(...a);
|
|
68
|
+
export const configDelete = (name, ...a) => b().configDelete(scoped(name), ...a);
|
|
69
|
+
export const configRead = (name, ...a) => b().configRead(scoped(name), ...a);
|
|
70
|
+
export const configWrite = (name, ...a) => b().configWrite(scoped(name), ...a);
|
|
71
|
+
export const convertFileSrc = (...a) => b().convertFileSrc(...a);
|
|
72
|
+
export const dataDir = () => b().dataDir(pluginId);
|
|
73
|
+
export const dbConnect = (...a) => b().dbConnect(...a);
|
|
74
|
+
export const dbDisconnect = (...a) => b().dbDisconnect(...a);
|
|
75
|
+
export const dbQuery = (...a) => b().dbQuery(...a);
|
|
76
|
+
export const dbSchema = (...a) => b().dbSchema(...a);
|
|
77
|
+
export const deckReady = (...a) => b().deckReady(...a);
|
|
78
|
+
export const deleteIconPack = (...a) => b().deleteIconPack(...a);
|
|
79
|
+
export const dirsDownload = (...a) => b().dirsDownload(...a);
|
|
80
|
+
export const exec = (...a) => b().exec(...a);
|
|
81
|
+
export const extensionInstallFolder = (...a) => b().extensionInstallFolder(...a);
|
|
82
|
+
export const extensionInstallStore = (...a) => b().extensionInstallStore(...a);
|
|
83
|
+
export const extensionPopup = (...a) => b().extensionPopup(...a);
|
|
84
|
+
export const extensionPopupClose = (...a) => b().extensionPopupClose(...a);
|
|
85
|
+
export const extensionReload = (...a) => b().extensionReload(...a);
|
|
86
|
+
export const extensionRemove = (...a) => b().extensionRemove(...a);
|
|
87
|
+
export const extensionSetEnabled = (...a) => b().extensionSetEnabled(...a);
|
|
88
|
+
export const extensionsList = (...a) => b().extensionsList(...a);
|
|
89
|
+
export const footerOrder = (...a) => b().footerOrder(...a);
|
|
90
|
+
export const fsCopy = (...a) => b().fsCopy(...a);
|
|
91
|
+
export const fsCreateDir = (...a) => b().fsCreateDir(...a);
|
|
92
|
+
export const fsCreateFile = (...a) => b().fsCreateFile(...a);
|
|
93
|
+
export const fsDelete = (...a) => b().fsDelete(...a);
|
|
94
|
+
export const fsDrives = (...a) => b().fsDrives(...a);
|
|
95
|
+
export const fsFiles = (...a) => b().fsFiles(...a);
|
|
96
|
+
export const fsFind = (...a) => b().fsFind(...a);
|
|
97
|
+
export const fsHash = (...a) => b().fsHash(...a);
|
|
98
|
+
export const fsHomeDir = (...a) => b().fsHomeDir(...a);
|
|
99
|
+
export const fsList = (...a) => b().fsList(...a);
|
|
100
|
+
export const fsMove = (...a) => b().fsMove(...a);
|
|
101
|
+
export const fsOpen = (...a) => b().fsOpen(...a);
|
|
102
|
+
export const fsRead = (...a) => b().fsRead(...a);
|
|
103
|
+
export const fsReadBytes = (...a) => b().fsReadBytes(...a);
|
|
104
|
+
export const fsRename = (...a) => b().fsRename(...a);
|
|
105
|
+
export const fsReplace = (...a) => b().fsReplace(...a);
|
|
106
|
+
export const fsReveal = (...a) => b().fsReveal(...a);
|
|
107
|
+
export const fsSaveUnique = (...a) => b().fsSaveUnique(...a);
|
|
108
|
+
export const fsSearch = (...a) => b().fsSearch(...a);
|
|
109
|
+
export const fsSize = (...a) => b().fsSize(...a);
|
|
110
|
+
export const fsThumbnail = (...a) => b().fsThumbnail(...a);
|
|
111
|
+
export const fsTrash = (...a) => b().fsTrash(...a);
|
|
112
|
+
export const fsWrite = (...a) => b().fsWrite(...a);
|
|
113
|
+
export const fsWriteBytes = (...a) => b().fsWriteBytes(...a);
|
|
114
|
+
export const getAutostart = (...a) => b().getAutostart(...a);
|
|
115
|
+
export const ghPrLineComment = (...a) => b().ghPrLineComment(...a);
|
|
116
|
+
export const ghPrThreads = (...a) => b().ghPrThreads(...a);
|
|
117
|
+
export const ghRun = (...a) => b().ghRun(...a);
|
|
118
|
+
export const ghThreadReply = (...a) => b().ghThreadReply(...a);
|
|
119
|
+
export const ghThreadResolve = (...a) => b().ghThreadResolve(...a);
|
|
120
|
+
export const gitAiCommitMsg = (...a) => b().gitAiCommitMsg(...a);
|
|
121
|
+
export const gitBlameLine = (...a) => b().gitBlameLine(...a);
|
|
122
|
+
export const gitCheckout = (...a) => b().gitCheckout(...a);
|
|
123
|
+
export const gitCheckoutDetach = (...a) => b().gitCheckoutDetach(...a);
|
|
124
|
+
export const gitCheckoutNew = (...a) => b().gitCheckoutNew(...a);
|
|
125
|
+
export const gitCheckoutTrack = (...a) => b().gitCheckoutTrack(...a);
|
|
126
|
+
export const gitCommitFiles = (...a) => b().gitCommitFiles(...a);
|
|
127
|
+
export const gitDiscard = (...a) => b().gitDiscard(...a);
|
|
128
|
+
export const gitFileBytes = (...a) => b().gitFileBytes(...a);
|
|
129
|
+
export const gitFileDiff = (...a) => b().gitFileDiff(...a);
|
|
130
|
+
export const gitInfo = (...a) => b().gitInfo(...a);
|
|
131
|
+
export const gitLogGraph = (...a) => b().gitLogGraph(...a);
|
|
132
|
+
export const gitPoll = (...a) => b().gitPoll(...a);
|
|
133
|
+
export const gitRangeFiles = (...a) => b().gitRangeFiles(...a);
|
|
134
|
+
export const gitRefs = (...a) => b().gitRefs(...a);
|
|
135
|
+
export const gitRepos = (...a) => b().gitRepos(...a);
|
|
136
|
+
export const gitRun = (...a) => b().gitRun(...a);
|
|
137
|
+
export const gitStatus = (...a) => b().gitStatus(...a);
|
|
138
|
+
export const glabApi = (...a) => b().glabApi(...a);
|
|
139
|
+
export const glabRun = (...a) => b().glabRun(...a);
|
|
140
|
+
export const googleAccount = (...a) => b().googleAccount(...a);
|
|
141
|
+
export const googleSignIn = (...a) => b().googleSignIn(...a);
|
|
142
|
+
export const googleSignOut = (...a) => b().googleSignOut(...a);
|
|
143
|
+
export const googleToken = (...a) => b().googleToken(...a);
|
|
144
|
+
export const httpCancel = (...a) => b().httpCancel(...a);
|
|
145
|
+
export const httpSend = (...a) => b().httpSend(...a);
|
|
146
|
+
export const httpSendAs = (...a) => b().httpSendAs(...a);
|
|
147
|
+
export const httpSendReply = (...a) => b().httpSendReply(...a);
|
|
148
|
+
export const importIconPack = (...a) => b().importIconPack(...a);
|
|
149
|
+
export const installAgentHooks = (...a) => b().installAgentHooks(...a);
|
|
150
|
+
export const installAgentMcp = (...a) => b().installAgentMcp(...a);
|
|
151
|
+
export const installAgentSkills = (...a) => b().installAgentSkills(...a);
|
|
152
|
+
export const installFromRegistry = (...a) => b().installFromRegistry(...a);
|
|
153
|
+
export const isFullscreen = (...a) => b().isFullscreen(...a);
|
|
154
|
+
export const languagesDir = (...a) => b().languagesDir(...a);
|
|
155
|
+
export const launchFiles = (...a) => b().launchFiles(...a);
|
|
156
|
+
export const launchUrls = (...a) => b().launchUrls(...a);
|
|
157
|
+
export const listApps = (...a) => b().listApps(...a);
|
|
158
|
+
export const listInstalled = (...a) => b().listInstalled(...a);
|
|
159
|
+
export const logLatest = (...a) => b().logLatest(...a);
|
|
160
|
+
export const mediaMeta = (...a) => b().mediaMeta(...a);
|
|
161
|
+
export const mediaSetNowPlaying = (...a) => b().mediaSetNowPlaying(...a);
|
|
162
|
+
export const mediaSetPlayback = (...a) => b().mediaSetPlayback(...a);
|
|
163
|
+
export const memKill = (...a) => b().memKill(...a);
|
|
164
|
+
export const memUsage = (...a) => b().memUsage(...a);
|
|
165
|
+
export const notifyOs = (...a) => b().notifyOs(...a);
|
|
166
|
+
export const openExternal = (...a) => b().openExternal(...a);
|
|
167
|
+
export const openFile = (...a) => b().openFile(...a);
|
|
168
|
+
export const openTestDeck = (...a) => b().openTestDeck(...a);
|
|
169
|
+
export const pickAnyFile = (...a) => b().pickAnyFile(...a);
|
|
170
|
+
export const pickExe = (...a) => b().pickExe(...a);
|
|
171
|
+
export const pickFile = (...a) => b().pickFile(...a);
|
|
172
|
+
export const pickFolder = (...a) => b().pickFolder(...a);
|
|
173
|
+
export const pickImage = (...a) => b().pickImage(...a);
|
|
174
|
+
export const pickSavePath = (...a) => b().pickSavePath(...a);
|
|
175
|
+
export const pickScript = (...a) => b().pickScript(...a);
|
|
176
|
+
export const pluginsDir = (...a) => b().pluginsDir(...a);
|
|
177
|
+
export const procKill = (...a) => b().procKill(...a);
|
|
178
|
+
export const procStream = (...a) => b().procStream(...a);
|
|
179
|
+
export const procWrite = (...a) => b().procWrite(...a);
|
|
180
|
+
export const readIconPackTheme = (...a) => b().readIconPackTheme(...a);
|
|
181
|
+
export const readTermLayout = (...a) => b().readTermLayout(...a);
|
|
182
|
+
export const readTrackMeta = (...a) => b().readTrackMeta(...a);
|
|
183
|
+
export const remoteHome = (...a) => b().remoteHome(...a);
|
|
184
|
+
export const remoteStat = (...a) => b().remoteStat(...a);
|
|
185
|
+
export const remoteSudoPassword = (...a) => b().remoteSudoPassword(...a);
|
|
186
|
+
export const removeLanguage = (...a) => b().removeLanguage(...a);
|
|
187
|
+
export const restartApp = (...a) => b().restartApp(...a);
|
|
188
|
+
export const revealInFolder = (...a) => b().revealInFolder(...a);
|
|
189
|
+
export const runScriptNow = (...a) => b().runScriptNow(...a);
|
|
190
|
+
export const sessionList = (...a) => b().sessionList(...a);
|
|
191
|
+
export const setAutostart = (...a) => b().setAutostart(...a);
|
|
192
|
+
export const setDebugTargets = (...a) => b().setDebugTargets(...a);
|
|
193
|
+
export const setWallpaper = (...a) => b().setWallpaper(...a);
|
|
194
|
+
export const sshHosts = (...a) => b().sshHosts(...a);
|
|
195
|
+
export const sshTunnelClose = (...a) => b().sshTunnelClose(...a);
|
|
196
|
+
export const sshTunnelOpen = (...a) => b().sshTunnelOpen(...a);
|
|
197
|
+
export const startupMarks = (...a) => b().startupMarks(...a);
|
|
198
|
+
export const toggleFullscreen = (...a) => b().toggleFullscreen(...a);
|
|
199
|
+
export const vaultChangePassword = (...a) => b().vaultChangePassword(...a);
|
|
200
|
+
export const vaultConfig = (...a) => b().vaultConfig(...a);
|
|
201
|
+
export const vaultCreate = (...a) => b().vaultCreate(...a);
|
|
202
|
+
export const vaultDelete = (...a) => b().vaultDelete(...a);
|
|
203
|
+
export const vaultExport = (...a) => b().vaultExport(...a);
|
|
204
|
+
export const vaultFill = (...a) => b().vaultFill(...a);
|
|
205
|
+
export const vaultFillNew = (...a) => b().vaultFillNew(...a);
|
|
206
|
+
export const vaultGenerate = (...a) => b().vaultGenerate(...a);
|
|
207
|
+
export const vaultImport = (...a) => b().vaultImport(...a);
|
|
208
|
+
export const vaultList = (...a) => b().vaultList(...a);
|
|
209
|
+
export const vaultLock = (...a) => b().vaultLock(...a);
|
|
210
|
+
export const vaultMatches = (...a) => b().vaultMatches(...a);
|
|
211
|
+
export const vaultNeverList = (...a) => b().vaultNeverList(...a);
|
|
212
|
+
export const vaultNeverRemove = (...a) => b().vaultNeverRemove(...a);
|
|
213
|
+
export const vaultOfferAnswer = (...a) => b().vaultOfferAnswer(...a);
|
|
214
|
+
export const vaultSave = (...a) => b().vaultSave(...a);
|
|
215
|
+
export const vaultSecret = (...a) => b().vaultSecret(...a);
|
|
216
|
+
export const vaultStatus = (...a) => b().vaultStatus(...a);
|
|
217
|
+
export const vaultTotp = (...a) => b().vaultTotp(...a);
|
|
218
|
+
export const vaultUnlock = (...a) => b().vaultUnlock(...a);
|
|
219
|
+
export const vpsRunsPull = (...a) => b().vpsRunsPull(...a);
|
|
220
|
+
export const watchFiles = (...a) => b().watchFiles(...a);
|
|
221
|
+
|
|
222
|
+
export const DEFAULT_SETTINGS = new Proxy({}, {
|
|
223
|
+
get: (_t, k) => b().DEFAULT_SETTINGS[k],
|
|
224
|
+
ownKeys: () => Reflect.ownKeys(b().DEFAULT_SETTINGS),
|
|
225
|
+
getOwnPropertyDescriptor: (_t, k) => ({ ...Object.getOwnPropertyDescriptor(b().DEFAULT_SETTINGS, k), configurable: true }),
|
|
226
|
+
});
|
|
227
|
+
export const FOOTER_ITEMS = new Proxy({}, {
|
|
228
|
+
get: (_t, k) => b().FOOTER_ITEMS[k],
|
|
229
|
+
ownKeys: () => Reflect.ownKeys(b().FOOTER_ITEMS),
|
|
230
|
+
getOwnPropertyDescriptor: (_t, k) => ({ ...Object.getOwnPropertyDescriptor(b().FOOTER_ITEMS, k), configurable: true }),
|
|
231
|
+
});
|
package/shim/p2p.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
// GENERATED by sdk/gen-shim.mjs — do not edit.
|
|
2
|
-
//
|
|
3
|
-
// Deck's live connections to other Decks. Resolved at USE time like the bridge: a plugin module is evaluated
|
|
4
|
-
// during loadPlugins, and a reference copied out at import time would capture a half-built
|
|
5
|
-
// object. One transport for every plugin, so a fix to it reaches all of them.
|
|
6
|
-
import { pluginId } from "./scope.js";
|
|
7
|
-
const t = () => {
|
|
8
|
-
const x = window.__deck?.forPlugin?.(pluginId)?.p2p ?? window.__deck?.p2p;
|
|
9
|
-
if (!x) throw new Error("window.__deck.p2p is missing — this plugin only runs inside Deck");
|
|
10
|
-
return x;
|
|
11
|
-
};
|
|
12
|
-
|
|
13
|
-
export const cleanCode = (...a) => t().cleanCode(...a);
|
|
14
|
-
export const newCode = (...a) => t().newCode(...a);
|
|
15
|
-
export const selfId = (...a) => t().selfId(...a);
|
|
16
|
-
export const share = (...a) => t().share(...a);
|
|
1
|
+
// GENERATED by sdk/gen-shim.mjs — do not edit.
|
|
2
|
+
//
|
|
3
|
+
// Deck's live connections to other Decks. Resolved at USE time like the bridge: a plugin module is evaluated
|
|
4
|
+
// during loadPlugins, and a reference copied out at import time would capture a half-built
|
|
5
|
+
// object. One transport for every plugin, so a fix to it reaches all of them.
|
|
6
|
+
import { pluginId } from "./scope.js";
|
|
7
|
+
const t = () => {
|
|
8
|
+
const x = window.__deck?.forPlugin?.(pluginId)?.p2p ?? window.__deck?.p2p;
|
|
9
|
+
if (!x) throw new Error("window.__deck.p2p is missing — this plugin only runs inside Deck");
|
|
10
|
+
return x;
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
export const cleanCode = (...a) => t().cleanCode(...a);
|
|
14
|
+
export const newCode = (...a) => t().newCode(...a);
|
|
15
|
+
export const selfId = (...a) => t().selfId(...a);
|
|
16
|
+
export const share = (...a) => t().share(...a);
|
package/shim/settings.js
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
// GENERATED by sdk/gen-shim.mjs — do not edit.
|
|
2
|
-
//
|
|
3
|
-
// Deck's settings store. Use this ONLY for settings Deck itself defines and its Rust side reads;
|
|
4
|
-
// a plugin's own settings belong in its own config file via configRead/configWrite.
|
|
5
|
-
import { pluginId } from "./scope.js";
|
|
6
|
-
const s = () => {
|
|
7
|
-
const x = window.__deck?.forPlugin?.(pluginId)?.settings ?? window.__deck?.settings;
|
|
8
|
-
if (!x) throw new Error("window.__deck.settings is missing — this plugin only runs inside Deck");
|
|
9
|
-
return x;
|
|
10
|
-
};
|
|
11
|
-
|
|
12
|
-
export const useSettings = (...a) => s().use(...a);
|
|
13
|
-
export const getSettings = (...a) => s().get(...a);
|
|
14
|
-
export const saveSettings = (...a) => s().save(...a);
|
|
15
|
-
// What to call the user (needs a Deck newer than 1.1): the name set in Settings, else their Google or Windows
|
|
16
|
-
// account's. For a plugin that shows the user to someone else.
|
|
17
|
-
export const userName = (...a) => s().userName(...a);
|
|
1
|
+
// GENERATED by sdk/gen-shim.mjs — do not edit.
|
|
2
|
+
//
|
|
3
|
+
// Deck's settings store. Use this ONLY for settings Deck itself defines and its Rust side reads;
|
|
4
|
+
// a plugin's own settings belong in its own config file via configRead/configWrite.
|
|
5
|
+
import { pluginId } from "./scope.js";
|
|
6
|
+
const s = () => {
|
|
7
|
+
const x = window.__deck?.forPlugin?.(pluginId)?.settings ?? window.__deck?.settings;
|
|
8
|
+
if (!x) throw new Error("window.__deck.settings is missing — this plugin only runs inside Deck");
|
|
9
|
+
return x;
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
export const useSettings = (...a) => s().use(...a);
|
|
13
|
+
export const getSettings = (...a) => s().get(...a);
|
|
14
|
+
export const saveSettings = (...a) => s().save(...a);
|
|
15
|
+
// What to call the user (needs a Deck newer than 1.1): the name set in Settings, else their Google or Windows
|
|
16
|
+
// account's. For a plugin that shows the user to someone else.
|
|
17
|
+
export const userName = (...a) => s().userName(...a);
|
package/shim/terminals.js
CHANGED
|
@@ -1,97 +1,100 @@
|
|
|
1
|
-
// GENERATED by sdk/gen-shim.mjs — do not edit.
|
|
2
|
-
//
|
|
3
|
-
// Deck's terminal panes. Resolved at USE time like the bridge: a plugin module is evaluated
|
|
4
|
-
// during loadPlugins, and a reference copied out at import time would capture a half-built
|
|
5
|
-
// object. The layout store is shared, not copied — a second one would not know about the panes
|
|
6
|
-
// Deck already has open.
|
|
7
|
-
import { pluginId } from "./scope.js";
|
|
8
|
-
const t = () => {
|
|
9
|
-
const x = window.__deck?.forPlugin?.(pluginId)?.terminals ?? window.__deck?.terminals;
|
|
10
|
-
if (!x) throw new Error("window.__deck.terminals is missing — this plugin only runs inside Deck");
|
|
11
|
-
return x;
|
|
12
|
-
};
|
|
13
|
-
|
|
14
|
-
export const GROUP_COLORS = (...a) => t().GROUP_COLORS(...a);
|
|
15
|
-
export const ZONE_BOARD = (...a) => t().ZONE_BOARD(...a);
|
|
16
|
-
export const activeWorkspaceCwd = (...a) => t().activeWorkspaceCwd(...a);
|
|
17
|
-
export const addTabToZone = (...a) => t().addTabToZone(...a);
|
|
18
|
-
export const addToGroup = (...a) => t().addToGroup(...a);
|
|
19
|
-
export const applyDtCommand = (...a) => t().applyDtCommand(...a);
|
|
20
|
-
export const applyTerminalLook = (...a) => t().applyTerminalLook(...a);
|
|
21
|
-
export const attach = (...a) => t().attach(...a);
|
|
22
|
-
export const bracketPaste = (...a) => t().bracketPaste(...a);
|
|
23
|
-
export const clearPane = (...a) => t().clearPane(...a);
|
|
24
|
-
export const closeLeaf = (...a) => t().closeLeaf(...a);
|
|
25
|
-
export const copyFrom = (...a) => t().copyFrom(...a);
|
|
26
|
-
export const destroy = (...a) => t().destroy(...a);
|
|
27
|
-
export const findLeaf = (...a) => t().findLeaf(...a);
|
|
28
|
-
export const focusPane = (...a) => t().focusPane(...a);
|
|
29
|
-
export const getInstance = (...a) => t().getInstance(...a);
|
|
30
|
-
export const getLayout = (...a) => t().getLayout(...a);
|
|
31
|
-
export const hasSelection = (...a) => t().hasSelection(...a);
|
|
32
|
-
export const insertBeside = (...a) => t().insertBeside(...a);
|
|
33
|
-
export const isPinned = (...a) => t().isPinned(...a);
|
|
34
|
-
export const isWorkspaceActive = (...a) => t().isWorkspaceActive(...a);
|
|
35
|
-
export const leafIds = (...a) => t().leafIds(...a);
|
|
36
|
-
export const leaveGroup = (...a) => t().leaveGroup(...a);
|
|
37
|
-
export const loadLayoutOnce = (...a) => t().loadLayoutOnce(...a);
|
|
38
|
-
export const markAgentStarted = (...a) => t().markAgentStarted(...a);
|
|
39
|
-
export const
|
|
40
|
-
export const
|
|
41
|
-
export const
|
|
42
|
-
export const
|
|
43
|
-
export const
|
|
44
|
-
export const
|
|
45
|
-
export const
|
|
46
|
-
export const
|
|
47
|
-
export const
|
|
48
|
-
export const
|
|
49
|
-
export const
|
|
50
|
-
export const
|
|
51
|
-
export const
|
|
52
|
-
export const
|
|
53
|
-
export const
|
|
54
|
-
export const
|
|
55
|
-
export const
|
|
56
|
-
export const
|
|
57
|
-
export const
|
|
58
|
-
export const
|
|
59
|
-
export const
|
|
60
|
-
export const
|
|
61
|
-
export const
|
|
62
|
-
export const
|
|
63
|
-
export const
|
|
64
|
-
export const
|
|
65
|
-
export const
|
|
66
|
-
export const
|
|
67
|
-
export const
|
|
68
|
-
export const
|
|
69
|
-
export const
|
|
70
|
-
export const
|
|
71
|
-
export const
|
|
72
|
-
export const
|
|
73
|
-
export const
|
|
74
|
-
export const
|
|
75
|
-
export const
|
|
76
|
-
export const
|
|
77
|
-
export const
|
|
78
|
-
export const
|
|
79
|
-
export const
|
|
80
|
-
export const
|
|
81
|
-
export const
|
|
82
|
-
export const
|
|
83
|
-
export const
|
|
84
|
-
export const
|
|
85
|
-
export const
|
|
86
|
-
export const
|
|
87
|
-
export const
|
|
88
|
-
export const
|
|
89
|
-
export const
|
|
90
|
-
export const
|
|
91
|
-
export const
|
|
92
|
-
export const
|
|
93
|
-
export const
|
|
94
|
-
export const
|
|
95
|
-
export const
|
|
96
|
-
export const
|
|
97
|
-
export const
|
|
1
|
+
// GENERATED by sdk/gen-shim.mjs — do not edit.
|
|
2
|
+
//
|
|
3
|
+
// Deck's terminal panes. Resolved at USE time like the bridge: a plugin module is evaluated
|
|
4
|
+
// during loadPlugins, and a reference copied out at import time would capture a half-built
|
|
5
|
+
// object. The layout store is shared, not copied — a second one would not know about the panes
|
|
6
|
+
// Deck already has open.
|
|
7
|
+
import { pluginId } from "./scope.js";
|
|
8
|
+
const t = () => {
|
|
9
|
+
const x = window.__deck?.forPlugin?.(pluginId)?.terminals ?? window.__deck?.terminals;
|
|
10
|
+
if (!x) throw new Error("window.__deck.terminals is missing — this plugin only runs inside Deck");
|
|
11
|
+
return x;
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
export const GROUP_COLORS = (...a) => t().GROUP_COLORS(...a);
|
|
15
|
+
export const ZONE_BOARD = (...a) => t().ZONE_BOARD(...a);
|
|
16
|
+
export const activeWorkspaceCwd = (...a) => t().activeWorkspaceCwd(...a);
|
|
17
|
+
export const addTabToZone = (...a) => t().addTabToZone(...a);
|
|
18
|
+
export const addToGroup = (...a) => t().addToGroup(...a);
|
|
19
|
+
export const applyDtCommand = (...a) => t().applyDtCommand(...a);
|
|
20
|
+
export const applyTerminalLook = (...a) => t().applyTerminalLook(...a);
|
|
21
|
+
export const attach = (...a) => t().attach(...a);
|
|
22
|
+
export const bracketPaste = (...a) => t().bracketPaste(...a);
|
|
23
|
+
export const clearPane = (...a) => t().clearPane(...a);
|
|
24
|
+
export const closeLeaf = (...a) => t().closeLeaf(...a);
|
|
25
|
+
export const copyFrom = (...a) => t().copyFrom(...a);
|
|
26
|
+
export const destroy = (...a) => t().destroy(...a);
|
|
27
|
+
export const findLeaf = (...a) => t().findLeaf(...a);
|
|
28
|
+
export const focusPane = (...a) => t().focusPane(...a);
|
|
29
|
+
export const getInstance = (...a) => t().getInstance(...a);
|
|
30
|
+
export const getLayout = (...a) => t().getLayout(...a);
|
|
31
|
+
export const hasSelection = (...a) => t().hasSelection(...a);
|
|
32
|
+
export const insertBeside = (...a) => t().insertBeside(...a);
|
|
33
|
+
export const isPinned = (...a) => t().isPinned(...a);
|
|
34
|
+
export const isWorkspaceActive = (...a) => t().isWorkspaceActive(...a);
|
|
35
|
+
export const leafIds = (...a) => t().leafIds(...a);
|
|
36
|
+
export const leaveGroup = (...a) => t().leaveGroup(...a);
|
|
37
|
+
export const loadLayoutOnce = (...a) => t().loadLayoutOnce(...a);
|
|
38
|
+
export const markAgentStarted = (...a) => t().markAgentStarted(...a);
|
|
39
|
+
export const mergeWindow = (...a) => t().mergeWindow(...a);
|
|
40
|
+
export const moveGroup = (...a) => t().moveGroup(...a);
|
|
41
|
+
export const moveLeaf = (...a) => t().moveLeaf(...a);
|
|
42
|
+
export const moveTabToZone = (...a) => t().moveTabToZone(...a);
|
|
43
|
+
export const moveWorkspace = (...a) => t().moveWorkspace(...a);
|
|
44
|
+
export const moveZone = (...a) => t().moveZone(...a);
|
|
45
|
+
export const mutateLayout = (...a) => t().mutateLayout(...a);
|
|
46
|
+
export const nextActiveAfterClose = (...a) => t().nextActiveAfterClose(...a);
|
|
47
|
+
export const nextZoneSpot = (...a) => t().nextZoneSpot(...a);
|
|
48
|
+
export const openActiveGroup = (...a) => t().openActiveGroup(...a);
|
|
49
|
+
export const openFile = (...a) => t().openFile(...a);
|
|
50
|
+
export const openInEditor = (...a) => t().openInEditor(...a);
|
|
51
|
+
export const openTabInWorkspace = (...a) => t().openTabInWorkspace(...a);
|
|
52
|
+
export const paneCwd = (...a) => t().paneCwd(...a);
|
|
53
|
+
export const paneHasAgent = (...a) => t().paneHasAgent(...a);
|
|
54
|
+
export const paneLabel = (...a) => t().paneLabel(...a);
|
|
55
|
+
export const paneLines = (...a) => t().paneLines(...a);
|
|
56
|
+
export const paneLocation = (...a) => t().paneLocation(...a);
|
|
57
|
+
export const pasteInto = (...a) => t().pasteInto(...a);
|
|
58
|
+
export const pasteText = (...a) => t().pasteText(...a);
|
|
59
|
+
export const pasteTextInto = (...a) => t().pasteTextInto(...a);
|
|
60
|
+
export const pruneGroups = (...a) => t().pruneGroups(...a);
|
|
61
|
+
export const publishLayout = (...a) => t().publishLayout(...a);
|
|
62
|
+
export const queueInput = (...a) => t().queueInput(...a);
|
|
63
|
+
export const rebindTerminals = (...a) => t().rebindTerminals(...a);
|
|
64
|
+
export const refit = (...a) => t().refit(...a);
|
|
65
|
+
export const reorderTab = (...a) => t().reorderTab(...a);
|
|
66
|
+
export const resetPaneModes = (...a) => t().resetPaneModes(...a);
|
|
67
|
+
export const restartPane = (...a) => t().restartPane(...a);
|
|
68
|
+
export const revealPane = (...a) => t().revealPane(...a);
|
|
69
|
+
export const runsLines = (...a) => t().runsLines(...a);
|
|
70
|
+
export const sendInput = (...a) => t().sendInput(...a);
|
|
71
|
+
export const setGroup = (...a) => t().setGroup(...a);
|
|
72
|
+
export const setLeafLabel = (...a) => t().setLeafLabel(...a);
|
|
73
|
+
export const setLeafView = (...a) => t().setLeafView(...a);
|
|
74
|
+
export const setTabWindow = (...a) => t().setTabWindow(...a);
|
|
75
|
+
export const showActiveTab = (...a) => t().showActiveTab(...a);
|
|
76
|
+
export const splitLeaf = (...a) => t().splitLeaf(...a);
|
|
77
|
+
export const stopPaneAgent = (...a) => t().stopPaneAgent(...a);
|
|
78
|
+
export const suspendWorkspace = (...a) => t().suspendWorkspace(...a);
|
|
79
|
+
export const switchWorkspace = (...a) => t().switchWorkspace(...a);
|
|
80
|
+
export const termKill = (...a) => t().termKill(...a);
|
|
81
|
+
export const termList = (...a) => t().termList(...a);
|
|
82
|
+
export const termResize = (...a) => t().termResize(...a);
|
|
83
|
+
export const termScrollback = (...a) => t().termScrollback(...a);
|
|
84
|
+
export const termSpawn = (...a) => t().termSpawn(...a);
|
|
85
|
+
export const termSweepScrollback = (...a) => t().termSweepScrollback(...a);
|
|
86
|
+
export const termWrite = (...a) => t().termWrite(...a);
|
|
87
|
+
export const toggleGroupFold = (...a) => t().toggleGroupFold(...a);
|
|
88
|
+
export const togglePin = (...a) => t().togglePin(...a);
|
|
89
|
+
export const ungroup = (...a) => t().ungroup(...a);
|
|
90
|
+
export const useAgentPanesVersion = (...a) => t().useAgentPanesVersion(...a);
|
|
91
|
+
export const useLayout = (...a) => t().useLayout(...a);
|
|
92
|
+
export const usePinnedPanes = (...a) => t().usePinnedPanes(...a);
|
|
93
|
+
export const webglLimit = (...a) => t().webglLimit(...a);
|
|
94
|
+
export const workspaceByCwd = (...a) => t().workspaceByCwd(...a);
|
|
95
|
+
export const workspaceShellCount = (...a) => t().workspaceShellCount(...a);
|
|
96
|
+
export const zoneAt = (...a) => t().zoneAt(...a);
|
|
97
|
+
export const zoneBoardFull = (...a) => t().zoneBoardFull(...a);
|
|
98
|
+
export const zoneOf = (...a) => t().zoneOf(...a);
|
|
99
|
+
export const zoneToward = (...a) => t().zoneToward(...a);
|
|
100
|
+
export const zones = (...a) => t().zones(...a);
|
package/template/plugin.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
{
|
|
2
|
-
"id": "__ID__",
|
|
3
|
-
"name": "__NAME__",
|
|
4
|
-
"description": "One line on what this is for, shown under its name in Settings.",
|
|
5
|
-
"icon": "Sparkles",
|
|
6
|
-
"color": "#a78bfa",
|
|
7
|
-
"version": "0.1.0",
|
|
8
|
-
"minDeck": "1.
|
|
9
|
-
"permissions": []
|
|
10
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"id": "__ID__",
|
|
3
|
+
"name": "__NAME__",
|
|
4
|
+
"description": "One line on what this is for, shown under its name in Settings.",
|
|
5
|
+
"icon": "Sparkles",
|
|
6
|
+
"color": "#a78bfa",
|
|
7
|
+
"version": "0.1.0",
|
|
8
|
+
"minDeck": "1.9.0",
|
|
9
|
+
"permissions": []
|
|
10
|
+
}
|
|
@@ -43,4 +43,4 @@ export declare function ContextMenu({ x, y, items, alignRight, onClose, onReorde
|
|
|
43
43
|
up?: boolean;
|
|
44
44
|
/** Called with (draggedId, newIndexAmongDraggableRows) after a drag-sort. */
|
|
45
45
|
onReorder?: (id: string, toIndex: number) => void;
|
|
46
|
-
}): import("react").
|
|
46
|
+
}): import("react").ReactNode;
|
|
@@ -10,8 +10,8 @@ export interface DropTarget {
|
|
|
10
10
|
parentId: string | null;
|
|
11
11
|
kind: string | null;
|
|
12
12
|
}
|
|
13
|
-
/** The row under a point, or null. Exported for the check. */
|
|
14
|
-
export declare function rowAt(x: number, y: number): DropTarget | null;
|
|
13
|
+
/** The row under a point of `doc` (the window the drag is in), or null. Exported for the check. */
|
|
14
|
+
export declare function rowAt(x: number, y: number, doc?: Document): DropTarget | null;
|
|
15
15
|
export interface DragState {
|
|
16
16
|
/** Id of the row being dragged, or null when idle. */
|
|
17
17
|
dragId: string | null;
|
package/types/core/bridge.d.ts
CHANGED
|
@@ -13,9 +13,9 @@ export interface PhysRect {
|
|
|
13
13
|
}
|
|
14
14
|
/** Open `url` in the browser pane's own webview (created the first time) at `r`. A private one
|
|
15
15
|
* keeps no cookies, history or cache. */
|
|
16
|
-
export declare const browserOpen: (pane: string, url: string, isPrivate: boolean, r: PhysRect) => Promise<void>;
|
|
16
|
+
export declare const browserOpen: (pane: string, url: string, isPrivate: boolean, r: PhysRect, window?: string) => Promise<void>;
|
|
17
17
|
/** Move the pane's webview, or hide it. */
|
|
18
|
-
export declare const browserBounds: (pane: string, r: PhysRect, visible: boolean) => Promise<void>;
|
|
18
|
+
export declare const browserBounds: (pane: string, r: PhysRect, visible: boolean, window?: string) => Promise<void>;
|
|
19
19
|
export declare const browserNav: (pane: string, action: "back" | "forward" | "reload" | "go" | "focus", url?: string) => Promise<void>;
|
|
20
20
|
/** The chords Rust takes from a focused page: `deck` moves the keyboard back to Deck, `page` does not. */
|
|
21
21
|
export declare const browserSetKeys: (deck: string[], page: string[]) => Promise<void>;
|
|
@@ -37,7 +37,7 @@ export declare const browserNotificationClicked: (pane: string, id: number) => P
|
|
|
37
37
|
/** Reload a page whose process hangs: that process is ended first. */
|
|
38
38
|
export declare const browserReloadHung: (pane: string) => Promise<void>;
|
|
39
39
|
/** The window fullscreen for a page that went fullscreen, or back as it was. */
|
|
40
|
-
export declare const browserWindowFullscreen: (on: boolean) => Promise<void>;
|
|
40
|
+
export declare const browserWindowFullscreen: (on: boolean, window?: string) => Promise<void>;
|
|
41
41
|
/** Put a hidden pane's page to sleep, or wake it. */
|
|
42
42
|
export declare const browserSleep: (pane: string, on: boolean) => Promise<void>;
|
|
43
43
|
/** A JPEG of what the pane's webview shows. */
|
|
@@ -263,6 +263,8 @@ export interface Settings {
|
|
|
263
263
|
tabWheelSwitch: boolean;
|
|
264
264
|
/** When the tabs do not fit, every one but the open tab shrinks to its icon. */
|
|
265
265
|
tabSqueeze?: boolean;
|
|
266
|
+
/** A title-bar tab's full width in px (120 to 320, 160 when unset): its width, or with tabSqueeze the most it narrows from. */
|
|
267
|
+
tabWidth?: number;
|
|
266
268
|
/** Each project's own colour on the sidebar's collapsed rail. Off, they are all one grey. */
|
|
267
269
|
projectColours?: boolean;
|
|
268
270
|
/** Agents listed under their workspace in the sidebar: under every one (default), only the open one, or none. */
|
|
@@ -407,7 +409,12 @@ export declare const remoteSudoPassword: (host: string, password: string) => Pro
|
|
|
407
409
|
/** Ask for the sudo password of `host` (SudoPasswordPrompt, mounted in App). True once it has
|
|
408
410
|
* been accepted, false if the prompt was cancelled. */
|
|
409
411
|
export declare function askSudoPassword(host: string): Promise<boolean>;
|
|
410
|
-
|
|
412
|
+
/**
|
|
413
|
+
* Watch `paths` for changes made outside Deck (`fs-changed` events, a path each). `owner` names
|
|
414
|
+
* the caller: each owner sets only its own list and the watcher follows every owner's together, so
|
|
415
|
+
* one caller cannot replace or end another's watch. An empty list takes the owner out.
|
|
416
|
+
*/
|
|
417
|
+
export declare const watchFiles: (paths: string[], owner?: string) => Promise<void>;
|
|
411
418
|
/** RAM in bytes: Deck and its WebView2 children, plus every claude.exe. */
|
|
412
419
|
export interface MemServer {
|
|
413
420
|
id: string;
|
package/types/core/browser.d.ts
CHANGED
|
@@ -217,6 +217,8 @@ export declare function noteTermOutput(pane: string, chunk: string): void;
|
|
|
217
217
|
export declare function forgetTermPane(pane: string): void;
|
|
218
218
|
/** Where a pane's page is on screen, in Deck's CSS pixels, while it shows one. */
|
|
219
219
|
export declare const pageBox: (pane: string) => DOMRect | null;
|
|
220
|
+
/** The Deck window a pane's page is drawn in: the main one, or a floating tab window's. */
|
|
221
|
+
export declare const paneWindow: (pane: string) => Window;
|
|
220
222
|
/** Close the pane's webview to give back its memory, keeping the tab and its address. */
|
|
221
223
|
export declare function discardBrowserPane(pane: string): Promise<void>;
|
|
222
224
|
export declare function trackBrowser(pane: string, el: HTMLElement, url: string): () => void;
|
|
@@ -45,6 +45,12 @@ export interface LayoutTab {
|
|
|
45
45
|
hidden?: boolean;
|
|
46
46
|
/** The tab group it is in (LayoutWorkspace.groups); a group's tabs sit together in one zone. */
|
|
47
47
|
group?: string;
|
|
48
|
+
/**
|
|
49
|
+
* Torn off into a window of its own (core/floatwin.ts): the window's id. Such a tab is in no
|
|
50
|
+
* zone, though it keeps its x/y to go back to. A restart reopens the window (Layout.floats has
|
|
51
|
+
* where it was).
|
|
52
|
+
*/
|
|
53
|
+
window?: string;
|
|
48
54
|
}
|
|
49
55
|
export interface LayoutWorkspace {
|
|
50
56
|
id: string;
|
|
@@ -57,9 +63,19 @@ export interface LayoutWorkspace {
|
|
|
57
63
|
/** Its colour on the sidebar's collapsed rail, by index (Terminals' TONES); none picks one from the name. */
|
|
58
64
|
color?: number;
|
|
59
65
|
}
|
|
66
|
+
/** Where a floating window was, in physical screen pixels (its size and place before any maximise), to reopen it there. */
|
|
67
|
+
export interface FloatBounds {
|
|
68
|
+
id: string;
|
|
69
|
+
x: number;
|
|
70
|
+
y: number;
|
|
71
|
+
w: number;
|
|
72
|
+
h: number;
|
|
73
|
+
max?: boolean;
|
|
74
|
+
}
|
|
60
75
|
export interface Layout {
|
|
61
76
|
workspaces: LayoutWorkspace[];
|
|
62
77
|
activeWs: string;
|
|
78
|
+
floats?: FloatBounds[];
|
|
63
79
|
}
|
|
64
80
|
export declare function publishLayout(l: Layout): void;
|
|
65
81
|
export declare function getLayout(): Layout | null;
|
|
@@ -202,6 +218,20 @@ export declare function showActiveTab(w: LayoutWorkspace): LayoutWorkspace;
|
|
|
202
218
|
* the zone nor back to its first tab; otherwise the first zone left.
|
|
203
219
|
*/
|
|
204
220
|
export declare function nextActiveAfterClose(tabs: readonly LayoutTab[], closing: string): string | undefined;
|
|
221
|
+
/**
|
|
222
|
+
* Tear a tab off into window `win`, or (`win` undefined) dock it back. A workspace always keeps
|
|
223
|
+
* one docked tab: floating its last one leaves a fresh terminal behind, as the main window has
|
|
224
|
+
* to show something. Tearing off the active tab makes its neighbour active.
|
|
225
|
+
*/
|
|
226
|
+
export declare function setTabWindow(w: LayoutWorkspace, tabId: string, win: string | undefined, keepGroup?: boolean): LayoutWorkspace;
|
|
227
|
+
/**
|
|
228
|
+
* Merge floating window `from`'s tabs into another window: floating window `into`, or (`into`
|
|
229
|
+
* null) the main window, into the active zone of the project it shows. They go in behind the tab
|
|
230
|
+
* that window shows, which stays shown: a tab dropped somewhere does not take you away from the one
|
|
231
|
+
* you were on. The tabs move between projects when the window they land in shows another one's,
|
|
232
|
+
* since a window holds one project's tabs.
|
|
233
|
+
*/
|
|
234
|
+
export declare function mergeWindow(l: Layout, from: string, into: string | null): Layout;
|
|
205
235
|
/** The first free spot on the top row, for a zone created without a position of its own. */
|
|
206
236
|
export declare function nextZoneSpot(tabs: readonly LayoutTab[], cols?: number, rows?: number): {
|
|
207
237
|
x: number;
|
|
@@ -431,6 +461,12 @@ export declare function sendInput(paneId: string, text: string): void;
|
|
|
431
461
|
* layout and re-fires the observer that called us. Measuring first and resizing once — only when
|
|
432
462
|
* the size actually differs — means the observer's next pass finds nothing to do and it settles.
|
|
433
463
|
*/
|
|
464
|
+
/**
|
|
465
|
+
* The terminals drawn in `doc` take its window's scale again: its window moved onto a monitor of
|
|
466
|
+
* other scaling (a floating window reopened where it was, or dragged there). The same hand-over
|
|
467
|
+
* as a move between windows (see attach).
|
|
468
|
+
*/
|
|
469
|
+
export declare function rebindTerminals(doc: Document): void;
|
|
434
470
|
export declare function refit(id: string): void;
|
|
435
471
|
/**
|
|
436
472
|
* Clear the screen, the way the shell expects.
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
// GENERATED by sdk/gen-types.mjs from Deck's source — do not edit.
|
|
2
|
+
type Cleanup = void | (() => void);
|
|
3
|
+
type Hook = (win: Window) => Cleanup;
|
|
4
|
+
/** Every Deck window: the main one, then each floating one. */
|
|
5
|
+
export declare const allWindows: () => Window[];
|
|
6
|
+
/**
|
|
7
|
+
* A Deck window's Tauri label: "main", or a floating window's (floatwin.rs). A floating window is
|
|
8
|
+
* only registered here once its label exists, so every hook can rely on it.
|
|
9
|
+
*/
|
|
10
|
+
export declare function windowLabel(w: Window): string;
|
|
11
|
+
/**
|
|
12
|
+
* Whether `x` is an element, in any Deck window. Not `instanceof Element`: an element in a
|
|
13
|
+
* floating window is an instance of THAT window's Element, so the main window's check is false.
|
|
14
|
+
*/
|
|
15
|
+
export declare function isElement(x: unknown): x is Element;
|
|
16
|
+
/**
|
|
17
|
+
* A ResizeObserver from the window `el` is drawn in. One made by the main window watches an element
|
|
18
|
+
* in a floating window only when the main window next draws, so a terminal opened in a float that
|
|
19
|
+
* waited for its size could sit blank for seconds.
|
|
20
|
+
*/
|
|
21
|
+
export declare function resizeObserverFor(el: Element, cb: ResizeObserverCallback): ResizeObserver;
|
|
22
|
+
/** The window an element is drawn in: the main one, or a floating window's. */
|
|
23
|
+
export declare function winOf(el: Element | null | undefined): Window;
|
|
24
|
+
/**
|
|
25
|
+
* The Deck window the user is in: the one they last clicked, typed or moved focus in. Not
|
|
26
|
+
* document.hasFocus() alone: with a floating window in front, the main window's document still
|
|
27
|
+
* says it has focus too (WebView2, for a popup it opened), so the first match was always main.
|
|
28
|
+
*/
|
|
29
|
+
export declare function activeWindow(): Window;
|
|
30
|
+
/** What has focus in the window the user is in: what `document.activeElement` means in one window. */
|
|
31
|
+
export declare function activeElement(): Element | null;
|
|
32
|
+
/** Run `fn` for every Deck window, now and as floats open; what it returns runs when that window goes, or on the returned unsubscribe. */
|
|
33
|
+
export declare function onEachWindow(fn: Hook): () => void;
|
|
34
|
+
/** A floating window opened (floatwin.ts), its label known: every hook runs for it. */
|
|
35
|
+
export declare function addWindow(win: Window): void;
|
|
36
|
+
/** A floating window is going: what each hook installed in it is undone. */
|
|
37
|
+
export declare function removeWindow(win: Window): void;
|
|
38
|
+
/**
|
|
39
|
+
* Listen on every Deck window (or every window's document), now and as floats open; returns the
|
|
40
|
+
* unsubscribe. For what closes a menu or a dialog wherever the user is: Escape, a click outside.
|
|
41
|
+
*/
|
|
42
|
+
export declare function onAll<K extends keyof WindowEventMap>(type: K, fn: (e: WindowEventMap[K]) => void, opts?: boolean | AddEventListenerOptions, on?: "window" | "document"): () => void;
|
|
43
|
+
/**
|
|
44
|
+
* Make the main realm's `navigator.clipboard` work from every Deck window. The browser refuses a
|
|
45
|
+
* clipboard call from a document that does not have focus ("Document is not focused"), and the
|
|
46
|
+
* realm's clipboard is the MAIN window's: while the user works in a floating window, every copy and
|
|
47
|
+
* paste failed, a terminal's Ctrl+C clearing the selection with nothing copied. Each call now goes
|
|
48
|
+
* to the clipboard of the window the user is in, which is main's own when that is where they are.
|
|
49
|
+
* Installed once, before plugins load, so their copies and pastes get it too.
|
|
50
|
+
*/
|
|
51
|
+
export declare function routeClipboard(): void;
|
|
52
|
+
export {};
|
|
@@ -13,6 +13,12 @@ export declare function fileUri(path: string): monaco.Uri;
|
|
|
13
13
|
export declare function setUntitledLanguage(path: string, id: string | null): void;
|
|
14
14
|
/** Take `path` for `owner`; false when another editor's buffer has it. */
|
|
15
15
|
export declare function claimUntitled(path: string, owner: string): boolean;
|
|
16
|
+
/**
|
|
17
|
+
* Put `value` into `m` as the one edit between their common start and end, rather than replacing
|
|
18
|
+
* the whole text: a cursor outside the change stays where it is. A whole-text replace (setValue, or
|
|
19
|
+
* an edit over the full range) moved every cursor to the top of the file, mid-typing.
|
|
20
|
+
*/
|
|
21
|
+
export declare function replaceText(m: monaco.editor.ITextModel, value: string): void;
|
|
16
22
|
export declare function getFileModel(path: string, initial: string): monaco.editor.ITextModel;
|
|
17
23
|
export declare function setModelValue(path: string, value: string): void;
|
|
18
24
|
export declare function disposeModel(path: string | undefined): void;
|