"use client"; import { ArrowRightIcon } from "@radix-ui/react-icons"; import { useInView } from "framer-motion"; import { useRef } from "react"; import { Button } from "./ui/button"; import { AppWindow, AppWindowIcon, AppWindowMac, ChevronDown } from "lucide-react"; import CoolHeaderText from "./cool-header-text"; import Particles from "./ui/particles"; import confetti from "canvas-confetti"; const download = () => { throwConfetti() window.location.replace(`https://realm.abunchofknowitalls.com/Realm.exe`) } const throwConfetti = () => { const end = Date.now() + 3 * 1000; // 3 seconds const colors = ["#a786ff", "#fd8bbc", "#eca184", "#f8deb1"]; const frame = () => { if (Date.now() > end) return; confetti({ particleCount: 2, angle: 60, spread: 55, startVelocity: 60, origin: { x: 0, y: 0.5 }, colors, }); confetti({ particleCount: 2, angle: 120, spread: 55, startVelocity: 60, origin: { x: 1, y: 0.5 }, colors, }); requestAnimationFrame(frame); }; frame(); }; export default function Header() { const ref = useRef(null); const inView = useInView(ref, { once: true, margin: "-100px" }); return ( <> Collaborate, Communicate, Connect Because that's what you wanted and you deserve to own your content. Download Realm for > ); }
Collaborate, Communicate, Connect Because that's what you wanted and you deserve to own your content.