-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
408 lines (348 loc) · 12.4 KB
/
index.html
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
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Truchastic UI</title>
<meta name="description" content="CSS Framework based on with WebComponents and inspired on Elastic UI ">
<link rel="stylesheet" href="style.css">
</head>
<body>
<div style="
background: rgb(255, 255, 255);
box-shadow: rgb(0 0 0 / 8%) 0px 0.9px 4px, rgb(0 0 0 / 6%) 0px 2.6px 8px, rgb(0 0 0 / 5%) 0px 5.7px 12px, rgb(0 0 0 / 4%) 0px 15px 15px;
border-inline-start: 1px solid rgba(211, 218, 230, 0.7);
margin: 10px;
padding: 10px;
">
<iframe style="position: absolute; right: 0px; "
src="https://ghbtns.com/github-btn.html?user=alepiumetti&repo=truchastic-ui&type=star&count=true" frameborder="0"
scrolling="0" width="150" height="20" title="GitHub"></iframe>
<header>
<tui-container w="100%" textAlign="center">
<h1>Truchastic UI</h1>
</tui-container>
<tui-container w="100%" textAlign="center">
<h3>CSS Library based on WebComponents | Inspired on Elastic UI and Chakra UI</h3>
</tui-container>
</header>
<hr />
<h2> Components </h2>
<hr />
<tui-container padding=10>
<h3>Buttons</h3>
<tui-container>
<tui-code-line>
<tui-button>btn</tui-button>
</tui-code-line>
</tui-container>
<br />
<tui-container w="100%">
<table>
<tr>
<th>
Attribute
</th>
<th>
Type
</th>
<th>
Values
</th>
</tr>
<tr>
<td>variant</td>
<td>string</td>
<td>
<tui-code-line>primary</tui-code-line>
<tui-code-line>danger</tui-code-line>
<tui-code-line>success</tui-code-line>
<tui-code-line>warning</tui-code-line>
</td>
</tr>
</table>
</tui-container>
<br />
<tui-hstack justifyContent="space-around" w="50%">
<tui-button variant="primary">Primary</tui-button>
<tui-button variant="primary" filled=true>Filled</tui-button>
<tui-button variant="primary" empty=true>Empty</tui-button>
</tui-hstack>
<br />
<tui-hstack justifyContent="space-around" w="50%">
<tui-button variant="danger">Danger</tui-button>
<tui-button variant="danger" filled=true>Filled</tui-button>
<tui-button variant="danger" empty=true>Empty</tui-button>
</tui-hstack>
<br />
<tui-hstack justifyContent="space-around" w="50%">
<tui-button variant="success">Success</tui-button>
<tui-button variant="success" filled=true>Filled</tui-button>
<tui-button variant="success" empty=true>Empty</tui-button>
</tui-hstack>
<br />
<tui-hstack justifyContent="space-around" w="50%">
<tui-button variant="warning">Warning</tui-button>
<tui-button variant="warning" filled=true>Filled</tui-button>
<tui-button variant="warning" empty=true>Empty</tui-button>
</tui-hstack>
</tui-container>
<br />
<hr />
<br />
<tui-container padding="10">
<h3>Modal</h3>
<br />
<tui-container w="100%">
<table>
<tr>
<th>
Attribute
</th>
<th>
Type
</th>
<th>
Values
</th>
</tr>
<tr>
<td>size</td>
<td>string</td>
<td>
<tui-code-line>default: md</tui-code-line>
<tui-code-line>sm</tui-code-line>
<tui-code-line>md</tui-code-line>
<tui-code-line>xl</tui-code-line>
</td>
</tr>
</table>
</tui-container>
<br />
<tui-container>
<tui-code>
<tui-button variant="primary" onclick="togglemodal('open')"> Open </tui-button>
<br />
<br />
<tui-modal id="modal" >
<blockquote>
<tui-modal-header>
<blockquote>
<tui-modal-title>
Modal Title
</tui-modal-title> <br />
<span style="cursor:pointer" onclick="togglemodal('close')" >
x
</span>
</blockquote>
</tui-modal-header> <br />
<tui-modal-body>
<blockquote>
Body
</blockquote>
</tui-modal-body> <br />
<tui-modal-footer>
<blockquote>
<tui-hstack justifyContent="flex-end" >
<blockquote>
<tui-button variant="danger" onclick="togglemodal('close')">
<blockquote>
Cancel
</blockquote>
</tui-button> <br />
<tui-button variant="primary" onclick="togglemodal('close')" >
<blockquote>
Ok
</blockquote>
</tui-button> <br />
</blockquote>
</tui-hstack>
</blockquote>
</tui-modal-footer> <br />
</blockquote>
</tui-modal>
<br />
<br />
<script>
<blockquote>
function togglemodal(action) {
<blockquote>
if (action === 'open') {
<blockquote>
let modal = document.getElementById('modal');
modal.setAttribute('show', 'true');
</blockquote>
} else if (action === 'close') {
<blockquote>
let modal = document.getElementById('modal');
modal.removeAttribute('show', 'false');
</blockquote>
}
</blockquote>
</blockquote>
</script>
</tui-code>
</tui-container>
<br />
<br />
<!-- Normal Modal -->
<tui-button variant="primary" onclick="togglemodal('modal-normal','open')">Open Modal xl</tui-button>
<tui-modal id="modal-normal" size="xl">
<tui-modal-header>
<tui-modal-title>
Modal Title
</tui-modal-title>
<div class="modal-close">
<!-- Tiene estilo en linea porque no estaba tomando el estilo de CSS -->
<span id="close-modal" style="cursor:pointer" onclick="togglemodal('modal-normal','close')">
x
</span>
</div>
</tui-modal-header>
<tui-modal-body>
Body
</tui-modal-body>
<tui-modal-footer>
<tui-hstack justifyContent="flex-end">
<tui-button variant="danger" filled="true" onclick="togglemodal('modal-normal','close')">Cancel</tui-button>
<div style="width: 15px;"></div> <!-- Spacer -->
<tui-button variant="primary" onclick="togglemodal('modal-normal','close')">Ok</tui-button>
</tui-hstack>
</tui-modal-footer>
</tui-modal>
<!-- Size Medium -->
<tui-button variant="primary" onclick="togglemodal('modal-medium','open')">Open Modal md</tui-button>
<tui-modal id="modal-medium" size="md">
<tui-modal-header>
<tui-modal-title>
Medium Modal Title
</tui-modal-title>
<div class="modal-close">
<!-- Tiene estilo en linea porque no estaba tomando el estilo de CSS -->
<span id="close-modal" style="cursor:pointer" onclick="togglemodal('modal-medium','close')">
x
</span>
</div>
</tui-modal-header>
<tui-modal-body>
Body
</tui-modal-body>
<tui-modal-footer>
<tui-hstack justifyContent="flex-end">
<tui-button variant="danger" filled="true" onclick="togglemodal('modal-medium','close')">Cancel</tui-button>
<div style="width: 15px;"></div> <!-- Spacer -->
<tui-button variant="primary" onclick="togglemodal('modal-medium','close')">Ok</tui-button>
</tui-hstack>
</tui-modal-footer>
</tui-modal>
<!-- Size Small -->
<tui-button variant="primary" onclick="togglemodal('modal-small','open')">Open Modal sm</tui-button>
<tui-modal id="modal-small" size="sm">
<tui-modal-header>
<tui-modal-title>
Small Modal Title
</tui-modal-title>
<div class="modal-close">
<!-- Tiene estilo en linea porque no estaba tomando el estilo de CSS -->
<span id="close-modal" style="cursor:pointer" onclick="togglemodal('modal-small','close')">
x
</span>
</div>
</tui-modal-header>
<tui-modal-body>
Body
</tui-modal-body>
<tui-modal-footer>
<tui-hstack justifyContent="flex-end">
<tui-button variant="danger" filled="true" onclick="togglemodal('modal-small','close')">Cancel</tui-button>
<div style="width: 15px;"></div> <!-- Spacer -->
<tui-button variant="primary" onclick="togglemodal('modal-small','close')">Ok</tui-button>
</tui-hstack>
</tui-modal-footer>
</tui-modal>
<hr />
<h3>Cards</h3>
<p> ⚠️ Docs under construction ⚠️ </p>
<tui-hstack>
<tui-card>
<tui-card-header>
<tui-h1>
Card header
</tui-h1>
</tui-card-header>
<tui-card-body>
<p>
Aenean malesuada nibh sed diam facilisis fringilla. Curabitur efficitur risus ac gravida volutpat. Quisque
in ultrices libero. Fusce congue enim in lacus posuere finibus. Quisque eu imperdiet lectus. Mauris
hendrerit congue libero, congue condimentum urna varius ac. Nulla scelerisque libero sed pretium gravida.
</p>
</tui-card-body>
</tui-card>
<tui-card>
<tui-card-header>
<tui-h1>
Card header
</tui-h1>
</tui-card-header>
<tui-card-body>
<p>
Aenean malesuada nibh sed diam facilisis fringilla. Curabitur efficitur risus ac gravida volutpat. Quisque
in ultrices libero. Fusce congue enim in lacus posuere finibus. Quisque eu imperdiet lectus. Mauris
hendrerit congue libero, congue condimentum urna varius ac. Nulla scelerisque libero sed pretium gravida.
</p>
</tui-card-body>
</tui-card>
</tui-hstack>
<hr />
<h3>Form Control</h3>
<p> ⚠️ Docs under Construction ⚠️ </p>
<tui-form-group>
<tui-form-label>String</tui-form-label>
<tui-form-input />
</tui-form-group>
<tui-form-group>
<tui-form-label>Number</tui-form-label>
<tui-form-input type="number" />
</tui-form-group>
<br />
<h4>Variants</h4>
<tui-hstack justifyContent="space-around">
<tui-form-group>
<tui-form-label>Default</tui-form-label>
<tui-form-input />
</tui-form-group>
<tui-form-group>
<tui-form-label>Info</tui-form-label>
<tui-form-input variant="info" />
</tui-form-group>
<tui-form-group>
<tui-form-label>Warning</tui-form-label>
<tui-form-input variant="warning" />
</tui-form-group>
<tui-form-group>
<tui-form-label>Danger</tui-form-label>
<tui-form-input variant="danger" />
</tui-form-group>
<tui-form-group>
<tui-form-label>Success</tui-form-label>
<tui-form-input variant="success" />
</tui-form-group>
</tui-hstack>
</tui-container>
</tui-container>
</div>
<footer>
<tui-container p=5 textAlign="right">
<p style="font-size: small; ">Built with ❤️ by <a href="https://alejandropiumetti.com.ar/">alepiumetti</a></p>
</tui-container>
</footer>
<script src="./components/layout.js"></script>
<script src="./components/buttons.js"></script>
<script src="./components/text.js"></script>
<script src="./components/modal.js"></script>
<script src="./components/card.js"></script>
<script src="./components/form.js"></script>
<script src="./script.js"></script>
</body>
</html>