@trilogy-ds/styles 0.0.1-beta.9 → 0.0.3-beta-v4

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 (94) hide show
  1. package/dist/default/trilogy-mangled.css +1 -1
  2. package/dist/default/trilogy-partials.css +1 -1
  3. package/dist/default/trilogy.css +1 -1
  4. package/framework/src/base/_color.scss +9 -39
  5. package/framework/src/base/_generic.scss +4 -1
  6. package/framework/src/base/_helpers.scss +13 -38
  7. package/framework/src/base/_loading.scss +8 -1
  8. package/framework/src/base/_reset.scss +8 -3
  9. package/framework/src/components/_accordion.scss +53 -88
  10. package/framework/src/components/_all.scss +1 -7
  11. package/framework/src/components/_autolayout.scss +302 -0
  12. package/framework/src/components/_breadcrumb.scss +39 -34
  13. package/framework/src/components/_card.scss +8 -79
  14. package/framework/src/components/_countdown.scss +49 -47
  15. package/framework/src/components/_divider.scss +10 -15
  16. package/framework/src/components/_fab.scss +25 -38
  17. package/framework/src/components/_modal.scss +161 -158
  18. package/framework/src/components/_otp.scss +10 -29
  19. package/framework/src/components/_pagination.scss +59 -161
  20. package/framework/src/components/_plus-symbol.scss +1 -1
  21. package/framework/src/components/_popover.scss +260 -260
  22. package/framework/src/components/_price.scss +119 -170
  23. package/framework/src/components/_product-tour.scss +2 -4
  24. package/framework/src/components/_progress-radial.scss +24 -19
  25. package/framework/src/components/_range.scss +73 -72
  26. package/framework/src/components/_segmented-control.scss +51 -53
  27. package/framework/src/components/_stepper.scss +42 -222
  28. package/framework/src/components/_tabs.scss +46 -81
  29. package/framework/src/components/_timeline.scss +27 -112
  30. package/framework/src/elements/_alert.scss +13 -10
  31. package/framework/src/elements/_all.scss +1 -4
  32. package/framework/src/elements/_autocomplete.scss +32 -0
  33. package/framework/src/elements/_badge.scss +67 -61
  34. package/framework/src/elements/_box.scss +64 -161
  35. package/framework/src/elements/_button.scss +15 -141
  36. package/framework/src/elements/_checkbox.scss +29 -26
  37. package/framework/src/elements/_chips.scss +69 -85
  38. package/framework/src/elements/_container.scss +7 -39
  39. package/framework/src/elements/_entry.scss +76 -88
  40. package/framework/src/elements/_form.scss +26 -23
  41. package/framework/src/elements/_icon.scss +4 -4
  42. package/framework/src/elements/_image.scss +50 -40
  43. package/framework/src/elements/_input-gauge.scss +32 -33
  44. package/framework/src/elements/_input-icons.scss +33 -31
  45. package/framework/src/elements/_link.scss +38 -65
  46. package/framework/src/elements/_list.scss +45 -44
  47. package/framework/src/elements/_loader.scss +2 -2
  48. package/framework/src/elements/_other.scss +0 -37
  49. package/framework/src/elements/_paragraph.scss +35 -69
  50. package/framework/src/elements/_progress.scss +33 -22
  51. package/framework/src/elements/_radio.scss +45 -31
  52. package/framework/src/elements/_select.scss +85 -304
  53. package/framework/src/elements/_sticker.scss +12 -27
  54. package/framework/src/elements/_switch.scss +101 -99
  55. package/framework/src/elements/_table.scss +175 -228
  56. package/framework/src/elements/_tag.scss +104 -105
  57. package/framework/src/elements/_textarea.scss +113 -105
  58. package/framework/src/elements/_title.scss +89 -87
  59. package/framework/src/elements/_toaster.scss +4 -5
  60. package/framework/src/grid/_columns.scss +257 -764
  61. package/framework/src/grid/_rows.scss +45 -38
  62. package/framework/src/layout/_all.scss +0 -1
  63. package/framework/src/layout/_hero.scss +89 -215
  64. package/framework/src/layout/_section.scss +5 -29
  65. package/framework/src/theming/_all.scss +3 -0
  66. package/framework/src/theming/buttons_partial.scss +32 -0
  67. package/framework/src/theming/common_partials.scss +10 -0
  68. package/framework/src/theming/links_partial.scss +20 -0
  69. package/framework/src/utilities/_a11y.scss +13 -0
  70. package/framework/src/utilities/_all.scss +4 -0
  71. package/framework/src/utilities/_background.scss +19 -0
  72. package/framework/src/utilities/_colors.scss +40 -0
  73. package/framework/src/utilities/_controls.scss +38 -49
  74. package/framework/src/utilities/_derived-variables.scss +4 -15
  75. package/framework/src/utilities/_initial-variables.scss +4 -36
  76. package/framework/src/utilities/_mixins.scss +483 -592
  77. package/framework/src/utilities/_pre.scss +1 -0
  78. package/package.json +3 -3
  79. package/framework/src/components/_autolayout2.scss +0 -38
  80. package/framework/src/components/_disclaimer.scss +0 -84
  81. package/framework/src/components/_dropdown.scss +0 -128
  82. package/framework/src/components/_level.scss +0 -120
  83. package/framework/src/components/_media.scss +0 -64
  84. package/framework/src/components/_menu.scss +0 -213
  85. package/framework/src/components/_search-modal.scss +0 -197
  86. package/framework/src/components/_slices.scss +0 -316
  87. package/framework/src/components/_slider.scss +0 -92
  88. package/framework/src/components/_switch.scss +0 -209
  89. package/framework/src/elements/_checkradio.scss +0 -173
  90. package/framework/src/elements/_dot.scss +0 -6
  91. package/framework/src/elements/_notification.scss +0 -151
  92. package/framework/src/elements/_options.scss +0 -146
  93. package/framework/src/elements/_timeline.scss +0 -283
  94. package/framework/src/layout/_toolbar.scss +0 -100
