nuxt / ui

A UI Library for Modern Web Apps, powered by Vue & Tailwind CSS.
https://ui.nuxt.com
MIT License
3.79k stars 462 forks source link

Carousel arrows & indicators are broken in RTL #1354

Open MuhammadM1998 opened 7 months ago

MuhammadM1998 commented 7 months ago

Environment

N/A

Version

v2.13.0

Reproduction

https://ui.nuxt.com/components/carousel#arrows

Description

I've created a video repro but my internet is poor it didn't upload šŸ˜…

Additional context

prevButton: {
      color: 'black' as const,
-      class: 'rtl:[&_span:first-child]:rotate-180 absolute left-4 top-1/2 transform -translate-y-1/2 rounded-full',
+      class: 'rtl:[&_span:first-child]:rotate-180 absolute ltr:left-4 rtl:right-4 top-1/2 transform -translate-y-1/2 rounded-full',
      icon: 'i-heroicons-chevron-left-20-solid'
},
nextButton: {
      color: 'black' as const,
-     class: 'rtl:[&_span:last-child]:rotate-180 absolute right-4 top-1/2 transform -translate-y-1/2 rounded-full',
+     class: 'rtl:[&_span:last-child]:rotate-180 absolute ltr:right-4 rtl:left-4 top-1/2 transform -translate-y-1/2 rounded-full',
      icon: 'i-heroicons-chevron-right-20-solid '
}

function onClickPrev () {

function onClick (page: number) {

Logs

No response

benjamincanac commented 7 months ago

Would you mind submitting a PR so I can see the preview?

MuhammadM1998 commented 7 months ago

Sure no problem

beingmomen commented 3 weeks ago

I have the same issue