Verified Commit dabc68b4 authored by Juhee Lee's avatar Juhee Lee Committed by GitLab
Browse files

chore: register chat handlers for duo agent platform v2 webview

parent b76e05d2
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -953,7 +953,7 @@
          "type": "webview",
          "id": "gl.webview.root.duoAgentPlatform",
          "name": "",
          "when": "config.gitlab.duoAgentPlatform.enabled && (gitlab.featureFlags.duoAgentPlatformNext)"
          "when": "config.gitlab.duoAgentPlatform.enabled && gitlab.featureFlags.duoAgentPlatformNext && (gitlab.featureFlags.duo_agentic_chat || gitlab.featureFlags.duo_workflow)"
        }
      ]
    },
+2 −2
Original line number Diff line number Diff line
@@ -20,7 +20,7 @@ export const KNOWLEDGE_GRAPH_WEBVIEW_ID = 'knowledge-graph';
export const SECURITY_VULNS_WEBVIEW_ID = 'security-vuln-details';
export const AGENTIC_TABS_WEBVIEW_ID = 'agentic-tabs';
export const MCP_DASHBOARD_WEBVIEW_ID = 'root/mcp';
export const AGENT_PLATFORM_DUO_UI_NEXT_WEBVIEW_ID = 'root/duoAgentPlatform';
export const AGENT_PLATFORM_V2_WEBVIEW_ID = 'root/duoAgentPlatform';
export const FLOW_BUILDER_WEBVIEW_ID = 'root/flow';

export const LS_WEBVIEW_IDS = [
@@ -29,6 +29,6 @@ export const LS_WEBVIEW_IDS = [
  AGENTIC_CHAT_WEBVIEW_ID,
  AGENTIC_TABS_WEBVIEW_ID,
  MCP_DASHBOARD_WEBVIEW_ID,
  AGENT_PLATFORM_DUO_UI_NEXT_WEBVIEW_ID,
  AGENT_PLATFORM_V2_WEBVIEW_ID,
  FLOW_BUILDER_WEBVIEW_ID,
];
+6 −3
Original line number Diff line number Diff line
@@ -6,7 +6,7 @@ import {
  SECURITY_VULNS_WEBVIEW_ID,
  AGENTIC_TABS_WEBVIEW_ID,
  MCP_DASHBOARD_WEBVIEW_ID,
  AGENT_PLATFORM_DUO_UI_NEXT_WEBVIEW_ID,
  AGENT_PLATFORM_V2_WEBVIEW_ID,
  FLOW_BUILDER_WEBVIEW_ID,
} from '../constants';

@@ -27,14 +27,17 @@ import { LSDuoChatWebviewController } from './duo_chat/duo_chat_controller';
import { registerKnowledgeGraphHandlers } from './knowldege_graph/knowledge_graph_handler';
import { KnowledgeGraphWebview } from './knowldege_graph/knowledge_graph_webview';

const CHAT_WEBVIEW_IDS = [DUO_CHAT_WEBVIEW_ID, AGENTIC_CHAT_WEBVIEW_ID];
const CHAT_WEBVIEW_IDS = [
  DUO_CHAT_WEBVIEW_ID,
  AGENTIC_CHAT_WEBVIEW_ID,
  AGENT_PLATFORM_V2_WEBVIEW_ID,
];

// webviews that show in the VS Code panels, sidebar or other custom views (like activity bar)
const PANEL_WEBVIEW_IDS = [
  ...CHAT_WEBVIEW_IDS,
  DUO_WORKFLOW_PANEL_WEBVIEW_ID,
  AGENTIC_TABS_WEBVIEW_ID,
  AGENT_PLATFORM_DUO_UI_NEXT_WEBVIEW_ID,
];

// webviews in the editor area (i.e. tabs)