@@ -1,100 +1,84 @@
1
- $chip-radius: 30px !default;
1
+ @import "../utilities/spacing";
2
2
 
3
3
  .chips-list {
4
- align-items: center;
5
- display: inline-flex;
6
- justify-content: flex-start;
7
- margin-bottom: 16px;
8
- flex-wrap: wrap;
4
+ align-items: center;
5
+ display: flex;
6
+ justify-content: flex-start;
7
+ flex-wrap: wrap;
8
+ gap: $spacing-2;
9
9
 
10
- // multi-chips : ajout d'une marge bottom, supprimable par facette
11
- &:not(.is-gapless) {
12
- &:not(:last-child) {
13
- margin-right: 8px;
14
- }
10
+ // centrage des chips
11
+ &.is-centered {
12
+ justify-content: center;
13
+ }
15
14
 
16
- .chips {
17
- margin-bottom: 10px;
18
- }
15
+ &.is-scrollable {
16
+ flex-wrap: nowrap;
17
+ overflow: auto;
18
+ &::-webkit-scrollbar {
19
+ display: none;
19
20
  }
21
+ }
20
22
 
21
- // multi-chips : ajout d'une marge à droite de chaque chip
22
- .chips:not(:last-child) {
23
- margin-right: 8px;
23
+ &.is-multiple {
24
+ .chips:before {
25
+ content: "";
26
+ mask-image: url('./assets/icons/all/check.svg');
27
+ background-color: currentColor;
28
+ margin-right: 4px;
29
+ margin-left: -8px;
30
+ width: 0;
31
+ height: 20px;
32
+ mask-size: 20px;
33
+ transition: width 250ms;
24
34
  }
25
-
26
- // centrage des chips
27
- &.is-centered {
28
- justify-content: center;
35
+ .chips.is-active:before{
36
+ width: 20px;
29
37
  }
38
+ }
30
39
 
31
- &.is-multiple {
32
- .chips.is-active:before {
33
- content: "";
34
- mask-image: url('./assets/icons/all/check.svg');
35
- background-color: getColor('background');
36
- margin-right: 4px;
37
- margin-left: -8px;
38
- width: 20px;
39
- height: 20px;
40
- mask-size: 20px;
40
+ .chips {
41
+ align-items: center;
42
+ background-color: white;
43
+ border-radius: 9999px;
44
+ color: getColor('font');
45
+ display: inline-flex;
46
+ font-size: $size-normal;
47
+ height: 32px;
48
+ justify-content: center;
49
+ line-height: 2;
50
+ padding: 6px $spacing-4;
51
+ white-space: nowrap;
52
+ cursor: pointer;
53
+ border: var(--border);
54
+ &:not(.is-disabled) {
55
+ &.is-active {
56
+ background-color: getColor('main');
57
+ color: white;
58
+ border: var(--border-active);
59
+ padding: 5px ($spacing-4 - 1px);
60
+ #{$hoverSelector} {
61
+ background-color: getColor('main');
62
+ color: white;
41
63
  }
64
+ }
65
+ #{$hoverSelector} {
66
+ background-color: getColor('neutral-fade');
67
+ }
42
68
  }
43
69
 
44
- .chips {
45
- align-items: center;
46
- background-color: getColor('grey-lighter');
47
- border-radius: $chip-radius;
48
- color: getColor('font');
49
- display: inline-flex;
50
- font-weight: 400;
51
- font-size: $size-normal;
52
- height: 32px;
53
- justify-content: center;
54
- line-height: 2;
55
- padding: 6px $spacing-4;
56
- white-space: nowrap;
57
- cursor: pointer;
58
- border: 1px solid getColor('grey-light');
70
+ &.is-inverted {
71
+ background-color: white;
72
+ color: getColor('accent');
59
73
 
60
- &:not(.is-disabled) {
61
- &:hover {
62
- background-color: getColor('grey-light');
63
- border: 2px solid currentColor;
64
- color: getColor('alternate');
65
- padding: 5px 15px;
66
- }
67
-
68
- &:focus,
69
- &:focus-visible,
70
- &.is-active {
71
- background-color: getColor('alternate');
72
- color: white;
73
- font-weight: 600;
74
- border: 2px solid getColor('alternate');
75
- padding: 5px 15px;
76
- }
77
- }
78
-
79
- &.is-disabled {
80
- background-color: getColor('grey-disabled');
81
- color: getColor('grey-darker');
82
- cursor: no-drop;
83
- border: 1px solid getColor('grey-disabled');
84
- }
85
-
86
- &.is-inverted {
87
- background-color: white;
88
- color: getColor('alternate');
89
-
90
- &:active,
91
- &:hover,
92
- &:focus,
93
- &:focus-visible,
94
- &.is-active {
95
- background-color: getColor('alternate') !important;
96
- color: getColor('background') !important;
97
- }
98
- }
74
+ &:active,
75
+ &:hover,
76
+ &:focus,
77
+ &:focus-visible,
78
+ &.is-active {
79
+ background-color: getColor('accent') !important;
80
+ color: getColor('background') !important;
81
+ }
99
82
  }
83
+ }
100
84
  }
@@ -21,14 +21,7 @@
21
21
 
22
22
  @include desktop {
23
23
  max-width: $desktop - 2 * $gap;
24
- width: $desktop - 2 * $gap;
25
-
26
- &.is-fluid {
27
- margin-left: $gap;
28
- margin-right: $gap;
29
- max-width: none;
30
- width: auto;
31
- }
24
+ width: auto;
32
25
  }
33
26
 
34
27
  @include until-widescreen {
@@ -51,34 +44,11 @@
51
44
  }
52
45
 
53
46
  @include fullhd {
47
+ margin: 0 auto;
54
48
  max-width: $fullhd - 2 * $gap;
55
49
  width: $fullhd - 2 * $gap;
56
50
  }
57
51
 
58
- &:not(.is-fluid) {
59
- @include desktop {
60
- width: 904px;
61
- max-width: 904px;
62
- }
63
-
64
- @include widescreen {
65
- width: 1160px;
66
- max-width: 1160px;
67
- }
68
-
69
- @include fullhd {
70
- width: 1308px;
71
- max-width: 1308px;
72
- }
73
- }
74
-
75
- &.is-fluid {
76
- @include fullhd {
77
- margin: 0 auto;
78
- max-width: $fullhd - 2 * $gap;
79
- }
80
- }
81
-
82
52
  &.is-medium {
83
53
  max-width: 960px;
84
54
  margin: auto;
@@ -95,14 +65,12 @@ header .navbar,
95
65
  header,
96
66
  footer {
97
67
  > .container {
98
- &.is-fluid {
99
- @include desktop {
100
- margin: 0 auto;
101
- }
68
+ @include desktop {
69
+ margin: 0 auto;
70
+ }
102
71
 
103
- @include fullhd {
104
- max-width: 100%;
105
- }
72
+ @include fullhd {
73
+ max-width: 100%;
106
74
  }
107
75
  }
108
76
  }
@@ -1,109 +1,97 @@
1
1
  .input,
2
2
  .textarea {
3
- @include input;
4
-
5
- padding-left: $spacing-4;
6
- padding-right: $spacing-4;
7
- font-family: $body-family;
8
- font-size: $size-medium;
9
- max-width: 100%;
10
- width: 100%;
11
-
12
- &:focus-visible,
13
- :focus {
14
- outline: 1px auto getColor('alternate');
3
+ @include input;
4
+
5
+ padding-left: $spacing-4;
6
+ padding-right: $spacing-4;
7
+ font-size: $size-medium;
8
+ max-width: 100%;
9
+ width: 100%;
10
+
11
+ // Colors
12
+ @each $name in $colors-brand-functionnal {
13
+ $color: getColor($name);
14
+ $color-invert: invertColor($name);
15
+ $brandName: getColorBrandName($name);
16
+
17
+ &.is-#{$brandName} {
18
+ border: 1px solid $color;
15
19
  }
20
+ }
16
21
 
17
- // Colors
18
- @each $name in $colors-brand-funcionnal {
19
- $color: getColor($name);
20
- $color-invert: invertColor($name);
21
- $brandName: getColorBrandName($name);
22
-
23
- &.is-#{$brandName} {
24
- border: 2px solid $color;
25
- &:focus-visible,
26
- &:hover,
27
- &.is-hovered,
28
- &:focus,
29
- &.is-focused {
30
- outline: 1px auto $color !important;
31
- }
32
- }
33
- }
22
+ &:active,
23
+ &:focus,
24
+ &:focus-visible:not(.icon) {
25
+ padding-left: 15px !important;
26
+ }
34
27
 
35
- // Sizes
36
- &.is-small {
37
- @include control-small;
38
- }
28
+ // Sizes
29
+ &.is-small {
30
+ @include control-small;
31
+ }
39
32
 
40
- &.is-large {
41
- @include control-large;
42
- }
33
+ &.is-large {
34
+ @include control-large;
35
+ }
43
36
 
44
- &.is-fullwidth {
45
- display: block;
46
- width: 100%;
47
- }
37
+ &.is-fullwidth {
38
+ display: block;
39
+ width: 100%;
40
+ }
48
41
 
49
- &.is-inline {
50
- display: inline;
51
- }
42
+ &.is-inline {
43
+ display: inline;
44
+ }
52
45
 
53
- .icon-status {
54
- color: aqua !important;
55
- }
46
+ .icon-status {
47
+ color: aqua !important;
48
+ }
56
49
 
57
- & label {
58
- margin-top: 10px;
59
- }
50
+ & label {
51
+ margin-top: 10px;
52
+ }
60
53
  }
61
54
 
62
55
  .input {
63
- &::-ms-clear {
64
- display: none;
65
- }
66
-
67
- &.is-small {
68
- height: 24px;
69
- }
70
-
71
- &.is-rounded {
72
- border-radius: $radius-rounded;
73
- padding-left: 1em;
74
- padding-right: 1em;
75
- }
76
-
77
- &.is-static {
78
- background-color: transparent;
79
- border-color: transparent;
80
- padding-left: 0;
81
- padding-right: 0;
82
- }
56
+ &::-ms-clear {
57
+ display: none;
58
+ }
59
+
60
+ &.is-small {
61
+ height: 24px;
62
+ }
63
+
64
+ &.is-rounded {
65
+ padding-left: 1em;
66
+ padding-right: 1em;
67
+ }
68
+
69
+ &.is-static {
70
+ background-color: transparent;
71
+ border-color: transparent;
72
+ padding-left: 0;
73
+ padding-right: 0;
74
+ }
83
75
  }
84
76
 
85
77
  .textarea {
86
- display: block;
87
- max-width: 100%;
88
- min-width: 100%;
89
- resize: vertical;
90
- padding-top: 15px;
91
-
78
+ display: block;
79
+ max-width: 100%;
80
+ min-width: 100%;
81
+ resize: vertical;
82
+ padding-top: 15px;
92
83
 
93
- &:not([rows]) {
94
- max-height: 600px;
95
- min-height: 120px;
96
- }
97
84
 
98
- &[rows] {
99
- height: initial;
100
- }
85
+ &:not([rows]) {
86
+ max-height: 600px;
87
+ min-height: 120px;
88
+ }
101
89
 
102
- &.has-fixed-size {
103
- resize: none;
104
- }
105
- }
90
+ &[rows] {
91
+ height: initial;
92
+ }
106
93
 
107
- .textarea[disabled]:hover {
108
- outline: 1px auto getColor('grey-disabled') !important;
94
+ &.has-fixed-size {
95
+ resize: none;
96
+ }
109
97
  }
@@ -5,20 +5,21 @@ $help-size: $size-small;
5
5
  $label-weight: $weight-bold;
6
6
 
7
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
8
  &.is-fullwidth {
17
9
  div.control {
18
10
  flex: 1;
19
11
  }
20
12
  }
21
13
 
14
+ .input-label {
15
+ display: inline-block;
16
+ margin-bottom: 6px;
17
+ }
18
+
19
+ .input-sample {
20
+ margin-bottom: 10px !important;
21
+ }
22
+
22
23
  @include mobile {
23
24
  &.is-very-short,
24
25
  &.is-short {
@@ -92,15 +93,12 @@ $label-weight: $weight-bold;
92
93
  .input,
93
94
  .textarea,
94
95
  .select select {
95
- &:hover,
96
- &.is-hovered {
96
+ &:hover {
97
97
  z-index: zindex('tiny');
98
98
  }
99
99
 
100
100
  &:focus,
101
- &.is-focused,
102
- &:active,
103
- &.is-active {
101
+ &:active {
104
102
  z-index: zindex('small');
105
103
 
106
104
  &:hover {
@@ -220,10 +218,9 @@ $label-weight: $weight-bold;
220
218
 
221
219
  .input {
222
220
  @each $name, $pair in $colors-feedback {
223
- $bg-color: nth($pair, 1);
224
221
  &.is-#{$name} {
225
222
  ~ .icon {
226
- color: getColor($bg-color);
223
+ color: fadeColor($name);
227
224
  }
228
225
  }
229
226
  }
@@ -235,10 +232,9 @@ $label-weight: $weight-bold;
235
232
 
236
233
  .textarea {
237
234
  @each $name, $pair in $colors-feedback {
238
- $bg-color: nth($pair, 1);
239
235
  &.is-#{$name} {
240
236
  ~ .icon {
241
- color: getColor($bg-color)
237
+ color: fadeColor($name);
242
238
  }
243
239
  }
244
240
  }
@@ -259,6 +255,7 @@ $label-weight: $weight-bold;
259
255
  left: 0;
260
256
  border-top-left-radius: $radius;
261
257
  border-bottom-left-radius: $radius;
258
+ padding: 0 24px;
262
259
  }
263
260
 
264
261
  .textarea {
@@ -301,6 +298,7 @@ $label-weight: $weight-bold;
301
298
  right: 0;
302
299
  border-top-right-radius: $radius;
303
300
  border-bottom-right-radius: $radius;
301
+ padding: 0 24px;
304
302
  }
305
303
  }
306
304
 
@@ -331,7 +329,8 @@ $label-weight: $weight-bold;
331
329
  left: 16px;
332
330
  border-left: transparent 1px solid;
333
331
  font-size: $text-12;
334
- color: getColor('grey');
332
+ color: getColor('font');
333
+ filter: grayscale(1);
335
334
  transform: translateY(0);
336
335
  transition: all 0.2s ease-out;
337
336
  z-index: zindex('small');
@@ -392,20 +391,20 @@ $label-weight: $weight-bold;
392
391
  &.has-password-discover {
393
392
  .input {
394
393
  ~ .icon:not(:last-child) {
395
- color: getColor('grey');
394
+ color: getColor('neutral');
396
395
  background-color: transparent;
397
396
  right: 45px;
398
397
  cursor: pointer;
398
+
399
399
  &:hover,
400
400
  &:focus {
401
- color: getColor('grey-darker');
401
+ color: getColor('neutral');
402
402
  }
403
403
  }
404
404
  }
405
405
  }
406
406
 
407
407
  + .help {
408
- margin: 4px 0;
409
408
  font-size: $text-12;
410
409
  font-weight: $weight-medium;
411
410
  }
@@ -444,6 +443,10 @@ $label-weight: $weight-bold;
444
443
  font-size: $size-large;
445
444
  }
446
445
  }
446
+
447
+ &:has(input[disabled]) {
448
+ @include disabledRulesWithoutBG;
449
+ }
447
450
  }
448
451
 
449
452
  .field-label {
@@ -558,7 +561,7 @@ $label-weight: $weight-bold;
558
561
  }
559
562
 
560
563
  .label {
561
- color: getColor('grey-dark');
564
+ color: getColor('neutral');
562
565
  display: block;
563
566
  font-size: $size-normal;
564
567
  font-weight: $label-weight;
@@ -582,7 +585,7 @@ $label-weight: $weight-bold;
582
585
  font-size: $help-size;
583
586
  margin-top: 2.5px;
584
587
 
585
- @each $name, $pair in $colors-brand-funcionnal {
588
+ @each $name, $pair in $colors-brand-functionnal {
586
589
  $color: getColor($name);
587
590
  $brandName: getColorBrandName($name);
588
591
 
@@ -71,7 +71,7 @@ $size: (
71
71
  max-width: 100%;
72
72
  }
73
73
 
74
- @each $name, $pair in $colors-brand-funcionnal {
74
+ @each $name, $pair in $colors-brand-functionnal {
75
75
  $color: getColor($name);
76
76
  $brandName: getColorBrandName($name);
77
77
 
@@ -85,13 +85,13 @@ $size: (
85
85
  }
86
86
 
87
87
  &.is-circled {
88
- border-radius: 100%;
88
+ border-radius: 9999px;
89
89
  text-align: center;
90
90
  }
91
91
 
92
92
  &.is-stretched {
93
93
  transform: skewX(-#{$icon-stretching-level});
94
- border-top-right-radius: $radius-large;
94
+ border-top-right-radius: 9px;
95
95
  background-color: getColor('font');
96
96
 
97
97
  [class^="tri-"],
@@ -240,7 +240,7 @@ $size: (
240
240
  right: 0;
241
241
  width: $icon-dimensions-default;
242
242
  height: $icon-dimensions-default;
243
- border-radius: 100%;
243
+ border-radius: 9999px;
244
244
  background-color: getColor('main');
245
245
  }
246
246