You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: packages/documentation-site/patternfly-docs/content/design-guidelines/components/avatar/avatar.md
+31-13Lines changed: 31 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -3,30 +3,48 @@ id: Avatar
3
3
section: components
4
4
---
5
5
6
+
import '../components.css';
7
+
8
+
## Elements
9
+
10
+
<divclass="ws-docs-content-img">
11
+

12
+
</div>
13
+
1.**Image/graphic:** Visual representation of the user. If there is no custom image for a user, the default graphic will be shown.
14
+
1.**Border (optional):** Outline, to improve the visual prominence of an avatar in a UI element.
15
+
6
16
## Usage
7
17
8
-
There are four size variations available to use for different scenarios. The typical usage for an avatar is to represent the current user in the masthead. However, based on your product's use cases and needs, there is room for customization.
18
+
An avatar is typically used to represent the current user in the masthead. However, based on your product's use cases and needs, there is room for customization, as outlined in the following [avatar variations](#variations) section.
19
+
20
+
## Variations
21
+
22
+
There are 4 size variations available to use for different scenarios:
23
+
24
+
1. Small (sm), 24px
9
25
26
+
- Default size.
27
+
- Used in accordions, data lists, and tables:
10
28
11
-
### Small (24 px)
12
-
This size variation should be used in components such as accordions, data lists, tables, etc.
29
+
<imgsrc="./img/small-avatar-data list & accordion.png"alt="Image displaying small avatar usage in data list and accordion"width="802"/>
13
30
14
-
<imgsrc="./img/small-avatar-data list & accordion.png"alt="Image displaying small avatar usage in data list and accordion"width="802"/>
31
+
- Also used in the masthead component:
15
32
16
-
### Medium (36 px)
17
-
This size variation is the default avatar size and should be used in the masthead component.
33
+
<imgsrc="./img/medium-avatar-masthead.png"alt="Image displaying medium avatar usage in masthead"width="1024"/>
18
34
19
-
<imgsrc="./img/medium-avatar-masthead.png"alt="Image displaying medium avatar usage in masthead"width="1024"/>
35
+
1. Medium (md), 36px
20
36
21
-
### Large (72 px)
22
-
This size variation should be used in components such as cards.
37
+
1. Large (lg), 72px
38
+
39
+
- Used in cards.
23
40
24
-
<imgsrc="./img/large-avatar-card.png"alt="Image displaying large avatar usage in card"width="353"/>
41
+
<imgsrc="./img/large-avatar-card.png"alt="Image displaying large avatar usage in card"width="353"/>
25
42
26
-
### Extra Large (128 px)
27
-
This size variation should be used in components such as profile displays.
43
+
1. Extra large (xl), 128px
44
+
45
+
- Used in profile displays.
28
46
29
-
<imgsrc="./img/extra-large-avatar-profile display.png"alt="Image displaying extra large avatar usage in profile display"width="1024"/>
47
+
<imgsrc="./img/extra-large-avatar-profile display.png"alt="Image displaying extra large avatar usage in profile display"width="1024"/>
30
48
31
49
## Accessibility
32
50
For information regarding accessibility, visit the [avatar accessibility](/components/avatar/accessibility) tab.
0 commit comments