jodit 4.5.4 → 4.5.8
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/CHANGELOG.md +33 -0
- package/es2015/jodit.css +1 -1
- package/es2015/jodit.fat.min.js +2 -2
- package/es2015/jodit.js +20 -12
- package/es2015/jodit.min.js +2 -2
- package/es2015/plugins/debug/debug.css +1 -1
- package/es2015/plugins/debug/debug.js +1 -1
- package/es2015/plugins/debug/debug.min.js +1 -1
- package/es2015/plugins/speech-recognize/speech-recognize.css +1 -1
- package/es2015/plugins/speech-recognize/speech-recognize.js +1 -1
- package/es2015/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/es2018/jodit.css +1 -1
- package/es2018/jodit.fat.min.js +2 -2
- package/es2018/jodit.js +16 -6
- package/es2018/jodit.min.js +2 -2
- package/es2018/plugins/debug/debug.css +1 -1
- package/es2018/plugins/debug/debug.js +1 -1
- package/es2018/plugins/debug/debug.min.js +1 -1
- package/es2018/plugins/speech-recognize/speech-recognize.css +1 -1
- package/es2018/plugins/speech-recognize/speech-recognize.js +1 -1
- package/es2018/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/es2021/jodit.css +1 -1
- package/es2021/jodit.fat.min.js +2 -2
- package/es2021/jodit.js +16 -6
- package/es2021/jodit.min.js +2 -2
- package/es2021/plugins/debug/debug.css +1 -1
- package/es2021/plugins/debug/debug.js +1 -1
- package/es2021/plugins/debug/debug.min.js +1 -1
- package/es2021/plugins/speech-recognize/speech-recognize.css +1 -1
- package/es2021/plugins/speech-recognize/speech-recognize.js +1 -1
- package/es2021/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/es2021.en/jodit.css +1 -1
- package/es2021.en/jodit.fat.min.js +2 -2
- package/es2021.en/jodit.js +16 -6
- package/es2021.en/jodit.min.js +2 -2
- package/es2021.en/plugins/debug/debug.css +1 -1
- package/es2021.en/plugins/debug/debug.js +1 -1
- package/es2021.en/plugins/debug/debug.min.js +1 -1
- package/es2021.en/plugins/speech-recognize/speech-recognize.css +1 -1
- package/es2021.en/plugins/speech-recognize/speech-recognize.js +1 -1
- package/es2021.en/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/es5/5.fat.min.js +1 -1
- package/es5/5.min.js +1 -1
- package/es5/975.fat.min.js +1 -1
- package/es5/975.min.js +1 -1
- package/es5/jodit.css +2 -2
- package/es5/jodit.fat.min.js +2 -2
- package/es5/jodit.js +26 -21
- package/es5/jodit.min.css +2 -2
- package/es5/jodit.min.js +2 -2
- package/es5/plugins/debug/debug.css +1 -1
- package/es5/plugins/debug/debug.js +1 -1
- package/es5/plugins/debug/debug.min.js +1 -1
- package/es5/plugins/speech-recognize/speech-recognize.css +1 -1
- package/es5/plugins/speech-recognize/speech-recognize.js +1 -1
- package/es5/plugins/speech-recognize/speech-recognize.min.js +1 -1
- package/esm/core/constants.js +1 -1
- package/esm/core/helpers/utils/append-script.d.ts +1 -4
- package/esm/core/helpers/utils/append-script.js +2 -2
- package/esm/jodit.d.ts +3 -0
- package/esm/jodit.js +4 -1
- package/esm/plugins/paste/paste.js +6 -1
- package/package.json +1 -1
- package/types/core/helpers/utils/append-script.d.ts +1 -4
- package/types/jodit.d.ts +3 -0
package/esm/core/constants.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
4
|
* Copyright (c) 2013-2025 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
-
export const APP_VERSION = "4.5.
|
|
6
|
+
export const APP_VERSION = "4.5.8";
|
|
7
7
|
// prettier-ignore
|
|
8
8
|
export const ES = "es2020";
|
|
9
9
|
export const IS_ES_MODERN = true;
|
|
@@ -8,10 +8,7 @@
|
|
|
8
8
|
*/
|
|
9
9
|
import type { IViewBased } from "../../../types/index";
|
|
10
10
|
export type Loader = (jodit: IViewBased, url: string) => Promise<any>;
|
|
11
|
-
export
|
|
12
|
-
callback: EventListener;
|
|
13
|
-
element: HTMLElement;
|
|
14
|
-
}
|
|
11
|
+
export declare const alreadyLoadedList: Map<string, Promise<any>>;
|
|
15
12
|
/**
|
|
16
13
|
* Load script and return promise
|
|
17
14
|
*/
|
|
@@ -5,9 +5,9 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import { isString } from "../checker/is-string.js";
|
|
7
7
|
import { completeUrl } from "./complete-url.js";
|
|
8
|
-
const alreadyLoadedList = new Map();
|
|
8
|
+
export const alreadyLoadedList = new Map();
|
|
9
9
|
const cacheLoaders = (loader) => {
|
|
10
|
-
return
|
|
10
|
+
return (jodit, url) => {
|
|
11
11
|
if (alreadyLoadedList.has(url)) {
|
|
12
12
|
return alreadyLoadedList.get(url);
|
|
13
13
|
}
|
package/esm/jodit.d.ts
CHANGED
|
@@ -34,6 +34,9 @@ export declare class Jodit extends ViewWithToolbar implements IJodit, Dlgs {
|
|
|
34
34
|
* ```
|
|
35
35
|
*/
|
|
36
36
|
waitForReady(): Promise<IJodit>;
|
|
37
|
+
/**
|
|
38
|
+
* @deprecated I don't know why I wrote itp
|
|
39
|
+
*/
|
|
37
40
|
static get ready(): Promise<IJodit>;
|
|
38
41
|
/**
|
|
39
42
|
* Define if object is Jodit
|
package/esm/jodit.js
CHANGED
|
@@ -49,9 +49,12 @@ let Jodit = Jodit_1 = class Jodit extends ViewWithToolbar {
|
|
|
49
49
|
this.hookStatus('ready', () => resolve(this));
|
|
50
50
|
});
|
|
51
51
|
}
|
|
52
|
+
/**
|
|
53
|
+
* @deprecated I don't know why I wrote itp
|
|
54
|
+
*/
|
|
52
55
|
static get ready() {
|
|
53
56
|
return new Promise(resolve => {
|
|
54
|
-
eventEmitter.on('
|
|
57
|
+
eventEmitter.on('joditready', resolve);
|
|
55
58
|
});
|
|
56
59
|
}
|
|
57
60
|
/**
|
|
@@ -153,7 +153,12 @@ export class paste extends Plugin {
|
|
|
153
153
|
case INSERT_AS_TEXT:
|
|
154
154
|
html = htmlspecialchars(html);
|
|
155
155
|
break;
|
|
156
|
-
default:
|
|
156
|
+
default: {
|
|
157
|
+
const newHTML = this.j.e.fire('onCustomPasteHTMLOption', action, html, e);
|
|
158
|
+
if (typeof newHTML === 'string') {
|
|
159
|
+
html = newHTML;
|
|
160
|
+
}
|
|
161
|
+
}
|
|
157
162
|
}
|
|
158
163
|
}
|
|
159
164
|
pasteInsertHtml(e, this.j, html);
|
package/package.json
CHANGED
|
@@ -8,10 +8,7 @@
|
|
|
8
8
|
*/
|
|
9
9
|
import type { IViewBased } from "../../../types/index";
|
|
10
10
|
export type Loader = (jodit: IViewBased, url: string) => Promise<any>;
|
|
11
|
-
export
|
|
12
|
-
callback: EventListener;
|
|
13
|
-
element: HTMLElement;
|
|
14
|
-
}
|
|
11
|
+
export declare const alreadyLoadedList: Map<string, Promise<any>>;
|
|
15
12
|
/**
|
|
16
13
|
* Load script and return promise
|
|
17
14
|
*/
|
package/types/jodit.d.ts
CHANGED
|
@@ -34,6 +34,9 @@ export declare class Jodit extends ViewWithToolbar implements IJodit, Dlgs {
|
|
|
34
34
|
* ```
|
|
35
35
|
*/
|
|
36
36
|
waitForReady(): Promise<IJodit>;
|
|
37
|
+
/**
|
|
38
|
+
* @deprecated I don't know why I wrote itp
|
|
39
|
+
*/
|
|
37
40
|
static get ready(): Promise<IJodit>;
|
|
38
41
|
/**
|
|
39
42
|
* Define if object is Jodit
|