Commit Graph
2609 Commits
Author SHA1 Message Date
Kang ec59a5dbe3 feat(ai): refactor agent tool management and enhance context handling
- Moved agent tool definitions and schemas into a new harness module, improving organization and maintainability.
- Updated agent tool functions to utilize a shared registry for tool schemas, enhancing flexibility and reducing redundancy.
- Introduced new fields in the AiRequestOptions and AiToolCall structs to support ephemeral context and thought signatures, improving the tracking of agent actions.
- Enhanced the handling of tool calls in various AI provider request bodies, ensuring better integration with the new context management features.
- Improved risk assessment logic to incorporate new agent approval decisions, streamlining command execution policies.
2026-10-03 08:29:58 +08:00
Kang 16a3d04fea feat(locales): add new command-related localization strings in multiple languages
- Introduced new localization strings for command management and execution status in English, French, Japanese, Korean, Simplified Chinese, and Traditional Chinese.
- Enhanced user experience by providing clear feedback on command actions, including approval, execution, and risk assessment.
- Updated locale files to ensure consistency and clarity across different languages, improving the overall interaction with the AI agent.
2026-10-02 23:59:52 +08:00
Kang 6d3639274c feat(ai): enhance AI agent step management and presentation
- Introduced new fields in the AiAgentStepView and AiAgentLoopState structs to track command card IDs and step kinds, improving the context of AI agent actions.
- Updated the NyaTermApp methods to utilize the new command card information, enhancing the AI's ability to manage and present agent steps.
- Added a new presentation module to define transient contracts for AI response phases and agent step kinds, streamlining the handling of AI interactions.
- Refactored the AI panel to incorporate command syntax highlighting and improved command management, enhancing user experience during AI interactions.
2026-10-02 23:59:44 +08:00
Kang 71629573a5 feat(ai): enhance AI reasoning effort options and localization
- Added new reasoning effort options in English, French, Japanese, Korean, Simplified Chinese, and Traditional Chinese to improve user experience and clarity.
- Updated the AI panel to support the new reasoning effort options, allowing users to select from various levels of reasoning effort.
- Refactored the AI state management to handle reasoning choices more effectively, ensuring a seamless integration with the existing AI functionalities.
- Improved the SVG icon for the AI "new" action to enhance visual consistency across the application.
2026-10-02 21:22:35 +08:00
Kang a2a2f7901e Merge branch 'migration/gpui' of https://github.com/nyakang/nyaterm into migration/gpui 2026-10-02 20:01:42 +08:00
Kang 25e152d6f4 feat(tray): improve native window handling for Windows
- Refactored the window activation logic to ensure the main window is properly activated before opening dialogs from the tray.
- Introduced a new `show_native_window` function to manage window visibility and focus, preserving the state of minimized or maximized windows.
- Added a test to verify that the native window activation behaves correctly, ensuring the main window is set as the owner of new dialogs.
- Enhanced the overall user experience by ensuring that tray actions do not interfere with window state management.
2026-10-02 20:01:40 +08:00
Kang 3c7ebd60a3 ci: update architecture allowlist baselines 2026-10-02 19:17:23 +08:00
Kang 67e8327407 feat(locales): add provider status messages and counts in multiple languages
- Introduced new localization strings for provider status messages and counts in English, French, Japanese, Korean, Simplified Chinese, and Traditional Chinese.
- Enhanced user experience by providing clear feedback on provider testing statuses, including idle, testing, success, and error states.
- Updated locale files to ensure consistency and clarity across different languages.
2026-10-02 18:29:22 +08:00
Kang 26e6a422d0 feat(settings): enhance AI provider settings UI with improved layout and status indicators
- Refactored the AI provider list to utilize a grid layout for better responsiveness based on viewport width.
- Updated the provider buttons to include status indicators and tooltips, enhancing user interaction and clarity.
- Improved styling and organization of provider elements, ensuring a more visually appealing and functional settings panel.
- Removed unnecessary properties and streamlined the code for better maintainability.
2026-10-02 18:29:09 +08:00
Kang fcc3362531 feat(shutdown): enhance shutdown process for blocking jobs and workspace management
- Refactored the shutdown mechanism in the `SchedulerInner` to improve the handling of worker threads during shutdown, allowing for a more graceful cancellation of jobs.
- Introduced a new `begin_shutdown` method to initiate the shutdown process without blocking the caller, enabling UI responsiveness during job cancellation.
- Updated the `DesktopController` to utilize the new shutdown methods, ensuring that workspace sessions and blocking jobs are properly managed during application shutdown.
- Enhanced the `AgentManagementState` to support a clean shutdown of the agent worker, preventing resource leaks and ensuring proper cleanup.
- Added tests to validate the new shutdown behavior, ensuring that jobs can be cancelled without affecting the responsiveness of the UI.
2026-10-02 17:55:51 +08:00
Kang fe0dadd855 feat(icons): add new SVG icons for settings and AI providers
- Introduced a comprehensive set of new SVG icons for various settings and AI providers, enhancing the visual representation within the application.
- Added icons for functionalities such as agent, AI, backup, cloud, dashboard, and more, improving user interface consistency and accessibility.
- Updated the AI module to include new provider settings and reasoning effort options, expanding the capabilities of the AI integration.
- Enhanced the overall icon library to support a wider range of features and improve user experience.
2026-10-02 16:17:06 +08:00
Kang 3671a31b19 feat(platform): implement native menu theme initialization for Windows
- Added a new module to handle native menu theming on Windows, allowing menus to follow the system theme.
- Introduced functionality to enable dark mode for native menus based on the Windows version.
- Updated the main application entry point to initialize the native menu theme during startup.
- Enhanced the Cargo.toml file with additional Windows system features for improved compatibility.
2026-10-02 13:56:44 +08:00
Kang 7db53313ae feat(tray): enhance system tray functionality and localization
- Updated tray menu options across multiple languages to improve clarity and consistency, including renaming actions and adding new entries for session management and cloud sync.
- Introduced new tray actions such as "Hide to Tray," "Active Sessions," and "Open Cloud Sync History" to enhance user experience.
- Refactored tray-related code to improve organization and maintainability, including the addition of a new model for tray actions and entries.
- Implemented logic to handle tray interactions more effectively, ensuring that user actions are accurately reflected in the application state.
2026-10-02 13:25:33 +08:00
Kang a23fad5600 test(desktop): use cross-platform select-all shortcut 2026-10-02 11:14:16 +08:00
Kang bf655d3d36 feat(transfers): add UI font size configuration and update transfer panel metrics (#832)
- Introduced a new `ui_font_size` property in the transfer panel and related components to allow dynamic font size adjustments.
- Updated the transfer browser path row and breadcrumb rendering to utilize the new font size metrics for improved layout and readability.
- Added tests to ensure that changes in font size correctly refresh the transfer snapshot without requiring panel interaction.
- Enhanced the appearance settings to defer transfer panel snapshot flush upon appearance changes.
2026-10-02 09:44:07 +08:00
Kang 906892605c feat(connections): enhance editor field updates for shell path and working directory (#818)
- Added functionality to reset editor fields for shell path and working directory upon selection in the connection editor.
- Implemented tests to ensure that existing inputs are updated and preserved correctly when using path pickers in the connection settings.
- Improved user experience by ensuring that selected paths are reflected in the editor state and UI.
2026-10-01 14:31:00 +08:00
Kang 422f628d15 chore(dependencies): update git revisions and versions in Cargo files
- Updated the source revisions for several dependencies in Cargo.lock and Cargo.toml to the latest commits.
- Bumped the version of `gpui-base`, `gpui-component`, `gpui-macros`, `gpui-kit`, and `gpui-kit-assets` to 0.7.0.
- Adjusted dependencies in `gpui_apple` and `gpui_linux` to reflect the latest changes.
- Removed unused dependencies and updated existing ones for better compatibility and performance.
2026-10-01 14:11:39 +08:00
Kang 4c286f37fe feat(terminal): implement colon input diagnostics for Windows
- Introduced a new module for diagnosing colon input behavior on Windows, allowing for better handling of shifted semicolon inputs.
- Added functionality to track and log colon input events, including key presses and their outcomes.
- Implemented a probe mechanism to monitor colon input over time, ensuring accurate diagnostics and feedback.
- Enhanced existing terminal input handling to integrate colon input diagnostics seamlessly.
- Updated tests to validate the new diagnostics features and ensure robustness in various input scenarios.
2026-10-01 13:08:49 +08:00
Kang b63d24533b feat(serial): implement custom baud rate input with keyboard and pointer support (#822)
- Added a new test for serial custom baud rate input that verifies pointer focus and keyboard edits.
- Updated the serial baud picker to use an editor stepper field for better user interaction.
- Enhanced the apply button functionality to ensure the custom baud rate is correctly set and reflected in the connection state.
2026-10-01 11:30:06 +08:00
Kang e7678f75ea fix(desktop): manage agent worker threads 2026-09-30 11:29:39 +08:00
Kang d93e4b7291 Merge pull request #772 from moonmicah/feat/credential-autofill-connection-password
feat(terminal): autofill password prompts from connection password ca…
2026-09-30 11:02:23 +08:00
Kang 9d3ba0d463 refactor(settings): streamline settings navigation and group management
- Removed unused settings groups from the expanded groups in the ShellSettingsNavigationState.
- Simplified the settings navigation structure by consolidating transfer, security, and sync backup groups into a standalone format.
- Updated the rendering logic to conditionally display active group information based on the current tab state.
2026-09-30 10:57:14 +08:00
Kang d513c21fe9 feat(settings): add terminal right-click actions and internal editor display options
- Introduced `TerminalRightClickAction` and `InternalEditorDisplay` enums to manage terminal right-click behavior and internal editor display modes.
- Updated `AppSettingsSummary` to include new settings for terminal right-click actions and internal editor display preferences.
- Enhanced localization files to support new settings descriptions and options in multiple languages.
- Implemented compatibility functions for the new enums to ensure smooth transitions from previous settings.
- Updated the application logic to handle the new settings in the user interface and configuration management.
2026-09-30 09:24:49 +08:00
Kang 676c1b6d1d feat(ai): enhance agent functionality with JSON protocol and localization support
- Introduced a new JSON protocol for agent interactions, allowing for structured command execution and responses.
- Added support for traditional Chinese and Korean languages in agent prompts and responses.
- Implemented validation for AI session scopes to ensure proper agent type and terminal scope matching.
- Enhanced the agent command execution flow with improved error handling and fallback mechanisms.
- Updated tests to cover new features and ensure robustness in multi-language support and JSON protocol handling.
2026-09-30 00:52:01 +08:00
Kang 6a612c4398 fix(desktop): avoid non-Windows unused mut 2026-09-29 21:25:39 +08:00
Kang 266c45ef3d Merge branch 'migration/gpui' of https://github.com/nyakang/nyaterm into migration/gpui 2026-09-29 20:07:21 +08:00
Kang d37cd2a042 feat(conpty): integrate bundled ConPTY support for Windows
- Added support for a bundled ConPTY implementation on Windows, enhancing local terminal functionality.
- Updated the Cargo.toml and Cargo.lock to include the new `nyaterm-transport` dependency.
- Implemented configuration and status checks for the bundled ConPTY in the application.
- Enhanced the UI to display ConPTY status and added localization for related messages in multiple languages.
- Updated release scripts to package and verify ConPTY files for Windows distributions.
- Added tests to ensure proper functionality and integration of the ConPTY feature.
2026-09-29 20:07:19 +08:00
Kang 7b32fb50bc Merge pull request #816 from LunaSpica/fix/gpui-connection-icon-popover
fix(ui): 修复 GPUI 连接图标弹层背景透出
2026-09-29 19:06:57 +08:00
Yue-Sui 3a535878cc fix(ui): 限制连接图标弹层高度并统一图标布局 2026-09-29 18:52:02 +08:00
Kang cb87fd0267 feat(recording): implement session rekeying and disconnection handling
- Added support for rekeying sessions in the recording feature, allowing for seamless session ID updates.
- Introduced a mechanism to disconnect sessions, ensuring proper cleanup and state management.
- Enhanced the recording pipeline to handle rekeyed sessions and maintain accurate recording states.
- Updated tests to validate the new rekeying and disconnection functionalities, ensuring reliability during session transitions.
2026-09-29 18:27:52 +08:00
Kang 9f443c888d feat(terminal): implement terminal input line resynchronization for tab completion (#820)
- Added functionality to resync terminal input lines with the expected command after tab completion.
- Introduced a new method in the recording pipeline to handle input line resynchronization.
- Enhanced the session capture state to manage input before tab and ensure correct input recovery.
- Updated tests to validate the new resynchronization behavior during tab completion scenarios.
2026-09-29 18:11:36 +08:00
Kang 19fb63e4d7 refactor(ui): adjust layout properties for update overlay and app menu badge
- Removed max height constraint from the update overlay to allow for more flexible height adjustments.
- Changed height setting for the update release notes to ensure proper display within the viewport.
- Updated positioning of app menu badge elements for improved alignment and visibility.
2026-09-29 14:27:39 +08:00
Yue-Sui e3cd043001 fix(ui): 让连接图标弹层随内容增高 2026-09-29 13:39:18 +08:00
Kang 543e77a580 fix(terminal): honor credential autofill password source
Resolve saved account and connection passwords according to ConnectionAuth::uses_account_password, including legacy records. Cover stale connection records, missing or unavailable account passwords, and non-password auth with real store tests.

Validation: cargo fmt --check; cargo test -p nyaterm-core credential_autofill; cargo test -p nyaterm-desktop --lib credential_autofill; cargo check -p nyaterm-desktop (Windows).
2026-09-29 13:35:19 +08:00
Yue-Sui 0c2bda218a fix(ui): 确保连接图标列表可滚动 2026-09-29 13:33:02 +08:00
Yue-Sui 4365afaac7 fix(ui): 修复 GPUI 连接图标弹层背景透出 2026-09-29 13:08:10 +08:00
Kang 5db6d5b347 Merge remote-tracking branch 'origin/migration/gpui' into pr/772 2026-09-29 11:16:04 +08:00
Kang 4aae108050 chore(release): bump version to 2.0.0-preview.4 v2.0.0-preview.4 2026-09-29 10:53:12 +08:00
Kang 678769d154 fix(terminal): restrict terminal actions to focused input
- Added checks to ensure terminal actions (copy, paste, select all) only execute when the terminal input is focused.
- Implemented mouse event propagation prevention to enhance user interaction handling in the terminal surface.
- Improved key event handling to respect focus state, ensuring proper user activity tracking.
2026-09-29 10:52:03 +08:00
Kang 6f85024bc1 feat(terminal): enhance search functionality with improved occurrence handling
- Introduced `TerminalGridOccurrence` to group soft-wrapped segments for search results.
- Updated search methods to support range modes, allowing for more flexible matching criteria.
- Enhanced the terminal search state to manage pending search requests and results more effectively.
- Added logic to handle search result truncation and visibility, ensuring accurate feedback during searches.
- Implemented tests to validate the new search behavior and ensure correct handling of edge cases.
2026-09-29 10:31:02 +08:00
Kang fc19ed2807 feat(cloud-sync): integrate nyaterm-store and serde_json for enhanced snapshot handling
- Added `nyaterm-store` and `serde_json` as dependencies in the Cargo.toml.
- Implemented a new cloud snapshot decode helper in the main application to handle snapshot decoding requests.
- Introduced tests for the cloud snapshot decode helper to validate functionality and error handling.
- Enhanced cloud sync error handling and added new checks for snapshot integrity and size limits.
- Updated localization files to include new messages related to cloud sync operations.
2026-09-29 08:34:59 +08:00
moonmicah 89a4a3451b test(terminal): pin the connection password store fill against a real database
Addresses review follow-ups on the connection-password autofill.

connection_has_resolvable_password now reuses
connection_auth_inline_password for the inline case instead of reading
auth.password directly. The two are not equivalent: the helper also
excludes a locked catalog shape (has_password with ciphertext still in
password), so the gate no longer has to reason about that trap twice.
The hydrated plaintext case the raw field check used to cover is kept,
and connection_has_resolvable_password_reads_catalog_shape pins it.

Adds connection_password_resolves_from_store_to_the_terminal_payload,
which drives a real ConnectionStore instead of only the candidate gate,
so the resolve half of the fill path is covered: a connection that is
offered does resolve, the payload is the secret plus a carriage return,
and an unknown connection id is MissingConnection.

The last hop -- the actual session write -- still has no harness, since
standing up a live session in a unit test does not exist yet.
2026-09-29 08:24:34 +08:00
moonmicah 7db10751f4 fix(terminal): require confirmation before autofilling a connection password
Terminal output must never authorize sending a connection password, so a
reply that resolves to a connection-password candidate is downgraded to a
suggestion in credential_autofill_action. Only the pending-vault path, which
follows an explicit username-suggestion selection, can still auto-send.

Also fix three candidate-detection defects:

- Gate connection-password candidates on credential_prompt_requests_password
  so PIN, OTP, passcode, verification/auth code and MFA challenges are
  refused instead of being treated as login-password prompts. Vault
  credentials keep the broad CredentialPromptKind::Password match.
- Compare the prompt target with the effective session login user from
  SessionLaunchConfig instead of the catalog connection's configured
  username, which saved-account auth can override at connect time.
- Require a password source the connection can actually resolve: an account
  reference only qualifies when uses_account_password() is set, otherwise the
  connection's own stored password must exist.

pin and ??? are also dropped from the prompt target-user patterns, since a
code challenge does not ask for the account's login secret.

Tests: cargo test -p nyaterm-core -p nyaterm-desktop, cargo clippy
--workspace --all-targets, cargo fmt --all -- --check, and
scripts/ci/check_architecture.py.
2026-09-29 08:24:34 +08:00
moonmicah 05973b49cd feat(terminal): autofill password prompts from connection password candidates 2026-09-29 08:24:34 +08:00
Kang 095d4cb33e refactor(clipboard): improve advertisement handling and add initial advertisement logic
- Introduced a new method `initial_advertisement` to handle clipboard message creation for initial copy operations.
- Renamed `advertise_current` to `current_advertisement` for clarity and updated its implementation.
- Updated the `on_request_format_list` method to utilize the new initial advertisement logic.
- Added a test to ensure the initial advertisement correctly uses the text format when file capability is available.
2026-09-29 01:20:18 +08:00
Kang 1d3a496db0 feat(tooltip): enhance tooltip font handling and add tests for font fallback tracking
- Updated the tooltip component to utilize the current UI font and its fallbacks.
- Introduced a new function to refresh font settings in the root component when the theme changes.
- Added tests to verify that tooltips correctly reflect font changes and fallback settings after updates.
- Ensured that the root component carries the complete font stack for proper rendering of tooltips.
2026-09-29 00:55:03 +08:00
Kang e3e506b7b6 refactor(terminal): update height and line height settings for terminal surfaces (#804)
- Replaced `min_h` with `h` for setting the height of terminal surface elements.
- Added `line_height` to ensure consistent line spacing based on cell height.
- Adjusted layout properties to improve rendering of terminal surfaces.
2026-09-29 00:47:16 +08:00
Kang c679ddba72 refactor(clipboard): rename and restructure clipboard advertisement handling
- Renamed `advertise_current` to `current_advertisement` for clarity and updated its return type to `ClipboardMessage`.
- Refactored the logic to handle clipboard message creation more cleanly, ensuring an empty format list is included in the initial advertisement.
- Added a new test to verify that the initial clipboard advertisement correctly includes an empty format list when no text is present.
2026-09-29 00:46:43 +08:00
Kang 7a8dc859ef refactor(connection-editor): streamline credential overlay handling and improve button interactions (#807)
- Replaced direct div usage with `full_window_input_layer` for the credential overlay.
- Enhanced the close button functionality to ensure it properly handles clicks while the overlay is active.
- Added debug selectors for better testing and debugging of UI elements.
- Introduced a new test to verify that the credential manager blocks editor clicks and closes correctly.
2026-09-29 00:15:29 +08:00
Kang 1fcb95eedf feat(remote-desktop): enhance key mapping and modifier handling (#809)
- Implemented `rdp_key_modifiers` function to correctly handle shifted punctuation keys in RDP sessions.
- Updated input handling in the remote desktop feature to differentiate between VNC and RDP sessions.
- Added tests to verify that shifted printable keys use their physical scan codes correctly.
- Refactored input initialization to streamline the process based on session type.
2026-09-29 00:04:18 +08:00