diff --git a/apps/common/mobile/resources/less/about.less b/apps/common/mobile/resources/less/about.less new file mode 100644 index 000000000..7234dcb25 --- /dev/null +++ b/apps/common/mobile/resources/less/about.less @@ -0,0 +1,41 @@ +@text-normal: #000; + +.about { + .page-content { + text-align: center; + } + + .content-block:first-child { + margin: 15px 0; + } + + .content-block { + margin: 0 auto 15px; + + a { + color: @text-normal; + } + } + + h3 { + font-weight: normal; + margin: 0; + + &.vendor { + color: @text-normal; + font-weight: bold; + margin-top: 15px; + } + } + + p > label { + margin-right: 5px; + } + + .logo { + display: inline-block; + width: 100%; + height: 55px; + background: url('../../../../common/mobile/resources/img/about/logo.svg') no-repeat center; + } +} \ No newline at end of file diff --git a/apps/common/mobile/resources/less/common-ios.less b/apps/common/mobile/resources/less/common-ios.less index 325b67602..ef453c9e0 100644 --- a/apps/common/mobile/resources/less/common-ios.less +++ b/apps/common/mobile/resources/less/common-ios.less @@ -330,4 +330,10 @@ } } } + + .about { + .logo { + margin-top: 20px; + } + } } diff --git a/apps/presentationeditor/mobile/locale/en.json b/apps/presentationeditor/mobile/locale/en.json index d4ae0d7d0..e532842d2 100644 --- a/apps/presentationeditor/mobile/locale/en.json +++ b/apps/presentationeditor/mobile/locale/en.json @@ -66,7 +66,12 @@ "textSlideSize": "Slide Size", "mniSlideStandard": "Standard (4:3)", "mniSlideWide": "Widescreen (16:9)", - "textColorSchemes": "Color Schemes" + "textColorSchemes": "Color Schemes", + "textVersion": "Version", + "textAddress": "address:", + "textEmail": "email:", + "textTel": "tel:", + "textPoweredBy": "Powered By" }, "Add": { "textSlide": "Slide", diff --git a/apps/presentationeditor/mobile/src/controller/Main.jsx b/apps/presentationeditor/mobile/src/controller/Main.jsx index 00beac336..f8ed8780c 100644 --- a/apps/presentationeditor/mobile/src/controller/Main.jsx +++ b/apps/presentationeditor/mobile/src/controller/Main.jsx @@ -43,6 +43,7 @@ class MainController extends Component { this.props.storeAppOptions.setConfigOptions(this.editorConfig); this.editorConfig.lang && this.api.asc_setLocale(this.editorConfig.lang); + // console.log(this.editorConfig); }; const loadDocument = data => { diff --git a/apps/presentationeditor/mobile/src/controller/settings/PresentationAbout.jsx b/apps/presentationeditor/mobile/src/controller/settings/PresentationAbout.jsx new file mode 100644 index 000000000..db46185db --- /dev/null +++ b/apps/presentationeditor/mobile/src/controller/settings/PresentationAbout.jsx @@ -0,0 +1,17 @@ +import React, { Component } from "react"; +import PresentationAbout from "../../view/settings/PresentationAbout"; + +class PresentationAboutController extends Component { + constructor(props) { + super(props); + } + + render() { + return ( + + ); + } +} + + +export default PresentationAboutController; \ No newline at end of file diff --git a/apps/presentationeditor/mobile/src/controller/settings/PresentationSettings.jsx b/apps/presentationeditor/mobile/src/controller/settings/PresentationSettings.jsx index 144d4a66e..1a1099035 100644 --- a/apps/presentationeditor/mobile/src/controller/settings/PresentationSettings.jsx +++ b/apps/presentationeditor/mobile/src/controller/settings/PresentationSettings.jsx @@ -1,4 +1,4 @@ -import React, {Component} from 'React'; +import React, {Component} from 'react'; import { observer, inject } from "mobx-react"; import {PresentationSettings} from '../../view/settings/PresentationSettings'; diff --git a/apps/presentationeditor/mobile/src/less/app-material.less b/apps/presentationeditor/mobile/src/less/app-material.less index 3a7fb97e7..2a0550a09 100644 --- a/apps/presentationeditor/mobile/src/less/app-material.less +++ b/apps/presentationeditor/mobile/src/less/app-material.less @@ -45,4 +45,4 @@ margin-left: 20px; color: #212121; } -} \ No newline at end of file +} diff --git a/apps/presentationeditor/mobile/src/less/app.less b/apps/presentationeditor/mobile/src/less/app.less index d2d73f91e..d83b0a431 100644 --- a/apps/presentationeditor/mobile/src/less/app.less +++ b/apps/presentationeditor/mobile/src/less/app.less @@ -5,6 +5,7 @@ @import '../../../../common/mobile/resources/less/common.less'; @import '../../../../common/mobile/resources/less/common-ios.less'; @import '../../../../common/mobile/resources/less/common-material.less'; +@import '../../../../common/mobile/resources/less/about.less'; @import './app-material.less'; @import './app-ios.less'; @import './icons-ios.less'; diff --git a/apps/presentationeditor/mobile/src/view/settings/PresentationAbout.jsx b/apps/presentationeditor/mobile/src/view/settings/PresentationAbout.jsx new file mode 100644 index 000000000..27e777d22 --- /dev/null +++ b/apps/presentationeditor/mobile/src/view/settings/PresentationAbout.jsx @@ -0,0 +1,94 @@ +import React, { Fragment } from 'react'; +import { observer, inject } from "mobx-react"; +import { Page, Navbar, Link } from "framework7-react"; +import { useTranslation } from "react-i18next"; + +const PagePresentationAbout = props => { + const { t } = useTranslation(); + const _t = t("View.Settings", { returnObjects: true }); + const store = props.storeAppOptions; + const isCanBranding = store.canBranding; + const licInfo = isCanBranding ? store.customization : null; + const customer = licInfo ? licInfo.customer : null; + const nameCustomer = customer ? customer.name : null; + const mailCustomer = customer ? customer.mail : null; + const addressCustomer = customer ? customer.address : null; + const urlCustomer = customer ? customer.www : null; + const infoCustomer = customer ? customer.info : null; + const logoCustomer = customer ? customer.logo : null; + + console.log(store); + console.log(isCanBranding); + + return ( + + +
+ {licInfo && typeof licInfo == 'object' && typeof(customer)=='object' ? null : ( + + )} + {logoCustomer && logoCustomer.length ? ( + + ) : null} +
+
+

