@tscircuit/runframe 0.0.968 → 0.0.970

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5574,7 +5574,7 @@ $1`).replace(/>(\s*)(?=<!--\s*\/)/g,"> ")}}}),set={};H2n(set,{all_layers:()=>kye
5574
5574
  * Copyright (c) 2013-2015, 2017, Jon Schlinkert.
5575
5575
  * Released under the MIT License.
5576
5576
  *)
5577
- */const f3n=({containerClassName:t,...e})=>{const n=Ce.useRef(null),[i,r]=Ce.useState(620);return Ce.useLayoutEffect(()=>{const o=()=>{if(n.current){const a=n.current.clientHeight,c=window.innerHeight;r(Math.min(Math.max(a,620),c))}};o();const s=new ResizeObserver(o);return n.current&&s.observe(n.current),window.addEventListener("resize",o),()=>{s.disconnect(),window.removeEventListener("resize",o)}},[]),ye.jsx("div",{ref:n,className:t||"rf-w-full rf-h-full",children:ye.jsx(p3n,{...e,height:i})})},m3n='*,:after,:before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }/*! tailwindcss v3.4.17 | MIT License | https://tailwindcss.com*/*,:after,:before{border:0 solid #e5e7eb;box-sizing:border-box}:after,:before{--tw-content:""}:host,html{line-height:1.5;-webkit-text-size-adjust:100%;font-family:ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-feature-settings:normal;font-variation-settings:normal;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-tap-highlight-color:transparent}body{line-height:inherit;margin:0}hr{border-top-width:1px;color:inherit;height:0}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-size:1em;font-variation-settings:normal}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-collapse:collapse;border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{color:inherit;font-family:inherit;font-feature-settings:inherit;font-size:100%;font-variation-settings:inherit;font-weight:inherit;letter-spacing:inherit;line-height:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{color:#9ca3af;opacity:1}input::placeholder,textarea::placeholder{color:#9ca3af;opacity:1}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]:where(:not([hidden=until-found])){display:none}:root{--radius:0.5rem}.rf-pointer-events-none{pointer-events:none}.rf-invisible{visibility:hidden}.rf-fixed{position:fixed}.rf-absolute{position:absolute}.rf-relative{position:relative}.rf-inset-0{inset:0}.-rf-left-2{left:-.5rem}.-rf-right-10{right:-2.5rem}.-rf-right-2{right:-.5rem}.-rf-right-4{right:-1rem}.-rf-right-6{right:-1.5rem}.-rf-right-7{right:-1.75rem}.-rf-right-8{right:-2rem}.-rf-right-9{right:-2.25rem}.rf-bottom-full{bottom:100%}.rf-left-0{left:0}.rf-left-1{left:.25rem}.rf-left-1\\/2{left:50%}.rf-left-2{left:.5rem}.rf-left-\\[50\\%\\]{left:50%}.rf-right-0{right:0}.rf-right-1{right:.25rem}.rf-right-4{right:1rem}.rf-right-\\[4px\\]{right:4px}.rf-top-0{top:0}.rf-top-1{top:.25rem}.rf-top-2{top:.5rem}.rf-top-2\\.5{top:.625rem}.rf-top-\\[50\\%\\]{top:50%}.rf-top-\\[6px\\]{top:6px}.\\!rf-z-\\[101\\]{z-index:101!important}.\\!rf-z-\\[200\\]{z-index:200!important}.rf-z-10{z-index:10}.rf-z-50{z-index:50}.rf-z-\\[100\\]{z-index:100}.rf-z-\\[101\\]{z-index:101}.rf-order-1{order:1}.rf-order-2{order:2}.rf-order-3{order:3}.rf-m-1{margin:.25rem}.rf-m-6{margin:1.5rem}.-rf-mx-1,.rf--mx-1{margin-left:-.25rem;margin-right:-.25rem}.rf-mx-1{margin-left:.25rem;margin-right:.25rem}.rf-mx-2{margin-left:.5rem;margin-right:.5rem}.rf-mx-4{margin-left:1rem;margin-right:1rem}.rf-mx-auto{margin-left:auto;margin-right:auto}.rf-my-1{margin-bottom:.25rem;margin-top:.25rem}.rf-my-12{margin-bottom:3rem;margin-top:3rem}.rf-my-4{margin-bottom:1rem;margin-top:1rem}.rf-my-auto{margin-bottom:auto;margin-top:auto}.rf-mb-1{margin-bottom:.25rem}.rf-mb-12{margin-bottom:3rem}.rf-mb-2{margin-bottom:.5rem}.rf-mb-3{margin-bottom:.75rem}.rf-mb-4{margin-bottom:1rem}.rf-mb-6{margin-bottom:1.5rem}.rf-mb-8{margin-bottom:2rem}.rf-ml-1{margin-left:.25rem}.rf-ml-2{margin-left:.5rem}.rf-ml-auto{margin-left:auto}.rf-mr-1{margin-right:.25rem}.rf-mr-2{margin-right:.5rem}.rf-mt-0{margin-top:0}.rf-mt-0\\.5{margin-top:.125rem}.rf-mt-1{margin-top:.25rem}.rf-mt-2{margin-top:.5rem}.rf-mt-3{margin-top:.75rem}.rf-mt-4{margin-top:1rem}.rf-mt-5{margin-top:1.25rem}.rf-mt-auto{margin-top:auto}.rf-block{display:block}.rf-inline-block{display:inline-block}.rf-inline{display:inline}.rf-flex{display:flex}.rf-inline-flex{display:inline-flex}.rf-grid{display:grid}.rf-hidden{display:none}.rf-aspect-square{aspect-ratio:1/1}.rf-aspect-video{aspect-ratio:16/9}.rf-size-14{height:3.5rem;width:3.5rem}.rf-size-4{height:1rem;width:1rem}.\\!rf-h-2{height:.5rem!important}.\\!rf-h-2\\.5{height:.625rem!important}.\\!rf-h-3{height:.75rem!important}.\\!rf-h-full{height:100%!important}.rf-h-1{height:.25rem}.rf-h-10{height:2.5rem}.rf-h-12{height:3rem}.rf-h-2{height:.5rem}.rf-h-2\\.5{height:.625rem}.rf-h-20{height:5rem}.rf-h-24{height:6rem}.rf-h-3{height:.75rem}.rf-h-3\\.5{height:.875rem}.rf-h-4{height:1rem}.rf-h-5{height:1.25rem}.rf-h-6{height:1.5rem}.rf-h-60{height:15rem}.rf-h-64{height:16rem}.rf-h-7{height:1.75rem}.rf-h-8{height:2rem}.rf-h-9{height:2.25rem}.rf-h-\\[400px\\]{height:400px}.rf-h-\\[calc\\(100vh-52px\\)\\]{height:calc(100vh - 52px)}.rf-h-\\[var\\(--radix-select-trigger-height\\)\\]{height:var(--radix-select-trigger-height)}.rf-h-auto{height:auto}.rf-h-fit{height:-moz-fit-content;height:fit-content}.rf-h-full{height:100%}.rf-h-px{height:1px}.rf-h-screen{height:100vh}.\\!rf-max-h-\\[40vh\\]{max-height:40vh!important}.rf-max-h-32{max-height:8rem}.rf-max-h-96{max-height:24rem}.rf-max-h-\\[200px\\]{max-height:200px}.rf-max-h-\\[300px\\]{max-height:300px}.rf-max-h-\\[500px\\]{max-height:500px}.rf-max-h-\\[70vh\\]{max-height:70vh}.rf-max-h-\\[90vh\\]{max-height:90vh}.rf-max-h-full{max-height:100%}.rf-min-h-0{min-height:0}.rf-min-h-\\[200px\\]{min-height:200px}.rf-min-h-\\[300px\\]{min-height:300px}.rf-min-h-\\[620px\\]{min-height:620px}.rf-min-h-\\[calc\\(100vh-240px\\)\\]{min-height:calc(100vh - 240px)}.\\!rf-w-2{width:.5rem!important}.\\!rf-w-2\\.5{width:.625rem!important}.rf-w-1{width:.25rem}.rf-w-1\\/2{width:50%}.rf-w-11{width:2.75rem}.rf-w-11\\/12{width:91.666667%}.rf-w-12{width:3rem}.rf-w-16{width:4rem}.rf-w-2{width:.5rem}.rf-w-2\\.5{width:.625rem}.rf-w-20{width:5rem}.rf-w-24{width:6rem}.rf-w-28{width:7rem}.rf-w-3{width:.75rem}.rf-w-3\\.5{width:.875rem}.rf-w-32{width:8rem}.rf-w-4{width:1rem}.rf-w-40{width:10rem}.rf-w-48{width:12rem}.rf-w-5{width:1.25rem}.rf-w-6{width:1.5rem}.rf-w-64{width:16rem}.rf-w-72{width:18rem}.rf-w-8{width:2rem}.rf-w-80{width:20rem}.rf-w-9{width:2.25rem}.rf-w-96{width:24rem}.rf-w-\\[400px\\]{width:400px}.rf-w-\\[95\\%\\]{width:95%}.rf-w-fit{width:-moz-fit-content;width:fit-content}.rf-w-full{width:100%}.rf-w-screen{width:100vw}.rf-min-w-0{min-width:0}.rf-min-w-10{min-width:2.5rem}.rf-min-w-16{min-width:4rem}.rf-min-w-32{min-width:8rem}.rf-min-w-80{min-width:20rem}.rf-min-w-96{min-width:24rem}.rf-min-w-\\[148px\\]{min-width:148px}.rf-min-w-\\[400px\\]{min-width:400px}.rf-min-w-\\[8rem\\]{min-width:8rem}.rf-min-w-\\[var\\(--radix-select-trigger-width\\)\\]{min-width:var(--radix-select-trigger-width)}.\\!rf-max-w-\\[660px\\]{max-width:660px!important}.rf-max-w-2xl{max-width:42rem}.rf-max-w-3xl{max-width:48rem}.rf-max-w-4xl{max-width:56rem}.rf-max-w-5xl{max-width:64rem}.rf-max-w-64{max-width:16rem}.rf-max-w-96{max-width:24rem}.rf-max-w-\\[100px\\]{max-width:100px}.rf-max-w-\\[120px\\]{max-width:120px}.rf-max-w-\\[150px\\]{max-width:150px}.rf-max-w-\\[400px\\]{max-width:400px}.rf-max-w-full{max-width:100%}.rf-max-w-lg{max-width:32rem}.rf-max-w-md{max-width:28rem}.rf-max-w-none{max-width:none}.rf-max-w-xl{max-width:36rem}.rf-max-w-xs{max-width:20rem}.rf-flex-1{flex:1 1 0%}.rf-flex-shrink-0,.rf-shrink-0{flex-shrink:0}.rf-flex-grow{flex-grow:1}.rf-table-auto{table-layout:auto}.rf-origin-\\[--radix-popover-content-transform-origin\\]{transform-origin:var(--radix-popover-content-transform-origin)}.-rf-translate-x-1{--tw-translate-x:-0.25rem}.-rf-translate-x-1,.-rf-translate-x-1\\/2{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-rf-translate-x-1\\/2{--tw-translate-x:-50%}.-rf-translate-y-1{--tw-translate-y:-0.25rem}.-rf-translate-y-1,.rf--translate-x-1{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rf--translate-x-1{--tw-translate-x:-0.25rem}.rf--translate-x-1\\/2{--tw-translate-x:-50%}.rf--translate-x-1\\/2,.rf--translate-y-1{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rf--translate-y-1{--tw-translate-y:-0.25rem}.rf-translate-x-\\[-50\\%\\]{--tw-translate-x:-50%}.rf-translate-x-\\[-50\\%\\],.rf-translate-y-\\[-50\\%\\]{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rf-translate-y-\\[-50\\%\\]{--tw-translate-y:-50%}.rf-transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes rf-pulse{50%{opacity:.5}}.rf-animate-pulse{animation:rf-pulse 2s cubic-bezier(.4,0,.6,1) infinite}@keyframes rf-spin{to{transform:rotate(1turn)}}.rf-animate-spin{animation:rf-spin 1s linear infinite}.rf-cursor-default{cursor:default}.rf-cursor-not-allowed{cursor:not-allowed}.rf-cursor-pointer{cursor:pointer}.rf-select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.rf-grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.rf-grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.rf-grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.rf-flex-row{flex-direction:row}.rf-flex-col{flex-direction:column}.rf-flex-col-reverse{flex-direction:column-reverse}.rf-flex-wrap{flex-wrap:wrap}.rf-place-items-center{place-items:center}.rf-items-start{align-items:flex-start}.rf-items-end{align-items:flex-end}.rf-items-center{align-items:center}.rf-items-stretch{align-items:stretch}.rf-justify-end{justify-content:flex-end}.rf-justify-center{justify-content:center}.rf-justify-between{justify-content:space-between}.rf-gap-0{gap:0}.rf-gap-1{gap:.25rem}.rf-gap-2{gap:.5rem}.rf-gap-3{gap:.75rem}.rf-gap-4{gap:1rem}.rf-gap-5{gap:1.25rem}.rf-gap-6{gap:1.5rem}.rf-gap-8{gap:2rem}.rf-space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(.5rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(.5rem*var(--tw-space-x-reverse))}.rf-space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(.5rem*var(--tw-space-y-reverse));margin-top:calc(.5rem*(1 - var(--tw-space-y-reverse)))}.rf-space-y-3>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(.75rem*var(--tw-space-y-reverse));margin-top:calc(.75rem*(1 - var(--tw-space-y-reverse)))}.rf-space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(1rem*var(--tw-space-y-reverse));margin-top:calc(1rem*(1 - var(--tw-space-y-reverse)))}.rf-space-y-6>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(1.5rem*var(--tw-space-y-reverse));margin-top:calc(1.5rem*(1 - var(--tw-space-y-reverse)))}.rf-divide-y>:not([hidden])~:not([hidden]){--tw-divide-y-reverse:0;border-bottom-width:calc(1px*var(--tw-divide-y-reverse));border-top-width:calc(1px*(1 - var(--tw-divide-y-reverse)))}.rf-overflow-auto{overflow:auto}.rf-overflow-hidden{overflow:hidden}.rf-overflow-visible{overflow:visible}.\\!rf-overflow-x-auto{overflow-x:auto!important}.rf-overflow-x-auto{overflow-x:auto}.\\!rf-overflow-y-auto{overflow-y:auto!important}.rf-overflow-y-auto{overflow-y:auto}.rf-overflow-x-hidden{overflow-x:hidden}.rf-overflow-x-clip{overflow-x:clip}.rf-truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.rf-whitespace-normal{white-space:normal}.rf-whitespace-nowrap{white-space:nowrap}.rf-whitespace-pre-wrap{white-space:pre-wrap}.rf-break-words{overflow-wrap:break-word}.rf-break-all{word-break:break-all}.rf-rounded{border-radius:.25rem}.rf-rounded-2xl{border-radius:1rem}.rf-rounded-full{border-radius:9999px}.rf-rounded-lg{border-radius:var(--radius)}.rf-rounded-md{border-radius:calc(var(--radius) - 2px)}.rf-rounded-sm{border-radius:calc(var(--radius) - 4px)}.rf-rounded-xl{border-radius:.75rem}.rf-border{border-width:1px}.rf-border-2{border-width:2px}.rf-border-b{border-bottom-width:1px}.rf-border-t{border-top-width:1px}.rf-border-none{border-style:none}.rf-border-blue-200{--tw-border-opacity:1;border-color:rgb(191 219 254/var(--tw-border-opacity,1))}.rf-border-blue-400{--tw-border-opacity:1;border-color:rgb(96 165 250/var(--tw-border-opacity,1))}.rf-border-blue-500{--tw-border-opacity:1;border-color:rgb(59 130 246/var(--tw-border-opacity,1))}.rf-border-blue-600{--tw-border-opacity:1;border-color:rgb(37 99 235/var(--tw-border-opacity,1))}.rf-border-gray-200{--tw-border-opacity:1;border-color:rgb(229 231 235/var(--tw-border-opacity,1))}.rf-border-gray-300{--tw-border-opacity:1;border-color:rgb(209 213 219/var(--tw-border-opacity,1))}.rf-border-green-200{--tw-border-opacity:1;border-color:rgb(187 247 208/var(--tw-border-opacity,1))}.rf-border-green-400{--tw-border-opacity:1;border-color:rgb(74 222 128/var(--tw-border-opacity,1))}.rf-border-input{border-color:hsl(var(--input))}.rf-border-neutral-200{--tw-border-opacity:1;border-color:rgb(229 229 229/var(--tw-border-opacity,1))}.rf-border-orange-200{--tw-border-opacity:1;border-color:rgb(254 215 170/var(--tw-border-opacity,1))}.rf-border-primary{border-color:hsl(var(--primary))}.rf-border-red-200{--tw-border-opacity:1;border-color:rgb(254 202 202/var(--tw-border-opacity,1))}.rf-border-red-400{--tw-border-opacity:1;border-color:rgb(248 113 113/var(--tw-border-opacity,1))}.rf-border-red-500{--tw-border-opacity:1;border-color:rgb(239 68 68/var(--tw-border-opacity,1))}.rf-border-zinc-200{--tw-border-opacity:1;border-color:rgb(228 228 231/var(--tw-border-opacity,1))}.rf-border-zinc-900{--tw-border-opacity:1;border-color:rgb(24 24 27/var(--tw-border-opacity,1))}.rf-bg-background{background-color:hsl(var(--background))}.rf-bg-black{--tw-bg-opacity:1;background-color:rgb(0 0 0/var(--tw-bg-opacity,1))}.rf-bg-black\\/80{background-color:rgba(0,0,0,.8)}.rf-bg-blue-100{--tw-bg-opacity:1;background-color:rgb(219 234 254/var(--tw-bg-opacity,1))}.rf-bg-blue-50{--tw-bg-opacity:1;background-color:rgb(239 246 255/var(--tw-bg-opacity,1))}.rf-bg-blue-500{--tw-bg-opacity:1;background-color:rgb(59 130 246/var(--tw-bg-opacity,1))}.rf-bg-blue-600{--tw-bg-opacity:1;background-color:rgb(37 99 235/var(--tw-bg-opacity,1))}.rf-bg-gray-100{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity,1))}.rf-bg-gray-200{--tw-bg-opacity:1;background-color:rgb(229 231 235/var(--tw-bg-opacity,1))}.rf-bg-gray-300{--tw-bg-opacity:1;background-color:rgb(209 213 219/var(--tw-bg-opacity,1))}.rf-bg-gray-400{--tw-bg-opacity:1;background-color:rgb(156 163 175/var(--tw-bg-opacity,1))}.rf-bg-gray-50{--tw-bg-opacity:1;background-color:rgb(249 250 251/var(--tw-bg-opacity,1))}.rf-bg-gray-500{--tw-bg-opacity:1;background-color:rgb(107 114 128/var(--tw-bg-opacity,1))}.rf-bg-gray-700{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity,1))}.rf-bg-gray-800{--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity,1))}.rf-bg-gray-900{--tw-bg-opacity:1;background-color:rgb(17 24 39/var(--tw-bg-opacity,1))}.rf-bg-green-100{--tw-bg-opacity:1;background-color:rgb(220 252 231/var(--tw-bg-opacity,1))}.rf-bg-green-50{--tw-bg-opacity:1;background-color:rgb(240 253 244/var(--tw-bg-opacity,1))}.rf-bg-muted{background-color:hsl(var(--muted))}.rf-bg-neutral-100{--tw-bg-opacity:1;background-color:rgb(245 245 245/var(--tw-bg-opacity,1))}.rf-bg-neutral-50{--tw-bg-opacity:1;background-color:rgb(250 250 250/var(--tw-bg-opacity,1))}.rf-bg-neutral-800{--tw-bg-opacity:1;background-color:rgb(38 38 38/var(--tw-bg-opacity,1))}.rf-bg-neutral-900{--tw-bg-opacity:1;background-color:rgb(23 23 23/var(--tw-bg-opacity,1))}.rf-bg-orange-400{--tw-bg-opacity:1;background-color:rgb(251 146 60/var(--tw-bg-opacity,1))}.rf-bg-orange-50{--tw-bg-opacity:1;background-color:rgb(255 247 237/var(--tw-bg-opacity,1))}.rf-bg-popover{background-color:hsl(var(--popover))}.rf-bg-red-100{--tw-bg-opacity:1;background-color:rgb(254 226 226/var(--tw-bg-opacity,1))}.rf-bg-red-50{--tw-bg-opacity:1;background-color:rgb(254 242 242/var(--tw-bg-opacity,1))}.rf-bg-red-500{--tw-bg-opacity:1;background-color:rgb(239 68 68/var(--tw-bg-opacity,1))}.rf-bg-red-900{--tw-bg-opacity:1;background-color:rgb(127 29 29/var(--tw-bg-opacity,1))}.rf-bg-slate-50{--tw-bg-opacity:1;background-color:rgb(248 250 252/var(--tw-bg-opacity,1))}.rf-bg-transparent{background-color:transparent}.rf-bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity,1))}.rf-bg-yellow-100{--tw-bg-opacity:1;background-color:rgb(254 249 195/var(--tw-bg-opacity,1))}.rf-bg-zinc-100{--tw-bg-opacity:1;background-color:rgb(244 244 245/var(--tw-bg-opacity,1))}.rf-bg-zinc-200{--tw-bg-opacity:1;background-color:rgb(228 228 231/var(--tw-bg-opacity,1))}.rf-bg-zinc-50{--tw-bg-opacity:1;background-color:rgb(250 250 250/var(--tw-bg-opacity,1))}.rf-bg-zinc-800{--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.rf-bg-zinc-900{--tw-bg-opacity:1;background-color:rgb(24 24 27/var(--tw-bg-opacity,1))}.rf-bg-opacity-50{--tw-bg-opacity:0.5}.rf-fill-current{fill:currentColor}.rf-object-contain{-o-object-fit:contain;object-fit:contain}.rf-object-cover{-o-object-fit:cover;object-fit:cover}.\\!rf-p-0{padding:0!important}.rf-p-0{padding:0}.rf-p-1{padding:.25rem}.rf-p-2{padding:.5rem}.rf-p-3{padding:.75rem}.rf-p-4{padding:1rem}.rf-p-5{padding:1.25rem}.rf-p-6{padding:1.5rem}.rf-p-8{padding:2rem}.rf-px-1{padding-left:.25rem;padding-right:.25rem}.rf-px-2{padding-left:.5rem;padding-right:.5rem}.rf-px-3{padding-left:.75rem;padding-right:.75rem}.rf-px-4{padding-left:1rem;padding-right:1rem}.rf-px-6{padding-left:1.5rem;padding-right:1.5rem}.rf-px-8{padding-left:2rem;padding-right:2rem}.rf-py-0{padding-bottom:0;padding-top:0}.rf-py-0\\.5{padding-bottom:.125rem;padding-top:.125rem}.rf-py-1{padding-bottom:.25rem;padding-top:.25rem}.rf-py-1\\.5{padding-bottom:.375rem;padding-top:.375rem}.rf-py-10{padding-bottom:2.5rem;padding-top:2.5rem}.rf-py-12{padding-bottom:3rem;padding-top:3rem}.rf-py-2{padding-bottom:.5rem;padding-top:.5rem}.rf-py-3{padding-bottom:.75rem;padding-top:.75rem}.rf-py-4{padding-bottom:1rem;padding-top:1rem}.rf-py-6{padding-bottom:1.5rem;padding-top:1.5rem}.rf-py-8{padding-bottom:2rem;padding-top:2rem}.rf-pb-0{padding-bottom:0}.rf-pb-1{padding-bottom:.25rem}.rf-pb-2{padding-bottom:.5rem}.rf-pb-3{padding-bottom:.75rem}.rf-pb-4{padding-bottom:1rem}.rf-pl-2{padding-left:.5rem}.rf-pl-4{padding-left:1rem}.rf-pl-8{padding-left:2rem}.rf-pr-2{padding-right:.5rem}.rf-pt-0{padding-top:0}.rf-pt-2{padding-top:.5rem}.rf-pt-4{padding-top:1rem}.rf-text-left{text-align:left}.rf-text-center{text-align:center}.rf-text-right{text-align:right}.rf-font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.rf-text-2xl{font-size:1.5rem;line-height:2rem}.rf-text-3xl{font-size:1.875rem;line-height:2.25rem}.rf-text-\\[8px\\]{font-size:8px}.rf-text-base{font-size:1rem;line-height:1.5rem}.rf-text-lg{font-size:1.125rem;line-height:1.75rem}.rf-text-sm{font-size:.875rem;line-height:1.25rem}.rf-text-xl{font-size:1.25rem;line-height:1.75rem}.rf-text-xs{font-size:.75rem;line-height:1rem}.\\!rf-font-normal{font-weight:400!important}.rf-font-bold{font-weight:700}.rf-font-medium{font-weight:500}.rf-font-semibold{font-weight:600}.rf-uppercase{text-transform:uppercase}.rf-capitalize{text-transform:capitalize}.rf-tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}.rf-leading-5{line-height:1.25rem}.rf-leading-none{line-height:1}.rf-leading-relaxed{line-height:1.625}.rf-leading-tight{line-height:1.25}.rf-tracking-wide{letter-spacing:.025em}.rf-tracking-widest{letter-spacing:.1em}.rf-text-black{--tw-text-opacity:1;color:rgb(0 0 0/var(--tw-text-opacity,1))}.rf-text-blue-500{--tw-text-opacity:1;color:rgb(59 130 246/var(--tw-text-opacity,1))}.rf-text-blue-600{--tw-text-opacity:1;color:rgb(37 99 235/var(--tw-text-opacity,1))}.rf-text-blue-700{--tw-text-opacity:1;color:rgb(29 78 216/var(--tw-text-opacity,1))}.rf-text-blue-800{--tw-text-opacity:1;color:rgb(30 64 175/var(--tw-text-opacity,1))}.rf-text-blue-900{--tw-text-opacity:1;color:rgb(30 58 138/var(--tw-text-opacity,1))}.rf-text-current{color:currentColor}.rf-text-gray-300{--tw-text-opacity:1;color:rgb(209 213 219/var(--tw-text-opacity,1))}.rf-text-gray-400{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity,1))}.rf-text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity,1))}.rf-text-gray-600{--tw-text-opacity:1;color:rgb(75 85 99/var(--tw-text-opacity,1))}.rf-text-gray-700{--tw-text-opacity:1;color:rgb(55 65 81/var(--tw-text-opacity,1))}.rf-text-gray-800{--tw-text-opacity:1;color:rgb(31 41 55/var(--tw-text-opacity,1))}.rf-text-gray-900{--tw-text-opacity:1;color:rgb(17 24 39/var(--tw-text-opacity,1))}.rf-text-green-500{--tw-text-opacity:1;color:rgb(34 197 94/var(--tw-text-opacity,1))}.rf-text-green-600{--tw-text-opacity:1;color:rgb(22 163 74/var(--tw-text-opacity,1))}.rf-text-green-700{--tw-text-opacity:1;color:rgb(21 128 61/var(--tw-text-opacity,1))}.rf-text-green-800{--tw-text-opacity:1;color:rgb(22 101 52/var(--tw-text-opacity,1))}.rf-text-green-900{--tw-text-opacity:1;color:rgb(20 83 45/var(--tw-text-opacity,1))}.rf-text-muted-foreground{color:hsl(var(--muted-foreground))}.rf-text-neutral-50{--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.rf-text-neutral-500{--tw-text-opacity:1;color:rgb(115 115 115/var(--tw-text-opacity,1))}.rf-text-neutral-900{--tw-text-opacity:1;color:rgb(23 23 23/var(--tw-text-opacity,1))}.rf-text-neutral-950{--tw-text-opacity:1;color:rgb(10 10 10/var(--tw-text-opacity,1))}.rf-text-orange-500{--tw-text-opacity:1;color:rgb(249 115 22/var(--tw-text-opacity,1))}.rf-text-orange-600{--tw-text-opacity:1;color:rgb(234 88 12/var(--tw-text-opacity,1))}.rf-text-orange-800{--tw-text-opacity:1;color:rgb(154 52 18/var(--tw-text-opacity,1))}.rf-text-popover-foreground{color:hsl(var(--popover-foreground))}.rf-text-red-200{--tw-text-opacity:1;color:rgb(254 202 202/var(--tw-text-opacity,1))}.rf-text-red-300{--tw-text-opacity:1;color:rgb(252 165 165/var(--tw-text-opacity,1))}.rf-text-red-400{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity,1))}.rf-text-red-500{--tw-text-opacity:1;color:rgb(239 68 68/var(--tw-text-opacity,1))}.rf-text-red-600{--tw-text-opacity:1;color:rgb(220 38 38/var(--tw-text-opacity,1))}.rf-text-red-700{--tw-text-opacity:1;color:rgb(185 28 28/var(--tw-text-opacity,1))}.rf-text-red-800{--tw-text-opacity:1;color:rgb(153 27 27/var(--tw-text-opacity,1))}.rf-text-red-900{--tw-text-opacity:1;color:rgb(127 29 29/var(--tw-text-opacity,1))}.rf-text-slate-500{--tw-text-opacity:1;color:rgb(100 116 139/var(--tw-text-opacity,1))}.rf-text-slate-600{--tw-text-opacity:1;color:rgb(71 85 105/var(--tw-text-opacity,1))}.rf-text-slate-800{--tw-text-opacity:1;color:rgb(30 41 59/var(--tw-text-opacity,1))}.rf-text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity,1))}.rf-text-yellow-400{--tw-text-opacity:1;color:rgb(250 204 21/var(--tw-text-opacity,1))}.rf-text-yellow-500{--tw-text-opacity:1;color:rgb(234 179 8/var(--tw-text-opacity,1))}.rf-text-yellow-600{--tw-text-opacity:1;color:rgb(202 138 4/var(--tw-text-opacity,1))}.rf-text-yellow-900{--tw-text-opacity:1;color:rgb(113 63 18/var(--tw-text-opacity,1))}.rf-text-zinc-200{--tw-text-opacity:1;color:rgb(228 228 231/var(--tw-text-opacity,1))}.rf-text-zinc-300{--tw-text-opacity:1;color:rgb(212 212 216/var(--tw-text-opacity,1))}.rf-text-zinc-400{--tw-text-opacity:1;color:rgb(161 161 170/var(--tw-text-opacity,1))}.rf-text-zinc-50{--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.rf-text-zinc-500{--tw-text-opacity:1;color:rgb(113 113 122/var(--tw-text-opacity,1))}.rf-text-zinc-900{--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}.rf-text-zinc-950{--tw-text-opacity:1;color:rgb(9 9 11/var(--tw-text-opacity,1))}.rf-underline{text-decoration-line:underline}.rf-line-through{text-decoration-line:line-through}.rf-underline-offset-4{text-underline-offset:4px}.rf-opacity-0{opacity:0}.rf-opacity-100{opacity:1}.rf-opacity-25{opacity:.25}.rf-opacity-30{opacity:.3}.rf-opacity-50{opacity:.5}.rf-opacity-60{opacity:.6}.rf-opacity-75{opacity:.75}.rf-shadow{--tw-shadow:0 1px 3px 0 rgba(0,0,0,.1),0 1px 2px -1px rgba(0,0,0,.1);--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color)}.rf-shadow,.rf-shadow-lg{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.rf-shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color)}.rf-shadow-md{--tw-shadow:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -2px rgba(0,0,0,.1);--tw-shadow-colored:0 4px 6px -1px var(--tw-shadow-color),0 2px 4px -2px var(--tw-shadow-color)}.rf-shadow-md,.rf-shadow-sm{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.rf-shadow-sm{--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color)}.rf-outline-none{outline:2px solid transparent;outline-offset:2px}.rf-ring-2{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.rf-ring-blue-500{--tw-ring-opacity:1;--tw-ring-color:rgb(59 130 246/var(--tw-ring-opacity,1))}.rf-ring-primary{--tw-ring-color:hsl(var(--primary))}.rf-ring-offset-background{--tw-ring-offset-color:hsl(var(--background))}.rf-ring-offset-white{--tw-ring-offset-color:#fff}.rf-transition{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}.rf-transition-all{transition-duration:.15s;transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1)}.rf-transition-colors{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1)}.rf-transition-opacity{transition-duration:.15s;transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1)}.rf-duration-200{transition-duration:.2s}.rf-ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}@keyframes enter{0%{opacity:var(--tw-enter-opacity,1);transform:translate3d(var(--tw-enter-translate-x,0),var(--tw-enter-translate-y,0),0) scale3d(var(--tw-enter-scale,1),var(--tw-enter-scale,1),var(--tw-enter-scale,1)) rotate(var(--tw-enter-rotate,0))}}@keyframes exit{to{opacity:var(--tw-exit-opacity,1);transform:translate3d(var(--tw-exit-translate-x,0),var(--tw-exit-translate-y,0),0) scale3d(var(--tw-exit-scale,1),var(--tw-exit-scale,1),var(--tw-exit-scale,1)) rotate(var(--tw-exit-rotate,0))}}.rf-slide-in-from-left-1{--tw-enter-translate-x:-0.25rem}.rf-slide-out-to-left-1{--tw-exit-translate-x:-0.25rem}.rf-duration-200{animation-duration:.2s}.rf-ease-in-out{animation-timing-function:cubic-bezier(.4,0,.2,1)}.file\\:rf-border-0::file-selector-button{border-width:0}.file\\:rf-bg-transparent::file-selector-button{background-color:transparent}.file\\:rf-text-sm::file-selector-button{font-size:.875rem;line-height:1.25rem}.file\\:rf-font-medium::file-selector-button{font-weight:500}.placeholder\\:rf-text-zinc-500::-moz-placeholder{--tw-text-opacity:1;color:rgb(113 113 122/var(--tw-text-opacity,1))}.placeholder\\:rf-text-zinc-500::placeholder{--tw-text-opacity:1;color:rgb(113 113 122/var(--tw-text-opacity,1))}.hover\\:rf-border-blue-300:hover{--tw-border-opacity:1;border-color:rgb(147 197 253/var(--tw-border-opacity,1))}.hover\\:\\!rf-bg-transparent:hover{background-color:transparent!important}.hover\\:rf-bg-blue-700:hover{--tw-bg-opacity:1;background-color:rgb(29 78 216/var(--tw-bg-opacity,1))}.hover\\:rf-bg-red-500\\/90:hover{background-color:rgba(239,68,68,.9)}.hover\\:rf-bg-zinc-100:hover{--tw-bg-opacity:1;background-color:rgb(244 244 245/var(--tw-bg-opacity,1))}.hover\\:rf-bg-zinc-100\\/80:hover{background-color:hsla(240,5%,96%,.8)}.hover\\:rf-bg-zinc-900\\/90:hover{background-color:rgba(24,24,27,.9)}.hover\\:rf-text-blue-800:hover{--tw-text-opacity:1;color:rgb(30 64 175/var(--tw-text-opacity,1))}.hover\\:rf-text-red-400:hover{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity,1))}.hover\\:rf-text-slate-900:hover{--tw-text-opacity:1;color:rgb(15 23 42/var(--tw-text-opacity,1))}.hover\\:rf-text-zinc-900:hover{--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}.hover\\:rf-underline:hover{text-decoration-line:underline}.focus\\:rf-bg-gray-100:focus{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity,1))}.focus\\:rf-bg-zinc-100:focus{--tw-bg-opacity:1;background-color:rgb(244 244 245/var(--tw-bg-opacity,1))}.focus\\:rf-text-gray-900:focus{--tw-text-opacity:1;color:rgb(17 24 39/var(--tw-text-opacity,1))}.focus\\:rf-text-zinc-900:focus{--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}.focus\\:rf-outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\\:rf-ring-2:focus{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.focus\\:rf-ring-ring:focus{--tw-ring-color:hsl(var(--ring))}.focus\\:rf-ring-offset-2:focus{--tw-ring-offset-width:2px}.focus-visible\\:rf-outline-none:focus-visible{outline:2px solid transparent;outline-offset:2px}.focus-visible\\:rf-ring-1:focus-visible{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.focus-visible\\:rf-ring-2:focus-visible{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.focus-visible\\:rf-ring-zinc-950:focus-visible{--tw-ring-opacity:1;--tw-ring-color:rgb(9 9 11/var(--tw-ring-opacity,1))}.focus-visible\\:rf-ring-offset-2:focus-visible{--tw-ring-offset-width:2px}.disabled\\:rf-pointer-events-none:disabled{pointer-events:none}.disabled\\:rf-cursor-not-allowed:disabled{cursor:not-allowed}.disabled\\:rf-opacity-50:disabled{opacity:.5}.rf-group\\/bar:hover .group-hover\\/bar\\:rf-opacity-100{opacity:1}.data-\\[disabled\\=true\\]\\:rf-pointer-events-none[data-disabled=true],.data-\\[disabled\\]\\:rf-pointer-events-none[data-disabled]{pointer-events:none}.data-\\[side\\=bottom\\]\\:rf-translate-y-1[data-side=bottom]{--tw-translate-y:0.25rem}.data-\\[side\\=bottom\\]\\:rf-translate-y-1[data-side=bottom],.data-\\[side\\=left\\]\\:-rf-translate-x-1[data-side=left]{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.data-\\[side\\=left\\]\\:-rf-translate-x-1[data-side=left]{--tw-translate-x:-0.25rem}.data-\\[side\\=right\\]\\:rf-translate-x-1[data-side=right]{--tw-translate-x:0.25rem}.data-\\[side\\=right\\]\\:rf-translate-x-1[data-side=right],.data-\\[side\\=top\\]\\:-rf-translate-y-1[data-side=top]{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.data-\\[side\\=top\\]\\:-rf-translate-y-1[data-side=top]{--tw-translate-y:-0.25rem}.data-\\[selected\\=true\\]\\:rf-bg-zinc-100[data-selected=true]{--tw-bg-opacity:1;background-color:rgb(244 244 245/var(--tw-bg-opacity,1))}.data-\\[state\\=active\\]\\:rf-bg-white[data-state=active]{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity,1))}.data-\\[state\\=checked\\]\\:rf-bg-zinc-900[data-state=checked]{--tw-bg-opacity:1;background-color:rgb(24 24 27/var(--tw-bg-opacity,1))}.data-\\[state\\=open\\]\\:rf-bg-zinc-100[data-state=open]{--tw-bg-opacity:1;background-color:rgb(244 244 245/var(--tw-bg-opacity,1))}.data-\\[selected\\=true\\]\\:rf-text-zinc-900[data-selected=true]{--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}.data-\\[state\\=active\\]\\:rf-text-zinc-950[data-state=active]{--tw-text-opacity:1;color:rgb(9 9 11/var(--tw-text-opacity,1))}.data-\\[state\\=checked\\]\\:rf-text-zinc-50[data-state=checked]{--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.data-\\[disabled\\=true\\]\\:rf-opacity-50[data-disabled=true],.data-\\[disabled\\]\\:rf-opacity-50[data-disabled]{opacity:.5}.data-\\[state\\=active\\]\\:rf-shadow[data-state=active]{--tw-shadow:0 1px 3px 0 rgba(0,0,0,.1),0 1px 2px -1px rgba(0,0,0,.1);--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.data-\\[state\\=open\\]\\:rf-animate-in[data-state=open]{animation-duration:.15s;animation-name:enter;--tw-enter-opacity:initial;--tw-enter-scale:initial;--tw-enter-rotate:initial;--tw-enter-translate-x:initial;--tw-enter-translate-y:initial}.data-\\[state\\=closed\\]\\:rf-animate-out[data-state=closed]{animation-duration:.15s;animation-name:exit;--tw-exit-opacity:initial;--tw-exit-scale:initial;--tw-exit-rotate:initial;--tw-exit-translate-x:initial;--tw-exit-translate-y:initial}.data-\\[state\\=closed\\]\\:rf-fade-out-0[data-state=closed]{--tw-exit-opacity:0}.data-\\[state\\=open\\]\\:rf-fade-in-0[data-state=open]{--tw-enter-opacity:0}.data-\\[state\\=closed\\]\\:rf-zoom-out-95[data-state=closed]{--tw-exit-scale:.95}.data-\\[state\\=open\\]\\:rf-zoom-in-95[data-state=open]{--tw-enter-scale:.95}.data-\\[side\\=bottom\\]\\:rf-slide-in-from-top-2[data-side=bottom]{--tw-enter-translate-y:-0.5rem}.data-\\[side\\=left\\]\\:rf-slide-in-from-right-2[data-side=left]{--tw-enter-translate-x:0.5rem}.data-\\[side\\=right\\]\\:rf-slide-in-from-left-2[data-side=right]{--tw-enter-translate-x:-0.5rem}.data-\\[side\\=top\\]\\:rf-slide-in-from-bottom-2[data-side=top]{--tw-enter-translate-y:0.5rem}.data-\\[state\\=closed\\]\\:rf-slide-out-to-left-1\\/2[data-state=closed]{--tw-exit-translate-x:-50%}.data-\\[state\\=closed\\]\\:rf-slide-out-to-top-\\[48\\%\\][data-state=closed]{--tw-exit-translate-y:-48%}.data-\\[state\\=open\\]\\:rf-slide-in-from-left-1\\/2[data-state=open]{--tw-enter-translate-x:-50%}.data-\\[state\\=open\\]\\:rf-slide-in-from-top-\\[48\\%\\][data-state=open]{--tw-enter-translate-y:-48%}.dark\\:rf-border-zinc-50:is(.rf-dark *){--tw-border-opacity:1;border-color:rgb(250 250 250/var(--tw-border-opacity,1))}.dark\\:rf-border-zinc-800:is(.rf-dark *){--tw-border-opacity:1;border-color:rgb(39 39 42/var(--tw-border-opacity,1))}.dark\\:rf-bg-gray-700:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity,1))}.dark\\:rf-bg-gray-800:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity,1))}.dark\\:rf-bg-red-900:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(127 29 29/var(--tw-bg-opacity,1))}.dark\\:rf-bg-zinc-50:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(250 250 250/var(--tw-bg-opacity,1))}.dark\\:rf-bg-zinc-800:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.dark\\:rf-bg-zinc-950:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(9 9 11/var(--tw-bg-opacity,1))}.dark\\:rf-text-gray-500:is(.rf-dark *){--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity,1))}.dark\\:rf-text-zinc-400:is(.rf-dark *){--tw-text-opacity:1;color:rgb(161 161 170/var(--tw-text-opacity,1))}.dark\\:rf-text-zinc-50:is(.rf-dark *){--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.dark\\:rf-text-zinc-900:is(.rf-dark *){--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}.dark\\:rf-placeholder-zinc-400:is(.rf-dark *)::-moz-placeholder{--tw-placeholder-opacity:1;color:rgb(161 161 170/var(--tw-placeholder-opacity,1))}.dark\\:rf-placeholder-zinc-400:is(.rf-dark *)::placeholder{--tw-placeholder-opacity:1;color:rgb(161 161 170/var(--tw-placeholder-opacity,1))}.dark\\:rf-ring-offset-zinc-950:is(.rf-dark *){--tw-ring-offset-color:#09090b}.dark\\:placeholder\\:rf-text-zinc-400:is(.rf-dark *)::-moz-placeholder{--tw-text-opacity:1;color:rgb(161 161 170/var(--tw-text-opacity,1))}.dark\\:placeholder\\:rf-text-zinc-400:is(.rf-dark *)::placeholder{--tw-text-opacity:1;color:rgb(161 161 170/var(--tw-text-opacity,1))}.dark\\:hover\\:rf-bg-red-900\\/90:hover:is(.rf-dark *){background-color:rgba(127,29,29,.9)}.dark\\:hover\\:rf-bg-zinc-50\\/90:hover:is(.rf-dark *){background-color:hsla(0,0%,98%,.9)}.dark\\:hover\\:rf-bg-zinc-800:hover:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.dark\\:hover\\:rf-bg-zinc-800\\/80:hover:is(.rf-dark *){background-color:rgba(39,39,42,.8)}.dark\\:hover\\:rf-text-zinc-50:hover:is(.rf-dark *){--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.dark\\:focus\\:rf-bg-zinc-800:focus:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.dark\\:focus\\:rf-text-zinc-50:focus:is(.rf-dark *){--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.dark\\:focus-visible\\:rf-ring-zinc-300:focus-visible:is(.rf-dark *){--tw-ring-opacity:1;--tw-ring-color:rgb(212 212 216/var(--tw-ring-opacity,1))}.dark\\:data-\\[selected\\=true\\]\\:rf-bg-zinc-800[data-selected=true]:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.dark\\:data-\\[state\\=active\\]\\:rf-bg-zinc-950[data-state=active]:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(9 9 11/var(--tw-bg-opacity,1))}.dark\\:data-\\[state\\=checked\\]\\:rf-bg-zinc-50[data-state=checked]:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(250 250 250/var(--tw-bg-opacity,1))}.dark\\:data-\\[state\\=open\\]\\:rf-bg-zinc-800[data-state=open]:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.dark\\:data-\\[selected\\=true\\]\\:rf-text-zinc-50[data-selected=true]:is(.rf-dark *){--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.dark\\:data-\\[state\\=active\\]\\:rf-text-zinc-50[data-state=active]:is(.rf-dark *){--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.dark\\:data-\\[state\\=checked\\]\\:rf-text-zinc-900[data-state=checked]:is(.rf-dark *){--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}@media (min-width:640px){.sm\\:rf-order-1{order:1}.sm\\:rf-order-2{order:2}.sm\\:rf-mt-0{margin-top:0}.sm\\:rf-inline{display:inline}.sm\\:rf-grid{display:grid}.sm\\:rf-hidden{display:none}.sm\\:rf-w-auto{width:auto}.sm\\:rf-grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.sm\\:rf-grid-cols-\\[1fr_auto\\]{grid-template-columns:1fr auto}.sm\\:rf-flex-row{flex-direction:row}.sm\\:rf-items-center{align-items:center}.sm\\:rf-justify-end{justify-content:flex-end}.sm\\:rf-gap-3{gap:.75rem}.sm\\:rf-space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(.5rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(.5rem*var(--tw-space-x-reverse))}.sm\\:rf-rounded-lg{border-radius:var(--radius)}.sm\\:rf-px-4{padding-left:1rem;padding-right:1rem}.sm\\:rf-text-left{text-align:left}.sm\\:rf-text-sm{font-size:.875rem;line-height:1.25rem}.sm\\:rf-text-xl{font-size:1.25rem;line-height:1.75rem}}@media (min-width:768px){.md\\:rf-grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}}.\\[\\&\\>span\\]\\:rf-line-clamp-1>span{display:-webkit-box;overflow:hidden;-webkit-box-orient:vertical;-webkit-line-clamp:1}.\\[\\&\\>svg\\]\\:rf-size-4>svg{height:1rem;width:1rem}.\\[\\&\\>svg\\]\\:rf-shrink-0>svg{flex-shrink:0}.\\[\\&\\>svg\\]\\:rf-text-red-300>svg{--tw-text-opacity:1;color:rgb(252 165 165/var(--tw-text-opacity,1))}.\\[\\&\\>svg\\]\\:hover\\:rf-text-red-400:hover>svg{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity,1))}.\\[\\&_\\[cmdk-group-heading\\]\\]\\:rf-px-2 [cmdk-group-heading]{padding-left:.5rem;padding-right:.5rem}.\\[\\&_\\[cmdk-group-heading\\]\\]\\:rf-py-1\\.5 [cmdk-group-heading]{padding-bottom:.375rem;padding-top:.375rem}.\\[\\&_\\[cmdk-group-heading\\]\\]\\:rf-text-xs [cmdk-group-heading]{font-size:.75rem;line-height:1rem}.\\[\\&_\\[cmdk-group-heading\\]\\]\\:rf-font-medium [cmdk-group-heading]{font-weight:500}.\\[\\&_\\[cmdk-group-heading\\]\\]\\:rf-text-zinc-500 [cmdk-group-heading]{--tw-text-opacity:1;color:rgb(113 113 122/var(--tw-text-opacity,1))}.dark\\:\\[\\&_\\[cmdk-group-heading\\]\\]\\:rf-text-zinc-400 [cmdk-group-heading]:is(.rf-dark *){--tw-text-opacity:1;color:rgb(161 161 170/var(--tw-text-opacity,1))}.\\[\\&_\\[cmdk-group\\]\\:not\\(\\[hidden\\]\\)_\\~\\[cmdk-group\\]\\]\\:rf-pt-0 [cmdk-group]:not([hidden])~[cmdk-group]{padding-top:0}.\\[\\&_\\[cmdk-group\\]\\]\\:rf-px-2 [cmdk-group]{padding-left:.5rem;padding-right:.5rem}.\\[\\&_\\[cmdk-input-wrapper\\]_svg\\]\\:rf-h-5 [cmdk-input-wrapper] svg{height:1.25rem}.\\[\\&_\\[cmdk-input-wrapper\\]_svg\\]\\:rf-w-5 [cmdk-input-wrapper] svg{width:1.25rem}.\\[\\&_\\[cmdk-input\\]\\]\\:rf-h-12 [cmdk-input]{height:3rem}.\\[\\&_\\[cmdk-item\\]\\]\\:rf-px-2 [cmdk-item]{padding-left:.5rem;padding-right:.5rem}.\\[\\&_\\[cmdk-item\\]\\]\\:rf-py-3 [cmdk-item]{padding-bottom:.75rem;padding-top:.75rem}.\\[\\&_\\[cmdk-item\\]_svg\\]\\:rf-h-5 [cmdk-item] svg{height:1.25rem}.\\[\\&_\\[cmdk-item\\]_svg\\]\\:rf-w-5 [cmdk-item] svg{width:1.25rem}.\\[\\&_svg\\]\\:rf-pointer-events-none svg{pointer-events:none}.\\[\\&_svg\\]\\:rf-size-4 svg{height:1rem;width:1rem}.\\[\\&_svg\\]\\:rf-shrink-0 svg{flex-shrink:0}',_3n=()=>{Ce.useEffect(()=>{if(document.querySelector('style[data-styles="tscircuit-runframe"]'))return;const e=document.createElement("style");e.setAttribute("data-styles","tscircuit-runframe"),e.textContent=m3n,document.head.appendChild(e)},[])},y3n=t=>{Ce.useEffect(()=>(t?document.body.style.overflow="hidden":document.body.style.overflow="",()=>{document.body.style.overflow=""}),[t])},Nnt=t=>`hsl(${A2.indexOf(t)*137.5%360}, 70%, 50%)`,g3n=({phaseTimings:t})=>{if(!t)return null;const e=Object.values(t).reduce((n,i)=>n+i,0);return ye.jsxs("div",{className:"rf-space-y-2 rf-w-full rf-px-4",children:[ye.jsx("div",{className:"rf-relative rf-h-8 rf-flex rf-rounded-sm",children:A2.map(n=>{const i=t[n]||0,r=i/e*100;return ye.jsx("div",{className:"rf-group/bar rf-relative rf-overflow-visible",style:{width:`${r}%`,backgroundColor:Nnt(n)},children:ye.jsxs("div",{className:"rf-opacity-0 group-hover/bar:rf-opacity-100 rf-transition-opacity rf-absolute rf-bottom-full rf-left-1/2 rf-transform -rf-translate-x-1/2 rf-mb-2 rf-px-2 rf-py-1 rf-text-xs rf-whitespace-nowrap rf-rounded rf-bg-gray-900 rf-text-white rf-pointer-events-none",children:[n,": ",i.toFixed(1),"ms"]})},n)})}),ye.jsxs("div",{className:"rf-text-xs rf-text-gray-500",children:["Total: ",e.toFixed(2),"ms"]})]})},b3n=({renderLog:t,onRerunWithDebug:e})=>{const[n,i]=Ce.useState("chronological"),[r,o]=Ce.useState(""),s=[{value:"",label:"None"},{value:"DEBUG=Group_doInitialSchematicTraceRender",label:"DEBUG=Group_doInitialSchematicTraceRender"},{value:"DEBUG=Group_doInitialSchematicLayoutMatchpack",label:"DEBUG=Group_doInitialSchematicLayoutMatchpack"},{value:"DEBUG=Group_doInitialPcbLayoutPack",label:"DEBUG=Group_doInitialPcbLayoutPack"}];if(!t)return ye.jsxs("div",{className:"rf-p-4 rf-bg-gray-100 rf-rounded-md",children:[ye.jsx("div",{className:"rf-mb-4",children:"No render log, make sure this tab is open when you render"}),e&&ye.jsxs("div",{className:"rf-flex rf-gap-2 rf-items-center",children:[ye.jsx("select",{value:r,onChange:l=>o(l.target.value),className:"rf-px-3 rf-py-1 rf-border rf-rounded rf-text-xs rf-bg-white",children:s.map(l=>ye.jsx("option",{value:l.value,children:l.label},l.value))}),ye.jsx(P_,{onClick:()=>e(r),size:"sm",className:"rf-text-xs",children:"Rerun Render with Debug"})]})]});const a=Object.entries(t?.phaseTimings??{});n==="chronological"?a.sort((l,u)=>A2.indexOf(l[0])-A2.indexOf(u[0])):a.sort((l,u)=>u[1]-l[1]);const c=a.reduce((l,[u,d])=>l+d,0);return ye.jsxs("div",{className:"rf-bg-white",children:[ye.jsxs("div",{className:"rf-flex rf-justify-between rf-items-center rf-mb-4",children:[ye.jsx("div",{children:"Render Logs"}),ye.jsxs("div",{className:"rf-flex rf-gap-4 rf-items-center",children:[e&&ye.jsxs("div",{className:"rf-flex rf-gap-2 rf-items-center",children:[ye.jsx("select",{value:r,onChange:l=>o(l.target.value),className:"rf-px-3 rf-py-1 rf-border rf-rounded rf-text-xs rf-bg-white",children:s.map(l=>ye.jsx("option",{value:l.value,children:l.label},l.value))}),ye.jsx(P_,{onClick:()=>e(r),size:"sm",className:"rf-text-xs",children:"Rerun Render with Debug"})]}),ye.jsx("div",{className:"rf-flex rf-gap-2 rf-items-center",children:ye.jsxs("select",{onChange:l=>{if(l.target.value){const u=t?.debugOutputs?.find(d=>d.name===l.target.value);if(u){const d=new Blob([u.content],{type:"text/plain"}),h=URL.createObjectURL(d),f=document.createElement("a");f.href=h,f.download=`debug-${u.name}.txt`,document.body.appendChild(f),f.click(),document.body.removeChild(f),URL.revokeObjectURL(h)}l.target.value=""}},disabled:!t?.debugOutputs||t.debugOutputs.length===0,className:"rf-px-3 rf-py-1 rf-border rf-rounded rf-text-xs rf-bg-white disabled:rf-opacity-50 disabled:rf-cursor-not-allowed",children:[ye.jsx("option",{value:"",children:"Download Debug Output"}),t?.debugOutputs?.map(l=>ye.jsx("option",{value:l.name,children:l.name},l.name))]})}),ye.jsxs("div",{className:"rf-flex rf-text-xs rf-items-center",children:[ye.jsx("div",{className:"rf-mr-2",children:"Sort by:"}),ye.jsxs("select",{value:n,onChange:l=>i(l.target.value),className:"rf-px-2 rf-py-1 rf-border rf-rounded rf-text-xs",children:[ye.jsx("option",{value:"chronological",children:"Phase Order"}),ye.jsx("option",{value:"longest",children:"Duration"})]})]})]})]}),ye.jsx(g3n,{phaseTimings:t.phaseTimings}),ye.jsxs("table",{className:"rf-w-full rf-text-xs",children:[ye.jsx("thead",{children:ye.jsxs("tr",{children:[ye.jsx("th",{className:"rf-text-left rf-p-2",children:"Phase Order"}),ye.jsx("th",{className:"rf-text-left rf-p-2",children:"Phase"}),ye.jsx("th",{className:"rf-text-left rf-p-2",children:"Duration (ms)"})]})}),ye.jsx("tbody",{children:a.map(([l,u])=>ye.jsxs("tr",{children:[ye.jsx("td",{className:"rf-p-2",children:A2.indexOf(l)}),ye.jsx("td",{className:"rf-p-2",children:l}),ye.jsx("td",{className:"rf-p-2",children:ye.jsx("div",{className:"rf-w-8",children:ye.jsx("div",{className:"rf-h-2 rf-rounded-sm",style:{backgroundColor:Nnt(l),width:`${u/c*100}%`}})})}),ye.jsx("td",{className:"rf-p-2",children:ye.jsxs("div",{className:"rf-flex w-full",children:[ye.jsxs("span",{className:"rf-flex-grow",children:[u,"ms"]}),ye.jsxs("span",{className:"rf-text-gray-500 rf-pr-2",children:[(u/c*100).toFixed(1),"%"]})]})})]},l))})]})]})},knt=({errorMessage:t,errorStack:e,circuitJsonErrors:n})=>{Ce.useEffect(()=>{if(t){const i=new Error(t);e&&(i.stack=e);try{AL.captureException(i)}catch{}}},[t,e]),Ce.useEffect(()=>{if(n&&n.length>0)for(const i of n){const r=new Error(i.message||"Circuit JSON Error");i.stack&&(r.stack=i.stack);try{AL.captureException(r,{error_type:i.type})}catch{}}},[n])},x3n="0.0.967";function v3n(t,e){const[n,i]=Ce.useState(()=>{try{const r=window.localStorage.getItem(t);return r?JSON.parse(r):e}catch(r){return console.error("Error reading from localStorage:",r),e}});return Ce.useEffect(()=>{try{window.localStorage.setItem(t,JSON.stringify(n))}catch(r){console.error("Error writing to localStorage:",r)}},[t,n]),[n,i]}const jye={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1},Hye=new Map,iV=t=>{const e=Hye.get(t);return e?Object.fromEntries(Object.entries(e.stores).map(([n,i])=>[n,i.getState()])):{}},w3n=(t,e,n)=>{if(t===void 0)return{type:"untracked",connection:e.connect(n)};const i=Hye.get(n.name);if(i)return{type:"tracked",store:t,...i};const r={connection:e.connect(n),stores:{}};return Hye.set(n.name,r),{type:"tracked",store:t,...r}},Ont=(t,e={})=>(n,i,r)=>{const{enabled:o,anonymousActionType:s,store:a,...c}=e;let l;try{l=(o??(jye?"production":void 0)!=="production")&&window.__REDUX_DEVTOOLS_EXTENSION__}catch{}if(!l)return(jye?"production":void 0)!=="production"&&o&&console.warn("[zustand devtools middleware] Please install/enable Redux devtools extension"),t(n,i,r);const{connection:u,...d}=w3n(a,l,c);let h=!0;r.setState=(y,g,b)=>{const v=n(y,g);if(!h)return v;const w=b===void 0?{type:s||"anonymous"}:typeof b=="string"?{type:b}:b;return a===void 0?(u?.send(w,i()),v):(u?.send({...w,type:`${a}/${w.type}`},{...iV(c.name),[a]:r.getState()}),v)};const f=(...y)=>{const g=h;h=!1,n(...y),h=g},m=t(r.setState,i,r);if(d.type==="untracked"?u?.init(m):(d.stores[d.store]=r,u?.init(Object.fromEntries(Object.entries(d.stores).map(([y,g])=>[y,y===d.store?m:g.getState()])))),r.dispatchFromDevtools&&typeof r.dispatch=="function"){let y=!1;const g=r.dispatch;r.dispatch=(...b)=>{(jye?"production":void 0)!=="production"&&b[0].type==="__setState"&&!y&&(console.warn('[zustand devtools middleware] "__setState" action type is reserved to set state from the devtools. Avoid using it.'),y=!0),g(...b)}}return u.subscribe(y=>{var g;switch(y.type){case"ACTION":if(typeof y.payload!="string"){console.error("[zustand devtools middleware] Unsupported action format");return}return Vye(y.payload,b=>{if(b.type==="__setState"){if(a===void 0){f(b.state);return}Object.keys(b.state).length!==1&&console.error(`
5577
+ */const f3n=({containerClassName:t,...e})=>{const n=Ce.useRef(null),[i,r]=Ce.useState(620);return Ce.useLayoutEffect(()=>{const o=()=>{if(n.current){const a=n.current.clientHeight,c=window.innerHeight;r(Math.min(Math.max(a,620),c))}};o();const s=new ResizeObserver(o);return n.current&&s.observe(n.current),window.addEventListener("resize",o),()=>{s.disconnect(),window.removeEventListener("resize",o)}},[]),ye.jsx("div",{ref:n,className:t||"rf-w-full rf-h-full",children:ye.jsx(p3n,{...e,height:i})})},m3n='*,:after,:before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }/*! tailwindcss v3.4.17 | MIT License | https://tailwindcss.com*/*,:after,:before{border:0 solid #e5e7eb;box-sizing:border-box}:after,:before{--tw-content:""}:host,html{line-height:1.5;-webkit-text-size-adjust:100%;font-family:ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-feature-settings:normal;font-variation-settings:normal;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-tap-highlight-color:transparent}body{line-height:inherit;margin:0}hr{border-top-width:1px;color:inherit;height:0}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-size:1em;font-variation-settings:normal}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-collapse:collapse;border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{color:inherit;font-family:inherit;font-feature-settings:inherit;font-size:100%;font-variation-settings:inherit;font-weight:inherit;letter-spacing:inherit;line-height:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{color:#9ca3af;opacity:1}input::placeholder,textarea::placeholder{color:#9ca3af;opacity:1}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]:where(:not([hidden=until-found])){display:none}:root{--radius:0.5rem}.rf-pointer-events-none{pointer-events:none}.rf-invisible{visibility:hidden}.rf-fixed{position:fixed}.rf-absolute{position:absolute}.rf-relative{position:relative}.rf-inset-0{inset:0}.-rf-left-2{left:-.5rem}.-rf-right-10{right:-2.5rem}.-rf-right-2{right:-.5rem}.-rf-right-4{right:-1rem}.-rf-right-6{right:-1.5rem}.-rf-right-7{right:-1.75rem}.-rf-right-8{right:-2rem}.-rf-right-9{right:-2.25rem}.rf-bottom-full{bottom:100%}.rf-left-0{left:0}.rf-left-1{left:.25rem}.rf-left-1\\/2{left:50%}.rf-left-2{left:.5rem}.rf-left-\\[50\\%\\]{left:50%}.rf-right-0{right:0}.rf-right-1{right:.25rem}.rf-right-4{right:1rem}.rf-right-\\[4px\\]{right:4px}.rf-top-0{top:0}.rf-top-1{top:.25rem}.rf-top-2{top:.5rem}.rf-top-2\\.5{top:.625rem}.rf-top-\\[50\\%\\]{top:50%}.rf-top-\\[6px\\]{top:6px}.\\!rf-z-\\[101\\]{z-index:101!important}.\\!rf-z-\\[200\\]{z-index:200!important}.rf-z-10{z-index:10}.rf-z-50{z-index:50}.rf-z-\\[100\\]{z-index:100}.rf-z-\\[101\\]{z-index:101}.rf-order-1{order:1}.rf-order-2{order:2}.rf-order-3{order:3}.rf-m-1{margin:.25rem}.rf-m-6{margin:1.5rem}.-rf-mx-1,.rf--mx-1{margin-left:-.25rem;margin-right:-.25rem}.rf-mx-1{margin-left:.25rem;margin-right:.25rem}.rf-mx-2{margin-left:.5rem;margin-right:.5rem}.rf-mx-4{margin-left:1rem;margin-right:1rem}.rf-mx-auto{margin-left:auto;margin-right:auto}.rf-my-1{margin-bottom:.25rem;margin-top:.25rem}.rf-my-12{margin-bottom:3rem;margin-top:3rem}.rf-my-4{margin-bottom:1rem;margin-top:1rem}.rf-my-auto{margin-bottom:auto;margin-top:auto}.rf-mb-1{margin-bottom:.25rem}.rf-mb-12{margin-bottom:3rem}.rf-mb-2{margin-bottom:.5rem}.rf-mb-3{margin-bottom:.75rem}.rf-mb-4{margin-bottom:1rem}.rf-mb-6{margin-bottom:1.5rem}.rf-mb-8{margin-bottom:2rem}.rf-ml-1{margin-left:.25rem}.rf-ml-2{margin-left:.5rem}.rf-ml-auto{margin-left:auto}.rf-mr-1{margin-right:.25rem}.rf-mr-2{margin-right:.5rem}.rf-mt-0{margin-top:0}.rf-mt-0\\.5{margin-top:.125rem}.rf-mt-1{margin-top:.25rem}.rf-mt-2{margin-top:.5rem}.rf-mt-3{margin-top:.75rem}.rf-mt-4{margin-top:1rem}.rf-mt-5{margin-top:1.25rem}.rf-mt-auto{margin-top:auto}.rf-block{display:block}.rf-inline-block{display:inline-block}.rf-inline{display:inline}.rf-flex{display:flex}.rf-inline-flex{display:inline-flex}.rf-grid{display:grid}.rf-hidden{display:none}.rf-aspect-square{aspect-ratio:1/1}.rf-aspect-video{aspect-ratio:16/9}.rf-size-14{height:3.5rem;width:3.5rem}.rf-size-4{height:1rem;width:1rem}.\\!rf-h-2{height:.5rem!important}.\\!rf-h-2\\.5{height:.625rem!important}.\\!rf-h-3{height:.75rem!important}.\\!rf-h-full{height:100%!important}.rf-h-1{height:.25rem}.rf-h-10{height:2.5rem}.rf-h-12{height:3rem}.rf-h-2{height:.5rem}.rf-h-2\\.5{height:.625rem}.rf-h-20{height:5rem}.rf-h-24{height:6rem}.rf-h-3{height:.75rem}.rf-h-3\\.5{height:.875rem}.rf-h-4{height:1rem}.rf-h-5{height:1.25rem}.rf-h-6{height:1.5rem}.rf-h-60{height:15rem}.rf-h-64{height:16rem}.rf-h-7{height:1.75rem}.rf-h-8{height:2rem}.rf-h-9{height:2.25rem}.rf-h-\\[400px\\]{height:400px}.rf-h-\\[calc\\(100vh-52px\\)\\]{height:calc(100vh - 52px)}.rf-h-\\[var\\(--radix-select-trigger-height\\)\\]{height:var(--radix-select-trigger-height)}.rf-h-auto{height:auto}.rf-h-fit{height:-moz-fit-content;height:fit-content}.rf-h-full{height:100%}.rf-h-px{height:1px}.rf-h-screen{height:100vh}.\\!rf-max-h-\\[40vh\\]{max-height:40vh!important}.rf-max-h-32{max-height:8rem}.rf-max-h-96{max-height:24rem}.rf-max-h-\\[200px\\]{max-height:200px}.rf-max-h-\\[300px\\]{max-height:300px}.rf-max-h-\\[500px\\]{max-height:500px}.rf-max-h-\\[70vh\\]{max-height:70vh}.rf-max-h-\\[90vh\\]{max-height:90vh}.rf-max-h-full{max-height:100%}.rf-min-h-0{min-height:0}.rf-min-h-\\[200px\\]{min-height:200px}.rf-min-h-\\[300px\\]{min-height:300px}.rf-min-h-\\[620px\\]{min-height:620px}.rf-min-h-\\[calc\\(100vh-240px\\)\\]{min-height:calc(100vh - 240px)}.\\!rf-w-2{width:.5rem!important}.\\!rf-w-2\\.5{width:.625rem!important}.rf-w-1{width:.25rem}.rf-w-1\\/2{width:50%}.rf-w-11{width:2.75rem}.rf-w-11\\/12{width:91.666667%}.rf-w-12{width:3rem}.rf-w-16{width:4rem}.rf-w-2{width:.5rem}.rf-w-2\\.5{width:.625rem}.rf-w-20{width:5rem}.rf-w-24{width:6rem}.rf-w-28{width:7rem}.rf-w-3{width:.75rem}.rf-w-3\\.5{width:.875rem}.rf-w-32{width:8rem}.rf-w-4{width:1rem}.rf-w-40{width:10rem}.rf-w-48{width:12rem}.rf-w-5{width:1.25rem}.rf-w-6{width:1.5rem}.rf-w-64{width:16rem}.rf-w-72{width:18rem}.rf-w-8{width:2rem}.rf-w-80{width:20rem}.rf-w-9{width:2.25rem}.rf-w-96{width:24rem}.rf-w-\\[400px\\]{width:400px}.rf-w-\\[95\\%\\]{width:95%}.rf-w-fit{width:-moz-fit-content;width:fit-content}.rf-w-full{width:100%}.rf-w-screen{width:100vw}.rf-min-w-0{min-width:0}.rf-min-w-10{min-width:2.5rem}.rf-min-w-16{min-width:4rem}.rf-min-w-32{min-width:8rem}.rf-min-w-80{min-width:20rem}.rf-min-w-96{min-width:24rem}.rf-min-w-\\[148px\\]{min-width:148px}.rf-min-w-\\[400px\\]{min-width:400px}.rf-min-w-\\[8rem\\]{min-width:8rem}.rf-min-w-\\[var\\(--radix-select-trigger-width\\)\\]{min-width:var(--radix-select-trigger-width)}.\\!rf-max-w-\\[660px\\]{max-width:660px!important}.rf-max-w-2xl{max-width:42rem}.rf-max-w-3xl{max-width:48rem}.rf-max-w-4xl{max-width:56rem}.rf-max-w-5xl{max-width:64rem}.rf-max-w-64{max-width:16rem}.rf-max-w-96{max-width:24rem}.rf-max-w-\\[100px\\]{max-width:100px}.rf-max-w-\\[120px\\]{max-width:120px}.rf-max-w-\\[150px\\]{max-width:150px}.rf-max-w-\\[400px\\]{max-width:400px}.rf-max-w-full{max-width:100%}.rf-max-w-lg{max-width:32rem}.rf-max-w-md{max-width:28rem}.rf-max-w-none{max-width:none}.rf-max-w-xl{max-width:36rem}.rf-max-w-xs{max-width:20rem}.rf-flex-1{flex:1 1 0%}.rf-flex-shrink-0,.rf-shrink-0{flex-shrink:0}.rf-flex-grow{flex-grow:1}.rf-table-auto{table-layout:auto}.rf-origin-\\[--radix-popover-content-transform-origin\\]{transform-origin:var(--radix-popover-content-transform-origin)}.-rf-translate-x-1{--tw-translate-x:-0.25rem}.-rf-translate-x-1,.-rf-translate-x-1\\/2{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-rf-translate-x-1\\/2{--tw-translate-x:-50%}.-rf-translate-y-1{--tw-translate-y:-0.25rem}.-rf-translate-y-1,.rf--translate-x-1{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rf--translate-x-1{--tw-translate-x:-0.25rem}.rf--translate-x-1\\/2{--tw-translate-x:-50%}.rf--translate-x-1\\/2,.rf--translate-y-1{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rf--translate-y-1{--tw-translate-y:-0.25rem}.rf-translate-x-\\[-50\\%\\]{--tw-translate-x:-50%}.rf-translate-x-\\[-50\\%\\],.rf-translate-y-\\[-50\\%\\]{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rf-translate-y-\\[-50\\%\\]{--tw-translate-y:-50%}.rf-transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes rf-pulse{50%{opacity:.5}}.rf-animate-pulse{animation:rf-pulse 2s cubic-bezier(.4,0,.6,1) infinite}@keyframes rf-spin{to{transform:rotate(1turn)}}.rf-animate-spin{animation:rf-spin 1s linear infinite}.rf-cursor-default{cursor:default}.rf-cursor-not-allowed{cursor:not-allowed}.rf-cursor-pointer{cursor:pointer}.rf-select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.rf-grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.rf-grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.rf-grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.rf-flex-row{flex-direction:row}.rf-flex-col{flex-direction:column}.rf-flex-col-reverse{flex-direction:column-reverse}.rf-flex-wrap{flex-wrap:wrap}.rf-place-items-center{place-items:center}.rf-items-start{align-items:flex-start}.rf-items-end{align-items:flex-end}.rf-items-center{align-items:center}.rf-items-stretch{align-items:stretch}.rf-justify-end{justify-content:flex-end}.rf-justify-center{justify-content:center}.rf-justify-between{justify-content:space-between}.rf-gap-0{gap:0}.rf-gap-1{gap:.25rem}.rf-gap-2{gap:.5rem}.rf-gap-3{gap:.75rem}.rf-gap-4{gap:1rem}.rf-gap-5{gap:1.25rem}.rf-gap-6{gap:1.5rem}.rf-gap-8{gap:2rem}.rf-space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(.5rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(.5rem*var(--tw-space-x-reverse))}.rf-space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(.5rem*var(--tw-space-y-reverse));margin-top:calc(.5rem*(1 - var(--tw-space-y-reverse)))}.rf-space-y-3>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(.75rem*var(--tw-space-y-reverse));margin-top:calc(.75rem*(1 - var(--tw-space-y-reverse)))}.rf-space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(1rem*var(--tw-space-y-reverse));margin-top:calc(1rem*(1 - var(--tw-space-y-reverse)))}.rf-space-y-6>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(1.5rem*var(--tw-space-y-reverse));margin-top:calc(1.5rem*(1 - var(--tw-space-y-reverse)))}.rf-divide-y>:not([hidden])~:not([hidden]){--tw-divide-y-reverse:0;border-bottom-width:calc(1px*var(--tw-divide-y-reverse));border-top-width:calc(1px*(1 - var(--tw-divide-y-reverse)))}.rf-overflow-auto{overflow:auto}.rf-overflow-hidden{overflow:hidden}.rf-overflow-visible{overflow:visible}.\\!rf-overflow-x-auto{overflow-x:auto!important}.rf-overflow-x-auto{overflow-x:auto}.\\!rf-overflow-y-auto{overflow-y:auto!important}.rf-overflow-y-auto{overflow-y:auto}.rf-overflow-x-hidden{overflow-x:hidden}.rf-overflow-x-clip{overflow-x:clip}.rf-truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.rf-whitespace-normal{white-space:normal}.rf-whitespace-nowrap{white-space:nowrap}.rf-whitespace-pre-wrap{white-space:pre-wrap}.rf-break-words{overflow-wrap:break-word}.rf-break-all{word-break:break-all}.rf-rounded{border-radius:.25rem}.rf-rounded-2xl{border-radius:1rem}.rf-rounded-full{border-radius:9999px}.rf-rounded-lg{border-radius:var(--radius)}.rf-rounded-md{border-radius:calc(var(--radius) - 2px)}.rf-rounded-sm{border-radius:calc(var(--radius) - 4px)}.rf-rounded-xl{border-radius:.75rem}.rf-border{border-width:1px}.rf-border-2{border-width:2px}.rf-border-b{border-bottom-width:1px}.rf-border-t{border-top-width:1px}.rf-border-none{border-style:none}.rf-border-blue-200{--tw-border-opacity:1;border-color:rgb(191 219 254/var(--tw-border-opacity,1))}.rf-border-blue-400{--tw-border-opacity:1;border-color:rgb(96 165 250/var(--tw-border-opacity,1))}.rf-border-blue-500{--tw-border-opacity:1;border-color:rgb(59 130 246/var(--tw-border-opacity,1))}.rf-border-blue-600{--tw-border-opacity:1;border-color:rgb(37 99 235/var(--tw-border-opacity,1))}.rf-border-gray-200{--tw-border-opacity:1;border-color:rgb(229 231 235/var(--tw-border-opacity,1))}.rf-border-gray-300{--tw-border-opacity:1;border-color:rgb(209 213 219/var(--tw-border-opacity,1))}.rf-border-green-200{--tw-border-opacity:1;border-color:rgb(187 247 208/var(--tw-border-opacity,1))}.rf-border-green-400{--tw-border-opacity:1;border-color:rgb(74 222 128/var(--tw-border-opacity,1))}.rf-border-input{border-color:hsl(var(--input))}.rf-border-neutral-200{--tw-border-opacity:1;border-color:rgb(229 229 229/var(--tw-border-opacity,1))}.rf-border-orange-200{--tw-border-opacity:1;border-color:rgb(254 215 170/var(--tw-border-opacity,1))}.rf-border-primary{border-color:hsl(var(--primary))}.rf-border-red-200{--tw-border-opacity:1;border-color:rgb(254 202 202/var(--tw-border-opacity,1))}.rf-border-red-400{--tw-border-opacity:1;border-color:rgb(248 113 113/var(--tw-border-opacity,1))}.rf-border-red-500{--tw-border-opacity:1;border-color:rgb(239 68 68/var(--tw-border-opacity,1))}.rf-border-zinc-200{--tw-border-opacity:1;border-color:rgb(228 228 231/var(--tw-border-opacity,1))}.rf-border-zinc-900{--tw-border-opacity:1;border-color:rgb(24 24 27/var(--tw-border-opacity,1))}.rf-bg-background{background-color:hsl(var(--background))}.rf-bg-black{--tw-bg-opacity:1;background-color:rgb(0 0 0/var(--tw-bg-opacity,1))}.rf-bg-black\\/80{background-color:rgba(0,0,0,.8)}.rf-bg-blue-100{--tw-bg-opacity:1;background-color:rgb(219 234 254/var(--tw-bg-opacity,1))}.rf-bg-blue-50{--tw-bg-opacity:1;background-color:rgb(239 246 255/var(--tw-bg-opacity,1))}.rf-bg-blue-500{--tw-bg-opacity:1;background-color:rgb(59 130 246/var(--tw-bg-opacity,1))}.rf-bg-blue-600{--tw-bg-opacity:1;background-color:rgb(37 99 235/var(--tw-bg-opacity,1))}.rf-bg-gray-100{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity,1))}.rf-bg-gray-200{--tw-bg-opacity:1;background-color:rgb(229 231 235/var(--tw-bg-opacity,1))}.rf-bg-gray-300{--tw-bg-opacity:1;background-color:rgb(209 213 219/var(--tw-bg-opacity,1))}.rf-bg-gray-400{--tw-bg-opacity:1;background-color:rgb(156 163 175/var(--tw-bg-opacity,1))}.rf-bg-gray-50{--tw-bg-opacity:1;background-color:rgb(249 250 251/var(--tw-bg-opacity,1))}.rf-bg-gray-500{--tw-bg-opacity:1;background-color:rgb(107 114 128/var(--tw-bg-opacity,1))}.rf-bg-gray-700{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity,1))}.rf-bg-gray-800{--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity,1))}.rf-bg-gray-900{--tw-bg-opacity:1;background-color:rgb(17 24 39/var(--tw-bg-opacity,1))}.rf-bg-green-100{--tw-bg-opacity:1;background-color:rgb(220 252 231/var(--tw-bg-opacity,1))}.rf-bg-green-50{--tw-bg-opacity:1;background-color:rgb(240 253 244/var(--tw-bg-opacity,1))}.rf-bg-muted{background-color:hsl(var(--muted))}.rf-bg-neutral-100{--tw-bg-opacity:1;background-color:rgb(245 245 245/var(--tw-bg-opacity,1))}.rf-bg-neutral-50{--tw-bg-opacity:1;background-color:rgb(250 250 250/var(--tw-bg-opacity,1))}.rf-bg-neutral-800{--tw-bg-opacity:1;background-color:rgb(38 38 38/var(--tw-bg-opacity,1))}.rf-bg-neutral-900{--tw-bg-opacity:1;background-color:rgb(23 23 23/var(--tw-bg-opacity,1))}.rf-bg-orange-400{--tw-bg-opacity:1;background-color:rgb(251 146 60/var(--tw-bg-opacity,1))}.rf-bg-orange-50{--tw-bg-opacity:1;background-color:rgb(255 247 237/var(--tw-bg-opacity,1))}.rf-bg-popover{background-color:hsl(var(--popover))}.rf-bg-red-100{--tw-bg-opacity:1;background-color:rgb(254 226 226/var(--tw-bg-opacity,1))}.rf-bg-red-50{--tw-bg-opacity:1;background-color:rgb(254 242 242/var(--tw-bg-opacity,1))}.rf-bg-red-500{--tw-bg-opacity:1;background-color:rgb(239 68 68/var(--tw-bg-opacity,1))}.rf-bg-red-900{--tw-bg-opacity:1;background-color:rgb(127 29 29/var(--tw-bg-opacity,1))}.rf-bg-slate-50{--tw-bg-opacity:1;background-color:rgb(248 250 252/var(--tw-bg-opacity,1))}.rf-bg-transparent{background-color:transparent}.rf-bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity,1))}.rf-bg-yellow-100{--tw-bg-opacity:1;background-color:rgb(254 249 195/var(--tw-bg-opacity,1))}.rf-bg-zinc-100{--tw-bg-opacity:1;background-color:rgb(244 244 245/var(--tw-bg-opacity,1))}.rf-bg-zinc-200{--tw-bg-opacity:1;background-color:rgb(228 228 231/var(--tw-bg-opacity,1))}.rf-bg-zinc-50{--tw-bg-opacity:1;background-color:rgb(250 250 250/var(--tw-bg-opacity,1))}.rf-bg-zinc-800{--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.rf-bg-zinc-900{--tw-bg-opacity:1;background-color:rgb(24 24 27/var(--tw-bg-opacity,1))}.rf-bg-opacity-50{--tw-bg-opacity:0.5}.rf-fill-current{fill:currentColor}.rf-object-contain{-o-object-fit:contain;object-fit:contain}.rf-object-cover{-o-object-fit:cover;object-fit:cover}.\\!rf-p-0{padding:0!important}.rf-p-0{padding:0}.rf-p-1{padding:.25rem}.rf-p-2{padding:.5rem}.rf-p-3{padding:.75rem}.rf-p-4{padding:1rem}.rf-p-5{padding:1.25rem}.rf-p-6{padding:1.5rem}.rf-p-8{padding:2rem}.rf-px-1{padding-left:.25rem;padding-right:.25rem}.rf-px-2{padding-left:.5rem;padding-right:.5rem}.rf-px-3{padding-left:.75rem;padding-right:.75rem}.rf-px-4{padding-left:1rem;padding-right:1rem}.rf-px-6{padding-left:1.5rem;padding-right:1.5rem}.rf-px-8{padding-left:2rem;padding-right:2rem}.rf-py-0{padding-bottom:0;padding-top:0}.rf-py-0\\.5{padding-bottom:.125rem;padding-top:.125rem}.rf-py-1{padding-bottom:.25rem;padding-top:.25rem}.rf-py-1\\.5{padding-bottom:.375rem;padding-top:.375rem}.rf-py-10{padding-bottom:2.5rem;padding-top:2.5rem}.rf-py-12{padding-bottom:3rem;padding-top:3rem}.rf-py-2{padding-bottom:.5rem;padding-top:.5rem}.rf-py-3{padding-bottom:.75rem;padding-top:.75rem}.rf-py-4{padding-bottom:1rem;padding-top:1rem}.rf-py-6{padding-bottom:1.5rem;padding-top:1.5rem}.rf-py-8{padding-bottom:2rem;padding-top:2rem}.rf-pb-0{padding-bottom:0}.rf-pb-1{padding-bottom:.25rem}.rf-pb-2{padding-bottom:.5rem}.rf-pb-3{padding-bottom:.75rem}.rf-pb-4{padding-bottom:1rem}.rf-pl-2{padding-left:.5rem}.rf-pl-4{padding-left:1rem}.rf-pl-8{padding-left:2rem}.rf-pr-2{padding-right:.5rem}.rf-pt-0{padding-top:0}.rf-pt-2{padding-top:.5rem}.rf-pt-4{padding-top:1rem}.rf-text-left{text-align:left}.rf-text-center{text-align:center}.rf-text-right{text-align:right}.rf-font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.rf-text-2xl{font-size:1.5rem;line-height:2rem}.rf-text-3xl{font-size:1.875rem;line-height:2.25rem}.rf-text-\\[8px\\]{font-size:8px}.rf-text-base{font-size:1rem;line-height:1.5rem}.rf-text-lg{font-size:1.125rem;line-height:1.75rem}.rf-text-sm{font-size:.875rem;line-height:1.25rem}.rf-text-xl{font-size:1.25rem;line-height:1.75rem}.rf-text-xs{font-size:.75rem;line-height:1rem}.\\!rf-font-normal{font-weight:400!important}.rf-font-bold{font-weight:700}.rf-font-medium{font-weight:500}.rf-font-semibold{font-weight:600}.rf-uppercase{text-transform:uppercase}.rf-capitalize{text-transform:capitalize}.rf-tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}.rf-leading-5{line-height:1.25rem}.rf-leading-none{line-height:1}.rf-leading-relaxed{line-height:1.625}.rf-leading-tight{line-height:1.25}.rf-tracking-wide{letter-spacing:.025em}.rf-tracking-widest{letter-spacing:.1em}.rf-text-black{--tw-text-opacity:1;color:rgb(0 0 0/var(--tw-text-opacity,1))}.rf-text-blue-500{--tw-text-opacity:1;color:rgb(59 130 246/var(--tw-text-opacity,1))}.rf-text-blue-600{--tw-text-opacity:1;color:rgb(37 99 235/var(--tw-text-opacity,1))}.rf-text-blue-700{--tw-text-opacity:1;color:rgb(29 78 216/var(--tw-text-opacity,1))}.rf-text-blue-800{--tw-text-opacity:1;color:rgb(30 64 175/var(--tw-text-opacity,1))}.rf-text-blue-900{--tw-text-opacity:1;color:rgb(30 58 138/var(--tw-text-opacity,1))}.rf-text-current{color:currentColor}.rf-text-gray-300{--tw-text-opacity:1;color:rgb(209 213 219/var(--tw-text-opacity,1))}.rf-text-gray-400{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity,1))}.rf-text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity,1))}.rf-text-gray-600{--tw-text-opacity:1;color:rgb(75 85 99/var(--tw-text-opacity,1))}.rf-text-gray-700{--tw-text-opacity:1;color:rgb(55 65 81/var(--tw-text-opacity,1))}.rf-text-gray-800{--tw-text-opacity:1;color:rgb(31 41 55/var(--tw-text-opacity,1))}.rf-text-gray-900{--tw-text-opacity:1;color:rgb(17 24 39/var(--tw-text-opacity,1))}.rf-text-green-500{--tw-text-opacity:1;color:rgb(34 197 94/var(--tw-text-opacity,1))}.rf-text-green-600{--tw-text-opacity:1;color:rgb(22 163 74/var(--tw-text-opacity,1))}.rf-text-green-700{--tw-text-opacity:1;color:rgb(21 128 61/var(--tw-text-opacity,1))}.rf-text-green-800{--tw-text-opacity:1;color:rgb(22 101 52/var(--tw-text-opacity,1))}.rf-text-green-900{--tw-text-opacity:1;color:rgb(20 83 45/var(--tw-text-opacity,1))}.rf-text-muted-foreground{color:hsl(var(--muted-foreground))}.rf-text-neutral-50{--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.rf-text-neutral-500{--tw-text-opacity:1;color:rgb(115 115 115/var(--tw-text-opacity,1))}.rf-text-neutral-900{--tw-text-opacity:1;color:rgb(23 23 23/var(--tw-text-opacity,1))}.rf-text-neutral-950{--tw-text-opacity:1;color:rgb(10 10 10/var(--tw-text-opacity,1))}.rf-text-orange-500{--tw-text-opacity:1;color:rgb(249 115 22/var(--tw-text-opacity,1))}.rf-text-orange-600{--tw-text-opacity:1;color:rgb(234 88 12/var(--tw-text-opacity,1))}.rf-text-orange-800{--tw-text-opacity:1;color:rgb(154 52 18/var(--tw-text-opacity,1))}.rf-text-popover-foreground{color:hsl(var(--popover-foreground))}.rf-text-red-200{--tw-text-opacity:1;color:rgb(254 202 202/var(--tw-text-opacity,1))}.rf-text-red-300{--tw-text-opacity:1;color:rgb(252 165 165/var(--tw-text-opacity,1))}.rf-text-red-400{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity,1))}.rf-text-red-500{--tw-text-opacity:1;color:rgb(239 68 68/var(--tw-text-opacity,1))}.rf-text-red-600{--tw-text-opacity:1;color:rgb(220 38 38/var(--tw-text-opacity,1))}.rf-text-red-700{--tw-text-opacity:1;color:rgb(185 28 28/var(--tw-text-opacity,1))}.rf-text-red-800{--tw-text-opacity:1;color:rgb(153 27 27/var(--tw-text-opacity,1))}.rf-text-red-900{--tw-text-opacity:1;color:rgb(127 29 29/var(--tw-text-opacity,1))}.rf-text-slate-500{--tw-text-opacity:1;color:rgb(100 116 139/var(--tw-text-opacity,1))}.rf-text-slate-600{--tw-text-opacity:1;color:rgb(71 85 105/var(--tw-text-opacity,1))}.rf-text-slate-800{--tw-text-opacity:1;color:rgb(30 41 59/var(--tw-text-opacity,1))}.rf-text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity,1))}.rf-text-yellow-400{--tw-text-opacity:1;color:rgb(250 204 21/var(--tw-text-opacity,1))}.rf-text-yellow-500{--tw-text-opacity:1;color:rgb(234 179 8/var(--tw-text-opacity,1))}.rf-text-yellow-600{--tw-text-opacity:1;color:rgb(202 138 4/var(--tw-text-opacity,1))}.rf-text-yellow-900{--tw-text-opacity:1;color:rgb(113 63 18/var(--tw-text-opacity,1))}.rf-text-zinc-200{--tw-text-opacity:1;color:rgb(228 228 231/var(--tw-text-opacity,1))}.rf-text-zinc-300{--tw-text-opacity:1;color:rgb(212 212 216/var(--tw-text-opacity,1))}.rf-text-zinc-400{--tw-text-opacity:1;color:rgb(161 161 170/var(--tw-text-opacity,1))}.rf-text-zinc-50{--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.rf-text-zinc-500{--tw-text-opacity:1;color:rgb(113 113 122/var(--tw-text-opacity,1))}.rf-text-zinc-900{--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}.rf-text-zinc-950{--tw-text-opacity:1;color:rgb(9 9 11/var(--tw-text-opacity,1))}.rf-underline{text-decoration-line:underline}.rf-line-through{text-decoration-line:line-through}.rf-underline-offset-4{text-underline-offset:4px}.rf-opacity-0{opacity:0}.rf-opacity-100{opacity:1}.rf-opacity-25{opacity:.25}.rf-opacity-30{opacity:.3}.rf-opacity-50{opacity:.5}.rf-opacity-60{opacity:.6}.rf-opacity-75{opacity:.75}.rf-shadow{--tw-shadow:0 1px 3px 0 rgba(0,0,0,.1),0 1px 2px -1px rgba(0,0,0,.1);--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color)}.rf-shadow,.rf-shadow-lg{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.rf-shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color)}.rf-shadow-md{--tw-shadow:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -2px rgba(0,0,0,.1);--tw-shadow-colored:0 4px 6px -1px var(--tw-shadow-color),0 2px 4px -2px var(--tw-shadow-color)}.rf-shadow-md,.rf-shadow-sm{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.rf-shadow-sm{--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color)}.rf-outline-none{outline:2px solid transparent;outline-offset:2px}.rf-ring-2{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.rf-ring-blue-500{--tw-ring-opacity:1;--tw-ring-color:rgb(59 130 246/var(--tw-ring-opacity,1))}.rf-ring-primary{--tw-ring-color:hsl(var(--primary))}.rf-ring-offset-background{--tw-ring-offset-color:hsl(var(--background))}.rf-ring-offset-white{--tw-ring-offset-color:#fff}.rf-transition{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}.rf-transition-all{transition-duration:.15s;transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1)}.rf-transition-colors{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1)}.rf-transition-opacity{transition-duration:.15s;transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1)}.rf-duration-200{transition-duration:.2s}.rf-ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}@keyframes enter{0%{opacity:var(--tw-enter-opacity,1);transform:translate3d(var(--tw-enter-translate-x,0),var(--tw-enter-translate-y,0),0) scale3d(var(--tw-enter-scale,1),var(--tw-enter-scale,1),var(--tw-enter-scale,1)) rotate(var(--tw-enter-rotate,0))}}@keyframes exit{to{opacity:var(--tw-exit-opacity,1);transform:translate3d(var(--tw-exit-translate-x,0),var(--tw-exit-translate-y,0),0) scale3d(var(--tw-exit-scale,1),var(--tw-exit-scale,1),var(--tw-exit-scale,1)) rotate(var(--tw-exit-rotate,0))}}.rf-slide-in-from-left-1{--tw-enter-translate-x:-0.25rem}.rf-slide-out-to-left-1{--tw-exit-translate-x:-0.25rem}.rf-duration-200{animation-duration:.2s}.rf-ease-in-out{animation-timing-function:cubic-bezier(.4,0,.2,1)}.file\\:rf-border-0::file-selector-button{border-width:0}.file\\:rf-bg-transparent::file-selector-button{background-color:transparent}.file\\:rf-text-sm::file-selector-button{font-size:.875rem;line-height:1.25rem}.file\\:rf-font-medium::file-selector-button{font-weight:500}.placeholder\\:rf-text-zinc-500::-moz-placeholder{--tw-text-opacity:1;color:rgb(113 113 122/var(--tw-text-opacity,1))}.placeholder\\:rf-text-zinc-500::placeholder{--tw-text-opacity:1;color:rgb(113 113 122/var(--tw-text-opacity,1))}.hover\\:rf-border-blue-300:hover{--tw-border-opacity:1;border-color:rgb(147 197 253/var(--tw-border-opacity,1))}.hover\\:\\!rf-bg-transparent:hover{background-color:transparent!important}.hover\\:rf-bg-blue-700:hover{--tw-bg-opacity:1;background-color:rgb(29 78 216/var(--tw-bg-opacity,1))}.hover\\:rf-bg-red-500\\/90:hover{background-color:rgba(239,68,68,.9)}.hover\\:rf-bg-zinc-100:hover{--tw-bg-opacity:1;background-color:rgb(244 244 245/var(--tw-bg-opacity,1))}.hover\\:rf-bg-zinc-100\\/80:hover{background-color:hsla(240,5%,96%,.8)}.hover\\:rf-bg-zinc-900\\/90:hover{background-color:rgba(24,24,27,.9)}.hover\\:rf-text-blue-800:hover{--tw-text-opacity:1;color:rgb(30 64 175/var(--tw-text-opacity,1))}.hover\\:rf-text-red-400:hover{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity,1))}.hover\\:rf-text-slate-900:hover{--tw-text-opacity:1;color:rgb(15 23 42/var(--tw-text-opacity,1))}.hover\\:rf-text-zinc-900:hover{--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}.hover\\:rf-underline:hover{text-decoration-line:underline}.focus\\:rf-bg-gray-100:focus{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity,1))}.focus\\:rf-bg-zinc-100:focus{--tw-bg-opacity:1;background-color:rgb(244 244 245/var(--tw-bg-opacity,1))}.focus\\:rf-text-gray-900:focus{--tw-text-opacity:1;color:rgb(17 24 39/var(--tw-text-opacity,1))}.focus\\:rf-text-zinc-900:focus{--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}.focus\\:rf-outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\\:rf-ring-2:focus{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.focus\\:rf-ring-ring:focus{--tw-ring-color:hsl(var(--ring))}.focus\\:rf-ring-offset-2:focus{--tw-ring-offset-width:2px}.focus-visible\\:rf-outline-none:focus-visible{outline:2px solid transparent;outline-offset:2px}.focus-visible\\:rf-ring-1:focus-visible{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.focus-visible\\:rf-ring-2:focus-visible{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.focus-visible\\:rf-ring-zinc-950:focus-visible{--tw-ring-opacity:1;--tw-ring-color:rgb(9 9 11/var(--tw-ring-opacity,1))}.focus-visible\\:rf-ring-offset-2:focus-visible{--tw-ring-offset-width:2px}.disabled\\:rf-pointer-events-none:disabled{pointer-events:none}.disabled\\:rf-cursor-not-allowed:disabled{cursor:not-allowed}.disabled\\:rf-opacity-50:disabled{opacity:.5}.rf-group\\/bar:hover .group-hover\\/bar\\:rf-opacity-100{opacity:1}.data-\\[disabled\\=true\\]\\:rf-pointer-events-none[data-disabled=true],.data-\\[disabled\\]\\:rf-pointer-events-none[data-disabled]{pointer-events:none}.data-\\[side\\=bottom\\]\\:rf-translate-y-1[data-side=bottom]{--tw-translate-y:0.25rem}.data-\\[side\\=bottom\\]\\:rf-translate-y-1[data-side=bottom],.data-\\[side\\=left\\]\\:-rf-translate-x-1[data-side=left]{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.data-\\[side\\=left\\]\\:-rf-translate-x-1[data-side=left]{--tw-translate-x:-0.25rem}.data-\\[side\\=right\\]\\:rf-translate-x-1[data-side=right]{--tw-translate-x:0.25rem}.data-\\[side\\=right\\]\\:rf-translate-x-1[data-side=right],.data-\\[side\\=top\\]\\:-rf-translate-y-1[data-side=top]{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.data-\\[side\\=top\\]\\:-rf-translate-y-1[data-side=top]{--tw-translate-y:-0.25rem}.data-\\[selected\\=true\\]\\:rf-bg-zinc-100[data-selected=true]{--tw-bg-opacity:1;background-color:rgb(244 244 245/var(--tw-bg-opacity,1))}.data-\\[state\\=active\\]\\:rf-bg-white[data-state=active]{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity,1))}.data-\\[state\\=checked\\]\\:rf-bg-zinc-900[data-state=checked]{--tw-bg-opacity:1;background-color:rgb(24 24 27/var(--tw-bg-opacity,1))}.data-\\[state\\=open\\]\\:rf-bg-zinc-100[data-state=open]{--tw-bg-opacity:1;background-color:rgb(244 244 245/var(--tw-bg-opacity,1))}.data-\\[selected\\=true\\]\\:rf-text-zinc-900[data-selected=true]{--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}.data-\\[state\\=active\\]\\:rf-text-zinc-950[data-state=active]{--tw-text-opacity:1;color:rgb(9 9 11/var(--tw-text-opacity,1))}.data-\\[state\\=checked\\]\\:rf-text-zinc-50[data-state=checked]{--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.data-\\[disabled\\=true\\]\\:rf-opacity-50[data-disabled=true],.data-\\[disabled\\]\\:rf-opacity-50[data-disabled]{opacity:.5}.data-\\[state\\=active\\]\\:rf-shadow[data-state=active]{--tw-shadow:0 1px 3px 0 rgba(0,0,0,.1),0 1px 2px -1px rgba(0,0,0,.1);--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.data-\\[state\\=open\\]\\:rf-animate-in[data-state=open]{animation-duration:.15s;animation-name:enter;--tw-enter-opacity:initial;--tw-enter-scale:initial;--tw-enter-rotate:initial;--tw-enter-translate-x:initial;--tw-enter-translate-y:initial}.data-\\[state\\=closed\\]\\:rf-animate-out[data-state=closed]{animation-duration:.15s;animation-name:exit;--tw-exit-opacity:initial;--tw-exit-scale:initial;--tw-exit-rotate:initial;--tw-exit-translate-x:initial;--tw-exit-translate-y:initial}.data-\\[state\\=closed\\]\\:rf-fade-out-0[data-state=closed]{--tw-exit-opacity:0}.data-\\[state\\=open\\]\\:rf-fade-in-0[data-state=open]{--tw-enter-opacity:0}.data-\\[state\\=closed\\]\\:rf-zoom-out-95[data-state=closed]{--tw-exit-scale:.95}.data-\\[state\\=open\\]\\:rf-zoom-in-95[data-state=open]{--tw-enter-scale:.95}.data-\\[side\\=bottom\\]\\:rf-slide-in-from-top-2[data-side=bottom]{--tw-enter-translate-y:-0.5rem}.data-\\[side\\=left\\]\\:rf-slide-in-from-right-2[data-side=left]{--tw-enter-translate-x:0.5rem}.data-\\[side\\=right\\]\\:rf-slide-in-from-left-2[data-side=right]{--tw-enter-translate-x:-0.5rem}.data-\\[side\\=top\\]\\:rf-slide-in-from-bottom-2[data-side=top]{--tw-enter-translate-y:0.5rem}.data-\\[state\\=closed\\]\\:rf-slide-out-to-left-1\\/2[data-state=closed]{--tw-exit-translate-x:-50%}.data-\\[state\\=closed\\]\\:rf-slide-out-to-top-\\[48\\%\\][data-state=closed]{--tw-exit-translate-y:-48%}.data-\\[state\\=open\\]\\:rf-slide-in-from-left-1\\/2[data-state=open]{--tw-enter-translate-x:-50%}.data-\\[state\\=open\\]\\:rf-slide-in-from-top-\\[48\\%\\][data-state=open]{--tw-enter-translate-y:-48%}.dark\\:rf-border-zinc-50:is(.rf-dark *){--tw-border-opacity:1;border-color:rgb(250 250 250/var(--tw-border-opacity,1))}.dark\\:rf-border-zinc-800:is(.rf-dark *){--tw-border-opacity:1;border-color:rgb(39 39 42/var(--tw-border-opacity,1))}.dark\\:rf-bg-gray-700:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity,1))}.dark\\:rf-bg-gray-800:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity,1))}.dark\\:rf-bg-red-900:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(127 29 29/var(--tw-bg-opacity,1))}.dark\\:rf-bg-zinc-50:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(250 250 250/var(--tw-bg-opacity,1))}.dark\\:rf-bg-zinc-800:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.dark\\:rf-bg-zinc-950:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(9 9 11/var(--tw-bg-opacity,1))}.dark\\:rf-text-gray-500:is(.rf-dark *){--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity,1))}.dark\\:rf-text-zinc-400:is(.rf-dark *){--tw-text-opacity:1;color:rgb(161 161 170/var(--tw-text-opacity,1))}.dark\\:rf-text-zinc-50:is(.rf-dark *){--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.dark\\:rf-text-zinc-900:is(.rf-dark *){--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}.dark\\:rf-placeholder-zinc-400:is(.rf-dark *)::-moz-placeholder{--tw-placeholder-opacity:1;color:rgb(161 161 170/var(--tw-placeholder-opacity,1))}.dark\\:rf-placeholder-zinc-400:is(.rf-dark *)::placeholder{--tw-placeholder-opacity:1;color:rgb(161 161 170/var(--tw-placeholder-opacity,1))}.dark\\:rf-ring-offset-zinc-950:is(.rf-dark *){--tw-ring-offset-color:#09090b}.dark\\:placeholder\\:rf-text-zinc-400:is(.rf-dark *)::-moz-placeholder{--tw-text-opacity:1;color:rgb(161 161 170/var(--tw-text-opacity,1))}.dark\\:placeholder\\:rf-text-zinc-400:is(.rf-dark *)::placeholder{--tw-text-opacity:1;color:rgb(161 161 170/var(--tw-text-opacity,1))}.dark\\:hover\\:rf-bg-red-900\\/90:hover:is(.rf-dark *){background-color:rgba(127,29,29,.9)}.dark\\:hover\\:rf-bg-zinc-50\\/90:hover:is(.rf-dark *){background-color:hsla(0,0%,98%,.9)}.dark\\:hover\\:rf-bg-zinc-800:hover:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.dark\\:hover\\:rf-bg-zinc-800\\/80:hover:is(.rf-dark *){background-color:rgba(39,39,42,.8)}.dark\\:hover\\:rf-text-zinc-50:hover:is(.rf-dark *){--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.dark\\:focus\\:rf-bg-zinc-800:focus:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.dark\\:focus\\:rf-text-zinc-50:focus:is(.rf-dark *){--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.dark\\:focus-visible\\:rf-ring-zinc-300:focus-visible:is(.rf-dark *){--tw-ring-opacity:1;--tw-ring-color:rgb(212 212 216/var(--tw-ring-opacity,1))}.dark\\:data-\\[selected\\=true\\]\\:rf-bg-zinc-800[data-selected=true]:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.dark\\:data-\\[state\\=active\\]\\:rf-bg-zinc-950[data-state=active]:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(9 9 11/var(--tw-bg-opacity,1))}.dark\\:data-\\[state\\=checked\\]\\:rf-bg-zinc-50[data-state=checked]:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(250 250 250/var(--tw-bg-opacity,1))}.dark\\:data-\\[state\\=open\\]\\:rf-bg-zinc-800[data-state=open]:is(.rf-dark *){--tw-bg-opacity:1;background-color:rgb(39 39 42/var(--tw-bg-opacity,1))}.dark\\:data-\\[selected\\=true\\]\\:rf-text-zinc-50[data-selected=true]:is(.rf-dark *){--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.dark\\:data-\\[state\\=active\\]\\:rf-text-zinc-50[data-state=active]:is(.rf-dark *){--tw-text-opacity:1;color:rgb(250 250 250/var(--tw-text-opacity,1))}.dark\\:data-\\[state\\=checked\\]\\:rf-text-zinc-900[data-state=checked]:is(.rf-dark *){--tw-text-opacity:1;color:rgb(24 24 27/var(--tw-text-opacity,1))}@media (min-width:640px){.sm\\:rf-order-1{order:1}.sm\\:rf-order-2{order:2}.sm\\:rf-mt-0{margin-top:0}.sm\\:rf-inline{display:inline}.sm\\:rf-grid{display:grid}.sm\\:rf-hidden{display:none}.sm\\:rf-w-auto{width:auto}.sm\\:rf-grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.sm\\:rf-grid-cols-\\[1fr_auto\\]{grid-template-columns:1fr auto}.sm\\:rf-flex-row{flex-direction:row}.sm\\:rf-items-center{align-items:center}.sm\\:rf-justify-end{justify-content:flex-end}.sm\\:rf-gap-3{gap:.75rem}.sm\\:rf-space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(.5rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(.5rem*var(--tw-space-x-reverse))}.sm\\:rf-rounded-lg{border-radius:var(--radius)}.sm\\:rf-px-4{padding-left:1rem;padding-right:1rem}.sm\\:rf-text-left{text-align:left}.sm\\:rf-text-sm{font-size:.875rem;line-height:1.25rem}.sm\\:rf-text-xl{font-size:1.25rem;line-height:1.75rem}}@media (min-width:768px){.md\\:rf-grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}}.\\[\\&\\>span\\]\\:rf-line-clamp-1>span{display:-webkit-box;overflow:hidden;-webkit-box-orient:vertical;-webkit-line-clamp:1}.\\[\\&\\>svg\\]\\:rf-size-4>svg{height:1rem;width:1rem}.\\[\\&\\>svg\\]\\:rf-shrink-0>svg{flex-shrink:0}.\\[\\&\\>svg\\]\\:rf-text-red-300>svg{--tw-text-opacity:1;color:rgb(252 165 165/var(--tw-text-opacity,1))}.\\[\\&\\>svg\\]\\:hover\\:rf-text-red-400:hover>svg{--tw-text-opacity:1;color:rgb(248 113 113/var(--tw-text-opacity,1))}.\\[\\&_\\[cmdk-group-heading\\]\\]\\:rf-px-2 [cmdk-group-heading]{padding-left:.5rem;padding-right:.5rem}.\\[\\&_\\[cmdk-group-heading\\]\\]\\:rf-py-1\\.5 [cmdk-group-heading]{padding-bottom:.375rem;padding-top:.375rem}.\\[\\&_\\[cmdk-group-heading\\]\\]\\:rf-text-xs [cmdk-group-heading]{font-size:.75rem;line-height:1rem}.\\[\\&_\\[cmdk-group-heading\\]\\]\\:rf-font-medium [cmdk-group-heading]{font-weight:500}.\\[\\&_\\[cmdk-group-heading\\]\\]\\:rf-text-zinc-500 [cmdk-group-heading]{--tw-text-opacity:1;color:rgb(113 113 122/var(--tw-text-opacity,1))}.dark\\:\\[\\&_\\[cmdk-group-heading\\]\\]\\:rf-text-zinc-400 [cmdk-group-heading]:is(.rf-dark *){--tw-text-opacity:1;color:rgb(161 161 170/var(--tw-text-opacity,1))}.\\[\\&_\\[cmdk-group\\]\\:not\\(\\[hidden\\]\\)_\\~\\[cmdk-group\\]\\]\\:rf-pt-0 [cmdk-group]:not([hidden])~[cmdk-group]{padding-top:0}.\\[\\&_\\[cmdk-group\\]\\]\\:rf-px-2 [cmdk-group]{padding-left:.5rem;padding-right:.5rem}.\\[\\&_\\[cmdk-input-wrapper\\]_svg\\]\\:rf-h-5 [cmdk-input-wrapper] svg{height:1.25rem}.\\[\\&_\\[cmdk-input-wrapper\\]_svg\\]\\:rf-w-5 [cmdk-input-wrapper] svg{width:1.25rem}.\\[\\&_\\[cmdk-input\\]\\]\\:rf-h-12 [cmdk-input]{height:3rem}.\\[\\&_\\[cmdk-item\\]\\]\\:rf-px-2 [cmdk-item]{padding-left:.5rem;padding-right:.5rem}.\\[\\&_\\[cmdk-item\\]\\]\\:rf-py-3 [cmdk-item]{padding-bottom:.75rem;padding-top:.75rem}.\\[\\&_\\[cmdk-item\\]_svg\\]\\:rf-h-5 [cmdk-item] svg{height:1.25rem}.\\[\\&_\\[cmdk-item\\]_svg\\]\\:rf-w-5 [cmdk-item] svg{width:1.25rem}.\\[\\&_svg\\]\\:rf-pointer-events-none svg{pointer-events:none}.\\[\\&_svg\\]\\:rf-size-4 svg{height:1rem;width:1rem}.\\[\\&_svg\\]\\:rf-shrink-0 svg{flex-shrink:0}',_3n=()=>{Ce.useEffect(()=>{if(document.querySelector('style[data-styles="tscircuit-runframe"]'))return;const e=document.createElement("style");e.setAttribute("data-styles","tscircuit-runframe"),e.textContent=m3n,document.head.appendChild(e)},[])},y3n=t=>{Ce.useEffect(()=>(t?document.body.style.overflow="hidden":document.body.style.overflow="",()=>{document.body.style.overflow=""}),[t])},Nnt=t=>`hsl(${A2.indexOf(t)*137.5%360}, 70%, 50%)`,g3n=({phaseTimings:t})=>{if(!t)return null;const e=Object.values(t).reduce((n,i)=>n+i,0);return ye.jsxs("div",{className:"rf-space-y-2 rf-w-full rf-px-4",children:[ye.jsx("div",{className:"rf-relative rf-h-8 rf-flex rf-rounded-sm",children:A2.map(n=>{const i=t[n]||0,r=i/e*100;return ye.jsx("div",{className:"rf-group/bar rf-relative rf-overflow-visible",style:{width:`${r}%`,backgroundColor:Nnt(n)},children:ye.jsxs("div",{className:"rf-opacity-0 group-hover/bar:rf-opacity-100 rf-transition-opacity rf-absolute rf-bottom-full rf-left-1/2 rf-transform -rf-translate-x-1/2 rf-mb-2 rf-px-2 rf-py-1 rf-text-xs rf-whitespace-nowrap rf-rounded rf-bg-gray-900 rf-text-white rf-pointer-events-none",children:[n,": ",i.toFixed(1),"ms"]})},n)})}),ye.jsxs("div",{className:"rf-text-xs rf-text-gray-500",children:["Total: ",e.toFixed(2),"ms"]})]})},b3n=({renderLog:t,onRerunWithDebug:e})=>{const[n,i]=Ce.useState("chronological"),[r,o]=Ce.useState(""),s=[{value:"",label:"None"},{value:"DEBUG=Group_doInitialSchematicTraceRender",label:"DEBUG=Group_doInitialSchematicTraceRender"},{value:"DEBUG=Group_doInitialSchematicLayoutMatchpack",label:"DEBUG=Group_doInitialSchematicLayoutMatchpack"},{value:"DEBUG=Group_doInitialPcbLayoutPack",label:"DEBUG=Group_doInitialPcbLayoutPack"}];if(!t)return ye.jsxs("div",{className:"rf-p-4 rf-bg-gray-100 rf-rounded-md",children:[ye.jsx("div",{className:"rf-mb-4",children:"No render log, make sure this tab is open when you render"}),e&&ye.jsxs("div",{className:"rf-flex rf-gap-2 rf-items-center",children:[ye.jsx("select",{value:r,onChange:l=>o(l.target.value),className:"rf-px-3 rf-py-1 rf-border rf-rounded rf-text-xs rf-bg-white",children:s.map(l=>ye.jsx("option",{value:l.value,children:l.label},l.value))}),ye.jsx(P_,{onClick:()=>e(r),size:"sm",className:"rf-text-xs",children:"Rerun Render with Debug"})]})]});const a=Object.entries(t?.phaseTimings??{});n==="chronological"?a.sort((l,u)=>A2.indexOf(l[0])-A2.indexOf(u[0])):a.sort((l,u)=>u[1]-l[1]);const c=a.reduce((l,[u,d])=>l+d,0);return ye.jsxs("div",{className:"rf-bg-white",children:[ye.jsxs("div",{className:"rf-flex rf-justify-between rf-items-center rf-mb-4",children:[ye.jsx("div",{children:"Render Logs"}),ye.jsxs("div",{className:"rf-flex rf-gap-4 rf-items-center",children:[e&&ye.jsxs("div",{className:"rf-flex rf-gap-2 rf-items-center",children:[ye.jsx("select",{value:r,onChange:l=>o(l.target.value),className:"rf-px-3 rf-py-1 rf-border rf-rounded rf-text-xs rf-bg-white",children:s.map(l=>ye.jsx("option",{value:l.value,children:l.label},l.value))}),ye.jsx(P_,{onClick:()=>e(r),size:"sm",className:"rf-text-xs",children:"Rerun Render with Debug"})]}),ye.jsx("div",{className:"rf-flex rf-gap-2 rf-items-center",children:ye.jsxs("select",{onChange:l=>{if(l.target.value){const u=t?.debugOutputs?.find(d=>d.name===l.target.value);if(u){const d=new Blob([u.content],{type:"text/plain"}),h=URL.createObjectURL(d),f=document.createElement("a");f.href=h,f.download=`debug-${u.name}.txt`,document.body.appendChild(f),f.click(),document.body.removeChild(f),URL.revokeObjectURL(h)}l.target.value=""}},disabled:!t?.debugOutputs||t.debugOutputs.length===0,className:"rf-px-3 rf-py-1 rf-border rf-rounded rf-text-xs rf-bg-white disabled:rf-opacity-50 disabled:rf-cursor-not-allowed",children:[ye.jsx("option",{value:"",children:"Download Debug Output"}),t?.debugOutputs?.map(l=>ye.jsx("option",{value:l.name,children:l.name},l.name))]})}),ye.jsxs("div",{className:"rf-flex rf-text-xs rf-items-center",children:[ye.jsx("div",{className:"rf-mr-2",children:"Sort by:"}),ye.jsxs("select",{value:n,onChange:l=>i(l.target.value),className:"rf-px-2 rf-py-1 rf-border rf-rounded rf-text-xs",children:[ye.jsx("option",{value:"chronological",children:"Phase Order"}),ye.jsx("option",{value:"longest",children:"Duration"})]})]})]})]}),ye.jsx(g3n,{phaseTimings:t.phaseTimings}),ye.jsxs("table",{className:"rf-w-full rf-text-xs",children:[ye.jsx("thead",{children:ye.jsxs("tr",{children:[ye.jsx("th",{className:"rf-text-left rf-p-2",children:"Phase Order"}),ye.jsx("th",{className:"rf-text-left rf-p-2",children:"Phase"}),ye.jsx("th",{className:"rf-text-left rf-p-2",children:"Duration (ms)"})]})}),ye.jsx("tbody",{children:a.map(([l,u])=>ye.jsxs("tr",{children:[ye.jsx("td",{className:"rf-p-2",children:A2.indexOf(l)}),ye.jsx("td",{className:"rf-p-2",children:l}),ye.jsx("td",{className:"rf-p-2",children:ye.jsx("div",{className:"rf-w-8",children:ye.jsx("div",{className:"rf-h-2 rf-rounded-sm",style:{backgroundColor:Nnt(l),width:`${u/c*100}%`}})})}),ye.jsx("td",{className:"rf-p-2",children:ye.jsxs("div",{className:"rf-flex w-full",children:[ye.jsxs("span",{className:"rf-flex-grow",children:[u,"ms"]}),ye.jsxs("span",{className:"rf-text-gray-500 rf-pr-2",children:[(u/c*100).toFixed(1),"%"]})]})})]},l))})]})]})},knt=({errorMessage:t,errorStack:e,circuitJsonErrors:n})=>{Ce.useEffect(()=>{if(t){const i=new Error(t);e&&(i.stack=e);try{AL.captureException(i)}catch{}}},[t,e]),Ce.useEffect(()=>{if(n&&n.length>0)for(const i of n){const r=new Error(i.message||"Circuit JSON Error");i.stack&&(r.stack=i.stack);try{AL.captureException(r,{error_type:i.type})}catch{}}},[n])},x3n="0.0.969";function v3n(t,e){const[n,i]=Ce.useState(()=>{try{const r=window.localStorage.getItem(t);return r?JSON.parse(r):e}catch(r){return console.error("Error reading from localStorage:",r),e}});return Ce.useEffect(()=>{try{window.localStorage.setItem(t,JSON.stringify(n))}catch(r){console.error("Error writing to localStorage:",r)}},[t,n]),[n,i]}const jye={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1},Hye=new Map,iV=t=>{const e=Hye.get(t);return e?Object.fromEntries(Object.entries(e.stores).map(([n,i])=>[n,i.getState()])):{}},w3n=(t,e,n)=>{if(t===void 0)return{type:"untracked",connection:e.connect(n)};const i=Hye.get(n.name);if(i)return{type:"tracked",store:t,...i};const r={connection:e.connect(n),stores:{}};return Hye.set(n.name,r),{type:"tracked",store:t,...r}},Ont=(t,e={})=>(n,i,r)=>{const{enabled:o,anonymousActionType:s,store:a,...c}=e;let l;try{l=(o??(jye?"production":void 0)!=="production")&&window.__REDUX_DEVTOOLS_EXTENSION__}catch{}if(!l)return(jye?"production":void 0)!=="production"&&o&&console.warn("[zustand devtools middleware] Please install/enable Redux devtools extension"),t(n,i,r);const{connection:u,...d}=w3n(a,l,c);let h=!0;r.setState=(y,g,b)=>{const v=n(y,g);if(!h)return v;const w=b===void 0?{type:s||"anonymous"}:typeof b=="string"?{type:b}:b;return a===void 0?(u?.send(w,i()),v):(u?.send({...w,type:`${a}/${w.type}`},{...iV(c.name),[a]:r.getState()}),v)};const f=(...y)=>{const g=h;h=!1,n(...y),h=g},m=t(r.setState,i,r);if(d.type==="untracked"?u?.init(m):(d.stores[d.store]=r,u?.init(Object.fromEntries(Object.entries(d.stores).map(([y,g])=>[y,y===d.store?m:g.getState()])))),r.dispatchFromDevtools&&typeof r.dispatch=="function"){let y=!1;const g=r.dispatch;r.dispatch=(...b)=>{(jye?"production":void 0)!=="production"&&b[0].type==="__setState"&&!y&&(console.warn('[zustand devtools middleware] "__setState" action type is reserved to set state from the devtools. Avoid using it.'),y=!0),g(...b)}}return u.subscribe(y=>{var g;switch(y.type){case"ACTION":if(typeof y.payload!="string"){console.error("[zustand devtools middleware] Unsupported action format");return}return Vye(y.payload,b=>{if(b.type==="__setState"){if(a===void 0){f(b.state);return}Object.keys(b.state).length!==1&&console.error(`
5578
5578
  [zustand devtools middleware] Unsupported __setState action format.
5579
5579
  When using 'store' option in devtools(), the 'state' should have only one key, which is a value of 'store' that was passed in devtools(),
5580
5580
  and value of this only key should be a state object. Example: { "type": "__setState", "state": { "abc123Store": { "foo": "bar" } } }
@@ -6556,8 +6556,8 @@ to {
6556
6556
  JSZip uses the library pako released under the MIT license :
6557
6557
  https://github.com/nodeca/pako/blob/main/LICENSE
6558
6558
  */(function(i){t.exports=i()})(function(){return(function i(r,o,s){function a(u,d){if(!o[u]){if(!r[u]){var h=typeof P4=="function"&&P4;if(!d&&h)return h(u,!0);if(c)return c(u,!0);var f=new Error("Cannot find module '"+u+"'");throw f.code="MODULE_NOT_FOUND",f}var m=o[u]={exports:{}};r[u][0].call(m.exports,function(y){var g=r[u][1][y];return a(g||y)},m,m.exports,i,r,o,s)}return o[u].exports}for(var c=typeof P4=="function"&&P4,l=0;l<s.length;l++)a(s[l]);return a})({1:[function(i,r,o){var s=i("./utils"),a=i("./support"),c="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";o.encode=function(l){for(var u,d,h,f,m,y,g,b=[],v=0,w=l.length,T=w,N=s.getTypeOf(l)!=="string";v<l.length;)T=w-v,h=N?(u=l[v++],d=v<w?l[v++]:0,v<w?l[v++]:0):(u=l.charCodeAt(v++),d=v<w?l.charCodeAt(v++):0,v<w?l.charCodeAt(v++):0),f=u>>2,m=(3&u)<<4|d>>4,y=1<T?(15&d)<<2|h>>6:64,g=2<T?63&h:64,b.push(c.charAt(f)+c.charAt(m)+c.charAt(y)+c.charAt(g));return b.join("")},o.decode=function(l){var u,d,h,f,m,y,g=0,b=0,v="data:";if(l.substr(0,v.length)===v)throw new Error("Invalid base64 input, it looks like a data url.");var w,T=3*(l=l.replace(/[^A-Za-z0-9+/=]/g,"")).length/4;if(l.charAt(l.length-1)===c.charAt(64)&&T--,l.charAt(l.length-2)===c.charAt(64)&&T--,T%1!=0)throw new Error("Invalid base64 input, bad content length.");for(w=a.uint8array?new Uint8Array(0|T):new Array(0|T);g<l.length;)u=c.indexOf(l.charAt(g++))<<2|(f=c.indexOf(l.charAt(g++)))>>4,d=(15&f)<<4|(m=c.indexOf(l.charAt(g++)))>>2,h=(3&m)<<6|(y=c.indexOf(l.charAt(g++))),w[b++]=u,m!==64&&(w[b++]=d),y!==64&&(w[b++]=h);return w}},{"./support":30,"./utils":32}],2:[function(i,r,o){var s=i("./external"),a=i("./stream/DataWorker"),c=i("./stream/Crc32Probe"),l=i("./stream/DataLengthProbe");function u(d,h,f,m,y){this.compressedSize=d,this.uncompressedSize=h,this.crc32=f,this.compression=m,this.compressedContent=y}u.prototype={getContentWorker:function(){var d=new a(s.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new l("data_length")),h=this;return d.on("end",function(){if(this.streamInfo.data_length!==h.uncompressedSize)throw new Error("Bug : uncompressed data size mismatch")}),d},getCompressedWorker:function(){return new a(s.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",this.crc32).withStreamInfo("compression",this.compression)}},u.createWorkerFrom=function(d,h,f){return d.pipe(new c).pipe(new l("uncompressedSize")).pipe(h.compressWorker(f)).pipe(new l("compressedSize")).withStreamInfo("compression",h)},r.exports=u},{"./external":6,"./stream/Crc32Probe":25,"./stream/DataLengthProbe":26,"./stream/DataWorker":27}],3:[function(i,r,o){var s=i("./stream/GenericWorker");o.STORE={magic:"\0\0",compressWorker:function(){return new s("STORE compression")},uncompressWorker:function(){return new s("STORE decompression")}},o.DEFLATE=i("./flate")},{"./flate":7,"./stream/GenericWorker":28}],4:[function(i,r,o){var s=i("./utils"),a=(function(){for(var c,l=[],u=0;u<256;u++){c=u;for(var d=0;d<8;d++)c=1&c?3988292384^c>>>1:c>>>1;l[u]=c}return l})();r.exports=function(c,l){return c!==void 0&&c.length?s.getTypeOf(c)!=="string"?(function(u,d,h,f){var m=a,y=f+h;u^=-1;for(var g=f;g<y;g++)u=u>>>8^m[255&(u^d[g])];return-1^u})(0|l,c,c.length,0):(function(u,d,h,f){var m=a,y=f+h;u^=-1;for(var g=f;g<y;g++)u=u>>>8^m[255&(u^d.charCodeAt(g))];return-1^u})(0|l,c,c.length,0):0}},{"./utils":32}],5:[function(i,r,o){o.base64=!1,o.binary=!1,o.dir=!1,o.createFolders=!0,o.date=null,o.compression=null,o.compressionOptions=null,o.comment=null,o.unixPermissions=null,o.dosPermissions=null},{}],6:[function(i,r,o){var s=null;s=typeof Promise<"u"?Promise:i("lie"),r.exports={Promise:s}},{lie:37}],7:[function(i,r,o){var s=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Uint32Array<"u",a=i("pako"),c=i("./utils"),l=i("./stream/GenericWorker"),u=s?"uint8array":"array";function d(h,f){l.call(this,"FlateWorker/"+h),this._pako=null,this._pakoAction=h,this._pakoOptions=f,this.meta={}}o.magic="\b\0",c.inherits(d,l),d.prototype.processChunk=function(h){this.meta=h.meta,this._pako===null&&this._createPako(),this._pako.push(c.transformTo(u,h.data),!1)},d.prototype.flush=function(){l.prototype.flush.call(this),this._pako===null&&this._createPako(),this._pako.push([],!0)},d.prototype.cleanUp=function(){l.prototype.cleanUp.call(this),this._pako=null},d.prototype._createPako=function(){this._pako=new a[this._pakoAction]({raw:!0,level:this._pakoOptions.level||-1});var h=this;this._pako.onData=function(f){h.push({data:f,meta:h.meta})}},o.compressWorker=function(h){return new d("Deflate",h)},o.uncompressWorker=function(){return new d("Inflate",{})}},{"./stream/GenericWorker":28,"./utils":32,pako:38}],8:[function(i,r,o){function s(m,y){var g,b="";for(g=0;g<y;g++)b+=String.fromCharCode(255&m),m>>>=8;return b}function a(m,y,g,b,v,w){var T,N,R=m.file,P=m.compression,M=w!==u.utf8encode,I=c.transformTo("string",w(R.name)),A=c.transformTo("string",u.utf8encode(R.name)),$=R.comment,k=c.transformTo("string",w($)),V=c.transformTo("string",u.utf8encode($)),X=A.length!==R.name.length,W=V.length!==$.length,K="",ee="",se="",de=R.dir,be=R.date,re={crc32:0,compressedSize:0,uncompressedSize:0};y&&!g||(re.crc32=m.crc32,re.compressedSize=m.compressedSize,re.uncompressedSize=m.uncompressedSize);var ue=0;y&&(ue|=8),M||!X&&!W||(ue|=2048);var he=0,Te=0;de&&(he|=16),v==="UNIX"?(Te=798,he|=(function(De,Ge){var ke=De;return De||(ke=Ge?16893:33204),(65535&ke)<<16})(R.unixPermissions,de)):(Te=20,he|=(function(De){return 63&(De||0)})(R.dosPermissions)),T=be.getUTCHours(),T<<=6,T|=be.getUTCMinutes(),T<<=5,T|=be.getUTCSeconds()/2,N=be.getUTCFullYear()-1980,N<<=4,N|=be.getUTCMonth()+1,N<<=5,N|=be.getUTCDate(),X&&(ee=s(1,1)+s(d(I),4)+A,K+="up"+s(ee.length,2)+ee),W&&(se=s(1,1)+s(d(k),4)+V,K+="uc"+s(se.length,2)+se);var Ie="";return Ie+=`
6559
- \0`,Ie+=s(ue,2),Ie+=P.magic,Ie+=s(T,2),Ie+=s(N,2),Ie+=s(re.crc32,4),Ie+=s(re.compressedSize,4),Ie+=s(re.uncompressedSize,4),Ie+=s(I.length,2),Ie+=s(K.length,2),{fileRecord:h.LOCAL_FILE_HEADER+Ie+I+K,dirRecord:h.CENTRAL_FILE_HEADER+s(Te,2)+Ie+s(k.length,2)+"\0\0\0\0"+s(he,4)+s(b,4)+I+K+k}}var c=i("../utils"),l=i("../stream/GenericWorker"),u=i("../utf8"),d=i("../crc32"),h=i("../signature");function f(m,y,g,b){l.call(this,"ZipFileWorker"),this.bytesWritten=0,this.zipComment=y,this.zipPlatform=g,this.encodeFileName=b,this.streamFiles=m,this.accumulate=!1,this.contentBuffer=[],this.dirRecords=[],this.currentSourceOffset=0,this.entriesCount=0,this.currentFile=null,this._sources=[]}c.inherits(f,l),f.prototype.push=function(m){var y=m.meta.percent||0,g=this.entriesCount,b=this._sources.length;this.accumulate?this.contentBuffer.push(m):(this.bytesWritten+=m.data.length,l.prototype.push.call(this,{data:m.data,meta:{currentFile:this.currentFile,percent:g?(y+100*(g-b-1))/g:100}}))},f.prototype.openedSource=function(m){this.currentSourceOffset=this.bytesWritten,this.currentFile=m.file.name;var y=this.streamFiles&&!m.file.dir;if(y){var g=a(m,y,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);this.push({data:g.fileRecord,meta:{percent:0}})}else this.accumulate=!0},f.prototype.closedSource=function(m){this.accumulate=!1;var y=this.streamFiles&&!m.file.dir,g=a(m,y,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(g.dirRecord),y)this.push({data:(function(b){return h.DATA_DESCRIPTOR+s(b.crc32,4)+s(b.compressedSize,4)+s(b.uncompressedSize,4)})(m),meta:{percent:100}});else for(this.push({data:g.fileRecord,meta:{percent:0}});this.contentBuffer.length;)this.push(this.contentBuffer.shift());this.currentFile=null},f.prototype.flush=function(){for(var m=this.bytesWritten,y=0;y<this.dirRecords.length;y++)this.push({data:this.dirRecords[y],meta:{percent:100}});var g=this.bytesWritten-m,b=(function(v,w,T,N,R){var P=c.transformTo("string",R(N));return h.CENTRAL_DIRECTORY_END+"\0\0\0\0"+s(v,2)+s(v,2)+s(w,4)+s(T,4)+s(P.length,2)+P})(this.dirRecords.length,g,m,this.zipComment,this.encodeFileName);this.push({data:b,meta:{percent:100}})},f.prototype.prepareNextSource=function(){this.previous=this._sources.shift(),this.openedSource(this.previous.streamInfo),this.isPaused?this.previous.pause():this.previous.resume()},f.prototype.registerPrevious=function(m){this._sources.push(m);var y=this;return m.on("data",function(g){y.processChunk(g)}),m.on("end",function(){y.closedSource(y.previous.streamInfo),y._sources.length?y.prepareNextSource():y.end()}),m.on("error",function(g){y.error(g)}),this},f.prototype.resume=function(){return!!l.prototype.resume.call(this)&&(!this.previous&&this._sources.length?(this.prepareNextSource(),!0):this.previous||this._sources.length||this.generatedError?void 0:(this.end(),!0))},f.prototype.error=function(m){var y=this._sources;if(!l.prototype.error.call(this,m))return!1;for(var g=0;g<y.length;g++)try{y[g].error(m)}catch{}return!0},f.prototype.lock=function(){l.prototype.lock.call(this);for(var m=this._sources,y=0;y<m.length;y++)m[y].lock()},r.exports=f},{"../crc32":4,"../signature":23,"../stream/GenericWorker":28,"../utf8":31,"../utils":32}],9:[function(i,r,o){var s=i("../compressions"),a=i("./ZipFileWorker");o.generateWorker=function(c,l,u){var d=new a(l.streamFiles,u,l.platform,l.encodeFileName),h=0;try{c.forEach(function(f,m){h++;var y=(function(w,T){var N=w||T,R=s[N];if(!R)throw new Error(N+" is not a valid compression method !");return R})(m.options.compression,l.compression),g=m.options.compressionOptions||l.compressionOptions||{},b=m.dir,v=m.date;m._compressWorker(y,g).withStreamInfo("file",{name:f,dir:b,date:v,comment:m.comment||"",unixPermissions:m.unixPermissions,dosPermissions:m.dosPermissions}).pipe(d)}),d.entriesCount=h}catch(f){d.error(f)}return d}},{"../compressions":3,"./ZipFileWorker":8}],10:[function(i,r,o){function s(){if(!(this instanceof s))return new s;if(arguments.length)throw new Error("The constructor with parameters has been removed in JSZip 3.0, please check the upgrade guide.");this.files=Object.create(null),this.comment=null,this.root="",this.clone=function(){var a=new s;for(var c in this)typeof this[c]!="function"&&(a[c]=this[c]);return a}}(s.prototype=i("./object")).loadAsync=i("./load"),s.support=i("./support"),s.defaults=i("./defaults"),s.version="3.10.1",s.loadAsync=function(a,c){return new s().loadAsync(a,c)},s.external=i("./external"),r.exports=s},{"./defaults":5,"./external":6,"./load":11,"./object":15,"./support":30}],11:[function(i,r,o){var s=i("./utils"),a=i("./external"),c=i("./utf8"),l=i("./zipEntries"),u=i("./stream/Crc32Probe"),d=i("./nodejsUtils");function h(f){return new a.Promise(function(m,y){var g=f.decompressed.getContentWorker().pipe(new u);g.on("error",function(b){y(b)}).on("end",function(){g.streamInfo.crc32!==f.decompressed.crc32?y(new Error("Corrupted zip : CRC32 mismatch")):m()}).resume()})}r.exports=function(f,m){var y=this;return m=s.extend(m||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:c.utf8decode}),d.isNode&&d.isStream(f)?a.Promise.reject(new Error("JSZip can't accept a stream when loading a zip file.")):s.prepareContent("the loaded zip file",f,!0,m.optimizedBinaryString,m.base64).then(function(g){var b=new l(m);return b.load(g),b}).then(function(g){var b=[a.Promise.resolve(g)],v=g.files;if(m.checkCRC32)for(var w=0;w<v.length;w++)b.push(h(v[w]));return a.Promise.all(b)}).then(function(g){for(var b=g.shift(),v=b.files,w=0;w<v.length;w++){var T=v[w],N=T.fileNameStr,R=s.resolve(T.fileNameStr);y.file(R,T.decompressed,{binary:!0,optimizedBinaryString:!0,date:T.date,dir:T.dir,comment:T.fileCommentStr.length?T.fileCommentStr:null,unixPermissions:T.unixPermissions,dosPermissions:T.dosPermissions,createFolders:m.createFolders}),T.dir||(y.file(R).unsafeOriginalName=N)}return b.zipComment.length&&(y.comment=b.zipComment),y})}},{"./external":6,"./nodejsUtils":14,"./stream/Crc32Probe":25,"./utf8":31,"./utils":32,"./zipEntries":33}],12:[function(i,r,o){var s=i("../utils"),a=i("../stream/GenericWorker");function c(l,u){a.call(this,"Nodejs stream input adapter for "+l),this._upstreamEnded=!1,this._bindStream(u)}s.inherits(c,a),c.prototype._bindStream=function(l){var u=this;(this._stream=l).pause(),l.on("data",function(d){u.push({data:d,meta:{percent:0}})}).on("error",function(d){u.isPaused?this.generatedError=d:u.error(d)}).on("end",function(){u.isPaused?u._upstreamEnded=!0:u.end()})},c.prototype.pause=function(){return!!a.prototype.pause.call(this)&&(this._stream.pause(),!0)},c.prototype.resume=function(){return!!a.prototype.resume.call(this)&&(this._upstreamEnded?this.end():this._stream.resume(),!0)},r.exports=c},{"../stream/GenericWorker":28,"../utils":32}],13:[function(i,r,o){var s=i("readable-stream").Readable;function a(c,l,u){s.call(this,l),this._helper=c;var d=this;c.on("data",function(h,f){d.push(h)||d._helper.pause(),u&&u(f)}).on("error",function(h){d.emit("error",h)}).on("end",function(){d.push(null)})}i("../utils").inherits(a,s),a.prototype._read=function(){this._helper.resume()},r.exports=a},{"../utils":32,"readable-stream":16}],14:[function(i,r,o){r.exports={isNode:typeof Buffer<"u",newBufferFrom:function(s,a){if(Buffer.from&&Buffer.from!==Uint8Array.from)return Buffer.from(s,a);if(typeof s=="number")throw new Error('The "data" argument must not be a number');return new Buffer(s,a)},allocBuffer:function(s){if(Buffer.alloc)return Buffer.alloc(s);var a=new Buffer(s);return a.fill(0),a},isBuffer:function(s){return Buffer.isBuffer(s)},isStream:function(s){return s&&typeof s.on=="function"&&typeof s.pause=="function"&&typeof s.resume=="function"}}},{}],15:[function(i,r,o){function s(R,P,M){var I,A=c.getTypeOf(P),$=c.extend(M||{},d);$.date=$.date||new Date,$.compression!==null&&($.compression=$.compression.toUpperCase()),typeof $.unixPermissions=="string"&&($.unixPermissions=parseInt($.unixPermissions,8)),$.unixPermissions&&16384&$.unixPermissions&&($.dir=!0),$.dosPermissions&&16&$.dosPermissions&&($.dir=!0),$.dir&&(R=v(R)),$.createFolders&&(I=b(R))&&w.call(this,I,!0);var k=A==="string"&&$.binary===!1&&$.base64===!1;M&&M.binary!==void 0||($.binary=!k),(P instanceof h&&P.uncompressedSize===0||$.dir||!P||P.length===0)&&($.base64=!1,$.binary=!0,P="",$.compression="STORE",A="string");var V=null;V=P instanceof h||P instanceof l?P:y.isNode&&y.isStream(P)?new g(R,P):c.prepareContent(R,P,$.binary,$.optimizedBinaryString,$.base64);var X=new f(R,V,$);this.files[R]=X}var a=i("./utf8"),c=i("./utils"),l=i("./stream/GenericWorker"),u=i("./stream/StreamHelper"),d=i("./defaults"),h=i("./compressedObject"),f=i("./zipObject"),m=i("./generate"),y=i("./nodejsUtils"),g=i("./nodejs/NodejsStreamInputAdapter"),b=function(R){R.slice(-1)==="/"&&(R=R.substring(0,R.length-1));var P=R.lastIndexOf("/");return 0<P?R.substring(0,P):""},v=function(R){return R.slice(-1)!=="/"&&(R+="/"),R},w=function(R,P){return P=P!==void 0?P:d.createFolders,R=v(R),this.files[R]||s.call(this,R,null,{dir:!0,createFolders:P}),this.files[R]};function T(R){return Object.prototype.toString.call(R)==="[object RegExp]"}var N={load:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},forEach:function(R){var P,M,I;for(P in this.files)I=this.files[P],(M=P.slice(this.root.length,P.length))&&P.slice(0,this.root.length)===this.root&&R(M,I)},filter:function(R){var P=[];return this.forEach(function(M,I){R(M,I)&&P.push(I)}),P},file:function(R,P,M){if(arguments.length!==1)return R=this.root+R,s.call(this,R,P,M),this;if(T(R)){var I=R;return this.filter(function($,k){return!k.dir&&I.test($)})}var A=this.files[this.root+R];return A&&!A.dir?A:null},folder:function(R){if(!R)return this;if(T(R))return this.filter(function(A,$){return $.dir&&R.test(A)});var P=this.root+R,M=w.call(this,P),I=this.clone();return I.root=M.name,I},remove:function(R){R=this.root+R;var P=this.files[R];if(P||(R.slice(-1)!=="/"&&(R+="/"),P=this.files[R]),P&&!P.dir)delete this.files[R];else for(var M=this.filter(function(A,$){return $.name.slice(0,R.length)===R}),I=0;I<M.length;I++)delete this.files[M[I].name];return this},generate:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},generateInternalStream:function(R){var P,M={};try{if((M=c.extend(R||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:a.utf8encode})).type=M.type.toLowerCase(),M.compression=M.compression.toUpperCase(),M.type==="binarystring"&&(M.type="string"),!M.type)throw new Error("No output type specified.");c.checkSupport(M.type),M.platform!=="darwin"&&M.platform!=="freebsd"&&M.platform!=="linux"&&M.platform!=="sunos"||(M.platform="UNIX"),M.platform==="win32"&&(M.platform="DOS");var I=M.comment||this.comment||"";P=m.generateWorker(this,M,I)}catch(A){(P=new l("error")).error(A)}return new u(P,M.type||"string",M.mimeType)},generateAsync:function(R,P){return this.generateInternalStream(R).accumulate(P)},generateNodeStream:function(R,P){return(R=R||{}).type||(R.type="nodebuffer"),this.generateInternalStream(R).toNodejsStream(P)}};r.exports=N},{"./compressedObject":2,"./defaults":5,"./generate":9,"./nodejs/NodejsStreamInputAdapter":12,"./nodejsUtils":14,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31,"./utils":32,"./zipObject":35}],16:[function(i,r,o){r.exports=i("stream")},{stream:void 0}],17:[function(i,r,o){var s=i("./DataReader");function a(c){s.call(this,c);for(var l=0;l<this.data.length;l++)c[l]=255&c[l]}i("../utils").inherits(a,s),a.prototype.byteAt=function(c){return this.data[this.zero+c]},a.prototype.lastIndexOfSignature=function(c){for(var l=c.charCodeAt(0),u=c.charCodeAt(1),d=c.charCodeAt(2),h=c.charCodeAt(3),f=this.length-4;0<=f;--f)if(this.data[f]===l&&this.data[f+1]===u&&this.data[f+2]===d&&this.data[f+3]===h)return f-this.zero;return-1},a.prototype.readAndCheckSignature=function(c){var l=c.charCodeAt(0),u=c.charCodeAt(1),d=c.charCodeAt(2),h=c.charCodeAt(3),f=this.readData(4);return l===f[0]&&u===f[1]&&d===f[2]&&h===f[3]},a.prototype.readData=function(c){if(this.checkOffset(c),c===0)return[];var l=this.data.slice(this.zero+this.index,this.zero+this.index+c);return this.index+=c,l},r.exports=a},{"../utils":32,"./DataReader":18}],18:[function(i,r,o){var s=i("../utils");function a(c){this.data=c,this.length=c.length,this.index=0,this.zero=0}a.prototype={checkOffset:function(c){this.checkIndex(this.index+c)},checkIndex:function(c){if(this.length<this.zero+c||c<0)throw new Error("End of data reached (data length = "+this.length+", asked index = "+c+"). Corrupted zip ?")},setIndex:function(c){this.checkIndex(c),this.index=c},skip:function(c){this.setIndex(this.index+c)},byteAt:function(){},readInt:function(c){var l,u=0;for(this.checkOffset(c),l=this.index+c-1;l>=this.index;l--)u=(u<<8)+this.byteAt(l);return this.index+=c,u},readString:function(c){return s.transformTo("string",this.readData(c))},readData:function(){},lastIndexOfSignature:function(){},readAndCheckSignature:function(){},readDate:function(){var c=this.readInt(4);return new Date(Date.UTC(1980+(c>>25&127),(c>>21&15)-1,c>>16&31,c>>11&31,c>>5&63,(31&c)<<1))}},r.exports=a},{"../utils":32}],19:[function(i,r,o){var s=i("./Uint8ArrayReader");function a(c){s.call(this,c)}i("../utils").inherits(a,s),a.prototype.readData=function(c){this.checkOffset(c);var l=this.data.slice(this.zero+this.index,this.zero+this.index+c);return this.index+=c,l},r.exports=a},{"../utils":32,"./Uint8ArrayReader":21}],20:[function(i,r,o){var s=i("./DataReader");function a(c){s.call(this,c)}i("../utils").inherits(a,s),a.prototype.byteAt=function(c){return this.data.charCodeAt(this.zero+c)},a.prototype.lastIndexOfSignature=function(c){return this.data.lastIndexOf(c)-this.zero},a.prototype.readAndCheckSignature=function(c){return c===this.readData(4)},a.prototype.readData=function(c){this.checkOffset(c);var l=this.data.slice(this.zero+this.index,this.zero+this.index+c);return this.index+=c,l},r.exports=a},{"../utils":32,"./DataReader":18}],21:[function(i,r,o){var s=i("./ArrayReader");function a(c){s.call(this,c)}i("../utils").inherits(a,s),a.prototype.readData=function(c){if(this.checkOffset(c),c===0)return new Uint8Array(0);var l=this.data.subarray(this.zero+this.index,this.zero+this.index+c);return this.index+=c,l},r.exports=a},{"../utils":32,"./ArrayReader":17}],22:[function(i,r,o){var s=i("../utils"),a=i("../support"),c=i("./ArrayReader"),l=i("./StringReader"),u=i("./NodeBufferReader"),d=i("./Uint8ArrayReader");r.exports=function(h){var f=s.getTypeOf(h);return s.checkSupport(f),f!=="string"||a.uint8array?f==="nodebuffer"?new u(h):a.uint8array?new d(s.transformTo("uint8array",h)):new c(s.transformTo("array",h)):new l(h)}},{"../support":30,"../utils":32,"./ArrayReader":17,"./NodeBufferReader":19,"./StringReader":20,"./Uint8ArrayReader":21}],23:[function(i,r,o){o.LOCAL_FILE_HEADER="PK",o.CENTRAL_FILE_HEADER="PK",o.CENTRAL_DIRECTORY_END="PK",o.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK\x07",o.ZIP64_CENTRAL_DIRECTORY_END="PK",o.DATA_DESCRIPTOR="PK\x07\b"},{}],24:[function(i,r,o){var s=i("./GenericWorker"),a=i("../utils");function c(l){s.call(this,"ConvertWorker to "+l),this.destType=l}a.inherits(c,s),c.prototype.processChunk=function(l){this.push({data:a.transformTo(this.destType,l.data),meta:l.meta})},r.exports=c},{"../utils":32,"./GenericWorker":28}],25:[function(i,r,o){var s=i("./GenericWorker"),a=i("../crc32");function c(){s.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}i("../utils").inherits(c,s),c.prototype.processChunk=function(l){this.streamInfo.crc32=a(l.data,this.streamInfo.crc32||0),this.push(l)},r.exports=c},{"../crc32":4,"../utils":32,"./GenericWorker":28}],26:[function(i,r,o){var s=i("../utils"),a=i("./GenericWorker");function c(l){a.call(this,"DataLengthProbe for "+l),this.propName=l,this.withStreamInfo(l,0)}s.inherits(c,a),c.prototype.processChunk=function(l){if(l){var u=this.streamInfo[this.propName]||0;this.streamInfo[this.propName]=u+l.data.length}a.prototype.processChunk.call(this,l)},r.exports=c},{"../utils":32,"./GenericWorker":28}],27:[function(i,r,o){var s=i("../utils"),a=i("./GenericWorker");function c(l){a.call(this,"DataWorker");var u=this;this.dataIsReady=!1,this.index=0,this.max=0,this.data=null,this.type="",this._tickScheduled=!1,l.then(function(d){u.dataIsReady=!0,u.data=d,u.max=d&&d.length||0,u.type=s.getTypeOf(d),u.isPaused||u._tickAndRepeat()},function(d){u.error(d)})}s.inherits(c,a),c.prototype.cleanUp=function(){a.prototype.cleanUp.call(this),this.data=null},c.prototype.resume=function(){return!!a.prototype.resume.call(this)&&(!this._tickScheduled&&this.dataIsReady&&(this._tickScheduled=!0,s.delay(this._tickAndRepeat,[],this)),!0)},c.prototype._tickAndRepeat=function(){this._tickScheduled=!1,this.isPaused||this.isFinished||(this._tick(),this.isFinished||(s.delay(this._tickAndRepeat,[],this),this._tickScheduled=!0))},c.prototype._tick=function(){if(this.isPaused||this.isFinished)return!1;var l=null,u=Math.min(this.max,this.index+16384);if(this.index>=this.max)return this.end();switch(this.type){case"string":l=this.data.substring(this.index,u);break;case"uint8array":l=this.data.subarray(this.index,u);break;case"array":case"nodebuffer":l=this.data.slice(this.index,u)}return this.index=u,this.push({data:l,meta:{percent:this.max?this.index/this.max*100:0}})},r.exports=c},{"../utils":32,"./GenericWorker":28}],28:[function(i,r,o){function s(a){this.name=a||"default",this.streamInfo={},this.generatedError=null,this.extraStreamInfo={},this.isPaused=!0,this.isFinished=!1,this.isLocked=!1,this._listeners={data:[],end:[],error:[]},this.previous=null}s.prototype={push:function(a){this.emit("data",a)},end:function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),this.isFinished=!0}catch(a){this.emit("error",a)}return!0},error:function(a){return!this.isFinished&&(this.isPaused?this.generatedError=a:(this.isFinished=!0,this.emit("error",a),this.previous&&this.previous.error(a),this.cleanUp()),!0)},on:function(a,c){return this._listeners[a].push(c),this},cleanUp:function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},emit:function(a,c){if(this._listeners[a])for(var l=0;l<this._listeners[a].length;l++)this._listeners[a][l].call(this,c)},pipe:function(a){return a.registerPrevious(this)},registerPrevious:function(a){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.streamInfo=a.streamInfo,this.mergeStreamInfo(),this.previous=a;var c=this;return a.on("data",function(l){c.processChunk(l)}),a.on("end",function(){c.end()}),a.on("error",function(l){c.error(l)}),this},pause:function(){return!this.isPaused&&!this.isFinished&&(this.isPaused=!0,this.previous&&this.previous.pause(),!0)},resume:function(){if(!this.isPaused||this.isFinished)return!1;var a=this.isPaused=!1;return this.generatedError&&(this.error(this.generatedError),a=!0),this.previous&&this.previous.resume(),!a},flush:function(){},processChunk:function(a){this.push(a)},withStreamInfo:function(a,c){return this.extraStreamInfo[a]=c,this.mergeStreamInfo(),this},mergeStreamInfo:function(){for(var a in this.extraStreamInfo)Object.prototype.hasOwnProperty.call(this.extraStreamInfo,a)&&(this.streamInfo[a]=this.extraStreamInfo[a])},lock:function(){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.isLocked=!0,this.previous&&this.previous.lock()},toString:function(){var a="Worker "+this.name;return this.previous?this.previous+" -> "+a:a}},r.exports=s},{}],29:[function(i,r,o){var s=i("../utils"),a=i("./ConvertWorker"),c=i("./GenericWorker"),l=i("../base64"),u=i("../support"),d=i("../external"),h=null;if(u.nodestream)try{h=i("../nodejs/NodejsStreamOutputAdapter")}catch{}function f(y,g){return new d.Promise(function(b,v){var w=[],T=y._internalType,N=y._outputType,R=y._mimeType;y.on("data",function(P,M){w.push(P),g&&g(M)}).on("error",function(P){w=[],v(P)}).on("end",function(){try{var P=(function(M,I,A){switch(M){case"blob":return s.newBlob(s.transformTo("arraybuffer",I),A);case"base64":return l.encode(I);default:return s.transformTo(M,I)}})(N,(function(M,I){var A,$=0,k=null,V=0;for(A=0;A<I.length;A++)V+=I[A].length;switch(M){case"string":return I.join("");case"array":return Array.prototype.concat.apply([],I);case"uint8array":for(k=new Uint8Array(V),A=0;A<I.length;A++)k.set(I[A],$),$+=I[A].length;return k;case"nodebuffer":return Buffer.concat(I);default:throw new Error("concat : unsupported type '"+M+"'")}})(T,w),R);b(P)}catch(M){v(M)}w=[]}).resume()})}function m(y,g,b){var v=g;switch(g){case"blob":case"arraybuffer":v="uint8array";break;case"base64":v="string"}try{this._internalType=v,this._outputType=g,this._mimeType=b,s.checkSupport(v),this._worker=y.pipe(new a(v)),y.lock()}catch(w){this._worker=new c("error"),this._worker.error(w)}}m.prototype={accumulate:function(y){return f(this,y)},on:function(y,g){var b=this;return y==="data"?this._worker.on(y,function(v){g.call(b,v.data,v.meta)}):this._worker.on(y,function(){s.delay(g,arguments,b)}),this},resume:function(){return s.delay(this._worker.resume,[],this._worker),this},pause:function(){return this._worker.pause(),this},toNodejsStream:function(y){if(s.checkSupport("nodestream"),this._outputType!=="nodebuffer")throw new Error(this._outputType+" is not supported by this method");return new h(this,{objectMode:this._outputType!=="nodebuffer"},y)}},r.exports=m},{"../base64":1,"../external":6,"../nodejs/NodejsStreamOutputAdapter":13,"../support":30,"../utils":32,"./ConvertWorker":24,"./GenericWorker":28}],30:[function(i,r,o){if(o.base64=!0,o.array=!0,o.string=!0,o.arraybuffer=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u",o.nodebuffer=typeof Buffer<"u",o.uint8array=typeof Uint8Array<"u",typeof ArrayBuffer>"u")o.blob=!1;else{var s=new ArrayBuffer(0);try{o.blob=new Blob([s],{type:"application/zip"}).size===0}catch{try{var a=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);a.append(s),o.blob=a.getBlob("application/zip").size===0}catch{o.blob=!1}}}try{o.nodestream=!!i("readable-stream").Readable}catch{o.nodestream=!1}},{"readable-stream":16}],31:[function(i,r,o){for(var s=i("./utils"),a=i("./support"),c=i("./nodejsUtils"),l=i("./stream/GenericWorker"),u=new Array(256),d=0;d<256;d++)u[d]=252<=d?6:248<=d?5:240<=d?4:224<=d?3:192<=d?2:1;u[254]=u[254]=1;function h(){l.call(this,"utf-8 decode"),this.leftOver=null}function f(){l.call(this,"utf-8 encode")}o.utf8encode=function(m){return a.nodebuffer?c.newBufferFrom(m,"utf-8"):(function(y){var g,b,v,w,T,N=y.length,R=0;for(w=0;w<N;w++)(64512&(b=y.charCodeAt(w)))==55296&&w+1<N&&(64512&(v=y.charCodeAt(w+1)))==56320&&(b=65536+(b-55296<<10)+(v-56320),w++),R+=b<128?1:b<2048?2:b<65536?3:4;for(g=a.uint8array?new Uint8Array(R):new Array(R),w=T=0;T<R;w++)(64512&(b=y.charCodeAt(w)))==55296&&w+1<N&&(64512&(v=y.charCodeAt(w+1)))==56320&&(b=65536+(b-55296<<10)+(v-56320),w++),b<128?g[T++]=b:(b<2048?g[T++]=192|b>>>6:(b<65536?g[T++]=224|b>>>12:(g[T++]=240|b>>>18,g[T++]=128|b>>>12&63),g[T++]=128|b>>>6&63),g[T++]=128|63&b);return g})(m)},o.utf8decode=function(m){return a.nodebuffer?s.transformTo("nodebuffer",m).toString("utf-8"):(function(y){var g,b,v,w,T=y.length,N=new Array(2*T);for(g=b=0;g<T;)if((v=y[g++])<128)N[b++]=v;else if(4<(w=u[v]))N[b++]=65533,g+=w-1;else{for(v&=w===2?31:w===3?15:7;1<w&&g<T;)v=v<<6|63&y[g++],w--;1<w?N[b++]=65533:v<65536?N[b++]=v:(v-=65536,N[b++]=55296|v>>10&1023,N[b++]=56320|1023&v)}return N.length!==b&&(N.subarray?N=N.subarray(0,b):N.length=b),s.applyFromCharCode(N)})(m=s.transformTo(a.uint8array?"uint8array":"array",m))},s.inherits(h,l),h.prototype.processChunk=function(m){var y=s.transformTo(a.uint8array?"uint8array":"array",m.data);if(this.leftOver&&this.leftOver.length){if(a.uint8array){var g=y;(y=new Uint8Array(g.length+this.leftOver.length)).set(this.leftOver,0),y.set(g,this.leftOver.length)}else y=this.leftOver.concat(y);this.leftOver=null}var b=(function(w,T){var N;for((T=T||w.length)>w.length&&(T=w.length),N=T-1;0<=N&&(192&w[N])==128;)N--;return N<0||N===0?T:N+u[w[N]]>T?N:T})(y),v=y;b!==y.length&&(a.uint8array?(v=y.subarray(0,b),this.leftOver=y.subarray(b,y.length)):(v=y.slice(0,b),this.leftOver=y.slice(b,y.length))),this.push({data:o.utf8decode(v),meta:m.meta})},h.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:o.utf8decode(this.leftOver),meta:{}}),this.leftOver=null)},o.Utf8DecodeWorker=h,s.inherits(f,l),f.prototype.processChunk=function(m){this.push({data:o.utf8encode(m.data),meta:m.meta})},o.Utf8EncodeWorker=f},{"./nodejsUtils":14,"./stream/GenericWorker":28,"./support":30,"./utils":32}],32:[function(i,r,o){var s=i("./support"),a=i("./base64"),c=i("./nodejsUtils"),l=i("./external");function u(g){return g}function d(g,b){for(var v=0;v<g.length;++v)b[v]=255&g.charCodeAt(v);return b}i("setimmediate"),o.newBlob=function(g,b){o.checkSupport("blob");try{return new Blob([g],{type:b})}catch{try{var v=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);return v.append(g),v.getBlob(b)}catch{throw new Error("Bug : can't construct the Blob.")}}};var h={stringifyByChunk:function(g,b,v){var w=[],T=0,N=g.length;if(N<=v)return String.fromCharCode.apply(null,g);for(;T<N;)b==="array"||b==="nodebuffer"?w.push(String.fromCharCode.apply(null,g.slice(T,Math.min(T+v,N)))):w.push(String.fromCharCode.apply(null,g.subarray(T,Math.min(T+v,N)))),T+=v;return w.join("")},stringifyByChar:function(g){for(var b="",v=0;v<g.length;v++)b+=String.fromCharCode(g[v]);return b},applyCanBeUsed:{uint8array:(function(){try{return s.uint8array&&String.fromCharCode.apply(null,new Uint8Array(1)).length===1}catch{return!1}})(),nodebuffer:(function(){try{return s.nodebuffer&&String.fromCharCode.apply(null,c.allocBuffer(1)).length===1}catch{return!1}})()}};function f(g){var b=65536,v=o.getTypeOf(g),w=!0;if(v==="uint8array"?w=h.applyCanBeUsed.uint8array:v==="nodebuffer"&&(w=h.applyCanBeUsed.nodebuffer),w)for(;1<b;)try{return h.stringifyByChunk(g,v,b)}catch{b=Math.floor(b/2)}return h.stringifyByChar(g)}function m(g,b){for(var v=0;v<g.length;v++)b[v]=g[v];return b}o.applyFromCharCode=f;var y={};y.string={string:u,array:function(g){return d(g,new Array(g.length))},arraybuffer:function(g){return y.string.uint8array(g).buffer},uint8array:function(g){return d(g,new Uint8Array(g.length))},nodebuffer:function(g){return d(g,c.allocBuffer(g.length))}},y.array={string:f,array:u,arraybuffer:function(g){return new Uint8Array(g).buffer},uint8array:function(g){return new Uint8Array(g)},nodebuffer:function(g){return c.newBufferFrom(g)}},y.arraybuffer={string:function(g){return f(new Uint8Array(g))},array:function(g){return m(new Uint8Array(g),new Array(g.byteLength))},arraybuffer:u,uint8array:function(g){return new Uint8Array(g)},nodebuffer:function(g){return c.newBufferFrom(new Uint8Array(g))}},y.uint8array={string:f,array:function(g){return m(g,new Array(g.length))},arraybuffer:function(g){return g.buffer},uint8array:u,nodebuffer:function(g){return c.newBufferFrom(g)}},y.nodebuffer={string:f,array:function(g){return m(g,new Array(g.length))},arraybuffer:function(g){return y.nodebuffer.uint8array(g).buffer},uint8array:function(g){return m(g,new Uint8Array(g.length))},nodebuffer:u},o.transformTo=function(g,b){if(b=b||"",!g)return b;o.checkSupport(g);var v=o.getTypeOf(b);return y[v][g](b)},o.resolve=function(g){for(var b=g.split("/"),v=[],w=0;w<b.length;w++){var T=b[w];T==="."||T===""&&w!==0&&w!==b.length-1||(T===".."?v.pop():v.push(T))}return v.join("/")},o.getTypeOf=function(g){return typeof g=="string"?"string":Object.prototype.toString.call(g)==="[object Array]"?"array":s.nodebuffer&&c.isBuffer(g)?"nodebuffer":s.uint8array&&g instanceof Uint8Array?"uint8array":s.arraybuffer&&g instanceof ArrayBuffer?"arraybuffer":void 0},o.checkSupport=function(g){if(!s[g.toLowerCase()])throw new Error(g+" is not supported by this platform")},o.MAX_VALUE_16BITS=65535,o.MAX_VALUE_32BITS=-1,o.pretty=function(g){var b,v,w="";for(v=0;v<(g||"").length;v++)w+="\\x"+((b=g.charCodeAt(v))<16?"0":"")+b.toString(16).toUpperCase();return w},o.delay=function(g,b,v){setImmediate(function(){g.apply(v||null,b||[])})},o.inherits=function(g,b){function v(){}v.prototype=b.prototype,g.prototype=new v},o.extend=function(){var g,b,v={};for(g=0;g<arguments.length;g++)for(b in arguments[g])Object.prototype.hasOwnProperty.call(arguments[g],b)&&v[b]===void 0&&(v[b]=arguments[g][b]);return v},o.prepareContent=function(g,b,v,w,T){return l.Promise.resolve(b).then(function(N){return s.blob&&(N instanceof Blob||["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(N))!==-1)&&typeof FileReader<"u"?new l.Promise(function(R,P){var M=new FileReader;M.onload=function(I){R(I.target.result)},M.onerror=function(I){P(I.target.error)},M.readAsArrayBuffer(N)}):N}).then(function(N){var R=o.getTypeOf(N);return R?(R==="arraybuffer"?N=o.transformTo("uint8array",N):R==="string"&&(T?N=a.decode(N):v&&w!==!0&&(N=(function(P){return d(P,s.uint8array?new Uint8Array(P.length):new Array(P.length))})(N))),N):l.Promise.reject(new Error("Can't read the data of '"+g+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"))})}},{"./base64":1,"./external":6,"./nodejsUtils":14,"./support":30,setimmediate:54}],33:[function(i,r,o){var s=i("./reader/readerFor"),a=i("./utils"),c=i("./signature"),l=i("./zipEntry"),u=i("./support");function d(h){this.files=[],this.loadOptions=h}d.prototype={checkSignature:function(h){if(!this.reader.readAndCheckSignature(h)){this.reader.index-=4;var f=this.reader.readString(4);throw new Error("Corrupted zip or bug: unexpected signature ("+a.pretty(f)+", expected "+a.pretty(h)+")")}},isSignature:function(h,f){var m=this.reader.index;this.reader.setIndex(h);var y=this.reader.readString(4)===f;return this.reader.setIndex(m),y},readBlockEndOfCentral:function(){this.diskNumber=this.reader.readInt(2),this.diskWithCentralDirStart=this.reader.readInt(2),this.centralDirRecordsOnThisDisk=this.reader.readInt(2),this.centralDirRecords=this.reader.readInt(2),this.centralDirSize=this.reader.readInt(4),this.centralDirOffset=this.reader.readInt(4),this.zipCommentLength=this.reader.readInt(2);var h=this.reader.readData(this.zipCommentLength),f=u.uint8array?"uint8array":"array",m=a.transformTo(f,h);this.zipComment=this.loadOptions.decodeFileName(m)},readBlockZip64EndOfCentral:function(){this.zip64EndOfCentralSize=this.reader.readInt(8),this.reader.skip(4),this.diskNumber=this.reader.readInt(4),this.diskWithCentralDirStart=this.reader.readInt(4),this.centralDirRecordsOnThisDisk=this.reader.readInt(8),this.centralDirRecords=this.reader.readInt(8),this.centralDirSize=this.reader.readInt(8),this.centralDirOffset=this.reader.readInt(8),this.zip64ExtensibleData={};for(var h,f,m,y=this.zip64EndOfCentralSize-44;0<y;)h=this.reader.readInt(2),f=this.reader.readInt(4),m=this.reader.readData(f),this.zip64ExtensibleData[h]={id:h,length:f,value:m}},readBlockZip64EndOfCentralLocator:function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),1<this.disksCount)throw new Error("Multi-volumes zip are not supported")},readLocalFiles:function(){var h,f;for(h=0;h<this.files.length;h++)f=this.files[h],this.reader.setIndex(f.localHeaderOffset),this.checkSignature(c.LOCAL_FILE_HEADER),f.readLocalPart(this.reader),f.handleUTF8(),f.processAttributes()},readCentralDir:function(){var h;for(this.reader.setIndex(this.centralDirOffset);this.reader.readAndCheckSignature(c.CENTRAL_FILE_HEADER);)(h=new l({zip64:this.zip64},this.loadOptions)).readCentralPart(this.reader),this.files.push(h);if(this.centralDirRecords!==this.files.length&&this.centralDirRecords!==0&&this.files.length===0)throw new Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length)},readEndOfCentral:function(){var h=this.reader.lastIndexOfSignature(c.CENTRAL_DIRECTORY_END);if(h<0)throw this.isSignature(0,c.LOCAL_FILE_HEADER)?new Error("Corrupted zip: can't find end of central directory"):new Error("Can't find end of central directory : is this a zip file ? If it is, see https://stuk.github.io/jszip/documentation/howto/read_zip.html");this.reader.setIndex(h);var f=h;if(this.checkSignature(c.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===a.MAX_VALUE_16BITS||this.diskWithCentralDirStart===a.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===a.MAX_VALUE_16BITS||this.centralDirRecords===a.MAX_VALUE_16BITS||this.centralDirSize===a.MAX_VALUE_32BITS||this.centralDirOffset===a.MAX_VALUE_32BITS){if(this.zip64=!0,(h=this.reader.lastIndexOfSignature(c.ZIP64_CENTRAL_DIRECTORY_LOCATOR))<0)throw new Error("Corrupted zip: can't find the ZIP64 end of central directory locator");if(this.reader.setIndex(h),this.checkSignature(c.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,c.ZIP64_CENTRAL_DIRECTORY_END)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(c.ZIP64_CENTRAL_DIRECTORY_END),this.relativeOffsetEndOfZip64CentralDir<0))throw new Error("Corrupted zip: can't find the ZIP64 end of central directory");this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir),this.checkSignature(c.ZIP64_CENTRAL_DIRECTORY_END),this.readBlockZip64EndOfCentral()}var m=this.centralDirOffset+this.centralDirSize;this.zip64&&(m+=20,m+=12+this.zip64EndOfCentralSize);var y=f-m;if(0<y)this.isSignature(f,c.CENTRAL_FILE_HEADER)||(this.reader.zero=y);else if(y<0)throw new Error("Corrupted zip: missing "+Math.abs(y)+" bytes.")},prepareReader:function(h){this.reader=s(h)},load:function(h){this.prepareReader(h),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()}},r.exports=d},{"./reader/readerFor":22,"./signature":23,"./support":30,"./utils":32,"./zipEntry":34}],34:[function(i,r,o){var s=i("./reader/readerFor"),a=i("./utils"),c=i("./compressedObject"),l=i("./crc32"),u=i("./utf8"),d=i("./compressions"),h=i("./support");function f(m,y){this.options=m,this.loadOptions=y}f.prototype={isEncrypted:function(){return(1&this.bitFlag)==1},useUTF8:function(){return(2048&this.bitFlag)==2048},readLocalPart:function(m){var y,g;if(m.skip(22),this.fileNameLength=m.readInt(2),g=m.readInt(2),this.fileName=m.readData(this.fileNameLength),m.skip(g),this.compressedSize===-1||this.uncompressedSize===-1)throw new Error("Bug or corrupted zip : didn't get enough information from the central directory (compressedSize === -1 || uncompressedSize === -1)");if((y=(function(b){for(var v in d)if(Object.prototype.hasOwnProperty.call(d,v)&&d[v].magic===b)return d[v];return null})(this.compressionMethod))===null)throw new Error("Corrupted zip : compression "+a.pretty(this.compressionMethod)+" unknown (inner file : "+a.transformTo("string",this.fileName)+")");this.decompressed=new c(this.compressedSize,this.uncompressedSize,this.crc32,y,m.readData(this.compressedSize))},readCentralPart:function(m){this.versionMadeBy=m.readInt(2),m.skip(2),this.bitFlag=m.readInt(2),this.compressionMethod=m.readString(2),this.date=m.readDate(),this.crc32=m.readInt(4),this.compressedSize=m.readInt(4),this.uncompressedSize=m.readInt(4);var y=m.readInt(2);if(this.extraFieldsLength=m.readInt(2),this.fileCommentLength=m.readInt(2),this.diskNumberStart=m.readInt(2),this.internalFileAttributes=m.readInt(2),this.externalFileAttributes=m.readInt(4),this.localHeaderOffset=m.readInt(4),this.isEncrypted())throw new Error("Encrypted zip are not supported");m.skip(y),this.readExtraFields(m),this.parseZIP64ExtraField(m),this.fileComment=m.readData(this.fileCommentLength)},processAttributes:function(){this.unixPermissions=null,this.dosPermissions=null;var m=this.versionMadeBy>>8;this.dir=!!(16&this.externalFileAttributes),m==0&&(this.dosPermissions=63&this.externalFileAttributes),m==3&&(this.unixPermissions=this.externalFileAttributes>>16&65535),this.dir||this.fileNameStr.slice(-1)!=="/"||(this.dir=!0)},parseZIP64ExtraField:function(){if(this.extraFields[1]){var m=s(this.extraFields[1].value);this.uncompressedSize===a.MAX_VALUE_32BITS&&(this.uncompressedSize=m.readInt(8)),this.compressedSize===a.MAX_VALUE_32BITS&&(this.compressedSize=m.readInt(8)),this.localHeaderOffset===a.MAX_VALUE_32BITS&&(this.localHeaderOffset=m.readInt(8)),this.diskNumberStart===a.MAX_VALUE_32BITS&&(this.diskNumberStart=m.readInt(4))}},readExtraFields:function(m){var y,g,b,v=m.index+this.extraFieldsLength;for(this.extraFields||(this.extraFields={});m.index+4<v;)y=m.readInt(2),g=m.readInt(2),b=m.readData(g),this.extraFields[y]={id:y,length:g,value:b};m.setIndex(v)},handleUTF8:function(){var m=h.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=u.utf8decode(this.fileName),this.fileCommentStr=u.utf8decode(this.fileComment);else{var y=this.findExtraFieldUnicodePath();if(y!==null)this.fileNameStr=y;else{var g=a.transformTo(m,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(g)}var b=this.findExtraFieldUnicodeComment();if(b!==null)this.fileCommentStr=b;else{var v=a.transformTo(m,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(v)}}},findExtraFieldUnicodePath:function(){var m=this.extraFields[28789];if(m){var y=s(m.value);return y.readInt(1)!==1||l(this.fileName)!==y.readInt(4)?null:u.utf8decode(y.readData(m.length-5))}return null},findExtraFieldUnicodeComment:function(){var m=this.extraFields[25461];if(m){var y=s(m.value);return y.readInt(1)!==1||l(this.fileComment)!==y.readInt(4)?null:u.utf8decode(y.readData(m.length-5))}return null}},r.exports=f},{"./compressedObject":2,"./compressions":3,"./crc32":4,"./reader/readerFor":22,"./support":30,"./utf8":31,"./utils":32}],35:[function(i,r,o){function s(y,g,b){this.name=y,this.dir=b.dir,this.date=b.date,this.comment=b.comment,this.unixPermissions=b.unixPermissions,this.dosPermissions=b.dosPermissions,this._data=g,this._dataBinary=b.binary,this.options={compression:b.compression,compressionOptions:b.compressionOptions}}var a=i("./stream/StreamHelper"),c=i("./stream/DataWorker"),l=i("./utf8"),u=i("./compressedObject"),d=i("./stream/GenericWorker");s.prototype={internalStream:function(y){var g=null,b="string";try{if(!y)throw new Error("No output type specified.");var v=(b=y.toLowerCase())==="string"||b==="text";b!=="binarystring"&&b!=="text"||(b="string"),g=this._decompressWorker();var w=!this._dataBinary;w&&!v&&(g=g.pipe(new l.Utf8EncodeWorker)),!w&&v&&(g=g.pipe(new l.Utf8DecodeWorker))}catch(T){(g=new d("error")).error(T)}return new a(g,b,"")},async:function(y,g){return this.internalStream(y).accumulate(g)},nodeStream:function(y,g){return this.internalStream(y||"nodebuffer").toNodejsStream(g)},_compressWorker:function(y,g){if(this._data instanceof u&&this._data.compression.magic===y.magic)return this._data.getCompressedWorker();var b=this._decompressWorker();return this._dataBinary||(b=b.pipe(new l.Utf8EncodeWorker)),u.createWorkerFrom(b,y,g)},_decompressWorker:function(){return this._data instanceof u?this._data.getContentWorker():this._data instanceof d?this._data:new c(this._data)}};for(var h=["asText","asBinary","asNodeBuffer","asUint8Array","asArrayBuffer"],f=function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},m=0;m<h.length;m++)s.prototype[h[m]]=f;r.exports=s},{"./compressedObject":2,"./stream/DataWorker":27,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31}],36:[function(i,r,o){(function(s){var a,c,l=s.MutationObserver||s.WebKitMutationObserver;if(l){var u=0,d=new l(y),h=s.document.createTextNode("");d.observe(h,{characterData:!0}),a=function(){h.data=u=++u%2}}else if(s.setImmediate||s.MessageChannel===void 0)a="document"in s&&"onreadystatechange"in s.document.createElement("script")?function(){var g=s.document.createElement("script");g.onreadystatechange=function(){y(),g.onreadystatechange=null,g.parentNode.removeChild(g),g=null},s.document.documentElement.appendChild(g)}:function(){setTimeout(y,0)};else{var f=new s.MessageChannel;f.port1.onmessage=y,a=function(){f.port2.postMessage(0)}}var m=[];function y(){var g,b;c=!0;for(var v=m.length;v;){for(b=m,m=[],g=-1;++g<v;)b[g]();v=m.length}c=!1}r.exports=function(g){m.push(g)!==1||c||a()}}).call(this,typeof FO<"u"?FO:typeof self<"u"?self:typeof window<"u"?window:{})},{}],37:[function(i,r,o){var s=i("immediate");function a(){}var c={},l=["REJECTED"],u=["FULFILLED"],d=["PENDING"];function h(v){if(typeof v!="function")throw new TypeError("resolver must be a function");this.state=d,this.queue=[],this.outcome=void 0,v!==a&&g(this,v)}function f(v,w,T){this.promise=v,typeof w=="function"&&(this.onFulfilled=w,this.callFulfilled=this.otherCallFulfilled),typeof T=="function"&&(this.onRejected=T,this.callRejected=this.otherCallRejected)}function m(v,w,T){s(function(){var N;try{N=w(T)}catch(R){return c.reject(v,R)}N===v?c.reject(v,new TypeError("Cannot resolve promise with itself")):c.resolve(v,N)})}function y(v){var w=v&&v.then;if(v&&(typeof v=="object"||typeof v=="function")&&typeof w=="function")return function(){w.apply(v,arguments)}}function g(v,w){var T=!1;function N(M){T||(T=!0,c.reject(v,M))}function R(M){T||(T=!0,c.resolve(v,M))}var P=b(function(){w(R,N)});P.status==="error"&&N(P.value)}function b(v,w){var T={};try{T.value=v(w),T.status="success"}catch(N){T.status="error",T.value=N}return T}(r.exports=h).prototype.finally=function(v){if(typeof v!="function")return this;var w=this.constructor;return this.then(function(T){return w.resolve(v()).then(function(){return T})},function(T){return w.resolve(v()).then(function(){throw T})})},h.prototype.catch=function(v){return this.then(null,v)},h.prototype.then=function(v,w){if(typeof v!="function"&&this.state===u||typeof w!="function"&&this.state===l)return this;var T=new this.constructor(a);return this.state!==d?m(T,this.state===u?v:w,this.outcome):this.queue.push(new f(T,v,w)),T},f.prototype.callFulfilled=function(v){c.resolve(this.promise,v)},f.prototype.otherCallFulfilled=function(v){m(this.promise,this.onFulfilled,v)},f.prototype.callRejected=function(v){c.reject(this.promise,v)},f.prototype.otherCallRejected=function(v){m(this.promise,this.onRejected,v)},c.resolve=function(v,w){var T=b(y,w);if(T.status==="error")return c.reject(v,T.value);var N=T.value;if(N)g(v,N);else{v.state=u,v.outcome=w;for(var R=-1,P=v.queue.length;++R<P;)v.queue[R].callFulfilled(w)}return v},c.reject=function(v,w){v.state=l,v.outcome=w;for(var T=-1,N=v.queue.length;++T<N;)v.queue[T].callRejected(w);return v},h.resolve=function(v){return v instanceof this?v:c.resolve(new this(a),v)},h.reject=function(v){var w=new this(a);return c.reject(w,v)},h.all=function(v){var w=this;if(Object.prototype.toString.call(v)!=="[object Array]")return this.reject(new TypeError("must be an array"));var T=v.length,N=!1;if(!T)return this.resolve([]);for(var R=new Array(T),P=0,M=-1,I=new this(a);++M<T;)A(v[M],M);return I;function A($,k){w.resolve($).then(function(V){R[k]=V,++P!==T||N||(N=!0,c.resolve(I,R))},function(V){N||(N=!0,c.reject(I,V))})}},h.race=function(v){var w=this;if(Object.prototype.toString.call(v)!=="[object Array]")return this.reject(new TypeError("must be an array"));var T=v.length,N=!1;if(!T)return this.resolve([]);for(var R=-1,P=new this(a);++R<T;)M=v[R],w.resolve(M).then(function(I){N||(N=!0,c.resolve(P,I))},function(I){N||(N=!0,c.reject(P,I))});var M;return P}},{immediate:36}],38:[function(i,r,o){var s={};(0,i("./lib/utils/common").assign)(s,i("./lib/deflate"),i("./lib/inflate"),i("./lib/zlib/constants")),r.exports=s},{"./lib/deflate":39,"./lib/inflate":40,"./lib/utils/common":41,"./lib/zlib/constants":44}],39:[function(i,r,o){var s=i("./zlib/deflate"),a=i("./utils/common"),c=i("./utils/strings"),l=i("./zlib/messages"),u=i("./zlib/zstream"),d=Object.prototype.toString,h=0,f=-1,m=0,y=8;function g(v){if(!(this instanceof g))return new g(v);this.options=a.assign({level:f,method:y,chunkSize:16384,windowBits:15,memLevel:8,strategy:m,to:""},v||{});var w=this.options;w.raw&&0<w.windowBits?w.windowBits=-w.windowBits:w.gzip&&0<w.windowBits&&w.windowBits<16&&(w.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new u,this.strm.avail_out=0;var T=s.deflateInit2(this.strm,w.level,w.method,w.windowBits,w.memLevel,w.strategy);if(T!==h)throw new Error(l[T]);if(w.header&&s.deflateSetHeader(this.strm,w.header),w.dictionary){var N;if(N=typeof w.dictionary=="string"?c.string2buf(w.dictionary):d.call(w.dictionary)==="[object ArrayBuffer]"?new Uint8Array(w.dictionary):w.dictionary,(T=s.deflateSetDictionary(this.strm,N))!==h)throw new Error(l[T]);this._dict_set=!0}}function b(v,w){var T=new g(w);if(T.push(v,!0),T.err)throw T.msg||l[T.err];return T.result}g.prototype.push=function(v,w){var T,N,R=this.strm,P=this.options.chunkSize;if(this.ended)return!1;N=w===~~w?w:w===!0?4:0,typeof v=="string"?R.input=c.string2buf(v):d.call(v)==="[object ArrayBuffer]"?R.input=new Uint8Array(v):R.input=v,R.next_in=0,R.avail_in=R.input.length;do{if(R.avail_out===0&&(R.output=new a.Buf8(P),R.next_out=0,R.avail_out=P),(T=s.deflate(R,N))!==1&&T!==h)return this.onEnd(T),!(this.ended=!0);R.avail_out!==0&&(R.avail_in!==0||N!==4&&N!==2)||(this.options.to==="string"?this.onData(c.buf2binstring(a.shrinkBuf(R.output,R.next_out))):this.onData(a.shrinkBuf(R.output,R.next_out)))}while((0<R.avail_in||R.avail_out===0)&&T!==1);return N===4?(T=s.deflateEnd(this.strm),this.onEnd(T),this.ended=!0,T===h):N!==2||(this.onEnd(h),!(R.avail_out=0))},g.prototype.onData=function(v){this.chunks.push(v)},g.prototype.onEnd=function(v){v===h&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=a.flattenChunks(this.chunks)),this.chunks=[],this.err=v,this.msg=this.strm.msg},o.Deflate=g,o.deflate=b,o.deflateRaw=function(v,w){return(w=w||{}).raw=!0,b(v,w)},o.gzip=function(v,w){return(w=w||{}).gzip=!0,b(v,w)}},{"./utils/common":41,"./utils/strings":42,"./zlib/deflate":46,"./zlib/messages":51,"./zlib/zstream":53}],40:[function(i,r,o){var s=i("./zlib/inflate"),a=i("./utils/common"),c=i("./utils/strings"),l=i("./zlib/constants"),u=i("./zlib/messages"),d=i("./zlib/zstream"),h=i("./zlib/gzheader"),f=Object.prototype.toString;function m(g){if(!(this instanceof m))return new m(g);this.options=a.assign({chunkSize:16384,windowBits:0,to:""},g||{});var b=this.options;b.raw&&0<=b.windowBits&&b.windowBits<16&&(b.windowBits=-b.windowBits,b.windowBits===0&&(b.windowBits=-15)),!(0<=b.windowBits&&b.windowBits<16)||g&&g.windowBits||(b.windowBits+=32),15<b.windowBits&&b.windowBits<48&&(15&b.windowBits)==0&&(b.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new d,this.strm.avail_out=0;var v=s.inflateInit2(this.strm,b.windowBits);if(v!==l.Z_OK)throw new Error(u[v]);this.header=new h,s.inflateGetHeader(this.strm,this.header)}function y(g,b){var v=new m(b);if(v.push(g,!0),v.err)throw v.msg||u[v.err];return v.result}m.prototype.push=function(g,b){var v,w,T,N,R,P,M=this.strm,I=this.options.chunkSize,A=this.options.dictionary,$=!1;if(this.ended)return!1;w=b===~~b?b:b===!0?l.Z_FINISH:l.Z_NO_FLUSH,typeof g=="string"?M.input=c.binstring2buf(g):f.call(g)==="[object ArrayBuffer]"?M.input=new Uint8Array(g):M.input=g,M.next_in=0,M.avail_in=M.input.length;do{if(M.avail_out===0&&(M.output=new a.Buf8(I),M.next_out=0,M.avail_out=I),(v=s.inflate(M,l.Z_NO_FLUSH))===l.Z_NEED_DICT&&A&&(P=typeof A=="string"?c.string2buf(A):f.call(A)==="[object ArrayBuffer]"?new Uint8Array(A):A,v=s.inflateSetDictionary(this.strm,P)),v===l.Z_BUF_ERROR&&$===!0&&(v=l.Z_OK,$=!1),v!==l.Z_STREAM_END&&v!==l.Z_OK)return this.onEnd(v),!(this.ended=!0);M.next_out&&(M.avail_out!==0&&v!==l.Z_STREAM_END&&(M.avail_in!==0||w!==l.Z_FINISH&&w!==l.Z_SYNC_FLUSH)||(this.options.to==="string"?(T=c.utf8border(M.output,M.next_out),N=M.next_out-T,R=c.buf2string(M.output,T),M.next_out=N,M.avail_out=I-N,N&&a.arraySet(M.output,M.output,T,N,0),this.onData(R)):this.onData(a.shrinkBuf(M.output,M.next_out)))),M.avail_in===0&&M.avail_out===0&&($=!0)}while((0<M.avail_in||M.avail_out===0)&&v!==l.Z_STREAM_END);return v===l.Z_STREAM_END&&(w=l.Z_FINISH),w===l.Z_FINISH?(v=s.inflateEnd(this.strm),this.onEnd(v),this.ended=!0,v===l.Z_OK):w!==l.Z_SYNC_FLUSH||(this.onEnd(l.Z_OK),!(M.avail_out=0))},m.prototype.onData=function(g){this.chunks.push(g)},m.prototype.onEnd=function(g){g===l.Z_OK&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=a.flattenChunks(this.chunks)),this.chunks=[],this.err=g,this.msg=this.strm.msg},o.Inflate=m,o.inflate=y,o.inflateRaw=function(g,b){return(b=b||{}).raw=!0,y(g,b)},o.ungzip=y},{"./utils/common":41,"./utils/strings":42,"./zlib/constants":44,"./zlib/gzheader":47,"./zlib/inflate":49,"./zlib/messages":51,"./zlib/zstream":53}],41:[function(i,r,o){var s=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Int32Array<"u";o.assign=function(l){for(var u=Array.prototype.slice.call(arguments,1);u.length;){var d=u.shift();if(d){if(typeof d!="object")throw new TypeError(d+"must be non-object");for(var h in d)d.hasOwnProperty(h)&&(l[h]=d[h])}}return l},o.shrinkBuf=function(l,u){return l.length===u?l:l.subarray?l.subarray(0,u):(l.length=u,l)};var a={arraySet:function(l,u,d,h,f){if(u.subarray&&l.subarray)l.set(u.subarray(d,d+h),f);else for(var m=0;m<h;m++)l[f+m]=u[d+m]},flattenChunks:function(l){var u,d,h,f,m,y;for(u=h=0,d=l.length;u<d;u++)h+=l[u].length;for(y=new Uint8Array(h),u=f=0,d=l.length;u<d;u++)m=l[u],y.set(m,f),f+=m.length;return y}},c={arraySet:function(l,u,d,h,f){for(var m=0;m<h;m++)l[f+m]=u[d+m]},flattenChunks:function(l){return[].concat.apply([],l)}};o.setTyped=function(l){l?(o.Buf8=Uint8Array,o.Buf16=Uint16Array,o.Buf32=Int32Array,o.assign(o,a)):(o.Buf8=Array,o.Buf16=Array,o.Buf32=Array,o.assign(o,c))},o.setTyped(s)},{}],42:[function(i,r,o){var s=i("./common"),a=!0,c=!0;try{String.fromCharCode.apply(null,[0])}catch{a=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{c=!1}for(var l=new s.Buf8(256),u=0;u<256;u++)l[u]=252<=u?6:248<=u?5:240<=u?4:224<=u?3:192<=u?2:1;function d(h,f){if(f<65537&&(h.subarray&&c||!h.subarray&&a))return String.fromCharCode.apply(null,s.shrinkBuf(h,f));for(var m="",y=0;y<f;y++)m+=String.fromCharCode(h[y]);return m}l[254]=l[254]=1,o.string2buf=function(h){var f,m,y,g,b,v=h.length,w=0;for(g=0;g<v;g++)(64512&(m=h.charCodeAt(g)))==55296&&g+1<v&&(64512&(y=h.charCodeAt(g+1)))==56320&&(m=65536+(m-55296<<10)+(y-56320),g++),w+=m<128?1:m<2048?2:m<65536?3:4;for(f=new s.Buf8(w),g=b=0;b<w;g++)(64512&(m=h.charCodeAt(g)))==55296&&g+1<v&&(64512&(y=h.charCodeAt(g+1)))==56320&&(m=65536+(m-55296<<10)+(y-56320),g++),m<128?f[b++]=m:(m<2048?f[b++]=192|m>>>6:(m<65536?f[b++]=224|m>>>12:(f[b++]=240|m>>>18,f[b++]=128|m>>>12&63),f[b++]=128|m>>>6&63),f[b++]=128|63&m);return f},o.buf2binstring=function(h){return d(h,h.length)},o.binstring2buf=function(h){for(var f=new s.Buf8(h.length),m=0,y=f.length;m<y;m++)f[m]=h.charCodeAt(m);return f},o.buf2string=function(h,f){var m,y,g,b,v=f||h.length,w=new Array(2*v);for(m=y=0;m<v;)if((g=h[m++])<128)w[y++]=g;else if(4<(b=l[g]))w[y++]=65533,m+=b-1;else{for(g&=b===2?31:b===3?15:7;1<b&&m<v;)g=g<<6|63&h[m++],b--;1<b?w[y++]=65533:g<65536?w[y++]=g:(g-=65536,w[y++]=55296|g>>10&1023,w[y++]=56320|1023&g)}return d(w,y)},o.utf8border=function(h,f){var m;for((f=f||h.length)>h.length&&(f=h.length),m=f-1;0<=m&&(192&h[m])==128;)m--;return m<0||m===0?f:m+l[h[m]]>f?m:f}},{"./common":41}],43:[function(i,r,o){r.exports=function(s,a,c,l){for(var u=65535&s|0,d=s>>>16&65535|0,h=0;c!==0;){for(c-=h=2e3<c?2e3:c;d=d+(u=u+a[l++]|0)|0,--h;);u%=65521,d%=65521}return u|d<<16|0}},{}],44:[function(i,r,o){r.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],45:[function(i,r,o){var s=(function(){for(var a,c=[],l=0;l<256;l++){a=l;for(var u=0;u<8;u++)a=1&a?3988292384^a>>>1:a>>>1;c[l]=a}return c})();r.exports=function(a,c,l,u){var d=s,h=u+l;a^=-1;for(var f=u;f<h;f++)a=a>>>8^d[255&(a^c[f])];return-1^a}},{}],46:[function(i,r,o){var s,a=i("../utils/common"),c=i("./trees"),l=i("./adler32"),u=i("./crc32"),d=i("./messages"),h=0,f=4,m=0,y=-2,g=-1,b=4,v=2,w=8,T=9,N=286,R=30,P=19,M=2*N+1,I=15,A=3,$=258,k=$+A+1,V=42,X=113,W=1,K=2,ee=3,se=4;function de(Se,dt){return Se.msg=d[dt],dt}function be(Se){return(Se<<1)-(4<Se?9:0)}function re(Se){for(var dt=Se.length;0<=--dt;)Se[dt]=0}function ue(Se){var dt=Se.state,Ke=dt.pending;Ke>Se.avail_out&&(Ke=Se.avail_out),Ke!==0&&(a.arraySet(Se.output,dt.pending_buf,dt.pending_out,Ke,Se.next_out),Se.next_out+=Ke,dt.pending_out+=Ke,Se.total_out+=Ke,Se.avail_out-=Ke,dt.pending-=Ke,dt.pending===0&&(dt.pending_out=0))}function he(Se,dt){c._tr_flush_block(Se,0<=Se.block_start?Se.block_start:-1,Se.strstart-Se.block_start,dt),Se.block_start=Se.strstart,ue(Se.strm)}function Te(Se,dt){Se.pending_buf[Se.pending++]=dt}function Ie(Se,dt){Se.pending_buf[Se.pending++]=dt>>>8&255,Se.pending_buf[Se.pending++]=255&dt}function De(Se,dt){var Ke,Xe,Qe=Se.max_chain_length,He=Se.strstart,Pe=Se.prev_length,Ye=Se.nice_match,Oe=Se.strstart>Se.w_size-k?Se.strstart-(Se.w_size-k):0,Ze=Se.window,nt=Se.w_mask,pt=Se.prev,gt=Se.strstart+$,Et=Ze[He+Pe-1],Nt=Ze[He+Pe];Se.prev_length>=Se.good_match&&(Qe>>=2),Ye>Se.lookahead&&(Ye=Se.lookahead);do if(Ze[(Ke=dt)+Pe]===Nt&&Ze[Ke+Pe-1]===Et&&Ze[Ke]===Ze[He]&&Ze[++Ke]===Ze[He+1]){He+=2,Ke++;do;while(Ze[++He]===Ze[++Ke]&&Ze[++He]===Ze[++Ke]&&Ze[++He]===Ze[++Ke]&&Ze[++He]===Ze[++Ke]&&Ze[++He]===Ze[++Ke]&&Ze[++He]===Ze[++Ke]&&Ze[++He]===Ze[++Ke]&&Ze[++He]===Ze[++Ke]&&He<gt);if(Xe=$-(gt-He),He=gt-$,Pe<Xe){if(Se.match_start=dt,Ye<=(Pe=Xe))break;Et=Ze[He+Pe-1],Nt=Ze[He+Pe]}}while((dt=pt[dt&nt])>Oe&&--Qe!=0);return Pe<=Se.lookahead?Pe:Se.lookahead}function Ge(Se){var dt,Ke,Xe,Qe,He,Pe,Ye,Oe,Ze,nt,pt=Se.w_size;do{if(Qe=Se.window_size-Se.lookahead-Se.strstart,Se.strstart>=pt+(pt-k)){for(a.arraySet(Se.window,Se.window,pt,pt,0),Se.match_start-=pt,Se.strstart-=pt,Se.block_start-=pt,dt=Ke=Se.hash_size;Xe=Se.head[--dt],Se.head[dt]=pt<=Xe?Xe-pt:0,--Ke;);for(dt=Ke=pt;Xe=Se.prev[--dt],Se.prev[dt]=pt<=Xe?Xe-pt:0,--Ke;);Qe+=pt}if(Se.strm.avail_in===0)break;if(Pe=Se.strm,Ye=Se.window,Oe=Se.strstart+Se.lookahead,Ze=Qe,nt=void 0,nt=Pe.avail_in,Ze<nt&&(nt=Ze),Ke=nt===0?0:(Pe.avail_in-=nt,a.arraySet(Ye,Pe.input,Pe.next_in,nt,Oe),Pe.state.wrap===1?Pe.adler=l(Pe.adler,Ye,nt,Oe):Pe.state.wrap===2&&(Pe.adler=u(Pe.adler,Ye,nt,Oe)),Pe.next_in+=nt,Pe.total_in+=nt,nt),Se.lookahead+=Ke,Se.lookahead+Se.insert>=A)for(He=Se.strstart-Se.insert,Se.ins_h=Se.window[He],Se.ins_h=(Se.ins_h<<Se.hash_shift^Se.window[He+1])&Se.hash_mask;Se.insert&&(Se.ins_h=(Se.ins_h<<Se.hash_shift^Se.window[He+A-1])&Se.hash_mask,Se.prev[He&Se.w_mask]=Se.head[Se.ins_h],Se.head[Se.ins_h]=He,He++,Se.insert--,!(Se.lookahead+Se.insert<A)););}while(Se.lookahead<k&&Se.strm.avail_in!==0)}function ke(Se,dt){for(var Ke,Xe;;){if(Se.lookahead<k){if(Ge(Se),Se.lookahead<k&&dt===h)return W;if(Se.lookahead===0)break}if(Ke=0,Se.lookahead>=A&&(Se.ins_h=(Se.ins_h<<Se.hash_shift^Se.window[Se.strstart+A-1])&Se.hash_mask,Ke=Se.prev[Se.strstart&Se.w_mask]=Se.head[Se.ins_h],Se.head[Se.ins_h]=Se.strstart),Ke!==0&&Se.strstart-Ke<=Se.w_size-k&&(Se.match_length=De(Se,Ke)),Se.match_length>=A)if(Xe=c._tr_tally(Se,Se.strstart-Se.match_start,Se.match_length-A),Se.lookahead-=Se.match_length,Se.match_length<=Se.max_lazy_match&&Se.lookahead>=A){for(Se.match_length--;Se.strstart++,Se.ins_h=(Se.ins_h<<Se.hash_shift^Se.window[Se.strstart+A-1])&Se.hash_mask,Ke=Se.prev[Se.strstart&Se.w_mask]=Se.head[Se.ins_h],Se.head[Se.ins_h]=Se.strstart,--Se.match_length!=0;);Se.strstart++}else Se.strstart+=Se.match_length,Se.match_length=0,Se.ins_h=Se.window[Se.strstart],Se.ins_h=(Se.ins_h<<Se.hash_shift^Se.window[Se.strstart+1])&Se.hash_mask;else Xe=c._tr_tally(Se,0,Se.window[Se.strstart]),Se.lookahead--,Se.strstart++;if(Xe&&(he(Se,!1),Se.strm.avail_out===0))return W}return Se.insert=Se.strstart<A-1?Se.strstart:A-1,dt===f?(he(Se,!0),Se.strm.avail_out===0?ee:se):Se.last_lit&&(he(Se,!1),Se.strm.avail_out===0)?W:K}function ce(Se,dt){for(var Ke,Xe,Qe;;){if(Se.lookahead<k){if(Ge(Se),Se.lookahead<k&&dt===h)return W;if(Se.lookahead===0)break}if(Ke=0,Se.lookahead>=A&&(Se.ins_h=(Se.ins_h<<Se.hash_shift^Se.window[Se.strstart+A-1])&Se.hash_mask,Ke=Se.prev[Se.strstart&Se.w_mask]=Se.head[Se.ins_h],Se.head[Se.ins_h]=Se.strstart),Se.prev_length=Se.match_length,Se.prev_match=Se.match_start,Se.match_length=A-1,Ke!==0&&Se.prev_length<Se.max_lazy_match&&Se.strstart-Ke<=Se.w_size-k&&(Se.match_length=De(Se,Ke),Se.match_length<=5&&(Se.strategy===1||Se.match_length===A&&4096<Se.strstart-Se.match_start)&&(Se.match_length=A-1)),Se.prev_length>=A&&Se.match_length<=Se.prev_length){for(Qe=Se.strstart+Se.lookahead-A,Xe=c._tr_tally(Se,Se.strstart-1-Se.prev_match,Se.prev_length-A),Se.lookahead-=Se.prev_length-1,Se.prev_length-=2;++Se.strstart<=Qe&&(Se.ins_h=(Se.ins_h<<Se.hash_shift^Se.window[Se.strstart+A-1])&Se.hash_mask,Ke=Se.prev[Se.strstart&Se.w_mask]=Se.head[Se.ins_h],Se.head[Se.ins_h]=Se.strstart),--Se.prev_length!=0;);if(Se.match_available=0,Se.match_length=A-1,Se.strstart++,Xe&&(he(Se,!1),Se.strm.avail_out===0))return W}else if(Se.match_available){if((Xe=c._tr_tally(Se,0,Se.window[Se.strstart-1]))&&he(Se,!1),Se.strstart++,Se.lookahead--,Se.strm.avail_out===0)return W}else Se.match_available=1,Se.strstart++,Se.lookahead--}return Se.match_available&&(Xe=c._tr_tally(Se,0,Se.window[Se.strstart-1]),Se.match_available=0),Se.insert=Se.strstart<A-1?Se.strstart:A-1,dt===f?(he(Se,!0),Se.strm.avail_out===0?ee:se):Se.last_lit&&(he(Se,!1),Se.strm.avail_out===0)?W:K}function we(Se,dt,Ke,Xe,Qe){this.good_length=Se,this.max_lazy=dt,this.nice_length=Ke,this.max_chain=Xe,this.func=Qe}function xe(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=w,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new a.Buf16(2*M),this.dyn_dtree=new a.Buf16(2*(2*R+1)),this.bl_tree=new a.Buf16(2*(2*P+1)),re(this.dyn_ltree),re(this.dyn_dtree),re(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new a.Buf16(I+1),this.heap=new a.Buf16(2*N+1),re(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new a.Buf16(2*N+1),re(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function qe(Se){var dt;return Se&&Se.state?(Se.total_in=Se.total_out=0,Se.data_type=v,(dt=Se.state).pending=0,dt.pending_out=0,dt.wrap<0&&(dt.wrap=-dt.wrap),dt.status=dt.wrap?V:X,Se.adler=dt.wrap===2?0:1,dt.last_flush=h,c._tr_init(dt),m):de(Se,y)}function et(Se){var dt=qe(Se);return dt===m&&(function(Ke){Ke.window_size=2*Ke.w_size,re(Ke.head),Ke.max_lazy_match=s[Ke.level].max_lazy,Ke.good_match=s[Ke.level].good_length,Ke.nice_match=s[Ke.level].nice_length,Ke.max_chain_length=s[Ke.level].max_chain,Ke.strstart=0,Ke.block_start=0,Ke.lookahead=0,Ke.insert=0,Ke.match_length=Ke.prev_length=A-1,Ke.match_available=0,Ke.ins_h=0})(Se.state),dt}function ot(Se,dt,Ke,Xe,Qe,He){if(!Se)return y;var Pe=1;if(dt===g&&(dt=6),Xe<0?(Pe=0,Xe=-Xe):15<Xe&&(Pe=2,Xe-=16),Qe<1||T<Qe||Ke!==w||Xe<8||15<Xe||dt<0||9<dt||He<0||b<He)return de(Se,y);Xe===8&&(Xe=9);var Ye=new xe;return(Se.state=Ye).strm=Se,Ye.wrap=Pe,Ye.gzhead=null,Ye.w_bits=Xe,Ye.w_size=1<<Ye.w_bits,Ye.w_mask=Ye.w_size-1,Ye.hash_bits=Qe+7,Ye.hash_size=1<<Ye.hash_bits,Ye.hash_mask=Ye.hash_size-1,Ye.hash_shift=~~((Ye.hash_bits+A-1)/A),Ye.window=new a.Buf8(2*Ye.w_size),Ye.head=new a.Buf16(Ye.hash_size),Ye.prev=new a.Buf16(Ye.w_size),Ye.lit_bufsize=1<<Qe+6,Ye.pending_buf_size=4*Ye.lit_bufsize,Ye.pending_buf=new a.Buf8(Ye.pending_buf_size),Ye.d_buf=1*Ye.lit_bufsize,Ye.l_buf=3*Ye.lit_bufsize,Ye.level=dt,Ye.strategy=He,Ye.method=Ke,et(Se)}s=[new we(0,0,0,0,function(Se,dt){var Ke=65535;for(Ke>Se.pending_buf_size-5&&(Ke=Se.pending_buf_size-5);;){if(Se.lookahead<=1){if(Ge(Se),Se.lookahead===0&&dt===h)return W;if(Se.lookahead===0)break}Se.strstart+=Se.lookahead,Se.lookahead=0;var Xe=Se.block_start+Ke;if((Se.strstart===0||Se.strstart>=Xe)&&(Se.lookahead=Se.strstart-Xe,Se.strstart=Xe,he(Se,!1),Se.strm.avail_out===0)||Se.strstart-Se.block_start>=Se.w_size-k&&(he(Se,!1),Se.strm.avail_out===0))return W}return Se.insert=0,dt===f?(he(Se,!0),Se.strm.avail_out===0?ee:se):(Se.strstart>Se.block_start&&(he(Se,!1),Se.strm.avail_out),W)}),new we(4,4,8,4,ke),new we(4,5,16,8,ke),new we(4,6,32,32,ke),new we(4,4,16,16,ce),new we(8,16,32,32,ce),new we(8,16,128,128,ce),new we(8,32,128,256,ce),new we(32,128,258,1024,ce),new we(32,258,258,4096,ce)],o.deflateInit=function(Se,dt){return ot(Se,dt,w,15,8,0)},o.deflateInit2=ot,o.deflateReset=et,o.deflateResetKeep=qe,o.deflateSetHeader=function(Se,dt){return Se&&Se.state?Se.state.wrap!==2?y:(Se.state.gzhead=dt,m):y},o.deflate=function(Se,dt){var Ke,Xe,Qe,He;if(!Se||!Se.state||5<dt||dt<0)return Se?de(Se,y):y;if(Xe=Se.state,!Se.output||!Se.input&&Se.avail_in!==0||Xe.status===666&&dt!==f)return de(Se,Se.avail_out===0?-5:y);if(Xe.strm=Se,Ke=Xe.last_flush,Xe.last_flush=dt,Xe.status===V)if(Xe.wrap===2)Se.adler=0,Te(Xe,31),Te(Xe,139),Te(Xe,8),Xe.gzhead?(Te(Xe,(Xe.gzhead.text?1:0)+(Xe.gzhead.hcrc?2:0)+(Xe.gzhead.extra?4:0)+(Xe.gzhead.name?8:0)+(Xe.gzhead.comment?16:0)),Te(Xe,255&Xe.gzhead.time),Te(Xe,Xe.gzhead.time>>8&255),Te(Xe,Xe.gzhead.time>>16&255),Te(Xe,Xe.gzhead.time>>24&255),Te(Xe,Xe.level===9?2:2<=Xe.strategy||Xe.level<2?4:0),Te(Xe,255&Xe.gzhead.os),Xe.gzhead.extra&&Xe.gzhead.extra.length&&(Te(Xe,255&Xe.gzhead.extra.length),Te(Xe,Xe.gzhead.extra.length>>8&255)),Xe.gzhead.hcrc&&(Se.adler=u(Se.adler,Xe.pending_buf,Xe.pending,0)),Xe.gzindex=0,Xe.status=69):(Te(Xe,0),Te(Xe,0),Te(Xe,0),Te(Xe,0),Te(Xe,0),Te(Xe,Xe.level===9?2:2<=Xe.strategy||Xe.level<2?4:0),Te(Xe,3),Xe.status=X);else{var Pe=w+(Xe.w_bits-8<<4)<<8;Pe|=(2<=Xe.strategy||Xe.level<2?0:Xe.level<6?1:Xe.level===6?2:3)<<6,Xe.strstart!==0&&(Pe|=32),Pe+=31-Pe%31,Xe.status=X,Ie(Xe,Pe),Xe.strstart!==0&&(Ie(Xe,Se.adler>>>16),Ie(Xe,65535&Se.adler)),Se.adler=1}if(Xe.status===69)if(Xe.gzhead.extra){for(Qe=Xe.pending;Xe.gzindex<(65535&Xe.gzhead.extra.length)&&(Xe.pending!==Xe.pending_buf_size||(Xe.gzhead.hcrc&&Xe.pending>Qe&&(Se.adler=u(Se.adler,Xe.pending_buf,Xe.pending-Qe,Qe)),ue(Se),Qe=Xe.pending,Xe.pending!==Xe.pending_buf_size));)Te(Xe,255&Xe.gzhead.extra[Xe.gzindex]),Xe.gzindex++;Xe.gzhead.hcrc&&Xe.pending>Qe&&(Se.adler=u(Se.adler,Xe.pending_buf,Xe.pending-Qe,Qe)),Xe.gzindex===Xe.gzhead.extra.length&&(Xe.gzindex=0,Xe.status=73)}else Xe.status=73;if(Xe.status===73)if(Xe.gzhead.name){Qe=Xe.pending;do{if(Xe.pending===Xe.pending_buf_size&&(Xe.gzhead.hcrc&&Xe.pending>Qe&&(Se.adler=u(Se.adler,Xe.pending_buf,Xe.pending-Qe,Qe)),ue(Se),Qe=Xe.pending,Xe.pending===Xe.pending_buf_size)){He=1;break}He=Xe.gzindex<Xe.gzhead.name.length?255&Xe.gzhead.name.charCodeAt(Xe.gzindex++):0,Te(Xe,He)}while(He!==0);Xe.gzhead.hcrc&&Xe.pending>Qe&&(Se.adler=u(Se.adler,Xe.pending_buf,Xe.pending-Qe,Qe)),He===0&&(Xe.gzindex=0,Xe.status=91)}else Xe.status=91;if(Xe.status===91)if(Xe.gzhead.comment){Qe=Xe.pending;do{if(Xe.pending===Xe.pending_buf_size&&(Xe.gzhead.hcrc&&Xe.pending>Qe&&(Se.adler=u(Se.adler,Xe.pending_buf,Xe.pending-Qe,Qe)),ue(Se),Qe=Xe.pending,Xe.pending===Xe.pending_buf_size)){He=1;break}He=Xe.gzindex<Xe.gzhead.comment.length?255&Xe.gzhead.comment.charCodeAt(Xe.gzindex++):0,Te(Xe,He)}while(He!==0);Xe.gzhead.hcrc&&Xe.pending>Qe&&(Se.adler=u(Se.adler,Xe.pending_buf,Xe.pending-Qe,Qe)),He===0&&(Xe.status=103)}else Xe.status=103;if(Xe.status===103&&(Xe.gzhead.hcrc?(Xe.pending+2>Xe.pending_buf_size&&ue(Se),Xe.pending+2<=Xe.pending_buf_size&&(Te(Xe,255&Se.adler),Te(Xe,Se.adler>>8&255),Se.adler=0,Xe.status=X)):Xe.status=X),Xe.pending!==0){if(ue(Se),Se.avail_out===0)return Xe.last_flush=-1,m}else if(Se.avail_in===0&&be(dt)<=be(Ke)&&dt!==f)return de(Se,-5);if(Xe.status===666&&Se.avail_in!==0)return de(Se,-5);if(Se.avail_in!==0||Xe.lookahead!==0||dt!==h&&Xe.status!==666){var Ye=Xe.strategy===2?(function(Oe,Ze){for(var nt;;){if(Oe.lookahead===0&&(Ge(Oe),Oe.lookahead===0)){if(Ze===h)return W;break}if(Oe.match_length=0,nt=c._tr_tally(Oe,0,Oe.window[Oe.strstart]),Oe.lookahead--,Oe.strstart++,nt&&(he(Oe,!1),Oe.strm.avail_out===0))return W}return Oe.insert=0,Ze===f?(he(Oe,!0),Oe.strm.avail_out===0?ee:se):Oe.last_lit&&(he(Oe,!1),Oe.strm.avail_out===0)?W:K})(Xe,dt):Xe.strategy===3?(function(Oe,Ze){for(var nt,pt,gt,Et,Nt=Oe.window;;){if(Oe.lookahead<=$){if(Ge(Oe),Oe.lookahead<=$&&Ze===h)return W;if(Oe.lookahead===0)break}if(Oe.match_length=0,Oe.lookahead>=A&&0<Oe.strstart&&(pt=Nt[gt=Oe.strstart-1])===Nt[++gt]&&pt===Nt[++gt]&&pt===Nt[++gt]){Et=Oe.strstart+$;do;while(pt===Nt[++gt]&&pt===Nt[++gt]&&pt===Nt[++gt]&&pt===Nt[++gt]&&pt===Nt[++gt]&&pt===Nt[++gt]&&pt===Nt[++gt]&&pt===Nt[++gt]&&gt<Et);Oe.match_length=$-(Et-gt),Oe.match_length>Oe.lookahead&&(Oe.match_length=Oe.lookahead)}if(Oe.match_length>=A?(nt=c._tr_tally(Oe,1,Oe.match_length-A),Oe.lookahead-=Oe.match_length,Oe.strstart+=Oe.match_length,Oe.match_length=0):(nt=c._tr_tally(Oe,0,Oe.window[Oe.strstart]),Oe.lookahead--,Oe.strstart++),nt&&(he(Oe,!1),Oe.strm.avail_out===0))return W}return Oe.insert=0,Ze===f?(he(Oe,!0),Oe.strm.avail_out===0?ee:se):Oe.last_lit&&(he(Oe,!1),Oe.strm.avail_out===0)?W:K})(Xe,dt):s[Xe.level].func(Xe,dt);if(Ye!==ee&&Ye!==se||(Xe.status=666),Ye===W||Ye===ee)return Se.avail_out===0&&(Xe.last_flush=-1),m;if(Ye===K&&(dt===1?c._tr_align(Xe):dt!==5&&(c._tr_stored_block(Xe,0,0,!1),dt===3&&(re(Xe.head),Xe.lookahead===0&&(Xe.strstart=0,Xe.block_start=0,Xe.insert=0))),ue(Se),Se.avail_out===0))return Xe.last_flush=-1,m}return dt!==f?m:Xe.wrap<=0?1:(Xe.wrap===2?(Te(Xe,255&Se.adler),Te(Xe,Se.adler>>8&255),Te(Xe,Se.adler>>16&255),Te(Xe,Se.adler>>24&255),Te(Xe,255&Se.total_in),Te(Xe,Se.total_in>>8&255),Te(Xe,Se.total_in>>16&255),Te(Xe,Se.total_in>>24&255)):(Ie(Xe,Se.adler>>>16),Ie(Xe,65535&Se.adler)),ue(Se),0<Xe.wrap&&(Xe.wrap=-Xe.wrap),Xe.pending!==0?m:1)},o.deflateEnd=function(Se){var dt;return Se&&Se.state?(dt=Se.state.status)!==V&&dt!==69&&dt!==73&&dt!==91&&dt!==103&&dt!==X&&dt!==666?de(Se,y):(Se.state=null,dt===X?de(Se,-3):m):y},o.deflateSetDictionary=function(Se,dt){var Ke,Xe,Qe,He,Pe,Ye,Oe,Ze,nt=dt.length;if(!Se||!Se.state||(He=(Ke=Se.state).wrap)===2||He===1&&Ke.status!==V||Ke.lookahead)return y;for(He===1&&(Se.adler=l(Se.adler,dt,nt,0)),Ke.wrap=0,nt>=Ke.w_size&&(He===0&&(re(Ke.head),Ke.strstart=0,Ke.block_start=0,Ke.insert=0),Ze=new a.Buf8(Ke.w_size),a.arraySet(Ze,dt,nt-Ke.w_size,Ke.w_size,0),dt=Ze,nt=Ke.w_size),Pe=Se.avail_in,Ye=Se.next_in,Oe=Se.input,Se.avail_in=nt,Se.next_in=0,Se.input=dt,Ge(Ke);Ke.lookahead>=A;){for(Xe=Ke.strstart,Qe=Ke.lookahead-(A-1);Ke.ins_h=(Ke.ins_h<<Ke.hash_shift^Ke.window[Xe+A-1])&Ke.hash_mask,Ke.prev[Xe&Ke.w_mask]=Ke.head[Ke.ins_h],Ke.head[Ke.ins_h]=Xe,Xe++,--Qe;);Ke.strstart=Xe,Ke.lookahead=A-1,Ge(Ke)}return Ke.strstart+=Ke.lookahead,Ke.block_start=Ke.strstart,Ke.insert=Ke.lookahead,Ke.lookahead=0,Ke.match_length=Ke.prev_length=A-1,Ke.match_available=0,Se.next_in=Ye,Se.input=Oe,Se.avail_in=Pe,Ke.wrap=He,m},o.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":41,"./adler32":43,"./crc32":45,"./messages":51,"./trees":52}],47:[function(i,r,o){r.exports=function(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}},{}],48:[function(i,r,o){r.exports=function(s,a){var c,l,u,d,h,f,m,y,g,b,v,w,T,N,R,P,M,I,A,$,k,V,X,W,K;c=s.state,l=s.next_in,W=s.input,u=l+(s.avail_in-5),d=s.next_out,K=s.output,h=d-(a-s.avail_out),f=d+(s.avail_out-257),m=c.dmax,y=c.wsize,g=c.whave,b=c.wnext,v=c.window,w=c.hold,T=c.bits,N=c.lencode,R=c.distcode,P=(1<<c.lenbits)-1,M=(1<<c.distbits)-1;e:do{T<15&&(w+=W[l++]<<T,T+=8,w+=W[l++]<<T,T+=8),I=N[w&P];t:for(;;){if(w>>>=A=I>>>24,T-=A,(A=I>>>16&255)===0)K[d++]=65535&I;else{if(!(16&A)){if((64&A)==0){I=N[(65535&I)+(w&(1<<A)-1)];continue t}if(32&A){c.mode=12;break e}s.msg="invalid literal/length code",c.mode=30;break e}$=65535&I,(A&=15)&&(T<A&&(w+=W[l++]<<T,T+=8),$+=w&(1<<A)-1,w>>>=A,T-=A),T<15&&(w+=W[l++]<<T,T+=8,w+=W[l++]<<T,T+=8),I=R[w&M];n:for(;;){if(w>>>=A=I>>>24,T-=A,!(16&(A=I>>>16&255))){if((64&A)==0){I=R[(65535&I)+(w&(1<<A)-1)];continue n}s.msg="invalid distance code",c.mode=30;break e}if(k=65535&I,T<(A&=15)&&(w+=W[l++]<<T,(T+=8)<A&&(w+=W[l++]<<T,T+=8)),m<(k+=w&(1<<A)-1)){s.msg="invalid distance too far back",c.mode=30;break e}if(w>>>=A,T-=A,(A=d-h)<k){if(g<(A=k-A)&&c.sane){s.msg="invalid distance too far back",c.mode=30;break e}if(X=v,(V=0)===b){if(V+=y-A,A<$){for($-=A;K[d++]=v[V++],--A;);V=d-k,X=K}}else if(b<A){if(V+=y+b-A,(A-=b)<$){for($-=A;K[d++]=v[V++],--A;);if(V=0,b<$){for($-=A=b;K[d++]=v[V++],--A;);V=d-k,X=K}}}else if(V+=b-A,A<$){for($-=A;K[d++]=v[V++],--A;);V=d-k,X=K}for(;2<$;)K[d++]=X[V++],K[d++]=X[V++],K[d++]=X[V++],$-=3;$&&(K[d++]=X[V++],1<$&&(K[d++]=X[V++]))}else{for(V=d-k;K[d++]=K[V++],K[d++]=K[V++],K[d++]=K[V++],2<($-=3););$&&(K[d++]=K[V++],1<$&&(K[d++]=K[V++]))}break}}break}}while(l<u&&d<f);l-=$=T>>3,w&=(1<<(T-=$<<3))-1,s.next_in=l,s.next_out=d,s.avail_in=l<u?u-l+5:5-(l-u),s.avail_out=d<f?f-d+257:257-(d-f),c.hold=w,c.bits=T}},{}],49:[function(i,r,o){var s=i("../utils/common"),a=i("./adler32"),c=i("./crc32"),l=i("./inffast"),u=i("./inftrees"),d=1,h=2,f=0,m=-2,y=1,g=852,b=592;function v(V){return(V>>>24&255)+(V>>>8&65280)+((65280&V)<<8)+((255&V)<<24)}function w(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new s.Buf16(320),this.work=new s.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function T(V){var X;return V&&V.state?(X=V.state,V.total_in=V.total_out=X.total=0,V.msg="",X.wrap&&(V.adler=1&X.wrap),X.mode=y,X.last=0,X.havedict=0,X.dmax=32768,X.head=null,X.hold=0,X.bits=0,X.lencode=X.lendyn=new s.Buf32(g),X.distcode=X.distdyn=new s.Buf32(b),X.sane=1,X.back=-1,f):m}function N(V){var X;return V&&V.state?((X=V.state).wsize=0,X.whave=0,X.wnext=0,T(V)):m}function R(V,X){var W,K;return V&&V.state?(K=V.state,X<0?(W=0,X=-X):(W=1+(X>>4),X<48&&(X&=15)),X&&(X<8||15<X)?m:(K.window!==null&&K.wbits!==X&&(K.window=null),K.wrap=W,K.wbits=X,N(V))):m}function P(V,X){var W,K;return V?(K=new w,(V.state=K).window=null,(W=R(V,X))!==f&&(V.state=null),W):m}var M,I,A=!0;function $(V){if(A){var X;for(M=new s.Buf32(512),I=new s.Buf32(32),X=0;X<144;)V.lens[X++]=8;for(;X<256;)V.lens[X++]=9;for(;X<280;)V.lens[X++]=7;for(;X<288;)V.lens[X++]=8;for(u(d,V.lens,0,288,M,0,V.work,{bits:9}),X=0;X<32;)V.lens[X++]=5;u(h,V.lens,0,32,I,0,V.work,{bits:5}),A=!1}V.lencode=M,V.lenbits=9,V.distcode=I,V.distbits=5}function k(V,X,W,K){var ee,se=V.state;return se.window===null&&(se.wsize=1<<se.wbits,se.wnext=0,se.whave=0,se.window=new s.Buf8(se.wsize)),K>=se.wsize?(s.arraySet(se.window,X,W-se.wsize,se.wsize,0),se.wnext=0,se.whave=se.wsize):(K<(ee=se.wsize-se.wnext)&&(ee=K),s.arraySet(se.window,X,W-K,ee,se.wnext),(K-=ee)?(s.arraySet(se.window,X,W-K,K,0),se.wnext=K,se.whave=se.wsize):(se.wnext+=ee,se.wnext===se.wsize&&(se.wnext=0),se.whave<se.wsize&&(se.whave+=ee))),0}o.inflateReset=N,o.inflateReset2=R,o.inflateResetKeep=T,o.inflateInit=function(V){return P(V,15)},o.inflateInit2=P,o.inflate=function(V,X){var W,K,ee,se,de,be,re,ue,he,Te,Ie,De,Ge,ke,ce,we,xe,qe,et,ot,Se,dt,Ke,Xe,Qe=0,He=new s.Buf8(4),Pe=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!V||!V.state||!V.output||!V.input&&V.avail_in!==0)return m;(W=V.state).mode===12&&(W.mode=13),de=V.next_out,ee=V.output,re=V.avail_out,se=V.next_in,K=V.input,be=V.avail_in,ue=W.hold,he=W.bits,Te=be,Ie=re,dt=f;e:for(;;)switch(W.mode){case y:if(W.wrap===0){W.mode=13;break}for(;he<16;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if(2&W.wrap&&ue===35615){He[W.check=0]=255&ue,He[1]=ue>>>8&255,W.check=c(W.check,He,2,0),he=ue=0,W.mode=2;break}if(W.flags=0,W.head&&(W.head.done=!1),!(1&W.wrap)||(((255&ue)<<8)+(ue>>8))%31){V.msg="incorrect header check",W.mode=30;break}if((15&ue)!=8){V.msg="unknown compression method",W.mode=30;break}if(he-=4,Se=8+(15&(ue>>>=4)),W.wbits===0)W.wbits=Se;else if(Se>W.wbits){V.msg="invalid window size",W.mode=30;break}W.dmax=1<<Se,V.adler=W.check=1,W.mode=512&ue?10:12,he=ue=0;break;case 2:for(;he<16;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if(W.flags=ue,(255&W.flags)!=8){V.msg="unknown compression method",W.mode=30;break}if(57344&W.flags){V.msg="unknown header flags set",W.mode=30;break}W.head&&(W.head.text=ue>>8&1),512&W.flags&&(He[0]=255&ue,He[1]=ue>>>8&255,W.check=c(W.check,He,2,0)),he=ue=0,W.mode=3;case 3:for(;he<32;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}W.head&&(W.head.time=ue),512&W.flags&&(He[0]=255&ue,He[1]=ue>>>8&255,He[2]=ue>>>16&255,He[3]=ue>>>24&255,W.check=c(W.check,He,4,0)),he=ue=0,W.mode=4;case 4:for(;he<16;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}W.head&&(W.head.xflags=255&ue,W.head.os=ue>>8),512&W.flags&&(He[0]=255&ue,He[1]=ue>>>8&255,W.check=c(W.check,He,2,0)),he=ue=0,W.mode=5;case 5:if(1024&W.flags){for(;he<16;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}W.length=ue,W.head&&(W.head.extra_len=ue),512&W.flags&&(He[0]=255&ue,He[1]=ue>>>8&255,W.check=c(W.check,He,2,0)),he=ue=0}else W.head&&(W.head.extra=null);W.mode=6;case 6:if(1024&W.flags&&(be<(De=W.length)&&(De=be),De&&(W.head&&(Se=W.head.extra_len-W.length,W.head.extra||(W.head.extra=new Array(W.head.extra_len)),s.arraySet(W.head.extra,K,se,De,Se)),512&W.flags&&(W.check=c(W.check,K,De,se)),be-=De,se+=De,W.length-=De),W.length))break e;W.length=0,W.mode=7;case 7:if(2048&W.flags){if(be===0)break e;for(De=0;Se=K[se+De++],W.head&&Se&&W.length<65536&&(W.head.name+=String.fromCharCode(Se)),Se&&De<be;);if(512&W.flags&&(W.check=c(W.check,K,De,se)),be-=De,se+=De,Se)break e}else W.head&&(W.head.name=null);W.length=0,W.mode=8;case 8:if(4096&W.flags){if(be===0)break e;for(De=0;Se=K[se+De++],W.head&&Se&&W.length<65536&&(W.head.comment+=String.fromCharCode(Se)),Se&&De<be;);if(512&W.flags&&(W.check=c(W.check,K,De,se)),be-=De,se+=De,Se)break e}else W.head&&(W.head.comment=null);W.mode=9;case 9:if(512&W.flags){for(;he<16;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if(ue!==(65535&W.check)){V.msg="header crc mismatch",W.mode=30;break}he=ue=0}W.head&&(W.head.hcrc=W.flags>>9&1,W.head.done=!0),V.adler=W.check=0,W.mode=12;break;case 10:for(;he<32;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}V.adler=W.check=v(ue),he=ue=0,W.mode=11;case 11:if(W.havedict===0)return V.next_out=de,V.avail_out=re,V.next_in=se,V.avail_in=be,W.hold=ue,W.bits=he,2;V.adler=W.check=1,W.mode=12;case 12:if(X===5||X===6)break e;case 13:if(W.last){ue>>>=7&he,he-=7&he,W.mode=27;break}for(;he<3;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}switch(W.last=1&ue,he-=1,3&(ue>>>=1)){case 0:W.mode=14;break;case 1:if($(W),W.mode=20,X!==6)break;ue>>>=2,he-=2;break e;case 2:W.mode=17;break;case 3:V.msg="invalid block type",W.mode=30}ue>>>=2,he-=2;break;case 14:for(ue>>>=7&he,he-=7&he;he<32;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if((65535&ue)!=(ue>>>16^65535)){V.msg="invalid stored block lengths",W.mode=30;break}if(W.length=65535&ue,he=ue=0,W.mode=15,X===6)break e;case 15:W.mode=16;case 16:if(De=W.length){if(be<De&&(De=be),re<De&&(De=re),De===0)break e;s.arraySet(ee,K,se,De,de),be-=De,se+=De,re-=De,de+=De,W.length-=De;break}W.mode=12;break;case 17:for(;he<14;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if(W.nlen=257+(31&ue),ue>>>=5,he-=5,W.ndist=1+(31&ue),ue>>>=5,he-=5,W.ncode=4+(15&ue),ue>>>=4,he-=4,286<W.nlen||30<W.ndist){V.msg="too many length or distance symbols",W.mode=30;break}W.have=0,W.mode=18;case 18:for(;W.have<W.ncode;){for(;he<3;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}W.lens[Pe[W.have++]]=7&ue,ue>>>=3,he-=3}for(;W.have<19;)W.lens[Pe[W.have++]]=0;if(W.lencode=W.lendyn,W.lenbits=7,Ke={bits:W.lenbits},dt=u(0,W.lens,0,19,W.lencode,0,W.work,Ke),W.lenbits=Ke.bits,dt){V.msg="invalid code lengths set",W.mode=30;break}W.have=0,W.mode=19;case 19:for(;W.have<W.nlen+W.ndist;){for(;we=(Qe=W.lencode[ue&(1<<W.lenbits)-1])>>>16&255,xe=65535&Qe,!((ce=Qe>>>24)<=he);){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if(xe<16)ue>>>=ce,he-=ce,W.lens[W.have++]=xe;else{if(xe===16){for(Xe=ce+2;he<Xe;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if(ue>>>=ce,he-=ce,W.have===0){V.msg="invalid bit length repeat",W.mode=30;break}Se=W.lens[W.have-1],De=3+(3&ue),ue>>>=2,he-=2}else if(xe===17){for(Xe=ce+3;he<Xe;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}he-=ce,Se=0,De=3+(7&(ue>>>=ce)),ue>>>=3,he-=3}else{for(Xe=ce+7;he<Xe;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}he-=ce,Se=0,De=11+(127&(ue>>>=ce)),ue>>>=7,he-=7}if(W.have+De>W.nlen+W.ndist){V.msg="invalid bit length repeat",W.mode=30;break}for(;De--;)W.lens[W.have++]=Se}}if(W.mode===30)break;if(W.lens[256]===0){V.msg="invalid code -- missing end-of-block",W.mode=30;break}if(W.lenbits=9,Ke={bits:W.lenbits},dt=u(d,W.lens,0,W.nlen,W.lencode,0,W.work,Ke),W.lenbits=Ke.bits,dt){V.msg="invalid literal/lengths set",W.mode=30;break}if(W.distbits=6,W.distcode=W.distdyn,Ke={bits:W.distbits},dt=u(h,W.lens,W.nlen,W.ndist,W.distcode,0,W.work,Ke),W.distbits=Ke.bits,dt){V.msg="invalid distances set",W.mode=30;break}if(W.mode=20,X===6)break e;case 20:W.mode=21;case 21:if(6<=be&&258<=re){V.next_out=de,V.avail_out=re,V.next_in=se,V.avail_in=be,W.hold=ue,W.bits=he,l(V,Ie),de=V.next_out,ee=V.output,re=V.avail_out,se=V.next_in,K=V.input,be=V.avail_in,ue=W.hold,he=W.bits,W.mode===12&&(W.back=-1);break}for(W.back=0;we=(Qe=W.lencode[ue&(1<<W.lenbits)-1])>>>16&255,xe=65535&Qe,!((ce=Qe>>>24)<=he);){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if(we&&(240&we)==0){for(qe=ce,et=we,ot=xe;we=(Qe=W.lencode[ot+((ue&(1<<qe+et)-1)>>qe)])>>>16&255,xe=65535&Qe,!(qe+(ce=Qe>>>24)<=he);){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}ue>>>=qe,he-=qe,W.back+=qe}if(ue>>>=ce,he-=ce,W.back+=ce,W.length=xe,we===0){W.mode=26;break}if(32&we){W.back=-1,W.mode=12;break}if(64&we){V.msg="invalid literal/length code",W.mode=30;break}W.extra=15&we,W.mode=22;case 22:if(W.extra){for(Xe=W.extra;he<Xe;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}W.length+=ue&(1<<W.extra)-1,ue>>>=W.extra,he-=W.extra,W.back+=W.extra}W.was=W.length,W.mode=23;case 23:for(;we=(Qe=W.distcode[ue&(1<<W.distbits)-1])>>>16&255,xe=65535&Qe,!((ce=Qe>>>24)<=he);){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if((240&we)==0){for(qe=ce,et=we,ot=xe;we=(Qe=W.distcode[ot+((ue&(1<<qe+et)-1)>>qe)])>>>16&255,xe=65535&Qe,!(qe+(ce=Qe>>>24)<=he);){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}ue>>>=qe,he-=qe,W.back+=qe}if(ue>>>=ce,he-=ce,W.back+=ce,64&we){V.msg="invalid distance code",W.mode=30;break}W.offset=xe,W.extra=15&we,W.mode=24;case 24:if(W.extra){for(Xe=W.extra;he<Xe;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}W.offset+=ue&(1<<W.extra)-1,ue>>>=W.extra,he-=W.extra,W.back+=W.extra}if(W.offset>W.dmax){V.msg="invalid distance too far back",W.mode=30;break}W.mode=25;case 25:if(re===0)break e;if(De=Ie-re,W.offset>De){if((De=W.offset-De)>W.whave&&W.sane){V.msg="invalid distance too far back",W.mode=30;break}Ge=De>W.wnext?(De-=W.wnext,W.wsize-De):W.wnext-De,De>W.length&&(De=W.length),ke=W.window}else ke=ee,Ge=de-W.offset,De=W.length;for(re<De&&(De=re),re-=De,W.length-=De;ee[de++]=ke[Ge++],--De;);W.length===0&&(W.mode=21);break;case 26:if(re===0)break e;ee[de++]=W.length,re--,W.mode=21;break;case 27:if(W.wrap){for(;he<32;){if(be===0)break e;be--,ue|=K[se++]<<he,he+=8}if(Ie-=re,V.total_out+=Ie,W.total+=Ie,Ie&&(V.adler=W.check=W.flags?c(W.check,ee,Ie,de-Ie):a(W.check,ee,Ie,de-Ie)),Ie=re,(W.flags?ue:v(ue))!==W.check){V.msg="incorrect data check",W.mode=30;break}he=ue=0}W.mode=28;case 28:if(W.wrap&&W.flags){for(;he<32;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if(ue!==(4294967295&W.total)){V.msg="incorrect length check",W.mode=30;break}he=ue=0}W.mode=29;case 29:dt=1;break e;case 30:dt=-3;break e;case 31:return-4;case 32:default:return m}return V.next_out=de,V.avail_out=re,V.next_in=se,V.avail_in=be,W.hold=ue,W.bits=he,(W.wsize||Ie!==V.avail_out&&W.mode<30&&(W.mode<27||X!==4))&&k(V,V.output,V.next_out,Ie-V.avail_out)?(W.mode=31,-4):(Te-=V.avail_in,Ie-=V.avail_out,V.total_in+=Te,V.total_out+=Ie,W.total+=Ie,W.wrap&&Ie&&(V.adler=W.check=W.flags?c(W.check,ee,Ie,V.next_out-Ie):a(W.check,ee,Ie,V.next_out-Ie)),V.data_type=W.bits+(W.last?64:0)+(W.mode===12?128:0)+(W.mode===20||W.mode===15?256:0),(Te==0&&Ie===0||X===4)&&dt===f&&(dt=-5),dt)},o.inflateEnd=function(V){if(!V||!V.state)return m;var X=V.state;return X.window&&(X.window=null),V.state=null,f},o.inflateGetHeader=function(V,X){var W;return V&&V.state?(2&(W=V.state).wrap)==0?m:((W.head=X).done=!1,f):m},o.inflateSetDictionary=function(V,X){var W,K=X.length;return V&&V.state?(W=V.state).wrap!==0&&W.mode!==11?m:W.mode===11&&a(1,X,K,0)!==W.check?-3:k(V,X,K,K)?(W.mode=31,-4):(W.havedict=1,f):m},o.inflateInfo="pako inflate (from Nodeca project)"},{"../utils/common":41,"./adler32":43,"./crc32":45,"./inffast":48,"./inftrees":50}],50:[function(i,r,o){var s=i("../utils/common"),a=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],c=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],l=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],u=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];r.exports=function(d,h,f,m,y,g,b,v){var w,T,N,R,P,M,I,A,$,k=v.bits,V=0,X=0,W=0,K=0,ee=0,se=0,de=0,be=0,re=0,ue=0,he=null,Te=0,Ie=new s.Buf16(16),De=new s.Buf16(16),Ge=null,ke=0;for(V=0;V<=15;V++)Ie[V]=0;for(X=0;X<m;X++)Ie[h[f+X]]++;for(ee=k,K=15;1<=K&&Ie[K]===0;K--);if(K<ee&&(ee=K),K===0)return y[g++]=20971520,y[g++]=20971520,v.bits=1,0;for(W=1;W<K&&Ie[W]===0;W++);for(ee<W&&(ee=W),V=be=1;V<=15;V++)if(be<<=1,(be-=Ie[V])<0)return-1;if(0<be&&(d===0||K!==1))return-1;for(De[1]=0,V=1;V<15;V++)De[V+1]=De[V]+Ie[V];for(X=0;X<m;X++)h[f+X]!==0&&(b[De[h[f+X]]++]=X);if(M=d===0?(he=Ge=b,19):d===1?(he=a,Te-=257,Ge=c,ke-=257,256):(he=l,Ge=u,-1),V=W,P=g,de=X=ue=0,N=-1,R=(re=1<<(se=ee))-1,d===1&&852<re||d===2&&592<re)return 1;for(;;){for(I=V-de,$=b[X]<M?(A=0,b[X]):b[X]>M?(A=Ge[ke+b[X]],he[Te+b[X]]):(A=96,0),w=1<<V-de,W=T=1<<se;y[P+(ue>>de)+(T-=w)]=I<<24|A<<16|$|0,T!==0;);for(w=1<<V-1;ue&w;)w>>=1;if(w!==0?(ue&=w-1,ue+=w):ue=0,X++,--Ie[V]==0){if(V===K)break;V=h[f+b[X]]}if(ee<V&&(ue&R)!==N){for(de===0&&(de=ee),P+=W,be=1<<(se=V-de);se+de<K&&!((be-=Ie[se+de])<=0);)se++,be<<=1;if(re+=1<<se,d===1&&852<re||d===2&&592<re)return 1;y[N=ue&R]=ee<<24|se<<16|P-g|0}}return ue!==0&&(y[P+ue]=V-de<<24|64<<16|0),v.bits=ee,0}},{"../utils/common":41}],51:[function(i,r,o){r.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],52:[function(i,r,o){var s=i("../utils/common"),a=0,c=1;function l(Qe){for(var He=Qe.length;0<=--He;)Qe[He]=0}var u=0,d=29,h=256,f=h+1+d,m=30,y=19,g=2*f+1,b=15,v=16,w=7,T=256,N=16,R=17,P=18,M=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],I=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],A=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],$=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],k=new Array(2*(f+2));l(k);var V=new Array(2*m);l(V);var X=new Array(512);l(X);var W=new Array(256);l(W);var K=new Array(d);l(K);var ee,se,de,be=new Array(m);function re(Qe,He,Pe,Ye,Oe){this.static_tree=Qe,this.extra_bits=He,this.extra_base=Pe,this.elems=Ye,this.max_length=Oe,this.has_stree=Qe&&Qe.length}function ue(Qe,He){this.dyn_tree=Qe,this.max_code=0,this.stat_desc=He}function he(Qe){return Qe<256?X[Qe]:X[256+(Qe>>>7)]}function Te(Qe,He){Qe.pending_buf[Qe.pending++]=255&He,Qe.pending_buf[Qe.pending++]=He>>>8&255}function Ie(Qe,He,Pe){Qe.bi_valid>v-Pe?(Qe.bi_buf|=He<<Qe.bi_valid&65535,Te(Qe,Qe.bi_buf),Qe.bi_buf=He>>v-Qe.bi_valid,Qe.bi_valid+=Pe-v):(Qe.bi_buf|=He<<Qe.bi_valid&65535,Qe.bi_valid+=Pe)}function De(Qe,He,Pe){Ie(Qe,Pe[2*He],Pe[2*He+1])}function Ge(Qe,He){for(var Pe=0;Pe|=1&Qe,Qe>>>=1,Pe<<=1,0<--He;);return Pe>>>1}function ke(Qe,He,Pe){var Ye,Oe,Ze=new Array(b+1),nt=0;for(Ye=1;Ye<=b;Ye++)Ze[Ye]=nt=nt+Pe[Ye-1]<<1;for(Oe=0;Oe<=He;Oe++){var pt=Qe[2*Oe+1];pt!==0&&(Qe[2*Oe]=Ge(Ze[pt]++,pt))}}function ce(Qe){var He;for(He=0;He<f;He++)Qe.dyn_ltree[2*He]=0;for(He=0;He<m;He++)Qe.dyn_dtree[2*He]=0;for(He=0;He<y;He++)Qe.bl_tree[2*He]=0;Qe.dyn_ltree[2*T]=1,Qe.opt_len=Qe.static_len=0,Qe.last_lit=Qe.matches=0}function we(Qe){8<Qe.bi_valid?Te(Qe,Qe.bi_buf):0<Qe.bi_valid&&(Qe.pending_buf[Qe.pending++]=Qe.bi_buf),Qe.bi_buf=0,Qe.bi_valid=0}function xe(Qe,He,Pe,Ye){var Oe=2*He,Ze=2*Pe;return Qe[Oe]<Qe[Ze]||Qe[Oe]===Qe[Ze]&&Ye[He]<=Ye[Pe]}function qe(Qe,He,Pe){for(var Ye=Qe.heap[Pe],Oe=Pe<<1;Oe<=Qe.heap_len&&(Oe<Qe.heap_len&&xe(He,Qe.heap[Oe+1],Qe.heap[Oe],Qe.depth)&&Oe++,!xe(He,Ye,Qe.heap[Oe],Qe.depth));)Qe.heap[Pe]=Qe.heap[Oe],Pe=Oe,Oe<<=1;Qe.heap[Pe]=Ye}function et(Qe,He,Pe){var Ye,Oe,Ze,nt,pt=0;if(Qe.last_lit!==0)for(;Ye=Qe.pending_buf[Qe.d_buf+2*pt]<<8|Qe.pending_buf[Qe.d_buf+2*pt+1],Oe=Qe.pending_buf[Qe.l_buf+pt],pt++,Ye===0?De(Qe,Oe,He):(De(Qe,(Ze=W[Oe])+h+1,He),(nt=M[Ze])!==0&&Ie(Qe,Oe-=K[Ze],nt),De(Qe,Ze=he(--Ye),Pe),(nt=I[Ze])!==0&&Ie(Qe,Ye-=be[Ze],nt)),pt<Qe.last_lit;);De(Qe,T,He)}function ot(Qe,He){var Pe,Ye,Oe,Ze=He.dyn_tree,nt=He.stat_desc.static_tree,pt=He.stat_desc.has_stree,gt=He.stat_desc.elems,Et=-1;for(Qe.heap_len=0,Qe.heap_max=g,Pe=0;Pe<gt;Pe++)Ze[2*Pe]!==0?(Qe.heap[++Qe.heap_len]=Et=Pe,Qe.depth[Pe]=0):Ze[2*Pe+1]=0;for(;Qe.heap_len<2;)Ze[2*(Oe=Qe.heap[++Qe.heap_len]=Et<2?++Et:0)]=1,Qe.depth[Oe]=0,Qe.opt_len--,pt&&(Qe.static_len-=nt[2*Oe+1]);for(He.max_code=Et,Pe=Qe.heap_len>>1;1<=Pe;Pe--)qe(Qe,Ze,Pe);for(Oe=gt;Pe=Qe.heap[1],Qe.heap[1]=Qe.heap[Qe.heap_len--],qe(Qe,Ze,1),Ye=Qe.heap[1],Qe.heap[--Qe.heap_max]=Pe,Qe.heap[--Qe.heap_max]=Ye,Ze[2*Oe]=Ze[2*Pe]+Ze[2*Ye],Qe.depth[Oe]=(Qe.depth[Pe]>=Qe.depth[Ye]?Qe.depth[Pe]:Qe.depth[Ye])+1,Ze[2*Pe+1]=Ze[2*Ye+1]=Oe,Qe.heap[1]=Oe++,qe(Qe,Ze,1),2<=Qe.heap_len;);Qe.heap[--Qe.heap_max]=Qe.heap[1],(function(Nt,xt){var $t,Zt,hn,en,ln,En,rt=xt.dyn_tree,pe=xt.max_code,We=xt.stat_desc.static_tree,ut=xt.stat_desc.has_stree,vt=xt.stat_desc.extra_bits,Bt=xt.stat_desc.extra_base,Ht=xt.stat_desc.max_length,cn=0;for(en=0;en<=b;en++)Nt.bl_count[en]=0;for(rt[2*Nt.heap[Nt.heap_max]+1]=0,$t=Nt.heap_max+1;$t<g;$t++)Ht<(en=rt[2*rt[2*(Zt=Nt.heap[$t])+1]+1]+1)&&(en=Ht,cn++),rt[2*Zt+1]=en,pe<Zt||(Nt.bl_count[en]++,ln=0,Bt<=Zt&&(ln=vt[Zt-Bt]),En=rt[2*Zt],Nt.opt_len+=En*(en+ln),ut&&(Nt.static_len+=En*(We[2*Zt+1]+ln)));if(cn!==0){do{for(en=Ht-1;Nt.bl_count[en]===0;)en--;Nt.bl_count[en]--,Nt.bl_count[en+1]+=2,Nt.bl_count[Ht]--,cn-=2}while(0<cn);for(en=Ht;en!==0;en--)for(Zt=Nt.bl_count[en];Zt!==0;)pe<(hn=Nt.heap[--$t])||(rt[2*hn+1]!==en&&(Nt.opt_len+=(en-rt[2*hn+1])*rt[2*hn],rt[2*hn+1]=en),Zt--)}})(Qe,He),ke(Ze,Et,Qe.bl_count)}function Se(Qe,He,Pe){var Ye,Oe,Ze=-1,nt=He[1],pt=0,gt=7,Et=4;for(nt===0&&(gt=138,Et=3),He[2*(Pe+1)+1]=65535,Ye=0;Ye<=Pe;Ye++)Oe=nt,nt=He[2*(Ye+1)+1],++pt<gt&&Oe===nt||(pt<Et?Qe.bl_tree[2*Oe]+=pt:Oe!==0?(Oe!==Ze&&Qe.bl_tree[2*Oe]++,Qe.bl_tree[2*N]++):pt<=10?Qe.bl_tree[2*R]++:Qe.bl_tree[2*P]++,Ze=Oe,Et=(pt=0)===nt?(gt=138,3):Oe===nt?(gt=6,3):(gt=7,4))}function dt(Qe,He,Pe){var Ye,Oe,Ze=-1,nt=He[1],pt=0,gt=7,Et=4;for(nt===0&&(gt=138,Et=3),Ye=0;Ye<=Pe;Ye++)if(Oe=nt,nt=He[2*(Ye+1)+1],!(++pt<gt&&Oe===nt)){if(pt<Et)for(;De(Qe,Oe,Qe.bl_tree),--pt!=0;);else Oe!==0?(Oe!==Ze&&(De(Qe,Oe,Qe.bl_tree),pt--),De(Qe,N,Qe.bl_tree),Ie(Qe,pt-3,2)):pt<=10?(De(Qe,R,Qe.bl_tree),Ie(Qe,pt-3,3)):(De(Qe,P,Qe.bl_tree),Ie(Qe,pt-11,7));Ze=Oe,Et=(pt=0)===nt?(gt=138,3):Oe===nt?(gt=6,3):(gt=7,4)}}l(be);var Ke=!1;function Xe(Qe,He,Pe,Ye){Ie(Qe,(u<<1)+(Ye?1:0),3),(function(Oe,Ze,nt,pt){we(Oe),Te(Oe,nt),Te(Oe,~nt),s.arraySet(Oe.pending_buf,Oe.window,Ze,nt,Oe.pending),Oe.pending+=nt})(Qe,He,Pe)}o._tr_init=function(Qe){Ke||((function(){var He,Pe,Ye,Oe,Ze,nt=new Array(b+1);for(Oe=Ye=0;Oe<d-1;Oe++)for(K[Oe]=Ye,He=0;He<1<<M[Oe];He++)W[Ye++]=Oe;for(W[Ye-1]=Oe,Oe=Ze=0;Oe<16;Oe++)for(be[Oe]=Ze,He=0;He<1<<I[Oe];He++)X[Ze++]=Oe;for(Ze>>=7;Oe<m;Oe++)for(be[Oe]=Ze<<7,He=0;He<1<<I[Oe]-7;He++)X[256+Ze++]=Oe;for(Pe=0;Pe<=b;Pe++)nt[Pe]=0;for(He=0;He<=143;)k[2*He+1]=8,He++,nt[8]++;for(;He<=255;)k[2*He+1]=9,He++,nt[9]++;for(;He<=279;)k[2*He+1]=7,He++,nt[7]++;for(;He<=287;)k[2*He+1]=8,He++,nt[8]++;for(ke(k,f+1,nt),He=0;He<m;He++)V[2*He+1]=5,V[2*He]=Ge(He,5);ee=new re(k,M,h+1,f,b),se=new re(V,I,0,m,b),de=new re(new Array(0),A,0,y,w)})(),Ke=!0),Qe.l_desc=new ue(Qe.dyn_ltree,ee),Qe.d_desc=new ue(Qe.dyn_dtree,se),Qe.bl_desc=new ue(Qe.bl_tree,de),Qe.bi_buf=0,Qe.bi_valid=0,ce(Qe)},o._tr_stored_block=Xe,o._tr_flush_block=function(Qe,He,Pe,Ye){var Oe,Ze,nt=0;0<Qe.level?(Qe.strm.data_type===2&&(Qe.strm.data_type=(function(pt){var gt,Et=4093624447;for(gt=0;gt<=31;gt++,Et>>>=1)if(1&Et&&pt.dyn_ltree[2*gt]!==0)return a;if(pt.dyn_ltree[18]!==0||pt.dyn_ltree[20]!==0||pt.dyn_ltree[26]!==0)return c;for(gt=32;gt<h;gt++)if(pt.dyn_ltree[2*gt]!==0)return c;return a})(Qe)),ot(Qe,Qe.l_desc),ot(Qe,Qe.d_desc),nt=(function(pt){var gt;for(Se(pt,pt.dyn_ltree,pt.l_desc.max_code),Se(pt,pt.dyn_dtree,pt.d_desc.max_code),ot(pt,pt.bl_desc),gt=y-1;3<=gt&&pt.bl_tree[2*$[gt]+1]===0;gt--);return pt.opt_len+=3*(gt+1)+5+5+4,gt})(Qe),Oe=Qe.opt_len+3+7>>>3,(Ze=Qe.static_len+3+7>>>3)<=Oe&&(Oe=Ze)):Oe=Ze=Pe+5,Pe+4<=Oe&&He!==-1?Xe(Qe,He,Pe,Ye):Qe.strategy===4||Ze===Oe?(Ie(Qe,2+(Ye?1:0),3),et(Qe,k,V)):(Ie(Qe,4+(Ye?1:0),3),(function(pt,gt,Et,Nt){var xt;for(Ie(pt,gt-257,5),Ie(pt,Et-1,5),Ie(pt,Nt-4,4),xt=0;xt<Nt;xt++)Ie(pt,pt.bl_tree[2*$[xt]+1],3);dt(pt,pt.dyn_ltree,gt-1),dt(pt,pt.dyn_dtree,Et-1)})(Qe,Qe.l_desc.max_code+1,Qe.d_desc.max_code+1,nt+1),et(Qe,Qe.dyn_ltree,Qe.dyn_dtree)),ce(Qe),Ye&&we(Qe)},o._tr_tally=function(Qe,He,Pe){return Qe.pending_buf[Qe.d_buf+2*Qe.last_lit]=He>>>8&255,Qe.pending_buf[Qe.d_buf+2*Qe.last_lit+1]=255&He,Qe.pending_buf[Qe.l_buf+Qe.last_lit]=255&Pe,Qe.last_lit++,He===0?Qe.dyn_ltree[2*Pe]++:(Qe.matches++,He--,Qe.dyn_ltree[2*(W[Pe]+h+1)]++,Qe.dyn_dtree[2*he(He)]++),Qe.last_lit===Qe.lit_bufsize-1},o._tr_align=function(Qe){Ie(Qe,2,3),De(Qe,T,k),(function(He){He.bi_valid===16?(Te(He,He.bi_buf),He.bi_buf=0,He.bi_valid=0):8<=He.bi_valid&&(He.pending_buf[He.pending++]=255&He.bi_buf,He.bi_buf>>=8,He.bi_valid-=8)})(Qe)}},{"../utils/common":41}],53:[function(i,r,o){r.exports=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}},{}],54:[function(i,r,o){(function(s){(function(a,c){if(!a.setImmediate){var l,u,d,h,f=1,m={},y=!1,g=a.document,b=Object.getPrototypeOf&&Object.getPrototypeOf(a);b=b&&b.setTimeout?b:a,l={}.toString.call(a.process)==="[object process]"?function(N){n.nextTick(function(){w(N)})}:(function(){if(a.postMessage&&!a.importScripts){var N=!0,R=a.onmessage;return a.onmessage=function(){N=!1},a.postMessage("","*"),a.onmessage=R,N}})()?(h="setImmediate$"+Math.random()+"$",a.addEventListener?a.addEventListener("message",T,!1):a.attachEvent("onmessage",T),function(N){a.postMessage(h+N,"*")}):a.MessageChannel?((d=new MessageChannel).port1.onmessage=function(N){w(N.data)},function(N){d.port2.postMessage(N)}):g&&"onreadystatechange"in g.createElement("script")?(u=g.documentElement,function(N){var R=g.createElement("script");R.onreadystatechange=function(){w(N),R.onreadystatechange=null,u.removeChild(R),R=null},u.appendChild(R)}):function(N){setTimeout(w,0,N)},b.setImmediate=function(N){typeof N!="function"&&(N=new Function(""+N));for(var R=new Array(arguments.length-1),P=0;P<R.length;P++)R[P]=arguments[P+1];var M={callback:N,args:R};return m[f]=M,l(f),f++},b.clearImmediate=v}function v(N){delete m[N]}function w(N){if(y)setTimeout(w,0,N);else{var R=m[N];if(R){y=!0;try{(function(P){var M=P.callback,I=P.args;switch(I.length){case 0:M();break;case 1:M(I[0]);break;case 2:M(I[0],I[1]);break;case 3:M(I[0],I[1],I[2]);break;default:M.apply(c,I)}})(R)}finally{v(N),y=!1}}}}function T(N){N.source===a&&typeof N.data=="string"&&N.data.indexOf(h)===0&&w(+N.data.slice(h.length))}})(typeof self>"u"?s===void 0?this:s:self)}).call(this,typeof FO<"u"?FO:typeof self<"u"?self:typeof window<"u"?window:{})},{}]},{},[10])(10)})})(C2e)),C2e.exports}var dZn=uZn();const hZn=u2(dZn);var R2e,lft;function pZn(){return lft||(lft=1,R2e=function(t,e){e||(e={}),typeof e=="function"&&(e={cmp:e});var n=typeof e.cycles=="boolean"?e.cycles:!1,i=e.cmp&&(function(o){return function(s){return function(a,c){var l={key:a,value:s[a]},u={key:c,value:s[c]};return o(l,u)}}})(e.cmp),r=[];return(function o(s){if(s&&s.toJSON&&typeof s.toJSON=="function"&&(s=s.toJSON()),s!==void 0){if(typeof s=="number")return isFinite(s)?""+s:"null";if(typeof s!="object")return JSON.stringify(s);var a,c;if(Array.isArray(s)){for(c="[",a=0;a<s.length;a++)a&&(c+=","),c+=o(s[a])||"null";return c+"]"}if(s===null)return"null";if(r.indexOf(s)!==-1){if(n)return JSON.stringify("__cycle__");throw new TypeError("Converting circular structure to JSON")}var l=r.push(s)-1,u=Object.keys(s).sort(i&&i(s));for(c="",a=0;a<u.length;a++){var d=u[a],h=o(s[d]);h&&(c&&(c+=","),c+=JSON.stringify(d)+":"+h)}return r.splice(l,1),"{"+c+"}"}})(t)}),R2e}var fZn=pZn();const mZn=u2(fZn);var uft={0:"M0.4544564813877358 0L0.2723441540828736 0.03592830447352719L0.1086847233315459 0.14528754990019965L0.020630545837255005 0.3040632652221331L0 0.5395277421960205L0.049259221760993496 0.7369487828466779L0.18080513776237842 0.9005494166306564L0.37036887043974215 0.9872116270037247L0.5864663759301132 1L0.8148695622827444 0.9332890276148733L0.9326583645506394 0.8113052246023419L1 0.4031281830668562L0.833288960385582 0.09886798567812842L0.6801767918233781 0.02483708485091681L0.4544564813877358 0",1:"M 0.198 0.272 L 0.537 0 L 0.54 1",2:"M0.069593147751606 0.19461498231706575L0.1039380353319058 0.1224291500164194L0.20543361884368308 0.05510832064153169L0.3717712794432549 0.009452970962689482L0.4785344452623127 0L0.663238590738758 0.008714098643339864L0.8017933618843684 0.04769189395915288L0.8775637379550322 0.10746757678258442L0.9047778372591005 0.17693069668193287L0.9029710920770878 0.2231347105796246L0.8704496788008566 0.30047744598157516L0.7292906538577354 0.4508486051631194L0.3737955032119913 0.7369006417749693L0 1L1 1",3:"M0.03917438899874637 0.19855364635107545L0.15510940508963084 0.06745632622133718L0.37598645522339846 0L0.8486391893813088 0.0652271323161611L0.9782182415054349 0.21747394183735683L0.9213133780517754 0.3547560290117714L0.6504271515903481 0.4543436297681271L0.22975249764129613 0.48476611625264143L0.7659038682744629 0.5411919558122493L0.9258712987734741 0.6203185665660985L1 0.7458360609169667L0.8938813281118737 0.9059190913045964L0.6166890258875837 1L0.261528440153542 0.9874861530507921L0 0.8837289530851273",4:"M0.7328897338403042 0L0 0.6684672518568535L1 0.6684672518568535M0.7243346007604563 0.4530722484807562L0.7243346007604563 1",5:"M 0 0 L 0 0.4973 L 0.4262 0.4319 L 0.7305 0.4565 L 0.8516 0.5009 L 0.9357 0.5639 L 1 0.7356 L 0.9696 0.8248 L 0.8898 0.895 L 0.733 0.9602 L 0.5518 0.9945 L 0.3814 1 L 0.2379 0.9821 L 0.1219 0.947 L 0 0.8748 M 0 0 L 1 0",6:"M0.6964601700926856 0L0.3639239026215478 0.0743562375769351L0.1415931962925719 0.21735490179786915L0.009977939399608712 0.46336322325406004L0.00029622007592593224 0.7083131475173043L0.09408885043224748 0.8746809149767036L0.3379247445101846 0.9876686500961888L0.7109203869569624 1L0.9260852957913362 0.9103558029693921L1 0.7716571969091733L0.9824294723385016 0.6390635485705886L0.7446504992867332 0.4733643097729175L0.31028858071607296 0.47578021640899115L0.1208702146816024 0.5481452483973847L0 0.6616669755788906",7:"M0 0L1 0L0.9246479649697582 0.030539772727272752L0.8850302419354837 0.05075757575757579L0.7922946068548385 0.11079545454545457L0.7419268208165322 0.15213068181818185L0.6907258064516127 0.20202020202020204L0.6400666267641127 0.26122159090909086L0.5913243447580644 0.33049242424242414L0.5458740234374998 0.4105902777777778L0.5050907258064514 0.5022727272727272L0.4703495148689514 0.6062973484848484L0.43257456133442534 0.787133049242424L0.41612903225806447 1",8:"M0.5143001078924863 0L0.16007477667923162 0.10731570786949331L0.14924628550868277 0.3146018498698755L0.2939585848842112 0.41617921794558677L0.8648302624811545 0.5385163833653317L1 0.7775820770511038L0.8180842915260376 0.9505845566922285L0.41968938540525413 1L0.08062381919779889 0.882831681184498L0 0.6936376947135333L0.17150171673893433 0.5188652309607817L0.6529263782780712 0.4242818653203618L0.8650205888491803 0.29644027376796367L0.8702067371119496 0.09910067291661573L0.5143001078924863 0",9:"M1 0.25379591792994305L0.9514789771111742 0.11679361536614272L0.8702482473521467 0.05711741614054847L0.7327445265851579 0.015213872471965633L0.525248180711544 0L0.3292056884418538 0.012928195113745608L0.15997632037247655 0.058762870026191856L0.05266940041228321 0.12882439350476L0 0.2562067822770946L0.11316462894512366 0.4121335905917837L0.2403060136479954 0.4603365890068938L0.4097241967586011 0.4745978388276783L0.8642414300184816 0.420815170259988L0.9732054796346318 0.34537434075898393L1 0.25379591792994305M0.9647426784191072 0.35488595400360495L0.4756895081034974 1",A:"M0 1L0.4808333333333333 0L1 1M0.24250000000000002 0.6099439775910365L0.7341666666666666 0.6099439775910365",B:"M0 1L0 0.0117369978777208L0.30665717153513444 0L0.5874522807082946 0.03451403469442413L0.7766202217193218 0.15033936404895643L0.7471969743588041 0.31967962568332936L0.5246013359741988 0.4102978954282461L0.04378745314885416 0.44918617613783574L0.5112949594180156 0.469692928091109L0.8540266515643348 0.5552749498651879L1 0.6868463175009967L0.9880091196159324 0.8570018204672155L0.922301719975498 0.9321708046604659L0.7584266951758925 0.9932594737131338L0 1",C:"M1 0.23038928858890784L0.9328355511865092 0.12426412616785204L0.8096380839483327 0.04912601676267708L0.5763225801788256 0L0.4039037709527492 0.015028068281399815L0.2519579390951737 0.06533979308999706L0.10359458463139784 0.18146243506591617L0 0.4862728453971315L0.08129580872733055 0.792689266886982L0.20257034847159672 0.9160822255736587L0.3286572892798542 0.9738230826074175L0.5742878414421707 1L0.7883510303801312 0.9665431511195721L0.946851033994232 0.8689071500976585L1 0.7311049027121912",D:"M0 1L0.015604366822624637 0.020770988281483303L0.22564758265176144 0L0.3865476147957666 0.0024153386496795644L0.6479126635475078 0.051745644338731314L0.841191887805517 0.15827717679529366L0.9517008345536152 0.30172260586872185L0.9957536578687336 0.4504541551987709L1 0.5624359222498485L0.9798483279164735 0.6584121775234548L0.9386273319285215 0.7395945263504481L0.806292129480815 0.8624239259880274L0.6296239151398265 0.9406169638094516L0.3397492767598845 0.9954164354263132L0 1",E:"M0 0L0 1M0 0L1 0M0 0.5L0.7 0.5M0 1L1 1",F:"M0 0L0 1M0.011363636363636364 0.006802721088435374L1 0.006802721088435374M0.011363636363636364 0.4965986394557823L0.8409090909090909 0.4965986394557823",G:"M0.902666857540557 0.03860785012651126L0.6504261864675637 0L0.3838947267237336 0.015442305268228053L0.21293332876776194 0.07706794377239819L0.07799659974941617 0.1994951236187481L0 0.46380381528937314L0.04159964421546915 0.7502491408002389L0.13176692977834842 0.8535497868383203L0.2709176262273927 0.936767572377719L0.4386472596876406 0.9891638569283179L0.6145513562841309 1L0.7782254421419019 0.9585373611026471L0.9092650433859927 0.8540372997461425L1 0.5556012645283437L0.5583959277303046 0.55491741080559",H:"M0 0L0 1M0 0.4788732394366197L0.989010989010989 0.4788732394366197M1 0L1 1",I:"M0.5 0L0.5 1",J:"M0.9976457238788704 0L1 0.7396412315872798L0.9773931362096968 0.8322033314977973L0.9345115952458736 0.882296255506608L0.8743862896259549 0.9221331222466961L0.8024024079884948 0.9526431718061675L0.6443996712151668 0.9893997797356828L0.5035848940343224 1L0.3127211130319937 0.9877004749449337L0.17201910858386513 0.9539509911894274L0.10357419806379677 0.9212555066079295L0.053656568662899015 0.8816079295154184L0.020759483663648916 0.8360407488986785L0.003376206348523566 0.7855864537444934L0 0.7312775330396476",K:"M0 0L0 1M0.8787878787878788 0.06666666666666667L0 0.6148148148148148M0.3333333333333333 0.45925925925925926L1 0.9777777777777777",L:"M0 0L0 1L1 1",M:"M0 1L0 0L0.5 0.6512L1 0L1 1",N:"M0 1L0 0L1 1L0.9803729146221786 0",O:"M0.4718499217948183 1L0.2896765846490613 0.9606979309189402L0.12315162147934663 0.8411184486080473L0 0.4352399966492615L0.11730398524516283 0.13145645436014852L0.2612197451988078 0.04493357858878059L0.5104071592772554 0L0.7450113425917159 0.05393013710105273L0.882367950645524 0.15242300282020502L1 0.5224527406249126L0.9414597290654386 0.7560662329321755L0.8371289514446183 0.8910800547287298L0.6518259868433511 0.9830452628933628L0.4718499217948183 1",P:"M0 1L0 0.018871774228013626L0.29609603495819875 0L0.5609840637427541 0.011794858892508529L0.7332142696692472 0.04353904702296349L0.8102258645858864 0.0691965055027166L0.9330504315465442 0.14445061754775845L0.9876391714147118 0.22527816445836535L1 0.3434414070631638L0.9510549958116356 0.41772808046663146L0.8746646891596713 0.45879131862541683L0.7528523813396283 0.49171525113425024L0.5766919939969619 0.5153253033973054L0.33725744877712827 0.5284469008187558L0.025622667325582785 0.529905468802775",Q:"M0.4618887943546369 0.9755918167206952L0.28356128136544534 0.9372490397450218L0.12055179272160406 0.8205882753548176L0 0.4246165790405623L0.1148276047430244 0.12824784112887844L0.25570518844754375 0.043836831567190586L0.49963205786237674 0L0.7292835601228574 0.0526138004304122L0.8637404608452104 0.14870263423138746L0.9788892040030622 0.5097006183769648L0.9215847647858059 0.7376120297474734L0.8194564929275405 0.869330409436378L0.6380654214095985 0.9590509139448092L0.4618887943546369 0.9755918167206952M0.5824181120212351 0.6861805006946525L1 1",R:"M0 0.9928375167236815L0 0.02590227442068435L0.3611517274211098 0L0.6146286724700761 0.008660554424468435L0.7675462459194776 0.035269459580494614L0.831839975516866 0.056961676692569484L0.8847592491838954 0.08519560521497332L0.9238557535364527 0.120683646438422L0.9583303225312839 0.21691797435320384L0.955092470586235 0.3022616904894429L0.9198097669001631 0.3640573439322699L0.8564862239866702 0.40639258627024005L0.7691258543593579 0.43335506909190874L0.601775027203482 0.4539166070813109L0.023939064200217658 0.46997623755243123M0.5038084874863982 0.5108023922274467L1 1",S:"M0.8886929689221953 0.15146982162688968L0.7276173683050475 0.013780286031594946L0.34582323121005076 0L0.1318235250900008 0.09920162734298861L0.0444543935052531 0.2811287071349243L0.08064065829108809 0.3709571405906485L0.21603115127470426 0.4485505768228281L0.7525409135992945 0.5111160926769565L0.9330263665417677 0.5850732219351329L1 0.7129938124702524L0.9117772389978691 0.9130572743138187L0.6423187128058188 1L0.29586019579751677 0.9935291584506244L0.10638454191462794 0.9229845198431584L0 0.7570771288048773",T:"M0 0L1 0M0.5148514851485149 0L0.5148514851485149 1",U:"M0 0L0.0023103778751369115 0.5467447428390111L0.01823032542100219 0.6954785891481812L0.05895528135268338 0.8056480226151669L0.13703402031421133 0.8894445726483398L0.23918400876232196 0.9448524533417946L0.3917887458926616 0.9848674531975652L0.584341627875137 1L0.7194816196604602 0.9848501456716763L0.8303268115073934 0.9449411544119768L0.8966613970084885 0.898186315516197L0.9251437568455642 0.867453197565408L0.9687114937020809 0.7890904895145239L0.9890470974808324 0.6852857184065537L1 0.0014769088758762145",V:"M0 0L0.5348837209302325 1L1 0",W:"M0 0L0.23300090661831369 0.9873417721518988L0.49954669084315495 0.30081906180193585L0.7851314596554849 1L1 0.0215934475055845",X:"M0 0L0.9893617021276596 1M1 0L0.010638297872340425 1",Y:"M0 0L0.4860515021459227 0.44712562100780695M1 0.0014194464158977947L0.48927038626609437 0.44996451383960256L0.5075107296137339 1",Z:"M0 0L1 0L0 1L1 1",".":"M 0.49 1 L 0.41 1","*":"M 0.5 0.25 L 0.8 0.25 M 0.5 0.25 L 0.5927 0.4402 M 0.5 0.25 L 0.2573 0.3676 M 0.5 0.25 L 0.2573 0.1324 M 0.5 0.25 L 0.599 0.055","(":"M0.75 0L0.25 0.5L0.25 0.5L0.75 1",")":"M0.25 0L0.75 0.5L0.75 0.5L0.25 1","-":"M0 0.5L1 0.5","+":"M 0 0.5 L 1 0.5 M 0.5 0.125 L 0.5 0.875","=":"M0 0.25L1 0.25M0 0.75L1 0.75",_:"M0 1 L1 1","[":"M0.75 0L0.25 0L0.25 1L0.75 1","]":"M0.25 0L0.75 0L0.75 1L0.25 1","<":"M0.75 0L0.25 0.5L0.25 0.5L0.75 1",">":"M0.25 0L0.75 0.5L0.75 0.5L0.25 1","'":"M 0.5 0 L 0.5 0.5",'"':"M 0.25 0 L 0.25 0.5 M 0.75 0 L 0.75 0.5"},P2e={};for(const t in uft){P2e[t]=[];const e=uft[t].split("M").slice(1).map(n=>n.split("L").map(i=>i.trim().split(" ").map(parseFloat)));for(const n of e)for(let i=0;i<n.length-1;i++)P2e[t].push({x1:n[i][0],y1:1-n[i][1],x2:n[i+1][0],y2:1-n[i+1][1]})}function RX(t,e){return Array.isArray(e)?[t.a*e[0]+t.c*e[1]+t.e,t.b*e[0]+t.d*e[1]+t.f]:{x:t.a*e.x+t.c*e.y+t.e,y:t.b*e.x+t.d*e.y+t.f}}function dft(){return{a:1,c:0,e:0,b:0,d:1,f:0}}function g7(t,e=0){return{a:1,c:0,e:t,b:0,d:1,f:e}}function hft(...t){t=Array.isArray(t[0])?t[0]:t;const e=(n,i)=>({a:n.a*i.a+n.c*i.b,c:n.a*i.c+n.c*i.d,e:n.a*i.e+n.c*i.f+n.e,b:n.b*i.a+n.d*i.b,d:n.b*i.c+n.d*i.d,f:n.b*i.e+n.d*i.f+n.f});switch(t.length){case 0:throw new Error("no matrices provided");case 1:return t[0];case 2:return e(t[0],t[1]);default:{const[n,i,...r]=t,o=e(n,i);return hft(o,...r)}}}function I2e(...t){return hft(...t)}const{cos:_Zn,sin:yZn}=Math;function N2e(t,e,n){const i=_Zn(t),r=yZn(t);return{a:i,c:-r,e:0,b:r,d:i,f:0}}var Ug=({command_code:t,schema:e,stringify:n})=>({command_code:t,schema:e,stringify:n}),gZn=Ug({command_code:"FMAT",schema:Ne({command_code:Ae("FMAT").default("FMAT"),format:Be()}),stringify:t=>`FMAT,${t.format}`}),bZn=Ug({command_code:"G00",schema:Ne({command_code:Ae("G00").default("G00")}),stringify:()=>"G00"}),xZn=Ug({command_code:"G01",schema:Ne({command_code:Ae("G01").default("G01")}),stringify:()=>"G01"}),vZn=Ug({command_code:"G05",schema:Ne({command_code:Ae("G05").default("G05")}),stringify:()=>"G05"}),wZn=Ug({command_code:"G85",schema:Ne({command_code:Ae("G85").default("G85")}),stringify:()=>"G85"}),SZn=Ug({command_code:"G90",schema:Ne({command_code:Ae("G90").default("G90")}),stringify:()=>"G90"}),EZn=Ug({command_code:"M15",schema:Ne({command_code:Ae("M15").default("M15")}),stringify:()=>"M15"}),TZn=Ug({command_code:"M16",schema:Ne({command_code:Ae("M16").default("M16")}),stringify:()=>"M16"}),MZn=Ug({command_code:"M30",schema:Ne({command_code:Ae("M30").default("M30")}),stringify:()=>"M30"}),AZn=Ug({command_code:"M48",schema:Ne({command_code:Ae("M48").default("M48")}),stringify:()=>"M48"}),CZn=Ug({command_code:"M95",schema:Ne({command_code:Ae("M95").default("M95")}),stringify:()=>"M95"}),pft=Ug({command_code:"define_tool",schema:Ne({command_code:Ae("define_tool").default("define_tool"),tool_number:Be(),diameter:Be()}),stringify:t=>`T${t.tool_number}C${t.diameter.toFixed(6)}`}),RZn=Ug({command_code:"drill_at",schema:Ne({command_code:Ae("drill_at").default("drill_at"),x:Be(),y:Be()}),stringify:t=>`X${t.x.toFixed(4)}Y${t.y.toFixed(4)}`}),PZn=Ug({command_code:"header_attribute",schema:Ne({command_code:Ae("header_attribute").default("header_attribute"),attribute_name:B(),attribute_value:B()}),stringify({attribute_name:t,attribute_value:e}){return`; #@! ${t},${e}`}}),IZn=Ug({command_code:"header_comment",schema:Ne({command_code:Ae("header_comment").default("header_comment"),text:B()}),stringify({text:t}){return`; ${t}`}}),NZn=Ug({command_code:"rewind",schema:Ne({command_code:Ae("rewind").default("rewind")}),stringify:()=>"%"}),kZn=Ug({command_code:"unit_format",schema:Ne({command_code:Ae("unit_format").default("unit_format"),unit:oi([Ae("INCH"),Ae("METRIC")]),lz:oi([Ae("LZ"),Ae("TZ")]).nullable().default(null)}),stringify(t){return`${t.unit}${t.lz?`,${t.lz}`:""}`}}),OZn=Ug({command_code:"use_tool",schema:Ne({command_code:Ae("use_tool").default("use_tool"),tool_number:Be()}),stringify:t=>`T${t.tool_number}`}),LZn=Ug({command_code:"aper_function_header",schema:Ne({command_code:Ae("aper_function_header").default("aper_function_header"),is_plated:bt()}),stringify({is_plated:t}){if(!t)throw new Error("not implemented");return"; #@! TA.AperFunction,Plated,PTH,ComponentDrill"}}),DZn=Ug({command_code:"percent_sign",schema:Ne({command_code:Ae("percent_sign").default("percent_sign")}),stringify:()=>"%"}),fft={G00:bZn,G01:xZn,G85:wZn,M48:AZn,M95:CZn,FMAT:gZn,unit_format:kZn,aper_function_header:LZn,percent_sign:DZn,T:pft,define_tool:pft,use_tool:OZn,G90:SZn,G05:vZn,M15:EZn,M16:TZn,M30:MZn,drill_at:RZn,header_comment:IZn,header_attribute:PZn,rewind:NZn},zZn=t=>t.map(e=>fft[e.command_code].stringify(e)).join(`
6560
- `),FZn=class{commands;constructor(){this.commands=[]}add(t,e){return this.commands.push({command_code:fft[t].command_code,...e}),this}build(){return this.commands}},BZn=()=>new FZn,UZn=({circuitJson:t,is_plated:e,flip_y_axis:n=!1})=>{const i=BZn();i.add("M48",{});const r=new Date().toISOString();i.add("header_comment",{text:`DRILL file {tscircuit} date ${r}`}).add("header_comment",{text:"FORMAT={-:-/ absolute / metric / decimal}"}).add("header_attribute",{attribute_name:"TF.CreationDate",attribute_value:r}).add("header_attribute",{attribute_name:"TF.GenerationSoftware",attribute_value:"tscircuit"}).add("header_attribute",{attribute_name:"TF.FileFunction",attribute_value:"Plated,1,2,PTH"}).add("FMAT",{format:2}).add("unit_format",{unit:"METRIC",lz:null});let o=10;const s={};for(const a of t)if(a.type==="pcb_plated_hole"||a.type==="pcb_hole"||a.type==="pcb_via"){let c;if("hole_diameter"in a?c=a.hole_diameter:a.type==="pcb_plated_hole"&&a.shape==="pill"&&(c=Math.min(a.hole_width,a.hole_height)),!c)continue;s[c]||(i.add("aper_function_header",{is_plated:!0}),i.add("define_tool",{tool_number:o,diameter:c}),s[c]=o,o++)}i.add("percent_sign",{}),i.add("G90",{}),i.add("G05",{});for(let a=10;a<o;a++){i.add("use_tool",{tool_number:a});for(const c of t)if(c.type==="pcb_plated_hole"||c.type==="pcb_hole"||c.type==="pcb_via"){let l;if("hole_diameter"in c&&(l=c.hole_diameter),c.type==="pcb_plated_hole"&&c.shape==="pill"){if(l=Math.min(c.hole_width,c.hole_height),s[l]===a){const u=n?-1:1;if(c.hole_width>c.hole_height){const d=(c.hole_width-c.hole_height)/2;i.add("G00",{}).add("drill_at",{x:c.x-d,y:c.y*u}).add("M15",{}).add("G01",{}).add("drill_at",{x:c.x+d,y:c.y*u}).add("M16",{}).add("G05",{})}else{const d=(c.hole_height-c.hole_width)/2;i.add("G00",{}).add("drill_at",{x:c.x,y:(c.y-d)*u}).add("M15",{}).add("G01",{}).add("drill_at",{x:c.x,y:(c.y+d)*u}).add("M16",{}).add("G05",{})}}}else if(l)s[l]===a&&i.add("drill_at",{x:c.x,y:c.y*(n?-1:1)});else continue}}return i.add("M30",{}),i.build()},Zm=({command_code:t,schema:e,stringify:n})=>({command_code:t,schema:e,stringify:n}),$Zn=Zm({command_code:"TA",schema:Ne({command_code:Ae("TA").default("TA"),attribute_name:B(),attribute_value:B()}).describe("Add attribute on aperture: Add an aperture attribute to the dictionary or modify it."),stringify:({attribute_name:t,attribute_value:e})=>`%TA${t},${e}*%`}),jZn=Zm({command_code:"TF",schema:Ne({command_code:Ae("TF").default("TF"),attribute_name:B(),attribute_value:B()}).describe("Add attribute on file: Set a file attribute."),stringify:({attribute_name:t,attribute_value:e})=>`%TF.${t},${e}*%`}),HZn=Zm({command_code:"TO",schema:Ne({command_code:Ae("TO").default("TO"),attribute_name:B(),attribute_value:B()}).describe("Add attribute on object: Add an object attribute to the dictionary or modify it."),stringify:({attribute_name:t,attribute_value:e})=>`%TO${t},${e}*%`}),VZn=Zm({command_code:"AB",schema:Ne({command_code:Ae("AB").default("AB"),block:B()}).describe("Aperture block: Opens a block aperture statement and assigns its aperture number or closes a block aperture statement"),stringify(){return""}}),GZn=Zm({command_code:"G04",schema:Ne({command_code:Ae("G04").default("G04"),comment:B()}).describe("Comment: A human readable comment, does not affect the image. 4.1"),stringify:t=>`G04 ${t.comment}*`}),YZn=Zm({command_code:"G75",schema:Ne({command_code:Ae("G75").default("G75")}).describe("Create arc: A G75 must be called before creating the first arc."),stringify(){return"G75*"}}),qZn=Zm({command_code:"AD",schema:Ne({command_code:Ae("AD").default("AD"),aperture_code:B()}).describe("Aperture define: Defines a template-based aperture, assigns a D code to it. 4.3"),stringify(){return""}}),XZn=Zm({command_code:"AM",schema:Ne({command_code:Ae("AM").default("AM"),macro_name:B(),template_code:B()}).describe("Aperture macro: Defines a macro aperture template. 4.5"),stringify({macro_name:t,template_code:e}){return`%AM${t}*
6559
+ \0`,Ie+=s(ue,2),Ie+=P.magic,Ie+=s(T,2),Ie+=s(N,2),Ie+=s(re.crc32,4),Ie+=s(re.compressedSize,4),Ie+=s(re.uncompressedSize,4),Ie+=s(I.length,2),Ie+=s(K.length,2),{fileRecord:h.LOCAL_FILE_HEADER+Ie+I+K,dirRecord:h.CENTRAL_FILE_HEADER+s(Te,2)+Ie+s(k.length,2)+"\0\0\0\0"+s(he,4)+s(b,4)+I+K+k}}var c=i("../utils"),l=i("../stream/GenericWorker"),u=i("../utf8"),d=i("../crc32"),h=i("../signature");function f(m,y,g,b){l.call(this,"ZipFileWorker"),this.bytesWritten=0,this.zipComment=y,this.zipPlatform=g,this.encodeFileName=b,this.streamFiles=m,this.accumulate=!1,this.contentBuffer=[],this.dirRecords=[],this.currentSourceOffset=0,this.entriesCount=0,this.currentFile=null,this._sources=[]}c.inherits(f,l),f.prototype.push=function(m){var y=m.meta.percent||0,g=this.entriesCount,b=this._sources.length;this.accumulate?this.contentBuffer.push(m):(this.bytesWritten+=m.data.length,l.prototype.push.call(this,{data:m.data,meta:{currentFile:this.currentFile,percent:g?(y+100*(g-b-1))/g:100}}))},f.prototype.openedSource=function(m){this.currentSourceOffset=this.bytesWritten,this.currentFile=m.file.name;var y=this.streamFiles&&!m.file.dir;if(y){var g=a(m,y,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);this.push({data:g.fileRecord,meta:{percent:0}})}else this.accumulate=!0},f.prototype.closedSource=function(m){this.accumulate=!1;var y=this.streamFiles&&!m.file.dir,g=a(m,y,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(g.dirRecord),y)this.push({data:(function(b){return h.DATA_DESCRIPTOR+s(b.crc32,4)+s(b.compressedSize,4)+s(b.uncompressedSize,4)})(m),meta:{percent:100}});else for(this.push({data:g.fileRecord,meta:{percent:0}});this.contentBuffer.length;)this.push(this.contentBuffer.shift());this.currentFile=null},f.prototype.flush=function(){for(var m=this.bytesWritten,y=0;y<this.dirRecords.length;y++)this.push({data:this.dirRecords[y],meta:{percent:100}});var g=this.bytesWritten-m,b=(function(v,w,T,N,R){var P=c.transformTo("string",R(N));return h.CENTRAL_DIRECTORY_END+"\0\0\0\0"+s(v,2)+s(v,2)+s(w,4)+s(T,4)+s(P.length,2)+P})(this.dirRecords.length,g,m,this.zipComment,this.encodeFileName);this.push({data:b,meta:{percent:100}})},f.prototype.prepareNextSource=function(){this.previous=this._sources.shift(),this.openedSource(this.previous.streamInfo),this.isPaused?this.previous.pause():this.previous.resume()},f.prototype.registerPrevious=function(m){this._sources.push(m);var y=this;return m.on("data",function(g){y.processChunk(g)}),m.on("end",function(){y.closedSource(y.previous.streamInfo),y._sources.length?y.prepareNextSource():y.end()}),m.on("error",function(g){y.error(g)}),this},f.prototype.resume=function(){return!!l.prototype.resume.call(this)&&(!this.previous&&this._sources.length?(this.prepareNextSource(),!0):this.previous||this._sources.length||this.generatedError?void 0:(this.end(),!0))},f.prototype.error=function(m){var y=this._sources;if(!l.prototype.error.call(this,m))return!1;for(var g=0;g<y.length;g++)try{y[g].error(m)}catch{}return!0},f.prototype.lock=function(){l.prototype.lock.call(this);for(var m=this._sources,y=0;y<m.length;y++)m[y].lock()},r.exports=f},{"../crc32":4,"../signature":23,"../stream/GenericWorker":28,"../utf8":31,"../utils":32}],9:[function(i,r,o){var s=i("../compressions"),a=i("./ZipFileWorker");o.generateWorker=function(c,l,u){var d=new a(l.streamFiles,u,l.platform,l.encodeFileName),h=0;try{c.forEach(function(f,m){h++;var y=(function(w,T){var N=w||T,R=s[N];if(!R)throw new Error(N+" is not a valid compression method !");return R})(m.options.compression,l.compression),g=m.options.compressionOptions||l.compressionOptions||{},b=m.dir,v=m.date;m._compressWorker(y,g).withStreamInfo("file",{name:f,dir:b,date:v,comment:m.comment||"",unixPermissions:m.unixPermissions,dosPermissions:m.dosPermissions}).pipe(d)}),d.entriesCount=h}catch(f){d.error(f)}return d}},{"../compressions":3,"./ZipFileWorker":8}],10:[function(i,r,o){function s(){if(!(this instanceof s))return new s;if(arguments.length)throw new Error("The constructor with parameters has been removed in JSZip 3.0, please check the upgrade guide.");this.files=Object.create(null),this.comment=null,this.root="",this.clone=function(){var a=new s;for(var c in this)typeof this[c]!="function"&&(a[c]=this[c]);return a}}(s.prototype=i("./object")).loadAsync=i("./load"),s.support=i("./support"),s.defaults=i("./defaults"),s.version="3.10.1",s.loadAsync=function(a,c){return new s().loadAsync(a,c)},s.external=i("./external"),r.exports=s},{"./defaults":5,"./external":6,"./load":11,"./object":15,"./support":30}],11:[function(i,r,o){var s=i("./utils"),a=i("./external"),c=i("./utf8"),l=i("./zipEntries"),u=i("./stream/Crc32Probe"),d=i("./nodejsUtils");function h(f){return new a.Promise(function(m,y){var g=f.decompressed.getContentWorker().pipe(new u);g.on("error",function(b){y(b)}).on("end",function(){g.streamInfo.crc32!==f.decompressed.crc32?y(new Error("Corrupted zip : CRC32 mismatch")):m()}).resume()})}r.exports=function(f,m){var y=this;return m=s.extend(m||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:c.utf8decode}),d.isNode&&d.isStream(f)?a.Promise.reject(new Error("JSZip can't accept a stream when loading a zip file.")):s.prepareContent("the loaded zip file",f,!0,m.optimizedBinaryString,m.base64).then(function(g){var b=new l(m);return b.load(g),b}).then(function(g){var b=[a.Promise.resolve(g)],v=g.files;if(m.checkCRC32)for(var w=0;w<v.length;w++)b.push(h(v[w]));return a.Promise.all(b)}).then(function(g){for(var b=g.shift(),v=b.files,w=0;w<v.length;w++){var T=v[w],N=T.fileNameStr,R=s.resolve(T.fileNameStr);y.file(R,T.decompressed,{binary:!0,optimizedBinaryString:!0,date:T.date,dir:T.dir,comment:T.fileCommentStr.length?T.fileCommentStr:null,unixPermissions:T.unixPermissions,dosPermissions:T.dosPermissions,createFolders:m.createFolders}),T.dir||(y.file(R).unsafeOriginalName=N)}return b.zipComment.length&&(y.comment=b.zipComment),y})}},{"./external":6,"./nodejsUtils":14,"./stream/Crc32Probe":25,"./utf8":31,"./utils":32,"./zipEntries":33}],12:[function(i,r,o){var s=i("../utils"),a=i("../stream/GenericWorker");function c(l,u){a.call(this,"Nodejs stream input adapter for "+l),this._upstreamEnded=!1,this._bindStream(u)}s.inherits(c,a),c.prototype._bindStream=function(l){var u=this;(this._stream=l).pause(),l.on("data",function(d){u.push({data:d,meta:{percent:0}})}).on("error",function(d){u.isPaused?this.generatedError=d:u.error(d)}).on("end",function(){u.isPaused?u._upstreamEnded=!0:u.end()})},c.prototype.pause=function(){return!!a.prototype.pause.call(this)&&(this._stream.pause(),!0)},c.prototype.resume=function(){return!!a.prototype.resume.call(this)&&(this._upstreamEnded?this.end():this._stream.resume(),!0)},r.exports=c},{"../stream/GenericWorker":28,"../utils":32}],13:[function(i,r,o){var s=i("readable-stream").Readable;function a(c,l,u){s.call(this,l),this._helper=c;var d=this;c.on("data",function(h,f){d.push(h)||d._helper.pause(),u&&u(f)}).on("error",function(h){d.emit("error",h)}).on("end",function(){d.push(null)})}i("../utils").inherits(a,s),a.prototype._read=function(){this._helper.resume()},r.exports=a},{"../utils":32,"readable-stream":16}],14:[function(i,r,o){r.exports={isNode:typeof Buffer<"u",newBufferFrom:function(s,a){if(Buffer.from&&Buffer.from!==Uint8Array.from)return Buffer.from(s,a);if(typeof s=="number")throw new Error('The "data" argument must not be a number');return new Buffer(s,a)},allocBuffer:function(s){if(Buffer.alloc)return Buffer.alloc(s);var a=new Buffer(s);return a.fill(0),a},isBuffer:function(s){return Buffer.isBuffer(s)},isStream:function(s){return s&&typeof s.on=="function"&&typeof s.pause=="function"&&typeof s.resume=="function"}}},{}],15:[function(i,r,o){function s(R,P,M){var I,A=c.getTypeOf(P),$=c.extend(M||{},d);$.date=$.date||new Date,$.compression!==null&&($.compression=$.compression.toUpperCase()),typeof $.unixPermissions=="string"&&($.unixPermissions=parseInt($.unixPermissions,8)),$.unixPermissions&&16384&$.unixPermissions&&($.dir=!0),$.dosPermissions&&16&$.dosPermissions&&($.dir=!0),$.dir&&(R=v(R)),$.createFolders&&(I=b(R))&&w.call(this,I,!0);var k=A==="string"&&$.binary===!1&&$.base64===!1;M&&M.binary!==void 0||($.binary=!k),(P instanceof h&&P.uncompressedSize===0||$.dir||!P||P.length===0)&&($.base64=!1,$.binary=!0,P="",$.compression="STORE",A="string");var V=null;V=P instanceof h||P instanceof l?P:y.isNode&&y.isStream(P)?new g(R,P):c.prepareContent(R,P,$.binary,$.optimizedBinaryString,$.base64);var X=new f(R,V,$);this.files[R]=X}var a=i("./utf8"),c=i("./utils"),l=i("./stream/GenericWorker"),u=i("./stream/StreamHelper"),d=i("./defaults"),h=i("./compressedObject"),f=i("./zipObject"),m=i("./generate"),y=i("./nodejsUtils"),g=i("./nodejs/NodejsStreamInputAdapter"),b=function(R){R.slice(-1)==="/"&&(R=R.substring(0,R.length-1));var P=R.lastIndexOf("/");return 0<P?R.substring(0,P):""},v=function(R){return R.slice(-1)!=="/"&&(R+="/"),R},w=function(R,P){return P=P!==void 0?P:d.createFolders,R=v(R),this.files[R]||s.call(this,R,null,{dir:!0,createFolders:P}),this.files[R]};function T(R){return Object.prototype.toString.call(R)==="[object RegExp]"}var N={load:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},forEach:function(R){var P,M,I;for(P in this.files)I=this.files[P],(M=P.slice(this.root.length,P.length))&&P.slice(0,this.root.length)===this.root&&R(M,I)},filter:function(R){var P=[];return this.forEach(function(M,I){R(M,I)&&P.push(I)}),P},file:function(R,P,M){if(arguments.length!==1)return R=this.root+R,s.call(this,R,P,M),this;if(T(R)){var I=R;return this.filter(function($,k){return!k.dir&&I.test($)})}var A=this.files[this.root+R];return A&&!A.dir?A:null},folder:function(R){if(!R)return this;if(T(R))return this.filter(function(A,$){return $.dir&&R.test(A)});var P=this.root+R,M=w.call(this,P),I=this.clone();return I.root=M.name,I},remove:function(R){R=this.root+R;var P=this.files[R];if(P||(R.slice(-1)!=="/"&&(R+="/"),P=this.files[R]),P&&!P.dir)delete this.files[R];else for(var M=this.filter(function(A,$){return $.name.slice(0,R.length)===R}),I=0;I<M.length;I++)delete this.files[M[I].name];return this},generate:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},generateInternalStream:function(R){var P,M={};try{if((M=c.extend(R||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:a.utf8encode})).type=M.type.toLowerCase(),M.compression=M.compression.toUpperCase(),M.type==="binarystring"&&(M.type="string"),!M.type)throw new Error("No output type specified.");c.checkSupport(M.type),M.platform!=="darwin"&&M.platform!=="freebsd"&&M.platform!=="linux"&&M.platform!=="sunos"||(M.platform="UNIX"),M.platform==="win32"&&(M.platform="DOS");var I=M.comment||this.comment||"";P=m.generateWorker(this,M,I)}catch(A){(P=new l("error")).error(A)}return new u(P,M.type||"string",M.mimeType)},generateAsync:function(R,P){return this.generateInternalStream(R).accumulate(P)},generateNodeStream:function(R,P){return(R=R||{}).type||(R.type="nodebuffer"),this.generateInternalStream(R).toNodejsStream(P)}};r.exports=N},{"./compressedObject":2,"./defaults":5,"./generate":9,"./nodejs/NodejsStreamInputAdapter":12,"./nodejsUtils":14,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31,"./utils":32,"./zipObject":35}],16:[function(i,r,o){r.exports=i("stream")},{stream:void 0}],17:[function(i,r,o){var s=i("./DataReader");function a(c){s.call(this,c);for(var l=0;l<this.data.length;l++)c[l]=255&c[l]}i("../utils").inherits(a,s),a.prototype.byteAt=function(c){return this.data[this.zero+c]},a.prototype.lastIndexOfSignature=function(c){for(var l=c.charCodeAt(0),u=c.charCodeAt(1),d=c.charCodeAt(2),h=c.charCodeAt(3),f=this.length-4;0<=f;--f)if(this.data[f]===l&&this.data[f+1]===u&&this.data[f+2]===d&&this.data[f+3]===h)return f-this.zero;return-1},a.prototype.readAndCheckSignature=function(c){var l=c.charCodeAt(0),u=c.charCodeAt(1),d=c.charCodeAt(2),h=c.charCodeAt(3),f=this.readData(4);return l===f[0]&&u===f[1]&&d===f[2]&&h===f[3]},a.prototype.readData=function(c){if(this.checkOffset(c),c===0)return[];var l=this.data.slice(this.zero+this.index,this.zero+this.index+c);return this.index+=c,l},r.exports=a},{"../utils":32,"./DataReader":18}],18:[function(i,r,o){var s=i("../utils");function a(c){this.data=c,this.length=c.length,this.index=0,this.zero=0}a.prototype={checkOffset:function(c){this.checkIndex(this.index+c)},checkIndex:function(c){if(this.length<this.zero+c||c<0)throw new Error("End of data reached (data length = "+this.length+", asked index = "+c+"). Corrupted zip ?")},setIndex:function(c){this.checkIndex(c),this.index=c},skip:function(c){this.setIndex(this.index+c)},byteAt:function(){},readInt:function(c){var l,u=0;for(this.checkOffset(c),l=this.index+c-1;l>=this.index;l--)u=(u<<8)+this.byteAt(l);return this.index+=c,u},readString:function(c){return s.transformTo("string",this.readData(c))},readData:function(){},lastIndexOfSignature:function(){},readAndCheckSignature:function(){},readDate:function(){var c=this.readInt(4);return new Date(Date.UTC(1980+(c>>25&127),(c>>21&15)-1,c>>16&31,c>>11&31,c>>5&63,(31&c)<<1))}},r.exports=a},{"../utils":32}],19:[function(i,r,o){var s=i("./Uint8ArrayReader");function a(c){s.call(this,c)}i("../utils").inherits(a,s),a.prototype.readData=function(c){this.checkOffset(c);var l=this.data.slice(this.zero+this.index,this.zero+this.index+c);return this.index+=c,l},r.exports=a},{"../utils":32,"./Uint8ArrayReader":21}],20:[function(i,r,o){var s=i("./DataReader");function a(c){s.call(this,c)}i("../utils").inherits(a,s),a.prototype.byteAt=function(c){return this.data.charCodeAt(this.zero+c)},a.prototype.lastIndexOfSignature=function(c){return this.data.lastIndexOf(c)-this.zero},a.prototype.readAndCheckSignature=function(c){return c===this.readData(4)},a.prototype.readData=function(c){this.checkOffset(c);var l=this.data.slice(this.zero+this.index,this.zero+this.index+c);return this.index+=c,l},r.exports=a},{"../utils":32,"./DataReader":18}],21:[function(i,r,o){var s=i("./ArrayReader");function a(c){s.call(this,c)}i("../utils").inherits(a,s),a.prototype.readData=function(c){if(this.checkOffset(c),c===0)return new Uint8Array(0);var l=this.data.subarray(this.zero+this.index,this.zero+this.index+c);return this.index+=c,l},r.exports=a},{"../utils":32,"./ArrayReader":17}],22:[function(i,r,o){var s=i("../utils"),a=i("../support"),c=i("./ArrayReader"),l=i("./StringReader"),u=i("./NodeBufferReader"),d=i("./Uint8ArrayReader");r.exports=function(h){var f=s.getTypeOf(h);return s.checkSupport(f),f!=="string"||a.uint8array?f==="nodebuffer"?new u(h):a.uint8array?new d(s.transformTo("uint8array",h)):new c(s.transformTo("array",h)):new l(h)}},{"../support":30,"../utils":32,"./ArrayReader":17,"./NodeBufferReader":19,"./StringReader":20,"./Uint8ArrayReader":21}],23:[function(i,r,o){o.LOCAL_FILE_HEADER="PK",o.CENTRAL_FILE_HEADER="PK",o.CENTRAL_DIRECTORY_END="PK",o.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK\x07",o.ZIP64_CENTRAL_DIRECTORY_END="PK",o.DATA_DESCRIPTOR="PK\x07\b"},{}],24:[function(i,r,o){var s=i("./GenericWorker"),a=i("../utils");function c(l){s.call(this,"ConvertWorker to "+l),this.destType=l}a.inherits(c,s),c.prototype.processChunk=function(l){this.push({data:a.transformTo(this.destType,l.data),meta:l.meta})},r.exports=c},{"../utils":32,"./GenericWorker":28}],25:[function(i,r,o){var s=i("./GenericWorker"),a=i("../crc32");function c(){s.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}i("../utils").inherits(c,s),c.prototype.processChunk=function(l){this.streamInfo.crc32=a(l.data,this.streamInfo.crc32||0),this.push(l)},r.exports=c},{"../crc32":4,"../utils":32,"./GenericWorker":28}],26:[function(i,r,o){var s=i("../utils"),a=i("./GenericWorker");function c(l){a.call(this,"DataLengthProbe for "+l),this.propName=l,this.withStreamInfo(l,0)}s.inherits(c,a),c.prototype.processChunk=function(l){if(l){var u=this.streamInfo[this.propName]||0;this.streamInfo[this.propName]=u+l.data.length}a.prototype.processChunk.call(this,l)},r.exports=c},{"../utils":32,"./GenericWorker":28}],27:[function(i,r,o){var s=i("../utils"),a=i("./GenericWorker");function c(l){a.call(this,"DataWorker");var u=this;this.dataIsReady=!1,this.index=0,this.max=0,this.data=null,this.type="",this._tickScheduled=!1,l.then(function(d){u.dataIsReady=!0,u.data=d,u.max=d&&d.length||0,u.type=s.getTypeOf(d),u.isPaused||u._tickAndRepeat()},function(d){u.error(d)})}s.inherits(c,a),c.prototype.cleanUp=function(){a.prototype.cleanUp.call(this),this.data=null},c.prototype.resume=function(){return!!a.prototype.resume.call(this)&&(!this._tickScheduled&&this.dataIsReady&&(this._tickScheduled=!0,s.delay(this._tickAndRepeat,[],this)),!0)},c.prototype._tickAndRepeat=function(){this._tickScheduled=!1,this.isPaused||this.isFinished||(this._tick(),this.isFinished||(s.delay(this._tickAndRepeat,[],this),this._tickScheduled=!0))},c.prototype._tick=function(){if(this.isPaused||this.isFinished)return!1;var l=null,u=Math.min(this.max,this.index+16384);if(this.index>=this.max)return this.end();switch(this.type){case"string":l=this.data.substring(this.index,u);break;case"uint8array":l=this.data.subarray(this.index,u);break;case"array":case"nodebuffer":l=this.data.slice(this.index,u)}return this.index=u,this.push({data:l,meta:{percent:this.max?this.index/this.max*100:0}})},r.exports=c},{"../utils":32,"./GenericWorker":28}],28:[function(i,r,o){function s(a){this.name=a||"default",this.streamInfo={},this.generatedError=null,this.extraStreamInfo={},this.isPaused=!0,this.isFinished=!1,this.isLocked=!1,this._listeners={data:[],end:[],error:[]},this.previous=null}s.prototype={push:function(a){this.emit("data",a)},end:function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),this.isFinished=!0}catch(a){this.emit("error",a)}return!0},error:function(a){return!this.isFinished&&(this.isPaused?this.generatedError=a:(this.isFinished=!0,this.emit("error",a),this.previous&&this.previous.error(a),this.cleanUp()),!0)},on:function(a,c){return this._listeners[a].push(c),this},cleanUp:function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},emit:function(a,c){if(this._listeners[a])for(var l=0;l<this._listeners[a].length;l++)this._listeners[a][l].call(this,c)},pipe:function(a){return a.registerPrevious(this)},registerPrevious:function(a){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.streamInfo=a.streamInfo,this.mergeStreamInfo(),this.previous=a;var c=this;return a.on("data",function(l){c.processChunk(l)}),a.on("end",function(){c.end()}),a.on("error",function(l){c.error(l)}),this},pause:function(){return!this.isPaused&&!this.isFinished&&(this.isPaused=!0,this.previous&&this.previous.pause(),!0)},resume:function(){if(!this.isPaused||this.isFinished)return!1;var a=this.isPaused=!1;return this.generatedError&&(this.error(this.generatedError),a=!0),this.previous&&this.previous.resume(),!a},flush:function(){},processChunk:function(a){this.push(a)},withStreamInfo:function(a,c){return this.extraStreamInfo[a]=c,this.mergeStreamInfo(),this},mergeStreamInfo:function(){for(var a in this.extraStreamInfo)Object.prototype.hasOwnProperty.call(this.extraStreamInfo,a)&&(this.streamInfo[a]=this.extraStreamInfo[a])},lock:function(){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.isLocked=!0,this.previous&&this.previous.lock()},toString:function(){var a="Worker "+this.name;return this.previous?this.previous+" -> "+a:a}},r.exports=s},{}],29:[function(i,r,o){var s=i("../utils"),a=i("./ConvertWorker"),c=i("./GenericWorker"),l=i("../base64"),u=i("../support"),d=i("../external"),h=null;if(u.nodestream)try{h=i("../nodejs/NodejsStreamOutputAdapter")}catch{}function f(y,g){return new d.Promise(function(b,v){var w=[],T=y._internalType,N=y._outputType,R=y._mimeType;y.on("data",function(P,M){w.push(P),g&&g(M)}).on("error",function(P){w=[],v(P)}).on("end",function(){try{var P=(function(M,I,A){switch(M){case"blob":return s.newBlob(s.transformTo("arraybuffer",I),A);case"base64":return l.encode(I);default:return s.transformTo(M,I)}})(N,(function(M,I){var A,$=0,k=null,V=0;for(A=0;A<I.length;A++)V+=I[A].length;switch(M){case"string":return I.join("");case"array":return Array.prototype.concat.apply([],I);case"uint8array":for(k=new Uint8Array(V),A=0;A<I.length;A++)k.set(I[A],$),$+=I[A].length;return k;case"nodebuffer":return Buffer.concat(I);default:throw new Error("concat : unsupported type '"+M+"'")}})(T,w),R);b(P)}catch(M){v(M)}w=[]}).resume()})}function m(y,g,b){var v=g;switch(g){case"blob":case"arraybuffer":v="uint8array";break;case"base64":v="string"}try{this._internalType=v,this._outputType=g,this._mimeType=b,s.checkSupport(v),this._worker=y.pipe(new a(v)),y.lock()}catch(w){this._worker=new c("error"),this._worker.error(w)}}m.prototype={accumulate:function(y){return f(this,y)},on:function(y,g){var b=this;return y==="data"?this._worker.on(y,function(v){g.call(b,v.data,v.meta)}):this._worker.on(y,function(){s.delay(g,arguments,b)}),this},resume:function(){return s.delay(this._worker.resume,[],this._worker),this},pause:function(){return this._worker.pause(),this},toNodejsStream:function(y){if(s.checkSupport("nodestream"),this._outputType!=="nodebuffer")throw new Error(this._outputType+" is not supported by this method");return new h(this,{objectMode:this._outputType!=="nodebuffer"},y)}},r.exports=m},{"../base64":1,"../external":6,"../nodejs/NodejsStreamOutputAdapter":13,"../support":30,"../utils":32,"./ConvertWorker":24,"./GenericWorker":28}],30:[function(i,r,o){if(o.base64=!0,o.array=!0,o.string=!0,o.arraybuffer=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u",o.nodebuffer=typeof Buffer<"u",o.uint8array=typeof Uint8Array<"u",typeof ArrayBuffer>"u")o.blob=!1;else{var s=new ArrayBuffer(0);try{o.blob=new Blob([s],{type:"application/zip"}).size===0}catch{try{var a=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);a.append(s),o.blob=a.getBlob("application/zip").size===0}catch{o.blob=!1}}}try{o.nodestream=!!i("readable-stream").Readable}catch{o.nodestream=!1}},{"readable-stream":16}],31:[function(i,r,o){for(var s=i("./utils"),a=i("./support"),c=i("./nodejsUtils"),l=i("./stream/GenericWorker"),u=new Array(256),d=0;d<256;d++)u[d]=252<=d?6:248<=d?5:240<=d?4:224<=d?3:192<=d?2:1;u[254]=u[254]=1;function h(){l.call(this,"utf-8 decode"),this.leftOver=null}function f(){l.call(this,"utf-8 encode")}o.utf8encode=function(m){return a.nodebuffer?c.newBufferFrom(m,"utf-8"):(function(y){var g,b,v,w,T,N=y.length,R=0;for(w=0;w<N;w++)(64512&(b=y.charCodeAt(w)))==55296&&w+1<N&&(64512&(v=y.charCodeAt(w+1)))==56320&&(b=65536+(b-55296<<10)+(v-56320),w++),R+=b<128?1:b<2048?2:b<65536?3:4;for(g=a.uint8array?new Uint8Array(R):new Array(R),w=T=0;T<R;w++)(64512&(b=y.charCodeAt(w)))==55296&&w+1<N&&(64512&(v=y.charCodeAt(w+1)))==56320&&(b=65536+(b-55296<<10)+(v-56320),w++),b<128?g[T++]=b:(b<2048?g[T++]=192|b>>>6:(b<65536?g[T++]=224|b>>>12:(g[T++]=240|b>>>18,g[T++]=128|b>>>12&63),g[T++]=128|b>>>6&63),g[T++]=128|63&b);return g})(m)},o.utf8decode=function(m){return a.nodebuffer?s.transformTo("nodebuffer",m).toString("utf-8"):(function(y){var g,b,v,w,T=y.length,N=new Array(2*T);for(g=b=0;g<T;)if((v=y[g++])<128)N[b++]=v;else if(4<(w=u[v]))N[b++]=65533,g+=w-1;else{for(v&=w===2?31:w===3?15:7;1<w&&g<T;)v=v<<6|63&y[g++],w--;1<w?N[b++]=65533:v<65536?N[b++]=v:(v-=65536,N[b++]=55296|v>>10&1023,N[b++]=56320|1023&v)}return N.length!==b&&(N.subarray?N=N.subarray(0,b):N.length=b),s.applyFromCharCode(N)})(m=s.transformTo(a.uint8array?"uint8array":"array",m))},s.inherits(h,l),h.prototype.processChunk=function(m){var y=s.transformTo(a.uint8array?"uint8array":"array",m.data);if(this.leftOver&&this.leftOver.length){if(a.uint8array){var g=y;(y=new Uint8Array(g.length+this.leftOver.length)).set(this.leftOver,0),y.set(g,this.leftOver.length)}else y=this.leftOver.concat(y);this.leftOver=null}var b=(function(w,T){var N;for((T=T||w.length)>w.length&&(T=w.length),N=T-1;0<=N&&(192&w[N])==128;)N--;return N<0||N===0?T:N+u[w[N]]>T?N:T})(y),v=y;b!==y.length&&(a.uint8array?(v=y.subarray(0,b),this.leftOver=y.subarray(b,y.length)):(v=y.slice(0,b),this.leftOver=y.slice(b,y.length))),this.push({data:o.utf8decode(v),meta:m.meta})},h.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:o.utf8decode(this.leftOver),meta:{}}),this.leftOver=null)},o.Utf8DecodeWorker=h,s.inherits(f,l),f.prototype.processChunk=function(m){this.push({data:o.utf8encode(m.data),meta:m.meta})},o.Utf8EncodeWorker=f},{"./nodejsUtils":14,"./stream/GenericWorker":28,"./support":30,"./utils":32}],32:[function(i,r,o){var s=i("./support"),a=i("./base64"),c=i("./nodejsUtils"),l=i("./external");function u(g){return g}function d(g,b){for(var v=0;v<g.length;++v)b[v]=255&g.charCodeAt(v);return b}i("setimmediate"),o.newBlob=function(g,b){o.checkSupport("blob");try{return new Blob([g],{type:b})}catch{try{var v=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);return v.append(g),v.getBlob(b)}catch{throw new Error("Bug : can't construct the Blob.")}}};var h={stringifyByChunk:function(g,b,v){var w=[],T=0,N=g.length;if(N<=v)return String.fromCharCode.apply(null,g);for(;T<N;)b==="array"||b==="nodebuffer"?w.push(String.fromCharCode.apply(null,g.slice(T,Math.min(T+v,N)))):w.push(String.fromCharCode.apply(null,g.subarray(T,Math.min(T+v,N)))),T+=v;return w.join("")},stringifyByChar:function(g){for(var b="",v=0;v<g.length;v++)b+=String.fromCharCode(g[v]);return b},applyCanBeUsed:{uint8array:(function(){try{return s.uint8array&&String.fromCharCode.apply(null,new Uint8Array(1)).length===1}catch{return!1}})(),nodebuffer:(function(){try{return s.nodebuffer&&String.fromCharCode.apply(null,c.allocBuffer(1)).length===1}catch{return!1}})()}};function f(g){var b=65536,v=o.getTypeOf(g),w=!0;if(v==="uint8array"?w=h.applyCanBeUsed.uint8array:v==="nodebuffer"&&(w=h.applyCanBeUsed.nodebuffer),w)for(;1<b;)try{return h.stringifyByChunk(g,v,b)}catch{b=Math.floor(b/2)}return h.stringifyByChar(g)}function m(g,b){for(var v=0;v<g.length;v++)b[v]=g[v];return b}o.applyFromCharCode=f;var y={};y.string={string:u,array:function(g){return d(g,new Array(g.length))},arraybuffer:function(g){return y.string.uint8array(g).buffer},uint8array:function(g){return d(g,new Uint8Array(g.length))},nodebuffer:function(g){return d(g,c.allocBuffer(g.length))}},y.array={string:f,array:u,arraybuffer:function(g){return new Uint8Array(g).buffer},uint8array:function(g){return new Uint8Array(g)},nodebuffer:function(g){return c.newBufferFrom(g)}},y.arraybuffer={string:function(g){return f(new Uint8Array(g))},array:function(g){return m(new Uint8Array(g),new Array(g.byteLength))},arraybuffer:u,uint8array:function(g){return new Uint8Array(g)},nodebuffer:function(g){return c.newBufferFrom(new Uint8Array(g))}},y.uint8array={string:f,array:function(g){return m(g,new Array(g.length))},arraybuffer:function(g){return g.buffer},uint8array:u,nodebuffer:function(g){return c.newBufferFrom(g)}},y.nodebuffer={string:f,array:function(g){return m(g,new Array(g.length))},arraybuffer:function(g){return y.nodebuffer.uint8array(g).buffer},uint8array:function(g){return m(g,new Uint8Array(g.length))},nodebuffer:u},o.transformTo=function(g,b){if(b=b||"",!g)return b;o.checkSupport(g);var v=o.getTypeOf(b);return y[v][g](b)},o.resolve=function(g){for(var b=g.split("/"),v=[],w=0;w<b.length;w++){var T=b[w];T==="."||T===""&&w!==0&&w!==b.length-1||(T===".."?v.pop():v.push(T))}return v.join("/")},o.getTypeOf=function(g){return typeof g=="string"?"string":Object.prototype.toString.call(g)==="[object Array]"?"array":s.nodebuffer&&c.isBuffer(g)?"nodebuffer":s.uint8array&&g instanceof Uint8Array?"uint8array":s.arraybuffer&&g instanceof ArrayBuffer?"arraybuffer":void 0},o.checkSupport=function(g){if(!s[g.toLowerCase()])throw new Error(g+" is not supported by this platform")},o.MAX_VALUE_16BITS=65535,o.MAX_VALUE_32BITS=-1,o.pretty=function(g){var b,v,w="";for(v=0;v<(g||"").length;v++)w+="\\x"+((b=g.charCodeAt(v))<16?"0":"")+b.toString(16).toUpperCase();return w},o.delay=function(g,b,v){setImmediate(function(){g.apply(v||null,b||[])})},o.inherits=function(g,b){function v(){}v.prototype=b.prototype,g.prototype=new v},o.extend=function(){var g,b,v={};for(g=0;g<arguments.length;g++)for(b in arguments[g])Object.prototype.hasOwnProperty.call(arguments[g],b)&&v[b]===void 0&&(v[b]=arguments[g][b]);return v},o.prepareContent=function(g,b,v,w,T){return l.Promise.resolve(b).then(function(N){return s.blob&&(N instanceof Blob||["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(N))!==-1)&&typeof FileReader<"u"?new l.Promise(function(R,P){var M=new FileReader;M.onload=function(I){R(I.target.result)},M.onerror=function(I){P(I.target.error)},M.readAsArrayBuffer(N)}):N}).then(function(N){var R=o.getTypeOf(N);return R?(R==="arraybuffer"?N=o.transformTo("uint8array",N):R==="string"&&(T?N=a.decode(N):v&&w!==!0&&(N=(function(P){return d(P,s.uint8array?new Uint8Array(P.length):new Array(P.length))})(N))),N):l.Promise.reject(new Error("Can't read the data of '"+g+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"))})}},{"./base64":1,"./external":6,"./nodejsUtils":14,"./support":30,setimmediate:54}],33:[function(i,r,o){var s=i("./reader/readerFor"),a=i("./utils"),c=i("./signature"),l=i("./zipEntry"),u=i("./support");function d(h){this.files=[],this.loadOptions=h}d.prototype={checkSignature:function(h){if(!this.reader.readAndCheckSignature(h)){this.reader.index-=4;var f=this.reader.readString(4);throw new Error("Corrupted zip or bug: unexpected signature ("+a.pretty(f)+", expected "+a.pretty(h)+")")}},isSignature:function(h,f){var m=this.reader.index;this.reader.setIndex(h);var y=this.reader.readString(4)===f;return this.reader.setIndex(m),y},readBlockEndOfCentral:function(){this.diskNumber=this.reader.readInt(2),this.diskWithCentralDirStart=this.reader.readInt(2),this.centralDirRecordsOnThisDisk=this.reader.readInt(2),this.centralDirRecords=this.reader.readInt(2),this.centralDirSize=this.reader.readInt(4),this.centralDirOffset=this.reader.readInt(4),this.zipCommentLength=this.reader.readInt(2);var h=this.reader.readData(this.zipCommentLength),f=u.uint8array?"uint8array":"array",m=a.transformTo(f,h);this.zipComment=this.loadOptions.decodeFileName(m)},readBlockZip64EndOfCentral:function(){this.zip64EndOfCentralSize=this.reader.readInt(8),this.reader.skip(4),this.diskNumber=this.reader.readInt(4),this.diskWithCentralDirStart=this.reader.readInt(4),this.centralDirRecordsOnThisDisk=this.reader.readInt(8),this.centralDirRecords=this.reader.readInt(8),this.centralDirSize=this.reader.readInt(8),this.centralDirOffset=this.reader.readInt(8),this.zip64ExtensibleData={};for(var h,f,m,y=this.zip64EndOfCentralSize-44;0<y;)h=this.reader.readInt(2),f=this.reader.readInt(4),m=this.reader.readData(f),this.zip64ExtensibleData[h]={id:h,length:f,value:m}},readBlockZip64EndOfCentralLocator:function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),1<this.disksCount)throw new Error("Multi-volumes zip are not supported")},readLocalFiles:function(){var h,f;for(h=0;h<this.files.length;h++)f=this.files[h],this.reader.setIndex(f.localHeaderOffset),this.checkSignature(c.LOCAL_FILE_HEADER),f.readLocalPart(this.reader),f.handleUTF8(),f.processAttributes()},readCentralDir:function(){var h;for(this.reader.setIndex(this.centralDirOffset);this.reader.readAndCheckSignature(c.CENTRAL_FILE_HEADER);)(h=new l({zip64:this.zip64},this.loadOptions)).readCentralPart(this.reader),this.files.push(h);if(this.centralDirRecords!==this.files.length&&this.centralDirRecords!==0&&this.files.length===0)throw new Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length)},readEndOfCentral:function(){var h=this.reader.lastIndexOfSignature(c.CENTRAL_DIRECTORY_END);if(h<0)throw this.isSignature(0,c.LOCAL_FILE_HEADER)?new Error("Corrupted zip: can't find end of central directory"):new Error("Can't find end of central directory : is this a zip file ? If it is, see https://stuk.github.io/jszip/documentation/howto/read_zip.html");this.reader.setIndex(h);var f=h;if(this.checkSignature(c.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===a.MAX_VALUE_16BITS||this.diskWithCentralDirStart===a.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===a.MAX_VALUE_16BITS||this.centralDirRecords===a.MAX_VALUE_16BITS||this.centralDirSize===a.MAX_VALUE_32BITS||this.centralDirOffset===a.MAX_VALUE_32BITS){if(this.zip64=!0,(h=this.reader.lastIndexOfSignature(c.ZIP64_CENTRAL_DIRECTORY_LOCATOR))<0)throw new Error("Corrupted zip: can't find the ZIP64 end of central directory locator");if(this.reader.setIndex(h),this.checkSignature(c.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,c.ZIP64_CENTRAL_DIRECTORY_END)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(c.ZIP64_CENTRAL_DIRECTORY_END),this.relativeOffsetEndOfZip64CentralDir<0))throw new Error("Corrupted zip: can't find the ZIP64 end of central directory");this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir),this.checkSignature(c.ZIP64_CENTRAL_DIRECTORY_END),this.readBlockZip64EndOfCentral()}var m=this.centralDirOffset+this.centralDirSize;this.zip64&&(m+=20,m+=12+this.zip64EndOfCentralSize);var y=f-m;if(0<y)this.isSignature(f,c.CENTRAL_FILE_HEADER)||(this.reader.zero=y);else if(y<0)throw new Error("Corrupted zip: missing "+Math.abs(y)+" bytes.")},prepareReader:function(h){this.reader=s(h)},load:function(h){this.prepareReader(h),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()}},r.exports=d},{"./reader/readerFor":22,"./signature":23,"./support":30,"./utils":32,"./zipEntry":34}],34:[function(i,r,o){var s=i("./reader/readerFor"),a=i("./utils"),c=i("./compressedObject"),l=i("./crc32"),u=i("./utf8"),d=i("./compressions"),h=i("./support");function f(m,y){this.options=m,this.loadOptions=y}f.prototype={isEncrypted:function(){return(1&this.bitFlag)==1},useUTF8:function(){return(2048&this.bitFlag)==2048},readLocalPart:function(m){var y,g;if(m.skip(22),this.fileNameLength=m.readInt(2),g=m.readInt(2),this.fileName=m.readData(this.fileNameLength),m.skip(g),this.compressedSize===-1||this.uncompressedSize===-1)throw new Error("Bug or corrupted zip : didn't get enough information from the central directory (compressedSize === -1 || uncompressedSize === -1)");if((y=(function(b){for(var v in d)if(Object.prototype.hasOwnProperty.call(d,v)&&d[v].magic===b)return d[v];return null})(this.compressionMethod))===null)throw new Error("Corrupted zip : compression "+a.pretty(this.compressionMethod)+" unknown (inner file : "+a.transformTo("string",this.fileName)+")");this.decompressed=new c(this.compressedSize,this.uncompressedSize,this.crc32,y,m.readData(this.compressedSize))},readCentralPart:function(m){this.versionMadeBy=m.readInt(2),m.skip(2),this.bitFlag=m.readInt(2),this.compressionMethod=m.readString(2),this.date=m.readDate(),this.crc32=m.readInt(4),this.compressedSize=m.readInt(4),this.uncompressedSize=m.readInt(4);var y=m.readInt(2);if(this.extraFieldsLength=m.readInt(2),this.fileCommentLength=m.readInt(2),this.diskNumberStart=m.readInt(2),this.internalFileAttributes=m.readInt(2),this.externalFileAttributes=m.readInt(4),this.localHeaderOffset=m.readInt(4),this.isEncrypted())throw new Error("Encrypted zip are not supported");m.skip(y),this.readExtraFields(m),this.parseZIP64ExtraField(m),this.fileComment=m.readData(this.fileCommentLength)},processAttributes:function(){this.unixPermissions=null,this.dosPermissions=null;var m=this.versionMadeBy>>8;this.dir=!!(16&this.externalFileAttributes),m==0&&(this.dosPermissions=63&this.externalFileAttributes),m==3&&(this.unixPermissions=this.externalFileAttributes>>16&65535),this.dir||this.fileNameStr.slice(-1)!=="/"||(this.dir=!0)},parseZIP64ExtraField:function(){if(this.extraFields[1]){var m=s(this.extraFields[1].value);this.uncompressedSize===a.MAX_VALUE_32BITS&&(this.uncompressedSize=m.readInt(8)),this.compressedSize===a.MAX_VALUE_32BITS&&(this.compressedSize=m.readInt(8)),this.localHeaderOffset===a.MAX_VALUE_32BITS&&(this.localHeaderOffset=m.readInt(8)),this.diskNumberStart===a.MAX_VALUE_32BITS&&(this.diskNumberStart=m.readInt(4))}},readExtraFields:function(m){var y,g,b,v=m.index+this.extraFieldsLength;for(this.extraFields||(this.extraFields={});m.index+4<v;)y=m.readInt(2),g=m.readInt(2),b=m.readData(g),this.extraFields[y]={id:y,length:g,value:b};m.setIndex(v)},handleUTF8:function(){var m=h.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=u.utf8decode(this.fileName),this.fileCommentStr=u.utf8decode(this.fileComment);else{var y=this.findExtraFieldUnicodePath();if(y!==null)this.fileNameStr=y;else{var g=a.transformTo(m,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(g)}var b=this.findExtraFieldUnicodeComment();if(b!==null)this.fileCommentStr=b;else{var v=a.transformTo(m,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(v)}}},findExtraFieldUnicodePath:function(){var m=this.extraFields[28789];if(m){var y=s(m.value);return y.readInt(1)!==1||l(this.fileName)!==y.readInt(4)?null:u.utf8decode(y.readData(m.length-5))}return null},findExtraFieldUnicodeComment:function(){var m=this.extraFields[25461];if(m){var y=s(m.value);return y.readInt(1)!==1||l(this.fileComment)!==y.readInt(4)?null:u.utf8decode(y.readData(m.length-5))}return null}},r.exports=f},{"./compressedObject":2,"./compressions":3,"./crc32":4,"./reader/readerFor":22,"./support":30,"./utf8":31,"./utils":32}],35:[function(i,r,o){function s(y,g,b){this.name=y,this.dir=b.dir,this.date=b.date,this.comment=b.comment,this.unixPermissions=b.unixPermissions,this.dosPermissions=b.dosPermissions,this._data=g,this._dataBinary=b.binary,this.options={compression:b.compression,compressionOptions:b.compressionOptions}}var a=i("./stream/StreamHelper"),c=i("./stream/DataWorker"),l=i("./utf8"),u=i("./compressedObject"),d=i("./stream/GenericWorker");s.prototype={internalStream:function(y){var g=null,b="string";try{if(!y)throw new Error("No output type specified.");var v=(b=y.toLowerCase())==="string"||b==="text";b!=="binarystring"&&b!=="text"||(b="string"),g=this._decompressWorker();var w=!this._dataBinary;w&&!v&&(g=g.pipe(new l.Utf8EncodeWorker)),!w&&v&&(g=g.pipe(new l.Utf8DecodeWorker))}catch(T){(g=new d("error")).error(T)}return new a(g,b,"")},async:function(y,g){return this.internalStream(y).accumulate(g)},nodeStream:function(y,g){return this.internalStream(y||"nodebuffer").toNodejsStream(g)},_compressWorker:function(y,g){if(this._data instanceof u&&this._data.compression.magic===y.magic)return this._data.getCompressedWorker();var b=this._decompressWorker();return this._dataBinary||(b=b.pipe(new l.Utf8EncodeWorker)),u.createWorkerFrom(b,y,g)},_decompressWorker:function(){return this._data instanceof u?this._data.getContentWorker():this._data instanceof d?this._data:new c(this._data)}};for(var h=["asText","asBinary","asNodeBuffer","asUint8Array","asArrayBuffer"],f=function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},m=0;m<h.length;m++)s.prototype[h[m]]=f;r.exports=s},{"./compressedObject":2,"./stream/DataWorker":27,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31}],36:[function(i,r,o){(function(s){var a,c,l=s.MutationObserver||s.WebKitMutationObserver;if(l){var u=0,d=new l(y),h=s.document.createTextNode("");d.observe(h,{characterData:!0}),a=function(){h.data=u=++u%2}}else if(s.setImmediate||s.MessageChannel===void 0)a="document"in s&&"onreadystatechange"in s.document.createElement("script")?function(){var g=s.document.createElement("script");g.onreadystatechange=function(){y(),g.onreadystatechange=null,g.parentNode.removeChild(g),g=null},s.document.documentElement.appendChild(g)}:function(){setTimeout(y,0)};else{var f=new s.MessageChannel;f.port1.onmessage=y,a=function(){f.port2.postMessage(0)}}var m=[];function y(){var g,b;c=!0;for(var v=m.length;v;){for(b=m,m=[],g=-1;++g<v;)b[g]();v=m.length}c=!1}r.exports=function(g){m.push(g)!==1||c||a()}}).call(this,typeof FO<"u"?FO:typeof self<"u"?self:typeof window<"u"?window:{})},{}],37:[function(i,r,o){var s=i("immediate");function a(){}var c={},l=["REJECTED"],u=["FULFILLED"],d=["PENDING"];function h(v){if(typeof v!="function")throw new TypeError("resolver must be a function");this.state=d,this.queue=[],this.outcome=void 0,v!==a&&g(this,v)}function f(v,w,T){this.promise=v,typeof w=="function"&&(this.onFulfilled=w,this.callFulfilled=this.otherCallFulfilled),typeof T=="function"&&(this.onRejected=T,this.callRejected=this.otherCallRejected)}function m(v,w,T){s(function(){var N;try{N=w(T)}catch(R){return c.reject(v,R)}N===v?c.reject(v,new TypeError("Cannot resolve promise with itself")):c.resolve(v,N)})}function y(v){var w=v&&v.then;if(v&&(typeof v=="object"||typeof v=="function")&&typeof w=="function")return function(){w.apply(v,arguments)}}function g(v,w){var T=!1;function N(M){T||(T=!0,c.reject(v,M))}function R(M){T||(T=!0,c.resolve(v,M))}var P=b(function(){w(R,N)});P.status==="error"&&N(P.value)}function b(v,w){var T={};try{T.value=v(w),T.status="success"}catch(N){T.status="error",T.value=N}return T}(r.exports=h).prototype.finally=function(v){if(typeof v!="function")return this;var w=this.constructor;return this.then(function(T){return w.resolve(v()).then(function(){return T})},function(T){return w.resolve(v()).then(function(){throw T})})},h.prototype.catch=function(v){return this.then(null,v)},h.prototype.then=function(v,w){if(typeof v!="function"&&this.state===u||typeof w!="function"&&this.state===l)return this;var T=new this.constructor(a);return this.state!==d?m(T,this.state===u?v:w,this.outcome):this.queue.push(new f(T,v,w)),T},f.prototype.callFulfilled=function(v){c.resolve(this.promise,v)},f.prototype.otherCallFulfilled=function(v){m(this.promise,this.onFulfilled,v)},f.prototype.callRejected=function(v){c.reject(this.promise,v)},f.prototype.otherCallRejected=function(v){m(this.promise,this.onRejected,v)},c.resolve=function(v,w){var T=b(y,w);if(T.status==="error")return c.reject(v,T.value);var N=T.value;if(N)g(v,N);else{v.state=u,v.outcome=w;for(var R=-1,P=v.queue.length;++R<P;)v.queue[R].callFulfilled(w)}return v},c.reject=function(v,w){v.state=l,v.outcome=w;for(var T=-1,N=v.queue.length;++T<N;)v.queue[T].callRejected(w);return v},h.resolve=function(v){return v instanceof this?v:c.resolve(new this(a),v)},h.reject=function(v){var w=new this(a);return c.reject(w,v)},h.all=function(v){var w=this;if(Object.prototype.toString.call(v)!=="[object Array]")return this.reject(new TypeError("must be an array"));var T=v.length,N=!1;if(!T)return this.resolve([]);for(var R=new Array(T),P=0,M=-1,I=new this(a);++M<T;)A(v[M],M);return I;function A($,k){w.resolve($).then(function(V){R[k]=V,++P!==T||N||(N=!0,c.resolve(I,R))},function(V){N||(N=!0,c.reject(I,V))})}},h.race=function(v){var w=this;if(Object.prototype.toString.call(v)!=="[object Array]")return this.reject(new TypeError("must be an array"));var T=v.length,N=!1;if(!T)return this.resolve([]);for(var R=-1,P=new this(a);++R<T;)M=v[R],w.resolve(M).then(function(I){N||(N=!0,c.resolve(P,I))},function(I){N||(N=!0,c.reject(P,I))});var M;return P}},{immediate:36}],38:[function(i,r,o){var s={};(0,i("./lib/utils/common").assign)(s,i("./lib/deflate"),i("./lib/inflate"),i("./lib/zlib/constants")),r.exports=s},{"./lib/deflate":39,"./lib/inflate":40,"./lib/utils/common":41,"./lib/zlib/constants":44}],39:[function(i,r,o){var s=i("./zlib/deflate"),a=i("./utils/common"),c=i("./utils/strings"),l=i("./zlib/messages"),u=i("./zlib/zstream"),d=Object.prototype.toString,h=0,f=-1,m=0,y=8;function g(v){if(!(this instanceof g))return new g(v);this.options=a.assign({level:f,method:y,chunkSize:16384,windowBits:15,memLevel:8,strategy:m,to:""},v||{});var w=this.options;w.raw&&0<w.windowBits?w.windowBits=-w.windowBits:w.gzip&&0<w.windowBits&&w.windowBits<16&&(w.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new u,this.strm.avail_out=0;var T=s.deflateInit2(this.strm,w.level,w.method,w.windowBits,w.memLevel,w.strategy);if(T!==h)throw new Error(l[T]);if(w.header&&s.deflateSetHeader(this.strm,w.header),w.dictionary){var N;if(N=typeof w.dictionary=="string"?c.string2buf(w.dictionary):d.call(w.dictionary)==="[object ArrayBuffer]"?new Uint8Array(w.dictionary):w.dictionary,(T=s.deflateSetDictionary(this.strm,N))!==h)throw new Error(l[T]);this._dict_set=!0}}function b(v,w){var T=new g(w);if(T.push(v,!0),T.err)throw T.msg||l[T.err];return T.result}g.prototype.push=function(v,w){var T,N,R=this.strm,P=this.options.chunkSize;if(this.ended)return!1;N=w===~~w?w:w===!0?4:0,typeof v=="string"?R.input=c.string2buf(v):d.call(v)==="[object ArrayBuffer]"?R.input=new Uint8Array(v):R.input=v,R.next_in=0,R.avail_in=R.input.length;do{if(R.avail_out===0&&(R.output=new a.Buf8(P),R.next_out=0,R.avail_out=P),(T=s.deflate(R,N))!==1&&T!==h)return this.onEnd(T),!(this.ended=!0);R.avail_out!==0&&(R.avail_in!==0||N!==4&&N!==2)||(this.options.to==="string"?this.onData(c.buf2binstring(a.shrinkBuf(R.output,R.next_out))):this.onData(a.shrinkBuf(R.output,R.next_out)))}while((0<R.avail_in||R.avail_out===0)&&T!==1);return N===4?(T=s.deflateEnd(this.strm),this.onEnd(T),this.ended=!0,T===h):N!==2||(this.onEnd(h),!(R.avail_out=0))},g.prototype.onData=function(v){this.chunks.push(v)},g.prototype.onEnd=function(v){v===h&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=a.flattenChunks(this.chunks)),this.chunks=[],this.err=v,this.msg=this.strm.msg},o.Deflate=g,o.deflate=b,o.deflateRaw=function(v,w){return(w=w||{}).raw=!0,b(v,w)},o.gzip=function(v,w){return(w=w||{}).gzip=!0,b(v,w)}},{"./utils/common":41,"./utils/strings":42,"./zlib/deflate":46,"./zlib/messages":51,"./zlib/zstream":53}],40:[function(i,r,o){var s=i("./zlib/inflate"),a=i("./utils/common"),c=i("./utils/strings"),l=i("./zlib/constants"),u=i("./zlib/messages"),d=i("./zlib/zstream"),h=i("./zlib/gzheader"),f=Object.prototype.toString;function m(g){if(!(this instanceof m))return new m(g);this.options=a.assign({chunkSize:16384,windowBits:0,to:""},g||{});var b=this.options;b.raw&&0<=b.windowBits&&b.windowBits<16&&(b.windowBits=-b.windowBits,b.windowBits===0&&(b.windowBits=-15)),!(0<=b.windowBits&&b.windowBits<16)||g&&g.windowBits||(b.windowBits+=32),15<b.windowBits&&b.windowBits<48&&(15&b.windowBits)==0&&(b.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new d,this.strm.avail_out=0;var v=s.inflateInit2(this.strm,b.windowBits);if(v!==l.Z_OK)throw new Error(u[v]);this.header=new h,s.inflateGetHeader(this.strm,this.header)}function y(g,b){var v=new m(b);if(v.push(g,!0),v.err)throw v.msg||u[v.err];return v.result}m.prototype.push=function(g,b){var v,w,T,N,R,P,M=this.strm,I=this.options.chunkSize,A=this.options.dictionary,$=!1;if(this.ended)return!1;w=b===~~b?b:b===!0?l.Z_FINISH:l.Z_NO_FLUSH,typeof g=="string"?M.input=c.binstring2buf(g):f.call(g)==="[object ArrayBuffer]"?M.input=new Uint8Array(g):M.input=g,M.next_in=0,M.avail_in=M.input.length;do{if(M.avail_out===0&&(M.output=new a.Buf8(I),M.next_out=0,M.avail_out=I),(v=s.inflate(M,l.Z_NO_FLUSH))===l.Z_NEED_DICT&&A&&(P=typeof A=="string"?c.string2buf(A):f.call(A)==="[object ArrayBuffer]"?new Uint8Array(A):A,v=s.inflateSetDictionary(this.strm,P)),v===l.Z_BUF_ERROR&&$===!0&&(v=l.Z_OK,$=!1),v!==l.Z_STREAM_END&&v!==l.Z_OK)return this.onEnd(v),!(this.ended=!0);M.next_out&&(M.avail_out!==0&&v!==l.Z_STREAM_END&&(M.avail_in!==0||w!==l.Z_FINISH&&w!==l.Z_SYNC_FLUSH)||(this.options.to==="string"?(T=c.utf8border(M.output,M.next_out),N=M.next_out-T,R=c.buf2string(M.output,T),M.next_out=N,M.avail_out=I-N,N&&a.arraySet(M.output,M.output,T,N,0),this.onData(R)):this.onData(a.shrinkBuf(M.output,M.next_out)))),M.avail_in===0&&M.avail_out===0&&($=!0)}while((0<M.avail_in||M.avail_out===0)&&v!==l.Z_STREAM_END);return v===l.Z_STREAM_END&&(w=l.Z_FINISH),w===l.Z_FINISH?(v=s.inflateEnd(this.strm),this.onEnd(v),this.ended=!0,v===l.Z_OK):w!==l.Z_SYNC_FLUSH||(this.onEnd(l.Z_OK),!(M.avail_out=0))},m.prototype.onData=function(g){this.chunks.push(g)},m.prototype.onEnd=function(g){g===l.Z_OK&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=a.flattenChunks(this.chunks)),this.chunks=[],this.err=g,this.msg=this.strm.msg},o.Inflate=m,o.inflate=y,o.inflateRaw=function(g,b){return(b=b||{}).raw=!0,y(g,b)},o.ungzip=y},{"./utils/common":41,"./utils/strings":42,"./zlib/constants":44,"./zlib/gzheader":47,"./zlib/inflate":49,"./zlib/messages":51,"./zlib/zstream":53}],41:[function(i,r,o){var s=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Int32Array<"u";o.assign=function(l){for(var u=Array.prototype.slice.call(arguments,1);u.length;){var d=u.shift();if(d){if(typeof d!="object")throw new TypeError(d+"must be non-object");for(var h in d)d.hasOwnProperty(h)&&(l[h]=d[h])}}return l},o.shrinkBuf=function(l,u){return l.length===u?l:l.subarray?l.subarray(0,u):(l.length=u,l)};var a={arraySet:function(l,u,d,h,f){if(u.subarray&&l.subarray)l.set(u.subarray(d,d+h),f);else for(var m=0;m<h;m++)l[f+m]=u[d+m]},flattenChunks:function(l){var u,d,h,f,m,y;for(u=h=0,d=l.length;u<d;u++)h+=l[u].length;for(y=new Uint8Array(h),u=f=0,d=l.length;u<d;u++)m=l[u],y.set(m,f),f+=m.length;return y}},c={arraySet:function(l,u,d,h,f){for(var m=0;m<h;m++)l[f+m]=u[d+m]},flattenChunks:function(l){return[].concat.apply([],l)}};o.setTyped=function(l){l?(o.Buf8=Uint8Array,o.Buf16=Uint16Array,o.Buf32=Int32Array,o.assign(o,a)):(o.Buf8=Array,o.Buf16=Array,o.Buf32=Array,o.assign(o,c))},o.setTyped(s)},{}],42:[function(i,r,o){var s=i("./common"),a=!0,c=!0;try{String.fromCharCode.apply(null,[0])}catch{a=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{c=!1}for(var l=new s.Buf8(256),u=0;u<256;u++)l[u]=252<=u?6:248<=u?5:240<=u?4:224<=u?3:192<=u?2:1;function d(h,f){if(f<65537&&(h.subarray&&c||!h.subarray&&a))return String.fromCharCode.apply(null,s.shrinkBuf(h,f));for(var m="",y=0;y<f;y++)m+=String.fromCharCode(h[y]);return m}l[254]=l[254]=1,o.string2buf=function(h){var f,m,y,g,b,v=h.length,w=0;for(g=0;g<v;g++)(64512&(m=h.charCodeAt(g)))==55296&&g+1<v&&(64512&(y=h.charCodeAt(g+1)))==56320&&(m=65536+(m-55296<<10)+(y-56320),g++),w+=m<128?1:m<2048?2:m<65536?3:4;for(f=new s.Buf8(w),g=b=0;b<w;g++)(64512&(m=h.charCodeAt(g)))==55296&&g+1<v&&(64512&(y=h.charCodeAt(g+1)))==56320&&(m=65536+(m-55296<<10)+(y-56320),g++),m<128?f[b++]=m:(m<2048?f[b++]=192|m>>>6:(m<65536?f[b++]=224|m>>>12:(f[b++]=240|m>>>18,f[b++]=128|m>>>12&63),f[b++]=128|m>>>6&63),f[b++]=128|63&m);return f},o.buf2binstring=function(h){return d(h,h.length)},o.binstring2buf=function(h){for(var f=new s.Buf8(h.length),m=0,y=f.length;m<y;m++)f[m]=h.charCodeAt(m);return f},o.buf2string=function(h,f){var m,y,g,b,v=f||h.length,w=new Array(2*v);for(m=y=0;m<v;)if((g=h[m++])<128)w[y++]=g;else if(4<(b=l[g]))w[y++]=65533,m+=b-1;else{for(g&=b===2?31:b===3?15:7;1<b&&m<v;)g=g<<6|63&h[m++],b--;1<b?w[y++]=65533:g<65536?w[y++]=g:(g-=65536,w[y++]=55296|g>>10&1023,w[y++]=56320|1023&g)}return d(w,y)},o.utf8border=function(h,f){var m;for((f=f||h.length)>h.length&&(f=h.length),m=f-1;0<=m&&(192&h[m])==128;)m--;return m<0||m===0?f:m+l[h[m]]>f?m:f}},{"./common":41}],43:[function(i,r,o){r.exports=function(s,a,c,l){for(var u=65535&s|0,d=s>>>16&65535|0,h=0;c!==0;){for(c-=h=2e3<c?2e3:c;d=d+(u=u+a[l++]|0)|0,--h;);u%=65521,d%=65521}return u|d<<16|0}},{}],44:[function(i,r,o){r.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],45:[function(i,r,o){var s=(function(){for(var a,c=[],l=0;l<256;l++){a=l;for(var u=0;u<8;u++)a=1&a?3988292384^a>>>1:a>>>1;c[l]=a}return c})();r.exports=function(a,c,l,u){var d=s,h=u+l;a^=-1;for(var f=u;f<h;f++)a=a>>>8^d[255&(a^c[f])];return-1^a}},{}],46:[function(i,r,o){var s,a=i("../utils/common"),c=i("./trees"),l=i("./adler32"),u=i("./crc32"),d=i("./messages"),h=0,f=4,m=0,y=-2,g=-1,b=4,v=2,w=8,T=9,N=286,R=30,P=19,M=2*N+1,I=15,A=3,$=258,k=$+A+1,V=42,X=113,W=1,K=2,ee=3,se=4;function de(Se,dt){return Se.msg=d[dt],dt}function be(Se){return(Se<<1)-(4<Se?9:0)}function re(Se){for(var dt=Se.length;0<=--dt;)Se[dt]=0}function ue(Se){var dt=Se.state,Ke=dt.pending;Ke>Se.avail_out&&(Ke=Se.avail_out),Ke!==0&&(a.arraySet(Se.output,dt.pending_buf,dt.pending_out,Ke,Se.next_out),Se.next_out+=Ke,dt.pending_out+=Ke,Se.total_out+=Ke,Se.avail_out-=Ke,dt.pending-=Ke,dt.pending===0&&(dt.pending_out=0))}function he(Se,dt){c._tr_flush_block(Se,0<=Se.block_start?Se.block_start:-1,Se.strstart-Se.block_start,dt),Se.block_start=Se.strstart,ue(Se.strm)}function Te(Se,dt){Se.pending_buf[Se.pending++]=dt}function Ie(Se,dt){Se.pending_buf[Se.pending++]=dt>>>8&255,Se.pending_buf[Se.pending++]=255&dt}function De(Se,dt){var Ke,Xe,Qe=Se.max_chain_length,He=Se.strstart,Pe=Se.prev_length,Ye=Se.nice_match,Oe=Se.strstart>Se.w_size-k?Se.strstart-(Se.w_size-k):0,Ze=Se.window,nt=Se.w_mask,pt=Se.prev,gt=Se.strstart+$,Et=Ze[He+Pe-1],Nt=Ze[He+Pe];Se.prev_length>=Se.good_match&&(Qe>>=2),Ye>Se.lookahead&&(Ye=Se.lookahead);do if(Ze[(Ke=dt)+Pe]===Nt&&Ze[Ke+Pe-1]===Et&&Ze[Ke]===Ze[He]&&Ze[++Ke]===Ze[He+1]){He+=2,Ke++;do;while(Ze[++He]===Ze[++Ke]&&Ze[++He]===Ze[++Ke]&&Ze[++He]===Ze[++Ke]&&Ze[++He]===Ze[++Ke]&&Ze[++He]===Ze[++Ke]&&Ze[++He]===Ze[++Ke]&&Ze[++He]===Ze[++Ke]&&Ze[++He]===Ze[++Ke]&&He<gt);if(Xe=$-(gt-He),He=gt-$,Pe<Xe){if(Se.match_start=dt,Ye<=(Pe=Xe))break;Et=Ze[He+Pe-1],Nt=Ze[He+Pe]}}while((dt=pt[dt&nt])>Oe&&--Qe!=0);return Pe<=Se.lookahead?Pe:Se.lookahead}function Ge(Se){var dt,Ke,Xe,Qe,He,Pe,Ye,Oe,Ze,nt,pt=Se.w_size;do{if(Qe=Se.window_size-Se.lookahead-Se.strstart,Se.strstart>=pt+(pt-k)){for(a.arraySet(Se.window,Se.window,pt,pt,0),Se.match_start-=pt,Se.strstart-=pt,Se.block_start-=pt,dt=Ke=Se.hash_size;Xe=Se.head[--dt],Se.head[dt]=pt<=Xe?Xe-pt:0,--Ke;);for(dt=Ke=pt;Xe=Se.prev[--dt],Se.prev[dt]=pt<=Xe?Xe-pt:0,--Ke;);Qe+=pt}if(Se.strm.avail_in===0)break;if(Pe=Se.strm,Ye=Se.window,Oe=Se.strstart+Se.lookahead,Ze=Qe,nt=void 0,nt=Pe.avail_in,Ze<nt&&(nt=Ze),Ke=nt===0?0:(Pe.avail_in-=nt,a.arraySet(Ye,Pe.input,Pe.next_in,nt,Oe),Pe.state.wrap===1?Pe.adler=l(Pe.adler,Ye,nt,Oe):Pe.state.wrap===2&&(Pe.adler=u(Pe.adler,Ye,nt,Oe)),Pe.next_in+=nt,Pe.total_in+=nt,nt),Se.lookahead+=Ke,Se.lookahead+Se.insert>=A)for(He=Se.strstart-Se.insert,Se.ins_h=Se.window[He],Se.ins_h=(Se.ins_h<<Se.hash_shift^Se.window[He+1])&Se.hash_mask;Se.insert&&(Se.ins_h=(Se.ins_h<<Se.hash_shift^Se.window[He+A-1])&Se.hash_mask,Se.prev[He&Se.w_mask]=Se.head[Se.ins_h],Se.head[Se.ins_h]=He,He++,Se.insert--,!(Se.lookahead+Se.insert<A)););}while(Se.lookahead<k&&Se.strm.avail_in!==0)}function ke(Se,dt){for(var Ke,Xe;;){if(Se.lookahead<k){if(Ge(Se),Se.lookahead<k&&dt===h)return W;if(Se.lookahead===0)break}if(Ke=0,Se.lookahead>=A&&(Se.ins_h=(Se.ins_h<<Se.hash_shift^Se.window[Se.strstart+A-1])&Se.hash_mask,Ke=Se.prev[Se.strstart&Se.w_mask]=Se.head[Se.ins_h],Se.head[Se.ins_h]=Se.strstart),Ke!==0&&Se.strstart-Ke<=Se.w_size-k&&(Se.match_length=De(Se,Ke)),Se.match_length>=A)if(Xe=c._tr_tally(Se,Se.strstart-Se.match_start,Se.match_length-A),Se.lookahead-=Se.match_length,Se.match_length<=Se.max_lazy_match&&Se.lookahead>=A){for(Se.match_length--;Se.strstart++,Se.ins_h=(Se.ins_h<<Se.hash_shift^Se.window[Se.strstart+A-1])&Se.hash_mask,Ke=Se.prev[Se.strstart&Se.w_mask]=Se.head[Se.ins_h],Se.head[Se.ins_h]=Se.strstart,--Se.match_length!=0;);Se.strstart++}else Se.strstart+=Se.match_length,Se.match_length=0,Se.ins_h=Se.window[Se.strstart],Se.ins_h=(Se.ins_h<<Se.hash_shift^Se.window[Se.strstart+1])&Se.hash_mask;else Xe=c._tr_tally(Se,0,Se.window[Se.strstart]),Se.lookahead--,Se.strstart++;if(Xe&&(he(Se,!1),Se.strm.avail_out===0))return W}return Se.insert=Se.strstart<A-1?Se.strstart:A-1,dt===f?(he(Se,!0),Se.strm.avail_out===0?ee:se):Se.last_lit&&(he(Se,!1),Se.strm.avail_out===0)?W:K}function ce(Se,dt){for(var Ke,Xe,Qe;;){if(Se.lookahead<k){if(Ge(Se),Se.lookahead<k&&dt===h)return W;if(Se.lookahead===0)break}if(Ke=0,Se.lookahead>=A&&(Se.ins_h=(Se.ins_h<<Se.hash_shift^Se.window[Se.strstart+A-1])&Se.hash_mask,Ke=Se.prev[Se.strstart&Se.w_mask]=Se.head[Se.ins_h],Se.head[Se.ins_h]=Se.strstart),Se.prev_length=Se.match_length,Se.prev_match=Se.match_start,Se.match_length=A-1,Ke!==0&&Se.prev_length<Se.max_lazy_match&&Se.strstart-Ke<=Se.w_size-k&&(Se.match_length=De(Se,Ke),Se.match_length<=5&&(Se.strategy===1||Se.match_length===A&&4096<Se.strstart-Se.match_start)&&(Se.match_length=A-1)),Se.prev_length>=A&&Se.match_length<=Se.prev_length){for(Qe=Se.strstart+Se.lookahead-A,Xe=c._tr_tally(Se,Se.strstart-1-Se.prev_match,Se.prev_length-A),Se.lookahead-=Se.prev_length-1,Se.prev_length-=2;++Se.strstart<=Qe&&(Se.ins_h=(Se.ins_h<<Se.hash_shift^Se.window[Se.strstart+A-1])&Se.hash_mask,Ke=Se.prev[Se.strstart&Se.w_mask]=Se.head[Se.ins_h],Se.head[Se.ins_h]=Se.strstart),--Se.prev_length!=0;);if(Se.match_available=0,Se.match_length=A-1,Se.strstart++,Xe&&(he(Se,!1),Se.strm.avail_out===0))return W}else if(Se.match_available){if((Xe=c._tr_tally(Se,0,Se.window[Se.strstart-1]))&&he(Se,!1),Se.strstart++,Se.lookahead--,Se.strm.avail_out===0)return W}else Se.match_available=1,Se.strstart++,Se.lookahead--}return Se.match_available&&(Xe=c._tr_tally(Se,0,Se.window[Se.strstart-1]),Se.match_available=0),Se.insert=Se.strstart<A-1?Se.strstart:A-1,dt===f?(he(Se,!0),Se.strm.avail_out===0?ee:se):Se.last_lit&&(he(Se,!1),Se.strm.avail_out===0)?W:K}function we(Se,dt,Ke,Xe,Qe){this.good_length=Se,this.max_lazy=dt,this.nice_length=Ke,this.max_chain=Xe,this.func=Qe}function xe(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=w,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new a.Buf16(2*M),this.dyn_dtree=new a.Buf16(2*(2*R+1)),this.bl_tree=new a.Buf16(2*(2*P+1)),re(this.dyn_ltree),re(this.dyn_dtree),re(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new a.Buf16(I+1),this.heap=new a.Buf16(2*N+1),re(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new a.Buf16(2*N+1),re(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function qe(Se){var dt;return Se&&Se.state?(Se.total_in=Se.total_out=0,Se.data_type=v,(dt=Se.state).pending=0,dt.pending_out=0,dt.wrap<0&&(dt.wrap=-dt.wrap),dt.status=dt.wrap?V:X,Se.adler=dt.wrap===2?0:1,dt.last_flush=h,c._tr_init(dt),m):de(Se,y)}function et(Se){var dt=qe(Se);return dt===m&&(function(Ke){Ke.window_size=2*Ke.w_size,re(Ke.head),Ke.max_lazy_match=s[Ke.level].max_lazy,Ke.good_match=s[Ke.level].good_length,Ke.nice_match=s[Ke.level].nice_length,Ke.max_chain_length=s[Ke.level].max_chain,Ke.strstart=0,Ke.block_start=0,Ke.lookahead=0,Ke.insert=0,Ke.match_length=Ke.prev_length=A-1,Ke.match_available=0,Ke.ins_h=0})(Se.state),dt}function ot(Se,dt,Ke,Xe,Qe,He){if(!Se)return y;var Pe=1;if(dt===g&&(dt=6),Xe<0?(Pe=0,Xe=-Xe):15<Xe&&(Pe=2,Xe-=16),Qe<1||T<Qe||Ke!==w||Xe<8||15<Xe||dt<0||9<dt||He<0||b<He)return de(Se,y);Xe===8&&(Xe=9);var Ye=new xe;return(Se.state=Ye).strm=Se,Ye.wrap=Pe,Ye.gzhead=null,Ye.w_bits=Xe,Ye.w_size=1<<Ye.w_bits,Ye.w_mask=Ye.w_size-1,Ye.hash_bits=Qe+7,Ye.hash_size=1<<Ye.hash_bits,Ye.hash_mask=Ye.hash_size-1,Ye.hash_shift=~~((Ye.hash_bits+A-1)/A),Ye.window=new a.Buf8(2*Ye.w_size),Ye.head=new a.Buf16(Ye.hash_size),Ye.prev=new a.Buf16(Ye.w_size),Ye.lit_bufsize=1<<Qe+6,Ye.pending_buf_size=4*Ye.lit_bufsize,Ye.pending_buf=new a.Buf8(Ye.pending_buf_size),Ye.d_buf=1*Ye.lit_bufsize,Ye.l_buf=3*Ye.lit_bufsize,Ye.level=dt,Ye.strategy=He,Ye.method=Ke,et(Se)}s=[new we(0,0,0,0,function(Se,dt){var Ke=65535;for(Ke>Se.pending_buf_size-5&&(Ke=Se.pending_buf_size-5);;){if(Se.lookahead<=1){if(Ge(Se),Se.lookahead===0&&dt===h)return W;if(Se.lookahead===0)break}Se.strstart+=Se.lookahead,Se.lookahead=0;var Xe=Se.block_start+Ke;if((Se.strstart===0||Se.strstart>=Xe)&&(Se.lookahead=Se.strstart-Xe,Se.strstart=Xe,he(Se,!1),Se.strm.avail_out===0)||Se.strstart-Se.block_start>=Se.w_size-k&&(he(Se,!1),Se.strm.avail_out===0))return W}return Se.insert=0,dt===f?(he(Se,!0),Se.strm.avail_out===0?ee:se):(Se.strstart>Se.block_start&&(he(Se,!1),Se.strm.avail_out),W)}),new we(4,4,8,4,ke),new we(4,5,16,8,ke),new we(4,6,32,32,ke),new we(4,4,16,16,ce),new we(8,16,32,32,ce),new we(8,16,128,128,ce),new we(8,32,128,256,ce),new we(32,128,258,1024,ce),new we(32,258,258,4096,ce)],o.deflateInit=function(Se,dt){return ot(Se,dt,w,15,8,0)},o.deflateInit2=ot,o.deflateReset=et,o.deflateResetKeep=qe,o.deflateSetHeader=function(Se,dt){return Se&&Se.state?Se.state.wrap!==2?y:(Se.state.gzhead=dt,m):y},o.deflate=function(Se,dt){var Ke,Xe,Qe,He;if(!Se||!Se.state||5<dt||dt<0)return Se?de(Se,y):y;if(Xe=Se.state,!Se.output||!Se.input&&Se.avail_in!==0||Xe.status===666&&dt!==f)return de(Se,Se.avail_out===0?-5:y);if(Xe.strm=Se,Ke=Xe.last_flush,Xe.last_flush=dt,Xe.status===V)if(Xe.wrap===2)Se.adler=0,Te(Xe,31),Te(Xe,139),Te(Xe,8),Xe.gzhead?(Te(Xe,(Xe.gzhead.text?1:0)+(Xe.gzhead.hcrc?2:0)+(Xe.gzhead.extra?4:0)+(Xe.gzhead.name?8:0)+(Xe.gzhead.comment?16:0)),Te(Xe,255&Xe.gzhead.time),Te(Xe,Xe.gzhead.time>>8&255),Te(Xe,Xe.gzhead.time>>16&255),Te(Xe,Xe.gzhead.time>>24&255),Te(Xe,Xe.level===9?2:2<=Xe.strategy||Xe.level<2?4:0),Te(Xe,255&Xe.gzhead.os),Xe.gzhead.extra&&Xe.gzhead.extra.length&&(Te(Xe,255&Xe.gzhead.extra.length),Te(Xe,Xe.gzhead.extra.length>>8&255)),Xe.gzhead.hcrc&&(Se.adler=u(Se.adler,Xe.pending_buf,Xe.pending,0)),Xe.gzindex=0,Xe.status=69):(Te(Xe,0),Te(Xe,0),Te(Xe,0),Te(Xe,0),Te(Xe,0),Te(Xe,Xe.level===9?2:2<=Xe.strategy||Xe.level<2?4:0),Te(Xe,3),Xe.status=X);else{var Pe=w+(Xe.w_bits-8<<4)<<8;Pe|=(2<=Xe.strategy||Xe.level<2?0:Xe.level<6?1:Xe.level===6?2:3)<<6,Xe.strstart!==0&&(Pe|=32),Pe+=31-Pe%31,Xe.status=X,Ie(Xe,Pe),Xe.strstart!==0&&(Ie(Xe,Se.adler>>>16),Ie(Xe,65535&Se.adler)),Se.adler=1}if(Xe.status===69)if(Xe.gzhead.extra){for(Qe=Xe.pending;Xe.gzindex<(65535&Xe.gzhead.extra.length)&&(Xe.pending!==Xe.pending_buf_size||(Xe.gzhead.hcrc&&Xe.pending>Qe&&(Se.adler=u(Se.adler,Xe.pending_buf,Xe.pending-Qe,Qe)),ue(Se),Qe=Xe.pending,Xe.pending!==Xe.pending_buf_size));)Te(Xe,255&Xe.gzhead.extra[Xe.gzindex]),Xe.gzindex++;Xe.gzhead.hcrc&&Xe.pending>Qe&&(Se.adler=u(Se.adler,Xe.pending_buf,Xe.pending-Qe,Qe)),Xe.gzindex===Xe.gzhead.extra.length&&(Xe.gzindex=0,Xe.status=73)}else Xe.status=73;if(Xe.status===73)if(Xe.gzhead.name){Qe=Xe.pending;do{if(Xe.pending===Xe.pending_buf_size&&(Xe.gzhead.hcrc&&Xe.pending>Qe&&(Se.adler=u(Se.adler,Xe.pending_buf,Xe.pending-Qe,Qe)),ue(Se),Qe=Xe.pending,Xe.pending===Xe.pending_buf_size)){He=1;break}He=Xe.gzindex<Xe.gzhead.name.length?255&Xe.gzhead.name.charCodeAt(Xe.gzindex++):0,Te(Xe,He)}while(He!==0);Xe.gzhead.hcrc&&Xe.pending>Qe&&(Se.adler=u(Se.adler,Xe.pending_buf,Xe.pending-Qe,Qe)),He===0&&(Xe.gzindex=0,Xe.status=91)}else Xe.status=91;if(Xe.status===91)if(Xe.gzhead.comment){Qe=Xe.pending;do{if(Xe.pending===Xe.pending_buf_size&&(Xe.gzhead.hcrc&&Xe.pending>Qe&&(Se.adler=u(Se.adler,Xe.pending_buf,Xe.pending-Qe,Qe)),ue(Se),Qe=Xe.pending,Xe.pending===Xe.pending_buf_size)){He=1;break}He=Xe.gzindex<Xe.gzhead.comment.length?255&Xe.gzhead.comment.charCodeAt(Xe.gzindex++):0,Te(Xe,He)}while(He!==0);Xe.gzhead.hcrc&&Xe.pending>Qe&&(Se.adler=u(Se.adler,Xe.pending_buf,Xe.pending-Qe,Qe)),He===0&&(Xe.status=103)}else Xe.status=103;if(Xe.status===103&&(Xe.gzhead.hcrc?(Xe.pending+2>Xe.pending_buf_size&&ue(Se),Xe.pending+2<=Xe.pending_buf_size&&(Te(Xe,255&Se.adler),Te(Xe,Se.adler>>8&255),Se.adler=0,Xe.status=X)):Xe.status=X),Xe.pending!==0){if(ue(Se),Se.avail_out===0)return Xe.last_flush=-1,m}else if(Se.avail_in===0&&be(dt)<=be(Ke)&&dt!==f)return de(Se,-5);if(Xe.status===666&&Se.avail_in!==0)return de(Se,-5);if(Se.avail_in!==0||Xe.lookahead!==0||dt!==h&&Xe.status!==666){var Ye=Xe.strategy===2?(function(Oe,Ze){for(var nt;;){if(Oe.lookahead===0&&(Ge(Oe),Oe.lookahead===0)){if(Ze===h)return W;break}if(Oe.match_length=0,nt=c._tr_tally(Oe,0,Oe.window[Oe.strstart]),Oe.lookahead--,Oe.strstart++,nt&&(he(Oe,!1),Oe.strm.avail_out===0))return W}return Oe.insert=0,Ze===f?(he(Oe,!0),Oe.strm.avail_out===0?ee:se):Oe.last_lit&&(he(Oe,!1),Oe.strm.avail_out===0)?W:K})(Xe,dt):Xe.strategy===3?(function(Oe,Ze){for(var nt,pt,gt,Et,Nt=Oe.window;;){if(Oe.lookahead<=$){if(Ge(Oe),Oe.lookahead<=$&&Ze===h)return W;if(Oe.lookahead===0)break}if(Oe.match_length=0,Oe.lookahead>=A&&0<Oe.strstart&&(pt=Nt[gt=Oe.strstart-1])===Nt[++gt]&&pt===Nt[++gt]&&pt===Nt[++gt]){Et=Oe.strstart+$;do;while(pt===Nt[++gt]&&pt===Nt[++gt]&&pt===Nt[++gt]&&pt===Nt[++gt]&&pt===Nt[++gt]&&pt===Nt[++gt]&&pt===Nt[++gt]&&pt===Nt[++gt]&&gt<Et);Oe.match_length=$-(Et-gt),Oe.match_length>Oe.lookahead&&(Oe.match_length=Oe.lookahead)}if(Oe.match_length>=A?(nt=c._tr_tally(Oe,1,Oe.match_length-A),Oe.lookahead-=Oe.match_length,Oe.strstart+=Oe.match_length,Oe.match_length=0):(nt=c._tr_tally(Oe,0,Oe.window[Oe.strstart]),Oe.lookahead--,Oe.strstart++),nt&&(he(Oe,!1),Oe.strm.avail_out===0))return W}return Oe.insert=0,Ze===f?(he(Oe,!0),Oe.strm.avail_out===0?ee:se):Oe.last_lit&&(he(Oe,!1),Oe.strm.avail_out===0)?W:K})(Xe,dt):s[Xe.level].func(Xe,dt);if(Ye!==ee&&Ye!==se||(Xe.status=666),Ye===W||Ye===ee)return Se.avail_out===0&&(Xe.last_flush=-1),m;if(Ye===K&&(dt===1?c._tr_align(Xe):dt!==5&&(c._tr_stored_block(Xe,0,0,!1),dt===3&&(re(Xe.head),Xe.lookahead===0&&(Xe.strstart=0,Xe.block_start=0,Xe.insert=0))),ue(Se),Se.avail_out===0))return Xe.last_flush=-1,m}return dt!==f?m:Xe.wrap<=0?1:(Xe.wrap===2?(Te(Xe,255&Se.adler),Te(Xe,Se.adler>>8&255),Te(Xe,Se.adler>>16&255),Te(Xe,Se.adler>>24&255),Te(Xe,255&Se.total_in),Te(Xe,Se.total_in>>8&255),Te(Xe,Se.total_in>>16&255),Te(Xe,Se.total_in>>24&255)):(Ie(Xe,Se.adler>>>16),Ie(Xe,65535&Se.adler)),ue(Se),0<Xe.wrap&&(Xe.wrap=-Xe.wrap),Xe.pending!==0?m:1)},o.deflateEnd=function(Se){var dt;return Se&&Se.state?(dt=Se.state.status)!==V&&dt!==69&&dt!==73&&dt!==91&&dt!==103&&dt!==X&&dt!==666?de(Se,y):(Se.state=null,dt===X?de(Se,-3):m):y},o.deflateSetDictionary=function(Se,dt){var Ke,Xe,Qe,He,Pe,Ye,Oe,Ze,nt=dt.length;if(!Se||!Se.state||(He=(Ke=Se.state).wrap)===2||He===1&&Ke.status!==V||Ke.lookahead)return y;for(He===1&&(Se.adler=l(Se.adler,dt,nt,0)),Ke.wrap=0,nt>=Ke.w_size&&(He===0&&(re(Ke.head),Ke.strstart=0,Ke.block_start=0,Ke.insert=0),Ze=new a.Buf8(Ke.w_size),a.arraySet(Ze,dt,nt-Ke.w_size,Ke.w_size,0),dt=Ze,nt=Ke.w_size),Pe=Se.avail_in,Ye=Se.next_in,Oe=Se.input,Se.avail_in=nt,Se.next_in=0,Se.input=dt,Ge(Ke);Ke.lookahead>=A;){for(Xe=Ke.strstart,Qe=Ke.lookahead-(A-1);Ke.ins_h=(Ke.ins_h<<Ke.hash_shift^Ke.window[Xe+A-1])&Ke.hash_mask,Ke.prev[Xe&Ke.w_mask]=Ke.head[Ke.ins_h],Ke.head[Ke.ins_h]=Xe,Xe++,--Qe;);Ke.strstart=Xe,Ke.lookahead=A-1,Ge(Ke)}return Ke.strstart+=Ke.lookahead,Ke.block_start=Ke.strstart,Ke.insert=Ke.lookahead,Ke.lookahead=0,Ke.match_length=Ke.prev_length=A-1,Ke.match_available=0,Se.next_in=Ye,Se.input=Oe,Se.avail_in=Pe,Ke.wrap=He,m},o.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":41,"./adler32":43,"./crc32":45,"./messages":51,"./trees":52}],47:[function(i,r,o){r.exports=function(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}},{}],48:[function(i,r,o){r.exports=function(s,a){var c,l,u,d,h,f,m,y,g,b,v,w,T,N,R,P,M,I,A,$,k,V,X,W,K;c=s.state,l=s.next_in,W=s.input,u=l+(s.avail_in-5),d=s.next_out,K=s.output,h=d-(a-s.avail_out),f=d+(s.avail_out-257),m=c.dmax,y=c.wsize,g=c.whave,b=c.wnext,v=c.window,w=c.hold,T=c.bits,N=c.lencode,R=c.distcode,P=(1<<c.lenbits)-1,M=(1<<c.distbits)-1;e:do{T<15&&(w+=W[l++]<<T,T+=8,w+=W[l++]<<T,T+=8),I=N[w&P];t:for(;;){if(w>>>=A=I>>>24,T-=A,(A=I>>>16&255)===0)K[d++]=65535&I;else{if(!(16&A)){if((64&A)==0){I=N[(65535&I)+(w&(1<<A)-1)];continue t}if(32&A){c.mode=12;break e}s.msg="invalid literal/length code",c.mode=30;break e}$=65535&I,(A&=15)&&(T<A&&(w+=W[l++]<<T,T+=8),$+=w&(1<<A)-1,w>>>=A,T-=A),T<15&&(w+=W[l++]<<T,T+=8,w+=W[l++]<<T,T+=8),I=R[w&M];n:for(;;){if(w>>>=A=I>>>24,T-=A,!(16&(A=I>>>16&255))){if((64&A)==0){I=R[(65535&I)+(w&(1<<A)-1)];continue n}s.msg="invalid distance code",c.mode=30;break e}if(k=65535&I,T<(A&=15)&&(w+=W[l++]<<T,(T+=8)<A&&(w+=W[l++]<<T,T+=8)),m<(k+=w&(1<<A)-1)){s.msg="invalid distance too far back",c.mode=30;break e}if(w>>>=A,T-=A,(A=d-h)<k){if(g<(A=k-A)&&c.sane){s.msg="invalid distance too far back",c.mode=30;break e}if(X=v,(V=0)===b){if(V+=y-A,A<$){for($-=A;K[d++]=v[V++],--A;);V=d-k,X=K}}else if(b<A){if(V+=y+b-A,(A-=b)<$){for($-=A;K[d++]=v[V++],--A;);if(V=0,b<$){for($-=A=b;K[d++]=v[V++],--A;);V=d-k,X=K}}}else if(V+=b-A,A<$){for($-=A;K[d++]=v[V++],--A;);V=d-k,X=K}for(;2<$;)K[d++]=X[V++],K[d++]=X[V++],K[d++]=X[V++],$-=3;$&&(K[d++]=X[V++],1<$&&(K[d++]=X[V++]))}else{for(V=d-k;K[d++]=K[V++],K[d++]=K[V++],K[d++]=K[V++],2<($-=3););$&&(K[d++]=K[V++],1<$&&(K[d++]=K[V++]))}break}}break}}while(l<u&&d<f);l-=$=T>>3,w&=(1<<(T-=$<<3))-1,s.next_in=l,s.next_out=d,s.avail_in=l<u?u-l+5:5-(l-u),s.avail_out=d<f?f-d+257:257-(d-f),c.hold=w,c.bits=T}},{}],49:[function(i,r,o){var s=i("../utils/common"),a=i("./adler32"),c=i("./crc32"),l=i("./inffast"),u=i("./inftrees"),d=1,h=2,f=0,m=-2,y=1,g=852,b=592;function v(V){return(V>>>24&255)+(V>>>8&65280)+((65280&V)<<8)+((255&V)<<24)}function w(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new s.Buf16(320),this.work=new s.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function T(V){var X;return V&&V.state?(X=V.state,V.total_in=V.total_out=X.total=0,V.msg="",X.wrap&&(V.adler=1&X.wrap),X.mode=y,X.last=0,X.havedict=0,X.dmax=32768,X.head=null,X.hold=0,X.bits=0,X.lencode=X.lendyn=new s.Buf32(g),X.distcode=X.distdyn=new s.Buf32(b),X.sane=1,X.back=-1,f):m}function N(V){var X;return V&&V.state?((X=V.state).wsize=0,X.whave=0,X.wnext=0,T(V)):m}function R(V,X){var W,K;return V&&V.state?(K=V.state,X<0?(W=0,X=-X):(W=1+(X>>4),X<48&&(X&=15)),X&&(X<8||15<X)?m:(K.window!==null&&K.wbits!==X&&(K.window=null),K.wrap=W,K.wbits=X,N(V))):m}function P(V,X){var W,K;return V?(K=new w,(V.state=K).window=null,(W=R(V,X))!==f&&(V.state=null),W):m}var M,I,A=!0;function $(V){if(A){var X;for(M=new s.Buf32(512),I=new s.Buf32(32),X=0;X<144;)V.lens[X++]=8;for(;X<256;)V.lens[X++]=9;for(;X<280;)V.lens[X++]=7;for(;X<288;)V.lens[X++]=8;for(u(d,V.lens,0,288,M,0,V.work,{bits:9}),X=0;X<32;)V.lens[X++]=5;u(h,V.lens,0,32,I,0,V.work,{bits:5}),A=!1}V.lencode=M,V.lenbits=9,V.distcode=I,V.distbits=5}function k(V,X,W,K){var ee,se=V.state;return se.window===null&&(se.wsize=1<<se.wbits,se.wnext=0,se.whave=0,se.window=new s.Buf8(se.wsize)),K>=se.wsize?(s.arraySet(se.window,X,W-se.wsize,se.wsize,0),se.wnext=0,se.whave=se.wsize):(K<(ee=se.wsize-se.wnext)&&(ee=K),s.arraySet(se.window,X,W-K,ee,se.wnext),(K-=ee)?(s.arraySet(se.window,X,W-K,K,0),se.wnext=K,se.whave=se.wsize):(se.wnext+=ee,se.wnext===se.wsize&&(se.wnext=0),se.whave<se.wsize&&(se.whave+=ee))),0}o.inflateReset=N,o.inflateReset2=R,o.inflateResetKeep=T,o.inflateInit=function(V){return P(V,15)},o.inflateInit2=P,o.inflate=function(V,X){var W,K,ee,se,de,be,re,ue,he,Te,Ie,De,Ge,ke,ce,we,xe,qe,et,ot,Se,dt,Ke,Xe,Qe=0,He=new s.Buf8(4),Pe=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!V||!V.state||!V.output||!V.input&&V.avail_in!==0)return m;(W=V.state).mode===12&&(W.mode=13),de=V.next_out,ee=V.output,re=V.avail_out,se=V.next_in,K=V.input,be=V.avail_in,ue=W.hold,he=W.bits,Te=be,Ie=re,dt=f;e:for(;;)switch(W.mode){case y:if(W.wrap===0){W.mode=13;break}for(;he<16;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if(2&W.wrap&&ue===35615){He[W.check=0]=255&ue,He[1]=ue>>>8&255,W.check=c(W.check,He,2,0),he=ue=0,W.mode=2;break}if(W.flags=0,W.head&&(W.head.done=!1),!(1&W.wrap)||(((255&ue)<<8)+(ue>>8))%31){V.msg="incorrect header check",W.mode=30;break}if((15&ue)!=8){V.msg="unknown compression method",W.mode=30;break}if(he-=4,Se=8+(15&(ue>>>=4)),W.wbits===0)W.wbits=Se;else if(Se>W.wbits){V.msg="invalid window size",W.mode=30;break}W.dmax=1<<Se,V.adler=W.check=1,W.mode=512&ue?10:12,he=ue=0;break;case 2:for(;he<16;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if(W.flags=ue,(255&W.flags)!=8){V.msg="unknown compression method",W.mode=30;break}if(57344&W.flags){V.msg="unknown header flags set",W.mode=30;break}W.head&&(W.head.text=ue>>8&1),512&W.flags&&(He[0]=255&ue,He[1]=ue>>>8&255,W.check=c(W.check,He,2,0)),he=ue=0,W.mode=3;case 3:for(;he<32;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}W.head&&(W.head.time=ue),512&W.flags&&(He[0]=255&ue,He[1]=ue>>>8&255,He[2]=ue>>>16&255,He[3]=ue>>>24&255,W.check=c(W.check,He,4,0)),he=ue=0,W.mode=4;case 4:for(;he<16;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}W.head&&(W.head.xflags=255&ue,W.head.os=ue>>8),512&W.flags&&(He[0]=255&ue,He[1]=ue>>>8&255,W.check=c(W.check,He,2,0)),he=ue=0,W.mode=5;case 5:if(1024&W.flags){for(;he<16;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}W.length=ue,W.head&&(W.head.extra_len=ue),512&W.flags&&(He[0]=255&ue,He[1]=ue>>>8&255,W.check=c(W.check,He,2,0)),he=ue=0}else W.head&&(W.head.extra=null);W.mode=6;case 6:if(1024&W.flags&&(be<(De=W.length)&&(De=be),De&&(W.head&&(Se=W.head.extra_len-W.length,W.head.extra||(W.head.extra=new Array(W.head.extra_len)),s.arraySet(W.head.extra,K,se,De,Se)),512&W.flags&&(W.check=c(W.check,K,De,se)),be-=De,se+=De,W.length-=De),W.length))break e;W.length=0,W.mode=7;case 7:if(2048&W.flags){if(be===0)break e;for(De=0;Se=K[se+De++],W.head&&Se&&W.length<65536&&(W.head.name+=String.fromCharCode(Se)),Se&&De<be;);if(512&W.flags&&(W.check=c(W.check,K,De,se)),be-=De,se+=De,Se)break e}else W.head&&(W.head.name=null);W.length=0,W.mode=8;case 8:if(4096&W.flags){if(be===0)break e;for(De=0;Se=K[se+De++],W.head&&Se&&W.length<65536&&(W.head.comment+=String.fromCharCode(Se)),Se&&De<be;);if(512&W.flags&&(W.check=c(W.check,K,De,se)),be-=De,se+=De,Se)break e}else W.head&&(W.head.comment=null);W.mode=9;case 9:if(512&W.flags){for(;he<16;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if(ue!==(65535&W.check)){V.msg="header crc mismatch",W.mode=30;break}he=ue=0}W.head&&(W.head.hcrc=W.flags>>9&1,W.head.done=!0),V.adler=W.check=0,W.mode=12;break;case 10:for(;he<32;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}V.adler=W.check=v(ue),he=ue=0,W.mode=11;case 11:if(W.havedict===0)return V.next_out=de,V.avail_out=re,V.next_in=se,V.avail_in=be,W.hold=ue,W.bits=he,2;V.adler=W.check=1,W.mode=12;case 12:if(X===5||X===6)break e;case 13:if(W.last){ue>>>=7&he,he-=7&he,W.mode=27;break}for(;he<3;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}switch(W.last=1&ue,he-=1,3&(ue>>>=1)){case 0:W.mode=14;break;case 1:if($(W),W.mode=20,X!==6)break;ue>>>=2,he-=2;break e;case 2:W.mode=17;break;case 3:V.msg="invalid block type",W.mode=30}ue>>>=2,he-=2;break;case 14:for(ue>>>=7&he,he-=7&he;he<32;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if((65535&ue)!=(ue>>>16^65535)){V.msg="invalid stored block lengths",W.mode=30;break}if(W.length=65535&ue,he=ue=0,W.mode=15,X===6)break e;case 15:W.mode=16;case 16:if(De=W.length){if(be<De&&(De=be),re<De&&(De=re),De===0)break e;s.arraySet(ee,K,se,De,de),be-=De,se+=De,re-=De,de+=De,W.length-=De;break}W.mode=12;break;case 17:for(;he<14;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if(W.nlen=257+(31&ue),ue>>>=5,he-=5,W.ndist=1+(31&ue),ue>>>=5,he-=5,W.ncode=4+(15&ue),ue>>>=4,he-=4,286<W.nlen||30<W.ndist){V.msg="too many length or distance symbols",W.mode=30;break}W.have=0,W.mode=18;case 18:for(;W.have<W.ncode;){for(;he<3;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}W.lens[Pe[W.have++]]=7&ue,ue>>>=3,he-=3}for(;W.have<19;)W.lens[Pe[W.have++]]=0;if(W.lencode=W.lendyn,W.lenbits=7,Ke={bits:W.lenbits},dt=u(0,W.lens,0,19,W.lencode,0,W.work,Ke),W.lenbits=Ke.bits,dt){V.msg="invalid code lengths set",W.mode=30;break}W.have=0,W.mode=19;case 19:for(;W.have<W.nlen+W.ndist;){for(;we=(Qe=W.lencode[ue&(1<<W.lenbits)-1])>>>16&255,xe=65535&Qe,!((ce=Qe>>>24)<=he);){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if(xe<16)ue>>>=ce,he-=ce,W.lens[W.have++]=xe;else{if(xe===16){for(Xe=ce+2;he<Xe;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if(ue>>>=ce,he-=ce,W.have===0){V.msg="invalid bit length repeat",W.mode=30;break}Se=W.lens[W.have-1],De=3+(3&ue),ue>>>=2,he-=2}else if(xe===17){for(Xe=ce+3;he<Xe;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}he-=ce,Se=0,De=3+(7&(ue>>>=ce)),ue>>>=3,he-=3}else{for(Xe=ce+7;he<Xe;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}he-=ce,Se=0,De=11+(127&(ue>>>=ce)),ue>>>=7,he-=7}if(W.have+De>W.nlen+W.ndist){V.msg="invalid bit length repeat",W.mode=30;break}for(;De--;)W.lens[W.have++]=Se}}if(W.mode===30)break;if(W.lens[256]===0){V.msg="invalid code -- missing end-of-block",W.mode=30;break}if(W.lenbits=9,Ke={bits:W.lenbits},dt=u(d,W.lens,0,W.nlen,W.lencode,0,W.work,Ke),W.lenbits=Ke.bits,dt){V.msg="invalid literal/lengths set",W.mode=30;break}if(W.distbits=6,W.distcode=W.distdyn,Ke={bits:W.distbits},dt=u(h,W.lens,W.nlen,W.ndist,W.distcode,0,W.work,Ke),W.distbits=Ke.bits,dt){V.msg="invalid distances set",W.mode=30;break}if(W.mode=20,X===6)break e;case 20:W.mode=21;case 21:if(6<=be&&258<=re){V.next_out=de,V.avail_out=re,V.next_in=se,V.avail_in=be,W.hold=ue,W.bits=he,l(V,Ie),de=V.next_out,ee=V.output,re=V.avail_out,se=V.next_in,K=V.input,be=V.avail_in,ue=W.hold,he=W.bits,W.mode===12&&(W.back=-1);break}for(W.back=0;we=(Qe=W.lencode[ue&(1<<W.lenbits)-1])>>>16&255,xe=65535&Qe,!((ce=Qe>>>24)<=he);){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if(we&&(240&we)==0){for(qe=ce,et=we,ot=xe;we=(Qe=W.lencode[ot+((ue&(1<<qe+et)-1)>>qe)])>>>16&255,xe=65535&Qe,!(qe+(ce=Qe>>>24)<=he);){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}ue>>>=qe,he-=qe,W.back+=qe}if(ue>>>=ce,he-=ce,W.back+=ce,W.length=xe,we===0){W.mode=26;break}if(32&we){W.back=-1,W.mode=12;break}if(64&we){V.msg="invalid literal/length code",W.mode=30;break}W.extra=15&we,W.mode=22;case 22:if(W.extra){for(Xe=W.extra;he<Xe;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}W.length+=ue&(1<<W.extra)-1,ue>>>=W.extra,he-=W.extra,W.back+=W.extra}W.was=W.length,W.mode=23;case 23:for(;we=(Qe=W.distcode[ue&(1<<W.distbits)-1])>>>16&255,xe=65535&Qe,!((ce=Qe>>>24)<=he);){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if((240&we)==0){for(qe=ce,et=we,ot=xe;we=(Qe=W.distcode[ot+((ue&(1<<qe+et)-1)>>qe)])>>>16&255,xe=65535&Qe,!(qe+(ce=Qe>>>24)<=he);){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}ue>>>=qe,he-=qe,W.back+=qe}if(ue>>>=ce,he-=ce,W.back+=ce,64&we){V.msg="invalid distance code",W.mode=30;break}W.offset=xe,W.extra=15&we,W.mode=24;case 24:if(W.extra){for(Xe=W.extra;he<Xe;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}W.offset+=ue&(1<<W.extra)-1,ue>>>=W.extra,he-=W.extra,W.back+=W.extra}if(W.offset>W.dmax){V.msg="invalid distance too far back",W.mode=30;break}W.mode=25;case 25:if(re===0)break e;if(De=Ie-re,W.offset>De){if((De=W.offset-De)>W.whave&&W.sane){V.msg="invalid distance too far back",W.mode=30;break}Ge=De>W.wnext?(De-=W.wnext,W.wsize-De):W.wnext-De,De>W.length&&(De=W.length),ke=W.window}else ke=ee,Ge=de-W.offset,De=W.length;for(re<De&&(De=re),re-=De,W.length-=De;ee[de++]=ke[Ge++],--De;);W.length===0&&(W.mode=21);break;case 26:if(re===0)break e;ee[de++]=W.length,re--,W.mode=21;break;case 27:if(W.wrap){for(;he<32;){if(be===0)break e;be--,ue|=K[se++]<<he,he+=8}if(Ie-=re,V.total_out+=Ie,W.total+=Ie,Ie&&(V.adler=W.check=W.flags?c(W.check,ee,Ie,de-Ie):a(W.check,ee,Ie,de-Ie)),Ie=re,(W.flags?ue:v(ue))!==W.check){V.msg="incorrect data check",W.mode=30;break}he=ue=0}W.mode=28;case 28:if(W.wrap&&W.flags){for(;he<32;){if(be===0)break e;be--,ue+=K[se++]<<he,he+=8}if(ue!==(4294967295&W.total)){V.msg="incorrect length check",W.mode=30;break}he=ue=0}W.mode=29;case 29:dt=1;break e;case 30:dt=-3;break e;case 31:return-4;case 32:default:return m}return V.next_out=de,V.avail_out=re,V.next_in=se,V.avail_in=be,W.hold=ue,W.bits=he,(W.wsize||Ie!==V.avail_out&&W.mode<30&&(W.mode<27||X!==4))&&k(V,V.output,V.next_out,Ie-V.avail_out)?(W.mode=31,-4):(Te-=V.avail_in,Ie-=V.avail_out,V.total_in+=Te,V.total_out+=Ie,W.total+=Ie,W.wrap&&Ie&&(V.adler=W.check=W.flags?c(W.check,ee,Ie,V.next_out-Ie):a(W.check,ee,Ie,V.next_out-Ie)),V.data_type=W.bits+(W.last?64:0)+(W.mode===12?128:0)+(W.mode===20||W.mode===15?256:0),(Te==0&&Ie===0||X===4)&&dt===f&&(dt=-5),dt)},o.inflateEnd=function(V){if(!V||!V.state)return m;var X=V.state;return X.window&&(X.window=null),V.state=null,f},o.inflateGetHeader=function(V,X){var W;return V&&V.state?(2&(W=V.state).wrap)==0?m:((W.head=X).done=!1,f):m},o.inflateSetDictionary=function(V,X){var W,K=X.length;return V&&V.state?(W=V.state).wrap!==0&&W.mode!==11?m:W.mode===11&&a(1,X,K,0)!==W.check?-3:k(V,X,K,K)?(W.mode=31,-4):(W.havedict=1,f):m},o.inflateInfo="pako inflate (from Nodeca project)"},{"../utils/common":41,"./adler32":43,"./crc32":45,"./inffast":48,"./inftrees":50}],50:[function(i,r,o){var s=i("../utils/common"),a=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],c=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],l=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],u=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];r.exports=function(d,h,f,m,y,g,b,v){var w,T,N,R,P,M,I,A,$,k=v.bits,V=0,X=0,W=0,K=0,ee=0,se=0,de=0,be=0,re=0,ue=0,he=null,Te=0,Ie=new s.Buf16(16),De=new s.Buf16(16),Ge=null,ke=0;for(V=0;V<=15;V++)Ie[V]=0;for(X=0;X<m;X++)Ie[h[f+X]]++;for(ee=k,K=15;1<=K&&Ie[K]===0;K--);if(K<ee&&(ee=K),K===0)return y[g++]=20971520,y[g++]=20971520,v.bits=1,0;for(W=1;W<K&&Ie[W]===0;W++);for(ee<W&&(ee=W),V=be=1;V<=15;V++)if(be<<=1,(be-=Ie[V])<0)return-1;if(0<be&&(d===0||K!==1))return-1;for(De[1]=0,V=1;V<15;V++)De[V+1]=De[V]+Ie[V];for(X=0;X<m;X++)h[f+X]!==0&&(b[De[h[f+X]]++]=X);if(M=d===0?(he=Ge=b,19):d===1?(he=a,Te-=257,Ge=c,ke-=257,256):(he=l,Ge=u,-1),V=W,P=g,de=X=ue=0,N=-1,R=(re=1<<(se=ee))-1,d===1&&852<re||d===2&&592<re)return 1;for(;;){for(I=V-de,$=b[X]<M?(A=0,b[X]):b[X]>M?(A=Ge[ke+b[X]],he[Te+b[X]]):(A=96,0),w=1<<V-de,W=T=1<<se;y[P+(ue>>de)+(T-=w)]=I<<24|A<<16|$|0,T!==0;);for(w=1<<V-1;ue&w;)w>>=1;if(w!==0?(ue&=w-1,ue+=w):ue=0,X++,--Ie[V]==0){if(V===K)break;V=h[f+b[X]]}if(ee<V&&(ue&R)!==N){for(de===0&&(de=ee),P+=W,be=1<<(se=V-de);se+de<K&&!((be-=Ie[se+de])<=0);)se++,be<<=1;if(re+=1<<se,d===1&&852<re||d===2&&592<re)return 1;y[N=ue&R]=ee<<24|se<<16|P-g|0}}return ue!==0&&(y[P+ue]=V-de<<24|64<<16|0),v.bits=ee,0}},{"../utils/common":41}],51:[function(i,r,o){r.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],52:[function(i,r,o){var s=i("../utils/common"),a=0,c=1;function l(Qe){for(var He=Qe.length;0<=--He;)Qe[He]=0}var u=0,d=29,h=256,f=h+1+d,m=30,y=19,g=2*f+1,b=15,v=16,w=7,T=256,N=16,R=17,P=18,M=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],I=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],A=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],$=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],k=new Array(2*(f+2));l(k);var V=new Array(2*m);l(V);var X=new Array(512);l(X);var W=new Array(256);l(W);var K=new Array(d);l(K);var ee,se,de,be=new Array(m);function re(Qe,He,Pe,Ye,Oe){this.static_tree=Qe,this.extra_bits=He,this.extra_base=Pe,this.elems=Ye,this.max_length=Oe,this.has_stree=Qe&&Qe.length}function ue(Qe,He){this.dyn_tree=Qe,this.max_code=0,this.stat_desc=He}function he(Qe){return Qe<256?X[Qe]:X[256+(Qe>>>7)]}function Te(Qe,He){Qe.pending_buf[Qe.pending++]=255&He,Qe.pending_buf[Qe.pending++]=He>>>8&255}function Ie(Qe,He,Pe){Qe.bi_valid>v-Pe?(Qe.bi_buf|=He<<Qe.bi_valid&65535,Te(Qe,Qe.bi_buf),Qe.bi_buf=He>>v-Qe.bi_valid,Qe.bi_valid+=Pe-v):(Qe.bi_buf|=He<<Qe.bi_valid&65535,Qe.bi_valid+=Pe)}function De(Qe,He,Pe){Ie(Qe,Pe[2*He],Pe[2*He+1])}function Ge(Qe,He){for(var Pe=0;Pe|=1&Qe,Qe>>>=1,Pe<<=1,0<--He;);return Pe>>>1}function ke(Qe,He,Pe){var Ye,Oe,Ze=new Array(b+1),nt=0;for(Ye=1;Ye<=b;Ye++)Ze[Ye]=nt=nt+Pe[Ye-1]<<1;for(Oe=0;Oe<=He;Oe++){var pt=Qe[2*Oe+1];pt!==0&&(Qe[2*Oe]=Ge(Ze[pt]++,pt))}}function ce(Qe){var He;for(He=0;He<f;He++)Qe.dyn_ltree[2*He]=0;for(He=0;He<m;He++)Qe.dyn_dtree[2*He]=0;for(He=0;He<y;He++)Qe.bl_tree[2*He]=0;Qe.dyn_ltree[2*T]=1,Qe.opt_len=Qe.static_len=0,Qe.last_lit=Qe.matches=0}function we(Qe){8<Qe.bi_valid?Te(Qe,Qe.bi_buf):0<Qe.bi_valid&&(Qe.pending_buf[Qe.pending++]=Qe.bi_buf),Qe.bi_buf=0,Qe.bi_valid=0}function xe(Qe,He,Pe,Ye){var Oe=2*He,Ze=2*Pe;return Qe[Oe]<Qe[Ze]||Qe[Oe]===Qe[Ze]&&Ye[He]<=Ye[Pe]}function qe(Qe,He,Pe){for(var Ye=Qe.heap[Pe],Oe=Pe<<1;Oe<=Qe.heap_len&&(Oe<Qe.heap_len&&xe(He,Qe.heap[Oe+1],Qe.heap[Oe],Qe.depth)&&Oe++,!xe(He,Ye,Qe.heap[Oe],Qe.depth));)Qe.heap[Pe]=Qe.heap[Oe],Pe=Oe,Oe<<=1;Qe.heap[Pe]=Ye}function et(Qe,He,Pe){var Ye,Oe,Ze,nt,pt=0;if(Qe.last_lit!==0)for(;Ye=Qe.pending_buf[Qe.d_buf+2*pt]<<8|Qe.pending_buf[Qe.d_buf+2*pt+1],Oe=Qe.pending_buf[Qe.l_buf+pt],pt++,Ye===0?De(Qe,Oe,He):(De(Qe,(Ze=W[Oe])+h+1,He),(nt=M[Ze])!==0&&Ie(Qe,Oe-=K[Ze],nt),De(Qe,Ze=he(--Ye),Pe),(nt=I[Ze])!==0&&Ie(Qe,Ye-=be[Ze],nt)),pt<Qe.last_lit;);De(Qe,T,He)}function ot(Qe,He){var Pe,Ye,Oe,Ze=He.dyn_tree,nt=He.stat_desc.static_tree,pt=He.stat_desc.has_stree,gt=He.stat_desc.elems,Et=-1;for(Qe.heap_len=0,Qe.heap_max=g,Pe=0;Pe<gt;Pe++)Ze[2*Pe]!==0?(Qe.heap[++Qe.heap_len]=Et=Pe,Qe.depth[Pe]=0):Ze[2*Pe+1]=0;for(;Qe.heap_len<2;)Ze[2*(Oe=Qe.heap[++Qe.heap_len]=Et<2?++Et:0)]=1,Qe.depth[Oe]=0,Qe.opt_len--,pt&&(Qe.static_len-=nt[2*Oe+1]);for(He.max_code=Et,Pe=Qe.heap_len>>1;1<=Pe;Pe--)qe(Qe,Ze,Pe);for(Oe=gt;Pe=Qe.heap[1],Qe.heap[1]=Qe.heap[Qe.heap_len--],qe(Qe,Ze,1),Ye=Qe.heap[1],Qe.heap[--Qe.heap_max]=Pe,Qe.heap[--Qe.heap_max]=Ye,Ze[2*Oe]=Ze[2*Pe]+Ze[2*Ye],Qe.depth[Oe]=(Qe.depth[Pe]>=Qe.depth[Ye]?Qe.depth[Pe]:Qe.depth[Ye])+1,Ze[2*Pe+1]=Ze[2*Ye+1]=Oe,Qe.heap[1]=Oe++,qe(Qe,Ze,1),2<=Qe.heap_len;);Qe.heap[--Qe.heap_max]=Qe.heap[1],(function(Nt,xt){var $t,Zt,hn,en,ln,En,rt=xt.dyn_tree,pe=xt.max_code,We=xt.stat_desc.static_tree,ut=xt.stat_desc.has_stree,vt=xt.stat_desc.extra_bits,Bt=xt.stat_desc.extra_base,Ht=xt.stat_desc.max_length,cn=0;for(en=0;en<=b;en++)Nt.bl_count[en]=0;for(rt[2*Nt.heap[Nt.heap_max]+1]=0,$t=Nt.heap_max+1;$t<g;$t++)Ht<(en=rt[2*rt[2*(Zt=Nt.heap[$t])+1]+1]+1)&&(en=Ht,cn++),rt[2*Zt+1]=en,pe<Zt||(Nt.bl_count[en]++,ln=0,Bt<=Zt&&(ln=vt[Zt-Bt]),En=rt[2*Zt],Nt.opt_len+=En*(en+ln),ut&&(Nt.static_len+=En*(We[2*Zt+1]+ln)));if(cn!==0){do{for(en=Ht-1;Nt.bl_count[en]===0;)en--;Nt.bl_count[en]--,Nt.bl_count[en+1]+=2,Nt.bl_count[Ht]--,cn-=2}while(0<cn);for(en=Ht;en!==0;en--)for(Zt=Nt.bl_count[en];Zt!==0;)pe<(hn=Nt.heap[--$t])||(rt[2*hn+1]!==en&&(Nt.opt_len+=(en-rt[2*hn+1])*rt[2*hn],rt[2*hn+1]=en),Zt--)}})(Qe,He),ke(Ze,Et,Qe.bl_count)}function Se(Qe,He,Pe){var Ye,Oe,Ze=-1,nt=He[1],pt=0,gt=7,Et=4;for(nt===0&&(gt=138,Et=3),He[2*(Pe+1)+1]=65535,Ye=0;Ye<=Pe;Ye++)Oe=nt,nt=He[2*(Ye+1)+1],++pt<gt&&Oe===nt||(pt<Et?Qe.bl_tree[2*Oe]+=pt:Oe!==0?(Oe!==Ze&&Qe.bl_tree[2*Oe]++,Qe.bl_tree[2*N]++):pt<=10?Qe.bl_tree[2*R]++:Qe.bl_tree[2*P]++,Ze=Oe,Et=(pt=0)===nt?(gt=138,3):Oe===nt?(gt=6,3):(gt=7,4))}function dt(Qe,He,Pe){var Ye,Oe,Ze=-1,nt=He[1],pt=0,gt=7,Et=4;for(nt===0&&(gt=138,Et=3),Ye=0;Ye<=Pe;Ye++)if(Oe=nt,nt=He[2*(Ye+1)+1],!(++pt<gt&&Oe===nt)){if(pt<Et)for(;De(Qe,Oe,Qe.bl_tree),--pt!=0;);else Oe!==0?(Oe!==Ze&&(De(Qe,Oe,Qe.bl_tree),pt--),De(Qe,N,Qe.bl_tree),Ie(Qe,pt-3,2)):pt<=10?(De(Qe,R,Qe.bl_tree),Ie(Qe,pt-3,3)):(De(Qe,P,Qe.bl_tree),Ie(Qe,pt-11,7));Ze=Oe,Et=(pt=0)===nt?(gt=138,3):Oe===nt?(gt=6,3):(gt=7,4)}}l(be);var Ke=!1;function Xe(Qe,He,Pe,Ye){Ie(Qe,(u<<1)+(Ye?1:0),3),(function(Oe,Ze,nt,pt){we(Oe),Te(Oe,nt),Te(Oe,~nt),s.arraySet(Oe.pending_buf,Oe.window,Ze,nt,Oe.pending),Oe.pending+=nt})(Qe,He,Pe)}o._tr_init=function(Qe){Ke||((function(){var He,Pe,Ye,Oe,Ze,nt=new Array(b+1);for(Oe=Ye=0;Oe<d-1;Oe++)for(K[Oe]=Ye,He=0;He<1<<M[Oe];He++)W[Ye++]=Oe;for(W[Ye-1]=Oe,Oe=Ze=0;Oe<16;Oe++)for(be[Oe]=Ze,He=0;He<1<<I[Oe];He++)X[Ze++]=Oe;for(Ze>>=7;Oe<m;Oe++)for(be[Oe]=Ze<<7,He=0;He<1<<I[Oe]-7;He++)X[256+Ze++]=Oe;for(Pe=0;Pe<=b;Pe++)nt[Pe]=0;for(He=0;He<=143;)k[2*He+1]=8,He++,nt[8]++;for(;He<=255;)k[2*He+1]=9,He++,nt[9]++;for(;He<=279;)k[2*He+1]=7,He++,nt[7]++;for(;He<=287;)k[2*He+1]=8,He++,nt[8]++;for(ke(k,f+1,nt),He=0;He<m;He++)V[2*He+1]=5,V[2*He]=Ge(He,5);ee=new re(k,M,h+1,f,b),se=new re(V,I,0,m,b),de=new re(new Array(0),A,0,y,w)})(),Ke=!0),Qe.l_desc=new ue(Qe.dyn_ltree,ee),Qe.d_desc=new ue(Qe.dyn_dtree,se),Qe.bl_desc=new ue(Qe.bl_tree,de),Qe.bi_buf=0,Qe.bi_valid=0,ce(Qe)},o._tr_stored_block=Xe,o._tr_flush_block=function(Qe,He,Pe,Ye){var Oe,Ze,nt=0;0<Qe.level?(Qe.strm.data_type===2&&(Qe.strm.data_type=(function(pt){var gt,Et=4093624447;for(gt=0;gt<=31;gt++,Et>>>=1)if(1&Et&&pt.dyn_ltree[2*gt]!==0)return a;if(pt.dyn_ltree[18]!==0||pt.dyn_ltree[20]!==0||pt.dyn_ltree[26]!==0)return c;for(gt=32;gt<h;gt++)if(pt.dyn_ltree[2*gt]!==0)return c;return a})(Qe)),ot(Qe,Qe.l_desc),ot(Qe,Qe.d_desc),nt=(function(pt){var gt;for(Se(pt,pt.dyn_ltree,pt.l_desc.max_code),Se(pt,pt.dyn_dtree,pt.d_desc.max_code),ot(pt,pt.bl_desc),gt=y-1;3<=gt&&pt.bl_tree[2*$[gt]+1]===0;gt--);return pt.opt_len+=3*(gt+1)+5+5+4,gt})(Qe),Oe=Qe.opt_len+3+7>>>3,(Ze=Qe.static_len+3+7>>>3)<=Oe&&(Oe=Ze)):Oe=Ze=Pe+5,Pe+4<=Oe&&He!==-1?Xe(Qe,He,Pe,Ye):Qe.strategy===4||Ze===Oe?(Ie(Qe,2+(Ye?1:0),3),et(Qe,k,V)):(Ie(Qe,4+(Ye?1:0),3),(function(pt,gt,Et,Nt){var xt;for(Ie(pt,gt-257,5),Ie(pt,Et-1,5),Ie(pt,Nt-4,4),xt=0;xt<Nt;xt++)Ie(pt,pt.bl_tree[2*$[xt]+1],3);dt(pt,pt.dyn_ltree,gt-1),dt(pt,pt.dyn_dtree,Et-1)})(Qe,Qe.l_desc.max_code+1,Qe.d_desc.max_code+1,nt+1),et(Qe,Qe.dyn_ltree,Qe.dyn_dtree)),ce(Qe),Ye&&we(Qe)},o._tr_tally=function(Qe,He,Pe){return Qe.pending_buf[Qe.d_buf+2*Qe.last_lit]=He>>>8&255,Qe.pending_buf[Qe.d_buf+2*Qe.last_lit+1]=255&He,Qe.pending_buf[Qe.l_buf+Qe.last_lit]=255&Pe,Qe.last_lit++,He===0?Qe.dyn_ltree[2*Pe]++:(Qe.matches++,He--,Qe.dyn_ltree[2*(W[Pe]+h+1)]++,Qe.dyn_dtree[2*he(He)]++),Qe.last_lit===Qe.lit_bufsize-1},o._tr_align=function(Qe){Ie(Qe,2,3),De(Qe,T,k),(function(He){He.bi_valid===16?(Te(He,He.bi_buf),He.bi_buf=0,He.bi_valid=0):8<=He.bi_valid&&(He.pending_buf[He.pending++]=255&He.bi_buf,He.bi_buf>>=8,He.bi_valid-=8)})(Qe)}},{"../utils/common":41}],53:[function(i,r,o){r.exports=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}},{}],54:[function(i,r,o){(function(s){(function(a,c){if(!a.setImmediate){var l,u,d,h,f=1,m={},y=!1,g=a.document,b=Object.getPrototypeOf&&Object.getPrototypeOf(a);b=b&&b.setTimeout?b:a,l={}.toString.call(a.process)==="[object process]"?function(N){n.nextTick(function(){w(N)})}:(function(){if(a.postMessage&&!a.importScripts){var N=!0,R=a.onmessage;return a.onmessage=function(){N=!1},a.postMessage("","*"),a.onmessage=R,N}})()?(h="setImmediate$"+Math.random()+"$",a.addEventListener?a.addEventListener("message",T,!1):a.attachEvent("onmessage",T),function(N){a.postMessage(h+N,"*")}):a.MessageChannel?((d=new MessageChannel).port1.onmessage=function(N){w(N.data)},function(N){d.port2.postMessage(N)}):g&&"onreadystatechange"in g.createElement("script")?(u=g.documentElement,function(N){var R=g.createElement("script");R.onreadystatechange=function(){w(N),R.onreadystatechange=null,u.removeChild(R),R=null},u.appendChild(R)}):function(N){setTimeout(w,0,N)},b.setImmediate=function(N){typeof N!="function"&&(N=new Function(""+N));for(var R=new Array(arguments.length-1),P=0;P<R.length;P++)R[P]=arguments[P+1];var M={callback:N,args:R};return m[f]=M,l(f),f++},b.clearImmediate=v}function v(N){delete m[N]}function w(N){if(y)setTimeout(w,0,N);else{var R=m[N];if(R){y=!0;try{(function(P){var M=P.callback,I=P.args;switch(I.length){case 0:M();break;case 1:M(I[0]);break;case 2:M(I[0],I[1]);break;case 3:M(I[0],I[1],I[2]);break;default:M.apply(c,I)}})(R)}finally{v(N),y=!1}}}}function T(N){N.source===a&&typeof N.data=="string"&&N.data.indexOf(h)===0&&w(+N.data.slice(h.length))}})(typeof self>"u"?s===void 0?this:s:self)}).call(this,typeof FO<"u"?FO:typeof self<"u"?self:typeof window<"u"?window:{})},{}]},{},[10])(10)})})(C2e)),C2e.exports}var dZn=uZn();const hZn=u2(dZn);var R2e,lft;function pZn(){return lft||(lft=1,R2e=function(t,e){e||(e={}),typeof e=="function"&&(e={cmp:e});var n=typeof e.cycles=="boolean"?e.cycles:!1,i=e.cmp&&(function(o){return function(s){return function(a,c){var l={key:a,value:s[a]},u={key:c,value:s[c]};return o(l,u)}}})(e.cmp),r=[];return(function o(s){if(s&&s.toJSON&&typeof s.toJSON=="function"&&(s=s.toJSON()),s!==void 0){if(typeof s=="number")return isFinite(s)?""+s:"null";if(typeof s!="object")return JSON.stringify(s);var a,c;if(Array.isArray(s)){for(c="[",a=0;a<s.length;a++)a&&(c+=","),c+=o(s[a])||"null";return c+"]"}if(s===null)return"null";if(r.indexOf(s)!==-1){if(n)return JSON.stringify("__cycle__");throw new TypeError("Converting circular structure to JSON")}var l=r.push(s)-1,u=Object.keys(s).sort(i&&i(s));for(c="",a=0;a<u.length;a++){var d=u[a],h=o(s[d]);h&&(c&&(c+=","),c+=JSON.stringify(d)+":"+h)}return r.splice(l,1),"{"+c+"}"}})(t)}),R2e}var fZn=pZn();const mZn=u2(fZn);var uft={0:"M0.4544564813877358 0L0.2723441540828736 0.03592830447352719L0.1086847233315459 0.14528754990019965L0.020630545837255005 0.3040632652221331L0 0.5395277421960205L0.049259221760993496 0.7369487828466779L0.18080513776237842 0.9005494166306564L0.37036887043974215 0.9872116270037247L0.5864663759301132 1L0.8148695622827444 0.9332890276148733L0.9326583645506394 0.8113052246023419L1 0.4031281830668562L0.833288960385582 0.09886798567812842L0.6801767918233781 0.02483708485091681L0.4544564813877358 0",1:"M 0.198 0.272 L 0.537 0 L 0.54 1",2:"M0.069593147751606 0.19461498231706575L0.1039380353319058 0.1224291500164194L0.20543361884368308 0.05510832064153169L0.3717712794432549 0.009452970962689482L0.4785344452623127 0L0.663238590738758 0.008714098643339864L0.8017933618843684 0.04769189395915288L0.8775637379550322 0.10746757678258442L0.9047778372591005 0.17693069668193287L0.9029710920770878 0.2231347105796246L0.8704496788008566 0.30047744598157516L0.7292906538577354 0.4508486051631194L0.3737955032119913 0.7369006417749693L0 1L1 1",3:"M0.03917438899874637 0.19855364635107545L0.15510940508963084 0.06745632622133718L0.37598645522339846 0L0.8486391893813088 0.0652271323161611L0.9782182415054349 0.21747394183735683L0.9213133780517754 0.3547560290117714L0.6504271515903481 0.4543436297681271L0.22975249764129613 0.48476611625264143L0.7659038682744629 0.5411919558122493L0.9258712987734741 0.6203185665660985L1 0.7458360609169667L0.8938813281118737 0.9059190913045964L0.6166890258875837 1L0.261528440153542 0.9874861530507921L0 0.8837289530851273",4:"M0.7328897338403042 0L0 0.6684672518568535L1 0.6684672518568535M0.7243346007604563 0.4530722484807562L0.7243346007604563 1",5:"M 0 0 L 0 0.4973 L 0.4262 0.4319 L 0.7305 0.4565 L 0.8516 0.5009 L 0.9357 0.5639 L 1 0.7356 L 0.9696 0.8248 L 0.8898 0.895 L 0.733 0.9602 L 0.5518 0.9945 L 0.3814 1 L 0.2379 0.9821 L 0.1219 0.947 L 0 0.8748 M 0 0 L 1 0",6:"M0.6964601700926856 0L0.3639239026215478 0.0743562375769351L0.1415931962925719 0.21735490179786915L0.009977939399608712 0.46336322325406004L0.00029622007592593224 0.7083131475173043L0.09408885043224748 0.8746809149767036L0.3379247445101846 0.9876686500961888L0.7109203869569624 1L0.9260852957913362 0.9103558029693921L1 0.7716571969091733L0.9824294723385016 0.6390635485705886L0.7446504992867332 0.4733643097729175L0.31028858071607296 0.47578021640899115L0.1208702146816024 0.5481452483973847L0 0.6616669755788906",7:"M0 0L1 0L0.9246479649697582 0.030539772727272752L0.8850302419354837 0.05075757575757579L0.7922946068548385 0.11079545454545457L0.7419268208165322 0.15213068181818185L0.6907258064516127 0.20202020202020204L0.6400666267641127 0.26122159090909086L0.5913243447580644 0.33049242424242414L0.5458740234374998 0.4105902777777778L0.5050907258064514 0.5022727272727272L0.4703495148689514 0.6062973484848484L0.43257456133442534 0.787133049242424L0.41612903225806447 1",8:"M0.5143001078924863 0L0.16007477667923162 0.10731570786949331L0.14924628550868277 0.3146018498698755L0.2939585848842112 0.41617921794558677L0.8648302624811545 0.5385163833653317L1 0.7775820770511038L0.8180842915260376 0.9505845566922285L0.41968938540525413 1L0.08062381919779889 0.882831681184498L0 0.6936376947135333L0.17150171673893433 0.5188652309607817L0.6529263782780712 0.4242818653203618L0.8650205888491803 0.29644027376796367L0.8702067371119496 0.09910067291661573L0.5143001078924863 0",9:"M1 0.25379591792994305L0.9514789771111742 0.11679361536614272L0.8702482473521467 0.05711741614054847L0.7327445265851579 0.015213872471965633L0.525248180711544 0L0.3292056884418538 0.012928195113745608L0.15997632037247655 0.058762870026191856L0.05266940041228321 0.12882439350476L0 0.2562067822770946L0.11316462894512366 0.4121335905917837L0.2403060136479954 0.4603365890068938L0.4097241967586011 0.4745978388276783L0.8642414300184816 0.420815170259988L0.9732054796346318 0.34537434075898393L1 0.25379591792994305M0.9647426784191072 0.35488595400360495L0.4756895081034974 1",A:"M0 1L0.4808333333333333 0L1 1M0.24250000000000002 0.6099439775910365L0.7341666666666666 0.6099439775910365",B:"M0 1L0 0.0117369978777208L0.30665717153513444 0L0.5874522807082946 0.03451403469442413L0.7766202217193218 0.15033936404895643L0.7471969743588041 0.31967962568332936L0.5246013359741988 0.4102978954282461L0.04378745314885416 0.44918617613783574L0.5112949594180156 0.469692928091109L0.8540266515643348 0.5552749498651879L1 0.6868463175009967L0.9880091196159324 0.8570018204672155L0.922301719975498 0.9321708046604659L0.7584266951758925 0.9932594737131338L0 1",C:"M1 0.23038928858890784L0.9328355511865092 0.12426412616785204L0.8096380839483327 0.04912601676267708L0.5763225801788256 0L0.4039037709527492 0.015028068281399815L0.2519579390951737 0.06533979308999706L0.10359458463139784 0.18146243506591617L0 0.4862728453971315L0.08129580872733055 0.792689266886982L0.20257034847159672 0.9160822255736587L0.3286572892798542 0.9738230826074175L0.5742878414421707 1L0.7883510303801312 0.9665431511195721L0.946851033994232 0.8689071500976585L1 0.7311049027121912",D:"M0 1L0.015604366822624637 0.020770988281483303L0.22564758265176144 0L0.3865476147957666 0.0024153386496795644L0.6479126635475078 0.051745644338731314L0.841191887805517 0.15827717679529366L0.9517008345536152 0.30172260586872185L0.9957536578687336 0.4504541551987709L1 0.5624359222498485L0.9798483279164735 0.6584121775234548L0.9386273319285215 0.7395945263504481L0.806292129480815 0.8624239259880274L0.6296239151398265 0.9406169638094516L0.3397492767598845 0.9954164354263132L0 1",E:"M0 0L0 1M0 0L1 0M0 0.5L0.7 0.5M0 1L1 1",F:"M0 0L0 1M0.011363636363636364 0.006802721088435374L1 0.006802721088435374M0.011363636363636364 0.4965986394557823L0.8409090909090909 0.4965986394557823",G:"M0.902666857540557 0.03860785012651126L0.6504261864675637 0L0.3838947267237336 0.015442305268228053L0.21293332876776194 0.07706794377239819L0.07799659974941617 0.1994951236187481L0 0.46380381528937314L0.04159964421546915 0.7502491408002389L0.13176692977834842 0.8535497868383203L0.2709176262273927 0.936767572377719L0.4386472596876406 0.9891638569283179L0.6145513562841309 1L0.7782254421419019 0.9585373611026471L0.9092650433859927 0.8540372997461425L1 0.5556012645283437L0.5583959277303046 0.55491741080559",H:"M0 0L0 1M0 0.4788732394366197L0.989010989010989 0.4788732394366197M1 0L1 1",I:"M0.5 0L0.5 1",J:"M0.9976457238788704 0L1 0.7396412315872798L0.9773931362096968 0.8322033314977973L0.9345115952458736 0.882296255506608L0.8743862896259549 0.9221331222466961L0.8024024079884948 0.9526431718061675L0.6443996712151668 0.9893997797356828L0.5035848940343224 1L0.3127211130319937 0.9877004749449337L0.17201910858386513 0.9539509911894274L0.10357419806379677 0.9212555066079295L0.053656568662899015 0.8816079295154184L0.020759483663648916 0.8360407488986785L0.003376206348523566 0.7855864537444934L0 0.7312775330396476",K:"M0 0L0 1M0.8787878787878788 0.06666666666666667L0 0.6148148148148148M0.3333333333333333 0.45925925925925926L1 0.9777777777777777",L:"M0 0L0 1L1 1",M:"M0 1L0 0L0.5 0.6512L1 0L1 1",N:"M0 1L0 0L1 1L0.9803729146221786 0",O:"M0.4718499217948183 1L0.2896765846490613 0.9606979309189402L0.12315162147934663 0.8411184486080473L0 0.4352399966492615L0.11730398524516283 0.13145645436014852L0.2612197451988078 0.04493357858878059L0.5104071592772554 0L0.7450113425917159 0.05393013710105273L0.882367950645524 0.15242300282020502L1 0.5224527406249126L0.9414597290654386 0.7560662329321755L0.8371289514446183 0.8910800547287298L0.6518259868433511 0.9830452628933628L0.4718499217948183 1",P:"M0 1L0 0.018871774228013626L0.29609603495819875 0L0.5609840637427541 0.011794858892508529L0.7332142696692472 0.04353904702296349L0.8102258645858864 0.0691965055027166L0.9330504315465442 0.14445061754775845L0.9876391714147118 0.22527816445836535L1 0.3434414070631638L0.9510549958116356 0.41772808046663146L0.8746646891596713 0.45879131862541683L0.7528523813396283 0.49171525113425024L0.5766919939969619 0.5153253033973054L0.33725744877712827 0.5284469008187558L0.025622667325582785 0.529905468802775",Q:"M0.4618887943546369 0.9755918167206952L0.28356128136544534 0.9372490397450218L0.12055179272160406 0.8205882753548176L0 0.4246165790405623L0.1148276047430244 0.12824784112887844L0.25570518844754375 0.043836831567190586L0.49963205786237674 0L0.7292835601228574 0.0526138004304122L0.8637404608452104 0.14870263423138746L0.9788892040030622 0.5097006183769648L0.9215847647858059 0.7376120297474734L0.8194564929275405 0.869330409436378L0.6380654214095985 0.9590509139448092L0.4618887943546369 0.9755918167206952M0.5824181120212351 0.6861805006946525L1 1",R:"M0 0.9928375167236815L0 0.02590227442068435L0.3611517274211098 0L0.6146286724700761 0.008660554424468435L0.7675462459194776 0.035269459580494614L0.831839975516866 0.056961676692569484L0.8847592491838954 0.08519560521497332L0.9238557535364527 0.120683646438422L0.9583303225312839 0.21691797435320384L0.955092470586235 0.3022616904894429L0.9198097669001631 0.3640573439322699L0.8564862239866702 0.40639258627024005L0.7691258543593579 0.43335506909190874L0.601775027203482 0.4539166070813109L0.023939064200217658 0.46997623755243123M0.5038084874863982 0.5108023922274467L1 1",S:"M0.8886929689221953 0.15146982162688968L0.7276173683050475 0.013780286031594946L0.34582323121005076 0L0.1318235250900008 0.09920162734298861L0.0444543935052531 0.2811287071349243L0.08064065829108809 0.3709571405906485L0.21603115127470426 0.4485505768228281L0.7525409135992945 0.5111160926769565L0.9330263665417677 0.5850732219351329L1 0.7129938124702524L0.9117772389978691 0.9130572743138187L0.6423187128058188 1L0.29586019579751677 0.9935291584506244L0.10638454191462794 0.9229845198431584L0 0.7570771288048773",T:"M0 0L1 0M0.5148514851485149 0L0.5148514851485149 1",U:"M0 0L0.0023103778751369115 0.5467447428390111L0.01823032542100219 0.6954785891481812L0.05895528135268338 0.8056480226151669L0.13703402031421133 0.8894445726483398L0.23918400876232196 0.9448524533417946L0.3917887458926616 0.9848674531975652L0.584341627875137 1L0.7194816196604602 0.9848501456716763L0.8303268115073934 0.9449411544119768L0.8966613970084885 0.898186315516197L0.9251437568455642 0.867453197565408L0.9687114937020809 0.7890904895145239L0.9890470974808324 0.6852857184065537L1 0.0014769088758762145",V:"M0 0L0.5348837209302325 1L1 0",W:"M0 0L0.23300090661831369 0.9873417721518988L0.49954669084315495 0.30081906180193585L0.7851314596554849 1L1 0.0215934475055845",X:"M0 0L0.9893617021276596 1M1 0L0.010638297872340425 1",Y:"M0 0L0.4860515021459227 0.44712562100780695M1 0.0014194464158977947L0.48927038626609437 0.44996451383960256L0.5075107296137339 1",Z:"M0 0L1 0L0 1L1 1",".":"M 0.49 1 L 0.41 1","*":"M 0.5 0.25 L 0.8 0.25 M 0.5 0.25 L 0.5927 0.4402 M 0.5 0.25 L 0.2573 0.3676 M 0.5 0.25 L 0.2573 0.1324 M 0.5 0.25 L 0.599 0.055","(":"M0.75 0L0.25 0.5L0.25 0.5L0.75 1",")":"M0.25 0L0.75 0.5L0.75 0.5L0.25 1","-":"M0 0.5L1 0.5","+":"M 0 0.5 L 1 0.5 M 0.5 0.125 L 0.5 0.875","=":"M0 0.25L1 0.25M0 0.75L1 0.75",_:"M0 1 L1 1","[":"M0.75 0L0.25 0L0.25 1L0.75 1","]":"M0.25 0L0.75 0L0.75 1L0.25 1","<":"M0.75 0L0.25 0.5L0.25 0.5L0.75 1",">":"M0.25 0L0.75 0.5L0.75 0.5L0.25 1","'":"M 0.5 0 L 0.5 0.5",'"':"M 0.25 0 L 0.25 0.5 M 0.75 0 L 0.75 0.5"},P2e={};for(const t in uft){P2e[t]=[];const e=uft[t].split("M").slice(1).map(n=>n.split("L").map(i=>i.trim().split(" ").map(parseFloat)));for(const n of e)for(let i=0;i<n.length-1;i++)P2e[t].push({x1:n[i][0],y1:1-n[i][1],x2:n[i+1][0],y2:1-n[i+1][1]})}function RX(t,e){return Array.isArray(e)?[t.a*e[0]+t.c*e[1]+t.e,t.b*e[0]+t.d*e[1]+t.f]:{x:t.a*e.x+t.c*e.y+t.e,y:t.b*e.x+t.d*e.y+t.f}}function dft(){return{a:1,c:0,e:0,b:0,d:1,f:0}}function g7(t,e=0){return{a:1,c:0,e:t,b:0,d:1,f:e}}function hft(...t){t=Array.isArray(t[0])?t[0]:t;const e=(n,i)=>({a:n.a*i.a+n.c*i.b,c:n.a*i.c+n.c*i.d,e:n.a*i.e+n.c*i.f+n.e,b:n.b*i.a+n.d*i.b,d:n.b*i.c+n.d*i.d,f:n.b*i.e+n.d*i.f+n.f});switch(t.length){case 0:throw new Error("no matrices provided");case 1:return t[0];case 2:return e(t[0],t[1]);default:{const[n,i,...r]=t,o=e(n,i);return hft(o,...r)}}}function I2e(...t){return hft(...t)}const{cos:_Zn,sin:yZn}=Math;function N2e(t,e,n){const i=_Zn(t),r=yZn(t);return{a:i,c:-r,e:0,b:r,d:i,f:0}}var Ug=({command_code:t,schema:e,stringify:n})=>({command_code:t,schema:e,stringify:n}),gZn=Ug({command_code:"FMAT",schema:Ne({command_code:Ae("FMAT").default("FMAT"),format:Be()}),stringify:t=>`FMAT,${t.format}`}),bZn=Ug({command_code:"G00",schema:Ne({command_code:Ae("G00").default("G00")}),stringify:()=>"G00"}),xZn=Ug({command_code:"G01",schema:Ne({command_code:Ae("G01").default("G01")}),stringify:()=>"G01"}),vZn=Ug({command_code:"G05",schema:Ne({command_code:Ae("G05").default("G05")}),stringify:()=>"G05"}),wZn=Ug({command_code:"G85",schema:Ne({command_code:Ae("G85").default("G85"),x:Be(),y:Be(),width:Be()}),stringify:({x:t,y:e})=>`G85X${t.toFixed(3)}Y${e.toFixed(3)}`}),SZn=Ug({command_code:"G90",schema:Ne({command_code:Ae("G90").default("G90")}),stringify:()=>"G90"}),EZn=Ug({command_code:"M15",schema:Ne({command_code:Ae("M15").default("M15")}),stringify:()=>"M15"}),TZn=Ug({command_code:"M16",schema:Ne({command_code:Ae("M16").default("M16")}),stringify:()=>"M16"}),MZn=Ug({command_code:"M30",schema:Ne({command_code:Ae("M30").default("M30")}),stringify:()=>"M30"}),AZn=Ug({command_code:"M48",schema:Ne({command_code:Ae("M48").default("M48")}),stringify:()=>"M48"}),CZn=Ug({command_code:"M95",schema:Ne({command_code:Ae("M95").default("M95")}),stringify:()=>"M95"}),pft=Ug({command_code:"define_tool",schema:Ne({command_code:Ae("define_tool").default("define_tool"),tool_number:Be(),diameter:Be()}),stringify:t=>`T${t.tool_number}C${t.diameter.toFixed(6)}`}),RZn=Ug({command_code:"drill_at",schema:Ne({command_code:Ae("drill_at").default("drill_at"),x:Be(),y:Be()}),stringify:t=>`X${t.x.toFixed(4)}Y${t.y.toFixed(4)}`}),PZn=Ug({command_code:"header_attribute",schema:Ne({command_code:Ae("header_attribute").default("header_attribute"),attribute_name:B(),attribute_value:B()}),stringify({attribute_name:t,attribute_value:e}){return`; #@! ${t},${e}`}}),IZn=Ug({command_code:"header_comment",schema:Ne({command_code:Ae("header_comment").default("header_comment"),text:B()}),stringify({text:t}){return`; ${t}`}}),NZn=Ug({command_code:"rewind",schema:Ne({command_code:Ae("rewind").default("rewind")}),stringify:()=>"%"}),kZn=Ug({command_code:"unit_format",schema:Ne({command_code:Ae("unit_format").default("unit_format"),unit:oi([Ae("INCH"),Ae("METRIC")]),lz:oi([Ae("LZ"),Ae("TZ")]).nullable().default(null)}),stringify(t){return`${t.unit}${t.lz?`,${t.lz}`:""}`}}),OZn=Ug({command_code:"use_tool",schema:Ne({command_code:Ae("use_tool").default("use_tool"),tool_number:Be()}),stringify:t=>`T${t.tool_number}`}),LZn=Ug({command_code:"aper_function_header",schema:Ne({command_code:Ae("aper_function_header").default("aper_function_header"),is_plated:bt()}),stringify({is_plated:t}){return t?"; #@! TA.AperFunction,Plated,PTH,ComponentDrill":"; #@! TA.AperFunction,NonPlated,NPTH,ComponentDrill"}}),DZn=Ug({command_code:"percent_sign",schema:Ne({command_code:Ae("percent_sign").default("percent_sign")}),stringify:()=>"%"}),fft={G00:bZn,G01:xZn,G85:wZn,M48:AZn,M95:CZn,FMAT:gZn,unit_format:kZn,aper_function_header:LZn,percent_sign:DZn,T:pft,define_tool:pft,use_tool:OZn,G90:SZn,G05:vZn,M15:EZn,M16:TZn,M30:MZn,drill_at:RZn,header_comment:IZn,header_attribute:PZn,rewind:NZn},zZn=t=>t.map(e=>fft[e.command_code].stringify(e)).join(`
6560
+ `),FZn=class{commands;constructor(){this.commands=[]}add(t,e){return this.commands.push({command_code:fft[t].command_code,...e}),this}build(){return this.commands}},BZn=()=>new FZn,UZn=({circuitJson:t,is_plated:e,flip_y_axis:n=!1})=>{const i=BZn();i.add("M48",{});const r=new Date().toISOString();i.add("header_comment",{text:`DRILL file {tscircuit} date ${r}`}).add("header_comment",{text:"FORMAT={-:-/ absolute / metric / decimal}"}).add("header_attribute",{attribute_name:"TF.CreationDate",attribute_value:r}).add("header_attribute",{attribute_name:"TF.GenerationSoftware",attribute_value:"tscircuit"}).add("header_attribute",{attribute_name:"TF.FileFunction",attribute_value:"Plated,1,2,PTH"}).add("FMAT",{format:2}).add("unit_format",{unit:"METRIC",lz:null});let o=10;const s={};for(const a of t){if(a.type!=="pcb_plated_hole"&&a.type!=="pcb_hole"&&a.type!=="pcb_via")continue;const c="hole_diameter"in a&&typeof a.hole_diameter=="number"?a.hole_diameter:"hole_width"in a&&typeof a.hole_width=="number"&&"hole_height"in a&&typeof a.hole_height=="number"?Math.min(a.hole_width,a.hole_height):void 0;c&&(s[c]||(i.add("aper_function_header",{is_plated:e}),i.add("define_tool",{tool_number:o,diameter:c}),s[c]=o,o++))}i.add("percent_sign",{}),i.add("G90",{}),i.add("G05",{});for(let a=10;a<o;a++){i.add("use_tool",{tool_number:a});for(const c of t)if(c.type==="pcb_plated_hole"||c.type==="pcb_hole"||c.type==="pcb_via"){const l="hole_diameter"in c&&typeof c.hole_diameter=="number"?c.hole_diameter:"hole_width"in c&&typeof c.hole_width=="number"&&"hole_height"in c&&typeof c.hole_height=="number"?Math.min(c.hole_width,c.hole_height):void 0;if(!l||s[l]!==a)continue;const u="x"in c&&typeof c.x=="number"?c.x:0,d="y"in c&&typeof c.y=="number"?c.y:0,h="hole_offset_x"in c&&typeof c.hole_offset_x=="number"?c.hole_offset_x:0,f="hole_offset_y"in c&&typeof c.hole_offset_y=="number"?c.hole_offset_y:0,m=u+h,y=d+f,g=n?-1:1;if("hole_width"in c&&typeof c.hole_width=="number"&&"hole_height"in c&&typeof c.hole_height=="number"){const b=c.hole_width,v=c.hole_height,w=Math.max(b,v),T=Math.min(b,v);if(Math.abs(w-T)<=1e-6){i.add("drill_at",{x:m,y:y*g});continue}const R=("hole_ccw_rotation"in c&&typeof c.hole_ccw_rotation=="number"?c.hole_ccw_rotation:"ccw_rotation"in c&&typeof c.ccw_rotation=="number"?c.ccw_rotation:0)*Math.PI/180,P=Math.cos(R),M=Math.sin(R),I=b>=v,A=(w-T)/2,$=I?{x:-A,y:0}:{x:0,y:-A},k=I?{x:A,y:0}:{x:0,y:A},V=({x:be,y:re})=>({x:be*P-re*M,y:be*M+re*P}),X=V($),W=V(k),K=m+X.x,ee=(y+X.y)*g,se=m+W.x,de=(y+W.y)*g;i.add("drill_at",{x:K,y:ee}).add("G85",{x:se,y:de,width:T});continue}i.add("drill_at",{x:m,y:y*g})}}return i.add("M30",{}),i.build()},Zm=({command_code:t,schema:e,stringify:n})=>({command_code:t,schema:e,stringify:n}),$Zn=Zm({command_code:"TA",schema:Ne({command_code:Ae("TA").default("TA"),attribute_name:B(),attribute_value:B()}).describe("Add attribute on aperture: Add an aperture attribute to the dictionary or modify it."),stringify:({attribute_name:t,attribute_value:e})=>`%TA${t},${e}*%`}),jZn=Zm({command_code:"TF",schema:Ne({command_code:Ae("TF").default("TF"),attribute_name:B(),attribute_value:B()}).describe("Add attribute on file: Set a file attribute."),stringify:({attribute_name:t,attribute_value:e})=>`%TF.${t},${e}*%`}),HZn=Zm({command_code:"TO",schema:Ne({command_code:Ae("TO").default("TO"),attribute_name:B(),attribute_value:B()}).describe("Add attribute on object: Add an object attribute to the dictionary or modify it."),stringify:({attribute_name:t,attribute_value:e})=>`%TO${t},${e}*%`}),VZn=Zm({command_code:"AB",schema:Ne({command_code:Ae("AB").default("AB"),block:B()}).describe("Aperture block: Opens a block aperture statement and assigns its aperture number or closes a block aperture statement"),stringify(){return""}}),GZn=Zm({command_code:"G04",schema:Ne({command_code:Ae("G04").default("G04"),comment:B()}).describe("Comment: A human readable comment, does not affect the image. 4.1"),stringify:t=>`G04 ${t.comment}*`}),YZn=Zm({command_code:"G75",schema:Ne({command_code:Ae("G75").default("G75")}).describe("Create arc: A G75 must be called before creating the first arc."),stringify(){return"G75*"}}),qZn=Zm({command_code:"AD",schema:Ne({command_code:Ae("AD").default("AD"),aperture_code:B()}).describe("Aperture define: Defines a template-based aperture, assigns a D code to it. 4.3"),stringify(){return""}}),XZn=Zm({command_code:"AM",schema:Ne({command_code:Ae("AM").default("AM"),macro_name:B(),template_code:B()}).describe("Aperture macro: Defines a macro aperture template. 4.5"),stringify({macro_name:t,template_code:e}){return`%AM${t}*
6561
6561
  ${e}%`}}),WZn=Zm({command_code:"TD",schema:Ne({command_code:Ae("TD").default("TD"),attribute:B().optional()}).describe("Delete attribute: Attribute delete Delete one or all attributes in the dictionary."),stringify({attribute:t}){return t?`%TD${t}*%`:"%TD*%"}}),ZZn=Zm({command_code:"M02",schema:Ne({command_code:Ae("M02").default("M02")}).describe("End of file: 4.13"),stringify(){return"M02*"}}),KZn=Zm({command_code:"G37",schema:Ne({command_code:Ae("G37").default("G37")}).describe("End region statement: Ends the region statement"),stringify(){return"G37*"}}),b7=t=>{const e=t*1e6;let n=e.toFixed(0);for(;n.length<9;)e<0?n=`-0${n.slice(1)}`:n=`0${n}`;return n},QZn=Zm({command_code:"D03",schema:Ne({command_code:Ae("D03").default("D03"),x:Be(),y:Be()}).describe("Flash operation: Creates a flash object with the current aperture. The current point is moved to the flash point."),stringify({x:t,y:e}){const[n,i]=[t,e].map(r=>b7(r));return`X${n}Y${i}D03*`}});Ne({command_code:Ae("LM"),mirroring:B()}).describe("Load mirroring: Loads the mirror object transformation parameter."),Ne({command_code:Ae("LP"),polarity:B()}).describe("Load polarity: Loads the polarity object transformation parameter.");var JZn=Zm({command_code:"LR",schema:Ne({command_code:Ae("LR").default("LR"),rotation_degrees:Be()}).describe("Load rotation: Loads the rotation object transformation parameter."),stringify:({rotation_degrees:t})=>`%LR${t}*%`});Ne({command_code:Ae("LS"),scaling:B()}).describe("Load scaling: Loads the scale object transformation parameter.");var eKn=Zm({command_code:"D02",schema:Ne({command_code:Ae("D02").default("D02"),x:Be(),y:Be()}).describe("Move operation: D02 moves the current point to the coordinate in the command. It does not create an object."),stringify({x:t,y:e}){const[n,i]=[t,e].map(r=>b7(r));return`X${n}Y${i}D02*`}}),tKn=Zm({command_code:"D01",schema:Ne({command_code:Ae("D01").default("D01"),x:Be(),y:Be(),i:Be().optional(),j:Be().optional()}).describe("Plot operation: Outside a region statement D01 creates a draw or arc object with the current aperture. Inside it adds a draw/arc segment to the contour under construction. The current point is moved to draw/arc end point after the creation of the draw/arc."),stringify({x:t,y:e,i:n,j:i}){const r=b7(t),o=b7(e);let s=`X${r}Y${o}`;if(n!==void 0&&i!==void 0){const a=b7(n),c=b7(i);s+=`I${a}J${c}`}return`${s}D01*`}});Ne({command_code:Ae("FS"),format:B()}).describe("Sets the coordinate format, e.g. the number of decimals."),Ne({command_code:Ae("Dnn"),d_code:B()}).describe("(nn≥10) Sets the current aperture to D code nn. 4.6");var nKn=Zm({command_code:"G02",schema:Ne({command_code:Ae("G02").default("G02")}).describe("Set movement mode to clockwise circular: Sets linear/circular mode to clockwise circular."),stringify(){return"G02*"}}),iKn=Zm({command_code:"G03",schema:Ne({command_code:Ae("G03").default("G03")}).describe("Set movement mode to counterclockwise circular: Sets linear/circular mode to counterclockwise circular."),stringify(){return"G03*"}}),rKn=Zm({command_code:"G01",schema:Ne({command_code:Ae("G01").default("G01")}).describe("Set movement mode to linear: Sets linear/circular mode to linear."),stringify(){return"G01*"}}),oKn=Zm({command_code:"MO",schema:Ne({command_code:Ae("MO").default("MO"),unit:dn(["MM","in"])}).describe("Mode: Sets the unit to mm or inch. 4.2.1"),stringify({unit:t}){return`%MO${t}*%`}}),sKn=Zm({command_code:"G36",schema:Ne({command_code:Ae("G36").default("G36")}).describe("Start region statement: Starts a region statement which creates a region by defining its contours."),stringify(){return"G36*"}});Ne({command_code:Ae("SR"),statement:B()}).describe("Step and repeat: Open or closes a step and repeat statement.");var aKn=Zm({command_code:"FS",schema:Ne({command_code:Ae("FS").default("FS"),zero_omission_mode:oi([Ae("L").describe("leading zeros omitted"),Ae("T")]).nullable().default(null),coordinate_notation:oi([Ae("A").describe("absolute notation"),Ae("I").describe("incremental notation")]).default("A"),x_integer_digits:Be().int().default(4),x_decimal_digits:Be().int().default(6),y_integer_digits:Be().int().default(4),y_decimal_digits:Be().int().default(6)}),stringify:()=>"%FSLAX46Y46*%"}),cKn=Zm({command_code:"LP",schema:Ne({command_code:Ae("LP").default("LP"),polarity:dn(["D","C"])}).describe("Layer Polarity: Sets the layer polarity to dark or clear. 4.2.1"),stringify({polarity:t}){return`%LP${t}*%`}}),lKn=Ne({standard_template_code:Ae("C").describe("circle"),diameter:Be(),hole_diameter:Be().optional()}),uKn=Ne({standard_template_code:Ae("R").describe("rectangle"),x_size:Be(),y_size:Be(),hole_diameter:Be().optional()}),dKn=Ne({standard_template_code:Ae("O").describe("obround"),x_size:Be(),y_size:Be(),hole_diameter:Be().optional()}),hKn=Ne({standard_template_code:Ae("P").describe("polygon"),outer_diameter:Be(),number_of_vertices:Be().int(),rotation:Be().optional(),hole_diameter:Be().optional()}),pKn=uy("standard_template_code",[lKn,uKn,dKn,hKn]),fKn=Ne({macro_name:Ae("HORZPILL"),x_size:Be(),y_size:Be(),circle_diameter:Be(),circle_center_offset:Be()}),mKn=Ne({macro_name:Ae("VERTPILL"),x_size:Be(),y_size:Be(),circle_diameter:Be(),circle_center_offset:Be()}),_Kn=Ne({macro_name:Ae("ROUNDRECT"),corner_radius:Be(),corner_1_x:Be(),corner_1_y:Be(),corner_2_x:Be(),corner_2_y:Be(),corner_3_x:Be(),corner_3_y:Be(),corner_4_x:Be(),corner_4_y:Be()}),yKn=uy("macro_name",[fKn,mKn,_Kn]),gKn=oi([pKn,yKn]),bKn=Zm({command_code:"ADD",schema:gKn.and(Ne({command_code:Ae("ADD").default("ADD"),aperture_number:Be().int()})),stringify(t){if("macro_name"in t){const{aperture_number:e,macro_name:n}=t;let i=`%ADD${e}${n},`;if(n==="HORZPILL"||n==="VERTPILL")i+=`${t.x_size.toFixed(6)}X${t.y_size.toFixed(6)}X${t.circle_diameter.toFixed(6)}X${t.circle_center_offset.toFixed(6)}`;else if(n==="ROUNDRECT")throw new Error("ROUNDRECT macro not implemented yet");return i+="*%",i}if("standard_template_code"in t){const{aperture_number:e,standard_template_code:n}=t;let i=`%ADD${e}${n},`;return n==="C"?i+=`${t.diameter.toFixed(6)}`:n==="R"||n==="O"?i+=`${t.x_size.toFixed(6)}X${t.y_size.toFixed(6)}`:n==="P"&&(i+=`${t.outer_diameter}X${t.number_of_vertices}X${t.rotation?`X${t.rotation}`:""}`),t.hole_diameter&&(i+=`X${t.hole_diameter.toFixed(6)}`),i+="*%",i}throw new Error(`Invalid aperture template config: ${JSON.stringify(t)}`)}}),xKn=Zm({command_code:"D",schema:Ne({command_code:Ae("D").default("D"),aperture_number:Be().int()}),stringify({aperture_number:t}){return`D${t}*`}}),mft={add_attribute_on_aperture:$Zn,add_attribute_on_file:jZn,add_attribute_on_object:HZn,aperture_block:VZn,comment:GZn,create_arc:YZn,define_aperture:qZn,define_macro_aperture_template:XZn,delete_attribute:WZn,end_of_file:ZZn,move_operation:eKn,flash_operation:QZn,end_region_statement:KZn,format_specification:aKn,load_rotation:JZn,plot_operation:tKn,define_aperture_template:bKn,set_movement_mode_to_clockwise_circular:nKn,set_movement_mode_to_counterclockwise_circular:iKn,set_movement_mode_to_linear:rKn,select_aperture:xKn,set_unit:oKn,set_layer_polarity:cKn,start_region_statement:sKn},Ky=()=>new vKn,vKn=class{commands;constructor(){this.commands=[]}$if(t,e){return t?e(this):this}add(t,e){return this.commands.push({command_code:mft[t].command_code,...e}),this}build(){return this.commands}},wKn=t=>{const e=Object.values(mft).find(n=>n.command_code===t.command_code);if(!e)throw new Error(`Command for command_code:"${t.command_code}" not found`);if(!e.stringify)throw new Error(`Command for command_code:"${t.command_code}" does not have a stringify method`);return e.stringify(t)},SKn=t=>{const e={};for(const n of Object.keys(t))e[n]=t[n].map(i=>wKn(i)).join(`
6562
6562
  `);return e};function EKn(t){const e=[];for(let n=0;n<t.length-1;n++)e.push([t[n],t[n+1]]);return e}var TKn=t=>{t.push(...Ky().add("comment",{comment:"APERTURE MACROS START"}).add("define_macro_aperture_template",{macro_name:"HORZPILL",template_code:`
6563
6563
  0 Horizontal pill (stadium) shape macro*
@@ -6598,7 +6598,7 @@ ${e}%`}}),WZn=Zm({command_code:"TD",schema:Ne({command_code:Ae("TD").default("TD
6598
6598
  20,1,$1+$1,$4,$5,$6,$7,0*
6599
6599
  20,1,$1+$1,$6,$7,$8,$9,0*
6600
6600
  20,1,$1+$1,$8,$9,$2,$3,0*
6601
- `.trim()}).add("comment",{comment:"APERTURE MACROS END"}).build())};function MKn(t){const e=t.filter(i=>i.type==="pcb_trace"),n={};for(const i of e)for(const r of i.route)r.route_type==="wire"&&(n[r.layer]=n[r.layer]||new Set,n[r.layer].add(r.width));return{top:Array.from(n.top||[]),bottom:Array.from(n.bottom||[])}}function AKn({glayer:t,soup:e,glayer_name:n}){const i=()=>{const s=t.reduce((a,c)=>c.command_code==="ADD"?Math.max(a,c.aperture_number):a,0);return s===0?10:s+1};t.push(...Ky().add("comment",{comment:"aperture START LIST"}).build());const r=MKn(e);for(const s of r[n.startsWith("F_")?"top":"bottom"])t.push(...Ky().add("define_aperture_template",{aperture_number:i(),standard_template_code:"C",diameter:s}).build());const o=CKn(e,n.startsWith("F_")?"top":"bottom");for(const s of o)t.push(...Ky().add("define_aperture_template",{aperture_number:i(),...s}).build());t.push(...Ky().add("delete_attribute",{}).add("comment",{comment:"aperture END LIST"}).build())}var _ft=t=>{if(t.shape==="rect")return{standard_template_code:"R",x_size:t.width,y_size:t.height};if(t.shape==="circle")return{standard_template_code:"C",diameter:t.radius*2};if(t.shape==="rotated_rect")return{standard_template_code:"R",x_size:t.width,y_size:t.height};throw new Error(`Unsupported shape ${t.shape}`)},yft=t=>{if("stroke_width"in t)return{standard_template_code:"C",diameter:t.stroke_width};throw new Error(`Provide stroke_width for: ${t}`)},gft=t=>{if("font_size"in t)return{standard_template_code:"C",diameter:t.font_size/8};throw new Error(`Provide font_size for: ${t}`)},bft=t=>{if(t.shape==="rect")return{standard_template_code:"R",x_size:t.width,y_size:t.height};if(t.shape==="rotated_rect")return{standard_template_code:"R",x_size:t.width,y_size:t.height};if(t.shape==="circle")return{standard_template_code:"C",diameter:t.radius*2};if(t.shape==="pill"){if(!("width"in t&&"height"in t))throw new Error("Invalid pill shape in getApertureConfigFromPcbPlatedHole: missing dimensions");return t.width>=t.height?{macro_name:"HORZPILL",x_size:t.width,y_size:t.height,circle_diameter:Math.min(t.width,t.height),circle_center_offset:t.width/2}:{macro_name:"VERTPILL",x_size:t.width,y_size:t.height,circle_diameter:Math.min(t.width,t.height),circle_center_offset:t.height/2}}throw new Error(`Unsupported shape ${t.shape}`)},xft=t=>{if(t.shape==="circle"){if(!("outer_diameter"in t&&"hole_diameter"in t))throw new Error("Invalid circle shape in getApertureConfigFromPcbPlatedHole: missing diameters");return{standard_template_code:"C",diameter:t.outer_diameter}}if(t.shape==="pill"){if(!("outer_width"in t&&"outer_height"in t))throw new Error("Invalid pill shape in getApertureConfigFromPcbPlatedHole: missing dimensions");return t.outer_width>t.outer_height?{macro_name:"HORZPILL",x_size:t.outer_width,y_size:t.outer_height,circle_diameter:Math.min(t.outer_width,t.outer_height),circle_center_offset:t.outer_width/2}:{macro_name:"VERTPILL",x_size:t.outer_width,y_size:t.outer_height,circle_diameter:Math.min(t.outer_width,t.outer_height),circle_center_offset:t.outer_height/2}}if(t.shape==="circular_hole_with_rect_pad"){if(!("rect_pad_width"in t&&"rect_pad_height"in t))throw new Error("Invalid circular_hole_with_rect_pad shape in getApertureConfigFromPcbPlatedHole: missing dimensions");return{standard_template_code:"R",x_size:t.rect_pad_width,y_size:t.rect_pad_height}}throw new Error(`Unsupported shape in getApertureConfigFromPcbPlatedHole: ${t.shape}`)},vft=t=>{if(!("hole_diameter"in t))throw new Error(`Invalid shape called in getApertureConfigFromCirclePcbHole: ${t.hole_shape}`);return{standard_template_code:"C",diameter:t.hole_diameter}},wft=t=>{if(!("outer_diameter"in t))throw new Error("outer_diameter not specified in getApertureConfigFromPcbVia");return{standard_template_code:"C",diameter:t.outer_diameter}};function CKn(t,e){const n=[],i=new Set,r=o=>{const s=mZn(o);i.has(s)||(n.push(o),i.add(s))};for(const o of t)o.type==="pcb_smtpad"?o.layer===e&&r(_ft(o)):o.type==="pcb_solder_paste"?o.layer===e&&r(bft(o)):o.type==="pcb_plated_hole"?o.layers.includes(e)&&r(xft(o)):o.type==="pcb_hole"?o.hole_shape==="circle"?r(vft(o)):console.warn("NOT IMPLEMENTED: drawing gerber for non circle holes"):o.type==="pcb_via"?r(wft(o)):o.type==="pcb_silkscreen_path"?r(yft(o)):o.type==="pcb_silkscreen_text"&&r(gft(o));return n}var P3=(t,e)=>{let n;if("trace_width"in e){const i=e.trace_width;n=t.find(r=>"standard_template_code"in r&&r.command_code==="ADD"&&r.standard_template_code==="C"&&r.diameter===i)}else("standard_template_code"in e||"macro_name"in e)&&(n=t.find(i=>i.command_code==="ADD"&&Object.keys(e).every(r=>i[r]===e[r])));if(!n)throw new Error(`Aperture not found for search params ${JSON.stringify(e)}`);return n.aperture_number},RKn={version:"0.0.32"},PKn={"top-copper":"Copper,L1,Top","bottom-copper":"Copper,L2,Bot","top-soldermask":"Soldermask,Top","bottom-soldermask":"Soldermask,Bot","top-silkscreen":"Legend,Top","bottom-silkscreen":"Legend,Bot","top-paste":"Paste,Top","bottom-paste":"Paste,Bot",edgecut:"Profile,NP"},I3=t=>{const e=PKn[t.layer_type?`${t.layer}-${t.layer_type}`:t.layer];return Ky().add("add_attribute_on_file",{attribute_name:"GenerationSoftware",attribute_value:`tscircuit,circuit-json-to-gerber,${RKn.version}`}).add("add_attribute_on_file",{attribute_name:"CreationDate",attribute_value:new Date().toISOString()}).add("add_attribute_on_file",{attribute_name:"SameCoordinates",attribute_value:"Original"}).add("add_attribute_on_file",{attribute_name:"FileFunction",attribute_value:e}).$if(t.layer!=="edgecut",n=>n.add("add_attribute_on_file",{attribute_name:"FilePolarity",attribute_value:t.layer_type==="soldermask"?"Negative":"Positive"})).add("format_specification",{}).add("set_unit",{unit:"MM"}).add("comment",{comment:"Gerber Fmt 4.6, Leading zero omitted, Abs format (unit mm)"}).add("comment",{comment:`Created by tscircuit (builder) date ${new Date().toISOString()}`}).add("set_movement_mode_to_linear",{}).add("set_layer_polarity",{polarity:"D"}).add("create_arc",{}).build()},IKn={top:"F_",bottom:"B_"},NKn={copper:"Cu",silkscreen:"SilkScreen",soldermask:"Mask",mask:"Mask",paste:"Paste"},k5=(t,e)=>t==="edgecut"?"Edge_Cuts":`${IKn[t]}${NKn[e]}`,kKn=(t,e={})=>{e.flip_y_axis??=!1;const n={F_Cu:I3({layer:"top",layer_type:"copper"}),F_SilkScreen:I3({layer:"top",layer_type:"silkscreen"}),F_Mask:I3({layer:"top",layer_type:"soldermask"}),F_Paste:I3({layer:"top",layer_type:"paste"}),B_Cu:I3({layer:"bottom",layer_type:"copper"}),B_SilkScreen:I3({layer:"bottom",layer_type:"silkscreen"}),B_Mask:I3({layer:"bottom",layer_type:"soldermask"}),B_Paste:I3({layer:"bottom",layer_type:"paste"}),Edge_Cuts:I3({layer:"edgecut"})};for(const r of["F_Cu","B_Cu","F_Mask","B_Mask","F_Paste","B_Paste","F_SilkScreen","B_SilkScreen"]){const o=n[r];TKn(o),AKn({soup:t,glayer:o,glayer_name:r})}n.Edge_Cuts.push(...Ky().add("define_aperture_template",{aperture_number:10,standard_template_code:"C",diameter:.05}).build());const i=r=>e.flip_y_axis?-r:r;for(const r of["top","bottom","edgecut"])for(const o of t)if(o.type==="pcb_trace"){const{route:s}=o;for(const[a,c]of EKn(s))if(a.route_type==="wire"&&a.layer===r){const l=n[k5(r,"copper")];l.push(...Ky().add("select_aperture",{aperture_number:P3(l,{trace_width:a.width})}).add("move_operation",{x:a.x,y:i(a.y)}).add("plot_operation",{x:c.x,y:i(c.y)}).build())}}else if(o.type==="pcb_silkscreen_path"){if(o.layer===r){const s=n[k5(r,"silkscreen")],a=yft(o),c=Ky().add("select_aperture",{aperture_number:P3(s,a)});o.route.length>0&&c.add("move_operation",{x:o.route[0].x,y:i(o.route[0].y)});for(let l=1;l<o.route.length;l++)c.add("plot_operation",{x:o.route[l].x,y:i(o.route[l].y)});s.push(...c.build())}}else if(o.type==="pcb_silkscreen_text"){if(o.layer===r){const a=n[k5(r,"silkscreen")],c=gft(o),l=Ky().add("select_aperture",{aperture_number:P3(a,c)});let u=o.anchor_position.x,d=o.anchor_position.y;const h=o.font_size*.7,f=h*.4,m=h*.5,y=o.text.split("").reduce((M,I)=>I===" "?M+m+f:M+h+f,0)-f,g=h;switch(o.anchor_alignment||(()=>{const M=o.anchor_side;if(M)switch(M){case"top":return"top_center";case"bottom":return"bottom_center";case"left":return"center_left";case"right":return"center_right"}})()||"center"){case"top_left":break;case"top_center":u-=y/2;break;case"top_right":u-=y;break;case"center_right":d-=g/2;break;case"center_left":u-=y,d-=g/2;break;case"bottom_left":d-=g;break;case"bottom_center":u-=y/2,d-=g;break;case"bottom_right":u-=y,d-=g;break;default:u-=y/2,d-=g/2;break}let v=u;const w=d;let T=o.ccw_rotation||0;const N=v+y/2,R=w+g/2,P=[];if(o.layer==="bottom"&&(P.push(g7(N,R),{a:-1,b:0,c:0,d:1,e:0,f:0},g7(-N,-R)),T=-T),T){const M=T*Math.PI/180;P.push(g7(N,R),N2e(M),g7(-N,-R))}for(const M of o.text.toUpperCase()){if(M===" "){v+=m+f;continue}const I=P2e[M]||[];for(const A of I){const $=v+A.x1*h,k=w+A.y1*h,V=v+A.x2*h,X=w+A.y2*h;let W={x:$,y:k},K={x:V,y:X};if(P.length>0){const ee=I2e(...P);W=RX(ee,W),K=RX(ee,K)}l.add("move_operation",{x:W.x,y:i(W.y)}),l.add("plot_operation",{x:K.x,y:i(K.y)})}v+=h+f}a.push(...l.build())}}else if(o.type==="pcb_smtpad"&&o.shape!=="polygon"){if(o.layer===r)for(const s of[n[k5(r,"copper")],n[k5(r,"soldermask")]]){const a=_ft(o),c=P3(s,a),l=Ky().add("select_aperture",{aperture_number:c});o.shape==="rotated_rect"&&o.ccw_rotation&&l.add("load_rotation",{rotation_degrees:o.ccw_rotation}),l.add("flash_operation",{x:o.x,y:i(o.y)}),o.shape==="rotated_rect"&&o.ccw_rotation&&l.add("load_rotation",{rotation_degrees:0}),s.push(...l.build())}}else if(o.type==="pcb_solder_paste"){if(o.layer===r)for(const s of[n[k5(r,"paste")]])s.push(...Ky().add("select_aperture",{aperture_number:P3(s,bft(o))}).add("flash_operation",{x:o.x,y:i(o.y)}).build())}else if(o.type==="pcb_plated_hole"){if(o.layers.includes(r))for(const s of[n[k5(r,"copper")],n[k5(r,"soldermask")]])if(o.shape==="pill"){const a={standard_template_code:"C",diameter:o.outer_width>o.outer_height?o.outer_height:o.outer_width};let c=10;try{c=P3(s,a)}catch{c=Math.max(...s.filter(g=>"aperture_number"in g).map(g=>g.aperture_number),9)+1,s.push(...Ky().add("define_aperture_template",{aperture_number:c,...a}).build())}const l=Ky().add("select_aperture",{aperture_number:c}),u=(o.ccw_rotation??0)*Math.PI/180,d=Math.cos(u),h=Math.sin(u),f=(g,b)=>{const v=g*d-b*h,w=g*h+b*d;return{x:o.x+v,y:o.y+w}},m=o.outer_width>o.outer_height,y=m?(o.outer_width-o.outer_height)/2:(o.outer_height-o.outer_width)/2;if(y<=0){const g=f(0,0);l.add("flash_operation",{x:g.x,y:i(g.y)})}else{const g=m?{x:-y,y:0}:{x:0,y:-y},b=m?{x:y,y:0}:{x:0,y},v=f(g.x,g.y),w=f(b.x,b.y);l.add("flash_operation",{x:v.x,y:i(v.y)}).add("move_operation",{x:v.x,y:i(v.y)}).add("plot_operation",{x:w.x,y:i(w.y)}).add("flash_operation",{x:w.x,y:i(w.y)})}s.push(...l.build())}else{const a=xft(o);s.push(...Ky().add("select_aperture",{aperture_number:P3(s,a)}).add("flash_operation",{x:o.x,y:i(o.y)}).build())}}else if(o.type==="pcb_hole"){if(r!=="edgecut")for(const s of[n[k5(r,"soldermask")]]){if(o.hole_shape!=="circle"){console.warn("NOT IMPLEMENTED: drawing gerber for non-round holes");continue}s.push(...Ky().add("select_aperture",{aperture_number:P3(s,vft(o))}).add("flash_operation",{x:o.x,y:i(o.y)}).build())}}else if(o.type==="pcb_via"){if(o.layers.includes(r))for(const s of[n[k5(r,"copper")]])s.push(...Ky().add("select_aperture",{aperture_number:P3(s,wft(o))}).add("flash_operation",{x:o.x,y:i(o.y)}).build())}else if(o.type==="pcb_board"&&r==="edgecut"){const s=n.Edge_Cuts,{width:a,height:c,center:l,outline:u}=o,d=Ky().add("select_aperture",{aperture_number:10});if(u&&u.length>2){d.add("move_operation",u[0]);for(let h=1;h<u.length;h++)d.add("plot_operation",u[h])}else d.add("move_operation",{x:l.x-a/2,y:i(l.y-c/2)}).add("plot_operation",{x:l.x+a/2,y:i(l.y-c/2)}).add("plot_operation",{x:l.x+a/2,y:i(l.y+c/2)}).add("plot_operation",{x:l.x-a/2,y:i(l.y+c/2)}).add("plot_operation",{x:l.x-a/2,y:i(l.y-c/2)});s.push(...d.build())}else if(o.type==="pcb_cutout"){if(r==="edgecut"){const s=n.Edge_Cuts,a=Ky().add("select_aperture",{aperture_number:10}),c=o;if(c.shape==="rect"){const{center:l,width:u,height:d,rotation:h}=c,f=u/2,m=d/2,y=[{x:-f,y:m},{x:f,y:m},{x:f,y:-m},{x:-f,y:-m}];let g=dft();if(h){const v=h*Math.PI/180;g=N2e(v)}g=I2e(g7(l.x,l.y),g);const b=y.map(v=>RX(g,v));a.add("move_operation",{x:b[0].x,y:i(b[0].y)});for(let v=1;v<b.length;v++)a.add("plot_operation",{x:b[v].x,y:i(b[v].y)});a.add("plot_operation",{x:b[0].x,y:i(b[0].y)})}else if(c.shape==="circle"){const{center:l,radius:u}=c,d={x:l.x+u,y:l.y},h={x:l.x-u,y:l.y};a.add("move_operation",{x:d.x,y:i(d.y)}).add("set_movement_mode_to_counterclockwise_circular",{}).add("plot_operation",{x:h.x,y:i(h.y),i:-u,j:0}).add("plot_operation",{x:d.x,y:i(d.y),i:u,j:0}).add("set_movement_mode_to_linear",{})}else if(c.shape==="polygon"){const{points:l}=c;if(l.length>0){a.add("move_operation",{x:l[0].x,y:i(l[0].y)});for(let u=1;u<l.length;u++)a.add("plot_operation",{x:l[u].x,y:i(l[u].y)});a.add("plot_operation",{x:l[0].x,y:i(l[0].y)})}}s.push(...a.build())}}else if(o.type==="pcb_copper_pour"&&r===o.layer){const s=n[k5(r,"copper")],a=Ky().add("select_aperture",{aperture_number:10}).add("start_region_statement",{});if(o.shape==="brep"){const{brep_shape:c}=o;if(!c)continue;const{outer_ring:l,inner_rings:u}=c,d=f=>{if(!f||f.vertices.length===0)return;a.add("move_operation",{x:f.vertices[0].x,y:i(f.vertices[0].y)});const m=[...f.vertices,f.vertices[0]];for(let y=0;y<m.length-1;y++){const g=m[y],b=m[y+1];if(g.bulge&&Math.abs(g.bulge)>1e-9){const v=(e.flip_y_axis?-1:1)*g.bulge;v>0?a.add("set_movement_mode_to_counterclockwise_circular",{}):a.add("set_movement_mode_to_clockwise_circular",{});const w={x:g.x,y:g.y},T={x:b.x,y:b.y},N=T.x-w.x,R=T.y-w.y,P=Math.sqrt(N*N+R*R);if(P<1e-9){a.add("set_movement_mode_to_linear",{}),a.add("plot_operation",{x:b.x,y:i(b.y)});continue}const M=Math.abs(v),I=4*Math.atan(M);if(Math.abs(Math.sin(I/2))<1e-9){a.add("set_movement_mode_to_linear",{}),a.add("plot_operation",{x:b.x,y:i(b.y)});continue}const A=P/(2*Math.sin(I/2)),$=(Math.PI-I)/2,k=Math.atan2(R,N),V=v>0?$:-$,X=k+V,W=w.x+A*Math.cos(X),K=w.y+A*Math.sin(X),ee=W-w.x,se=K-w.y;a.add("plot_operation",{x:b.x,y:i(b.y),i:ee,j:e.flip_y_axis?-se:se})}else a.add("set_movement_mode_to_linear",{}),a.add("plot_operation",{x:b.x,y:i(b.y)})}},h=f=>{const{vertices:m}=f;if(!m||m.length===0)return{vertices:[]};const y=m.length;return{vertices:[...m].reverse().map((v,w)=>{const T=(y-2-w+y)%y,N=m[T].bulge;return{...v,bulge:N?-N:void 0}})}};if(d(h(l)),u)for(const f of u)d(h(f))}else if(o.shape==="rect"){const{center:c,width:l,height:u,rotation:d}=o,h=l/2,f=u/2,m=[{x:-h,y:f},{x:h,y:f},{x:h,y:-f},{x:-h,y:-f}];let y=dft();if(d){const b=d*Math.PI/180;y=N2e(b)}y=I2e(g7(c.x,c.y),y);const g=m.map(b=>RX(y,b));a.add("move_operation",{x:g[0].x,y:i(g[0].y)});for(let b=1;b<g.length;b++)a.add("plot_operation",{x:g[b].x,y:i(g[b].y)});a.add("plot_operation",{x:g[0].x,y:i(g[0].y)})}else if(o.shape==="polygon"){const{points:c}=o;if(c.length>0){a.add("move_operation",{x:c[0].x,y:i(c[0].y)});for(let l=1;l<c.length;l++)a.add("plot_operation",{x:c[l].x,y:i(c[l].y)});a.add("plot_operation",{x:c[0].x,y:i(c[0].y)})}}a.add("end_region_statement",{}),s.push(...a.build())}for(const r of Object.keys(n))n[r].push(...Ky().add("end_of_file",{}).build());return n},Wk={},k2e={},Sft;function OKn(){return Sft||(Sft=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0});var e=(function(){function o(s,a){var c=[],l=!0,u=!1,d=void 0;try{for(var h=s[Symbol.iterator](),f;!(l=(f=h.next()).done)&&(c.push(f.value),!(a&&c.length===a));l=!0);}catch(m){u=!0,d=m}finally{try{!l&&h.return&&h.return()}finally{if(u)throw d}}return c}return function(s,a){if(Array.isArray(s))return s;if(Symbol.iterator in Object(s))return o(s,a);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})();t.default=i,t.parseUnitObj=r;var n=/-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/;function i(o){var s=parseFloat(o),a=o.match(n)||[],c=a.length>0?o.substr(a[0].length).trim():"";return[s,c]}function r(o){var s=i(o),a=e(s,2),c=a[0],l=a[1];return{val:c,unit:l}}})(k2e)),k2e}var Eft;function LKn(){if(Eft)return Wk;Eft=1,Object.defineProperty(Wk,"__esModule",{value:!0});var t=(function(){function c(l,u){var d=[],h=!0,f=!1,m=void 0;try{for(var y=l[Symbol.iterator](),g;!(h=(g=y.next()).done)&&(d.push(g.value),!(u&&d.length===u));h=!0);}catch(b){f=!0,m=b}finally{try{!h&&y.return&&y.return()}finally{if(f)throw m}}return d}return function(l,u){if(Array.isArray(l))return l;if(Symbol.iterator in Object(l))return c(l,u);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})();Wk.formatSI=o,Wk.unformatSI=a;function e(c){return c&&c.__esModule?c:{default:c}}var n=OKn(),i=e(n),r={24:"Y",21:"Z",18:"E",15:"P",12:"T",9:"G",6:"M",3:"k",0:"","-3":"m","-6":"µ","-9":"n","-12":"p","-15":"f","-18":"a","-21":"z","-24":"y"};function o(c){if(c===0)return"0";for(var l=Math.abs(c),u=0;l>=1e3&&u<24;)l/=1e3,u+=3;for(;l<1&&u>-24;)l*=1e3,u-=3;var d=c<0?"-":"";return l>1e3?d+l.toFixed(0)+r[u]:d+parseFloat(l.toPrecision(3))+r[u]}var s={Y:1e24,Z:1e21,E:1e18,P:1e15,T:1e12,G:1e9,M:1e6,k:1e3,"":1,m:.001,µ:1e-6,u:1e-6,n:1e-9,p:1e-12,f:1e-15,a:1e-18,z:1e-21,y:1e-24};function a(c){if(c==null||c==="")return NaN;var l=(0,i.default)(c),u=t(l,2),d=u[0],h=u[1],f=s[h];return d*f}return Wk}var DKn=LKn(),PX={exports:{}};/* @license
6601
+ `.trim()}).add("comment",{comment:"APERTURE MACROS END"}).build())};function MKn(t){const e=t.filter(i=>i.type==="pcb_trace"),n={};for(const i of e)for(const r of i.route)r.route_type==="wire"&&(n[r.layer]=n[r.layer]||new Set,n[r.layer].add(r.width));return{top:Array.from(n.top||[]),bottom:Array.from(n.bottom||[])}}function AKn({glayer:t,soup:e,glayer_name:n}){const i=()=>{const s=t.reduce((a,c)=>c.command_code==="ADD"?Math.max(a,c.aperture_number):a,0);return s===0?10:s+1};t.push(...Ky().add("comment",{comment:"aperture START LIST"}).build());const r=MKn(e);for(const s of r[n.startsWith("F_")?"top":"bottom"])t.push(...Ky().add("define_aperture_template",{aperture_number:i(),standard_template_code:"C",diameter:s}).build());const o=CKn(e,n.startsWith("F_")?"top":"bottom");for(const s of o)t.push(...Ky().add("define_aperture_template",{aperture_number:i(),...s}).build());t.push(...Ky().add("delete_attribute",{}).add("comment",{comment:"aperture END LIST"}).build())}var _ft=t=>{if(t.shape==="rect")return{standard_template_code:"R",x_size:t.width,y_size:t.height};if(t.shape==="circle")return{standard_template_code:"C",diameter:t.radius*2};if(t.shape==="rotated_rect")return{standard_template_code:"R",x_size:t.width,y_size:t.height};throw new Error(`Unsupported shape ${t.shape}`)},yft=t=>{if("stroke_width"in t)return{standard_template_code:"C",diameter:t.stroke_width};throw new Error(`Provide stroke_width for: ${t}`)},gft=t=>{if("font_size"in t)return{standard_template_code:"C",diameter:t.font_size/8};throw new Error(`Provide font_size for: ${t}`)},bft=t=>{if(t.shape==="rect")return{standard_template_code:"R",x_size:t.width,y_size:t.height};if(t.shape==="rotated_rect")return{standard_template_code:"R",x_size:t.width,y_size:t.height};if(t.shape==="circle")return{standard_template_code:"C",diameter:t.radius*2};if(t.shape==="pill"){if(!("width"in t&&"height"in t))throw new Error("Invalid pill shape in getApertureConfigFromPcbPlatedHole: missing dimensions");return t.width>=t.height?{macro_name:"HORZPILL",x_size:t.width,y_size:t.height,circle_diameter:Math.min(t.width,t.height),circle_center_offset:t.width/2}:{macro_name:"VERTPILL",x_size:t.width,y_size:t.height,circle_diameter:Math.min(t.width,t.height),circle_center_offset:t.height/2}}throw new Error(`Unsupported shape ${t.shape}`)},xft=t=>{if(t.shape==="circle"){if(!("outer_diameter"in t&&"hole_diameter"in t))throw new Error("Invalid circle shape in getApertureConfigFromPcbPlatedHole: missing diameters");return{standard_template_code:"C",diameter:t.outer_diameter}}if(t.shape==="pill"){if(!("outer_width"in t&&"outer_height"in t))throw new Error("Invalid pill shape in getApertureConfigFromPcbPlatedHole: missing dimensions");return t.outer_width>t.outer_height?{macro_name:"HORZPILL",x_size:t.outer_width,y_size:t.outer_height,circle_diameter:Math.min(t.outer_width,t.outer_height),circle_center_offset:t.outer_width/2}:{macro_name:"VERTPILL",x_size:t.outer_width,y_size:t.outer_height,circle_diameter:Math.min(t.outer_width,t.outer_height),circle_center_offset:t.outer_height/2}}const e=t.shape;if(e==="circular_hole_with_rect_pad"||e==="pill_hole_with_rect_pad"||e==="rotated_pill_hole_with_rect_pad"){if(!("rect_pad_width"in t&&"rect_pad_height"in t))throw new Error(`Invalid ${e} shape in getApertureConfigFromPcbPlatedHole: missing dimensions`);return{standard_template_code:"R",x_size:t.rect_pad_width,y_size:t.rect_pad_height}}throw new Error(`Unsupported shape in getApertureConfigFromPcbPlatedHole: ${t.shape}`)},vft=t=>{if(!("hole_diameter"in t))throw new Error(`Invalid shape called in getApertureConfigFromCirclePcbHole: ${t.hole_shape}`);return{standard_template_code:"C",diameter:t.hole_diameter}},wft=t=>{if(!("outer_diameter"in t))throw new Error("outer_diameter not specified in getApertureConfigFromPcbVia");return{standard_template_code:"C",diameter:t.outer_diameter}};function CKn(t,e){const n=[],i=new Set,r=o=>{const s=mZn(o);i.has(s)||(n.push(o),i.add(s))};for(const o of t)o.type==="pcb_smtpad"?o.layer===e&&r(_ft(o)):o.type==="pcb_solder_paste"?o.layer===e&&r(bft(o)):o.type==="pcb_plated_hole"?o.layers.includes(e)&&r(xft(o)):o.type==="pcb_hole"?o.hole_shape==="circle"?r(vft(o)):console.warn("NOT IMPLEMENTED: drawing gerber for non circle holes"):o.type==="pcb_via"?r(wft(o)):o.type==="pcb_silkscreen_path"?r(yft(o)):o.type==="pcb_silkscreen_text"&&r(gft(o));return n}var P3=(t,e)=>{let n;if("trace_width"in e){const i=e.trace_width;n=t.find(r=>"standard_template_code"in r&&r.command_code==="ADD"&&r.standard_template_code==="C"&&r.diameter===i)}else("standard_template_code"in e||"macro_name"in e)&&(n=t.find(i=>i.command_code==="ADD"&&Object.keys(e).every(r=>i[r]===e[r])));if(!n)throw new Error(`Aperture not found for search params ${JSON.stringify(e)}`);return n.aperture_number},RKn={version:"0.0.33"},PKn={"top-copper":"Copper,L1,Top","bottom-copper":"Copper,L2,Bot","top-soldermask":"Soldermask,Top","bottom-soldermask":"Soldermask,Bot","top-silkscreen":"Legend,Top","bottom-silkscreen":"Legend,Bot","top-paste":"Paste,Top","bottom-paste":"Paste,Bot",edgecut:"Profile,NP"},I3=t=>{const e=PKn[t.layer_type?`${t.layer}-${t.layer_type}`:t.layer];return Ky().add("add_attribute_on_file",{attribute_name:"GenerationSoftware",attribute_value:`tscircuit,circuit-json-to-gerber,${RKn.version}`}).add("add_attribute_on_file",{attribute_name:"CreationDate",attribute_value:new Date().toISOString()}).add("add_attribute_on_file",{attribute_name:"SameCoordinates",attribute_value:"Original"}).add("add_attribute_on_file",{attribute_name:"FileFunction",attribute_value:e}).$if(t.layer!=="edgecut",n=>n.add("add_attribute_on_file",{attribute_name:"FilePolarity",attribute_value:t.layer_type==="soldermask"?"Negative":"Positive"})).add("format_specification",{}).add("set_unit",{unit:"MM"}).add("comment",{comment:"Gerber Fmt 4.6, Leading zero omitted, Abs format (unit mm)"}).add("comment",{comment:`Created by tscircuit (builder) date ${new Date().toISOString()}`}).add("set_movement_mode_to_linear",{}).add("set_layer_polarity",{polarity:"D"}).add("create_arc",{}).build()},IKn={top:"F_",bottom:"B_"},NKn={copper:"Cu",silkscreen:"SilkScreen",soldermask:"Mask",mask:"Mask",paste:"Paste"},k5=(t,e)=>t==="edgecut"?"Edge_Cuts":`${IKn[t]}${NKn[e]}`,kKn=(t,e={})=>{e.flip_y_axis??=!1;const n={F_Cu:I3({layer:"top",layer_type:"copper"}),F_SilkScreen:I3({layer:"top",layer_type:"silkscreen"}),F_Mask:I3({layer:"top",layer_type:"soldermask"}),F_Paste:I3({layer:"top",layer_type:"paste"}),B_Cu:I3({layer:"bottom",layer_type:"copper"}),B_SilkScreen:I3({layer:"bottom",layer_type:"silkscreen"}),B_Mask:I3({layer:"bottom",layer_type:"soldermask"}),B_Paste:I3({layer:"bottom",layer_type:"paste"}),Edge_Cuts:I3({layer:"edgecut"})};for(const o of["F_Cu","B_Cu","F_Mask","B_Mask","F_Paste","B_Paste","F_SilkScreen","B_SilkScreen"]){const s=n[o];TKn(s),AKn({soup:t,glayer:s,glayer_name:o})}n.Edge_Cuts.push(...Ky().add("define_aperture_template",{aperture_number:10,standard_template_code:"C",diameter:.05}).build());const i=o=>e.flip_y_axis?-o:o,r=new Map;for(const o of t)if(o.type==="pcb_plated_hole"&&"x"in o&&typeof o.x=="number"&&"y"in o&&typeof o.y=="number"){const s="ccw_rotation"in o&&typeof o.ccw_rotation=="number"?o.ccw_rotation:0;r.set(`${o.x}:${o.y}`,s)}for(const o of["top","bottom","edgecut"])for(const s of t)if(s.type==="pcb_trace"){const{route:a}=s;for(const[c,l]of EKn(a))if(c.route_type==="wire"&&c.layer===o){const u=n[k5(o,"copper")];u.push(...Ky().add("select_aperture",{aperture_number:P3(u,{trace_width:c.width})}).add("move_operation",{x:c.x,y:i(c.y)}).add("plot_operation",{x:l.x,y:i(l.y)}).build())}}else if(s.type==="pcb_silkscreen_path"){if(s.layer===o){const a=n[k5(o,"silkscreen")],c=yft(s),l=Ky().add("select_aperture",{aperture_number:P3(a,c)});s.route.length>0&&l.add("move_operation",{x:s.route[0].x,y:i(s.route[0].y)});for(let u=1;u<s.route.length;u++)l.add("plot_operation",{x:s.route[u].x,y:i(s.route[u].y)});a.push(...l.build())}}else if(s.type==="pcb_silkscreen_text"){if(s.layer===o){const c=n[k5(o,"silkscreen")],l=gft(s),u=Ky().add("select_aperture",{aperture_number:P3(c,l)});let d=s.anchor_position.x,h=s.anchor_position.y;const f=s.font_size*.7,m=f*.4,y=f*.5,g=s.text.split("").reduce((I,A)=>A===" "?I+y+m:I+f+m,0)-m,b=f;switch(s.anchor_alignment||(()=>{const I=s.anchor_side;if(I)switch(I){case"top":return"top_center";case"bottom":return"bottom_center";case"left":return"center_left";case"right":return"center_right"}})()||"center"){case"top_left":break;case"top_center":d-=g/2;break;case"top_right":d-=g;break;case"center_right":h-=b/2;break;case"center_left":d-=g,h-=b/2;break;case"bottom_left":h-=b;break;case"bottom_center":d-=g/2,h-=b;break;case"bottom_right":d-=g,h-=b;break;default:d-=g/2,h-=b/2;break}let w=d;const T=h;let N=s.ccw_rotation||0;const R=w+g/2,P=T+b/2,M=[];if(s.layer==="bottom"&&(M.push(g7(R,P),{a:-1,b:0,c:0,d:1,e:0,f:0},g7(-R,-P)),N=-N),N){const I=N*Math.PI/180;M.push(g7(R,P),N2e(I),g7(-R,-P))}for(const I of s.text.toUpperCase()){if(I===" "){w+=y+m;continue}const A=P2e[I]||[];for(const $ of A){const k=w+$.x1*f,V=T+$.y1*f,X=w+$.x2*f,W=T+$.y2*f;let K={x:k,y:V},ee={x:X,y:W};if(M.length>0){const se=I2e(...M);K=RX(se,K),ee=RX(se,ee)}u.add("move_operation",{x:K.x,y:i(K.y)}),u.add("plot_operation",{x:ee.x,y:i(ee.y)})}w+=f+m}c.push(...u.build())}}else if(s.type==="pcb_smtpad"&&s.shape!=="polygon"){if(s.layer===o)for(const a of[n[k5(o,"copper")],n[k5(o,"soldermask")]]){const c=_ft(s),l=P3(a,c),u=Ky().add("select_aperture",{aperture_number:l});s.shape==="rotated_rect"&&s.ccw_rotation&&u.add("load_rotation",{rotation_degrees:s.ccw_rotation}),u.add("flash_operation",{x:s.x,y:i(s.y)}),s.shape==="rotated_rect"&&s.ccw_rotation&&u.add("load_rotation",{rotation_degrees:0}),a.push(...u.build())}}else if(s.type==="pcb_solder_paste"){if(s.layer===o){const a=n[k5(o,"paste")],c=P3(a,bft(s)),l="ccw_rotation"in s&&typeof s.ccw_rotation=="number"?s.ccw_rotation:r.get(`${s.x}:${s.y}`)??0,u=Ky().add("select_aperture",{aperture_number:c});l&&u.add("load_rotation",{rotation_degrees:l}),u.add("flash_operation",{x:s.x,y:i(s.y)}),l&&u.add("load_rotation",{rotation_degrees:0}),a.push(...u.build())}}else if(s.type==="pcb_plated_hole"){if(s.layers.includes(o))for(const a of[n[k5(o,"copper")],n[k5(o,"soldermask")]]){const c="hole_width"in s&&typeof s.hole_width=="number"?s.hole_width:0,l="hole_height"in s&&typeof s.hole_height=="number"?s.hole_height:0,u=[c];"outer_width"in s&&typeof s.outer_width=="number"&&u.push(s.outer_width),"rect_pad_width"in s&&typeof s.rect_pad_width=="number"&&u.push(s.rect_pad_width);const d=Math.max(...u),h=[l];"outer_height"in s&&typeof s.outer_height=="number"&&h.push(s.outer_height),"rect_pad_height"in s&&typeof s.rect_pad_height=="number"&&h.push(s.rect_pad_height);const f=Math.max(...h);if(s.shape==="pill"){const m={standard_template_code:"C",diameter:Math.min(d,f)};let y;try{y=P3(a,m)}catch{y=Math.max(...a.filter(P=>"aperture_number"in P).map(P=>P.aperture_number),9)+1,a.push(...Ky().add("define_aperture_template",{aperture_number:y,...m}).build())}const g=Ky().add("select_aperture",{aperture_number:y}),b=(s.ccw_rotation??0)*Math.PI/180,v=Math.cos(b),w=Math.sin(b),T=(P,M)=>{const I=P*v-M*w,A=P*w+M*v;return{x:s.x+I,y:s.y+A}},N=d>=f,R=N?(d-f)/2:(f-d)/2;if(R<=0){const P=T(0,0);g.add("flash_operation",{x:P.x,y:i(P.y)})}else{const P=N?{x:-R,y:0}:{x:0,y:-R},M=N?{x:R,y:0}:{x:0,y:R},I=T(P.x,P.y),A=T(M.x,M.y);g.add("flash_operation",{x:I.x,y:i(I.y)}).add("move_operation",{x:I.x,y:i(I.y)}).add("plot_operation",{x:A.x,y:i(A.y)}).add("flash_operation",{x:A.x,y:i(A.y)})}a.push(...g.build())}else{const m=xft({...s,...s.shape!=="circle"?{outer_width:d,outer_height:f}:{}}),y="rect_ccw_rotation"in s&&typeof s.rect_ccw_rotation=="number"?s.rect_ccw_rotation:void 0,g=Ky().add("select_aperture",{aperture_number:P3(a,m)});y&&g.add("load_rotation",{rotation_degrees:y}),g.add("flash_operation",{x:s.x,y:i(s.y)}),y&&g.add("load_rotation",{rotation_degrees:0}),a.push(...g.build())}}}else if(s.type==="pcb_hole"){if(o!=="edgecut")for(const a of[n[k5(o,"soldermask")]]){if(s.hole_shape!=="circle"){console.warn("NOT IMPLEMENTED: drawing gerber for non-round holes");continue}a.push(...Ky().add("select_aperture",{aperture_number:P3(a,vft(s))}).add("flash_operation",{x:s.x,y:i(s.y)}).build())}}else if(s.type==="pcb_via"){if(s.layers.includes(o))for(const a of[n[k5(o,"copper")]])a.push(...Ky().add("select_aperture",{aperture_number:P3(a,wft(s))}).add("flash_operation",{x:s.x,y:i(s.y)}).build())}else if(s.type==="pcb_board"&&o==="edgecut"){const a=n.Edge_Cuts,{width:c,height:l,center:u,outline:d}=s,h=Ky().add("select_aperture",{aperture_number:10});if(d&&d.length>2){h.add("move_operation",d[0]);for(let f=1;f<d.length;f++)h.add("plot_operation",d[f])}else h.add("move_operation",{x:u.x-c/2,y:i(u.y-l/2)}).add("plot_operation",{x:u.x+c/2,y:i(u.y-l/2)}).add("plot_operation",{x:u.x+c/2,y:i(u.y+l/2)}).add("plot_operation",{x:u.x-c/2,y:i(u.y+l/2)}).add("plot_operation",{x:u.x-c/2,y:i(u.y-l/2)});a.push(...h.build())}else if(s.type==="pcb_cutout"){if(o==="edgecut"){const a=n.Edge_Cuts,c=Ky().add("select_aperture",{aperture_number:10}),l=s;if(l.shape==="rect"){const{center:u,width:d,height:h,rotation:f}=l,m=d/2,y=h/2,g=[{x:-m,y},{x:m,y},{x:m,y:-y},{x:-m,y:-y}];let b=dft();if(f){const w=f*Math.PI/180;b=N2e(w)}b=I2e(g7(u.x,u.y),b);const v=g.map(w=>RX(b,w));c.add("move_operation",{x:v[0].x,y:i(v[0].y)});for(let w=1;w<v.length;w++)c.add("plot_operation",{x:v[w].x,y:i(v[w].y)});c.add("plot_operation",{x:v[0].x,y:i(v[0].y)})}else if(l.shape==="circle"){const{center:u,radius:d}=l,h={x:u.x+d,y:u.y},f={x:u.x-d,y:u.y};c.add("move_operation",{x:h.x,y:i(h.y)}).add("set_movement_mode_to_counterclockwise_circular",{}).add("plot_operation",{x:f.x,y:i(f.y),i:-d,j:0}).add("plot_operation",{x:h.x,y:i(h.y),i:d,j:0}).add("set_movement_mode_to_linear",{})}else if(l.shape==="polygon"){const{points:u}=l;if(u.length>0){c.add("move_operation",{x:u[0].x,y:i(u[0].y)});for(let d=1;d<u.length;d++)c.add("plot_operation",{x:u[d].x,y:i(u[d].y)});c.add("plot_operation",{x:u[0].x,y:i(u[0].y)})}}a.push(...c.build())}}else if(s.type==="pcb_copper_pour"&&o===s.layer){const a=n[k5(o,"copper")],c=Ky().add("select_aperture",{aperture_number:10}).add("start_region_statement",{});if(s.shape==="brep"){const{brep_shape:l}=s;if(!l)continue;const{outer_ring:u,inner_rings:d}=l,h=m=>{if(!m||m.vertices.length===0)return;c.add("move_operation",{x:m.vertices[0].x,y:i(m.vertices[0].y)});const y=[...m.vertices,m.vertices[0]];for(let g=0;g<y.length-1;g++){const b=y[g],v=y[g+1];if(b.bulge&&Math.abs(b.bulge)>1e-9){const w=(e.flip_y_axis?-1:1)*b.bulge;w>0?c.add("set_movement_mode_to_counterclockwise_circular",{}):c.add("set_movement_mode_to_clockwise_circular",{});const T={x:b.x,y:b.y},N={x:v.x,y:v.y},R=N.x-T.x,P=N.y-T.y,M=Math.sqrt(R*R+P*P);if(M<1e-9){c.add("set_movement_mode_to_linear",{}),c.add("plot_operation",{x:v.x,y:i(v.y)});continue}const I=Math.abs(w),A=4*Math.atan(I);if(Math.abs(Math.sin(A/2))<1e-9){c.add("set_movement_mode_to_linear",{}),c.add("plot_operation",{x:v.x,y:i(v.y)});continue}const $=M/(2*Math.sin(A/2)),k=(Math.PI-A)/2,V=Math.atan2(P,R),X=w>0?k:-k,W=V+X,K=T.x+$*Math.cos(W),ee=T.y+$*Math.sin(W),se=K-T.x,de=ee-T.y;c.add("plot_operation",{x:v.x,y:i(v.y),i:se,j:e.flip_y_axis?-de:de})}else c.add("set_movement_mode_to_linear",{}),c.add("plot_operation",{x:v.x,y:i(v.y)})}},f=m=>{const{vertices:y}=m;if(!y||y.length===0)return{vertices:[]};const g=y.length;return{vertices:[...y].reverse().map((w,T)=>{const N=(g-2-T+g)%g,R=y[N].bulge;return{...w,bulge:R?-R:void 0}})}};if(h(f(u)),d)for(const m of d)h(f(m))}else if(s.shape==="rect"){const{center:l,width:u,height:d,rotation:h}=s,f=u/2,m=d/2,y=[{x:-f,y:m},{x:f,y:m},{x:f,y:-m},{x:-f,y:-m}];let g=dft();if(h){const v=h*Math.PI/180;g=N2e(v)}g=I2e(g7(l.x,l.y),g);const b=y.map(v=>RX(g,v));c.add("move_operation",{x:b[0].x,y:i(b[0].y)});for(let v=1;v<b.length;v++)c.add("plot_operation",{x:b[v].x,y:i(b[v].y)});c.add("plot_operation",{x:b[0].x,y:i(b[0].y)})}else if(s.shape==="polygon"){const{points:l}=s;if(l.length>0){c.add("move_operation",{x:l[0].x,y:i(l[0].y)});for(let u=1;u<l.length;u++)c.add("plot_operation",{x:l[u].x,y:i(l[u].y)});c.add("plot_operation",{x:l[0].x,y:i(l[0].y)})}}c.add("end_region_statement",{}),a.push(...c.build())}for(const o of Object.keys(n))n[o].push(...Ky().add("end_of_file",{}).build());return n},Wk={},k2e={},Sft;function OKn(){return Sft||(Sft=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0});var e=(function(){function o(s,a){var c=[],l=!0,u=!1,d=void 0;try{for(var h=s[Symbol.iterator](),f;!(l=(f=h.next()).done)&&(c.push(f.value),!(a&&c.length===a));l=!0);}catch(m){u=!0,d=m}finally{try{!l&&h.return&&h.return()}finally{if(u)throw d}}return c}return function(s,a){if(Array.isArray(s))return s;if(Symbol.iterator in Object(s))return o(s,a);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})();t.default=i,t.parseUnitObj=r;var n=/-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/;function i(o){var s=parseFloat(o),a=o.match(n)||[],c=a.length>0?o.substr(a[0].length).trim():"";return[s,c]}function r(o){var s=i(o),a=e(s,2),c=a[0],l=a[1];return{val:c,unit:l}}})(k2e)),k2e}var Eft;function LKn(){if(Eft)return Wk;Eft=1,Object.defineProperty(Wk,"__esModule",{value:!0});var t=(function(){function c(l,u){var d=[],h=!0,f=!1,m=void 0;try{for(var y=l[Symbol.iterator](),g;!(h=(g=y.next()).done)&&(d.push(g.value),!(u&&d.length===u));h=!0);}catch(b){f=!0,m=b}finally{try{!h&&y.return&&y.return()}finally{if(f)throw m}}return d}return function(l,u){if(Array.isArray(l))return l;if(Symbol.iterator in Object(l))return c(l,u);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})();Wk.formatSI=o,Wk.unformatSI=a;function e(c){return c&&c.__esModule?c:{default:c}}var n=OKn(),i=e(n),r={24:"Y",21:"Z",18:"E",15:"P",12:"T",9:"G",6:"M",3:"k",0:"","-3":"m","-6":"µ","-9":"n","-12":"p","-15":"f","-18":"a","-21":"z","-24":"y"};function o(c){if(c===0)return"0";for(var l=Math.abs(c),u=0;l>=1e3&&u<24;)l/=1e3,u+=3;for(;l<1&&u>-24;)l*=1e3,u-=3;var d=c<0?"-":"";return l>1e3?d+l.toFixed(0)+r[u]:d+parseFloat(l.toPrecision(3))+r[u]}var s={Y:1e24,Z:1e21,E:1e18,P:1e15,T:1e12,G:1e9,M:1e6,k:1e3,"":1,m:.001,µ:1e-6,u:1e-6,n:1e-9,p:1e-12,f:1e-15,a:1e-18,z:1e-21,y:1e-24};function a(c){if(c==null||c==="")return NaN;var l=(0,i.default)(c),u=t(l,2),d=u[0],h=u[1],f=s[h];return d*f}return Wk}var DKn=LKn(),PX={exports:{}};/* @license
6602
6602
  Papa Parse
6603
6603
  v5.5.3
6604
6604
  https://github.com/mholt/PapaParse