laravelEcomm/public/Dashboard/vendors/tinymce/plugins/media/plugin.min.js

9 lines
18 KiB
JavaScript
Raw Normal View History

2024-07-12 07:06:02 +00: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.7.0 (2021-02-10)
*/
!function(){"use strict";var e,t,r,n=tinymce.util.Tools.resolve("tinymce.PluginManager"),p=function(){return(p=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var o in t=arguments[r])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)},c=function(){},i=function(e){return function(){return e}},a=i(!1),u=i(!0),o=function(){return s},s=(e=function(e){return e.isNone()},{fold:function(e,t){return e()},is:a,isSome:a,isNone:u,getOr:r=function(e){return e},getOrThunk:t=function(e){return e()},getOrDie:function(e){throw new Error(e||"error: getOrDie called on none.")},getOrNull:i(null),getOrUndefined:i(undefined),or:r,orThunk:t,map:o,each:c,bind:o,exists:a,forall:u,filter:o,equals:e,equals_:e,toArray:function(){return[]},toString:i("none()")}),l=function(r){var e=i(r),t=function(){return o},n=function(e){return e(r)},o={fold:function(e,t){return t(r)},is:function(e){return r===e},isSome:u,isNone:a,getOr:e,getOrThunk:e,getOrDie:e,getOrNull:e,getOrUndefined:e,or:t,orThunk:t,map:function(e){return l(e(r))},each:function(e){e(r)},bind:n,exists:n,forall:n,filter:function(e){return e(r)?o:s},toArray:function(){return[r]},toString:function(){return"some("+r+")"},equals:function(e){return e.is(r)},equals_:function(e,t){return e.fold(a,function(e){return t(r,e)})}};return o},m={some:l,none:o,from:function(e){return null===e||e===undefined?s:l(e)}},d=function(n){return function(e){return r=typeof(t=e),(null===t?"null":"object"==r&&(Array.prototype.isPrototypeOf(t)||t.constructor&&"Array"===t.constructor.name)?"array":"object"==r&&(String.prototype.isPrototypeOf(t)||t.constructor&&"String"===t.constructor.name)?"string":r)===n;var t,r}},f=d("string"),h=d("object"),g=d("array"),v=function(e){return!(null===(t=e)||t===undefined);var t},w=Array.prototype.push,b=function(e,t){for(var r=0,n=e.length;r<n;r++){t(e[r],r)}},y=function(e){var t=e;return{get:function(){return t},set:function(e){t=e}}},x=Object.keys,j=Object.hasOwnProperty,O=function(e,t){for(var r=x(e),n=0,o=r.length;n<o;n++){var i=r[n];t(e[i],i)}},S=function(e,t){var r,n,o,i,a={};return r=t,i=a,n=function(e,t){i[t]=e},o=c,O(e,function(e,t){(r(e,t)?n:o)(e,t)}),a},_=function(e,t){return k(e,t)?m.from(e[t]):m.none()},k=function(e,t){return j.call(e,t)},A=function(e){return e.getParam("media_scripts")},T=tinymce.util.Tools.resolve("tinymce.util.Tools"),C=tinymce.util.Tools.resolve("tinymce.dom.DOMUtils"),P=tinymce.util.Tools.resolve("tinymce.html.SaxParser"),D=function(e,t){if(e)for(var r=0;r<e.length;r++)if(-1!==t.indexOf(e[r].filter))return e[r]},$=C.DOM,M=function(e){return e.replace(/px$/,"")},z=function(a,e){var c=y(!1),u={};return P({validate:!1,allow_conditional_comments:!0,start:function(e,t){if(!c.get())if(k(t.map,"data-ephox-embed-iri"))c.set(!0),o=(n=t).map.style,i=o?$.parseStyle(o):{},u={type:"ephox-embed-iri",source:n.map["data-ephox-embed-iri"],altsource:"",poster:"",width:_(i,"max-width").map(M).getOr(""),height:_(i,"max-height").map(M).getOr("")};else{if(u.source||"param"!==e||(u.source=t.map.movie),"iframe"!==e&&"object"!==e&&"embed"!==e&&"video"!==e&&"audio"!==e||(u.type||(u.type=e),u=T.extend(t.map,u)),"script"===e){var r=D(a,t.map.src);if(!r)return;u={type:"script",source:t.map.src,width:String(r.width),height:String(r.height)}}"source"===e&&(u.source?u.altsource||(u.altsource=t.map.src):u.source=t.map.src),"img"!==e||u.poster||(u.poster=t.map.src)}var n,o,i}}).parse(e),u.source=u.source||u.src||u.data,u.altsource=u.altsource||"",u.poster=u.poster||"",u},F=function(e){var t={mp3:"audio/mpeg",m4a:"audio/x-m4a",wav:"audio/wav",mp4:"video/mp4",webm:"video/webm",ogg:"video/ogg",swf:"application/x-shockwave-flash"}[e.toLowerCase().split(".").pop()];return t||""},N=tinymce.util.Tools.resolve("tinymce.html.Schema"),U=tinymce.util.Tools.resolve("tinymce.html.Writer"),E=C.DOM,R=function(e){return/^[0-9.]+$/.test(e)?e+"px":e},L=function(i,e){O(e,function(e,t){var r=""+e;if(i.map[t])for(var n=i.length;n--;){var o=i[n];o.name===t&&(r?(i.map[t]=r,o.value=r):(delete i.map[t],i.splice(n,1)))}else r&&(i.push({name:t,value: