@jingyi0605/codingns4dsh 0.2.1-beta.10 → 0.2.1-beta.12

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 (248) hide show
  1. package/README.en.md +7 -5
  2. package/README.md +12 -6
  3. package/data/build/dist/bootstrap/dsh-connection-adapter.d.ts +1 -1
  4. package/data/build/dist/bootstrap/index.d.ts +1 -1
  5. package/data/build/dist/client/bundle.js +9713 -7350
  6. package/data/build/dist/client/bundle.js.map +1 -1
  7. package/data/build/dist/client/cli-slots.d.ts +13 -3
  8. package/data/build/dist/client/cli-slots.d.ts.map +1 -1
  9. package/data/build/dist/client/cli-slots.js +93 -18
  10. package/data/build/dist/client/cli-slots.js.map +1 -1
  11. package/data/build/dist/client/client.assistant-configuration-view.js +4 -3
  12. package/data/build/dist/client/client.assistant-configuration-view.js.map +1 -1
  13. package/data/build/dist/client/client.moss-voice-output.js +415 -0
  14. package/data/build/dist/client/client.moss-voice-output.js.map +1 -0
  15. package/data/build/dist/client/client.native-workspace-store.js +4 -4
  16. package/data/build/dist/client/client.native-workspace-store.js.map +1 -1
  17. package/data/build/dist/client/client.primitives-adapter.js.map +1 -1
  18. package/data/build/dist/client/client.react-dom.js +0 -404
  19. package/data/build/dist/client/client.react-dom.js.map +1 -1
  20. package/data/build/dist/client/client.session-translation.js +105 -2
  21. package/data/build/dist/client/client.session-translation.js.map +1 -1
  22. package/data/build/dist/client/client.transport.js +103 -11
  23. package/data/build/dist/client/client.transport.js.map +1 -1
  24. package/data/build/dist/client/conversation-translation-settings.d.ts +10 -0
  25. package/data/build/dist/client/conversation-translation-settings.d.ts.map +1 -0
  26. package/data/build/dist/client/conversation-translation-settings.js +52 -0
  27. package/data/build/dist/client/conversation-translation-settings.js.map +1 -0
  28. package/data/build/dist/client/desktop-assistant.js +569 -450
  29. package/data/build/dist/client/features/cli-adapters.d.ts.map +1 -1
  30. package/data/build/dist/client/features/cli-adapters.js +3 -1
  31. package/data/build/dist/client/features/cli-adapters.js.map +1 -1
  32. package/data/build/dist/client/features/session-translation.d.ts.map +1 -1
  33. package/data/build/dist/client/features/session-translation.js +49 -48
  34. package/data/build/dist/client/features/session-translation.js.map +1 -1
  35. package/data/build/dist/client/locales/panels.d.ts.map +1 -1
  36. package/data/build/dist/client/locales/panels.js +103 -11
  37. package/data/build/dist/client/locales/panels.js.map +1 -1
  38. package/data/build/dist/client/native-model-translation-menu.d.ts +6 -0
  39. package/data/build/dist/client/native-model-translation-menu.d.ts.map +1 -0
  40. package/data/build/dist/client/native-model-translation-menu.js +57 -0
  41. package/data/build/dist/client/native-model-translation-menu.js.map +1 -0
  42. package/data/build/dist/client/native-translation-default.d.ts +6 -0
  43. package/data/build/dist/client/native-translation-default.d.ts.map +1 -0
  44. package/data/build/dist/client/native-translation-default.js +30 -0
  45. package/data/build/dist/client/native-translation-default.js.map +1 -0
  46. package/data/build/dist/client/session-translation-chat.d.ts +23 -2
  47. package/data/build/dist/client/session-translation-chat.d.ts.map +1 -1
  48. package/data/build/dist/client/session-translation-chat.js +238 -72
  49. package/data/build/dist/client/session-translation-chat.js.map +1 -1
  50. package/data/build/dist/client/session-translation-interactions.d.ts +31 -0
  51. package/data/build/dist/client/session-translation-interactions.d.ts.map +1 -0
  52. package/data/build/dist/client/session-translation-interactions.js +158 -0
  53. package/data/build/dist/client/session-translation-interactions.js.map +1 -0
  54. package/data/build/dist/client/session-translation-model-pool.d.ts +16 -0
  55. package/data/build/dist/client/session-translation-model-pool.d.ts.map +1 -0
  56. package/data/build/dist/client/session-translation-model-pool.js +246 -0
  57. package/data/build/dist/client/session-translation-model-pool.js.map +1 -0
  58. package/data/build/dist/client/session-translation-pending-dom.d.ts +8 -0
  59. package/data/build/dist/client/session-translation-pending-dom.d.ts.map +1 -0
  60. package/data/build/dist/client/session-translation-pending-dom.js +58 -0
  61. package/data/build/dist/client/session-translation-pending-dom.js.map +1 -0
  62. package/data/build/dist/client/session-translation-retry.d.ts +16 -0
  63. package/data/build/dist/client/session-translation-retry.d.ts.map +1 -0
  64. package/data/build/dist/client/session-translation-retry.js +66 -0
  65. package/data/build/dist/client/session-translation-retry.js.map +1 -0
  66. package/data/build/dist/client/session-translation-rules.d.ts +13 -0
  67. package/data/build/dist/client/session-translation-rules.d.ts.map +1 -0
  68. package/data/build/dist/client/session-translation-rules.js +58 -0
  69. package/data/build/dist/client/session-translation-rules.js.map +1 -0
  70. package/data/build/dist/client/style.css +276 -276
  71. package/data/build/dist/dsh-capabilities/client/interaction-presentation-adapter.d.ts +30 -0
  72. package/data/build/dist/dsh-capabilities/client/interaction-presentation-adapter.d.ts.map +1 -0
  73. package/data/build/dist/dsh-capabilities/client/interaction-presentation-adapter.js +93 -0
  74. package/data/build/dist/dsh-capabilities/client/interaction-presentation-adapter.js.map +1 -0
  75. package/data/build/dist/dsh-capabilities/client/interaction-text-dom.d.ts +12 -0
  76. package/data/build/dist/dsh-capabilities/client/interaction-text-dom.d.ts.map +1 -0
  77. package/data/build/dist/dsh-capabilities/client/interaction-text-dom.js +181 -0
  78. package/data/build/dist/dsh-capabilities/client/interaction-text-dom.js.map +1 -0
  79. package/data/build/dist/dsh-capabilities/client/message-presentation-adapter.d.ts +19 -0
  80. package/data/build/dist/dsh-capabilities/client/message-presentation-adapter.d.ts.map +1 -0
  81. package/data/build/dist/dsh-capabilities/client/message-presentation-adapter.js +39 -0
  82. package/data/build/dist/dsh-capabilities/client/message-presentation-adapter.js.map +1 -0
  83. package/data/build/dist/dsh-capabilities/client/primitives-adapter.d.ts +1 -0
  84. package/data/build/dist/dsh-capabilities/client/primitives-adapter.d.ts.map +1 -1
  85. package/data/build/dist/dsh-capabilities/client/primitives-adapter.js +1 -0
  86. package/data/build/dist/dsh-capabilities/client/primitives-adapter.js.map +1 -1
  87. package/data/build/dist/dsh-capabilities/client/question-history-adapter.d.ts +20 -0
  88. package/data/build/dist/dsh-capabilities/client/question-history-adapter.d.ts.map +1 -0
  89. package/data/build/dist/dsh-capabilities/client/question-history-adapter.js +65 -0
  90. package/data/build/dist/dsh-capabilities/client/question-history-adapter.js.map +1 -0
  91. package/data/build/dist/dsh-capabilities/client/slot-presentation-mirror.d.ts +32 -0
  92. package/data/build/dist/dsh-capabilities/client/slot-presentation-mirror.d.ts.map +1 -0
  93. package/data/build/dist/dsh-capabilities/client/slot-presentation-mirror.js +90 -0
  94. package/data/build/dist/dsh-capabilities/client/slot-presentation-mirror.js.map +1 -0
  95. package/data/build/dist/dsh-capabilities/host/connection-peer-adapter.d.ts +10 -0
  96. package/data/build/dist/dsh-capabilities/host/connection-peer-adapter.d.ts.map +1 -0
  97. package/data/build/dist/dsh-capabilities/host/connection-peer-adapter.js +34 -0
  98. package/data/build/dist/dsh-capabilities/host/connection-peer-adapter.js.map +1 -0
  99. package/data/build/dist/dsh-capabilities/host/native-dispatch-adapter.d.ts +21 -0
  100. package/data/build/dist/dsh-capabilities/host/native-dispatch-adapter.d.ts.map +1 -0
  101. package/data/build/dist/dsh-capabilities/host/native-dispatch-adapter.js +11 -0
  102. package/data/build/dist/dsh-capabilities/host/native-dispatch-adapter.js.map +1 -0
  103. package/data/build/dist/dsh-capabilities/host/session-activation-adapter.d.ts +17 -0
  104. package/data/build/dist/dsh-capabilities/host/session-activation-adapter.d.ts.map +1 -0
  105. package/data/build/dist/dsh-capabilities/host/session-activation-adapter.js +37 -0
  106. package/data/build/dist/dsh-capabilities/host/session-activation-adapter.js.map +1 -0
  107. package/data/build/dist/dsh-capabilities/host/session-model-selection-adapter.d.ts +17 -0
  108. package/data/build/dist/dsh-capabilities/host/session-model-selection-adapter.d.ts.map +1 -0
  109. package/data/build/dist/dsh-capabilities/host/session-model-selection-adapter.js +45 -0
  110. package/data/build/dist/dsh-capabilities/host/session-model-selection-adapter.js.map +1 -0
  111. package/data/build/dist/dsh-capabilities/host/session-prompt-adapter.d.ts +28 -0
  112. package/data/build/dist/dsh-capabilities/host/session-prompt-adapter.d.ts.map +1 -0
  113. package/data/build/dist/dsh-capabilities/host/session-prompt-adapter.js +31 -0
  114. package/data/build/dist/dsh-capabilities/host/session-prompt-adapter.js.map +1 -0
  115. package/data/build/dist/dsh-capabilities/matrix.d.ts.map +1 -1
  116. package/data/build/dist/dsh-capabilities/matrix.js +12 -3
  117. package/data/build/dist/dsh-capabilities/matrix.js.map +1 -1
  118. package/data/build/dist/dsh-capabilities/routes.d.ts.map +1 -1
  119. package/data/build/dist/dsh-capabilities/routes.js +26 -3
  120. package/data/build/dist/dsh-capabilities/routes.js.map +1 -1
  121. package/data/build/dist/dsh-capabilities/types.d.ts +1 -1
  122. package/data/build/dist/dsh-capabilities/types.d.ts.map +1 -1
  123. package/data/build/dist/dsh-capabilities/types.js.map +1 -1
  124. package/data/build/dist/host/cli-adapters/antigravity-driver.js +1 -1
  125. package/data/build/dist/host/cli-adapters/antigravity-driver.js.map +1 -1
  126. package/data/build/dist/host/cli-adapters/attachment-utils.d.ts +4 -3
  127. package/data/build/dist/host/cli-adapters/attachment-utils.d.ts.map +1 -1
  128. package/data/build/dist/host/cli-adapters/attachment-utils.js +9 -8
  129. package/data/build/dist/host/cli-adapters/attachment-utils.js.map +1 -1
  130. package/data/build/dist/host/cli-adapters/claude-driver.js +1 -1
  131. package/data/build/dist/host/cli-adapters/claude-driver.js.map +1 -1
  132. package/data/build/dist/host/cli-adapters/command-code-driver.js +1 -1
  133. package/data/build/dist/host/cli-adapters/command-code-driver.js.map +1 -1
  134. package/data/build/dist/host/cli-adapters/driver.d.ts +2 -0
  135. package/data/build/dist/host/cli-adapters/driver.d.ts.map +1 -1
  136. package/data/build/dist/host/cli-adapters/dsh-message-projector.d.ts +2 -0
  137. package/data/build/dist/host/cli-adapters/dsh-message-projector.d.ts.map +1 -1
  138. package/data/build/dist/host/cli-adapters/dsh-message-projector.js +28 -11
  139. package/data/build/dist/host/cli-adapters/dsh-message-projector.js.map +1 -1
  140. package/data/build/dist/host/cli-adapters/feature.d.ts.map +1 -1
  141. package/data/build/dist/host/cli-adapters/feature.js +369 -70
  142. package/data/build/dist/host/cli-adapters/feature.js.map +1 -1
  143. package/data/build/dist/host/cli-adapters/gemini-driver.js +1 -1
  144. package/data/build/dist/host/cli-adapters/gemini-driver.js.map +1 -1
  145. package/data/build/dist/host/cli-adapters/grok-driver.d.ts +1 -0
  146. package/data/build/dist/host/cli-adapters/grok-driver.d.ts.map +1 -1
  147. package/data/build/dist/host/cli-adapters/grok-driver.js +128 -40
  148. package/data/build/dist/host/cli-adapters/grok-driver.js.map +1 -1
  149. package/data/build/dist/host/cli-adapters/kimi-driver.js +2 -2
  150. package/data/build/dist/host/cli-adapters/kimi-driver.js.map +1 -1
  151. package/data/build/dist/host/cli-adapters/mcode-driver.js +1 -1
  152. package/data/build/dist/host/cli-adapters/mcode-driver.js.map +1 -1
  153. package/data/build/dist/host/cli-adapters/native-subagent-dispatch.js +2 -2
  154. package/data/build/dist/host/cli-adapters/native-subagent-dispatch.js.map +1 -1
  155. package/data/build/dist/host/cli-adapters/native-team-subagent.d.ts.map +1 -1
  156. package/data/build/dist/host/cli-adapters/native-team-subagent.js +2 -1
  157. package/data/build/dist/host/cli-adapters/native-team-subagent.js.map +1 -1
  158. package/data/build/dist/host/cli-adapters/pi-driver.js +1 -1
  159. package/data/build/dist/host/cli-adapters/pi-driver.js.map +1 -1
  160. package/data/build/dist/host/cli-adapters/registry.d.ts.map +1 -1
  161. package/data/build/dist/host/cli-adapters/registry.js +25 -16
  162. package/data/build/dist/host/cli-adapters/registry.js.map +1 -1
  163. package/data/build/dist/host/cli-adapters/zcode-driver.js +1 -1
  164. package/data/build/dist/host/cli-adapters/zcode-driver.js.map +1 -1
  165. package/data/build/dist/host/features/global-voice-rpc.d.ts.map +1 -1
  166. package/data/build/dist/host/features/global-voice-rpc.js +2 -3
  167. package/data/build/dist/host/features/global-voice-rpc.js.map +1 -1
  168. package/data/build/dist/host/features/interaction-translation.d.ts +9 -0
  169. package/data/build/dist/host/features/interaction-translation.d.ts.map +1 -0
  170. package/data/build/dist/host/features/interaction-translation.js +168 -0
  171. package/data/build/dist/host/features/interaction-translation.js.map +1 -0
  172. package/data/build/dist/host/features/peer-host.js +6 -6
  173. package/data/build/dist/host/features/peer-host.js.map +1 -1
  174. package/data/build/dist/host/features/session-prompt-translation.d.ts +10 -0
  175. package/data/build/dist/host/features/session-prompt-translation.d.ts.map +1 -0
  176. package/data/build/dist/host/features/session-prompt-translation.js +197 -0
  177. package/data/build/dist/host/features/session-prompt-translation.js.map +1 -0
  178. package/data/build/dist/host/features/session-translation-protection.d.ts +16 -0
  179. package/data/build/dist/host/features/session-translation-protection.d.ts.map +1 -0
  180. package/data/build/dist/host/features/session-translation-protection.js +183 -0
  181. package/data/build/dist/host/features/session-translation-protection.js.map +1 -0
  182. package/data/build/dist/host/features/session-translation-recovery.d.ts +20 -0
  183. package/data/build/dist/host/features/session-translation-recovery.d.ts.map +1 -0
  184. package/data/build/dist/host/features/session-translation-recovery.js +122 -0
  185. package/data/build/dist/host/features/session-translation-recovery.js.map +1 -0
  186. package/data/build/dist/host/features/session-translation-runtime.d.ts +16 -0
  187. package/data/build/dist/host/features/session-translation-runtime.d.ts.map +1 -0
  188. package/data/build/dist/host/features/session-translation-runtime.js +85 -0
  189. package/data/build/dist/host/features/session-translation-runtime.js.map +1 -0
  190. package/data/build/dist/host/features/session-translation-service.d.ts +14 -4
  191. package/data/build/dist/host/features/session-translation-service.d.ts.map +1 -1
  192. package/data/build/dist/host/features/session-translation-service.js +217 -211
  193. package/data/build/dist/host/features/session-translation-service.js.map +1 -1
  194. package/data/build/dist/host/features/session-translation.d.ts.map +1 -1
  195. package/data/build/dist/host/features/session-translation.js +5 -2
  196. package/data/build/dist/host/features/session-translation.js.map +1 -1
  197. package/data/build/dist/host/modules/peer-host/peer-host-native-dispatch.d.ts +2 -2
  198. package/data/build/dist/host/modules/peer-host/peer-host-native-dispatch.d.ts.map +1 -1
  199. package/data/build/dist/host/modules/peer-host/peer-host-native-dispatch.js +10 -9
  200. package/data/build/dist/host/modules/peer-host/peer-host-native-dispatch.js.map +1 -1
  201. package/data/build/dist/host/modules/peer-host/peer-host-native-streams.d.ts +3 -3
  202. package/data/build/dist/host/modules/peer-host/peer-host-native-streams.d.ts.map +1 -1
  203. package/data/build/dist/host/modules/peer-host/peer-host-native-streams.js +26 -14
  204. package/data/build/dist/host/modules/peer-host/peer-host-native-streams.js.map +1 -1
  205. package/data/build/dist/host/native-session-bridge.d.ts +2 -1
  206. package/data/build/dist/host/native-session-bridge.d.ts.map +1 -1
  207. package/data/build/dist/host/native-session-bridge.js +7 -15
  208. package/data/build/dist/host/native-session-bridge.js.map +1 -1
  209. package/data/build/dist/host/rpc.d.ts.map +1 -1
  210. package/data/build/dist/host/rpc.js +14 -8
  211. package/data/build/dist/host/rpc.js.map +1 -1
  212. package/data/build/dist/host/settings.d.ts.map +1 -1
  213. package/data/build/dist/host/settings.js +10 -2
  214. package/data/build/dist/host/settings.js.map +1 -1
  215. package/data/build/dist/shared/attachment-prompts.d.ts +11 -0
  216. package/data/build/dist/shared/attachment-prompts.d.ts.map +1 -0
  217. package/data/build/dist/shared/attachment-prompts.js +17 -0
  218. package/data/build/dist/shared/attachment-prompts.js.map +1 -0
  219. package/data/build/dist/shared/contracts/cli-adapter.d.ts +8 -1
  220. package/data/build/dist/shared/contracts/cli-adapter.d.ts.map +1 -1
  221. package/data/build/dist/shared/contracts/errors.d.ts +2 -2
  222. package/data/build/dist/shared/contracts/interaction-presentation.d.ts +32 -0
  223. package/data/build/dist/shared/contracts/interaction-presentation.d.ts.map +1 -0
  224. package/data/build/dist/shared/contracts/interaction-presentation.js +2 -0
  225. package/data/build/dist/shared/contracts/interaction-presentation.js.map +1 -0
  226. package/data/build/dist/shared/contracts/interaction-translation.d.ts +53 -0
  227. package/data/build/dist/shared/contracts/interaction-translation.d.ts.map +1 -0
  228. package/data/build/dist/shared/contracts/interaction-translation.js +44 -0
  229. package/data/build/dist/shared/contracts/interaction-translation.js.map +1 -0
  230. package/data/build/dist/shared/contracts/session-translation.d.ts +75 -7
  231. package/data/build/dist/shared/contracts/session-translation.d.ts.map +1 -1
  232. package/data/build/dist/shared/contracts/session-translation.js +132 -2
  233. package/data/build/dist/shared/contracts/session-translation.js.map +1 -1
  234. package/data/build/dist/shared/contracts/version.d.ts +4 -4
  235. package/data/build/dist/shared/contracts/version.js +3 -3
  236. package/data/build/dist/shared/index.d.ts +1 -1
  237. package/data/build/dist/shared/index.d.ts.map +1 -1
  238. package/data/build/dist/shared/index.js +1 -1
  239. package/data/build/dist/shared/index.js.map +1 -1
  240. package/data/build/dist/shared/translation-indicator.d.ts +26 -0
  241. package/data/build/dist/shared/translation-indicator.d.ts.map +1 -0
  242. package/data/build/dist/shared/translation-indicator.js +29 -0
  243. package/data/build/dist/shared/translation-indicator.js.map +1 -0
  244. package/package.json +35 -34
  245. package/profile/README.md +2 -2
  246. package/profile/package.json +3 -3
  247. package/profile/version.json +3 -3
  248. package/version.json +3 -3
