/* pdfobject v2.0.20160414 https://github.com/pipwerks/pdfobject copyright (c) 2008-2016 philip hutchison mit-style license: http://pipwerks.mit-license.org/ umd module pattern from https://github.com/umdjs/umd/blob/master/templates/returnexports.js */ (function(root,factory){if(typeof define==="function"&&define.amd){define([],factory)}else if(typeof module==="object"&&module.exports){module.exports=factory()}else{root.pdfobject=factory()}})(this,function(){return function(){"use strict";var pdfobjectversion="2.0.20160414",supportspdfs,createaxo,isie,supportspdfmimetype=typeof navigator.mimetypes["application/pdf"]!=="undefined",supportspdfactivex,buildquerystring,log,embederror,embed,gettargetelement,generatepdfjsiframe,isios=function(){return/iphone|ipad|ipod/i.test(navigator.useragent.tolowercase())}(),generateembedelement;createaxo=function(type){var ax;try{ax=new activexobject(type)}catch(e){ax=null}return ax};isie=function(){return!!(window.activexobject||"activexobject"in window)};supportspdfactivex=function(){return!!(createaxo("acropdf.pdf")||createaxo("pdf.pdfctrl"))};supportspdfs=supportspdfmimetype||isie()&&supportspdfactivex();buildquerystring=function(pdfparams){var string="",prop;if(pdfparams){for(prop in pdfparams){if(pdfparams.hasownproperty(prop)){string+=encodeuricomponent(prop)+"="+encodeuricomponent(pdfparams[prop])+"&"}}if(string){string="#"+string;string=string.slice(0,string.length-1)}}return string};log=function(msg){if(typeof console!=="undefined"&&console.log){console.log("[pdfobject] "+msg)}};embederror=function(msg){log(msg);return false};gettargetelement=function(targetselector){var targetnode=document.body;if(typeof targetselector==="string"){targetnode=document.queryselector(targetselector)}else if(typeof jquery!=="undefined"&&targetselector instanceof jquery&&targetselector.length){targetnode=targetselector.get(0)}else if(typeof targetselector.nodetype!=="undefined"&&targetselector.nodetype===1){targetnode=targetselector}return targetnode};generatepdfjsiframe=function(targetnode,url,pdfjs_url,id){var querystring=pdfjs_url+"?file="+url;var scrollfix=isios?"-webkit-overflow-scrolling: touch; overflow-y: scroll; ":"overflow: hidden; ";var iframe="
";targetnode.classname+=" pdfobject-container";targetnode.style.position="relative";targetnode.style.overflow="auto";targetnode.innerhtml=iframe;return targetnode.getelementsbytagname("iframe")[0]};generateembedelement=function(targetnode,targetselector,url,width,height,id){var style="";if(targetselector&&targetselector!==document.body){style="width: "+width+"; height: "+height+";"}else{style="position: absolute; top: 0; right: 0; bottom: 0; left: 0; width: 100%; height: 100%;"}targetnode.classname+=" pdfobject-container";targetnode.innerhtml="";return targetnode.getelementsbytagname("embed")[0]};embed=function(url,targetselector,options){if(typeof url!=="string"){return embederror("url is not valid")}targetselector=typeof targetselector!=="undefined"?targetselector:false;options=typeof options!=="undefined"?options:{};var id=options.id&&typeof options.id==="string"?"id='"+options.id+"'":"",page=options.page?options.page:false,pdfopenparams=options.pdfopenparams?options.pdfopenparams:{},fallbacklink=typeof options.fallbacklink!=="undefined"?options.fallbacklink:true,width=options.width?options.width:"100%",height=options.height?options.height:"100%",forcepdfjs=typeof options.forcepdfjs==="boolean"?options.forcepdfjs:false,pdfjs_url=options.pdfjs_url?options.pdfjs_url:false,targetnode=gettargetelement(targetselector),fallbackhtml="",fallbackhtml_default="this browser does not support inline pdfs. please download the pdf to view it: download pdf
";if(!targetnode){return embederror("target element cannot be determined")}if(page){pdfopenparams.page=page}url=encodeuri(url)+buildquerystring(pdfopenparams);if(forcepdfjs&&pdfjs_url){return generatepdfjsiframe(targetnode,url,pdfjs_url,id)}else if(supportspdfs){return generateembedelement(targetnode,targetselector,url,width,height,id)}else{if(pdfjs_url){return generatepdfjsiframe(targetnode,url,pdfjs_url,id)}else if(fallbacklink){fallbackhtml=typeof fallbacklink==="string"?fallbacklink:fallbackhtml_default;targetnode.innerhtml=fallbackhtml.replace(/\[url\]/g,url)}return embederror("this browser does not support embedded pdfs")}};return{embed:function(a,b,c){return embed(a,b,c)},pdfobjectversion:function(){return pdfobjectversion}(),supportspdfs:function(){return supportspdfs}()}}()});