mirror of
https://github.com/open-webui/open-webui.git
synced 2025-12-13 21:05:19 +00:00
refac
This commit is contained in:
parent
ac879513e5
commit
2904a78222
2 changed files with 3 additions and 1 deletions
|
|
@ -94,6 +94,7 @@
|
||||||
<Message
|
<Message
|
||||||
{message}
|
{message}
|
||||||
{thread}
|
{thread}
|
||||||
|
disabled={!channel?.write_access}
|
||||||
showUserProfile={messageIdx === 0 ||
|
showUserProfile={messageIdx === 0 ||
|
||||||
messageList.at(messageIdx - 1)?.user_id !== message.user_id ||
|
messageList.at(messageIdx - 1)?.user_id !== message.user_id ||
|
||||||
messageList.at(messageIdx - 1)?.meta?.model_id !== message?.meta?.model_id}
|
messageList.at(messageIdx - 1)?.meta?.model_id !== message?.meta?.model_id}
|
||||||
|
|
|
||||||
|
|
@ -40,6 +40,7 @@
|
||||||
export let message;
|
export let message;
|
||||||
export let showUserProfile = true;
|
export let showUserProfile = true;
|
||||||
export let thread = false;
|
export let thread = false;
|
||||||
|
export let disabled = false;
|
||||||
|
|
||||||
export let onDelete: Function = () => {};
|
export let onDelete: Function = () => {};
|
||||||
export let onEdit: Function = () => {};
|
export let onEdit: Function = () => {};
|
||||||
|
|
@ -68,7 +69,7 @@
|
||||||
? 'pt-1.5 pb-0.5'
|
? 'pt-1.5 pb-0.5'
|
||||||
: ''} w-full max-w-full mx-auto group hover:bg-gray-300/5 dark:hover:bg-gray-700/5 transition relative"
|
: ''} w-full max-w-full mx-auto group hover:bg-gray-300/5 dark:hover:bg-gray-700/5 transition relative"
|
||||||
>
|
>
|
||||||
{#if !edit}
|
{#if !edit && !disabled}
|
||||||
<div
|
<div
|
||||||
class=" absolute {showButtons ? '' : 'invisible group-hover:visible'} right-1 -top-2 z-10"
|
class=" absolute {showButtons ? '' : 'invisible group-hover:visible'} right-1 -top-2 z-10"
|
||||||
>
|
>
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue