@seafile/sdoc-editor 2.0.124 → 2.0.126

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.
@@ -102,7 +102,6 @@
102
102
 
103
103
  .sdoc-dropdown-menu .sdoc-dropdown-item-right-icon {
104
104
  color: #999;
105
- transform: scale(.8);
106
105
  }
107
106
 
108
107
  .sdoc-dropdown-menu .sdoc-dropdown-item-with-left-icon {
@@ -72,6 +72,10 @@ var EditableArticle = function EditableArticle(_ref) {
72
72
  scrollTop = _scrollRef$current.scrollTop,
73
73
  clientHeight = _scrollRef$current.clientHeight;
74
74
  eventProxy.onKeyDown(event);
75
+ var selection = editor.selection;
76
+ if (!_slate.Range.isCollapsed(selection)) {
77
+ return;
78
+ }
75
79
  if (event.key === 'ArrowLeft') {
76
80
  event.preventDefault();
77
81
  _slate.Transforms.move(editor, {
@@ -205,7 +209,7 @@ var EditableArticle = function EditableArticle(_ref) {
205
209
  }
206
210
 
207
211
  // eslint-disable-next-line react-hooks/exhaustive-deps
208
- }, [scrollRef]);
212
+ }, [scrollRef, editor]);
209
213
  var handleScrollIntoView = (0, _react.useCallback)(function (editor, domRange) {
210
214
  try {
211
215
  var selection = editor.selection;
@@ -141,7 +141,6 @@
141
141
 
142
142
  .sdoc-color-menu-popover .sdoc-more-colors .sdocfont {
143
143
  font-size: 12px;
144
- transform: scale(.6);
145
144
  color: #888;
146
145
  }
147
146
 
@@ -36,5 +36,4 @@
36
36
 
37
37
  .side-extendable .sdoc-right-slide {
38
38
  color: #fff;
39
- transform: scale(.6);
40
39
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@seafile/sdoc-editor",
3
- "version": "2.0.124",
3
+ "version": "2.0.126",
4
4
  "main": "dist/index.js",
5
5
  "scripts": {
6
6
  "test": "jest",
@@ -70,5 +70,5 @@
70
70
  "publishConfig": {
71
71
  "access": "public"
72
72
  },
73
- "gitHead": "9b30ab7dd281cd78875a7a366e98b517aa4b47b9"
73
+ "gitHead": "7af77d5a5fda5e6aaa76145cf4547f5bc66cb4b1"
74
74
  }