refac
This commit is contained in:
@@ -248,8 +248,8 @@
|
||||
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-100 px-5 pt-4 pb-1.5">
|
||||
<h1 class="text-lg font-normal self-center ">
|
||||
<div class=" flex justify-between dark:text-gray-100 px-4 pt-3 pb-1">
|
||||
<h1 class="text-sm font-medium self-center">
|
||||
{#if edit}
|
||||
{$i18n.t('Edit Connection')}
|
||||
{:else}
|
||||
@@ -257,13 +257,13 @@
|
||||
{/if}
|
||||
</h1>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
aria-label={$i18n.t('Close modal')}
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
@@ -338,7 +338,7 @@
|
||||
|
||||
<Tooltip content={$i18n.t('Verify Connection')} className="self-end -mb-1">
|
||||
<button
|
||||
class="self-center p-1 bg-transparent hover:bg-gray-100 dark:hover:bg-gray-850 rounded-lg transition"
|
||||
class="self-center p-1 bg-transparent hover:bg-gray-50/70 dark:hover:bg-gray-850/50 rounded-lg transition"
|
||||
on:click={() => {
|
||||
verifyHandler();
|
||||
}}
|
||||
|
||||
@@ -138,13 +138,22 @@
|
||||
if (error?.status !== 404) throw error;
|
||||
}
|
||||
|
||||
const lifecycle = await getOrchestratorLifecycle(localStorage.token, url, key, policyId, auth_type);
|
||||
const lifecycle = await getOrchestratorLifecycle(
|
||||
localStorage.token,
|
||||
url,
|
||||
key,
|
||||
policyId,
|
||||
auth_type
|
||||
);
|
||||
const data = policy?.data ?? {};
|
||||
policyImage = data.image ?? '';
|
||||
policyIdleTimeout = data.idle_timeout_minutes ?? 30;
|
||||
policyStorage = data.storage ? 'persistent' : 'ephemeral';
|
||||
policyStorageSize = data.storage ?? '5Gi';
|
||||
policyEnvPairs = Object.entries(data.env ?? {}).map(([key, value]) => ({ key, value: String(value) }));
|
||||
policyEnvPairs = Object.entries(data.env ?? {}).map(([key, value]) => ({
|
||||
key,
|
||||
value: String(value)
|
||||
}));
|
||||
policyCpu = data.cpu_limit ?? '1';
|
||||
policyMemory = data.memory_limit ?? '1Gi';
|
||||
lifecycleJson = stringifyJson(lifecycle?.data);
|
||||
@@ -358,8 +367,8 @@
|
||||
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<div class="flex justify-between dark:text-gray-100 px-5 pt-4 pb-2">
|
||||
<h1 class="text-lg font-normal self-center ">
|
||||
<div class="flex justify-between dark:text-gray-100 px-4 pt-3 pb-1">
|
||||
<h1 class="text-sm font-medium self-center">
|
||||
{#if edit}
|
||||
{$i18n.t('Edit Terminal Connection')}
|
||||
{:else}
|
||||
@@ -368,13 +377,13 @@
|
||||
</h1>
|
||||
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
aria-label={$i18n.t('Close')}
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
@@ -452,7 +461,7 @@
|
||||
|
||||
<Tooltip content={$i18n.t('Verify Connection')} className="self-end -mb-1">
|
||||
<button
|
||||
class="self-center p-1 bg-transparent hover:bg-gray-100 dark:hover:bg-gray-850 rounded-lg transition"
|
||||
class="self-center p-1 bg-transparent hover:bg-gray-50/70 dark:hover:bg-gray-850/50 rounded-lg transition"
|
||||
on:click={() => {
|
||||
verifyHandler();
|
||||
}}
|
||||
@@ -527,7 +536,9 @@
|
||||
{#if loadingPolicy}
|
||||
<div class="mt-2 text-xs text-gray-500">{$i18n.t('Loading policy...')}</div>
|
||||
{:else if policyLoadError}
|
||||
<div class="mt-2 text-xs text-red-600 dark:text-red-400">{$i18n.t('Failed to load policy: {{error}}', { error: policyLoadError })}</div>
|
||||
<div class="mt-2 text-xs text-red-600 dark:text-red-400">
|
||||
{$i18n.t('Failed to load policy: {{error}}', { error: policyLoadError })}
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
<div class="flex gap-2 mt-2">
|
||||
@@ -715,7 +726,7 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex flex-wrap items-center justify-between gap-2 mt-2">
|
||||
<div class="flex flex-wrap items-center justify-between gap-2 mt-2">
|
||||
<div class="flex items-center gap-3 text-xs text-gray-500 dark:text-gray-400">
|
||||
<label class="flex items-center gap-1.5">
|
||||
<input type="checkbox" bind:checked={refreshOnlyIdle} />
|
||||
@@ -727,7 +738,9 @@
|
||||
</label>
|
||||
</div>
|
||||
<div class="mt-2 text-xs text-gray-500 dark:text-gray-400">
|
||||
{$i18n.t('Policy changes apply to newly provisioned terminals. Refresh matching terminals to apply them to existing terminals.')}
|
||||
{$i18n.t(
|
||||
'Policy changes apply to newly provisioned terminals. Refresh matching terminals to apply them to existing terminals.'
|
||||
)}
|
||||
</div>
|
||||
<button
|
||||
type="button"
|
||||
|
||||
@@ -444,8 +444,8 @@
|
||||
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-100 px-5 pt-4 pb-2">
|
||||
<h1 class=" text-lg font-normal self-center ">
|
||||
<div class=" flex justify-between dark:text-gray-100 px-4 pt-3 pb-1">
|
||||
<h1 class=" text-sm font-medium self-center">
|
||||
{#if edit}
|
||||
{$i18n.t('Edit Connection')}
|
||||
{:else}
|
||||
@@ -470,13 +470,13 @@
|
||||
</button>
|
||||
</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
aria-label={$i18n.t('Close Configure Connection Modal')}
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
@@ -622,7 +622,7 @@
|
||||
className="shrink-0 flex items-center mr-1"
|
||||
>
|
||||
<button
|
||||
class="self-center p-1 bg-transparent hover:bg-gray-100 dark:hover:bg-gray-850 rounded-lg transition"
|
||||
class="self-center p-1 bg-transparent hover:bg-gray-50/70 dark:hover:bg-gray-850/50 rounded-lg transition"
|
||||
on:click={() => {
|
||||
verifyHandler();
|
||||
}}
|
||||
|
||||
@@ -110,9 +110,9 @@
|
||||
<Modal size="md" bind:show>
|
||||
<div>
|
||||
<!-- Header -->
|
||||
<div class="flex justify-between dark:text-gray-100 px-5 pt-4 pb-2">
|
||||
<div class="flex justify-between dark:text-gray-100 px-4 pt-3 pb-1">
|
||||
<input
|
||||
class="w-full text-lg font-normal bg-transparent outline-hidden placeholder:text-gray-300 dark:placeholder:text-gray-700"
|
||||
class="w-full text-sm font-medium bg-transparent outline-hidden placeholder:text-gray-300 dark:placeholder:text-gray-700"
|
||||
type="text"
|
||||
bind:value={name}
|
||||
placeholder={$i18n.t('Automation title')}
|
||||
@@ -122,7 +122,7 @@
|
||||
aria-label={$i18n.t('Close')}
|
||||
on:click={() => (show = false)}
|
||||
>
|
||||
<XMark className="size-5" />
|
||||
<XMark className="size-4" />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -43,8 +43,12 @@
|
||||
{$WEBUI_NAME}
|
||||
<Confetti x={[-1, -0.25]} y={[0, 0.5]} />
|
||||
</h2>
|
||||
<button class="self-center" on:click={closeModal} aria-label={$i18n.t('Close')}>
|
||||
<XMark className={'size-5'} />
|
||||
<button
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={closeModal}
|
||||
aria-label={$i18n.t('Close')}
|
||||
>
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
<div class="flex items-center mt-1">
|
||||
|
||||
@@ -63,16 +63,16 @@
|
||||
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-5 pt-4 pb-2">
|
||||
<div class=" text-lg font-normal self-center">{$i18n.t('Import')}</div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<div class=" text-sm font-medium self-center">{$i18n.t('Import')}</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
aria-label={$i18n.t('Close')}
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -178,14 +178,18 @@
|
||||
|
||||
<Modal size="md" bind:show>
|
||||
{#if model}
|
||||
<div class="flex justify-between dark:text-gray-300 px-5 pt-4 pb-2">
|
||||
<div class="flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<Tooltip content={`${model.name} (${model.id})`} placement="top-start">
|
||||
<div class="text-lg font-normal self-center line-clamp-1">
|
||||
<div class="text-sm font-medium self-center line-clamp-1">
|
||||
{model.name}
|
||||
</div>
|
||||
</Tooltip>
|
||||
<button class="self-center" on:click={close} aria-label="Close">
|
||||
<XMark className={'size-5'} />
|
||||
<button
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={close}
|
||||
aria-label="Close"
|
||||
>
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -42,12 +42,16 @@
|
||||
<Modal size="sm" bind:show>
|
||||
{#if selectedFeedback}
|
||||
<div>
|
||||
<div class="flex justify-between dark:text-gray-300 px-5 pt-4 pb-2">
|
||||
<div class="text-lg font-normal self-center">
|
||||
<div class="flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<div class="text-sm font-medium self-center">
|
||||
{$i18n.t('Feedback Details')}
|
||||
</div>
|
||||
<button class="self-center" on:click={close} aria-label="Close">
|
||||
<XMark className={'size-5'} />
|
||||
<button
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={close}
|
||||
aria-label="Close"
|
||||
>
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -61,14 +61,18 @@
|
||||
|
||||
<Modal size="md" bind:show>
|
||||
{#if model}
|
||||
<div class="flex justify-between dark:text-gray-300 px-5 pt-4 pb-2">
|
||||
<div class="flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<Tooltip content={`${model.name} (${model.id})`} placement="top-start">
|
||||
<div class="text-lg font-normal self-center line-clamp-1">
|
||||
<div class="text-sm font-medium self-center line-clamp-1">
|
||||
{model.name}
|
||||
</div>
|
||||
</Tooltip>
|
||||
<button class="self-center" on:click={close} aria-label="Close">
|
||||
<XMark className={'size-5'} />
|
||||
<button
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={close}
|
||||
aria-label="Close"
|
||||
>
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
<div class="px-5 pb-4 dark:text-gray-200">
|
||||
|
||||
@@ -13,21 +13,19 @@
|
||||
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-100 px-5 pt-4 pb-2">
|
||||
<div
|
||||
class="flex w-full justify-between items-center text-lg font-normal self-center "
|
||||
>
|
||||
<div class=" flex justify-between dark:text-gray-100 px-4 pt-3 pb-1">
|
||||
<div class="flex w-full justify-between items-center text-sm font-medium self-center">
|
||||
<div class=" shrink-0">
|
||||
{$i18n.t('Manage Ollama')}
|
||||
</div>
|
||||
</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -130,8 +130,8 @@
|
||||
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-100 px-5 pt-4 pb-2">
|
||||
<div class=" text-lg font-normal self-center ">
|
||||
<div class=" flex justify-between dark:text-gray-100 px-4 pt-3 pb-1">
|
||||
<div class=" text-sm font-medium self-center">
|
||||
{#if edit}
|
||||
{$i18n.t('Edit Arena Model')}
|
||||
{:else}
|
||||
@@ -139,12 +139,12 @@
|
||||
{/if}
|
||||
</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -391,13 +391,18 @@
|
||||
|
||||
<Modal bind:show={showWebhookModal} size="sm">
|
||||
<div>
|
||||
<div class="flex justify-between dark:text-gray-100 px-5 pt-4 pb-2">
|
||||
<h1 class="text-lg font-normal self-center">
|
||||
<div class="flex justify-between dark:text-gray-100 px-4 pt-3 pb-1">
|
||||
<h1 class="text-sm font-medium self-center">
|
||||
{editing ? $i18n.t('Edit webhook') : $i18n.t('Add webhook')}
|
||||
</h1>
|
||||
|
||||
<button class="self-center" aria-label={$i18n.t('Close')} type="button" on:click={resetForm}>
|
||||
<XMark className="size-5" />
|
||||
<button
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
aria-label={$i18n.t('Close')}
|
||||
type="button"
|
||||
on:click={resetForm}
|
||||
>
|
||||
<XMark className="size-4" />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
@@ -531,7 +536,7 @@
|
||||
{#each targetGroupResults as group}
|
||||
<button
|
||||
type="button"
|
||||
class="w-full flex items-center justify-between gap-2 px-3 py-1.5 text-xs text-left hover:bg-gray-50 dark:hover:bg-gray-850"
|
||||
class="w-full flex items-center justify-between gap-2 px-3 py-1.5 text-xs text-left hover:bg-gray-50/70 dark:hover:bg-gray-850/50"
|
||||
on:click={() => addTargetGroup(group)}
|
||||
>
|
||||
<span class="truncate">{group.name}</span>
|
||||
@@ -542,7 +547,7 @@
|
||||
{#each targetUserResults as user}
|
||||
<button
|
||||
type="button"
|
||||
class="w-full flex items-center justify-between gap-2 px-3 py-1.5 text-xs text-left hover:bg-gray-50 dark:hover:bg-gray-850"
|
||||
class="w-full flex items-center justify-between gap-2 px-3 py-1.5 text-xs text-left hover:bg-gray-50/70 dark:hover:bg-gray-850/50"
|
||||
on:click={() => addTargetUser(user)}
|
||||
>
|
||||
<span class="truncate">
|
||||
@@ -721,7 +726,7 @@
|
||||
<div class="flex gap-1 items-center">
|
||||
<Tooltip content={$i18n.t('Configure')}>
|
||||
<button
|
||||
class="self-center p-1 bg-transparent hover:bg-gray-100 dark:hover:bg-gray-850 rounded-lg transition"
|
||||
class="self-center p-1 bg-transparent hover:bg-gray-50/70 dark:hover:bg-gray-850/50 rounded-lg transition"
|
||||
on:click={() => editWebhook(webhook)}
|
||||
type="button"
|
||||
>
|
||||
|
||||
@@ -410,13 +410,13 @@
|
||||
|
||||
<Modal bind:show={showSourceModal} size="sm">
|
||||
<div>
|
||||
<div class="flex justify-between dark:text-gray-100 px-5 pt-4 pb-2">
|
||||
<h1 class="text-lg font-normal self-center">
|
||||
<div class="flex justify-between dark:text-gray-100 px-4 pt-3 pb-1">
|
||||
<h1 class="text-sm font-medium self-center">
|
||||
{editingItem ? $i18n.t('Edit Knowledge Connection') : $i18n.t('Add Knowledge Connection')}
|
||||
</h1>
|
||||
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
aria-label={$i18n.t('Close')}
|
||||
type="button"
|
||||
on:click={() => {
|
||||
@@ -424,7 +424,7 @@
|
||||
resetForm();
|
||||
}}
|
||||
>
|
||||
<XMark className="size-5" />
|
||||
<XMark className="size-4" />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
@@ -724,7 +724,7 @@
|
||||
className="shrink-0 flex items-center mr-1"
|
||||
>
|
||||
<button
|
||||
class="self-center p-1 bg-transparent hover:bg-gray-100 dark:hover:bg-gray-850 rounded-lg transition"
|
||||
class="self-center p-1 bg-transparent hover:bg-gray-50/70 dark:hover:bg-gray-850/50 rounded-lg transition"
|
||||
type="button"
|
||||
on:click={testSource}
|
||||
disabled={testing}
|
||||
@@ -841,7 +841,7 @@
|
||||
<div class="flex gap-1 items-center">
|
||||
<Tooltip content={$i18n.t('Configure')}>
|
||||
<button
|
||||
class="self-center p-1 bg-transparent hover:bg-gray-100 dark:hover:bg-gray-850 rounded-lg transition disabled:opacity-50 disabled:cursor-not-allowed"
|
||||
class="self-center p-1 bg-transparent hover:bg-gray-50/70 dark:hover:bg-gray-850/50 rounded-lg transition disabled:opacity-50 disabled:cursor-not-allowed"
|
||||
type="button"
|
||||
disabled={!connection}
|
||||
aria-label={$i18n.t('Configure')}
|
||||
|
||||
@@ -39,17 +39,17 @@
|
||||
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-100 px-5 pt-4">
|
||||
<div class=" text-lg font-normal self-center ">
|
||||
<div class=" flex justify-between dark:text-gray-100 px-4 pt-3 pb-1">
|
||||
<div class=" text-sm font-medium self-center">
|
||||
{$i18n.t('Manage Models')}
|
||||
</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -165,17 +165,17 @@
|
||||
|
||||
<Modal size="lg" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-100 px-5 pt-4 pb-2">
|
||||
<div class=" text-lg font-normal self-center ">
|
||||
<div class=" flex justify-between dark:text-gray-100 px-4 pt-3 pb-1">
|
||||
<div class=" text-sm font-medium self-center">
|
||||
{$i18n.t('Settings')}
|
||||
</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -34,8 +34,8 @@
|
||||
|
||||
<Modal size="md" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-100 px-5 pt-4 mb-1.5">
|
||||
<div class=" text-lg font-normal self-center min-w-0 truncate">
|
||||
<div class=" flex justify-between dark:text-gray-100 px-4 pt-3 mb-1">
|
||||
<div class=" text-sm font-medium self-center min-w-0 truncate">
|
||||
{$i18n.t('User Preview')}
|
||||
{#if userName}
|
||||
<span class="text-sm font-normal text-gray-500 ml-1">{userName}</span>
|
||||
@@ -47,7 +47,7 @@
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -133,8 +133,8 @@
|
||||
|
||||
<Modal size="lg" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-100 px-5 pt-4 mb-1.5">
|
||||
<div class=" text-lg font-normal self-center ">
|
||||
<div class=" flex justify-between dark:text-gray-100 px-4 pt-3 mb-1">
|
||||
<div class=" text-sm font-medium self-center">
|
||||
{#if custom}
|
||||
{#if edit}
|
||||
{$i18n.t('Edit User Group')}
|
||||
@@ -146,12 +146,12 @@
|
||||
{/if}
|
||||
</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -143,16 +143,16 @@
|
||||
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-5 pt-4 pb-2">
|
||||
<div class=" text-lg font-normal self-center">{$i18n.t('Add User')}</div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<div class=" text-sm font-medium self-center">{$i18n.t('Add User')}</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
aria-label={$i18n.t('Close')}
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -68,16 +68,16 @@
|
||||
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-5 pt-4 pb-2">
|
||||
<div class=" text-lg font-normal self-center">{$i18n.t('Edit User')}</div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<div class=" text-sm font-medium self-center">{$i18n.t('Edit User')}</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
aria-label={$i18n.t('Close')}
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -64,14 +64,14 @@
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<!-- Header -->
|
||||
<div class="flex justify-between items-center dark:text-gray-100 px-5 pt-4 pb-2">
|
||||
<div class="flex justify-between items-center dark:text-gray-100 px-4 pt-3 pb-1">
|
||||
<h3 class="text-base font-normal">{$i18n.t('New Calendar')}</h3>
|
||||
<button
|
||||
class="self-center shrink-0 ml-2"
|
||||
aria-label={$i18n.t('Close')}
|
||||
on:click={() => (show = false)}
|
||||
>
|
||||
<XMark className="size-5" />
|
||||
<XMark className="size-4" />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
@@ -81,7 +81,7 @@
|
||||
<div>
|
||||
<div class="mb-1 text-xs text-gray-500">{$i18n.t('Name')}</div>
|
||||
<input
|
||||
class="w-full text-sm bg-transparent outline-hidden placeholder:text-gray-300 dark:placeholder:text-gray-700"
|
||||
class="w-full text-sm bg-transparent outline-hidden placeholder:text-gray-300 dark:placeholder:text-gray-700"
|
||||
type="text"
|
||||
bind:value={name}
|
||||
placeholder={$i18n.t('Calendar name')}
|
||||
|
||||
@@ -72,7 +72,7 @@
|
||||
<AddMembersModal bind:show={showAddMembersModal} {channel} {onUpdate} />
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-100 px-5 pt-4 mb-1.5">
|
||||
<div class=" flex justify-between dark:text-gray-100 px-4 pt-3 mb-1">
|
||||
<div class="self-center text-base">
|
||||
<div class="flex items-center gap-0.5 shrink-0">
|
||||
{#if channel?.type === 'dm'}
|
||||
@@ -95,12 +95,12 @@
|
||||
</div>
|
||||
</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -52,19 +52,19 @@
|
||||
{#if channel}
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-100 px-5 pt-4 mb-1.5">
|
||||
<div class=" flex justify-between dark:text-gray-100 px-4 pt-3 mb-1">
|
||||
<div class="self-center text-base">
|
||||
<div class="flex items-center gap-0.5 shrink-0">
|
||||
{$i18n.t('Add Members')}
|
||||
</div>
|
||||
</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -69,19 +69,19 @@
|
||||
{#if channel}
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-100 px-5 pt-4 mb-1.5">
|
||||
<div class=" flex justify-between dark:text-gray-100 px-4 pt-3 mb-1">
|
||||
<div class="self-center text-base">
|
||||
<div class="flex items-center gap-0.5 shrink-0">
|
||||
{$i18n.t('Pinned Messages')}
|
||||
</div>
|
||||
</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -99,7 +99,7 @@
|
||||
{#if channel}
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<div class="flex justify-between dark:text-gray-100 px-5 pt-4 mb-1.5">
|
||||
<div class="flex justify-between dark:text-gray-100 px-4 pt-3 mb-1">
|
||||
<div class="flex w-full justify-between items-center mr-3">
|
||||
<div class="self-center text-base flex gap-1.5 items-center">
|
||||
<div>{$i18n.t('Webhooks')}</div>
|
||||
@@ -117,8 +117,11 @@
|
||||
</button>
|
||||
</div>
|
||||
|
||||
<button class="self-center" on:click={() => (show = false)}>
|
||||
<XMark className="size-5" />
|
||||
<button
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => (show = false)}
|
||||
>
|
||||
<XMark className="size-4" />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -36,18 +36,18 @@
|
||||
|
||||
<Modal bind:show size="sm">
|
||||
<div class="flex flex-col h-full">
|
||||
<div class="flex justify-between items-center dark:text-gray-100 px-5 pt-4 pb-1.5">
|
||||
<h1 class="text-lg font-normal self-center ">
|
||||
<div class="flex justify-between items-center dark:text-gray-100 px-4 pt-3 pb-1">
|
||||
<h1 class="text-sm font-medium self-center">
|
||||
{$i18n.t('Attach Webpage')}
|
||||
</h1>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
aria-label={$i18n.t('Close modal')}
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className="size-5" />
|
||||
<XMark className="size-4" />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -66,15 +66,15 @@
|
||||
|
||||
<Modal bind:show size="md">
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-5 pt-4 pb-2">
|
||||
<div class=" text-lg font-normal self-center">{$i18n.t('Input Variables')}</div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<div class=" text-sm font-medium self-center">{$i18n.t('Input Variables')}</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -98,7 +98,7 @@
|
||||
<Modal size="lg" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-4.5 pt-3 pb-2">
|
||||
<div class=" text-lg font-normal self-center flex items-center">
|
||||
<div class=" text-sm font-medium self-center flex items-center">
|
||||
{#if citation?.source?.name}
|
||||
{@const document = mergedDocuments?.[0]}
|
||||
{#if document?.metadata?.file_id || document.source?.url?.includes('http')}
|
||||
@@ -130,13 +130,13 @@
|
||||
{/if}
|
||||
</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
aria-label={$i18n.t('Close citation modal')}
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -39,17 +39,17 @@
|
||||
|
||||
<Modal size="lg" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-5 pt-4 pb-2">
|
||||
<div class=" text-lg font-normal self-center capitalize">
|
||||
<div class=" flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<div class=" text-sm font-medium self-center capitalize">
|
||||
{$i18n.t('Citations')}
|
||||
</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -13,8 +13,8 @@
|
||||
|
||||
<Modal size="lg" bind:show>
|
||||
<div>
|
||||
<div class="flex justify-between dark:text-gray-300 px-5 pt-4 pb-2">
|
||||
<div class="text-lg font-normal self-center flex flex-col gap-0.5 capitalize">
|
||||
<div class="flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<div class="text-sm font-medium self-center flex flex-col gap-0.5 capitalize">
|
||||
{#if codeExecution?.result}
|
||||
<div>
|
||||
{#if codeExecution.result?.error}
|
||||
@@ -44,13 +44,13 @@
|
||||
</div>
|
||||
</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => {
|
||||
show = false;
|
||||
codeExecution = null;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -115,7 +115,7 @@
|
||||
class="flex-1 overflow-hidden max-w-full mt-0.5 py-0.5 pl-1 {$showSidebar ? 'ml-1' : ''}"
|
||||
>
|
||||
{#if chat?.id}
|
||||
<div class="flex max-w-full min-w-0 items-center gap-2">
|
||||
<div class="flex max-w-full min-w-0 items-center gap-2 mr-2">
|
||||
<div
|
||||
class="min-w-0 truncate py-1 text-left text-[15px] font-normal text-gray-700 dark:text-gray-300"
|
||||
>
|
||||
|
||||
@@ -29,18 +29,18 @@
|
||||
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-100 px-5 pt-4 pb-1.5">
|
||||
<h1 class="text-lg font-normal self-center ">
|
||||
<div class=" flex justify-between dark:text-gray-100 px-4 pt-3 pb-1">
|
||||
<h1 class="text-sm font-medium self-center">
|
||||
{$i18n.t('Quick Actions')}
|
||||
</h1>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
aria-label={$i18n.t('Close modal')}
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -25,18 +25,18 @@
|
||||
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-100 px-5 pt-4 pb-1.5">
|
||||
<h1 class="text-lg font-normal self-center ">
|
||||
<div class=" flex justify-between dark:text-gray-100 px-4 pt-3 pb-1">
|
||||
<h1 class="text-sm font-medium self-center">
|
||||
{$i18n.t('Manage')}
|
||||
</h1>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
aria-label={$i18n.t('Close modal')}
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -104,19 +104,22 @@
|
||||
|
||||
<Modal size="lg" bind:show>
|
||||
<div>
|
||||
<div class="flex justify-between dark:text-gray-300 px-5 pt-4 pb-1">
|
||||
<div class="flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<div class="flex items-center gap-2">
|
||||
<div class="text-lg font-normal">{$i18n.t('Memory')}</div>
|
||||
<div class="text-sm font-medium">{$i18n.t('Memory')}</div>
|
||||
|
||||
{#if !loading}
|
||||
<div class="text-lg font-normal text-gray-500 dark:text-gray-500">
|
||||
<div class="text-sm font-medium text-gray-500 dark:text-gray-500">
|
||||
{memories.length}
|
||||
</div>
|
||||
{/if}
|
||||
</div>
|
||||
|
||||
<button class="self-center" on:click={() => (show = false)}>
|
||||
<XMark className="size-5" />
|
||||
<button
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => (show = false)}
|
||||
>
|
||||
<XMark className="size-4" />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -53,16 +53,19 @@
|
||||
|
||||
<Modal bind:show size="sm">
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-5 pt-4 pb-2">
|
||||
<div class=" text-lg font-normal self-center">
|
||||
<div class=" flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<div class=" text-sm font-medium self-center">
|
||||
{#if edit}
|
||||
{$i18n.t('Edit Memory')}
|
||||
{:else}
|
||||
{$i18n.t('Add Memory')}
|
||||
{/if}
|
||||
</div>
|
||||
<button class="self-center" on:click={() => (show = false)}>
|
||||
<XMark className={'size-5'} />
|
||||
<button
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => (show = false)}
|
||||
>
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -354,17 +354,17 @@
|
||||
</div>
|
||||
</div>
|
||||
{:else}
|
||||
<div class="flex justify-between px-5 pt-4 pb-0.5">
|
||||
<div class="text-lg font-normal self-center">{$i18n.t('Sync Usage Stats')}</div>
|
||||
<div class="flex justify-between px-4 pt-3 pb-1">
|
||||
<div class="text-sm font-medium self-center">{$i18n.t('Sync Usage Stats')}</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
aria-label={$i18n.t('Close modal')}
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
disabled={syncing}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -111,16 +111,16 @@
|
||||
|
||||
<Modal bind:show size="md">
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-5 pt-4 pb-0.5">
|
||||
<div class=" text-lg font-normal self-center">{$i18n.t('Share Chat')}</div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<div class=" text-sm font-medium self-center">{$i18n.t('Share Chat')}</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
aria-label={$i18n.t('Close')}
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -18,16 +18,16 @@
|
||||
|
||||
<Modal bind:show size="md">
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-5 pt-4 pb-0.5">
|
||||
<div class=" text-lg font-normal self-center">{$i18n.t('Available Skills')}</div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<div class=" text-sm font-medium self-center">{$i18n.t('Available Skills')}</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
aria-label={$i18n.t('Close')}
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -33,16 +33,16 @@
|
||||
|
||||
<Modal bind:show size="md">
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-5 pt-4 pb-0.5">
|
||||
<div class=" text-lg font-normal self-center">{$i18n.t('Available Tools')}</div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<div class=" text-sm font-medium self-center">{$i18n.t('Available Tools')}</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
aria-label={$i18n.t('Close')}
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -92,21 +92,21 @@
|
||||
|
||||
<Modal size="lg" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-5 pt-4 pb-1">
|
||||
<div class="flex items-center gap-2 text-lg font-normal self-center">
|
||||
<div class=" flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<div class="flex items-center gap-2 text-sm font-medium self-center">
|
||||
<div>{title}</div>
|
||||
{#if count !== null}
|
||||
<div class="text-lg font-normal text-gray-500 dark:text-gray-500">
|
||||
<div class="text-sm font-medium text-gray-500 dark:text-gray-500">
|
||||
{count}
|
||||
</div>
|
||||
{:else if chatList}
|
||||
<div class="text-lg font-normal text-gray-500 dark:text-gray-500">
|
||||
<div class="text-sm font-medium text-gray-500 dark:text-gray-500">
|
||||
{chatList.length}
|
||||
</div>
|
||||
{/if}
|
||||
</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
@@ -115,7 +115,7 @@
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
viewBox="0 0 20 20"
|
||||
fill="currentColor"
|
||||
class="w-5 h-5"
|
||||
class="size-4"
|
||||
>
|
||||
<path
|
||||
fill-rule="evenodd"
|
||||
@@ -267,7 +267,7 @@
|
||||
{/if}
|
||||
|
||||
<div
|
||||
class=" w-full flex items-center rounded-lg text-sm py-2 px-3 hover:bg-gray-50 dark:hover:bg-gray-850"
|
||||
class=" w-full flex items-center rounded-lg text-sm py-2 px-3 hover:bg-gray-50/70 dark:hover:bg-gray-850/50"
|
||||
draggable="false"
|
||||
>
|
||||
{#if showUserInfo && chat.user_id}
|
||||
|
||||
@@ -202,21 +202,21 @@
|
||||
|
||||
<Modal size="xl" bind:show>
|
||||
<div>
|
||||
<div class="flex justify-between dark:text-gray-300 px-5 pt-4 pb-1">
|
||||
<div class="flex items-center gap-2 text-lg font-normal self-center">
|
||||
<div class="flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<div class="flex items-center gap-2 text-sm font-medium self-center">
|
||||
<div>{$i18n.t('Files')}</div>
|
||||
{#if query && files}
|
||||
<div class="text-lg font-normal text-gray-500 dark:text-gray-500">
|
||||
<div class="text-sm font-medium text-gray-500 dark:text-gray-500">
|
||||
{files.length}
|
||||
</div>
|
||||
{:else if fileCount !== null}
|
||||
<div class="text-lg font-normal text-gray-500 dark:text-gray-500">
|
||||
<div class="text-sm font-medium text-gray-500 dark:text-gray-500">
|
||||
{fileCount}
|
||||
</div>
|
||||
{/if}
|
||||
</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
@@ -225,7 +225,7 @@
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
viewBox="0 0 20 20"
|
||||
fill="currentColor"
|
||||
class="w-5 h-5"
|
||||
class="size-4"
|
||||
>
|
||||
<path
|
||||
fill-rule="evenodd"
|
||||
@@ -338,7 +338,7 @@
|
||||
|
||||
{#each files as file (file.id)}
|
||||
<div
|
||||
class="w-full flex justify-between items-center rounded-lg text-sm py-2 px-3 hover:bg-gray-50 dark:hover:bg-gray-850 cursor-pointer"
|
||||
class="w-full flex justify-between items-center rounded-lg text-sm py-2 px-3 hover:bg-gray-50/70 dark:hover:bg-gray-850/50 cursor-pointer"
|
||||
on:click={() => openFileViewer(file)}
|
||||
>
|
||||
<div class="basis-3/5 min-w-0">
|
||||
|
||||
@@ -140,8 +140,8 @@
|
||||
|
||||
<Modal size="md" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-5 pt-4 pb-1">
|
||||
<div class=" text-lg font-normal self-center">
|
||||
<div class=" flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<div class=" text-sm font-medium self-center">
|
||||
{#if edit}
|
||||
{$i18n.t('Edit Channel')}
|
||||
{:else}
|
||||
@@ -149,12 +149,12 @@
|
||||
{/if}
|
||||
</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -110,8 +110,8 @@
|
||||
|
||||
<Modal size="md" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-5 pt-4 pb-1">
|
||||
<div class=" text-lg font-normal self-center">
|
||||
<div class=" flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<div class=" text-sm font-medium self-center">
|
||||
{#if edit}
|
||||
{$i18n.t('Edit Folder')}
|
||||
{:else}
|
||||
@@ -119,12 +119,12 @@
|
||||
{/if}
|
||||
</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -57,16 +57,16 @@
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-100 px-5 pt-3 pb-1">
|
||||
<div class=" text-lg font-normal self-center ">
|
||||
<div class=" text-sm font-medium self-center">
|
||||
{$i18n.t('Share')}: {folder?.name ?? ''}
|
||||
</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -73,17 +73,17 @@
|
||||
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-5 pt-4 pb-1">
|
||||
<div class=" text-lg font-normal self-center">
|
||||
<div class=" flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<div class=" text-sm font-medium self-center">
|
||||
{$i18n.t('Set your status')}
|
||||
</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -320,16 +320,16 @@
|
||||
|
||||
<Modal size="sm" bind:show={showControls}>
|
||||
<div class="text-gray-700 dark:text-gray-100">
|
||||
<div class="flex justify-between px-4.5 pt-4.5 pb-2">
|
||||
<div class="text-lg font-normal self-center">{$i18n.t('Controls')}</div>
|
||||
<div class="flex justify-between px-4 pt-3 pb-1">
|
||||
<div class="text-sm font-medium self-center">{$i18n.t('Controls')}</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
aria-label={$i18n.t('Close')}
|
||||
on:click={() => {
|
||||
showControls = false;
|
||||
}}
|
||||
>
|
||||
<XMark className="size-5" />
|
||||
<XMark className="size-4" />
|
||||
</button>
|
||||
</div>
|
||||
<div class="px-4.5 pb-5 overflow-y-auto max-h-[70vh]">
|
||||
|
||||
@@ -121,7 +121,7 @@
|
||||
|
||||
<div class=" flex flex-col justify-between w-full overflow-y-auto h-full">
|
||||
<div class="mx-auto w-full md:px-0 h-full">
|
||||
<div class=" flex flex-col h-full px-4">
|
||||
<div class=" flex flex-col h-full px-2.5">
|
||||
<div
|
||||
class=" pt-0.5 pb-2.5 flex flex-col justify-between w-full flex-auto overflow-auto h-0"
|
||||
id="messages-container"
|
||||
|
||||
@@ -123,7 +123,7 @@
|
||||
|
||||
<div class=" flex flex-col justify-between w-full overflow-y-auto h-full">
|
||||
<div class="mx-auto w-full md:px-0 h-full">
|
||||
<div class=" flex flex-col h-full px-4">
|
||||
<div class=" flex flex-col h-full px-2.5">
|
||||
<!-- Results Area -->
|
||||
<div
|
||||
class=" pt-0.5 pb-2.5 flex flex-col justify-between w-full flex-auto overflow-auto h-0"
|
||||
|
||||
@@ -31,14 +31,14 @@
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<!-- Header -->
|
||||
<div class="flex justify-between items-center dark:text-gray-100 px-5 pt-4 pb-2">
|
||||
<div class="flex justify-between items-center dark:text-gray-100 px-4 pt-3 pb-1">
|
||||
<h3 class="text-base font-normal">{$i18n.t('New Directory')}</h3>
|
||||
<button
|
||||
class="self-center shrink-0 ml-2"
|
||||
aria-label={$i18n.t('Close')}
|
||||
on:click={() => (show = false)}
|
||||
>
|
||||
<XMark className="size-5" />
|
||||
<XMark className="size-4" />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
@@ -47,7 +47,7 @@
|
||||
<div>
|
||||
<div class="mb-1 text-xs text-gray-500">{$i18n.t('Name')}</div>
|
||||
<input
|
||||
class="w-full text-sm bg-transparent outline-hidden placeholder:text-gray-300 dark:placeholder:text-gray-700"
|
||||
class="w-full text-sm bg-transparent outline-hidden placeholder:text-gray-300 dark:placeholder:text-gray-700"
|
||||
type="text"
|
||||
bind:value={name}
|
||||
placeholder={$i18n.t('Directory name')}
|
||||
|
||||
@@ -302,15 +302,15 @@
|
||||
|
||||
<!-- Edit Modal -->
|
||||
<Modal size="lg" bind:show={showEditModal}>
|
||||
<div class="px-5 pt-4 pb-5">
|
||||
<div class="flex justify-between items-center mb-2">
|
||||
<div class="text-lg font-normal">{$i18n.t('Edit Prompt')}</div>
|
||||
<div class="px-4 pt-3 pb-4">
|
||||
<div class="flex justify-between items-center mb-2 dark:text-gray-100">
|
||||
<div class="text-sm font-medium">{$i18n.t('Edit Prompt')}</div>
|
||||
<button
|
||||
class="p-1 hover:bg-gray-100 dark:hover:bg-gray-800 rounded-lg"
|
||||
class="rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
aria-label={$i18n.t('Close')}
|
||||
on:click={() => (showEditModal = false)}
|
||||
>
|
||||
<XMark className="size-5" />
|
||||
<XMark className="size-4" />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -15,15 +15,15 @@
|
||||
|
||||
<Modal size="sm" bind:show>
|
||||
<div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-5 pt-4 pb-2">
|
||||
<div class=" text-lg font-normal self-center">{$i18n.t('Show your support!')}</div>
|
||||
<div class=" flex justify-between dark:text-gray-300 px-4 pt-3 pb-1">
|
||||
<div class=" text-sm font-medium self-center">{$i18n.t('Show your support!')}</div>
|
||||
<button
|
||||
class="self-center"
|
||||
class="self-center rounded-lg p-1 text-gray-500 transition hover:bg-gray-50 hover:text-gray-700 dark:text-gray-400 dark:hover:bg-gray-800 dark:hover:text-gray-200"
|
||||
on:click={() => {
|
||||
show = false;
|
||||
}}
|
||||
>
|
||||
<XMark className={'size-5'} />
|
||||
<XMark className={'size-4'} />
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user