安装
用法
import { MorphingText } from "@/components/magicui/morphing-text";
<MorphingText texts={["Hello", "World"]} />
属性
属性 | 类型 | 默认值 | 描述 |
---|---|---|---|
texts | string[] | [] | 用于变形的文本数组 |
className | string? | "" | 容器的附加类 |
这个 MorphingText
组件可以在文本字符串数组之间动态过渡,从而创建平滑、引人入胜的视觉效果。
致谢
- 鸣谢 @luis-code