Compare commits

...
Author SHA1 Message Date
陈大猫 9a49ac33bf feat(sftp): add default download folder setting (#4353) (#4392) 2026-11-25 22:18:12 +08:00
陈大猫 da162f050b perf(electron): eliminate O(N^2) shift in SessionOutputBuffer and quadratic slicing in collapseCarriageReturns (#4397) 2026-11-25 22:09:02 +08:00
陈大猫 834ca122c4 refactor(domain): unify duplicated renderer TS and Electron CJS modules via domain/*.shared.cjs (#4394) 2026-11-25 22:04:43 +08:00
陈大猫 ac885e2a36 perf(ai): replace full @streamdown/code bundle with fine-grained shiki/core highlighter (#4390)
* perf(ai): replace full @streamdown/code bundle with fine-grained shiki/core highlighter

* fix(deps): preserve peer dependencies in package-lock.json
2026-11-25 22:04:36 +08:00
陈大猫 fea4e1eda0 build(packaging): prune unused node_modules/dev payloads from app.asar and move @remote-dom/core to devDependencies (#4388)
* build(packaging): prune unused node_modules/dev payloads from app.asar and move @remote-dom/core to devDependencies

* fix(build): keep explicit !electron/plugins/fixtures/**/* exclusion for packaging boundary test
2026-11-25 22:04:29 +08:00
陈大猫 cb87b71603 fix(electron): clean up OpenCode list servers, file watchers, SOCKS5 listener, worker SFTP encodings, and async MCP discovery heal (#4403) 2026-11-25 22:04:16 +08:00
陈大猫 b1de01546f refactor(electron): consolidate duplicated main and terminal-worker CJS helpers (#4389) 2026-11-25 22:04:08 +08:00
陈大猫 d5acb4641e refactor(domain): deduplicate ZIP builder, snippet shortkey recorder, hex-to-HSL math, and shell tokenizer (#4398) 2026-11-25 22:04:01 +08:00
陈大猫 60841628d6 perf(theme): respect fingerprint short-circuit in useActiveChromeTheme on same-theme tab switches (#4366)
* perf(theme): respect fingerprint short-circuit in useActiveChromeTheme on same-theme tab switches

* fix(theme): track UI palette and accent changes for chrome surface refresh
2026-11-25 22:03:54 +08:00
陈大猫 99197b3e18 perf(plugins): replace 50ms hostDom polling interval with event/property-driven sync and memoize PluginRemoteSurface (#4402)
* perf(plugins): replace 50ms hostDom polling interval with event/property-driven sync and memoize PluginRemoteSurface

* fix(plugin-sdk): order structural mutations before control flushes and cover native control mutators
2026-11-25 22:03:45 +08:00
陈大猫 d052a8597c refactor(state): compose useAISettingsState in useAIState and extract shared SSH credential/preflight builders (#4401) 2026-11-25 22:03:38 +08:00
陈大猫 d4f819b885 refactor(vault): consolidate shared SSH credential picker, algorithm overrides, and serial port discovery (#4400) 2026-11-25 22:03:30 +08:00
陈大猫 8930270820 perf(plugins): arm TerminalSelectionAuthority expiry timer lazily only while handles or dialogs are active (#4399) 2026-11-25 22:03:23 +08:00
陈大猫 5789b28014 refactor(ai): consolidate duplicated subprocess, line-buffer, and stream utilities across AI SDK drivers (#4396)
* refactor(ai): consolidate duplicated subprocess, line-buffer, and stream utilities across AI SDK drivers

* test(ai): keep event loop referenced during collectBoundedStdout abort grace test
2026-11-25 22:03:16 +08:00
陈大猫 8c66f8786d refactor(electron): unify interactive SSH IPC prompt lifecycle into ipcPromptRegistry (#4395) 2026-11-25 22:03:09 +08:00
陈大猫 29be836550 perf(bundle): code-split re2js, css-tree/remote-dom, and Monaco out of startup index chunk (#4391) 2026-11-25 22:03:02 +08:00
陈大猫 703148c84f perf(terminal): eliminate O(N^2) output history shift, idle timestamp sorting, and redundant keyword regex scans (#4382)
* perf(terminal): eliminate O(N^2) output history shift, idle timestamp sorting, and redundant keyword regex scans

* fix(terminal): invalidate timestamp gutter viewport key on parsed writes
2026-11-25 22:02:55 +08:00
陈大猫 5b33d410f9 perf(ai): batch reasoning-delta and raw reasoning stream updates via requestAnimationFrame (#4378) 2026-11-25 22:02:49 +08:00
陈大猫 c27a40e5f0 perf(ui): eliminate HostTreeSidebar 60fps ResizeObserver layout thrash and stop hidden activeHostId rerenders (#4375) 2026-11-25 22:02:42 +08:00
陈大猫 30f9a91576 perf(renderer): pause background polling timers when hidden or idle and remove dead CloudSync auto-sync timer (#4372) 2026-11-25 22:02:35 +08:00
陈大猫 6461acb575 perf(terminal): gate redundant WebGL atlas wipes and recovery refits on window focus (#4371) 2026-11-25 22:02:27 +08:00
陈大猫 2347f33bc8 perf(electron): fix trayPanelRefreshTimer leak and make sessionLogStreamManager flush timer on-demand (#4370) 2026-11-25 22:02:21 +08:00
陈大猫 22e6b02ce2 perf(assets): convert Nerd Font symbols to WOFF2 and drop unused @fontsource .woff fallbacks (#4387) 2026-11-25 21:56:35 +08:00
陈大猫 58bc929a17 refactor(ui): extract shared VaultHostCard and InlineRenameInput components (#4393) 2026-11-25 21:56:29 +08:00
陈大猫 7e94183b89 fix(sftp): prevent drag listener/body-style/selection leaks and avoid full transfer list cloning on progress (#4383) 2026-11-25 21:53:05 +08:00
陈大猫 b8d05b3074 test: remove 2 verbatim duplicate test cases and rename env-gated SCP real tests to *.live.test.cjs (#4386) 2026-11-25 21:40:20 +08:00
陈大猫 e99ab5a8eb build(monaco): skip unused Monaco NLS locale bundles in copy-monaco.cjs (#4385) 2026-11-25 21:40:13 +08:00
陈大猫 9a2d6ef7bf test: remove 2 dead test helpers and 3 obsolete/superseded plugin UI PoC tests (#4384) 2026-11-25 21:40:06 +08:00
陈大猫 27a6f2e7a6 test: remove 3 legacy barrel test files duplicating 366 CI test executions (#4381) 2026-11-25 21:39:59 +08:00
陈大猫 c52ca5f730 perf(plugins): short-circuit PluginTerminalProviderRegistry cloning and IPC when plugin host is disabled (#4380) 2026-11-25 21:39:51 +08:00
陈大猫 0aeb1df039 fix(editor): replace leaking Monaco editor.addCommand with disposable editor.addAction (#4379) 2026-11-25 21:39:44 +08:00
陈大猫 b8f3577cd8 perf(ai): bound TraceStore/SessionStateStore with LRU ring buffer and clean consumed TwoPassCompactionCache entries (#4377) 2026-11-25 21:39:38 +08:00
陈大猫 412f6c4ec6 perf(ai): defer backup JSON.stringify in writeSessionsForStorage and fix mirror no-op guard (#4376) 2026-11-25 21:39:31 +08:00
陈大猫 32b1b633db fix(electron): prevent session log stream and SSH decoder leaks on explicit session close (#4374) 2026-11-25 21:39:24 +08:00
陈大猫 e2b0f83ea9 fix(ai): detach global window listeners and mark completion when aiMarkdownWarmup fires (#4373) 2026-11-25 21:39:17 +08:00
陈大猫 4d7906a710 perf(ui): coalesce AsidePanel and VaultViewLayout resize with rAF and avoid split-panel width reflow (#4369) 2026-11-25 21:39:09 +08:00
陈大猫 9c14e3934f perf(plugins): prevent plugin contribution reload and DOM observer teardown on tab switch (#4368) 2026-11-25 21:39:02 +08:00
陈大猫 59db998ec4 perf(ui): narrow unscoped useActiveTabId subscriptions on tab switch (#4367) 2026-11-25 21:38:54 +08:00
陈大猫 78c7d30648 perf(sftp): eliminate inline toggle callback and narrow SFTP pane active/focus subscriptions (#4365) 2026-11-25 21:38:47 +08:00
陈大猫 4c3f0ce80b perf(terminal): decouple plugin sidebar subscriptions and gate closed side-panel reflows (#4364) 2026-11-25 21:38:40 +08:00
陈大猫 fd732dff9c perf(terminal): stabilize theme panel callbacks and memoize SidePanelBrowserSlot (#4362) 2026-11-25 21:38:33 +08:00
陈大猫 93bec7497c fix(ui): unify custom tooltips and keep Custom CSS docs in help modal (#4360) 2026-11-25 20:08:02 +08:00
陈大猫 fa9b28adde fix(terminal): handle Ctrl+Insert copy without clearing selection or leaking Win32 input (#4357)
* fix(terminal): handle Ctrl+Insert copy without clearing selection or leaking Win32 input (#4351)

* fix(terminal): suppress paired Ctrl+Insert keyup in native Kitty mode and set Windows UA in test

* test(terminal): override navigator.userAgent via Object.defineProperty in JSDOM fixture
2026-11-25 19:35:45 +08:00
陈大猫 0eefb9ea46 fix(mcp): recognize Powerline U+E0B0-U+E0B7 idle prompt endings (#4359) 2026-11-25 19:18:40 +08:00
陈大猫 ed90d61014 fix(terminal): cap ligature joiner span to avoid WebGL 16384px overflow atlas spike (#4063) (#4358) 2026-11-25 19:02:59 +08:00
GOUKI9999 d066f1f082 fix(tabs): honor disabled double-click on workspace tabs (#4355) 2026-11-25 17:34:32 +08:00
陈大猫 b64c36fd40 feat(ui): inline compose directory picker and streamline AI session history UX (#4356)
* feat(ui): inline compose directory picker and streamline AI session history UX

* fix(ai): exclude workspace members and hidden terminals from active-elsewhere jump targets

* fix(ai): clear non-AI magnification overlay when jumping to an active chat tab
2026-11-25 17:29:32 +08:00
Joseph Hau 403c690061 feat(terminal): support Directory Picker in Windows CMD (#4343)
* feat(terminal): support Directory Picker in Windows CMD

* fix: show CMD-specific directory integration status
2026-11-25 15:52:30 +08:00
Radwan Selo a4805b3e3d feat(capabilities): add terminal_execute_bulk to run one command on many sessions (#4342)
* feat(capabilities): add terminal_execute_bulk to run one command on many sessions

Add a terminal_execute_bulk MCP tool that runs the same short command on
2-20 open terminal sessions and groups identical results.

- All-or-nothing preflight: scope, closing, busy, connected, transport
  and the per-shell command safety policy are checked for every target
  before anything is sent. Any bad target cancels the whole call and all
  bad targets are reported at once.
- One approval listing every host. Remembered grants and external-client
  session approval never satisfy it (policy.requiresFreshApproval), and a
  pending fan-out is not swept up by another request's session approval.
- Targets are claimed before the prompt and re-checked after it; all
  targets then start in the same synchronous turn under a single per-chat
  exec lock, each with its own wall-clock timeout.
- Results are grouped only when status, exit code, stdout, stderr and
  error are identical on the full output, then truncated (tailLines and
  size caps). JSON output matches the other tools.
- Loaded on demand through the terminal_bulk toolset.

* fix(capabilities): harden terminal_execute_bulk after review

- Only trust the metadata "connected" flag for worker-hosted sessions; a
  live main-process session with a stale snapshot is no longer refused.
- Keep targets protected from idle auto-close from the claim through the
  approval wait to completion, and release on every path.
- Classify blocklist refusals before status keywords so a pattern such as
  "cancel-job" is reported as not_sent, not cancelled.
- List the terminal_bulk toolset in the MCP server instructions and the
  netcatty-mcp skill so clients can discover it.
- Test that the bulk RPC gets the same timeout budget as terminal_execute.

* fix(capabilities): validate worker sessions up front and cancel them at the deadline

An independent review found that the default (terminal worker) sessions
could receive a partial send, and that the backstop deadline never
reached the worker.

- Add a no-send precheck mode to the worker exec handler. The bulk
  preflight now runs every deterministic check for worker sessions
  (transport, shell kind, shell-specific safety patterns, unsupported
  local shell, busy job) so a refusal cancels the whole call before any
  host receives the command.
- Add netcatty:ai:exec:cancel and call it at the deadline, so a stuck
  worker command is cancelled before the per-chat lock is released
  instead of overlapping the next command. Background jobs are left
  alone.
- Make the deadline grace 3s and give the bulk RPC extra timeout budget
  for its preflight, so the backstop fires before the client gives up.
- Do not group hosts whose exec layer already dropped different amounts
  of output, and share one size budget between stdout and stderr.
- Restrict the capability to the sidebar agent; the global agent runs
  delegated, which bulk refuses.
- Document that live terminal readiness is a send-time state.

* test(capabilities): cover terminal_execute_bulk over the real MCP wire and close mutation gaps

- Drive the tool through the real stdio MCP server: hidden until the
  terminal_bulk toolset is loaded, schema shape, JSON result, Error text
  with isError, schema rejection of a native array, and privacy masking
  of the grouped result with token restoration in the command.
- Mutation testing (18 deliberate breakages of the safety-critical
  lines) left three survivors; add tests that kill two of them: hosts
  differing only in exit code, status, stderr or error never share a
  group, and a session-scoped answer to a fan-out approval does not
  approve later writes from that client.
- Assert that delegated agents cannot reach the fan-out at the gate.

* fix(capabilities): address review findings on terminal_execute_bulk

- Keep the tool MCP-only for now. The in-app agent has no completed-write
  replay for it after a context-compaction retry, and its SDK approval
  gate would stack a second prompt on the bridge's fresh approval. Both
  can follow in a separate change.
- Re-run the transport preflight for every claimed target after the
  approval and before the synchronous start, so a worker session that
  changed while the user was deciding cancels the whole call instead of
  being refused after other hosts have started.
- Never group hosts whose exec layer already dropped part of the output:
  equal retained tails do not prove equal full results.

* fix(capabilities): only report not_sent on explicit evidence and flag capped output

- Classify a host as not_sent only when the exec layer says so (a known
  pre-send code or refusal text). An error with no output and no exit
  code, such as a terminal worker exiting after it typed the command,
  is now reported as error, so a mutating command is never presented as
  safe to retry blindly. SHELL_NOT_READY and EXECUTION_NOT_AUTHORIZED
  are now recognised, so a call where every host refuses fails as
  not sent instead of returning ok.
- Have execViaRawPty and execViaChannel set outputTruncated when they
  stop collecting at their size cap, so hosts that differ only in the
  discarded output are never grouped.

* test(capabilities): run terminal_execute_bulk against the real worker exec handler

Wire the bridge to the production terminal-worker exec handler with fake
shells that speak the wrapper protocol, and cover the grouped result,
Stop while every host is running, and real per-host timeouts.

* fix(capabilities): do not probe hosts before the bulk approval

In confirm mode the preflight ran the shell-kind probe, which opens an
SSH exec channel and runs a remote command, before the approval prompt.
Denying the call (or another target failing) still executed something on
the host, and on an account with a forced command that could trigger it.

- The preflight before the prompt is now read-only: no channel is opened,
  and the safety check uses the shell kind only if it is already known,
  otherwise the shell-independent patterns.
- The full check, including the probe and the shell-aware patterns, runs
  right after approval and before any command is sent, so the call is
  still all-or-nothing. Without a prompt the full check runs first.
- The worker precheck honours the same distinction.

* fix(capabilities): recheck local guards before probing hosts after approval

After the approval the bulk call ran the probing transport pass first and
rechecked cancellation, scope and the privacy policy afterwards. A call
that was no longer authorized (Stop pressed, session out of scope,
privacy settings changed while the prompt was open) was rejected only
after the hosts had already been probed.

Run the local, read-only guards first, then the probing pass, then the
guards again because the pass awaits, and only then take the chat lock
and start. A refusal by the privacy hook now happens before the lock is
taken.

* fix(capabilities): re-read the permission mode and classify exec refusals precisely

- Re-evaluate the live permission mode with the other local guards, both
  before the probing pass and again before the start. Switching to
  observer while a prompt is open (or while hosts are being checked) now
  refuses the call, and a call that needed no approval is refused if the
  mode turns into confirm before it starts.
- Keep the code of an error the exec layer throws, so SHELL_PROMPT_PENDING
  (thrown before anything is written) is reported as not_sent and an
  all-refused call fails as not sent.
- Recognise the executors' real closed-stream messages ("Stream closed
  unexpectedly", "Serial port closed unexpectedly") as connection_lost.
2026-11-25 15:45:53 +08:00
陈大猫 5a1352aab0 feat(sftp): insert file path or cd into paired terminal from SFTP context menu (#4323)
* feat(sftp): insert file path or cd into paired terminal from SFTP context menu

* fix(sftp): guard terminal path insertion against unclosed quote contexts

* fix(sftp): reject trailing dollar fusion and after-cursor command text

* fix(terminal): detect standard root-directory shell prompts (user@host:/$) for SFTP path injection

* fix(sftp): reject arithmetic insertion contexts and continuation-prompt cd

* fix(terminal): ignore right-aligned prompt decorations in after-cursor readiness check

* fix(sftp): resolve remote shell dialect from prompt/OS and use portable Unix quoting

* fix(terminal): require unwritten xterm gap cells before ignoring right-prompt decorations
2026-11-25 12:02:41 +08:00
陈大猫 a9cf94aeba feat(sftp): add back and forward directory history navigation (#4324)
* feat(sftp): add back and forward directory history navigation

* fix(sftp): preserve pending nav history transition on mid-flight refresh
2026-11-25 11:26:13 +08:00
陈大猫 196132621c feat(ai): make tool call output truncation limit configurable in AI settings (#4328) 2026-11-25 11:25:00 +08:00
陈大猫 0098f2e670 feat(terminal): keep compose bar right-click isolated and allow reordering pinned snippets (#4327) 2026-11-25 11:22:00 +08:00
陈大猫 730c8cad59 feat(portforward): use capped exponential backoff instead of giving up after 15s (#4322) 2026-11-25 11:20:42 +08:00
陈大猫 d9cb9a8fbc feat(tabs): reopen recently closed terminal tabs and workspaces with Cmd/Ctrl+Shift+T (#4325)
* feat(tabs): reopen recently closed terminal tabs and workspaces with Cmd/Ctrl+Shift+T

* test(tabs): drain activeTabStore notification timer before closing jsdom

* fix(tabs): exclude ephemeral hosts from closed tab reopen history
2026-11-25 11:18:18 +08:00
陈大猫 bbbcf72b81 feat(tabs): focus adjacent terminal tab on close instead of jumping to Vaults or SFTP (#4320)
* feat(tabs): focus adjacent terminal tab on close instead of jumping to Vaults or SFTP

* test(tabs): reset activeTabStore before tearing down JSDOM globals
2026-11-25 10:48:00 +08:00
陈大猫 10ad09fe34 feat(sftp): skip auto-opening SFTP side panel for network devices (#4321) 2026-11-25 10:44:22 +08:00
陈大猫 040aec53b2 feat(ai): tint user message bubbles with theme accent for clearer turn separation (#4317)
* feat(ai): tint user message bubbles with theme accent for clearer turn separation

* fix(css): wrap global border-color reset in @layer base so user bubble border-primary utilities apply
2026-11-25 10:37:12 +08:00
陈大猫 2bf8611919 feat(local-terminal): support optional startup command on local terminal hosts (#4326)
* feat(local-terminal): support optional startup command on local terminal hosts

* fix(local-terminal): validate saved local launch target before overlaying startup command
2026-11-25 10:26:36 +08:00
陈大猫 1d53af5a51 feat(ui): improve selected protocol contrast in new connection form (#4319) 2026-11-25 10:07:40 +08:00
陈大猫 3c3319eead feat(i18n): default UI language to system locale on first launch (#4318) 2026-11-25 10:03:10 +08:00
陈大猫 50dbb5cb5f fix: prefill saved password on SSH auth retry after MFA failure (#4350)
Fixes #4346

Prefill the saved host password in the SSH credential retry dialog after a target authentication failure, instead of clearing the field.

Linux Electron smoke PASS on 20b0ad946b:
/workspace/netcatty-smoke-shots/pr-4350-20b0ad946-20261125-095752
GitHub Codex CLEAN; CI 45524469003 green.
2026-11-25 10:01:44 +08:00
陈大猫 462c2adb2a fix: preserve occupied groups during Smart Merge (#4344)
Fixes #4344

Preserve occupied host groups (and their saved defaults) after Smart Merge when a null baseline meets remote tombstones for a moved group.

Linux Electron smoke PASS on 184c783d19:
/workspace/netcatty-smoke-shots/pr-4349-184c783d-20261124-194948
GitHub Codex CLEAN; CI 45386915778 green.
2026-11-24 19:58:38 +08:00
陈大猫 610da46a6f fix: distinguish closing tabs from session panes (#4336) (#4339) 2026-11-24 14:53:22 +08:00
陈大猫andCodex 30e9609b1b fix(terminal): preserve pane geometry through zoom and restore (#4337)
* fix(terminal): preserve pane geometry through zoom and restore

* fix(terminal): resolve percentage pane restore geometry

* fix(terminal): resolve percentage pane zoom-entry geometry

---------

Co-authored-by: Codex <codex@openai.com>
2026-11-24 14:08:32 +08:00
jinshenganyuciandbincxz 6527d5596f feat(sftp): stream packed downloads and restore folders locally (#4179)
* feat(sftp): stream packed downloads and restore selected folders locally

* fix(sftp): address packed download lifecycle and cleanup review

* fix(sftp): preserve live packed state across window reload and fall back on POSIX special child names

* fix(sftp): guard active-packed snapshot replay race and fall back on selected root symlinks

* fix(sftp): fall back before nested-link containment check for selected root symlinks

---------

Co-authored-by: bincxz <16399091+binaricat@users.noreply.github.com>
2026-11-24 10:52:54 +08:00
GOUKI9999andbincxz a791d0b8c4 feat(terminal): configure SSH reconnect interval from 5 to 3600 seconds (#4039)
* feat(terminal): make SSH reconnect interval configurable

* fix(terminal): read latest reconnect settings via ref on session exit

* fix(terminal): pause connection timeout while waiting for auto-reconnect

---------

Co-authored-by: bincxz <16399091+binaricat@users.noreply.github.com>
2026-11-24 10:52:25 +08:00
KenX049andbincxz bcce829294 feat(tabs): move a tab to its own window without reconnecting (#4202)
* feat(tabs): move a tab to its own window without reconnecting (#4201)

Adds "Move Tab to New Window" to the tab context menu. Instead of opening
a new connection like "Copy Tab to New Window", the tab is hidden from the
tab bar and an attach popup takes over the same live PTY, so bastion
sessions are not re-authenticated and no extra seat is used. Closing the
popup returns the tab (with its screen state) to the window it came from.

- popup lifecycle notifies the home window via terminal-popup:attach-closed
- new runtime poppedOut flag; popped-out tabs still persist for restore and
  are not labelled as AI silent sessions in the tray

* fix(tabs): keep moved tabs alive when their source window closes

- A moved-tab popup registers as the lifetime heir of its session. If the
  source window is destroyed, ownership passes to the popup instead of the
  session being closed (worker and in-process paths). AI observe popups are
  unchanged.
- If the source window is gone when the popup closes, skip the hand-back so
  the popup's ownership closes the session.
- Only offer/allow Move Tab to New Window for connected sessions; attach
  mode cannot connect or reconnect a backend.

* fix(tabs): expose Move Tab to New Window through TerminalHost

The handler was registered but not passed into the terminal domain bag,
so AppView received undefined and the menu item never rendered.

* fix(tabs): address move-to-window focus, crash ownership, live count, history, and AI context review findings

* fix(tabs): activate moved-tab lifetime heir only after output rebind succeeds

* fix(tabs): wait for popup attachment before hiding tab and exclude plugin sessions

* fix(tabs): confirm renderer reattach before resolving move and await output restore before unhiding tab

* fix(tabs): preserve detached output across popup crashes and avoid focusing main window from tray

* fix(tabs): deliver attach snapshots and output restore directly to peer session windows

* fix(tabs): schedule automatic output restore retries when popup recovery fails

* fix(tabs): handle reopen replay preservation, stale restore cancellation, startup workspace move, and shutdown log capture

* fix(tabs): reassert popped-out state after tray reopen

* test(terminal): provide log finalizer stubs in popup snapshot harness

---------

Co-authored-by: bincxz <16399091+binaricat@users.noreply.github.com>
2026-11-24 10:50:36 +08:00
6cdf6b836b feat(terminal): show live jump hosts and fix AI prompt readiness (#4316)
* feat(terminal): extract hostnames from shell prompts

* fix(ai): accept decorated two-line shell prompts

* feat(tabs): add prompt-host title presentation

* feat(session): track prompt-host transitions

* feat(terminal): publish live prompt hostnames to tabs

* fix(session): include prompt host action in publisher runtime

* fix(ai): accept redrawn JumpServer shell prompts

* fix(tabs): prefer live prompt host behind user labels

* build(windows): normalize cross-built native modules

* fix(build): avoid config lint global shadowing

* fix(session): constrain live prompt hostname parsing

* fix(tabs): refresh workspace labels from live prompt hosts

* build(windows): validate cross-built native payloads

* fix(session): cover strict zsh and jump host prompts

* test(tabs): type live workspace prompt fixtures

* build(windows): scan packed native modules safely

* build(windows): add explicit cross-build script

* build(windows): make cross packaging self-contained

* fix(terminal): address review findings on JumpServer prompts and Windows cross-pack

* fix(windows): preserve child-process detection in cross-built packages

* fix(windows): require patched conpty.node during cross-packaging

---------

Co-authored-by: zjio26 <zjao2026@outlook.com>
Co-authored-by: bincxz <16399091+binaricat@users.noreply.github.com>
2026-11-24 10:50:25 +08:00
182531d7a7 feat(terminal): support Directory Picker in Windows PowerShell (#4177)
* feat(terminal): support Directory Picker in Windows PowerShell

* fix(terminal): handle qualified PowerShell paths and CI fixtures

* test(plugins): await dialog focus restoration in log settings

* test(terminal): normalize Windows fixture paths with native realpath

* fix(terminal): retry stale listings and recognize spaced UNC shares

---------

Co-authored-by: Cursor Agent <cursoragent@cursor.com>
Co-authored-by: bincxz <16399091+binaricat@users.noreply.github.com>
2026-11-24 10:50:14 +08:00
GOUKI9999andbincxz abd074fe95 fix(ai): refresh stale runtime model catalogs on use (#4263)
* fix(ai): refresh stale runtime model catalogs on use

* fix(ai): check model catalog freshness on picker open

* fix(ai): preserve saved rows on current-only stale catalog revalidation

* fix(ai): skip Cursor CLI probes on cacheOnly and warm model catalog checks

* fix(ai): keep cacheOnly model hydration non-blocking and restart-safe

* fix(ai): persist exact alias keys for cacheOnly hydration and reconcile warnings

* fix(ai): add backward-compatible pre-alias v1 catalog resolution for cacheOnly

* fix(ai): track alias migration per entry and consult Cursor alias before probing

* fix(ai): resolve pre-alias catalogs asynchronously by exact binary and allow missing CLI on cacheOnly

* fix(ai): preserve saved models for missing CLI and persist joined aliases after load

* fix(ai): reuse saved alias when bare CLI disappears from PATH

* fix(ai): alias env-configured CLI paths and adopt valid model on picker revalidation

* fix(ai): reprobe moved Cursor CLI on stale revalidation instead of pinning stale alias

* fix(ai): preserve PATH fallback when env-configured CLI path is invalid

---------

Co-authored-by: bincxz <16399091+binaricat@users.noreply.github.com>
2026-11-24 10:50:03 +08:00
陈大猫andCodex fedab5ec3b fix(settings): draw a border on frameless settings windows (#4333)
* fix(settings): draw a border on frameless settings windows

* chore: retrigger CI after unrelated compressUploadBridge flake

---------

Co-authored-by: Codex <codex@openai.com>
2026-11-23 21:47:09 +08:00
陈大猫andCodex ad612aeb0c fix(hotkeys): let Linux Alt+M pane zoom reach the renderer (#4331)
Fixes #4329

Co-authored-by: Codex <codex@openai.com>
2026-11-23 20:49:18 +08:00
rnaranyandClaude Code 2ddb6f2bee feat(autocomplete): localize batch-4 descriptions and select Fig specs per target OS (#4180)
* feat(autocomplete): add zh-CN descriptions for small-gap utilities

Localize the remaining Fig descriptions of 22 general-purpose commands that
had 15 or fewer untranslated keys: echo, which, paste, pwd, clear, su,
crontab, env, uname, base64, date, id, split, seq, join, dig, dd, htop,
basename, dirname, readlink, and more.

- Add 159 unique zh-CN entries (160 per-command entries; basename and
  dirname share one key) and regenerate zh-TW from them.
- Preload the new specs and extend the untranslated-description audit and
  its preload assertions.
- Add batch 4 coverage, semantics, insertion-text and zh-TW terminology
  tests plus the batch research note.
- Keep upstream wording quirks documented instead of hidden: dig labels NS
  as "Query MX Record", readlink reuses stat wording, and date/su/env follow
  the BSD/macOS flags their specs actually expose.

* fix(autocomplete): align uname and dd wording with GNU output

Review the batch 4 commands against jaywcjlove/linux-command (MIT), which
Netcatty's Linux-centric sessions match better than the bundled Fig wording.

- uname -s/-r/-v now say kernel name/release/version: GNU uname prints the
  kernel, not the distribution, and macOS reports Darwin through the same
  options.
- dd cbs states the conversion record is counted in bytes.
- Document which specs in this batch expose BSD/macOS-only options (date, su,
  id, base64, split, seq, env, more, which) so their descriptions are not
  rewritten into GNU wording that the inserted option does not have, and note
  dd's upstream `files` operand artifact.

No key was added or removed; zh-TW is regenerated from zh-CN.

* feat(autocomplete): ship a GNU date spec for Linux-first completion

The bundled Fig date spec follows BSD/macOS flags (-j, -n, -t, -v, epoch
seconds for -r), so Linux hosts were offered options that do not exist there.
Local specs already override the bundled package, so add electron/specs/date.js
with the GNU option set: -d/--date, --debug, -f/--file, -I/--iso-8601,
-R/--rfc-email, --rfc-3339, -r/--reference, -s/--set, -u/--utc, plus the
+FORMAT operand.

- Translate the 13 new descriptions; zh-TW is regenerated from them.
- Remove the 13 BSD-only date entries after a repository-wide scan showed no
  other spec references them.
- Resolve local specs first in the batch 4 test, matching runtime and the
  untranslated-description audit, and spot-check the new GNU wording.

* fix(autocomplete): correct GNU wording and add local specs

Follow-up review of batch 4 found wording that would show up in the popup and
two upstream spec defects. Local specs already override @withfig/autocomplete,
so the wrong option sets are replaced rather than translated around.

- Add electron/specs/{dig,readlink,base64,htop}.js:
  dig fixes the NS label and drops the bogus TTL type; readlink replaces the
  stat wording with the real GNU options; base64 moves from BSD -b/-i/-o to
  GNU -w and --ignore-garbage; htop documents the -H delay in seconds.
- Correct awk -c (traditional mode) and -t (--lint-old) to match gawk, with
  the dictionary keys migrated alongside -n.
- Reword review findings: htop -H highlights exited processes, split -a uses
  characters and -b uses KiB/MiB/GiB, dd cbs is a conversion record length,
  join -a/-v name the file index and -o covers unpaired lines, basename -a
  accepts multiple paths, env -0 ends records with NUL, dig ANY notes RFC 8482,
  su -f/-m keep the BSD behavior without hardcoded environment claims, and
  uname uses one verb for the kernel fields.
- Extend the zh-TW generator with documented post-conversion fixes (number
  bases, extended, instance, header, TLS extension, data) and regenerate.
- Update the batch 2 and batch 4 research notes, and resolve local specs first
  in the batch 4 test so it exercises what the app loads.

* test(autocomplete): cover all preloaded specs and Apple extension term

- Assert every one of the 22 batch-4 commands in COMMON_FIG_SPECS; the old
  loop only covered 7, so dropping a preload entry could pass unnoticed.
- Keep the noun “extension” as 擴充功能: the generic 擴充套件→擴充 rule is
  right for “extended” compounds (擴充屬性, 擴充標頭, 擴充正規表示式), but
  Apple's option descriptions need the noun form.

* fix(autocomplete): choose Fig specs by target OS and correct GNU semantics

- Resolve date, base64 and readlink against the target session's OS: macOS
  keeps its BSD specs while Linux keeps the local GNU ones. The renderer now
  passes the OS over the Fig bridge, and spec contents, in-flight loads, the
  available-name list and the loaded-name index are all scoped by command and
  OS, so one renderer can serve Linux and macOS sessions without mixing them.
- Add native macOS date and readlink specs (date gains -z, readlink exposes
  only -f/-n) and keep the bundled date/base64 specs as the macOS fallback.
  The bridge spec list merges specs/macos only for macOS sessions, so a
  platform-only command is never suggested where it cannot load.
- Fix GNU readlink: -q/--quiet/-s/--silent suppress error messages, -v/--verbose
  reports them, and the nonexistent --strip is gone. Restore filepath
  completion for base64 operands and date -f/-r, and cover date -r with numeric
  prefixes so digit-leading filenames stay discoverable.
- Complete values attached to optional option arguments (-Is -> -Iseconds,
  --iso-8601=s -> --iso-8601=seconds) only for specs that opt in through
  netcattyOptionalArgAttached, leaving other commands' optional arguments and
  required-argument completion unchanged.
- Describe su -m as BSD's caller login shell versus util-linux's -s/SHELL
  order, refresh the affected zh-CN/zh-TW entries and the bundled-date fallback
  translations, and regenerate zh-TW with the repository script.
- Add focused tests for per-OS loader caching, spec listing and scoping,
  attached-argument completion, path completion, and localized descriptions;
  update the batch-4 research notes to match.

* test(autocomplete): retrigger CI after a runner cancellation

The lint-and-test job on f09b3eed0 ended with "The runner has received a
shutdown signal" during the plugin boundary step, not with a test failure.
Contributors cannot re-run that job, so this empty commit triggers a fresh
PR synchronize check.

* fix(i18n): correct zh-CN autocomplete option descriptions

- Fix 38 "registry" mistranslations: Docker/kubectl image registry vs
  npm/yarn/pnpm package source
- Fix git --source (prints a ref name, not source code)
- Fix the truncated --pathspec-file-nul key (NUL, not whitespace)
- Correct OpenCC s2twp ambiguous characters in generated zh-TW and add
  the correction table to the generator
- Add regression assertions for the corrected entries

Co-Authored-By: Claude Code <noreply@anthropic.com>

* fix(i18n): correct autocomplete option descriptions

- Fix 32 verified mistranslations across git, Docker/Kubernetes,
  package managers, and core ops commands: git pull --rebase direction,
  find primaries, scp/curl cipher terminology, git config
  --default/--system, unzip/python editorial notes, and more
- Unify git worktree on 工作树 (15 entries), Docker secret on 密钥 (7),
  and Docker buildx on 构建器 (10)
- Restore git blame's missing subcommand description with a local spec
  override and translate it
- Update batch1/batch2 expectations and the research notes for the two
  editorial notes that are now faithful translations

Co-Authored-By: Claude Code <noreply@anthropic.com>

* feat(autocomplete): add podman and ip descriptions

- Add 66 podman descriptions (325/325 coverage) and a batch5 test
- Add a local ip spec covering addresses, links, routes, neighbors,
  rules, tunnels, netns, multicast, xfrm and monitor, plus 15 root
  options; translate all 88 descriptions
- Fix podman machine terminology (虚拟机) and --log-level wording
  (指定级别及以上)
- Add a batch6 test for the ip spec

Co-Authored-By: Claude Code <noreply@anthropic.com>

* feat(autocomplete): show Chinese descriptions for command suggestions

- Generate commandDescriptions.ts from the Fig specs and the committed
  dictionaries (674 commands; 83 already translated)
- Fill source "command" suggestions with zh-CN/zh-TW descriptions
- Align cp's zh-CN description with the conventional wording
- Stop maintaining zh-TW: new entries are zh-CN only, and the tests no
  longer require zh-TW key parity, only that zh-TW has no stale keys

Co-Authored-By: Claude Code <noreply@anthropic.com>

---------

Co-authored-by: Claude Code <noreply@anthropic.com>
2026-11-23 18:42:12 +08:00
AlexPlumandbincxz 2ca3ae0e28 feat(ai): add OpenCode Go provider (#4253)
* feat(ai): add OpenCode Go provider with API-key auto-config

Add OpenCode Go as a first-class AI provider preset for Catty:

- Pre-fill the Console endpoint (https://opencode.ai/inference/go/openai/v1)
  and a curated model list, with live discovery from /models.
- After the user pastes an API key and saves, select a sensible default
  model and activate the provider when no other provider is active.
- Parse nested limit.context values from model list payloads (OpenCode Go
  reports context windows this way).
- Point users at the Console API-key page from the provider form and make
  the settings search find the entry with "opencode".

The existing x-opencode-session header already covers chat routing for
opencode.ai hosts.

* fix(ai): fix OpenCode Go protocol choices

OpenCode Go exposes exactly one wire protocol and request format, so the
provider form must not offer Anthropic/Google styles or a Responses toggle.
Hide both controls for fixed-protocol presets, force the saved config back
to OpenAI Chat Completions, and ignore stale overrides at request time.

* fix(ai): route OpenCode Go models to their native protocol

OpenCode Go's catalog is not uniformly Chat Completions: 20 models are
native chat, 5 are Responses, 6 are Anthropic Messages, and 1 is Google
GenerateContent. The Console gateway translates between them, but forcing
Chat Completions loses each model's native reasoning and tool handling.

Keep the protocol controls hidden, then pick the wire family from the
selected model:

- responses -> OpenAI Responses
- messages  -> Anthropic Messages (/anthropic/v1 prefix)
- google    -> Google GenerateContent (/google/v1beta prefix)
- default   -> OpenAI Chat Completions

Model discovery stays on the OpenAI prefix, and a read-only Base URL makes
it clear that the endpoint paths are fixed by the provider.

* fix(ai): send OpenCode session and client headers

OpenCode Go needs `x-opencode-session` on every model call for routing and
prompt-cache affinity. Catty already forwards the chat session id; this also
covers plugin model invocations, which previously had no session header.

OpenCode also asks clients to identify themselves instead of presenting a
generic SDK user agent. Send `Netcatty-AI/1.0` for opencode.ai hosts while
keeping user-configured headers as the override.

* fix(ai): hide custom headers for fixed-protocol providers

OpenCode Go has one hosted endpoint and no proxy or self-signed setup to
configure, so the custom-header editor only adds noise. Hide it for
fixed-protocol presets and leave any previously stored headers untouched
instead of overwriting them with the hidden rows.

* fix(ai): use the official OpenCode mark for the provider icon

The previous asset was a monochrome silhouette that was left-aligned and
touched the badge edges, so it read as a generic terminal glyph. Replace it
with the official OpenCode mark (white frame, gray block, dark background)
and render it full-color instead of applying the monochrome invert filter.

* fix(ai): keep the OpenCode icon square at small sizes

The 16px composer badge used a 6px radius, so the full-color mark read as a
black circle. Give full-color icons size-aware corners (3/4/6px) and move
the asset to a new filename so a stale 300px SVG from an earlier build cannot
be reused.

* fix(ai): preserve disabled state when editing an existing OpenCode Go provider

* fix(ai): recognize Google SSE streaming requests in bridge fetch

---------

Co-authored-by: bincxz <16399091+binaricat@users.noreply.github.com>
2026-11-23 18:42:08 +08:00
陈大猫 d4a39ad2c6 feat(plugins): add bounded SSH host byte streams (network.hostStream) (#4297)
* feat(plugins): add bounded SSH host byte streams (network.hostStream)

* fix(plugins): route plugin-stream SSH host-key verification and cancel on abort
2026-11-23 18:42:03 +08:00
陈大猫 41c193c594 fix(storage): guard and recover missing LevelDB CURRENT before Chromium startup (#4315) 2026-11-23 17:08:41 +08:00
27a55f8b40 fix(window): fit main window to half-screen tiling cells (#4254)
* fix(window): fit main window to half-screen tiling cells

macOS and Windows window tiling keep the app's minimum size when the
requested cell is smaller, so the 1100x640 minimum pushed half-tiled
windows past the screen edge. Cap the effective minimum at half the
display work area minus the macOS tiling margin, and pull restored
bounds back inside the work area while preserving windows that span
adjacent displays.

Let Vault page headers wrap their action buttons on narrow half-screen
windows instead of clipping them.

Tests: window manager suite (127) and Vault header/layout tests pass.

Co-Authored-By: Claude Code <noreply@anthropic.com>

* fix(vault): allow nested VaultPageHeader action groups to wrap

---------

Co-authored-by: Claude Code <noreply@anthropic.com>
Co-authored-by: bincxz <16399091+binaricat@users.noreply.github.com>
2026-11-23 17:04:14 +08:00
陈大猫 f56249879c fix(ai): retain completed worker job routes for idempotent stop and poll (#4314) 2026-11-23 16:59:36 +08:00
574c683d72 fix(sftp): refresh transfer acquisition after saved host edits (#3696)
* fix(sftp): refresh transfer acquisition after host edits

* Keep SFTP transfers on the pane connection endpoint

* fix: address Codex review on PR #3696

* fix: address Codex review on PR #3696

* fix: address Codex review on PR #3696

* fix: address Codex review on PR #3696

* fix: address Codex review on PR #3696

* fix: address Codex review on PR #3696

* fix(sftp): align same-host copy guard with pinned routes after rebase

---------

Co-authored-by: Codex <codex@openai.com>
Co-authored-by: netcatty-bot <308658023+netcatty-bot@users.noreply.github.com>
2026-11-23 16:54:54 +08:00
陈大猫 06a42f623e fix(tabs): stop overflowed top tabs from stealing titlebar drag regions (#4221)
* fix(tabs): stop overflowed top tabs from stealing titlebar drag regions

Keep the native no-drag exclusion on the stationary scroll viewport, neutralize scrolled descendant regions, and move the 20 px drag handle outside the viewport. Add a source-level regression for the region policy.

Related #4220. Addresses bug 2 only; the split-pane blanking bug remains unresolved.

* fix(tabs): keep unused tab-strip space draggable when tabs do not overflow

* test(tabs): read source fixtures locally in TopTabs drag-region test
2026-11-23 16:50:47 +08:00
陈大猫 1f95fc01a0 fix(deeplink): report unsupported JumpServer protocol before SSH field validation (#4313) 2026-11-23 16:46:45 +08:00
陈大猫 2da20e6b2a fix(plugins): preserve plugin tabs on overlay close and harden host surface controls (#4296) 2026-11-23 16:46:40 +08:00
陈大猫 9afe0e29af fix(ai): persist active chat selection across restarts (#4302) 2026-11-23 16:46:35 +08:00
GOUKI9999 065dccca1d fix(ai): recognize macOS root prompts (host:dir user#) as idle-ready (#4197)
* fix(ai): recognize macOS root prompts (host:dir user#) as idle-ready

* fix(ai): reject cmd prompt lines with pending input from root-prompt match
2026-11-23 16:46:27 +08:00
minmie 10b91f607e fix(terminal): prevent mid-composition IME keydowns from duplicating voice input (#4304)
* fix(terminal): prevent mid-composition IME keydowns from duplicating voice input

Ignore sentinel mid-composition keydowns (keyCode 0 or Unidentified/Process/Dead/Compose) so xterm.js does not call _finalizeComposition(false) before voice ITN/AI polish finishes, preserve early synchronous commit state so trailing compositionend emits only the minimal diff, and track the last committed composition text for in-place consecutive rewrites.

* fix(terminal): invalidate early IME diff on terminal-mutating keys and keep tests ASCII-only

Address PR #4304 review feedback:
- Narrow sentinel keydown detection so non-empty keyCode 0 events (e.g. iOS UIKeyInput arrows) are not swallowed.
- Suppress early-sync backspace diffing and follow-up in-place rewrites when a mid-composition keydown can mutate terminal state or move the PTY cursor (such as ArrowLeft or Home).
- Escape CJK test fixtures as \uXXXX in imeCompositionRewrite.test.ts to preserve ASCII-only source files.
2026-11-23 16:44:31 +08:00
陈大猫 b24b458faf fix: fit main windows and vault editor widths on small displays (#4178)
* fix: fit main window startup bounds on small displays

* fix: fit vault editor widths without losing preferences
2026-11-23 16:33:19 +08:00
陈大猫 d979d8e272 fix(win): register Default Apps capabilities for ssh:// links (#4205)
* fix(win): register Default Apps capabilities for ssh:// links

* chore: retrigger CI after lint-and-test runner shutdown (#4205)
2026-11-23 16:33:14 +08:00
陈大猫 bbdb946989 fix(sftp): map WSL terminal cwd onto the local Windows file pane (#4212)
* fix(sftp): map WSL terminal cwd onto the local Windows file pane (#4211)

* chore: retrigger CI after plugin-contract runner cancel (#4212)
2026-11-23 16:33:09 +08:00
陈大猫andCodex 76041cc5e8 fix: skip unchanged WebDAV vault downloads on auto-sync inspect (#4312)
Persist response ETags alongside the synced snapshot anchor and use If-None-Match for remote inspections. Honor 304 without fetching a vault body, capture upload validators from the existing verification GET, and keep full downloads for upload preflight and servers without validators.

Co-authored-by: Codex <codex@openai.com>
2026-11-23 15:58:34 +08:00
陈大猫 abd2557356 fix: dev CJS imports, ligatures empty-line cache crash, and AI sidebar UX (#4310)
* fix: resolve dev CJS imports, ligatures empty-line crash, and streamline AI sidebar UX

* fix(ai): ignore nested control keydown events in session manager row
2026-11-23 15:00:06 +08:00
陈大猫 ad3d0cfeda refactor: streamline codebase, unify duplicated modules, and consolidate test suite (#4307)
* refactor: streamline codebase, unify duplicated modules, and consolidate tests

* fix(test): batch discovered test files into Windows-safe command lines
2026-11-23 11:00:14 +08:00
github-actions[bot]andgithub-actions[bot] f2c71874cf chore: update star history charts [skip ci] (#4308)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-11-23 00:07:34 +00:00
陈大猫 13eb477ba5 fix(plugins): keep disabled-runtime host-ready and terminal-target IPC channels quiet (#4306) 2026-11-22 17:33:03 +08:00
GOUKI9999andbincxz 00e63be4f1 feat(ai): global AI session manager with cross-scope rebind (#4098 phases 4-5) (#4159)
* feat(ai): global AI session manager with cross-scope rebind

Scope-agnostic view over every AI chat regardless of panel scope
(issue #4098 phases 4-5), hosted as a scoped/global toggle inside the
existing session history drawer.

- Global list: title, agent, resolved scope (workspace title / terminal
  label / global / dangling), state badge (active / idle / dissociated),
  message count, relative time; title-substring search, agent filter,
  newest-first ordering and a render batch guard. Titles only, never
  message bodies.
- Per-row actions: open/switch (exact-scope chats only; other-scope rows
  offer rebind instead of faking activation), rebind to the current
  panel (issue #4019 path) or to any open workspace/terminal via an
  explicit target picker, confirm-gated per-record delete, and
  single-chat export (exportSessionsBackup now takes an optional
  session-id subset; import merges by id).
- App-wide open terminals are threaded to every AI panel so the manager
  resolves scopes and rebind targets across tabs.
- Deletion safety: no scopeKey is passed, stale pointers of any panel
  are repaired by the #4125 validation effect; deleting the last chat
  cannot resurrect on reboot (intentionally-deleted ids + migration
  marker). No cleanup/eviction semantics are touched (#4015 R2).

* fix(ai): stop active turns before scope rebind

Rebinding a chat while a turn streams into it corrupts streaming state
(the stream targets the old scope while the active map/panel pointer move
underneath it). Both rebind paths — the global session manager and the
/rebind <n> panel command — now await stopStreamingForSession first,
chosen over rejecting the rebind because it cleanly awaits termination
(stopAgentTurn + waitForActiveTurn) and preserves the user's rebind
intent. stopStreamingForSession moves above the /rebind handler to avoid
a TDZ reference; the guard lives in AIChatSidePanelHelpers so both call
sites share it. Also passes the panel scope host ids to the manager for
the 'This panel' rebind target.

* fix(ai): derive session manager rebind targets from all live terminals

The global AI session manager built its app-wide terminal list from
contextsByTabId, which only covers tabs whose AI panel context is
mounted - a live terminal without one was missing as a rebind target.
useTerminalAiContexts now also exposes buildAllTerminalAiInfos over the
full terminal session store (same buildAITerminalSessionInfo per
session, so infos merge seamlessly where a context exists) and threads
it to AIChatPanelsHost as appTerminalSessions.

* fix(ai): preserve host ids on panel rebind and reset stale agent filters

- 'This panel' rebind now carries the viewing panel's scope host ids
  (currentScopeHostIds) onto the rewritten scope, so the destination
  host association is not orphaned; explicit picker targets already
  forwarded their hostIds.
- The agent filter no longer survives its agent: when the filtered
  agent's last chat is deleted the filter resets to 'all' instead of
  leaving a permanently empty list with a blank select; the select's
  built-in 'all' option stays the manual clear affordance.

* fix(ai): clear source workspace views when rebinding a chat

* fix(ai): demote implicit source views when rebinding restored chats

* fix(ai): stabilize appTerminalInfos identity and polish global session manager UI

- Retain appTerminalInfos array identity across structurally equal terminal updates so unrelated tab state churn does not re-render every mounted AIChatSidePanel.
- Replace native <select> elements in GlobalAIChatSessionManager with the shared Radix Select component for consistent dark/light theme rendering.
- Wrap the disabled cross-scope open button in a <span> inside TooltipTrigger (and add type="button" to row action buttons) so hover tooltips fire reliably.

* fix(ai): carry member host IDs on explicit workspace rebind targets

* fix(ai): remove redundant title beside history drawer scope switcher

* fix(ai): guard optional appTerminalSessions in AIChatPanelsHost

* fix(ai): clear persisted source workspace anchors when rebinding chats

* fix(ai): exclude non-exact workspace matches from implicit auto-resume

---------

Co-authored-by: bincxz <16399091+binaricat@users.noreply.github.com>
2026-11-22 11:53:02 +08:00
陈大猫 3a19f750a1 chore: add cloud environment setup config (#4303) 2026-11-22 11:26:24 +08:00
Radwan Selo 9d4e90b3aa feat(ai): add query and group filters to vault_hosts_list (#4278)
vault_hosts_list always returned every saved host, which costs a lot of
tokens in large vaults when the agent only needs one host to resolve a
hostId.

Add two optional parameters:
- query: case-insensitive; every space-separated word must match the
  label, hostname, username, or tags. Does not search group.
- group: group path that also matches subgroups on a path boundary
  (prod matches prod/web, not production). Case-sensitive.

Missing, empty, or non-string filters mean no filter, so existing calls
return the same result as before. Malformed host data (non-array tags)
no longer risks crashing the listing.

Regenerated the capability tool specs.
2026-11-21 20:16:14 +08:00
1094 changed files with 71826 additions and 34732 deletions

No files matched your search

+3
View File
@@ -0,0 +1,3 @@
{
"install": "if command -v apt-get >/dev/null 2>&1 && { ! command -v fish >/dev/null 2>&1 || ! command -v xvfb-run >/dev/null 2>&1; }; then sudo env DEBIAN_FRONTEND=noninteractive apt-get update -qq && sudo env DEBIAN_FRONTEND=noninteractive apt-get install -y -qq fish xvfb; fi && npm ci && npm run build:plugin-runtime-deps"
}
+8 -2
View File
@@ -44,7 +44,7 @@ jobs:
- name: Verify generated Catty tool specs
run: |
npm run generate:capability-tools
git diff --exit-code infrastructure/ai/harness/generated/cattyToolSpecs.json
git diff --exit-code infrastructure/ai/harness/generated/cattyToolSpecs.json infrastructure/ai/harness/generated/globalAgentToolSpecs.json
- name: Verify Codex App Server schema
run: npm run check:codex-app-server-schema
@@ -54,7 +54,6 @@ jobs:
npm run check:plugin-contract
npm run test:plugin-runtime
npm run test:plugin-examples
node --test --import tsx components/settings/tabs/Plugin*.test.tsx
- name: Test
run: npm test
@@ -155,5 +154,12 @@ jobs:
NETCATTY_SSH_TEST_RUNTIME: electron
run: node --test electron/bridges/sshChaChaTransport.test.cjs
- name: Exercise native PowerShell and CMD directory navigation in ConPTY
env:
NETCATTY_DIRECTORY_WINDOWS_LIVE: "1"
run: |
$env:NETCATTY_TEST_PWSH = (Get-Command pwsh -ErrorAction Stop).Source
node --test --test-force-exit --import tsx infrastructure/services/terminalDirectory.windows.test.ts
- name: Exercise two SSH password prompts in the desktop app
run: node scripts/terminal-broadcast-ssh.live.cjs
+3 -2
View File
@@ -23,7 +23,6 @@
!CODE_OF_CONDUCT.md
!CODE_SIGNING_POLICY.md
!CONTRIBUTING.md
!ET_INTEGRATION_CHECKLIST.md
!LICENSE
!PRIVACY.md
!README.ja-JP.md
@@ -38,7 +37,6 @@
!index.css
!index.html
!index.tsx
!metadata.json
!package-lock.json
!package.json
!tsconfig.json
@@ -48,6 +46,9 @@
# --- Layer 2: allowlist root directories ---
# Un-ignore the directory entry, then everything under it. Git does not
# traverse ignored directories, so both steps are required.
!.agents/
/.agents/*
!/.agents/environment.json
!.github/
!.github/**
!application/
+1 -1
View File
@@ -100,7 +100,7 @@ Placement rules (`resolveAgentKinds` in `toolSurfaces.cjs`):
| Vault bridge | `electron/bridges/aiBridge/vaultAgentBridge.cjs` + `infrastructure/ai/vaultAgentBridgeClient.ts` | Renderer vault state; **never** returns password/privateKey |
| AI context | `buildAITerminalSessionInfo` + `useTerminalAiContexts` | Per-session `hostChain` + `activePortForwards`; mirrored in `getContext` and Catty system prompt |
**Policy:** SFTP writes/transfers, `portforward_start`, and `host_notes_set` require confirm-mode approval. Observer mode blocks writes.
**Policy:** SFTP writes/transfers, `portforward_start`, and `host_notes_set` require confirm-mode approval. Observer mode blocks writes. `terminal_execute_bulk` (2–20 sessions, loaded via the `terminal_bulk` toolset) is all-or-nothing before sending and sets `policy.requiresFreshApproval`: remembered grants and external-client session approval never satisfy it. See `docs/features/terminal-execute-bulk.md`.
**Handles:** `ToolOutputStore` persists across turns per chat session; cleared on chat session delete. Large `sftp.read` results spill to `tool_output_read`.
+2 -2
View File
@@ -40,7 +40,7 @@ Netcatty is an Electron + React desktop app (SSH manager, terminal, SFTP browser
### Electron Main Process (`electron/`)
- **`main.cjs`** — entry point; wires crash logging, process error guards, and delegates to `main/registerBridges.cjs`
- **`bridges/`** — one `.cjs` file per capability domain (sshBridge, sftpBridge, terminalBridge, portForwardingBridge, aiBridge, etc.). Each bridge exposes IPC handlers via `ipcMain`. Tests live alongside the bridge file (`*.test.cjs`).
- **`preload.cjs`** — exposes a typed `window.electron` API to the renderer via `contextBridge`. Uses `preload/api.cjs` for the generated API surface.
- **`preload.cjs`** — exposes a typed `window.netcatty` API to the renderer via `contextBridge`. Uses `preload/api.cjs` for the generated API surface.
- **`cli/`** — `netcatty-tool-cli.cjs` is a separate internal binary for tool/MCP integration; treat as internal surface only.
### Renderer Process (React + Vite)
@@ -52,7 +52,7 @@ Three-layer architecture (see `AGENTS.md` for full detail):
- **`components/`** — presentation only. `App.tsx` wires hooks to components; no business logic in components.
### IPC Pattern
UI calls `window.electron.*` (preload API) → IPC → bridge handler in main process. Never call `ipcRenderer` directly from components.
UI calls `window.netcatty.*` (via `infrastructure/services/netcattyBridge.ts`) → IPC → bridge handler in main process. Never call `ipcRenderer` directly from components.
### Key Conventions
- All storage reads/writes go through `localStorageAdapter`; storage keys are in `infrastructure/config/storageKeys.ts`.
-219
View File
@@ -1,219 +0,0 @@
# EternalTerminal (ET) 集成清单 — 按 Mosh 方式重做
> 目标:在上游最新架构(分支 `feat/et-history-reapply`,基于 `031bf0ee`)上,
> **完全照搬 Mosh 的方式**重新集成 EternalTerminal:
> 1. **打包客户端** —— 像 `mosh-client` 那样,把 `et` 客户端二进制构建 + 下载 +
> 捆绑进安装包,运行时只用捆绑的二进制(不依赖系统安装的 et)。
> 2. **接入协议** —— 把旧分支 `feat/eternal-terminal`(tip `67e81616`)里的 ET
> 后端 + UI 重新落到上游重构后的目录结构上,并让它启动**捆绑的** `et`。
>
> 旧实现参考:`git show 67e81616`(共 7 个 ET 提交,见 `feat/eternal-terminal`)。
> Mosh 模板参考(**仅 MoshCatty 纯二进制路径**):`resources/mosh/README.md`、
> `scripts/fetch-mosh-binaries.cjs`、`scripts/resolve-mosh-bin-release.cjs`、
> `scripts/mosh-extra-resources.cjs`、`electron/bridges/terminalBridge/moshSession.cjs`。
> 客户端本体在独立仓库 [binaricat/MoshCatty](https://github.com/binaricat/MoshCatty)
> (`moshcatty-*` releases);Netcatty 内已无 Cygwin 构建流水线 / FluentTerminal 回退。
## 关键设计差异(ET vs Mosh)
- **协议**:Mosh 需要 Node 做 SSH bootstrap + 抓 `MOSH CONNECT` + 换 PTY
(`moshHandshake` + `moshSession`)。**ET 不需要** —— `et` 客户端自己完成 SSH
引导 + 协议握手,我们只要把 `et` 当作普通 PTY 进程 `pty.spawn` 即可。所以**没有**
`etHandshake.cjs`。
- **凭证注入**:Mosh 自己驱动 ssh、直接往 PTY 里敲密码;ET 内部驱动 ssh,需用
**SSH_ASKPASS + 临时 ~/.ssh 环境**把保存的密码/密钥/跳板/算法喂给 et 内部的 ssh
(旧实现 `prepareEtSshEnvironment` 已完整实现,直接搬运)。
- **纯二进制**:MoshCatty 与理想 ET 打包都是「每平台一个客户端文件」。Mosh 侧已
无 terminfo / Cygwin DLL 袋;`et` 同样本地不渲染终端。Windows 若动态链 CRT
才考虑可选 DLL 目录,否则只放 `et[.exe]`。
- **构建系统**:Mosh 客户端在 **MoshCatty** 仓库用 Rust 构建并发布;Netcatty 只
`fetch`。**ET** 用 CMake + Ninja + vcpkg
(`cmake -DDISABLE_TELEMETRY=ON -GNinja -DCMAKE_BUILD_TYPE=RelWithDebInfo`),
产物是单个 `et`(Windows `et.exe`),由 `scripts/build-et/` + `build-et-binaries.yml` 发布。
## 命名约定(镜像 Mosh / MoshCatty)
| Mosh (MoshCatty) | ET |
|------|----|
| `resources/mosh/<plat-arch>/mosh-client[.exe]` | `resources/et/<plat-arch>/et[.exe]` |
| 打包后 `<Resources>/mosh/mosh-client` | 打包后 `<Resources>/et/et` |
| 上游构建:`binaricat/MoshCatty` CI releases | `scripts/build-et/` + `build-et-binaries.yml` |
| `scripts/fetch-mosh-binaries.cjs` | `scripts/fetch-et-binaries.cjs` |
| `scripts/resolve-mosh-bin-release.cjs` | `scripts/resolve-et-bin-release.cjs` |
| `scripts/mosh-extra-resources.cjs` | `scripts/et-extra-resources.cjs` |
| env `MOSH_BIN_RELEASE` / 仓库 `MoshCatty` / tag `moshcatty-*` | env `ET_BIN_RELEASE` / 仓库 `Netcatty-et-bin` / tag `et-bin-*` |
| `npm run fetch:mosh[:dev]` | `npm run fetch:et[:dev]` |
| `bundledMoshClient()` / `resolveBareMoshClient()` | `bundledEtClient()` / `resolveBareEtClient()` |
---
## Phase 1 — 打包基础设施(构建/下载/捆绑)
- [x] **1.1** `resources/et/README.md` —— 镜像 `resources/mosh/README.md`:说明
二进制来源、`Netcatty-et-bin` 发布仓库、`et-bin-*` tag、许可证(ET 为
Apache-2.0,与 GPL-3.0 兼容)、可复现构建命令。
- [x] **1.2** `.gitignore` —— 追加 ET 段(镜像 mosh 段):
`/resources/et/*/et`、`/resources/et/*/et.exe`、`/resources/et/*/*.dll`、
`/resources/et/*/et-win32-*-dlls/`。保留 `resources/et/README.md`。
- [x] **1.3** `scripts/build-et/build-linux.sh` —— manylinux2014 + vcpkg 静态三元组
构建 `et`(x64/arm64),产物 `et-linux-<arch>.tar.gz`(+.sha256),内含单个 `et`。
校验非系统动态库(ldd 白名单)。
- [x] **1.4** `scripts/build-et/build-macos.sh` —— arm64 + x86_64 分别构建后 `lipo`
成 universal,`MACOSX_DEPLOYMENT_TARGET=11.0`,产物 `et-darwin-universal.tar.gz`。
- [x] **1.5** `scripts/build-et/build-windows.ps1`(或 `.sh`)—— MSVC + vcpkg
`x64-windows-static`,产物 `et-win32-x64.tar.gz`(含 `et.exe`;若动态链接 CRT
则随附 DLL 目录 `et-win32-x64-dlls/`,否则纯静态无 DLL)。
- [x] **1.6** `scripts/et-extra-resources.cjs` —— 镜像 `mosh-extra-resources.cjs`:
按平台/arch 仅当 `resources/et/<plat-arch>/et[.exe]` 存在时才产出 extraResources
指令(`to: "et/"`);Windows 额外处理可选 DLL 目录。纯客户端文件为主。
- [x] **1.7** `scripts/resolve-et-bin-release.cjs` —— 镜像 `resolve-mosh-bin-release.cjs`:
`TAG_RE=/^et-bin-.../`,默认仓库 `Netcatty-et-bin`,env `ET_BIN_RELEASE` 优先。
- [x] **1.8** `scripts/fetch-et-binaries.cjs` —— 镜像 `fetch-mosh-binaries.cjs`:
`TARGETS` 四项(linux-x64/arm64、darwin-universal、win32-x64),全部 tar.gz;
SHA256SUMS 校验;解包到 `resources/et/<plat-arch>/`。**Windows 用自建产物**。
- [x] **1.9** 单元测试:`scripts/fetch-et-binaries.test.cjs`、
`scripts/resolve-et-bin-release.test.cjs`、`scripts/et-extra-resources.test.cjs`
(镜像对应 mosh 测试,改名/改路径)。
- [x] **1.10** `package.json` scripts:新增
`"fetch:et": "node scripts/fetch-et-binaries.cjs"`、
`"fetch:et:dev": "node scripts/fetch-et-binaries.cjs --host --resolve-release"`;
把 `dev` 脚本改成先 `fetch:mosh:dev && fetch:et:dev`;`test` glob 已覆盖
`scripts/*.test.cjs`(确认即可)。
- [x] **1.11** `electron-builder.config.cjs`:引入 `etExtraResources`,在 darwin/win32/
linux 三处把 `etExtraResources(plat)` 合并进 `extraResources`(与 mosh 数组拼接)。
- [x] **1.12** `.github/workflows/build-et-binaries.yml` —— 四个构建 job + 一个
`release` job(dispatch 且 `release_tag` 非空时发布到 `Netcatty-et-bin`,附
`SHA256SUMS`)。`paths` 过滤指向 `scripts/build-et/**`、`scripts/fetch-et-binaries.cjs`、
`scripts/et-extra-resources.cjs`。env 用 `ET_REF`(默认 ET release tag,如 `et-v6.2.x`)。
> 注:实际二进制由用户手动 `workflow_dispatch` 触发产出;本地/CI 未设
> `ET_BIN_RELEASE` 时 fetch 步骤安静跳过(同 mosh 的 `MOSH_BIN_RELEASE`)。
## Phase 2 — 运行时定位捆绑客户端
- [x] **2.1** `electron/bridges/terminalBridge.cjs` 新增 `bundledEtClient(opts)`
—— 镜像 `bundledMoshClient`:打包路径 `<Resources>/et/et[.exe]`;dev 回退
`<projectRoot>/resources/et/<plat-arch>/et[.exe]`;导出到 module.exports。
## Phase 3 — ET 协议后端(搬运旧实现到新架构)
- [x] **3.1** 新建 `electron/bridges/terminalBridge/etSession.cjs` —— 用上游
`moshSession.cjs` 的 `createXxxSessionApi(ctx)` + `with(ctx)` 工厂模式,封装:
`ET_ASKPASS_SCRIPT`、`writeSecureFile`、`prepareEtSshEnvironment`、
`createEtAskpassArtifacts`、`cleanupStaleEtTempDirs`、
`cleanupSessionExternalAuthArtifacts`、`execOnEtSession`、`startEtSession`。
**改动点**:`etCmd` 由 `findExecutable('et')` 改为 `resolveBareEtClient()`
(取捆绑二进制);找不到时抛错(同 mosh:提示跑 `npm run fetch:et:dev`)。
Windows 若有动态链接 DLL 目录,可把该目录加进 PATH(MoshCatty 路径已无此需求)。
- [x] **3.2** `terminalBridge.cjs` 接线 `createEtSessionApi(ctx)`(镜像 moshSessionApi
的 ctx),传入 `bundledEtClient`、`tempDirBridge`、`execFile/execFileSync` 等;
解构出 `startEtSession`、`execOnEtSession`、`cleanupStaleEtTempDirs`、
`cleanupSessionExternalAuthArtifacts`、`resolveBareEtClient`。
- [x] **3.3** `init()` 调 `cleanupStaleEtTempDirs()`;`registerHandlers` 加
`ipcMain.handle("netcatty:et:start", startEtSession)`;`closeSession` 与
`cleanupAllSessions` 调 `cleanupSessionExternalAuthArtifacts(session)`;
`module.exports` 导出 `startEtSession`、`execOnEtSession`、`bundledEtClient`。
- [x] **3.4** 测试:`terminalBridge.bundledEt.test.cjs`(路径解析)+
`terminalBridge/etSession.test.cjs`(prepareEtSshEnvironment 的端口/密钥/
askpass/跳板/legacy 算法分支)。可参考旧分支是否已有 ET 测试并搬运。
## Phase 4 — domain / 类型 / preload 接口面
- [x] **4.1** `domain/models.ts`:`HostProtocol` 加 `'et'`;`ProtocolConfig.etPort?`;
`Host`/`GroupConfig` 加 `etEnabled?`/`etPort?`/`etTerminalPath?`;
`TerminalSession.etEnabled?`;`ConnectionLog.protocol` 加 `'et'`。
(照搬 `git show 794eecdf -- domain/models.ts`)
- [x] **4.2** `domain/groupConfig.ts`:加 `etEnabled` 默认项(照搬旧 diff)。
- [x] **4.3** `global.d.ts`:`NetcattyBridge` 加 `startEtSession?(options): Promise<...>`
及相关 options 类型(照搬 `git show 794eecdf -- global.d.ts`,并补齐后续 ET 提交
新增的 etPort/terminalPath/jumpHosts/legacyAlgorithms 字段)。
- [x] **4.4** `electron/preload/api.cjs`:加 `startEtSession`(镜像第 26 行的
`startMoshSession`)→ `ipcRenderer.invoke("netcatty:et:start", options)`。
**注意**:上游已把 preload 重构成 `createPreloadApi`,落点在 `preload/api.cjs`,
不是旧的 `preload.cjs` 内联对象。
## Phase 5 — 渲染层 + UI + i18n
- [x] **5.1** `application/state/useTerminalBackend.ts`:加 `etAvailable`(查
`bridge?.startEtSession`)+ `startEtSession`,并在返回对象/依赖数组里登记
(镜像 mosh 的第 10/42/198/205 行处)。
- [x] **5.2** `application/state/useSessionState.ts`:路由 ET 会话(照搬旧 diff,+6 行)。
- [x] **5.3** `components/terminal/runtime/createTerminalSessionStarters.ts`:加
`startEt(term)`(镜像 `startMosh`,组装 options:etPort/terminalPath/
jumpHosts/legacyAlgorithms/凭证/identityFilePaths)。
**注意**:上游把它从旧的 `infrastructure/runtime/` 移到了
`components/terminal/runtime/` —— 落点以上游为准。
- [x] **5.4** UI 组件(照搬 `git show b1a306f8 6c0d5bf3 55caa268` 的相应文件,
映射到上游同名组件):
- [ ] `components/ProtocolSelectDialog.tsx` —— 新增 ET 选项
- [ ] `components/QuickConnectWizard.tsx`
- [ ] `components/HostDetailsPanel.tsx` —— ET 设置(启用、ET 端口、etterminal 路径)
- [ ] `components/GroupDetailsPanel.tsx`
- [ ] `components/VaultView.tsx`
- [ ] `components/Terminal.tsx` / `components/TerminalLayer.tsx`
- [ ] `components/terminal/TerminalConnectionDialog.tsx` / `TerminalToolbar.tsx`
- [ ] `App.tsx`
- [x] **5.5** i18n:`application/i18n/locales/en.ts` 与 `zh-CN.ts` 加 ET 文案
(照搬旧 diff,键名对齐上游现有 mosh 文案结构)。
## Phase 6 — 校验
- [x] **6.1** `npm run lint`(确保新 .cjs 在 scripts/ 下不受 ESLint 限制,
或按需加 eslint-disable,与 mosh 脚本一致)。
- [x] **6.2** `npm test`(新增的 fetch/resolve/extra-resources/etSession 测试全绿)。
- [x] **6.3** `npm run build`(渲染层 TS 编译通过,无类型错误)。
- [ ] **6.4** 手动冒烟(需先有发布的二进制):
`ET_BIN_RELEASE=et-bin-... npm run fetch:et` → `npm run start` →
新建 ET 会话连一台装了 etserver 的主机,验证连接/输入/退出/凭证注入。
---
## 进度记录
- 状态:**Phase 1–5 已完成并通过校验**(仅余 1 个可选项 + CI 产二进制)
- 验证结果:
- `npx eslint <所有改动文件>` → 干净(0 错 0 警)
- `npx tsc --noEmit` → 我的改动 **0 个新增类型错误**
(`TerminalConnectionDialog` 里 `case 'mosh'` 的 TS2678 是既有问题,行号因我插入 ET 早返回从 60→64,非新增)
- `node --test`(ET 相关)→ etSession/bundledEt/3 个脚本测试 **全绿**
- `npm test` → 1383 通过 / 16 失败,**16 个全是既有的 Windows 环境失败**
(mosh 打包测试的 GNU-tar `C:` 问题、`isExecutableFile` 无 x 位、ACP execPath、SKILL.md 权限、Comware DH 等;均在我未改动的文件里)
- `npm run build`(Vite)→ **构建成功**(8.55s),渲染层打包通过
### 已完成
- **Phase 1**:`scripts/et-extra-resources.cjs` / `resolve-et-bin-release.cjs` /
`fetch-et-binaries.cjs`(+3 测试,27 通过)、`scripts/build-et/{build-linux.sh,
build-macos.sh,build-windows.ps1}`、`.github/workflows/build-et-binaries.yml`、
`resources/et/README.md`、`.gitignore`、`package.json`、`electron-builder.config.cjs`。
- **Phase 2**:`terminalBridge.cjs` 新增并导出 `bundledEtClient`。
- **Phase 3**:`terminalBridge/etSession.cjs`(startEtSession + prepareEtSshEnvironment +
SSH_ASKPASS 机制 + execOnEtSession + 清理),接线进 terminalBridge.cjs(ctx/IPC
`netcatty:et:start`/init 清理/close/quit 清理/导出),+2 测试(13 通过)。
**et 指向捆绑二进制**(resolveBareEtClient→bundledEtClient),找不到则报错。
- **Phase 4**:domain `connection.ts`/`history.ts`/`terminal.ts`、`groupConfig.ts`、
`types/global/netcatty-bridge-session.d.ts`(startEtSession + NetcattyJumpHost[])、
`electron/preload/api.cjs`、`domain/vaultImport.ts`(排除 'et' 导入协议)。
- **Phase 5**:
- 启动派发:`useTerminalEffects.ts`、`Terminal.tsx`(×3) → `startEt`
- 运行时 starter:`createTerminalSessionStarters.ts` 新增 `startEt`(含单跳板/凭证/
legacy 算法/askpass 路径),`.types.ts` 加 `etAvailable`/`startEtSession`
- 后端 hook:`useTerminalBackend.ts`(etAvailable + startEtSession)
- 会话透传 etEnabled:`sessionFactories.ts`、`useSessionState.ts`(×6)、
`TerminalLayer.tsx`(×3)、`TerminalLayerSupport.tsx`、`AppHandlers.ts`(协议解析/日志/选择)
- UI:`HostDetailsAdvancedSections.tsx`(ET 开关+端口+etterminal 路径,与 Mosh 互斥)、
`HostDetailsPanel.tsx`、`ProtocolSelectDialog.tsx`(ET 选项)、
`TerminalConnectionDialog.tsx`(ET 标签)、`TerminalToolbar.tsx`(编码菜单门控)、
`GroupSshSettingsSection.tsx` + `GroupDetailsPanel.tsx`(组级 ET)、`VaultView.tsx`
- i18n:en/zh-CN 的 `hostDetails.section.et`、`hostDetails.et.*`、
`terminal.connection.protocol.et`、`terminal.et.*`
### 剩余(可选 / 非阻塞)
- [ ] **QuickConnectWizard.tsx**:把 ET 加为“快速连接”协议按钮(type/端口/建主机映射 +
UI 按钮)。当前快速连接未列 ET;保存主机后开启 ET 再连即可,故仅为便利项。
- [ ] **产出二进制**:手动 `workflow_dispatch` 跑 `build-et-binaries.yml`(带
`release_tag=et-bin-<ver>-1`)发布到 `Netcatty-et-bin`,并配 `ET_BIN_RELEASE_TOKEN`
secret。之后 `ET_BIN_RELEASE=... npm run fetch:et` 即可本地/打包捆绑 `et`。
build-et 脚本本机无法编译 C++,需在 CI 验证。
- [ ] **端到端冒烟**:有二进制后 `npm run dev`,对装有 etserver 的主机建 ET 会话验证。
- 当前分支:`feat/et-history-reapply`(基于上游 `031bf0ee`)
- 旧 ET 实现参考分支:`feat/eternal-terminal`(tip `67e81616`,7 个 ET 提交)
+1
View File
@@ -145,6 +145,7 @@ If you regularly work with a fleet of servers, Netcatty is built for speed and f
- **File workflows** — drag & drop uploads/downloads
- **Edit in place** — built-in editor for quick changes
- **Create remote archives** — select files or folders, right-click **Compress...**, and create a named `.tar.gz` or `.zip` archive in the displayed destination directory; the server needs `tar`/`gzip` or `zip` for the chosen format.
- **Packed downloads** — download folders or multiple items in one stream, then automatically restore their original layout locally without leaving an archive on the server. Enabled by default in SFTP settings; unsupported connections use regular downloads. [Details and compatibility](docs/features/sftp-packed-download.md).
### 🎨 Personalization
- **Custom themes** — tune the app appearance to your taste
+1
View File
@@ -142,6 +142,7 @@
- **文件工作流** —— 拖拽上传/下载更直观
- **就地编辑** —— 内置编辑器快速修改文件
- **远程压缩** —— 单选或多选文件、文件夹,右键选择“压缩…”,在对话框显示的保存目录生成指定名称的 `.tar.gz` 或 `.zip` 压缩包;服务器需安装对应的 `tar`/`gzip` 或 `zip`。
- **打包下载** —— 下载文件夹或多个项目时,将所选内容一次传回并在本地自动还原原有目录结构,服务器不留压缩包。SFTP 设置中默认开启;不支持时使用普通下载。[使用说明与兼容性](docs/features/sftp-packed-download.md)。
### 🎨 个性化
- **自定义主题** —— 按喜好调整应用外观
@@ -0,0 +1,138 @@
import assert from 'node:assert/strict';
import test from 'node:test';
import React, { act } from 'react';
import { createRoot } from 'react-dom/client';
import { JSDOM } from 'jsdom';
import { createLocalShellHost } from '../domain/localShellHost';
import { collectSessionIds } from '../domain/workspace';
import { executeHotkeyActionImpl, handleGlobalHotkeyKeyDownImpl } from './app/AppHandlers';
import { DEFAULT_KEY_BINDINGS, matchesKeyBinding } from '../domain/models/keyBindings';
import { activeTabStore } from './state/activeTabStore';
import { resolveCloseIntent } from './state/resolveCloseIntent';
import { useSessionState } from './state/useSessionState';
async function setup(t: test.TestContext, paneCount: number | 'standalone', terminalFocus = true) {
const dom = new JSDOM(
'<div id="root"></div><div data-session-id="focused"><textarea class="xterm-helper-textarea"></textarea></div><button>Outside terminal</button>',
{ url: 'http://localhost' },
);
const previous = new Map<string, PropertyDescriptor | undefined>();
for (const [key, value] of Object.entries({
window: dom.window,
document: dom.window.document,
HTMLElement: dom.window.HTMLElement,
localStorage: dom.window.localStorage,
CustomEvent: dom.window.CustomEvent,
Event: dom.window.Event,
IS_REACT_ACT_ENVIRONMENT: true,
})) {
previous.set(key, Object.getOwnPropertyDescriptor(globalThis, key));
Object.defineProperty(globalThis, key, { configurable: true, value });
}
activeTabStore.setActiveTabId('vault');
const root = createRoot(document.getElementById('root')!);
t.after(async () => {
await act(async () => root.unmount());
activeTabStore.setActiveTabId('vault');
dom.window.close();
for (const [key, descriptor] of previous) {
if (descriptor) Object.defineProperty(globalThis, key, descriptor);
else Reflect.deleteProperty(globalThis, key);
}
});
let state: ReturnType<typeof useSessionState>;
function Probe() {
state = useSessionState({ persistSessionRestore: false });
return null;
}
await act(async () => root.render(React.createElement(Probe)));
await act(async () => {
if (paneCount === 'standalone') state.createLocalTerminal();
else state.createWorkspaceWithHosts('Split tab', Array.from({ length: paneCount }, (_, index) => (
createLocalShellHost({ id: `local-${index}` })
)));
});
// Choose the second pane so closing an arbitrary first pane cannot pass.
if (paneCount !== 'standalone' && paneCount > 1) {
await act(async () => state.setWorkspaceFocusedSession(state.workspaces[0].id, state.sessions[1].id));
}
document.querySelector<HTMLElement>(terminalFocus ? 'textarea' : 'button')!.focus();
const confirmations: string[][] = [];
const closeTabInFlightRef = { current: false };
const execute = (action: string, event: KeyboardEvent) => executeHotkeyActionImpl(() => ({
activeTabStore,
closeSession: state.closeSession,
closeWorkspace: state.closeWorkspace,
closeTabInFlightRef,
collectSessionIds,
confirmIfBusyLocalTerminal: async (ids: string[]) => { confirmations.push(ids); return true; },
editorTabs: [],
isEditorTabId: () => false,
orderedTabs: [],
resolveCloseIntent,
sessions: state.sessions,
settings: {},
workspaces: state.workspaces,
}), action, event);
return {
get state() { return state!; },
confirmations,
async press(shiftKey = false, scheme: 'mac' | 'pc' = 'mac') {
const event = new dom.window.KeyboardEvent('keydown', {
key: 'w', code: 'KeyW', metaKey: scheme === 'mac', ctrlKey: scheme === 'pc', shiftKey,
bubbles: true, cancelable: true,
});
document.activeElement!.addEventListener('keydown', (e) => handleGlobalHotkeyKeyDownImpl(() => ({
HOTKEY_DEBUG: false,
closeTabKeyStr: scheme === 'mac' ? '\u2318 + W' : 'Ctrl + W',
executeHotkeyAction: execute,
hotkeyScheme: scheme,
keyBindings: DEFAULT_KEY_BINDINGS,
matchesKeyBinding,
}), e as KeyboardEvent), { once: true });
await act(async () => { document.activeElement!.dispatchEvent(event); });
assert.equal(event.defaultPrevented, true);
assert.equal(closeTabInFlightRef.current, false);
},
};
}
for (const scheme of ['mac', 'pc'] as const) {
for (const terminalFocus of [true, false]) {
test(`${scheme} close-tab closes every pane and the tab with terminal focus ${terminalFocus}`, async (t) => {
const harness = await setup(t, 2, terminalFocus);
const ids = harness.state.sessions.map((session) => session.id);
await harness.press(false, scheme);
assert.deepEqual(harness.state.sessions, []);
assert.deepEqual(harness.state.workspaces, []);
assert.equal(activeTabStore.getActiveTabId(), 'vault');
assert.deepEqual(harness.confirmations, [ids]);
});
}
test(`${scheme} close-pane closes only the focused pane in a split tab`, async (t) => {
const harness = await setup(t, 2);
const workspace = harness.state.workspaces[0];
const focusedId = workspace.focusedSessionId;
const survivorId = harness.state.sessions[0].id;
await harness.press(true, scheme);
assert.deepEqual(harness.state.sessions.map((session) => session.id), [survivorId]);
assert.equal(harness.state.workspaces.length, 1);
assert.deepEqual(collectSessionIds(harness.state.workspaces[0].root), [survivorId]);
assert.equal(activeTabStore.getActiveTabId(), workspace.id);
assert.deepEqual(harness.confirmations, [[focusedId]]);
});
for (const paneCount of [1, 'standalone'] as const) {
test(`${scheme} close-pane closes a ${paneCount} pane tab`, async (t) => {
const harness = await setup(t, paneCount);
const id = harness.state.sessions[0].id;
await harness.press(true, scheme);
assert.deepEqual(harness.state.sessions, []);
assert.deepEqual(harness.state.workspaces, []);
assert.equal(activeTabStore.getActiveTabId(), 'vault');
assert.deepEqual(harness.confirmations, [[id]]);
});
}
}
@@ -1032,3 +1032,108 @@ test('host list shortcut calls the same store toggle as the toolbar button', ()
const source = readFileSync(new URL('./app/AppSideEffects.tsx', import.meta.url), 'utf8');
assert.match(source, /toggleHostTree:\s*\(\)\s*=>\s*terminalHostTreeStore\.toggle\(\)/);
});
test('Cmd+Shift+T on macOS and Ctrl+Shift+T on PC dispatch reopenClosedTab and stay out of text inputs', () => {
for (const [scheme, keyProps] of [
['mac', { metaKey: true, ctrlKey: false }],
['pc', { metaKey: false, ctrlKey: true }],
] as const) {
const target = new FakeHTMLElement();
const actions: string[] = [];
let prevented = false;
let stopped = false;
handleGlobalHotkeyKeyDownImpl(() => ({
HOTKEY_DEBUG: false,
closeTabKeyStr: '',
executeHotkeyAction: (action: string) => {
actions.push(action);
},
hotkeyScheme: scheme,
keyBindings: DEFAULT_KEY_BINDINGS,
matchesKeyBinding,
}), {
key: 'T',
code: 'KeyT',
...keyProps,
altKey: false,
shiftKey: true,
target,
composedPath: () => [target],
preventDefault: () => { prevented = true; },
stopPropagation: () => { stopped = true; },
} as unknown as KeyboardEvent);
assert.deepEqual(actions, ['reopenClosedTab']);
assert.equal(prevented, true);
assert.equal(stopped, true);
const input = new FakeInputHTMLElement();
const inputActions: string[] = [];
handleGlobalHotkeyKeyDownImpl(() => ({
HOTKEY_DEBUG: false,
closeTabKeyStr: '',
executeHotkeyAction: (action: string) => {
inputActions.push(action);
},
hotkeyScheme: scheme,
keyBindings: DEFAULT_KEY_BINDINGS,
matchesKeyBinding,
}), {
key: 'T',
code: 'KeyT',
...keyProps,
altKey: false,
shiftKey: true,
target: input,
composedPath: () => [input],
preventDefault: () => {},
stopPropagation: () => {},
} as unknown as KeyboardEvent);
assert.deepEqual(inputActions, []);
}
});
test('executeHotkeyActionImpl reopenClosedTab calls reopenLastClosedTab and records connection logs for reopened workspace panes', () => {
const logs: Array<Record<string, unknown>> = [];
let receivedHostIds: string[] = [];
const hostsById = new Map([
['h-1', { id: 'h-1', label: 'Prod', hostname: 'prod.test', username: 'ops', port: 22, os: 'linux', group: '', tags: [] }],
]);
executeHotkeyActionImpl(() => ({
activeTabStore: { getActiveTabId: () => 'vault' },
addConnectionLogRef: { current: (log: Record<string, unknown>) => logs.push(log) },
editorTabs: [],
hostsById,
orderedTabs: [],
reopenLastClosedTab: (opts: { availableHostIds?: ReadonlySet<string> }) => {
receivedHostIds = [...(opts.availableHostIds ?? [])];
return {
kind: 'workspace',
tabId: 'ws-new',
workspace: { id: 'ws-new', title: 'Prod Split', root: { id: 'p', type: 'pane', sessionId: 's-new-1' } },
sessions: [
{ id: 's-new-1', hostId: 'h-1', hostLabel: 'Prod', hostname: 'prod.test', username: 'ops', status: 'connecting', protocol: 'ssh', workspaceId: 'ws-new' },
{ id: 's-new-2', hostId: 'local-terminal', hostLabel: 'Local Terminal', hostname: 'localhost', username: 'local', status: 'connecting', protocol: 'local', workspaceId: 'ws-new' },
],
};
},
sessions: [],
settings: {},
systemInfoRef: { current: { username: 'dev', hostname: 'laptop' } },
toEditorTabId: (id: string) => id,
workspaces: [],
}), 'reopenClosedTab', {} as KeyboardEvent);
assert.deepEqual(receivedHostIds, ['h-1']);
assert.equal(logs.length, 2);
assert.equal(logs[0].sessionId, 's-new-1');
assert.equal(logs[0].hostId, 'h-1');
assert.equal(logs[0].username, 'ops');
assert.equal(logs[1].sessionId, 's-new-2');
assert.equal(logs[1].hostId, '');
assert.equal(logs[1].username, 'dev');
assert.equal(logs[1].protocol, 'local');
});
+162 -1
View File
@@ -2,7 +2,7 @@ import test from "node:test";
import assert from "node:assert/strict";
import type { TerminalSession } from "../domain/models";
import { copySessionToNewWindowWithCurrentShellImpl } from "./app/AppHandlers";
import { copySessionToNewWindowWithCurrentShellImpl, moveSessionToNewWindowImpl } from "./app/AppHandlers";
const sourceSession = (overrides: Partial<TerminalSession> = {}): TerminalSession => ({
id: "session-1",
@@ -187,3 +187,164 @@ test("copySessionToNewWindowWithCurrentShellImpl shows an error when the bridge
assert.equal(result, false);
assert.deepEqual(errors, ["Could not open"]);
});
const moveCtx = (openTerminalPopup: ((payload: Record<string, unknown>) => Promise<unknown>) | undefined) => {
const calls: unknown[][] = [];
const errors: string[] = [];
const getCtx = () => ({
netcattyBridge: { get: () => (openTerminalPopup ? { openTerminalPopup } : {}) },
sessions: [sourceSession({ id: "other" }), sourceSession()],
setActiveTabId: (id: string) => calls.push(["active", id]),
setSessionPoppedOut: (id: string, poppedOut: boolean) => calls.push(["poppedOut", id, poppedOut]),
t: (key: string) => key,
toast: { error: (message: string) => errors.push(message) },
});
return { calls, errors, getCtx };
};
test("moveSessionToNewWindowImpl hides the tab and attaches a popup to the same live session", async () => {
const payloads: Record<string, unknown>[] = [];
const { calls, errors, getCtx } = moveCtx(async (payload) => {
payloads.push(payload);
return { success: true };
});
assert.equal(await moveSessionToNewWindowImpl(getCtx, "session-1"), true);
assert.deepEqual(calls, [["poppedOut", "session-1", true], ["active", "other"]]);
assert.equal(payloads[0].attachSessionId, "session-1");
assert.equal(payloads[0].moveSession, true);
assert.deepEqual(errors, []);
});
test("moveSessionToNewWindowImpl leaves the tab untouched when the popup fails to attach", async () => {
const { calls, errors, getCtx } = moveCtx(async () => ({ success: false, error: "boom" }));
assert.equal(await moveSessionToNewWindowImpl(getCtx, "session-1"), false);
assert.deepEqual(calls, []);
assert.deepEqual(errors, ["boom"]);
});
test("moveSessionToNewWindowImpl waits for popup attachment before hiding the tab", async () => {
let resolveOpen: ((value: unknown) => void) | null = null;
const { calls, getCtx } = moveCtx(
() => new Promise((resolve) => { resolveOpen = resolve; }),
);
const pending = moveSessionToNewWindowImpl(getCtx, "session-1");
await Promise.resolve();
assert.deepEqual(calls, []);
resolveOpen?.({ success: true });
assert.equal(await pending, true);
assert.deepEqual(calls, [["poppedOut", "session-1", true], ["active", "other"]]);
});
test("moveSessionToNewWindowImpl ignores tabs without a live backend", async () => {
const { calls, getCtx } = moveCtx(async () => ({ success: true }));
const ctx = getCtx();
const result = await moveSessionToNewWindowImpl(
() => ({ ...ctx, sessions: [sourceSession({ status: "disconnected" })] }),
"session-1",
);
assert.equal(result, false);
assert.deepEqual(calls, []);
});
test("moveSessionToNewWindowImpl ignores plugin-backed sessions", async () => {
const { calls, getCtx } = moveCtx(async () => ({ success: true }));
const ctx = getCtx();
const result = await moveSessionToNewWindowImpl(
() => ({ ...ctx, sessions: [sourceSession({ protocol: "plugin:com.acme.db" })] }),
"session-1",
);
assert.equal(result, false);
assert.deepEqual(calls, []);
});
test("moveSessionToNewWindowImpl ignores workspace panes", async () => {
const { calls, getCtx } = moveCtx(async () => ({ success: true }));
const ctx = getCtx();
const result = await moveSessionToNewWindowImpl(
() => ({ ...ctx, sessions: [sourceSession({ workspaceId: "ws-1" })] }),
"session-1",
);
assert.equal(result, false);
assert.deepEqual(calls, []);
});
test("moveSessionToNewWindowImpl preserves active tab focus when moving an inactive tab", async () => {
const { calls, errors, getCtx } = moveCtx(async () => ({ success: true }));
const ctx = getCtx();
const result = await moveSessionToNewWindowImpl(
() => ({
...ctx,
getActiveTabId: () => "ws-1",
getOrderedTabs: () => ["ws-1", "session-1"],
}),
"session-1",
);
assert.equal(result, true);
assert.deepEqual(calls, [["poppedOut", "session-1", true]]);
assert.deepEqual(errors, []);
});
test("moveSessionToNewWindowImpl does not steal focus when moving an inactive tab fails", async () => {
const { calls, errors, getCtx } = moveCtx(async () => ({ success: false, error: "nope" }));
const ctx = getCtx();
const result = await moveSessionToNewWindowImpl(
() => ({
...ctx,
getActiveTabId: () => "editor:1",
getOrderedTabs: () => ["editor:1", "session-1"],
}),
"session-1",
);
assert.equal(result, false);
assert.deepEqual(calls, []);
assert.deepEqual(errors, ["nope"]);
});
test("moveSessionToNewWindowImpl selects the adjacent ordered visible tab when moving the active tab", async () => {
const { calls, getCtx } = moveCtx(async () => ({ success: true }));
const ctx = getCtx();
const result = await moveSessionToNewWindowImpl(
() => ({
...ctx,
sessions: [sourceSession()],
getActiveTabId: () => "session-1",
getOrderedTabs: () => ["ws-1", "session-1", "editor:1"],
}),
"session-1",
);
assert.equal(result, true);
assert.deepEqual(calls, [["poppedOut", "session-1", true], ["active", "ws-1"]]);
});
test("moveSessionToNewWindowImpl closes the popup if the tab moved into a workspace during startup", async () => {
const closedPopups: string[] = [];
let sessions: TerminalSession[] = [sourceSession()];
const calls: unknown[][] = [];
const getCtx = () => ({
netcattyBridge: {
get: () => ({
openTerminalPopup: async () => {
sessions = [sourceSession({ workspaceId: "ws-late" })];
return { success: true, popupId: "popup-late" };
},
closeTerminalPopup: async (popupId: string) => {
closedPopups.push(popupId);
return { success: true };
},
}),
},
sessions,
setActiveTabId: (id: string) => calls.push(["active", id]),
setSessionPoppedOut: (id: string, poppedOut: boolean) => calls.push(["poppedOut", id, poppedOut]),
t: (key: string) => key,
toast: { error: () => {} },
});
assert.equal(await moveSessionToNewWindowImpl(getCtx, "session-1"), false);
assert.deepEqual(closedPopups, ["popup-late"]);
assert.deepEqual(calls, []);
});
+28
View File
@@ -63,6 +63,34 @@ test("handleTrayJumpToSessionImpl opens a terminal popup for AI silent sessions"
assert.deepEqual(opened[0], buildAiSilentSessionPopupPayload(session({ hiddenFromTabs: true })));
});
test("handleTrayJumpToSessionImpl reasserts poppedOut after reopening a moved tab", async () => {
const poppedCalls: Array<[string, boolean]> = [];
const opened: unknown[] = [];
await handleTrayJumpToSessionImpl(
() => ({
sessions: [session({ hiddenFromTabs: true, poppedOut: true })],
setActiveTabId: () => {},
setSessionPoppedOut: (id: string, poppedOut: boolean) => poppedCalls.push([id, poppedOut]),
setWorkspaceFocusedSession: () => {},
getActiveTabId: () => "vault",
netcattyBridge: {
get: () => ({
openTerminalPopup: async (payload: unknown) => {
opened.push(payload);
return { success: true, popupId: "popup-reopen" };
},
}),
},
toast: { error: () => {} },
t: (k: string) => k,
}),
"session-1",
);
assert.equal((opened[0] as { moveSession?: boolean }).moveSession, true);
assert.deepEqual(poppedCalls, [["session-1", true]]);
});
test("handleTrayJumpToSessionImpl still activates normal solo sessions in the main window", async () => {
let activeTabId = "vault";
let openedMain = 0;
@@ -1,57 +0,0 @@
import assert from "node:assert/strict";
import { readFileSync } from "node:fs";
import test from "node:test";
const appSideEffectsSource = readFileSync(new URL("./AppSideEffects.tsx", import.meta.url), "utf8");
const terminalHostSource = readFileSync(new URL("./hosts/TerminalHost.tsx", import.meta.url), "utf8");
const appViewSource = readFileSync(new URL("./AppView.tsx", import.meta.url), "utf8");
const runtimeSource = readFileSync(new URL("../state/useThemeRuntime.ts", import.meta.url), "utf8");
const settingsSource = readFileSync(new URL("../state/useSettingsState.ts", import.meta.url), "utf8");
test("follow-app terminal theme selection updates the matching UI theme via ThemeRuntime", () => {
assert.match(runtimeSource, /getFollowAppTerminalThemeSelectionUpdate\(themeId\)/);
assert.match(runtimeSource, /setDarkUiThemeId\(update\.uiThemeId\)/);
assert.match(runtimeSource, /setLightUiThemeId\(update\.uiThemeId\)/);
assert.match(runtimeSource, /setTheme\(update\.appTheme\)/);
assert.doesNotMatch(runtimeSource, /isFollowAppIntentSettled\(userIntent\.themeId/);
assert.match(terminalHostSource, /useThemeRuntime\(/);
assert.match(terminalHostSource, /pickTerminalTheme\(themeId\)/);
assert.match(terminalHostSource, /pickTheme: pickTerminalTheme/);
// Theme members are listed field-by-field on the TerminalHost bag (not themeRuntime bag).
assert.match(terminalHostSource, /clearThemeIntent,/);
assert.match(terminalHostSource, /settleManualThemeIntent,/);
assert.match(terminalHostSource, /pickTerminalTheme,/);
assert.match(terminalHostSource, /resolveSessionAppearance: resolveFocusedAppearance/);
assert.doesNotMatch(
terminalHostSource,
/followAppTerminalTheme, themeRuntime, handleConnectSerial/,
);
// Terminal domain must not thrash on whole settings bag identity.
assert.match(terminalHostSource, /sshDebugLogsEnabled:/);
assert.doesNotMatch(
terminalHostSource,
/splitSessionWithCurrentShell, settings, terminalFontFamilyId/,
);
// Hotkey path must not depend on whole settings/sessions for callback identity.
assert.match(appSideEffectsSource, /showSftpTab: showSftpTabRef\.current/);
assert.match(appSideEffectsSource, /sessions: sessionsRef\.current/);
assert.match(appSideEffectsSource, /connectionLogs: connectionLogsRef\.current/);
assert.match(terminalHostSource, /useTerminalAppearanceInjection/);
assert.match(terminalHostSource, /includeChromeSurfaces: followAppTerminalTheme/);
assert.match(terminalHostSource, /useTerminalAppearanceInjection\(accentedGlobalAppearance/);
assert.match(terminalHostSource, /clearThemeIntent\(\)/);
assert.match(runtimeSource, /injectTerminalAppearanceVars\(appearance\.theme, \{ includeChromeSurfaces \}\)/);
assert.doesNotMatch(settingsSource, /pendingFollowAppTerminalThemeId/);
assert.doesNotMatch(settingsSource, /applyFollowAppTerminalThemePick/);
assert.match(settingsSource, /appearanceTransitionModeRef\.current = 'instant'/);
assert.match(appViewSource, /data-terminal-appearance-root/);
assert.match(appViewSource, /pickTerminalTheme=\{ctx\.pickTerminalTheme\}/);
});
test("default terminal theme selection persists via TerminalHost", () => {
// Product path lives on TerminalHost; AppSideEffects no longer owns this handler.
assert.match(terminalHostSource, /const handleDefaultTerminalThemeChange = useCallback\(\(themeId: string\) => \{/);
assert.match(terminalHostSource, /setTerminalThemeId\(themeId\)/);
assert.match(terminalHostSource, /TERMINAL_THEME_AUTO/);
assert.match(appViewSource, /onUpdateTerminalThemeId=\{handleDefaultTerminalThemeChange\}/);
});
+140 -8
View File
@@ -8,6 +8,7 @@ import { resolveHostDefaultLocalShell } from '../../domain/localShellHost';
import { getAvailablePaneMagnificationController } from '../../domain/paneMagnification';
import { sanitizeHostIconFields } from '../../domain/hostIcon';
import { resolveEffectiveTerminalProtocol } from '../../domain/terminalProtocol';
import { isPluginHostProtocol } from '../../domain/pluginConnection';
import { getTerminalPassthroughActions } from '../state/useGlobalHotkeys';
import { getSettingsChromeSnapshot } from '../state/settingsChromeStore';
import { isHostTreeWorkTabSurface } from './workTabSurface';
@@ -73,7 +74,7 @@ export const getLogHostVisualSnapshot = (host: Host) => {
* spawning a new shell via connection reuse.
*/
export function buildAiSilentSessionPopupPayload(session: TerminalSession): TerminalPopupPayload {
const { hiddenFromTabs: _hiddenFromTabs, ...sourceSession } = session;
const { hiddenFromTabs: _hiddenFromTabs, poppedOut: _poppedOut, ...sourceSession } = session;
return {
title: session.hostLabel || 'Terminal',
parentSessionId: session.id,
@@ -89,6 +90,7 @@ export async function handleTrayJumpToSessionImpl(getCtx: AppContextGetter, sess
const {
sessions,
setActiveTabId,
setSessionPoppedOut,
setWorkspaceFocusedSession,
netcattyBridge,
toast,
@@ -111,13 +113,20 @@ export async function handleTrayJumpToSessionImpl(getCtx: AppContextGetter, sess
return;
}
try {
const result = await bridge.openTerminalPopup(buildAiSilentSessionPopupPayload(session));
const payload = session.poppedOut
? { ...buildAiSilentSessionPopupPayload(session), moveSession: true }
: buildAiSilentSessionPopupPayload(session);
const result = await bridge.openTerminalPopup(payload);
if (!result?.success) {
toast?.error?.(
result?.error
|| t?.('tabs.copyTabToNewWindowFailed')
|| 'Failed to open tab in a new window',
);
} else if (session.poppedOut) {
// Reassert popped-out state in case a stale attach-closed event from a
// prior crashed popup arrived while the replacement popup was attaching.
setSessionPoppedOut?.(sessionId, true);
}
} catch (err) {
toast?.error?.(
@@ -695,6 +704,96 @@ export async function copySessionToNewWindowWithCurrentShellImpl(getCtx: AppCont
}
}
const inFlightMoveSessions = new Set<string>();
/**
* Move a solo tab into its own window without reconnecting: an attach popup
* takes over the same live PTY (no second login, e.g. on a bastion with seat
* limits). The tab is hidden only after the popup actually attaches, and
* closing the popup brings it back via onTerminalPopupAttachClosed.
*/
export async function moveSessionToNewWindowImpl(getCtx: AppContextGetter, sessionId: string) {
if (inFlightMoveSessions.has(sessionId)) return false;
const {
getActiveTabId,
getOrderedTabs,
netcattyBridge,
sessions,
setActiveTabId,
setSessionPoppedOut,
t,
toast,
} = getCtx();
const session = sessions.find((item: TerminalSession) => item.id === sessionId);
// Attach mode only takes over a live non-plugin backend; plugin connections
// remain owned by their source renderer until plugin lifetime transfer exists.
if (
!session
|| session.workspaceId
|| session.hiddenFromTabs
|| session.status !== 'connected'
|| isPluginHostProtocol(session.protocol)
|| (typeof session.protocol === 'string' && session.protocol.startsWith('plugin:'))
) {
return false;
}
const fail = (error?: string) => {
toast?.error?.(error || (t?.('tabs.moveTabToNewWindowFailed') ?? 'Failed to move tab to a new window'));
return false;
};
const bridge = netcattyBridge?.get?.();
if (!bridge?.openTerminalPopup) return fail();
inFlightMoveSessions.add(sessionId);
try {
const result = await bridge.openTerminalPopup({ ...buildAiSilentSessionPopupPayload(session), moveSession: true });
if (!result?.success) return fail(result?.error);
const latestCtx = getCtx();
const latestSessions: TerminalSession[] = latestCtx.sessions ?? sessions;
const stillPresent = latestSessions.find((item: TerminalSession) => item.id === sessionId);
if (!stillPresent || stillPresent.workspaceId || stillPresent.hiddenFromTabs) {
if (typeof result.popupId === 'string' && result.popupId) {
void bridge.closeTerminalPopup?.(result.popupId);
}
return false;
}
const latestGetActiveTabId = latestCtx.getActiveTabId ?? getActiveTabId;
const latestGetOrderedTabs = latestCtx.getOrderedTabs ?? getOrderedTabs;
const latestSetActiveTabId = latestCtx.setActiveTabId ?? setActiveTabId;
const latestSetSessionPoppedOut = latestCtx.setSessionPoppedOut ?? setSessionPoppedOut;
const isActive = typeof latestGetActiveTabId === 'function' ? latestGetActiveTabId() === sessionId : true;
latestSetSessionPoppedOut(sessionId, true);
if (isActive) {
const orderedTabs = typeof latestGetOrderedTabs === 'function' ? latestGetOrderedTabs() : null;
let fallbackTab: string | undefined;
if (Array.isArray(orderedTabs) && orderedTabs.length > 0) {
const index = orderedTabs.indexOf(sessionId);
const candidate = index >= 0
? (orderedTabs[index - 1] ?? orderedTabs[index + 1])
: orderedTabs.filter((id: string) => id !== sessionId).slice(-1)[0];
if (candidate && candidate !== sessionId) {
fallbackTab = candidate;
}
}
if (!fallbackTab) {
fallbackTab = latestSessions
.filter((item: TerminalSession) => item.id !== sessionId && !item.workspaceId && !item.hiddenFromTabs)
.slice(-1)[0]?.id ?? 'vault';
}
latestSetActiveTabId(fallbackTab);
}
return true;
} catch (err) {
return fail(err instanceof Error ? err.message : undefined);
} finally {
inFlightMoveSessions.delete(sessionId);
}
}
export async function confirmIfBusyLocalTerminalImpl(getCtx: AppContextGetter, sessionIds: string[]) {
const { netcattyBridge, sessions, t } = getCtx();
{
@@ -816,7 +915,7 @@ export async function closeTabsBatchImpl(getCtx: AppContextGetter, targetIds: st
}
export function executeHotkeyActionImpl(getCtx: AppContextGetter, action: string, e: KeyboardEvent) {
const { IS_DEV, MOVE_FOCUS_DEBOUNCE_MS, activeTabStore, addConnectionLogRef, canUseGlobalBroadcast, closePluginViewTab, closeSession, closeTabInFlightRef, closeWorkspace, collectSessionIds, confirmIfBusyLocalTerminal, createLocalTerminalWithCurrentShell, editorTabs, fromEditorTabId, handleOpenSettingsRef, handleRequestCloseEditorTabRef, isEditorTabId, isPluginViewTabId, isQuickSwitcherOpen, lastMoveFocusTimeRef, moveFocusInWorkspace, orderedTabs, resolveCloseIntent, resolveSnippetsShortcutIntent, sessions, setActiveTabId, setAddToWorkspaceDialog, setIsQuickSwitcherOpen, setNavigateToSection, settings, sftpPaneMagnificationRef, splitSessionWithCurrentShell, systemInfoRef, terminalPaneMagnificationRef, toEditorTabId, toggleBroadcast, toggleGlobalBroadcast, toggleHostTree, toggleScriptsSidePanelRef, toggleSidePanelRef, toggleWindowOpacity, workspaces } = getCtx();
const { IS_DEV, MOVE_FOCUS_DEBOUNCE_MS, activeTabStore, addConnectionLogRef, canUseGlobalBroadcast, closePluginViewTab, closeSession, closeTabInFlightRef, closeWorkspace, collectSessionIds, confirmIfBusyLocalTerminal, createLocalTerminalWithCurrentShell, editorTabs, fromEditorTabId, handleOpenSettingsRef, handleRequestCloseEditorTabRef, hostsById, isEditorTabId, isPluginViewTabId, isQuickSwitcherOpen, lastMoveFocusTimeRef, moveFocusInWorkspace, orderedTabs, reopenLastClosedTab, resolveCloseIntent, resolveSnippetsShortcutIntent, sessions, setActiveTabId, setAddToWorkspaceDialog, setIsQuickSwitcherOpen, setNavigateToSection, settings, sftpPaneMagnificationRef, splitSessionWithCurrentShell, systemInfoRef, terminalPaneMagnificationRef, toEditorTabId, toggleBroadcast, toggleGlobalBroadcast, toggleHostTree, toggleScriptsSidePanelRef, toggleSidePanelRef, toggleWindowOpacity, workspaces } = getCtx();
{
const shortcutTabs = buildNumberShortcutTabTargets({
showSftpTab: settings.showSftpTab ?? true,
@@ -875,20 +974,16 @@ export function executeHotkeyActionImpl(getCtx: AppContextGetter, action: string
const session = sessions.find((s) => s.id === currentId) ?? null;
const workspace = workspaces.find((w) => w.id === currentId) ?? null;
const focusIsInsideTerminal = !!document.activeElement?.closest('[data-session-id]');
const intent = resolveCloseIntent({
activeTabId: currentId,
workspace: workspace ? { id: workspace.id, focusedSessionId: workspace.focusedSessionId } : null,
sessionForTab: session,
focusIsInsideTerminal,
});
closeTabInFlightRef.current = true;
(async () => {
try {
switch (intent.kind) {
case 'closeTerminal':
case 'closeSingleTab': {
const ok = await confirmIfBusyLocalTerminal([intent.sessionId]);
if (ok) closeSession(intent.sessionId);
@@ -932,7 +1027,11 @@ export function executeHotkeyActionImpl(getCtx: AppContextGetter, action: string
: aliveIds[0];
if (focusedId) {
const ok = await confirmIfBusyLocalTerminal([focusedId]);
if (ok) closeSession(focusedId);
if (ok) {
// The pane shortcut closes the tab when only one pane remains.
if (aliveIds.length === 1) closeWorkspace(workspace.id);
else closeSession(focusedId);
}
}
} else if (session) {
// Standalone session tab — close the session
@@ -962,6 +1061,39 @@ export function executeHotkeyActionImpl(getCtx: AppContextGetter, action: string
});
break;
}
case 'reopenClosedTab': {
const reopened = reopenLastClosedTab?.({
availableHostIds: hostsById ? new Set(hostsById.keys()) : undefined,
hostsById,
});
if (reopened && addConnectionLogRef?.current) {
const reopenedSessions = reopened.kind === 'session'
? [reopened.session]
: reopened.sessions;
const localUsername = systemInfoRef?.current?.username ?? '';
const localHostname = systemInfoRef?.current?.hostname ?? '';
const startTime = Date.now();
for (const reopenedSession of reopenedSessions) {
addConnectionLogRef.current({
sessionId: reopenedSession.id,
hostId: reopenedSession.protocol === 'local' && reopenedSession.hostId === 'local-terminal'
? ''
: reopenedSession.hostId,
hostLabel: reopenedSession.hostLabel,
hostname: reopenedSession.hostname,
username: reopenedSession.protocol === 'local'
? localUsername
: reopenedSession.username,
protocol: reopenedSession.protocol || 'ssh',
startTime,
localUsername,
localHostname,
saved: false,
});
}
}
break;
}
case 'openHosts':
setActiveTabId('vault');
break;
+22 -8
View File
@@ -1,9 +1,10 @@
import React, { memo, useMemo } from 'react';
import React, { memo, useMemo, useRef } from 'react';
import { useActiveTabId } from '../state/activeTabStore';
import { useAppearanceChromeStore } from '../state/appearanceChromeStore';
import type { EditorTabChrome } from '../state/editorTabStore';
import type { LogView } from '../state/logViewState';
import { useTerminalHostTreeOpen } from '../state/terminalHostTreeStore';
import { useManualTerminalChromeSurfaceInjection } from '../state/useManualTerminalChromeSurfaceInjection';
import { TerminalHostTreeSidebar } from '../../components/terminalLayer/TerminalHostTreeSidebar';
import type {
@@ -93,6 +94,7 @@ const AppHostTreeLayerInner: React.FC<AppHostTreeLayerProps> = ({
onCreateLocalTerminal,
}) => {
const activeTabId = useActiveTabId();
const isHostTreeOpen = useTerminalHostTreeOpen();
const { accentMode, customAccent } = useAppearanceChromeStore();
const sessionIds = useMemo(() => new Set(sessions.map((session) => session.id)), [sessions]);
const workspaceIds = useMemo(() => new Set(workspaces.map((workspace) => workspace.id)), [workspaces]);
@@ -113,13 +115,18 @@ const AppHostTreeLayerInner: React.FC<AppHostTreeLayerProps> = ({
sessionIds,
workspaceIds,
});
const sidebarActive = surfaceVisible && enabled && isHostTreeOpen;
const activeHostId = useMemo(() => resolveWorkTabActiveHostId({
activeTabId,
editorTabs,
sessions,
workspaces,
}), [activeTabId, editorTabs, sessions, workspaces]);
const activeHostId = useMemo(() => (
sidebarActive
? resolveWorkTabActiveHostId({
activeTabId,
editorTabs,
sessions,
workspaces,
})
: undefined
), [activeTabId, editorTabs, sessions, sidebarActive, workspaces]);
const hostTreeTheme = useMemo(() => (
resolveActiveChromeTheme({
@@ -150,6 +157,13 @@ const AppHostTreeLayerInner: React.FC<AppHostTreeLayerProps> = ({
themeById,
workspaceById,
]);
const lastActiveSidebarThemeRef = useRef(hostTreeTheme);
if (sidebarActive) {
lastActiveSidebarThemeRef.current = hostTreeTheme;
}
const sidebarPreviewTheme = sidebarActive
? hostTreeTheme
: lastActiveSidebarThemeRef.current;
useManualTerminalChromeSurfaceInjection(
hostTreeTheme,
@@ -168,7 +182,7 @@ const AppHostTreeLayerInner: React.FC<AppHostTreeLayerProps> = ({
hosts={hosts}
customGroups={customGroups}
groupConfigs={groupConfigs}
resolvedPreviewTheme={hostTreeTheme}
resolvedPreviewTheme={sidebarPreviewTheme}
activeHostId={activeHostId}
onConnect={onConnect}
onNewHost={onNewHost}
+11
View File
@@ -22,6 +22,10 @@ test('visible log view leaves room for the terminal host sidebar', () => {
assert.deepEqual(getLogViewWrapperStyle(true, 220), {
left: 220,
});
assert.deepEqual(getLogViewWrapperStyle(true, 220, true), {
left: 220,
transition: 'left 220ms cubic-bezier(0.4, 0, 0.2, 1)',
});
});
test('hidden log view remains hidden while preserving host sidebar offset', () => {
@@ -76,3 +80,10 @@ test('terminal layer force-mounts immediately when a hidden MCP session exists',
assert.match(appMountsSource, /useState\(isVisible \|\| hasHiddenSession\)/);
assert.match(appMountsSource, /if \(isVisible \|\| hasHiddenSession\) setShouldMount\(true\)/);
});
test('AppMounts narrows active-tab subscriptions instead of using useActiveTabId', () => {
assert.doesNotMatch(appMountsSource, /\buseActiveTabId\b/);
assert.match(appMountsSource, /const isVisible = useIsTabActive\(logView\.id\);/);
assert.match(appMountsSource, /const isTerminalSurfaceActive = useIsTerminalSurfaceActive\(sessionIds, workspaceIds\);/);
assert.match(appMountsSource, /<LazyLoadBoundary name="Terminal" resetKey=\{isVisible \? "active" : "idle"\}>/);
});
+36 -14
View File
@@ -1,6 +1,10 @@
import React, { Suspense, lazy, useEffect, useLayoutEffect, useMemo, useRef, useState } from 'react';
import { useActiveTabId, useIsSftpActive, useIsVaultActive } from '../state/activeTabStore';
import { useTerminalHostTreeLayoutWidth } from '../state/terminalHostTreeStore';
import React, { Suspense, lazy, useCallback, useEffect, useLayoutEffect, useMemo, useRef, useState, useSyncExternalStore } from 'react';
import { activeTabStore, useIsSftpActive, useIsTabActive, useIsVaultActive } from '../state/activeTabStore';
import {
useTerminalHostTreeLayoutTransitionAnimated,
useTerminalHostTreeLayoutWidth,
} from '../state/terminalHostTreeStore';
import { TERMINAL_HOST_TREE_LEFT_TRANSITION } from '../state/terminalHostTreeAnimation';
import { isTerminalContentTabSurface } from './workTabSurface';
import { cn } from '../../lib/utils';
import { ConnectionLog, TerminalTheme } from '../../types';
@@ -68,9 +72,11 @@ interface LogViewWrapperProps {
export function getLogViewWrapperStyle(
isVisible: boolean,
hostTreeLayoutWidth: number,
animateLayout = false,
): React.CSSProperties {
const baseStyle = {
const baseStyle: React.CSSProperties = {
left: hostTreeLayoutWidth,
...(animateLayout ? { transition: TERMINAL_HOST_TREE_LEFT_TRANSITION } : null),
};
return isVisible
? baseStyle
@@ -78,11 +84,15 @@ export function getLogViewWrapperStyle(
}
export const LogViewWrapper: React.FC<LogViewWrapperProps> = ({ logView, defaultTerminalTheme, defaultFontSize, onClose, onUpdateLog }) => {
const activeTabId = useActiveTabId();
const isVisible = activeTabId === logView.id;
const isVisible = useIsTabActive(logView.id);
const hostTreeLayoutWidth = useTerminalHostTreeLayoutWidth();
const hostTreeLayoutAnimated = useTerminalHostTreeLayoutTransitionAnimated();
const containerStyle = getLogViewWrapperStyle(isVisible, hostTreeLayoutWidth);
const containerStyle = getLogViewWrapperStyle(
isVisible,
hostTreeLayoutWidth,
isVisible && hostTreeLayoutAnimated,
);
return (
<div
@@ -163,15 +173,27 @@ export const SftpViewMount: React.FC<SftpViewProps> = (props) => {
);
};
export function useIsTerminalSurfaceActive(
sessionIds: ReadonlySet<string>,
workspaceIds: ReadonlySet<string>,
): boolean {
const getSnapshot = useCallback(
() =>
isTerminalContentTabSurface({
activeTabId: activeTabStore.getActiveTabId(),
sessionIds,
workspaceIds,
}),
[sessionIds, workspaceIds],
);
return useSyncExternalStore(activeTabStore.subscribe, getSnapshot, getSnapshot);
}
export const TerminalLayerMount: React.FC<TerminalLayerProps> = (props) => {
const activeTabId = useActiveTabId();
const sessionIds = useMemo(() => new Set(props.sessions.map((session) => session.id)), [props.sessions]);
const workspaceIds = useMemo(() => new Set(props.workspaces.map((workspace) => workspace.id)), [props.workspaces]);
const isVisible = isTerminalContentTabSurface({
activeTabId,
sessionIds,
workspaceIds,
}) || !!props.draggingSessionId;
const isTerminalSurfaceActive = useIsTerminalSurfaceActive(sessionIds, workspaceIds);
const isVisible = isTerminalSurfaceActive || !!props.draggingSessionId;
// Silent MCP sessions never become the activeTabId, so `isVisible` alone
// would leave this whole layer (and its PTY-starting TerminalPane) unmounted
// for up to 5s (the idle-callback fallback below) after host_open returns —
@@ -203,7 +225,7 @@ export const TerminalLayerMount: React.FC<TerminalLayerProps> = (props) => {
if (!shouldRender) return null;
return (
<LazyLoadBoundary name="Terminal" resetKey={activeTabId}>
<LazyLoadBoundary name="Terminal" resetKey={isVisible ? "active" : "idle"}>
<Suspense fallback={<TerminalLayerFallback visible={isVisible} />}>
<LazyTerminalLayer {...props} />
</Suspense>
@@ -1,28 +0,0 @@
import assert from "node:assert/strict";
import { readFileSync } from "node:fs";
import test from "node:test";
const source = readFileSync(new URL("./AppSideEffects.tsx", import.meta.url), "utf8");
test("open-terminal requests wait behind App Lock and resume after unlock", () => {
const handlerStart = source.indexOf("const _handleOpenTerminalPath");
const handlerEnd = source.indexOf("useEffect(() =>", handlerStart);
const handlerSource = source.slice(handlerStart, handlerEnd);
const drainStart = source.indexOf("const pending = pendingDeepLinksWhileLockedRef.current.splice(0)");
const drainEnd = source.indexOf("}, [appLockLocked]);", drainStart);
const drainSource = source.slice(drainStart, drainEnd);
assert.match(handlerSource, /shouldDeferExternalActionWhileAppLocked/);
assert.match(handlerSource, /kind: 'open-terminal-path'/);
assert.match(drainSource, /_processOpenTerminalPath\(item\.payload\)/);
const processStart = source.indexOf("const _processOpenTerminalPath");
const processSource = source.slice(processStart, handlerStart);
assert.match(processSource, /handleCreateLocalTerminal\(undefined, \{ localStartDir \}\)/);
assert.match(processSource, /resolveShellSetting\(shellSetting, shells\)/);
assert.match(source, /const openTerminalQueueRef = useRef\(createOpenTerminalQueue\(\)\)/);
const enqueueAt = processSource.indexOf("openTerminalQueueRef.current.enqueue(() => {");
const createAt = processSource.indexOf("handleCreateLocalTerminal");
assert.ok(enqueueAt >= 0 && createAt > enqueueAt);
assert.match(processSource, /await ensureDiscoveredShells\(\)/);
});
@@ -1,21 +0,0 @@
import assert from "node:assert/strict";
import { readFileSync } from "node:fs";
import test from "node:test";
const source = readFileSync(new URL("./AppSideEffects.tsx", import.meta.url), "utf8");
test("deep-link tab names are applied to terminal sessions", () => {
assert.match(source, /type DeepLinkPayload = \{[\s\S]*tabName\?: string/);
assert.match(source, /const handleConnectToHostWithTabName = useCallback/);
assert.match(source, /renameSessionInline\(sessionId, tabName\)/);
assert.match(source, /handleConnectToHostWithTabName\(ephemeralHost, tabName\)/);
assert.match(
source,
/handleConnectToHostWithTabName\(buildSshDeepLinkConnectionHost\(originalHost\), tabName\)/,
);
assert.match(
source,
/handleConnectToHostWithTabName\(buildTelnetDeepLinkConnectionHost\(matchedEffectiveHost\), tabName\)/,
);
assert.match(source, /label: tabName/);
});
@@ -1,16 +0,0 @@
import assert from 'node:assert/strict';
import { readFileSync } from 'node:fs';
import test from 'node:test';
const source = readFileSync(new URL('./AppSideEffects.tsx', import.meta.url), 'utf8');
test('quick-switcher Escape handling stays in the bubble phase', () => {
const effectStart = source.indexOf('const onKeyDown = (e: KeyboardEvent) => {\n _handleEscapeKeyDown(e);');
const effectEnd = source.indexOf('}, [appLockLocked]);', effectStart);
const effectSource = source.slice(effectStart, effectEnd);
assert.notEqual(effectStart, -1);
assert.match(effectSource, /window\.addEventListener\('keydown', onKeyDown\)/);
assert.match(effectSource, /window\.removeEventListener\('keydown', onKeyDown\)/);
assert.doesNotMatch(source, /onCaptureKeyDown/);
});
@@ -1,30 +0,0 @@
import assert from "node:assert/strict";
import test from "node:test";
import { readFileSync } from "node:fs";
const source = readFileSync(new URL("./AppSideEffects.tsx", import.meta.url), "utf8");
test("snippets delete handler cleans host bindings via deleteSelectedSnippets", () => {
assert.match(source, /collectSnippetDeleteIds/);
assert.match(source, /deleteSelectedSnippets/);
assert.match(
source,
/netcatty:snippets:delete[\s\S]*void deleteSelectedSnippets\(ids\)/,
);
assert.doesNotMatch(
source,
/updateSnippets\(snippets\.filter\(\(s\) => !ids\.has\(s\.id\)\)\)/,
);
});
test("snippets delete handler uses vault live snapshot instead of component refs", () => {
// Component-level snippetsRef/hostsRef lag concurrent vault mutations that
// already advanced useVaultState refs before React re-renders AppSideEffects.
// Deletion must go through the vault hook's atomic live-snapshot path.
assert.match(source, /deleteSelectedSnippets,/);
assert.doesNotMatch(source, /snippetsRef\.current\s*=\s*snippets/);
assert.doesNotMatch(
source,
/deleteSelectedSnippetsFromVault\(\s*snippetsRef\.current/,
);
});
@@ -1,21 +0,0 @@
import assert from "node:assert/strict";
import { readFileSync } from "node:fs";
import test from "node:test";
const source = readFileSync(new URL("./AppSideEffects.tsx", import.meta.url), "utf8");
test("handleConnectToHost reads temporary connection settings at call time", () => {
assert.match(source, /const temporaryConnectionSettingsRef = useRef\(terminalSettings\)/);
assert.match(source, /temporaryConnectionSettingsRef\.current = terminalSettings/);
const handlerStart = source.indexOf("const handleConnectToHost = useCallback");
const handlerEnd = source.indexOf("const handleConnectToHostWithTabName");
assert.ok(handlerStart >= 0 && handlerEnd > handlerStart);
const handler = source.slice(handlerStart, handlerEnd);
assert.match(handler, /temporaryConnectionSettingsRef\.current/);
assert.match(handler, /temporaryConnectionPrepareOptions\(liveTerminalSettings\)/);
assert.match(handler, /terminalSettings: liveTerminalSettings/);
assert.doesNotMatch(handler, /terminalSettings\.temporaryConnections/);
assert.doesNotMatch(handler, /\[addConnectionLog, connectToHost, resolveEffectiveHost, identities, keys, discoveredShells, terminalSettings\]/);
});
@@ -1,28 +0,0 @@
import assert from 'node:assert/strict';
import { readFileSync } from 'node:fs';
import { dirname, join } from 'node:path';
import { fileURLToPath } from 'node:url';
import test from 'node:test';
const here = dirname(fileURLToPath(import.meta.url));
const appSideEffectsSource = readFileSync(join(here, 'AppSideEffects.tsx'), 'utf8');
test('terminal keyboard focus tracking is always published to the main process', () => {
assert.match(
appSideEffectsSource,
/useTerminalKeyboardFocus\(\s*\)/,
'the terminal keyboard focus signal must be unconditional',
);
});
test('terminal keyboard focus is not gated on hotkey scheme or font zoom settings', () => {
// When the signal is turned off, the main process falls back to window zoom
// for Ctrl+= / Ctrl+- / Ctrl+0 while the user is typing in a terminal, so
// "disable terminal zoom" and per-binding overrides stop having any effect
// on those chords (#3327).
assert.doesNotMatch(appSideEffectsSource, /useTerminalKeyboardFocus\(\s*hotkeyScheme/);
assert.doesNotMatch(
appSideEffectsSource,
/useTerminalKeyboardFocus\(\s*[^)\s][^)]*disableTerminalFontZoom/,
);
});
+38 -10
View File
@@ -47,7 +47,7 @@ import { materializeHostProxyProfile } from '../../domain/proxyProfiles';
import { useVaultHostDeletion } from '../state/useVaultHostDeletion';
import { buildSshDeepLinkConnectionHost, buildSshDeepLinkEphemeralHost, buildSshDeepLinkEphemeralHostFromSaved, buildSshDeepLinkHostDraft, findSshDeepLinkHost, parseSshDeepLink } from '../../domain/sshDeepLink';
import { buildTelnetDeepLinkConnectionHost, buildTelnetDeepLinkEphemeralHostFromSaved, buildTelnetDeepLinkOpenHost, findTelnetDeepLinkHost, materializeTelnetDeepLinkMatchHost, parseTelnetDeepLink } from '../../domain/telnetDeepLink';
import { buildJmsDeepLinkEphemeralHost, isSupportedJmsProtocol, parseJmsDeepLink } from '../../domain/jmsDeepLink';
import { buildJmsDeepLinkEphemeralHost, parseJmsDeepLinkResult } from '../../domain/jmsDeepLink';
import { applyEphemeralHostDistroUpdate, applyEphemeralHostsUpdate, splitHostsUpdateByEphemeral } from '../../domain/ephemeralHosts';
import { prepareConnectionHost, temporaryConnectionPrepareOptions } from '../../domain/legacyAlgorithms';
import { resolveHostAuth } from '../../domain/sshAuth';
@@ -104,7 +104,7 @@ import { collectSnippetDeleteIds } from '../../domain/snippetSelection.ts';
import { shouldOpenLocalTerminalOnStartup, resolveStartupLandingSetting } from '../../domain/startupLanding';
import { createOpenTerminalQueue } from './openTerminalQueue';
import { useAppStartupEffects } from './useAppStartupEffects';
import { handleTrayJumpToSessionImpl, handleTrayTogglePortForwardImpl, handleTrayPanelConnectImpl, handleTrayPanelConnectRequestImpl, flushQueuedTrayPanelConnectHostsImpl, handleGlobalHotkeyKeyDownImpl, handleEscapeKeyDownImpl, handleKeyboardInteractiveSubmitImpl, handleKeyboardInteractiveCancelImpl, handlePassphraseSubmitImpl, handlePassphraseCancelImpl, handlePassphraseSkipImpl, handleFidoPromptSubmitImpl, handleFidoPromptCancelImpl, createLocalTerminalWithCurrentShellImpl, splitSessionWithCurrentShellImpl, copySessionWithCurrentShellImpl, duplicateSessionWithCurrentShellImpl, copyWorkspaceWithCurrentShellImpl, copySessionToNewWindowWithCurrentShellImpl, confirmIfBusyLocalTerminalImpl, closeTabsBatchImpl, executeHotkeyActionImpl, handleCreateLocalTerminalImpl, handleConnectToHostImpl, handleTerminalDataCaptureImpl, startRestoredSessionConnectionLogImpl, hasMultipleProtocolsImpl, handleHostConnectWithProtocolCheckImpl, handleProtocolSelectImpl, handleRootContextMenuImpl, markForwardedNativeShortcutEvent } from './AppHandlers';
import { handleTrayJumpToSessionImpl, handleTrayTogglePortForwardImpl, handleTrayPanelConnectImpl, handleTrayPanelConnectRequestImpl, flushQueuedTrayPanelConnectHostsImpl, handleGlobalHotkeyKeyDownImpl, handleEscapeKeyDownImpl, handleKeyboardInteractiveSubmitImpl, handleKeyboardInteractiveCancelImpl, handlePassphraseSubmitImpl, handlePassphraseCancelImpl, handlePassphraseSkipImpl, handleFidoPromptSubmitImpl, handleFidoPromptCancelImpl, createLocalTerminalWithCurrentShellImpl, splitSessionWithCurrentShellImpl, copySessionWithCurrentShellImpl, duplicateSessionWithCurrentShellImpl, copyWorkspaceWithCurrentShellImpl, copySessionToNewWindowWithCurrentShellImpl, moveSessionToNewWindowImpl, confirmIfBusyLocalTerminalImpl, closeTabsBatchImpl, executeHotkeyActionImpl, handleCreateLocalTerminalImpl, handleConnectToHostImpl, handleTerminalDataCaptureImpl, startRestoredSessionConnectionLogImpl, hasMultipleProtocolsImpl, handleHostConnectWithProtocolCheckImpl, handleProtocolSelectImpl, handleRootContextMenuImpl, markForwardedNativeShortcutEvent } from './AppHandlers';
type OpenSessionInNewWindowPayload = {
title?: string;
@@ -264,6 +264,7 @@ export function AppSideEffects() {
closeSession,
closeSessions,
closeWorkspace,
reopenLastClosedTab,
updateSessionStatus,
createWorkspaceWithHosts,
createWorkspaceFromTargets,
@@ -283,6 +284,7 @@ export function AppSideEffects() {
createSessionFromCloneSource,
getSessionRestoreCwd,
renameSessionInline,
setSessionPoppedOut,
} = sessionState;
// Presence-only list: keystrokes must not rebuild App domains / TopTabs structure.
@@ -292,6 +294,8 @@ export function AppSideEffects() {
() => new Map(hosts.map((host) => [host.id, host])),
[hosts],
);
const hostByIdRef = useRef(hostById);
hostByIdRef.current = hostById;
const terminalHosts = useMemo(
() => (ephemeralHosts.length > 0 ? [...hosts, ...ephemeralHosts] : hosts),
[hosts, ephemeralHosts],
@@ -604,6 +608,7 @@ export function AppSideEffects() {
sessionId,
sessions,
setActiveTabId,
setSessionPoppedOut,
setWorkspaceFocusedSession,
getActiveTabId: () => activeTabStore.getActiveTabId(),
netcattyBridge,
@@ -1027,6 +1032,24 @@ export function AppSideEffects() {
const copySessionToNewWindowWithCurrentShell = useCallback((sessionId: string) => { return copySessionToNewWindowWithCurrentShellImpl(() => ({ classifyLocalShellType, discoveredShells, netcattyBridge, resolveShellSetting, sessions, terminalSettings, t, toast }), sessionId); }, [sessions, terminalSettings, discoveredShells, t]);
const moveSessionToNewWindow = useCallback((sessionId: string) => {
return moveSessionToNewWindowImpl(() => ({
getActiveTabId: () => activeTabStore.getActiveTabId(),
getOrderedTabs: () => orderedTabsRef.current,
netcattyBridge,
sessions: Array.from(sessionByIdRef.current.values()),
setActiveTabId,
setSessionPoppedOut,
t,
toast,
}), sessionId);
}, [setActiveTabId, setSessionPoppedOut, t]);
// A tab moved to its own window returns to the tab bar when that window closes.
useEffect(() => netcattyBridge.get()?.onTerminalPopupAttachClosed?.(({ sessionId }) => {
setSessionPoppedOut(sessionId, false);
}), [setSessionPoppedOut]);
const closeTabKeyStr = useMemo(() => {
if (hotkeyScheme === 'disabled') return null;
const closeTabBinding = keyBindings.find((binding) => binding.action === 'closeTab');
@@ -1108,12 +1131,14 @@ export function AppSideEffects() {
fromEditorTabId,
handleOpenSettingsRef,
handleRequestCloseEditorTabRef,
hostsById: hostByIdRef.current,
isEditorTabId,
isPluginViewTabId,
isQuickSwitcherOpen: isQuickSwitcherOpenRef.current,
lastMoveFocusTimeRef,
moveFocusInWorkspace,
orderedTabs: orderedTabsRef.current,
reopenLastClosedTab,
resolveCloseIntent,
resolveSnippetsShortcutIntent,
sessions: sessionsRef.current,
@@ -1145,6 +1170,7 @@ export function AppSideEffects() {
closePluginViewTab,
closeSession,
closeWorkspace,
reopenLastClosedTab,
createLocalTerminalWithCurrentShell,
splitSessionWithCurrentShell,
moveFocusInWorkspace,
@@ -1734,16 +1760,16 @@ export function AppSideEffects() {
const _processJmsDeepLink = useEffectEvent((payload: { url?: string }) => {
startupLaunchIntentReceivedRef.current = true;
const rawUrl = payload?.url || '';
const target = parseJmsDeepLink(rawUrl);
if (!target) {
toast.warning(t('deepLink.jms.invalid'));
const result = parseJmsDeepLinkResult(rawUrl);
if (result.ok === false) {
if (result.reason === 'unsupported_protocol') {
toast.warning(t('deepLink.jms.unsupported', { protocol: result.protocol }));
} else {
toast.warning(t('deepLink.jms.invalid'));
}
return;
}
if (!isSupportedJmsProtocol(target.protocol)) {
toast.warning(t('deepLink.jms.unsupported', { protocol: target.protocol }));
return;
}
const ephemeralHost = buildJmsDeepLinkEphemeralHost(target, {
const ephemeralHost = buildJmsDeepLinkEphemeralHost(result.target, {
id: crypto.randomUUID(),
now: Date.now(),
});
@@ -2071,6 +2097,7 @@ export function AppSideEffects() {
duplicateSessionWithCurrentShell,
copyWorkspaceWithCurrentShell,
copySessionToNewWindowWithCurrentShell,
moveSessionToNewWindow,
createWorkspaceFromTargets: createWorkspaceFromEffectiveTargets,
createWorkspaceWithHosts: createWorkspaceWithEffectiveHosts,
handleConnectSerial,
@@ -2149,6 +2176,7 @@ export function AppSideEffects() {
duplicateSessionWithCurrentShell,
copyWorkspaceWithCurrentShell,
copySessionToNewWindowWithCurrentShell,
moveSessionToNewWindow,
createWorkspaceFromEffectiveTargets,
createWorkspaceWithEffectiveHosts,
handleConnectSerial,
@@ -1,23 +0,0 @@
import test from "node:test";
import assert from "node:assert/strict";
import { readFileSync } from "node:fs";
const appViewSource = readFileSync(new URL("./AppView.tsx", import.meta.url), "utf8");
const pluginHostSource = readFileSync(new URL("./AppPluginKeybindingHost.tsx", import.meta.url), "utf8");
const editorSurfaceSource = readFileSync(new URL("./AppHostEditorSurface.tsx", import.meta.url), "utf8");
test("AppView shell does not subscribe to useActiveTabId", () => {
// Top-tab switches must not rebuild the AppView shell. Leaves own the subscription.
assert.doesNotMatch(appViewSource, /useActiveTabId\s*\(/);
assert.doesNotMatch(appViewSource, /useActiveTabId/);
// Still uses activeTabStore for imperative tab close / neighbor activation.
assert.match(appViewSource, /activeTabStore/);
});
test("plugin keybindings and host-editor surface subscribe as leaves", () => {
assert.match(pluginHostSource, /useActiveTabId/);
assert.match(pluginHostSource, /resolveActivePluginKeybindingContext/);
assert.match(editorSurfaceSource, /useWorkSurfaceVisible/);
assert.match(editorSurfaceSource, /useActiveTabId/);
assert.match(appViewSource, /AppPluginKeybindingHost/);
});
+14 -4
View File
@@ -5,7 +5,11 @@ import { activeTabStore, toEditorTabId, useIsEditorTabActive } from '../state/ac
import { editorTabStore, tabIsDirty } from '../state/editorTabStore';
import { releaseEditorTabSaveCoordinator, saveEditorTab } from '../state/editorTabSave';
import { focusEditorInWindow, popOutEditorTab } from '../state/editorWindowClient';
import { useTerminalHostTreeLayoutWidth } from '../state/terminalHostTreeStore';
import {
useTerminalHostTreeLayoutTransitionAnimated,
useTerminalHostTreeLayoutWidth,
} from '../state/terminalHostTreeStore';
import { TERMINAL_HOST_TREE_LEFT_TRANSITION } from '../state/terminalHostTreeAnimation';
import { TopTabs } from '../../components/TopTabs';
import { VaultView } from '../../components/VaultView';
import { QuickAddSnippetDialog } from '../../components/QuickAddSnippetDialog';
@@ -67,12 +71,16 @@ const focusEditorWindowTab = (id: string) => { void focusEditorInWindow(id); };
const TextEditorTabFallback = ({ tabId }: { tabId: string }) => {
const isVisible = useIsEditorTabActive(tabId);
const hostTreeLayoutWidth = useTerminalHostTreeLayoutWidth();
const hostTreeLayoutAnimated = useTerminalHostTreeLayoutTransitionAnimated();
return (
<div
style={{
...(isVisible ? null : { pointerEvents: 'none', visibility: 'hidden' }),
zIndex: 20,
left: hostTreeLayoutWidth,
...(isVisible && hostTreeLayoutAnimated
? { transition: TERMINAL_HOST_TREE_LEFT_TRANSITION }
: null),
}}
className="netcatty-lazy-fade-in absolute top-0 right-0 bottom-0 min-h-0 flex flex-col bg-background"
aria-hidden="true"
@@ -265,7 +273,7 @@ function AppViewInner({ domains }: AppViewProps) {
const {
addShellHistoryEntry, clearAllCommandHistory, removeShellHistoryEntry, addSessionToWorkspace, addToWorkspaceDialog, appendHostToWorkspace, appendLocalTerminalToWorkspace, moveWorkspacePane,
clearAndRemoveSource, clearAndRemoveSources, closeLogView, closeSession, closeTabsBatch, closeWorkspace, commitPluginImporterData, commitVaultImportTransaction, commitVaultGroupMutation, copySessionToNewWindowWithCurrentShell, copySessionWithCurrentShell, duplicateSessionWithCurrentShell, copyWorkspaceWithCurrentShell,
clearAndRemoveSource, clearAndRemoveSources, closeLogView, closeSession, closeTabsBatch, closeWorkspace, commitPluginImporterData, commitVaultImportTransaction, commitVaultGroupMutation, copySessionToNewWindowWithCurrentShell, moveSessionToNewWindow, copySessionWithCurrentShell, duplicateSessionWithCurrentShell, copyWorkspaceWithCurrentShell,
convertKnownHostToHost, createWorkspaceFromSessions, createWorkspaceFromTargets, createWorkspaceWithHosts,
customGroups, currentTerminalTheme, deepLinkHostDraft, draggingSessionId, effectiveKnownHosts, editorTabs, editorWordWrap, emptyVaultConflict,
followAppTerminalTheme,
@@ -278,7 +286,7 @@ function AppViewInner({ domains }: AppViewProps) {
passphraseQueue, fidoPromptQueue, protocolSelectHost, proxyProfiles, portForwardingRules, removeSessionFromWorkspace, reorderWorkTabs, reorderWorkspaceSessions,
resolveEmptyVaultConflict, resolveSessionAppearance, runSnippet, sessionLogsDir, sessionLogsEnabled, sessionLogsFormat, sessionLogsTimestampsEnabled, sessionRenameTarget, sshDebugLogsEnabled,
sessions, setActiveTabId, setDeepLinkHostDraft, setDraggingSessionId, setEditorWordWrap,
setNavigateToSection, setTerminalFontFamilyId, setTerminalFontSize, setVaultFocusRequest, updateSessionFontSize, updateSessionRestoreCwd, updateSessionDynamicTitle, updateSessionCodingCliProvider, clearSessionFontSizeOverride,
setNavigateToSection, setTerminalFontFamilyId, setTerminalFontSize, setVaultFocusRequest, updateSessionFontSize, updateSessionRestoreCwd, updateSessionDynamicTitle, updateSessionPromptHost, updateSessionCodingCliProvider, clearSessionFontSizeOverride,
setWorkspaceFocusedSession, setWorkspaceAnchorChat, sftpAutoOpenSidebar, sftpFollowTerminalCwd, setSftpFollowTerminalCwd, sftpAutoSync, sftpDefaultViewMode, sftpDoubleClickBehavior,
sftpShowHiddenFiles, sftpUseCompressedUpload, snippetPackages, snippets, splitSessionWithCurrentShell, startSessionRename,
startWorkspaceRename, submitSessionRename, submitWorkspaceRename, t, terminalFontFamilyId, terminalFontSize, terminalSettings, terminalThemeId, themeById,
@@ -560,6 +568,7 @@ function AppViewInner({ domains }: AppViewProps) {
onDuplicateSession={duplicateSessionWithCurrentShell}
tabDoubleClickBehavior={terminalSettings.tabDoubleClickBehavior}
onCopySessionToNewWindow={copySessionToNewWindowWithCurrentShell}
onMoveSessionToNewWindow={moveSessionToNewWindow}
onEditHost={handleEditHostFromOverlay}
onRenameWorkspace={startWorkspaceRename}
onCopyWorkspace={copyWorkspaceWithCurrentShell}
@@ -652,7 +661,7 @@ function AppViewInner({ domains }: AppViewProps) {
customGroups={customGroups}
knownHosts={effectiveKnownHosts}
managedSources={managedSources}
sessionCount={sessions.filter((s) => !s.hiddenFromTabs).length}
sessionCount={sessions.filter((s) => !s.hiddenFromTabs || s.poppedOut).length}
hotkeyScheme={hotkeyScheme}
keyBindings={keyBindings}
terminalThemeId={terminalThemeId}
@@ -760,6 +769,7 @@ function AppViewInner({ domains }: AppViewProps) {
onUpdateSessionFontSize={updateSessionFontSize}
onUpdateSessionRestoreCwd={updateSessionRestoreCwd}
onUpdateSessionDynamicTitle={updateSessionDynamicTitle}
onUpdateSessionPromptHost={updateSessionPromptHost}
onUpdateSessionCodingCliProvider={updateSessionCodingCliProvider}
onClearSessionFontSizeOverride={clearSessionFontSizeOverride}
onUpdateTerminalFontWeight={handleUpdateTerminalFontWeight}
@@ -1,19 +0,0 @@
import assert from 'node:assert/strict';
import { readFileSync } from 'node:fs';
import test from 'node:test';
const source = readFileSync(new URL('./AppView.tsx', import.meta.url), 'utf8');
test('workspace append resolves group defaults before creating host sessions', () => {
assert.match(source, /resolveEffectiveTerminalHost\(\{/);
assert.match(source, /groupConfigs,/);
assert.match(source, /proxyProfiles,/);
assert.match(
source,
/appendHostToWorkspace\(workspaceId, resolveWorkspaceAppendHost\(host\), rootDir\)/,
);
assert.match(
source,
/appendHostToWorkspace\([\s\S]*?resolveWorkspaceAppendHost\(target\.host\),[\s\S]*?rootDir/,
);
});
+1 -1
View File
@@ -2,7 +2,7 @@ import React, { Suspense, lazy, useMemo, useState } from 'react';
import type { QuickSwitcherProps } from '../../components/QuickSwitcher';
import { LazyLoadBoundary } from '../../components/ui/lazy-load-boundary';
import { getHostSearchMatch } from '../../lib/searchMatcher';
import { getHostSearchMatch } from '../../domain/searchMatcher';
import type { Host } from '../../types';
const LazyQuickSwitcher = lazy(() =>
-4
View File
@@ -84,10 +84,6 @@ class AppShellPropsStore {
export const appShellPropsStore = new AppShellPropsStore();
export function publishAppShellDomains(domains: AppViewDomains): void {
appShellPropsStore.setDomains(domains);
}
export function publishAppShellDomainSlice<K extends keyof AppViewDomains>(
key: K,
slice: AppViewDomains[K],
+2
View File
@@ -179,6 +179,7 @@ export function TerminalHost() {
copySessionWithCurrentShell: handlers.copySessionWithCurrentShell,
copyWorkspaceWithCurrentShell: handlers.copyWorkspaceWithCurrentShell,
copySessionToNewWindowWithCurrentShell: handlers.copySessionToNewWindowWithCurrentShell,
moveSessionToNewWindow: handlers.moveSessionToNewWindow,
duplicateSessionWithCurrentShell: handlers.duplicateSessionWithCurrentShell,
closeWorkspace: sessionActions?.closeWorkspace,
createWorkspaceFromSessions: sessionActions?.createWorkspaceFromSessions,
@@ -256,6 +257,7 @@ export function TerminalHost() {
updateSessionFontSize: sessionActions?.updateSessionFontSize,
updateSessionRestoreCwd: sessionActions?.updateSessionRestoreCwd,
updateSessionDynamicTitle: sessionActions?.updateSessionDynamicTitle,
updateSessionPromptHost: sessionActions?.updateSessionPromptHost,
updateSessionCodingCliProvider: sessionActions?.updateSessionCodingCliProvider,
updateTerminalSetting: terminalSettingsActions?.updateTerminalSetting,
workspaces: session.workspaces,
@@ -0,0 +1,760 @@
import assert from 'node:assert/strict';
import test from 'node:test';
import type { ComponentProps } from 'react';
import { JSDOM } from 'jsdom';
import type { Host, TerminalSession, Workspace } from '../../types';
function setupDom() {
const dom = new JSDOM('<!doctype html><html><body><div id="root"></div></body></html>', {
pretendToBeVisual: true,
url: 'http://localhost',
});
const previous = new Map<string, PropertyDescriptor | undefined>();
const install = (key: string, value: unknown) => {
previous.set(key, Object.getOwnPropertyDescriptor(globalThis, key));
Object.defineProperty(globalThis, key, { configurable: true, writable: true, value });
};
for (const key of [
'window',
'document',
'navigator',
'HTMLElement',
'Element',
'Node',
'MutationObserver',
'CustomEvent',
'Event',
'DOMException',
]) {
install(key, key === 'window' ? dom.window : dom.window[key as keyof typeof dom.window]);
}
install('localStorage', dom.window.localStorage);
install('getComputedStyle', dom.window.getComputedStyle.bind(dom.window));
install('requestAnimationFrame', (cb: FrameRequestCallback) => setTimeout(() => cb(Date.now()), 0) as unknown as number);
install('cancelAnimationFrame', (id: number) => clearTimeout(id));
install(
'ResizeObserver',
class ResizeObserver {
observe() {}
unobserve() {}
disconnect() {}
},
);
install('IS_REACT_ACT_ENVIRONMENT', true);
return {
dom,
cleanup() {
dom.window.close();
for (const [key, descriptor] of previous) {
if (descriptor) {
Object.defineProperty(globalThis, key, descriptor);
} else {
Reflect.deleteProperty(globalThis, key);
}
}
},
};
}
const flushTabStore = () => new Promise<void>((resolve) => setTimeout(resolve, 25));
async function waitForAct(
act: (fn: () => Promise<void>) => Promise<void>,
condition: () => boolean,
timeoutMs = 3000,
) {
const deadline = Date.now() + timeoutMs;
while (!condition()) {
if (Date.now() >= deadline) {
throw new Error('Timed out waiting for condition');
}
await act(async () => {
await new Promise<void>((resolve) => setTimeout(resolve, 15));
});
}
}
const makeSession = (id: string, hostId: string): TerminalSession => ({
id,
hostId,
hostLabel: `host-${hostId}`,
username: 'root',
hostname: `${hostId}.example.com`,
status: 'connected',
});
const makeWorkspace = (id: string, sessionId: string): Workspace => ({
id,
title: `Workspace ${id}`,
focusedSessionId: sessionId,
root: { id: `pane-${id}`, type: 'pane', sessionId },
});
const makeHost = (id: string): Host => ({
id,
label: `host-${id}`,
hostname: `${id}.example.com`,
port: 22,
username: 'root',
authMethod: 'password',
tags: [],
os: 'linux',
});
test('usePluginVaultPages does not re-render on non-vault tab switches while preserving active state', async () => {
const env = setupDom();
const { act } = await import('react');
const { createRoot } = await import('react-dom/client');
const { activeTabStore } = await import('../state/activeTabStore');
const { usePluginVaultPages } = await import('../state/usePluginVaultPages');
const previousTabId = activeTabStore.getActiveTabId();
Object.assign(env.dom.window, {
netcatty: {
async getPluginRuntimeStatus() {
return { available: true };
},
async getPluginContributions() {
return { locale: 'en', plugins: [] };
},
onPluginContributionsChanged() {
return () => {};
},
},
});
let renders = 0;
let lastActive: boolean | null = null;
const select = () => {};
function Harness() {
renders += 1;
const model = usePluginVaultPages({ locale: 'en', section: 'hosts', select });
lastActive = model.active;
return <div data-active={String(model.active)} />;
}
const root = createRoot(document.getElementById('root')!);
try {
activeTabStore.setActiveTabId('session-1');
await flushTabStore();
await act(async () => {
root.render(<Harness />);
await flushTabStore();
});
assert.equal(lastActive, false);
const settledRenders = renders;
// Switching between terminal tabs and other non-vault tabs must cause 0 re-renders.
await act(async () => {
activeTabStore.setActiveTabId('session-2');
await flushTabStore();
});
await act(async () => {
activeTabStore.setActiveTabId('workspace-1');
await flushTabStore();
});
await act(async () => {
activeTabStore.setActiveTabId('sftp');
await flushTabStore();
});
assert.equal(renders, settledRenders);
assert.equal(lastActive, false);
// Switching to vault flips active to true with exactly 1 render.
await act(async () => {
activeTabStore.setActiveTabId('vault');
await flushTabStore();
});
assert.equal(renders, settledRenders + 1);
assert.equal(lastActive, true);
// Switching back to a terminal tab flips active back to false.
await act(async () => {
activeTabStore.setActiveTabId('session-1');
await flushTabStore();
});
assert.equal(renders, settledRenders + 2);
assert.equal(lastActive, false);
} finally {
await act(async () => {
root.unmount();
await flushTabStore();
});
activeTabStore.setActiveTabId(previousTabId, { recordPrevious: false });
env.cleanup();
}
});
test('useShowHostTreeToggle and TopTabs avoid re-renders when switching between two terminal tabs', async () => {
const env = setupDom();
const { act } = await import('react');
const { createRoot } = await import('react-dom/client');
const { activeTabStore } = await import('../state/activeTabStore');
const { TopTabs, useShowHostTreeToggle } = await import('../../components/TopTabs');
const { I18nProvider } = await import('../i18n/I18nProvider');
const { TooltipProvider } = await import('../../components/ui/tooltip');
const previousTabId = activeTabStore.getActiveTabId();
const session1 = makeSession('session-1', 'h1');
const session2 = makeSession('session-2', 'h2');
const workspace1 = makeWorkspace('workspace-1', 'session-1');
const hosts = [makeHost('h1'), makeHost('h2')];
const hostById = new Map(hosts.map((h) => [h.id, h]));
const sessions = [session1, session2];
const orphanSessions = [session1, session2];
const workspaces = [workspace1];
const logViews: never[] = [];
const orderedTabs = ['session-1', 'session-2', 'workspace-1'];
const editorTabs: never[] = [];
const pluginViewTabs: never[] = [];
const sessionIds = new Set(['session-1', 'session-2']);
const workspaceIds = new Set(['workspace-1']);
const logViewIds = new Set(['log-1']);
let selectorRenders = 0;
let lastVisible: boolean | null = null;
function SelectorHarness({ enabled }: { enabled: boolean }) {
selectorRenders += 1;
lastVisible = useShowHostTreeToggle({
enabled,
logViewIds,
orderedTabs,
sessionIds,
workspaceIds,
});
return <div data-show={String(lastVisible)} />;
}
const noop = () => {};
const root = createRoot(document.getElementById('root')!);
try {
// 1. Direct selector test across all tab transitions
activeTabStore.setActiveTabId('session-1');
await flushTabStore();
await act(async () => {
root.render(<SelectorHarness enabled={true} />);
await flushTabStore();
});
assert.equal(lastVisible, true);
const rendersAfterMount = selectorRenders;
for (const nextTab of ['session-2', 'workspace-1', 'log-1', 'editor:file-1', 'session-1']) {
await act(async () => {
activeTabStore.setActiveTabId(nextTab);
await flushTabStore();
});
}
assert.equal(selectorRenders, rendersAfterMount);
assert.equal(lastVisible, true);
await act(async () => {
activeTabStore.setActiveTabId('vault');
await flushTabStore();
});
assert.equal(selectorRenders, rendersAfterMount + 1);
assert.equal(lastVisible, false);
await act(async () => {
activeTabStore.setActiveTabId('sftp');
await flushTabStore();
});
assert.equal(selectorRenders, rendersAfterMount + 1);
assert.equal(lastVisible, false);
await act(async () => {
activeTabStore.setActiveTabId('session-2');
await flushTabStore();
});
assert.equal(selectorRenders, rendersAfterMount + 2);
assert.equal(lastVisible, true);
// Disabled host tree never re-renders on tab switches
await act(async () => {
root.render(<SelectorHarness enabled={false} />);
await flushTabStore();
});
const rendersWhenDisabled = selectorRenders;
await act(async () => {
activeTabStore.setActiveTabId('vault');
await flushTabStore();
});
await act(async () => {
activeTabStore.setActiveTabId('session-1');
await flushTabStore();
});
assert.equal(selectorRenders, rendersWhenDisabled);
assert.equal(lastVisible, false);
// 2. Full TopTabs mount: verify host-tree toggle stays visible across session-1 -> session-2
// and hides when switching to vault.
activeTabStore.setActiveTabId('session-1');
await flushTabStore();
await act(async () => {
root.render(
<I18nProvider locale="en">
<TooltipProvider>
<TopTabs
theme="dark"
themePreference="dark"
hosts={hosts}
sessions={sessions}
orphanSessions={orphanSessions}
workspaces={workspaces}
logViews={logViews}
orderedTabs={orderedTabs}
draggingSessionId={null}
isMacClient={false}
onCloseSession={noop}
onRenameSession={noop}
onCopySession={noop}
onCopySessionToNewWindow={noop}
onRenameWorkspace={noop}
onCopyWorkspace={noop}
onCloseWorkspace={noop}
onCloseLogView={noop}
onCloseTabsBatch={noop}
onOpenQuickSwitcher={noop}
onThemeChange={noop}
onOpenSettings={noop}
externalMcpEnabled={false}
onToggleExternalMcp={noop}
windowOpacity={1}
setWindowOpacity={noop}
onStartSessionDrag={noop}
onEndSessionDrag={noop}
onReorderTabs={noop}
onRemoveSessionFromWorkspace={noop}
showSftpTab={true}
showHostTreeSidebar={true}
switchTabKeyBinding={null}
tabDoubleClickBehavior="copy"
editorTabs={editorTabs}
pluginViewTabs={pluginViewTabs}
onClosePluginViewTab={noop}
onRequestCloseEditorTab={noop}
hostById={hostById}
/>
</TooltipProvider>
</I18nProvider>,
);
});
await waitForAct(
act,
() =>
document
.querySelector('[data-section="top-tabs-host-tree-toggle"]')
?.getAttribute('data-visible') === 'true',
);
const hostTreeToggleSlot = document.querySelector('[data-section="top-tabs-host-tree-toggle"]')!;
assert.equal(hostTreeToggleSlot.getAttribute('data-visible'), 'true');
await act(async () => {
activeTabStore.setActiveTabId('session-2');
await flushTabStore();
});
assert.equal(hostTreeToggleSlot.getAttribute('data-visible'), 'true');
await act(async () => {
activeTabStore.setActiveTabId('vault');
await flushTabStore();
});
await waitForAct(
act,
() => hostTreeToggleSlot.getAttribute('data-visible') === 'false',
);
} finally {
await act(async () => {
root.unmount();
await flushTabStore();
});
activeTabStore.setActiveTabId(previousTabId, { recordPrevious: false });
env.cleanup();
}
});
test('LogViewWrapper does not re-render on unrelated tab switches', async () => {
const env = setupDom();
const { Profiler, act } = await import('react');
const { createRoot } = await import('react-dom/client');
const { activeTabStore } = await import('../state/activeTabStore');
const { LogViewWrapper } = await import('./AppMounts');
const previousTabId = activeTabStore.getActiveTabId();
const logView = {
id: 'log-view-1',
connectionLogId: 'log-1',
log: {
id: 'log-1',
hostId: 'host-1',
hostLabel: 'Prod',
hostname: 'prod.example.com',
username: 'root',
protocol: 'ssh' as const,
startTime: 1,
localUsername: 'local',
localHostname: 'localhost',
saved: false,
terminalData: '',
},
};
const defaultTerminalTheme = {
id: 'default',
name: 'Default',
type: 'dark' as const,
colors: {
background: '#000000',
foreground: '#ffffff',
cursor: '#ffffff',
selection: '#444444',
black: '#000000',
red: '#ff0000',
green: '#00ff00',
yellow: '#ffff00',
blue: '#0000ff',
magenta: '#ff00ff',
cyan: '#00ffff',
white: '#ffffff',
brightBlack: '#888888',
brightRed: '#ff8888',
brightGreen: '#88ff88',
brightYellow: '#ffff88',
brightBlue: '#8888ff',
brightMagenta: '#ff88ff',
brightCyan: '#88ffff',
brightWhite: '#ffffff',
},
};
let commitCount = 0;
const onRender = () => {
commitCount += 1;
};
const onClose = () => {};
const onUpdateLog = () => {};
const originalConsoleError = console.error;
// LazyLogView imports @xterm/xterm/css/xterm.css which is unsupported under Node ESM
// and settles into LazyLoadBoundary's alert fallback; silence that expected boundary log.
console.error = () => {};
const root = createRoot(document.getElementById('root')!);
try {
activeTabStore.setActiveTabId('session-1');
await flushTabStore();
await act(async () => {
root.render(
<Profiler id="log-view-wrapper" onRender={onRender}>
<LogViewWrapper
logView={logView}
defaultTerminalTheme={defaultTerminalTheme}
defaultFontSize={14}
onClose={onClose}
onUpdateLog={onUpdateLog}
/>
</Profiler>,
);
});
await waitForAct(act, () => document.querySelector('[role="alert"]') !== null);
const commitsAfterMount = commitCount;
const container = document.getElementById('root')!.firstElementChild as HTMLElement;
assert.equal(container.getAttribute('data-inactive-app-surface'), 'true');
// Switching between two terminal tabs and vault must cause 0 re-renders of LogViewWrapper.
await act(async () => {
activeTabStore.setActiveTabId('session-2');
await flushTabStore();
});
await act(async () => {
activeTabStore.setActiveTabId('vault');
await flushTabStore();
});
assert.equal(commitCount, commitsAfterMount);
assert.equal(container.getAttribute('data-inactive-app-surface'), 'true');
// Activating this log view re-renders it and reveals the surface.
await act(async () => {
activeTabStore.setActiveTabId(logView.id);
await flushTabStore();
});
assert.equal(commitCount, commitsAfterMount + 1);
assert.equal(container.getAttribute('data-inactive-app-surface'), null);
// Leaving this log view hides it again.
await act(async () => {
activeTabStore.setActiveTabId('session-1');
await flushTabStore();
});
assert.equal(commitCount, commitsAfterMount + 2);
assert.equal(container.getAttribute('data-inactive-app-surface'), 'true');
} finally {
console.error = originalConsoleError;
await act(async () => {
root.unmount();
await flushTabStore();
});
activeTabStore.setActiveTabId(previousTabId, { recordPrevious: false });
env.cleanup();
}
});
test('useIsTerminalSurfaceActive and TerminalLayerMount avoid re-renders on terminal-to-terminal switches', async () => {
const env = setupDom();
const { Profiler, act } = await import('react');
const { createRoot } = await import('react-dom/client');
const { activeTabStore } = await import('../state/activeTabStore');
const { TerminalLayerMount, useIsTerminalSurfaceActive } = await import('./AppMounts');
const previousTabId = activeTabStore.getActiveTabId();
const sessions = [makeSession('session-1', 'h1'), makeSession('session-2', 'h2')];
const workspaces = [makeWorkspace('workspace-1', 'session-1')];
const sessionIds = new Set(['session-1', 'session-2']);
const workspaceIds = new Set(['workspace-1']);
let renders = 0;
let lastActive: boolean | null = null;
function Harness() {
renders += 1;
lastActive = useIsTerminalSurfaceActive(sessionIds, workspaceIds);
return <div data-terminal-active={String(lastActive)} />;
}
const originalConsoleError = console.error;
console.error = () => {};
const root = createRoot(document.getElementById('root')!);
try {
activeTabStore.setActiveTabId('session-1');
await flushTabStore();
await act(async () => {
root.render(<Harness />);
await flushTabStore();
});
assert.equal(lastActive, true);
const rendersAfterMount = renders;
// Switching between two terminal sessions and a workspace keeps surface active -> 0 re-renders.
await act(async () => {
activeTabStore.setActiveTabId('session-2');
await flushTabStore();
});
await act(async () => {
activeTabStore.setActiveTabId('workspace-1');
await flushTabStore();
});
assert.equal(renders, rendersAfterMount);
assert.equal(lastActive, true);
// Switching to vault flips active true -> false (1 re-render).
await act(async () => {
activeTabStore.setActiveTabId('vault');
await flushTabStore();
});
assert.equal(renders, rendersAfterMount + 1);
assert.equal(lastActive, false);
// Switching vault -> sftp -> log view keeps surface inactive -> 0 re-renders.
await act(async () => {
activeTabStore.setActiveTabId('sftp');
await flushTabStore();
});
await act(async () => {
activeTabStore.setActiveTabId('log-1');
await flushTabStore();
});
assert.equal(renders, rendersAfterMount + 1);
assert.equal(lastActive, false);
// Returning to a terminal tab flips false -> true (1 re-render).
await act(async () => {
activeTabStore.setActiveTabId('session-2');
await flushTabStore();
});
assert.equal(renders, rendersAfterMount + 2);
assert.equal(lastActive, true);
// Verify TerminalLayerMount itself does not re-render on session-1 -> session-2 -> workspace-1
let mountCommits = 0;
activeTabStore.setActiveTabId('session-1');
await flushTabStore();
await act(async () => {
root.render(
<Profiler
id="terminal-layer-mount"
onRender={() => {
mountCommits += 1;
}}
>
<TerminalLayerMount
{...({
sessions,
workspaces,
draggingSessionId: null,
} as unknown as ComponentProps<typeof TerminalLayerMount>)}
/>
</Profiler>,
);
});
await waitForAct(act, () => document.querySelector('[role="alert"]') !== null);
const commitsAfterTerminalMount = mountCommits;
await act(async () => {
activeTabStore.setActiveTabId('session-2');
await flushTabStore();
});
await act(async () => {
activeTabStore.setActiveTabId('workspace-1');
await flushTabStore();
});
assert.equal(mountCommits, commitsAfterTerminalMount);
// Switching away to vault flips isVisible (and LazyLoadBoundary resetKey) and triggers a re-render.
await act(async () => {
activeTabStore.setActiveTabId('vault');
await flushTabStore();
});
assert.ok(mountCommits > commitsAfterTerminalMount);
} finally {
console.error = originalConsoleError;
await act(async () => {
root.unmount();
await flushTabStore();
});
activeTabStore.setActiveTabId(previousTabId, { recordPrevious: false });
env.cleanup();
}
});
test('usePluginAIContextHost does not re-render on tab switches and reads live activeTabId on demand', async () => {
const env = setupDom();
const { act } = await import('react');
const { createRoot } = await import('react-dom/client');
const { activeTabStore } = await import('../state/activeTabStore');
const { usePluginAIContextHost } = await import('../state/usePluginAIContextHost');
const { registerAppAppLockRuntime, getAppAppLockRuntime } = await import('../state/appRuntimeBridge');
const previousTabId = activeTabStore.getActiveTabId();
const oldLock = getAppAppLockRuntime();
registerAppAppLockRuntime({ locked: false } as NonNullable<ReturnType<typeof getAppAppLockRuntime>>);
const sessions = [makeSession('session-1', 'h1'), makeSession('session-2', 'h2')];
const workspaces = [makeWorkspace('workspace-1', 'session-1')];
let requestHandler: ((req: {
kind: string;
requestId: string;
runtimeId: string;
actionToken: string;
payload: Record<string, unknown>;
}) => void) | null = null;
const responses: Array<{ requestId: string; result?: unknown; error?: boolean }> = [];
Object.assign(env.dom.window, {
netcatty: {
onPluginAIHostRequest(handler: typeof requestHandler) {
requestHandler = handler;
return () => {
requestHandler = null;
};
},
async setPluginAIHostReady() {},
async respondPluginAIHost(payload: { requestId: string; result?: unknown; error?: boolean }) {
responses.push(payload);
},
},
});
let renders = 0;
let latestChoice: ReturnType<typeof usePluginAIContextHost>['choice'] = null;
function Harness() {
renders += 1;
const host = usePluginAIContextHost({ sessions, workspaces });
latestChoice = host.choice;
return <div data-testid="ai-context-host" />;
}
const root = createRoot(document.getElementById('root')!);
try {
activeTabStore.setActiveTabId('session-1');
await flushTabStore();
await act(async () => {
root.render(<Harness />);
await flushTabStore();
});
const rendersAfterMount = renders;
// Switching across any tabs must cause 0 re-renders.
for (const nextTab of ['session-2', 'workspace-1', 'vault', 'sftp', 'session-2']) {
await act(async () => {
activeTabStore.setActiveTabId(nextTab);
await flushTabStore();
});
}
assert.equal(renders, rendersAfterMount);
// Triggering selection on demand without re-rendering must read live activeTabId ('session-2').
assert.ok(requestHandler, 'expected plugin AI host request listener to be registered');
await act(async () => {
requestHandler!({
kind: 'context.select',
requestId: 'req-1',
runtimeId: 'rt-1',
actionToken: 'tok-1',
payload: {},
});
});
await waitForAct(act, () => latestChoice !== null);
await act(async () => {
latestChoice!.confirm('');
});
await waitForAct(act, () => responses.length === 1);
assert.equal(responses[0].error, undefined);
const result = responses[0].result as {
items: Array<{ hostHandle: string; scope: string; title: string; version: string }>;
};
const sessionItem = result.items.find((item) => item.scope === 'session');
assert.ok(sessionItem, 'expected active session source to be included');
assert.equal(sessionItem.title, 'host-h2');
// Switching tabs without re-rendering must make context.current immediately report false.
const rendersBeforeSwitch = renders;
await act(async () => {
activeTabStore.setActiveTabId('session-1');
await flushTabStore();
});
assert.equal(renders, rendersBeforeSwitch);
await act(async () => {
requestHandler!({
kind: 'context.current',
requestId: 'req-2',
runtimeId: 'rt-1',
actionToken: 'tok-2',
payload: { hostHandle: sessionItem.hostHandle, version: sessionItem.version },
});
});
await waitForAct(act, () => responses.length === 2);
assert.deepEqual(responses[1].result, { current: false });
} finally {
registerAppAppLockRuntime(oldLock);
await act(async () => {
root.unmount();
await flushTabStore();
});
activeTabStore.setActiveTabId(previousTabId, { recordPrevious: false });
env.cleanup();
}
});
@@ -86,6 +86,7 @@ export function SessionPublisher({ persistSessionRestore, children }: SessionPub
updateSessionRestoreCwd,
getSessionRestoreCwd,
updateSessionDynamicTitle,
updateSessionPromptHost,
updateSessionCodingCliProvider,
} = session;
@@ -173,6 +174,7 @@ export function SessionPublisher({ persistSessionRestore, children }: SessionPub
updateSessionRestoreCwd,
getSessionRestoreCwd,
updateSessionDynamicTitle,
updateSessionPromptHost,
updateSessionCodingCliProvider,
}), [
addSessionToWorkspace,
@@ -226,6 +228,7 @@ export function SessionPublisher({ persistSessionRestore, children }: SessionPub
toggleWorkspaceViewMode,
updateSessionCodingCliProvider,
updateSessionDynamicTitle,
updateSessionPromptHost,
updateSessionFontSize,
updateSessionRestoreCwd,
updateSessionStatus,
@@ -1,6 +1,6 @@
import assert from 'node:assert/strict';
import { readFileSync } from 'node:fs';
import { dirname, join } from 'node:path';
import { existsSync, readFileSync, statSync } from 'node:fs';
import { dirname, join, relative, resolve } from 'node:path';
import test from 'node:test';
import { fileURLToPath } from 'node:url';
@@ -11,6 +11,83 @@ const read = (path: string) => readFileSync(join(root, path), 'utf8');
const staticImports = (source: string) =>
[...source.matchAll(/^\s*import\s+(?!type\b)[^;]*?from\s+['"]([^'"]+)['"]/gm)].map((match) => match[1]);
const STATIC_SPECIFIER_RE =
/(?:^|\n)\s*(?:import\s+(?!type\b)(?:[^;'"]*?\s+from\s+)?|export\s+(?!type\b)[^;'"]*?\s+from\s+)['"]([^'"]+)['"]/g;
const CJS_REQUIRE_RE = /\brequire\(\s*['"]([^'"]+)['"]\s*\)/g;
function extractStaticModuleSpecifiers(filePath: string, source: string): string[] {
const specs: string[] = [];
for (const match of source.matchAll(STATIC_SPECIFIER_RE)) {
specs.push(match[1]);
}
if (filePath.endsWith('.cjs')) {
for (const match of source.matchAll(CJS_REQUIRE_RE)) {
specs.push(match[1]);
}
}
return specs;
}
function resolveLocalModule(fromFile: string, specifier: string): string | null {
let base: string | null = null;
if (specifier.startsWith('@/')) {
base = join(root, specifier.slice(2));
} else if (specifier.startsWith('.')) {
base = resolve(dirname(fromFile), specifier);
}
if (!base) return null;
const candidates = [
base,
`${base}.ts`,
`${base}.tsx`,
`${base}.js`,
`${base}.jsx`,
`${base}.mjs`,
`${base}.cjs`,
join(base, 'index.ts'),
join(base, 'index.tsx'),
join(base, 'index.js'),
join(base, 'index.jsx'),
];
for (const candidate of candidates) {
if (existsSync(candidate) && statSync(candidate).isFile()) {
return candidate;
}
}
return null;
}
function collectStartupExternalDependencies(entryRelativePath: string): Map<string, string[]> {
const entryAbs = join(root, entryRelativePath);
const visited = new Set<string>([entryAbs]);
const parentChain = new Map<string, string[]>([[entryAbs, [entryRelativePath]]]);
const externalPaths = new Map<string, string[]>();
const queue: string[] = [entryAbs];
while (queue.length > 0) {
const current = queue.shift()!;
const source = readFileSync(current, 'utf8');
const chain = parentChain.get(current)!;
for (const specifier of extractStaticModuleSpecifiers(current, source)) {
if (specifier.startsWith('.') || specifier.startsWith('@/')) {
const resolved = resolveLocalModule(current, specifier);
if (resolved && !visited.has(resolved)) {
visited.add(resolved);
parentChain.set(resolved, [...chain, relative(root, resolved)]);
queue.push(resolved);
}
continue;
}
if (!externalPaths.has(specifier)) {
externalPaths.set(specifier, [...chain, specifier]);
}
}
}
return externalPaths;
}
test('only the English dictionary is bundled with the startup entry', () => {
const imports = staticImports(read('application/i18n/messages.ts'));
assert.deepEqual(imports.filter((path) => path.startsWith('./locales/')), ['./locales/en']);
@@ -34,6 +111,27 @@ test("Vite's preload helper stays out of the vendor-ai chunk", () => {
assert.match(read('vite.config.ts'), /vite\/preload-helper'\)\) return 'preload-helper'/);
});
test('the QR decoder is loaded on demand', () => {
assert.ok(!staticImports(read('components/HostTotpFields.tsx')).includes('jsqr'));
test('the QR decoder and RE2JS regex validator are loaded on demand', () => {
const imports = staticImports(read('components/HostTotpFields.tsx'));
assert.ok(!imports.includes('jsqr'));
assert.ok(!imports.includes('re2js'));
});
test('startup entry does not statically reach re2js, css-tree, @remote-dom/core, or @monaco-editor/react', () => {
const externals = collectStartupExternalDependencies('index.tsx');
const forbidden = [
{ label: 're2js', match: (spec: string) => spec === 're2js' || spec.startsWith('re2js/') },
{ label: 'css-tree', match: (spec: string) => spec === 'css-tree' || spec.startsWith('css-tree/') },
{ label: '@remote-dom/core', match: (spec: string) => spec === '@remote-dom/core' || spec.startsWith('@remote-dom/core/') },
{ label: '@monaco-editor/react', match: (spec: string) => spec === '@monaco-editor/react' || spec.startsWith('@monaco-editor/react/') },
];
for (const rule of forbidden) {
const matchEntry = [...externals.entries()].find(([spec]) => rule.match(spec));
assert.equal(
matchEntry,
undefined,
`${rule.label} must not be statically reachable from index.tsx (found via ${matchEntry?.[1].join(' -> ')})`,
);
}
});
@@ -1,279 +0,0 @@
import assert from 'node:assert/strict';
import { readFileSync } from 'node:fs';
import test from 'node:test';
const appSource = readFileSync(new URL('../../App.tsx', import.meta.url), 'utf8');
const appSideEffectsSource = readFileSync(
new URL('./AppSideEffects.tsx', import.meta.url),
'utf8',
);
const indexSource = readFileSync(new URL('../../index.tsx', import.meta.url), 'utf8');
const startupEffectsSource = readFileSync(
new URL('./useAppStartupEffects.ts', import.meta.url),
'utf8',
);
const updateCheckSource = readFileSync(
new URL('../state/useUpdateCheck.ts', import.meta.url),
'utf8',
);
const portForwardingAutoStartSource = readFileSync(
new URL('../state/usePortForwardingAutoStart.ts', import.meta.url),
'utf8',
);
const appLockBridgeSource = readFileSync(
new URL('../state/useAppLockBridge.ts', import.meta.url),
'utf8',
);
test('every renderer root mounts under StrictMode', () => {
assert.match(indexSource, /import \{ StrictMode, Suspense, lazy \} from 'react'/);
const renderCalls = indexSource.match(/root\.render\(/g) ?? [];
assert.equal(renderCalls.length, 5, 'main, settings, tray, terminal-popup and editor-window roots');
let cursor = 0;
for (let index = 0; index < renderCalls.length; index += 1) {
const renderAt = indexSource.indexOf('root.render(', cursor);
assert.notEqual(renderAt, -1);
const opener = indexSource.slice(renderAt, renderAt + 60);
assert.match(opener, /root\.render\(\s*<StrictMode>/, `root.render #${index + 1} lacks StrictMode`);
cursor = renderAt + 'root.render('.length;
}
});
test('clone-session payload is consumed once even if the effect re-runs', () => {
const effectStart = appSideEffectsSource.indexOf('consumedNewWindowSessionRef');
assert.notEqual(effectStart, -1, 'clone-session effect must latch on payload identity');
const effectEnd = appSideEffectsSource.indexOf(
'}, [createSessionFromCloneSource, isVaultInitialized, pendingNewWindowSession]);',
effectStart,
);
assert.notEqual(effectEnd, -1);
const body = appSideEffectsSource.slice(effectStart, effectEnd);
// A ref comparison is required: clearing the state only lands on the next
// render, so a re-invoked effect still closes over the same payload.
assert.match(body, /if \(consumedNewWindowSessionRef\.current === pendingNewWindowSession\) return;/);
assert.ok(
body.indexOf('consumedNewWindowSessionRef.current = pending')
< body.indexOf('createSessionFromCloneSource(pending.sourceSession'),
'payload must be marked consumed before the clone is created',
);
});
test('rendererReady is notified once per renderer process', () => {
assert.match(appLockBridgeSource, /^let rendererReadySent = false;$/m);
const guardAt = appLockBridgeSource.indexOf('if (rendererReadySent) return;');
assert.notEqual(guardAt, -1);
const guarded = appLockBridgeSource.slice(guardAt, guardAt + 200);
assert.match(guarded, /rendererReadySent = true;/);
assert.match(guarded, /netcattyBridge\.get\(\)\?\.rendererReady\?\.\(\)/);
assert.ok(
guarded.indexOf('rendererReadySent = true;')
< guarded.indexOf('netcattyBridge.get()?.rendererReady?.()'),
'the latch must be set before the IPC call so a re-entrant effect is blocked',
);
});
test('update-available toast latches on the release version', () => {
const latchAt = startupEffectsSource.indexOf('toastedUpdateVersionRef');
assert.notEqual(latchAt, -1);
assert.match(startupEffectsSource, /const toastedUpdateVersionRef = useRef<string \| null>\(null\)/);
assert.match(startupEffectsSource, /if \(toastedUpdateVersionRef\.current === version\) return;/);
const guardAt = startupEffectsSource.indexOf('if (toastedUpdateVersionRef.current === version) return;');
const toastAt = startupEffectsSource.indexOf('toast.info(', guardAt);
assert.notEqual(toastAt, -1);
assert.ok(guardAt < toastAt, 'the version latch must gate the toast call');
});
test('port-forward auto-start runs once across a StrictMode double effect', () => {
assert.match(
portForwardingAutoStartSource,
/const autoStartExecutedRef = useRef\(false\);/,
'the launch auto-start needs a module-render latch, not just an effect dep list',
);
const effectStart = portForwardingAutoStartSource.indexOf('if (autoStartExecutedRef.current) return;');
assert.notEqual(effectStart, -1, 'the effect must bail out when the latch is already set');
const effectEnd = portForwardingAutoStartSource.indexOf(
'}, [\n enabled,\n isVaultInitialized,\n runAutoStart,\n ]);',
effectStart,
);
assert.notEqual(effectEnd, -1, 'auto-start effect dep list moved; update this contract');
const body = portForwardingAutoStartSource.slice(effectStart, effectEnd);
// StrictMode invokes the effect twice with the same render's closure, so the
// latch has to be written before the async run is kicked off — awaiting or
// deferring the write would let the second invoke start a duplicate tunnel.
const latchAt = body.indexOf('autoStartExecutedRef.current = true;');
const runAt = body.indexOf('void runAutoStart();');
assert.notEqual(latchAt, -1);
assert.notEqual(runAt, -1);
assert.ok(latchAt < runAt, 'the latch must be set before runAutoStart() is called');
// The vault gate must also sit before the latch: latching on a pre-hydration
// invoke would permanently suppress the real auto-start.
assert.ok(
body.indexOf('if (!isVaultInitialized) return;') < latchAt,
'the vault gate must precede the latch write',
);
});
test('cancelled startup update check resets its latch instead of skipping forever', () => {
const scheduleAt = updateCheckSource.indexOf('let checkArmed = true;');
assert.notEqual(scheduleAt, -1);
const tail = updateCheckSource.slice(scheduleAt);
// The latch is only meaningful once the timer actually fires; a cleanup that
// cancels it beforehand must let the next effect schedule again.
assert.match(tail, /startupCheckTimeoutRef\.current = setTimeout\(async \(\) => \{\s*\n\s*checkArmed = false;/);
assert.match(tail, /if \(checkArmed\) \{\s*\n\s*hasCheckedOnStartupRef\.current = false;\s*\n\s*\}/);
});
test('terminal popup config survives StrictMode unsubscribe/resubscribe', () => {
const preloadSource = readFileSync(new URL('../../electron/preload.cjs', import.meta.url), 'utf8');
const apiSource = readFileSync(new URL('../../electron/preload/api.cjs', import.meta.url), 'utf8');
assert.match(preloadSource, /lastPayload:\s*null/);
assert.match(
preloadSource,
/terminalPopupConfigState\.lastPayload = payload/,
'incoming popup config must be retained beyond the one-shot pending slot',
);
const subscribeAt = apiSource.indexOf('onTerminalPopupConfig:');
assert.notEqual(subscribeAt, -1);
const subscribe = apiSource.slice(subscribeAt, subscribeAt + 700);
assert.match(
subscribe,
/terminalPopupConfigState\.pending \?\? terminalPopupConfigState\.lastPayload/,
'resubscribe must replay lastPayload after pending was drained',
);
assert.match(subscribe, /terminalPopupConfigState\.pending = null/);
assert.doesNotMatch(
subscribe,
/terminalPopupConfigState\.lastPayload = null/,
'StrictMode remount must not clear lastPayload on subscribe',
);
});
test('vault init cancels the superseded StrictMode effect before publishing ready', () => {
const vaultSource = readFileSync(
new URL('../state/useVaultState.ts', import.meta.url),
'utf8',
);
const initAt = vaultSource.indexOf('let cancelled = false;');
assert.notEqual(initAt, -1, 'vault init must track cancellation');
const initSlice = vaultSource.slice(initAt, initAt + 20000);
assert.match(
initSlice,
/return \(\) => \{\s*\n\s*cancelled = true;\s*\n\s*resolveTerminalDataReady\(\);\s*\n\s*\};/,
'StrictMode cleanup cancels init and unblocks the terminal-data ready promise',
);
assert.match(
initSlice,
/if \(!cancelled\) \{\s*\n\s*setIsInitialized\(true\);\s*\n\s*setVaultInitialized\(true\);\s*\n\s*\}/,
'only the surviving init may mark the vault ready',
);
assert.match(initSlice, /if \(cancelled\) return;/);
});
test('global hotkey registration cleans up across StrictMode remount', () => {
const systemEffectsSource = readFileSync(
new URL('../state/systemSettingsEffects.ts', import.meta.url),
'utf8',
);
const hotkeyAt = systemEffectsSource.indexOf('Persist and sync toggle window hotkey setting');
assert.notEqual(hotkeyAt, -1);
const hotkeyEffect = systemEffectsSource.slice(hotkeyAt, hotkeyAt + 2200);
assert.match(hotkeyEffect, /let cancelled = false;/);
assert.match(hotkeyEffect, /if \(cancelled\) return;/);
assert.match(
hotkeyEffect,
/if \(didRegister\) \{\s*\n\s*bridge\?\.unregisterGlobalHotkey/,
'cleanup must unregister a registration started by this effect',
);
// Early return before notify must not skip returning the cleanup function.
assert.doesNotMatch(
hotkeyEffect,
/if \(!persistMountedRef\.current\) return;\s*\n\s*notifySettingsChanged/,
);
});
test('settings persistMountedRef resets on StrictMode cleanup', () => {
const settingsSource = readFileSync(
new URL('../state/useSettingsState.ts', import.meta.url),
'utf8',
);
const markAt = settingsSource.indexOf('Mark persist effects mounted AFTER all persist useEffects');
assert.notEqual(markAt, -1);
const markEffect = settingsSource.slice(markAt, markAt + 500);
assert.match(markEffect, /persistMountedRef\.current = true;/);
assert.match(
markEffect,
/return \(\) => \{\s*\n\s*persistMountedRef\.current = false;\s*\n\s*\};/,
'remount must treat boot as a fresh mount, not a settings change',
);
});
test('tray panel connect flush latches against StrictMode double invoke', () => {
const sideEffectsSource = readFileSync(
new URL('./AppSideEffects.tsx', import.meta.url),
'utf8',
);
assert.match(sideEffectsSource, /pendingTrayConnectFlushKeyRef/);
assert.match(
sideEffectsSource,
/if \(pendingTrayConnectFlushKeyRef\.current === flushKey\) return;/,
);
});
test('ssh transport idle TTL notify latches against StrictMode double invoke', () => {
const settingsSource = readFileSync(
new URL('../state/useSettingsState.ts', import.meta.url),
'utf8',
);
assert.match(settingsSource, /lastPushedSshTransportIdleTtlRef/);
assert.match(
settingsSource,
/if \(lastPushedSshTransportIdleTtlRef\.current === sshTransportIdleTtlMs\) return;/,
);
assert.match(
settingsSource,
/lastPushedSshTransportIdleTtlRef\.current = sshTransportIdleTtlMs;/,
);
});
test('terminal selection Ask-AI payload is consumed once under StrictMode', () => {
const hostSource = readFileSync(
new URL('../../components/terminalLayer/TerminalLayerSupport.tsx', import.meta.url),
'utf8',
);
assert.match(hostSource, /consumedTerminalSelectionRequestIds/);
assert.doesNotMatch(
hostSource,
/consumedTerminalSelectionRequestIdRef/,
'component refs reset on StrictMode remount; use a module Set',
);
assert.match(
hostSource,
/if \(consumedTerminalSelectionRequestIds\.has\(pendingTerminalSelection\.requestId\)\)/,
);
const latchAt = hostSource.indexOf('markTerminalSelectionRequestConsumed(pendingTerminalSelection.requestId)');
const draftAt = hostSource.indexOf('updateDraft(scopeKey, defaultAgentId');
assert.ok(latchAt > 0 && draftAt > latchAt, 'must latch before mutating the draft');
});
test('Codex App Server interaction bridge is app-singleton like MCP approvals', () => {
assert.match(appSource, /setupCodexAppServerInteractionBridge/);
const panelSource = readFileSync(
new URL('../../components/AIChatSidePanel.tsx', import.meta.url),
'utf8',
);
assert.doesNotMatch(
panelSource,
/setupCodexAppServerInteractionBridge/,
'per-panel Codex IPC listeners fan out approvals under retained multi-tab mounts',
);
});
@@ -1,30 +0,0 @@
import assert from "node:assert/strict";
import test from "node:test";
import { readFileSync } from "node:fs";
test("active chrome theme applies top tab vars and clears them before vault restore transition", () => {
const chromeThemeSource = readFileSync(new URL("../state/useActiveChromeTheme.ts", import.meta.url), "utf8");
const syncSource = readFileSync(new URL("../state/activeChromeThemeSync.ts", import.meta.url), "utf8");
const effectsSource = readFileSync(new URL("../../components/terminalLayer/useTerminalLayerEffects.ts", import.meta.url), "utf8");
assert.match(chromeThemeSource, /applyTopTabsChromeThemeVars\(theme\)/);
assert.match(chromeThemeSource, /resolveReadableForegroundForHsl\(cursor\)/);
const restoreBlock = chromeThemeSource.match(
/clearTopTabsChromeThemeVars\(\);\s*runThemeTransition\(\(\) => \{\s*removeActiveChromeTheme\(\);/,
)?.[0] ?? "";
assert.notEqual(restoreBlock, "", "top tab vars must clear before the vault restore transition starts");
assert.match(syncSource, /activeTabId === 'vault' \|\| activeTabId === 'sftp'\)[\s\S]*clearTopTabsChromeThemeVars\(\)/);
assert.match(effectsSource, /if \(!isTerminalLayerVisible\) \{[\s\S]*clearTopTabsPreviewVars\(\)/);
});
test("top tabs chrome theme keeps accent foreground in sync", () => {
const source = readFileSync(new URL("./topTabsChromeTheme.ts", import.meta.url), "utf8");
const supportSource = readFileSync(new URL("../../components/terminalLayer/TerminalLayerSupport.tsx", import.meta.url), "utf8");
assert.match(source, /--primary-foreground/);
assert.match(source, /--accent-foreground/);
assert.match(source, /resolveReadableForegroundForHsl\(accent\)/);
assert.match(supportSource, /removeStylePropertyIfSet\(tabsRoot, '--primary-foreground'\)/);
assert.match(supportSource, /removeStylePropertyIfSet\(tabsRoot, '--accent-foreground'\)/);
});
+6 -43
View File
@@ -1,47 +1,10 @@
import type { TerminalTheme } from '../../types';
import { resolveReadableForegroundForHsl } from '../../domain/colorContrast';
function hexToHslToken(hex: string): string {
const normalized = hex.startsWith('#') ? hex : `#${hex}`;
const r = parseInt(normalized.slice(1, 3), 16) / 255;
const g = parseInt(normalized.slice(3, 5), 16) / 255;
const b = parseInt(normalized.slice(5, 7), 16) / 255;
const max = Math.max(r, g, b);
const min = Math.min(r, g, b);
let h = 0;
let s = 0;
const l = (max + min) / 2;
if (max !== min) {
const d = max - min;
s = l > 0.5 ? d / (2 - max - min) : d / (max + min);
switch (max) {
case r:
h = ((g - b) / d + (g < b ? 6 : 0)) / 6;
break;
case g:
h = ((b - r) / d + 2) / 6;
break;
default:
h = ((r - g) / d + 4) / 6;
break;
}
}
return `${Math.round(h * 3600) / 10} ${Math.round(s * 1000) / 10}% ${Math.round(l * 1000) / 10}%`;
}
function adjustLightnessToken(hsl: string, delta: number): string {
const parts = hsl.split(/\s+/);
const newL = Math.max(0, Math.min(100, parseFloat(parts[2]) + delta));
return `${parts[0]} ${parts[1]} ${Math.round(newL * 10) / 10}%`;
}
function adjustSaturationToken(hsl: string, factor: number): string {
const parts = hsl.split(/\s+/);
const newS = Math.max(0, Math.min(100, parseFloat(parts[1]) * factor));
return `${parts[0]} ${Math.round(newS * 10) / 10}% ${parts[2]}`;
}
import {
adjustLightnessToken,
adjustSaturationToken,
hexToHslToken,
resolveReadableForegroundForHsl,
} from '../../domain/colorContrast';
const setStylePropertyIfChanged = (element: HTMLElement, property: string, value: string) => {
if (element.style.getPropertyValue(property) === value) return;
@@ -53,6 +53,8 @@ for (const accept of [false, true]) {
{ id: "already-paused", status: "paused" },
{ id: "pausing", status: "pausing" },
{ id: "interrupted", status: "interrupted" },
{ id: "packed-running", status: "transferring", controlKind: "packed-download", resumable: false },
{ id: "packed-queued", status: "queued", controlKind: "packed-download", resumable: false },
{ id: "child", parentTaskId: "running", status: "transferring" },
],
}) as unknown as ReturnType<typeof sftpTransferCenterStore.getSnapshot>);
@@ -110,6 +112,44 @@ for (const accept of [false, true]) {
});
}
for (const accept of [false, true]) {
test(`packed-only quit still asks for confirmation without pausing or resuming (${accept ? "accept" : "cancel"})`, async (t) => {
const previousWindow = Object.getOwnPropertyDescriptor(globalThis, "window");
const previousAct = Object.getOwnPropertyDescriptor(globalThis, "IS_REACT_ACT_ENVIRONMENT");
let renderer: ReactTestRenderer | undefined;
let prompts = 0;
let query!: () => Promise<void>;
const reports: Array<[boolean, string | undefined]> = [];
Object.defineProperty(globalThis, "IS_REACT_ACT_ENVIRONMENT", { configurable: true, value: true });
Object.defineProperty(globalThis, "window", { configurable: true, value: {
confirm() { prompts++; return accept; },
} });
t.after(async () => {
await act(async () => renderer?.unmount());
if (previousWindow) Object.defineProperty(globalThis, "window", previousWindow); else Reflect.deleteProperty(globalThis, "window");
if (previousAct) Object.defineProperty(globalThis, "IS_REACT_ACT_ENVIRONMENT", previousAct); else Reflect.deleteProperty(globalThis, "IS_REACT_ACT_ENVIRONMENT");
});
t.mock.method(sftpTransferCenterStore, "getSnapshot", () => ({
activeCount: 1, queuedCount: 0, attentionCount: 0,
tasks: [{ ...makeTask("packed", "transferring"), controlKind: "packed-download", resumable: false }],
}));
t.mock.method(sftpTransferCenterStore, "pause", async () => { assert.fail("packed downloads cannot be paused"); });
t.mock.method(sftpTransferCenterStore, "resume", async () => { assert.fail("packed selections cannot be replayed"); });
t.mock.method(netcattyBridge, "get", () => ({
onCheckDirtyEditors(callback: typeof query) { query = callback; return () => {}; },
reportDirtyEditorsResult(dirty: boolean, reason?: string) { reports.push([dirty, reason]); },
}));
function Probe() {
useAppStartupEffects({ enabled: false, updateState: {}, sessions: [], hosts: [], keys: [], identities: [], knownHosts: [], proxyProfiles: [], groupConfigs: [], workspaces: [], portForwardingRules: [], t: (key: string) => key });
return null;
}
await act(async () => { renderer = create(React.createElement(Probe)); });
await query();
assert.equal(prompts, 1);
assert.deepEqual(reports, [[true, "transfers"], accept ? [false, undefined] : [true, "transfers"]]);
});
}
for (const outcome of ["pause-rejected", "pause-expired", "prompt-expired"] as const) {
test(`transfer quit refuses ${outcome} and resumes only the formerly active task`, async (t) => {
const previousWindow = Object.getOwnPropertyDescriptor(globalThis, "window");
@@ -250,3 +290,71 @@ test("retry Cancel preserves the expired attempt auto-resume ownership", async (
assert.equal(resumes, 1, "Cancel must restore work running before the first attempt");
assert.deepEqual(replies.at(-1), { dirty: true, requestId: "retry" });
});
test("stale listActivePackedDownloads snapshot cannot resurrect a packed transfer settled while in flight", async (t) => {
const previousAct = Object.getOwnPropertyDescriptor(globalThis, "IS_REACT_ACT_ENVIRONMENT");
Object.defineProperty(globalThis, "IS_REACT_ACT_ENVIRONMENT", { configurable: true, value: true });
let renderer: ReactTestRenderer | undefined;
const raceId = "packed-snapshot-race-settled";
const liveId = "packed-snapshot-race-live";
let emitGlobal!: (event: Record<string, unknown>) => void;
let resolveActive!: (events: Array<Record<string, unknown>>) => void;
const activePromise = new Promise<Array<Record<string, unknown>>>((resolve) => {
resolveActive = resolve;
});
t.after(async () => {
await act(async () => renderer?.unmount());
sftpTransferCenterStore.dismiss(raceId);
sftpTransferCenterStore.dismiss(liveId);
if (previousAct) Object.defineProperty(globalThis, "IS_REACT_ACT_ENVIRONMENT", previousAct);
else Reflect.deleteProperty(globalThis, "IS_REACT_ACT_ENVIRONMENT");
});
t.mock.method(netcattyBridge, "get", () => ({
onGlobalSftpTransferEvent: (cb: typeof emitGlobal) => { emitGlobal = cb; return () => {}; },
listActivePackedDownloads: () => activePromise,
}));
function Probe() {
useAppStartupEffects({
enabled: false, updateState: {}, sessions: [], hosts: [], keys: [], identities: [],
knownHosts: [], proxyProfiles: [], groupConfigs: [], workspaces: [], portForwardingRules: [],
t: (key: string) => key,
});
return null;
}
await act(async () => { renderer = create(React.createElement(Probe)); });
// Transfer completes before the active snapshot promise resolves; this window
// had no prior row for raceId so the completion event alone creates nothing.
emitGlobal({
type: "completed",
transferId: raceId,
controlKind: "packed-download",
transferred: 256,
totalBytes: 256,
endedAt: Date.now(),
});
assert.equal(sftpTransferCenterStore.getTask(raceId), undefined);
// Now the stale snapshot arrives containing both the settled raceId and a genuinely live transfer.
await act(async () => {
resolveActive([
{
type: "progress", transferId: raceId, direction: "download", fileName: "compose",
sourcePath: "/srv/compose", targetPath: "/tmp/compose", isDirectory: true,
controlKind: "packed-download", origin: "manual", retryable: false, resumable: false,
transferred: 128, phase: "transferring",
},
{
type: "progress", transferId: liveId, direction: "download", fileName: "still-running",
sourcePath: "/srv/still-running", targetPath: "/tmp/still-running", isDirectory: true,
controlKind: "packed-download", origin: "manual", retryable: false, resumable: false,
transferred: 64, phase: "extracting",
},
]);
await activePromise;
});
assert.equal(sftpTransferCenterStore.getTask(raceId), undefined, "settled transfer must not be recreated as stuck transferring");
assert.equal(sftpTransferCenterStore.getTask(liveId)?.status, "transferring");
assert.equal(sftpTransferCenterStore.getTask(liveId)?.phase, "extracting");
});
+34 -3
View File
@@ -315,7 +315,8 @@ export function useAppStartupEffects(ctx: StartupEffectsContext) {
status: s.status,
workspaceId: s.workspaceId,
workspaceTitle: ws?.title,
aiHidden: s.hiddenFromTabs === true,
aiHidden: s.hiddenFromTabs === true && !s.poppedOut,
poppedOut: s.poppedOut === true,
};
});
@@ -393,7 +394,10 @@ export function useAppStartupEffects(ctx: StartupEffectsContext) {
!task.parentTaskId && !["completed", "failed", "cancelled"].includes(task.status)
));
if (unfinishedTasks.length > 0) {
const resumable = unfinishedTasks.filter((task) => (
// Packed streams cannot pause or resume. Keep them in the quit
// confirmation, but let them run until the owner actually closes.
const pausableTasks = unfinishedTasks.filter((task) => task.controlKind !== "packed-download");
const resumable = pausableTasks.filter((task) => (
task.status === "transferring" || task.status === "queued"
|| previousAttempt?.resumeTaskIds.has(task.id)
));
@@ -410,7 +414,7 @@ export function useAppStartupEffects(ctx: StartupEffectsContext) {
};
transferQuitPendingRef.current = attempt;
bridge.reportDirtyEditorsResult?.(true, reason, { ...response, pending: true });
const paused = await Promise.allSettled(unfinishedTasks.map((task) => sftpTransferCenterStore.pause(task.id)));
const paused = await Promise.allSettled(pausableTasks.map((task) => sftpTransferCenterStore.pause(task.id)));
if (transferQuitPendingRef.current !== attempt) return;
const expired = () => request && Date.now() >= request.deadline;
if (!expired() && paused.every((result) => result.status === "fulfilled")) {
@@ -451,10 +455,34 @@ export function useAppStartupEffects(ctx: StartupEffectsContext) {
}, [enabled, t]);
useEffect(() => {
let active = true;
let pendingActivePackedSync = true;
// Any global event observed while the initial active-packed snapshot is in
// flight is strictly newer than (or equal to) the snapshot; skip replaying
// those IDs so a settled transfer cannot be recreated as stuck "transferring".
const observedPackedEventIds = new Set<string>();
const bridge = netcattyBridge.get();
const unsubscribeEvents = bridge?.onGlobalSftpTransferEvent?.((event) => {
if (pendingActivePackedSync && event?.transferId) {
observedPackedEventIds.add(event.transferId);
}
sftpTransferCenterStore.ingestBackgroundEvent(event);
});
void bridge?.listActivePackedDownloads?.().then((activePacked) => {
pendingActivePackedSync = false;
if (!active || !Array.isArray(activePacked)) {
observedPackedEventIds.clear();
return;
}
for (const event of activePacked) {
if (observedPackedEventIds.has(event.transferId)) continue;
sftpTransferCenterStore.ingestBackgroundEvent(event);
}
observedPackedEventIds.clear();
}).catch(() => {
pendingActivePackedSync = false;
observedPackedEventIds.clear();
});
const restartBackgroundTransfer = async (taskId: string, fromBeginning: boolean) => {
const task = sftpTransferCenterStore.getSnapshot().tasks.find((candidate) => candidate.id === taskId);
if (!task || !bridge?.openSftpForSession || !bridge.startStreamTransfer) return;
@@ -591,6 +619,9 @@ export function useAppStartupEffects(ctx: StartupEffectsContext) {
},
});
return () => {
active = false;
pendingActivePackedSync = false;
observedPackedEventIds.clear();
unsubscribeEvents?.();
unregisterOwner();
};
-10
View File
@@ -7,7 +7,6 @@ import type {
import {
cloudSyncPayloadsEqual,
convergentConflictAddressKey,
materializeSyncPayloadFromConvergentState,
planConvergentSyncMigration,
refreshConvergentSyncMigrationPlan,
resolveConvergentFieldConflict,
@@ -238,12 +237,3 @@ export async function initializePreparedConvergentMigration(options: {
});
return prepared.plan.preview;
}
export async function prepareConvergentSyncDowngrade(
manager: CloudSyncManager = getCloudSyncManager(),
now = Date.now(),
): Promise<SyncPayload> {
const replica = await manager.loadConvergentReplica();
if (!replica) throw new Error('No convergent sync replica is available to downgrade');
return materializeSyncPayloadFromConvergentState(replica.state, { syncedAt: now });
}
@@ -1,18 +0,0 @@
import assert from 'node:assert/strict';
import test from 'node:test';
import { enAiMessages } from './en/ai';
import { esAiMessages } from './es/ai';
import { ruAiMessages } from './ru/ai';
import { zhCNAiMessages } from './zh-CN/ai';
import { zhTWAiMessages } from './zh-TW/ai';
for (const [locale, messages] of Object.entries({
en: enAiMessages, es: esAiMessages, ru: ruAiMessages,
'zh-CN': zhCNAiMessages, 'zh-TW': zhTWAiMessages,
})) {
test(`${locale} translates the Catty iteration limit notice and Continue action`, () => {
assert.ok(messages['ai.chat.iterationLimitReached']);
assert.match(messages['ai.chat.iterationLimitReached'], /\{limit\}/);
assert.ok(messages['ai.chat.continue']);
});
}
@@ -1,49 +0,0 @@
import test from 'node:test';
import assert from 'node:assert/strict';
import en from '../locales/en.ts';
import ru from '../locales/ru.ts';
import es from '../locales/es.ts';
import zhCN from '../locales/zh-CN.ts';
import zhTW from '../locales/zh-TW.ts';
const keys = [
'cloudSync.convergent.title',
'cloudSync.convergent.experimental',
'cloudSync.convergent.desc',
'cloudSync.convergent.active',
'cloudSync.convergent.paused',
'cloudSync.convergent.enabled',
'cloudSync.convergent.preview.title',
'cloudSync.convergent.preview.entities',
'cloudSync.convergent.preview.providers',
'cloudSync.convergent.preview.conflicts',
'cloudSync.convergent.preview.compatibility',
'cloudSync.convergent.preview.confirm',
'cloudSync.convergent.preview.status.ready',
'cloudSync.convergent.preview.status.empty',
'cloudSync.convergent.preview.status.unavailable',
'cloudSync.convergent.preview.status.blocked',
'cloudSync.convergent.preview.schema',
'cloudSync.convergent.field.presence',
'cloudSync.convergent.field.position',
'cloudSync.convergent.conflicts.title',
'cloudSync.convergent.conflict.empty',
'cloudSync.convergent.conflict.secretSet',
'cloudSync.convergent.conflict.current',
'cloudSync.convergent.conflict.choose',
'cloudSync.convergent.conflict.resolved',
'cloudSync.convergent.downgrade.desc',
'cloudSync.convergent.downgrade.button',
'cloudSync.convergent.downgrade.confirm',
'cloudSync.convergent.downgrade.done',
] as const;
test('convergent sync copy exists in every bundled locale', () => {
for (const [locale, messages] of Object.entries({ en, ru, es, zhCN, zhTW })) {
for (const key of keys) {
assert.equal(typeof messages[key], 'string', `${locale} is missing ${key}`);
assert.notEqual(messages[key], '', `${locale} has empty ${key}`);
}
}
});
@@ -1,64 +0,0 @@
import test from 'node:test';
import assert from 'node:assert/strict';
import en from '../locales/en.ts';
import ru from '../locales/ru.ts';
import es from '../locales/es.ts';
import zhCN from '../locales/zh-CN.ts';
import zhTW from '../locales/zh-TW.ts';
const keys = [
'cloudSync.provider.disconnect',
'cloudSync.provider.disconnect.confirmTitle',
'cloudSync.provider.disconnect.confirmMessage',
'cloudSync.provider.disconnect.confirmAction',
'cloudSync.provider.disconnect.toastTitle',
'cloudSync.provider.disconnect.cloudRemains',
'cloudSync.provider.disconnect.failed',
] as const;
test('disconnect copy exists in every bundled locale', () => {
for (const [locale, messages] of Object.entries({ en, ru, es, zhCN, zhTW })) {
for (const key of keys) {
assert.equal(typeof messages[key], 'string', `${locale} is missing ${key}`);
assert.notEqual(messages[key], '', `${locale} has empty ${key}`);
}
}
});
test('disconnect confirm copy states that saved provider credentials are removed', () => {
// The confirm dialog must explain the data consequence of disconnecting:
// locally saved endpoint + credentials removal, not just "stops syncing".
const expected = [
[en, 'will be removed'],
[es, 'eliminarán'],
[ru, 'будут удалены'],
[zhCN, '删除'],
[zhTW, '刪除'],
] as const;
for (const [messages, fragment] of expected) {
assert.ok(
(messages['cloudSync.provider.disconnect.confirmMessage'] as string).includes(fragment),
`confirmMessage should mention credential removal: ${fragment}`,
);
}
});
test('disconnect toast copy explains the cloud copy is retained', () => {
for (const [locale, messages] of Object.entries({ en, ru, es, zhCN, zhTW })) {
assert.ok(
(messages['cloudSync.provider.disconnect.cloudRemains'] as string).includes(
'{name}',
),
`${locale} cloudRemains hint should reference the provider name`,
);
}
});
test('disconnect copy distinguishes login cleanup from retained local data', () => {
assert.match(en['cloudSync.provider.disconnect.confirmMessage'], /backup history and sync encryption password stay here/);
assert.doesNotMatch(en['cloudSync.provider.disconnect.cloudRemains'], /change.*password/);
for (const messages of [en, ru, es, zhCN, zhTW]) {
assert.ok(messages['cloudSync.provider.disconnect.failed'].includes('{name}'));
}
});
@@ -1,37 +0,0 @@
import test from "node:test";
import assert from "node:assert/strict";
import en from "../locales/en.ts";
import ru from "../locales/ru.ts";
import es from "../locales/es.ts";
import zhCN from "../locales/zh-CN.ts";
const strategyKeys = [
"cloudSync.strategy.title",
"cloudSync.strategy.desc",
"cloudSync.strategy.smartMerge",
"cloudSync.strategy.smartMergeDesc",
"cloudSync.strategy.smartMergePreserve",
"cloudSync.strategy.smartMergePreserveDesc",
"cloudSync.strategy.preferCloud",
"cloudSync.strategy.preferCloudDesc",
"cloudSync.strategy.preferLocal",
"cloudSync.strategy.preferLocalDesc",
"cloudSync.aiSessions.title",
"cloudSync.aiSessions.desc",
"cloudSync.aiSessions.compatibility",
"cloudSync.aiSessions.enableFailed",
] as const;
test("cloud sync strategy copy exists in every bundled locale", () => {
for (const [locale, messages] of Object.entries({ en, ru, es, zhCN })) {
for (const key of strategyKeys) {
assert.equal(
typeof messages[key],
"string",
`${locale} is missing ${key}`,
);
assert.notEqual(messages[key], "", `${locale} has empty ${key}`);
}
}
});
@@ -1,27 +0,0 @@
import assert from 'node:assert/strict';
import test from 'node:test';
import en from './en.ts';
import ru from './ru.ts';
import es from './es.ts';
import zhCN from './zh-CN.ts';
import zhTW from './zh-TW.ts';
const STEER_KEYS = [
'ai.codex.steer.addInstruction',
'ai.codex.steer.sending',
'ai.codex.steer.placeholder',
'ai.codex.steer.notSteerableReview',
'ai.codex.steer.notSteerableCompact',
'ai.codex.steer.busy',
'ai.codex.steer.inactive',
'ai.codex.steer.unsupported',
'ai.codex.steer.failed',
] as const;
test('Codex steering UI is localized in every supported locale', () => {
for (const [name, messages] of Object.entries({ en, es, 'zh-CN': zhCN, 'zh-TW': zhTW, ru })) {
const missing = STEER_KEYS.filter(key => !messages[key]);
assert.deepEqual(missing, [], `${name} is missing Codex steering labels`);
}
});
+23 -7
View File
@@ -71,6 +71,9 @@ export const enAiMessages: Messages = {
'ai.providers.apiKey': 'API Key',
'ai.providers.apiKey.placeholder': 'Enter API key',
'ai.providers.apiKey.decrypting': 'Decrypting...',
'ai.providers.opencodeGo.help': 'Paste an OpenCode API key to use OpenCode Go. The base URL and model list are configured automatically.',
'ai.providers.opencodeGo.getKey': 'Get an API key',
'ai.providers.fixedBaseUrl.help': 'Fixed by the provider. Netcatty chooses the endpoint path for each model automatically.',
'ai.providers.baseUrl': 'Base URL',
'ai.providers.baseUrl.anthropicHelp': 'Anthropic-compatible: host with or without /v1 (for example https://gateway.example or https://gateway.example/v1). Detection and chat both use /v1/models and /v1/messages.',
'ai.providers.baseUrl.ollamaHelp': 'Local Ollama: http://localhost:11434/v1 (no API key). Ollama Cloud: https://ollama.com/v1 plus your cloud API key.',
@@ -615,6 +618,23 @@ export const enAiMessages: Messages = {
'ai.chat.rebindUsage': 'Usage: /rebind <number from /chats>',
'ai.chat.rebindDone': 'Chat "{title}" rebound to this panel.',
'ai.chat.rebindUnavailable': 'No rebind target in this panel scope.',
'ai.chat.managerScopeTab': 'Current chats',
'ai.chat.managerAllChatsTab': 'All chats',
'ai.chat.managerSearchPlaceholder': 'Search chat titles…',
'ai.chat.managerFilterAllAgents': 'All agents',
'ai.chat.managerMoreActions': 'More actions',
'ai.chat.managerOpen': 'Open in this panel',
'ai.chat.managerOpenDisabled': 'Bound to another workspace or terminal — use move to transfer it',
'ai.chat.managerRebind': 'Move to…',
'ai.chat.managerRebindPick': 'Choose a terminal or workspace…',
'ai.chat.managerRebindHere': 'Current panel',
'ai.chat.managerRebindDone': 'Moved "{title}" to {target}.',
'ai.chat.managerExportOne': 'Export this chat',
'ai.chat.managerBadgeActive': 'Active',
'ai.chat.managerBadgeIdle': 'Idle',
'ai.chat.managerMessagesCount': '{n} messages',
'ai.chat.managerDeleteTitle': 'Delete this chat?',
'ai.chat.managerDeleteMessage': '"{title}" and its messages will be removed from every panel. This cannot be undone.',
'ai.chat.justNow': 'Just now',
'ai.chat.minutesAgo': '{n}m ago',
'ai.chat.hoursAgo': '{n}h ago',
@@ -702,6 +722,9 @@ export const enAiMessages: Messages = {
'ai.safety.responseIdleTimeout.unit': 'sec',
'ai.safety.maxIterations': 'Max Iterations',
'ai.safety.maxIterations.description': 'Maximum number of AI tool-use loops to prevent runaway execution. External agents may have their own internal iteration limits that take precedence.',
'ai.safety.toolOutputMaxChars': 'Built-in AI Tool Output Limit',
'ai.safety.toolOutputMaxChars.description': 'Maximum characters kept inline per built-in AI tool result (such as terminal commands or SFTP reads) before truncating and spilling the full output to a saved handle (2,000–200,000).',
'ai.safety.toolOutputMaxChars.unit': 'chars',
'ai.safety.blocklist': 'Command Blocklist',
'ai.safety.blocklist.description': 'Regex patterns to block dangerous commands executed through Netcatty.',
'ai.safety.blocklist.placeholder': 'Regex pattern...',
@@ -732,9 +755,6 @@ export const enAiMessages: Messages = {
'terminal.layer.theme': 'Theme',
'terminal.layer.notes': 'Notes',
'terminal.layer.aiChat': 'AI Chat',
'terminal.layer.movePanelLeft': 'Move panel to left',
'terminal.layer.movePanelRight': 'Move panel to right',
'terminal.layer.movePanelBottom': 'Move panel to bottom',
'terminal.layer.choosePanelPosition': 'Change position',
'terminal.layer.dockLeft': 'Left',
'terminal.layer.dockRight': 'Right',
@@ -768,19 +788,15 @@ export const enAiMessages: Messages = {
'terminal.layer.hostTree.details.protocol': 'Protocol',
'terminal.layer.hostTree.details.group': 'Group',
'terminal.layer.hostTree.details.tags': 'Tags',
'terminal.layer.hostTree.details.lastConnected': 'Last connected',
'topTabs.openQuickSwitcher': 'Open quick switcher',
'topTabs.moreTabs': 'More tabs',
'topTabs.aiAssistant': 'AI Assistant',
'topTabs.newLocalTerminal': 'New Local Terminal',
'topTabs.controlPanel': 'Quick controls',
'topTabs.controlPanel.externalMcp': 'External MCP',
'topTabs.controlPanel.theme': 'Theme',
'topTabs.controlPanel.theme.light': 'Light',
'topTabs.controlPanel.theme.dark': 'Dark',
'topTabs.controlPanel.theme.system': 'System',
'topTabs.externalMcp.enable': 'Enable External MCP',
'topTabs.externalMcp.disable': 'Disable External MCP',
'topTabs.windowOpacity': 'Window opacity',
'topTabs.openSettings': 'Open Settings',
'ai.chat.sessionHistory': 'Session history',
+6 -14
View File
@@ -84,7 +84,6 @@ export const enCoreMessages: Messages = {
'common.edit': 'Edit',
'common.clear': 'Clear',
'common.optional': 'Optional',
'common.selectPlaceholder': 'Select...',
'common.add': 'Add',
'common.rename': 'Rename',
'common.refresh': 'Refresh',
@@ -124,11 +123,9 @@ export const enCoreMessages: Messages = {
'field.label': 'Label',
'field.type': 'Type',
'auth.keyType': 'Type {type}',
'auth.showAllKeys': 'Show all keys',
// Dialogs / prompts
'confirm.deleteHost': 'Delete Host "{name}"?',
'confirm.deleteIdentity': 'Delete Identity "{name}"?',
'confirm.removeProvider': 'Remove provider "{name}"?',
'confirm.closeBusyTerminal.title': 'Confirm close',
'confirm.closeBusyTerminal.message': 'Process "{command}" is still running and will be terminated.',
@@ -401,7 +398,6 @@ export const enCoreMessages: Messages = {
'tray.status.inactive': 'Inactive',
'tray.status.error': 'Error',
'tray.status.unknown': 'Unknown',
'tray.recentHosts': 'Recent Hosts',
'tray.empty.title': 'Nothing here yet',
'tray.empty.subtitle': 'Go connect to a server, they miss you 🚀',
'tray.quit': 'Quit Netcatty',
@@ -460,9 +456,6 @@ export const enCoreMessages: Messages = {
'update.downloadFailed.message': 'Failed to download update. You can download it manually.',
'update.needsSave.title': 'Unsaved Changes',
'update.needsSave.message': 'Save your open editors first, then click Restart Now again to install the update.',
'update.openReleases': 'Open Releases',
'update.remindLater': 'Remind Later',
'update.skipVersion': 'Skip This Version',
// Settings > Appearance
'settings.appearance.uiTheme': 'UI Theme',
@@ -482,7 +475,7 @@ export const enCoreMessages: Messages = {
'settings.appearance.themeColor.dark': 'Dark palette',
'settings.appearance.customCss': 'Custom CSS',
'settings.appearance.customCss.desc':
'Add custom CSS to personalize the app appearance. Changes apply immediately. Selected top tabs (`.top-tab[data-active="true"]`) read `--top-tab-active-bg`, `--top-tab-active-fg`, and `--top-tab-active-border`. Leave them unset to keep the current look.',
'Add custom CSS to personalize the app appearance. Changes apply immediately.',
'settings.appearance.customCss.help.ariaLabel': 'Custom CSS help',
'settings.appearance.customCss.help.title': 'Custom CSS guide',
'settings.appearance.customCss.help.body': `Major UI regions expose a \`data-section\` attribute you can target. Changes apply as soon as you edit the CSS.
@@ -912,7 +905,9 @@ Highlight the focused split pane:
'settings.terminal.connection.temporaryNetworkDeviceMode': 'Network device mode for temporary connections',
'settings.terminal.connection.temporaryNetworkDeviceMode.desc': 'SSH connections with no saved host, including external launches and quick connect, start in network device mode. Saved hosts and groups keep their own device type. Off by default.',
'settings.terminal.connection.sshAutoReconnectEnabled': 'Automatically reconnect SSH sessions',
'settings.terminal.connection.sshAutoReconnectEnabled.desc': 'When turned on, established SSH sessions that drop unexpectedly try to reconnect every 5 seconds until the tab is closed or the connection succeeds.',
'settings.terminal.connection.sshAutoReconnectEnabled.desc': 'Retry unexpectedly disconnected SSH sessions at the configured interval until the tab is closed or the connection succeeds.',
'settings.terminal.connection.sshAutoReconnectInterval': 'SSH reconnect interval (seconds)',
'settings.terminal.connection.sshAutoReconnectInterval.desc': 'Wait between automatic reconnect attempts: 5–3600 seconds (default 5). Changes apply to the next scheduled attempt; an existing wait is unchanged.',
'settings.terminal.connection.keepaliveInterval': 'Keepalive Interval',
'settings.terminal.connection.keepaliveInterval.desc': 'How often (in seconds) to send SSH-level keepalive packets. Set to 0 to disable globally — note that individual hosts can override this in their own settings.',
'settings.terminal.connection.keepaliveCountMax': 'Max unanswered keepalives',
@@ -1044,6 +1039,7 @@ Highlight the focused split pane:
'settings.shortcuts.binding.close-tab': 'Close Tab',
'settings.shortcuts.binding.close-session': 'Close Session Pane',
'settings.shortcuts.binding.new-tab': 'New Local Tab',
'settings.shortcuts.binding.reopen-closed-tab': 'Reopen Closed Tab',
'settings.shortcuts.binding.copy': 'Copy from Terminal',
'settings.shortcuts.binding.paste': 'Paste to Terminal',
'settings.shortcuts.binding.paste-selection': 'Paste Selection to Terminal',
@@ -1083,8 +1079,6 @@ Highlight the focused split pane:
'settings.shortcuts.binding.sftp-navigate-to': 'Navigate to Selected Directory',
// Context menus / common actions
'action.newHost': 'New Host',
'action.newSubfolder': 'New Subfolder',
'action.copyPublicKey': 'Copy Public Key',
'action.keyExport': 'Key Export',
'action.edit': 'Edit',
@@ -1319,12 +1313,9 @@ Highlight the focused split pane:
"settings.plugins.manager.remove": "Uninstall",
"settings.plugins.manager.removeNote": "Uninstall removes package code and local KV data. User-owned settings, secrets and sync sidecars are retained.",
"settings.plugins.permissions.statusUnknown": "Status unknown",
"plugins.sidebar.extensions": "Extension pages",
"plugins.sidebar.selectTerminal": "Select an open terminal first.",
"plugins.sidebar.loading": "Loading extension page…",
"plugins.vault.loading": "Loading plugin page…",
"plugins.vault.extensions": "Extensions",
"plugins.vault.back": "Back to hosts",
"plugins.interaction.title": "Plugin request",
"plugins.interaction.sharing": "Text you share becomes available to this plugin and its granted capabilities, including network access. Reading does not approve a new network destination.",
"plugins.interaction.input": "Input text",
@@ -1473,6 +1464,7 @@ Highlight the focused split pane:
'plugins.hostActions.selectionNote': 'Only the selected hosts\' saved labels, addresses, usernames, protocols, groups and tags are shared. Group selection includes only the hosts selected now. Later edit or connection requests follow this plugin\'s permission settings.',
'plugins.hostActions.create': 'Review host draft',
'plugins.hostActions.edit': 'Review host changes',
'plugins.hostActions.streamNote': 'Allow this plugin to send and receive data at this destination through the selected SSH server. Addresses are resolved on that server. This may read or change database data. No terminal or startup scripts will run. SSH passwords and keys stay in the app. Select an SSH server to continue.',
'plugins.hostActions.connect': 'Confirm connection',
'plugins.hostActions.fieldDiff': 'Changes to save',
'plugins.hostActions.defaultsWarning': 'Saved connection defaults apply. Changing a group can change inherited authentication, proxy settings and scripts.',
-20
View File
@@ -1,6 +1,5 @@
export const enScriptsMessages = {
'scripts.meta.name': 'Name',
'scripts.meta.language': 'Language',
'scripts.meta.description': 'Description',
'scripts.meta.descriptionPlaceholder': 'Optional notes about this script',
'scripts.meta.trigger': 'Trigger',
@@ -15,7 +14,6 @@ export const enScriptsMessages = {
'scripts.actions.openEditor': 'Open editor',
'scripts.actions.openEditorHint': 'Edit script in a larger window',
'scripts.editor.modalTitle': 'Script editor',
'scripts.editor.modalSubtitle': 'Edit metadata and script code in a larger workspace.',
'scripts.editor.lineCount': '{count} lines',
'scripts.editor.resize': 'Resize editor',
'scripts.targets.hint': 'Selected groups are resolved dynamically, so hosts added later are included automatically.',
@@ -86,17 +84,13 @@ export const enScriptsMessages = {
'scripts.dialog.retry': 'Retry',
'scripts.dialog.skip': 'Skip',
'scripts.dialog.abort': 'Abort',
'scripts.running.stepProgress': 'Step {current} / {total}',
'scripts.running.determinateProgress': '{label} {current}/{total}',
'scripts.running.progressFallback': 'Progress',
'scripts.running.operationsCount': '{count} operations',
'scripts.running.opsPrefix': '',
'scripts.running.opsSuffix': ' operations',
'scripts.running.elapsedLabel': 'Elapsed',
'scripts.running.lastSentLabel': 'Sent:',
'scripts.running.elapsed': '{elapsed}',
'scripts.running.completedSummary': 'Completed · {count} operations · {elapsed}',
'scripts.running.dismissHint': 'Tap close to dismiss',
'scripts.running.dismiss': 'Close',
'scripts.running.viewLogs': 'View logs',
'scripts.running.logTitle': '{name} · Run log',
@@ -111,26 +105,12 @@ export const enScriptsMessages = {
'vault.nav.scripts': 'Scripts',
'snippets.action.newScript': 'New automation script',
'hostDetails.section.automation': 'Automation',
'hostDetails.automation.loginScript': 'Login script',
'hostDetails.automation.loginScriptPlaceholder': 'Select a script',
'hostDetails.automation.none': 'None',
'hostDetails.automation.outputTriggers': 'Output triggers',
'hostDetails.automation.addTrigger': 'Add trigger',
'hostDetails.automation.triggerPatternPlaceholder': 'Regex pattern',
'hostDetails.automation.linkedScripts': 'Linked scripts',
'hostDetails.automation.linkedScriptsEmpty': 'No scripts linked to this host yet.',
'hostDetails.automation.linkScriptPlaceholder': 'Link existing script…',
'hostDetails.automation.unlink': 'Unlink',
'hostDetails.automation.equivalenceHint': 'Links add this host to the script\'s target list in Scripts. Both views stay in sync.',
'hostDetails.automation.queueHint': 'Scripts run in order when this host connects. Global scripts run first, then this queue.',
'hostDetails.automation.globalScripts': 'Global connect scripts',
'hostDetails.automation.globalScriptsHint': 'Runs first on every connect. Reorder in Scripts library sort order.',
'hostDetails.automation.connectQueue': 'This host\'s run queue',
'hostDetails.automation.connectQueueEmpty': 'No connect scripts queued for this host yet.',
'hostDetails.automation.addToQueuePlaceholder': 'Add script to queue…',
'hostDetails.automation.moveUp': 'Move up',
'hostDetails.automation.moveDown': 'Move down',
'hostDetails.automation.removeFromQueue': 'Remove from queue',
'hostDetails.automation.dragHandle': 'Drag to reorder',
'hostDetails.automation.queueDragHint': 'Drag items to reorder the connect queue.',
};
@@ -14,13 +14,11 @@ export const enSystemManagerMessages: Messages = {
'systemManager.tabs.docker': 'Docker',
'systemManager.tabs.gpu': 'GPU',
'systemManager.tabs.ariaLabel': 'System manager sections',
'systemManager.popup.loading': 'Opening terminal…',
'systemManager.popup.startupFailed': 'The startup command did not complete successfully. Check that the target is still available and try again.',
'systemManager.errors.loadProcesses': 'Failed to load processes',
'systemManager.errors.loadTmux': 'Failed to load tmux sessions',
'systemManager.errors.loadTmuxWindows': 'Failed to load tmux windows',
'systemManager.errors.loadTmuxPanes': 'Failed to load tmux panes',
'systemManager.errors.loadTmuxClients': 'Failed to load tmux clients',
'systemManager.errors.actionFailed': 'Action failed',
'systemManager.errors.loadDocker': 'Failed to load containers',
@@ -31,7 +29,6 @@ export const enSystemManagerMessages: Messages = {
'systemManager.errors.nerdctlUnreachable': "nerdctl can't reach containerd",
'systemManager.errors.clusterUnreachable': "Can't reach the cluster for context {{context}}",
'systemManager.errors.clusterUnreachableGeneric': "Can't reach the cluster",
'systemManager.errors.loadOverview': 'Failed to load system overview',
'systemManager.errors.loadGpu': 'Failed to load GPU / NPU stats',
'systemManager.errors.loadPorts': 'Failed to load listening ports',
'systemManager.errors.loadServices': 'Failed to load systemd services',
@@ -65,13 +62,10 @@ export const enSystemManagerMessages: Messages = {
'systemManager.overview.noTopProcesses': 'No process data',
'systemManager.processes.search': 'Search processes…',
'systemManager.processes.command': 'Command',
'systemManager.processes.user': 'User',
'systemManager.processes.term': 'Terminate',
'systemManager.processes.kill': 'Kill',
'systemManager.processes.stop': 'Stop (SIGSTOP)',
'systemManager.processes.cont': 'Continue (SIGCONT)',
'systemManager.processes.hup': 'Hang up (SIGHUP)',
'systemManager.processes.renice': 'Renice',
'systemManager.processes.renicePrompt': 'Nice value (-20 to 19)',
'systemManager.processes.reniceInvalid': 'Nice value must be between -20 and 19',
@@ -86,7 +80,6 @@ export const enSystemManagerMessages: Messages = {
'systemManager.processes.stat': 'State',
'systemManager.processes.meta': '{{count}} process(es)',
'systemManager.processes.loading': 'Loading processes…',
'systemManager.processes.loadingMore': 'Loading more processes…',
'systemManager.processes.state.running': 'Running',
'systemManager.processes.state.sleeping': 'Sleeping',
'systemManager.processes.state.stopped': 'Stopped',
@@ -124,12 +117,9 @@ export const enSystemManagerMessages: Messages = {
'systemManager.tmux.attached': 'Attached',
'systemManager.tmux.detached': 'Detached',
'systemManager.tmux.windows': '{{count}} window(s)',
'systemManager.tmux.created': 'Created',
'systemManager.tmux.activity': 'Activity',
'systemManager.tmux.rename': 'Rename',
'systemManager.tmux.detach': 'Detach all',
'systemManager.tmux.killSession': 'Kill session',
'systemManager.tmux.killServer': 'Kill server',
'systemManager.tmux.loadingDetails': 'Loading details…',
'systemManager.tmux.clients': 'Attached clients',
'systemManager.tmux.windowList': 'Windows',
@@ -140,31 +130,17 @@ export const enSystemManagerMessages: Messages = {
'systemManager.docker.unavailable': 'No container runtime (Docker, Podman, nerdctl, or kubectl) was detected on this host',
'systemManager.tmux.windowsMismatch': 'Session reports {{count}} window(s) but list-windows returned none',
'systemManager.tmux.lastCommand': 'last command: {{command}}',
'systemManager.tmux.noPanes': 'No panes',
'systemManager.tmux.panes': '{{count}} pane(s)',
'systemManager.tmux.active': 'active',
'systemManager.tmux.unnamedWindow': 'Unnamed window',
'systemManager.tmux.unnamedPane': 'Unnamed pane',
'systemManager.tmux.attachWindow': 'Attach to window',
'systemManager.tmux.selectWindow': 'Select window',
'systemManager.tmux.killWindow': 'Kill window',
'systemManager.tmux.killPane': 'Kill pane',
'systemManager.tmux.splitHorizontal': 'Split horizontal',
'systemManager.tmux.splitVertical': 'Split vertical',
'systemManager.tmux.sendKeys': 'Send keys',
'systemManager.tmux.sendKeysTo': 'Send keys to window {{window}} pane {{pane}}',
'systemManager.tmux.sendKeysPlaceholder': 'Command or text…',
'systemManager.tmux.renameSessionPrompt': 'Rename session',
'systemManager.tmux.renameWindowPrompt': 'Rename window',
'systemManager.tmux.windowName': 'Window name',
'systemManager.tmux.confirmKillSession': 'Kill tmux session "{{name}}"?',
'systemManager.tmux.confirmDetachSession': 'Detach all clients from "{{name}}"?',
'systemManager.tmux.confirmKillWindow': 'Kill window "{{name}}"?',
'systemManager.tmux.confirmKillPane': 'Kill pane #{{index}}?',
'systemManager.tmux.confirmKillServer': 'Kill tmux server? All sessions will be terminated.',
'systemManager.tmux.meta': '{{count}} session(s)',
'systemManager.docker.title': 'Containers',
'systemManager.docker.subTabs.containers': 'Containers',
'systemManager.docker.subTabs.images': 'Images',
'systemManager.docker.empty': 'No containers found',
@@ -177,7 +153,6 @@ export const enSystemManagerMessages: Messages = {
'systemManager.docker.filter.paused': 'Paused',
'systemManager.docker.shell': 'Shell',
'systemManager.docker.logs': 'Logs',
'systemManager.docker.details': 'Details',
'systemManager.docker.inspect': 'Inspect',
'systemManager.docker.imageInspect': 'Image inspect',
'systemManager.docker.confirmRemove': 'Remove this container?',
+6 -64
View File
@@ -12,8 +12,12 @@ export const enTerminalMessages: Messages = {
'terminal.directory.hidden': 'Show hidden directories',
'terminal.directory.refresh': 'Refresh',
'terminal.directory.unavailable': 'Directory navigation is unavailable for this session.',
'terminal.directory.integrationUnavailable': 'PowerShell directory integration is not ready. Startup arguments or execution policy may prevent it.',
'terminal.directory.cmdIntegrationUnavailable': 'Waiting for a directory report from the original Command Prompt session.',
'terminal.directory.nonFilesystem': 'The current PowerShell location is not a filesystem directory.',
'terminal.directory.busy': 'Wait for an empty shell prompt.',
'terminal.directory.readFailed': 'Could not read this directory. Try refreshing.',
'terminal.directory.accessDenied': 'Permission denied while listing this directory.',
'terminal.directory.changeFailed': 'Could not confirm the directory change. Refresh before retrying.',
'terminal.directory.unsupportedPath': 'This directory name cannot be sent safely to the terminal.',
'settings.terminal.behavior.contextChips': 'Context Chips',
@@ -53,7 +57,6 @@ export const enTerminalMessages: Messages = {
'terminal.toolbar.availableAfterConnect': 'Available after connect',
'terminal.toolbar.sendYmodem': 'Send with YMODEM',
'terminal.toolbar.receiveYmodem': 'Receive with YMODEM',
'terminal.toolbar.sftp': 'SFTP',
'terminal.toolbar.more': 'More actions',
'terminal.toolbar.scripts': 'Scripts',
'terminal.toolbar.history': 'Command history',
@@ -101,7 +104,6 @@ export const enTerminalMessages: Messages = {
'terminal.composeBar.resize': 'Resize compose bar height',
'terminal.composeBar.manageSnippets': 'Manage quick snippets',
'terminal.composeBar.searchSnippets': 'Search snippets...',
'terminal.composeBar.noPinnedSnippets': 'Pin snippets with + for quick access',
'terminal.composeBar.noMatchingSnippets': 'No matching snippets',
'terminal.composeBar.pinnedCount': '{count} pinned',
'terminal.composeBar.unpinSnippet': 'Remove {label} from quick bar',
@@ -195,7 +197,6 @@ export const enTerminalMessages: Messages = {
'terminal.osc7Setup.title': 'Configure directory tracking',
'terminal.osc7Setup.desc': 'Netcatty will add OSC 7 prompt hooks for the current remote user. This helps SFTP follow the terminal directory after sudo or su.',
'terminal.osc7Setup.targets': 'Possible files to update',
'terminal.osc7Setup.command': 'Command to run',
'terminal.osc7Setup.run': 'Run setup',
'terminal.osc7Setup.running': 'Configuring...',
'terminal.osc7Setup.configured': 'Directory tracking configured',
@@ -279,9 +280,6 @@ export const enTerminalMessages: Messages = {
'terminal.themeModal.themeType': '{type} theme',
'terminal.hiddenTheme.title': 'Current hidden theme',
'terminal.hiddenTheme.desc': 'This theme is hidden from manual picks and will be replaced when you choose another theme.',
'topTabs.toggleTheme.systemExitTitle': 'System theme is active',
'topTabs.toggleTheme.systemExitMessage': 'Open Settings to choose a fixed Light or Dark theme.',
'topTabs.toggleTheme.openSettings': 'Open Settings',
// Custom Themes
'terminal.customTheme.section': 'Custom Themes',
@@ -294,7 +292,6 @@ export const enTerminalMessages: Messages = {
'terminal.customTheme.importDesc': 'Import from iTerm2 color scheme file',
'terminal.customTheme.importError': 'Failed to parse the selected file. Please ensure it is a valid .itermcolors XML file.',
'terminal.customTheme.delete': 'Delete Theme',
'terminal.customTheme.confirmDelete': 'Confirm Delete',
'terminal.customTheme.name': 'Name',
'terminal.customTheme.namePlaceholder': 'My Custom Theme',
'terminal.customTheme.type': 'Type',
@@ -354,10 +351,7 @@ export const enTerminalMessages: Messages = {
'cloudSync.provider.disconnect.cloudRemains': 'Encrypted sync copies may still exist in your {name} storage. To remove them, delete the sync files there. Disconnecting does not clear this device for handover.',
'cloudSync.provider.disconnect.failed': 'Could not finish disconnecting from {name}. Saved connection details may remain. Please try again.',
'cloudSync.provider.webdav': 'WebDAV',
'cloudSync.provider.webdav.desc': 'Connect to a self-hosted WebDAV endpoint',
'cloudSync.provider.s3': 'S3 Compatible',
'cloudSync.provider.s3.desc': 'Connect to S3-compatible object storage',
'cloudSync.provider.comingSoon': 'Coming soon',
'cloudSync.webdav.title': 'WebDAV Settings',
'cloudSync.webdav.desc': 'Configure a WebDAV endpoint for encrypted sync.',
'cloudSync.webdav.endpoint': 'Endpoint URL',
@@ -386,20 +380,6 @@ export const enTerminalMessages: Messages = {
'cloudSync.s3.allowInsecure': 'Allow insecure connection (ignore certificate errors)',
'cloudSync.s3.showSecret': 'Show secrets',
'cloudSync.s3.validation.required': 'Endpoint, region, bucket, access key, and secret are required.',
'cloudSync.smb.title': 'SMB Settings',
'cloudSync.smb.desc': 'Connect to an SMB/CIFS file share for encrypted sync.',
'cloudSync.smb.share': 'Share Path',
'cloudSync.smb.username': 'Username',
'cloudSync.smb.password': 'Password',
'cloudSync.smb.domain': 'Domain (optional)',
'cloudSync.smb.domainPlaceholder': 'e.g., WORKGROUP',
'cloudSync.smb.port': 'Port (optional)',
'cloudSync.smb.showSecret': 'Show password',
'cloudSync.smb.validation.share': 'Share path is required.',
'cloudSync.smb.validation.port': 'Port must be a number between 1 and 65535.',
'cloudSync.connect.smb.success': 'SMB connected successfully',
'cloudSync.connect.smb.failedTitle': 'SMB connection failed',
'cloudSync.provider.smb': 'SMB Share',
'cloudSync.connect.webdav.success': 'WebDAV connected successfully',
'cloudSync.connect.webdav.failedTitle': 'WebDAV connection failed',
'cloudSync.connect.s3.success': 'S3 connected successfully',
@@ -416,7 +396,6 @@ export const enTerminalMessages: Messages = {
'cloudSync.lastSync.minutesAgo': '{minutes} min ago',
'cloudSync.changeKey': 'Change Key',
'cloudSync.providers.title': 'Cloud Providers',
'cloudSync.syncAll': 'Sync All Connected Providers',
'cloudSync.autoSync.title': 'Auto-sync',
'cloudSync.autoSync.desc': 'Automatically sync when changes are made',
'cloudSync.strategy.title': 'Sync strategy',
@@ -481,7 +460,6 @@ export const enTerminalMessages: Messages = {
'cloudSync.localBackups.folderWarning': 'This folder alone is not a complete, portable backup. Deleting or wiping the app profile (userData) may make these restore points unreadable.',
'cloudSync.localBackups.retentionTitle': 'Backup Retention',
'cloudSync.localBackups.retentionDesc': 'Choose how many local backups Netcatty should keep.',
'cloudSync.localBackups.maxCount': 'Max backups',
'cloudSync.localBackups.maxSaved': 'Saved backup retention: {count}',
'cloudSync.localBackups.maxInvalid': 'Please enter a number between 1 and 100.',
'cloudSync.localBackups.empty': 'No local backups yet.',
@@ -604,10 +582,7 @@ export const enTerminalMessages: Messages = {
'cloudSync.clearLocal.toast.desc': 'Local version reset to 0. Sync to download from cloud.',
// Keychain
'keychain.filter.key': 'KEY',
'keychain.filter.certificate': 'CERTIFICATE',
'keychain.action.generateKey': 'Generate Key',
'keychain.action.importKey': 'Import Key',
'keychain.action.newIdentity': 'New Identity',
'keychain.action.importCertificate': 'Import Certificate',
'keychain.view.grid': 'Grid',
@@ -651,20 +626,8 @@ export const enTerminalMessages: Messages = {
'keychain.export.exporting': 'Exporting...',
'keychain.export.exportAndAttach': 'Export and Attach',
'keychain.export.title': 'Key export',
'keychain.export.exportToRequired': 'Export to *',
'keychain.export.selectHostPlaceholder': 'Select a host...',
'keychain.export.locationLabel': 'Location ~ $1 *',
'keychain.export.filenameLabel': 'Filename ~ $2 *',
'keychain.export.advanced': 'Advanced',
'keychain.export.note.supportsOnly': 'Key export currently supports only',
'keychain.export.note.systems': 'systems.',
'keychain.export.note.use': 'Use',
'keychain.export.note.customize': 'section to customize the export script.',
'keychain.export.scriptRequired': 'Script *',
'keychain.export.exportToHost': 'Export to host',
'keychain.export.failedGeneric': 'Export failed: {message}',
'keychain.field.label': 'Label',
'keychain.field.labelRequired': 'Label *',
'keychain.field.labelPlaceholder': 'Key label',
'keychain.field.privateKeyRequired': 'Private key *',
'keychain.field.publicKey': 'Public key',
@@ -700,13 +663,9 @@ export const enTerminalMessages: Messages = {
"fido.recovery.usePassword": "Use configured password",
"fido.recovery.passwordFallback": "Trying the password configured for this host",
"fido.prompt.cancelled": "Security key authentication cancelled.",
'fido.prompt.touchDone': 'I touched it',
'fido.prompt.timeout': 'FIDO prompt timed out. Try connecting again.',
'fido.error.opensshMissing': 'OpenSSH with FIDO/libfido2 is required. On macOS: brew install openssh libfido2.',
'fido.error.agentUnavailable': 'Could not start a FIDO-capable SSH agent.',
'keychain.generate.resident': 'Store credentials on the key',
'keychain.generate.verifyRequired': 'Verify PIN each time',
'keychain.action.loadResident': 'Load resident keys from security key',
'keychain.generate.keySize': 'Key size',
'keychain.generate.labelPlaceholder': 'Key label',
'keychain.generate.passphrasePlaceholder': 'Passphrase (optional)',
@@ -716,7 +675,6 @@ export const enTerminalMessages: Messages = {
'keychain.import.dropHint': 'Drop a key file here',
'keychain.import.importFromFile': 'Import from file',
'keychain.import.saveKey': 'Save Key',
'keychain.import.importedKeyLabel': 'Imported Key',
'keychain.identity.usernameRequired': 'Username *',
'keychain.identity.method.passwordOnly': 'Password',
'keychain.identity.summary.password': 'Auth password',
@@ -725,14 +683,8 @@ export const enTerminalMessages: Messages = {
'keychain.identity.summary.passwordAndKey': 'Auth password and key',
'keychain.identity.summary.passwordAndCertificate': 'Auth password and certificate',
'keychain.identity.summary.none': 'No credentials',
'keychain.identity.selectCredential': 'Select {kind}',
'keychain.identity.save': 'Save',
'keychain.identity.update': 'Update',
'keychain.keyDialog.newTitle': 'New Key',
'keychain.keyDialog.newDesc': 'Add a new SSH key',
'keychain.keyDialog.editTitle': 'Edit Key',
'keychain.keyDialog.editDesc': 'Update this SSH key',
'keychain.keyDialog.updateKey': 'Update Key',
// Tabs
'tabs.closeSessionAria': 'Close session',
@@ -744,6 +696,8 @@ export const enTerminalMessages: Messages = {
'tabs.duplicateSession': 'Duplicate Session',
'tabs.copyTabToNewWindow': 'Copy Tab to New Window',
'tabs.copyTabToNewWindowFailed': 'Failed to open tab in a new window',
'tabs.moveTabToNewWindow': 'Move Tab to New Window',
'tabs.moveTabToNewWindowFailed': 'Failed to move tab to a new window',
'tabs.closeOthers': 'Close Others',
'tabs.closeToLeft': 'Close Tabs to the Left',
'tabs.closeToRight': 'Close Tabs to the Right',
@@ -807,8 +761,6 @@ export const enTerminalMessages: Messages = {
'snippets.search.noResults.desc': 'No scripts or script packages match "{query}". Try a different search term or clear the search to browse.',
'snippets.section.packages': 'Script Packages',
'snippets.section.snippets': 'Scripts',
'snippets.kind.codeSnippet': 'Code snippet',
'snippets.kind.automationScript': 'Automation script',
'snippets.package.count': '{count} script(s)',
'snippets.commandFallback': 'Command',
'snippets.view.grid': 'Grid',
@@ -840,9 +792,6 @@ export const enTerminalMessages: Messages = {
'snippets.import.modal.multipleFiles': '{count} files selected',
'snippets.import.modal.parsedSummary': '{files} file(s), {total} script(s), {packages} script package(s), {conflicts} duplicate command(s). Host bindings are ignored.',
'snippets.import.modal.confirm': 'Confirm import',
'snippets.import.conflict.title': 'Import snippets?',
'snippets.import.conflict.desc': '{file} contains {total} snippet(s). {conflicts} duplicate command(s) already exist.',
'snippets.import.conflict.hostBindingsNote': 'Host bindings are not imported or exported with snippets.',
'snippets.import.conflict.skip': 'Skip duplicates',
'snippets.import.conflict.overwrite': 'Overwrite duplicates',
'snippets.packageDialog.title': 'New Script Package',
@@ -901,9 +850,6 @@ export const enTerminalMessages: Messages = {
'serial.field.customPort': 'Custom Port Path',
'serial.field.namedPipeHint': 'Windows VM console: enter \\\\.\\pipe\\name. The VM must create the pipe as a server. Baud rate and framing are ignored.',
'serial.field.customPortPlaceholder': 'e.g. /dev/ttys001 or COM1',
'serial.type.hardware': 'Hardware',
'serial.type.pseudo': 'Pseudo Terminal',
'serial.type.custom': 'Custom',
'serial.parity.none': 'None',
'serial.parity.even': 'Even',
'serial.parity.odd': 'Odd',
@@ -924,7 +870,6 @@ export const enTerminalMessages: Messages = {
'serial.backspace.default': 'Default (DEL, 0x7F)',
'serial.backspace.ctrlH': 'Ctrl+H (BS, 0x08)',
'serial.field.charset': 'Charset',
'serial.connectionError': 'Failed to connect to serial port',
'serial.field.baudRatePlaceholder': 'Select or enter baud rate...',
'serial.field.baudRateEmpty': 'Enter a custom baud rate',
'serial.field.customBaudRate': 'Using custom baud rate',
@@ -943,10 +888,7 @@ export const enTerminalMessages: Messages = {
'keyboard.interactive.title': 'Authentication Required',
'keyboard.interactive.desc': 'The server requires additional authentication.',
'keyboard.interactive.descWithHost': 'The server {hostname} requires additional authentication.',
'keyboard.interactive.response': 'Response',
'keyboard.interactive.verificationCode': 'Verification code',
'keyboard.interactive.enterCode': 'Enter verification code',
'keyboard.interactive.enterResponse': 'Enter response',
'keyboard.interactive.submit': 'Submit',
'keyboard.interactive.verifying': 'Verifying...',
'keyboard.interactive.savePassword': 'Save password',
+24 -110
View File
@@ -19,14 +19,6 @@ export const enVaultMessages: Messages = {
'notes.export.toast.failed': 'Failed to export notes.',
'notes.codeBlock.copied': 'Copied',
'notes.codeBlock.copyFailed': 'Failed to copy code block.',
'notes.group.prompt': 'Folder path',
'notes.group.all': 'Notebook',
'notes.group.ungrouped': 'Ungrouped',
'notes.section.notebooks': 'Notebook',
'notes.section.notes': 'Notes',
'notes.mode.edit': 'Edit',
'notes.mode.split': 'Split',
'notes.mode.preview': 'Preview',
'notes.title.placeholder': 'Note title',
'notes.editor.placeholder': 'Write Markdown notes here...',
'notes.editor.unrenderableMarkdown': 'This note contains Markdown the rich editor cannot display (for example unbalanced <tag> text). Showing the raw Markdown source instead — the content is intact.',
@@ -72,25 +64,18 @@ export const enVaultMessages: Messages = {
'notes.toolbar.divider': 'Divider',
'notes.toolbar.link': 'Insert Link',
'notes.toolbar.image': 'Insert Image',
'notes.action.pin': 'Pin Note',
'notes.action.unpin': 'Unpin Note',
'notes.tag.remove': 'Remove tag',
'notes.tag.placeholder': 'Tag name...',
'notes.tag.add': 'Add tag',
'notes.outline.title': 'Table of Contents',
'notes.outline.titleWithCount': 'Table of Contents ({count})',
'notes.outline.empty': 'No outline headings',
'notes.outline.emptyHint': 'Use # and ## in Markdown to create headings',
'notes.export.share': 'Export & Share',
'notes.export.currentNote': 'Current Note',
'notes.export.exportMarkdown': 'Export as Markdown (.md)',
'notes.export.exportHtml': 'Export as HTML (.html)',
'notes.export.copyMarkdown': 'Copy Markdown Source',
'notes.export.allNotes': 'All Notes',
'notes.export.exportAllZip': 'Export All as ZIP Archive',
'notes.export.toast.markdownSuccess': 'Markdown file exported',
'notes.export.toast.htmlSuccess': 'HTML file exported',
'notes.export.toast.zipSuccess': 'All notes exported as ZIP backup',
// Vault import
'vault.import.title': 'Add data to your vault',
@@ -261,7 +246,6 @@ export const enVaultMessages: Messages = {
'pf.tooltip.localDesc': 'Local port forwarding: Access remote services through SSH tunnel',
'pf.tooltip.remoteDesc': 'Remote port forwarding: Expose local services to remote host',
'pf.tooltip.dynamicDesc': 'Dynamic SOCKS proxy: Route traffic through SSH tunnel',
'pf.deleteActive.title': 'Delete Active Port Forwarding?',
'pf.deleteActive.desc': 'This port forwarding rule "{label}" is currently active. Deleting it will stop the tunnel first.',
'pf.deleteActive.confirm': 'Stop and Delete',
'pf.form.autoStart': 'Auto Start',
@@ -295,13 +279,9 @@ export const enVaultMessages: Messages = {
'sftp.columns.actions': 'Actions',
'sftp.sort.directoriesFirst': 'Folders first',
'sftp.emptyDirectory': 'Empty directory',
'sftp.nav.up': 'Go up',
'sftp.nav.home': 'Go to home',
'sftp.nav.refresh': 'Refresh',
'sftp.upload': 'Upload',
'sftp.uploadFiles': 'Upload files',
'sftp.uploadFolder': 'Upload folder',
'sftp.dragDropToUpload': 'Drag and drop files here to upload',
'sftp.retry': 'Retry',
'sftp.context.open': 'Open',
'sftp.context.navigateTo': 'Navigate to',
@@ -316,6 +296,12 @@ export const enVaultMessages: Messages = {
'sftp.extract.extracting': 'Extracting {fileName}...',
'sftp.extract.success': 'Extracted {fileName}',
'sftp.extract.error': 'Failed to extract {fileName}: {error}',
'sftp.packedDownload.receiving': 'Receiving packed download…',
'sftp.packedDownload.extracting': 'Restoring files…',
'sftp.packedDownload.fallback': 'Packed download is unavailable. Downloading files individually.',
'sftp.packedDownload.selection': '{count} selected items',
'sftp.packedDownload.conflict': 'An item with the same name already exists. Choose a different destination folder?',
'sftp.archive.action': 'Compress...',
'sftp.archive.title': 'Compress files',
'sftp.archive.description': 'Create an archive on the server from {count} selected items.',
@@ -340,28 +326,21 @@ export const enVaultMessages: Messages = {
'sftp.copyCurrentPath': 'Copy current path',
'sftp.copyCurrentPath.success': 'Current path copied',
'sftp.copyCurrentPath.error': 'Could not copy current path',
'sftp.viewMode.label': 'View mode',
'sftp.viewMode.list': 'List view',
'sftp.viewMode.tree': 'Tree view',
'sftp.viewMode.switchToList': 'Switch to list view',
'sftp.viewMode.switchToTree': 'Switch to tree view',
'sftp.listDensity.compact': 'Compact list',
'sftp.listDensity.comfortable': 'Comfortable list',
'sftp.listDensity.switchToCompact': 'Switch to compact list',
'sftp.listDensity.switchToComfortable': 'Switch to comfortable list',
'sftp.tree.loadError': 'Failed to load directory',
'sftp.tree.loading': 'Loading...',
'sftp.kind.folder': 'Folder',
'sftp.context.rename': 'Rename',
'sftp.context.permissions': 'Permissions',
'sftp.context.delete': 'Delete',
'sftp.context.refresh': 'Refresh',
'sftp.context.uploadFiles': 'Upload File(s)...',
'sftp.context.uploadFilesHere': 'Upload File(s) Here...',
'sftp.context.uploadFolder': 'Upload Folder...',
'sftp.context.uploadFolderHere': 'Upload Folder Here...',
'sftp.context.downloadSelected': 'Download selected ({count})',
'sftp.context.deleteSelected': 'Delete selected ({count})',
'sftp.dropFilesHere': 'Drop files here',
'sftp.itemsCount': '{count} items',
'sftp.selectedCount': '{count} selected',
@@ -370,8 +349,6 @@ export const enVaultMessages: Messages = {
'sftp.task.waiting': 'Waiting...',
'sftp.transfer.preparing': 'preparing...',
'sftp.status.loading': 'Loading...',
'sftp.status.uploading': 'Uploading...',
'sftp.status.ready': 'Ready',
'sftp.transfers': 'Transfers',
'sftp.transfers.active': '{count} active',
'sftp.transfers.clearCompleted': 'Clear completed',
@@ -435,7 +412,6 @@ export const enVaultMessages: Messages = {
'sftp.transferCenter.applyAll': 'Apply to all',
'sftp.transfers.resizeNameColumn': 'Resize file name column',
'sftp.transfers.dragToResize': 'Drag to resize',
'sftp.goUp': 'Go up',
'sftp.goToTerminalCwd': 'Go to terminal directory',
'sftp.locatePathInTerminal': 'Open path in terminal',
'sftp.followTerminalCwd': 'Follow terminal directory',
@@ -445,35 +421,30 @@ export const enVaultMessages: Messages = {
'sftp.encoding.auto': 'Auto',
'sftp.encoding.utf8': 'UTF-8',
'sftp.encoding.gb18030': 'GB18030',
'sftp.goBack': 'Go back',
'sftp.goForward': 'Go forward',
'sftp.goHome': 'Go to home',
'sftp.goRoot': 'Go to root',
'sftp.folderName': 'Folder name',
'sftp.folderName.placeholder': 'Enter folder name',
'sftp.fileName': 'File name',
'sftp.fileName.placeholder': 'Enter file name',
'sftp.prompt.newFolderName': 'New folder name?',
'sftp.rename.title': 'Rename',
'sftp.rename.newName': 'New name',
'sftp.rename.placeholder': 'Enter new name',
'sftp.confirm.deleteOne': 'Delete "{name}"?',
'sftp.deleteConfirm.single': 'Delete "{name}"?',
'sftp.deleteConfirm.title': 'Delete {count} item(s)?',
'sftp.deleteConfirm.desc': 'This action cannot be undone. The following will be deleted:',
'sftp.deleteConfirm.descSingle': 'This action cannot be undone.',
'sftp.deleteConfirm.host': 'Host',
'sftp.deleteConfirm.path': 'Path',
'sftp.error.loadFailed': 'Failed to load directory',
'sftp.error.downloadFailed': 'Download failed',
'sftp.error.uploadFailed': 'Upload failed',
'sftp.error.deleteFailed': 'Delete failed',
'sftp.error.createFolderFailed': 'Failed to create folder',
'sftp.error.createFileFailed': 'Failed to create file',
'sftp.error.invalidFileName': 'Filename contains invalid characters: {chars}',
'sftp.error.reservedName': 'This filename is reserved by the system',
'sftp.overwrite.title': 'File Already Exists',
'sftp.overwrite.desc': 'A file named "{name}" already exists. Do you want to replace it?',
'sftp.overwrite.confirm': 'Replace',
'sftp.error.renameFailed': 'Failed to rename',
'sftp.picker.title': 'Select Host',
'sftp.picker.desc': 'Pick a host for the {side} pane',
'sftp.picker.searchPlaceholder': 'Search hosts...',
@@ -481,8 +452,6 @@ export const enVaultMessages: Messages = {
'sftp.picker.local.desc': 'Browse local files',
'sftp.picker.local.badge': 'Local',
'sftp.picker.connected.section': 'Connected',
'sftp.picker.connected.badge': 'Live',
'sftp.picker.connected.connecting': 'Connecting',
'sftp.picker.noMatch': 'No matching hosts',
'sftp.permissions.title': 'Edit Permissions',
'sftp.permissions.owner': 'Owner',
@@ -490,16 +459,12 @@ export const enVaultMessages: Messages = {
'sftp.permissions.others': 'Others',
'sftp.permissions.octal': 'Octal',
'sftp.permissions.symbolic': 'Symbolic',
'sftp.permissions.success': 'Permissions updated successfully',
'sftp.permissions.failed': 'Failed to update permissions',
'sftp.pane.local': 'Local',
'sftp.pane.remote': 'Remote',
'sftp.pane.selectHost': 'Select host',
'sftp.pane.selectHostToStart': 'Select a host to start',
'sftp.pane.chooseFilesystem': 'Choose a local or remote filesystem to browse',
'sftp.tabs.addTab': 'Add new tab',
'sftp.tabs.closeTab': 'Close tab',
'sftp.tabs.newTab': 'New Tab',
'sftp.tabs.copyDefaultPath': 'Copy tab (default path)',
'sftp.tabs.copyCurrentPath': 'Copy and go to current path',
'sftp.conflict.title': 'File Conflict',
@@ -525,47 +490,27 @@ export const enVaultMessages: Messages = {
'sftp.conflict.action.replace': 'Replace',
// SFTP Upload Phases
'sftp.upload.phase.compressing': 'Compressing',
'sftp.upload.phase.uploading': 'Uploading',
'sftp.upload.phase.extracting': 'Extracting',
'sftp.upload.phase.compressed': 'Compressed',
// SFTP File Opener
'sftp.context.copyPath': 'Copy file path',
'sftp.context.insertPathToTerminal': 'Insert path into terminal',
'sftp.context.cdInTerminal': 'Open in terminal (cd)',
'sftp.terminal.insertBlockedUnsafeQuote': 'Cannot insert path while the terminal cursor is inside an unclosed quote or escape',
'sftp.context.openWithDefault': 'Open with system default',
'sftp.context.openWith': 'Open with...',
'sftp.context.edit': 'Edit',
'sftp.context.preview': 'Preview',
'sftp.opener.title': 'Open with',
'sftp.opener.desc': 'Choose an application to open this file',
'sftp.opener.builtInEditor': 'Built-in Editor',
'sftp.opener.editDescription': 'Edit text files',
'sftp.opener.builtInImageViewer': 'Built-in Image Viewer',
'sftp.opener.previewDescription': 'Preview images',
'sftp.opener.systemApp': 'Choose Application...',
'sftp.opener.systemAppDescription': 'Select an application from your computer',
'sftp.opener.onlySystemApp': 'This file can only be opened with an external application',
'sftp.opener.noAppsAvailable': 'No applications available',
'sftp.opener.noExtension': 'files without extension',
'sftp.opener.setDefault': 'Always use this for {ext} files',
'sftp.opener.confirmTitle': 'Set as Default?',
'sftp.opener.confirmDescription': 'Do you want to always use {app} for {ext} files?',
'sftp.opener.yesRemember': 'Yes, remember this choice',
'sftp.opener.justOnce': 'Just this once',
'sftp.opener.confirm.title': 'Set Default Application',
'sftp.opener.confirm.desc': 'Do you want to always open .{ext} files with this application?',
'sftp.editor.title': 'Text Editor',
'sftp.editor.save': 'Save to Remote',
'sftp.editor.saving': 'Saving...',
'sftp.editor.saved': 'Saved successfully',
'sftp.editor.saveFailed': 'Failed to save file',
'sftp.editor.unsavedChanges': 'You have unsaved changes. Close anyway?',
'sftp.editor.syntaxHighlight': 'Syntax Highlighting',
'sftp.preview.title': 'Image Preview',
'sftp.preview.zoomIn': 'Zoom In',
'sftp.preview.zoomOut': 'Zoom Out',
'sftp.preview.resetZoom': 'Reset Zoom',
'sftp.preview.fitToWindow': 'Fit to Window',
// Settings > SFTP File Associations
'settings.tab.sftpFileAssociations': 'SFTP',
@@ -644,28 +589,16 @@ export const enVaultMessages: Messages = {
'sftp.autoSync.error': 'Failed to sync file: {error}',
// SFTP Folder Upload Progress
'sftp.upload.progress': 'Uploading {current} of {total} files...',
'sftp.upload.uploading': 'Uploading...',
'sftp.upload.compressing': 'Compressing...',
'sftp.upload.extracting': 'Extracting...',
'sftp.upload.scanning': 'Scanning files...',
'sftp.upload.completed': 'Completed',
'sftp.upload.compressed': 'Compressed Transfer',
'sftp.upload.currentFile': 'Current: {fileName}',
'sftp.upload.cancelled': 'Upload cancelled',
'sftp.upload.noFiles': 'No files to upload',
'sftp.upload.partialSuccess': 'Uploaded {success} file(s); {failed} failed',
'sftp.upload.cancel': 'Cancel',
'sftp.upload.completedToPath': 'Uploaded to {path}',
// SFTP Download
'sftp.download.completed': 'Downloaded',
'sftp.download.cancelled': 'Download cancelled',
// SFTP Reconnecting
'sftp.reconnecting.title': 'Reconnecting...',
'sftp.reconnecting.desc': 'Connection lost, attempting to reconnect',
'sftp.reconnected': 'Connection restored',
'sftp.error.reconnectFailed': 'Failed to reconnect. Please try again.',
'sftp.error.connectionLostManual': 'Connection lost. Please reconnect manually.',
'sftp.error.connectionLostReconnecting': 'Connection lost. Reconnecting...',
@@ -683,6 +616,17 @@ export const enVaultMessages: Messages = {
'settings.sftp.compressedUpload.enable': 'Enable folder compression',
'settings.sftp.compressedUpload.enableDesc': 'Automatically compress folders using tar before transfer. Requires tar support on the server. Falls back to regular transfer if not available.',
'settings.sftp.packedDownload': 'Packed downloads',
'settings.sftp.packedDownload.enable': 'Pack folders and multiple items for download',
'settings.sftp.packedDownload.enableDesc': 'Download the selection in one stream and restore its original layout on this device. If the server cannot pack it, download files individually.',
'settings.sftp.downloadLocation': 'Download location',
'settings.sftp.downloadLocation.directory': 'Default download folder',
'settings.sftp.downloadLocation.directoryDesc': 'SFTP download dialogs open in this folder. If it is not set or no longer exists, the system Downloads folder is used.',
'settings.sftp.downloadLocation.systemDefault': 'System Downloads folder',
'settings.sftp.downloadLocation.browse': 'Browse…',
'settings.sftp.downloadLocation.reset': 'Use the system Downloads folder',
'settings.sftp.downloadLocation.select': 'Choose default download folder',
'settings.sftp.skipUnchanged.enable': 'Skip unchanged files',
'settings.sftp.skipUnchanged.enableDesc': 'Skip files whose size and modification time already match the destination (rsync-style). Disabled when replacing a folder into a staging path.',
@@ -741,12 +685,6 @@ export const enVaultMessages: Messages = {
'hostDetails.saveAria': 'Save',
// Host connection test
'hostConnectionTest.title': 'Test Connection',
'hostConnectionTest.test': 'Test',
'hostConnectionTest.chainOf': 'Chain {current} of {total}',
'hostConnectionTest.success': 'Connection successful',
'hostConnectionTest.successHint': 'The host accepted your credentials. You can close this window.',
'hostConnectionTest.connecting': 'Connecting… timeout in {seconds}s',
'hostConnectionTest.failed': 'Connection failed.',
'hostConnectionTest.retry': 'Retry',
'hostConnectionTest.credentialsUnavailable': 'Saved credentials cannot be decrypted on this device. Re-enter them below.',
'hostDetails.section.address': 'Address',
@@ -783,11 +721,8 @@ export const enVaultMessages: Messages = {
'hostDetails.notes.toggle.show': 'Show notes editor',
'hostDetails.notes.toggle.hide': 'Hide notes editor',
'hostDetails.group.placeholder': 'Parent Group',
'hostDetails.section.credentials': 'Credentials',
'hostDetails.section.portCredentials': 'Port & Credentials',
'hostDetails.section.appearance': 'Appearance',
'hostDetails.distro.title': 'Linux Distribution',
'hostDetails.distro.desc': 'Auto-detect on connect, or override the distro icon manually.',
'hostDetails.icon.title': 'Host Icon',
'hostDetails.icon.sectionTitle': 'Color & Icon',
'hostDetails.icon.desc': 'Choose the icon source and color for this host.',
@@ -799,7 +734,6 @@ export const enVaultMessages: Messages = {
'hostDetails.icon.mode.custom': 'Custom',
'hostDetails.icon.reset': 'Reset host icon',
'hostDetails.icon.colorLabel': 'Icon color',
'hostDetails.icon.colorDefault': 'Default',
'hostDetails.icon.colorAuto': 'Automatic',
'hostDetails.icon.colorManual': 'Manual',
'hostDetails.icon.colorChoice': 'Color',
@@ -850,7 +784,6 @@ export const enVaultMessages: Messages = {
'hostDetails.distro.mode.auto': 'Auto-detect',
'hostDetails.distro.mode.manual': 'Manual override',
'hostDetails.distro.detectedLabel': 'Current',
'hostDetails.distro.manualLabel': 'Override',
'hostDetails.distro.pending': 'Detect after first connection',
'hostDetails.distro.unknown': 'Unknown',
'hostDetails.distro.option.linux': 'Generic Linux',
@@ -901,7 +834,6 @@ export const enVaultMessages: Messages = {
'hostDetails.auth.mfaFirst': 'Prefer interactive auth',
'hostDetails.auth.mfaFirst.desc': 'For servers that require password and MFA through keyboard-interactive.',
'hostDetails.totp.title': 'Authenticator (TOTP)',
'hostDetails.totp.enable': 'Save a TOTP secret for this host',
'hostDetails.totp.setup': 'Set up…',
'hostDetails.totp.edit': 'Edit',
'hostDetails.totp.modalTitle': 'Set up authenticator',
@@ -1004,10 +936,8 @@ export const enVaultMessages: Messages = {
'hostDetails.jumpHosts.direct': 'Direct',
'hostDetails.jumpHosts.configure': 'Configure Proxy Hosts',
'hostDetails.proxy': 'Proxy via HTTP/SOCKS5/Command',
'hostDetails.proxy.none': 'None',
'hostDetails.proxy.direct': 'Direct (no proxy)',
'hostDetails.proxy.directHint': 'Does not use a group or global default proxy',
'hostDetails.proxy.edit': 'Edit Proxy',
'hostDetails.proxy.configure': 'Configure Proxy',
'hostDetails.proxyPanel.title': 'Proxy via HTTP/SOCKS5/Command',
'hostDetails.proxyPanel.hostPlaceholder': 'Proxy host',
@@ -1017,7 +947,6 @@ export const enVaultMessages: Messages = {
'hostDetails.proxyPanel.credentials': 'Credentials',
'hostDetails.proxyPanel.usernamePlaceholder': 'Username',
'hostDetails.proxyPanel.passwordPlaceholder': 'Password',
'hostDetails.proxyPanel.identities': 'Identities',
'hostDetails.proxyPanel.keychainIdentity': 'Keychain identity',
'hostDetails.proxyPanel.manualCredentials': 'Manual credentials',
'hostDetails.proxyPanel.remove': 'Remove Proxy',
@@ -1041,8 +970,6 @@ export const enVaultMessages: Messages = {
'hostDetails.envVars.newVariable': 'New Variable',
'hostDetails.envVars.variableName': 'Variable name',
'hostDetails.chain.title': 'Edit Chain',
'hostDetails.chain.desc': 'Adding another host will create a connection to {host}.',
'hostDetails.chain.addHost': 'Add a Host',
'hostDetails.chain.target': 'Target',
'hostDetails.chain.availableHosts': 'Available Hosts',
'hostDetails.chain.clear': 'Clear',
@@ -1089,6 +1016,8 @@ export const enVaultMessages: Messages = {
'localShell.field.shellResolved': 'Runs {command}',
'localShell.field.startDir': 'Start directory',
'localShell.field.startDirPlaceholder': 'Inherit global start directory (home if unset)',
'localShell.field.startupCommandPlaceholder': 'Command to run after shell starts (e.g. npm run dev)',
'localShell.field.startupCommandDesc': 'Runs automatically after the local shell starts in the configured directory.',
'localShell.saveAndConnect': 'Save & Connect',
'hostDetails.plugin.title': 'Plugin connection',
@@ -1108,28 +1037,14 @@ export const enVaultMessages: Messages = {
'hostDetails.plugin.useSsh': 'Use SSH instead',
// Host form (legacy modal)
'hostForm.title.edit': 'Edit Host',
'hostForm.title.new': 'New Host',
'hostForm.desc.edit': 'Update connection details for this host',
'hostForm.desc.new': 'Create a new SSH host entry',
'hostForm.field.label': 'Label',
'hostForm.placeholder.label': 'My Production Server',
'hostForm.field.hostname': 'Hostname / IP',
'hostForm.placeholder.hostname': '192.168.1.1',
'hostForm.field.port': 'Port',
'hostForm.field.username': 'Username',
'hostForm.field.osType': 'OS Type',
'hostForm.placeholder.selectOs': 'Select OS',
'hostForm.field.group': 'Group',
'hostForm.placeholder.group': 'e.g. AWS, DigitalOcean',
'hostForm.field.tags': 'Tags',
'hostForm.placeholder.addTag': 'Add a tag...',
'hostForm.auth.method': 'Authentication Method',
'hostForm.auth.password': 'Password',
'hostForm.auth.sshKey': 'SSH Key',
'hostForm.auth.selectKey': 'Select an SSH Key',
'hostForm.auth.noKeys': 'No keys available',
'hostForm.auth.noKeysHint': 'No SSH keys found in Keychain. Please create one first.',
'hostForm.saveHost': 'Save Host',
// Connection logs
@@ -1148,7 +1063,6 @@ export const enVaultMessages: Messages = {
'logs.action.delete': 'Delete',
// Log view
'logView.customizeAppearance': 'Customize appearance',
'logView.appearance': 'Appearance',
'logView.readOnly': 'Read-only',
'logView.export': 'Export',
+23 -7
View File
@@ -62,6 +62,9 @@ export const esAiMessages: Messages = {
'ai.providers.apiKey': 'Clave de API',
'ai.providers.apiKey.placeholder': 'Ingresa la clave de API',
'ai.providers.apiKey.decrypting': 'Descifrando...',
'ai.providers.opencodeGo.help': 'Pega una clave de API de OpenCode para usar OpenCode Go. La URL base y la lista de modelos se configuran automáticamente.',
'ai.providers.opencodeGo.getKey': 'Obtener una clave de API',
'ai.providers.fixedBaseUrl.help': 'Fijada por el proveedor. Netcatty elige automáticamente la ruta del endpoint para cada modelo.',
'ai.providers.baseUrl': 'URL base',
'ai.providers.baseUrl.anthropicHelp': 'Compatible con Anthropic: host con o sin /v1 (por ejemplo https://gateway.example o https://gateway.example/v1). La detección y el chat usan /v1/models y /v1/messages.',
'ai.providers.baseUrl.ollamaHelp': 'Ollama local: http://localhost:11434/v1 (sin API key). Ollama Cloud: https://ollama.com/v1 y tu clave de Cloud.',
@@ -615,6 +618,23 @@ export const esAiMessages: Messages = {
'ai.chat.rebindUsage': 'Uso: /rebind <número de /chats>',
'ai.chat.rebindDone': 'Chat «{title}» reasociado a este panel.',
'ai.chat.rebindUnavailable': 'No hay destino de reasociación en el ámbito de este panel.',
'ai.chat.managerScopeTab': 'Chats actuales',
'ai.chat.managerAllChatsTab': 'Todos los chats',
'ai.chat.managerSearchPlaceholder': 'Buscar títulos de chats…',
'ai.chat.managerFilterAllAgents': 'Todos los agentes',
'ai.chat.managerMoreActions': 'Más acciones',
'ai.chat.managerOpen': 'Abrir en este panel',
'ai.chat.managerOpenDisabled': 'Vinculado a otro espacio de trabajo o terminal',
'ai.chat.managerRebind': 'Mover a…',
'ai.chat.managerRebindPick': 'Elegir terminal o espacio de trabajo…',
'ai.chat.managerRebindHere': 'Panel actual',
'ai.chat.managerRebindDone': 'Se movió «{title}» a {target}.',
'ai.chat.managerExportOne': 'Exportar este chat',
'ai.chat.managerBadgeActive': 'Activo',
'ai.chat.managerBadgeIdle': 'Inactivo',
'ai.chat.managerMessagesCount': '{n} mensajes',
'ai.chat.managerDeleteTitle': '¿Eliminar este chat?',
'ai.chat.managerDeleteMessage': '«{title}» y sus mensajes se eliminarán de todos los paneles. Esta acción no se puede deshacer.',
'ai.chat.justNow': 'Ahora mismo',
'ai.chat.minutesAgo': 'hace {n} min',
'ai.chat.hoursAgo': 'hace {n} h',
@@ -702,6 +722,9 @@ export const esAiMessages: Messages = {
'ai.safety.responseIdleTimeout.unit': 'seg',
'ai.safety.maxIterations': 'Máximo de iteraciones',
'ai.safety.maxIterations.description': 'Máximo de bucles de uso de herramientas de IA para evitar una ejecución descontrolada. Los agentes externos pueden tener sus propios límites de iteración internos que tienen prioridad.',
'ai.safety.toolOutputMaxChars': 'Límite de salida de herramientas de IA integrada',
'ai.safety.toolOutputMaxChars.description': 'Máximo de caracteres que se mantienen en línea por resultado de herramienta de la IA integrada (como comandos de terminal o lecturas SFTP) antes de truncar y guardar la salida completa en un identificador (2,000–200,000).',
'ai.safety.toolOutputMaxChars.unit': 'car.',
'ai.safety.blocklist': 'Lista de bloqueo de comandos',
'ai.safety.blocklist.description': 'Patrones regex para bloquear comandos peligrosos ejecutados mediante Netcatty.',
'ai.safety.blocklist.placeholder': 'Patrón regex...',
@@ -732,9 +755,6 @@ export const esAiMessages: Messages = {
'terminal.layer.theme': 'Tema',
'terminal.layer.notes': 'Notas',
'terminal.layer.aiChat': 'Chat de IA',
'terminal.layer.movePanelLeft': 'Mover panel a la izquierda',
'terminal.layer.movePanelRight': 'Mover panel a la derecha',
'terminal.layer.movePanelBottom': 'Mover panel a la parte inferior',
'terminal.layer.choosePanelPosition': 'Cambiar posición',
'terminal.layer.dockLeft': 'Izquierda',
'terminal.layer.dockRight': 'Derecha',
@@ -768,19 +788,15 @@ export const esAiMessages: Messages = {
'terminal.layer.hostTree.details.protocol': 'Protocolo',
'terminal.layer.hostTree.details.group': 'Grupo',
'terminal.layer.hostTree.details.tags': 'Etiquetas',
'terminal.layer.hostTree.details.lastConnected': 'Última conexión',
'topTabs.openQuickSwitcher': 'Abrir selector rápido',
'topTabs.moreTabs': 'Más pestañas',
'topTabs.aiAssistant': 'Asistente de IA',
'topTabs.newLocalTerminal': 'Nueva terminal local',
'topTabs.controlPanel': 'Controles rápidos',
'topTabs.controlPanel.externalMcp': 'MCP externo',
'topTabs.controlPanel.theme': 'Tema',
'topTabs.controlPanel.theme.light': 'Claro',
'topTabs.controlPanel.theme.dark': 'Oscuro',
'topTabs.controlPanel.theme.system': 'Sistema',
'topTabs.externalMcp.enable': 'Habilitar MCP externo',
'topTabs.externalMcp.disable': 'Desactivar MCP externo',
'topTabs.windowOpacity': 'Opacidad de la ventana',
'topTabs.openSettings': 'Abrir Configuración',
'ai.chat.sessionHistory': 'Historial de sesiones',
+6 -14
View File
@@ -84,7 +84,6 @@ export const esCoreMessages: Messages = {
'common.edit': 'Editar',
'common.clear': 'Limpiar',
'common.optional': 'Opcional',
'common.selectPlaceholder': 'Seleccionar...',
'common.add': 'Agregar',
'common.rename': 'Renombrar',
'common.refresh': 'Actualizar',
@@ -124,11 +123,9 @@ export const esCoreMessages: Messages = {
'field.label': 'Etiqueta',
'field.type': 'Tipo',
'auth.keyType': 'Tipo {type}',
'auth.showAllKeys': 'Mostrar todas las claves',
// Dialogs / prompts
'confirm.deleteHost': '¿Eliminar el host "{name}"?',
'confirm.deleteIdentity': '¿Eliminar la identidad "{name}"?',
'confirm.removeProvider': '¿Quitar el proveedor "{name}"?',
'confirm.closeBusyTerminal.title': 'Confirmar cierre',
'confirm.closeBusyTerminal.message': 'El proceso "{command}" aún se está ejecutando y se terminará.',
@@ -401,7 +398,6 @@ export const esCoreMessages: Messages = {
'tray.status.inactive': 'Inactivo',
'tray.status.error': 'Error',
'tray.status.unknown': 'Desconocido',
'tray.recentHosts': 'Hosts recientes',
'tray.empty.title': 'Nada por aquí todavía',
'tray.empty.subtitle': 'Ve a conectarte a un servidor, te extrañan 🚀',
'tray.quit': 'Salir de Netcatty',
@@ -460,9 +456,6 @@ export const esCoreMessages: Messages = {
'update.downloadFailed.message': 'No se pudo descargar la actualización. Puedes descargarla manualmente.',
'update.needsSave.title': 'Cambios sin guardar',
'update.needsSave.message': 'Primero guarda los editores abiertos y luego haz clic en Reiniciar ahora de nuevo para instalar la actualización.',
'update.openReleases': 'Abrir versiones',
'update.remindLater': 'Recordarme después',
'update.skipVersion': 'Omitir esta versión',
// Settings > Appearance
'settings.appearance.uiTheme': 'Tema de la interfaz',
@@ -482,7 +475,7 @@ export const esCoreMessages: Messages = {
'settings.appearance.themeColor.dark': 'Paleta oscura',
'settings.appearance.customCss': 'CSS personalizado',
'settings.appearance.customCss.desc':
'Agrega CSS personalizado para personalizar la apariencia de la aplicación. Los cambios se aplican de inmediato. Las pestañas superiores seleccionadas (`.top-tab[data-active="true"]`) leen `--top-tab-active-bg`, `--top-tab-active-fg` y `--top-tab-active-border`. Si no las defines, se conserva el aspecto actual.',
'Agrega CSS personalizado para personalizar la apariencia de la aplicación. Los cambios se aplican de inmediato.',
'settings.appearance.customCss.help.ariaLabel': 'Ayuda de CSS personalizado',
'settings.appearance.customCss.help.title': 'Guía de CSS personalizado',
'settings.appearance.customCss.help.body': `Las principales regiones de la interfaz exponen un atributo \`data-section\` que puedes usar como destino. Los cambios se aplican en cuanto editas el CSS.
@@ -912,7 +905,9 @@ Resalta el panel dividido enfocado:
'settings.terminal.connection.temporaryNetworkDeviceMode': 'Modo de dispositivo de red para conexiones temporales',
'settings.terminal.connection.temporaryNetworkDeviceMode.desc': 'Las conexiones SSH sin un host guardado, incluidos los inicios externos y la conexión rápida, se inician en modo de dispositivo de red. Los hosts y grupos guardados conservan su propio tipo de dispositivo. Desactivado de forma predeterminada.',
'settings.terminal.connection.sshAutoReconnectEnabled': 'Reconectar sesiones SSH automáticamente',
'settings.terminal.connection.sshAutoReconnectEnabled.desc': 'Cuando está activado, las sesiones SSH establecidas que se caen inesperadamente intentan reconectarse cada 5 segundos hasta que la pestaña se cierra o la conexión se establece.',
'settings.terminal.connection.sshAutoReconnectEnabled.desc': 'Reintenta las sesiones SSH desconectadas inesperadamente con el intervalo configurado hasta cerrar la pestaña o restablecer la conexión.',
'settings.terminal.connection.sshAutoReconnectInterval': 'Intervalo de reconexión SSH (segundos)',
'settings.terminal.connection.sshAutoReconnectInterval.desc': 'Espera entre intentos: 5–3600 segundos (predeterminado 5). Los cambios se aplican al siguiente intento programado, sin alterar una espera en curso.',
'settings.terminal.connection.keepaliveInterval': 'Intervalo de keepalive',
'settings.terminal.connection.keepaliveInterval.desc': 'Con qué frecuencia (en segundos) enviar paquetes keepalive a nivel de SSH. Pon 0 para desactivarlo globalmente; ten en cuenta que los hosts individuales pueden anular esto en su propia configuración.',
'settings.terminal.connection.keepaliveCountMax': 'Máximo de keepalives sin respuesta',
@@ -1044,6 +1039,7 @@ Resalta el panel dividido enfocado:
'settings.shortcuts.binding.close-tab': 'Cerrar pestaña',
'settings.shortcuts.binding.close-session': 'Cerrar panel de sesión',
'settings.shortcuts.binding.new-tab': 'Nueva pestaña local',
'settings.shortcuts.binding.reopen-closed-tab': 'Reabrir pestaña cerrada',
'settings.shortcuts.binding.copy': 'Copiar desde la terminal',
'settings.shortcuts.binding.paste': 'Pegar en la terminal',
'settings.shortcuts.binding.paste-selection': 'Pegar selección en la terminal',
@@ -1083,8 +1079,6 @@ Resalta el panel dividido enfocado:
'settings.shortcuts.binding.sftp-navigate-to': 'Ir al directorio seleccionado',
// Context menus / common actions
'action.newHost': 'Nuevo host',
'action.newSubfolder': 'Nueva subcarpeta',
'action.copyPublicKey': 'Copiar clave pública',
'action.keyExport': 'Exportar clave',
'action.edit': 'Editar',
@@ -1319,12 +1313,9 @@ Resalta el panel dividido enfocado:
"settings.plugins.manager.remove": "Desinstalar",
"settings.plugins.manager.removeNote": "La desinstalación elimina el código y los datos KV locales. Se conservan los ajustes del usuario, los secretos y los datos auxiliares de sincronización.",
"settings.plugins.permissions.statusUnknown": "Estado desconocido",
"plugins.sidebar.extensions": "Páginas de extensiones",
"plugins.sidebar.selectTerminal": "Selecciona primero un terminal abierto.",
"plugins.sidebar.loading": "Cargando página de extensión…",
"plugins.vault.loading": "Cargando página del plugin…",
"plugins.vault.extensions": "Extensiones",
"plugins.vault.back": "Volver a hosts",
"plugins.interaction.title": "Solicitud de complemento",
"plugins.interaction.sharing": "El texto compartido estará disponible para este complemento y sus capacidades autorizadas, incluida la red. Leer no autoriza un nuevo destino de red.",
"plugins.interaction.input": "Introducir texto",
@@ -1473,6 +1464,7 @@ Resalta el panel dividido enfocado:
'plugins.hostActions.selectionNote': 'Solo se comparten los nombres, direcciones, usuarios, protocolos, grupos y etiquetas guardados de los equipos seleccionados. Los grupos solo incluyen los equipos seleccionados ahora. Las solicitudes posteriores de edición o conexión siguen los permisos de este complemento.',
'plugins.hostActions.create': 'Revisar borrador de equipo',
'plugins.hostActions.edit': 'Revisar cambios del equipo',
'plugins.hostActions.streamNote': 'Permite que este complemento envíe y reciba datos en este destino a través del servidor SSH seleccionado. Las direcciones se resuelven en ese servidor. Esto puede leer o modificar datos de bases de datos. No se abrirá ninguna terminal ni se ejecutarán scripts de inicio. Las contraseñas y claves SSH permanecen en la aplicación. Selecciona un servidor SSH para continuar.',
'plugins.hostActions.connect': 'Confirmar conexión',
'plugins.hostActions.fieldDiff': 'Cambios que se guardarán',
'plugins.hostActions.defaultsWarning': 'Se aplican los ajustes de conexión guardados. Cambiar el grupo puede cambiar la autenticación, el proxy y los scripts heredados.',
-20
View File
@@ -1,6 +1,5 @@
export const esScriptsMessages = {
'scripts.meta.name': 'Nombre',
'scripts.meta.language': 'Lenguaje',
'scripts.meta.description': 'Descripción',
'scripts.meta.descriptionPlaceholder': 'Notas opcionales sobre este script',
'scripts.meta.trigger': 'Disparador',
@@ -15,7 +14,6 @@ export const esScriptsMessages = {
'scripts.actions.openEditor': 'Abrir editor',
'scripts.actions.openEditorHint': 'Editar el script en una ventana más grande',
'scripts.editor.modalTitle': 'Editor de scripts',
'scripts.editor.modalSubtitle': 'Edita los metadatos y el código del script en un espacio de trabajo más amplio.',
'scripts.editor.lineCount': '{count} líneas',
'scripts.editor.resize': 'Redimensionar el editor',
'scripts.targets.hint': 'Los grupos seleccionados se resuelven dinámicamente, por lo que los hosts agregados después se incluyen automáticamente.',
@@ -86,17 +84,13 @@ export const esScriptsMessages = {
'scripts.dialog.retry': 'Reintentar',
'scripts.dialog.skip': 'Omitir',
'scripts.dialog.abort': 'Abortar',
'scripts.running.stepProgress': 'Paso {current} / {total}',
'scripts.running.determinateProgress': '{label} {current}/{total}',
'scripts.running.progressFallback': 'Progreso',
'scripts.running.operationsCount': '{count} operaciones',
'scripts.running.opsPrefix': '',
'scripts.running.opsSuffix': ' operaciones',
'scripts.running.elapsedLabel': 'Transcurrido',
'scripts.running.lastSentLabel': 'Enviado:',
'scripts.running.elapsed': '{elapsed}',
'scripts.running.completedSummary': 'Completado · {count} operaciones · {elapsed}',
'scripts.running.dismissHint': 'Toca cerrar para descartar',
'scripts.running.dismiss': 'Cerrar',
'scripts.running.viewLogs': 'Ver registros',
'scripts.running.logTitle': '{name} · Registro de ejecución',
@@ -111,26 +105,12 @@ export const esScriptsMessages = {
'vault.nav.scripts': 'Scripts',
'snippets.action.newScript': 'Nuevo script de automatización',
'hostDetails.section.automation': 'Automatización',
'hostDetails.automation.loginScript': 'Script de inicio de sesión',
'hostDetails.automation.loginScriptPlaceholder': 'Selecciona un script',
'hostDetails.automation.none': 'Ninguno',
'hostDetails.automation.outputTriggers': 'Disparadores de salida',
'hostDetails.automation.addTrigger': 'Agregar disparador',
'hostDetails.automation.triggerPatternPlaceholder': 'Patrón de regex',
'hostDetails.automation.linkedScripts': 'Scripts vinculados',
'hostDetails.automation.linkedScriptsEmpty': 'Aún no hay scripts vinculados a este host.',
'hostDetails.automation.linkScriptPlaceholder': 'Vincular script existente…',
'hostDetails.automation.unlink': 'Desvincular',
'hostDetails.automation.equivalenceHint': 'Los vínculos agregan este host a la lista de destinos del script en Scripts. Ambas vistas se mantienen sincronizadas.',
'hostDetails.automation.queueHint': 'Los scripts se ejecutan en orden cuando este host se conecta. Los scripts globales se ejecutan primero, luego esta cola.',
'hostDetails.automation.globalScripts': 'Scripts de conexión globales',
'hostDetails.automation.globalScriptsHint': 'Se ejecutan primero en cada conexión. Reordena según el orden de clasificación de la biblioteca de Scripts.',
'hostDetails.automation.connectQueue': 'Cola de ejecución de este host',
'hostDetails.automation.connectQueueEmpty': 'Aún no hay scripts de conexión en cola para este host.',
'hostDetails.automation.addToQueuePlaceholder': 'Agregar script a la cola…',
'hostDetails.automation.moveUp': 'Subir',
'hostDetails.automation.moveDown': 'Bajar',
'hostDetails.automation.removeFromQueue': 'Quitar de la cola',
'hostDetails.automation.dragHandle': 'Arrastra para reordenar',
'hostDetails.automation.queueDragHint': 'Arrastra los elementos para reordenar la cola de conexión.',
};
@@ -14,13 +14,11 @@ export const esSystemManagerMessages: Messages = {
'systemManager.tabs.docker': 'Docker',
'systemManager.tabs.gpu': 'GPU',
'systemManager.tabs.ariaLabel': 'Secciones del administrador del sistema',
'systemManager.popup.loading': 'Abriendo terminal…',
'systemManager.popup.startupFailed': 'El comando de inicio no se completó correctamente. Verifica que el destino siga disponible e inténtalo de nuevo.',
'systemManager.errors.loadProcesses': 'No se pudieron cargar los procesos',
'systemManager.errors.loadTmux': 'No se pudieron cargar las sesiones de tmux',
'systemManager.errors.loadTmuxWindows': 'No se pudieron cargar las ventanas de tmux',
'systemManager.errors.loadTmuxPanes': 'No se pudieron cargar los paneles de tmux',
'systemManager.errors.loadTmuxClients': 'No se pudieron cargar los clientes de tmux',
'systemManager.errors.actionFailed': 'La acción falló',
'systemManager.errors.loadDocker': 'No se pudieron cargar los contenedores',
@@ -28,7 +26,6 @@ export const esSystemManagerMessages: Messages = {
'systemManager.errors.loadDockerImages': 'No se pudieron cargar las imágenes',
'systemManager.errors.loadKubernetes': 'No se pudieron cargar los recursos de Kubernetes',
'systemManager.errors.loadPods': 'No se pudieron cargar los pods',
'systemManager.errors.loadOverview': 'No se pudo cargar el resumen del sistema',
'systemManager.errors.loadGpu': 'No se pudieron cargar las estadísticas de GPU / NPU',
'systemManager.errors.loadPorts': 'No se pudieron cargar los puertos en escucha',
'systemManager.errors.loadServices': 'No se pudieron cargar los servicios de systemd',
@@ -65,13 +62,10 @@ export const esSystemManagerMessages: Messages = {
'systemManager.overview.noTopProcesses': 'Sin datos de procesos',
'systemManager.processes.search': 'Buscar procesos…',
'systemManager.processes.command': 'Comando',
'systemManager.processes.user': 'Usuario',
'systemManager.processes.term': 'Terminar',
'systemManager.processes.kill': 'Forzar cierre',
'systemManager.processes.stop': 'Detener (SIGSTOP)',
'systemManager.processes.cont': 'Continuar (SIGCONT)',
'systemManager.processes.hup': 'Colgar (SIGHUP)',
'systemManager.processes.renice': 'Renice',
'systemManager.processes.renicePrompt': 'Valor de nice (-20 a 19)',
'systemManager.processes.reniceInvalid': 'El valor de nice debe estar entre -20 y 19',
@@ -86,7 +80,6 @@ export const esSystemManagerMessages: Messages = {
'systemManager.processes.stat': 'Estado',
'systemManager.processes.meta': '{{count}} proceso(s)',
'systemManager.processes.loading': 'Cargando procesos…',
'systemManager.processes.loadingMore': 'Cargando más procesos…',
'systemManager.processes.state.running': 'En ejecución',
'systemManager.processes.state.sleeping': 'En reposo',
'systemManager.processes.state.stopped': 'Detenido',
@@ -124,12 +117,9 @@ export const esSystemManagerMessages: Messages = {
'systemManager.tmux.attached': 'Conectada',
'systemManager.tmux.detached': 'Desacoplada',
'systemManager.tmux.windows': '{{count}} ventana(s)',
'systemManager.tmux.created': 'Creada',
'systemManager.tmux.activity': 'Actividad',
'systemManager.tmux.rename': 'Renombrar',
'systemManager.tmux.detach': 'Desacoplar todo',
'systemManager.tmux.killSession': 'Terminar sesión',
'systemManager.tmux.killServer': 'Terminar servidor',
'systemManager.tmux.loadingDetails': 'Cargando detalles…',
'systemManager.tmux.clients': 'Clientes conectados',
'systemManager.tmux.windowList': 'Ventanas',
@@ -140,31 +130,17 @@ export const esSystemManagerMessages: Messages = {
'systemManager.docker.unavailable': 'No se detectó ningún runtime de contenedores (Docker, Podman, nerdctl o kubectl) en este host',
'systemManager.tmux.windowsMismatch': 'La sesión reporta {{count}} ventana(s), pero list-windows no devolvió ninguna',
'systemManager.tmux.lastCommand': 'último comando: {{command}}',
'systemManager.tmux.noPanes': 'No hay paneles',
'systemManager.tmux.panes': '{{count}} panel(es)',
'systemManager.tmux.active': 'activo',
'systemManager.tmux.unnamedWindow': 'Ventana sin nombre',
'systemManager.tmux.unnamedPane': 'Panel sin nombre',
'systemManager.tmux.attachWindow': 'Conectar a la ventana',
'systemManager.tmux.selectWindow': 'Seleccionar ventana',
'systemManager.tmux.killWindow': 'Terminar ventana',
'systemManager.tmux.killPane': 'Terminar panel',
'systemManager.tmux.splitHorizontal': 'Dividir horizontal',
'systemManager.tmux.splitVertical': 'Dividir vertical',
'systemManager.tmux.sendKeys': 'Enviar teclas',
'systemManager.tmux.sendKeysTo': 'Enviar teclas a la ventana {{window}} panel {{pane}}',
'systemManager.tmux.sendKeysPlaceholder': 'Comando o texto…',
'systemManager.tmux.renameSessionPrompt': 'Renombrar sesión',
'systemManager.tmux.renameWindowPrompt': 'Renombrar ventana',
'systemManager.tmux.windowName': 'Nombre de la ventana',
'systemManager.tmux.confirmKillSession': '¿Terminar la sesión de tmux "{{name}}"?',
'systemManager.tmux.confirmDetachSession': '¿Desacoplar todos los clientes de "{{name}}"?',
'systemManager.tmux.confirmKillWindow': '¿Terminar la ventana "{{name}}"?',
'systemManager.tmux.confirmKillPane': '¿Terminar el panel #{{index}}?',
'systemManager.tmux.confirmKillServer': '¿Terminar el servidor de tmux? Se terminarán todas las sesiones.',
'systemManager.tmux.meta': '{{count}} sesión(es)',
'systemManager.docker.title': 'Contenedores',
'systemManager.docker.subTabs.containers': 'Contenedores',
'systemManager.docker.subTabs.images': 'Imágenes',
'systemManager.docker.empty': 'No se encontraron contenedores',
@@ -177,7 +153,6 @@ export const esSystemManagerMessages: Messages = {
'systemManager.docker.filter.paused': 'En pausa',
'systemManager.docker.shell': 'Shell',
'systemManager.docker.logs': 'Registros',
'systemManager.docker.details': 'Detalles',
'systemManager.docker.inspect': 'Inspeccionar',
'systemManager.docker.imageInspect': 'Inspección de imagen',
'systemManager.docker.confirmRemove': '¿Eliminar este contenedor?',
+6 -64
View File
@@ -12,6 +12,10 @@ export const esTerminalMessages: Messages = {
'terminal.directory.hidden': 'Mostrar directorios ocultos',
'terminal.directory.refresh': 'Actualizar',
'terminal.directory.unavailable': 'La navegación de directorios no está disponible para esta sesión.',
'terminal.directory.integrationUnavailable': 'La integración de directorios de PowerShell no está lista. Los argumentos de inicio o la política de ejecución pueden impedirla.',
'terminal.directory.cmdIntegrationUnavailable': 'Esperando el directorio de la sesión original del símbolo del sistema.',
'terminal.directory.nonFilesystem': 'La ubicación actual de PowerShell no es un directorio del sistema de archivos.',
'terminal.directory.accessDenied': 'Permiso denegado al listar este directorio.',
'terminal.directory.busy': 'Espera a que el prompt esté vacío.',
'terminal.directory.readFailed': 'No se pudo leer el directorio. Actualiza e inténtalo de nuevo.',
'terminal.directory.changeFailed': 'No se pudo confirmar el cambio. Actualiza antes de reintentar.',
@@ -53,7 +57,6 @@ export const esTerminalMessages: Messages = {
'terminal.toolbar.availableAfterConnect': 'Disponible después de conectar',
'terminal.toolbar.sendYmodem': 'Enviar con YMODEM',
'terminal.toolbar.receiveYmodem': 'Recibir con YMODEM',
'terminal.toolbar.sftp': 'SFTP',
'terminal.toolbar.more': 'Más acciones',
'terminal.toolbar.scripts': 'Scripts',
'terminal.toolbar.history': 'Historial de comandos',
@@ -101,7 +104,6 @@ export const esTerminalMessages: Messages = {
'terminal.composeBar.resize': 'Cambiar la altura de la barra de redacción',
'terminal.composeBar.manageSnippets': 'Administrar snippets rápidos',
'terminal.composeBar.searchSnippets': 'Buscar snippets...',
'terminal.composeBar.noPinnedSnippets': 'Fija snippets con + para acceso rápido',
'terminal.composeBar.noMatchingSnippets': 'No hay snippets que coincidan',
'terminal.composeBar.pinnedCount': '{count} fijados',
'terminal.composeBar.unpinSnippet': 'Quitar {label} de la barra rápida',
@@ -195,7 +197,6 @@ export const esTerminalMessages: Messages = {
'terminal.osc7Setup.title': 'Configurar seguimiento de directorio',
'terminal.osc7Setup.desc': 'Netcatty agregará hooks de prompt OSC 7 para el usuario remoto actual. Esto ayuda a que SFTP siga el directorio de la terminal después de sudo o su.',
'terminal.osc7Setup.targets': 'Posibles archivos a actualizar',
'terminal.osc7Setup.command': 'Comando a ejecutar',
'terminal.osc7Setup.run': 'Ejecutar configuración',
'terminal.osc7Setup.running': 'Configurando...',
'terminal.osc7Setup.configured': 'Seguimiento de directorio configurado',
@@ -279,9 +280,6 @@ export const esTerminalMessages: Messages = {
'terminal.themeModal.themeType': 'Tema {type}',
'terminal.hiddenTheme.title': 'Tema oculto actual',
'terminal.hiddenTheme.desc': 'Este tema está oculto de la selección manual y se reemplazará cuando elijas otro tema.',
'topTabs.toggleTheme.systemExitTitle': 'El tema del sistema está activo',
'topTabs.toggleTheme.systemExitMessage': 'Abre Configuración para elegir un tema fijo de Claro u Oscuro.',
'topTabs.toggleTheme.openSettings': 'Abrir Configuración',
// Custom Themes
'terminal.customTheme.section': 'Temas personalizados',
@@ -294,7 +292,6 @@ export const esTerminalMessages: Messages = {
'terminal.customTheme.importDesc': 'Importar desde archivo de esquema de color de iTerm2',
'terminal.customTheme.importError': 'No se pudo analizar el archivo seleccionado. Asegúrate de que sea un archivo XML .itermcolors válido.',
'terminal.customTheme.delete': 'Eliminar tema',
'terminal.customTheme.confirmDelete': 'Confirmar eliminación',
'terminal.customTheme.name': 'Nombre',
'terminal.customTheme.namePlaceholder': 'Mi tema personalizado',
'terminal.customTheme.type': 'Tipo',
@@ -354,10 +351,7 @@ export const esTerminalMessages: Messages = {
'cloudSync.provider.disconnect.cloudRemains': 'Las copias de sincronización cifradas pueden seguir en tu almacenamiento de {name}. Para eliminarlas, borra los archivos de sincronización allí. Desconectar no prepara este dispositivo para entregarlo a otra persona.',
'cloudSync.provider.disconnect.failed': 'No se pudo completar la desconexión de {name}. Los datos de conexión guardados podrían permanecer. Inténtalo de nuevo.',
'cloudSync.provider.webdav': 'WebDAV',
'cloudSync.provider.webdav.desc': 'Conectar a un endpoint WebDAV autoalojado',
'cloudSync.provider.s3': 'Compatible con S3',
'cloudSync.provider.s3.desc': 'Conectar a almacenamiento de objetos compatible con S3',
'cloudSync.provider.comingSoon': 'Próximamente',
'cloudSync.webdav.title': 'Configuración de WebDAV',
'cloudSync.webdav.desc': 'Configura un endpoint WebDAV para la sincronización cifrada.',
'cloudSync.webdav.endpoint': 'URL del endpoint',
@@ -386,20 +380,6 @@ export const esTerminalMessages: Messages = {
'cloudSync.s3.allowInsecure': 'Permitir conexión insegura (ignorar errores de certificado)',
'cloudSync.s3.showSecret': 'Mostrar secretos',
'cloudSync.s3.validation.required': 'Endpoint, región, bucket, clave de acceso y secreto son obligatorios.',
'cloudSync.smb.title': 'Configuración de SMB',
'cloudSync.smb.desc': 'Conéctate a un recurso compartido de archivos SMB/CIFS para la sincronización cifrada.',
'cloudSync.smb.share': 'Ruta del recurso compartido',
'cloudSync.smb.username': 'Nombre de usuario',
'cloudSync.smb.password': 'Contraseña',
'cloudSync.smb.domain': 'Dominio (opcional)',
'cloudSync.smb.domainPlaceholder': 'p. ej., WORKGROUP',
'cloudSync.smb.port': 'Puerto (opcional)',
'cloudSync.smb.showSecret': 'Mostrar contraseña',
'cloudSync.smb.validation.share': 'La ruta del recurso compartido es obligatoria.',
'cloudSync.smb.validation.port': 'El puerto debe ser un número entre 1 y 65535.',
'cloudSync.connect.smb.success': 'SMB se conectó correctamente',
'cloudSync.connect.smb.failedTitle': 'Falló la conexión a SMB',
'cloudSync.provider.smb': 'Recurso compartido SMB',
'cloudSync.connect.webdav.success': 'WebDAV se conectó correctamente',
'cloudSync.connect.webdav.failedTitle': 'Falló la conexión a WebDAV',
'cloudSync.connect.s3.success': 'S3 se conectó correctamente',
@@ -416,7 +396,6 @@ export const esTerminalMessages: Messages = {
'cloudSync.lastSync.minutesAgo': 'Hace {minutes} min',
'cloudSync.changeKey': 'Cambiar clave',
'cloudSync.providers.title': 'Proveedores de nube',
'cloudSync.syncAll': 'Sincronizar todos los proveedores conectados',
'cloudSync.autoSync.title': 'Sincronización automática',
'cloudSync.autoSync.desc': 'Sincronizar automáticamente cuando se realicen cambios',
'cloudSync.strategy.title': 'Estrategia de sincronización',
@@ -481,7 +460,6 @@ export const esTerminalMessages: Messages = {
'cloudSync.localBackups.folderWarning': 'Esta carpeta por sí sola no es una copia de seguridad completa y portátil. Eliminar o vaciar el perfil de la aplicación (userData) puede impedir la lectura de estos puntos de restauración.',
'cloudSync.localBackups.retentionTitle': 'Retención de copias de seguridad',
'cloudSync.localBackups.retentionDesc': 'Elige cuántas copias de seguridad locales debe conservar Netcatty.',
'cloudSync.localBackups.maxCount': 'Copias máximas',
'cloudSync.localBackups.maxSaved': 'Retención de copia guardada: {count}',
'cloudSync.localBackups.maxInvalid': 'Ingresa un número entre 1 y 100.',
'cloudSync.localBackups.empty': 'Aún no hay copias de seguridad locales.',
@@ -604,10 +582,7 @@ export const esTerminalMessages: Messages = {
'cloudSync.clearLocal.toast.desc': 'Versión local restablecida a 0. Sincroniza para descargar desde la nube.',
// Keychain
'keychain.filter.key': 'CLAVE',
'keychain.filter.certificate': 'CERTIFICADO',
'keychain.action.generateKey': 'Generar clave',
'keychain.action.importKey': 'Importar clave',
'keychain.action.newIdentity': 'Nueva identidad',
'keychain.action.importCertificate': 'Importar certificado',
'keychain.view.grid': 'Cuadrícula',
@@ -651,20 +626,8 @@ export const esTerminalMessages: Messages = {
'keychain.export.exporting': 'Exportando...',
'keychain.export.exportAndAttach': 'Exportar y adjuntar',
'keychain.export.title': 'Exportación de clave',
'keychain.export.exportToRequired': 'Exportar a *',
'keychain.export.selectHostPlaceholder': 'Selecciona un host...',
'keychain.export.locationLabel': 'Ubicación ~ $1 *',
'keychain.export.filenameLabel': 'Nombre de archivo ~ $2 *',
'keychain.export.advanced': 'Avanzado',
'keychain.export.note.supportsOnly': 'La exportación de claves actualmente solo admite',
'keychain.export.note.systems': 'sistemas.',
'keychain.export.note.use': 'Usa la',
'keychain.export.note.customize': 'sección para personalizar el script de exportación.',
'keychain.export.scriptRequired': 'Script *',
'keychain.export.exportToHost': 'Exportar al host',
'keychain.export.failedGeneric': 'Falló la exportación: {message}',
'keychain.field.label': 'Etiqueta',
'keychain.field.labelRequired': 'Etiqueta *',
'keychain.field.labelPlaceholder': 'Etiqueta de la clave',
'keychain.field.privateKeyRequired': 'Clave privada *',
'keychain.field.publicKey': 'Clave pública',
@@ -679,7 +642,6 @@ export const esTerminalMessages: Messages = {
'keychain.import.dropHint': 'Suelta un archivo de clave aquí',
'keychain.import.importFromFile': 'Importar desde archivo',
'keychain.import.saveKey': 'Guardar clave',
'keychain.import.importedKeyLabel': 'Clave importada',
'keychain.identity.usernameRequired': 'Nombre de usuario *',
'keychain.identity.method.passwordOnly': 'Contraseña',
'keychain.identity.summary.password': 'Contraseña de autenticación',
@@ -688,14 +650,8 @@ export const esTerminalMessages: Messages = {
'keychain.identity.summary.passwordAndKey': 'Contraseña y clave de autenticación',
'keychain.identity.summary.passwordAndCertificate': 'Contraseña y certificado de autenticación',
'keychain.identity.summary.none': 'Sin credenciales',
'keychain.identity.selectCredential': 'Seleccionar {kind}',
'keychain.identity.save': 'Guardar',
'keychain.identity.update': 'Actualizar',
'keychain.keyDialog.newTitle': 'Nueva clave',
'keychain.keyDialog.newDesc': 'Agregar una nueva clave SSH',
'keychain.keyDialog.editTitle': 'Editar clave',
'keychain.keyDialog.editDesc': 'Actualizar esta clave SSH',
'keychain.keyDialog.updateKey': 'Actualizar clave',
'keychain.generate.standardKeys': 'Claves estándar',
'keychain.generate.securityKeys': 'Llaves de seguridad · FIDO2',
'keychain.generate.residentDesc': 'Permite recuperar las credenciales desde esta llave de seguridad.',
@@ -704,7 +660,6 @@ export const esTerminalMessages: Messages = {
'keychain.generate.fidoHint': 'Conecta una llave de seguridad FIDO2. Es posible que se te solicite su PIN o un toque.',
'keychain.generate.resident': 'Guardar las credenciales en la llave',
'keychain.generate.verifyRequired': 'Verificar el PIN cada vez',
'keychain.action.loadResident': 'Cargar claves residentes desde la llave de seguridad',
// FIDO2 security key prompts and recovery states
'fido.prompt.pinTouchDesc': 'Ingresa tu PIN y luego toca la llave para confirmar.',
@@ -720,7 +675,6 @@ export const esTerminalMessages: Messages = {
'fido.prompt.touchWaiting': 'Esperando tu llave…',
'fido.prompt.touchAutomatic': 'Continúa automáticamente después de que la toques',
'fido.prompt.cancelled': 'Se canceló la autenticación con llave de seguridad.',
'fido.prompt.touchDone': 'Ya la toqué',
'fido.prompt.timeout': 'El aviso de FIDO agotó el tiempo de espera. Intenta conectarte de nuevo.',
'fido.recovery.device-unavailable.title': 'Conecta la llave de seguridad correspondiente',
'fido.recovery.device-unavailable.desc': 'Conecta el dispositivo que contiene la credencial de esta llave y vuelve a intentarlo.',
@@ -733,8 +687,6 @@ export const esTerminalMessages: Messages = {
'fido.recovery.retry': 'Reintentar verificación',
'fido.recovery.usePassword': 'Usar la contraseña configurada',
'fido.recovery.passwordFallback': 'Probando la contraseña configurada para este host',
'fido.error.opensshMissing': 'Se requiere OpenSSH con FIDO/libfido2. En macOS: brew install openssh libfido2.',
'fido.error.agentUnavailable': 'No se pudo iniciar un agente SSH compatible con FIDO.',
// Tabs
'tabs.closeSessionAria': 'Cerrar sesión',
@@ -746,6 +698,8 @@ export const esTerminalMessages: Messages = {
'tabs.duplicateSession': 'Duplicar sesión',
'tabs.copyTabToNewWindow': 'Copiar pestaña a una nueva ventana',
'tabs.copyTabToNewWindowFailed': 'No se pudo abrir la pestaña en una nueva ventana',
'tabs.moveTabToNewWindow': 'Mover pestaña a una nueva ventana',
'tabs.moveTabToNewWindowFailed': 'No se pudo mover la pestaña a una nueva ventana',
'tabs.closeOthers': 'Cerrar las demás',
'tabs.closeToLeft': 'Cerrar pestañas a la izquierda',
'tabs.closeToRight': 'Cerrar pestañas a la derecha',
@@ -809,8 +763,6 @@ export const esTerminalMessages: Messages = {
'snippets.search.noResults.desc': 'Ningún script o paquete de scripts coincide con "{query}". Prueba con otro término de búsqueda o limpia la búsqueda para explorar.',
'snippets.section.packages': 'Paquetes de scripts',
'snippets.section.snippets': 'Scripts',
'snippets.kind.codeSnippet': 'Snippet de código',
'snippets.kind.automationScript': 'Script de automatización',
'snippets.package.count': '{count} script(s)',
'snippets.commandFallback': 'Comando',
'snippets.view.grid': 'Cuadrícula',
@@ -842,9 +794,6 @@ export const esTerminalMessages: Messages = {
'snippets.import.modal.multipleFiles': '{count} archivos seleccionados',
'snippets.import.modal.parsedSummary': '{files} archivo(s), {total} script(s), {packages} paquete(s) de scripts, {conflicts} comando(s) duplicado(s). Las vinculaciones de host se ignoran.',
'snippets.import.modal.confirm': 'Confirmar importación',
'snippets.import.conflict.title': '¿Importar snippets?',
'snippets.import.conflict.desc': '{file} contiene {total} snippet(s). Ya existen {conflicts} comando(s) duplicado(s).',
'snippets.import.conflict.hostBindingsNote': 'Las vinculaciones de host no se importan ni se exportan con los snippets.',
'snippets.import.conflict.skip': 'Omitir duplicados',
'snippets.import.conflict.overwrite': 'Sobrescribir duplicados',
'snippets.packageDialog.title': 'Nuevo paquete de scripts',
@@ -903,9 +852,6 @@ export const esTerminalMessages: Messages = {
'serial.field.customPort': 'Ruta de puerto personalizada',
'serial.field.namedPipeHint': 'Consola de VM en Windows: introduce \\\\.\\pipe\\name. La VM debe crear la canalización como servidor. Se ignoran la velocidad y la trama.',
'serial.field.customPortPlaceholder': 'p. ej., /dev/ttys001 o COM1',
'serial.type.hardware': 'Hardware',
'serial.type.pseudo': 'Pseudoterminal',
'serial.type.custom': 'Personalizado',
'serial.parity.none': 'Ninguna',
'serial.parity.even': 'Par',
'serial.parity.odd': 'Impar',
@@ -926,7 +872,6 @@ export const esTerminalMessages: Messages = {
'serial.backspace.default': 'Predeterminado (DEL, 0x7F)',
'serial.backspace.ctrlH': 'Ctrl+H (BS, 0x08)',
'serial.field.charset': 'Codificación de caracteres',
'serial.connectionError': 'No se pudo conectar al puerto serial',
'serial.field.baudRatePlaceholder': 'Selecciona o ingresa la velocidad de baudios...',
'serial.field.baudRateEmpty': 'Ingresa una velocidad de baudios personalizada',
'serial.field.customBaudRate': 'Usando velocidad de baudios personalizada',
@@ -945,10 +890,7 @@ export const esTerminalMessages: Messages = {
'keyboard.interactive.title': 'Se requiere autenticación',
'keyboard.interactive.desc': 'El servidor requiere autenticación adicional.',
'keyboard.interactive.descWithHost': 'El servidor {hostname} requiere autenticación adicional.',
'keyboard.interactive.response': 'Respuesta',
'keyboard.interactive.verificationCode': 'Código de verificación',
'keyboard.interactive.enterCode': 'Ingresa el código de verificación',
'keyboard.interactive.enterResponse': 'Ingresa la respuesta',
'keyboard.interactive.submit': 'Enviar',
'keyboard.interactive.verifying': 'Verificando...',
'keyboard.interactive.savePassword': 'Guardar contraseña',
+24 -110
View File
@@ -19,14 +19,6 @@ export const esVaultMessages: Messages = {
'notes.export.toast.failed': 'No se pudieron exportar las notas.',
'notes.codeBlock.copied': 'Copiado',
'notes.codeBlock.copyFailed': 'No se pudo copiar el bloque de código.',
'notes.group.prompt': 'Ruta de la carpeta',
'notes.group.all': 'Cuaderno',
'notes.group.ungrouped': 'Sin grupo',
'notes.section.notebooks': 'Cuaderno',
'notes.section.notes': 'Notas',
'notes.mode.edit': 'Editar',
'notes.mode.split': 'Dividir',
'notes.mode.preview': 'Vista previa',
'notes.title.placeholder': 'Título de la nota',
'notes.editor.placeholder': 'Escribe notas Markdown aquí...',
'notes.editor.unrenderableMarkdown': 'Esta nota contiene Markdown que el editor enriquecido no puede mostrar (por ejemplo, etiquetas sin cerrar como <tag>). Se muestra el origen Markdown sin cambios: el contenido está intacto.',
@@ -72,25 +64,18 @@ export const esVaultMessages: Messages = {
'notes.toolbar.divider': 'Línea divisoria',
'notes.toolbar.link': 'Insertar enlace',
'notes.toolbar.image': 'Insertar imagen',
'notes.action.pin': 'Fijar nota',
'notes.action.unpin': 'Desfijar nota',
'notes.tag.remove': 'Eliminar etiqueta',
'notes.tag.placeholder': 'Nombre de etiqueta...',
'notes.tag.add': 'Añadir etiqueta',
'notes.outline.title': 'Índice de contenido',
'notes.outline.titleWithCount': 'Índice de contenido ({count})',
'notes.outline.empty': 'Sin encabezados de esquema',
'notes.outline.emptyHint': 'Use # y ## en Markdown para crear encabezados',
'notes.export.share': 'Exportar y compartir',
'notes.export.currentNote': 'Nota actual',
'notes.export.exportMarkdown': 'Exportar como Markdown (.md)',
'notes.export.exportHtml': 'Exportar como HTML (.html)',
'notes.export.copyMarkdown': 'Copiar código Markdown',
'notes.export.allNotes': 'Todas las notas',
'notes.export.exportAllZip': 'Exportar todo como archivo ZIP',
'notes.export.toast.markdownSuccess': 'Archivo Markdown exportado',
'notes.export.toast.htmlSuccess': 'Archivo HTML exportado',
'notes.export.toast.zipSuccess': 'Todas las notas exportadas como copia de seguridad ZIP',
// Vault import
'vault.import.title': 'Agrega datos a tu Vault',
@@ -261,7 +246,6 @@ export const esVaultMessages: Messages = {
'pf.tooltip.localDesc': 'Reenvío de puerto local: accede a servicios remotos a través del túnel SSH',
'pf.tooltip.remoteDesc': 'Reenvío de puerto remoto: expone servicios locales al host remoto',
'pf.tooltip.dynamicDesc': 'Proxy SOCKS dinámico: enruta el tráfico a través del túnel SSH',
'pf.deleteActive.title': '¿Eliminar el reenvío de puertos activo?',
'pf.deleteActive.desc': 'Esta regla de reenvío de puertos "{label}" está activa actualmente. Eliminarla primero detendrá el túnel.',
'pf.deleteActive.confirm': 'Detener y eliminar',
'pf.form.autoStart': 'Inicio automático',
@@ -295,13 +279,9 @@ export const esVaultMessages: Messages = {
'sftp.columns.actions': 'Acciones',
'sftp.sort.directoriesFirst': 'Carpetas primero',
'sftp.emptyDirectory': 'Directorio vacío',
'sftp.nav.up': 'Subir un nivel',
'sftp.nav.home': 'Ir al inicio',
'sftp.nav.refresh': 'Actualizar',
'sftp.upload': 'Subir',
'sftp.uploadFiles': 'Subir archivos',
'sftp.uploadFolder': 'Subir carpeta',
'sftp.dragDropToUpload': 'Arrastra y suelta archivos aquí para subirlos',
'sftp.retry': 'Reintentar',
'sftp.context.open': 'Abrir',
'sftp.context.navigateTo': 'Navegar a',
@@ -316,6 +296,12 @@ export const esVaultMessages: Messages = {
'sftp.extract.extracting': 'Extrayendo {fileName}...',
'sftp.extract.success': 'Se extrajo {fileName}',
'sftp.extract.error': 'No se pudo extraer {fileName}: {error}',
'sftp.packedDownload.receiving': 'Recibiendo la descarga empaquetada…',
'sftp.packedDownload.extracting': 'Restaurando archivos…',
'sftp.packedDownload.fallback': 'La descarga empaquetada no está disponible. Se descargarán los archivos por separado.',
'sftp.packedDownload.selection': '{count} elementos seleccionados',
'sftp.packedDownload.conflict': 'Ya existe un elemento con el mismo nombre. ¿Quieres elegir otra carpeta de destino?',
'sftp.archive.action': 'Comprimir...',
'sftp.archive.title': 'Comprimir archivos',
'sftp.archive.description': 'Crea un archivo comprimido en el servidor con los {count} elementos seleccionados.',
@@ -340,28 +326,21 @@ export const esVaultMessages: Messages = {
'sftp.copyCurrentPath': 'Copiar ruta actual',
'sftp.copyCurrentPath.success': 'Ruta actual copiada',
'sftp.copyCurrentPath.error': 'No se pudo copiar la ruta actual',
'sftp.viewMode.label': 'Modo de vista',
'sftp.viewMode.list': 'Vista de lista',
'sftp.viewMode.tree': 'Vista de árbol',
'sftp.viewMode.switchToList': 'Cambiar a vista de lista',
'sftp.viewMode.switchToTree': 'Cambiar a vista de árbol',
'sftp.listDensity.compact': 'Lista compacta',
'sftp.listDensity.comfortable': 'Lista cómoda',
'sftp.listDensity.switchToCompact': 'Cambiar a lista compacta',
'sftp.listDensity.switchToComfortable': 'Cambiar a lista cómoda',
'sftp.tree.loadError': 'No se pudo cargar el directorio',
'sftp.tree.loading': 'Cargando...',
'sftp.kind.folder': 'Carpeta',
'sftp.context.rename': 'Renombrar',
'sftp.context.permissions': 'Permisos',
'sftp.context.delete': 'Eliminar',
'sftp.context.refresh': 'Actualizar',
'sftp.context.uploadFiles': 'Subir archivo(s)...',
'sftp.context.uploadFilesHere': 'Subir archivo(s) aquí...',
'sftp.context.uploadFolder': 'Subir carpeta...',
'sftp.context.uploadFolderHere': 'Subir carpeta aquí...',
'sftp.context.downloadSelected': 'Descargar seleccionados ({count})',
'sftp.context.deleteSelected': 'Eliminar seleccionados ({count})',
'sftp.dropFilesHere': 'Suelta los archivos aquí',
'sftp.itemsCount': '{count} elementos',
'sftp.selectedCount': '{count} seleccionados',
@@ -370,8 +349,6 @@ export const esVaultMessages: Messages = {
'sftp.task.waiting': 'Esperando...',
'sftp.transfer.preparing': 'preparando...',
'sftp.status.loading': 'Cargando...',
'sftp.status.uploading': 'Subiendo...',
'sftp.status.ready': 'Listo',
'sftp.transfers': 'Transferencias',
'sftp.transfers.active': '{count} activas',
'sftp.transfers.clearCompleted': 'Limpiar completadas',
@@ -435,7 +412,6 @@ export const esVaultMessages: Messages = {
'sftp.transferCenter.applyAll': 'Aplicar a todas',
'sftp.transfers.resizeNameColumn': 'Redimensionar la columna de nombre de archivo',
'sftp.transfers.dragToResize': 'Arrastra para redimensionar',
'sftp.goUp': 'Subir un nivel',
'sftp.goToTerminalCwd': 'Ir al directorio de la terminal',
'sftp.locatePathInTerminal': 'Abrir ruta en la terminal',
'sftp.followTerminalCwd': 'Seguir el directorio de la terminal',
@@ -445,35 +421,30 @@ export const esVaultMessages: Messages = {
'sftp.encoding.auto': 'Auto',
'sftp.encoding.utf8': 'UTF-8',
'sftp.encoding.gb18030': 'GB18030',
'sftp.goBack': 'Ir atrás',
'sftp.goForward': 'Ir adelante',
'sftp.goHome': 'Ir al inicio',
'sftp.goRoot': 'Ir a la raíz',
'sftp.folderName': 'Nombre de la carpeta',
'sftp.folderName.placeholder': 'Ingresa el nombre de la carpeta',
'sftp.fileName': 'Nombre del archivo',
'sftp.fileName.placeholder': 'Ingresa el nombre del archivo',
'sftp.prompt.newFolderName': '¿Nombre de la carpeta nueva?',
'sftp.rename.title': 'Renombrar',
'sftp.rename.newName': 'Nombre nuevo',
'sftp.rename.placeholder': 'Ingresa el nombre nuevo',
'sftp.confirm.deleteOne': '¿Eliminar "{name}"?',
'sftp.deleteConfirm.single': '¿Eliminar "{name}"?',
'sftp.deleteConfirm.title': '¿Eliminar {count} elemento(s)?',
'sftp.deleteConfirm.desc': 'Esta acción no se puede deshacer. Se eliminará lo siguiente:',
'sftp.deleteConfirm.descSingle': 'Esta acción no se puede deshacer.',
'sftp.deleteConfirm.host': 'Host',
'sftp.deleteConfirm.path': 'Ruta',
'sftp.error.loadFailed': 'No se pudo cargar el directorio',
'sftp.error.downloadFailed': 'No se pudo descargar',
'sftp.error.uploadFailed': 'No se pudo subir',
'sftp.error.deleteFailed': 'No se pudo eliminar',
'sftp.error.createFolderFailed': 'No se pudo crear la carpeta',
'sftp.error.createFileFailed': 'No se pudo crear el archivo',
'sftp.error.invalidFileName': 'El nombre de archivo contiene caracteres no válidos: {chars}',
'sftp.error.reservedName': 'Este nombre de archivo está reservado por el sistema',
'sftp.overwrite.title': 'El archivo ya existe',
'sftp.overwrite.desc': 'Ya existe un archivo llamado "{name}". ¿Quieres reemplazarlo?',
'sftp.overwrite.confirm': 'Reemplazar',
'sftp.error.renameFailed': 'No se pudo renombrar',
'sftp.picker.title': 'Seleccionar host',
'sftp.picker.desc': 'Elige un host para el panel {side}',
'sftp.picker.searchPlaceholder': 'Buscar hosts...',
@@ -481,8 +452,6 @@ export const esVaultMessages: Messages = {
'sftp.picker.local.desc': 'Explorar archivos locales',
'sftp.picker.local.badge': 'Local',
'sftp.picker.connected.section': 'Conectados',
'sftp.picker.connected.badge': 'En vivo',
'sftp.picker.connected.connecting': 'Conectando',
'sftp.picker.noMatch': 'No hay hosts que coincidan',
'sftp.permissions.title': 'Editar permisos',
'sftp.permissions.owner': 'Propietario',
@@ -490,16 +459,12 @@ export const esVaultMessages: Messages = {
'sftp.permissions.others': 'Otros',
'sftp.permissions.octal': 'Octal',
'sftp.permissions.symbolic': 'Simbólico',
'sftp.permissions.success': 'Permisos actualizados correctamente',
'sftp.permissions.failed': 'No se pudieron actualizar los permisos',
'sftp.pane.local': 'Local',
'sftp.pane.remote': 'Remoto',
'sftp.pane.selectHost': 'Seleccionar host',
'sftp.pane.selectHostToStart': 'Selecciona un host para comenzar',
'sftp.pane.chooseFilesystem': 'Elige un sistema de archivos local o remoto para explorar',
'sftp.tabs.addTab': 'Agregar pestaña nueva',
'sftp.tabs.closeTab': 'Cerrar pestaña',
'sftp.tabs.newTab': 'Pestaña nueva',
'sftp.tabs.copyDefaultPath': 'Copiar pestaña (ruta predeterminada)',
'sftp.tabs.copyCurrentPath': 'Copiar e ir a la ruta actual',
'sftp.conflict.title': 'Conflicto de archivos',
@@ -525,47 +490,27 @@ export const esVaultMessages: Messages = {
'sftp.conflict.action.replace': 'Reemplazar',
// SFTP Upload Phases
'sftp.upload.phase.compressing': 'Comprimiendo',
'sftp.upload.phase.uploading': 'Subiendo',
'sftp.upload.phase.extracting': 'Extrayendo',
'sftp.upload.phase.compressed': 'Comprimido',
// SFTP File Opener
'sftp.context.copyPath': 'Copiar ruta del archivo',
'sftp.context.insertPathToTerminal': 'Insertar ruta en la terminal',
'sftp.context.cdInTerminal': 'Abrir en la terminal (cd)',
'sftp.terminal.insertBlockedUnsafeQuote': 'No se puede insertar la ruta mientras el cursor de la terminal esté dentro de una comilla o secuencia de escape sin cerrar',
'sftp.context.openWithDefault': 'Abrir con la aplicación predeterminada del sistema',
'sftp.context.openWith': 'Abrir con...',
'sftp.context.edit': 'Editar',
'sftp.context.preview': 'Vista previa',
'sftp.opener.title': 'Abrir con',
'sftp.opener.desc': 'Elige una aplicación para abrir este archivo',
'sftp.opener.builtInEditor': 'Editor integrado',
'sftp.opener.editDescription': 'Editar archivos de texto',
'sftp.opener.builtInImageViewer': 'Visor de imágenes integrado',
'sftp.opener.previewDescription': 'Previsualizar imágenes',
'sftp.opener.systemApp': 'Elegir aplicación...',
'sftp.opener.systemAppDescription': 'Selecciona una aplicación de tu computadora',
'sftp.opener.onlySystemApp': 'Este archivo solo se puede abrir con una aplicación externa',
'sftp.opener.noAppsAvailable': 'No hay aplicaciones disponibles',
'sftp.opener.noExtension': 'archivos sin extensión',
'sftp.opener.setDefault': 'Usar siempre esto para archivos {ext}',
'sftp.opener.confirmTitle': '¿Establecer como predeterminado?',
'sftp.opener.confirmDescription': '¿Quieres usar siempre {app} para archivos {ext}?',
'sftp.opener.yesRemember': 'Sí, recordar esta elección',
'sftp.opener.justOnce': 'Solo esta vez',
'sftp.opener.confirm.title': 'Establecer aplicación predeterminada',
'sftp.opener.confirm.desc': '¿Quieres abrir siempre los archivos .{ext} con esta aplicación?',
'sftp.editor.title': 'Editor de texto',
'sftp.editor.save': 'Guardar en remoto',
'sftp.editor.saving': 'Guardando...',
'sftp.editor.saved': 'Guardado correctamente',
'sftp.editor.saveFailed': 'No se pudo guardar el archivo',
'sftp.editor.unsavedChanges': 'Tienes cambios sin guardar. ¿Cerrar de todos modos?',
'sftp.editor.syntaxHighlight': 'Resaltado de sintaxis',
'sftp.preview.title': 'Vista previa de imagen',
'sftp.preview.zoomIn': 'Acercar',
'sftp.preview.zoomOut': 'Alejar',
'sftp.preview.resetZoom': 'Restablecer zoom',
'sftp.preview.fitToWindow': 'Ajustar a la ventana',
// Settings > SFTP File Associations
'settings.tab.sftpFileAssociations': 'SFTP',
@@ -644,28 +589,16 @@ export const esVaultMessages: Messages = {
'sftp.autoSync.error': 'No se pudo sincronizar el archivo: {error}',
// SFTP Folder Upload Progress
'sftp.upload.progress': 'Subiendo {current} de {total} archivos...',
'sftp.upload.uploading': 'Subiendo...',
'sftp.upload.compressing': 'Comprimiendo...',
'sftp.upload.extracting': 'Extrayendo...',
'sftp.upload.scanning': 'Escaneando archivos...',
'sftp.upload.completed': 'Completado',
'sftp.upload.compressed': 'Transferencia comprimida',
'sftp.upload.currentFile': 'Actual: {fileName}',
'sftp.upload.cancelled': 'Subida cancelada',
'sftp.upload.noFiles': 'No hay archivos para subir',
'sftp.upload.partialSuccess': 'Se subieron {success} archivo(s); {failed} fallaron',
'sftp.upload.cancel': 'Cancelar',
'sftp.upload.completedToPath': 'Subido a {path}',
// SFTP Download
'sftp.download.completed': 'Descargado',
'sftp.download.cancelled': 'Descarga cancelada',
// SFTP Reconnecting
'sftp.reconnecting.title': 'Reconectando...',
'sftp.reconnecting.desc': 'Se perdió la conexión, intentando reconectar',
'sftp.reconnected': 'Conexión restablecida',
'sftp.error.reconnectFailed': 'No se pudo reconectar. Inténtalo de nuevo.',
'sftp.error.connectionLostManual': 'Se perdió la conexión. Vuelve a conectar manualmente.',
'sftp.error.connectionLostReconnecting': 'Se perdió la conexión. Reconectando...',
@@ -683,6 +616,17 @@ export const esVaultMessages: Messages = {
'settings.sftp.compressedUpload.enable': 'Habilitar la compresión de carpetas',
'settings.sftp.compressedUpload.enableDesc': 'Comprime automáticamente las carpetas con tar antes de la transferencia. Requiere soporte de tar en el servidor. Si no está disponible, se recurre a una transferencia normal.',
'settings.sftp.packedDownload': 'Descargas empaquetadas',
'settings.sftp.packedDownload.enable': 'Empaquetar carpetas y selecciones múltiples para descargar',
'settings.sftp.packedDownload.enableDesc': 'Descarga la selección en una sola transferencia y restaura su estructura original en este dispositivo. Si el servidor no puede empaquetarla, los archivos se descargan por separado.',
'settings.sftp.downloadLocation': 'Ubicación de descarga',
'settings.sftp.downloadLocation.directory': 'Carpeta de descarga predeterminada',
'settings.sftp.downloadLocation.directoryDesc': 'Los diálogos de descarga SFTP se abren en esta carpeta. Si no está configurada o ya no existe, se usa la carpeta Descargas del sistema.',
'settings.sftp.downloadLocation.systemDefault': 'Carpeta Descargas del sistema',
'settings.sftp.downloadLocation.browse': 'Examinar…',
'settings.sftp.downloadLocation.reset': 'Usar la carpeta Descargas del sistema',
'settings.sftp.downloadLocation.select': 'Elegir la carpeta de descarga predeterminada',
'settings.sftp.skipUnchanged.enable': 'Omitir archivos sin cambios',
'settings.sftp.skipUnchanged.enableDesc': 'Omite los archivos cuyo tamaño y hora de modificación ya coinciden con el destino (estilo rsync). Deshabilitado al reemplazar una carpeta en una ruta de staging.',
@@ -773,11 +717,8 @@ export const esVaultMessages: Messages = {
'hostDetails.notes.toggle.show': 'Mostrar el editor de notas',
'hostDetails.notes.toggle.hide': 'Ocultar el editor de notas',
'hostDetails.group.placeholder': 'Grupo padre',
'hostDetails.section.credentials': 'Credenciales',
'hostDetails.section.portCredentials': 'Puerto y credenciales',
'hostDetails.section.appearance': 'Apariencia',
'hostDetails.distro.title': 'Distribución de Linux',
'hostDetails.distro.desc': 'Detecta automáticamente al conectar, o anula el ícono de la distro manualmente.',
'hostDetails.icon.title': 'Ícono del host',
'hostDetails.icon.sectionTitle': 'Color e ícono',
'hostDetails.icon.desc': 'Elige la fuente y el color del ícono para este host.',
@@ -789,7 +730,6 @@ export const esVaultMessages: Messages = {
'hostDetails.icon.mode.custom': 'Personalizado',
'hostDetails.icon.reset': 'Restablecer el ícono del host',
'hostDetails.icon.colorLabel': 'Color del ícono',
'hostDetails.icon.colorDefault': 'Predeterminado',
'hostDetails.icon.colorAuto': 'Automático',
'hostDetails.icon.colorManual': 'Manual',
'hostDetails.icon.colorChoice': 'Color',
@@ -840,7 +780,6 @@ export const esVaultMessages: Messages = {
'hostDetails.distro.mode.auto': 'Detección automática',
'hostDetails.distro.mode.manual': 'Anulación manual',
'hostDetails.distro.detectedLabel': 'Actual',
'hostDetails.distro.manualLabel': 'Anulación',
'hostDetails.distro.pending': 'Detectar después de la primera conexión',
'hostDetails.distro.unknown': 'Desconocido',
'hostDetails.distro.option.linux': 'Linux genérico',
@@ -891,7 +830,6 @@ export const esVaultMessages: Messages = {
'hostDetails.auth.mfaFirst': 'Preferir autenticación interactiva',
'hostDetails.auth.mfaFirst.desc': 'Para servidores que requieren contraseña y MFA a través de keyboard-interactive.',
'hostDetails.totp.title': 'Autenticador (TOTP)',
'hostDetails.totp.enable': 'Guardar un secreto TOTP para este host',
'hostDetails.totp.setup': 'Configurar…',
'hostDetails.totp.edit': 'Editar',
'hostDetails.totp.modalTitle': 'Configurar autenticador',
@@ -994,10 +932,8 @@ export const esVaultMessages: Messages = {
'hostDetails.jumpHosts.direct': 'Directo',
'hostDetails.jumpHosts.configure': 'Configurar hosts proxy',
'hostDetails.proxy': 'Proxy mediante HTTP/SOCKS5/Comando',
'hostDetails.proxy.none': 'Ninguno',
'hostDetails.proxy.direct': 'Directo (sin proxy)',
'hostDetails.proxy.directHint': 'No usa el proxy del grupo ni el predeterminado global',
'hostDetails.proxy.edit': 'Editar proxy',
'hostDetails.proxy.configure': 'Configurar proxy',
'hostDetails.proxyPanel.title': 'Proxy mediante HTTP/SOCKS5/Comando',
'hostDetails.proxyPanel.hostPlaceholder': 'Host del proxy',
@@ -1007,7 +943,6 @@ export const esVaultMessages: Messages = {
'hostDetails.proxyPanel.credentials': 'Credenciales',
'hostDetails.proxyPanel.usernamePlaceholder': 'Nombre de usuario',
'hostDetails.proxyPanel.passwordPlaceholder': 'Contraseña',
'hostDetails.proxyPanel.identities': 'Identidades',
'hostDetails.proxyPanel.keychainIdentity': 'Identidad del llavero',
'hostDetails.proxyPanel.manualCredentials': 'Credenciales manuales',
'hostDetails.proxyPanel.remove': 'Quitar proxy',
@@ -1031,8 +966,6 @@ export const esVaultMessages: Messages = {
'hostDetails.envVars.newVariable': 'Variable nueva',
'hostDetails.envVars.variableName': 'Nombre de la variable',
'hostDetails.chain.title': 'Editar cadena',
'hostDetails.chain.desc': 'Agregar otro host creará una conexión a {host}.',
'hostDetails.chain.addHost': 'Agregar un host',
'hostDetails.chain.target': 'Destino',
'hostDetails.chain.availableHosts': 'Hosts disponibles',
'hostDetails.chain.clear': 'Limpiar',
@@ -1069,12 +1002,6 @@ export const esVaultMessages: Messages = {
// Host connection test
'hostConnectionTest.title': 'Probar conexión',
'hostConnectionTest.test': 'Probar',
'hostConnectionTest.chainOf': 'Cadena {current} de {total}',
'hostConnectionTest.success': 'Conexión correcta',
'hostConnectionTest.successHint': 'El host aceptó tus credenciales. Puedes cerrar esta ventana.',
'hostConnectionTest.connecting': 'Conectando… tiempo de espera en {seconds}s',
'hostConnectionTest.failed': 'No se pudo conectar.',
'hostConnectionTest.retry': 'Reintentar',
'hostConnectionTest.credentialsUnavailable': 'Las credenciales guardadas no se pueden descifrar en este dispositivo. Vuelve a ingresarlas abajo.',
@@ -1091,6 +1018,8 @@ export const esVaultMessages: Messages = {
'localShell.field.shellResolved': 'Ejecuta {command}',
'localShell.field.startDir': 'Directorio de inicio',
'localShell.field.startDirPlaceholder': 'Heredar directorio inicial global (personal si no se configura)',
'localShell.field.startupCommandPlaceholder': 'Comando para ejecutar al iniciar la shell (p. ej., npm run dev)',
'localShell.field.startupCommandDesc': 'Se ejecuta automáticamente cuando la shell local inicia en el directorio configurado.',
'localShell.saveAndConnect': 'Guardar y conectar',
'hostDetails.plugin.title': 'Conexión de plugin',
@@ -1110,28 +1039,14 @@ export const esVaultMessages: Messages = {
'hostDetails.plugin.useSsh': 'Usar SSH en su lugar',
// Host form (legacy modal)
'hostForm.title.edit': 'Editar host',
'hostForm.title.new': 'Host nuevo',
'hostForm.desc.edit': 'Actualiza los detalles de conexión de este host',
'hostForm.desc.new': 'Crea una nueva entrada de host SSH',
'hostForm.field.label': 'Etiqueta',
'hostForm.placeholder.label': 'Mi servidor de producción',
'hostForm.field.hostname': 'Nombre de host / IP',
'hostForm.placeholder.hostname': '192.168.1.1',
'hostForm.field.port': 'Puerto',
'hostForm.field.username': 'Nombre de usuario',
'hostForm.field.osType': 'Tipo de SO',
'hostForm.placeholder.selectOs': 'Seleccionar SO',
'hostForm.field.group': 'Grupo',
'hostForm.placeholder.group': 'p. ej., AWS, DigitalOcean',
'hostForm.field.tags': 'Etiquetas',
'hostForm.placeholder.addTag': 'Agregar una etiqueta...',
'hostForm.auth.method': 'Método de autenticación',
'hostForm.auth.password': 'Contraseña',
'hostForm.auth.sshKey': 'Clave SSH',
'hostForm.auth.selectKey': 'Seleccionar una clave SSH',
'hostForm.auth.noKeys': 'No hay claves disponibles',
'hostForm.auth.noKeysHint': 'No se encontraron claves SSH en el llavero. Crea una primero.',
'hostForm.saveHost': 'Guardar host',
// Connection logs
@@ -1150,7 +1065,6 @@ export const esVaultMessages: Messages = {
'logs.action.delete': 'Eliminar',
// Log view
'logView.customizeAppearance': 'Personalizar la apariencia',
'logView.appearance': 'Apariencia',
'logView.readOnly': 'Solo lectura',
'logView.export': 'Exportar',
@@ -1,29 +0,0 @@
import assert from 'node:assert/strict';
import test from 'node:test';
import en from './en.ts';
import ru from './ru.ts';
import es from './es.ts';
import zhCN from './zh-CN.ts';
import zhTW from './zh-TW.ts';
const KEYS = [
'ai.externalMcp.approvalAlert',
'ai.externalMcp.approvalAlert.description',
'ai.externalMcp.approvalAlert.off',
'ai.externalMcp.approvalAlert.unfocused',
'ai.externalMcp.approvalAlert.always',
'ai.externalMcp.approvalAlert.notificationTitle',
'ai.externalMcp.approvalAlert.notificationBody',
'ai.externalMcp.approvalAlert.notificationBodyOnHost',
] as const;
test('External MCP approval alerts are localized in every supported locale', () => {
for (const [name, messages] of Object.entries({ en, es, 'zh-CN': zhCN, 'zh-TW': zhTW, ru })) {
const missing = KEYS.filter((key) => !messages[key]);
assert.deepEqual(missing, [], `${name} is missing approval alert labels`);
assert.match(messages['ai.externalMcp.approvalAlert.notificationBody'], /\{tool\}/);
assert.match(messages['ai.externalMcp.approvalAlert.notificationBodyOnHost'], /\{tool\}/);
assert.match(messages['ai.externalMcp.approvalAlert.notificationBodyOnHost'], /\{host\}/);
}
});
@@ -1,58 +0,0 @@
import assert from "node:assert/strict";
import test from "node:test";
import en from "./en.ts";
import ru from "./ru.ts";
import es from "./es.ts";
import zhCN from "./zh-CN.ts";
import zhTW from "./zh-TW.ts";
const KEYS = [
"ai.externalMcp.http.title",
"ai.externalMcp.http.description",
"ai.externalMcp.http.enable",
"ai.externalMcp.http.port",
"ai.externalMcp.http.portHint",
"ai.externalMcp.http.allowCustomBind",
"ai.externalMcp.http.allowCustomBind.description",
"ai.externalMcp.http.listenAddress",
"ai.externalMcp.http.listenAddress.placeholder",
"ai.externalMcp.http.clientHost",
"ai.externalMcp.http.clientHost.description",
"ai.externalMcp.http.clientHost.placeholder",
"ai.externalMcp.http.clientHostRequired",
"ai.externalMcp.http.invalidClientHost",
"ai.externalMcp.http.warning",
"ai.externalMcp.http.url",
"ai.externalMcp.http.token",
"ai.externalMcp.http.regenerate",
"ai.externalMcp.http.regenerateHint",
"ai.externalMcp.http.wslHint",
"ai.externalMcp.http.codexSnippet",
"ai.externalMcp.http.claudeCommand",
"ai.externalMcp.http.genericSnippet",
"ai.externalMcp.http.envLine",
"ai.externalMcp.http.notListening",
"ai.externalMcp.http.listening",
"ai.externalMcp.http.portInUse",
"ai.externalMcp.http.requiresExternalMcp",
"ai.externalMcp.http.invalidPort",
"ai.externalMcp.http.invalidAddress",
"ai.externalMcp.http.listenFailed",
"ai.externalMcp.http.legacySseNote",
] as const;
test("External MCP HTTP strings exist in every locale", () => {
for (const [name, messages] of Object.entries({ en, es, "zh-CN": zhCN, "zh-TW": zhTW, ru })) {
const missing = KEYS.filter((key) => !messages[key]);
assert.deepEqual(missing, [], `${name} is missing HTTP MCP labels`);
assert.match(messages["ai.externalMcp.http.portInUse"], /\{port\}/);
}
assert.match(zhTW["ai.externalMcp.http.port"], /連接埠/);
assert.match(zhTW["ai.externalMcp.http.listenAddress"], /位址/);
assert.match(zhTW["ai.externalMcp.http.clientHost"], /位址/);
assert.doesNotMatch(zhTW["ai.externalMcp.http.clientHost"], /地址/);
assert.doesNotMatch(zhTW["ai.externalMcp.http.port"], /端口/);
assert.doesNotMatch(zhTW["ai.externalMcp.http.listenAddress"], /地址/);
assert.match(zhTW["ai.externalMcp.http.wslHint"], /鏡像網路/);
});
@@ -1,23 +0,0 @@
import assert from 'node:assert/strict';
import test from 'node:test';
import en from './en.ts';
import es from './es.ts';
import ru from './ru.ts';
import zhCN from './zh-CN.ts';
import zhTW from './zh-TW.ts';
const KEYS = [
'title', 'description', 'boundary', 'enable', 'privateIps', 'privateIps.description',
'cidrs', 'cidrs.description', 'patterns', 'patterns.description',
'connectionScope', 'reconnect', 'apply', 'applying', 'applied', 'failed',
];
test('Shared AI privacy settings are localized in every supported locale', () => {
for (const [name, messages] of Object.entries({ en, es, ru, 'zh-CN': zhCN, 'zh-TW': zhTW })) {
assert.deepEqual(
KEYS.filter((key) => !messages[`ai.privacy.${key}`]),
[],
`${name} is missing privacy settings labels`,
);
}
});
@@ -0,0 +1,230 @@
import assert from "node:assert/strict";
import { readFileSync } from "node:fs";
import test from "node:test";
import { describePluginGitHubInstallError } from "../../../domain/pluginGitHubInstallError.ts";
import { SUPPORTED_UI_LOCALES } from "../../../infrastructure/config/i18n.ts";
import { getLoadedLocaleMessages, loadLocaleMessages } from "../messages.ts";
import en from "./en.ts";
import { enMonitorMessages } from "./en/monitor.ts";
import { enSystemManagerMessages } from "./en/systemManager.ts";
import { enTerminalMessages } from "./en/terminal.ts";
import es from "./es.ts";
import { esMonitorMessages } from "./es/monitor.ts";
import { esSystemManagerMessages } from "./es/systemManager.ts";
import { esTerminalMessages } from "./es/terminal.ts";
import ru from "./ru.ts";
import { ruMonitorMessages } from "./ru/monitor.ts";
import { ruSystemManagerMessages } from "./ru/systemManager.ts";
import { ruTerminalMessages } from "./ru/terminal.ts";
import zhCN from "./zh-CN.ts";
import { zhCNMonitorMessages } from "./zh-CN/monitor.ts";
import { zhCnSystemManagerMessages } from "./zh-CN/systemManager.ts";
import { zhCNVaultMessages } from "./zh-CN/vault.ts";
import zhTW from "./zh-TW.ts";
import { zhTWMonitorMessages } from "./zh-TW/monitor.ts";
import { zhTwSystemManagerMessages } from "./zh-TW/systemManager.ts";
import { zhTWVaultMessages } from "./zh-TW/vault.ts";
const ALL_LOCALES = {
en,
es,
ru,
"zh-CN": zhCN,
"zh-TW": zhTW,
} as const;
test("disconnect confirm copy states that saved provider credentials are removed and local data stays", () => {
const expected = [
[en, "will be removed"],
[es, "eliminarán"],
[ru, "будут удалены"],
[zhCN, "删除"],
[zhTW, "刪除"],
] as const;
for (const [messages, fragment] of expected) {
assert.ok(
messages["cloudSync.provider.disconnect.confirmMessage"]?.includes(fragment),
`confirmMessage should mention credential removal: ${fragment}`,
);
}
assert.match(
en["cloudSync.provider.disconnect.confirmMessage"],
/backup history and sync encryption password stay here/,
);
assert.doesNotMatch(en["cloudSync.provider.disconnect.cloudRemains"], /change.*password/);
});
test("Taiwan Traditional Chinese copy uses Taiwan terminology for HTTP MCP and OpenCode 2", () => {
assert.match(zhTW["ai.externalMcp.http.port"], /連接埠/);
assert.match(zhTW["ai.externalMcp.http.listenAddress"], /位址/);
assert.match(zhTW["ai.externalMcp.http.clientHost"], /位址/);
assert.doesNotMatch(zhTW["ai.externalMcp.http.clientHost"], /地址/);
assert.doesNotMatch(zhTW["ai.externalMcp.http.port"], /端口/);
assert.doesNotMatch(zhTW["ai.externalMcp.http.listenAddress"], /地址/);
assert.match(zhTW["ai.externalMcp.http.wslHint"], /鏡像網路/);
const opencodeKeys = [
"ai.opencode.v2.startupTimeout",
"ai.opencode.v2.exited",
"ai.opencode.v2.unauthorized",
"ai.opencode.v2.unavailable",
"ai.opencode.v2.sessionFailed",
"ai.opencode.v2.empty",
"ai.opencode.v2.contextSkipped",
"ai.opencode.v2.mcpSkipped",
];
for (const key of opencodeKeys) {
assert.notEqual(en[key], zhCN[key]);
assert.notEqual(en[key], zhTW[key]);
assert.notEqual(zhCN[key], zhTW[key]);
}
const text = opencodeKeys.map((key) => zhTW[key]).join("\n");
assert.match(text, /終端機/);
assert.match(text, /連線/);
assert.match(text, /設定/);
assert.match(text, /傳回/);
assert.equal(text.includes("终端"), false);
assert.equal(text.includes("连接"), false);
assert.equal(text.includes("设置"), false);
assert.equal(text.includes("返回"), false);
});
test("monitoring UI literal message keys exist and all monitor locales stay at parity", () => {
for (const name of ["MonitorPanels", "MonitorNavButton", "MonitorDiskUsage"]) {
const source = readFileSync(new URL(`../../../components/vault/${name}.tsx`, import.meta.url), "utf8");
const keys = [...source.matchAll(/\bt\("(monitor\.[^"]+)"/g)].map((match) => match[1]);
for (const key of keys) {
assert.ok(Object.hasOwn(enMonitorMessages, key), `${name}: ${key}`);
}
}
for (const [locale, messages] of Object.entries({
es: esMonitorMessages,
ru: ruMonitorMessages,
"zh-CN": zhCNMonitorMessages,
"zh-TW": zhTWMonitorMessages,
})) {
assert.deepEqual(Object.keys(messages).sort(), Object.keys(enMonitorMessages).sort(), locale);
}
});
test("GitHub plugin install copy is complete in every supported locale and error presentation maps statuses", async () => {
const keys = Object.keys(en).filter((key) => key.startsWith("settings.plugins.github."));
assert.ok(keys.length > 30);
for (const { id } of SUPPORTED_UI_LOCALES) {
await loadLocaleMessages(id);
const messages = getLoadedLocaleMessages(id)!;
for (const key of keys) {
assert.ok(messages[key]?.trim(), `${id}: ${key}`);
}
}
const expired = describePluginGitHubInstallError(
"Error invoking remote method 'plugins:github:install': Error: GitHub package preview expired. Download and review it again",
);
assert.equal(expired.key, "settings.plugins.github.error.expired");
assert.equal(expired.details, null);
assert.deepEqual(describePluginGitHubInstallError("GitHub download failed (HTTP 503)").values, { status: "503" });
const validator = "manifest version must be a semantic version";
assert.equal(describePluginGitHubInstallError(validator).details, validator);
assert.equal(describePluginGitHubInstallError(validator).key, "settings.plugins.github.error.failed");
assert.equal(
describePluginGitHubInstallError("Plugin is incompatible: engine version").key,
"settings.plugins.github.error.incompatible",
);
});
test("SSH network latency wording stays aligned between terminal and system manager surfaces", () => {
const surfaces = [
[enTerminalMessages, enSystemManagerMessages],
[ruTerminalMessages, ruSystemManagerMessages],
[esTerminalMessages, esSystemManagerMessages],
[zhCNVaultMessages, zhCnSystemManagerMessages],
[zhTWVaultMessages, zhTwSystemManagerMessages],
] as const;
for (const [terminalMessages, systemManagerMessages] of surfaces) {
assert.ok(terminalMessages["terminal.serverStats.latency"]);
assert.equal(
terminalMessages["terminal.serverStats.latency"],
systemManagerMessages["systemManager.overview.latency"],
);
}
});
test("English snippet bulk-delete copy stays entity-neutral and grammatical for one item", () => {
assert.equal(
en["snippets.selection.deleteConfirmTitle"].replace("{count}", "1"),
"Delete selected items (1)?",
);
assert.equal(
en["snippets.selection.deleteSuccess"].replace("{count}", "1"),
"Deleted selected items: 1.",
);
});
test("inline image settings copy is translated rather than left in English", () => {
const translatedKeys = [
"settings.terminal.section.inlineImages",
"settings.terminal.inlineImages.enabled",
"settings.terminal.inlineImages.enabled.desc",
"settings.terminal.inlineImages.kitty",
"settings.terminal.inlineImages.kitty.desc",
"settings.terminal.inlineImages.sixel.desc",
"settings.terminal.inlineImages.iip",
"settings.terminal.inlineImages.iip.desc",
"settings.terminal.inlineImages.storageLimit",
"settings.terminal.inlineImages.storageLimit.desc",
"settings.terminal.inlineImages.maxMegapixels",
"settings.terminal.inlineImages.maxMegapixels.desc",
"settings.terminal.inlineImages.sequenceLimit",
"settings.terminal.inlineImages.sequenceLimit.desc",
"settings.terminal.inlineImages.hibernateNote",
];
for (const [locale, messages] of Object.entries(ALL_LOCALES)) {
if (locale === "en") continue;
const untranslated = translatedKeys.filter((key) => messages[key] === en[key]);
assert.deepEqual(untranslated, [], `${locale} still uses the English string`);
}
});
test("removed session log rememberApplication key stays absent across locales", () => {
for (const [locale, messages] of Object.entries(ALL_LOCALES)) {
assert.equal(
messages["terminal.toolbar.sessionLog.rememberApplication"],
undefined,
`${locale} should not reintroduce removed rememberApplication key`,
);
}
});
test("managed group delete warning mentions SSH config backup in every locale", () => {
const backupMarkers = ["备份", "備份", "copia de seguridad", "резервную копию", "Back up"];
for (const [locale, messages] of Object.entries(ALL_LOCALES)) {
const text = messages["vault.groups.deleteDialog.managedWarning"] ?? "";
assert.match(text, /SSH/, `${locale} warning should reference the SSH config file`);
assert.ok(
backupMarkers.some((marker) => text.includes(marker)),
`${locale} warning should tell the user to back up the file`,
);
}
});
test("AI tool output limit settings copy is localized across all five locales", () => {
const keys = [
"ai.safety.toolOutputMaxChars",
"ai.safety.toolOutputMaxChars.description",
"ai.safety.toolOutputMaxChars.unit",
] as const;
for (const [locale, messages] of Object.entries(ALL_LOCALES)) {
for (const key of keys) {
assert.ok(messages[key]?.trim(), `${locale}: missing ${key}`);
if (locale !== "en") {
assert.notEqual(messages[key], en[key], `${locale}: ${key} should be translated`);
}
}
}
assert.match(zhTW["ai.safety.toolOutputMaxChars.description"], /傳回/);
assert.equal(zhTW["ai.safety.toolOutputMaxChars.description"].includes("返回"), false);
});
@@ -1,40 +0,0 @@
import { test } from "node:test";
import assert from "node:assert/strict";
import { readFileSync } from "node:fs";
import { enMonitorMessages } from "./en/monitor";
import { esMonitorMessages } from "./es/monitor";
import { ruMonitorMessages } from "./ru/monitor";
import { zhCNMonitorMessages } from "./zh-CN/monitor";
import { zhTWMonitorMessages } from "./zh-TW/monitor";
test("monitoring UI literal message keys exist, including editor-only controls", () => {
for (const name of ["MonitorPanels", "MonitorNavButton", "MonitorDiskUsage"]) {
const source = readFileSync(new URL(`../../../components/vault/${name}.tsx`, import.meta.url), "utf8");
const keys = [...source.matchAll(/\bt\("(monitor\.[^"]+)"/g)].map((match) => match[1]);
for (const key of keys)
assert.ok(Object.hasOwn(enMonitorMessages, key), `${name}: ${key}`);
}
});
for (const [locale, messages] of Object.entries({
es: esMonitorMessages,
ru: ruMonitorMessages,
"zh-CN": zhCNMonitorMessages,
"zh-TW": zhTWMonitorMessages,
})) {
test(`monitoring has translated actions, states and matching placeholders in ${locale}`, () => {
assert.deepEqual(
Object.keys(messages).sort(),
Object.keys(enMonitorMessages).sort(),
);
for (const key of Object.keys(enMonitorMessages)) {
const english = enMonitorMessages[key as keyof typeof enMonitorMessages];
const translated = messages[key as keyof typeof messages];
assert.ok(translated.trim(), key);
assert.deepEqual(
(translated.match(/\{\w+\}/g) ?? []).sort(),
(english.match(/\{\w+\}/g) ?? []).sort(),
key,
);
}
});
}
@@ -1,39 +0,0 @@
import test from 'node:test';
import assert from 'node:assert/strict';
import en from './en';
import zhCN from './zh-CN';
import zhTW from './zh-TW';
const KEYS = [
'ai.opencode.v2.startupTimeout',
'ai.opencode.v2.exited',
'ai.opencode.v2.unauthorized',
'ai.opencode.v2.unavailable',
'ai.opencode.v2.sessionFailed',
'ai.opencode.v2.empty',
'ai.opencode.v2.contextSkipped',
'ai.opencode.v2.mcpSkipped',
];
test('OpenCode 2 strings exist in English, Simplified Chinese, and Taiwan Chinese', () => {
for (const key of KEYS) {
assert.equal(typeof en[key], 'string', `en missing ${key}`);
assert.equal(typeof zhCN[key], 'string', `zh-CN missing ${key}`);
assert.equal(typeof zhTW[key], 'string', `zh-TW missing ${key}`);
assert.notEqual(en[key], zhCN[key]);
assert.notEqual(en[key], zhTW[key]);
assert.notEqual(zhCN[key], zhTW[key]);
}
});
test('Taiwan OpenCode 2 wording uses Taiwan terms', () => {
const text = KEYS.map((key) => zhTW[key]).join('\n');
assert.match(text, /終端機/);
assert.match(text, /連線/);
assert.match(text, /設定/);
assert.match(text, /傳回/);
assert.equal(text.includes('终端'), false);
assert.equal(text.includes('连接'), false);
assert.equal(text.includes('设置'), false);
assert.equal(text.includes('返回'), false);
});
@@ -1,30 +0,0 @@
import assert from 'node:assert/strict';
import test from 'node:test';
import { SUPPORTED_UI_LOCALES } from '../../../infrastructure/config/i18n';
import { getLoadedLocaleMessages, loadLocaleMessages } from '../messages';
import en from './en';
import { describePluginGitHubInstallError } from '../../../domain/pluginGitHubInstallError';
test('GitHub install copy and error interpolation are complete in every supported UI locale', async () => {
const keys = Object.keys(en).filter(key => key.startsWith('settings.plugins.github.'));
assert.ok(keys.length > 30);
for (const { id } of SUPPORTED_UI_LOCALES) {
await loadLocaleMessages(id);
const messages = getLoadedLocaleMessages(id)!;
for (const key of keys) {
assert.ok(messages[key]?.trim(), `${id}: ${key}`);
assert.deepEqual(messages[key].match(/\{\w+\}/g) ?? [], en[key].match(/\{\w+\}/g) ?? [], `${id}: ${key}`);
}
}
});
test('GitHub error presentation handles Electron wrappers, HTTP status and diagnostic fallback', () => {
const expired = describePluginGitHubInstallError("Error invoking remote method 'plugins:github:install': Error: GitHub package preview expired. Download and review it again");
assert.equal(expired.key, 'settings.plugins.github.error.expired');
assert.equal(expired.details, null);
assert.deepEqual(describePluginGitHubInstallError('GitHub download failed (HTTP 503)').values, { status: '503' });
const validator = 'manifest version must be a semantic version';
assert.equal(describePluginGitHubInstallError(validator).details, validator);
assert.equal(describePluginGitHubInstallError(validator).key, 'settings.plugins.github.error.failed');
assert.equal(describePluginGitHubInstallError('Plugin is incompatible: engine version').key, 'settings.plugins.github.error.incompatible');
});
+23 -6
View File
@@ -43,6 +43,9 @@ export const ruAiMessages: Messages = {
'ai.providers.apiKey': 'API-ключ',
'ai.providers.apiKey.placeholder': 'Введите API-ключ',
'ai.providers.apiKey.decrypting': 'Расшифровка...',
'ai.providers.opencodeGo.help': 'Вставьте API-ключ OpenCode, чтобы использовать OpenCode Go. Базовый URL и список моделей настроятся автоматически.',
'ai.providers.opencodeGo.getKey': 'Получить API-ключ',
'ai.providers.fixedBaseUrl.help': 'Задаётся провайдером. Netcatty автоматически выбирает путь эндпоинта для каждой модели.',
'ai.providers.baseUrl': 'Базовый URL',
'ai.providers.baseUrl.anthropicHelp': 'Anthropic-совместимый: хост с /v1 или без (например https://gateway.example или https://gateway.example/v1). Проверка и чат используют /v1/models и /v1/messages.',
'ai.providers.baseUrl.ollamaHelp': 'Локальный Ollama: http://localhost:11434/v1 (без API-ключа). Ollama Cloud: https://ollama.com/v1 и ключ Cloud.',
@@ -554,6 +557,23 @@ export const ruAiMessages: Messages = {
'ai.chat.rebindUsage': 'Использование: /rebind <номер из /chats>',
'ai.chat.rebindDone': 'Чат «{title}» привязан к этой панели.',
'ai.chat.rebindUnavailable': 'В области этой панели нет цели для привязки.',
'ai.chat.managerScopeTab': 'Текущие чаты',
'ai.chat.managerAllChatsTab': 'Все чаты',
'ai.chat.managerSearchPlaceholder': 'Поиск по названиям чатов…',
'ai.chat.managerFilterAllAgents': 'Все агенты',
'ai.chat.managerMoreActions': 'Ещё действия',
'ai.chat.managerOpen': 'Открыть в этой панели',
'ai.chat.managerOpenDisabled': 'Открыт в другом рабочем пространстве или терминале',
'ai.chat.managerRebind': 'Переместить в…',
'ai.chat.managerRebindPick': 'Выберите терминал или рабочее пространство…',
'ai.chat.managerRebindHere': 'Текущая панель',
'ai.chat.managerRebindDone': 'Чат «{title}» перемещён в {target}.',
'ai.chat.managerExportOne': 'Экспортировать этот чат',
'ai.chat.managerBadgeActive': 'Активен',
'ai.chat.managerBadgeIdle': 'Простой',
'ai.chat.managerMessagesCount': '{n} сообщений',
'ai.chat.managerDeleteTitle': 'Удалить этот чат?',
'ai.chat.managerDeleteMessage': '«{title}» и его сообщения будут удалены из всех панелей. Это действие нельзя отменить.',
'ai.chat.justNow': 'Только что',
'ai.chat.minutesAgo': '{n}м назад',
'ai.chat.hoursAgo': '{n}ч назад',
@@ -641,6 +661,9 @@ export const ruAiMessages: Messages = {
'ai.safety.responseIdleTimeout.unit': 'с',
'ai.safety.maxIterations': 'Макс. число итераций',
'ai.safety.maxIterations.description': 'Максимальное число циклов использования инструментов AI, чтобы предотвратить бесконтрольное выполнение. У внешних агентов могут быть собственные внутренние лимиты итераций, имеющие приоритет.',
'ai.safety.toolOutputMaxChars': 'Лимит вывода инструментов встроенного ИИ',
'ai.safety.toolOutputMaxChars.description': 'Максимум символов, оставляемых напрямую в результате инструмента встроенного ИИ (например, вывода команд терминала или чтения SFTP) до обрезки и сохранения полного вывода в дескриптор (2 000–200 000).',
'ai.safety.toolOutputMaxChars.unit': 'симв.',
'ai.safety.blocklist': 'Чёрный список команд',
'ai.safety.blocklist.description': 'Regex-шаблоны для блокировки опасных команд. Применяется как к встроенным, так и к внешним агентам через механизм выполнения Netcatty.',
'ai.safety.blocklist.placeholder': 'Regex-шаблон...',
@@ -671,9 +694,6 @@ export const ruAiMessages: Messages = {
'terminal.layer.theme': 'Тема',
'terminal.layer.notes': 'Заметки',
'terminal.layer.aiChat': 'AI-чат',
'terminal.layer.movePanelLeft': 'Переместить панель влево',
'terminal.layer.movePanelRight': 'Переместить панель вправо',
'terminal.layer.movePanelBottom': 'Переместить панель вниз',
'terminal.layer.choosePanelPosition': 'Изменить положение',
'terminal.layer.dockLeft': 'Слева',
'terminal.layer.dockRight': 'Справа',
@@ -701,15 +721,12 @@ export const ruAiMessages: Messages = {
'topTabs.openQuickSwitcher': 'Открыть быстрый переключатель',
'topTabs.moreTabs': 'Больше вкладок',
'topTabs.aiAssistant': 'AI-помощник',
'topTabs.newLocalTerminal': 'Новый локальный терминал',
'topTabs.controlPanel': 'Быстрые настройки',
'topTabs.controlPanel.externalMcp': 'Внешний MCP',
'topTabs.controlPanel.theme': 'Тема',
'topTabs.controlPanel.theme.light': 'Светлая',
'topTabs.controlPanel.theme.dark': 'Тёмная',
'topTabs.controlPanel.theme.system': 'Системная',
'topTabs.externalMcp.enable': 'Включить внешний MCP',
'topTabs.externalMcp.disable': 'Отключить внешний MCP',
'topTabs.windowOpacity': 'Прозрачность окна',
'topTabs.openSettings': 'Открыть настройки',
'ai.chat.sessionHistory': 'История сессий',
+5 -14
View File
@@ -38,7 +38,6 @@ export const ruCoreMessages: Messages = {
"settings.plugins.github.error.failed": "Не удалось проверить или установить плагин. Изучите технические подробности перед повторной попыткой.",
"settings.plugins.github.error.details": "Технические подробности",
// Common
'common.save': 'Сохранить',
'common.cancel': 'Отмена',
@@ -58,7 +57,6 @@ export const ruCoreMessages: Messages = {
'common.edit': 'Редактировать',
'common.clear': 'Очистить',
'common.optional': 'Необязательно',
'common.selectPlaceholder': 'Выбрать...',
'common.add': 'Добавить',
'common.rename': 'Переименовать',
'common.refresh': 'Обновить',
@@ -97,11 +95,9 @@ export const ruCoreMessages: Messages = {
'field.label': 'Метка',
'field.type': 'Тип',
'auth.keyType': 'Тип {type}',
'auth.showAllKeys': 'Показать все ключи',
// Dialogs / prompts
'confirm.deleteHost': 'Удалить хост "{name}"?',
'confirm.deleteIdentity': 'Удалить идентификатор "{name}"?',
'confirm.removeProvider': 'Удалить провайдера "{name}"?',
'confirm.closeBusyTerminal.title': 'Подтвердите закрытие',
'confirm.closeBusyTerminal.message': 'Процесс "{command}" всё ещё выполняется и будет завершён.',
@@ -359,7 +355,6 @@ export const ruCoreMessages: Messages = {
'tray.status.inactive': 'Неактивно',
'tray.status.error': 'Ошибка',
'tray.status.unknown': 'Неизвестно',
'tray.recentHosts': 'Недавние хосты',
'tray.empty.title': 'Пока здесь ничего нет',
'tray.empty.subtitle': 'Подключитесь к серверу, они по вам скучают 🚀',
'tray.quit': 'Выйти из Netcatty',
@@ -418,9 +413,6 @@ export const ruCoreMessages: Messages = {
'update.downloadFailed.message': 'Не удалось скачать обновление. Вы можете скачать его вручную.',
'update.needsSave.title': 'Несохранённые изменения',
'update.needsSave.message': 'Сначала сохраните открытые редакторы, затем снова нажмите «Перезапустить сейчас», чтобы установить обновление.',
'update.openReleases': 'Открыть релизы',
'update.remindLater': 'Напомнить позже',
'update.skipVersion': 'Пропустить эту версию',
// Settings > Appearance
'settings.appearance.uiTheme': 'Тема интерфейса',
@@ -440,7 +432,7 @@ export const ruCoreMessages: Messages = {
'settings.appearance.themeColor.dark': 'Палитра тёмной темы',
'settings.appearance.customCss': 'Пользовательский CSS',
'settings.appearance.customCss.desc':
'Добавьте пользовательский CSS, чтобы настроить внешний вид. Изменения применяются сразу. Выбранные верхние вкладки (`.top-tab[data-active="true"]`) читают `--top-tab-active-bg`, `--top-tab-active-fg` и `--top-tab-active-border`. Не задавайте их, чтобы сохранить текущий вид.',
'Добавьте пользовательский CSS, чтобы настроить внешний вид. Изменения применяются сразу.',
'settings.appearance.customCss.help.ariaLabel': 'Справка по пользовательскому CSS',
'settings.appearance.customCss.help.title': 'Руководство по пользовательскому CSS',
'settings.appearance.customCss.help.body': `Основные области интерфейса помечены атрибутом \`data-section\` для CSS-селекторов. Изменения применяются сразу после правки.
@@ -840,6 +832,8 @@ export const ruCoreMessages: Messages = {
'settings.terminal.connection.temporaryLegacyAlgorithms.desc': 'SSH-подключения без сохранённого хоста, включая запуск в стиле PuTTY и быстрое подключение, предлагают те же устаревшие алгоритмы, что и настройка хоста. Сохранённые хосты используют свою настройку. По умолчанию выключено: у этих алгоритмов есть известные слабости.',
'settings.terminal.connection.temporaryNetworkDeviceMode': 'Режим сетевого устройства для временных подключений',
'settings.terminal.connection.temporaryNetworkDeviceMode.desc': 'SSH-подключения без сохранённого хоста, включая внешний запуск и быстрое подключение, открываются в режиме сетевого устройства. Сохранённые хосты и группы сохраняют свой тип устройства. По умолчанию выключено.',
'settings.terminal.connection.sshAutoReconnectInterval': 'Интервал переподключения SSH (секунды)',
'settings.terminal.connection.sshAutoReconnectInterval.desc': 'Ожидание между попытками: 5–3600 секунд (по умолчанию 5). Изменение применяется к следующему ожиданию; уже запущенный таймер не меняется.',
'settings.terminal.connection.keepaliveInterval': 'Интервал keepalive',
'settings.terminal.connection.keepaliveInterval.desc': 'Как часто (в секундах) отправлять keepalive-пакеты на уровне SSH. Установите 0, чтобы отключить глобально. Учтите, что отдельные хосты могут переопределять это значение в своих настройках.',
'settings.terminal.connection.keepaliveCountMax': 'Макс. число пропущенных keepalive',
@@ -958,6 +952,7 @@ export const ruCoreMessages: Messages = {
'settings.shortcuts.binding.close-tab': 'Закрыть вкладку',
'settings.shortcuts.binding.close-session': 'Закрыть панель сессии',
'settings.shortcuts.binding.new-tab': 'Новая локальная вкладка',
'settings.shortcuts.binding.reopen-closed-tab': 'Повторно открыть закрытую вкладку',
'settings.shortcuts.binding.copy': 'Копировать из терминала',
'settings.shortcuts.binding.paste': 'Вставить в терминал',
'settings.shortcuts.binding.paste-selection': 'Вставить выделение в терминал',
@@ -997,8 +992,6 @@ export const ruCoreMessages: Messages = {
'settings.shortcuts.binding.sftp-navigate-to': 'Перейти в выбранную директорию',
// Context menus / common actions
'action.newHost': 'Новый хост',
'action.newSubfolder': 'Новая подпапка',
'action.copyPublicKey': 'Копировать публичный ключ',
'action.keyExport': 'Экспорт ключа',
'action.edit': 'Редактировать',
@@ -1188,12 +1181,9 @@ export const ruCoreMessages: Messages = {
"settings.plugins.manager.remove": "Удалить",
"settings.plugins.manager.removeNote": "Удаление очищает код пакета и локальные данные KV. Настройки пользователя, секреты и данные синхронизации сохраняются.",
"settings.plugins.permissions.statusUnknown": "Состояние неизвестно",
"plugins.sidebar.extensions": "Страницы расширений",
"plugins.sidebar.selectTerminal": "Сначала выберите открытый терминал.",
"plugins.sidebar.loading": "Загрузка страницы расширения…",
"plugins.vault.loading": "Загрузка страницы плагина…",
"plugins.vault.extensions": "Расширения",
"plugins.vault.back": "К хостам",
"plugins.interaction.title": "Запрос плагина",
"plugins.interaction.sharing": "Переданный текст доступен плагину и его разрешённым возможностям, включая сеть. Чтение не разрешает новый сетевой адрес.",
"plugins.interaction.input": "Ввести текст",
@@ -1338,6 +1328,7 @@ export const ruCoreMessages: Messages = {
'plugins.hostActions.selectionNote': 'Передаются только метаданные выбранных хостов: сохранённые имена, адреса, пользователи, протоколы, группы и теги. Группа включает только выбранные сейчас хосты. Дальнейшие запросы изменения или подключения зависят от настроек разрешений плагина.',
'plugins.hostActions.create': 'Проверить черновик хоста',
'plugins.hostActions.edit': 'Проверить изменения хоста',
'plugins.hostActions.streamNote': 'Разрешить этому плагину отправлять и получать данные по указанному адресу через выбранный SSH-сервер. Адреса разрешаются на этом сервере. Это может читать или изменять данные базы данных. Терминал и стартовые скрипты не запускаются. Пароли и ключи SSH остаются в приложении. Выберите SSH-сервер для продолжения.',
'plugins.hostActions.connect': 'Подтвердить подключение',
'plugins.hostActions.fieldDiff': 'Изменения для сохранения',
'plugins.hostActions.defaultsWarning': 'Применяются сохранённые настройки подключения. Смена группы может изменить унаследованные настройки входа, прокси и скрипты.',
-20
View File
@@ -1,6 +1,5 @@
export const ruScriptsMessages = {
'scripts.meta.name': 'Название',
'scripts.meta.language': 'Язык',
'scripts.meta.description': 'Описание',
'scripts.meta.descriptionPlaceholder': 'Необязательные заметки об этом скрипте',
'scripts.meta.trigger': 'Триггер',
@@ -15,7 +14,6 @@ export const ruScriptsMessages = {
'scripts.actions.openEditor': 'Открыть редактор',
'scripts.actions.openEditorHint': 'Редактировать скрипт в большом окне',
'scripts.editor.modalTitle': 'Редактор скриптов',
'scripts.editor.modalSubtitle': 'Редактируйте метаданные и код скрипта в большом рабочем пространстве.',
'scripts.editor.lineCount': '{count} строк',
'scripts.editor.resize': 'Изменить размер редактора',
'scripts.targets.hint': 'Выбранные группы разрешаются динамически, поэтому новые хосты включаются автоматически.',
@@ -86,17 +84,13 @@ export const ruScriptsMessages = {
'scripts.dialog.retry': 'Повторить',
'scripts.dialog.skip': 'Пропустить',
'scripts.dialog.abort': 'Прервать',
'scripts.running.stepProgress': 'Шаг {current} / {total}',
'scripts.running.determinateProgress': '{label} {current}/{total}',
'scripts.running.progressFallback': 'Выполнение',
'scripts.running.operationsCount': 'Операций: {count}',
'scripts.running.opsPrefix': '',
'scripts.running.opsSuffix': ' операций',
'scripts.running.elapsedLabel': 'Прошло времени',
'scripts.running.lastSentLabel': 'Отправлено:',
'scripts.running.elapsed': '{elapsed}',
'scripts.running.completedSummary': 'Завершено · операций: {count} · {elapsed}',
'scripts.running.dismissHint': 'Нажмите закрытие, чтобы скрыть',
'scripts.running.dismiss': 'Закрыть',
'scripts.running.viewLogs': 'Просмотреть журнал',
'scripts.running.logTitle': '{name} · Журнал запуска',
@@ -111,26 +105,12 @@ export const ruScriptsMessages = {
'vault.nav.scripts': 'Скрипты',
'snippets.action.newScript': 'Новый сценарий автоматизации',
'hostDetails.section.automation': 'Автоматизация',
'hostDetails.automation.loginScript': 'Скрипт входа',
'hostDetails.automation.loginScriptPlaceholder': 'Выберите скрипт',
'hostDetails.automation.none': 'Нет',
'hostDetails.automation.outputTriggers': 'Триггеры вывода',
'hostDetails.automation.addTrigger': 'Добавить триггер',
'hostDetails.automation.triggerPatternPlaceholder': 'Регулярное выражение',
'hostDetails.automation.linkedScripts': 'Связанные скрипты',
'hostDetails.automation.linkedScriptsEmpty': 'С этим хостом пока не связано ни одного скрипта.',
'hostDetails.automation.linkScriptPlaceholder': 'Связать существующий скрипт…',
'hostDetails.automation.unlink': 'Отвязать',
'hostDetails.automation.equivalenceHint': 'Связь добавляет этот хост в список целей скрипта в разделе «Скрипты». Оба представления синхронизированы.',
'hostDetails.automation.queueHint': 'Скрипты запускаются по порядку при подключении этого хоста. Сначала выполняются глобальные скрипты, затем эта очередь.',
'hostDetails.automation.globalScripts': 'Глобальные скрипты подключения',
'hostDetails.automation.globalScriptsHint': 'Выполняются первыми при каждом подключении. Порядок можно изменить в библиотеке скриптов.',
'hostDetails.automation.connectQueue': 'Очередь запуска этого хоста',
'hostDetails.automation.connectQueueEmpty': 'В очереди этого хоста пока нет скриптов подключения.',
'hostDetails.automation.addToQueuePlaceholder': 'Добавить скрипт в очередь…',
'hostDetails.automation.moveUp': 'Переместить вверх',
'hostDetails.automation.moveDown': 'Переместить вниз',
'hostDetails.automation.removeFromQueue': 'Удалить из очереди',
'hostDetails.automation.dragHandle': 'Перетащите для изменения порядка',
'hostDetails.automation.queueDragHint': 'Перетаскивайте элементы, чтобы изменить порядок очереди подключения.',
};
@@ -14,13 +14,11 @@ export const ruSystemManagerMessages: Messages = {
'systemManager.tabs.docker': 'Docker',
'systemManager.tabs.gpu': 'GPU',
'systemManager.tabs.ariaLabel': 'Разделы системного менеджера',
'systemManager.popup.loading': 'Открытие терминала…',
'systemManager.popup.startupFailed': 'Команда запуска не была выполнена успешно. Проверьте, что цель доступна, и повторите попытку.',
'systemManager.errors.loadProcesses': 'Не удалось загрузить процессы',
'systemManager.errors.loadTmux': 'Не удалось загрузить сессии tmux',
'systemManager.errors.loadTmuxWindows': 'Не удалось загрузить окна tmux',
'systemManager.errors.loadTmuxPanes': 'Не удалось загрузить панели tmux',
'systemManager.errors.loadTmuxClients': 'Не удалось загрузить клиентов tmux',
'systemManager.errors.actionFailed': 'Не удалось выполнить действие',
'systemManager.errors.loadDocker': 'Не удалось загрузить контейнеры',
@@ -28,7 +26,6 @@ export const ruSystemManagerMessages: Messages = {
'systemManager.errors.loadDockerImages': 'Не удалось загрузить образы',
'systemManager.errors.loadKubernetes': 'Не удалось загрузить ресурсы Kubernetes',
'systemManager.errors.loadPods': 'Не удалось загрузить поды',
'systemManager.errors.loadOverview': 'Не удалось загрузить обзор системы',
'systemManager.errors.loadGpu': 'Не удалось загрузить статистику GPU / NPU',
'systemManager.errors.loadPorts': 'Не удалось загрузить слушающие порты',
'systemManager.errors.loadServices': 'Не удалось загрузить службы systemd',
@@ -62,13 +59,10 @@ export const ruSystemManagerMessages: Messages = {
'systemManager.overview.noTopProcesses': 'Нет данных процессов',
'systemManager.processes.search': 'Поиск процессов…',
'systemManager.processes.command': 'Команда',
'systemManager.processes.user': 'Пользователь',
'systemManager.processes.term': 'Завершить',
'systemManager.processes.kill': 'Убить',
'systemManager.processes.stop': 'Остановить (SIGSTOP)',
'systemManager.processes.cont': 'Продолжить (SIGCONT)',
'systemManager.processes.hup': 'Сигнал SIGHUP',
'systemManager.processes.renice': 'Изменить приоритет',
'systemManager.processes.renicePrompt': 'Значение nice (-20 до 19)',
'systemManager.processes.reniceInvalid': 'Nice должно быть от -20 до 19',
@@ -83,7 +77,6 @@ export const ruSystemManagerMessages: Messages = {
'systemManager.processes.stat': 'Состояние',
'systemManager.processes.meta': '{{count}} проц.',
'systemManager.processes.loading': 'Загрузка процессов…',
'systemManager.processes.loadingMore': 'Загрузка следующих процессов…',
'systemManager.processes.state.running': 'Активен',
'systemManager.processes.state.sleeping': 'Спящий',
'systemManager.processes.state.stopped': 'Остановлен',
@@ -121,12 +114,9 @@ export const ruSystemManagerMessages: Messages = {
'systemManager.tmux.attached': 'Подключена',
'systemManager.tmux.detached': 'Отключена',
'systemManager.tmux.windows': '{{count}} окон',
'systemManager.tmux.created': 'Создана',
'systemManager.tmux.activity': 'Активность',
'systemManager.tmux.rename': 'Переименовать',
'systemManager.tmux.detach': 'Отключить всех',
'systemManager.tmux.killSession': 'Завершить сессию',
'systemManager.tmux.killServer': 'Остановить сервер',
'systemManager.tmux.loadingDetails': 'Загрузка деталей…',
'systemManager.tmux.clients': 'Подключённые клиенты',
'systemManager.tmux.windowList': 'Окна',
@@ -137,31 +127,17 @@ export const ruSystemManagerMessages: Messages = {
'systemManager.docker.unavailable': 'На этом хосте не обнаружена среда контейнеров (Docker, Podman, nerdctl или kubectl)',
'systemManager.tmux.windowsMismatch': 'В сессии указано {{count}} окон, но list-windows ничего не вернул',
'systemManager.tmux.lastCommand': 'последняя команда: {{command}}',
'systemManager.tmux.noPanes': 'Нет панелей',
'systemManager.tmux.panes': '{{count}} пан.',
'systemManager.tmux.active': 'активно',
'systemManager.tmux.unnamedWindow': 'Безымянное окно',
'systemManager.tmux.unnamedPane': 'Безымянная панель',
'systemManager.tmux.attachWindow': 'Подключить к окну',
'systemManager.tmux.selectWindow': 'Выбрать окно',
'systemManager.tmux.killWindow': 'Закрыть окно',
'systemManager.tmux.killPane': 'Закрыть панель',
'systemManager.tmux.splitHorizontal': 'Разделить горизонтально',
'systemManager.tmux.splitVertical': 'Разделить вертикально',
'systemManager.tmux.sendKeys': 'Отправить клавиши',
'systemManager.tmux.sendKeysTo': 'Отправить клавиши в окно {{window}} панель {{pane}}',
'systemManager.tmux.sendKeysPlaceholder': 'Команда или текст…',
'systemManager.tmux.renameSessionPrompt': 'Переименовать сессию',
'systemManager.tmux.renameWindowPrompt': 'Переименовать окно',
'systemManager.tmux.windowName': 'Имя окна',
'systemManager.tmux.confirmKillSession': 'Завершить сессию tmux «{{name}}»?',
'systemManager.tmux.confirmDetachSession': 'Отключить всех клиентов от «{{name}}»?',
'systemManager.tmux.confirmKillWindow': 'Закрыть окно «{{name}}»?',
'systemManager.tmux.confirmKillPane': 'Закрыть панель #{{index}}?',
'systemManager.tmux.confirmKillServer': 'Остановить сервер tmux? Все сессии будут завершены.',
'systemManager.tmux.meta': '{{count}} сессий',
'systemManager.docker.title': 'Контейнеры',
'systemManager.docker.subTabs.containers': 'Контейнеры',
'systemManager.docker.subTabs.images': 'Образы',
'systemManager.docker.empty': 'Контейнеры не найдены',
@@ -174,7 +150,6 @@ export const ruSystemManagerMessages: Messages = {
'systemManager.docker.filter.paused': 'На паузе',
'systemManager.docker.shell': 'Оболочка',
'systemManager.docker.logs': 'Логи',
'systemManager.docker.details': 'Детали',
'systemManager.docker.inspect': 'Проверить',
'systemManager.docker.imageInspect': 'Проверить образ',
'systemManager.docker.confirmRemove': 'Удалить этот контейнер?',
+6 -63
View File
@@ -12,6 +12,10 @@ export const ruTerminalMessages: Messages = {
'terminal.directory.hidden': 'Показывать скрытые каталоги',
'terminal.directory.refresh': 'Обновить',
'terminal.directory.unavailable': 'Навигация по каталогам недоступна для этого сеанса.',
'terminal.directory.integrationUnavailable': 'Интеграция каталогов PowerShell не готова. Проверьте параметры запуска и политику выполнения.',
'terminal.directory.cmdIntegrationUnavailable': 'Ожидание данных о каталоге от исходного сеанса командной строки.',
'terminal.directory.nonFilesystem': 'Текущее расположение PowerShell не является каталогом файловой системы.',
'terminal.directory.accessDenied': 'Нет разрешения на просмотр содержимого этого каталога.',
'terminal.directory.busy': 'Дождитесь пустой командной строки.',
'terminal.directory.readFailed': 'Не удалось прочитать каталог. Попробуйте обновить.',
'terminal.directory.changeFailed': 'Не удалось подтвердить смену каталога. Обновите перед повтором.',
@@ -61,7 +65,6 @@ export const ruTerminalMessages: Messages = {
'logs.action.delete': 'Удалить',
// Log view
'logView.customizeAppearance': 'Настроить внешний вид',
'logView.appearance': 'Внешний вид',
'logView.readOnly': 'Только чтение',
'logView.export': 'Экспорт',
@@ -74,7 +77,6 @@ export const ruTerminalMessages: Messages = {
'terminal.toolbar.availableAfterConnect': 'Доступно после подключения',
'terminal.toolbar.sendYmodem': 'Отправить через YMODEM',
'terminal.toolbar.receiveYmodem': 'Получить через YMODEM',
'terminal.toolbar.sftp': 'SFTP',
'terminal.toolbar.more': 'Другие действия',
'terminal.toolbar.scripts': 'Скрипты',
'terminal.toolbar.history': 'История команд',
@@ -122,7 +124,6 @@ export const ruTerminalMessages: Messages = {
'terminal.composeBar.resize': 'Изменить высоту строки ввода',
'terminal.composeBar.manageSnippets': 'Управление быстрыми сниппетами',
'terminal.composeBar.searchSnippets': 'Поиск сниппетов...',
'terminal.composeBar.noPinnedSnippets': 'Закрепите сниппеты через + для быстрого доступа',
'terminal.composeBar.noMatchingSnippets': 'Сниппеты не найдены',
'terminal.composeBar.pinnedCount': 'Закреплено: {count}',
'terminal.composeBar.unpinSnippet': 'Убрать {label} из панели',
@@ -214,7 +215,6 @@ export const ruTerminalMessages: Messages = {
'terminal.osc7Setup.title': 'Настроить отслеживание каталога',
'terminal.osc7Setup.desc': 'Netcatty добавит хуки OSC 7 для текущего удалённого пользователя. Это помогает SFTP следовать за каталогом терминала после sudo или su.',
'terminal.osc7Setup.targets': 'Возможные файлы для обновления',
'terminal.osc7Setup.command': 'Команда для запуска',
'terminal.osc7Setup.run': 'Запустить настройку',
'terminal.osc7Setup.running': 'Настройка...',
'terminal.osc7Setup.configured': 'Отслеживание каталога настроено',
@@ -297,9 +297,6 @@ export const ruTerminalMessages: Messages = {
'terminal.themeModal.themeType': 'Тема {type}',
'terminal.hiddenTheme.title': 'Текущая скрытая тема',
'terminal.hiddenTheme.desc': 'Эта тема скрыта из ручного выбора и будет заменена, когда вы выберете другую тему.',
'topTabs.toggleTheme.systemExitTitle': 'Активна системная тема',
'topTabs.toggleTheme.systemExitMessage': 'Откройте настройки, чтобы выбрать фиксированную светлую или тёмную тему.',
'topTabs.toggleTheme.openSettings': 'Открыть настройки',
// Custom Themes
'terminal.customTheme.section': 'Пользовательские темы',
@@ -312,7 +309,6 @@ export const ruTerminalMessages: Messages = {
'terminal.customTheme.importDesc': 'Импорт из файла цветовой схемы iTerm2',
'terminal.customTheme.importError': 'Не удалось разобрать выбранный файл. Убедитесь, что это корректный XML-файл .itermcolors.',
'terminal.customTheme.delete': 'Удалить тему',
'terminal.customTheme.confirmDelete': 'Подтвердить удаление',
'terminal.customTheme.name': 'Название',
'terminal.customTheme.namePlaceholder': 'Моя пользовательская тема',
'terminal.customTheme.type': 'Тип',
@@ -372,10 +368,7 @@ export const ruTerminalMessages: Messages = {
'cloudSync.provider.disconnect.cloudRemains': 'Зашифрованные копии синхронизации могут остаться в хранилище {name}. Чтобы удалить их, удалите там файлы синхронизации. Отключение не очищает устройство для передачи другому человеку.',
'cloudSync.provider.disconnect.failed': 'Не удалось завершить отключение от {name}. Сохранённые данные подключения могут остаться. Повторите попытку.',
'cloudSync.provider.webdav': 'WebDAV',
'cloudSync.provider.webdav.desc': 'Подключение к самостоятельно размещённому WebDAV endpoint',
'cloudSync.provider.s3': 'Совместимое с S3',
'cloudSync.provider.s3.desc': 'Подключение к объектному хранилищу, совместимому с S3',
'cloudSync.provider.comingSoon': 'Скоро',
'cloudSync.webdav.title': 'Настройки WebDAV',
'cloudSync.webdav.desc': 'Настройка WebDAV endpoint для зашифрованной синхронизации.',
'cloudSync.webdav.endpoint': 'Конечная точка URL',
@@ -404,20 +397,6 @@ export const ruTerminalMessages: Messages = {
'cloudSync.s3.allowInsecure': 'Разрешить небезопасное соединение (игнорировать ошибки сертификата)',
'cloudSync.s3.showSecret': 'Показать секреты',
'cloudSync.s3.validation.required': 'Endpoint, регион, бакет, access key и secret обязательны.',
'cloudSync.smb.title': 'Настройки SMB',
'cloudSync.smb.desc': 'Подключение к файловой SMB/CIFS-шаре для зашифрованной синхронизации.',
'cloudSync.smb.share': 'Путь к шаре',
'cloudSync.smb.username': 'Имя пользователя',
'cloudSync.smb.password': 'Пароль',
'cloudSync.smb.domain': 'Домен (необязательно)',
'cloudSync.smb.domainPlaceholder': 'например, WORKGROUP',
'cloudSync.smb.port': 'Порт (необязательно)',
'cloudSync.smb.showSecret': 'Показать пароль',
'cloudSync.smb.validation.share': 'Путь к шаре обязателен.',
'cloudSync.smb.validation.port': 'Порт должен быть числом от 1 до 65535.',
'cloudSync.connect.smb.success': 'SMB успешно подключён',
'cloudSync.connect.smb.failedTitle': 'Ошибка подключения SMB',
'cloudSync.provider.smb': 'SMB-шара',
'cloudSync.connect.webdav.success': 'WebDAV успешно подключён',
'cloudSync.connect.webdav.failedTitle': 'Ошибка подключения WebDAV',
'cloudSync.connect.s3.success': 'S3 успешно подключён',
@@ -434,7 +413,6 @@ export const ruTerminalMessages: Messages = {
'cloudSync.lastSync.minutesAgo': '{minutes} мин назад',
'cloudSync.changeKey': 'Изменить ключ',
'cloudSync.providers.title': 'Облачные провайдеры',
'cloudSync.syncAll': 'Синхронизировать всех подключённых провайдеров',
'cloudSync.autoSync.title': 'Автосинхронизация',
'cloudSync.autoSync.desc': 'Автоматически синхронизировать при внесении изменений',
'cloudSync.strategy.title': 'Стратегия синхронизации',
@@ -499,7 +477,6 @@ export const ruTerminalMessages: Messages = {
'cloudSync.localBackups.folderWarning': 'Эта папка сама по себе не является полной переносимой резервной копией. Удаление или очистка профиля приложения (userData) может сделать эти точки восстановления нечитаемыми.',
'cloudSync.localBackups.retentionTitle': 'Хранение резервных копий',
'cloudSync.localBackups.retentionDesc': 'Выберите, сколько локальных резервных копий должен хранить Netcatty.',
'cloudSync.localBackups.maxCount': 'Макс. число копий',
'cloudSync.localBackups.maxSaved': 'Хранение резервных копий: {count}',
'cloudSync.localBackups.maxInvalid': 'Введите число от 1 до 100.',
'cloudSync.localBackups.empty': 'Локальных резервных копий пока нет.',
@@ -622,10 +599,7 @@ export const ruTerminalMessages: Messages = {
'cloudSync.clearLocal.toast.desc': 'Локальная версия сброшена до 0. Выполните синхронизацию для загрузки из облака.',
// Keychain
'keychain.filter.key': 'Ключ',
'keychain.filter.certificate': 'Сертификат',
'keychain.action.generateKey': 'Создать ключ',
'keychain.action.importKey': 'Импорт. ключ',
'keychain.action.newIdentity': 'Новый ид-катор',
'keychain.action.importCertificate': 'Импорт. сертификат',
'keychain.view.grid': 'Сетка',
@@ -666,20 +640,8 @@ export const ruTerminalMessages: Messages = {
'keychain.export.exporting': 'Экспорт...',
'keychain.export.exportAndAttach': 'Экспортировать и привязать',
'keychain.export.title': 'Экспорт ключа',
'keychain.export.exportToRequired': 'Экспортировать в *',
'keychain.export.selectHostPlaceholder': 'Выберите хост...',
'keychain.export.locationLabel': 'Расположение ~ $1 *',
'keychain.export.filenameLabel': 'Имя файла ~ $2 *',
'keychain.export.advanced': 'Дополнительно',
'keychain.export.note.supportsOnly': 'Экспорт ключей сейчас поддерживается только в',
'keychain.export.note.systems': 'системах.',
'keychain.export.note.use': 'Используйте',
'keychain.export.note.customize': 'раздел для настройки скрипта экспорта.',
'keychain.export.scriptRequired': 'Скрипт *',
'keychain.export.exportToHost': 'Экспортировать на хост',
'keychain.export.failedGeneric': 'Ошибка экспорта: {message}',
'keychain.field.label': 'Метка',
'keychain.field.labelRequired': 'Метка *',
'keychain.field.labelPlaceholder': 'Метка ключа',
'keychain.field.privateKeyRequired': 'Приватный ключ *',
'keychain.field.publicKey': 'Публичный ключ',
@@ -715,13 +677,9 @@ export const ruTerminalMessages: Messages = {
"fido.recovery.usePassword": "Использовать сохранённый пароль",
"fido.recovery.passwordFallback": "Вход с паролем, настроенным для этого хоста",
"fido.prompt.cancelled": "Проверка ключа безопасности отменена.",
'fido.prompt.touchDone': 'Я коснулся',
'fido.prompt.timeout': 'Время ожидания FIDO истекло. Попробуйте снова.',
'fido.error.opensshMissing': 'Нужен OpenSSH с FIDO/libfido2. macOS: brew install openssh libfido2.',
'fido.error.agentUnavailable': 'Не удалось запустить SSH agent с FIDO.',
'keychain.generate.resident': 'Хранить учётные данные на ключе',
'keychain.generate.verifyRequired': 'Проверять PIN каждый раз',
'keychain.action.loadResident': 'Загрузить resident-ключи с устройства',
'keychain.generate.keySize': 'Размер ключа',
'keychain.generate.labelPlaceholder': 'Метка ключа',
'keychain.generate.passphrasePlaceholder': 'Парольная фраза (необязательно)',
@@ -731,7 +689,6 @@ export const ruTerminalMessages: Messages = {
'keychain.import.dropHint': 'Перетащите сюда файл ключа',
'keychain.import.importFromFile': 'Импортировать из файла',
'keychain.import.saveKey': 'Сохранить ключ',
'keychain.import.importedKeyLabel': 'Импортированный ключ',
'keychain.identity.usernameRequired': 'Имя пользователя *',
'keychain.identity.method.passwordOnly': 'Пароль',
'keychain.identity.summary.password': 'Пароль аутентификации',
@@ -740,14 +697,8 @@ export const ruTerminalMessages: Messages = {
'keychain.identity.summary.passwordAndKey': 'Пароль и ключ аутентификации',
'keychain.identity.summary.passwordAndCertificate': 'Пароль и сертификат аутентификации',
'keychain.identity.summary.none': 'Нет учётных данных',
'keychain.identity.selectCredential': 'Выберите {kind}',
'keychain.identity.save': 'Сохранить',
'keychain.identity.update': 'Обновить',
'keychain.keyDialog.newTitle': 'Новый ключ',
'keychain.keyDialog.newDesc': 'Добавить новый SSH-ключ',
'keychain.keyDialog.editTitle': 'Редактировать ключ',
'keychain.keyDialog.editDesc': 'Обновить этот SSH-ключ',
'keychain.keyDialog.updateKey': 'Обновить ключ',
// Tabs
'tabs.closeSessionAria': 'Закрыть сессию',
@@ -759,6 +710,8 @@ export const ruTerminalMessages: Messages = {
'tabs.duplicateSession': 'Дублировать сессию',
'tabs.copyTabToNewWindow': 'Копировать вкладку в новое окно',
'tabs.copyTabToNewWindowFailed': 'Не удалось открыть вкладку в новом окне',
'tabs.moveTabToNewWindow': 'Переместить вкладку в новое окно',
'tabs.moveTabToNewWindowFailed': 'Не удалось переместить вкладку в новое окно',
'tabs.closeOthers': 'Закрыть остальные',
'tabs.closeToLeft': 'Закрыть вкладки слева',
'tabs.closeToRight': 'Закрыть вкладки справа',
@@ -859,9 +812,6 @@ export const ruTerminalMessages: Messages = {
'snippets.import.modal.multipleFiles': 'Выбрано файлов: {count}',
'snippets.import.modal.parsedSummary': '{files} файл(ов), {total} сниппет(ов), {packages} пакет(ов), повторяющихся команд: {conflicts}. Привязки к хостам игнорируются.',
'snippets.import.modal.confirm': 'Подтвердить импорт',
'snippets.import.conflict.title': 'Импортировать сниппеты?',
'snippets.import.conflict.desc': 'Файл «{file}» содержит {total} сниппет(ов), из них повторяющихся команд: {conflicts}.',
'snippets.import.conflict.hostBindingsNote': 'Привязки сниппетов к хостам не импортируются и не экспортируются.',
'snippets.import.conflict.skip': 'Пропустить повторы',
'snippets.import.conflict.overwrite': 'Перезаписать повторы',
'snippets.packageDialog.title': 'Новый пакет',
@@ -908,9 +858,6 @@ export const ruTerminalMessages: Messages = {
'serial.field.customPort': 'Путь к пользовательскому порту',
'serial.field.namedPipeHint': 'Консоль ВМ Windows: введите \\\\.\\pipe\\name. ВМ должна создать канал как сервер. Скорость и параметры кадра игнорируются.',
'serial.field.customPortPlaceholder': 'например, /dev/ttys001 или COM1',
'serial.type.hardware': 'Аппаратный',
'serial.type.pseudo': 'Псевдотерминал',
'serial.type.custom': 'Пользовательский',
'serial.parity.none': 'Нет',
'serial.parity.even': 'Чётная',
'serial.parity.odd': 'Нечётная',
@@ -931,7 +878,6 @@ export const ruTerminalMessages: Messages = {
'serial.backspace.default': 'По умолчанию (DEL, 0x7F)',
'serial.backspace.ctrlH': 'Ctrl+H (BS, 0x08)',
'serial.field.charset': 'Кодировка',
'serial.connectionError': 'Не удалось подключиться к последовательному порту',
'serial.field.baudRatePlaceholder': 'Выберите или введите скорость...',
'serial.field.baudRateEmpty': 'Введите пользовательскую скорость передачи',
'serial.field.customBaudRate': 'Используется пользовательская скорость передачи',
@@ -950,10 +896,7 @@ export const ruTerminalMessages: Messages = {
'keyboard.interactive.title': 'Требуется аутентификация',
'keyboard.interactive.desc': 'Сервер требует дополнительную аутентификацию.',
'keyboard.interactive.descWithHost': 'Сервер {hostname} требует дополнительную аутентификацию.',
'keyboard.interactive.response': 'Ответ',
'keyboard.interactive.verificationCode': 'Код подтверждения',
'keyboard.interactive.enterCode': 'Введите код подтверждения',
'keyboard.interactive.enterResponse': 'Введите ответ',
'keyboard.interactive.submit': 'Отправить',
'keyboard.interactive.verifying': 'Проверка...',
'keyboard.interactive.savePassword': 'Сохранить пароль',
+24 -109
View File
@@ -19,14 +19,6 @@ export const ruVaultMessages: Messages = {
'notes.export.toast.failed': 'Не удалось экспортировать заметки.',
'notes.codeBlock.copied': 'Скопировано',
'notes.codeBlock.copyFailed': 'Не удалось скопировать блок кода.',
'notes.group.prompt': 'Путь папки',
'notes.group.all': 'Блокнот',
'notes.group.ungrouped': 'Без группы',
'notes.section.notebooks': 'Блокнот',
'notes.section.notes': 'Заметки',
'notes.mode.edit': 'Правка',
'notes.mode.split': 'Разделить',
'notes.mode.preview': 'Просмотр',
'notes.title.placeholder': 'Заголовок заметки',
'notes.editor.placeholder': 'Пишите Markdown-заметки здесь...',
'notes.editor.unrenderableMarkdown': 'Эта заметка содержит Markdown, который не может отобразить визуальный редактор (например, незакрытые теги вида <tag>). Показан исходный Markdown — содержимое не потеряно.',
@@ -72,25 +64,18 @@ export const ruVaultMessages: Messages = {
'notes.toolbar.divider': 'Разделитель',
'notes.toolbar.link': 'Вставить ссылку',
'notes.toolbar.image': 'Вставить изображение',
'notes.action.pin': 'Закрепить заметку',
'notes.action.unpin': 'Открепить заметку',
'notes.tag.remove': 'Удалить тег',
'notes.tag.placeholder': 'Имя тега...',
'notes.tag.add': 'Добавить тег',
'notes.outline.title': 'Оглавление',
'notes.outline.titleWithCount': 'Оглавление ({count})',
'notes.outline.empty': 'Нет заголовков',
'notes.outline.emptyHint': 'Используйте # и ## в Markdown для создания заголовков',
'notes.export.share': 'Экспорт и общий доступ',
'notes.export.currentNote': 'Текущая заметка',
'notes.export.exportMarkdown': 'Экспорт в Markdown (.md)',
'notes.export.exportHtml': 'Экспорт в HTML (.html)',
'notes.export.copyMarkdown': 'Копировать исходный Markdown',
'notes.export.allNotes': 'Все заметки',
'notes.export.exportAllZip': 'Экспортировать все в ZIP-архив',
'notes.export.toast.markdownSuccess': 'Markdown-файл экспортирован',
'notes.export.toast.htmlSuccess': 'HTML-файл экспортирован',
'notes.export.toast.zipSuccess': 'Все заметки экспортированы в архив ZIP',
// Vault hosts header/actions
'vault.hosts.search.placeholder': 'Найти хост или ssh user@hostname / ssh -p 2222 user@hostname...',
@@ -305,7 +290,6 @@ export const ruVaultMessages: Messages = {
'pf.tooltip.localDesc': 'Локальный проброс портов: доступ к удалённым сервисам через SSH-туннель',
'pf.tooltip.remoteDesc': 'Удалённый проброс портов: публикация локальных сервисов на удалённом хосте',
'pf.tooltip.dynamicDesc': 'Динамический SOCKS-прокси: маршрутизация трафика через SSH-туннель',
'pf.deleteActive.title': 'Удалить активное правило проброса портов?',
'pf.deleteActive.desc': 'Правило проброса портов "{label}" сейчас активно. При удалении туннель будет сначала остановлен.',
'pf.deleteActive.confirm': 'Остановить и удалить',
'pf.form.autoStart': 'Автозапуск',
@@ -339,13 +323,9 @@ export const ruVaultMessages: Messages = {
'sftp.columns.actions': 'Действия',
'sftp.sort.directoriesFirst': 'Папки сверху',
'sftp.emptyDirectory': 'Пустой каталог',
'sftp.nav.up': 'Наверх',
'sftp.nav.home': 'Перейти в домашний каталог',
'sftp.nav.refresh': 'Обновить',
'sftp.upload': 'Загрузить',
'sftp.uploadFiles': 'Загрузить файлы',
'sftp.uploadFolder': 'Загрузить папку',
'sftp.dragDropToUpload': 'Перетащите сюда файлы для загрузки',
'sftp.retry': 'Повторить',
'sftp.context.open': 'Открыть',
'sftp.context.navigateTo': 'Перейти к',
@@ -360,6 +340,12 @@ export const ruVaultMessages: Messages = {
'sftp.extract.extracting': 'Распаковка {fileName}...',
'sftp.extract.success': 'Распакован {fileName}',
'sftp.extract.error': 'Не удалось распаковать {fileName}: {error}',
'sftp.packedDownload.receiving': 'Получение архива…',
'sftp.packedDownload.extracting': 'Распаковка файлов…',
'sftp.packedDownload.fallback': 'Упаковка недоступна. Файлы будут скачаны по отдельности.',
'sftp.packedDownload.selection': 'Выбрано элементов: {count}',
'sftp.packedDownload.conflict': 'Элемент с таким именем уже существует. Выбрать другую папку назначения?',
'sftp.archive.action': 'Сжать...',
'sftp.archive.title': 'Сжать файлы',
'sftp.archive.description': 'Создать архив на сервере из выбранных объектов: {count}.',
@@ -384,28 +370,21 @@ export const ruVaultMessages: Messages = {
'sftp.copyCurrentPath': 'Копировать текущий путь',
'sftp.copyCurrentPath.success': 'Текущий путь скопирован',
'sftp.copyCurrentPath.error': 'Не удалось скопировать текущий путь',
'sftp.viewMode.label': 'Режим просмотра',
'sftp.viewMode.list': 'Список',
'sftp.viewMode.tree': 'Дерево',
'sftp.viewMode.switchToList': 'Переключиться на список',
'sftp.viewMode.switchToTree': 'Переключиться на дерево',
'sftp.listDensity.compact': 'Компактный список',
'sftp.listDensity.comfortable': 'Обычный список',
'sftp.listDensity.switchToCompact': 'Переключиться на компактный список',
'sftp.listDensity.switchToComfortable': 'Переключиться на обычный список',
'sftp.tree.loadError': 'Не удалось загрузить каталог',
'sftp.tree.loading': 'Загрузка...',
'sftp.kind.folder': 'Папка',
'sftp.context.rename': 'Переименовать',
'sftp.context.permissions': 'Права доступа',
'sftp.context.delete': 'Удалить',
'sftp.context.refresh': 'Обновить',
'sftp.context.uploadFiles': 'Загрузить файл(ы)...',
'sftp.context.uploadFilesHere': 'Загрузить файлы сюда...',
'sftp.context.uploadFolder': 'Загрузить папку...',
'sftp.context.uploadFolderHere': 'Загрузить папку сюда...',
'sftp.context.downloadSelected': 'Скачать выбранное ({count})',
'sftp.context.deleteSelected': 'Удалить выбранное ({count})',
'sftp.dropFilesHere': 'Перетащите сюда файлы',
'sftp.itemsCount': '{count} записей',
'sftp.selectedCount': '{count} выбрано',
@@ -414,8 +393,6 @@ export const ruVaultMessages: Messages = {
'sftp.task.waiting': 'Ожидание...',
'sftp.transfer.preparing': 'подготовка...',
'sftp.status.loading': 'Загрузка...',
'sftp.status.uploading': 'Загрузка...',
'sftp.status.ready': 'Готово',
'sftp.transfers': 'Передачи',
'sftp.transfers.active': '{count} активн(ый/ых)',
'sftp.transfers.clearCompleted': 'Очистить завершённые',
@@ -478,7 +455,6 @@ export const ruVaultMessages: Messages = {
'sftp.transferCenter.applyAll': 'Применить ко всем',
'sftp.transfers.resizeNameColumn': 'Изменить ширину столбца имени файла',
'sftp.transfers.dragToResize': 'Перетащите для изменения размера',
'sftp.goUp': 'Наверх',
'sftp.goToTerminalCwd': 'Перейти в каталог терминала',
'sftp.locatePathInTerminal': 'Открыть путь в терминале',
'sftp.followTerminalCwd': 'Следовать за каталогом терминала',
@@ -488,35 +464,30 @@ export const ruVaultMessages: Messages = {
'sftp.encoding.auto': 'Авто',
'sftp.encoding.utf8': 'UTF-8',
'sftp.encoding.gb18030': 'GB18030',
'sftp.goBack': 'Назад',
'sftp.goForward': 'Вперёд',
'sftp.goHome': 'Перейти в домашний каталог',
'sftp.goRoot': 'Перейти в корень',
'sftp.folderName': 'Имя папки',
'sftp.folderName.placeholder': 'Введите имя папки',
'sftp.fileName': 'Имя файла',
'sftp.fileName.placeholder': 'Введите имя файла',
'sftp.prompt.newFolderName': 'Имя новой папки?',
'sftp.rename.title': 'Переименовать',
'sftp.rename.newName': 'Новое имя',
'sftp.rename.placeholder': 'Введите новое имя',
'sftp.confirm.deleteOne': 'Удалить "{name}"?',
'sftp.deleteConfirm.single': 'Удалить "{name}"?',
'sftp.deleteConfirm.title': 'Удалить {count} элемент(ов)?',
'sftp.deleteConfirm.desc': 'Это действие нельзя отменить. Будет удалено следующее:',
'sftp.deleteConfirm.descSingle': 'Это действие нельзя отменить.',
'sftp.deleteConfirm.host': 'Хост',
'sftp.deleteConfirm.path': 'Путь',
'sftp.error.loadFailed': 'Не удалось загрузить каталог',
'sftp.error.downloadFailed': 'Ошибка скачивания',
'sftp.error.uploadFailed': 'Ошибка загрузки',
'sftp.error.deleteFailed': 'Ошибка удаления',
'sftp.error.createFolderFailed': 'Не удалось создать папку',
'sftp.error.createFileFailed': 'Не удалось создать файл',
'sftp.error.invalidFileName': 'Имя файла содержит недопустимые символы: {chars}',
'sftp.error.reservedName': 'Это имя файла зарезервировано системой',
'sftp.overwrite.title': 'Файл уже существует',
'sftp.overwrite.desc': 'Файл с именем "{name}" уже существует. Хотите заменить его?',
'sftp.overwrite.confirm': 'Заменить',
'sftp.error.renameFailed': 'Не удалось переименовать',
'sftp.picker.title': 'Выберите хост',
'sftp.picker.desc': 'Выберите хост для панели {side}',
'sftp.picker.searchPlaceholder': 'Поиск хостов...',
@@ -524,8 +495,6 @@ export const ruVaultMessages: Messages = {
'sftp.picker.local.desc': 'Просмотр локальных файлов',
'sftp.picker.local.badge': 'Локально',
'sftp.picker.connected.section': 'Подключённые',
'sftp.picker.connected.badge': 'Онлайн',
'sftp.picker.connected.connecting': 'Подключение',
'sftp.picker.noMatch': 'Подходящие хосты не найдены',
'sftp.permissions.title': 'Изменить права доступа',
'sftp.permissions.owner': 'Владелец',
@@ -533,16 +502,12 @@ export const ruVaultMessages: Messages = {
'sftp.permissions.others': 'Остальные',
'sftp.permissions.octal': 'Восьмеричный',
'sftp.permissions.symbolic': 'Символьный',
'sftp.permissions.success': 'Права доступа успешно обновлены',
'sftp.permissions.failed': 'Не удалось обновить права доступа',
'sftp.pane.local': 'Локально',
'sftp.pane.remote': 'Удалённо',
'sftp.pane.selectHost': 'Выберите хост',
'sftp.pane.selectHostToStart': 'Выберите хост для начала',
'sftp.pane.chooseFilesystem': 'Выберите локальную или удалённую файловую систему для просмотра',
'sftp.tabs.addTab': 'Добавить новую вкладку',
'sftp.tabs.closeTab': 'Закрыть вкладку',
'sftp.tabs.newTab': 'Новая вкладка',
'sftp.tabs.copyDefaultPath': 'Копировать вкладку (путь по умолчанию)',
'sftp.tabs.copyCurrentPath': 'Копировать и перейти к текущему пути',
'sftp.conflict.title': 'Конфликт файлов',
@@ -568,47 +533,27 @@ export const ruVaultMessages: Messages = {
'sftp.conflict.action.replace': 'Заменить',
// SFTP Upload Phases
'sftp.upload.phase.compressing': 'Сжатие',
'sftp.upload.phase.uploading': 'Загрузка',
'sftp.upload.phase.extracting': 'Распаковка',
'sftp.upload.phase.compressed': 'Сжато',
// SFTP File Opener
'sftp.context.copyPath': 'Копировать путь к файлу',
'sftp.context.insertPathToTerminal': 'Вставить путь в терминал',
'sftp.context.cdInTerminal': 'Открыть в терминале (cd)',
'sftp.terminal.insertBlockedUnsafeQuote': 'Невозможно вставить путь, пока курсор терминала находится внутри незакрытых кавычек или экранирования',
'sftp.context.openWithDefault': 'Открыть в системном приложении',
'sftp.context.openWith': 'Открыть с помощью...',
'sftp.context.edit': 'Редактировать',
'sftp.context.preview': 'Предпросмотр',
'sftp.opener.title': 'Открыть с помощью',
'sftp.opener.desc': 'Выберите приложение для открытия этого файла',
'sftp.opener.builtInEditor': 'Встроенный редактор',
'sftp.opener.editDescription': 'Редактировать текстовые файлы',
'sftp.opener.builtInImageViewer': 'Встроенный просмотрщик изображений',
'sftp.opener.previewDescription': 'Просмотр изображений',
'sftp.opener.systemApp': 'Выбрать приложение...',
'sftp.opener.systemAppDescription': 'Выберите приложение на вашем компьютере',
'sftp.opener.onlySystemApp': 'Этот файл можно открыть только во внешнем приложении',
'sftp.opener.noAppsAvailable': 'Нет доступных приложений',
'sftp.opener.noExtension': 'файлы без расширения',
'sftp.opener.setDefault': 'Всегда использовать это для файлов {ext}',
'sftp.opener.confirmTitle': 'Установить по умолчанию?',
'sftp.opener.confirmDescription': 'Хотите всегда использовать {app} для файлов {ext}?',
'sftp.opener.yesRemember': 'Да, запомнить выбор',
'sftp.opener.justOnce': 'Только один раз',
'sftp.opener.confirm.title': 'Установить приложение по умолчанию',
'sftp.opener.confirm.desc': 'Хотите всегда открывать файлы .{ext} этим приложением?',
'sftp.editor.title': 'Текстовый редактор',
'sftp.editor.save': 'Сохранить на удалённый сервер',
'sftp.editor.saving': 'Сохранение...',
'sftp.editor.saved': 'Успешно сохранено',
'sftp.editor.saveFailed': 'Не удалось сохранить файл',
'sftp.editor.unsavedChanges': 'У вас есть несохранённые изменения. Всё равно закрыть?',
'sftp.editor.syntaxHighlight': 'Подсветка синтаксиса',
'sftp.preview.title': 'Просмотр изображения',
'sftp.preview.zoomIn': 'Увеличить',
'sftp.preview.zoomOut': 'Уменьшить',
'sftp.preview.resetZoom': 'Сбросить масштаб',
'sftp.preview.fitToWindow': 'Подогнать по окну',
// Settings > SFTP File Associations
'settings.tab.sftpFileAssociations': 'SFTP',
@@ -687,28 +632,16 @@ export const ruVaultMessages: Messages = {
'sftp.autoSync.error': 'Не удалось синхронизировать файл: {error}',
// SFTP Folder Upload Progress
'sftp.upload.progress': 'Загрузка файлов {current} из {total}...',
'sftp.upload.uploading': 'Загрузка...',
'sftp.upload.compressing': 'Сжатие...',
'sftp.upload.extracting': 'Распаковка...',
'sftp.upload.scanning': 'Сканирование файлов...',
'sftp.upload.completed': 'Завершено',
'sftp.upload.compressed': 'Сжатая передача',
'sftp.upload.currentFile': 'Текущий: {fileName}',
'sftp.upload.cancelled': 'Загрузка отменена',
'sftp.upload.noFiles': 'Нет файлов для загрузки',
'sftp.upload.partialSuccess': 'Загружено: {success}; ошибок: {failed}',
'sftp.upload.cancel': 'Отмена',
'sftp.upload.completedToPath': 'Загружено в {path}',
// SFTP Download
'sftp.download.completed': 'Скачано',
'sftp.download.cancelled': 'Скачивание отменено',
// SFTP Reconnecting
'sftp.reconnecting.title': 'Переподключение...',
'sftp.reconnecting.desc': 'Соединение потеряно, выполняется попытка переподключения',
'sftp.reconnected': 'Соединение восстановлено',
'sftp.error.reconnectFailed': 'Не удалось переподключиться. Попробуйте ещё раз.',
'sftp.error.connectionLostManual': 'Соединение потеряно. Пожалуйста, переподключитесь вручную.',
'sftp.error.connectionLostReconnecting': 'Соединение потеряно. Переподключение...',
@@ -726,6 +659,17 @@ export const ruVaultMessages: Messages = {
'settings.sftp.compressedUpload.enable': 'Включить сжатие папок',
'settings.sftp.compressedUpload.enableDesc': 'Автоматически сжимать папки с помощью tar перед передачей. Требует поддержки tar на сервере. Если она недоступна, будет использована обычная передача.',
'settings.sftp.packedDownload': 'Скачивание архивом',
'settings.sftp.packedDownload.enable': 'Упаковывать папки и выбранные вместе файлы перед скачиванием',
'settings.sftp.packedDownload.enableDesc': 'Выбранные файлы передаются одним потоком и распаковываются с сохранением структуры папок. Если сервер не поддерживает упаковку, файлы скачиваются по отдельности.',
'settings.sftp.downloadLocation': 'Папка для загрузок',
'settings.sftp.downloadLocation.directory': 'Папка загрузок по умолчанию',
'settings.sftp.downloadLocation.directoryDesc': 'Диалоги скачивания по SFTP открываются в этой папке. Если она не задана или больше не существует, используется системная папка «Загрузки».',
'settings.sftp.downloadLocation.systemDefault': 'Системная папка «Загрузки»',
'settings.sftp.downloadLocation.browse': 'Обзор…',
'settings.sftp.downloadLocation.reset': 'Использовать системную папку «Загрузки»',
'settings.sftp.downloadLocation.select': 'Выберите папку загрузок по умолчанию',
'settings.sftp.skipUnchanged.enable': 'Пропускать неизменённые файлы',
'settings.sftp.skipUnchanged.enableDesc': 'Пропускать файлы, у которых размер и время изменения уже совпадают с назначением (в стиле rsync). Отключается при замене папки во временный путь.',
@@ -783,12 +727,6 @@ export const ruVaultMessages: Messages = {
'vault.panel.resizeWidth': 'Изменить ширину панели',
'hostDetails.saveAria': 'Сохранить',
'hostConnectionTest.title': 'Проверка подключения',
'hostConnectionTest.test': 'Проверить',
'hostConnectionTest.chainOf': 'Цепочка {current} из {total}',
'hostConnectionTest.success': 'Подключение успешно',
'hostConnectionTest.successHint': 'Хост принял ваши учётные данные. Можно закрыть окно.',
'hostConnectionTest.connecting': 'Подключение… таймаут через {seconds} с',
'hostConnectionTest.failed': 'Не удалось подключиться.',
'hostConnectionTest.retry': 'Повторить',
'hostConnectionTest.credentialsUnavailable': 'Сохранённые учётные данные не удаётся расшифровать на этом устройстве. Введите их заново ниже.',
'hostDetails.section.address': 'Адрес',
@@ -825,11 +763,8 @@ export const ruVaultMessages: Messages = {
'hostDetails.notes.toggle.show': 'Показать редактор заметок',
'hostDetails.notes.toggle.hide': 'Скрыть редактор заметок',
'hostDetails.group.placeholder': 'Родительская группа',
'hostDetails.section.credentials': 'Учётные данные',
'hostDetails.section.portCredentials': 'Порт и учётные данные',
'hostDetails.section.appearance': 'Внешний вид',
'hostDetails.distro.title': 'Дистрибутив Linux',
'hostDetails.distro.desc': 'Автоопределение при подключении или ручная замена значка дистрибутива.',
'hostDetails.icon.title': 'Значок хоста',
'hostDetails.icon.sectionTitle': 'Цвет и значок',
'hostDetails.icon.desc': 'Выберите источник значка и цвет для этого хоста.',
@@ -841,7 +776,6 @@ export const ruVaultMessages: Messages = {
'hostDetails.icon.mode.custom': 'Свой',
'hostDetails.icon.reset': 'Сбросить значок',
'hostDetails.icon.colorLabel': 'Цвет значка',
'hostDetails.icon.colorDefault': 'По умолчанию',
'hostDetails.icon.colorAuto': 'Авто',
'hostDetails.icon.colorManual': 'Вручную',
'hostDetails.icon.colorChoice': 'Цвет',
@@ -892,7 +826,6 @@ export const ruVaultMessages: Messages = {
'hostDetails.distro.mode.auto': 'Автоопределение',
'hostDetails.distro.mode.manual': 'Ручное переопределение',
'hostDetails.distro.detectedLabel': 'Текущий',
'hostDetails.distro.manualLabel': 'Переопределить',
'hostDetails.distro.pending': 'Определится после первого подключения',
'hostDetails.distro.unknown': 'Неизвестно',
'hostDetails.distro.option.linux': 'Обычный Linux',
@@ -940,7 +873,6 @@ export const ruVaultMessages: Messages = {
'hostDetails.auth.mfaFirst': 'Сначала интерактивная аутентификация',
'hostDetails.auth.mfaFirst.desc': 'Для серверов, которым нужны пароль и MFA через keyboard-interactive.',
'hostDetails.totp.title': 'Аутентификатор (TOTP)',
'hostDetails.totp.enable': 'Сохранить секрет TOTP для этого хоста',
'hostDetails.totp.setup': 'Настроить…',
'hostDetails.totp.edit': 'Изменить',
'hostDetails.totp.modalTitle': 'Настройка аутентификатора',
@@ -1043,10 +975,8 @@ export const ruVaultMessages: Messages = {
'hostDetails.jumpHosts.direct': 'Напрямую',
'hostDetails.jumpHosts.configure': 'Настроить прокси-хосты',
'hostDetails.proxy': 'Прокси через HTTP/SOCKS5/Command',
'hostDetails.proxy.none': 'Нет',
'hostDetails.proxy.direct': 'Напрямую (без прокси)',
'hostDetails.proxy.directHint': 'Не использует прокси группы или глобальный прокси по умолчанию',
'hostDetails.proxy.edit': 'Редактировать прокси',
'hostDetails.proxy.configure': 'Настроить прокси',
'hostDetails.proxyPanel.title': 'Прокси через HTTP/SOCKS5/Command',
'hostDetails.proxyPanel.hostPlaceholder': 'Прокси-хост',
@@ -1056,7 +986,6 @@ export const ruVaultMessages: Messages = {
'hostDetails.proxyPanel.credentials': 'Учётные данные',
'hostDetails.proxyPanel.usernamePlaceholder': 'Имя пользователя',
'hostDetails.proxyPanel.passwordPlaceholder': 'Пароль',
'hostDetails.proxyPanel.identities': 'Идентификаторы',
'hostDetails.proxyPanel.keychainIdentity': 'Идентификатор из связки ключей',
'hostDetails.proxyPanel.manualCredentials': 'Ввести вручную',
'hostDetails.proxyPanel.remove': 'Удалить прокси',
@@ -1079,8 +1008,6 @@ export const ruVaultMessages: Messages = {
'hostDetails.envVars.newVariable': 'Новая переменная',
'hostDetails.envVars.variableName': 'Имя переменной',
'hostDetails.chain.title': 'Редактировать цепочку',
'hostDetails.chain.desc': 'Добавление ещё одного хоста создаст подключение к {host}.',
'hostDetails.chain.addHost': 'Добавить хост',
'hostDetails.chain.target': 'Цель',
'hostDetails.chain.availableHosts': 'Доступные хосты',
'hostDetails.chain.clear': 'Очистить',
@@ -1127,6 +1054,8 @@ export const ruVaultMessages: Messages = {
'localShell.field.shellResolved': 'Запускает {command}',
'localShell.field.startDir': 'Начальный каталог',
'localShell.field.startDirPlaceholder': 'Использовать общий начальный каталог (иначе домашний)',
'localShell.field.startupCommandPlaceholder': 'Команда после запуска оболочки (например, npm run dev)',
'localShell.field.startupCommandDesc': 'Выполняется автоматически после запуска локальной оболочки в указанном каталоге.',
'localShell.saveAndConnect': 'Сохранить и открыть',
'hostDetails.plugin.title': 'Подключение плагина',
@@ -1146,28 +1075,14 @@ export const ruVaultMessages: Messages = {
'hostDetails.plugin.useSsh': 'Использовать SSH',
// Host form (legacy modal)
'hostForm.title.edit': 'Редактировать хост',
'hostForm.title.new': 'Новый хост',
'hostForm.desc.edit': 'Обновите параметры подключения для этого хоста',
'hostForm.desc.new': 'Создайте новую запись SSH-хоста',
'hostForm.field.label': 'Метка',
'hostForm.placeholder.label': 'Мой production-сервер',
'hostForm.field.hostname': 'Имя хоста / IP',
'hostForm.placeholder.hostname': '192.168.1.1',
'hostForm.field.port': 'Порт',
'hostForm.field.username': 'Имя пользователя',
'hostForm.field.osType': 'Тип ОС',
'hostForm.placeholder.selectOs': 'Выберите ОС',
'hostForm.field.group': 'Группа',
'hostForm.placeholder.group': 'например, AWS, DigitalOcean',
'hostForm.field.tags': 'Теги',
'hostForm.placeholder.addTag': 'Добавить тег...',
'hostForm.auth.method': 'Метод аутентификации',
'hostForm.auth.password': 'Пароль',
'hostForm.auth.sshKey': 'SSH-ключ',
'hostForm.auth.selectKey': 'Выберите SSH-ключ',
'hostForm.auth.noKeys': 'Нет доступных ключей',
'hostForm.auth.noKeysHint': 'В связке ключей не найдено SSH-ключей. Сначала создайте один.',
'hostForm.saveHost': 'Сохранить хост',
'vault.import.plugins.title': 'Импортёры плагинов',
'vault.import.plugins.loading': 'Создание безопасного предварительного просмотра…',
@@ -1,23 +0,0 @@
import test from "node:test";
import assert from "node:assert/strict";
import { enTerminalMessages } from "./en/terminal";
import { esTerminalMessages } from "./es/terminal";
import { ruTerminalMessages } from "./ru/terminal";
import { zhCNVaultMessages } from "./zh-CN/vault";
import { zhTWVaultMessages } from "./zh-TW/vault";
test("per-GPU stats strings exist in every locale", () => {
const labels = [
[enTerminalMessages, "GPU Device Usage", "GPU {{index}}"],
[esTerminalMessages, "Uso de cada GPU", "GPU {{index}}"],
[ruTerminalMessages, "Использование видеокарт", "GPU {{index}}"],
[zhCNVaultMessages, "GPU 设备使用率", "GPU {{index}}"],
[zhTWVaultMessages, "GPU 裝置使用率", "GPU {{index}}"],
] as const;
for (const [messages, devices, indexLabel] of labels) {
assert.equal(messages["terminal.serverStats.gpuDevices"], devices);
assert.equal(messages["terminal.serverStats.gpuIndex"], indexLabel);
}
});
@@ -1,28 +0,0 @@
import test from "node:test";
import assert from "node:assert/strict";
import { enSystemManagerMessages } from "./en/systemManager";
import { enTerminalMessages } from "./en/terminal";
import { ruSystemManagerMessages } from "./ru/systemManager";
import { ruTerminalMessages } from "./ru/terminal";
import { esSystemManagerMessages } from "./es/systemManager";
import { esTerminalMessages } from "./es/terminal";
import { zhCnSystemManagerMessages } from "./zh-CN/systemManager";
import { zhCNVaultMessages } from "./zh-CN/vault";
import { zhTwSystemManagerMessages } from "./zh-TW/systemManager";
import { zhTWVaultMessages } from "./zh-TW/vault";
test("SSH network latency is explicit in every locale and UI surface", () => {
const labels = [
[enTerminalMessages, enSystemManagerMessages, "SSH network latency"],
[ruTerminalMessages, ruSystemManagerMessages, "Сетевая задержка SSH"],
[esTerminalMessages, esSystemManagerMessages, "Latencia de red SSH"],
[zhCNVaultMessages, zhCnSystemManagerMessages, "SSH 网络延迟"],
[zhTWVaultMessages, zhTwSystemManagerMessages, "SSH 網路延遲"],
] as const;
for (const [terminalMessages, systemManagerMessages, expected] of labels) {
assert.equal(terminalMessages["terminal.serverStats.latency"], expected);
assert.equal(systemManagerMessages["systemManager.overview.latency"], expected);
}
});
@@ -1,13 +0,0 @@
import assert from "node:assert/strict";
import test from "node:test";
import en from "./en";
import es from "./es";
import ru from "./ru";
import zhCN from "./zh-CN";
import zhTW from "./zh-TW";
test("folder cleanup-warning counts are localized in every supported locale", () => {
for (const [locale, messages] of Object.entries({ en, es, ru, zhCN, zhTW })) {
assert.match(messages["sftp.transfers.cleanupWarnings"] ?? "", /\{count\}/, locale);
}
});
@@ -1,35 +0,0 @@
import test from 'node:test';
import assert from 'node:assert/strict';
import { enVaultMessages } from './en/vault.ts';
import { esVaultMessages } from './es/vault.ts';
import { ruVaultMessages } from './ru/vault.ts';
import { zhCNVaultMessages } from './zh-CN/vault.ts';
import { zhTWVaultMessages } from './zh-TW/vault.ts';
const FOLDER_CONFLICT_KEYS = [
'sftp.conflict.folderTitle',
'sftp.conflict.folderDesc',
'sftp.conflict.folderFileDesc',
'sftp.conflict.folderSymlinkDesc',
'sftp.conflict.folderUnknownDesc',
'sftp.conflict.folderMergeHint',
'sftp.conflict.folderReplaceWarning',
] as const;
test('folder conflict safety copy exists in every supported locale', () => {
const locales = {
en: enVaultMessages,
es: esVaultMessages,
ru: ruVaultMessages,
'zh-CN': zhCNVaultMessages,
'zh-TW': zhTWVaultMessages,
};
for (const [locale, messages] of Object.entries(locales)) {
for (const key of FOLDER_CONFLICT_KEYS) {
assert.equal(typeof messages[key], 'string', `${locale} is missing ${key}`);
assert.notEqual(messages[key]?.trim(), '', `${locale} has an empty ${key}`);
}
}
});
@@ -1,44 +0,0 @@
import assert from 'node:assert/strict';
import test from 'node:test';
import en from './en.ts';
import ru from './ru.ts';
import es from './es.ts';
import zhCN from './zh-CN.ts';
import zhTW from './zh-TW.ts';
const KEYS = [
'snippets.selection.deleteSelected',
'snippets.selection.deleteConfirmTitle',
'snippets.selection.deleteConfirmDesc',
'snippets.selection.deleteSuccess',
] as const;
test('snippet bulk-delete copy exists in every locale', () => {
for (const [locale, messages] of Object.entries({ en, ru, es, zhCN, zhTW })) {
const missing = KEYS.filter((key) => !messages[key]);
assert.deepEqual(missing, [], `${locale} is missing snippet bulk-delete copy`);
}
});
test('snippet shortkey system-conflict copy names the conflicting action', () => {
for (const [locale, messages] of Object.entries({ en, ru, es, zhCN, zhTW })) {
const text = messages['snippets.shortkey.error.systemConflict'];
assert.match(
text ?? '',
/\{name\}/,
`${locale} system-conflict copy should include {name}`,
);
}
});
test('English bulk-delete copy is entity-neutral and grammatical for one item', () => {
assert.equal(
en['snippets.selection.deleteConfirmTitle'].replace('{count}', '1'),
'Delete selected items (1)?',
);
assert.equal(
en['snippets.selection.deleteSuccess'].replace('{count}', '1'),
'Deleted selected items: 1.',
);
});
@@ -1,24 +0,0 @@
import assert from 'node:assert/strict';
import test from 'node:test';
import en from './en';
import ru from './ru';
import es from './es';
import zhCN from './zh-CN';
import zhTW from './zh-TW';
const keys = [
'terminal.layer.hostTree.newHost',
'terminal.layer.hostTree.newHostInGroup',
'terminal.layer.hostTree.editHost',
'terminal.layer.hostTree.hostSavedNextConnection',
] as const;
test('terminal host management strings exist in every shipped locale', () => {
for (const [locale, messages] of Object.entries({ en, es, 'zh-CN': zhCN, 'zh-TW': zhTW, ru })) {
for (const key of keys) {
assert.equal(typeof messages[key], 'string', `${locale} is missing ${key}`);
assert.notEqual(messages[key], '', `${locale} has an empty ${key}`);
}
}
});
@@ -1,57 +0,0 @@
import assert from "node:assert/strict";
import test from "node:test";
import en from "./en.ts";
import ru from "./ru.ts";
import es from "./es.ts";
import zhCN from "./zh-CN.ts";
import zhTW from "./zh-TW.ts";
const INLINE_IMAGE_KEYS = [
"settings.terminal.section.inlineImages",
"settings.terminal.inlineImages.enabled",
"settings.terminal.inlineImages.enabled.desc",
"settings.terminal.inlineImages.kitty",
"settings.terminal.inlineImages.kitty.desc",
"settings.terminal.inlineImages.sixel",
"settings.terminal.inlineImages.sixel.desc",
"settings.terminal.inlineImages.iip",
"settings.terminal.inlineImages.iip.desc",
"settings.terminal.inlineImages.storageLimit",
"settings.terminal.inlineImages.storageLimit.desc",
"settings.terminal.inlineImages.maxMegapixels",
"settings.terminal.inlineImages.maxMegapixels.desc",
"settings.terminal.inlineImages.sequenceLimit",
"settings.terminal.inlineImages.sequenceLimit.desc",
"settings.terminal.inlineImages.unit.mb",
"settings.terminal.inlineImages.unit.megapixels",
"settings.terminal.inlineImages.hibernateNote",
];
const LOCALES = [
{ name: "en", messages: en },
{ name: "es", messages: es },
{ name: "zh-CN", messages: zhCN },
{ name: "zh-TW", messages: zhTW },
{ name: "ru", messages: ru },
];
test("every locale ships the inline image settings strings", () => {
for (const locale of LOCALES) {
const missing = INLINE_IMAGE_KEYS.filter((key) => !locale.messages[key]);
assert.deepEqual(missing, [], `${locale.name} is missing inline image settings labels`);
}
});
test("inline image strings are actually translated, not copied from English", () => {
const translatedKeys = INLINE_IMAGE_KEYS.filter(
(key) => !key.startsWith("settings.terminal.inlineImages.unit.")
&& key !== "settings.terminal.inlineImages.sixel",
);
for (const locale of LOCALES) {
if (locale.name === "en") continue;
const untranslated = translatedKeys.filter((key) => locale.messages[key] === en[key]);
assert.deepEqual(untranslated, [], `${locale.name} still uses the English string`);
}
});
@@ -1,29 +0,0 @@
import test from "node:test";
import assert from "node:assert/strict";
import en from "./en.ts";
import ru from "./ru.ts";
import es from "./es.ts";
import zhCN from "./zh-CN.ts";
const osc7Keys = [
"terminal.toolbar.configureOsc7",
"terminal.osc7Setup.title",
"terminal.osc7Setup.desc",
"terminal.osc7Setup.targets",
"terminal.osc7Setup.command",
"terminal.osc7Setup.run",
"terminal.osc7Setup.running",
"terminal.osc7Setup.configured",
"terminal.osc7Setup.failed",
"terminal.osc7Setup.sent",
] as const;
test("OSC 7 setup copy exists in every bundled locale", () => {
for (const [locale, messages] of Object.entries({ en, ru, es, zhCN })) {
for (const key of osc7Keys) {
assert.equal(typeof messages[key], "string", `${locale} is missing ${key}`);
assert.notEqual(messages[key], "", `${locale} has empty ${key}`);
}
}
});
@@ -1,31 +0,0 @@
import test from "node:test";
import assert from "node:assert/strict";
import { enTerminalMessages } from "./en/terminal";
import { esTerminalMessages } from "./es/terminal";
import { ruTerminalMessages } from "./ru/terminal";
import { zhCNTerminalMessages } from "./zh-CN/terminal";
import { zhTWTerminalMessages } from "./zh-TW/terminal";
test("terminal reconnect notices are localized in every bundled language", () => {
const messages = [
enTerminalMessages,
esTerminalMessages,
ruTerminalMessages,
zhCNTerminalMessages,
zhTWTerminalMessages,
];
const keys = [
"terminal.progress.enterReconnectHint",
"terminal.progress.reconnecting",
"terminal.progress.autoReconnectScheduled",
"terminal.progress.autoReconnectAttempt",
];
for (const locale of messages) {
for (const key of keys) {
assert.equal(typeof locale[key], "string", `missing ${key}`);
assert.notEqual(locale[key]?.trim(), "", `empty ${key}`);
}
}
});
@@ -1,32 +0,0 @@
import assert from 'node:assert/strict';
import test from 'node:test';
import en from './en';
import es from './es';
import ru from './ru';
import zhCN from './zh-CN';
import zhTW from './zh-TW';
const keys = [
'terminal.toolbar.openSessionLog',
'terminal.toolbar.sessionLogActions',
'terminal.toolbar.sessionLog.menu',
'terminal.toolbar.sessionLog.open',
'terminal.toolbar.sessionLog.reveal',
'terminal.toolbar.sessionLog.chooseApplication',
'terminal.toolbar.sessionLog.systemDefault',
'terminal.toolbar.openSessionLogFailed',
] as const;
test('saved session log actions are translated in every shipped locale', () => {
for (const [locale, messages] of Object.entries({ en, es, ru, 'zh-CN': zhCN, 'zh-TW': zhTW })) {
for (const key of keys) assert.ok(messages[key], `${locale} is missing ${key}`);
assert.equal(messages['terminal.toolbar.sessionLog.rememberApplication'], undefined);
}
assert.equal(en['terminal.toolbar.sessionLog.menu'], 'Session log');
assert.equal(en['terminal.toolbar.sessionLog.open'], 'Open');
assert.equal(en['terminal.toolbar.sessionLog.reveal'], 'Show in folder');
assert.equal(en['terminal.toolbar.sessionLog.chooseApplication'], 'Open with…');
assert.equal(en['terminal.toolbar.sessionLog.systemDefault'], 'Open with system default');
assert.equal(zhCN['terminal.toolbar.sessionLog.menu'], '会话日志');
assert.equal(zhTW['terminal.toolbar.sessionLog.menu'], '工作階段日誌');
});
@@ -1,20 +0,0 @@
import assert from 'node:assert/strict';
import test from 'node:test';
import en from './en.ts';
import ru from './ru.ts';
import es from './es.ts';
import zhCN from './zh-CN.ts';
import zhTW from './zh-TW.ts';
const UNDO_KEYS = [
'ai.chat.undoLastTurn',
'ai.chat.undoLastTurnNotice',
] as const;
test('Undo-last-turn UI is localized in every supported locale', () => {
for (const [name, messages] of Object.entries({ en, es, 'zh-CN': zhCN, 'zh-TW': zhTW, ru })) {
const missing = UNDO_KEYS.filter(key => !messages[key]);
assert.deepEqual(missing, [], `${name} is missing undo-last-turn labels`);
}
});
@@ -1,37 +0,0 @@
import assert from "node:assert/strict";
import test from "node:test";
import en from "./en.ts";
import ru from "./ru.ts";
import es from "./es.ts";
import zhCN from "./zh-CN.ts";
import zhTW from "./zh-TW.ts";
const KEYS = [
"vault.hosts.selectedSummary",
"vault.groups.selectedCount",
"vault.groups.deleteMultiple.success",
"vault.groups.deleteDialog.bulkTitle",
"vault.groups.deleteDialog.bulkDesc",
"vault.groups.deleteDialog.bulkDeleteHosts",
"vault.import.destination.title",
"vault.import.destination.settings",
"vault.import.destination.done",
"vault.import.securecrt.folder",
"vault.import.securecrt.promptTitle",
"vault.import.securecrt.promptDesc",
"vault.import.progress.fileCount",
"vault.import.progress.persistFailed",
"vault.import.progress.rollbackFailed",
"vault.import.sshConfig.managedDestinationHint",
"vault.import.mobaxterm.masterPassword",
"vault.import.mobaxterm.masterPasswordPlaceholder",
"vault.import.mobaxterm.masterPasswordHint",
] as const;
test("bulk vault import and group-selection copy exists in every locale", () => {
for (const [locale, messages] of Object.entries({ en, ru, es, zhCN, zhTW })) {
const missing = KEYS.filter((key) => !messages[key]);
assert.deepEqual(missing, [], `${locale} is missing bulk vault labels`);
}
});
@@ -1,48 +0,0 @@
import assert from 'node:assert/strict';
import test from 'node:test';
import en from './en.ts';
import ru from './ru.ts';
import es from './es.ts';
import zhCN from './zh-CN.ts';
import zhTW from './zh-TW.ts';
const KEYS = [
'vault.groups.deleteDialog.managedDesc',
'vault.groups.deleteDialog.mixedDesc',
'vault.groups.deleteDialog.managedWarning',
'vault.groups.deleteDialog.managedFile',
] as const;
test('managed group delete warning copy exists in every locale', () => {
for (const [locale, messages] of Object.entries({ en, ru, es, zhCN, zhTW })) {
const missing = KEYS.filter((key) => !messages[key]);
assert.deepEqual(missing, [], `${locale} is missing managed group delete copy`);
}
});
test('managed group delete warning mentions data loss in every locale', () => {
const MARKERS = ['备份', '備份', 'copia de seguridad', 'резервную копию', 'Back up'];
for (const [locale, messages] of Object.entries({ en, ru, es, zhCN, zhTW })) {
const text = messages['vault.groups.deleteDialog.managedWarning'];
assert.match(
text ?? '',
/SSH/,
`${locale} warning should reference the SSH config file`,
);
assert.ok(
MARKERS.some((marker) => text?.includes(marker)),
`${locale} warning should tell the user to back up the file`,
);
}
});
test('linked file line interpolates the file path', () => {
for (const messages of [en, ru, es, zhCN, zhTW]) {
assert.match(
messages['vault.groups.deleteDialog.managedFile'] ?? '',
/\{file\}/,
'managedFile copy should include the {file} placeholder',
);
}
});
+23 -7
View File
@@ -71,6 +71,9 @@ export const zhCNAiMessages: Messages = {
'ai.providers.apiKey': 'API Key',
'ai.providers.apiKey.placeholder': '输入 API Key',
'ai.providers.apiKey.decrypting': '解密中...',
'ai.providers.opencodeGo.help': '粘贴 OpenCode API Key 即可使用 OpenCode Go,Base URL 与模型列表会自动配置。',
'ai.providers.opencodeGo.getKey': '获取 API Key',
'ai.providers.fixedBaseUrl.help': '由提供商固定,Netcatty 会按模型自动选择对应的接口路径。',
'ai.providers.baseUrl': 'Base URL',
'ai.providers.baseUrl.anthropicHelp': 'Anthropic 兼容:可填不带或带 /v1 的主机(例如 https://gateway.example 或 https://gateway.example/v1)。检测与聊天都会请求 /v1/models、/v1/messages。',
'ai.providers.baseUrl.ollamaHelp': '本地 Ollama:http://localhost:11434/v1(无需 API Key)。Ollama Cloud:https://ollama.com/v1,并填写 Cloud API Key。',
@@ -615,6 +618,23 @@ export const zhCNAiMessages: Messages = {
'ai.chat.rebindUsage': '用法:/rebind <序号>',
'ai.chat.rebindDone': '聊天“{title}”已重绑到此面板。',
'ai.chat.rebindUnavailable': '当前面板范围内没有可用的重绑目标。',
'ai.chat.managerScopeTab': '当前会话',
'ai.chat.managerAllChatsTab': '全部会话',
'ai.chat.managerSearchPlaceholder': '搜索会话标题…',
'ai.chat.managerFilterAllAgents': '全部 Agent',
'ai.chat.managerMoreActions': '更多操作',
'ai.chat.managerOpen': '在本面板打开',
'ai.chat.managerOpenDisabled': '正在其他工作区或终端中使用',
'ai.chat.managerRebind': '移动到…',
'ai.chat.managerRebindPick': '选择目标终端或工作区…',
'ai.chat.managerRebindHere': '当前面板',
'ai.chat.managerRebindDone': '已将“{title}”移动到 {target}。',
'ai.chat.managerExportOne': '导出此会话',
'ai.chat.managerBadgeActive': '使用中',
'ai.chat.managerBadgeIdle': '空闲',
'ai.chat.managerMessagesCount': '{n} 条消息',
'ai.chat.managerDeleteTitle': '删除此会话?',
'ai.chat.managerDeleteMessage': '“{title}”及其消息将从所有面板中移除,且无法撤销。',
'ai.chat.justNow': '刚刚',
'ai.chat.minutesAgo': '{n}分钟前',
'ai.chat.hoursAgo': '{n}小时前',
@@ -702,6 +722,9 @@ export const zhCNAiMessages: Messages = {
'ai.safety.responseIdleTimeout.unit': '秒',
'ai.safety.maxIterations': '最大迭代次数',
'ai.safety.maxIterations.description': '防止 AI 失控执行的最大工具调用循环次数。外部 Agent 可能有自己的内部迭代限制,以其为准。',
'ai.safety.toolOutputMaxChars': '内置 AI 工具输出限制',
'ai.safety.toolOutputMaxChars.description': '内置 AI 单次工具调用(如终端命令或 SFTP 读取)直接返回的最大字符数,超出后会截断并将完整结果保存为可读取的句柄(2,000–200,000)。',
'ai.safety.toolOutputMaxChars.unit': '字符',
'ai.safety.blocklist': '命令黑名单',
'ai.safety.blocklist.description': '用于拦截通过 Netcatty 执行的危险命令的正则表达式。',
'ai.safety.blocklist.placeholder': '正则表达式...',
@@ -732,9 +755,6 @@ export const zhCNAiMessages: Messages = {
'terminal.layer.theme': '主题',
'terminal.layer.notes': '笔记',
'terminal.layer.aiChat': 'AI 助手',
'terminal.layer.movePanelLeft': '面板移至左侧',
'terminal.layer.movePanelRight': '面板移至右侧',
'terminal.layer.movePanelBottom': '面板移至底部',
'terminal.layer.choosePanelPosition': '改变位置',
'terminal.layer.dockLeft': '左侧',
'terminal.layer.dockRight': '右侧',
@@ -768,19 +788,15 @@ export const zhCNAiMessages: Messages = {
'terminal.layer.hostTree.details.protocol': '协议',
'terminal.layer.hostTree.details.group': '分组',
'terminal.layer.hostTree.details.tags': '标签',
'terminal.layer.hostTree.details.lastConnected': '最近连接',
'topTabs.openQuickSwitcher': '打开快速切换',
'topTabs.moreTabs': '更多标签页',
'topTabs.aiAssistant': 'AI 助手',
'topTabs.newLocalTerminal': '新建本地终端',
'topTabs.controlPanel': '快捷控制',
'topTabs.controlPanel.externalMcp': '对外 MCP',
'topTabs.controlPanel.theme': '主题',
'topTabs.controlPanel.theme.light': '浅色',
'topTabs.controlPanel.theme.dark': '深色',
'topTabs.controlPanel.theme.system': '系统',
'topTabs.externalMcp.enable': '启用对外 MCP',
'topTabs.externalMcp.disable': '停用对外 MCP',
'topTabs.windowOpacity': '窗口透明度',
'topTabs.openSettings': '打开设置',
'ai.chat.sessionHistory': '会话历史',
+10 -37
View File
@@ -110,11 +110,9 @@ export const zhCNCoreMessages: Messages = {
'field.label': 'Label',
'field.type': '类型',
'auth.keyType': '类型 {type}',
'auth.showAllKeys': '显示全部 keys',
// Dialogs / prompts
'confirm.deleteHost': '删除主机 "{name}"?',
'confirm.deleteIdentity': '删除身份 "{name}"?',
'confirm.removeProvider': '移除提供商 "{name}"?',
'confirm.closeBusyTerminal.title': '确认关闭',
'confirm.closeBusyTerminal.message': '进程 "{command}" 仍在运行,关闭后会被终止。',
@@ -407,7 +405,6 @@ export const zhCNCoreMessages: Messages = {
'tray.status.inactive': '未启用',
'tray.status.error': '错误',
'tray.status.unknown': '未知',
'tray.recentHosts': '最近连接的主机',
'tray.empty.title': '一切都很安静',
'tray.empty.subtitle': '去连接个服务器吧,它们想念你了 🚀',
'tray.quit': '退出 Netcatty',
@@ -466,9 +463,6 @@ export const zhCNCoreMessages: Messages = {
'update.downloadFailed.message': '下载更新失败,可前往 GitHub 手动下载。',
'update.needsSave.title': '有未保存内容',
'update.needsSave.message': '请先保存已打开的编辑器,然后再次点击「立即重启」以安装更新。',
'update.openReleases': '打开 Releases',
'update.remindLater': '稍后提醒',
'update.skipVersion': '跳过此版本',
// Settings > Appearance
'settings.appearance.uiTheme': '界面主题',
@@ -488,7 +482,7 @@ export const zhCNCoreMessages: Messages = {
'settings.appearance.themeColor.dark': '深色主题',
'settings.appearance.customCss': '自定义 CSS',
'settings.appearance.customCss.desc':
'使用自定义 CSS 个性化界面,修改会立即生效。选中的顶部标签(`.top-tab[data-active="true"]`)会读取 `--top-tab-active-bg`、`--top-tab-active-fg` 和 `--top-tab-active-border`。不设置则保持当前外观。',
'使用自定义 CSS 个性化界面,修改会立即生效。',
'settings.appearance.customCss.help.ariaLabel': '自定义 CSS 说明',
'settings.appearance.customCss.help.title': '自定义 CSS 说明',
'settings.appearance.customCss.help.body': `主要 UI 区块都暴露了 \`data-section\` 属性,供你用 CSS 定位。编辑后会立即生效。
@@ -651,8 +645,6 @@ Vaults 标签保持扁平,不使用这块背景。
'settings.appearance.appIcon.whiteViolet': '白底 · 紫罗兰猫',
'settings.appearance.appIcon.rainbow': '彩虹猫',
// Context menus / common actions
'action.newHost': '新建主机',
'action.newSubfolder': '新建文件夹',
'action.copyPublicKey': '复制公钥',
'action.keyExport': '导出密钥',
'action.edit': '编辑',
@@ -1034,13 +1026,9 @@ Vaults 标签保持扁平,不使用这块背景。
'sftp.columns.actions': '操作',
'sftp.sort.directoriesFirst': '目录置顶',
'sftp.emptyDirectory': '空目录',
'sftp.nav.up': '返回上层',
'sftp.nav.home': '返回主目录',
'sftp.nav.refresh': '刷新',
'sftp.upload': '上传',
'sftp.uploadFiles': '上传文件',
'sftp.uploadFolder': '上传文件夹',
'sftp.dragDropToUpload': '拖拽文件到这里上传',
'sftp.retry': '重试',
'sftp.context.open': '打开',
'sftp.context.navigateTo': '跳转到这里',
@@ -1055,6 +1043,12 @@ Vaults 标签保持扁平,不使用这块背景。
'sftp.extract.extracting': '正在解压 {fileName}...',
'sftp.extract.success': '已解压 {fileName}',
'sftp.extract.error': '解压 {fileName} 失败:{error}',
'sftp.packedDownload.receiving': '正在接收打包数据…',
'sftp.packedDownload.extracting': '正在还原文件…',
'sftp.packedDownload.fallback': '当前无法打包下载,已改为逐文件下载。',
'sftp.packedDownload.selection': '已选 {count} 项',
'sftp.packedDownload.conflict': '目标位置已有同名项目,要选择其他保存文件夹吗?',
'sftp.archive.action': '压缩…',
'sftp.archive.title': '压缩文件',
'sftp.archive.description': '将 {count} 个选中项目打包到服务器上的压缩包。',
@@ -1079,28 +1073,21 @@ Vaults 标签保持扁平,不使用这块背景。
'sftp.copyCurrentPath': '复制当前路径',
'sftp.copyCurrentPath.success': '已复制当前路径',
'sftp.copyCurrentPath.error': '无法复制当前路径',
'sftp.viewMode.label': '视图模式',
'sftp.viewMode.list': '列表视图',
'sftp.viewMode.tree': '树形视图',
'sftp.viewMode.switchToList': '切换到列表视图',
'sftp.viewMode.switchToTree': '切换到树形视图',
'sftp.listDensity.compact': '紧凑列表',
'sftp.listDensity.comfortable': '宽松列表',
'sftp.listDensity.switchToCompact': '切换到紧凑列表',
'sftp.listDensity.switchToComfortable': '切换到宽松列表',
'sftp.tree.loadError': '加载目录失败',
'sftp.tree.loading': '加载中...',
'sftp.kind.folder': '文件夹',
'sftp.context.rename': '重命名',
'sftp.context.permissions': '权限',
'sftp.context.delete': '删除',
'sftp.context.refresh': '刷新',
'sftp.context.uploadFiles': '上传文件...',
'sftp.context.uploadFilesHere': '上传文件到这里...',
'sftp.context.uploadFolder': '上传文件夹...',
'sftp.context.uploadFolderHere': '上传文件夹到这里...',
'sftp.context.downloadSelected': '下载选中项({count})',
'sftp.context.deleteSelected': '删除选中项({count})',
'sftp.dropFilesHere': '拖拽文件到这里',
'sftp.itemsCount': '{count} 个项目',
'sftp.selectedCount': '已选 {count} 个',
@@ -1109,8 +1096,6 @@ Vaults 标签保持扁平,不使用这块背景。
'sftp.task.waiting': '等待中...',
'sftp.transfer.preparing': '准备中...',
'sftp.status.loading': '加载中...',
'sftp.status.uploading': '上传中...',
'sftp.status.ready': '就绪',
'sftp.transfers': '传输',
'sftp.transfers.active': '{count} 个进行中',
'sftp.transfers.clearCompleted': '清除已完成',
@@ -1173,7 +1158,6 @@ Vaults 标签保持扁平,不使用这块背景。
'sftp.transferCenter.applyAll': '应用到全部',
'sftp.transfers.resizeNameColumn': '调整文件名列宽',
'sftp.transfers.dragToResize': '拖拽调整高度',
'sftp.goUp': '上一级',
'sftp.goToTerminalCwd': '定位到终端当前目录',
'sftp.locatePathInTerminal': '定位路径到终端',
'sftp.followTerminalCwd': '追随终端目录',
@@ -1183,35 +1167,30 @@ Vaults 标签保持扁平,不使用这块背景。
'sftp.encoding.auto': '自动',
'sftp.encoding.utf8': 'UTF-8',
'sftp.encoding.gb18030': 'GB18030',
'sftp.goBack': '后退',
'sftp.goForward': '前进',
'sftp.goHome': '返回主目录',
'sftp.goRoot': '回到根目录',
'sftp.folderName': '文件夹名称',
'sftp.folderName.placeholder': '输入文件夹名称',
'sftp.fileName': '文件名称',
'sftp.fileName.placeholder': '输入文件名称',
'sftp.prompt.newFolderName': '新建文件夹名称?',
'sftp.rename.title': '重命名',
'sftp.rename.newName': '新名称',
'sftp.rename.placeholder': '输入新名称',
'sftp.confirm.deleteOne': '删除 "{name}"?',
'sftp.deleteConfirm.single': '删除 "{name}"?',
'sftp.deleteConfirm.title': '删除 {count} 个项目?',
'sftp.deleteConfirm.desc': '此操作不可撤销,将删除以下内容:',
'sftp.deleteConfirm.descSingle': '此操作不可撤销。',
'sftp.deleteConfirm.host': '主机',
'sftp.deleteConfirm.path': '路径',
'sftp.error.loadFailed': '加载目录失败',
'sftp.error.downloadFailed': '下载失败',
'sftp.error.uploadFailed': '上传失败',
'sftp.error.deleteFailed': '删除失败',
'sftp.error.createFolderFailed': '创建文件夹失败',
'sftp.error.createFileFailed': '创建文件失败',
'sftp.error.invalidFileName': '文件名包含非法字符:{chars}',
'sftp.error.reservedName': '此文件名是系统保留名称',
'sftp.overwrite.title': '文件已存在',
'sftp.overwrite.desc': '名为"{name}"的文件已存在。是否要替换它?',
'sftp.overwrite.confirm': '替换',
'sftp.error.renameFailed': '重命名失败',
'sftp.picker.title': '选择主机',
'sftp.picker.desc': '为{side}窗格选择主机',
'sftp.picker.searchPlaceholder': '搜索主机...',
@@ -1219,8 +1198,6 @@ Vaults 标签保持扁平,不使用这块背景。
'sftp.picker.local.desc': '浏览本地文件',
'sftp.picker.local.badge': '本地',
'sftp.picker.connected.section': '已连接',
'sftp.picker.connected.badge': '已连接',
'sftp.picker.connected.connecting': '连接中',
'sftp.picker.noMatch': '没有匹配的主机',
'sftp.permissions.title': '编辑权限',
'sftp.permissions.owner': '所有者',
@@ -1228,8 +1205,6 @@ Vaults 标签保持扁平,不使用这块背景。
'sftp.permissions.others': '其他',
'sftp.permissions.octal': '八进制',
'sftp.permissions.symbolic': '符号',
'sftp.permissions.success': '权限已更新',
'sftp.permissions.failed': '权限更新失败',
// Quick Switcher
'qs.search.placeholder': '搜索主机或标签页',
@@ -1255,12 +1230,9 @@ Vaults 标签保持扁平,不使用这块背景。
"settings.plugins.manager.remove": "卸载",
"settings.plugins.manager.removeNote": "卸载会移除插件代码和本地 KV 数据,保留用户设置、秘密存储和同步 sidecar。",
"settings.plugins.permissions.statusUnknown": "状态未知",
"plugins.sidebar.extensions": "扩展页面",
"plugins.sidebar.selectTerminal": "请先选择已打开的终端。",
"plugins.sidebar.loading": "正在加载扩展页面…",
"plugins.vault.loading": "正在加载插件页面…",
"plugins.vault.extensions": "扩展",
"plugins.vault.back": "返回主机",
"plugins.interaction.title": "插件请求",
"plugins.interaction.sharing": "分享的文本将交给此插件及其已授权的能力(包括网络访问)。读取文本不代表批准新的网络目标。",
"plugins.interaction.input": "输入文本",
@@ -1409,6 +1381,7 @@ Vaults 标签保持扁平,不使用这块背景。
'plugins.hostActions.selectionNote': '仅向此插件共享所选主机的元数据:名称、地址、用户名、协议、分组和标签。选择分组仅包含本次选中的成员。后续编辑或连接请求遵循此插件的权限设置。',
'plugins.hostActions.create': '预览主机草稿',
'plugins.hostActions.edit': '预览主机修改',
'plugins.hostActions.streamNote': '允许此插件通过选定的 SSH 服务器向以上地址和端口收发数据。地址由该服务器解析,可能读取或修改数据库数据。不打开终端、不运行启动脚本,SSH 密码和私钥不会交给插件。请选择 SSH 服务器。',
'plugins.hostActions.connect': '确认连接',
'plugins.hostActions.fieldDiff': '即将保存的修改',
'plugins.hostActions.defaultsWarning': '将应用已保存的连接默认设置。修改分组可能改变继承的认证、代理和脚本设置。',
-20
View File
@@ -1,6 +1,5 @@
export const zhCNScriptsMessages = {
'scripts.meta.name': '名称',
'scripts.meta.language': '语言',
'scripts.meta.description': '描述',
'scripts.meta.descriptionPlaceholder': '可选,脚本的简要说明',
'scripts.meta.trigger': '触发方式',
@@ -15,7 +14,6 @@ export const zhCNScriptsMessages = {
'scripts.actions.openEditor': '弹窗编辑',
'scripts.actions.openEditorHint': '在更大的窗口中编辑脚本',
'scripts.editor.modalTitle': '脚本编辑器',
'scripts.editor.modalSubtitle': '在更大的工作区中编辑脚本元数据和代码。',
'scripts.editor.lineCount': '{count} 行',
'scripts.editor.resize': '调整编辑器高度',
'scripts.targets.hint': '所选分组会动态匹配,之后加入分组的主机也会自动生效。',
@@ -86,17 +84,13 @@ export const zhCNScriptsMessages = {
'scripts.dialog.retry': '重试',
'scripts.dialog.skip': '跳过',
'scripts.dialog.abort': '终止',
'scripts.running.stepProgress': '步骤 {current} / {total}',
'scripts.running.determinateProgress': '{label} {current}/{total}',
'scripts.running.progressFallback': '进度',
'scripts.running.operationsCount': '已执行 {count} 个操作',
'scripts.running.opsPrefix': '已执行 ',
'scripts.running.opsSuffix': ' 个操作',
'scripts.running.elapsedLabel': '耗时',
'scripts.running.lastSentLabel': '已发送:',
'scripts.running.elapsed': '耗时 {elapsed}',
'scripts.running.completedSummary': '已完成 · 共 {count} 个操作 · {elapsed}',
'scripts.running.dismissHint': '点击关闭',
'scripts.running.dismiss': '关闭',
'scripts.running.viewLogs': '查看日志',
'scripts.running.logTitle': '{name} · 运行日志',
@@ -111,26 +105,12 @@ export const zhCNScriptsMessages = {
'vault.nav.scripts': '脚本',
'snippets.action.newScript': '新建自动化脚本',
'hostDetails.section.automation': '自动化',
'hostDetails.automation.loginScript': '登录脚本',
'hostDetails.automation.loginScriptPlaceholder': '选择脚本',
'hostDetails.automation.none': '无',
'hostDetails.automation.outputTriggers': '输出触发器',
'hostDetails.automation.addTrigger': '添加触发器',
'hostDetails.automation.triggerPatternPlaceholder': '正则表达式',
'hostDetails.automation.linkedScripts': '已关联脚本',
'hostDetails.automation.linkedScriptsEmpty': '尚未关联任何脚本。',
'hostDetails.automation.linkScriptPlaceholder': '关联已有脚本…',
'hostDetails.automation.unlink': '取消关联',
'hostDetails.automation.equivalenceHint': '此处关联会将本主机加入 Scripts 中该脚本的目标列表,两侧视图同步。',
'hostDetails.automation.queueHint': '连接本主机时按顺序运行脚本。全局脚本最先执行,再执行下方队列。',
'hostDetails.automation.globalScripts': '全局连接脚本',
'hostDetails.automation.globalScriptsHint': '每次连接时最先运行。顺序在脚本库排序中调整。',
'hostDetails.automation.connectQueue': '本主机运行队列',
'hostDetails.automation.connectQueueEmpty': '尚未为本主机配置连接脚本队列。',
'hostDetails.automation.addToQueuePlaceholder': '添加脚本到队列…',
'hostDetails.automation.moveUp': '上移',
'hostDetails.automation.moveDown': '下移',
'hostDetails.automation.removeFromQueue': '从队列移除',
'hostDetails.automation.dragHandle': '拖拽排序',
'hostDetails.automation.queueDragHint': '拖动条目即可调整连接时的运行顺序。',
};
@@ -14,13 +14,11 @@ export const zhCnSystemManagerMessages: Messages = {
'systemManager.tabs.docker': 'Docker',
'systemManager.tabs.gpu': 'GPU',
'systemManager.tabs.ariaLabel': '系统管理分区',
'systemManager.popup.loading': '正在打开终端…',
'systemManager.popup.startupFailed': '启动命令未成功。请确认目标仍然可用后重试。',
'systemManager.errors.loadProcesses': '加载进程列表失败',
'systemManager.errors.loadTmux': '加载 tmux 会话失败',
'systemManager.errors.loadTmuxWindows': '加载 tmux 窗口失败',
'systemManager.errors.loadTmuxPanes': '加载 tmux 面板失败',
'systemManager.errors.loadTmuxClients': '加载 tmux 客户端失败',
'systemManager.errors.actionFailed': '操作失败',
'systemManager.errors.loadDocker': '加载容器列表失败',
@@ -31,7 +29,6 @@ export const zhCnSystemManagerMessages: Messages = {
'systemManager.errors.nerdctlUnreachable': 'nerdctl 无法连接 containerd',
'systemManager.errors.clusterUnreachable': '无法连接到上下文 {{context}} 的集群',
'systemManager.errors.clusterUnreachableGeneric': '无法连接到集群',
'systemManager.errors.loadOverview': '加载系统概览失败',
'systemManager.errors.loadGpu': '加载 GPU / NPU 状态失败',
'systemManager.errors.loadPorts': '加载监听端口失败',
'systemManager.errors.loadServices': '加载 systemd 服务失败',
@@ -65,13 +62,10 @@ export const zhCnSystemManagerMessages: Messages = {
'systemManager.overview.noTopProcesses': '暂无进程数据',
'systemManager.processes.search': '搜索进程…',
'systemManager.processes.command': '命令',
'systemManager.processes.user': '用户',
'systemManager.processes.term': '终止',
'systemManager.processes.kill': '强杀',
'systemManager.processes.stop': '暂停 (SIGSTOP)',
'systemManager.processes.cont': '继续 (SIGCONT)',
'systemManager.processes.hup': '挂断 (SIGHUP)',
'systemManager.processes.renice': '调整优先级',
'systemManager.processes.renicePrompt': 'Nice 值 (-20 到 19)',
'systemManager.processes.reniceInvalid': 'Nice 值必须在 -20 到 19 之间',
@@ -86,7 +80,6 @@ export const zhCnSystemManagerMessages: Messages = {
'systemManager.processes.stat': '状态',
'systemManager.processes.meta': '{{count}} 个进程',
'systemManager.processes.loading': '正在加载进程…',
'systemManager.processes.loadingMore': '正在显示更多进程…',
'systemManager.processes.state.running': '运行中',
'systemManager.processes.state.sleeping': '睡眠',
'systemManager.processes.state.stopped': '已暂停',
@@ -124,12 +117,9 @@ export const zhCnSystemManagerMessages: Messages = {
'systemManager.tmux.attached': '已附加',
'systemManager.tmux.detached': '未附加',
'systemManager.tmux.windows': '{{count}} 个窗口',
'systemManager.tmux.created': '创建时间',
'systemManager.tmux.activity': '活动时间',
'systemManager.tmux.rename': '重命名',
'systemManager.tmux.detach': '全部分离',
'systemManager.tmux.killSession': '结束会话',
'systemManager.tmux.killServer': '结束 tmux 服务',
'systemManager.tmux.loadingDetails': '正在加载详情…',
'systemManager.tmux.clients': '已附加客户端',
'systemManager.tmux.windowList': '窗口',
@@ -140,31 +130,17 @@ export const zhCnSystemManagerMessages: Messages = {
'systemManager.docker.unavailable': '此主机未检测到容器运行时(Docker、Podman、nerdctl 或 kubectl)',
'systemManager.tmux.windowsMismatch': '会话显示有 {{count}} 个窗口,但 list-windows 未返回任何窗口',
'systemManager.tmux.lastCommand': '最后执行的命令:{{command}}',
'systemManager.tmux.noPanes': '没有面板',
'systemManager.tmux.panes': '{{count}} 个面板',
'systemManager.tmux.active': '当前',
'systemManager.tmux.unnamedWindow': '未命名窗口',
'systemManager.tmux.unnamedPane': '未命名面板',
'systemManager.tmux.attachWindow': '附加到窗口',
'systemManager.tmux.selectWindow': '选中窗口',
'systemManager.tmux.killWindow': '关闭窗口',
'systemManager.tmux.killPane': '关闭面板',
'systemManager.tmux.splitHorizontal': '水平分屏',
'systemManager.tmux.splitVertical': '垂直分屏',
'systemManager.tmux.sendKeys': '发送按键',
'systemManager.tmux.sendKeysTo': '向窗口 {{window}} 面板 {{pane}} 发送按键',
'systemManager.tmux.sendKeysPlaceholder': '命令或文本…',
'systemManager.tmux.renameSessionPrompt': '重命名会话',
'systemManager.tmux.renameWindowPrompt': '重命名窗口',
'systemManager.tmux.windowName': '窗口名称',
'systemManager.tmux.confirmKillSession': '确定结束 tmux 会话「{{name}}」?',
'systemManager.tmux.confirmDetachSession': '确定将所有客户端从「{{name}}」分离?',
'systemManager.tmux.confirmKillWindow': '确定关闭窗口「{{name}}」?',
'systemManager.tmux.confirmKillPane': '确定关闭面板 #{{index}}?',
'systemManager.tmux.confirmKillServer': '确定结束 tmux 服务?所有会话将被终止。',
'systemManager.tmux.meta': '{{count}} 个会话',
'systemManager.docker.title': '容器',
'systemManager.docker.subTabs.containers': '容器',
'systemManager.docker.subTabs.images': '镜像',
'systemManager.docker.empty': '未找到容器',
@@ -177,7 +153,6 @@ export const zhCnSystemManagerMessages: Messages = {
'systemManager.docker.filter.paused': '已暂停',
'systemManager.docker.shell': 'Shell',
'systemManager.docker.logs': '日志',
'systemManager.docker.details': '详情',
'systemManager.docker.inspect': 'Inspect',
'systemManager.docker.imageInspect': '镜像 Inspect',
'systemManager.docker.confirmRemove': '确定删除此容器?',
+24 -74
View File
@@ -12,6 +12,10 @@ export const zhCNTerminalMessages: Messages = {
'terminal.directory.hidden': '显示隐藏目录',
'terminal.directory.refresh': '刷新',
'terminal.directory.unavailable': '此会话暂不支持目录导航。',
'terminal.directory.integrationUnavailable': 'PowerShell 目录集成未就绪,启动参数或执行策略可能阻止了加载。',
'terminal.directory.cmdIntegrationUnavailable': '正在等待原 CMD 会话报告当前目录。',
'terminal.directory.nonFilesystem': '当前 PowerShell 位置不是文件系统目录。',
'terminal.directory.accessDenied': '没有权限列出此目录。',
'terminal.directory.busy': '请等待终端回到空命令提示符。',
'terminal.directory.readFailed': '无法读取此目录,请刷新重试。',
'terminal.directory.changeFailed': '未能确认目录切换,请刷新后重试。',
@@ -57,7 +61,6 @@ export const zhCNTerminalMessages: Messages = {
'terminal.osc7Setup.title': '配置目录追踪',
'terminal.osc7Setup.desc': 'Netcatty 会为当前远端用户添加 OSC 7 提示符配置。这样在 sudo 或 su 之后,SFTP 也能继续跟随终端目录。',
'terminal.osc7Setup.targets': '可能写入的文件',
'terminal.osc7Setup.command': '将执行的命令',
'terminal.osc7Setup.run': '执行配置',
'terminal.osc7Setup.running': '正在配置...',
'terminal.osc7Setup.configured': '目录追踪已配置',
@@ -96,39 +99,23 @@ export const zhCNTerminalMessages: Messages = {
'history.clearAll.dialog.confirm': '全部清空',
// SFTP File Opener
'sftp.context.copyPath': '复制文件路径',
'sftp.context.insertPathToTerminal': '插入路径到终端',
'sftp.context.cdInTerminal': '在终端中打开 (cd)',
'sftp.terminal.insertBlockedUnsafeQuote': '终端光标位于未闭合的引号或转义符内,无法安全插入路径',
'sftp.context.openWith': '打开方式...',
'sftp.context.edit': '编辑',
'sftp.context.preview': '预览',
'sftp.opener.title': '打开方式',
'sftp.opener.desc': '选择一个应用程序来打开此文件',
'sftp.opener.builtInEditor': '内置编辑器',
'sftp.opener.editDescription': '编辑文本文件',
'sftp.opener.builtInImageViewer': '内置图片预览',
'sftp.opener.previewDescription': '预览图片',
'sftp.opener.systemApp': '选择应用程序...',
'sftp.opener.systemAppDescription': '从本地选择一个应用程序',
'sftp.opener.onlySystemApp': '此文件只能用外部应用程序打开',
'sftp.opener.noAppsAvailable': '无可用应用程序',
'sftp.opener.noExtension': '无扩展名文件',
'sftp.opener.setDefault': '始终使用此方式打开 {ext} 文件',
'sftp.opener.confirmTitle': '设为默认?',
'sftp.opener.confirmDescription': '是否始终使用 {app} 打开 {ext} 文件?',
'sftp.opener.yesRemember': '是,记住此选择',
'sftp.opener.justOnce': '仅此一次',
'sftp.opener.confirm.title': '设置默认应用程序',
'sftp.opener.confirm.desc': '是否始终使用此应用程序打开 .{ext} 文件?',
'sftp.editor.title': '文本编辑器',
'sftp.editor.save': '保存到远程',
'sftp.editor.saving': '保存中...',
'sftp.editor.saved': '保存成功',
'sftp.editor.saveFailed': '保存文件失败',
'sftp.editor.unsavedChanges': '您有未保存的更改。确定要关闭吗?',
'sftp.editor.syntaxHighlight': '语法高亮',
'sftp.preview.title': '图片预览',
'sftp.preview.zoomIn': '放大',
'sftp.preview.zoomOut': '缩小',
'sftp.preview.resetZoom': '重置缩放',
'sftp.preview.fitToWindow': '适应窗口',
// Settings > SFTP File Associations
'settings.tab.sftpFileAssociations': 'SFTP',
@@ -208,28 +195,16 @@ export const zhCNTerminalMessages: Messages = {
'sftp.autoSync.error': '同步文件失败:{error}',
// SFTP Folder Upload Progress
'sftp.upload.progress': '正在上传 {current}/{total} 个文件...',
'sftp.upload.uploading': '正在上传...',
'sftp.upload.compressing': '正在压缩...',
'sftp.upload.extracting': '正在解压...',
'sftp.upload.scanning': '正在扫描文件...',
'sftp.upload.completed': '已完成',
'sftp.upload.compressed': '压缩传输',
'sftp.upload.currentFile': '当前: {fileName}',
'sftp.upload.cancelled': '上传已取消',
'sftp.upload.noFiles': '没有可上传的文件',
'sftp.upload.partialSuccess': '已上传 {success} 个文件,{failed} 个失败',
'sftp.upload.cancel': '取消',
'sftp.upload.completedToPath': '已上传至 {path}',
// SFTP Download
'sftp.download.completed': '已下载',
'sftp.download.cancelled': '下载已取消',
// SFTP Reconnecting
'sftp.reconnecting.title': '正在重连...',
'sftp.reconnecting.desc': '连接已断开,正在尝试重新连接',
'sftp.reconnected': '连接已恢复',
'sftp.error.reconnectFailed': '重连失败,请重试。',
'sftp.error.connectionLostManual': '连接已断开,请手动重新连接。',
'sftp.error.connectionLostReconnecting': '连接已断开,正在重连...',
@@ -247,6 +222,17 @@ export const zhCNTerminalMessages: Messages = {
'settings.sftp.compressedUpload.enable': '启用文件夹压缩',
'settings.sftp.compressedUpload.enableDesc': '自动使用 tar 压缩文件夹后再传输。需要服务器支持 tar 命令,不支持时自动回退到普通传输。',
'settings.sftp.packedDownload': '打包下载',
'settings.sftp.packedDownload.enable': '下载文件夹或多选项目时打包',
'settings.sftp.packedDownload.enableDesc': '将所选内容一次传回,在本地自动还原原有目录结构。服务器不支持打包时,自动逐文件下载。',
'settings.sftp.downloadLocation': '下载位置',
'settings.sftp.downloadLocation.directory': '默认下载文件夹',
'settings.sftp.downloadLocation.directoryDesc': '下载 SFTP 文件时,保存对话框默认打开此文件夹。未设置或文件夹已不存在时,使用系统“下载”文件夹。',
'settings.sftp.downloadLocation.systemDefault': '系统“下载”文件夹',
'settings.sftp.downloadLocation.browse': '浏览…',
'settings.sftp.downloadLocation.reset': '恢复为系统“下载”文件夹',
'settings.sftp.downloadLocation.select': '选择默认下载文件夹',
'settings.sftp.skipUnchanged.enable': '跳过未改文件',
'settings.sftp.skipUnchanged.enableDesc': '当目标文件的大小与修改时间已与源一致时跳过传输(类似 rsync)。替换到暂存路径时自动禁用。',
@@ -489,7 +475,9 @@ export const zhCNTerminalMessages: Messages = {
'settings.terminal.connection.defaultProxy.desc': '主机没有单独设置、也没有从分组继承代理时使用的已保存代理。选择“无”则直接连接。',
'settings.terminal.connection.defaultProxy.none': '无',
'settings.terminal.connection.sshAutoReconnectEnabled': 'SSH 断线后自动重连',
'settings.terminal.connection.sshAutoReconnectEnabled.desc': '打开后,已连上的 SSH 会话意外断开时会每 5 秒尝试重新连接,直到关闭标签页或连接恢复。',
'settings.terminal.connection.sshAutoReconnectEnabled.desc': '打开后,SSH 会话意外断开时会按设定间隔尝试重新连接,直到关闭标签页或连接恢复。',
'settings.terminal.connection.sshAutoReconnectInterval': 'SSH 重连间隔(秒)',
'settings.terminal.connection.sshAutoReconnectInterval.desc': '自动重连尝试之间的等待时间:5–3600 秒,默认 5 秒。修改从下次安排重试时生效,不改变已开始的等待。',
'settings.terminal.connection.keepaliveInterval': '会话保持间隔',
'settings.terminal.connection.keepaliveInterval.desc': '向服务器发送 SSH 保活数据包的频率(秒)。设为 0 表示全局禁用——单个主机可在自己的设置里覆盖此值。',
'settings.terminal.connection.keepaliveCountMax': '最大无响应保活次数',
@@ -614,6 +602,7 @@ export const zhCNTerminalMessages: Messages = {
'settings.shortcuts.binding.close-tab': '关闭标签页',
'settings.shortcuts.binding.close-session': '关闭会话窗格',
'settings.shortcuts.binding.new-tab': '新建本地标签页',
'settings.shortcuts.binding.reopen-closed-tab': '重新打开关闭的标签页',
'settings.shortcuts.binding.copy': '从终端复制',
'settings.shortcuts.binding.paste': '粘贴到终端',
'settings.shortcuts.binding.paste-selection': '将选区粘贴到终端',
@@ -661,7 +650,6 @@ export const zhCNTerminalMessages: Messages = {
'hostDetails.proxyPanel.credentials': '凭据',
'hostDetails.proxyPanel.usernamePlaceholder': '用户名',
'hostDetails.proxyPanel.passwordPlaceholder': '密码',
'hostDetails.proxyPanel.identities': '身份',
'hostDetails.proxyPanel.keychainIdentity': '钥匙串身份',
'hostDetails.proxyPanel.manualCredentials': '手动凭据',
'hostDetails.proxyPanel.remove': '移除代理',
@@ -682,8 +670,6 @@ export const zhCNTerminalMessages: Messages = {
'hostDetails.envVars.newVariable': '新变量',
'hostDetails.envVars.variableName': '变量名',
'hostDetails.chain.title': '编辑链路',
'hostDetails.chain.desc': '添加另一台主机将创建到 {host} 的连接。',
'hostDetails.chain.addHost': '添加主机',
'hostDetails.chain.target': '目标',
'hostDetails.chain.availableHosts': '可用主机',
'hostDetails.chain.clear': '清空',
@@ -695,10 +681,7 @@ export const zhCNTerminalMessages: Messages = {
'hostDetails.group.addProtocol': '添加协议',
// Keychain
'keychain.filter.key': '密钥',
'keychain.filter.certificate': '证书',
'keychain.action.generateKey': '生成密钥',
'keychain.action.importKey': '导入密钥',
'keychain.action.newIdentity': '新建身份',
'keychain.action.importCertificate': '导入证书',
'keychain.view.grid': '网格',
@@ -739,20 +722,8 @@ export const zhCNTerminalMessages: Messages = {
'keychain.export.exporting': '导出中...',
'keychain.export.exportAndAttach': '导出并绑定',
'keychain.export.title': '密钥导出',
'keychain.export.exportToRequired': '导出到 *',
'keychain.export.selectHostPlaceholder': '选择主机...',
'keychain.export.locationLabel': '位置 ~ $1 *',
'keychain.export.filenameLabel': '文件名 ~ $2 *',
'keychain.export.advanced': '高级',
'keychain.export.note.supportsOnly': '密钥导出目前仅支持',
'keychain.export.note.systems': '系统。',
'keychain.export.note.use': '请使用',
'keychain.export.note.customize': '部分自定义导出脚本。',
'keychain.export.scriptRequired': '脚本 *',
'keychain.export.exportToHost': '导出到主机',
'keychain.export.failedGeneric': '导出失败:{message}',
'keychain.field.label': '名称',
'keychain.field.labelRequired': '名称 *',
'keychain.field.labelPlaceholder': '密钥 Label',
'keychain.field.privateKeyRequired': '私钥 *',
'keychain.field.publicKey': '公钥',
@@ -788,13 +759,9 @@ export const zhCNTerminalMessages: Messages = {
"fido.recovery.usePassword": "改用已配置的密码",
"fido.recovery.passwordFallback": "正在使用此主机已配置的密码登录",
"fido.prompt.cancelled": "已取消安全密钥验证。",
'fido.prompt.touchDone': '已触摸',
'fido.prompt.timeout': 'FIDO 提示已超时,请重新连接。',
'fido.error.opensshMissing': '需要带 FIDO/libfido2 的 OpenSSH。macOS:brew install openssh libfido2。',
'fido.error.agentUnavailable': '无法启动支持 FIDO 的 SSH agent。',
'keychain.generate.resident': '在设备上保存凭据',
'keychain.generate.verifyRequired': '每次验证 PIN',
'keychain.action.loadResident': '从安全密钥加载驻留密钥',
'keychain.generate.keySize': '密钥长度',
'keychain.generate.labelPlaceholder': '密钥 Label',
'keychain.generate.passphrasePlaceholder': 'Passphrase(可选)',
@@ -804,7 +771,6 @@ export const zhCNTerminalMessages: Messages = {
'keychain.import.dropHint': '将密钥文件拖到这里',
'keychain.import.importFromFile': '从文件导入',
'keychain.import.saveKey': '保存密钥',
'keychain.import.importedKeyLabel': '已导入密钥',
'keychain.identity.usernameRequired': '用户名 *',
'keychain.identity.method.passwordOnly': '密码',
'keychain.identity.summary.password': '认证密码',
@@ -813,14 +779,8 @@ export const zhCNTerminalMessages: Messages = {
'keychain.identity.summary.passwordAndKey': '认证密码与密钥',
'keychain.identity.summary.passwordAndCertificate': '认证密码与证书',
'keychain.identity.summary.none': '无凭据',
'keychain.identity.selectCredential': '选择{kind}',
'keychain.identity.save': '保存',
'keychain.identity.update': '更新',
'keychain.keyDialog.newTitle': '新建密钥',
'keychain.keyDialog.newDesc': '添加新的 SSH 密钥',
'keychain.keyDialog.editTitle': '编辑密钥',
'keychain.keyDialog.editDesc': '更新此 SSH 密钥',
'keychain.keyDialog.updateKey': '更新密钥',
// Tabs
'tabs.closeSessionAria': '关闭会话',
@@ -832,6 +792,8 @@ export const zhCNTerminalMessages: Messages = {
'tabs.duplicateSession': '复制会话',
'tabs.copyTabToNewWindow': '复制标签页到新窗口',
'tabs.copyTabToNewWindowFailed': '无法在新窗口打开标签页',
'tabs.moveTabToNewWindow': '移动标签页到新窗口',
'tabs.moveTabToNewWindowFailed': '无法将标签页移动到新窗口',
'tabs.closeOthers': '关闭其他标签',
'tabs.closeToLeft': '关闭左侧标签',
'tabs.closeToRight': '关闭右侧标签',
@@ -895,8 +857,6 @@ export const zhCNTerminalMessages: Messages = {
'snippets.search.noResults.desc': '没有脚本或脚本包与"{query}"匹配。换一个关键字,或清除搜索进行浏览。',
'snippets.section.packages': '脚本包',
'snippets.section.snippets': '脚本',
'snippets.kind.codeSnippet': '代码片段',
'snippets.kind.automationScript': '自动化脚本',
'snippets.package.count': '{count} 个脚本',
'snippets.commandFallback': '命令',
'snippets.view.grid': '网格',
@@ -928,9 +888,6 @@ export const zhCNTerminalMessages: Messages = {
'snippets.import.modal.multipleFiles': '已选择 {count} 个文件',
'snippets.import.modal.parsedSummary': '{files} 个文件,{total} 个脚本,{packages} 个脚本包,{conflicts} 个重复命令。主机绑定会被忽略。',
'snippets.import.modal.confirm': '确认导入',
'snippets.import.conflict.title': '导入代码片段?',
'snippets.import.conflict.desc': '“{file}”包含 {total} 个代码片段,其中 {conflicts} 个命令已存在。',
'snippets.import.conflict.hostBindingsNote': '代码片段的主机绑定不会被导入或导出。',
'snippets.import.conflict.skip': '跳过重复项',
'snippets.import.conflict.overwrite': '覆盖重复项',
'snippets.packageDialog.title': '新建脚本包',
@@ -989,9 +946,6 @@ export const zhCNTerminalMessages: Messages = {
'serial.field.customPort': '自定义串口路径',
'serial.field.namedPipeHint': 'Windows 虚拟机控制台:输入 \\\\.\\pipe\\name。虚拟机需作为服务端创建管道,波特率和串口帧设置不生效。',
'serial.field.customPortPlaceholder': '例如 /dev/ttys001 或 COM1',
'serial.type.hardware': '硬件',
'serial.type.pseudo': '虚拟终端',
'serial.type.custom': '自定义',
'serial.parity.none': '无',
'serial.parity.even': '偶校验',
'serial.parity.odd': '奇校验',
@@ -1012,7 +966,6 @@ export const zhCNTerminalMessages: Messages = {
'serial.backspace.default': '默认(DEL,0x7F)',
'serial.backspace.ctrlH': 'Ctrl+H(BS,0x08)',
'serial.field.charset': '字符编码',
'serial.connectionError': '连接串口失败',
'serial.field.baudRatePlaceholder': '选择或输入波特率...',
'serial.field.baudRateEmpty': '输入自定义波特率',
'serial.field.customBaudRate': '使用自定义波特率',
@@ -1031,10 +984,7 @@ export const zhCNTerminalMessages: Messages = {
'keyboard.interactive.title': '需要验证',
'keyboard.interactive.desc': '服务器需要额外的身份验证。',
'keyboard.interactive.descWithHost': '服务器 {hostname} 需要额外的身份验证。',
'keyboard.interactive.response': '响应',
'keyboard.interactive.verificationCode': '验证码',
'keyboard.interactive.enterCode': '输入验证码',
'keyboard.interactive.enterResponse': '输入响应',
'keyboard.interactive.submit': '提交',
'keyboard.interactive.verifying': '验证中...',
'keyboard.interactive.savePassword': '保存密码',
+2 -77
View File
@@ -19,14 +19,6 @@ export const zhCNVaultMessages: Messages = {
'notes.export.toast.failed': '导出笔记失败。',
'notes.codeBlock.copied': '已复制',
'notes.codeBlock.copyFailed': '复制代码块失败。',
'notes.group.prompt': '文件夹路径',
'notes.group.all': '笔记本',
'notes.group.ungrouped': '未分组',
'notes.section.notebooks': '笔记本',
'notes.section.notes': '笔记',
'notes.mode.edit': '编辑',
'notes.mode.split': '分屏',
'notes.mode.preview': '预览',
'notes.title.placeholder': '笔记标题',
'notes.editor.placeholder': '在这里写 Markdown 笔记...',
'notes.editor.unrenderableMarkdown': '这篇笔记包含富文本编辑器无法显示的 Markdown(例如未闭合的 <tag> 文本),已改为显示原始 Markdown 源码,内容并没有丢失。',
@@ -72,25 +64,18 @@ export const zhCNVaultMessages: Messages = {
'notes.toolbar.divider': '分割线',
'notes.toolbar.link': '插入超链接',
'notes.toolbar.image': '插入图片',
'notes.action.pin': '置顶笔记',
'notes.action.unpin': '取消置顶',
'notes.tag.remove': '移除标签',
'notes.tag.placeholder': '标签名...',
'notes.tag.add': '添加标签',
'notes.outline.title': '大纲目录',
'notes.outline.titleWithCount': '大纲目录 ({count})',
'notes.outline.empty': '暂无标题大纲',
'notes.outline.emptyHint': '在 Markdown 中使用 #、## 编写各级标题',
'notes.export.share': '导出与分享',
'notes.export.currentNote': '当前笔记',
'notes.export.exportMarkdown': '导出为 Markdown (.md)',
'notes.export.exportHtml': '导出为 HTML (.html)',
'notes.export.copyMarkdown': '复制 Markdown 源码',
'notes.export.allNotes': '全部笔记',
'notes.export.exportAllZip': '导出全部为 ZIP 压缩包',
'notes.export.toast.markdownSuccess': '已导出 Markdown 文件',
'notes.export.toast.htmlSuccess': '已导出 HTML 文件',
'notes.export.toast.zipSuccess': '已导出全部笔记备份 ZIP',
// Select Host panel
'selectHost.title': '选择主机',
@@ -131,12 +116,6 @@ export const zhCNVaultMessages: Messages = {
'vault.panel.resizeWidth': '调整面板宽度',
'hostDetails.saveAria': '保存',
'hostConnectionTest.title': '测试连接',
'hostConnectionTest.test': '测试',
'hostConnectionTest.chainOf': '第 {current}/{total} 跳',
'hostConnectionTest.success': '连接成功',
'hostConnectionTest.successHint': '主机已接受您的凭据。您可以关闭此窗口。',
'hostConnectionTest.connecting': '正在连接… {seconds} 秒后超时',
'hostConnectionTest.failed': '连接失败。',
'hostConnectionTest.retry': '重试',
'hostConnectionTest.credentialsUnavailable': '保存的凭据无法在此设备上解密。请在下方重新输入。',
'hostDetails.section.address': '地址',
@@ -173,11 +152,8 @@ export const zhCNVaultMessages: Messages = {
'hostDetails.notes.toggle.show': '显示备注编辑框',
'hostDetails.notes.toggle.hide': '隐藏备注编辑框',
'hostDetails.group.placeholder': '父级 Group',
'hostDetails.section.credentials': '凭据',
'hostDetails.section.portCredentials': '端口与凭据',
'hostDetails.section.appearance': '外观',
'hostDetails.distro.title': 'Linux 发行版',
'hostDetails.distro.desc': '可在连接后自动探测,也可以手动覆盖图标所用的发行版。',
'hostDetails.icon.title': '主机图标',
'hostDetails.icon.sectionTitle': '颜色与图标',
'hostDetails.icon.desc': '选择此主机使用的图标来源和颜色。',
@@ -189,7 +165,6 @@ export const zhCNVaultMessages: Messages = {
'hostDetails.icon.mode.custom': '自定义',
'hostDetails.icon.reset': '重置主机图标',
'hostDetails.icon.colorLabel': '图标颜色',
'hostDetails.icon.colorDefault': '默认',
'hostDetails.icon.colorAuto': '自动',
'hostDetails.icon.colorManual': '手动',
'hostDetails.icon.colorChoice': '颜色',
@@ -240,7 +215,6 @@ export const zhCNVaultMessages: Messages = {
'hostDetails.distro.mode.auto': '自动探测',
'hostDetails.distro.mode.manual': '手动覆盖',
'hostDetails.distro.detectedLabel': '当前值',
'hostDetails.distro.manualLabel': '手动指定',
'hostDetails.distro.pending': '首次连接后自动探测',
'hostDetails.distro.unknown': '未知',
'hostDetails.distro.option.linux': '通用 Linux',
@@ -291,7 +265,6 @@ export const zhCNVaultMessages: Messages = {
'hostDetails.auth.mfaFirst': '优先交互式认证',
'hostDetails.auth.mfaFirst.desc': '适用于必须通过 keyboard-interactive 输入密码和 MFA 的服务器。',
'hostDetails.totp.title': '验证器 (TOTP)',
'hostDetails.totp.enable': '为这台主机保存 TOTP 密钥',
'hostDetails.totp.setup': '设置…',
'hostDetails.totp.edit': '编辑',
'hostDetails.totp.modalTitle': '设置验证器',
@@ -394,10 +367,8 @@ export const zhCNVaultMessages: Messages = {
'hostDetails.jumpHosts.direct': '直连',
'hostDetails.jumpHosts.configure': '配置代理主机',
'hostDetails.proxy': '通过 HTTP/SOCKS5/命令代理',
'hostDetails.proxy.none': '无',
'hostDetails.proxy.direct': '直连(不使用代理)',
'hostDetails.proxy.directHint': '不使用分组或全局默认代理',
'hostDetails.proxy.edit': '编辑代理',
'hostDetails.proxy.configure': '配置代理',
'hostDetails.envVars': '环境变量',
'hostDetails.envVars.add': '添加环境变量',
@@ -437,6 +408,8 @@ export const zhCNVaultMessages: Messages = {
'localShell.field.shellResolved': '启动 {command}',
'localShell.field.startDir': '启动目录',
'localShell.field.startDirPlaceholder': '继承全局起始目录(未设置时为主目录)',
'localShell.field.startupCommandPlaceholder': 'Shell 启动后执行的命令(例如:npm run dev)',
'localShell.field.startupCommandDesc': '本地 Shell 在启动目录打开后自动执行该命令。',
'localShell.saveAndConnect': '保存并打开',
'hostDetails.plugin.title': '插件连接',
@@ -456,28 +429,14 @@ export const zhCNVaultMessages: Messages = {
'hostDetails.plugin.useSsh': '改用 SSH',
// Host form (legacy modal)
'hostForm.title.edit': '编辑主机',
'hostForm.title.new': '新建主机',
'hostForm.desc.edit': '更新该主机的连接信息',
'hostForm.desc.new': '创建一个新的 SSH 主机条目',
'hostForm.field.label': '名称',
'hostForm.placeholder.label': 'My Production Server',
'hostForm.field.hostname': 'Hostname / IP',
'hostForm.placeholder.hostname': '192.168.1.1',
'hostForm.field.port': '端口',
'hostForm.field.username': '用户名',
'hostForm.field.osType': '操作系统类型',
'hostForm.placeholder.selectOs': '选择操作系统',
'hostForm.field.group': '分组',
'hostForm.placeholder.group': '例如:AWS、DigitalOcean',
'hostForm.field.tags': '标签',
'hostForm.placeholder.addTag': '添加标签…',
'hostForm.auth.method': '认证方式',
'hostForm.auth.password': '密码',
'hostForm.auth.sshKey': 'SSH密钥',
'hostForm.auth.selectKey': '选择 SSH密钥',
'hostForm.auth.noKeys': '暂无密钥',
'hostForm.auth.noKeysHint': '钥匙串中未找到 SSH密钥,请先创建一个。',
'hostForm.saveHost': '保存主机',
// Connection logs
@@ -495,7 +454,6 @@ export const zhCNVaultMessages: Messages = {
'logs.action.delete': '删除',
// Log view
'logView.customizeAppearance': '自定义外观',
'logView.appearance': '外观',
'logView.readOnly': '只读',
'logView.export': '导出',
@@ -508,7 +466,6 @@ export const zhCNVaultMessages: Messages = {
'terminal.toolbar.availableAfterConnect': '连接后可用',
'terminal.toolbar.sendYmodem': 'YMODEM 发送',
'terminal.toolbar.receiveYmodem': 'YMODEM 接收',
'terminal.toolbar.sftp': 'SFTP',
'terminal.toolbar.more': '更多操作',
'terminal.toolbar.scripts': '脚本',
'terminal.toolbar.history': '命令历史',
@@ -533,7 +490,6 @@ export const zhCNVaultMessages: Messages = {
'terminal.composeBar.resize': '拖拽调整撰写栏高度',
'terminal.composeBar.manageSnippets': '管理快捷代码片段',
'terminal.composeBar.searchSnippets': '搜索代码片段...',
'terminal.composeBar.noPinnedSnippets': '点击 + 固定常用代码片段',
'terminal.composeBar.noMatchingSnippets': '没有匹配的代码片段',
'terminal.composeBar.pinnedCount': '已固定 {count} 个',
'terminal.composeBar.unpinSnippet': '从快捷栏移除 {label}',
@@ -690,9 +646,6 @@ export const zhCNVaultMessages: Messages = {
'terminal.themeModal.themeType': '{type} 主题',
'terminal.hiddenTheme.title': '当前隐藏主题',
'terminal.hiddenTheme.desc': '这个主题已从手动选择列表中隐藏;当你选择其他可见主题后,它会被替换。',
'topTabs.toggleTheme.systemExitTitle': '当前正在跟随系统主题',
'topTabs.toggleTheme.systemExitMessage': '请到设置里选择固定的浅色或深色主题。',
'topTabs.toggleTheme.openSettings': '打开设置',
// Custom Themes
'terminal.customTheme.section': '自定义主题',
@@ -705,7 +658,6 @@ export const zhCNVaultMessages: Messages = {
'terminal.customTheme.importDesc': '从 iTerm2 配色方案文件导入',
'terminal.customTheme.importError': '无法解析所选文件,请确保它是有效的 .itermcolors XML 文件。',
'terminal.customTheme.delete': '删除主题',
'terminal.customTheme.confirmDelete': '确认删除',
'terminal.customTheme.name': '名称',
'terminal.customTheme.namePlaceholder': '我的自定义主题',
'terminal.customTheme.type': '类型',
@@ -764,10 +716,7 @@ export const zhCNVaultMessages: Messages = {
'cloudSync.provider.disconnect.cloudRemains': '云端的加密同步副本可能仍保存在 {name} 存储中。如需清除,请到该服务商删除同步文件。断开连接不代表设备已完成交接清理。',
'cloudSync.provider.disconnect.failed': '未能完成与 {name} 的断开连接,保存的连接资料可能仍在,请重试。',
'cloudSync.provider.webdav': 'WebDAV',
'cloudSync.provider.webdav.desc': '连接到自建 WebDAV 端点',
'cloudSync.provider.s3': 'S3 兼容存储',
'cloudSync.provider.s3.desc': '连接到 S3 兼容对象存储',
'cloudSync.provider.comingSoon': '即将支持',
'cloudSync.webdav.title': 'WebDAV 设置',
'cloudSync.webdav.desc': '配置 WebDAV 端点用于加密同步。',
'cloudSync.webdav.endpoint': '端点地址',
@@ -796,20 +745,6 @@ export const zhCNVaultMessages: Messages = {
'cloudSync.s3.allowInsecure': '允许不安全的连接(忽略证书错误)',
'cloudSync.s3.showSecret': '显示密钥',
'cloudSync.s3.validation.required': '端点、Region、Bucket、Access Key 与 Secret 必填。',
'cloudSync.smb.title': 'SMB 设置',
'cloudSync.smb.desc': '连接到 SMB/CIFS 文件共享以进行加密同步。',
'cloudSync.smb.share': '共享路径',
'cloudSync.smb.username': '用户名',
'cloudSync.smb.password': '密码',
'cloudSync.smb.domain': '域(可选)',
'cloudSync.smb.domainPlaceholder': '例如:WORKGROUP',
'cloudSync.smb.port': '端口(可选)',
'cloudSync.smb.showSecret': '显示密码',
'cloudSync.smb.validation.share': '共享路径必填。',
'cloudSync.smb.validation.port': '端口必须是 1 到 65535 之间的数字。',
'cloudSync.connect.smb.success': 'SMB 已连接',
'cloudSync.connect.smb.failedTitle': 'SMB 连接失败',
'cloudSync.provider.smb': 'SMB 共享',
'cloudSync.connect.webdav.success': 'WebDAV 已连接',
'cloudSync.connect.webdav.failedTitle': 'WebDAV 连接失败',
'cloudSync.connect.s3.success': 'S3 已连接',
@@ -826,7 +761,6 @@ export const zhCNVaultMessages: Messages = {
'cloudSync.lastSync.minutesAgo': '{minutes} 分钟前',
'cloudSync.changeKey': '更改 Key',
'cloudSync.providers.title': '云服务',
'cloudSync.syncAll': '同步所有已连接的服务',
'cloudSync.autoSync.title': '自动同步',
'cloudSync.autoSync.desc': '发生变更时自动同步',
'cloudSync.strategy.title': '同步策略',
@@ -891,7 +825,6 @@ export const zhCNVaultMessages: Messages = {
'cloudSync.localBackups.folderWarning': '仅复制此文件夹并不构成完整、可迁移的备份。删除或清空应用配置目录(userData)可能导致这些恢复点无法读取。',
'cloudSync.localBackups.retentionTitle': '备份保留数量',
'cloudSync.localBackups.retentionDesc': '设置 Netcatty 最多保留多少份本地备份。',
'cloudSync.localBackups.maxCount': '最多保留',
'cloudSync.localBackups.maxSaved': '已保存保留数量:{count}',
'cloudSync.localBackups.maxInvalid': '请输入 1 到 100 之间的数字。',
'cloudSync.localBackups.empty': '还没有本地备份。',
@@ -1021,7 +954,6 @@ export const zhCNVaultMessages: Messages = {
'sftp.context.openWithDefault': '系统默认程序打开',
'common.clear': '清除',
'common.optional': '可选',
'common.selectPlaceholder': '请选择...',
'common.error': '错误',
'common.validation': '验证',
'common.saveChanges': '保存修改',
@@ -1063,7 +995,6 @@ export const zhCNVaultMessages: Messages = {
'pf.tooltip.localDesc': '本地端口转发:通过 SSH 隧道访问远程服务',
'pf.tooltip.remoteDesc': '远程端口转发:将本地服务暴露给远程主机',
'pf.tooltip.dynamicDesc': '动态 SOCKS 代理:通过 SSH 隧道转发流量',
'pf.deleteActive.title': '删除正在运行的端口转发?',
'pf.deleteActive.desc': '端口转发规则 "{label}" 当前正在运行。删除前将先关闭转发连接。',
'pf.deleteActive.confirm': '关闭并删除',
'pf.form.autoStart': '自动启动',
@@ -1078,8 +1009,6 @@ export const zhCNVaultMessages: Messages = {
'sftp.pane.selectHostToStart': '先选择一个主机',
'sftp.pane.chooseFilesystem': '选择要浏览的本地或远端文件系统',
'sftp.tabs.addTab': '新建标签页',
'sftp.tabs.closeTab': '关闭标签页',
'sftp.tabs.newTab': '新标签页',
'sftp.tabs.copyDefaultPath': '复制标签页(默认路径)',
'sftp.tabs.copyCurrentPath': '复制并跳转到当前路径',
'sftp.conflict.title': '文件冲突',
@@ -1105,10 +1034,6 @@ export const zhCNVaultMessages: Messages = {
'sftp.conflict.action.replace': '替换',
// SFTP Upload Phases
'sftp.upload.phase.compressing': '正在压缩',
'sftp.upload.phase.uploading': '正在上传',
'sftp.upload.phase.extracting': '正在解压',
'sftp.upload.phase.compressed': '压缩传输',
'vault.import.plugins.title': '插件导入器',
'vault.import.plugins.loading': '正在生成安全导入预览…',
'vault.import.plugins.progress': '已处理 {completed}/{total} {message}',
+23 -7
View File
@@ -71,6 +71,9 @@ export const zhTWAiMessages: Messages = {
'ai.providers.apiKey': 'API Key',
'ai.providers.apiKey.placeholder': '輸入 API Key',
'ai.providers.apiKey.decrypting': '解密中...',
'ai.providers.opencodeGo.help': '貼上 OpenCode API Key 即可使用 OpenCode Go,Base URL 與模型清單會自動設定。',
'ai.providers.opencodeGo.getKey': '取得 API Key',
'ai.providers.fixedBaseUrl.help': '由提供商固定,Netcatty 會依模型自動選擇對應的介面路徑。',
'ai.providers.baseUrl': 'Base URL',
'ai.providers.baseUrl.anthropicHelp': 'Anthropic 相容:可填不帶或帶 /v1 的主機(例如 https://gateway.example 或 https://gateway.example/v1)。偵測與聊天都會請求 /v1/models、/v1/messages。',
'ai.providers.baseUrl.ollamaHelp': '本機 Ollama:http://localhost:11434/v1(不需 API Key)。Ollama Cloud:https://ollama.com/v1,並填寫 Cloud API Key。',
@@ -614,6 +617,23 @@ export const zhTWAiMessages: Messages = {
'ai.chat.rebindUsage': '用法:/rebind <序號>',
'ai.chat.rebindDone': '聊天「{title}」已重新綁定到此面板。',
'ai.chat.rebindUnavailable': '目前面板範圍內沒有可用的重新綁定目標。',
'ai.chat.managerScopeTab': '目前會話',
'ai.chat.managerAllChatsTab': '全部會話',
'ai.chat.managerSearchPlaceholder': '搜尋會話標題…',
'ai.chat.managerFilterAllAgents': '全部 Agent',
'ai.chat.managerMoreActions': '更多操作',
'ai.chat.managerOpen': '在此面板開啟',
'ai.chat.managerOpenDisabled': '正在其他工作區或終端中使用',
'ai.chat.managerRebind': '移動到…',
'ai.chat.managerRebindPick': '選擇目標終端或工作區…',
'ai.chat.managerRebindHere': '目前面板',
'ai.chat.managerRebindDone': '已將「{title}」移動到 {target}。',
'ai.chat.managerExportOne': '匯出此會話',
'ai.chat.managerBadgeActive': '使用中',
'ai.chat.managerBadgeIdle': '閒置',
'ai.chat.managerMessagesCount': '{n} 則訊息',
'ai.chat.managerDeleteTitle': '刪除此會話?',
'ai.chat.managerDeleteMessage': '「{title}」及其訊息將從所有面板中移除,且無法復原。',
'ai.chat.justNow': '剛剛',
'ai.chat.minutesAgo': '{n}分鐘前',
'ai.chat.hoursAgo': '{n}小時前',
@@ -701,6 +721,9 @@ export const zhTWAiMessages: Messages = {
'ai.safety.responseIdleTimeout.unit': '秒',
'ai.safety.maxIterations': '最大迭代次數',
'ai.safety.maxIterations.description': '防止 AI 失控執行的最大工具呼叫迴圈次數。外部 Agent 可能有自己的內部迭代限制,以其為準。',
'ai.safety.toolOutputMaxChars': '內建 AI 工具輸出上限',
'ai.safety.toolOutputMaxChars.description': '內建 AI 單次工具呼叫(例如終端機指令或 SFTP 讀取)直接傳回的最大字元數,超出時會截斷並將完整輸出儲存為可讀取的控制碼(2,000–200,000)。',
'ai.safety.toolOutputMaxChars.unit': '字元',
'ai.safety.blocklist': '指令黑名單',
'ai.safety.blocklist.description': '用於攔截透過 Netcatty 執行的危險指令的正規表示式。',
'ai.safety.blocklist.placeholder': '正規表示式...',
@@ -731,9 +754,6 @@ export const zhTWAiMessages: Messages = {
'terminal.layer.theme': '主題',
'terminal.layer.notes': '筆記',
'terminal.layer.aiChat': 'AI 助手',
'terminal.layer.movePanelLeft': '面板移至左側',
'terminal.layer.movePanelRight': '面板移至右側',
'terminal.layer.movePanelBottom': '面板移至底部',
'terminal.layer.choosePanelPosition': '變更位置',
'terminal.layer.dockLeft': '左側',
'terminal.layer.dockRight': '右側',
@@ -767,19 +787,15 @@ export const zhTWAiMessages: Messages = {
'terminal.layer.hostTree.details.protocol': '協定',
'terminal.layer.hostTree.details.group': '群組',
'terminal.layer.hostTree.details.tags': '標籤',
'terminal.layer.hostTree.details.lastConnected': '最近連線',
'topTabs.openQuickSwitcher': '開啟快速切換',
'topTabs.moreTabs': '更多分頁',
'topTabs.aiAssistant': 'AI 助手',
'topTabs.newLocalTerminal': '新增本機終端',
'topTabs.controlPanel': '快捷控制',
'topTabs.controlPanel.externalMcp': '對外 MCP',
'topTabs.controlPanel.theme': '主題',
'topTabs.controlPanel.theme.light': '淺色',
'topTabs.controlPanel.theme.dark': '深色',
'topTabs.controlPanel.theme.system': '系統',
'topTabs.externalMcp.enable': '啟用對外 MCP',
'topTabs.externalMcp.disable': '停用對外 MCP',
'topTabs.windowOpacity': '視窗透明度',
'topTabs.openSettings': '開啟設定',
'ai.chat.sessionHistory': '工作階段歷史',
+10 -37
View File
@@ -110,11 +110,9 @@ export const zhTWCoreMessages: Messages = {
'field.label': 'Label',
'field.type': '型別',
'auth.keyType': '型別 {type}',
'auth.showAllKeys': '顯示全部 keys',
// Dialogs / prompts
'confirm.deleteHost': '刪除主機 "{name}"?',
'confirm.deleteIdentity': '刪除身分 "{name}"?',
'confirm.removeProvider': '移除供應商 "{name}"?',
'confirm.closeBusyTerminal.title': '確認關閉',
'confirm.closeBusyTerminal.message': '行程 "{command}" 仍在執行,關閉後會被終止。',
@@ -407,7 +405,6 @@ export const zhTWCoreMessages: Messages = {
'tray.status.inactive': '未啟用',
'tray.status.error': '錯誤',
'tray.status.unknown': '未知',
'tray.recentHosts': '最近連線的主機',
'tray.empty.title': '一切都很安靜',
'tray.empty.subtitle': '去連線個伺服器吧,它們想念你了 🚀',
'tray.quit': '結束 Netcatty',
@@ -466,9 +463,6 @@ export const zhTWCoreMessages: Messages = {
'update.downloadFailed.message': '下載更新失敗,可前往 GitHub 手動下載。',
'update.needsSave.title': '有未儲存內容',
'update.needsSave.message': '請先儲存已開啟的編輯器,然後再次點選「立即重新啟動」以安裝更新。',
'update.openReleases': '開啟 Releases',
'update.remindLater': '稍後提醒',
'update.skipVersion': '跳過此版本',
// Settings > Appearance
'settings.appearance.uiTheme': '介面主題',
@@ -488,7 +482,7 @@ export const zhTWCoreMessages: Messages = {
'settings.appearance.themeColor.dark': '深色主題',
'settings.appearance.customCss': '自訂 CSS',
'settings.appearance.customCss.desc':
'使用自訂 CSS 個人化介面,修改會立即生效。選取的頂部分頁(`.top-tab[data-active="true"]`)會讀取 `--top-tab-active-bg`、`--top-tab-active-fg` 和 `--top-tab-active-border`。不設定則維持目前外觀。',
'使用自訂 CSS 個人化介面,修改會立即生效。',
'settings.appearance.customCss.help.ariaLabel': '自訂 CSS 說明',
'settings.appearance.customCss.help.title': '自訂 CSS 說明',
'settings.appearance.customCss.help.body': `主要 UI 區塊都公開了 \`data-section\` 屬性,供你用 CSS 定位。編輯後會立即生效。
@@ -651,8 +645,6 @@ Vaults 分頁維持扁平,不使用這塊背景。
'settings.appearance.appIcon.whiteViolet': '白底 · 紫羅蘭貓',
'settings.appearance.appIcon.rainbow': '彩虹貓',
// Context menus / common actions
'action.newHost': '新增主機',
'action.newSubfolder': '新增資料夾',
'action.copyPublicKey': '複製公鑰',
'action.keyExport': '匯出金鑰',
'action.edit': '編輯',
@@ -1034,13 +1026,9 @@ Vaults 分頁維持扁平,不使用這塊背景。
'sftp.columns.actions': '操作',
'sftp.sort.directoriesFirst': '資料夾置頂',
'sftp.emptyDirectory': '空目錄',
'sftp.nav.up': '返回上層',
'sftp.nav.home': '返回主目錄',
'sftp.nav.refresh': '重新整理',
'sftp.upload': '上傳',
'sftp.uploadFiles': '上傳檔案',
'sftp.uploadFolder': '上傳資料夾',
'sftp.dragDropToUpload': '拖曳檔案到這裡上傳',
'sftp.retry': '重試',
'sftp.context.open': '開啟',
'sftp.context.navigateTo': '跳轉到這裡',
@@ -1055,6 +1043,12 @@ Vaults 分頁維持扁平,不使用這塊背景。
'sftp.extract.extracting': '正在解壓 {fileName}...',
'sftp.extract.success': '已解壓 {fileName}',
'sftp.extract.error': '解壓 {fileName} 失敗:{error}',
'sftp.packedDownload.receiving': '正在接收封裝資料…',
'sftp.packedDownload.extracting': '正在還原檔案…',
'sftp.packedDownload.fallback': '目前無法打包下載,已改為逐檔下載。',
'sftp.packedDownload.selection': '已選取 {count} 個項目',
'sftp.packedDownload.conflict': '目的地已有同名項目,要選擇其他儲存位置嗎?',
'sftp.archive.action': '壓縮…',
'sftp.archive.title': '壓縮檔案',
'sftp.archive.description': '將 {count} 個選取項目打包成伺服器上的壓縮檔。',
@@ -1079,28 +1073,21 @@ Vaults 分頁維持扁平,不使用這塊背景。
'sftp.copyCurrentPath': '複製目前路徑',
'sftp.copyCurrentPath.success': '已複製目前路徑',
'sftp.copyCurrentPath.error': '無法複製目前路徑',
'sftp.viewMode.label': '檢視模式',
'sftp.viewMode.list': '列表檢視',
'sftp.viewMode.tree': '樹形檢視',
'sftp.viewMode.switchToList': '切換到列表檢視',
'sftp.viewMode.switchToTree': '切換到樹形檢視',
'sftp.listDensity.compact': '緊湊列表',
'sftp.listDensity.comfortable': '寬鬆列表',
'sftp.listDensity.switchToCompact': '切換到緊湊列表',
'sftp.listDensity.switchToComfortable': '切換到寬鬆列表',
'sftp.tree.loadError': '載入目錄失敗',
'sftp.tree.loading': '載入中...',
'sftp.kind.folder': '資料夾',
'sftp.context.rename': '重新命名',
'sftp.context.permissions': '權限',
'sftp.context.delete': '刪除',
'sftp.context.refresh': '重新整理',
'sftp.context.uploadFiles': '上傳檔案...',
'sftp.context.uploadFilesHere': '上傳檔案到這裡...',
'sftp.context.uploadFolder': '上傳資料夾...',
'sftp.context.uploadFolderHere': '上傳資料夾到這裡...',
'sftp.context.downloadSelected': '下載選取項({count})',
'sftp.context.deleteSelected': '刪除選取項({count})',
'sftp.dropFilesHere': '拖曳檔案到這裡',
'sftp.itemsCount': '{count} 個專案',
'sftp.selectedCount': '已選 {count} 個',
@@ -1109,8 +1096,6 @@ Vaults 分頁維持扁平,不使用這塊背景。
'sftp.task.waiting': '等待中...',
'sftp.transfer.preparing': '準備中...',
'sftp.status.loading': '載入中...',
'sftp.status.uploading': '上傳中...',
'sftp.status.ready': '就緒',
'sftp.transfers': '傳輸',
'sftp.transfers.active': '{count} 個進行中',
'sftp.transfers.clearCompleted': '清除已完成',
@@ -1173,7 +1158,6 @@ Vaults 分頁維持扁平,不使用這塊背景。
'sftp.transferCenter.applyAll': '套用到全部',
'sftp.transfers.resizeNameColumn': '調整檔名列寬',
'sftp.transfers.dragToResize': '拖曳調整高度',
'sftp.goUp': '上一級',
'sftp.goToTerminalCwd': '定位到終端目前目錄',
'sftp.locatePathInTerminal': '定位路徑到終端',
'sftp.followTerminalCwd': '追隨終端目錄',
@@ -1183,35 +1167,30 @@ Vaults 分頁維持扁平,不使用這塊背景。
'sftp.encoding.auto': '自動',
'sftp.encoding.utf8': 'UTF-8',
'sftp.encoding.gb18030': 'GB18030',
'sftp.goBack': '後退',
'sftp.goForward': '前進',
'sftp.goHome': '返回主目錄',
'sftp.goRoot': '回到根目錄',
'sftp.folderName': '資料夾名稱',
'sftp.folderName.placeholder': '輸入資料夾名稱',
'sftp.fileName': '檔案名稱',
'sftp.fileName.placeholder': '輸入檔案名稱',
'sftp.prompt.newFolderName': '新增資料夾名稱?',
'sftp.rename.title': '重新命名',
'sftp.rename.newName': '新名稱',
'sftp.rename.placeholder': '輸入新名稱',
'sftp.confirm.deleteOne': '刪除 "{name}"?',
'sftp.deleteConfirm.single': '刪除 "{name}"?',
'sftp.deleteConfirm.title': '刪除 {count} 個專案?',
'sftp.deleteConfirm.desc': '此操作不可復原,將刪除以下內容:',
'sftp.deleteConfirm.descSingle': '此操作不可復原。',
'sftp.deleteConfirm.host': '主機',
'sftp.deleteConfirm.path': '路徑',
'sftp.error.loadFailed': '載入目錄失敗',
'sftp.error.downloadFailed': '下載失敗',
'sftp.error.uploadFailed': '上傳失敗',
'sftp.error.deleteFailed': '刪除失敗',
'sftp.error.createFolderFailed': '建立資料夾失敗',
'sftp.error.createFileFailed': '建立檔案失敗',
'sftp.error.invalidFileName': '檔名包含非法字元:{chars}',
'sftp.error.reservedName': '此檔名是系統保留名稱',
'sftp.overwrite.title': '檔案已存在',
'sftp.overwrite.desc': '名為"{name}"的檔案已存在。是否要替換它?',
'sftp.overwrite.confirm': '替換',
'sftp.error.renameFailed': '重新命名失敗',
'sftp.picker.title': '選擇主機',
'sftp.picker.desc': '為{side}窗格選擇主機',
'sftp.picker.searchPlaceholder': '搜尋主機...',
@@ -1219,8 +1198,6 @@ Vaults 分頁維持扁平,不使用這塊背景。
'sftp.picker.local.desc': '瀏覽本機檔案',
'sftp.picker.local.badge': '本機',
'sftp.picker.connected.section': '已連線',
'sftp.picker.connected.badge': '已連線',
'sftp.picker.connected.connecting': '連線中',
'sftp.picker.noMatch': '沒有相符的主機',
'sftp.permissions.title': '編輯權限',
'sftp.permissions.owner': '擁有者',
@@ -1228,8 +1205,6 @@ Vaults 分頁維持扁平,不使用這塊背景。
'sftp.permissions.others': '其他',
'sftp.permissions.octal': '八進位制',
'sftp.permissions.symbolic': '符號',
'sftp.permissions.success': '權限已更新',
'sftp.permissions.failed': '權限更新失敗',
// Quick Switcher
'qs.search.placeholder': '搜尋主機或分頁',
@@ -1256,12 +1231,9 @@ Vaults 分頁維持扁平,不使用這塊背景。
"settings.plugins.manager.remove": "解除安裝",
"settings.plugins.manager.removeNote": "解除安裝會移除外掛代碼和本地 KV 資料,保留使用者設定、秘密儲存和同步 sidecar。",
"settings.plugins.permissions.statusUnknown": "狀態不明",
"plugins.sidebar.extensions": "擴充功能頁面",
"plugins.sidebar.selectTerminal": "請先選擇已開啟的終端。",
"plugins.sidebar.loading": "正在載入擴充功能頁面…",
"plugins.vault.loading": "正在載入擴充功能頁面…",
"plugins.vault.extensions": "擴充功能",
"plugins.vault.back": "返回主機",
"plugins.interaction.title": "外掛請求",
"plugins.interaction.sharing": "分享的文字會交給此外掛及其已授權能力(包括網路存取)。讀取文字不代表核准新的網路目的地。",
"plugins.interaction.input": "輸入文字",
@@ -1410,6 +1382,7 @@ Vaults 分頁維持扁平,不使用這塊背景。
'plugins.hostActions.selectionNote': '僅向此外掛分享所選主機的中繼資料:名稱、位址、使用者名稱、協定、群組和標籤。選擇群組僅包含本次選取的成員。後續編輯或連線請求遵循此外掛的權限設定。',
'plugins.hostActions.create': '預覽主機草稿',
'plugins.hostActions.edit': '預覽主機修改',
'plugins.hostActions.streamNote': '允許此外掛透過選定的 SSH 伺服器向以上位址與連接埠收發資料。位址由該伺服器解析,可能讀取或修改資料庫資料。不會開啟終端機或執行啟動腳本,SSH 密碼與私鑰不會交給外掛。請選擇 SSH 伺服器。',
'plugins.hostActions.connect': '確認連線',
'plugins.hostActions.fieldDiff': '即將儲存的修改',
'plugins.hostActions.defaultsWarning': '將套用已儲存的連線預設設定。修改群組可能改變繼承的驗證、代理和指令碼設定。',
-20
View File
@@ -1,6 +1,5 @@
export const zhTWScriptsMessages = {
'scripts.meta.name': '名稱',
'scripts.meta.language': '語言',
'scripts.meta.description': '描述',
'scripts.meta.descriptionPlaceholder': '可選,指令碼的簡要說明',
'scripts.meta.trigger': '觸發方式',
@@ -15,7 +14,6 @@ export const zhTWScriptsMessages = {
'scripts.actions.openEditor': '彈出視窗編輯',
'scripts.actions.openEditorHint': '在更大的視窗中編輯指令碼',
'scripts.editor.modalTitle': '指令碼編輯器',
'scripts.editor.modalSubtitle': '在更大的工作區中編輯指令碼的中繼資料與程式碼。',
'scripts.editor.lineCount': '{count} 行',
'scripts.editor.resize': '調整編輯器高度',
'scripts.targets.hint': '所選群組會動態比對,之後加入群組的主機也會自動生效。',
@@ -86,17 +84,13 @@ export const zhTWScriptsMessages = {
'scripts.dialog.retry': '重試',
'scripts.dialog.skip': '跳過',
'scripts.dialog.abort': '終止',
'scripts.running.stepProgress': '步驟 {current} / {total}',
'scripts.running.determinateProgress': '{label} {current}/{total}',
'scripts.running.progressFallback': '進度',
'scripts.running.operationsCount': '已執行 {count} 個操作',
'scripts.running.opsPrefix': '已執行 ',
'scripts.running.opsSuffix': ' 個操作',
'scripts.running.elapsedLabel': '耗時',
'scripts.running.lastSentLabel': '已傳送:',
'scripts.running.elapsed': '耗時 {elapsed}',
'scripts.running.completedSummary': '已完成 · 共 {count} 個操作 · {elapsed}',
'scripts.running.dismissHint': '點選關閉',
'scripts.running.dismiss': '關閉',
'scripts.running.viewLogs': '檢視日誌',
'scripts.running.logTitle': '{name} · 執行日誌',
@@ -111,26 +105,12 @@ export const zhTWScriptsMessages = {
'vault.nav.scripts': '指令碼',
'snippets.action.newScript': '新增自動化指令碼',
'hostDetails.section.automation': '自動化',
'hostDetails.automation.loginScript': '登入指令碼',
'hostDetails.automation.loginScriptPlaceholder': '選擇指令碼',
'hostDetails.automation.none': '無',
'hostDetails.automation.outputTriggers': '輸出觸發器',
'hostDetails.automation.addTrigger': '新增觸發器',
'hostDetails.automation.triggerPatternPlaceholder': '正規表示式',
'hostDetails.automation.linkedScripts': '已關聯指令碼',
'hostDetails.automation.linkedScriptsEmpty': '尚未關聯任何指令碼。',
'hostDetails.automation.linkScriptPlaceholder': '關聯既有指令碼…',
'hostDetails.automation.unlink': '取消關聯',
'hostDetails.automation.equivalenceHint': '此處關聯會將本主機加入 Scripts 中該指令碼的目標列表,兩側檢視同步。',
'hostDetails.automation.queueHint': '連線本主機時依序執行指令碼。全域指令碼最先執行,再執行下方佇列。',
'hostDetails.automation.globalScripts': '全域連線指令碼',
'hostDetails.automation.globalScriptsHint': '每次連線時最先執行。順序在指令碼庫排序中調整。',
'hostDetails.automation.connectQueue': '本主機執行佇列',
'hostDetails.automation.connectQueueEmpty': '尚未為本主機設定連線指令碼佇列。',
'hostDetails.automation.addToQueuePlaceholder': '新增指令碼到佇列…',
'hostDetails.automation.moveUp': '上移',
'hostDetails.automation.moveDown': '下移',
'hostDetails.automation.removeFromQueue': '從佇列移除',
'hostDetails.automation.dragHandle': '拖曳排序',
'hostDetails.automation.queueDragHint': '拖動項目即可調整連線時的執行順序。',
};
@@ -14,13 +14,11 @@ export const zhTwSystemManagerMessages: Messages = {
'systemManager.tabs.docker': 'Docker',
'systemManager.tabs.gpu': 'GPU',
'systemManager.tabs.ariaLabel': '系統管理分區',
'systemManager.popup.loading': '正在開啟終端…',
'systemManager.popup.startupFailed': '啟動指令未順利完成。請確認目標仍可使用後再試一次。',
'systemManager.errors.loadProcesses': '載入行程列表失敗',
'systemManager.errors.loadTmux': '載入 tmux 工作階段失敗',
'systemManager.errors.loadTmuxWindows': '載入 tmux 視窗失敗',
'systemManager.errors.loadTmuxPanes': '載入 tmux 窗格失敗',
'systemManager.errors.loadTmuxClients': '載入 tmux 用戶端失敗',
'systemManager.errors.actionFailed': '操作失敗',
'systemManager.errors.loadDocker': '載入容器列表失敗',
@@ -31,7 +29,6 @@ export const zhTwSystemManagerMessages: Messages = {
'systemManager.errors.nerdctlUnreachable': 'nerdctl 無法連線到 containerd',
'systemManager.errors.clusterUnreachable': '無法連到內容 {{context}} 的叢集',
'systemManager.errors.clusterUnreachableGeneric': '無法連到叢集',
'systemManager.errors.loadOverview': '載入系統概覽失敗',
'systemManager.errors.loadGpu': '載入 GPU / NPU 狀態失敗',
'systemManager.errors.loadPorts': '載入監聽連接埠失敗',
'systemManager.errors.loadServices': '載入 systemd 服務失敗',
@@ -65,13 +62,10 @@ export const zhTwSystemManagerMessages: Messages = {
'systemManager.overview.noTopProcesses': '暫無行程資料',
'systemManager.processes.search': '搜尋行程…',
'systemManager.processes.command': '指令',
'systemManager.processes.user': '使用者',
'systemManager.processes.term': '終止',
'systemManager.processes.kill': '強制終止',
'systemManager.processes.stop': '暫停 (SIGSTOP)',
'systemManager.processes.cont': '繼續 (SIGCONT)',
'systemManager.processes.hup': '掛斷 (SIGHUP)',
'systemManager.processes.renice': '調整優先順序',
'systemManager.processes.renicePrompt': 'Nice 值 (-20 到 19)',
'systemManager.processes.reniceInvalid': 'Nice 值必須在 -20 到 19 之間',
@@ -86,7 +80,6 @@ export const zhTwSystemManagerMessages: Messages = {
'systemManager.processes.stat': '狀態',
'systemManager.processes.meta': '{{count}} 個行程',
'systemManager.processes.loading': '正在載入行程…',
'systemManager.processes.loadingMore': '正在載入更多行程…',
'systemManager.processes.state.running': '執行中',
'systemManager.processes.state.sleeping': '睡眠',
'systemManager.processes.state.stopped': '已暫停',
@@ -124,12 +117,9 @@ export const zhTwSystemManagerMessages: Messages = {
'systemManager.tmux.attached': '已附加',
'systemManager.tmux.detached': '未附加',
'systemManager.tmux.windows': '{{count}} 個視窗',
'systemManager.tmux.created': '建立時間',
'systemManager.tmux.activity': '活動時間',
'systemManager.tmux.rename': '重新命名',
'systemManager.tmux.detach': '全部分離',
'systemManager.tmux.killSession': '結束工作階段',
'systemManager.tmux.killServer': '結束 tmux 伺服器',
'systemManager.tmux.loadingDetails': '正在載入詳情…',
'systemManager.tmux.clients': '已附加用戶端',
'systemManager.tmux.windowList': '視窗',
@@ -140,31 +130,17 @@ export const zhTwSystemManagerMessages: Messages = {
'systemManager.docker.unavailable': '此主機未偵測到容器執行環境(Docker、Podman、nerdctl 或 kubectl)',
'systemManager.tmux.windowsMismatch': '工作階段顯示有 {{count}} 個視窗,但 list-windows 未傳回任何視窗',
'systemManager.tmux.lastCommand': '最後執行的指令:{{command}}',
'systemManager.tmux.noPanes': '沒有窗格',
'systemManager.tmux.panes': '{{count}} 個窗格',
'systemManager.tmux.active': '使用中',
'systemManager.tmux.unnamedWindow': '未命名視窗',
'systemManager.tmux.unnamedPane': '未命名窗格',
'systemManager.tmux.attachWindow': '附加到視窗',
'systemManager.tmux.selectWindow': '選擇視窗',
'systemManager.tmux.killWindow': '關閉視窗',
'systemManager.tmux.killPane': '關閉窗格',
'systemManager.tmux.splitHorizontal': '水平分割',
'systemManager.tmux.splitVertical': '垂直分割',
'systemManager.tmux.sendKeys': '傳送按鍵',
'systemManager.tmux.sendKeysTo': '向視窗 {{window}} 窗格 {{pane}} 傳送按鍵',
'systemManager.tmux.sendKeysPlaceholder': '指令或文字…',
'systemManager.tmux.renameSessionPrompt': '重新命名工作階段',
'systemManager.tmux.renameWindowPrompt': '重新命名視窗',
'systemManager.tmux.windowName': '視窗名稱',
'systemManager.tmux.confirmKillSession': '確定結束 tmux 工作階段「{{name}}」?',
'systemManager.tmux.confirmDetachSession': '確定將所有用戶端從「{{name}}」分離?',
'systemManager.tmux.confirmKillWindow': '確定關閉視窗「{{name}}」?',
'systemManager.tmux.confirmKillPane': '確定關閉窗格 #{{index}}?',
'systemManager.tmux.confirmKillServer': '確定結束 tmux 伺服器?所有工作階段將被終止。',
'systemManager.tmux.meta': '{{count}} 個工作階段',
'systemManager.docker.title': '容器',
'systemManager.docker.subTabs.containers': '容器',
'systemManager.docker.subTabs.images': '映像',
'systemManager.docker.empty': '未找到容器',
@@ -177,7 +153,6 @@ export const zhTwSystemManagerMessages: Messages = {
'systemManager.docker.filter.paused': '已暫停',
'systemManager.docker.shell': 'Shell',
'systemManager.docker.logs': '日誌',
'systemManager.docker.details': '詳情',
'systemManager.docker.inspect': 'Inspect',
'systemManager.docker.imageInspect': '映像 Inspect',
'systemManager.docker.confirmRemove': '確定刪除此容器?',
+24 -74
View File
@@ -12,6 +12,10 @@ export const zhTWTerminalMessages: Messages = {
'terminal.directory.hidden': '顯示隱藏目錄',
'terminal.directory.refresh': '重新整理',
'terminal.directory.unavailable': '此工作階段暫不支援目錄導覽。',
'terminal.directory.integrationUnavailable': 'PowerShell 目錄整合尚未就緒,啟動參數或執行原則可能阻止載入。',
'terminal.directory.cmdIntegrationUnavailable': '正在等待原 CMD 工作階段回報目前目錄。',
'terminal.directory.nonFilesystem': '目前 PowerShell 位置不是檔案系統目錄。',
'terminal.directory.accessDenied': '沒有權限列出此目錄。',
'terminal.directory.busy': '請等待終端回到空白命令提示字元。',
'terminal.directory.readFailed': '無法讀取此目錄,請重新整理後重試。',
'terminal.directory.changeFailed': '未能確認目錄切換,請重新整理後重試。',
@@ -57,7 +61,6 @@ export const zhTWTerminalMessages: Messages = {
'terminal.osc7Setup.title': '設定目錄追蹤',
'terminal.osc7Setup.desc': 'Netcatty 會為目前遠端使用者新增 OSC 7 提示字元設定。這樣在 sudo 或 su 之後,SFTP 也能繼續跟隨終端目錄。',
'terminal.osc7Setup.targets': '可能寫入的檔案',
'terminal.osc7Setup.command': '將執行的指令',
'terminal.osc7Setup.run': '執行設定',
'terminal.osc7Setup.running': '正在設定...',
'terminal.osc7Setup.configured': '目錄追蹤已設定',
@@ -96,39 +99,23 @@ export const zhTWTerminalMessages: Messages = {
'history.clearAll.dialog.confirm': '全部清空',
// SFTP File Opener
'sftp.context.copyPath': '複製檔案路徑',
'sftp.context.insertPathToTerminal': '插入路徑到終端機',
'sftp.context.cdInTerminal': '在終端機中開啟 (cd)',
'sftp.terminal.insertBlockedUnsafeQuote': '終端機游標位於未閉合的引號或跳脫字元內,無法安全插入路徑',
'sftp.context.openWith': '開啟方式...',
'sftp.context.edit': '編輯',
'sftp.context.preview': '預覽',
'sftp.opener.title': '開啟方式',
'sftp.opener.desc': '選擇一個應用程式來開啟此檔案',
'sftp.opener.builtInEditor': '內建編輯器',
'sftp.opener.editDescription': '編輯文字檔案',
'sftp.opener.builtInImageViewer': '內建圖片預覽',
'sftp.opener.previewDescription': '預覽圖片',
'sftp.opener.systemApp': '選擇應用程式...',
'sftp.opener.systemAppDescription': '從本機選擇一個應用程式',
'sftp.opener.onlySystemApp': '此檔案只能用外部應用程式開啟',
'sftp.opener.noAppsAvailable': '無可用應用程式',
'sftp.opener.noExtension': '無副檔名檔案',
'sftp.opener.setDefault': '始終使用此方式開啟 {ext} 檔案',
'sftp.opener.confirmTitle': '設為預設?',
'sftp.opener.confirmDescription': '是否始終使用 {app} 開啟 {ext} 檔案?',
'sftp.opener.yesRemember': '是,記住此選擇',
'sftp.opener.justOnce': '僅此一次',
'sftp.opener.confirm.title': '設定預設應用程式',
'sftp.opener.confirm.desc': '是否始終使用此應用程式開啟 .{ext} 檔案?',
'sftp.editor.title': '文字編輯器',
'sftp.editor.save': '儲存到遠端',
'sftp.editor.saving': '儲存中...',
'sftp.editor.saved': '儲存成功',
'sftp.editor.saveFailed': '儲存檔案失敗',
'sftp.editor.unsavedChanges': '你有未儲存的更改。確定要關閉嗎?',
'sftp.editor.syntaxHighlight': '語法標示',
'sftp.preview.title': '圖片預覽',
'sftp.preview.zoomIn': '放大',
'sftp.preview.zoomOut': '縮小',
'sftp.preview.resetZoom': '重設縮放',
'sftp.preview.fitToWindow': '適應視窗',
// Settings > SFTP File Associations
'settings.tab.sftpFileAssociations': 'SFTP',
@@ -208,28 +195,16 @@ export const zhTWTerminalMessages: Messages = {
'sftp.autoSync.error': '同步檔案失敗:{error}',
// SFTP Folder Upload Progress
'sftp.upload.progress': '正在上傳 {current}/{total} 個檔案...',
'sftp.upload.uploading': '正在上傳...',
'sftp.upload.compressing': '正在壓縮...',
'sftp.upload.extracting': '正在解壓...',
'sftp.upload.scanning': '正在掃描檔案...',
'sftp.upload.completed': '已完成',
'sftp.upload.compressed': '壓縮傳輸',
'sftp.upload.currentFile': '目前: {fileName}',
'sftp.upload.cancelled': '上傳已取消',
'sftp.upload.noFiles': '沒有可上傳的檔案',
'sftp.upload.partialSuccess': '已上傳 {success} 個檔案,{failed} 個失敗',
'sftp.upload.cancel': '取消',
'sftp.upload.completedToPath': '已上傳至 {path}',
// SFTP Download
'sftp.download.completed': '已下載',
'sftp.download.cancelled': '下載已取消',
// SFTP Reconnecting
'sftp.reconnecting.title': '正在重連...',
'sftp.reconnecting.desc': '連線已斷開,正在嘗試重新連線',
'sftp.reconnected': '連線已恢復',
'sftp.error.reconnectFailed': '重連失敗,請重試。',
'sftp.error.connectionLostManual': '連線已斷開,請手動重新連線。',
'sftp.error.connectionLostReconnecting': '連線已斷開,正在重連...',
@@ -247,6 +222,17 @@ export const zhTWTerminalMessages: Messages = {
'settings.sftp.compressedUpload.enable': '啟用資料夾壓縮',
'settings.sftp.compressedUpload.enableDesc': '自動使用 tar 壓縮資料夾後再傳輸。需要伺服器支援 tar 指令,不支援時自動改用一般傳輸。',
'settings.sftp.packedDownload': '打包下載',
'settings.sftp.packedDownload.enable': '下載資料夾或多個項目時打包',
'settings.sftp.packedDownload.enableDesc': '一次傳回所選內容,並在本機自動還原原本的資料夾結構。若伺服器不支援打包,會自動逐檔下載。',
'settings.sftp.downloadLocation': '下載位置',
'settings.sftp.downloadLocation.directory': '預設下載資料夾',
'settings.sftp.downloadLocation.directoryDesc': '下載 SFTP 檔案時,儲存對話框預設開啟此資料夾。未設定或資料夾已不存在時,使用系統「下載」資料夾。',
'settings.sftp.downloadLocation.systemDefault': '系統「下載」資料夾',
'settings.sftp.downloadLocation.browse': '瀏覽…',
'settings.sftp.downloadLocation.reset': '恢復為系統「下載」資料夾',
'settings.sftp.downloadLocation.select': '選擇預設下載資料夾',
'settings.sftp.skipUnchanged.enable': '跳過未改檔案',
'settings.sftp.skipUnchanged.enableDesc': '當目標檔案的大小與修改時間已與來源一致時跳過傳輸(類似 rsync)。替換到暫存路徑時自動停用。',
@@ -489,7 +475,9 @@ export const zhTWTerminalMessages: Messages = {
'settings.terminal.connection.defaultProxy.desc': '主機沒有單獨設定、也沒有從群組繼承代理時使用的已儲存代理。選擇「無」則直接連線。',
'settings.terminal.connection.defaultProxy.none': '無',
'settings.terminal.connection.sshAutoReconnectEnabled': 'SSH 斷線後自動重連',
'settings.terminal.connection.sshAutoReconnectEnabled.desc': '開啟後,已連上的 SSH 工作階段意外斷開時會每 5 秒嘗試重新連線,直到關閉分頁或連線恢復。',
'settings.terminal.connection.sshAutoReconnectEnabled.desc': '開啟後,SSH 工作階段意外斷開時會按設定間隔嘗試重新連線,直到關閉分頁或連線恢復。',
'settings.terminal.connection.sshAutoReconnectInterval': 'SSH 重連間隔(秒)',
'settings.terminal.connection.sshAutoReconnectInterval.desc': '自動重連嘗試之間的等待時間:5–3600 秒,預設 5 秒。修改從下次安排重試時生效,不改變已開始的等待。',
'settings.terminal.connection.keepaliveInterval': '工作階段保持間隔',
'settings.terminal.connection.keepaliveInterval.desc': '向伺服器傳送 SSH 保活資料包的頻率(秒)。設為 0 表示全域停用——單個主機可在自己的設定裡覆蓋此值。',
'settings.terminal.connection.keepaliveCountMax': '最大無回應保活次數',
@@ -614,6 +602,7 @@ export const zhTWTerminalMessages: Messages = {
'settings.shortcuts.binding.close-tab': '關閉分頁',
'settings.shortcuts.binding.close-session': '關閉工作階段窗格',
'settings.shortcuts.binding.new-tab': '新增本機分頁',
'settings.shortcuts.binding.reopen-closed-tab': '重新開啟關閉的分頁',
'settings.shortcuts.binding.copy': '從終端複製',
'settings.shortcuts.binding.paste': '貼上到終端',
'settings.shortcuts.binding.paste-selection': '將選區貼上到終端',
@@ -661,7 +650,6 @@ export const zhTWTerminalMessages: Messages = {
'hostDetails.proxyPanel.credentials': '憑證',
'hostDetails.proxyPanel.usernamePlaceholder': '使用者名稱',
'hostDetails.proxyPanel.passwordPlaceholder': '密碼',
'hostDetails.proxyPanel.identities': '身分',
'hostDetails.proxyPanel.keychainIdentity': '鑰匙串身分',
'hostDetails.proxyPanel.manualCredentials': '手動憑證',
'hostDetails.proxyPanel.remove': '移除代理',
@@ -682,8 +670,6 @@ export const zhTWTerminalMessages: Messages = {
'hostDetails.envVars.newVariable': '新變數',
'hostDetails.envVars.variableName': '變數名',
'hostDetails.chain.title': '編輯鏈路',
'hostDetails.chain.desc': '新增另一台主機將建立到 {host} 的連線。',
'hostDetails.chain.addHost': '新增主機',
'hostDetails.chain.target': '目標',
'hostDetails.chain.availableHosts': '可用主機',
'hostDetails.chain.clear': '清空',
@@ -695,10 +681,7 @@ export const zhTWTerminalMessages: Messages = {
'hostDetails.group.addProtocol': '新增協定',
// Keychain
'keychain.filter.key': '金鑰',
'keychain.filter.certificate': '憑證',
'keychain.action.generateKey': '產生金鑰',
'keychain.action.importKey': '匯入金鑰',
'keychain.action.newIdentity': '新增身分',
'keychain.action.importCertificate': '匯入憑證',
'keychain.view.grid': '網格',
@@ -739,20 +722,8 @@ export const zhTWTerminalMessages: Messages = {
'keychain.export.exporting': '匯出中...',
'keychain.export.exportAndAttach': '匯出並繫結',
'keychain.export.title': '金鑰匯出',
'keychain.export.exportToRequired': '匯出到 *',
'keychain.export.selectHostPlaceholder': '選擇主機...',
'keychain.export.locationLabel': '位置 ~ $1 *',
'keychain.export.filenameLabel': '檔名 ~ $2 *',
'keychain.export.advanced': '高階',
'keychain.export.note.supportsOnly': '金鑰匯出目前僅支援',
'keychain.export.note.systems': '系統。',
'keychain.export.note.use': '請使用',
'keychain.export.note.customize': '部分自訂匯出指令碼。',
'keychain.export.scriptRequired': '指令碼 *',
'keychain.export.exportToHost': '匯出到主機',
'keychain.export.failedGeneric': '匯出失敗:{message}',
'keychain.field.label': '名稱',
'keychain.field.labelRequired': '名稱 *',
'keychain.field.labelPlaceholder': '金鑰 Label',
'keychain.field.privateKeyRequired': '私鑰 *',
'keychain.field.publicKey': '公鑰',
@@ -788,13 +759,9 @@ export const zhTWTerminalMessages: Messages = {
"fido.recovery.usePassword": "改用已設定的密碼",
"fido.recovery.passwordFallback": "正在使用此主機已設定的密碼登入",
"fido.prompt.cancelled": "已取消安全金鑰驗證。",
'fido.prompt.touchDone': '已觸摸',
'fido.prompt.timeout': 'FIDO 提示已逾時,請重新連線。',
'fido.error.opensshMissing': '需要支援 FIDO/libfido2 的 OpenSSH。macOS:brew install openssh libfido2。',
'fido.error.agentUnavailable': '無法啟動支援 FIDO 的 SSH agent。',
'keychain.generate.resident': '在裝置上儲存憑證',
'keychain.generate.verifyRequired': '每次驗證 PIN',
'keychain.action.loadResident': '從安全金鑰載入駐留金鑰',
'keychain.generate.keySize': '金鑰長度',
'keychain.generate.labelPlaceholder': '金鑰 Label',
'keychain.generate.passphrasePlaceholder': 'Passphrase(可選)',
@@ -804,7 +771,6 @@ export const zhTWTerminalMessages: Messages = {
'keychain.import.dropHint': '將金鑰檔案拖到這裡',
'keychain.import.importFromFile': '從檔案匯入',
'keychain.import.saveKey': '儲存金鑰',
'keychain.import.importedKeyLabel': '已匯入金鑰',
'keychain.identity.usernameRequired': '使用者名稱 *',
'keychain.identity.method.passwordOnly': '密碼',
'keychain.identity.summary.password': '認證密碼',
@@ -813,14 +779,8 @@ export const zhTWTerminalMessages: Messages = {
'keychain.identity.summary.passwordAndKey': '認證密碼與金鑰',
'keychain.identity.summary.passwordAndCertificate': '認證密碼與憑證',
'keychain.identity.summary.none': '無憑證',
'keychain.identity.selectCredential': '選擇{kind}',
'keychain.identity.save': '儲存',
'keychain.identity.update': '更新',
'keychain.keyDialog.newTitle': '新增金鑰',
'keychain.keyDialog.newDesc': '新增新的 SSH 金鑰',
'keychain.keyDialog.editTitle': '編輯金鑰',
'keychain.keyDialog.editDesc': '更新此 SSH 金鑰',
'keychain.keyDialog.updateKey': '更新金鑰',
// Tabs
'tabs.closeSessionAria': '關閉工作階段',
@@ -832,6 +792,8 @@ export const zhTWTerminalMessages: Messages = {
'tabs.duplicateSession': '複製工作階段',
'tabs.copyTabToNewWindow': '複製分頁到新視窗',
'tabs.copyTabToNewWindowFailed': '無法在新視窗開啟分頁',
'tabs.moveTabToNewWindow': '移動分頁到新視窗',
'tabs.moveTabToNewWindowFailed': '無法將分頁移動到新視窗',
'tabs.closeOthers': '關閉其他分頁',
'tabs.closeToLeft': '關閉左側分頁',
'tabs.closeToRight': '關閉右側分頁',
@@ -891,8 +853,6 @@ export const zhTWTerminalMessages: Messages = {
'snippets.targets.allHosts': '對所有主機生效',
'snippets.targets.allHostsShort': '所有主機',
'snippets.targets.allHostsActive': '將作用於所有可連線的主機。',
'snippets.kind.codeSnippet': '程式碼片段',
'snippets.kind.automationScript': '自動化指令碼',
'snippets.search.noResults.title': '無相符結果',
'snippets.search.noResults.desc': '沒有程式碼片段或程式碼包與"{query}"相符。換一個關鍵字,或清除搜尋進行瀏覽。',
'snippets.section.packages': '程式碼包',
@@ -928,9 +888,6 @@ export const zhTWTerminalMessages: Messages = {
'snippets.import.modal.multipleFiles': '已選擇 {count} 個檔案',
'snippets.import.modal.parsedSummary': '{files} 個檔案,{total} 個程式碼片段,{packages} 個程式碼包,{conflicts} 個重複指令。主機繫結會被忽略。',
'snippets.import.modal.confirm': '確認匯入',
'snippets.import.conflict.title': '匯入程式碼片段?',
'snippets.import.conflict.desc': '“{file}”包含 {total} 個程式碼片段,其中 {conflicts} 個指令已存在。',
'snippets.import.conflict.hostBindingsNote': '程式碼片段的主機繫結不會被匯入或匯出。',
'snippets.import.conflict.skip': '跳過重複項',
'snippets.import.conflict.overwrite': '覆蓋重複項',
'snippets.packageDialog.title': '新增程式碼包',
@@ -989,9 +946,6 @@ export const zhTWTerminalMessages: Messages = {
'serial.field.customPort': '自訂序列埠路徑',
'serial.field.namedPipeHint': 'Windows 虛擬機主控台:輸入 \\\\.\\pipe\\name。虛擬機需作為伺服器端建立管道,鮑率與串口框架設定不生效。',
'serial.field.customPortPlaceholder': '例如 /dev/ttys001 或 COM1',
'serial.type.hardware': '硬體',
'serial.type.pseudo': '虛擬終端',
'serial.type.custom': '自訂',
'serial.parity.none': '無',
'serial.parity.even': '偶同位',
'serial.parity.odd': '奇同位',
@@ -1012,7 +966,6 @@ export const zhTWTerminalMessages: Messages = {
'serial.backspace.default': '預設(DEL,0x7F)',
'serial.backspace.ctrlH': 'Ctrl+H(BS,0x08)',
'serial.field.charset': '字元編碼',
'serial.connectionError': '連線序列埠失敗',
'serial.field.baudRatePlaceholder': '選擇或輸入鮑率...',
'serial.field.baudRateEmpty': '輸入自訂鮑率',
'serial.field.customBaudRate': '使用自訂鮑率',
@@ -1031,10 +984,7 @@ export const zhTWTerminalMessages: Messages = {
'keyboard.interactive.title': '需要驗證',
'keyboard.interactive.desc': '伺服器需要額外的身分驗證。',
'keyboard.interactive.descWithHost': '伺服器 {hostname} 需要額外的身分驗證。',
'keyboard.interactive.response': '回應',
'keyboard.interactive.verificationCode': '驗證碼',
'keyboard.interactive.enterCode': '輸入驗證碼',
'keyboard.interactive.enterResponse': '輸入回應',
'keyboard.interactive.submit': '送出',
'keyboard.interactive.verifying': '驗證中...',
'keyboard.interactive.savePassword': '儲存密碼',
+2 -77
View File
@@ -19,14 +19,6 @@ export const zhTWVaultMessages: Messages = {
'notes.export.toast.failed': '匯出筆記失敗。',
'notes.codeBlock.copied': '已複製',
'notes.codeBlock.copyFailed': '複製程式碼塊失敗。',
'notes.group.prompt': '資料夾路徑',
'notes.group.all': '筆記本',
'notes.group.ungrouped': '未群組',
'notes.section.notebooks': '筆記本',
'notes.section.notes': '筆記',
'notes.mode.edit': '編輯',
'notes.mode.split': '分割',
'notes.mode.preview': '預覽',
'notes.title.placeholder': '筆記標題',
'notes.editor.placeholder': '在這裡寫 Markdown 筆記...',
'notes.editor.unrenderableMarkdown': '這篇筆記包含富文本編輯器無法顯示的 Markdown(例如未閉合的 <tag> 文字),已改為顯示原始 Markdown 原始碼,內容並沒有遺失。',
@@ -72,25 +64,18 @@ export const zhTWVaultMessages: Messages = {
'notes.toolbar.divider': '分隔線',
'notes.toolbar.link': '插入超連結',
'notes.toolbar.image': '插入圖片',
'notes.action.pin': '置頂筆記',
'notes.action.unpin': '取消置頂',
'notes.tag.remove': '移除標籤',
'notes.tag.placeholder': '標籤名...',
'notes.tag.add': '新增標籤',
'notes.outline.title': '大綱目錄',
'notes.outline.titleWithCount': '大綱目錄 ({count})',
'notes.outline.empty': '暫無標題大綱',
'notes.outline.emptyHint': '在 Markdown 中使用 #、## 編寫各級標題',
'notes.export.share': '匯出與分享',
'notes.export.currentNote': '目前筆記',
'notes.export.exportMarkdown': '匯出為 Markdown (.md)',
'notes.export.exportHtml': '匯出為 HTML (.html)',
'notes.export.copyMarkdown': '複製 Markdown 源碼',
'notes.export.allNotes': '全部筆記',
'notes.export.exportAllZip': '匯出全部為 ZIP 壓縮包',
'notes.export.toast.markdownSuccess': '已匯出 Markdown 檔案',
'notes.export.toast.htmlSuccess': '已匯出 HTML 檔案',
'notes.export.toast.zipSuccess': '已匯出全部筆記備份 ZIP',
// Select Host panel
'selectHost.title': '選擇主機',
@@ -130,12 +115,6 @@ export const zhTWVaultMessages: Messages = {
'hostDetails.title.new': '新增主機',
'hostDetails.saveAria': '儲存',
'hostConnectionTest.title': '測試連線',
'hostConnectionTest.test': '測試',
'hostConnectionTest.chainOf': '第 {current}/{total} 跳',
'hostConnectionTest.success': '連線成功',
'hostConnectionTest.successHint': '主機已接受您的憑證。您可以關閉此視窗。',
'hostConnectionTest.connecting': '正在連線… {seconds} 秒後逾時',
'hostConnectionTest.failed': '連線失敗。',
'hostConnectionTest.retry': '重試',
'hostConnectionTest.credentialsUnavailable': '儲存的憑證無法在此裝置上解密。請在下方重新輸入。',
'hostDetails.section.address': '位址',
@@ -172,11 +151,8 @@ export const zhTWVaultMessages: Messages = {
'hostDetails.notes.toggle.show': '顯示備註編輯框',
'hostDetails.notes.toggle.hide': '隱藏備註編輯框',
'hostDetails.group.placeholder': '父級 Group',
'hostDetails.section.credentials': '憑證',
'hostDetails.section.portCredentials': '埠與憑證',
'hostDetails.section.appearance': '外觀',
'hostDetails.distro.title': 'Linux 發行版',
'hostDetails.distro.desc': '可在連線後自動探測,也可以手動覆蓋圖示所用的發行版。',
'hostDetails.icon.title': '主機圖示',
'hostDetails.icon.preview': '圖示預覽',
'vault.panel.resizeWidth': '調整面板寬度',
@@ -190,7 +166,6 @@ export const zhTWVaultMessages: Messages = {
'hostDetails.icon.mode.custom': '自訂',
'hostDetails.icon.reset': '重設主機圖示',
'hostDetails.icon.colorLabel': '圖示顏色',
'hostDetails.icon.colorDefault': '預設',
'hostDetails.icon.colorAuto': '自動',
'hostDetails.icon.colorManual': '手動',
'hostDetails.icon.colorChoice': '顏色',
@@ -240,7 +215,6 @@ export const zhTWVaultMessages: Messages = {
'hostDetails.distro.mode.auto': '自動探測',
'hostDetails.distro.mode.manual': '手動覆蓋',
'hostDetails.distro.detectedLabel': '目前值',
'hostDetails.distro.manualLabel': '手動指定',
'hostDetails.distro.pending': '首次連線後自動探測',
'hostDetails.distro.unknown': '未知',
'hostDetails.distro.option.linux': '通用 Linux',
@@ -291,7 +265,6 @@ export const zhTWVaultMessages: Messages = {
'hostDetails.auth.mfaFirst': '優先互動式驗證',
'hostDetails.auth.mfaFirst.desc': '適用於必須透過 keyboard-interactive 輸入密碼和 MFA 的伺服器。',
'hostDetails.totp.title': '驗證器 (TOTP)',
'hostDetails.totp.enable': '為這台主機儲存 TOTP 金鑰',
'hostDetails.totp.setup': '設定…',
'hostDetails.totp.edit': '編輯',
'hostDetails.totp.modalTitle': '設定驗證器',
@@ -394,10 +367,8 @@ export const zhTWVaultMessages: Messages = {
'hostDetails.jumpHosts.direct': '直連',
'hostDetails.jumpHosts.configure': '設定代理主機',
'hostDetails.proxy': '透過 HTTP/SOCKS5/指令代理',
'hostDetails.proxy.none': '無',
'hostDetails.proxy.direct': '直連(不使用代理)',
'hostDetails.proxy.directHint': '不使用群組或全域預設代理',
'hostDetails.proxy.edit': '編輯代理',
'hostDetails.proxy.configure': '設定代理',
'hostDetails.envVars': '環境變數',
'hostDetails.envVars.add': '新增環境變數',
@@ -437,6 +408,8 @@ export const zhTWVaultMessages: Messages = {
'localShell.field.shellResolved': '啟動 {command}',
'localShell.field.startDir': '啟動目錄',
'localShell.field.startDirPlaceholder': '繼承全域起始目錄(未設定時為主目錄)',
'localShell.field.startupCommandPlaceholder': 'Shell 啟動後執行的指令(例如:npm run dev)',
'localShell.field.startupCommandDesc': '本地 Shell 在啟動目錄開啟後自動執行該指令。',
'localShell.saveAndConnect': '儲存並開啟',
'hostDetails.plugin.title': '外掛程式連線',
@@ -456,28 +429,14 @@ export const zhTWVaultMessages: Messages = {
'hostDetails.plugin.useSsh': '改用 SSH',
// Host form (legacy modal)
'hostForm.title.edit': '編輯主機',
'hostForm.title.new': '新增主機',
'hostForm.desc.edit': '更新該主機的連線資訊',
'hostForm.desc.new': '建立一個新的 SSH 主機條目',
'hostForm.field.label': '名稱',
'hostForm.placeholder.label': 'My Production Server',
'hostForm.field.hostname': 'Hostname / IP',
'hostForm.placeholder.hostname': '192.168.1.1',
'hostForm.field.port': '埠',
'hostForm.field.username': '使用者名稱',
'hostForm.field.osType': '作業系統型別',
'hostForm.placeholder.selectOs': '選擇作業系統',
'hostForm.field.group': '群組',
'hostForm.placeholder.group': '例如:AWS、DigitalOcean',
'hostForm.field.tags': '標籤',
'hostForm.placeholder.addTag': '新增標籤…',
'hostForm.auth.method': '認證方式',
'hostForm.auth.password': '密碼',
'hostForm.auth.sshKey': 'SSH金鑰',
'hostForm.auth.selectKey': '選擇 SSH金鑰',
'hostForm.auth.noKeys': '暫無金鑰',
'hostForm.auth.noKeysHint': '鑰匙串中未找到 SSH金鑰,請先建立一個。',
'hostForm.saveHost': '儲存主機',
// Connection logs
@@ -495,7 +454,6 @@ export const zhTWVaultMessages: Messages = {
'logs.action.delete': '刪除',
// Log view
'logView.customizeAppearance': '自訂外觀',
'logView.appearance': '外觀',
'logView.readOnly': '只讀',
'logView.export': '匯出',
@@ -508,7 +466,6 @@ export const zhTWVaultMessages: Messages = {
'terminal.toolbar.availableAfterConnect': '連線後可用',
'terminal.toolbar.sendYmodem': 'YMODEM 傳送',
'terminal.toolbar.receiveYmodem': 'YMODEM 接收',
'terminal.toolbar.sftp': 'SFTP',
'terminal.toolbar.more': '更多操作',
'terminal.toolbar.scripts': '指令碼',
'terminal.toolbar.history': '指令歷史',
@@ -533,7 +490,6 @@ export const zhTWVaultMessages: Messages = {
'terminal.composeBar.resize': '拖曳調整撰寫欄高度',
'terminal.composeBar.manageSnippets': '管理快捷程式碼片段',
'terminal.composeBar.searchSnippets': '搜尋程式碼片段...',
'terminal.composeBar.noPinnedSnippets': '點選 + 固定常用程式碼片段',
'terminal.composeBar.noMatchingSnippets': '沒有相符的程式碼片段',
'terminal.composeBar.pinnedCount': '已固定 {count} 個',
'terminal.composeBar.unpinSnippet': '從快捷欄移除 {label}',
@@ -690,9 +646,6 @@ export const zhTWVaultMessages: Messages = {
'terminal.themeModal.themeType': '{type} 主題',
'terminal.hiddenTheme.title': '目前隱藏主題',
'terminal.hiddenTheme.desc': '這個主題已從手動選擇列表中隱藏;當你選擇其他可見主題後,它會被替換。',
'topTabs.toggleTheme.systemExitTitle': '目前正在跟隨系統主題',
'topTabs.toggleTheme.systemExitMessage': '請到設定裡選擇固定的淺色或深色主題。',
'topTabs.toggleTheme.openSettings': '開啟設定',
// Custom Themes
'terminal.customTheme.section': '自訂主題',
@@ -705,7 +658,6 @@ export const zhTWVaultMessages: Messages = {
'terminal.customTheme.importDesc': '從 iTerm2 配色方案檔案匯入',
'terminal.customTheme.importError': '無法解析所選檔案,請確保它是有效的 .itermcolors XML 檔案。',
'terminal.customTheme.delete': '刪除主題',
'terminal.customTheme.confirmDelete': '確認刪除',
'terminal.customTheme.name': '名稱',
'terminal.customTheme.namePlaceholder': '我的自訂主題',
'terminal.customTheme.type': '型別',
@@ -764,10 +716,7 @@ export const zhTWVaultMessages: Messages = {
'cloudSync.provider.disconnect.cloudRemains': '雲端的加密同步副本可能仍保存在 {name} 儲存空間中。如需清除,請到該服務商刪除同步檔案。中斷連線不代表裝置已完成交接清理。',
'cloudSync.provider.disconnect.failed': '未能完成與 {name} 的中斷連線,保存的連線資料可能仍在,請重試。',
'cloudSync.provider.webdav': 'WebDAV',
'cloudSync.provider.webdav.desc': '連線到自建 WebDAV 端點',
'cloudSync.provider.s3': 'S3 相容儲存',
'cloudSync.provider.s3.desc': '連線到 S3 相容物件儲存',
'cloudSync.provider.comingSoon': '即將支援',
'cloudSync.webdav.title': 'WebDAV 設定',
'cloudSync.webdav.desc': '設定 WebDAV 端點用於加密同步。',
'cloudSync.webdav.endpoint': '端點位址',
@@ -796,20 +745,6 @@ export const zhTWVaultMessages: Messages = {
'cloudSync.s3.allowInsecure': '允許不安全的連線(忽略憑證錯誤)',
'cloudSync.s3.showSecret': '顯示金鑰',
'cloudSync.s3.validation.required': '端點、Region、Bucket、Access Key 與 Secret 必填。',
'cloudSync.smb.title': 'SMB 設定',
'cloudSync.smb.desc': '連線到 SMB/CIFS 檔案共享以進行加密同步。',
'cloudSync.smb.share': '共享路徑',
'cloudSync.smb.username': '使用者名稱',
'cloudSync.smb.password': '密碼',
'cloudSync.smb.domain': '域(可選)',
'cloudSync.smb.domainPlaceholder': '例如:WORKGROUP',
'cloudSync.smb.port': '埠(可選)',
'cloudSync.smb.showSecret': '顯示密碼',
'cloudSync.smb.validation.share': '共享路徑必填。',
'cloudSync.smb.validation.port': '埠必須是 1 到 65535 之間的數字。',
'cloudSync.connect.smb.success': 'SMB 已連線',
'cloudSync.connect.smb.failedTitle': 'SMB 連線失敗',
'cloudSync.provider.smb': 'SMB 共享',
'cloudSync.connect.webdav.success': 'WebDAV 已連線',
'cloudSync.connect.webdav.failedTitle': 'WebDAV 連線失敗',
'cloudSync.connect.s3.success': 'S3 已連線',
@@ -826,7 +761,6 @@ export const zhTWVaultMessages: Messages = {
'cloudSync.lastSync.minutesAgo': '{minutes} 分鐘前',
'cloudSync.changeKey': '更改 Key',
'cloudSync.providers.title': '雲服務',
'cloudSync.syncAll': '同步所有已連線的服務',
'cloudSync.autoSync.title': '自動同步',
'cloudSync.autoSync.desc': '發生變更時自動同步',
'cloudSync.strategy.title': '同步策略',
@@ -891,7 +825,6 @@ export const zhTWVaultMessages: Messages = {
'cloudSync.localBackups.folderWarning': '僅複製此資料夾並不構成完整、可攜的備份。刪除或清空應用程式設定目錄(userData)可能導致這些還原點無法讀取。',
'cloudSync.localBackups.retentionTitle': '備份保留數量',
'cloudSync.localBackups.retentionDesc': '設定 Netcatty 最多保留多少份本機備份。',
'cloudSync.localBackups.maxCount': '最多保留',
'cloudSync.localBackups.maxSaved': '已儲存保留數量:{count}',
'cloudSync.localBackups.maxInvalid': '請輸入 1 到 100 之間的數字。',
'cloudSync.localBackups.empty': '還沒有本機備份。',
@@ -1021,7 +954,6 @@ export const zhTWVaultMessages: Messages = {
'sftp.context.openWithDefault': '系統預設程式開啟',
'common.clear': '清除',
'common.optional': '可選',
'common.selectPlaceholder': '請選擇...',
'common.error': '錯誤',
'common.validation': '驗證',
'common.saveChanges': '儲存修改',
@@ -1063,7 +995,6 @@ export const zhTWVaultMessages: Messages = {
'pf.tooltip.localDesc': '本機埠轉發:透過 SSH 隧道存取遠端服務',
'pf.tooltip.remoteDesc': '遠端埠轉發:將本機服務公開給遠端主機',
'pf.tooltip.dynamicDesc': '動態 SOCKS 代理:透過 SSH 隧道轉發流量',
'pf.deleteActive.title': '刪除正在執行的埠轉發?',
'pf.deleteActive.desc': '埠轉發規則 "{label}" 目前正在執行。刪除前將先關閉轉發連線。',
'pf.deleteActive.confirm': '關閉並刪除',
'pf.form.autoStart': '自動啟動',
@@ -1078,8 +1009,6 @@ export const zhTWVaultMessages: Messages = {
'sftp.pane.selectHostToStart': '先選擇一個主機',
'sftp.pane.chooseFilesystem': '選擇要瀏覽的本機或遠端檔案系統',
'sftp.tabs.addTab': '新增分頁',
'sftp.tabs.closeTab': '關閉分頁',
'sftp.tabs.newTab': '新分頁',
'sftp.tabs.copyDefaultPath': '複製分頁(預設路徑)',
'sftp.tabs.copyCurrentPath': '複製並跳轉到目前路徑',
'sftp.conflict.title': '檔案衝突',
@@ -1105,10 +1034,6 @@ export const zhTWVaultMessages: Messages = {
'sftp.conflict.action.replace': '替換',
// SFTP Upload Phases
'sftp.upload.phase.compressing': '正在壓縮',
'sftp.upload.phase.uploading': '正在上傳',
'sftp.upload.phase.extracting': '正在解壓',
'sftp.upload.phase.compressed': '壓縮傳輸',
'vault.import.plugins.title': '外掛程式匯入器',
'vault.import.plugins.loading': '正在建立安全匯入預覽…',
'vault.import.plugins.progress': '已處理 {completed}/{total} {message}',
@@ -1,34 +0,0 @@
import assert from "node:assert/strict";
import test from "node:test";
import { readFileSync } from "node:fs";
const source = readFileSync(new URL("./activeChromeThemeSync.ts", import.meta.url), "utf8");
const chromeThemeSource = readFileSync(new URL("./useActiveChromeTheme.ts", import.meta.url), "utf8");
const storeSource = readFileSync(new URL("./activeTabStore.ts", import.meta.url), "utf8");
test("active tab changes notify chrome theme before react subscribers", () => {
const setActiveTabIdBody = storeSource.match(/setActiveTabId = \(id: string(?:, options\?: \w+)?\) => \{[\s\S]*?\n {2}\};/)?.[0] ?? "";
assert.match(setActiveTabIdBody, /this\.syncListeners\.forEach\(\(listener\) => listener\(id\)\)/);
assert.match(setActiveTabIdBody, /this\.scheduleNotify\(\)/);
assert.ok(
setActiveTabIdBody.indexOf("syncListeners.forEach") < setActiveTabIdBody.indexOf("scheduleNotify"),
"sync chrome theme listeners must run before deferred react notify",
);
assert.match(source, /activeTabStore\.subscribeSync\(notifyActiveChromeThemeForTab\)/);
assert.match(source, /isActiveChromeThemeResolvable/);
assert.match(source, /clearTopTabsChromeThemeVars/);
});
test("tab chrome notify defers apply via rAF and short-circuits on fingerprint", () => {
assert.match(source, /requestAnimationFrame/);
assert.match(source, /themeFingerprint/);
assert.match(source, /export function applyChromeThemeForTab/);
assert.match(source, /export function notifyActiveChromeThemeForTab/);
// Tab path must not use view transitions.
assert.doesNotMatch(source, /mode:\s*['"]view['"]/);
});
test("syncActiveChromeTheme applies terminal chrome with instant mode", () => {
assert.match(chromeThemeSource, /mode:\s*['"]instant['"]/);
assert.match(chromeThemeSource, /nextFingerprint === appliedFingerprint/);
});
+135
View File
@@ -6,6 +6,8 @@ import {
bumpDraftMutationVersionState,
bumpDraftUploadGenerationState,
clearScopeDraftState,
clearSessionViewsForSession,
demoteImplicitSourceViewsForSession,
createEmptyDraft,
ensureDraftForScopeState,
getDraftMutationVersionState,
@@ -218,6 +220,139 @@ test("pruneStaleSessionPanelViews returns the original ref when nothing is stale
assert.equal(next, panelViewByScope);
});
test("clearSessionViewsForSession clears the rebound chat's source views and keeps the destination + unrelated scopes", () => {
// Mirrors rebindSessionScope: source A shows chat-1, destination B is set to
// chat-1, and unrelated scopes keep their own chats/drafts.
const panelViewByScope = {
"workspace:A": { mode: "session", sessionId: "chat-1" },
"workspace:A-alias": { mode: "session", sessionId: "chat-1" },
"workspace:B": { mode: "session", sessionId: "prev-b" },
"workspace:C": { mode: "session", sessionId: "chat-2" },
"workspace:D": { mode: "draft" },
} satisfies Record<string, { mode: "draft" } | { mode: "session"; sessionId: string }>;
const next = setSessionView(
clearSessionViewsForSession(panelViewByScope, "chat-1", "workspace:B"),
"workspace:B",
"chat-1",
);
assert.deepEqual(next, {
"workspace:A": { mode: "draft" },
"workspace:A-alias": { mode: "draft" },
"workspace:B": { mode: "session", sessionId: "chat-1" },
"workspace:C": { mode: "session", sessionId: "chat-2" },
"workspace:D": { mode: "draft" },
});
// The destination's prior view must not be cleared by the purge (setSessionView
// overwrites it), and unrelated scopes must keep their exact view objects.
assert.equal(next["workspace:C"], panelViewByScope["workspace:C"]);
assert.equal(next["workspace:D"], panelViewByScope["workspace:D"]);
});
test("clearSessionViewsForSession returns the original ref when no other scope points at the chat", () => {
const panelViewByScope = {
"workspace:B": { mode: "session", sessionId: "chat-2" },
"workspace:C": { mode: "draft" },
} satisfies Record<string, { mode: "draft" } | { mode: "session"; sessionId: string }>;
const next = clearSessionViewsForSession(panelViewByScope, "chat-1", "workspace:B");
assert.equal(next, panelViewByScope);
});
// Mirrors rebindSessionScope's single setPanelViewByScope updater: explicit
// source views are purged, implicit source scopes from the pre-rebind active
// map are demoted to draft, and the destination view is (re)set to the chat.
function applyRebindViewUpdates(
panelViewByScope: Record<string, { mode: "draft" } | { mode: "session"; sessionId: string }>,
activeSessionIdMap: Record<string, string | null>,
sessionId: string,
keepScopeKey: string,
) {
return setSessionView(
demoteImplicitSourceViewsForSession(
clearSessionViewsForSession(panelViewByScope, sessionId, keepScopeKey),
activeSessionIdMap,
sessionId,
keepScopeKey,
),
keepScopeKey,
sessionId,
);
}
test("round 4 RESTORED: rebind of a restored chat demotes implicit source scopes when panel views are empty", () => {
// Post-restart (issue #4125): the active-session map is restored from the
// IndexedDB meta store, but panelViewByScope is memory-only and starts EMPTY.
// chat-1 is A's only session; rebinding it to B has no explicit source view
// for the round-3 purge to demote. A's implicit view must be written to draft.
const activeSessionIdMap = {
"workspace:A": "chat-1",
"workspace:C": "chat-2",
};
const next = applyRebindViewUpdates({}, activeSessionIdMap, "chat-1", "workspace:B");
assert.deepEqual(next, {
// A had no explicit view but was an implicit source via the restored map:
// it now has an explicit draft view that blocks the sessions[0] fallback.
"workspace:A": { mode: "draft" },
// Destination still points at the rebound chat.
"workspace:B": { mode: "session", sessionId: "chat-1" },
});
// Unrelated scope C (its active pointer named chat-2, not chat-1) is not a
// source scope and must not gain any view.
assert.equal(next["workspace:C"], undefined);
});
test("round 4: rebind keeps explicit source views demoted and leaves unrelated + target scopes intact", () => {
const activeSessionIdMap = {
"workspace:A": "chat-1",
"workspace:A-alias": "chat-1",
"workspace:C": "chat-2",
};
const panelViewByScope = {
"workspace:A": { mode: "session", sessionId: "chat-1" },
"workspace:A-alias": { mode: "session", sessionId: "chat-1" },
"workspace:B": { mode: "session", sessionId: "prev-b" },
"workspace:C": { mode: "session", sessionId: "chat-2" },
"workspace:D": { mode: "draft" },
} satisfies Record<string, { mode: "draft" } | { mode: "session"; sessionId: string }>;
const next = applyRebindViewUpdates(panelViewByScope, activeSessionIdMap, "chat-1", "workspace:B");
assert.deepEqual(next, {
"workspace:A": { mode: "draft" },
"workspace:A-alias": { mode: "draft" },
"workspace:B": { mode: "session", sessionId: "chat-1" },
"workspace:C": { mode: "session", sessionId: "chat-2" },
"workspace:D": { mode: "draft" },
});
// Unrelated scopes keep their exact objects; the destination is overwritten
// by setSessionView, not by the purge.
assert.equal(next["workspace:C"], panelViewByScope["workspace:C"]);
assert.equal(next["workspace:D"], panelViewByScope["workspace:D"]);
});
test("round 4: implicit source keys come from the PRE-rebind active map (post-clear would miss them)", () => {
// rebindActiveSessionMap drops A's pointer to chat-1 before views are
// written. Feeding the post-clear map to the demotion would miss A entirely,
// so the source keys MUST be captured before rebindActiveSessionMap runs.
const preRebind = { "workspace:A": "chat-1", "workspace:B": "chat-1" };
const postClear = { "workspace:B": "chat-1" };
const fromPreRebind = demoteImplicitSourceViewsForSession(
{}, preRebind, "chat-1", "workspace:B",
);
assert.deepEqual(fromPreRebind, { "workspace:A": { mode: "draft" } });
const fromPostClear = demoteImplicitSourceViewsForSession(
{}, postClear, "chat-1", "workspace:B",
);
assert.deepEqual(fromPostClear, {});
});
test("clearScopeDraftState removes both the draft and current panel view", () => {
const draftsByScope = {
"terminal:1": createEmptyDraft("agent-alpha"),
+62
View File
@@ -193,6 +193,68 @@ export function pruneStaleSessionPanelViews(
return next;
}
/**
* PR #4159 review fix (round 3): when a chat is rebound to `keepScopeKey`,
* drop every *other* scope's explicit session view that still points at it.
* `getSessionScopeMatchRank` keeps other-workspace chats visible at rank 1, so
* a surviving view would keep the moved chat as that panel's activeSession;
* the active-session effect in AIChatSidePanel then recreates the pointer that
* rebindActiveSessionMap just removed, and follow-up turns in the source
* workspace keep executing against the moved chat. Demote to an explicit draft
* (not delete) so resolveDisplayedPanelView cannot fall through to sessions[0]
* and re-select it. The destination scope is left intact for setSessionView.
*/
export function clearSessionViewsForSession(
panelViewByScope: PanelViewByScope,
sessionId: string,
keepScopeKey: string,
): PanelViewByScope {
let next = panelViewByScope;
for (const [scopeKey, panelView] of Object.entries(panelViewByScope)) {
if (scopeKey === keepScopeKey) continue;
if (panelView?.mode !== 'session' || panelView.sessionId !== sessionId) continue;
const updated = setDraftView(next, scopeKey);
if (updated !== next) {
next = updated;
}
}
return next;
}
/**
* PR #4159 review fix (round 4): a restored chat has no explicit source view
* to demote. After a restart the active-session map is restored (localStorage /
* IndexedDB meta, issue #4125) but panelViewByScope is memory-only and starts
* empty, so clearSessionViewsForSession finds nothing. getSessionScopeMatchRank
* still lists the rebound chat at rank 1 in that scope, resolveDisplayedPanelView
* falls through to sessions[0], and the active-session effect recreates the
* pointer rebindActiveSessionMap removed — follow-up turns would run in the old
* workspace. Write an explicit draft view for every source scope key captured
* from the PRE-rebind active map (every key naming sessionId under a different
* scope), even when no explicit panel view existed, so the draft short-circuits
* that fallback. The destination scope is left for setSessionView.
*/
export function demoteImplicitSourceViewsForSession(
panelViewByScope: PanelViewByScope,
activeSessionIdMap: ActiveSessionIdMap,
sessionId: string,
keepScopeKey: string,
): PanelViewByScope {
let next = panelViewByScope;
for (const [scopeKey, id] of Object.entries(activeSessionIdMap)) {
if (id !== sessionId || scopeKey === keepScopeKey) continue;
const updated = setDraftView(next, scopeKey);
if (updated !== next) {
next = updated;
}
}
return next;
}
export function updateDraftForScope(
draftsByScope: DraftsByScope,
scopeKey: string,
@@ -138,6 +138,52 @@ test('DebouncedBackupMirror flushNow writes the pending payload immediately', ()
assert.deepEqual(writes, ['{"gen":1}']);
});
test('DebouncedBackupMirror defers lazy serializer execution until debounce timer or flushNow fires', async () => {
const writes: string[] = [];
const serialized: number[] = [];
const mirror = new DebouncedBackupMirror((json) => writes.push(json), 15);
mirror.schedule(() => {
serialized.push(1);
return '{"gen":1}';
});
mirror.schedule(() => {
serialized.push(2);
return '{"gen":2}';
});
// Neither producer runs synchronously during burst scheduling.
assert.deepEqual(serialized, []);
assert.deepEqual(writes, []);
await new Promise((resolve) => setTimeout(resolve, 35));
// Only the final producer in the burst is invoked when the timer fires.
assert.deepEqual(serialized, [2]);
assert.deepEqual(writes, ['{"gen":2}']);
// flushNow invokes only the pending lazy producer immediately; reset discards without calling it.
mirror.schedule(() => {
serialized.push(3);
return '{"gen":3}';
});
mirror.schedule(() => {
serialized.push(4);
return '{"gen":4}';
});
assert.deepEqual(serialized, [2]);
mirror.flushNow();
assert.deepEqual(serialized, [2, 4]);
assert.deepEqual(writes, ['{"gen":2}', '{"gen":4}']);
mirror.schedule(() => {
serialized.push(5);
return '{"gen":5}';
});
mirror.reset();
await new Promise((resolve) => setTimeout(resolve, 30));
assert.deepEqual(serialized, [2, 4]);
assert.deepEqual(writes, ['{"gen":2}', '{"gen":4}']);
});
test('readLiveSessionsArray treats non-array JSON as empty (corrupt)', () => {
assert.deepEqual(readLiveSessionsArray(null), []);
assert.deepEqual(readLiveSessionsArray(''), []);
+19 -10
View File
@@ -119,28 +119,37 @@ export function mergeImportedSessions(current: AISession[], imported: AISession[
return Array.from(byId.values()).sort((a, b) => (b.updatedAt ?? 0) - (a.updatedAt ?? 0));
}
export type BackupMirrorInput = string | (() => string);
/**
* Debounced mirror scheduler. One rolling timer per process: the last
* mutation batch wins, and the write happens `debounceMs` after the batch
* settles (at most once per batch, per the durability spec).
* Accepts either a pre-serialized JSON string or a lazy serializer invoked
* only when the debounce timer or `flushNow()` actually runs.
*/
export class DebouncedBackupMirror {
private timer: ReturnType<typeof setTimeout> | null = null;
private pendingJson: string | null = null;
private pendingInput: BackupMirrorInput | null = null;
constructor(
private readonly write: (json: string) => void,
private readonly debounceMs: number = AI_SESSIONS_BACKUP_DEBOUNCE_MS,
) {}
schedule(json: string) {
this.pendingJson = json;
private emit(input: BackupMirrorInput) {
const json = typeof input === 'function' ? input() : input;
this.write(json);
}
schedule(input: BackupMirrorInput) {
this.pendingInput = input;
if (this.timer) clearTimeout(this.timer);
this.timer = setTimeout(() => {
this.timer = null;
const json = this.pendingJson;
this.pendingJson = null;
if (json != null) this.write(json);
const pending = this.pendingInput;
this.pendingInput = null;
if (pending != null) this.emit(pending);
}, this.debounceMs);
}
@@ -149,14 +158,14 @@ export class DebouncedBackupMirror {
clearTimeout(this.timer);
this.timer = null;
}
const json = this.pendingJson;
this.pendingJson = null;
if (json != null) this.write(json);
const pending = this.pendingInput;
this.pendingInput = null;
if (pending != null) this.emit(pending);
}
reset() {
if (this.timer) clearTimeout(this.timer);
this.timer = null;
this.pendingJson = null;
this.pendingInput = null;
}
}
@@ -847,3 +847,75 @@ test('rewriting the same sessions array skips re-serialization and store writes'
__resetIdbPersistenceForTests();
}
});
test('writeSessionsForStorage defers backup JSON.stringify during bursts and skips unchanged rewrites when sync is disabled', async (t) => {
const {
writeSessionsForStorage,
flushBackupMirror,
__flushIdbWritesForTests,
__resetBackupMirrorForTests,
__resetIdbPersistenceForTests,
} = await import('./aiStateSnapshots');
__resetBackupMirrorForTests();
__resetIdbPersistenceForTests();
const idb = installFakeIndexedDb();
const backupWrites: string[] = [];
const previousWindow = globalThis.window;
Object.defineProperty(globalThis, 'window', {
configurable: true,
value: {
netcatty: {
aiSessionsBackupWrite: async (payload: { json: string }) => {
backupWrites.push(payload.json);
return { ok: true };
},
},
},
});
// Default syncEnabled=false path: pruneSessionsForStorage allocates a new array each call.
t.mock.method(localStorageAdapter, 'read', () => null);
t.mock.method(localStorageAdapter, 'writeString', () => true);
try {
const stringify = t.mock.method(JSON, 'stringify');
const a1 = makeSession('chat-a', 1, [{ id: 'm1', role: 'assistant', content: 'chunk 1', timestamp: 1 }]);
const b = makeSession('chat-b', 0, []);
const a2 = makeSession('chat-a', 2, [{ id: 'm1', role: 'assistant', content: 'chunk 1+2', timestamp: 2 }]);
const a3 = makeSession('chat-a', 3, [{ id: 'm1', role: 'assistant', content: 'chunk 1+2+3', timestamp: 3 }]);
// Streaming persist burst: 3 consecutive writes must perform 0 eager JSON.stringify calls.
assert.equal(writeSessionsForStorage([a1, b]), true);
assert.equal(writeSessionsForStorage([a2, b]), true);
assert.equal(writeSessionsForStorage([a3, b]), true);
assert.equal(stringify.mock.callCount(), 0, 'JSON.stringify must not run eagerly on writeSessionsForStorage');
assert.equal(backupWrites.length, 0);
// Flushing the debounced mirror serializes only the latest persisted snapshot once.
flushBackupMirror();
assert.equal(stringify.mock.callCount(), 1);
assert.equal(backupWrites.length, 1);
const flushed = JSON.parse(backupWrites[0]) as AISession[];
assert.equal(flushed.find((s) => s.id === 'chat-a')?.messages[0]?.content, 'chunk 1+2+3');
// Rewriting unchanged sessions with syncEnabled=false (fresh array from pruneSessionsForStorage)
// must NOT schedule a redundant mirror or run JSON.stringify on flush.
assert.equal(writeSessionsForStorage([a3, b]), true);
flushBackupMirror();
assert.equal(stringify.mock.callCount(), 1, 'unchanged sessions must not re-schedule mirror when sync is disabled');
assert.equal(backupWrites.length, 1);
// Removing a session still schedules and mirrors the updated set.
assert.equal(writeSessionsForStorage([a3], { deletedSessionIds: ['chat-b'] }), true);
assert.equal(stringify.mock.callCount(), 1, 'deletion backup serialization is also deferred until flush/debounce');
flushBackupMirror();
assert.equal(stringify.mock.callCount(), 2);
assert.equal(backupWrites.length, 2);
assert.deepEqual((JSON.parse(backupWrites[1]) as AISession[]).map((s) => s.id), ['chat-a']);
await __flushIdbWritesForTests();
} finally {
idb.restore();
__resetBackupMirrorForTests();
__resetIdbPersistenceForTests();
Object.defineProperty(globalThis, 'window', { configurable: true, value: previousWindow });
}
});
Loaded 100 of 1094 files, more files were not shown because too many files have changed in this diff. Show more