@jingyi0605/codingns4dsh 0.1.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 (312) hide show
  1. package/README.md +1114 -0
  2. package/assets/provider-icons/claude-code.png +0 -0
  3. package/assets/provider-icons/codex.png +0 -0
  4. package/assets/provider-icons/command-code.svg +5 -0
  5. package/assets/provider-icons/deepseek-harness.svg +9 -0
  6. package/assets/provider-icons/gemini.png +0 -0
  7. package/assets/provider-icons/grok.png +0 -0
  8. package/assets/provider-icons/kimi.png +0 -0
  9. package/assets/provider-icons/opencode.png +0 -0
  10. package/assets/provider-icons/pi.svg +7 -0
  11. package/data/build/dist/bootstrap/dsh-connection-adapter.d.ts +97 -0
  12. package/data/build/dist/bootstrap/dsh-connection-adapter.js +169 -0
  13. package/data/build/dist/bootstrap/index.d.ts +38 -0
  14. package/data/build/dist/bootstrap/index.js +44 -0
  15. package/data/build/dist/client/account-bar.d.ts +9 -0
  16. package/data/build/dist/client/account-bar.js +398 -0
  17. package/data/build/dist/client/bundle.js +26167 -0
  18. package/data/build/dist/client/cli-catalog.d.ts +24 -0
  19. package/data/build/dist/client/cli-catalog.js +108 -0
  20. package/data/build/dist/client/cli-slots.d.ts +38 -0
  21. package/data/build/dist/client/cli-slots.js +297 -0
  22. package/data/build/dist/client/debug/ui.d.ts +12 -0
  23. package/data/build/dist/client/debug/ui.js +451 -0
  24. package/data/build/dist/client/dsh-h5-bootstrap.d.ts +64 -0
  25. package/data/build/dist/client/dsh-h5-bootstrap.js +293 -0
  26. package/data/build/dist/client/dsh-runtime-version.d.ts +3 -0
  27. package/data/build/dist/client/dsh-runtime-version.js +11 -0
  28. package/data/build/dist/client/external-tool-stream.d.ts +24 -0
  29. package/data/build/dist/client/external-tool-stream.js +114 -0
  30. package/data/build/dist/client/features/cli-adapters.d.ts +7 -0
  31. package/data/build/dist/client/features/cli-adapters.js +215 -0
  32. package/data/build/dist/client/features/debug.d.ts +4 -0
  33. package/data/build/dist/client/features/debug.js +24 -0
  34. package/data/build/dist/client/features/index.d.ts +33 -0
  35. package/data/build/dist/client/features/index.js +44 -0
  36. package/data/build/dist/client/features/lan-access-panel.d.ts +5 -0
  37. package/data/build/dist/client/features/lan-access-panel.js +146 -0
  38. package/data/build/dist/client/features/lan-access.d.ts +9 -0
  39. package/data/build/dist/client/features/lan-access.js +30 -0
  40. package/data/build/dist/client/features/login-protection-panel.d.ts +5 -0
  41. package/data/build/dist/client/features/login-protection-panel.js +91 -0
  42. package/data/build/dist/client/features/login-protection-session.d.ts +6 -0
  43. package/data/build/dist/client/features/login-protection-session.js +25 -0
  44. package/data/build/dist/client/features/login-protection.d.ts +4 -0
  45. package/data/build/dist/client/features/login-protection.js +23 -0
  46. package/data/build/dist/client/features/reverse-proxy-panel.d.ts +9 -0
  47. package/data/build/dist/client/features/reverse-proxy-panel.js +159 -0
  48. package/data/build/dist/client/features/reverse-proxy.d.ts +12 -0
  49. package/data/build/dist/client/features/reverse-proxy.js +112 -0
  50. package/data/build/dist/client/features/terminal-enhancement-panel.d.ts +5 -0
  51. package/data/build/dist/client/features/terminal-enhancement-panel.js +160 -0
  52. package/data/build/dist/client/features/terminal-enhancement.d.ts +4 -0
  53. package/data/build/dist/client/features/terminal-enhancement.js +24 -0
  54. package/data/build/dist/client/features/types.d.ts +58 -0
  55. package/data/build/dist/client/features/types.js +2 -0
  56. package/data/build/dist/client/features/workspace-session-enhancement-panel.d.ts +5 -0
  57. package/data/build/dist/client/features/workspace-session-enhancement-panel.js +66 -0
  58. package/data/build/dist/client/features/workspace-session-enhancement.d.ts +4 -0
  59. package/data/build/dist/client/features/workspace-session-enhancement.js +101 -0
  60. package/data/build/dist/client/h5-bootstrap-entry.d.ts +2 -0
  61. package/data/build/dist/client/h5-bootstrap-entry.js +17 -0
  62. package/data/build/dist/client/index.d.ts +31 -0
  63. package/data/build/dist/client/index.js +98 -0
  64. package/data/build/dist/client/lan-access.d.ts +28 -0
  65. package/data/build/dist/client/lan-access.js +68 -0
  66. package/data/build/dist/client/locale.d.ts +20 -0
  67. package/data/build/dist/client/locale.js +393 -0
  68. package/data/build/dist/client/provider-icon-assets.d.ts +2 -0
  69. package/data/build/dist/client/provider-icon-assets.js +23 -0
  70. package/data/build/dist/client/provider-icons.d.ts +19 -0
  71. package/data/build/dist/client/provider-icons.js +39 -0
  72. package/data/build/dist/client/remote-web-context.d.ts +57 -0
  73. package/data/build/dist/client/remote-web-context.js +939 -0
  74. package/data/build/dist/client/session-adapter-cache.d.ts +18 -0
  75. package/data/build/dist/client/session-adapter-cache.js +84 -0
  76. package/data/build/dist/client/settings-bridge.d.ts +32 -0
  77. package/data/build/dist/client/settings-bridge.js +126 -0
  78. package/data/build/dist/client/settings-section.d.ts +30 -0
  79. package/data/build/dist/client/settings-section.js +93 -0
  80. package/data/build/dist/client/subscription-slot.d.ts +18 -0
  81. package/data/build/dist/client/subscription-slot.js +223 -0
  82. package/data/build/dist/client/terminal/index.d.ts +4 -0
  83. package/data/build/dist/client/terminal/index.js +3 -0
  84. package/data/build/dist/client/terminal/model.d.ts +116 -0
  85. package/data/build/dist/client/terminal/model.js +435 -0
  86. package/data/build/dist/client/terminal/styles.d.ts +21 -0
  87. package/data/build/dist/client/terminal/styles.js +51 -0
  88. package/data/build/dist/client/terminal/ui.d.ts +19 -0
  89. package/data/build/dist/client/terminal/ui.js +257 -0
  90. package/data/build/dist/client/terminal/xterm-view.d.ts +13 -0
  91. package/data/build/dist/client/terminal/xterm-view.js +213 -0
  92. package/data/build/dist/client/theme.d.ts +56 -0
  93. package/data/build/dist/client/theme.js +186 -0
  94. package/data/build/dist/client/workspace-session-archive-dom.d.ts +29 -0
  95. package/data/build/dist/client/workspace-session-archive-dom.js +525 -0
  96. package/data/build/dist/client/workspace-session-fiber.d.ts +3 -0
  97. package/data/build/dist/client/workspace-session-fiber.js +33 -0
  98. package/data/build/dist/client/workspace-session-logo-dom.d.ts +26 -0
  99. package/data/build/dist/client/workspace-session-logo-dom.js +128 -0
  100. package/data/build/dist/features/index.d.ts +3 -0
  101. package/data/build/dist/features/index.js +2 -0
  102. package/data/build/dist/features/registry.d.ts +74 -0
  103. package/data/build/dist/features/registry.js +382 -0
  104. package/data/build/dist/features/resource-scope/index.d.ts +39 -0
  105. package/data/build/dist/features/resource-scope/index.js +161 -0
  106. package/data/build/dist/host/auth-session.d.ts +42 -0
  107. package/data/build/dist/host/auth-session.js +186 -0
  108. package/data/build/dist/host/cli-adapters/claude-driver.d.ts +14 -0
  109. package/data/build/dist/host/cli-adapters/claude-driver.js +103 -0
  110. package/data/build/dist/host/cli-adapters/codex-driver.d.ts +45 -0
  111. package/data/build/dist/host/cli-adapters/codex-driver.js +534 -0
  112. package/data/build/dist/host/cli-adapters/command-code-driver.d.ts +38 -0
  113. package/data/build/dist/host/cli-adapters/command-code-driver.js +394 -0
  114. package/data/build/dist/host/cli-adapters/command-code-subscription.d.ts +19 -0
  115. package/data/build/dist/host/cli-adapters/command-code-subscription.js +126 -0
  116. package/data/build/dist/host/cli-adapters/driver.d.ts +41 -0
  117. package/data/build/dist/host/cli-adapters/driver.js +2 -0
  118. package/data/build/dist/host/cli-adapters/dsh-message-projector.d.ts +37 -0
  119. package/data/build/dist/host/cli-adapters/dsh-message-projector.js +180 -0
  120. package/data/build/dist/host/cli-adapters/dsh-tool-history.d.ts +48 -0
  121. package/data/build/dist/host/cli-adapters/dsh-tool-history.js +373 -0
  122. package/data/build/dist/host/cli-adapters/feature.d.ts +7 -0
  123. package/data/build/dist/host/cli-adapters/feature.js +335 -0
  124. package/data/build/dist/host/cli-adapters/gemini-driver.d.ts +24 -0
  125. package/data/build/dist/host/cli-adapters/gemini-driver.js +427 -0
  126. package/data/build/dist/host/cli-adapters/grok-driver.d.ts +38 -0
  127. package/data/build/dist/host/cli-adapters/grok-driver.js +372 -0
  128. package/data/build/dist/host/cli-adapters/http-sse-client.d.ts +22 -0
  129. package/data/build/dist/host/cli-adapters/http-sse-client.js +99 -0
  130. package/data/build/dist/host/cli-adapters/interaction-events.d.ts +11 -0
  131. package/data/build/dist/host/cli-adapters/interaction-events.js +80 -0
  132. package/data/build/dist/host/cli-adapters/json-rpc-process.d.ts +65 -0
  133. package/data/build/dist/host/cli-adapters/json-rpc-process.js +256 -0
  134. package/data/build/dist/host/cli-adapters/kimi-driver.d.ts +21 -0
  135. package/data/build/dist/host/cli-adapters/kimi-driver.js +382 -0
  136. package/data/build/dist/host/cli-adapters/model-catalog.d.ts +22 -0
  137. package/data/build/dist/host/cli-adapters/model-catalog.js +89 -0
  138. package/data/build/dist/host/cli-adapters/opencode-driver.d.ts +55 -0
  139. package/data/build/dist/host/cli-adapters/opencode-driver.js +728 -0
  140. package/data/build/dist/host/cli-adapters/pi-driver.d.ts +43 -0
  141. package/data/build/dist/host/cli-adapters/pi-driver.js +312 -0
  142. package/data/build/dist/host/cli-adapters/process-utils.d.ts +16 -0
  143. package/data/build/dist/host/cli-adapters/process-utils.js +27 -0
  144. package/data/build/dist/host/cli-adapters/provider-subscription.d.ts +82 -0
  145. package/data/build/dist/host/cli-adapters/provider-subscription.js +610 -0
  146. package/data/build/dist/host/cli-adapters/registry.d.ts +95 -0
  147. package/data/build/dist/host/cli-adapters/registry.js +659 -0
  148. package/data/build/dist/host/cli-adapters/rpc-driver-utils.d.ts +24 -0
  149. package/data/build/dist/host/cli-adapters/rpc-driver-utils.js +119 -0
  150. package/data/build/dist/host/cli-adapters/session-probe.d.ts +20 -0
  151. package/data/build/dist/host/cli-adapters/session-probe.js +139 -0
  152. package/data/build/dist/host/cli-adapters/session-store.d.ts +68 -0
  153. package/data/build/dist/host/cli-adapters/session-store.js +180 -0
  154. package/data/build/dist/host/cli-adapters/standard-stream-driver.d.ts +45 -0
  155. package/data/build/dist/host/cli-adapters/standard-stream-driver.js +205 -0
  156. package/data/build/dist/host/cli-adapters/stream-normalizer.d.ts +25 -0
  157. package/data/build/dist/host/cli-adapters/stream-normalizer.js +83 -0
  158. package/data/build/dist/host/cli-adapters/tool-observation.d.ts +9 -0
  159. package/data/build/dist/host/cli-adapters/tool-observation.js +39 -0
  160. package/data/build/dist/host/control-api-client.d.ts +84 -0
  161. package/data/build/dist/host/control-api-client.js +130 -0
  162. package/data/build/dist/host/credential-store.d.ts +54 -0
  163. package/data/build/dist/host/credential-store.js +114 -0
  164. package/data/build/dist/host/debug.d.ts +79 -0
  165. package/data/build/dist/host/debug.js +295 -0
  166. package/data/build/dist/host/dsh-device-runtime.d.ts +39 -0
  167. package/data/build/dist/host/dsh-device-runtime.js +118 -0
  168. package/data/build/dist/host/dsh-gateway-feature.d.ts +5 -0
  169. package/data/build/dist/host/dsh-gateway-feature.js +55 -0
  170. package/data/build/dist/host/dsh-runtime-version.d.ts +12 -0
  171. package/data/build/dist/host/dsh-runtime-version.js +69 -0
  172. package/data/build/dist/host/features/auth.d.ts +11 -0
  173. package/data/build/dist/host/features/auth.js +273 -0
  174. package/data/build/dist/host/features/debug.d.ts +5 -0
  175. package/data/build/dist/host/features/debug.js +90 -0
  176. package/data/build/dist/host/features/host-status.d.ts +12 -0
  177. package/data/build/dist/host/features/host-status.js +54 -0
  178. package/data/build/dist/host/features/index.d.ts +19 -0
  179. package/data/build/dist/host/features/index.js +29 -0
  180. package/data/build/dist/host/features/lan-access-dsh.d.ts +8 -0
  181. package/data/build/dist/host/features/lan-access-dsh.js +45 -0
  182. package/data/build/dist/host/features/terminal-process.d.ts +5 -0
  183. package/data/build/dist/host/features/terminal-process.js +110 -0
  184. package/data/build/dist/host/features/terminal-status.d.ts +18 -0
  185. package/data/build/dist/host/features/terminal-status.js +56 -0
  186. package/data/build/dist/host/features/types.d.ts +41 -0
  187. package/data/build/dist/host/features/types.js +2 -0
  188. package/data/build/dist/host/index.d.ts +43 -0
  189. package/data/build/dist/host/index.js +135 -0
  190. package/data/build/dist/host/lan-access-dsh.d.ts +83 -0
  191. package/data/build/dist/host/lan-access-dsh.js +831 -0
  192. package/data/build/dist/host/native-session-bridge.d.ts +130 -0
  193. package/data/build/dist/host/native-session-bridge.js +317 -0
  194. package/data/build/dist/host/relay-tunnel-runtime.d.ts +97 -0
  195. package/data/build/dist/host/relay-tunnel-runtime.js +361 -0
  196. package/data/build/dist/host/remote-web-runtime.d.ts +78 -0
  197. package/data/build/dist/host/remote-web-runtime.js +559 -0
  198. package/data/build/dist/host/rpc-table.d.ts +32 -0
  199. package/data/build/dist/host/rpc-table.js +47 -0
  200. package/data/build/dist/host/rpc.d.ts +18 -0
  201. package/data/build/dist/host/rpc.js +248 -0
  202. package/data/build/dist/host/settings.d.ts +19 -0
  203. package/data/build/dist/host/settings.js +80 -0
  204. package/data/build/dist/host/terminal/attachment-registry.d.ts +17 -0
  205. package/data/build/dist/host/terminal/attachment-registry.js +49 -0
  206. package/data/build/dist/host/terminal/backends/conpty-backend.d.ts +39 -0
  207. package/data/build/dist/host/terminal/backends/conpty-backend.js +160 -0
  208. package/data/build/dist/host/terminal/backends/local-pty-backend.d.ts +36 -0
  209. package/data/build/dist/host/terminal/backends/local-pty-backend.js +178 -0
  210. package/data/build/dist/host/terminal/backends/tmux-backend.d.ts +40 -0
  211. package/data/build/dist/host/terminal/backends/tmux-backend.js +191 -0
  212. package/data/build/dist/host/terminal/broker/conpty-broker-client.d.ts +27 -0
  213. package/data/build/dist/host/terminal/broker/conpty-broker-client.js +154 -0
  214. package/data/build/dist/host/terminal/broker/conpty-broker-process.d.ts +10 -0
  215. package/data/build/dist/host/terminal/broker/conpty-broker-process.js +147 -0
  216. package/data/build/dist/host/terminal/broker/conpty-broker-protocol.d.ts +92 -0
  217. package/data/build/dist/host/terminal/broker/conpty-broker-protocol.js +134 -0
  218. package/data/build/dist/host/terminal/controller-factory.d.ts +37 -0
  219. package/data/build/dist/host/terminal/controller-factory.js +82 -0
  220. package/data/build/dist/host/terminal/index.d.ts +17 -0
  221. package/data/build/dist/host/terminal/index.js +17 -0
  222. package/data/build/dist/host/terminal/runtime-adapter.d.ts +77 -0
  223. package/data/build/dist/host/terminal/runtime-adapter.js +18 -0
  224. package/data/build/dist/host/terminal/runtime-manager.d.ts +41 -0
  225. package/data/build/dist/host/terminal/runtime-manager.js +179 -0
  226. package/data/build/dist/host/terminal/shell-detection.d.ts +23 -0
  227. package/data/build/dist/host/terminal/shell-detection.js +105 -0
  228. package/data/build/dist/host/terminal/startup.d.ts +33 -0
  229. package/data/build/dist/host/terminal/startup.js +100 -0
  230. package/data/build/dist/host/terminal/terminal-controller.d.ts +78 -0
  231. package/data/build/dist/host/terminal/terminal-controller.js +324 -0
  232. package/data/build/dist/host/terminal/terminal-process-service.d.ts +30 -0
  233. package/data/build/dist/host/terminal/terminal-process-service.js +194 -0
  234. package/data/build/dist/host/terminal/terminal-process-store.d.ts +45 -0
  235. package/data/build/dist/host/terminal/terminal-process-store.js +183 -0
  236. package/data/build/dist/host/terminal/terminal-service.d.ts +87 -0
  237. package/data/build/dist/host/terminal/terminal-service.js +528 -0
  238. package/data/build/dist/host/terminal/terminal-store.d.ts +49 -0
  239. package/data/build/dist/host/terminal/terminal-store.js +242 -0
  240. package/data/build/dist/index.d.ts +37 -0
  241. package/data/build/dist/index.js +26 -0
  242. package/data/build/dist/shared/contracts/auth.d.ts +122 -0
  243. package/data/build/dist/shared/contracts/auth.js +8 -0
  244. package/data/build/dist/shared/contracts/cli-adapter.d.ts +192 -0
  245. package/data/build/dist/shared/contracts/cli-adapter.js +2 -0
  246. package/data/build/dist/shared/contracts/command-code.d.ts +5 -0
  247. package/data/build/dist/shared/contracts/command-code.js +2 -0
  248. package/data/build/dist/shared/contracts/config.d.ts +113 -0
  249. package/data/build/dist/shared/contracts/config.js +86 -0
  250. package/data/build/dist/shared/contracts/debug-config.d.ts +28 -0
  251. package/data/build/dist/shared/contracts/debug-config.js +78 -0
  252. package/data/build/dist/shared/contracts/debug.d.ts +75 -0
  253. package/data/build/dist/shared/contracts/debug.js +121 -0
  254. package/data/build/dist/shared/contracts/dsh-device.d.ts +72 -0
  255. package/data/build/dist/shared/contracts/dsh-device.js +2 -0
  256. package/data/build/dist/shared/contracts/errors.d.ts +33 -0
  257. package/data/build/dist/shared/contracts/errors.js +41 -0
  258. package/data/build/dist/shared/contracts/feature.d.ts +71 -0
  259. package/data/build/dist/shared/contracts/feature.js +2 -0
  260. package/data/build/dist/shared/contracts/host-status.d.ts +14 -0
  261. package/data/build/dist/shared/contracts/host-status.js +2 -0
  262. package/data/build/dist/shared/contracts/lan-access-dsh.d.ts +30 -0
  263. package/data/build/dist/shared/contracts/lan-access-dsh.js +2 -0
  264. package/data/build/dist/shared/contracts/peer-host.d.ts +37 -0
  265. package/data/build/dist/shared/contracts/peer-host.js +9 -0
  266. package/data/build/dist/shared/contracts/signaling.d.ts +67 -0
  267. package/data/build/dist/shared/contracts/signaling.js +2 -0
  268. package/data/build/dist/shared/contracts/subscription.d.ts +69 -0
  269. package/data/build/dist/shared/contracts/subscription.js +2 -0
  270. package/data/build/dist/shared/contracts/terminal-process.d.ts +65 -0
  271. package/data/build/dist/shared/contracts/terminal-process.js +2 -0
  272. package/data/build/dist/shared/contracts/terminal.d.ts +127 -0
  273. package/data/build/dist/shared/contracts/terminal.js +2 -0
  274. package/data/build/dist/shared/contracts/transport.d.ts +45 -0
  275. package/data/build/dist/shared/contracts/transport.js +3 -0
  276. package/data/build/dist/shared/contracts/version.d.ts +19 -0
  277. package/data/build/dist/shared/contracts/version.js +74 -0
  278. package/data/build/dist/shared/index.d.ts +22 -0
  279. package/data/build/dist/shared/index.js +9 -0
  280. package/data/build/dist/transport/carrier.d.ts +38 -0
  281. package/data/build/dist/transport/carrier.js +268 -0
  282. package/data/build/dist/transport/debug.d.ts +22 -0
  283. package/data/build/dist/transport/debug.js +57 -0
  284. package/data/build/dist/transport/dsh-envelope.d.ts +41 -0
  285. package/data/build/dist/transport/dsh-envelope.js +107 -0
  286. package/data/build/dist/transport/dsh-gateway.d.ts +64 -0
  287. package/data/build/dist/transport/dsh-gateway.js +254 -0
  288. package/data/build/dist/transport/dsh-session.d.ts +55 -0
  289. package/data/build/dist/transport/dsh-session.js +256 -0
  290. package/data/build/dist/transport/dsh-transport.d.ts +57 -0
  291. package/data/build/dist/transport/dsh-transport.js +125 -0
  292. package/data/build/dist/transport/frame.d.ts +132 -0
  293. package/data/build/dist/transport/frame.js +168 -0
  294. package/data/build/dist/transport/index.d.ts +11 -0
  295. package/data/build/dist/transport/index.js +11 -0
  296. package/data/build/dist/transport/multiplexer.d.ts +63 -0
  297. package/data/build/dist/transport/multiplexer.js +323 -0
  298. package/data/build/dist/transport/webrtc-client.d.ts +65 -0
  299. package/data/build/dist/transport/webrtc-client.js +255 -0
  300. package/data/build/dist/transport/webrtc-host.d.ts +58 -0
  301. package/data/build/dist/transport/webrtc-host.js +252 -0
  302. package/data/build/dist/typert.host.d.ts +25 -0
  303. package/data/build/dist/typert.host.js +150 -0
  304. package/dsh.bundle.patch +12 -0
  305. package/package.json +135 -0
  306. package/profile/README.md +27 -0
  307. package/profile/cordis.patch.yml +2 -0
  308. package/profile/package.json +20 -0
  309. package/profile/scripts/check-dsh-install.mjs +71 -0
  310. package/profile/version.json +5 -0
  311. package/scripts/check-dsh-install.mjs +88 -0
  312. package/version.json +6 -0
