-
Notifications
You must be signed in to change notification settings - Fork 827
Commit
* feat(illustration): add illustration component * feat(illustration): add empty state illustrations * feat(illustration): remove vector-effect property * feat(illustration): add addition svgs * feat(illustration): fix lint error * feat(illiustration): fix linter errors * feat(illiustration): fix vnu errors * feat(illustration): add classnames to svg elements * feat(illustration): edit svg attributes * feat(illustration): create docblocks * feat(illustration): add snapshots * feat(illustrations): update snapshots * feat(illustration): add call to action variants and improve docs * feat(illustrations): update snapshots * chore(illustration): remove ids chore(illustration): remove ids * chore(illustration): clean up svgs chore(illustration): update tests * chore(illustration): update snapshots * chore(illustration): use lorum ipsum * chore(illustration): update tests * chore(illustration): add tokens * fix(illustration): doc fixes and text longform fix(illustration): update tests
- Loading branch information
There are no files selected for viewing
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
// Copyright (c) 2015-present, salesforce.com, inc. All rights reserved | ||
// Licensed under BSD 3-Clause - see LICENSE.txt or git.io/sfdc-license | ||
|
||
/** | ||
* An illustration is a component that displays an stateful image and message. | ||
* Illustrations should be used within other components, such as cards, to express the state of the component (i.e. empty states). | ||
* They should be accompanied by text that also describes the state of the component. | ||
* | ||
* #### Accessibility | ||
* | ||
* Each SVG tag requires an `aria-hidden="true"` attribute | ||
* | ||
* @summary Illustrations are used to display illustration images. They should be used within other components, such as cards. | ||
* | ||
* @base | ||
* @name illustration | ||
* @selector .slds-illustration | ||
* @support dev-ready | ||
*/ |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
// Copyright (c) 2015-present, salesforce.com, inc. All rights reserved | ||
// Licensed under BSD 3-Clause - see LICENSE.txt or git.io/sfdc-license | ||
|
||
/** | ||
* | ||
* @summary Initiates an illustration component | ||
* | ||
* @name base | ||
* @selector .slds-illustration | ||
* @restrict div | ||
* @variant | ||
*/ | ||
.slds-illustration { | ||
|
||
text-align: center; | ||
|
||
/** | ||
* @summary Applies width and height values for small illustrations | ||
* @selector .slds-illustration_small | ||
* @restrict .slds-illustration | ||
* @modifier | ||
* @group width | ||
*/ | ||
&_small svg { | ||
width: 100%; | ||
max-width: 300px; | ||
max-height: 200px; | ||
margin-bottom: $spacing-medium; | ||
} | ||
|
||
/** | ||
* @summary Applies width and height values for large illustrations | ||
* @selector .slds-illustration_large | ||
* @restrict .slds-illustration | ||
* @modifier | ||
* @group width | ||
*/ | ||
&_large svg { | ||
width: 100%; | ||
max-width: 600px; | ||
max-height: 400px; | ||
margin-bottom: $spacing-medium; | ||
} | ||
|
||
.slds-illustration__stroke-primary { | ||
stroke: $illustration-color-primary; | ||
stop-color: $illustration-color-primary; | ||
} | ||
|
||
.slds-illustration__stroke-secondary { | ||
stroke: $illustration-color-secondary; | ||
stop-color: $illustration-color-secondary; | ||
} | ||
|
||
.slds-illustration__fill-primary { | ||
fill: $illustration-color-primary; | ||
} | ||
|
||
.slds-illustration__fill-secondary { | ||
fill: $illustration-color-secondary; | ||
} | ||
|
||
.slds-illustration__stop-color-primary { | ||
stop-color: $illustration-color-primary; | ||
} | ||
|
||
.slds-illustration__stop-color-secondary { | ||
stop-color: $illustration-color-secondary; | ||
} | ||
} |