11'use client' ;
22
33import { useFlags } from '@databuddy/sdk/react' ;
4- import { FlagIcon } from '@phosphor-icons/react' ;
4+ import { FlagIcon , InfoIcon } from '@phosphor-icons/react' ;
55import { useAtom } from 'jotai' ;
66import { useParams } from 'next/navigation' ;
77import { Suspense , useCallback , useState } from 'react' ;
88import { Badge } from '@/components/ui/badge' ;
99import { Card , CardContent } from '@/components/ui/card' ;
10+ import {
11+ Tooltip ,
12+ TooltipContent ,
13+ TooltipTrigger ,
14+ } from '@/components/ui/tooltip' ;
1015import { useWebsite } from '@/hooks/use-websites' ;
1116import { trpc } from '@/lib/trpc' ;
1217import { isAnalyticsRefreshingAtom } from '@/stores/jotai/filterAtoms' ;
@@ -145,7 +150,7 @@ export default function FlagsPage() {
145150 websiteName = { website ?. name || undefined }
146151 />
147152 { experimentFlag . isReady && (
148- < div className = "flex items-center gap-2 " >
153+ < div className = "flex items-center gap-3 " >
149154 < FlagIcon
150155 className = "h-5 w-5"
151156 color = { experimentFlag . enabled ? 'red' : 'blue' }
@@ -157,6 +162,23 @@ export default function FlagsPage() {
157162 ) : (
158163 < Badge className = "bg-blue-500 text-white" > Blue Team</ Badge >
159164 ) }
165+ < Tooltip >
166+ < TooltipTrigger asChild >
167+ < InfoIcon className = "h-4 w-4" weight = "duotone" />
168+ </ TooltipTrigger >
169+ < TooltipContent className = "max-w-xs" >
170+ < div className = "space-y-2" >
171+ < p className = "font-medium" > A/B Test Experiment</ p >
172+ < p className = "text-xs leading-relaxed" >
173+ This is a proof-of-concept feature flag demonstrating A/B
174+ testing capabilities. Approximately 50% of users are randomly
175+ assigned to the "Red Team" experience, while the other 50% see
176+ the "Blue Team" experience. This live experiment helps test
177+ feature flag functionality and user experience variations.
178+ </ p >
179+ </ div >
180+ </ TooltipContent >
181+ </ Tooltip >
160182 </ div >
161183 ) }
162184 < Suspense fallback = { < FlagsListSkeleton /> } >
0 commit comments