import{o as e,t}from"./chunk-mlkTr37E.js";import{E as n}from"./api-DIOhBogn.js";import"./logger-BTOOQRog.js";import"./es-CGMBJHcJ.js";var r=t(((e,t)=>{(function(n,r){typeof define==`function`&&define.amd?define([],r):typeof e==`object`?t.exports=r():n.download=r()})(e,function(){return function e(t,n,r){var i=window,a=`application/octet-stream`,o=r||a,s=t,c=!n&&!r&&s,l=document.createElement(`a`),u=function(e){return String(e)},d=i.Blob||i.MozBlob||i.WebKitBlob||u,f=n||`download`,p,m;if(d=d.call?d.bind(i):Blob,String(this)===`true`&&(s=[s,o],o=s[0],s=s[1]),c&&c.length<2048&&(f=c.split(`/`).pop().split(`?`)[0],l.href=c,l.href.indexOf(c)!==-1)){var h=new XMLHttpRequest;return h.open(`GET`,c,!0),h.responseType=`blob`,h.onload=function(t){e(t.target.response,f,a)},setTimeout(function(){h.send()},0),h}if(/^data:([\w+-]+\/[\w+.-]+)?[,;]/.test(s))if(s.length>1024*1024*1.999&&d!==u)s=y(s),o=s.type||a;else return navigator.msSaveBlob?navigator.msSaveBlob(y(s),f):b(s);else if(/([\x80-\xff])/.test(s)){for(var g=0,_=new Uint8Array(s.length),v=_.length;g<v;++g)_[g]=s.charCodeAt(g);s=new d([_],{type:o})}p=s instanceof d?s:new d([s],{type:o});function y(e){for(var t=e.split(/[:;,]/),n=t[1],r=(t[2]==`base64`?atob:decodeURIComponent)(t.pop()),i=r.length,a=0,o=new Uint8Array(i);a<i;++a)o[a]=r.charCodeAt(a);return new d([o],{type:n})}function b(e,t){if(`download`in l)return l.href=e,l.setAttribute(`download`,f),l.className=`download-js-link`,l.innerHTML=`downloading...`,l.style.display=`none`,document.body.appendChild(l),setTimeout(function(){l.click(),document.body.removeChild(l),t===!0&&setTimeout(function(){i.URL.revokeObjectURL(l.href)},250)},66),!0;if(/(Version)\/(\d+)\.(\d+)(?:\.(\d+))?.*Safari\//.test(navigator.userAgent))return/^data:/.test(e)&&(e=`data:`+e.replace(/^data:([\w\/\-\+]+)/,a)),window.open(e)||confirm(`Displaying New Document

Use Save As... to download, then click back to return to this page.`)&&(location.href=e),!0;var n=document.createElement(`iframe`);document.body.appendChild(n),!t&&/^data:/.test(e)&&(e=`data:`+e.replace(/^data:([\w\/\-\+]+)/,a)),n.src=e,setTimeout(function(){document.body.removeChild(n)},333)}if(navigator.msSaveBlob)return navigator.msSaveBlob(p,f);if(i.URL)b(i.URL.createObjectURL(p),!0);else{if(typeof p==`string`||p.constructor===u)try{return b(`data:`+o+`;base64,`+i.btoa(p))}catch{return b(`data:`+o+`,`+encodeURIComponent(p))}m=new FileReader,m.onload=function(e){b(this.result)},m.readAsDataURL(p)}return!0}})}));n();var i=e(r()),a=async(e,t)=>(0,i.default)(e,t,`application/pdf`),o=e=>{let t=new Blob([e],{type:`application/pdf`});return URL.createObjectURL(t)};export{a as n,o as t};