mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-09-08 17:07:03 +03:00
Upgraded squire 2.3.1 to 2.3.2
This commit is contained in:
parent
de042ed365
commit
f1468cb08b
11 changed files with 60 additions and 29 deletions
15
vendors/squire-rte/dist/squire-raw.js
vendored
15
vendors/squire-rte/dist/squire-raw.js
vendored
|
|
@ -2594,7 +2594,7 @@
|
|||
this._lastAnchorNode = anchor;
|
||||
this._lastFocusNode = focus;
|
||||
newPath = anchor && focus ? anchor === focus ? this._getPath(focus) : "(selection)" : "";
|
||||
if (this._path !== newPath) {
|
||||
if (this._path !== newPath || anchor !== focus) {
|
||||
this._path = newPath;
|
||||
this.fireEvent("pathChange", {
|
||||
path: newPath
|
||||
|
|
@ -3549,7 +3549,7 @@
|
|||
this.decreaseListLevel(range);
|
||||
return this;
|
||||
} else if (getNearest(block, root, "BLOCKQUOTE")) {
|
||||
this.removeQuote(range);
|
||||
this.replaceWithBlankLine(range);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
|
@ -3900,6 +3900,17 @@
|
|||
return this.focus();
|
||||
}
|
||||
removeQuote(range) {
|
||||
this.modifyBlocks((frag) => {
|
||||
Array.from(frag.querySelectorAll("blockquote")).forEach(
|
||||
(el) => {
|
||||
replaceWith(el, empty(el));
|
||||
}
|
||||
);
|
||||
return frag;
|
||||
}, range);
|
||||
return this.focus();
|
||||
}
|
||||
replaceWithBlankLine(range) {
|
||||
this.modifyBlocks(
|
||||
() => this.createDefaultBlock([
|
||||
createElement("INPUT", {
|
||||
|
|
|
|||
15
vendors/squire-rte/dist/squire-raw.mjs
vendored
15
vendors/squire-rte/dist/squire-raw.mjs
vendored
|
|
@ -2591,7 +2591,7 @@ var Squire = class {
|
|||
this._lastAnchorNode = anchor;
|
||||
this._lastFocusNode = focus;
|
||||
newPath = anchor && focus ? anchor === focus ? this._getPath(focus) : "(selection)" : "";
|
||||
if (this._path !== newPath) {
|
||||
if (this._path !== newPath || anchor !== focus) {
|
||||
this._path = newPath;
|
||||
this.fireEvent("pathChange", {
|
||||
path: newPath
|
||||
|
|
@ -3546,7 +3546,7 @@ var Squire = class {
|
|||
this.decreaseListLevel(range);
|
||||
return this;
|
||||
} else if (getNearest(block, root, "BLOCKQUOTE")) {
|
||||
this.removeQuote(range);
|
||||
this.replaceWithBlankLine(range);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
|
@ -3897,6 +3897,17 @@ var Squire = class {
|
|||
return this.focus();
|
||||
}
|
||||
removeQuote(range) {
|
||||
this.modifyBlocks((frag) => {
|
||||
Array.from(frag.querySelectorAll("blockquote")).forEach(
|
||||
(el) => {
|
||||
replaceWith(el, empty(el));
|
||||
}
|
||||
);
|
||||
return frag;
|
||||
}, range);
|
||||
return this.focus();
|
||||
}
|
||||
replaceWithBlankLine(range) {
|
||||
this.modifyBlocks(
|
||||
() => this.createDefaultBlock([
|
||||
createElement("INPUT", {
|
||||
|
|
|
|||
18
vendors/squire-rte/dist/squire.js
vendored
18
vendors/squire-rte/dist/squire.js
vendored
File diff suppressed because one or more lines are too long
4
vendors/squire-rte/dist/squire.js.map
vendored
4
vendors/squire-rte/dist/squire.js.map
vendored
File diff suppressed because one or more lines are too long
18
vendors/squire-rte/dist/squire.mjs
vendored
18
vendors/squire-rte/dist/squire.mjs
vendored
File diff suppressed because one or more lines are too long
4
vendors/squire-rte/dist/squire.mjs.map
vendored
4
vendors/squire-rte/dist/squire.mjs.map
vendored
File diff suppressed because one or more lines are too long
1
vendors/squire-rte/dist/types/Editor.d.ts
vendored
1
vendors/squire-rte/dist/types/Editor.d.ts
vendored
|
|
@ -163,6 +163,7 @@ declare class Squire {
|
|||
increaseQuoteLevel(range?: Range): Squire;
|
||||
decreaseQuoteLevel(range?: Range): Squire;
|
||||
removeQuote(range?: Range): Squire;
|
||||
replaceWithBlankLine(range?: Range): Squire;
|
||||
code(): Squire;
|
||||
removeCode(): Squire;
|
||||
toggleCode(): Squire;
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
Loading…
Add table
Add a link
Reference in a new issue