pdfShow-13fe577e.js 688 Bytes
var i=(o,e,r)=>new Promise((c,t)=>{var p=n=>{try{a(r.next(n))}catch(s){t(s)}},d=n=>{try{a(r.throw(n))}catch(s){t(s)}},a=n=>n.done?c(n.value):Promise.resolve(n.value).then(p,d);a((r=r.apply(o,e)).next())});import{aX as f}from"./index.js";function l(o){return i(this,null,function*(){try{const e=yield fetch(o);if(!e.ok)throw new Error("PDF 下载失败");const r=yield e.blob(),c=URL.createObjectURL(r),t=window.open(c,"_blank");t||console.error("弹出窗口被阻止,无法预览 PDF"),t.onunload=()=>URL.revokeObjectURL(c)}catch(e){console.error("出现错误:",e)}})}const v=o=>{f(),o&&(o=o.replace("https://alterego.oss-cn-qingdao.aliyuncs.com","/aliyun-oss-pdf")),l(o)};export{v};