jodit 4.17.3 → 4.17.4
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 +6 -0
- package/es2015/jodit.css +1 -1
- package/es2015/jodit.fat.min.js +3 -3
- package/es2015/jodit.js +28 -7
- package/es2015/jodit.min.js +10 -10
- 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.fat.min.js +3 -3
- package/es2018/jodit.min.js +3 -3
- package/es2018/plugins/debug/debug.min.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 +3 -3
- package/es2021/jodit.js +28 -7
- package/es2021/jodit.min.js +3 -3
- 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 +3 -3
- package/es2021.en/jodit.js +28 -7
- package/es2021.en/jodit.min.js +3 -3
- 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/jodit.css +2 -2
- package/es5/jodit.fat.min.js +2 -2
- package/es5/jodit.js +28 -7
- 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/es5/polyfills.fat.min.js +1 -1
- package/es5/polyfills.js +1 -1
- package/es5/polyfills.min.js +1 -1
- package/esm/core/constants.js +1 -1
- package/esm/modules/file-browser/data-provider.d.ts +1 -0
- package/esm/modules/file-browser/data-provider.js +26 -5
- package/package.json +1 -1
- package/types/modules/file-browser/data-provider.d.ts +1 -0
- package/.nvmrc +0 -1
- package/examples/build/es2015/jodit.min.css +0 -1
- package/examples/build/es2015/jodit.min.js +0 -10
- package/examples/build/es2015/plugins/debug/debug.min.js +0 -10
- package/examples/build/es2015/plugins/speech-recognize/speech-recognize.min.css +0 -1
- package/examples/build/es2015/plugins/speech-recognize/speech-recognize.min.js +0 -10
package/es2015/jodit.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* jodit - Jodit is an awesome and useful wysiwyg editor with filebrowser
|
|
3
3
|
* Author: Chupurnov <chupurnov@gmail.com> (https://xdsoft.net/jodit/)
|
|
4
|
-
* Version: v4.17.
|
|
4
|
+
* Version: v4.17.4
|
|
5
5
|
* Url: https://xdsoft.net/jodit/
|
|
6
6
|
* License(s): MIT
|
|
7
7
|
*/
|
|
@@ -1805,7 +1805,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
1805
1805
|
* ```
|
|
1806
1806
|
* @packageDocumentation
|
|
1807
1807
|
* @module constants
|
|
1808
|
-
*/ const APP_VERSION = "4.17.
|
|
1808
|
+
*/ const APP_VERSION = "4.17.4";
|
|
1809
1809
|
// prettier-ignore
|
|
1810
1810
|
const ES = "es2015";
|
|
1811
1811
|
const IS_ES_MODERN = true;
|
|
@@ -20947,6 +20947,16 @@ const DOCS_URL = 'https://xdsoft.net/jodit/docs/modules/file_browser.html';
|
|
|
20947
20947
|
});
|
|
20948
20948
|
return resp;
|
|
20949
20949
|
}
|
|
20950
|
+
/**
|
|
20951
|
+
* Actions that only read from the connector. A newer request for one of them
|
|
20952
|
+
* makes the older one pointless, so it is aborted; every other action changes
|
|
20953
|
+
* server state and must be allowed to finish.
|
|
20954
|
+
*/ const REPLACEABLE_ACTIONS = new Set([
|
|
20955
|
+
'items',
|
|
20956
|
+
'folder',
|
|
20957
|
+
'permissions',
|
|
20958
|
+
'getLocalFileByUrl'
|
|
20959
|
+
]);
|
|
20950
20960
|
class DataProvider {
|
|
20951
20961
|
/**
|
|
20952
20962
|
* Alias for options
|
|
@@ -20955,10 +20965,19 @@ class DataProvider {
|
|
|
20955
20965
|
}
|
|
20956
20966
|
get(name) {
|
|
20957
20967
|
const instances = this.__ajaxInstances;
|
|
20958
|
-
|
|
20959
|
-
|
|
20968
|
+
// A listing asked for again supersedes the one still loading, so the
|
|
20969
|
+
// earlier request is aborted. That must never happen to a request
|
|
20970
|
+
// that changes something on the server: aborting it does not undo it,
|
|
20971
|
+
// the caller just never hears the result. Removing several files at
|
|
20972
|
+
// once used to send one `fileRemove` per file and abort all but the
|
|
20973
|
+
// last, so only the last one was ever removed. Mutating requests get a
|
|
20974
|
+
// key of their own and run side by side.
|
|
20975
|
+
const replaceable = REPLACEABLE_ACTIONS.has(name);
|
|
20976
|
+
const key = replaceable ? name : `${name}#${++this.__requestSerial}`;
|
|
20977
|
+
if (replaceable && instances.has(key)) {
|
|
20978
|
+
const ajax = instances.get(key);
|
|
20960
20979
|
ajax === null || ajax === void 0 ? void 0 : ajax.abort();
|
|
20961
|
-
instances.delete(
|
|
20980
|
+
instances.delete(key);
|
|
20962
20981
|
}
|
|
20963
20982
|
const opts = (0,jodit_core_helpers_utils_config_proto__WEBPACK_IMPORTED_MODULE_11__.ConfigProto)(this.options[name] !== undefined ? this.options[name] : {}, (0,jodit_core_helpers_utils_config_proto__WEBPACK_IMPORTED_MODULE_11__.ConfigProto)({
|
|
20964
20983
|
onProgress: this.progressHandler
|
|
@@ -20967,11 +20986,11 @@ class DataProvider {
|
|
|
20967
20986
|
opts.data = opts.prepareData.call(this, opts.data);
|
|
20968
20987
|
}
|
|
20969
20988
|
const ajax = new jodit_core_request_ajax__WEBPACK_IMPORTED_MODULE_14__.Ajax(opts);
|
|
20970
|
-
instances.set(
|
|
20989
|
+
instances.set(key, ajax);
|
|
20971
20990
|
const promise = ajax.send();
|
|
20972
20991
|
promise.finally(()=>{
|
|
20973
20992
|
ajax.destruct();
|
|
20974
|
-
instances.delete(
|
|
20993
|
+
instances.delete(key);
|
|
20975
20994
|
this.progressHandler(100);
|
|
20976
20995
|
}).catch(()=>null);
|
|
20977
20996
|
return promise.then((resp)=>resp.json()).then((resp)=>{
|
|
@@ -21283,11 +21302,13 @@ class DataProvider {
|
|
|
21283
21302
|
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "options", void 0);
|
|
21284
21303
|
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "__currentPermissions", void 0);
|
|
21285
21304
|
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "__ajaxInstances", void 0);
|
|
21305
|
+
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "__requestSerial", void 0);
|
|
21286
21306
|
(0,_swc_helpers_define_property__WEBPACK_IMPORTED_MODULE_1__._)(this, "progressHandler", void 0);
|
|
21287
21307
|
this.parent = parent;
|
|
21288
21308
|
this.options = options;
|
|
21289
21309
|
this.__currentPermissions = null;
|
|
21290
21310
|
this.__ajaxInstances = new Map();
|
|
21311
|
+
this.__requestSerial = 0;
|
|
21291
21312
|
this.progressHandler = (ignore)=>{};
|
|
21292
21313
|
}
|
|
21293
21314
|
}
|