@khorsheed/dsh-file-preview 0.4.1 → 0.4.2

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 CHANGED
@@ -7,7 +7,7 @@
7
7
  "cordis",
8
8
  "file-preview"
9
9
  ],
10
- "version": "0.4.1",
10
+ "version": "0.4.2",
11
11
  "type": "module",
12
12
  "main": "lib/index.js",
13
13
  "types": "lib/types/index.d.ts",
@@ -16,10 +16,6 @@
16
16
  "types": "./lib/types/index.d.ts",
17
17
  "default": "./lib/index.js"
18
18
  },
19
- "./invariant": {
20
- "types": "./lib/types/invariant.d.ts",
21
- "default": "./lib/invariant.js"
22
- },
23
19
  "./types": {
24
20
  "types": "./lib/types/types.d.ts",
25
21
  "default": "./lib/types/types.js"
@@ -52,21 +48,23 @@
52
48
  "CHANGELOG.md"
53
49
  ],
54
50
  "license": "MIT",
51
+ "engines": {
52
+ "dsh": ">=0.1.5-rc.1 <0.3.0-0"
53
+ },
55
54
  "peerDependencies": {
56
55
  "@deepseek-ai/cordis": "^4.0.1",
57
- "@deepseek-ai/dsh-agent": "^0.1.0-rc.6 || ^0.2.0-rc.1",
58
- "@deepseek-ai/dsh-api-remotes": "^0.1.0-rc.6 || ^0.2.0-rc.1",
59
- "@deepseek-ai/dsh-client-locale": "^0.1.0-rc.6 || ^0.2.0-rc.1",
60
- "@deepseek-ai/dsh-client-ui-chat": "^0.1.0-rc.6 || ^0.2.0-rc.1",
61
- "@deepseek-ai/dsh-client-ui-primitives": "^0.1.0-rc.6 || ^0.2.0-rc.1",
62
- "@deepseek-ai/dsh-client-ui-sidebar-right": "^0.1.7-rc.1 || ^0.2.0-rc.1",
63
- "@deepseek-ai/dsh-client-ui-slots": "^0.1.0-rc.6 || ^0.2.0-rc.1",
64
- "@deepseek-ai/dsh-fs": "^0.1.0-rc.6 || ^0.2.0-rc.1",
65
- "@deepseek-ai/dsh-invariants": "^0.1.0-rc.6 || ^0.2.0-rc.1",
66
- "@deepseek-ai/dsh-native-command": "^0.1.0-rc.6 || ^0.2.0-rc.1",
67
- "@deepseek-ai/dsh-session": "^0.1.0-rc.6 || ^0.2.0-rc.1",
68
- "@deepseek-ai/dsh-tools": "^0.1.0-rc.6 || ^0.2.0-rc.1",
69
- "@deepseek-ai/dsh-typert-protocol": "^0.1.0-rc.6 || ^0.2.0-rc.1",
56
+ "@deepseek-ai/dsh-agent": "^0.1.0-rc.6 || ^0.2.0-rc.1 || ^0.2.1-rc.1",
57
+ "@deepseek-ai/dsh-api-remotes": "^0.1.0-rc.6 || ^0.2.0-rc.1 || ^0.2.1-rc.1",
58
+ "@deepseek-ai/dsh-client-locale": "^0.1.0-rc.6 || ^0.2.0-rc.1 || ^0.2.1-rc.1",
59
+ "@deepseek-ai/dsh-client-ui-chat": "^0.1.0-rc.6 || ^0.2.0-rc.1 || ^0.2.1-rc.1",
60
+ "@deepseek-ai/dsh-client-ui-primitives": "^0.1.0-rc.6 || ^0.2.0-rc.1 || ^0.2.1-rc.1",
61
+ "@deepseek-ai/dsh-client-ui-sidebar-right": "^0.1.7-rc.1 || ^0.2.0-rc.1 || ^0.2.1-rc.1",
62
+ "@deepseek-ai/dsh-client-ui-slots": "^0.1.0-rc.6 || ^0.2.0-rc.1 || ^0.2.1-rc.1",
63
+ "@deepseek-ai/dsh-fs": "^0.1.0-rc.6 || ^0.2.0-rc.1 || ^0.2.1-rc.1",
64
+ "@deepseek-ai/dsh-native-command": "^0.1.0-rc.6 || ^0.2.0-rc.1 || ^0.2.1-rc.1",
65
+ "@deepseek-ai/dsh-session": "^0.1.0-rc.6 || ^0.2.0-rc.1 || ^0.2.1-rc.1",
66
+ "@deepseek-ai/dsh-tools": "^0.1.0-rc.6 || ^0.2.0-rc.1 || ^0.2.1-rc.1",
67
+ "@deepseek-ai/dsh-typert-protocol": "^0.1.0-rc.6 || ^0.2.0-rc.1 || ^0.2.1-rc.1",
70
68
  "react": "^18.2.0",
71
69
  "react-dom": "^18.2.0"
72
70
  },
@@ -117,7 +115,7 @@
117
115
  },
