Skip to content

Commit f34d636

Browse files
malik-joudaMalikJouda
authored andcommitted
fix(ChangelogVersion/ChangelogVersions): handle RTL mode (#4777)
Co-authored-by: malik jouda <[email protected]>
1 parent f9e0148 commit f34d636

File tree

7 files changed

+86
-86
lines changed

7 files changed

+86
-86
lines changed

docs/app/components/content/examples/changelog/ChangelogVersionsStickyExample.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ const versions = [{
6262
:badge="undefined"
6363
class="flex items-start"
6464
:ui="{
65-
container: 'max-w-lg mr-0',
65+
container: 'max-w-lg me-0',
6666
indicator: 'sticky top-(--ui-header-height) pt-4 -mt-4 flex flex-col items-end'
6767
}"
6868
>

src/theme/changelog-version.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ export default {
1212
image: 'object-cover object-top w-full h-full',
1313
authors: 'flex flex-wrap gap-x-4 gap-y-1.5',
1414
footer: 'border-t border-default pt-5 flex items-center justify-between',
15-
indicator: 'absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0',
15+
indicator: 'absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0',
1616
dot: 'size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1',
1717
dotInner: 'size-2 rounded-full bg-primary'
1818
},

src/theme/changelog-versions.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ export default {
22
slots: {
33
root: 'relative',
44
container: 'flex flex-col gap-y-8 sm:gap-y-12 lg:gap-y-16',
5-
indicator: 'absolute hidden lg:block overflow-hidden inset-y-3 left-32 h-full w-px bg-border -ml-[8.5px]',
6-
beam: 'absolute left-0 top-0 w-full bg-primary will-change-[height]'
5+
indicator: 'absolute hidden lg:block overflow-hidden inset-y-3 start-32 h-full w-px bg-border -ms-[8.5px]',
6+
beam: 'absolute start-0 top-0 w-full bg-primary will-change-[height]'
77
}
88
}

test/components/__snapshots__/ChangelogVersion-vue.spec.ts.snap

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
exports[`ChangelogVersion > renders with actions slot correctly 1`] = `
44
"<article class="relative">
5-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
5+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
66
<!--v-if-->
77
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
88
<div class="size-2 rounded-full bg-primary"></div>
@@ -19,7 +19,7 @@ exports[`ChangelogVersion > renders with actions slot correctly 1`] = `
1919

2020
exports[`ChangelogVersion > renders with as correctly 1`] = `
2121
"<section class="relative">
22-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
22+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
2323
<!--v-if-->
2424
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
2525
<div class="size-2 rounded-full bg-primary"></div>
@@ -34,7 +34,7 @@ exports[`ChangelogVersion > renders with as correctly 1`] = `
3434

3535
exports[`ChangelogVersion > renders with authors correctly 1`] = `
3636
"<article class="relative">
37-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
37+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
3838
<!--v-if-->
3939
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
4040
<div class="size-2 rounded-full bg-primary"></div>
@@ -59,7 +59,7 @@ exports[`ChangelogVersion > renders with authors correctly 1`] = `
5959
6060
exports[`ChangelogVersion > renders with authors slot correctly 1`] = `
6161
"<article class="relative">
62-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
62+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
6363
<!--v-if-->
6464
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
6565
<div class="size-2 rounded-full bg-primary"></div>
@@ -76,7 +76,7 @@ exports[`ChangelogVersion > renders with authors slot correctly 1`] = `
7676
7777
exports[`ChangelogVersion > renders with badge correctly 1`] = `
7878
"<article class="relative">
79-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
79+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
8080
<!--v-if-->
8181
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
8282
<div class="size-2 rounded-full bg-primary"></div>
@@ -99,7 +99,7 @@ exports[`ChangelogVersion > renders with badge correctly 1`] = `
9999
100100
exports[`ChangelogVersion > renders with badge object correctly 1`] = `
101101
"<article class="relative">
102-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
102+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
103103
<!--v-if-->
104104
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
105105
<div class="size-2 rounded-full bg-primary"></div>
@@ -122,7 +122,7 @@ exports[`ChangelogVersion > renders with badge object correctly 1`] = `
122122
123123
exports[`ChangelogVersion > renders with badge slot correctly 1`] = `
124124
"<article class="relative">
125-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
125+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
126126
<!--v-if-->
127127
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
128128
<div class="size-2 rounded-full bg-primary"></div>
@@ -144,7 +144,7 @@ exports[`ChangelogVersion > renders with badge slot correctly 1`] = `
144144
145145
exports[`ChangelogVersion > renders with body slot correctly 1`] = `
146146
"<article class="relative">
147-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
147+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
148148
<!--v-if-->
149149
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
150150
<div class="size-2 rounded-full bg-primary"></div>
@@ -159,7 +159,7 @@ exports[`ChangelogVersion > renders with body slot correctly 1`] = `
159159
160160
exports[`ChangelogVersion > renders with class correctly 1`] = `
161161
"<article class="absolute">
162-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
162+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
163163
<!--v-if-->
164164
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
165165
<div class="size-2 rounded-full bg-primary"></div>
@@ -174,7 +174,7 @@ exports[`ChangelogVersion > renders with class correctly 1`] = `
174174
175175
exports[`ChangelogVersion > renders with date correctly 1`] = `
176176
"<article class="relative">
177-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0"><time datetime="2025-01-01T00:00:00.000Z" class="text-sm/6 text-toned truncate">Jan 1, 2025</time>
177+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0"><time datetime="2025-01-01T00:00:00.000Z" class="text-sm/6 text-toned truncate">Jan 1, 2025</time>
178178
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
179179
<div class="size-2 rounded-full bg-primary"></div>
180180
</div>
@@ -195,7 +195,7 @@ exports[`ChangelogVersion > renders with date correctly 1`] = `
195195
196196
exports[`ChangelogVersion > renders with date slot correctly 1`] = `
197197
"<article class="relative">
198-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
198+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
199199
<!--v-if-->
200200
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
201201
<div class="size-2 rounded-full bg-primary"></div>
@@ -218,7 +218,7 @@ exports[`ChangelogVersion > renders with date slot correctly 1`] = `
218218
219219
exports[`ChangelogVersion > renders with description correctly 1`] = `
220220
"<article class="relative">
221-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
221+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
222222
<!--v-if-->
223223
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
224224
<div class="size-2 rounded-full bg-primary"></div>
@@ -238,7 +238,7 @@ exports[`ChangelogVersion > renders with description correctly 1`] = `
238238
239239
exports[`ChangelogVersion > renders with description slot correctly 1`] = `
240240
"<article class="relative">
241-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
241+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
242242
<!--v-if-->
243243
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
244244
<div class="size-2 rounded-full bg-primary"></div>
@@ -258,7 +258,7 @@ exports[`ChangelogVersion > renders with description slot correctly 1`] = `
258258
259259
exports[`ChangelogVersion > renders with description slot correctly 2`] = `
260260
"<article class="relative">
261-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
261+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
262262
<!--v-if-->
263263
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
264264
<div class="size-2 rounded-full bg-primary"></div>
@@ -278,7 +278,7 @@ exports[`ChangelogVersion > renders with description slot correctly 2`] = `
278278
279279
exports[`ChangelogVersion > renders with footer slot correctly 1`] = `
280280
"<article class="relative">
281-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
281+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
282282
<!--v-if-->
283283
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
284284
<div class="size-2 rounded-full bg-primary"></div>
@@ -293,7 +293,7 @@ exports[`ChangelogVersion > renders with footer slot correctly 1`] = `
293293
294294
exports[`ChangelogVersion > renders with header slot correctly 1`] = `
295295
"<article class="relative">
296-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
296+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
297297
<!--v-if-->
298298
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
299299
<div class="size-2 rounded-full bg-primary"></div>
@@ -308,7 +308,7 @@ exports[`ChangelogVersion > renders with header slot correctly 1`] = `
308308
309309
exports[`ChangelogVersion > renders with image correctly 1`] = `
310310
"<article class="relative">
311-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
311+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
312312
<!--v-if-->
313313
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
314314
<div class="size-2 rounded-full bg-primary"></div>
@@ -330,7 +330,7 @@ exports[`ChangelogVersion > renders with image correctly 1`] = `
330330
331331
exports[`ChangelogVersion > renders with image slot correctly 1`] = `
332332
"<article class="relative">
333-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
333+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
334334
<!--v-if-->
335335
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
336336
<div class="size-2 rounded-full bg-primary"></div>
@@ -352,7 +352,7 @@ exports[`ChangelogVersion > renders with image slot correctly 1`] = `
352352
353353
exports[`ChangelogVersion > renders with indicator slot correctly 1`] = `
354354
"<article class="relative">
355-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">Indicator slot</div>
355+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">Indicator slot</div>
356356
<div class="flex flex-col mx-auto max-w-2xl">
357357
<!--v-if-->
358358
<!--v-if-->
@@ -362,7 +362,7 @@ exports[`ChangelogVersion > renders with indicator slot correctly 1`] = `
362362
363363
exports[`ChangelogVersion > renders with title correctly 1`] = `
364364
"<article class="relative">
365-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
365+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
366366
<!--v-if-->
367367
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
368368
<div class="size-2 rounded-full bg-primary"></div>
@@ -384,7 +384,7 @@ exports[`ChangelogVersion > renders with title correctly 1`] = `
384384
385385
exports[`ChangelogVersion > renders with title slot correctly 1`] = `
386386
"<article class="relative">
387-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
387+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
388388
<!--v-if-->
389389
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
390390
<div class="size-2 rounded-full bg-primary"></div>
@@ -406,7 +406,7 @@ exports[`ChangelogVersion > renders with title slot correctly 1`] = `
406406
407407
exports[`ChangelogVersion > renders with title slot correctly 2`] = `
408408
"<article class="relative">
409-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
409+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
410410
<!--v-if-->
411411
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
412412
<div class="size-2 rounded-full bg-primary"></div>
@@ -428,7 +428,7 @@ exports[`ChangelogVersion > renders with title slot correctly 2`] = `
428428
429429
exports[`ChangelogVersion > renders with to & image correctly 1`] = `
430430
"<article class="relative">
431-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
431+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
432432
<!--v-if-->
433433
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
434434
<div class="size-2 rounded-full bg-primary"></div>
@@ -448,7 +448,7 @@ exports[`ChangelogVersion > renders with to & image correctly 1`] = `
448448
449449
exports[`ChangelogVersion > renders with to correctly 1`] = `
450450
"<article class="relative">
451-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
451+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
452452
<!--v-if-->
453453
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
454454
<div class="size-2 rounded-full bg-primary"></div>
@@ -463,7 +463,7 @@ exports[`ChangelogVersion > renders with to correctly 1`] = `
463463
464464
exports[`ChangelogVersion > renders with ui correctly 1`] = `
465465
"<article class="relative">
466-
<div class="absolute left-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
466+
<div class="absolute start-0 top-0 w-32 hidden lg:flex items-center justify-end gap-3 min-w-0">
467467
<!--v-if-->
468468
<div class="size-4 rounded-full bg-default ring ring-default flex items-center justify-center my-1">
469469
<div class="size-2 rounded-full bg-primary"></div>

0 commit comments

Comments
 (0)