ublo-lib 1.47.89 → 1.47.90

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.
@@ -1,36 +1,27 @@
1
1
  .carousel {
2
- --carousel-width: var(--content-width);
3
- --carousel-wheel-height: calc(var(--carousel-item-height) + 150px);
4
- --carousel-scale-height: calc(var(--carousel-item-height) + 100px);
5
- --carousel-padding-top: 60px;
6
- --carousel-button-width: 48px;
7
- --carousel-button-background: hsl(0, 0%, 100%);
8
- --carousel-button-hover-background: hsl(0, 0%, 100%);
9
- --carousel-left-button-glow: transparent;
10
- --carousel-right-button-glow: transparent;
11
- --carousel-button-radius: 50%;
12
- --carousel-button-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
13
- --carousel-button-icon-size: 16px;
14
- --carousel-button-icon-color: #081527;
15
- --carousel-before-background: transparent;
16
- --carousel-after-background: transparent;
17
-
2
+ /* Variables avec valeurs par défaut (fallback) */
18
3
  position: relative;
19
4
  display: flex;
20
5
  justify-content: center;
21
6
  /* 2px viennent des pseudo-elements after des boutons de control */
22
7
  width: calc(100vw - var(--scrollbar-size) - 2px);
23
- max-width: var(--carousel-width);
8
+ max-width: var(--carousel-width, var(--content-width));
24
9
  margin: 0 auto;
25
- padding-top: var(--carousel-padding-top);
10
+ padding-top: var(--carousel-padding-top, 60px);
26
11
  }
27
12
 
28
13
  .carousel--wheel {
29
- --carousel-height: var(--carousel-wheel-height);
14
+ --carousel-height: var(
15
+ --carousel-wheel-height,
16
+ calc(var(--carousel-item-height, 300px) + 150px)
17
+ );
30
18
  }
31
19
 
32
20
  .carousel--scale {
33
- --carousel-height: var(--carousel-scale-height);
21
+ --carousel-height: var(
22
+ --carousel-scale-height,
23
+ calc(var(--carousel-item-height, 300px) + 100px)
24
+ );
34
25
  }
35
26
 
36
27
  /* ----- FALLBACK : Cas où il n'y a pas de logique de carousel ----- */
@@ -46,7 +37,7 @@
46
37
 
47
38
  .controls {
48
39
  position: absolute;
49
- top: var(--carousel-item-height);
40
+ top: var(--carousel-item-height, 300px);
50
41
  left: 0;
51
42
  width: 100%;
52
43
  margin: 0 auto;
@@ -59,25 +50,34 @@
59
50
 
60
51
  .carousel--wheel .controls {
61
52
  /* boutons au milieu de l'item central (item height / 2 - paddingtop carousel) */
62
- top: calc((var(--carousel-item-height) + var(--carousel-padding-top)) / 2);
53
+ top: calc(
54
+ (var(--carousel-item-height, 300px) + var(--carousel-padding-top, 60px)) / 2
55
+ );
63
56
  left: auto;
64
57
  /* largeur de la taille de l'item + des boutons + petit écart */
65
58
  width: calc(
66
- var(--carousel-item-width) + (var(--carousel-button-width) * 2) + 20px
59
+ var(--carousel-item-width, 400px) + (var(--carousel-button-width, 48px) * 2) +
60
+ 20px
67
61
  );
68
62
  transform: none;
69
63
  }
70
64
 
71
65
  .control {
72
- --ds-button-background: var(--carousel-button-background);
73
- --ds-button-hover-background: var(--carousel-button-hover-background);
74
- --ds-button-radius: var(--carousel-button-radius);
66
+ --ds-button-background: var(--carousel-button-background, hsl(0, 0%, 100%));
67
+ --ds-button-hover-background: var(
68
+ --carousel-button-hover-background,
69
+ hsl(0, 0%, 100%)
70
+ );
71
+ --ds-button-radius: var(--carousel-button-radius, 50%);
75
72
  --ds-button-border: var(--carousel-button-border);
76
- --ds-button-shadow: var(--carousel-button-shadow);
73
+ --ds-button-shadow: var(
74
+ --carousel-button-shadow,
75
+ 0 2px 8px rgba(0, 0, 0, 0.15)
76
+ );
77
77
 
78
78
  pointer-events: auto;
79
- width: var(--carousel-button-width);
80
- height: var(--carousel-button-width);
79
+ width: var(--carousel-button-width, 48px);
80
+ height: var(--carousel-button-width, 48px);
81
81
  display: flex;
82
82
  align-items: center;
83
83
  justify-content: center;
@@ -91,22 +91,22 @@
91
91
  left: -1px;
92
92
  height: 100%;
93
93
  width: 100%;
94
- background-image: var(--carousel-left-button-glow);
95
- border-radius: var(--carousel-button-radius);
94
+ background-image: var(--carousel-left-button-glow, transparent);
95
+ border-radius: var(--carousel-button-radius, 50%);
96
96
  z-index: -1;
97
97
  }
98
98
 
99
99
  .control + .control::after {
100
100
  left: auto;
101
101
  right: -1px;
102
- background-image: var(--carousel-right-button-glow);
102
+ background-image: var(--carousel-right-button-glow, transparent);
103
103
  z-index: -1;
104
104
  }
105
105
 
106
106
  .controlIcon {
107
- --size: var(--carousel-button-icon-size);
107
+ --size: var(--carousel-button-icon-size, 16px);
108
108
 
109
- fill: var(--carousel-button-icon-color);
109
+ fill: var(--carousel-button-icon-color, #081527);
110
110
  }
111
111
 
112
112
  .viewport {
@@ -123,8 +123,8 @@
123
123
  top: 0;
124
124
  left: 0;
125
125
  height: 100%;
126
- width: var(--carousel-item-width);
127
- background: var(--carousel-before-background);
126
+ width: var(--carousel-item-width, 400px);
127
+ background: var(--carousel-before-background, transparent);
128
128
  z-index: 1;
129
129
  }
130
130
 
@@ -134,8 +134,8 @@
134
134
  top: 0;
135
135
  right: 0;
136
136
  height: 100%;
137
- width: var(--carousel-item-width);
138
- background: var(--carousel-after-background);
137
+ width: var(--carousel-item-width, 400px);
138
+ background: var(--carousel-after-background, transparent);
139
139
  z-index: 1;
140
140
  }
141
141
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ublo-lib",
3
- "version": "1.47.89",
3
+ "version": "1.47.90",
4
4
  "peerDependencies": {
5
5
  "classnames": "^2.5.1",
6
6
  "dt-design-system": "^3.12.0",