dsh-focus-overlay 0.12.2 → 0.12.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 CHANGED
@@ -55,7 +55,7 @@ Click the line to expand that turn's full work detail (per-category one-line sum
55
55
  | Feature | Description |
56
56
  | --- | --- |
57
57
  | Full-screen overlay | Registered into `shell.overlay` (additive, `replaceRisk: none`) — covers header / composer / sidebar; the thin top bar keeps only the session title and an exit button |
58
- | Official rendering primitives | Assistant text through official `MarkdownText` (GFM + code highlighting + TeX + code copy buttons + footnotes); user messages through `MessageText`; buttons, modals and icons are all official primitives |
58
+ | Official rendering primitives | Assistant text through official `MarkdownText` (GFM + code highlighting + TeX + code copy buttons + footnotes); user messages through the official `projectUserText` projection; buttons, modals and icons are all official primitives |
59
59
  | Image resolution | Assistant `image` blocks resolve through `uiConversation.imageUrl` (the dsh 0.1.2+ session-authorized image cache), falling back to the legacy resolver on older dsh |
60
60
  | Tool-call folding | Follows the official "transcript view" preference (normal / compact); compact mode folds each turn's work part into a "N tool calls · M messages · K subagents" disclosure line ("Thought for a while" when nothing is countable), clickable to expand the full detail; steering messages always stay top-level, never buried; the last turn stays unfolded while streaming |
61
61
  | Categorized summaries | The expanded detail counts tools by family: commands / edits / searches / reads / directory listings / subagents / todos / goals / workflows / skills / questions / plans / background jobs / context injections |
package/README.md CHANGED
@@ -53,7 +53,7 @@
53
53
  | 功能 | 说明 |
54
54
  | --- | --- |
55
55
  | 全屏专注遮罩 | 经 `shell.overlay` 注册(纯增量、`replaceRisk: none`),覆盖标题区 / 输入区 / 侧栏;顶部只留会话标题与「退出专注」按钮 |
56
- | 官方渲染原语 | AI 文本走官方 `MarkdownText`(GFM + 代码高亮 + TeX + 代码复制按钮 + 脚注),用户消息走 `MessageText`;按钮、模态、图标均为官方原语 |
56
+ | 官方渲染原语 | AI 文本走官方 `MarkdownText`(GFM + 代码高亮 + TeX + 代码复制按钮 + 脚注),用户消息走官方 `projectUserText` 投影;按钮、模态、图标均为官方原语 |
57
57
  | 图片解析 | assistant 的 `image` 块经 `uiConversation.imageUrl`(dsh 0.1.2+ 的会话授权图片缓存)解析,旧版 dsh 自动回退到 legacy 解析器 |
58
58
  | 工具调用折叠 | 遵循官方「对话显示」偏好(normal / compact);compact 模式把每轮的工作部分折叠成「N 次工具调用 · M 条消息 · K 个 subagent」披露行(无内容时显示「已思考」),点击可展开完整明细;steering 消息始终独立成行不被折叠;流式中的最后一轮保持展开直到结束 |
59
59
  | 分类摘要明细 | 展开后按工具类别计数:命令 / 编辑 / 搜索 / 读取 / 列目录 / 子代理 / 待办 / 目标 / 工作流 / 技能 / 提问 / 计划 / 后台任务 / 上下文注入 |
package/lib/client.js CHANGED
@@ -2264,6 +2264,19 @@ body[data-fm-focus] #root :has(> [data-slot="conversation"]){margin-bottom:0!imp
2264
2264
  (0, react.useEffect)(() => focusStore.subscribe(() => setV(focusStore.getDonePing())), []);
2265
2265
  return v;
2266
2266
  }
2267
+ /** Body of a sent user message / steering row.
2268
+ *
2269
+ * dsh 0.1.3-alpha.2 removed the `MessageText` component from the primitives
2270
+ * module in favour of the `projectUserText` display projection (which has
2271
+ * existed since 0.1.2 and is still exported by 0.1.5). Importing the removed
2272
+ * name made it `undefined`, so the overlay threw React #130 the moment it
2273
+ * rendered a session containing a user message — the "toggle does nothing"
2274
+ * symptom. `projectUserText` returns inline plain runs plus `@session` /
2275
+ * `/skill` chips; `.fm-user` still supplies the bubble chrome and
2276
+ * `white-space: pre-wrap`, so the text keeps its shape. */
2277
+ function UserText({ text }) {
2278
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(react_jsx_runtime.Fragment, { children: (0, _deepseek_ai_dsh_client_ui_primitives.projectUserText)(text, []) });
2279
+ }
2267
2280
  let bodyEl = null;
2268
2281
  const anchors = {};
2269
2282
  function useSessionSnapshot(sessions, sessionId) {
@@ -2975,7 +2988,7 @@ body[data-fm-focus] #root :has(> [data-slot="conversation"]){margin-bottom:0!imp
2975
2988
  },
2976
2989
  children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
2977
2990
  className: "fm-user",
2978
- children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.MessageText, { text: it.text })
2991
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(UserText, { text: it.text })
2979
2992
  })
2980
2993
  }, key);
2981
2994
  if (it.kind === "steering") return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
@@ -2986,7 +2999,7 @@ body[data-fm-focus] #root :has(> [data-slot="conversation"]){margin-bottom:0!imp
2986
2999
  },
2987
3000
  children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
2988
3001
  className: "fm-user fm-steering",
2989
- children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.MessageText, { text: it.text })
3002
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(UserText, { text: it.text })
2990
3003
  })
2991
3004
  }, key);
2992
3005
  if (it.kind === "assistant") return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(AssistantItem, {
@@ -3484,7 +3497,7 @@ body[data-fm-focus] #root :has(> [data-slot="conversation"]){margin-bottom:0!imp
3484
3497
  * action row, and a collapsible plugin card in the Plugins settings tab
3485
3498
  * (`settings.plugin.item`). Rendering reuses the official client UI primitives
3486
3499
  * module (`@deepseek-ai/dsh-client-ui-primitives` runtime id) — Markdown /
3487
- * MessageText / Tooltip / Button — plus the conversation service's composer
3500
+ * projectUserText / Tooltip / Button — plus the conversation service's composer
3488
3501
  * registry and the uiSession pending-interaction service (dsh 0.1.2).
3489
3502
  */
3490
3503
  const NS = "focus";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dsh-focus-overlay",
3
- "version": "0.12.2",
3
+ "version": "0.12.3",
4
4
  "description": "Focus Mode for the dsh web GUI: a full-screen reading overlay that hides chrome and folds the AI tool-call flow into summaries, reusing the official Markdown / image primitives.",
5
5
  "type": "module",
6
6
  "main": "lib/index.mjs",
@@ -30,7 +30,8 @@
30
30
  "dshReleases": {
31
31
  "0.1.2-alpha.5": "compatible",
32
32
  "0.1.2-rc.1": "compatible",
33
- "0.1.3-alpha.1": "compatible"
33
+ "0.1.3-alpha.1": "compatible",
34
+ "0.1.5-rc.1": "compatible"
34
35
  }
35
36
  }
36
37
  },