Browse Source

聊天消息调整,首页样式微调

master
mk 6 months ago
parent
commit
c9fc181c4e
  1. 2
      .gitignore
  2. BIN
      backend/open_webui/static/splash.png
  3. 1
      src/lib/components/chat/Chat.svelte
  4. 4
      src/lib/components/chat/Header.svelte
  5. 8
      src/lib/components/chat/Messages.svelte
  6. BIN
      static/img/messages.png

2
.gitignore

@ -1,6 +1,6 @@
.DS_Store
node_modules
/build
/build*
/.svelte-kit
/package
.env

BIN
backend/open_webui/static/splash.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

1
src/lib/components/chat/Chat.svelte

@ -1860,7 +1860,6 @@
</svelte:head>
<audio id="audioElement" src="" style="display: none;" />
<EventConfirmDialog
bind:show={showEventConfirmation}
title={eventConfirmationTitle}

4
src/lib/components/chat/Header.svelte

@ -142,8 +142,10 @@
background-size: 100% 100%;
padding: 50px 70px 39px;
box-sizing: border-box;
width: calc(100vw - 20px);
width: calc(68vw - 20px);
margin: 0 auto;
border-radius: 5px;
position: relative;
bottom: 122px;
}
</style>

8
src/lib/components/chat/Messages.svelte

@ -24,7 +24,7 @@
const i18n = getContext('i18n');
export let className = 'h-full flex pt-8';
export let className = 'h-full flex pt-17';
export let chatId = '';
export let user = $_user;
@ -344,8 +344,8 @@
}
};
</script>
<div class={className}>
<img src={'/img/messages.png'} style="position: absolute;top: 0;left:0;right:0;bottom:40%;z-index: 0;" alt="">
<div class={className } >
{#if Object.keys(history?.messages ?? {}).length == 0}
<ChatPlaceholder
modelIds={selectedModels}
@ -379,7 +379,7 @@
}}
/>
{:else}
<div class="w-full pt-2">
<div class="w-full pt-2" style="z-index: 2;">
{#key chatId}
<div class="w-full">
{#if messages.at(0)?.parentId !== null}

BIN
static/img/messages.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 745 KiB

Loading…
Cancel
Save