@@ -8991,32 +8991,78 @@
8991
8991
  "cli.adapterDisabled": "{name} disabled",
8992
8992
  "cli.translationConversation": "Translate conversation",
8993
8993
  "cli.translationConversationToggle": "Toggle conversation translation",
8994
+ "cli.translationSettings": "Conversation translation settings",
8995
+ "cli.translationSettingsClose": "Close",
8996
+ "cli.translationSettingsDescription": "Choose which messages to translate in conversations with translation enabled.",
8997
+ "cli.translationUserMessages": "Translate user messages",
8998
+ "cli.translationThinkingMessages": "Translate AI thinking messages",
8999
+ "cli.translationAssistantMessages": "Translate AI final messages",
8994
9000
  "lan.fieldListenPort": "listen port",
8995
9001
  "lan.fieldDshPort": "DSH local port",
8996
9002
  "lan.fieldMustBeNumber": "{field} must be a number",
8997
9003
  "lan.fieldMustBeInteger": "{field} must be an integer from {minimum} to 65535",
8998
9004
  "workspace.sessionSettingsSaved": "Workspace session settings saved",
8999
9005
  "feature.sessionTranslation.label": "Session translation",
9000
- "feature.sessionTranslation.description": "Translate selected external Agent requests and replies while keeping tools, commands, paths, and original history unchanged.",
9006
+ "feature.sessionTranslation.description": "Translate selected external Agent requests and replies while keeping tools, commands, paths, and original history unchanged. Control DSH native session translation using the switch in the conversation model selector.",
9001
9007
  "translation.inputTitle": "Translate requests before sending",
