first commit

This commit is contained in:
Noor E Ilahi
2026-01-09 12:54:53 +05:30
commit 7ccf44f7da
1070 changed files with 113036 additions and 0 deletions

View File

@@ -0,0 +1,74 @@
import Vue from 'vue';
import VueI18n from 'vue-i18n';
import { getModuleList, ModuleLoaderInterceptor } from '@/moduleLoader';
import merge from 'lodash/merge';
import veeValidateEn from 'vee-validate/dist/locale/en.json';
import veeValidateRu from 'vee-validate/dist/locale/ru.json';
import moment from 'moment';
import * as Sentry from '@sentry/vue';
export function getLangCookie() {
const v = document.cookie.match('(^|;) ?lang=([^;]*)(;|$)');
return v ? v[2] : null;
}
// Set root domain cookie, ex: *.cattr.app
export function setLangCookie(lang) {
const rootDomain = location.hostname.split('.').reverse().splice(0, 2).reverse().join('.');
document.cookie = 'lang=' + lang + '; domain=' + rootDomain;
}
// Get the browser language
export function getUserLang() {
return typeof navigator.language !== 'undefined' && navigator.language.length
? navigator.language.substring(0, 2).toLowerCase()
: 'en';
}
Vue.use(VueI18n);
let messages = {
en: require('./locales/en'),
ru: require('./locales/ru'),
};
let pluralizationRules = {};
ModuleLoaderInterceptor.on('loaded', () => {
const modules = Object.values(getModuleList()).map(i => {
return i.moduleInstance;
});
modules.forEach(m => {
const moduleMessages = m.getLocalizationData();
merge(messages, moduleMessages);
merge(pluralizationRules, m.getPluralizationRules());
});
});
merge(messages, {
en: {
validation: veeValidateEn.messages,
},
ru: {
validation: veeValidateRu.messages,
},
});
merge(pluralizationRules, require('./pluralizationRules'));
const locale = getLangCookie() || getUserLang();
Sentry.setTag('locale', locale);
moment.locale(locale);
const i18n = new VueI18n({
locale: locale,
fallbackLocale: 'en',
silentFallbackWarn: true,
messages,
pluralizationRules,
});
export default i18n;

View File

