import React, { Fragment } from 'react'; import { observer, inject } from "mobx-react"; import { Page, Navbar, Link } from "framework7-react"; import { useTranslation } from "react-i18next"; const PageAbout = props => { const { t } = useTranslation(); const _t = t("About", { 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; const publisherUrl = __PUBLISHER_URL__, publisherPrintUrl = publisherUrl.replace(/https?:\/{2}|\/$/,""); const editors = { de: 'DOCUMENT EDITOR', pe: 'PRESENTATION EDITOR', sse: 'SPREADSHEET EDITOR' }; const nameEditor = editors[editorType]; return ( {licInfo && typeof licInfo == 'object' && typeof(customer) == 'object' ? (
{logoCustomer && logoCustomer.length ? ( ) : null}

{nameEditor}

{_t.textVersion} {__PRODUCT_VERSION__}

{nameCustomer && nameCustomer.length ? (

{nameCustomer}

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

{addressCustomer}

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

{mailCustomer}

) : null} {urlCustomer && urlCustomer.length ? (

{urlCustomer}

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

) : null}

{__PUBLISHER_NAME__}

{publisherPrintUrl}

) : (

{nameEditor}

{_t.textVersion} {__PRODUCT_VERSION__}

{__PUBLISHER_NAME__}

{__PUBLISHER_ADDRESS__}

{__SUPPORT_EMAIL__}

{__PUBLISHER_PHONE__}

{publisherPrintUrl}

)}
); }; const About = inject("storeAppOptions")(observer(PageAbout)); About.appVersion = () => (__PRODUCT_VERSION__); About.compareVersions = () => /d$/.test(__PRODUCT_VERSION__); About.developVersion = () => /(?:d|debug)$/.test(__PRODUCT_VERSION__); export default About;