@seafile/sdoc-editor 0.1.148 → 0.1.149-beta
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api/sdoc-server-api.js +10 -0
- package/dist/api/seafile-api.js +27 -5
- package/dist/basic-sdk/comment/comment/comment-item-content.js +5 -0
- package/dist/basic-sdk/comment/comment/comment-item-reply.js +3 -0
- package/dist/basic-sdk/comment/comment/global-comment-header.js +5 -2
- package/dist/basic-sdk/comment/comment/global-comment.js +1 -1
- package/dist/basic-sdk/comment/comment/style.css +6 -5
- package/dist/basic-sdk/constants/index.js +20 -1
- package/dist/basic-sdk/editor/common-editor.js +50 -0
- package/dist/basic-sdk/editor/index.css +29 -0
- package/dist/basic-sdk/editor/index.js +129 -0
- package/dist/basic-sdk/{slate-editor.js → editor/slate-editor.js} +21 -16
- package/dist/basic-sdk/extension/constants/element-type.js +4 -1
- package/dist/basic-sdk/extension/core/transforms/replace-node-children.js +26 -0
- package/dist/basic-sdk/extension/render/render-element.js +213 -1
- package/dist/basic-sdk/socket/helpers.js +2 -0
- package/dist/basic-sdk/socket/socket-client.js +38 -0
- package/dist/basic-sdk/socket/socket-manager.js +25 -2
- package/dist/basic-sdk/socket/with-socket-io.js +35 -12
- package/dist/basic-sdk/utils/diff.js +2 -2
- package/dist/basic-sdk/utils/rebase.js +181 -0
- package/dist/basic-sdk/views/diff-viewer.js +3 -1
- package/dist/basic-sdk/views/viewer.js +9 -12
- package/dist/components/doc-operations/index.js +4 -2
- package/dist/components/doc-operations/revision-operations/index.js +5 -2
- package/dist/components/doc-operations/revision-operations/publish-button.js +6 -13
- package/dist/components/tip-dialog/index.js +48 -0
- package/dist/components/tip-dialog/tip-content.js +50 -0
- package/dist/constants/index.js +23 -2
- package/dist/context.js +35 -4
- package/dist/pages/simple-editor.js +255 -83
- package/package.json +1 -1
- package/public/locales/en/sdoc-editor.json +11 -1
- package/public/locales/zh_CN/sdoc-editor.json +10 -1
- package/public/media/sdoc-editor-font/iconfont.eot +0 -0
- package/public/media/sdoc-editor-font/iconfont.svg +4 -0
- package/public/media/sdoc-editor-font/iconfont.ttf +0 -0
- package/public/media/sdoc-editor-font/iconfont.woff +0 -0
- package/public/media/sdoc-editor-font/iconfont.woff2 +0 -0
- package/public/media/sdoc-editor-font.css +14 -6
- package/dist/basic-sdk/editor.js +0 -105
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import React, { Fragment
|
|
1
|
+
import React, { Fragment } from 'react';
|
|
2
2
|
import { Editable, Slate } from '@seafile/slate-react';
|
|
3
3
|
import { renderLeaf as _renderLeaf, renderElement as _renderElement, createDefaultEditor } from '../extension';
|
|
4
4
|
import withNodeId from '../node-id';
|
|
@@ -8,18 +8,15 @@ import { usePipDecorate } from '../decorates';
|
|
|
8
8
|
import { ArticleContainer, EditorContainer, EditorContent } from '../layout';
|
|
9
9
|
import '../assets/css/simple-viewer.css';
|
|
10
10
|
var SDocViewer = function SDocViewer(_ref) {
|
|
11
|
-
var
|
|
11
|
+
var editor = _ref.editor,
|
|
12
|
+
document = _ref.document,
|
|
12
13
|
customRenderLeaf = _ref.renderLeaf,
|
|
13
14
|
customRenderElement = _ref.renderElement,
|
|
14
15
|
showToolbar = _ref.showToolbar,
|
|
15
16
|
showOutline = _ref.showOutline;
|
|
16
|
-
var
|
|
17
|
-
var defaultEditor = createDefaultEditor();
|
|
18
|
-
return withNodeId(defaultEditor);
|
|
19
|
-
}, []);
|
|
20
|
-
editor.readonly = true;
|
|
17
|
+
var validEditor = editor || withNodeId(createDefaultEditor());
|
|
21
18
|
var slateValue = (document || generateDefaultDocContent()).children;
|
|
22
|
-
var decorate = usePipDecorate(
|
|
19
|
+
var decorate = usePipDecorate(validEditor);
|
|
23
20
|
return /*#__PURE__*/React.createElement(EditorContainer, {
|
|
24
21
|
editor: editor,
|
|
25
22
|
showToolbar: showToolbar,
|
|
@@ -29,19 +26,19 @@ var SDocViewer = function SDocViewer(_ref) {
|
|
|
29
26
|
readonly: true,
|
|
30
27
|
showOutline: showOutline
|
|
31
28
|
}, /*#__PURE__*/React.createElement(Slate, {
|
|
32
|
-
editor:
|
|
29
|
+
editor: validEditor,
|
|
33
30
|
value: slateValue
|
|
34
31
|
}, /*#__PURE__*/React.createElement(ArticleContainer, {
|
|
35
|
-
editor:
|
|
32
|
+
editor: validEditor,
|
|
36
33
|
readOnly: true
|
|
37
34
|
}, /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement(SetNodeToDecorations, null), /*#__PURE__*/React.createElement(Editable, {
|
|
38
35
|
readOnly: true,
|
|
39
36
|
placeholder: "",
|
|
40
37
|
renderElement: function renderElement(props) {
|
|
41
|
-
return (customRenderElement || _renderElement)(props,
|
|
38
|
+
return (customRenderElement || _renderElement)(props, validEditor);
|
|
42
39
|
},
|
|
43
40
|
renderLeaf: function renderLeaf(props) {
|
|
44
|
-
return (customRenderLeaf || _renderLeaf)(props,
|
|
41
|
+
return (customRenderLeaf || _renderLeaf)(props, validEditor);
|
|
45
42
|
},
|
|
46
43
|
onDOMBeforeInput: function onDOMBeforeInput(event) {},
|
|
47
44
|
decorate: decorate
|
|
@@ -11,14 +11,16 @@ import './style.css';
|
|
|
11
11
|
var DocOperations = function DocOperations(_ref) {
|
|
12
12
|
var isShowChanges = _ref.isShowChanges,
|
|
13
13
|
changes = _ref.changes,
|
|
14
|
-
toggleViewChanges = _ref.toggleViewChanges
|
|
14
|
+
toggleViewChanges = _ref.toggleViewChanges,
|
|
15
|
+
publishRevision = _ref.publishRevision;
|
|
15
16
|
var isSdocRevision = context.getSetting('isSdocRevision');
|
|
16
17
|
return /*#__PURE__*/React.createElement("div", {
|
|
17
18
|
className: "doc-ops"
|
|
18
19
|
}, /*#__PURE__*/React.createElement(RevisionOperations, {
|
|
19
20
|
isShowChanges: isShowChanges,
|
|
20
21
|
changes: changes,
|
|
21
|
-
toggleViewChanges: toggleViewChanges
|
|
22
|
+
toggleViewChanges: toggleViewChanges,
|
|
23
|
+
publishRevision: publishRevision
|
|
22
24
|
}), /*#__PURE__*/React.createElement(CommentsOperation, null), !isSdocRevision && /*#__PURE__*/React.createElement(ShareOperation, null), /*#__PURE__*/React.createElement(HistoryOperation, null), /*#__PURE__*/React.createElement(CollaboratorsOperation, null), !isSdocRevision && /*#__PURE__*/React.createElement(MoreOperations, null));
|
|
23
25
|
};
|
|
24
26
|
export default withTranslation('sdoc-editor')(DocOperations);
|
|
@@ -8,7 +8,8 @@ import ChangesCount from './changes-count';
|
|
|
8
8
|
var RevisionOperations = function RevisionOperations(_ref) {
|
|
9
9
|
var isShowChanges = _ref.isShowChanges,
|
|
10
10
|
changes = _ref.changes,
|
|
11
|
-
toggleViewChanges = _ref.toggleViewChanges
|
|
11
|
+
toggleViewChanges = _ref.toggleViewChanges,
|
|
12
|
+
publishRevision = _ref.publishRevision;
|
|
12
13
|
var isSdocRevision = context.getSetting('isSdocRevision');
|
|
13
14
|
var isPublished = context.getSetting('isPublished');
|
|
14
15
|
return /*#__PURE__*/React.createElement(React.Fragment, null, !isSdocRevision && /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(MoreRevisionOperations, null), /*#__PURE__*/React.createElement(Revisions, null)), isSdocRevision && isShowChanges && /*#__PURE__*/React.createElement(ChangesCount, {
|
|
@@ -16,6 +17,8 @@ var RevisionOperations = function RevisionOperations(_ref) {
|
|
|
16
17
|
}), isSdocRevision && /*#__PURE__*/React.createElement(ViewChanges, {
|
|
17
18
|
isShowChanges: isShowChanges,
|
|
18
19
|
toggleViewChanges: toggleViewChanges
|
|
19
|
-
}), isSdocRevision && !isPublished && /*#__PURE__*/React.createElement(PublishRevision,
|
|
20
|
+
}), isSdocRevision && !isPublished && /*#__PURE__*/React.createElement(PublishRevision, {
|
|
21
|
+
publishRevision: publishRevision
|
|
22
|
+
}));
|
|
20
23
|
};
|
|
21
24
|
export default RevisionOperations;
|
|
@@ -1,21 +1,14 @@
|
|
|
1
1
|
import React, { useCallback } from 'react';
|
|
2
|
+
import { useTranslation } from 'react-i18next';
|
|
2
3
|
import { Button } from 'reactstrap';
|
|
3
|
-
import { withTranslation } from 'react-i18next';
|
|
4
|
-
import context from '../../../context';
|
|
5
|
-
import toaster from '../../../components/toast';
|
|
6
4
|
var PublishRevision = function PublishRevision(_ref) {
|
|
7
|
-
var
|
|
8
|
-
var
|
|
9
|
-
|
|
5
|
+
var publishRevision = _ref.publishRevision;
|
|
6
|
+
var _useTranslation = useTranslation(),
|
|
7
|
+
t = _useTranslation.t;
|
|
10
8
|
var publish = useCallback(function (event) {
|
|
11
9
|
event.stopPropagation();
|
|
12
10
|
event.nativeEvent.stopImmediatePropagation();
|
|
13
|
-
|
|
14
|
-
var origin_file_path = res.data.origin_file_path;
|
|
15
|
-
window.location.href = "".concat(siteRoot, "lib/").concat(repoID, "/file/").concat(origin_file_path);
|
|
16
|
-
}).catch(function (error) {
|
|
17
|
-
toaster.danger(t('Error'));
|
|
18
|
-
});
|
|
11
|
+
publishRevision();
|
|
19
12
|
|
|
20
13
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
21
14
|
}, []);
|
|
@@ -25,4 +18,4 @@ var PublishRevision = function PublishRevision(_ref) {
|
|
|
25
18
|
className: "ml-4"
|
|
26
19
|
}, t('Publish'));
|
|
27
20
|
};
|
|
28
|
-
export default
|
|
21
|
+
export default PublishRevision;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import React, { useCallback } from 'react';
|
|
2
|
+
import { useTranslation } from 'react-i18next';
|
|
3
|
+
import { Modal, ModalHeader, ModalBody, ModalFooter, Button } from 'reactstrap';
|
|
4
|
+
import classnames from 'classnames';
|
|
5
|
+
import { TIP_TYPE, TIP_TITLE } from '../../constants';
|
|
6
|
+
import TipContent from './tip-content';
|
|
7
|
+
var TipDialog = function TipDialog(_ref) {
|
|
8
|
+
var className = _ref.className,
|
|
9
|
+
tipType = _ref.tipType,
|
|
10
|
+
toggle = _ref.toggle,
|
|
11
|
+
submit = _ref.submit;
|
|
12
|
+
var _useTranslation = useTranslation(),
|
|
13
|
+
t = _useTranslation.t;
|
|
14
|
+
var closeDialog = useCallback(function () {
|
|
15
|
+
toggle && toggle(false);
|
|
16
|
+
|
|
17
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
18
|
+
}, [tipType]);
|
|
19
|
+
var confirmTip = useCallback(function () {
|
|
20
|
+
submit && submit();
|
|
21
|
+
|
|
22
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
23
|
+
}, []);
|
|
24
|
+
return /*#__PURE__*/React.createElement(Modal, {
|
|
25
|
+
isOpen: true,
|
|
26
|
+
autoFocus: false,
|
|
27
|
+
zIndex: 1071,
|
|
28
|
+
returnFocusAfterClose: false,
|
|
29
|
+
toggle: closeDialog,
|
|
30
|
+
className: classnames('sdoc-tip-dialog', className),
|
|
31
|
+
contentClassName: "sdoc-tip-modal"
|
|
32
|
+
}, /*#__PURE__*/React.createElement(ModalHeader, {
|
|
33
|
+
toggle: [TIP_TYPE.HAS_BEEN_REPLACED, TIP_TYPE.HAS_BEEN_PUBLISHED].includes(tipType) ? undefined : closeDialog
|
|
34
|
+
}, t(TIP_TITLE[tipType])), /*#__PURE__*/React.createElement(ModalBody, {
|
|
35
|
+
className: "sdoc-tip-body"
|
|
36
|
+
}, /*#__PURE__*/React.createElement(TipContent, {
|
|
37
|
+
tipType: tipType
|
|
38
|
+
})), ![TIP_TYPE.HAS_BEEN_REPLACED, TIP_TYPE.HAS_BEEN_PUBLISHED].includes(tipType) && /*#__PURE__*/React.createElement(ModalFooter, null, /*#__PURE__*/React.createElement(Button, {
|
|
39
|
+
color: "secondary",
|
|
40
|
+
className: "mr-2",
|
|
41
|
+
onClick: closeDialog
|
|
42
|
+
}, t('Cancel')), /*#__PURE__*/React.createElement(Button, {
|
|
43
|
+
color: "primary",
|
|
44
|
+
className: "highlight-bg-color",
|
|
45
|
+
onClick: confirmTip
|
|
46
|
+
}, t('Confirm'))));
|
|
47
|
+
};
|
|
48
|
+
export default TipDialog;
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
|
2
|
+
import React, { useEffect, useState } from 'react';
|
|
3
|
+
import PropTypes from 'prop-types';
|
|
4
|
+
import { useTranslation } from 'react-i18next';
|
|
5
|
+
import { TIP_TYPE, TIP_CONTENT } from '../../constants';
|
|
6
|
+
import context from '../../context';
|
|
7
|
+
var TipContent = function TipContent(_ref) {
|
|
8
|
+
var tipType = _ref.tipType;
|
|
9
|
+
var _useState = useState(3),
|
|
10
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
11
|
+
time = _useState2[0],
|
|
12
|
+
setTime = _useState2[1];
|
|
13
|
+
useEffect(function () {
|
|
14
|
+
if (tipType === TIP_TYPE.HAS_BEEN_PUBLISHED) {
|
|
15
|
+
var _time = 3;
|
|
16
|
+
var timer = setInterval(function () {
|
|
17
|
+
_time--;
|
|
18
|
+
setTime(_time);
|
|
19
|
+
if (_time === 0) {
|
|
20
|
+
clearInterval(timer);
|
|
21
|
+
timer = null;
|
|
22
|
+
}
|
|
23
|
+
}, 1000);
|
|
24
|
+
return function () {
|
|
25
|
+
timer && clearInterval(timer);
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
}, [tipType]);
|
|
29
|
+
useEffect(function () {
|
|
30
|
+
if (time === 0) {
|
|
31
|
+
var repoID = context.getSetting('repoID');
|
|
32
|
+
var siteRoot = context.getSetting('siteRoot');
|
|
33
|
+
var originFilePath = context.getSetting('originFilePath');
|
|
34
|
+
var originFileURL = "".concat(siteRoot, "lib/").concat(repoID, "/file").concat(originFilePath);
|
|
35
|
+
window.location.href = originFileURL;
|
|
36
|
+
}
|
|
37
|
+
}, [time]);
|
|
38
|
+
var _useTranslation = useTranslation(),
|
|
39
|
+
t = _useTranslation.t;
|
|
40
|
+
if (tipType === TIP_TYPE.HAS_BEEN_PUBLISHED) {
|
|
41
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, t(TIP_CONTENT[tipType], {
|
|
42
|
+
time: time
|
|
43
|
+
}));
|
|
44
|
+
}
|
|
45
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, t(TIP_CONTENT[tipType]));
|
|
46
|
+
};
|
|
47
|
+
TipContent.propTypes = {
|
|
48
|
+
tipType: PropTypes.string
|
|
49
|
+
};
|
|
50
|
+
export default TipContent;
|
package/dist/constants/index.js
CHANGED
|
@@ -1,6 +1,27 @@
|
|
|
1
|
+
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
2
|
+
var _TIP_TITLE, _TIP_CONTENT;
|
|
1
3
|
export var EXTERNAL_EVENT = {
|
|
2
4
|
INTERNAL_LINK_CLICK: 'internal_link_click',
|
|
3
5
|
TOGGLE_STAR: 'toggle_star',
|
|
4
6
|
UNMARK_AS_DRAFT: 'unmark_as_draft',
|
|
5
|
-
SHARE_SDOC: 'share_sdoc'
|
|
6
|
-
|
|
7
|
+
SHARE_SDOC: 'share_sdoc',
|
|
8
|
+
PUBLISH_DOCUMENT: 'publish_document',
|
|
9
|
+
PUBLISH_DOCUMENT_ERROR: 'publish_document_error',
|
|
10
|
+
DOCUMENT_REPLACED: 'document_replaced',
|
|
11
|
+
DOCUMENT_REPLACED_ERROR: 'document_replaced_error'
|
|
12
|
+
};
|
|
13
|
+
export var MODE = {
|
|
14
|
+
DIFF_VIEWER: 'diff-viewer',
|
|
15
|
+
VIEWER: 'viewer',
|
|
16
|
+
EDITOR: 'editor'
|
|
17
|
+
};
|
|
18
|
+
export var TIP_TYPE = {
|
|
19
|
+
DELETE_NO_CHANGES_REVISION: 'delete_no_changes_revision',
|
|
20
|
+
MERGE: 'merge',
|
|
21
|
+
HAS_CONFLICT_BEFORE_PUBLISH: 'has_conflict_before_publish',
|
|
22
|
+
HAS_BEEN_PUBLISHED: 'has_been_published',
|
|
23
|
+
HAS_BEEN_REPLACED: 'has_been_merge',
|
|
24
|
+
HAS_CONFLICT_BEFORE_VIEW_CHANGES: 'has_conflict_before_view_changes'
|
|
25
|
+
};
|
|
26
|
+
export var TIP_TITLE = (_TIP_TITLE = {}, _defineProperty(_TIP_TITLE, TIP_TYPE.DELETE_NO_CHANGES_REVISION, 'Tip'), _defineProperty(_TIP_TITLE, TIP_TYPE.MERGE, 'Tip'), _defineProperty(_TIP_TITLE, TIP_TYPE.HAS_CONFLICT_BEFORE_PUBLISH, 'Tip'), _defineProperty(_TIP_TITLE, TIP_TYPE.HAS_BEEN_PUBLISHED, 'Tip'), _defineProperty(_TIP_TITLE, TIP_TYPE.HAS_BEEN_REPLACED, 'Tip'), _defineProperty(_TIP_TITLE, TIP_TYPE.HAS_CONFLICT_BEFORE_VIEW_CHANGES, 'Tip'), _TIP_TITLE);
|
|
27
|
+
export var TIP_CONTENT = (_TIP_CONTENT = {}, _defineProperty(_TIP_CONTENT, TIP_TYPE.DELETE_NO_CHANGES_REVISION, 'Rebase_delete_no_change_revision_tip'), _defineProperty(_TIP_CONTENT, TIP_TYPE.MERGE, 'Merge_tip'), _defineProperty(_TIP_CONTENT, TIP_TYPE.HAS_CONFLICT_BEFORE_PUBLISH, 'Has_conflict_before_publish_tip'), _defineProperty(_TIP_CONTENT, TIP_TYPE.HAS_BEEN_PUBLISHED, 'Has_been_published_tip'), _defineProperty(_TIP_CONTENT, TIP_TYPE.HAS_BEEN_REPLACED, 'Has_been_replaced_tip'), _defineProperty(_TIP_CONTENT, TIP_TYPE.HAS_CONFLICT_BEFORE_VIEW_CHANGES, 'Has_conflict_before_view_changes_tip'), _TIP_CONTENT);
|
package/dist/context.js
CHANGED
|
@@ -10,6 +10,9 @@ var Context = /*#__PURE__*/function () {
|
|
|
10
10
|
this.initSettings = function () {
|
|
11
11
|
_this.settings = window.seafile ? window.seafile : window.seafileConfig;
|
|
12
12
|
};
|
|
13
|
+
// saveDocContentByRebase(content) {
|
|
14
|
+
// return this.sdocServerApi.saveDocContentByRebase(content);
|
|
15
|
+
// }
|
|
13
16
|
this.uploadLocalImage = function (imageFile) {
|
|
14
17
|
var docUuid = _this.getSetting('docUuid');
|
|
15
18
|
return _this.api.uploadSdocImage(docUuid, imageFile).then(function (res) {
|
|
@@ -45,6 +48,13 @@ var Context = /*#__PURE__*/function () {
|
|
|
45
48
|
if (this.settings[key] === false) return this.settings[key];
|
|
46
49
|
return this.settings[key] || '';
|
|
47
50
|
}
|
|
51
|
+
}, {
|
|
52
|
+
key: "updateSettings",
|
|
53
|
+
value: function updateSettings(update) {
|
|
54
|
+
for (var key in update) {
|
|
55
|
+
this.settings[key] = update[key];
|
|
56
|
+
}
|
|
57
|
+
}
|
|
48
58
|
}, {
|
|
49
59
|
key: "getViewConfig",
|
|
50
60
|
value: function getViewConfig() {
|
|
@@ -156,14 +166,15 @@ var Context = /*#__PURE__*/function () {
|
|
|
156
166
|
}, {
|
|
157
167
|
key: "publishSdocRevision",
|
|
158
168
|
value: function publishSdocRevision() {
|
|
169
|
+
var replace = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 1;
|
|
159
170
|
var docUuid = this.getSetting('docUuid');
|
|
160
|
-
return this.api.sdocPublishRevision(docUuid);
|
|
171
|
+
return this.api.sdocPublishRevision(docUuid, replace);
|
|
161
172
|
}
|
|
162
173
|
}, {
|
|
163
|
-
key: "
|
|
164
|
-
value: function
|
|
174
|
+
key: "getSeadocOriginFileDownloadLink",
|
|
175
|
+
value: function getSeadocOriginFileDownloadLink() {
|
|
165
176
|
var docUuid = this.getSetting('docUuid');
|
|
166
|
-
return this.api.
|
|
177
|
+
return this.api.getSeadocOriginFileDownloadLink(docUuid);
|
|
167
178
|
}
|
|
168
179
|
}, {
|
|
169
180
|
key: "getSdocRevisionsCount",
|
|
@@ -177,6 +188,26 @@ var Context = /*#__PURE__*/function () {
|
|
|
177
188
|
var docUuid = this.getSetting('docUuid');
|
|
178
189
|
return this.api.getSdocRevisions(docUuid, page, perPage);
|
|
179
190
|
}
|
|
191
|
+
}, {
|
|
192
|
+
key: "deleteSdocRevision",
|
|
193
|
+
value: function deleteSdocRevision() {
|
|
194
|
+
var docUuid = this.getSetting('docUuid');
|
|
195
|
+
return this.api.deleteSdocRevision(docUuid);
|
|
196
|
+
}
|
|
197
|
+
}, {
|
|
198
|
+
key: "updateSdocRevision",
|
|
199
|
+
value: function updateSdocRevision() {
|
|
200
|
+
var docUuid = this.getSetting('docUuid');
|
|
201
|
+
return this.api.updateSdocRevision(docUuid);
|
|
202
|
+
}
|
|
203
|
+
}, {
|
|
204
|
+
key: "getFileHistoryVersion",
|
|
205
|
+
value: function getFileHistoryVersion(fileVersion, filePath) {
|
|
206
|
+
var docUuid = this.getSetting('docUuid');
|
|
207
|
+
return this.api.getFileHistoryVersion(docUuid, fileVersion, filePath);
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
// local files
|
|
180
211
|
}, {
|
|
181
212
|
key: "getSdocLocalFiles",
|
|
182
213
|
value: function getSdocLocalFiles(p) {
|