9002
9008
  "translation.inputLanguage": "Request language",
9003
- "translation.outputTitle": "Translate visible replies",
9009
+ "translation.outputTitle": "Translate the AI’s reasoning and final messages into the language specified below",
9004
9010
  "translation.outputLanguage": "Reply language",
9005
- "translation.modelTitle": "Translation model",
9011
+ "translation.modelTitle": "Translation model pool",
9012
+ "translation.rulesTitle": "Translation rules",
9013
+ "translation.rulesHelp": "Rules apply to input, reasoning, and replies, including text already in the target language. They take priority over the default translation prompts.",
9014
+ "translation.rulesEmpty": "No custom rules. The default translation prompts apply.",
9015
+ "translation.ruleAdd": "Add rule",
9016
+ "translation.ruleEdit": "Edit rule {number}",
9017
+ "translation.ruleRemove": "Remove rule {number}",
9018
+ "translation.ruleText": "Rule instructions",
9019
+ "translation.rulePlaceholder": "For example: Keep product names in their original language.",
9020
+ "translation.ruleSave": "Save rule",
9021
+ "translation.ruleSaving": "Saving…",
9022
+ "translation.ruleCancel": "Cancel",
9006
9023
  "translation.modelFollowDefault": "Use the default DSH model",
9024
+ "translation.modelResetTitle": "Use the default DSH model?",
9025
+ "translation.modelResetHelp": "This will clear all {count} models and their priority order from the pool, then follow the default DSH model. Continue?",
9026
+ "translation.modelResetConfirm": "Clear pool and use default",
9007
9027
  "translation.modelUnavailable": "Saved model is unavailable",
9008
9028
  "translation.modelLoading": "Loading available DSH models…",
9009
9029
  "translation.modelEmpty": "No DSH text models are available.",
9010
- "translation.modelHelp": "DeepSeek official and configured third-party models are available here. Translation requests always disable thinking.",
9030
+ "translation.modelHelp": "Drag to set priority; the first model is tried first. If all models fail, the original text is kept.",
9031
+ "translation.modelDefaultActive": "No models selected; using the default DSH model.",
9032
+ "translation.modelPriority": "Priority {priority}",
9033
+ "translation.modelPoolCount": "{count} models · ordered by priority",
9034
+ "translation.modelPoolEmpty": "Add models to set up automatic fallback.",
9035
+ "translation.modelAdd": "Add models",
9036
+ "translation.modelRemove": "Remove {model}",
9037
+ "translation.modelDrag": "Reorder {model}",
9038
+ "translation.modelDragHelp": "Drag to reorder, or use the Up and Down arrow keys.",
9039
+ "translation.modelReordered": "{model} moved to priority {priority}",
9040
+ "translation.modelPickerTitle": "Add translation models",
9041
+ "translation.modelPickerHelp": "Select models to add to the end of the pool. Drag them to adjust priority after adding.",
9042
+ "translation.modelSearch": "Search models or providers",
9043
+ "translation.modelPickerCount": "{count} selected",
9044
+ "translation.modelAddSelected": "Add selected ({count})",
9045
+ "translation.modelCancel": "Cancel",
9046
+ "translation.modelNoMatches": "No matching models.",
9047
+ "translation.modelAllAdded": "All available models are already in the pool.",
9011
9048
  "translation.detailsTitle": "Translation details",
9012
9049
  "translation.viewDetails": "View translation details",
9013
9050
  "translation.statusTranslated": "Translated",
9051
+ "translation.statusTranslating": "Translating…",
9052
+ "translation.progressHelp": "Preparing and translating your message. The translation result will be available when this finishes.",
9014
9053
  "translation.statusFailed": "Translation failed; original kept",
9054
+ "translation.retry": "Retry translation",
9055
+ "translation.sendDirectly": "Send directly",
9056
+ "translation.cancelSending": "Cancel sending",
9057
+ "translation.inputFailedTitle": "Message translation failed",
9058
+ "translation.inputFailedHelp": "Your message has not been sent. Choose how to continue.",
9059
+ "translation.decisionFailed": "Could not apply your choice. Please try again.",
9015
9060
  "translation.statusNotNeeded": "Already in the target language; translation skipped",
9016
9061
  "translation.detectedLanguage": "Detected language",
9017
9062
  "translation.modelNotUsed": "Not used; translation was unnecessary",
9018
9063
  "translation.originalText": "Original text",
9019
- "translation.translatedText": "Translated / sent text",
9064
+ "translation.translatedText": "Translation",
9065
+ "translation.actualSentText": "Actual sent text:",
9020
9066
  "translation.modelUsed": "Model used",
9021
9067
  "translation.modelUnknown": "Model information unavailable",
9022
9068
  "translation.modelOfficial": "DeepSeek official",
@@ -9046,33 +9092,79 @@
9046
9092
  "cli.adapterDisabled": "已停用 {name}",
9047
9093
  "cli.translationConversation": "翻译对话",
9048
9094
  "cli.translationConversationToggle": "切换对话翻译",
9095
+ "cli.translationSettings": "对话翻译设置",
9096
+ "cli.translationSettingsClose": "关闭",
9097
+ "cli.translationSettingsDescription": "选择已开启对话翻译的会话中需要翻译的消息类型。",
9098
+ "cli.translationUserMessages": "翻译用户消息",
9099
+ "cli.translationThinkingMessages": "翻译 AI 思考消息",
9100
+ "cli.translationAssistantMessages": "翻译 AI 正式消息",
9049
9101
  "lan.fieldListenPort": "监听端口",
9050
9102
  "lan.fieldDshPort": "DSH 本地端口",
9051
9103
  "lan.fieldMustBeNumber": "{field} 必须是数字",
9052
9104
  "lan.fieldMustBeInteger": "{field} 必须是 {minimum} 到 65535 的整数",
9053
9105
  "workspace.sessionSettingsSaved": "工作区会话设置已保存",
9054
9106
  "feature.sessionTranslation.label": "会话翻译",
9055
- "feature.sessionTranslation.description": "为选定的外部 Agent 翻译请求和回复,同时保留工具、命令、路径与原始历史。",
9107
+ "feature.sessionTranslation.description": "为选定的外部 Agent 翻译请求和回复,同时保留工具、命令、路径与原始历史;DSH 原生会话翻译由对话框模型选择器中的会话翻译开关控制。",
9056
9108
  "translation.inputTitle": "发送前翻译请求",
9057
9109
  "translation.inputLanguage": "请求目标语言",
9058
- "translation.outputTitle": "翻译界面回复",
9110
+ "translation.outputTitle": "AI的思考内容和正式消息翻译为以下指定语言",
9059
9111
  "translation.outputLanguage": "回复语言",
9060
- "translation.modelTitle": "翻译模型",
9112
+ "translation.modelTitle": "翻译模型池",
9113
+ "translation.rulesTitle": "翻译规则",
9114
+ "translation.rulesHelp": "规则适用于输入、思考和回复,包括已经是目标语言的文本。规则的优先级高于默认翻译提示词。",
9115
+ "translation.rulesEmpty": "尚未添加自定义规则,使用默认翻译提示词。",
9116
+ "translation.ruleAdd": "添加规则",
9117
+ "translation.ruleEdit": "编辑规则 {number}",
9118
+ "translation.ruleRemove": "移除规则 {number}",
9119
+ "translation.ruleText": "规则内容",
9120
+ "translation.rulePlaceholder": "例如:产品名称保留原文,不进行翻译。",
9121
+ "translation.ruleSave": "保存规则",
9122
+ "translation.ruleSaving": "正在保存…",
9123
+ "translation.ruleCancel": "取消",
9061
9124
  "translation.modelFollowDefault": "跟随 DSH 默认模型",
9125
+ "translation.modelResetTitle": "确认跟随 DSH 默认模型?",
9126
+ "translation.modelResetHelp": "这将清空模型池中的全部 {count} 个模型及其优先级顺序,并改为跟随 DSH 默认模型。是否继续?",
9127
+ "translation.modelResetConfirm": "清空并跟随默认模型",
9062
9128
  "translation.modelUnavailable": "已保存的模型当前不可用",
9063
9129
  "translation.modelLoading": "正在加载可用的 DSH 模型…",
9064
9130
  "translation.modelEmpty": "当前没有可用的 DSH 文本模型。",
9065
- "translation.modelHelp": "这里可以选择 DeepSeek 官方模型或已配置的第三方模型;翻译请求始终关闭思考。",
9131
+ "translation.modelHelp": "拖拽调整优先级,优先使用列表首个模型;全部失败时保留原文。",
9132
+ "translation.modelDefaultActive": "未选择模型,当前跟随 DSH 默认模型。",
9133
+ "translation.modelPriority": "优先级 {priority}",
9134
+ "translation.modelPoolCount": "{count} 个模型 · 按优先级排列",
9135
+ "translation.modelPoolEmpty": "添加模型,配置自动回退顺序。",
9136
+ "translation.modelAdd": "添加模型",
9137
+ "translation.modelRemove": "移除 {model}",
9138
+ "translation.modelDrag": "调整 {model} 的顺序",
9139
+ "translation.modelDragHelp": "拖拽调整顺序,也可使用上下方向键。",
9140
+ "translation.modelReordered": "{model} 已移至优先级 {priority}",
9141
+ "translation.modelPickerTitle": "添加翻译模型",
9142
+ "translation.modelPickerHelp": "选择模型后添加到模型池末尾,添加后可拖拽调整优先级。",
9143
+ "translation.modelSearch": "搜索模型或供应商",
9144
+ "translation.modelPickerCount": "已选择 {count} 个",
9145
+ "translation.modelAddSelected": "添加所选({count})",
9146
+ "translation.modelCancel": "取消",
9147
+ "translation.modelNoMatches": "没有匹配的模型。",
9148
+ "translation.modelAllAdded": "所有可用模型均已添加到模型池。",
9066
9149
  "translation.detailsTitle": "翻译详情",
9067
9150
  "translation.viewDetails": "查看翻译详情",
9068
9151
  "translation.statusTranslated": "已翻译",
9152
+ "translation.statusTranslating": "正在翻译…",
9153
+ "translation.progressHelp": "正在准备并翻译消息,完成后可查看翻译结果。",
9069
9154
  "translation.statusFailed": "翻译失败,已保留原文",
9155
+ "translation.retry": "重试翻译",
9156
+ "translation.sendDirectly": "直接发送",
9157
+ "translation.cancelSending": "取消发送",
9158
+ "translation.inputFailedTitle": "消息翻译失败",
9159
+ "translation.inputFailedHelp": "消息尚未发送,请选择如何继续。",
9160
+ "translation.decisionFailed": "未能应用你的选择,请重试。",
9070
9161
  "translation.statusNotNeeded": "原文已是目标语言,无需翻译",
9071
9162
  "translation.detectedLanguage": "检测到的语言",
9072
9163
  "translation.modelNotUsed": "未调用,原文无需翻译",
9073
9164
  "translation.originalText": "原文",
9074
- "translation.translatedText": "译文 / 实际发送文本",
9075
- "translation.modelUsed": "实际翻译模型",
9165
+ "translation.translatedText": "译文",
9166
+ "translation.actualSentText": "实际发送文本:",
9167
+ "translation.modelUsed": "翻译模型",
9076
9168
  "translation.modelUnknown": "暂无模型信息",
