From 99966d2de9dcd0bf3b2d7fdad057889e14bd31f6 Mon Sep 17 00:00:00 2001 From: Ilia Mashkov Date: Sun, 15 Feb 2026 23:07:23 +0300 Subject: [PATCH] feat(TypographyControls): drasticaly reduce animations, keep only the container functional --- .../components/TypographyControls.svelte | 219 +++--------------- 1 file changed, 36 insertions(+), 183 deletions(-) diff --git a/src/widgets/ComparisonSlider/ui/ComparisonSlider/components/TypographyControls.svelte b/src/widgets/ComparisonSlider/ui/ComparisonSlider/components/TypographyControls.svelte index dcaa6d1..2238bd6 100644 --- a/src/widgets/ComparisonSlider/ui/ComparisonSlider/components/TypographyControls.svelte +++ b/src/widgets/ComparisonSlider/ui/ComparisonSlider/components/TypographyControls.svelte @@ -1,198 +1,51 @@ -{#snippet InputComponent(className: string)} - -{/snippet} + + -{#snippet Controls(className: string, orientation: Orientation)} - {#if typography.weightControl && typography.sizeControl && typography.heightControl} -
- - - -
- {/if} -{/snippet} - -
- {#if staticPosition} -
- {@render InputComponent?.('p-6')} - {@render Controls?.('flex flex-col justify-between items-center-safe gap-6', 'horizontal')} -
- {:else} - - {#snippet badge()} -
- -
- {/snippet} - - {#snippet visibleContent()} - {@render InputComponent(cn( - 'pl-1 sm:pl-3 pr-1 sm:pr-3', - 'h-6 sm:h-8 md:h-10', - 'rounded-lg', - isActive - ? 'h-7 sm:h-8 text-[0.825rem]' - : 'bg-transparent shadow-none border-none p-0 h-auto text-sm sm:text-base font-medium focus-visible:ring-0 text-slate-900/50', -))} - {/snippet} - - {#snippet hiddenContent()} - {@render Controls?.('flex flex-row justify-between items-center-safe gap-2 sm:gap-0 h-64', 'vertical')} - {/snippet} -
- {/if} -
+ +{#if typography.weightControl && typography.sizeControl && typography.heightControl} +
+ + + +
+{/if}