make translate for login, register pages
This commit is contained in:
@@ -0,0 +1,51 @@
|
||||
{
|
||||
"HomePage": {
|
||||
"title": "Welcome to our application",
|
||||
"description": "This is a demo application with i18n support"
|
||||
},
|
||||
"Global": {
|
||||
"statistics": "Statistik"
|
||||
},
|
||||
"Login-register-form": {
|
||||
"already-have-an-account": "Already have an account",
|
||||
"company": "Company",
|
||||
"company-placeholder": "Your company",
|
||||
"confirm-password": "Confirm password",
|
||||
"copyright-protection": "Copyright protection",
|
||||
"create-an-account": "Create an account",
|
||||
"email-adress": "Email adress",
|
||||
"enter-email": "Enter your email",
|
||||
"enter-password": "Enter your password",
|
||||
"forgot-password": "Forgot your password",
|
||||
"free-start": "Free start",
|
||||
"free-start-description": "Upon registration, you receive a \"DEMO\" subscription with the ability to tag up to 3 files per month and 10 MB of storage.",
|
||||
"full-name": "Full name",
|
||||
"i-agree-to": "I agree to the",
|
||||
"login": "Login",
|
||||
"login-error-email": "Email address must not be empty.",
|
||||
"login-error-password": "The password must not be empty.",
|
||||
"monitoring-violations": "Real-time monitoring of violations",
|
||||
"name-placeholder": "Ivanov Ivan Ivanovich",
|
||||
"no-account": "No account",
|
||||
"or-log-in-via": "or log in via",
|
||||
"or-register-via": "or register via",
|
||||
"password": "Password",
|
||||
"password-placeholder": "Minimum 8 characters",
|
||||
"phone": "Phone",
|
||||
"protecting-watermark": "Protecting content with hidden watermarks",
|
||||
"register": "Register",
|
||||
"register-error-agree": "Please review the terms of use and privacy policy.",
|
||||
"register-error-name": "Name must be at least 3 characters long.",
|
||||
"register-error-password-one-digit": "Password must contain at least 1 digit.",
|
||||
"register-error-password-one-letter": "Password must contain at least 1 letter.",
|
||||
"register-error-password-symbols": "Password must be at least 8 characters long.",
|
||||
"register-error-phone": "Please enter a phone number.",
|
||||
"register-error-valid-email": "Please enter a valid email address.",
|
||||
"remember-me": "Remember me",
|
||||
"repeat-password": "Repeat password",
|
||||
"request-ended-with-an-error": "The request ended with an error",
|
||||
"safe-storage": "Reliable storage and data security",
|
||||
"sign-in": "Sign in",
|
||||
"terms-of-use": "terms of use and privacy policy"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,51 @@
|
||||
{
|
||||
"HomePage": {
|
||||
"title": "Добро пожаловать в наше приложение",
|
||||
"description": "Это демонстрационное приложение с поддержкой i18n"
|
||||
},
|
||||
"Global": {
|
||||
"statistics": "Статистика"
|
||||
},
|
||||
"Login-register-form": {
|
||||
"already-have-an-account": "Уже есть аккаунт",
|
||||
"company": "Компания",
|
||||
"company-placeholder": "ООО «Ваша компания»",
|
||||
"confirm-password": "Подтвердите пароль",
|
||||
"copyright-protection": "Защита авторских прав",
|
||||
"create-an-account": "Создать аккаунт",
|
||||
"email-adress": "Email адрес",
|
||||
"enter-email": "Введите ваш email",
|
||||
"enter-password": "Введите пароль",
|
||||
"forgot-password": "Забыли пароль",
|
||||
"free-start": "Бесплатный старт",
|
||||
"free-start-description": "При регистрации вы получаете подписку \"ДЕМО\" с возможностью маркировки до 3 файлов в месяц и 10 МБ хранилища.",
|
||||
"full-name": "Полное имя",
|
||||
"i-agree-to": "Я соглашаюсь с",
|
||||
"login": "Войти",
|
||||
"login-error-email": "Адрес электронной почты не должен быть пустым.",
|
||||
"login-error-password": "Пароль не должен быть пустым.",
|
||||
"monitoring-violations": "Мониторинг нарушений в реальном времени",
|
||||
"name-placeholder": "Иванов Иван Иванович",
|
||||
"no-account": "Нет аккаунта",
|
||||
"or-log-in-via": "или войти через",
|
||||
"or-register-via": "или зарегистрироваться через",
|
||||
"password": "Пароль",
|
||||
"password-placeholder": "Минимум 8 символов",
|
||||
"phone": "Телефон",
|
||||
"protecting-watermark": "Защита контента скрытыми водяными знаками",
|
||||
"register": "Зарегистрироваться",
|
||||
"register-error-agree": "Пожалуйста, ознакомьтесь с условиями использования и политикой конфиденциальности.",
|
||||
"register-error-name": "Имя должно содержать не менее 3 символов.",
|
||||
"register-error-password-one-digit": "Пароль должен содержать как минимум 1 цифру.",
|
||||
"register-error-password-one-letter": "Пароль должен содержать как минимум 1 букву.",
|
||||
"register-error-password-symbols": "Длина пароля должна быть не менее 8 символов.",
|
||||
"register-error-phone": "Пожалуйста, введите телефонный номер.",
|
||||
"register-error-valid-email": "Пожалуйста, введите правильный адрес электронной почты.",
|
||||
"remember-me": "Запомнить меня",
|
||||
"repeat-password": "Повторите пароль",
|
||||
"request-ended-with-an-error": "Запрос завершился с ошибкой",
|
||||
"safe-storage": "Надежное хранение и безопасность данных",
|
||||
"sign-in": "Войти в систему",
|
||||
"terms-of-use": "условиями использования и политикой конфиденциальности"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
import { createNavigation } from 'next-intl/navigation';
|
||||
import { routing } from './routing';
|
||||
|
||||
export const { Link, redirect, usePathname, useRouter, getPathname } =
|
||||
createNavigation(routing);
|
||||
@@ -0,0 +1,15 @@
|
||||
import { getRequestConfig } from 'next-intl/server';
|
||||
import { hasLocale } from 'next-intl';
|
||||
import { routing } from './routing';
|
||||
|
||||
export default getRequestConfig(async ({ requestLocale }) => {
|
||||
const requested = await requestLocale;
|
||||
const locale = hasLocale(routing.locales, requested)
|
||||
? requested
|
||||
: routing.defaultLocale;
|
||||
|
||||
return {
|
||||
locale,
|
||||
messages: (await import(`./messages/${locale}.json`)).default
|
||||
};
|
||||
});
|
||||
@@ -0,0 +1,6 @@
|
||||
import { defineRouting } from 'next-intl/routing';
|
||||
|
||||
export const routing = defineRouting({
|
||||
locales: ['ru', 'en'],
|
||||
defaultLocale: 'ru'
|
||||
});
|
||||
Reference in New Issue
Block a user