forked from reactstrap/reactstrap
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCardPage.js
More file actions
239 lines (224 loc) · 7.92 KB
/
Copy pathCardPage.js
File metadata and controls
239 lines (224 loc) · 7.92 KB
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
/* eslint react/no-multi-comp: 0, react/prop-types: 0 */
import React from 'react';
import { PrismCode } from 'react-prism';
import PageTitle from '../UI/PageTitle';
import SectionTitle from '../UI/SectionTitle';
import CardExample from '../examples/Card';
import CardContentExample from '../examples/CardContentTypes';
import CardSizingExample from '../examples/CardSizing';
import CardAlignmentExample from '../examples/CardAlignment';
import CardHeaderFooterExample from '../examples/CardHeaderFooter';
import CardImageCapsExample from '../examples/CardImageCaps';
import CardImageOverlayExample from '../examples/CardImageOverlay';
import CardBackgroundsExample from '../examples/CardBackgrounds';
import CardOutlineExample from '../examples/CardOutline';
import CardGroupsExample from '../examples/CardGroups';
import CardDecksExample from '../examples/CardDecks';
import CardColumnsExample from '../examples/CardColumns';
const CardExampleSource = require('!!raw!../examples/Card');
const CardContentExampleSource = require('!!raw!../examples/CardContentTypes');
const CardSizingExampleSource = require('!!raw!../examples/CardSizing');
const CardAlignmentExampleSource = require('!!raw!../examples/CardAlignment');
const CardHeaderFooterExampleSource = require('!!raw!../examples/CardHeaderFooter');
const CardImageCapsExampleSource = require('!!raw!../examples/CardImageCaps');
const CardImageOverlayExampleSource = require('!!raw!../examples/CardImageOverlay');
const CardBackgroundsExampleSource = require('!!raw!../examples/CardBackgrounds');
const CardOutlineExampleSource = require('!!raw!../examples/CardOutline');
const CardGroupsExampleSource = require('!!raw!../examples/CardGroups');
const CardDecksExampleSource = require('!!raw!../examples/CardDecks');
const CardColumnsExampleSource = require('!!raw!../examples/CardColumns');
export default class CardPage extends React.Component {
render() {
return (
<div>
<PageTitle title="Card" />
<hr />
<div className="docs-example">
<CardExample />
</div>
<pre>
<PrismCode className="language-jsx">
{CardExampleSource}
</PrismCode>
</pre>
<h4>Properties</h4>
<pre>
<PrismCode className="language-jsx">
{`Card.propTypes = {
// Pass in a Component to override default element
tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
inverse: PropTypes.bool,
color: PropTypes.string,
body: PropTypes.bool,
className: PropTypes.string
};
CardBody.propTypes = {
// Pass in a Component to override default element
tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
className: PropTypes.string
};
CardColumns.propTypes = {
// Pass in a Component to override default element
tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
className: PropTypes.string
};
CardDeck.propTypes = {
// Pass in a Component to override default element
tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
className: PropTypes.string
};
CardFooter.propTypes = {
// Pass in a Component to override default element
tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
className: PropTypes.string
};
CardGroup.propTypes = {
// Pass in a Component to override default element
tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
className: PropTypes.string
};
CardHeader.propTypes = {
// Pass in a Component to override default element
tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
className: PropTypes.string
};
CardImg.propTypes = {
// Pass in a Component to override default element
tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
className: PropTypes.string,
// Use top or bottom to position image via "card-img-top" or "card-img-bottom"
top: PropTypes.bool,
bottom: PropTypes.bool
};
CardImgOverlay.propTypes = {
// Pass in a Component to override default element
tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
className: PropTypes.string
};
CardLink.propTypes = {
// Pass in a Component to override default element
tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
className: PropTypes.string,
// ref will only get you a reference to the CardLink component, use innerRef to get a reference to the DOM element (for things like focus management).
innerRef: PropTypes.oneOfType([PropTypes.func, PropTypes.string])
};
CardSubtitle.propTypes = {
// Pass in a Component to override default element
tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
className: PropTypes.string
};
CardText.propTypes = {
// Pass in a Component to override default element
tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
className: PropTypes.string
};
CardTitle.propTypes = {
// Pass in a Component to override default element
tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
className: PropTypes.string
};`}
</PrismCode>
</pre>
<SectionTitle>Content Types</SectionTitle>
<div className="docs-example">
<CardContentExample />
</div>
<pre>
<PrismCode className="language-jsx">
{CardContentExampleSource}
</PrismCode>
</pre>
<SectionTitle>Sizing</SectionTitle>
<div className="docs-example">
<CardSizingExample />
</div>
<pre>
<PrismCode className="language-jsx">
{CardSizingExampleSource}
</PrismCode>
</pre>
<SectionTitle>Text alignment</SectionTitle>
<div className="docs-example">
<CardAlignmentExample />
</div>
<pre>
<PrismCode className="language-jsx">
{CardAlignmentExampleSource}
</PrismCode>
</pre>
<SectionTitle>Header and Footer</SectionTitle>
<div className="docs-example">
<CardHeaderFooterExample />
</div>
<pre>
<PrismCode className="language-jsx">
{CardHeaderFooterExampleSource}
</PrismCode>
</pre>
<SectionTitle>Image caps</SectionTitle>
<div className="docs-example">
<CardImageCapsExample />
</div>
<pre>
<PrismCode className="language-jsx">
{CardImageCapsExampleSource}
</PrismCode>
</pre>
<SectionTitle>Image overlays</SectionTitle>
<div className="docs-example">
<CardImageOverlayExample />
</div>
<pre>
<PrismCode className="language-jsx">
{CardImageOverlayExampleSource}
</PrismCode>
</pre>
<SectionTitle>Background variants</SectionTitle>
<div className="docs-example">
<CardBackgroundsExample />
</div>
<pre>
<PrismCode className="language-jsx">
{CardBackgroundsExampleSource}
</PrismCode>
</pre>
<SectionTitle>Outline variants</SectionTitle>
<div className="docs-example">
<CardOutlineExample />
</div>
<pre>
<PrismCode className="language-jsx">
{CardOutlineExampleSource}
</PrismCode>
</pre>
<SectionTitle>Groups</SectionTitle>
<div className="docs-example">
<CardGroupsExample />
</div>
<pre>
<PrismCode className="language-jsx">
{CardGroupsExampleSource}
</PrismCode>
</pre>
<SectionTitle>Decks</SectionTitle>
<div className="docs-example">
<CardDecksExample />
</div>
<pre>
<PrismCode className="language-jsx">
{CardDecksExampleSource}
</PrismCode>
</pre>
<SectionTitle>Columns</SectionTitle>
<div className="docs-example">
<CardColumnsExample />
</div>
<pre>
<PrismCode className="language-jsx">
{CardColumnsExampleSource}
</PrismCode>
</pre>
</div>
);
}
}