fix(demo & streak): fix Neha demo account hang, enhance streak animation for light/dark modes and cries/celebration emojis
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
"use client"
|
||||
"use client"
|
||||
|
||||
import { ReactNode, useState, useEffect, useRef } from "react"
|
||||
import { BookOpen, LayoutDashboard, Settings, FileText, Activity, LineChart, Trophy, User, ChevronUp, Lock, ShieldAlert, Flame, Target, Gauge, Zap, Calendar, Clock, BrainCircuit, BarChart3, School, CheckSquare } from "lucide-react"
|
||||
@@ -358,9 +358,14 @@ export default function DashboardLayout({ children }: { children: ReactNode }) {
|
||||
<div className="flex items-center gap-4">
|
||||
{/* Streak count moved to top header */}
|
||||
{user && (
|
||||
<Link href="/dashboard/streaks" className="hover:opacity-85 transition-opacity">
|
||||
<button
|
||||
type="button"
|
||||
onClick={() => window.dispatchEvent(new CustomEvent("pragativeer-show-streak-animation"))}
|
||||
className="hover:opacity-85 transition-opacity cursor-pointer border-none bg-transparent p-0"
|
||||
title="View Streak Celebration"
|
||||
>
|
||||
<StreakCounter streak={user.streak_count} />
|
||||
</Link>
|
||||
</button>
|
||||
)}
|
||||
|
||||
{/* Demo Switcher — only visible when logged in as a known demo account */}
|
||||
@@ -381,7 +386,7 @@ export default function DashboardLayout({ children }: { children: ReactNode }) {
|
||||
<option value={DEMO_USERS.NEHA.id}>Neha Verma (AI Coach)</option>
|
||||
<option value={DEMO_USERS.AI_COACH.id}>Rahul (AI Coach)</option>
|
||||
<option value={DEMO_USERS.PRO.id}>Priya (Pro Plan)</option>
|
||||
{/* <option value={DEMO_USERS.FREE.id}>Amit (Free Plan)</option> */}
|
||||
<option value={DEMO_USERS.FREE.id}>Amit (Free Plan)</option>
|
||||
</select>
|
||||
</div>
|
||||
)}
|
||||
|
||||
Reference in New Issue
Block a user