@innovatorved/code-lab 0.4.0 → 0.6.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/ARCHITECTURE.md +4 -4
- package/CHANGELOG.md +36 -0
- package/README.md +6 -30
- package/dist/code-lab-sql.esm.js +1 -1
- package/dist/code-lab-sql.umd.js +2 -2
- package/dist/code-lab.css +32 -5818
- package/dist/code-lab.d.ts +1 -1
- package/dist/code-lab.esm.js +4655 -64400
- package/dist/code-lab.js +4540 -64286
- package/dist/code-lab.umd.js +4540 -64286
- package/dist/diagnostics.d.ts +3 -0
- package/dist/extensions/cpp.d.ts +2 -2
- package/dist/extensions/cpp.esm.js +1804 -14725
- package/dist/extensions/cpp.js +1804 -14725
- package/dist/extensions/guided-lab.esm.js +2938 -16127
- package/dist/extensions/guided-lab.js +2938 -16127
- package/dist/extensions/python.d.ts +2 -2
- package/dist/extensions/python.esm.js +1765 -14698
- package/dist/extensions/python.js +1765 -14698
- package/dist/index.d.ts +1 -1
- package/dist/packages/settings/src/configuration-service.d.ts +7 -0
- package/dist/packages/settings/src/index.d.ts +1 -1
- package/dist/packages/ui/src/index.d.ts +2 -2
- package/dist/packages/ui/src/plugin-registry.d.ts +1 -0
- package/dist/packages/ui/src/settings-dialog.d.ts +31 -3
- package/dist/packages/ui/src/themes.d.ts +5 -0
- package/dist/preview-sw.js +4 -188
- package/dist/runtime.esm.js +109 -10284
- package/dist/runtime.js +107 -10284
- package/dist/schemas.d.ts +2 -2
- package/dist/schemas.esm.js +2938 -16127
- package/dist/schemas.js +2941 -16130
- package/dist/scm.d.ts +296 -14
- package/dist/shell.esm.js +811 -9178
- package/dist/shell.js +811 -9178
- package/dist/storage.d.ts +56 -0
- package/dist/terminal.esm.js +20 -1347
- package/dist/terminal.js +20 -1347
- package/dist/workbench/command-palette.d.ts +16 -1
- package/dist/workbench/diff-editor.d.ts +27 -1
- package/dist/workbench/icons.d.ts +6 -2
- package/dist/workbench/index.d.ts +33 -1
- package/dist/workbench/intellisense.d.ts +194 -0
- package/dist/workbench/styles.d.ts +1 -1
- package/dist/workbench/xterm-adapter.d.ts +122 -0
- package/package.json +8 -2
- package/packages/commands/package.json +1 -1
- package/packages/core/package.json +1 -1
- package/packages/editor/package.json +1 -1
- package/packages/fs/package.json +1 -1
- package/packages/preview/package.json +1 -1
- package/packages/runtime/package.json +1 -1
- package/packages/settings/package.json +1 -1
- package/packages/settings/src/builtin-schemas.ts +17 -6
- package/packages/settings/src/configuration-service.ts +72 -6
- package/packages/settings/src/index.ts +1 -0
- package/packages/sql/package.json +1 -1
- package/packages/terminal/package.json +1 -1
- package/packages/ui/package.json +1 -1
- package/packages/ui/src/index.ts +4 -0
- package/packages/ui/src/plugin-registry.ts +17 -2
- package/packages/ui/src/settings-dialog.ts +393 -99
- package/packages/ui/src/themes.ts +183 -24
- package/src/code-lab.css +2763 -444
- package/src/diagnostics.ts +139 -7
- package/src/extensions/cpp.ts +337 -71
- package/src/extensions/python.ts +375 -75
- package/src/index.ts +1 -1
- package/src/runtime.ts +272 -43
- package/src/schemas.ts +2 -2
- package/src/scm.ts +2172 -74
- package/src/shell.ts +1999 -193
- package/src/storage.ts +401 -5
- package/src/terminal.ts +148 -12
- package/src/workbench/command-palette.ts +289 -48
- package/src/workbench/diff-editor.ts +240 -78
- package/src/workbench/icons.ts +250 -46
- package/src/workbench/index.ts +7 -1
- package/src/workbench/intellisense.ts +1859 -0
- package/src/workbench/styles.ts +25 -19
- package/src/workbench/xterm-adapter.ts +1566 -0
- package/src/workbench.ts +13446 -3881
package/dist/storage.d.ts
CHANGED
|
@@ -15,6 +15,9 @@ export interface StoredProject {
|
|
|
15
15
|
id: string;
|
|
16
16
|
name: string;
|
|
17
17
|
files: Record<string, string>;
|
|
18
|
+
binaryFiles?: Record<string, Uint8Array | string>;
|
|
19
|
+
gitFiles?: Record<string, Uint8Array | string>;
|
|
20
|
+
gitMeta?: Record<string, unknown>;
|
|
18
21
|
updatedAt: number;
|
|
19
22
|
createdAt?: number;
|
|
20
23
|
entry?: string;
|
|
@@ -33,7 +36,32 @@ export interface WorkspaceStorageOptions {
|
|
|
33
36
|
storagePrefix?: string;
|
|
34
37
|
preferredBackend?: StorageBackendType;
|
|
35
38
|
}
|
|
39
|
+
export type WorkspaceKind = 'blank' | 'repo' | 'demo' | 'custom';
|
|
40
|
+
export interface WorkspaceMeta {
|
|
41
|
+
labId: string;
|
|
42
|
+
title: string;
|
|
43
|
+
kind: WorkspaceKind;
|
|
44
|
+
repo?: string;
|
|
45
|
+
updatedAt: number;
|
|
46
|
+
fileCount?: number;
|
|
47
|
+
}
|
|
48
|
+
export declare const WORKSPACE_REGISTRY_KEY = "codelab:workspace-registry:v1";
|
|
49
|
+
export declare function listWorkspaces(): WorkspaceMeta[];
|
|
50
|
+
export declare function getWorkspaceMeta(labId: string): WorkspaceMeta | null;
|
|
51
|
+
export declare function upsertWorkspaceMeta(meta: WorkspaceMeta): void;
|
|
52
|
+
export declare function removeWorkspaceMeta(labId: string): void;
|
|
53
|
+
export declare function hasWorkspaceData(labId: string): boolean;
|
|
54
|
+
export declare function createBlankWorkspaceId(): string;
|
|
55
|
+
export declare function encodeBase64Bytes(bytes: Uint8Array): string;
|
|
56
|
+
export declare function decodeBase64Bytes(b64: string): Uint8Array;
|
|
36
57
|
export declare class WorkspaceStorage {
|
|
58
|
+
static readonly WORKSPACE_REGISTRY_KEY = "codelab:workspace-registry:v1";
|
|
59
|
+
static readonly listWorkspaces: typeof listWorkspaces;
|
|
60
|
+
static readonly getWorkspaceMeta: typeof getWorkspaceMeta;
|
|
61
|
+
static readonly upsertWorkspaceMeta: typeof upsertWorkspaceMeta;
|
|
62
|
+
static readonly removeWorkspaceMeta: typeof removeWorkspaceMeta;
|
|
63
|
+
static readonly hasWorkspaceData: typeof hasWorkspaceData;
|
|
64
|
+
static readonly createBlankWorkspaceId: typeof createBlankWorkspaceId;
|
|
37
65
|
private readonly dbName;
|
|
38
66
|
private readonly storeName;
|
|
39
67
|
private readonly storagePrefix;
|
|
@@ -48,10 +76,38 @@ export declare class WorkspaceStorage {
|
|
|
48
76
|
loadProject(id: string): Promise<StoredProject | null>;
|
|
49
77
|
listProjects(): Promise<ProjectSummary[]>;
|
|
50
78
|
deleteProject(id: string): Promise<boolean>;
|
|
79
|
+
listWorkspaces(): WorkspaceMeta[];
|
|
80
|
+
getWorkspaceMeta(labId: string): WorkspaceMeta | null;
|
|
81
|
+
upsertWorkspaceMeta(meta: WorkspaceMeta): void;
|
|
82
|
+
removeWorkspaceMeta(labId: string): void;
|
|
83
|
+
hasWorkspaceData(labId: string): boolean;
|
|
84
|
+
createBlankWorkspaceId(): string;
|
|
51
85
|
}
|
|
52
86
|
export declare function createWorkspaceStorage(options?: WorkspaceStorageOptions): WorkspaceStorage;
|
|
87
|
+
export declare const CodeLabWorkspaceStorage: {
|
|
88
|
+
WORKSPACE_REGISTRY_KEY: string;
|
|
89
|
+
WorkspaceStorage: typeof WorkspaceStorage;
|
|
90
|
+
createWorkspaceStorage: typeof createWorkspaceStorage;
|
|
91
|
+
listWorkspaces: typeof listWorkspaces;
|
|
92
|
+
getWorkspaceMeta: typeof getWorkspaceMeta;
|
|
93
|
+
upsertWorkspaceMeta: typeof upsertWorkspaceMeta;
|
|
94
|
+
removeWorkspaceMeta: typeof removeWorkspaceMeta;
|
|
95
|
+
hasWorkspaceData: typeof hasWorkspaceData;
|
|
96
|
+
createBlankWorkspaceId: typeof createBlankWorkspaceId;
|
|
97
|
+
encodeBase64Bytes: typeof encodeBase64Bytes;
|
|
98
|
+
decodeBase64Bytes: typeof decodeBase64Bytes;
|
|
99
|
+
};
|
|
53
100
|
declare const _default: {
|
|
101
|
+
WORKSPACE_REGISTRY_KEY: string;
|
|
54
102
|
WorkspaceStorage: typeof WorkspaceStorage;
|
|
55
103
|
createWorkspaceStorage: typeof createWorkspaceStorage;
|
|
104
|
+
listWorkspaces: typeof listWorkspaces;
|
|
105
|
+
getWorkspaceMeta: typeof getWorkspaceMeta;
|
|
106
|
+
upsertWorkspaceMeta: typeof upsertWorkspaceMeta;
|
|
107
|
+
removeWorkspaceMeta: typeof removeWorkspaceMeta;
|
|
108
|
+
hasWorkspaceData: typeof hasWorkspaceData;
|
|
109
|
+
createBlankWorkspaceId: typeof createBlankWorkspaceId;
|
|
110
|
+
encodeBase64Bytes: typeof encodeBase64Bytes;
|
|
111
|
+
decodeBase64Bytes: typeof decodeBase64Bytes;
|
|
56
112
|
};
|
|
57
113
|
export default _default;
|