@@ -0,0 +1,66 @@
1
+ import { createElement, useState } from 'react';
2
+ import { CODINGNS_WORKSPACE_SESSION_ENHANCEMENT_FIELD, DEFAULT_WORKSPACE_SESSION_ENHANCEMENT_SETTINGS, } from '../../shared/contracts/config.js';
3
+ import { dshFormRootStyle, dshSettingsHelpStyle, dshSettingsListRowStyle, dshThemeColor, } from '../theme.js';
4
+ import { useCodingNsTranslator } from '../locale.js';
5
+ /** 工作区会话增强的单列设置面板。 */
6
+ export function WorkspaceSessionEnhancementPanel({ services, enabled, snapshot }) {
7
+ const t = useCodingNsTranslator(services.locale);
8
+ const [writeError, setWriteError] = useState(null);
9
+ const value = snapshot.value?.workspaceSessionEnhancement
10
+ ?? DEFAULT_WORKSPACE_SESSION_ENHANCEMENT_SETTINGS;
11
+ const disabled = !enabled || snapshot.status === 'loading' || !snapshot.writable;
12
+ const updateSetting = (field, nextValue) => {
13
+ setWriteError(null);
14
+ void services.settings.mutate([{
15
+ op: 'set',
16
+ path: [CODINGNS_WORKSPACE_SESSION_ENHANCEMENT_FIELD, field],
17
+ value: nextValue,
18
+ }]).catch((cause) => {
19
+ setWriteError(cause instanceof Error ? cause.message : String(cause));
20
+ });
21
+ };
22
+ return createElement('div', {
23
+ 'aria-disabled': disabled,
24
+ style: {
25
+ ...dshFormRootStyle,
26
+ display: 'flex',
27
+ flexDirection: 'column',
28
+ gap: 12,
29
+ opacity: disabled ? 0.5 : 1,
30
+ pointerEvents: disabled ? 'none' : 'auto',
31
+ },
32
+ }, createElement('label', {
33
+ style: dshSettingsListRowStyle,
34
+ }, createElement('span', { style: { minWidth: 0 } }, createElement('strong', { style: { display: 'block', fontSize: 13, lineHeight: 1.4 } }, t('workspace.showLogo')), createElement('span', { style: { display: 'block', marginTop: 3, ...dshSettingsHelpStyle } }, t('workspace.logoDescription'))), createElement('input', {
35
+ type: 'checkbox',
36
+ role: 'switch',
37
+ 'aria-label': t('workspace.showLogo'),
38
+ checked: value.showAdapterLogo,
39
+ disabled,
40
+ onChange: (event) => updateSetting('showAdapterLogo', event.currentTarget.checked),
41
+ style: { flex: '0 0 auto', accentColor: dshThemeColor.accent },
42
+ })), createElement('label', {
43
+ style: dshSettingsListRowStyle,
44
+ }, createElement('span', { style: { minWidth: 0 } }, createElement('strong', { style: { display: 'block', fontSize: 13, lineHeight: 1.4 } }, t('workspace.showSubscriptionUsage')), createElement('span', { style: { display: 'block', marginTop: 3, ...dshSettingsHelpStyle } }, t('workspace.subscriptionUsageDescription'))), createElement('input', {
45
+ type: 'checkbox',
46
+ role: 'switch',
47
+ 'aria-label': t('workspace.showSubscriptionUsage'),
48
+ checked: value.showSubscriptionUsage,
49
+ disabled,
50
+ onChange: (event) => updateSetting('showSubscriptionUsage', event.currentTarget.checked),
51
+ style: { flex: '0 0 auto', accentColor: dshThemeColor.accent },
52
+ })), createElement('label', {
53
+ style: dshSettingsListRowStyle,
54
+ }, createElement('span', { style: { minWidth: 0 } }, createElement('strong', { style: { display: 'block', fontSize: 13, lineHeight: 1.4 } }, t('workspace.showArchivedSessions')), createElement('span', { style: { display: 'block', marginTop: 3, ...dshSettingsHelpStyle } }, t('workspace.archivedSessionsDescription'))), createElement('input', {
55
+ type: 'checkbox',
56
+ role: 'switch',
57
+ 'aria-label': t('workspace.showArchivedSessions'),
58
+ checked: value.showArchivedSessions,
59
+ disabled,
60
+ onChange: (event) => updateSetting('showArchivedSessions', event.currentTarget.checked),
61
+ style: { flex: '0 0 auto', accentColor: dshThemeColor.accent },
62
+ })), writeError === null
63
+ ? null
64
+ : createElement('div', { role: 'alert', style: { color: dshThemeColor.error, fontSize: 12 } }, writeError));
65
+ }
66
+ //# sourceMappingURL=workspace-session-enhancement-panel.js.map
@@ -0,0 +1,4 @@
1
+ import type { CodingNsClientFeatureModule } from './types.js';
2
+ /** DSH 0.1.6 原生会话行增强:Logo 与归档会话入口共用同一生命周期。 */
3
+ export declare const workspaceSessionEnhancementFeature: CodingNsClientFeatureModule;
4
+ //# sourceMappingURL=workspace-session-enhancement.d.ts.map
@@ -0,0 +1,101 @@
1
+ import { DEFAULT_WORKSPACE_SESSION_ENHANCEMENT_SETTINGS } from '../../shared/contracts/config.js';
2
+ import { clearSessionAdapters, fetchSessionAdapters, replaceSessionAdapters, } from '../session-adapter-cache.js';
3
+ import { startWorkspaceSessionLogoDom } from '../workspace-session-logo-dom.js';
4
+ import { startWorkspaceSessionArchiveDom } from '../workspace-session-archive-dom.js';
5
+ import { WorkspaceSessionEnhancementPanel } from './workspace-session-enhancement-panel.js';
6
+ import { registerSubscriptionSlot } from '../subscription-slot.js';
7
+ /** DSH 0.1.6 原生会话行增强:Logo 与归档会话入口共用同一生命周期。 */
8
+ export const workspaceSessionEnhancementFeature = {
9
+ descriptor: {
10
+ name: 'workspaceSessionEnhancement',
11
+ version: '0.1.0',
12
+ enabledByDefault: false,
13
+ dependencies: ['cliAdapters'],
14
+ runtime: 'client',
15
+ ui: {
16
+ label: '工作区会话增强',
17
+ description: '在原生工作区会话行显示 Agent Logo、归档入口和订阅/用量信息。',
18
+ labelKey: 'feature.workspaceSession.label',
19
+ descriptionKey: 'feature.workspaceSession.description',
20
+ order: 35,
21
+ defaultOpen: true,
22
+ legacyFallback: true,
23
+ legacyFallbackKey: 'feature.workspaceSession.legacyFallback',
24
+ },
25
+ },
26
+ start(context) {
27
+ let generation = 0;
28
+ let logoDom;
29
+ let archiveDom;
30
+ let disposeSubscription;
31
+ const disableLogo = () => {
32
+ generation += 1;
33
+ logoDom?.dispose();
34
+ logoDom = undefined;
35
+ clearSessionAdapters();
36
+ };
37
+ const enableArchive = () => {
38
+ if (archiveDom === undefined)
39
+ archiveDom = startWorkspaceSessionArchiveDom({ remote: context.services.remote });
40
+ };
41
+ const enableSubscription = () => {
42
+ if (disposeSubscription !== undefined || context.services.slots === undefined)
43
+ return;
44
+ disposeSubscription = registerSubscriptionSlot(context.services.slots, context.services.rpc);
45
+ };
46
+ const disableSubscription = () => {
47
+ disposeSubscription?.();
48
+ disposeSubscription = undefined;
49
+ };
50
+ const disposeAll = () => {
51
+ disableLogo();
52
+ archiveDom?.dispose();
53
+ archiveDom = undefined;
54
+ disableSubscription();
55
+ };
56
+ const enableLogo = () => {
57
+ if (logoDom !== undefined)
58
+ return;
59
+ const currentGeneration = ++generation;
60
+ logoDom = startWorkspaceSessionLogoDom();
61
+ void fetchSessionAdapters(context.services.rpc)
62
+ .then((bindings) => {
63
+ if (generation !== currentGeneration || logoDom === undefined)
64
+ return;
65
+ replaceSessionAdapters(bindings);
66
+ logoDom.refresh();
67
+ archiveDom?.refresh();
68
+ })
69
+ .catch(() => undefined);
70
+ };
71
+ const sync = () => {
72
+ const workspaceSettings = context.services.settings.getSnapshot().value?.workspaceSessionEnhancement;
73
+ const showArchivedSessions = workspaceSettings?.showArchivedSessions
74
+ ?? DEFAULT_WORKSPACE_SESSION_ENHANCEMENT_SETTINGS.showArchivedSessions;
75
+ if (showArchivedSessions)
76
+ enableArchive();
77
+ else {
78
+ archiveDom?.dispose();
79
+ archiveDom = undefined;
80
+ }
81
+ const showAdapterLogo = workspaceSettings?.showAdapterLogo
82
+ ?? DEFAULT_WORKSPACE_SESSION_ENHANCEMENT_SETTINGS.showAdapterLogo;
83
+ if (showAdapterLogo)
84
+ enableLogo();
85
+ else
86
+ disableLogo();
87
+ const showSubscriptionUsage = workspaceSettings?.showSubscriptionUsage
88
+ ?? DEFAULT_WORKSPACE_SESSION_ENHANCEMENT_SETTINGS.showSubscriptionUsage;
89
+ if (showSubscriptionUsage)
90
+ enableSubscription();
91
+ else
92
+ disableSubscription();
93
+ };
94
+ sync();
95
+ const unsubscribe = context.services.settings.subscribe(sync);
96
+ context.resources.add(unsubscribe);
97
+ context.resources.add(disposeAll);
98
+ },
99
+ settingsPanel: WorkspaceSessionEnhancementPanel,
100
+ };
101
+ //# sourceMappingURL=workspace-session-enhancement.js.map
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=h5-bootstrap-entry.d.ts.map
@@ -0,0 +1,17 @@
1
+ import { createHttpDshH5ControlApi, startDshH5BrowserBootstrap } from './dsh-h5-bootstrap.js';
2
+ /**
3
+ * 独立 H5 静态项目使用的浏览器入口。
4
+ * 这里故意只暴露无凭据的工厂和启动函数;Cookie 由浏览器自动管理,
5
+ * 页面脚本永远拿不到 Control API 的 HttpOnly 会话内容。
6
+ */
7
+ const runtime = {
8
+ createHttpDshH5ControlApi,
9
+ startDshH5BrowserBootstrap,
10
+ };
11
+ Object.defineProperty(globalThis, 'DshCodingNsH5', {
12
+ configurable: true,
13
+ enumerable: false,
14
+ value: runtime,
15
+ writable: false,
16
+ });
17
+ //# sourceMappingURL=h5-bootstrap-entry.js.map
@@ -0,0 +1,31 @@
1
+ /**
2
+ * DSH Client 入口。
3
+ *
4
+ * 该文件只使用浏览器安全的 TypeScript/JavaScript。Client 侧能力全部以功能模块
5
+ * 形式交给 FeatureRegistry 管理:设置页遍历注册表渲染卡片,设置里的启用开关
6
+ * 驱动模块 start/disable 与资源清理。入口只负责装配与依赖声明。
7
+ */
8
+ import type { Context } from '@deepseek-ai/cordis';
9
+ import './provider-icon-assets.js';
10
+ export { ensureCryptoRandomUUID } from './lan-access.js';
11
+ export type { CryptoRandomUUIDInstallResult, LanAccessCrypto, LanAccessGlobal, } from './lan-access.js';
12
+ export { CLIENT_FEATURES, settingsModules, startBrowserRelayConnection } from './features/index.js';
13
+ export { chooseDshDevice, createHttpDshH5ControlApi, startDshH5Bootstrap, startDshH5BrowserBootstrap } from './dsh-h5-bootstrap.js';
14
+ export type { DshH5BootstrapOptions, DshH5BootstrapResult, DshH5BrowserBootstrapOptions, DshH5BrowserBootstrapResult, DshH5BrowserControlApi, } from './dsh-h5-bootstrap.js';
15
+ export { RemoteDshWebContext } from './remote-web-context.js';
16
+ export type { RemoteDshWebBoot, RemoteDshWebContextOptions } from './remote-web-context.js';
17
+ export type { CodingNsClientFeatureModule, CodingNsClientServices, CodingNsRpcClient, CodingNsRpcResult, FeaturePanelProps, } from './features/index.js';
18
+ export { CodingNsSettingsSection } from './settings-section.js';
19
+ export { startWorkspaceSessionArchiveDom, WORKSPACE_SESSION_ARCHIVE_ATTRIBUTE, WORKSPACE_SESSION_ARCHIVE_MODAL_ATTRIBUTE, } from './workspace-session-archive-dom.js';
20
+ export { CodingNsTerminalView, CodingNsWebTerminals, registerCodingNsTerminalUi } from './terminal/index.js';
21
+ export { registerSubscriptionSlot, registerCommandCodeSubscriptionSlot, CommandCodeSubscriptionSlot } from './subscription-slot.js';
22
+ /** Client Runner 用于等待服务就绪的 Cordis 依赖声明。 */
23
+ export declare const inject: readonly ["slots", "settingsScope", "connection", "remote", "remote.workspace", "remote.session", "remote.terminal", "sidebarRight", "sidebarRightTabs", "theme", "locale", "uiConversation"];
24
+ /**
25
+ * 把 Codingns4DSH 设置页挂载到 DSH 设置左侧导航,并让模块开关驱动启停。
26
+ *
27
+ * 设置页与启停同步共享同一个注册表实例,所以界面上的模块清单就是运行时实际
28
+ * 管理的模块清单,两者不会漂移。
29
+ */
30
+ export declare function apply(ctx?: Context): void;
31
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1,98 @@
1
+ import './provider-icon-assets.js';
2
+ import { FeatureRegistry } from '../features/registry.js';
3
+ import { registerCodingNsLocale } from './locale.js';
4
+ import { CODINGNS_SETTINGS_NAMESPACE, captureRestartFeatureStates, enabledFeatureNames, } from '../shared/contracts/config.js';
5
+ import { CLIENT_FEATURES } from './features/index.js';
6
+ import { ensureCryptoRandomUUID } from './lan-access.js';
7
+ import { CodingNsSettingsSection } from './settings-section.js';
8
+ import { createCodingNsSettingsBridge } from './settings-bridge.js';
9
+ import { CodingNsWebTerminals, registerCodingNsTerminalUi } from './terminal/index.js';
10
+ import { startCodingNsAccountBar } from './account-bar.js';
11
+ import { assertInjectedDshVersion } from './dsh-runtime-version.js';
12
+ export { ensureCryptoRandomUUID } from './lan-access.js';
13
+ export { CLIENT_FEATURES, settingsModules, startBrowserRelayConnection } from './features/index.js';
14
+ export { chooseDshDevice, createHttpDshH5ControlApi, startDshH5Bootstrap, startDshH5BrowserBootstrap } from './dsh-h5-bootstrap.js';
15
+ export { RemoteDshWebContext } from './remote-web-context.js';
16
+ export { CodingNsSettingsSection } from './settings-section.js';
17
+ export { startWorkspaceSessionArchiveDom, WORKSPACE_SESSION_ARCHIVE_ATTRIBUTE, WORKSPACE_SESSION_ARCHIVE_MODAL_ATTRIBUTE, } from './workspace-session-archive-dom.js';
18
+ export { CodingNsTerminalView, CodingNsWebTerminals, registerCodingNsTerminalUi } from './terminal/index.js';
19
+ export { registerSubscriptionSlot, registerCommandCodeSubscriptionSlot, CommandCodeSubscriptionSlot } from './subscription-slot.js';
20
+ /** Client Runner 用于等待服务就绪的 Cordis 依赖声明。 */
21
+ export const inject = ['slots', 'settingsScope', 'connection', 'remote', 'remote.workspace', 'remote.session', 'remote.terminal', 'sidebarRight', 'sidebarRightTabs', 'theme', 'locale', 'uiConversation'];
22
+ /**
23
+ * 把 Codingns4DSH 设置页挂载到 DSH 设置左侧导航,并让模块开关驱动启停。
24
+ *
25
+ * 设置页与启停同步共享同一个注册表实例,所以界面上的模块清单就是运行时实际
26
+ * 管理的模块清单,两者不会漂移。
27
+ */
28
+ export function apply(ctx) {
29
+ if (ctx === undefined)
30
+ return;
31
+ const dshVersion = assertInjectedDshVersion();
32
+ // 版本门禁通过后才修改浏览器全局,避免不兼容 Client 留下半初始化状态。
33
+ ensureCryptoRandomUUID();
34
+ ctx.effect(() => registerCodingNsLocale(ctx), 'codingns4dsh: Client 词典');
35
+ ctx.inject(['slots', 'settingsScope', 'connection', 'remote', 'remote.workspace', 'remote.session', 'remote.terminal', 'sidebarRight', 'sidebarRightTabs', 'theme', 'locale', 'uiConversation'], (settingsCtx) => {
36
+ const localSettings = settingsCtx.settingsScope.bind({
37
+ namespace: CODINGNS_SETTINGS_NAMESPACE,
38
+ });
39
+ // Host 与 Client 共用同一个 cordis Context 类型,而 DSH 的 Host 侧声明会把
40
+ // connection 收窄成 Host 句柄;浏览器侧按 ConnectionHandle 收窄回真实形状。
41
+ const connection = settingsCtx.connection;
42
+ const settings = createCodingNsSettingsBridge(localSettings, connection.rpc);
43
+ // Typert manifest 可能晚于立即加载的 Client 入口完成登记,必须在每次调用时取 Remote。
44
+ const terminalRemote = () => settingsCtx.remote.terminal;
45
+ const webTerminals = new CodingNsWebTerminals(settingsCtx, terminalRemote);
46
+ const disposeTerminalUi = registerCodingNsTerminalUi(settingsCtx, webTerminals, settings);
47
+ const services = {
48
+ dshVersion,
49
+ settings,
50
+ rpc: connection.rpc,
51
+ remote: settingsCtx.remote,
52
+ slots: settingsCtx.slots,
53
+ locale: settingsCtx.locale,
54
+ uiConversation: settingsCtx.uiConversation,
55
+ uiContext: settingsCtx,
56
+ };
57
+ const disposeAccountBar = startCodingNsAccountBar(connection.rpc, undefined, settings);
58
+ const registry = new FeatureRegistry(services);
59
+ registry.registerMany(CLIENT_FEATURES);
60
+ registry.validate();
61
+ const restartStates = {};
62
+ let restartStatesCaptured = false;
63
+ settingsCtx.effect(() => {
64
+ const sync = () => {
65
+ const snapshot = settings.getSnapshot();
66
+ if (!restartStatesCaptured && snapshot.status === 'ready') {
67
+ Object.assign(restartStates, captureRestartFeatureStates(registry.descriptors(), snapshot.value, dshVersion));
68
+ restartStatesCaptured = true;
69
+ }
70
+ void registry
71
+ .reconcile(enabledFeatureNames(registry.descriptors(), snapshot.value, restartStates, dshVersion))
72
+ .catch((error) => {
73
+ console.error('codingns4dsh: 功能模块状态同步失败', error);
74
+ });
75
+ };
76
+ sync();
77
+ void settings.load().catch((error) => {
78
+ console.error('codingns4dsh: 远程设置读取失败', error);
79
+ });
80
+ const unsubscribe = settings.subscribe(sync);
81
+ return () => {
82
+ unsubscribe();
83
+ disposeTerminalUi();
84
+ disposeAccountBar.dispose();
85
+ void webTerminals.dispose();
86
+ settings.dispose();
87
+ };
88
+ }, 'codingns4dsh: 功能模块启停同步');
89
+ settingsCtx.slots.inject('settings.section', () => settingsCtx.slots.register({
90
+ name: 'settings.section',
91
+ id: 'codingns',
92
+ order: 30,
93
+ label: 'Codingns4DSH',
94
+ inject: () => ({ settings, registry, services, restartStates }),
95
+ }, CodingNsSettingsSection));
96
+ });
97
+ }
98
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1,28 @@
1
+ /**
2
+ * 局域网访问兼容模块。
3
+ *
4
+ * 非 HTTPS 页面通常仍然暴露 `crypto.getRandomValues`,但部分浏览器不会
5
+ * 暴露只在安全上下文提供的 `crypto.randomUUID`。DSH 页面依赖后者生成会话
6
+ * 标识,因此在 Client 入口加载时补齐一个 RFC 4122 v4 实现。
7
+ */
8
+ export interface LanAccessCrypto {
9
+ randomUUID?: () => string;
10
+ getRandomValues?: (array: Uint8Array) => Uint8Array;
11
+ }
12
+ export interface LanAccessGlobal {
13
+ crypto?: LanAccessCrypto;
14
+ }
15
+ export interface CryptoRandomUUIDInstallResult {
16
+ /** 安装调用结束后,目标是否拥有可调用的 randomUUID。 */
17
+ readonly available: boolean;
18
+ /** 本次调用是否新增了 randomUUID 实现。 */
19
+ readonly installed: boolean;
20
+ }
21
+ /**
22
+ * 确保目标页面拥有 `crypto.randomUUID`。
23
+ *
24
+ * 该函数幂等且可注入目标对象,便于在浏览器和测试环境中复用。无法修改
25
+ * 浏览器原生 crypto 时返回 available=false,不会阻止 DSH 继续启动。
26
+ */
27
+ export declare function ensureCryptoRandomUUID(target?: LanAccessGlobal): CryptoRandomUUIDInstallResult;
28
+ //# sourceMappingURL=lan-access.d.ts.map
@@ -0,0 +1,68 @@
1
+ /**
2
+ * 局域网访问兼容模块。
3
+ *
4
+ * 非 HTTPS 页面通常仍然暴露 `crypto.getRandomValues`,但部分浏览器不会
5
+ * 暴露只在安全上下文提供的 `crypto.randomUUID`。DSH 页面依赖后者生成会话
6
+ * 标识,因此在 Client 入口加载时补齐一个 RFC 4122 v4 实现。
7
+ */
8
+ /**
9
+ * 确保目标页面拥有 `crypto.randomUUID`。
10
+ *
11
+ * 该函数幂等且可注入目标对象,便于在浏览器和测试环境中复用。无法修改
12
+ * 浏览器原生 crypto 时返回 available=false,不会阻止 DSH 继续启动。
13
+ */
14
+ export function ensureCryptoRandomUUID(target = globalThis) {
15
+ const cryptoObject = target.crypto;
16
+ if (cryptoObject === undefined)
17
+ return { available: false, installed: false };
18
+ if (typeof cryptoObject.randomUUID === 'function')
19
+ return { available: true, installed: false };
20
+ const getRandomValues = typeof cryptoObject.getRandomValues === 'function'
21
+ ? cryptoObject.getRandomValues.bind(cryptoObject)
22
+ : undefined;
23
+ const randomUUID = () => createUuidV4(getRandomValues);
24
+ try {
25
+ Object.defineProperty(cryptoObject, 'randomUUID', {
26
+ configurable: true,
27
+ enumerable: false,
28
+ value: randomUUID,
29
+ writable: true,
30
+ });
31
+ }
32
+ catch {
33
+ try {
34
+ cryptoObject.randomUUID = randomUUID;
35
+ }
36
+ catch {
37
+ return { available: false, installed: false };
38
+ }
39
+ }
40
+ return typeof cryptoObject.randomUUID === 'function'
41
+ ? { available: true, installed: true }
42
+ : { available: false, installed: false };
43
+ }
44
+ function createUuidV4(getRandomValues) {
45
+ const bytes = new Uint8Array(16);
46
+ if (getRandomValues !== undefined) {
47
+ try {
48
+ getRandomValues(bytes);
49
+ }
50
+ catch {
51
+ fillWithMathRandom(bytes);
52
+ }
53
+ }
54
+ else {
55
+ fillWithMathRandom(bytes);
56
+ }
57
+ // RFC 4122: version 4 and the variant used by the standard UUID string form.
58
+ bytes[6] = (bytes[6] & 0x0f) | 0x40;
59
+ bytes[8] = (bytes[8] & 0x3f) | 0x80;
60
+ const hex = Array.from(bytes, (value) => value.toString(16).padStart(2, '0')).join('');
61
+ return `${hex.slice(0, 8)}-${hex.slice(8, 12)}-${hex.slice(12, 16)}-${hex.slice(16, 20)}-${hex.slice(20)}`;
62
+ }
63
+ function fillWithMathRandom(bytes) {
64
+ for (let index = 0; index < bytes.length; index += 1) {
65
+ bytes[index] = Math.floor(Math.random() * 256);
66
+ }
67
+ }
68
+ //# sourceMappingURL=lan-access.js.map
@@ -0,0 +1,20 @@
1
+ import type { Context } from '@deepseek-ai/cordis';
2
+ import type { LocaleRuntime } from '@deepseek-ai/dsh-client-locale/client';
3
+ import type { Translate } from '@deepseek-ai/dsh-client-ui-slots';
4
+ /** Codingns4DSH 自有词典命名空间。词典缺少的语言由 DSH 自动回退到英文。 */
5
+ export declare const CODINGNS_LOCALE_NS: "codingns";
6
+ declare module '@deepseek-ai/dsh-client-ui-slots' {
7
+ interface LocaleNamespaceMap {
8
+ codingns: string;
9
+ }
10
+ }
11
+ /** Client 侧服务中实际使用的 DSH 语言运行时最小接口。 */
12
+ export type CodingNsLocale = Pick<LocaleRuntime, 'bind' | 'getSnapshot' | 'subscribe' | 'register'>;
13
+ export type CodingNsTranslator = Translate<string>;
14
+ /** 在当前 Client Cordis 作用域注册中英文词典。 */
15
+ export declare function registerCodingNsLocale(ctx: Context): () => void;
16
+ /** 订阅 DSH 语言修订,并返回当前 Codingns4DSH 命名空间翻译函数。 */
17
+ export declare function useCodingNsTranslator(locale: CodingNsLocale): CodingNsTranslator;
18
+ /** 非 React 注册回调使用的翻译函数。 */
19
+ export declare function codingNsTranslator(locale: CodingNsLocale): CodingNsTranslator;
20
+ //# sourceMappingURL=locale.d.ts.map