()
| 2 | import { motion } from 'framer-motion' |
| 3 | |
| 4 | export default function RippleLoader() { |
| 5 | const rippleVariants = { |
| 6 | start: { |
| 7 | opacity: 1, |
| 8 | scale: 0, |
| 9 | }, |
| 10 | end: { |
| 11 | opacity: 0, |
| 12 | scale: 3, |
| 13 | }, |
| 14 | } |
| 15 | |
| 16 | const rippleTransition = { |
| 17 | duration: 2, |
| 18 | ease: 'easeInOut', |
| 19 | repeat: Infinity, |
| 20 | repeatDelay: 1, |
| 21 | } |
| 22 | |
| 23 | return ( |
| 24 | <div className="flex items-center justify-center"> |
| 25 | <div className="relative h-10 w-10"> |
| 26 | <motion.div |
| 27 | className="absolute h-full w-full rounded-full bg-red-500 opacity-0" |
| 28 | variants={rippleVariants} |
| 29 | initial="start" |
| 30 | animate="end" |
| 31 | transition={rippleTransition} |
| 32 | ></motion.div> |
| 33 | <motion.div |
| 34 | className="absolute h-full w-full rounded-full bg-red-500 opacity-0" |
| 35 | variants={rippleVariants} |
| 36 | initial="start" |
| 37 | animate="end" |
| 38 | transition={{ ...rippleTransition, delay: 0.5 }} |
| 39 | ></motion.div> |
| 40 | <motion.div |
| 41 | className="absolute h-full w-full rounded-full bg-red-500 opacity-0" |
| 42 | variants={rippleVariants} |
| 43 | initial="start" |
| 44 | animate="end" |
| 45 | transition={{ ...rippleTransition, delay: 1 }} |
| 46 | ></motion.div> |
| 47 | </div> |
| 48 | </div> |
| 49 | ) |
| 50 | } |
nothing calls this directly
no outgoing calls
no test coverage detected