feat: Update tracking (#3805)
* Update tracking * [autofix.ci] apply automated fixes * cleanup --------- Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
This commit is contained in:
parent
56802bada6
commit
2bd5d4b911
7 changed files with 17 additions and 3 deletions
|
|
@ -11,6 +11,7 @@ import {
|
||||||
STATUS_INACTIVE,
|
STATUS_INACTIVE,
|
||||||
} from "@/constants/constants";
|
} from "@/constants/constants";
|
||||||
import { BuildStatus } from "@/constants/enums";
|
import { BuildStatus } from "@/constants/enums";
|
||||||
|
import { track } from "@/customization/utils/analytics";
|
||||||
import { useDarkStore } from "@/stores/darkStore";
|
import { useDarkStore } from "@/stores/darkStore";
|
||||||
import useFlowStore from "@/stores/flowStore";
|
import useFlowStore from "@/stores/flowStore";
|
||||||
import { useShortcutsStore } from "@/stores/shortcuts";
|
import { useShortcutsStore } from "@/stores/shortcuts";
|
||||||
|
|
@ -160,6 +161,7 @@ export default function NodeStatus({
|
||||||
if (buildStatus === BuildStatus.BUILDING || isBuilding) return;
|
if (buildStatus === BuildStatus.BUILDING || isBuilding) return;
|
||||||
setValidationStatus(null);
|
setValidationStatus(null);
|
||||||
buildFlow({ stopNodeId: nodeId });
|
buildFlow({ stopNodeId: nodeId });
|
||||||
|
track("Flow Build - Clicked", { stopNodeId: nodeId });
|
||||||
}}
|
}}
|
||||||
unstyled
|
unstyled
|
||||||
className="group p-1"
|
className="group p-1"
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,7 @@ import {
|
||||||
} from "@/controllers/API/queries/folders";
|
} from "@/controllers/API/queries/folders";
|
||||||
import { useGetDownloadFolders } from "@/controllers/API/queries/folders/use-get-download-folders";
|
import { useGetDownloadFolders } from "@/controllers/API/queries/folders/use-get-download-folders";
|
||||||
import { ENABLE_CUSTOM_PARAM } from "@/customization/feature-flags";
|
import { ENABLE_CUSTOM_PARAM } from "@/customization/feature-flags";
|
||||||
|
import { track } from "@/customization/utils/analytics";
|
||||||
import { createFileUpload } from "@/helpers/create-file-upload";
|
import { createFileUpload } from "@/helpers/create-file-upload";
|
||||||
import { getObjectsFromFilelist } from "@/helpers/get-objects-from-filelist";
|
import { getObjectsFromFilelist } from "@/helpers/get-objects-from-filelist";
|
||||||
import useUploadFlow from "@/hooks/flows/use-upload-flow";
|
import useUploadFlow from "@/hooks/flows/use-upload-flow";
|
||||||
|
|
@ -151,6 +152,7 @@ const SideBarFoldersButtonsComponent = ({
|
||||||
description: "",
|
description: "",
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
track("Create New Folder");
|
||||||
}
|
}
|
||||||
|
|
||||||
function handleEditFolderName(e, name): void {
|
function handleEditFolderName(e, name): void {
|
||||||
|
|
@ -401,6 +403,7 @@ const SideBarFoldersButtonsComponent = ({
|
||||||
handleDownloadFolder(item.id!);
|
handleDownloadFolder(item.id!);
|
||||||
e.stopPropagation();
|
e.stopPropagation();
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
|
track("Folder Exported", { folderId: item.id! });
|
||||||
}}
|
}}
|
||||||
unstyled
|
unstyled
|
||||||
>
|
>
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
import { useDeleteBuilds } from "@/controllers/API/queries/_builds";
|
import { useDeleteBuilds } from "@/controllers/API/queries/_builds";
|
||||||
import { usePostUploadFile } from "@/controllers/API/queries/files/use-post-upload-file";
|
import { usePostUploadFile } from "@/controllers/API/queries/files/use-post-upload-file";
|
||||||
|
import { track } from "@/customization/utils/analytics";
|
||||||
import { useEffect, useRef, useState } from "react";
|
import { useEffect, useRef, useState } from "react";
|
||||||
import ShortUniqueId from "short-unique-id";
|
import ShortUniqueId from "short-unique-id";
|
||||||
import IconComponent from "../../../../components/genericIconComponent";
|
import IconComponent from "../../../../components/genericIconComponent";
|
||||||
|
|
@ -284,9 +285,10 @@ export default function ChatView({
|
||||||
chatValue={chatValue}
|
chatValue={chatValue}
|
||||||
noInput={!inputTypes.includes("ChatInput")}
|
noInput={!inputTypes.includes("ChatInput")}
|
||||||
lockChat={lockChat}
|
lockChat={lockChat}
|
||||||
sendMessage={({ repeat, files }) =>
|
sendMessage={({ repeat, files }) => {
|
||||||
sendMessage({ repeat, files })
|
sendMessage({ repeat, files });
|
||||||
}
|
track("Playground Message Sent");
|
||||||
|
}}
|
||||||
setChatValue={(value) => {
|
setChatValue={(value) => {
|
||||||
setChatValue(value);
|
setChatValue(value);
|
||||||
}}
|
}}
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,4 @@
|
||||||
|
import { track } from "@/customization/utils/analytics";
|
||||||
import useFlowStore from "@/stores/flowStore";
|
import useFlowStore from "@/stores/flowStore";
|
||||||
import { ReactNode, forwardRef, useEffect, useState } from "react";
|
import { ReactNode, forwardRef, useEffect, useState } from "react";
|
||||||
import EditFlowSettings from "../../components/editFlowSettingsComponent";
|
import EditFlowSettings from "../../components/editFlowSettingsComponent";
|
||||||
|
|
@ -66,6 +67,7 @@ const ExportModal = forwardRef(
|
||||||
description,
|
description,
|
||||||
);
|
);
|
||||||
setOpen(false);
|
setOpen(false);
|
||||||
|
track("Flow Exported", { flowId: currentFlow!.id });
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<BaseModal.Trigger asChild>{props.children}</BaseModal.Trigger>
|
<BaseModal.Trigger asChild>{props.children}</BaseModal.Trigger>
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
import { useCustomNavigate } from "@/customization/hooks/use-custom-navigate";
|
import { useCustomNavigate } from "@/customization/hooks/use-custom-navigate";
|
||||||
|
import { track } from "@/customization/utils/analytics";
|
||||||
import useAddFlow from "@/hooks/flows/use-add-flow";
|
import useAddFlow from "@/hooks/flows/use-add-flow";
|
||||||
import { useParams } from "react-router-dom";
|
import { useParams } from "react-router-dom";
|
||||||
import {
|
import {
|
||||||
|
|
@ -19,6 +20,7 @@ export default function NewFlowCardComponent() {
|
||||||
addFlow().then((id) => {
|
addFlow().then((id) => {
|
||||||
navigate(`/flow/${id}${folderId ? `/folder/${folderId}` : ""}`);
|
navigate(`/flow/${id}${folderId ? `/folder/${folderId}` : ""}`);
|
||||||
});
|
});
|
||||||
|
track("New Flow Created: Blank Flow");
|
||||||
}}
|
}}
|
||||||
className="h-64 w-80 cursor-pointer bg-background pt-4"
|
className="h-64 w-80 cursor-pointer bg-background pt-4"
|
||||||
data-testid="blank-flow"
|
data-testid="blank-flow"
|
||||||
|
|
|
||||||
|
|
@ -11,6 +11,7 @@ import BasicPrompt from "../../../../assets/undraw_short_bio_re_fmx0.svg?react";
|
||||||
import TransferFiles from "../../../../assets/undraw_transfer_files_re_a2a9.svg?react";
|
import TransferFiles from "../../../../assets/undraw_transfer_files_re_a2a9.svg?react";
|
||||||
|
|
||||||
import { useCustomNavigate } from "@/customization/hooks/use-custom-navigate";
|
import { useCustomNavigate } from "@/customization/hooks/use-custom-navigate";
|
||||||
|
import { track } from "@/customization/utils/analytics";
|
||||||
import useAddFlow from "@/hooks/flows/use-add-flow";
|
import useAddFlow from "@/hooks/flows/use-add-flow";
|
||||||
import {
|
import {
|
||||||
Card,
|
Card,
|
||||||
|
|
@ -144,6 +145,7 @@ export default function UndrawCardComponent({
|
||||||
addFlow({ flow }).then((id) => {
|
addFlow({ flow }).then((id) => {
|
||||||
navigate(`/flow/${id}/folder/${folderIdUrl}`);
|
navigate(`/flow/${id}/folder/${folderIdUrl}`);
|
||||||
});
|
});
|
||||||
|
track(`New Flow Created: ${flow.name} Template`);
|
||||||
}}
|
}}
|
||||||
className="h-64 w-80 cursor-pointer bg-background pt-4"
|
className="h-64 w-80 cursor-pointer bg-background pt-4"
|
||||||
>
|
>
|
||||||
|
|
|
||||||
|
|
@ -295,6 +295,7 @@ export default function Page({ view }: { view?: boolean }): JSX.Element {
|
||||||
(params: Connection) => {
|
(params: Connection) => {
|
||||||
takeSnapshot();
|
takeSnapshot();
|
||||||
onConnect(params);
|
onConnect(params);
|
||||||
|
track("New Component Connection Added");
|
||||||
},
|
},
|
||||||
[takeSnapshot, onConnect],
|
[takeSnapshot, onConnect],
|
||||||
);
|
);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue