[common] Add sharing settings

This commit is contained in:
SergeyEzhin 2022-07-29 22:25:44 +03:00
parent 8227926d6d
commit 75f01aca9a
10 changed files with 93 additions and 5 deletions

View file

@ -0,0 +1,18 @@
import React, { Component } from 'react'
import {observer, inject} from "mobx-react"
import { withTranslation } from 'react-i18next';
import SharingSettings from '../view/SharingSettings';
class SharingSettingsController extends Component {
constructor(props){
super(props);
}
render() {
return (
<SharingSettings />
)
}
}
export default SharingSettingsController;

View file

@ -0,0 +1,22 @@
import React, { Component, useEffect } from 'react';
import { observer, inject } from "mobx-react";
import { f7, Popover, List, ListItem, Navbar, NavRight, Sheet, BlockTitle, Page, View, Icon, Link } from 'framework7-react';
import { useTranslation } from 'react-i18next';
import { Device } from "../../utils/device";
const SharingSettings = props => {
const { t } = useTranslation();
const _t = t('Common.Collaboration', {returnObjects: true});
const url = 'https://nct.onlyoffice.com/Products/Files/Share.aspx?fileid=142278';
return (
<Page>
<Navbar title={t('Common.Collaboration.textSharingSettings')} backLink={_t.textBack} />
<div id="sharing-placeholder" className="sharing-placeholder">
<iframe width="100%" height="100%" frameBorder={0} scrolling="0" align="top" src={url}></iframe>
</div>
</Page>
)
}
export default SharingSettings;

View file

@ -1138,8 +1138,11 @@ input[type="number"]::-webkit-inner-spin-button {
}
}
// Sharing Settings
.sharing-placeholder {
height: 100%;
}

File diff suppressed because one or more lines are too long

View file

@ -163,7 +163,9 @@
"textTryUndoRedo": "The Undo/Redo functions are disabled for the Fast co-editing mode.",
"textUnderline": "Underline",
"textUsers": "Users",
"textWidow": "Widow control"
"textWidow": "Widow control",
"textWidow": "Widow control",
"textSharingSettings": "Sharing Settings"
},
"HighlightColorPalette": {
"textNoFill": "No Fill"

View file

@ -13,6 +13,7 @@ import { DocumentFormats, DocumentMargins, DocumentColorSchemes } from "./Docume
import { MacrosSettings, Direction } from "./ApplicationSettings";
import About from '../../../../../common/mobile/lib/view/About';
import NavigationController from '../../controller/settings/Navigation';
import SharingSettingsController from "../../../../../common/mobile/lib/controller/SharingSettings";
const routes = [
{
@ -68,6 +69,13 @@ const routes = [
{
path: '/direction/',
component: Direction
},
// Sharing Settings
{
path: '/sharing-settings/',
component: SharingSettingsController
}
];
@ -174,6 +182,9 @@ const SettingsList = inject("storeAppOptions", "storeReview")(observer(props =>
<ListItem title={_t.textApplicationSettings} link="#" onClick={onoptionclick.bind(this, "/application-settings/")}>
<Icon slot="media" icon="icon-app-settings"></Icon>
</ListItem>
<ListItem title={t('Common.Collaboration.textSharingSettings')} link="#" onClick={onoptionclick.bind(this, "/sharing-settings/")}>
<Icon slot="media" icon="icon-sharing-settings"></Icon>
</ListItem>
{_canDownload &&
<ListItem title={_t.textDownload} link="#" onClick={onoptionclick.bind(this, "/download/")}>
<Icon slot="media" icon="icon-download"></Icon>

View file

@ -32,7 +32,9 @@
"textReopen": "Reopen",
"textResolve": "Resolve",
"textTryUndoRedo": "The Undo/Redo functions are disabled for the Fast co-editing mode.",
"textUsers": "Users"
"textUsers": "Users",
"textWidow": "Widow control",
"textSharingSettings": "Sharing Settings"
},
"HighlightColorPalette": {
"textNoFill": "No Fill"

View file

@ -12,6 +12,7 @@ import PresentationSettingsController from "../../controller/settings/Presentati
import { PresentationColorSchemes } from "./PresentationSettings";
// import PresentationAboutController from '../../controller/settings/PresentationAbout';
import About from '../../../../../common/mobile/lib/view/About';
import SharingSettingsController from "../../../../../common/mobile/lib/controller/SharingSettings";
const routes = [
{
@ -45,6 +46,13 @@ const routes = [
{
path: '/about/',
component: About
},
// Sharing Settings
{
path: '/sharing-settings/',
component: SharingSettingsController
}
/*{
path: '/presentation-settings/',
@ -178,6 +186,9 @@ const SettingsList = inject("storeAppOptions", "storeToolbarSettings")(observer(
<ListItem title={_t.textApplicationSettings} link="#" onClick={onoptionclick.bind(this, '/application-settings/')}>
<Icon slot="media" icon="icon-app-settings"></Icon>
</ListItem>
<ListItem title={t('Common.Collaboration.textSharingSettings')} link="#" onClick={onoptionclick.bind(this, "/sharing-settings/")}>
<Icon slot="media" icon="icon-sharing-settings"></Icon>
</ListItem>
{_canDownload &&
<ListItem title={_t.textDownload} link="#" onClick={onoptionclick.bind(this, '/download/')}>
<Icon slot="media" icon="icon-download"></Icon>

View file

@ -32,7 +32,9 @@
"textReopen": "Reopen",
"textResolve": "Resolve",
"textTryUndoRedo": "The Undo/Redo functions are disabled for the Fast co-editing mode.",
"textUsers": "Users"
"textUsers": "Users",
"textWidow": "Widow control",
"textSharingSettings": "Sharing Settings"
},
"ThemeColorPalette": {
"textCustomColors": "Custom Colors",

View file

@ -13,6 +13,7 @@ import {MacrosSettings, RegionalSettings, FormulaLanguage} from './ApplicationSe
// import SpreadsheetAbout from './SpreadsheetAbout.jsx';
import About from '../../../../../common/mobile/lib/view/About';
import { Direction } from '../../../../../spreadsheeteditor/mobile/src/view/settings/ApplicationSettings';
import SharingSettingsController from "../../../../../common/mobile/lib/controller/SharingSettings";
const routes = [
{
@ -66,6 +67,13 @@ const routes = [
{
path: '/direction/',
component: Direction
},
// Sharing Settings
{
path: '/sharing-settings/',
component: SharingSettingsController
}
];
@ -188,6 +196,9 @@ const SettingsList = inject("storeAppOptions")(observer(props => {
<ListItem title={_t.textApplicationSettings} link="#" onClick={onoptionclick.bind(this, '/application-settings/')}>
<Icon slot="media" icon="icon-app-settings"></Icon>
</ListItem>
<ListItem title={t('Common.Collaboration.textSharingSettings')} link="#" onClick={onoptionclick.bind(this, "/sharing-settings/")}>
<Icon slot="media" icon="icon-sharing-settings"></Icon>
</ListItem>
{_canDownload &&
<ListItem title={_t.textDownload} link="#" onClick={onoptionclick.bind(this, '/download/')}>
<Icon slot="media" icon="icon-download"></Icon>