{#if showFullMessages}
{}} continueResponse={() => {}} regenerateResponse={() => {}} messagesCount={null} editCodeBlock={false} />
{/if}
{ if (e.detail === false) { onClose(); } }} >
{#if $mobile}
{ await showControls.set(true); await showOverview.set(false); await showArtifacts.set(false); }} >
{$i18n.t('Controls')}
{/if}
{ await showControls.set(true); await showOverview.set(true); await showArtifacts.set(false); }} >
{$i18n.t('Overview')}
{ await showControls.set(true); await showArtifacts.set(true); await showOverview.set(false); }} >
{$i18n.t('Artifacts')}
{#if !$temporaryChatEnabled && ($user?.role === 'admin' || ($user.permissions?.chat?.share ?? true))}
{ shareHandler(); }} >
{$i18n.t('Share')}
{/if}
{$i18n.t('Download')}
{#if $user?.role === 'admin' || ($user.permissions?.chat?.export ?? true)}
{ downloadJSONExport(); }} >
{$i18n.t('Export chat (.json)')}
{/if}
{ downloadTxt(); }} >
{$i18n.t('Plain text (.txt)')}
{ downloadPdf(); }} >
{$i18n.t('PDF document (.pdf)')}
{ const res = await copyToClipboard(await getChatAsText()).catch((e) => { console.error(e); }); if (res) { toast.success($i18n.t('Copied to clipboard')); } }} >
{$i18n.t('Copy')}
{#if chat?.id}
{$i18n.t('Move')}
{#each $folders.sort((a, b) => b.updated_at - a.updated_at) as folder}
{ moveChatHandler(chat?.id, folder?.id); }} >
{folder?.name ?? 'Folder'}
{/each}
{/if}
{ archiveChatHandler(); }} >
{$i18n.t('Archive')}
{#if !$temporaryChatEnabled}
{/if}