jodit 4.2.41 → 4.2.45
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 +65 -5
- package/es2015/jodit.css +5 -7
- package/es2015/jodit.fat.min.css +1 -1
- package/es2015/jodit.fat.min.js +2 -2
- package/es2015/jodit.js +121 -45
- package/es2015/jodit.min.css +1 -1
- 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 +5 -7
- package/es2018/jodit.fat.min.css +1 -1
- package/es2018/jodit.fat.min.js +2 -2
- package/es2018/jodit.js +121 -45
- package/es2018/jodit.min.css +1 -1
- 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 +5 -7
- package/es2021/jodit.fat.min.css +1 -1
- package/es2021/jodit.fat.min.js +2 -2
- package/es2021/jodit.js +121 -45
- package/es2021/jodit.min.css +1 -1
- 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 +5 -7
- package/es2021.en/jodit.fat.min.css +1 -1
- package/es2021.en/jodit.fat.min.js +2 -2
- package/es2021.en/jodit.js +121 -45
- package/es2021.en/jodit.min.css +1 -1
- 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/164.fat.min.js +1 -1
- package/es5/164.min.js +1 -1
- package/es5/5.fat.min.js +1 -1
- package/es5/5.min.js +1 -1
- package/es5/jodit.css +35 -66
- package/es5/jodit.fat.min.css +1 -1
- package/es5/jodit.fat.min.js +2 -2
- package/es5/jodit.js +121 -45
- package/es5/jodit.min.css +3 -3
- 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/complete-url.d.ts +0 -3
- package/esm/core/helpers/utils/complete-url.js +1 -1
- package/esm/core/helpers/utils/config-proto.d.ts +18 -0
- package/esm/core/helpers/utils/config-proto.js +25 -0
- package/esm/core/selection/style/api/extract.js +1 -0
- package/esm/jodit.d.ts +11 -1
- package/esm/jodit.js +14 -8
- package/esm/modules/history/snapshot.d.ts +1 -0
- package/esm/modules/history/snapshot.js +8 -1
- package/esm/modules/toolbar/button/button.js +18 -9
- package/esm/plugins/ai-assistant/langs/index.d.ts +3 -0
- package/esm/plugins/ai-assistant/langs/index.js +3 -0
- package/esm/plugins/image-properties/readers/align.d.ts +3 -1
- package/esm/plugins/image-properties/readers/align.js +3 -1
- package/esm/plugins/image-properties/readers/index.d.ts +3 -0
- package/esm/plugins/image-properties/readers/link.d.ts +3 -0
- package/esm/plugins/image-properties/readers/margin.js +3 -0
- package/esm/plugins/image-properties/readers/size.js +3 -0
- package/esm/plugins/image-properties/ui/ui-image-form.d.ts +3 -0
- package/esm/plugins/image-properties/ui/ui-image-main-tab.d.ts +3 -0
- package/esm/plugins/image-properties/ui/ui-image-position-tab.d.ts +3 -0
- package/esm/plugins/image-properties/utils/open-image-editor.d.ts +3 -0
- package/esm/plugins/image-properties/utils/open-image-popup.d.ts +3 -0
- package/esm/plugins/image-properties/utils/utils.js +3 -0
- package/esm/plugins/image-properties/writers/index.d.ts +3 -0
- package/esm/plugins/image-properties/writers/link.d.ts +3 -0
- package/esm/plugins/image-properties/writers/margin.d.ts +3 -0
- package/esm/plugins/image-properties/writers/size.js +3 -0
- package/esm/plugins/source/editor/engines/ace.js +4 -0
- package/esm/plugins/source/editor/engines/area.js +2 -1
- package/esm/plugins/symbols/config.js +6 -7
- package/esm/plugins/symbols/symbols.d.ts +1 -3
- package/esm/plugins/symbols/symbols.js +16 -11
- package/esm/types/history.d.ts +3 -0
- package/package.json +1 -1
- package/types/core/helpers/utils/complete-url.d.ts +0 -3
- package/types/core/helpers/utils/config-proto.d.ts +18 -0
- package/types/jodit.d.ts +11 -1
- package/types/modules/history/snapshot.d.ts +1 -0
- package/types/plugins/ai-assistant/langs/index.d.ts +3 -0
- package/types/plugins/image-properties/readers/align.d.ts +3 -1
- package/types/plugins/image-properties/readers/index.d.ts +3 -0
- package/types/plugins/image-properties/readers/link.d.ts +3 -0
- package/types/plugins/image-properties/ui/ui-image-form.d.ts +3 -0
- package/types/plugins/image-properties/ui/ui-image-main-tab.d.ts +3 -0
- package/types/plugins/image-properties/ui/ui-image-position-tab.d.ts +3 -0
- package/types/plugins/image-properties/utils/open-image-editor.d.ts +3 -0
- package/types/plugins/image-properties/utils/open-image-popup.d.ts +3 -0
- package/types/plugins/image-properties/writers/index.d.ts +3 -0
- package/types/plugins/image-properties/writers/link.d.ts +3 -0
- package/types/plugins/image-properties/writers/margin.d.ts +3 -0
- package/types/plugins/symbols/symbols.d.ts +1 -3
- package/types/types/history.d.ts +3 -0
package/package.json
CHANGED
|
@@ -3,7 +3,4 @@
|
|
|
3
3
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
4
|
* Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
-
/**
|
|
7
|
-
* @module helpers/utils
|
|
8
|
-
*/
|
|
9
6
|
export declare const completeUrl: (url: string) => string;
|
|
@@ -39,3 +39,21 @@ import type { IDictionary } from "../../../types";
|
|
|
39
39
|
*/
|
|
40
40
|
export declare function ConfigProto(options: IDictionary, proto: IDictionary, deep?: number): IDictionary;
|
|
41
41
|
export declare function ConfigFlatten(obj: IDictionary): IDictionary;
|
|
42
|
+
/**
|
|
43
|
+
* Returns a plain object from a prototype-based object.
|
|
44
|
+
* ```typescript
|
|
45
|
+
* const editor = Jodit.make('#editor', {
|
|
46
|
+
* image: {
|
|
47
|
+
* dialogWidth: 500
|
|
48
|
+
* }
|
|
49
|
+
* });
|
|
50
|
+
*
|
|
51
|
+
* console.log(editor.o.image.openOnDblClick) // true
|
|
52
|
+
* // But you can't get all options in plain object
|
|
53
|
+
* console.log(JSON.stringify(editor.o.image)); // {"dialogWidth":500}
|
|
54
|
+
*
|
|
55
|
+
* const plain = Jodit.modules.Helpers.ConfigDeepFlatten(editor.o.image);
|
|
56
|
+
* console.log(JSON.stringify(plain)); // {"dialogWidth":500, "openOnDblClick": true, "editSrc": true, ...}
|
|
57
|
+
* ```
|
|
58
|
+
*/
|
|
59
|
+
export declare function ConfigDeepFlatten(obj: IDictionary): IDictionary;
|
package/types/jodit.d.ts
CHANGED
|
@@ -49,7 +49,17 @@ export declare class Jodit extends ViewWithToolbar implements IJodit, Dlgs {
|
|
|
49
49
|
*/
|
|
50
50
|
get defaultTimeout(): number;
|
|
51
51
|
/**
|
|
52
|
-
* Method wrap usual
|
|
52
|
+
* Method wrap usual object in Object helper for prevent deep object merging in options*
|
|
53
|
+
* ```js
|
|
54
|
+
* const editor = Jodit.make('#editor', {
|
|
55
|
+
* controls: {
|
|
56
|
+
* fontsize: {
|
|
57
|
+
* list: Jodit.atom([8, 9, 10])
|
|
58
|
+
* }
|
|
59
|
+
* }
|
|
60
|
+
* });
|
|
61
|
+
* ```
|
|
62
|
+
* In this case, the array [8, 9, 10] will not be combined with other arrays, but will replace them
|
|
53
63
|
*/
|
|
54
64
|
static atom<T>(object: T): T;
|
|
55
65
|
/**
|
|
@@ -37,6 +37,7 @@ export declare class Snapshot extends ViewComponent<IJodit> implements ISnapshot
|
|
|
37
37
|
private __isBlocked;
|
|
38
38
|
get isBlocked(): boolean;
|
|
39
39
|
private __block;
|
|
40
|
+
private __levelOfTransaction;
|
|
40
41
|
transaction(changes: () => void): void;
|
|
41
42
|
/**
|
|
42
43
|
* Creates object a snapshot of editor: html and the current selection. Current selection calculate by
|
|
@@ -3,6 +3,9 @@
|
|
|
3
3
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
4
|
* Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
+
/**
|
|
7
|
+
* @module plugins/ai-assistant
|
|
8
|
+
*/
|
|
6
9
|
import * as en from "./en.js";
|
|
7
10
|
import * as es from "./es.js";
|
|
8
11
|
export { en, es };
|
|
@@ -4,5 +4,7 @@
|
|
|
4
4
|
* Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
6
|
import type { EditValues } from "../interface";
|
|
7
|
-
/**
|
|
7
|
+
/**
|
|
8
|
+
* @private
|
|
9
|
+
*/
|
|
8
10
|
export declare function readAlign(image: HTMLImageElement, values: EditValues): void;
|
|
@@ -3,6 +3,9 @@
|
|
|
3
3
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
4
|
* Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
+
/**
|
|
7
|
+
* @module plugins/image-properties
|
|
8
|
+
*/
|
|
6
9
|
import type { IJodit } from "../../../types";
|
|
7
10
|
import type { ImagePropertiesState } from "../interface";
|
|
8
11
|
/**
|
|
@@ -3,6 +3,9 @@
|
|
|
3
3
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
4
|
* Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
+
/**
|
|
7
|
+
* @module plugins/image-properties
|
|
8
|
+
*/
|
|
6
9
|
import type { IJodit } from "../../../types";
|
|
7
10
|
import type { EditValues, ImagePropertiesState } from "../interface";
|
|
8
11
|
/** @private */
|
|
@@ -3,6 +3,9 @@
|
|
|
3
3
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
4
|
* Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
+
/**
|
|
7
|
+
* @module plugins/image-properties
|
|
8
|
+
*/
|
|
6
9
|
import type { IComponent, IContainer, IElms, IJodit, Nullable } from "../../../types";
|
|
7
10
|
import { UIGroup } from "../../../core/ui/group/group";
|
|
8
11
|
import type { ImagePropertiesAPI, ImagePropertiesState } from "../interface";
|
|
@@ -3,6 +3,9 @@
|
|
|
3
3
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
4
|
* Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
+
/**
|
|
7
|
+
* @module plugins/image-properties
|
|
8
|
+
*/
|
|
6
9
|
import type { IJodit } from "../../../types";
|
|
7
10
|
import { UIGroup } from "../../../core/ui/group/group";
|
|
8
11
|
import type { ImagePropertiesAPI, ImagePropertiesState } from "../interface";
|
|
@@ -3,6 +3,9 @@
|
|
|
3
3
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
4
|
* Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
+
/**
|
|
7
|
+
* @module plugins/image-properties
|
|
8
|
+
*/
|
|
6
9
|
import type { IJodit } from "../../../types";
|
|
7
10
|
import { UIElement } from "../../../core/ui/element";
|
|
8
11
|
import type { ImagePropertiesAPI, ImagePropertiesState } from "../interface";
|
|
@@ -3,6 +3,9 @@
|
|
|
3
3
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
4
|
* Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
+
/**
|
|
7
|
+
* @module plugins/image-properties
|
|
8
|
+
*/
|
|
6
9
|
import type { IJodit } from "../../../types";
|
|
7
10
|
import type { ImagePropertiesState } from "../interface";
|
|
8
11
|
/**
|
|
@@ -3,6 +3,9 @@
|
|
|
3
3
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
4
|
* Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
+
/**
|
|
7
|
+
* @module plugins/image-properties
|
|
8
|
+
*/
|
|
6
9
|
import type { IDialog, IJodit } from "../../../types";
|
|
7
10
|
import type { ImagePropertiesState } from "../interface";
|
|
8
11
|
/** @private */
|
|
@@ -3,6 +3,9 @@
|
|
|
3
3
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
4
|
* Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
+
/**
|
|
7
|
+
* @module plugins/image-properties
|
|
8
|
+
*/
|
|
6
9
|
import type { IJodit } from "../../../types";
|
|
7
10
|
import type { ImagePropertiesState } from "../interface";
|
|
8
11
|
/**
|
|
@@ -3,6 +3,9 @@
|
|
|
3
3
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
4
|
* Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
+
/**
|
|
7
|
+
* @module plugins/image-properties
|
|
8
|
+
*/
|
|
6
9
|
import type { IJodit } from "../../../types";
|
|
7
10
|
/** @private */
|
|
8
11
|
export declare function applyLink(j: IJodit, image: HTMLImageElement, imageLink: string, imageLinkOpenInNewTab: boolean): void;
|
|
@@ -3,6 +3,9 @@
|
|
|
3
3
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
4
|
* Copyright (c) 2013-2024 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
+
/**
|
|
7
|
+
* @module plugins/image-properties
|
|
8
|
+
*/
|
|
6
9
|
import type { IJodit } from "../../../types";
|
|
7
10
|
/** @private */
|
|
8
11
|
export declare function applyMargin(j: IJodit, marginTop: number | string, marginRight: number | string, marginBottom: number | string, marginLeft: number | string, image: HTMLImageElement, marginIsLocked: boolean): void;
|
|
@@ -16,11 +16,9 @@ import "./config";
|
|
|
16
16
|
* The plugin inserts characters that are not part of the standard keyboard.
|
|
17
17
|
*/
|
|
18
18
|
export declare class symbols extends Plugin {
|
|
19
|
-
/** @override */
|
|
20
19
|
buttons: Plugin['buttons'];
|
|
21
|
-
private
|
|
20
|
+
private __countInRow;
|
|
22
21
|
constructor(jodit: IJodit);
|
|
23
|
-
/** @override */
|
|
24
22
|
afterInit(jodit: IJodit): void;
|
|
25
23
|
/** @override */
|
|
26
24
|
protected beforeDestruct(jodit: IJodit): void;
|
package/types/types/history.d.ts
CHANGED
|
@@ -28,6 +28,9 @@ export interface ISnapshot {
|
|
|
28
28
|
make(): SnapshotType;
|
|
29
29
|
restoreOnlySelection(snapshot: SnapshotType): void;
|
|
30
30
|
restore(snapshot: SnapshotType): void;
|
|
31
|
+
/**
|
|
32
|
+
* Pack all changes in one transaction without creating history point
|
|
33
|
+
*/
|
|
31
34
|
transaction(changes: () => void): void;
|
|
32
35
|
}
|
|
33
36
|
export interface IHistory {
|