@qzsy/dsh-bridge 2.18.0 → 3.0.0

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.
Files changed (81) hide show
  1. package/CHANGELOG.md +12 -1098
  2. package/LICENSE +21 -21
  3. package/README.md +72 -476
  4. package/client/build.mjs +1 -3
  5. package/client/client.js +381 -9747
  6. package/client/index.js +242 -6828
  7. package/client/locales.mjs +99 -233
  8. package/cordis.patch.yml +5 -3
  9. package/lib/config.js +93 -0
  10. package/lib/data-dir.js +16 -0
  11. package/lib/dsh-cookie.js +111 -0
  12. package/lib/gate.js +382 -0
  13. package/lib/identity.js +23 -0
  14. package/lib/index.js +302 -3496
  15. package/lib/saas/tunnel-client.mjs +529 -467
  16. package/locale/en.json +3 -3
  17. package/locale/zh.json +3 -3
  18. package/package.json +15 -70
  19. package/README.en.md +0 -488
  20. package/client/host-families.js +0 -442
  21. package/client/mobile-styles.js +0 -1299
  22. package/client/mobile-yield.js +0 -219
  23. package/client/panel-locales.mjs +0 -777
  24. package/client/picker-yield.js +0 -77
  25. package/client/resource-url-compat.js +0 -90
  26. package/client/settings-nav-icon.js +0 -105
  27. package/client/theme-tokens.js +0 -49
  28. package/client/tunnel-guard.js +0 -46
  29. package/client/unlock-manager.js +0 -144
  30. package/lib/auth/dsh-native-cookie.js +0 -148
  31. package/lib/auth/login-template.js +0 -516
  32. package/lib/auth/manager.js +0 -596
  33. package/lib/bridge-rpc-constants.js +0 -66
  34. package/lib/bridge-rpc.js +0 -722
  35. package/lib/cloudflared-manager.mjs +0 -1277
  36. package/lib/cloudflared-network-args.js +0 -99
  37. package/lib/cloudflared-process-scan.js +0 -153
  38. package/lib/compat.js +0 -172
  39. package/lib/connection-compat.js +0 -115
  40. package/lib/feishu/comment.js +0 -50
  41. package/lib/feishu/gateway.js +0 -644
  42. package/lib/feishu/index.js +0 -432
  43. package/lib/feishu/lark-bundled.mjs +0 -131929
  44. package/lib/feishu/markdown.js +0 -148
  45. package/lib/feishu/node.js +0 -1152
  46. package/lib/feishu/slash-commands.js +0 -255
  47. package/lib/platform/account-ops.js +0 -248
  48. package/lib/platform/activity.js +0 -169
  49. package/lib/platform/ask-user.js +0 -293
  50. package/lib/platform/base.js +0 -147
  51. package/lib/platform/changes-digest.js +0 -93
  52. package/lib/platform/commands.js +0 -267
  53. package/lib/platform/config-restore.js +0 -78
  54. package/lib/platform/conversation-bridge.js +0 -1544
  55. package/lib/platform/dsh-storage.js +0 -222
  56. package/lib/platform/index.js +0 -10
  57. package/lib/platform/instances.js +0 -458
  58. package/lib/platform/manager.js +0 -130
  59. package/lib/platform/message-split.js +0 -229
  60. package/lib/platform/session-catalog.js +0 -405
  61. package/lib/platform/session-config.js +0 -52
  62. package/lib/platform/stream-slices.js +0 -21
  63. package/lib/qq/gateway.js +0 -1107
  64. package/lib/qq/index.js +0 -561
  65. package/lib/qq/node.js +0 -1153
  66. package/lib/qq/qqbot-bundled.mjs +0 -8273
  67. package/lib/restart-helper.mjs +0 -133
  68. package/lib/security/log-sanitize.js +0 -50
  69. package/lib/security/path-validator.js +0 -195
  70. package/lib/security/rate-limiter.js +0 -93
  71. package/lib/session-strip.js +0 -100
  72. package/lib/sse-keepalive.js +0 -115
  73. package/lib/telegram/gateway.js +0 -643
  74. package/lib/telegram/index.js +0 -255
  75. package/lib/telegram/node.js +0 -410
  76. package/lib/tunnel-client.mjs +0 -537
  77. package/lib/wechat/gateway.js +0 -1000
  78. package/lib/wechat/index.js +0 -282
  79. package/lib/wechat/media.js +0 -302
  80. package/lib/wechat/node.js +0 -360
  81. package/llms.txt +0 -36
