Files
MattrixwvReactComponents/lib/component/loading/drop/Drop.tsx

50 lines
883 B
TypeScript

import type { LoadingPulseProps } from "$/types/LoadingTypes";
export default function Drop({
width,
height,
className,
animationDuration = 1.2,
stroke,
fill
}: LoadingPulseProps){
//https://github.com/n3r4zzurr0/svg-spinners/blob/main/svg-smil/pulse.svg
return (
<svg
width={width}
height={height}
viewBox="0 0 24 24"
xmlns="http://www.w3.org/2000/svg"
>
<circle
cx="12"
cy="12"
r="0"
className={className}
stroke={stroke}
fill={fill}
>
<animate
attributeName="r"
calcMode="spline"
dur={animationDuration}
values="0;11"
keySplines=".52,.6,.25,.99"
repeatCount="indefinite"
/>
<animate
attributeName="opacity"
calcMode="spline"
dur={animationDuration}
values="1;0"
keySplines=".52,.6,.25,.99"
repeatCount="indefinite"
/>
</circle>
</svg>
);
}