import { motion } from 'motion/react' import React from 'react' interface DotGridProps { rows: number columns: number count: number } const DotGrid: React.FC = ({ rows, columns, count }) => { const container = { hidden: { opacity: 1 }, visible: { opacity: 1, transition: { staggerChildren: 0.01, delayChildren: 0.01, }, }, } const item = { hidden: { opacity: 0 }, visible: { opacity: 0.3 }, } const highlightedVariants = { visible: { opacity: [1, 0.5, 1], transition: { repeat: Infinity, duration: 0.5, repeatDelay: 1.5, ease: 'easeInOut', }, }, } return (
{Array.from({ length: rows * columns }).map((_, index) => { const isHighlighted = index < count return ( ) })}
) } export default DotGrid