dsh-config-sync-plugin 0.3.83 → 0.3.85
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 +22 -2
- package/README.md +22 -2
- package/client.js +59 -28
- package/package.json +1 -1
- package/tools/selftest.mjs +11 -6
package/README.en.md
CHANGED
|
@@ -19,7 +19,7 @@ The package name is **`dsh-config-sync-plugin`** (the `dsh-config-sync` name on
|
|
|
19
19
|
|
|
20
20
|
| Way | Command / entry | Notes |
|
|
21
21
|
|---|---|---|
|
|
22
|
-
| npm | `npm i dsh-config-sync-plugin` | Use it as a dependency, or add `"dsh-config-sync-plugin": "^0.3.
|
|
22
|
+
| npm | `npm i dsh-config-sync-plugin` | Use it as a dependency, or add `"dsh-config-sync-plugin": "^0.3.85"` to the profile's `package.json` and run `pnpm i`. The name matches the `cordis.patch.yml` insert name and the install folder `dsh-config-sync-plugin-<ver>` |
|
|
23
23
|
| Marketplace | client → Plugins → Discover → “Config Sync” | Installs from the git commit registered in `market-index.json` |
|
|
24
24
|
| Offline tgz | `releases\dsh-config-sync-plugin-<ver>.tgz` | GitHub Release asset for air-gapped machines; the panel's Update button downloads the same file |
|
|
25
25
|
|
|
@@ -239,7 +239,7 @@ Each workspace switches between the three states independently; expanding it let
|
|
|
239
239
|
Five interaction refinements on top of the 0.3.76 "Workspace visibility" card:
|
|
240
240
|
|
|
241
241
|
1. **Session names**: each expanded session shows a readable title (from the `session/title` event, falling back to the first user message text); hover for the full session ID. Titles are cached and rebuilt from the local logs on each machine.
|
|
242
|
-
2. **Edit button**: the state dropdown and per-session Hide/Show buttons stay hidden until you click Edit on that workspace; click Done to leave edit mode, so states cannot be changed by accident.
|
|
242
|
+
2. **Edit button**: the state dropdown and per-session Hide/Show buttons stay hidden until you click Edit on that workspace; click Done to leave edit mode, so states cannot be changed by accident. (From 0.3.84 there is a single Edit button for the whole card — see below.)
|
|
243
243
|
3. **Click to expand**: click anywhere on a workspace row to expand/collapse its sessions; no separate expand button.
|
|
244
244
|
4. **Card position**: the Workspace visibility card moved just above Feedback, as the last configuration step.
|
|
245
245
|
5. **Sticky title + quick jump**: the panel title bar is sticky, with shortcut tabs below it (Overview / Workspaces / Targets / Automation / Scripts / Restore / Content / Plugin data / Feedback); clicking one smoothly scrolls to that section.
|
|
@@ -253,6 +253,23 @@ Two display fixes on top of 0.3.77:
|
|
|
253
253
|
1. **Jump order matches section order**: the quick-jump tabs now follow the exact render order of the sections (Overview / Sync conflicts [when present] / Local paths [when expanded] / Targets / Automation & updates / Scripts / Restore / Content / Plugin data / Workspace visibility / Feedback). The two conditional sections (conflicts, local paths) appear in the tabs only when their cards are shown.
|
|
254
254
|
2. **Scroll lands below the title**: the sticky title bar now uses an opaque background (same fill as panel cards), so content no longer shows through it; jumping to a tab sets the scroll offset from the title bar's actual height, so the target section lands fully below the title instead of being covered.
|
|
255
255
|
|
|
256
|
+
### Workspace visibility card: one Edit button for the whole card, sessions paired with their toggles (0.3.84 / 0.3.85)
|
|
257
|
+
|
|
258
|
+
The edit interaction of the "Workspace visibility" card was rebuilt:
|
|
259
|
+
|
|
260
|
+
1. **A single Edit button for the entire card** (0.3.84): previously every workspace row carried its own Edit/Done button, and once there were several rows the buttons no longer lined up with the sessions. Now there is one button on the right of the header row — "Edit" when idle, switching to "Done" (primary colour, same position) once you are editing — and it unlocks every workspace tri-state plus every session toggle at once; clicking again leaves edit mode. The per-row button is gone.
|
|
261
|
+
2. **Session/button pairing made concrete** (0.3.84): each session gets its own row with a divider between rows; in edit mode the whole row gets a background and rounded corners, framing "this session" together with "its button". The toggle sits at the end of that row with a fixed width, so a wrap never puts it next to a different session. The word and colour distinguish Hide (red) from Show (green), the `title` carries the session name, and hidden sessions get a struck-through, dimmed name (the separate "Hidden" label was dropped).
|
|
262
|
+
3. **No tinted explanation banner** (0.3.85): edit mode no longer inserts a yellow-bordered hint row above the list; whether you are editing is read from the header button alone.
|
|
263
|
+
|
|
264
|
+
### Workspace visibility card: blank sessions and idle-review parents are collapsed too (0.3.83)
|
|
265
|
+
|
|
266
|
+
On top of 0.3.82's "collapse agent child sessions by default", two more kinds of noise are folded away:
|
|
267
|
+
|
|
268
|
+
1. **Blank sessions**: entries that were created but never used — no message, no turn (empty `origin` in the session header, and the log only holds permission / sandbox / approval / session-end-seed events, no `turn/start` and no `user/message`).
|
|
269
|
+
2. **Mnemon idle-review parents**: `mnemon-review-owner-v1-*`, which carry only a `subagent/catalog` event — the actual content lives in the `mnemon-review-v1-*` child session they point at.
|
|
270
|
+
|
|
271
|
+
Both naturally satisfy the same "blank" test, so one rule folds them away; no name matching is needed. A "Show blank" checkbox in the header row brings them back, and the footer reports how many blank and how many agent sessions were collapsed. On this machine the default view drops from 99 entries to 10.
|
|
272
|
+
|
|
256
273
|
### Workspace visibility card: agent sessions collapsed by default + instant hide/show (0.3.82)
|
|
257
274
|
|
|
258
275
|
Two changes to the "Workspace visibility" card:
|
|
@@ -652,6 +669,9 @@ The log shows which path ran: `文件比较(快筛):比对 N 个,深哈
|
|
|
652
669
|
|
|
653
670
|
| Date | Version | Summary |
|
|
654
671
|
|---|---|---|
|
|
672
|
+
| 2026-11-23 | 0.3.85 | Removed the tinted banner above the workspace list in edit mode; edit state is read from the Edit/Done button in the header |
|
|
673
|
+
| 2026-11-23 | 0.3.84 | Workspace visibility card uses one Edit button for the whole card; each session row carries its own toggle with a background and divider, hidden names struck through |
|
|
674
|
+
| 2026-11-23 | 0.3.83 | Workspace visibility card also collapses blank sessions and Mnemon idle-review parents; default view on this machine 99 → 10 |
|
|
655
675
|
| 2026-11-23 | 0.3.82 | Workspace visibility card collapses agent sessions by default; hide/show goes through workspaceRegistry and applies instantly (no restart) |
|
|
656
676
|
| 2026-11-21 | 0.3.75 | Sync hidden/archived workspaces across machines (workspace-archives.v1.json into settings); hidden workspaces and sessions stay hidden on B after pull |
|
|
657
677
|
| 2026-11-19 | 0.3.69 | Carry billion-context compaction state across machines (bili-state.mjs); two new notice kinds (plugin-missing / context-state) |
|
package/README.md
CHANGED
|
@@ -15,7 +15,7 @@ DSH 插件:左侧栏多一行「配置同步」,点开是整页体检面板
|
|
|
15
15
|
|
|
16
16
|
| 方式 | 命令 / 入口 | 说明 |
|
|
17
17
|
|---|---|---|
|
|
18
|
-
| npm | `npm i dsh-config-sync-plugin` | 适合把它当依赖管理,或在 profile 的 `package.json` 里写 `"dsh-config-sync-plugin": "^0.3.
|
|
18
|
+
| npm | `npm i dsh-config-sync-plugin` | 适合把它当依赖管理,或在 profile 的 `package.json` 里写 `"dsh-config-sync-plugin": "^0.3.85"` 后 `pnpm i`;包名与 `cordis.patch.yml` 里注册的名字、插件目录 `dsh-config-sync-plugin-<ver>` 一致 |
|
|
19
19
|
| 插件市场 | 客户端「插件市场 → 发现」搜「配置同步」 | 走 `market-index.json` 登记的 git 提交,版本与 README 对齐 |
|
|
20
20
|
| 离线 tgz | `releases\dsh-config-sync-plugin-<ver>.tgz` | GitHub Release 附件,适合内网机器;面板「更新」按钮下载的也是它 |
|
|
21
21
|
|
|
@@ -259,7 +259,7 @@ pwsh -File runtime\sync.ps1 pull `
|
|
|
259
259
|
在 0.3.76「工作区显示」卡片之上做了五点交互调整:
|
|
260
260
|
|
|
261
261
|
1. **会话名称**:工作区展开后每条会话显示可读标题(从 `session/title` 事件提取,取不到时回退到首条用户消息文本),鼠标悬停可看完整会话 ID;标题提取带缓存,换机器后按新机器日志重建。
|
|
262
|
-
2. **修改按钮**:三态下拉与会话的「隐藏 /
|
|
262
|
+
2. **修改按钮**:三态下拉与会话的「隐藏 / 显示」按钮默认不出现,点该工作区的「修改」才进入编辑态,点「完成」退出,避免误改。(0.3.84 起改为**整卡一个**「修改」按钮,见下文。)
|
|
263
263
|
3. **点行展开**:点工作区整行即可展开 / 收起会话,不再单独点展开按钮。
|
|
264
264
|
4. **卡片位置**:工作区显示卡片移到「问题反馈」前,作为配置调整的最后一步。
|
|
265
265
|
5. **固定标题 + 快速跳转**:面板标题栏吸顶;标题下方增加快捷标签(概览 / 工作区显示 / 同步目标 / 自动化 / 生成脚本 / 还原备份 / 同步内容 / 插件数据 / 问题反馈),点击平滑滚动到对应分区。
|
|
@@ -273,6 +273,23 @@ pwsh -File runtime\sync.ps1 pull `
|
|
|
273
273
|
1. **跳转顺序对齐卡片**:快捷标签顺序改为与分区实际渲染顺序完全一致(概览 / 同步冲突[有冲突时] / 本机路径[展开时] / 同步目标 / 自动化与插件更新 / 生成脚本 / 还原备份 / 同步内容 / 插件数据 / 工作区显示 / 问题反馈)。同步冲突、本机路径两个条件分区只在卡片存在时才出现在标签里。
|
|
274
274
|
2. **滚动落点在标题下方**:标题栏改为不透明背景(面板卡片同色),滚动时内容不再从标题背后透出;点标签跳转时按标题栏实际高度设置滚动落点,目标分区完整显示在标题下方,不再被遮住。
|
|
275
275
|
|
|
276
|
+
### 工作区显示卡片:整卡一个「修改」按钮,会话与开关一一对应(0.3.84 / 0.3.85)
|
|
277
|
+
|
|
278
|
+
「工作区显示」卡片的编辑交互重做:
|
|
279
|
+
|
|
280
|
+
1. **整张卡片只有一个「修改」按钮**(0.3.84):以前每个工作区行各带一个「修改 / 完成」,按钮一多就和会话对不上。现在标题行右侧只有一个按钮 —— 非编辑态是「修改」,点进去变成「完成」(主色高亮,位置不动),所有工作区的三态下拉和所有会话的显隐开关一起解锁,再点一次统一退出。行内那个按钮已删除。
|
|
281
|
+
2. **会话与按钮的对应关系做实**(0.3.84):每条会话独占一行,行间加分隔线;编辑态下整行加底色 + 圆角,把「这一行会话」和「这一行按钮」框在一起。开关贴在该行最右侧且等宽,换行也不会漂到别的会话旁边。按钮文案与颜色区分「隐藏」(红)/「显示」(绿),`title` 里带会话名,隐藏的会话名加删除线并变灰(原来那个单独的「已隐藏」小字去掉了)。
|
|
282
|
+
3. **不额外插强调色说明条**(0.3.85):编辑态不再在列表上方插一条黄底提示,是否在编辑只看标题行那个按钮本身。
|
|
283
|
+
|
|
284
|
+
### 工作区显示卡片:连空会话与空闲审查父容器一起折叠(0.3.83)
|
|
285
|
+
|
|
286
|
+
在 0.3.82「默认折叠智能体子会话」之外,再默认折叠两类干扰条目:
|
|
287
|
+
|
|
288
|
+
1. **空会话**:建了但从没发过消息、也没跑过 turn 的历史条目(会话头 `origin` 为空,日志里只有 permission / sandbox / approval / session-end-seed 这几条,没有 `turn/start`、没有 `user/message`)。
|
|
289
|
+
2. **Mnemon 空闲审查的父容器**:`mnemon-review-owner-v1-*`,它自己只有一条 `subagent/catalog` 事件,真正的内容都在它指向的 `mnemon-review-v1-*` 子会话里。
|
|
290
|
+
|
|
291
|
+
两类都天然满足「blank」判据,所以用同一条规则折掉,不需要单独写名字匹配。卡片标题行新增「显示空会话」勾选项,需要时可以放回来;footer 会分别说明折叠了多少条空会话和多少条智能体会话。本机默认视图从 99 条降到 10 条。
|
|
292
|
+
|
|
276
293
|
### 工作区显示卡片:默认折叠智能体会话 + 隐藏/显示即时生效(0.3.82)
|
|
277
294
|
|
|
278
295
|
「工作区显示」卡片两处改动:
|
|
@@ -634,6 +651,9 @@ pwsh -File sync.ps1 push -ScanHistory
|
|
|
634
651
|
|
|
635
652
|
| 日期 | 版本 | 要点 |
|
|
636
653
|
|---|---|---|
|
|
654
|
+
| 2026-11-23 | 0.3.85 | 去掉工作区显示卡片编辑态的强调色说明条,编辑与否只看标题行「修改」/「完成」按钮 |
|
|
655
|
+
| 2026-11-23 | 0.3.84 | 工作区显示卡片改成整卡一个「修改」按钮;会话行自带开关、加底色与分隔线,隐藏态删除线 |
|
|
656
|
+
| 2026-11-23 | 0.3.83 | 工作区显示卡片再折叠空会话与 Mnemon 空闲审查父容器;本机默认视图 99 → 10 条 |
|
|
637
657
|
| 2026-11-23 | 0.3.82 | 工作区显示卡片默认折叠智能体会话;隐藏/显示改走 workspaceRegistry,切完即时生效(不再需要重启) |
|
|
638
658
|
| 2026-11-21 | 0.3.75 | 隐藏/归档的工作区跨机同步(workspace-archives.v1.json 纳入 settings),B 机拉取后不再显示已隐藏的工作区与会话 |
|
|
639
659
|
| 2026-11-19 | 0.3.69 | 跨机搬运 billion-context 压缩状态(bili-state.mjs);同步清单新增 plugin-missing / context-state 两类提示 |
|
package/client.js
CHANGED
|
@@ -1608,7 +1608,9 @@ window.__ModuleLoader__.load({
|
|
|
1608
1608
|
const [busy, setBusy] = react.useState(false)
|
|
1609
1609
|
const [msg, setMsg] = react.useState('')
|
|
1610
1610
|
const [expanded, setExpanded] = react.useState({})
|
|
1611
|
-
|
|
1611
|
+
// 整张卡片只有一个「修改」按钮:进入编辑态后所有工作区与会话一起可改,
|
|
1612
|
+
// 不再每行各带一个按钮(那样按钮多、和会话对不上)。
|
|
1613
|
+
const [editing, setEditing] = react.useState(false)
|
|
1612
1614
|
// 默认折叠智能体(subagent)会话:一屏全是子会话时根本找不到自己的会话。
|
|
1613
1615
|
const [showAgents, setShowAgents] = react.useState(false)
|
|
1614
1616
|
// 默认折叠空会话:建了没聊过、或者只是 Mnemon 空闲审查的父容器,列出只会干扰。
|
|
@@ -1672,7 +1674,9 @@ window.__ModuleLoader__.load({
|
|
|
1672
1674
|
h('div', { style: { display: 'flex', alignItems: 'center', gap: '8px', flexWrap: 'wrap' } },
|
|
1673
1675
|
h('div', { style: S.cardTitle }, M('工作区显示状态', 'Workspace visibility')),
|
|
1674
1676
|
h('div', { style: { ...S.hint, flex: 1, minWidth: '160px' } },
|
|
1675
|
-
|
|
1677
|
+
editing
|
|
1678
|
+
? M('点工作区展开会话;每条会话右侧的按钮就是它自己的显示/隐藏。改动即时生效。', 'Click a workspace to expand sessions; the button on each row toggles that session. Changes apply immediately.')
|
|
1679
|
+
: M('点工作区展开会话;要改状态先点右侧「修改」。改动即时生效,会话列表会跟着变。', 'Click a workspace to expand sessions; click Edit on the right to change states. Changes apply immediately and the session list follows.')),
|
|
1676
1680
|
h('label', {
|
|
1677
1681
|
style: { display: 'inline-flex', alignItems: 'center', gap: '4px', fontSize: '12px', color: 'var(--dsw-alias-label-secondary)', cursor: 'pointer' },
|
|
1678
1682
|
title: M('默认隐藏空会话(没跑过对话的历史条目)与 Mnemon 空闲审查的父容器,勾选后一并列出', 'Blank sessions (never used) and Mnemon idle-review parents are hidden by default; tick to list them too'),
|
|
@@ -1697,6 +1701,14 @@ window.__ModuleLoader__.load({
|
|
|
1697
1701
|
}),
|
|
1698
1702
|
h('span', null, M('显示智能体', 'Show agents')),
|
|
1699
1703
|
),
|
|
1704
|
+
// 全卡片唯一的主操作按钮:编辑 / 完成切换(编辑态下高亮,位置不变)
|
|
1705
|
+
h('button', {
|
|
1706
|
+
type: 'button',
|
|
1707
|
+
style: editing ? { ...S.btnPrimary } : { ...S.btn },
|
|
1708
|
+
disabled: busy,
|
|
1709
|
+
onClick: () => setEditing(v => !v),
|
|
1710
|
+
title: editing ? M('退出编辑态', 'Leave edit mode') : M('进入编辑态,才能改状态', 'Enter edit mode to change states'),
|
|
1711
|
+
}, editing ? M('完成', 'Done') : M('修改', 'Edit')),
|
|
1700
1712
|
h('button', { type: 'button', style: S.btn, disabled: busy, onClick: load }, busy ? M('刷新中…', 'Refreshing…') : M('刷新', 'Refresh')),
|
|
1701
1713
|
),
|
|
1702
1714
|
msg ? h('div', { style: { ...S.hint, color: 'var(--dsw-alias-state-success-primary, #1a7f37)' } }, msg) : null,
|
|
@@ -1710,8 +1722,14 @@ window.__ModuleLoader__.load({
|
|
|
1710
1722
|
: h('div', { style: { display: 'flex', flexDirection: 'column', gap: '6px', marginTop: '2px' } },
|
|
1711
1723
|
wss.map(w => {
|
|
1712
1724
|
const open = !!expanded[w.workspaceId]
|
|
1713
|
-
const
|
|
1714
|
-
return h('div', {
|
|
1725
|
+
const wsTone = w.state === 'archive' ? 'warn' : w.state === 'normal' ? 'ok' : 'pull'
|
|
1726
|
+
return h('div', {
|
|
1727
|
+
key: w.workspaceId,
|
|
1728
|
+
style: {
|
|
1729
|
+
border: '1px solid ' + (editing ? 'var(--dsw-alias-border-l2)' : 'var(--dsw-alias-border-l1)'),
|
|
1730
|
+
borderRadius: '8px', padding: '8px 10px',
|
|
1731
|
+
},
|
|
1732
|
+
},
|
|
1715
1733
|
// 整行可点展开 / 收起(需求3)
|
|
1716
1734
|
h('div', {
|
|
1717
1735
|
style: { display: 'flex', alignItems: 'center', gap: '8px', flexWrap: 'wrap', cursor: 'pointer' },
|
|
@@ -1720,44 +1738,57 @@ window.__ModuleLoader__.load({
|
|
|
1720
1738
|
},
|
|
1721
1739
|
h('span', { style: { fontSize: '12px', color: 'var(--dsw-alias-label-tertiary)', width: '12px' } }, open ? '▾' : '▸'),
|
|
1722
1740
|
h('span', { style: { fontSize: '12px', fontWeight: 600, minWidth: '90px' } }, w.title || w.workspaceId.slice(0, 8)),
|
|
1723
|
-
|
|
1724
|
-
|
|
1725
|
-
|
|
1726
|
-
|
|
1727
|
-
onClick: (e) => { stop(e); setEditing(v => ({ ...v, [w.workspaceId]: !edit })) },
|
|
1728
|
-
}, edit ? M('完成', 'Done') : M('修改', 'Edit')),
|
|
1729
|
-
),
|
|
1730
|
-
// 编辑态才出现三态选择(需求2)
|
|
1731
|
-
edit
|
|
1732
|
-
? h('div', { style: { display: 'flex', alignItems: 'center', gap: '8px', marginTop: '6px', flexWrap: 'wrap' }, onClick: stop },
|
|
1733
|
-
h('span', { style: S.footnote }, M('工作区状态', 'Workspace state')),
|
|
1734
|
-
h('select', {
|
|
1741
|
+
// 非编辑态:状态只作为徽标展示(只读);
|
|
1742
|
+
// 编辑态:徽标右侧直接给出三态下拉,改的是这个工作区本身 —— 不再需要行内「修改」按钮。
|
|
1743
|
+
editing
|
|
1744
|
+
? h('select', {
|
|
1735
1745
|
value: w.state === 'partial' ? 'partial' : w.state,
|
|
1736
1746
|
disabled: busy,
|
|
1747
|
+
onClick: stop,
|
|
1737
1748
|
onChange: (e) => { if (e.target.value !== 'partial') changeWorkspace(w.workspaceId, e.target.value) },
|
|
1738
|
-
|
|
1749
|
+
title: M('这个工作区的三态', 'State of this workspace'),
|
|
1750
|
+
style: { fontSize: '12px', padding: '3px 6px', borderRadius: '6px', border: '1px solid var(--dsw-alias-border-l2)', background: 'var(--dsw-alias-bg-base)', color: 'var(--dsw-alias-label-primary)' },
|
|
1739
1751
|
},
|
|
1740
1752
|
w.state === 'partial' ? h('option', { value: 'partial' }, stateLabel('partial')) : null,
|
|
1741
1753
|
opts.map(([v, label]) => h('option', { key: v, value: v }, label)),
|
|
1742
|
-
)
|
|
1743
|
-
|
|
1744
|
-
:
|
|
1745
|
-
|
|
1754
|
+
)
|
|
1755
|
+
: h('span', { style: chipStyle(wsTone) }, stateLabel(w.state)),
|
|
1756
|
+
h('span', { style: { ...S.footnote, flex: 1 } }, M(w.sessionCount + ' 会话 · ' + w.hiddenCount + ' 隐藏', w.sessionCount + ' sessions · ' + w.hiddenCount + ' hidden')),
|
|
1757
|
+
),
|
|
1758
|
+
// 展开的会话列表:每行是「会话名 + 它自己的开关」,按钮与会话同一行、紧跟其名,
|
|
1759
|
+
// 编辑态下用带词义的按钮文案(隐藏/显示,颜色区分),不再是一个孤零零的按钮。
|
|
1746
1760
|
open
|
|
1747
1761
|
? h('div', { style: { display: 'flex', flexDirection: 'column', gap: '2px', marginTop: '6px', paddingLeft: '18px' } },
|
|
1748
1762
|
(w.sessions || []).length === 0
|
|
1749
1763
|
? h('div', { style: S.footnote }, M('这个工作区还没有会话。', 'No sessions in this workspace.'))
|
|
1750
|
-
: w.sessions.map(s => h('div', {
|
|
1764
|
+
: w.sessions.map(s => h('div', {
|
|
1765
|
+
key: s.id,
|
|
1766
|
+
style: {
|
|
1767
|
+
display: 'flex', alignItems: 'center', gap: '8px', fontSize: '12px', lineHeight: '18px',
|
|
1768
|
+
borderTop: '1px solid var(--dsw-alias-border-l1)',
|
|
1769
|
+
// 编辑态给整行加底色,视线一眼能把「这一行会话」和「这一行的按钮」框在一起
|
|
1770
|
+
padding: editing ? '3px 6px' : '3px 0',
|
|
1771
|
+
borderRadius: editing ? '6px' : 0,
|
|
1772
|
+
background: editing ? 'var(--dsw-alias-fill-l1, var(--dsw-alias-border-l1))' : 'transparent',
|
|
1773
|
+
},
|
|
1774
|
+
},
|
|
1751
1775
|
h('span', {
|
|
1752
|
-
style: {
|
|
1776
|
+
style: {
|
|
1777
|
+
flex: '1 1 auto', minWidth: 0, overflow: 'hidden', textOverflow: 'ellipsis', whiteSpace: 'nowrap',
|
|
1778
|
+
color: s.hidden ? 'var(--dsw-alias-label-tertiary)' : 'var(--dsw-alias-label-secondary)',
|
|
1779
|
+
textDecoration: s.hidden ? 'line-through' : 'none',
|
|
1780
|
+
},
|
|
1753
1781
|
title: (s.title || s.id) + '\n' + s.id,
|
|
1754
1782
|
}, s.title || s.id),
|
|
1755
|
-
|
|
1756
|
-
|
|
1757
|
-
: null,
|
|
1758
|
-
edit
|
|
1783
|
+
// 按钮与会话同行、等宽右对齐:换行也不会跑到别的会话旁边
|
|
1784
|
+
editing
|
|
1759
1785
|
? h('button', {
|
|
1760
|
-
type: 'button',
|
|
1786
|
+
type: 'button',
|
|
1787
|
+
style: s.hidden
|
|
1788
|
+
? { ...S.btn, minWidth: '56px', color: 'var(--dsw-alias-state-success-primary, #1a7f37)' }
|
|
1789
|
+
: { ...S.btn, minWidth: '56px', color: 'var(--dsw-alias-state-error-primary)' },
|
|
1790
|
+
disabled: busy,
|
|
1791
|
+
title: (s.hidden ? M('让这条会话重新显示在列表里', 'Make this session visible again') : M('把这条会话从列表隐藏', 'Hide this session from the list')) + '\n' + (s.title || s.id),
|
|
1761
1792
|
onClick: () => changeSession(s.id, !s.hidden),
|
|
1762
1793
|
}, s.hidden ? M('显示', 'Show') : M('隐藏', 'Hide'))
|
|
1763
1794
|
: null,
|
package/package.json
CHANGED
package/tools/selftest.mjs
CHANGED
|
@@ -1677,14 +1677,19 @@ console.log('== 配置同步页面 5 点调整 ==')
|
|
|
1677
1677
|
&& wvSrc.includes('cleanTitle(providerTitle) || cleanTitle(fallbackTitle)')
|
|
1678
1678
|
&& !wvSrc.includes('if (lastTitle) break'), '标题演进:provider > fallback > 无来源 > 首条消息')
|
|
1679
1679
|
check('会话名称:卡片显示 s.title || s.id', cliSrc.includes('s.title || s.id'), 'client.js 卡片')
|
|
1680
|
-
// 2)
|
|
1681
|
-
check('
|
|
1682
|
-
cliSrc.includes('
|
|
1680
|
+
// 2) 修改按钮:全卡片只有一个「修改」,进入编辑态后三态 select 与每行的隐藏/显示按钮一起出现
|
|
1681
|
+
check('修改按钮:整卡一个「修改」,编辑态才显示三态 select 与会话隐藏按钮',
|
|
1682
|
+
cliSrc.includes('// 整张卡片只有一个「修改」按钮')
|
|
1683
1683
|
&& cliSrc.includes("M('修改', 'Edit')") && cliSrc.includes("M('完成', 'Done')")
|
|
1684
|
-
|
|
1685
|
-
&& cliSrc.includes('
|
|
1684
|
+
// 工作区行不再各带一个编辑按钮
|
|
1685
|
+
&& !cliSrc.includes('const edit = !!editing[w.workspaceId]')
|
|
1686
|
+
&& !cliSrc.includes('setEditing(v => ({ ...v, [w.workspaceId]: !edit }))')
|
|
1687
|
+
// 编辑态由整卡开关控制,且行内下拉与行内按钮都存在
|
|
1688
|
+
&& cliSrc.includes('onClick: () => setEditing(v => !v)')
|
|
1686
1689
|
&& cliSrc.includes('changeWorkspace(w.workspaceId, e.target.value)')
|
|
1687
|
-
&& cliSrc.includes('changeSession(s.id, !s.hidden)')
|
|
1690
|
+
&& cliSrc.includes('changeSession(s.id, !s.hidden)')
|
|
1691
|
+
// 编辑态只靠顶部按钮本身表达状态,不再额外插入强调色说明条
|
|
1692
|
+
&& !cliSrc.includes('editBanner') && !cliSrc.includes("M('编辑中', 'Editing')"), 'client.js 编辑态')
|
|
1688
1693
|
// 3) 点工作区整行即展开,不再单独展开按钮
|
|
1689
1694
|
check('点工作区即展开(整行 onClick,无独立展开按钮)',
|
|
1690
1695
|
cliSrc.includes("onClick: () => setExpanded(e => ({ ...e, [w.workspaceId]: !open }))")
|