Seed demo data globally via Layout and Admin
cgen-3b21c0fa437a4a7793174c129695f249
This commit is contained in:
parent
e12a453f61
commit
7c94e84f13
1 changed files with 4 additions and 0 deletions
|
|
@ -12,6 +12,8 @@ import {
|
||||||
} from "@/components/ui/dropdown-menu";
|
} from "@/components/ui/dropdown-menu";
|
||||||
import { Avatar, AvatarFallback, AvatarImage } from "@/components/ui/avatar";
|
import { Avatar, AvatarFallback, AvatarImage } from "@/components/ui/avatar";
|
||||||
import { User, Settings, LogOut, Bell } from "lucide-react";
|
import { User, Settings, LogOut, Bell } from "lucide-react";
|
||||||
|
import { useEffect } from "react";
|
||||||
|
import { ensureDemoSeed } from "@/lib/demo-feed";
|
||||||
|
|
||||||
interface LayoutProps {
|
interface LayoutProps {
|
||||||
children: React.ReactNode;
|
children: React.ReactNode;
|
||||||
|
|
@ -41,6 +43,8 @@ export default function Layout({ children }: LayoutProps) {
|
||||||
window.scrollTo({ top: 0, behavior: "smooth" });
|
window.scrollTo({ top: 0, behavior: "smooth" });
|
||||||
};
|
};
|
||||||
|
|
||||||
|
useEffect(() => { try { ensureDemoSeed(); } catch {} }, []);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="min-h-screen bg-aethex-gradient">
|
<div className="min-h-screen bg-aethex-gradient">
|
||||||
<header className="sticky top-0 z-50 border-b border-border/40 bg-background/95 backdrop-blur supports-[backdrop-filter]:bg-background/60 animate-slide-down">
|
<header className="sticky top-0 z-50 border-b border-border/40 bg-background/95 backdrop-blur supports-[backdrop-filter]:bg-background/60 animate-slide-down">
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue