Fixes #36035.

git-svn-id: https://develop.svn.wordpress.org/trunk@36798 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Ozz 2016-03-01 23:12:43 +00:00
parent 84ecbb5e44
commit b4db71a2f8
23 changed files with 3575 additions and 1820 deletions

View File

@ -119,7 +119,10 @@ tinymce.PluginManager.add('fullscreen', function(editor) {
text: 'Fullscreen', text: 'Fullscreen',
shortcut: 'Meta+Alt+F', shortcut: 'Meta+Alt+F',
selectable: true, selectable: true,
onClick: toggleFullscreen, onClick: function() {
toggleFullscreen();
editor.focus();
},
onPostRender: function() { onPostRender: function() {
var self = this; var self = this;

View File

@ -1 +1 @@
tinymce.PluginManager.add("fullscreen",function(a){function b(){var a,b,c=window,d=document,e=d.body;return e.offsetWidth&&(a=e.offsetWidth,b=e.offsetHeight),c.innerWidth&&c.innerHeight&&(a=c.innerWidth,b=c.innerHeight),{w:a,h:b}}function c(){var a=tinymce.DOM.getViewPort();return{x:a.x,y:a.y}}function d(a){scrollTo(a.x,a.y)}function e(){function e(){m.setStyle(p,"height",b().h-(o.clientHeight-p.clientHeight))}var n,o,p,q,r=document.body,s=document.documentElement;l=!l,o=a.getContainer(),n=o.style,p=a.getContentAreaContainer().firstChild,q=p.style,l?(k=c(),f=q.width,g=q.height,q.width=q.height="100%",i=n.width,j=n.height,n.width=n.height="",m.addClass(r,"mce-fullscreen"),m.addClass(s,"mce-fullscreen"),m.addClass(o,"mce-fullscreen"),m.bind(window,"resize",e),e(),h=e):(q.width=f,q.height=g,i&&(n.width=i),j&&(n.height=j),m.removeClass(r,"mce-fullscreen"),m.removeClass(s,"mce-fullscreen"),m.removeClass(o,"mce-fullscreen"),m.unbind(window,"resize",h),d(k)),a.fire("FullscreenStateChanged",{state:l})}var f,g,h,i,j,k,l=!1,m=tinymce.DOM;return a.settings.inline?void 0:(a.on("init",function(){a.addShortcut("Meta+Alt+F","",e)}),a.on("remove",function(){h&&m.unbind(window,"resize",h)}),a.addCommand("mceFullScreen",e),a.addMenuItem("fullscreen",{text:"Fullscreen",shortcut:"Meta+Alt+F",selectable:!0,onClick:e,onPostRender:function(){var b=this;a.on("FullscreenStateChanged",function(a){b.active(a.state)})},context:"view"}),a.addButton("fullscreen",{tooltip:"Fullscreen",shortcut:"Meta+Alt+F",onClick:e,onPostRender:function(){var b=this;a.on("FullscreenStateChanged",function(a){b.active(a.state)})}}),{isFullscreen:function(){return l}})}); tinymce.PluginManager.add("fullscreen",function(a){function b(){var a,b,c=window,d=document,e=d.body;return e.offsetWidth&&(a=e.offsetWidth,b=e.offsetHeight),c.innerWidth&&c.innerHeight&&(a=c.innerWidth,b=c.innerHeight),{w:a,h:b}}function c(){var a=tinymce.DOM.getViewPort();return{x:a.x,y:a.y}}function d(a){scrollTo(a.x,a.y)}function e(){function e(){m.setStyle(p,"height",b().h-(o.clientHeight-p.clientHeight))}var n,o,p,q,r=document.body,s=document.documentElement;l=!l,o=a.getContainer(),n=o.style,p=a.getContentAreaContainer().firstChild,q=p.style,l?(k=c(),f=q.width,g=q.height,q.width=q.height="100%",i=n.width,j=n.height,n.width=n.height="",m.addClass(r,"mce-fullscreen"),m.addClass(s,"mce-fullscreen"),m.addClass(o,"mce-fullscreen"),m.bind(window,"resize",e),e(),h=e):(q.width=f,q.height=g,i&&(n.width=i),j&&(n.height=j),m.removeClass(r,"mce-fullscreen"),m.removeClass(s,"mce-fullscreen"),m.removeClass(o,"mce-fullscreen"),m.unbind(window,"resize",h),d(k)),a.fire("FullscreenStateChanged",{state:l})}var f,g,h,i,j,k,l=!1,m=tinymce.DOM;return a.settings.inline?void 0:(a.on("init",function(){a.addShortcut("Meta+Alt+F","",e)}),a.on("remove",function(){h&&m.unbind(window,"resize",h)}),a.addCommand("mceFullScreen",e),a.addMenuItem("fullscreen",{text:"Fullscreen",shortcut:"Meta+Alt+F",selectable:!0,onClick:function(){e(),a.focus()},onPostRender:function(){var b=this;a.on("FullscreenStateChanged",function(a){b.active(a.state)})},context:"view"}),a.addButton("fullscreen",{tooltip:"Fullscreen",shortcut:"Meta+Alt+F",onClick:e,onPostRender:function(){var b=this;a.on("FullscreenStateChanged",function(a){b.active(a.state)})}}),{isFullscreen:function(){return l}})});

View File

@ -811,6 +811,16 @@ tinymce.PluginManager.add('media', function(editor, url) {
}); });
}); });
editor.on('click keyup', function() {
var selectedNode = editor.selection.getNode();
if (selectedNode && editor.dom.hasClass(selectedNode, 'mce-preview-object')) {
if (editor.dom.getAttrib(selectedNode, 'data-mce-selected')) {
selectedNode.setAttribute('data-mce-selected', '2');
}
}
});
editor.on('ObjectSelected', function(e) { editor.on('ObjectSelected', function(e) {
var objectType = e.target.getAttribute('data-mce-object'); var objectType = e.target.getAttribute('data-mce-object');
@ -850,6 +860,18 @@ tinymce.PluginManager.add('media', function(editor, url) {
prependToContext: true prependToContext: true
}); });
editor.on('setContent', function() {
// TODO: This shouldn't be needed there should be a way to mark bogus
// elements so they are never removed except external save
editor.$('span.mce-preview-object').each(function(index, elm) {
var $elm = editor.$(elm);
if ($elm.find('span.mce-shim', elm).length === 0) {
$elm.append('<span class="mce-shim"></span>');
}
});
});
editor.addCommand('mceMedia', showDialog); editor.addCommand('mceMedia', showDialog);
this.showDialog = showDialog; this.showDialog = showDialog;

File diff suppressed because one or more lines are too long

View File

@ -223,10 +223,20 @@ define("tinymce/pasteplugin/Utils", [
return html; return html;
} }
// TODO: Should be in some global class
function createIdGenerator(prefix) {
var count = 0;
return function() {
return prefix + (count++);
};
}
return { return {
filter: filter, filter: filter,
innerText: innerText, innerText: innerText,
trimHtml: trimHtml trimHtml: trimHtml,
createIdGenerator: createIdGenerator
}; };
}); });
@ -272,6 +282,7 @@ define("tinymce/pasteplugin/Clipboard", [
var self = this, pasteBinElm, lastRng, keyboardPasteTimeStamp = 0, draggingInternally = false; var self = this, pasteBinElm, lastRng, keyboardPasteTimeStamp = 0, draggingInternally = false;
var pasteBinDefaultContent = '%MCEPASTEBIN%', keyboardPastePlainTextState; var pasteBinDefaultContent = '%MCEPASTEBIN%', keyboardPastePlainTextState;
var mceInternalUrlPrefix = 'data:text/mce-internal,'; var mceInternalUrlPrefix = 'data:text/mce-internal,';
var uniqueId = Utils.createIdGenerator("mceclip");
/** /**
* Pastes the specified HTML. This means that the HTML is filtered and then * Pastes the specified HTML. This means that the HTML is filtered and then
@ -514,56 +525,6 @@ define("tinymce/pasteplugin/Clipboard", [
return html; return html;
} }
/**
* Some Windows 10/Edge versions will return a double encoded string. This checks if the
* content has this odd encoding and decodes it.
*/
function decodeEdgeData(data) {
var i, out, fingerprint, code;
// Check if data is encoded
fingerprint = [25942, 29554, 28521, 14958];
for (i = 0; i < fingerprint.length; i++) {
if (data.charCodeAt(i) != fingerprint[i]) {
return data;
}
}
// Decode UTF-16 to UTF-8
out = '';
for (i = 0; i < data.length; i++) {
code = data.charCodeAt(i);
/*eslint no-bitwise:0*/
out += String.fromCharCode((code & 0x00FF));
out += String.fromCharCode((code & 0xFF00) >> 8);
}
// Decode UTF-8
return decodeURIComponent(escape(out));
}
/**
* Extracts HTML contents from within a fragment.
*/
function extractFragment(data) {
var idx, startFragment, endFragment;
startFragment = '<!--StartFragment-->';
idx = data.indexOf(startFragment);
if (idx !== -1) {
data = data.substr(idx + startFragment.length);
}
endFragment = '<!--EndFragment-->';
idx = data.indexOf(endFragment);
if (idx !== -1) {
data = data.substr(0, idx);
}
return data;
}
/** /**
* Gets various content types out of a datatransfer object. * Gets various content types out of a datatransfer object.
* *
@ -586,14 +547,8 @@ define("tinymce/pasteplugin/Clipboard", [
if (dataTransfer.types) { if (dataTransfer.types) {
for (var i = 0; i < dataTransfer.types.length; i++) { for (var i = 0; i < dataTransfer.types.length; i++) {
var contentType = dataTransfer.types[i], var contentType = dataTransfer.types[i];
data = dataTransfer.getData(contentType); items[contentType] = dataTransfer.getData(contentType);
if (contentType == 'text/html') {
data = extractFragment(decodeEdgeData(data));
}
items[contentType] = data;
} }
} }
} }
@ -612,27 +567,46 @@ define("tinymce/pasteplugin/Clipboard", [
return getDataTransferItems(clipboardEvent.clipboardData || editor.getDoc().dataTransfer); return getDataTransferItems(clipboardEvent.clipboardData || editor.getDoc().dataTransfer);
} }
function hasHtmlOrText(content) {
return hasContentType(content, 'text/html') || hasContentType(content, 'text/plain');
}
/** /**
* Checks if the clipboard contains image data if it does it will take that data * Checks if the clipboard contains image data if it does it will take that data
* and convert it into a data url image and paste that image at the caret location. * and convert it into a data url image and paste that image at the caret location.
* *
* @param {ClipboardEvent} e Paste/drop event object. * @param {ClipboardEvent} e Paste/drop event object.
* @param {DOMRange} rng Optional rng object to move selection to. * @param {DOMRange} rng Rng object to move selection to.
* @return {Boolean} true/false if the image data was found or not. * @return {Boolean} true/false if the image data was found or not.
*/ */
function pasteImageData(e, rng) { function pasteImageData(e, rng) {
var dataTransfer = e.clipboardData || e.dataTransfer; var dataTransfer = e.clipboardData || e.dataTransfer;
function getBase64FromUri(uri) {
var idx;
idx = uri.indexOf(',');
if (idx !== -1) {
return uri.substr(idx + 1);
}
return null;
}
function processItems(items) { function processItems(items) {
var i, item, reader, hadImage = false; var i, item, reader, hadImage = false;
function pasteImage(reader) { function pasteImage(reader, blob) {
if (rng) { if (rng) {
editor.selection.setRng(rng); editor.selection.setRng(rng);
rng = null; rng = null;
} }
pasteHtml('<img src="' + reader.result + '">'); var blobCache = editor.editorUpload.blobCache;
var blobInfo = blobCache.create(uniqueId(), blob, getBase64FromUri(reader.result));
blobCache.add(blobInfo);
pasteHtml('<img src="' + blobInfo.blobUri() + '">');
} }
if (items) { if (items) {
@ -640,9 +614,11 @@ define("tinymce/pasteplugin/Clipboard", [
item = items[i]; item = items[i];
if (/^image\/(jpeg|png|gif|bmp)$/.test(item.type)) { if (/^image\/(jpeg|png|gif|bmp)$/.test(item.type)) {
var blob = item.getAsFile ? item.getAsFile() : item;
reader = new FileReader(); reader = new FileReader();
reader.onload = pasteImage.bind(null, reader); reader.onload = pasteImage.bind(null, reader, blob);
reader.readAsDataURL(item.getAsFile ? item.getAsFile() : item); reader.readAsDataURL(blob);
e.preventDefault(); e.preventDefault();
hadImage = true; hadImage = true;
@ -785,6 +761,10 @@ define("tinymce/pasteplugin/Clipboard", [
} }
} }
var getLastRng = function() {
return lastRng || editor.selection.getRng();
};
editor.on('paste', function(e) { editor.on('paste', function(e) {
// Getting content from the Clipboard can take some time // Getting content from the Clipboard can take some time
var clipboardTimer = new Date().getTime(); var clipboardTimer = new Date().getTime();
@ -801,7 +781,7 @@ define("tinymce/pasteplugin/Clipboard", [
return; return;
} }
if (pasteImageData(e)) { if (!hasHtmlOrText(clipboardContent) && pasteImageData(e, getLastRng())) {
removePasteBin(); removePasteBin();
return; return;
} }
@ -839,18 +819,21 @@ define("tinymce/pasteplugin/Clipboard", [
}); });
editor.on('drop', function(e) { editor.on('drop', function(e) {
var rng = getCaretRangeFromEvent(e); var dropContent, rng;
rng = getCaretRangeFromEvent(e);
if (e.isDefaultPrevented() || draggingInternally) { if (e.isDefaultPrevented() || draggingInternally) {
return; return;
} }
if (pasteImageData(e, rng)) { dropContent = getDataTransferItems(e.dataTransfer);
if (!hasHtmlOrText(dropContent) && pasteImageData(e, rng)) {
return; return;
} }
if (rng && editor.settings.paste_filter_drop !== false) { if (rng && editor.settings.paste_filter_drop !== false) {
var dropContent = getDataTransferItems(e.dataTransfer);
var content = dropContent['mce-internal'] || dropContent['text/html'] || dropContent['text/plain']; var content = dropContent['mce-internal'] || dropContent['text/html'] || dropContent['text/plain'];
if (content) { if (content) {
@ -1626,25 +1609,34 @@ define("tinymce/pasteplugin/Plugin", [
PluginManager.add('paste', function(editor) { PluginManager.add('paste', function(editor) {
var self = this, clipboard, settings = editor.settings; var self = this, clipboard, settings = editor.settings;
function isUserInformedAboutPlainText() {
return userIsInformed || editor.settings.paste_plaintext_inform === false;
}
function togglePlainTextPaste() { function togglePlainTextPaste() {
if (clipboard.pasteFormat == "text") { if (clipboard.pasteFormat == "text") {
this.active(false); this.active(false);
clipboard.pasteFormat = "html"; clipboard.pasteFormat = "html";
editor.fire('PastePlainTextToggle', {state: false});
} else { } else {
clipboard.pasteFormat = "text"; clipboard.pasteFormat = "text";
this.active(true); this.active(true);
if (!userIsInformed) { if (!isUserInformedAboutPlainText()) {
var message = editor.translate('Paste is now in plain text mode. Contents will now ' + var message = editor.translate('Paste is now in plain text mode. Contents will now ' +
'be pasted as plain text until you toggle this option off.'); 'be pasted as plain text until you toggle this option off.');
editor.notificationManager.open({ editor.notificationManager.open({
text: message, text: message,
type: 'info' type: 'info'
}); });
userIsInformed = true; userIsInformed = true;
editor.fire('PastePlainTextToggle', {state: true});
} }
} }
editor.focus();
} }
self.clipboard = clipboard = new Clipboard(editor); self.clipboard = clipboard = new Clipboard(editor);

File diff suppressed because one or more lines are too long

View File

@ -1 +1 @@
.mce-content-body .mce-reset{margin:0;padding:0;border:0;outline:0;vertical-align:top;background:transparent;text-decoration:none;color:black;font-family:Arial;font-size:11px;text-shadow:none;float:none;position:static;width:auto;height:auto;white-space:nowrap;cursor:inherit;line-height:normal;font-weight:normal;text-align:left;-webkit-tap-highlight-color:transparent;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box;direction:ltr;max-width:none}.mce-object{border:1px dotted #3a3a3a;background:#d5d5d5 url(img/object.gif) no-repeat center}.mce-preview-object{display:inline-block;position:relative;margin:0 2px 0 2px;line-height:0;border:1px solid gray}.mce-preview-object .mce-shim{position:absolute;top:0;left:0;width:100%;height:100%;background:url(data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)}figure.align-left{float:left}figure.align-right{float:right}figure.image.align-center{display:table;margin-left:auto;margin-right:auto}figure.image{display:inline-block;border:1px solid gray;margin:0 2px 0 1px;background:#f5f2f0}figure.image img{margin:8px 8px 0 8px}figure.image figcaption{margin:6px 8px 6px 8px;text-align:center}.mce-preview-object[data-mce-selected] .mce-shim{display:none}.mce-pagebreak{cursor:default;display:block;border:0;width:100%;height:5px;border:1px dashed #666;margin-top:15px;page-break-before:always}@media print{.mce-pagebreak{border:0}}.mce-item-anchor{cursor:default;display:inline-block;-webkit-user-select:all;-webkit-user-modify:read-only;-moz-user-select:all;-moz-user-modify:read-only;user-select:all;user-modify:read-only;width:9px !important;height:9px !important;border:1px dotted #3a3a3a;background:#d5d5d5 url(img/anchor.gif) no-repeat center}.mce-nbsp,.mce-shy{background:#aaa}.mce-shy::after{content:'-'}hr{cursor:default}.mce-match-marker{background:#aaa;color:#fff}.mce-match-marker-selected{background:#39f;color:#fff}.mce-spellchecker-word{border-bottom:2px solid #f00;cursor:default}.mce-spellchecker-grammar{border-bottom:2px solid #008000;cursor:default}.mce-item-table,.mce-item-table td,.mce-item-table th,.mce-item-table caption{border:1px dashed #bbb}td[data-mce-selected],th[data-mce-selected]{background-color:#39f !important}.mce-edit-focus{outline:1px dotted #333}.mce-content-body *[contentEditable=false] *[contentEditable=true]:focus{outline:2px solid #2d8ac7}.mce-content-body *[contentEditable=false] *[contentEditable=true]:hover{outline:2px solid #7acaff}.mce-content-body *[contentEditable=false][data-mce-selected]{outline:2px solid #2d8ac7}.mce-resize-bar-dragging{background-color:blue;opacity:.25;filter:alpha(opacity=25);zoom:1} .mce-content-body .mce-reset{margin:0;padding:0;border:0;outline:0;vertical-align:top;background:transparent;text-decoration:none;color:black;font-family:Arial;font-size:11px;text-shadow:none;float:none;position:static;width:auto;height:auto;white-space:nowrap;cursor:inherit;line-height:normal;font-weight:normal;text-align:left;-webkit-tap-highlight-color:transparent;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box;direction:ltr;max-width:none}.mce-object{border:1px dotted #3a3a3a;background:#d5d5d5 url(img/object.gif) no-repeat center}.mce-preview-object{display:inline-block;position:relative;margin:0 2px 0 2px;line-height:0;border:1px solid gray}.mce-preview-object .mce-shim{position:absolute;top:0;left:0;width:100%;height:100%;background:url(data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)}figure.align-left{float:left}figure.align-right{float:right}figure.image.align-center{display:table;margin-left:auto;margin-right:auto}figure.image{display:inline-block;border:1px solid gray;margin:0 2px 0 1px;background:#f5f2f0}figure.image img{margin:8px 8px 0 8px}figure.image figcaption{margin:6px 8px 6px 8px;text-align:center}.mce-preview-object[data-mce-selected="2"] .mce-shim{display:none}.mce-pagebreak{cursor:default;display:block;border:0;width:100%;height:5px;border:1px dashed #666;margin-top:15px;page-break-before:always}@media print{.mce-pagebreak{border:0}}.mce-item-anchor{cursor:default;display:inline-block;-webkit-user-select:all;-webkit-user-modify:read-only;-moz-user-select:all;-moz-user-modify:read-only;user-select:all;user-modify:read-only;width:9px !important;height:9px !important;border:1px dotted #3a3a3a;background:#d5d5d5 url(img/anchor.gif) no-repeat center}.mce-nbsp,.mce-shy{background:#aaa}.mce-shy::after{content:'-'}hr{cursor:default}.mce-match-marker{background:#aaa;color:#fff}.mce-match-marker-selected{background:#39f;color:#fff}.mce-spellchecker-word{border-bottom:2px solid #f00;cursor:default}.mce-spellchecker-grammar{border-bottom:2px solid #008000;cursor:default}.mce-item-table,.mce-item-table td,.mce-item-table th,.mce-item-table caption{border:1px dashed #bbb}td[data-mce-selected],th[data-mce-selected]{background-color:#39f !important}.mce-edit-focus{outline:1px dotted #333}.mce-content-body *[contentEditable=false] *[contentEditable=true]:focus{outline:2px solid #2d8ac7}.mce-content-body *[contentEditable=false] *[contentEditable=true]:hover{outline:2px solid #7acaff}.mce-content-body *[contentEditable=false][data-mce-selected]{outline:2px solid #2d8ac7}.mce-resize-bar-dragging{background-color:blue;opacity:.25;filter:alpha(opacity=25);zoom:1}

View File

@ -1 +1 @@
body{background-color:#fff;color:#000;font-family:Verdana,Arial,Helvetica,sans-serif;font-size:11px;scrollbar-3dlight-color:#f0f0ee;scrollbar-arrow-color:#676662;scrollbar-base-color:#f0f0ee;scrollbar-darkshadow-color:#ddd;scrollbar-face-color:#e0e0dd;scrollbar-highlight-color:#f0f0ee;scrollbar-shadow-color:#f0f0ee;scrollbar-track-color:#f5f5f5}td,th{font-family:Verdana,Arial,Helvetica,sans-serif;font-size:11px}.mce-content-body .mce-reset{margin:0;padding:0;border:0;outline:0;vertical-align:top;background:transparent;text-decoration:none;color:black;font-family:Arial;font-size:11px;text-shadow:none;float:none;position:static;width:auto;height:auto;white-space:nowrap;cursor:inherit;line-height:normal;font-weight:normal;text-align:left;-webkit-tap-highlight-color:transparent;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box;direction:ltr;max-width:none}.mce-object{border:1px dotted #3a3a3a;background:#d5d5d5 url(img/object.gif) no-repeat center}.mce-preview-object{display:inline-block;position:relative;margin:0 2px 0 2px;line-height:0;border:1px solid gray}.mce-preview-object .mce-shim{position:absolute;top:0;left:0;width:100%;height:100%;background:url(data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)}figure.align-left{float:left}figure.align-right{float:right}figure.image.align-center{display:table;margin-left:auto;margin-right:auto}figure.image{display:inline-block;border:1px solid gray;margin:0 2px 0 1px;background:#f5f2f0}figure.image img{margin:8px 8px 0 8px}figure.image figcaption{margin:6px 8px 6px 8px;text-align:center}.mce-preview-object[data-mce-selected] .mce-shim{display:none}.mce-pagebreak{cursor:default;display:block;border:0;width:100%;height:5px;border:1px dashed #666;margin-top:15px;page-break-before:always}@media print{.mce-pagebreak{border:0}}.mce-item-anchor{cursor:default;display:inline-block;-webkit-user-select:all;-webkit-user-modify:read-only;-moz-user-select:all;-moz-user-modify:read-only;user-select:all;user-modify:read-only;width:9px !important;height:9px !important;border:1px dotted #3a3a3a;background:#d5d5d5 url(img/anchor.gif) no-repeat center}.mce-nbsp,.mce-shy{background:#aaa}.mce-shy::after{content:'-'}hr{cursor:default}.mce-match-marker{background:#aaa;color:#fff}.mce-match-marker-selected{background:#39f;color:#fff}.mce-spellchecker-word{border-bottom:2px solid #f00;cursor:default}.mce-spellchecker-grammar{border-bottom:2px solid #008000;cursor:default}.mce-item-table,.mce-item-table td,.mce-item-table th,.mce-item-table caption{border:1px dashed #bbb}td[data-mce-selected],th[data-mce-selected]{background-color:#39f !important}.mce-edit-focus{outline:1px dotted #333}.mce-content-body *[contentEditable=false] *[contentEditable=true]:focus{outline:2px solid #2d8ac7}.mce-content-body *[contentEditable=false] *[contentEditable=true]:hover{outline:2px solid #7acaff}.mce-content-body *[contentEditable=false][data-mce-selected]{outline:2px solid #2d8ac7}.mce-resize-bar-dragging{background-color:blue;opacity:.25;filter:alpha(opacity=25);zoom:1} body{background-color:#fff;color:#000;font-family:Verdana,Arial,Helvetica,sans-serif;font-size:11px;scrollbar-3dlight-color:#f0f0ee;scrollbar-arrow-color:#676662;scrollbar-base-color:#f0f0ee;scrollbar-darkshadow-color:#ddd;scrollbar-face-color:#e0e0dd;scrollbar-highlight-color:#f0f0ee;scrollbar-shadow-color:#f0f0ee;scrollbar-track-color:#f5f5f5}td,th{font-family:Verdana,Arial,Helvetica,sans-serif;font-size:11px}.mce-content-body .mce-reset{margin:0;padding:0;border:0;outline:0;vertical-align:top;background:transparent;text-decoration:none;color:black;font-family:Arial;font-size:11px;text-shadow:none;float:none;position:static;width:auto;height:auto;white-space:nowrap;cursor:inherit;line-height:normal;font-weight:normal;text-align:left;-webkit-tap-highlight-color:transparent;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box;direction:ltr;max-width:none}.mce-object{border:1px dotted #3a3a3a;background:#d5d5d5 url(img/object.gif) no-repeat center}.mce-preview-object{display:inline-block;position:relative;margin:0 2px 0 2px;line-height:0;border:1px solid gray}.mce-preview-object .mce-shim{position:absolute;top:0;left:0;width:100%;height:100%;background:url(data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)}figure.align-left{float:left}figure.align-right{float:right}figure.image.align-center{display:table;margin-left:auto;margin-right:auto}figure.image{display:inline-block;border:1px solid gray;margin:0 2px 0 1px;background:#f5f2f0}figure.image img{margin:8px 8px 0 8px}figure.image figcaption{margin:6px 8px 6px 8px;text-align:center}.mce-preview-object[data-mce-selected="2"] .mce-shim{display:none}.mce-pagebreak{cursor:default;display:block;border:0;width:100%;height:5px;border:1px dashed #666;margin-top:15px;page-break-before:always}@media print{.mce-pagebreak{border:0}}.mce-item-anchor{cursor:default;display:inline-block;-webkit-user-select:all;-webkit-user-modify:read-only;-moz-user-select:all;-moz-user-modify:read-only;user-select:all;user-modify:read-only;width:9px !important;height:9px !important;border:1px dotted #3a3a3a;background:#d5d5d5 url(img/anchor.gif) no-repeat center}.mce-nbsp,.mce-shy{background:#aaa}.mce-shy::after{content:'-'}hr{cursor:default}.mce-match-marker{background:#aaa;color:#fff}.mce-match-marker-selected{background:#39f;color:#fff}.mce-spellchecker-word{border-bottom:2px solid #f00;cursor:default}.mce-spellchecker-grammar{border-bottom:2px solid #008000;cursor:default}.mce-item-table,.mce-item-table td,.mce-item-table th,.mce-item-table caption{border:1px dashed #bbb}td[data-mce-selected],th[data-mce-selected]{background-color:#39f !important}.mce-edit-focus{outline:1px dotted #333}.mce-content-body *[contentEditable=false] *[contentEditable=true]:focus{outline:2px solid #2d8ac7}.mce-content-body *[contentEditable=false] *[contentEditable=true]:hover{outline:2px solid #7acaff}.mce-content-body *[contentEditable=false][data-mce-selected]{outline:2px solid #2d8ac7}.mce-resize-bar-dragging{background-color:blue;opacity:.25;filter:alpha(opacity=25);zoom:1}

File diff suppressed because it is too large Load Diff

View File

@ -78,8 +78,39 @@
<glyph unicode="&#xe62b;" glyph-name="tabletopheader" d="M0 896v-832h1024v832h-1024zM320 128h-256v192h256v-192zM320 384h-256v192h256v-192zM640 128h-256v192h256v-192zM640 384h-256v192h256v-192zM960 128h-256v192h256v-192zM960 384h-256v192h256v-192z" /> <glyph unicode="&#xe62b;" glyph-name="tabletopheader" d="M0 896v-832h1024v832h-1024zM320 128h-256v192h256v-192zM320 384h-256v192h256v-192zM640 128h-256v192h256v-192zM640 384h-256v192h256v-192zM960 128h-256v192h256v-192zM960 384h-256v192h256v-192z" />
<glyph unicode="&#xe800;" glyph-name="tabledeleterow" d="M886.4 572.8l-156.8-156.8 160-160-76.8-76.8-160 160-156.8-156.8-76.8 73.6 160 160-163.2 163.2 76.8 76.8 163.2-163.2 156.8 156.8 73.6-76.8zM0 896v-896h1024v896h-1024zM960 576h-22.4l-64-64h86.4v-192h-89.6l64-64h25.6v-192h-896v192h310.4l64 64h-374.4v192h371.2l-64 64h-307.2v192h896v-192z" /> <glyph unicode="&#xe800;" glyph-name="tabledeleterow" d="M886.4 572.8l-156.8-156.8 160-160-76.8-76.8-160 160-156.8-156.8-76.8 73.6 160 160-163.2 163.2 76.8 76.8 163.2-163.2 156.8 156.8 73.6-76.8zM0 896v-896h1024v896h-1024zM960 576h-22.4l-64-64h86.4v-192h-89.6l64-64h25.6v-192h-896v192h310.4l64 64h-374.4v192h371.2l-64 64h-307.2v192h896v-192z" />
<glyph unicode="&#xe801;" glyph-name="tabledeletecol" d="M320 499.2l64-64v-12.8l-64-64v140.8zM640 422.4l64-64v137.6l-64-64v-9.6zM1024 896v-896h-1024v896h1024zM960 768h-256v-51.2l-12.8 12.8-51.2-51.2v89.6h-256v-89.6l-51.2 51.2-12.8-12.8v51.2h-256v-704h256v118.4l35.2-35.2 28.8 28.8v-115.2h256v115.2l48-48 16 16v-83.2h256v707.2zM672 662.4l-156.8-156.8-163.2 163.2-76.8-76.8 163.2-163.2-156.8-156.8 76.8-76.8 156.8 156.8 160-160 76.8 76.8-160 160 156.8 156.8-76.8 76.8z" /> <glyph unicode="&#xe801;" glyph-name="tabledeletecol" d="M320 499.2l64-64v-12.8l-64-64v140.8zM640 422.4l64-64v137.6l-64-64v-9.6zM1024 896v-896h-1024v896h1024zM960 768h-256v-51.2l-12.8 12.8-51.2-51.2v89.6h-256v-89.6l-51.2 51.2-12.8-12.8v51.2h-256v-704h256v118.4l35.2-35.2 28.8 28.8v-115.2h256v115.2l48-48 16 16v-83.2h256v707.2zM672 662.4l-156.8-156.8-163.2 163.2-76.8-76.8 163.2-163.2-156.8-156.8 76.8-76.8 156.8 156.8 160-160 76.8 76.8-160 160 156.8 156.8-76.8 76.8z" />
<glyph unicode="&#xe914;" glyph-name="editimage" d="M768 416v-352h-640v640h352l128 128h-512c-52.8 0-96-43.2-96-96v-704c0-52.8 43.2-96 96-96h704c52.798 0 96 43.2 96 96v512l-128-128zM864 960l-608-608v-160h160l608 608c0 96-64 160-160 160zM416 320l-48 48 480 480 48-48-480-480z" /> <glyph unicode="&#xe900;" glyph-name="a11y" d="M960 704v64l-448-128-448 128v-64l320-128v-256l-128-448h64l192 448 192-448h64l-128 448v256zM416 800q0 40 28 68t68 28 68-28 28-68-28-68-68-28-68 28-28 68z" />
<glyph unicode="&#xe934;" glyph-name="drop" d="M864.626 486.838c-65.754 183.44-205.11 348.15-352.626 473.162-147.516-125.012-286.87-289.722-352.626-473.162-40.664-113.436-44.682-236.562 12.584-345.4 65.846-125.14 198.632-205.438 340.042-205.438s274.196 80.298 340.040 205.44c57.27 108.838 53.25 231.962 12.586 345.398zM738.764 201.044c-43.802-83.252-132.812-137.044-226.764-137.044-55.12 0-108.524 18.536-152.112 50.652 13.242-1.724 26.632-2.652 40.112-2.652 117.426 0 228.668 67.214 283.402 171.242 44.878 85.292 40.978 173.848 23.882 244.338 14.558-28.15 26.906-56.198 36.848-83.932 22.606-63.062 40.024-156.34-5.368-242.604z" /> <glyph unicode="&#xe902;" glyph-name="fill" d="M521.6 915.2l-67.2-67.2-86.4 86.4-86.4-86.4 86.4-86.4-368-368 432-432 518.4 518.4-428.8 435.2zM435.2 134.4l-262.4 262.4 35.2 35.2 576 51.2-348.8-348.8zM953.6 409.6c-6.4-6.4-16-16-28.8-32-28.8-32-41.6-64-41.6-89.6v0 0 0 0 0 0 0c0-16 6.4-35.2 22.4-48 12.8-12.8 32-22.4 48-22.4s35.2 6.4 48 22.4 22.4 32 22.4 48v0 0 0 0 0 0 0c0 25.6-12.8 54.4-41.6 89.6-9.6 16-22.4 25.6-28.8 32v0z" />
<glyph unicode="&#xe903;" glyph-name="borderwidth" d="M0 265.6h1024v-128h-1024v128zM0 32h1024v-64h-1024v64zM0 566.4h1024v-192h-1024v192zM0 928h1024v-256h-1024v256z" />
<glyph unicode="&#xe904;" glyph-name="line" d="M739.2 627.2l-502.4-502.4h-185.6v185.6l502.4 502.4 185.6-185.6zM803.2 688l-185.6 185.6 67.2 67.2c22.4 22.4 54.4 22.4 76.8 0l108.8-108.8c22.4-22.4 22.4-54.4 0-76.8l-67.2-67.2zM41.6 48h940.8v-112h-940.8v112z" />
<glyph unicode="&#xe905;" glyph-name="count" d="M0 480h1024v-64h-1024v64zM304 912v-339.2h-67.2v272h-67.2v67.2zM444.8 694.4v-54.4h134.4v-67.2h-201.6v153.6l134.4 64v54.4h-134.4v67.2h201.6v-153.6zM854.4 912v-339.2h-204.8v67.2h137.6v67.2h-137.6v70.4h137.6v67.2h-137.6v67.2zM115.2 166.4c3.2 57.6 38.4 83.2 108.8 83.2 38.4 0 67.2-9.6 86.4-25.6s25.6-35.2 25.6-70.4v-112c0-25.6 0-28.8 9.6-41.6h-73.6c-3.2 9.6-3.2 9.6-6.4 19.2-22.4-19.2-41.6-25.6-70.4-25.6-54.4 0-89.6 32-89.6 76.8s28.8 70.4 99.2 80l38.4 6.4c16 3.2 22.4 6.4 22.4 16 0 12.8-12.8 22.4-38.4 22.4s-41.6-9.6-44.8-28.8h-67.2zM262.4 115.2c-6.4-3.2-12.8-6.4-25.6-6.4l-25.6-6.4c-25.6-6.4-38.4-16-38.4-28.8 0-16 12.8-25.6 35.2-25.6s41.6 9.6 54.4 32v35.2zM390.4 336h73.6v-112c22.4 16 41.6 22.4 67.2 22.4 64 0 105.6-51.2 105.6-124.8 0-76.8-44.8-134.4-108.8-134.4-32 0-48 9.6-67.2 35.2v-28.8h-70.4v342.4zM460.8 121.6c0-41.6 22.4-70.4 51.2-70.4s51.2 28.8 51.2 70.4c0 44.8-19.2 70.4-51.2 70.4-28.8 0-51.2-28.8-51.2-70.4zM851.2 153.6c-3.2 22.4-19.2 35.2-44.8 35.2-32 0-51.2-25.6-51.2-70.4 0-48 19.2-73.6 51.2-73.6 25.6 0 41.6 12.8 44.8 41.6l70.4-3.2c-9.6-60.8-54.4-96-118.4-96-73.6 0-121.6 51.2-121.6 128 0 80 48 131.2 124.8 131.2 64 0 108.8-35.2 112-96h-67.2z" />
<glyph unicode="&#xe907;" glyph-name="translate" d="M553.6 304l-118.4 118.4c80 89.6 137.6 195.2 172.8 304h137.6v92.8h-326.4v92.8h-92.8v-92.8h-326.4v-92.8h518.4c-32-89.6-80-176-147.2-249.6-44.8 48-80 99.2-108.8 156.8h-92.8c35.2-76.8 80-147.2 137.6-211.2l-236.8-233.6 67.2-67.2 233.6 233.6 144-144c3.2 0 38.4 92.8 38.4 92.8zM816 540.8h-92.8l-208-560h92.8l51.2 140.8h220.8l51.2-140.8h92.8l-208 560zM691.2 214.4l76.8 201.6 76.8-201.6h-153.6z" />
<glyph unicode="&#xe908;" glyph-name="drag" d="M576 896h128v-128h-128v128zM576 640h128v-128h-128v128zM320 640h128v-128h-128v128zM576 384h128v-128h-128v128zM320 384h128v-128h-128v128zM320 128h128v-128h-128v128zM576 128h128v-128h-128v128zM320 896h128v-128h-128v128z" />
<glyph unicode="&#xe90b;" glyph-name="home" d="M1024 369.556l-512 397.426-512-397.428v162.038l512 397.426 512-397.428zM896 384v-384h-256v256h-256v-256h-256v384l384 288z" />
<glyph unicode="&#xe911;" glyph-name="books" d="M576.234 670.73l242.712 81.432 203.584-606.784-242.712-81.432zM0 64h256v704h-256v-704zM64 640h128v-64h-128v64zM320 64h256v704h-256v-704zM384 640h128v-64h-128v64z" />
<glyph unicode="&#xe914;" glyph-name="upload" d="M839.432 760.57c27.492-27.492 50.554-78.672 55.552-120.57h-318.984v318.984c41.898-4.998 93.076-28.060 120.568-55.552l142.864-142.862zM512 576v384h-368c-44 0-80-36-80-80v-864c0-44 36-80 80-80h672c44 0 80 36 80 80v560h-384zM576 192v-192h-192v192h-160l256 256 256-256h-160z" />
<glyph unicode="&#xe915;" glyph-name="editimage" d="M768 416v-352h-640v640h352l128 128h-512c-52.8 0-96-43.2-96-96v-704c0-52.8 43.2-96 96-96h704c52.798 0 96 43.2 96 96v512l-128-128zM864 960l-608-608v-160h160l608 608c0 96-64 160-160 160zM416 320l-48 48 480 480 48-48-480-480z" />
<glyph unicode="&#xe91c;" glyph-name="bubble" d="M928 896h-832c-52.8 0-96-43.2-96-96v-512c0-52.8 43.2-96 96-96h160v-256l307.2 256h364.8c52.8 0 96 43.2 96 96v512c0 52.8-43.2 96-96 96zM896 320h-379.142l-196.858-174.714v174.714h-192v448h768v-448z" />
<glyph unicode="&#xe91d;" glyph-name="user" d="M622.826 257.264c-22.11 3.518-22.614 64.314-22.614 64.314s64.968 64.316 79.128 150.802c38.090 0 61.618 91.946 23.522 124.296 1.59 34.054 48.96 267.324-190.862 267.324s-192.45-233.27-190.864-267.324c-38.094-32.35-14.57-124.296 23.522-124.296 14.158-86.486 79.128-150.802 79.128-150.802s-0.504-60.796-22.614-64.314c-71.22-11.332-337.172-128.634-337.172-257.264h896c0 128.63-265.952 245.932-337.174 257.264z" />
<glyph unicode="&#xe926;" glyph-name="lock" d="M592 512h-16v192c0 105.87-86.13 192-192 192h-128c-105.87 0-192-86.13-192-192v-192h-16c-26.4 0-48-21.6-48-48v-480c0-26.4 21.6-48 48-48h544c26.4 0 48 21.6 48 48v480c0 26.4-21.6 48-48 48zM192 704c0 35.29 28.71 64 64 64h128c35.29 0 64-28.71 64-64v-192h-256v192z" />
<glyph unicode="&#xe927;" glyph-name="unlock" d="M768 896c105.87 0 192-86.13 192-192v-192h-128v192c0 35.29-28.71 64-64 64h-128c-35.29 0-64-28.71-64-64v-192h16c26.4 0 48-21.6 48-48v-480c0-26.4-21.6-48-48-48h-544c-26.4 0-48 21.6-48 48v480c0 26.4 21.6 48 48 48h400v192c0 105.87 86.13 192 192 192h128z" />
<glyph unicode="&#xe928;" glyph-name="settings" d="M448 832v16c0 26.4-21.6 48-48 48h-160c-26.4 0-48-21.6-48-48v-16h-192v-128h192v-16c0-26.4 21.6-48 48-48h160c26.4 0 48 21.6 48 48v16h576v128h-576zM256 704v128h128v-128h-128zM832 528c0 26.4-21.6 48-48 48h-160c-26.4 0-48-21.6-48-48v-16h-576v-128h576v-16c0-26.4 21.6-48 48-48h160c26.4 0 48 21.6 48 48v16h192v128h-192v16zM640 384v128h128v-128h-128zM448 208c0 26.4-21.6 48-48 48h-160c-26.4 0-48-21.6-48-48v-16h-192v-128h192v-16c0-26.4 21.6-48 48-48h160c26.4 0 48 21.6 48 48v16h576v128h-576v16zM256 64v128h128v-128h-128z" />
<glyph unicode="&#xe92a;" glyph-name="remove2" d="M192-64h640l64 704h-768zM640 832v128h-256v-128h-320v-192l64 64h768l64-64v192h-320zM576 832h-128v64h128v-64z" />
<glyph unicode="&#xe92d;" glyph-name="menu" d="M384 896h256v-256h-256zM384 576h256v-256h-256zM384 256h256v-256h-256z" />
<glyph unicode="&#xe930;" glyph-name="warning" d="M1009.956 44.24l-437.074 871.112c-16.742 29.766-38.812 44.648-60.882 44.648s-44.14-14.882-60.884-44.648l-437.074-871.112c-33.486-59.532-5-108.24 63.304-108.24h869.308c68.302 0 96.792 48.708 63.302 108.24zM512 64c-35.346 0-64 28.654-64 64 0 35.348 28.654 64 64 64 35.348 0 64-28.652 64-64 0-35.346-28.652-64-64-64zM556 256h-88l-20 256c0 35.346 28.654 64 64 64s64-28.654 64-64l-20-256z" />
<glyph unicode="&#xe931;" glyph-name="question" d="M448 256h128v-128h-128zM704 704c35.346 0 64-28.654 64-64v-192l-192-128h-128v64l192 128v64h-320v128h384zM512 864c-111.118 0-215.584-43.272-294.156-121.844s-121.844-183.038-121.844-294.156c0-111.118 43.272-215.584 121.844-294.156s183.038-121.844 294.156-121.844c111.118 0 215.584 43.272 294.156 121.844s121.844 183.038 121.844 294.156c0 111.118-43.272 215.584-121.844 294.156s-183.038 121.844-294.156 121.844zM512 960v0c282.77 0 512-229.23 512-512s-229.23-512-512-512c-282.77 0-512 229.23-512 512s229.23 512 512 512z" />
<glyph unicode="&#xe932;" glyph-name="pluscircle" d="M512 960c-282.77 0-512-229.23-512-512s229.23-512 512-512 512 229.23 512 512-229.23 512-512 512zM512 64c-212.078 0-384 171.922-384 384s171.922 384 384 384c212.078 0 384-171.922 384-384s-171.922-384-384-384zM768 384h-192v-192h-128v192h-192v128h192v192h128v-192h192z" />
<glyph unicode="&#xe933;" glyph-name="info" d="M512 960c-282.77 0-512-229.23-512-512s229.23-512 512-512 512 229.23 512 512-229.23 512-512 512zM448 768h128v-128h-128v128zM640 128h-256v64h64v256h-64v64h192v-320h64v-64z" />
<glyph unicode="&#xe934;" glyph-name="notice" d="M1024 224l-288 736h-448l-288-288v-448l288-288h448l288 288v448l-288 288zM576 128h-128v128h128v-128zM576 384h-128v384h128v-384z" />
<glyph unicode="&#xe935;" glyph-name="drop" d="M864.626 486.838c-65.754 183.44-205.11 348.15-352.626 473.162-147.516-125.012-286.87-289.722-352.626-473.162-40.664-113.436-44.682-236.562 12.584-345.4 65.846-125.14 198.632-205.438 340.042-205.438s274.196 80.298 340.040 205.44c57.27 108.838 53.25 231.962 12.586 345.398zM738.764 201.044c-43.802-83.252-132.812-137.044-226.764-137.044-55.12 0-108.524 18.536-152.112 50.652 13.242-1.724 26.632-2.652 40.112-2.652 117.426 0 228.668 67.214 283.402 171.242 44.878 85.292 40.978 173.848 23.882 244.338 14.558-28.15 26.906-56.198 36.848-83.932 22.606-63.062 40.024-156.34-5.368-242.604z" />
<glyph unicode="&#xe939;" glyph-name="minus" d="M0 544v-192c0-17.672 14.328-32 32-32h960c17.672 0 32 14.328 32 32v192c0 17.672-14.328 32-32 32h-960c-17.672 0-32-14.328-32-32z" />
<glyph unicode="&#xe93a;" glyph-name="plus" d="M992 576h-352v352c0 17.672-14.328 32-32 32h-192c-17.672 0-32-14.328-32-32v-352h-352c-17.672 0-32-14.328-32-32v-192c0-17.672 14.328-32 32-32h352v-352c0-17.672 14.328-32 32-32h192c17.672 0 32 14.328 32 32v352h352c17.672 0 32 14.328 32 32v192c0 17.672-14.328 32-32 32z" />
<glyph unicode="&#xe93b;" glyph-name="arrowup" d="M0 320l192-192 320 320 320-320 192 192-511.998 512z" />
<glyph unicode="&#xe93c;" glyph-name="arrowright" d="M384 960l-192-192 320-320-320-320 192-192 512 512z" />
<glyph unicode="&#xe93d;" glyph-name="arrowdown" d="M1024 576l-192 192-320-320-320 320-192-192 512-511.998z" />
<glyph unicode="&#xe93f;" glyph-name="arrowup2" d="M768 320l-256 256-256-256z" />
<glyph unicode="&#xe940;" glyph-name="arrowdown2" d="M256 576l256-256 256 256z" />
<glyph unicode="&#xe941;" glyph-name="menu2" d="M256 704l256-256 256 256zM255.996 384.004l256-256 256 256z" />
<glyph unicode="&#xe961;" glyph-name="newtab" d="M704 384l128 128v-512h-768v768h512l-128-128h-256v-512h512zM960 896v-352l-130.744 130.744-354.746-354.744h-90.51v90.512l354.744 354.744-130.744 130.744z" />
<glyph unicode="&#xeaa8;" glyph-name="rotateleft" d="M607.998 831.986c-212.070 0-383.986-171.916-383.986-383.986h-191.994l246.848-246.848 246.848 246.848h-191.994c0 151.478 122.798 274.276 274.276 274.276 151.48 0 274.276-122.798 274.276-274.276 0-151.48-122.796-274.276-274.276-274.276v-109.71c212.070 0 383.986 171.916 383.986 383.986s-171.916 383.986-383.986 383.986z" /> <glyph unicode="&#xeaa8;" glyph-name="rotateleft" d="M607.998 831.986c-212.070 0-383.986-171.916-383.986-383.986h-191.994l246.848-246.848 246.848 246.848h-191.994c0 151.478 122.798 274.276 274.276 274.276 151.48 0 274.276-122.798 274.276-274.276 0-151.48-122.796-274.276-274.276-274.276v-109.71c212.070 0 383.986 171.916 383.986 383.986s-171.916 383.986-383.986 383.986z" />
<glyph unicode="&#xeaa9;" glyph-name="rotateright" d="M416.002 831.986c212.070 0 383.986-171.916 383.986-383.986h191.994l-246.848-246.848-246.848 246.848h191.994c0 151.478-122.798 274.276-274.276 274.276-151.48 0-274.276-122.798-274.276-274.276 0-151.48 122.796-274.276 274.276-274.276v-109.71c-212.070 0-383.986 171.916-383.986 383.986s171.916 383.986 383.986 383.986z" /> <glyph unicode="&#xeaa9;" glyph-name="rotateright" d="M416.002 831.986c212.070 0 383.986-171.916 383.986-383.986h191.994l-246.848-246.848-246.848 246.848h191.994c0 151.478-122.798 274.276-274.276 274.276-151.48 0-274.276-122.798-274.276-274.276 0-151.48 122.796-274.276 274.276-274.276v-109.71c-212.070 0-383.986 171.916-383.986 383.986s171.916 383.986 383.986 383.986z" />
<glyph unicode="&#xeaaa;" glyph-name="flipv" d="M0 576h1024v384zM1024 0v384h-1024z" /> <glyph unicode="&#xeaaa;" glyph-name="flipv" d="M0 576h1024v384zM1024 0v384h-1024z" />
@ -91,8 +122,8 @@
<glyph unicode="&#xeccc;" glyph-name="sun" d="M512 128c35.346 0 64-28.654 64-64v-64c0-35.346-28.654-64-64-64s-64 28.654-64 64v64c0 35.346 28.654 64 64 64zM512 768c-35.346 0-64 28.654-64 64v64c0 35.346 28.654 64 64 64s64-28.654 64-64v-64c0-35.346-28.654-64-64-64zM960 512c35.346 0 64-28.654 64-64s-28.654-64-64-64h-64c-35.348 0-64 28.654-64 64s28.652 64 64 64h64zM192 448c0-35.346-28.654-64-64-64h-64c-35.346 0-64 28.654-64 64s28.654 64 64 64h64c35.346 0 64-28.654 64-64zM828.784 221.726l45.256-45.258c24.992-24.99 24.992-65.516 0-90.508-24.994-24.992-65.518-24.992-90.51 0l-45.256 45.256c-24.992 24.99-24.992 65.516 0 90.51 24.994 24.992 65.518 24.992 90.51 0zM195.216 674.274l-45.256 45.256c-24.994 24.994-24.994 65.516 0 90.51s65.516 24.994 90.51 0l45.256-45.256c24.994-24.994 24.994-65.516 0-90.51s-65.516-24.994-90.51 0zM828.784 674.274c-24.992-24.992-65.516-24.992-90.51 0-24.992 24.994-24.992 65.516 0 90.51l45.256 45.254c24.992 24.994 65.516 24.994 90.51 0 24.992-24.994 24.992-65.516 0-90.51l-45.256-45.254zM195.216 221.726c24.992 24.992 65.518 24.992 90.508 0 24.994-24.994 24.994-65.52 0-90.51l-45.254-45.256c-24.994-24.992-65.516-24.992-90.51 0s-24.994 65.518 0 90.508l45.256 45.258zM512 704c-141.384 0-256-114.616-256-256 0-141.382 114.616-256 256-256 141.382 0 256 114.618 256 256 0 141.384-114.616 256-256 256zM512 288c-88.366 0-160 71.634-160 160s71.634 160 160 160 160-71.634 160-160-71.634-160-160-160z" /> <glyph unicode="&#xeccc;" glyph-name="sun" d="M512 128c35.346 0 64-28.654 64-64v-64c0-35.346-28.654-64-64-64s-64 28.654-64 64v64c0 35.346 28.654 64 64 64zM512 768c-35.346 0-64 28.654-64 64v64c0 35.346 28.654 64 64 64s64-28.654 64-64v-64c0-35.346-28.654-64-64-64zM960 512c35.346 0 64-28.654 64-64s-28.654-64-64-64h-64c-35.348 0-64 28.654-64 64s28.652 64 64 64h64zM192 448c0-35.346-28.654-64-64-64h-64c-35.346 0-64 28.654-64 64s28.654 64 64 64h64c35.346 0 64-28.654 64-64zM828.784 221.726l45.256-45.258c24.992-24.99 24.992-65.516 0-90.508-24.994-24.992-65.518-24.992-90.51 0l-45.256 45.256c-24.992 24.99-24.992 65.516 0 90.51 24.994 24.992 65.518 24.992 90.51 0zM195.216 674.274l-45.256 45.256c-24.994 24.994-24.994 65.516 0 90.51s65.516 24.994 90.51 0l45.256-45.256c24.994-24.994 24.994-65.516 0-90.51s-65.516-24.994-90.51 0zM828.784 674.274c-24.992-24.992-65.516-24.992-90.51 0-24.992 24.994-24.992 65.516 0 90.51l45.256 45.254c24.992 24.994 65.516 24.994 90.51 0 24.992-24.994 24.992-65.516 0-90.51l-45.256-45.254zM195.216 221.726c24.992 24.992 65.518 24.992 90.508 0 24.994-24.994 24.994-65.52 0-90.51l-45.254-45.256c-24.994-24.992-65.516-24.992-90.51 0s-24.994 65.518 0 90.508l45.256 45.258zM512 704c-141.384 0-256-114.616-256-256 0-141.382 114.616-256 256-256 141.382 0 256 114.618 256 256 0 141.384-114.616 256-256 256zM512 288c-88.366 0-160 71.634-160 160s71.634 160 160 160 160-71.634 160-160-71.634-160-160-160z" />
<glyph unicode="&#xeccd;" glyph-name="moon" d="M715.812 895.52c-60.25 34.784-124.618 55.904-189.572 64.48 122.936-160.082 144.768-384.762 37.574-570.42-107.2-185.67-312.688-279.112-512.788-252.68 39.898-51.958 90.376-97.146 150.628-131.934 245.908-141.974 560.37-57.72 702.344 188.198 141.988 245.924 57.732 560.372-188.186 702.356z" /> <glyph unicode="&#xeccd;" glyph-name="moon" d="M715.812 895.52c-60.25 34.784-124.618 55.904-189.572 64.48 122.936-160.082 144.768-384.762 37.574-570.42-107.2-185.67-312.688-279.112-512.788-252.68 39.898-51.958 90.376-97.146 150.628-131.934 245.908-141.974 560.37-57.72 702.344 188.198 141.988 245.924 57.732 560.372-188.186 702.356z" />
<glyph unicode="&#xecd4;" glyph-name="contrast" d="M512 960c-282.77 0-512-229.23-512-512s229.23-512 512-512 512 229.23 512 512-229.23 512-512 512zM128 448c0 212.078 171.922 384 384 384v-768c-212.078 0-384 171.922-384 384z" /> <glyph unicode="&#xecd4;" glyph-name="contrast" d="M512 960c-282.77 0-512-229.23-512-512s229.23-512 512-512 512 229.23 512 512-229.23 512-512 512zM128 448c0 212.078 171.922 384 384 384v-768c-212.078 0-384 171.922-384 384z" />
<glyph unicode="&#xed6a;" glyph-name="cross2" d="M893.254 738.746l-90.508 90.508-290.746-290.744-290.746 290.744-90.508-90.506 290.746-290.748-290.746-290.746 90.508-90.508 290.746 290.746 290.746-290.746 90.508 90.51-290.744 290.744z" /> <glyph unicode="&#xed6a;" glyph-name="remove22" d="M893.254 738.746l-90.508 90.508-290.746-290.744-290.746 290.744-90.508-90.506 290.746-290.748-290.746-290.746 90.508-90.508 290.746 290.746 290.746-290.746 90.508 90.51-290.744 290.744z" />
<glyph unicode="&#xedc0;" glyph-name="arrowleft" d="M672-64l192 192-320 320 320 320-192 192-512-512z" /> <glyph unicode="&#xedc0;" glyph-name="arrowleft" d="M672-64l192 192-320 320 320 320-192 192-512-512z" />
<glyph unicode="&#xedf9;" glyph-name="arrow-resize2" d="M0 896v-384c0-35.346 28.654-64 64-64s64 28.654 64 64v229.488l677.488-677.488h-229.488c-35.346 0-64-28.652-64-64 0-35.346 28.654-64 64-64h384c35.346 0 64 28.654 64 64v384c0 35.348-28.654 64-64 64s-64-28.652-64-64v-229.488l-677.488 677.488h229.488c35.346 0 64 28.654 64 64s-28.652 64-64 64h-384c-35.346 0-64-28.654-64-64z" /> <glyph unicode="&#xedf9;" glyph-name="resize2" d="M0 896v-384c0-35.346 28.654-64 64-64s64 28.654 64 64v229.488l677.488-677.488h-229.488c-35.346 0-64-28.652-64-64 0-35.346 28.654-64 64-64h384c35.346 0 64 28.654 64 64v384c0 35.348-28.654 64-64 64s-64-28.652-64-64v-229.488l-677.488 677.488h229.488c35.346 0 64 28.654 64 64s-28.652 64-64 64h-384c-35.346 0-64-28.654-64-64z" />
<glyph unicode="&#xee78;" glyph-name="crop" d="M832 704l192 192-64 64-192-192h-448v192h-128v-192h-192v-128h192v-512h512v-192h128v192h192v128h-192v448zM320 640h320l-320-320v320zM384 256l320 320v-320h-320z" /> <glyph unicode="&#xee78;" glyph-name="crop" d="M832 704l192 192-64 64-192-192h-448v192h-128v-192h-192v-128h192v-512h512v-192h128v192h192v128h-192v448zM320 640h320l-320-320v320zM384 256l320 320v-320h-320z" />
</font></defs></svg> </font></defs></svg>

Before

Width:  |  Height:  |  Size: 36 KiB

After

Width:  |  Height:  |  Size: 44 KiB

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -589,6 +589,18 @@ tinymce.ThemeManager.add('modern', function(editor) {
}); });
} }
function fireSkinLoaded(editor) {
return function() {
if (editor.initialized) {
editor.fire('SkinLoaded');
} else {
editor.on('init', function() {
editor.fire('SkinLoaded');
});
}
};
}
/** /**
* Renders the inline editor UI. * Renders the inline editor UI.
* *
@ -709,9 +721,7 @@ tinymce.ThemeManager.add('modern', function(editor) {
// Preload skin css // Preload skin css
if (args.skinUiCss) { if (args.skinUiCss) {
tinymce.DOM.styleSheetLoader.load(args.skinUiCss, function() { tinymce.DOM.styleSheetLoader.load(args.skinUiCss, fireSkinLoaded(editor));
editor.fire('SkinLoaded');
});
} }
return {}; return {};
@ -737,9 +747,7 @@ tinymce.ThemeManager.add('modern', function(editor) {
} }
if (args.skinUiCss) { if (args.skinUiCss) {
tinymce.DOM.styleSheetLoader.load(args.skinUiCss, function() { tinymce.DOM.styleSheetLoader.load(args.skinUiCss, fireSkinLoaded(editor));
editor.fire('SkinLoaded');
});
} }
// Basic UI layout // Basic UI layout

File diff suppressed because one or more lines are too long

View File

@ -1,4 +1,4 @@
// 4.3.4 (2016-02-11) // 4.3.6 (2016-03-01)
/** /**
* Compiled inline version. (Library mode) * Compiled inline version. (Library mode)
@ -15752,11 +15752,16 @@ define("tinymce/dom/ControlSelection", [
var throttledUpdateResizeRect = Delay.throttle(updateResizeRect); var throttledUpdateResizeRect = Delay.throttle(updateResizeRect);
editor.on('nodechange ResizeEditor ResizeWindow drop', throttledUpdateResizeRect); editor.on('nodechange ResizeEditor ResizeWindow drop', function(e) {
if (!editor.composing) {
throttledUpdateResizeRect(e);
}
});
// Update resize rect while typing in a table // Update resize rect while typing in a table
editor.on('keydown keyup', function(e) { editor.on('keydown keyup compositionend', function(e) {
if (selectedElm && selectedElm.nodeName == "TABLE") { // Don't update the resize rect while composing since it blows away the IME see: #2710
if (selectedElm && selectedElm.nodeName == "TABLE" && !editor.composing) {
throttledUpdateResizeRect(e); throttledUpdateResizeRect(e);
} }
}); });
@ -22694,6 +22699,10 @@ define("tinymce/EditorCommands", [
} }
} }
function canHaveChildren(node) {
return node && !editor.schema.getShortEndedElements()[node.nodeName];
}
function moveSelectionToMarker(marker) { function moveSelectionToMarker(marker) {
var parentEditableFalseElm; var parentEditableFalseElm;
@ -22786,7 +22795,7 @@ define("tinymce/EditorCommands", [
var caretElement = rng.startContainer || (rng.parentElement ? rng.parentElement() : null); var caretElement = rng.startContainer || (rng.parentElement ? rng.parentElement() : null);
var body = editor.getBody(); var body = editor.getBody();
if (caretElement === body && selection.isCollapsed()) { if (caretElement === body && selection.isCollapsed()) {
if (dom.isBlock(body.firstChild) && dom.isEmpty(body.firstChild)) { if (dom.isBlock(body.firstChild) && canHaveChildren(body.firstChild) && dom.isEmpty(body.firstChild)) {
rng = dom.createRng(); rng = dom.createRng();
rng.setStart(body.firstChild, 0); rng.setStart(body.firstChild, 0);
rng.setEnd(body.firstChild, 0); rng.setEnd(body.firstChild, 0);
@ -23700,8 +23709,6 @@ define("tinymce/util/Class", [
// Add mixins // Add mixins
if (prop.Mixins) { if (prop.Mixins) {
each(prop.Mixins, function(mixin) { each(prop.Mixins, function(mixin) {
mixin = mixin;
for (var name in mixin) { for (var name in mixin) {
if (name !== "init") { if (name !== "init") {
prop[name] = mixin[name]; prop[name] = mixin[name];
@ -24563,7 +24570,7 @@ define("tinymce/ui/Selector", [
return uniqueItems; return uniqueItems;
} }
var expression = /^([\w\\*]+)?(?:#([\w\\]+))?(?:\.([\w\\\.]+))?(?:\[\@?([\w\\]+)([\^\$\*!~]?=)([\w\\]+)\])?(?:\:(.+))?/i; var expression = /^([\w\\*]+)?(?:#([\w\-\\]+))?(?:\.([\w\\\.]+))?(?:\[\@?([\w\\]+)([\^\$\*!~]?=)([\w\\]+)\])?(?:\:(.+))?/i;
/*jshint maxlen:255 */ /*jshint maxlen:255 */
/*eslint max-len:0 */ /*eslint max-len:0 */
@ -26182,6 +26189,20 @@ define("tinymce/ui/Control", [
self.fire('repaint', {}, false); self.fire('repaint', {}, false);
}, },
/**
* Updates the controls layout rect by re-measuing it.
*/
updateLayoutRect: function() {
var self = this;
self.parent()._lastRect = null;
DomUtils.css(self.getEl(), {width: '', height: ''});
self._layoutRect = self._lastRepaintRect = self._lastLayoutRect = null;
self.initLayoutRect();
},
/** /**
* Binds a callback to the specified event. This event can both be * Binds a callback to the specified event. This event can both be
* native browser events like "click" or custom ones like PostRender. * native browser events like "click" or custom ones like PostRender.
@ -27250,7 +27271,7 @@ define("tinymce/ui/KeyboardNavigation", [
// Notice: since type can be "email" etc we don't check the type // Notice: since type can be "email" etc we don't check the type
// So all input elements gets treated as text input elements // So all input elements gets treated as text input elements
return tagName == "INPUT" || tagName == "TEXTAREA"; return tagName == "INPUT" || tagName == "TEXTAREA" || tagName == "SELECT";
} }
/** /**
@ -29269,7 +29290,9 @@ define("tinymce/ui/Window", [
} }
self.on('click', function(e) { self.on('click', function(e) {
if (e.target.className.indexOf(self.classPrefix + 'close') != -1) { var closeClass = self.classPrefix + 'close';
if (e.target.className.indexOf(closeClass) != -1 || e.target.parentNode.className.indexOf(closeClass) != -1) {
self.close(); self.close();
} }
}); });
@ -29387,8 +29410,10 @@ define("tinymce/ui/Window", [
headerHtml = ( headerHtml = (
'<div id="' + id + '-head" class="' + prefix + 'window-head">' + '<div id="' + id + '-head" class="' + prefix + 'window-head">' +
'<div id="' + id + '-title" class="' + prefix + 'title">' + self.encode(settings.title) + '</div>' + '<div id="' + id + '-title" class="' + prefix + 'title">' + self.encode(settings.title) + '</div>' +
'<button type="button" class="' + prefix + 'close" aria-hidden="true">\u00d7</button>' +
'<div id="' + id + '-dragh" class="' + prefix + 'dragh"></div>' + '<div id="' + id + '-dragh" class="' + prefix + 'dragh"></div>' +
'<button type="button" class="' + prefix + 'close" aria-hidden="true">' +
'<i class="mce-ico mce-i-remove"></i>' +
'</button>' +
'</div>' '</div>'
); );
} }
@ -29892,7 +29917,9 @@ define("tinymce/WindowManager", [
args.items = { args.items = {
defaults: args.defaults, defaults: args.defaults,
type: args.bodyType || 'form', type: args.bodyType || 'form',
items: args.body items: args.body,
data: args.data,
callbacks: args.commands
}; };
} }
@ -30403,8 +30430,9 @@ define("tinymce/ui/Progress", [
define("tinymce/ui/Notification", [ define("tinymce/ui/Notification", [
"tinymce/ui/Control", "tinymce/ui/Control",
"tinymce/ui/Movable", "tinymce/ui/Movable",
"tinymce/ui/Progress" "tinymce/ui/Progress",
], function(Control, Movable, Progress) { "tinymce/util/Delay"
], function(Control, Movable, Progress, Delay) {
return Control.extend({ return Control.extend({
Mixins: [Movable], Mixins: [Movable],
@ -30486,6 +30514,16 @@ define("tinymce/ui/Notification", [
); );
}, },
postRender: function() {
var self = this;
Delay.setTimeout(function() {
self.$el.addClass(self.classPrefix + 'in');
});
return self._super();
},
bindStates: function() { bindStates: function() {
var self = this; var self = this;
@ -30955,7 +30993,7 @@ define("tinymce/util/Quirks", [
return false; return false;
} }
for (node = node; node != rootNode && !blockElements[node.nodeName]; node = node.parentNode) { for (; node != rootNode && !blockElements[node.nodeName]; node = node.parentNode) {
if (node.nextSibling) { if (node.nextSibling) {
return false; return false;
} }
@ -32966,6 +33004,11 @@ define("tinymce/file/Uploader", [
notification.progressBar.value(percentLoaded); notification.progressBar.value(percentLoaded);
}; };
xhr.onerror = function() {
notification.close();
failure("Image upload failed due to a XHR Transport error. Code: " + xhr.status);
};
xhr.onload = function() { xhr.onload = function() {
var json; var json;
@ -33026,6 +33069,7 @@ define("tinymce/file/Uploader", [
return new Promise(function(resolve) { return new Promise(function(resolve) {
var handler = settings.handler; var handler = settings.handler;
try {
handler(blobInfoToData(blobInfo), function(url) { handler(blobInfoToData(blobInfo), function(url) {
resolve({ resolve({
url: url, url: url,
@ -33040,6 +33084,14 @@ define("tinymce/file/Uploader", [
error: failure error: failure
}); });
}, openNotification); }, openNotification);
} catch (ex) {
resolve({
url: '',
blobInfo: blobInfo,
status: false,
error: ex.message
});
}
}); });
} }
@ -33491,12 +33543,14 @@ define("tinymce/EditorUpload", [
result = Arr.map(result, function(uploadInfo, index) { result = Arr.map(result, function(uploadInfo, index) {
var image = imageInfos[index].image; var image = imageInfos[index].image;
if (uploadInfo.status) {
replaceUrlInUndoStack(image.src, uploadInfo.url); replaceUrlInUndoStack(image.src, uploadInfo.url);
editor.$(image).attr({ editor.$(image).attr({
src: uploadInfo.url, src: uploadInfo.url,
'data-mce-src': editor.convertURL(uploadInfo.url, 'src') 'data-mce-src': editor.convertURL(uploadInfo.url, 'src')
}); });
}
return { return {
element: image, element: image,
@ -34813,13 +34867,24 @@ define("tinymce/DragDropOverrides", [
} }
function drop() { function drop() {
var evt;
if (state.dragging) { if (state.dragging) {
// Hack for IE since it doesn't sync W3C Range with IE Specific range // Hack for IE since it doesn't sync W3C Range with IE Specific range
editor.selection.setRng(editor.selection.getSel().getRangeAt(0)); editor.selection.setRng(editor.selection.getSel().getRangeAt(0));
if (isValidDropTarget(editor.selection.getNode())) { if (isValidDropTarget(editor.selection.getNode())) {
var targetClone = state.element;
evt = editor.fire('drop', {targetClone: targetClone});
if (evt.isDefaultPrevented()) {
return;
}
targetClone = evt.targetClone;
editor.undoManager.transact(function() { editor.undoManager.transact(function() {
editor.insertContent(dom.getOuterHTML(state.element)); editor.insertContent(dom.getOuterHTML(targetClone));
$(state.element).remove(); $(state.element).remove();
}); });
} }
@ -34829,7 +34894,7 @@ define("tinymce/DragDropOverrides", [
} }
function start(e) { function start(e) {
var ceElm; var ceElm, evt;
stop(); stop();
@ -34840,7 +34905,8 @@ define("tinymce/DragDropOverrides", [
ceElm = Arr.find(editor.dom.getParents(e.target), Fun.or(isContentEditableFalse, isContentEditableTrue)); ceElm = Arr.find(editor.dom.getParents(e.target), Fun.or(isContentEditableFalse, isContentEditableTrue));
if (isDraggable(ceElm)) { if (isDraggable(ceElm)) {
if (editor.fire('dragstart', {target: ceElm}).isDefaultPrevented()) { evt = editor.fire('dragstart', {target: ceElm});
if (evt.isDefaultPrevented()) {
return; return;
} }
@ -34912,7 +34978,7 @@ define("tinymce/DragDropOverrides", [
* *
* @example * @example
* // Disable the default cE=false selection * // Disable the default cE=false selection
* tinymce.activeEditor.on('ShowCaret ObjectSelected', function(e) { * tinymce.activeEditor.on('ShowCaret BeforeObjectSelected', function(e) {
* e.preventDefault(); * e.preventDefault();
* }); * });
* *
@ -34935,10 +35001,11 @@ define("tinymce/SelectionOverrides", [
"tinymce/util/Fun", "tinymce/util/Fun",
"tinymce/util/Arr", "tinymce/util/Arr",
"tinymce/util/Delay", "tinymce/util/Delay",
"tinymce/DragDropOverrides" "tinymce/DragDropOverrides",
"tinymce/text/Zwsp"
], function( ], function(
Env, CaretWalker, CaretPosition, CaretContainer, CaretUtils, FakeCaret, LineWalker, Env, CaretWalker, CaretPosition, CaretContainer, CaretUtils, FakeCaret, LineWalker,
LineUtils, NodeType, RangeUtils, ClientRect, VK, Fun, Arr, Delay, DragDropOverrides LineUtils, NodeType, RangeUtils, ClientRect, VK, Fun, Arr, Delay, DragDropOverrides, Zwsp
) { ) {
var curry = Fun.curry, var curry = Fun.curry,
isContentEditableTrue = NodeType.isContentEditableTrue, isContentEditableTrue = NodeType.isContentEditableTrue,
@ -35006,12 +35073,13 @@ define("tinymce/SelectionOverrides", [
function selectNode(node) { function selectNode(node) {
var e; var e;
e = editor.fire('ObjectSelected', {target: node}); fakeCaret.hide();
e = editor.fire('BeforeObjectSelected', {target: node});
if (e.isDefaultPrevented()) { if (e.isDefaultPrevented()) {
return null; return null;
} }
fakeCaret.hide();
return getNodeRange(node); return getNodeRange(node);
} }
@ -35235,7 +35303,7 @@ define("tinymce/SelectionOverrides", [
} }
function renderCaretAtRange(range) { function renderCaretAtRange(range) {
var caretPosition; var caretPosition, ceRoot;
range = CaretUtils.normalizeRange(1, rootNode, range); range = CaretUtils.normalizeRange(1, rootNode, range);
caretPosition = CaretPosition.fromRangeStart(range); caretPosition = CaretPosition.fromRangeStart(range);
@ -35248,6 +35316,12 @@ define("tinymce/SelectionOverrides", [
return showCaret(1, caretPosition.getNode(true), false); return showCaret(1, caretPosition.getNode(true), false);
} }
// TODO: Should render caret before/after depending on where you click on the page forces after now
ceRoot = editor.dom.getParent(caretPosition.getNode(), Fun.or(isContentEditableFalse, isContentEditableTrue));
if (isContentEditableFalse(ceRoot)) {
return showCaret(1, ceRoot, false);
}
fakeCaret.hide(); fakeCaret.hide();
return null; return null;
@ -35393,8 +35467,10 @@ define("tinymce/SelectionOverrides", [
if (contentEditableRoot) { if (contentEditableRoot) {
if (isContentEditableFalse(contentEditableRoot)) { if (isContentEditableFalse(contentEditableRoot)) {
e.preventDefault(); e.preventDefault();
setContentEditableSelection(selectNode(contentEditableRoot), false); setContentEditableSelection(selectNode(contentEditableRoot));
} else { } else {
clearContentEditableSelection();
if (!isXYWithinRange(e.clientX, e.clientY, editor.selection.getRng())) { if (!isXYWithinRange(e.clientX, e.clientY, editor.selection.getRng())) {
editor.selection.placeCaretAt(e.clientX, e.clientY); editor.selection.placeCaretAt(e.clientX, e.clientY);
} }
@ -35541,7 +35617,7 @@ define("tinymce/SelectionOverrides", [
// Make sure we have a proper fake caret on focus // Make sure we have a proper fake caret on focus
Delay.setEditorTimeout(editor, function() { Delay.setEditorTimeout(editor, function() {
editor.selection.setRng(renderRangeCaret(editor.selection.getRng())); editor.selection.setRng(renderRangeCaret(editor.selection.getRng()));
}); }, 0);
}); });
DragDropOverrides.init(editor); DragDropOverrides.init(editor);
@ -35571,9 +35647,9 @@ define("tinymce/SelectionOverrides", [
return CaretContainer.isCaretContainer(rng.startContainer) || CaretContainer.isCaretContainer(rng.endContainer); return CaretContainer.isCaretContainer(rng.startContainer) || CaretContainer.isCaretContainer(rng.endContainer);
} }
function setContentEditableSelection(range, fireEvent) { function setContentEditableSelection(range) {
var node, $ = editor.$, dom = editor.dom, $realSelectionContainer, sel, var node, $ = editor.$, dom = editor.dom, $realSelectionContainer, sel,
startContainer, startOffset, endOffset, e, caretPosition; startContainer, startOffset, endOffset, e, caretPosition, targetClone, origTargetClone;
if (!range) { if (!range) {
clearContentEditableSelection(); clearContentEditableSelection();
@ -35618,15 +35694,19 @@ define("tinymce/SelectionOverrides", [
node = startContainer.childNodes[startOffset]; node = startContainer.childNodes[startOffset];
} }
if (isContentEditableFalse(node)) { if (!isContentEditableFalse(node)) {
if (fireEvent !== false) { clearContentEditableSelection();
e = editor.fire('ObjectSelected', {target: node}); return null;
}
targetClone = origTargetClone = node.cloneNode(true);
e = editor.fire('ObjectSelected', {target: node, targetClone: targetClone});
if (e.isDefaultPrevented()) { if (e.isDefaultPrevented()) {
clearContentEditableSelection(); clearContentEditableSelection();
return null; return null;
} }
}
targetClone = e.targetClone;
$realSelectionContainer = $('#' + realSelectionId); $realSelectionContainer = $('#' + realSelectionId);
if ($realSelectionContainer.length === 0) { if ($realSelectionContainer.length === 0) {
$realSelectionContainer = $( $realSelectionContainer = $(
@ -35636,13 +35716,22 @@ define("tinymce/SelectionOverrides", [
$realSelectionContainer.appendTo(editor.getBody()); $realSelectionContainer.appendTo(editor.getBody());
} }
$realSelectionContainer.empty().append('\u00a0').append(node.cloneNode(true)).append('\u00a0').css({
top: dom.getPos(node, editor.getBody()).y
});
range = editor.dom.createRng(); range = editor.dom.createRng();
// WHY is IE making things so hard! Copy on <i contentEditable="false">x</i> produces: <em>x</em>
if (targetClone === origTargetClone && Env.ie) {
$realSelectionContainer.empty().append(Zwsp.ZWSP).append(targetClone).append(Zwsp.ZWSP);
range.setStart($realSelectionContainer[0].firstChild, 0);
range.setEnd($realSelectionContainer[0].lastChild, 1);
} else {
$realSelectionContainer.empty().append('\u00a0').append(targetClone).append('\u00a0');
range.setStart($realSelectionContainer[0].firstChild, 1); range.setStart($realSelectionContainer[0].firstChild, 1);
range.setEnd($realSelectionContainer[0].lastChild, 0); range.setEnd($realSelectionContainer[0].lastChild, 0);
}
$realSelectionContainer.css({
top: dom.getPos(node, editor.getBody()).y
});
editor.getBody().focus(); editor.getBody().focus();
$realSelectionContainer[0].focus(); $realSelectionContainer[0].focus();
@ -35657,10 +35746,6 @@ define("tinymce/SelectionOverrides", [
return range; return range;
} }
clearContentEditableSelection();
return null;
}
function clearContentEditableSelection() { function clearContentEditableSelection() {
if (selectedContentEditableNode) { if (selectedContentEditableNode) {
selectedContentEditableNode.removeAttribute('data-mce-selected'); selectedContentEditableNode.removeAttribute('data-mce-selected');
@ -36712,6 +36797,10 @@ define("tinymce/Editor", [
self.nodeChanged({initial: true}); self.nodeChanged({initial: true});
self.execCallback('init_instance_callback', self); self.execCallback('init_instance_callback', self);
self.on('compositionstart compositionend', function(e) {
self.composing = e.type === 'compositionstart';
});
// Add editor specific CSS styles // Add editor specific CSS styles
if (self.contentStyles.length > 0) { if (self.contentStyles.length > 0) {
contentCssText = ''; contentCssText = '';
@ -38413,7 +38502,7 @@ define("tinymce/EditorManager", [
* @property minorVersion * @property minorVersion
* @type String * @type String
*/ */
minorVersion: '3.4', minorVersion: '3.6',
/** /**
* Release date of TinyMCE build. * Release date of TinyMCE build.
@ -38421,7 +38510,7 @@ define("tinymce/EditorManager", [
* @property releaseDate * @property releaseDate
* @type String * @type String
*/ */
releaseDate: '2016-02-11', releaseDate: '2016-03-01',
/** /**
* Collection of editor instances. * Collection of editor instances.
@ -38586,7 +38675,7 @@ define("tinymce/EditorManager", [
* }); * });
*/ */
init: function(settings) { init: function(settings) {
var self = this; var self = this, result;
function createId(elm) { function createId(elm) {
var id = elm.id; var id = elm.id;
@ -38629,10 +38718,12 @@ define("tinymce/EditorManager", [
each(settings.types, function(type) { each(settings.types, function(type) {
targets = targets.concat(DOM.select(type.selector)); targets = targets.concat(DOM.select(type.selector));
}); });
return targets;
} else if (settings.selector) { } else if (settings.selector) {
targets = DOM.select(settings.selector); return DOM.select(settings.selector);
} else if (settings.target) { } else if (settings.target) {
targets = [settings.target]; return [settings.target];
} }
// Fallback to old setting // Fallback to old setting
@ -38678,7 +38769,11 @@ define("tinymce/EditorManager", [
return targets; return targets;
} }
function initEditors(resolve, readyHandler) { var provideResults = function(editors) {
result = editors;
};
function initEditors() {
var initCount = 0, editors = [], targets; var initCount = 0, editors = [], targets;
function createEditor(id, settings, targetElm) { function createEditor(id, settings, targetElm) {
@ -38689,7 +38784,7 @@ define("tinymce/EditorManager", [
editor.on('init', function() { editor.on('init', function() {
if (++initCount === targets.length) { if (++initCount === targets.length) {
resolve(editors); provideResults(editors);
} }
}); });
@ -38698,10 +38793,10 @@ define("tinymce/EditorManager", [
} }
} }
DOM.unbind(window, 'ready', readyHandler); DOM.unbind(window, 'ready', initEditors);
execCallback('onpageload'); execCallback('onpageload');
targets = findTargets(settings); targets = $.unique(findTargets(settings));
// TODO: Deprecate this one // TODO: Deprecate this one
if (settings.types) { if (settings.types) {
@ -38725,13 +38820,16 @@ define("tinymce/EditorManager", [
} }
self.settings = settings; self.settings = settings;
DOM.bind(window, 'ready', initEditors);
return new Promise(function(resolve) { return new Promise(function(resolve) {
var readyHandler = function() { if (result) {
initEditors(resolve, readyHandler); resolve(result);
} else {
provideResults = function(editors) {
resolve(editors);
}; };
}
DOM.bind(window, 'ready', readyHandler);
}); });
}, },
@ -43266,6 +43364,102 @@ define("tinymce/ui/Iframe", [
}); });
}); });
// Included from: js/tinymce/classes/ui/InfoBox.js
/**
* InfoBox.js
*
* Released under LGPL License.
* Copyright (c) 1999-2016 Ephox Corp. All rights reserved
*
* License: http://www.tinymce.com/license
* Contributing: http://www.tinymce.com/contributing
*/
/**
* ....
*
* @-x-less InfoBox.less
* @class tinymce.ui.InfoBox
* @extends tinymce.ui.Widget
*/
define("tinymce/ui/InfoBox", [
"tinymce/ui/Widget"
], function(Widget) {
"use strict";
return Widget.extend({
/**
* Constructs a instance with the specified settings.
*
* @constructor
* @param {Object} settings Name/value object with settings.
* @setting {Boolean} multiline Multiline label.
*/
init: function(settings) {
var self = this;
self._super(settings);
self.classes.add('widget').add('infobox');
self.canFocus = false;
},
severity: function(level) {
this.classes.remove('error');
this.classes.remove('warning');
this.classes.remove('success');
this.classes.add(level);
},
help: function(state) {
this.state.set('help', state);
},
/**
* Renders the control as a HTML string.
*
* @method renderHtml
* @return {String} HTML representing the control.
*/
renderHtml: function() {
var self = this, prefix = self.classPrefix;
return (
'<div id="' + self._id + '" class="' + self.classes + '">' +
'<div id="' + self._id + '-body">' +
self.encode(self.state.get('text')) +
'<button role="button" tabindex="-1">' +
'<i class="' + prefix + 'ico ' + prefix + 'i-help"></i>' +
'</button>' +
'</div>' +
'</div>'
);
},
bindStates: function() {
var self = this;
self.state.on('change:text', function(e) {
self.getEl('body').firstChild.data = self.encode(e.value);
if (self.state.get('rendered')) {
self.updateLayoutRect();
}
});
self.state.on('change:help', function(e) {
self.classes.toggle('has-help', e.value);
if (self.state.get('rendered')) {
self.updateLayoutRect();
}
});
return self._super();
}
});
});
// Included from: js/tinymce/classes/ui/Label.js // Included from: js/tinymce/classes/ui/Label.js
/** /**
@ -43358,6 +43552,13 @@ define("tinymce/ui/Label", [
return self._super(); return self._super();
}, },
severity: function(level) {
this.classes.remove('error');
this.classes.remove('warning');
this.classes.remove('success');
this.classes.add(level);
},
/** /**
* Renders the control as a HTML string. * Renders the control as a HTML string.
* *
@ -43365,13 +43566,29 @@ define("tinymce/ui/Label", [
* @return {String} HTML representing the control. * @return {String} HTML representing the control.
*/ */
renderHtml: function() { renderHtml: function() {
var self = this, forId = self.settings.forId; var self = this, targetCtrl, forName, forId = self.settings.forId;
if (!forId && (forName = self.settings.forName)) {
targetCtrl = self.getRoot().find('#' + forName)[0];
if (targetCtrl) {
forId = targetCtrl._id;
}
}
if (forId) {
return ( return (
'<label id="' + self._id + '" class="' + self.classes + '"' + (forId ? ' for="' + forId + '"' : '') + '>' + '<label id="' + self._id + '" class="' + self.classes + '"' + (forId ? ' for="' + forId + '"' : '') + '>' +
self.encode(self.state.get('text')) + self.encode(self.state.get('text')) +
'</label>' '</label>'
); );
}
return (
'<span id="' + self._id + '" class="' + self.classes + '">' +
self.encode(self.state.get('text')) +
'</span>'
);
}, },
bindStates: function() { bindStates: function() {
@ -43379,6 +43596,10 @@ define("tinymce/ui/Label", [
self.state.on('change:text', function(e) { self.state.on('change:text', function(e) {
self.innerHtml(self.encode(e.value)); self.innerHtml(self.encode(e.value));
if (self.state.get('rendered')) {
self.updateLayoutRect();
}
}); });
return self._super(); return self._super();
@ -44709,15 +44930,31 @@ define("tinymce/ui/SelectBox", [
self._super(settings); self._super(settings);
if (self.settings.size) { if (self.settings.size) {
self.size = self.settings.size; self.size = self.settings.size;
} }
if (self.settings.options) { if (self.settings.options) {
self._options = self.settings.options; self._options = self.settings.options;
} }
self.on('keydown', function(e) {
var rootControl;
if (e.keyCode == 13) {
e.preventDefault();
// Find root control that we can do toJSON on
self.parents().reverse().each(function(ctrl) {
if (ctrl.toJSON) {
rootControl = ctrl;
return false;
}
});
// Fire event on current text box with the serialized data of the whole form
self.fire('submit', {data: rootControl.toJSON()});
}
});
}, },
/** /**
@ -45549,5 +45786,42 @@ define("tinymce/ui/TextBox", [
}); });
}); });
expose(["tinymce/geom/Rect","tinymce/util/Promise","tinymce/util/Delay","tinymce/dom/EventUtils","tinymce/dom/Sizzle","tinymce/Env","tinymce/util/Tools","tinymce/dom/DomQuery","tinymce/html/Styles","tinymce/dom/TreeWalker","tinymce/html/Entities","tinymce/dom/DOMUtils","tinymce/dom/ScriptLoader","tinymce/AddOnManager","tinymce/dom/RangeUtils","tinymce/html/Node","tinymce/html/Schema","tinymce/html/SaxParser","tinymce/html/DomParser","tinymce/html/Writer","tinymce/html/Serializer","tinymce/dom/Serializer","tinymce/util/VK","tinymce/dom/ControlSelection","tinymce/dom/BookmarkManager","tinymce/dom/Selection","tinymce/Formatter","tinymce/UndoManager","tinymce/EditorCommands","tinymce/util/URI","tinymce/util/Class","tinymce/util/EventDispatcher","tinymce/util/Observable","tinymce/ui/Selector","tinymce/ui/Collection","tinymce/ui/ReflowQueue","tinymce/ui/Control","tinymce/ui/Factory","tinymce/ui/KeyboardNavigation","tinymce/ui/Container","tinymce/ui/DragHelper","tinymce/ui/Scrollable","tinymce/ui/Panel","tinymce/ui/Movable","tinymce/ui/Resizable","tinymce/ui/FloatPanel","tinymce/ui/Window","tinymce/ui/MessageBox","tinymce/WindowManager","tinymce/ui/Tooltip","tinymce/ui/Widget","tinymce/ui/Progress","tinymce/ui/Notification","tinymce/NotificationManager","tinymce/EditorObservable","tinymce/Shortcuts","tinymce/Editor","tinymce/util/I18n","tinymce/FocusManager","tinymce/EditorManager","tinymce/util/XHR","tinymce/util/JSON","tinymce/util/JSONRequest","tinymce/util/JSONP","tinymce/util/LocalStorage","tinymce/Compat","tinymce/ui/Layout","tinymce/ui/AbsoluteLayout","tinymce/ui/Button","tinymce/ui/ButtonGroup","tinymce/ui/Checkbox","tinymce/ui/ComboBox","tinymce/ui/ColorBox","tinymce/ui/PanelButton","tinymce/ui/ColorButton","tinymce/util/Color","tinymce/ui/ColorPicker","tinymce/ui/Path","tinymce/ui/ElementPath","tinymce/ui/FormItem","tinymce/ui/Form","tinymce/ui/FieldSet","tinymce/ui/FilePicker","tinymce/ui/FitLayout","tinymce/ui/FlexLayout","tinymce/ui/FlowLayout","tinymce/ui/FormatControls","tinymce/ui/GridLayout","tinymce/ui/Iframe","tinymce/ui/Label","tinymce/ui/Toolbar","tinymce/ui/MenuBar","tinymce/ui/MenuButton","tinymce/ui/MenuItem","tinymce/ui/Throbber","tinymce/ui/Menu","tinymce/ui/ListBox","tinymce/ui/Radio","tinymce/ui/ResizeHandle","tinymce/ui/SelectBox","tinymce/ui/Slider","tinymce/ui/Spacer","tinymce/ui/SplitButton","tinymce/ui/StackLayout","tinymce/ui/TabPanel","tinymce/ui/TextBox"]); // Included from: js/tinymce/classes/Register.js
/**
* Register.js
*
* Released under LGPL License.
* Copyright (c) 1999-2015 Ephox Corp. All rights reserved
*
* License: http://www.tinymce.com/license
* Contributing: http://www.tinymce.com/contributing
*/
/**
* This registers tinymce in common module loaders.
*
* @private
* @class tinymce.Register
*/
define("tinymce/Register", [
], function() {
/*eslint consistent-this: 0 */
var context = this || window;
var tinymce = function() {
return context.tinymce;
};
if (typeof context.define === "function") {
// Bolt
if (!context.define.amd) {
context.define("ephox/tinymce", [], tinymce);
}
}
return {};
});
expose(["tinymce/geom/Rect","tinymce/util/Promise","tinymce/util/Delay","tinymce/dom/EventUtils","tinymce/dom/Sizzle","tinymce/Env","tinymce/util/Tools","tinymce/dom/DomQuery","tinymce/html/Styles","tinymce/dom/TreeWalker","tinymce/html/Entities","tinymce/dom/DOMUtils","tinymce/dom/ScriptLoader","tinymce/AddOnManager","tinymce/dom/RangeUtils","tinymce/html/Node","tinymce/html/Schema","tinymce/html/SaxParser","tinymce/html/DomParser","tinymce/html/Writer","tinymce/html/Serializer","tinymce/dom/Serializer","tinymce/util/VK","tinymce/dom/ControlSelection","tinymce/dom/BookmarkManager","tinymce/dom/Selection","tinymce/Formatter","tinymce/UndoManager","tinymce/EditorCommands","tinymce/util/URI","tinymce/util/Class","tinymce/util/EventDispatcher","tinymce/util/Observable","tinymce/ui/Selector","tinymce/ui/Collection","tinymce/ui/ReflowQueue","tinymce/ui/Control","tinymce/ui/Factory","tinymce/ui/KeyboardNavigation","tinymce/ui/Container","tinymce/ui/DragHelper","tinymce/ui/Scrollable","tinymce/ui/Panel","tinymce/ui/Movable","tinymce/ui/Resizable","tinymce/ui/FloatPanel","tinymce/ui/Window","tinymce/ui/MessageBox","tinymce/WindowManager","tinymce/ui/Tooltip","tinymce/ui/Widget","tinymce/ui/Progress","tinymce/ui/Notification","tinymce/NotificationManager","tinymce/EditorObservable","tinymce/Shortcuts","tinymce/Editor","tinymce/util/I18n","tinymce/FocusManager","tinymce/EditorManager","tinymce/util/XHR","tinymce/util/JSON","tinymce/util/JSONRequest","tinymce/util/JSONP","tinymce/util/LocalStorage","tinymce/Compat","tinymce/ui/Layout","tinymce/ui/AbsoluteLayout","tinymce/ui/Button","tinymce/ui/ButtonGroup","tinymce/ui/Checkbox","tinymce/ui/ComboBox","tinymce/ui/ColorBox","tinymce/ui/PanelButton","tinymce/ui/ColorButton","tinymce/util/Color","tinymce/ui/ColorPicker","tinymce/ui/Path","tinymce/ui/ElementPath","tinymce/ui/FormItem","tinymce/ui/Form","tinymce/ui/FieldSet","tinymce/ui/FilePicker","tinymce/ui/FitLayout","tinymce/ui/FlexLayout","tinymce/ui/FlowLayout","tinymce/ui/FormatControls","tinymce/ui/GridLayout","tinymce/ui/Iframe","tinymce/ui/InfoBox","tinymce/ui/Label","tinymce/ui/Toolbar","tinymce/ui/MenuBar","tinymce/ui/MenuButton","tinymce/ui/MenuItem","tinymce/ui/Throbber","tinymce/ui/Menu","tinymce/ui/ListBox","tinymce/ui/Radio","tinymce/ui/ResizeHandle","tinymce/ui/SelectBox","tinymce/ui/Slider","tinymce/ui/Spacer","tinymce/ui/SplitButton","tinymce/ui/StackLayout","tinymce/ui/TabPanel","tinymce/ui/TextBox"]);
})(this); })(this);

File diff suppressed because one or more lines are too long

View File

@ -18,7 +18,7 @@ $wp_db_version = 36686;
* *
* @global string $tinymce_version * @global string $tinymce_version
*/ */
$tinymce_version = '4304-20160224'; $tinymce_version = '4306-20160301';
/** /**
* Holds the required PHP version * Holds the required PHP version

View File

@ -1 +1 @@
tinymce.PluginManager.add("noneditable",function(e){function t(e){return function(t){return-1!==(" "+t.attr("class")+" ").indexOf(e)}}function n(t){function n(t){var n=arguments,r=n[n.length-2];return r>0&&'"'==a.charAt(r-1)?t:'<span class="'+s+'" data-mce-content="'+e.dom.encode(n[0])+'">'+e.dom.encode("string"==typeof n[1]?n[1]:n[0])+"</span>"}var r=o.length,a=t.content,s=tinymce.trim(i);if("raw"!=t.format){for(;r--;)a=a.replace(o[r],n);t.content=a}}var r,i,o,a="contenteditable";r=" "+tinymce.trim(e.getParam("noneditable_editable_class","mceEditable"))+" ",i=" "+tinymce.trim(e.getParam("noneditable_noneditable_class","mceNonEditable"))+" ";var s=t(r),l=t(i);o=e.getParam("noneditable_regexp"),o&&!o.length&&(o=[o]),e.on("PreInit",function(){o&&e.on("BeforeSetContent",n),e.parser.addAttributeFilter("class",function(e){for(var t,n=e.length;n--;)t=e[n],s(t)?t.attr(a,"true"):l(t)&&t.attr(a,"false")}),e.serializer.addAttributeFilter(a,function(e){for(var t,n=e.length;n--;)t=e[n],(s(t)||l(t))&&(o&&t.attr("data-mce-content")?(t.name="#text",t.type=3,t.raw=!0,t.value=t.attr("data-mce-content")):t.attr(a,null))})})}); tinymce.PluginManager.add("noneditable",function(a){function b(a){return function(b){return-1!==(" "+b.attr("class")+" ").indexOf(a)}}function c(b){function c(b){var c=arguments,d=c[c.length-2];return d>0&&'"'==g.charAt(d-1)?b:'<span class="'+h+'" data-mce-content="'+a.dom.encode(c[0])+'">'+a.dom.encode("string"==typeof c[1]?c[1]:c[0])+"</span>"}var d=f.length,g=b.content,h=tinymce.trim(e);if("raw"!=b.format){for(;d--;)g=g.replace(f[d],c);b.content=g}}var d,e,f,g="contenteditable";d=" "+tinymce.trim(a.getParam("noneditable_editable_class","mceEditable"))+" ",e=" "+tinymce.trim(a.getParam("noneditable_noneditable_class","mceNonEditable"))+" ";var h=b(d),i=b(e);f=a.getParam("noneditable_regexp"),f&&!f.length&&(f=[f]),a.on("PreInit",function(){f&&a.on("BeforeSetContent",c),a.parser.addAttributeFilter("class",function(a){for(var b,c=a.length;c--;)b=a[c],h(b)?b.attr(g,"true"):i(b)&&b.attr(g,"false")}),a.serializer.addAttributeFilter(g,function(a){for(var b,c=a.length;c--;)b=a[c],(h(b)||i(b))&&(f&&b.attr("data-mce-content")?(b.name="#text",b.type=3,b.raw=!0,b.value=b.attr("data-mce-content")):b.attr(g,null))})})});

View File

@ -47,6 +47,19 @@ test('mceInsertContent - p inside text of p', function() {
equal(rng.startContainer.innerHTML, 'abc'); equal(rng.startContainer.innerHTML, 'abc');
}); });
test('mceInsertContent before HR', function() {
var rng;
editor.setContent('<hr>');
editor.focus();
rng = editor.dom.createRng();
rng.setStart(editor.getBody(), 0);
rng.setEnd(editor.getBody(), 0);
editor.selection.setRng(rng);
editor.execCommand('mceInsertContent', false, 'x');
equal(getContent(), '<p>x</p><hr />');
});
test('mceInsertContent - p inside whole p', function() { test('mceInsertContent - p inside whole p', function() {
var rng; var rng;

View File

@ -28,3 +28,6 @@
.mce-dotted {background-image: url(../img/raster.gif);} .mce-dotted {background-image: url(../img/raster.gif);}
.mce-i-test {background: red;} .mce-i-test {background: red;}
body .mce-window, body .mce-notification {
transform: none;
}