9077
9169
  "translation.modelOfficial": "DeepSeek 官方",
9078
9170
  "translation.modelThirdParty": "第三方",
@@ -11556,84 +11648,77 @@
11556
11648
  return n;
11557
11649
  }
11558
11650
  //#endregion
11559
- //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.2_@deepseek-ai+cordis@4.0.4/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/TextShimmer.module.css
11651
+ //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.3_@deepseek-ai+cordis@4.0.5-alpha.2/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/TextShimmer.module.css
11560
11652
  var TextShimmer_module_default = {
11561
- "content": "bpvwYa_content",
11562
- "decoration": "bpvwYa_decoration",
11563
- "dsh-row-shimmer-highlight": "bpvwYa_dsh-row-shimmer-highlight",
11564
- "dsh-row-shimmer-sweep": "bpvwYa_dsh-row-shimmer-sweep",
11565
- "highlight": "bpvwYa_highlight",
11566
- "root": "bpvwYa_root",
11567
- "sweep": "bpvwYa_sweep",
11568
- "text": "bpvwYa_text"
11653
+ "content": "JPqLFa_content",
11654
+ "decoration": "JPqLFa_decoration",
11655
+ "dsh-row-shimmer-highlight": "JPqLFa_dsh-row-shimmer-highlight",
11656
+ "dsh-row-shimmer-sweep": "JPqLFa_dsh-row-shimmer-sweep",
11657
+ "highlight": "JPqLFa_highlight",
11658
+ "root": "JPqLFa_root",
11659
+ "sweep": "JPqLFa_sweep",
11660
+ "text": "JPqLFa_text"
11569
11661
  };
11570
11662
  //#endregion
11571
- //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.2_@deepseek-ai+cordis@4.0.4/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/DisclosureRow.module.css
11663
+ //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.3_@deepseek-ai+cordis@4.0.5-alpha.2/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/DisclosureRow.module.css
11572
11664
  var DisclosureRow_module_default = {
11573
- "chevronHover": "X4MG3q_chevronHover",
11574
- "header": "X4MG3q_header",
11575
- "iconIdle": "X4MG3q_iconIdle",
11576
- "leading": "X4MG3q_leading",
11577
- "root": "X4MG3q_root",
11578
- "row": "X4MG3q_row",
11579
- "title": "X4MG3q_title"
11665
+ "chevronHover": "HRTIjW_chevronHover",
11666
+ "header": "HRTIjW_header",
11667
+ "iconIdle": "HRTIjW_iconIdle",
11668
+ "leading": "HRTIjW_leading",
11669
+ "root": "HRTIjW_root",
11670
+ "row": "HRTIjW_row",
11671
+ "title": "HRTIjW_title"
11580
11672
  };
11581
11673
  //#endregion
11582
- //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.2_@deepseek-ai+cordis@4.0.4/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/Button.module.css
11674
+ //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.3_@deepseek-ai+cordis@4.0.5-alpha.2/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/Button.module.css
11583
11675
  var Button_module_default = {
11584
- "button": "OhWqWa_button",
11585
- "ghost": "OhWqWa_ghost",
11586
- "icon": "OhWqWa_icon",
11587
- "md": "OhWqWa_md",
11588
- "outline": "OhWqWa_outline",
11589
- "primary": "OhWqWa_primary",
11590
- "sm": "OhWqWa_sm",
11591
- "toolbar": "OhWqWa_toolbar"
11676
+ "button": "qwxocG_button",
11677
+ "ghost": "qwxocG_ghost",
11678
+ "icon": "qwxocG_icon",
11679
+ "md": "qwxocG_md",
11680
+ "outline": "qwxocG_outline",
11681
+ "primary": "qwxocG_primary",
11682
+ "sm": "qwxocG_sm",
11683
+ "toolbar": "qwxocG_toolbar"
11592
11684
  };
11593
11685
  //#endregion
11594
- //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.2_@deepseek-ai+cordis@4.0.4/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/Input.module.css
11686
+ //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.3_@deepseek-ai+cordis@4.0.5-alpha.2/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/Input.module.css
11595
11687
  var Input_module_default = {
11596
- "icon": "dUks_a_icon",
11597
- "input": "dUks_a_input",
11598
- "wrap": "dUks_a_wrap"
11688
+ "icon": "Z9tYSa_icon",
11689
+ "input": "Z9tYSa_input",
11690
+ "wrap": "Z9tYSa_wrap"
11599
11691
  };
11600
11692
  //#endregion
11601
- //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.2_@deepseek-ai+cordis@4.0.4/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/ShortcutKeys.module.css
11693
+ //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.3_@deepseek-ai+cordis@4.0.5-alpha.2/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/ShortcutKeys.module.css
11602
11694
  var import_react_dom = require_react_dom();
11603
11695
  var ShortcutKeys_module_default = {
11604
- "joined": "jNAsuq_joined",
11605
- "key": "jNAsuq_key",
11606
- "keys": "jNAsuq_keys",
11607
- "separator": "jNAsuq_separator",
11608
- "tooltip": "jNAsuq_tooltip"
11696
+ "joined": "QXraKa_joined",
11697
+ "key": "QXraKa_key",
11698
+ "keys": "QXraKa_keys",
11699
+ "separator": "QXraKa_separator",
11700
+ "tooltip": "QXraKa_tooltip"
11609
11701
  };
11610
11702
  //#endregion
11611
- //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.2_@deepseek-ai+cordis@4.0.4/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/MenuSurface.module.css
11703
+ //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.3_@deepseek-ai+cordis@4.0.5-alpha.2/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/MenuSurface.module.css
11612
11704
  var MenuSurface_module_default = {
11613
- "backing": "WqPUZG_backing",
11614
- "compact": "WqPUZG_compact",
11615
- "material": "WqPUZG_material",
11616
- "surface": "WqPUZG_surface"
11705
+ "backing": "UijD9G_backing",
11706
+ "compact": "UijD9G_compact",
11707
+ "material": "UijD9G_material",
11708
+ "surface": "UijD9G_surface"
11617
11709
  };
11618
11710
  //#endregion
11619
- //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.2_@deepseek-ai+cordis@4.0.4/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/Tooltip.module.css
11620
- var Tooltip_module_default = {
11621
- "bubble": "hMkNvq_bubble",
11622
- "label": "hMkNvq_label",
11623
- "tooltip-in": "hMkNvq_tooltip-in"
11624
- };
11625
- //#endregion
11626
- //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.2_@deepseek-ai+cordis@4.0.4/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/HoverCard.module.css
11711
+ //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.3_@deepseek-ai+cordis@4.0.5-alpha.2/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/HoverCard.module.css
11627
11712
  var HoverCard_module_default = {
11628
- "card": "oNH0AW_card",
11629
- "copied": "oNH0AW_copied",
11630
- "copyable": "oNH0AW_copyable",
11631
- "feedback": "oNH0AW_feedback",
11632
- "inline": "oNH0AW_inline",
11633
- "media": "oNH0AW_media",
11634
- "preview": "oNH0AW_preview",
11635
- "root": "oNH0AW_root",
11636
- "status": "oNH0AW_status"
11713
+ "card": "wtRhtW_card",
11714
+ "copied": "wtRhtW_copied",
11715
+ "copyable": "wtRhtW_copyable",
11716
+ "feedback": "wtRhtW_feedback",
11717
+ "inline": "wtRhtW_inline",
11718
+ "media": "wtRhtW_media",
11719
+ "preview": "wtRhtW_preview",
11720
+ "root": "wtRhtW_root",
11721
+ "status": "wtRhtW_status"
11637
11722
  };
11638
11723
  //#endregion
11639
11724
  //#region node_modules/.pnpm/simple-icons@16.31.0/node_modules/simple-icons/index.mjs
@@ -11997,19 +12082,26 @@
11997
12082
  hex: "0084FF"
11998
12083
  };
11999
12084
  //#endregion
12000
- //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.2_@deepseek-ai+cordis@4.0.4/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/markdown/MarkdownText.module.css
12085
+ //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.3_@deepseek-ai+cordis@4.0.5-alpha.2/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/markdown/MarkdownText.module.css
12001
12086
  var MarkdownText_module_default = {
12002
- "compact": "_9jVLZa_compact",
12003
- "fileLink": "_9jVLZa_fileLink",
12004
- "fileMention": "_9jVLZa_fileMention",
12005
- "image": "_9jVLZa_image",
12006
- "imageAlt": "_9jVLZa_imageAlt",
12007
- "imageButton": "_9jVLZa_imageButton",
12008
- "linkIcon": "_9jVLZa_linkIcon",
12009
- "markdown": "_9jVLZa_markdown",
12010
- "previewName": "_9jVLZa_previewName",
12011
- "tableFill": "_9jVLZa_tableFill",
12012
- "tableScroll": "_9jVLZa_tableScroll"
12087
+ "compact": "JW1tIq_compact",
12088
+ "fileLink": "JW1tIq_fileLink",
12089
+ "fileMention": "JW1tIq_fileMention",
12090
+ "image": "JW1tIq_image",
12091
+ "imageAlt": "JW1tIq_imageAlt",
12092
+ "imageButton": "JW1tIq_imageButton",
12093
+ "linkIcon": "JW1tIq_linkIcon",
12094
+ "markdown": "JW1tIq_markdown",
12095
+ "previewName": "JW1tIq_previewName",
12096
+ "tableFill": "JW1tIq_tableFill",
12097
+ "tableScroll": "JW1tIq_tableScroll"
12098
+ };
12099
+ //#endregion
12100
+ //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.3_@deepseek-ai+cordis@4.0.5-alpha.2/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/Tooltip.module.css
12101
+ var Tooltip_module_default = {
12102
+ "bubble": "PhTCOW_bubble",
12103
+ "label": "PhTCOW_label",
12104
+ "tooltip-in": "PhTCOW_tooltip-in"
12013
12105
  };
12014
12106
  //#endregion
12015
12107
  //#region node_modules/.pnpm/@shikijs+types@4.5.0/node_modules/@shikijs/types/dist/index.mjs
@@ -22568,7 +22660,7 @@ XID_Start XIDS`.split(/\s/).map((p) => [w(p), p]));
22568
22660
  json_default = [lang$72];
22569
22661
  }));
22570
22662
  //#endregion
22571
- //#region node_modules/.pnpm/@deepseek-ai+dsh-util-code-language@0.2.1-alpha.2_@deepseek-ai+cordis@4.0.4/node_modules/@deepseek-ai/dsh-util-code-language/lib/index.js
22663
+ //#region node_modules/.pnpm/@deepseek-ai+dsh-util-code-language@0.2.1-alpha.3_@deepseek-ai+cordis@4.0.5-alpha.2/node_modules/@deepseek-ai/dsh-util-code-language/lib/index.js
22572
22664
  init_typescript();
22573
22665
  init_shellscript();
22574
22666
  init_json();
@@ -23209,15 +23301,15 @@ XID_Start XIDS`.split(/\s/).map((p) => [w(p), p]));
23209
23301
  };
23210
23302
  })))();
