@tobycaimf/dsh-archived-sessions 1.0.1 → 1.0.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/README.en.md +13 -11
- package/README.md +13 -11
- package/lib/client.js +309 -286
- package/lib/client.js.map +2 -2
- package/lib/index.js +43 -0
- package/lib/index.js.map +2 -2
- package/package.json +2 -2
- package/src/client/index.jsx +314 -324
- package/src/index.js +48 -0
package/README.en.md
CHANGED
|
@@ -2,20 +2,20 @@
|
|
|
2
2
|
|
|
3
3
|
> English | [中文](./README.md)
|
|
4
4
|
|
|
5
|
-
> Manage your
|
|
6
|
-
> Archive
|
|
7
|
-
>
|
|
5
|
+
> Manage **all your sessions** in DSH from one place — **Session Manager**.
|
|
6
|
+
> Archive / restore / permanently delete / move to another workspace, with workspace tags and session dates, plus batch actions.
|
|
7
|
+
> Target directories can be an **existing workspace** or a **new path** (auto-created); the new-path mode also supports the **native OS directory picker**, and the settings nav gets a dedicated archive-box icon.
|
|
8
8
|
|
|
9
|
-
A persistent DSH plugin (host + browser halves).
|
|
9
|
+
A persistent DSH plugin (host + browser halves). Under **Settings → 会话管理 (Session Manager)** unify all conversations: archive (hide from sidebar), restore, permanently delete, and relocate between workspaces.
|
|
10
10
|
|
|
11
11
|
## Features
|
|
12
12
|
|
|
13
|
-
- **
|
|
14
|
-
- **Restore**:
|
|
13
|
+
- **Unified panel**: a single Session Manager entry with an **All / Archived** filter; each row shows the title (falls back to the first user message), **archive status** (active / archived), the **session date**, and a **workspace tag** (title or directory name; a dashed "原工作区已删除 / workspace deleted" tag when the original workspace is gone).
|
|
14
|
+
- **Archive / Restore**: archive hides a session from the sidebar; restore unarchives and puts it back into its group.
|
|
15
15
|
- **Permanently delete**: physically removes the session log file + detaches workspace accounting — **irreversible** (asks for confirmation first).
|
|
16
|
-
- **
|
|
17
|
-
- **
|
|
18
|
-
- **Adaptive UI**: follows the theme tokens (light/dark), stacks vertically on narrow screens; loading / empty / error / busy states, keyboard focus and `prefers-reduced-motion` support.
|
|
16
|
+
- **Move to a workspace**: pick an **existing workspace**, or enter a **new directory path** (auto-created); the new-path mode also lets you open the **native OS directory picker** with a **「浏览…」** button. The session's working directory and log are migrated, and it moves into the corresponding workspace group. Sessions that are currently open must be switched away from first.
|
|
17
|
+
- **Batch multi-select**: select-all / archive selected / restore selected / delete selected (single confirmation for batch delete).
|
|
18
|
+
- **Adaptive UI**: follows the theme tokens (light/dark), stacks vertically on narrow screens; loading / empty / error / busy states, keyboard focus and `prefers-reduced-motion` support; dedicated archive-box nav icon.
|
|
19
19
|
|
|
20
20
|
## Screenshots
|
|
21
21
|
|
|
@@ -37,7 +37,7 @@ git clone https://github.com/TOBYCAI/dsh-archived-sessions.git
|
|
|
37
37
|
dsh plugin --profile desktop add link:/path/to/dsh-archived-sessions
|
|
38
38
|
```
|
|
39
39
|
|
|
40
|
-
> After installing, **restart DSH** (or refresh the page to reload the bundle). Then Settings →
|
|
40
|
+
> After installing, **restart DSH** (or refresh the page to reload the bundle). Then Settings → 会话管理 (Session Manager) becomes available.
|
|
41
41
|
|
|
42
42
|
## Uninstall
|
|
43
43
|
|
|
@@ -65,11 +65,13 @@ lib/client.js pre-built client (ModuleLoader CJS handshake)
|
|
|
65
65
|
| Method | Path | Description |
|
|
66
66
|
|---|---|---|
|
|
67
67
|
| POST | `/archived-sessions/list` | List archived sessions (skips deleted / non-existent ones) |
|
|
68
|
+
| POST | `/archived-sessions/archive` | Archive (hide) a single session |
|
|
69
|
+
| POST | `/archived-sessions/archive-many` | Archive many |
|
|
68
70
|
| POST | `/archived-sessions/restore` | Unarchive a single session |
|
|
69
71
|
| POST | `/archived-sessions/restore-many` | Unarchive many |
|
|
70
72
|
| POST | `/archived-sessions/delete` | Permanently delete a single session (physically removes log, keeps hidden) |
|
|
71
73
|
| POST | `/archived-sessions/delete-many` | Permanently delete many |
|
|
72
|
-
| POST | `/archived-sessions/sessions` | List all sessions (with archived flag) for the
|
|
74
|
+
| POST | `/archived-sessions/sessions` | List all sessions (with archived flag) for the Session Manager panel |
|
|
73
75
|
| POST | `/archived-sessions/workspaces` | List available target workspaces |
|
|
74
76
|
| POST | `/archived-sessions/move` | Move a session to a target workspace `{ sessionId, targetPath }` |
|
|
75
77
|
|
package/README.md
CHANGED
|
@@ -2,20 +2,20 @@
|
|
|
2
2
|
|
|
3
3
|
> [English](./README.en.md) | 中文
|
|
4
4
|
|
|
5
|
-
> DSH
|
|
6
|
-
>
|
|
7
|
-
>
|
|
5
|
+
> DSH 设置面板**「会话管理」**:一个入口统一管理全部会话。
|
|
6
|
+
> 归档 / 恢复 / 彻底删除 / 移动到其他工作区,带工作区标签与会话日期,支持批量。
|
|
7
|
+
> 工作区目录可选「已有」或「新建」,新建支持**系统目录选择**;设置导航带专属归档盒图标。
|
|
8
8
|
|
|
9
|
-
一个 DSH 持久化插件(host + browser 双半)。在 **设置 →
|
|
9
|
+
一个 DSH 持久化插件(host + browser 双半)。在 **设置 → 会话管理** 里统一管理所有会话:归档(从侧栏隐藏)、恢复、彻底删除、移动到其他工作区。
|
|
10
10
|
|
|
11
11
|
## 功能
|
|
12
12
|
|
|
13
|
-
-
|
|
14
|
-
-
|
|
13
|
+
- **统一面板**:单一「会话管理」入口,顶部「全部 / 已归档」筛选;每行显示标题(缺失时回退首条用户消息)、**归档状态**(活动 / 已归档)、**会话日期**、**所属工作区标签**(标题或目录名;原工作区已删除时显示「工作区已删 · 目录名」)。
|
|
14
|
+
- **归档 / 恢复**:归档把会话从侧栏隐藏;恢复取消归档放回原分组。
|
|
15
15
|
- **彻底删除**:物理删除会话日志文件 + 解除工作区归属,**不可恢复**(删除前有二次确认)。
|
|
16
|
-
-
|
|
17
|
-
-
|
|
18
|
-
- **自适应 UI**:深浅色跟随主题 token,窄屏自动纵向堆叠;加载/空/错误/操作中状态齐全;支持键盘焦点、`prefers-reduced-motion
|
|
16
|
+
- **移动到工作区**:任选**已有工作区**或**新建目录路径**(自动创建);新建目录支持直接输入路径或点击 **「浏览…」调用系统目录选择窗口**。会话的工作目录与日志会一起迁移,随后滑入对应工作区分组;处于打开状态的会话需先切走。
|
|
17
|
+
- **批量多选**:全选 / 批量归档 / 恢复所选 / 删除所选(批量删除一次二次确认)。
|
|
18
|
+
- **自适应 UI**:深浅色跟随主题 token,窄屏自动纵向堆叠;加载/空/错误/操作中状态齐全;支持键盘焦点、`prefers-reduced-motion`;设置导航左侧为归档盒专属图标。
|
|
19
19
|
|
|
20
20
|
## 截图
|
|
21
21
|
|
|
@@ -37,7 +37,7 @@ git clone https://github.com/TOBYCAI/dsh-archived-sessions.git
|
|
|
37
37
|
dsh plugin --profile desktop add link:/path/to/dsh-archived-sessions
|
|
38
38
|
```
|
|
39
39
|
|
|
40
|
-
> 装完**重启 DSH**(或刷新页面重新加载 bundle)后,设置 →
|
|
40
|
+
> 装完**重启 DSH**(或刷新页面重新加载 bundle)后,设置 → 会话管理 即可用。
|
|
41
41
|
|
|
42
42
|
## 卸载
|
|
43
43
|
|
|
@@ -65,11 +65,13 @@ lib/client.js 预构建 client(ModuleLoader CJS handshake)
|
|
|
65
65
|
| 方法 | 路径 | 说明 |
|
|
66
66
|
|---|---|---|
|
|
67
67
|
| POST | `/archived-sessions/list` | 列出归档会话(跳过已删除/不存在者) |
|
|
68
|
+
| POST | `/archived-sessions/archive` | 归档(隐藏)单个会话 |
|
|
69
|
+
| POST | `/archived-sessions/archive-many` | 批量归档 |
|
|
68
70
|
| POST | `/archived-sessions/restore` | 取消归档单个 |
|
|
69
71
|
| POST | `/archived-sessions/restore-many` | 批量取消归档 |
|
|
70
72
|
| POST | `/archived-sessions/delete` | 彻底删除单个(物理删日志,保持隐藏) |
|
|
71
73
|
| POST | `/archived-sessions/delete-many` | 批量彻底删除 |
|
|
72
|
-
| POST | `/archived-sessions/sessions` |
|
|
74
|
+
| POST | `/archived-sessions/sessions` | 列出全部会话(含已归档标记),供「会话管理」面板 |
|
|
73
75
|
| POST | `/archived-sessions/workspaces` | 列出可选目标工作区 |
|
|
74
76
|
| POST | `/archived-sessions/move` | 把会话移动到目标工作区 `{ sessionId, targetPath }` |
|
|
75
77
|
|