- Use toast.success/warning instead of toast({title:}) for better UX
- Change credentials copy format to labeled multi-line format
- Add ESLint global declarations for Node.js globals
Co-Authored-By: Claude <noreply@anthropic.com>
For telnet hosts, use telnetUsername instead of username since the UI
stores telnet credentials separately from SSH credentials.
Co-Authored-By: Claude <noreply@anthropic.com>
Exporting partial data (SSH without mosh flag) is better than completely
losing the host entry. Only serial hosts are now skipped since they truly
cannot be represented in CSV format.
Co-Authored-By: Claude <noreply@anthropic.com>
Mosh hosts are typically represented as protocol=ssh with moshEnabled=true,
not protocol=mosh. The export filter now also skips hosts with moshEnabled
to prevent data loss when the mosh setting would be silently dropped on import.
Co-Authored-By: Claude <noreply@anthropic.com>
When copying credentials, only treat host as telnet when protocol is
explicitly set to "telnet". Having telnetEnabled=true just means telnet
is available as an alternative protocol, not the primary one.
Co-Authored-By: Claude <noreply@anthropic.com>
When copying credentials for hosts with IPv6 addresses and non-default ports,
the address is now properly formatted as [2001:db8::1]:2222 instead of the
ambiguous 2001:db8::1:2222.
Co-Authored-By: Claude <noreply@anthropic.com>
Address Codex review: mosh hosts are now filtered out during CSV export
alongside serial hosts, as the CSV import's normalizeProtocol only
recognizes ssh/telnet/local. Exporting mosh hosts would silently convert
them to SSH on re-import.
Updated toast message to say "unsupported hosts" instead of "serial hosts"
since both serial and mosh are now skipped.
Co-Authored-By: Claude <noreply@anthropic.com>
Address Codex review: IPv6 addresses are now wrapped in brackets when
exported to CSV (e.g., [2001:db8::1]). This ensures they can be correctly
parsed on re-import, as the CSV import parser treats unbracketed colons
as port separators.
Co-Authored-By: Claude <noreply@anthropic.com>
Address Codex review: for telnet protocol hosts, now uses telnetUsername,
telnetPassword, and telnetPort instead of the SSH credentials. This ensures
the copied credentials match what the telnet connection actually uses.
Co-Authored-By: Claude <noreply@anthropic.com>
Address Codex review: for telnet protocol hosts, now exports telnetPort
instead of port (which is the SSH port). This ensures that re-importing
the CSV will preserve the correct telnet connection port.
Co-Authored-By: Claude <noreply@anthropic.com>
Address Codex review: the showPassword state is now reset to false
when initialData changes, ensuring each host's password defaults
to masked mode. This prevents a privacy issue where switching hosts
would keep the password visible if it was previously shown.
Co-Authored-By: Claude <noreply@anthropic.com>
Address Codex review: serial hosts (protocol === "serial") are now
filtered out during CSV export since the CSV import format doesn't
support serial port configuration. Importing serial hosts would result
in invalid SSH entries.
When serial hosts are skipped, users are notified via a toast message
showing how many were excluded.
Co-Authored-By: Claude <noreply@anthropic.com>
Address Codex security review: values starting with =, +, -, @, tab or
carriage return are now prefixed with a single quote to prevent
spreadsheet applications from interpreting them as formulas.
This mitigates CSV injection attacks when exported files are opened
in Excel, Google Sheets, or similar applications.
Co-Authored-By: Claude <noreply@anthropic.com>
Address Codex review feedback: when a host is configured with an identityId,
the copy credentials function now correctly resolves username and password
from the identity first, falling back to host fields if not available.
Co-Authored-By: Claude <noreply@anthropic.com>
- Add export button to export hosts to CSV file using import template format
- Add eye icon to toggle password visibility in host edit panel
- Add "Copy Credentials" option to host context menu for sharing host info
- Make label field optional when creating new host (defaults to hostname/IP)
- Fix duplicate keyboard shortcuts:
- clear-buffer: changed from ⌘+K to ⌘+⌃+K (Mac) and Ctrl+L to Ctrl+Shift+K (PC)
- open-sftp: changed from ⌘+Shift+S to ⌘+Shift+O (Mac) and Ctrl+Shift+O (PC)
- snippets: changed PC shortcut from Ctrl+Alt+S to Ctrl+Shift+S to match Mac
Co-Authored-By: Claude <noreply@anthropic.com>
The workflow triggers on `v*` tags and build.yml extracts version from
any v-prefixed tag. Updated the regex from `^v\d+\.\d+\.\d+` to `^v\d`
to accept tags like v1, v1.2, v1.2.3, etc.
This ensures version parsing stays in sync with build.yml behavior.
Co-Authored-By: Claude <noreply@anthropic.com>
- Tag release: use version from tag (e.g., v1.2.3 -> 1.2.3)
- workflow_dispatch: use short commit ID (first 7 chars)
This ensures electron-builder artifacts match the release notes
download links in all scenarios.
Co-Authored-By: Claude <noreply@anthropic.com>
Version priority is now:
1. VERSION env variable
2. Valid version tag (v1.2.3 format)
3. Short commit ID (first 7 chars)
4. package.json version as final fallback
Co-Authored-By: Claude <noreply@anthropic.com>
When workflow is triggered via workflow_dispatch, GITHUB_REF_NAME is
the branch name (e.g., "main") instead of a version tag. This caused
the generated release notes to have incorrect download URLs.
Now the script:
1. Checks if GITHUB_REF_NAME is a valid version tag (v1.2.3 format)
2. Falls back to reading version from package.json if not
This ensures the release notes always match the actual artifact
filenames produced by electron-builder.
Co-Authored-By: Claude <noreply@anthropic.com>
Define custom Monaco themes (netcatty-dark, netcatty-light) that inherit from built-in themes but use the app's background color from CSS variables. This ensures the text editor background matches the current UI theme, including Pure Black mode.
Co-Authored-By: Claude <noreply@anthropic.com>
Add Pure Black dark theme with true black background (#000000) for AMOLED screens, and Lavender light theme to balance theme count. Also increase sidebar nav item selection contrast from 5% to 10% for better visibility in dark themes.
Co-Authored-By: Claude <noreply@anthropic.com>
- Add "Duplicate" option to host context menu to quickly copy hosts
- Add "Save Password" toggle in host details panel
- Add savePassword field to Host interface
- Add i18n translations for both features (en, zh-CN)
- Internationalize existing hardcoded context menu items
Co-authored-by: binaricat <16399091+binaricat@users.noreply.github.com>
Use both Object.defineProperty for the ariaHidden property and
setAttribute override to catch all ways aria-hidden can be set.
The MutationObserver approach was too late (async) to prevent
the browser warning.
Co-Authored-By: Claude <noreply@anthropic.com>
The previous setAttribute override wasn't catching all cases where
aria-hidden was being set. Using MutationObserver to watch for
attribute changes and immediately remove aria-hidden when the
context menu is open (has children).
Co-Authored-By: Claude <noreply@anthropic.com>
Remove residual code from merge conflict that caused duplicate variable
declaration error. The lazy-loading pattern is now correctly placed in
handleFileChange function only.
Co-Authored-By: Claude <noreply@anthropic.com>
The useEffect that triggers loadFiles with force:true was running on
every navigation because currentPath was in its dependencies. This
caused redundant SFTP list calls that bypassed caching.
Now we track the previous encoding with a ref and only force reload
when filenameEncoding actually changes, not on every path change.
Regular navigation still works through useSftpModalSession's own
path change handling.
Co-Authored-By: Claude <noreply@anthropic.com>
When auto-detection mode is used and a directory is empty (or all
filenames are valid UTF-8), detectEncodingFromList now returns null
instead of defaulting to "utf-8". The caller then preserves the
previously resolved session encoding.
This fixes the issue where navigating into an empty directory on a
GB18030 server would silently flip the session to UTF-8, causing
subsequent creates/renames/uploads to send UTF-8 bytes and produce
garbled filenames.
Co-Authored-By: Claude <noreply@anthropic.com>
1. Fix getStringLen to honor encoding parameter in SFTP patch
- When a non-UTF-8 encoding is provided, the function now correctly
calculates byte length using that encoding instead of defaulting to UTF-8
- This prevents protocol errors when writing data with custom encodings
2. Fix aria-hidden warning on context menu portal
- Override setAttribute on the portal container to block aria-hidden="true"
when the menu is open (has children)
- This prevents "Blocked aria-hidden on an element because its descendant
retained focus" warnings when context menu opens inside a dialog
Co-Authored-By: Claude <noreply@anthropic.com>
Serial connections don't support SFTP, so they shouldn't appear
in the host picker when adding a new SFTP connection.
Co-Authored-By: Claude <noreply@anthropic.com>
The previous fix only checked the direct parent task ID, which doesn't
work for deeply nested folders:
- Top-level task "A" (user cancels this)
- Child folder "B" with parentTaskId="A" (detected cancellation)
- Grandchild file "C" with parentTaskId="B" (NOT detected!)
Now we pass rootTaskId through all levels of transferDirectory and
transferFile calls, so all nested operations check against the
original top-level task ID.
Co-Authored-By: Claude <noreply@anthropic.com>