23211
23303
  var CodeCard_module_default = {
23212
- "action": "dokyLW_action",
23213
- "actions": "dokyLW_actions",
23214
- "body": "dokyLW_body",
23215
- "card": "dokyLW_card",
23216
- "header": "dokyLW_header",
23217
- "heading": "dokyLW_heading",
23218
- "language": "dokyLW_language",
23219
- "status": "dokyLW_status",
23220
- "title": "dokyLW_title"
23304
+ "action": "YsOdSa_action",
23305
+ "actions": "YsOdSa_actions",
23306
+ "body": "YsOdSa_body",
23307
+ "card": "YsOdSa_card",
23308
+ "header": "YsOdSa_header",
23309
+ "heading": "YsOdSa_heading",
23310
+ "language": "YsOdSa_language",
23311
+ "status": "YsOdSa_status",
23312
+ "title": "YsOdSa_title"
23221
23313
  };
23222
23314
  //#endregion
23223
23315
  //#region node_modules/.pnpm/diff@9.0.0/node_modules/diff/libesm/diff/base.js
@@ -23734,17 +23826,17 @@ XID_Start XIDS`.split(/\s/).map((p) => [w(p), p]));
23734
23826
  };
23735
23827
  new ArrayDiff();
23736
23828
  //#endregion
23737
- //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.2_@deepseek-ai+cordis@4.0.4/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/DiffBlock.module.css
23829
+ //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.3_@deepseek-ai+cordis@4.0.5-alpha.2/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/DiffBlock.module.css
23738
23830
  var DiffBlock_module_default = {
23739
- "add": "MGM43W_add",
23740
- "block": "MGM43W_block",
23741
- "body": "MGM43W_body",
23742
- "context": "MGM43W_context",
23743
- "del": "MGM43W_del",
23744
- "expand": "MGM43W_expand",
23745
- "gap": "MGM43W_gap",
23746
- "line": "MGM43W_line",
23747
- "path": "MGM43W_path"
23831
+ "add": "L2QO-G_add",
23832
+ "block": "L2QO-G_block",
23833
+ "body": "L2QO-G_body",
23834
+ "context": "L2QO-G_context",
23835
+ "del": "L2QO-G_del",
23836
+ "expand": "L2QO-G_expand",
23837
+ "gap": "L2QO-G_gap",
23838
+ "line": "L2QO-G_line",
23839
+ "path": "L2QO-G_path"
23748
23840
  };
23749
23841
  //#endregion
23750
23842
  //#region node_modules/.pnpm/mdast-util-to-string@4.0.0/node_modules/mdast-util-to-string/lib/index.js
@@ -63470,35 +63562,35 @@ XID_Start XIDS`.split(/\s/).map((p) => [w(p), p]));
63470
63562
  chunkString: "chunkString"
63471
63563
  };
63472
63564
  //#endregion
63473
- //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.2_@deepseek-ai+cordis@4.0.4/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/markdown/CodeBlock.module.css
63565
+ //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.3_@deepseek-ai+cordis@4.0.5-alpha.2/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/markdown/CodeBlock.module.css
63474
63566
  var CodeBlock_module_default = {
63475
- "action": "v8s9Ea_action",
63476
- "banner": "v8s9Ea_banner",
63477
- "bannerWrap": "v8s9Ea_bannerWrap",
63478
- "block": "v8s9Ea_block",
63479
- "card": "v8s9Ea_card",
63480
- "content": "v8s9Ea_content",
63481
- "copyButton": "v8s9Ea_copyButton",
63482
- "infostring": "v8s9Ea_infostring",
63483
- "numbered": "v8s9Ea_numbered",
63484
- "plain": "v8s9Ea_plain",
63485
- "shiki": "v8s9Ea_shiki"
63567
+ "action": "DPs2Ha_action",
63568
+ "banner": "DPs2Ha_banner",
63569
+ "bannerWrap": "DPs2Ha_bannerWrap",
63570
+ "block": "DPs2Ha_block",
63571
+ "card": "DPs2Ha_card",
63572
+ "content": "DPs2Ha_content",
63573
+ "copyButton": "DPs2Ha_copyButton",
63574
+ "infostring": "DPs2Ha_infostring",
63575
+ "numbered": "DPs2Ha_numbered",
63576
+ "plain": "DPs2Ha_plain",
63577
+ "shiki": "DPs2Ha_shiki"
63486
63578
  };
63487
63579
  //#endregion
63488
- //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.2_@deepseek-ai+cordis@4.0.4/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/ImageLightbox.module.css
63580
+ //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.3_@deepseek-ai+cordis@4.0.5-alpha.2/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/ImageLightbox.module.css
63489
63581
  var ImageLightbox_module_default = {
63490
- "backdrop": "_9Z-wXG_backdrop",
63491
- "close": "_9Z-wXG_close",
63492
- "image": "_9Z-wXG_image",
63493
- "mask": "_9Z-wXG_mask",
63494
- "stage": "_9Z-wXG_stage"
63582
+ "backdrop": "D0cLTG_backdrop",
63583
+ "close": "D0cLTG_close",
63584
+ "image": "D0cLTG_image",
63585
+ "mask": "D0cLTG_mask",
63586
+ "stage": "D0cLTG_stage"
63495
63587
  };
63496
63588
  //#endregion
63497
- //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.2_@deepseek-ai+cordis@4.0.4/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/ImagePreview.module.css
63589
+ //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.3_@deepseek-ai+cordis@4.0.5-alpha.2/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/ImagePreview.module.css
63498
63590
  var ImagePreview_module_default = {
63499
- "frame": "o4symG_frame",
63500
- "image": "o4symG_image",
63501
- "status": "o4symG_status"
63591
+ "frame": "FtSukG_frame",
63592
+ "image": "FtSukG_image",
63593
+ "status": "FtSukG_status"
63502
63594
  };
63503
63595
  //#endregion
63504
63596
  //#region node_modules/.pnpm/@shikijs+langs@4.5.0/node_modules/@shikijs/langs/dist/python.mjs
@@ -64231,7 +64323,7 @@ XID_Start XIDS`.split(/\s/).map((p) => [w(p), p]));
64231
64323
  groovy_default = [lang];
64232
64324
  }));
64233
64325
  //#endregion
64234
- //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.2_@deepseek-ai+cordis@4.0.4/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/index.js
64326
+ //#region node_modules/.pnpm/@deepseek-ai+dsh-client-ui-primitives@0.2.1-alpha.3_@deepseek-ai+cordis@4.0.5-alpha.2/node_modules/@deepseek-ai/dsh-client-ui-primitives/lib/index.js
64235
64327
  init_typescript();
64236
64328
  init_shellscript();
64237
64329
  init_json();
@@ -64810,317 +64902,8 @@ XID_Start XIDS`.split(/\s/).map((p) => [w(p), p]));
64810
64902
  el.remove();
64811
64903
  }
64812
64904
  }