@@ -0,0 +1,462 @@
{
"navigation": {
"about": "About",
"settings": "Settings",
"client-login": "Desktop app login",
"company_settings": "Company Settings",
"logout": "Logout",
"dropdown": {
"reports": "Reports",
"projects": "Projects"
}
},
"setup": {
"process": {
"info_without_docker": "Please, change your server's settings according to examples below. Note, that you should replace paths with the path to your Cattr installed.",
"important_information": "Important information",
"title_supervisor": "Supervisor configuration",
"title_cron": "Cron configuration",
"end_install": "Start use Cattr",
"button_process": "Installing",
"config_confirmation": "The required configuration files are changed accordingly",
"title": "Cattr install",
"subtitle": "Please, do not close or reload this tab until the installation is completed"
},
"step_description": {
"welcome": "Welcome",
"database_settings": "Database configuration",
"mail_settings": "Mail configuration",
"company_settings": "Company configuration",
"account": "Create account",
"permission": "Permissions",
"backend_ping": "Connection to backend server",
"recaptcha": "reCAPTCHA configuration"
},
"buttons": {
"next": "Next",
"back": "Back",
"complete": "Complete",
"update": "Update",
"connect": "Connect to database",
"checked": "Enabled",
"unchecked": "Disabled"
},
"header": {
"welcome": {
"title": "Welcome to Cattr",
"subtitle": "This is a quick setup",
"language": "Please, select your company language"
},
"backend_ping": {
"title": "Connection to backend server",
"subtitle": "Checking the connection with your Cattr backend server",
"success": "Success",
"error": "Connection refused",
"process": "Processing",
"status": "Backend status",
"server_url": "Trying to find the server at: {serverUrl}",
"wrong_url": "Wrong url?",
"building_when": "URL should be set up on frontend building",
"read_more": "You can read more in {0}",
"documentation": "documentation"
},
"database_settings": {
"title": "Database configuration",
"subtitle": "Set MySQL configuration",
"success": "Success",
"error": "Wrong params",
"process": "Wait process",
"host": "Host",
"database": "Database name",
"username":"User name",
"password":"Password",
"status": "Database status",
"docker_title": "Cattr is running inside the official Docker container",
"docker_subtitle": "You do not need to adjust database connection settings"
},
"mail_settings": {
"title": "Mail configuration",
"subtitle": "Set mail settings",
"email": "E-mail",
"password": "Password",
"host": "Server address",
"port": "Port",
"encryption": "Encryption"
},
"company_settings": {
"title": "Company settings",
"subtitle": "Set company settings",
"language": "Language",
"timezone": "Timezone"
},
"account": {
"title": "Admin account settings",
"subtitle": "Create admin account",
"email": "E-mail",
"password": "Password"
},
"permission": {
"title": "Permission",
"subtitle": "Give permission",
"registration_process": "Wait until the registration process is completed",
"registration": "Registration"
},
"recaptcha": {
"title": "reCAPTCHA settings",
"subtitle": "Connect reCAPTCHA to protect user accounts from password attacks",
"get_recaptcha": "Get reCAPTCHA keys"
}
}
},
"auth": {
"submit": "Login",
"forgot_password": "Forgot password?",
"message": {
"user_not_found": "We can't find the user with provided credentials",
"solve_captcha": "You must resolve a CAPTCHA",
"auth_error": "Authorization error",
"data_reset": "Data is flushing right now, please wait a minute and try again"
},
"desktop": {
"header": "Desktop application login",
"step": "Step {n}",
"step1": "Transferring data",
"step2": "Opening application",
"retry": "Retry",
"cancel": "Cancel",
"open": "Open application",
"finish": "Finish",
"error": "The desktop application is not installed on your PC",
"download": "You can download it {0}",
"download_button": "here"
},
"switch_to_common": "Log in with password",
"close": "Close page",
"desktop_error": "Error happened during authorization",
"desktop_working": "Authorizing"
},
"reset": {
"forgot_password": "Forgot password?",
"reset_password": "Reset password",
"confirm_password": "Confirm password",
"step": "Step {n}",
"step_description": {
"step_1": "Enter email",
"step_2": "Check your email",
"step_3": "Enter new password",
"step_4": "Enjoy"
},
"tabs": {
"enter_email": {
"title": "Forgot password?",
"subtitle": "Enter your email and we will send a link to reset your password"
},
"check_email": {
"title": "Check your email",
"subtitle": "Check your email, and follow the link in the password reset email to complete the process"
},
"new_password": {
"title": "Enter new password",
"subtitle": "Password must be at least 6 characters"
},
"success": {
"title": "Success",
"subtitle": "Your password has been successfully changed"
}
},
"page_is_not_available": "This page is no longer available",
"go_away": "Go to login page"
},
"register": {
"title": "Register",
"subtitle": "Please fill out the fields to confirm your registration",
"register_btn": "Create account",
"success_title": "Account was created successfully",
"success_subtitle": "Go to the login page to log in to your account"
},
"settings": {
"account": "Account",
"general": "General",
"language": "Language",
"company": "Company",
"company_timezone": "Company timezone"
},
"control": {
"save": "Save",
"create": "Create",
"view": "View",
"edit": "Edit",
"delete": "Delete",
"add": "Add",
"yes": "Yes",
"no": "No",
"back": "Back",
"submit": "Submit",
"deselect_all": "Deselect All",
"select_all": "Select All",
"clear_all": "Clear All",
"select_all_open": "Select All Open",
"select_all_closed": "Select All Closed",
"user_selected": "No users selected | 1 user selected | {count} users selected",
"element_selected": "No elements selected | 1 element selected | {count} elements selected",
"project_selected": "No projects selected | 1 project selected | {count} projects selected",
"project_selected_all": "All projects selected",
"status_selected": "No statuses selected | 1 status selected | {count} statuses selected",
"status_selected_all": "All statuses selected",
"screenshot_state_options": {
"required": "Required",
"optional": "Optional",
"forbidden": "Forbidden"
},
"day": "Day",
"week": "Week",
"month": "Month",
"range": "Range",
"today": "Today",
"ok": "Ok",
"active": "Active",
"inactive": "Inactive",
"search": "Search",
"add_time": "Add time",
"enable": "Enable",
"disable": "Disable",
"select": "Select",
"cancel": "Cancel",
"reset": "Reset",
"show_active": "Show active tasks"
},
"field": {
"password": "Password",
"name": "Name",
"full_name": "Name",
"status": "Status",
"email": "E-mail",
"user": "User",
"users": "Users",
"active": "Active",
"change_password": "Change password",
"screenshot": "Screenshot",
"screenshots": "Screenshots",
"manual_time": "Manual Time",
"screenshots_interval": "Screenshots Interval",
"computer_time_popup": "Inactivity Time Popup",
"timezone": "Timezone",
"default_role": "Default Role",
"project_roles": "Project Roles",
"task": "Task",
"tasks": "Tasks",
"project": "Project",
"projects": "Projects",
"priority": "Priority",
"created_at": "Created",
"updated_at": "Last edit",
"team": "Team",
"amount_of_tasks": "Amount of tasks",
"description": "Description",
"important": "Important",
"actions": "Actions",
"start_at": "Start at",
"end_at": "End at",
"expires_at": "Expires at",
"role": "Role",
"user_language": "User Language",
"send_invite": "Send invite",
"selected": "Selected",
"total": "Total",
"total_time": "Total time",
"total_spent": "Total Spent Time",
"time": "Time",
"auto_thin": "Automatic storage cleanup",
"screenshots_state": "Enable screenshots",
"members": "Members",
"url": "URL",
"efficiency": "Employee efficiency ratio",
"statuses": {
"any": "Any",
"active": "Active",
"disabled": "Disabled"
},
"roles": {
"admin": {
"name": "Admin",
"description": "Full access to everything"
},
"manager": {
"name": "Manager",
"description": "Full access to tasks, projects, screenshot and all users' activity"
},
"auditor": {
"name": "Auditor",
"description": "Read access to projects, create and read access to all the tasks, access to all users activity"
},
"user": {
"name": "User",
"description": "Read access to assigned projects, create and view tasks, view personal activity"
},
"any": "Any"
},
"type": "Type",
"types": {
"all": "All",
"any": "Any",
"employee": "Employee",
"client": "Client"
},
"work_time": "Working Hours",
"notice": "Notice",
"report": "Report",
"minutes": "{value} minutes",
"duration": "Duration",
"duration_value": "{0} to {1}",
"web_and_app_monitoring": "Enable app monitoring",
"parent_group": "Parent group"
},
"filter": {
"enter-single": "Enter {0}",
"enter-multiple": "Enter {0} or {1}",
"fields": {
"task_name": "task name",
"project_name": "project name",
"full_name": "full name",
"name": "name",
"email": "e-mail",
"url": "URL"
},
"full_name": "Filter by full name",
"email": "Filter by e-mail",
"task": "Filter by task name",
"project": "Filter by project name"
},
"message": {
"no_data": "No data to display",
"page_not_found": "The page you're looking for doesn't exist",
"api_error": "Looks like we have temporal problems, contact your administrator about that :(",
"page_forbidden": "Access denied",
"field_is_required": "This field is required",
"something_went_wrong": "Something went wrong",
"success": "Success",
"error": "Error",
"vulnerable_version": "You are using an outdated app version, please update to the latest one",
"update_version": "New version is available",
"report_has_been_queued": "Report has been queued and will be sent on your email"
},
"time": {
"d": "d",
"h": "h",
"m": "m",
"s": "s"
},
"tooltip": {
"task_important": "Related screenshots should not be deleted automatically",
"user_change_password": "Makes the password change on the first login mandatory",
"user_manual_time": "Allow users to manually add time",
"user_send_invite": "Email user the account's credentials. If \"Password\" field is not filled in, an email with an auto-generated password will be sent in any case ",
"user_computer_time_popup": "User's inactivity time in minutes before 'inactivity detected' modal pops up",
"user_interval_screenshot": "Screenshot creation time interval in minutes",
"color_intervals": "Lets you select colors for clocked-in time intervals from 0 to 100%",
"work_time": "Minimum amount of working hours/day",
"auto_thin": "Old screenshots will be deleted automatically",
"activity_progress": {
"not_tracked": "No activity tracked",
"overall": "Overall activity: | Overall activity: 1% | Overall activity: {percent}%",
"mouse": "Mouse: 0% | Mouse: 1% | Mouse: {percent}%",
"keyboard": "Keyboard: 0% | Keyboard: 1% | Keyboard: {percent}%",
"just_mouse": "Mouse:",
"just_keyboard": "Keyboard:"
}
},
"invite": {
"resend": "Resend invite"
},
"about": {
"modules": {
"name": "Module",
"version": "Version",
"status": "Status",
"vulnerable": "Vulnerable",
"ok": "Up to date",
"outdated": "Out of date"
},
"module_versions": "Module versions",
"module_storage": "Storage",
"no_modules": "No modules installed",
"no_storage": "No info about storage",
"storage": {
"last_thinning": "Last cleanup was",
"space": {
"left": "Free space",
"total": "Total space",
"used": "Space used"
},
"screenshots_available": "Can be removed",
"screenshots": "0 screenshots | {n} screenshot | {n} screenshots",
"thin_unavailable": "Cleanup is unavailable at this moment",
"thin_available": "Cleanup is available",
"thin": "Cleanup space"
}
},
"notification": {
"save": {
"success": {
"title": "Success",
"message": "Saved successfully"
},
"error": {
"title": "Error",
"message": "Failed to save"
}
},
"record": {
"save": {
"success": {
"title": "Success",
"message": "Record was saved successfully"
}
},
"delete": {
"confirmation": {
"title": "Delete record?",
"message": "Are you sure you want delete this record?"
},
"success": {
"title": "Success",
"message": "Record was successfully deleted"
},
"error": {
"title": "Error",
"message": "Failed to destroy the report"
}
}
},
"settings": {
"save": {
"success": {
"title": "Success",
"message": "Settings were saved successfully"
}
}
},
"screenshot": {
"save": {
"success": {
"title": "Success",
"message": "Screenshots were saved successfully"
},
"error": {
"title": "Error",
"message": "Failed to save the screenshots"
}
},
"delete": {
"success": {
"title": "Success",
"message": "Screenshots were successfully deleted"
},
"error": {
"title": "Error",
"message": "Failed to remove the screenshots"
}
}
}
}
}

