From 8737d6cb3391fca261e664e7c78c581a41f938d0 Mon Sep 17 00:00:00 2001 From: Cory LaViska Date: Mon, 28 Oct 2024 11:39:16 -0400 Subject: [PATCH] fix directionality check (#2235) --- docs/pages/resources/changelog.md | 1 + src/components/carousel/carousel.component.ts | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/pages/resources/changelog.md b/docs/pages/resources/changelog.md index a5f25444b..59251fa62 100644 --- a/docs/pages/resources/changelog.md +++ b/docs/pages/resources/changelog.md @@ -15,6 +15,7 @@ New versions of Shoelace are released as-needed and generally occur when a criti ## Next - Added support for Enter to `` to align with ARIA APG's [window splitter pattern](https://www.w3.org/WAI/ARIA/apg/patterns/windowsplitter/) [#2234] +- Fixed a bug in `` that caused the navigation icons to be reversed ## 2.18.0 diff --git a/src/components/carousel/carousel.component.ts b/src/components/carousel/carousel.component.ts index 6237888c4..40234ae30 100644 --- a/src/components/carousel/carousel.component.ts +++ b/src/components/carousel/carousel.component.ts @@ -512,7 +512,7 @@ export default class SlCarousel extends ShoelaceElement { const currentPage = this.getCurrentPage(); const prevEnabled = this.canScrollPrev(); const nextEnabled = this.canScrollNext(); - const isLtr = this.localize.dir() === 'rtl'; + const isLtr = this.localize.dir() === 'ltr'; return html`