diff --git a/CHANGELOG.md b/CHANGELOG.md index d67263859..ddde1ac85 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +### Removed +- Removed the Ask Sourcebot first-visit tutorial banner. [#1675](https://github.com/sourcebot-dev/sourcebot/pull/1675) + ## [5.1.14] - 2026-09-17 ### Added diff --git a/packages/web/public/ask_sb_tutorial_at_mentions.png b/packages/web/public/ask_sb_tutorial_at_mentions.png deleted file mode 100644 index 412b02fe1..000000000 Binary files a/packages/web/public/ask_sb_tutorial_at_mentions.png and /dev/null differ diff --git a/packages/web/public/ask_sb_tutorial_citations.png b/packages/web/public/ask_sb_tutorial_citations.png deleted file mode 100644 index 2266fdb5d..000000000 Binary files a/packages/web/public/ask_sb_tutorial_citations.png and /dev/null differ diff --git a/packages/web/public/ask_sb_tutorial_search_scope.png b/packages/web/public/ask_sb_tutorial_search_scope.png deleted file mode 100644 index 33376ca80..000000000 Binary files a/packages/web/public/ask_sb_tutorial_search_scope.png and /dev/null differ diff --git a/packages/web/src/actions.ts b/packages/web/src/actions.ts index 0483e75f0..c8f7a7a04 100644 --- a/packages/web/src/actions.ts +++ b/packages/web/src/actions.ts @@ -12,7 +12,7 @@ import { createLogger, env, generateApiKey, getTokenFromConfig } from "@sourcebo import { StatusCodes } from "http-status-codes"; import { cookies } from "next/headers"; import { getBrowsePath } from "./app/(app)/browse/hooks/utils"; -import { AGENTIC_SEARCH_TUTORIAL_DISMISSED_COOKIE_NAME, MOBILE_UNSUPPORTED_SPLASH_SCREEN_DISMISSED_COOKIE_NAME } from "./lib/constants"; +import { MOBILE_UNSUPPORTED_SPLASH_SCREEN_DISMISSED_COOKIE_NAME } from "./lib/constants"; import { RepositoryQuery } from "./lib/types"; import { withAuth, withOptionalAuth } from "./middleware/withAuth"; @@ -367,16 +367,6 @@ export const getRepoImage = async (repoId: number): Promise sew(async () => { - const cookieStore = await cookies(); - cookieStore.set(AGENTIC_SEARCH_TUTORIAL_DISMISSED_COOKIE_NAME, dismissed ? "true" : "false", { - httpOnly: false, // Allow client-side access - maxAge: 365 * 24 * 60 * 60, // 1 year in seconds - }); - return true; -}); - // eslint-disable-next-line authz/require-auth-wrapper -- UI-only preference cookie, no DB access export const dismissMobileUnsupportedSplashScreen = async () => sew(async () => { const cookieStore = await cookies(); diff --git a/packages/web/src/app/(app)/chat/components/tutorialDialog.tsx b/packages/web/src/app/(app)/chat/components/tutorialDialog.tsx deleted file mode 100644 index d8663e95d..000000000 --- a/packages/web/src/app/(app)/chat/components/tutorialDialog.tsx +++ /dev/null @@ -1,349 +0,0 @@ -"use client" - -import { setAgenticSearchTutorialDismissedCookie } from "@/actions" -import { Button } from "@/components/ui/button" -import { Dialog, DialogContent, DialogTitle } from "@/components/ui/dialog" -import { ModelProviderLogo } from "@/features/chat/components/chatBox/modelProviderLogo" -import { cn } from "@/lib/utils" -import mentionsDemo from "@/public/ask_sb_tutorial_at_mentions.png" -import citationsDemo from "@/public/ask_sb_tutorial_citations.png" -import searchScopeDemo from "@/public/ask_sb_tutorial_search_scope.png" -import logoDarkSmall from "@/public/sb_logo_dark_small.png" -import { useQuery } from "@tanstack/react-query" -import { - ArrowLeftRightIcon, - AtSignIcon, - BookMarkedIcon, - BookTextIcon, - ChevronLeft, - ChevronRight, - CircleCheckIcon, - FileIcon, - FolderIcon, - GitCommitHorizontalIcon, - LibraryBigIcon, - ScanSearchIcon, - StarIcon, - TicketIcon, -} from "lucide-react" -import Image from "next/image" -import Link from "next/link" -import { useCallback, useState } from "react" - - - - -// Star button component that fetches GitHub star count -const GitHubStarButton = () => { - const { data: starCount, isLoading, isError } = useQuery({ - queryKey: ['github-stars', 'sourcebot-dev/sourcebot'], - queryFn: async () => { - const response = await fetch('https://api.github.com/repos/sourcebot-dev/sourcebot') - if (!response.ok) { - throw new Error('Failed to fetch star count') - } - const data = await response.json() - return data.stargazers_count as number; - }, - staleTime: 5 * 60 * 1000, // 5 minutes - gcTime: 30 * 60 * 1000, // 30 minutes - retry: 3, - retryDelay: attemptIndex => Math.min(1000 * 2 ** attemptIndex, 30000), - }) - - const formatStarCount = (count: number) => { - if (count >= 1000) { - return `${(count / 1000).toFixed(1)}k` - } - return count.toString() - } - - return ( - - ) -} - - -const tutorialSteps = [ - { - leftContent: ( -
-
-

- Ask Sourcebot. -

-

- Ask questions about your entire codebase in natural language. - Get back responses grounded in code with inline citations. -

-

- Ask Sourcebot is an agentic search tool that can answer questions about your codebase by searching, reading files, navigating references, and more. Supports any compatible LLM. -

-
-
-
- - - - - - - - - -
-
-
- ), - rightContent: ( -