jodit 4.0.0-beta.95 → 4.0.0-beta.99
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 +21 -5
- package/README.md +4 -4
- package/es2015/jodit.css +1 -1
- package/es2015/jodit.fat.min.js +2 -2
- package/es2015/jodit.js +95 -88
- package/es2015/jodit.min.js +2 -2
- 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 +95 -88
- package/es2018/jodit.min.js +2 -2
- 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 +95 -88
- package/es2021/jodit.min.js +2 -2
- 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 +95 -88
- package/es2021.en/jodit.min.js +2 -2
- 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/jodit.css +2 -2
- package/es5/jodit.fat.min.js +2 -2
- package/es5/jodit.js +104 -97
- package/es5/jodit.min.css +2 -2
- package/es5/jodit.min.js +2 -2
- 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/async/async.d.ts +1 -1
- package/esm/core/async/async.js +4 -0
- package/esm/core/constants.js +1 -1
- package/esm/core/helpers/string/ucfirst.js +1 -1
- package/esm/core/helpers/utils/index.d.ts +0 -1
- package/esm/core/helpers/utils/index.js +0 -1
- package/esm/core/selection/interface.d.ts +1 -1
- package/esm/core/ui/form/inputs/area/area.d.ts +1 -1
- package/esm/core/ui/form/inputs/area/area.js +1 -1
- package/esm/core/ui/form/inputs/checkbox/checkbox.d.ts +1 -1
- package/esm/core/ui/form/inputs/checkbox/checkbox.js +1 -1
- package/esm/core/ui/form/inputs/file/file.d.ts +1 -1
- package/esm/core/ui/form/inputs/file/file.js +1 -1
- package/esm/core/ui/form/inputs/index.d.ts +1 -1
- package/esm/core/ui/form/inputs/index.js +1 -1
- package/esm/core/ui/form/inputs/input/input.d.ts +1 -1
- package/esm/core/ui/form/inputs/input/input.js +1 -1
- package/esm/core/ui/form/inputs/select/select.d.ts +1 -1
- package/esm/core/ui/form/inputs/select/select.js +1 -1
- package/esm/modules/messages/messages.d.ts +28 -0
- package/esm/modules/messages/messages.js +28 -0
- package/esm/modules/table/table.d.ts +4 -2
- package/esm/modules/table/table.js +2 -0
- package/esm/modules/widget/color-picker/color-picker.d.ts +1 -1
- package/esm/modules/widget/color-picker/color-picker.js +1 -1
- package/esm/modules/widget/file-selector/file-selector.d.ts +1 -18
- package/esm/modules/widget/file-selector/file-selector.js +12 -19
- package/esm/modules/widget/tabs/tabs.d.ts +17 -6
- package/esm/modules/widget/tabs/tabs.js +17 -6
- package/package.json +1 -1
- package/types/core/async/async.d.ts +1 -1
- package/types/core/helpers/utils/index.d.ts +0 -1
- package/types/core/selection/interface.d.ts +1 -1
- package/types/core/ui/form/inputs/area/area.d.ts +1 -1
- package/types/core/ui/form/inputs/checkbox/checkbox.d.ts +1 -1
- package/types/core/ui/form/inputs/file/file.d.ts +1 -1
- package/types/core/ui/form/inputs/index.d.ts +1 -1
- package/types/core/ui/form/inputs/input/input.d.ts +1 -1
- package/types/core/ui/form/inputs/select/select.d.ts +1 -1
- package/types/modules/messages/messages.d.ts +28 -0
- package/types/modules/table/table.d.ts +4 -2
- package/types/modules/widget/color-picker/color-picker.d.ts +1 -1
- package/types/modules/widget/file-selector/file-selector.d.ts +1 -18
- package/types/modules/widget/tabs/tabs.d.ts +17 -6
- package/esm/core/helpers/utils/val.d.ts +0 -9
- package/esm/core/helpers/utils/val.js +0 -18
- package/types/core/helpers/utils/val.d.ts +0 -9
|
@@ -14,7 +14,7 @@ export declare class Async implements IAsync {
|
|
|
14
14
|
private timers;
|
|
15
15
|
private __callbacks;
|
|
16
16
|
delay(timeout: number | IAsyncParams): RejectablePromise<void>;
|
|
17
|
-
setTimeout(callback: Callback, timeout: number | IAsyncParams, ...args: any[]): number;
|
|
17
|
+
setTimeout(callback: Callback, timeout: number | IAsyncParams | undefined, ...args: any[]): number;
|
|
18
18
|
updateTimeout(label: string, timeout: number): Nullable<number>;
|
|
19
19
|
private clearLabel;
|
|
20
20
|
clearTimeout(timer: number): void;
|
package/esm/core/async/async.js
CHANGED
|
@@ -10,6 +10,7 @@ import { isPromise } from "jodit/esm/core/helpers/checker/is-promise.js";
|
|
|
10
10
|
import { isString } from "jodit/esm/core/helpers/checker/is-string.js";
|
|
11
11
|
import { isNumber } from "jodit/esm/core/helpers/checker/is-number.js";
|
|
12
12
|
import { assert } from "jodit/esm/core/helpers/utils/assert.js";
|
|
13
|
+
import { isVoid } from "jodit/esm/core/helpers/checker/is-void.js";
|
|
13
14
|
import { IS_ES_NEXT } from "jodit/esm/core/constants.js";
|
|
14
15
|
export class Async {
|
|
15
16
|
constructor() {
|
|
@@ -44,6 +45,9 @@ export class Async {
|
|
|
44
45
|
return 0;
|
|
45
46
|
}
|
|
46
47
|
let options = {};
|
|
48
|
+
if (isVoid(timeout)) {
|
|
49
|
+
timeout = 0;
|
|
50
|
+
}
|
|
47
51
|
if (!isNumber(timeout)) {
|
|
48
52
|
options = timeout;
|
|
49
53
|
timeout = options.timeout || 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-2023 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
-
export const APP_VERSION = "4.0.0-beta.
|
|
6
|
+
export const APP_VERSION = "4.0.0-beta.99";
|
|
7
7
|
// prettier-ignore
|
|
8
8
|
export const ES = "es2020";
|
|
9
9
|
export const IS_ES_MODERN = true;
|
|
@@ -3,10 +3,10 @@
|
|
|
3
3
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
4
|
* Copyright (c) 2013-2023 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
-
import type { ICommitStyle } from "jodit/esm/types";
|
|
7
6
|
/**
|
|
8
7
|
* @module selection
|
|
9
8
|
*/
|
|
9
|
+
import type { ICommitStyle } from "jodit/esm/types";
|
|
10
10
|
declare module 'jodit/types/events' {
|
|
11
11
|
interface IEventEmitter {
|
|
12
12
|
/**
|
|
@@ -15,7 +15,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
15
15
|
};
|
|
16
16
|
var UITextArea_1;
|
|
17
17
|
/**
|
|
18
|
-
* @module ui/form
|
|
18
|
+
* @module ui/form
|
|
19
19
|
*/
|
|
20
20
|
import { UIInput } from "jodit/esm/core/ui/form/inputs/input/input.js";
|
|
21
21
|
import { component } from "jodit/esm/core/decorators/component/component.js";
|
|
@@ -15,7 +15,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
15
15
|
};
|
|
16
16
|
var UICheckbox_1;
|
|
17
17
|
/**
|
|
18
|
-
* @module ui/form
|
|
18
|
+
* @module ui/form
|
|
19
19
|
*/
|
|
20
20
|
import { UIInput } from "jodit/esm/core/ui/form/inputs/input/input.js";
|
|
21
21
|
import { component, watch, hook } from "jodit/esm/core/decorators/index.js";
|
|
@@ -14,7 +14,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
14
14
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
15
15
|
};
|
|
16
16
|
/**
|
|
17
|
-
* @module ui/form
|
|
17
|
+
* @module ui/form
|
|
18
18
|
*/
|
|
19
19
|
import { UIInput } from "jodit/esm/core/ui/form/inputs/input/input.js";
|
|
20
20
|
import { component } from "jodit/esm/core/decorators/component/component.js";
|
|
@@ -15,7 +15,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
15
15
|
};
|
|
16
16
|
var UIInput_1;
|
|
17
17
|
/**
|
|
18
|
-
* @module ui/form
|
|
18
|
+
* @module ui/form
|
|
19
19
|
*/
|
|
20
20
|
import { UIElement } from "jodit/esm/core/ui/element.js";
|
|
21
21
|
import { attr } from "jodit/esm/core/helpers/utils/index.js";
|
|
@@ -15,7 +15,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
15
15
|
};
|
|
16
16
|
var UISelect_1;
|
|
17
17
|
/**
|
|
18
|
-
* @module ui/form
|
|
18
|
+
* @module ui/form
|
|
19
19
|
*/
|
|
20
20
|
import { attr } from "jodit/esm/core/helpers/utils/attr.js";
|
|
21
21
|
import { component } from "jodit/esm/core/decorators/component/component.js";
|
|
@@ -25,9 +25,37 @@ export declare class UIMessages extends UIGroup implements IMessages {
|
|
|
25
25
|
defaultTimeout: number;
|
|
26
26
|
defaultOffset: number;
|
|
27
27
|
});
|
|
28
|
+
/**
|
|
29
|
+
* Show popup info message in the lower right corner of the container
|
|
30
|
+
* ```js
|
|
31
|
+
* const jodit = Jodit.make('#editor');
|
|
32
|
+
* jodit.info('Hello world', 3000);
|
|
33
|
+
* ```
|
|
34
|
+
*/
|
|
28
35
|
info(text: string, timeout?: number): void;
|
|
36
|
+
/**
|
|
37
|
+
* Show popup success message in the lower right corner of the container
|
|
38
|
+
* ```js
|
|
39
|
+
* const jodit = Jodit.make('#editor');
|
|
40
|
+
* jodit.success('Hello world', 3000);
|
|
41
|
+
* ```
|
|
42
|
+
*/
|
|
29
43
|
success(text: string, timeout?: number): void;
|
|
44
|
+
/**
|
|
45
|
+
* Show popup error message in the lower right corner of the container
|
|
46
|
+
* ```js
|
|
47
|
+
* const jodit = Jodit.make('#editor');
|
|
48
|
+
* jodit.error('Hello world', 3000);
|
|
49
|
+
* ```
|
|
50
|
+
*/
|
|
30
51
|
error(text: string, timeout?: number): void;
|
|
52
|
+
/**
|
|
53
|
+
* Show popup message in the lower right corner of the container
|
|
54
|
+
* ```js
|
|
55
|
+
* const jodit = Jodit.make('#editor');
|
|
56
|
+
* jodit.message('Hello world', 'info', 3000);
|
|
57
|
+
* ```
|
|
58
|
+
*/
|
|
31
59
|
message(text: string, variant?: MessageVariant, timeout?: number): void;
|
|
32
60
|
private __message;
|
|
33
61
|
private __getRemoveCallback;
|
|
@@ -38,15 +38,43 @@ let UIMessages = class UIMessages extends UIGroup {
|
|
|
38
38
|
this.options = options;
|
|
39
39
|
this.__messages = new Set();
|
|
40
40
|
}
|
|
41
|
+
/**
|
|
42
|
+
* Show popup info message in the lower right corner of the container
|
|
43
|
+
* ```js
|
|
44
|
+
* const jodit = Jodit.make('#editor');
|
|
45
|
+
* jodit.info('Hello world', 3000);
|
|
46
|
+
* ```
|
|
47
|
+
*/
|
|
41
48
|
info(text, timeout) {
|
|
42
49
|
this.__message(text, 'info', timeout);
|
|
43
50
|
}
|
|
51
|
+
/**
|
|
52
|
+
* Show popup success message in the lower right corner of the container
|
|
53
|
+
* ```js
|
|
54
|
+
* const jodit = Jodit.make('#editor');
|
|
55
|
+
* jodit.success('Hello world', 3000);
|
|
56
|
+
* ```
|
|
57
|
+
*/
|
|
44
58
|
success(text, timeout) {
|
|
45
59
|
this.__message(text, 'success', timeout);
|
|
46
60
|
}
|
|
61
|
+
/**
|
|
62
|
+
* Show popup error message in the lower right corner of the container
|
|
63
|
+
* ```js
|
|
64
|
+
* const jodit = Jodit.make('#editor');
|
|
65
|
+
* jodit.error('Hello world', 3000);
|
|
66
|
+
* ```
|
|
67
|
+
*/
|
|
47
68
|
error(text, timeout) {
|
|
48
69
|
this.__message(text, 'error', timeout);
|
|
49
70
|
}
|
|
71
|
+
/**
|
|
72
|
+
* Show popup message in the lower right corner of the container
|
|
73
|
+
* ```js
|
|
74
|
+
* const jodit = Jodit.make('#editor');
|
|
75
|
+
* jodit.message('Hello world', 'info', 3000);
|
|
76
|
+
* ```
|
|
77
|
+
*/
|
|
50
78
|
message(text, variant, timeout) {
|
|
51
79
|
this.__message(text, variant, timeout);
|
|
52
80
|
}
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
* @packageDocumentation
|
|
9
9
|
* @module modules/table
|
|
10
10
|
*/
|
|
11
|
-
import type { ICreate, IJodit } from "jodit/esm/types";
|
|
11
|
+
import type { ICreate, IJodit, Prettify } from "jodit/esm/types";
|
|
12
12
|
import { ViewComponent } from "jodit/esm/core/component";
|
|
13
13
|
export declare class Table extends ViewComponent<IJodit> {
|
|
14
14
|
/** @override */
|
|
@@ -45,11 +45,13 @@ export declare class Table extends ViewComponent<IJodit> {
|
|
|
45
45
|
/**
|
|
46
46
|
* Inserts a new line after row what contains the selected cell
|
|
47
47
|
*
|
|
48
|
+
* @param table - Working table
|
|
48
49
|
* @param line - Insert a new line after/before this
|
|
49
50
|
* line contains the selected cell
|
|
50
51
|
* @param after - Insert a new line after line contains the selected cell
|
|
52
|
+
* @param create - Instance of Create class
|
|
51
53
|
*/
|
|
52
|
-
static appendRow(table: HTMLTableElement, line: false | HTMLTableRowElement, after: boolean, create: ICreate): void;
|
|
54
|
+
static appendRow(table: HTMLTableElement, line: false | HTMLTableRowElement, after: boolean, create: Prettify<Pick<ICreate, 'element'>>): void;
|
|
53
55
|
/**
|
|
54
56
|
* Remove row
|
|
55
57
|
*/
|
|
@@ -156,9 +156,11 @@ export class Table extends ViewComponent {
|
|
|
156
156
|
/**
|
|
157
157
|
* Inserts a new line after row what contains the selected cell
|
|
158
158
|
*
|
|
159
|
+
* @param table - Working table
|
|
159
160
|
* @param line - Insert a new line after/before this
|
|
160
161
|
* line contains the selected cell
|
|
161
162
|
* @param after - Insert a new line after line contains the selected cell
|
|
163
|
+
* @param create - Instance of Create class
|
|
162
164
|
*/
|
|
163
165
|
static appendRow(table, line, after, create) {
|
|
164
166
|
let row;
|
|
@@ -17,7 +17,7 @@ import type { IJodit } from "jodit/esm/types";
|
|
|
17
17
|
* @param coldColor - Color value ex. #fff or rgb(123, 123, 123) or rgba(123, 123, 123, 1)
|
|
18
18
|
* @example
|
|
19
19
|
* ```javascript
|
|
20
|
-
*
|
|
20
|
+
* const tabs = TabsWidget(editor, {
|
|
21
21
|
* 'Text' : ColorPickerWidget(editor, function (color) {
|
|
22
22
|
* box.style.color = color;
|
|
23
23
|
* }, box.style.color),
|
|
@@ -20,7 +20,7 @@ Icon.set('palette', paletteIcon);
|
|
|
20
20
|
* @param coldColor - Color value ex. #fff or rgb(123, 123, 123) or rgba(123, 123, 123, 1)
|
|
21
21
|
* @example
|
|
22
22
|
* ```javascript
|
|
23
|
-
*
|
|
23
|
+
* const tabs = TabsWidget(editor, {
|
|
24
24
|
* 'Text' : ColorPickerWidget(editor, function (color) {
|
|
25
25
|
* box.style.color = color;
|
|
26
26
|
* }, box.style.color),
|
|
@@ -28,27 +28,10 @@ interface ImageSelectorCallbacks {
|
|
|
28
28
|
* Generate 3 tabs
|
|
29
29
|
* upload - Use Drag and Drop
|
|
30
30
|
* url - By specifying the image url
|
|
31
|
-
* filebrowser - After opening the file browser
|
|
31
|
+
* filebrowser - After opening the file browser. In the absence of one of the parameters will be less tabs
|
|
32
32
|
*
|
|
33
33
|
* @param callbacks - Object with keys `url`, `upload` and `filebrowser`, values which are callback
|
|
34
34
|
* functions with different parameters
|
|
35
|
-
*
|
|
36
|
-
* @example
|
|
37
|
-
* ```javascript
|
|
38
|
-
* let widget = new Jodit.modules.Widget(editor);
|
|
39
|
-
*
|
|
40
|
-
* return widget.c('ImageSelector', {
|
|
41
|
-
* url: function (url, alt) {
|
|
42
|
-
* editor.selections.insertImage(url);
|
|
43
|
-
* },
|
|
44
|
-
* upload: function (images) {
|
|
45
|
-
* editor.selections.insertImage(images[0]);
|
|
46
|
-
* },
|
|
47
|
-
* filebrowser: function (images) {
|
|
48
|
-
* editor.selections.insertImage(images[0]);
|
|
49
|
-
* }
|
|
50
|
-
* }, image);
|
|
51
|
-
* ```
|
|
52
35
|
*/
|
|
53
36
|
export declare const FileSelectorWidget: (editor: IJodit, callbacks: ImageSelectorCallbacks, elm: HTMLElement | null, close: () => void, isImage?: boolean) => HTMLDivElement;
|
|
54
37
|
export {};
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
4
|
* Copyright (c) 2013-2023 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
-
import { isFunction, $$, attr
|
|
6
|
+
import { isFunction, $$, attr } from "jodit/esm/core/helpers/index.js";
|
|
7
7
|
import { Dom } from "jodit/esm/core/dom/dom.js";
|
|
8
8
|
import { UIBlock, UIForm, UIInput, UIButton } from "jodit/esm/core/ui/index.js";
|
|
9
9
|
import { TabsWidget } from "jodit/esm/modules/widget/tabs/tabs.js";
|
|
@@ -11,27 +11,10 @@ import { TabsWidget } from "jodit/esm/modules/widget/tabs/tabs.js";
|
|
|
11
11
|
* Generate 3 tabs
|
|
12
12
|
* upload - Use Drag and Drop
|
|
13
13
|
* url - By specifying the image url
|
|
14
|
-
* filebrowser - After opening the file browser
|
|
14
|
+
* filebrowser - After opening the file browser. In the absence of one of the parameters will be less tabs
|
|
15
15
|
*
|
|
16
16
|
* @param callbacks - Object with keys `url`, `upload` and `filebrowser`, values which are callback
|
|
17
17
|
* functions with different parameters
|
|
18
|
-
*
|
|
19
|
-
* @example
|
|
20
|
-
* ```javascript
|
|
21
|
-
* let widget = new Jodit.modules.Widget(editor);
|
|
22
|
-
*
|
|
23
|
-
* return widget.c('ImageSelector', {
|
|
24
|
-
* url: function (url, alt) {
|
|
25
|
-
* editor.selections.insertImage(url);
|
|
26
|
-
* },
|
|
27
|
-
* upload: function (images) {
|
|
28
|
-
* editor.selections.insertImage(images[0]);
|
|
29
|
-
* },
|
|
30
|
-
* filebrowser: function (images) {
|
|
31
|
-
* editor.selections.insertImage(images[0]);
|
|
32
|
-
* }
|
|
33
|
-
* }, image);
|
|
34
|
-
* ```
|
|
35
18
|
*/
|
|
36
19
|
export const FileSelectorWidget = (editor, callbacks, elm, close, isImage = true) => {
|
|
37
20
|
let currentImage;
|
|
@@ -122,3 +105,13 @@ export const FileSelectorWidget = (editor, callbacks, elm, close, isImage = true
|
|
|
122
105
|
}
|
|
123
106
|
return TabsWidget(editor, tabs);
|
|
124
107
|
};
|
|
108
|
+
function val(elm, selector, value) {
|
|
109
|
+
const child = elm.querySelector(selector);
|
|
110
|
+
if (!child) {
|
|
111
|
+
return '';
|
|
112
|
+
}
|
|
113
|
+
if (value) {
|
|
114
|
+
child.value = value;
|
|
115
|
+
}
|
|
116
|
+
return child.value;
|
|
117
|
+
}
|
|
@@ -24,12 +24,23 @@ export interface TabOption {
|
|
|
24
24
|
*
|
|
25
25
|
* @example
|
|
26
26
|
* ```javascript
|
|
27
|
-
*
|
|
28
|
-
*
|
|
29
|
-
*
|
|
30
|
-
*
|
|
31
|
-
*
|
|
32
|
-
*
|
|
27
|
+
* const editor = Jodit.make('#editor');
|
|
28
|
+
* const tabs = Jodit.modules.TabsWidget(editor, [
|
|
29
|
+
* { name: 'Images', content: '<div>Images</div>' },
|
|
30
|
+
* {
|
|
31
|
+
* name: 'Title 2',
|
|
32
|
+
* content: editor.c.fromHTML('<div>Some content</div>')
|
|
33
|
+
* },
|
|
34
|
+
* {
|
|
35
|
+
* name: 'Color Picker',
|
|
36
|
+
* content: ColorPickerWidget(
|
|
37
|
+
* editor,
|
|
38
|
+
* function (color) {
|
|
39
|
+
* box.style.color = color;
|
|
40
|
+
* },
|
|
41
|
+
* box.style.color
|
|
42
|
+
* )
|
|
43
|
+
* }
|
|
33
44
|
* ]);
|
|
34
45
|
* ```
|
|
35
46
|
*/
|
|
@@ -21,12 +21,23 @@ import { Dom } from "jodit/esm/core/dom/dom.js";
|
|
|
21
21
|
*
|
|
22
22
|
* @example
|
|
23
23
|
* ```javascript
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
*
|
|
28
|
-
*
|
|
29
|
-
*
|
|
24
|
+
* const editor = Jodit.make('#editor');
|
|
25
|
+
* const tabs = Jodit.modules.TabsWidget(editor, [
|
|
26
|
+
* { name: 'Images', content: '<div>Images</div>' },
|
|
27
|
+
* {
|
|
28
|
+
* name: 'Title 2',
|
|
29
|
+
* content: editor.c.fromHTML('<div>Some content</div>')
|
|
30
|
+
* },
|
|
31
|
+
* {
|
|
32
|
+
* name: 'Color Picker',
|
|
33
|
+
* content: ColorPickerWidget(
|
|
34
|
+
* editor,
|
|
35
|
+
* function (color) {
|
|
36
|
+
* box.style.color = color;
|
|
37
|
+
* },
|
|
38
|
+
* box.style.color
|
|
39
|
+
* )
|
|
40
|
+
* }
|
|
30
41
|
* ]);
|
|
31
42
|
* ```
|
|
32
43
|
*/
|
package/package.json
CHANGED
|
@@ -14,7 +14,7 @@ export declare class Async implements IAsync {
|
|
|
14
14
|
private timers;
|
|
15
15
|
private __callbacks;
|
|
16
16
|
delay(timeout: number | IAsyncParams): RejectablePromise<void>;
|
|
17
|
-
setTimeout(callback: Callback, timeout: number | IAsyncParams, ...args: any[]): number;
|
|
17
|
+
setTimeout(callback: Callback, timeout: number | IAsyncParams | undefined, ...args: any[]): number;
|
|
18
18
|
updateTimeout(label: string, timeout: number): Nullable<number>;
|
|
19
19
|
private clearLabel;
|
|
20
20
|
clearTimeout(timer: number): void;
|
|
@@ -3,10 +3,10 @@
|
|
|
3
3
|
* Released under MIT see LICENSE.txt in the project root for license information.
|
|
4
4
|
* Copyright (c) 2013-2023 Valeriy Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
-
import type { ICommitStyle } from "jodit/esm/types";
|
|
7
6
|
/**
|
|
8
7
|
* @module selection
|
|
9
8
|
*/
|
|
9
|
+
import type { ICommitStyle } from "jodit/esm/types";
|
|
10
10
|
declare module 'jodit/types/events' {
|
|
11
11
|
interface IEventEmitter {
|
|
12
12
|
/**
|