From 9c75a341b997d98fa6b87f6d0b5e09f4e5abc608 Mon Sep 17 00:00:00 2001 From: kudindmitriy Date: Mon, 20 Apr 2026 23:33:17 +0300 Subject: [PATCH] Bob AI: add a glassmorphic badge with a random funny fact about the --- src/components/sections/hero/HeroBrand.tsx | 11 +++++++- src/components/ui/GlassmorphicBadge.tsx | 31 ++++++++++++++++++++++ 2 files changed, 41 insertions(+), 1 deletion(-) create mode 100644 src/components/ui/GlassmorphicBadge.tsx diff --git a/src/components/sections/hero/HeroBrand.tsx b/src/components/sections/hero/HeroBrand.tsx index 2239e0f..a3739f5 100644 --- a/src/components/sections/hero/HeroBrand.tsx +++ b/src/components/sections/hero/HeroBrand.tsx @@ -2,6 +2,8 @@ import Button from "@/components/ui/Button"; import TextAnimation from "@/components/ui/TextAnimation"; import ImageOrVideo from "@/components/ui/ImageOrVideo"; import AutoFillText from "@/components/ui/AutoFillText"; +import GlassmorphicBadge from "@/components/ui/GlassmorphicBadge"; +import { motion } from "motion/react"; type HeroBrandProps = { brand: string; @@ -35,7 +37,14 @@ const HeroBrand = ({ />
-
+
+ + +
{ + const [fact, setFact] = useState(""); + + useEffect(() => { + setFact(funnyFacts[Math.floor(Math.random() * funnyFacts.length)]); + }, []); + + if (!fact) { + return null; + } + + return ( +
+ Fun Fact: {fact} +
+ ); +}; + +export default GlassmorphicBadge; \ No newline at end of file