forked from coreui/coreui-react
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCAlert.stories.js
52 lines (46 loc) · 1.3 KB
/
CAlert.stories.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
import React from 'react';
import CAlert from '../src/alert/CAlert'
import CCard from '../src/card/CCard'
import CCardBody from '../src/card/CCardBody'
import CCol from '../src/grid/CCol'
import { select } from '@storybook/addon-knobs';
export default {
title: 'CAlert'
};
export const single = () => {
const colorOptions = [
"primary",
"secondary",
"success",
"warning",
"danger",
"info",
"light",
"dark",
]
const color = select('Color', colorOptions, 'primary', 'Other')
return <>
<CCol lg="12" xs="12">
<CCard>
<CCardBody>
<CAlert color={color}>Lorem ipsum dolor cet emit. Emit cet dolor ipsum lorem.</CAlert>
</CCardBody>
</CCard>
</CCol>
</>
}
export const all = () =>
<CCol lg="12" xs="12">
<CCard>
<CCardBody>
<CAlert color="primary">CAlert primary</CAlert>
<CAlert color="secondary">CAlert secondary</CAlert>
<CAlert color="success">CAlert success</CAlert>
<CAlert color="danger">CAlert danger</CAlert>
<CAlert color="warning">CAlert warning</CAlert>
<CAlert color="info">CAlert info</CAlert>
<CAlert color="light">CAlert light</CAlert>
<CAlert color="dark">CAlert dark</CAlert>
</CCardBody>
</CCard>
</CCol>