forked from open-webui/open-webui
refac: styling
This commit is contained in:
parent
6318282873
commit
bf2ff47df0
3 changed files with 59 additions and 61 deletions
|
@ -389,7 +389,7 @@
|
||||||
</div>
|
</div>
|
||||||
{/if}
|
{/if}
|
||||||
|
|
||||||
<div class="w-full">
|
<div class="w-full absolute bottom-0">
|
||||||
<div class="px-2.5 -mb-0.5 mx-auto inset-x-0 bg-transparent flex justify-center">
|
<div class="px-2.5 -mb-0.5 mx-auto inset-x-0 bg-transparent flex justify-center">
|
||||||
<div class="flex flex-col max-w-3xl w-full">
|
<div class="flex flex-col max-w-3xl w-full">
|
||||||
<div class="relative">
|
<div class="relative">
|
||||||
|
|
|
@ -277,7 +277,7 @@
|
||||||
// };
|
// };
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<div class="h-full">
|
<div class="h-full flex">
|
||||||
{#if messages.length == 0}
|
{#if messages.length == 0}
|
||||||
<Placeholder
|
<Placeholder
|
||||||
models={selectedModels}
|
models={selectedModels}
|
||||||
|
@ -297,7 +297,7 @@
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
{:else}
|
{:else}
|
||||||
<div class="pt-2 pb-10">
|
<div class="pt-2 pb-28">
|
||||||
{#key chatId}
|
{#key chatId}
|
||||||
{#each messages as message, messageIdx}
|
{#each messages as message, messageIdx}
|
||||||
<div class=" w-full">
|
<div class=" w-full">
|
||||||
|
@ -355,7 +355,7 @@
|
||||||
{/each}
|
{/each}
|
||||||
|
|
||||||
{#if bottomPadding}
|
{#if bottomPadding}
|
||||||
<div class=" mb-10" />
|
<div class=" mb-20" />
|
||||||
{/if}
|
{/if}
|
||||||
{/key}
|
{/key}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -24,68 +24,66 @@
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
{#if models.length > 0}
|
{#if models.length > 0}
|
||||||
<div class=" text-center py-24 md:py-36">
|
<div class="m-auto w-full max-w-3xl px-8 pb-24">
|
||||||
<div class="m-auto max-w-3xl px-8">
|
<div class="flex justify-start">
|
||||||
<div class="flex justify-start mt-8">
|
<div class="flex -space-x-4 mb-0.5">
|
||||||
<div class="flex -space-x-4 mb-0.5">
|
{#each models as model, modelIdx}
|
||||||
{#each models as model, modelIdx}
|
<button
|
||||||
<button
|
on:click={() => {
|
||||||
on:click={() => {
|
selectedModelIdx = modelIdx;
|
||||||
selectedModelIdx = modelIdx;
|
}}
|
||||||
}}
|
>
|
||||||
>
|
{#if model in modelfiles}
|
||||||
{#if model in modelfiles}
|
<img
|
||||||
<img
|
src={modelfiles[model]?.imageUrl ?? `${WEBUI_BASE_URL}/static/favicon.png`}
|
||||||
src={modelfiles[model]?.imageUrl ?? `${WEBUI_BASE_URL}/static/favicon.png`}
|
alt="modelfile"
|
||||||
alt="modelfile"
|
class=" size-[2.7rem] rounded-full border-[1px] border-gray-200 dark:border-none"
|
||||||
class=" size-[2.7rem] rounded-full border-[1px] border-gray-200 dark:border-none"
|
draggable="false"
|
||||||
draggable="false"
|
/>
|
||||||
/>
|
{:else}
|
||||||
{:else}
|
<img
|
||||||
<img
|
src={$i18n.language === 'dg-DG'
|
||||||
src={$i18n.language === 'dg-DG'
|
? `/doge.png`
|
||||||
? `/doge.png`
|
: `${WEBUI_BASE_URL}/static/favicon.png`}
|
||||||
: `${WEBUI_BASE_URL}/static/favicon.png`}
|
class=" size-[2.7rem] rounded-full border-[1px] border-gray-200 dark:border-none"
|
||||||
class=" size-[2.7rem] rounded-full border-[1px] border-gray-200 dark:border-none"
|
alt="logo"
|
||||||
alt="logo"
|
draggable="false"
|
||||||
draggable="false"
|
/>
|
||||||
/>
|
|
||||||
{/if}
|
|
||||||
</button>
|
|
||||||
{/each}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div
|
|
||||||
class=" mt-2 mb-4 text-2xl text-gray-800 dark:text-gray-100 font-semibold text-left flex items-center gap-4"
|
|
||||||
>
|
|
||||||
<div>
|
|
||||||
{#if modelfile}
|
|
||||||
<span class=" capitalize">
|
|
||||||
{modelfile.title}
|
|
||||||
</span>
|
|
||||||
<div class="mt-0.5 text-base font-normal text-gray-500 dark:text-gray-400">
|
|
||||||
{modelfile.desc}
|
|
||||||
</div>
|
|
||||||
{#if modelfile.user}
|
|
||||||
<div class="mt-0.5 text-sm font-normal text-gray-400 dark:text-gray-500">
|
|
||||||
By <a href="https://openwebui.com/m/{modelfile.user.username}"
|
|
||||||
>{modelfile.user.name ? modelfile.user.name : `@${modelfile.user.username}`}</a
|
|
||||||
>
|
|
||||||
</div>
|
|
||||||
{/if}
|
{/if}
|
||||||
{:else}
|
</button>
|
||||||
<div class=" line-clamp-1">{$i18n.t('Hello, {{name}}', { name: $user.name })}</div>
|
{/each}
|
||||||
|
</div>
|
||||||
<div class=" font-medium text-gray-400 dark:text-gray-500">
|
</div>
|
||||||
{$i18n.t('How can I help you today?')}
|
<div
|
||||||
|
class=" mt-2 mb-4 text-2xl text-gray-800 dark:text-gray-100 font-semibold text-left flex items-center gap-4"
|
||||||
|
>
|
||||||
|
<div>
|
||||||
|
{#if modelfile}
|
||||||
|
<span class=" capitalize">
|
||||||
|
{modelfile.title}
|
||||||
|
</span>
|
||||||
|
<div class="mt-0.5 text-base font-normal text-gray-500 dark:text-gray-400">
|
||||||
|
{modelfile.desc}
|
||||||
|
</div>
|
||||||
|
{#if modelfile.user}
|
||||||
|
<div class="mt-0.5 text-sm font-normal text-gray-400 dark:text-gray-500">
|
||||||
|
By <a href="https://openwebui.com/m/{modelfile.user.username}"
|
||||||
|
>{modelfile.user.name ? modelfile.user.name : `@${modelfile.user.username}`}</a
|
||||||
|
>
|
||||||
</div>
|
</div>
|
||||||
{/if}
|
{/if}
|
||||||
</div>
|
{:else}
|
||||||
</div>
|
<div class=" line-clamp-1">{$i18n.t('Hello, {{name}}', { name: $user.name })}</div>
|
||||||
|
|
||||||
<div class=" max-w-full">
|
<div class=" font-medium text-gray-400 dark:text-gray-500">
|
||||||
<Suggestions {suggestionPrompts} {submitPrompt} />
|
{$i18n.t('How can I help you today?')}
|
||||||
|
</div>
|
||||||
|
{/if}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class=" w-full">
|
||||||
|
<Suggestions {suggestionPrompts} {submitPrompt} />
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{/if}
|
{/if}
|
||||||
|
|
Loading…
Reference in a new issue