@licium/react-editor 3.2.3 → 3.2.5

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.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2020 NHN Cloud Corp.
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
package/README.md CHANGED
@@ -1,8 +1,11 @@
1
+ > This is a fork of the [Toast UI Editor](https://github.com/natorus87/tui.editor) maintained by `@licium`.
2
+ > Original repository: https://github.com/natorus87/tui.editor
3
+
1
4
  # TOAST UI Editor for React
2
5
 
3
- > This is a [React](https://reactjs.org/) component wrapping [TOAST UI Editor](https://github.com/nhn/tui.editor/tree/master/apps/editor).
6
+ > This is a [React](https://reactjs.org/) component wrapping [TOAST UI Editor](https://github.com/natorus87/tui.editor/tree/master/apps/editor).
4
7
 
5
- [![npm version](https://img.shields.io/npm/v/@toast-ui/react-editor.svg)](https://www.npmjs.com/package/@toast-ui/react-editor)
8
+ [![npm version](https://img.shields.io/npm/v/@licium/react-editor.svg)](https://www.npmjs.com/package/@licium/react-editor)
6
9
 
7
10
  ## 🚩 Table of Contents
8
11
 
@@ -26,29 +29,29 @@ React Wrapper of TOAST UI Editor applies Google Analytics (GA) to collect statis
26
29
  ### Using npm
27
30
 
28
31
  ```sh
29
- npm install --save @toast-ui/react-editor
32
+ npm install --save @licium/react-editor
30
33
  ```
31
34
 
32
35
  ## 📝 Usage
33
36
 
34
37
  ### Import
35
38
 
36
- You can use TOAST UI Editor for React as a ECMAScript module or a CommonJS module. As this module does not contain CSS files, you should import `toastui-editor.css` from `@toast-ui/editor` in the script.
39
+ You can use TOAST UI Editor for React as a ECMAScript module or a CommonJS module. As this module does not contain CSS files, you should import `toastui-editor.css` from `@licium/editor` in the script.
37
40
 
38
41
  - ES Modules
39
42
 
40
43
  ```js
41
- import '@toast-ui/editor/dist/toastui-editor.css';
44
+ import '@licium/editor/dist/toastui-editor.css';
42
45
 
43
- import { Editor } from '@toast-ui/react-editor';
46
+ import { Editor } from '@licium/react-editor';
44
47
  ```
45
48
 
46
49
  - CommonJS
47
50
 
48
51
  ```js
49
- require('@toast-ui/editor/dist/toastui-editor.css');
52
+ require('@licium/editor/dist/toastui-editor.css');
50
53
 
51
- const { Editor } = require('@toast-ui/react-editor');
54
+ const { Editor } = require('@licium/react-editor');
52
55
  ```
53
56
 
54
57
  ### Props
@@ -56,9 +59,9 @@ const { Editor } = require('@toast-ui/react-editor');
56
59
  [All the options of the TOAST UI Editor](https://nhn.github.io/tui.editor/latest/ToastUIEditor) are supported in the form of props.
57
60
 
58
61
  ```js
59
- import '@toast-ui/editor/dist/toastui-editor.css';
62
+ import '@licium/editor/dist/toastui-editor.css';
60
63
 
61
- import { Editor } from '@toast-ui/react-editor';
64
+ import { Editor } from '@licium/react-editor';
62
65
 
63
66
  const MyComponent = () => (
64
67
  <Editor
@@ -76,9 +79,9 @@ const MyComponent = () => (
76
79
  For using [instance methods of TOAST UI Editor](https://nhn.github.io/tui.editor/latest/ToastUIEditor#addHook), first thing to do is creating Refs of wrapper component using [`createRef()`](https://reactjs.org/docs/refs-and-the-dom.html#creating-refs). But the wrapper component does not provide a way to call instance methods of TOAST UI Editor directly. Instead, you can call `getInstance()` method of the wrapper component to get the instance, and call the methods on it.
77
80
 
78
81
  ```js
79
- import '@toast-ui/editor/dist/toastui-editor.css';
82
+ import '@licium/editor/dist/toastui-editor.css';
80
83
 
81
- import { Editor } from '@toast-ui/react-editor';
84
+ import { Editor } from '@licium/react-editor';
82
85
 
83
86
  class MyComponent extends React.Component {
84
87
  editorRef = React.createRef();
@@ -109,9 +112,9 @@ class MyComponent extends React.Component {
109
112
  An instance of the wrapper component also provides a handy method for getting the root element. If you want to manipulate the root element directly, you can call `getRootElement` to get the element.
110
113
 
111
114
  ```js
112
- import '@toast-ui/editor/dist/toastui-editor.css';
115
+ import '@licium/editor/dist/toastui-editor.css';
113
116
 
114
- import { Editor } from '@toast-ui/react-editor';
117
+ import { Editor } from '@licium/react-editor';
115
118
 
116
119
  class MyComponent extends React.Component {
117
120
  editorRef = React.createRef();
@@ -142,9 +145,9 @@ class MyComponent extends React.Component {
142
145
  [All the events of TOAST UI Editor](https://nhn.github.io/tui.editor/latest/ToastUIEditor#focus) are supported in the form of `on[EventName]` props. The first letter of each event name should be capitalized. For example, for using `focus` event you can use `onFocus` prop like the example below.
143
146
 
144
147
  ```js
145
- import '@toast-ui/editor/dist/toastui-editor.css';
148
+ import '@licium/editor/dist/toastui-editor.css';
146
149
 
147
- import { Editor } from '@toast-ui/react-editor';
150
+ import { Editor } from '@licium/react-editor';
148
151
 
149
152
  class MyComponent extends React.Component {
150
153
  handleFocus = () => {
package/dist/esm/index.js CHANGED
@@ -1,15 +1,15 @@
1
1
  /**
2
2
  * TOAST UI Editor : React Wrapper
3
- * @version 3.2.3 | Fri Jan 02 2026
3
+ * @version 3.2.3 | Sat Jan 03 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
7
7
 
8
8
  import React from 'react';
9
- import Editor from '@toast-ui/editor';
10
- import Viewer from '@toast-ui/editor/dist/toastui-editor-viewer';
9
+ import Editor from '@licium/editor';
10
+ import Viewer from '@licium/editor/dist/toastui-editor-viewer';
11
11
 
12
- /*! *****************************************************************************
12
+ /******************************************************************************
13
13
  Copyright (c) Microsoft Corporation.
14
14
 
15
15
  Permission to use, copy, modify, and/or distribute this software for any
@@ -23,7 +23,7 @@ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
23
23
  OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
24
24
  PERFORMANCE OF THIS SOFTWARE.
25
25
  ***************************************************************************** */
26
- /* global Reflect, Promise */
26
+ /* global Reflect, Promise, SuppressedError, Symbol, Iterator */
27
27
 
28
28
  var extendStatics = function(d, b) {
29
29
  extendStatics = Object.setPrototypeOf ||
@@ -49,6 +49,11 @@ var __assign = function() {
49
49
  return t;
50
50
  };
51
51
  return __assign.apply(this, arguments);
52
+ };
53
+
54
+ typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
55
+ var e = new Error(message);
56
+ return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
52
57
  };
53
58
 
54
59
  var default_1 = /** @class */ (function (_super) {
@@ -1,2 +1,2 @@
1
1
  /*! For license information please see toastui-react-editor.js.LICENSE.txt */
2
- !function(){"use strict";var t={n:function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,{a:n}),n},d:function(e,n){for(var r in n)t.o(n,r)&&!t.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:n[r]})},o:function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r:function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})}},e={};t.r(e),t.d(e,{Editor:function(){return a},Viewer:function(){return d}});var n=function(t,e){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},n(t,e)};function r(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function r(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)}var o=function(){return o=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t},o.apply(this,arguments)};Object.create,Object.create;var i=require("react"),s=t.n(i),u=require("@toast-ui/editor"),p=t.n(u),c=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.rootEl=s().createRef(),e}return r(e,t),e.prototype.getRootElement=function(){return this.rootEl.current},e.prototype.getInstance=function(){return this.editorInst},e.prototype.getBindingEventNames=function(){var t=this;return Object.keys(this.props).filter((function(t){return/^on[A-Z][a-zA-Z]+/.test(t)})).filter((function(e){return t.props[e]}))},e.prototype.bindEventHandlers=function(t){var e=this;this.getBindingEventNames().forEach((function(n){var r=n[2].toLowerCase()+n.slice(3);e.editorInst.off(r),e.editorInst.on(r,t[n])}))},e.prototype.getInitEvents=function(){var t=this;return this.getBindingEventNames().reduce((function(e,n){return e[n[2].toLowerCase()+n.slice(3)]=t.props[n],e}),{})},e.prototype.componentDidMount=function(){this.editorInst=new(p())(o(o({el:this.rootEl.current},this.props),{events:this.getInitEvents()}))},e.prototype.shouldComponentUpdate=function(t){var e=this.getInstance(),n=t.height,r=t.previewStyle;return n&&this.props.height!==n&&e.setHeight(n),r&&this.props.previewStyle!==r&&e.changePreviewStyle(r),this.bindEventHandlers(t),!1},e.prototype.componentWillUnmount=function(){this.editorInst.destroy()},e.prototype.render=function(){return s().createElement("div",{ref:this.rootEl})},e}(s().Component),a=c,f=require("@toast-ui/editor/dist/toastui-editor-viewer"),l=t.n(f),h=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.rootEl=s().createRef(),e}return r(e,t),e.prototype.getRootElement=function(){return this.rootEl.current},e.prototype.getInstance=function(){return this.viewerInst},e.prototype.getBindingEventNames=function(){var t=this;return Object.keys(this.props).filter((function(t){return/^on[A-Z][a-zA-Z]+/.test(t)})).filter((function(e){return t.props[e]}))},e.prototype.bindEventHandlers=function(t){var e=this;this.getBindingEventNames().forEach((function(n){var r=n[2].toLowerCase()+n.slice(3);e.viewerInst.off(r),e.viewerInst.on(r,t[n])}))},e.prototype.getInitEvents=function(){var t=this;return this.getBindingEventNames().reduce((function(e,n){return e[n[2].toLowerCase()+n.slice(3)]=t.props[n],e}),{})},e.prototype.componentDidMount=function(){this.viewerInst=new(l())(o(o({el:this.rootEl.current},this.props),{events:this.getInitEvents()}))},e.prototype.shouldComponentUpdate=function(t){return this.bindEventHandlers(t),!1},e.prototype.componentWillUnmount=function(){this.viewerInst.destroy()},e.prototype.render=function(){return s().createElement("div",{ref:this.rootEl})},e}(s().Component),d=h;module.exports=e}();
2
+ !function(){"use strict";var t={n:function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,{a:n}),n},d:function(e,n){for(var r in n)t.o(n,r)&&!t.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:n[r]})},o:function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r:function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})}},e={};t.r(e),t.d(e,{Editor:function(){return f},Viewer:function(){return h}});var n=function(t,e){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},n(t,e)};function r(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function r(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)}var o=function(){return o=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t},o.apply(this,arguments)};Object.create,Object.create,"function"==typeof SuppressedError&&SuppressedError;var i=require("react"),s=t.n(i),u=require("@licium/editor"),p=t.n(u),c=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.rootEl=s().createRef(),e}return r(e,t),e.prototype.getRootElement=function(){return this.rootEl.current},e.prototype.getInstance=function(){return this.editorInst},e.prototype.getBindingEventNames=function(){var t=this;return Object.keys(this.props).filter((function(t){return/^on[A-Z][a-zA-Z]+/.test(t)})).filter((function(e){return t.props[e]}))},e.prototype.bindEventHandlers=function(t){var e=this;this.getBindingEventNames().forEach((function(n){var r=n[2].toLowerCase()+n.slice(3);e.editorInst.off(r),e.editorInst.on(r,t[n])}))},e.prototype.getInitEvents=function(){var t=this;return this.getBindingEventNames().reduce((function(e,n){return e[n[2].toLowerCase()+n.slice(3)]=t.props[n],e}),{})},e.prototype.componentDidMount=function(){this.editorInst=new(p())(o(o({el:this.rootEl.current},this.props),{events:this.getInitEvents()}))},e.prototype.shouldComponentUpdate=function(t){var e=this.getInstance(),n=t.height,r=t.previewStyle;return n&&this.props.height!==n&&e.setHeight(n),r&&this.props.previewStyle!==r&&e.changePreviewStyle(r),this.bindEventHandlers(t),!1},e.prototype.componentWillUnmount=function(){this.editorInst.destroy()},e.prototype.render=function(){return s().createElement("div",{ref:this.rootEl})},e}(s().Component),f=c,a=require("@licium/editor/dist/toastui-editor-viewer"),l=t.n(a),d=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.rootEl=s().createRef(),e}return r(e,t),e.prototype.getRootElement=function(){return this.rootEl.current},e.prototype.getInstance=function(){return this.viewerInst},e.prototype.getBindingEventNames=function(){var t=this;return Object.keys(this.props).filter((function(t){return/^on[A-Z][a-zA-Z]+/.test(t)})).filter((function(e){return t.props[e]}))},e.prototype.bindEventHandlers=function(t){var e=this;this.getBindingEventNames().forEach((function(n){var r=n[2].toLowerCase()+n.slice(3);e.viewerInst.off(r),e.viewerInst.on(r,t[n])}))},e.prototype.getInitEvents=function(){var t=this;return this.getBindingEventNames().reduce((function(e,n){return e[n[2].toLowerCase()+n.slice(3)]=t.props[n],e}),{})},e.prototype.componentDidMount=function(){this.viewerInst=new(l())(o(o({el:this.rootEl.current},this.props),{events:this.getInitEvents()}))},e.prototype.shouldComponentUpdate=function(t){return this.bindEventHandlers(t),!1},e.prototype.componentWillUnmount=function(){this.viewerInst.destroy()},e.prototype.render=function(){return s().createElement("div",{ref:this.rootEl})},e}(s().Component),h=d;module.exports=e}();
@@ -1,21 +1,6 @@
1
1
  /*!
2
2
  * TOAST UI Editor : React Wrapper
3
- * @version 3.2.3 | Fri Jan 02 2026
3
+ * @version 3.2.3 | Sat Jan 03 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
7
-
8
- /*! *****************************************************************************
9
- Copyright (c) Microsoft Corporation.
10
-
11
- Permission to use, copy, modify, and/or distribute this software for any
12
- purpose with or without fee is hereby granted.
13
-
14
- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
15
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
16
- AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
17
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
18
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
19
- OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
20
- PERFORMANCE OF THIS SOFTWARE.
21
- ***************************************************************************** */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@licium/react-editor",
3
- "version": "3.2.3",
3
+ "version": "3.2.5",
4
4
  "description": "TOAST UI Editor for React",
5
5
  "files": [
6
6
  "dist",
@@ -16,12 +16,12 @@
16
16
  },
17
17
  "homepage": "https://ui.toast.com",
18
18
  "bugs": {
19
- "url": "https://github.com/nhn/tui.editor/issues"
19
+ "url": "https://github.com/natorus87/tui.editor/issues"
20
20
  },
21
21
  "author": "NHN Cloud FE Development Lab <dl_javascript@nhn.com>",
22
22
  "repository": {
23
23
  "type": "git",
24
- "url": "https://github.com/nhn/tui.editor.git",
24
+ "url": "https://github.com/natorus87/tui.editor.git",
25
25
  "directory": "apps/react-editor"
26
26
  },
27
27
  "license": "MIT",
@@ -35,7 +35,7 @@
35
35
  "react-dom": "^17.0.1"
36
36
  },
37
37
  "dependencies": {
38
- "@licium/editor": "^3.2.2"
38
+ "@licium/editor": "^3.2.5"
39
39
  },
40
- "gitHead": "cbc7cab7b3f081a1aaf1d338b8138512ace132b9"
40
+ "gitHead": "99372e785bf25153af30befd49b60ea4adb48e2b"
41
41
  }