| 1 |
- import{D as r}from"./entry/index-D9RAguAn.js";import{d as c,u as l}from"./base64Conver-DEMZeTZS.js";function m(e,t,o,s){l(e).then(a=>{f(a,t,o)})}function f(e,t,o,s){const a=c(e);u(a,t,o)}function u(e,t,o,s){const a=[e],d=new Blob(a,{type:o||"application/octet-stream"}),i=window.URL.createObjectURL(d),n=document.createElement("a");n.style.display="none",n.href=i,n.setAttribute("download",t),typeof n.download=="undefined"&&n.setAttribute("target","_blank"),document.body.appendChild(n),n.click(),document.body.removeChild(n),window.URL.revokeObjectURL(i)}function p({url:e,target:t="_blank",fileName:o}){const s=window.navigator.userAgent.toLowerCase().indexOf("chrome")>-1,a=window.navigator.userAgent.toLowerCase().indexOf("safari")>-1;if(/(iP)/g.test(window.navigator.userAgent))return!1;if(s||a){const d=document.createElement("a");if(d.href=e,d.target=t,d.download!==void 0&&(d.download=o||e.substring(e.lastIndexOf("/")+1,e.length)),document.createEvent){const i=document.createEvent("MouseEvents");return i.initEvent("click",!0,!0),d.dispatchEvent(i),!0}}return e.indexOf("?")===-1&&(e+="?download"),r(e,{target:t}),!0}export{f as a,u as b,m as c,p as d};
|