]*>/gi, '[quote]'), c(/<\/blockquote>/gi, '[/quote]'), c(/ /gi, '\n'), c(/ /gi, '\n'), c(/ /gi, '\n'), c(//gi, ''), c(/<\/p>/gi, '\n'), c(/ |\u00a0/gi, ' '), c(/"/gi, '"'), c(/</gi, '<'), c(/>/gi, '>'), c(/&/gi, '&'), b; }, c = function (b) { b = a.trim(b); var c = function (a, c) { b = b.replace(a, c); }; return c(/\n/gi, ' '), c(/\[b\]/gi, ''), c(/\[\/b\]/gi, ' '), c(/\[i\]/gi, ''), c(/\[\/i\]/gi, ' '), c(/\[u\]/gi, ''), c(/\[\/u\]/gi, ' '), c(/\[url=([^\]]+)\](.*?)\[\/url\]/gi, '$2 '), c(/\[url\](.*?)\[\/url\]/gi, '$1 '), c(/\[img\](.*?)\[\/img\]/gi, ' '), c(/\[color=(.*?)\](.*?)\[\/color\]/gi, '$2 '), c(/\[code\](.*?)\[\/code\]/gi, '$1 '), c(/\[quote.*?\](.*?)\[\/quote\]/gi, '$1 '), b; }; return {html2bbcode: b, bbcode2html: c}; }), g('0', ['1', '2'], function (a, b) { return a.add('bbcode', function () { return {init: function (a) { a.on('beforeSetContent', function (a) { a.content = b.bbcode2html(a.content); }), a.on('postProcess', function (a) { a.set && (a.content = b.bbcode2html(a.content)), a.get && (a.content = b.html2bbcode(a.content)); }); }}; }), function () {}; }), d('0')(); }());
2 |
--------------------------------------------------------------------------------
/src/components/tinymce/plugins/legacyoutput/plugin.min.js:
--------------------------------------------------------------------------------
1 | !(function () { var a = {}, b = function (b) { for (var c = a[b], e = c.deps, f = c.defn, g = e.length, h = new Array(g), i = 0; i < g; ++i)h[i] = d(e[i]); var j = f.apply(null, h); if (void 0 === j) throw 'module [' + b + '] returned undefined'; c.instance = j; }, c = function (b, c, d) { if (typeof b !== 'string') throw 'module id must be a string'; if (void 0 === c) throw 'no dependencies for ' + b; if (void 0 === d) throw 'no definition function for ' + b; a[b] = {deps: c, defn: d, instance: void 0}; }, d = function (c) { var d = a[c]; if (void 0 === d) throw 'module [' + c + '] was undefined'; return void 0 === d.instance && b(c), d.instance; }, e = function (a, b) { for (var c = a.length, e = new Array(c), f = 0; f < c; ++f)e[f] = d(a[f]); b.apply(null, e); }, f = {}; f.bolt = {module: {api: {define: c, require: e, demand: d}}}; var g = c, h = function (a, b) { g(a, [], function () { return b; }); }; h('4', tinymce.util.Tools.resolve), g('1', ['4'], function (a) { return a('tinymce.PluginManager'); }), g('5', ['4'], function (a) { return a('tinymce.util.Tools'); }), g('2', ['5'], function (a) { var b = function (b) { var c = 'p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li,table,img', d = a.explode(b.settings.font_size_style_values), e = b.schema; b.formatter.register({alignleft: {selector: c, attributes: {align: 'left'}}, aligncenter: {selector: c, attributes: {align: 'center'}}, alignright: {selector: c, attributes: {align: 'right'}}, alignjustify: {selector: c, attributes: {align: 'justify'}}, bold: [{inline: 'b', remove: 'all'}, {inline: 'strong', remove: 'all'}, {inline: 'span', styles: {fontWeight: 'bold'}}], italic: [{inline: 'i', remove: 'all'}, {inline: 'em', remove: 'all'}, {inline: 'span', styles: {fontStyle: 'italic'}}], underline: [{inline: 'u', remove: 'all'}, {inline: 'span', styles: {textDecoration: 'underline'}, exact: !0}], strikethrough: [{inline: 'strike', remove: 'all'}, {inline: 'span', styles: {textDecoration: 'line-through'}, exact: !0}], fontname: {inline: 'font', attributes: {face: '%value'}}, fontsize: {inline: 'font', attributes: {size: function (b) { return a.inArray(d, b.value) + 1; }}}, forecolor: {inline: 'font', attributes: {color: '%value'}}, hilitecolor: {inline: 'font', styles: {backgroundColor: '%value'}}}), a.each('b,i,u,strike'.split(','), function (a) { e.addValidElements(a + '[*]'); }), e.getElementRule('font') || e.addValidElements('font[face|size|color|style]'), a.each(c.split(','), function (a) { var b = e.getElementRule(a); b && (b.attributes.align || (b.attributes.align = {}, b.attributesOrder.push('align'))); }); }, c = function (a) { a.settings.inline_styles = !1, a.on('init', function () { b(a); }); }; return {setup: c}; }), g('3', [], function () { var a = function (a) { a.addButton('fontsizeselect', function () { var b = [], c = '8pt=1 10pt=2 12pt=3 14pt=4 18pt=5 24pt=6 36pt=7', d = a.settings.fontsizeFormats || c; return a.$.each(d.split(' '), function (a, c) { var d = c, e = c, f = c.split('='); f.length > 1 && (d = f[0], e = f[1]), b.push({text: d, value: e}); }), {type: 'listbox', text: 'Font Sizes', tooltip: 'Font Sizes', values: b, fixedWidth: !0, onPostRender: function () { var b = this; a.on('NodeChange', function () { var c; c = a.dom.getParent(a.selection.getNode(), 'font'), c ? b.value(c.size) : b.value(''); }); }, onclick: function (b) { b.control.settings.value && a.execCommand('FontSize', !1, b.control.settings.value); }}; }), a.addButton('fontselect', function () { function b (a) { a = a.replace(/;$/, '').split(';'); for (var b = a.length; b--;)a[b] = a[b].split('='); return a; } var c = 'Andale Mono=andale mono,monospace;Arial=arial,helvetica,sans-serif;Arial Black=arial black,sans-serif;Book Antiqua=book antiqua,palatino,serif;Comic Sans MS=comic sans ms,sans-serif;Courier New=courier new,courier,monospace;Georgia=georgia,palatino,serif;Helvetica=helvetica,arial,sans-serif;Impact=impact,sans-serif;Symbol=symbol;Tahoma=tahoma,arial,helvetica,sans-serif;Terminal=terminal,monaco,monospace;Times New Roman=times new roman,times,serif;Trebuchet MS=trebuchet ms,geneva,sans-serif;Verdana=verdana,geneva,sans-serif;Webdings=webdings;Wingdings=wingdings,zapf dingbats', d = [], e = b(a.settings.font_formats || c); return a.$.each(e, function (a, b) { d.push({text: {raw: b[0]}, value: b[1], textStyle: b[1].indexOf('dings') === -1 ? 'font-family:' + b[1] : ''}); }), {type: 'listbox', text: 'Font Family', tooltip: 'Font Family', values: d, fixedWidth: !0, onPostRender: function () { var b = this; a.on('NodeChange', function () { var c; c = a.dom.getParent(a.selection.getNode(), 'font'), c ? b.value(c.face) : b.value(''); }); }, onselect: function (b) { b.control.settings.value && a.execCommand('FontName', !1, b.control.settings.value); }}; }); }; return {register: a}; }), g('0', ['1', '2', '3'], function (a, b, c) { return a.add('legacyoutput', function (a) { b.setup(a), c.register(a); }), function () {}; }), d('0')(); }());
2 |
--------------------------------------------------------------------------------
/src/components/tinymce/plugins/toc/plugin.min.js:
--------------------------------------------------------------------------------
1 | !(function () { var a = {}, b = function (b) { for (var c = a[b], e = c.deps, f = c.defn, g = e.length, h = new Array(g), i = 0; i < g; ++i)h[i] = d(e[i]); var j = f.apply(null, h); if (void 0 === j) throw 'module [' + b + '] returned undefined'; c.instance = j; }, c = function (b, c, d) { if (typeof b !== 'string') throw 'module id must be a string'; if (void 0 === c) throw 'no dependencies for ' + b; if (void 0 === d) throw 'no definition function for ' + b; a[b] = {deps: c, defn: d, instance: void 0}; }, d = function (c) { var d = a[c]; if (void 0 === d) throw 'module [' + c + '] was undefined'; return void 0 === d.instance && b(c), d.instance; }, e = function (a, b) { for (var c = a.length, e = new Array(c), f = 0; f < c; ++f)e[f] = d(a[f]); b.apply(null, e); }, f = {}; f.bolt = {module: {api: {define: c, require: e, demand: d}}}; var g = c, h = function (a, b) { g(a, [], function () { return b; }); }; h('6', tinymce.util.Tools.resolve), g('1', ['6'], function (a) { return a('tinymce.PluginManager'); }), g('8', ['6'], function (a) { return a('tinymce.dom.DOMUtils'); }), g('9', ['6'], function (a) { return a('tinymce.util.I18n'); }), g('a', ['6'], function (a) { return a('tinymce.util.Tools'); }), g('3', [], function () { var a = function (a) { return a.getParam('toc_class', 'mce-toc'); }, b = function (a) { var b = a.getParam('toc_header', 'h2'); return /^h[1-6]$/.test(b) ? b : 'h2'; }, c = function (a) { var b = parseInt(a.getParam('toc_depth', '3'), 10); return b >= 1 && b <= 9 ? b : 3; }; return {getTocClass: a, getTocHeader: b, getTocDepth: c}; }), g('b', [], function () { var a = function (a) { var b = 0; return function () { var c = (new Date()).getTime().toString(32); return a + c + (b++).toString(32); }; }; return {create: a}; }), g('7', ['8', '9', 'a', '3', 'b'], function (a, b, c, d, e) { var f = e.create('mcetoc_'), g = function (a) { var b, c = []; for (b = 1; b <= a; b++)c.push('h' + b); return c.join(','); }, h = function (a) { return i(a).length > 0; }, i = function (a) { var b = d.getTocClass(a), e = d.getTocHeader(a), h = g(d.getTocDepth(a)), i = a.$(h); return i.length && /^h[1-9]$/i.test(e) && (i = i.filter(function (c, d) { return !a.dom.hasClass(d.parentNode, b); })), c.map(i, function (b) { return {id: b.id ? b.id : f(), level: parseInt(b.nodeName.replace(/^H/i, ''), 10), title: a.$.text(b), element: b}; }); }, j = function (a) { var b, c = 9; for (b = 0; b < a.length; b++) if (a[b].level < c && (c = a[b].level), c === 1) return c; return c; }, k = function (b, c) { var d = '<' + b + ' contenteditable="true">', e = '' + b + '>'; return d + a.DOM.encode(c) + e; }, l = function (a) { var b = m(a); return '
' + b + '
'; }, m = function (a) { var c, e, f, g, h = '', l = i(a), m = j(l) - 1; if (!l.length) return ''; for (h += k(d.getTocHeader(a), b.translate('Table of Contents')), c = 0; c < l.length; c++) { if (f = l[c], f.element.id = f.id, g = l[c + 1] && l[c + 1].level, m === f.level)h += ''; else for (e = m; e < f.level; e++)h += ''; if (h += '' + f.title + ' ', g !== f.level && g) for (e = f.level; e > g; e--)h += ' '; else h += ' ', g || (h += ''); m = f.level; } return h; }, n = function (a, b) { return !b.length || a.dom.getParents(b[0], '.mce-offscreen-selection').length > 0; }, o = function (a) { var b = d.getTocClass(a), c = a.$('.' + b); n(a, c) ? a.insertContent(l(a)) : p(a); }, p = function (a) { var b = d.getTocClass(a), c = a.$('.' + b); c.length && a.undoManager.transact(function () { c.html(m(a)); }); }; return {hasHeaders: h, insertToc: o, updateToc: p}; }), g('2', ['7'], function (a) { var b = function (b) { b.addCommand('mceInsertToc', function () { a.insertToc(b); }), b.addCommand('mceUpdateToc', function () { a.updateToc(b); }); }; return {register: b}; }), g('4', ['3'], function (a) { var b = function (b) { var c = b.$, d = a.getTocClass(b); b.on('PreProcess', function (a) { var b = c('.' + d, a.node); b.length && (b.removeAttr('contentEditable'), b.find('[contenteditable]').removeAttr('contentEditable')); }), b.on('SetContent', function () { var a = c('.' + d); a.length && (a.attr('contentEditable', !1), a.children(':first-child').attr('contentEditable', !0)); }); }; return {setup: b}; }), g('5', ['3', '7'], function (a, b) { var c = function (a) { return function (c) { var d = c.control; a.on('LoadContent SetContent change', function () { d.disabled(a.readonly || !b.hasHeaders(a)); }); }; }, d = function (b) { return function (c) { return c && b.dom.is(c, '.' + a.getTocClass(b)) && b.getBody().contains(c); }; }, e = function (a) { a.addButton('toc', {tooltip: 'Table of Contents', cmd: 'mceInsertToc', icon: 'toc', onPostRender: c(a)}), a.addButton('tocupdate', {tooltip: 'Update', cmd: 'mceUpdateToc', icon: 'reload'}), a.addMenuItem('toc', {text: 'Table of Contents', context: 'insert', cmd: 'mceInsertToc', onPostRender: c(a)}), a.addContextToolbar(d(a), 'tocupdate'); }; return {register: e}; }), g('0', ['1', '2', '3', '4', '5'], function (a, b, c, d, e) { return a.add('toc', function (a) { b.register(a), e.register(a), d.setup(a); }), function () {}; }), d('0')(); }());
2 |
--------------------------------------------------------------------------------
/src/components/tinymce/plugins/insertdatetime/plugin.min.js:
--------------------------------------------------------------------------------
1 | !(function () { var a = {}, b = function (b) { for (var c = a[b], e = c.deps, f = c.defn, g = e.length, h = new Array(g), i = 0; i < g; ++i)h[i] = d(e[i]); var j = f.apply(null, h); if (void 0 === j) throw 'module [' + b + '] returned undefined'; c.instance = j; }, c = function (b, c, d) { if (typeof b !== 'string') throw 'module id must be a string'; if (void 0 === c) throw 'no dependencies for ' + b; if (void 0 === d) throw 'no definition function for ' + b; a[b] = {deps: c, defn: d, instance: void 0}; }, d = function (c) { var d = a[c]; if (void 0 === d) throw 'module [' + c + '] was undefined'; return void 0 === d.instance && b(c), d.instance; }, e = function (a, b) { for (var c = a.length, e = new Array(c), f = 0; f < c; ++f)e[f] = d(a[f]); b.apply(null, e); }, f = {}; f.bolt = {module: {api: {define: c, require: e, demand: d}}}; var g = c, h = function (a, b) { g(a, [], function () { return b; }); }; g('1', [], function () { var a = function (b) { var c = b, d = function () { return c; }, e = function (a) { c = a; }, f = function () { return a(d()); }; return {get: d, set: e, clone: f}; }; return a; }), h('5', tinymce.util.Tools.resolve), g('2', ['5'], function (a) { return a('tinymce.PluginManager'); }), g('6', [], function () { var a = function (a) { return a.getParam('fullpage_hide_in_source_view'); }, b = function (a) { return a.getParam('fullpage_default_xml_pi'); }, c = function (a) { return a.getParam('fullpage_default_encoding'); }, d = function (a) { return a.getParam('fullpage_default_font_family'); }, e = function (a) { return a.getParam('fullpage_default_font_size'); }, f = function (a) { return a.getParam('fullpage_default_text_color'); }, g = function (a) { return a.getParam('fullpage_default_title'); }, h = function (a) { return a.getParam('fullpage_default_doctype', ''); }; return {shouldHideInSourceView: a, getDefaultXmlPi: b, getDefaultEncoding: c, getDefaultFontFamily: d, getDefaultFontSize: e, getDefaultTextColor: f, getDefaultTitle: g, getDefaultDocType: h}; }), g('8', ['5'], function (a) { return a('tinymce.util.Tools'); }), g('9', [], function () { var a = function (a) { return a.getParam('insertdatetime_dateformat', a.translate('%Y-%m-%d')); }, b = function (a) { return a.getParam('insertdatetime_timeformat', a.translate('%H:%M:%S')); }, c = function (a) { return a.getParam('insertdatetime_formats', ['%H:%M:%S', '%Y-%m-%d', '%I:%M:%S %p', '%D']); }, d = function (a) { var d = c(a); return d.length > 0 ? d[0] : b(a); }, e = function (a) { return a.getParam('insertdatetime_element', !1); }; return {getDateFormat: a, getTimeFormat: b, getFormats: c, getDefaultDateTime: d, shouldInsertTimeElement: e}; }), g('7', ['8', '9'], function (a, b) { var c = 'Sun Mon Tue Wed Thu Fri Sat Sun'.split(' '), d = 'Sunday Monday Tuesday Wednesday Thursday Friday Saturday Sunday'.split(' '), e = 'Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec'.split(' '), f = 'January February March April May June July August September October November December'.split(' '), g = function (a, b) { if (a = '' + a, a.length < b) for (var c = 0; c < b - a.length; c++)a = '0' + a; return a; }, h = function (a, b, h) { return h = h || new Date(), b = b.replace('%D', '%m/%d/%Y'), b = b.replace('%r', '%I:%M:%S %p'), b = b.replace('%Y', '' + h.getFullYear()), b = b.replace('%y', '' + h.getYear()), b = b.replace('%m', g(h.getMonth() + 1, 2)), b = b.replace('%d', g(h.getDate(), 2)), b = b.replace('%H', '' + g(h.getHours(), 2)), b = b.replace('%M', '' + g(h.getMinutes(), 2)), b = b.replace('%S', '' + g(h.getSeconds(), 2)), b = b.replace('%I', '' + ((h.getHours() + 11) % 12 + 1)), b = b.replace('%p', '' + (h.getHours() < 12 ? 'AM' : 'PM')), b = b.replace('%B', '' + a.translate(f[h.getMonth()])), b = b.replace('%b', '' + a.translate(e[h.getMonth()])), b = b.replace('%A', '' + a.translate(d[h.getDay()])), b = b.replace('%a', '' + a.translate(c[h.getDay()])), b = b.replace('%%', '%'); }, i = function (a, b, c, d) { var e = a.dom.create('time', {datetime: c}, d); b.parentNode.insertBefore(e, b), a.dom.remove(b), a.selection.select(e, !0), a.selection.collapse(!1); }, j = function (a, c) { if (b.shouldInsertTimeElement(a)) { var d, e = h(a, c); d = /%[HMSIp]/.test(c) ? h(a, '%Y-%m-%dT%H:%M') : h(a, '%Y-%m-%d'); var f = a.dom.getParent(a.selection.getStart(), 'time'); f ? i(a, f, d, e) : a.insertContent('' + e + ' '); } else a.insertContent(h(a, c)); }; return {insertDateTime: j, getDateTime: h}; }), g('3', ['6', '7'], function (a, b) { var c = function (c) { c.addCommand('mceInsertDate', function () { b.insertDateTime(c, a.getDateFormat()); }), c.addCommand('mceInsertTime', function () { b.insertDateTime(c, a.getTimeFormat()); }); }; return {register: c}; }), g('4', ['8', '9', '7'], function (a, b, c) { var d = function (d, e) { var f = b.getFormats(d); return a.map(f, function (a) { return {text: c.getDateTime(d, a), onclick: function () { e.set(a), c.insertDateTime(d, a); }}; }); }, e = function (a, e) { var f = d(a, e); a.addButton('insertdatetime', {type: 'splitbutton', title: 'Insert date/time', menu: f, onclick: function () { var d = e.get(); c.insertDateTime(a, d || b.getDefaultDateTime(a)); }}), a.addMenuItem('insertdatetime', {icon: 'date', text: 'Date/time', menu: f, context: 'insert'}); }; return {register: e}; }), g('0', ['1', '2', '3', '4'], function (a, b, c, d) { return b.add('insertdatetime', function (b) { var e = a(null); c.register(b), d.register(b, e); }), function () {}; }), d('0')(); }());
2 |
--------------------------------------------------------------------------------
/src/components/tinymce/plugins/importcss/plugin.min.js:
--------------------------------------------------------------------------------
1 | !(function () { var a = {}, b = function (b) { for (var c = a[b], e = c.deps, f = c.defn, g = e.length, h = new Array(g), i = 0; i < g; ++i)h[i] = d(e[i]); var j = f.apply(null, h); if (void 0 === j) throw 'module [' + b + '] returned undefined'; c.instance = j; }, c = function (b, c, d) { if (typeof b !== 'string') throw 'module id must be a string'; if (void 0 === c) throw 'no dependencies for ' + b; if (void 0 === d) throw 'no definition function for ' + b; a[b] = {deps: c, defn: d, instance: void 0}; }, d = function (c) { var d = a[c]; if (void 0 === d) throw 'module [' + c + '] was undefined'; return void 0 === d.instance && b(c), d.instance; }, e = function (a, b) { for (var c = a.length, e = new Array(c), f = 0; f < c; ++f)e[f] = d(a[f]); b.apply(null, e); }, f = {}; f.bolt = {module: {api: {define: c, require: e, demand: d}}}; var g = c, h = function (a, b) { g(a, [], function () { return b; }); }; h('4', tinymce.util.Tools.resolve), g('1', ['4'], function (a) { return a('tinymce.PluginManager'); }), g('5', ['4'], function (a) { return a('tinymce.dom.DOMUtils'); }), g('6', ['4'], function (a) { return a('tinymce.EditorManager'); }), g('7', ['4'], function (a) { return a('tinymce.Env'); }), g('8', ['4'], function (a) { return a('tinymce.util.Tools'); }), g('9', [], function () { var a = function (a) { return a.getParam('importcss_merge_classes'); }, b = function (a) { return a.getParam('importcss_exclusive'); }, c = function (a) { return a.getParam('importcss_selector_converter'); }, d = function (a) { return a.getParam('importcss_selector_filter'); }, e = function (a) { return a.getParam('importcss_groups'); }, f = function (a) { return a.getParam('importcss_append'); }, g = function (a) { return a.getParam('importcss_file_filter'); }; return {shouldMergeClasses: a, shouldImportExclusive: b, getSelectorConverter: c, getSelectorFilter: d, getCssGroups: e, shouldAppend: f, getFileFilter: g}; }), g('3', ['5', '6', '7', '8', '9'], function (a, b, c, d, e) { var f = function (a) { var b = c.cacheSuffix; return typeof a === 'string' && (a = a.replace('?' + b, '').replace('&' + b, '')), a; }, g = function (a, c) { var d = a.settings, e = d.skin !== !1 && (d.skin || 'lightgray'); if (e) { var f = d.skin_url ? a.documentBaseURI.toAbsolute(d.skin_url) : b.baseURL + '/skins/' + e; return c === f + '/content' + (a.inline ? '.inline' : '') + '.min.css'; } return !1; }, h = function (a) { return typeof a === 'string' ? function (b) { return b.indexOf(a) !== -1; } : a instanceof RegExp ? function (b) { return a.test(b); } : a; }, i = function (a, b, c) { function e (b, i) { var j, k = b.href; if (k = f(k), k && c(k, i) && !g(a, k)) { d.each(b.imports, function (a) { e(a, !0); }); try { j = b.cssRules || b.rules; } catch (a) {}d.each(j, function (a) { a.styleSheet ? e(a.styleSheet, !0) : a.selectorText && d.each(a.selectorText.split(','), function (a) { h.push(d.trim(a)); }); }); } } var h = [], i = {}; d.each(a.contentCSS, function (a) { i[a] = !0; }), c || (c = function (a, b) { return b || i[a]; }); try { d.each(b.styleSheets, function (a) { e(a); }); } catch (a) {} return h; }, j = function (a, b) { var c, f = /^(?:([a-z0-9\-_]+))?(\.[a-z0-9_\-\.]+)$/i.exec(b); if (f) { var g = f[1], h = f[2].substr(1).split('.').join(' '), i = d.makeMap('a,img'); return f[1] ? (c = {title: b}, a.schema.getTextBlockElements()[g] ? c.block = g : a.schema.getBlockElements()[g] || i[g.toLowerCase()] ? c.selector = g : c.inline = g) : f[2] && (c = {inline: 'span', title: b.substr(1), classes: h}), e.shouldMergeClasses(a) !== !1 ? c.classes = h : c.attributes = {'class': h}, c; } }, k = function (a, b) { return d.grep(a, function (a) { return !a.filter || a.filter(b); }); }, l = function (a) { return d.map(a, function (a) { return d.extend({}, a, {original: a, selectors: {}, filter: h(a.filter), item: {text: a.title, menu: []}}); }); }, m = function (a, b) { return b === null || e.shouldImportExclusive(a) !== !1; }, n = function (a, b, c, d) { return !(m(a, c) ? b in d : b in c.selectors); }, o = function (a, b, c, d) { m(a, c) ? d[b] = !0 : c.selectors[b] = !0; }, p = function (a, b, c, d) { var f; return f = d && d.selector_converter ? d.selector_converter : e.getSelectorConverter(a) ? e.getSelectorConverter(a) : function () { return j(a, c, d); }, f.call(b, c, d); }, q = function (b) { b.on('renderFormatsMenu', function (c) { var f = {}, g = h(e.getSelectorFilter(b)), j = c.control, m = l(e.getCssGroups(b)), q = function (c, e) { if (n(b, c, e, f)) { o(b, c, e, f); var g = p(b, b.plugins.importcss, c, e); if (g) { var h = g.name || a.DOM.uniqueId(); return b.formatter.register(h, g), d.extend({}, j.settings.itemDefaults, {text: g.title, format: h}); } } return null; }; e.shouldAppend(b) || j.items().remove(), d.each(i(b, c.doc || b.getDoc(), h(e.getFileFilter(b))), function (a) { if (a.indexOf('.mce-') === -1 && (!g || g(a))) { var b = k(m, a); if (b.length > 0)d.each(b, function (b) { var c = q(a, b); c && b.item.menu.push(c); }); else { var c = q(a, null); c && j.add(c); } } }), d.each(m, function (a) { a.item.menu.length > 0 && j.add(a.item); }), c.control.renderNew(); }); }; return {defaultConvertSelectorToFormat: j, setup: q}; }), g('2', ['3'], function (a) { var b = function (b) { var c = function (c) { return a.defaultConvertSelectorToFormat(b, c); }; return {convertSelectorToFormat: c}; }; return {get: b}; }), g('0', ['1', '2', '3'], function (a, b, c) { return a.add('importcss', function (a) { return c.setup(a), b.get(a); }), function () {}; }), d('0')(); }());
2 |
--------------------------------------------------------------------------------
/src/components/tinymce/plugins/autosave/plugin.min.js:
--------------------------------------------------------------------------------
1 | !(function () { var a = {}, b = function (b) { for (var c = a[b], e = c.deps, f = c.defn, g = e.length, h = new Array(g), i = 0; i < g; ++i)h[i] = d(e[i]); var j = f.apply(null, h); if (void 0 === j) throw 'module [' + b + '] returned undefined'; c.instance = j; }, c = function (b, c, d) { if (typeof b !== 'string') throw 'module id must be a string'; if (void 0 === c) throw 'no dependencies for ' + b; if (void 0 === d) throw 'no definition function for ' + b; a[b] = {deps: c, defn: d, instance: void 0}; }, d = function (c) { var d = a[c]; if (void 0 === d) throw 'module [' + c + '] was undefined'; return void 0 === d.instance && b(c), d.instance; }, e = function (a, b) { for (var c = a.length, e = new Array(c), f = 0; f < c; ++f)e[f] = d(a[f]); b.apply(null, e); }, f = {}; f.bolt = {module: {api: {define: c, require: e, demand: d}}}; var g = c, h = function (a, b) { g(a, [], function () { return b; }); }; g('1', [], function () { var a = function (b) { var c = b, d = function () { return c; }, e = function (a) { c = a; }, f = function () { return a(d()); }; return {get: d, set: e, clone: f}; }; return a; }), h('6', tinymce.util.Tools.resolve), g('2', ['6'], function (a) { return a('tinymce.PluginManager'); }), h('c', setInterval), g('d', ['6'], function (a) { return a('tinymce.util.LocalStorage'); }), g('a', ['6'], function (a) { return a('tinymce.util.Tools'); }), g('e', [], function () { var a = function (a) { return a.fire('RestoreDraft'); }, b = function (a) { return a.fire('StoreDraft'); }, c = function (a) { return a.fire('RemoveDraft'); }; return {fireRestoreDraft: a, fireStoreDraft: b, fireRemoveDraft: c}; }), h('f', document), g('g', [], function () { var a = function (a, b) { var c = {s: 1e3, m: 6e4}; return a = /^(\d+)([ms]?)$/.exec('' + (a || b)), (a[2] ? c[a[2]] : 1) * parseInt(a, 10); }; return {parse: a}; }), g('b', ['f', 'g'], function (a, b) { var c = function (a) { return a.getParam('autosave_ask_before_unload', !0); }, d = function (b) { var c = b.getParam('autosave_prefix', 'tinymce-autosave-{path}{query}-{id}-'); return c = c.replace(/\{path\}/g, a.location.pathname), c = c.replace(/\{query\}/g, a.location.search), c = c.replace(/\{id\}/g, b.id); }, e = function (a) { return a.getParam('autosave_restore_when_empty', !1); }, f = function (a) { return b.parse(a.settings.autosave_interval, '30s'); }, g = function (a) { return b.parse(a.settings.autosave_retention, '20m'); }; return {shouldAskBeforeUnload: c, getAutoSavePrefix: d, shouldRestoreWhenEmpty: e, getAutoSaveInterval: f, getAutoSaveRetention: g}; }), g('7', ['c', 'd', 'a', 'e', 'b'], function (a, b, c, d, e) { var f = function (a, b) { var d = a.settings.forced_root_block; return b = c.trim(typeof b === 'undefined' ? a.getBody().innerHTML : b), b === '' || new RegExp('^<' + d + '[^>]*>((\xa0| |[ \t]| ]*>)+?|)' + d + '>| $', 'i').test(b); }, g = function (a) { var c = parseInt(b.getItem(e.getAutoSavePrefix(a) + 'time'), 10) || 0; return !((new Date()).getTime() - c > e.getAutoSaveRetention(a)) || (h(a, !1), !1); }, h = function (a, c) { var f = e.getAutoSavePrefix(a); b.removeItem(f + 'draft'), b.removeItem(f + 'time'), c !== !1 && d.fireRemoveDraft(a); }, i = function (a) { var c = e.getAutoSavePrefix(a); !f(a) && a.isDirty() && (b.setItem(c + 'draft', a.getContent({format: 'raw', no_events: !0})), b.setItem(c + 'time', (new Date()).getTime()), d.fireStoreDraft(a)); }, j = function (a) { var c = e.getAutoSavePrefix(a); g(a) && (a.setContent(b.getItem(c + 'draft'), {format: 'raw'}), d.fireRestoreDraft(a)); }, k = function (b, c) { var d = e.getAutoSaveInterval(b); c.get() || (a(function () { b.removed || i(b); }, d), c.set(!0)); }, l = function (a) { a.undoManager.transact(function () { j(a), h(a); }), a.focus(); }; return {isEmpty: f, hasDraft: g, removeDraft: h, storeDraft: i, restoreDraft: j, startStoreDraft: k, restoreLastDraft: l}; }), g('3', ['7'], function (a) { var b = function (a, b) { return function () { var c = Array.prototype.slice.call(arguments); return a.apply(null, [b].concat(c)); }; }, c = function (c) { return {hasDraft: b(a.hasDraft, c), storeDraft: b(a.storeDraft, c), restoreDraft: b(a.restoreDraft, c), removeDraft: b(a.removeDraft, c), isEmpty: b(a.isEmpty, c)}; }; return {get: c}; }), h('8', window), g('9', ['6'], function (a) { return a('tinymce.EditorManager'); }), g('4', ['8', '9', 'a', 'b'], function (a, b, c, d) { b._beforeUnloadHandler = function () { var a; return c.each(b.get(), function (b) { b.plugins.autosave && b.plugins.autosave.storeDraft(), !a && b.isDirty() && d.shouldAskBeforeUnload(b) && (a = b.translate('You have unsaved changes are you sure you want to navigate away?')); }), a; }; var e = function (c) { a.onbeforeunload = b._beforeUnloadHandler; }; return {setup: e}; }), g('5', ['7'], function (a) { var b = function (b, c) { return function (d) { var e = d.control; e.disabled(!a.hasDraft(b)), b.on('StoreDraft RestoreDraft RemoveDraft', function () { e.disabled(!a.hasDraft(b)); }), a.startStoreDraft(b, c); }; }, c = function (c, d) { c.addButton('restoredraft', {title: 'Restore last draft', onclick: function () { a.restoreLastDraft(c); }, onPostRender: b(c, d)}), c.addMenuItem('restoredraft', {text: 'Restore last draft', onclick: function () { a.restoreLastDraft(c); }, onPostRender: b(c, d), context: 'file'}); }; return {register: c}; }), g('0', ['1', '2', '3', '4', '5'], function (a, b, c, d, e) { return b.add('autosave', function (b) { var f = a(!1); return d.setup(b), e.register(b, f), c.get(b); }), function () {}; }), d('0')(); }());
2 |
--------------------------------------------------------------------------------
/src/views/index.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
8 | 上传模板
9 |
10 |
20 |
21 |
22 | 加载组件中...
23 |
24 |
25 |
26 |
27 |
28 |
29 |
145 |
--------------------------------------------------------------------------------
/src/components/tinymce/plugins/print/plugin.js:
--------------------------------------------------------------------------------
1 | (function () {
2 | var defs = {}; // id -> {dependencies, definition, instance (possibly undefined)}
3 |
4 | // Used when there is no 'main' module.
5 | // The name is probably (hopefully) unique so minification removes for releases.
6 | var register_3795 = function (id) {
7 | var module = dem(id);
8 | var fragments = id.split('.');
9 | var target = Function('return this;')();
10 | for (var i = 0; i < fragments.length - 1; ++i) {
11 | if (target[fragments[i]] === undefined) { target[fragments[i]] = {}; }
12 | target = target[fragments[i]];
13 | }
14 | target[fragments[fragments.length - 1]] = module;
15 | };
16 |
17 | var instantiate = function (id) {
18 | var actual = defs[id];
19 | var dependencies = actual.deps;
20 | var definition = actual.defn;
21 | var len = dependencies.length;
22 | var instances = new Array(len);
23 | for (var i = 0; i < len; ++i) { instances[i] = dem(dependencies[i]); }
24 | var defResult = definition.apply(null, instances);
25 | if (defResult === undefined) { throw 'module [' + id + '] returned undefined'; }
26 | actual.instance = defResult;
27 | };
28 |
29 | var def = function (id, dependencies, definition) {
30 | if (typeof id !== 'string') { throw 'module id must be a string'; } else if (dependencies === undefined) { throw 'no dependencies for ' + id; } else if (definition === undefined) { throw 'no definition function for ' + id; }
31 | defs[id] = {
32 | deps: dependencies,
33 | defn: definition,
34 | instance: undefined
35 | };
36 | };
37 |
38 | var dem = function (id) {
39 | var actual = defs[id];
40 | if (actual === undefined) { throw 'module [' + id + '] was undefined'; } else if (actual.instance === undefined) { instantiate(id); }
41 | return actual.instance;
42 | };
43 |
44 | var req = function (ids, callback) {
45 | var len = ids.length;
46 | var instances = new Array(len);
47 | for (var i = 0; i < len; ++i) { instances[i] = dem(ids[i]); }
48 | callback.apply(null, instances);
49 | };
50 |
51 | var ephox = {};
52 |
53 | ephox.bolt = {
54 | module: {
55 | api: {
56 | define: def,
57 | require: req,
58 | demand: dem
59 | }
60 | }
61 | };
62 |
63 | var define = def;
64 | var require = req;
65 | var demand = dem;
66 | // this helps with minification when using a lot of global references
67 | var defineGlobal = function (id, ref) {
68 | define(id, [], function () { return ref; });
69 | };
70 | /* jsc
71 | ["tinymce.plugins.print.Plugin","tinymce.core.PluginManager","tinymce.plugins.print.api.Commands","tinymce.plugins.print.ui.Buttons","global!tinymce.util.Tools.resolve"]
72 | jsc */
73 | defineGlobal('global!tinymce.util.Tools.resolve', tinymce.util.Tools.resolve);
74 | /**
75 | * ResolveGlobal.js
76 | *
77 | * Released under LGPL License.
78 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
79 | *
80 | * License: http://www.tinymce.com/license
81 | * Contributing: http://www.tinymce.com/contributing
82 | */
83 |
84 | define(
85 | 'tinymce.core.PluginManager',
86 | [
87 | 'global!tinymce.util.Tools.resolve'
88 | ],
89 | function (resolve) {
90 | return resolve('tinymce.PluginManager');
91 | }
92 | );
93 |
94 | /**
95 | * Commands.js
96 | *
97 | * Released under LGPL License.
98 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
99 | *
100 | * License: http://www.tinymce.com/license
101 | * Contributing: http://www.tinymce.com/contributing
102 | */
103 |
104 | define(
105 | 'tinymce.plugins.print.api.Commands',
106 | [
107 | ],
108 | function () {
109 | var register = function (editor) {
110 | editor.addCommand('mcePrint', function () {
111 | editor.getWin().print();
112 | });
113 | };
114 |
115 | return {
116 | register: register
117 | };
118 | }
119 | );
120 | /**
121 | * Buttons.js
122 | *
123 | * Released under LGPL License.
124 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
125 | *
126 | * License: http://www.tinymce.com/license
127 | * Contributing: http://www.tinymce.com/contributing
128 | */
129 |
130 | define(
131 | 'tinymce.plugins.print.ui.Buttons',
132 | [
133 | ],
134 | function () {
135 | var register = function (editor) {
136 | editor.addButton('print', {
137 | title: 'Print',
138 | cmd: 'mcePrint'
139 | });
140 |
141 | editor.addMenuItem('print', {
142 | text: 'Print',
143 | cmd: 'mcePrint',
144 | icon: 'print'
145 | });
146 | };
147 |
148 | return {
149 | register: register
150 | };
151 | }
152 | );
153 | /**
154 | * Plugin.js
155 | *
156 | * Released under LGPL License.
157 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
158 | *
159 | * License: http://www.tinymce.com/license
160 | * Contributing: http://www.tinymce.com/contributing
161 | */
162 |
163 | define(
164 | 'tinymce.plugins.print.Plugin',
165 | [
166 | 'tinymce.core.PluginManager',
167 | 'tinymce.plugins.print.api.Commands',
168 | 'tinymce.plugins.print.ui.Buttons'
169 | ],
170 | function (PluginManager, Commands, Buttons) {
171 | PluginManager.add('print', function (editor) {
172 | Commands.register(editor);
173 | Buttons.register(editor);
174 | editor.addShortcut('Meta+P', '', 'mcePrint');
175 | });
176 |
177 | return function () { };
178 | }
179 | );
180 | dem('tinymce.plugins.print.Plugin')();
181 | })();
182 |
--------------------------------------------------------------------------------
/src/components/tinymce/plugins/hr/plugin.js:
--------------------------------------------------------------------------------
1 | (function () {
2 | var defs = {}; // id -> {dependencies, definition, instance (possibly undefined)}
3 |
4 | // Used when there is no 'main' module.
5 | // The name is probably (hopefully) unique so minification removes for releases.
6 | var register_3795 = function (id) {
7 | var module = dem(id);
8 | var fragments = id.split('.');
9 | var target = Function('return this;')();
10 | for (var i = 0; i < fragments.length - 1; ++i) {
11 | if (target[fragments[i]] === undefined) { target[fragments[i]] = {}; }
12 | target = target[fragments[i]];
13 | }
14 | target[fragments[fragments.length - 1]] = module;
15 | };
16 |
17 | var instantiate = function (id) {
18 | var actual = defs[id];
19 | var dependencies = actual.deps;
20 | var definition = actual.defn;
21 | var len = dependencies.length;
22 | var instances = new Array(len);
23 | for (var i = 0; i < len; ++i) { instances[i] = dem(dependencies[i]); }
24 | var defResult = definition.apply(null, instances);
25 | if (defResult === undefined) { throw 'module [' + id + '] returned undefined'; }
26 | actual.instance = defResult;
27 | };
28 |
29 | var def = function (id, dependencies, definition) {
30 | if (typeof id !== 'string') { throw 'module id must be a string'; } else if (dependencies === undefined) { throw 'no dependencies for ' + id; } else if (definition === undefined) { throw 'no definition function for ' + id; }
31 | defs[id] = {
32 | deps: dependencies,
33 | defn: definition,
34 | instance: undefined
35 | };
36 | };
37 |
38 | var dem = function (id) {
39 | var actual = defs[id];
40 | if (actual === undefined) { throw 'module [' + id + '] was undefined'; } else if (actual.instance === undefined) { instantiate(id); }
41 | return actual.instance;
42 | };
43 |
44 | var req = function (ids, callback) {
45 | var len = ids.length;
46 | var instances = new Array(len);
47 | for (var i = 0; i < len; ++i) { instances[i] = dem(ids[i]); }
48 | callback.apply(null, instances);
49 | };
50 |
51 | var ephox = {};
52 |
53 | ephox.bolt = {
54 | module: {
55 | api: {
56 | define: def,
57 | require: req,
58 | demand: dem
59 | }
60 | }
61 | };
62 |
63 | var define = def;
64 | var require = req;
65 | var demand = dem;
66 | // this helps with minification when using a lot of global references
67 | var defineGlobal = function (id, ref) {
68 | define(id, [], function () { return ref; });
69 | };
70 | /* jsc
71 | ["tinymce.plugins.hr.Plugin","tinymce.core.PluginManager","tinymce.plugins.hr.api.Commands","tinymce.plugins.hr.ui.Buttons","global!tinymce.util.Tools.resolve"]
72 | jsc */
73 | defineGlobal('global!tinymce.util.Tools.resolve', tinymce.util.Tools.resolve);
74 | /**
75 | * ResolveGlobal.js
76 | *
77 | * Released under LGPL License.
78 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
79 | *
80 | * License: http://www.tinymce.com/license
81 | * Contributing: http://www.tinymce.com/contributing
82 | */
83 |
84 | define(
85 | 'tinymce.core.PluginManager',
86 | [
87 | 'global!tinymce.util.Tools.resolve'
88 | ],
89 | function (resolve) {
90 | return resolve('tinymce.PluginManager');
91 | }
92 | );
93 |
94 | /**
95 | * Commands.js
96 | *
97 | * Released under LGPL License.
98 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
99 | *
100 | * License: http://www.tinymce.com/license
101 | * Contributing: http://www.tinymce.com/contributing
102 | */
103 |
104 | define(
105 | 'tinymce.plugins.hr.api.Commands',
106 | [
107 | ],
108 | function () {
109 | var register = function (editor) {
110 | editor.addCommand('InsertHorizontalRule', function () {
111 | editor.execCommand('mceInsertContent', false, ' ');
112 | });
113 | };
114 |
115 | return {
116 | register: register
117 | };
118 | }
119 | );
120 | /**
121 | * Buttons.js
122 | *
123 | * Released under LGPL License.
124 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
125 | *
126 | * License: http://www.tinymce.com/license
127 | * Contributing: http://www.tinymce.com/contributing
128 | */
129 |
130 | define(
131 | 'tinymce.plugins.hr.ui.Buttons',
132 | [
133 | ],
134 | function () {
135 | var register = function (editor) {
136 | editor.addButton('hr', {
137 | icon: 'hr',
138 | tooltip: 'Horizontal line',
139 | cmd: 'InsertHorizontalRule'
140 | });
141 |
142 | editor.addMenuItem('hr', {
143 | icon: 'hr',
144 | text: 'Horizontal line',
145 | cmd: 'InsertHorizontalRule',
146 | context: 'insert'
147 | });
148 | };
149 |
150 | return {
151 | register: register
152 | };
153 | }
154 | );
155 | /**
156 | * Plugin.js
157 | *
158 | * Released under LGPL License.
159 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
160 | *
161 | * License: http://www.tinymce.com/license
162 | * Contributing: http://www.tinymce.com/contributing
163 | */
164 |
165 | define(
166 | 'tinymce.plugins.hr.Plugin',
167 | [
168 | 'tinymce.core.PluginManager',
169 | 'tinymce.plugins.hr.api.Commands',
170 | 'tinymce.plugins.hr.ui.Buttons'
171 | ],
172 | function (PluginManager, Commands, Buttons) {
173 | PluginManager.add('hr', function (editor) {
174 | Commands.register(editor);
175 | Buttons.register(editor);
176 | });
177 |
178 | return function () { };
179 | }
180 | );
181 | dem('tinymce.plugins.hr.Plugin')();
182 | })();
183 |
--------------------------------------------------------------------------------
/src/components/tinymce/plugins/visualblocks/css/visualblocks.css:
--------------------------------------------------------------------------------
1 | .mce-visualblocks p {
2 | padding-top: 10px;
3 | border: 1px dashed #BBB;
4 | margin-left: 3px;
5 | background-image: url(data:image/gif;base64,R0lGODlhCQAJAJEAAAAAAP///7u7u////yH5BAEAAAMALAAAAAAJAAkAAAIQnG+CqCN/mlyvsRUpThG6AgA7);
6 | background-repeat: no-repeat;
7 | }
8 |
9 | .mce-visualblocks h1 {
10 | padding-top: 10px;
11 | border: 1px dashed #BBB;
12 | margin-left: 3px;
13 | background-image: url(data:image/gif;base64,R0lGODlhDQAKAIABALu7u////yH5BAEAAAEALAAAAAANAAoAAAIXjI8GybGu1JuxHoAfRNRW3TWXyF2YiRUAOw==);
14 | background-repeat: no-repeat;
15 | }
16 |
17 | .mce-visualblocks h2 {
18 | padding-top: 10px;
19 | border: 1px dashed #BBB;
20 | margin-left: 3px;
21 | background-image: url(data:image/gif;base64,R0lGODlhDgAKAIABALu7u////yH5BAEAAAEALAAAAAAOAAoAAAIajI8Hybbx4oOuqgTynJd6bGlWg3DkJzoaUAAAOw==);
22 | background-repeat: no-repeat;
23 | }
24 |
25 | .mce-visualblocks h3 {
26 | padding-top: 10px;
27 | border: 1px dashed #BBB;
28 | margin-left: 3px;
29 | background-image: url(data:image/gif;base64,R0lGODlhDgAKAIABALu7u////yH5BAEAAAEALAAAAAAOAAoAAAIZjI8Hybbx4oOuqgTynJf2Ln2NOHpQpmhAAQA7);
30 | background-repeat: no-repeat;
31 | }
32 |
33 | .mce-visualblocks h4 {
34 | padding-top: 10px;
35 | border: 1px dashed #BBB;
36 | margin-left: 3px;
37 | background-image: url(data:image/gif;base64,R0lGODlhDgAKAIABALu7u////yH5BAEAAAEALAAAAAAOAAoAAAIajI8HybbxInR0zqeAdhtJlXwV1oCll2HaWgAAOw==);
38 | background-repeat: no-repeat;
39 | }
40 |
41 | .mce-visualblocks h5 {
42 | padding-top: 10px;
43 | border: 1px dashed #BBB;
44 | margin-left: 3px;
45 | background-image: url(data:image/gif;base64,R0lGODlhDgAKAIABALu7u////yH5BAEAAAEALAAAAAAOAAoAAAIajI8HybbxIoiuwjane4iq5GlW05GgIkIZUAAAOw==);
46 | background-repeat: no-repeat;
47 | }
48 |
49 | .mce-visualblocks h6 {
50 | padding-top: 10px;
51 | border: 1px dashed #BBB;
52 | margin-left: 3px;
53 | background-image: url(data:image/gif;base64,R0lGODlhDgAKAIABALu7u////yH5BAEAAAEALAAAAAAOAAoAAAIajI8HybbxIoiuwjan04jep1iZ1XRlAo5bVgAAOw==);
54 | background-repeat: no-repeat;
55 | }
56 |
57 | .mce-visualblocks div:not([data-mce-bogus]) {
58 | padding-top: 10px;
59 | border: 1px dashed #BBB;
60 | margin-left: 3px;
61 | background-image: url(data:image/gif;base64,R0lGODlhEgAKAIABALu7u////yH5BAEAAAEALAAAAAASAAoAAAIfjI9poI0cgDywrhuxfbrzDEbQM2Ei5aRjmoySW4pAAQA7);
62 | background-repeat: no-repeat;
63 | }
64 |
65 | .mce-visualblocks section {
66 | padding-top: 10px;
67 | border: 1px dashed #BBB;
68 | margin: 0 0 1em 3px;
69 | background-image: url(data:image/gif;base64,R0lGODlhKAAKAIABALu7u////yH5BAEAAAEALAAAAAAoAAoAAAI5jI+pywcNY3sBWHdNrplytD2ellDeSVbp+GmWqaDqDMepc8t17Y4vBsK5hDyJMcI6KkuYU+jpjLoKADs=);
70 | background-repeat: no-repeat;
71 | }
72 |
73 | .mce-visualblocks article {
74 | padding-top: 10px;
75 | border: 1px dashed #BBB;
76 | margin: 0 0 1em 3px;
77 | background-image: url(data:image/gif;base64,R0lGODlhKgAKAIABALu7u////yH5BAEAAAEALAAAAAAqAAoAAAI6jI+pywkNY3wG0GBvrsd2tXGYSGnfiF7ikpXemTpOiJScasYoDJJrjsG9gkCJ0ag6KhmaIe3pjDYBBQA7);
78 | background-repeat: no-repeat;
79 | }
80 |
81 | .mce-visualblocks blockquote {
82 | padding-top: 10px;
83 | border: 1px dashed #BBB;
84 | background-image: url(data:image/gif;base64,R0lGODlhPgAKAIABALu7u////yH5BAEAAAEALAAAAAA+AAoAAAJPjI+py+0Knpz0xQDyuUhvfoGgIX5iSKZYgq5uNL5q69asZ8s5rrf0yZmpNkJZzFesBTu8TOlDVAabUyatguVhWduud3EyiUk45xhTTgMBBQA7);
85 | background-repeat: no-repeat;
86 | }
87 |
88 | .mce-visualblocks address {
89 | padding-top: 10px;
90 | border: 1px dashed #BBB;
91 | margin: 0 0 1em 3px;
92 | background-image: url(data:image/gif;base64,R0lGODlhLQAKAIABALu7u////yH5BAEAAAEALAAAAAAtAAoAAAI/jI+pywwNozSP1gDyyZcjb3UaRpXkWaXmZW4OqKLhBmLs+K263DkJK7OJeifh7FicKD9A1/IpGdKkyFpNmCkAADs=);
93 | background-repeat: no-repeat;
94 | }
95 |
96 | .mce-visualblocks pre {
97 | padding-top: 10px;
98 | border: 1px dashed #BBB;
99 | margin-left: 3px;
100 | background-image: url(data:image/gif;base64,R0lGODlhFQAKAIABALu7uwAAACH5BAEAAAEALAAAAAAVAAoAAAIjjI+ZoN0cgDwSmnpz1NCueYERhnibZVKLNnbOq8IvKpJtVQAAOw==);
101 | background-repeat: no-repeat;
102 | }
103 |
104 | .mce-visualblocks figure {
105 | padding-top: 10px;
106 | border: 1px dashed #BBB;
107 | margin: 0 0 1em 3px;
108 | background-image: url(data:image/gif;base64,R0lGODlhJAAKAIAAALu7u////yH5BAEAAAEALAAAAAAkAAoAAAI0jI+py+2fwAHUSFvD3RlvG4HIp4nX5JFSpnZUJ6LlrM52OE7uSWosBHScgkSZj7dDKnWAAgA7);
109 | background-repeat: no-repeat;
110 | }
111 |
112 | .mce-visualblocks hgroup {
113 | padding-top: 10px;
114 | border: 1px dashed #BBB;
115 | margin: 0 0 1em 3px;
116 | background-image: url(data:image/gif;base64,R0lGODlhJwAKAIABALu7uwAAACH5BAEAAAEALAAAAAAnAAoAAAI3jI+pywYNI3uB0gpsRtt5fFnfNZaVSYJil4Wo03Hv6Z62uOCgiXH1kZIIJ8NiIxRrAZNMZAtQAAA7);
117 | background-repeat: no-repeat;
118 | }
119 |
120 | .mce-visualblocks aside {
121 | padding-top: 10px;
122 | border: 1px dashed #BBB;
123 | margin: 0 0 1em 3px;
124 | background-image: url(data:image/gif;base64,R0lGODlhHgAKAIABAKqqqv///yH5BAEAAAEALAAAAAAeAAoAAAItjI+pG8APjZOTzgtqy7I3f1yehmQcFY4WKZbqByutmW4aHUd6vfcVbgudgpYCADs=);
125 | background-repeat: no-repeat;
126 | }
127 |
128 | .mce-visualblocks figcaption {
129 | border: 1px dashed #BBB;
130 | }
131 |
132 | .mce-visualblocks ul {
133 | padding-top: 10px;
134 | border: 1px dashed #BBB;
135 | margin: 0 0 1em 3px;
136 | background-image: url(data:image/gif;base64,R0lGODlhDQAKAIAAALu7u////yH5BAEAAAEALAAAAAANAAoAAAIXjI8GybGuYnqUVSjvw26DzzXiqIDlVwAAOw==);
137 | background-repeat: no-repeat;
138 | }
139 |
140 | .mce-visualblocks ol {
141 | padding-top: 10px;
142 | border: 1px dashed #BBB;
143 | margin: 0 0 1em 3px;
144 | background-image: url(data:image/gif;base64,R0lGODlhDQAKAIABALu7u////yH5BAEAAAEALAAAAAANAAoAAAIXjI8GybH6HHt0qourxC6CvzXieHyeWQAAOw==);
145 | background-repeat: no-repeat;
146 | }
147 |
148 | .mce-visualblocks dl {
149 | padding-top: 10px;
150 | border: 1px dashed #BBB;
151 | margin: 0 0 1em 3px;
152 | background-image: url(data:image/gif;base64,R0lGODlhDQAKAIABALu7u////yH5BAEAAAEALAAAAAANAAoAAAIXjI8GybEOnmOvUoWznTqeuEjNSCqeGRUAOw==);
153 | background-repeat: no-repeat;
154 | }
155 |
--------------------------------------------------------------------------------
/src/components/tinymce/plugins/textpattern/plugin.min.js:
--------------------------------------------------------------------------------
1 | !(function () { var a = {}, b = function (b) { for (var c = a[b], e = c.deps, f = c.defn, g = e.length, h = new Array(g), i = 0; i < g; ++i)h[i] = d(e[i]); var j = f.apply(null, h); if (void 0 === j) throw 'module [' + b + '] returned undefined'; c.instance = j; }, c = function (b, c, d) { if (typeof b !== 'string') throw 'module id must be a string'; if (void 0 === c) throw 'no dependencies for ' + b; if (void 0 === d) throw 'no definition function for ' + b; a[b] = {deps: c, defn: d, instance: void 0}; }, d = function (c) { var d = a[c]; if (void 0 === d) throw 'module [' + c + '] was undefined'; return void 0 === d.instance && b(c), d.instance; }, e = function (a, b) { for (var c = a.length, e = new Array(c), f = 0; f < c; ++f)e[f] = d(a[f]); b.apply(null, e); }, f = {}; f.bolt = {module: {api: {define: c, require: e, demand: d}}}; var g = c, h = function (a, b) { g(a, [], function () { return b; }); }; g('1', [], function () { var a = function (b) { var c = b, d = function () { return c; }, e = function (a) { c = a; }, f = function () { return a(d()); }; return {get: d, set: e, clone: f}; }; return a; }), h('6', tinymce.util.Tools.resolve), g('2', ['6'], function (a) { return a('tinymce.PluginManager'); }), g('3', [], function () { var a = function (a) { var b = function (b) { a.set(b); }, c = function () { return a.get(); }; return {setPatterns: b, getPatterns: c}; }; return {get: a}; }), g('4', [], function () { var a = [{start: '*', end: '*', format: 'italic'}, {start: '**', end: '**', format: 'bold'}, {start: '***', end: '***', format: ['bold', 'italic']}, {start: '#', format: 'h1'}, {start: '##', format: 'h2'}, {start: '###', format: 'h3'}, {start: '####', format: 'h4'}, {start: '#####', format: 'h5'}, {start: '######', format: 'h6'}, {start: '1. ', cmd: 'InsertOrderedList'}, {start: '* ', cmd: 'InsertUnorderedList'}, {start: '- ', cmd: 'InsertUnorderedList'}], b = function (b) { return void 0 !== b.textpattern_patterns ? b.textpattern_patterns : a; }; return {getPatterns: b}; }), g('7', ['6'], function (a) { return a('tinymce.util.Delay'); }), g('8', ['6'], function (a) { return a('tinymce.util.VK'); }), h('b', document), g('c', ['6'], function (a) { return a('tinymce.dom.TreeWalker'); }), g('d', ['6'], function (a) { return a('tinymce.util.Tools'); }), g('e', [], function () { var a = function (a) { return a.sort(function (a, b) { return a.start.length > b.start.length ? -1 : a.start.length < b.start.length ? 1 : 0; }); }, b = function (a, b) { for (var c = 0; c < a.length; c++) if (b.indexOf(a[c].start) === 0 && (!a[c].end || b.lastIndexOf(a[c].end) === b.length - a[c].end.length)) return a[c]; }, c = function (a, b, c, d) { var e = b.substr(c - a.end.length - d, a.end.length); return e === a.end; }, d = function (a, b, c) { return a - b - c.end.length - c.start.length > 0; }, e = function (b, e, f, g) { var h, i, j = a(b); for (i = 0; i < j.length; i++) if (h = j[i], void 0 !== h.end && c(h, e, f, g) && d(f, g, h)) return h; }; return {findPattern: b, findEndPattern: e}; }), g('a', ['b', 'c', 'd', 'e'], function (a, b, c, d) { var e = function (a, b, c, d, e) { return a = d > 0 ? a.splitText(d) : a, a.splitText(c - d + b.end.length), a.deleteData(0, b.start.length), a.deleteData(a.data.length - b.end.length, b.end.length), a; }, f = function (b, c, e) { if (c.collapsed !== !1) { var f = c.startContainer, g = f.data, h = e === !0 ? 1 : 0; if (f.nodeType === 3) { var i = d.findEndPattern(b, g, c.startOffset, h); if (void 0 !== i) { var j = g.lastIndexOf(i.end, c.startOffset - h), k = g.lastIndexOf(i.start, j - i.end.length); if (j = g.indexOf(i.end, k + i.start.length), k !== -1) { var l = a.createRange(); l.setStart(f, k), l.setEnd(f, j + i.end.length); var m = d.findPattern(b, l.toString()); if (!(void 0 === i || m !== i || f.data.length <= i.start.length + i.end.length)) return {pattern: i, startOffset: k, endOffset: j}; } } } } }, g = function (a, b, d, f) { var g = c.isArray(d.pattern.format) ? d.pattern.format : [d.pattern.format], h = c.grep(g, function (b) { var c = a.formatter.get(b); return c && c[0].inline; }); if (h.length !== 0) return a.undoManager.transact(function () { b = e(b, d.pattern, d.endOffset, d.startOffset, f), g.forEach(function (c) { a.formatter.apply(c, {}, b); }); }), b; }, h = function (a, b, c) { var d = a.selection.getRng(!0), e = f(b, d, c); if (e) return g(a, d.startContainer, e, c); }, i = function (a, b) { return h(a, b, !0); }, j = function (a, b) { return h(a, b, !1); }, k = function (a, e) { var f, g, h, i, j, k, l, m, n, o, p; if (f = a.selection, g = a.dom, f.isCollapsed() && (l = g.getParent(f.getStart(), 'p'))) { for (n = new b(l, l); j = n.next();) if (j.nodeType === 3) { i = j; break; } if (i) { if (m = d.findPattern(e, i.data), !m) return; if (o = f.getRng(!0), h = o.startContainer, p = o.startOffset, i === h && (p = Math.max(0, p - m.start.length)), c.trim(i.data).length === m.start.length) return; m.format && (k = a.formatter.get(m.format), k && k[0].block && (i.deleteData(0, m.start.length), a.formatter.apply(m.format, {}, i), o.setStart(h, p), o.collapse(!0), f.setRng(o))), m.cmd && a.undoManager.transact(function () { i.deleteData(0, m.start.length), a.execCommand(m.cmd); }); } } }; return {patternFromRng: f, applyInlineFormatSpace: i, applyInlineFormatEnter: j, applyBlockFormat: k}; }), g('9', ['8', 'a'], function (a, b) { function c (a, c) { var d, e; d = b.applyInlineFormatEnter(a, c), d && (e = a.dom.createRng(), e.setStart(d, d.data.length), e.setEnd(d, d.data.length), a.selection.setRng(e)), b.applyBlockFormat(a, c); } function d (a, c) { var d, e, f, g, h; d = b.applyInlineFormatSpace(a, c), d && (h = a.dom, e = d.data.slice(-1), /[\u00a0 ]/.test(e) && (d.deleteData(d.data.length - 1, 1), f = h.doc.createTextNode(e), h.insertAfter(f, d.parentNode), g = h.createRng(), g.setStart(f, 1), g.setEnd(f, 1), a.selection.setRng(g))); } var e = function (a, b, c) { for (var d = 0; d < a.length; d++) if (c(a[d], b)) return !0; }, f = function (b, c) { return e(b, c, function (b, c) { return b === c.keyCode && a.modifierPressed(c) === !1; }); }, g = function (a, b) { return e(a, b, function (a, b) { return a.charCodeAt(0) === b.charCode; }); }; return {handleEnter: c, handleInlineKey: d, checkCharCode: g, checkKeyCode: f}; }), g('5', ['7', '8', '9'], function (a, b, c) { var d = function (d, e) { var f = [',', '.', ';', ':', '!', '?'], g = [32]; d.on('keydown', function (a) { a.keyCode !== 13 || b.modifierPressed(a) || c.handleEnter(d, e.get()); }, !0), d.on('keyup', function (a) { c.checkKeyCode(g, a) && c.handleInlineKey(d, e.get()); }), d.on('keypress', function (b) { c.checkCharCode(f, b) && a.setEditorTimeout(d, function () { c.handleInlineKey(d, e.get()); }); }); }; return {setup: d}; }), g('0', ['1', '2', '3', '4', '5'], function (a, b, c, d, e) { return b.add('textpattern', function (b) { var f = a(d.getPatterns(b.settings)); return e.setup(b, f), c.get(f); }), function () {}; }), d('0')(); }());
2 |
--------------------------------------------------------------------------------
/src/components/tinymce/plugins/textcolor/plugin.min.js:
--------------------------------------------------------------------------------
1 | !(function () { var a = {}, b = function (b) { for (var c = a[b], e = c.deps, f = c.defn, g = e.length, h = new Array(g), i = 0; i < g; ++i)h[i] = d(e[i]); var j = f.apply(null, h); if (void 0 === j) throw 'module [' + b + '] returned undefined'; c.instance = j; }, c = function (b, c, d) { if (typeof b !== 'string') throw 'module id must be a string'; if (void 0 === c) throw 'no dependencies for ' + b; if (void 0 === d) throw 'no definition function for ' + b; a[b] = {deps: c, defn: d, instance: void 0}; }, d = function (c) { var d = a[c]; if (void 0 === d) throw 'module [' + c + '] was undefined'; return void 0 === d.instance && b(c), d.instance; }, e = function (a, b) { for (var c = a.length, e = new Array(c), f = 0; f < c; ++f)e[f] = d(a[f]); b.apply(null, e); }, f = {}; f.bolt = {module: {api: {define: c, require: e, demand: d}}}; var g = c, h = function (a, b) { g(a, [], function () { return b; }); }; h('3', tinymce.util.Tools.resolve), g('1', ['3'], function (a) { return a('tinymce.PluginManager'); }), g('4', ['3'], function (a) { return a('tinymce.dom.DOMUtils'); }), g('5', ['3'], function (a) { return a('tinymce.util.Tools'); }), g('6', [], function () { var a = ['000000', 'Black', '993300', 'Burnt orange', '333300', 'Dark olive', '003300', 'Dark green', '003366', 'Dark azure', '000080', 'Navy Blue', '333399', 'Indigo', '333333', 'Very dark gray', '800000', 'Maroon', 'FF6600', 'Orange', '808000', 'Olive', '008000', 'Green', '008080', 'Teal', '0000FF', 'Blue', '666699', 'Grayish blue', '808080', 'Gray', 'FF0000', 'Red', 'FF9900', 'Amber', '99CC00', 'Yellow green', '339966', 'Sea green', '33CCCC', 'Turquoise', '3366FF', 'Royal blue', '800080', 'Purple', '999999', 'Medium gray', 'FF00FF', 'Magenta', 'FFCC00', 'Gold', 'FFFF00', 'Yellow', '00FF00', 'Lime', '00FFFF', 'Aqua', '00CCFF', 'Sky blue', '993366', 'Red violet', 'FFFFFF', 'White', 'FF99CC', 'Pink', 'FFCC99', 'Peach', 'FFFF99', 'Light yellow', 'CCFFCC', 'Pale green', 'CCFFFF', 'Pale cyan', '99CCFF', 'Light sky blue', 'CC99FF', 'Plum'], b = function (b) { return b.getParam('textcolor_map', a); }, c = function (a) { return a.getParam('forecolor_map', b(a)); }, d = function (a) { return a.getParam('backcolor_map', b(a)); }, e = function (a) { return a.getParam('textcolor_rows', 5); }, f = function (a) { return a.getParam('textcolor_cols', 8); }, g = function (a) { return a.getParam('forecolor_rows', e(a)); }, h = function (a) { return a.getParam('backcolor_rows', e(a)); }, i = function (a) { return a.getParam('forecolor_cols', f(a)); }, j = function (a) { return a.getParam('backcolor_cols', f(a)); }, k = function (a) { return a.getParam('color_picker_callback', null); }, l = function (a) { return typeof k(a) === 'function'; }; return {getForeColorMap: c, getBackColorMap: d, getForeColorRows: g, getBackColorRows: h, getForeColorCols: i, getBackColorCols: j, getColorPickerCallback: k, hasColorPicker: l}; }), g('7', [], function () { var a = function (a, b) { var c; return a.dom.getParents(a.selection.getStart(), function (a) { var d; (d = a.style[b === 'forecolor' ? 'color' : 'background-color']) && (c = d); }), c; }, b = function (a) { var b, c = []; for (b = 0; b < a.length; b += 2)c.push({text: a[b + 1], color: '#' + a[b]}); return c; }, c = function (a, b, c) { a.undoManager.transact(function () { a.focus(), a.formatter.apply(b, {value: c}), a.nodeChanged(); }); }, d = function (a, b) { a.undoManager.transact(function () { a.focus(), a.formatter.remove(b, {value: null}, null, !0), a.nodeChanged(); }); }; return {getCurrentColor: a, mapColors: b, applyFormat: c, removeFormat: d}; }), g('9', ['3'], function (a) { return a('tinymce.util.I18n'); }), g('8', ['4', '9', '6', '7'], function (a, b, c, d) { var e = function (c, e, f, g) { var h, i, j, k, l, m, n, o = 0, p = a.DOM.uniqueId('mcearia'), q = function (a, c) { var d = a === 'transparent'; return '' + (d ? '×' : '') + '
'; }; for (h = d.mapColors(f), h.push({text: b.translate('No color'), color: 'transparent'}), j = ''; }; return {getHtml: e}; }), g('2', ['4', '5', '6', '7', '8'], function (a, b, c, d, e) { var f = function (a, b) { a.style.background = b, a.setAttribute('data-mce-color', b); }, g = function (a) { return function (b) { var c = b.control; c._color ? d.applyFormat(a, c.settings.format, c._color) : d.removeFormat(a, c.settings.format); }; }, h = function (e, g) { return function (h) { var i, j = this.parent(), k = d.getCurrentColor(e, j.settings.format), l = function (a) { j.hidePanel(), j.color(a), d.applyFormat(e, j.settings.format, a); }, m = function () { j.hidePanel(), j.resetColor(), d.removeFormat(e, j.settings.format); }; if (a.DOM.getParent(h.target, '.mce-custom-color-btn')) { j.hidePanel(); var n = c.getColorPickerCallback(e); n.call(e, function (a) { var c, d, e, h = j.panel.getEl().getElementsByTagName('table')[0]; for (c = b.map(h.rows[h.rows.length - 1].childNodes, function (a) { return a.firstChild; }), e = 0; e < c.length && (d = c[e], d.getAttribute('data-mce-color')); e++);if (e === g) for (e = 0; e < g - 1; e++)f(c[e], c[e + 1].getAttribute('data-mce-color')); f(d, a), l(a); }, k); }i = h.target.getAttribute('data-mce-color'), i ? (this.lastId && a.DOM.get(this.lastId).setAttribute('aria-selected', !1), h.target.setAttribute('aria-selected', !0), this.lastId = h.target.id, i === 'transparent' ? m() : l(i)) : i !== null && j.hidePanel(); }; }, i = function (a, b) { return function () { var d = b ? c.getForeColorCols(a) : c.getBackColorCols(a), f = b ? c.getForeColorRows(a) : c.getBackColorRows(a), g = b ? c.getForeColorMap(a) : c.getBackColorMap(a), h = c.hasColorPicker(a); return e.getHtml(d, f, g, h); }; }, j = function (a) { a.addButton('forecolor', {type: 'colorbutton', tooltip: 'Text color', format: 'forecolor', panel: {role: 'application', ariaRemember: !0, html: i(a, !0), onclick: h(a, c.getForeColorCols(a))}, onclick: g(a)}), a.addButton('backcolor', {type: 'colorbutton', tooltip: 'Background color', format: 'hilitecolor', panel: {role: 'application', ariaRemember: !0, html: i(a, !1), onclick: h(a, c.getBackColorCols(a))}, onclick: g(a)}); }; return {register: j}; }), g('0', ['1', '2'], function (a, b) { return a.add('textcolor', function (a) { b.register(a); }), function () {}; }), d('0')(); }());
2 |
--------------------------------------------------------------------------------
/src/components/tinymce/plugins/emoticons/plugin.js:
--------------------------------------------------------------------------------
1 | (function () {
2 | var defs = {}; // id -> {dependencies, definition, instance (possibly undefined)}
3 |
4 | // Used when there is no 'main' module.
5 | // The name is probably (hopefully) unique so minification removes for releases.
6 | var register_3795 = function (id) {
7 | var module = dem(id);
8 | var fragments = id.split('.');
9 | var target = Function('return this;')();
10 | for (var i = 0; i < fragments.length - 1; ++i) {
11 | if (target[fragments[i]] === undefined) { target[fragments[i]] = {}; }
12 | target = target[fragments[i]];
13 | }
14 | target[fragments[fragments.length - 1]] = module;
15 | };
16 |
17 | var instantiate = function (id) {
18 | var actual = defs[id];
19 | var dependencies = actual.deps;
20 | var definition = actual.defn;
21 | var len = dependencies.length;
22 | var instances = new Array(len);
23 | for (var i = 0; i < len; ++i) { instances[i] = dem(dependencies[i]); }
24 | var defResult = definition.apply(null, instances);
25 | if (defResult === undefined) { throw 'module [' + id + '] returned undefined'; }
26 | actual.instance = defResult;
27 | };
28 |
29 | var def = function (id, dependencies, definition) {
30 | if (typeof id !== 'string') { throw 'module id must be a string'; } else if (dependencies === undefined) { throw 'no dependencies for ' + id; } else if (definition === undefined) { throw 'no definition function for ' + id; }
31 | defs[id] = {
32 | deps: dependencies,
33 | defn: definition,
34 | instance: undefined
35 | };
36 | };
37 |
38 | var dem = function (id) {
39 | var actual = defs[id];
40 | if (actual === undefined) { throw 'module [' + id + '] was undefined'; } else if (actual.instance === undefined) { instantiate(id); }
41 | return actual.instance;
42 | };
43 |
44 | var req = function (ids, callback) {
45 | var len = ids.length;
46 | var instances = new Array(len);
47 | for (var i = 0; i < len; ++i) { instances[i] = dem(ids[i]); }
48 | callback.apply(null, instances);
49 | };
50 |
51 | var ephox = {};
52 |
53 | ephox.bolt = {
54 | module: {
55 | api: {
56 | define: def,
57 | require: req,
58 | demand: dem
59 | }
60 | }
61 | };
62 |
63 | var define = def;
64 | var require = req;
65 | var demand = dem;
66 | // this helps with minification when using a lot of global references
67 | var defineGlobal = function (id, ref) {
68 | define(id, [], function () { return ref; });
69 | };
70 | /* jsc
71 | ["tinymce.plugins.emoticons.Plugin","tinymce.core.PluginManager","tinymce.plugins.emoticons.ui.Buttons","global!tinymce.util.Tools.resolve","tinymce.plugins.emoticons.ui.PanelHtml","tinymce.core.util.Tools"]
72 | jsc */
73 | defineGlobal('global!tinymce.util.Tools.resolve', tinymce.util.Tools.resolve);
74 | /**
75 | * ResolveGlobal.js
76 | *
77 | * Released under LGPL License.
78 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
79 | *
80 | * License: http://www.tinymce.com/license
81 | * Contributing: http://www.tinymce.com/contributing
82 | */
83 |
84 | define(
85 | 'tinymce.core.PluginManager',
86 | [
87 | 'global!tinymce.util.Tools.resolve'
88 | ],
89 | function (resolve) {
90 | return resolve('tinymce.PluginManager');
91 | }
92 | );
93 |
94 | /**
95 | * ResolveGlobal.js
96 | *
97 | * Released under LGPL License.
98 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
99 | *
100 | * License: http://www.tinymce.com/license
101 | * Contributing: http://www.tinymce.com/contributing
102 | */
103 |
104 | define(
105 | 'tinymce.core.util.Tools',
106 | [
107 | 'global!tinymce.util.Tools.resolve'
108 | ],
109 | function (resolve) {
110 | return resolve('tinymce.util.Tools');
111 | }
112 | );
113 |
114 | /**
115 | * PanelHtml.js
116 | *
117 | * Released under LGPL License.
118 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
119 | *
120 | * License: http://www.tinymce.com/license
121 | * Contributing: http://www.tinymce.com/contributing
122 | */
123 |
124 | define(
125 | 'tinymce.plugins.emoticons.ui.PanelHtml',
126 | [
127 | 'tinymce.core.util.Tools'
128 | ],
129 | function (Tools) {
130 | var emoticons = [
131 | ['cool', 'cry', 'embarassed', 'foot-in-mouth'],
132 | ['frown', 'innocent', 'kiss', 'laughing'],
133 | ['money-mouth', 'sealed', 'smile', 'surprised'],
134 | ['tongue-out', 'undecided', 'wink', 'yell']
135 | ];
136 |
137 | var getHtml = function (pluginUrl) {
138 | var emoticonsHtml;
139 |
140 | emoticonsHtml = '';
141 |
142 | Tools.each(emoticons, function (row) {
143 | emoticonsHtml += '';
144 |
145 | Tools.each(row, function (icon) {
146 | var emoticonUrl = pluginUrl + '/img/smiley-' + icon + '.gif';
147 |
148 | emoticonsHtml += ' ';
151 | });
152 |
153 | emoticonsHtml += ' ';
154 | });
155 |
156 | emoticonsHtml += '
';
157 |
158 | return emoticonsHtml;
159 | };
160 |
161 | return {
162 | getHtml: getHtml
163 | };
164 | }
165 | );
166 | /**
167 | * Buttons.js
168 | *
169 | * Released under LGPL License.
170 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
171 | *
172 | * License: http://www.tinymce.com/license
173 | * Contributing: http://www.tinymce.com/contributing
174 | */
175 |
176 | define(
177 | 'tinymce.plugins.emoticons.ui.Buttons',
178 | [
179 | 'tinymce.plugins.emoticons.ui.PanelHtml'
180 | ],
181 | function (PanelHtml) {
182 | var insertEmoticon = function (editor, src, alt) {
183 | editor.insertContent(editor.dom.createHTML('img', { src: src, alt: alt }));
184 | };
185 |
186 | var register = function (editor, pluginUrl) {
187 | var panelHtml = PanelHtml.getHtml(pluginUrl);
188 |
189 | editor.addButton('emoticons', {
190 | type: 'panelbutton',
191 | panel: {
192 | role: 'application',
193 | autohide: true,
194 | html: panelHtml,
195 | onclick: function (e) {
196 | var linkElm = editor.dom.getParent(e.target, 'a');
197 | if (linkElm) {
198 | insertEmoticon(editor, linkElm.getAttribute('data-mce-url'), linkElm.getAttribute('data-mce-alt'));
199 | this.hide();
200 | }
201 | }
202 | },
203 | tooltip: 'Emoticons'
204 | });
205 | };
206 |
207 | return {
208 | register: register
209 | };
210 | }
211 | );
212 | /**
213 | * Plugin.js
214 | *
215 | * Released under LGPL License.
216 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
217 | *
218 | * License: http://www.tinymce.com/license
219 | * Contributing: http://www.tinymce.com/contributing
220 | */
221 |
222 | /**
223 | * This class contains all core logic for the emoticons plugin.
224 | *
225 | * @class tinymce.emoticons.Plugin
226 | * @private
227 | */
228 | define(
229 | 'tinymce.plugins.emoticons.Plugin',
230 | [
231 | 'tinymce.core.PluginManager',
232 | 'tinymce.plugins.emoticons.ui.Buttons'
233 | ],
234 | function (PluginManager, Buttons) {
235 | PluginManager.add('emoticons', function (editor, pluginUrl) {
236 | Buttons.register(editor, pluginUrl);
237 | });
238 |
239 | return function () { };
240 | }
241 | );
242 | dem('tinymce.plugins.emoticons.Plugin')();
243 | })();
244 |
--------------------------------------------------------------------------------
/src/components/tinymce/plugins/directionality/plugin.js:
--------------------------------------------------------------------------------
1 | (function () {
2 | var defs = {}; // id -> {dependencies, definition, instance (possibly undefined)}
3 |
4 | // Used when there is no 'main' module.
5 | // The name is probably (hopefully) unique so minification removes for releases.
6 | var register_3795 = function (id) {
7 | var module = dem(id);
8 | var fragments = id.split('.');
9 | var target = Function('return this;')();
10 | for (var i = 0; i < fragments.length - 1; ++i) {
11 | if (target[fragments[i]] === undefined) { target[fragments[i]] = {}; }
12 | target = target[fragments[i]];
13 | }
14 | target[fragments[fragments.length - 1]] = module;
15 | };
16 |
17 | var instantiate = function (id) {
18 | var actual = defs[id];
19 | var dependencies = actual.deps;
20 | var definition = actual.defn;
21 | var len = dependencies.length;
22 | var instances = new Array(len);
23 | for (var i = 0; i < len; ++i) { instances[i] = dem(dependencies[i]); }
24 | var defResult = definition.apply(null, instances);
25 | if (defResult === undefined) { throw 'module [' + id + '] returned undefined'; }
26 | actual.instance = defResult;
27 | };
28 |
29 | var def = function (id, dependencies, definition) {
30 | if (typeof id !== 'string') { throw 'module id must be a string'; } else if (dependencies === undefined) { throw 'no dependencies for ' + id; } else if (definition === undefined) { throw 'no definition function for ' + id; }
31 | defs[id] = {
32 | deps: dependencies,
33 | defn: definition,
34 | instance: undefined
35 | };
36 | };
37 |
38 | var dem = function (id) {
39 | var actual = defs[id];
40 | if (actual === undefined) { throw 'module [' + id + '] was undefined'; } else if (actual.instance === undefined) { instantiate(id); }
41 | return actual.instance;
42 | };
43 |
44 | var req = function (ids, callback) {
45 | var len = ids.length;
46 | var instances = new Array(len);
47 | for (var i = 0; i < len; ++i) { instances[i] = dem(ids[i]); }
48 | callback.apply(null, instances);
49 | };
50 |
51 | var ephox = {};
52 |
53 | ephox.bolt = {
54 | module: {
55 | api: {
56 | define: def,
57 | require: req,
58 | demand: dem
59 | }
60 | }
61 | };
62 |
63 | var define = def;
64 | var require = req;
65 | var demand = dem;
66 | // this helps with minification when using a lot of global references
67 | var defineGlobal = function (id, ref) {
68 | define(id, [], function () { return ref; });
69 | };
70 | /* jsc
71 | ["tinymce.plugins.directionality.Plugin","tinymce.core.PluginManager","tinymce.plugins.directionality.api.Commands","tinymce.plugins.directionality.ui.Buttons","global!tinymce.util.Tools.resolve","tinymce.plugins.directionality.core.Direction","tinymce.core.util.Tools"]
72 | jsc */
73 | defineGlobal('global!tinymce.util.Tools.resolve', tinymce.util.Tools.resolve);
74 | /**
75 | * ResolveGlobal.js
76 | *
77 | * Released under LGPL License.
78 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
79 | *
80 | * License: http://www.tinymce.com/license
81 | * Contributing: http://www.tinymce.com/contributing
82 | */
83 |
84 | define(
85 | 'tinymce.core.PluginManager',
86 | [
87 | 'global!tinymce.util.Tools.resolve'
88 | ],
89 | function (resolve) {
90 | return resolve('tinymce.PluginManager');
91 | }
92 | );
93 |
94 | /**
95 | * ResolveGlobal.js
96 | *
97 | * Released under LGPL License.
98 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
99 | *
100 | * License: http://www.tinymce.com/license
101 | * Contributing: http://www.tinymce.com/contributing
102 | */
103 |
104 | define(
105 | 'tinymce.core.util.Tools',
106 | [
107 | 'global!tinymce.util.Tools.resolve'
108 | ],
109 | function (resolve) {
110 | return resolve('tinymce.util.Tools');
111 | }
112 | );
113 |
114 | /**
115 | * Direction.js
116 | *
117 | * Released under LGPL License.
118 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
119 | *
120 | * License: http://www.tinymce.com/license
121 | * Contributing: http://www.tinymce.com/contributing
122 | */
123 |
124 | define(
125 | 'tinymce.plugins.directionality.core.Direction',
126 | [
127 | 'tinymce.core.util.Tools'
128 | ],
129 | function (Tools) {
130 | var setDir = function (editor, dir) {
131 | var dom = editor.dom, curDir, blocks = editor.selection.getSelectedBlocks();
132 |
133 | if (blocks.length) {
134 | curDir = dom.getAttrib(blocks[0], 'dir');
135 |
136 | Tools.each(blocks, function (block) {
137 | // Add dir to block if the parent block doesn't already have that dir
138 | if (!dom.getParent(block.parentNode, '*[dir="' + dir + '"]', dom.getRoot())) {
139 | dom.setAttrib(block, 'dir', curDir !== dir ? dir : null);
140 | }
141 | });
142 |
143 | editor.nodeChanged();
144 | }
145 | };
146 |
147 | return {
148 | setDir: setDir
149 | };
150 | }
151 | );
152 |
153 | /**
154 | * Commands.js
155 | *
156 | * Released under LGPL License.
157 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
158 | *
159 | * License: http://www.tinymce.com/license
160 | * Contributing: http://www.tinymce.com/contributing
161 | */
162 |
163 | define(
164 | 'tinymce.plugins.directionality.api.Commands',
165 | [
166 | 'tinymce.plugins.directionality.core.Direction'
167 | ],
168 | function (Direction) {
169 | var register = function (editor) {
170 | editor.addCommand('mceDirectionLTR', function () {
171 | Direction.setDir(editor, 'ltr');
172 | });
173 |
174 | editor.addCommand('mceDirectionRTL', function () {
175 | Direction.setDir(editor, 'rtl');
176 | });
177 | };
178 |
179 | return {
180 | register: register
181 | };
182 | }
183 | );
184 | /**
185 | * Buttons.js
186 | *
187 | * Released under LGPL License.
188 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
189 | *
190 | * License: http://www.tinymce.com/license
191 | * Contributing: http://www.tinymce.com/contributing
192 | */
193 |
194 | define(
195 | 'tinymce.plugins.directionality.ui.Buttons',
196 | [
197 | 'tinymce.core.util.Tools'
198 | ],
199 | function (Tools) {
200 | var generateSelector = function (dir) {
201 | var selector = [];
202 |
203 | Tools.each('h1 h2 h3 h4 h5 h6 div p'.split(' '), function (name) {
204 | selector.push(name + '[dir=' + dir + ']');
205 | });
206 |
207 | return selector.join(',');
208 | };
209 |
210 | var register = function (editor) {
211 | editor.addButton('ltr', {
212 | title: 'Left to right',
213 | cmd: 'mceDirectionLTR',
214 | stateSelector: generateSelector('ltr')
215 | });
216 |
217 | editor.addButton('rtl', {
218 | title: 'Right to left',
219 | cmd: 'mceDirectionRTL',
220 | stateSelector: generateSelector('rtl')
221 | });
222 | };
223 |
224 | return {
225 | register: register
226 | };
227 | }
228 | );
229 | /**
230 | * Plugin.js
231 | *
232 | * Released under LGPL License.
233 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
234 | *
235 | * License: http://www.tinymce.com/license
236 | * Contributing: http://www.tinymce.com/contributing
237 | */
238 |
239 | define(
240 | 'tinymce.plugins.directionality.Plugin',
241 | [
242 | 'tinymce.core.PluginManager',
243 | 'tinymce.plugins.directionality.api.Commands',
244 | 'tinymce.plugins.directionality.ui.Buttons'
245 | ],
246 | function (PluginManager, Commands, Buttons) {
247 | PluginManager.add('directionality', function (editor) {
248 | Commands.register(editor);
249 | Buttons.register(editor);
250 | });
251 |
252 | return function () { };
253 | }
254 | );
255 | dem('tinymce.plugins.directionality.Plugin')();
256 | })();
257 |
--------------------------------------------------------------------------------
/src/components/tinymce/plugins/template/plugin.min.js:
--------------------------------------------------------------------------------
1 | !(function () { var a = {}, b = function (b) { for (var c = a[b], e = c.deps, f = c.defn, g = e.length, h = new Array(g), i = 0; i < g; ++i)h[i] = d(e[i]); var j = f.apply(null, h); if (void 0 === j) throw 'module [' + b + '] returned undefined'; c.instance = j; }, c = function (b, c, d) { if (typeof b !== 'string') throw 'module id must be a string'; if (void 0 === c) throw 'no dependencies for ' + b; if (void 0 === d) throw 'no definition function for ' + b; a[b] = {deps: c, defn: d, instance: void 0}; }, d = function (c) { var d = a[c]; if (void 0 === d) throw 'module [' + c + '] was undefined'; return void 0 === d.instance && b(c), d.instance; }, e = function (a, b) { for (var c = a.length, e = new Array(c), f = 0; f < c; ++f)e[f] = d(a[f]); b.apply(null, e); }, f = {}; f.bolt = {module: {api: {define: c, require: e, demand: d}}}; var g = c, h = function (a, b) { g(a, [], function () { return b; }); }; h('5', tinymce.util.Tools.resolve), g('1', ['5'], function (a) { return a('tinymce.PluginManager'); }), h('c', Array), h('d', Error), g('6', ['c', 'd'], function (a, b) { var c = function () {}, d = function (a, b) { return function () { return a(b.apply(null, arguments)); }; }, e = function (a) { return function () { return a; }; }, f = function (a) { return a; }, g = function (a, b) { return a === b; }, h = function (b) { for (var c = new a(arguments.length - 1), d = 1; d < arguments.length; d++)c[d - 1] = arguments[d]; return function () { for (var d = new a(arguments.length), e = 0; e < d.length; e++)d[e] = arguments[e]; var f = c.concat(d); return b.apply(null, f); }; }, i = function (a) { return function () { return !a.apply(null, arguments); }; }, j = function (a) { return function () { throw new b(a); }; }, k = function (a) { return a(); }, l = function (a) { a(); }, m = e(!1), n = e(!0); return {noop: c, compose: d, constant: e, identity: f, tripleEquals: g, curry: h, not: i, die: j, apply: k, call: l, never: m, always: n}; }), g('8', ['5'], function (a) { return a('tinymce.util.Tools'); }), g('e', ['5'], function (a) { return a('tinymce.util.XHR'); }), g('f', ['5'], function (a) { return a('tinymce.dom.DOMUtils'); }), g('9', ['f'], function (a) { var b = function (a) { return a.getParam('template_cdate_classes', 'cdate'); }, c = function (a) { return a.getParam('template_mdate_classes', 'mdate'); }, d = function (a) { return a.getParam('template_selected_content_classes', 'selcontent'); }, e = function (a) { return a.getParam('template_preview_replace_values'); }, f = function (a) { return a.getParam('template_replace_values'); }, g = function (a) { return a.templates; }, h = function (a) { return a.getParam('template_cdate_format', a.getLang('template.cdate_format')); }, i = function (a) { return a.getParam('template_mdate_format', a.getLang('template.mdate_format')); }, j = function (a) { return a.getParam('template_popup_width', 600); }, k = function (b) { return Math.min(a.DOM.getViewPort().h, b.getParam('template_popup_height', 500)); }; return {getCreationDateClasses: b, getModificationDateClasses: c, getSelectedContentClasses: d, getPreviewReplaceValues: e, getTemplateReplaceValues: f, getTemplates: g, getCdateFormat: h, getMdateFormat: i, getDialogWidth: j, getDialogHeight: k}; }), g('a', [], function () { var a = function (a, b) { if (a = '' + a, a.length < b) for (var c = 0; c < b - a.length; c++)a = '0' + a; return a; }, b = function (b, c, d) { var e = 'Sun Mon Tue Wed Thu Fri Sat Sun'.split(' '), f = 'Sunday Monday Tuesday Wednesday Thursday Friday Saturday Sunday'.split(' '), g = 'Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec'.split(' '), h = 'January February March April May June July August September October November December'.split(' '); return d = d || new Date(), c = c.replace('%D', '%m/%d/%Y'), c = c.replace('%r', '%I:%M:%S %p'), c = c.replace('%Y', '' + d.getFullYear()), c = c.replace('%y', '' + d.getYear()), c = c.replace('%m', a(d.getMonth() + 1, 2)), c = c.replace('%d', a(d.getDate(), 2)), c = c.replace('%H', '' + a(d.getHours(), 2)), c = c.replace('%M', '' + a(d.getMinutes(), 2)), c = c.replace('%S', '' + a(d.getSeconds(), 2)), c = c.replace('%I', '' + ((d.getHours() + 11) % 12 + 1)), c = c.replace('%p', '' + (d.getHours() < 12 ? 'AM' : 'PM')), c = c.replace('%B', '' + b.translate(h[d.getMonth()])), c = c.replace('%b', '' + b.translate(g[d.getMonth()])), c = c.replace('%A', '' + b.translate(f[d.getDay()])), c = c.replace('%a', '' + b.translate(e[d.getDay()])), c = c.replace('%%', '%'); }; return {getDateTime: b}; }), g('7', ['8', 'e', '9', 'a'], function (a, b, c, d) { var e = function (a, d) { return function () { var e = c.getTemplates(a); return typeof e === 'function' ? void e(d) : void (typeof e === 'string' ? b.send({url: e, success: function (a) { d(JSON.parse(a)); }}) : d(e)); }; }, f = function (b, c, d) { return a.each(d, function (a, b) { typeof a === 'function' && (a = a(b)), c = c.replace(new RegExp('\\{\\$' + b + '\\}', 'g'), a); }), c; }, g = function (b, d) { var e = b.dom, f = c.getTemplateReplaceValues(b); a.each(e.select('*', d), function (b) { a.each(f, function (a, c) { e.hasClass(b, c) && typeof f[c] === 'function' && f[c](b); }); }); }, h = function (a, b) { return new RegExp('\\b' + b + '\\b', 'g').test(a.className); }, i = function (b, e, i) { var j, k, l = b.dom, m = b.selection.getContent(); i = f(b, i, c.getTemplateReplaceValues(b)), j = l.create('div', null, i), k = l.select('.mceTmpl', j), k && k.length > 0 && (j = l.create('div', null), j.appendChild(k[0].cloneNode(!0))), a.each(l.select('*', j), function (a) { h(a, c.getCreationDateClasses(b).replace(/\s+/g, '|')) && (a.innerHTML = d.getDateTime(b, c.getCdateFormat(b))), h(a, c.getModificationDateClasses(b).replace(/\s+/g, '|')) && (a.innerHTML = d.getDateTime(b, c.getMdateFormat(b))), h(a, c.getSelectedContentClasses(b).replace(/\s+/g, '|')) && (a.innerHTML = m); }), g(b, j), b.execCommand('mceInsertContent', !1, j.innerHTML), b.addVisual(); }; return {createTemplateList: e, replaceTemplateValues: f, replaceVals: g, insertTemplate: i}; }), g('2', ['6', '7'], function (a, b) { var c = function (c) { c.addCommand('mceInsertTemplate', a.curry(b.insertTemplate, c)); }; return {register: c}; }), g('3', ['8', '9', 'a', '7'], function (a, b, c, d) { var e = function (e) { e.on('PreProcess', function (f) { var g = e.dom, h = b.getMdateFormat(e); a.each(g.select('div', f.node), function (b) { g.hasClass(b, 'mceTmpl') && (a.each(g.select('*', b), function (a) { g.hasClass(a, e.getParam('template_mdate_classes', 'mdate').replace(/\s+/g, '|')) && (a.innerHTML = c.getDateTime(e, h)); }), d.replaceVals(e, b)); }); }); }; return {setup: e}; }), g('b', ['f', '8', 'e', '9', '7'], function (a, b, c, d, e) { var f = function (a, c, f) { if (f.indexOf('') === -1) { var g = ''; b.each(a.contentCSS, function (b) { g += ' '; }); var h = a.settings.body_class || ''; h.indexOf('=') !== -1 && (h = a.getParam('body_class', '', 'hash'), h = h[a.id] || ''), f = '' + g + '' + f + ''; }f = e.replaceTemplateValues(a, f, d.getPreviewReplaceValues(a)); var i = c.find('iframe')[0].getEl().contentWindow.document; i.open(), i.write(f), i.close(); }, g = function (a, g) { var h, i, j = []; if (!g || g.length === 0) { var k = a.translate('No templates defined.'); return void a.notificationManager.open({text: k, type: 'info'}); }b.each(g, function (a) { j.push({selected: !j.length, text: a.title, value: {url: a.url, content: a.content, description: a.description}}); }); var l = function (b) { var d = b.control.value(); d.url ? c.send({url: d.url, success: function (b) { i = b, f(a, h, i); }}) : (i = d.content, f(a, h, i)), h.find('#description')[0].text(b.control.value().description); }; h = a.windowManager.open({title: 'Insert template', layout: 'flex', direction: 'column', align: 'stretch', padding: 15, spacing: 10, items: [{type: 'form', flex: 0, padding: 0, items: [{type: 'container', label: 'Templates', items: {type: 'listbox', label: 'Templates', name: 'template', values: j, onselect: l}}]}, {type: 'label', name: 'description', label: 'Description', text: '\xa0'}, {type: 'iframe', flex: 1, border: 1}], onsubmit: function () { e.insertTemplate(a, !1, i); }, minWidth: d.getDialogWidth(a), minHeight: d.getDialogHeight(a)}), h.find('listbox')[0].fire('select'); }; return {open: g}; }), g('4', ['7', 'b'], function (a, b) { var c = function (a) { return function (c) { b.open(a, c); }; }, d = function (b) { b.addButton('template', {title: 'Insert template', onclick: a.createTemplateList(b.settings, c(b))}), b.addMenuItem('template', {text: 'Template', onclick: a.createTemplateList(b.settings, c(b)), icon: 'template', context: 'insert'}); }; return {register: d}; }), g('0', ['1', '2', '3', '4'], function (a, b, c, d) { return a.add('template', function (a) { d.register(a), b.register(a), c.setup(a); }), function () {}; }), d('0')(); }());
2 |
--------------------------------------------------------------------------------
/src/components/tinymce/langs/en_GB.js:
--------------------------------------------------------------------------------
1 | tinymce.addI18n('en_GB', {
2 | 'Cut': 'Cut',
3 | 'Heading 5': 'Heading 5',
4 | 'Header 2': 'Header 2',
5 | 'Your browser doesn\'t support direct access to the clipboard. Please use the Ctrl+X\/C\/V keyboard shortcuts instead.': 'Your browser doesn\'t support direct access to the clipboard. Please use the Ctrl+X\/C\/V keyboard shortcuts instead.',
6 | 'Heading 4': 'Heading 4',
7 | 'Div': 'Div',
8 | 'Heading 2': 'Heading 2',
9 | 'Paste': 'Paste',
10 | 'Close': 'Close',
11 | 'Font Family': 'Font Family',
12 | 'Pre': 'Pre',
13 | 'Align right': 'Align right',
14 | 'New document': 'New document',
15 | 'Blockquote': 'Blockquote',
16 | 'Numbered list': 'Numbered list',
17 | 'Heading 1': 'Heading 1',
18 | 'Headings': 'Headings',
19 | 'Increase indent': 'Increase indent',
20 | 'Formats': 'Formats',
21 | 'Headers': 'Headers',
22 | 'Select all': 'Select all',
23 | 'Header 3': 'Header 3',
24 | 'Blocks': 'Blocks',
25 | 'Undo': 'Undo',
26 | 'Strikethrough': 'Strike-through',
27 | 'Bullet list': 'Bullet list',
28 | 'Header 1': 'Header 1',
29 | 'Superscript': 'Superscript',
30 | 'Clear formatting': 'Clear formatting',
31 | 'Font Sizes': 'Font Sizes',
32 | 'Subscript': 'Subscript',
33 | 'Header 6': 'Header 6',
34 | 'Redo': 'Redo',
35 | 'Paragraph': 'Paragraph',
36 | 'Ok': 'Ok',
37 | 'Bold': 'Bold',
38 | 'Code': 'Code',
39 | 'Italic': 'Italic',
40 | 'Align center': 'Align centre',
41 | 'Header 5': 'Header 5',
42 | 'Heading 6': 'Heading 6',
43 | 'Heading 3': 'Heading 3',
44 | 'Decrease indent': 'Decrease indent',
45 | 'Header 4': 'Header 4',
46 | 'Paste is now in plain text mode. Contents will now be pasted as plain text until you toggle this option off.': 'Paste is now in plain text mode. Contents will now be pasted as plain text until you toggle this option off.',
47 | 'Underline': 'Underline',
48 | 'Cancel': 'Cancel',
49 | 'Justify': 'Justify',
50 | 'Inline': 'Inline',
51 | 'Copy': 'Copy',
52 | 'Align left': 'Align left',
53 | 'Visual aids': 'Visual aids',
54 | 'Lower Greek': 'Lower Greek',
55 | 'Square': 'Square',
56 | 'Default': 'Default',
57 | 'Lower Alpha': 'Lower Alpha',
58 | 'Circle': 'Circle',
59 | 'Disc': 'Disc',
60 | 'Upper Alpha': 'Upper Alpha',
61 | 'Upper Roman': 'Upper Roman',
62 | 'Lower Roman': 'Lower Roman',
63 | 'Id should start with a letter, followed only by letters, numbers, dashes, dots, colons or underscores.': 'ID should start with a letter, followed only by letters, numbers, dashes, dots, colons or underscores.',
64 | 'Name': 'Name',
65 | 'Anchor': 'Anchor',
66 | 'Id': 'ID',
67 | 'You have unsaved changes are you sure you want to navigate away?': 'You have unsaved changes are you sure you want to navigate away?',
68 | 'Restore last draft': 'Restore last draft',
69 | 'Special character': 'Special character',
70 | 'Source code': 'Source code',
71 | 'Language': 'Language',
72 | 'Insert\/Edit code sample': 'Insert\/Edit code sample',
73 | 'B': 'B',
74 | 'R': 'R',
75 | 'G': 'G',
76 | 'Color': 'Colour',
77 | 'Right to left': 'Right to left',
78 | 'Left to right': 'Left to right',
79 | 'Emoticons': 'Emoticons',
80 | 'Robots': 'Robots',
81 | 'Document properties': 'Document properties',
82 | 'Title': 'Title',
83 | 'Keywords': 'Keywords',
84 | 'Encoding': 'Encoding',
85 | 'Description': 'Description',
86 | 'Author': 'Author',
87 | 'Fullscreen': 'Full-screen',
88 | 'Horizontal line': 'Horizontal line',
89 | 'Horizontal space': 'Horizontal space',
90 | 'Insert\/edit image': 'Insert\/edit image',
91 | 'General': 'General',
92 | 'Advanced': 'Advanced',
93 | 'Source': 'Source',
94 | 'Border': 'Border',
95 | 'Constrain proportions': 'Constrain proportions',
96 | 'Vertical space': 'Vertical space',
97 | 'Image description': 'Image description',
98 | 'Style': 'Style',
99 | 'Dimensions': 'Dimensions',
100 | 'Insert image': 'Insert image',
101 | 'Image': 'Image',
102 | 'Zoom in': 'Zoom in',
103 | 'Contrast': 'Contrast',
104 | 'Back': 'Back',
105 | 'Gamma': 'Gamma',
106 | 'Flip horizontally': 'Flip horizontally',
107 | 'Resize': 'Resize',
108 | 'Sharpen': 'Sharpen',
109 | 'Zoom out': 'Zoom out',
110 | 'Image options': 'Image options',
111 | 'Apply': 'Apply',
112 | 'Brightness': 'Brightness',
113 | 'Rotate clockwise': 'Rotate clockwise',
114 | 'Rotate counterclockwise': 'Rotate counterclockwise',
115 | 'Edit image': 'Edit image',
116 | 'Color levels': 'Colour levels',
117 | 'Crop': 'Crop',
118 | 'Orientation': 'Orientation',
119 | 'Flip vertically': 'Flip vertically',
120 | 'Invert': 'Invert',
121 | 'Date\/time': 'Date\/time',
122 | 'Insert date\/time': 'Insert date\/time',
123 | 'Remove link': 'Remove link',
124 | 'Url': 'URL',
125 | 'Text to display': 'Text to display',
126 | 'Anchors': 'Anchors',
127 | 'Insert link': 'Insert link',
128 | 'Link': 'Link',
129 | 'New window': 'New window',
130 | 'None': 'None',
131 | 'The URL you entered seems to be an external link. Do you want to add the required http:\/\/ prefix?': 'The URL you entered seems to be an external link. Do you want to add the required http:\/\/ prefix?',
132 | 'Paste or type a link': 'Paste or type a link',
133 | 'Target': 'Target',
134 | 'The URL you entered seems to be an email address. Do you want to add the required mailto: prefix?': 'The URL you entered seems to be an email address. Do you want to add the required mailto: prefix?',
135 | 'Insert\/edit link': 'Insert\/edit link',
136 | 'Insert\/edit video': 'Insert\/edit video',
137 | 'Media': 'Media',
138 | 'Alternative source': 'Alternative source',
139 | 'Paste your embed code below:': 'Paste your embed code below:',
140 | 'Insert video': 'Insert video',
141 | 'Poster': 'Poster',
142 | 'Insert\/edit media': 'Insert\/edit media',
143 | 'Embed': 'Embed',
144 | 'Nonbreaking space': 'Non-breaking space',
145 | 'Page break': 'Page break',
146 | 'Paste as text': 'Paste as text',
147 | 'Preview': 'Preview',
148 | 'Print': 'Print',
149 | 'Save': 'Save',
150 | 'Could not find the specified string.': 'Could not find the specified string.',
151 | 'Replace': 'Replace',
152 | 'Next': 'Next',
153 | 'Whole words': 'Whole words',
154 | 'Find and replace': 'Find and replace',
155 | 'Replace with': 'Replace with',
156 | 'Find': 'Find',
157 | 'Replace all': 'Replace all',
158 | 'Match case': 'Match case',
159 | 'Prev': 'Prev',
160 | 'Spellcheck': 'Spell-check',
161 | 'Finish': 'Finish',
162 | 'Ignore all': 'Ignore all',
163 | 'Ignore': 'Ignore',
164 | 'Add to Dictionary': 'Add to Dictionary',
165 | 'Insert row before': 'Insert row before',
166 | 'Rows': 'Rows',
167 | 'Height': 'Height',
168 | 'Paste row after': 'Paste row after',
169 | 'Alignment': 'Alignment',
170 | 'Border color': 'Border colour',
171 | 'Column group': 'Column group',
172 | 'Row': 'Row',
173 | 'Insert column before': 'Insert column before',
174 | 'Split cell': 'Split cell',
175 | 'Cell padding': 'Cell padding',
176 | 'Cell spacing': 'Cell spacing',
177 | 'Row type': 'Row type',
178 | 'Insert table': 'Insert table',
179 | 'Body': 'Body',
180 | 'Caption': 'Caption',
181 | 'Footer': 'Footer',
182 | 'Delete row': 'Delete row',
183 | 'Paste row before': 'Paste row before',
184 | 'Scope': 'Scope',
185 | 'Delete table': 'Delete table',
186 | 'H Align': 'H Align',
187 | 'Top': 'Top',
188 | 'Header cell': 'Header cell',
189 | 'Column': 'Column',
190 | 'Row group': 'Row group',
191 | 'Cell': 'Cell',
192 | 'Middle': 'Middle',
193 | 'Cell type': 'Cell type',
194 | 'Copy row': 'Copy row',
195 | 'Row properties': 'Row properties',
196 | 'Table properties': 'Table properties',
197 | 'Bottom': 'Bottom',
198 | 'V Align': 'V Align',
199 | 'Header': 'Header',
200 | 'Right': 'Right',
201 | 'Insert column after': 'Insert column after',
202 | 'Cols': 'Cols',
203 | 'Insert row after': 'Insert row after',
204 | 'Width': 'Width',
205 | 'Cell properties': 'Cell properties',
206 | 'Left': 'Left',
207 | 'Cut row': 'Cut row',
208 | 'Delete column': 'Delete column',
209 | 'Center': 'Centre',
210 | 'Merge cells': 'Merge cells',
211 | 'Insert template': 'Insert template',
212 | 'Templates': 'Templates',
213 | 'Background color': 'Background colour',
214 | 'Custom...': 'Custom...',
215 | 'Custom color': 'Custom colour',
216 | 'No color': 'No colour',
217 | 'Text color': 'Text colour',
218 | 'Table of Contents': 'Table of Contents',
219 | 'Show blocks': 'Show blocks',
220 | 'Show invisible characters': 'Show invisible characters',
221 | 'Words: {0}': 'Words: {0}',
222 | 'Insert': 'Insert',
223 | 'File': 'File',
224 | 'Edit': 'Edit',
225 | 'Rich Text Area. Press ALT-F9 for menu. Press ALT-F10 for toolbar. Press ALT-0 for help': 'Rich Text Area. Press ALT-F9 for menu. Press ALT-F10 for toolbar. Press ALT-0 for help',
226 | 'Tools': 'Tools',
227 | 'View': 'View',
228 | 'Table': 'Table',
229 | 'Format': 'Format'
230 | });
231 |
--------------------------------------------------------------------------------
/src/components/tinymce/plugins/colorpicker/plugin.js:
--------------------------------------------------------------------------------
1 | (function () {
2 | var defs = {}; // id -> {dependencies, definition, instance (possibly undefined)}
3 |
4 | // Used when there is no 'main' module.
5 | // The name is probably (hopefully) unique so minification removes for releases.
6 | var register_3795 = function (id) {
7 | var module = dem(id);
8 | var fragments = id.split('.');
9 | var target = Function('return this;')();
10 | for (var i = 0; i < fragments.length - 1; ++i) {
11 | if (target[fragments[i]] === undefined) { target[fragments[i]] = {}; }
12 | target = target[fragments[i]];
13 | }
14 | target[fragments[fragments.length - 1]] = module;
15 | };
16 |
17 | var instantiate = function (id) {
18 | var actual = defs[id];
19 | var dependencies = actual.deps;
20 | var definition = actual.defn;
21 | var len = dependencies.length;
22 | var instances = new Array(len);
23 | for (var i = 0; i < len; ++i) { instances[i] = dem(dependencies[i]); }
24 | var defResult = definition.apply(null, instances);
25 | if (defResult === undefined) { throw 'module [' + id + '] returned undefined'; }
26 | actual.instance = defResult;
27 | };
28 |
29 | var def = function (id, dependencies, definition) {
30 | if (typeof id !== 'string') { throw 'module id must be a string'; } else if (dependencies === undefined) { throw 'no dependencies for ' + id; } else if (definition === undefined) { throw 'no definition function for ' + id; }
31 | defs[id] = {
32 | deps: dependencies,
33 | defn: definition,
34 | instance: undefined
35 | };
36 | };
37 |
38 | var dem = function (id) {
39 | var actual = defs[id];
40 | if (actual === undefined) { throw 'module [' + id + '] was undefined'; } else if (actual.instance === undefined) { instantiate(id); }
41 | return actual.instance;
42 | };
43 |
44 | var req = function (ids, callback) {
45 | var len = ids.length;
46 | var instances = new Array(len);
47 | for (var i = 0; i < len; ++i) { instances[i] = dem(ids[i]); }
48 | callback.apply(null, instances);
49 | };
50 |
51 | var ephox = {};
52 |
53 | ephox.bolt = {
54 | module: {
55 | api: {
56 | define: def,
57 | require: req,
58 | demand: dem
59 | }
60 | }
61 | };
62 |
63 | var define = def;
64 | var require = req;
65 | var demand = dem;
66 | // this helps with minification when using a lot of global references
67 | var defineGlobal = function (id, ref) {
68 | define(id, [], function () { return ref; });
69 | };
70 | /* jsc
71 | ["tinymce.plugins.colorpicker.Plugin","tinymce.core.PluginManager","tinymce.plugins.colorpicker.ui.Dialog","global!tinymce.util.Tools.resolve","tinymce.core.util.Color"]
72 | jsc */
73 | defineGlobal('global!tinymce.util.Tools.resolve', tinymce.util.Tools.resolve);
74 | /**
75 | * ResolveGlobal.js
76 | *
77 | * Released under LGPL License.
78 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
79 | *
80 | * License: http://www.tinymce.com/license
81 | * Contributing: http://www.tinymce.com/contributing
82 | */
83 |
84 | define(
85 | 'tinymce.core.PluginManager',
86 | [
87 | 'global!tinymce.util.Tools.resolve'
88 | ],
89 | function (resolve) {
90 | return resolve('tinymce.PluginManager');
91 | }
92 | );
93 |
94 | /**
95 | * ResolveGlobal.js
96 | *
97 | * Released under LGPL License.
98 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
99 | *
100 | * License: http://www.tinymce.com/license
101 | * Contributing: http://www.tinymce.com/contributing
102 | */
103 |
104 | define(
105 | 'tinymce.core.util.Color',
106 | [
107 | 'global!tinymce.util.Tools.resolve'
108 | ],
109 | function (resolve) {
110 | return resolve('tinymce.util.Color');
111 | }
112 | );
113 |
114 | /**
115 | * Dialog.js
116 | *
117 | * Released under LGPL License.
118 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
119 | *
120 | * License: http://www.tinymce.com/license
121 | * Contributing: http://www.tinymce.com/contributing
122 | */
123 |
124 | define(
125 | 'tinymce.plugins.colorpicker.ui.Dialog',
126 | [
127 | 'tinymce.core.util.Color'
128 | ],
129 | function (Color) {
130 | var showPreview = function (win, hexColor) {
131 | win.find('#preview')[0].getEl().style.background = hexColor;
132 | };
133 |
134 | var setColor = function (win, value) {
135 | var color = new Color(value), rgb = color.toRgb();
136 |
137 | win.fromJSON({
138 | r: rgb.r,
139 | g: rgb.g,
140 | b: rgb.b,
141 | hex: color.toHex().substr(1)
142 | });
143 |
144 | showPreview(win, color.toHex());
145 | };
146 |
147 | var open = function (editor, callback, value) {
148 | var win = editor.windowManager.open({
149 | title: 'Color',
150 | items: {
151 | type: 'container',
152 | layout: 'flex',
153 | direction: 'row',
154 | align: 'stretch',
155 | padding: 5,
156 | spacing: 10,
157 | items: [
158 | {
159 | type: 'colorpicker',
160 | value: value,
161 | onchange: function () {
162 | var rgb = this.rgb();
163 |
164 | if (win) {
165 | win.find('#r').value(rgb.r);
166 | win.find('#g').value(rgb.g);
167 | win.find('#b').value(rgb.b);
168 | win.find('#hex').value(this.value().substr(1));
169 | showPreview(win, this.value());
170 | }
171 | }
172 | },
173 | {
174 | type: 'form',
175 | padding: 0,
176 | labelGap: 5,
177 | defaults: {
178 | type: 'textbox',
179 | size: 7,
180 | value: '0',
181 | flex: 1,
182 | spellcheck: false,
183 | onchange: function () {
184 | var colorPickerCtrl = win.find('colorpicker')[0];
185 | var name, value;
186 |
187 | name = this.name();
188 | value = this.value();
189 |
190 | if (name === 'hex') {
191 | value = '#' + value;
192 | setColor(win, value);
193 | colorPickerCtrl.value(value);
194 | return;
195 | }
196 |
197 | value = {
198 | r: win.find('#r').value(),
199 | g: win.find('#g').value(),
200 | b: win.find('#b').value()
201 | };
202 |
203 | colorPickerCtrl.value(value);
204 | setColor(win, value);
205 | }
206 | },
207 | items: [
208 | { name: 'r', label: 'R', autofocus: 1 },
209 | { name: 'g', label: 'G' },
210 | { name: 'b', label: 'B' },
211 | { name: 'hex', label: '#', value: '000000' },
212 | { name: 'preview', type: 'container', border: 1 }
213 | ]
214 | }
215 | ]
216 | },
217 | onSubmit: function () {
218 | callback('#' + win.toJSON().hex);
219 | }
220 | });
221 |
222 | setColor(win, value);
223 | };
224 |
225 | return {
226 | open: open
227 | };
228 | }
229 | );
230 | /**
231 | * Plugin.js
232 | *
233 | * Released under LGPL License.
234 | * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
235 | *
236 | * License: http://www.tinymce.com/license
237 | * Contributing: http://www.tinymce.com/contributing
238 | */
239 |
240 | define(
241 | 'tinymce.plugins.colorpicker.Plugin',
242 | [
243 | 'tinymce.core.PluginManager',
244 | 'tinymce.plugins.colorpicker.ui.Dialog'
245 | ],
246 | function (PluginManager, Dialog) {
247 | PluginManager.add('colorpicker', function (editor) {
248 | if (!editor.settings.color_picker_callback) {
249 | editor.settings.color_picker_callback = function (callback, value) {
250 | Dialog.open(editor, callback, value);
251 | };
252 | }
253 | });
254 |
255 | return function () { };
256 | }
257 | );
258 | dem('tinymce.plugins.colorpicker.Plugin')();
259 | })();
260 |
--------------------------------------------------------------------------------
/src/components/tinymce/plugins/contextmenu/plugin.min.js:
--------------------------------------------------------------------------------
1 | !(function () { var a = {}, b = function (b) { for (var c = a[b], e = c.deps, f = c.defn, g = e.length, h = new Array(g), i = 0; i < g; ++i)h[i] = d(e[i]); var j = f.apply(null, h); if (void 0 === j) throw 'module [' + b + '] returned undefined'; c.instance = j; }, c = function (b, c, d) { if (typeof b !== 'string') throw 'module id must be a string'; if (void 0 === c) throw 'no dependencies for ' + b; if (void 0 === d) throw 'no definition function for ' + b; a[b] = {deps: c, defn: d, instance: void 0}; }, d = function (c) { var d = a[c]; if (void 0 === d) throw 'module [' + c + '] was undefined'; return void 0 === d.instance && b(c), d.instance; }, e = function (a, b) { for (var c = a.length, e = new Array(c), f = 0; f < c; ++f)e[f] = d(a[f]); b.apply(null, e); }, f = {}; f.bolt = {module: {api: {define: c, require: e, demand: d}}}; var g = c, h = function (a, b) { g(a, [], function () { return b; }); }; g('1', [], function () { var a = function (b) { var c = b, d = function () { return c; }, e = function (a) { c = a; }, f = function () { return a(d()); }; return {get: d, set: e, clone: f}; }; return a; }), h('5', tinymce.util.Tools.resolve), g('2', ['5'], function (a) { return a('tinymce.PluginManager'); }), g('3', [], function () { var a = function (a) { var b = function () { return a.get(); }; return {isContextMenuVisible: b}; }; return {get: a}; }), g('6', ['5'], function (a) { return a('tinymce.dom.DOMUtils'); }), g('7', ['5'], function (a) { return a('tinymce.Env'); }), g('8', [], function () { var a = function (a) { return a.settings.contextmenu_never_use_native; }, b = function (a) { return a.getParam('contextmenu', 'link openlink image inserttable | cell row column deletetable'); }; return {shouldNeverUseNative: a, getContextMenu: b}; }), h('f', Array), h('g', Error), g('i', ['f', 'g'], function (a, b) { var c = function () {}, d = function (a, b) { return function () { return a(b.apply(null, arguments)); }; }, e = function (a) { return function () { return a; }; }, f = function (a) { return a; }, g = function (a, b) { return a === b; }, h = function (b) { for (var c = new a(arguments.length - 1), d = 1; d < arguments.length; d++)c[d - 1] = arguments[d]; return function () { for (var d = new a(arguments.length), e = 0; e < d.length; e++)d[e] = arguments[e]; var f = c.concat(d); return b.apply(null, f); }; }, i = function (a) { return function () { return !a.apply(null, arguments); }; }, j = function (a) { return function () { throw new b(a); }; }, k = function (a) { return a(); }, l = function (a) { a(); }, m = e(!1), n = e(!0); return {noop: c, compose: d, constant: e, identity: f, tripleEquals: g, curry: h, not: i, die: j, apply: k, call: l, never: m, always: n}; }), h('j', Object), g('e', ['i', 'j'], function (a, b) { var c = a.never, d = a.always, e = function () { return f; }, f = (function () { var f = function (a) { return a.isNone(); }, g = function (a) { return a(); }, h = function (a) { return a; }, i = function () {}, j = {fold: function (a, b) { return a(); }, is: c, isSome: c, isNone: d, getOr: h, getOrThunk: g, getOrDie: function (a) { throw new Error(a || 'error: getOrDie called on none.'); }, or: h, orThunk: g, map: e, ap: e, each: i, bind: e, flatten: e, exists: c, forall: d, filter: e, equals: f, equals_: f, toArray: function () { return []; }, toString: a.constant('none()')}; return b.freeze && b.freeze(j), j; }()), g = function (a) { var b = function () { return a; }, h = function () { return k; }, i = function (b) { return g(b(a)); }, j = function (b) { return b(a); }, k = {fold: function (b, c) { return c(a); }, is: function (b) { return a === b; }, isSome: d, isNone: c, getOr: b, getOrThunk: b, getOrDie: b, or: h, orThunk: h, map: i, ap: function (b) { return b.fold(e, function (b) { return g(b(a)); }); }, each: function (b) { b(a); }, bind: j, flatten: b, exists: j, forall: j, filter: function (b) { return b(a) ? k : f; }, equals: function (b) { return b.is(a); }, equals_: function (b, d) { return b.fold(c, function (b) { return d(a, b); }); }, toArray: function () { return [a]; }, toString: function () { return 'some(' + a + ')'; }}; return k; }, h = function (a) { return a === null || void 0 === a ? f : g(a); }; return {some: g, none: e, from: h}; }), h('h', String), g('b', ['e', 'f', 'g', 'h'], function (a, b, c, d) { var e = (function () { var a = b.prototype.indexOf, c = function (b, c) { return a.call(b, c); }, d = function (a, b) { return u(a, b); }; return void 0 === a ? d : c; }()), f = function (b, c) { var d = e(b, c); return d === -1 ? a.none() : a.some(d); }, g = function (a, b) { return e(a, b) > -1; }, h = function (a, b) { return t(a, b).isSome(); }, i = function (a, b) { for (var c = [], d = 0; d < a; d++)c.push(b(d)); return c; }, j = function (a, b) { for (var c = [], d = 0; d < a.length; d += b) { var e = a.slice(d, d + b); c.push(e); } return c; }, k = function (a, c) { for (var d = a.length, e = new b(d), f = 0; f < d; f++) { var g = a[f]; e[f] = c(g, f, a); } return e; }, l = function (a, b) { for (var c = 0, d = a.length; c < d; c++) { var e = a[c]; b(e, c, a); } }, m = function (a, b) { for (var c = a.length - 1; c >= 0; c--) { var d = a[c]; b(d, c, a); } }, n = function (a, b) { for (var c = [], d = [], e = 0, f = a.length; e < f; e++) { var g = a[e], h = b(g, e, a) ? c : d; h.push(g); } return {pass: c, fail: d}; }, o = function (a, b) { for (var c = [], d = 0, e = a.length; d < e; d++) { var f = a[d]; b(f, d, a) && c.push(f); } return c; }, p = function (a, b) { if (a.length === 0) return []; for (var c = b(a[0]), d = [], e = [], f = 0, g = a.length; f < g; f++) { var h = a[f], i = b(h); i !== c && (d.push(e), e = []), c = i, e.push(h); } return e.length !== 0 && d.push(e), d; }, q = function (a, b, c) { return m(a, function (a) { c = b(c, a); }), c; }, r = function (a, b, c) { return l(a, function (a) { c = b(c, a); }), c; }, s = function (b, c) { for (var d = 0, e = b.length; d < e; d++) { var f = b[d]; if (c(f, d, b)) return a.some(f); } return a.none(); }, t = function (b, c) { for (var d = 0, e = b.length; d < e; d++) { var f = b[d]; if (c(f, d, b)) return a.some(d); } return a.none(); }, u = function (a, b) { for (var c = 0, d = a.length; c < d; ++c) if (a[c] === b) return c; return -1; }, v = b.prototype.push, w = function (a) { for (var d = [], e = 0, f = a.length; e < f; ++e) { if (!b.prototype.isPrototypeOf(a[e])) throw new c('Arr.flatten item ' + e + ' was not an array, input: ' + a); v.apply(d, a[e]); } return d; }, x = function (a, b) { var c = k(a, b); return w(c); }, y = function (a, b) { for (var c = 0, d = a.length; c < d; ++c) { var e = a[c]; if (b(e, c, a) !== !0) return !1; } return !0; }, z = function (a, b) { return a.length === b.length && y(a, function (a, c) { return a === b[c]; }); }, A = b.prototype.slice, B = function (a) { var b = A.call(a, 0); return b.reverse(), b; }, C = function (a, b) { return o(a, function (a) { return !g(b, a); }); }, D = function (a, b) { for (var c = {}, e = 0, f = a.length; e < f; e++) { var g = a[e]; c[d(g)] = b(g, e); } return c; }, E = function (a) { return [a]; }, F = function (a, b) { var c = A.call(a, 0); return c.sort(b), c; }, G = function (b) { return b.length === 0 ? a.none() : a.some(b[0]); }, H = function (b) { return b.length === 0 ? a.none() : a.some(b[b.length - 1]); }; return {map: k, each: l, eachr: m, partition: n, filter: o, groupBy: p, indexOf: f, foldr: q, foldl: r, find: s, findIndex: t, flatten: w, bind: x, forall: y, exists: h, contains: g, equal: z, reverse: B, chunk: j, difference: C, mapToObject: D, pure: E, sort: F, range: i, head: G, last: H}; }), g('9', ['b'], function (a) { var b = function (a, b, c) { return b >= a.left && b <= a.right && c >= a.top && c <= a.bottom; }, c = function (c, d, e) { return !e.collapsed && a.foldl(e.getClientRects(), function (a, e) { return a || b(e, c, d); }, !1); }; return {isXYWithinRange: c}; }), g('c', ['5'], function (a) { return a('tinymce.ui.Factory'); }), g('d', ['5'], function (a) { return a('tinymce.util.Tools'); }), g('a', ['c', 'd', '8'], function (a, b, c) { var d = function (d, e) { var f, g, h = []; g = c.getContextMenu(d), b.each(g.split(/[ ,]/), function (a) { var b = d.menuItems[a]; a === '|' && (b = {text: a}), b && (b.shortcut = '', h.push(b)); }); for (var i = 0; i < h.length; i++)h[i].text === '|' && (i !== 0 && i !== h.length - 1 || h.splice(i, 1)); return f = a.create('menu', {items: h, context: 'contextmenu', classes: 'contextmenu'}).renderTo(), f.on('hide', function (a) { a.control === this && e.set(!1); }), d.on('remove', function () { f.remove(), f = null; }), f; }, e = function (a, b, c, e, f) { f.get() === null ? f.set(d(a, e)) : f.get().show(), f.get().moveTo(b, c), e.set(!0); }; return {show: e}; }), g('4', ['6', '7', '8', '9', 'a'], function (a, b, c, d, e) { var f = function (a, b) { return b.ctrlKey && !c.shouldNeverUseNative(a); }, g = function () { return b.mac && b.webkit; }, h = function (a) { return a && a.nodeName === 'IMG'; }, i = function (a, b) { return h(a.target) && d.isXYWithinRange(a.clientX, a.clientY, b) === !1; }, j = function (b, c, d) { b.on('mousedown', function (a) { g() && a.button === 2 && !f(b, a) && b.selection.isCollapsed() && b.once('contextmenu', function (a) { h(a.target) || b.selection.placeCaretAt(a.clientX, a.clientY); }); }), b.on('contextmenu', function (g) { var h = g.pageX, j = g.pageY; if (!b.inline) { var k = a.DOM.getPos(b.getContentAreaContainer()); h = k.x + g.clientX, j = k.y + g.clientY; }f(b, g) || (i(g, b.selection.getRng()) && b.selection.select(g.target), g.preventDefault(), e.show(b, h, j, c, d)); }); }; return {setup: j}; }), g('0', ['1', '2', '3', '4'], function (a, b, c, d) { return b.add('contextmenu', function (b) { var e = a(null), f = a(!1); return d.setup(b, f, e), c.get(f); }), function () {}; }), d('0')(); }());
2 |
--------------------------------------------------------------------------------