dsh-split-view 0.2.1 → 0.2.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 ADDED
@@ -0,0 +1,66 @@
1
+ # dsh-split-view
2
+
3
+ [中文](README.md) | English
4
+
5
+ [![npm version](https://img.shields.io/npm/v/dsh-split-view.svg?style=flat-square)](https://www.npmjs.com/package/dsh-split-view)
6
+
7
+ One plugin that turns the DeepSeek Harness main window into split panes, so you can watch several sessions at once.
8
+
9
+ If you have ever run several tasks at the same time, you know the pain: switching between tabs over and over.
10
+
11
+ dsh-split-view borrows the idea of terminal splitting. The DSH main window becomes a draggable split container, and each pane runs a full DSH client of its own.
12
+
13
+ ## What it looks like
14
+
15
+ ![demo](demo.gif)
16
+
17
+ Above is daily use: split right, split down, drag the divider, double-click the title bar to maximize, close.
18
+
19
+
20
+
21
+ ![two panes](demo2.png)
22
+
23
+
24
+
25
+ ![three panes](demo3.png)
26
+
27
+ Horizontal and vertical splits nest freely. Every pane has a title bar: the live session title on the left, and five buttons on the right — split right, split down, maximize/restore, reload, close. Click the title to rename the session, double-click to maximize, and copy "session id + session title" with one click.
28
+
29
+ ## Install
30
+
31
+ ```sh
32
+ dsh plugin --profile web add dsh-split-view
33
+ dsh web # restart to activate
34
+ ```
35
+
36
+ Install from source for local development: `dsh plugin --profile web add -w /path/to/dsh-split-view`.
37
+
38
+ Uninstall with `dsh plugin --profile web remove dsh-split-view`, restart, and the window is back to normal. If the plugin itself breaks, boot stops with an error instead of a silent blank page, so uninstalling is also the emergency recovery path.
39
+
40
+ ## Default shortcuts (customizable in Settings)
41
+
42
+ | Key (⌘ on macOS, Ctrl on Windows/Linux) | Action |
43
+ |---|---|
44
+ | ⇧⌘D | Split right |
45
+ | ⇧⌘V | Split down |
46
+ | ⇧⌘X | Close focused pane |
47
+ | ⇧⌘Enter | Maximize / restore focused pane |
48
+
49
+ ## Settings
50
+
51
+ Open Settings from any pane; the navigation on the left has a "Split View" entry.
52
+
53
+ Four groups:
54
+
55
+ - **Shortcuts**: click the combo of an action to start recording, press the new combo to rebind, Esc to cancel. What you bind is up to you: combos taken by the browser or the OS, or combos that collide with another action, still bind — you get a warning, not a block. The only hard rule is that a combo must include ⌘/Ctrl.
56
+ - **Focus highlight color**: the outline and title-bar tint of the focused pane. Preset palette, a custom color picker, plus "Follow theme" — follows the brand color token of the current skin, so it changes when you switch skins.
57
+ - **Title bar**: one switch hides all pane title bars. Note that the title bar carries the copy-session-info, split, maximize, reload and close buttons, and double-click-to-maximize and click-title-to-rename also live there — with it hidden, those actions are keyboard-only. Clicking a pane to focus it is unaffected.
58
+ - **Restore defaults**: resets everything above; asks for confirmation first.
59
+
60
+ ## For other plugins
61
+
62
+ The whole split-view capability is exposed as a Cordis service: pane operations, pane×session operations (load a given session, send a message, rename, switch model, cancel a turn), plus queries and subscriptions. See [api.md](./api.md) for the service API aimed at integrators.
63
+
64
+ ## License
65
+
66
+ MIT © dsh-split-view contributors
package/README.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # dsh-split-view(分屏插件)
2
2
 
3
+ 中文 | [English](README.en.md)
4
+
5
+ [![npm version](https://img.shields.io/npm/v/dsh-split-view.svg?style=flat-square)](https://www.npmjs.com/package/dsh-split-view)
6
+
3
7
  一个插件把 DeepSeek Harness 主窗口变成多个分屏,同时查看多个会话的状态。
4
8
 
5
9
  有过【同时跑多个任务】经历的同学应该能感受这种痛苦:多个标签切来切去,很心累。
package/lib/client.js CHANGED
@@ -2648,43 +2648,6 @@ function collectSyncedStorage() {
2648
2648
  } catch {
2649
2649
  // storage unavailable — the hook stays off
2650
2650
  }
2651
- // TEMP(agent-team-demo): auto-pin agent-teams member sessions into panes
2652
- // on top-level boot. Remove once the dedicated dsh-agent-team plugin lands.
2653
- (() => {
2654
- if (window.__dshMemberDemoScheduled) return;
2655
- window.__dshMemberDemoScheduled = true;
2656
- const KEY = "dsh-split:memberPanes";
2657
- const TRACE = "dsh-split:demoTrace";
2658
- const trace = (m) => { try { localStorage.setItem(TRACE, (localStorage.getItem(TRACE) || "").slice(-400) + "\n" + new Date().toISOString().slice(11,19) + " " + m); } catch (e) {} };
2659
- const sleep = (ms) => new Promise((r) => setTimeout(r, ms));
2660
- const run = async () => {
2661
- try {
2662
- trace("start iframes=" + document.querySelectorAll("iframe").length);
2663
- const res = await fetch("/plugins/dsh-agent-teams/state", { cache: "no-store" });
2664
- if (!res.ok) { trace("state route not ok: " + res.status); return; }
2665
- const data = await res.json();
2666
- const teams = (data && data.teams) || [];
2667
- trace("fetched teams=" + teams.length);
2668
- const pinned = new Set(JSON.parse(localStorage.getItem(KEY) || "[]"));
2669
- let changed = false;
2670
- for (const team of teams) {
2671
- for (const m of team.members || []) {
2672
- if (!m || !m.id || pinned.has(m.id)) continue;
2673
- trace("split before " + m.id.slice(0, 8));
2674
- try {
2675
- const out = await splitImpl({ session: m.id, direction: "right" });
2676
- trace("split after leaf=" + (out && out.leafId));
2677
- if (out && out.leafId) { pinned.add(m.id); changed = true; await sleep(1200); }
2678
- } catch (e) { trace("split err: " + (e && e.message)); }
2679
- }
2680
- }
2681
- if (changed) localStorage.setItem(KEY, JSON.stringify([...pinned]));
2682
- trace("done iframes=" + document.querySelectorAll("iframe").length);
2683
- } catch (e) { trace("outer err: " + (e && e.message)); }
2684
- };
2685
- // TEMP(agent-team-demo): 6s delay lets boot/layout restore settle first.
2686
- setTimeout(run, 6000);
2687
- })();
2688
2651
  const handleCommand = (cmd, paneId) => {
2689
2652
  const snap = layout.getSnapshot();
2690
2653
  const target = paneId && findNode(snap.tree, paneId) ? paneId : snap.focused;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dsh-split-view",
3
- "version": "0.2.1",
3
+ "version": "0.2.2",
4
4
  "description": "Multi-session split view for the DeepSeek Harness web GUI: the top window shadows the root slot with a resizable split container; each pane is an iframe running a full DSH client pinned to its own session, with per-pane title bars, LRU hibernation and a dual-loopback origin pool.",
5
5
  "license": "MIT",
6
6
  "type": "module",