forked from coreui/coreui-react
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCWidgetIcon.stories.js
47 lines (42 loc) · 1.05 KB
/
CWidgetIcon.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
import React from 'react';
import CWidgetIcon from '../src/widgets/CWidgetIcon'
import CCard from '../src/card/CCard'
import CCardBody from '../src/card/CCardBody'
import CCol from '../src/grid/CCol'
import { boolean, number, text, select } from '@storybook/addon-knobs';
export default {
title: 'CWidgetIcon'
};
export const basic = () => {
const colorOptions = [
"",
"primary",
"secondary",
"success",
"warning",
"danger",
"info",
"light",
"dark",
]
const color = select('Color', colorOptions, 'info', 'Other')
const header = text('Header', 'Header text', 'Other')
const _text = text('Text', 'Text', 'Other')
const iconPadding = boolean('Icon padding', false, 'Other')
return <>
<CCol lg="6" md="8" xs="12">
<CCard>
<CCardBody>
<CWidgetIcon
color={color}
header={header}
text={_text}
iconPadding={iconPadding}
>
Icon
</CWidgetIcon>
</CCardBody>
</CCard>
</CCol>
</>
}