mirror of
https://gitee.com/ant-design/ant-design.git
synced 2024-12-12 11:55:23 +08:00
882cec62d6
* docs: Add components overview page * fix detail * remove ContributorsList form overview page * fix components url * improve code style * remove extra file * fix detail * fix lint * fix lint * docs: Finish components overview page * fix lint * docs: Update cover * fix lint * update cover * update menu * improve overview page * refactor code * fix order * update title * add components count * fix overview page ssr bug * move less file * update title margin Co-authored-by: arvinxx <arvinx@foxmail.com>
1002 B
1002 B
category | type | title | cover |
---|---|---|---|
Components | Data Display | Avatar | https://gw.alipayobjects.com/zos/antfincdn/aBcnbw68hP/Avatar.svg |
Avatars can be used to represent people or objects. It supports images, Icon
s, or letters.
API
Property | Description | Type | Default | Version |
---|---|---|---|---|
icon | custom icon type for an icon avatar | ReactNode | - | |
shape | the shape of avatar | circle | square |
circle |
|
size | the size of the avatar | number | large | small | default |
default |
|
src | the address of the image for an image avatar | string | - | |
srcSet | a list of sources to use for different screen resolutions | string | - | |
alt | This attribute defines the alternative text describing the image | string | - | |
onError | handler when img load error, return false to prevent default fallback behavior | () => boolean | - | |
gap | Letter type unit distance between left and right sides | number | 4 | 4.3.0 |