mirror of
https://github.com/open-webui/open-webui.git
synced 2026-09-07 08:27:05 +00:00
refac
This commit is contained in:
parent
b356b80f8c
commit
e4694f82eb
2 changed files with 25 additions and 21 deletions
|
|
@ -466,7 +466,7 @@
|
|||
});
|
||||
</script>
|
||||
|
||||
<div class="relative {className}">
|
||||
<div class="relative {className}">
|
||||
{#if loading}
|
||||
<div class="absolute inset-0 flex items-center justify-center">
|
||||
<Spinner className="size-5" />
|
||||
|
|
@ -477,17 +477,19 @@
|
|||
</div>
|
||||
{/if}
|
||||
|
||||
<div
|
||||
class={singlePage
|
||||
? 'overflow-hidden h-full flex items-center justify-center overscroll-contain'
|
||||
: 'overflow-y-auto h-full'}
|
||||
bind:this={outerContainer}
|
||||
tabindex="0"
|
||||
on:scroll={handleScroll}
|
||||
on:wheel|nonpassive={handleWheel}
|
||||
on:pointerdown={focusViewer}
|
||||
on:keydown={handleKeyDown}
|
||||
>
|
||||
<div
|
||||
class={singlePage
|
||||
? 'overflow-hidden h-full flex items-center justify-center overscroll-contain'
|
||||
: 'overflow-y-auto h-full'}
|
||||
bind:this={outerContainer}
|
||||
role="region"
|
||||
aria-label={`${itemLabel} viewer`}
|
||||
tabindex="0"
|
||||
on:scroll={handleScroll}
|
||||
on:wheel|nonpassive={handleWheel}
|
||||
on:pointerdown={focusViewer}
|
||||
on:keydown={handleKeyDown}
|
||||
>
|
||||
<div bind:this={sceneElement} class={singlePage ? '' : 'w-full'}></div>
|
||||
</div>
|
||||
|
||||
|
|
|
|||
|
|
@ -231,15 +231,17 @@
|
|||
});
|
||||
</script>
|
||||
|
||||
<div
|
||||
bind:this={rootEl}
|
||||
tabindex="0"
|
||||
on:keydown={handleKeyDown}
|
||||
on:pointerdown={focusPreview}
|
||||
class="relative grid {hideThumbs
|
||||
? 'grid-cols-[minmax(0,1fr)]'
|
||||
: 'grid-cols-[144px_minmax(0,1fr)]'} min-h-0 bg-transparent text-gray-900 dark:text-gray-100 {className}"
|
||||
>
|
||||
<div
|
||||
bind:this={rootEl}
|
||||
role="region"
|
||||
aria-label={`${itemLabel} preview`}
|
||||
tabindex="0"
|
||||
on:keydown={handleKeyDown}
|
||||
on:pointerdown={focusPreview}
|
||||
class="relative grid {hideThumbs
|
||||
? 'grid-cols-[minmax(0,1fr)]'
|
||||
: 'grid-cols-[144px_minmax(0,1fr)]'} min-h-0 bg-transparent text-gray-900 dark:text-gray-100 {className}"
|
||||
>
|
||||
<aside
|
||||
class={hideThumbs
|
||||
? 'hidden'
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue