@seafile/sdoc-editor 1.0.176 → 1.0.177
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/basic-sdk/comment/components/comment-editor.js +0 -1
- package/dist/basic-sdk/comment/components/comment-item-wrapper.js +19 -10
- package/dist/basic-sdk/comment/components/comment-list.css +2 -6
- package/dist/basic-sdk/comment/components/comment-list.js +29 -39
- package/dist/basic-sdk/comment/components/editor-comment.js +13 -2
- package/dist/basic-sdk/extension/plugins/text-style/menu/comemnt-editor-menu.js +7 -11
- package/dist/basic-sdk/extension/plugins/text-style/menu/index.js +3 -16
- package/dist/components/doc-operations/revision-operations/more-revision-operations/index.js +4 -0
- package/dist/components/doc-operations/revision-operations/revisions/index.js +13 -0
- package/dist/constants/index.js +3 -1
- package/package.json +1 -1
- package/public/media/sdoc-editor-font/iconfont.css +542 -0
- package/public/media/sdoc-editor-font/iconfont.eot +0 -0
- package/public/media/sdoc-editor-font/iconfont.svg +16 -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 +38 -6
|
@@ -30,7 +30,9 @@ const CommentItemWrapper = _ref => {
|
|
|
30
30
|
updateScrollPosition,
|
|
31
31
|
hiddenComment,
|
|
32
32
|
setCurrentCommentGroup,
|
|
33
|
-
onCommentClick
|
|
33
|
+
onCommentClick,
|
|
34
|
+
isEmptyComment,
|
|
35
|
+
addNewComment
|
|
34
36
|
} = _ref;
|
|
35
37
|
const listRef = (0, _react.useRef)(null);
|
|
36
38
|
const {
|
|
@@ -38,7 +40,7 @@ const CommentItemWrapper = _ref => {
|
|
|
38
40
|
} = (0, _useCommentContext.useCommentContext)();
|
|
39
41
|
const scrollRef = (0, _react.useRef)(document.querySelector('.sdoc-scroll-container'));
|
|
40
42
|
const [isShowDeleteDialog, setIsShowDeleteDialog] = (0, _react.useState)(false);
|
|
41
|
-
const commentOpToolsId = `commentOpTools_${comment.id}`;
|
|
43
|
+
const commentOpToolsId = `commentOpTools_${comment === null || comment === void 0 ? void 0 : comment.id}`;
|
|
42
44
|
const deleteComment = (0, _react.useCallback)(async commentId => {
|
|
43
45
|
await _context.default.deleteComment(commentId);
|
|
44
46
|
const {
|
|
@@ -249,12 +251,11 @@ const CommentItemWrapper = _ref => {
|
|
|
249
251
|
}, [isActive]);
|
|
250
252
|
const className = (0, _classnames.default)('comment-ui-container', {
|
|
251
253
|
'active': isActive,
|
|
252
|
-
'sdoc-resolved': comment.resolved,
|
|
254
|
+
'sdoc-resolved': comment === null || comment === void 0 ? void 0 : comment.resolved,
|
|
253
255
|
'd-flex flex-column': element,
|
|
254
256
|
'global-comment-item-detail-wrapper': isGlobalComment,
|
|
255
257
|
'comment-item-detail-wrapper': !isGlobalComment
|
|
256
258
|
});
|
|
257
|
-
const tip = comment.resolved ? 'Reopen_discussion' : 'Enter_reply_shift_Enter_for_new_line_Enter_to_send';
|
|
258
259
|
const handleScrollToArticle = (0, _react.useCallback)(e => {
|
|
259
260
|
e.stopPropagation();
|
|
260
261
|
const dom = _slateReact.ReactEditor.toDOMNode(editor, element);
|
|
@@ -265,7 +266,7 @@ const CommentItemWrapper = _ref => {
|
|
|
265
266
|
});
|
|
266
267
|
}, [editor, element, scrollRef]);
|
|
267
268
|
return /*#__PURE__*/_react.default.createElement("div", {
|
|
268
|
-
id: `comment-item-wrapper_${comment.id}`,
|
|
269
|
+
id: `comment-item-wrapper_${comment === null || comment === void 0 ? void 0 : comment.id}`,
|
|
269
270
|
className: className,
|
|
270
271
|
onClick: onItemClick
|
|
271
272
|
}, element && /*#__PURE__*/_react.default.createElement("div", {
|
|
@@ -275,7 +276,7 @@ const CommentItemWrapper = _ref => {
|
|
|
275
276
|
className: "sdocfont sdoc-comment-quote mr-2"
|
|
276
277
|
}), /*#__PURE__*/_react.default.createElement("div", {
|
|
277
278
|
className: "comment-item-selected-text"
|
|
278
|
-
}, _slate.Node.string(element))), /*#__PURE__*/_react.default.createElement("div", {
|
|
279
|
+
}, _slate.Node.string(element))), !isEmptyComment && /*#__PURE__*/_react.default.createElement("div", {
|
|
279
280
|
ref: listRef,
|
|
280
281
|
className: "comment-item-list"
|
|
281
282
|
}, /*#__PURE__*/_react.default.createElement(_commentItemContent.default, {
|
|
@@ -297,11 +298,19 @@ const CommentItemWrapper = _ref => {
|
|
|
297
298
|
updateReply
|
|
298
299
|
};
|
|
299
300
|
return /*#__PURE__*/_react.default.createElement(_commentItemReply.default, props);
|
|
300
|
-
})), !isGlobalComment &&
|
|
301
|
-
className: "sdoc-reply-wrapper"
|
|
302
|
-
|
|
301
|
+
})), !isGlobalComment && /*#__PURE__*/_react.default.createElement("div", {
|
|
302
|
+
className: "sdoc-reply-wrapper",
|
|
303
|
+
style: {
|
|
304
|
+
paddingTop: isEmptyComment ? '16px' : ''
|
|
305
|
+
}
|
|
306
|
+
}, isEmptyComment && /*#__PURE__*/_react.default.createElement(_commentEditor.default, {
|
|
307
|
+
type: "comment",
|
|
308
|
+
placeholder: 'Enter_reply_shift_Enter_for_new_line_Enter_to_send',
|
|
309
|
+
insertContent: addNewComment,
|
|
310
|
+
hiddenComment: hiddenComment
|
|
311
|
+
}), !isEmptyComment && /*#__PURE__*/_react.default.createElement(_commentEditor.default, {
|
|
303
312
|
type: "reply",
|
|
304
|
-
placeholder:
|
|
313
|
+
placeholder: 'Enter_reply_shift_Enter_for_new_line_Enter_to_send',
|
|
305
314
|
insertContent: insertContent,
|
|
306
315
|
hiddenComment: hiddenComment
|
|
307
316
|
})), isShowDeleteDialog && isActive && /*#__PURE__*/_react.default.createElement(_commentDeletePopover.default, {
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
}
|
|
10
10
|
|
|
11
11
|
.sdoc-comment-list-container .comment-ui-container {
|
|
12
|
-
background-color: rgba(255, 255, 255
|
|
12
|
+
background-color: rgba(255, 255, 255);
|
|
13
13
|
margin-bottom: 0px;
|
|
14
14
|
box-shadow: 0 1px 3px rgba(0, 0, 0, .15), 0 4px 8px 3px rgba(0, 0, 0, .15);
|
|
15
15
|
padding: 16px;
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
.sdoc-comment-list-container .comment-ui-container.active {
|
|
38
38
|
position: relative;
|
|
39
39
|
left: -5px;
|
|
40
|
-
background: rgba(255, 255, 255,
|
|
40
|
+
background: rgba(255, 255, 255, 1);
|
|
41
41
|
box-shadow: 0 1px 3px rgba(0, 0, 0, .15), 0 4px 8px 3px rgba(0, 0, 0, .15);
|
|
42
42
|
}
|
|
43
43
|
|
|
@@ -340,10 +340,6 @@
|
|
|
340
340
|
justify-content: flex-end;
|
|
341
341
|
}
|
|
342
342
|
|
|
343
|
-
.sdoc-reply-wrapper {
|
|
344
|
-
padding: 0 10px;
|
|
345
|
-
}
|
|
346
|
-
|
|
347
343
|
.sdoc-doc-comment-editor-container.sdoc-comment-list-container .comment-ui-container {
|
|
348
344
|
padding-left: 10px;
|
|
349
345
|
padding-right: 10px;
|
|
@@ -11,24 +11,23 @@ var _dayjs = _interopRequireDefault(require("dayjs"));
|
|
|
11
11
|
var _context = _interopRequireDefault(require("../../../context"));
|
|
12
12
|
var _useSelectionPosition = require("../../hooks/use-selection-position");
|
|
13
13
|
var _useCommentContext = require("../hooks/comment-hooks/use-comment-context");
|
|
14
|
-
var _commentEditor = _interopRequireDefault(require("./comment-editor"));
|
|
15
14
|
var _commentItemWrapper = _interopRequireDefault(require("./comment-item-wrapper"));
|
|
16
15
|
var _commentItemCollapseWrapper = _interopRequireDefault(require("./comment-item-collapse-wrapper"));
|
|
17
16
|
require("./comment-list.css");
|
|
18
17
|
const CommentList = _ref => {
|
|
19
|
-
var _topLevelComment$repl, _topLevelComment$repl2;
|
|
20
18
|
let {
|
|
21
19
|
editor,
|
|
22
|
-
comments,
|
|
20
|
+
comments = [],
|
|
21
|
+
commentDetail = {},
|
|
23
22
|
activeElement,
|
|
24
|
-
|
|
23
|
+
isShowCommentDetail,
|
|
24
|
+
onSetCommentDetail,
|
|
25
|
+
deleteUnseenNotifications
|
|
25
26
|
} = _ref;
|
|
26
|
-
const commentRef = (0, _react.useRef)(null);
|
|
27
27
|
const position = (0, _useSelectionPosition.useCommentListPosition)(activeElement);
|
|
28
28
|
const {
|
|
29
29
|
dispatch
|
|
30
30
|
} = (0, _useCommentContext.useCommentContext)();
|
|
31
|
-
const [isShowCommentDetail, setIsShowCommentDetail] = (0, _react.useState)(false);
|
|
32
31
|
const insertComment = (0, _react.useCallback)(async (elementId, comment) => {
|
|
33
32
|
const res = await _context.default.insertComment(comment);
|
|
34
33
|
const {
|
|
@@ -48,7 +47,8 @@ const CommentList = _ref => {
|
|
|
48
47
|
comment: newComment
|
|
49
48
|
}
|
|
50
49
|
});
|
|
51
|
-
|
|
50
|
+
onSetCommentDetail(newComment);
|
|
51
|
+
}, [dispatch, onSetCommentDetail]);
|
|
52
52
|
const insertContent = (0, _react.useCallback)(content => {
|
|
53
53
|
const user = _context.default.getUserInfo();
|
|
54
54
|
const elementId = activeElement === null || activeElement === void 0 ? void 0 : activeElement.id;
|
|
@@ -63,47 +63,37 @@ const CommentList = _ref => {
|
|
|
63
63
|
updated_at: time
|
|
64
64
|
};
|
|
65
65
|
insertComment(elementId, comment);
|
|
66
|
-
setIsShowCommentDetail(true);
|
|
67
66
|
}, [insertComment, activeElement === null || activeElement === void 0 ? void 0 : activeElement.id]);
|
|
68
|
-
const setCurrentCommentGroup = (0, _react.useCallback)(() => {
|
|
69
|
-
setIsShowCommentDetail(true);
|
|
70
|
-
}, []);
|
|
71
|
-
const topLevelComment = (comments === null || comments === void 0 ? void 0 : comments.length) > 0 ? comments[0] : {};
|
|
72
|
-
const replyCount = topLevelComment === null || topLevelComment === void 0 ? void 0 : (_topLevelComment$repl = topLevelComment.replies) === null || _topLevelComment$repl === void 0 ? void 0 : _topLevelComment$repl.length;
|
|
73
|
-
const latestReply = ((_topLevelComment$repl2 = topLevelComment.replies) === null || _topLevelComment$repl2 === void 0 ? void 0 : _topLevelComment$repl2.length) > 0 ? topLevelComment.replies[topLevelComment.replies.length - 1] : null;
|
|
74
67
|
return /*#__PURE__*/_react.default.createElement("div", {
|
|
75
|
-
ref: commentRef,
|
|
76
68
|
id: "sdoc-comment-list-container",
|
|
77
69
|
className: "sdoc-comment-list-container sdoc-comment-list-container-popover",
|
|
78
70
|
style: {
|
|
79
71
|
top: position.y,
|
|
80
72
|
width: '300px'
|
|
81
73
|
}
|
|
82
|
-
}, !isShowCommentDetail &&
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
topLevelComment: topLevelComment
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
74
|
+
}, !isShowCommentDetail && comments.map(comment => {
|
|
75
|
+
var _topLevelComment$repl, _topLevelComment$repl2;
|
|
76
|
+
const topLevelComment = comment || {};
|
|
77
|
+
const replyCount = topLevelComment === null || topLevelComment === void 0 ? void 0 : (_topLevelComment$repl = topLevelComment.replies) === null || _topLevelComment$repl === void 0 ? void 0 : _topLevelComment$repl.length;
|
|
78
|
+
const latestReply = ((_topLevelComment$repl2 = topLevelComment.replies) === null || _topLevelComment$repl2 === void 0 ? void 0 : _topLevelComment$repl2.length) > 0 ? topLevelComment.replies[topLevelComment.replies.length - 1] : null;
|
|
79
|
+
return /*#__PURE__*/_react.default.createElement(_commentItemCollapseWrapper.default, {
|
|
80
|
+
key: topLevelComment.id,
|
|
81
|
+
editor: editor,
|
|
82
|
+
topLevelComment: topLevelComment,
|
|
83
|
+
replyCount: replyCount,
|
|
84
|
+
latestReply: latestReply,
|
|
85
|
+
setCurrentCommentGroup: () => {
|
|
86
|
+
deleteUnseenNotifications && deleteUnseenNotifications(topLevelComment);
|
|
87
|
+
onSetCommentDetail(topLevelComment);
|
|
88
|
+
}
|
|
89
|
+
});
|
|
90
|
+
}), isShowCommentDetail && /*#__PURE__*/_react.default.createElement("div", {
|
|
98
91
|
className: "comment-list"
|
|
99
|
-
},
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
isActive: true
|
|
105
|
-
};
|
|
106
|
-
return /*#__PURE__*/_react.default.createElement(_commentItemWrapper.default, props);
|
|
92
|
+
}, /*#__PURE__*/_react.default.createElement(_commentItemWrapper.default, {
|
|
93
|
+
comment: commentDetail,
|
|
94
|
+
isActive: true,
|
|
95
|
+
isEmptyComment: Object.keys(commentDetail).length ? false : true,
|
|
96
|
+
addNewComment: insertContent
|
|
107
97
|
})));
|
|
108
98
|
};
|
|
109
99
|
var _default = exports.default = CommentList;
|
|
@@ -32,6 +32,8 @@ const EditorComment = _ref => {
|
|
|
32
32
|
const [activeElement, setActiveElement] = (0, _react.useState)(null); // The slate node currently activated by clicking
|
|
33
33
|
const [comments, setComments] = (0, _react.useState)([]);
|
|
34
34
|
const [isShowComments, setIsShowComments] = (0, _react.useState)(false);
|
|
35
|
+
const [isShowCommentDetail, setIsShowCommentDetail] = (0, _react.useState)(true);
|
|
36
|
+
const [commentDetail, setCommentDetail] = (0, _react.useState)({});
|
|
35
37
|
const onAddCommentToggle = (0, _react.useCallback)(event => {
|
|
36
38
|
event.stopPropagation();
|
|
37
39
|
let activeElement = currentSelectionElement;
|
|
@@ -41,6 +43,8 @@ const EditorComment = _ref => {
|
|
|
41
43
|
}
|
|
42
44
|
setActiveElement(activeElement);
|
|
43
45
|
setIsShowComments(true);
|
|
46
|
+
setIsShowCommentDetail(true);
|
|
47
|
+
setCommentDetail({});
|
|
44
48
|
}, [currentSelectionElement]);
|
|
45
49
|
const onSelectElement = (0, _react.useCallback)(elementId => {
|
|
46
50
|
const activeElement = (0, _index.getCommentElementById)(elementId, editor);
|
|
@@ -48,9 +52,15 @@ const EditorComment = _ref => {
|
|
|
48
52
|
const unresolvedComments = element_comments_map[elementId].filter(item => !item.resolved);
|
|
49
53
|
setComments(unresolvedComments);
|
|
50
54
|
setIsShowComments(true);
|
|
55
|
+
setIsShowCommentDetail(false);
|
|
51
56
|
}, [editor, element_comments_map]);
|
|
57
|
+
const onSetCommentDetail = (0, _react.useCallback)(comment => {
|
|
58
|
+
setCommentDetail(comment);
|
|
59
|
+
setIsShowCommentDetail(true);
|
|
60
|
+
}, []);
|
|
52
61
|
const hiddenComment = (0, _react.useCallback)(() => {
|
|
53
62
|
setComments([]);
|
|
63
|
+
setCommentDetail({});
|
|
54
64
|
setIsShowComments(false);
|
|
55
65
|
}, []);
|
|
56
66
|
|
|
@@ -117,8 +127,9 @@ const EditorComment = _ref => {
|
|
|
117
127
|
editor: editor,
|
|
118
128
|
comments: comments,
|
|
119
129
|
activeElement: activeElement,
|
|
120
|
-
|
|
121
|
-
|
|
130
|
+
isShowCommentDetail: isShowCommentDetail,
|
|
131
|
+
commentDetail: commentDetail,
|
|
132
|
+
onSetCommentDetail: onSetCommentDetail,
|
|
122
133
|
deleteUnseenNotifications: deleteUnseenNotifications
|
|
123
134
|
})));
|
|
124
135
|
};
|
|
@@ -12,20 +12,14 @@ var _core = require("../../../core");
|
|
|
12
12
|
var _commons = require("../../../commons");
|
|
13
13
|
var _helpers = require("../helpers");
|
|
14
14
|
var _menusConfig = require("../../../constants/menus-config");
|
|
15
|
-
const
|
|
16
|
-
let {
|
|
17
|
-
id
|
|
18
|
-
} = _ref;
|
|
19
|
-
return [_menusConfig.BOLD, _menusConfig.ITALIC].includes(id);
|
|
20
|
-
};
|
|
21
|
-
const CommentEditorTextStyleMenuList = _ref2 => {
|
|
15
|
+
const CommentEditorTextStyleMenuList = _ref => {
|
|
22
16
|
let {
|
|
23
17
|
editor,
|
|
24
18
|
isRichEditor,
|
|
25
19
|
className,
|
|
26
20
|
idPrefix,
|
|
27
21
|
readonly
|
|
28
|
-
} =
|
|
22
|
+
} = _ref;
|
|
29
23
|
const isActive = (0, _react.useCallback)(type => {
|
|
30
24
|
const isMark = (0, _helpers.getValue)(editor, type);
|
|
31
25
|
return !!isMark;
|
|
@@ -50,8 +44,10 @@ const CommentEditorTextStyleMenuList = _ref2 => {
|
|
|
50
44
|
(0, _core.focusEditor)(editor);
|
|
51
45
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
52
46
|
}, [editor]);
|
|
53
|
-
const getTextStyleList = (0, _react.useCallback)(
|
|
54
|
-
|
|
47
|
+
const getTextStyleList = (0, _react.useCallback)(() => {
|
|
48
|
+
const styleMenus = _constants.MENUS_CONFIG_MAP[_constants.TEXT_STYLE];
|
|
49
|
+
const commentMenus = styleMenus.filter(item => [_menusConfig.BOLD, _menusConfig.ITALIC].includes(item.id));
|
|
50
|
+
return commentMenus.map(item => {
|
|
55
51
|
let itemProps = {
|
|
56
52
|
isRichEditor,
|
|
57
53
|
className,
|
|
@@ -68,7 +64,7 @@ const CommentEditorTextStyleMenuList = _ref2 => {
|
|
|
68
64
|
|
|
69
65
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
70
66
|
}, [editor, readonly]);
|
|
71
|
-
const list = getTextStyleList(
|
|
67
|
+
const list = getTextStyleList();
|
|
72
68
|
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, list.map((itemProps, index) => /*#__PURE__*/_react.default.createElement(_commons.MenuItem, Object.assign({
|
|
73
69
|
key: index
|
|
74
70
|
}, itemProps))));
|
|
@@ -17,15 +17,7 @@ var _fontSizeScale = _interopRequireDefault(require("../../font/menu/font-size/f
|
|
|
17
17
|
var _helpers2 = require("../helpers");
|
|
18
18
|
var _useColorContext = require("../../../../hooks/use-color-context");
|
|
19
19
|
var _mouseEvent = require("../../../../utils/mouse-event");
|
|
20
|
-
|
|
21
|
-
var _constants2 = require("../../../../constants");
|
|
22
|
-
const filterFontTypes = _ref => {
|
|
23
|
-
let {
|
|
24
|
-
id
|
|
25
|
-
} = _ref;
|
|
26
|
-
return [_menusConfig.BOLD, _menusConfig.ITALIC].includes(id);
|
|
27
|
-
};
|
|
28
|
-
const TextStyleMenuList = _ref2 => {
|
|
20
|
+
const TextStyleMenuList = _ref => {
|
|
29
21
|
let {
|
|
30
22
|
editor,
|
|
31
23
|
t,
|
|
@@ -33,10 +25,9 @@ const TextStyleMenuList = _ref2 => {
|
|
|
33
25
|
className,
|
|
34
26
|
idPrefix,
|
|
35
27
|
readonly
|
|
36
|
-
} =
|
|
28
|
+
} = _ref;
|
|
37
29
|
let selectedFontSize = (0, _helpers.getFontSize)(editor);
|
|
38
30
|
let selectedFontSizeValue = selectedFontSize;
|
|
39
|
-
const isCommentEditor = editor.editorType === _constants2.COMMENT_EDITOR;
|
|
40
31
|
const {
|
|
41
32
|
lastUsedFontColor,
|
|
42
33
|
updateLastUsedFontColor,
|
|
@@ -114,17 +105,13 @@ const TextStyleMenuList = _ref2 => {
|
|
|
114
105
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
115
106
|
}, [editor, lastUsedFontColor, lastUsedHighlightColor, readonly]);
|
|
116
107
|
let list = getTextStyleList(_constants.TEXT_STYLE);
|
|
117
|
-
// Filter for comment editor
|
|
118
|
-
if (isCommentEditor) {
|
|
119
|
-
list = list.filter(filterFontTypes);
|
|
120
|
-
}
|
|
121
108
|
const dropdownList = getTextStyleList(_constants.TEXT_STYLE_MORE);
|
|
122
109
|
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, list.map((itemProps, index) => {
|
|
123
110
|
const Component = itemProps.isColor ? _commons.ColorMenu : _commons.MenuItem;
|
|
124
111
|
return /*#__PURE__*/_react.default.createElement(Component, Object.assign({
|
|
125
112
|
key: index
|
|
126
113
|
}, itemProps));
|
|
127
|
-
}),
|
|
114
|
+
}), /*#__PURE__*/_react.default.createElement(_commons.MoreDropdown, null, dropdownList.map((itemProps, index) => /*#__PURE__*/_react.default.createElement(_commons.MenuItem, Object.assign({
|
|
128
115
|
key: index
|
|
129
116
|
}, itemProps))), /*#__PURE__*/_react.default.createElement(_fontSizeScale.default, {
|
|
130
117
|
disabled: isDisabled(),
|
package/dist/components/doc-operations/revision-operations/more-revision-operations/index.js
CHANGED
|
@@ -11,11 +11,14 @@ var _reactI18next = require("react-i18next");
|
|
|
11
11
|
var _reactstrap = require("reactstrap");
|
|
12
12
|
var _context = _interopRequireDefault(require("../../../../context"));
|
|
13
13
|
var _toast = _interopRequireDefault(require("../../../toast"));
|
|
14
|
+
var _basicSdk = require("../../../../basic-sdk");
|
|
15
|
+
var _constants = require("../../../../constants");
|
|
14
16
|
require("./index.css");
|
|
15
17
|
const MoreRevisionOperations = _ref => {
|
|
16
18
|
let {
|
|
17
19
|
t
|
|
18
20
|
} = _ref;
|
|
21
|
+
const eventBus = _basicSdk.EventBus.getInstance();
|
|
19
22
|
const [isDropdownOpen, setIsDropdownOpen] = (0, _react.useState)(false);
|
|
20
23
|
const toggleDropdown = (0, _react.useCallback)(isDropdownOpen => {
|
|
21
24
|
setIsDropdownOpen(!isDropdownOpen);
|
|
@@ -26,6 +29,7 @@ const MoreRevisionOperations = _ref => {
|
|
|
26
29
|
const siteRoot = _context.default.getSetting('siteRoot');
|
|
27
30
|
const revisionURL = `${siteRoot}lib/${repoID}/revisions/${res.data.revision_id}/`;
|
|
28
31
|
window.open(revisionURL, '_blank');
|
|
32
|
+
eventBus.dispatch(_constants.EXTERNAL_EVENT.NEW_REVISION);
|
|
29
33
|
}).catch(error => {
|
|
30
34
|
_toast.default.danger(t('Error'));
|
|
31
35
|
});
|
|
@@ -12,13 +12,19 @@ var _context = _interopRequireDefault(require("../../../../context"));
|
|
|
12
12
|
var _revisionsDialog = _interopRequireDefault(require("./revisions-dialog"));
|
|
13
13
|
var _utils = require("../../../../utils");
|
|
14
14
|
var _toast = _interopRequireDefault(require("../../../toast"));
|
|
15
|
+
var _basicSdk = require("../../../../basic-sdk");
|
|
16
|
+
var _constants = require("../../../../constants");
|
|
15
17
|
require("./index.css");
|
|
16
18
|
const Revisions = () => {
|
|
19
|
+
const eventBus = _basicSdk.EventBus.getInstance();
|
|
17
20
|
const {
|
|
18
21
|
t
|
|
19
22
|
} = (0, _reactI18next.useTranslation)();
|
|
20
23
|
const [revisionsCount, setRevisionsCount] = (0, _react.useState)(0);
|
|
21
24
|
const [isShowRevisions, setShowRevisions] = (0, _react.useState)(false);
|
|
25
|
+
const autoIncrementRevisionsCount = (0, _react.useCallback)(() => {
|
|
26
|
+
setRevisionsCount(revisionsCount + 1);
|
|
27
|
+
}, [revisionsCount]);
|
|
22
28
|
|
|
23
29
|
// did mount
|
|
24
30
|
(0, _react.useEffect)(() => {
|
|
@@ -32,6 +38,13 @@ const Revisions = () => {
|
|
|
32
38
|
|
|
33
39
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
34
40
|
}, []);
|
|
41
|
+
(0, _react.useEffect)(() => {
|
|
42
|
+
const autoIncrementRevisionSubscribe = eventBus.subscribe(_constants.EXTERNAL_EVENT.NEW_REVISION, autoIncrementRevisionsCount);
|
|
43
|
+
return () => {
|
|
44
|
+
autoIncrementRevisionSubscribe();
|
|
45
|
+
};
|
|
46
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
47
|
+
}, [autoIncrementRevisionsCount]);
|
|
35
48
|
const showRevisions = (0, _react.useCallback)(() => {
|
|
36
49
|
setShowRevisions(true);
|
|
37
50
|
}, []);
|
package/dist/constants/index.js
CHANGED
|
@@ -40,7 +40,9 @@ const EXTERNAL_EVENT = exports.EXTERNAL_EVENT = {
|
|
|
40
40
|
INSERT_LINK: 'insert_link',
|
|
41
41
|
// document
|
|
42
42
|
COLLABORATORS_UPDATED: 'collaborators_updated',
|
|
43
|
-
IMAGE_COLUMN_TOGGLE: 'Image_column_toggle'
|
|
43
|
+
IMAGE_COLUMN_TOGGLE: 'Image_column_toggle',
|
|
44
|
+
// revise
|
|
45
|
+
NEW_REVISION: 'new_revision'
|
|
44
46
|
};
|
|
45
47
|
const TIP_TYPE = exports.TIP_TYPE = {
|
|
46
48
|
DELETE_NO_CHANGES_REVISION: 'delete_no_changes_revision',
|
package/package.json
CHANGED
|
@@ -0,0 +1,542 @@
|
|
|
1
|
+
@font-face {
|
|
2
|
+
font-family: "sdocfont"; /* Project id 4097705 */
|
|
3
|
+
src: url('iconfont.eot?t=1734577970007'); /* IE9 */
|
|
4
|
+
src: url('iconfont.eot?t=1734577970007#iefix') format('embedded-opentype'), /* IE6-IE8 */
|
|
5
|
+
url('iconfont.woff2?t=1734577970007') format('woff2'),
|
|
6
|
+
url('iconfont.woff?t=1734577970007') format('woff'),
|
|
7
|
+
url('iconfont.ttf?t=1734577970007') format('truetype'),
|
|
8
|
+
url('iconfont.svg?t=1734577970007#sdocfont') format('svg');
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
.sdocfont {
|
|
12
|
+
font-family: "sdocfont" !important;
|
|
13
|
+
font-size: 16px;
|
|
14
|
+
font-style: normal;
|
|
15
|
+
-webkit-font-smoothing: antialiased;
|
|
16
|
+
-moz-osx-font-smoothing: grayscale;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.sdoc-send-arrow:before {
|
|
20
|
+
content: "\e67e";
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.sdoc-try-again:before {
|
|
24
|
+
content: "\e67f";
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.sdoc-ai-translate:before {
|
|
28
|
+
content: "\e680";
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.sdoc-insert-below:before {
|
|
32
|
+
content: "\e681";
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.sdoc-continue-writing:before {
|
|
36
|
+
content: "\e682";
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.sdoc-replace:before {
|
|
40
|
+
content: "\e683";
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.sdoc-adjust:before {
|
|
44
|
+
content: "\e684";
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
.sdoc-ask-ai:before {
|
|
48
|
+
content: "\e685";
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
.sdoc-check-mark:before {
|
|
52
|
+
content: "\e67d";
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.sdoc-play:before {
|
|
56
|
+
content: "\e67c";
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
.sdoc-video:before {
|
|
60
|
+
content: "\e67b";
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.sdoc-mark-as-resolved:before {
|
|
64
|
+
content: "\e67a";
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
.sdoc-multi-column:before {
|
|
68
|
+
content: "\e679";
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
.sdoc-table-of-content-outline:before {
|
|
72
|
+
content: "\e678";
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
.sdoc-table-of-content:before {
|
|
76
|
+
content: "\e628";
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
.sdoc-info:before {
|
|
80
|
+
content: "\e677";
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
.sdoc-inline-code:before {
|
|
84
|
+
content: "\e676";
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
.sdoc-sort:before {
|
|
88
|
+
content: "\e674";
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
.sdoc-set-up:before {
|
|
92
|
+
content: "\e675";
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
.sdoc-filter1:before {
|
|
96
|
+
content: "\e672";
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
.sdoc-eye-slash:before {
|
|
100
|
+
content: "\e673";
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
.sdoc-settings:before {
|
|
104
|
+
content: "\e671";
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
.sdoc-seatable-table:before {
|
|
108
|
+
content: "\e66f";
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
.sdoc-more-vertical-left:before {
|
|
112
|
+
content: "\e670";
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
.sdoc-text-style:before {
|
|
116
|
+
content: "\e66e";
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
.sdoc-choose-column:before {
|
|
120
|
+
content: "\e66d";
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
.sdoc-history-switch:before {
|
|
124
|
+
content: "\e66c";
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
.sdoc-save:before {
|
|
128
|
+
content: "\e66b";
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
.sdoc-center-alignment:before {
|
|
132
|
+
content: "\e668";
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
.sdoc-bottom-alignment:before {
|
|
136
|
+
content: "\e669";
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
.sdoc-top-alignment:before {
|
|
140
|
+
content: "\e66a";
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
.sdoc-all-read:before {
|
|
144
|
+
content: "\e65d";
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
.sdoc-freezed:before {
|
|
148
|
+
content: "\e667";
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
.sdoc-callout-color:before {
|
|
152
|
+
content: "\e666";
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
.sdoc-callout-icon:before {
|
|
156
|
+
content: "\e665";
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
.sdoc-trumpet:before {
|
|
160
|
+
content: "\e664";
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
.sdoc-light-bulb:before {
|
|
164
|
+
content: "\e663";
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
.sdoc-danger:before {
|
|
168
|
+
content: "\e662";
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
.sdoc-prohibit:before {
|
|
172
|
+
content: "\e661";
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
.sdoc-filter:before {
|
|
176
|
+
content: "\e65e";
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
.sdoc-chart:before {
|
|
180
|
+
content: "\e65b";
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
.sdoc-comment-quote:before {
|
|
184
|
+
content: "\e660";
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
.sdoc-find-replace:before {
|
|
188
|
+
content: "\e65f";
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
.sdoc-jump-to:before {
|
|
192
|
+
content: "\e65a";
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
.sdoc-callout:before {
|
|
196
|
+
content: "\e65c";
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
.sdoc-add:before {
|
|
200
|
+
content: "\e658";
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
.sdoc-tag:before {
|
|
204
|
+
content: "\e659";
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
.sdoc-describe:before {
|
|
208
|
+
content: "\e657";
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
.sdoc-add-comment:before {
|
|
212
|
+
content: "\e63b";
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
.sdoc-comment-count:before {
|
|
216
|
+
content: "\e656";
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
.sdoc-link-file:before {
|
|
220
|
+
content: "\e654";
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
.sdoc-sm-close:before {
|
|
224
|
+
content: "\e655";
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
.sdoc-merge-cell:before {
|
|
228
|
+
content: "\e653";
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
.sdoc-download:before {
|
|
232
|
+
content: "\e652";
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
.sdoc-next-page:before {
|
|
236
|
+
content: "\e626";
|
|
237
|
+
}
|
|
238
|
+
|
|
239
|
+
.sdoc-previous-page:before {
|
|
240
|
+
content: "\e651";
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
.sdoc-save-tip:before {
|
|
244
|
+
content: "\e650";
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
.sdoc-file:before {
|
|
248
|
+
content: "\e60f";
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
.sdoc-header6:before {
|
|
252
|
+
content: "\e60e";
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
.sdoc-more-vertical-right:before {
|
|
256
|
+
content: "\e60b";
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
.sdoc-more-vertical:before {
|
|
260
|
+
content: "\e60c";
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
.sdoc-append:before {
|
|
264
|
+
content: "\e60d";
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
.sdoc-quote1:before {
|
|
268
|
+
content: "\e60a";
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
.sdoc-cut:before {
|
|
272
|
+
content: "\e609";
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
.sdoc-header5:before {
|
|
276
|
+
content: "\e604";
|
|
277
|
+
}
|
|
278
|
+
|
|
279
|
+
.sdoc-header2:before {
|
|
280
|
+
content: "\e605";
|
|
281
|
+
}
|
|
282
|
+
|
|
283
|
+
.sdoc-header3:before {
|
|
284
|
+
content: "\e606";
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
.sdoc-header1:before {
|
|
288
|
+
content: "\e607";
|
|
289
|
+
}
|
|
290
|
+
|
|
291
|
+
.sdoc-header4:before {
|
|
292
|
+
content: "\e608";
|
|
293
|
+
}
|
|
294
|
+
|
|
295
|
+
.sdoc-text:before {
|
|
296
|
+
content: "\e603";
|
|
297
|
+
}
|
|
298
|
+
|
|
299
|
+
.sdoc-close1:before {
|
|
300
|
+
content: "\e647";
|
|
301
|
+
}
|
|
302
|
+
|
|
303
|
+
.sdoc-rename:before {
|
|
304
|
+
content: "\e620";
|
|
305
|
+
}
|
|
306
|
+
|
|
307
|
+
.sdoc-align-center:before {
|
|
308
|
+
content: "\e62e";
|
|
309
|
+
}
|
|
310
|
+
|
|
311
|
+
.sdoc-table:before {
|
|
312
|
+
content: "\e643";
|
|
313
|
+
}
|
|
314
|
+
|
|
315
|
+
.sdoc-list-ol:before {
|
|
316
|
+
content: "\e644";
|
|
317
|
+
}
|
|
318
|
+
|
|
319
|
+
.sdoc-strikethrough:before {
|
|
320
|
+
content: "\e645";
|
|
321
|
+
}
|
|
322
|
+
|
|
323
|
+
.sdoc-link:before {
|
|
324
|
+
content: "\e648";
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
.sdoc-list-ul:before {
|
|
328
|
+
content: "\e649";
|
|
329
|
+
}
|
|
330
|
+
|
|
331
|
+
.sdoc-auto-linefeed:before {
|
|
332
|
+
content: "\e64a";
|
|
333
|
+
}
|
|
334
|
+
|
|
335
|
+
.sdoc-delete-table:before {
|
|
336
|
+
content: "\e64b";
|
|
337
|
+
}
|
|
338
|
+
|
|
339
|
+
.sdoc-image:before {
|
|
340
|
+
content: "\e64c";
|
|
341
|
+
}
|
|
342
|
+
|
|
343
|
+
.sdoc-align-right:before {
|
|
344
|
+
content: "\e64d";
|
|
345
|
+
}
|
|
346
|
+
|
|
347
|
+
.sdoc-text-link:before {
|
|
348
|
+
content: "\e64e";
|
|
349
|
+
}
|
|
350
|
+
|
|
351
|
+
.sdoc-check-square:before {
|
|
352
|
+
content: "\e624";
|
|
353
|
+
}
|
|
354
|
+
|
|
355
|
+
.sdoc-italic:before {
|
|
356
|
+
content: "\e625";
|
|
357
|
+
}
|
|
358
|
+
|
|
359
|
+
.sdoc-copy:before {
|
|
360
|
+
content: "\e627";
|
|
361
|
+
}
|
|
362
|
+
|
|
363
|
+
.sdoc-caret-up:before {
|
|
364
|
+
content: "\e62f";
|
|
365
|
+
}
|
|
366
|
+
|
|
367
|
+
.sdoc-increase-font-size:before {
|
|
368
|
+
content: "\e630";
|
|
369
|
+
}
|
|
370
|
+
|
|
371
|
+
.sdoc-subscripts:before {
|
|
372
|
+
content: "\e632";
|
|
373
|
+
}
|
|
374
|
+
|
|
375
|
+
.sdoc-redo:before {
|
|
376
|
+
content: "\e633";
|
|
377
|
+
}
|
|
378
|
+
|
|
379
|
+
.sdoc-more:before {
|
|
380
|
+
content: "\e634";
|
|
381
|
+
}
|
|
382
|
+
|
|
383
|
+
.sdoc-column:before {
|
|
384
|
+
content: "\e611";
|
|
385
|
+
}
|
|
386
|
+
|
|
387
|
+
.sdoc-insert:before {
|
|
388
|
+
content: "\e636";
|
|
389
|
+
}
|
|
390
|
+
|
|
391
|
+
.sdoc-delete:before {
|
|
392
|
+
content: "\e637";
|
|
393
|
+
}
|
|
394
|
+
|
|
395
|
+
.sdoc-bg-color:before {
|
|
396
|
+
content: "\e638";
|
|
397
|
+
}
|
|
398
|
+
|
|
399
|
+
.sdoc-align-left:before {
|
|
400
|
+
content: "\e639";
|
|
401
|
+
}
|
|
402
|
+
|
|
403
|
+
.sdoc-underline:before {
|
|
404
|
+
content: "\e63a";
|
|
405
|
+
}
|
|
406
|
+
|
|
407
|
+
.sdoc-row:before {
|
|
408
|
+
content: "\e63c";
|
|
409
|
+
}
|
|
410
|
+
|
|
411
|
+
.sdoc-highlight-color:before {
|
|
412
|
+
content: "\e614";
|
|
413
|
+
}
|
|
414
|
+
|
|
415
|
+
.sdoc-format-clear:before {
|
|
416
|
+
content: "\e612";
|
|
417
|
+
}
|
|
418
|
+
|
|
419
|
+
.sdoc-drop-down:before {
|
|
420
|
+
content: "\e615";
|
|
421
|
+
}
|
|
422
|
+
|
|
423
|
+
.sdoc-font-color:before {
|
|
424
|
+
content: "\e616";
|
|
425
|
+
}
|
|
426
|
+
|
|
427
|
+
.sdoc-inline-link:before {
|
|
428
|
+
content: "\e617";
|
|
429
|
+
}
|
|
430
|
+
|
|
431
|
+
.sdoc-revoke:before {
|
|
432
|
+
content: "\e61a";
|
|
433
|
+
}
|
|
434
|
+
|
|
435
|
+
.sdoc-quote:before {
|
|
436
|
+
content: "\e61b";
|
|
437
|
+
}
|
|
438
|
+
|
|
439
|
+
.sdoc-bold:before {
|
|
440
|
+
content: "\e61d";
|
|
441
|
+
}
|
|
442
|
+
|
|
443
|
+
.sdoc-unlink:before {
|
|
444
|
+
content: "\e61e";
|
|
445
|
+
}
|
|
446
|
+
|
|
447
|
+
.sdoc-card-link:before {
|
|
448
|
+
content: "\e61f";
|
|
449
|
+
}
|
|
450
|
+
|
|
451
|
+
.sdoc-code-block:before {
|
|
452
|
+
content: "\e621";
|
|
453
|
+
}
|
|
454
|
+
|
|
455
|
+
.sdoc-reduce-font-size:before {
|
|
456
|
+
content: "\e623";
|
|
457
|
+
}
|
|
458
|
+
|
|
459
|
+
.sdoc-close:before {
|
|
460
|
+
content: "\e610";
|
|
461
|
+
}
|
|
462
|
+
|
|
463
|
+
.sdoc-superscripts:before {
|
|
464
|
+
content: "\e613";
|
|
465
|
+
}
|
|
466
|
+
|
|
467
|
+
.sdoc-document:before {
|
|
468
|
+
content: "\e646";
|
|
469
|
+
}
|
|
470
|
+
|
|
471
|
+
.sdoc-confirm:before {
|
|
472
|
+
content: "\e640";
|
|
473
|
+
}
|
|
474
|
+
|
|
475
|
+
.sdoc-more-options:before {
|
|
476
|
+
content: "\e641";
|
|
477
|
+
}
|
|
478
|
+
|
|
479
|
+
.sdoc-comments:before {
|
|
480
|
+
content: "\e642";
|
|
481
|
+
}
|
|
482
|
+
|
|
483
|
+
.sdoc-right-slide:before {
|
|
484
|
+
content: "\e602";
|
|
485
|
+
}
|
|
486
|
+
|
|
487
|
+
.sdoc-revise:before {
|
|
488
|
+
content: "\e63f";
|
|
489
|
+
}
|
|
490
|
+
|
|
491
|
+
.sdoc-starred:before {
|
|
492
|
+
content: "\e63d";
|
|
493
|
+
}
|
|
494
|
+
|
|
495
|
+
.sdoc-unstarred:before {
|
|
496
|
+
content: "\e63e";
|
|
497
|
+
}
|
|
498
|
+
|
|
499
|
+
.sdoc-cancel:before {
|
|
500
|
+
content: "\e631";
|
|
501
|
+
}
|
|
502
|
+
|
|
503
|
+
.sdoc-fullscreen:before {
|
|
504
|
+
content: "\e635";
|
|
505
|
+
}
|
|
506
|
+
|
|
507
|
+
.sdoc-check-circle:before {
|
|
508
|
+
content: "\e62a";
|
|
509
|
+
}
|
|
510
|
+
|
|
511
|
+
.sdoc-description:before {
|
|
512
|
+
content: "\e62b";
|
|
513
|
+
}
|
|
514
|
+
|
|
515
|
+
.sdoc-exclamation-triangle:before {
|
|
516
|
+
content: "\e62c";
|
|
517
|
+
}
|
|
518
|
+
|
|
519
|
+
.sdoc-exclamation-circle:before {
|
|
520
|
+
content: "\e62d";
|
|
521
|
+
}
|
|
522
|
+
|
|
523
|
+
.sdoc-history:before {
|
|
524
|
+
content: "\e618";
|
|
525
|
+
}
|
|
526
|
+
|
|
527
|
+
.sdoc-quote-left:before {
|
|
528
|
+
content: "\e619";
|
|
529
|
+
}
|
|
530
|
+
|
|
531
|
+
.sdoc-menu:before {
|
|
532
|
+
content: "\e61c";
|
|
533
|
+
}
|
|
534
|
+
|
|
535
|
+
.sdoc-share:before {
|
|
536
|
+
content: "\e622";
|
|
537
|
+
}
|
|
538
|
+
|
|
539
|
+
.sdoc-user:before {
|
|
540
|
+
content: "\e629";
|
|
541
|
+
}
|
|
542
|
+
|
|
Binary file
|
|
@@ -14,6 +14,22 @@
|
|
|
14
14
|
/>
|
|
15
15
|
<missing-glyph />
|
|
16
16
|
|
|
17
|
+
<glyph glyph-name="sdoc-send-arrow" unicode="" d="M1024 384c0-281.6-230.4-512-512-512S0 102.4 0 384 230.4 896 512 896s512-230.4 512-512zM476.8 652.8l-233.6-233.6c-19.2-19.2-19.2-54.4 0-73.6s54.4-19.2 73.6 0l144 144v-336c0-28.8 22.4-54.4 54.4-54.4s54.4 22.4 54.4 54.4V489.6l144-144c19.2-19.2 54.4-19.2 73.6 0s19.2 54.4 0 73.6l-233.6 233.6c-22.4 22.4-57.6 22.4-76.8 0z" horiz-adv-x="1024" />
|
|
18
|
+
|
|
19
|
+
<glyph glyph-name="sdoc-try-again" unicode="" d="M320 416L0 624 320 832v-160h352c195.2 0 352-156.8 352-352s-156.8-352-352-352H128v96h544c140.8 0 256 115.2 256 256s-115.2 256-256 256H320v-160z" horiz-adv-x="1024" />
|
|
20
|
+
|
|
21
|
+
<glyph glyph-name="sdoc-ai-translate" unicode="" d="M934.4-99.2l-64 131.2H576l-64-131.2c-12.8-22.4-41.6-35.2-67.2-22.4s-35.2 44.8-25.6 67.2l80 147.2 156.8 316.8c12.8 25.6 38.4 41.6 64 41.6s51.2-12.8 64-41.6l156.8-316.8 76.8-153.6c9.6-22.4 0-51.2-19.2-60.8-9.6-6.4-16-6.4-25.6-6.4-16 0-32 9.6-38.4 28.8zM624 128h192l-99.2 192-92.8-192z m-576-105.6c-19.2 0-32 9.6-41.6 28.8-9.6 22.4 0 51.2 22.4 60.8C131.2 160 224 230.4 297.6 313.6c-51.2 70.4-92.8 140.8-121.6 208-9.6 25.6 6.4 54.4 28.8 64 22.4 6.4 51.2-6.4 60.8-28.8 22.4-54.4 51.2-112 89.6-163.2 64 92.8 112 198.4 140.8 310.4h-448C19.2 704 0 723.2 0 752S19.2 800 48 800h256V848C304 876.8 323.2 896 352 896s48-19.2 48-48V800h256c28.8 0 48-19.2 48-48S684.8 704 656 704h-67.2c-28.8-140.8-92.8-272-176-384l70.4-57.6c16-12.8 19.2-48 0-64-19.2-19.2-44.8-16-64 0l-60.8 48c-80-89.6-176-163.2-288-217.6-9.6-3.2-19.2-6.4-22.4-6.4z" horiz-adv-x="1024" />
|
|
22
|
+
|
|
23
|
+
<glyph glyph-name="sdoc-insert-below" unicode="" d="M1024 864H0v-96h1024V864zM0 576v-288c0-172.8 134.4-297.6 307.2-304h12.8v-67.2c0-19.2 12.8-32 32-32 9.6 0 16 3.2 22.4 9.6L512 32l-137.6 137.6c-12.8 12.8-32 12.8-44.8 0-6.4-6.4-9.6-12.8-9.6-22.4v-67.2c-102.4 0-217.6 96-224 195.2V576H0z m608-480v-96h416v96H608zM256 480v-96h768v96H256z" horiz-adv-x="1024" />
|
|
24
|
+
|
|
25
|
+
<glyph glyph-name="sdoc-continue-writing" unicode="" d="M572.792306 886.271631c-12.79838 9.598785-28.796355 12.79838-44.794331 6.39919s-25.59676-12.79838-31.99595-28.796355L352.020247 521.517795c-6.39919-12.79838-12.79838-22.397165-22.397165-31.99595l-111.985827-83.189471C179.242115 374.336423 160.044544 319.943307 160.044544 275.148976c0-31.995951 6.39919-99.187447 19.197571-204.774083l-47.993926-111.985827c-15.997975-3.199595-28.796355-12.79838-31.995951-28.796355-6.39919-15.997975-3.199595-31.995951 9.598786-44.794331 6.39919-6.39919 15.997975-12.79838 28.796355-12.79838H767.967604v95.987852H256.032396l25.59676 41.594735 191.975703 60.792306c44.794331 15.997975 76.790281 47.993926 92.788257 92.788257l44.794331 131.183397c3.199595 12.79838 12.79838 22.397165 22.397165 31.99595l271.965579 255.967604c12.79838 9.598785 15.997975 25.59676 15.997976 41.594736s-9.598785 28.796355-22.397166 38.395141L572.792306 886.271631z m-79.989876-678.314151c-6.39919-19.19757-22.397165-38.395141-44.794331-44.79433l-134.382992-44.794331 134.382992 191.975703c12.79838 3.199595 22.397165 9.598785 28.796355 22.397165 3.199595 12.79838 3.199595 28.796355-6.39919 38.395141-6.39919 9.598785-19.19757 12.79838-28.796355 12.79838-9.598785 0-22.397165-6.39919-28.796356-15.997975-6.39919-6.39919-6.39919-19.19757-6.39919-25.59676l-134.382992-191.975704-6.39919 140.782183c0 22.397165 9.598785 41.594736 25.59676 57.592711l86.389067 73.590686c15.997975 12.79838 25.59676 28.796355 35.195545 44.794331l6.399191 12.79838 153.580562-108.786232-6.39919-6.39919c-12.79838-12.79838-25.59676-28.796355-31.995951-47.993926l-41.594735-108.786232z m131.183397 233.570439l-163.179348 118.385017 99.187447 214.372868L799.963555 607.906862l-175.977728-166.378943z" horiz-adv-x="1024" />
|
|
26
|
+
|
|
27
|
+
<glyph glyph-name="sdoc-replace" unicode="" d="M278.4 505.6V608h505.6c67.2 0 80-92.8 80-80v96C864 672 828.8 704 780.8 704H278.4V806.4c0 25.6-25.6 32-48 19.2l-224-147.2c-3.2-6.4-6.4-12.8-6.4-19.2 0-6.4 3.2-16 9.6-19.2 137.6-92.8 211.2-144 224-153.6 16-12.8 44.8-6.4 44.8 19.2z m467.2-243.2V160H240C172.8 160 160 252.8 160 240v-96C160 96 195.2 64 243.2 64h502.4v-102.4c0-25.6 25.6-32 48-19.2l224 147.2c6.4 6.4 9.6 12.8 9.6 19.2s-3.2 16-9.6 19.2c-137.6 92.8-211.2 144-224 153.6-19.2 12.8-48 6.4-48-19.2z" horiz-adv-x="1027" />
|
|
28
|
+
|
|
29
|
+
<glyph glyph-name="sdoc-adjust" unicode="" d="M230.4 844.8L51.2 665.6c-25.6-25.6-25.6-64 0-89.6L704-76.8c25.6-25.6 64-22.4 89.6 0l179.2 179.2c25.6 25.6 25.6 64 0 89.6L320 844.8c-25.6 25.6-64 25.6-89.6 0zM192 326.4l-48-96-96-48 96-48 48-96 48 96 96 48-96 48-48 96z m352 137.6l316.8-307.2-118.4-115.2-313.6 307.2 115.2 115.2z m-83.2 76.8L352 435.2 169.6 617.6l112 108.8 179.2-185.6zM832 848l-48-96-96-48 96-48 48-96 48 96 96 48-96 48-48 96z m-262.4 0l-28.8-57.6-57.6-28.8 57.6-28.8 28.8-60.8 28.8 57.6 57.6 28.8-57.6 28.8-28.8 60.8z" horiz-adv-x="1024" />
|
|
30
|
+
|
|
31
|
+
<glyph glyph-name="sdoc-ask-ai" unicode="" d="M585.6 643.2L678.4 896l92.8-252.8 252.8-92.8-252.8-92.8-92.8-249.6-92.8 249.6-249.6 92.8 249.6 92.8zM185.6 198.4L256 384l70.4-185.6L512 128l-185.6-70.4L256-128l-70.4 185.6L0 128z" horiz-adv-x="1024" />
|
|
32
|
+
|
|
17
33
|
<glyph glyph-name="sdoc-check-mark" unicode="" d="M44.8 371.2c-19.2 22.4-16 54.4 6.4 73.6s54.4 16 73.6-6.4l243.2-300.8L896 745.6c19.2 22.4 54.4 28.8 76.8 9.6 22.4-19.2 25.6-51.2 6.4-76.8-384-441.6-576-665.6-588.8-678.4-12.8-16-35.2-12.8-44.8 0-6.4 6.4-105.6 134.4-300.8 371.2z" horiz-adv-x="1024" />
|
|
18
34
|
|
|
19
35
|
<glyph glyph-name="sdoc-play" unicode="" d="M512 896C230.4 896 0 665.6 0 384s230.4-512 512-512 512 230.4 512 512c0 134.4-54.4 265.6-150.4 361.6S646.4 896 512 896z m0-944c-236.8 0-432 192-432 432S275.2 816 512 816s432-192 432-432c0-115.2-44.8-224-124.8-304s-192-128-307.2-128z m185.6 457.6l-134.4 76.8-140.8 83.2c-9.6 3.2-19.2 3.2-25.6-3.2-6.4-6.4-12.8-16-9.6-25.6v-320c0-9.6 3.2-19.2 9.6-25.6s16-6.4 25.6-3.2l140.8 83.2 134.4 76.8c9.6 6.4 12.8 16 12.8 25.6s-6.4 28.8-12.8 32z" horiz-adv-x="1024" />
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
@font-face {
|
|
2
2
|
font-family: "sdocfont";
|
|
3
3
|
/* Project id 4097705 */
|
|
4
|
-
src: url('./sdoc-editor-font/iconfont.eot?t=
|
|
4
|
+
src: url('./sdoc-editor-font/iconfont.eot?t=1734577970007');
|
|
5
5
|
/* IE9 */
|
|
6
|
-
src: url('./sdoc-editor-font/iconfont.eot?t=
|
|
6
|
+
src: url('./sdoc-editor-font/iconfont.eot?t=1734577970007#iefix') format('embedded-opentype'),
|
|
7
7
|
/* IE6-IE8 */
|
|
8
|
-
url('./sdoc-editor-font/iconfont.woff2?t=
|
|
9
|
-
url('./sdoc-editor-font/iconfont.woff?t=
|
|
10
|
-
url('./sdoc-editor-font/iconfont.ttf?t=
|
|
11
|
-
url('./sdoc-editor-font/iconfont.svg?t=
|
|
8
|
+
url('./sdoc-editor-font/iconfont.woff2?t=1734577970007') format('woff2'),
|
|
9
|
+
url('./sdoc-editor-font/iconfont.woff?t=1734577970007') format('woff'),
|
|
10
|
+
url('./sdoc-editor-font/iconfont.ttf?t=1734577970007') format('truetype'),
|
|
11
|
+
url('./sdoc-editor-font/iconfont.svg?t=1734577970007#sdocfont') format('svg');
|
|
12
12
|
}
|
|
13
13
|
|
|
14
14
|
.sdocfont {
|
|
@@ -19,6 +19,38 @@
|
|
|
19
19
|
-moz-osx-font-smoothing: grayscale;
|
|
20
20
|
}
|
|
21
21
|
|
|
22
|
+
.sdoc-send-arrow:before {
|
|
23
|
+
content: "\e67e";
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.sdoc-try-again:before {
|
|
27
|
+
content: "\e67f";
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.sdoc-ai-translate:before {
|
|
31
|
+
content: "\e680";
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.sdoc-insert-below:before {
|
|
35
|
+
content: "\e681";
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.sdoc-continue-writing:before {
|
|
39
|
+
content: "\e682";
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.sdoc-replace:before {
|
|
43
|
+
content: "\e683";
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.sdoc-adjust:before {
|
|
47
|
+
content: "\e684";
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.sdoc-ask-ai:before {
|
|
51
|
+
content: "\e685";
|
|
52
|
+
}
|
|
53
|
+
|
|
22
54
|
.sdoc-check-mark:before {
|
|
23
55
|
content: "\e67d";
|
|
24
56
|
}
|