@jcy2387/dsh-conversation-ui 0.1.0-rc.12 → 0.1.2-alpha.3
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/README.en.md +8 -9
- package/README.md +7 -8
- package/lib/client.js +1339 -1183
- package/lib/client.js.map +1 -1
- package/lib/index.js +4 -5
- package/package.json +54 -32
- package/src/client/CodexTurnProcessNodeView.tsx +143 -0
- package/src/client/DeliverablesCard.tsx +1 -1
- package/src/client/FollowHost.tsx +13 -7
- package/src/client/ToolActivityGroup.tsx +52 -90
- package/src/client/TranscriptViewBridge.tsx +26 -0
- package/src/client/TurnPreludeUserNodeView.tsx +80 -202
- package/src/client/TypewriterAssistantNodeView.module.css +54 -54
- package/src/client/TypewriterAssistantNodeView.tsx +96 -103
- package/src/client/TypewriterToolNodeView.tsx +94 -179
- package/src/client/conversation-ui-card-controller.ts +1 -1
- package/src/client/deliverables.ts +31 -43
- package/src/client/index.ts +58 -12
- package/src/client/turnElapsed.ts +1 -1
- package/src/client/turnProcessFallback.ts +90 -0
- package/src/client/useChatSeatHidden.ts +91 -0
- package/src/client/useSearchableHidden.ts +23 -0
- package/src/config.ts +3 -6
- package/src/plugin.ts +4 -6
- package/src/client/TurnProcessMember.tsx +0 -92
- package/src/client/teleprompterGlide.ts +0 -590
- package/src/client/turnProcessFold.ts +0 -224
package/README.en.md
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
English | [简体中文](README.md)
|
|
7
7
|
|
|
8
|
-
A Codex-style conversation UI enhancement plugin for DeepSeek Harness (DSH): the Web chat is re-rendered as one ordered event stream — process updates, thinking, tool activity, retries, workflows, and the final answer appear in the order they happened, while
|
|
8
|
+
A Codex-style conversation UI enhancement plugin for DeepSeek Harness (DSH): the Web chat is re-rendered as one ordered event stream — process updates, thinking, tool activity, retries, workflows, and the final answer appear in the order they happened, while DSH retains authoritative viewport control. This package is the Conversation UI package of the [DSH Codex Suite](../../README.md) monorepo.
|
|
9
9
|
|
|
10
10
|
**The package is fully independent from the Codex Provider** and can be installed alone to enhance conversations with any model.
|
|
11
11
|
|
|
@@ -25,16 +25,15 @@ A Codex-style conversation UI enhancement plugin for DeepSeek Harness (DSH): the
|
|
|
25
25
|
|
|
26
26
|
| Mode | Behavior |
|
|
27
27
|
| --- | --- |
|
|
28
|
-
| `teleprompter` (default) |
|
|
28
|
+
| `teleprompter` (default) | The latest model snapshot appears immediately, with no extra character-reveal queue. |
|
|
29
29
|
| `typewriter` | Progressive reveal by grapheme cluster, safe for CJK text and emoji. |
|
|
30
30
|
|
|
31
31
|
- Three smoothing presets: `realtime` (snappier), `balanced` (default), `silky` (extra smooth). Presets shape the reveal cadence — EMA-smoothed arrival rate, buffer targets, catch-up ceilings, and the settle drain after the input idles — so long replies never dump whole paragraphs at once and fast streams never stutter.
|
|
32
32
|
- `typewriter` mode also exposes a fixed reveal rate via `revealCharsPerSec`.
|
|
33
33
|
|
|
34
|
-
###
|
|
34
|
+
### Streaming viewport cooperation
|
|
35
35
|
|
|
36
|
-
-
|
|
37
|
-
- Scrolling upward to read **releases the follow**; returning to the bottom resumes it.
|
|
36
|
+
- Current DSH `ChatView` exclusively owns per-session restoration, bottom-follow, and reader unpinning. The plugin no longer writes `scrollTop` or row transforms, avoiding ownership races during session switches.
|
|
38
37
|
- Respects `prefers-reduced-motion`; when the frame rate degrades, an FPS guard skips DOM commits for offscreen replies so visible frames stay fluid.
|
|
39
38
|
|
|
40
39
|
### Deliverables card
|
|
@@ -76,8 +75,8 @@ Profile patch ID: `conversation-ui`. Set values in the profile's `cordis.patch.y
|
|
|
76
75
|
| `mode` | `teleprompter` \| `typewriter` | `teleprompter` | Reveal style of assistant content. |
|
|
77
76
|
| `preset` | `realtime` \| `balanced` \| `silky` | `balanced` | Smoothing cadence preset. |
|
|
78
77
|
| `revealCharsPerSec` | 5–200 | `80` | Fixed reveal rate for `typewriter` mode. |
|
|
79
|
-
| `scrollSpeedPxPerSec` | 1–200 | `48` |
|
|
80
|
-
| `maxScrollSpeedPxPerSec` | 1–2000 | `1000` |
|
|
78
|
+
| `scrollSpeedPxPerSec` | 1–200 | `48` | Deprecated; retained for old Profile compatibility. DSH owns scrolling. |
|
|
79
|
+
| `maxScrollSpeedPxPerSec` | 1–2000 | `1000` | Deprecated; retained for old Profile compatibility. DSH owns scrolling. |
|
|
81
80
|
|
|
82
81
|
Overlay example:
|
|
83
82
|
|
|
@@ -106,7 +105,7 @@ The package ships a [`conversation-ui-off.yml`](conversation-ui-off.yml) overlay
|
|
|
106
105
|
The package ships two halves that cooperate over one very narrow config channel:
|
|
107
106
|
|
|
108
107
|
- **Host half** (`src/`): a Cordis plugin. It validates the config schema, injects the validated value into every served index HTML (the boot global `window.__DSH_CONVERSATION_UI_CONFIG__`), and registers the user-settings namespace plus a loopback-only settings RPC (read/write preferences, report installation kind, trigger an npm update).
|
|
109
|
-
- **Web half** (`src/client/`): React views. It registers at low priority to shadow
|
|
108
|
+
- **Web half** (`src/client/`): React views. It registers at low priority to shadow Assistant and Turn-process presentation, wraps other chat rows (tool cards, retries, workflows…) in place while delegating all scrolling to DSH `ChatView`, adds the turn-tail deliverables card, and mounts the plugin configuration card in Settings. The stream still renders with defaults when locale, connection, or the settings service is absent.
|
|
110
109
|
|
|
111
110
|
## Development
|
|
112
111
|
|
|
@@ -116,7 +115,7 @@ pnpm --filter @jcy2387/dsh-conversation-ui test
|
|
|
116
115
|
pnpm --filter @jcy2387/dsh-conversation-ui build
|
|
117
116
|
```
|
|
118
117
|
|
|
119
|
-
Tests run on vitest + Testing Library, covering
|
|
118
|
+
Tests run on vitest + Testing Library, covering stream smoothing, native scroll delegation, Turn folding, and the settings card (both client and host sides). See the [monorepo README](../../README.md) for workspace-wide commands.
|
|
120
119
|
|
|
121
120
|
## License
|
|
122
121
|
|
package/README.md
CHANGED
|
@@ -25,16 +25,15 @@ DeepSeek Harness(DSH)的 Codex 风格对话界面增强插件:把 Web 对
|
|
|
25
25
|
|
|
26
26
|
| 模式 | 行为 |
|
|
27
27
|
| --- | --- |
|
|
28
|
-
| `teleprompter`(默认) |
|
|
28
|
+
| `teleprompter`(默认) | 直接呈现模型的最新内容快照,不引入额外逐字队列。 |
|
|
29
29
|
| `typewriter` | 按字素(grapheme)渐进揭示,对中文、emoji 等宽字符安全。 |
|
|
30
30
|
|
|
31
31
|
- 三档平滑预设:`realtime`(更跟手)、`balanced`(默认)、`silky`(更绵密)。预设控制揭示节奏曲线:到达速率的 EMA 平滑、缓冲目标、追速上限和停顿后的收尾排空速度,让长回复不会整段砸出、快流不会卡顿。
|
|
32
32
|
- `typewriter` 模式另有固定揭示速度 `revealCharsPerSec` 可调。
|
|
33
33
|
|
|
34
|
-
###
|
|
34
|
+
### 流式视口协作
|
|
35
35
|
|
|
36
|
-
-
|
|
37
|
-
- 用户向上滚动阅读时**自动释放跟随**,回到底部后恢复。
|
|
36
|
+
- 当前 DSH `ChatView` 独占会话级位置恢复、底部跟随和用户上滑释放;插件不再直接写 `scrollTop` 或行变换,避免切换会话时争抢滚动所有权。
|
|
38
37
|
- 尊重 `prefers-reduced-motion`;帧率退化时暂停离屏内容的 DOM 提交(FPS 守卫),保住可见帧的流畅。
|
|
39
38
|
|
|
40
39
|
### 产物卡片
|
|
@@ -76,8 +75,8 @@ Profile patch ID:`conversation-ui`。在 profile 的 `cordis.patch.yml` overla
|
|
|
76
75
|
| `mode` | `teleprompter` \| `typewriter` | `teleprompter` | 助手内容的揭示模式。 |
|
|
77
76
|
| `preset` | `realtime` \| `balanced` \| `silky` | `balanced` | 平滑节奏预设。 |
|
|
78
77
|
| `revealCharsPerSec` | 5–200 | `80` | `typewriter` 模式的固定揭示速度。 |
|
|
79
|
-
| `scrollSpeedPxPerSec` | 1–200 | `48` |
|
|
80
|
-
| `maxScrollSpeedPxPerSec` | 1–2000 | `1000` |
|
|
78
|
+
| `scrollSpeedPxPerSec` | 1–200 | `48` | 已弃用;仅保留旧 Profile 配置兼容,滚动由 DSH 管理。 |
|
|
79
|
+
| `maxScrollSpeedPxPerSec` | 1–2000 | `1000` | 已弃用;仅保留旧 Profile 配置兼容,滚动由 DSH 管理。 |
|
|
81
80
|
|
|
82
81
|
Overlay 示例:
|
|
83
82
|
|
|
@@ -106,7 +105,7 @@ Overlay 示例:
|
|
|
106
105
|
本包由两半组成,通过一条极窄的配置通道协作:
|
|
107
106
|
|
|
108
107
|
- **Host 半**(`src/`):Cordis 插件。负责校验配置 schema,并把校验后的配置注入每个服务出的 index HTML(启动配置全局变量 `window.__DSH_CONVERSATION_UI_CONFIG__`);同时注册用户设置命名空间与一条仅限 loopback 的设置 RPC(读取/写入偏好、查询安装形态、触发 npm 更新)。
|
|
109
|
-
- **Web 半**(`src/client/`):React 视图。以低优先级注册替换 `assistant-step`
|
|
108
|
+
- **Web 半**(`src/client/`):React 视图。以低优先级注册替换 `assistant-step` 与 Turn 过程呈现;其余对话行(Tool 卡片、重试、工作流等)原位包装,但滚动完全委托给 DSH `ChatView`;在 Turn 尾部注册产物卡片,并在设置页挂载插件配置卡片。缺少 locale / connection / 设置服务时仍以默认配置运行流式渲染。
|
|
110
109
|
|
|
111
110
|
## 开发
|
|
112
111
|
|
|
@@ -116,7 +115,7 @@ pnpm --filter @jcy2387/dsh-conversation-ui test
|
|
|
116
115
|
pnpm --filter @jcy2387/dsh-conversation-ui build
|
|
117
116
|
```
|
|
118
117
|
|
|
119
|
-
测试基于 vitest + Testing Library
|
|
118
|
+
测试基于 vitest + Testing Library,覆盖流式揭示、原生滚动委托、Turn 折叠与设置卡片(客户端与 Host 两侧)。工作区级命令见 [Monorepo README](../../README.zh.md)。
|
|
120
119
|
|
|
121
120
|
## 许可证
|
|
122
121
|
|