@linkdesk/contracts 0.1.35 → 0.1.36
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/linkdesk.d.ts +14 -1
- package/package.json +24 -24
package/linkdesk.d.ts
CHANGED
|
@@ -1931,9 +1931,22 @@ export interface EditorAPI {
|
|
|
1931
1931
|
getDecoration(uri: string): Promise<FileDecoration | null>;
|
|
1932
1932
|
onDidChange(cb: (uris: string[]) => void): () => void;
|
|
1933
1933
|
};
|
|
1934
|
-
/**
|
|
1934
|
+
/**
|
|
1935
|
+
* 文件关联——扩展名→插件 ID(主进程 FileAssociationService 直答)。
|
|
1936
|
+
* T2(第 3 波):`getPluginFor` 升级为覆盖表感知的完整解析(覆盖 → 声明 → 角色,01 §T2.2)——
|
|
1937
|
+
* 三入口(FoldersView/SearchView/intake)同吃 ⇒ F3「一处真相」;`listHandlersFor` = 选择器只读面;
|
|
1938
|
+
* `setDefault` = 覆盖表唯一写口(「设为默认」/「恢复自动」,双向同步)。
|
|
1939
|
+
*/
|
|
1935
1940
|
fileAssociation: {
|
|
1936
1941
|
getPluginFor(ext: string): Promise<string | undefined>;
|
|
1942
|
+
/** 列该扩展名全部声明者+当前默认标记(「打开方式…」选择器数据源,01 §T2.1);无声明者 ⇒ [] */
|
|
1943
|
+
listHandlersFor(ext: string): Promise<Array<{
|
|
1944
|
+
pluginId: string;
|
|
1945
|
+
displayName: string;
|
|
1946
|
+
isCurrent: boolean;
|
|
1947
|
+
}>>;
|
|
1948
|
+
/** 覆盖表唯一写口——`pluginId: null` = 恢复自动(删覆盖键);写后 config:changed 即时广播 */
|
|
1949
|
+
setDefault(ext: string, pluginId: string | null): Promise<void>;
|
|
1937
1950
|
};
|
|
1938
1951
|
/** langDef——语言定义注册表(主进程直答)。只返回可序列化字段(monarch tokenizer 函数主进程侧剥壳) */
|
|
1939
1952
|
langDef: {
|
package/package.json
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@linkdesk/contracts",
|
|
3
|
-
"version": "0.1.
|
|
4
|
-
"description": "LinkDesk 插件契约类型——window.linkdesk.* 全量类型定义(E5.8 契约生成产物)。第三方插件作者唯一合法类型消费路径。",
|
|
5
|
-
"type": "module",
|
|
6
|
-
"types": "./linkdesk.d.ts",
|
|
7
|
-
"files": [
|
|
8
|
-
"linkdesk.d.ts"
|
|
9
|
-
],
|
|
10
|
-
"sideEffects": false,
|
|
11
|
-
"publishConfig": {
|
|
12
|
-
"access": "public"
|
|
13
|
-
},
|
|
14
|
-
"scripts": {
|
|
15
|
-
"prepack": "node ../scripts/generate-contract.mjs"
|
|
16
|
-
},
|
|
17
|
-
"keywords": [
|
|
18
|
-
"linkdesk",
|
|
19
|
-
"plugin",
|
|
20
|
-
"types",
|
|
21
|
-
"contract"
|
|
22
|
-
],
|
|
23
|
-
"license": "MIT"
|
|
24
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "@linkdesk/contracts",
|
|
3
|
+
"version": "0.1.36",
|
|
4
|
+
"description": "LinkDesk 插件契约类型——window.linkdesk.* 全量类型定义(E5.8 契约生成产物)。第三方插件作者唯一合法类型消费路径。",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"types": "./linkdesk.d.ts",
|
|
7
|
+
"files": [
|
|
8
|
+
"linkdesk.d.ts"
|
|
9
|
+
],
|
|
10
|
+
"sideEffects": false,
|
|
11
|
+
"publishConfig": {
|
|
12
|
+
"access": "public"
|
|
13
|
+
},
|
|
14
|
+
"scripts": {
|
|
15
|
+
"prepack": "node ../scripts/generate-contract.mjs"
|
|
16
|
+
},
|
|
17
|
+
"keywords": [
|
|
18
|
+
"linkdesk",
|
|
19
|
+
"plugin",
|
|
20
|
+
"types",
|
|
21
|
+
"contract"
|
|
22
|
+
],
|
|
23
|
+
"license": "MIT"
|
|
24
|
+
}
|