This commit is contained in:
Timothy Jaeryang Baek committed 2026-10-31 18:23:26 +09:00
1 parent 64796faceb
commit a3e261d4cb
5 files changed
+143 -134

No files matched your search

@@ -245,7 +245,7 @@
{#each knowledgeResults as item, idx}
{@const itemIdx = idx}
{#if idx === 0 || item?.type !== knowledgeResults[idx - 1]?.type}
<div class="px-2 py-1 text-[0.6875rem] text-gray-500 dark:text-gray-400">
<div class="app-muted mb-0.5 px-2 pt-1 pb-0.5 text-[0.625rem] leading-none">
{#if item?.type === 'folder'}
{$i18n.t('Folders')}
{:else if item?.type === 'collection'}
@@ -259,9 +259,9 @@
{/if}
<button
class="flex h-[1.6875rem] w-full max-w-full items-center justify-between overflow-hidden rounded-xl px-2 text-left text-[0.8125rem] hover:bg-gray-50/40 dark:hover:bg-gray-800/40 {itemIdx ===
class="flex h-6 w-full max-w-full items-center justify-between overflow-hidden rounded-xl px-2 text-left text-xs transition-colors duration-75 hover:bg-gray-50/40 dark:hover:bg-gray-800/40 {itemIdx ===
selectedIdx
? 'bg-gray-50/40 dark:bg-gray-800/40 dark:text-gray-100 selected-command-option-button'
? 'app-interactive-active selected-command-option-button'
: ''}"
type="button"
on:click={() => {
@@ -272,11 +272,9 @@
}}
data-selected={itemIdx === selectedIdx}
>
<div
class="flex w-full min-w-0 items-center gap-1.5 overflow-hidden text-black dark:text-gray-100"
>
<div class="flex w-full min-w-0 items-center gap-2 overflow-hidden">
<Tooltip
className="shrink-0 flex"
className="app-icon-muted flex w-4 shrink-0 items-center justify-center"
content={item?.legacy
? $i18n.t('Legacy')
: item?.type === 'filesystem'
@@ -320,7 +318,7 @@
{/if}
{#if filteredModels.length > 0}
<div class="px-2 py-1 text-[0.6875rem] text-gray-500 dark:text-gray-400">
<div class="app-muted mb-0.5 px-2 pt-1 pb-0.5 text-[0.625rem] leading-none">
{$i18n.t('Models')}
</div>
@@ -328,9 +326,9 @@
{@const itemIdx = knowledgeResults.length + modelIdx}
<Tooltip content={model.id} placement="top-start">
<button
class="flex h-[1.6875rem] w-full items-center rounded-xl px-2 text-left text-[0.8125rem] hover:bg-gray-50/40 dark:hover:bg-gray-800/40 {itemIdx ===
class="flex h-6 w-full items-center rounded-xl px-2 text-left text-xs transition-colors duration-75 hover:bg-gray-50/40 dark:hover:bg-gray-800/40 {itemIdx ===
selectedIdx
? 'bg-gray-50/40 dark:bg-gray-800/40 selected-command-option-button'
? 'app-interactive-active selected-command-option-button'
: ''}"
type="button"
on:click={() => {
@@ -342,11 +340,11 @@
on:focus={() => {}}
data-selected={itemIdx === selectedIdx}
>
<div class="flex min-w-0 items-center text-black dark:text-gray-100">
<div class="flex min-w-0 items-center gap-2">
<img
src={`${WEBUI_API_BASE_URL}/models/model/profile/image?id=${model.id}&lang=${$i18n.language}`}
alt={resolveLocalizedModelName(model, $i18n.language) ?? model.id}
class="mr-2 size-4.5 rounded-full object-cover"
class="size-4 shrink-0 rounded-full object-cover"
on:error={(e) => {
// LICENSE covers this Open WebUI fallback logo.
// Do not alter, remove, obscure, or replace it except as LICENSE permits:
@@ -143,7 +143,7 @@
{#if filteredItems.length > 0 || query.startsWith('http')}
{#each filteredItems as item, idx}
{#if idx === 0 || item?.type !== items[idx - 1]?.type}
<div class="px-2 py-1 text-[0.6875rem] text-gray-500 dark:text-gray-400">
<div class="app-muted mb-0.5 px-2 pt-1 pb-0.5 text-[0.625rem] leading-none">
{#if item?.type === 'folder'}
{$i18n.t('Folders')}
{:else if item?.type === 'collection'}
@@ -156,9 +156,9 @@
{#if !['youtube', 'web'].includes(item.type)}
<button
class="flex h-[1.6875rem] w-full items-center justify-between rounded-xl px-2 text-left text-[0.8125rem] hover:bg-gray-50/40 dark:hover:bg-gray-800/40 {idx ===
class="flex h-6 w-full items-center justify-between rounded-xl px-2 text-left text-xs transition-colors duration-75 hover:bg-gray-50/40 dark:hover:bg-gray-800/40 {idx ===
selectedIdx
? 'bg-gray-50/40 dark:bg-gray-800/40 dark:text-gray-100 selected-command-option-button'
? 'app-interactive-active selected-command-option-button'
: ''}"
type="button"
on:click={() => {
@@ -173,8 +173,9 @@
}}
data-selected={idx === selectedIdx}
>
<div class="flex min-w-0 items-center gap-1.5 text-black dark:text-gray-100">
<div class="flex w-full min-w-0 items-center gap-2">
<Tooltip
className="app-icon-muted flex w-4 shrink-0 items-center justify-center"
content={item?.legacy
? $i18n.t('Legacy')
: item?.type === 'file'
@@ -193,7 +194,11 @@
{/if}
</Tooltip>
<Tooltip content={`${decodeString(item?.name)}`} placement="top-start">
<Tooltip
className="min-w-0 flex-1"
content={`${decodeString(item?.name)}`}
placement="top-start"
>
<div class="min-w-0 flex-1 truncate">
{decodeString(item?.name)}
</div>
@@ -205,7 +210,7 @@
{#if webUploadEnabled && isYoutubeUrl(query)}
<button
class="flex h-[1.6875rem] w-full items-center rounded-xl bg-gray-50/40 px-2 text-left text-[0.8125rem] dark:bg-gray-800/40 dark:text-gray-100 selected-command-option-button"
class="flex h-6 w-full items-center rounded-xl app-interactive-active px-2 text-left text-xs transition-colors duration-75 selected-command-option-button"
type="button"
data-selected={selectedIdx === filteredItems.findIndex((i) => i.type === 'youtube')}
on:click={() => {
@@ -221,8 +226,12 @@
}
}}
>
<div class="flex min-w-0 items-center gap-1.5 text-black dark:text-gray-100">
<Tooltip content={$i18n.t('YouTube')} placement="top">
<div class="flex w-full min-w-0 items-center gap-2">
<Tooltip
className="app-icon-muted flex w-4 shrink-0 items-center justify-center"
content={$i18n.t('YouTube')}
placement="top"
>
<Youtube className="size-3.5" />
</Tooltip>
@@ -233,7 +242,7 @@
</button>
{:else if webUploadEnabled && query.startsWith('http')}
<button
class="flex h-[1.6875rem] w-full items-center rounded-xl bg-gray-50/40 px-2 text-left text-[0.8125rem] dark:bg-gray-800/40 dark:text-gray-100 selected-command-option-button"
class="flex h-6 w-full items-center rounded-xl app-interactive-active px-2 text-left text-xs transition-colors duration-75 selected-command-option-button"
type="button"
data-selected={selectedIdx === filteredItems.findIndex((i) => i.type === 'web')}
on:click={() => {
@@ -249,8 +258,12 @@
}
}}
>
<div class="flex min-w-0 items-center gap-1.5 text-black dark:text-gray-100">
<Tooltip content={$i18n.t('Web')} placement="top">
<div class="flex w-full min-w-0 items-center gap-2">
<Tooltip
className="app-icon-muted flex w-4 shrink-0 items-center justify-center"
content={$i18n.t('Web')}
placement="top"
>
<GlobeAlt className="size-3.5" />
</Tooltip>
@@ -100,7 +100,7 @@
};
</script>
<div class="px-2 py-1 text-[0.6875rem] text-gray-500 dark:text-gray-400">
<div class="app-muted mb-0.5 px-2 pt-1 pb-0.5 text-[0.625rem] leading-none">
{$i18n.t('Skills')}
</div>
@@ -113,9 +113,9 @@
tippyOptions={{ maxWidth: '20rem' }}
>
<button
class="flex h-[1.6875rem] w-full items-center rounded-xl px-2 text-left text-[0.8125rem] hover:bg-gray-50/40 dark:hover:bg-gray-800/40 {skillIdx ===
class="flex h-6 w-full items-center rounded-xl px-2 text-left text-xs transition-colors duration-75 hover:bg-gray-50/40 dark:hover:bg-gray-800/40 {skillIdx ===
selectedIdx
? 'bg-gray-50/40 dark:bg-gray-800/40 selected-command-option-button'
? 'app-interactive-active selected-command-option-button'
: ''}"
type="button"
on:click={() => {
@@ -127,14 +127,14 @@
on:focus={() => {}}
data-selected={skillIdx === selectedIdx}
>
<div class="flex w-full min-w-0 items-center text-black dark:text-gray-100">
<div class="mr-2 flex size-4.5 shrink-0 items-center justify-center">
<div class="flex w-full min-w-0 items-center gap-2">
<div class="app-icon-muted flex w-4 shrink-0 items-center justify-center">
<Cube className="size-3.5" />
</div>
<div class="truncate min-w-0 flex-1">
{resolveLocalizedResource(skill, $i18n.language)}
</div>
<div class="ml-2 max-w-24 shrink-0 truncate text-xs text-gray-500 dark:text-gray-400">
<div class="app-muted max-w-24 shrink-0 truncate text-[0.625rem]">
{skill.source === 'terminal' ? $i18n.t('Terminal') : skill.id}
</div>
</div>