i18n: add missing translations
This commit is contained in:
@@ -762,7 +762,7 @@
|
||||
<option value="">{$i18n.t('Default (SentenceTransformers)')}</option>
|
||||
<option value="ollama">{$i18n.t('Ollama')}</option>
|
||||
<option value="openai">{$i18n.t('OpenAI')}</option>
|
||||
<option value="azure_openai">Azure OpenAI</option>
|
||||
<option value="azure_openai">{$i18n.t('Azure OpenAI')}</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -410,10 +410,10 @@
|
||||
</div>
|
||||
|
||||
<div class="mt-2 text-xs text-gray-500">
|
||||
<span class=" font-semibold dark:text-gray-200">Warning:</span> Pipelines are a plugin
|
||||
system with arbitrary code execution —
|
||||
<span class=" font-semibold dark:text-gray-200">{$i18n.t('Warning:')}</span>
|
||||
{$i18n.t('Pipelines are a plugin system with arbitrary code execution —')}
|
||||
<span class=" font-medium dark:text-gray-400"
|
||||
>don't fetch random pipelines from sources you don't trust.</span
|
||||
>{$i18n.t("don't fetch random pipelines from sources you don't trust.")}</span
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -213,9 +213,9 @@
|
||||
{:else}
|
||||
<div>
|
||||
<div class=" flex items-center gap-3 justify-between text-xs uppercase px-1 font-bold">
|
||||
<div class="w-full basis-3/5">Group</div>
|
||||
<div class="w-full basis-3/5">{$i18n.t('Group')}</div>
|
||||
|
||||
<div class="w-full basis-2/5 text-right">Users</div>
|
||||
<div class="w-full basis-2/5 text-right">{$i18n.t('Users')}</div>
|
||||
</div>
|
||||
|
||||
<hr class="mt-1.5 border-gray-100 dark:border-gray-850" />
|
||||
|
||||
@@ -166,12 +166,12 @@
|
||||
{#if total > $config?.license_metadata?.seats}
|
||||
<span class="text-lg font-medium text-red-500"
|
||||
>{total} of {$config?.license_metadata?.seats}
|
||||
<span class="text-sm font-normal">available users</span></span
|
||||
<span class="text-sm font-normal">{$i18n.t('available users')}</span></span
|
||||
>
|
||||
{:else}
|
||||
<span class="text-lg font-medium text-gray-500 dark:text-gray-300"
|
||||
>{total} of {$config?.license_metadata?.seats}
|
||||
<span class="text-sm font-normal">available users</span></span
|
||||
<span class="text-sm font-normal">{$i18n.t('available users')}</span></span
|
||||
>
|
||||
{/if}
|
||||
{:else}
|
||||
|
||||
@@ -59,7 +59,7 @@
|
||||
>
|
||||
<div class="w-full flex justify-center py-1 text-xs animate-pulse items-center gap-2">
|
||||
<Spinner className=" size-4" />
|
||||
<div class=" ">Loading...</div>
|
||||
<div class=" ">{$i18n.t('Loading...')}</div>
|
||||
</div>
|
||||
</Loader>
|
||||
{:else if !thread}
|
||||
@@ -84,7 +84,7 @@
|
||||
</div>
|
||||
{:else}
|
||||
<div class="flex justify-center text-xs items-center gap-2 py-5">
|
||||
<div class=" ">Start of the channel</div>
|
||||
<div class=" ">{$i18n.t('Start of the channel')}</div>
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
|
||||
@@ -1,5 +1,8 @@
|
||||
<script lang="ts">
|
||||
import { DropdownMenu } from 'bits-ui';
|
||||
import { getContext } from 'svelte';
|
||||
|
||||
const i18n = getContext('i18n');
|
||||
|
||||
import { flyAndScale } from '$lib/utils/transitions';
|
||||
import { WEBUI_BASE_URL } from '$lib/constants';
|
||||
@@ -76,7 +79,7 @@
|
||||
</div>
|
||||
|
||||
<div class=" -translate-y-[1px]">
|
||||
<span class="text-xs"> Active </span>
|
||||
<span class="text-xs"> {$i18n.t('Active')} </span>
|
||||
</div>
|
||||
{:else}
|
||||
<div>
|
||||
@@ -86,7 +89,7 @@
|
||||
</div>
|
||||
|
||||
<div class=" -translate-y-[1px]">
|
||||
<span class="text-xs"> Away </span>
|
||||
<span class="text-xs"> {$i18n.t('Away')} </span>
|
||||
</div>
|
||||
{/if}
|
||||
</div>
|
||||
|
||||
@@ -132,7 +132,7 @@
|
||||
<!-- Virtualized Emoji List -->
|
||||
<div class="w-full flex justify-start h-96 overflow-y-auto px-3 pb-3 text-sm">
|
||||
{#if emojiRows.length === 0}
|
||||
<div class="text-center text-xs text-gray-500 dark:text-gray-400">No results</div>
|
||||
<div class="text-center text-xs text-gray-500 dark:text-gray-400">{$i18n.t('No results')}</div>
|
||||
{:else}
|
||||
<div class="w-full flex ml-0.5">
|
||||
<VirtualList rowHeight={ROW_HEIGHT} items={emojiRows} height={384} let:item>
|
||||
|
||||
@@ -8,9 +8,11 @@
|
||||
import XMark from '$lib/components/icons/XMark.svelte';
|
||||
import MessageInput from './MessageInput.svelte';
|
||||
import Messages from './Messages.svelte';
|
||||
import { onDestroy, onMount, tick } from 'svelte';
|
||||
import { onDestroy, onMount, tick, getContext } from 'svelte';
|
||||
import { toast } from 'svelte-sonner';
|
||||
|
||||
const i18n = getContext('i18n');
|
||||
|
||||
export let threadId = null;
|
||||
export let channel = null;
|
||||
|
||||
@@ -158,7 +160,7 @@
|
||||
{#if channel}
|
||||
<div class="flex flex-col w-full h-full bg-gray-50 dark:bg-gray-850">
|
||||
<div class="flex items-center justify-between px-3.5 pt-3">
|
||||
<div class=" font-medium text-lg">Thread</div>
|
||||
<div class=" font-medium text-lg">{$i18n.t('Thread')}</div>
|
||||
|
||||
<div>
|
||||
<button
|
||||
|
||||
@@ -872,7 +872,7 @@
|
||||
: `${WEBUI_BASE_URL}/static/favicon.png`)}
|
||||
/>
|
||||
<div class="translate-y-[0.5px]">
|
||||
Talking to <span class=" font-medium">{atSelectedModel.name}</span>
|
||||
{$i18n.t('Talk to model')}: <span class=" font-medium">{atSelectedModel.name}</span>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
|
||||
@@ -388,7 +388,7 @@
|
||||
>
|
||||
<div class="flex flex-col">
|
||||
<div class="line-clamp-1">{$i18n.t('Microsoft OneDrive (work/school)')}</div>
|
||||
<div class="text-xs text-gray-500">Includes SharePoint</div>
|
||||
<div class="text-xs text-gray-500">{$i18n.t('Includes SharePoint')}</div>
|
||||
</div>
|
||||
</DropdownMenu.Item>
|
||||
</DropdownMenu.SubContent>
|
||||
|
||||
@@ -416,7 +416,7 @@
|
||||
>
|
||||
<div class="w-full flex justify-center py-1 text-xs animate-pulse items-center gap-2">
|
||||
<Spinner className=" size-4" />
|
||||
<div class=" ">Loading...</div>
|
||||
<div class=" ">{$i18n.t('Loading...')}</div>
|
||||
</div>
|
||||
</Loader>
|
||||
{/if}
|
||||
|
||||
@@ -548,13 +548,13 @@
|
||||
>
|
||||
{#if executing}
|
||||
<div class=" ">
|
||||
<div class=" text-gray-500 text-xs mb-1">STDOUT/STDERR</div>
|
||||
<div class="text-sm">Running...</div>
|
||||
<div class=" text-gray-500 text-xs mb-1">{$i18n.t('STDOUT/STDERR')}</div>
|
||||
<div class="text-sm">{$i18n.t('Running...')}</div>
|
||||
</div>
|
||||
{:else}
|
||||
{#if stdout || stderr}
|
||||
<div class=" ">
|
||||
<div class=" text-gray-500 text-xs mb-1">STDOUT/STDERR</div>
|
||||
<div class=" text-gray-500 text-xs mb-1">{$i18n.t('STDOUT/STDERR')}</div>
|
||||
<div
|
||||
class="text-sm {stdout?.split('\n')?.length > 100
|
||||
? `max-h-96`
|
||||
@@ -566,7 +566,7 @@
|
||||
{/if}
|
||||
{#if result || files}
|
||||
<div class=" ">
|
||||
<div class=" text-gray-500 text-xs mb-1">RESULT</div>
|
||||
<div class=" text-gray-500 text-xs mb-1">{$i18n.t('RESULT')}</div>
|
||||
{#if result}
|
||||
<div class="text-sm">{`${JSON.stringify(result)}`}</div>
|
||||
{/if}
|
||||
|
||||
@@ -1102,7 +1102,7 @@
|
||||
{#if (params?.use_mmap ?? null) !== null}
|
||||
<div class="flex justify-between items-center mt-1">
|
||||
<div class="text-xs text-gray-500">
|
||||
{params.use_mmap ? 'Enabled' : 'Disabled'}
|
||||
{params.use_mmap ? $i18n.t('Enabled') : $i18n.t('Disabled')}
|
||||
</div>
|
||||
<div class=" pr-2">
|
||||
<Switch bind:state={params.use_mmap} />
|
||||
@@ -1143,7 +1143,7 @@
|
||||
{#if (params?.use_mlock ?? null) !== null}
|
||||
<div class="flex justify-between items-center mt-1">
|
||||
<div class="text-xs text-gray-500">
|
||||
{params.use_mlock ? 'Enabled' : 'Disabled'}
|
||||
{params.use_mlock ? $i18n.t('Enabled') : $i18n.t('Disabled')}
|
||||
</div>
|
||||
|
||||
<div class=" pr-2">
|
||||
|
||||
@@ -263,7 +263,7 @@
|
||||
bind:value={TTSEngineConfig.dtype}
|
||||
placeholder={$i18n.t('Select dtype')}
|
||||
>
|
||||
<option value="" disabled selected>Select dtype</option>
|
||||
<option value="" disabled selected>{$i18n.t('Select dtype')}</option>
|
||||
<option value="fp32">fp32</option>
|
||||
<option value="fp16">fp16</option>
|
||||
<option value="q8">q8</option>
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
>
|
||||
<div>
|
||||
<div class="text-xs flex items-center justify-between mb-2">
|
||||
<div class="font-medium">Actions</div>
|
||||
<div class="font-medium">{$i18n.t('Actions')}</div>
|
||||
|
||||
<div class="flex items-center gap-2 text-gray-700 dark:text-gray-300">
|
||||
<button
|
||||
|
||||
@@ -225,7 +225,7 @@ print("${endTag}")
|
||||
basicSetup,
|
||||
keymap.of([{ key: 'Tab', run: acceptCompletion }, indentWithTab]),
|
||||
indentUnit.of(' '),
|
||||
placeholder('Enter your code here...'),
|
||||
placeholder($i18n.t('Enter your code here...')),
|
||||
EditorView.updateListener.of((e) => {
|
||||
if (e.docChanged) {
|
||||
_value = e.state.doc.toString();
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
<script lang="ts">
|
||||
import { DropdownMenu } from 'bits-ui';
|
||||
import { createEventDispatcher } from 'svelte';
|
||||
import { createEventDispatcher, getContext } from 'svelte';
|
||||
|
||||
const i18n = getContext('i18n');
|
||||
|
||||
import { flyAndScale } from '$lib/utils/transitions';
|
||||
|
||||
@@ -31,15 +33,15 @@
|
||||
transition={flyAndScale}
|
||||
>
|
||||
<DropdownMenu.Item class="flex items-center px-3 py-2 text-sm font-medium">
|
||||
<div class="flex items-center">Profile</div>
|
||||
<div class="flex items-center">{$i18n.t('Profile')}</div>
|
||||
</DropdownMenu.Item>
|
||||
|
||||
<DropdownMenu.Item class="flex items-center px-3 py-2 text-sm font-medium">
|
||||
<div class="flex items-center">Profile</div>
|
||||
<div class="flex items-center">{$i18n.t('Profile')}</div>
|
||||
</DropdownMenu.Item>
|
||||
|
||||
<DropdownMenu.Item class="flex items-center px-3 py-2 text-sm font-medium">
|
||||
<div class="flex items-center">Profile</div>
|
||||
<div class="flex items-center">{$i18n.t('Profile')}</div>
|
||||
</DropdownMenu.Item>
|
||||
</DropdownMenu.Content>
|
||||
</slot>
|
||||
|
||||
@@ -85,7 +85,7 @@
|
||||
{:else}
|
||||
<div>
|
||||
<div class="block px-5 py-2 text-sm text-gray-700 dark:text-gray-100">
|
||||
No results found
|
||||
{$i18n.t('No results found')}
|
||||
</div>
|
||||
</div>
|
||||
{/each}
|
||||
|
||||
@@ -70,7 +70,7 @@
|
||||
{:else if (valvesSpec.properties[property]?.type ?? null) === 'boolean'}
|
||||
<div class="flex justify-between items-center">
|
||||
<div class="text-xs text-gray-500">
|
||||
{valves[property] ? 'Enabled' : 'Disabled'}
|
||||
{valves[property] ? $i18n.t('Enabled') : $i18n.t('Disabled')}
|
||||
</div>
|
||||
|
||||
<div class=" pr-2">
|
||||
@@ -173,5 +173,5 @@
|
||||
</div>
|
||||
{/each}
|
||||
{:else}
|
||||
<div class="text-xs">No valves</div>
|
||||
<div class="text-xs">{$i18n.t('No valves')}</div>
|
||||
{/if}
|
||||
|
||||
@@ -317,7 +317,7 @@
|
||||
class="w-full flex justify-center py-1 text-xs animate-pulse items-center gap-2"
|
||||
>
|
||||
<Spinner className=" size-4" />
|
||||
<div class=" ">Loading...</div>
|
||||
<div class=" ">{$i18n.t('Loading...')}</div>
|
||||
</div>
|
||||
</Loader>
|
||||
{/if}
|
||||
|
||||
@@ -332,7 +332,7 @@
|
||||
>
|
||||
<div class="w-full flex justify-center py-4 text-xs animate-pulse items-center gap-2">
|
||||
<Spinner className=" size-4" />
|
||||
<div class=" ">Loading...</div>
|
||||
<div class=" ">{$i18n.t('Loading...')}</div>
|
||||
</div>
|
||||
</Loader>
|
||||
{/if}
|
||||
|
||||
@@ -1094,7 +1094,7 @@
|
||||
class="w-full flex justify-center py-1 text-xs animate-pulse items-center gap-2"
|
||||
>
|
||||
<Spinner className=" size-4" />
|
||||
<div class=" ">Loading...</div>
|
||||
<div class=" ">{$i18n.t('Loading...')}</div>
|
||||
</div>
|
||||
</Loader>
|
||||
{/if}
|
||||
@@ -1103,7 +1103,7 @@
|
||||
class="w-full flex justify-center py-1 text-xs animate-pulse items-center gap-2"
|
||||
>
|
||||
<Spinner className=" size-4" />
|
||||
<div class=" ">Loading...</div>
|
||||
<div class=" ">{$i18n.t('Loading...')}</div>
|
||||
</div>
|
||||
{/if}
|
||||
</div>
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
<div class="mt-1">
|
||||
<div class="pb-10">
|
||||
{#if files.length > 0}
|
||||
<div class=" text-xs font-medium pb-1">Files</div>
|
||||
<div class=" text-xs font-medium pb-1">{$i18n.t('Files')}</div>
|
||||
|
||||
<div class="flex flex-col gap-1">
|
||||
{#each files.filter((file) => file.type !== 'image') as file, fileIdx}
|
||||
@@ -87,7 +87,7 @@
|
||||
<hr class="my-2 border-gray-50 dark:border-gray-700/10" />
|
||||
{/if}
|
||||
|
||||
<div class=" text-xs font-medium mb-1">Model</div>
|
||||
<div class=" text-xs font-medium mb-1">{$i18n.t('Model')}</div>
|
||||
|
||||
<div class="w-full">
|
||||
<select class="w-full bg-transparent text-sm outline-hidden" bind:value={selectedModelId}>
|
||||
|
||||
@@ -310,7 +310,7 @@
|
||||
/>
|
||||
</svg>
|
||||
</div>
|
||||
<div class=" self-center text-sm font-medium">{'Back'}</div>
|
||||
<div class=" self-center text-sm font-medium">{$i18n.t('Back')}</div>
|
||||
</button>
|
||||
{/if}
|
||||
|
||||
@@ -450,7 +450,7 @@
|
||||
}}
|
||||
type="button"
|
||||
>
|
||||
Reset Image</button
|
||||
{$i18n.t('Reset Image')}</button
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@@ -699,7 +699,7 @@
|
||||
</div>
|
||||
{/each}
|
||||
{:else}
|
||||
<div class="text-xs text-center">No suggestion prompts</div>
|
||||
<div class="text-xs text-center">{$i18n.t('No suggestion prompts')}</div>
|
||||
{/if}
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
Reference in New Issue
Block a user