1
- import React , { Component } from 'react' ;
1
+ import React , { Component } from 'react'
2
2
3
3
import {
4
4
Avatar ,
@@ -34,10 +34,12 @@ import {
34
34
BaseStyles ,
35
35
ThemeProvider ,
36
36
theme ,
37
- } from 'rimble-ui' ;
37
+ } from 'rimble-ui'
38
38
39
- import TestForm from './components/TestForm' ;
40
- import BaseLineGrid from './components/BaseLineGrid' ;
39
+ import { Eth , Btc } from '@rimble/icons'
40
+
41
+ import TestForm from './components/TestForm'
42
+ import BaseLineGrid from './components/BaseLineGrid'
41
43
42
44
const testTheme = {
43
45
...theme ,
@@ -53,16 +55,15 @@ const testTheme = {
53
55
danger : 'orangered' ,
54
56
info : 'blue' ,
55
57
} ,
56
- } ;
58
+ }
57
59
58
60
const selectOptions = [
59
61
{ value : '123' , label : 'One Two Three' } ,
60
62
{ value : 'abc' , label : 'A B C' } ,
61
- ] ;
63
+ ]
62
64
63
65
const testComponents = props => (
64
66
< React . Fragment >
65
-
66
67
< h1 > H1 - Quick zephyrs blow, vexing daft Jim.</ h1 >
67
68
< h2 > H1 - Quick zephyrs blow, vexing daft Jim.</ h2 >
68
69
< h3 > H1 - Quick zephyrs blow, vexing daft Jim.</ h3 >
@@ -77,55 +78,73 @@ const testComponents = props => (
77
78
< Heading as = { 'h5' } > H5 - Quick zephyrs blow, vexing daft Jim.</ Heading >
78
79
< Heading as = { 'h6' } > H6 - Quick zephyrs blow, vexing daft Jim.</ Heading >
79
80
80
- < Heading as = { 'h1' } fontSize = { 1 } > H1 - Quick zephyrs blow, vexing daft Jim.</ Heading >
81
- < Heading as = { 'h2' } fontSize = { 2 } > H2 - Quick zephyrs blow, vexing daft Jim.</ Heading >
82
- < Heading as = { 'h3' } fontSize = { 3 } > H3 - Quick zephyrs blow, vexing daft Jim.</ Heading >
83
- < Heading as = { 'h4' } fontSize = { 4 } > H4 - Quick zephyrs blow, vexing daft Jim.</ Heading >
84
- < Heading as = { 'h5' } fontSize = { 5 } > H5 - Quick zephyrs blow, vexing daft Jim.</ Heading >
85
- < Heading as = { 'h6' } fontSize = { 6 } > H6 - Quick zephyrs blow, vexing daft Jim.</ Heading >
81
+ < Heading as = { 'h1' } fontSize = { 1 } >
82
+ H1 - Quick zephyrs blow, vexing daft Jim.
83
+ </ Heading >
84
+ < Heading as = { 'h2' } fontSize = { 2 } >
85
+ H2 - Quick zephyrs blow, vexing daft Jim.
86
+ </ Heading >
87
+ < Heading as = { 'h3' } fontSize = { 3 } >
88
+ H3 - Quick zephyrs blow, vexing daft Jim.
89
+ </ Heading >
90
+ < Heading as = { 'h4' } fontSize = { 4 } >
91
+ H4 - Quick zephyrs blow, vexing daft Jim.
92
+ </ Heading >
93
+ < Heading as = { 'h5' } fontSize = { 5 } >
94
+ H5 - Quick zephyrs blow, vexing daft Jim.
95
+ </ Heading >
96
+ < Heading as = { 'h6' } fontSize = { 6 } >
97
+ H6 - Quick zephyrs blow, vexing daft Jim.
98
+ </ Heading >
86
99
87
100
< Heading fontSize = { 7 } > XL - Quick zephyrs blow, vexing daft Jim.</ Heading >
88
101
89
- < Heading as = { 'h1' } fontSize = { 6 } > H1 - Quick zephyrs blow, vexing daft Jim.</ Heading >
102
+ < Heading as = { 'h1' } fontSize = { 6 } >
103
+ H1 - Quick zephyrs blow, vexing daft Jim.
104
+ </ Heading >
90
105
91
- < Heading as = { 'h2' } fontSize = { 5 } > H2 - Quick zephyrs blow, vexing daft Jim.</ Heading >
106
+ < Heading as = { 'h2' } fontSize = { 5 } >
107
+ H2 - Quick zephyrs blow, vexing daft Jim.
108
+ </ Heading >
92
109
93
- < Heading as = { 'h3' } fontSize = { 4 } > H3 - Quick zephyrs blow, vexing daft Jim.</ Heading >
110
+ < Heading as = { 'h3' } fontSize = { 4 } >
111
+ H3 - Quick zephyrs blow, vexing daft Jim.
112
+ </ Heading >
94
113
95
- < Heading as = { 'h4' } fontSize = { 3 } > H4 - Quick zephyrs blow, vexing daft Jim.</ Heading >
114
+ < Heading as = { 'h4' } fontSize = { 3 } >
115
+ H4 - Quick zephyrs blow, vexing daft Jim.
116
+ </ Heading >
96
117
97
- < Heading as = { 'h5' } fontSize = { 2 } > H5 - Quick zephyrs blow, vexing daft Jim.</ Heading >
118
+ < Heading as = { 'h5' } fontSize = { 2 } >
119
+ H5 - Quick zephyrs blow, vexing daft Jim.
120
+ </ Heading >
98
121
99
- < Heading as = { 'h6' } fontSize = { 1 } > H6 - Quick zephyrs blow, vexing daft Jim.</ Heading >
122
+ < Heading as = { 'h6' } fontSize = { 1 } >
123
+ H6 - Quick zephyrs blow, vexing daft Jim.
124
+ </ Heading >
100
125
101
126
< Heading fontSize = { 0 } > SX - Quick zephyrs blow, vexing daft Jim.</ Heading >
102
127
103
128
< Text fontWeight = { 1 } >
104
- 1 / 300 —
105
- Lorem ipsum dolor sit amet, consectetur adipisicing elit. Soluta
129
+ 1 / 300 — Lorem ipsum dolor sit amet, consectetur adipisicing elit. Soluta
106
130
quibusdam, assumenda officiis.
107
131
</ Text >
108
132
< Text fontWeight = { 2 } >
109
- 2 / 400 —
110
- Lorem ipsum dolor sit amet, consectetur adipisicing elit. Soluta
133
+ 2 / 400 — Lorem ipsum dolor sit amet, consectetur adipisicing elit. Soluta
111
134
quibusdam, assumenda officiis.
112
135
</ Text >
113
136
< Text fontWeight = { 3 } >
114
- 3 / 600 —
115
- Lorem ipsum dolor sit amet, consectetur adipisicing elit. Soluta
137
+ 3 / 600 — Lorem ipsum dolor sit amet, consectetur adipisicing elit. Soluta
116
138
quibusdam, assumenda officiis.
117
139
</ Text >
118
140
< Text fontWeight = { 4 } >
119
- 4 / 700 —
120
- Lorem ipsum dolor sit amet, consectetur adipisicing elit. Soluta
141
+ 4 / 700 — Lorem ipsum dolor sit amet, consectetur adipisicing elit. Soluta
121
142
quibusdam, assumenda officiis.
122
143
</ Text >
123
144
124
145
< Button size = { 'medium' } > Click me!</ Button >
125
146
< Link > I'm a Link!</ Link >
126
- < EthAddress
127
- address = "0x99cb784f0429efd72wu39fn4256n8wud4e01c7d2"
128
- />
147
+ < EthAddress address = "0x99cb784f0429efd72wu39fn4256n8wud4e01c7d2" />
129
148
< EthAddress
130
149
textLabels
131
150
address = "0x99cb784f0429efd72wu39fn4256n8wud4e01c7d2"
@@ -134,8 +153,35 @@ const testComponents = props => (
134
153
< TestForm />
135
154
</ Card >
136
155
< Input placeholder = { 'placeholder' } />
137
- < Icon name = { 'Info' } />
138
- < Icon name = { 'Info' } color = "primary" />
156
+
157
+ < Box >
158
+ < Text > Icon component from rimble-ui</ Text >
159
+ < Icon name = { 'Info' } />
160
+ < Icon name = { 'Eth' } />
161
+ < Icon name = { 'Btc' } />
162
+ </ Box >
163
+
164
+ < Box >
165
+ < Text >
166
+ Icon component from rimble-ui using "primary" color from theme
167
+ </ Text >
168
+ < Icon name = { 'Info' } color = "primary" />
169
+ < Icon name = { 'Eth' } color = "primary" />
170
+ < Icon name = { 'Btc' } color = "primary" />
171
+ </ Box >
172
+ < Box >
173
+ < Text > Icon component from rimble-ui, color="green"</ Text >
174
+ < Icon name = { 'Info' } color = "green" />
175
+ < Icon name = { 'Eth' } color = "green" />
176
+ < Icon name = { 'Btc' } color = "green" />
177
+ </ Box >
178
+ < Box >
179
+ < Text > Icons imported as components from @rimble/icons</ Text >
180
+ < Eth color = "primary" />
181
+ < Btc color = "primary" />
182
+ < Eth color = "green" />
183
+ < Btc color = "green" />
184
+ </ Box >
139
185
< Tooltip message = "Your custom message" >
140
186
< span > hover me</ span >
141
187
</ Tooltip >
@@ -223,7 +269,7 @@ const testComponents = props => (
223
269
< Checkbox disabled label = "Checkbox disabled" readOnly />
224
270
< Checkbox disabled checked label = "Checkbox checked disabled" readOnly />
225
271
226
- < Box my = { 4 } opacity = { .6 } >
272
+ < Box my = { 4 } opacity = { 0 .6} >
227
273
< Flex >
228
274
< Box width = { 1 } height = { '4rem' } bg = { 'primary' } m = { 1 } />
229
275
< Box width = { 1 } height = { '4rem' } bg = { 'primary' } m = { 1 } />
@@ -269,9 +315,9 @@ const testComponents = props => (
269
315
< Heading mb = { 3 } > Heading</ Heading >
270
316
< Text mb = { 4 } >
271
317
Lorem ipsum dolor sit amet, consectetur adipisicing elit. Ullam autem
272
- ratione doloribus quidem neque provident eius error dignissimos
273
- delectus architecto nemo quos alias sunt voluptate impedit, facilis
274
- sequi tempore. Amet!
318
+ ratione doloribus quidem neque provident eius error dignissimos delectus
319
+ architecto nemo quos alias sunt voluptate impedit, facilis sequi
320
+ tempore. Amet!
275
321
</ Text >
276
322
< Flex >
277
323
< Button mr = { 3 } > Accept</ Button >
@@ -281,18 +327,10 @@ const testComponents = props => (
281
327
</ Card >
282
328
< Table />
283
329
< Image src = "https://source.unsplash.com/random/1280x720" />
284
- < MetaMaskButton >
285
- Connect with MetaMask
286
- </ MetaMaskButton >
287
- < MetaMaskButton . Outline >
288
- Connect with MetaMask
289
- </ MetaMaskButton . Outline >
290
- < UPortButton >
291
- Connect with uPort
292
- </ UPortButton >
293
- < UPortButton . Solid >
294
- Connect with uPort
295
- </ UPortButton . Solid >
330
+ < MetaMaskButton > Connect with MetaMask</ MetaMaskButton >
331
+ < MetaMaskButton . Outline > Connect with MetaMask</ MetaMaskButton . Outline >
332
+ < UPortButton > Connect with uPort</ UPortButton >
333
+ < UPortButton . Solid > Connect with uPort</ UPortButton . Solid >
296
334
< Loader />
297
335
< QR value = "test" />
298
336
< Modal />
@@ -322,26 +360,22 @@ const testComponents = props => (
322
360
I am a DANGER Flash with a < Flash . Link > Link</ Flash . Link >
323
361
</ Flash >
324
362
</ React . Fragment >
325
- ) ;
363
+ )
326
364
327
365
export default class App extends Component {
328
366
render ( ) {
329
367
return (
330
368
< Flex position = { 'relative' } >
331
369
< Box m = { 4 } >
332
- < BaseStyles >
333
- { testComponents ( ) }
334
- </ BaseStyles >
370
+ < BaseStyles > { testComponents ( ) } </ BaseStyles >
335
371
</ Box >
336
372
< Box m = { 4 } >
337
373
< ThemeProvider theme = { testTheme } >
338
- < BaseStyles >
339
- { testComponents ( ) }
340
- </ BaseStyles >
374
+ < BaseStyles > { testComponents ( ) } </ BaseStyles >
341
375
</ ThemeProvider >
342
376
</ Box >
343
377
< BaseLineGrid />
344
378
</ Flex >
345
- ) ;
379
+ )
346
380
}
347
381
}
0 commit comments