@seafile/sdoc-editor 1.0.198-test1.4 → 1.0.198-test1.6

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.
@@ -28,8 +28,8 @@ const Whiteboard = _ref => {
28
28
  const readOnly = true;
29
29
  const handleDoubleClick = event => {
30
30
  event.preventDefault();
31
- const url = `/lib/${repoID}/file${filePath}`;
32
- console.log('doubleclick', url1);
31
+ const siteRoot = window.app.config.siteRoot;
32
+ const url = `${siteRoot}lib/${repoID}/file${filePath}`;
33
33
  window.open(url, '_blank');
34
34
  return;
35
35
  };
@@ -57,11 +57,16 @@ const Whiteboard = _ref => {
57
57
  };
58
58
  function renderWhiteboard(props, editor) {
59
59
  const {
60
- element
60
+ element,
61
+ children,
62
+ attributes
61
63
  } = props;
62
- console.log(3, props);
63
- return /*#__PURE__*/_react.default.createElement(Whiteboard, {
64
+ return /*#__PURE__*/_react.default.createElement("div", Object.assign({}, attributes, {
65
+ contentEditable: "false",
66
+ suppressContentEditableWarning: true
67
+ }), children, /*#__PURE__*/_react.default.createElement(Whiteboard, {
64
68
  editor: editor,
65
- element: element
66
- });
69
+ element: element,
70
+ contentEditable: "false"
71
+ }));
67
72
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@seafile/sdoc-editor",
3
- "version": "1.0.198-test1.4",
3
+ "version": "1.0.198-test1.6",
4
4
  "private": false,
5
5
  "description": "This is a sdoc editor",
6
6
  "main": "dist/index.js",