mirror of
https://github.com/open-webui/open-webui.git
synced 2026-10-28 06:22:33 +00:00
fix: Archived Chats hides Export when the Allow Chat Export permission is off (#32684)
This commit is contained in:
parent
fdb304be2f
commit
c9936e81ec
1 changed files with 13 additions and 11 deletions
|
|
@ -252,17 +252,19 @@
|
|||
</div>
|
||||
</button>
|
||||
|
||||
<button
|
||||
class="flex h-[1.6875rem] w-full cursor-pointer select-none items-center gap-2 rounded-lg bg-transparent px-2 text-xs hover:text-gray-900 disabled:cursor-default disabled:opacity-30 dark:hover:text-gray-100"
|
||||
disabled={loading || chatCount === 0}
|
||||
type="button"
|
||||
on:click={exportChatsHandler}
|
||||
>
|
||||
<Download className="size-3.5 shrink-0" strokeWidth="1.5" />
|
||||
<div class="min-w-0 flex-1 truncate text-left">
|
||||
{$i18n.t('settings.personal.archivedChats.exportArchivedChats.label')}
|
||||
</div>
|
||||
</button>
|
||||
{#if $user?.role === 'admin' || ($user?.permissions?.chat?.export ?? true)}
|
||||
<button
|
||||
class="flex h-[1.6875rem] w-full cursor-pointer select-none items-center gap-2 rounded-lg bg-transparent px-2 text-xs hover:text-gray-900 disabled:cursor-default disabled:opacity-30 dark:hover:text-gray-100"
|
||||
disabled={loading || chatCount === 0}
|
||||
type="button"
|
||||
on:click={exportChatsHandler}
|
||||
>
|
||||
<Download className="size-3.5 shrink-0" strokeWidth="1.5" />
|
||||
<div class="min-w-0 flex-1 truncate text-left">
|
||||
{$i18n.t('settings.personal.archivedChats.exportArchivedChats.label')}
|
||||
</div>
|
||||
</button>
|
||||
{/if}
|
||||
</DropdownMenu>
|
||||
</div>
|
||||
</Dropdown>
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue