@trilogy-ds/styles 0.0.1-beta-1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (104) hide show
  1. package/framework/src/_all.scss +8 -0
  2. package/framework/src/base/_all.scss +9 -0
  3. package/framework/src/base/_color.scss +58 -0
  4. package/framework/src/base/_elements.scss +34 -0
  5. package/framework/src/base/_fonts.scss +2 -0
  6. package/framework/src/base/_generic.scss +68 -0
  7. package/framework/src/base/_helpers.scss +880 -0
  8. package/framework/src/base/_loading.scss +102 -0
  9. package/framework/src/base/_reset.scss +138 -0
  10. package/framework/src/components/_accordion.scss +178 -0
  11. package/framework/src/components/_all.scss +30 -0
  12. package/framework/src/components/_autolayout2.scss +38 -0
  13. package/framework/src/components/_breadcrumb.scss +45 -0
  14. package/framework/src/components/_card.scss +298 -0
  15. package/framework/src/components/_countdown.scss +55 -0
  16. package/framework/src/components/_disclaimer.scss +84 -0
  17. package/framework/src/components/_divider.scss +18 -0
  18. package/framework/src/components/_dropdown.scss +128 -0
  19. package/framework/src/components/_fab.scss +60 -0
  20. package/framework/src/components/_level.scss +120 -0
  21. package/framework/src/components/_media.scss +64 -0
  22. package/framework/src/components/_menu.scss +213 -0
  23. package/framework/src/components/_modal.scss +201 -0
  24. package/framework/src/components/_otp.scss +92 -0
  25. package/framework/src/components/_pagination.scss +182 -0
  26. package/framework/src/components/_plus-symbol.scss +32 -0
  27. package/framework/src/components/_popover.scss +340 -0
  28. package/framework/src/components/_price.scss +209 -0
  29. package/framework/src/components/_product-tour.scss +131 -0
  30. package/framework/src/components/_progress-radial.scss +23 -0
  31. package/framework/src/components/_range.scss +84 -0
  32. package/framework/src/components/_scroll-view.scss +19 -0
  33. package/framework/src/components/_search-modal.scss +197 -0
  34. package/framework/src/components/_segmented-control.scss +60 -0
  35. package/framework/src/components/_slices.scss +316 -0
  36. package/framework/src/components/_slider.scss +92 -0
  37. package/framework/src/components/_stepper.scss +397 -0
  38. package/framework/src/components/_switch.scss +209 -0
  39. package/framework/src/components/_tabs.scss +212 -0
  40. package/framework/src/components/_timeline.scss +367 -0
  41. package/framework/src/elements/_alert.scss +91 -0
  42. package/framework/src/elements/_all.scss +35 -0
  43. package/framework/src/elements/_badge.scss +81 -0
  44. package/framework/src/elements/_box.scss +267 -0
  45. package/framework/src/elements/_button.scss +192 -0
  46. package/framework/src/elements/_checkbox.scss +39 -0
  47. package/framework/src/elements/_checkradio.scss +173 -0
  48. package/framework/src/elements/_chips.scss +100 -0
  49. package/framework/src/elements/_container.scss +108 -0
  50. package/framework/src/elements/_dot.scss +6 -0
  51. package/framework/src/elements/_entry.scss +109 -0
  52. package/framework/src/elements/_form.scss +593 -0
  53. package/framework/src/elements/_icon.scss +384 -0
  54. package/framework/src/elements/_image.scss +59 -0
  55. package/framework/src/elements/_input-gauge.scss +37 -0
  56. package/framework/src/elements/_input-icons.scss +41 -0
  57. package/framework/src/elements/_link.scss +79 -0
  58. package/framework/src/elements/_list.scss +61 -0
  59. package/framework/src/elements/_loader.scss +126 -0
  60. package/framework/src/elements/_notification.scss +151 -0
  61. package/framework/src/elements/_options.scss +146 -0
  62. package/framework/src/elements/_other.scss +44 -0
  63. package/framework/src/elements/_paragraph.scss +101 -0
  64. package/framework/src/elements/_progress.scss +212 -0
  65. package/framework/src/elements/_radio.scss +67 -0
  66. package/framework/src/elements/_select.scss +315 -0
  67. package/framework/src/elements/_sticker.scss +151 -0
  68. package/framework/src/elements/_switch.scss +108 -0
  69. package/framework/src/elements/_table.scss +298 -0
  70. package/framework/src/elements/_tag.scss +131 -0
  71. package/framework/src/elements/_textarea.scss +125 -0
  72. package/framework/src/elements/_timeline.scss +283 -0
  73. package/framework/src/elements/_title.scss +139 -0
  74. package/framework/src/elements/_toaster.scss +128 -0
  75. package/framework/src/grid/_all.scss +3 -0
  76. package/framework/src/grid/_columns.scss +952 -0
  77. package/framework/src/grid/_rows.scss +47 -0
  78. package/framework/src/grid/_tiles.scss +78 -0
  79. package/framework/src/layout/_all.scss +6 -0
  80. package/framework/src/layout/_hero.scss +268 -0
  81. package/framework/src/layout/_main.scss +36 -0
  82. package/framework/src/layout/_section.scss +65 -0
  83. package/framework/src/layout/_toolbar.scss +100 -0
  84. package/framework/src/trilogy-core.scss +16 -0
  85. package/framework/src/trilogy-mangled.scss +14 -0
  86. package/framework/src/trilogy-namespaced.scss +14 -0
  87. package/framework/src/trilogy.scss +8 -0
  88. package/framework/src/utilities/_all.scss +9 -0
  89. package/framework/src/utilities/_animations.scss +71 -0
  90. package/framework/src/utilities/_controls.scss +67 -0
  91. package/framework/src/utilities/_derived-variables.scss +104 -0
  92. package/framework/src/utilities/_functions.scss +94 -0
  93. package/framework/src/utilities/_initial-variables.scss +150 -0
  94. package/framework/src/utilities/_mixins.scss +745 -0
  95. package/framework/src/utilities/_post.scss +6 -0
  96. package/framework/src/utilities/_pre.scss +5 -0
  97. package/framework/src/utilities/_spacing.scss +10 -0
  98. package/framework/src/utilities/_tools.scss +3 -0
  99. package/package.json +22 -0
  100. package/themes/default/src/_all.scss +1 -0
  101. package/themes/default/src/assets.scss +11 -0
  102. package/themes/default/src/utilities/_all.scss +0 -0
  103. package/themes/default/src/utilities/_post.scss +0 -0
  104. package/themes/default/src/utilities/_pre.scss +3 -0
@@ -0,0 +1,593 @@
1
+ $file-radius: $radius;
2
+ $file-name-max-width: 16em;
3
+ $field-margin: 20px;
4
+ $help-size: $size-small;
5
+ $label-weight: $weight-bold;
6
+
7
+ .field {
8
+ &:not(:first-child) {
9
+ margin-top: $field-margin;
10
+ }
11
+
12
+ &:not(:last-child) {
13
+ margin-bottom: 7.5px;
14
+ }
15
+
16
+ &.is-fullwidth {
17
+ div.control {
18
+ flex: 1;
19
+ }
20
+ }
21
+
22
+ @include mobile {
23
+ &.is-very-short,
24
+ &.is-short {
25
+ width: 50%;
26
+ }
27
+
28
+ &.is-long,
29
+ &.is-very-long {
30
+ width: 100%;
31
+ }
32
+ }
33
+
34
+ @include tablet {
35
+ &.is-very-short {
36
+ width: 130px;
37
+ }
38
+
39
+ &.is-short {
40
+ width: 270px;
41
+ }
42
+
43
+ &.is-long {
44
+ width: 400px;
45
+ }
46
+
47
+ &.is-very-long {
48
+ width: 500px;
49
+ }
50
+ }
51
+
52
+ .select {
53
+ @extend .is-fullwidth;
54
+ }
55
+
56
+ &.has-addons {
57
+ display: flex;
58
+ justify-content: flex-start;
59
+
60
+ .control {
61
+ &:not(:last-child) {
62
+ margin-right: -1px;
63
+ }
64
+
65
+ &:not(:first-child):not(:last-child) {
66
+ .button,
67
+ .input,
68
+ .select select {
69
+ border-radius: 0;
70
+ }
71
+ }
72
+
73
+ &:first-child {
74
+ .button,
75
+ .input,
76
+ .select select {
77
+ border-bottom-right-radius: 0;
78
+ border-top-right-radius: 0;
79
+ }
80
+ }
81
+
82
+ &:last-child {
83
+ .button,
84
+ .input,
85
+ .select select {
86
+ border-bottom-left-radius: 0;
87
+ border-top-left-radius: 0;
88
+ }
89
+ }
90
+
91
+ .button,
92
+ .input,
93
+ .textarea,
94
+ .select select {
95
+ &:hover,
96
+ &.is-hovered {
97
+ z-index: zindex('tiny');
98
+ }
99
+
100
+ &:focus,
101
+ &.is-focused,
102
+ &:active,
103
+ &.is-active {
104
+ z-index: zindex('small');
105
+
106
+ &:hover {
107
+ z-index: zindex('medium');
108
+ }
109
+ }
110
+ }
111
+
112
+ &.is-expanded {
113
+ flex-grow: 1;
114
+ }
115
+ }
116
+
117
+ &.has-addons-centered {
118
+ justify-content: center;
119
+ }
120
+
121
+ &.has-addons-right {
122
+ justify-content: flex-end;
123
+ }
124
+
125
+ &.has-addons-fullwidth {
126
+ .control {
127
+ flex-grow: 1;
128
+ flex-shrink: 0;
129
+ }
130
+ }
131
+ }
132
+
133
+ &.is-grouped {
134
+ display: flex;
135
+ justify-content: flex-start;
136
+
137
+ & > .control {
138
+ flex-shrink: 0;
139
+
140
+ &:not(:last-child) {
141
+ margin-bottom: 0;
142
+ margin-right: 7.5px;
143
+ }
144
+
145
+ &.is-expanded {
146
+ flex-grow: 1;
147
+ flex-shrink: 1;
148
+ }
149
+ }
150
+
151
+ &.is-grouped-centered {
152
+ justify-content: center;
153
+ }
154
+
155
+ &.is-grouped-right {
156
+ justify-content: flex-end;
157
+ }
158
+
159
+ &.is-grouped-multiline {
160
+ flex-wrap: wrap;
161
+
162
+ & > .control {
163
+ &:last-child,
164
+ &:not(:last-child) {
165
+ margin-bottom: 7.5px;
166
+ }
167
+ }
168
+
169
+ &:last-child {
170
+ margin-bottom: -7.5px;
171
+ }
172
+
173
+ &:not(:last-child) {
174
+ margin-bottom: 0;
175
+ }
176
+ }
177
+ }
178
+
179
+ &.is-horizontal {
180
+ @include tablet {
181
+ display: flex;
182
+ }
183
+ }
184
+ }
185
+
186
+ .control {
187
+ font-size: $size-normal;
188
+ position: relative;
189
+ text-align: left;
190
+
191
+ &.has-icons-left,
192
+ &.has-icons-right {
193
+ .input,
194
+ .textarea,
195
+ .select {
196
+ &:focus {
197
+ & ~ .icon {
198
+ color: getColor('grey');
199
+ }
200
+ }
201
+
202
+ ~ .icon {
203
+ [class^='tri-'],
204
+ [class*=' tri-'] {
205
+ font-size: 20px;
206
+ }
207
+ }
208
+ }
209
+
210
+ .icon {
211
+ color: getColor('grey-light');
212
+ position: absolute;
213
+ top: 0;
214
+ height: 100%;
215
+ width: 40px;
216
+ pointer-events: auto;
217
+ z-index: zindex('void');
218
+ padding: 10px;
219
+ }
220
+
221
+ .input {
222
+ @each $name, $pair in $colors-feedback {
223
+ $bg-color: nth($pair, 1);
224
+ &.is-#{$name} {
225
+ ~ .icon {
226
+ color: getColor($bg-color);
227
+ }
228
+ }
229
+ }
230
+
231
+ &.is-error {
232
+ border-color: getColor('error');
233
+ }
234
+ }
235
+
236
+ .textarea {
237
+ @each $name, $pair in $colors-feedback {
238
+ $bg-color: nth($pair, 1);
239
+ &.is-#{$name} {
240
+ ~ .icon {
241
+ color: getColor($bg-color)
242
+ }
243
+ }
244
+ }
245
+
246
+ &.is-error {
247
+ border-color: getColor('error');
248
+ }
249
+ }
250
+ }
251
+
252
+ &.has-icons-left {
253
+ .input,
254
+ .select select {
255
+ padding-left: 45px;
256
+ }
257
+
258
+ .icon {
259
+ left: 0;
260
+ border-top-left-radius: $radius;
261
+ border-bottom-left-radius: $radius;
262
+ }
263
+
264
+ .textarea {
265
+ padding-left: 50px;
266
+ padding-right: $spacing-4;
267
+ padding-bottom: $spacing-4 !important;
268
+ padding-top: $spacing-4;
269
+ }
270
+
271
+ & .textarea + label {
272
+ left: 5rem;
273
+ }
274
+
275
+ & .textarea + label + .icon {
276
+ display: inherit;
277
+ padding-top: $spacing-4;
278
+ margin: 0 16px;
279
+ width: auto;
280
+ }
281
+
282
+ .textarea-counter {
283
+ position: absolute;
284
+ bottom: 5px;
285
+ right: 16px;
286
+ font-size: $size-xsmall;
287
+ }
288
+
289
+ .is-error ~ .textarea-counter {
290
+ bottom: 28px;
291
+ }
292
+ }
293
+
294
+ &.has-icons-right {
295
+ .input,
296
+ .select select {
297
+ padding-right: 45px;
298
+ }
299
+
300
+ .icon {
301
+ right: 0;
302
+ border-top-right-radius: $radius;
303
+ border-bottom-right-radius: $radius;
304
+ }
305
+ }
306
+
307
+ /** Dynamic placeholders **/
308
+ &.has-dynamic-placeholder {
309
+
310
+ ::placeholder {
311
+ color: black;
312
+ }
313
+
314
+
315
+ textarea:not(:placeholder-shown) {
316
+ padding-top: $spacing-5;
317
+ }
318
+
319
+
320
+ .input ~ label {
321
+ top: 10px;
322
+ }
323
+
324
+ .icon {
325
+ color: getColor('font');
326
+ }
327
+
328
+ label {
329
+ position: absolute;
330
+ top: 10px;
331
+ left: 16px;
332
+ border-left: transparent 1px solid;
333
+ font-size: $text-12;
334
+ color: getColor('grey');
335
+ transform: translateY(0);
336
+ transition: all 0.2s ease-out;
337
+ z-index: zindex('small');
338
+ white-space: nowrap;
339
+ text-overflow: ellipsis;
340
+ max-width: calc(100% - 4em);
341
+ overflow: hidden;
342
+ pointer-events: none;
343
+ user-select: none;
344
+ line-height: 14px;
345
+ }
346
+
347
+ &.has-icons-left label {
348
+ left: 45px;
349
+ }
350
+
351
+ select:not(.no-label) {
352
+ padding-top: 19px;
353
+ }
354
+
355
+ .input {
356
+ padding-top: 19px;
357
+
358
+ &:placeholder-shown {
359
+ padding-top: 0.375em;
360
+ }
361
+
362
+ &:-ms-input-placeholder {
363
+ padding-top: 0.375em;
364
+ }
365
+ }
366
+
367
+ textarea {
368
+ padding-top: $spacing-4;
369
+ padding-bottom: $spacing-2 !important;
370
+ }
371
+
372
+ input:placeholder-shown ~ label,
373
+ textarea:placeholder-shown ~ label {
374
+ visibility: hidden;
375
+ opacity: 0;
376
+ font-size: $size-normal;
377
+ transform: translateY(10px);
378
+ }
379
+
380
+ input:-ms-input-placeholder ~ label {
381
+ visibility: hidden;
382
+ opacity: 0;
383
+ font-size: $size-normal;
384
+ transform: translateY(10px);
385
+ }
386
+ }
387
+
388
+ &.has-icons-left.has-dynamic-placeholder .textarea + label {
389
+ left: 50px;
390
+ }
391
+
392
+ &.has-password-discover {
393
+ .input {
394
+ ~ .icon:not(:last-child) {
395
+ color: getColor('grey');
396
+ background-color: transparent;
397
+ right: 45px;
398
+ cursor: pointer;
399
+ &:hover,
400
+ &:focus {
401
+ color: getColor('grey-darker');
402
+ }
403
+ }
404
+ }
405
+ }
406
+
407
+ + .help {
408
+ margin: 4px 0;
409
+ font-size: $text-12;
410
+ font-weight: $weight-medium;
411
+ }
412
+
413
+ .is-searching {
414
+ background-color: transparent;
415
+ border-top-right-radius: $radius;
416
+ border-bottom-right-radius: $radius;
417
+ height: 100%;
418
+ position: absolute;
419
+ right: 0;
420
+ top: 0;
421
+ width: 45px;
422
+
423
+ &::after {
424
+ @include spinner;
425
+ @include center(1em);
426
+ }
427
+ }
428
+
429
+ &.is-loading {
430
+ &::after {
431
+ @include spinner;
432
+
433
+ position: absolute !important;
434
+ right: 0.625em;
435
+ top: 0.625em;
436
+ z-index: zindex('small');
437
+ }
438
+
439
+ &.is-small::after {
440
+ font-size: $size-small;
441
+ }
442
+
443
+ &.is-large::after {
444
+ font-size: $size-large;
445
+ }
446
+ }
447
+ }
448
+
449
+ .field-label {
450
+ .label {
451
+ font-size: inherit;
452
+ }
453
+
454
+ @include mobile {
455
+ margin-bottom: 5px;
456
+ }
457
+
458
+ @include tablet {
459
+ flex-basis: 0;
460
+ flex-grow: 1;
461
+ flex-shrink: 0;
462
+ margin-right: 16px;
463
+ text-align: right;
464
+
465
+ &.is-small {
466
+ font-size: $size-small;
467
+ padding-top: 0.375em;
468
+ }
469
+
470
+ &.is-normal {
471
+ padding-top: 0.375em;
472
+ }
473
+
474
+ &.is-large {
475
+ font-size: $size-large;
476
+ padding-top: 0.375em;
477
+ }
478
+ }
479
+ }
480
+
481
+ .field-body {
482
+ .field .field {
483
+ margin-bottom: 0;
484
+ }
485
+
486
+ @include tablet {
487
+ display: flex;
488
+ flex-basis: 0;
489
+ flex-grow: 5;
490
+ flex-shrink: 1;
491
+
492
+ .field {
493
+ margin-bottom: 0;
494
+ }
495
+
496
+ & > .field {
497
+ flex-shrink: 1;
498
+
499
+ &:not(.is-narrow) {
500
+ flex-grow: 1;
501
+ }
502
+
503
+ &:not(:last-child) {
504
+ margin-right: 7.5px;
505
+ }
506
+ }
507
+ }
508
+ }
509
+
510
+ .file {
511
+ @include unselectable;
512
+
513
+ align-items: stretch;
514
+ display: flex;
515
+ justify-content: flex-start;
516
+ position: relative;
517
+
518
+ // Sizes
519
+ &.is-small {
520
+ font-size: $size-small;
521
+ }
522
+
523
+ &.is-large {
524
+ font-size: $size-large;
525
+ }
526
+
527
+ &.is-centered {
528
+ justify-content: center;
529
+ }
530
+
531
+ &.is-right {
532
+ justify-content: flex-end;
533
+ }
534
+ }
535
+
536
+ .is-horizontal {
537
+ .field:not(:first-child) {
538
+ margin-top: 0;
539
+ }
540
+
541
+ &.is-mobile {
542
+ @include mobile {
543
+ .field-body {
544
+ display: flex;
545
+
546
+ .field {
547
+ margin-bottom: 0;
548
+ }
549
+
550
+ & > .field {
551
+ &:not(:last-child) {
552
+ margin-right: 7.5px;
553
+ }
554
+ }
555
+ }
556
+ }
557
+ }
558
+ }
559
+
560
+ .label {
561
+ color: getColor('grey-dark');
562
+ display: block;
563
+ font-size: $size-normal;
564
+ font-weight: $label-weight;
565
+
566
+ &:not(:last-child) {
567
+ margin-bottom: 0.5em;
568
+ }
569
+
570
+ // Sizes
571
+ &.is-small {
572
+ font-size: $size-small;
573
+ }
574
+
575
+ &.is-large {
576
+ font-size: $size-large;
577
+ }
578
+ }
579
+
580
+ .help {
581
+ display: block;
582
+ font-size: $help-size;
583
+ margin-top: 2.5px;
584
+
585
+ @each $name, $pair in $colors-brand-funcionnal {
586
+ $color: getColor($name);
587
+ $brandName: getColorBrandName($name);
588
+
589
+ &.is-#{$brandName} {
590
+ color: $color;
591
+ }
592
+ }
593
+ }