@jiyr0119/dsh-service-console 0.1.1 → 0.2.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/README.md CHANGED
@@ -1,8 +1,8 @@
1
1
  # DSH Service Console
2
2
 
3
- > A local development service console for DSH: discover listening ports, identify services related to the current conversation or workspace, and safely inspect, stop, or restart them.
3
+ **English**
4
4
 
5
- **DSH 本地开发服务控制台:发现监听端口,识别与当前对话或工作区相关的服务,并安全地查看、停止和重启。**
5
+ > A local development service console for DSH: discover listening ports, identify services related to the current conversation or workspace, and safely inspect, stop, or restart them.
6
6
 
7
7
  Single-purpose plugin for the DeepSeek Harness web UI. When the model (or you) starts a local dev server (`npm run dev`, Vite, Next.js, Uvicorn, Express, Rust, …), Service Console shows it in one place: which ports it listens on, which command and working directory started it, whether it belongs to this conversation or workspace, and whether it is safe to stop or restart.
8
8
 
@@ -12,7 +12,10 @@ Single-purpose plugin for the DeepSeek Harness web UI. When the model (or you) s
12
12
  - **Ownership & risk** — five-level attribution: `This chat` (matched against the session launch ledger), `Workspace`, `Other local`, `Unknown`, `Protected`.
13
13
  - **Control** — graceful stop to the process group, restart with a safe saved launch command. Every action is confirmed twice and re-validated against the current snapshot.
14
14
  - **Safeguards** — PID-reuse / fingerprint checks before any signal; unknown and protected services are read-only; force-kill is off by default; no implicit auto-cleanup; command output is redacted.
15
- - **Scopes, search, config, i18n** — conversation / workspace / machine scopes, keyword filtering, refresh interval / graceful timeout / force-kill settings, zh/en.
15
+ - **All local services** — every listening service on this machine is visible; ownership is shown as a safety signal rather than a hidden category filter.
16
+ - **Search, config, i18n** — keyword filtering, graceful timeout / force-kill settings, and automatic Chinese/English labels from DSH's active locale.
17
+ - **On-demand scanning** — opening the console fetches the current snapshot once; use the refresh button for an explicit rescan. There is no background polling.
18
+ - **DSH-native inspector** — an expanded service record card presents process identity, ports, command, working directory and ownership evidence in the Web UI's token-based visual language.
16
19
 
17
20
  ## Install
18
21
 
@@ -28,6 +31,12 @@ Then refresh the DSH web UI — a `🖥 SC` entry appears in the conversation he
28
31
 
29
32
  Alternative — dynamic paste (zero-build, process-local): paste `dynamic/host.js` + `dynamic/client.js` via the dynamic Cordis plugin flow.
30
33
 
34
+ ## UI preview
35
+
36
+ ![Service Console 0.2.0 — all local services and DSH-style inspector](./assets/service-console-0.2.0.gif)
37
+
38
+ The preview shows the complete local listening-service list and the expanded inspector card. The ownership badge remains visible as a safety signal, while the list itself is no longer split into conversation/workspace/machine categories.
39
+
31
40
  ## Permissions & safety
32
41
 
33
42
  - The client never sends raw PIDs or shell commands; it targets a service ID and the Host re-validates PID / start time / fingerprint before acting.
@@ -44,6 +53,23 @@ npm run build
44
53
  npm test # unit + integration tests (node --test)
45
54
  ```
46
55
 
56
+ ## Testing
57
+
58
+ `npm test` builds once and runs the whole suite with Node's built-in test runner (`node --test`). No extra test framework is required.
59
+
60
+ | File | Type | What it covers |
61
+ | --- | --- | --- |
62
+ | `test/process-inspector.test.mjs` | Unit | Platform output parsing (`parseLstart`, `parseListenRows`, `parsePsRows`, `parseAddress`), command redaction, five-level ownership classification |
63
+ | `test/host-more.test.mjs` | Unit | Config validation, session ledger, lifecycle state machine (stop/restart) with fake dependencies, service aggregation & fingerprint stability |
64
+ | `test/integration.test.mjs` | Integration | Real system commands + a temporary HTTP server spawned by the test itself; signals are only ever sent to test-owned processes |
65
+
66
+ ```bash
67
+ npm test # full suite
68
+ npm run build && node --test test/process-inspector.test.mjs # run a single file
69
+ ```
70
+
71
+ Unit tests import the built output under `lib/`, so the sources must be compiled first — `npm test` handles this automatically.
72
+
47
73
  ## License
48
74
 
49
75
  MIT
package/README.zh.md CHANGED
@@ -1,5 +1,7 @@
1
1
  # DSH Service Console
2
2
 
3
+ [English](./README.md) | **简体中文**
4
+
3
5
  > A local development service console for DSH: discover listening ports, identify services related to the current conversation or workspace, and safely inspect, stop, or restart them.
4
6
  >
5
7
  > **DSH 本地开发服务控制台:发现监听端口,识别与当前对话或工作区相关的服务,并安全地查看、停止和重启。**
@@ -12,7 +14,10 @@
12
14
  - **归属与风险** — 五级归属:`本次对话`(与会话启动台账匹配)、`工作区`、`本机其他`、`未知`、`受保护`。
13
15
  - **受控操作** — 对进程组优雅停止;对保存了安全启动命令的服务重启。每个动作均二次确认,并在操作前重新校验快照。
14
16
  - **安全防护** — 任何信号前校验 PID 复用 / fingerprint;未知与受保护服务只读;强制终止默认关闭;无隐式自动清理;命令输出脱敏。
15
- - **范围 / 搜索 / 配置 / 国际化** — 本次对话 / 工作区 / 本机三种范围、关键字过滤、刷新间隔 / 优雅超时 / 强制终止设置、中英文。
17
+ - **全量本机服务** — 展示本机全部监听服务;归属只作为安全提示,不再隐藏端口分类,用户可自行选择要查看或停止的服务。
18
+ - **搜索 / 配置 / 国际化** — 支持关键字过滤、优雅超时 / 强制终止设置;中英文界面自动跟随 DSH 当前语言。
19
+ - **按需扫描** — 打开控制台时获取一次当前快照;点击刷新按钮才会主动重新扫描,不进行后台定时轮询。
20
+ - **DSH 原生检查卡片** — 展开详情采用 DSH Web token 化视觉风格,展示进程身份、端口、命令、工作目录和归属证据。
16
21
 
17
22
  ## 安装
18
23
 
@@ -28,6 +33,12 @@ dsh plugin --profile web add -w @jiyr0119/dsh-service-console@latest
28
33
 
29
34
  备用方式——动态粘贴(零构建、进程级):通过动态 Cordis 插件流程粘贴 `dynamic/host.js` + `dynamic/client.js`。
30
35
 
36
+ ## 界面预览
37
+
38
+ ![Service Console 0.2.0:全量本机服务与 DSH 风格检查卡片](./assets/service-console-0.2.0.gif)
39
+
40
+ 预览展示本机完整监听服务列表与展开后的检查卡片。归属徽标仍作为安全提示保留,但列表不再按对话 / 工作区 / 本机拆分隐藏服务。
41
+
31
42
  ## 权限与安全
32
43
 
33
44
  - Client 不直接传任意 PID 或 Shell 命令,只以 service ID 为目标,Host 在操作前重新校验 PID / 启动时间 / fingerprint。
@@ -44,6 +55,23 @@ npm run build
44
55
  npm test # 单元 + 集成测试(node --test)
45
56
  ```
