NameColorBadge
文档基于名称哈希生成稳定背景色的徽章组件,常用于组件卡片或标题标识
Component Demo
Basic usage and examples of the NameColorBadge component
基础用法
尺寸
稳定配色
相同名称生成相同颜色
动态名称
API Documentation
Complete API reference for the NameColorBadge component
Props
| 属性名 | 类型 | 默认值 | 描述 |
|---|---|---|---|
className | string | - | 自定义类名 |
name | string | - | 用于生成背景色的名称 |
size | 'lg' | 'md' | 'sm' | 'md' | 尺寸(sm / md / lg) |