@@ -4,7 +4,40 @@ import {COMMON, get, SystemCommonProps} from './constants'
44import sx , { SxProp } from './sx'
55
66const variants = variant ( {
7- scale : 'flash'
7+ variants : {
8+ default : {
9+ color : 'alert.info.text' ,
10+ backgroundColor : 'alert.info.bg' ,
11+ borderColor : 'alert.info.border' ,
12+ svg : {
13+ color : 'alert.info.icon'
14+ }
15+ } ,
16+ success : {
17+ color : 'alert.success.text' ,
18+ backgroundColor : 'alert.success.bg' ,
19+ borderColor : 'alert.success.border' ,
20+ svg : {
21+ color : 'alert.success.icon'
22+ }
23+ } ,
24+ danger : {
25+ color : 'alert.error.text' ,
26+ backgroundColor : 'alert.error.bg' ,
27+ borderColor : 'alert.error.border' ,
28+ svg : {
29+ color : 'alert.error.icon'
30+ }
31+ } ,
32+ warning : {
33+ color : 'alert.warn.text' ,
34+ backgroundColor : 'alert.warn.bg' ,
35+ borderColor : 'alert.warn.border' ,
36+ svg : {
37+ color : 'alert.warn.icon'
38+ }
39+ }
40+ }
841} )
942
1043const Flash = styled . div <
@@ -15,7 +48,7 @@ const Flash = styled.div<
1548 SxProp
1649> `
1750 position: relative;
18- color: ${ get ( 'colors.text.grayDark ' ) } ;
51+ color: ${ get ( 'colors.text.primary ' ) } ;
1952 padding: ${ get ( 'space.3' ) } ;
2053 border-style: solid;
2154 border-width: ${ props => ( props . full ? '1px 0px' : '1px' ) } ;
@@ -27,7 +60,6 @@ const Flash = styled.div<
2760 }
2861
2962 svg {
30- color: ${ props => get ( `flashIcon.${ props . variant } ` ) ( props . theme ) } ;
3163 margin-right: ${ get ( 'space.2' ) } ;
3264 }
3365
0 commit comments