text-blink
loading-ui/text-blinkFreeComponent
@loading-ui publishes no description for this item.
Live preview
live · rendered by the registry
Rendered by @loading-ui on their own page — this is the component running, not a screenshot of it.Install it
npx shadcn@latest add https://loading-ui.com/r/text-blink.jsonSource
1import { cn } from "@/lib/utils";23type TextBlinkProps = Omit<React.ComponentProps<"span">, "children"> & {4 children: React.ReactNode;5 as?: React.ElementType;6 minOpacity?: number;7};89function TextBlink({10 children,11 as: Component = "p",12 className,13 minOpacity = 0.45,14 style,15 ...props16}: TextBlinkProps) {17 return (18 <>19 <style>{`20 @keyframes loading-ui-text-blink {21 0%,22 100% {23 opacity: 1;24 }2526 50% {27 opacity: var(--loading-ui-text-blink-opacity);28 }29 }30 `}</style>31 <Component32 className={cn("inline-block font-medium", className)}33 style={34 {35 ...style,36 "--loading-ui-text-blink-opacity": minOpacity,37 animation:38 "loading-ui-text-blink var(--duration, 2s) ease-in-out infinite",39 } as React.CSSProperties40 }41 {...props}42 >43 {children}44 </Component>45 </>46 );47}4849export { TextBlink };
Files it writes
More from @loading-ui
All 50 items| Component | Registry | Kind | Access | Installs | Command |
|---|---|---|---|---|---|
| accordion-loaderaccordion-loader | @loading-ui | Components | Free | no deps | |
| analyzing-imageanalyzing-image | @loading-ui | Components | Free | 1 dep | |
| arcarc | @loading-ui | Components | Free | no deps | |
| barsbars | @loading-ui | Components | Free | no deps | |
| bobbing-dotsbobbing-dots | @loading-ui | Components | Free | 1 dep | |
| bouncing-dotsbouncing-dots | @loading-ui | Components | Free | no deps | |
| classicclassic | @loading-ui | Components | Free | no deps | |
| clock-ringclock-ring | @loading-ui | Components | Free | no deps |
