From a6baae0cf179df5c3b1d64cadfb0b57badcb4156 Mon Sep 17 00:00:00 2001 From: dev Date: Sat, 23 May 2026 22:07:16 +0200 Subject: [PATCH] fix(carousel/range-calendar/time-range-field): apply canonical i18n + vertical layout patterns MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## Vertical carousel layout Recipe was making the indicator group stretch full width (380px) because the root stayed in `flex-direction: column` and the indicator-group inherited `align-items: stretch`. Reshaped: - `[data-carousel][data-orientation='vertical']` now flips the root to `flex-direction: row` so viewport and indicator-group sit side-by-side. - Viewport takes `flex: 1 1 auto` of the inline axis with explicit 100% block-size. - Indicator-group becomes `flex: 0 0 auto; inline-size: max-content; align-self: center` — narrow column of dots on the right edge. Active vertical-stretched indicator already had `block-size: 2.25×` treatment from the prior commit, so it now appears as a vertical pill inside the dot column. ## i18n controls: follow canonical pattern Mirrored the date-range-picker / calendar demos verbatim — those are the canon and the new demos drifted from them. Three corrections: 1. **Locale**: ` + + + + diff --git a/web/routes/uix/components/range-calendar/+page.svelte b/web/routes/uix/components/range-calendar/+page.svelte index 1dd0c4995..b931e2b90 100644 --- a/web/routes/uix/components/range-calendar/+page.svelte +++ b/web/routes/uix/components/range-calendar/+page.svelte @@ -55,12 +55,8 @@ let readonly = $state(false); let weekStartsOn = $state('1'); let locale = $state('en-US'); - // `dir` reflows the calendar header + weekday strip + day grid. `auto` - // inherits the app preference set in the topbar; explicit `ltr`/`rtl` - // overrides it per-instance. - type DirCtl = 'auto' | 'ltr' | 'rtl'; - let dirCtl = $state('auto'); - const dir = $derived(dirCtl === 'auto' ? undefined : dirCtl); + type Direction = 'ltr' | 'rtl'; + let dir = $state('ltr'); let size = $state('md'); let variant = $state('surface'); let color = $state('primary'); @@ -464,22 +460,22 @@ -