diff --git a/app/client/src/components/editorComponents/ApiResponseView.tsx b/app/client/src/components/editorComponents/ApiResponseView.tsx index f44ef9a25c..0c95c332d3 100644 --- a/app/client/src/components/editorComponents/ApiResponseView.tsx +++ b/app/client/src/components/editorComponents/ApiResponseView.tsx @@ -387,6 +387,11 @@ function ApiResponseView(props: Props) { const selectedResponseTab = useSelector(getApiPaneResponseSelectedTab); const updateSelectedResponseTab = useCallback((tabKey: string) => { + if (tabKey === DEBUGGER_TAB_KEYS.ERROR_TAB) { + AnalyticsUtil.logEvent("OPEN_DEBUGGER", { + source: "API_PANE", + }); + } dispatch(setApiPaneResponseSelectedTab(tabKey)); }, []); diff --git a/app/client/src/components/editorComponents/Debugger/DebuggerTabs.tsx b/app/client/src/components/editorComponents/Debugger/DebuggerTabs.tsx index d527bf1bcc..61325ba0a9 100644 --- a/app/client/src/components/editorComponents/Debugger/DebuggerTabs.tsx +++ b/app/client/src/components/editorComponents/Debugger/DebuggerTabs.tsx @@ -7,6 +7,7 @@ import { setCanvasDebuggerSelectedTab, showDebugger, } from "actions/debuggerActions"; +import AnalyticsUtil from "utils/AnalyticsUtil"; import Errors from "./Errors"; import Resizer, { ResizerCSS } from "./Resizer"; import EntityDeps from "./EntityDependecies"; @@ -72,6 +73,11 @@ function DebuggerTabs() { const panelRef: RefObject = useRef(null); const selectedTab = useSelector(getSelectedCanvasDebuggerTab); const setSelectedTab = (tabKey: string) => { + if (tabKey === DEBUGGER_TAB_KEYS.ERROR_TAB) { + AnalyticsUtil.logEvent("OPEN_DEBUGGER", { + source: "WIDGET_EDITOR", + }); + } dispatch(setCanvasDebuggerSelectedTab(tabKey)); }; const onClose = () => dispatch(showDebugger(false)); diff --git a/app/client/src/pages/Editor/QueryEditor/EditorJSONtoForm.tsx b/app/client/src/pages/Editor/QueryEditor/EditorJSONtoForm.tsx index 1aa93e255c..68342db478 100644 --- a/app/client/src/pages/Editor/QueryEditor/EditorJSONtoForm.tsx +++ b/app/client/src/pages/Editor/QueryEditor/EditorJSONtoForm.tsx @@ -758,6 +758,11 @@ export function EditorJSONtoForm(props: Props) { }); const onResponseTabSelect = (tabKey: string) => { + if (tabKey === DEBUGGER_TAB_KEYS.ERROR_TAB) { + AnalyticsUtil.logEvent("OPEN_DEBUGGER", { + source: "QUERY_PANE", + }); + } updateActionResponseDisplayFormat({ id: currentActionConfig?.id || "", field: "responseDisplayFormat", diff --git a/app/shared/ast/src/index.ts b/app/shared/ast/src/index.ts index a144366904..eeba8fcda3 100644 --- a/app/shared/ast/src/index.ts +++ b/app/shared/ast/src/index.ts @@ -1,4 +1,4 @@ -import acorn, { parse, Node, SourceLocation, Options, Comment } from "acorn"; +import { parse, Node, SourceLocation, Options, Comment } from "acorn"; import { ancestor, simple } from "acorn-walk"; import { ECMA_VERSION, NodeTypes } from "./constants/ast"; import { has, isFinite, isString, memoize, toPath } from "lodash";