Merge pull request #4150 from Yokayo/staging Update ru-ru locale

19d1bd29d4ceeabb928542b1a923732a07ae0848

Cohee <18619528+Cohee1207@users.noreply.github.com>

Signed
10 files changed, +189 -48Ignore whitespace
public/index.html+7 -7
@@ -661,7 +661,7 @@
661 </div>661 </div>
662 </div>662 </div>
663 <div data-source="openrouter" class="range-block">663 <div data-source="openrouter" class="range-block">
664 <div class="range-block-title" title="Allow compressing requests by removing messages from the middle of the prompt.">664 <div class="range-block-title" data-i18n="[title]Allow compressing requests by removing messages from the middle of the prompt." title="Allow compressing requests by removing messages from the middle of the prompt.">
665 <span data-i18n="Middle-out Transform">Middle-out Transform</span>665 <span data-i18n="Middle-out Transform">Middle-out Transform</span>
666 <a href="https://openrouter.ai/docs/transforms" target="_blank" rel="noreferrer noopener" class="note-link-span fa-solid fa-circle-question"></a>666 <a href="https://openrouter.ai/docs/transforms" target="_blank" rel="noreferrer noopener" class="note-link-span fa-solid fa-circle-question"></a>
667 </div>667 </div>
@@ -674,7 +674,7 @@
674 </div>674 </div>
675 </div>675 </div>
676 <div data-source="openrouter">676 <div data-source="openrouter">
677 Max prompt cost: <span id="openrouter_max_prompt_cost">Unknown</span>677 <span data-i18n="Max prompt cost:">Max prompt cost:</span> <span id="openrouter_max_prompt_cost" data-i18n="Unknown">Unknown</span>
678 </div>678 </div>
679 <hr>679 <hr>
680 <div class="range-block">680 <div class="range-block">
@@ -2714,12 +2714,12 @@
2714 </select>2714 </select>
2715 <div class="marginTopBot5">2715 <div class="marginTopBot5">
2716 <i class="fa-solid fa-flask"></i>2716 <i class="fa-solid fa-flask"></i>
2717 <span>Experimental feature. Use at your own risk.</span>2717 <span data-i18n="Experimental feature. Use at your own risk.">Experimental feature. Use at your own risk.</span>
2718 </div>2718 </div>
2719 <div class="marginTopBot5">2719 <div class="marginTopBot5">
2720 <small>2720 <small>
2721 <i class="fa-solid fa-lightbulb"></i>2721 <i class="fa-solid fa-lightbulb"></i>
2722 &nbsp;2722 &nbsp;<span data-i18n="Tabby model hint prefix"></span>
2723 <code>inline_model_loading: True</code>2723 <code>inline_model_loading: True</code>
2724 <span data-i18n="must be set in Tabby's config.yml to switch models.">2724 <span data-i18n="must be set in Tabby's config.yml to switch models.">
2725 must be set in Tabby's config.yml to switch models.2725 must be set in Tabby's config.yml to switch models.
@@ -2851,7 +2851,7 @@
2851 <input id="openai_reverse_proxy" type="text" class="text_pole" placeholder="https://api.openai.com/v1" />2851 <input id="openai_reverse_proxy" type="text" class="text_pole" placeholder="https://api.openai.com/v1" />
2852 <small class="reverse_proxy_warning">2852 <small class="reverse_proxy_warning">
2853 <span data-i18n="Doesn't work? Try adding">Doesn't work? Try adding</span> <code>/v1</code> <span data-i18n="at the end!">at the end!</span>2853 <span data-i18n="Doesn't work? Try adding">Doesn't work? Try adding</span> <code>/v1</code> <span data-i18n="at the end!">at the end!</span>
2854 <code>/chat/completions</code> <b data-i18n="suffix will be added automatically.">suffix will be added automatically.</b>2854 <span data-i18n="completions note prefix"></span><code>/chat/completions</code> <b data-i18n="suffix will be added automatically.">suffix will be added automatically.</b>
2855 </small>2855 </small>
2856 </div>2856 </div>
2857 <div class="range-block-title justifyLeft" data-i18n="Proxy Password">2857 <div class="range-block-title justifyLeft" data-i18n="Proxy Password">
@@ -3566,7 +3566,7 @@
3566 <div>3566 <div>
3567 <small>3567 <small>
3568 <span data-i18n="Doesn't work? Try adding">Doesn't work? Try adding</span> <code>/v1</code> <span data-i18n="at the end!">at the end!</span>3568 <span data-i18n="Doesn't work? Try adding">Doesn't work? Try adding</span> <code>/v1</code> <span data-i18n="at the end!">at the end!</span>
3569 <code>/chat/completions</code> <b data-i18n="suffix will be added automatically.">suffix will be added automatically.</b>3569 <b data-i18n="completions note prefix"></b><code>/chat/completions</code> <b data-i18n="suffix will be added automatically.">suffix will be added automatically.</b>
3570 </small>3570 </small>
3571 </div>3571 </div>
3572 <h4>3572 <h4>
@@ -4744,7 +4744,7 @@
4744 <input id="never_resize_avatars" type="checkbox" />4744 <input id="never_resize_avatars" type="checkbox" />
4745 <small data-i18n="Never resize avatars">Never resize avatars</small>4745 <small data-i18n="Never resize avatars">Never resize avatars</small>
4746 </label>4746 </label>
4747 <label for="background_thumbnails_animation" class="checkbox_label" title="Make animated backgrounds static in the selection menu. This will reduce UI and network lag if you have a large amount. This is only a change for the selection menu.">4747 <label data-i18n="[title]Make animated backgrounds static in the selection menu. This will reduce UI and network lag if you have a large amount. This is only a change for the selection menu." for="background_thumbnails_animation" class="checkbox_label" title="Make animated backgrounds static in the selection menu. This will reduce UI and network lag if you have a large amount. This is only a change for the selection menu.">
4748 <input id="background_thumbnails_animation" type="checkbox" />4748 <input id="background_thumbnails_animation" type="checkbox" />
4749 <small data-i18n="Animated background thumbnails">Animated background thumbnails</small>4749 <small data-i18n="Animated background thumbnails">Animated background thumbnails</small>
4750 </label>4750 </label>
public/locales/ru-ru.json+143 -4
@@ -105,7 +105,7 @@
105 "Adjust context size to worker capabilities": "Подстраивать размер контекста под возможности рабочих машин",105 "Adjust context size to worker capabilities": "Подстраивать размер контекста под возможности рабочих машин",
106 "Adjust response length to worker capabilities": "Подстраивать длину ответа под возможности рабочих машин",106 "Adjust response length to worker capabilities": "Подстраивать длину ответа под возможности рабочих машин",
107 "API key": "API-ключ",107 "API key": "API-ключ",
108 "Tabby API key": "Tabby API-ключ",108 "Tabby API key": "Ключ от Tabby API",
109 "Get it here:": "Получите здесь:",109 "Get it here:": "Получите здесь:",
110 "Register": "Зарегистрироваться",110 "Register": "Зарегистрироваться",
111 "TogetherAI Model": "Модель TogetherAI",111 "TogetherAI Model": "Модель TogetherAI",
@@ -275,7 +275,7 @@
275 "Chat History": "История чатов",275 "Chat History": "История чатов",
276 "Content": "Содержание",276 "Content": "Содержание",
277 "Selective": "Выборочно",277 "Selective": "Выборочно",
278 "Disable": "Отключено",278 "Disable": "Откл.",
279 "Back to parent chat": "Вернуться в основной чат",279 "Back to parent chat": "Вернуться в основной чат",
280 "Convert to group": "Сделать групповым",280 "Convert to group": "Сделать групповым",
281 "Start new chat": "Начать новый чат",281 "Start new chat": "Начать новый чат",
@@ -509,7 +509,7 @@
509 "Restore default prompt": "Восстановить станндартный промпт",509 "Restore default prompt": "Восстановить станндартный промпт",
510 "New preset": "Новый пресет",510 "New preset": "Новый пресет",
511 "Delete preset": "Удалить пресет",511 "Delete preset": "Удалить пресет",
512 "API Connections": "Соединения с API",512 "API Connections": "Соединение с API",
513 "Can help with bad responses by queueing only the approved workers. May slowdown the response time.": "Может помочь при плохих ответах, делая запросы только к доверенным рабочим машинам. Может замедлить время ответа.",513 "Can help with bad responses by queueing only the approved workers. May slowdown the response time.": "Может помочь при плохих ответах, делая запросы только к доверенным рабочим машинам. Может замедлить время ответа.",
514 "Clear your API key": "Стереть ключ от API",514 "Clear your API key": "Стереть ключ от API",
515 "Refresh models": "Обновить модели",515 "Refresh models": "Обновить модели",
@@ -2419,5 +2419,144 @@
2419 "Update enabled": "Обновить включенные",2419 "Update enabled": "Обновить включенные",
2420 "Could not connect to API": "Не удалось подключиться к API",2420 "Could not connect to API": "Не удалось подключиться к API",
2421 "Connected to API": "Соединение с API установлено",2421 "Connected to API": "Соединение с API установлено",
2422 "Go back": "Назад"2422 "Go back": "Назад",
2423 "Recent Chats": "Недавние чаты",
2424 "Docs": "Документация",
2425 "Temporary Chat": "Временный чат",
2426 "Load": "Загрузить",
2427 "Import from JSONL": "Импорт из формата JSONL",
2428 "**Hint:** Set any character as your welcome page assistant from their \"More...\" menu.": "**Подсказка**: задайте персонажа, который будет встречать вас на главной странице. Для этого зайдите в меню \"Ещё...\" в интерфейсе карточки.",
2429 "[The chat is empty]": "[Чат пуст]",
2430 "Show more recent chats": "Больше недавних чатов",
2431 "Show less recent chats": "Меньше недавних чатов",
2432 "Rename chat": "Переименовать чат",
2433 "Delete chat": "Удалить чат",
2434 "Hide recent chats": "Скрыть недавние чаты",
2435 "Show recent chats": "Показать недавние чаты",
2436 "Set / Unset as Welcome Page Assistant": "Установить / снять с роли помощника на экране приветствия",
2437 "${0} is a system assistant. Choose another character.": "Персонаж ${0} выбран в качестве системного помощника. Выберите другого.",
2438 "Set ${0} as your assistant.": "Персонаж ${0} установлен в качестве помощника.",
2439 "${0} is no longer your assistant.": "Персонаж ${0} снят с роли помощника.",
2440 "Manage API keys": "Управление ключами",
2441 "Key:": "Ключ:",
2442 "No secrets saved.": "Ключей нет.",
2443 "Add Secret": "Добавить ключ",
2444 "Enter the secret value:": "Ключ:",
2445 "Enter a label for the secret (optional):": "Название ключа (необязательно):",
2446 "Copy ID": "Копировать ID",
2447 "Rename Secret": "Переименовать ключ",
2448 "Enter new label for the secret:": "Новое название ключа:",
2449 "Delete Secret: ${0}": "Удалить ключ ${0}",
2450 "Are you sure you want to delete this secret? This action cannot be undone.": "Вы точно хотите удалить этот ключ? Отменить будет невозможно.",
2451 "Secret ID copied to clipboard.": "ID ключа скопирован в буфер обмена.",
2452 "The key exposure might be disabled by the server config.": "Вероятно, в настройках сервера отключена возможность раскрытия ключей.",
2453 "Failed to copy secret value": "Не удалось скопировать значение",
2454 "Select": "Выделить",
2455 "Allow compressing requests by removing messages from the middle of the prompt.": "Включает возможность сжатия запроса путём удаления сообщений из середины промпта.",
2456 "Allow": "Разрешить",
2457 "Forbid": "Запретить",
2458 "Auto": "Авто",
2459 "Max prompt cost:": "Макс. стоимость промпта:",
2460 "Unknown": "Неизвестно",
2461 "enable_functions_desc_4": "Не работает, если выбрана постобработка промпта с отключенными функциями!",
2462 "This setting affects visibility only.": "Влияет только на видимость.",
2463 "openrouter_web_search_fee": "Платная опция! Добавляет $0,02 к стоимости каждого промпта.",
2464 "prompt_post_processing_semi_tools": "Semi-strict (чередовать роли, функции включены)",
2465 "prompt_post_processing_strict_tools": "Strict (чередовать роли, сначала пользователь; функции включены)",
2466 "prompt_post_processing_single": "Только одно сообщение пользователя (функции отключены)",
2467 "prompt_post_processing_merge_tools": "Объединять идущие подряд сообщение с одной ролью (функции включены)",
2468 "completions note prefix": "Постфикс ",
2469 "suffix will be added automatically.": "будет добавлен автоматически.",
2470 "Tabby Model": "Модель Tabby",
2471 "Experimental feature. Use at your own risk.": "Экспериментальная возможность. Используйте на собственный риск.",
2472 "Tabby model hint prefix": "Чтобы иметь возможность менять модели на лету, укажите параметр ",
2473 "must be set in Tabby's config.yml to switch models.": " в файле config.yml на сервере Tabby.",
2474 "Use an admin API key.": "Используйте admin-ключ.",
2475 "Use OpenRouter website setting": "Использовать указанную на сайте OpenRouter",
2476 "Allocates a portion of the response length for thinking (min: 1024 tokens, low: 10%, medium: 25%, high: 50%, max: 95%), but minimum 1024 tokens. Auto does not request thinking.": "Отводит часть ответа под рассуждения (Минимальные: 10%, Обычные: 25%, Подробные: 50%, Максимальные: 95%), но минимум 1024 токена. При выборе значение Авто рассуждения не запрашиваются.",
2477 "Use system prompt": "Включить системный промпт",
2478 "Send inline videos": "Отправлять inline-видео",
2479 "video_inlining_hint_1": "Отправляет модели видео, если она поддерживает такую возможность. Чтобы прикрепить видео к чату, используйте на любом сообщении кнопку",
2480 "video_inlining_hint_2": "либо меню",
2481 "video_inlining_hint_3": ".",
2482 "video_inlining_hint_4": "Видео должно весить не более 20 Мб и длиться не дольше 1 минуты.",
2483 "Allocates a portion of the response length for thinking (Flash 2.5/Pro 2.5) (min: 0/128 tokens, low: 10%, medium: 25%, high: 50%, max: 24576/32768 tokens). Auto lets the model decide.": "Отводит часть ответа под рассуждения (Flash 2.5/Pro 2.5) (Минимальные: 0/128 токенов, Поверхностные: 10%, Обычные: 25%, Подробные: 50%, Максимальные: 24576/32768 токенов). При выборе значения Авто модель определяет объём самостоятельно.",
2484 "Google Vertex AI Configuration": "Настройки Google Vertex AI",
2485 "Authentication Mode": "Режим аутентификации:",
2486 "Express Mode (API Key)": "Express Mode (ключ от API)",
2487 "Full Version (Service Account)": "Полновесный (аккаунт на сервисе)",
2488 "Google Vertex AI API Key": "Ключ от Google Vertex AI",
2489 "Service Account Configuration": "Настройки аккаунта",
2490 "Region": "Регион",
2491 "Service Account JSON Content": "Данные аккаунта в формате JSON",
2492 "Validate JSON": "Провалидировать JSON",
2493 "View available regions and models": "Посмотреть список доступных регионов и моделей",
2494 "Click to Edit": "Редактирование по клику",
2495 "Click the message text in the chat log to edit it.": "Нажмите на текст сообщения в чате, чтобы приступить к редактированию.",
2496 "Rounded": "Закруглённые",
2497 "Notifications:": "Уведомления:",
2498 "Top Left": "Слева сверху",
2499 "Top Center": "Сверху по центру",
2500 "Top Right": "Справа сверху",
2501 "Bottom Left": "Снизу слева",
2502 "Bottom Center": "Снизу по центру",
2503 "Bottom Right": "Снизу справа",
2504 "Additional Matching Sources": "Доп. места для поиска",
2505 "Character Personality": "Резюме по личности персонажа",
2506 "Cap the number of entry activation recursions": "Макс. глубина рекурсии при активации записи другой записью",
2507 "Animated background thumbnails": "Статичное превью анимированных фонов",
2508 "Make animated backgrounds static in the selection menu. This will reduce UI and network lag if you have a large amount. This is only a change for the selection menu.": "Отключить анимацию фонов при их предпросмотре в меню выбора. Может помочь снизить объём лагов интерфейса и/или интернет-соединения. Затрагивает только меню выбора.",
2509 "Clean-Up": "Уборка",
2510 "Find and delete backups, unused chats, files, images, etc.": "Найти и удалить бэкапы, неиспользуемые чаты, файлы, картинки и т.д.",
2511 "Once deleted, the files will be gone forever!": "Восстановить удалённые файлы будет невозможно!",
2512 "Make sure to back up your data in advance.": "Перед удалением не забывайте делать копии.",
2513 "No results yet. Tap 'Scan' to start scanning.": "Пока ничего не найдено. Нажмите \"Начать сканирование\", чтобы запустить процесс поиска.",
2514 "Scan": "Начать сканирование",
2515 "Chats": "Чаты",
2516 "Chat files associated with deleted characters.": "Чаты с удалёнными персонажами.",
2517 "Group Chats": "Групповые чаты",
2518 "Chat files associated with deleted groups.": "Чаты с удалёнными группами.",
2519 "Chat Backups": "Копии чатов",
2520 "Automatically generated chat backups.": "Автоматически создаваемые бэкапы чатов.",
2521 "Settings Backups": "Копии настроек",
2522 "Automatically generated settings backups.": "Автоматически создаваемые бэкапы настроек.",
2523 "Delete all items in this category": "Удалить всё в этой категории",
2524 "View item content": "Посмотреть содержимое",
2525 "Download item": "Скачать содержимое",
2526 "Delete this item": "Удалить содержимое",
2527 "This will permanently delete the file. THIS CANNOT BE UNDONE!": "Файл будет удалён навсегда. ОТМЕНИТЬ БУДЕТ НЕВОЗМОЖНО!",
2528 "This will permanently delete all files in this category. THIS CANNOT BE UNDONE!": "Все файлы в этой категории будут удалены. ОТМЕНИТЬ БУДЕТ НЕВОЗМОЖНО!",
2529 "Close popup": "Закрыть окно",
2530 "Branch or tag name (optional)": "Ветка или тэг (необязательно)",
2531 "ext_regex_bulk_edit": "Массовое редактирование",
2532 "Enable": "Вкл.",
2533 "Provided free of charge by Pollinations.AI": "Предоставляется бесплатно сервисом Pollinations.AI",
2534 "Avoid sending sensitive information. Provider's outputs may include ads.": "Не отправляйте чувствительную информацию. Тексты от провайдера могут содержать рекламу.",
2535 "Pollinations Model": "Модель Pollinations",
2536 "Character details are hidden.": "Информация о персонаже скрыта.",
2537 "Allow / Forbid the use of global styles for this character.": "Разрешить/запретить использование персонажем глобальных стилей.",
2538 "Choose how to apply CSS style tags if they are defined in Creator's Notes of this character:": "Выберите, к чему применять CSS-теги, объявленные в Заметках создателя у этого персонажа:",
2539 "CAUTION: Malformed styles may cause issues.": "ОСТОРОЖНО: некорректно размеченные стили могут приводить к неожиданному поведению.",
2540 "Just to Creator's Notes": "Только к Заметкам создателя",
2541 "Apply to the entire app": "Ко всему приложению",
2542 "Pin greeting message styles": "CSS из первого сообщения активен всегда",
2543 "Always render style tags from greetings, even if the message is unloaded due to lazy loading.": "Всегда учитывать CSS-стили из первого сообщения, даже если оно на данный момент скрыто механизмом ленивой загрузки.",
2544 "Secret": "Ключ",
2545 "Save and connect": "Сохранить и подключиться",
2546 "No scripts found": "Скриптов нет",
2547 "Are you sure you want to delete this regex script?": "Вы точно хотите удалить этот скрипт?",
2548 "Are you sure you want to move this regex script to scoped?": "Вы точно хотите сделать этот скрипт локальным?",
2549 "Cannot edit scoped scripts in group chats.": "Локальные скрипты невозможно редактировать в групповом чате.",
2550 "No character selected.": "Не выбран персонаж.",
2551 "Are you sure you want to move this regex script to global?": "Вы точно хотите сделать этот скрипт глобальным?",
2552 "Could not save regex script: The script name was undefined or empty!": "Не удалось сохранить regex-скрипт: Не указано либо не определено название скрипта!",
2553 "This regex script will not work, but was saved anyway: A find regex isn't present.": "Этот regex не будет работать, но всё равно сохранён: Не указано рег. выражение для поиска",
2554 "Ephemerality": "Иллюзорность",
2555 "This regex script will not work, but was saved anyway: One \"Affects\" checkbox must be selected!": "Этот regex не будет работать, но всё равно сохранён: Должна быть отмечена хотя бы одна галочка в блоке \"Затрагивает\"!",
2556 "This character has embedded regex script(s).": "У этого персонажа имеются встроенные regex скрипты.",
2557 "Would you like to allow using them?": "Должны ли они продолжать работу?",
2558 "If you want to do it later, select 'Regex' from the extensions menu.": "Если захотите включить их позже, выберите в меню расширений пункт \"Regex\".",
2559 "Are you sure you want to delete the selected regex scripts?": "Вы точно хотите удалить выбранные скрипты?",
2560 "Regex script \"${0}\" imported.": "Успешно импортирован скрипт ${0}",
2561 "Invalid regex object.": "Некорректный объект рег. выражения."
2423}2562}
public/script.js+12 -10
@@ -673,16 +673,8 @@ export const extension_prompt_roles = {
673673
674export const MAX_INJECTION_DEPTH = 10000;674export const MAX_INJECTION_DEPTH = 10000;
675675
676const SAFETY_CHAT = [676// Initialized in getSystemMessages()
677 {677const SAFETY_CHAT = [];
678 name: systemUserName,
679 force_avatar: system_avatar,
680 is_system: true,
681 is_user: false,
682 create_date: 0,
683 mes: 'You deleted a character/chat and arrived back here for safety reasons! Pick another character!',
684 },
685];
686678
687export let system_messages = {};679export let system_messages = {};
688680
@@ -769,6 +761,16 @@ async function getSystemMessages() {
769 },761 },
770 },762 },
771 };763 };
764
765 const safetyMessage = {
766 name: systemUserName,
767 force_avatar: system_avatar,
768 is_system: true,
769 is_user: false,
770 create_date: 0,
771 mes: t`You deleted a character/chat and arrived back here for safety reasons! Pick another character!`,
772 };
773 SAFETY_CHAT.splice(0, SAFETY_CHAT.length, safetyMessage);
772}774}
773775
774async function getClientVersion() {776async function getClientVersion() {
public/scripts/extensions/assets/index.js+5 -5
@@ -53,11 +53,11 @@ function filterAssets() {
53}53}
5454
55const KNOWN_TYPES = {55const KNOWN_TYPES = {
56 'extension': 'Extensions',56 'extension': t`Extensions`,
57 'character': 'Characters',57 'character': t`Characters`,
58 'ambient': 'Ambient sounds',58 'ambient': t`Ambient sounds`,
59 'bgm': 'Background music',59 'bgm': t`Background music`,
60 'blip': 'Blip sounds',60 'blip': t`Blip sounds`,
61};61};
6262
63async function downloadAssetsList(url) {63async function downloadAssetsList(url) {
public/scripts/extensions/regex/dropdown.html+2 -2
@@ -53,7 +53,7 @@
53 <small data-i18n="ext_regex_global_scripts_desc">53 <small data-i18n="ext_regex_global_scripts_desc">
54 Available for all characters. Saved to local settings.54 Available for all characters. Saved to local settings.
55 </small>55 </small>
56 <div id="saved_regex_scripts" class="flex-container regex-script-container flexFlowColumn"></div>56 <div id="saved_regex_scripts" no-scripts-text="No scripts found" data-i18n="[no-scripts-text]No scripts found" class="flex-container regex-script-container flexFlowColumn"></div>
57 </div>57 </div>
58 <hr />58 <hr />
59 <div id="scoped_scripts_block" class="padding5">59 <div id="scoped_scripts_block" class="padding5">
@@ -68,7 +68,7 @@
68 <small data-i18n="ext_regex_scoped_scripts_desc">68 <small data-i18n="ext_regex_scoped_scripts_desc">
69 Only available for this character. Saved to the card data.69 Only available for this character. Saved to the card data.
70 </small>70 </small>
71 <div id="saved_scoped_scripts" class="flex-container regex-script-container flexFlowColumn"></div>71 <div id="saved_scoped_scripts" no-scripts-text="No scripts found" data-i18n="[no-scripts-text]No scripts found" class="flex-container regex-script-container flexFlowColumn"></div>
72 </div>72 </div>
73 </div>73 </div>
74 </div>74 </div>
public/scripts/extensions/regex/editor.html+1 -1
@@ -146,7 +146,7 @@
146 </select>146 </select>
147 </label>147 </label>
148 <span>148 <span>
149 <small data-i18n="ext_regex_other_options" data-i18n="Ephemerality">Ephemerality</small>149 <small data-i18n="Ephemerality">Ephemerality</small>
150 <span class="fa-solid fa-circle-question note-link-span" data-i18n="[title]ext_regex_other_options_desc" title="By default, regex scripts alter the chat file directly and irreversibly.&#13;Enabling either (or both) of the options below will prevent chat file alteration, while still altering the specified item(s)."></span>150 <span class="fa-solid fa-circle-question note-link-span" data-i18n="[title]ext_regex_other_options_desc" title="By default, regex scripts alter the chat file directly and irreversibly.&#13;Enabling either (or both) of the options below will prevent chat file alteration, while still altering the specified item(s)."></span>
151 </span>151 </span>
152 <label class="checkbox flex-container" data-i18n="[title]ext_regex_only_format_visual_desc" title="Chat history file contents won't change, but regex will be applied to the messages displayed in the Chat UI.">152 <label class="checkbox flex-container" data-i18n="[title]ext_regex_only_format_visual_desc" title="Chat history file contents won't change, but regex will be applied to the messages displayed in the Chat UI.">
public/scripts/extensions/regex/embeddedScripts.html+3 -3
@@ -1,5 +1,5 @@
1<div>1<div>
2 <h3>This character has embedded regex script(s).</h3>2 <h3 data-i18n="This character has embedded regex script(s).">This character has embedded regex script(s).</h3>
3 <h3>Would you like to allow using them?</h3>3 <h3 data-i18n="Would you like to allow using them?">Would you like to allow using them?</h3>
4 <div class="m-b-1">If you want to do it later, select "Regex" from the extensions menu.</div>4 <div class="m-b-1" data-i18n="If you want to do it later, select 'Regex' from the extensions menu.">If you want to do it later, select "Regex" from the extensions menu.</div>
5</div>5</div>
public/scripts/extensions/regex/index.js+14 -14
@@ -45,18 +45,18 @@ async function saveRegexScript(regexScript, existingScriptIndex, isScoped) {
4545
46 // Is the script name undefined or empty?46 // Is the script name undefined or empty?
47 if (!regexScript.scriptName) {47 if (!regexScript.scriptName) {
48 toastr.error('Could not save regex script: The script name was undefined or empty!');48 toastr.error(t`Could not save regex script: The script name was undefined or empty!`);
49 return;49 return;
50 }50 }
5151
52 // Is a find regex present?52 // Is a find regex present?
53 if (regexScript.findRegex.length === 0) {53 if (regexScript.findRegex.length === 0) {
54 toastr.warning('This regex script will not work, but was saved anyway: A find regex isn\'t present.');54 toastr.warning(t`This regex script will not work, but was saved anyway: A find regex isn't present.`);
55 }55 }
5656
57 // Is there someplace to place results?57 // Is there someplace to place results?
58 if (regexScript.placement.length === 0) {58 if (regexScript.placement.length === 0) {
59 toastr.warning('This regex script will not work, but was saved anyway: One "Affects" checkbox must be selected!');59 toastr.warning(t`This regex script will not work, but was saved anyway: One "Affects" checkbox must be selected!`);
60 }60 }
6161
62 if (existingScriptIndex !== -1) {62 if (existingScriptIndex !== -1) {
@@ -139,7 +139,7 @@ async function loadRegexScripts() {
139 await onRegexEditorOpenClick(scriptHtml.attr('id'), isScoped);139 await onRegexEditorOpenClick(scriptHtml.attr('id'), isScoped);
140 });140 });
141 scriptHtml.find('.move_to_global').on('click', async function () {141 scriptHtml.find('.move_to_global').on('click', async function () {
142 const confirm = await callGenericPopup('Are you sure you want to move this regex script to global?', POPUP_TYPE.CONFIRM);142 const confirm = await callGenericPopup(t`Are you sure you want to move this regex script to global?`, POPUP_TYPE.CONFIRM);
143143
144 if (!confirm) {144 if (!confirm) {
145 return;145 return;
@@ -150,16 +150,16 @@ async function loadRegexScripts() {
150 });150 });
151 scriptHtml.find('.move_to_scoped').on('click', async function () {151 scriptHtml.find('.move_to_scoped').on('click', async function () {
152 if (this_chid === undefined) {152 if (this_chid === undefined) {
153 toastr.error('No character selected.');153 toastr.error(t`No character selected.`);
154 return;154 return;
155 }155 }
156156
157 if (selected_group) {157 if (selected_group) {
158 toastr.error('Cannot edit scoped scripts in group chats.');158 toastr.error(t`Cannot edit scoped scripts in group chats.`);
159 return;159 return;
160 }160 }
161161
162 const confirm = await callGenericPopup('Are you sure you want to move this regex script to scoped?', POPUP_TYPE.CONFIRM);162 const confirm = await callGenericPopup(t`Are you sure you want to move this regex script to scoped?`, POPUP_TYPE.CONFIRM);
163163
164 if (!confirm) {164 if (!confirm) {
165 return;165 return;
@@ -174,7 +174,7 @@ async function loadRegexScripts() {
174 download(fileData, fileName, 'application/json');174 download(fileData, fileName, 'application/json');
175 });175 });
176 scriptHtml.find('.delete_regex').on('click', async function () {176 scriptHtml.find('.delete_regex').on('click', async function () {
177 const confirm = await callGenericPopup('Are you sure you want to delete this regex script?', POPUP_TYPE.CONFIRM);177 const confirm = await callGenericPopup(t`Are you sure you want to delete this regex script?`, POPUP_TYPE.CONFIRM);
178178
179 if (!confirm) {179 if (!confirm) {
180 return;180 return;
@@ -483,10 +483,10 @@ async function onRegexImportObjectChange(regexScript, isScoped) {
483483
484 saveSettingsDebounced();484 saveSettingsDebounced();
485 await loadRegexScripts();485 await loadRegexScripts();
486 toastr.success(`Regex script "${regexScript.scriptName}" imported.`);486 toastr.success(t`Regex script "${regexScript.scriptName}" imported.`);
487 } catch (error) {487 } catch (error) {
488 console.log(error);488 console.log(error);
489 toastr.error('Invalid regex object.');489 toastr.error(t`Invalid regex object.`);
490 return;490 return;
491 }491 }
492}492}
@@ -578,12 +578,12 @@ jQuery(async () => {
578 });578 });
579 $('#open_scoped_editor').on('click', function () {579 $('#open_scoped_editor').on('click', function () {
580 if (this_chid === undefined) {580 if (this_chid === undefined) {
581 toastr.error('No character selected.');581 toastr.error(t`No character selected.`);
582 return;582 return;
583 }583 }
584584
585 if (selected_group) {585 if (selected_group) {
586 toastr.error('Cannot edit scoped scripts in group chats.');586 toastr.error(t`Cannot edit scoped scripts in group chats.`);
587 return;587 return;
588 }588 }
589589
@@ -707,12 +707,12 @@ jQuery(async () => {
707707
708 $('#regex_scoped_toggle').on('input', function () {708 $('#regex_scoped_toggle').on('input', function () {
709 if (this_chid === undefined) {709 if (this_chid === undefined) {
710 toastr.error('No character selected.');710 toastr.error(t`No character selected.`);
711 return;711 return;
712 }712 }
713713
714 if (selected_group) {714 if (selected_group) {
715 toastr.error('Cannot edit scoped scripts in group chats.');715 toastr.error(t`Cannot edit scoped scripts in group chats.`);
716 return;716 return;
717 }717 }
718718
public/scripts/extensions/regex/style.css+1 -1
@@ -15,7 +15,7 @@
15}15}
1616
17.regex-script-container:empty::after {17.regex-script-container:empty::after {
18 content: "No scripts found";18 content: attr(no-scripts-text);
19 font-size: 0.95em;19 font-size: 0.95em;
20 opacity: 0.7;20 opacity: 0.7;
21 display: block;21 display: block;
public/scripts/openai.js+1 -1
@@ -1956,7 +1956,7 @@ function saveModelList(data) {
1956}1956}
19571957
1958function appendOpenRouterOptions(model_list, groupModels = false, sort = false) {1958function appendOpenRouterOptions(model_list, groupModels = false, sort = false) {
1959 $('#model_openrouter_select').append($('<option>', { value: openrouter_website_model, text: 'Use OpenRouter website setting' }));1959 $('#model_openrouter_select').append($('<option>', { value: openrouter_website_model, text: t`Use OpenRouter website setting` }));
19601960
1961 const appendOption = (model, parent = null) => {1961 const appendOption = (model, parent = null) => {
1962 (parent || $('#model_openrouter_select')).append(1962 (parent || $('#model_openrouter_select')).append(