@devframes/plugin-code-server 0.9.12 → 0.9.16
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/dist/node/cli.d.mts +2 -3
- package/dist/node/cli.mjs +1 -1
- package/dist/node/index.d.mts +2 -2
- package/dist/node/index.mjs +1 -1
- package/dist/node/rpc/index.d.mts +2 -3
- package/dist/node/setup.d.mts +8 -8
- package/dist/node/types.d.mts +14 -15
- package/dist/node/vite.d.mts +3 -4
- package/dist/node/vite.mjs +1 -1
- package/dist/{node-vxRsKluL.mjs → node-DofLjzm7.mjs} +1 -1
- package/package.json +14 -14
package/dist/node/cli.d.mts
CHANGED
|
@@ -6,6 +6,5 @@ import { CacHandle, CreateCacOptions } from "devframe/adapters/cac";
|
|
|
6
6
|
* `mcp` subcommands, backed by {@link createCodeServerDevframe}. Used by the package
|
|
7
7
|
* `bin` (`devframe-code-server`).
|
|
8
8
|
*/
|
|
9
|
-
declare function createCodeServerCli(options?: CodeServerOptions, cliOptions?: CreateCacOptions): CacHandle;
|
|
10
|
-
//#endregion
|
|
11
|
-
export { createCodeServerCli };
|
|
9
|
+
export declare function createCodeServerCli(options?: CodeServerOptions, cliOptions?: CreateCacOptions): CacHandle;
|
|
10
|
+
//#endregion
|
package/dist/node/cli.mjs
CHANGED
package/dist/node/index.d.mts
CHANGED
|
@@ -18,6 +18,6 @@ import { DevframeDefinition } from "devframe";
|
|
|
18
18
|
* export default createCodeServerDevframe({ serverPort: 8080 })
|
|
19
19
|
* ```
|
|
20
20
|
*/
|
|
21
|
-
declare function createCodeServerDevframe(options?: CodeServerOptions): DevframeDefinition;
|
|
21
|
+
export declare function createCodeServerDevframe(options?: CodeServerOptions): DevframeDefinition;
|
|
22
22
|
//#endregion
|
|
23
|
-
export { type CodeServerBackend, type CodeServerConnect, type CodeServerDetection, type CodeServerLogin, type CodeServerMode, type CodeServerOptions, type CodeServerServerInfo, type CodeServerSharedState, type CodeServerStartRequest, type CodeServerStartResult, type CodeServerStatus, type CodeServerStatusResult, type CodeServerTunnelOptions, DEFAULT_CODE_SERVER_PORT, DEFAULT_PORT, PLUGIN_ID, STATE_KEY, createCodeServerDevframe
|
|
23
|
+
export { type CodeServerBackend, type CodeServerConnect, type CodeServerDetection, type CodeServerLogin, type CodeServerMode, type CodeServerOptions, type CodeServerServerInfo, type CodeServerSharedState, type CodeServerStartRequest, type CodeServerStartResult, type CodeServerStatus, type CodeServerStatusResult, type CodeServerTunnelOptions, DEFAULT_CODE_SERVER_PORT, DEFAULT_PORT, PLUGIN_ID, STATE_KEY, createCodeServerDevframe as default, getCookieSessionName };
|
package/dist/node/index.mjs
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { t as createCodeServerDevframe } from "../node-
|
|
1
|
+
import { t as createCodeServerDevframe } from "../node-DofLjzm7.mjs";
|
|
2
2
|
import { DEFAULT_CODE_SERVER_PORT, DEFAULT_PORT, PLUGIN_ID, STATE_KEY, getCookieSessionName } from "./constants.mjs";
|
|
3
3
|
export { DEFAULT_CODE_SERVER_PORT, DEFAULT_PORT, PLUGIN_ID, STATE_KEY, createCodeServerDevframe, createCodeServerDevframe as default, getCookieSessionName };
|
|
@@ -2,7 +2,7 @@ import { CodeServerDetection, CodeServerSharedState, CodeServerStartRequest, Cod
|
|
|
2
2
|
import "../index.mjs";
|
|
3
3
|
import { RpcDefinitionsToFunctions } from "devframe/rpc";
|
|
4
4
|
//#region src/node/rpc/index.d.ts
|
|
5
|
-
declare const serverFunctions: readonly [{
|
|
5
|
+
export declare const serverFunctions: readonly [{
|
|
6
6
|
name: "devframes:plugin:code-server:detect";
|
|
7
7
|
type?: "query" | undefined;
|
|
8
8
|
cacheable?: boolean;
|
|
@@ -65,5 +65,4 @@ declare module 'devframe' {
|
|
|
65
65
|
'devframes:plugin:code-server:state': CodeServerSharedState;
|
|
66
66
|
}
|
|
67
67
|
}
|
|
68
|
-
//#endregion
|
|
69
|
-
export { serverFunctions };
|
|
68
|
+
//#endregion
|
package/dist/node/setup.d.mts
CHANGED
|
@@ -12,7 +12,7 @@ import { DevframeNodeContext } from "devframe";
|
|
|
12
12
|
*
|
|
13
13
|
* Depends only on the core devframe context (shared state), not on the hub.
|
|
14
14
|
*/
|
|
15
|
-
declare class CodeServerSupervisor {
|
|
15
|
+
export declare class CodeServerSupervisor {
|
|
16
16
|
private readonly ctx;
|
|
17
17
|
private readonly mode;
|
|
18
18
|
private readonly explicitBackend?;
|
|
@@ -197,11 +197,11 @@ interface CodeServerProfile {
|
|
|
197
197
|
}) => CodeServerConnect;
|
|
198
198
|
}
|
|
199
199
|
/** Resolve the launch profile for a mode + backend. */
|
|
200
|
-
declare function resolveProfile(mode: CodeServerMode, backend: CodeServerBackend): CodeServerProfile;
|
|
200
|
+
export declare function resolveProfile(mode: CodeServerMode, backend: CodeServerBackend): CodeServerProfile;
|
|
201
201
|
//#endregion
|
|
202
202
|
//#region src/node/context.d.ts
|
|
203
|
-
declare function setCodeServerSupervisor(ctx: DevframeNodeContext, supervisor: CodeServerSupervisor): void;
|
|
204
|
-
declare function getCodeServerSupervisor(ctx: DevframeNodeContext): CodeServerSupervisor;
|
|
203
|
+
export declare function setCodeServerSupervisor(ctx: DevframeNodeContext, supervisor: CodeServerSupervisor): void;
|
|
204
|
+
export declare function getCodeServerSupervisor(ctx: DevframeNodeContext): CodeServerSupervisor;
|
|
205
205
|
//#endregion
|
|
206
206
|
//#region src/node/detect.d.ts
|
|
207
207
|
interface DetectCodeServerResult {
|
|
@@ -221,7 +221,7 @@ interface DetectCodeServerResult {
|
|
|
221
221
|
* noise (e.g. an `i18next: …` initialization line printed before the version)
|
|
222
222
|
* from leaking into the reported version.
|
|
223
223
|
*/
|
|
224
|
-
declare function detectCodeServer(bin?: string, timeoutMs?: number): Promise<DetectCodeServerResult>;
|
|
224
|
+
export declare function detectCodeServer(bin?: string, timeoutMs?: number): Promise<DetectCodeServerResult>;
|
|
225
225
|
//#endregion
|
|
226
226
|
//#region ../../node_modules/.pnpm/nostics@1.2.0/node_modules/nostics/dist/diagnostic-wduO7saY.d.mts
|
|
227
227
|
//#region src/utils.d.ts
|
|
@@ -457,7 +457,7 @@ type ExtractReportersOptions<Reporters extends readonly any[]> = Reporters exten
|
|
|
457
457
|
* `DP_CODE_SERVER_` prefix per the built-in plugin convention, keeping it
|
|
458
458
|
* collision-free with devframe core (`DF`) and the hub (`DF8xxx`).
|
|
459
459
|
*/
|
|
460
|
-
declare const diagnostics: Diagnostics<{
|
|
460
|
+
export declare const diagnostics: Diagnostics<{
|
|
461
461
|
readonly DP_CODE_SERVER_0001: {
|
|
462
462
|
readonly why: (p: {
|
|
463
463
|
bin: string;
|
|
@@ -507,6 +507,6 @@ declare const diagnostics: Diagnostics<{
|
|
|
507
507
|
* Works in any devframe runtime (CLI, Vite, embedded, build), since it only relies
|
|
508
508
|
* on the core `ctx.rpc` shared-state surface, not on the hub.
|
|
509
509
|
*/
|
|
510
|
-
declare function setupCodeServer(ctx: DevframeNodeContext, options?: CodeServerOptions): Promise<CodeServerSupervisor>;
|
|
510
|
+
export declare function setupCodeServer(ctx: DevframeNodeContext, options?: CodeServerOptions): Promise<CodeServerSupervisor>;
|
|
511
511
|
//#endregion
|
|
512
|
-
export {
|
|
512
|
+
export type { CodeServerProfile, CodeServerProfileKind };
|
package/dist/node/types.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
//#region src/node/types.d.ts
|
|
2
2
|
/** Lifecycle state of the managed editor process. */
|
|
3
|
-
type CodeServerStatus = 'stopped' | 'starting' | 'running' | 'error';
|
|
3
|
+
export type CodeServerStatus = 'stopped' | 'starting' | 'running' | 'error';
|
|
4
4
|
/**
|
|
5
5
|
* Which editor server binary the plugin launches in `mode: 'local'`:
|
|
6
6
|
*
|
|
@@ -13,7 +13,7 @@ type CodeServerStatus = 'stopped' | 'starting' | 'running' | 'error';
|
|
|
13
13
|
* (ships with the `code` CLI). The plugin generates a connection token and
|
|
14
14
|
* hands it to the client as a `?tkn=` query parameter.
|
|
15
15
|
*/
|
|
16
|
-
type CodeServerBackend = 'code-server' | 'ms-code-serve-web';
|
|
16
|
+
export type CodeServerBackend = 'code-server' | 'ms-code-serve-web';
|
|
17
17
|
/**
|
|
18
18
|
* How the editor is served:
|
|
19
19
|
*
|
|
@@ -24,13 +24,13 @@ type CodeServerBackend = 'code-server' | 'ms-code-serve-web';
|
|
|
24
24
|
* prompt (surfaced as {@link CodeServerLogin}); authentication is handled by
|
|
25
25
|
* `vscode.dev` itself, not this plugin.
|
|
26
26
|
*/
|
|
27
|
-
type CodeServerMode = 'local' | 'tunnel';
|
|
27
|
+
export type CodeServerMode = 'local' | 'tunnel';
|
|
28
28
|
/**
|
|
29
29
|
* Result of probing the host for a usable editor binary. Drives the launcher
|
|
30
30
|
* UI: when `installed` is false the SPA renders install instructions instead of
|
|
31
31
|
* a launch button.
|
|
32
32
|
*/
|
|
33
|
-
interface CodeServerDetection {
|
|
33
|
+
export interface CodeServerDetection {
|
|
34
34
|
/** Whether detection has run at least once on this context. */
|
|
35
35
|
checked: boolean;
|
|
36
36
|
/** Whether the resolved binary reported a version. */
|
|
@@ -48,14 +48,14 @@ interface CodeServerDetection {
|
|
|
48
48
|
* A device-login prompt emitted by `code tunnel` on first launch. Surfaced to
|
|
49
49
|
* the client so the user can complete authentication in their browser.
|
|
50
50
|
*/
|
|
51
|
-
interface CodeServerLogin {
|
|
51
|
+
export interface CodeServerLogin {
|
|
52
52
|
/** The verification URL to open (e.g. `https://github.com/login/device`). */
|
|
53
53
|
url: string;
|
|
54
54
|
/** The one-time code to enter there. */
|
|
55
55
|
code: string;
|
|
56
56
|
}
|
|
57
57
|
/** Serializable, secret-free description of the editor process. */
|
|
58
|
-
interface CodeServerServerInfo {
|
|
58
|
+
export interface CodeServerServerInfo {
|
|
59
59
|
status: CodeServerStatus;
|
|
60
60
|
/** Port the local server is bound to, when starting/running. */
|
|
61
61
|
port?: number;
|
|
@@ -80,7 +80,7 @@ interface CodeServerServerInfo {
|
|
|
80
80
|
* The full shared-state payload broadcast to subscribed clients. Deliberately
|
|
81
81
|
* carries no authentication material; see {@link CodeServerConnect}.
|
|
82
82
|
*/
|
|
83
|
-
interface CodeServerSharedState {
|
|
83
|
+
export interface CodeServerSharedState {
|
|
84
84
|
detection: CodeServerDetection;
|
|
85
85
|
server: CodeServerServerInfo;
|
|
86
86
|
}
|
|
@@ -95,7 +95,7 @@ interface CodeServerSharedState {
|
|
|
95
95
|
* `cookie` is present, sets it (cookies are port-agnostic, so a cookie set on
|
|
96
96
|
* the launcher's origin reaches the editor on its own port) before loading.
|
|
97
97
|
*/
|
|
98
|
-
interface CodeServerConnect {
|
|
98
|
+
export interface CodeServerConnect {
|
|
99
99
|
/** Absolute URL to embed. When set, used verbatim (tunnel mode). */
|
|
100
100
|
url?: string;
|
|
101
101
|
/** Path + query to open relative to the editor origin (local mode). */
|
|
@@ -107,18 +107,18 @@ interface CodeServerConnect {
|
|
|
107
107
|
};
|
|
108
108
|
}
|
|
109
109
|
/** Result of the `status` query: shared state plus connect info when running. */
|
|
110
|
-
interface CodeServerStatusResult extends CodeServerSharedState {
|
|
110
|
+
export interface CodeServerStatusResult extends CodeServerSharedState {
|
|
111
111
|
connect?: CodeServerConnect;
|
|
112
112
|
}
|
|
113
113
|
/** Result of the `start` action, identical shape to {@link CodeServerStatusResult}. */
|
|
114
|
-
type CodeServerStartResult = CodeServerStatusResult;
|
|
114
|
+
export type CodeServerStartResult = CodeServerStatusResult;
|
|
115
115
|
/** Wire payload for the `start` RPC. */
|
|
116
|
-
interface CodeServerStartRequest {
|
|
116
|
+
export interface CodeServerStartRequest {
|
|
117
117
|
/** Workspace folder to open. Defaults to the configured / context cwd. */
|
|
118
118
|
folder?: string;
|
|
119
119
|
}
|
|
120
120
|
/** Options accepted by {@link import('./index').createCodeServerDevframe}. */
|
|
121
|
-
interface CodeServerOptions {
|
|
121
|
+
export interface CodeServerOptions {
|
|
122
122
|
/**
|
|
123
123
|
* How the editor is served (default `'local'`). `'tunnel'` uses Microsoft's
|
|
124
124
|
* `code tunnel` and embeds `vscode.dev`.
|
|
@@ -184,12 +184,11 @@ interface CodeServerOptions {
|
|
|
184
184
|
auth?: boolean;
|
|
185
185
|
}
|
|
186
186
|
/** Options for `mode: 'tunnel'`. */
|
|
187
|
-
interface CodeServerTunnelOptions {
|
|
187
|
+
export interface CodeServerTunnelOptions {
|
|
188
188
|
/**
|
|
189
189
|
* The machine name registered with the tunnel service and used to build the
|
|
190
190
|
* `vscode.dev/tunnel/<name>` URL. Defaults to the device hostname.
|
|
191
191
|
*/
|
|
192
192
|
name?: string;
|
|
193
193
|
}
|
|
194
|
-
//#endregion
|
|
195
|
-
export { CodeServerBackend, CodeServerConnect, CodeServerDetection, CodeServerLogin, CodeServerMode, CodeServerOptions, CodeServerServerInfo, CodeServerSharedState, CodeServerStartRequest, CodeServerStartResult, CodeServerStatus, CodeServerStatusResult, CodeServerTunnelOptions };
|
|
194
|
+
//#endregion
|
package/dist/node/vite.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { CodeServerOptions } from "./types.mjs";
|
|
2
2
|
import { DevframeViteBridgeOptions, DevframeVitePlugin } from "@devframes/vite/single";
|
|
3
3
|
//#region src/node/vite.d.ts
|
|
4
|
-
interface CodeServerViteOptions extends CodeServerOptions {
|
|
4
|
+
export interface CodeServerViteOptions extends CodeServerOptions {
|
|
5
5
|
/** Forwarded to the underlying `devframeViteBridge`/`devframeVitePlugin` (mount base, etc.). */
|
|
6
6
|
vite?: DevframeViteBridgeOptions;
|
|
7
7
|
}
|
|
@@ -12,6 +12,5 @@ interface CodeServerViteOptions extends CodeServerOptions {
|
|
|
12
12
|
* the bundled SPA at the mount base. The bridge is listed first so its
|
|
13
13
|
* `__connection.json` route is matched ahead of the SPA fallback.
|
|
14
14
|
*/
|
|
15
|
-
declare function codeServerVite(options?: CodeServerViteOptions): DevframeVitePlugin[];
|
|
16
|
-
//#endregion
|
|
17
|
-
export { CodeServerViteOptions, codeServerVite };
|
|
15
|
+
export declare function codeServerVite(options?: CodeServerViteOptions): DevframeVitePlugin[];
|
|
16
|
+
//#endregion
|
package/dist/node/vite.mjs
CHANGED
|
@@ -2,7 +2,7 @@ import { PLUGIN_ID } from "./node/constants.mjs";
|
|
|
2
2
|
import { defineDevframe } from "devframe";
|
|
3
3
|
//#region package.json
|
|
4
4
|
var name = "@devframes/plugin-code-server";
|
|
5
|
-
var version = "0.9.
|
|
5
|
+
var version = "0.9.16";
|
|
6
6
|
var description = "Devframe plugin that runs VS Code in the browser as an embedded editor panel.";
|
|
7
7
|
var homepage = "https://github.com/devframes/devframe#readme";
|
|
8
8
|
//#endregion
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@devframes/plugin-code-server",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.9.
|
|
4
|
+
"version": "0.9.16",
|
|
5
5
|
"description": "Devframe plugin that runs VS Code in the browser as an embedded editor panel.",
|
|
6
6
|
"author": "Anthony Fu <anthonyfu117@hotmail.com>",
|
|
7
7
|
"license": "MIT",
|
|
@@ -39,8 +39,8 @@
|
|
|
39
39
|
"dist"
|
|
40
40
|
],
|
|
41
41
|
"peerDependencies": {
|
|
42
|
-
"@devframes/plugin-code-server--assets": "0.9.
|
|
43
|
-
"devframe": "0.9.
|
|
42
|
+
"@devframes/plugin-code-server--assets": "0.9.16",
|
|
43
|
+
"devframe": "0.9.16",
|
|
44
44
|
"vite": "^8.0.0"
|
|
45
45
|
},
|
|
46
46
|
"peerDependenciesMeta": {
|
|
@@ -52,26 +52,26 @@
|
|
|
52
52
|
}
|
|
53
53
|
},
|
|
54
54
|
"dependencies": {
|
|
55
|
-
"@devframes/vite": "0.9.
|
|
55
|
+
"@devframes/vite": "0.9.16",
|
|
56
56
|
"cac": "^7.0.0"
|
|
57
57
|
},
|
|
58
58
|
"devDependencies": {
|
|
59
59
|
"@antfu/design": "^0.4.0",
|
|
60
|
-
"@devframes/plugin-code-server--assets": "0.9.
|
|
60
|
+
"@devframes/plugin-code-server--assets": "0.9.16",
|
|
61
61
|
"@iconify-json/ph": "^1.2.2",
|
|
62
|
-
"@storybook/addon-docs": "^10.
|
|
63
|
-
"@storybook/vue3-vite": "^10.
|
|
64
|
-
"@types/node": "^26.
|
|
62
|
+
"@storybook/addon-docs": "^10.6.0",
|
|
63
|
+
"@storybook/vue3-vite": "^10.6.0",
|
|
64
|
+
"@types/node": "^26.5.0",
|
|
65
65
|
"@vitejs/plugin-vue": "^6.0.8",
|
|
66
66
|
"colorjs.io": "^0.7.1",
|
|
67
|
-
"devframe": "0.9.
|
|
68
|
-
"h3": "^2.0.1-rc.
|
|
67
|
+
"devframe": "0.9.16",
|
|
68
|
+
"h3": "^2.0.1-rc.31",
|
|
69
69
|
"pathe": "^2.0.3",
|
|
70
|
-
"storybook": "^10.
|
|
71
|
-
"tsdown": "^0.
|
|
72
|
-
"unocss": "^66.
|
|
70
|
+
"storybook": "^10.6.0",
|
|
71
|
+
"tsdown": "^0.23.0",
|
|
72
|
+
"unocss": "^66.10.0",
|
|
73
73
|
"vite": "^8.2.2",
|
|
74
|
-
"vitest": "^
|
|
74
|
+
"vitest": "^5.0.0",
|
|
75
75
|
"vue": "^3.5.42"
|
|
76
76
|
},
|
|
77
77
|
"scripts": {
|