From 31a72d90ea451dcb018f3fe0f837fb63534a1b1d Mon Sep 17 00:00:00 2001 From: Ilia Mashkov Date: Mon, 2 Feb 2026 12:18:20 +0300 Subject: [PATCH] chore: incorporate renewed appliderFontStore and comparisonStore logic --- .../ui/FontVirtualList/FontVirtualList.svelte | 24 ++++++--- .../ui/FontSampler/FontSampler.svelte | 3 +- .../ComparisonSlider/components/Labels.svelte | 52 ++++++++++++------- 3 files changed, 53 insertions(+), 26 deletions(-) diff --git a/src/entities/Font/ui/FontVirtualList/FontVirtualList.svelte b/src/entities/Font/ui/FontVirtualList/FontVirtualList.svelte index ede09df..b26a909 100644 --- a/src/entities/Font/ui/FontVirtualList/FontVirtualList.svelte +++ b/src/entities/Font/ui/FontVirtualList/FontVirtualList.svelte @@ -3,25 +3,35 @@ - Renders a virtualized list of fonts - Handles font registration with the manager --> - {#snippet fontSelector( name: string, id: string, + url: string, fonts: UnifiedFont[], selectFont: (font: UnifiedFont) => void, align: 'start' | 'end', )} -
e.stopPropagation())}> +
e.stopPropagation())} + >
- + {name}
@@ -80,12 +82,12 @@ function selectFontB(font: UnifiedFont) { 'w-52 max-h-[280px] overflow-hidden rounded-lg', )} side="top" - align={align} + {align} sideOffset={8} size="small" >
- + {#snippet children({ item: font })} {@const handleClick = () => selectFont(font)} - + {font.name} @@ -118,7 +120,14 @@ function selectFontB(font: UnifiedFont) { ch_01
- {@render fontSelector(fontB.name, fontB.id, fontList, selectFontB, 'start')} + {@render fontSelector( + fontB.name, + fontB.id, + fontB.styles.regular!, + fontList, + selectFontB, + 'start', +)}
- {@render fontSelector(fontA.name, fontA.id, fontList, selectFontA, 'end')} + {@render fontSelector( + fontA.name, + fontA.id, + fontA.styles.regular!, + fontList, + selectFontA, + 'end', +)}