@septkit/shell-lib 0.0.1

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.
@@ -0,0 +1,2 @@
1
+ export declare const LIBRARY_DB_PREFIX = "SET-LIBRARY-";
2
+ export declare const TEMP_DOCUMENT_PREFIX = "TEMP-";
@@ -0,0 +1,2 @@
1
+ export type * from './types';
2
+ export { LIBRARY_DB_PREFIX, TEMP_DOCUMENT_PREFIX } from './constants';
package/dist/index.js ADDED
@@ -0,0 +1,4 @@
1
+ //#region src/constants.ts
2
+ var e = "SET-LIBRARY-", t = "TEMP-";
3
+ //#endregion
4
+ export { e as LIBRARY_DB_PREFIX, t as TEMP_DOCUMENT_PREFIX };
@@ -0,0 +1,17 @@
1
+ import { Scl } from '@dialecte/scl/v2019C1';
2
+ export interface ShellCommands {
3
+ activateDocument: (documentId: string) => void;
4
+ switchProject: (projectName: string) => Promise<void>;
5
+ onDocumentsChanged: (listener: () => void) => () => void;
6
+ }
7
+ export interface Observable<T> {
8
+ readonly value: T | undefined;
9
+ emit(newValue: T | undefined): void;
10
+ subscribe(listener: (value: T | undefined, prev: T | undefined) => void): () => void;
11
+ }
12
+ export interface ExtensionAPI {
13
+ project: Scl.Project;
14
+ activeFileName: Observable<string>;
15
+ activeDocumentId: Observable<string>;
16
+ commands: ShellCommands;
17
+ }
@@ -0,0 +1 @@
1
+ export type * from './api';
package/package.json ADDED
@@ -0,0 +1,33 @@
1
+ {
2
+ "name": "@septkit/shell-lib",
3
+ "version": "0.0.1",
4
+ "type": "module",
5
+ "files": [
6
+ "dist"
7
+ ],
8
+ "source": "src/index.ts",
9
+ "scripts": {
10
+ "build": "vite build",
11
+ "type-check": "vue-tsc --build",
12
+ "lint": "oxlint . --fix -D correctness --ignore-path .gitignore",
13
+ "format": "prettier --write src/",
14
+ "format:check": "prettier --check src/"
15
+ },
16
+ "exports": {
17
+ ".": {
18
+ "types": "./dist/index.d.ts",
19
+ "import": "./dist/index.js"
20
+ }
21
+ },
22
+ "dependencies": {
23
+ "@dialecte/scl": "^0.2.3"
24
+ },
25
+ "devDependencies": {
26
+ "oxlint": "~1.6.0",
27
+ "prettier": "3.5.3",
28
+ "typescript": "~5.8.3",
29
+ "vite": "^8.0.8",
30
+ "vite-plugin-dts": "^4.5.4",
31
+ "vue-tsc": "^3.2.6"
32
+ }
33
+ }