mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-14 20:19:34 +01:00
fix(Carousel): use dir from locale (#2647)
This commit is contained in:
@@ -149,8 +149,7 @@ const options = computed<EmblaOptionsType>(() => ({
|
||||
...(props.fade ? { align: 'center', containScroll: false } : {}),
|
||||
...rootProps.value,
|
||||
axis: props.orientation === 'horizontal' ? 'x' : 'y',
|
||||
// TODO: Get from ConfigProvider
|
||||
direction: 'ltr'
|
||||
direction: dir.value === 'rtl' ? 'rtl' : 'ltr'
|
||||
}))
|
||||
|
||||
const plugins = computedAsync<EmblaPluginType[]>(async () => {
|
||||
|
||||
@@ -18,8 +18,8 @@ export default (options: Required<ModuleOptions>) => ({
|
||||
vertical: {
|
||||
container: 'flex-col -mt-4',
|
||||
item: 'pt-4',
|
||||
prev: '-top-12 left-1/2 -translate-x-1/2 rotate-90',
|
||||
next: '-bottom-12 left-1/2 -translate-x-1/2 rotate-90'
|
||||
prev: '-top-12 left-1/2 -translate-x-1/2 rotate-90 rtl:-rotate-90',
|
||||
next: '-bottom-12 left-1/2 -translate-x-1/2 rotate-90 rtl:-rotate-90'
|
||||
},
|
||||
horizontal: {
|
||||
container: 'flex-row -ms-4',
|
||||
|
||||
Reference in New Issue
Block a user