File tree Expand file tree Collapse file tree 2 files changed +13
-0
lines changed
stories-web/src/components Expand file tree Collapse file tree 2 files changed +13
-0
lines changed Original file line number Diff line number Diff line change 3535 margin-block-end : 0 ;
3636 }
3737
38+ ._trailing {
39+ margin-left : auto ;
40+ }
41+
3842 @include -state-style (map .get ($options , color ));
3943 @include -size-style (map .get ($options , size ));
4044
Original file line number Diff line number Diff line change @@ -8,13 +8,15 @@ export interface Props {
88 "informative" | "positive" | "negative" | "notice"
99 > ;
1010 size ?: Extract < Size , 's' | 'm' | 'l' > ;
11+ hasButton ?: boolean ;
1112}
1213
1314const Callout : FC < Props > = ( props : Props ) => {
1415 const wrapperClasses = [ 'in-callout' ]
1516 const {
1617 color = "informative" ,
1718 size = "m" ,
19+ hasButton = false ,
1820 children
1921 } = props
2022
@@ -27,6 +29,13 @@ const Callout: FC<Props> = (props: Props) => {
2729 < div className = "_body" >
2830 { children }
2931 </ div >
32+ { hasButton && (
33+ < div className = "_trailing" >
34+ < button className = "in-button -size-s -appearance-transparent" >
35+ < div className = "_body" > 閉じる</ div >
36+ </ button >
37+ </ div >
38+ ) }
3039 </ div >
3140 )
3241}
You can’t perform that action at this time.
0 commit comments