Files
ort/docs/components/FooterEmoji.tsx
2026-01-06 22:23:32 -06:00

16 lines
506 B
TypeScript

'use client';
import { usePathname } from 'next/navigation';
import { useEffect, useState } from 'react';
const FOOTER_EMOJIS = [ '💜', '🩷', '💜', '🩷', '💜', '🩷', '💜', '🩷', '☕', '👽', '🦀', '🌈', '🏳️‍⚧️' ];
export default function FooterEmoji() {
const route = usePathname();
const [ emoji, setEmoji ] = useState(FOOTER_EMOJIS[0]);
useEffect(() => {
setEmoji(FOOTER_EMOJIS[Math.floor(Math.random() * FOOTER_EMOJIS.length)]);
}, [ route ]);
return emoji;
}