mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-27 12:53:13 +03:00
Koenig - Change ~strike~ text expansion to ~~strike~~
refs https://github.com/TryGhost/Ghost/issues/9505
This commit is contained in:
parent
801c73dae6
commit
d54172172d
@ -196,7 +196,7 @@ export default function (editor) {
|
|||||||
|
|
||||||
function matchStrikethrough(editor, text) {
|
function matchStrikethrough(editor, text) {
|
||||||
let {range} = editor;
|
let {range} = editor;
|
||||||
let matches = text.match(/(?:^|\s)~([^\s~]+|[^\s~][^~]*[^\s])~/);
|
let matches = text.match(/(?:^|\s)~~([^\s~]+|[^\s~][^~]*[^\s])~~/);
|
||||||
if (matches) {
|
if (matches) {
|
||||||
let match = matches[0].trim();
|
let match = matches[0].trim();
|
||||||
range = range.extend(-(match.length));
|
range = range.extend(-(match.length));
|
||||||
|
Loading…
Reference in New Issue
Block a user