@seafile/sdoc-editor 2.0.192 → 2.0.193
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.
|
@@ -167,6 +167,7 @@ var SideToolbar = function SideToolbar() {
|
|
|
167
167
|
}, [editor, isShowSideMenu, scrollRef, sidePosition.top]);
|
|
168
168
|
var onMouseDown = (0, _react.useCallback)(function (e) {
|
|
169
169
|
e.stopPropagation();
|
|
170
|
+
if (!editor.selection) (0, _helpers2.setSelection)(editor, slateNode);
|
|
170
171
|
var domSelection = window.getSelection();
|
|
171
172
|
if (domSelection.type !== 'Range' || !editor.selection || _slate.Path.equals(editor.selection.focus.path, editor.selection.anchor.path)) {
|
|
172
173
|
draggedPreviewContainer.current = null;
|
|
@@ -238,7 +239,7 @@ var SideToolbar = function SideToolbar() {
|
|
|
238
239
|
draggedSourcePaths.current = null;
|
|
239
240
|
}
|
|
240
241
|
}
|
|
241
|
-
}, [editor]);
|
|
242
|
+
}, [editor, slateNode]);
|
|
242
243
|
var onShowSideMenuToggle = (0, _react.useCallback)(function () {
|
|
243
244
|
(0, _helpers2.setSelection)(editor, slateNode);
|
|
244
245
|
var _menuRef$current$getB = menuRef.current.getBoundingClientRect(),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@seafile/sdoc-editor",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.193",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"test": "jest",
|
|
@@ -71,5 +71,5 @@
|
|
|
71
71
|
"publishConfig": {
|
|
72
72
|
"access": "public"
|
|
73
73
|
},
|
|
74
|
-
"gitHead": "
|
|
74
|
+
"gitHead": "ee833b5b8307c8dfa1f669faf7bd1385f60fc7c7"
|
|
75
75
|
}
|