View File

@@ -0,0 +1,461 @@
{
"navigation": {
"about": "О приложении",
"client-login": "Войти в приложение",
"settings": "Настройки",
"company_settings": "Настройки компании",
"logout": "Выход",
"dropdown": {
"reports": "Отчеты",
"projects": "Проекты"
}
},
"setup": {
"process": {
"info_without_docker": "Внесите изменения в файлы конфигурации для корректной работы сервиса. Обратите внимание, что пути нужно заменить на актуальные для вашего оборудования.",
"important_information": "Важная информация",
"title_supervisor": "Настройка аккаунта Supervisor",
"title_cron": "Конфигурация планировщика задач",
"end_install": "Начать пользоваться Cattr",
"button_process": "Установка...",
"config_confirmation": "Изменения в конфигурацию внесены",
"title": "Установка началась",
"subtitle": "Не закрывайте и не перезагружайте эту вкладку до окончания установки"
},
"step_description": {
"welcome": "Приветствие",
"database_settings": "Настройка базы данных",
"mail_settings": "Настройка почты",
"company_settings": "Настройка параметров компании",
"account": "Настройки аккаунта",
"permission": "Доступы",
"backend_ping": "Подключение к серверу",
"recaptcha": "Настройка reCAPTCHA"
},
"buttons": {
"next": "Дальше",
"back": "Назад",
"complete": "Завершить",
"update": "Обновить",
"connect": "Проверить соединение с базой данных",
"checked": "Включено",
"unchecked": "Выключено"
},
"header": {
"welcome": {
"title": "Добро пожаловать в Cattr",
"subtitle": "Вас приветствует мастер первоначальной установки",
"language": "Выберите язык вашей компании"
},
"backend_ping": {
"title": "Подключение к серверу",
"subtitle": "Проверка подключения к серверу",
"success": "Сервер найден",
"error": "Сервер не найден",
"process": "Проверяю...",
"status": "Статус сервера",
"server_url": "Подключение к серверу будет осуществляться по адресу: {serverUrl}",
"wrong_url": "Неправильный URL-адрес?",
"building_when": "Адрес задается при сборке",
"read_more": "Подробнее можно прочитать в {0}",
"documentation": "документации"
},
"database_settings": {
"title": "Настройка базы данных",
"subtitle": "Задайте настройки базы данных MySQL",
"success": "Подключено",
"error": "Некорректные данные",
"process": "Проверяю...",
"host": "Хост",
"database": "Название базы данных",
"username":"Имя пользователя",
"password":"Пароль",
"status": "Статус базы данных",
"docker_title": "Cattr будет запущен в официальном docker-контейнере",
"docker_subtitle": "Вам не требуется задавать параметры подключения к базе данных"
},
"mail_settings": {
"title": "Настройка почты",
"subtitle": "Задайте настройки почты",
"email": "Почта",
"password": "Пароль",
"host": "Адрес сервера",
"port": "Порт",
"encryption": "Шифрование"
},
"company_settings": {
"title": "Настройка компании",
"subtitle": "Задайте настройки компании",
"timezone": "Часовой пояс"
},
"account": {
"title": "Настройки аккаунта",
"subtitle": "Создайте аккаунта админа",
"email": "Почта",
"password": "Пароль"
},
"permission": {
"title": "Доступы",
"subtitle": "Дать доступ",
"registration_process": "Ожидайте процесса регистрации",
"registration": "Регистрация"
},
"recaptcha": {
"title": "Настройка reCAPTCHA",
"subtitle": "Подключите reCAPTCHA для защиты пользовательских аккаунтов от попыток взлома",
"get_recaptcha": "Получить ключи для reCAPTCHA"
}
}
},
"auth": {
"submit": "Войти",
"forgot_password": "Забыли пароль?",
"message": {
"user_not_found": "Пользователь с таким паролем не найден",
"solve_captcha": "Вы должны решить CAPTCHA",
"auth_error": "Ошибка авторизации",
"data_reset": "Данные сбрасываются, пожалуйста, подождите немного и попробуйте снова"
},
"desktop": {
"header": "Вход в клиентское приложение Cattr",
"step": "{n} шаг",
"step1": "Передаю данные",
"step2": "Открываю приложение",
"retry": "Попробовать еще раз",
"cancel": "Отменить",
"open": "Открыть приложение",
"finish": "Готово",
"error": "Похоже, Вы не установили клиентское приложение",
"download": "Вы можете скачать его {0}",
"download_button": "здесь"
},
"switch_to_common": "Войти с паролем",
"close": "Закрыть страницу",
"desktop_error": "В процессе авторизации произошла ошибка",
"desktop_working": "Авторизация"
},
"reset": {
"forgot_password": "Забыли пароль?",
"reset_password": "Восстановить пароль",
"confirm_password": "Подтверждение пароля",
"step": "Шаг {n}",
"step_description": {
"step_1": "Введите email",
"step_2": "Проверьте правильность email",
"step_3": "Введите новый пароль",
"step_4": "Успешно"
},
"tabs": {
"enter_email": {
"title": "Забыли пароль?",
"subtitle": "Введите адрес электронной почты, и мы вышлем на него ссылку для восстановления пароля"
},
"check_email": {
"title": "Проверьте почту",
"subtitle": "Проверьте правильность своей электронной почты и перейдите по ссылке в письме, чтобы завершить процесс"
},
"new_password": {
"title": "Введите новый пароль",
"subtitle": "Пароль должен содержать не менее 6 символов"
},
"success": {
"title": "Успешно",
"subtitle": "Ваш пароль был успешно изменен"
}
},
"page_is_not_available": "Страница недоступна",
"go_away": "Перейти на страницу авторизации"
},
"register": {
"title": "Регистрация",
"subtitle": "Заполните поля для подтверждения регистрации",
"register_btn": "Создать аккаунт",
"success_title": "Аккаунт был успешно создан",
"success_subtitle": "Перейдите на страницу авторизации, чтобы войти в аккаунт"
},
"settings": {
"account": "Аккаунт",
"general": "Общее",
"language": "Язык",
"company": "Компания",
"company_timezone": "Часовой пояс компании"
},
"control": {
"save": "Сохранить",
"create": "Создать",
"view": "Просмотр",
"edit": "Редактировать",
"delete": "Удалить",
"add": "Добавить",
"yes": "Да",
"no": "Нет",
"back": "Назад",
"submit": "Отправить",
"deselect_all": "Отменить выбор всех",
"select_all": "Выбрать все",
"clear_all": "Очистить все",
"select_all_open": "Выбрать все открытые",
"select_all_closed": "Выбрать все закрытые",
"user_selected": "Нет выбранных пользователей | Выбран 1 пользователь | Выбрано {count} пользователя(ей)",
"element_selected": "Нет выбранных элементов | Выбран 1 элемент | Выбрано {count} элемента(ов)",
"project_selected": "Нет выбранных проектов| Выбран 1 проект | Выбрано {count} проекта(ов)",
"project_selected_all": "Выбраны все проекты",
"status_selected": "Нет выбранных статусов | Выбран 1 статус | Выбрано {count} статуса(ов)",
"status_selected_all": "Выбраны все статусы",
"screenshot_state_options": {
"required": "Обязательны",
"optional": "Необязательны",
"forbidden": "Запрещены"
},
"day": "День",
"week": "Неделя",
"month": "Месяц",
"range": "Диапазон",
"today": "Сегодня",
"ok": "Ok",
"active": "Активные",
"inactive": "Неактивные",
"search": "Поиск",
"add_time": "Добавить время",
"enable": "Включить",
"disable": "Выключить",
"select": "Выбрать",
"cancel": "Закрыть",
"reset": "Сбросить",
"show_active": "Показать только активные задачи"
},
"field": {
"password": "Пароль",
"name": "Название",
"full_name": "Имя",
"status": "Статус",
"email": "E-mail",
"user": "Пользователь",
"users": "Пользователи",
"active": "Активен",
"change_password": "Сменить пароль",
"screenshot": "Скриншот",
"screenshots": "Скриншоты",
"manual_time": "Установка интервалов",
"screenshots_interval": "Интервал скриншотов",
"computer_time_popup": "Время неактивности",
"timezone": "Часовой пояс",
"default_role": "Роль по умолчанию",
"project_roles": "Роли для проектов",
"task": "Задача",
"tasks": "Задачи",
"project": "Проект",
"projects": "Проекты",
"priority": "Приоритет",
"created_at": "Создано",
"updated_at": "Изменено",
"team": "Команда",
"amount_of_tasks": "Количество задач",
"description": "Описание",
"important": "Важно",
"actions": "Действия",
"start_at": "Начало в",
"end_at": "Конец в",
"expires_at": "Истекает",
"role": "Роль",
"user_language": "Язык пользователя",
"send_invite": "Отправить приглашение",
"selected": "Выбрано",
"total": "Всего",
"total_time": "Общее время",
"total_spent": "Потраченное время",
"time": "Время",
"auto_thin": "Автоматическая очистка хранилища",
"screenshots_state": "Включить скриншоты",
"members": "Участники",
"url": "URL",
"efficiency": "Коэффициент эффективности сотрудника",
"statuses": {
"any": "Все",
"active": "Активен",
"disabled": "Отключен"
},
"roles": {
"admin": {
"name": "Администратор",
"description": "Имеет полный доступ ко всему"
},
"manager": {
"name": "Менеджер",
"description": "Имеет полный доступ к задачам, проектам, скриншотам и к просмотру активности всех пользователей"
},
"user": {
"name" : "Пользователь",
"description" : "Имеет доступ на чтение к проектам, над которыми работает, создание и просмотр своих задач, просмотр личной активности"
},
"auditor": {
"name": "Проверяющий",
"description": "Имеет доступ на чтение ко всем проектам, создание и чтение всех задач, просмотр активности всех пользователей"
},
"any": "Все"
},
"type": "Тип",
"types": {
"all": "Все",
"any": "Любой",
"employee": "Сотрудник",
"client": "Клиент"
},
"work_time": "Продолжительность рабочего дня",
"notice": "Предупреждение",
"report": "Отчет",
"minutes": "{value} минут(-ы)",
"duration": "Продолжительность",
"duration_value": "{0} по {1}",
"web_and_app_monitoring": "Мониторинг приложений",
"parent_group": "Родительская группа"
},
"filter": {
"enter-single": "Введите {0}",
"enter-multiple": "Введите {0} или {1}",
"fields": {
"task_name": "название задачи",
"project_name": "название проекта",
"full_name": "полное имя",
"name": "имя",
"email": "e-mail",
"url": "URL"
},
"full_name": "Фильтр по имени",
"email": "Фильтр по e-mail",
"task": "Фильтр по задачам",
"project": "Фильтр по проектам"
},
"message": {
"no_data": "Нет данных для отображения",
"page_not_found": "Похоже, что страница, которую вы ищете, не существует :(",
"api_error": "Похоже, что мы испытываем временные технические трудности, сообщите об этом вашему администратору :(",
"page_forbidden": "Страница не доступна",
"field_is_required": "Это поле обязательно для заполнения",
"something_went_wrong": "Что то пошло не так",
"success": "Успешно",
"error": "Ошибка",
"vulnerable_version": "Ваша текущая версия приложения устарела. Установите обновления, которые устранят известные уязвимости",
"update_version": "Доступна новая версия",
"report_has_been_queued": "Отчет заказан и будет отправлен на почту"
},
"time": {
"d": "д",
"h": "ч",
"m": "м",
"s": "с"
},
"tooltip": {
"task_important": "Соответствующие скриншоты не будут удаляться автоматически",
"user_change_password": "Обязать пользователя сменить пароль при входе",
"user_manual_time": "Дать возможность пользователю добавлять время вручную",
"user_send_invite": "Отправить данные учетной записи на почту пользователю. Если поле \"Пароль\" не заполнено, он будет сгенерирован автоматически",
"user_computer_time_popup": "Время неактивности в минутах до появления оповещения в приложении-клиенте",
"user_interval_screenshot": "Интервал создания скриншотов в минутах",
"color_intervals": "Позволяет задать цвета для интервалов рабочего дня с 0 до 100 процентов",
"work_time": "Минимальная продолжительность рабочего дня",
"auto_thin": "Старые скриншоты будут удаляться автоматически",
"activity_progress": {
"not_tracked": "Активность не отслеживалась",
"overall": "Общая активность: | Общая активность: 1% | Общая активность: {percent}%",
"mouse": "Мышь: 0% | Мышь: 1% | Мышь: {percent}%",
"keyboard": "Клавиатура: 0% | Клавиатура: 1% | Клавиатура: {percent}%",
"just_mouse": "Мышь:",
"just_keyboard": "Клавиатура:"
}
},
"invite": {
"resend": "Переотправить приглашение"
},
"about": {
"modules": {
"name": "Модуль",
"version": "Версия",
"status": "Статус",
"vulnerable": "Есть известные уязвимости",
"ok": "Обновление не требуется",
"outdated": "Требуется обновление"
},
"module_versions": "Версия модулей",
"module_storage": "Хранилище",
"no_modules": "Нет установленных модулей",
"no_storage": "Нет информации про хранилище",
"storage": {
"last_thinning": "Последняя очистка",
"space": {
"left": "Осталось",
"total": "Всего",
"used": "Использовано"
},
"screenshots_available": "Можно удалить",
"screenshots": "0 скриншотов | {n} скриншот | {n} скриншота | {n} скриншотов",
"thin_unavailable": "Очистка сейчас недоступна",
"thin_available": "Доступна очистка",
"thin": "Очистить место"
}
},
"notification": {
"save": {
"success": {
"title": "Успешно",
"message": "Сохранено успешно"
},
"error": {
"title": "Ошибка",
"message": "Не удалось сохранить"
}
},
"record": {
"save": {
"success": {
"title": "Успешно",
"message": "Запись была успешно сохранена"
}
},
"delete": {
"confirmation": {
"title": "Удалить запись?",
"message": "Вы уверены, что хотите удалить запись?"
},
"success": {
"title": "Успешно",
"message": "Запись была успешно удалена"
},
"error": {
"title": "Ошибка",
"message": "Не удалось удалить отчёт"
}
}
},
"settings": {
"save": {
"success": {
"title": "Успешно",
"message": "Настройки успешно сохранены"
}
}
},
"screenshot": {
"save": {
"success": {
"title": "Успешно",
"message": "Скриншот(-ы) успешно сохранен(-ы)"
},
"error": {
"title": "Ошибка",
"message": "Не удалось сохранить скриншот(-ы)"
}
},
"delete": {
"success": {
"title": "Успешно",
"message": "Скриншот(-ы) успешно удален(-ы)"
},
"error": {
"title": "Ошибка",
"message": "Не удалось удалить скриншот(-ы)"
}
}
}
}
}

View File

@@ -0,0 +1,29 @@
module.exports = {
/**
* @param choice {number} a choice index given by the input to $tc: `$tc('path.to.rule', choiceIndex)`
* @param choicesLength {number} an overall amount of available choices
* @returns a final choice index to select plural word by
*/
ru: function (choice, choicesLength) {
// this === VueI18n instance, so the locale property also exists here
if (choice === 0) {
return 0;
}
const teen = choice > 10 && choice < 20;
const endsWithOne = choice % 10 === 1;
if (choicesLength < 4) {
return !teen && endsWithOne ? 1 : 2;
}
if (!teen && endsWithOne) {
return 1;
}
if (!teen && choice % 10 >= 2 && choice % 10 <= 4) {
return 2;
}
return choicesLength < 4 ? 2 : 3;
},
};