🐸 Rybbit - open-source and privacy-friendly alternative to Google Analytics that is 10x more intuitive.
Update HomePage and Card components for enhanced clarity and user experience
Bill Yang6441d44f3a01
diff --git a/docs/src/app/(home)/page.tsx b/docs/src/app/(home)/page.tsxindex 79f66cc7e..b46d2d0d5 100644--- a/docs/src/app/(home)/page.tsx+++ b/docs/src/app/(home)/page.tsx@@ -141,7 +141,7 @@ export default function HomePage() {tilt_wrap.className)}>- The Open Source Google Analytics Replacement+ The Modern Google Analytics Replacement</h1><h2 className="text-base md:text-xl pt-4 md:pt-6 px-4 tracking-tight max-w-4xl text-center text-neutral-300 font-light">Next-gen, open source, lightweight, cookieless web & product analytics for everyone.diff --git a/docs/src/components/Cards/Card.tsx b/docs/src/components/Cards/Card.tsxindex 15700c258..3e9403c01 100644--- a/docs/src/components/Cards/Card.tsx+++ b/docs/src/components/Cards/Card.tsx@@ -11,7 +11,9 @@ interface CardProps {export function Card({ title, description, children, className, icon: Icon }: CardProps) {return (- <div className={cn("bg-neutral-800/20 p-4 md:p-6 rounded-xl border border-neutral-800/50", className)}>+ <div+ className={cn("bg-neutral-800/20 p-4 md:p-6 rounded-xl border border-neutral-800/50 overflow-hidden", className)}+ >{Icon && (<div className="w-8 h-8 rounded-lg bg-gradient-to-br from-emerald-500/20 to-emerald-600/10 border border-emerald-500/30 shadow-md shadow-emerald-500/10 flex items-center justify-center mb-3"><Icon className="w-4 h-4 text-emerald-400" />diff --git a/docs/src/components/Cards/Funnels.tsx b/docs/src/components/Cards/Funnels.tsxindex 2b4e83bff..ea8880952 100644--- a/docs/src/components/Cards/Funnels.tsx+++ b/docs/src/components/Cards/Funnels.tsx@@ -13,7 +13,7 @@ const funnelData = [users: 59,},{- step: 4,+ step: 3,label: "Purchase",users: 5,},@@ -29,7 +29,7 @@ export function Funnels() {icon={Filter}>{/* Funnel Steps */}- <div className="space-y-4 mt-4">+ <div className="space-y-4 mt-4 transform -rotate-2 translate-x-8 translate-y-8 bg-neutral-800/20 border border-neutral-800/50 pb-20 rounded-lg p-4">{funnelData.map((item, index) => {const overallConversion = (item.users / totalUsers) * 100;const previousUsers = index > 0 ? funnelData[index - 1].users : item.users;diff --git a/docs/src/components/Cards/RealTimeAnalytics.tsx b/docs/src/components/Cards/RealTimeAnalytics.tsxindex 2cf21b70f..d52086fa8 100644--- a/docs/src/components/Cards/RealTimeAnalytics.tsx+++ b/docs/src/components/Cards/RealTimeAnalytics.tsx@@ -109,7 +109,7 @@ function EventCard({ event, index, isNew }: { event: Event; index: number; isNewreturn (<div- className="absolute w-full rounded-lg bg-neutral-800/50 overflow-hidden p-2 flex flex-col transition-all duration-500"+ className="absolute w-full rounded-md bg-neutral-800/50 overflow-hidden p-2 flex flex-col transition-all duration-500"style={{transform: isAnimating && index === 0 ? `translateY(-70px)` : `translateY(${index * 70}px)`,opacity: isAnimating && index === 0 ? 0 : index < 4 ? 1 : 0,@@ -198,10 +198,12 @@ export function RealTimeAnalytics() {description="See your site performance as it happens with instant data updates and live visitor activity."icon={Activity}>- <div className="relative" style={{ height: "280px" }}>- {events.map((event, index) => (- <EventCard key={event.id} event={event} index={index} isNew={event.isNew} />- ))}+ <div className="space-y-4 mt-4 transform -rotate-2 translate-x-8 translate-y-8 bg-neutral-800/20 border border-neutral-800/50 pb-20 rounded-lg p-4 -mb-[400px]">+ <div className="relative" style={{ height: "280px" }}>+ {events.map((event, index) => (+ <EventCard key={event.id} event={event} index={index} isNew={event.isNew} />+ ))}+ </div></div></Card>);diff --git a/docs/src/components/Cards/SessionReplay.tsx b/docs/src/components/Cards/SessionReplay.tsxindex 25e4b1b8e..a6a6484dc 100644--- a/docs/src/components/Cards/SessionReplay.tsx+++ b/docs/src/components/Cards/SessionReplay.tsx@@ -53,13 +53,13 @@ export function SessionReplay() {description="Watch real user sessions to understand their behavior and identify pain points."icon={Film}>- <div className="bg-neutral-900 rounded-lg overflow-hidden">+ <div className=" mt-4 transform rotate-2 translate-x-8 translate-y-8 bg-neutral-900 rounded-lg -mb-[30px] rounded-xl">{/* Video player container */}- <div className="relative bg-black">+ <div className="relative">{/* Mock website content */}- <div className="bg-neutral-950 relative overflow-hidden">+ <div className="relative overflow-hidden">{/* Browser chrome */}- <div className="bg-neutral-800 h-7 flex items-center px-2 gap-2">+ <div className="bg-neutral-800 h-7 flex items-center px-2 gap-2 rounded-t-lg"><div className="flex gap-1"><div className="w-2 h-2 rounded-full bg-red-500"></div><div className="w-2 h-2 rounded-full bg-yellow-500"></div>@@ -158,7 +158,7 @@ export function SessionReplay() {</div>{/* Video controls */}- <div className="bg-neutral-800/50 backdrop-blur-sm p-2">+ <div className="bg-neutral-800/50 backdrop-blur-sm p-2 pb-10"><div className="flex items-center gap-3">{/* Play/Pause button */}<button@@ -176,9 +176,7 @@ export function SessionReplay() {</div>{/* Time display */}- <div className="text-[10px] text-neutral-400 tabular-nums">- 2:34 / 5:12- </div>+ <div className="text-[10px] text-neutral-400 tabular-nums">2:34 / 5:12</div></div></div></div>diff --git a/docs/src/components/Cards/UserSessions.tsx b/docs/src/components/Cards/UserSessions.tsxindex 7dabf2cc2..e3e5272ee 100644--- a/docs/src/components/Cards/UserSessions.tsx+++ b/docs/src/components/Cards/UserSessions.tsx@@ -12,22 +12,23 @@ export function UserSessions() {description="Track complete user journeys through your site with detailed session timelines."icon={Users}>- <div className="flex justify-between items-center mb-3">- <div className="flex items-center gap-2">- <Avatar size={28} id="john-doe" />- <div>- <div className="text-sm">John Doe</div>- <div className="text-xs text-neutral-400">Today, 14:22 - 14:36 (14m)</div>+ <div className="space-y-4 mt-4 transform rotate-2 translate-x-8 translate-y-4 bg-neutral-800/20 border border-neutral-800/50 pb-20 rounded-lg p-4 -mb-[400px]">+ <div className="flex justify-between items-center mb-3">+ <div className="flex items-center gap-2">+ <Avatar size={28} id="john-doe" />+ <div>+ <div className="text-sm">John Doe</div>+ <div className="text-xs text-neutral-400">Today, 14:22 - 14:36 (14m)</div>+ </div>+ </div>+ <div className="flex items-center gap-1.5">+ <CountryFlag country="US" />+ <Browser browser="Chrome" />+ <OperatingSystem os="macOS" />+ <Laptop className="w-4 h-4" /></div></div>- <div className="flex items-center gap-1.5">- <CountryFlag country="US" />- <Browser browser="Chrome" />- <OperatingSystem os="macOS" />- <Laptop className="w-4 h-4" />- </div>- </div>- {/*+ {/*<div className="flex gap-2 mb-3"><div className="flex items-center gap-1 text-xs bg-blue-500/20 text-blue-400 px-2 py-1 rounded"><Eye className="w-3 h-3" />@@ -39,116 +40,117 @@ export function UserSessions() {</div></div> */}- {/* Timeline */}- <div className="px-1 py-1">- {/* Event 1 */}- <div className="flex mb-2">- <div className="relative flex-shrink-0">- <div className="absolute top-7 left-3.5 w-[1px] bg-neutral-700 h-[calc(100%-16px)]" />- <div className="flex items-center justify-center w-7 h-7 rounded-full bg-blue-900/30 border border-blue-500/50">- <span className="text-xs font-medium">1</span>+ {/* Timeline */}+ <div className="px-1 py-1">+ {/* Event 1 */}+ <div className="flex mb-2">+ <div className="relative flex-shrink-0">+ <div className="absolute top-7 left-3.5 w-[1px] bg-neutral-700 h-[calc(100%-16px)]" />+ <div className="flex items-center justify-center w-7 h-7 rounded-full bg-blue-900/30 border border-blue-500/50">+ <span className="text-xs font-medium">1</span>+ </div></div>- </div>- <div className="flex flex-col ml-2 flex-1">- <div className="flex items-center flex-1 py-0.5">- <Eye className="w-3.5 h-3.5 text-blue-400 mr-2" />- <div className="flex-1 min-w-0 mr-3">- <div className="text-sm truncate">/home</div>+ <div className="flex flex-col ml-2 flex-1">+ <div className="flex items-center flex-1 py-0.5">+ <Eye className="w-3.5 h-3.5 text-blue-400 mr-2" />+ <div className="flex-1 min-w-0 mr-3">+ <div className="text-sm truncate">/home</div>+ </div>+ <div className="text-xs text-neutral-400">14:22:05</div></div>- <div className="text-xs text-neutral-400">14:22:05</div>- </div>- <div className="flex items-center pl-5 mt-0.5">- <div className="text-xs text-neutral-400">- <Clock className="w-3 h-3 inline mr-1" />- 1m 32s+ <div className="flex items-center pl-5 mt-0.5">+ <div className="text-xs text-neutral-400">+ <Clock className="w-3 h-3 inline mr-1" />+ 1m 32s+ </div></div></div></div>- </div>- {/* Event 2 */}- <div className="flex mb-2">- <div className="relative flex-shrink-0">- <div className="absolute top-7 left-3.5 w-[1px] bg-neutral-700 h-[calc(100%-16px)]" />- <div className="flex items-center justify-center w-7 h-7 rounded-full bg-amber-900/30 border border-amber-500/50">- <span className="text-xs font-medium">2</span>- </div>- </div>-- <div className="flex flex-col ml-2 flex-1">- <div className="flex items-center flex-1 py-0.5">- <MousePointerClick className="w-3.5 h-3.5 text-amber-400 mr-2" />- <div className="flex-1 min-w-0 mr-3">- <div className="text-sm truncate">button_click</div>+ {/* Event 2 */}+ <div className="flex mb-2">+ <div className="relative flex-shrink-0">+ <div className="absolute top-7 left-3.5 w-[1px] bg-neutral-700 h-[calc(100%-16px)]" />+ <div className="flex items-center justify-center w-7 h-7 rounded-full bg-amber-900/30 border border-amber-500/50">+ <span className="text-xs font-medium">2</span></div>- <div className="text-xs text-neutral-400">14:25:55</div></div>- <div className="flex items-center pl-5 mt-0.5">- <div className="flex flex-wrap gap-1.5">- <div className="px-1.5 py-0 h-5 text-xs bg-neutral-800 rounded border border-neutral-700">- <span className="text-neutral-400 font-light mr-1">button_id:</span>- <span>pricing</span>++ <div className="flex flex-col ml-2 flex-1">+ <div className="flex items-center flex-1 py-0.5">+ <MousePointerClick className="w-3.5 h-3.5 text-amber-400 mr-2" />+ <div className="flex-1 min-w-0 mr-3">+ <div className="text-sm truncate">button_click</div></div>- <div className="px-1.5 py-0 h-5 text-xs bg-neutral-800 rounded border border-neutral-700">- <span className="text-neutral-400 font-light mr-1">section:</span>- <span>features</span>+ <div className="text-xs text-neutral-400">14:25:55</div>+ </div>+ <div className="flex items-center pl-5 mt-0.5">+ <div className="flex flex-wrap gap-1.5">+ <div className="px-1.5 py-0 h-5 text-xs bg-neutral-800 rounded border border-neutral-700">+ <span className="text-neutral-400 font-light mr-1">button_id:</span>+ <span>pricing</span>+ </div>+ <div className="px-1.5 py-0 h-5 text-xs bg-neutral-800 rounded border border-neutral-700">+ <span className="text-neutral-400 font-light mr-1">section:</span>+ <span>features</span>+ </div></div></div></div></div>- </div>- {/* Event 3 */}- <div className="flex mb-2">- <div className="relative flex-shrink-0">- <div className="absolute top-7 left-3.5 w-[1px] bg-neutral-700 h-[calc(100%-16px)]" />- <div className="flex items-center justify-center w-7 h-7 rounded-full bg-blue-900/30 border border-blue-500/50">- <span className="text-xs font-medium">3</span>+ {/* Event 3 */}+ <div className="flex mb-2">+ <div className="relative flex-shrink-0">+ <div className="absolute top-7 left-3.5 w-[1px] bg-neutral-700 h-[calc(100%-16px)]" />+ <div className="flex items-center justify-center w-7 h-7 rounded-full bg-blue-900/30 border border-blue-500/50">+ <span className="text-xs font-medium">3</span>+ </div></div>- </div>- <div className="flex flex-col ml-2 flex-1">- <div className="flex items-center flex-1 py-0.5">- <Eye className="w-3.5 h-3.5 text-blue-400 mr-2" />- <div className="flex-1 min-w-0 mr-3">- <div className="text-sm truncate">/pricing</div>+ <div className="flex flex-col ml-2 flex-1">+ <div className="flex items-center flex-1 py-0.5">+ <Eye className="w-3.5 h-3.5 text-blue-400 mr-2" />+ <div className="flex-1 min-w-0 mr-3">+ <div className="text-sm truncate">/pricing</div>+ </div>+ <div className="text-xs text-neutral-400">14:25:58</div></div>- <div className="text-xs text-neutral-400">14:25:58</div>- </div>- <div className="flex items-center pl-5 mt-0.5">- <div className="text-xs text-neutral-400">- <Clock className="w-3 h-3 inline mr-1" />- 4m 42s+ <div className="flex items-center pl-5 mt-0.5">+ <div className="text-xs text-neutral-400">+ <Clock className="w-3 h-3 inline mr-1" />+ 4m 42s+ </div></div></div></div>- </div>-- {/* Event 4 */}- <div className="flex mb-2">- <div className="relative flex-shrink-0">- <div className="flex items-center justify-center w-7 h-7 rounded-full bg-amber-900/30 border border-amber-500/50">- <span className="text-xs font-medium">4</span>- </div>- </div>- <div className="flex flex-col ml-2 flex-1">- <div className="flex items-center flex-1 py-0.5">- <MousePointerClick className="w-3.5 h-3.5 text-amber-400 mr-2" />- <div className="flex-1 min-w-0 mr-3">- <div className="text-sm truncate">form_submit</div>+ {/* Event 4 */}+ <div className="flex mb-2">+ <div className="relative flex-shrink-0">+ <div className="flex items-center justify-center w-7 h-7 rounded-full bg-amber-900/30 border border-amber-500/50">+ <span className="text-xs font-medium">4</span></div>- <div className="text-xs text-neutral-400">14:30:40</div></div>- <div className="flex items-center pl-5 mt-0.5">- <div className="flex flex-wrap gap-1.5">- <div className="px-1.5 py-0 h-5 text-xs bg-neutral-800 rounded border border-neutral-700">- <span className="text-neutral-400 font-light mr-1">form_id:</span>- <span>contact-form</span>++ <div className="flex flex-col ml-2 flex-1">+ <div className="flex items-center flex-1 py-0.5">+ <MousePointerClick className="w-3.5 h-3.5 text-amber-400 mr-2" />+ <div className="flex-1 min-w-0 mr-3">+ <div className="text-sm truncate">form_submit</div></div>- <div className="px-1.5 py-0 h-5 text-xs bg-neutral-800 rounded border border-neutral-700">- <span className="text-neutral-400 font-light mr-1">success:</span>- <span>true</span>+ <div className="text-xs text-neutral-400">14:30:40</div>+ </div>+ <div className="flex items-center pl-5 mt-0.5">+ <div className="flex flex-wrap gap-1.5">+ <div className="px-1.5 py-0 h-5 text-xs bg-neutral-800 rounded border border-neutral-700">+ <span className="text-neutral-400 font-light mr-1">form_id:</span>+ <span>contact-form</span>+ </div>+ <div className="px-1.5 py-0 h-5 text-xs bg-neutral-800 rounded border border-neutral-700">+ <span className="text-neutral-400 font-light mr-1">success:</span>+ <span>true</span>+ </div></div></div></div>