@seafile/sdoc-editor 2.0.163 → 2.0.165
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.
|
@@ -161,9 +161,13 @@ var insertFragmentList = exports.insertFragmentList = function insertFragmentLis
|
|
|
161
161
|
}
|
|
162
162
|
var nodes = fragment;
|
|
163
163
|
if (isListRoot(fragment[0]) && !isEmptySelection) {
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
}
|
|
164
|
+
if ((0, _core.isSelectionAtBlockEnd)(editor)) {
|
|
165
|
+
nodes = [(0, _core.generateDefaultText)()].concat((0, _toConsumableArray2["default"])(fragment));
|
|
166
|
+
} else if ((0, _core.isSelectionAtBlockStart)(editor)) {
|
|
167
|
+
nodes = [].concat((0, _toConsumableArray2["default"])(fragment), [(0, _core.generateDefaultText)()]);
|
|
168
|
+
} else {
|
|
169
|
+
nodes = [(0, _core.generateDefaultText)()].concat((0, _toConsumableArray2["default"])(fragment), [(0, _core.generateDefaultText)()]);
|
|
170
|
+
}
|
|
167
171
|
}
|
|
168
172
|
return _insertFragment(nodes);
|
|
169
173
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@seafile/sdoc-editor",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.165",
|
|
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": "b4ab6e0d30e5ba7de70ab91fe42003c8087d524a"
|
|
75
75
|
}
|