feat(frontend): polish connection tree and terminal groups

Add explorer-style tree search in the connections view with
match-path expansion, clearer count highlighting, and a refined
sidebar header layout.

Improve terminal tab grouping by keeping new sessions appended
within their server group, highlighting the active group, and
deduplicating broadcast actions to send commands once per server.
This commit is contained in:
yinjianm
2026-03-25 23:19:53 +08:00
parent 385e916c54
commit 1662b2b9e8
15 changed files with 563 additions and 83 deletions
@@ -241,6 +241,7 @@ import { useWorkspaceEventEmitter } from '../composables/workspaceEvents';
import { useSessionStore } from '../stores/session.store';
import type { SessionState } from '../stores/session/types';
import { useConnectionsStore } from '../stores/connections.store';
import { getUniqueConnectedSshSessions } from '../utils/sessionSelection';
const quickCommandsStore = useQuickCommandsStore();
const quickCommandTagsStore = useQuickCommandTagsStore();
@@ -763,13 +764,7 @@ const closeQuickCommandContextMenu = () => {
const handleQuickCommandMenuAction = (action: 'sendToAllSessions', command: QuickCommandFE) => {
closeQuickCommandContextMenu();
if (action === 'sendToAllSessions') {
const activeSshSessions = Array.from(sessionStore.sessions.values()).filter(
(s: SessionState) => {
if (s.wsManager.connectionStatus.value !== 'connected') return false;
const connInfo = connectionsStore.connections.find(c => c.id === Number(s.connectionId));
return connInfo?.type === 'SSH';
}
);
const activeSshSessions = getUniqueConnectedSshSessions(sessionStore.sessions, connectionsStore.connections);
if (activeSshSessions.length > 0) {
activeSshSessions.forEach((session: SessionState) => {