284 lines
724 KiB
JavaScript
284 lines
724 KiB
JavaScript
|
|
(function($n,vA){typeof exports=="object"&&typeof module<"u"?vA(exports,require("vue"),require("pinia")):typeof define=="function"&&define.amd?define(["exports","vue","pinia"],vA):($n=typeof globalThis<"u"?globalThis:$n||self,vA($n.OrgChart={},$n.Vue,$n.pinia))})(this,function($n,vA,Mc){"use strict";/*!
|
|||
|
|
* html2canvas 1.4.1 <https://html2canvas.hertzen.com>
|
|||
|
|
* Copyright (c) 2022 Niklas von Hertzen <https://hertzen.com>
|
|||
|
|
* Released under MIT License
|
|||
|
|
*//*! *****************************************************************************
|
|||
|
|
Copyright (c) Microsoft Corporation.
|
|||
|
|
|
|||
|
|
Permission to use, copy, modify, and/or distribute this software for any
|
|||
|
|
purpose with or without fee is hereby granted.
|
|||
|
|
|
|||
|
|
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|||
|
|
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|||
|
|
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|||
|
|
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|||
|
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|||
|
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|||
|
|
PERFORMANCE OF THIS SOFTWARE.
|
|||
|
|
***************************************************************************** */var Rc=function(t,A){return Rc=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,r){e.__proto__=r}||function(e,r){for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])},Rc(t,A)};function Pr(t,A){if(typeof A!="function"&&A!==null)throw new TypeError("Class extends value "+String(A)+" is not a constructor or null");Rc(t,A);function e(){this.constructor=t}t.prototype=A===null?Object.create(A):(e.prototype=A.prototype,new e)}var kc=function(){return kc=Object.assign||function(A){for(var e,r=1,n=arguments.length;r<n;r++){e=arguments[r];for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&(A[i]=e[i])}return A},kc.apply(this,arguments)};function zt(t,A,e,r){function n(i){return i instanceof e?i:new e(function(a){a(i)})}return new(e||(e=Promise))(function(i,a){function s(f){try{l(r.next(f))}catch(d){a(d)}}function o(f){try{l(r.throw(f))}catch(d){a(d)}}function l(f){f.done?i(f.value):n(f.value).then(s,o)}l((r=r.apply(t,A||[])).next())})}function Dt(t,A){var e={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},r,n,i,a;return a={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function s(l){return function(f){return o([l,f])}}function o(l){if(r)throw new TypeError("Generator is already executing.");for(;e;)try{if(r=1,n&&(i=l[0]&2?n.return:l[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,l[1])).done)return i;switch(n=0,i&&(l=[l[0]&2,i.value]),l[0]){case 0:case 1:i=l;break;case 4:return e.label++,{value:l[1],done:!1};case 5:e.label++,n=l[1],l=[0];continue;case 7:l=e.ops.pop(),e.trys.pop();continue;default:if(i=e.trys,!(i=i.length>0&&i[i.length-1])&&(l[0]===6||l[0]===2)){e=0;continue}if(l[0]===3&&(!i||l[1]>i[0]&&l[1]<i[3])){e.label=l[1];break}if(l[0]===6&&e.label<i[1]){e.label=i[1],i=l;break}if(i&&e.label<i[2]){e.label=i[2],e.ops.push(l);break}i[2]&&e.ops.pop(),e.trys.pop();continue}l=A.call(t,e)}catch(f){l=[6,f],n=0}finally{r=i=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}function Vo(t,A,e){if(e||arguments.length===2)for(var r=0,n=A.length,i;r<n;r++)(i||!(r in A))&&(i||(i=Array.prototype.slice.call(A,0,r)),i[r]=A[r]);return t.concat(i||A)}for(var bn=function(){function t(A,e,r,n){this.left=A,this.top=e,this.width=r,this.height=n}return t.prototype.add=function(A,e,r,n){return new t(this.left+A,this.top+e,this.width+r,this.height+n)},t.fromClientRect=function(A,e){return new t(e.left+A.windowBounds.left,e.top+A.windowBounds.top,e.width,e.height)},t.fromDOMRectList=function(A,e){var r=Array.from(e).find(function(n){return n.width!==0});return r?new t(r.left+A.windowBounds.left,r.top+A.windowBounds.top,r.width,r.height):t.EMPTY},t.EMPTY=new t(0,0,0,0),t}(),jo=function(t,A){return bn.fromClientRect(t,A.getBoundingClientRect())},Nm=function(t){var A=t.body,e=t.documentElement;if(!A||!e)throw new Error("Unable to get document size");var r=Math.max(Math.max(A.scrollWidth,e.scrollWidth),Math.max(A.offsetWidth,e.offsetWidth),Math.max(A.clientWidth,e.clientWidth)),n=Math.max(Math.max(A.scrollHeight,e.scrollHeight),Math.max(A.offsetHeight,e.offsetHeight),Math.max(A.clientHeight,e.clientHeight));return new bn(0,0,r,n)},Go=function(t){for(var A=[],e=0,r=t.length;e<r;){var n=t.charCodeAt(e++);if(n>=55296&&n<=56319&&e<r){var i=t.charCodeAt(e++);(i&64512)===56320?A.push(((n&1023)<<10)+(i&1023)+65536):(A.push(n),e--)}else A.push(n)}return A},tt=function(){for(var t=[],A=0;A<arguments.length;A++)t[A]=arguments[A];if(String.fromCodePoint)return String.fromCodePoint.apply(String,t);var e=t.length;if(!e)return"";for(var r=[],n=-1,i="";++n<e;){var a=t[n];a<=65535?r.push(a):(a-=65536,r.push((a>>10)+55296,a%1024+56320)),(n+1===e||r.length>16384)&&(i+=String.fromCharCode.apply(String,r),r.length=0)}return i},b0="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Tm=typeof Uint8Array>"u"?[]:new Uint8Array(256),$o=0;$o<b0.length;$o++)Tm[b0.charCodeAt($o)]=$o;for(var F0="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnop
|
|||
|
|
content: "" !important;
|
|||
|
|
display: none !important;
|
|||
|
|
}`,vF=function(t){BF(t,"."+Nf+dF+g1+`
|
|||
|
|
.`+Tf+pF+g1)},BF=function(t,A){var e=t.ownerDocument;if(e){var r=e.createElement("style");r.textContent=A,t.appendChild(r)}},d1=function(){function t(){}return t.getOrigin=function(A){var e=t._link;return e?(e.href=A,e.href=e.href,e.protocol+e.hostname+e.port):"about:blank"},t.isSameOrigin=function(A){return t.getOrigin(A)===t._origin},t.setContext=function(A){t._link=A.document.createElement("a"),t._origin=t.getOrigin(A.location.href)},t._origin="about:blank",t}(),wF=function(){function t(A,e){this.context=A,this._options=e,this._cache={}}return t.prototype.addImage=function(A){var e=Promise.resolve();return this.has(A)||(Hf(A)||bF(A))&&(this._cache[A]=this.loadImage(A)).catch(function(){}),e},t.prototype.match=function(A){return this._cache[A]},t.prototype.loadImage=function(A){return zt(this,void 0,void 0,function(){var e,r,n,i,a=this;return Dt(this,function(s){switch(s.label){case 0:return e=d1.isSameOrigin(A),r=!Of(A)&&this._options.useCORS===!0&&Ot.SUPPORT_CORS_IMAGES&&!e,n=!Of(A)&&!e&&!Hf(A)&&typeof this._options.proxy=="string"&&Ot.SUPPORT_CORS_XHR&&!r,!e&&this._options.allowTaint===!1&&!Of(A)&&!Hf(A)&&!n&&!r?[2]:(i=A,n?[4,this.proxy(i)]:[3,2]);case 1:i=s.sent(),s.label=2;case 2:return this.context.logger.debug("Added image "+A.substring(0,256)),[4,new Promise(function(o,l){var f=new Image;f.onload=function(){return o(f)},f.onerror=l,(FF(i)||r)&&(f.crossOrigin="anonymous"),f.src=i,f.complete===!0&&setTimeout(function(){return o(f)},500),a._options.imageTimeout>0&&setTimeout(function(){return l("Timed out ("+a._options.imageTimeout+"ms) loading image")},a._options.imageTimeout)})];case 3:return[2,s.sent()]}})})},t.prototype.has=function(A){return typeof this._cache[A]<"u"},t.prototype.keys=function(){return Promise.resolve(Object.keys(this._cache))},t.prototype.proxy=function(A){var e=this,r=this._options.proxy;if(!r)throw new Error("No proxy defined");var n=A.substring(0,256);return new Promise(function(i,a){var s=Ot.SUPPORT_RESPONSE_TYPE?"blob":"text",o=new XMLHttpRequest;o.onload=function(){if(o.status===200)if(s==="text")i(o.response);else{var d=new FileReader;d.addEventListener("load",function(){return i(d.result)},!1),d.addEventListener("error",function(p){return a(p)},!1),d.readAsDataURL(o.response)}else a("Failed to proxy resource "+n+" with status code "+o.status)},o.onerror=a;var l=r.indexOf("?")>-1?"&":"?";if(o.open("GET",""+r+l+"url="+encodeURIComponent(A)+"&responseType="+s),s!=="text"&&o instanceof XMLHttpRequest&&(o.responseType=s),e._options.imageTimeout){var f=e._options.imageTimeout;o.timeout=f,o.ontimeout=function(){return a("Timed out ("+f+"ms) proxying "+n)}}o.send()})},t}(),mF=/^data:image\/svg\+xml/i,yF=/^data:image\/.*;base64,/i,CF=/^data:image\/.*/i,bF=function(t){return Ot.SUPPORT_SVG_DRAWING||!QF(t)},Of=function(t){return CF.test(t)},FF=function(t){return yF.test(t)},Hf=function(t){return t.substr(0,4)==="blob"},QF=function(t){return t.substr(-3).toLowerCase()==="svg"||mF.test(t)},DA=function(){function t(A,e){this.type=0,this.x=A,this.y=e}return t.prototype.add=function(A,e){return new t(this.x+A,this.y+e)},t}(),Ba=function(t,A,e){return new DA(t.x+(A.x-t.x)*e,t.y+(A.y-t.y)*e)},Iu=function(){function t(A,e,r,n){this.type=1,this.start=A,this.startControl=e,this.endControl=r,this.end=n}return t.prototype.subdivide=function(A,e){var r=Ba(this.start,this.startControl,A),n=Ba(this.startControl,this.endControl,A),i=Ba(this.endControl,this.end,A),a=Ba(r,n,A),s=Ba(n,i,A),o=Ba(a,s,A);return e?new t(this.start,r,a,o):new t(o,s,i,this.end)},t.prototype.add=function(A,e){return new t(this.start.add(A,e),this.startControl.add(A,e),this.endControl.add(A,e),this.end.add(A,e))},t.prototype.reverse=function(){return new t(this.end,this.endControl,this.startControl,this.start)},t}(),Qr=function(t){return t.type===1},UF=function(){function t(A){var e=A.styles,r=A.bounds,n=Is(e.borderTopLeftRadius,r.width,r.height),i=n[0],a=n[1],s=Is(e.borderTopRightRadius,r.width,r.height),o=s[0],l=s[1],f=Is(e.borderBottomRightRadius,r.width,r.height),d=f[0],p=f[1],h=Is(e.borderBottomLeftRadius,r.width,r.height)
|
|||
|
|
*
|
|||
|
|
* jsPDF - PDF Document creation from JavaScript
|
|||
|
|
* Version 2.5.1 Built on 2022-01-28T15:37:57.791Z
|
|||
|
|
* CommitID 00000000
|
|||
|
|
*
|
|||
|
|
* Copyright (c) 2010-2021 James Hall <james@parall.ax>, https://github.com/MrRio/jsPDF
|
|||
|
|
* 2015-2021 yWorks GmbH, http://www.yworks.com
|
|||
|
|
* 2015-2021 Lukas Holländer <lukas.hollaender@yworks.com>, https://github.com/HackbrettXXX
|
|||
|
|
* 2016-2018 Aras Abbasi <aras.abbasi@gmail.com>
|
|||
|
|
* 2010 Aaron Spike, https://github.com/acspike
|
|||
|
|
* 2012 Willow Systems Corporation, https://github.com/willowsystems
|
|||
|
|
* 2012 Pablo Hess, https://github.com/pablohess
|
|||
|
|
* 2012 Florian Jenett, https://github.com/fjenett
|
|||
|
|
* 2013 Warren Weckesser, https://github.com/warrenweckesser
|
|||
|
|
* 2013 Youssef Beddad, https://github.com/lifof
|
|||
|
|
* 2013 Lee Driscoll, https://github.com/lsdriscoll
|
|||
|
|
* 2013 Stefan Slonevskiy, https://github.com/stefslon
|
|||
|
|
* 2013 Jeremy Morel, https://github.com/jmorel
|
|||
|
|
* 2013 Christoph Hartmann, https://github.com/chris-rock
|
|||
|
|
* 2014 Juan Pablo Gaviria, https://github.com/juanpgaviria
|
|||
|
|
* 2014 James Makes, https://github.com/dollaruw
|
|||
|
|
* 2014 Diego Casorran, https://github.com/diegocr
|
|||
|
|
* 2014 Steven Spungin, https://github.com/Flamenco
|
|||
|
|
* 2014 Kenneth Glassey, https://github.com/Gavvers
|
|||
|
|
*
|
|||
|
|
* Permission is hereby granted, free of charge, to any person obtaining
|
|||
|
|
* a copy of this software and associated documentation files (the
|
|||
|
|
* "Software"), to deal in the Software without restriction, including
|
|||
|
|
* without limitation the rights to use, copy, modify, merge, publish,
|
|||
|
|
* distribute, sublicense, and/or sell copies of the Software, and to
|
|||
|
|
* permit persons to whom the Software is furnished to do so, subject to
|
|||
|
|
* the following conditions:
|
|||
|
|
*
|
|||
|
|
* The above copyright notice and this permission notice shall be
|
|||
|
|
* included in all copies or substantial portions of the Software.
|
|||
|
|
*
|
|||
|
|
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
|||
|
|
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
|||
|
|
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|||
|
|
* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
|||
|
|
* LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
|||
|
|
* OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
|||
|
|
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|||
|
|
*
|
|||
|
|
* Contributor(s):
|
|||
|
|
* siefkenj, ahwolf, rickygu, Midnith, saintclair, eaparango,
|
|||
|
|
* kim3er, mfo, alnorth, Flamenco
|
|||
|
|
*/var ee=function(){return typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:this}();function qf(){ee.console&&typeof ee.console.log=="function"&&ee.console.log.apply(ee.console,arguments)}var _e={log:qf,warn:function(t){ee.console&&(typeof ee.console.warn=="function"?ee.console.warn.apply(ee.console,arguments):qf.call(null,arguments))},error:function(t){ee.console&&(typeof ee.console.error=="function"?ee.console.error.apply(ee.console,arguments):qf(t))}};function Wf(t,A,e){var r=new XMLHttpRequest;r.open("GET",t),r.responseType="blob",r.onload=function(){Hi(r.response,A,e)},r.onerror=function(){_e.error("could not download file")},r.send()}function O1(t){var A=new XMLHttpRequest;A.open("HEAD",t,!1);try{A.send()}catch{}return A.status>=200&&A.status<=299}function Mu(t){try{t.dispatchEvent(new MouseEvent("click"))}catch{var A=document.createEvent("MouseEvents");A.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),t.dispatchEvent(A)}}var ks,zf,Hi=ee.saveAs||((typeof window>"u"?"undefined":Qe(window))!=="object"||window!==ee?function(){}:typeof HTMLAnchorElement<"u"&&"download"in HTMLAnchorElement.prototype?function(t,A,e){var r=ee.URL||ee.webkitURL,n=document.createElement("a");A=A||t.name||"download",n.download=A,n.rel="noopener",typeof t=="string"?(n.href=t,n.origin!==location.origin?O1(n.href)?Wf(t,A,e):Mu(n,n.target="_blank"):Mu(n)):(n.href=r.createObjectURL(t),setTimeout(function(){r.revokeObjectURL(n.href)},4e4),setTimeout(function(){Mu(n)},0))}:"msSaveOrOpenBlob"in navigator?function(t,A,e){if(A=A||t.name||"download",typeof t=="string")if(O1(t))Wf(t,A,e);else{var r=document.createElement("a");r.href=t,r.target="_blank",setTimeout(function(){Mu(r)})}else navigator.msSaveOrOpenBlob(function(n,i){return i===void 0?i={autoBom:!1}:Qe(i)!=="object"&&(_e.warn("Deprecated: Expected third argument to be a object"),i={autoBom:!i}),i.autoBom&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(n.type)?new Blob([String.fromCharCode(65279),n],{type:n.type}):n}(t,e),A)}:function(t,A,e,r){if((r=r||open("","_blank"))&&(r.document.title=r.document.body.innerText="downloading..."),typeof t=="string")return Wf(t,A,e);var n=t.type==="application/octet-stream",i=/constructor/i.test(ee.HTMLElement)||ee.safari,a=/CriOS\/[\d]+/.test(navigator.userAgent);if((a||n&&i)&&(typeof FileReader>"u"?"undefined":Qe(FileReader))==="object"){var s=new FileReader;s.onloadend=function(){var f=s.result;f=a?f:f.replace(/^data:[^;]*;/,"data:attachment/file;"),r?r.location.href=f:location=f,r=null},s.readAsDataURL(t)}else{var o=ee.URL||ee.webkitURL,l=o.createObjectURL(t);r?r.location=l:location.href=l,r=null,setTimeout(function(){o.revokeObjectURL(l)},4e4)}});/**
|
|||
|
|
* A class to parse color values
|
|||
|
|
* @author Stoyan Stefanov <sstoo@gmail.com>
|
|||
|
|
* {@link http://www.phpied.com/rgb-color-parser-in-javascript/}
|
|||
|
|
* @license Use it if you like it
|
|||
|
|
*/function H1(t){var A;t=t||"",this.ok=!1,t.charAt(0)=="#"&&(t=t.substr(1,6)),t={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dodgerblue:"1e90ff",feldspar:"d19275",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgrey:"d3d3d3",lightgreen:"90ee90",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslateblue:"8470ff",lightslategray:"778899",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"00ff00",limegreen:"32cd32",linen:"faf0e6",magenta:"ff00ff",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370d8",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"d87093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",red:"ff0000",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",violetred:"d02090",wheat:"f5deb3",white:"ffffff",whitesmoke:"f5f5f5",yellow:"ffff00",yellowgreen:"9acd32"}[t=(t=t.replace(/ /g,"")).toLowerCase()]||t;for(var e=[{re:/^rgb\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/,example:["rgb(123, 234, 45)","rgb(255,234,245)"],process:function(s){return[parseInt(s[1]),parseInt(s[2]),parseInt(s[3])]}},{re:/^(\w{2})(\w{2})(\w{2})$/,example:["#00ff00","336699"],process:function(s){return[parseInt(s[1],16),parseInt(s[2],16),parseInt(s[3],16)]}},{re:/^(\w{1})(\w{1})(\w{1})$/,example:["#fb0","f0f"],process:function(s){return[parseInt(s[1]+s[1],16),parseInt(s[2]+s[2],16),parseInt(s[3]+s[3],16)]}}],r=0;r<e.length;r++){var n=e[r].re,i=e[r].process,a=n.exec(t);a&&(A=i(a),this.r=A[0],this.g=A[1],this.b=A[2],this.ok=!0)}this.r=this.r<0||isNaN(this.r)?0:this.r>255?255:this.r,this.g=this.g<0||isNaN(this.g)?0:this.g>255?255:this.g,this.b=this.b<0||isNaN(this.b)?0:this.b>255?255:this.b,this.toRGB=function(){return"rgb("+this.r+", "+this.g+", "+this.b+")"},this.toHex=function(){var s=this.r.toString(16),o=this.g.toString(16),l=this.b.toString(16);return s.length==1&&(s="0"+s),o.length==1&&(o="0"+o),l.length==1&&(l="0"+l),"#"+s+o+l}}/**
|
|||
|
|
* @license
|
|||
|
|
* Joseph Myers does not specify a particular license for his work.
|
|||
|
|
*
|
|||
|
|
* Author: Joseph Myers
|
|||
|
|
* Accessed from: http://www.myersdaily.org/joseph/javascript/md5.js
|
|||
|
|
*
|
|||
|
|
* Modified by: Owen Leong
|
|||
|
|
*/function Xf(t,A){var e=t[0],r=t[1],n=t[2],i=t[3];e=Rt(e,r,n,i,A[0],7,-680876936),i=Rt(i,e,r,n,A[1],12,-389564586),n=Rt(n,i,e,r,A[2],17,606105819),r=Rt(r,n,i,e,A[3],22,-1044525330),e=Rt(e,r,n,i,A[4],7,-176418897),i=Rt(i,e,r,n,A[5],12,1200080426),n=Rt(n,i,e,r,A[6],17,-1473231341),r=Rt(r,n,i,e,A[7],22,-45705983),e=Rt(e,r,n,i,A[8],7,1770035416),i=Rt(i,e,r,n,A[9],12,-1958414417),n=Rt(n,i,e,r,A[10],17,-42063),r=Rt(r,n,i,e,A[11],22,-1990404162),e=Rt(e,r,n,i,A[12],7,1804603682),i=Rt(i,e,r,n,A[13],12,-40341101),n=Rt(n,i,e,r,A[14],17,-1502002290),e=kt(e,r=Rt(r,n,i,e,A[15],22,1236535329),n,i,A[1],5,-165796510),i=kt(i,e,r,n,A[6],9,-1069501632),n=kt(n,i,e,r,A[11],14,643717713),r=kt(r,n,i,e,A[0],20,-373897302),e=kt(e,r,n,i,A[5],5,-701558691),i=kt(i,e,r,n,A[10],9,38016083),n=kt(n,i,e,r,A[15],14,-660478335),r=kt(r,n,i,e,A[4],20,-405537848),e=kt(e,r,n,i,A[9],5,568446438),i=kt(i,e,r,n,A[14],9,-1019803690),n=kt(n,i,e,r,A[3],14,-187363961),r=kt(r,n,i,e,A[8],20,1163531501),e=kt(e,r,n,i,A[13],5,-1444681467),i=kt(i,e,r,n,A[2],9,-51403784),n=kt(n,i,e,r,A[7],14,1735328473),e=Kt(e,r=kt(r,n,i,e,A[12],20,-1926607734),n,i,A[5],4,-378558),i=Kt(i,e,r,n,A[8],11,-2022574463),n=Kt(n,i,e,r,A[11],16,1839030562),r=Kt(r,n,i,e,A[14],23,-35309556),e=Kt(e,r,n,i,A[1],4,-1530992060),i=Kt(i,e,r,n,A[4],11,1272893353),n=Kt(n,i,e,r,A[7],16,-155497632),r=Kt(r,n,i,e,A[10],23,-1094730640),e=Kt(e,r,n,i,A[13],4,681279174),i=Kt(i,e,r,n,A[0],11,-358537222),n=Kt(n,i,e,r,A[3],16,-722521979),r=Kt(r,n,i,e,A[6],23,76029189),e=Kt(e,r,n,i,A[9],4,-640364487),i=Kt(i,e,r,n,A[12],11,-421815835),n=Kt(n,i,e,r,A[15],16,530742520),e=Vt(e,r=Kt(r,n,i,e,A[2],23,-995338651),n,i,A[0],6,-198630844),i=Vt(i,e,r,n,A[7],10,1126891415),n=Vt(n,i,e,r,A[14],15,-1416354905),r=Vt(r,n,i,e,A[5],21,-57434055),e=Vt(e,r,n,i,A[12],6,1700485571),i=Vt(i,e,r,n,A[3],10,-1894986606),n=Vt(n,i,e,r,A[10],15,-1051523),r=Vt(r,n,i,e,A[1],21,-2054922799),e=Vt(e,r,n,i,A[8],6,1873313359),i=Vt(i,e,r,n,A[15],10,-30611744),n=Vt(n,i,e,r,A[6],15,-1560198380),r=Vt(r,n,i,e,A[13],21,1309151649),e=Vt(e,r,n,i,A[4],6,-145523070),i=Vt(i,e,r,n,A[11],10,-1120210379),n=Vt(n,i,e,r,A[2],15,718787259),r=Vt(r,n,i,e,A[9],21,-343485551),t[0]=ni(e,t[0]),t[1]=ni(r,t[1]),t[2]=ni(n,t[2]),t[3]=ni(i,t[3])}function Ru(t,A,e,r,n,i){return A=ni(ni(A,t),ni(r,i)),ni(A<<n|A>>>32-n,e)}function Rt(t,A,e,r,n,i,a){return Ru(A&e|~A&r,t,A,n,i,a)}function kt(t,A,e,r,n,i,a){return Ru(A&r|e&~r,t,A,n,i,a)}function Kt(t,A,e,r,n,i,a){return Ru(A^e^r,t,A,n,i,a)}function Vt(t,A,e,r,n,i,a){return Ru(e^(A|~r),t,A,n,i,a)}function _1(t){var A,e=t.length,r=[1732584193,-271733879,-1732584194,271733878];for(A=64;A<=t.length;A+=64)Xf(r,BQ(t.substring(A-64,A)));t=t.substring(A-64);var n=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];for(A=0;A<t.length;A++)n[A>>2]|=t.charCodeAt(A)<<(A%4<<3);if(n[A>>2]|=128<<(A%4<<3),A>55)for(Xf(r,n),A=0;A<16;A++)n[A]=0;return n[14]=8*e,Xf(r,n),r}function BQ(t){var A,e=[];for(A=0;A<64;A+=4)e[A>>2]=t.charCodeAt(A)+(t.charCodeAt(A+1)<<8)+(t.charCodeAt(A+2)<<16)+(t.charCodeAt(A+3)<<24);return e}ks=ee.atob.bind(ee),zf=ee.btoa.bind(ee);var P1="0123456789abcdef".split("");function wQ(t){for(var A="",e=0;e<4;e++)A+=P1[t>>8*e+4&15]+P1[t>>8*e&15];return A}function mQ(t){return String.fromCharCode((255&t)>>0,(65280&t)>>8,(16711680&t)>>16,(4278190080&t)>>24)}function Yf(t){return _1(t).map(mQ).join("")}var yQ=function(t){for(var A=0;A<t.length;A++)t[A]=wQ(t[A]);return t.join("")}(_1("hello"))!="5d41402abc4b2a76b9719d911017c592";function ni(t,A){if(yQ){var e=(65535&t)+(65535&A);return(t>>16)+(A>>16)+(e>>16)<<16|65535&e}return t+A&4294967295}/**
|
|||
|
|
* @license
|
|||
|
|
* FPDF is released under a permissive license: there is no usage restriction.
|
|||
|
|
* You may embed it freely in your application (commercial or not), with or
|
|||
|
|
* without modifications.
|
|||
|
|
*
|
|||
|
|
* Reference: http://www.fpdf.org/en/script/script37.php
|
|||
|
|
*/function Jf(t,A){var e,r,n,i;if(t!==e){for(var a=(n=t,i=1+(256/t.length>>0),new Array(i+1).join(n)),s=[],o=0;o<256;o++)s[o]=o;var l=0;for(o=0;o<256;o++){var f=s[o];l=(l+f+a.charCodeAt(o))%256,s[o]=s[l],s[l]=f}e=t,r=s}else s=r;var d=A.length,p=0,h=0,m="";for(o=0;o<d;o++)h=(h+(f=s[p=(p+1)%256]))%256,s[p]=s[h],s[h]=f,a=s[(s[p]+s[h])%256],m+=String.fromCharCode(A.charCodeAt(o)^a);return m}/**
|
|||
|
|
* @license
|
|||
|
|
* Licensed under the MIT License.
|
|||
|
|
* http://opensource.org/licenses/mit-license
|
|||
|
|
* Author: Owen Leong (@owenl131)
|
|||
|
|
* Date: 15 Oct 2020
|
|||
|
|
* References:
|
|||
|
|
* https://www.cs.cmu.edu/~dst/Adobe/Gallery/anon21jul01-pdf-encryption.txt
|
|||
|
|
* https://github.com/foliojs/pdfkit/blob/master/lib/security.js
|
|||
|
|
* http://www.fpdf.org/en/script/script37.php
|
|||
|
|
*/var D1={print:4,modify:8,copy:16,"annot-forms":32};function ya(t,A,e,r){this.v=1,this.r=2;var n=192;t.forEach(function(s){if(D1.perm!==void 0)throw new Error("Invalid permission: "+s);n+=D1[s]}),this.padding="(¿N^NuAd\0NVÿú\b..\0¶Ðh>/\f©þdSiz";var i=(A+this.padding).substr(0,32),a=(e+this.padding).substr(0,32);this.O=this.processOwnerPassword(i,a),this.P=-(1+(255^n)),this.encryptionKey=Yf(i+this.O+this.lsbFirstWord(this.P)+this.hexToBytes(r)).substr(0,5),this.U=Jf(this.encryptionKey,this.padding)}function Ca(t){if(/[^\u0000-\u00ff]/.test(t))throw new Error("Invalid PDF Name Object: "+t+", Only accept ASCII characters.");for(var A="",e=t.length,r=0;r<e;r++){var n=t.charCodeAt(r);n<33||n===35||n===37||n===40||n===41||n===47||n===60||n===62||n===91||n===93||n===123||n===125||n>126?A+="#"+("0"+n.toString(16)).slice(-2):A+=t[r]}return A}function M1(t){if(Qe(t)!=="object")throw new Error("Invalid Context passed to initialize PubSub (jsPDF-module)");var A={};this.subscribe=function(e,r,n){if(n=n||!1,typeof e!="string"||typeof r!="function"||typeof n!="boolean")throw new Error("Invalid arguments passed to PubSub.subscribe (jsPDF-module)");A.hasOwnProperty(e)||(A[e]={});var i=Math.random().toString(35);return A[e][i]=[r,!!n],i},this.unsubscribe=function(e){for(var r in A)if(A[r][e])return delete A[r][e],Object.keys(A[r]).length===0&&delete A[r],!0;return!1},this.publish=function(e){if(A.hasOwnProperty(e)){var r=Array.prototype.slice.call(arguments,1),n=[];for(var i in A[e]){var a=A[e][i];try{a[0].apply(t,r)}catch(s){ee.console&&_e.error("jsPDF PubSub Error",s.message,s)}a[1]&&n.push(i)}n.length&&n.forEach(this.unsubscribe)}},this.getTopics=function(){return A}}function ku(t){if(!(this instanceof ku))return new ku(t);var A="opacity,stroke-opacity".split(",");for(var e in t)t.hasOwnProperty(e)&&A.indexOf(e)>=0&&(this[e]=t[e]);this.id="",this.objectNumber=-1}function R1(t,A){this.gState=t,this.matrix=A,this.id="",this.objectNumber=-1}function _i(t,A,e,r,n){if(!(this instanceof _i))return new _i(t,A,e,r,n);this.type=t==="axial"?2:3,this.coords=A,this.colors=e,R1.call(this,r,n)}function ba(t,A,e,r,n){if(!(this instanceof ba))return new ba(t,A,e,r,n);this.boundingBox=t,this.xStep=A,this.yStep=e,this.stream="",this.cloneIndex=0,R1.call(this,r,n)}function te(t){var A,e=typeof arguments[0]=="string"?arguments[0]:"p",r=arguments[1],n=arguments[2],i=arguments[3],a=[],s=1,o=16,l="S",f=null;Qe(t=t||{})==="object"&&(e=t.orientation,r=t.unit||r,n=t.format||n,i=t.compress||t.compressPdf||i,(f=t.encryption||null)!==null&&(f.userPassword=f.userPassword||"",f.ownerPassword=f.ownerPassword||"",f.userPermissions=f.userPermissions||[]),s=typeof t.userUnit=="number"?Math.abs(t.userUnit):1,t.precision!==void 0&&(A=t.precision),t.floatPrecision!==void 0&&(o=t.floatPrecision),l=t.defaultPathOperation||"S"),a=t.filters||(i===!0?["FlateEncode"]:a),r=r||"mm",e=(""+(e||"P")).toLowerCase();var d=t.putOnlyUsedFonts||!1,p={},h={internal:{},__private__:{}};h.__private__.PubSub=M1;var m="1.3",w=h.__private__.getPdfVersion=function(){return m};h.__private__.setPdfVersion=function(g){m=g};var b={a0:[2383.94,3370.39],a1:[1683.78,2383.94],a2:[1190.55,1683.78],a3:[841.89,1190.55],a4:[595.28,841.89],a5:[419.53,595.28],a6:[297.64,419.53],a7:[209.76,297.64],a8:[147.4,209.76],a9:[104.88,147.4],a10:[73.7,104.88],b0:[2834.65,4008.19],b1:[2004.09,2834.65],b2:[1417.32,2004.09],b3:[1000.63,1417.32],b4:[708.66,1000.63],b5:[498.9,708.66],b6:[354.33,498.9],b7:[249.45,354.33],b8:[175.75,249.45],b9:[124.72,175.75],b10:[87.87,124.72],c0:[2599.37,3676.54],c1:[1836.85,2599.37],c2:[1298.27,1836.85],c3:[918.43,1298.27],c4:[649.13,918.43],c5:[459.21,649.13],c6:[323.15,459.21],c7:[229.61,323.15],c8:[161.57,229.61],c9:[113.39,161.57],c10:[79.37,113.39],dl:[311.81,623.62],letter:[612,792],"government-letter":[576,756],legal:[612,1008],"junior-legal":[576,360],ledger:[1224,792],tabloid:[792,1224],"credit-card":[153,243]};h.__private__.getPageFormats=function(){return b};var y=h.__private__.getPageFormat=function(g){return b[g]};n=n||"a4";var U={COMPAT:"compat",ADVANCED:"advanc
|
|||
|
|
`),$e(g,F),be.publish("endTilingPattern",F),Ir.pop().restore()};var qe=h.__private__.newObject=function(){var g=We();return $t(g,!0),g},We=h.__private__.newObjectDeferred=function(){return W++,nA[W]=function(){return hA},W},$t=function(g,F){return F=typeof F=="boolean"&&F,nA[g]=hA,F&&V(g+" 0 obj"),g},fi=h.__private__.newAdditionalObject=function(){var g={objId:We(),content:""};return xA.push(g),g},tr=We(),ut=We(),or=h.__private__.decodeColorString=function(g){var F=g.split(" ");if(F.length!==2||F[1]!=="g"&&F[1]!=="G")F.length===5&&(F[4]==="k"||F[4]==="K")&&(F=[(1-F[0])*(1-F[3]),(1-F[1])*(1-F[3]),(1-F[2])*(1-F[3]),"r"]);else{var D=parseFloat(F[0]);F=[D,D,D,"r"]}for(var q="#",rA=0;rA<3;rA++)q+=("0"+Math.floor(255*parseFloat(F[rA])).toString(16)).slice(-2);return q},ur=h.__private__.encodeColorString=function(g){var F;typeof g=="string"&&(g={ch1:g});var D=g.ch1,q=g.ch2,rA=g.ch3,pA=g.ch4,UA=g.pdfColorType==="draw"?["G","RG","K"]:["g","rg","k"];if(typeof D=="string"&&D.charAt(0)!=="#"){var MA=new H1(D);if(MA.ok)D=MA.toHex();else if(!/^\d*\.?\d*$/.test(D))throw new Error('Invalid color "'+D+'" passed to jsPDF.encodeColorString.')}if(typeof D=="string"&&/^#[0-9A-Fa-f]{3}$/.test(D)&&(D="#"+D[1]+D[1]+D[2]+D[2]+D[3]+D[3]),typeof D=="string"&&/^#[0-9A-Fa-f]{6}$/.test(D)){var YA=parseInt(D.substr(1),16);D=YA>>16&255,q=YA>>8&255,rA=255&YA}if(q===void 0||pA===void 0&&D===q&&q===rA)if(typeof D=="string")F=D+" "+UA[0];else switch(g.precision){case 2:F=aA(D/255)+" "+UA[0];break;case 3:default:F=N(D/255)+" "+UA[0]}else if(pA===void 0||Qe(pA)==="object"){if(pA&&!isNaN(pA.a)&&pA.a===0)return F=["1.","1.","1.",UA[1]].join(" ");if(typeof D=="string")F=[D,q,rA,UA[1]].join(" ");else switch(g.precision){case 2:F=[aA(D/255),aA(q/255),aA(rA/255),UA[1]].join(" ");break;default:case 3:F=[N(D/255),N(q/255),N(rA/255),UA[1]].join(" ")}}else if(typeof D=="string")F=[D,q,rA,pA,UA[2]].join(" ");else switch(g.precision){case 2:F=[aA(D),aA(q),aA(rA),aA(pA),UA[2]].join(" ");break;case 3:default:F=[N(D),N(q),N(rA),N(pA),UA[2]].join(" ")}return F},Br=h.__private__.getFilters=function(){return a},rr=h.__private__.putStream=function(g){var F=(g=g||{}).data||"",D=g.filters||Br(),q=g.alreadyAppliedFilters||[],rA=g.addLength1||!1,pA=F.length,UA=g.objectId,MA=function(Wt){return Wt};if(f!==null&&UA===void 0)throw new Error("ObjectId must be passed to putStream for file encryption");f!==null&&(MA=qt.encryptor(UA,0));var YA={};D===!0&&(D=["FlateEncode"]);var le=g.additionalKeyValues||[],de=(YA=te.API.processDataByFilters!==void 0?te.API.processDataByFilters(F,D):{data:F,reverseChain:[]}).reverseChain+(Array.isArray(q)?q.join(" "):q.toString());if(YA.data.length!==0&&(le.push({key:"Length",value:YA.data.length}),rA===!0&&le.push({key:"Length1",value:pA})),de.length!=0)if(de.split("/").length-1==1)le.push({key:"Filter",value:de});else{le.push({key:"Filter",value:"["+de+"]"});for(var Ce=0;Ce<le.length;Ce+=1)if(le[Ce].key==="DecodeParms"){for(var Xe=[],At=0;At<YA.reverseChain.split("/").length-1;At+=1)Xe.push("null");Xe.push(le[Ce].value),le[Ce].value="["+Xe.join(" ")+"]"}}V("<<");for(var wt=0;wt<le.length;wt++)V("/"+le[wt].key+" "+le[wt].value);V(">>"),YA.data.length!==0&&(V("stream"),V(MA(YA.data)),V("endstream"))},Lr=h.__private__.putPage=function(g){var F=g.number,D=g.data,q=g.objId,rA=g.contentsObjId;$t(q,!0),V("<</Type /Page"),V("/Parent "+g.rootDictionaryObjId+" 0 R"),V("/Resources "+g.resourceDictionaryObjId+" 0 R"),V("/MediaBox ["+parseFloat(K(g.mediaBox.bottomLeftX))+" "+parseFloat(K(g.mediaBox.bottomLeftY))+" "+K(g.mediaBox.topRightX)+" "+K(g.mediaBox.topRightY)+"]"),g.cropBox!==null&&V("/CropBox ["+K(g.cropBox.bottomLeftX)+" "+K(g.cropBox.bottomLeftY)+" "+K(g.cropBox.topRightX)+" "+K(g.cropBox.topRightY)+"]"),g.bleedBox!==null&&V("/BleedBox ["+K(g.bleedBox.bottomLeftX)+" "+K(g.bleedBox.bottomLeftY)+" "+K(g.bleedBox.topRightX)+" "+K(g.bleedBox.topRightY)+"]"),g.trimBox!==null&&V("/TrimBox ["+K(g.trimBox.bottomLeftX)+" "+K(g.trimBox.bottomLeftY)+" "+K(g.trimBox.topRightX)+" "+K(g.trimBox.topRightY)+"]"),g.artBox!==null&&V("/ArtBox ["+K(g.artBox.bottomLeftX)+" "
|
|||
|
|
`);return T===U.ADVANCED&&(pA+=`
|
|||
|
|
Q`),$t(rA,!0),rr({data:pA,filters:Br(),objectId:rA}),V("endobj"),q},qA=h.__private__.putPages=function(){var g,F,D=[];for(g=1;g<=Le;g++)ie[g].objId=We(),ie[g].contentsObjId=We();for(g=1;g<=Le;g++)D.push(Lr({number:g,data:EA[g],objId:ie[g].objId,contentsObjId:ie[g].contentsObjId,mediaBox:ie[g].mediaBox,cropBox:ie[g].cropBox,bleedBox:ie[g].bleedBox,trimBox:ie[g].trimBox,artBox:ie[g].artBox,userUnit:ie[g].userUnit,rootDictionaryObjId:tr,resourceDictionaryObjId:ut}));$t(tr,!0),V("<</Type /Pages");var q="/Kids [";for(F=0;F<Le;F++)q+=D[F]+" 0 R ";V(q+"]"),V("/Count "+Le),V(">>"),V("endobj"),be.publish("postPutPages")},Y=function(g){be.publish("putFont",{font:g,out:V,newObject:qe,putStream:rr}),g.isAlreadyPutted!==!0&&(g.objectNumber=qe(),V("<<"),V("/Type /Font"),V("/BaseFont /"+Ca(g.postScriptName)),V("/Subtype /Type1"),typeof g.encoding=="string"&&V("/Encoding /"+g.encoding),V("/FirstChar 32"),V("/LastChar 255"),V(">>"),V("endobj"))},QA=function(){for(var g in pe)pe.hasOwnProperty(g)&&(d===!1||d===!0&&p.hasOwnProperty(g))&&Y(pe[g])},OA=function(g){g.objectNumber=qe();var F=[];F.push({key:"Type",value:"/XObject"}),F.push({key:"Subtype",value:"/Form"}),F.push({key:"BBox",value:"["+[K(g.x),K(g.y),K(g.x+g.width),K(g.y+g.height)].join(" ")+"]"}),F.push({key:"Matrix",value:"["+g.matrix.toString()+"]"});var D=g.pages[1].join(`
|
|||
|
|
`);rr({data:D,additionalKeyValues:F,objectId:g.objectNumber}),V("endobj")},ve=function(){for(var g in vt)vt.hasOwnProperty(g)&&OA(vt[g])},bt=function(g,F){var D,q=[],rA=1/(F-1);for(D=0;D<1;D+=rA)q.push(D);if(q.push(1),g[0].offset!=0){var pA={offset:0,color:g[0].color};g.unshift(pA)}if(g[g.length-1].offset!=1){var UA={offset:1,color:g[g.length-1].color};g.push(UA)}for(var MA="",YA=0,le=0;le<q.length;le++){for(D=q[le];D>g[YA+1].offset;)YA++;var de=g[YA].offset,Ce=(D-de)/(g[YA+1].offset-de),Xe=g[YA].color,At=g[YA+1].color;MA+=$(Math.round((1-Ce)*Xe[0]+Ce*At[0]).toString(16))+$(Math.round((1-Ce)*Xe[1]+Ce*At[1]).toString(16))+$(Math.round((1-Ce)*Xe[2]+Ce*At[2]).toString(16))}return MA.trim()},Bt=function(g,F){F||(F=21);var D=qe(),q=bt(g.colors,F),rA=[];rA.push({key:"FunctionType",value:"0"}),rA.push({key:"Domain",value:"[0.0 1.0]"}),rA.push({key:"Size",value:"["+F+"]"}),rA.push({key:"BitsPerSample",value:"8"}),rA.push({key:"Range",value:"[0.0 1.0 0.0 1.0 0.0 1.0]"}),rA.push({key:"Decode",value:"[0.0 1.0 0.0 1.0 0.0 1.0]"}),rr({data:q,additionalKeyValues:rA,alreadyAppliedFilters:["/ASCIIHexDecode"],objectId:D}),V("endobj"),g.objectNumber=qe(),V("<< /ShadingType "+g.type),V("/ColorSpace /DeviceRGB");var pA="/Coords ["+K(parseFloat(g.coords[0]))+" "+K(parseFloat(g.coords[1]))+" ";g.type===2?pA+=K(parseFloat(g.coords[2]))+" "+K(parseFloat(g.coords[3])):pA+=K(parseFloat(g.coords[2]))+" "+K(parseFloat(g.coords[3]))+" "+K(parseFloat(g.coords[4]))+" "+K(parseFloat(g.coords[5])),V(pA+="]"),g.matrix&&V("/Matrix ["+g.matrix.toString()+"]"),V("/Function "+D+" 0 R"),V("/Extend [true true]"),V(">>"),V("endobj")},lt=function(g,F){var D=We(),q=qe();F.push({resourcesOid:D,objectOid:q}),g.objectNumber=q;var rA=[];rA.push({key:"Type",value:"/Pattern"}),rA.push({key:"PatternType",value:"1"}),rA.push({key:"PaintType",value:"1"}),rA.push({key:"TilingType",value:"1"}),rA.push({key:"BBox",value:"["+g.boundingBox.map(K).join(" ")+"]"}),rA.push({key:"XStep",value:K(g.xStep)}),rA.push({key:"YStep",value:K(g.yStep)}),rA.push({key:"Resources",value:D+" 0 R"}),g.matrix&&rA.push({key:"Matrix",value:"["+g.matrix.toString()+"]"}),rr({data:g.stream,additionalKeyValues:rA,objectId:g.objectNumber}),V("endobj")},Yr=function(g){var F;for(F in we)we.hasOwnProperty(F)&&(we[F]instanceof _i?Bt(we[F]):we[F]instanceof ba&<(we[F],g))},ze=function(g){for(var F in g.objectNumber=qe(),V("<<"),g)switch(F){case"opacity":V("/ca "+aA(g[F]));break;case"stroke-opacity":V("/CA "+aA(g[F]))}V(">>"),V("endobj")},ea=function(){var g;for(g in Se)Se.hasOwnProperty(g)&&ze(Se[g])},hi=function(){for(var g in V("/XObject <<"),vt)vt.hasOwnProperty(g)&&vt[g].objectNumber>=0&&V("/"+g+" "+vt[g].objectNumber+" 0 R");be.publish("putXobjectDict"),V(">>")},Zl=function(){qt.oid=qe(),V("<<"),V("/Filter /Standard"),V("/V "+qt.v),V("/R "+qt.r),V("/U <"+qt.toHexString(qt.U)+">"),V("/O <"+qt.toHexString(qt.O)+">"),V("/P "+qt.P),V(">>"),V("endobj")},Ac=function(){for(var g in V("/Font <<"),pe)pe.hasOwnProperty(g)&&(d===!1||d===!0&&p.hasOwnProperty(g))&&V("/"+g+" "+pe[g].objectNumber+" 0 R");V(">>")},Pd=function(){if(Object.keys(we).length>0){for(var g in V("/Shading <<"),we)we.hasOwnProperty(g)&&we[g]instanceof _i&&we[g].objectNumber>=0&&V("/"+g+" "+we[g].objectNumber+" 0 R");be.publish("putShadingPatternDict"),V(">>")}},Wa=function(g){if(Object.keys(we).length>0){for(var F in V("/Pattern <<"),we)we.hasOwnProperty(F)&&we[F]instanceof h.TilingPattern&&we[F].objectNumber>=0&&we[F].objectNumber<g&&V("/"+F+" "+we[F].objectNumber+" 0 R");be.publish("putTilingPatternDict"),V(">>")}},Dd=function(){if(Object.keys(Se).length>0){var g;for(g in V("/ExtGState <<"),Se)Se.hasOwnProperty(g)&&Se[g].objectNumber>=0&&V("/"+g+" "+Se[g].objectNumber+" 0 R");be.publish("putGStateDict"),V(">>")}},ct=function(g){$t(g.resourcesOid,!0),V("<<"),V("/ProcSet [/PDF /Text /ImageB /ImageC /ImageI]"),Ac(),Pd(),Wa(g.objectOid),Dd(),hi(),V(">>"),V("endobj")},ec=function(){var g=[];QA(),ea(),ve(),Yr(g),be.publish("putResources"),g.forEach(ct),ct({resourcesOid:ut,objectOid:Number.MAX_SAFE_INTEGER}),be.publish("postPutResources")},tc=fun
|
|||
|
|
`)[0].split("<")[0]+": "+q.message;if(!ee.console)throw new Error(D);ee.console.error(D,q),ee.alert&&alert(D)}},g.foo.bar=g,g.foo},za=function(g,F){var D,q,rA,pA,UA,MA,YA,le,de;if(rA=(F=F||{}).sourceEncoding||"Unicode",UA=F.outputEncoding,(F.autoencode||UA)&&pe[ne].metadata&&pe[ne].metadata[rA]&&pe[ne].metadata[rA].encoding&&(pA=pe[ne].metadata[rA].encoding,!UA&&pe[ne].encoding&&(UA=pe[ne].encoding),!UA&&pA.codePages&&(UA=pA.codePages[0]),typeof UA=="string"&&(UA=pA[UA]),UA)){for(YA=!1,MA=[],D=0,q=g.length;D<q;D++)(le=UA[g.charCodeAt(D)])?MA.push(String.fromCharCode(le)):MA.push(g[D]),MA[D].charCodeAt(0)>>8&&(YA=!0);g=MA.join("")}for(D=g.length;YA===void 0&&D!==0;)g.charCodeAt(D-1)>>8&&(YA=!0),D--;if(!YA)return g;for(MA=F.noBOM?[]:[254,255],D=0,q=g.length;D<q;D++){if((de=(le=g.charCodeAt(D))>>8)>>8)throw new Error("Character at position "+D+" of string '"+g+"' exceeds 16bits. Cannot be encoded into UCS-2 BE");MA.push(de),MA.push(le-(de<<8))}return String.fromCharCode.apply(void 0,MA)},lr=h.__private__.pdfEscape=h.pdfEscape=function(g,F){return za(g,F).replace(/\\/g,"\\\\").replace(/\(/g,"\\(").replace(/\)/g,"\\)")},po=h.__private__.beginPage=function(g){EA[++Le]=[],ie[Le]={objId:0,contentsObjId:0,userUnit:Number(s),artBox:null,bleedBox:null,cropBox:null,trimBox:null,mediaBox:{bottomLeftX:0,bottomLeftY:0,topRightX:Number(g[0]),topRightY:Number(g[1])}},ic(Le),gA(EA[_])},nc=function(g,F){var D,q,rA;switch(e=F||e,typeof g=="string"&&(D=y(g.toLowerCase()),Array.isArray(D)&&(q=D[0],rA=D[1])),Array.isArray(g)&&(q=g[0]*TA,rA=g[1]*TA),isNaN(q)&&(q=n[0],rA=n[1]),(q>14400||rA>14400)&&(_e.warn("A page in a PDF can not be wider or taller than 14400 userUnit. jsPDF limits the width/height to 14400"),q=Math.min(14400,q),rA=Math.min(14400,rA)),n=[q,rA],e.substr(0,1)){case"l":rA>q&&(n=[rA,q]);break;case"p":q>rA&&(n=[rA,q])}po(n),cc(mo),V(Zr),Co!==0&&V(Co+" J"),bo!==0&&V(bo+" j"),be.publish("addPage",{pageNumber:Le})},Rd=function(g){g>0&&g<=Le&&(EA.splice(g,1),ie.splice(g,1),Le--,_>Le&&(_=Le),this.setPage(_))},ic=function(g){g>0&&g<=Le&&(_=g)},kd=h.__private__.getNumberOfPages=h.getNumberOfPages=function(){return EA.length-1},ac=function(g,F,D){var q,rA=void 0;return D=D||{},g=g!==void 0?g:pe[ne].fontName,F=F!==void 0?F:pe[ne].fontStyle,q=g.toLowerCase(),Ue[q]!==void 0&&Ue[q][F]!==void 0?rA=Ue[q][F]:Ue[g]!==void 0&&Ue[g][F]!==void 0?rA=Ue[g][F]:D.disableWarning===!1&&_e.warn("Unable to look up font label for font '"+g+"', '"+F+"'. Refer to getFontList() for available fonts."),rA||D.noFallback||(rA=Ue.times[F])==null&&(rA=Ue.times.normal),rA},Kd=h.__private__.putInfo=function(){var g=qe(),F=function(q){return q};for(var D in f!==null&&(F=qt.encryptor(g,0)),V("<<"),V("/Producer ("+lr(F("jsPDF "+te.version))+")"),zA)zA.hasOwnProperty(D)&&zA[D]&&V("/"+D.substr(0,1).toUpperCase()+D.substr(1)+" ("+lr(F(zA[D]))+")");V("/CreationDate ("+lr(F(iA))+")"),V(">>"),V("endobj")},vo=h.__private__.putCatalog=function(g){var F=(g=g||{}).rootDictionaryObjId||tr;switch(qe(),V("<<"),V("/Type /Catalog"),V("/Pages "+F+" 0 R"),LA||(LA="fullwidth"),LA){case"fullwidth":V("/OpenAction [3 0 R /FitH null]");break;case"fullheight":V("/OpenAction [3 0 R /FitV null]");break;case"fullpage":V("/OpenAction [3 0 R /Fit]");break;case"original":V("/OpenAction [3 0 R /XYZ null null 1]");break;default:var D=""+LA;D.substr(D.length-1)==="%"&&(LA=parseInt(LA)/100),typeof LA=="number"&&V("/OpenAction [3 0 R /XYZ null null "+aA(LA)+"]")}switch(re||(re="continuous"),re){case"continuous":V("/PageLayout /OneColumn");break;case"single":V("/PageLayout /SinglePage");break;case"two":case"twoleft":V("/PageLayout /TwoColumnLeft");break;case"tworight":V("/PageLayout /TwoColumnRight")}GA&&V("/PageMode /"+GA),be.publish("putCatalog"),V(">>"),V("endobj")},Vd=h.__private__.putTrailer=function(){V("trailer"),V("<<"),V("/Size "+(W+1)),V("/Root "+W+" 0 R"),V("/Info "+(W-1)+" 0 R"),f!==null&&V("/Encrypt "+qt.oid+" 0 R"),V("/ID [ <"+tA+"> <"+tA+"> ]"),V(">>")},jd=h.__private__.putHeader=function(){V("%PDF-"+m),V("%ºß¬à")},Gd=h.__private__.putXRef=function(){var g="0000000000";V("xref"),V("0 "+(W
|
|||
|
|
`)},Xa=h.__private__.getBlob=function(g){return new Blob([KA(g)],{type:"application/pdf"})},Ya=h.output=h.__private__.output=Jr(function(g,F){switch(typeof(F=F||{})=="string"?F={filename:F}:F.filename=F.filename||"generated.pdf",g){case void 0:return _n();case"save":h.save(F.filename);break;case"arraybuffer":return KA(_n());case"blob":return Xa(_n());case"bloburi":case"bloburl":if(ee.URL!==void 0&&typeof ee.URL.createObjectURL=="function")return ee.URL&&ee.URL.createObjectURL(Xa(_n()))||void 0;_e.warn("bloburl is not supported by your system, because URL.createObjectURL is not supported by your browser.");break;case"datauristring":case"dataurlstring":var D="",q=_n();try{D=zf(q)}catch{D=zf(unescape(encodeURIComponent(q)))}return"data:application/pdf;filename="+F.filename+";base64,"+D;case"pdfobjectnewwindow":if(Object.prototype.toString.call(ee)==="[object Window]"){var rA="https://cdnjs.cloudflare.com/ajax/libs/pdfobject/2.1.1/pdfobject.min.js",pA=' integrity="sha512-4ze/a9/4jqu+tX9dfOqJYSvyYd5M6qum/3HpCLr+/Jqf0whc37VUbkpNGHR7/8pSnCFw47T1fmIpwBV7UySh3g==" crossorigin="anonymous"';F.pdfObjectUrl&&(rA=F.pdfObjectUrl,pA="");var UA='<html><style>html, body { padding: 0; margin: 0; } iframe { width: 100%; height: 100%; border: 0;} </style><body><script src="'+rA+'"'+pA+'><\/script><script >PDFObject.embed("'+this.output("dataurlstring")+'", '+JSON.stringify(F)+");<\/script></body></html>",MA=ee.open();return MA!==null&&MA.document.write(UA),MA}throw new Error("The option pdfobjectnewwindow just works in a browser-environment.");case"pdfjsnewwindow":if(Object.prototype.toString.call(ee)==="[object Window]"){var YA='<html><style>html, body { padding: 0; margin: 0; } iframe { width: 100%; height: 100%; border: 0;} </style><body><iframe id="pdfViewer" src="'+(F.pdfJsUrl||"examples/PDF.js/web/viewer.html")+"?file=&downloadName="+F.filename+'" width="500px" height="400px" /></body></html>',le=ee.open();if(le!==null){le.document.write(YA);var de=this;le.document.documentElement.querySelector("#pdfViewer").onload=function(){le.document.title=F.filename,le.document.documentElement.querySelector("#pdfViewer").contentWindow.PDFViewerApplication.open(de.output("bloburl"))}}return le}throw new Error("The option pdfjsnewwindow just works in a browser-environment.");case"dataurlnewwindow":if(Object.prototype.toString.call(ee)!=="[object Window]")throw new Error("The option dataurlnewwindow just works in a browser-environment.");var Ce='<html><style>html, body { padding: 0; margin: 0; } iframe { width: 100%; height: 100%; border: 0;} </style><body><iframe src="'+this.output("datauristring",F)+'"></iframe></body></html>',Xe=ee.open();if(Xe!==null&&(Xe.document.write(Ce),Xe.document.title=F.filename),Xe||typeof safari>"u")return Xe;break;case"datauri":case"dataurl":return ee.document.location.href=this.output("datauristring",F);default:return null}}),sc=function(g){return Array.isArray(Xr)===!0&&Xr.indexOf(g)>-1};switch(r){case"pt":TA=1;break;case"mm":TA=72/25.4;break;case"cm":TA=72/2.54;break;case"in":TA=72;break;case"px":TA=sc("px_scaling")==1?.75:96/72;break;case"pc":case"em":TA=12;break;case"ex":TA=6;break;default:if(typeof r!="number")throw new Error("Invalid unit: "+r);TA=r}var qt=null;bA(),eA();var $d=function(g){return f!==null?qt.encryptor(g,0):function(F){return F}},oc=h.__private__.getPageInfo=h.getPageInfo=function(g){if(isNaN(g)||g%1!=0)throw new Error("Invalid argument passed to jsPDF.getPageInfo");return{objId:ie[g].objId,pageNumber:g,pageContext:ie[g]}},ae=h.__private__.getPageInfoByObjId=function(g){if(isNaN(g)||g%1!=0)throw new Error("Invalid argument passed to jsPDF.getPageInfoByObjId");for(var F in ie)if(ie[F].objId===g)break;return oc(F)},qd=h.__private__.getCurrentPageInfo=h.getCurrentPageInfo=function(){return{objId:ie[_].objId,pageNumber:_,pageContext:ie[_]}};h.addPage=function(){return nc.apply(this,arguments),this},h.setPage=function(){return ic.apply(this,arguments),gA.call(this,EA[_]),this},h.insertPage=function(g){return this.addPage(),this.movePage(_,g),this},h.movePage=function(g,F){var D,q;if(g>F){D=EA[g],q=
|
|||
|
|
`,this.setCharSpace(this.getCharSpace()||0)),(Xe=q.horizontalScale)!==void 0&&(St+=K(100*Xe)+` Tz
|
|||
|
|
`),q.lang;var fr=-1,r0=q.renderingMode!==void 0?q.renderingMode:q.stroke,To=wt.internal.getCurrentPageInfo().pageContext;switch(r0){case 0:case!1:case"fill":fr=0;break;case 1:case!0:case"stroke":fr=1;break;case 2:case"fillThenStroke":fr=2;break;case 3:case"invisible":fr=3;break;case 4:case"fillAndAddForClipping":fr=4;break;case 5:case"strokeAndAddPathForClipping":fr=5;break;case 6:case"fillThenStrokeAndAddToPathForClipping":fr=6;break;case 7:case"addToPathForClipping":fr=7}var Bc=To.usedRenderingMode!==void 0?To.usedRenderingMode:-1;fr!==-1?St+=fr+` Tr
|
|||
|
|
`:Bc!==-1&&(St+=`0 Tr
|
|||
|
|
`),fr!==-1&&(To.usedRenderingMode=fr),YA=q.align||"left";var en,Oo=IA*wr,n0=wt.internal.pageSize.getWidth(),i0=pe[ne];le=q.charSpace||As,de=q.maxWidth||0,Ce=Object.assign({autoencode:!0,noBOM:!0},q.flags);var Bi=[];if(Object.prototype.toString.call(g)==="[object Array]"){var Nr;UA=xo(g),YA!=="left"&&(en=UA.map(function(ke){return wt.getStringUnitWidth(ke,{font:i0,charSpace:le,fontSize:IA,doKerning:!1})*IA/Dn}));var tn,wi=0;if(YA==="right"){F-=en[0],g=[],cr=UA.length;for(var yn=0;yn<cr;yn++)yn===0?(tn=Pn(F),Nr=di(D)):(tn=S(wi-en[yn]),Nr=-Oo),g.push([UA[yn],tn,Nr]),wi=en[yn]}else if(YA==="center"){F-=en[0]/2,g=[],cr=UA.length;for(var Mn=0;Mn<cr;Mn++)Mn===0?(tn=Pn(F),Nr=di(D)):(tn=S((wi-en[Mn])/2),Nr=-Oo),g.push([UA[Mn],tn,Nr]),wi=en[Mn]}else if(YA==="left"){g=[],cr=UA.length;for(var os=0;os<cr;os++)g.push(UA[os])}else{if(YA!=="justify")throw new Error('Unrecognized alignment option, use "left", "center", "right" or "justify".');g=[],cr=UA.length,de=de!==0?de:n0;for(var rn=0;rn<cr;rn++)Nr=rn===0?di(D):-Oo,tn=rn===0?Pn(F):0,rn<cr-1?Bi.push(K(S((de-en[rn])/(UA[rn].split(" ").length-1)))):Bi.push(0),g.push([UA[rn],tn,Nr])}}var us=typeof q.R2L=="boolean"?q.R2L:VA;us===!0&&(g=Io(g,function(ke,Ke,ft){return[ke.split("").reverse().join(""),Ke,ft]})),pA={text:g,x:F,y:D,options:q,mutex:{pdfEscape:lr,activeFontKey:ne,fonts:pe,activeFontSize:IA}},be.publish("postProcessText",pA),g=pA.text,An=pA.mutex.isHex||!1;var Ho=pe[ne].encoding;Ho!=="WinAnsiEncoding"&&Ho!=="StandardEncoding"||(g=Io(g,function(ke,Ke,ft){return[vc(ke),Ke,ft]})),UA=xo(g),g=[];for(var mi,nn,Rn,aa=0,ls=1,sa=Array.isArray(UA[0])?ls:aa,yi="",_o=function(ke,Ke,ft){var Ft="";return ft instanceof XA?(ft=typeof q.angle=="number"?er(ft,new XA(1,0,0,1,ke,Ke)):er(new XA(1,0,0,1,ke,Ke),ft),T===U.ADVANCED&&(ft=er(new XA(1,0,0,-1,0,0),ft)),Ft=ft.join(" ")+` Tm
|
|||
|
|
`):Ft=K(ke)+" "+K(Ke)+` Td
|
|||
|
|
`,Ft},Tr=0;Tr<UA.length;Tr++){switch(yi="",sa){case ls:Rn=(An?"<":"(")+UA[Tr][0]+(An?">":")"),mi=parseFloat(UA[Tr][1]),nn=parseFloat(UA[Tr][2]);break;case aa:Rn=(An?"<":"(")+UA[Tr]+(An?">":")"),mi=Pn(F),nn=di(D)}Bi!==void 0&&Bi[Tr]!==void 0&&(yi=Bi[Tr]+` Tw
|
|||
|
|
`),Tr===0?g.push(yi+_o(mi,nn,At)+Rn):sa===aa?g.push(yi+Rn):sa===ls&&g.push(yi+_o(mi,nn,At)+Rn)}g=sa===aa?g.join(` Tj
|
|||
|
|
T* `):g.join(` Tj
|
|||
|
|
`),g+=` Tj
|
|||
|
|
`;var kn=`BT
|
|||
|
|
/`;return kn+=ne+" "+IA+` Tf
|
|||
|
|
`,kn+=K(IA*wr)+` TL
|
|||
|
|
`,kn+=na+`
|
|||
|
|
`,kn+=St,kn+=g,V(kn+="ET"),p[ne]=!0,wt};var Wd=h.__private__.clip=h.clip=function(g){return V(g==="evenodd"?"W*":"W"),this};h.clipEvenOdd=function(){return Wd("evenodd")},h.__private__.discardPath=h.discardPath=function(){return V("n"),this};var mn=h.__private__.isValidStyle=function(g){var F=!1;return[void 0,null,"S","D","F","DF","FD","f","f*","B","B*","n"].indexOf(g)!==-1&&(F=!0),F};h.__private__.setDefaultPathOperation=h.setDefaultPathOperation=function(g){return mn(g)&&(l=g),this};var uc=h.__private__.getStyle=h.getStyle=function(g){var F=l;switch(g){case"D":case"S":F="S";break;case"F":F="f";break;case"FD":case"DF":F="B";break;case"f":case"f*":case"B":case"B*":F=g}return F},lc=h.close=function(){return V("h"),this};h.stroke=function(){return V("S"),this},h.fill=function(g){return Ja("f",g),this},h.fillEvenOdd=function(g){return Ja("f*",g),this},h.fillStroke=function(g){return Ja("B",g),this},h.fillStrokeEvenOdd=function(g){return Ja("B*",g),this};var Ja=function(g,F){Qe(F)==="object"?Xd(F,g):V(g)},Bo=function(g){g===null||T===U.ADVANCED&&g===void 0||(g=uc(g),V(g))};function zd(g,F,D,q,rA){var pA=new ba(F||this.boundingBox,D||this.xStep,q||this.yStep,this.gState,rA||this.matrix);pA.stream=this.stream;var UA=g+"$$"+this.cloneIndex+++"$$";return $e(UA,pA),pA}var Xd=function(g,F){var D=pt[g.key],q=we[D];if(q instanceof _i)V("q"),V(Yd(F)),q.gState&&h.setGState(q.gState),V(g.matrix.toString()+" cm"),V("/"+D+" sh"),V("Q");else if(q instanceof ba){var rA=new XA(1,0,0,-1,0,vi());g.matrix&&(rA=rA.multiply(g.matrix||Sr),D=zd.call(q,g.key,g.boundingBox,g.xStep,g.yStep,rA).id),V("q"),V("/Pattern cs"),V("/"+D+" scn"),q.gState&&h.setGState(q.gState),V(F),V("Q")}},Yd=function(g){switch(g){case"f":case"F":return"W n";case"f*":return"W* n";case"B":return"W S";case"B*":return"W* S";case"S":return"W S";case"n":return"W n"}},wo=h.moveTo=function(g,F){return V(K(S(g))+" "+K(R(F))+" m"),this},ta=h.lineTo=function(g,F){return V(K(S(g))+" "+K(R(F))+" l"),this},gi=h.curveTo=function(g,F,D,q,rA,pA){return V([K(S(g)),K(R(F)),K(S(D)),K(R(q)),K(S(rA)),K(R(pA)),"c"].join(" ")),this};h.__private__.line=h.line=function(g,F,D,q,rA){if(isNaN(g)||isNaN(F)||isNaN(D)||isNaN(q)||!mn(rA))throw new Error("Invalid arguments passed to jsPDF.line");return T===U.COMPAT?this.lines([[D-g,q-F]],g,F,[1,1],rA||"S"):this.lines([[D-g,q-F]],g,F,[1,1]).stroke()},h.__private__.lines=h.lines=function(g,F,D,q,rA,pA){var UA,MA,YA,le,de,Ce,Xe,At,wt,Wt,St,An;if(typeof g=="number"&&(An=D,D=F,F=g,g=An),q=q||[1,1],pA=pA||!1,isNaN(F)||isNaN(D)||!Array.isArray(g)||!Array.isArray(q)||!mn(rA)||typeof pA!="boolean")throw new Error("Invalid arguments passed to jsPDF.lines");for(wo(F,D),UA=q[0],MA=q[1],le=g.length,Wt=F,St=D,YA=0;YA<le;YA++)(de=g[YA]).length===2?(Wt=de[0]*UA+Wt,St=de[1]*MA+St,ta(Wt,St)):(Ce=de[0]*UA+Wt,Xe=de[1]*MA+St,At=de[2]*UA+Wt,wt=de[3]*MA+St,Wt=de[4]*UA+Wt,St=de[5]*MA+St,gi(Ce,Xe,At,wt,Wt,St));return pA&&lc(),Bo(rA),this},h.path=function(g){for(var F=0;F<g.length;F++){var D=g[F],q=D.c;switch(D.op){case"m":wo(q[0],q[1]);break;case"l":ta(q[0],q[1]);break;case"c":gi.apply(this,q);break;case"h":lc()}}return this},h.__private__.rect=h.rect=function(g,F,D,q,rA){if(isNaN(g)||isNaN(F)||isNaN(D)||isNaN(q)||!mn(rA))throw new Error("Invalid arguments passed to jsPDF.rect");return T===U.COMPAT&&(q=-q),V([K(S(g)),K(R(F)),K(S(D)),K(S(q)),"re"].join(" ")),Bo(rA),this},h.__private__.triangle=h.triangle=function(g,F,D,q,rA,pA,UA){if(isNaN(g)||isNaN(F)||isNaN(D)||isNaN(q)||isNaN(rA)||isNaN(pA)||!mn(UA))throw new Error("Invalid arguments passed to jsPDF.triangle");return this.lines([[D-g,q-F],[rA-D,pA-q],[g-rA,F-pA]],g,F,[1,1],UA,!0),this},h.__private__.roundedRect=h.roundedRect=function(g,F,D,q,rA,pA,UA){if(isNaN(g)||isNaN(F)||isNaN(D)||isNaN(q)||isNaN(rA)||isNaN(pA)||!mn(UA))throw new Error("Invalid arguments passed to jsPDF.roundedRect");var MA=4/3*(Math.SQRT2-1);return rA=Math.min(rA,.5*D),pA=Math.min(pA,.5*q),this.lines([[D-2*rA,0],[rA*MA,0,rA,pA-pA*MA,rA,pA],[0,q-2*pA],[0,pA*MA,-rA*MA,pA,-rA,pA],[2*rA-D,0],[-rA*MA,0,-rA,-pA*MA,-rA,-pA],[0,2*pA-q],[0,-pA*MA,rA*MA,-pA,rA,-pA]],g
|
|||
|
|
`),i}},Ah=function(t,A){var e=t.fontSize===0?t.maxFontSize:t.fontSize,r={text:"",fontSize:""},n=(A=(A=A.substr(0,1)=="("?A.substr(1):A).substr(A.length-1)==")"?A.substr(0,A.length-1):A).split(" ");n=t.multiline?n.map(function(N){return N.split(`
|
|||
|
|
`)}):n.map(function(N){return[N]});var i=e,a=$A.internal.getHeight(t)||0;a=a<0?-a:a;var s=$A.internal.getWidth(t)||0;s=s<0?-s:s;var o=function(N,S,M){if(N+1<n.length){var R=S+" "+n[N+1][0];return Ku(R,t,M).width<=s-4}return!1};i++;A:for(;i>0;){A="",i--;var l,f,d=Ku("3",t,i).height,p=t.multiline?a-i:(a-d)/2,h=p+=2,m=0,w=0,b=0;if(i<=0){A=`(...) Tj
|
|||
|
|
`,A+="% Width of Text: "+Ku(A,t,i=12).width+", FieldWidth:"+s+`
|
|||
|
|
`;break}for(var y="",U=0,T=0;T<n.length;T++)if(n.hasOwnProperty(T)){var k=!1;if(n[T].length!==1&&b!==n[T].length-1){if((d+2)*(U+2)+2>a)continue A;y+=n[T][b],k=!0,w=T,T--}else{y=(y+=n[T][b]+" ").substr(y.length-1)==" "?y.substr(0,y.length-1):y;var G=parseInt(T),j=o(G,y,i),K=T>=n.length-1;if(j&&!K){y+=" ",b=0;continue}if(j||K){if(K)w=G;else if(t.multiline&&(d+2)*(U+2)+2>a)continue A}else{if(!t.multiline||(d+2)*(U+2)+2>a)continue A;w=G}}for(var O="",Z=m;Z<=w;Z++){var aA=n[Z];if(t.multiline){if(Z===w){O+=aA[b]+" ",b=(b+1)%aA.length;continue}if(Z===m){O+=aA[aA.length-1]+" ";continue}}O+=aA[0]+" "}switch(O=O.substr(O.length-1)==" "?O.substr(0,O.length-1):O,f=Ku(O,t,i).width,t.textAlign){case"right":l=s-f-2;break;case"center":l=(s-f)/2;break;case"left":default:l=2}A+=se(l)+" "+se(h)+` Td
|
|||
|
|
`,A+="("+Pi(O)+`) Tj
|
|||
|
|
`,A+=-se(l)+` 0 Td
|
|||
|
|
`,h=-(i+2),f=0,m=k?w:w+1,U++,y=""}break}return r.text=A,r.fontSize=i,r},Ku=function(t,A,e){var r=A.scope.internal.getFont(A.fontName,A.fontStyle),n=A.scope.getStringUnitWidth(t,{font:r,fontSize:parseFloat(e),charSpace:0})*parseFloat(e);return{height:A.scope.getStringUnitWidth("3",{font:r,fontSize:parseFloat(e),charSpace:0})*parseFloat(e)*1.5,width:n}},EQ={fields:[],xForms:[],acroFormDictionaryRoot:null,printedOut:!1,internal:null,isInitialized:!1},xQ=function(t,A){var e={type:"reference",object:t};A.internal.getPageInfo(t.page).pageContext.annotations.find(function(r){return r.type===e.type&&r.object===e.object})===void 0&&A.internal.getPageInfo(t.page).pageContext.annotations.push(e)},IQ=function(t,A){for(var e in t)if(t.hasOwnProperty(e)){var r=e,n=t[e];A.internal.newObjectDeferredBegin(n.objId,!0),Qe(n)==="object"&&typeof n.putStream=="function"&&n.putStream(),delete t[r]}},SQ=function(t,A){if(A.scope=t,t.internal!==void 0&&(t.internal.acroformPlugin===void 0||t.internal.acroformPlugin.isInitialized===!1)){if(Rr.FieldNum=0,t.internal.acroformPlugin=JSON.parse(JSON.stringify(EQ)),t.internal.acroformPlugin.acroFormDictionaryRoot)throw new Error("Exception while creating AcroformDictionary");Zf=t.internal.scaleFactor,t.internal.acroformPlugin.acroFormDictionaryRoot=new j1,t.internal.acroformPlugin.acroFormDictionaryRoot.scope=t,t.internal.acroformPlugin.acroFormDictionaryRoot._eventID=t.internal.events.subscribe("postPutResources",function(){(function(e){e.internal.events.unsubscribe(e.internal.acroformPlugin.acroFormDictionaryRoot._eventID),delete e.internal.acroformPlugin.acroFormDictionaryRoot._eventID,e.internal.acroformPlugin.printedOut=!0})(t)}),t.internal.events.subscribe("buildDocument",function(){(function(e){e.internal.acroformPlugin.acroFormDictionaryRoot.objId=void 0;var r=e.internal.acroformPlugin.acroFormDictionaryRoot.Fields;for(var n in r)if(r.hasOwnProperty(n)){var i=r[n];i.objId=void 0,i.hasAnnotation&&xQ(i,e)}})(t)}),t.internal.events.subscribe("putCatalog",function(){(function(e){if(e.internal.acroformPlugin.acroFormDictionaryRoot===void 0)throw new Error("putCatalogCallback: Root missing.");e.internal.write("/AcroForm "+e.internal.acroformPlugin.acroFormDictionaryRoot.objId+" 0 R")})(t)}),t.internal.events.subscribe("postPutPages",function(e){(function(r,n){var i=!r;for(var a in r||(n.internal.newObjectDeferredBegin(n.internal.acroformPlugin.acroFormDictionaryRoot.objId,!0),n.internal.acroformPlugin.acroFormDictionaryRoot.putStream()),r=r||n.internal.acroformPlugin.acroFormDictionaryRoot.Kids)if(r.hasOwnProperty(a)){var s=r[a],o=[],l=s.Rect;if(s.Rect&&(s.Rect=QQ(s.Rect,n)),n.internal.newObjectDeferredBegin(s.objId,!0),s.DA=$A.createDefaultAppearanceStream(s),Qe(s)==="object"&&typeof s.getKeyValueListForStream=="function"&&(o=s.getKeyValueListForStream()),s.Rect=l,s.hasAppearanceStream&&!s.appearanceStreamContent){var f=UQ(s);o.push({key:"AP",value:"<</N "+f+">>"}),n.internal.acroformPlugin.xForms.push(f)}if(s.appearanceStreamContent){var d="";for(var p in s.appearanceStreamContent)if(s.appearanceStreamContent.hasOwnProperty(p)){var h=s.appearanceStreamContent[p];if(d+="/"+p+" ",d+="<<",Object.keys(h).length>=1||Array.isArray(h)){for(var a in h)if(h.hasOwnProperty(a)){var m=h[a];typeof m=="function"&&(m=m.call(n,s)),d+="/"+a+" "+m+" ",n.internal.acroformPlugin.xForms.indexOf(m)>=0||n.internal.acroformPlugin.xForms.push(m)}}else typeof(m=h)=="function"&&(m=m.call(n,s)),d+="/"+a+" "+m,n.internal.acroformPlugin.xForms.indexOf(m)>=0||n.internal.acroformPlugin.xForms.push(m);d+=">>"}o.push({key:"AP",value:`<<
|
|||
|
|
`+d+">>"})}n.internal.putStream({additionalKeyValues:o,objectId:s.objId}),n.internal.out("endobj")}i&&IQ(n.internal.acroformPlugin.xForms,n)})(e,t)}),t.internal.acroformPlugin.isInitialized=!0}},K1=Ye.__acroform__.arrayToPdfArray=function(t,A,e){var r=function(a){return a};if(Array.isArray(t)){for(var n="[",i=0;i<t.length;i++)switch(i!==0&&(n+=" "),Qe(t[i])){case"boolean":case"number":case"object":n+=t[i].toString();break;case"string":t[i].substr(0,1)!=="/"?(A!==void 0&&e&&(r=e.internal.getEncryptor(A)),n+="("+Pi(r(t[i].toString()))+")"):n+=t[i].toString()}return n+="]"}throw new Error("Invalid argument passed to jsPDF.__acroform__.arrayToPdfArray")},eh=function(t,A,e){var r=function(n){return n};return A!==void 0&&e&&(r=e.internal.getEncryptor(A)),(t=t||"").toString(),t="("+Pi(r(t))+")"},hn=function(){this._objId=void 0,this._scope=void 0,Object.defineProperty(this,"objId",{get:function(){if(this._objId===void 0){if(this.scope===void 0)return;this._objId=this.scope.internal.newObjectDeferred()}return this._objId},set:function(t){this._objId=t}}),Object.defineProperty(this,"scope",{value:this._scope,writable:!0})};hn.prototype.toString=function(){return this.objId+" 0 R"},hn.prototype.putStream=function(){var t=this.getKeyValueListForStream();this.scope.internal.putStream({data:this.stream,additionalKeyValues:t,objectId:this.objId}),this.scope.internal.out("endobj")},hn.prototype.getKeyValueListForStream=function(){var t=[],A=Object.getOwnPropertyNames(this).filter(function(i){return i!="content"&&i!="appearanceStreamContent"&&i!="scope"&&i!="objId"&&i.substring(0,1)!="_"});for(var e in A)if(Object.getOwnPropertyDescriptor(this,A[e]).configurable===!1){var r=A[e],n=this[r];n&&(Array.isArray(n)?t.push({key:r,value:K1(n,this.objId,this.scope)}):n instanceof hn?(n.scope=this.scope,t.push({key:r,value:n.objId+" 0 R"})):typeof n!="function"&&t.push({key:r,value:n}))}return t};var V1=function(){hn.call(this),Object.defineProperty(this,"Type",{value:"/XObject",configurable:!1,writable:!0}),Object.defineProperty(this,"Subtype",{value:"/Form",configurable:!1,writable:!0}),Object.defineProperty(this,"FormType",{value:1,configurable:!1,writable:!0});var t,A=[];Object.defineProperty(this,"BBox",{configurable:!1,get:function(){return A},set:function(e){A=e}}),Object.defineProperty(this,"Resources",{value:"2 0 R",configurable:!1,writable:!0}),Object.defineProperty(this,"stream",{enumerable:!1,configurable:!0,set:function(e){t=e.trim()},get:function(){return t||null}})};ar(V1,hn);var j1=function(){hn.call(this);var t,A=[];Object.defineProperty(this,"Kids",{enumerable:!1,configurable:!0,get:function(){return A.length>0?A:void 0}}),Object.defineProperty(this,"Fields",{enumerable:!1,configurable:!1,get:function(){return A}}),Object.defineProperty(this,"DA",{enumerable:!1,configurable:!1,get:function(){if(t){var e=function(r){return r};return this.scope&&(e=this.scope.internal.getEncryptor(this.objId)),"("+Pi(e(t))+")"}},set:function(e){t=e}})};ar(j1,hn);var Rr=function t(){hn.call(this);var A=4;Object.defineProperty(this,"F",{enumerable:!1,configurable:!1,get:function(){return A},set:function(y){if(isNaN(y))throw new Error('Invalid value "'+y+'" for attribute F supplied.');A=y}}),Object.defineProperty(this,"showWhenPrinted",{enumerable:!0,configurable:!0,get:function(){return!!nt(A,3)},set:function(y){y?this.F=it(A,3):this.F=at(A,3)}});var e=0;Object.defineProperty(this,"Ff",{enumerable:!1,configurable:!1,get:function(){return e},set:function(y){if(isNaN(y))throw new Error('Invalid value "'+y+'" for attribute Ff supplied.');e=y}});var r=[];Object.defineProperty(this,"Rect",{enumerable:!1,configurable:!1,get:function(){if(r.length!==0)return r},set:function(y){r=y!==void 0?y:[]}}),Object.defineProperty(this,"x",{enumerable:!0,configurable:!0,get:function(){return!r||isNaN(r[0])?0:r[0]},set:function(y){r[0]=y}}),Object.defineProperty(this,"y",{enumerable:!0,configurable:!0,get:function(){return!r||isNaN(r[1])?0:r[1]},set:function(y){r[1]=y}}),Object.defineProperty(this,"width",{enumerable:!0,configurable:!0,get:function(){return!r||isNaN(r
|
|||
|
|
`)}},set:function(e){Qe(e)==="object"&&(A=e)}}),Object.defineProperty(this,"caption",{enumerable:!0,configurable:!0,get:function(){return A.CA||""},set:function(e){typeof e=="string"&&(A.CA=e)}}),Object.defineProperty(this,"AS",{enumerable:!1,configurable:!1,get:function(){return t},set:function(e){t=e}}),Object.defineProperty(this,"appearanceState",{enumerable:!0,configurable:!0,get:function(){return t.substr(1,t.length-1)},set:function(e){t="/"+e}})};ar(Ut,Rr);var ju=function(){Ut.call(this),this.pushButton=!0};ar(ju,Ut);var xa=function(){Ut.call(this),this.radio=!0,this.pushButton=!1;var t=[];Object.defineProperty(this,"Kids",{enumerable:!0,configurable:!1,get:function(){return t},set:function(A){t=A!==void 0?A:[]}})};ar(xa,Ut);var Gu=function(){var t,A;Rr.call(this),Object.defineProperty(this,"Parent",{enumerable:!1,configurable:!1,get:function(){return t},set:function(n){t=n}}),Object.defineProperty(this,"optionName",{enumerable:!1,configurable:!0,get:function(){return A},set:function(n){A=n}});var e,r={};Object.defineProperty(this,"MK",{enumerable:!1,configurable:!1,get:function(){var n=function(s){return s};this.scope&&(n=this.scope.internal.getEncryptor(this.objId));var i,a=[];for(i in a.push("<<"),r)a.push("/"+i+" ("+Pi(n(r[i]))+")");return a.push(">>"),a.join(`
|
|||
|
|
`)},set:function(n){Qe(n)==="object"&&(r=n)}}),Object.defineProperty(this,"caption",{enumerable:!0,configurable:!0,get:function(){return r.CA||""},set:function(n){typeof n=="string"&&(r.CA=n)}}),Object.defineProperty(this,"AS",{enumerable:!1,configurable:!1,get:function(){return e},set:function(n){e=n}}),Object.defineProperty(this,"appearanceState",{enumerable:!0,configurable:!0,get:function(){return e.substr(1,e.length-1)},set:function(n){e="/"+n}}),this.caption="l",this.appearanceState="Off",this._AppearanceType=$A.RadioButton.Circle,this.appearanceStreamContent=this._AppearanceType.createAppearanceStream(this.optionName)};ar(Gu,Rr),xa.prototype.setAppearance=function(t){if(!("createAppearanceStream"in t)||!("getCA"in t))throw new Error("Couldn't assign Appearance to RadioButton. Appearance was Invalid!");for(var A in this.Kids)if(this.Kids.hasOwnProperty(A)){var e=this.Kids[A];e.appearanceStreamContent=t.createAppearanceStream(e.optionName),e.caption=t.getCA()}},xa.prototype.createOption=function(t){var A=new Gu;return A.Parent=this,A.optionName=t,this.Kids.push(A),LQ.call(this.scope,A),A};var $u=function(){Ut.call(this),this.fontName="zapfdingbats",this.caption="3",this.appearanceState="On",this.value="On",this.textAlign="center",this.appearanceStreamContent=$A.CheckBox.createAppearanceStream()};ar($u,Ut);var Di=function(){Rr.call(this),this.FT="/Tx",Object.defineProperty(this,"multiline",{enumerable:!0,configurable:!0,get:function(){return!!nt(this.Ff,13)},set:function(A){A?this.Ff=it(this.Ff,13):this.Ff=at(this.Ff,13)}}),Object.defineProperty(this,"fileSelect",{enumerable:!0,configurable:!0,get:function(){return!!nt(this.Ff,21)},set:function(A){A?this.Ff=it(this.Ff,21):this.Ff=at(this.Ff,21)}}),Object.defineProperty(this,"doNotSpellCheck",{enumerable:!0,configurable:!0,get:function(){return!!nt(this.Ff,23)},set:function(A){A?this.Ff=it(this.Ff,23):this.Ff=at(this.Ff,23)}}),Object.defineProperty(this,"doNotScroll",{enumerable:!0,configurable:!0,get:function(){return!!nt(this.Ff,24)},set:function(A){A?this.Ff=it(this.Ff,24):this.Ff=at(this.Ff,24)}}),Object.defineProperty(this,"comb",{enumerable:!0,configurable:!0,get:function(){return!!nt(this.Ff,25)},set:function(A){A?this.Ff=it(this.Ff,25):this.Ff=at(this.Ff,25)}}),Object.defineProperty(this,"richText",{enumerable:!0,configurable:!0,get:function(){return!!nt(this.Ff,26)},set:function(A){A?this.Ff=it(this.Ff,26):this.Ff=at(this.Ff,26)}});var t=null;Object.defineProperty(this,"MaxLen",{enumerable:!0,configurable:!1,get:function(){return t},set:function(A){t=A}}),Object.defineProperty(this,"maxLength",{enumerable:!0,configurable:!0,get:function(){return t},set:function(A){Number.isInteger(A)&&(t=A)}}),Object.defineProperty(this,"hasAppearanceStream",{enumerable:!0,configurable:!0,get:function(){return this.V||this.DV}})};ar(Di,Rr);var qu=function(){Di.call(this),Object.defineProperty(this,"password",{enumerable:!0,configurable:!0,get:function(){return!!nt(this.Ff,14)},set:function(t){t?this.Ff=it(this.Ff,14):this.Ff=at(this.Ff,14)}}),this.password=!0};ar(qu,Di);var $A={CheckBox:{createAppearanceStream:function(){return{N:{On:$A.CheckBox.YesNormal},D:{On:$A.CheckBox.YesPushDown,Off:$A.CheckBox.OffPushDown}}},YesPushDown:function(t){var A=fn(t);A.scope=t.scope;var e=[],r=t.scope.internal.getFont(t.fontName,t.fontStyle).id,n=t.scope.__private__.encodeColorString(t.color),i=Ah(t,t.caption);return e.push("0.749023 g"),e.push("0 0 "+se($A.internal.getWidth(t))+" "+se($A.internal.getHeight(t))+" re"),e.push("f"),e.push("BMC"),e.push("q"),e.push("0 0 1 rg"),e.push("/"+r+" "+se(i.fontSize)+" Tf "+n),e.push("BT"),e.push(i.text),e.push("ET"),e.push("Q"),e.push("EMC"),A.stream=e.join(`
|
|||
|
|
`),A},YesNormal:function(t){var A=fn(t);A.scope=t.scope;var e=t.scope.internal.getFont(t.fontName,t.fontStyle).id,r=t.scope.__private__.encodeColorString(t.color),n=[],i=$A.internal.getHeight(t),a=$A.internal.getWidth(t),s=Ah(t,t.caption);return n.push("1 g"),n.push("0 0 "+se(a)+" "+se(i)+" re"),n.push("f"),n.push("q"),n.push("0 0 1 rg"),n.push("0 0 "+se(a-1)+" "+se(i-1)+" re"),n.push("W"),n.push("n"),n.push("0 g"),n.push("BT"),n.push("/"+e+" "+se(s.fontSize)+" Tf "+r),n.push(s.text),n.push("ET"),n.push("Q"),A.stream=n.join(`
|
|||
|
|
`),A},OffPushDown:function(t){var A=fn(t);A.scope=t.scope;var e=[];return e.push("0.749023 g"),e.push("0 0 "+se($A.internal.getWidth(t))+" "+se($A.internal.getHeight(t))+" re"),e.push("f"),A.stream=e.join(`
|
|||
|
|
`),A}},RadioButton:{Circle:{createAppearanceStream:function(t){var A={D:{Off:$A.RadioButton.Circle.OffPushDown},N:{}};return A.N[t]=$A.RadioButton.Circle.YesNormal,A.D[t]=$A.RadioButton.Circle.YesPushDown,A},getCA:function(){return"l"},YesNormal:function(t){var A=fn(t);A.scope=t.scope;var e=[],r=$A.internal.getWidth(t)<=$A.internal.getHeight(t)?$A.internal.getWidth(t)/4:$A.internal.getHeight(t)/4;r=Number((.9*r).toFixed(5));var n=$A.internal.Bezier_C,i=Number((r*n).toFixed(5));return e.push("q"),e.push("1 0 0 1 "+ii($A.internal.getWidth(t)/2)+" "+ii($A.internal.getHeight(t)/2)+" cm"),e.push(r+" 0 m"),e.push(r+" "+i+" "+i+" "+r+" 0 "+r+" c"),e.push("-"+i+" "+r+" -"+r+" "+i+" -"+r+" 0 c"),e.push("-"+r+" -"+i+" -"+i+" -"+r+" 0 -"+r+" c"),e.push(i+" -"+r+" "+r+" -"+i+" "+r+" 0 c"),e.push("f"),e.push("Q"),A.stream=e.join(`
|
|||
|
|
`),A},YesPushDown:function(t){var A=fn(t);A.scope=t.scope;var e=[],r=$A.internal.getWidth(t)<=$A.internal.getHeight(t)?$A.internal.getWidth(t)/4:$A.internal.getHeight(t)/4;r=Number((.9*r).toFixed(5));var n=Number((2*r).toFixed(5)),i=Number((n*$A.internal.Bezier_C).toFixed(5)),a=Number((r*$A.internal.Bezier_C).toFixed(5));return e.push("0.749023 g"),e.push("q"),e.push("1 0 0 1 "+ii($A.internal.getWidth(t)/2)+" "+ii($A.internal.getHeight(t)/2)+" cm"),e.push(n+" 0 m"),e.push(n+" "+i+" "+i+" "+n+" 0 "+n+" c"),e.push("-"+i+" "+n+" -"+n+" "+i+" -"+n+" 0 c"),e.push("-"+n+" -"+i+" -"+i+" -"+n+" 0 -"+n+" c"),e.push(i+" -"+n+" "+n+" -"+i+" "+n+" 0 c"),e.push("f"),e.push("Q"),e.push("0 g"),e.push("q"),e.push("1 0 0 1 "+ii($A.internal.getWidth(t)/2)+" "+ii($A.internal.getHeight(t)/2)+" cm"),e.push(r+" 0 m"),e.push(r+" "+a+" "+a+" "+r+" 0 "+r+" c"),e.push("-"+a+" "+r+" -"+r+" "+a+" -"+r+" 0 c"),e.push("-"+r+" -"+a+" -"+a+" -"+r+" 0 -"+r+" c"),e.push(a+" -"+r+" "+r+" -"+a+" "+r+" 0 c"),e.push("f"),e.push("Q"),A.stream=e.join(`
|
|||
|
|
`),A},OffPushDown:function(t){var A=fn(t);A.scope=t.scope;var e=[],r=$A.internal.getWidth(t)<=$A.internal.getHeight(t)?$A.internal.getWidth(t)/4:$A.internal.getHeight(t)/4;r=Number((.9*r).toFixed(5));var n=Number((2*r).toFixed(5)),i=Number((n*$A.internal.Bezier_C).toFixed(5));return e.push("0.749023 g"),e.push("q"),e.push("1 0 0 1 "+ii($A.internal.getWidth(t)/2)+" "+ii($A.internal.getHeight(t)/2)+" cm"),e.push(n+" 0 m"),e.push(n+" "+i+" "+i+" "+n+" 0 "+n+" c"),e.push("-"+i+" "+n+" -"+n+" "+i+" -"+n+" 0 c"),e.push("-"+n+" -"+i+" -"+i+" -"+n+" 0 -"+n+" c"),e.push(i+" -"+n+" "+n+" -"+i+" "+n+" 0 c"),e.push("f"),e.push("Q"),A.stream=e.join(`
|
|||
|
|
`),A}},Cross:{createAppearanceStream:function(t){var A={D:{Off:$A.RadioButton.Cross.OffPushDown},N:{}};return A.N[t]=$A.RadioButton.Cross.YesNormal,A.D[t]=$A.RadioButton.Cross.YesPushDown,A},getCA:function(){return"8"},YesNormal:function(t){var A=fn(t);A.scope=t.scope;var e=[],r=$A.internal.calculateCross(t);return e.push("q"),e.push("1 1 "+se($A.internal.getWidth(t)-2)+" "+se($A.internal.getHeight(t)-2)+" re"),e.push("W"),e.push("n"),e.push(se(r.x1.x)+" "+se(r.x1.y)+" m"),e.push(se(r.x2.x)+" "+se(r.x2.y)+" l"),e.push(se(r.x4.x)+" "+se(r.x4.y)+" m"),e.push(se(r.x3.x)+" "+se(r.x3.y)+" l"),e.push("s"),e.push("Q"),A.stream=e.join(`
|
|||
|
|
`),A},YesPushDown:function(t){var A=fn(t);A.scope=t.scope;var e=$A.internal.calculateCross(t),r=[];return r.push("0.749023 g"),r.push("0 0 "+se($A.internal.getWidth(t))+" "+se($A.internal.getHeight(t))+" re"),r.push("f"),r.push("q"),r.push("1 1 "+se($A.internal.getWidth(t)-2)+" "+se($A.internal.getHeight(t)-2)+" re"),r.push("W"),r.push("n"),r.push(se(e.x1.x)+" "+se(e.x1.y)+" m"),r.push(se(e.x2.x)+" "+se(e.x2.y)+" l"),r.push(se(e.x4.x)+" "+se(e.x4.y)+" m"),r.push(se(e.x3.x)+" "+se(e.x3.y)+" l"),r.push("s"),r.push("Q"),A.stream=r.join(`
|
|||
|
|
`),A},OffPushDown:function(t){var A=fn(t);A.scope=t.scope;var e=[];return e.push("0.749023 g"),e.push("0 0 "+se($A.internal.getWidth(t))+" "+se($A.internal.getHeight(t))+" re"),e.push("f"),A.stream=e.join(`
|
|||
|
|
`),A}}},createDefaultAppearanceStream:function(t){var A=t.scope.internal.getFont(t.fontName,t.fontStyle).id,e=t.scope.__private__.encodeColorString(t.color);return"/"+A+" "+t.fontSize+" Tf "+e}};$A.internal={Bezier_C:.551915024494,calculateCross:function(t){var A=$A.internal.getWidth(t),e=$A.internal.getHeight(t),r=Math.min(A,e);return{x1:{x:(A-r)/2,y:(e-r)/2+r},x2:{x:(A-r)/2+r,y:(e-r)/2},x3:{x:(A-r)/2,y:(e-r)/2},x4:{x:(A-r)/2+r,y:(e-r)/2+r}}}},$A.internal.getWidth=function(t){var A=0;return Qe(t)==="object"&&(A=k1(t.Rect[2])),A},$A.internal.getHeight=function(t){var A=0;return Qe(t)==="object"&&(A=k1(t.Rect[3])),A};var LQ=Ye.addField=function(t){if(SQ(this,t),!(t instanceof Rr))throw new Error("Invalid argument passed to jsPDF.addField.");var A;return(A=t).scope.internal.acroformPlugin.printedOut&&(A.scope.internal.acroformPlugin.printedOut=!1,A.scope.internal.acroformPlugin.acroFormDictionaryRoot=null),A.scope.internal.acroformPlugin.acroFormDictionaryRoot.Fields.push(A),t.page=t.scope.internal.getCurrentPageInfo().pageNumber,this};Ye.AcroFormChoiceField=Qa,Ye.AcroFormListBox=Ua,Ye.AcroFormComboBox=Ea,Ye.AcroFormEditBox=Vu,Ye.AcroFormButton=Ut,Ye.AcroFormPushButton=ju,Ye.AcroFormRadioButton=xa,Ye.AcroFormCheckBox=$u,Ye.AcroFormTextField=Di,Ye.AcroFormPasswordField=qu,Ye.AcroFormAppearance=$A,Ye.AcroForm={ChoiceField:Qa,ListBox:Ua,ComboBox:Ea,EditBox:Vu,Button:Ut,PushButton:ju,RadioButton:xa,CheckBox:$u,TextField:Di,PasswordField:qu,Appearance:$A},te.AcroForm={ChoiceField:Qa,ListBox:Ua,ComboBox:Ea,EditBox:Vu,Button:Ut,PushButton:ju,RadioButton:xa,CheckBox:$u,TextField:Di,PasswordField:qu,Appearance:$A};function G1(t){return t.reduce(function(A,e,r){return A[e]=r,A},{})}(function(t){t.__addimage__={};var A="UNKNOWN",e={PNG:[[137,80,78,71]],TIFF:[[77,77,0,42],[73,73,42,0]],JPEG:[[255,216,255,224,void 0,void 0,74,70,73,70,0],[255,216,255,225,void 0,void 0,69,120,105,102,0,0],[255,216,255,219],[255,216,255,238]],JPEG2000:[[0,0,0,12,106,80,32,32]],GIF87a:[[71,73,70,56,55,97]],GIF89a:[[71,73,70,56,57,97]],WEBP:[[82,73,70,70,void 0,void 0,void 0,void 0,87,69,66,80]],BMP:[[66,77],[66,65],[67,73],[67,80],[73,67],[80,84]]},r=t.__addimage__.getImageFileTypeByImageData=function(N,S){var M,R,iA,tA,lA,eA=A;if((S=S||A)==="RGBA"||N.data!==void 0&&N.data instanceof Uint8ClampedArray&&"height"in N&&"width"in N)return"RGBA";if(j(N))for(lA in e)for(iA=e[lA],M=0;M<iA.length;M+=1){for(tA=!0,R=0;R<iA[M].length;R+=1)if(iA[M][R]!==void 0&&iA[M][R]!==N[R]){tA=!1;break}if(tA===!0){eA=lA;break}}else for(lA in e)for(iA=e[lA],M=0;M<iA.length;M+=1){for(tA=!0,R=0;R<iA[M].length;R+=1)if(iA[M][R]!==void 0&&iA[M][R]!==N.charCodeAt(R)){tA=!1;break}if(tA===!0){eA=lA;break}}return eA===A&&S!==A&&(eA=S),eA},n=function N(S){for(var M=this.internal.write,R=this.internal.putStream,iA=(0,this.internal.getFilters)();iA.indexOf("FlateEncode")!==-1;)iA.splice(iA.indexOf("FlateEncode"),1);S.objectId=this.internal.newObject();var tA=[];if(tA.push({key:"Type",value:"/XObject"}),tA.push({key:"Subtype",value:"/Image"}),tA.push({key:"Width",value:S.width}),tA.push({key:"Height",value:S.height}),S.colorSpace===b.INDEXED?tA.push({key:"ColorSpace",value:"[/Indexed /DeviceRGB "+(S.palette.length/3-1)+" "+("sMask"in S&&S.sMask!==void 0?S.objectId+2:S.objectId+1)+" 0 R]"}):(tA.push({key:"ColorSpace",value:"/"+S.colorSpace}),S.colorSpace===b.DEVICE_CMYK&&tA.push({key:"Decode",value:"[1 0 1 0 1 0 1 0]"})),tA.push({key:"BitsPerComponent",value:S.bitsPerComponent}),"decodeParameters"in S&&S.decodeParameters!==void 0&&tA.push({key:"DecodeParms",value:"<<"+S.decodeParameters+">>"}),"transparency"in S&&Array.isArray(S.transparency)){for(var lA="",eA=0,cA=S.transparency.length;eA<cA;eA++)lA+=S.transparency[eA]+" "+S.transparency[eA]+" ";tA.push({key:"Mask",value:"["+lA+"]"})}S.sMask!==void 0&&tA.push({key:"SMask",value:S.objectId+1+" 0 R"});var sA=S.filter!==void 0?["/"+S.filter]:void 0;if(R({data:S.data,additionalKeyValues:tA,alreadyAppliedFilters:sA,objectId:S.objectId}),M("endobj"),"sMask"in S&&S.sMask!==void 0){var bA="/Predictor "+S.predictor+" /Colors 1 /BitsPerComponent "+S.bi
|
|||
|
|
`},e.outline.makeRef=function(r){return r.id+" 0 R"},e.outline.makeString=function(r){return"("+e.internal.pdfEscape(r)+")"},e.outline.objStart=function(r){this.ctx.val+=`\r
|
|||
|
|
`+r.id+` 0 obj\r
|
|||
|
|
<<\r
|
|||
|
|
`},e.outline.objEnd=function(){this.ctx.val+=`>> \r
|
|||
|
|
endobj\r
|
|||
|
|
`},e.outline.count_r=function(r,n){for(var i=0;i<n.children.length;i++)r.count++,this.count_r(r,n.children[i]);return r.count}}])}(te.API),function(t){var A=[192,193,194,195,196,197,198,199];t.processJPEG=function(e,r,n,i,a,s){var o,l=this.decode.DCT_DECODE,f=null;if(typeof e=="string"||this.__addimage__.isArrayBuffer(e)||this.__addimage__.isArrayBufferView(e)){switch(e=a||e,e=this.__addimage__.isArrayBuffer(e)?new Uint8Array(e):e,(o=function(d){for(var p,h=256*d.charCodeAt(4)+d.charCodeAt(5),m=d.length,w={width:0,height:0,numcomponents:1},b=4;b<m;b+=2){if(b+=h,A.indexOf(d.charCodeAt(b+1))!==-1){p=256*d.charCodeAt(b+5)+d.charCodeAt(b+6),w={width:256*d.charCodeAt(b+7)+d.charCodeAt(b+8),height:p,numcomponents:d.charCodeAt(b+9)};break}h=256*d.charCodeAt(b+2)+d.charCodeAt(b+3)}return w}(e=this.__addimage__.isArrayBufferView(e)?this.__addimage__.arrayBufferToBinaryString(e):e)).numcomponents){case 1:s=this.color_spaces.DEVICE_GRAY;break;case 4:s=this.color_spaces.DEVICE_CMYK;break;case 3:s=this.color_spaces.DEVICE_RGB}f={data:e,width:o.width,height:o.height,colorSpace:s,bitsPerComponent:8,filter:l,index:r,alias:n}}return f}}(te.API);var Ia,zu,e2,t2,r2,PQ=function(){var t,A,e;function r(i){var a,s,o,l,f,d,p,h,m,w,b,y,U,T;for(this.data=i,this.pos=8,this.palette=[],this.imgData=[],this.transparency={},this.animation=null,this.text={},d=null;;){switch(a=this.readUInt32(),m=function(){var k,G;for(G=[],k=0;k<4;++k)G.push(String.fromCharCode(this.data[this.pos++]));return G}.call(this).join("")){case"IHDR":this.width=this.readUInt32(),this.height=this.readUInt32(),this.bits=this.data[this.pos++],this.colorType=this.data[this.pos++],this.compressionMethod=this.data[this.pos++],this.filterMethod=this.data[this.pos++],this.interlaceMethod=this.data[this.pos++];break;case"acTL":this.animation={numFrames:this.readUInt32(),numPlays:this.readUInt32()||1/0,frames:[]};break;case"PLTE":this.palette=this.read(a);break;case"fcTL":d&&this.animation.frames.push(d),this.pos+=4,d={width:this.readUInt32(),height:this.readUInt32(),xOffset:this.readUInt32(),yOffset:this.readUInt32()},f=this.readUInt16(),l=this.readUInt16()||100,d.delay=1e3*f/l,d.disposeOp=this.data[this.pos++],d.blendOp=this.data[this.pos++],d.data=[];break;case"IDAT":case"fdAT":for(m==="fdAT"&&(this.pos+=4,a-=4),i=d?.data||this.imgData,y=0;0<=a?y<a:y>a;0<=a?++y:--y)i.push(this.data[this.pos++]);break;case"tRNS":switch(this.transparency={},this.colorType){case 3:if(o=this.palette.length/3,this.transparency.indexed=this.read(a),this.transparency.indexed.length>o)throw new Error("More transparent colors than palette size");if((w=o-this.transparency.indexed.length)>0)for(U=0;0<=w?U<w:U>w;0<=w?++U:--U)this.transparency.indexed.push(255);break;case 0:this.transparency.grayscale=this.read(a)[0];break;case 2:this.transparency.rgb=this.read(a)}break;case"tEXt":p=(b=this.read(a)).indexOf(0),h=String.fromCharCode.apply(String,b.slice(0,p)),this.text[h]=String.fromCharCode.apply(String,b.slice(p+1));break;case"IEND":return d&&this.animation.frames.push(d),this.colors=function(){switch(this.colorType){case 0:case 3:case 4:return 1;case 2:case 6:return 3}}.call(this),this.hasAlphaChannel=(T=this.colorType)===4||T===6,s=this.colors+(this.hasAlphaChannel?1:0),this.pixelBitlength=this.bits*s,this.colorSpace=function(){switch(this.colors){case 1:return"DeviceGray";case 3:return"DeviceRGB"}}.call(this),void(this.imgData=new Uint8Array(this.imgData));default:this.pos+=a}if(this.pos+=4,this.pos>this.data.length)throw new Error("Incomplete or corrupt PNG file")}}r.prototype.read=function(i){var a,s;for(s=[],a=0;0<=i?a<i:a>i;0<=i?++a:--a)s.push(this.data[this.pos++]);return s},r.prototype.readUInt32=function(){return this.data[this.pos++]<<24|this.data[this.pos++]<<16|this.data[this.pos++]<<8|this.data[this.pos++]},r.prototype.readUInt16=function(){return this.data[this.pos++]<<8|this.data[this.pos++]},r.prototype.decodePixels=function(i){var a=this.pixelBitlength/8,s=new Uint8Array(this.width*this.height*a),o=0,l=this;if(i==null&&(i=this.imgData),i.length===0)return new Uint8Array(0);function f(d,p,h,m){
|
|||
|
|
* @license
|
|||
|
|
*
|
|||
|
|
* Copyright (c) 2014 James Robb, https://github.com/jamesbrobb
|
|||
|
|
*
|
|||
|
|
* Permission is hereby granted, free of charge, to any person obtaining
|
|||
|
|
* a copy of this software and associated documentation files (the
|
|||
|
|
* "Software"), to deal in the Software without restriction, including
|
|||
|
|
* without limitation the rights to use, copy, modify, merge, publish,
|
|||
|
|
* distribute, sublicense, and/or sell copies of the Software, and to
|
|||
|
|
* permit persons to whom the Software is furnished to do so, subject to
|
|||
|
|
* the following conditions:
|
|||
|
|
*
|
|||
|
|
* The above copyright notice and this permission notice shall be
|
|||
|
|
* included in all copies or substantial portions of the Software.
|
|||
|
|
*
|
|||
|
|
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
|||
|
|
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
|||
|
|
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|||
|
|
* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
|||
|
|
* LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
|||
|
|
* OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
|||
|
|
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|||
|
|
* ====================================================================
|
|||
|
|
*//**
|
|||
|
|
* @license
|
|||
|
|
* (c) Dean McNamee <dean@gmail.com>, 2013.
|
|||
|
|
*
|
|||
|
|
* https://github.com/deanm/omggif
|
|||
|
|
*
|
|||
|
|
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
|||
|
|
* of this software and associated documentation files (the "Software"), to
|
|||
|
|
* deal in the Software without restriction, including without limitation the
|
|||
|
|
* rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
|
|||
|
|
* sell copies of the Software, and to permit persons to whom the Software is
|
|||
|
|
* furnished to do so, subject to the following conditions:
|
|||
|
|
*
|
|||
|
|
* The above copyright notice and this permission notice shall be included in
|
|||
|
|
* all copies or substantial portions of the Software.
|
|||
|
|
*
|
|||
|
|
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|||
|
|
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|||
|
|
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|||
|
|
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|||
|
|
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|||
|
|
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
|
|||
|
|
* IN THE SOFTWARE.
|
|||
|
|
*
|
|||
|
|
* omggif is a JavaScript implementation of a GIF 89a encoder and decoder,
|
|||
|
|
* including animation and compression. It does not rely on any specific
|
|||
|
|
* underlying system, so should run in the browser, Node, or Plask.
|
|||
|
|
*/function DQ(t){var A=0;if(t[A++]!==71||t[A++]!==73||t[A++]!==70||t[A++]!==56||(t[A++]+1&253)!=56||t[A++]!==97)throw new Error("Invalid GIF 87a/89a header.");var e=t[A++]|t[A++]<<8,r=t[A++]|t[A++]<<8,n=t[A++],i=n>>7,a=1<<(7&n)+1;t[A++],t[A++];var s=null,o=null;i&&(s=A,o=a,A+=3*a);var l=!0,f=[],d=0,p=null,h=0,m=null;for(this.width=e,this.height=r;l&&A<t.length;)switch(t[A++]){case 33:switch(t[A++]){case 255:if(t[A]!==11||t[A+1]==78&&t[A+2]==69&&t[A+3]==84&&t[A+4]==83&&t[A+5]==67&&t[A+6]==65&&t[A+7]==80&&t[A+8]==69&&t[A+9]==50&&t[A+10]==46&&t[A+11]==48&&t[A+12]==3&&t[A+13]==1&&t[A+16]==0)A+=14,m=t[A++]|t[A++]<<8,A++;else for(A+=12;;){if(!((N=t[A++])>=0))throw Error("Invalid block size");if(N===0)break;A+=N}break;case 249:if(t[A++]!==4||t[A+4]!==0)throw new Error("Invalid graphics extension block.");var w=t[A++];d=t[A++]|t[A++]<<8,p=t[A++],!(1&w)&&(p=null),h=w>>2&7,A++;break;case 254:for(;;){if(!((N=t[A++])>=0))throw Error("Invalid block size");if(N===0)break;A+=N}break;default:throw new Error("Unknown graphic control label: 0x"+t[A-1].toString(16))}break;case 44:var b=t[A++]|t[A++]<<8,y=t[A++]|t[A++]<<8,U=t[A++]|t[A++]<<8,T=t[A++]|t[A++]<<8,k=t[A++],G=k>>6&1,j=1<<(7&k)+1,K=s,O=o,Z=!1;k>>7&&(Z=!0,K=A,O=j,A+=3*j);var aA=A;for(A++;;){var N;if(!((N=t[A++])>=0))throw Error("Invalid block size");if(N===0)break;A+=N}f.push({x:b,y,width:U,height:T,has_local_palette:Z,palette_offset:K,palette_size:O,data_offset:aA,data_length:A-aA,transparent_index:p,interlaced:!!G,delay:d,disposal:h});break;case 59:l=!1;break;default:throw new Error("Unknown gif block: 0x"+t[A-1].toString(16))}this.numFrames=function(){return f.length},this.loopCount=function(){return m},this.frameInfo=function(S){if(S<0||S>=f.length)throw new Error("Frame index out of range.");return f[S]},this.decodeAndBlitFrameBGRA=function(S,M){var R=this.frameInfo(S),iA=R.width*R.height,tA=new Uint8Array(iA);n2(t,R.data_offset,tA,iA);var lA=R.palette_offset,eA=R.transparent_index;eA===null&&(eA=256);var cA=R.width,sA=e-cA,bA=cA,Q=4*(R.y*e+R.x),_=4*((R.y+R.height)*e+R.x),P=Q,$=4*sA;R.interlaced===!0&&($+=4*e*7);for(var W=8,nA=0,fA=tA.length;nA<fA;++nA){var hA=tA[nA];if(bA===0&&(bA=cA,(P+=$)>=_&&($=4*sA+4*e*(W-1),P=Q+(cA+sA)*(W<<1),W>>=1)),hA===eA)P+=4;else{var xA=t[lA+3*hA],EA=t[lA+3*hA+1],_A=t[lA+3*hA+2];M[P++]=_A,M[P++]=EA,M[P++]=xA,M[P++]=255}--bA}},this.decodeAndBlitFrameRGBA=function(S,M){var R=this.frameInfo(S),iA=R.width*R.height,tA=new Uint8Array(iA);n2(t,R.data_offset,tA,iA);var lA=R.palette_offset,eA=R.transparent_index;eA===null&&(eA=256);var cA=R.width,sA=e-cA,bA=cA,Q=4*(R.y*e+R.x),_=4*((R.y+R.height)*e+R.x),P=Q,$=4*sA;R.interlaced===!0&&($+=4*e*7);for(var W=8,nA=0,fA=tA.length;nA<fA;++nA){var hA=tA[nA];if(bA===0&&(bA=cA,(P+=$)>=_&&($=4*sA+4*e*(W-1),P=Q+(cA+sA)*(W<<1),W>>=1)),hA===eA)P+=4;else{var xA=t[lA+3*hA],EA=t[lA+3*hA+1],_A=t[lA+3*hA+2];M[P++]=xA,M[P++]=EA,M[P++]=_A,M[P++]=255}--bA}}}function n2(t,A,e,r){for(var n=t[A++],i=1<<n,a=i+1,s=a+1,o=n+1,l=(1<<o)-1,f=0,d=0,p=0,h=t[A++],m=new Int32Array(4096),w=null;;){for(;f<16&&h!==0;)d|=t[A++]<<f,f+=8,h===1?h=t[A++]:--h;if(f<o)break;var b=d&l;if(d>>=o,f-=o,b!==i){if(b===a)break;for(var y=b<s?b:w,U=0,T=y;T>i;)T=m[T]>>8,++U;var k=T;if(p+U+(y!==b?1:0)>r)return void _e.log("Warning, gif stream longer than expected.");e[p++]=k;var G=p+=U;for(y!==b&&(e[p++]=k),T=y;U--;)T=m[T],e[--G]=255&T,T>>=8;w!==null&&s<4096&&(m[s++]=w<<8|k,s>=l+1&&o<12&&(++o,l=l<<1|1)),w=b}else s=a+1,l=(1<<(o=n+1))-1,w=null}return p!==r&&_e.log("Warning, gif stream shorter than expected."),e}/**
|
|||
|
|
* @license
|
|||
|
|
Copyright (c) 2008, Adobe Systems Incorporated
|
|||
|
|
All rights reserved.
|
|||
|
|
|
|||
|
|
Redistribution and use in source and binary forms, with or without
|
|||
|
|
modification, are permitted provided that the following conditions are
|
|||
|
|
met:
|
|||
|
|
|
|||
|
|
* Redistributions of source code must retain the above copyright notice,
|
|||
|
|
this list of conditions and the following disclaimer.
|
|||
|
|
|
|||
|
|
* Redistributions in binary form must reproduce the above copyright
|
|||
|
|
notice, this list of conditions and the following disclaimer in the
|
|||
|
|
documentation and/or other materials provided with the distribution.
|
|||
|
|
|
|||
|
|
* Neither the name of Adobe Systems Incorporated nor the names of its
|
|||
|
|
contributors may be used to endorse or promote products derived from
|
|||
|
|
this software without specific prior written permission.
|
|||
|
|
|
|||
|
|
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
|
|||
|
|
IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
|
|||
|
|
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
|||
|
|
PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
|
|||
|
|
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
|
|||
|
|
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
|||
|
|
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
|
|||
|
|
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
|
|||
|
|
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
|||
|
|
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
|||
|
|
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|||
|
|
*/function ih(t){var A,e,r,n,i,a=Math.floor,s=new Array(64),o=new Array(64),l=new Array(64),f=new Array(64),d=new Array(65535),p=new Array(65535),h=new Array(64),m=new Array(64),w=[],b=0,y=7,U=new Array(64),T=new Array(64),k=new Array(64),G=new Array(256),j=new Array(2048),K=[0,1,5,6,14,15,27,28,2,4,7,13,16,26,29,42,3,8,12,17,25,30,41,43,9,11,18,24,31,40,44,53,10,19,23,32,39,45,52,54,20,22,33,38,46,51,55,60,21,34,37,47,50,56,59,61,35,36,48,49,57,58,62,63],O=[0,0,1,5,1,1,1,1,1,1,0,0,0,0,0,0,0],Z=[0,1,2,3,4,5,6,7,8,9,10,11],aA=[0,0,2,1,3,3,2,4,3,5,5,4,4,0,0,1,125],N=[1,2,3,0,4,17,5,18,33,49,65,6,19,81,97,7,34,113,20,50,129,145,161,8,35,66,177,193,21,82,209,240,36,51,98,114,130,9,10,22,23,24,25,26,37,38,39,40,41,42,52,53,54,55,56,57,58,67,68,69,70,71,72,73,74,83,84,85,86,87,88,89,90,99,100,101,102,103,104,105,106,115,116,117,118,119,120,121,122,131,132,133,134,135,136,137,138,146,147,148,149,150,151,152,153,154,162,163,164,165,166,167,168,169,170,178,179,180,181,182,183,184,185,186,194,195,196,197,198,199,200,201,202,210,211,212,213,214,215,216,217,218,225,226,227,228,229,230,231,232,233,234,241,242,243,244,245,246,247,248,249,250],S=[0,0,3,1,1,1,1,1,1,1,1,1,0,0,0,0,0],M=[0,1,2,3,4,5,6,7,8,9,10,11],R=[0,0,2,1,2,4,4,3,4,7,5,4,4,0,1,2,119],iA=[0,1,2,3,17,4,5,33,49,6,18,65,81,7,97,113,19,34,50,129,8,20,66,145,161,177,193,9,35,51,82,240,21,98,114,209,10,22,36,52,225,37,241,23,24,25,26,38,39,40,41,42,53,54,55,56,57,58,67,68,69,70,71,72,73,74,83,84,85,86,87,88,89,90,99,100,101,102,103,104,105,106,115,116,117,118,119,120,121,122,130,131,132,133,134,135,136,137,138,146,147,148,149,150,151,152,153,154,162,163,164,165,166,167,168,169,170,178,179,180,181,182,183,184,185,186,194,195,196,197,198,199,200,201,202,210,211,212,213,214,215,216,217,218,226,227,228,229,230,231,232,233,234,242,243,244,245,246,247,248,249,250];function tA(Q,_){for(var P=0,$=0,W=new Array,nA=1;nA<=16;nA++){for(var fA=1;fA<=Q[nA];fA++)W[_[$]]=[],W[_[$]][0]=P,W[_[$]][1]=nA,$++,P++;P*=2}return W}function lA(Q){for(var _=Q[0],P=Q[1]-1;P>=0;)_&1<<P&&(b|=1<<y),P--,--y<0&&(b==255?(eA(255),eA(0)):eA(b),y=7,b=0)}function eA(Q){w.push(Q)}function cA(Q){eA(Q>>8&255),eA(255&Q)}function sA(Q,_,P,$,W){for(var nA,fA=W[0],hA=W[240],xA=function(FA,IA){var LA,SA,VA,GA,ZA,re,he,ye,zA,ne,TA=0;for(zA=0;zA<8;++zA){LA=FA[TA],SA=FA[TA+1],VA=FA[TA+2],GA=FA[TA+3],ZA=FA[TA+4],re=FA[TA+5],he=FA[TA+6];var Re=LA+(ye=FA[TA+7]),ge=LA-ye,Ge=SA+he,pe=SA-he,Ue=VA+re,It=VA-re,we=GA+ZA,pt=GA-ZA,Se=Re+we,_t=Re-we,ue=Ge+Ue,Le=Ge-Ue;FA[TA]=Se+ue,FA[TA+4]=Se-ue;var ie=.707106781*(Le+_t);FA[TA+2]=_t+ie,FA[TA+6]=_t-ie;var be=.382683433*((Se=pt+It)-(Le=pe+ge)),Xr=.5411961*Se+be,vt=1.306562965*Le+be,vr=.707106781*(ue=It+pe),Ir=ge+vr,XA=ge-vr;FA[TA+5]=XA+Xr,FA[TA+3]=XA-Xr,FA[TA+1]=Ir+vt,FA[TA+7]=Ir-vt,TA+=8}for(TA=0,zA=0;zA<8;++zA){LA=FA[TA],SA=FA[TA+8],VA=FA[TA+16],GA=FA[TA+24],ZA=FA[TA+32],re=FA[TA+40],he=FA[TA+48];var er=LA+(ye=FA[TA+56]),Sr=LA-ye,$e=SA+he,qe=SA-he,We=VA+re,$t=VA-re,fi=GA+ZA,tr=GA-ZA,ut=er+fi,or=er-fi,ur=$e+We,Br=$e-We;FA[TA]=ut+ur,FA[TA+32]=ut-ur;var rr=.707106781*(Br+or);FA[TA+16]=or+rr,FA[TA+48]=or-rr;var Lr=.382683433*((ut=tr+$t)-(Br=qe+Sr)),qA=.5411961*ut+Lr,Y=1.306562965*Br+Lr,QA=.707106781*(ur=$t+qe),OA=Sr+QA,ve=Sr-QA;FA[TA+40]=ve+qA,FA[TA+24]=ve-qA,FA[TA+8]=OA+Y,FA[TA+56]=OA-Y,TA++}for(zA=0;zA<64;++zA)ne=FA[zA]*IA[zA],h[zA]=ne>0?ne+.5|0:ne-.5|0;return h}(Q,_),EA=0;EA<64;++EA)m[K[EA]]=xA[EA];var _A=m[0]-P;P=m[0],_A==0?lA($[0]):(lA($[p[nA=32767+_A]]),lA(d[nA]));for(var NA=63;NA>0&&m[NA]==0;)NA--;if(NA==0)return lA(fA),P;for(var jA,gA=1;gA<=NA;){for(var V=gA;m[gA]==0&&gA<=NA;)++gA;var JA=gA-V;if(JA>=16){jA=JA>>4;for(var KA=1;KA<=jA;++KA)lA(hA);JA&=15}nA=32767+m[gA],lA(W[(JA<<4)+p[nA]]),lA(d[nA]),gA++}return NA!=63&&lA(fA),P}function bA(Q){Q=Math.min(Math.max(Q,1),100),i!=Q&&(function(_){for(var P=[16,11,10,16,24,40,51,61,12,12,14,19,26,58,60,55,14,13,16,24,40,57,69,56,14,17,22,29,51,87,80,62,18,22,37,56,68,109,103,77,24,35,55,64,81,104,113,92,49,64,78,87,103,121,120,101,72,92,95,98,112,100,103,99],$=0;$<64;$++){var W=a((P[$]*_+50)/100);W=Math.min(Math.max(W,1),255),s[K[$]]=W}for
|
|||
|
|
* @license
|
|||
|
|
* Copyright (c) 2017 Aras Abbasi
|
|||
|
|
*
|
|||
|
|
* Licensed under the MIT License.
|
|||
|
|
* http://opensource.org/licenses/mit-license
|
|||
|
|
*/function kr(t,A){if(this.pos=0,this.buffer=t,this.datav=new DataView(t.buffer),this.is_with_alpha=!!A,this.bottom_up=!0,this.flag=String.fromCharCode(this.buffer[0])+String.fromCharCode(this.buffer[1]),this.pos+=2,["BM","BA","CI","CP","IC","PT"].indexOf(this.flag)===-1)throw new Error("Invalid BMP File");this.parseHeader(),this.parseBGR()}function i2(t){function A(O){if(!O)throw Error("assert :P")}function e(O,Z,aA){for(var N=0;4>N;N++)if(O[Z+N]!=aA.charCodeAt(N))return!0;return!1}function r(O,Z,aA,N,S){for(var M=0;M<S;M++)O[Z+M]=aA[N+M]}function n(O,Z,aA,N){for(var S=0;S<N;S++)O[Z+S]=aA}function i(O){return new Int32Array(O)}function a(O,Z){for(var aA=[],N=0;N<O;N++)aA.push(new Z);return aA}function s(O,Z){var aA=[];return function N(S,M,R){for(var iA=R[M],tA=0;tA<iA&&(S.push(R.length>M+1?[]:new Z),!(R.length<M+1));tA++)N(S[tA],M+1,R)}(aA,0,O),aA}var o=function(){var O=this;function Z(u,c){for(var v=1<<c-1>>>0;u&v;)v>>>=1;return v?(u&v-1)+v:u}function aA(u,c,v,B,C){A(!(B%v));do u[c+(B-=v)]=C;while(0<B)}function N(u,c,v,B,C){if(A(2328>=C),512>=C)var E=i(512);else if((E=i(C))==null)return 0;return function(x,I,L,H,z,oA){var uA,AA,mA=I,dA=1<<L,X=i(16),J=i(16);for(A(z!=0),A(H!=null),A(x!=null),A(0<L),AA=0;AA<z;++AA){if(15<H[AA])return 0;++X[H[AA]]}if(X[0]==z)return 0;for(J[1]=0,uA=1;15>uA;++uA){if(X[uA]>1<<uA)return 0;J[uA+1]=J[uA]+X[uA]}for(AA=0;AA<z;++AA)uA=H[AA],0<H[AA]&&(oA[J[uA]++]=AA);if(J[15]==1)return(H=new S).g=0,H.value=oA[0],aA(x,mA,1,dA,H),dA;var BA,yA=-1,wA=dA-1,RA=0,HA=1,Ae=1,PA=1<<L;for(AA=0,uA=1,z=2;uA<=L;++uA,z<<=1){if(HA+=Ae<<=1,0>(Ae-=X[uA]))return 0;for(;0<X[uA];--X[uA])(H=new S).g=uA,H.value=oA[AA++],aA(x,mA+RA,z,PA,H),RA=Z(RA,uA)}for(uA=L+1,z=2;15>=uA;++uA,z<<=1){if(HA+=Ae<<=1,0>(Ae-=X[uA]))return 0;for(;0<X[uA];--X[uA]){if(H=new S,(RA&wA)!=yA){for(mA+=PA,BA=1<<(yA=uA)-L;15>yA&&!(0>=(BA-=X[yA]));)++yA,BA<<=1;dA+=PA=1<<(BA=yA-L),x[I+(yA=RA&wA)].g=BA+L,x[I+yA].value=mA-I-yA}H.g=uA-L,H.value=oA[AA++],aA(x,mA+(RA>>L),z,PA,H),RA=Z(RA,uA)}}return HA!=2*J[15]-1?0:dA}(u,c,v,B,C,E)}function S(){this.value=this.g=0}function M(){this.value=this.g=0}function R(){this.G=a(5,S),this.H=i(5),this.jc=this.Qb=this.qb=this.nd=0,this.pd=a(cr,M)}function iA(u,c,v,B){A(u!=null),A(c!=null),A(2147483648>B),u.Ca=254,u.I=0,u.b=-8,u.Ka=0,u.oa=c,u.pa=v,u.Jd=c,u.Yc=v+B,u.Zc=4<=B?v+B-4+1:v,nA(u)}function tA(u,c){for(var v=0;0<c--;)v|=hA(u,128)<<c;return v}function lA(u,c){var v=tA(u,c);return fA(u)?-v:v}function eA(u,c,v,B){var C,E=0;for(A(u!=null),A(c!=null),A(4294967288>B),u.Sb=B,u.Ra=0,u.u=0,u.h=0,4<B&&(B=4),C=0;C<B;++C)E+=c[v+C]<<8*C;u.Ra=E,u.bb=B,u.oa=c,u.pa=v}function cA(u){for(;8<=u.u&&u.bb<u.Sb;)u.Ra>>>=8,u.Ra+=u.oa[u.pa+u.bb]<<ss-8>>>0,++u.bb,u.u-=8;P(u)&&(u.h=1,u.u=0)}function sA(u,c){if(A(0<=c),!u.h&&c<=as){var v=_(u)&is[c];return u.u+=c,cA(u),v}return u.h=1,u.u=0}function bA(){this.b=this.Ca=this.I=0,this.oa=[],this.pa=0,this.Jd=[],this.Yc=0,this.Zc=[],this.Ka=0}function Q(){this.Ra=0,this.oa=[],this.h=this.u=this.bb=this.Sb=this.pa=0}function _(u){return u.Ra>>>(u.u&ss-1)>>>0}function P(u){return A(u.bb<=u.Sb),u.h||u.bb==u.Sb&&u.u>ss}function $(u,c){u.u=c,u.h=P(u)}function W(u){u.u>=No&&(A(u.u>=No),cA(u))}function nA(u){A(u!=null&&u.oa!=null),u.pa<u.Zc?(u.I=(u.oa[u.pa++]|u.I<<8)>>>0,u.b+=8):(A(u!=null&&u.oa!=null),u.pa<u.Yc?(u.b+=8,u.I=u.oa[u.pa++]|u.I<<8):u.Ka?u.b=0:(u.I<<=8,u.b+=8,u.Ka=1))}function fA(u){return tA(u,1)}function hA(u,c){var v=u.Ca;0>u.b&&nA(u);var B=u.b,C=v*c>>>8,E=(u.I>>>B>C)+0;for(E?(v-=C,u.I-=C+1<<B>>>0):v=C+1,B=v,C=0;256<=B;)C+=8,B>>=8;return B=7^C+fr[B],u.b-=B,u.Ca=(v<<B)-1,E}function xA(u,c,v){u[c+0]=v>>24&255,u[c+1]=v>>16&255,u[c+2]=v>>8&255,u[c+3]=v>>0&255}function EA(u,c){return u[c+0]<<0|u[c+1]<<8}function _A(u,c){return EA(u,c)|u[c+2]<<16}function NA(u,c){return EA(u,c)|EA(u,c+2)<<16}function jA(u,c){var v=1<<c;return A(u!=null),A(0<c),u.X=i(v),u.X==null?0:(u.Mb=32-c,u.Xa=c,1)}function gA(u,c){A(u!=null),A(c!=null),A(u.Xa==c.Xa),r(c.X,0,u.X,0,1<<c.Xa)}function V(){this.X=[],this.Xa=this.Mb=0}function JA(u,c,v,B){A(v!=null),A(B!=null);var C=v[0],E=B[0];return C==0&&(C=(u*E+c/2)/c),E==0&&
|
|||
|
|
`:"")+G})):U.push(k[0])}),w=U,o=e2.apply(this,[y,e])}for(i=0,a=w.length;i<a;i++){var T=0;if(r=w[i],o&&r[0]==`
|
|||
|
|
`&&(r=r.substr(1),T=1),p+h+(m=(n=zu.apply(this,[r,e])).reduce(function(k,G){return k+G},0))>A||T){if(m>A){for(s=t2.apply(this,[r,n,A-(p+h),A]),f.push(s.shift()),f=[s.pop()];s.length;)d.push([s.shift()]);m=n.slice(r.length-(f[0]?f[0].length:0)).reduce(function(k,G){return k+G},0)}else f=[r];d.push(f),p=m+o,h=b}else f.push(r),p+=h+m,h=b}return l=o?function(k,G){return(G?y:"")+k.join(" ")}:function(k){return k.join(" ")},d.map(l)},Ia.splitTextToSize=function(t,A,e){var r,n=(e=e||{}).fontSize||this.internal.getFontSize(),i=function(f){if(f.widths&&f.kerning)return{widths:f.widths,kerning:f.kerning};var d=this.internal.getFont(f.fontName,f.fontStyle);return d.metadata.Unicode?{widths:d.metadata.Unicode.widths||{0:1},kerning:d.metadata.Unicode.kerning||{}}:{font:d.metadata,fontSize:this.internal.getFontSize(),charSpace:this.internal.getCharSpace()}}.call(this,e);r=Array.isArray(t)?t:String(t).split(/\r?\n/);var a=1*this.internal.scaleFactor*A/n;i.textIndent=e.textIndent?1*e.textIndent*this.internal.scaleFactor/n:0,i.lineIndent=e.lineIndent;var s,o,l=[];for(s=0,o=r.length;s<o;s++)l=l.concat(r2.apply(this,[r[s],a,i]));return l},function(t){t.__fontmetrics__=t.__fontmetrics__||{};for(var A="klmnopqrstuvwxyz",e={},r={},n=0;n<A.length;n++)e[A[n]]="0123456789abcdef"[n],r["0123456789abcdef"[n]]=A[n];var i=function(d){return"0x"+parseInt(d,10).toString(16)},a=t.__fontmetrics__.compress=function(d){var p,h,m,w,b=["{"];for(var y in d){if(p=d[y],isNaN(parseInt(y,10))?h="'"+y+"'":(y=parseInt(y,10),h=(h=i(y).slice(2)).slice(0,-1)+r[h.slice(-1)]),typeof p=="number")p<0?(m=i(p).slice(3),w="-"):(m=i(p).slice(2),w=""),m=w+m.slice(0,-1)+r[m.slice(-1)];else{if(Qe(p)!=="object")throw new Error("Don't know what to do with value type "+Qe(p)+".");m=a(p)}b.push(h+m)}return b.push("}"),b.join("")},s=t.__fontmetrics__.uncompress=function(d){if(typeof d!="string")throw new Error("Invalid argument passed to uncompress.");for(var p,h,m,w,b={},y=1,U=b,T=[],k="",G="",j=d.length-1,K=1;K<j;K+=1)(w=d[K])=="'"?p?(m=p.join(""),p=void 0):p=[]:p?p.push(w):w=="{"?(T.push([U,m]),U={},m=void 0):w=="}"?((h=T.pop())[0][h[1]]=U,m=void 0,U=h[0]):w=="-"?y=-1:m===void 0?e.hasOwnProperty(w)?(k+=e[w],m=parseInt(k,16)*y,y=1,k=""):k+=w:e.hasOwnProperty(w)?(G+=e[w],U[m]=parseInt(G,16)*y,y=1,m=void 0,G=""):G+=w;return b},o={codePages:["WinAnsiEncoding"],WinAnsiEncoding:s("{19m8n201n9q201o9r201s9l201t9m201u8m201w9n201x9o201y8o202k8q202l8r202m9p202q8p20aw8k203k8t203t8v203u9v2cq8s212m9t15m8w15n9w2dw9s16k8u16l9u17s9z17x8y17y9y}")},l={Unicode:{Courier:o,"Courier-Bold":o,"Courier-BoldOblique":o,"Courier-Oblique":o,Helvetica:o,"Helvetica-Bold":o,"Helvetica-BoldOblique":o,"Helvetica-Oblique":o,"Times-Roman":o,"Times-Bold":o,"Times-BoldItalic":o,"Times-Italic":o}},f={Unicode:{"Courier-Oblique":s("{'widths'{k3w'fof'6o}'kerning'{'fof'-6o}}"),"Times-BoldItalic":s("{'widths'{k3o2q4ycx2r201n3m201o6o201s2l201t2l201u2l201w3m201x3m201y3m2k1t2l2r202m2n2n3m2o3m2p5n202q6o2r1w2s2l2t2l2u3m2v3t2w1t2x2l2y1t2z1w3k3m3l3m3m3m3n3m3o3m3p3m3q3m3r3m3s3m203t2l203u2l3v2l3w3t3x3t3y3t3z3m4k5n4l4m4m4m4n4m4o4s4p4m4q4m4r4s4s4y4t2r4u3m4v4m4w3x4x5t4y4s4z4s5k3x5l4s5m4m5n3r5o3x5p4s5q4m5r5t5s4m5t3x5u3x5v2l5w1w5x2l5y3t5z3m6k2l6l3m6m3m6n2w6o3m6p2w6q2l6r3m6s3r6t1w6u1w6v3m6w1w6x4y6y3r6z3m7k3m7l3m7m2r7n2r7o1w7p3r7q2w7r4m7s3m7t2w7u2r7v2n7w1q7x2n7y3t202l3mcl4mal2ram3man3mao3map3mar3mas2lat4uau1uav3maw3way4uaz2lbk2sbl3t'fof'6obo2lbp3tbq3mbr1tbs2lbu1ybv3mbz3mck4m202k3mcm4mcn4mco4mcp4mcq5ycr4mcs4mct4mcu4mcv4mcw2r2m3rcy2rcz2rdl4sdm4sdn4sdo4sdp4sdq4sds4sdt4sdu4sdv4sdw4sdz3mek3mel3mem3men3meo3mep3meq4ser2wes2wet2weu2wev2wew1wex1wey1wez1wfl3rfm3mfn3mfo3mfp3mfq3mfr3tfs3mft3rfu3rfv3rfw3rfz2w203k6o212m6o2dw2l2cq2l3t3m3u2l17s3x19m3m}'kerning'{cl{4qu5kt5qt5rs17ss5ts}201s{201ss}201t{cks4lscmscnscoscpscls2wu2yu201ts}201x{2wu2yu}2k{201ts}2w{4qx5kx5ou5qx5rs17su5tu}2x{17su5tu5ou}2y{4qx5kx5ou5qx5rs17ss5ts}'fof'-6ofn{17sw5tw5ou5qw5rs}7t{cksclscmscnscoscps4ls}3u{17su5tu5os5qs}3v{17su5tu5os5qs}7p{17su5tu}ck{4qu5kt5qt5rs17ss5ts}4l{4qu5kt5qt5rs17ss5ts}cm{4qu5kt5qt5rs17ss5ts}cn{4qu5kt5qt5rs17ss5ts}co{4qu5kt5qt5rs17ss5ts}cp{4qu5kt5qt5rs17ss5ts}6l{4qu
|
|||
|
|
<<
|
|||
|
|
`+w.join(`
|
|||
|
|
`)+`
|
|||
|
|
>>`)}),this.internal.viewerpreferences.isSubscribed=!0),this.internal.viewerpreferences.configuration=e,this},function(t){var A=function(){var r='<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"><rdf:Description rdf:about="" xmlns:jspdf="'+this.internal.__metadata__.namespaceuri+'"><jspdf:metadata>',n=unescape(encodeURIComponent('<x:xmpmeta xmlns:x="adobe:ns:meta/">')),i=unescape(encodeURIComponent(r)),a=unescape(encodeURIComponent(this.internal.__metadata__.metadata)),s=unescape(encodeURIComponent("</jspdf:metadata></rdf:Description></rdf:RDF>")),o=unescape(encodeURIComponent("</x:xmpmeta>")),l=i.length+a.length+s.length+n.length+o.length;this.internal.__metadata__.metadata_object_number=this.internal.newObject(),this.internal.write("<< /Type /Metadata /Subtype /XML /Length "+l+" >>"),this.internal.write("stream"),this.internal.write(n+i+a+s+o),this.internal.write("endstream"),this.internal.write("endobj")},e=function(){this.internal.__metadata__.metadata_object_number&&this.internal.write("/Metadata "+this.internal.__metadata__.metadata_object_number+" 0 R")};t.addMetadata=function(r,n){return this.internal.__metadata__===void 0&&(this.internal.__metadata__={metadata:r,namespaceuri:n||"http://jspdf.default.namespaceuri/"},this.internal.events.subscribe("putCatalog",e),this.internal.events.subscribe("postPutResources",A)),this}}(te.API),function(t){var A=t.API,e=A.pdfEscape16=function(i,a){for(var s,o=a.metadata.Unicode.widths,l=["","0","00","000","0000"],f=[""],d=0,p=i.length;d<p;++d){if(s=a.metadata.characterToGlyph(i.charCodeAt(d)),a.metadata.glyIdsUsed.push(s),a.metadata.toUnicode[s]=i.charCodeAt(d),o.indexOf(s)==-1&&(o.push(s),o.push([parseInt(a.metadata.widthOfGlyph(s),10)])),s=="0")return f.join("");s=s.toString(16),f.push(l[4-s.length],s)}return f.join("")},r=function(i){var a,s,o,l,f,d,p;for(f=`/CIDInit /ProcSet findresource begin
|
|||
|
|
12 dict begin
|
|||
|
|
begincmap
|
|||
|
|
/CIDSystemInfo <<
|
|||
|
|
/Registry (Adobe)
|
|||
|
|
/Ordering (UCS)
|
|||
|
|
/Supplement 0
|
|||
|
|
>> def
|
|||
|
|
/CMapName /Adobe-Identity-UCS def
|
|||
|
|
/CMapType 2 def
|
|||
|
|
1 begincodespacerange
|
|||
|
|
<0000><ffff>
|
|||
|
|
endcodespacerange`,o=[],d=0,p=(s=Object.keys(i).sort(function(h,m){return h-m})).length;d<p;d++)a=s[d],o.length>=100&&(f+=`
|
|||
|
|
`+o.length+` beginbfchar
|
|||
|
|
`+o.join(`
|
|||
|
|
`)+`
|
|||
|
|
endbfchar`,o=[]),i[a]!==void 0&&i[a]!==null&&typeof i[a].toString=="function"&&(l=("0000"+i[a].toString(16)).slice(-4),a=("0000"+(+a).toString(16)).slice(-4),o.push("<"+a+"><"+l+">"));return o.length&&(f+=`
|
|||
|
|
`+o.length+` beginbfchar
|
|||
|
|
`+o.join(`
|
|||
|
|
`)+`
|
|||
|
|
endbfchar
|
|||
|
|
`),f+=`endcmap
|
|||
|
|
CMapName currentdict /CMap defineresource pop
|
|||
|
|
end
|
|||
|
|
end`};A.events.push(["putFont",function(i){(function(a){var s=a.font,o=a.out,l=a.newObject,f=a.putStream;if(s.metadata instanceof t.API.TTFFont&&s.encoding==="Identity-H"){for(var d=s.metadata.Unicode.widths,p=s.metadata.subset.encode(s.metadata.glyIdsUsed,1),h="",m=0;m<p.length;m++)h+=String.fromCharCode(p[m]);var w=l();f({data:h,addLength1:!0,objectId:w}),o("endobj");var b=l();f({data:r(s.metadata.toUnicode),addLength1:!0,objectId:b}),o("endobj");var y=l();o("<<"),o("/Type /FontDescriptor"),o("/FontName /"+Ca(s.fontName)),o("/FontFile2 "+w+" 0 R"),o("/FontBBox "+t.API.PDFObject.convert(s.metadata.bbox)),o("/Flags "+s.metadata.flags),o("/StemV "+s.metadata.stemV),o("/ItalicAngle "+s.metadata.italicAngle),o("/Ascent "+s.metadata.ascender),o("/Descent "+s.metadata.decender),o("/CapHeight "+s.metadata.capHeight),o(">>"),o("endobj");var U=l();o("<<"),o("/Type /Font"),o("/BaseFont /"+Ca(s.fontName)),o("/FontDescriptor "+y+" 0 R"),o("/W "+t.API.PDFObject.convert(d)),o("/CIDToGIDMap /Identity"),o("/DW 1000"),o("/Subtype /CIDFontType2"),o("/CIDSystemInfo"),o("<<"),o("/Supplement 0"),o("/Registry (Adobe)"),o("/Ordering ("+s.encoding+")"),o(">>"),o(">>"),o("endobj"),s.objectNumber=l(),o("<<"),o("/Type /Font"),o("/Subtype /Type0"),o("/ToUnicode "+b+" 0 R"),o("/BaseFont /"+Ca(s.fontName)),o("/Encoding /"+s.encoding),o("/DescendantFonts ["+U+" 0 R]"),o(">>"),o("endobj"),s.isAlreadyPutted=!0}})(i)}]),A.events.push(["putFont",function(i){(function(a){var s=a.font,o=a.out,l=a.newObject,f=a.putStream;if(s.metadata instanceof t.API.TTFFont&&s.encoding==="WinAnsiEncoding"){for(var d=s.metadata.rawData,p="",h=0;h<d.length;h++)p+=String.fromCharCode(d[h]);var m=l();f({data:p,addLength1:!0,objectId:m}),o("endobj");var w=l();f({data:r(s.metadata.toUnicode),addLength1:!0,objectId:w}),o("endobj");var b=l();o("<<"),o("/Descent "+s.metadata.decender),o("/CapHeight "+s.metadata.capHeight),o("/StemV "+s.metadata.stemV),o("/Type /FontDescriptor"),o("/FontFile2 "+m+" 0 R"),o("/Flags 96"),o("/FontBBox "+t.API.PDFObject.convert(s.metadata.bbox)),o("/FontName /"+Ca(s.fontName)),o("/ItalicAngle "+s.metadata.italicAngle),o("/Ascent "+s.metadata.ascender),o(">>"),o("endobj"),s.objectNumber=l();for(var y=0;y<s.metadata.hmtx.widths.length;y++)s.metadata.hmtx.widths[y]=parseInt(s.metadata.hmtx.widths[y]*(1e3/s.metadata.head.unitsPerEm));o("<</Subtype/TrueType/Type/Font/ToUnicode "+w+" 0 R/BaseFont/"+Ca(s.fontName)+"/FontDescriptor "+b+" 0 R/Encoding/"+s.encoding+" /FirstChar 29 /LastChar 255 /Widths "+t.API.PDFObject.convert(s.metadata.hmtx.widths)+">>"),o("endobj"),s.isAlreadyPutted=!0}})(i)}]);var n=function(i){var a,s=i.text||"",o=i.x,l=i.y,f=i.options||{},d=i.mutex||{},p=d.pdfEscape,h=d.activeFontKey,m=d.fonts,w=h,b="",y=0,U="",T=m[w].encoding;if(m[w].encoding!=="Identity-H")return{text:s,x:o,y:l,options:f,mutex:d};for(U=s,w=h,Array.isArray(s)&&(U=s[0]),y=0;y<U.length;y+=1)m[w].metadata.hasOwnProperty("cmap")&&(a=m[w].metadata.cmap.unicode.codeMap[U[y].charCodeAt(0)]),a||U[y].charCodeAt(0)<256&&m[w].metadata.hasOwnProperty("Unicode")?b+=U[y]:b+="";var k="";return parseInt(w.slice(1))<14||T==="WinAnsiEncoding"?k=p(b,w).split("").map(function(G){return G.charCodeAt(0).toString(16)}).join(""):T==="Identity-H"&&(k=e(b,m[w])),d.isHex=!0,{text:k,x:o,y:l,options:f,mutex:d}};A.events.push(["postProcessText",function(i){var a=i.text||"",s=[],o={text:a,x:i.x,y:i.y,options:i.options,mutex:i.mutex};if(Array.isArray(a)){var l=0;for(l=0;l<a.length;l+=1)Array.isArray(a[l])&&a[l].length===3?s.push([n(Object.assign({},o,{text:a[l][0]})).text,a[l][1],a[l][2]]):s.push(n(Object.assign({},o,{text:a[l]})).text);i.text=s}else i.text=n(Object.assign({},o,{text:a})).text}])}(te),function(t){var A=function(){return this.internal.vFS===void 0&&(this.internal.vFS={}),!0};t.existsFileInVFS=function(e){return A.call(this),this.internal.vFS[e]!==void 0},t.addFileToVFS=function(e,r){return A.call(this),this.internal.vFS[e]=r,this},t.getFileFromVFS=function(e){return A.call(this),this.internal.vFS[e]!==void 0?this.internal.vFS[e]:null}}(te.API),function(t){t.__bidiEngine__=t.prototype._
|
|||
|
|
`)}return""+e},A}();const u2=Mc.defineStore("StructStore",()=>{const t=vA.ref(),A=vA.ref();return{dataSource:t,selectedElement:A}}),Ks=t=>(vA.pushScopeId("data-v-83904042"),t=t(),vA.popScopeId(),t),AU={class:"node-container"},eU={class:"root-node"},tU=["colspan"],rU=["id"],nU={class:"section-list"},iU={class:"column-avatar"},aU=["src"],sU={class:"column-content"},oU={class:"header"},uU={class:"subheader"},lU={class:"caption"},cU={class:"column-side"},fU={key:0},hU=["colspan"],gU={class:"node-container"},dU={class:"nodeline"},pU=["colspan"],vU=[Ks(()=>vA.createElementVNode("div",{class:"nodeline-down"},null,-1))],BU={class:"nodeline"},wU=Ks(()=>vA.createElementVNode("td",{class:"nodeline-right"},null,-1)),mU=Ks(()=>vA.createElementVNode("td",{class:"nodeline-left nodeline-top"},null,-1)),yU=Ks(()=>vA.createElementVNode("td",{class:"nodeline-right nodeline-top"},null,-1)),CU=Ks(()=>vA.createElementVNode("td",{class:"nodeline-left"},null,-1)),bU={class:"node-children"},FU=vA.defineComponent({__name:"OrgChartNode",props:{dataSource:Object},setup(t){const A=t,{selectedElement:e}=Mc.storeToRefs(u2()),r=vA.toRefs(A).dataSource,n=vA.ref(!1);vA.onBeforeMount(()=>{A.dataSource?.depth<1?n.value=!0:n.value=!1}),vA.onBeforeUpdate(()=>{A.dataSource?.depth<1?n.value=!0:n.value=!1}),vA.onMounted(()=>{}),vA.watch(()=>A.dataSource,l=>{});const i=vA.ref();vA.watch(()=>n,l=>{}),vA.watchEffect(()=>{n.value?(i.value?.classList.remove("oncollapse"),i.value?.classList.add("onexpand")):(i.value?.classList.remove("onexpand"),i.value?.classList.add("oncollapse"))});const a=l=>{e.value=l},s=()=>{n.value=!n.value},o=()=>n.value;return(l,f)=>{const d=vA.resolveComponent("OrgChartNode",!0);return vA.openBlock(),vA.createElementBlock("table",AU,[vA.createElementVNode("tbody",null,[vA.createElementVNode("tr",eU,[vA.createElementVNode("td",{colspan:vA.unref(r)?.children&&vA.unref(r)?.children.length?vA.unref(r)?.children.length*2:0},[vA.createElementVNode("div",{class:vA.normalizeClass(vA.unref(r)?.personID==1?"element-container root-element":"element-container child-element"),id:vA.unref(r)?.personID,onClik:f[1]||(f[1]=p=>a(vA.unref(r)?.persosnID))},[vA.createElementVNode("div",nU,[vA.createElementVNode("div",iU,[vA.createElementVNode("img",{src:vA.unref(r)?.avatar&&vA.unref(r)?.avatar!==""?vA.unref(r)?.avatar:"data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4NCjwhLS0gVXBsb2FkZWQgdG86IFNWRyBSZXBvLCB3d3cuc3ZncmVwby5jb20sIEdlbmVyYXRvcjogU1ZHIFJlcG8gTWl4ZXIgVG9vbHMgLS0+Cjxzdmcgd2lkdGg9IjgwMHB4IiBoZWlnaHQ9IjgwMHB4IiB2aWV3Qm94PSIwIDAgMTYgMTYiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+DQogICAgPHBhdGggZD0ibSA4IDEgYyAtMS42NTYyNSAwIC0zIDEuMzQzNzUgLTMgMyBzIDEuMzQzNzUgMyAzIDMgcyAzIC0xLjM0Mzc1IDMgLTMgcyAtMS4zNDM3NSAtMyAtMyAtMyB6IG0gLTEuNSA3IGMgLTIuNDkyMTg4IDAgLTQuNSAyLjAwNzgxMiAtNC41IDQuNSB2IDAuNSBjIDAgMS4xMDkzNzUgMC44OTA2MjUgMiAyIDIgaCA4IGMgMS4xMDkzNzUgMCAyIC0wLjg5MDYyNSAyIC0yIHYgLTAuNSBjIDAgLTIuNDkyMTg4IC0yLjAwNzgxMiAtNC41IC00LjUgLTQuNSB6IG0gMCAwIiBmaWxsPSIjMmUzNDM2Ii8+DQo8L3N2Zz4=",alt:"{{ propDataSource?.name }}"},null,8,aU)]),vA.createElementVNode("div",sU,[vA.createElementVNode("div",oU,[vA.unref(r)?.name.trim()!==""?(vA.openBlock(),vA.createElementBlock(vA.Fragment,{key:0},[vA.createTextVNode(vA.toDisplayString(vA.unref(r)?.name),1)],64)):(vA.openBlock(),vA.createElementBlock(vA.Fragment,{key:1},[vA.createTextVNode(vA.toDisplayString(vA.unref(r)?.depth>0?"ว่าง":"")+" ",1)],64))]),vA.createElementVNode("div",uU,vA.toDisplayString(vA.unref(r)?.positionName?vA.unref(r)?.positionName:""),1),vA.createElementVNode("div",lU,vA.toDisplayString(vA.unref(r)?.departmentName?vA.unref(r)?.departmentName:""),1)]),vA.createElementVNode("div",cU,[vA.unref(r)?.children&&vA.unref(r)?.children.length>0?(vA.openBlock(),vA.createElementBlock("button",{key:0,ref_key:"sideButton",ref:i,class:"side-button",onClick:f[0]||(f[0]=p=>s())},null,512)):vA.createCommentVNode("",!0)])])],42,rU)],8,tU)]),vA.unref(r)?.children&&vA.unref(r)?.children.length?(vA.openBlock(),vA.createElementBlock("tr",fU,[vA.createElementVNode("td",{colspan:vA.unref(r)?.
|
|||
|
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var HU=Object.hasOwnProperty,c2=Object.setPrototypeOf,_U=Object.isFrozen,PU=Object.getPrototypeOf,DU=Object.getOwnPropertyDescriptor,Jt=Object.freeze,jr=Object.seal,MU=Object.create,f2=typeof Reflect<"u"&&Reflect,Yu=f2.apply,oh=f2.construct;Yu||(Yu=function(A,e,r){return A.apply(e,r)}),Jt||(Jt=function(A){return A}),jr||(jr=function(A){return A}),oh||(oh=function(A,e){return Xu(A,Vr(e))});var RU=Er(Array.prototype.forEach),h2=Er(Array.prototype.pop),Vs=Er(Array.prototype.push),Ju=Er(String.prototype.toLowerCase),uh=Er(String.prototype.toString),kU=Er(String.prototype.match),Gr=Er(String.prototype.replace),KU=Er(String.prototype.indexOf),VU=Er(String.prototype.trim),Zt=Er(RegExp.prototype.test),lh=jU(TypeError);function Er(t){return function(A){for(var e=arguments.length,r=new Array(e>1?e-1:0),n=1;n<e;n++)r[n-1]=arguments[n];return Yu(t,A,r)}}function jU(t){return function(){for(var A=arguments.length,e=new Array(A),r=0;r<A;r++)e[r]=arguments[r];return oh(t,e)}}function fe(t,A,e){e=e||Ju,c2&&c2(t,null);for(var r=A.length;r--;){var n=A[r];if(typeof n=="string"){var i=e(n);i!==n&&(_U(A)||(A[r]=i),n=i)}t[n]=!0}return t}function Mi(t){var A=MU(null),e;for(e in t)Yu(HU,t,[e])===!0&&(A[e]=t[e]);return A}function Zu(t,A){for(;t!==null;){var e=DU(t,A);if(e){if(e.get)return Er(e.get);if(typeof e.value=="function")return Er(e.value)}t=PU(t)}function r(n){return console.warn("fallback value for",n),null}return r}var g2=Jt(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),ch=Jt(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),fh=Jt(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),GU=Jt(["animate","color-profile","cursor","discard","fedropshadow","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),hh=Jt(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover"]),$U=Jt(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),d2=Jt(["#text"]),p2=Jt(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class
|
|||
|
|
`+ze),NA&&(ze=Gr(ze,R," "),ze=Gr(ze,iA," "),ze=Gr(ze,tA," ")),k&&FA?k.createHTML(ze):ze},A.setConfig=function(qA){Xr(qA),gA=!0},A.clearConfig=function(){Le=null,gA=!1},A.isValidAttribute=function(qA,Y,QA){Le||Xr({});var OA=ue(qA),ve=ue(Y);return ur(OA,ve,QA)},A.addHook=function(qA,Y){typeof Y=="function"&&(M[qA]=M[qA]||[],Vs(M[qA],Y))},A.removeHook=function(qA){if(M[qA])return h2(M[qA])},A.removeHooks=function(qA){M[qA]&&(M[qA]=[])},A.removeAllHooks=function(){M={}},A}var n3=B2();const i3=Object.freeze(Object.defineProperty({__proto__:null,default:n3},Symbol.toStringTag,{value:"Module"}));var el=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},tl=function(t){return t&&t.Math==Math&&t},Et=tl(typeof globalThis=="object"&&globalThis)||tl(typeof window=="object"&&window)||tl(typeof self=="object"&&self)||tl(typeof el=="object"&&el)||function(){return this}()||Function("return this")(),Sa={},st=function(t){try{return!!t()}catch{return!0}},a3=st,dn=!a3(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!=7}),s3=st,rl=!s3(function(){var t=function(){}.bind();return typeof t!="function"||t.hasOwnProperty("prototype")}),o3=rl,nl=Function.prototype.call,Ht=o3?nl.bind(nl):function(){return nl.apply(nl,arguments)},w2={},m2={}.propertyIsEnumerable,y2=Object.getOwnPropertyDescriptor,u3=y2&&!m2.call({1:2},1);w2.f=u3?function(A){var e=y2(this,A);return!!e&&e.enumerable}:m2;var il=function(t,A){return{enumerable:!(t&1),configurable:!(t&2),writable:!(t&4),value:A}},C2=rl,b2=Function.prototype,dh=b2.call,l3=C2&&b2.bind.bind(dh,dh),ot=C2?l3:function(t){return function(){return dh.apply(t,arguments)}},F2=ot,c3=F2({}.toString),f3=F2("".slice),Ri=function(t){return f3(c3(t),8,-1)},h3=ot,g3=st,d3=Ri,ph=Object,p3=h3("".split),Q2=g3(function(){return!ph("z").propertyIsEnumerable(0)})?function(t){return d3(t)=="String"?p3(t,""):ph(t)}:ph,ki=function(t){return t==null},v3=ki,B3=TypeError,pn=function(t){if(v3(t))throw B3("Can't call method on "+t);return t},w3=Q2,m3=pn,js=function(t){return w3(m3(t))},vh=typeof document=="object"&&document.all,y3=typeof vh>"u"&&vh!==void 0,U2={all:vh,IS_HTMLDDA:y3},E2=U2,C3=E2.all,Je=E2.IS_HTMLDDA?function(t){return typeof t=="function"||t===C3}:function(t){return typeof t=="function"},x2=Je,I2=U2,b3=I2.all,xn=I2.IS_HTMLDDA?function(t){return typeof t=="object"?t!==null:x2(t)||t===b3}:function(t){return typeof t=="object"?t!==null:x2(t)},Bh=Et,F3=Je,Q3=function(t){return F3(t)?t:void 0},Ki=function(t,A){return arguments.length<2?Q3(Bh[t]):Bh[t]&&Bh[t][A]},U3=ot,al=U3({}.isPrototypeOf),sl=typeof navigator<"u"&&String(navigator.userAgent)||"",S2=Et,wh=sl,L2=S2.process,N2=S2.Deno,T2=L2&&L2.versions||N2&&N2.version,O2=T2&&T2.v8,$r,ol;O2&&($r=O2.split("."),ol=$r[0]>0&&$r[0]<4?1:+($r[0]+$r[1])),!ol&&wh&&($r=wh.match(/Edge\/(\d+)/),(!$r||$r[1]>=74)&&($r=wh.match(/Chrome\/(\d+)/),$r&&(ol=+$r[1])));var mh=ol,H2=mh,E3=st,_2=!!Object.getOwnPropertySymbols&&!E3(function(){var t=Symbol();return!String(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&H2&&H2<41}),x3=_2,P2=x3&&!Symbol.sham&&typeof Symbol.iterator=="symbol",I3=Ki,S3=Je,L3=al,N3=P2,T3=Object,D2=N3?function(t){return typeof t=="symbol"}:function(t){var A=I3("Symbol");return S3(A)&&L3(A.prototype,T3(t))},O3=String,ul=function(t){try{return O3(t)}catch{return"Object"}},H3=Je,_3=ul,P3=TypeError,In=function(t){if(H3(t))return t;throw P3(_3(t)+" is not a function")},D3=In,M3=ki,La=function(t,A){var e=t[A];return M3(e)?void 0:D3(e)},yh=Ht,Ch=Je,bh=xn,R3=TypeError,k3=function(t,A){var e,r;if(A==="string"&&Ch(e=t.toString)&&!bh(r=yh(e,t))||Ch(e=t.valueOf)&&!bh(r=yh(e,t))||A!=="string"&&Ch(e=t.toString)&&!bh(r=yh(e,t)))return r;throw R3("Can't convert object to primitive value")},Gs={},K3={get exports(){return Gs},set exports(t){Gs=t}},M2=Et,V3=Object.defineProperty,Fh=function(t,A){try{V3(M2,t,{value:A,configurable:!0,writable:!0})}catch{M2[t]=A}return A},j3=Et,G3=Fh,R2="__core-js_shared__",$3=j3[R2]||G3(R2,{}),Qh=$3,k2=Qh;(K3.exports=function(t,A){return k2[t]||(k2[t]=A!==void 0?A:{})})("versi
|
|||
|
|
`)&&t.flags==="s")}),c6=st,f6=Et,h6=f6.RegExp,g6=c6(function(){var t=h6("(?<a>b)","g");return t.exec("b").groups.a!=="b"||"b".replace(t,"$<a>c")!=="bc"}),ka=Ht,Pl=ot,d6=wn,p6=xB,v6=IB,B6=Gs,w6=Ig,m6=vl.get,y6=l6,C6=g6,b6=B6("native-string-replace",String.prototype.replace),Dl=RegExp.prototype.exec,Sg=Dl,F6=Pl("".charAt),Q6=Pl("".indexOf),U6=Pl("".replace),Lg=Pl("".slice),Ng=function(){var t=/a/,A=/b*/g;return ka(Dl,t,"a"),ka(Dl,A,"a"),t.lastIndex!==0||A.lastIndex!==0}(),PB=v6.BROKEN_CARET,Tg=/()??/.exec("")[1]!==void 0,E6=Ng||Tg||PB||y6||C6;E6&&(Sg=function(A){var e=this,r=m6(e),n=d6(A),i=r.raw,a,s,o,l,f,d,p;if(i)return i.lastIndex=e.lastIndex,a=ka(Sg,i,n),e.lastIndex=i.lastIndex,a;var h=r.groups,m=PB&&e.sticky,w=ka(p6,e),b=e.source,y=0,U=n;if(m&&(w=U6(w,"y",""),Q6(w,"g")===-1&&(w+="g"),U=Lg(n,e.lastIndex),e.lastIndex>0&&(!e.multiline||e.multiline&&F6(n,e.lastIndex-1)!==`
|
|||
|
|
`)&&(b="(?: "+b+")",U=" "+U,y++),s=new RegExp("^(?:"+b+")",w)),Tg&&(s=new RegExp("^"+b+"$(?!\\s)",w)),Ng&&(o=e.lastIndex),l=ka(Dl,m?s:e,U),m?l?(l.input=Lg(l.input,y),l[0]=Lg(l[0],y),l.index=e.lastIndex,e.lastIndex+=l[0].length):e.lastIndex=0:Ng&&l&&(e.lastIndex=e.global?l.index+l[0].length:o),Tg&&l&&l.length>1&&ka(b6,l[0],s,function(){for(f=1;f<arguments.length-2;f++)arguments[f]===void 0&&(l[f]=void 0)}),l&&h)for(l.groups=d=w6(null),f=0;f<h.length;f++)p=h[f],d[p[0]]=l[p[1]];return l});var Ml=Sg,x6=Ar,DB=Ml;x6({target:"RegExp",proto:!0,forced:/./.exec!==DB},{exec:DB});var MB=Ys,RB=Vi,I6=Ml,kB=st,KB=xt,S6=$s,L6=KB("species"),Og=RegExp.prototype,Hg=function(t,A,e,r){var n=KB(t),i=!kB(function(){var l={};return l[n]=function(){return 7},""[t](l)!=7}),a=i&&!kB(function(){var l=!1,f=/a/;return t==="split"&&(f={},f.constructor={},f.constructor[L6]=function(){return f},f.flags="",f[n]=/./[n]),f.exec=function(){return l=!0,null},f[n](""),!l});if(!i||!a||e){var s=MB(/./[n]),o=A(n,""[t],function(l,f,d,p,h){var m=MB(l),w=f.exec;return w===I6||w===Og.exec?i&&!h?{done:!0,value:s(f,d,p)}:{done:!0,value:m(d,f,p)}:{done:!1}});RB(String.prototype,t,o[0]),RB(Og,n,o[1])}r&&S6(Og[n],"sham",!0)},_g=ot,N6=ml,T6=wn,O6=pn,H6=_g("".charAt),VB=_g("".charCodeAt),_6=_g("".slice),jB=function(t){return function(A,e){var r=T6(O6(A)),n=N6(e),i=r.length,a,s;return n<0||n>=i?t?"":void 0:(a=VB(r,n),a<55296||a>56319||n+1===i||(s=VB(r,n+1))<56320||s>57343?t?H6(r,n):a:t?_6(r,n,n+2):(a-55296<<10)+(s-56320)+65536)}},P6={codeAt:jB(!1),charAt:jB(!0)},D6=P6.charAt,Pg=function(t,A,e){return A+(e?D6(t,A).length:1)},GB=Ht,M6=jt,R6=Je,k6=Ri,K6=Ml,V6=TypeError,Dg=function(t,A){var e=t.exec;if(R6(e)){var r=GB(e,t,A);return r!==null&&M6(r),r}if(k6(t)==="RegExp")return GB(K6,t,A);throw V6("RegExp#exec called on incompatible receiver")},j6=Ht,G6=Hg,$6=jt,q6=ki,W6=Oa,Mg=wn,z6=pn,X6=La,Y6=Pg,$B=Dg;G6("match",function(t,A,e){return[function(n){var i=z6(this),a=q6(n)?void 0:X6(n,t);return a?j6(a,n,i):new RegExp(n)[t](Mg(i))},function(r){var n=$6(this),i=Mg(r),a=e(A,n,i);if(a.done)return a.value;if(!n.global)return $B(n,i);var s=n.unicode;n.lastIndex=0;for(var o=[],l=0,f;(f=$B(n,i))!==null;){var d=Mg(f[0]);o[l]=d,d===""&&(n.lastIndex=Y6(i,W6(n.lastIndex),s)),l++}return l===0?null:o}]});var Rg=ot,J6=ll,Z6=Math.floor,kg=Rg("".charAt),AT=Rg("".replace),Kg=Rg("".slice),eT=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,tT=/\$([$&'`]|\d{1,2})/g,rT=function(t,A,e,r,n,i){var a=e+t.length,s=r.length,o=tT;return n!==void 0&&(n=J6(n),o=eT),AT(i,o,function(l,f){var d;switch(kg(f,0)){case"$":return"$";case"&":return t;case"`":return Kg(A,0,e);case"'":return Kg(A,a);case"<":d=n[Kg(f,1,-1)];break;default:var p=+f;if(p===0)return l;if(p>s){var h=Z6(p/10);return h===0?l:h<=s?r[h-1]===void 0?kg(f,1):r[h-1]+kg(f,1):l}d=r[p-1]}return d===void 0?"":d})},nT=Xh,qB=Ht,Rl=ot,iT=Hg,aT=st,sT=jt,oT=Je,uT=ki,lT=ml,cT=Oa,Ka=wn,fT=pn,hT=Pg,gT=La,dT=rT,pT=Dg,vT=xt,Vg=vT("replace"),BT=Math.max,wT=Math.min,mT=Rl([].concat),jg=Rl([].push),WB=Rl("".indexOf),zB=Rl("".slice),yT=function(t){return t===void 0?t:String(t)},CT=function(){return"a".replace(/./,"$0")==="$0"}(),XB=function(){return/./[Vg]?/./[Vg]("a","$0")==="":!1}(),bT=!aT(function(){var t=/./;return t.exec=function(){var A=[];return A.groups={a:"7"},A},"".replace(t,"$<a>")!=="7"});iT("replace",function(t,A,e){var r=XB?"$":"$0";return[function(i,a){var s=fT(this),o=uT(i)?void 0:gT(i,Vg);return o?qB(o,i,s,a):qB(A,Ka(s),i,a)},function(n,i){var a=sT(this),s=Ka(n);if(typeof i=="string"&&WB(i,r)===-1&&WB(i,"$<")===-1){var o=e(A,a,s,i);if(o.done)return o.value}var l=oT(i);l||(i=Ka(i));var f=a.global;if(f){var d=a.unicode;a.lastIndex=0}for(var p=[];;){var h=pT(a,s);if(h===null||(jg(p,h),!f))break;var m=Ka(h[0]);m===""&&(a.lastIndex=hT(s,cT(a.lastIndex),d))}for(var w="",b=0,y=0;y<p.length;y++){h=p[y];for(var U=Ka(h[0]),T=BT(wT(lT(h.index),s.length),0),k=[],G=1;G<h.length;G++)jg(k,yT(h[G]));var j=h.groups;if(l){var K=mT([U],k,T,s);j!==void 0&&jg(K,j);var O=Ka(nT(i,void 0,K))}else O=dT(U,s,T,k,j,i);T>=b&&(w+=zB(s,b,T)+O,b=T+U.length)}return w+zB(s,b)}]},!bT||!CT||XB);var FT=xn,Q
|
|||
|
|
\v\f\r \u2028\u2029\uFEFF`,TO=ot,OO=pn,HO=wn,cd=Dw,Mw=TO("".replace),_O=RegExp("^["+cd+"]+"),PO=RegExp("(^|[^"+cd+"])["+cd+"]+$"),fd=function(t){return function(A){var e=HO(OO(A));return t&1&&(e=Mw(e,_O,"")),t&2&&(e=Mw(e,PO,"$1")),e}},DO={start:fd(1),end:fd(2),trim:fd(3)},MO=gl.PROPER,RO=st,Rw=Dw,kw="
",kO=function(t){return RO(function(){return!!Rw[t]()||kw[t]()!==kw||MO&&Rw[t].name!==t})},KO=Ar,VO=DO.trim,jO=kO;KO({target:"String",proto:!0,forced:jO("trim")},{trim:function(){return VO(this)}});var hd=function(t){this.ok=!1,this.alpha=1,t.charAt(0)=="#"&&(t=t.substr(1,6)),t=t.replace(/ /g,""),t=t.toLowerCase();var A={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dodgerblue:"1e90ff",feldspar:"d19275",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgrey:"d3d3d3",lightgreen:"90ee90",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslateblue:"8470ff",lightslategray:"778899",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"00ff00",limegreen:"32cd32",linen:"faf0e6",magenta:"ff00ff",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370d8",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"d87093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"ff0000",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",violetred:"d02090",wheat:"f5deb3",white:"ffffff",whitesmoke:"f5f5f5",yellow:"ffff00",yellowgreen:"9acd32"};t=A[t]||t;for(var e=[{re:/^rgba\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3}),\s*((?:\d?\.)?\d)\)$/,example:["rgba(123, 234, 45, 0.8)","rgba(255,234,245,1.0)"],process:function(o){return[parseInt(o[1]),parseInt(o[2]),parseInt(o[3]),parseFloat(o[4])]}},{re:/^rgb\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/,example:["rgb(123, 234, 45)","rgb(255,234,245)"],process:function(o){return[parseInt(o[1]),parseInt(o[2]),parseInt(o[3])]}},{re:/^([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,example:["#00ff00","336699"],process:function(o){return[parseInt(o[1],16),parseInt(o[2],16),parseInt(o[3],16)]}},{re:/^([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,example:["#fb0","f0f"],process:function(
|
|||
|
|
Copyright (c) Microsoft Corporation.
|
|||
|
|
|
|||
|
|
Permission to use, copy, modify, and/or distribute this software for any
|
|||
|
|
purpose with or without fee is hereby granted.
|
|||
|
|
|
|||
|
|
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|||
|
|
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|||
|
|
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|||
|
|
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|||
|
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|||
|
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|||
|
|
PERFORMANCE OF THIS SOFTWARE.
|
|||
|
|
***************************************************************************** */var Gw=function(t,A){return(Gw=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,r){e.__proto__=r}||function(e,r){for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])})(t,A)};function $w(t,A){if(typeof A!="function"&&A!==null)throw new TypeError("Class extends value "+String(A)+" is not a constructor or null");function e(){this.constructor=t}Gw(t,A),t.prototype=A===null?Object.create(A):(e.prototype=A.prototype,new e)}function oH(t){var A="";Array.isArray(t)||(t=[t]);for(var e=0;e<t.length;e++){var r=t[e];if(r.type===CA.CLOSE_PATH)A+="z";else if(r.type===CA.HORIZ_LINE_TO)A+=(r.relative?"h":"H")+r.x;else if(r.type===CA.VERT_LINE_TO)A+=(r.relative?"v":"V")+r.y;else if(r.type===CA.MOVE_TO)A+=(r.relative?"m":"M")+r.x+" "+r.y;else if(r.type===CA.LINE_TO)A+=(r.relative?"l":"L")+r.x+" "+r.y;else if(r.type===CA.CURVE_TO)A+=(r.relative?"c":"C")+r.x1+" "+r.y1+" "+r.x2+" "+r.y2+" "+r.x+" "+r.y;else if(r.type===CA.SMOOTH_CURVE_TO)A+=(r.relative?"s":"S")+r.x2+" "+r.y2+" "+r.x+" "+r.y;else if(r.type===CA.QUAD_TO)A+=(r.relative?"q":"Q")+r.x1+" "+r.y1+" "+r.x+" "+r.y;else if(r.type===CA.SMOOTH_QUAD_TO)A+=(r.relative?"t":"T")+r.x+" "+r.y;else{if(r.type!==CA.ARC)throw new Error('Unexpected command type "'+r.type+'" at index '+e+".");A+=(r.relative?"a":"A")+r.rX+" "+r.rY+" "+r.xRot+" "+ +r.lArcFlag+" "+ +r.sweepFlag+" "+r.x+" "+r.y}}return A}function dd(t,A){var e=t[0],r=t[1];return[e*Math.cos(A)-r*Math.sin(A),e*Math.sin(A)+r*Math.cos(A)]}function Wr(){for(var t=[],A=0;A<arguments.length;A++)t[A]=arguments[A];for(var e=0;e<t.length;e++)if(typeof t[e]!="number")throw new Error("assertNumbers arguments["+e+"] is not a number. "+typeof t[e]+" == typeof "+t[e]);return!0}var ui=Math.PI;function pd(t,A,e){t.lArcFlag=t.lArcFlag===0?0:1,t.sweepFlag=t.sweepFlag===0?0:1;var r=t.rX,n=t.rY,i=t.x,a=t.y;r=Math.abs(t.rX),n=Math.abs(t.rY);var s=dd([(A-i)/2,(e-a)/2],-t.xRot/180*ui),o=s[0],l=s[1],f=Math.pow(o,2)/Math.pow(r,2)+Math.pow(l,2)/Math.pow(n,2);1<f&&(r*=Math.sqrt(f),n*=Math.sqrt(f)),t.rX=r,t.rY=n;var d=Math.pow(r,2)*Math.pow(l,2)+Math.pow(n,2)*Math.pow(o,2),p=(t.lArcFlag!==t.sweepFlag?1:-1)*Math.sqrt(Math.max(0,(Math.pow(r,2)*Math.pow(n,2)-d)/d)),h=r*l/n*p,m=-n*o/r*p,w=dd([h,m],t.xRot/180*ui);t.cX=w[0]+(A+i)/2,t.cY=w[1]+(e+a)/2,t.phi1=Math.atan2((l-m)/n,(o-h)/r),t.phi2=Math.atan2((-l-m)/n,(-o-h)/r),t.sweepFlag===0&&t.phi2>t.phi1&&(t.phi2-=2*ui),t.sweepFlag===1&&t.phi2<t.phi1&&(t.phi2+=2*ui),t.phi1*=180/ui,t.phi2*=180/ui}function qw(t,A,e){Wr(t,A,e);var r=t*t+A*A-e*e;if(0>r)return[];if(r===0)return[[t*e/(t*t+A*A),A*e/(t*t+A*A)]];var n=Math.sqrt(r);return[[(t*e+A*n)/(t*t+A*A),(A*e-t*n)/(t*t+A*A)],[(t*e-A*n)/(t*t+A*A),(A*e+t*n)/(t*t+A*A)]]}var gt,Nn=Math.PI/180;function Ww(t,A,e){return(1-e)*t+e*A}function zw(t,A,e,r){return t+Math.cos(r/180*ui)*A+Math.sin(r/180*ui)*e}function Xw(t,A,e,r){var n=1e-6,i=A-t,a=e-A,s=3*i+3*(r-e)-6*a,o=6*(a-i),l=3*i;return Math.abs(s)<n?[-l/o]:function(f,d,p){p===void 0&&(p=1e-6);var h=f*f/4-d;if(h<-p)return[];if(h<=p)return[-f/2];var m=Math.sqrt(h);return[-f/2-m,-f/2+m]}(o/s,l/s,n)}function Yw(t,A,e,r,n){var i=1-n;return t*(i*i*i)+A*(3*i*i*n)+e*(3*i*n*n)+r*(n*n*n)}(function(t){function A(){return n(function(s,o,l){return s.relative&&(s.x1!==void 0&&(s.x1+=o),s.y1!==void 0&&(s.y1+=l),s.x2!==void 0&&(s.x2+=o),s.y2!==void 0&&(s.y2+=l),s.x!==void 0&&(s.x+=o),s.y!==void 0&&(s.y+=l),s.relative=!1),s})}function e(){var s=NaN,o=NaN,l=NaN,f=NaN;return n(function(d,p,h){return d.type&CA.SMOOTH_CURVE_TO&&(d.type=CA.CURVE_TO,s=isNaN(s)?p:s,o=isNaN(o)?h:o,d.x1=d.relative?p-s:2*p-s,d.y1=d.relative?h-o:2*h-o),d.type&CA.CURVE_TO?(s=d.relative?p+d.x2:d.x2,o=d.relative?h+d.y2:d.y2):(s=NaN,o=NaN),d.type&CA.SMOOTH_QUAD_TO&&(d.type=CA.QUAD_TO,l=isNaN(l)?p:l,f=isNaN(f)?h:f,d.x1=d.relative?p-l:2*p-l,d.y1=d.relative?h-f:2*h-f),d.type&CA.QUAD_TO?(l=d.relative?p+d.x1:d.x1,f=d.relative?h+d.y1:d.y1):(l=NaN,f=NaN),d})}function r(){var s=NaN,o=NaN;return n(function(l,f,d){if(l.type&CA.SMOOTH_QUAD_TO&&(l.type=CA.QUAD_TO,s=isNaN(s)?f:s,o
|
|||
|
|
`},Zw=function(t){return"0".charCodeAt(0)<=t.charCodeAt(0)&&t.charCodeAt(0)<="9".charCodeAt(0)},lH=function(t){function A(){var e=t.call(this)||this;return e.curNumber="",e.curCommandType=-1,e.curCommandRelative=!1,e.canParseCommandOrComma=!0,e.curNumberHasExp=!1,e.curNumberHasExpDigits=!1,e.curNumberHasDecimal=!1,e.curArgs=[],e}return $w(A,t),A.prototype.finish=function(e){if(e===void 0&&(e=[]),this.parse(" ",e),this.curArgs.length!==0||!this.canParseCommandOrComma)throw new SyntaxError("Unterminated command at the path end.");return e},A.prototype.parse=function(e,r){var n=this;r===void 0&&(r=[]);for(var i=function(d){r.push(d),n.curArgs.length=0,n.canParseCommandOrComma=!0},a=0;a<e.length;a++){var s=e[a],o=!(this.curCommandType!==CA.ARC||this.curArgs.length!==3&&this.curArgs.length!==4||this.curNumber.length!==1||this.curNumber!=="0"&&this.curNumber!=="1"),l=Zw(s)&&(this.curNumber==="0"&&s==="0"||o);if(!Zw(s)||l)if(s!=="e"&&s!=="E")if(s!=="-"&&s!=="+"||!this.curNumberHasExp||this.curNumberHasExpDigits)if(s!=="."||this.curNumberHasExp||this.curNumberHasDecimal||o){if(this.curNumber&&this.curCommandType!==-1){var f=Number(this.curNumber);if(isNaN(f))throw new SyntaxError("Invalid number ending at "+a);if(this.curCommandType===CA.ARC){if(this.curArgs.length===0||this.curArgs.length===1){if(0>f)throw new SyntaxError('Expected positive number, got "'+f+'" at index "'+a+'"')}else if((this.curArgs.length===3||this.curArgs.length===4)&&this.curNumber!=="0"&&this.curNumber!=="1")throw new SyntaxError('Expected a flag, got "'+this.curNumber+'" at index "'+a+'"')}this.curArgs.push(f),this.curArgs.length===cH[this.curCommandType]&&(CA.HORIZ_LINE_TO===this.curCommandType?i({type:CA.HORIZ_LINE_TO,relative:this.curCommandRelative,x:f}):CA.VERT_LINE_TO===this.curCommandType?i({type:CA.VERT_LINE_TO,relative:this.curCommandRelative,y:f}):this.curCommandType===CA.MOVE_TO||this.curCommandType===CA.LINE_TO||this.curCommandType===CA.SMOOTH_QUAD_TO?(i({type:this.curCommandType,relative:this.curCommandRelative,x:this.curArgs[0],y:this.curArgs[1]}),CA.MOVE_TO===this.curCommandType&&(this.curCommandType=CA.LINE_TO)):this.curCommandType===CA.CURVE_TO?i({type:CA.CURVE_TO,relative:this.curCommandRelative,x1:this.curArgs[0],y1:this.curArgs[1],x2:this.curArgs[2],y2:this.curArgs[3],x:this.curArgs[4],y:this.curArgs[5]}):this.curCommandType===CA.SMOOTH_CURVE_TO?i({type:CA.SMOOTH_CURVE_TO,relative:this.curCommandRelative,x2:this.curArgs[0],y2:this.curArgs[1],x:this.curArgs[2],y:this.curArgs[3]}):this.curCommandType===CA.QUAD_TO?i({type:CA.QUAD_TO,relative:this.curCommandRelative,x1:this.curArgs[0],y1:this.curArgs[1],x:this.curArgs[2],y:this.curArgs[3]}):this.curCommandType===CA.ARC&&i({type:CA.ARC,relative:this.curCommandRelative,rX:this.curArgs[0],rY:this.curArgs[1],xRot:this.curArgs[2],lArcFlag:this.curArgs[3],sweepFlag:this.curArgs[4],x:this.curArgs[5],y:this.curArgs[6]})),this.curNumber="",this.curNumberHasExpDigits=!1,this.curNumberHasExp=!1,this.curNumberHasDecimal=!1,this.canParseCommandOrComma=!0}if(!uH(s))if(s===","&&this.canParseCommandOrComma)this.canParseCommandOrComma=!1;else if(s!=="+"&&s!=="-"&&s!==".")if(l)this.curNumber=s,this.curNumberHasDecimal=!1;else{if(this.curArgs.length!==0)throw new SyntaxError("Unterminated command at index "+a+".");if(!this.canParseCommandOrComma)throw new SyntaxError('Unexpected character "'+s+'" at index '+a+". Command cannot follow comma");if(this.canParseCommandOrComma=!1,s!=="z"&&s!=="Z")if(s==="h"||s==="H")this.curCommandType=CA.HORIZ_LINE_TO,this.curCommandRelative=s==="h";else if(s==="v"||s==="V")this.curCommandType=CA.VERT_LINE_TO,this.curCommandRelative=s==="v";else if(s==="m"||s==="M")this.curCommandType=CA.MOVE_TO,this.curCommandRelative=s==="m";else if(s==="l"||s==="L")this.curCommandType=CA.LINE_TO,this.curCommandRelative=s==="l";else if(s==="c"||s==="C")this.curCommandType=CA.CURVE_TO,this.curCommandRelative=s==="c";else if(s==="s"||s==="S")this.curCommandType=CA.SMOOTH_CURVE_TO,this.curCommandRelative=s==="s";else if(s==="q"||s==="Q")this.curCommandType=CA.QUAD_TO,this.curCommandRelative=s===
|