64813
- /**
64814
- * Document-wide input tracking shared by tooltips and focus-ring styles.
64815
- * Tooltips follow the last input; rings follow navigation or a key followed by
64816
- * focus on a different control. Modifiers and refocusing alone keep rings silent.
64817
- * Module-level listeners live for the document lifetime; Node imports are inert.
64818
- */
64819
- /** Modality values published on the document element. */
64820
- const INPUT_MODALITY = {
64821
- pointer: "pointer",
64822
- keyboard: "keyboard"
64823
- };
64824
- /** Attribute carrying whether focus navigation last owned focus. */
64825
- const INPUT_MODALITY_ATTRIBUTE = "data-input-modality";
64826
- const FOCUS_NAVIGATION = /* @__PURE__ */ new Set([
64827
- "Tab",
64828
- "Home",
64829
- "End",
64830
- "PageUp",
64831
- "PageDown"
64832
- ]);
64833
- let pointer = false;
64834
- let pointerOwnsFocus = false;
64835
- let keyFocusOrigin;
64836
- function publish() {
64837
- document.documentElement.setAttribute(INPUT_MODALITY_ATTRIBUTE, pointerOwnsFocus ? INPUT_MODALITY.pointer : INPUT_MODALITY.keyboard);
64838
- }
64839
- /**
64840
- * Whether the last input came from a pointer, independently of ring visibility.
64841
- * @returns True after pointer input; false after any key.
64842
- */
64843
- function pointerModality() {
64844
- return pointer;
64845
- }
64846
- if (typeof window !== "undefined") {
64847
- window.addEventListener("pointerdown", () => {
64848
- pointer = true;
64849
- pointerOwnsFocus = true;
64850
- keyFocusOrigin = void 0;
64851
- publish();
64852
- }, true);
64853
- window.addEventListener("keydown", (event) => {
64854
- pointer = false;
64855
- if (event.isComposing) {
64856
- keyFocusOrigin = void 0;
64857
- return;
64858
- }
64859
- keyFocusOrigin = event.composedPath()[0];
64860
- if (!FOCUS_NAVIGATION.has(event.key) && !event.key.startsWith("Arrow")) return;
64861
- pointerOwnsFocus = false;
64862
- publish();
64863
- }, true);
64864
- window.addEventListener("focusin", (event) => {
64865
- if (keyFocusOrigin === void 0 || event.composedPath()[0] === keyFocusOrigin) return;
64866
- keyFocusOrigin = void 0;
64867
- if (!pointerOwnsFocus) return;
64868
- pointerOwnsFocus = false;
64869
- publish();
64870
- }, true);
64871
- window.addEventListener("blur", () => {
64872
- keyFocusOrigin = void 0;
64873
- });
64874
- }
64875
- /** Anchor-preserving tooltips; an optional body portal escapes clipping containers and stacking contexts that cap the bubble's z-index. */
64876
- /**
64877
- * Suppression channel for enclosing tooltip and hover-card anchors: a visible
64878
- * tooltip within an anchor withdraws the enclosing preview while its bubble is shown.
64879
- */
64880
- const TooltipSuppression = (0, import_react.createContext)(null);
64881
- /**
64882
- * Attach a hover/focus tooltip to an anchor element.
64883
- * @param props.label - bubble text, or a resolver evaluated only while visible; an empty string shows only shortcut keys.
64884
- * @param props.shortcutKeys - effective key labels rendered as platform-formatted keycaps after optional text.
64885
- * @param props.side - placement relative to the anchor (default 'right').
64886
- * @param props.align - horizontal anchor-edge alignment for 'bottom'/'top' bubbles: 'end' pins
64887
- * the bubble's right edge to the anchor's (for anchors beside other hover surfaces the centered
64888
- * bubble would overlap); default 'center'. Ignored for side 'right'.
64889
- * @param props.portal - render the bubble under document.body, so an ancestor's clipping or its
64890
- * stacking context (which confines the bubble's z-index to that context) cannot hide it.
64891
- * @param props.delayMs - hover delay in milliseconds (default 0).
64892
- * @param props.focusDelayMs - keyboard focus delay in milliseconds (default 0); blur, click,
64893
- * mouse leave, disabling, and unmount cancel a pending show.
64894
- * @param props.gap - anchor-to-bubble distance in pixels for 'bottom'/'top' bubbles (default 8);
64895
- * ignored for side 'right'.
64896
- * @param props.disabled - suppress the bubble while true; the anchor renders identically so
64897
- * toggling never remounts it (which would cut its CSS transitions).
64898
- * @param props.maxWidth - bubble width cap in pixels, for labels long enough that the default
64899
- * half-viewport cap would render a slab wider than the surface the anchor sits on.
64900
- * @param props.openOnClick - clicking also pins the bubble for reading; another click, Escape,
64901
- * Tab, or an outside pointerdown dismisses it. Defaults to false for ordinary action tooltips.
64902
- * @param props.children - a single anchor element; its own ref (callback or object) is forwarded alongside the tooltip's.
64903
- * @returns the cloned anchor plus a fixed-position bubble, optionally portaled to the body.
64904
- * The bubble stays hidden until ResizeObserver supplies its size for viewport fitting; clicking the
64905
- * anchor dismisses the bubble unless openOnClick is enabled, and focus arriving after a pointer
64906
- * interaction (a closing menu refocusing its trigger) never raises it.
64907
- */
64908
- function Tooltip({ label, shortcutKeys, side = "right", align = "center", delayMs = 0, focusDelayMs = 0, gap = 8, disabled = false, portal = false, maxWidth, openOnClick = false, children }) {
64909
- const id = (0, import_react.useId)();
64910
- const [pinned, setPinned] = (0, import_react.useState)(false);
64911
- const anchor = (0, import_react.useRef)(null);
64912
- const childRef = children.ref;
64913
- const mergedRef = (0, import_react.useCallback)((el) => {
64914
- anchor.current = el;
64915
- if (typeof childRef === "function") childRef(el);
64916
- else if (childRef != null) childRef.current = el;
64917
- }, [childRef]);
64918
- const [pos, setPos] = (0, import_react.useState)(null);
64919
- const bubble = (0, import_react.useRef)(null);
64920
- const resolvedLabel = pos === null ? null : typeof label === "function" ? label() : label;
64921
- const y = pos === null ? 0 : side === "right" ? pos.top + (pos.bottom - pos.top) / 2 : side === "top" ? pos.top - gap : pos.bottom + gap;
64922
- const showTimer = (0, import_react.useRef)(null);
64923
- const triggers = (0, import_react.useRef)({
64924
- hover: false,
64925
- focus: false
64926
- });
64927
- const suppressAncestors = (0, import_react.useContext)(TooltipSuppression);
64928
- const [suppressed, setSuppressed] = (0, import_react.useState)(false);
64929
- const announce = (0, import_react.useCallback)((active) => {
64930
- suppressAncestors?.(active);
64931
- }, [suppressAncestors]);
64932
- const visible = pos !== null && !disabled;
64933
- (0, import_react.useEffect)(() => {
64934
- const el = bubble.current;
64935
- if (pos === null || !visible || suppressed || el === null) return;
64936
- const edgeMargin = 12;
64937
- let size;
64938
- let placement = side;
64939
- const fit = () => {
64940
- if (size === void 0) return;
64941
- const { inlineSize: width, blockSize: height } = size;
64942
- const offset = side === "right" ? 0 : align === "end" ? width : width / 2;
64943
- const left = Math.max(edgeMargin, Math.min(pos.x - offset, window.innerWidth - edgeMargin - width));
64944
- const fitsBelow = pos.bottom + gap + height <= window.innerHeight - edgeMargin;
64945
- const fitsAbove = pos.top - gap - height >= edgeMargin;
64946
- if (placement === "bottom" && !fitsBelow && fitsAbove) placement = "top";
64947
- else if (placement === "top" && !fitsAbove && fitsBelow) placement = "bottom";
64948
- el.style.left = `${left + offset}px`;
64949
- el.style.top = `${placement === "right" ? (pos.top + pos.bottom) / 2 : placement === "top" ? pos.top - gap : pos.bottom + gap}px`;
64950
- el.dataset.side = placement;
64951
- el.style.visibility = "visible";
64952
- };
64953
- const observer = new ResizeObserver((entries) => {
64954
- size = entries[0]?.borderBoxSize[0];
64955
- fit();
64956
- });
64957
- observer.observe(el, { box: "border-box" });
64958
- window.addEventListener("resize", fit);
64959
- return () => {
64960
- observer.disconnect();
64961
- window.removeEventListener("resize", fit);
64962
- };
64963
- }, [
64964
- align,
64965
- gap,
64966
- pos,
64967
- side,
64968
- suppressed,
64969
- visible
64970
- ]);
64971
- (0, import_react.useEffect)(() => {
64972
- announce(visible);
64973
- return () => {
64974
- announce(false);
64975
- };
64976
- }, [announce, visible]);
64977
- const cancelShow = (0, import_react.useCallback)(() => {
64978
- if (showTimer.current === null) return;
64979
- clearTimeout(showTimer.current);
64980
- showTimer.current = null;
64981
- }, []);
64982
- (0, import_react.useEffect)(() => {
64983
- if (pinned && (disabled || !openOnClick)) setPinned(false);
64984
- if (disabled) {
64985
- cancelShow();
64986
- triggers.current = {
64987
- hover: false,
64988
- focus: false
64989
- };
64990
- setPos(null);
64991
- }
64992
- return cancelShow;
64993
- }, [
64994
- cancelShow,
64995
- disabled,
64996
- openOnClick,
64997
- pinned
64998
- ]);
64999
- const show = () => {
65000
- if (disabled) return;
65001
- const el = anchor.current;
65002
- /* v8 ignore next -- the ref is attached by event time: events fire on the cloned anchor. */
65003
- if (el === null) return;
65004
- const r = el.getBoundingClientRect();
65005
- setPos({
65006
- x: side === "right" ? r.right + 10 : align === "end" ? r.right : r.left + r.width / 2,
65007
- top: r.top,
65008
- bottom: r.bottom
65009
- });
65010
- announce(true);
65011
- };
65012
- const showAfterDelay = (delay) => {
65013
- cancelShow();
65014
- if (delay <= 0) {
65015
- show();
65016
- return;
65017
- }
65018
- showTimer.current = setTimeout(() => {
65019
- showTimer.current = null;
65020
- show();
65021
- }, delay);
65022
- };
65023
- const withdraw = (0, import_react.useCallback)(() => {
65024
- setPinned(false);
65025
- setPos(null);
65026
- announce(false);
65027
- }, [announce]);
65028
- const hide = () => {
65029
- cancelShow();
65030
- if (!triggers.current.hover && !triggers.current.focus && !pinned) withdraw();
65031
- };
65032
- const dismiss = (0, import_react.useCallback)(() => {
65033
- cancelShow();
65034
- triggers.current = {
65035
- hover: false,
65036
- focus: false
65037
- };
65038
- withdraw();
65039
- }, [cancelShow, withdraw]);
65040
- useDismissOnOutsidePointer(anchor, openOnClick && visible, dismiss, bubble);
65041
- (0, import_react.useEffect)(() => {
65042
- if (!openOnClick || !visible) return;
65043
- const onKeyDown = (event) => {
65044
- if (event.key !== "Escape" && event.key !== "Tab") return;
65045
- if (event.key === "Escape") {
65046
- event.preventDefault();
65047
- event.stopPropagation();
65048
- }
65049
- dismiss();
65050
- };
65051
- document.addEventListener("keydown", onKeyDown, true);
65052
- return () => {
65053
- document.removeEventListener("keydown", onKeyDown, true);
65054
- };
65055
- }, [
65056
- dismiss,
65057
- openOnClick,
65058
- visible
65059
- ]);
65060
- const content = visible && !suppressed && (0, import_jsx_runtime.jsxs)("span", {
65061
- ref: bubble,
65062
- id: openOnClick ? id : void 0,
65063
- className: Tooltip_module_default.bubble,
65064
- "data-side": side,
65065
- "data-portal": portal || void 0,
65066
- "data-pinned": pinned || void 0,
65067
- "data-align": align,
65068
- "data-has-shortcut": shortcutKeys?.length ? true : void 0,
65069
- style: {
65070
- left: pos.x,
65071
- top: y,
65072
- visibility: "hidden",
65073
- ...maxWidth === void 0 ? {} : { maxWidth }
65074
- },
65075
- role: "tooltip",
65076
- "aria-label": shortcutKeys?.length ? [resolvedLabel, shortcutKeys.join(" ")].filter(Boolean).join(" ") : void 0,
65077
- children: [resolvedLabel && (0, import_jsx_runtime.jsx)("span", {
65078
- className: Tooltip_module_default.label,
65079
- children: resolvedLabel
65080
- }), shortcutKeys !== void 0 && shortcutKeys.length > 0 && (0, import_jsx_runtime.jsx)(ShortcutKeys, {
65081
- keys: shortcutKeys,
65082
- variant: "tooltip"
65083
- })]
65084
- });
65085
- return (0, import_jsx_runtime.jsxs)(TooltipSuppression.Provider, {
65086
- value: setSuppressed,
65087
- children: [(0, import_react.cloneElement)(children, {
65088
- ref: mergedRef,
65089
- "aria-describedby": openOnClick && visible ? [children.props["aria-describedby"], id].filter(Boolean).join(" ") : children.props["aria-describedby"],
65090
- onMouseEnter: (e) => {
65091
- children.props.onMouseEnter?.(e);
65092
- triggers.current.hover = true;
65093
- showAfterDelay(delayMs);
65094
- },
65095
- onMouseLeave: (e) => {
65096
- children.props.onMouseLeave?.(e);
65097
- triggers.current.hover = false;
65098
- cancelShow();
65099
- if (!pinned) withdraw();
65100
- },
65101
- onClick: (e) => {
65102
- children.props.onClick?.(e);
65103
- triggers.current.focus = false;
65104
- cancelShow();
65105
- if (openOnClick && !disabled && !pinned) {
65106
- setPinned(true);
65107
- show();
65108
- } else withdraw();
65109
- },
65110
- onFocus: (e) => {
65111
- children.props.onFocus?.(e);
65112
- if (pointerModality()) return;
65113
- triggers.current.focus = true;
65114
- showAfterDelay(focusDelayMs);
65115
- },
65116
- onBlur: (e) => {
65117
- children.props.onBlur?.(e);
65118
- triggers.current.focus = false;
65119
- hide();
65120
- }
65121
- }), portal ? content !== false && (0, import_react_dom.createPortal)(content, document.body) : content]
65122
- });
65123
- }
64905
+ /** Private coordination shared only by opted-in HoverCards inside one mounted group. */
64906
+ const HoverCardGroupContext = (0, import_react.createContext)(null);
65124
64907
  /** Preview opacity transition and retained lifetime during dismissal. */
65125
64908
  const PREVIEW_FADE_MS = 100;
65126
64909
  const PREVIEW_MAX_HEIGHT = 420;
@@ -65129,7 +64912,7 @@ XID_Start XIDS`.split(/\s/).map((p) => [w(p), p]));
65129
64912
  const ANCHOR_GAP = 8;
65130
64913
  const VIEWPORT_MARGIN = 8;
65131
64914
  /**
65132
- * Render an anchor with a hover-triggered preview card, hidden while a tooltip within the anchor is visible.
64915
+ * Render an anchor with a hover-triggered preview card independently of nested tooltips.
65133
64916
  * @param props.anchor - the hover target (rendered in place inside a wrapper span).
65134
64917
  * @param props.content - card content; the pointer may rest on it, so it is
65135
64918
  * readable and selectable, but it carries no dismissal affordance of its own.
@@ -65139,13 +64922,15 @@ XID_Start XIDS`.split(/\s/).map((p) => [w(p), p]));
65139
64922
  * @param props.widthAnchorRef - optional element whose width and horizontal position size the preview.
65140
64923
  * @param props.inline - keep the anchor in prose; show a contained preview on hover or keyboard focus.
