2 lines
8.4 KiB
JavaScript
2 lines
8.4 KiB
JavaScript
|
!function(){"use strict";var e,t,n,r,o,a,i=tinymce.util.Tools.resolve("tinymce.PluginManager"),l=function(e){return function(){return e}},c=function(a){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];for(var i=new Array(arguments.length-1),n=1;n<arguments.length;n++)i[n-1]=arguments[n];return function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n=new Array(arguments.length),r=0;r<n.length;r++)n[r]=arguments[r];var o=i.concat(n);return a.apply(null,o)}},u=l(!1),s=l(!0),f=u,m=s,d=function(){return p},p=(r={fold:function(e,t){return e()},is:f,isSome:f,isNone:m,getOr:n=function(e){return e},getOrThunk:t=function(e){return e()},getOrDie:function(e){throw new Error(e||"error: getOrDie called on none.")},getOrNull:function(){return null},getOrUndefined:function(){return undefined},or:n,orThunk:t,map:d,ap:d,each:function(){},bind:d,flatten:d,exists:f,forall:m,filter:d,equals:e=function(e){return e.isNone()},equals_:e,toArray:function(){return[]},toString:l("none()")},Object.freeze&&Object.freeze(r),r),h=function(n){var e=function(){return n},t=function(){return o},r=function(e){return e(n)},o={fold:function(e,t){return t(n)},is:function(e){return n===e},isSome:m,isNone:f,getOr:e,getOrThunk:e,getOrDie:e,getOrNull:e,getOrUndefined:e,or:t,orThunk:t,map:function(e){return h(e(n))},ap:function(e){return e.fold(d,function(e){return h(e(n))})},each:function(e){e(n)},bind:r,flatten:e,exists:r,forall:r,filter:function(e){return e(n)?o:p},equals:function(e){return e.is(n)},equals_:function(e,t){return e.fold(f,function(e){return t(n,e)})},toArray:function(){return[n]},toString:function(){return"some("+n+")"}};return o},y={some:h,none:d,from:function(e){return null===e||e===undefined?p:h(e)}},g=(o="function",function(e){return function(e){if(null===e)return"null";var t=typeof e;return"object"===t&&Array.prototype.isPrototypeOf(e)?"array":"object"===t&&String.prototype.isPrototypeOf(e)?"string":t}(e)===o}),k=(a=Array.prototype.indexOf)===undefined?function(e,t){return x(e,t)}:function(e,t){return a.call(e,t)},v=function(e,t){return-1<k(e,t)},b=function(e,t){for(var n=e.length,r=new Array(n),o=0;o<n;o++){var a=e[o];r[o]=t(a,o,e)}return r},x=function(e,t){for(var n=0,r=e.length;n<r;++n)if(e[n]===t)return n;return-1},w=(Array.prototype.slice,g(Array.from)&&Array.from,tinymce.util.Tools.resolve("tinymce.util.I18n")),A=tinymce.util.Tools.resolve("tinymce.Env"),C=A.mac?"\u2318":"Ctrl",S=A.mac?"Ctrl + Alt":"Shift + Alt",O={shortcuts:[{shortcut:C+" + B",action:"Bold"},{shortcut:C+" + I",action:"Italic"},{shortcut:C+" + U",action:"Underline"},{shortcut:C+" + A",action:"Select all"},{shortcut:C+" + Y or "+C+" + Shift + Z",action:"Redo"},{shortcut:C+" + Z",action:"Undo"},{shortcut:S+" + 1",action:"Header 1"},{shortcut:S+" + 2",action:"Header 2"},{shortcut:S+" + 3",action:"Header 3"},{shortcut:S+" + 4",action:"Header 4"},{shortcut:S+" + 5",action:"Header 5"},{shortcut:S+" + 6",action:"Header 6"},{shortcut:S+" + 7",action:"Paragraph"},{shortcut:S+" + 8",action:"Div"},{shortcut:S+" + 9",action:"Address"},{shortcut:"Alt + F9",action:"Focus to menubar"},{shortcut:"Alt + F10",action:"Focus to toolbar"},{shortcut:"Alt + F11",action:"Focus to element path"},{shortcut:"Ctrl + Shift + P > Ctrl + Shift + P",action:"Focus to contextual toolbar"},{shortcut:C+" + K",action:"Insert link (if link plugin activated)"},{shortcut:C+" + S",action:"Save (if save plugin activated)"},{shortcut:C+" + F",action:"Find (if searchreplace plugin activated)"}]},P=function(){var e=b(O.shortcuts,function(e){return'<tr data-mce-tabstop="1" tabindex="-1" aria-label="Action: '+(t=e).action+", Shortcut: "+t.shortcut.replace(/Ctrl/g,"Control")+'"><td>'+w.translate(e.action)+"</td><td>"+e.shortcut+"</td></tr>";var t}).join("");return{title:"Handy Shortcuts",type:"container",style:"overflow-y: auto; overflow-x: hidden; max-height: 250px",items:[{type:"container",html:'<div><table class="mce-table-striped"><thead><th>'+w.translate("Action")+"</th><th>"+w.translate("Shortcut")+"</th></thead>"+e+"</table></div>"}]}},T=Object.keys,_=[{key:"advlist",name:"Adv
|