Files
create-better-t-stack/apps/web/components/ShinyText/ShinyText.tsx
Aman Varshney c03c469838 fix errors
2025-02-15 13:17:27 +05:30

27 lines
423 B
TypeScript

interface ShinyTextProps {
text: string;
disabled?: boolean;
speed?: number;
className?: string;
}
const ShinyText = ({
text,
disabled = false,
speed = 5,
className = "",
}: ShinyTextProps) => {
const animationDuration = `${speed}s`;
return (
<div
className={`shiny-text ${disabled ? "disabled" : ""} ${className}`}
style={{ animationDuration }}
>
{text}
</div>
);
};
export default ShinyText;