mirror of
https://github.com/sparksuite/simplemde-markdown-editor.git
synced 2025-07-02 23:54:28 -06:00
Update version and rebuild project
This commit is contained in:
parent
120d7e5c85
commit
f1865e5536
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "simplemde",
|
"name": "simplemde",
|
||||||
"version": "1.9.0",
|
"version": "1.10.0",
|
||||||
"homepage": "https://github.com/NextStepWebs/simplemde-markdown-editor",
|
"homepage": "https://github.com/NextStepWebs/simplemde-markdown-editor",
|
||||||
"authors": [
|
"authors": [
|
||||||
"Wes Cossick"
|
"Wes Cossick"
|
||||||
|
@ -663,6 +663,10 @@ span.CodeMirror-selectedtext { background: none; }
|
|||||||
.CodeMirror .CodeMirror-code .cm-strikethrough {
|
.CodeMirror .CodeMirror-code .cm-strikethrough {
|
||||||
text-decoration: line-through;
|
text-decoration: line-through;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.CodeMirror .CodeMirror-placeholder {
|
||||||
|
opacity: .5;
|
||||||
|
}
|
||||||
.CodeMirror .cm-spell-error:not(.cm-url):not(.cm-comment):not(.cm-tag):not(.cm-word) {
|
.CodeMirror .cm-spell-error:not(.cm-url):not(.cm-comment):not(.cm-tag):not(.cm-word) {
|
||||||
background: rgba(255, 0, 0, .15);
|
background: rgba(255, 0, 0, .15);
|
||||||
}
|
}
|
File diff suppressed because one or more lines are too long
@ -7,7 +7,7 @@
|
|||||||
(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.SimpleMDE = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
|
(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.SimpleMDE = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
|
||||||
(function (global){
|
(function (global){
|
||||||
|
|
||||||
; Typo = global.Typo = require("C:\\Users\\Jamie Wohletz\\Documents\\Code\\simplemde-markdown-editor\\node_modules\\codemirror-spell-checker\\src\\js\\typo.js");
|
; Typo = global.Typo = require("D:\\My Web Sites\\simplemde-markdown-editor\\node_modules\\codemirror-spell-checker\\src\\js\\typo.js");
|
||||||
CodeMirror = global.CodeMirror = require("codemirror");
|
CodeMirror = global.CodeMirror = require("codemirror");
|
||||||
; var __browserify_shim_require__=require;(function browserifyShim(module, define, require) {
|
; var __browserify_shim_require__=require;(function browserifyShim(module, define, require) {
|
||||||
// Initialize data globally to reduce memory consumption
|
// Initialize data globally to reduce memory consumption
|
||||||
@ -105,7 +105,7 @@ if(!String.prototype.includes) {
|
|||||||
}).call(global, module, undefined, undefined);
|
}).call(global, module, undefined, undefined);
|
||||||
|
|
||||||
}).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
|
}).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
|
||||||
},{"C:\\Users\\Jamie Wohletz\\Documents\\Code\\simplemde-markdown-editor\\node_modules\\codemirror-spell-checker\\src\\js\\typo.js":2,"codemirror":7}],2:[function(require,module,exports){
|
},{"D:\\My Web Sites\\simplemde-markdown-editor\\node_modules\\codemirror-spell-checker\\src\\js\\typo.js":2,"codemirror":7}],2:[function(require,module,exports){
|
||||||
(function (global){
|
(function (global){
|
||||||
; var __browserify_shim_require__=require;(function browserifyShim(module, exports, require, define, browserify_shim__define__module__export__) {
|
; var __browserify_shim_require__=require;(function browserifyShim(module, exports, require, define, browserify_shim__define__module__export__) {
|
||||||
'use strict';
|
'use strict';
|
||||||
@ -1140,7 +1140,7 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
else if (typeof define == "function" && define.amd) // AMD
|
else if (typeof define == "function" && define.amd) // AMD
|
||||||
return define([], mod);
|
return define([], mod);
|
||||||
else // Plain browser env
|
else // Plain browser env
|
||||||
(this || window).CodeMirror = mod();
|
this.CodeMirror = mod();
|
||||||
})(function() {
|
})(function() {
|
||||||
"use strict";
|
"use strict";
|
||||||
|
|
||||||
@ -2221,6 +2221,10 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
if (!cm.state.focused) { cm.display.input.focus(); onFocus(cm); }
|
if (!cm.state.focused) { cm.display.input.focus(); onFocus(cm); }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function isReadOnly(cm) {
|
||||||
|
return cm.options.readOnly || cm.doc.cantEdit;
|
||||||
|
}
|
||||||
|
|
||||||
// This will be set to an array of strings when copying, so that,
|
// This will be set to an array of strings when copying, so that,
|
||||||
// when pasting, we know what kind of selections the copied text
|
// when pasting, we know what kind of selections the copied text
|
||||||
// was made out of.
|
// was made out of.
|
||||||
@ -2275,7 +2279,7 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
var pasted = e.clipboardData && e.clipboardData.getData("text/plain");
|
var pasted = e.clipboardData && e.clipboardData.getData("text/plain");
|
||||||
if (pasted) {
|
if (pasted) {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
if (!cm.isReadOnly() && !cm.options.disableInput)
|
if (!isReadOnly(cm) && !cm.options.disableInput)
|
||||||
runInOp(cm, function() { applyTextInput(cm, pasted, 0, null, "paste"); });
|
runInOp(cm, function() { applyTextInput(cm, pasted, 0, null, "paste"); });
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@ -2378,14 +2382,13 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
});
|
});
|
||||||
|
|
||||||
on(te, "paste", function(e) {
|
on(te, "paste", function(e) {
|
||||||
if (signalDOMEvent(cm, e) || handlePaste(e, cm)) return
|
if (handlePaste(e, cm)) return true;
|
||||||
|
|
||||||
cm.state.pasteIncoming = true;
|
cm.state.pasteIncoming = true;
|
||||||
input.fastPoll();
|
input.fastPoll();
|
||||||
});
|
});
|
||||||
|
|
||||||
function prepareCopyCut(e) {
|
function prepareCopyCut(e) {
|
||||||
if (signalDOMEvent(cm, e)) return
|
|
||||||
if (cm.somethingSelected()) {
|
if (cm.somethingSelected()) {
|
||||||
lastCopied = cm.getSelections();
|
lastCopied = cm.getSelections();
|
||||||
if (input.inaccurateSelection) {
|
if (input.inaccurateSelection) {
|
||||||
@ -2413,7 +2416,7 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
on(te, "copy", prepareCopyCut);
|
on(te, "copy", prepareCopyCut);
|
||||||
|
|
||||||
on(display.scroller, "paste", function(e) {
|
on(display.scroller, "paste", function(e) {
|
||||||
if (eventInWidget(display, e) || signalDOMEvent(cm, e)) return;
|
if (eventInWidget(display, e)) return;
|
||||||
cm.state.pasteIncoming = true;
|
cm.state.pasteIncoming = true;
|
||||||
input.focus();
|
input.focus();
|
||||||
});
|
});
|
||||||
@ -2547,7 +2550,7 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
// in which case reading its value would be expensive.
|
// in which case reading its value would be expensive.
|
||||||
if (this.contextMenuPending || !cm.state.focused ||
|
if (this.contextMenuPending || !cm.state.focused ||
|
||||||
(hasSelection(input) && !prevInput && !this.composing) ||
|
(hasSelection(input) && !prevInput && !this.composing) ||
|
||||||
cm.isReadOnly() || cm.options.disableInput || cm.state.keySeq)
|
isReadOnly(cm) || cm.options.disableInput || cm.state.keySeq)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
var text = input.value;
|
var text = input.value;
|
||||||
@ -2698,9 +2701,7 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
var div = input.div = display.lineDiv;
|
var div = input.div = display.lineDiv;
|
||||||
disableBrowserMagic(div);
|
disableBrowserMagic(div);
|
||||||
|
|
||||||
on(div, "paste", function(e) {
|
on(div, "paste", function(e) { handlePaste(e, cm); })
|
||||||
if (!signalDOMEvent(cm, e)) handlePaste(e, cm);
|
|
||||||
})
|
|
||||||
|
|
||||||
on(div, "compositionstart", function(e) {
|
on(div, "compositionstart", function(e) {
|
||||||
var data = e.data;
|
var data = e.data;
|
||||||
@ -2738,12 +2739,11 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
|
|
||||||
on(div, "input", function() {
|
on(div, "input", function() {
|
||||||
if (input.composing) return;
|
if (input.composing) return;
|
||||||
if (cm.isReadOnly() || !input.pollContent())
|
if (isReadOnly(cm) || !input.pollContent())
|
||||||
runInOp(input.cm, function() {regChange(cm);});
|
runInOp(input.cm, function() {regChange(cm);});
|
||||||
});
|
});
|
||||||
|
|
||||||
function onCopyCut(e) {
|
function onCopyCut(e) {
|
||||||
if (signalDOMEvent(cm, e)) return
|
|
||||||
if (cm.somethingSelected()) {
|
if (cm.somethingSelected()) {
|
||||||
lastCopied = cm.getSelections();
|
lastCopied = cm.getSelections();
|
||||||
if (e.type == "cut") cm.replaceSelection("", null, "cut");
|
if (e.type == "cut") cm.replaceSelection("", null, "cut");
|
||||||
@ -2819,13 +2819,8 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
try { var rng = range(start.node, start.offset, end.offset, end.node); }
|
try { var rng = range(start.node, start.offset, end.offset, end.node); }
|
||||||
catch(e) {} // Our model of the DOM might be outdated, in which case the range we try to set can be impossible
|
catch(e) {} // Our model of the DOM might be outdated, in which case the range we try to set can be impossible
|
||||||
if (rng) {
|
if (rng) {
|
||||||
if (!gecko && this.cm.state.focused) {
|
|
||||||
sel.collapse(start.node, start.offset);
|
|
||||||
if (!rng.collapsed) sel.addRange(rng);
|
|
||||||
} else {
|
|
||||||
sel.removeAllRanges();
|
sel.removeAllRanges();
|
||||||
sel.addRange(rng);
|
sel.addRange(rng);
|
||||||
}
|
|
||||||
if (old && sel.anchorNode == null) sel.addRange(old);
|
if (old && sel.anchorNode == null) sel.addRange(old);
|
||||||
else if (gecko) this.startGracePeriod();
|
else if (gecko) this.startGracePeriod();
|
||||||
}
|
}
|
||||||
@ -2969,7 +2964,7 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
this.div.focus();
|
this.div.focus();
|
||||||
},
|
},
|
||||||
applyComposition: function(composing) {
|
applyComposition: function(composing) {
|
||||||
if (this.cm.isReadOnly())
|
if (isReadOnly(this.cm))
|
||||||
operation(this.cm, regChange)(this.cm)
|
operation(this.cm, regChange)(this.cm)
|
||||||
else if (composing.data && composing.data != composing.startData)
|
else if (composing.data && composing.data != composing.startData)
|
||||||
operation(this.cm, applyTextInput)(this.cm, composing.data, 0, composing.sel);
|
operation(this.cm, applyTextInput)(this.cm, composing.data, 0, composing.sel);
|
||||||
@ -2981,7 +2976,7 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
|
|
||||||
onKeyPress: function(e) {
|
onKeyPress: function(e) {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
if (!this.cm.isReadOnly())
|
if (!isReadOnly(this.cm))
|
||||||
operation(this.cm, applyTextInput)(this.cm, String.fromCharCode(e.charCode == null ? e.keyCode : e.charCode), 0);
|
operation(this.cm, applyTextInput)(this.cm, String.fromCharCode(e.charCode == null ? e.keyCode : e.charCode), 0);
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -3286,7 +3281,7 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
|
|
||||||
// Give beforeSelectionChange handlers a change to influence a
|
// Give beforeSelectionChange handlers a change to influence a
|
||||||
// selection update.
|
// selection update.
|
||||||
function filterSelectionChange(doc, sel, options) {
|
function filterSelectionChange(doc, sel) {
|
||||||
var obj = {
|
var obj = {
|
||||||
ranges: sel.ranges,
|
ranges: sel.ranges,
|
||||||
update: function(ranges) {
|
update: function(ranges) {
|
||||||
@ -3294,8 +3289,7 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
for (var i = 0; i < ranges.length; i++)
|
for (var i = 0; i < ranges.length; i++)
|
||||||
this.ranges[i] = new Range(clipPos(doc, ranges[i].anchor),
|
this.ranges[i] = new Range(clipPos(doc, ranges[i].anchor),
|
||||||
clipPos(doc, ranges[i].head));
|
clipPos(doc, ranges[i].head));
|
||||||
},
|
}
|
||||||
origin: options && options.origin
|
|
||||||
};
|
};
|
||||||
signal(doc, "beforeSelectionChange", doc, obj);
|
signal(doc, "beforeSelectionChange", doc, obj);
|
||||||
if (doc.cm) signal(doc.cm, "beforeSelectionChange", doc.cm, obj);
|
if (doc.cm) signal(doc.cm, "beforeSelectionChange", doc.cm, obj);
|
||||||
@ -3321,7 +3315,7 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
|
|
||||||
function setSelectionNoUndo(doc, sel, options) {
|
function setSelectionNoUndo(doc, sel, options) {
|
||||||
if (hasHandler(doc, "beforeSelectionChange") || doc.cm && hasHandler(doc.cm, "beforeSelectionChange"))
|
if (hasHandler(doc, "beforeSelectionChange") || doc.cm && hasHandler(doc.cm, "beforeSelectionChange"))
|
||||||
sel = filterSelectionChange(doc, sel, options);
|
sel = filterSelectionChange(doc, sel);
|
||||||
|
|
||||||
var bias = options && options.bias ||
|
var bias = options && options.bias ||
|
||||||
(cmp(sel.primary().head, doc.sel.primary().head) < 0 ? -1 : 1);
|
(cmp(sel.primary().head, doc.sel.primary().head) < 0 ? -1 : 1);
|
||||||
@ -4747,7 +4741,7 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
var sel = cm.doc.sel, modifier = mac ? e.metaKey : e.ctrlKey, contained;
|
var sel = cm.doc.sel, modifier = mac ? e.metaKey : e.ctrlKey, contained;
|
||||||
if (cm.options.dragDrop && dragAndDrop && !cm.isReadOnly() &&
|
if (cm.options.dragDrop && dragAndDrop && !isReadOnly(cm) &&
|
||||||
type == "single" && (contained = sel.contains(start)) > -1 &&
|
type == "single" && (contained = sel.contains(start)) > -1 &&
|
||||||
(cmp((contained = sel.ranges[contained]).from(), start) < 0 || start.xRel > 0) &&
|
(cmp((contained = sel.ranges[contained]).from(), start) < 0 || start.xRel > 0) &&
|
||||||
(cmp(contained.to(), start) > 0 || start.xRel < 0))
|
(cmp(contained.to(), start) > 0 || start.xRel < 0))
|
||||||
@ -4971,7 +4965,7 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
e_preventDefault(e);
|
e_preventDefault(e);
|
||||||
if (ie) lastDrop = +new Date;
|
if (ie) lastDrop = +new Date;
|
||||||
var pos = posFromMouse(cm, e, true), files = e.dataTransfer.files;
|
var pos = posFromMouse(cm, e, true), files = e.dataTransfer.files;
|
||||||
if (!pos || cm.isReadOnly()) return;
|
if (!pos || isReadOnly(cm)) return;
|
||||||
// Might be a file drop, in which case we simply extract the text
|
// Might be a file drop, in which case we simply extract the text
|
||||||
// and insert it.
|
// and insert it.
|
||||||
if (files && files.length && window.FileReader && window.File) {
|
if (files && files.length && window.FileReader && window.File) {
|
||||||
@ -5210,7 +5204,7 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
cm.display.input.ensurePolled();
|
cm.display.input.ensurePolled();
|
||||||
var prevShift = cm.display.shift, done = false;
|
var prevShift = cm.display.shift, done = false;
|
||||||
try {
|
try {
|
||||||
if (cm.isReadOnly()) cm.state.suppressEdits = true;
|
if (isReadOnly(cm)) cm.state.suppressEdits = true;
|
||||||
if (dropShift) cm.display.shift = false;
|
if (dropShift) cm.display.shift = false;
|
||||||
done = bound(cm) != Pass;
|
done = bound(cm) != Pass;
|
||||||
} finally {
|
} finally {
|
||||||
@ -6371,7 +6365,6 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
signal(this, "overwriteToggle", this, this.state.overwrite);
|
signal(this, "overwriteToggle", this, this.state.overwrite);
|
||||||
},
|
},
|
||||||
hasFocus: function() { return this.display.input.getField() == activeElt(); },
|
hasFocus: function() { return this.display.input.getField() == activeElt(); },
|
||||||
isReadOnly: function() { return !!(this.options.readOnly || this.doc.cantEdit); },
|
|
||||||
|
|
||||||
scrollTo: methodOp(function(x, y) {
|
scrollTo: methodOp(function(x, y) {
|
||||||
if (x != null || y != null) resolveScrollToPos(this);
|
if (x != null || y != null) resolveScrollToPos(this);
|
||||||
@ -8218,7 +8211,7 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
if (nextChange == pos) { // Update current marker set
|
if (nextChange == pos) { // Update current marker set
|
||||||
spanStyle = spanEndStyle = spanStartStyle = title = css = "";
|
spanStyle = spanEndStyle = spanStartStyle = title = css = "";
|
||||||
collapsed = null; nextChange = Infinity;
|
collapsed = null; nextChange = Infinity;
|
||||||
var foundBookmarks = [], endStyles
|
var foundBookmarks = [];
|
||||||
for (var j = 0; j < spans.length; ++j) {
|
for (var j = 0; j < spans.length; ++j) {
|
||||||
var sp = spans[j], m = sp.marker;
|
var sp = spans[j], m = sp.marker;
|
||||||
if (m.type == "bookmark" && sp.from == pos && m.widgetNode) {
|
if (m.type == "bookmark" && sp.from == pos && m.widgetNode) {
|
||||||
@ -8231,7 +8224,7 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
if (m.className) spanStyle += " " + m.className;
|
if (m.className) spanStyle += " " + m.className;
|
||||||
if (m.css) css = (css ? css + ";" : "") + m.css;
|
if (m.css) css = (css ? css + ";" : "") + m.css;
|
||||||
if (m.startStyle && sp.from == pos) spanStartStyle += " " + m.startStyle;
|
if (m.startStyle && sp.from == pos) spanStartStyle += " " + m.startStyle;
|
||||||
if (m.endStyle && sp.to == nextChange) (endStyles || (endStyles = [])).push(m.endStyle, sp.to)
|
if (m.endStyle && sp.to == nextChange) spanEndStyle += " " + m.endStyle;
|
||||||
if (m.title && !title) title = m.title;
|
if (m.title && !title) title = m.title;
|
||||||
if (m.collapsed && (!collapsed || compareCollapsedMarkers(collapsed.marker, m) < 0))
|
if (m.collapsed && (!collapsed || compareCollapsedMarkers(collapsed.marker, m) < 0))
|
||||||
collapsed = sp;
|
collapsed = sp;
|
||||||
@ -8239,9 +8232,6 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
nextChange = sp.from;
|
nextChange = sp.from;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (endStyles) for (var j = 0; j < endStyles.length; j += 2)
|
|
||||||
if (endStyles[j + 1] == nextChange) spanEndStyle += " " + endStyles[j]
|
|
||||||
|
|
||||||
if (collapsed && (collapsed.from || 0) == pos) {
|
if (collapsed && (collapsed.from || 0) == pos) {
|
||||||
buildCollapsedSpan(builder, (collapsed.to == null ? len + 1 : collapsed.to) - pos,
|
buildCollapsedSpan(builder, (collapsed.to == null ? len + 1 : collapsed.to) - pos,
|
||||||
collapsed.marker, collapsed.from == null);
|
collapsed.marker, collapsed.from == null);
|
||||||
@ -8589,11 +8579,10 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
extendSelection(this, clipPos(this, head), other && clipPos(this, other), options);
|
extendSelection(this, clipPos(this, head), other && clipPos(this, other), options);
|
||||||
}),
|
}),
|
||||||
extendSelections: docMethodOp(function(heads, options) {
|
extendSelections: docMethodOp(function(heads, options) {
|
||||||
extendSelections(this, clipPosArray(this, heads), options);
|
extendSelections(this, clipPosArray(this, heads, options));
|
||||||
}),
|
}),
|
||||||
extendSelectionsBy: docMethodOp(function(f, options) {
|
extendSelectionsBy: docMethodOp(function(f, options) {
|
||||||
var heads = map(this.sel.ranges, f);
|
extendSelections(this, map(this.sel.ranges, f), options);
|
||||||
extendSelections(this, clipPosArray(this, heads), options);
|
|
||||||
}),
|
}),
|
||||||
setSelections: docMethodOp(function(ranges, primary, options) {
|
setSelections: docMethodOp(function(ranges, primary, options) {
|
||||||
if (!ranges.length) return;
|
if (!ranges.length) return;
|
||||||
@ -10010,7 +9999,7 @@ CodeMirror.overlayMode = function(base, overlay, combine) {
|
|||||||
|
|
||||||
// THE END
|
// THE END
|
||||||
|
|
||||||
CodeMirror.version = "5.10.1";
|
CodeMirror.version = "5.9.1";
|
||||||
|
|
||||||
return CodeMirror;
|
return CodeMirror;
|
||||||
});
|
});
|
||||||
@ -10770,7 +10759,7 @@ CodeMirror.defineMode("markdown", function(cmCfg, modeCfg) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function footnoteLink(stream, state) {
|
function footnoteLink(stream, state) {
|
||||||
if (stream.match(/^([^\]\\]|\\.)*\]:/, false)) {
|
if (stream.match(/^[^\]]*\]:/, false)) {
|
||||||
state.f = footnoteLinkInside;
|
state.f = footnoteLinkInside;
|
||||||
stream.next(); // Consume [
|
stream.next(); // Consume [
|
||||||
if (modeCfg.highlightFormatting) state.formatting = "link";
|
if (modeCfg.highlightFormatting) state.formatting = "link";
|
||||||
@ -10789,7 +10778,7 @@ CodeMirror.defineMode("markdown", function(cmCfg, modeCfg) {
|
|||||||
return returnType;
|
return returnType;
|
||||||
}
|
}
|
||||||
|
|
||||||
stream.match(/^([^\]\\]|\\.)+/, true);
|
stream.match(/^[^\]]+/, true);
|
||||||
|
|
||||||
return tokenTypes.linkText;
|
return tokenTypes.linkText;
|
||||||
}
|
}
|
||||||
@ -10983,7 +10972,6 @@ CodeMirror.defineMIME("text/x-markdown", "markdown");
|
|||||||
{name: "Common Lisp", mime: "text/x-common-lisp", mode: "commonlisp", ext: ["cl", "lisp", "el"], alias: ["lisp"]},
|
{name: "Common Lisp", mime: "text/x-common-lisp", mode: "commonlisp", ext: ["cl", "lisp", "el"], alias: ["lisp"]},
|
||||||
{name: "Cypher", mime: "application/x-cypher-query", mode: "cypher", ext: ["cyp", "cypher"]},
|
{name: "Cypher", mime: "application/x-cypher-query", mode: "cypher", ext: ["cyp", "cypher"]},
|
||||||
{name: "Cython", mime: "text/x-cython", mode: "python", ext: ["pyx", "pxd", "pxi"]},
|
{name: "Cython", mime: "text/x-cython", mode: "python", ext: ["pyx", "pxd", "pxi"]},
|
||||||
{name: "Crystal", mime: "text/x-crystal", mode: "crystal", ext: ["cr"]},
|
|
||||||
{name: "CSS", mime: "text/css", mode: "css", ext: ["css"]},
|
{name: "CSS", mime: "text/css", mode: "css", ext: ["css"]},
|
||||||
{name: "CQL", mime: "text/x-cassandra", mode: "sql", ext: ["cql"]},
|
{name: "CQL", mime: "text/x-cassandra", mode: "sql", ext: ["cql"]},
|
||||||
{name: "D", mime: "text/x-d", mode: "d", ext: ["d"]},
|
{name: "D", mime: "text/x-d", mode: "d", ext: ["d"]},
|
||||||
@ -11011,7 +10999,6 @@ CodeMirror.defineMIME("text/x-markdown", "markdown");
|
|||||||
{name: "Groovy", mime: "text/x-groovy", mode: "groovy", ext: ["groovy"]},
|
{name: "Groovy", mime: "text/x-groovy", mode: "groovy", ext: ["groovy"]},
|
||||||
{name: "HAML", mime: "text/x-haml", mode: "haml", ext: ["haml"]},
|
{name: "HAML", mime: "text/x-haml", mode: "haml", ext: ["haml"]},
|
||||||
{name: "Haskell", mime: "text/x-haskell", mode: "haskell", ext: ["hs"]},
|
{name: "Haskell", mime: "text/x-haskell", mode: "haskell", ext: ["hs"]},
|
||||||
{name: "Haskell (Literate)", mime: "text/x-literate-haskell", mode: "haskell-literate", ext: ["lhs"]},
|
|
||||||
{name: "Haxe", mime: "text/x-haxe", mode: "haxe", ext: ["hx"]},
|
{name: "Haxe", mime: "text/x-haxe", mode: "haxe", ext: ["hx"]},
|
||||||
{name: "HXML", mime: "text/x-hxml", mode: "haxe", ext: ["hxml"]},
|
{name: "HXML", mime: "text/x-hxml", mode: "haxe", ext: ["hxml"]},
|
||||||
{name: "ASP.NET", mime: "application/x-aspx", mode: "htmlembedded", ext: ["aspx"], alias: ["asp", "aspx"]},
|
{name: "ASP.NET", mime: "application/x-aspx", mode: "htmlembedded", ext: ["aspx"], alias: ["asp", "aspx"]},
|
||||||
@ -11025,7 +11012,6 @@ CodeMirror.defineMIME("text/x-markdown", "markdown");
|
|||||||
mode: "javascript", ext: ["js"], alias: ["ecmascript", "js", "node"]},
|
mode: "javascript", ext: ["js"], alias: ["ecmascript", "js", "node"]},
|
||||||
{name: "JSON", mimes: ["application/json", "application/x-json"], mode: "javascript", ext: ["json", "map"], alias: ["json5"]},
|
{name: "JSON", mimes: ["application/json", "application/x-json"], mode: "javascript", ext: ["json", "map"], alias: ["json5"]},
|
||||||
{name: "JSON-LD", mime: "application/ld+json", mode: "javascript", ext: ["jsonld"], alias: ["jsonld"]},
|
{name: "JSON-LD", mime: "application/ld+json", mode: "javascript", ext: ["jsonld"], alias: ["jsonld"]},
|
||||||
{name: "JSX", mime: "text/jsx", mode: "jsx", ext: ["jsx"]},
|
|
||||||
{name: "Jinja2", mime: "null", mode: "jinja2"},
|
{name: "Jinja2", mime: "null", mode: "jinja2"},
|
||||||
{name: "Julia", mime: "text/x-julia", mode: "julia", ext: ["jl"]},
|
{name: "Julia", mime: "text/x-julia", mode: "julia", ext: ["jl"]},
|
||||||
{name: "Kotlin", mime: "text/x-kotlin", mode: "clike", ext: ["kt"]},
|
{name: "Kotlin", mime: "text/x-kotlin", mode: "clike", ext: ["kt"]},
|
||||||
@ -11168,7 +11154,13 @@ CodeMirror.defineMIME("text/x-markdown", "markdown");
|
|||||||
})(function(CodeMirror) {
|
})(function(CodeMirror) {
|
||||||
"use strict";
|
"use strict";
|
||||||
|
|
||||||
var htmlConfig = {
|
CodeMirror.defineMode("xml", function(config, parserConfig) {
|
||||||
|
var indentUnit = config.indentUnit;
|
||||||
|
var multilineTagIndentFactor = parserConfig.multilineTagIndentFactor || 1;
|
||||||
|
var multilineTagIndentPastTag = parserConfig.multilineTagIndentPastTag;
|
||||||
|
if (multilineTagIndentPastTag == null) multilineTagIndentPastTag = true;
|
||||||
|
|
||||||
|
var Kludges = parserConfig.htmlMode ? {
|
||||||
autoSelfClosers: {'area': true, 'base': true, 'br': true, 'col': true, 'command': true,
|
autoSelfClosers: {'area': true, 'base': true, 'br': true, 'col': true, 'command': true,
|
||||||
'embed': true, 'frame': true, 'hr': true, 'img': true, 'input': true,
|
'embed': true, 'frame': true, 'hr': true, 'img': true, 'input': true,
|
||||||
'keygen': true, 'link': true, 'meta': true, 'param': true, 'source': true,
|
'keygen': true, 'link': true, 'meta': true, 'param': true, 'source': true,
|
||||||
@ -11200,9 +11192,7 @@ var htmlConfig = {
|
|||||||
allowUnquoted: true,
|
allowUnquoted: true,
|
||||||
allowMissing: true,
|
allowMissing: true,
|
||||||
caseFold: true
|
caseFold: true
|
||||||
}
|
} : {
|
||||||
|
|
||||||
var xmlConfig = {
|
|
||||||
autoSelfClosers: {},
|
autoSelfClosers: {},
|
||||||
implicitlyClosed: {},
|
implicitlyClosed: {},
|
||||||
contextGrabbers: {},
|
contextGrabbers: {},
|
||||||
@ -11210,14 +11200,8 @@ var xmlConfig = {
|
|||||||
allowUnquoted: false,
|
allowUnquoted: false,
|
||||||
allowMissing: false,
|
allowMissing: false,
|
||||||
caseFold: false
|
caseFold: false
|
||||||
}
|
};
|
||||||
|
var alignCDATA = parserConfig.alignCDATA;
|
||||||
CodeMirror.defineMode("xml", function(editorConf, config_) {
|
|
||||||
var indentUnit = editorConf.indentUnit
|
|
||||||
var config = {}
|
|
||||||
var defaults = config_.htmlMode ? htmlConfig : xmlConfig
|
|
||||||
for (var prop in defaults) config[prop] = defaults[prop]
|
|
||||||
for (var prop in config_) config[prop] = config_[prop]
|
|
||||||
|
|
||||||
// Return variables for tokenizers
|
// Return variables for tokenizers
|
||||||
var type, setStyle;
|
var type, setStyle;
|
||||||
@ -11347,7 +11331,7 @@ CodeMirror.defineMode("xml", function(editorConf, config_) {
|
|||||||
this.tagName = tagName;
|
this.tagName = tagName;
|
||||||
this.indent = state.indented;
|
this.indent = state.indented;
|
||||||
this.startOfLine = startOfLine;
|
this.startOfLine = startOfLine;
|
||||||
if (config.doNotIndent.hasOwnProperty(tagName) || (state.context && state.context.noIndent))
|
if (Kludges.doNotIndent.hasOwnProperty(tagName) || (state.context && state.context.noIndent))
|
||||||
this.noIndent = true;
|
this.noIndent = true;
|
||||||
}
|
}
|
||||||
function popContext(state) {
|
function popContext(state) {
|
||||||
@ -11360,8 +11344,8 @@ CodeMirror.defineMode("xml", function(editorConf, config_) {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
parentTagName = state.context.tagName;
|
parentTagName = state.context.tagName;
|
||||||
if (!config.contextGrabbers.hasOwnProperty(parentTagName) ||
|
if (!Kludges.contextGrabbers.hasOwnProperty(parentTagName) ||
|
||||||
!config.contextGrabbers[parentTagName].hasOwnProperty(nextTagName)) {
|
!Kludges.contextGrabbers[parentTagName].hasOwnProperty(nextTagName)) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
popContext(state);
|
popContext(state);
|
||||||
@ -11392,7 +11376,7 @@ CodeMirror.defineMode("xml", function(editorConf, config_) {
|
|||||||
if (type == "word") {
|
if (type == "word") {
|
||||||
var tagName = stream.current();
|
var tagName = stream.current();
|
||||||
if (state.context && state.context.tagName != tagName &&
|
if (state.context && state.context.tagName != tagName &&
|
||||||
config.implicitlyClosed.hasOwnProperty(state.context.tagName))
|
Kludges.implicitlyClosed.hasOwnProperty(state.context.tagName))
|
||||||
popContext(state);
|
popContext(state);
|
||||||
if (state.context && state.context.tagName == tagName) {
|
if (state.context && state.context.tagName == tagName) {
|
||||||
setStyle = "tag";
|
setStyle = "tag";
|
||||||
@ -11428,7 +11412,7 @@ CodeMirror.defineMode("xml", function(editorConf, config_) {
|
|||||||
var tagName = state.tagName, tagStart = state.tagStart;
|
var tagName = state.tagName, tagStart = state.tagStart;
|
||||||
state.tagName = state.tagStart = null;
|
state.tagName = state.tagStart = null;
|
||||||
if (type == "selfcloseTag" ||
|
if (type == "selfcloseTag" ||
|
||||||
config.autoSelfClosers.hasOwnProperty(tagName)) {
|
Kludges.autoSelfClosers.hasOwnProperty(tagName)) {
|
||||||
maybePopContext(state, tagName);
|
maybePopContext(state, tagName);
|
||||||
} else {
|
} else {
|
||||||
maybePopContext(state, tagName);
|
maybePopContext(state, tagName);
|
||||||
@ -11441,12 +11425,12 @@ CodeMirror.defineMode("xml", function(editorConf, config_) {
|
|||||||
}
|
}
|
||||||
function attrEqState(type, stream, state) {
|
function attrEqState(type, stream, state) {
|
||||||
if (type == "equals") return attrValueState;
|
if (type == "equals") return attrValueState;
|
||||||
if (!config.allowMissing) setStyle = "error";
|
if (!Kludges.allowMissing) setStyle = "error";
|
||||||
return attrState(type, stream, state);
|
return attrState(type, stream, state);
|
||||||
}
|
}
|
||||||
function attrValueState(type, stream, state) {
|
function attrValueState(type, stream, state) {
|
||||||
if (type == "string") return attrContinuedState;
|
if (type == "string") return attrContinuedState;
|
||||||
if (type == "word" && config.allowUnquoted) {setStyle = "string"; return attrState;}
|
if (type == "word" && Kludges.allowUnquoted) {setStyle = "string"; return attrState;}
|
||||||
setStyle = "error";
|
setStyle = "error";
|
||||||
return attrState(type, stream, state);
|
return attrState(type, stream, state);
|
||||||
}
|
}
|
||||||
@ -11456,14 +11440,12 @@ CodeMirror.defineMode("xml", function(editorConf, config_) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
return {
|
return {
|
||||||
startState: function(baseIndent) {
|
startState: function() {
|
||||||
var state = {tokenize: inText,
|
return {tokenize: inText,
|
||||||
state: baseState,
|
state: baseState,
|
||||||
indented: baseIndent || 0,
|
indented: 0,
|
||||||
tagName: null, tagStart: null,
|
tagName: null, tagStart: null,
|
||||||
context: null}
|
context: null};
|
||||||
if (baseIndent != null) state.baseIndent = baseIndent
|
|
||||||
return state
|
|
||||||
},
|
},
|
||||||
|
|
||||||
token: function(stream, state) {
|
token: function(stream, state) {
|
||||||
@ -11496,19 +11478,19 @@ CodeMirror.defineMode("xml", function(editorConf, config_) {
|
|||||||
return fullLine ? fullLine.match(/^(\s*)/)[0].length : 0;
|
return fullLine ? fullLine.match(/^(\s*)/)[0].length : 0;
|
||||||
// Indent the starts of attribute names.
|
// Indent the starts of attribute names.
|
||||||
if (state.tagName) {
|
if (state.tagName) {
|
||||||
if (config.multilineTagIndentPastTag !== false)
|
if (multilineTagIndentPastTag)
|
||||||
return state.tagStart + state.tagName.length + 2;
|
return state.tagStart + state.tagName.length + 2;
|
||||||
else
|
else
|
||||||
return state.tagStart + indentUnit * (config.multilineTagIndentFactor || 1);
|
return state.tagStart + indentUnit * multilineTagIndentFactor;
|
||||||
}
|
}
|
||||||
if (config.alignCDATA && /<!\[CDATA\[/.test(textAfter)) return 0;
|
if (alignCDATA && /<!\[CDATA\[/.test(textAfter)) return 0;
|
||||||
var tagAfter = textAfter && /^<(\/)?([\w_:\.-]*)/.exec(textAfter);
|
var tagAfter = textAfter && /^<(\/)?([\w_:\.-]*)/.exec(textAfter);
|
||||||
if (tagAfter && tagAfter[1]) { // Closing tag spotted
|
if (tagAfter && tagAfter[1]) { // Closing tag spotted
|
||||||
while (context) {
|
while (context) {
|
||||||
if (context.tagName == tagAfter[2]) {
|
if (context.tagName == tagAfter[2]) {
|
||||||
context = context.prev;
|
context = context.prev;
|
||||||
break;
|
break;
|
||||||
} else if (config.implicitlyClosed.hasOwnProperty(context.tagName)) {
|
} else if (Kludges.implicitlyClosed.hasOwnProperty(context.tagName)) {
|
||||||
context = context.prev;
|
context = context.prev;
|
||||||
} else {
|
} else {
|
||||||
break;
|
break;
|
||||||
@ -11516,30 +11498,25 @@ CodeMirror.defineMode("xml", function(editorConf, config_) {
|
|||||||
}
|
}
|
||||||
} else if (tagAfter) { // Opening tag spotted
|
} else if (tagAfter) { // Opening tag spotted
|
||||||
while (context) {
|
while (context) {
|
||||||
var grabbers = config.contextGrabbers[context.tagName];
|
var grabbers = Kludges.contextGrabbers[context.tagName];
|
||||||
if (grabbers && grabbers.hasOwnProperty(tagAfter[2]))
|
if (grabbers && grabbers.hasOwnProperty(tagAfter[2]))
|
||||||
context = context.prev;
|
context = context.prev;
|
||||||
else
|
else
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
while (context && context.prev && !context.startOfLine)
|
while (context && !context.startOfLine)
|
||||||
context = context.prev;
|
context = context.prev;
|
||||||
if (context) return context.indent + indentUnit;
|
if (context) return context.indent + indentUnit;
|
||||||
else return state.baseIndent || 0;
|
else return 0;
|
||||||
},
|
},
|
||||||
|
|
||||||
electricInput: /<\/[\s\w:]+>$/,
|
electricInput: /<\/[\s\w:]+>$/,
|
||||||
blockCommentStart: "<!--",
|
blockCommentStart: "<!--",
|
||||||
blockCommentEnd: "-->",
|
blockCommentEnd: "-->",
|
||||||
|
|
||||||
configuration: config.htmlMode ? "html" : "xml",
|
configuration: parserConfig.htmlMode ? "html" : "xml",
|
||||||
helperType: config.htmlMode ? "html" : "xml",
|
helperType: parserConfig.htmlMode ? "html" : "xml"
|
||||||
|
|
||||||
skipAttribute: function(state) {
|
|
||||||
if (state.state == attrValueState)
|
|
||||||
state.state = attrState
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -12904,18 +12881,56 @@ var marked = require("marked");
|
|||||||
// Some variables
|
// Some variables
|
||||||
var isMac = /Mac/.test(navigator.platform);
|
var isMac = /Mac/.test(navigator.platform);
|
||||||
|
|
||||||
|
// Mapping of actions that can be bound to keyboard shortcuts or toolbar buttons
|
||||||
|
var bindings = {
|
||||||
|
"toggleBold": toggleBold,
|
||||||
|
"toggleItalic": toggleItalic,
|
||||||
|
"drawLink": drawLink,
|
||||||
|
"toggleHeadingSmaller": toggleHeadingSmaller,
|
||||||
|
"toggleHeadingBigger": toggleHeadingBigger,
|
||||||
|
"drawImage": drawImage,
|
||||||
|
"toggleBlockquote": toggleBlockquote,
|
||||||
|
"toggleOrderedList": toggleOrderedList,
|
||||||
|
"toggleUnorderedList": toggleUnorderedList,
|
||||||
|
"toggleCodeBlock": toggleCodeBlock,
|
||||||
|
"togglePreview": togglePreview,
|
||||||
|
"toggleStrikethrough": toggleStrikethrough,
|
||||||
|
"toggleHeading1": toggleHeading1,
|
||||||
|
"toggleHeading2": toggleHeading2,
|
||||||
|
"toggleHeading3": toggleHeading3,
|
||||||
|
"cleanBlock": cleanBlock,
|
||||||
|
"drawTable": drawTable,
|
||||||
|
"drawHorizontalRule": drawHorizontalRule,
|
||||||
|
"undo": undo,
|
||||||
|
"redo": redo,
|
||||||
|
"toggleSideBySide": toggleSideBySide,
|
||||||
|
"toggleFullScreen": toggleFullScreen
|
||||||
|
};
|
||||||
|
|
||||||
var shortcuts = {
|
var shortcuts = {
|
||||||
"Cmd-B": toggleBold,
|
"toggleBold": "Cmd-B",
|
||||||
"Cmd-I": toggleItalic,
|
"toggleItalic": "Cmd-I",
|
||||||
"Cmd-K": drawLink,
|
"drawLink": "Cmd-K",
|
||||||
"Cmd-H": toggleHeadingSmaller,
|
"toggleHeadingSmaller": "Cmd-H",
|
||||||
"Shift-Cmd-H": toggleHeadingBigger,
|
"toggleHeadingBigger": "Shift-Cmd-H",
|
||||||
"Cmd-Alt-I": drawImage,
|
"cleanBlock": "Cmd-E",
|
||||||
"Cmd-'": toggleBlockquote,
|
"drawImage": "Cmd-Alt-I",
|
||||||
"Cmd-Alt-L": toggleOrderedList,
|
"toggleBlockquote": "Cmd-'",
|
||||||
"Cmd-L": toggleUnorderedList,
|
"toggleOrderedList": "Cmd-Alt-L",
|
||||||
"Cmd-Alt-C": toggleCodeBlock,
|
"toggleUnorderedList": "Cmd-L",
|
||||||
"Cmd-P": togglePreview
|
"toggleCodeBlock": "Cmd-Alt-C",
|
||||||
|
"togglePreview": "Cmd-P",
|
||||||
|
"toggleSideBySide": "F9",
|
||||||
|
"toggleFullScreen": "F11"
|
||||||
|
};
|
||||||
|
|
||||||
|
var getBindingName = function(f) {
|
||||||
|
for(var key in bindings) {
|
||||||
|
if(bindings[key] === f) {
|
||||||
|
return key;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return null;
|
||||||
};
|
};
|
||||||
|
|
||||||
var isMobile = function() {
|
var isMobile = function() {
|
||||||
@ -12943,13 +12958,13 @@ function fixShortcut(name) {
|
|||||||
/**
|
/**
|
||||||
* Create icon element for toolbar.
|
* Create icon element for toolbar.
|
||||||
*/
|
*/
|
||||||
function createIcon(options, enableTooltips) {
|
function createIcon(options, enableTooltips, shortcuts) {
|
||||||
options = options || {};
|
options = options || {};
|
||||||
var el = document.createElement("a");
|
var el = document.createElement("a");
|
||||||
enableTooltips = (enableTooltips == undefined) ? true : enableTooltips;
|
enableTooltips = (enableTooltips == undefined) ? true : enableTooltips;
|
||||||
|
|
||||||
if(options.title && enableTooltips) {
|
if(options.title && enableTooltips) {
|
||||||
el.title = options.title;
|
el.title = createTootlip(options.title, options.action, shortcuts);
|
||||||
|
|
||||||
if(isMac) {
|
if(isMac) {
|
||||||
el.title = el.title.replace("Ctrl", "⌘");
|
el.title = el.title.replace("Ctrl", "⌘");
|
||||||
@ -12969,6 +12984,19 @@ function createSep() {
|
|||||||
return el;
|
return el;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function createTootlip(title, action, shortcuts) {
|
||||||
|
var actionName;
|
||||||
|
var tooltip = title;
|
||||||
|
|
||||||
|
if(action) {
|
||||||
|
actionName = getBindingName(action);
|
||||||
|
if(shortcuts[actionName]) {
|
||||||
|
tooltip += " (" + fixShortcut(shortcuts[actionName]) + ")";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return tooltip;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The state of CodeMirror at the given position.
|
* The state of CodeMirror at the given position.
|
||||||
@ -13003,6 +13031,12 @@ function getState(cm, pos) {
|
|||||||
ret.strikethrough = true;
|
ret.strikethrough = true;
|
||||||
} else if(data === "comment") {
|
} else if(data === "comment") {
|
||||||
ret.code = true;
|
ret.code = true;
|
||||||
|
} else if(data === "link") {
|
||||||
|
ret.link = true;
|
||||||
|
} else if(data === "tag") {
|
||||||
|
ret.image = true;
|
||||||
|
} else if(data.match(/^header(\-[1-6])?$/)) {
|
||||||
|
ret[data.replace("header", "heading")] = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return ret;
|
return ret;
|
||||||
@ -13153,6 +13187,14 @@ function toggleOrderedList(editor) {
|
|||||||
_toggleLine(cm, "ordered-list");
|
_toggleLine(cm, "ordered-list");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Action for clean block (remove headline, list, blockquote code, markers)
|
||||||
|
*/
|
||||||
|
function cleanBlock(editor) {
|
||||||
|
var cm = editor.codemirror;
|
||||||
|
_cleanBlock(cm);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Action for drawing a link.
|
* Action for drawing a link.
|
||||||
*/
|
*/
|
||||||
@ -13517,6 +13559,28 @@ function _toggleBlock(editor, type, start_chars, end_chars) {
|
|||||||
cm.focus();
|
cm.focus();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function _cleanBlock(cm) {
|
||||||
|
if(/editor-preview-active/.test(cm.getWrapperElement().lastChild.className))
|
||||||
|
return;
|
||||||
|
|
||||||
|
var startPoint = cm.getCursor("start");
|
||||||
|
var endPoint = cm.getCursor("end");
|
||||||
|
var text;
|
||||||
|
|
||||||
|
for(var line = startPoint.line; line <= endPoint.line; line++) {
|
||||||
|
text = cm.getLine(line);
|
||||||
|
text = text.replace(/^[ ]*([# ]+|\*|\-|[> ]+|[0-9]+(.|\)))[ ]*/, "");
|
||||||
|
|
||||||
|
cm.replaceRange(text, {
|
||||||
|
line: line,
|
||||||
|
ch: 0
|
||||||
|
}, {
|
||||||
|
line: line,
|
||||||
|
ch: 99999999999999
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Merge the properties of one object into another.
|
// Merge the properties of one object into another.
|
||||||
function _mergeProperties(target, source) {
|
function _mergeProperties(target, source) {
|
||||||
for(var property in source) {
|
for(var property in source) {
|
||||||
@ -13568,14 +13632,14 @@ var toolbarBuiltInButtons = {
|
|||||||
name: "bold",
|
name: "bold",
|
||||||
action: toggleBold,
|
action: toggleBold,
|
||||||
className: "fa fa-bold",
|
className: "fa fa-bold",
|
||||||
title: "Bold (Ctrl+B)",
|
title: "Bold",
|
||||||
default: true
|
default: true
|
||||||
},
|
},
|
||||||
"italic": {
|
"italic": {
|
||||||
name: "italic",
|
name: "italic",
|
||||||
action: toggleItalic,
|
action: toggleItalic,
|
||||||
className: "fa fa-italic",
|
className: "fa fa-italic",
|
||||||
title: "Italic (Ctrl+I)",
|
title: "Italic",
|
||||||
default: true
|
default: true
|
||||||
},
|
},
|
||||||
"strikethrough": {
|
"strikethrough": {
|
||||||
@ -13588,20 +13652,20 @@ var toolbarBuiltInButtons = {
|
|||||||
name: "heading",
|
name: "heading",
|
||||||
action: toggleHeadingSmaller,
|
action: toggleHeadingSmaller,
|
||||||
className: "fa fa-header",
|
className: "fa fa-header",
|
||||||
title: "Heading (Ctrl+H)",
|
title: "Heading",
|
||||||
default: true
|
default: true
|
||||||
},
|
},
|
||||||
"heading-smaller": {
|
"heading-smaller": {
|
||||||
name: "heading-smaller",
|
name: "heading-smaller",
|
||||||
action: toggleHeadingSmaller,
|
action: toggleHeadingSmaller,
|
||||||
className: "fa fa-header fa-header-x fa-header-smaller",
|
className: "fa fa-header fa-header-x fa-header-smaller",
|
||||||
title: "Smaller Heading (Ctrl+H)"
|
title: "Smaller Heading"
|
||||||
},
|
},
|
||||||
"heading-bigger": {
|
"heading-bigger": {
|
||||||
name: "heading-bigger",
|
name: "heading-bigger",
|
||||||
action: toggleHeadingBigger,
|
action: toggleHeadingBigger,
|
||||||
className: "fa fa-header fa-header-x fa-header-bigger",
|
className: "fa fa-header fa-header-x fa-header-bigger",
|
||||||
title: "Bigger Heading (Shift+Ctrl+H)"
|
title: "Bigger Heading"
|
||||||
},
|
},
|
||||||
"heading-1": {
|
"heading-1": {
|
||||||
name: "heading-1",
|
name: "heading-1",
|
||||||
@ -13628,29 +13692,35 @@ var toolbarBuiltInButtons = {
|
|||||||
name: "code",
|
name: "code",
|
||||||
action: toggleCodeBlock,
|
action: toggleCodeBlock,
|
||||||
className: "fa fa-code",
|
className: "fa fa-code",
|
||||||
title: "Code (Ctrl+Alt+C)"
|
title: "Code"
|
||||||
},
|
},
|
||||||
"quote": {
|
"quote": {
|
||||||
name: "quote",
|
name: "quote",
|
||||||
action: toggleBlockquote,
|
action: toggleBlockquote,
|
||||||
className: "fa fa-quote-left",
|
className: "fa fa-quote-left",
|
||||||
title: "Quote (Ctrl+')",
|
title: "Quote",
|
||||||
default: true
|
default: true
|
||||||
},
|
},
|
||||||
"unordered-list": {
|
"unordered-list": {
|
||||||
name: "unordered-list",
|
name: "unordered-list",
|
||||||
action: toggleUnorderedList,
|
action: toggleUnorderedList,
|
||||||
className: "fa fa-list-ul",
|
className: "fa fa-list-ul",
|
||||||
title: "Generic List (Ctrl+L)",
|
title: "Generic List",
|
||||||
default: true
|
default: true
|
||||||
},
|
},
|
||||||
"ordered-list": {
|
"ordered-list": {
|
||||||
name: "ordered-list",
|
name: "ordered-list",
|
||||||
action: toggleOrderedList,
|
action: toggleOrderedList,
|
||||||
className: "fa fa-list-ol",
|
className: "fa fa-list-ol",
|
||||||
title: "Numbered List (Ctrl+Alt+L)",
|
title: "Numbered List",
|
||||||
default: true
|
default: true
|
||||||
},
|
},
|
||||||
|
"clean-block": {
|
||||||
|
name: "clean-block",
|
||||||
|
action: cleanBlock,
|
||||||
|
className: "fa fa-eraser fa-clean-block",
|
||||||
|
title: "Clean block"
|
||||||
|
},
|
||||||
"separator-2": {
|
"separator-2": {
|
||||||
name: "separator-2"
|
name: "separator-2"
|
||||||
},
|
},
|
||||||
@ -13658,14 +13728,14 @@ var toolbarBuiltInButtons = {
|
|||||||
name: "link",
|
name: "link",
|
||||||
action: drawLink,
|
action: drawLink,
|
||||||
className: "fa fa-link",
|
className: "fa fa-link",
|
||||||
title: "Create Link (Ctrl+K)",
|
title: "Create Link",
|
||||||
default: true
|
default: true
|
||||||
},
|
},
|
||||||
"image": {
|
"image": {
|
||||||
name: "image",
|
name: "image",
|
||||||
action: drawImage,
|
action: drawImage,
|
||||||
className: "fa fa-picture-o",
|
className: "fa fa-picture-o",
|
||||||
title: "Insert Image (Ctrl+Alt+I)",
|
title: "Insert Image",
|
||||||
default: true
|
default: true
|
||||||
},
|
},
|
||||||
"table": {
|
"table": {
|
||||||
@ -13687,21 +13757,21 @@ var toolbarBuiltInButtons = {
|
|||||||
name: "preview",
|
name: "preview",
|
||||||
action: togglePreview,
|
action: togglePreview,
|
||||||
className: "fa fa-eye no-disable",
|
className: "fa fa-eye no-disable",
|
||||||
title: "Toggle Preview (Ctrl+P)",
|
title: "Toggle Preview",
|
||||||
default: true
|
default: true
|
||||||
},
|
},
|
||||||
"side-by-side": {
|
"side-by-side": {
|
||||||
name: "side-by-side",
|
name: "side-by-side",
|
||||||
action: toggleSideBySide,
|
action: toggleSideBySide,
|
||||||
className: "fa fa-columns no-disable no-mobile",
|
className: "fa fa-columns no-disable no-mobile",
|
||||||
title: "Toggle Side by Side (F9)",
|
title: "Toggle Side by Side",
|
||||||
default: true
|
default: true
|
||||||
},
|
},
|
||||||
"fullscreen": {
|
"fullscreen": {
|
||||||
name: "fullscreen",
|
name: "fullscreen",
|
||||||
action: toggleFullScreen,
|
action: toggleFullScreen,
|
||||||
className: "fa fa-arrows-alt no-disable no-mobile",
|
className: "fa fa-arrows-alt no-disable no-mobile",
|
||||||
title: "Toggle Fullscreen (F11)",
|
title: "Toggle Fullscreen",
|
||||||
default: true
|
default: true
|
||||||
},
|
},
|
||||||
"guide": {
|
"guide": {
|
||||||
@ -13718,15 +13788,13 @@ var toolbarBuiltInButtons = {
|
|||||||
name: "undo",
|
name: "undo",
|
||||||
action: undo,
|
action: undo,
|
||||||
className: "fa fa-undo no-disable",
|
className: "fa fa-undo no-disable",
|
||||||
title: "Undo",
|
title: "Undo"
|
||||||
default: true
|
|
||||||
},
|
},
|
||||||
"redo": {
|
"redo": {
|
||||||
name: "redo",
|
name: "redo",
|
||||||
action: redo,
|
action: redo,
|
||||||
className: "fa fa-repeat no-disable",
|
className: "fa fa-repeat no-disable",
|
||||||
title: "Redo",
|
title: "Redo"
|
||||||
default: true
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -13816,6 +13884,9 @@ function SimpleMDE(options) {
|
|||||||
if(!options.hasOwnProperty("status")) {
|
if(!options.hasOwnProperty("status")) {
|
||||||
options.status = ["autosave", "lines", "words", "cursor"];
|
options.status = ["autosave", "lines", "words", "cursor"];
|
||||||
}
|
}
|
||||||
|
if(!options.hasOwnProperty("statusCustom")) {
|
||||||
|
options.statusCustom = {};
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
// Add default preview rendering function
|
// Add default preview rendering function
|
||||||
@ -13839,6 +13910,10 @@ function SimpleMDE(options) {
|
|||||||
options.blockStyles = extend({}, blockStyles, options.blockStyles || {});
|
options.blockStyles = extend({}, blockStyles, options.blockStyles || {});
|
||||||
|
|
||||||
|
|
||||||
|
// Merging the shortcuts, with the given options
|
||||||
|
options.shortcuts = extend({}, shortcuts, options.shortcuts || {});
|
||||||
|
|
||||||
|
|
||||||
// Change unique_id to uniqueId for backwards compatibility
|
// Change unique_id to uniqueId for backwards compatibility
|
||||||
if(options.autosave != undefined && options.autosave.unique_id != undefined && options.autosave.unique_id != "")
|
if(options.autosave != undefined && options.autosave.unique_id != undefined && options.autosave.unique_id != "")
|
||||||
options.autosave.uniqueId = options.autosave.unique_id;
|
options.autosave.uniqueId = options.autosave.unique_id;
|
||||||
@ -13909,23 +13984,20 @@ SimpleMDE.prototype.render = function(el) {
|
|||||||
var self = this;
|
var self = this;
|
||||||
var keyMaps = {};
|
var keyMaps = {};
|
||||||
|
|
||||||
for(var key in shortcuts) {
|
for(var key in options.shortcuts) {
|
||||||
|
// null stands for "do not bind this command"
|
||||||
|
if(options.shortcuts[key] !== null && bindings[key] !== null) {
|
||||||
(function(key) {
|
(function(key) {
|
||||||
keyMaps[fixShortcut(key)] = function() {
|
keyMaps[fixShortcut(options.shortcuts[key])] = function() {
|
||||||
shortcuts[key](self);
|
bindings[key](self);
|
||||||
};
|
};
|
||||||
})(key);
|
})(key);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
keyMaps["Enter"] = "newlineAndIndentContinueMarkdownList";
|
keyMaps["Enter"] = "newlineAndIndentContinueMarkdownList";
|
||||||
keyMaps["Tab"] = "tabAndIndentMarkdownList";
|
keyMaps["Tab"] = "tabAndIndentMarkdownList";
|
||||||
keyMaps["Shift-Tab"] = "shiftTabAndUnindentMarkdownList";
|
keyMaps["Shift-Tab"] = "shiftTabAndUnindentMarkdownList";
|
||||||
keyMaps["F11"] = function() {
|
|
||||||
toggleFullScreen(self);
|
|
||||||
};
|
|
||||||
keyMaps["F9"] = function() {
|
|
||||||
toggleSideBySide(self);
|
|
||||||
};
|
|
||||||
keyMaps["Esc"] = function(cm) {
|
keyMaps["Esc"] = function(cm) {
|
||||||
if(cm.getOption("fullScreen")) toggleFullScreen(self);
|
if(cm.getOption("fullScreen")) toggleFullScreen(self);
|
||||||
};
|
};
|
||||||
@ -13968,7 +14040,7 @@ SimpleMDE.prototype.render = function(el) {
|
|||||||
if(options.toolbar !== false) {
|
if(options.toolbar !== false) {
|
||||||
this.createToolbar();
|
this.createToolbar();
|
||||||
}
|
}
|
||||||
if(options.status !== false) {
|
if(options.status !== false || options.statusCustom) {
|
||||||
this.createStatusbar();
|
this.createStatusbar();
|
||||||
}
|
}
|
||||||
if(options.autosave != undefined && options.autosave.enabled === true) {
|
if(options.autosave != undefined && options.autosave.enabled === true) {
|
||||||
@ -14035,8 +14107,8 @@ SimpleMDE.prototype.autosave = function() {
|
|||||||
|
|
||||||
SimpleMDE.prototype.clearAutosavedValue = function() {
|
SimpleMDE.prototype.clearAutosavedValue = function() {
|
||||||
if(localStorage) {
|
if(localStorage) {
|
||||||
if(this.options.autosave.uniqueId == undefined || this.options.autosave.uniqueId == "") {
|
if(this.options.autosave == undefined || this.options.autosave.uniqueId == undefined || this.options.autosave.uniqueId == "") {
|
||||||
console.log("SimpleMDE: You must set a uniqueId to use the autosave feature");
|
console.log("SimpleMDE: You must set a uniqueId to clear the autosave value");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -14125,7 +14197,7 @@ SimpleMDE.prototype.createToolbar = function(items) {
|
|||||||
if(item === "|") {
|
if(item === "|") {
|
||||||
el = createSep();
|
el = createSep();
|
||||||
} else {
|
} else {
|
||||||
el = createIcon(item, self.options.toolbarTips);
|
el = createIcon(item, self.options.toolbarTips, self.options.shortcuts);
|
||||||
}
|
}
|
||||||
|
|
||||||
// bind events, special for info
|
// bind events, special for info
|
||||||
@ -14168,47 +14240,95 @@ SimpleMDE.prototype.createToolbar = function(items) {
|
|||||||
};
|
};
|
||||||
|
|
||||||
SimpleMDE.prototype.createStatusbar = function(status) {
|
SimpleMDE.prototype.createStatusbar = function(status) {
|
||||||
|
var customOptions = this.options.statusCustom;
|
||||||
status = status || this.options.status;
|
status = status || this.options.status;
|
||||||
var options = this.options;
|
var options = this.options;
|
||||||
|
|
||||||
if(!status || status.length === 0) return;
|
if(!status || status.length === 0) return;
|
||||||
|
|
||||||
|
// Copy the defaults if the status is a boolean true
|
||||||
|
if(status === true) status = ["autosave", "lines", "words", "cursor"];
|
||||||
|
|
||||||
|
// Set up the in-built actions: autosave, lines, words, cursor
|
||||||
|
var actions = {};
|
||||||
|
var i, name, onUpdate, defaultValue;
|
||||||
|
for(i = 0; i < status.length; i++) {
|
||||||
|
name = status[i];
|
||||||
|
|
||||||
|
if(name === "words") {
|
||||||
|
defaultValue = function(el) {
|
||||||
|
el.innerHTML = "0";
|
||||||
|
};
|
||||||
|
onUpdate = function(el) {
|
||||||
|
el.innerHTML = wordCount(cm.getValue());
|
||||||
|
};
|
||||||
|
} else if(name === "lines") {
|
||||||
|
defaultValue = function(el) {
|
||||||
|
el.innerHTML = "0";
|
||||||
|
};
|
||||||
|
onUpdate = function(el) {
|
||||||
|
el.innerHTML = cm.lineCount();
|
||||||
|
};
|
||||||
|
} else if(name === "cursor") {
|
||||||
|
defaultValue = function(el) {
|
||||||
|
el.innerHTML = "0:0";
|
||||||
|
};
|
||||||
|
onUpdate = function(el) {
|
||||||
|
pos = cm.getCursor();
|
||||||
|
el.innerHTML = pos.line + ":" + pos.ch;
|
||||||
|
};
|
||||||
|
} else if(name === "autosave") {
|
||||||
|
defaultValue = function(el) {
|
||||||
|
if(options.autosave != undefined && options.autosave.enabled === true) {
|
||||||
|
el.setAttribute("id", "autosaved");
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
actions[name] = {
|
||||||
|
onUpdate: onUpdate,
|
||||||
|
defaultValue: defaultValue
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
// Iterate any user-provided options
|
||||||
|
for(var key in customOptions) {
|
||||||
|
if(customOptions.hasOwnProperty(key)) {
|
||||||
|
var thisOption = customOptions[key];
|
||||||
|
|
||||||
|
// Copy the option into the combined actions
|
||||||
|
// This will allow the user to override the defaults
|
||||||
|
actions[key] = {
|
||||||
|
defaultValue: thisOption.defaultValue,
|
||||||
|
onUpdate: thisOption.onUpdate
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
var bar = document.createElement("div");
|
var bar = document.createElement("div");
|
||||||
bar.className = "editor-statusbar";
|
bar.className = "editor-statusbar";
|
||||||
|
|
||||||
var pos, cm = this.codemirror;
|
var pos, cm = this.codemirror;
|
||||||
for(var i = 0; i < status.length; i++) {
|
// Create a new span for each action
|
||||||
(function(name) {
|
for(name in actions) {
|
||||||
|
if(actions.hasOwnProperty(name)) {
|
||||||
var el = document.createElement("span");
|
var el = document.createElement("span");
|
||||||
el.className = name;
|
el.className = name;
|
||||||
if(name === "words") {
|
// Ensure the defaultValue is a function
|
||||||
el.innerHTML = "0";
|
if(typeof actions[name].defaultValue === "function") {
|
||||||
cm.on("update", function() {
|
actions[name].defaultValue(el);
|
||||||
el.innerHTML = wordCount(cm.getValue());
|
|
||||||
});
|
|
||||||
} else if(name == "characters") {
|
|
||||||
el.innerHTML = "0";
|
|
||||||
cm.on("update", function() {
|
|
||||||
el.innerHTML = cm.getValue().length;
|
|
||||||
});
|
|
||||||
} else if(name === "lines") {
|
|
||||||
el.innerHTML = "0";
|
|
||||||
cm.on("update", function() {
|
|
||||||
el.innerHTML = cm.lineCount();
|
|
||||||
});
|
|
||||||
} else if(name === "cursor") {
|
|
||||||
el.innerHTML = "0:0";
|
|
||||||
cm.on("cursorActivity", function() {
|
|
||||||
pos = cm.getCursor();
|
|
||||||
el.innerHTML = pos.line + ":" + pos.ch;
|
|
||||||
});
|
|
||||||
} else if(name === "autosave") {
|
|
||||||
if(options.autosave != undefined && options.autosave.enabled === true) {
|
|
||||||
el.setAttribute("id", "autosaved");
|
|
||||||
}
|
}
|
||||||
|
// Ensure the onUpdate is a function
|
||||||
|
if(typeof actions[name].onUpdate === "function") {
|
||||||
|
// Create a closure around the span and the name
|
||||||
|
// of the current action, then execute the onUpdate handler
|
||||||
|
cm.on("update", (function(el, name) {
|
||||||
|
return function() {
|
||||||
|
actions[name].onUpdate(el);
|
||||||
|
};
|
||||||
|
}(el, name)));
|
||||||
}
|
}
|
||||||
bar.appendChild(el);
|
bar.appendChild(el);
|
||||||
})(status[i]);
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
var cmWrapper = this.codemirror.getWrapperElement();
|
var cmWrapper = this.codemirror.getWrapperElement();
|
||||||
@ -14244,6 +14364,7 @@ SimpleMDE.toggleHeading3 = toggleHeading3;
|
|||||||
SimpleMDE.toggleCodeBlock = toggleCodeBlock;
|
SimpleMDE.toggleCodeBlock = toggleCodeBlock;
|
||||||
SimpleMDE.toggleUnorderedList = toggleUnorderedList;
|
SimpleMDE.toggleUnorderedList = toggleUnorderedList;
|
||||||
SimpleMDE.toggleOrderedList = toggleOrderedList;
|
SimpleMDE.toggleOrderedList = toggleOrderedList;
|
||||||
|
SimpleMDE.cleanBlock = cleanBlock;
|
||||||
SimpleMDE.drawLink = drawLink;
|
SimpleMDE.drawLink = drawLink;
|
||||||
SimpleMDE.drawImage = drawImage;
|
SimpleMDE.drawImage = drawImage;
|
||||||
SimpleMDE.drawTable = drawTable;
|
SimpleMDE.drawTable = drawTable;
|
||||||
@ -14293,6 +14414,9 @@ SimpleMDE.prototype.toggleUnorderedList = function() {
|
|||||||
SimpleMDE.prototype.toggleOrderedList = function() {
|
SimpleMDE.prototype.toggleOrderedList = function() {
|
||||||
toggleOrderedList(this);
|
toggleOrderedList(this);
|
||||||
};
|
};
|
||||||
|
SimpleMDE.prototype.cleanBlock = function() {
|
||||||
|
cleanBlock(this);
|
||||||
|
};
|
||||||
SimpleMDE.prototype.drawLink = function() {
|
SimpleMDE.prototype.drawLink = function() {
|
||||||
drawLink(this);
|
drawLink(this);
|
||||||
};
|
};
|
||||||
@ -14343,6 +14467,12 @@ SimpleMDE.prototype.isFullscreenActive = function() {
|
|||||||
return cm.getOption("fullScreen");
|
return cm.getOption("fullScreen");
|
||||||
};
|
};
|
||||||
|
|
||||||
|
SimpleMDE.prototype.getState = function() {
|
||||||
|
var cm = this.codemirror;
|
||||||
|
|
||||||
|
return getState(cm);
|
||||||
|
};
|
||||||
|
|
||||||
module.exports = SimpleMDE;
|
module.exports = SimpleMDE;
|
||||||
|
|
||||||
},{"./codemirror/tablist":13,"codemirror":7,"codemirror/addon/display/fullscreen.js":3,"codemirror/addon/display/placeholder.js":4,"codemirror/addon/edit/continuelist.js":5,"codemirror/addon/mode/overlay.js":6,"codemirror/mode/gfm/gfm.js":8,"codemirror/mode/markdown/markdown.js":9,"codemirror/mode/xml/xml.js":11,"marked":12,"spell-checker":1}]},{},[14])(14)
|
},{"./codemirror/tablist":13,"codemirror":7,"codemirror/addon/display/fullscreen.js":3,"codemirror/addon/display/placeholder.js":4,"codemirror/addon/edit/continuelist.js":5,"codemirror/addon/mode/overlay.js":6,"codemirror/mode/gfm/gfm.js":8,"codemirror/mode/markdown/markdown.js":9,"codemirror/mode/xml/xml.js":11,"marked":12,"spell-checker":1}]},{},[14])(14)
|
||||||
|
2
dist/simplemde.min.css
vendored
2
dist/simplemde.min.css
vendored
File diff suppressed because one or more lines are too long
16
dist/simplemde.min.js
vendored
16
dist/simplemde.min.js
vendored
File diff suppressed because one or more lines are too long
@ -323,6 +323,6 @@
|
|||||||
text-decoration: line-through;
|
text-decoration: line-through;
|
||||||
}
|
}
|
||||||
|
|
||||||
.CodeMirror .CodeMirror-placeholder{
|
.CodeMirror .CodeMirror-placeholder {
|
||||||
opacity: .5;
|
opacity: .5;
|
||||||
}
|
}
|
Loading…
x
Reference in New Issue
Block a user