@seafile/sdoc-editor 2.0.200 → 2.0.202

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.
@@ -159,6 +159,7 @@
159
159
 
160
160
  .sdoc-toggle-view .sdoc-tree-view,
161
161
  .sdoc-toggle-view .sdoc-list-view {
162
+ color: #666666;
162
163
  min-width: 66px;
163
164
  width: fit-content;
164
165
  border-radius: 2px;
@@ -33,6 +33,12 @@
33
33
  flex: 1 1;
34
34
  margin-left: .25rem;
35
35
  overflow: hidden;
36
+ white-space: nowrap;
37
+ text-overflow: ellipsis;
38
+ }
39
+
40
+ .sdoc-file-wrapper:has(.sdoc-file-checked) .sdoc-item-content {
41
+ padding-right: 32px;
36
42
  }
37
43
 
38
44
  .sdoc-item-name {
@@ -76,6 +76,13 @@
76
76
 
77
77
  .sdoc-files-tree .sdoc-file-info .sdoc-file-name {
78
78
  font-size: 14px;
79
+ white-space: nowrap;
80
+ overflow: hidden;
81
+ text-overflow: ellipsis;
82
+ }
83
+
84
+ .sdoc-files-tree .sdoc-file-info:has(.sdoc-file-checked) .sdoc-file-name {
85
+ padding-right: 32px;
79
86
  }
80
87
 
81
88
  .sdoc-files-tree .sdoc-folder-children {
@@ -173,7 +173,7 @@ var AddLinkDialog = function AddLinkDialog(_ref) {
173
173
  return function () {
174
174
  return clearTimeout(timer);
175
175
  };
176
- }, []);
176
+ }, [linked_id]);
177
177
  (0, _react.useEffect)(function () {
178
178
  var genHtml = /*#__PURE__*/function () {
179
179
  var _ref3 = (0, _asyncToGenerator2["default"])(/*#__PURE__*/(0, _regenerator2["default"])().m(function _callee() {
@@ -252,7 +252,7 @@ var parseHtmlString = exports.parseHtmlString = function parseHtmlString(htmlStr
252
252
  var parser = new DOMParser();
253
253
  var doc = parser.parseFromString(htmlString, 'text/html');
254
254
  var resultHtml;
255
- if (targetType == 'img') {
255
+ if (targetType === 'img') {
256
256
  resultHtml = (0, _toConsumableArray2["default"])(doc.querySelectorAll('p:has(img)')).map(function (p) {
257
257
  return p.outerHTML;
258
258
  }).join('');
@@ -264,6 +264,7 @@ var parseHtmlString = exports.parseHtmlString = function parseHtmlString(htmlStr
264
264
  return resultHtml;
265
265
  };
266
266
  var isEmptyNode = exports.isEmptyNode = function isEmptyNode(node) {
267
+ if (node.type === _constants.IMAGE_BLOCK) return false;
267
268
  var text = _slate.Node.string(node);
268
269
  return text.trim() === '';
269
270
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@seafile/sdoc-editor",
3
- "version": "2.0.200",
3
+ "version": "2.0.202",
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": "d6b974832aec38c7c3a19fddd0bdfe878b0a538b"
74
+ "gitHead": "a0f7311114597313bfe8367fc8725a8e1c2f8e89"
75
75
  }