From 51176cae7d24577fa66a9c225890d265d91c43b3 Mon Sep 17 00:00:00 2001 From: gazizova-vlada Date: Tue, 8 Feb 2022 17:43:32 +0300 Subject: [PATCH] Web:Studio:Added common-tooltips file and LanguageTimeSettingsTooltip component. Added translations of "DescriptionTimeLanguage" and "LanguageTimeSettingsTooltip" for locales en, ru. --- .../public/locales/en/Settings.json | 4 +- .../public/locales/ru/Settings.json | 4 +- .../common/sub-components/common-tooltips.js | 61 +++++++++++++++++++ 3 files changed, 67 insertions(+), 2 deletions(-) create mode 100644 web/ASC.Web.Client/src/components/pages/Settings/categories/common/sub-components/common-tooltips.js diff --git a/web/ASC.Web.Client/public/locales/en/Settings.json b/web/ASC.Web.Client/public/locales/en/Settings.json index b2e6f3dae2..86a716cded 100644 --- a/web/ASC.Web.Client/public/locales/en/Settings.json +++ b/web/ASC.Web.Client/public/locales/en/Settings.json @@ -26,6 +26,7 @@ "CustomTitles": "Custom titles", "CustomTitlesSettingsDescription": "Will be displayed on your welcome page and used for email notifications (From field). The custom domain name is a way to set an alternative URL for your portal. The custom portal name will appear next to the onlyoffice.com/onlyoffice.eu address.", "DeactivateOrDeletePortal": "Deactivate or delete portal.", + "DescriptionTimeLanguage": "To make the parameters you set take effect click the", "Disabled": "Disabled", "DocumentsAdministratorsCan": "Documents administrators can link Dropbox, Box, and other accounts to Common Documents and set up access rights in this section", "Employees": "users", @@ -36,6 +37,7 @@ "Guests": "Guests", "Job/Title": "Job/Title", "LanguageAndTimeZoneSettingsDescription": "Change language for all portal users and configure time zone so that all portal events are shown with the correct date and time.", + "LanguageTimeSettingsTooltip": "<0>{{text}} is a way to change the language of the whole portal for all portal users and to configure the time zone so that all the events of the ONLYOFFICE portal will be shown with the correct date and time. <2>{{description}} <0>{{save}} button at the bottom of the section.<5>{{learnMore}}", "LogoDark": "Logo for the About/Login page", "LogoDocsEditor": "Logo for the editors header", "LogoFavicon": "Favicon", @@ -79,4 +81,4 @@ "Users": "Users", "WelcomePageTitle": "Welcome page title", "YouHaveUnsavedChanges": "You have unsaved changes" -} \ No newline at end of file +} diff --git a/web/ASC.Web.Client/public/locales/ru/Settings.json b/web/ASC.Web.Client/public/locales/ru/Settings.json index 351e850f00..d0f2d4ef28 100644 --- a/web/ASC.Web.Client/public/locales/ru/Settings.json +++ b/web/ASC.Web.Client/public/locales/ru/Settings.json @@ -26,6 +26,7 @@ "CustomTitles": "Пользовательские заголовки", "CustomTitlesSettingsDescription": "Пользовательский заголовок страницы приветствия будет отображаться на странице приветствия вашего портала. Это же имя используется для поля 'От' вашего электронного уведомления портала. Пользовательское доменное имя - это способ установить альтернативный URL-адрес для вашего портала. Пользовательское имя портала будет отображаться рядом с адресом портала onlyoffice.com/onlyoffice.eu.", "DeactivateOrDeletePortal": "Деактивировать или удалить портал.", + "DescriptionTimeLanguage": "Чтобы применить их, используйте кнопку", "Disabled": "Отключено", "DocumentsAdministratorsCan": "Администраторы модуля Документы могут подключать Dropbox, Box и другие аккаунты в Общих документах и настраивать права доступа в этом разделе", "Employees": "Пользователи", @@ -36,6 +37,7 @@ "Guests": "Гости", "Job/Title": "Должность/Позиция", "LanguageAndTimeZoneSettingsDescription": "Настройки языка и часового пояса - это способ изменить язык всего портала для всех пользователей портала и настроить часовой пояс, чтобы все события портала отображались с правильной датой и временем.", + "LanguageTimeSettingsTooltip": "<0>{{text}} позволяют изменить язык всего портала для всех пользователей и настроить часовой пояс, чтобы все события на портале ONLYOFFICE отображались с корректной датой и временем. <2>{{description}} <0>{{save}} внизу раздела.<5>{{learnMore}} ", "LogoDark": "Логотип для страницы \"О программе\" и страницы входа ", "LogoDocsEditor": "Логотип для шапки редакторов", "LogoFavicon": "Иконка сайта", @@ -79,4 +81,4 @@ "Users": "Пользователи", "WelcomePageTitle": "Заголовок страницы приветствия", "YouHaveUnsavedChanges": "Имеются несохраненные изменения" -} \ No newline at end of file +} diff --git a/web/ASC.Web.Client/src/components/pages/Settings/categories/common/sub-components/common-tooltips.js b/web/ASC.Web.Client/src/components/pages/Settings/categories/common/sub-components/common-tooltips.js new file mode 100644 index 0000000000..a57ee0a241 --- /dev/null +++ b/web/ASC.Web.Client/src/components/pages/Settings/categories/common/sub-components/common-tooltips.js @@ -0,0 +1,61 @@ +import React from "react"; +import styled from "styled-components"; +import { Trans } from "react-i18next"; +import Link from "@appserver/components/link"; +import Text from "@appserver/components/text"; + +const StyledLanguageTimeSettingsTooltip = styled.div` + .font-size { + font-size: 12px; + } + .bold { + font-weight: 600; + } + .display { + display: inline; + } + .display-link { + display: block; + } +`; + +const LanguageTimeSettingsTooltip = ({ t }) => { + const learnMore = t("Common:LearnMore"); + const text = t("Settings:StudioTimeLanguageSettings"); + const save = t("Common:SaveButton"); + const description = t("Settings:DescriptionTimeLanguage"); + + return ( + + + + {{ text }} + + is a way to change the language of the whole portal for all portal + users and to configure the time zone so that all the events of the + ONLYOFFICE portal will be shown with the correct date and time. + + {{ description }} + {{ save }} button at + the bottom of the section. + + {{ learnMore }} + + + + + ); +}; + +export default LanguageTimeSettingsTooltip;