dsh-visualization 0.0.0-stage → 0.1.1

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/icon.svg ADDED
@@ -0,0 +1,16 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64" width="64" height="64" role="img" aria-label="DSH VISUALIZATION">
2
+ <defs>
3
+ <radialGradient id="g" cx="50%" cy="50%" r="50%">
4
+ <stop offset="0%" stop-color="#ffd79a" stop-opacity="0.95"/>
5
+ <stop offset="100%" stop-color="#ff9a5c" stop-opacity="0"/>
6
+ </radialGradient>
7
+ </defs>
8
+ <rect width="64" height="64" rx="14" fill="#0b0d11"/>
9
+ <circle cx="32" cy="32" r="13" fill="url(#g)"/>
10
+ <circle cx="32" cy="32" r="26" fill="none" stroke="#e6edfa" stroke-opacity="0.28" stroke-width="1.4"/>
11
+ <circle cx="32" cy="32" r="17" fill="none" stroke="#f0a6c6" stroke-opacity="0.55" stroke-width="1.8"/>
12
+ <circle cx="32" cy="32" r="9" fill="none" stroke="#b28cff" stroke-opacity="0.7" stroke-width="2"/>
13
+ <circle cx="32" cy="32" r="3.4" fill="#ffc46b"/>
14
+ <path d="M32 6 A26 26 0 0 1 56 22" fill="none" stroke="#ffc46b" stroke-width="3" stroke-linecap="round"/>
15
+ <path d="M58 32 A26 26 0 0 1 32 58" fill="none" stroke="#7fd8c4" stroke-width="3" stroke-linecap="round"/>
16
+ </svg>
package/index.js ADDED
@@ -0,0 +1,30 @@
1
+ import { createRequire } from 'node:module'
2
+
3
+ const req = createRequire(import.meta.url)
4
+
5
+ /* 本地开发时 fold.cjs 会被频繁改动;清掉 require 缓存,
6
+ 每次插件激活都拿到最新代码(发布版相当于零成本地多 require 一次)。 */
7
+ let core
8
+ try {
9
+ const corePath = req.resolve('./fold.cjs')
10
+ delete req.cache[corePath]
11
+ core = req(corePath)
12
+ } catch (e) {
13
+ console.error('[dsh-visualization] 载入 fold.cjs 失败:', e && e.message)
14
+ throw e
15
+ }
16
+
17
+ export const name = 'dsh-visualization'
18
+ export const inject = ['webServer']
19
+
20
+ export function apply(ctx, config = {}) {
21
+ try { core.setOrigin(ctx.webServer.getOrigin()) } catch (e) { /* 拿不到就留空 */ }
22
+ /* 默认只允许本机;需要远程访问时在插件的 config 里写 { "allowRemote": true } */
23
+ try { core.setPolicy({ allowRemote: config && config.allowRemote === true }) } catch (e) { }
24
+ const prefix = String(config.basePath || '/dsh-visualization').replace(/\/+$/, '') || '/dsh-visualization'
25
+ ctx.effect(() => ctx.webServer.register({
26
+ kind: 'prefix',
27
+ path: prefix,
28
+ handler: (req2, res) => core.handle(req2, res),
29
+ }))
30
+ }
package/locale/en.json ADDED
@@ -0,0 +1,6 @@
1
+ {
2
+ "meta": {
3
+ "title": "DSH VISUALIZATION session instrument",
4
+ "description": "Rings, turns, tools and background jobs of the live session, drawn as a layered instrument."
5
+ }
6
+ }
package/locale/zh.json ADDED
@@ -0,0 +1,6 @@
1
+ {
2
+ "meta": {
3
+ "title": "DSH VISUALIZATION 会话仪表盘",
4
+ "description": "把会话的轮次、步骤、工具和后台任务画成分层仪表盘,实时跟随当前会话。"
5
+ }
6
+ }
package/package.json CHANGED
@@ -1,6 +1,60 @@
1
1
  {
2
2
  "name": "dsh-visualization",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
3
+ "version": "0.1.1",
4
+ "description": "DSH Visualization — a session instrument: rings, turns, tools and background jobs of a live DeepSeek Harness session.",
5
+ "type": "module",
6
+ "main": "index.js",
7
+ "exports": {
8
+ ".": {
9
+ "default": "./index.js"
10
+ },
11
+ "./client": {
12
+ "default": "./client.js"
13
+ },
14
+ "./cordis.patch.yml": "./cordis.patch.yml",
15
+ "./locale/*.json": "./locale/*.json",
16
+ "./icon": "./icon.svg",
17
+ "./package.json": "./package.json"
18
+ },
19
+ "files": [
20
+ "index.js",
21
+ "client.js",
22
+ "fold.cjs",
23
+ "build.cjs",
24
+ "cordis.patch.yml",
25
+ "web",
26
+ "locale",
27
+ "icon.svg",
28
+ "LICENSE",
29
+ "README.md"
30
+ ],
31
+ "keywords": [
32
+ "dsh",
33
+ "dsh-plugin",
34
+ "visualization",
35
+ "session"
36
+ ],
37
+ "license": "PolyForm-Noncommercial-1.0.0",
38
+ "dsh": {
39
+ "bundle": {
40
+ "patch": "./cordis.patch.yml"
41
+ },
42
+ "client": {
43
+ "platform": "web",
44
+ "inject": [
45
+ "@deepseek-ai/dsh-client-ui-slots"
46
+ ]
47
+ }
48
+ },
49
+ "scripts": {
50
+ "build": "node build.cjs"
51
+ },
52
+ "repository": {
53
+ "type": "git",
54
+ "url": "git+https://github.com/peilopielo/dsh-Visualization.git"
55
+ },
56
+ "homepage": "https://github.com/peilopielo/dsh-Visualization",
57
+ "bugs": {
58
+ "url": "https://github.com/peilopielo/dsh-Visualization/issues"
59
+ }
60
+ }