oil-station/fuintCashier/static/tinymce/plugins/paste/plugin.min.js

9 lines
22 KiB
JavaScript
Raw Normal View History

2023-10-09 11:06:01 +08:00
/**
* Copyright (c) Tiny Technologies, Inc. All rights reserved.
* Licensed under the LGPL or a commercial license.
* For LGPL see License.txt in the project root for license information.
* For commercial licenses see https://www.tiny.cloud/
*
* Version: 5.6.2 (2020-12-08)
*/
!function(){"use strict";var e,t,n,r,d=function(e){var t=e;return{get:function(){return t},set:function(e){t=e}}},a=tinymce.util.Tools.resolve("tinymce.PluginManager"),o=function(e){return function(){return e}},i=o(!1),s=o(!0),u=function(){return l},l=(e=function(e){return e.isNone()},{fold:function(e,t){return e()},is:i,isSome:i,isNone:s,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:o(null),getOrUndefined:o(undefined),or:n,orThunk:t,map:u,each:function(){},bind:u,exists:i,forall:s,filter:u,equals:e,equals_:e,toArray:function(){return[]},toString:o("none()")}),c=function(n){var e=o(n),t=function(){return a},r=function(e){return e(n)},a={fold:function(e,t){return t(n)},is:function(e){return n===e},isSome:s,isNone:i,getOr:e,getOrThunk:e,getOrDie:e,getOrNull:e,getOrUndefined:e,or:t,orThunk:t,map:function(e){return c(e(n))},each:function(e){e(n)},bind:r,exists:r,forall:r,filter:function(e){return e(n)?a:l},toArray:function(){return[n]},toString:function(){return"some("+n+")"},equals:function(e){return e.is(n)},equals_:function(e,t){return e.fold(i,function(e){return t(n,e)})}};return a},f={some:c,none:u,from:function(e){return null===e||e===undefined?l:c(e)}},P=function(e){return!(null===(t=e)||t===undefined);var t},m=(r="function",function(e){return typeof e===r}),p=Array.prototype.slice,g=function(e,t){for(var n=0,r=e.length;n<r;n++){if(t(e[n],n))return!0}return!1},v=function(e,t){for(var n=e.length,r=new Array(n),a=0;a<n;a++){var o=e[a];r[a]=t(o,a)}return r},h=function(e,t){for(var n=0,r=e.length;n<r;n++){t(e[n],n)}},y=m(Array.from)?Array.from:function(e){return p.call(e)},b=function(){var t=d(f.none());return{clear:function(){return t.set(f.none())},set:function(e){return t.set(f.some(e))},isSet:function(){return t.get().isSome()},on:function(e){return t.get().each(e)}}},x=function(e,t,n){return""===t||e.length>=t.length&&e.substr(n,n+t.length)===t},w=tinymce.util.Tools.resolve("tinymce.Env"),_=tinymce.util.Tools.resolve("tinymce.util.Delay"),T=tinymce.util.Tools.resolve("tinymce.util.Promise"),C=tinymce.util.Tools.resolve("tinymce.util.VK"),D=function(e,t){return e.fire("PastePlainTextToggle",{state:t})},k=tinymce.util.Tools.resolve("tinymce.util.Tools"),S=function(e){return e.getParam("paste_data_images",!1)},O=function(e){return e.getParam("paste_retain_style_properties")},j=function(e){return e.getParam("validate")},R=function(e){return e.getParam("paste_data_images",!1,"boolean")},A=function(e){return k.explode(e.getParam("images_file_types","jpeg,jpg,jpe,jfi,jif,jfif,png,gif,bmp,webp","string"))},I="x-tinymce/html",F="\x3c!-- "+I+" --\x3e",E=function(e){return-1!==e.indexOf(F)},M=tinymce.util.Tools.resolve("tinymce.html.Entities"),N=function(e,t,n){var r=e.split(/\n\n/),a=function(e,t){var n,r=[],a="<"+e;if("object"==typeof t){for(n in t)t.hasOwnProperty(n)&&r.push(n+'="'+M.encodeAllRaw(t[n])+'"');r.length&&(a+=" "+r.join(" "))}return a+">"}(t,n),o="</"+t+">",i=k.map(r,function(e){return e.split(/\n/).join("<br />")});return 1===i.length?i[0]:k.map(i,function(e){return a+e+o}).join("")},B=tinymce.util.Tools.resolve("tinymce.html.DomParser"),H=tinymce.util.Tools.resolve("tinymce.html.Serializer"),L="\xa0",$=tinymce.util.Tools.resolve("tinymce.html.Node"),z=tinymce.util.Tools.resolve("tinymce.html.Schema");function U(t,e){return k.each(e,function(e){t=e.constructor===RegExp?t.replace(e,""):t.replace(e[0],e[1])}),t}function q(e){var t=z(),n=B({},t),r="",a=t.getShortEndedElements(),o=k.makeMap("script noscript style textarea video audio iframe object"," "),i=t.getBlockElements();return e=U(e,[/<!\[[^\]]+\]>/g]),function s(e){var t=e.name,n=e;if("br"!==t){if("wbr"!==t)if(a[t]&&(r+=" "),o[t])r+=" ";else{if(3===e.type&&(r+=e.value),!e.shortEnded&&(e=e.firstChild))for(;s(e),e=e.next;);i[t]&&n.next&&(r+="\n","p"===t&&(r+="\n"))}}else r+="\n"}(n.parse(e)),r}function V(e){return e=U(e,[/^[\s\S]*<body[^>]*>\s*|\s*<\/body[^>]*>[\s\S]*$/gi,/<!--StartFragment-->|<!--EndFragment-->/g,[/( ?)<span class="Apple-converted-space"