Persist the user's model selection per agent to settings and
automatically restore it when creating a new session. If the saved
model is no longer available, silently falls back to the agent default.
Separate the floating button and instance selector menu from
FloatingChatView into a standalone FloatingButton component.
This decouples the button lifecycle from any specific chat view
instance and fixes z-index stacking by using separate DOM roots:
- .agent-client-floating-button-root (z-index: 30) for button/menu
- .agent-client-floating-view-root (z-index: 20) for chat windows
- Add setting check before mounting floating chat in onload()
- Handle dynamic toggle in settings to create/close instances
- Prevents unnecessary agent process startup for sidebar-only users
Users can now open multiple independent floating chat windows, each
with its own session. Added instance selector menu when clicking the
floating button with multiple windows open.
Changes:
- Track floating chat instances with unique IDs
- Added window management methods to plugin class
- Instance selector UI with expand/close actions
- Custom events for inter-instance communication
- Fixed header width and updated inline header for consistency
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Introduces controlled input state management in ChatInput and ChatView to enable prompt, send, and cancel broadcast commands across multiple chat views. Adds ChatInputState model, registers new broadcast commands in the plugin, and implements input state sharing and command handling for multi-view operations.
Enable multiple independent agent sessions in separate ChatViews.
Each view manages its own AcpAdapter and agent process.
- Adapter management: singleton → Map<viewId, AcpAdapter>
- Settings Menu for agent switching and new view creation
- Keybinds target last active view only
- Rename activeAgentId → defaultAgentId (with migration)Enable multiple independent agent sessions in separate ChatViews.
Each view manages its own AcpAdapter and agent process.
- Adapter management: singleton → Map<viewId, AcpAdapter>
- Settings Menu for agent switching and new view creation
- Keybinds target last active view only
- Rename activeAgentId → defaultAgentId (with migration)
Add "Frontmatter tag" setting in Export section to customize
the tag applied to exported chat history notes. Supports nested
tags (e.g., projects/agent-client). Leave empty to disable tags.
Default remains "agent-client" for backward compatibility.
Add "Show emojis" toggle in Display settings (default: ON).
When disabled, emoji icons are hidden from tool calls, thoughts,
plans, terminals, and permission results.
Plan entries now use text styles to indicate status regardless of
emoji setting: completed items show strikethrough, in-progress
items are bold.
Add maxNoteLength and maxSelectionLength settings to displaySettings,
allowing users to configure the truncation limits for mentioned notes
and text selections. Default remains 10000 characters with minimum of 1.
- Add settings to plugin interface, defaults, and loadSettings parsing
- Update message-service.ts to accept limits as parameters
- Pass settings through SettingsContext in useChat
- Add UI controls in settings tab under Display Settings
- Change session callback types to Promise<void> for accurate typing
- Add void operator for floating promises in SessionHistoryContent
- Remove unused SessionInfo import from agent-client.port.ts
- Add proper SavedSessionInfo import and type assertion in plugin.ts
Introduces local session saving, retrieval, and deletion in settings-store and exposes these methods via ISettingsAccess. Updates ChatView and useChat to save session metadata on first message, and useSessionHistory to fallback to local sessions when agent session/list is unsupported. SessionHistoryModal now displays a banner when showing local sessions. Updates plugin settings schema and styles for local session support.
Move AcpAdapter creation from ChatView to plugin.getOrCreateAdapter()
for cleaner lifecycle management. The plugin now owns the adapter
directly, eliminating the need to register it from the React component.
Introduces settings to include images in exported markdown files, with options to save images using Obsidian's attachment settings, a custom folder, or embed as Base64. Updates the settings UI, plugin settings, and chat exporter logic to support these new export options.
Introduces a new setting allowing users to choose between 'Enter' or 'Cmd/Ctrl+Enter' as the keyboard shortcut for sending messages in the chat input. Updates the settings UI, plugin settings interface, and chat input logic to respect the selected shortcut.
Enhanced the update check logic to notify users of both stable and prerelease updates depending on their current version. Added 'semver' and its types as dependencies, and updated the version to 0.4.1 in manifest and package files.
Removed the async keyword from the onClose method in ChatView and the cancel-current-message command callback in plugin.ts, as neither function uses await or returns a promise.
Refactored MarkdownTextRenderer to accept an Obsidian App instance instead of the plugin, and updated all usages accordingly. Improved type safety for aliases extraction in Obsidian adapters. Enhanced error handling in AcpAdapter with more precise type checks. Simplified CustomAgentSettings to a type alias. Minor improvements to settings loading and error handling in plugin and hooks.
Prepends 'void' to fire-and-forget async function calls throughout the codebase to explicitly ignore returned promises and prevent unhandled promise rejections. Also updates a workspace method to use 'await' for proper async flow.
Introduces a new workspace event and command to allow users to cancel the current message in the chat view. The ChatView component now listens for the 'agent-client:cancel-message' event and triggers message generation cancellation, and the plugin registers a corresponding command.
Moved core domain models and ports to a new 'domain' directory, relocated the main plugin implementation to 'plugin.ts', and moved terminal manager to 'shared'. Updated all relevant import paths throughout the codebase to reflect the new structure. This refactor improves code organization and maintainability.
2025-11-24 20:59:15 +09:00
Renamed from src/infrastructure/obsidian-plugin/plugin.ts (Browse further)