feat: v2.5.4 — Query Explorer folded into Sessions, Windows picker and paths

- Sessions page tabs: Sessions · Events · Agents. QueryExplorer.tsx became
  AgentsTable.tsx (agents only — sessions and events already had tabs);
  /query redirects to /sessions?view=agents and leaves the sidebar.
  GET /api/query is unchanged and still answers all three entities.
- Windows picker opens in front: -EncodedCommand script spends the hidden
  first ShowWindow that windowsHide gives the process, then brings the TopMost
  owner forward via AttachThreadInput (v2.5.3's owner was itself hidden).
- Session page Resume/Fork/Open pane: owningLane and sessionWorktreeName
  match Windows folders (either separator), with a test.
This commit is contained in:
2026-10-06 21:56:51 +07:00
parent af014d9829
commit dd9b23106c
23 changed files with 168 additions and 150 deletions
+8 -5
View File
@@ -1,17 +1,19 @@
/**
* @file History.tsx
* @description Tabbed shell for /sessions that hosts the two views over the same
* event pipeline: the per-session list and the raw activity feed. The active tab
* lives in the `?view=` query param, so `/activity` can redirect into it.
* @description Tabbed shell for /sessions that hosts the three views over the
* same data: the per-session list, the raw activity feed and the agents table.
* The active tab lives in the `?view=` query param, so `/activity` and the old
* `/query` Query Explorer can redirect into it.
* @author Nguyễn Ngọc Trí Vĩ <vinnt@smartgift.vn>
*/
import type { ComponentType } from "react";
import { useSearchParams } from "react-router-dom";
import { useTranslation } from "react-i18next";
import { Activity, FolderOpen } from "lucide-react";
import { Activity, Bot, FolderOpen } from "lucide-react";
import { PageTabs } from "../components/PageTabs";
import { Sessions } from "./Sessions";
import { ActivityFeed } from "./ActivityFeed";
import { AgentsTable } from "./AgentsTable";
interface HistoryView {
id: string;
@@ -21,7 +23,7 @@ interface HistoryView {
}
/**
* Sessions page shell: grouped sessions and the raw event stream as sibling tabs.
* Sessions page shell: sessions, the raw event stream and agents as sibling tabs.
* @returns The tab bar plus the active view.
*/
export function History() {
@@ -31,6 +33,7 @@ export function History() {
const views: HistoryView[] = [
{ id: "sessions", label: t("sessions"), Icon: FolderOpen, Panel: Sessions },
{ id: "events", label: t("activityFeed"), Icon: Activity, Panel: ActivityFeed },
{ id: "agents", label: t("agents"), Icon: Bot, Panel: AgentsTable },
];
const defaultView = views[0]!;
const active = views.find((v) => v.id === params.get("view")) ?? defaultView;