46
57
 
58
+ ## 测试
59
+
60
+ `npm test` 会先构建一次,再用 Node 内置测试运行器(`node --test`)执行整个测试套件,无需额外测试框架。
61
+
62
+ | 文件 | 类型 | 覆盖内容 |
63
+ | --- | --- | --- |
64
+ | `test/process-inspector.test.mjs` | 单元测试 | 平台输出解析(`parseLstart`、`parseListenRows`、`parsePsRows`、`parseAddress`)、命令脱敏、五级归属分类 |
65
+ | `test/host-more.test.mjs` | 单元测试 | 配置校验、会话台账、基于 fake 依赖的生命周期状态机(停止/重启)、服务聚合与 fingerprint 稳定性 |
66
+ | `test/integration.test.mjs` | 集成测试 | 真实系统命令 + 测试自建的临时 HTTP 服务;只对测试自有进程发信号 |
67
+
68
+ ```bash
69
+ npm test # 全部用例
70
+ npm run build && node --test test/process-inspector.test.mjs # 单独运行某个文件
71
+ ```
72
+
73
+ 单元测试直接 import 构建产物(`lib/`),因此需要先编译源码——`npm test` 会自动完成。
74
+
47
75
  ## 许可证
48
76
 
49
77
  MIT
Binary file
package/dsh.plugin.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "id": "dsh-external/dsh-service-console",
3
- "version": "0.1.0",
3
+ "version": "0.2.1",
4
4
  "main": "./lib/index.js",
5
5
  "description": "本地开发服务控制台:发现监听端口,识别服务归属,安全查看/停止/重启。Local development service console for DSH.",