PRESENTATION EDITOR

+

{_t.textVersion} 6.1.1

+
+
+ {nameCustomer && nameCustomer.length ? ( +

{nameCustomer}

+ ) : null} + {addressCustomer && addressCustomer.length ? ( +

+ + {addressCustomer} +

+ ) : null} + {mailCustomer && mailCustomer.length ? ( +

+ + {mailCustomer} +

+ ) : null} + {licInfo && typeof licInfo == 'object' && typeof(customer)=='object' ? null : ( +

+ + +371 633-99867 +

+ )} + {urlCustomer && urlCustomer.length ? ( +

+ + {urlCustomer} + +

+ ) : null} + {infoCustomer && infoCustomer.length ? ( +

+ +

+ ) : null} +
+ {licInfo && typeof licInfo == 'object' && typeof(customer)=='object' ? ( +
+
+

+ +

+

Ascensio System SIA

+

+ www.onlyoffice.com +

+
+ ) : null} +
+ ); +}; + +const PresentationAbout = inject("storeAppOptions")(observer(PagePresentationAbout)); + +export default PresentationAbout; \ No newline at end of file diff --git a/apps/presentationeditor/mobile/src/view/settings/Settings.jsx b/apps/presentationeditor/mobile/src/view/settings/Settings.jsx index c0471856f..294a80ee9 100644 --- a/apps/presentationeditor/mobile/src/view/settings/Settings.jsx +++ b/apps/presentationeditor/mobile/src/view/settings/Settings.jsx @@ -9,6 +9,7 @@ import DownloadController from "../../controller/settings/Download"; import PresentationInfoController from "../../controller/settings/PresentationInfo"; import PresentationSettingsController from "../../controller/settings/PresentationSettings"; import { PresentationColorSchemes } from "./PresentationSettings"; +import PresentationAboutController from '../../controller/settings/PresentationAbout'; const routes = [ { @@ -38,6 +39,10 @@ const routes = [ { path: '/color-schemes/', component: PresentationColorSchemes + }, + { + path: '/about/', + component: PresentationAboutController } /*{ path: '/presentation-settings/', @@ -68,14 +73,32 @@ const SettingsList = withTranslation()(props => { } else { f7.popover.close('#settings-popover'); } - } + }; const onPrint = () => { closeModal(); const api = Common.EditorApi.get(); api.asc_Print(); - } + }; + const showHelp = () => { + // let url = '{{HELP_URL}}'; + let url = 'https://helpcenter.onlyoffice.com'; + + if (url.charAt(url.length-1) !== '/') { + url += '/'; + } + + if (Device.sailfish || Device.android) { + url+='mobile-applications/documents/mobile-web-editors/android/index.aspx'; + } + else { + url+='mobile-applications/documents/mobile-web-editors/ios/index.aspx'; + } + + closeModal(); + window.open(url, "_blank"); + }; return ( @@ -102,10 +125,10 @@ const SettingsList = withTranslation()(props => { - + - +