Illustration
Illustrations visually enhance content and concepts, creating engaging experiences.
#Purpose
Illustrations are valuable assets when used intentionally. They should be clear, relevant, and enhance the user's experience, not detract from it.
Illustrations can:
- Enhance Understanding: Clarify complex concepts, processes, or data.
- Create Emotional Connection: Evoke specific moods, feelings, or brand personality.
- Add Visual Interest: Break up text-heavy layouts and guide the user's eye.
- Provide Visual Cues: Direct attention, suggest actions, or enhance navigation.
#Examples
<Illustration src={IllustrationSuccess} alt="Accessibility illustration" />
#Sizes
Illustrations can be used in various sizes to fulfill different purposes:
- xSmall / Small(Icons/ pictorgrams): Used for visual cues, actions, or within text.
- Medium(Supporting): Reinforce content within sections, cards, or lists.
- Large (Hero/Header): Introduce sections, create a visual anchor, or stand alone.
<Illustration
src={IllustrationSuccess}
size={{ width: 32, height: 32 }}
alt="Illustration with custom size"
/>
<Illustration src={IllustrationSuccess} size="small" alt="Small size illustration" />
<Illustration src={IllustrationSuccess} size="medium" alt="Medium size illustration" />
<Illustration src={IllustrationSuccess} size="large" alt="Large size illustration" />
#Decorative
Decorative illustrations are purely aesthetic and do not convey essential information. They should be used sparingly to avoid clutter and maintain visual hierarchy.
<Illustration src={IllustrationSuccess} decorative />
#Properties
Property | Description | Defined | Value |
---|---|---|---|
srcRequired | string The illustration image source (base64, SVG, URL, or file path) | ||
sizeOptional | "large" | "medium" | "small" | object Controls the illustration size - defaults to medium | ||
altOptional | string Meaningful alt text that explains the illustration | ||
decorativeOptional | boolean If true, the illustration doesn’t need an alt text | ||
data-observe-keyOptional | string Unique string, used by external script e.g. for event tracking | ||
classNameOptional | string Custom className that's applied to the outermost element (only intended for special cases) | ||
styleOptional | object Style object to apply custom inline styles (only intended for special cases) | ||
tabIndexOptional | number Tab index of the outermost HTML element of the component | ||
onKeyDownOptional | function Callback for onKeyDown event | ||
onMouseDownOptional | function Callback for onMouseDown event | ||
onMouseEnterOptional | function Callback for onMouseEnter event | ||
onMouseLeaveOptional | function Callback for onMouseLeave event | ||
onFocusOptional | function Callback for onFocus event | ||
onBlurOptional | function Callback for onBlur event |
#Guidelines
#Best practices
#Do not use when
#Accessibility
Explore detailed guidelines for this component: Accessibility Specifications