65141
64924
  * @param props.disabled - suppress opening; turning true dismisses an open card.
64925
+ * @param props.grouped - share first-display dwell across the surrounding list and active portal.
64926
+ * Group replacement removes the previous card immediately, including a fading preview.
65142
64927
  * @param props.copyText - optional primary value copied by activation and
65143
64928
  * included in the card's accessible name.
65144
64929
  * @param props.copyLabel - localized accessible activation-label prefix.
65145
64930
  * @param props.copiedLabel - localized visible success label.
65146
64931
  * @returns anchor wrapper with the conditional portaled card.
65147
64932
  */
65148
- function HoverCard({ anchor, content, openDelayMs = 500, disabled = false, copyText, copyLabel, copiedLabel, variant = "compact", widthAnchorRef, inline = false }) {
64933
+ function HoverCard({ anchor, content, openDelayMs = 500, disabled = false, grouped = false, copyText, copyLabel, copiedLabel, variant = "compact", widthAnchorRef, inline = false }) {
65149
64934
  const rootRef = (0, import_react.useRef)(null);
65150
64935
  const cardRef = (0, import_react.useRef)(null);
65151
64936
  const timerRef = (0, import_react.useRef)(null);
@@ -65160,7 +64945,9 @@ XID_Start XIDS`.split(/\s/).map((p) => [w(p), p]));
65160
64945
  const [pos, setPos] = (0, import_react.useState)(null);
65161
64946
  const positioned = pos !== null;
65162
64947
  const [copied, setCopied] = (0, import_react.useState)(false);
65163
- const [suppressed, setSuppressed] = (0, import_react.useState)(false);
64948
+ const parentGroup = (0, import_react.useContext)(HoverCardGroupContext);
64949
+ const group = grouped ? parentGroup : null;
64950
+ const [groupOwner] = (0, import_react.useState)(() => Symbol("hover-card"));
65164
64951
  const clearCopied = (0, import_react.useCallback)(() => {
65165
64952
  if (copyTimerRef.current !== null) {
65166
64953
  clearTimeout(copyTimerRef.current);
@@ -65175,12 +64962,36 @@ XID_Start XIDS`.split(/\s/).map((p) => [w(p), p]));
65175
64962
  setPhase((current) => variant === "preview" && current !== "closed" ? "closing" : "closed");
65176
64963
  }, [clearCopied, variant]);
65177
64964
  const { arm: armClose, cancel: cancelClose } = usePointerGrace(close);
65178
- const clearTimer = () => {
64965
+ const clearTimer = (0, import_react.useCallback)(() => {
65179
64966
  if (timerRef.current !== null) {
65180
64967
  clearTimeout(timerRef.current);
65181
64968
  timerRef.current = null;
65182
64969
  }
65183
- };
64970
+ }, []);
64971
+ const dismissImmediately = (0, import_react.useCallback)(() => {
64972
+ clearTimer();
64973
+ cancelClose();
64974
+ copyEpochRef.current += 1;
64975
+ clearCopied();
64976
+ setPhase("closed");
64977
+ }, [
64978
+ clearTimer,
64979
+ cancelClose,
64980
+ clearCopied
64981
+ ]);
64982
+ const groupVisible = open && positioned;
64983
+ (0, import_react.useLayoutEffect)(() => {
64984
+ if (!groupVisible || group === null) return;
64985
+ group.shown(groupOwner, dismissImmediately, cardRef.current);
64986
+ return () => {
64987
+ group.release(groupOwner);
64988
+ };
64989
+ }, [
64990
+ group,
64991
+ groupOwner,
64992
+ groupVisible,
64993
+ dismissImmediately
64994
+ ]);
65184
64995
  (0, import_react.useEffect)(() => {
65185
64996
  if (!closing) return;
65186
64997
  const timer = setTimeout(() => {
@@ -65305,7 +65116,7 @@ XID_Start XIDS`.split(/\s/).map((p) => [w(p), p]));
65305
65116
  inline
65306
65117
  ]);
65307
65118
  (0, import_react.useLayoutEffect)(() => {
65308
- if (!open || pos === null || variant === "preview" || inline || suppressed) return;
65119
+ if (!open || pos === null || variant === "preview" || inline) return;
65309
65120
  /* v8 ignore next -- the card is mounted whenever pos is set, so the ref is attached here. */
65310
65121
  const h = cardRef.current?.offsetHeight ?? 0;
65311
65122
  if (pos.top + h > window.innerHeight - VIEWPORT_MARGIN) setPos({
@@ -65316,8 +65127,7 @@ XID_Start XIDS`.split(/\s/).map((p) => [w(p), p]));
65316
65127
  open,
65317
65128
  pos,
65318
65129
  variant,
65319
- inline,
65320
- suppressed
65130
+ inline
65321
65131
  ]);
65322
65132
  const copy = async (text) => {
65323
65133
  if (copied || copyingRef.current) return;
@@ -65339,7 +65149,7 @@ XID_Start XIDS`.split(/\s/).map((p) => [w(p), p]));
65339
65149
  cancelClose();
65340
65150
  close();
65341
65151
  };
65342
- const card = open && pos !== null && !suppressed && (0, import_jsx_runtime.jsx)("div", {
65152
+ const card = open && pos !== null && (0, import_jsx_runtime.jsx)("div", {
65343
65153
  ref: cardRef,
65344
65154
  className: clsx(HoverCard_module_default.card, variant === "preview" && HoverCard_module_default.preview, inline && HoverCard_module_default.media, copyable && HoverCard_module_default.copyable, copied && HoverCard_module_default.feedback),
65345
65155
  "data-closing": closing || void 0,
@@ -65393,7 +65203,8 @@ XID_Start XIDS`.split(/\s/).map((p) => [w(p), p]));
65393
65203
  return;
65394
65204
  }
65395
65205
  clearTimer();
65396
- timerRef.current = setTimeout(() => {
65206
+ if (group?.isWarm()) setPhase("open");
65207
+ else timerRef.current = setTimeout(() => {
65397
65208
  setPhase("open");
65398
65209
  }, openDelayMs);
65399
65210
  },
@@ -65404,11 +65215,8 @@ XID_Start XIDS`.split(/\s/).map((p) => [w(p), p]));
65404
65215
  onPointerDownCapture: dismissFromAnchor,
65405
65216
  onClickCapture: dismissFromAnchor,
65406
65217
  children: [
65407
- (0, import_jsx_runtime.jsx)(TooltipSuppression.Provider, {
65408
- value: setSuppressed,
65409
- children: anchor
65410
- }),
65411
- open && !suppressed && copyable && (0, import_jsx_runtime.jsx)("span", {
65218
+ anchor,
65219
+ open && copyable && (0, import_jsx_runtime.jsx)("span", {
65412
65220
  className: HoverCard_module_default.status,
65413
65221
  role: "status",
65414
65222
  children: copied ? copiedLabel : ""
@@ -66113,6 +65921,317 @@ XID_Start XIDS`.split(/\s/).map((p) => [w(p), p]));
66113
65921
  });
66114
65922
  }