@@ -1,777 +0,0 @@
1
- // dsh-bridge 设置面板 / 移动端弹窗的中英文词典(渲染层兜底翻译用)。
2
- //
3
- // 设计(与 locales.mjs 的语义化键词典并存,两者分工不同):
4
- // - locales.mjs 的 `zh` / `en` 是**语义化键**(如 'menu.open'),用于 DOM 注入、
5
- // innerHTML、aria/title 属性等「拿不到原文上下文」的调用点;
6
- // - 本文件的 `panelEn` 是**中文原文 → 英文译文**的映射(gettext 风格),用于
7
- // React 渲染层:client/index.js 的 `h()` 包装器在渲染时把字符串子节点 / title /
8
- // placeholder / aria-label / alt 交给 localeT(),精确命中词典才替换,未命中
9
- // 原样返回(用户数据、路径、代码、日志绝不会被误翻)。
10
- //
11
- // 约定:
12
- // - 键必须是源码里**原样**出现的字符串(含 emoji 与标点),由
13
- // test/panel-i18n.test.mjs 强制:源码新出现的中文文案若不在词典里就测试失败;
14
- // - 动态拼接的键用 `${name}` 占位符,调用 `localeT('…${name}…', { name })`;
15
- // - 值为数组时表示英文单复数 `[单数, 复数]`,按 `vars.count` 选择(中文无此需求)。
16
- //
17
- // 中文模式下 localeT() 直接返回原文(键本身),所以这里只需维护英文。
18
- // 维护方式见 test/panel-i18n.test.mjs 的失败提示(新增中文文案必须补词条)。
19
-
20
- /** @type {Record<string, string | [string, string]>} */
21
- export const panelEn = {
22
- "运行中": "Running",
23
- "未启动": "Not started",
24
- "已连接": "Connected",
25
- "下载中…": "Downloading…",
26
- "连接中…": "Connecting…",
27
- "自动重连中…": "Reconnecting…",
28
- "暂停中": "Paused",
29
- "异常": "Error",
30
- "点击前往「安全认证」配置": "Click to open Security settings",
31
- "🛡️ 访问安全认证已生效 · 扫码设备免密": "🛡️ Access protection is on · QR devices skip the password",
32
- "设置 ➔": "Settings ➔",
33
- "点击前往「安全认证」开启访问保护": "Click to enable access protection in “Security”",
34
- "⚠️ 当前未开启访问认证,建议在「安全认证」开启密码或扫码保护。": "⚠️ Access protection is off. Enable a password or QR protection under “Security”.",
35
- "去开启 ➔": "Enable ➔",
36
- "✓ 已复制": "✓ Copied",
37
- "复制链接": "Copy link",
38
- "隐藏二维码": "Hide QR code",
39
- "显示二维码": "Show QR code",
40
- "请在私密环境下使用": "Use in a private environment",
41
- "📱 提示:手机浏览器扫码打开后,在菜单点击「添加到主屏幕」即可作为独立全屏 App 运行。": "📱 Tip: after scanning with your phone, tap “Add to Home Screen” in the browser menu to run it as a standalone full-screen app.",
42
- "关闭隧道并重新开启,可获得新的 URL": "Stop and restart the tunnel to get a new URL",
43
- "🔄 重置链接": "🔄 Reset link",
44
- "🛜 局域网网卡 / IP 选择": "🛜 LAN adapter / IP selection",
45
- "切换中…": "Switching…",
46
- "检测到主机存在多张网卡(如物理 Wi-Fi、以太网、WSL 或虚拟机)。若默认 IP 无法被移动端访问,可手动切换:": "Multiple network adapters detected (e.g. Wi-Fi, Ethernet, WSL or a VM). If the default IP is unreachable from your phone, switch manually:",
47
- "${address} · ${name} [虚拟/WSL]": "${address} · ${name} [virtual/WSL]",
48
- "查看自建隧道服务器搭建教程": "View the self-hosted tunnel server guide",
49
- "公网访问入口": "Public access entry",
50
- "尚未配置任何公网隧道,可在下方开启 Cloudflare 隧道或配置自建隧道": "No public tunnel configured yet — enable the Cloudflare tunnel below or set up a self-hosted tunnel.",
51
- "复制": "Copy",
52
- "停止重连": "Stop reconnecting",
53
- "关闭": "Close",
54
- "关闭并重新开启,更换临时地址": "Stop and restart to get a new temporary address",
55
- "请先在「隧道配置」中保存服务器配置": "Save the server configuration under “Tunnel configuration” first",
56
- "开启公网隧道": "Enable public tunnel",
57
- "请在私密环境下扫码使用": "Scan in a private environment",
58
- "DSH 启动时自动恢复该隧道的运行状态": "Restore this tunnel automatically when DSH starts",
59
- "随 DSH 启动自动开启": "Start automatically with DSH",
60
- "隧道配置": "Tunnel configuration",
61
- "Token · 固定域名 · 自建服务器 · 外部登记": "Token · fixed domain · self-hosted server · external registration",
62
- "收起 ▴": "Collapse ▴",
63
- "展开 ▾": "Expand ▾",
64
- "保存配置失败": "Failed to save configuration",
65
- "隧道服务器配置": "Tunnel server configuration",
66
- "WebSocket 地址,例如 wss://tunnel.example.com/connect": "WebSocket URL, e.g. wss://tunnel.example.com/connect",
67
- "隧道服务端连接令牌(Tunnel Access Token)": "Tunnel server access token",
68
- "💡 用于与您的 VPS 隧道服务端建立反向通道(与 Web 网页访客访问密码互相独立)。": "💡 Used to open a reverse channel to your VPS tunnel server (independent of the visitor access password).",
69
- "保存中…": "Saving…",
70
- "✓ 已保存": "✓ Saved",
71
- "保存配置": "Save configuration",
72
- "请先保存服务器配置": "Save the server configuration first",
73
- "开启": "Enable",
74
- "✅ 数据面正常(每 60s 探测公网入口${ip})": "✅ Data plane healthy (public entry probed every 60s${ip})",
75
- "⚠️ 数据面间歇失败(连续 ${count} 次):${reason}": "⚠️ Data plane failing intermittently (${count} in a row): ${reason}",
76
- "原因未知": "Unknown cause",
77
- "❌ 数据面不可达(连续 ${count} 次):${reason}": "❌ Data plane unreachable (${count} in a row): ${reason}",
78
- "数据面探测:${reason}": "Data plane probe: ${reason}",
79
- "⚠️ 检测到另一个 cloudflared(PID ${pid},凭据来源 --${via})正在使用相同的 tunnel token:隧道状态可能只反映一半,请停用其中一侧": "⚠️ Another cloudflared (PID ${pid}, credentials via --${via}) is using the same tunnel token: the status may only reflect half the picture — stop one of them.",
80
- "系统安装(不参与版本钉死)": "System installation (version not pinned)",
81
- "插件内置": "Bundled with the plugin",
82
- "外部指定": "Externally specified",
83
- "版本未知": "Version unknown",
84
- "网络协议": "Network protocol",
85
- "默认(auto)": "Default (auto)",
86
- "强制 QUIC": "Force QUIC",
87
- "强制 HTTP/2": "Force HTTP/2",
88
- "边缘 IP": "Edge IP",
89
- "默认(4)": "Default (4)",
90
- "自动(auto)": "Auto",
91
- "边缘区域": "Edge region",
92
- "全球(默认)": "Global (default)",
93
- "美国(us)": "United States (us)",
94
- "✓ 固定域名配置已保存": "✓ Fixed-domain configuration saved",
95
- "保存失败": "Save failed",
96
- "⚙️ 高级配置:固定域名 (Cloudflare Token) ": "⚙️ Advanced: fixed domain (Cloudflare Token) ",
97
- "● 已配置固定域名": "● Fixed domain configured",
98
- "▴ 折叠": "▴ Collapse",
99
- "▾ 展开": "▾ Expand",
100
- "在 Cloudflare Zero Trust 控制台创建 Tunnel 即可获取专属 Token 并绑定自己的域名(如 dsh.yourname.com),每次重启 URL 永不变更。不填则使用默认免登录临时随机域名。": "Create a Tunnel in the Cloudflare Zero Trust dashboard to get a dedicated Token and bind your own domain (e.g. dsh.yourname.com); the URL then stays the same across restarts. Leave empty to use the default random temporary domain without login.",
101
- "📖 查看「Cloudflare 固定域名」申请与配置教程": "📖 Read the “Cloudflare fixed domain” setup guide",
102
- "自定义固定域名 (例如: dsh.yourdomain.com)": "Custom fixed domain (e.g. dsh.yourdomain.com)",
103
- "Tunnel Token (例如: eyJhIjoi...)": "Tunnel Token (e.g. eyJhIjoi...)",
104
- "网络参数取值来自 Cloudflare 官方白名单;改动需重新开启隧道(关闭→开启)后生效,当前二进制不支持的参数会自动跳过并在日志告警。": "Network parameters come from Cloudflare's official whitelist; changes take effect after restarting the tunnel (stop → start). Parameters unsupported by the current binary are skipped with a log warning.",
105
- "保存固定域名配置": "Save fixed-domain configuration",
106
- "清除": "Clear",
107
- "✓ 外部隧道地址已登记": "✓ External tunnel address registered",
108
- "✓ 已清除登记": "✓ Registration cleared",
109
- "外部已部署隧道": "Externally deployed tunnel",
110
- "已在 Docker / 服务器上自行部署隧道(如 cloudflared)时,登记公网地址即可在面板展示入口与二维码;插件不会重复下载或管理该隧道。": "If you already run a tunnel yourself (e.g. cloudflared in Docker or on a server), register its public URL to show the entry and QR code here; the plugin will not download or manage it.",
111
- "https://tunnel.yourdomain.com 或 trycloudflare 地址": "https://tunnel.yourdomain.com or a trycloudflare address",
112
- "保存": "Save",
113
- "「仅密码 / PIN 码登录」模式必须先设置访问密码才能开启安全防护。\n\n请先在下方「设置外部访客访问密码 / PIN 码」输入密码并点击「保存访问密码」,然后再开启。": "“Password / PIN only” mode needs an access password before protection can be enabled.\n\nSet one below under “External visitor access password / PIN”, click “Save access password”, then enable it.",
114
- "请先设置访客访问密码,再开启安全防护": "Set a visitor access password before enabling protection",
115
- "⚠️ 您尚未设置任何访问密码或管理密码。\n\n开启安全防护后,任何知道局域网 IP / 隧道地址的访客仍可直接进入(当前相当于\"免密开放\"状态)。\n\n是否仍要开启?建议先关闭,在下方「设置外部访客访问密码」处设置密码后再开启。": "⚠️ You have not set any access or admin password yet.\n\nWith protection enabled, anyone who knows the LAN IP / tunnel address can still get in (currently equivalent to “open, no password”).\n\nEnable anyway? It is better to set a password below under “External visitor access password” first.",
116
- "更新失败": "Update failed",
117
- "✓ 安全防护已开启(注意:尚未设置密码,访客仍可免密进入,请立即在下方设置访问密码)": "✓ Protection enabled (note: no password set yet — visitors can still enter without one; set an access password below now)",
118
- "✓ 访问安全认证已开启(现有登录态已刷新)": "✓ Access protection enabled (existing sessions refreshed)",
119
- "✓ 访问安全认证已关闭(访问免密,管理保护不受影响)": "✓ Access protection disabled (access is password-free; admin protection is unaffected)",
120
- "✓ 管理保护已开启(修改配置需管理密码)": "✓ Admin protection enabled (configuration changes require the admin password)",
121
- "✓ 管理保护已关闭(修改配置免密,请谨慎)": "✓ Admin protection disabled (configuration changes need no password — be careful)",
122
- "「仅密码 / PIN 码登录」需要先设置访问密码。\n\n请在下方「设置外部访客访问密码 / PIN 码」处输入密码并点击「保存访问密码」,然后再切换到此模式或开启安全防护。": "“Password / PIN only” needs an access password first.\n\nSet one below under “External visitor access password / PIN”, click “Save access password”, then switch to this mode or enable protection.",
123
- "请先在下方设置访客访问密码,再切换为「仅密码登录」模式": "Set a visitor access password below before switching to “Password only”",
124
- "✓ 外部验证模式已切换,已刷新全域登录态": "✓ Verification mode switched; all sessions refreshed",
125
- "✓ 防护生效范围已更新": "✓ Protection scope updated",
126
- "✓ 远程管理防篡改策略已更新": "✓ Remote management policy updated",
127
- "✓ 访客访问密码已成功保存!原有的历史访客会话已全部安全刷新。": "✓ Visitor access password saved. All previous visitor sessions were refreshed.",
128
- "✓ 后台管理密码已成功保存!远程管理解锁状态已重置生效。": "✓ Admin password saved. The remote-management unlock state was reset.",
129
- "重置后,之前包含旧 Token 的二维码和分享链接将立即失效。是否确认重置?": "Resetting invalidates every previously shared QR code and link containing the old Token. Reset now?",
130
- "重置失败": "Reset failed",
131
- "✓ 安全 Token 已重置,二维码与专属链接已刷新": "✓ Security Token reset; QR code and share link refreshed",
132
- "全部通道 (局域网+公网)": "All channels (LAN + public)",
133
- "仅公网隧道": "Public tunnel only",
134
- "仅局域网": "LAN only",
135
- "扫码免密 + 密码": "QR (no password) + password",
136
- "仅密码登录": "Password only",
137
- "仅安全 Token": "Security Token only",
138
- "需密码解锁": "Password unlock required",
139
- "仅限电脑本机管理": "This computer only",
140
- "宽松模式": "Relaxed",
141
- "🔐 全局访问安全防护体系": "🔐 Global access protection",
142
- "集成外部访问门禁拦截与管理后台防篡改控制,双重守护远程会话与网络配置安全": "External access gating plus admin anti-tamper control, guarding both remote sessions and network configuration",
143
- "✓ 已启用安全防护": "✓ Protection enabled",
144
- "未开启安全防护": "Protection disabled",
145
- "🌐 保护范围: ": "🌐 Scope: ",
146
- "🔑 外部验证: ": "🔑 External verification: ",
147
- "🔒 后台防篡改: ": "🔒 Admin anti-tamper: ",
148
- "尚未设置任何访问密码或管理密码": "No access or admin password set yet",
149
- " —— 此时“访问认证已开启”但任何知道局域网 IP / 隧道地址的人都能直接进入(隧道入口自身不设防,详见下方安全须知)。": " — access protection is on, but anyone who knows the LAN IP / tunnel address can still enter (the tunnel entry itself is unprotected; see the security notes below).",
150
- "建议立即在下方设置": "Set it below now:",
151
- "访客访问密码": "visitor access password",
152
- "或": "or",
153
- "管理密码": "admin password",
154
- "后再对外开放。": "before exposing it publicly.",
155
- "🛡️ 第一道防线:外部访问门禁(控制谁能使用 AI)": "🛡️ First line: external access gate (who may use the AI)",
156
- "控制外部设备通过局域网 IP 或公网隧道(Cloudflare/自建隧道)进入 DSH 聊天界面时的身份验证方式": "How external devices authenticate when reaching the DSH chat UI over the LAN IP or a public tunnel (Cloudflare / self-hosted)",
157
- "验证模式选择": "Verification mode",
158
- "🟢 扫码免密 + 密码认证 (推荐)": "🟢 QR (no password) + password (recommended)",
159
- "二维码自带专属 Token 扫码秒进;直接输 IP/公网域名需输密码": "QR codes carry a dedicated Token for instant access; typing the IP/public domain requires the password",
160
- "🔑 仅密码 / PIN 码登录": "🔑 Password / PIN only",
161
- "所有外部访问必须手动输入访问密码方可进入": "All external access requires the access password",
162
- "🎫 仅安全 Token 免密": "🎫 Security Token only (no password)",
163
- "仅持有带安全 Token 的二维码或专属分享链接方可进入": "Only QR codes or share links carrying the Security Token can get in",
164
- "防护生效通道": "Protected channels",
165
- "全部通道防护 (推荐)": "All channels (recommended)",
166
- "局域网 IP 直连与公网隧道全部受安全保护": "Both direct LAN IP access and the public tunnel are protected",
167
- "仅公网隧道开启防护": "Public tunnel only",
168
- "局域网内设备直接免密直连,公网隧道强制验证": "LAN devices connect without a password; the public tunnel always verifies",
169
- "仅局域网开启防护": "LAN only",
170
- "仅局域网直连需验证,公网隧道不开启": "Direct LAN access is verified; the public tunnel is not protected",
171
- "设置外部访客访问密码 ${status}": "External visitor access password ${status}",
172
- "(✓ 已设置访客密码)": "(✓ visitor password set)",
173
- "(⚠️ 尚未设置密码,直接输入 IP 将免密)": "(⚠️ no password yet — typing the IP grants access without one)",
174
- "输入新密码以修改(留空保存可清除访客密码)": "Enter a new password to change it (save empty to clear the visitor password)",
175
- "设置外部访客访问密码 / PIN 码": "Set external visitor access password / PIN",
176
- "隐藏": "Hide",
177
- "显示": "Show",
178
- "✓ 已成功保存!": "✓ Saved successfully!",
179
- "保存访问密码": "Save access password",
180
- "💡 当外部朋友或同事未通过二维码扫码,而是直接输入 IP 或公网域名访问时,需输入此密码登录。": "💡 Friends or colleagues who type the IP or public domain instead of scanning the QR code must enter this password to sign in.",
181
- "免密扫码 Token (专属访问凭据)": "Password-free QR Token (dedicated credential)",
182
- "未生成": "Not generated",
183
- "重新生成 Token,使之前分享的旧二维码和链接立即失效": "Regenerate the Token to invalidate previously shared QR codes and links",
184
- "🔄 重置安全 Token": "🔄 Reset Security Token",
185
- "💡 控制台生成的局域网与公网二维码已自动嵌入此 Token,手机扫码即可免密进入聊天界面(但不赋予后台管理设置权限)。": "💡 The LAN and public QR codes generated here already embed this Token, so a phone scans straight into the chat without a password (admin settings are not granted).",
186
- "🔒 第二道防线:管理后台防篡改(控制谁能修改本插件所有设置)": "🔒 Second line: admin anti-tamper (who may change this plugin's settings)",
187
- "锁定整个插件设置后台(包含局域网、公网隧道、IM 机器人密钥与安全设置),防止他人随意篡改配置": "Locks the whole settings console (LAN, public tunnel, IM bot secrets and security settings) against tampering",
188
- "🛡️ 管理保护已开启(修改配置需管理密码)": "🛡️ Admin protection is on (changes require the admin password)",
189
- "⚠️ 管理保护已关闭(修改配置免密)": "⚠️ Admin protection is off (changes need no password)",
190
- "关闭管理保护": "Disable admin protection",
191
- "开启管理保护": "Enable admin protection",
192
- "设置独立管理员密码 ${status}": "Set a dedicated admin password ${status}",
193
- "(✓ 已设置独立管理密码)": "(✓ dedicated admin password set)",
194
- "(未单独设置,默认使用上述访客访问密码)": "(not set — the visitor access password above is used)",
195
- "输入新密码以修改(留空保存可清除独立管理密码)": "Enter a new password to change it (save empty to clear the dedicated admin password)",
196
- "设置后台管理解锁密码(建议与访客密码不同)": "Set the admin unlock password (different from the visitor password is recommended)",
197
- "保存管理密码": "Save admin password",
198
- "🔑 核心作用:用于远程设备进入设置后台时的解锁验证。设置后,即便把访问密码告知他人,他人也无法进入设置后台改配置。": "🔑 Used to unlock the admin console from remote devices. Once set, sharing the access password no longer lets others change settings here.",
199
- "远程设备管理权限策略": "Remote device management policy",
200
- "🔒 需密码解锁 (推荐)": "🔒 Password unlock (recommended)",
201
- "远程手机/外网打开本插件设置时默认全局锁定,输入管理密码解锁后方可使用": "Remote phones/internet sessions start locked; unlock with the admin password to use the console",
202
- "🚫 仅限电脑本机管理 (最严格)": "🚫 This computer only (strictest)",
203
- "远程设备彻底锁定整个设置后台,仅允许在 127.0.0.1 电脑本机上操作": "Remote devices are fully locked out; only 127.0.0.1 on this computer may manage",
204
- "🔓 宽松模式": "🔓 Relaxed",
205
- "任何已通过第一道防线登录的设备均可直接修改所有配置": "Any device that passed the first line may change all settings",
206
- "添加白名单失败": "Failed to add to allowlist",
207
- "加载中…": "Loading…",
208
- "重连中…": "Reconnecting…",
209
- "暂停(会话过期)": "Paused (session expired)",
210
- "错误": "Error",
211
- "未连接": "Disconnected",
212
- "推荐": "Recommended",
213
- "📖 微信使用说明": "📖 WeChat guide",
214
- "📖 QQ 使用说明": "📖 QQ guide",
215
- "🌐 QQ 开放平台": "🌐 QQ Open Platform",
216
- "📖 飞书使用说明": "📖 Lark / Feishu guide",
217
- "🌐 飞书开放平台": "🌐 Lark / Feishu Open Platform",
218
- "📖 Telegram 使用说明": "📖 Telegram guide",
219
- "🌐 @BotFather 申请 Bot": "🌐 Create a bot via @BotFather",
220
- "收起命令": "Hide commands",
221
- "命令列表": "Command list",
222
- "/new <提示词> — 新建会话并开始(当前工作区)": "/new <prompt> — start a new session (current workspace)",
223
- "/new <提示词> @N — 在指定工作区新建会话": "/new <prompt> @N — start a session in workspace N",
224
- "/sessions(或 /list)— 列出会话(按工作区分组,带标题)": "/sessions (or /list) — list sessions (grouped by workspace, with titles)",
225
- "/use N(或 /resume N)— 切换到会话 N": "/use N (or /resume N) — switch to session N",
226
- "/workspaces — 列出所有可用工作区": "/workspaces — list all available workspaces",
227
- "/end — 结束当前会话(回到无活动会话状态)": "/end — end the current session (back to no active session)",
228
- "/stop — 停止当前任务": "/stop — stop the current task",
229
- "/status — 查看 Agent 状态与会话摘要": "/status — show agent status and session summary",
230
- "/yes 或 /no(或 1/2)— 回应权限审批请求": "/yes or /no (or 1/2) — answer an approval request",
231
- "/help — 显示完整命令帮助": "/help — show full command help",
232
- "连接状态": "Connection status",
233
- "登录账号": "Signed-in account",
234
- "活动会话": "Active session",
235
- "白名单 (已授权 ${count} 个账号/群):": "Allowlist (${count} authorized):",
236
- "移出白名单": "Remove from allowlist",
237
- "(空 — 扫码后首个发消息的微信用户将自动加入)": "(empty — the first WeChat user to message the bot is added automatically)",
238
- "(空 — 首个发消息的用户将自动加入)": "(empty — the first user to message the bot is added automatically)",
239
- "添加允许的微信 ID(如 xxx@im.wechat),按 Enter 添加": "Add an allowed WeChat ID (e.g. xxx@im.wechat), press Enter",
240
- "添加允许的用户/群 ID,按 Enter 添加": "Add an allowed user/group ID, press Enter",
241
- "添加": "Add",
242
- "使用已保存的凭证直接恢复连接,无需重新扫码": "Reconnect with the saved credentials — no need to scan again",
243
- "首次使用需扫码绑定": "First-time use requires scanning to bind",
244
- "重新连接": "Reconnect",
245
- "连接": "Connect",
246
- "停止接收消息;凭证保留,可随时\"重新连接\"恢复": "Stop receiving messages; credentials are kept — use “Reconnect” anytime",
247
- "断开": "Disconnect",
248
- "确认解绑?这将清除保存的凭证。": "Unbind? This clears the saved credentials.",
249
- "清除登录凭证,下次需重新配置": "Clear the login credentials; reconfigure next time",
250
- "解绑账号": "Unbind account",
251
- "开启后,白名单之外的新群首次 @机器人 即自动授权入白名单;关闭(默认)时新群必须先在此手动添加": "When on, a new group is auto-authorized the first time it @mentions the bot; when off (default) you must add it here first",
252
- "群聊自动授权(新群首次 @机器人 自动加入白名单,默认关闭)": "Group auto-authorization (first @mention joins the allowlist; default off)",
253
- "开启后,每轮结束会把\"改了哪些文件(+增/-删)\"播报到当前会话;/diff 可导出 .patch 补丁": "When on, each turn ends with a summary of changed files (+added/-removed); /diff exports a .patch",
254
- "本轮改动摘要(每轮播报改动文件清单,默认开启)": "Turn change summary (broadcast changed files each turn; default on)",
255
- "开启后,Agent 执行任务期间发消息会插话注入到当前轮次的下一步(不打断正在运行的工具调用);关闭后排队等待当前任务完成后处理": "When on, messages sent while the Agent is working are injected at its next step (running tool calls are not interrupted); when off, messages wait until the current turn finishes",
256
- "开启后单聊回复以流式消息逐段输出(同一条消息原地变长);关闭后等一轮结束再一次性发送。群聊平台不支持流式,始终一次性发送。": "When on, DM replies stream progressively (the same message grows in place); when off, the whole reply is sent once the turn ends. Group chats do not support streaming and are always sent at once.",
257
- "单聊流式输出(逐段显示,默认开启;群聊不支持)": "Streaming replies in DMs (progressive display, on by default; groups not supported)",
258
- "实时插话模式(Agent 忙碌时发消息可在下一步生效,默认关闭)": "Realtime steering (messages reach a busy Agent at its next step; default off)",
259
- "开启后 Agent 干活时卡片顶部会实时显示当前动作(如「正在运行命令」);关闭后不再显示": "When on, the card header shows the agent's current action live (e.g. “Running command”); when off it is hidden",
260
- "实时活动状态(卡片顶部显示「正在运行命令」等,默认关闭)": "Live activity status (shows “Running command” etc. atop the card; default off)",
261
- "收起高级设置": "Hide advanced settings",
262
- "⚙️ 高级设置": "⚙️ Advanced settings",
263
- "以下设置按平台保存,只影响该平台通过 Bot 新建的会话(留空 = 使用 DSH 默认值)。": "These settings are saved per platform and only affect sessions created through that bot (empty = DSH defaults).",
264
- "Agent 预设 — 决定远程会话可用的工具与技能,留空用 DSH 默认预设": "Agent preset — which tools and skills remote sessions may use; empty = DSH default preset",
265
- "留空 = DSH 默认(${name})": "Empty = DSH default (${name})",
266
- "留空 = DSH 默认预设": "Empty = DSH default preset",
267
- "正在读取本机可用预设…": "Reading available presets…",
268
- "本机可用:${list}": "Available: ${list}",
269
- "(无)": "(none)",
270
- "当前 DSH 版本未提供预设列表,请手动填写预设名": "This DSH version exposes no preset list — type the preset name manually",
271
- "工作区目录 — 该平台 /new 新建会话的默认目录,留空用首个已注册工作区": "Workspace directory — default cwd for /new sessions on this platform; empty = first registered workspace",
272
- "绝对路径,例如 /home/me/project 或 D:\\project": "Absolute path, e.g. /home/me/project or D:\\project",
273
- "模型提供方(可选)": "Model provider (optional)",
274
- "留空 = DSH 默认": "Empty = DSH default",
275
- "模型(可选)": "Model (optional)",
276
- "进度摘要间隔(秒)": "Progress digest interval (seconds)",
277
- "审批超时(秒)": "Approval timeout (seconds)",
278
- "单条消息上限(字符)": "Max message size (characters)",
279
- "分块发送间隔(毫秒)": "Chunk send interval (ms)",
280
- "保存高级设置": "Save advanced settings",
281
- "恢复推荐节奏参数": "Restore recommended pacing",
282
- "📱 手机 ${name} 扫码直达对话": "📱 Scan to chat with the bot on ${name}",
283
- "用 ${name} 扫描左侧二维码,立即打开与 Bot 对话;发送首条消息自动完成白名单授权。": "Scan the QR code with ${name} to open the chat; sending the first message authorizes you automatically.",
284
- "在 ${name} 客户端打开 ↗": "Open in ${name} ↗",
285
- "已扫码,请在手机上确认…": "Scanned — confirm on your phone…",
286
- "请使用微信扫码登录(ClawBot)": "Scan with WeChat to sign in (ClawBot)",
287
- "请用飞书扫码创建应用(二维码 10 分钟内有效)": "Scan with Lark / Feishu to create the app (QR valid for 10 minutes)",
288
- "请扫码登录": "Scan to sign in",
289
- "作废当前二维码并重新生成(旧码立即失效)": "Invalidate the current QR code and generate a new one (the old one stops working)",
290
- "生成中…": "Generating…",
291
- "🔄 重新生成二维码": "🔄 Regenerate QR code",
292
- "扫不出来或已过期时可点此换新码": "Tap here for a fresh code if scanning fails or it expired",
293
- "📱 一键创建飞书应用(推荐)": "📱 One-tap Lark / Feishu app creation (recommended)",
294
- "点击后用飞书扫码:自动创建机器人应用并预置所需权限、事件订阅与卡片回调,无需进开发者后台手工配置。": "Click and scan with Lark / Feishu: the bot app is created with the required permissions, event subscriptions and card callbacks preconfigured — no manual developer-console setup.",
295
- "使用飞书扫码创建应用并自动填入凭证": "Create the app by scanning with Lark / Feishu and fill in the credentials automatically",
296
- "处理中…": "Working…",
297
- "扫码一键创建应用": "Scan to create the app",
298
- "已有应用?在下方手动填入 App ID 与 App Secret,或 ": "Already have an app? Enter the App ID and App Secret below, or ",
299
- "前往飞书开放平台": "open the Lark / Feishu Open Platform",
300
- " 创建后填入。": " and paste them here.",
301
- "Bot Token — Telegram @BotFather 下发的机器人 Token": "Bot Token — the token issued by Telegram @BotFather",
302
- "请输入 Telegram Bot Token (如 123456789:ABCdef...)": "Enter the Telegram Bot Token (e.g. 123456789:ABCdef...)",
303
- "隐藏密钥": "Hide secret",
304
- "显示明文": "Show secret",
305
- "🙈 隐藏": "🙈 Hide",
306
- "👁️ 显示": "👁️ Show",
307
- "网络代理 (可选) — 支持国内 HTTP / HTTPS 代理": "Network proxy (optional) — HTTP / HTTPS proxy",
308
- "可选,例如 http://127.0.0.1:7890(为空则直连或读取环境变量)": "Optional, e.g. http://127.0.0.1:7890 (empty = direct or environment variables)",
309
- "AppID — QQ 开放平台机器人应用 ID": "AppID — QQ Open Platform bot app ID",
310
- "App ID — 飞书开放平台自建应用 ID (cli_xxx)": "App ID — Lark / Feishu Open Platform app ID (cli_xxx)",
311
- "请输入 AppID": "Enter the AppID",
312
- "请输入 App ID (如 cli_a1b2c3d4...)": "Enter the App ID (e.g. cli_a1b2c3d4...)",
313
- "AppSecret — QQ 开放平台机器人密钥": "AppSecret — QQ Open Platform bot secret",
314
- "App Secret — 飞书开放平台应用密钥": "App Secret — Lark / Feishu Open Platform app secret",
315
- "请输入 AppSecret(扫码绑定时自动填入)": "Enter the AppSecret (auto-filled after QR binding)",
316
- "请输入 App Secret": "Enter the App Secret",
317
- "📖 QQ 机器人开发文档": "📖 QQ bot developer docs",
318
- "📱 扫码绑定 QQ 机器人(推荐)": "📱 Scan to bind a QQ bot (recommended)",
319
- "扫码绑定机器人": "Scan to bind bot",
320
- "已创建过机器人?": "Already created a bot?",
321
- "在下方手动填入 AppID 与 AppSecret,或 ": "Enter the AppID and AppSecret below, or ",
322
- "前往 QQ 开放平台": "Go to the QQ Open Platform",
323
- "点击后用手机 QQ 扫码:由 QQ 开放平台官方接口直接回传机器人的 AppID 与 AppSecret,无需手工复制粘贴。": "Click and scan with mobile QQ: the official QQ Open Platform API returns the bot AppID and AppSecret directly — no manual copy-paste needed.",
324
- "使用手机 QQ 扫码绑定机器人并自动填入凭证": "Scan with mobile QQ to bind a bot and auto-fill credentials",
325
- "📖 前往飞书开放平台创建企业自建应用": "📖 Create an app on the Lark / Feishu Open Platform",
326
- "保存并连接": "Save and connect",
327
- "连接失败": "Connection failed",
328
- "扫码登录": "Scan to sign in",
329
- "登录失败": "Sign-in failed",
330
- "说明: 扫码成功后,向该微信 Bot 发送第一条消息即自动完成白名单授权。仅白名单内的微信用户能驱动 agent,其他人消息会被忽略。使用专用微信号,避免影响主号。": "Note: after scanning, the first message you send to this WeChat bot authorizes you automatically. Only allowlisted WeChat users can drive the agent; other messages are ignored. Use a dedicated WeChat account to avoid affecting your main one.",
331
- "说明: 推荐用手机 QQ 扫码一键绑定机器人;也可手动填入 AppID 与 AppSecret 后保存即自动连接(底层走腾讯官方 QQ 机器人 SDK)。用户向 Bot 发送第一条消息即自动完成白名单授权。仅白名单内的 QQ 用户能驱动 agent,其他人消息会被忽略。": "Note: scan with mobile QQ to bind a bot in one step, or enter the AppID and AppSecret manually and save to connect (powered by the official Tencent QQ Bot SDK). The first message a user sends to the bot authorizes them. Only allowlisted QQ users can drive the agent; other messages are ignored.",
332
- "请用手机 QQ 扫码绑定机器人(二维码过期会自动刷新)": "Scan with mobile QQ to bind a bot (the QR code refreshes automatically when it expires)",
333
- "说明: 登录成功后,发送第一条消息即自动完成白名单授权。仅白名单内的用户能驱动 agent,其他人消息会被忽略。": "Note: after signing in, the first message you send authorizes you automatically. Only allowlisted users can drive the agent; other messages are ignored.",
334
- "${days}天 ${hrs}小时 ${mins}分": "${days}d ${hrs}h ${mins}m",
335
- "${hrs}小时 ${mins}分": "${hrs}h ${mins}m",
336
- "${mins}分钟": ["${mins} minute","${mins} minutes"],
337
- "📊 宿主系统与运行看板": "📊 Host system & runtime dashboard",
338
- "CPU 核心与型号": "CPU cores & model",
339
- "${cores} 核心 (${model})": ["${cores} core (${model})", "${cores} cores (${model})"],
340
- "DSH 运行时间 (Uptime)": "DSH uptime",
341
- "Node 进程堆内存": "Node process heap",
342
- "系统内存占用: ${used} GB / ${total} GB": "System memory: ${used} GB / ${total} GB",
343
- "诊断请求异常": "Diagnostic request failed",
344
- "🔍 网络连通性一键诊断": "🔍 One-click network diagnostics",
345
- "一键检测本地反向代理端口、局域网 IPv4、Cloudflare Anycast 延迟以及国内 npmmirror 镜像源连通性。": "Checks the local reverse-proxy port, LAN IPv4, Cloudflare Anycast latency and npmmirror connectivity.",
346
- "正在探测连通性…": "Probing connectivity…",
347
- "🔄 重新诊断网络": "🔄 Run diagnostics again",
348
- "🔍 开始一键诊断": "🔍 Run diagnostics",
349
- "✓ 所有网络探测项正常": "✓ All network checks passed",
350
- "▲ 检测到部分延迟较高或异常": "▲ Some checks show high latency or errors",
351
- "正在执行网络端口与云端节点连通性探测…": "Probing local ports and cloud endpoints…",
352
- "✓ 备份文件已成功导出并下载到本地!": "✓ Backup exported and downloaded!",
353
- "导出备份失败": "Export failed",
354
- "导出异常": "Export error",
355
- "✓ 配置已成功导入并刷新生效!": "✓ Configuration imported and applied!",
356
- "导入配置失败": "Import failed",
357
- "导入解析失败: ${reason}": "Failed to parse the import: ${reason}",
358
- "🗄️ 全局配置备份与恢复": "🗄️ Global configuration backup & restore",
359
- "支持一键导出或导入恢复本插件所有配置(包含各 IM 平台凭证、授权白名单、公网隧道与安全认证规则)。": "Export or restore the plugin's full configuration in one click (IM credentials, allowlists, public tunnel and access-protection rules).",
360
- "正在导出…": "Exporting…",
361
- "📥 导出配置备份 (.json)": "📥 Export backup (.json)",
362
- "正在导入…": "Importing…",
363
- "📤 导入配置恢复": "📤 Import configuration",
364
- "• 进行中的会话 ${count} 个:": "• Running sessions: ${count}",
365
- "${count} 次工具调用": ["${count} tool call","${count} tool calls"],
366
- "(最近:${tool})": " (most recent: ${tool})",
367
- "思考中": "Thinking",
368
- " - ${title}(第 ${turn} 轮,${detail})": " - ${title} (turn ${turn}, ${detail})",
369
- " …等共 ${count} 个": " …and ${count} more",
370
- "• 进行中的子代理/agent 任务 ${count} 个:": "• Running subagent tasks: ${count}",
371
- "• 待审批请求 ${count} 个:": "• Pending approvals: ${count}",
372
- "⚠️ 检测到有任务正在运行,重启会中断它们:\n\n${list}\n\n中断后可能需要重新发起。确定要继续重启吗?": "⚠️ Tasks are still running; restarting will interrupt them:\n\n${list}\n\nThey may need to be restarted afterwards. Continue?",
373
- "正在向 DSH 服务发送重启指令…": "Sending the restart command to DSH…",
374
- "DSH 服务正在重启中,正在自动重新连接…": "DSH is restarting — reconnecting automatically…",
375
- "🎉 重启成功!已重新建立连接,正在刷新页面…": "🎉 Restart succeeded — connection restored, refreshing…",
376
- "重连等待超时,请手动刷新页面。": "Reconnect timed out; please refresh the page manually.",
377
- "当前有任务正在运行,重启会中断它们。确定继续吗?": "Tasks are still running; restarting will interrupt them. Continue?",
378
- "未知原因": "Unknown cause",
379
- "🔄 DSH 服务平滑重启": "🔄 Graceful DSH restart",
380
- "优雅退出并重新拉起当前 DSH 进程与所有插件服务,前端将在几秒后自动探测重连并刷新页面。": "Gracefully exits and restarts the DSH process and all plugin services; the front end reconnects automatically within seconds and refreshes the page.",
381
- "🔄 立即重启 DSH 服务": "🔄 Restart DSH now",
382
- "正在调度…": "Scheduling…",
383
- "📱 移动端页面改写层": "📱 Mobile page-rewrite layer",
384
- "控制手机端顶栏、全局移动样式、输入框折叠等页面改写。关闭后仅保留远程访问/隧道/机器人功能,刷新页面生效。": "Controls the mobile top bar, global mobile styling and input collapse. When off, only remote access / tunnel / bot features remain; refresh to apply.",
385
- "当前宿主已全局关闭此层(mobileUi:false),此处不可开启。": "The host has disabled this layer globally (mobileUi:false); it cannot be enabled here.",
386
- "关闭页面改写": "Disable page rewrite",
387
- "开启页面改写": "Enable page rewrite",
388
- "宿主已关闭": "Disabled by host",
389
- "当前:${state}": "Current: ${state}",
390
- "保存失败:${reason}": "Save failed: ${reason}",
391
- "🗂️ 远程工作区管理 (目录浏览器)": "🗂️ Remote workspace management (directory browser)",
392
- "在移动端或远程设备上可视点选电脑上的文件夹或直接输入路径添加至 DSH。": "Pick folders on the computer visually from a phone or remote device, or type a path, and add it to DSH.",
393
- "+ 远程添加工作区": "+ Add remote workspace",
394
- "正在读取工作区列表…": "Reading the workspace list…",
395
- "暂无已注册工作区,点击右上角「+ 远程添加工作区」即可浏览添加。": "No workspaces registered yet — use “+ Add remote workspace” above to browse and add one.",
396
- "正在调度 DSH 服务重启…": "Scheduling the DSH restart…",
397
- "🎉 重启成功!已自动加载最新版本。正在刷新页面…": "🎉 Restart succeeded — the latest version is loaded. Refreshing…",
398
- "已成功升级到 v${version}!": "Upgraded to v${version}!",
399
- "升级失败": "Upgrade failed",
400
- "升级请求失败": "Upgrade request failed",
401
- "DSH 已成功升级到 v${version}!": "DSH upgraded to v${version}!",
402
- "更新日志": "Changelog",
403
- "反馈 Issue": "Report an issue",
404
- "版本检查中…": "Checking versions…",
405
- "· 已是最新": "· Up to date",
406
- "(网络超时)": "(network timeout)",
407
- "发现 DSH 新版本 v${version}": "DSH v${version} is available",
408
- "重新检查 npm 线上版本": "Re-check the npm version",
409
- "检查中…": "Checking…",
410
- "检查更新": "Check for updates",
411
- "发现新版本 v${latest}(当前 v${current})": "v${latest} is available (current v${current})",
412
- "正在自动升级…": "Upgrading automatically…",
413
- "✓ 升级完成": "✓ Upgrade complete",
414
- "一键升级到 v${version}": "Upgrade to v${version}",
415
- "✨ 更新亮点:": "✨ Highlights:",
416
- "已成功升级到 v${version}!需要重启 DSH 服务使新版本生效": "Upgraded to v${version}! Restart the DSH service for it to take effect",
417
- "稍后手动重启": "Restart manually later",
418
- "正在处理…": "Working…",
419
- "▴ 折叠手动命令行": "▴ Hide manual commands",
420
- "▾ 查看手动升级命令 (如需)": "▾ Show manual upgrade commands (if needed)",
421
- "DSH 有新版本 v${latest}(当前 v${current})": "DSH v${latest} is available (current v${current})",
422
- "正在升级 DSH…": "Upgrading DSH…",
423
- "✓ DSH 升级完成": "✓ DSH upgrade complete",
424
- "一键升级 DSH 到 v${version}": "Upgrade DSH to v${version}",
425
- "查看官方升级方式 ↗": "See the official upgrade instructions ↗",
426
- "升级 DSH 命令行工具后需重启 DSH 服务生效。": "Restart the DSH service after upgrading the CLI for it to take effect.",
427
- "当前 DSH 非 npm 全局安装,无法一键自动升级,请按官方渠道手动更新。": "This DSH is not a global npm install, so one-click upgrade is unavailable — update manually through the official channel.",
428
- "局域网": "LAN",
429
- "公网隧道": "Public tunnel",
430
- "IM 机器人": "IM bots",
431
- "安全认证": "Security",
432
- "运维监控": "Operations",
433
- "访问会话已失效,请刷新页面重新登录": "Your access session expired; refresh the page and sign in again",
434
- "listPlatforms 查询失败": "Failed to load the platform list",
435
- "局域网访问": "LAN access",
436
- "同一 Wi-Fi 下的设备可直接扫码访问": "Devices on the same Wi-Fi can scan and connect directly",
437
- "固定域名模式": "Fixed-domain mode",
438
- "免登录临时域名": "Temporary domain (no login)",
439
- "自建隧道": "Self-hosted tunnel",
440
- "VPS 自建 · 固定地址": "Self-hosted on a VPS · fixed address",
441
- "Cloudflare 隧道": "Cloudflare tunnel",
442
- "自行部署登记": "Register an existing deployment",
443
- "另有 ${count} 个隧道入口在运行,可在下方「隧道配置」中查看与管理": ["${count} more tunnel entry is running — see “Tunnel configuration” below","${count} more tunnel entries are running — see “Tunnel configuration” below"],
444
- "固定域名模式(Token 运行 · 重启 URL 保持不变)": "Fixed-domain mode (Token-based · URL survives restarts)",
445
- "一键获取公网地址(免登录临时随机域名)": "Get a public URL in one click (random temporary domain, no login)",
446
- "连接自己部署的隧道服务器,获得固定域名": "Connect to your own tunnel server for a fixed domain",
447
- "飞书": "Lark / Feishu",
448
- "扫码一键创建 · 斜杠指令 · 文档评论": "One-tap QR setup · slash commands · doc comments",
449
- "微信": "WeChat",
450
- "ClawBot 扫码直连 · 无需公网": "ClawBot QR direct connect · no public server needed",
451
- "扫码一键绑定 · 官方 SDK · 私聊/群聊/按钮": "One-tap QR binding · official SDK · DMs, groups and buttons",
452
- "官方 Bot API": "Official Bot API",
453
- "平台清单加载失败:${reason}": "Failed to load the platform list: ${reason}",
454
- "重试": "Retry",
455
- "数据缺失": "Missing data",
456
- // 同平台多账号(issue #78)
457
- "未添加账号": "No accounts",
458
- "${count} 个账号": ["${count} account","${count} accounts"],
459
- "账号列表(${count} 个)": "Accounts (${count})",
460
- "账号 ${index}/${total}": "Account ${index}/${total}",
461
- "+ 添加账号": "+ Add account",
462
- "添加中…": "Adding…",
463
- "添加账号失败": "Failed to add the account",
464
- "添加一个新账号(同一平台可接入多个账号)": "Add another account (a platform can host multiple accounts)",
465
- "还没有添加「${name}」账号": "No ${name} account added yet",
466
- "添加账号后可填写该账号的凭证并独立连接;同一平台支持同时接入多个账号,凭证、白名单与会话归属互不影响。": "After adding an account, fill in its credentials to connect it independently. A platform can host multiple accounts with separate credentials, allowlists and session bindings.",
467
- "每个平台最多 ${limit} 个账号": "Up to ${limit} accounts per platform",
468
- "已达单平台账号上限(最多 ${limit} 个)": "Account limit reached for this platform (max ${limit})",
469
- "备注名(可选,用于区分同平台多个账号)": "Note name (optional, tells same-platform accounts apart)",
470
- "移除账号": "Remove account",
471
- "移除账号失败": "Failed to remove the account",
472
- "停止该账号并删除其配置与会话归属(不会删除 DSH 会话本身)": "Stop this account and delete its configuration and session binding (the DSH session itself is not deleted)",
473
- "确认移除账号「${name}」?将停止该账号并删除其配置与会话归属;DSH 会话本身不会被删除。": "Remove the account “${name}”? This stops it and deletes its configuration and session binding; the DSH session itself is not deleted.",
474
- "未配置凭证 — 请先完成下方配置。": "No credentials configured — complete the setup below first.",
475
- "访问密码": "access password",
476
- "请输入后台管理密码解锁管理权限。": "Enter the admin password to unlock management.",
477
- "当前未设置独立管理密码,输入您的访问密码即可解锁。": "No dedicated admin password is set; enter your access password to unlock.",
478
- "管理控制台已锁定(仅限电脑本机管理)": "Admin console locked (this computer only)",
479
- "当前设备通过远程局域网或公网接入。已开启「仅限电脑本机管理」最高安全策略,远程设备禁止查看与修改任何网络与机器人配置。如需管理请在电脑本机(127.0.0.1)上操作。": "This device is connected over the LAN or the public internet. The strictest policy “This computer only” is on: remote devices may not view or change any network or bot settings. Manage from the computer itself (127.0.0.1).",
480
- "❓ 远程如何救急解除锁定?": "❓ How do I unlock in an emergency?",
481
- "🛟 救急解除锁定指引:": "🛟 Emergency unlock guide:",
482
- "电脑本机直连修改": "On the computer itself",
483
- ":直接在运行本程序的电脑本机打开本控制台(127.0.0.1 享有物理免锁特权),可随时修改策略或清除密码。": ": open this console on the machine running DSH (127.0.0.1 is exempt from locking) to change the policy or clear the password at any time.",
484
- "服务器 / 无头环境": "Server / headless environment",
485
- ":救急重置步骤参见 GitHub README 的「三重容灾保命体系」章节。": ": see the emergency-reset steps in the “Triple Disaster Recovery (Never Locked Out)” section of the English README.",
486
- "管理控制台已锁定": "Admin console locked",
487
- "🔑 使用管理密码解锁": "🔑 Unlock with the admin password",
488
- "🔐 使用访问密码解锁": "🔐 Unlock with the access password",
489
- "当前设备为远程访问。为保护您的网络与平台配置安全,${hint}": "This is a remote device. To protect your network and platform configuration, ${hint}",
490
- "输入${kind}": "Enter the ${kind}",
491
- "验证中…": "Verifying…",
492
- "解锁管理权限": "Unlock management",
493
- "❓ 忘记${kind}?": "❓ Forgot the ${kind}?",
494
- "🛟 找回与重置${kind}指引:": "🛟 Recover or reset your ${kind}:",
495
- ":直接在运行本程序的电脑本机打开本控制台(127.0.0.1 享有物理免锁特权),可随时修改或清除密码。": ": open this console on the machine running DSH (127.0.0.1 is exempt from locking) to change or clear the password at any time.",
496
- "🔑 立即输入${kind}解锁": "🔑 Enter the ${kind} to unlock",
497
- "🔓 管理员权限已解锁(当前临时会话有效)": "🔓 Admin access unlocked (valid for this temporary session)",
498
- "🔒 重新锁定后台": "🔒 Lock the console again",
499
- "🔒 后台管理权限未解锁(修改敏感配置需先解锁)": "🔒 Admin access is locked (unlock before changing sensitive settings)",
500
- "⚠️ 尚未设置任何访问密码 / 管理密码,远程访客可免密进入!": "⚠️ No access or admin password is set — remote visitors can enter without one!",
501
- "🔑 解锁管理权限": "🔑 Unlock management",
502
- "🔐 立即设置密码": "🔐 Set a password now",
503
- "🔒 解锁后台管理权限": "🔒 Unlock admin access",
504
- "当前操作需要后台管理员权限。为保护您的网络配置与机器人平台安全,请输入管理密码解锁:": "This action requires admin access. To protect your network configuration and bot platforms, enter the admin password to unlock:",
505
- "当前操作需要后台管理权限。未设置独立管理密码,输入您的访问密码即可解锁:": "This action requires admin access. No dedicated admin password is set; enter your access password to unlock:",
506
- "取消": "Cancel",
507
- "立即解锁": "Unlock now",
508
- "💡 提示:若未单独配置管理密码,请输入初次设置的访问密码;电脑本机(127.0.0.1)访问享有免密管理特权。": "💡 Tip: if no dedicated admin password is set, enter the access password you configured first; access from 127.0.0.1 on this computer needs no unlock.",
509
- "选择电脑工作区": "Choose a workspace on your computer",
510
- "点击进入文件夹,或点击「+ 选为工作区」直接添加并切换": "Open a folder, or tap “+ Use as workspace” to add and switch directly",
511
- "🔒 此操作需要管理员权限": "🔒 Admin access required",
512
- "远程访问时浏览/添加工作区需输入后台管理密码解锁(与访问密码不同)。": "Browsing or adding workspaces remotely requires the admin password (different from the access password).",
513
- "请输入后台管理密码": "Enter the admin password",
514
- "解锁中…": "Unlocking…",
515
- "解锁": "Unlock",
516
- "返回上一级": "Go up one level",
517
- "⬆️ 上级": "⬆️ Up",
518
- "刷新目录": "Refresh directory",
519
- "当前目录:": "Current directory:",
520
- "正在添加并切换…": "Adding and switching…",
521
- "👉 设为当前工作区并进入": "👉 Use as workspace and enter",
522
- "过滤子文件夹…": "Filter subfolders…",
523
- "${count} 个文件夹": ["${count} folder","${count} folders"],
524
- "正在读取目录内容…": "Reading directory…",
525
- "未找到匹配的子文件夹": "No matching subfolders",
526
- "当前文件夹下没有更多子文件夹": "No more subfolders here",
527
- "(直接点击上方蓝色按钮即可进入当前目录)": "(tap the blue button above to enter the current directory)",
528
- "直接添加此子文件夹为工作区并进入": "Add this subfolder as a workspace and enter",
529
- "+ 选为工作区": "+ Use as workspace",
530
- "▼ 收起绝对路径手动输入": "▼ Hide manual path input",
531
- "▶ 手动粘贴/输入绝对路径": "▶ Paste / type an absolute path",
532
- "输入电脑绝对路径,例如 C:\\Projects\\my-app": "Enter an absolute path on your computer, e.g. C:\\Projects\\my-app",
533
- "前往": "Go",
534
- "添加并进入": "Add and enter",
535
- "已注册工作区 (${count} 个,点击直接切换):": "Registered workspaces (${count}, tap to switch):",
536
- "进入 ➔": "Enter ➔",
537
- "💡 点击文件夹可逐级进入": "💡 Tap folders to drill down",
538
- "解锁失败": "Unlock failed",
539
- "正在切换工作区…": "Switching workspace…",
540
- "✓ 已切换至工作区!": "✓ Switched to the workspace!",
541
- "读取目录失败": "Failed to read the directory",
542
- "当前策略仅限电脑本机管理,远程无法解锁": "The current policy is “this computer only”; remote unlock is unavailable",
543
- "请输入或选择工作区路径": "Enter or choose a workspace path",
544
- "✓ 工作区「${name}」已选定,正在切换…": "✓ Workspace “${name}” selected, switching…",
545
- "添加工作区失败": "Failed to add the workspace",
546
- "添加工作区异常": "Workspace add error",
547
- "远程访问": "Remote access",
548
- "管理员密码错误": "Incorrect admin password",
549
- "解锁请求失败": "Unlock request failed",
550
-
551
- "IPv4(4)": "IPv4 (4)",
552
- "IPv6(6)": "IPv6 (6)",
553
- "${label}:${reason}": "${label}: ${reason}",
554
- "cloudflared:${path}(${version} · ${source})": "cloudflared: ${path} (${version} · ${source})",
555
- "⚡ 自动推荐 (${ip} · ${label})": "⚡ Auto (recommended: ${ip} · ${label})",
556
- "开启公网隧道前,请先在「安全认证」中设置访问密码": "Before enabling the public tunnel, set an access password under “Security”",
557
- "去设置 ➔": "Set up ➔",
558
- "本机访问未能自动获取管理令牌(可能是桌面窗口/自定义协议的跨源限制)。请改用电脑浏览器打开 ${url} 进行管理类操作。": "This local page could not obtain the admin token automatically (possibly a cross-origin restriction of the desktop window or a custom protocol). Open ${url} in your computer's browser to perform admin operations.",
559
- "打开控制台 ↗": "Open console ↗",
560
- "知道了": "Got it",
561
- // SaaS 隧道(设备码绑定)面板
562
- "SaaS 账号": "SaaS account",
563
- "隧道模式": "Tunnel mode",
564
- "自建隧道 / SaaS 账号": "Self-hosted / SaaS account",
565
- "SaaS 模式:在控制台输入设备码完成绑定,插件自动维护网关连接与公网地址。": "SaaS mode: enter the device code in the console to bind this device; the plugin maintains the gateway connection and public URL automatically.",
566
- "自建模式:连接你自己部署的隧道服务器,配置与行为保持不变。": "Self-hosted mode: connect to the tunnel server you deployed yourself; configuration and behavior stay unchanged.",
567
- "操作失败": "Operation failed",
568
- "网关地址已保存": "Gateway URL saved",
569
- "请先填写 SaaS 网关地址": "Enter the SaaS gateway URL first",
570
- "设备码已生成,请在控制台输入设备码完成绑定": "Device code generated — enter it in the console to finish binding",
571
- "绑定请求已提交": "Binding request submitted",
572
- "设备已解绑": "Device unbound",
573
- "SaaS 隧道": "SaaS tunnel",
574
- "设备码绑定 · 免运维公网地址": "Device-code binding · managed public URL",
575
- "已绑定": "Bound",
576
- "未绑定": "Not bound",
577
- "设备 ID:${id}": "Device ID: ${id}",
578
- "设备密钥:${secret}": "Device secret: ${secret}",
579
- "最近错误:${detail}": "Last error: ${detail}",
580
- "设备码": "Device code",
581
- "已复制": "Copied",
582
- "打开控制台": "Open console",
583
- "设备码有效期至 ${time}": "Device code expires at ${time}",
584
- "等待控制台确认…": "Waiting for console confirmation…",
585
- "在控制台「添加设备」中输入上面的设备码并确认后,这里会自动完成绑定。": "Enter the code above under “Add device” in the console; binding completes here automatically after you confirm.",
586
- "SaaS 网关地址": "SaaS gateway URL",
587
- "保存网关地址": "Save gateway URL",
588
- "填写 SaaS 控制台(apps/web)基址;仅允许 http(s)/ws(s)。": "Base URL of the SaaS console (apps/web); only http(s)/ws(s) is accepted.",
589
- "设备码(可选:输入控制台显示的设备码继续绑定)": "Device code (optional: enter the console code to resume binding)",
590
- "例如 ABCD-1234": "e.g. ABCD-1234",
591
- "绑定中…": "Binding…",
592
- "绑定": "Bind",
593
- "获取设备码": "Get device code",
594
- "公网地址": "Public URL",
595
- "等待网关分配公网地址…": "Waiting for the gateway to assign a public URL…",
596
- "设备已绑定,可开启 SaaS 隧道": "Device bound — you can start the SaaS tunnel",
597
- "开启 SaaS 隧道": "Start SaaS tunnel",
598
- "断开中…": "Disconnecting…",
599
- "关闭隧道": "Stop tunnel",
600
- "解绑中…": "Unbinding…",
601
- "确认解绑": "Confirm unbind",
602
- "解绑": "Unbind",
603
- };
604
-
605
- // 服务端(RPC / 隧道管理器 / 网络诊断)产生的运行时文案:面板以子节点原样渲染,
606
- // 渲染层同样过 localeT()。这些字符串不在 client 源码里,故由 test 的「死词条」检查排除;
607
- // 词条按**精确匹配**生效,服务端改了文案只会退化成原文(不会误翻),无需同步发布。
608
- // 同时为少数带变量、无法精确匹配的文案提供正则模式($1.. 为捕获组)。
609
- /** @type {Record<string, string>} */
610
- export const serverEn = {
611
- "App ID 与 App Secret 未配置": "App ID and App Secret are not configured",
612
- "请填写完整的 App ID 和 App Secret,或使用扫码一键创建应用": "Enter a complete App ID and App Secret, or use one-tap QR app creation",
613
- "Telegram Bot Token 未配置": "Telegram Bot Token is not configured",
614
- "请填写完整的 Telegram Bot Token": "Enter a complete Telegram Bot Token",
615
- "请填写 QQ 机器人 AppID 与 AppSecret,或使用扫码一键绑定": "Enter the QQ bot AppID and AppSecret, or use scan-to-bind",
616
- "二维码已过期,正在刷新…": "QR code expired, refreshing…",
617
- "操作已被拦截:当前策略为仅限电脑本机管理": "Blocked: the current policy allows this computer only",
618
- "该操作涉及敏感配置:请先在「安全认证」中设置访问密码或管理密码后再执行": "This action touches sensitive configuration: set an access or admin password under “Security” first",
619
- "操作已被拦截:需要管理员权限,请先在控制台输入管理密码解锁": "Blocked: admin access required — enter the admin password to unlock first",
620
- "AuthManager 未初始化": "AuthManager is not initialized",
621
- "仅密码模式需要先设置访问密码:请先在下方「设置外部访客访问密码」处设置密码,再开启安全防护": "Password-only mode needs an access password: set one under “External visitor access password” below, then enable protection",
622
- "仅密码模式需要先设置访问密码:请先在下方「设置外部访客访问密码」处设置密码后再切换": "Password-only mode needs an access password: set one under “External visitor access password” below, then switch modes",
623
- "UI 配置持久化不可用": "UI configuration persistence is unavailable",
624
- "pageTweaks 必须为布尔值": "pageTweaks must be a boolean",
625
- "当前有任务正在运行,重启会打断它们": "Tasks are still running; restarting will interrupt them",
626
- "备份导出服务不可用": "Backup export service is unavailable",
627
- "备份导入服务不可用": "Backup import service is unavailable",
628
- "PlatformManager 未初始化,IM 平台清单不可用": "PlatformManager is not initialized; the IM platform list is unavailable",
629
- "PlatformManager 未初始化": "PlatformManager is not initialized",
630
- "缺少 platformId 参数": "Missing platformId parameter",
631
- // 同平台多账号(issue #78):服务端 add/remove 账号错误
632
- "单个平台最多添加 10 个账号": "Up to 10 accounts per platform",
633
- "缺少 instanceId 参数": "Missing instanceId parameter",
634
- "缺少 instanceId/platformId 参数": "Missing instanceId/platformId parameter",
635
- "多账号能力未接线": "Multi-account capability is not wired up",
636
- "隧道服务地址必须是 ws:// 或 wss://(也接受 http/https)": "The tunnel server URL must be ws:// or wss:// (http/https is also accepted)",
637
- "请输入合法的公网隧道地址(https://...)": "Enter a valid public tunnel URL (https://...)",
638
- "自建隧道已在运行": "The self-hosted tunnel is already running",
639
- "缺少配置:请在控制台配置 customTunnel.serverUrl 和 customTunnel.accessToken": "Missing configuration: set customTunnel.serverUrl and customTunnel.accessToken in the console",
640
- "Cloudflare 隧道已在运行": "The Cloudflare tunnel is already running",
641
- "正在初始化...": "Initializing…",
642
- "正在自动重连...": "Reconnecting automatically…",
643
- "正在连接 Cloudflare...": "Connecting to Cloudflare…",
644
- "正在下载 cloudflared (~30MB)...": "Downloading cloudflared (~30 MB)…",
645
- "临时隧道已建立": "Temporary tunnel established",
646
- "固定隧道已建立": "Fixed tunnel established",
647
- "隧道已注册,等待就绪...": "Tunnel registered, waiting to become ready…",
648
- "隧道已建立": "Tunnel established",
649
- "隧道未运行或尚未就绪": "The tunnel is not running or not ready yet",
650
- "已取消": "Cancelled",
651
- "客户端在线运行中 (WebSocket 通道已建立)": "Client online (WebSocket channel established)",
652
- "客户端在线运行中": "Client online",
653
- "待连接/就绪": "Waiting to connect / ready",
654
- "未配置自建服务器(若已部署自建隧道可在「公网隧道」中配置)": "No self-hosted server configured (configure it under “Public tunnel” if it is already deployed)",
655
- "无效的备份数据结构:缺少 config 节点": "Invalid backup data: the config node is missing",
656
- "下载超时(5分钟)": "Download timed out (5 minutes)",
657
- "重定向次数过多": "Too many redirects",
658
- "未知错误": "Unknown error",
659
- "未知": "Unknown",
660
- "停止 cloudflared...": "Stopping cloudflared…",
661
-
662
- "局域网 IP 分配与可用性": "LAN IP allocation & availability",
663
- "Cloudflare Anycast 边缘网络": "Cloudflare Anycast edge network",
664
- "国内 npm 高速镜像源 (npmmirror)": "npmmirror (fast npm mirror)",
665
- "自建隧道部署服务器": "Self-hosted tunnel server",
666
- "代理未启动": "Proxy is not running",
667
- "未检测到活跃局域网 IPv4 地址 (可能未连接 Wi-Fi/以太网)": "No active LAN IPv4 address detected (Wi-Fi/Ethernet may be disconnected)",
668
- "安全拦截:禁止访问 UNC 网络共享路径": "Blocked: UNC network share paths are not allowed",
669
- "扫码创建应用未返回完整凭据": "Scan-to-create did not return complete credentials",
670
- "飞书通道未启动:请先配置应用凭证并连接": "Lark / Feishu channel is not running: configure the app credentials and connect first",
671
- "缺少文件路径": "Missing file path",
672
- "评论会话不支持发送文件": "Sending files is not supported in comment sessions",
673
- "当前运行在 DSH 桌面版内,宿主由应用统一管理,插件不能自行重启。请用桌面应用菜单的重启/退出重进(有关闭确认保护正在跑的任务),不要用面板重启。": "DSH Desktop manages the host itself, so the plugin cannot restart it. Use the desktop app menu to restart or quit and reopen (it asks for confirmation when tasks are running) instead of the panel restart.",
674
- "桌面版 DSH 由应用内更新统一管理(一键升级仅支持 npm 全局安装的 CLI 版);请用桌面应用菜单的\"检查更新\"升级,勿用 npm 改动应用包内文件": "DSH Desktop updates itself from within the app (one-click upgrade only supports the globally npm-installed CLI); use “Check for updates” in the desktop app menu and do not modify files inside the app package with npm",
675
- "dsh 非标准 npm 全局安装(Electron/打包/源码/pnpm 等),无法自动升级;请按官方渠道手动更新": "dsh is not a standard global npm install (Electron/packaged/source/pnpm, etc.), so automatic upgrade is unavailable — update manually via the official channel",
676
- "缺少工作区目录路径": "Missing workspace directory path",
677
- "路径安全校验未通过": "Path failed the security check",
678
- "登录启动失败": "Failed to start sign-in",
679
- "升级命令执行失败": "Upgrade command failed",
680
- "未找到 dsh 命令(可能通过源码/打包方式运行,非 npm 全局安装)": "dsh command not found (it may be installed from source or packaged rather than as a global npm package)",
681
- "当前 DSH 为非 npm 全局安装,无法自动升级;请按官方渠道手动更新": "This DSH is not a global npm install, so automatic upgrade is unavailable — update manually via the official channel",
682
- "隧道未运行": "Tunnel is not running",
683
- "未命名会话": "Untitled session",
684
- "待审批请求": "Pending approval",
685
- "🏠 用户主目录": "🏠 Home",
686
- "💻 桌面": "💻 Desktop",
687
- "📁 文档": "📁 Documents",
688
- "📥 下载": "📥 Downloads",
689
- "根目录 /": "Root /",
690
- "C: 盘": "C: drive",
691
- "尝试次数过多,请 60 秒后再试": "Too many attempts, please try again in 60 seconds",
692
- "尝试次数过多,请稍后再试": "Too many attempts, please try again later",
693
- "当前已配置为仅限电脑本机管理设置": "Management is currently restricted to this computer",
694
- "请检查 Token 与参数": "check the Token and parameters",
695
- "已配置 Token": "Token configured",
696
- "登录失败或超时": "Sign-in failed or timed out",
697
- "探测 dsh 安装形态失败,请按官方渠道手动更新": "Failed to detect how dsh is installed; update manually via the official channel",
698
- "systemctl 执行超时(5s)": "systemctl timed out (5s)",
699
- "你已拒绝授权,可重新发起扫码创建": "You declined the authorization; you can start the QR sign-in again",
700
- "二维码已过期,请重新发起扫码创建": "The QR code expired; start the QR sign-in again",
701
- // SaaS v2 控制通道运行态(SaasTunnelClient 状态详情)
702
- "正在连接 SaaS 网关…": "Connecting to the SaaS gateway…",
703
- "SaaS 隧道已建立": "SaaS tunnel established",
704
- "SaaS 网关握手超时(15s 内未收到 hello-ack)": "SaaS gateway handshake timed out (no hello-ack within 15s)",
705
- "SaaS 网关正在下线,等待在途请求结束后断开": "The SaaS gateway is draining; disconnecting after in-flight requests finish",
706
- "SaaS 网关已下线(drain),隧道已优雅断开": "The SaaS gateway went offline (drain); the tunnel closed gracefully",
707
- "连接已取消": "Connection cancelled",
708
- };
709
-
710
- /** @type {[RegExp, string][]} 服务端动态文案的英文模式(按顺序首个命中生效) */
711
- export const serverPatterns = [
712
- [/^(.+)((access_denied|expired_token))$/, "$1t ($2)"],
713
- // 同平台多账号(issue #78):账号展示名 / 查重 / 类型 / 移除错误($1t 会再走一遍词典,
714
- // 让「飞书 2」这类 displayName 整体英文化)
715
- [/^(飞书|微信|QQ|Telegram) (\d+)$/, "$1t $2"],
716
- [/^同一应用不能重复添加:该凭证已被「(.*)」使用$/, "This app cannot be added twice: its credentials are already used by “$1t”"],
717
- [/^不支持的平台类型: \(空\)$/, "Unsupported platform type: (empty)"],
718
- [/^不支持的平台类型: (.*)$/, "Unsupported platform type: $1"],
719
- [/^账号不存在: (.*)$/, "Account not found: $1"],
720
- [/^systemctl 退出码 (.*)$/, "systemctl exit code $1"],
721
- [/^cloudflared 进程意外退出 \(code=(.*?)(, .*)?\)$/, "cloudflared exited unexpectedly (code=$1$2)"],
722
- [/^cloudflared 退出,code=(.*) signal=(.*)$/, "cloudflared exited (code=$1, signal=$2)"],
723
- [/^配置错误((.*))$/, "Configuration error ($1t)"],
724
- [/^(.*)(已自动重试 (\d+) 次仍失败,请检查网络\/Token,或点击「关闭」停止)$/, "$1t (retried $2 times without success — check your network/Token, or click “Close” to stop)"],
725
- [/^(.*),(.*) 后自动重连(第 (\d+)\/(\d+) 次)$/, "$1t, reconnecting automatically after $2 (attempt $3/$4)"],
726
- [/^(.*),(.*) 后继续自动重连(已重试 (\d+) 次;隧道长时间无法建立,请检查网络与 Token)$/, "$1t, continuing to reconnect automatically after $2 (retried $3 times; the tunnel has been down for a while — check your network and Token)"],
727
- [/^(.*);⚠️ 运行时健康探活未启用(未识别到 cloudflared metrics 地址),连接器若静默假死将无法自动发现$/, "$1t; ⚠️ runtime health probing is disabled (no cloudflared metrics address found) — a silently hung connector will not be detected automatically"],
728
- [/^健康探活连续 (\d+) 次失败:连接器已无健康边缘连接,正在观察能否自行恢复((\d+)\/(\d+))$/, "Health probe failed $1 times in a row: the connector has no healthy edge connection — watching whether it recovers ($2/$3)"],
729
- [/^健康探活连续 (\d+) 次失败:连接器已无健康边缘连接,正在自动重连…$/, "Health probe failed $1 times in a row: the connector has no healthy edge connection — reconnecting…"],
730
- [/^固定隧道已建立 \((.*)\)$/, "Fixed tunnel established ($1)"],
731
- [/^临时隧道已建立 \((.*)\)$/, "Temporary tunnel established ($1)"],
732
- [/^服务器连通良好 \(延迟 (\d+)ms · 状态: (.*)\)$/, "Server reachable (latency $1 ms · status: $2t)"],
733
- [/^连接畅通 \(延迟 (\d+)ms\)$/, "Connection OK (latency $1 ms)"],
734
- [/^连接异常: (.*) \(临时公网隧道可能受阻\)$/, "Connection error: $1t (the temporary public tunnel may be blocked)"],
735
- [/^连接超时或异常: (.*)$/, "Connection timed out or failed: $1t"],
736
- [/^连接超时 \((\d+(?:\.\d+)?)s\)$/, "Connection timed out ($1s)"],
737
- [/^无法连通自建服务器: (.*)$/, "Cannot reach the self-hosted server: $1t"],
738
- [/^本地反向代理端口 \((\d+)\)$/, "Local reverse-proxy port ($1)"],
739
- [/^正常运行中 \(代理目标端口: (\d+)\)$/, "Running (proxy target port: $1)"],
740
- [/^检测到有效局域网 IPv4: (.*)$/, "Valid LAN IPv4 detected: $1"],
741
- [/^自建隧道部署服务器 \((.*)\)$/, "Self-hosted tunnel server ($1)"],
742
- [/^指定路径不是文件夹: (.*)$/, "Not a folder: $1"],
743
- [/^无法访问指定路径 \((.*)\)$/, "Cannot access the path ($1t)"],
744
- [/^读取文件夹失败: (.*)$/, "Failed to read the folder: $1t"],
745
- [/^安全拦截:禁止访问系统敏感目录 \((.*)\)$/, "Blocked: access to a sensitive system directory is not allowed ($1)"],
746
- [/^安全拦截:禁止访问系统关键目录 \((.*)\)$/, "Blocked: access to a critical system directory is not allowed ($1)"],
747
- [/^安全拦截:禁止访问敏感配置目录「(.*)」$/, "Blocked: access to a sensitive configuration directory “$1” is not allowed"],
748
- [/^安全拦截:符号链接指向系统敏感目录 \((.*)\)$/, "Blocked: symlink points to a sensitive system directory ($1)"],
749
- [/^安全拦截:符号链接指向系统关键目录 \((.*)\)$/, "Blocked: symlink points to a critical system directory ($1)"],
750
- [/^安全拦截:符号链接指向敏感配置目录「(.*)」$/, "Blocked: symlink points to a sensitive configuration directory “$1”"],
751
- [/^非法的版本号格式: (.*)$/, "Invalid version format: $1"],
752
- [/^重启失败:(.*)$/, "Restart failed: $1t"],
753
- [/^systemctl (.*) 失败:(.*)。DSH 仍在运行;请手动执行「(.*)」或检查单元。$/, "systemctl $1 failed: $2t. DSH is still running; run “$3” manually or check the unit."],
754
- [/^npm 安装成功但 dsh 命令实际版本仍为 (.*)(预期 (.*))。可能安装到了错误位置,请手动执行 `(.*)` 并重启 DSH。$/, "npm install succeeded but the dsh command still reports $1 (expected $2). It may have installed to the wrong location — run `$3` manually and restart DSH."],
755
- [/^请求过于频繁,请等待 (\d+) 秒后再试$/, "Too many requests; retry in $1 s"],
756
- [/^添加工作区请求过于频繁,请等待 (\d+) 秒后再试$/, "Too many workspace requests; retry in $1 s"],
757
- [/^平台未注册: (.*)$/, "Platform not registered: $1"],
758
- [/^不支持的平台: (.*)$/, "Unsupported platform: $1"],
759
- [/^下载 cloudflared: (.*)$/, "Downloading cloudflared: $1"],
760
- [/^数据面探测超时 (.*)$/, "Data plane probe timed out $1"],
761
- [/^公网地址格式非法: (.*)$/, "Invalid public URL: $1"],
762
- [/^([A-Za-z]): 盘$/, "$1: drive"],
763
- [/^(.*) \(Wi-Fi 无线网卡\)$/, "$1t (Wi-Fi adapter)"],
764
- [/^(.*) \(有线网卡\)$/, "$1t (wired adapter)"],
765
- [/^(.*) \(虚拟网卡 \/ WSL \/ 虚拟机\)$/, "$1t (virtual adapter / WSL / VM)"],
766
- [/^cloudflared 启动失败: (.*)$/, "cloudflared failed to start: $1t"],
767
- [/^cloudflared 自动重连失败: (.*)$/, "cloudflared automatic reconnect failed: $1t"],
768
- // SaaS v2 控制通道动态状态($1t 递归翻译捕获组里的内层文案)
769
- [/^SaaS 隧道已建立 \((.*)\)$/, "SaaS tunnel established ($1)"],
770
- [/^SaaS 网关心跳连续 (\d+) 次未确认,主动重连$/, "SaaS gateway missed $1 heartbeat acks; reconnecting proactively"],
771
- [/^SaaS 隧道断开(?::(.*))?,(\d+(?:\.\d+)?)s 后重连(第 (\d+) 次)$/, "SaaS tunnel disconnected$1t; reconnecting in $2s (attempt $3)"],
772
- [/^SaaS 网关关闭连接 \((\d+)(?:: (.*))?\),请重新绑定设备$/, "SaaS gateway closed the connection ($1$2t); rebind the device"],
773
- [/^SaaS 网关连接已断开 \(code=(\d+)\)$/, "SaaS gateway connection dropped (code=$1)"],
774
- [/^SaaS 网关拒绝握手: (.*) \((.*)\)$/, "SaaS gateway rejected the handshake: $1t ($2)"],
775
- [/^SaaS 网关在握手完成前断开 \(code=(\d+)\)$/, "SaaS gateway disconnected before the handshake completed (code=$1)"],
776
- [/^SaaS 隧道重连已达上限 \((\d+) 次\)$/, "SaaS tunnel reconnect limit reached ($1 attempts)"],
777
- ];