6
6
  "engines": {
package/dynamic/client.js CHANGED
@@ -15,7 +15,7 @@ return {
15
15
 
16
16
  const TEXTS = {
17
17
  zh: {
18
- title: 'Service Console', scopeConv: '本次对话', scopeWs: '工作区', scopeMachine: '本机',
18
+ title: 'Service Console', scopeConv: '全部本机服务', scopeWs: '全部本机服务', scopeMachine: '全部本机服务',
19
19
  search: '搜索服务/端口/路径…', auto: '5s', config: '配置', close: '关闭',
20
20
  noSvc: '未发现服务', stop: '停止', restart: '重启', detail: '详情',
21
21
  confirmStop: '确认停止?', confirmRestart: '确认重启?', confirmTxt: '确认对 {name} (pid {pid}) 执行{action}?',
@@ -23,7 +23,7 @@ return {
23
23
  evidence: '归属证据', refreshInterval: '自动刷新间隔(ms)', gracefulTimeout: '优雅超时(ms)', forceKill: '允许强制终止',
24
24
  },
25
25
  en: {
26
- title: 'Service Console', scopeConv: 'This chat', scopeWs: 'Workspace', scopeMachine: 'This Mac',
26
+ title: 'Service Console', scopeConv: 'All local services', scopeWs: 'All local services', scopeMachine: 'All local services',
27
27
  search: 'Search services/ports/paths…', auto: '5s', config: 'Config', close: 'Close',
28
28
  noSvc: 'no services found', stop: 'Stop', restart: 'Restart', detail: 'Detail',
29
29
  confirmStop: 'Confirm stop?', confirmRestart: 'Confirm restart?', confirmTxt: 'Run {action} on {name} (pid {pid})?',
@@ -63,8 +63,8 @@ return {
63
63
 
64
64
  function Panel() {
65
65
  const [open, setLocal] = React.useState(store.open)
66
- const [lang, setLang] = React.useState('zh')
67
- const [scope, setScope] = React.useState('workspace')
66
+ const locale = ctx.get('locale')
67
+ const [lang, setLang] = React.useState(() => String(locale && locale.getLocale && locale.getLocale().id || '').toLowerCase().startsWith('zh') ? 'zh' : 'en')
68
68
  const [query, setQuery] = React.useState('')
69
69
  const [showConfig, setShowConfig] = React.useState(false)
70
70
  const [configData, setConfigData] = React.useState(null)
@@ -72,11 +72,10 @@ return {
72
72
  const [confirming, setConfirming] = React.useState(null)
73
73
  const [opResult, setOpResult] = React.useState(null)
74
74
  const [expanded, setExpanded] = React.useState(null)
75
- const [autoRefresh, setAutoRefresh] = React.useState(true)
76
75
  const timeoutRef = React.useRef(null)
77
- const intervalRef = React.useRef(null)
78
76
  React.useEffect(() => subscribe(setLocal), [])
79
- React.useEffect(() => () => { if (timeoutRef.current) timeoutRef.current(); if (intervalRef.current) intervalRef.current() }, [])
77
+ React.useEffect(() => locale && locale.subscribe ? locale.subscribe(() => setLang(String(locale.getLocale().id || '').toLowerCase().startsWith('zh') ? 'zh' : 'en')) : undefined, [])
78
+ React.useEffect(() => () => { if (timeoutRef.current) timeoutRef.current() }, [])
80
79
 
81
80
  const T = TEXTS[lang]
82
81
  const scan = () => {
@@ -92,8 +91,7 @@ return {
92
91
  }
93
92
  React.useEffect(() => {
94
93
  if (open && view.phase === 'idle') scan()
95
- if (open && autoRefresh) { intervalRef.current = ctx.interval(() => scan(), 5000); return () => { if (intervalRef.current) intervalRef.current(); intervalRef.current = null } }
96
- }, [open, autoRefresh])
94
+ }, [open, view.phase])
97
95
  if (!open) return null
98
96
 
99
97
  const runAction = (svc, action) => { setConfirming({ id: svc.id, action }); setOpResult(null) }
@@ -111,9 +109,8 @@ return {
111
109
  host.call('config', { action: 'update', patch }).then((res) => { if (res && res.data) setConfigData(res.data.config) })
112
110
  }
113
111
 
112
+ // Show every listening service; ownership is a safety badge, not a visibility filter.
114
113
  let rows = (view.data && view.data.services) || []
115
- if (scope === 'conversation') rows = rows.filter((s) => s.ownership === 'conversation-confirmed')
116
- else if (scope === 'workspace') rows = rows.filter((s) => s.ownership === 'conversation-confirmed' || s.ownership === 'workspace-inferred')
117
114
  if (query) {
118
115
  const q = String(query).toLowerCase()
119
116
  rows = rows.filter((s) => String(s.name).toLowerCase().indexOf(q) >= 0 || String(s.pid).indexOf(q) >= 0 || (s.commandSummary || '').toLowerCase().indexOf(q) >= 0 || (s.cwd || '').toLowerCase().indexOf(q) >= 0 || (s.listeners || []).some((l) => String(l.port).indexOf(q) >= 0))
@@ -127,15 +124,9 @@ return {
127
124
  return React.createElement('div', { style: STYLE.panel },
128
125
  React.createElement('div', { style: { display: 'flex', alignItems: 'center', gap: 6, marginBottom: 6, flexWrap: 'wrap' } },
129
126
  React.createElement('strong', null, T.title),
130
- React.createElement('select', { value: scope, onChange: (e) => setScope(e.target.value), style: STYLE.input },
131
- React.createElement('option', { value: 'conversation' }, T.scopeConv),
132
- React.createElement('option', { value: 'workspace' }, T.scopeWs),
133
- React.createElement('option', { value: 'machine' }, T.scopeMachine)
134
- ),
135
- React.createElement('button', { onClick: () => setLang(lang === 'zh' ? 'en' : 'zh'), style: STYLE.btn }, lang === 'zh' ? 'EN' : '中'),
127
+ React.createElement('span', { style: Object.assign({}, STYLE.muted, { padding: '3px 6px', border: '1px solid var(--dsw-alias-border-l1, #444)', borderRadius: 4 }) }, T.scopeMachine),
136
128
  React.createElement('button', { onClick: () => { setShowConfig(!showConfig); if (!showConfig) loadConfig() }, style: STYLE.btn }, T.config),
137
129
  React.createElement('span', { style: { flex: 1 } }),
138
- React.createElement('label', { style: STYLE.muted }, React.createElement('input', { type: 'checkbox', checked: autoRefresh, onChange: (e) => setAutoRefresh(e.target.checked) }), T.auto),
139
130
  React.createElement('button', { onClick: scan, style: STYLE.btn }, '↻'),
140
131
  React.createElement('button', { onClick: () => setOpen(false), style: STYLE.btn }, T.close)
141
132
  ),
package/lib/client.js CHANGED
@@ -29,7 +29,7 @@ window.__ModuleLoader__.load({
29
29
  react = __toESM(react, 1);
30
30
  let react_jsx_runtime = require("react/jsx-runtime");
31
31
  //#region \0dsh-css:/home/runner/work/dsh-service-console/dsh-service-console/src/client/service-console.module.css.mjs
32
- const css = ".PuSt5a_panel{z-index:9999;background:var(--dsw-alias-bg-overlay,#262626);width:540px;max-height:min(640px,100dvh - 110px);color:var(--dsw-alias-label-primary,#eee);border:1px solid var(--dsw-alias-border-l1,#444);pointer-events:auto;border-radius:10px;padding:12px;font-family:ui-monospace,SFMono-Regular,Menlo,monospace;font-size:12px;position:fixed;top:72px;right:20px;overflow:auto;box-shadow:0 8px 32px #00000059}.PuSt5a_header{flex-wrap:wrap;align-items:center;gap:6px;margin-bottom:6px;display:flex}.PuSt5a_row{border-bottom:1px solid var(--dsw-alias-border-l1,#333);padding:8px 0}.PuSt5a_rowMain{flex-wrap:wrap;align-items:center;gap:6px;display:flex}.PuSt5a_name{font-weight:600}.PuSt5a_muted{color:var(--dsw-alias-label-secondary,#999)}.PuSt5a_ok{color:var(--dsw-alias-state-success-primary,#4ade80)}.PuSt5a_err{color:var(--dsw-alias-state-error-primary,#f87171)}.PuSt5a_warn{color:var(--dsw-alias-state-warn-primary,#fbbf24)}.PuSt5a_btn{cursor:pointer;border:1px solid var(--dsw-alias-border-l1,#555);background:var(--dsw-alias-bg-layer-1,#333);color:var(--dsw-alias-label-primary,#eee);border-radius:4px;margin-left:6px;padding:1px 6px;font-family:inherit;font-size:11px;text-decoration:none}.PuSt5a_badge{border:1px solid;border-radius:4px;padding:0 5px;font-size:10px}.PuSt5a_input{background:var(--dsw-alias-bg-layer-1,#333);color:var(--dsw-alias-label-primary,#eee);border:1px solid var(--dsw-alias-border-l1,#555);border-radius:4px;padding:2px 6px;font-family:inherit;font-size:11px}.PuSt5a_search{box-sizing:border-box;width:100%;margin-bottom:6px}.PuSt5a_spacer{flex:1}.PuSt5a_configBox{background:var(--dsw-alias-bg-layer-1,#333);border-radius:6px;margin-bottom:8px;padding:8px}.PuSt5a_configRow{align-items:center;gap:6px;margin-top:4px;display:flex}.PuSt5a_confirmRow{margin-top:4px}.PuSt5a_detailBox{background:var(--dsw-alias-bg-layer-1,#333);border-radius:6px;margin-top:4px;padding:6px}.PuSt5a_entry{border:1px solid var(--dsw-alias-border-l2);min-width:111px;height:32px;color:var(--dsw-alias-label-primary);font-family:var(--dsw-font-family);cursor:pointer;background:0 0;border-radius:18px;justify-content:center;align-items:center;gap:4px;padding:6px 12px;font-size:13px;font-weight:400;line-height:20px;display:inline-flex}.PuSt5a_entry:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover)}.PuSt5a_entryLabel,.PuSt5a_entryIcon{white-space:nowrap;flex:none}";
32
+ const css = ".PuSt5a_panel{z-index:9999;box-sizing:border-box;width:min(620px,100vw - 32px);max-height:min(760px,100dvh - 88px);color:var(--dsw-alias-label-primary,#f5f5f5);background:var(--dsw-alias-bg-overlay,#202124);border:1px solid var(--dsw-alias-border-l1,#3b3d42);font-family:var(--dsw-font-family,Inter, -apple-system, BlinkMacSystemFont, sans-serif);pointer-events:auto;border-radius:14px;padding:18px;font-size:13px;position:fixed;top:64px;right:20px;overflow:auto;box-shadow:0 18px 55px #0000006b,0 2px 8px #0003}.PuSt5a_header{border-bottom:1px solid var(--dsw-alias-border-l1,#35373c);justify-content:space-between;align-items:flex-start;gap:16px;padding-bottom:14px;display:flex}.PuSt5a_titleBlock{flex-direction:column;gap:3px;display:flex}.PuSt5a_titleBlock strong{letter-spacing:-.02em;font-size:19px}.PuSt5a_eyebrow,.PuSt5a_detailAccent,.PuSt5a_detailLabel{color:var(--dsw-alias-label-tertiary,#858991);letter-spacing:.1em;text-transform:uppercase;font-size:10px;font-weight:650}.PuSt5a_subtitle,.PuSt5a_scopeHint{color:var(--dsw-alias-label-secondary,#a8abb2);font-size:12px}.PuSt5a_headerActions{gap:5px;display:flex}.PuSt5a_iconBtn,.PuSt5a_closeBtn{cursor:pointer;border:1px solid var(--dsw-alias-border-l2,#50535a);background:var(--dsw-alias-bg-layer-1,#2a2c30);width:30px;height:30px;color:var(--dsw-alias-label-primary,#eee);border-radius:8px;padding:0;font-family:inherit}.PuSt5a_iconBtn:hover,.PuSt5a_closeBtn:hover,.PuSt5a_btn:hover{background:var(--dsw-alias-interactive-bg-hover,#383b41)}.PuSt5a_closeBtn{color:var(--dsw-alias-label-secondary,#aaa);font-size:21px;line-height:1}.PuSt5a_scopeLine{color:var(--dsw-alias-label-primary,#eee);align-items:center;gap:7px;padding:12px 0 10px;font-size:12px;display:flex}.PuSt5a_liveDot{background:var(--dsw-alias-state-success-primary,#55d187);width:7px;height:7px;box-shadow:0 0 0 3px color-mix(in srgb, var(--dsw-alias-state-success-primary,#55d187) 18%, transparent);border-radius:50%}.PuSt5a_autoRefresh{color:var(--dsw-alias-label-secondary,#aaa);font-size:11px}.PuSt5a_autoRefresh input{accent-color:var(--dsw-alias-state-success-primary,#55d187)}.PuSt5a_row{border-bottom:1px solid var(--dsw-alias-border-l1,#35373c);padding:13px 0}.PuSt5a_rowMain{flex-wrap:wrap;align-items:center;gap:7px;display:flex}.PuSt5a_name{font-size:14px;font-weight:650}.PuSt5a_muted{color:var(--dsw-alias-label-secondary,#999)}.PuSt5a_ok{color:var(--dsw-alias-state-success-primary,#55d187)}.PuSt5a_err{color:var(--dsw-alias-state-error-primary,#ff7c83)}.PuSt5a_warn{color:var(--dsw-alias-state-warn-primary,#e7b85d)}.PuSt5a_status{color:var(--dsw-alias-label-secondary,#a8abb2);margin:10px 0;font-size:11px}.PuSt5a_btn{cursor:pointer;border:1px solid var(--dsw-alias-border-l2,#50535a);background:var(--dsw-alias-bg-layer-1,#2a2c30);color:var(--dsw-alias-label-primary,#eee);font:inherit;border-radius:7px;margin-left:5px;padding:5px 9px;font-size:11px;text-decoration:none}.PuSt5a_badge{border:1px solid;border-radius:999px;padding:2px 7px;font-size:10px}.PuSt5a_input{box-sizing:border-box;border:1px solid var(--dsw-alias-border-l2,#50535a);background:var(--dsw-alias-bg-layer-1,#2a2c30);color:var(--dsw-alias-label-primary,#eee);font:inherit;border-radius:8px;padding:8px 10px;font-size:12px}.PuSt5a_search{width:100%;margin-bottom:7px}.PuSt5a_spacer{flex:1}.PuSt5a_configBox{border:1px solid var(--dsw-alias-border-l1,#35373c);background:var(--dsw-alias-bg-layer-1,#292b30);border-radius:9px;margin:10px 0;padding:11px}.PuSt5a_configRow{align-items:center;gap:8px;margin-top:7px;display:flex}.PuSt5a_confirmRow{background:color-mix(in srgb, var(--dsw-alias-state-warn-primary,#e7b85d) 9%, transparent);border-radius:8px;flex-wrap:wrap;align-items:center;gap:5px;margin-top:9px;padding:9px;display:flex}.PuSt5a_detailBox{border:1px solid var(--dsw-alias-border-l2,#50535a);background:var(--dsw-alias-bg-layer-1,#292b30);box-shadow:inset 3px 0 0 var(--dsw-alias-state-warn-primary,#e7b85d);border-radius:10px;margin-top:11px;padding:13px}.PuSt5a_detailHeader{justify-content:space-between;align-items:center;margin-bottom:12px;font-size:12px;font-weight:650;display:flex}.PuSt5a_detailAccent{color:var(--dsw-alias-state-warn-primary,#e7b85d);font-size:9px}.PuSt5a_detailGrid{grid-template-columns:repeat(2,minmax(0,1fr));gap:11px;display:grid}.PuSt5a_detailGrid>div{flex-direction:column;gap:4px;min-width:0;display:flex}.PuSt5a_detailGrid code{overflow-wrap:anywhere;color:var(--dsw-alias-label-primary,#e7e8ea);font:11px ui-monospace,SFMono-Regular,Menlo,monospace}.PuSt5a_evidenceBlock{border-top:1px solid var(--dsw-alias-border-l1,#3b3d42);margin-top:14px;padding-top:11px}.PuSt5a_evidenceItem{color:var(--dsw-alias-label-secondary,#b4b6bc);gap:7px;margin-top:6px;font-size:11px;display:flex}.PuSt5a_evidenceItem span{color:var(--dsw-alias-state-warn-primary,#e7b85d)}.PuSt5a_entry{border:1px solid var(--dsw-alias-border-l2);min-width:111px;height:32px;color:var(--dsw-alias-label-primary);font-family:var(--dsw-font-family);cursor:pointer;background:0 0;border-radius:18px;justify-content:center;align-items:center;gap:4px;padding:6px 12px;font-size:13px;font-weight:400;line-height:20px;display:inline-flex}.PuSt5a_entry:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover)}.PuSt5a_entryLabel,.PuSt5a_entryIcon{white-space:nowrap;flex:none}@media (width<=640px){.PuSt5a_panel{width:calc(100vw - 20px);max-height:calc(100dvh - 20px);top:10px;right:10px}.PuSt5a_detailGrid{grid-template-columns:1fr}}@media (prefers-reduced-motion:reduce){.PuSt5a_panel{scroll-behavior:auto}}";
33
33
  const tagId = "@jiyr0119/dsh-service-console/service-console.module.css";
34
34
  if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId) + "]") === null) {
35
35
  const tag = document.createElement("style");
@@ -39,34 +39,58 @@ window.__ModuleLoader__.load({
39
39
  document.head.appendChild(tag);
40
40
  }
41
41
  var service_console_module_css_default = {
42
- "entryLabel": "PuSt5a_entryLabel",
43
- "warn": "PuSt5a_warn",
44
- "spacer": "PuSt5a_spacer",
45
- "confirmRow": "PuSt5a_confirmRow",
46
- "ok": "PuSt5a_ok",
47
- "panel": "PuSt5a_panel",
48
- "row": "PuSt5a_row",
49
- "entryIcon": "PuSt5a_entryIcon",
50
- "configRow": "PuSt5a_configRow",
51
- "header": "PuSt5a_header",
52
- "configBox": "PuSt5a_configBox",
53
- "search": "PuSt5a_search",
54
42
  "muted": "PuSt5a_muted",
43
+ "evidenceItem": "PuSt5a_evidenceItem",
55
44
  "rowMain": "PuSt5a_rowMain",
56
45
  "input": "PuSt5a_input",
46
+ "liveDot": "PuSt5a_liveDot",
47
+ "detailHeader": "PuSt5a_detailHeader",
48
+ "titleBlock": "PuSt5a_titleBlock",
57
49
  "name": "PuSt5a_name",
58
- "btn": "PuSt5a_btn",
50
+ "subtitle": "PuSt5a_subtitle",
51
+ "headerActions": "PuSt5a_headerActions",
52
+ "search": "PuSt5a_search",
53
+ "detailLabel": "PuSt5a_detailLabel",
54
+ "confirmRow": "PuSt5a_confirmRow",
55
+ "iconBtn": "PuSt5a_iconBtn",
56
+ "configRow": "PuSt5a_configRow",
59
57
  "err": "PuSt5a_err",
58
+ "row": "PuSt5a_row",
59
+ "closeBtn": "PuSt5a_closeBtn",
60
+ "entryLabel": "PuSt5a_entryLabel",
61
+ "spacer": "PuSt5a_spacer",
62
+ "autoRefresh": "PuSt5a_autoRefresh",
63
+ "warn": "PuSt5a_warn",
64
+ "ok": "PuSt5a_ok",
65
+ "status": "PuSt5a_status",
66
+ "btn": "PuSt5a_btn",
67
+ "detailAccent": "PuSt5a_detailAccent",
60
68
  "badge": "PuSt5a_badge",
69
+ "panel": "PuSt5a_panel",
70
+ "eyebrow": "PuSt5a_eyebrow",
61
71
  "detailBox": "PuSt5a_detailBox",
62
- "entry": "PuSt5a_entry"
72
+ "detailGrid": "PuSt5a_detailGrid",
73
+ "evidenceBlock": "PuSt5a_evidenceBlock",
74
+ "entry": "PuSt5a_entry",
75
+ "configBox": "PuSt5a_configBox",
76
+ "entryIcon": "PuSt5a_entryIcon",
77
+ "header": "PuSt5a_header",
78
+ "scopeHint": "PuSt5a_scopeHint",
79
+ "scopeLine": "PuSt5a_scopeLine"
63
80
  };
64
81
  //#endregion
65
82
  //#region src/client/ServiceConsole.tsx
66
83
  let timerCtx = null;
84
+ let localeCtx = null;
67
85
  function bindTimer(t) {
68
86
  timerCtx = t;
69
87
  }
88
+ function bindLocale(locale) {
89
+ localeCtx = locale;
90
+ }
91
+ function currentLanguage() {
92
+ return String(localeCtx?.getLocale()?.id || "").toLowerCase().startsWith("zh") ? "zh" : "en";
93
+ }
70
94
  async function api(path, payload) {
71
95
  const response = await fetch("/dsh-sc/api/" + path, {
72
96
  method: "POST",
@@ -133,11 +157,8 @@ window.__ModuleLoader__.load({
133
157
  const TEXTS = {
134
158
  zh: {
135
159
  title: "Service Console",
136
- search: "搜索服务/端口/路径…",
137
- scopeConv: "本次对话",
138
- scopeWs: "工作区",
139
- scopeMachine: "本机",
140
- auto: "5s",
160
+ subtitle: "本机监听服务",
161
+ search: "搜索服务、端口或路径…",
141
162
  config: "配置",
142
163
  close: "关闭",
143
164
  noSvc: "未发现服务",
@@ -154,15 +175,16 @@ window.__ModuleLoader__.load({
154
175
  evidence: "归属证据",
155
176
  refreshInterval: "自动刷新间隔(ms)",
156
177
  gracefulTimeout: "优雅超时(ms)",
157
- forceKill: "允许强制终止"
178
+ forceKill: "允许强制终止",
179
+ allLocal: "全部本机服务",
180
+ servicesFound: "项服务",
181
+ lastScan: "最近扫描",
182
+ closePanel: "关闭面板"
158
183
  },
159
184
  en: {
160
185
  title: "Service Console",
161
- search: "Search services/ports/paths…",
162
- scopeConv: "This chat",
163
- scopeWs: "Workspace",
164
- scopeMachine: "This Mac",
165
- auto: "5s",
186
+ subtitle: "Listening services on this Mac",
187
+ search: "Search services, ports, or paths…",
166
188
  config: "Config",
167
189
  close: "Close",
168
190
  noSvc: "no services found",
@@ -179,22 +201,28 @@ window.__ModuleLoader__.load({
179
201
  evidence: "Ownership evidence",
180
202
  refreshInterval: "Refresh interval (ms)",
181
203
  gracefulTimeout: "Graceful timeout (ms)",
182
- forceKill: "Allow force kill"
204
+ forceKill: "Allow force kill",
205
+ allLocal: "All local services",
206
+ servicesFound: "services",
207
+ lastScan: "Last scan",
208
+ closePanel: "Close panel"
183
209
  }
184
210
  };
185
211
  function ServiceConsoleEntry() {
186
212
  const [open, setLocal] = react.useState(store.open);
213
+ const [lang, setLang] = react.useState(currentLanguage());
187
214
  react.useEffect(() => subscribe(setLocal), []);
215
+ react.useEffect(() => localeCtx?.subscribe(() => setLang(currentLanguage())), []);
188
216
  return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
189
217
  className: service_console_module_css_default.entry,
190
218
  onClick: () => setOpen(!store.open),
191
- title: "Service Console",
192
- "aria-label": "Service Console",
219
+ title: lang === "zh" ? "服务控制台" : "Service Console",
220
+ "aria-label": lang === "zh" ? "服务控制台" : "Service Console",
193
221
  children: [
194
222
  open ? "✕" : null,
195
223
  !open ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
196
224
  className: service_console_module_css_default.entryLabel,
197
- children: "Services"
225
+ children: lang === "zh" ? "服务" : "Services"
198
226
  }) : null,
199
227
  !open ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
200
228
  className: service_console_module_css_default.entryIcon,
@@ -205,8 +233,7 @@ window.__ModuleLoader__.load({
205
233
  }
206
234
  function ServiceConsolePanel() {
207
235
  const [open, setLocal] = react.useState(store.open);
208
- const [lang, setLang] = react.useState("zh");
209
- const [scope, setScope] = react.useState("workspace");
236
+ const [lang, setLang] = react.useState(currentLanguage());
210
237
  const [query, setQuery] = react.useState("");
211
238
  const [showConfig, setShowConfig] = react.useState(false);
212
239
  const [configData, setConfigData] = react.useState(null);
@@ -219,13 +246,11 @@ window.__ModuleLoader__.load({
219
246
  const [confirming, setConfirming] = react.useState(null);
220
247
  const [opResult, setOpResult] = react.useState(null);
221
248
  const [expanded, setExpanded] = react.useState(null);
222
- const [autoRefresh, setAutoRefresh] = react.useState(true);
223
249
  const timeoutRef = react.useRef(null);
224
- const intervalRef = react.useRef(null);
225
250
  react.useEffect(() => subscribe(setLocal), []);
251
+ react.useEffect(() => localeCtx?.subscribe(() => setLang(currentLanguage())), []);
226
252
  react.useEffect(() => () => {
227
253
  timeoutRef.current?.();
228
- intervalRef.current?.();
229
254
  }, []);
230
255
  const T = TEXTS[lang];
231
256
  const scan = react.useCallback(() => {
@@ -270,16 +295,8 @@ window.__ModuleLoader__.load({
270
295
  }, []);
271
296
  react.useEffect(() => {
272
297
  if (open && view.phase === "idle") scan();
273
- if (open && autoRefresh) {
274
- intervalRef.current = timerCtx?.interval(() => scan(), 5e3) ?? null;
275
- return () => {
276
- intervalRef.current?.();
277
- intervalRef.current = null;
278
- };
279
- }
280
298
  }, [
281
299
  open,
282
- autoRefresh,
283
300
  scan,
284
301
  view.phase
285
302
  ]);
@@ -324,24 +341,29 @@ window.__ModuleLoader__.load({
324
341
  }).catch(() => void 0);
325
342
  };
326
343
  let rows = view.data?.services ?? [];
327
- if (scope === "conversation") rows = rows.filter((s) => s.ownership === "conversation-confirmed");
328
- else if (scope === "workspace") rows = rows.filter((s) => s.ownership === "conversation-confirmed" || s.ownership === "workspace-inferred");
329
344
  if (query) {
330
345
  const q = String(query).toLowerCase();
331
346
  rows = rows.filter((s) => s.name.toLowerCase().indexOf(q) >= 0 || String(s.pid).indexOf(q) >= 0 || (s.commandSummary ?? "").toLowerCase().indexOf(q) >= 0 || (s.cwd ?? "").toLowerCase().indexOf(q) >= 0 || s.listeners.some((l) => String(l.port).indexOf(q) >= 0));
332
347
  }
333
348
  const status = view.phase === "scanning" ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
334
- className: service_console_module_css_default.warn,
335
- children: ["⏳ ", view.at]
349
+ className: service_console_module_css_default.status,
350
+ children: [
351
+ "⏳ ",
352
+ T.lastScan,
353
+ ": ",
354
+ view.at
355
+ ]
336
356
  }) : view.phase === "done" ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
337
- className: service_console_module_css_default.ok,
357
+ className: service_console_module_css_default.status,
338
358
  children: [
339
- "✅ ",
340
- view.at,
359
+ "● ",
360
+ String(rows.length),
361
+ " ",
362
+ T.servicesFound,
341
363
  " · ",
342
- String(view.data?.count ?? 0),
343
- " · ledger=",
344
- String(view.data?.ledgerCount ?? 0)
364
+ T.lastScan,
365
+ ": ",
366
+ view.at
345
367
  ]
346
368
  }) : view.phase === "error" || view.phase === "timeout" ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
347
369
  className: service_console_module_css_default.err,
@@ -352,63 +374,56 @@ window.__ModuleLoader__.load({
352
374
  children: [
353
375
  /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
354
376
  className: service_console_module_css_default.header,
377
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
378
+ className: service_console_module_css_default.titleBlock,
379
+ children: [
380
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
381
+ className: service_console_module_css_default.eyebrow,
382
+ children: "DSH / LOCAL RUNTIME"
383
+ }),
384
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("strong", { children: T.title }),
385
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
386
+ className: service_console_module_css_default.subtitle,
387
+ children: T.subtitle
388
+ })
389
+ ]
390
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
391
+ className: service_console_module_css_default.headerActions,
392
+ children: [
393
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
394
+ className: service_console_module_css_default.iconBtn,
395
+ onClick: () => {
396
+ setShowConfig(!showConfig);
397
+ if (!showConfig) loadConfig();
398
+ },
399
+ "aria-label": T.config,
400
+ children: "⚙"
401
+ }),
402
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
403
+ className: service_console_module_css_default.iconBtn,
404
+ onClick: scan,
405
+ "aria-label": "Refresh",
406
+ children: "↻"
407
+ }),
408
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
409
+ className: service_console_module_css_default.closeBtn,
410
+ onClick: () => setOpen(false),
411
+ "aria-label": T.closePanel,
412
+ children: "×"
413
+ })
414
+ ]
415
+ })]
416
+ }),
417
+ /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
418
+ className: service_console_module_css_default.scopeLine,
355
419
  children: [
356
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("strong", { children: T.title }),
357
- /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("select", {
358
- className: service_console_module_css_default.input,
359
- value: scope,
360
- onChange: (e) => setScope(e.target.value),
361
- children: [
362
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("option", {
363
- value: "conversation",
364
- children: T.scopeConv
365
- }),
366
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("option", {
367
- value: "workspace",
368
- children: T.scopeWs
369
- }),
370
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("option", {
371
- value: "machine",
372
- children: T.scopeMachine
373
- })
374
- ]
375
- }),
376
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
377
- className: service_console_module_css_default.btn,
378
- onClick: () => setLang(lang === "zh" ? "en" : "zh"),
379
- children: lang === "zh" ? "EN" : "中"
420
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { className: service_console_module_css_default.liveDot }),
421
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { children: T.allLocal }),
422
+ /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
423
+ className: service_console_module_css_default.scopeHint,
424
+ children: ["· ", T.subtitle]
380
425
  }),
381
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
382
- className: service_console_module_css_default.btn,
383
- onClick: () => {
384
- setShowConfig(!showConfig);
385
- if (!showConfig) loadConfig();
386
- },
387
- children: T.config
388
- }),
389
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { className: service_console_module_css_default.spacer }),
390
- /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("label", {
391
- className: service_console_module_css_default.muted,
392
- children: [
393
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
394
- type: "checkbox",
395
- checked: autoRefresh,
396
- onChange: (e) => setAutoRefresh(e.target.checked)
397
- }),
398
- " ",
399
- T.auto
400
- ]
401
- }),
402
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
403
- className: service_console_module_css_default.btn,
404
- onClick: scan,
405
- children: "↻"
406
- }),
407
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
408
- className: service_console_module_css_default.btn,
409
- onClick: () => setOpen(false),
410
- children: T.close
411
- })
426
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { className: service_console_module_css_default.spacer })
412
427
  ]
