@seafile/sdoc-editor 3.0.274 → 3.0.276

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.
@@ -15,6 +15,11 @@
15
15
  border-top: 1px solid #eee;
16
16
  }
17
17
 
18
+ .sdoc-dropdown-menu .dropdown-item {
19
+ font-size: 14px;
20
+ color: #212529;
21
+ }
22
+
18
23
  .sdoc-dropdown-menu .sdoc-dropdown-menu-item {
19
24
  height: 32px;
20
25
  width: 100%;
@@ -135,11 +135,6 @@
135
135
  box-shadow: unset;
136
136
  }
137
137
 
138
- .sdoc-dropdown-menu .dropdown-item {
139
- font-size: 14px;
140
- color: #212529;
141
- }
142
-
143
138
  /* doc comment add editor */
144
139
  .sdoc-comment-drawer .sdoc-comments-panel-body .sdoc-global-comment-input-wrapper {
145
140
  padding: 0 16px;
@@ -23,20 +23,20 @@
23
23
  color: #BDBDBD;
24
24
  }
25
25
 
26
- .sdoc-font-size-menu-popover .sdoc-dropdown-menu-item .sdoc-check-mark {
26
+ .sdoc-font-size-menu-popover .sdoc-dropdown-menu .sdoc-dropdown-menu-item .sdoc-check-mark {
27
27
  position: absolute;
28
28
  left: 12px;
29
29
  color: #666;
30
30
  }
31
31
 
32
- .sdoc-font-size-menu-popover .sdoc-font-size-menu-container {
32
+ .sdoc-font-size-menu-popover .sdoc-dropdown-menu.sdoc-font-size-menu-container {
33
33
  height: fit-content;
34
34
  overflow-y: auto;
35
35
  overflow-x: hidden;
36
36
  min-width: 96px;
37
37
  }
38
38
 
39
- .sdoc-font-size-menu-popover .sdoc-dropdown-menu-item {
39
+ .sdoc-font-size-menu-popover .sdoc-dropdown-menu .sdoc-dropdown-menu-item {
40
40
  font-size: 14px;
41
41
  padding: 4px 12px 4px 38px;
42
42
  }
@@ -20,10 +20,9 @@ var _urlUtils = require("../../../utils/url-utils");
20
20
  var _constants2 = require("../../constants");
21
21
  var _core = require("../../core");
22
22
  var _utils = require("../../utils");
23
- var _helper = require("../embed-link/helper");
24
23
  var _helpers2 = require("../file-link/helpers");
25
24
  var _helpers3 = require("../sdoc-link/helpers");
26
- var _helper2 = require("../whiteboard/helper");
25
+ var _helper = require("../whiteboard/helper");
27
26
  var _helpers4 = require("../wiki-link/helpers");
28
27
  var _helpers5 = require("./helpers");
29
28
  var withLink = function withLink(editor) {
@@ -45,7 +44,7 @@ var withLink = function withLink(editor) {
45
44
  };
46
45
  newEditor.insertData = /*#__PURE__*/function () {
47
46
  var _ref = (0, _asyncToGenerator2["default"])(/*#__PURE__*/(0, _regenerator2["default"])().m(function _callee(data) {
48
- var pastedText, text, selectedElems, isCodeContext, res, fileInfo, fileName, fileUuid, _fileName, fileParentPath, filePath, repoId, _fileName2, _fileUuid, url, pathname, _context$getSetting, parts, wikiPageId, title, wikiPageList, page, linkedNodeId, _title, params, link, _link, embedLinkType, _link2, _Editor$next, _Editor$next2, focusPath, focusPoint, _t;
47
+ var pastedText, text, selectedElems, isCodeContext, res, fileInfo, fileName, fileUuid, _fileName, fileParentPath, filePath, repoId, _fileName2, _fileUuid, url, pathname, _context$getSetting, parts, wikiPageId, title, wikiPageList, page, linkedNodeId, _title, params, link, _link, _link2, _Editor$next, _Editor$next2, focusPath, focusPoint, _t;
49
48
  return (0, _regenerator2["default"])().w(function (_context) {
50
49
  while (1) switch (_context.p = _context.n) {
51
50
  case 0:
@@ -63,7 +62,7 @@ var withLink = function withLink(editor) {
63
62
  return _context.a(2, insertData(data));
64
63
  case 1:
65
64
  if (!(text && !(0, _utils.isImage)(text))) {
66
- _context.n = 16;
65
+ _context.n = 15;
67
66
  break;
68
67
  }
69
68
  if (!(0, _utils.isSameDomain)(text, _context2["default"].getSetting('serviceUrl'))) {
@@ -95,7 +94,7 @@ var withLink = function withLink(editor) {
95
94
  filePath = fileParentPath + '/' + _fileName;
96
95
  repoId = fileInfo.repo_id;
97
96
  console.log('insertWhiteboard', _fileName, filePath, repoId);
98
- (0, _helper2.insertWhiteboard)(editor, _fileName, filePath, repoId);
97
+ (0, _helper.insertWhiteboard)(editor, _fileName, filePath, repoId);
99
98
  _context.n = 10;
100
99
  break;
101
100
  case 5:
@@ -158,29 +157,20 @@ var withLink = function withLink(editor) {
158
157
  _link = (0, _helpers5.genLinkNode)(text, text);
159
158
  _slate.Transforms.insertNodes(newEditor, _link);
160
159
  case 12:
161
- _context.n = 15;
160
+ _context.n = 14;
162
161
  break;
163
162
  case 13:
164
- // Paste Seatable or Figma link
165
- embedLinkType = (0, _helper.getEmbedLinkType)(text);
166
- if (!embedLinkType) {
167
- _context.n = 14;
168
- break;
169
- }
170
- (0, _helper.insertEmbedLink)(newEditor, text, embedLinkType);
171
- return _context.a(2);
172
- case 14:
173
163
  _link2 = (0, _helpers5.genLinkNode)(text, text);
174
164
  _slate.Transforms.insertNodes(newEditor, _link2);
175
- case 15:
165
+ case 14:
176
166
  // Void merging text from link
177
167
  _Editor$next = _slate.Editor.next(newEditor), _Editor$next2 = (0, _slicedToArray2["default"])(_Editor$next, 2), focusPath = _Editor$next2[1];
178
168
  focusPoint = _slate.Editor.start(newEditor, focusPath);
179
169
  _slate.Transforms.select(newEditor, focusPoint);
180
170
  return _context.a(2);
181
- case 16:
171
+ case 15:
182
172
  insertData(data);
183
- case 17:
173
+ case 16:
184
174
  return _context.a(2);
185
175
  }
186
176
  }, _callee, null, [[2, 11]]);
@@ -91,12 +91,12 @@
91
91
  white-space: nowrap;
92
92
  }
93
93
 
94
- .sdoc-file-link-hover-menu-container .sdoc-file-display-style-popover .sdoc-dropdown-item {
94
+ .sdoc-link-hover-menu-container .sdoc-file-display-style-popover .sdoc-dropdown-menu-item {
95
95
  padding: 0 12px 0 38px;
96
96
  position: relative;
97
97
  }
98
98
 
99
- .sdoc-file-link-hover-menu-container .sdoc-file-display-style-popover .sdoc-dropdown-menu-item .sdoc-check-mark {
99
+ .sdoc-link-hover-menu-container .sdoc-file-display-style-popover .sdoc-dropdown-menu-item .sdoc-check-mark {
100
100
  position: absolute;
101
101
  left: 12px;
102
102
  }
@@ -22,7 +22,7 @@
22
22
  color: #adb5bd;
23
23
  }
24
24
 
25
- .sdoc-side-extendable {
25
+ .sdoc-table-context-menu .dropdown-item.sdoc-side-extendable {
26
26
  display: flex;
27
27
  justify-content: space-between;
28
28
  align-items: center;
@@ -3,21 +3,21 @@
3
3
  flex-direction: column;
4
4
  }
5
5
 
6
- .sdoc-table-alignment-menu {
7
- min-width: 96px !important;
6
+ .sdoc-dropdown-menu.sdoc-table-alignment-menu {
7
+ min-width: 96px;
8
8
  }
9
9
 
10
- .sdoc-table-alignment-menu .sdoc-dropdown-menu-item {
11
- padding: 4px 12px 4px 38px !important;
10
+ .sdoc-dropdown-menu.sdoc-table-alignment-menu .sdoc-dropdown-menu-item {
11
+ padding: 4px 12px 4px 38px;
12
12
  }
13
13
 
14
- .sdoc-table-alignment-menu .sdoc-dropdown-menu-item .sdoc-check-mark {
14
+ .sdoc-dropdown-menu.sdoc-table-alignment-menu .sdoc-dropdown-menu-item .sdoc-check-mark {
15
15
  position: absolute;
16
16
  left: 20px;
17
- font-size: 14px !important;
17
+ font-size: 14px;
18
18
  display: none;
19
19
  }
20
20
 
21
- .sdoc-table-alignment-menu .sdoc-dropdown-menu-item .sdoc-check-mark.active {
21
+ .sdoc-dropdown-menu.sdoc-table-alignment-menu .sdoc-dropdown-menu-item .sdoc-check-mark.active {
22
22
  display: inline;
23
23
  }
@@ -1,14 +1,14 @@
1
1
  .sdoc-text-align-dropdown .sdoc-dropdown-menu {
2
- min-width: 96px !important;
2
+ min-width: 96px;
3
3
  }
4
4
 
5
- .sdoc-text-align-dropdown .sdocfont.sdoc-check-mark {
5
+ .sdoc-text-align-dropdown .sdoc-dropdown-menu .sdoc-dropdown-menu-item .sdoc-check-mark {
6
6
  position: absolute;
7
7
  left: 12px;
8
8
  color: #666;
9
9
  }
10
10
 
11
- .sdoc-text-align-dropdown .sdoc-dropdown-menu-item {
11
+ .sdoc-text-align-dropdown .sdoc-dropdown-menu .sdoc-dropdown-menu-item {
12
12
  font-size: 14px;
13
13
  padding: 4px 12px 4px 38px;
14
14
  position: relative;
package/package.json CHANGED
@@ -1,6 +1,11 @@
1
1
  {
2
2
  "name": "@seafile/sdoc-editor",
3
- "version": "3.0.274",
3
+ "version": "3.0.276",
4
+ "repository": {
5
+ "type": "git",
6
+ "url": "git+https://github.com/haiwen/seadoc-editor.git",
7
+ "directory": "packages/sdoc-editor"
8
+ },
4
9
  "main": "dist/index.js",
5
10
  "scripts": {
6
11
  "test": "jest",
@@ -70,5 +75,5 @@
70
75
  "publishConfig": {
71
76
  "access": "public"
72
77
  },
73
- "gitHead": "e27c42534dbb7213e9d793633349ead657c48567"
78
+ "gitHead": "decec5ac319e288e1742dfdd0cd7a67e43b997bc"
74
79
  }
package/LICENSE.txt DELETED
@@ -1,13 +0,0 @@
1
- Copyright (c) 2025 Seafile Ltd.
2
-
3
- Licensed under the Apache License, Version 2.0 (the "License");
4
- you may not use this file except in compliance with the License.
5
- You may obtain a copy of the License at
6
-
7
- http://www.apache.org/licenses/LICENSE-2.0
8
-
9
- Unless required by applicable law or agreed to in writing, software
10
- distributed under the License is distributed on an "AS IS" BASIS,
11
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
- See the License for the specific language governing permissions and
13
- limitations under the License.