66115
65923
  /**
65924
+ * Document-wide input tracking shared by tooltips and focus-ring styles.
65925
+ * Tooltips follow the last input; rings follow navigation or a key followed by
65926
+ * focus on a different control. Modifiers and refocusing alone keep rings silent.
65927
+ * Module-level listeners live for the document lifetime; Node imports are inert.
65928
+ */
65929
+ /** Modality values published on the document element. */
65930
+ const INPUT_MODALITY = {
65931
+ pointer: "pointer",
65932
+ keyboard: "keyboard"
65933
+ };
65934
+ /** Attribute carrying whether focus navigation last owned focus. */
65935
+ const INPUT_MODALITY_ATTRIBUTE = "data-input-modality";
65936
+ const FOCUS_NAVIGATION = /* @__PURE__ */ new Set([
65937
+ "Tab",
65938
+ "Home",
65939
+ "End",
65940
+ "PageUp",
65941
+ "PageDown"
65942
+ ]);
65943
+ let pointer = false;
65944
+ let pointerOwnsFocus = false;
65945
+ let keyFocusOrigin;
65946
+ function publish() {
65947
+ document.documentElement.setAttribute(INPUT_MODALITY_ATTRIBUTE, pointerOwnsFocus ? INPUT_MODALITY.pointer : INPUT_MODALITY.keyboard);
65948
+ }
65949
+ /**
65950
+ * Whether the last input came from a pointer, independently of ring visibility.
65951
+ * @returns True after pointer input; false after any key.
65952
+ */
65953
+ function pointerModality() {
65954
+ return pointer;
65955
+ }
65956
+ if (typeof window !== "undefined") {
65957
+ window.addEventListener("pointerdown", () => {
65958
+ pointer = true;
65959
+ pointerOwnsFocus = true;
65960
+ keyFocusOrigin = void 0;
65961
+ publish();
65962
+ }, true);
65963
+ window.addEventListener("keydown", (event) => {
65964
+ pointer = false;
65965
+ if (event.isComposing) {
65966
+ keyFocusOrigin = void 0;
65967
+ return;
65968
+ }
65969
+ keyFocusOrigin = event.composedPath()[0];
65970
+ if (!FOCUS_NAVIGATION.has(event.key) && !event.key.startsWith("Arrow")) return;
65971
+ pointerOwnsFocus = false;
65972
+ publish();
65973
+ }, true);
65974
+ window.addEventListener("focusin", (event) => {
65975
+ if (keyFocusOrigin === void 0 || event.composedPath()[0] === keyFocusOrigin) return;
65976
+ keyFocusOrigin = void 0;
65977
+ if (!pointerOwnsFocus) return;
65978
+ pointerOwnsFocus = false;
65979
+ publish();
65980
+ }, true);
65981
+ window.addEventListener("blur", () => {
65982
+ keyFocusOrigin = void 0;
65983
+ });
65984
+ }
65985
+ /** Anchor-preserving tooltips; an optional body portal escapes clipping containers and stacking contexts that cap the bubble's z-index. */
65986
+ /**
65987
+ * Suppression channel for nested tooltips: a visible descendant tooltip
65988
+ * withdraws the enclosing tooltip while its bubble is shown.
65989
+ */
65990
+ const TooltipSuppression = (0, import_react.createContext)(null);
65991
+ /**
65992
+ * Attach a hover/focus tooltip to an anchor element.
65993
+ * @param props.label - bubble text, or a resolver evaluated only while visible; an empty string shows only shortcut keys.
65994
+ * @param props.shortcutKeys - effective key labels rendered as platform-formatted keycaps after optional text.
65995
+ * @param props.side - placement relative to the anchor (default 'right').
65996
+ * @param props.align - horizontal anchor-edge alignment for 'bottom'/'top' bubbles: 'end' pins
65997
+ * the bubble's right edge to the anchor's (for anchors beside other hover surfaces the centered
65998
+ * bubble would overlap); default 'center'. Ignored for side 'right'.
65999
+ * @param props.portal - render the bubble under document.body, so an ancestor's clipping or its
66000
+ * stacking context (which confines the bubble's z-index to that context) cannot hide it.
66001
+ * @param props.delayMs - hover delay in milliseconds (default 0).
66002
+ * @param props.focusDelayMs - keyboard focus delay in milliseconds (default 0); blur, click,
66003
+ * mouse leave, disabling, and unmount cancel a pending show.
66004
+ * @param props.gap - anchor-to-bubble distance in pixels for 'bottom'/'top' bubbles (default 8);
66005
+ * ignored for side 'right'.
66006
+ * @param props.disabled - suppress the bubble while true; the anchor renders identically so
66007
+ * toggling never remounts it (which would cut its CSS transitions).
66008
+ * @param props.maxWidth - bubble width cap in pixels, for labels long enough that the default
66009
+ * half-viewport cap would render a slab wider than the surface the anchor sits on.
66010
+ * @param props.openOnClick - clicking also pins the bubble for reading; another click, Escape,
66011
+ * Tab, or an outside pointerdown dismisses it. Defaults to false for ordinary action tooltips.
66012
+ * @param props.children - a single anchor element; its own ref (callback or object) is forwarded alongside the tooltip's.
66013
+ * @returns the cloned anchor plus a fixed-position bubble, optionally portaled to the body.
66014
+ * The bubble stays hidden until ResizeObserver supplies its size for viewport fitting; clicking the
66015
+ * anchor dismisses the bubble unless openOnClick is enabled, and focus arriving after a pointer
66016
+ * interaction (a closing menu refocusing its trigger) never raises it.
66017
+ */
66018
+ function Tooltip({ label, shortcutKeys, side = "right", align = "center", delayMs = 0, focusDelayMs = 0, gap = 8, disabled = false, portal = false, maxWidth, openOnClick = false, children }) {
66019
+ const id = (0, import_react.useId)();
66020
+ const [pinned, setPinned] = (0, import_react.useState)(false);
66021
+ const anchor = (0, import_react.useRef)(null);
66022
+ const childRef = children.ref;
66023
+ const mergedRef = (0, import_react.useCallback)((el) => {
66024
+ anchor.current = el;
66025
+ if (typeof childRef === "function") childRef(el);
66026
+ else if (childRef != null) childRef.current = el;
66027
+ }, [childRef]);
66028
+ const [pos, setPos] = (0, import_react.useState)(null);
66029
+ const bubble = (0, import_react.useRef)(null);
66030
+ const resolvedLabel = pos === null ? null : typeof label === "function" ? label() : label;
66031
+ const y = pos === null ? 0 : side === "right" ? pos.top + (pos.bottom - pos.top) / 2 : side === "top" ? pos.top - gap : pos.bottom + gap;
66032
+ const showTimer = (0, import_react.useRef)(null);
66033
+ const triggers = (0, import_react.useRef)({
66034
+ hover: false,
66035
+ focus: false
66036
+ });
66037
+ const suppressAncestors = (0, import_react.useContext)(TooltipSuppression);
66038
+ const [suppressed, setSuppressed] = (0, import_react.useState)(false);
66039
+ const announce = (0, import_react.useCallback)((active) => {
66040
+ suppressAncestors?.(active);
66041
+ }, [suppressAncestors]);
66042
+ const visible = pos !== null && !disabled;
66043
+ (0, import_react.useEffect)(() => {
66044
+ const el = bubble.current;
66045
+ if (pos === null || !visible || suppressed || el === null) return;
66046
+ const edgeMargin = 12;
66047
+ let size;
66048
+ let placement = side;
66049
+ const fit = () => {
66050
+ if (size === void 0) return;
66051
+ const { inlineSize: width, blockSize: height } = size;
66052
+ const offset = side === "right" ? 0 : align === "end" ? width : width / 2;
66053
+ const left = Math.max(edgeMargin, Math.min(pos.x - offset, window.innerWidth - edgeMargin - width));
66054
+ const fitsBelow = pos.bottom + gap + height <= window.innerHeight - edgeMargin;
66055
+ const fitsAbove = pos.top - gap - height >= edgeMargin;
66056
+ if (placement === "bottom" && !fitsBelow && fitsAbove) placement = "top";
66057
+ else if (placement === "top" && !fitsAbove && fitsBelow) placement = "bottom";
66058
+ el.style.left = `${left + offset}px`;
66059
+ el.style.top = `${placement === "right" ? (pos.top + pos.bottom) / 2 : placement === "top" ? pos.top - gap : pos.bottom + gap}px`;
66060
+ el.dataset.side = placement;
66061
+ el.style.visibility = "visible";
66062
+ };
66063
+ const observer = new ResizeObserver((entries) => {
66064
+ size = entries[0]?.borderBoxSize[0];
66065
+ fit();
66066
+ });
66067
+ observer.observe(el, { box: "border-box" });
66068
+ window.addEventListener("resize", fit);
66069
+ return () => {
66070
+ observer.disconnect();
66071
+ window.removeEventListener("resize", fit);
66072
+ };
66073
+ }, [
66074
+ align,
66075
+ gap,
66076
+ pos,
66077
+ side,
66078
+ suppressed,
66079
+ visible
66080
+ ]);
66081
+ (0, import_react.useEffect)(() => {
66082
+ announce(visible);
66083
+ return () => {
66084
+ announce(false);
66085
+ };
66086
+ }, [announce, visible]);
66087
+ const cancelShow = (0, import_react.useCallback)(() => {
66088
+ if (showTimer.current === null) return;
66089
+ clearTimeout(showTimer.current);
66090
+ showTimer.current = null;
66091
+ }, []);
66092
+ (0, import_react.useEffect)(() => {
66093
+ if (pinned && (disabled || !openOnClick)) setPinned(false);
66094
+ if (disabled) {
66095
+ cancelShow();
66096
+ triggers.current = {
66097
+ hover: false,
66098
+ focus: false
66099
+ };
66100
+ setPos(null);
66101
+ }
66102
+ return cancelShow;
66103
+ }, [
66104
+ cancelShow,
66105
+ disabled,
66106
+ openOnClick,
66107
+ pinned
66108
+ ]);
66109
+ const show = () => {
66110
+ if (disabled) return;
66111
+ const el = anchor.current;
66112
+ /* v8 ignore next -- the ref is attached by event time: events fire on the cloned anchor. */
66113
+ if (el === null) return;
66114
+ const r = el.getBoundingClientRect();
66115
+ setPos({
66116
+ x: side === "right" ? r.right + 10 : align === "end" ? r.right : r.left + r.width / 2,
66117
+ top: r.top,
66118
+ bottom: r.bottom
66119
+ });
66120
+ announce(true);
66121
+ };
66122
+ const showAfterDelay = (delay) => {
66123
+ cancelShow();
66124
+ if (delay <= 0) {
66125
+ show();
66126
+ return;
66127
+ }
66128
+ showTimer.current = setTimeout(() => {
66129
+ showTimer.current = null;
66130
+ show();
66131
+ }, delay);
66132
+ };
66133
+ const withdraw = (0, import_react.useCallback)(() => {
66134
+ setPinned(false);
66135
+ setPos(null);
66136
+ announce(false);
66137
+ }, [announce]);
66138
+ const hide = () => {
66139
+ cancelShow();
66140
+ if (!triggers.current.hover && !triggers.current.focus && !pinned) withdraw();
66141
+ };
66142
+ const dismiss = (0, import_react.useCallback)(() => {
66143
+ cancelShow();
66144
+ triggers.current = {
66145
+ hover: false,
66146
+ focus: false
66147
+ };
66148
+ withdraw();
66149
+ }, [cancelShow, withdraw]);
66150
+ useDismissOnOutsidePointer(anchor, openOnClick && visible, dismiss, bubble);
66151
+ (0, import_react.useEffect)(() => {
66152
+ if (!openOnClick || !visible) return;
66153
+ const onKeyDown = (event) => {
66154
+ if (event.key !== "Escape" && event.key !== "Tab") return;
66155
+ if (event.key === "Escape") {
66156
+ event.preventDefault();
66157
+ event.stopPropagation();
66158
+ }
66159
+ dismiss();
66160
+ };
66161
+ document.addEventListener("keydown", onKeyDown, true);
66162
+ return () => {
66163
+ document.removeEventListener("keydown", onKeyDown, true);
66164
+ };
66165
+ }, [
66166
+ dismiss,
66167
+ openOnClick,
66168
+ visible
66169
+ ]);
66170
+ const content = visible && !suppressed && (0, import_jsx_runtime.jsxs)("span", {
66171
+ ref: bubble,
66172
+ id: openOnClick ? id : void 0,
66173
+ className: Tooltip_module_default.bubble,
66174
+ "data-side": side,
66175
+ "data-portal": portal || void 0,
66176
+ "data-pinned": pinned || void 0,
66177
+ "data-align": align,
66178
+ "data-has-shortcut": shortcutKeys?.length ? true : void 0,
66179
+ style: {
66180
+ left: pos.x,
66181
+ top: y,
66182
+ visibility: "hidden",
66183
+ ...maxWidth === void 0 ? {} : { maxWidth }
66184
+ },
66185
+ role: "tooltip",
66186
+ "aria-label": shortcutKeys?.length ? [resolvedLabel, shortcutKeys.join(" ")].filter(Boolean).join(" ") : void 0,
66187
+ children: [resolvedLabel && (0, import_jsx_runtime.jsx)("span", {
66188
+ className: Tooltip_module_default.label,
66189
+ children: resolvedLabel
66190
+ }), shortcutKeys !== void 0 && shortcutKeys.length > 0 && (0, import_jsx_runtime.jsx)(ShortcutKeys, {
66191
+ keys: shortcutKeys,
66192
+ variant: "tooltip"
66193
+ })]
66194
+ });
66195
+ return (0, import_jsx_runtime.jsxs)(TooltipSuppression.Provider, {
66196
+ value: setSuppressed,
66197
+ children: [(0, import_react.cloneElement)(children, {
66198
+ ref: mergedRef,
66199
+ "aria-describedby": openOnClick && visible ? [children.props["aria-describedby"], id].filter(Boolean).join(" ") : children.props["aria-describedby"],
66200
+ onMouseEnter: (e) => {
66201
+ children.props.onMouseEnter?.(e);
66202
+ triggers.current.hover = true;
66203
+ showAfterDelay(delayMs);
66204
+ },
66205
+ onMouseLeave: (e) => {
66206
+ children.props.onMouseLeave?.(e);
66207
+ triggers.current.hover = false;
66208
+ cancelShow();
66209
+ if (!pinned) withdraw();
66210
+ },
66211
+ onClick: (e) => {
66212
+ children.props.onClick?.(e);
66213
+ triggers.current.focus = false;
66214
+ cancelShow();
66215
+ if (openOnClick && !disabled && !pinned) {
66216
+ setPinned(true);
66217
+ show();
66218
+ } else withdraw();
66219
+ },
66220
+ onFocus: (e) => {
66221
+ children.props.onFocus?.(e);
66222
+ if (pointerModality()) return;
66223
+ triggers.current.focus = true;
66224
+ showAfterDelay(focusDelayMs);
66225
+ },
66226
+ onBlur: (e) => {
66227
+ children.props.onBlur?.(e);
66228
+ triggers.current.focus = false;
66229
+ hide();
66230
+ }
66231
+ }), portal ? content !== false && (0, import_react_dom.createPortal)(content, document.body) : content]
66232
+ });
66233
+ }
66234
+ /**
66116
66235
  * The client's ONE syntax highlighter: a synchronous fine-grained shiki core
66117
66236
  * (JavaScript regex engine — no oniguruma WASM, bundle-friendly) with an
66118
66237
  * explicit grammar allowlist and a CSS-variables theme. Colors live in the