413
428
  }),
414
429
  /* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
@@ -565,30 +580,55 @@ window.__ModuleLoader__.load({
565
580
  }) : null,
566
581
  expanded === svc.id ? /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
567
582
  className: service_console_module_css_default.detailBox,
583
+ role: "region",
584
+ "aria-label": T.detail,
568
585
  children: [
569
586
  /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
570
- className: service_console_module_css_default.muted,
571
- children: ["id: ", svc.id]
587
+ className: service_console_module_css_default.detailHeader,
588
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { children: T.detail }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
589
+ className: service_console_module_css_default.detailAccent,
590
+ children: "SERVICE RECORD"
591
+ })]
572
592
  }),
573
593
  /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
574
- className: service_console_module_css_default.muted,
594
+ className: service_console_module_css_default.detailGrid,
575
595
  children: [
576
- "pgid: ",
577
- String(svc.processGroupId ?? "-"),
578
- " · ppid: ",
579
- String(svc.parentPid ?? "-"),
580
- " · startedAt: ",
581
- String(svc.startedAt ?? "-")
596
+ /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
597
+ className: service_console_module_css_default.detailLabel,
598
+ children: "SERVICE ID"
599
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("code", { children: svc.id })] }),
600
+ /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
601
+ className: service_console_module_css_default.detailLabel,
602
+ children: "PROCESS"
603
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("code", { children: [
604
+ "PID ",
605
+ svc.pid,
606
+ " · PGID ",
607
+ String(svc.processGroupId ?? "-")
608
+ ] })] }),
609
+ /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
610
+ className: service_console_module_css_default.detailLabel,
611
+ children: "PARENT"
612
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("code", { children: ["PPID ", String(svc.parentPid ?? "-")] })] }),
613
+ /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
614
+ className: service_console_module_css_default.detailLabel,
615
+ children: "STARTED"
616
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("code", { children: String(svc.startedAt ?? "-") })] })
582
617
  ]
583
618
  }),
584
619
  /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
585
- className: service_console_module_css_default.muted,
586
- children: [T.evidence, ":"]
587
- }),
588
- svc.ownershipEvidence.map((ev, i) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
589
- className: service_console_module_css_default.muted,
590
- children: [" · ", ev]
591
- }, i))
620
+ className: service_console_module_css_default.evidenceBlock,
621
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
622
+ className: service_console_module_css_default.detailLabel,
623
+ children: T.evidence
624
+ }), svc.ownershipEvidence.length ? svc.ownershipEvidence.map((ev, i) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
625
+ className: service_console_module_css_default.evidenceItem,
626
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { children: "↳" }), ev]
627
+ }, i)) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
628
+ className: service_console_module_css_default.muted,
629
+ children: "—"
630
+ })]
631
+ })
592
632
  ]
593
633
  }) : null
594
634
  ]
@@ -602,6 +642,8 @@ window.__ModuleLoader__.load({
602
642
  inject: ["slots", "timer"],
603
643
  apply(ctx) {
604
644
  bindTimer(ctx.timer);
645
+ const locale = ctx.get("locale");
646
+ if (locale) bindLocale(locale);
605
647
  const slots = ctx.get("slots");
606
648
  if (slots === void 0) return;
607
649
  slots.inject("conversation.session.header.utilities", () => slots.register({
@@ -1,9 +1,14 @@
1
1
  import * as React from 'react';
2
2
  interface TimerLike {
3
3
  timeout(callback: () => void, delay: number): () => void;
4
- interval(callback: () => void, delay: number): () => void;
5
4
  }
6
5
  export declare function bindTimer(t: TimerLike): void;
6
+ export declare function bindLocale(locale: {
7
+ getLocale: () => {
8
+ id?: string;
9
+ };
10
+ subscribe: (fn: () => void) => () => void;
11
+ }): void;
7
12
  export declare function ServiceConsoleEntry(): React.ReactElement;
8
13
  export declare function ServiceConsolePanel(): React.ReactElement | null;
9
14
  export {};
@@ -4,7 +4,6 @@ declare const _default: {
4
4
  get(name: string): unknown;
5
5
  timer: {
6
6
  timeout(cb: () => void, ms: number): () => void;
7
- interval(cb: () => void, ms: number): () => void;
8
7
  };
9
8
  }): void;
10
9
  };
package/manifest.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "id": "dsh-service-console",
3
3
  "name": "服务控制台 (Service Console)",
4
- "version": "0.1.0",
4
+ "version": "0.2.1",
5
5
  "description": "本地开发服务控制台:发现监听端口,识别归属,安全停止/重启",
6
6
  "kind": "dynamic-cordis-plugin",
7
7
  "platforms": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jiyr0119/dsh-service-console",
3
- "version": "0.1.1",
3
+ "version": "0.2.1",
4
4
  "description": "DeepSeek Harness 本地开发服务控制台(原生插件):发现监听端口,识别服务归属,安全查看/停止/重启。Local development service console for DSH.",
5
5
  "license": "MIT",
6
6
  "type": "module",