jodit 4.15.5 → 4.15.6
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 +11 -2
- package/es2015/jodit.min.js +3 -3
- 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 +11 -2
- 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 +11 -2
- 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 +11 -2
- 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/plugins/link/link.js +9 -0
- package/package.json +1 -1
package/es5/polyfills.fat.min.js
CHANGED
package/es5/polyfills.js
CHANGED
package/es5/polyfills.min.js
CHANGED
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-2026 Valerii Chupurnov. All rights reserved. https://xdsoft.net
|
|
5
5
|
*/
|
|
6
|
-
export const APP_VERSION = "4.15.
|
|
6
|
+
export const APP_VERSION = "4.15.6";
|
|
7
7
|
// prettier-ignore
|
|
8
8
|
export const ES = "es2020";
|
|
9
9
|
export const IS_ES_MODERN = true;
|
package/esm/plugins/link/link.js
CHANGED
|
@@ -204,6 +204,7 @@ export class link extends Plugin {
|
|
|
204
204
|
jodit.history.snapshot.restore(snapshot);
|
|
205
205
|
const textWasChanged = getSelectionText() !== content_input.value.trim();
|
|
206
206
|
const ci = jodit.createInside;
|
|
207
|
+
let caretAfter = null;
|
|
207
208
|
if (!link || !Dom.isOrContains(jodit.editor, link)) {
|
|
208
209
|
if (!jodit.s.isCollapsed()) {
|
|
209
210
|
const node = jodit.s.current();
|
|
@@ -218,6 +219,7 @@ export class link extends Plugin {
|
|
|
218
219
|
const a = ci.element('a');
|
|
219
220
|
jodit.s.insertNode(a, false, false);
|
|
220
221
|
links = [a];
|
|
222
|
+
caretAfter = a;
|
|
221
223
|
}
|
|
222
224
|
links.forEach(link => jodit.s.select(link));
|
|
223
225
|
}
|
|
@@ -252,6 +254,13 @@ export class link extends Plugin {
|
|
|
252
254
|
}
|
|
253
255
|
jodit.e.fire('applyLink', jodit, a, form);
|
|
254
256
|
});
|
|
257
|
+
// A brand-new link inserted at a collapsed caret used to stay
|
|
258
|
+
// *selected*. Safari does not paint that selection, so the next
|
|
259
|
+
// Enter silently replaced the link instead of starting a new line.
|
|
260
|
+
// Put the caret right after the link instead.
|
|
261
|
+
if (caretAfter) {
|
|
262
|
+
jodit.s.setCursorAfter(caretAfter);
|
|
263
|
+
}
|
|
255
264
|
jodit.synchronizeValues();
|
|
256
265
|
close();
|
|
257
266
|
return false;
|