text: import{r as t,h as n}from"./p-7e344a40.js";var e=function(t,n){return function(){for(var e=new Array(arguments.length),r=0;r<e.length;r++)e[r]=arguments[r];return t.apply(n,e)}},r=Object.prototype.toString;
  /*!
   * Determine if an object is a Buffer
   *
   * @author   Feross Aboukhadijeh <https://feross.org>
   * @license  MIT
   */function i(t){return"[object Array]"===r.call(t)}function o(t){return null!==t&&"object"==typeof t}function u(t){return"[object Function]"===r.call(t)}function a(t,n){if(null!=t)if("object"!=typeof t&&(t=[t]),i(t))for(var e=0,r=t.length;e<r;e++)n.call(null,t[e],e,t);else for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&n.call(null,t[o],o,t)}var c={isArray:i,isArrayBuffer:function(t){return"[object ArrayBuffer]"===r.call(t)},isBuffer:function(t){return null!=t&&null!=t.constructor&&"function"==typeof t.constructor.isBuffer&&t.constructor.isBuffer(t)},isFormData:function(t){return"undefined"!=typeof FormData&&t instanceof FormData},isArrayBufferView:function(t){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(t):t&&t.buffer&&t.buffer instanceof ArrayBuffer},isString:function(t){return"string"==typeof t},isNumber:function(t){return"number"==typeof t},isObject:o,isUndefined:function(t){return void 0===t},isDate:function(t){return"[object Date]"===r.call(t)},isFile:function(t){return"[object File]"===r.call(t)},isBlob:function(t){return"[object Blob]"===r.call(t)},isFunction:u,isStream:function(t){return o(t)&&u(t.pipe)},isURLSearchParams:function(t){return"undefined"!=typeof URLSearchParams&&t instanceof URLSearchParams},isStandardBrowserEnv:function(){return("undefined"==typeof navigator||"ReactNative"!==navigator.product&&"NativeScript"!==navigator.product&&"NS"!==navigator.product)&&"undefined"!=typeof window&&"undefined"!=typeof document},forEach:a,merge:function t(){var n={};function e(e,r){n[r]="object"==typeof n[r]&&"object"==typeof e?t(n[r],e):e}for(var r=0,i=arguments.length;r<i;r++)a(arguments[r],e);return n},deepMerge:function t(){var n={};function e(e,r){n[r]="object"==typeof n[r]&&"object"==typeof e?t(n[r],e):"object"==typeof e?t({},e):e}for(var r=0,i=arguments.length;r<i;r++)a(arguments[r],e);return n},extend:function(t,n,r){return a(n,(function(n,i){t[i]=r&&"function"==typeof n?e(n,r):n})),t},trim:function(t){return t.replace(/^\s*/,"").replace(/\s*$/,"")}};function f(t){return encodeURIComponent(t).replace(/%40/gi,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}var s=function(t,n,e){if(!n)return t;var r;if(e)r=e(n);else if(c.isURLSearchParams(n))r=n.toString();else{var i=[];c.forEach(n,(function(t,n){null!=t&&(c.isArray(t)?n+="[]":t=[t],c.forEach(t,(function(t){c.isDate(t)?t=t.toISOString():c.isObject(t)&&(t=JSON.stringify(t)),i.push(f(n)+"="+f(t))})))})),r=i.join("&")}if(r){var o=t.indexOf("#");-1!==o&&(t=t.slice(0,o)),t+=(-1===t.indexOf("?")?"?":"&")+r}return t};function d(){this.handlers=[]}d.prototype.use=function(t,n){return this.handlers.push({fulfilled:t,rejected:n}),this.handlers.length-1},d.prototype.eject=function(t){this.handlers[t]&&(this.handlers[t]=null)},d.prototype.forEach=function(t){c.forEach(this.handlers,(function(n){null!==n&&t(n)}))};var p=d,l=function(t,n,e){return c.forEach(e,(function(e){t=e(t,n)})),t},v=function(t){return!(!t||!t.__CANCEL__)},h=function(t,n){c.forEach(t,(function(e,r){r!==n&&r.toUpperCase()===n.toUpperCase()&&(t[n]=e,delete t[r])}))},m=function(t,n,e,r,i){return function(t,n,e,r,i){return t.config=n,e&&(t.code=e),t.request=r,t.response=i,t.isAxiosError=!0,t.toJSON=function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code}},t}(new Error(t),n,e,r,i)},y=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"],g=c.isStandardBrowserEnv()?function(){var t,n=/(msie|trident)/i.test(navigator.userAgent),e=document.createElement("a");function r(t){var r=t;return n&&(e.setAttribute("href",r),r=e.href),e.setAttribute("href",r),{href:e.href,protocol:e.protocol?e.protocol.replace(/:$/,""):"",host:e.host,search:e.search?e.search.replace(/^\?/,""):"",hash:e.hash?e.hash.replace(/^#/,""):"",hostname:e.hostname,port:e.port,pathname:"/"===e.pathname.charAt(0)?e.pathname:"/"+e.pathname}}return t=r(window.location.href),function(n){var e=c.isString(n)?r(n):n;return e.protocol===t.protocol&&e.host===t.host}}():function(){return!0},w=c.isStandardBrowserEnv()?{write:function(t,n,e,r,i,o){var u=[];u.push(t+"="+encodeURIComponent(n)),c.isNumber(e)&&u.push("expires="+new Date(e).toGMTString()),c.isString(r)&&u.push("path="+r),c.isString(i)&&u.push("domain="+i),!0===o&&u.push("secure"),document.cookie=u.join("; ")},read:function(t){var n=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return n?decodeURIComponent(n[3]):null},remove:function(t){this.write(t,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}},x=function(t){return new Promise((function(n,e){var r=t.data,i=t.headers;c.isFormData(r)&&delete i["Content-Type"];var o=new XMLHttpRequest;if(t.auth&&(i.Authorization="Basic "+btoa((t.auth.username||"")+":"+(t.auth.password||""))),o.open(t.method.toUpperCase(),s(t.url,t.params,t.paramsSerializer),!0),o.timeout=t.timeout,o.onreadystatechange=function(){if(o&&4===o.readyState&&(0!==o.status||o.responseURL&&0===o.responseURL.indexOf("file:"))){var r,i,u,a,f,s="getAllResponseHeaders"in o?(r=o.getAllResponseHeaders(),f={},r?(c.forEach(r.split("\n"),(function(t){if(a=t.indexOf(":"),i=c.trim(t.substr(0,a)).toLowerCase(),u=c.trim(t.substr(a+1)),i){if(f[i]&&y.indexOf(i)>=0)return;f[i]="set-cookie"===i?(f[i]?f[i]:[]).concat([u]):f[i]?f[i]+", "+u:u}})),f):f):null;!function(t,n,e){var r=e.config.validateStatus;!r||r(e.status)?t(e):n(m("Request failed with status code "+e.status,e.config,null,e.request,e))}(n,e,{data:t.responseType&&"text"!==t.responseType?o.response:o.responseText,status:o.status,statusText:o.statusText,headers:s,config:t,request:o}),o=null}},o.onabort=function(){o&&(e(m("Request aborted",t,"ECONNABORTED",o)),o=null)},o.onerror=function(){e(m("Network Error",t,null,o)),o=null},o.ontimeout=function(){e(m("timeout of "+t.timeout+"ms exceeded",t,"ECONNABORTED",o)),o=null},c.isStandardBrowserEnv()){var u=w,a=(t.withCredentials||g(t.url))&&t.xsrfCookieName?u.read(t.xsrfCookieName):void 0;a&&(i[t.xsrfHeaderName]=a)}if("setRequestHeader"in o&&c.forEach(i,(function(t,n){void 0===r&&"content-type"===n.toLowerCase()?delete i[n]:o.setRequestHeader(n,t)})),t.withCredentials&&(o.withCredentials=!0),t.responseType)try{o.responseType=t.responseType}catch(f){if("json"!==t.responseType)throw f}"function"==typeof t.onDownloadProgress&&o.addEventListener("progress",t.onDownloadProgress),"function"==typeof t.onUploadProgress&&o.upload&&o.upload.addEventListener("progress",t.onUploadProgress),t.cancelToken&&t.cancelToken.promise.then((function(t){o&&(o.abort(),e(t),o=null)})),void 0===r&&(r=null),o.send(r)}))},j={"Content-Type":"application/x-www-form-urlencoded"};function b(t,n){!c.isUndefined(t)&&c.isUndefined(t["Content-Type"])&&(t["Content-Type"]=n)}var R,N={adapter:("undefined"!=typeof process&&"[object process]"===Object.prototype.toString.call(process)?R=x:"undefined"!=typeof XMLHttpRequest&&(R=x),R),transformRequest:[function(t,n){return h(n,"Accept"),h(n,"Content-Type"),c.isFormData(t)||c.isArrayBuffer(t)||c.isBuffer(t)||c.isStream(t)||c.isFile(t)||c.isBlob(t)?t:c.isArrayBufferView(t)?t.buffer:c.isURLSearchParams(t)?(b(n,"application/x-www-form-urlencoded;charset=utf-8"),t.toString()):c.isObject(t)?(b(n,"application/json;charset=utf-8"),JSON.stringify(t)):t}],transformResponse:[function(t){if("string"==typeof t)try{t=JSON.parse(t)}catch(n){}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};c.forEach(["delete","get","head"],(function(t){N.headers[t]={}})),c.forEach(["post","put","patch"],(function(t){N.headers[t]=c.merge(j)}));var A=N;function C(t){t.cancelToken&&t.cancelToken.throwIfRequested()}var S=function(t){var n,e;return C(t),t.baseURL&&!/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(t.url)&&(t.url=(n=t.baseURL,(e=t.url)?n.replace(/\/+$/,"")+"/"+e.replace(/^\/+/,""):n)),t.headers=t.headers||{},t.data=l(t.data,t.headers,t.transformRequest),t.headers=c.merge(t.headers.common||{},t.headers[t.method]||{},t.headers||{}),c.forEach(["delete","get","head","post","put","patch","common"],(function(n){delete t.headers[n]})),(t.adapter||A.adapter)(t).then((function(n){return C(t),n.data=l(n.data,n.headers,t.transformResponse),n}),(function(n){return v(n)||(C(t),n&&n.response&&(n.response.data=l(n.response.data,n.response.headers,t.transformResponse))),Promise.reject(n)}))},O=function(t,n){n=n||{};var e={};return c.forEach(["url","method","params","data"],(function(t){void 0!==n[t]&&(e[t]=n[t])})),c.forEach(["headers","auth","proxy"],(function(r){c.isObject(n[r])?e[r]=c.deepMerge(t[r],n[r]):void 0!==n[r]?e[r]=n[r]:c.isObject(t[r])?e[r]=c.deepMerge(t[r]):void 0!==t[r]&&(e[r]=t[r])})),c.forEach(["baseURL","transformRequest","transformResponse","paramsSerializer","timeout","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","maxContentLength","validateStatus","maxRedirects","httpAgent","httpsAgent","cancelToken","socketPath"],(function(r){void 0!==n[r]?e[r]=n[r]:void 0!==t[r]&&(e[r]=t[r])})),e};function B(t){this.defaults=t,this.interceptors={request:new p,response:new p}}B.prototype.request=function(t){"string"==typeof t?(t=arguments[1]||{}).url=arguments[0]:t=t||{},(t=O(this.defaults,t)).method=t.method?t.method.toLowerCase():"get";var n=[S,void 0],e=Promise.resolve(t);for(this.interceptors.request.forEach((function(t){n.unshift(t.fulfilled,t.rejected)})),this.interceptors.response.forEach((function(t){n.push(t.fulfilled,t.rejected)}));n.length;)e=e.then(n.shift(),n.shift());return e},B.prototype.getUri=function(t){return t=O(this.defaults,t),s(t.url,t.params,t.paramsSerializer).replace(/^\?/,"")},c.forEach(["delete","get","head","options"],(function(t){B.prototype[t]=function(n,e){return this.request(c.merge(e||{},{method:t,url:n}))}})),c.forEach(["post","put","patch"],(function(t){B.prototype[t]=function(n,e,r){return this.request(c.merge(r||{},{method:t,url:n,data:e}))}}));var E=B;function D(t){this.message=t}D.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},D.prototype.__CANCEL__=!0;var T=D;function L(t){if("function"!=typeof t)throw new TypeError("executor must be a function.");var n;this.promise=new Promise((function(t){n=t}));var e=this;t((function(t){e.reason||(e.reason=new T(t),n(e.reason))}))}L.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},L.source=function(){var t;return{token:new L((function(n){t=n})),cancel:t}};var P=L;function F(t){var n=new E(t),r=e(E.prototype.request,n);return c.extend(r,E.prototype,n),c.extend(r,n),r}var U=F(A);U.Axios=E,U.create=function(t){return F(O(U.defaults,t))},U.Cancel=T,U.CancelToken=P,U.isCancel=v,U.all=function(t){return Promise.all(t)},U.spread=function(t){return function(n){return t.apply(null,n)}};var q=U;q.default=U;var z=q;function k(t){return n("div",{class:"go-red"},t.error)}function H(t){let e=t.scope;return e.error?n(k,{error:e.error}):n("div",{id:"lazyload-"+e.nodeId})}function X(){var t=document.createEvent("Event");t.initEvent("DOMContentLoaded",!0,!0),document.dispatchEvent(t)}var J=["application/javascript","application/ecmascript","application/x-ecmascript","application/x-javascript","text/ecmascript","text/javascript","text/javascript1.0","text/javascript1.1","text/javascript1.2","text/javascript1.3","text/javascript1.4","text/javascript1.5","text/jscript","text/livescript","text/x-ecmascript","text/x-javascript"];const M=class{constructor(n){t(this,n),this.isLoading=!0,this.error=""}componentWillLoad(){let t=this;t.isLoading=!0,t.viewHtml="";let n=t.siteRootUrl+"/api/v3.0/pc/"+t.componentName+"/view/display?nid="+t.nodeId+"&pid="+t.pageId,e=JSON.parse(t.nodeOptions);z.post(n,e,{headers:{"Content-Type":"application/json;charset=UTF-8","Access-Control-Allow-Origin":"*"}}).then((function(n){t.viewHtml=n.data,t.isLoading=!1,window.setTimeout((function(){!function(t){let n=document.querySelector("#lazyload-"+t.nodeId);if(n){var e=document.createElement("div");e.setAttribute("id","lazyload-injector-"+t.nodeId),e.innerHTML=t.viewHtml,n.appendChild(e),i=e.querySelectorAll("script"),o=[],[].forEach.call(i,(function(t){(r=t.getAttribute("type"))&&-1===J.indexOf(r)||o.push((function(n){!function(t,n){var e=document.createElement("script");e.type="text/javascript",t.src?(e.onload=n,e.onerror=n,e.src=t.src):e.textContent=t.innerText,document.head.appendChild(e),t.parentNode.removeChild(t),t.src||n()}(t,n)}))})),function t(n,e,r){void 0===r&&(r=0),n[r]&&n[r]((function(){++r===n.length?e():t(n,e,r)}))}(o,X,0)}var r,i,o}(t)}),100)})).catch((function(n){t.error=n.response?n.response.statusText+":"+n.response.data:n.message,t.isLoading=!1}))}render(){return this.isLoading?n("div",{class:"loading-panel"},"Loading..."):n(H,{scope:this})}};export{M as wv_lazyload};