mirror of
https://github.com/sourcebot-dev/sourcebot.git
synced 2025-12-13 04:45:19 +00:00
update trial card content and add events for code host selection on onboard
This commit is contained in:
parent
06ba66da46
commit
b527ec45cb
3 changed files with 26 additions and 7 deletions
|
|
@ -14,6 +14,7 @@ import { useCallback } from "react";
|
|||
import { OnboardingSteps } from "@/lib/constants";
|
||||
import { BackButton } from "./onboardBackButton";
|
||||
import { CodeHostIconButton } from "../../components/codeHostIconButton";
|
||||
import useCaptureEvent from "@/hooks/useCaptureEvent";
|
||||
|
||||
interface ConnectCodeHostProps {
|
||||
nextStep: OnboardingSteps;
|
||||
|
|
@ -80,27 +81,41 @@ interface CodeHostSelectionProps {
|
|||
}
|
||||
|
||||
const CodeHostSelection = ({ onSelect }: CodeHostSelectionProps) => {
|
||||
const captureEvent = useCaptureEvent();
|
||||
|
||||
return (
|
||||
<div className="grid grid-cols-2 sm:grid-cols-4 gap-4">
|
||||
<CodeHostIconButton
|
||||
name="GitHub"
|
||||
logo={getCodeHostIcon("github")!}
|
||||
onClick={() => onSelect("github")}
|
||||
onClick={() => {
|
||||
onSelect("github");
|
||||
captureEvent("wa_onboard_github_selected", {});
|
||||
}}
|
||||
/>
|
||||
<CodeHostIconButton
|
||||
name="GitLab"
|
||||
logo={getCodeHostIcon("gitlab")!}
|
||||
onClick={() => onSelect("gitlab")}
|
||||
onClick={() => {
|
||||
onSelect("gitlab");
|
||||
captureEvent("wa_onboard_gitlab_selected", {});
|
||||
}}
|
||||
/>
|
||||
<CodeHostIconButton
|
||||
name="Gitea"
|
||||
logo={getCodeHostIcon("gitea")!}
|
||||
onClick={() => onSelect("gitea")}
|
||||
onClick={() => {
|
||||
onSelect("gitea");
|
||||
captureEvent("wa_onboard_gitea_selected", {});
|
||||
}}
|
||||
/>
|
||||
<CodeHostIconButton
|
||||
name="Gerrit"
|
||||
logo={getCodeHostIcon("gerrit")!}
|
||||
onClick={() => onSelect("gerrit")}
|
||||
onClick={() => {
|
||||
onSelect("gerrit");
|
||||
captureEvent("wa_onboard_gerrit_selected", {});
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
)
|
||||
|
|
|
|||
|
|
@ -16,11 +16,10 @@ export const ENTERPRISE_FEATURES = [
|
|||
]
|
||||
|
||||
export const TEAM_FEATURES = [
|
||||
"Blazingly fast code search",
|
||||
"Index hundreds of repos from multiple code hosts (GitHub, GitLab, Gerrit, Gitea, etc.). Self-hosted code hosts supported.",
|
||||
"Index thousands of repos from multiple code hosts (GitHub, GitLab, Gerrit, Gitea, etc.). Self-hosted code hosts supported.",
|
||||
"Public and private repos supported.",
|
||||
"Create shareable links to code snippets.",
|
||||
"Powerful regex and symbol search",
|
||||
"Built on-top of zoekt, Google's code search engine. Blazingly fast and powerful (regex, symbol) code search.",
|
||||
]
|
||||
|
||||
export const MOBILE_UNSUPPORTED_SPLASH_SCREEN_DISMISSED_COOKIE_NAME = 'sb.mobile-unsupported-splash-screen-dismissed';
|
||||
|
|
@ -231,6 +231,11 @@ export type PosthogEventMap = {
|
|||
wa_org_domain_updated_fail: {
|
||||
error: string,
|
||||
},
|
||||
//////////////////////////////////////////////////////////////////
|
||||
wa_onboard_github_selected: {},
|
||||
wa_onboard_gitlab_selected: {},
|
||||
wa_onboard_gitea_selected: {},
|
||||
wa_onboard_gerrit_selected: {},
|
||||
}
|
||||
|
||||
export type PosthogEvent = keyof PosthogEventMap;
|
||||
Loading…
Reference in a new issue