118
116
  "compat": {
119
117
  "minHost": "0.1.5-rc.1",
120
- "verifiedHost": "0.1.5-rc.1",
118
+ "verifiedHost": "0.2.1-rc.1",
121
119
  "notes": "单一形态双线一致:自建「会话产物」page 型右栏 tab(向导页进入 + extension 档认领 dsh-resource://file/** 可渲染后缀,压过官方 document tab 的 fallback 档——rc.1 的 tab-registry 保留 band 机制),文件树/mention/回合卡/产物行点击全部落自绘详情页(共享内容面板全 chrome + 内容/改动记录切换 + 复制路径/在文件夹/IDE 打开);pdf/压缩包/二进制等 decline 后缀落回官方 document tab。方案 B(内容面注册进官方 documentPreviews 面做默认渲染器)与二期 headless 嵌入已于 2026-09-24 同日被仓主否决回退——接缝成本(renderer loading 协议/extension 档语义/headless 布局耦合)与 UX 妥协(改动记录塞进渲染器下拉、复制钮浮动压搜索行)不成立;改动记录维度(TurnFileRow + 详情页 DiffHistory)官方仍无对应物(workspace-changes 内存态、git-only、重启即失),维持自留并跟踪上游。turnTail 回合卡照常:0.1.6-alpha.2 起 list 槽臂同时注册官方 deliverables 条目的一等遮蔽(同 cell id、priority -1 空体胜出,官方条目在册故其子槽不塌),0.1.5 chain 槽臂保持 select + priority -1 抢占回退——均不涉及 rc.1 专有 API,minHost 不动。0.4.0 起宿主 Remote 与浏览器半同包(ui-file-preview 并入),headless 组合只装宿主半照常工作(client 面在 web 组合里经 dsh.client 发现)。"
122
120
  }
123
121
  }
package/lib/invariant.js DELETED
@@ -1,25 +0,0 @@
1
- //#region lib/types/invariant.js
2
- /**
3
- * Package-owned invariant companion for `@khorsheed/dsh-file-preview`.
4
- * @module @khorsheed/dsh-file-preview/invariant
5
- */
6
- const PACKAGE_NAME = "@khorsheed/dsh-file-preview";
7
- /** Cordis companion plugin name. */
8
- const name = "file-preview-invariant";
9
- /** Service required before the companion can reserve package ownership. */
10
- const inject = ["invariants"];
11
- /**
12
- * No runtime invariant: the service owns no durable package-local state and
13
- * writes nothing — `list` is a pure deterministic fold over the session log
14
- * (unit-tested), and `read` re-reads the filesystem through `ctx.fs`, whose
15
- * own invariants own that relationship.
16
- */
17
- const install = () => {};
18
- /**
19
- * Register this package's invariant companion.
20
- * @param ctx - Cordis context carrying the invariant service.
21
- * @returns the installed registration's disposer after setup succeeds.
22
- */
23
- const apply = (ctx) => Promise.resolve(ctx.invariants.register(PACKAGE_NAME, install));
24
- //#endregion
25
- export { apply, inject, name };
@@ -1,16 +0,0 @@
1
- /**
2
- * Package-owned invariant companion for `@khorsheed/dsh-file-preview`.
3
- * @module @khorsheed/dsh-file-preview/invariant
4
- */
5
- import type { Context } from '@deepseek-ai/cordis';
6
- /** Cordis companion plugin name. */
7
- export declare const name = "file-preview-invariant";
8
- /** Service required before the companion can reserve package ownership. */
9
- export declare const inject: string[];
10
- /**
11
- * Register this package's invariant companion.
12
- * @param ctx - Cordis context carrying the invariant service.
13
- * @returns the installed registration's disposer after setup succeeds.
14
- */
15
- export declare const apply: (ctx: Context) => Promise<() => void>;
16
- //# sourceMappingURL=invariant.d.ts.map
@@ -1,23 +0,0 @@
1
- /**
2
- * Package-owned invariant companion for `@khorsheed/dsh-file-preview`.
3
- * @module @khorsheed/dsh-file-preview/invariant
4
- */
5
- const PACKAGE_NAME = '@khorsheed/dsh-file-preview';
6
- /** Cordis companion plugin name. */
7
- export const name = 'file-preview-invariant';
8
- /** Service required before the companion can reserve package ownership. */
9
- export const inject = ['invariants'];
10
- /**
11
- * No runtime invariant: the service owns no durable package-local state and
12
- * writes nothing — `list` is a pure deterministic fold over the session log
13
- * (unit-tested), and `read` re-reads the filesystem through `ctx.fs`, whose
14
- * own invariants own that relationship.
15
- */
16
- const install = () => { };
17
- /**
18
- * Register this package's invariant companion.
19
- * @param ctx - Cordis context carrying the invariant service.
20
- * @returns the installed registration's disposer after setup succeeds.
21
- */
22
- export const apply = (ctx) => Promise.resolve(ctx.invariants.register(PACKAGE_NAME, install));
23
- /* jscpd:ignore-end */