@entur/expand 3.7.10 → 4.0.0-next.0
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.
- package/dist/Accordion.d.ts +7 -2
- package/dist/AccordionItem.d.ts +24 -3
- package/dist/BaseExpand.d.ts +6 -5
- package/dist/BaseExpandablePanel.d.ts +6 -5
- package/dist/ExpandArrow.d.ts +1 -2
- package/dist/ExpandablePanel.d.ts +31 -3
- package/dist/ExpandableText.d.ts +33 -4
- package/dist/ExpandableTextButton.d.ts +2 -2
- package/dist/expand.cjs.js +264 -150
- package/dist/expand.cjs.js.map +1 -1
- package/dist/expand.esm.js +266 -152
- package/dist/expand.esm.js.map +1 -1
- package/dist/styles.css +38 -27
- package/package.json +10 -12
package/dist/styles.css
CHANGED
|
@@ -178,7 +178,7 @@
|
|
|
178
178
|
}
|
|
179
179
|
|
|
180
180
|
@media (prefers-reduced-motion){
|
|
181
|
-
.
|
|
181
|
+
.eds-base-expand{
|
|
182
182
|
-webkit-transition:none !important;
|
|
183
183
|
-o-transition:none !important;
|
|
184
184
|
-moz-transition:none !important;
|
|
@@ -190,11 +190,21 @@
|
|
|
190
190
|
-moz-transition:none !important;
|
|
191
191
|
transition:none !important;
|
|
192
192
|
}
|
|
193
|
-
}.
|
|
194
|
-
|
|
195
|
-
-
|
|
196
|
-
-
|
|
197
|
-
transition:
|
|
193
|
+
}.eds-base-expand{
|
|
194
|
+
display:grid;
|
|
195
|
+
grid-template-rows:0fr;
|
|
196
|
+
-webkit-transition:grid-template-rows 0.2s ease-out;
|
|
197
|
+
-o-transition:grid-template-rows 0.2s ease-out;
|
|
198
|
+
-moz-transition:grid-template-rows 0.2s ease-out;
|
|
199
|
+
transition:grid-template-rows 0.2s ease-out;
|
|
200
|
+
transition:grid-template-rows 0.2s ease-out, -ms-grid-rows 0.2s ease-out;
|
|
201
|
+
}
|
|
202
|
+
.eds-base-expand--open{
|
|
203
|
+
grid-template-rows:1fr;
|
|
204
|
+
}
|
|
205
|
+
.eds-base-expand__inner{
|
|
206
|
+
overflow:hidden;
|
|
207
|
+
min-height:0;
|
|
198
208
|
}.eds-expandable-arrow{
|
|
199
209
|
color:var(--components-expand-expandablepanel-standard-icon);
|
|
200
210
|
-webkit-transition:0.2s -webkit-transform ease-out;
|
|
@@ -210,12 +220,12 @@
|
|
|
210
220
|
-o-transform:rotate(-180deg);
|
|
211
221
|
transform:rotate(-180deg);
|
|
212
222
|
}
|
|
213
|
-
.eds-contrast .eds-expandable-arrow{
|
|
223
|
+
:where(.eds-contrast) .eds-expandable-arrow{
|
|
214
224
|
color:var(--components-expand-expandablepanel-contrast-icon);
|
|
215
225
|
}
|
|
216
226
|
|
|
217
|
-
.eds-expandable-text--disable-animation .eds-expandable-arrow,
|
|
218
|
-
.eds-expandable-panel--disable-animation .eds-expandable-arrow{
|
|
227
|
+
.eds-expandable-text--disable-animation :where(.eds-expandable-arrow),
|
|
228
|
+
.eds-expandable-panel--disable-animation :where(.eds-expandable-arrow){
|
|
219
229
|
-webkit-transition:none;
|
|
220
230
|
-o-transition:none;
|
|
221
231
|
-moz-transition:none;
|
|
@@ -224,10 +234,10 @@
|
|
|
224
234
|
width:100%;
|
|
225
235
|
position:relative;
|
|
226
236
|
}
|
|
227
|
-
.eds-expandable-panel + .eds-expandable-panel{
|
|
237
|
+
.eds-expandable-panel + :where(.eds-expandable-panel){
|
|
228
238
|
margin-top:0.125rem;
|
|
229
239
|
}
|
|
230
|
-
.eds-expandable-panel:focus,
|
|
240
|
+
.eds-expandable-panel:where(:focus, :focus-within){
|
|
231
241
|
z-index:2;
|
|
232
242
|
}
|
|
233
243
|
.eds-expandable-panel__grid{
|
|
@@ -257,22 +267,22 @@
|
|
|
257
267
|
width:100%;
|
|
258
268
|
word-break:break-word;
|
|
259
269
|
}
|
|
260
|
-
.eds-contrast .eds-expandable-panel__trigger{
|
|
270
|
+
:where(.eds-contrast) .eds-expandable-panel__trigger{
|
|
261
271
|
background:var(--components-expand-expandablepanel-contrast-fill-default);
|
|
262
272
|
color:var(--components-expand-expandablepanel-contrast-text);
|
|
263
273
|
}
|
|
264
|
-
.eds-expandable-panel__trigger:hover{
|
|
274
|
+
.eds-expandable-panel__trigger:where(:hover){
|
|
265
275
|
background:var(--components-expand-expandablepanel-standard-fill-hover);
|
|
266
276
|
}
|
|
267
|
-
.eds-contrast .eds-expandable-panel__trigger:hover{
|
|
277
|
+
:where(.eds-contrast) .eds-expandable-panel__trigger:where(:hover){
|
|
268
278
|
background:var(--components-expand-expandablepanel-contrast-fill-hover);
|
|
269
279
|
}
|
|
270
|
-
.eds-expandable-panel__trigger:focus-visible{
|
|
280
|
+
.eds-expandable-panel__trigger:where(:focus-visible){
|
|
271
281
|
outline:2px solid #181c56;
|
|
272
282
|
outline-color:var(--basecolors-stroke-focus-standard);
|
|
273
283
|
outline-offset:0.125rem;
|
|
274
284
|
}
|
|
275
|
-
.eds-contrast .eds-expandable-panel__trigger:focus-visible{
|
|
285
|
+
:where(.eds-contrast) .eds-expandable-panel__trigger:where(:focus-visible){
|
|
276
286
|
outline-color:var(--basecolors-stroke-focus-contrast);
|
|
277
287
|
}
|
|
278
288
|
.eds-expandable-panel__icon-container{
|
|
@@ -293,13 +303,7 @@
|
|
|
293
303
|
overflow:auto;
|
|
294
304
|
padding:1rem 1rem 1rem 1.5rem;
|
|
295
305
|
}
|
|
296
|
-
.eds-expandable-panel .
|
|
297
|
-
-webkit-transition:height 0.5s ease-out;
|
|
298
|
-
-o-transition:height 0.5s ease-out;
|
|
299
|
-
-moz-transition:height 0.5s ease-out;
|
|
300
|
-
transition:height 0.5s ease-out;
|
|
301
|
-
}
|
|
302
|
-
.eds-expandable-panel--disable-animation .ReactCollapse--collapse{
|
|
306
|
+
.eds-expandable-panel--disable-animation :where(.eds-base-expand){
|
|
303
307
|
-webkit-transition:none;
|
|
304
308
|
-o-transition:none;
|
|
305
309
|
-moz-transition:none;
|
|
@@ -325,18 +329,25 @@
|
|
|
325
329
|
-moz-box-align:center;
|
|
326
330
|
align-items:center;
|
|
327
331
|
}
|
|
328
|
-
.eds-contrast .eds-expandable-text__trigger{
|
|
332
|
+
:where(.eds-contrast) .eds-expandable-text__trigger{
|
|
329
333
|
color:var(--components-expand-expandabletext-contrast-text);
|
|
330
334
|
}
|
|
331
|
-
.eds-expandable-text__trigger > h5,
|
|
335
|
+
.eds-expandable-text__trigger > :where(h5, h4, h3, h2, p){
|
|
332
336
|
margin-top:0;
|
|
333
337
|
margin-bottom:0;
|
|
334
338
|
}
|
|
335
|
-
.eds-expandable-text__trigger:focus-visible{
|
|
339
|
+
.eds-expandable-text__trigger:where(:focus-visible){
|
|
336
340
|
outline:2px solid #181c56;
|
|
337
341
|
outline-color:var(--basecolors-stroke-focus-standard);
|
|
338
342
|
outline-offset:0.125rem;
|
|
339
343
|
}
|
|
340
|
-
.eds-contrast .eds-expandable-text__trigger:focus-visible{
|
|
344
|
+
:where(.eds-contrast) .eds-expandable-text__trigger:where(:focus-visible){
|
|
341
345
|
outline-color:var(--basecolors-stroke-focus-contrast);
|
|
346
|
+
}
|
|
347
|
+
|
|
348
|
+
.eds-expandable-text--disable-animation :where(.eds-base-expand){
|
|
349
|
+
-webkit-transition:none;
|
|
350
|
+
-o-transition:none;
|
|
351
|
+
-moz-transition:none;
|
|
352
|
+
transition:none;
|
|
342
353
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@entur/expand",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "4.0.0-next.0",
|
|
4
4
|
"license": "EUPL-1.2",
|
|
5
5
|
"main": "dist/expand.cjs.js",
|
|
6
6
|
"module": "dist/expand.esm.js",
|
|
@@ -22,22 +22,20 @@
|
|
|
22
22
|
"test": "jest"
|
|
23
23
|
},
|
|
24
24
|
"peerDependencies": {
|
|
25
|
-
"react": ">=
|
|
26
|
-
"react-dom": ">=
|
|
25
|
+
"react": ">=18.0.0",
|
|
26
|
+
"react-dom": ">=18.0.0"
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@entur/icons": "^
|
|
30
|
-
"@entur/tokens": "^3.
|
|
31
|
-
"@entur/typography": "^
|
|
32
|
-
"@entur/utils": "^0.
|
|
33
|
-
"classnames": "^2.5.1"
|
|
34
|
-
"react-collapse": "^5.1.1"
|
|
29
|
+
"@entur/icons": "^10.0.0-next.0",
|
|
30
|
+
"@entur/tokens": "^3.24.1-next.0",
|
|
31
|
+
"@entur/typography": "^3.0.0-next.0",
|
|
32
|
+
"@entur/utils": "^1.0.0-next.0",
|
|
33
|
+
"classnames": "^2.5.1"
|
|
35
34
|
},
|
|
36
35
|
"devDependencies": {
|
|
37
36
|
"@testing-library/jest-dom": "^5.17.0",
|
|
38
|
-
"@testing-library/react": "^
|
|
37
|
+
"@testing-library/react": "^16.3.0",
|
|
39
38
|
"@testing-library/user-event": "14.6.1",
|
|
40
|
-
"@types/react-collapse": "5.0.4",
|
|
41
39
|
"@vitejs/plugin-react": "^5.0.1",
|
|
42
40
|
"jest": "^29.0.0",
|
|
43
41
|
"jest-environment-jsdom": "^29.0.0",
|
|
@@ -46,5 +44,5 @@
|
|
|
46
44
|
"vite": "^7.3.2",
|
|
47
45
|
"vite-plugin-dts": "^4.5.4"
|
|
48
46
|
},
|
|
49
|
-
"gitHead": "
|
|
47
|
+
"gitHead": "0f435bdeec98cc3cea1db7434b13b1f771a39a18"
|
|
50
48
|
}
|