vibeman 0.0.0 → 0.0.1
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.
- package/README.md +12 -0
- package/dist/index.js +116 -0
- package/dist/runtime/api/.tsbuildinfo +1 -0
- package/dist/runtime/api/agent/agent-service.d.ts +226 -0
- package/dist/runtime/api/agent/agent-service.js +901 -0
- package/dist/runtime/api/agent/ai-providers/claude-code-adapter.d.ts +61 -0
- package/dist/runtime/api/agent/ai-providers/claude-code-adapter.js +373 -0
- package/dist/runtime/api/agent/ai-providers/codex-cli-provider.d.ts +34 -0
- package/dist/runtime/api/agent/ai-providers/codex-cli-provider.js +281 -0
- package/dist/runtime/api/agent/ai-providers/index.d.ts +9 -0
- package/dist/runtime/api/agent/ai-providers/index.js +7 -0
- package/dist/runtime/api/agent/ai-providers/types.d.ts +180 -0
- package/dist/runtime/api/agent/ai-providers/types.js +5 -0
- package/dist/runtime/api/agent/codex-cli-provider.test.d.ts +1 -0
- package/dist/runtime/api/agent/codex-cli-provider.test.js +88 -0
- package/dist/runtime/api/agent/core-agent-service.d.ts +119 -0
- package/dist/runtime/api/agent/core-agent-service.js +267 -0
- package/dist/runtime/api/agent/parsers.d.ts +15 -0
- package/dist/runtime/api/agent/parsers.js +241 -0
- package/dist/runtime/api/agent/prompt-service.d.ts +17 -0
- package/dist/runtime/api/agent/prompt-service.js +340 -0
- package/dist/runtime/api/agent/routing-policy.d.ts +188 -0
- package/dist/runtime/api/agent/routing-policy.js +246 -0
- package/dist/runtime/api/api/router-helpers.d.ts +32 -0
- package/dist/runtime/api/api/router-helpers.js +31 -0
- package/dist/runtime/api/api/routers/ai.d.ts +188 -0
- package/dist/runtime/api/api/routers/ai.js +410 -0
- package/dist/runtime/api/api/routers/executions.d.ts +98 -0
- package/dist/runtime/api/api/routers/executions.js +103 -0
- package/dist/runtime/api/api/routers/git.d.ts +45 -0
- package/dist/runtime/api/api/routers/git.js +35 -0
- package/dist/runtime/api/api/routers/settings.d.ts +139 -0
- package/dist/runtime/api/api/routers/settings.js +113 -0
- package/dist/runtime/api/api/routers/tasks.d.ts +141 -0
- package/dist/runtime/api/api/routers/tasks.js +238 -0
- package/dist/runtime/api/api/routers/workflows.d.ts +268 -0
- package/dist/runtime/api/api/routers/workflows.js +308 -0
- package/dist/runtime/api/api/routers/worktrees.d.ts +102 -0
- package/dist/runtime/api/api/routers/worktrees.js +80 -0
- package/dist/runtime/api/api/trpc.d.ts +118 -0
- package/dist/runtime/api/api/trpc.js +34 -0
- package/dist/runtime/api/index.d.ts +9 -0
- package/dist/runtime/api/index.js +125 -0
- package/dist/runtime/api/lib/id-generator.d.ts +70 -0
- package/dist/runtime/api/lib/id-generator.js +123 -0
- package/dist/runtime/api/lib/image-paste-drop-extension.d.ts +26 -0
- package/dist/runtime/api/lib/image-paste-drop-extension.js +125 -0
- package/dist/runtime/api/lib/logger.d.ts +11 -0
- package/dist/runtime/api/lib/logger.js +188 -0
- package/dist/runtime/api/lib/markdown-utils.d.ts +8 -0
- package/dist/runtime/api/lib/markdown-utils.js +282 -0
- package/dist/runtime/api/lib/markdown-utils.test.d.ts +1 -0
- package/dist/runtime/api/lib/markdown-utils.test.js +348 -0
- package/dist/runtime/api/lib/server/agent-service-singleton.d.ts +6 -0
- package/dist/runtime/api/lib/server/agent-service-singleton.js +27 -0
- package/dist/runtime/api/lib/server/git-service-singleton.d.ts +6 -0
- package/dist/runtime/api/lib/server/git-service-singleton.js +47 -0
- package/dist/runtime/api/lib/server/project-root.d.ts +2 -0
- package/dist/runtime/api/lib/server/project-root.js +38 -0
- package/dist/runtime/api/lib/server/task-service-singleton.d.ts +7 -0
- package/dist/runtime/api/lib/server/task-service-singleton.js +58 -0
- package/dist/runtime/api/lib/server/vibing-orchestrator-singleton.d.ts +7 -0
- package/dist/runtime/api/lib/server/vibing-orchestrator-singleton.js +57 -0
- package/dist/runtime/api/lib/tiptap-utils.clamp-selection.test.d.ts +1 -0
- package/dist/runtime/api/lib/tiptap-utils.clamp-selection.test.js +27 -0
- package/dist/runtime/api/lib/tiptap-utils.d.ts +130 -0
- package/dist/runtime/api/lib/tiptap-utils.js +327 -0
- package/dist/runtime/api/lib/trpc/client.d.ts +1 -0
- package/dist/runtime/api/lib/trpc/client.js +5 -0
- package/dist/runtime/api/lib/trpc/server.d.ts +822 -0
- package/dist/runtime/api/lib/trpc/server.js +11 -0
- package/dist/runtime/api/lib/trpc/ws-server.d.ts +8 -0
- package/dist/runtime/api/lib/trpc/ws-server.js +33 -0
- package/dist/runtime/api/persistence/database-service.d.ts +14 -0
- package/dist/runtime/api/persistence/database-service.js +74 -0
- package/dist/runtime/api/persistence/execution-log-persistence.d.ts +90 -0
- package/dist/runtime/api/persistence/execution-log-persistence.js +410 -0
- package/dist/runtime/api/persistence/execution-log-persistence.test.d.ts +1 -0
- package/dist/runtime/api/persistence/execution-log-persistence.test.js +170 -0
- package/dist/runtime/api/router.d.ts +825 -0
- package/dist/runtime/api/router.js +56 -0
- package/dist/runtime/api/settings-service.d.ts +110 -0
- package/dist/runtime/api/settings-service.js +611 -0
- package/dist/runtime/api/tasks/file-watcher.d.ts +23 -0
- package/dist/runtime/api/tasks/file-watcher.js +88 -0
- package/dist/runtime/api/tasks/task-file-parser.d.ts +13 -0
- package/dist/runtime/api/tasks/task-file-parser.js +161 -0
- package/dist/runtime/api/tasks/task-service.d.ts +36 -0
- package/dist/runtime/api/tasks/task-service.js +173 -0
- package/dist/runtime/api/types/index.d.ts +179 -0
- package/dist/runtime/api/types/index.js +1 -0
- package/dist/runtime/api/types/settings.d.ts +81 -0
- package/dist/runtime/api/types/settings.js +2 -0
- package/dist/runtime/api/types.d.ts +2 -0
- package/dist/runtime/api/types.js +1 -0
- package/dist/runtime/api/utils/env.d.ts +6 -0
- package/dist/runtime/api/utils/env.js +12 -0
- package/dist/runtime/api/utils/stripNextEnv.d.ts +7 -0
- package/dist/runtime/api/utils/stripNextEnv.js +22 -0
- package/dist/runtime/api/utils/title-slug.d.ts +6 -0
- package/dist/runtime/api/utils/title-slug.js +77 -0
- package/dist/runtime/api/utils/url.d.ts +2 -0
- package/dist/runtime/api/utils/url.js +19 -0
- package/dist/runtime/api/vcs/git-history-service.d.ts +57 -0
- package/dist/runtime/api/vcs/git-history-service.js +228 -0
- package/dist/runtime/api/vcs/git-service.d.ts +127 -0
- package/dist/runtime/api/vcs/git-service.js +284 -0
- package/dist/runtime/api/vcs/worktree-service.d.ts +93 -0
- package/dist/runtime/api/vcs/worktree-service.js +506 -0
- package/dist/runtime/api/vcs/worktree-service.test.d.ts +1 -0
- package/dist/runtime/api/vcs/worktree-service.test.js +20 -0
- package/dist/runtime/api/workflows/quality-pipeline.d.ts +58 -0
- package/dist/runtime/api/workflows/quality-pipeline.js +400 -0
- package/dist/runtime/api/workflows/vibing-orchestrator.d.ts +313 -0
- package/dist/runtime/api/workflows/vibing-orchestrator.js +1861 -0
- package/dist/runtime/web/.next/BUILD_ID +1 -0
- package/dist/runtime/web/.next/app-build-manifest.json +59 -0
- package/dist/runtime/web/.next/app-path-routes-manifest.json +7 -0
- package/dist/runtime/web/.next/build-manifest.json +33 -0
- package/dist/runtime/web/.next/package.json +1 -0
- package/dist/runtime/web/.next/prerender-manifest.json +61 -0
- package/dist/runtime/web/.next/react-loadable-manifest.json +39 -0
- package/dist/runtime/web/.next/required-server-files.json +334 -0
- package/dist/runtime/web/.next/routes-manifest.json +62 -0
- package/dist/runtime/web/.next/server/app/_not-found/page.js +2 -0
- package/dist/runtime/web/.next/server/app/_not-found/page.js.nft.json +1 -0
- package/dist/runtime/web/.next/server/app/_not-found/page_client-reference-manifest.js +1 -0
- package/dist/runtime/web/.next/server/app/_not-found.html +7 -0
- package/dist/runtime/web/.next/server/app/_not-found.meta +8 -0
- package/dist/runtime/web/.next/server/app/_not-found.rsc +22 -0
- package/dist/runtime/web/.next/server/app/api/health/route.js +1 -0
- package/dist/runtime/web/.next/server/app/api/health/route.js.nft.json +1 -0
- package/dist/runtime/web/.next/server/app/api/health/route_client-reference-manifest.js +1 -0
- package/dist/runtime/web/.next/server/app/api/images/[...path]/route.js +1 -0
- package/dist/runtime/web/.next/server/app/api/images/[...path]/route.js.nft.json +1 -0
- package/dist/runtime/web/.next/server/app/api/images/[...path]/route_client-reference-manifest.js +1 -0
- package/dist/runtime/web/.next/server/app/api/upload/route.js +1 -0
- package/dist/runtime/web/.next/server/app/api/upload/route.js.nft.json +1 -0
- package/dist/runtime/web/.next/server/app/api/upload/route_client-reference-manifest.js +1 -0
- package/dist/runtime/web/.next/server/app/index.html +7 -0
- package/dist/runtime/web/.next/server/app/index.meta +7 -0
- package/dist/runtime/web/.next/server/app/index.rsc +27 -0
- package/dist/runtime/web/.next/server/app/page.js +147 -0
- package/dist/runtime/web/.next/server/app/page.js.nft.json +1 -0
- package/dist/runtime/web/.next/server/app/page_client-reference-manifest.js +1 -0
- package/dist/runtime/web/.next/server/app-paths-manifest.json +7 -0
- package/dist/runtime/web/.next/server/chunks/217.js +1 -0
- package/dist/runtime/web/.next/server/chunks/383.js +6 -0
- package/dist/runtime/web/.next/server/chunks/458.js +1 -0
- package/dist/runtime/web/.next/server/chunks/576.js +18 -0
- package/dist/runtime/web/.next/server/chunks/635.js +22 -0
- package/dist/runtime/web/.next/server/chunks/761.js +1 -0
- package/dist/runtime/web/.next/server/chunks/777.js +3 -0
- package/dist/runtime/web/.next/server/chunks/825.js +1 -0
- package/dist/runtime/web/.next/server/chunks/838.js +1 -0
- package/dist/runtime/web/.next/server/chunks/973.js +15 -0
- package/dist/runtime/web/.next/server/functions-config-manifest.json +4 -0
- package/dist/runtime/web/.next/server/middleware-build-manifest.js +1 -0
- package/dist/runtime/web/.next/server/middleware-manifest.json +6 -0
- package/dist/runtime/web/.next/server/middleware-react-loadable-manifest.js +1 -0
- package/dist/runtime/web/.next/server/next-font-manifest.js +1 -0
- package/dist/runtime/web/.next/server/next-font-manifest.json +1 -0
- package/dist/runtime/web/.next/server/pages/404.html +7 -0
- package/dist/runtime/web/.next/server/pages/500.html +1 -0
- package/dist/runtime/web/.next/server/pages/_app.js +1 -0
- package/dist/runtime/web/.next/server/pages/_app.js.nft.json +1 -0
- package/dist/runtime/web/.next/server/pages/_document.js +1 -0
- package/dist/runtime/web/.next/server/pages/_document.js.nft.json +1 -0
- package/dist/runtime/web/.next/server/pages/_error.js +19 -0
- package/dist/runtime/web/.next/server/pages/_error.js.nft.json +1 -0
- package/dist/runtime/web/.next/server/pages-manifest.json +6 -0
- package/dist/runtime/web/.next/server/server-reference-manifest.js +1 -0
- package/dist/runtime/web/.next/server/server-reference-manifest.json +1 -0
- package/dist/runtime/web/.next/server/webpack-runtime.js +1 -0
- package/dist/runtime/web/.next/static/1HR8N0rJkCvFRtbTPJMyH/_buildManifest.js +1 -0
- package/dist/runtime/web/.next/static/1HR8N0rJkCvFRtbTPJMyH/_ssgManifest.js +1 -0
- package/dist/runtime/web/.next/static/chunks/18-15c10d3288afef2e.js +1 -0
- package/dist/runtime/web/.next/static/chunks/1c0ca389.537bbe362e3ffbd9.js +3 -0
- package/dist/runtime/web/.next/static/chunks/22747d63-ad5da0c19f4cfe41.js +71 -0
- package/dist/runtime/web/.next/static/chunks/277-0142a939f08738c3.js +63 -0
- package/dist/runtime/web/.next/static/chunks/355.056c2645878a799a.js +1 -0
- package/dist/runtime/web/.next/static/chunks/420.a5ccf151c9e2b2f1.js +1 -0
- package/dist/runtime/web/.next/static/chunks/439.1be0c6242fd248d5.js +15 -0
- package/dist/runtime/web/.next/static/chunks/440.c52e7c0f797e22b2.js +1 -0
- package/dist/runtime/web/.next/static/chunks/575-e2478287c27da87b.js +1 -0
- package/dist/runtime/web/.next/static/chunks/691.920d88c115087314.js +1 -0
- package/dist/runtime/web/.next/static/chunks/765-e838910065b50c3d.js +1 -0
- package/dist/runtime/web/.next/static/chunks/87c73c54-09e1ba5c70e60a51.js +1 -0
- package/dist/runtime/web/.next/static/chunks/891cff7f.0f71fc028f87e683.js +1 -0
- package/dist/runtime/web/.next/static/chunks/8bb4d8db-3e2aa02b0a2384b9.js +1 -0
- package/dist/runtime/web/.next/static/chunks/9af238c7-271a911d4e99ab18.js +1 -0
- package/dist/runtime/web/.next/static/chunks/app/_not-found/page-1cb74d1cba27d0ab.js +1 -0
- package/dist/runtime/web/.next/static/chunks/app/api/health/route-105a61ae865ba536.js +1 -0
- package/dist/runtime/web/.next/static/chunks/app/api/images/[...path]/route-105a61ae865ba536.js +1 -0
- package/dist/runtime/web/.next/static/chunks/app/api/upload/route-105a61ae865ba536.js +1 -0
- package/dist/runtime/web/.next/static/chunks/app/layout-dc0cfd29075b2160.js +1 -0
- package/dist/runtime/web/.next/static/chunks/app/page-f34a8b196b18850b.js +1 -0
- package/dist/runtime/web/.next/static/chunks/cac567b0-5b77dd12911823cd.js +1 -0
- package/dist/runtime/web/.next/static/chunks/framework-2518f1345b5b2806.js +1 -0
- package/dist/runtime/web/.next/static/chunks/main-17665e5e39de9a8a.js +1 -0
- package/dist/runtime/web/.next/static/chunks/main-app-c0b0f5ba4f7f9d75.js +1 -0
- package/dist/runtime/web/.next/static/chunks/pages/_app-d6f6b3bbc3d81ee1.js +1 -0
- package/dist/runtime/web/.next/static/chunks/pages/_error-75a96cf1997cc3b9.js +1 -0
- package/dist/runtime/web/.next/static/chunks/polyfills-42372ed130431b0a.js +1 -0
- package/dist/runtime/web/.next/static/chunks/webpack-c8de37305b4635cf.js +1 -0
- package/dist/runtime/web/.next/static/css/08c950681f1a9a92.css +1 -0
- package/dist/runtime/web/.next/static/css/2728291c68f99cb1.css +3 -0
- package/dist/runtime/web/.next/static/css/521bd69cc298cd1a.css +1 -0
- package/dist/runtime/web/.next/static/css/537e22821e101b87.css +1 -0
- package/dist/runtime/web/.next/static/media/19cfc7226ec3afaa-s.woff2 +0 -0
- package/dist/runtime/web/.next/static/media/21350d82a1f187e9-s.woff2 +0 -0
- package/dist/runtime/web/.next/static/media/8e9860b6e62d6359-s.woff2 +0 -0
- package/dist/runtime/web/.next/static/media/ba9851c3c22cd980-s.woff2 +0 -0
- package/dist/runtime/web/.next/static/media/c5fe6dc8356a8c31-s.woff2 +0 -0
- package/dist/runtime/web/.next/static/media/df0a9ae256c0569c-s.woff2 +0 -0
- package/dist/runtime/web/.next/static/media/e4af272ccee01ff0-s.p.woff2 +0 -0
- package/dist/runtime/web/package.json +65 -0
- package/dist/runtime/web/server.js +44 -0
- package/dist/tsconfig.tsbuildinfo +1 -0
- package/package.json +80 -7
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[355],{79355:e=>{self,e.exports=(()=>{"use strict";var e={};return Object.defineProperty(e,"__esModule",{value:!0}),e.FitAddon=void 0,e.FitAddon=class{activate(e){this._terminal=e}dispose(){}fit(){let e=this.proposeDimensions();if(!e||!this._terminal||isNaN(e.cols)||isNaN(e.rows))return;let t=this._terminal._core;this._terminal.rows===e.rows&&this._terminal.cols===e.cols||(t._renderService.clear(),this._terminal.resize(e.cols,e.rows))}proposeDimensions(){if(!this._terminal||!this._terminal.element||!this._terminal.element.parentElement)return;let e=this._terminal._core,t=e._renderService.dimensions;if(0===t.css.cell.width||0===t.css.cell.height)return;let r=0===this._terminal.options.scrollback?0:e.viewport.scrollBarWidth,i=window.getComputedStyle(this._terminal.element.parentElement),s=parseInt(i.getPropertyValue("height")),l=Math.max(0,parseInt(i.getPropertyValue("width"))),n=window.getComputedStyle(this._terminal.element),a=s-(parseInt(n.getPropertyValue("padding-top"))+parseInt(n.getPropertyValue("padding-bottom")));return{cols:Math.max(2,Math.floor((l-(parseInt(n.getPropertyValue("padding-right"))+parseInt(n.getPropertyValue("padding-left")))-r)/t.css.cell.width)),rows:Math.max(1,Math.floor(a/t.css.cell.height))}}},e})()}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[420],{3063:t=>{var e="/";!function(){var r={675:function(t,e){"use strict";e.byteLength=f,e.toByteArray=c,e.fromByteArray=y;for(var r=[],n=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,s=i.length;a<s;++a)r[a]=i[a],n[i.charCodeAt(a)]=a;function u(t){var e=t.length;if(e%4>0)throw Error("Invalid string. Length must be a multiple of 4");var r=t.indexOf("=");-1===r&&(r=e);var n=r===e?0:4-r%4;return[r,n]}function f(t){var e=u(t),r=e[0],n=e[1];return(r+n)*3/4-n}function l(t,e,r){return(e+r)*3/4-r}function c(t){var e,r,i=u(t),a=i[0],s=i[1],f=new o(l(t,a,s)),c=0,p=s>0?a-4:a;for(r=0;r<p;r+=4)e=n[t.charCodeAt(r)]<<18|n[t.charCodeAt(r+1)]<<12|n[t.charCodeAt(r+2)]<<6|n[t.charCodeAt(r+3)],f[c++]=e>>16&255,f[c++]=e>>8&255,f[c++]=255&e;return 2===s&&(e=n[t.charCodeAt(r)]<<2|n[t.charCodeAt(r+1)]>>4,f[c++]=255&e),1===s&&(e=n[t.charCodeAt(r)]<<10|n[t.charCodeAt(r+1)]<<4|n[t.charCodeAt(r+2)]>>2,f[c++]=e>>8&255,f[c++]=255&e),f}function p(t){return r[t>>18&63]+r[t>>12&63]+r[t>>6&63]+r[63&t]}function h(t,e,r){for(var n=[],o=e;o<r;o+=3)n.push(p((t[o]<<16&0xff0000)+(t[o+1]<<8&65280)+(255&t[o+2])));return n.join("")}function y(t){for(var e,n=t.length,o=n%3,i=[],a=16383,s=0,u=n-o;s<u;s+=a)i.push(h(t,s,s+a>u?u:s+a));return 1===o?i.push(r[(e=t[n-1])>>2]+r[e<<4&63]+"=="):2===o&&i.push(r[(e=(t[n-2]<<8)+t[n-1])>>10]+r[e>>4&63]+r[e<<2&63]+"="),i.join("")}n[45]=62,n[95]=63},72:function(t,e,r){"use strict";var n=r(675),o=r(783),i="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;e.Buffer=f,e.SlowBuffer=m,e.INSPECT_MAX_BYTES=50;var a=0x7fffffff;function s(){try{var t=new Uint8Array(1),e={foo:function(){return 42}};return Object.setPrototypeOf(e,Uint8Array.prototype),Object.setPrototypeOf(t,e),42===t.foo()}catch(t){return!1}}function u(t){if(t>a)throw RangeError('The value "'+t+'" is invalid for option "size"');var e=new Uint8Array(t);return Object.setPrototypeOf(e,f.prototype),e}function f(t,e,r){if("number"==typeof t){if("string"==typeof e)throw TypeError('The "string" argument must be of type string. Received type number');return h(t)}return l(t,e,r)}function l(t,e,r){if("string"==typeof t)return y(t,e);if(ArrayBuffer.isView(t))return d(t);if(null==t)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t);if(Z(t,ArrayBuffer)||t&&Z(t.buffer,ArrayBuffer)||"undefined"!=typeof SharedArrayBuffer&&(Z(t,SharedArrayBuffer)||t&&Z(t.buffer,SharedArrayBuffer)))return g(t,e,r);if("number"==typeof t)throw TypeError('The "value" argument must not be of type number. Received type number');var n=t.valueOf&&t.valueOf();if(null!=n&&n!==t)return f.from(n,e,r);var o=b(t);if(o)return o;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof t[Symbol.toPrimitive])return f.from(t[Symbol.toPrimitive]("string"),e,r);throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t)}function c(t){if("number"!=typeof t)throw TypeError('"size" argument must be of type number');if(t<0)throw RangeError('The value "'+t+'" is invalid for option "size"')}function p(t,e,r){return(c(t),t<=0)?u(t):void 0!==e?"string"==typeof r?u(t).fill(e,r):u(t).fill(e):u(t)}function h(t){return c(t),u(t<0?0:0|v(t))}function y(t,e){if(("string"!=typeof e||""===e)&&(e="utf8"),!f.isEncoding(e))throw TypeError("Unknown encoding: "+e);var r=0|w(t,e),n=u(r),o=n.write(t,e);return o!==r&&(n=n.slice(0,o)),n}function d(t){for(var e=t.length<0?0:0|v(t.length),r=u(e),n=0;n<e;n+=1)r[n]=255&t[n];return r}function g(t,e,r){var n;if(e<0||t.byteLength<e)throw RangeError('"offset" is outside of buffer bounds');if(t.byteLength<e+(r||0))throw RangeError('"length" is outside of buffer bounds');return Object.setPrototypeOf(n=void 0===e&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,e):new Uint8Array(t,e,r),f.prototype),n}function b(t){if(f.isBuffer(t)){var e=0|v(t.length),r=u(e);return 0===r.length||t.copy(r,0,0,e),r}return void 0!==t.length?"number"!=typeof t.length||X(t.length)?u(0):d(t):"Buffer"===t.type&&Array.isArray(t.data)?d(t.data):void 0}function v(t){if(t>=a)throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a.toString(16)+" bytes");return 0|t}function m(t){return+t!=t&&(t=0),f.alloc(+t)}function w(t,e){if(f.isBuffer(t))return t.length;if(ArrayBuffer.isView(t)||Z(t,ArrayBuffer))return t.byteLength;if("string"!=typeof t)throw TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof t);var r=t.length,n=arguments.length>2&&!0===arguments[2];if(!n&&0===r)return 0;for(var o=!1;;)switch(e){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return V(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return Y(t).length;default:if(o)return n?-1:V(t).length;e=(""+e).toLowerCase(),o=!0}}function S(t,e,r){var n=!1;if((void 0===e||e<0)&&(e=0),e>this.length||((void 0===r||r>this.length)&&(r=this.length),r<=0||(r>>>=0)<=(e>>>=0)))return"";for(t||(t="utf8");;)switch(t){case"hex":return I(this,e,r);case"utf8":case"utf-8":return M(this,e,r);case"ascii":return N(this,e,r);case"latin1":case"binary":return C(this,e,r);case"base64":return k(this,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return U(this,e,r);default:if(n)throw TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),n=!0}}function _(t,e,r){var n=t[e];t[e]=t[r],t[r]=n}function E(t,e,r,n,o){if(0===t.length)return -1;if("string"==typeof r?(n=r,r=0):r>0x7fffffff?r=0x7fffffff:r<-0x80000000&&(r=-0x80000000),X(r*=1)&&(r=o?0:t.length-1),r<0&&(r=t.length+r),r>=t.length)if(o)return -1;else r=t.length-1;else if(r<0)if(!o)return -1;else r=0;if("string"==typeof e&&(e=f.from(e,n)),f.isBuffer(e))return 0===e.length?-1:A(t,e,r,n,o);if("number"==typeof e){if(e&=255,"function"==typeof Uint8Array.prototype.indexOf)if(o)return Uint8Array.prototype.indexOf.call(t,e,r);else return Uint8Array.prototype.lastIndexOf.call(t,e,r);return A(t,[e],r,n,o)}throw TypeError("val must be string, number or Buffer")}function A(t,e,r,n,o){var i,a=1,s=t.length,u=e.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(t.length<2||e.length<2)return -1;a=2,s/=2,u/=2,r/=2}function f(t,e){return 1===a?t[e]:t.readUInt16BE(e*a)}if(o){var l=-1;for(i=r;i<s;i++)if(f(t,i)===f(e,-1===l?0:i-l)){if(-1===l&&(l=i),i-l+1===u)return l*a}else -1!==l&&(i-=i-l),l=-1}else for(r+u>s&&(r=s-u),i=r;i>=0;i--){for(var c=!0,p=0;p<u;p++)if(f(t,i+p)!==f(e,p)){c=!1;break}if(c)return i}return -1}function O(t,e,r,n){r=Number(r)||0;var o=t.length-r;n?(n=Number(n))>o&&(n=o):n=o;var i=e.length;n>i/2&&(n=i/2);for(var a=0;a<n;++a){var s=parseInt(e.substr(2*a,2),16);if(X(s))break;t[r+a]=s}return a}function x(t,e,r,n){return K(V(e,t.length-r),t,r,n)}function R(t,e,r,n){return K(H(e),t,r,n)}function j(t,e,r,n){return R(t,e,r,n)}function P(t,e,r,n){return K(Y(e),t,r,n)}function T(t,e,r,n){return K(J(e,t.length-r),t,r,n)}function k(t,e,r){return 0===e&&r===t.length?n.fromByteArray(t):n.fromByteArray(t.slice(e,r))}function M(t,e,r){r=Math.min(t.length,r);for(var n=[],o=e;o<r;){var i,a,s,u,f=t[o],l=null,c=f>239?4:f>223?3:f>191?2:1;if(o+c<=r)switch(c){case 1:f<128&&(l=f);break;case 2:(192&(i=t[o+1]))==128&&(u=(31&f)<<6|63&i)>127&&(l=u);break;case 3:i=t[o+1],a=t[o+2],(192&i)==128&&(192&a)==128&&(u=(15&f)<<12|(63&i)<<6|63&a)>2047&&(u<55296||u>57343)&&(l=u);break;case 4:i=t[o+1],a=t[o+2],s=t[o+3],(192&i)==128&&(192&a)==128&&(192&s)==128&&(u=(15&f)<<18|(63&i)<<12|(63&a)<<6|63&s)>65535&&u<1114112&&(l=u)}null===l?(l=65533,c=1):l>65535&&(l-=65536,n.push(l>>>10&1023|55296),l=56320|1023&l),n.push(l),o+=c}return B(n)}e.kMaxLength=0x7fffffff,f.TYPED_ARRAY_SUPPORT=s(),f.TYPED_ARRAY_SUPPORT||"undefined"==typeof console||"function"!=typeof console.error||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(f.prototype,"parent",{enumerable:!0,get:function(){if(f.isBuffer(this))return this.buffer}}),Object.defineProperty(f.prototype,"offset",{enumerable:!0,get:function(){if(f.isBuffer(this))return this.byteOffset}}),f.poolSize=8192,f.from=function(t,e,r){return l(t,e,r)},Object.setPrototypeOf(f.prototype,Uint8Array.prototype),Object.setPrototypeOf(f,Uint8Array),f.alloc=function(t,e,r){return p(t,e,r)},f.allocUnsafe=function(t){return h(t)},f.allocUnsafeSlow=function(t){return h(t)},f.isBuffer=function(t){return null!=t&&!0===t._isBuffer&&t!==f.prototype},f.compare=function(t,e){if(Z(t,Uint8Array)&&(t=f.from(t,t.offset,t.byteLength)),Z(e,Uint8Array)&&(e=f.from(e,e.offset,e.byteLength)),!f.isBuffer(t)||!f.isBuffer(e))throw TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(t===e)return 0;for(var r=t.length,n=e.length,o=0,i=Math.min(r,n);o<i;++o)if(t[o]!==e[o]){r=t[o],n=e[o];break}return r<n?-1:+(n<r)},f.isEncoding=function(t){switch(String(t).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},f.concat=function(t,e){if(!Array.isArray(t))throw TypeError('"list" argument must be an Array of Buffers');if(0===t.length)return f.alloc(0);if(void 0===e)for(r=0,e=0;r<t.length;++r)e+=t[r].length;var r,n=f.allocUnsafe(e),o=0;for(r=0;r<t.length;++r){var i=t[r];if(Z(i,Uint8Array)&&(i=f.from(i)),!f.isBuffer(i))throw TypeError('"list" argument must be an Array of Buffers');i.copy(n,o),o+=i.length}return n},f.byteLength=w,f.prototype._isBuffer=!0,f.prototype.swap16=function(){var t=this.length;if(t%2!=0)throw RangeError("Buffer size must be a multiple of 16-bits");for(var e=0;e<t;e+=2)_(this,e,e+1);return this},f.prototype.swap32=function(){var t=this.length;if(t%4!=0)throw RangeError("Buffer size must be a multiple of 32-bits");for(var e=0;e<t;e+=4)_(this,e,e+3),_(this,e+1,e+2);return this},f.prototype.swap64=function(){var t=this.length;if(t%8!=0)throw RangeError("Buffer size must be a multiple of 64-bits");for(var e=0;e<t;e+=8)_(this,e,e+7),_(this,e+1,e+6),_(this,e+2,e+5),_(this,e+3,e+4);return this},f.prototype.toString=function(){var t=this.length;return 0===t?"":0==arguments.length?M(this,0,t):S.apply(this,arguments)},f.prototype.toLocaleString=f.prototype.toString,f.prototype.equals=function(t){if(!f.isBuffer(t))throw TypeError("Argument must be a Buffer");return this===t||0===f.compare(this,t)},f.prototype.inspect=function(){var t="",r=e.INSPECT_MAX_BYTES;return t=this.toString("hex",0,r).replace(/(.{2})/g,"$1 ").trim(),this.length>r&&(t+=" ... "),"<Buffer "+t+">"},i&&(f.prototype[i]=f.prototype.inspect),f.prototype.compare=function(t,e,r,n,o){if(Z(t,Uint8Array)&&(t=f.from(t,t.offset,t.byteLength)),!f.isBuffer(t))throw TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof t);if(void 0===e&&(e=0),void 0===r&&(r=t?t.length:0),void 0===n&&(n=0),void 0===o&&(o=this.length),e<0||r>t.length||n<0||o>this.length)throw RangeError("out of range index");if(n>=o&&e>=r)return 0;if(n>=o)return -1;if(e>=r)return 1;if(e>>>=0,r>>>=0,n>>>=0,o>>>=0,this===t)return 0;for(var i=o-n,a=r-e,s=Math.min(i,a),u=this.slice(n,o),l=t.slice(e,r),c=0;c<s;++c)if(u[c]!==l[c]){i=u[c],a=l[c];break}return i<a?-1:+(a<i)},f.prototype.includes=function(t,e,r){return -1!==this.indexOf(t,e,r)},f.prototype.indexOf=function(t,e,r){return E(this,t,e,r,!0)},f.prototype.lastIndexOf=function(t,e,r){return E(this,t,e,r,!1)},f.prototype.write=function(t,e,r,n){if(void 0===e)n="utf8",r=this.length,e=0;else if(void 0===r&&"string"==typeof e)n=e,r=this.length,e=0;else if(isFinite(e))e>>>=0,isFinite(r)?(r>>>=0,void 0===n&&(n="utf8")):(n=r,r=void 0);else throw Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var o=this.length-e;if((void 0===r||r>o)&&(r=o),t.length>0&&(r<0||e<0)||e>this.length)throw RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var i=!1;;)switch(n){case"hex":return O(this,t,e,r);case"utf8":case"utf-8":return x(this,t,e,r);case"ascii":return R(this,t,e,r);case"latin1":case"binary":return j(this,t,e,r);case"base64":return P(this,t,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return T(this,t,e,r);default:if(i)throw TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),i=!0}},f.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var L=4096;function B(t){var e=t.length;if(e<=L)return String.fromCharCode.apply(String,t);for(var r="",n=0;n<e;)r+=String.fromCharCode.apply(String,t.slice(n,n+=L));return r}function N(t,e,r){var n="";r=Math.min(t.length,r);for(var o=e;o<r;++o)n+=String.fromCharCode(127&t[o]);return n}function C(t,e,r){var n="";r=Math.min(t.length,r);for(var o=e;o<r;++o)n+=String.fromCharCode(t[o]);return n}function I(t,e,r){var n=t.length;(!e||e<0)&&(e=0),(!r||r<0||r>n)&&(r=n);for(var o="",i=e;i<r;++i)o+=Q[t[i]];return o}function U(t,e,r){for(var n=t.slice(e,r),o="",i=0;i<n.length;i+=2)o+=String.fromCharCode(n[i]+256*n[i+1]);return o}function D(t,e,r){if(t%1!=0||t<0)throw RangeError("offset is not uint");if(t+e>r)throw RangeError("Trying to access beyond buffer length")}function F(t,e,r,n,o,i){if(!f.isBuffer(t))throw TypeError('"buffer" argument must be a Buffer instance');if(e>o||e<i)throw RangeError('"value" argument is out of bounds');if(r+n>t.length)throw RangeError("Index out of range")}function W(t,e,r,n,o,i){if(r+n>t.length||r<0)throw RangeError("Index out of range")}function q(t,e,r,n,i){return e*=1,r>>>=0,i||W(t,e,r,4,34028234663852886e22,-34028234663852886e22),o.write(t,e,r,n,23,4),r+4}function G(t,e,r,n,i){return e*=1,r>>>=0,i||W(t,e,r,8,17976931348623157e292,-17976931348623157e292),o.write(t,e,r,n,52,8),r+8}f.prototype.slice=function(t,e){var r=this.length;t=~~t,e=void 0===e?r:~~e,t<0?(t+=r)<0&&(t=0):t>r&&(t=r),e<0?(e+=r)<0&&(e=0):e>r&&(e=r),e<t&&(e=t);var n=this.subarray(t,e);return Object.setPrototypeOf(n,f.prototype),n},f.prototype.readUIntLE=function(t,e,r){t>>>=0,e>>>=0,r||D(t,e,this.length);for(var n=this[t],o=1,i=0;++i<e&&(o*=256);)n+=this[t+i]*o;return n},f.prototype.readUIntBE=function(t,e,r){t>>>=0,e>>>=0,r||D(t,e,this.length);for(var n=this[t+--e],o=1;e>0&&(o*=256);)n+=this[t+--e]*o;return n},f.prototype.readUInt8=function(t,e){return t>>>=0,e||D(t,1,this.length),this[t]},f.prototype.readUInt16LE=function(t,e){return t>>>=0,e||D(t,2,this.length),this[t]|this[t+1]<<8},f.prototype.readUInt16BE=function(t,e){return t>>>=0,e||D(t,2,this.length),this[t]<<8|this[t+1]},f.prototype.readUInt32LE=function(t,e){return t>>>=0,e||D(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+0x1000000*this[t+3]},f.prototype.readUInt32BE=function(t,e){return t>>>=0,e||D(t,4,this.length),0x1000000*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},f.prototype.readIntLE=function(t,e,r){t>>>=0,e>>>=0,r||D(t,e,this.length);for(var n=this[t],o=1,i=0;++i<e&&(o*=256);)n+=this[t+i]*o;return n>=(o*=128)&&(n-=Math.pow(2,8*e)),n},f.prototype.readIntBE=function(t,e,r){t>>>=0,e>>>=0,r||D(t,e,this.length);for(var n=e,o=1,i=this[t+--n];n>0&&(o*=256);)i+=this[t+--n]*o;return i>=(o*=128)&&(i-=Math.pow(2,8*e)),i},f.prototype.readInt8=function(t,e){return(t>>>=0,e||D(t,1,this.length),128&this[t])?-((255-this[t]+1)*1):this[t]},f.prototype.readInt16LE=function(t,e){t>>>=0,e||D(t,2,this.length);var r=this[t]|this[t+1]<<8;return 32768&r?0xffff0000|r:r},f.prototype.readInt16BE=function(t,e){t>>>=0,e||D(t,2,this.length);var r=this[t+1]|this[t]<<8;return 32768&r?0xffff0000|r:r},f.prototype.readInt32LE=function(t,e){return t>>>=0,e||D(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},f.prototype.readInt32BE=function(t,e){return t>>>=0,e||D(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},f.prototype.readFloatLE=function(t,e){return t>>>=0,e||D(t,4,this.length),o.read(this,t,!0,23,4)},f.prototype.readFloatBE=function(t,e){return t>>>=0,e||D(t,4,this.length),o.read(this,t,!1,23,4)},f.prototype.readDoubleLE=function(t,e){return t>>>=0,e||D(t,8,this.length),o.read(this,t,!0,52,8)},f.prototype.readDoubleBE=function(t,e){return t>>>=0,e||D(t,8,this.length),o.read(this,t,!1,52,8)},f.prototype.writeUIntLE=function(t,e,r,n){if(t*=1,e>>>=0,r>>>=0,!n){var o=Math.pow(2,8*r)-1;F(this,t,e,r,o,0)}var i=1,a=0;for(this[e]=255&t;++a<r&&(i*=256);)this[e+a]=t/i&255;return e+r},f.prototype.writeUIntBE=function(t,e,r,n){if(t*=1,e>>>=0,r>>>=0,!n){var o=Math.pow(2,8*r)-1;F(this,t,e,r,o,0)}var i=r-1,a=1;for(this[e+i]=255&t;--i>=0&&(a*=256);)this[e+i]=t/a&255;return e+r},f.prototype.writeUInt8=function(t,e,r){return t*=1,e>>>=0,r||F(this,t,e,1,255,0),this[e]=255&t,e+1},f.prototype.writeUInt16LE=function(t,e,r){return t*=1,e>>>=0,r||F(this,t,e,2,65535,0),this[e]=255&t,this[e+1]=t>>>8,e+2},f.prototype.writeUInt16BE=function(t,e,r){return t*=1,e>>>=0,r||F(this,t,e,2,65535,0),this[e]=t>>>8,this[e+1]=255&t,e+2},f.prototype.writeUInt32LE=function(t,e,r){return t*=1,e>>>=0,r||F(this,t,e,4,0xffffffff,0),this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=255&t,e+4},f.prototype.writeUInt32BE=function(t,e,r){return t*=1,e>>>=0,r||F(this,t,e,4,0xffffffff,0),this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t,e+4},f.prototype.writeIntLE=function(t,e,r,n){if(t*=1,e>>>=0,!n){var o=Math.pow(2,8*r-1);F(this,t,e,r,o-1,-o)}var i=0,a=1,s=0;for(this[e]=255&t;++i<r&&(a*=256);)t<0&&0===s&&0!==this[e+i-1]&&(s=1),this[e+i]=(t/a|0)-s&255;return e+r},f.prototype.writeIntBE=function(t,e,r,n){if(t*=1,e>>>=0,!n){var o=Math.pow(2,8*r-1);F(this,t,e,r,o-1,-o)}var i=r-1,a=1,s=0;for(this[e+i]=255&t;--i>=0&&(a*=256);)t<0&&0===s&&0!==this[e+i+1]&&(s=1),this[e+i]=(t/a|0)-s&255;return e+r},f.prototype.writeInt8=function(t,e,r){return t*=1,e>>>=0,r||F(this,t,e,1,127,-128),t<0&&(t=255+t+1),this[e]=255&t,e+1},f.prototype.writeInt16LE=function(t,e,r){return t*=1,e>>>=0,r||F(this,t,e,2,32767,-32768),this[e]=255&t,this[e+1]=t>>>8,e+2},f.prototype.writeInt16BE=function(t,e,r){return t*=1,e>>>=0,r||F(this,t,e,2,32767,-32768),this[e]=t>>>8,this[e+1]=255&t,e+2},f.prototype.writeInt32LE=function(t,e,r){return t*=1,e>>>=0,r||F(this,t,e,4,0x7fffffff,-0x80000000),this[e]=255&t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24,e+4},f.prototype.writeInt32BE=function(t,e,r){return t*=1,e>>>=0,r||F(this,t,e,4,0x7fffffff,-0x80000000),t<0&&(t=0xffffffff+t+1),this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t,e+4},f.prototype.writeFloatLE=function(t,e,r){return q(this,t,e,!0,r)},f.prototype.writeFloatBE=function(t,e,r){return q(this,t,e,!1,r)},f.prototype.writeDoubleLE=function(t,e,r){return G(this,t,e,!0,r)},f.prototype.writeDoubleBE=function(t,e,r){return G(this,t,e,!1,r)},f.prototype.copy=function(t,e,r,n){if(!f.isBuffer(t))throw TypeError("argument should be a Buffer");if(r||(r=0),n||0===n||(n=this.length),e>=t.length&&(e=t.length),e||(e=0),n>0&&n<r&&(n=r),n===r||0===t.length||0===this.length)return 0;if(e<0)throw RangeError("targetStart out of bounds");if(r<0||r>=this.length)throw RangeError("Index out of range");if(n<0)throw RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),t.length-e<n-r&&(n=t.length-e+r);var o=n-r;if(this===t&&"function"==typeof Uint8Array.prototype.copyWithin)this.copyWithin(e,r,n);else if(this===t&&r<e&&e<n)for(var i=o-1;i>=0;--i)t[i+e]=this[i+r];else Uint8Array.prototype.set.call(t,this.subarray(r,n),e);return o},f.prototype.fill=function(t,e,r,n){if("string"==typeof t){if("string"==typeof e?(n=e,e=0,r=this.length):"string"==typeof r&&(n=r,r=this.length),void 0!==n&&"string"!=typeof n)throw TypeError("encoding must be a string");if("string"==typeof n&&!f.isEncoding(n))throw TypeError("Unknown encoding: "+n);if(1===t.length){var o,i=t.charCodeAt(0);("utf8"===n&&i<128||"latin1"===n)&&(t=i)}}else"number"==typeof t?t&=255:"boolean"==typeof t&&(t=Number(t));if(e<0||this.length<e||this.length<r)throw RangeError("Out of range index");if(r<=e)return this;if(e>>>=0,r=void 0===r?this.length:r>>>0,t||(t=0),"number"==typeof t)for(o=e;o<r;++o)this[o]=t;else{var a=f.isBuffer(t)?t:f.from(t,n),s=a.length;if(0===s)throw TypeError('The value "'+t+'" is invalid for argument "value"');for(o=0;o<r-e;++o)this[o+e]=a[o%s]}return this};var z=/[^+/0-9A-Za-z-_]/g;function $(t){if((t=(t=t.split("=")[0]).trim().replace(z,"")).length<2)return"";for(;t.length%4!=0;)t+="=";return t}function V(t,e){e=e||1/0;for(var r,n=t.length,o=null,i=[],a=0;a<n;++a){if((r=t.charCodeAt(a))>55295&&r<57344){if(!o){if(r>56319||a+1===n){(e-=3)>-1&&i.push(239,191,189);continue}o=r;continue}if(r<56320){(e-=3)>-1&&i.push(239,191,189),o=r;continue}r=(o-55296<<10|r-56320)+65536}else o&&(e-=3)>-1&&i.push(239,191,189);if(o=null,r<128){if((e-=1)<0)break;i.push(r)}else if(r<2048){if((e-=2)<0)break;i.push(r>>6|192,63&r|128)}else if(r<65536){if((e-=3)<0)break;i.push(r>>12|224,r>>6&63|128,63&r|128)}else if(r<1114112){if((e-=4)<0)break;i.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}else throw Error("Invalid code point")}return i}function H(t){for(var e=[],r=0;r<t.length;++r)e.push(255&t.charCodeAt(r));return e}function J(t,e){for(var r,n,o=[],i=0;i<t.length&&!((e-=2)<0);++i)n=(r=t.charCodeAt(i))>>8,o.push(r%256),o.push(n);return o}function Y(t){return n.toByteArray($(t))}function K(t,e,r,n){for(var o=0;o<n&&!(o+r>=e.length)&&!(o>=t.length);++o)e[o+r]=t[o];return o}function Z(t,e){return t instanceof e||null!=t&&null!=t.constructor&&null!=t.constructor.name&&t.constructor.name===e.name}function X(t){return t!=t}var Q=function(){for(var t="0123456789abcdef",e=Array(256),r=0;r<16;++r)for(var n=16*r,o=0;o<16;++o)e[n+o]=t[r]+t[o];return e}()},783:function(t,e){e.read=function(t,e,r,n,o){var i,a,s=8*o-n-1,u=(1<<s)-1,f=u>>1,l=-7,c=r?o-1:0,p=r?-1:1,h=t[e+c];for(c+=p,i=h&(1<<-l)-1,h>>=-l,l+=s;l>0;i=256*i+t[e+c],c+=p,l-=8);for(a=i&(1<<-l)-1,i>>=-l,l+=n;l>0;a=256*a+t[e+c],c+=p,l-=8);if(0===i)i=1-f;else{if(i===u)return a?NaN:1/0*(h?-1:1);a+=Math.pow(2,n),i-=f}return(h?-1:1)*a*Math.pow(2,i-n)},e.write=function(t,e,r,n,o,i){var a,s,u,f=8*i-o-1,l=(1<<f)-1,c=l>>1,p=5960464477539062e-23*(23===o),h=n?0:i-1,y=n?1:-1,d=+(e<0||0===e&&1/e<0);for(isNaN(e=Math.abs(e))||e===1/0?(s=+!!isNaN(e),a=l):(a=Math.floor(Math.log(e)/Math.LN2),e*(u=Math.pow(2,-a))<1&&(a--,u*=2),a+c>=1?e+=p/u:e+=p*Math.pow(2,1-c),e*u>=2&&(a++,u/=2),a+c>=l?(s=0,a=l):a+c>=1?(s=(e*u-1)*Math.pow(2,o),a+=c):(s=e*Math.pow(2,c-1)*Math.pow(2,o),a=0));o>=8;t[r+h]=255&s,h+=y,s/=256,o-=8);for(a=a<<o|s,f+=o;f>0;t[r+h]=255&a,h+=y,a/=256,f-=8);t[r+h-y]|=128*d}}},n={};function o(t){var e=n[t];if(void 0!==e)return e.exports;var i=n[t]={exports:{}},a=!0;try{r[t](i,i.exports,o),a=!1}finally{a&&delete n[t]}return i.exports}o.ab=e+"/",t.exports=o(72)}()},24783:module=>{var __dirname="/";!function(){var __webpack_modules__={950:function(__unused_webpack_module,exports){var indexOf=function(t,e){if(t.indexOf)return t.indexOf(e);for(var r=0;r<t.length;r++)if(t[r]===e)return r;return -1},Object_keys=function(t){if(Object.keys)return Object.keys(t);var e=[];for(var r in t)e.push(r);return e},forEach=function(t,e){if(t.forEach)return t.forEach(e);for(var r=0;r<t.length;r++)e(t[r],r,t)},defineProp=function(){try{return Object.defineProperty({},"_",{}),function(t,e,r){Object.defineProperty(t,e,{writable:!0,enumerable:!1,configurable:!0,value:r})}}catch(t){return function(t,e,r){t[e]=r}}}(),globals=["Array","Boolean","Date","Error","EvalError","Function","Infinity","JSON","Math","NaN","Number","Object","RangeError","ReferenceError","RegExp","String","SyntaxError","TypeError","URIError","decodeURI","decodeURIComponent","encodeURI","encodeURIComponent","escape","eval","isFinite","isNaN","parseFloat","parseInt","undefined","unescape"];function Context(){}Context.prototype={};var Script=exports.Script=function(t){if(!(this instanceof Script))return new Script(t);this.code=t};Script.prototype.runInContext=function(t){if(!(t instanceof Context))throw TypeError("needs a 'context' argument.");var e=document.createElement("iframe");e.style||(e.style={}),e.style.display="none",document.body.appendChild(e);var r=e.contentWindow,n=r.eval,o=r.execScript;!n&&o&&(o.call(r,"null"),n=r.eval),forEach(Object_keys(t),function(e){r[e]=t[e]}),forEach(globals,function(e){t[e]&&(r[e]=t[e])});var i=Object_keys(r),a=n.call(r,this.code);return forEach(Object_keys(r),function(e){(e in t||-1===indexOf(i,e))&&(t[e]=r[e])}),forEach(globals,function(e){e in t||defineProp(t,e,r[e])}),document.body.removeChild(e),a},Script.prototype.runInThisContext=function(){return eval(this.code)},Script.prototype.runInNewContext=function(t){var e=Script.createContext(t),r=this.runInContext(e);return t&&forEach(Object_keys(e),function(r){t[r]=e[r]}),r},forEach(Object_keys(Script.prototype),function(t){exports[t]=Script[t]=function(e){var r=Script(e);return r[t].apply(r,[].slice.call(arguments,1))}}),exports.isContext=function(t){return t instanceof Context},exports.createScript=function(t){return exports.Script(t)},exports.createContext=Script.createContext=function(t){var e=new Context;return"object"==typeof t&&forEach(Object_keys(t),function(r){e[r]=t[r]}),e}}};"undefined"!=typeof __nccwpck_require__&&(__nccwpck_require__.ab=__dirname+"/");var __nested_webpack_exports__={};__webpack_modules__[950](0,__nested_webpack_exports__),module.exports=__nested_webpack_exports__}()},27924:(t,e,r)=>{var n="/",o=r(77011);!function(){var e={782:function(t){"function"==typeof Object.create?t.exports=function(t,e){e&&(t.super_=e,t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}))}:t.exports=function(t,e){if(e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}}},646:function(t){"use strict";let e={};function r(t,r,n){function o(t,e,n){return"string"==typeof r?r:r(t,e,n)}n||(n=Error);class i extends n{constructor(t,e,r){super(o(t,e,r))}}i.prototype.name=n.name,i.prototype.code=t,e[t]=i}function n(t,e){if(!Array.isArray(t))return`of ${e} ${String(t)}`;{let r=t.length;return(t=t.map(t=>String(t)),r>2)?`one of ${e} ${t.slice(0,r-1).join(", ")}, or `+t[r-1]:2===r?`one of ${e} ${t[0]} or ${t[1]}`:`of ${e} ${t[0]}`}}function o(t,e,r){return t.substr(!r||r<0?0:+r,e.length)===e}function i(t,e,r){return(void 0===r||r>t.length)&&(r=t.length),t.substring(r-e.length,r)===e}function a(t,e,r){return"number"!=typeof r&&(r=0),!(r+e.length>t.length)&&-1!==t.indexOf(e,r)}r("ERR_INVALID_OPT_VALUE",function(t,e){return'The value "'+e+'" is invalid for option "'+t+'"'},TypeError),r("ERR_INVALID_ARG_TYPE",function(t,e,r){let s,u;if("string"==typeof e&&o(e,"not ")?(s="must not be",e=e.replace(/^not /,"")):s="must be",i(t," argument"))u=`The ${t} ${s} ${n(e,"type")}`;else{let r=a(t,".")?"property":"argument";u=`The "${t}" ${r} ${s} ${n(e,"type")}`}return u+`. Received type ${typeof r}`},TypeError),r("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),r("ERR_METHOD_NOT_IMPLEMENTED",function(t){return"The "+t+" method is not implemented"}),r("ERR_STREAM_PREMATURE_CLOSE","Premature close"),r("ERR_STREAM_DESTROYED",function(t){return"Cannot call "+t+" after a stream was destroyed"}),r("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),r("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),r("ERR_STREAM_WRITE_AFTER_END","write after end"),r("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),r("ERR_UNKNOWN_ENCODING",function(t){return"Unknown encoding: "+t},TypeError),r("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),t.exports.q=e},403:function(t,e,r){"use strict";var n=Object.keys||function(t){var e=[];for(var r in t)e.push(r);return e};t.exports=l;var i=r(709),a=r(337);r(782)(l,i);for(var s=n(a.prototype),u=0;u<s.length;u++){var f=s[u];l.prototype[f]||(l.prototype[f]=a.prototype[f])}function l(t){if(!(this instanceof l))return new l(t);i.call(this,t),a.call(this,t),this.allowHalfOpen=!0,t&&(!1===t.readable&&(this.readable=!1),!1===t.writable&&(this.writable=!1),!1===t.allowHalfOpen&&(this.allowHalfOpen=!1,this.once("end",c)))}function c(){this._writableState.ended||o.nextTick(p,this)}function p(t){t.end()}Object.defineProperty(l.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(l.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(l.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(l.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&this._readableState.destroyed&&this._writableState.destroyed},set:function(t){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=t,this._writableState.destroyed=t)}})},889:function(t,e,r){"use strict";t.exports=o;var n=r(170);function o(t){if(!(this instanceof o))return new o(t);n.call(this,t)}r(782)(o,n),o.prototype._transform=function(t,e,r){r(null,t)}},709:function(t,e,n){"use strict";t.exports=P,P.ReadableState=j,n(361).EventEmitter;var i,a,s,u,f,l=function(t,e){return t.listeners(e).length},c=n(678),p=n(300).Buffer,h=r.g.Uint8Array||function(){};function y(t){return p.from(t)}function d(t){return p.isBuffer(t)||t instanceof h}var g=n(837);a=g&&g.debuglog?g.debuglog("stream"):function(){};var b=n(379),v=n(25),m=n(776).getHighWaterMark,w=n(646).q,S=w.ERR_INVALID_ARG_TYPE,_=w.ERR_STREAM_PUSH_AFTER_EOF,E=w.ERR_METHOD_NOT_IMPLEMENTED,A=w.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;n(782)(P,c);var O=v.errorOrDestroy,x=["error","close","destroy","pause","resume"];function R(t,e,r){if("function"==typeof t.prependListener)return t.prependListener(e,r);t._events&&t._events[e]?Array.isArray(t._events[e])?t._events[e].unshift(r):t._events[e]=[r,t._events[e]]:t.on(e,r)}function j(t,e,r){i=i||n(403),t=t||{},"boolean"!=typeof r&&(r=e instanceof i),this.objectMode=!!t.objectMode,r&&(this.objectMode=this.objectMode||!!t.readableObjectMode),this.highWaterMark=m(this,t,"readableHighWaterMark",r),this.buffer=new b,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=!1!==t.emitClose,this.autoDestroy=!!t.autoDestroy,this.destroyed=!1,this.defaultEncoding=t.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,t.encoding&&(s||(s=n(704).s),this.decoder=new s(t.encoding),this.encoding=t.encoding)}function P(t){if(i=i||n(403),!(this instanceof P))return new P(t);var e=this instanceof i;this._readableState=new j(t,this,e),this.readable=!0,t&&("function"==typeof t.read&&(this._read=t.read),"function"==typeof t.destroy&&(this._destroy=t.destroy)),c.call(this)}function T(t,e,r,n,o){a("readableAddChunk",e);var i,s=t._readableState;if(null===e)s.reading=!1,C(t,s);else if(o||(i=M(s,e)),i)O(t,i);else if(s.objectMode||e&&e.length>0)if("string"==typeof e||s.objectMode||Object.getPrototypeOf(e)===p.prototype||(e=y(e)),n)s.endEmitted?O(t,new A):k(t,s,e,!0);else if(s.ended)O(t,new _);else{if(s.destroyed)return!1;s.reading=!1,s.decoder&&!r?(e=s.decoder.write(e),s.objectMode||0!==e.length?k(t,s,e,!1):D(t,s)):k(t,s,e,!1)}else n||(s.reading=!1,D(t,s));return!s.ended&&(s.length<s.highWaterMark||0===s.length)}function k(t,e,r,n){e.flowing&&0===e.length&&!e.sync?(e.awaitDrain=0,t.emit("data",r)):(e.length+=e.objectMode?1:r.length,n?e.buffer.unshift(r):e.buffer.push(r),e.needReadable&&I(t)),D(t,e)}function M(t,e){var r;return d(e)||"string"==typeof e||void 0===e||t.objectMode||(r=new S("chunk",["string","Buffer","Uint8Array"],e)),r}Object.defineProperty(P.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(t){this._readableState&&(this._readableState.destroyed=t)}}),P.prototype.destroy=v.destroy,P.prototype._undestroy=v.undestroy,P.prototype._destroy=function(t,e){e(t)},P.prototype.push=function(t,e){var r,n=this._readableState;return n.objectMode?r=!0:"string"==typeof t&&((e=e||n.defaultEncoding)!==n.encoding&&(t=p.from(t,e),e=""),r=!0),T(this,t,e,!1,r)},P.prototype.unshift=function(t){return T(this,t,null,!0,!1)},P.prototype.isPaused=function(){return!1===this._readableState.flowing},P.prototype.setEncoding=function(t){s||(s=n(704).s);var e=new s(t);this._readableState.decoder=e,this._readableState.encoding=this._readableState.decoder.encoding;for(var r=this._readableState.buffer.head,o="";null!==r;)o+=e.write(r.data),r=r.next;return this._readableState.buffer.clear(),""!==o&&this._readableState.buffer.push(o),this._readableState.length=o.length,this};var L=0x40000000;function B(t){return t>=L?t=L:(t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t++),t}function N(t,e){if(t<=0||0===e.length&&e.ended)return 0;if(e.objectMode)return 1;if(t!=t)if(e.flowing&&e.length)return e.buffer.head.data.length;else return e.length;return(t>e.highWaterMark&&(e.highWaterMark=B(t)),t<=e.length)?t:e.ended?e.length:(e.needReadable=!0,0)}function C(t,e){if(a("onEofChunk"),!e.ended){if(e.decoder){var r=e.decoder.end();r&&r.length&&(e.buffer.push(r),e.length+=e.objectMode?1:r.length)}e.ended=!0,e.sync?I(t):(e.needReadable=!1,e.emittedReadable||(e.emittedReadable=!0,U(t)))}}function I(t){var e=t._readableState;a("emitReadable",e.needReadable,e.emittedReadable),e.needReadable=!1,e.emittedReadable||(a("emitReadable",e.flowing),e.emittedReadable=!0,o.nextTick(U,t))}function U(t){var e=t._readableState;a("emitReadable_",e.destroyed,e.length,e.ended),!e.destroyed&&(e.length||e.ended)&&(t.emit("readable"),e.emittedReadable=!1),e.needReadable=!e.flowing&&!e.ended&&e.length<=e.highWaterMark,V(t)}function D(t,e){e.readingMore||(e.readingMore=!0,o.nextTick(F,t,e))}function F(t,e){for(;!e.reading&&!e.ended&&(e.length<e.highWaterMark||e.flowing&&0===e.length);){var r=e.length;if(a("maybeReadMore read 0"),t.read(0),r===e.length)break}e.readingMore=!1}function W(t){return function(){var e=t._readableState;a("pipeOnDrain",e.awaitDrain),e.awaitDrain&&e.awaitDrain--,0===e.awaitDrain&&l(t,"data")&&(e.flowing=!0,V(t))}}function q(t){var e=t._readableState;e.readableListening=t.listenerCount("readable")>0,e.resumeScheduled&&!e.paused?e.flowing=!0:t.listenerCount("data")>0&&t.resume()}function G(t){a("readable nexttick read 0"),t.read(0)}function z(t,e){e.resumeScheduled||(e.resumeScheduled=!0,o.nextTick($,t,e))}function $(t,e){a("resume",e.reading),e.reading||t.read(0),e.resumeScheduled=!1,t.emit("resume"),V(t),e.flowing&&!e.reading&&t.read(0)}function V(t){var e=t._readableState;for(a("flow",e.flowing);e.flowing&&null!==t.read(););}function H(t,e){var r;return 0===e.length?null:(e.objectMode?r=e.buffer.shift():!t||t>=e.length?(r=e.decoder?e.buffer.join(""):1===e.buffer.length?e.buffer.first():e.buffer.concat(e.length),e.buffer.clear()):r=e.buffer.consume(t,e.decoder),r)}function J(t){var e=t._readableState;a("endReadable",e.endEmitted),e.endEmitted||(e.ended=!0,o.nextTick(Y,e,t))}function Y(t,e){if(a("endReadableNT",t.endEmitted,t.length),!t.endEmitted&&0===t.length&&(t.endEmitted=!0,e.readable=!1,e.emit("end"),t.autoDestroy)){var r=e._writableState;(!r||r.autoDestroy&&r.finished)&&e.destroy()}}function K(t,e){for(var r=0,n=t.length;r<n;r++)if(t[r]===e)return r;return -1}P.prototype.read=function(t){a("read",t),t=parseInt(t,10);var e,r=this._readableState,n=t;if(0!==t&&(r.emittedReadable=!1),0===t&&r.needReadable&&((0!==r.highWaterMark?r.length>=r.highWaterMark:r.length>0)||r.ended))return a("read: emitReadable",r.length,r.ended),0===r.length&&r.ended?J(this):I(this),null;if(0===(t=N(t,r))&&r.ended)return 0===r.length&&J(this),null;var o=r.needReadable;return a("need readable",o),(0===r.length||r.length-t<r.highWaterMark)&&a("length less than watermark",o=!0),r.ended||r.reading?a("reading or ended",o=!1):o&&(a("do read"),r.reading=!0,r.sync=!0,0===r.length&&(r.needReadable=!0),this._read(r.highWaterMark),r.sync=!1,r.reading||(t=N(n,r))),null===(e=t>0?H(t,r):null)?(r.needReadable=r.length<=r.highWaterMark,t=0):(r.length-=t,r.awaitDrain=0),0===r.length&&(r.ended||(r.needReadable=!0),n!==t&&r.ended&&J(this)),null!==e&&this.emit("data",e),e},P.prototype._read=function(t){O(this,new E("_read()"))},P.prototype.pipe=function(t,e){var r=this,n=this._readableState;switch(n.pipesCount){case 0:n.pipes=t;break;case 1:n.pipes=[n.pipes,t];break;default:n.pipes.push(t)}n.pipesCount+=1,a("pipe count=%d opts=%j",n.pipesCount,e);var i=e&&!1===e.end||t===o.stdout||t===o.stderr?b:u;function s(t,e){a("onunpipe"),t===r&&e&&!1===e.hasUnpiped&&(e.hasUnpiped=!0,p())}function u(){a("onend"),t.end()}n.endEmitted?o.nextTick(i):r.once("end",i),t.on("unpipe",s);var f=W(r);t.on("drain",f);var c=!1;function p(){a("cleanup"),t.removeListener("close",d),t.removeListener("finish",g),t.removeListener("drain",f),t.removeListener("error",y),t.removeListener("unpipe",s),r.removeListener("end",u),r.removeListener("end",b),r.removeListener("data",h),c=!0,n.awaitDrain&&(!t._writableState||t._writableState.needDrain)&&f()}function h(e){a("ondata");var o=t.write(e);a("dest.write",o),!1===o&&((1===n.pipesCount&&n.pipes===t||n.pipesCount>1&&-1!==K(n.pipes,t))&&!c&&(a("false write response, pause",n.awaitDrain),n.awaitDrain++),r.pause())}function y(e){a("onerror",e),b(),t.removeListener("error",y),0===l(t,"error")&&O(t,e)}function d(){t.removeListener("finish",g),b()}function g(){a("onfinish"),t.removeListener("close",d),b()}function b(){a("unpipe"),r.unpipe(t)}return r.on("data",h),R(t,"error",y),t.once("close",d),t.once("finish",g),t.emit("pipe",r),n.flowing||(a("pipe resume"),r.resume()),t},P.prototype.unpipe=function(t){var e=this._readableState,r={hasUnpiped:!1};if(0===e.pipesCount)return this;if(1===e.pipesCount)return t&&t!==e.pipes||(t||(t=e.pipes),e.pipes=null,e.pipesCount=0,e.flowing=!1,t&&t.emit("unpipe",this,r)),this;if(!t){var n=e.pipes,o=e.pipesCount;e.pipes=null,e.pipesCount=0,e.flowing=!1;for(var i=0;i<o;i++)n[i].emit("unpipe",this,{hasUnpiped:!1});return this}var a=K(e.pipes,t);return -1===a||(e.pipes.splice(a,1),e.pipesCount-=1,1===e.pipesCount&&(e.pipes=e.pipes[0]),t.emit("unpipe",this,r)),this},P.prototype.on=function(t,e){var r=c.prototype.on.call(this,t,e),n=this._readableState;return"data"===t?(n.readableListening=this.listenerCount("readable")>0,!1!==n.flowing&&this.resume()):"readable"!==t||n.endEmitted||n.readableListening||(n.readableListening=n.needReadable=!0,n.flowing=!1,n.emittedReadable=!1,a("on readable",n.length,n.reading),n.length?I(this):n.reading||o.nextTick(G,this)),r},P.prototype.addListener=P.prototype.on,P.prototype.removeListener=function(t,e){var r=c.prototype.removeListener.call(this,t,e);return"readable"===t&&o.nextTick(q,this),r},P.prototype.removeAllListeners=function(t){var e=c.prototype.removeAllListeners.apply(this,arguments);return("readable"===t||void 0===t)&&o.nextTick(q,this),e},P.prototype.resume=function(){var t=this._readableState;return t.flowing||(a("resume"),t.flowing=!t.readableListening,z(this,t)),t.paused=!1,this},P.prototype.pause=function(){return a("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(a("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},P.prototype.wrap=function(t){var e=this,r=this._readableState,n=!1;for(var o in t.on("end",function(){if(a("wrapped end"),r.decoder&&!r.ended){var t=r.decoder.end();t&&t.length&&e.push(t)}e.push(null)}),t.on("data",function(o){if(a("wrapped data"),r.decoder&&(o=r.decoder.write(o)),!r.objectMode||null!=o)(r.objectMode||o&&o.length)&&(e.push(o)||(n=!0,t.pause()))}),t)void 0===this[o]&&"function"==typeof t[o]&&(this[o]=function(e){return function(){return t[e].apply(t,arguments)}}(o));for(var i=0;i<x.length;i++)t.on(x[i],this.emit.bind(this,x[i]));return this._read=function(e){a("wrapped _read",e),n&&(n=!1,t.resume())},this},"function"==typeof Symbol&&(P.prototype[Symbol.asyncIterator]=function(){return void 0===u&&(u=n(871)),u(this)}),Object.defineProperty(P.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(P.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(P.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(t){this._readableState&&(this._readableState.flowing=t)}}),P._fromList=H,Object.defineProperty(P.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}}),"function"==typeof Symbol&&(P.from=function(t,e){return void 0===f&&(f=n(727)),f(P,t,e)})},170:function(t,e,r){"use strict";t.exports=l;var n=r(646).q,o=n.ERR_METHOD_NOT_IMPLEMENTED,i=n.ERR_MULTIPLE_CALLBACK,a=n.ERR_TRANSFORM_ALREADY_TRANSFORMING,s=n.ERR_TRANSFORM_WITH_LENGTH_0,u=r(403);function f(t,e){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(null===n)return this.emit("error",new i);r.writechunk=null,r.writecb=null,null!=e&&this.push(e),n(t);var o=this._readableState;o.reading=!1,(o.needReadable||o.length<o.highWaterMark)&&this._read(o.highWaterMark)}function l(t){if(!(this instanceof l))return new l(t);u.call(this,t),this._transformState={afterTransform:f.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,t&&("function"==typeof t.transform&&(this._transform=t.transform),"function"==typeof t.flush&&(this._flush=t.flush)),this.on("prefinish",c)}function c(){var t=this;"function"!=typeof this._flush||this._readableState.destroyed?p(this,null,null):this._flush(function(e,r){p(t,e,r)})}function p(t,e,r){if(e)return t.emit("error",e);if(null!=r&&t.push(r),t._writableState.length)throw new s;if(t._transformState.transforming)throw new a;return t.push(null)}r(782)(l,u),l.prototype.push=function(t,e){return this._transformState.needTransform=!1,u.prototype.push.call(this,t,e)},l.prototype._transform=function(t,e,r){r(new o("_transform()"))},l.prototype._write=function(t,e,r){var n=this._transformState;if(n.writecb=r,n.writechunk=t,n.writeencoding=e,!n.transforming){var o=this._readableState;(n.needTransform||o.needReadable||o.length<o.highWaterMark)&&this._read(o.highWaterMark)}},l.prototype._read=function(t){var e=this._transformState;null===e.writechunk||e.transforming?e.needTransform=!0:(e.transforming=!0,this._transform(e.writechunk,e.writeencoding,e.afterTransform))},l.prototype._destroy=function(t,e){u.prototype._destroy.call(this,t,function(t){e(t)})}},337:function(t,e,n){"use strict";function i(t){var e=this;this.next=null,this.entry=null,this.finish=function(){$(e,t)}}t.exports=j,j.WritableState=R;var a,s,u={deprecate:n(769)},f=n(678),l=n(300).Buffer,c=r.g.Uint8Array||function(){};function p(t){return l.from(t)}function h(t){return l.isBuffer(t)||t instanceof c}var y=n(25),d=n(776).getHighWaterMark,g=n(646).q,b=g.ERR_INVALID_ARG_TYPE,v=g.ERR_METHOD_NOT_IMPLEMENTED,m=g.ERR_MULTIPLE_CALLBACK,w=g.ERR_STREAM_CANNOT_PIPE,S=g.ERR_STREAM_DESTROYED,_=g.ERR_STREAM_NULL_VALUES,E=g.ERR_STREAM_WRITE_AFTER_END,A=g.ERR_UNKNOWN_ENCODING,O=y.errorOrDestroy;function x(){}function R(t,e,r){a=a||n(403),t=t||{},"boolean"!=typeof r&&(r=e instanceof a),this.objectMode=!!t.objectMode,r&&(this.objectMode=this.objectMode||!!t.writableObjectMode),this.highWaterMark=d(this,t,"writableHighWaterMark",r),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var o=!1===t.decodeStrings;this.decodeStrings=!o,this.defaultEncoding=t.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(t){C(e,t)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!1!==t.emitClose,this.autoDestroy=!!t.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new i(this)}function j(t){var e=this instanceof(a=a||n(403));if(!e&&!s.call(j,this))return new j(t);this._writableState=new R(t,this,e),this.writable=!0,t&&("function"==typeof t.write&&(this._write=t.write),"function"==typeof t.writev&&(this._writev=t.writev),"function"==typeof t.destroy&&(this._destroy=t.destroy),"function"==typeof t.final&&(this._final=t.final)),f.call(this)}function P(t,e){var r=new E;O(t,r),o.nextTick(e,r)}function T(t,e,r,n){var i;return null===r?i=new _:"string"==typeof r||e.objectMode||(i=new b("chunk",["string","Buffer"],r)),!i||(O(t,i),o.nextTick(n,i),!1)}function k(t,e,r){return t.objectMode||!1===t.decodeStrings||"string"!=typeof e||(e=l.from(e,r)),e}function M(t,e,r,n,o,i){if(!r){var a=k(e,n,o);n!==a&&(r=!0,o="buffer",n=a)}var s=e.objectMode?1:n.length;e.length+=s;var u=e.length<e.highWaterMark;if(u||(e.needDrain=!0),e.writing||e.corked){var f=e.lastBufferedRequest;e.lastBufferedRequest={chunk:n,encoding:o,isBuf:r,callback:i,next:null},f?f.next=e.lastBufferedRequest:e.bufferedRequest=e.lastBufferedRequest,e.bufferedRequestCount+=1}else L(t,e,!1,s,n,o,i);return u}function L(t,e,r,n,o,i,a){e.writelen=n,e.writecb=a,e.writing=!0,e.sync=!0,e.destroyed?e.onwrite(new S("write")):r?t._writev(o,e.onwrite):t._write(o,i,e.onwrite),e.sync=!1}function B(t,e,r,n,i){--e.pendingcb,r?(o.nextTick(i,n),o.nextTick(G,t,e),t._writableState.errorEmitted=!0,O(t,n)):(i(n),t._writableState.errorEmitted=!0,O(t,n),G(t,e))}function N(t){t.writing=!1,t.writecb=null,t.length-=t.writelen,t.writelen=0}function C(t,e){var r=t._writableState,n=r.sync,i=r.writecb;if("function"!=typeof i)throw new m;if(N(r),e)B(t,r,n,e,i);else{var a=F(r)||t.destroyed;a||r.corked||r.bufferProcessing||!r.bufferedRequest||D(t,r),n?o.nextTick(I,t,r,a,i):I(t,r,a,i)}}function I(t,e,r,n){r||U(t,e),e.pendingcb--,n(),G(t,e)}function U(t,e){0===e.length&&e.needDrain&&(e.needDrain=!1,t.emit("drain"))}function D(t,e){e.bufferProcessing=!0;var r=e.bufferedRequest;if(t._writev&&r&&r.next){var n=Array(e.bufferedRequestCount),o=e.corkedRequestsFree;o.entry=r;for(var a=0,s=!0;r;)n[a]=r,r.isBuf||(s=!1),r=r.next,a+=1;n.allBuffers=s,L(t,e,!0,e.length,n,"",o.finish),e.pendingcb++,e.lastBufferedRequest=null,o.next?(e.corkedRequestsFree=o.next,o.next=null):e.corkedRequestsFree=new i(e),e.bufferedRequestCount=0}else{for(;r;){var u=r.chunk,f=r.encoding,l=r.callback,c=e.objectMode?1:u.length;if(L(t,e,!1,c,u,f,l),r=r.next,e.bufferedRequestCount--,e.writing)break}null===r&&(e.lastBufferedRequest=null)}e.bufferedRequest=r,e.bufferProcessing=!1}function F(t){return t.ending&&0===t.length&&null===t.bufferedRequest&&!t.finished&&!t.writing}function W(t,e){t._final(function(r){e.pendingcb--,r&&O(t,r),e.prefinished=!0,t.emit("prefinish"),G(t,e)})}function q(t,e){e.prefinished||e.finalCalled||("function"!=typeof t._final||e.destroyed?(e.prefinished=!0,t.emit("prefinish")):(e.pendingcb++,e.finalCalled=!0,o.nextTick(W,t,e)))}function G(t,e){var r=F(e);if(r&&(q(t,e),0===e.pendingcb)&&(e.finished=!0,t.emit("finish"),e.autoDestroy)){var n=t._readableState;(!n||n.autoDestroy&&n.endEmitted)&&t.destroy()}return r}function z(t,e,r){e.ending=!0,G(t,e),r&&(e.finished?o.nextTick(r):t.once("finish",r)),e.ended=!0,t.writable=!1}function $(t,e,r){var n=t.entry;for(t.entry=null;n;){var o=n.callback;e.pendingcb--,o(r),n=n.next}e.corkedRequestsFree.next=t}n(782)(j,f),R.prototype.getBuffer=function(){for(var t=this.bufferedRequest,e=[];t;)e.push(t),t=t.next;return e},function(){try{Object.defineProperty(R.prototype,"buffer",{get:u.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(t){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(s=Function.prototype[Symbol.hasInstance],Object.defineProperty(j,Symbol.hasInstance,{value:function(t){return!!s.call(this,t)||this===j&&t&&t._writableState instanceof R}})):s=function(t){return t instanceof this},j.prototype.pipe=function(){O(this,new w)},j.prototype.write=function(t,e,r){var n=this._writableState,o=!1,i=!n.objectMode&&h(t);return i&&!l.isBuffer(t)&&(t=p(t)),"function"==typeof e&&(r=e,e=null),i?e="buffer":e||(e=n.defaultEncoding),"function"!=typeof r&&(r=x),n.ending?P(this,r):(i||T(this,n,t,r))&&(n.pendingcb++,o=M(this,n,i,t,e,r)),o},j.prototype.cork=function(){this._writableState.corked++},j.prototype.uncork=function(){var t=this._writableState;t.corked&&(t.corked--,t.writing||t.corked||t.bufferProcessing||!t.bufferedRequest||D(this,t))},j.prototype.setDefaultEncoding=function(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new A(t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(j.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(j.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),j.prototype._write=function(t,e,r){r(new v("_write()"))},j.prototype._writev=null,j.prototype.end=function(t,e,r){var n=this._writableState;return"function"==typeof t?(r=t,t=null,e=null):"function"==typeof e&&(r=e,e=null),null!=t&&this.write(t,e),n.corked&&(n.corked=1,this.uncork()),n.ending||z(this,n,r),this},Object.defineProperty(j.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(j.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(t){this._writableState&&(this._writableState.destroyed=t)}}),j.prototype.destroy=y.destroy,j.prototype._undestroy=y.undestroy,j.prototype._destroy=function(t,e){e(t)}},871:function(t,e,r){"use strict";function n(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var i,a=r(698),s=Symbol("lastResolve"),u=Symbol("lastReject"),f=Symbol("error"),l=Symbol("ended"),c=Symbol("lastPromise"),p=Symbol("handlePromise"),h=Symbol("stream");function y(t,e){return{value:t,done:e}}function d(t){var e=t[s];if(null!==e){var r=t[h].read();null!==r&&(t[c]=null,t[s]=null,t[u]=null,e(y(r,!1)))}}function g(t){o.nextTick(d,t)}function b(t,e){return function(r,n){t.then(function(){if(e[l])return void r(y(void 0,!0));e[p](r,n)},n)}}var v=Object.getPrototypeOf(function(){}),m=Object.setPrototypeOf((n(i={get stream(){return this[h]},next:function(){var t,e=this,r=this[f];if(null!==r)return Promise.reject(r);if(this[l])return Promise.resolve(y(void 0,!0));if(this[h].destroyed)return new Promise(function(t,r){o.nextTick(function(){e[f]?r(e[f]):t(y(void 0,!0))})});var n=this[c];if(n)t=new Promise(b(n,this));else{var i=this[h].read();if(null!==i)return Promise.resolve(y(i,!1));t=new Promise(this[p])}return this[c]=t,t}},Symbol.asyncIterator,function(){return this}),n(i,"return",function(){var t=this;return new Promise(function(e,r){t[h].destroy(null,function(t){if(t)return void r(t);e(y(void 0,!0))})})}),i),v);t.exports=function(t){var e,r=Object.create(m,(n(e={},h,{value:t,writable:!0}),n(e,s,{value:null,writable:!0}),n(e,u,{value:null,writable:!0}),n(e,f,{value:null,writable:!0}),n(e,l,{value:t._readableState.endEmitted,writable:!0}),n(e,p,{value:function(t,e){var n=r[h].read();n?(r[c]=null,r[s]=null,r[u]=null,t(y(n,!1))):(r[s]=t,r[u]=e)},writable:!0}),e));return r[c]=null,a(t,function(t){if(t&&"ERR_STREAM_PREMATURE_CLOSE"!==t.code){var e=r[u];null!==e&&(r[c]=null,r[s]=null,r[u]=null,e(t)),r[f]=t;return}var n=r[s];null!==n&&(r[c]=null,r[s]=null,r[u]=null,n(y(void 0,!0))),r[l]=!0}),t.on("readable",g.bind(null,r)),r}},379:function(t,e,r){"use strict";function n(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,n)}return r}function o(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?n(Object(r),!0).forEach(function(e){i(t,e,r[e])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):n(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))})}return t}function i(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function a(t,e){if(!(t instanceof e))throw TypeError("Cannot call a class as a function")}function s(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function u(t,e,r){return e&&s(t.prototype,e),r&&s(t,r),t}var f=r(300).Buffer,l=r(837).inspect,c=l&&l.custom||"inspect";function p(t,e,r){f.prototype.copy.call(t,e,r)}t.exports=function(){function t(){a(this,t),this.head=null,this.tail=null,this.length=0}return u(t,[{key:"push",value:function(t){var e={data:t,next:null};this.length>0?this.tail.next=e:this.head=e,this.tail=e,++this.length}},{key:"unshift",value:function(t){var e={data:t,next:this.head};0===this.length&&(this.tail=e),this.head=e,++this.length}},{key:"shift",value:function(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(t){if(0===this.length)return"";for(var e=this.head,r=""+e.data;e=e.next;)r+=t+e.data;return r}},{key:"concat",value:function(t){if(0===this.length)return f.alloc(0);for(var e=f.allocUnsafe(t>>>0),r=this.head,n=0;r;)p(r.data,e,n),n+=r.data.length,r=r.next;return e}},{key:"consume",value:function(t,e){var r;return t<this.head.data.length?(r=this.head.data.slice(0,t),this.head.data=this.head.data.slice(t)):r=t===this.head.data.length?this.shift():e?this._getString(t):this._getBuffer(t),r}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(t){var e=this.head,r=1,n=e.data;for(t-=n.length;e=e.next;){var o=e.data,i=t>o.length?o.length:t;if(i===o.length?n+=o:n+=o.slice(0,t),0==(t-=i)){i===o.length?(++r,e.next?this.head=e.next:this.head=this.tail=null):(this.head=e,e.data=o.slice(i));break}++r}return this.length-=r,n}},{key:"_getBuffer",value:function(t){var e=f.allocUnsafe(t),r=this.head,n=1;for(r.data.copy(e),t-=r.data.length;r=r.next;){var o=r.data,i=t>o.length?o.length:t;if(o.copy(e,e.length-t,0,i),0==(t-=i)){i===o.length?(++n,r.next?this.head=r.next:this.head=this.tail=null):(this.head=r,r.data=o.slice(i));break}++n}return this.length-=n,e}},{key:c,value:function(t,e){return l(this,o({},e,{depth:0,customInspect:!1}))}}]),t}()},25:function(t){"use strict";function e(t,e){n(t,e),r(t)}function r(t){(!t._writableState||t._writableState.emitClose)&&(!t._readableState||t._readableState.emitClose)&&t.emit("close")}function n(t,e){t.emit("error",e)}t.exports={destroy:function(t,i){var a=this,s=this._readableState&&this._readableState.destroyed,u=this._writableState&&this._writableState.destroyed;return s||u?i?i(t):t&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,o.nextTick(n,this,t)):o.nextTick(n,this,t)):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(t||null,function(t){!i&&t?a._writableState?a._writableState.errorEmitted?o.nextTick(r,a):(a._writableState.errorEmitted=!0,o.nextTick(e,a,t)):o.nextTick(e,a,t):i?(o.nextTick(r,a),i(t)):o.nextTick(r,a)})),this},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)},errorOrDestroy:function(t,e){var r=t._readableState,n=t._writableState;r&&r.autoDestroy||n&&n.autoDestroy?t.destroy(e):t.emit("error",e)}}},698:function(t,e,r){"use strict";var n=r(646).q.ERR_STREAM_PREMATURE_CLOSE;function o(t){var e=!1;return function(){if(!e){e=!0;for(var r=arguments.length,n=Array(r),o=0;o<r;o++)n[o]=arguments[o];t.apply(this,n)}}}function i(){}function a(t){return t.setHeader&&"function"==typeof t.abort}function s(t,e,r){if("function"==typeof e)return s(t,null,e);e||(e={}),r=o(r||i);var u=e.readable||!1!==e.readable&&t.readable,f=e.writable||!1!==e.writable&&t.writable,l=function(){t.writable||p()},c=t._writableState&&t._writableState.finished,p=function(){f=!1,c=!0,u||r.call(t)},h=t._readableState&&t._readableState.endEmitted,y=function(){u=!1,h=!0,f||r.call(t)},d=function(e){r.call(t,e)},g=function(){var e;return u&&!h?(t._readableState&&t._readableState.ended||(e=new n),r.call(t,e)):f&&!c?(t._writableState&&t._writableState.ended||(e=new n),r.call(t,e)):void 0},b=function(){t.req.on("finish",p)};return a(t)?(t.on("complete",p),t.on("abort",g),t.req?b():t.on("request",b)):f&&!t._writableState&&(t.on("end",l),t.on("close",l)),t.on("end",y),t.on("finish",p),!1!==e.error&&t.on("error",d),t.on("close",g),function(){t.removeListener("complete",p),t.removeListener("abort",g),t.removeListener("request",b),t.req&&t.req.removeListener("finish",p),t.removeListener("end",l),t.removeListener("close",l),t.removeListener("finish",p),t.removeListener("end",y),t.removeListener("error",d),t.removeListener("close",g)}}t.exports=s},727:function(t,e,r){"use strict";function n(t,e,r,n,o,i,a){try{var s=t[i](a),u=s.value}catch(t){r(t);return}s.done?e(u):Promise.resolve(u).then(n,o)}function o(t){return function(){var e=this,r=arguments;return new Promise(function(o,i){var a=t.apply(e,r);function s(t){n(a,o,i,s,u,"next",t)}function u(t){n(a,o,i,s,u,"throw",t)}s(void 0)})}}function i(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,n)}return r}function a(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?i(Object(r),!0).forEach(function(e){s(t,e,r[e])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))})}return t}function s(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var u=r(646).q.ERR_INVALID_ARG_TYPE;t.exports=function(t,e,r){if(e&&"function"==typeof e.next)n=e;else if(e&&e[Symbol.asyncIterator])n=e[Symbol.asyncIterator]();else if(e&&e[Symbol.iterator])n=e[Symbol.iterator]();else throw new u("iterable",["Iterable"],e);var n,i=new t(a({objectMode:!0},r)),s=!1;function f(){return l.apply(this,arguments)}function l(){return(l=o(function*(){try{var t=yield n.next(),e=t.value;t.done?i.push(null):i.push((yield e))?f():s=!1}catch(t){i.destroy(t)}})).apply(this,arguments)}return i._read=function(){s||(s=!0,f())},i}},442:function(t,e,r){"use strict";function n(t){var e=!1;return function(){e||(e=!0,t.apply(void 0,arguments))}}var o,i=r(646).q,a=i.ERR_MISSING_ARGS,s=i.ERR_STREAM_DESTROYED;function u(t){if(t)throw t}function f(t){return t.setHeader&&"function"==typeof t.abort}function l(t,e,i,a){a=n(a);var u=!1;t.on("close",function(){u=!0}),void 0===o&&(o=r(698)),o(t,{readable:e,writable:i},function(t){if(t)return a(t);u=!0,a()});var l=!1;return function(e){if(!u&&!l){if(l=!0,f(t))return t.abort();if("function"==typeof t.destroy)return t.destroy();a(e||new s("pipe"))}}}function c(t){t()}function p(t,e){return t.pipe(e)}function h(t){return t.length&&"function"==typeof t[t.length-1]?t.pop():u}t.exports=function(){for(var t,e=arguments.length,r=Array(e),n=0;n<e;n++)r[n]=arguments[n];var o=h(r);if(Array.isArray(r[0])&&(r=r[0]),r.length<2)throw new a("streams");var i=r.map(function(e,n){var a=n<r.length-1;return l(e,a,n>0,function(e){t||(t=e),e&&i.forEach(c),a||(i.forEach(c),o(t))})});return r.reduce(p)}},776:function(t,e,r){"use strict";var n=r(646).q.ERR_INVALID_OPT_VALUE;function o(t,e,r){return null!=t.highWaterMark?t.highWaterMark:e?t[r]:null}t.exports={getHighWaterMark:function(t,e,r,i){var a=o(e,i,r);if(null!=a){if(!(isFinite(a)&&Math.floor(a)===a)||a<0)throw new n(i?r:"highWaterMark",a);return Math.floor(a)}return t.objectMode?16:16384}}},678:function(t,e,r){t.exports=r(781)},55:function(t,e,r){var n=r(300),o=n.Buffer;function i(t,e){for(var r in t)e[r]=t[r]}function a(t,e,r){return o(t,e,r)}o.from&&o.alloc&&o.allocUnsafe&&o.allocUnsafeSlow?t.exports=n:(i(n,e),e.Buffer=a),a.prototype=Object.create(o.prototype),i(o,a),a.from=function(t,e,r){if("number"==typeof t)throw TypeError("Argument must not be a number");return o(t,e,r)},a.alloc=function(t,e,r){if("number"!=typeof t)throw TypeError("Argument must be a number");var n=o(t);return void 0!==e?"string"==typeof r?n.fill(e,r):n.fill(e):n.fill(0),n},a.allocUnsafe=function(t){if("number"!=typeof t)throw TypeError("Argument must be a number");return o(t)},a.allocUnsafeSlow=function(t){if("number"!=typeof t)throw TypeError("Argument must be a number");return n.SlowBuffer(t)}},173:function(t,e,r){t.exports=o;var n=r(361).EventEmitter;function o(){n.call(this)}r(782)(o,n),o.Readable=r(709),o.Writable=r(337),o.Duplex=r(403),o.Transform=r(170),o.PassThrough=r(889),o.finished=r(698),o.pipeline=r(442),o.Stream=o,o.prototype.pipe=function(t,e){var r=this;function o(e){t.writable&&!1===t.write(e)&&r.pause&&r.pause()}function i(){r.readable&&r.resume&&r.resume()}r.on("data",o),t.on("drain",i),t._isStdio||e&&!1===e.end||(r.on("end",s),r.on("close",u));var a=!1;function s(){a||(a=!0,t.end())}function u(){a||(a=!0,"function"==typeof t.destroy&&t.destroy())}function f(t){if(l(),0===n.listenerCount(this,"error"))throw t}function l(){r.removeListener("data",o),t.removeListener("drain",i),r.removeListener("end",s),r.removeListener("close",u),r.removeListener("error",f),t.removeListener("error",f),r.removeListener("end",l),r.removeListener("close",l),t.removeListener("close",l)}return r.on("error",f),t.on("error",f),r.on("end",l),r.on("close",l),t.on("close",l),t.emit("pipe",r),t}},704:function(t,e,r){"use strict";var n=r(55).Buffer,o=n.isEncoding||function(t){switch((t=""+t)&&t.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function i(t){var e;if(!t)return"utf8";for(;;)switch(t){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return t;default:if(e)return;t=(""+t).toLowerCase(),e=!0}}function a(t){var e=i(t);if("string"!=typeof e&&(n.isEncoding===o||!o(t)))throw Error("Unknown encoding: "+t);return e||t}function s(t){var e;switch(this.encoding=a(t),this.encoding){case"utf16le":this.text=y,this.end=d,e=4;break;case"utf8":this.fillLast=c,e=4;break;case"base64":this.text=g,this.end=b,e=3;break;default:this.write=v,this.end=m;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=n.allocUnsafe(e)}function u(t){return t<=127?0:t>>5==6?2:t>>4==14?3:t>>3==30?4:t>>6==2?-1:-2}function f(t,e,r){var n=e.length-1;if(n<r)return 0;var o=u(e[n]);return o>=0?(o>0&&(t.lastNeed=o-1),o):--n<r||-2===o?0:(o=u(e[n]))>=0?(o>0&&(t.lastNeed=o-2),o):--n<r||-2===o?0:(o=u(e[n]))>=0?(o>0&&(2===o?o=0:t.lastNeed=o-3),o):0}function l(t,e,r){if((192&e[0])!=128)return t.lastNeed=0,"�";if(t.lastNeed>1&&e.length>1){if((192&e[1])!=128)return t.lastNeed=1,"�";if(t.lastNeed>2&&e.length>2&&(192&e[2])!=128)return t.lastNeed=2,"�"}}function c(t){var e=this.lastTotal-this.lastNeed,r=l(this,t,e);return void 0!==r?r:this.lastNeed<=t.length?(t.copy(this.lastChar,e,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):void(t.copy(this.lastChar,e,0,t.length),this.lastNeed-=t.length)}function p(t,e){var r=f(this,t,e);if(!this.lastNeed)return t.toString("utf8",e);this.lastTotal=r;var n=t.length-(r-this.lastNeed);return t.copy(this.lastChar,0,n),t.toString("utf8",e,n)}function h(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+"�":e}function y(t,e){if((t.length-e)%2==0){var r=t.toString("utf16le",e);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=t[t.length-1],t.toString("utf16le",e,t.length-1)}function d(t){var e=t&&t.length?this.write(t):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return e+this.lastChar.toString("utf16le",0,r)}return e}function g(t,e){var r=(t.length-e)%3;return 0===r?t.toString("base64",e):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=t[t.length-1]:(this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1]),t.toString("base64",e,t.length-r))}function b(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function v(t){return t.toString(this.encoding)}function m(t){return t&&t.length?this.write(t):""}e.s=s,s.prototype.write=function(t){var e,r;if(0===t.length)return"";if(this.lastNeed){if(void 0===(e=this.fillLast(t)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<t.length?e?e+this.text(t,r):this.text(t,r):e||""},s.prototype.end=h,s.prototype.text=p,s.prototype.fillLast=function(t){if(this.lastNeed<=t.length)return t.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);t.copy(this.lastChar,this.lastTotal-this.lastNeed,0,t.length),this.lastNeed-=t.length}},769:function(t){function e(t){try{if(!r.g.localStorage)return!1}catch(t){return!1}var e=r.g.localStorage[t];return null!=e&&"true"===String(e).toLowerCase()}t.exports=function t(t,r){if(e("noDeprecation"))return t;var n=!1;return function(){if(!n){if(e("throwDeprecation"))throw Error(r);e("traceDeprecation")?console.trace(r):console.warn(r),n=!0}return t.apply(this,arguments)}}},300:function(t){"use strict";t.exports=r(3063)},361:function(t){"use strict";t.exports=r(48429)},781:function(t){"use strict";t.exports=r(48429).EventEmitter},837:function(t){"use strict";t.exports=r(80839)}},i={};function a(t){var r=i[t];if(void 0!==r)return r.exports;var n=i[t]={exports:{}},o=!0;try{e[t](n,n.exports,a),o=!1}finally{o&&delete i[t]}return n.exports}a.ab=n+"/",t.exports=a(173)}()},48429:t=>{var e="/";!function(){"use strict";var r={864:function(t){var e,r="object"==typeof Reflect?Reflect:null,n=r&&"function"==typeof r.apply?r.apply:function(t,e,r){return Function.prototype.apply.call(t,e,r)};function o(t){console&&console.warn&&console.warn(t)}e=r&&"function"==typeof r.ownKeys?r.ownKeys:Object.getOwnPropertySymbols?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:function(t){return Object.getOwnPropertyNames(t)};var i=Number.isNaN||function(t){return t!=t};function a(){a.init.call(this)}t.exports=a,t.exports.once=v,a.EventEmitter=a,a.prototype._events=void 0,a.prototype._eventsCount=0,a.prototype._maxListeners=void 0;var s=10;function u(t){if("function"!=typeof t)throw TypeError('The "listener" argument must be of type Function. Received type '+typeof t)}function f(t){return void 0===t._maxListeners?a.defaultMaxListeners:t._maxListeners}function l(t,e,r,n){if(u(r),void 0===(a=t._events)?(a=t._events=Object.create(null),t._eventsCount=0):(void 0!==a.newListener&&(t.emit("newListener",e,r.listener?r.listener:r),a=t._events),s=a[e]),void 0===s)s=a[e]=r,++t._eventsCount;else if("function"==typeof s?s=a[e]=n?[r,s]:[s,r]:n?s.unshift(r):s.push(r),(i=f(t))>0&&s.length>i&&!s.warned){s.warned=!0;var i,a,s,l=Error("Possible EventEmitter memory leak detected. "+s.length+" "+String(e)+" listeners added. Use emitter.setMaxListeners() to increase limit");l.name="MaxListenersExceededWarning",l.emitter=t,l.type=e,l.count=s.length,o(l)}return t}function c(){if(!this.fired)return(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0==arguments.length)?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function p(t,e,r){var n={fired:!1,wrapFn:void 0,target:t,type:e,listener:r},o=c.bind(n);return o.listener=r,n.wrapFn=o,o}function h(t,e,r){var n=t._events;if(void 0===n)return[];var o=n[e];return void 0===o?[]:"function"==typeof o?r?[o.listener||o]:[o]:r?b(o):d(o,o.length)}function y(t){var e=this._events;if(void 0!==e){var r=e[t];if("function"==typeof r)return 1;if(void 0!==r)return r.length}return 0}function d(t,e){for(var r=Array(e),n=0;n<e;++n)r[n]=t[n];return r}function g(t,e){for(;e+1<t.length;e++)t[e]=t[e+1];t.pop()}function b(t){for(var e=Array(t.length),r=0;r<e.length;++r)e[r]=t[r].listener||t[r];return e}function v(t,e){return new Promise(function(r,n){function o(r){t.removeListener(e,i),n(r)}function i(){"function"==typeof t.removeListener&&t.removeListener("error",o),r([].slice.call(arguments))}w(t,e,i,{once:!0}),"error"!==e&&m(t,o,{once:!0})})}function m(t,e,r){"function"==typeof t.on&&w(t,"error",e,r)}function w(t,e,r,n){if("function"==typeof t.on)n.once?t.once(e,r):t.on(e,r);else if("function"==typeof t.addEventListener)t.addEventListener(e,function o(i){n.once&&t.removeEventListener(e,o),r(i)});else throw TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof t)}Object.defineProperty(a,"defaultMaxListeners",{enumerable:!0,get:function(){return s},set:function(t){if("number"!=typeof t||t<0||i(t))throw RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+t+".");s=t}}),a.init=function(){(void 0===this._events||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},a.prototype.setMaxListeners=function(t){if("number"!=typeof t||t<0||i(t))throw RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+t+".");return this._maxListeners=t,this},a.prototype.getMaxListeners=function(){return f(this)},a.prototype.emit=function(t){for(var e=[],r=1;r<arguments.length;r++)e.push(arguments[r]);var o="error"===t,i=this._events;if(void 0!==i)o=o&&void 0===i.error;else if(!o)return!1;if(o){if(e.length>0&&(a=e[0]),a instanceof Error)throw a;var a,s=Error("Unhandled error."+(a?" ("+a.message+")":""));throw s.context=a,s}var u=i[t];if(void 0===u)return!1;if("function"==typeof u)n(u,this,e);else for(var f=u.length,l=d(u,f),r=0;r<f;++r)n(l[r],this,e);return!0},a.prototype.addListener=function(t,e){return l(this,t,e,!1)},a.prototype.on=a.prototype.addListener,a.prototype.prependListener=function(t,e){return l(this,t,e,!0)},a.prototype.once=function(t,e){return u(e),this.on(t,p(this,t,e)),this},a.prototype.prependOnceListener=function(t,e){return u(e),this.prependListener(t,p(this,t,e)),this},a.prototype.removeListener=function(t,e){var r,n,o,i,a;if(u(e),void 0===(n=this._events)||void 0===(r=n[t]))return this;if(r===e||r.listener===e)0==--this._eventsCount?this._events=Object.create(null):(delete n[t],n.removeListener&&this.emit("removeListener",t,r.listener||e));else if("function"!=typeof r){for(o=-1,i=r.length-1;i>=0;i--)if(r[i]===e||r[i].listener===e){a=r[i].listener,o=i;break}if(o<0)return this;0===o?r.shift():g(r,o),1===r.length&&(n[t]=r[0]),void 0!==n.removeListener&&this.emit("removeListener",t,a||e)}return this},a.prototype.off=a.prototype.removeListener,a.prototype.removeAllListeners=function(t){var e,r,n;if(void 0===(r=this._events))return this;if(void 0===r.removeListener)return 0==arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==r[t]&&(0==--this._eventsCount?this._events=Object.create(null):delete r[t]),this;if(0==arguments.length){var o,i=Object.keys(r);for(n=0;n<i.length;++n)"removeListener"!==(o=i[n])&&this.removeAllListeners(o);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(e=r[t]))this.removeListener(t,e);else if(void 0!==e)for(n=e.length-1;n>=0;n--)this.removeListener(t,e[n]);return this},a.prototype.listeners=function(t){return h(this,t,!0)},a.prototype.rawListeners=function(t){return h(this,t,!1)},a.listenerCount=function(t,e){return"function"==typeof t.listenerCount?t.listenerCount(e):y.call(t,e)},a.prototype.listenerCount=y,a.prototype.eventNames=function(){return this._eventsCount>0?e(this._events):[]}}},n={};function o(t){var e=n[t];if(void 0!==e)return e.exports;var i=n[t]={exports:{}},a=!0;try{r[t](i,i.exports,o),a=!1}finally{a&&delete n[t]}return i.exports}o.ab=e+"/",t.exports=o(864)}()},73283:(t,e,r)=>{var n="/";!function(){var e={55:function(t,e,r){var n=r(300),o=n.Buffer;function i(t,e){for(var r in t)e[r]=t[r]}function a(t,e,r){return o(t,e,r)}o.from&&o.alloc&&o.allocUnsafe&&o.allocUnsafeSlow?t.exports=n:(i(n,e),e.Buffer=a),a.prototype=Object.create(o.prototype),i(o,a),a.from=function(t,e,r){if("number"==typeof t)throw TypeError("Argument must not be a number");return o(t,e,r)},a.alloc=function(t,e,r){if("number"!=typeof t)throw TypeError("Argument must be a number");var n=o(t);return void 0!==e?"string"==typeof r?n.fill(e,r):n.fill(e):n.fill(0),n},a.allocUnsafe=function(t){if("number"!=typeof t)throw TypeError("Argument must be a number");return o(t)},a.allocUnsafeSlow=function(t){if("number"!=typeof t)throw TypeError("Argument must be a number");return n.SlowBuffer(t)}},300:function(t){"use strict";t.exports=r(3063)}},o={};function i(t){var r=o[t];if(void 0!==r)return r.exports;var n=o[t]={exports:{}},a=!0;try{e[t](n,n.exports,i),a=!1}finally{a&&delete o[t]}return n.exports}i.ab=n+"/";var a={};!function(){"use strict";var t=a,e=i(55).Buffer,r=e.isEncoding||function(t){switch((t=""+t)&&t.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function n(t){var e;if(!t)return"utf8";for(;;)switch(t){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return t;default:if(e)return;t=(""+t).toLowerCase(),e=!0}}function o(t){var o=n(t);if("string"!=typeof o&&(e.isEncoding===r||!r(t)))throw Error("Unknown encoding: "+t);return o||t}function s(t){var r;switch(this.encoding=o(t),this.encoding){case"utf16le":this.text=y,this.end=d,r=4;break;case"utf8":this.fillLast=c,r=4;break;case"base64":this.text=g,this.end=b,r=3;break;default:this.write=v,this.end=m;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=e.allocUnsafe(r)}function u(t){return t<=127?0:t>>5==6?2:t>>4==14?3:t>>3==30?4:t>>6==2?-1:-2}function f(t,e,r){var n=e.length-1;if(n<r)return 0;var o=u(e[n]);return o>=0?(o>0&&(t.lastNeed=o-1),o):--n<r||-2===o?0:(o=u(e[n]))>=0?(o>0&&(t.lastNeed=o-2),o):--n<r||-2===o?0:(o=u(e[n]))>=0?(o>0&&(2===o?o=0:t.lastNeed=o-3),o):0}function l(t,e,r){if((192&e[0])!=128)return t.lastNeed=0,"�";if(t.lastNeed>1&&e.length>1){if((192&e[1])!=128)return t.lastNeed=1,"�";if(t.lastNeed>2&&e.length>2&&(192&e[2])!=128)return t.lastNeed=2,"�"}}function c(t){var e=this.lastTotal-this.lastNeed,r=l(this,t,e);return void 0!==r?r:this.lastNeed<=t.length?(t.copy(this.lastChar,e,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):void(t.copy(this.lastChar,e,0,t.length),this.lastNeed-=t.length)}function p(t,e){var r=f(this,t,e);if(!this.lastNeed)return t.toString("utf8",e);this.lastTotal=r;var n=t.length-(r-this.lastNeed);return t.copy(this.lastChar,0,n),t.toString("utf8",e,n)}function h(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+"�":e}function y(t,e){if((t.length-e)%2==0){var r=t.toString("utf16le",e);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=t[t.length-1],t.toString("utf16le",e,t.length-1)}function d(t){var e=t&&t.length?this.write(t):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return e+this.lastChar.toString("utf16le",0,r)}return e}function g(t,e){var r=(t.length-e)%3;return 0===r?t.toString("base64",e):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=t[t.length-1]:(this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1]),t.toString("base64",e,t.length-r))}function b(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function v(t){return t.toString(this.encoding)}function m(t){return t&&t.length?this.write(t):""}t.StringDecoder=s,s.prototype.write=function(t){var e,r;if(0===t.length)return"";if(this.lastNeed){if(void 0===(e=this.fillLast(t)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<t.length?e?e+this.text(t,r):this.text(t,r):e||""},s.prototype.end=h,s.prototype.text=p,s.prototype.fillLast=function(t){if(this.lastNeed<=t.length)return t.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);t.copy(this.lastChar,this.lastTotal-this.lastNeed,0,t.length),this.lastNeed-=t.length}}(),t.exports=a}()},80839:(t,e,r)=>{var n="/",o=r(3063).Buffer,i=r(77011);!function(){var e={992:function(t){t.exports=function(t,r,n){if(t.filter)return t.filter(r,n);if(null==t||"function"!=typeof r)throw TypeError();for(var o=[],i=0;i<t.length;i++)if(e.call(t,i)){var a=t[i];r.call(n,a,i,t)&&o.push(a)}return o};var e=Object.prototype.hasOwnProperty},256:function(t,e,r){"use strict";var n=r(192),o=r(139),i=o(n("String.prototype.indexOf"));t.exports=function(t,e){var r=n(t,!!e);return"function"==typeof r&&i(t,".prototype.")>-1?o(r):r}},139:function(t,e,r){"use strict";var n=r(212),o=r(192),i=o("%Function.prototype.apply%"),a=o("%Function.prototype.call%"),s=o("%Reflect.apply%",!0)||n.call(a,i),u=o("%Object.getOwnPropertyDescriptor%",!0),f=o("%Object.defineProperty%",!0),l=o("%Math.max%");if(f)try{f({},"a",{value:1})}catch(t){f=null}t.exports=function(t){var e=s(n,a,arguments);return u&&f&&u(e,"length").configurable&&f(e,"length",{value:1+l(0,t.length-(arguments.length-1))}),e};var c=function(){return s(n,i,arguments)};f?f(t.exports,"apply",{value:c}):t.exports.apply=c},181:function(t){"use strict";t.exports=EvalError},545:function(t){"use strict";t.exports=Error},22:function(t){"use strict";t.exports=RangeError},803:function(t){"use strict";t.exports=ReferenceError},182:function(t){"use strict";t.exports=SyntaxError},202:function(t){"use strict";t.exports=TypeError},284:function(t){"use strict";t.exports=URIError},144:function(t){var e=Object.prototype.hasOwnProperty,r=Object.prototype.toString;t.exports=function(t,n,o){if("[object Function]"!==r.call(n))throw TypeError("iterator must be a function");var i=t.length;if(i===+i)for(var a=0;a<i;a++)n.call(o,t[a],a,t);else for(var s in t)e.call(t,s)&&n.call(o,t[s],s,t)}},136:function(t){"use strict";var e="Function.prototype.bind called on incompatible ",r=Object.prototype.toString,n=Math.max,o="[object Function]",i=function(t,e){for(var r=[],n=0;n<t.length;n+=1)r[n]=t[n];for(var o=0;o<e.length;o+=1)r[o+t.length]=e[o];return r},a=function(t,e){for(var r=[],n=e||0,o=0;n<t.length;n+=1,o+=1)r[o]=t[n];return r},s=function(t,e){for(var r="",n=0;n<t.length;n+=1)r+=t[n],n+1<t.length&&(r+=e);return r};t.exports=function(t){var u,f=this;if("function"!=typeof f||r.apply(f)!==o)throw TypeError(e+f);for(var l=a(arguments,1),c=function(){if(this instanceof u){var e=f.apply(this,i(l,arguments));return Object(e)===e?e:this}return f.apply(t,i(l,arguments))},p=n(0,f.length-l.length),h=[],y=0;y<p;y++)h[y]="$"+y;if(u=Function("binder","return function ("+s(h,",")+"){ return binder.apply(this,arguments); }")(c),f.prototype){var d=function(){};d.prototype=f.prototype,u.prototype=new d,d.prototype=null}return u}},212:function(t,e,r){"use strict";var n=r(136);t.exports=Function.prototype.bind||n},192:function(t,e,r){"use strict";var n,o=r(545),i=r(181),a=r(22),s=r(803),u=r(182),f=r(202),l=r(284),c=Function,p=function(t){try{return c('"use strict"; return ('+t+").constructor;")()}catch(t){}},h=Object.getOwnPropertyDescriptor;if(h)try{h({},"")}catch(t){h=null}var y=function(){throw new f},d=h?function(){try{return arguments.callee,y}catch(t){try{return h(arguments,"callee").get}catch(t){return y}}}():y,g=r(115)(),b=r(14)(),v=Object.getPrototypeOf||(b?function(t){return t.__proto__}:null),m={},w="undefined"!=typeof Uint8Array&&v?v(Uint8Array):n,S={__proto__:null,"%AggregateError%":"undefined"==typeof AggregateError?n:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?n:ArrayBuffer,"%ArrayIteratorPrototype%":g&&v?v([][Symbol.iterator]()):n,"%AsyncFromSyncIteratorPrototype%":n,"%AsyncFunction%":m,"%AsyncGenerator%":m,"%AsyncGeneratorFunction%":m,"%AsyncIteratorPrototype%":m,"%Atomics%":"undefined"==typeof Atomics?n:Atomics,"%BigInt%":"undefined"==typeof BigInt?n:BigInt,"%BigInt64Array%":"undefined"==typeof BigInt64Array?n:BigInt64Array,"%BigUint64Array%":"undefined"==typeof BigUint64Array?n:BigUint64Array,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?n:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":o,"%eval%":eval,"%EvalError%":i,"%Float32Array%":"undefined"==typeof Float32Array?n:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?n:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?n:FinalizationRegistry,"%Function%":c,"%GeneratorFunction%":m,"%Int8Array%":"undefined"==typeof Int8Array?n:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?n:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?n:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":g&&v?v(v([][Symbol.iterator]())):n,"%JSON%":"object"==typeof JSON?JSON:n,"%Map%":"undefined"==typeof Map?n:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&g&&v?v((new Map)[Symbol.iterator]()):n,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?n:Promise,"%Proxy%":"undefined"==typeof Proxy?n:Proxy,"%RangeError%":a,"%ReferenceError%":s,"%Reflect%":"undefined"==typeof Reflect?n:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?n:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&g&&v?v((new Set)[Symbol.iterator]()):n,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?n:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":g&&v?v(""[Symbol.iterator]()):n,"%Symbol%":g?Symbol:n,"%SyntaxError%":u,"%ThrowTypeError%":d,"%TypedArray%":w,"%TypeError%":f,"%Uint8Array%":"undefined"==typeof Uint8Array?n:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?n:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?n:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?n:Uint32Array,"%URIError%":l,"%WeakMap%":"undefined"==typeof WeakMap?n:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?n:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?n:WeakSet};if(v)try{null.error}catch(t){var _=v(v(t));S["%Error.prototype%"]=_}var E=function t(e){var r;if("%AsyncFunction%"===e)r=p("async function () {}");else if("%GeneratorFunction%"===e)r=p("function* () {}");else if("%AsyncGeneratorFunction%"===e)r=p("async function* () {}");else if("%AsyncGenerator%"===e){var n=t("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if("%AsyncIteratorPrototype%"===e){var o=t("%AsyncGenerator%");o&&v&&(r=v(o.prototype))}return S[e]=r,r},A={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},O=r(212),x=r(270),R=O.call(Function.call,Array.prototype.concat),j=O.call(Function.apply,Array.prototype.splice),P=O.call(Function.call,String.prototype.replace),T=O.call(Function.call,String.prototype.slice),k=O.call(Function.call,RegExp.prototype.exec),M=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,L=/\\(\\)?/g,B=function(t){var e=T(t,0,1),r=T(t,-1);if("%"===e&&"%"!==r)throw new u("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==e)throw new u("invalid intrinsic syntax, expected opening `%`");var n=[];return P(t,M,function(t,e,r,o){n[n.length]=r?P(o,L,"$1"):e||t}),n},N=function(t,e){var r,n=t;if(x(A,n)&&(n="%"+(r=A[n])[0]+"%"),x(S,n)){var o=S[n];if(o===m&&(o=E(n)),void 0===o&&!e)throw new f("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:r,name:n,value:o}}throw new u("intrinsic "+t+" does not exist!")};t.exports=function(t,e){if("string"!=typeof t||0===t.length)throw new f("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof e)throw new f('"allowMissing" argument must be a boolean');if(null===k(/^%?[^%]*%?$/,t))throw new u("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var r=B(t),n=r.length>0?r[0]:"",o=N("%"+n+"%",e),i=o.name,a=o.value,s=!1,l=o.alias;l&&(n=l[0],j(r,R([0,1],l)));for(var c=1,p=!0;c<r.length;c+=1){var y=r[c],d=T(y,0,1),g=T(y,-1);if(('"'===d||"'"===d||"`"===d||'"'===g||"'"===g||"`"===g)&&d!==g)throw new u("property names with quotes must have matching quotes");if("constructor"!==y&&p||(s=!0),n+="."+y,x(S,i="%"+n+"%"))a=S[i];else if(null!=a){if(!(y in a)){if(!e)throw new f("base intrinsic for "+t+" exists, but the property is not available.");return}if(h&&c+1>=r.length){var b=h(a,y);a=(p=!!b)&&"get"in b&&!("originalValue"in b.get)?b.get:a[y]}else p=x(a,y),a=a[y];p&&!s&&(S[i]=a)}}return a}},14:function(t){"use strict";var e={__proto__:null,foo:{}},r=Object;t.exports=function(){return({__proto__:e}).foo===e.foo&&!(e instanceof r)}},942:function(t,e,r){"use strict";var n="undefined"!=typeof Symbol&&Symbol,o=r(773);t.exports=function(){return"function"==typeof n&&"function"==typeof Symbol&&"symbol"==typeof n("foo")&&"symbol"==typeof Symbol("bar")&&o()}},773:function(t){"use strict";t.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var t={},e=Symbol("test"),r=Object(e);if("string"==typeof e||"[object Symbol]"!==Object.prototype.toString.call(e)||"[object Symbol]"!==Object.prototype.toString.call(r))return!1;var n=42;for(e in t[e]=n,t)return!1;if("function"==typeof Object.keys&&0!==Object.keys(t).length||"function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(t).length)return!1;var o=Object.getOwnPropertySymbols(t);if(1!==o.length||o[0]!==e||!Object.prototype.propertyIsEnumerable.call(t,e))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var i=Object.getOwnPropertyDescriptor(t,e);if(i.value!==n||!0!==i.enumerable)return!1}return!0}},115:function(t,e,r){"use strict";var n="undefined"!=typeof Symbol&&Symbol,o=r(832);t.exports=function(){return"function"==typeof n&&"function"==typeof Symbol&&"symbol"==typeof n("foo")&&"symbol"==typeof Symbol("bar")&&o()}},832:function(t){"use strict";t.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var t={},e=Symbol("test"),r=Object(e);if("string"==typeof e||"[object Symbol]"!==Object.prototype.toString.call(e)||"[object Symbol]"!==Object.prototype.toString.call(r))return!1;var n=42;for(e in t[e]=n,t)return!1;if("function"==typeof Object.keys&&0!==Object.keys(t).length||"function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(t).length)return!1;var o=Object.getOwnPropertySymbols(t);if(1!==o.length||o[0]!==e||!Object.prototype.propertyIsEnumerable.call(t,e))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var i=Object.getOwnPropertyDescriptor(t,e);if(i.value!==n||!0!==i.enumerable)return!1}return!0}},270:function(t,e,r){"use strict";var n=Function.prototype.call,o=Object.prototype.hasOwnProperty;t.exports=r(212).call(n,o)},782:function(t){"function"==typeof Object.create?t.exports=function(t,e){e&&(t.super_=e,t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}))}:t.exports=function(t,e){if(e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}}},157:function(t){"use strict";var e="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,r=Object.prototype.toString,n=function(t){return(!e||!t||"object"!=typeof t||!(Symbol.toStringTag in t))&&"[object Arguments]"===r.call(t)},o=function(t){return!!n(t)||null!==t&&"object"==typeof t&&"number"==typeof t.length&&t.length>=0&&"[object Array]"!==r.call(t)&&"[object Function]"===r.call(t.callee)},i=function(){return n(arguments)}();n.isLegacyArguments=o,t.exports=i?n:o},391:function(t){"use strict";var e=Object.prototype.toString,r=Function.prototype.toString,n=/^\s*(?:function)?\*/,o="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,i=Object.getPrototypeOf,a=function(){if(!o)return!1;try{return Function("return function*() {}")()}catch(t){}}(),s=a?i(a):{};t.exports=function(t){return"function"==typeof t&&(!!n.test(r.call(t))||(o?i(t)===s:"[object GeneratorFunction]"===e.call(t)))}},994:function(t,e,n){"use strict";var o=n(144),i=n(349),a=n(256),s=a("Object.prototype.toString"),u=n(942)()&&"symbol"==typeof Symbol.toStringTag,f=i(),l=a("Array.prototype.indexOf",!0)||function(t,e){for(var r=0;r<t.length;r+=1)if(t[r]===e)return r;return -1},c=a("String.prototype.slice"),p={},h=n(24),y=Object.getPrototypeOf;u&&h&&y&&o(f,function(t){var e=new r.g[t];if(!(Symbol.toStringTag in e))throw EvalError("this engine has support for Symbol.toStringTag, but "+t+" does not have the property! Please report this.");var n=y(e),o=h(n,Symbol.toStringTag);o||(o=h(y(n),Symbol.toStringTag)),p[t]=o.get});var d=function(t){var e=!1;return o(p,function(r,n){if(!e)try{e=r.call(t)===n}catch(t){}}),e};t.exports=function(t){return!!t&&"object"==typeof t&&(u?!!h&&d(t):l(f,c(s(t),8,-1))>-1)}},369:function(t){t.exports=function(t){return t instanceof o}},584:function(t,e,r){"use strict";var n=r(157),o=r(391),i=r(490),a=r(994);function s(t){return t.call.bind(t)}var u="undefined"!=typeof BigInt,f="undefined"!=typeof Symbol,l=s(Object.prototype.toString),c=s(Number.prototype.valueOf),p=s(String.prototype.valueOf),h=s(Boolean.prototype.valueOf);if(u)var y=s(BigInt.prototype.valueOf);if(f)var d=s(Symbol.prototype.valueOf);function g(t,e){if("object"!=typeof t)return!1;try{return e(t),!0}catch(t){return!1}}function b(t){return"[object Map]"===l(t)}function v(t){return"[object Set]"===l(t)}function m(t){return"[object WeakMap]"===l(t)}function w(t){return"[object WeakSet]"===l(t)}function S(t){return"[object ArrayBuffer]"===l(t)}function _(t){return"undefined"!=typeof ArrayBuffer&&(S.working?S(t):t instanceof ArrayBuffer)}function E(t){return"[object DataView]"===l(t)}function A(t){return"undefined"!=typeof DataView&&(E.working?E(t):t instanceof DataView)}e.isArgumentsObject=n,e.isGeneratorFunction=o,e.isTypedArray=a,e.isPromise=function(t){return"undefined"!=typeof Promise&&t instanceof Promise||null!==t&&"object"==typeof t&&"function"==typeof t.then&&"function"==typeof t.catch},e.isArrayBufferView=function(t){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(t):a(t)||A(t)},e.isUint8Array=function(t){return"Uint8Array"===i(t)},e.isUint8ClampedArray=function(t){return"Uint8ClampedArray"===i(t)},e.isUint16Array=function(t){return"Uint16Array"===i(t)},e.isUint32Array=function(t){return"Uint32Array"===i(t)},e.isInt8Array=function(t){return"Int8Array"===i(t)},e.isInt16Array=function(t){return"Int16Array"===i(t)},e.isInt32Array=function(t){return"Int32Array"===i(t)},e.isFloat32Array=function(t){return"Float32Array"===i(t)},e.isFloat64Array=function(t){return"Float64Array"===i(t)},e.isBigInt64Array=function(t){return"BigInt64Array"===i(t)},e.isBigUint64Array=function(t){return"BigUint64Array"===i(t)},b.working="undefined"!=typeof Map&&b(new Map),e.isMap=function(t){return"undefined"!=typeof Map&&(b.working?b(t):t instanceof Map)},v.working="undefined"!=typeof Set&&v(new Set),e.isSet=function(t){return"undefined"!=typeof Set&&(v.working?v(t):t instanceof Set)},m.working="undefined"!=typeof WeakMap&&m(new WeakMap),e.isWeakMap=function(t){return"undefined"!=typeof WeakMap&&(m.working?m(t):t instanceof WeakMap)},w.working="undefined"!=typeof WeakSet&&w(new WeakSet),e.isWeakSet=function(t){return w(t)},S.working="undefined"!=typeof ArrayBuffer&&S(new ArrayBuffer),e.isArrayBuffer=_,E.working="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView&&E(new DataView(new ArrayBuffer(1),0,1)),e.isDataView=A;var O="undefined"!=typeof SharedArrayBuffer?SharedArrayBuffer:void 0;function x(t){return"[object SharedArrayBuffer]"===l(t)}function R(t){return void 0!==O&&(void 0===x.working&&(x.working=x(new O)),x.working?x(t):t instanceof O)}function j(t){return g(t,c)}function P(t){return g(t,p)}function T(t){return g(t,h)}function k(t){return u&&g(t,y)}function M(t){return f&&g(t,d)}e.isSharedArrayBuffer=R,e.isAsyncFunction=function(t){return"[object AsyncFunction]"===l(t)},e.isMapIterator=function(t){return"[object Map Iterator]"===l(t)},e.isSetIterator=function(t){return"[object Set Iterator]"===l(t)},e.isGeneratorObject=function(t){return"[object Generator]"===l(t)},e.isWebAssemblyCompiledModule=function(t){return"[object WebAssembly.Module]"===l(t)},e.isNumberObject=j,e.isStringObject=P,e.isBooleanObject=T,e.isBigIntObject=k,e.isSymbolObject=M,e.isBoxedPrimitive=function(t){return j(t)||P(t)||T(t)||k(t)||M(t)},e.isAnyArrayBuffer=function(t){return"undefined"!=typeof Uint8Array&&(_(t)||R(t))},["isProxy","isExternal","isModuleNamespaceObject"].forEach(function(t){Object.defineProperty(e,t,{enumerable:!1,value:function(){throw Error(t+" is not supported in userland")}})})},177:function(t,e,r){var n=Object.getOwnPropertyDescriptors||function(t){for(var e=Object.keys(t),r={},n=0;n<e.length;n++)r[e[n]]=Object.getOwnPropertyDescriptor(t,e[n]);return r},o=/%[sdj%]/g;e.format=function(t){if(!E(t)){for(var e=[],r=0;r<arguments.length;r++)e.push(f(arguments[r]));return e.join(" ")}for(var r=1,n=arguments,i=n.length,a=String(t).replace(o,function(t){if("%%"===t)return"%";if(r>=i)return t;switch(t){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch(t){return"[Circular]"}default:return t}}),s=n[r];r<i;s=n[++r])S(s)||!x(s)?a+=" "+s:a+=" "+f(s);return a},e.deprecate=function(t,r){if(void 0!==i&&!0===i.noDeprecation)return t;if(void 0===i)return function(){return e.deprecate(t,r).apply(this,arguments)};var n=!1;return function(){if(!n){if(i.throwDeprecation)throw Error(r);i.traceDeprecation?console.trace(r):console.error(r),n=!0}return t.apply(this,arguments)}};var a={},s=/^$/;if(i.env.NODE_DEBUG){var u=i.env.NODE_DEBUG;s=RegExp("^"+(u=u.replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase())+"$","i")}function f(t,r){var n={seen:[],stylize:c};return arguments.length>=3&&(n.depth=arguments[2]),arguments.length>=4&&(n.colors=arguments[3]),w(r)?n.showHidden=r:r&&e._extend(n,r),A(n.showHidden)&&(n.showHidden=!1),A(n.depth)&&(n.depth=2),A(n.colors)&&(n.colors=!1),A(n.customInspect)&&(n.customInspect=!0),n.colors&&(n.stylize=l),h(n,t,n.depth)}function l(t,e){var r=f.styles[e];return r?"\x1b["+f.colors[r][0]+"m"+t+"\x1b["+f.colors[r][1]+"m":t}function c(t,e){return t}function p(t){var e={};return t.forEach(function(t,r){e[t]=!0}),e}function h(t,r,n){if(t.customInspect&&r&&P(r.inspect)&&r.inspect!==e.inspect&&!(r.constructor&&r.constructor.prototype===r)){var o,i=r.inspect(n,t);return E(i)||(i=h(t,i,n)),i}var a=y(t,r);if(a)return a;var s=Object.keys(r),u=p(s);if(t.showHidden&&(s=Object.getOwnPropertyNames(r)),j(r)&&(s.indexOf("message")>=0||s.indexOf("description")>=0))return d(r);if(0===s.length){if(P(r)){var f=r.name?": "+r.name:"";return t.stylize("[Function"+f+"]","special")}if(O(r))return t.stylize(RegExp.prototype.toString.call(r),"regexp");if(R(r))return t.stylize(Date.prototype.toString.call(r),"date");if(j(r))return d(r)}var l="",c=!1,w=["{","}"];if(m(r)&&(c=!0,w=["[","]"]),P(r)&&(l=" [Function"+(r.name?": "+r.name:"")+"]"),O(r)&&(l=" "+RegExp.prototype.toString.call(r)),R(r)&&(l=" "+Date.prototype.toUTCString.call(r)),j(r)&&(l=" "+d(r)),0===s.length&&(!c||0==r.length))return w[0]+l+w[1];if(n<0)if(O(r))return t.stylize(RegExp.prototype.toString.call(r),"regexp");else return t.stylize("[Object]","special");return t.seen.push(r),o=c?g(t,r,n,u,s):s.map(function(e){return b(t,r,n,u,e,c)}),t.seen.pop(),v(o,l,w)}function y(t,e){if(A(e))return t.stylize("undefined","undefined");if(E(e)){var r="'"+JSON.stringify(e).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return t.stylize(r,"string")}return _(e)?t.stylize(""+e,"number"):w(e)?t.stylize(""+e,"boolean"):S(e)?t.stylize("null","null"):void 0}function d(t){return"["+Error.prototype.toString.call(t)+"]"}function g(t,e,r,n,o){for(var i=[],a=0,s=e.length;a<s;++a)B(e,String(a))?i.push(b(t,e,r,n,String(a),!0)):i.push("");return o.forEach(function(o){o.match(/^\d+$/)||i.push(b(t,e,r,n,o,!0))}),i}function b(t,e,r,n,o,i){var a,s,u;if((u=Object.getOwnPropertyDescriptor(e,o)||{value:e[o]}).get?s=u.set?t.stylize("[Getter/Setter]","special"):t.stylize("[Getter]","special"):u.set&&(s=t.stylize("[Setter]","special")),B(n,o)||(a="["+o+"]"),!s&&(0>t.seen.indexOf(u.value)?(s=S(r)?h(t,u.value,null):h(t,u.value,r-1)).indexOf("\n")>-1&&(s=i?s.split("\n").map(function(t){return" "+t}).join("\n").substr(2):"\n"+s.split("\n").map(function(t){return" "+t}).join("\n")):s=t.stylize("[Circular]","special")),A(a)){if(i&&o.match(/^\d+$/))return s;(a=JSON.stringify(""+o)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.substr(1,a.length-2),a=t.stylize(a,"name")):(a=a.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),a=t.stylize(a,"string"))}return a+": "+s}function v(t,e,r){var n=0;return t.reduce(function(t,e){return n++,e.indexOf("\n")>=0&&n++,t+e.replace(/\u001b\[\d\d?m/g,"").length+1},0)>60?r[0]+(""===e?"":e+"\n ")+" "+t.join(",\n ")+" "+r[1]:r[0]+e+" "+t.join(", ")+" "+r[1]}function m(t){return Array.isArray(t)}function w(t){return"boolean"==typeof t}function S(t){return null===t}function _(t){return"number"==typeof t}function E(t){return"string"==typeof t}function A(t){return void 0===t}function O(t){return x(t)&&"[object RegExp]"===T(t)}function x(t){return"object"==typeof t&&null!==t}function R(t){return x(t)&&"[object Date]"===T(t)}function j(t){return x(t)&&("[object Error]"===T(t)||t instanceof Error)}function P(t){return"function"==typeof t}function T(t){return Object.prototype.toString.call(t)}function k(t){return t<10?"0"+t.toString(10):t.toString(10)}e.debuglog=function(t){if(!a[t=t.toUpperCase()])if(s.test(t)){var r=i.pid;a[t]=function(){var n=e.format.apply(e,arguments);console.error("%s %d: %s",t,r,n)}}else a[t]=function(){};return a[t]},e.inspect=f,f.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},f.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},e.types=r(584),e.isArray=m,e.isBoolean=w,e.isNull=S,e.isNullOrUndefined=function(t){return null==t},e.isNumber=_,e.isString=E,e.isSymbol=function(t){return"symbol"==typeof t},e.isUndefined=A,e.isRegExp=O,e.types.isRegExp=O,e.isObject=x,e.isDate=R,e.types.isDate=R,e.isError=j,e.types.isNativeError=j,e.isFunction=P,e.isPrimitive=function(t){return null===t||"boolean"==typeof t||"number"==typeof t||"string"==typeof t||"symbol"==typeof t||void 0===t},e.isBuffer=r(369);var M=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function L(){var t=new Date,e=[k(t.getHours()),k(t.getMinutes()),k(t.getSeconds())].join(":");return[t.getDate(),M[t.getMonth()],e].join(" ")}function B(t,e){return Object.prototype.hasOwnProperty.call(t,e)}e.log=function(){console.log("%s - %s",L(),e.format.apply(e,arguments))},e.inherits=r(782),e._extend=function(t,e){if(!e||!x(e))return t;for(var r=Object.keys(e),n=r.length;n--;)t[r[n]]=e[r[n]];return t};var N="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function C(t,e){if(!t){var r=Error("Promise was rejected with a falsy value");r.reason=t,t=r}return e(t)}e.promisify=function(t){if("function"!=typeof t)throw TypeError('The "original" argument must be of type Function');if(N&&t[N]){var e=t[N];if("function"!=typeof e)throw TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(e,N,{value:e,enumerable:!1,writable:!1,configurable:!0}),e}function e(){for(var e,r,n=new Promise(function(t,n){e=t,r=n}),o=[],i=0;i<arguments.length;i++)o.push(arguments[i]);o.push(function(t,n){t?r(t):e(n)});try{t.apply(this,o)}catch(t){r(t)}return n}return Object.setPrototypeOf(e,Object.getPrototypeOf(t)),N&&Object.defineProperty(e,N,{value:e,enumerable:!1,writable:!1,configurable:!0}),Object.defineProperties(e,n(t))},e.promisify.custom=N,e.callbackify=function(t){if("function"!=typeof t)throw TypeError('The "original" argument must be of type Function');function e(){for(var e=[],r=0;r<arguments.length;r++)e.push(arguments[r]);var n=e.pop();if("function"!=typeof n)throw TypeError("The last argument must be of type Function");var o=this,a=function(){return n.apply(o,arguments)};t.apply(this,e).then(function(t){i.nextTick(a.bind(null,null,t))},function(t){i.nextTick(C.bind(null,t,a))})}return Object.setPrototypeOf(e,Object.getPrototypeOf(t)),Object.defineProperties(e,n(t)),e}},490:function(t,e,n){"use strict";var o=n(144),i=n(349),a=n(256),s=a("Object.prototype.toString"),u=n(942)()&&"symbol"==typeof Symbol.toStringTag,f=i(),l=a("String.prototype.slice"),c={},p=n(24),h=Object.getPrototypeOf;u&&p&&h&&o(f,function(t){if("function"==typeof r.g[t]){var e=new r.g[t];if(!(Symbol.toStringTag in e))throw EvalError("this engine has support for Symbol.toStringTag, but "+t+" does not have the property! Please report this.");var n=h(e),o=p(n,Symbol.toStringTag);o||(o=p(h(n),Symbol.toStringTag)),c[t]=o.get}});var y=function(t){var e=!1;return o(c,function(r,n){if(!e)try{var o=r.call(t);o===n&&(e=o)}catch(t){}}),e},d=n(994);t.exports=function(t){return!!d(t)&&(u?y(t):l(s(t),8,-1))}},349:function(t,e,n){"use strict";var o=n(992);t.exports=function(){return o(["BigInt64Array","BigUint64Array","Float32Array","Float64Array","Int16Array","Int32Array","Int8Array","Uint16Array","Uint32Array","Uint8Array","Uint8ClampedArray"],function(t){return"function"==typeof r.g[t]})}},24:function(t,e,r){"use strict";var n=r(192)("%Object.getOwnPropertyDescriptor%",!0);if(n)try{n([],"length")}catch(t){n=null}t.exports=n}},a={};function s(t){var r=a[t];if(void 0!==r)return r.exports;var n=a[t]={exports:{}},o=!0;try{e[t](n,n.exports,s),o=!1}finally{o&&delete a[t]}return n.exports}s.ab=n+"/",t.exports=s(177)}()}}]);
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[439],{6439:(e,t,i)=>{var s=i(77011);self,e.exports=(()=>{"use strict";var e={965:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.GlyphRenderer=void 0;let s=i(374),r=i(509),o=i(855),a=i(859),n=i(381),h=11*Float32Array.BYTES_PER_ELEMENT,l,c=0,d=0,_=0;class u extends a.Disposable{constructor(e,t,i,o){super(),this._terminal=e,this._gl=t,this._dimensions=i,this._optionsService=o,this._activeBuffer=0,this._vertices={count:0,attributes:new Float32Array(0),attributesBuffers:[new Float32Array(0),new Float32Array(0)]};let l=this._gl;void 0===r.TextureAtlas.maxAtlasPages&&(r.TextureAtlas.maxAtlasPages=Math.min(32,(0,s.throwIfFalsy)(l.getParameter(l.MAX_TEXTURE_IMAGE_UNITS))),r.TextureAtlas.maxTextureSize=(0,s.throwIfFalsy)(l.getParameter(l.MAX_TEXTURE_SIZE))),this._program=(0,s.throwIfFalsy)((0,n.createProgram)(l,"#version 300 es\nlayout (location = 0) in vec2 a_unitquad;\nlayout (location = 1) in vec2 a_cellpos;\nlayout (location = 2) in vec2 a_offset;\nlayout (location = 3) in vec2 a_size;\nlayout (location = 4) in float a_texpage;\nlayout (location = 5) in vec2 a_texcoord;\nlayout (location = 6) in vec2 a_texsize;\n\nuniform mat4 u_projection;\nuniform vec2 u_resolution;\n\nout vec2 v_texcoord;\nflat out int v_texpage;\n\nvoid main() {\n vec2 zeroToOne = (a_offset / u_resolution) + a_cellpos + (a_unitquad * a_size);\n gl_Position = u_projection * vec4(zeroToOne, 0.0, 1.0);\n v_texpage = int(a_texpage);\n v_texcoord = a_texcoord + a_unitquad * a_texsize;\n}",function(e){let t="";for(let i=1;i<e;i++)t+=` else if (v_texpage == ${i}) { outColor = texture(u_texture[${i}], v_texcoord); }`;return`#version 300 es
|
|
2
|
+
precision lowp float;
|
|
3
|
+
|
|
4
|
+
in vec2 v_texcoord;
|
|
5
|
+
flat in int v_texpage;
|
|
6
|
+
|
|
7
|
+
uniform sampler2D u_texture[${e}];
|
|
8
|
+
|
|
9
|
+
out vec4 outColor;
|
|
10
|
+
|
|
11
|
+
void main() {
|
|
12
|
+
if (v_texpage == 0) {
|
|
13
|
+
outColor = texture(u_texture[0], v_texcoord);
|
|
14
|
+
} ${t}
|
|
15
|
+
}`}(r.TextureAtlas.maxAtlasPages))),this.register((0,a.toDisposable)(()=>l.deleteProgram(this._program))),this._projectionLocation=(0,s.throwIfFalsy)(l.getUniformLocation(this._program,"u_projection")),this._resolutionLocation=(0,s.throwIfFalsy)(l.getUniformLocation(this._program,"u_resolution")),this._textureLocation=(0,s.throwIfFalsy)(l.getUniformLocation(this._program,"u_texture")),this._vertexArrayObject=l.createVertexArray(),l.bindVertexArray(this._vertexArrayObject);let c=new Float32Array([0,0,1,0,0,1,1,1]),d=l.createBuffer();this.register((0,a.toDisposable)(()=>l.deleteBuffer(d))),l.bindBuffer(l.ARRAY_BUFFER,d),l.bufferData(l.ARRAY_BUFFER,c,l.STATIC_DRAW),l.enableVertexAttribArray(0),l.vertexAttribPointer(0,2,this._gl.FLOAT,!1,0,0);let _=new Uint8Array([0,1,2,3]),u=l.createBuffer();this.register((0,a.toDisposable)(()=>l.deleteBuffer(u))),l.bindBuffer(l.ELEMENT_ARRAY_BUFFER,u),l.bufferData(l.ELEMENT_ARRAY_BUFFER,_,l.STATIC_DRAW),this._attributesBuffer=(0,s.throwIfFalsy)(l.createBuffer()),this.register((0,a.toDisposable)(()=>l.deleteBuffer(this._attributesBuffer))),l.bindBuffer(l.ARRAY_BUFFER,this._attributesBuffer),l.enableVertexAttribArray(2),l.vertexAttribPointer(2,2,l.FLOAT,!1,h,0),l.vertexAttribDivisor(2,1),l.enableVertexAttribArray(3),l.vertexAttribPointer(3,2,l.FLOAT,!1,h,2*Float32Array.BYTES_PER_ELEMENT),l.vertexAttribDivisor(3,1),l.enableVertexAttribArray(4),l.vertexAttribPointer(4,1,l.FLOAT,!1,h,4*Float32Array.BYTES_PER_ELEMENT),l.vertexAttribDivisor(4,1),l.enableVertexAttribArray(5),l.vertexAttribPointer(5,2,l.FLOAT,!1,h,5*Float32Array.BYTES_PER_ELEMENT),l.vertexAttribDivisor(5,1),l.enableVertexAttribArray(6),l.vertexAttribPointer(6,2,l.FLOAT,!1,h,7*Float32Array.BYTES_PER_ELEMENT),l.vertexAttribDivisor(6,1),l.enableVertexAttribArray(1),l.vertexAttribPointer(1,2,l.FLOAT,!1,h,9*Float32Array.BYTES_PER_ELEMENT),l.vertexAttribDivisor(1,1),l.useProgram(this._program);let g=new Int32Array(r.TextureAtlas.maxAtlasPages);for(let e=0;e<r.TextureAtlas.maxAtlasPages;e++)g[e]=e;l.uniform1iv(this._textureLocation,g),l.uniformMatrix4fv(this._projectionLocation,!1,n.PROJECTION_MATRIX),this._atlasTextures=[];for(let e=0;e<r.TextureAtlas.maxAtlasPages;e++){let t=new n.GLTexture((0,s.throwIfFalsy)(l.createTexture()));this.register((0,a.toDisposable)(()=>l.deleteTexture(t.texture))),l.activeTexture(l.TEXTURE0+e),l.bindTexture(l.TEXTURE_2D,t.texture),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_WRAP_S,l.CLAMP_TO_EDGE),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_WRAP_T,l.CLAMP_TO_EDGE),l.texImage2D(l.TEXTURE_2D,0,l.RGBA,1,1,0,l.RGBA,l.UNSIGNED_BYTE,new Uint8Array([255,0,0,255])),this._atlasTextures[e]=t}l.enable(l.BLEND),l.blendFunc(l.SRC_ALPHA,l.ONE_MINUS_SRC_ALPHA),this.handleResize()}beginFrame(){return!this._atlas||this._atlas.beginFrame()}updateCell(e,t,i,s,r,o,a,n,h){this._updateCell(this._vertices.attributes,e,t,i,s,r,o,a,n,h)}_updateCell(e,t,i,r,a,n,h,u,g,f){c=(i*this._terminal.cols+t)*11,r!==o.NULL_CELL_CODE&&void 0!==r?this._atlas&&(l=u&&u.length>1?this._atlas.getRasterizedGlyphCombinedChar(u,a,n,h,!1):this._atlas.getRasterizedGlyph(r,a,n,h,!1),d=Math.floor((this._dimensions.device.cell.width-this._dimensions.device.char.width)/2),a!==f&&l.offset.x>d?(_=l.offset.x-d,e[c]=-(l.offset.x-_)+this._dimensions.device.char.left,e[c+1]=-l.offset.y+this._dimensions.device.char.top,e[c+2]=(l.size.x-_)/this._dimensions.device.canvas.width,e[c+3]=l.size.y/this._dimensions.device.canvas.height,e[c+4]=l.texturePage,e[c+5]=l.texturePositionClipSpace.x+_/this._atlas.pages[l.texturePage].canvas.width,e[c+6]=l.texturePositionClipSpace.y,e[c+7]=l.sizeClipSpace.x-_/this._atlas.pages[l.texturePage].canvas.width):(e[c]=-l.offset.x+this._dimensions.device.char.left,e[c+1]=-l.offset.y+this._dimensions.device.char.top,e[c+2]=l.size.x/this._dimensions.device.canvas.width,e[c+3]=l.size.y/this._dimensions.device.canvas.height,e[c+4]=l.texturePage,e[c+5]=l.texturePositionClipSpace.x,e[c+6]=l.texturePositionClipSpace.y,e[c+7]=l.sizeClipSpace.x),e[c+8]=l.sizeClipSpace.y,this._optionsService.rawOptions.rescaleOverlappingGlyphs&&(0,s.allowRescaling)(r,g,l.size.x,this._dimensions.device.cell.width)&&(e[c+2]=(this._dimensions.device.cell.width-1)/this._dimensions.device.canvas.width)):e.fill(0,c,c+11-1-2)}clear(){let e=this._terminal,t=e.cols*e.rows*11;this._vertices.count!==t?this._vertices.attributes=new Float32Array(t):this._vertices.attributes.fill(0);let i=0;for(;i<this._vertices.attributesBuffers.length;i++)this._vertices.count!==t?this._vertices.attributesBuffers[i]=new Float32Array(t):this._vertices.attributesBuffers[i].fill(0);this._vertices.count=t,i=0;for(let t=0;t<e.rows;t++)for(let s=0;s<e.cols;s++)this._vertices.attributes[i+9]=s/e.cols,this._vertices.attributes[i+10]=t/e.rows,i+=11}handleResize(){let e=this._gl;e.useProgram(this._program),e.viewport(0,0,e.canvas.width,e.canvas.height),e.uniform2f(this._resolutionLocation,e.canvas.width,e.canvas.height),this.clear()}render(e){if(!this._atlas)return;let t=this._gl;t.useProgram(this._program),t.bindVertexArray(this._vertexArrayObject),this._activeBuffer=(this._activeBuffer+1)%2;let i=this._vertices.attributesBuffers[this._activeBuffer],s=0;for(let t=0;t<e.lineLengths.length;t++){let r=t*this._terminal.cols*11,o=this._vertices.attributes.subarray(r,r+11*e.lineLengths[t]);i.set(o,s),s+=o.length}t.bindBuffer(t.ARRAY_BUFFER,this._attributesBuffer),t.bufferData(t.ARRAY_BUFFER,i.subarray(0,s),t.STREAM_DRAW);for(let e=0;e<this._atlas.pages.length;e++)this._atlas.pages[e].version!==this._atlasTextures[e].version&&this._bindAtlasPageTexture(t,this._atlas,e);t.drawElementsInstanced(t.TRIANGLE_STRIP,4,t.UNSIGNED_BYTE,0,s/11)}setAtlas(e){for(let t of(this._atlas=e,this._atlasTextures))t.version=-1}_bindAtlasPageTexture(e,t,i){e.activeTexture(e.TEXTURE0+i),e.bindTexture(e.TEXTURE_2D,this._atlasTextures[i].texture),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE),e.texImage2D(e.TEXTURE_2D,0,e.RGBA,e.RGBA,e.UNSIGNED_BYTE,t.pages[i].canvas),e.generateMipmap(e.TEXTURE_2D),this._atlasTextures[i].version=t.pages[i].version}setDimensions(e){this._dimensions=e}}t.GlyphRenderer=u},742:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.RectangleRenderer=void 0;let s=i(374),r=i(859),o=i(310),a=i(381),n=8*Float32Array.BYTES_PER_ELEMENT;class h{constructor(){this.attributes=new Float32Array(160),this.count=0}}let l=0,c=0,d=0,_=0,u=0,g=0,f=0;class v extends r.Disposable{constructor(e,t,i,o){super(),this._terminal=e,this._gl=t,this._dimensions=i,this._themeService=o,this._vertices=new h,this._verticesCursor=new h;let l=this._gl;this._program=(0,s.throwIfFalsy)((0,a.createProgram)(l,"#version 300 es\nlayout (location = 0) in vec2 a_position;\nlayout (location = 1) in vec2 a_size;\nlayout (location = 2) in vec4 a_color;\nlayout (location = 3) in vec2 a_unitquad;\n\nuniform mat4 u_projection;\n\nout vec4 v_color;\n\nvoid main() {\n vec2 zeroToOne = a_position + (a_unitquad * a_size);\n gl_Position = u_projection * vec4(zeroToOne, 0.0, 1.0);\n v_color = a_color;\n}","#version 300 es\nprecision lowp float;\n\nin vec4 v_color;\n\nout vec4 outColor;\n\nvoid main() {\n outColor = v_color;\n}")),this.register((0,r.toDisposable)(()=>l.deleteProgram(this._program))),this._projectionLocation=(0,s.throwIfFalsy)(l.getUniformLocation(this._program,"u_projection")),this._vertexArrayObject=l.createVertexArray(),l.bindVertexArray(this._vertexArrayObject);let c=new Float32Array([0,0,1,0,0,1,1,1]),d=l.createBuffer();this.register((0,r.toDisposable)(()=>l.deleteBuffer(d))),l.bindBuffer(l.ARRAY_BUFFER,d),l.bufferData(l.ARRAY_BUFFER,c,l.STATIC_DRAW),l.enableVertexAttribArray(3),l.vertexAttribPointer(3,2,this._gl.FLOAT,!1,0,0);let _=new Uint8Array([0,1,2,3]),u=l.createBuffer();this.register((0,r.toDisposable)(()=>l.deleteBuffer(u))),l.bindBuffer(l.ELEMENT_ARRAY_BUFFER,u),l.bufferData(l.ELEMENT_ARRAY_BUFFER,_,l.STATIC_DRAW),this._attributesBuffer=(0,s.throwIfFalsy)(l.createBuffer()),this.register((0,r.toDisposable)(()=>l.deleteBuffer(this._attributesBuffer))),l.bindBuffer(l.ARRAY_BUFFER,this._attributesBuffer),l.enableVertexAttribArray(0),l.vertexAttribPointer(0,2,l.FLOAT,!1,n,0),l.vertexAttribDivisor(0,1),l.enableVertexAttribArray(1),l.vertexAttribPointer(1,2,l.FLOAT,!1,n,2*Float32Array.BYTES_PER_ELEMENT),l.vertexAttribDivisor(1,1),l.enableVertexAttribArray(2),l.vertexAttribPointer(2,4,l.FLOAT,!1,n,4*Float32Array.BYTES_PER_ELEMENT),l.vertexAttribDivisor(2,1),this._updateCachedColors(o.colors),this.register(this._themeService.onChangeColors(e=>{this._updateCachedColors(e),this._updateViewportRectangle()}))}renderBackgrounds(){this._renderVertices(this._vertices)}renderCursor(){this._renderVertices(this._verticesCursor)}_renderVertices(e){let t=this._gl;t.useProgram(this._program),t.bindVertexArray(this._vertexArrayObject),t.uniformMatrix4fv(this._projectionLocation,!1,a.PROJECTION_MATRIX),t.bindBuffer(t.ARRAY_BUFFER,this._attributesBuffer),t.bufferData(t.ARRAY_BUFFER,e.attributes,t.DYNAMIC_DRAW),t.drawElementsInstanced(this._gl.TRIANGLE_STRIP,4,t.UNSIGNED_BYTE,0,e.count)}handleResize(){this._updateViewportRectangle()}setDimensions(e){this._dimensions=e}_updateCachedColors(e){this._bgFloat=this._colorToFloat32Array(e.background),this._cursorFloat=this._colorToFloat32Array(e.cursor)}_updateViewportRectangle(){this._addRectangleFloat(this._vertices.attributes,0,0,0,this._terminal.cols*this._dimensions.device.cell.width,this._terminal.rows*this._dimensions.device.cell.height,this._bgFloat)}updateBackgrounds(e){let t=this._terminal,i=this._vertices,s,r,a,n,h,l,c,d,_,u,g,f=1;for(s=0;s<t.rows;s++){for(a=-1,n=0,h=0,l=!1,r=0;r<t.cols;r++)c=(s*t.cols+r)*o.RENDER_MODEL_INDICIES_PER_CELL,d=e.cells[c+o.RENDER_MODEL_BG_OFFSET],u=!!(0x4000000&(_=e.cells[c+o.RENDER_MODEL_FG_OFFSET])),(d!==n||_!==h&&(l||u))&&((0!==n||l&&0!==h)&&(g=8*f++,this._updateRectangle(i,g,h,n,a,r,s)),a=r,n=d,h=_,l=u);(0!==n||l&&0!==h)&&(g=8*f++,this._updateRectangle(i,g,h,n,a,t.cols,s))}i.count=f}updateCursor(e){let t=this._verticesCursor,i=e.cursor;if(!i||"block"===i.style)return void(t.count=0);let s,r=0;"bar"!==i.style&&"outline"!==i.style||(s=8*r++,this._addRectangleFloat(t.attributes,s,i.x*this._dimensions.device.cell.width,i.y*this._dimensions.device.cell.height,"bar"===i.style?i.dpr*i.cursorWidth:i.dpr,this._dimensions.device.cell.height,this._cursorFloat)),"underline"!==i.style&&"outline"!==i.style||(s=8*r++,this._addRectangleFloat(t.attributes,s,i.x*this._dimensions.device.cell.width,(i.y+1)*this._dimensions.device.cell.height-i.dpr,i.width*this._dimensions.device.cell.width,i.dpr,this._cursorFloat)),"outline"===i.style&&(s=8*r++,this._addRectangleFloat(t.attributes,s,i.x*this._dimensions.device.cell.width,i.y*this._dimensions.device.cell.height,i.width*this._dimensions.device.cell.width,i.dpr,this._cursorFloat),s=8*r++,this._addRectangleFloat(t.attributes,s,(i.x+i.width)*this._dimensions.device.cell.width-i.dpr,i.y*this._dimensions.device.cell.height,i.dpr,this._dimensions.device.cell.height,this._cursorFloat)),t.count=r}_updateRectangle(e,t,i,s,r,o,n){if(0x4000000&i)switch(0x3000000&i){case 0x1000000:case 0x2000000:l=this._themeService.colors.ansi[255&i].rgba;break;case 0x3000000:l=(0xffffff&i)<<8;break;default:l=this._themeService.colors.foreground.rgba}else switch(0x3000000&s){case 0x1000000:case 0x2000000:l=this._themeService.colors.ansi[255&s].rgba;break;case 0x3000000:l=(0xffffff&s)<<8;break;default:l=this._themeService.colors.background.rgba}e.attributes.length<t+4&&(e.attributes=(0,a.expandFloat32Array)(e.attributes,this._terminal.rows*this._terminal.cols*8)),c=r*this._dimensions.device.cell.width,d=n*this._dimensions.device.cell.height,_=(l>>24&255)/255,u=(l>>16&255)/255,g=(l>>8&255)/255,f=1,this._addRectangle(e.attributes,t,c,d,(o-r)*this._dimensions.device.cell.width,this._dimensions.device.cell.height,_,u,g,f)}_addRectangle(e,t,i,s,r,o,a,n,h,l){e[t]=i/this._dimensions.device.canvas.width,e[t+1]=s/this._dimensions.device.canvas.height,e[t+2]=r/this._dimensions.device.canvas.width,e[t+3]=o/this._dimensions.device.canvas.height,e[t+4]=a,e[t+5]=n,e[t+6]=h,e[t+7]=l}_addRectangleFloat(e,t,i,s,r,o,a){e[t]=i/this._dimensions.device.canvas.width,e[t+1]=s/this._dimensions.device.canvas.height,e[t+2]=r/this._dimensions.device.canvas.width,e[t+3]=o/this._dimensions.device.canvas.height,e[t+4]=a[0],e[t+5]=a[1],e[t+6]=a[2],e[t+7]=a[3]}_colorToFloat32Array(e){return new Float32Array([(e.rgba>>24&255)/255,(e.rgba>>16&255)/255,(e.rgba>>8&255)/255,(255&e.rgba)/255])}}t.RectangleRenderer=v},310:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.RenderModel=t.COMBINED_CHAR_BIT_MASK=t.RENDER_MODEL_EXT_OFFSET=t.RENDER_MODEL_FG_OFFSET=t.RENDER_MODEL_BG_OFFSET=t.RENDER_MODEL_INDICIES_PER_CELL=void 0;let s=i(296);t.RENDER_MODEL_INDICIES_PER_CELL=4,t.RENDER_MODEL_BG_OFFSET=1,t.RENDER_MODEL_FG_OFFSET=2,t.RENDER_MODEL_EXT_OFFSET=3,t.COMBINED_CHAR_BIT_MASK=0x80000000,t.RenderModel=class{constructor(){this.cells=new Uint32Array(0),this.lineLengths=new Uint32Array(0),this.selection=(0,s.createSelectionRenderModel)()}resize(e,i){let s=e*i*t.RENDER_MODEL_INDICIES_PER_CELL;s!==this.cells.length&&(this.cells=new Uint32Array(s),this.lineLengths=new Uint32Array(i))}clear(){this.cells.fill(0,0),this.lineLengths.fill(0,0)}}},666:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.JoinedCellData=t.WebglRenderer=void 0;let s=i(820),r=i(274),o=i(627),a=i(457),n=i(56),h=i(374),l=i(345),c=i(859),d=i(147),_=i(782),u=i(855),g=i(965),f=i(742),v=i(310),x=i(733);class p extends c.Disposable{constructor(e,t,i,a,d,u,g,f,p){if(super(),this._terminal=e,this._characterJoinerService=t,this._charSizeService=i,this._coreBrowserService=a,this._coreService=d,this._decorationService=u,this._optionsService=g,this._themeService=f,this._cursorBlinkStateManager=new c.MutableDisposable,this._charAtlasDisposable=this.register(new c.MutableDisposable),this._observerDisposable=this.register(new c.MutableDisposable),this._model=new v.RenderModel,this._workCell=new _.CellData,this._workCell2=new _.CellData,this._rectangleRenderer=this.register(new c.MutableDisposable),this._glyphRenderer=this.register(new c.MutableDisposable),this._onChangeTextureAtlas=this.register(new l.EventEmitter),this.onChangeTextureAtlas=this._onChangeTextureAtlas.event,this._onAddTextureAtlasCanvas=this.register(new l.EventEmitter),this.onAddTextureAtlasCanvas=this._onAddTextureAtlasCanvas.event,this._onRemoveTextureAtlasCanvas=this.register(new l.EventEmitter),this.onRemoveTextureAtlasCanvas=this._onRemoveTextureAtlasCanvas.event,this._onRequestRedraw=this.register(new l.EventEmitter),this.onRequestRedraw=this._onRequestRedraw.event,this._onContextLoss=this.register(new l.EventEmitter),this.onContextLoss=this._onContextLoss.event,this.register(this._themeService.onChangeColors(()=>this._handleColorChange())),this._cellColorResolver=new r.CellColorResolver(this._terminal,this._optionsService,this._model.selection,this._decorationService,this._coreBrowserService,this._themeService),this._core=this._terminal._core,this._renderLayers=[new x.LinkRenderLayer(this._core.screenElement,2,this._terminal,this._core.linkifier,this._coreBrowserService,g,this._themeService)],this.dimensions=(0,h.createRenderDimensions)(),this._devicePixelRatio=this._coreBrowserService.dpr,this._updateDimensions(),this._updateCursorBlink(),this.register(g.onOptionChange(()=>this._handleOptionsChanged())),this._canvas=this._coreBrowserService.mainDocument.createElement("canvas"),this._gl=this._canvas.getContext("webgl2",{antialias:!1,depth:!1,preserveDrawingBuffer:p}),!this._gl)throw Error("WebGL2 not supported "+this._gl);this.register((0,s.addDisposableDomListener)(this._canvas,"webglcontextlost",e=>{console.log("webglcontextlost event received"),e.preventDefault(),this._contextRestorationTimeout=setTimeout(()=>{this._contextRestorationTimeout=void 0,console.warn("webgl context not restored; firing onContextLoss"),this._onContextLoss.fire(e)},3e3)})),this.register((0,s.addDisposableDomListener)(this._canvas,"webglcontextrestored",e=>{console.warn("webglcontextrestored event received"),clearTimeout(this._contextRestorationTimeout),this._contextRestorationTimeout=void 0,(0,o.removeTerminalFromCache)(this._terminal),this._initializeWebGLState(),this._requestRedrawViewport()})),this._observerDisposable.value=(0,n.observeDevicePixelDimensions)(this._canvas,this._coreBrowserService.window,(e,t)=>this._setCanvasDevicePixelDimensions(e,t)),this.register(this._coreBrowserService.onWindowChange(e=>{this._observerDisposable.value=(0,n.observeDevicePixelDimensions)(this._canvas,e,(e,t)=>this._setCanvasDevicePixelDimensions(e,t))})),this._core.screenElement.appendChild(this._canvas),[this._rectangleRenderer.value,this._glyphRenderer.value]=this._initializeWebGLState(),this._isAttached=this._coreBrowserService.window.document.body.contains(this._core.screenElement),this.register((0,c.toDisposable)(()=>{for(let e of this._renderLayers)e.dispose();this._canvas.parentElement?.removeChild(this._canvas),(0,o.removeTerminalFromCache)(this._terminal)}))}get textureAtlas(){return this._charAtlas?.pages[0].canvas}_handleColorChange(){this._refreshCharAtlas(),this._clearModel(!0)}handleDevicePixelRatioChange(){this._devicePixelRatio!==this._coreBrowserService.dpr&&(this._devicePixelRatio=this._coreBrowserService.dpr,this.handleResize(this._terminal.cols,this._terminal.rows))}handleResize(e,t){for(let e of(this._updateDimensions(),this._model.resize(this._terminal.cols,this._terminal.rows),this._renderLayers))e.resize(this._terminal,this.dimensions);this._canvas.width=this.dimensions.device.canvas.width,this._canvas.height=this.dimensions.device.canvas.height,this._canvas.style.width=`${this.dimensions.css.canvas.width}px`,this._canvas.style.height=`${this.dimensions.css.canvas.height}px`,this._core.screenElement.style.width=`${this.dimensions.css.canvas.width}px`,this._core.screenElement.style.height=`${this.dimensions.css.canvas.height}px`,this._rectangleRenderer.value?.setDimensions(this.dimensions),this._rectangleRenderer.value?.handleResize(),this._glyphRenderer.value?.setDimensions(this.dimensions),this._glyphRenderer.value?.handleResize(),this._refreshCharAtlas(),this._clearModel(!1)}handleCharSizeChanged(){this.handleResize(this._terminal.cols,this._terminal.rows)}handleBlur(){for(let e of this._renderLayers)e.handleBlur(this._terminal);this._cursorBlinkStateManager.value?.pause(),this._requestRedrawViewport()}handleFocus(){for(let e of this._renderLayers)e.handleFocus(this._terminal);this._cursorBlinkStateManager.value?.resume(),this._requestRedrawViewport()}handleSelectionChanged(e,t,i){for(let s of this._renderLayers)s.handleSelectionChanged(this._terminal,e,t,i);this._model.selection.update(this._core,e,t,i),this._requestRedrawViewport()}handleCursorMove(){for(let e of this._renderLayers)e.handleCursorMove(this._terminal);this._cursorBlinkStateManager.value?.restartBlinkAnimation()}_handleOptionsChanged(){this._updateDimensions(),this._refreshCharAtlas(),this._updateCursorBlink()}_initializeWebGLState(){return this._rectangleRenderer.value=new f.RectangleRenderer(this._terminal,this._gl,this.dimensions,this._themeService),this._glyphRenderer.value=new g.GlyphRenderer(this._terminal,this._gl,this.dimensions,this._optionsService),this.handleCharSizeChanged(),[this._rectangleRenderer.value,this._glyphRenderer.value]}_refreshCharAtlas(){if(this.dimensions.device.char.width<=0&&this.dimensions.device.char.height<=0)return void(this._isAttached=!1);let e=(0,o.acquireTextureAtlas)(this._terminal,this._optionsService.rawOptions,this._themeService.colors,this.dimensions.device.cell.width,this.dimensions.device.cell.height,this.dimensions.device.char.width,this.dimensions.device.char.height,this._coreBrowserService.dpr);this._charAtlas!==e&&(this._onChangeTextureAtlas.fire(e.pages[0].canvas),this._charAtlasDisposable.value=(0,c.getDisposeArrayDisposable)([(0,l.forwardEvent)(e.onAddTextureAtlasCanvas,this._onAddTextureAtlasCanvas),(0,l.forwardEvent)(e.onRemoveTextureAtlasCanvas,this._onRemoveTextureAtlasCanvas)])),this._charAtlas=e,this._charAtlas.warmUp(),this._glyphRenderer.value?.setAtlas(this._charAtlas)}_clearModel(e){this._model.clear(),e&&this._glyphRenderer.value?.clear()}clearTextureAtlas(){this._charAtlas?.clearTexture(),this._clearModel(!0),this._requestRedrawViewport()}clear(){for(let e of(this._clearModel(!0),this._renderLayers))e.reset(this._terminal);this._cursorBlinkStateManager.value?.restartBlinkAnimation(),this._updateCursorBlink()}registerCharacterJoiner(e){return -1}deregisterCharacterJoiner(e){return!1}renderRows(e,t){if(!this._isAttached){if(!(this._coreBrowserService.window.document.body.contains(this._core.screenElement)&&this._charSizeService.width&&this._charSizeService.height))return;this._updateDimensions(),this._refreshCharAtlas(),this._isAttached=!0}for(let i of this._renderLayers)i.handleGridChanged(this._terminal,e,t);this._glyphRenderer.value&&this._rectangleRenderer.value&&(this._glyphRenderer.value.beginFrame()?(this._clearModel(!0),this._updateModel(0,this._terminal.rows-1)):this._updateModel(e,t),this._rectangleRenderer.value.renderBackgrounds(),this._glyphRenderer.value.render(this._model),this._cursorBlinkStateManager.value&&!this._cursorBlinkStateManager.value.isCursorVisible||this._rectangleRenderer.value.renderCursor())}_updateCursorBlink(){this._terminal.options.cursorBlink?this._cursorBlinkStateManager.value=new a.CursorBlinkStateManager(()=>{this._requestRedrawCursor()},this._coreBrowserService):this._cursorBlinkStateManager.clear(),this._requestRedrawCursor()}_updateModel(e,t){let i=this._core,s,r,o,a,n,h,l,c,d,_,g,f,x,p,L=this._workCell;e=m(e,i.rows-1,0),t=m(t,i.rows-1,0);let w=this._terminal.buffer.active.baseY+this._terminal.buffer.active.cursorY,b=w-i.buffer.ydisp,M=Math.min(this._terminal.buffer.active.cursorX,i.cols-1),R=-1,y=this._coreService.isCursorInitialized&&!this._coreService.isCursorHidden&&(!this._cursorBlinkStateManager.value||this._cursorBlinkStateManager.value.isCursorVisible);this._model.cursor=void 0;let A=!1;for(r=e;r<=t;r++)for(o=r+i.buffer.ydisp,a=i.buffer.lines.get(o),this._model.lineLengths[r]=0,n=this._characterJoinerService.getJoinedCharacters(o),x=0;x<i.cols;x++)if(s=this._cellColorResolver.result.bg,a.loadCell(x,L),0===x&&(s=this._cellColorResolver.result.bg),h=!1,l=x,n.length>0&&x===n[0][0]&&(h=!0,c=n.shift(),L=new C(L,a.translateToString(!0,c[0],c[1]),c[1]-c[0]),l=c[1]-1),d=L.getChars(),_=L.getCode(),f=(r*i.cols+x)*v.RENDER_MODEL_INDICIES_PER_CELL,this._cellColorResolver.resolve(L,x,o,this.dimensions.device.cell.width),y&&o===w&&(x===M&&(this._model.cursor={x:M,y:b,width:L.getWidth(),style:this._coreBrowserService.isFocused?i.options.cursorStyle||"block":i.options.cursorInactiveStyle,cursorWidth:i.options.cursorWidth,dpr:this._devicePixelRatio},R=M+L.getWidth()-1),x>=M&&x<=R&&(this._coreBrowserService.isFocused&&"block"===(i.options.cursorStyle||"block")||!1===this._coreBrowserService.isFocused&&"block"===i.options.cursorInactiveStyle)&&(this._cellColorResolver.result.fg=0x3000000|this._themeService.colors.cursorAccent.rgba>>8&0xffffff,this._cellColorResolver.result.bg=0x3000000|this._themeService.colors.cursor.rgba>>8&0xffffff)),_!==u.NULL_CELL_CODE&&(this._model.lineLengths[r]=x+1),(this._model.cells[f]!==_||this._model.cells[f+v.RENDER_MODEL_BG_OFFSET]!==this._cellColorResolver.result.bg||this._model.cells[f+v.RENDER_MODEL_FG_OFFSET]!==this._cellColorResolver.result.fg||this._model.cells[f+v.RENDER_MODEL_EXT_OFFSET]!==this._cellColorResolver.result.ext)&&(A=!0,d.length>1&&(_|=v.COMBINED_CHAR_BIT_MASK),this._model.cells[f]=_,this._model.cells[f+v.RENDER_MODEL_BG_OFFSET]=this._cellColorResolver.result.bg,this._model.cells[f+v.RENDER_MODEL_FG_OFFSET]=this._cellColorResolver.result.fg,this._model.cells[f+v.RENDER_MODEL_EXT_OFFSET]=this._cellColorResolver.result.ext,g=L.getWidth(),this._glyphRenderer.value.updateCell(x,r,_,this._cellColorResolver.result.bg,this._cellColorResolver.result.fg,this._cellColorResolver.result.ext,d,g,s),h))for(L=this._workCell,x++;x<l;x++)p=(r*i.cols+x)*v.RENDER_MODEL_INDICIES_PER_CELL,this._glyphRenderer.value.updateCell(x,r,u.NULL_CELL_CODE,0,0,0,u.NULL_CELL_CHAR,0,0),this._model.cells[p]=u.NULL_CELL_CODE,this._model.cells[p+v.RENDER_MODEL_BG_OFFSET]=this._cellColorResolver.result.bg,this._model.cells[p+v.RENDER_MODEL_FG_OFFSET]=this._cellColorResolver.result.fg,this._model.cells[p+v.RENDER_MODEL_EXT_OFFSET]=this._cellColorResolver.result.ext;A&&this._rectangleRenderer.value.updateBackgrounds(this._model),this._rectangleRenderer.value.updateCursor(this._model)}_updateDimensions(){this._charSizeService.width&&this._charSizeService.height&&(this.dimensions.device.char.width=Math.floor(this._charSizeService.width*this._devicePixelRatio),this.dimensions.device.char.height=Math.ceil(this._charSizeService.height*this._devicePixelRatio),this.dimensions.device.cell.height=Math.floor(this.dimensions.device.char.height*this._optionsService.rawOptions.lineHeight),this.dimensions.device.char.top=1===this._optionsService.rawOptions.lineHeight?0:Math.round((this.dimensions.device.cell.height-this.dimensions.device.char.height)/2),this.dimensions.device.cell.width=this.dimensions.device.char.width+Math.round(this._optionsService.rawOptions.letterSpacing),this.dimensions.device.char.left=Math.floor(this._optionsService.rawOptions.letterSpacing/2),this.dimensions.device.canvas.height=this._terminal.rows*this.dimensions.device.cell.height,this.dimensions.device.canvas.width=this._terminal.cols*this.dimensions.device.cell.width,this.dimensions.css.canvas.height=Math.round(this.dimensions.device.canvas.height/this._devicePixelRatio),this.dimensions.css.canvas.width=Math.round(this.dimensions.device.canvas.width/this._devicePixelRatio),this.dimensions.css.cell.height=this.dimensions.device.cell.height/this._devicePixelRatio,this.dimensions.css.cell.width=this.dimensions.device.cell.width/this._devicePixelRatio)}_setCanvasDevicePixelDimensions(e,t){this._canvas.width===e&&this._canvas.height===t||(this._canvas.width=e,this._canvas.height=t,this._requestRedrawViewport())}_requestRedrawViewport(){this._onRequestRedraw.fire({start:0,end:this._terminal.rows-1})}_requestRedrawCursor(){let e=this._terminal.buffer.active.cursorY;this._onRequestRedraw.fire({start:e,end:e})}}t.WebglRenderer=p;class C extends d.AttributeData{constructor(e,t,i){super(),this.content=0,this.combinedData="",this.fg=e.fg,this.bg=e.bg,this.combinedData=t,this._width=i}isCombined(){return 2097152}getWidth(){return this._width}getChars(){return this.combinedData}getCode(){return 2097151}setFromCharData(e){throw Error("not implemented")}getAsCharData(){return[this.fg,this.getChars(),this.getWidth(),this.getCode()]}}function m(e,t,i=0){return Math.max(Math.min(e,t),i)}t.JoinedCellData=C},381:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.GLTexture=t.expandFloat32Array=t.createShader=t.createProgram=t.PROJECTION_MATRIX=void 0;let s=i(374);function r(e,t,i){let r=(0,s.throwIfFalsy)(e.createShader(t));if(e.shaderSource(r,i),e.compileShader(r),e.getShaderParameter(r,e.COMPILE_STATUS))return r;console.error(e.getShaderInfoLog(r)),e.deleteShader(r)}t.PROJECTION_MATRIX=new Float32Array([2,0,0,0,0,-2,0,0,0,0,1,0,-1,1,0,1]),t.createProgram=function(e,t,i){let o=(0,s.throwIfFalsy)(e.createProgram());if(e.attachShader(o,(0,s.throwIfFalsy)(r(e,e.VERTEX_SHADER,t))),e.attachShader(o,(0,s.throwIfFalsy)(r(e,e.FRAGMENT_SHADER,i))),e.linkProgram(o),e.getProgramParameter(o,e.LINK_STATUS))return o;console.error(e.getProgramInfoLog(o)),e.deleteProgram(o)},t.createShader=r,t.expandFloat32Array=function(e,t){let i=new Float32Array(Math.min(2*e.length,t));for(let t=0;t<e.length;t++)i[t]=e[t];return i},t.GLTexture=class{constructor(e){this.texture=e,this.version=-1}}},592:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.BaseRenderLayer=void 0;let s=i(627),r=i(237),o=i(374),a=i(859);class n extends a.Disposable{constructor(e,t,i,s,r,o,n,h){super(),this._container=t,this._alpha=r,this._coreBrowserService=o,this._optionsService=n,this._themeService=h,this._deviceCharWidth=0,this._deviceCharHeight=0,this._deviceCellWidth=0,this._deviceCellHeight=0,this._deviceCharLeft=0,this._deviceCharTop=0,this._canvas=this._coreBrowserService.mainDocument.createElement("canvas"),this._canvas.classList.add(`xterm-${i}-layer`),this._canvas.style.zIndex=s.toString(),this._initCanvas(),this._container.appendChild(this._canvas),this.register(this._themeService.onChangeColors(t=>{this._refreshCharAtlas(e,t),this.reset(e)})),this.register((0,a.toDisposable)(()=>{this._canvas.remove()}))}_initCanvas(){this._ctx=(0,o.throwIfFalsy)(this._canvas.getContext("2d",{alpha:this._alpha})),this._alpha||this._clearAll()}handleBlur(e){}handleFocus(e){}handleCursorMove(e){}handleGridChanged(e,t,i){}handleSelectionChanged(e,t,i,s=!1){}_setTransparency(e,t){if(t===this._alpha)return;let i=this._canvas;this._alpha=t,this._canvas=this._canvas.cloneNode(),this._initCanvas(),this._container.replaceChild(this._canvas,i),this._refreshCharAtlas(e,this._themeService.colors),this.handleGridChanged(e,0,e.rows-1)}_refreshCharAtlas(e,t){this._deviceCharWidth<=0&&this._deviceCharHeight<=0||(this._charAtlas=(0,s.acquireTextureAtlas)(e,this._optionsService.rawOptions,t,this._deviceCellWidth,this._deviceCellHeight,this._deviceCharWidth,this._deviceCharHeight,this._coreBrowserService.dpr),this._charAtlas.warmUp())}resize(e,t){this._deviceCellWidth=t.device.cell.width,this._deviceCellHeight=t.device.cell.height,this._deviceCharWidth=t.device.char.width,this._deviceCharHeight=t.device.char.height,this._deviceCharLeft=t.device.char.left,this._deviceCharTop=t.device.char.top,this._canvas.width=t.device.canvas.width,this._canvas.height=t.device.canvas.height,this._canvas.style.width=`${t.css.canvas.width}px`,this._canvas.style.height=`${t.css.canvas.height}px`,this._alpha||this._clearAll(),this._refreshCharAtlas(e,this._themeService.colors)}_fillBottomLineAtCells(e,t,i=1){this._ctx.fillRect(e*this._deviceCellWidth,(t+1)*this._deviceCellHeight-this._coreBrowserService.dpr-1,i*this._deviceCellWidth,this._coreBrowserService.dpr)}_clearAll(){this._alpha?this._ctx.clearRect(0,0,this._canvas.width,this._canvas.height):(this._ctx.fillStyle=this._themeService.colors.background.css,this._ctx.fillRect(0,0,this._canvas.width,this._canvas.height))}_clearCells(e,t,i,s){this._alpha?this._ctx.clearRect(e*this._deviceCellWidth,t*this._deviceCellHeight,i*this._deviceCellWidth,s*this._deviceCellHeight):(this._ctx.fillStyle=this._themeService.colors.background.css,this._ctx.fillRect(e*this._deviceCellWidth,t*this._deviceCellHeight,i*this._deviceCellWidth,s*this._deviceCellHeight))}_fillCharTrueColor(e,t,i,s){this._ctx.font=this._getFont(e,!1,!1),this._ctx.textBaseline=r.TEXT_BASELINE,this._clipCell(i,s,t.getWidth()),this._ctx.fillText(t.getChars(),i*this._deviceCellWidth+this._deviceCharLeft,s*this._deviceCellHeight+this._deviceCharTop+this._deviceCharHeight)}_clipCell(e,t,i){this._ctx.beginPath(),this._ctx.rect(e*this._deviceCellWidth,t*this._deviceCellHeight,i*this._deviceCellWidth,this._deviceCellHeight),this._ctx.clip()}_getFont(e,t,i){return`${i?"italic":""} ${t?e.options.fontWeightBold:e.options.fontWeight} ${e.options.fontSize*this._coreBrowserService.dpr}px ${e.options.fontFamily}`}}t.BaseRenderLayer=n},733:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.LinkRenderLayer=void 0;let s=i(197),r=i(237),o=i(592);class a extends o.BaseRenderLayer{constructor(e,t,i,s,r,o,a){super(i,e,"link",t,!0,r,o,a),this.register(s.onShowLinkUnderline(e=>this._handleShowLinkUnderline(e))),this.register(s.onHideLinkUnderline(e=>this._handleHideLinkUnderline(e)))}resize(e,t){super.resize(e,t),this._state=void 0}reset(e){this._clearCurrentLink()}_clearCurrentLink(){if(this._state){this._clearCells(this._state.x1,this._state.y1,this._state.cols-this._state.x1,1);let e=this._state.y2-this._state.y1-1;e>0&&this._clearCells(0,this._state.y1+1,this._state.cols,e),this._clearCells(0,this._state.y2,this._state.x2,1),this._state=void 0}}_handleShowLinkUnderline(e){if(e.fg===r.INVERTED_DEFAULT_COLOR?this._ctx.fillStyle=this._themeService.colors.background.css:void 0!==e.fg&&(0,s.is256Color)(e.fg)?this._ctx.fillStyle=this._themeService.colors.ansi[e.fg].css:this._ctx.fillStyle=this._themeService.colors.foreground.css,e.y1===e.y2)this._fillBottomLineAtCells(e.x1,e.y1,e.x2-e.x1);else{this._fillBottomLineAtCells(e.x1,e.y1,e.cols-e.x1);for(let t=e.y1+1;t<e.y2;t++)this._fillBottomLineAtCells(0,t,e.cols);this._fillBottomLineAtCells(0,e.y2,e.x2)}this._state=e}_handleHideLinkUnderline(e){this._clearCurrentLink()}}t.LinkRenderLayer=a},820:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.addDisposableDomListener=void 0,t.addDisposableDomListener=function(e,t,i,s){e.addEventListener(t,i,s);let r=!1;return{dispose:()=>{r||(r=!0,e.removeEventListener(t,i,s))}}}},274:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CellColorResolver=void 0;let s=i(855),r=i(160),o=i(374),a,n=0,h=0,l=!1,c=!1,d=!1,_=0;t.CellColorResolver=class{constructor(e,t,i,s,r,o){this._terminal=e,this._optionService=t,this._selectionRenderModel=i,this._decorationService=s,this._coreBrowserService=r,this._themeService=o,this.result={fg:0,bg:0,ext:0}}resolve(e,t,i,u){if(this.result.bg=e.bg,this.result.fg=e.fg,this.result.ext=0x10000000&e.bg?e.extended.ext:0,h=0,n=0,c=!1,l=!1,d=!1,a=this._themeService.colors,_=0,e.getCode()!==s.NULL_CELL_CODE&&4===e.extended.underlineStyle&&(_=t*u%(2*Math.round(Math.max(1,Math.floor(this._optionService.rawOptions.fontSize*this._coreBrowserService.dpr/15))))),this._decorationService.forEachDecorationAtCell(t,i,"bottom",e=>{e.backgroundColorRGB&&(h=e.backgroundColorRGB.rgba>>8&0xffffff,c=!0),e.foregroundColorRGB&&(n=e.foregroundColorRGB.rgba>>8&0xffffff,l=!0)}),d=this._selectionRenderModel.isCellSelected(this._terminal,t,i)){if(0x4000000&this.result.fg||0!=(0x3000000&this.result.bg)){if(0x4000000&this.result.fg)switch(0x3000000&this.result.fg){case 0x1000000:case 0x2000000:h=this._themeService.colors.ansi[255&this.result.fg].rgba;break;case 0x3000000:h=(0xffffff&this.result.fg)<<8|255;break;default:h=this._themeService.colors.foreground.rgba}else switch(0x3000000&this.result.bg){case 0x1000000:case 0x2000000:h=this._themeService.colors.ansi[255&this.result.bg].rgba;break;case 0x3000000:h=(0xffffff&this.result.bg)<<8|255}h=r.rgba.blend(h,0xffffff00&(this._coreBrowserService.isFocused?a.selectionBackgroundOpaque:a.selectionInactiveBackgroundOpaque).rgba|128)>>8&0xffffff}else h=(this._coreBrowserService.isFocused?a.selectionBackgroundOpaque:a.selectionInactiveBackgroundOpaque).rgba>>8&0xffffff;if(c=!0,a.selectionForeground&&(n=a.selectionForeground.rgba>>8&0xffffff,l=!0),(0,o.treatGlyphAsBackgroundColor)(e.getCode())){if(0x4000000&this.result.fg&&0==(0x3000000&this.result.bg))n=(this._coreBrowserService.isFocused?a.selectionBackgroundOpaque:a.selectionInactiveBackgroundOpaque).rgba>>8&0xffffff;else{if(0x4000000&this.result.fg)switch(0x3000000&this.result.bg){case 0x1000000:case 0x2000000:n=this._themeService.colors.ansi[255&this.result.bg].rgba;break;case 0x3000000:n=(0xffffff&this.result.bg)<<8|255}else switch(0x3000000&this.result.fg){case 0x1000000:case 0x2000000:n=this._themeService.colors.ansi[255&this.result.fg].rgba;break;case 0x3000000:n=(0xffffff&this.result.fg)<<8|255;break;default:n=this._themeService.colors.foreground.rgba}n=r.rgba.blend(n,0xffffff00&(this._coreBrowserService.isFocused?a.selectionBackgroundOpaque:a.selectionInactiveBackgroundOpaque).rgba|128)>>8&0xffffff}l=!0}}this._decorationService.forEachDecorationAtCell(t,i,"top",e=>{e.backgroundColorRGB&&(h=e.backgroundColorRGB.rgba>>8&0xffffff,c=!0),e.foregroundColorRGB&&(n=e.foregroundColorRGB.rgba>>8&0xffffff,l=!0)}),c&&(h=d?-0x1000000&e.bg&-0x8000001|h|0x3000000:-0x1000000&e.bg|h|0x3000000),l&&(n=-0x1000000&e.fg&-0x4000001|n|0x3000000),0x4000000&this.result.fg&&(c&&!l&&(n=0==(0x3000000&this.result.bg)?-0x8000000&this.result.fg|0xffffff&a.background.rgba>>8|0x3000000:-0x8000000&this.result.fg|0x3ffffff&this.result.bg,l=!0),!c&&l&&(h=0==(0x3000000&this.result.fg)?-0x4000000&this.result.bg|0xffffff&a.foreground.rgba>>8|0x3000000:-0x4000000&this.result.bg|0x3ffffff&this.result.fg,c=!0)),a=void 0,this.result.bg=c?h:this.result.bg,this.result.fg=l?n:this.result.fg,this.result.ext&=0x1fffffff,this.result.ext|=_<<29&0xe0000000}}},627:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.removeTerminalFromCache=t.acquireTextureAtlas=void 0;let s=i(509),r=i(197),o=[];t.acquireTextureAtlas=function(e,t,i,a,n,h,l,c){let d=(0,r.generateConfig)(a,n,h,l,t,i,c);for(let t=0;t<o.length;t++){let i=o[t],s=i.ownedBy.indexOf(e);if(s>=0){if((0,r.configEquals)(i.config,d))return i.atlas;1===i.ownedBy.length?(i.atlas.dispose(),o.splice(t,1)):i.ownedBy.splice(s,1);break}}for(let t=0;t<o.length;t++){let i=o[t];if((0,r.configEquals)(i.config,d))return i.ownedBy.push(e),i.atlas}let _=e._core,u={atlas:new s.TextureAtlas(document,d,_.unicodeService),config:d,ownedBy:[e]};return o.push(u),u.atlas},t.removeTerminalFromCache=function(e){for(let t=0;t<o.length;t++){let i=o[t].ownedBy.indexOf(e);if(-1!==i){1===o[t].ownedBy.length?(o[t].atlas.dispose(),o.splice(t,1)):o[t].ownedBy.splice(i,1);break}}}},197:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.is256Color=t.configEquals=t.generateConfig=void 0;let s=i(160);t.generateConfig=function(e,t,i,r,o,a,n){let h={foreground:a.foreground,background:a.background,cursor:s.NULL_COLOR,cursorAccent:s.NULL_COLOR,selectionForeground:s.NULL_COLOR,selectionBackgroundTransparent:s.NULL_COLOR,selectionBackgroundOpaque:s.NULL_COLOR,selectionInactiveBackgroundTransparent:s.NULL_COLOR,selectionInactiveBackgroundOpaque:s.NULL_COLOR,ansi:a.ansi.slice(),contrastCache:a.contrastCache,halfContrastCache:a.halfContrastCache};return{customGlyphs:o.customGlyphs,devicePixelRatio:n,letterSpacing:o.letterSpacing,lineHeight:o.lineHeight,deviceCellWidth:e,deviceCellHeight:t,deviceCharWidth:i,deviceCharHeight:r,fontFamily:o.fontFamily,fontSize:o.fontSize,fontWeight:o.fontWeight,fontWeightBold:o.fontWeightBold,allowTransparency:o.allowTransparency,drawBoldTextInBrightColors:o.drawBoldTextInBrightColors,minimumContrastRatio:o.minimumContrastRatio,colors:h}},t.configEquals=function(e,t){for(let i=0;i<e.colors.ansi.length;i++)if(e.colors.ansi[i].rgba!==t.colors.ansi[i].rgba)return!1;return e.devicePixelRatio===t.devicePixelRatio&&e.customGlyphs===t.customGlyphs&&e.lineHeight===t.lineHeight&&e.letterSpacing===t.letterSpacing&&e.fontFamily===t.fontFamily&&e.fontSize===t.fontSize&&e.fontWeight===t.fontWeight&&e.fontWeightBold===t.fontWeightBold&&e.allowTransparency===t.allowTransparency&&e.deviceCharWidth===t.deviceCharWidth&&e.deviceCharHeight===t.deviceCharHeight&&e.drawBoldTextInBrightColors===t.drawBoldTextInBrightColors&&e.minimumContrastRatio===t.minimumContrastRatio&&e.colors.foreground.rgba===t.colors.foreground.rgba&&e.colors.background.rgba===t.colors.background.rgba},t.is256Color=function(e){return 0x1000000==(0x3000000&e)||0x2000000==(0x3000000&e)}},237:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.TEXT_BASELINE=t.DIM_OPACITY=t.INVERTED_DEFAULT_COLOR=void 0;let s=i(399);t.INVERTED_DEFAULT_COLOR=257,t.DIM_OPACITY=.5,t.TEXT_BASELINE=s.isFirefox||s.isLegacyEdge?"bottom":"ideographic"},457:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CursorBlinkStateManager=void 0,t.CursorBlinkStateManager=class{constructor(e,t){this._renderCallback=e,this._coreBrowserService=t,this.isCursorVisible=!0,this._coreBrowserService.isFocused&&this._restartInterval()}get isPaused(){return!(this._blinkStartTimeout||this._blinkInterval)}dispose(){this._blinkInterval&&(this._coreBrowserService.window.clearInterval(this._blinkInterval),this._blinkInterval=void 0),this._blinkStartTimeout&&(this._coreBrowserService.window.clearTimeout(this._blinkStartTimeout),this._blinkStartTimeout=void 0),this._animationFrame&&(this._coreBrowserService.window.cancelAnimationFrame(this._animationFrame),this._animationFrame=void 0)}restartBlinkAnimation(){this.isPaused||(this._animationTimeRestarted=Date.now(),this.isCursorVisible=!0,this._animationFrame||(this._animationFrame=this._coreBrowserService.window.requestAnimationFrame(()=>{this._renderCallback(),this._animationFrame=void 0})))}_restartInterval(e=600){this._blinkInterval&&(this._coreBrowserService.window.clearInterval(this._blinkInterval),this._blinkInterval=void 0),this._blinkStartTimeout=this._coreBrowserService.window.setTimeout(()=>{if(this._animationTimeRestarted){let e=600-(Date.now()-this._animationTimeRestarted);if(this._animationTimeRestarted=void 0,e>0)return void this._restartInterval(e)}this.isCursorVisible=!1,this._animationFrame=this._coreBrowserService.window.requestAnimationFrame(()=>{this._renderCallback(),this._animationFrame=void 0}),this._blinkInterval=this._coreBrowserService.window.setInterval(()=>{if(this._animationTimeRestarted){let e=600-(Date.now()-this._animationTimeRestarted);return this._animationTimeRestarted=void 0,void this._restartInterval(e)}this.isCursorVisible=!this.isCursorVisible,this._animationFrame=this._coreBrowserService.window.requestAnimationFrame(()=>{this._renderCallback(),this._animationFrame=void 0})},600)},e)}pause(){this.isCursorVisible=!0,this._blinkInterval&&(this._coreBrowserService.window.clearInterval(this._blinkInterval),this._blinkInterval=void 0),this._blinkStartTimeout&&(this._coreBrowserService.window.clearTimeout(this._blinkStartTimeout),this._blinkStartTimeout=void 0),this._animationFrame&&(this._coreBrowserService.window.cancelAnimationFrame(this._animationFrame),this._animationFrame=void 0)}resume(){this.pause(),this._animationTimeRestarted=void 0,this._restartInterval(),this.restartBlinkAnimation()}}},860:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.tryDrawCustomChar=t.powerlineDefinitions=t.boxDrawingDefinitions=t.blockElementDefinitions=void 0;let s=i(374);t.blockElementDefinitions={"▀":[{x:0,y:0,w:8,h:4}],"▁":[{x:0,y:7,w:8,h:1}],"▂":[{x:0,y:6,w:8,h:2}],"▃":[{x:0,y:5,w:8,h:3}],"▄":[{x:0,y:4,w:8,h:4}],"▅":[{x:0,y:3,w:8,h:5}],"▆":[{x:0,y:2,w:8,h:6}],"▇":[{x:0,y:1,w:8,h:7}],"█":[{x:0,y:0,w:8,h:8}],"▉":[{x:0,y:0,w:7,h:8}],"▊":[{x:0,y:0,w:6,h:8}],"▋":[{x:0,y:0,w:5,h:8}],"▌":[{x:0,y:0,w:4,h:8}],"▍":[{x:0,y:0,w:3,h:8}],"▎":[{x:0,y:0,w:2,h:8}],"▏":[{x:0,y:0,w:1,h:8}],"▐":[{x:4,y:0,w:4,h:8}],"▔":[{x:0,y:0,w:8,h:1}],"▕":[{x:7,y:0,w:1,h:8}],"▖":[{x:0,y:4,w:4,h:4}],"▗":[{x:4,y:4,w:4,h:4}],"▘":[{x:0,y:0,w:4,h:4}],"▙":[{x:0,y:0,w:4,h:8},{x:0,y:4,w:8,h:4}],"▚":[{x:0,y:0,w:4,h:4},{x:4,y:4,w:4,h:4}],"▛":[{x:0,y:0,w:4,h:8},{x:4,y:0,w:4,h:4}],"▜":[{x:0,y:0,w:8,h:4},{x:4,y:0,w:4,h:8}],"▝":[{x:4,y:0,w:4,h:4}],"▞":[{x:4,y:0,w:4,h:4},{x:0,y:4,w:4,h:4}],"▟":[{x:4,y:0,w:4,h:8},{x:0,y:4,w:8,h:4}],"\uD83E\uDF70":[{x:1,y:0,w:1,h:8}],"\uD83E\uDF71":[{x:2,y:0,w:1,h:8}],"\uD83E\uDF72":[{x:3,y:0,w:1,h:8}],"\uD83E\uDF73":[{x:4,y:0,w:1,h:8}],"\uD83E\uDF74":[{x:5,y:0,w:1,h:8}],"\uD83E\uDF75":[{x:6,y:0,w:1,h:8}],"\uD83E\uDF76":[{x:0,y:1,w:8,h:1}],"\uD83E\uDF77":[{x:0,y:2,w:8,h:1}],"\uD83E\uDF78":[{x:0,y:3,w:8,h:1}],"\uD83E\uDF79":[{x:0,y:4,w:8,h:1}],"\uD83E\uDF7A":[{x:0,y:5,w:8,h:1}],"\uD83E\uDF7B":[{x:0,y:6,w:8,h:1}],"\uD83E\uDF7C":[{x:0,y:0,w:1,h:8},{x:0,y:7,w:8,h:1}],"\uD83E\uDF7D":[{x:0,y:0,w:1,h:8},{x:0,y:0,w:8,h:1}],"\uD83E\uDF7E":[{x:7,y:0,w:1,h:8},{x:0,y:0,w:8,h:1}],"\uD83E\uDF7F":[{x:7,y:0,w:1,h:8},{x:0,y:7,w:8,h:1}],"\uD83E\uDF80":[{x:0,y:0,w:8,h:1},{x:0,y:7,w:8,h:1}],"\uD83E\uDF81":[{x:0,y:0,w:8,h:1},{x:0,y:2,w:8,h:1},{x:0,y:4,w:8,h:1},{x:0,y:7,w:8,h:1}],"\uD83E\uDF82":[{x:0,y:0,w:8,h:2}],"\uD83E\uDF83":[{x:0,y:0,w:8,h:3}],"\uD83E\uDF84":[{x:0,y:0,w:8,h:5}],"\uD83E\uDF85":[{x:0,y:0,w:8,h:6}],"\uD83E\uDF86":[{x:0,y:0,w:8,h:7}],"\uD83E\uDF87":[{x:6,y:0,w:2,h:8}],"\uD83E\uDF88":[{x:5,y:0,w:3,h:8}],"\uD83E\uDF89":[{x:3,y:0,w:5,h:8}],"\uD83E\uDF8A":[{x:2,y:0,w:6,h:8}],"\uD83E\uDF8B":[{x:1,y:0,w:7,h:8}],"\uD83E\uDF95":[{x:0,y:0,w:2,h:2},{x:4,y:0,w:2,h:2},{x:2,y:2,w:2,h:2},{x:6,y:2,w:2,h:2},{x:0,y:4,w:2,h:2},{x:4,y:4,w:2,h:2},{x:2,y:6,w:2,h:2},{x:6,y:6,w:2,h:2}],"\uD83E\uDF96":[{x:2,y:0,w:2,h:2},{x:6,y:0,w:2,h:2},{x:0,y:2,w:2,h:2},{x:4,y:2,w:2,h:2},{x:2,y:4,w:2,h:2},{x:6,y:4,w:2,h:2},{x:0,y:6,w:2,h:2},{x:4,y:6,w:2,h:2}],"\uD83E\uDF97":[{x:0,y:2,w:8,h:2},{x:0,y:6,w:8,h:2}]};let r={"░":[[1,0,0,0],[0,0,0,0],[0,0,1,0],[0,0,0,0]],"▒":[[1,0],[0,0],[0,1],[0,0]],"▓":[[0,1],[1,1],[1,0],[1,1]]};t.boxDrawingDefinitions={"─":{1:"M0,.5 L1,.5"},"━":{3:"M0,.5 L1,.5"},"│":{1:"M.5,0 L.5,1"},"┃":{3:"M.5,0 L.5,1"},"┌":{1:"M0.5,1 L.5,.5 L1,.5"},"┏":{3:"M0.5,1 L.5,.5 L1,.5"},"┐":{1:"M0,.5 L.5,.5 L.5,1"},"┓":{3:"M0,.5 L.5,.5 L.5,1"},"└":{1:"M.5,0 L.5,.5 L1,.5"},"┗":{3:"M.5,0 L.5,.5 L1,.5"},"┘":{1:"M.5,0 L.5,.5 L0,.5"},"┛":{3:"M.5,0 L.5,.5 L0,.5"},"├":{1:"M.5,0 L.5,1 M.5,.5 L1,.5"},"┣":{3:"M.5,0 L.5,1 M.5,.5 L1,.5"},"┤":{1:"M.5,0 L.5,1 M.5,.5 L0,.5"},"┫":{3:"M.5,0 L.5,1 M.5,.5 L0,.5"},"┬":{1:"M0,.5 L1,.5 M.5,.5 L.5,1"},"┳":{3:"M0,.5 L1,.5 M.5,.5 L.5,1"},"┴":{1:"M0,.5 L1,.5 M.5,.5 L.5,0"},"┻":{3:"M0,.5 L1,.5 M.5,.5 L.5,0"},"┼":{1:"M0,.5 L1,.5 M.5,0 L.5,1"},"╋":{3:"M0,.5 L1,.5 M.5,0 L.5,1"},"╴":{1:"M.5,.5 L0,.5"},"╸":{3:"M.5,.5 L0,.5"},"╵":{1:"M.5,.5 L.5,0"},"╹":{3:"M.5,.5 L.5,0"},"╶":{1:"M.5,.5 L1,.5"},"╺":{3:"M.5,.5 L1,.5"},"╷":{1:"M.5,.5 L.5,1"},"╻":{3:"M.5,.5 L.5,1"},"═":{1:(e,t)=>`M0,${.5-t} L1,${.5-t} M0,${.5+t} L1,${.5+t}`},"║":{1:(e,t)=>`M${.5-e},0 L${.5-e},1 M${.5+e},0 L${.5+e},1`},"╒":{1:(e,t)=>`M.5,1 L.5,${.5-t} L1,${.5-t} M.5,${.5+t} L1,${.5+t}`},"╓":{1:(e,t)=>`M${.5-e},1 L${.5-e},.5 L1,.5 M${.5+e},.5 L${.5+e},1`},"╔":{1:(e,t)=>`M1,${.5-t} L${.5-e},${.5-t} L${.5-e},1 M1,${.5+t} L${.5+e},${.5+t} L${.5+e},1`},"╕":{1:(e,t)=>`M0,${.5-t} L.5,${.5-t} L.5,1 M0,${.5+t} L.5,${.5+t}`},"╖":{1:(e,t)=>`M${.5+e},1 L${.5+e},.5 L0,.5 M${.5-e},.5 L${.5-e},1`},"╗":{1:(e,t)=>`M0,${.5+t} L${.5-e},${.5+t} L${.5-e},1 M0,${.5-t} L${.5+e},${.5-t} L${.5+e},1`},"╘":{1:(e,t)=>`M.5,0 L.5,${.5+t} L1,${.5+t} M.5,${.5-t} L1,${.5-t}`},"╙":{1:(e,t)=>`M1,.5 L${.5-e},.5 L${.5-e},0 M${.5+e},.5 L${.5+e},0`},"╚":{1:(e,t)=>`M1,${.5-t} L${.5+e},${.5-t} L${.5+e},0 M1,${.5+t} L${.5-e},${.5+t} L${.5-e},0`},"╛":{1:(e,t)=>`M0,${.5+t} L.5,${.5+t} L.5,0 M0,${.5-t} L.5,${.5-t}`},"╜":{1:(e,t)=>`M0,.5 L${.5+e},.5 L${.5+e},0 M${.5-e},.5 L${.5-e},0`},"╝":{1:(e,t)=>`M0,${.5-t} L${.5-e},${.5-t} L${.5-e},0 M0,${.5+t} L${.5+e},${.5+t} L${.5+e},0`},"╞":{1:(e,t)=>`M.5,0 L.5,1 M.5,${.5-t} L1,${.5-t} M.5,${.5+t} L1,${.5+t}`},"╟":{1:(e,t)=>`M${.5-e},0 L${.5-e},1 M${.5+e},0 L${.5+e},1 M${.5+e},.5 L1,.5`},"╠":{1:(e,t)=>`M${.5-e},0 L${.5-e},1 M1,${.5+t} L${.5+e},${.5+t} L${.5+e},1 M1,${.5-t} L${.5+e},${.5-t} L${.5+e},0`},"╡":{1:(e,t)=>`M.5,0 L.5,1 M0,${.5-t} L.5,${.5-t} M0,${.5+t} L.5,${.5+t}`},"╢":{1:(e,t)=>`M0,.5 L${.5-e},.5 M${.5-e},0 L${.5-e},1 M${.5+e},0 L${.5+e},1`},"╣":{1:(e,t)=>`M${.5+e},0 L${.5+e},1 M0,${.5+t} L${.5-e},${.5+t} L${.5-e},1 M0,${.5-t} L${.5-e},${.5-t} L${.5-e},0`},"╤":{1:(e,t)=>`M0,${.5-t} L1,${.5-t} M0,${.5+t} L1,${.5+t} M.5,${.5+t} L.5,1`},"╥":{1:(e,t)=>`M0,.5 L1,.5 M${.5-e},.5 L${.5-e},1 M${.5+e},.5 L${.5+e},1`},"╦":{1:(e,t)=>`M0,${.5-t} L1,${.5-t} M0,${.5+t} L${.5-e},${.5+t} L${.5-e},1 M1,${.5+t} L${.5+e},${.5+t} L${.5+e},1`},"╧":{1:(e,t)=>`M.5,0 L.5,${.5-t} M0,${.5-t} L1,${.5-t} M0,${.5+t} L1,${.5+t}`},"╨":{1:(e,t)=>`M0,.5 L1,.5 M${.5-e},.5 L${.5-e},0 M${.5+e},.5 L${.5+e},0`},"╩":{1:(e,t)=>`M0,${.5+t} L1,${.5+t} M0,${.5-t} L${.5-e},${.5-t} L${.5-e},0 M1,${.5-t} L${.5+e},${.5-t} L${.5+e},0`},"╪":{1:(e,t)=>`M.5,0 L.5,1 M0,${.5-t} L1,${.5-t} M0,${.5+t} L1,${.5+t}`},"╫":{1:(e,t)=>`M0,.5 L1,.5 M${.5-e},0 L${.5-e},1 M${.5+e},0 L${.5+e},1`},"╬":{1:(e,t)=>`M0,${.5+t} L${.5-e},${.5+t} L${.5-e},1 M1,${.5+t} L${.5+e},${.5+t} L${.5+e},1 M0,${.5-t} L${.5-e},${.5-t} L${.5-e},0 M1,${.5-t} L${.5+e},${.5-t} L${.5+e},0`},"╱":{1:"M1,0 L0,1"},"╲":{1:"M0,0 L1,1"},"╳":{1:"M1,0 L0,1 M0,0 L1,1"},"╼":{1:"M.5,.5 L0,.5",3:"M.5,.5 L1,.5"},"╽":{1:"M.5,.5 L.5,0",3:"M.5,.5 L.5,1"},"╾":{1:"M.5,.5 L1,.5",3:"M.5,.5 L0,.5"},"╿":{1:"M.5,.5 L.5,1",3:"M.5,.5 L.5,0"},"┍":{1:"M.5,.5 L.5,1",3:"M.5,.5 L1,.5"},"┎":{1:"M.5,.5 L1,.5",3:"M.5,.5 L.5,1"},"┑":{1:"M.5,.5 L.5,1",3:"M.5,.5 L0,.5"},"┒":{1:"M.5,.5 L0,.5",3:"M.5,.5 L.5,1"},"┕":{1:"M.5,.5 L.5,0",3:"M.5,.5 L1,.5"},"┖":{1:"M.5,.5 L1,.5",3:"M.5,.5 L.5,0"},"┙":{1:"M.5,.5 L.5,0",3:"M.5,.5 L0,.5"},"┚":{1:"M.5,.5 L0,.5",3:"M.5,.5 L.5,0"},"┝":{1:"M.5,0 L.5,1",3:"M.5,.5 L1,.5"},"┞":{1:"M0.5,1 L.5,.5 L1,.5",3:"M.5,.5 L.5,0"},"┟":{1:"M.5,0 L.5,.5 L1,.5",3:"M.5,.5 L.5,1"},"┠":{1:"M.5,.5 L1,.5",3:"M.5,0 L.5,1"},"┡":{1:"M.5,.5 L.5,1",3:"M.5,0 L.5,.5 L1,.5"},"┢":{1:"M.5,.5 L.5,0",3:"M0.5,1 L.5,.5 L1,.5"},"┥":{1:"M.5,0 L.5,1",3:"M.5,.5 L0,.5"},"┦":{1:"M0,.5 L.5,.5 L.5,1",3:"M.5,.5 L.5,0"},"┧":{1:"M.5,0 L.5,.5 L0,.5",3:"M.5,.5 L.5,1"},"┨":{1:"M.5,.5 L0,.5",3:"M.5,0 L.5,1"},"┩":{1:"M.5,.5 L.5,1",3:"M.5,0 L.5,.5 L0,.5"},"┪":{1:"M.5,.5 L.5,0",3:"M0,.5 L.5,.5 L.5,1"},"┭":{1:"M0.5,1 L.5,.5 L1,.5",3:"M.5,.5 L0,.5"},"┮":{1:"M0,.5 L.5,.5 L.5,1",3:"M.5,.5 L1,.5"},"┯":{1:"M.5,.5 L.5,1",3:"M0,.5 L1,.5"},"┰":{1:"M0,.5 L1,.5",3:"M.5,.5 L.5,1"},"┱":{1:"M.5,.5 L1,.5",3:"M0,.5 L.5,.5 L.5,1"},"┲":{1:"M.5,.5 L0,.5",3:"M0.5,1 L.5,.5 L1,.5"},"┵":{1:"M.5,0 L.5,.5 L1,.5",3:"M.5,.5 L0,.5"},"┶":{1:"M.5,0 L.5,.5 L0,.5",3:"M.5,.5 L1,.5"},"┷":{1:"M.5,.5 L.5,0",3:"M0,.5 L1,.5"},"┸":{1:"M0,.5 L1,.5",3:"M.5,.5 L.5,0"},"┹":{1:"M.5,.5 L1,.5",3:"M.5,0 L.5,.5 L0,.5"},"┺":{1:"M.5,.5 L0,.5",3:"M.5,0 L.5,.5 L1,.5"},"┽":{1:"M.5,0 L.5,1 M.5,.5 L1,.5",3:"M.5,.5 L0,.5"},"┾":{1:"M.5,0 L.5,1 M.5,.5 L0,.5",3:"M.5,.5 L1,.5"},"┿":{1:"M.5,0 L.5,1",3:"M0,.5 L1,.5"},"╀":{1:"M0,.5 L1,.5 M.5,.5 L.5,1",3:"M.5,.5 L.5,0"},"╁":{1:"M.5,.5 L.5,0 M0,.5 L1,.5",3:"M.5,.5 L.5,1"},"╂":{1:"M0,.5 L1,.5",3:"M.5,0 L.5,1"},"╃":{1:"M0.5,1 L.5,.5 L1,.5",3:"M.5,0 L.5,.5 L0,.5"},"╄":{1:"M0,.5 L.5,.5 L.5,1",3:"M.5,0 L.5,.5 L1,.5"},"╅":{1:"M.5,0 L.5,.5 L1,.5",3:"M0,.5 L.5,.5 L.5,1"},"╆":{1:"M.5,0 L.5,.5 L0,.5",3:"M0.5,1 L.5,.5 L1,.5"},"╇":{1:"M.5,.5 L.5,1",3:"M.5,.5 L.5,0 M0,.5 L1,.5"},"╈":{1:"M.5,.5 L.5,0",3:"M0,.5 L1,.5 M.5,.5 L.5,1"},"╉":{1:"M.5,.5 L1,.5",3:"M.5,0 L.5,1 M.5,.5 L0,.5"},"╊":{1:"M.5,.5 L0,.5",3:"M.5,0 L.5,1 M.5,.5 L1,.5"},"╌":{1:"M.1,.5 L.4,.5 M.6,.5 L.9,.5"},"╍":{3:"M.1,.5 L.4,.5 M.6,.5 L.9,.5"},"┄":{1:"M.0667,.5 L.2667,.5 M.4,.5 L.6,.5 M.7333,.5 L.9333,.5"},"┅":{3:"M.0667,.5 L.2667,.5 M.4,.5 L.6,.5 M.7333,.5 L.9333,.5"},"┈":{1:"M.05,.5 L.2,.5 M.3,.5 L.45,.5 M.55,.5 L.7,.5 M.8,.5 L.95,.5"},"┉":{3:"M.05,.5 L.2,.5 M.3,.5 L.45,.5 M.55,.5 L.7,.5 M.8,.5 L.95,.5"},"╎":{1:"M.5,.1 L.5,.4 M.5,.6 L.5,.9"},"╏":{3:"M.5,.1 L.5,.4 M.5,.6 L.5,.9"},"┆":{1:"M.5,.0667 L.5,.2667 M.5,.4 L.5,.6 M.5,.7333 L.5,.9333"},"┇":{3:"M.5,.0667 L.5,.2667 M.5,.4 L.5,.6 M.5,.7333 L.5,.9333"},"┊":{1:"M.5,.05 L.5,.2 M.5,.3 L.5,.45 L.5,.55 M.5,.7 L.5,.95"},"┋":{3:"M.5,.05 L.5,.2 M.5,.3 L.5,.45 L.5,.55 M.5,.7 L.5,.95"},"╭":{1:(e,t)=>`M.5,1 L.5,${.5+t/.15*.5} C.5,${.5+t/.15*.5},.5,.5,1,.5`},"╮":{1:(e,t)=>`M.5,1 L.5,${.5+t/.15*.5} C.5,${.5+t/.15*.5},.5,.5,0,.5`},"╯":{1:(e,t)=>`M.5,0 L.5,${.5-t/.15*.5} C.5,${.5-t/.15*.5},.5,.5,0,.5`},"╰":{1:(e,t)=>`M.5,0 L.5,${.5-t/.15*.5} C.5,${.5-t/.15*.5},.5,.5,1,.5`}},t.powerlineDefinitions={"":{d:"M0,0 L1,.5 L0,1",type:0,rightPadding:2},"":{d:"M-1,-.5 L1,.5 L-1,1.5",type:1,leftPadding:1,rightPadding:1},"":{d:"M1,0 L0,.5 L1,1",type:0,leftPadding:2},"":{d:"M2,-.5 L0,.5 L2,1.5",type:1,leftPadding:1,rightPadding:1},"":{d:"M0,0 L0,1 C0.552,1,1,0.776,1,.5 C1,0.224,0.552,0,0,0",type:0,rightPadding:1},"":{d:"M.2,1 C.422,1,.8,.826,.78,.5 C.8,.174,0.422,0,.2,0",type:1,rightPadding:1},"":{d:"M1,0 L1,1 C0.448,1,0,0.776,0,.5 C0,0.224,0.448,0,1,0",type:0,leftPadding:1},"":{d:"M.8,1 C0.578,1,0.2,.826,.22,.5 C0.2,0.174,0.578,0,0.8,0",type:1,leftPadding:1},"":{d:"M-.5,-.5 L1.5,1.5 L-.5,1.5",type:0},"":{d:"M-.5,-.5 L1.5,1.5",type:1,leftPadding:1,rightPadding:1},"":{d:"M1.5,-.5 L-.5,1.5 L1.5,1.5",type:0},"":{d:"M1.5,-.5 L-.5,1.5 L-.5,-.5",type:0},"":{d:"M1.5,-.5 L-.5,1.5",type:1,leftPadding:1,rightPadding:1},"":{d:"M-.5,-.5 L1.5,1.5 L1.5,-.5",type:0}},t.powerlineDefinitions[""]=t.powerlineDefinitions[""],t.powerlineDefinitions[""]=t.powerlineDefinitions[""],t.tryDrawCustomChar=function(e,i,a,l,c,d,_,u){let g=t.blockElementDefinitions[i];if(g)return function(e,t,i,s,r,o){for(let a=0;a<t.length;a++){let n=t[a],h=r/8,l=o/8;e.fillRect(i+n.x*h,s+n.y*l,n.w*h,n.h*l)}}(e,g,a,l,c,d),!0;let f=r[i];if(f)return function(e,t,i,r,a,n){let h=o.get(t);h||(h=new Map,o.set(t,h));let l=e.fillStyle;if("string"!=typeof l)throw Error(`Unexpected fillStyle type "${l}"`);let c=h.get(l);if(!c){let i,r,o,a,n=t[0].length,d=t.length,_=e.canvas.ownerDocument.createElement("canvas");_.width=n,_.height=d;let u=(0,s.throwIfFalsy)(_.getContext("2d")),g=new ImageData(n,d);if(l.startsWith("#"))i=parseInt(l.slice(1,3),16),r=parseInt(l.slice(3,5),16),o=parseInt(l.slice(5,7),16),a=l.length>7&&parseInt(l.slice(7,9),16)||1;else{if(!l.startsWith("rgba"))throw Error(`Unexpected fillStyle color format "${l}" when drawing pattern glyph`);[i,r,o,a]=l.substring(5,l.length-1).split(",").map(e=>parseFloat(e))}for(let e=0;e<d;e++)for(let s=0;s<n;s++)g.data[4*(e*n+s)]=i,g.data[4*(e*n+s)+1]=r,g.data[4*(e*n+s)+2]=o,g.data[4*(e*n+s)+3]=t[e][s]*(255*a);u.putImageData(g,0,0),c=(0,s.throwIfFalsy)(e.createPattern(_,null)),h.set(l,c)}e.fillStyle=c,e.fillRect(i,r,a,n)}(e,f,a,l,c,d),!0;let v=t.boxDrawingDefinitions[i];if(v)return function(e,t,i,s,r,o,a){for(let[l,c]of(e.strokeStyle=e.fillStyle,Object.entries(t))){for(let t of(e.beginPath(),e.lineWidth=a*Number.parseInt(l),("function"==typeof c?c(.15,.15/o*r):c).split(" "))){let l=t[0],c=n[l];if(!c){console.error(`Could not find drawing instructions for "${l}"`);continue}let d=t.substring(1).split(",");d[0]&&d[1]&&c(e,h(d,r,o,i,s,!0,a))}e.stroke(),e.closePath()}}(e,v,a,l,c,d,u),!0;let x=t.powerlineDefinitions[i];return!!x&&(function(e,t,i,s,r,o,a,l){let c=new Path2D;c.rect(i,s,r,o),e.clip(c),e.beginPath();let d=a/12;for(let a of(e.lineWidth=l*d,t.d.split(" "))){let c=a[0],_=n[c];if(!_){console.error(`Could not find drawing instructions for "${c}"`);continue}let u=a.substring(1).split(",");u[0]&&u[1]&&_(e,h(u,r,o,i,s,!1,l,(t.leftPadding??0)*(d/2),(t.rightPadding??0)*(d/2)))}1===t.type?(e.strokeStyle=e.fillStyle,e.stroke()):e.fill(),e.closePath()}(e,x,a,l,c,d,_,u),!0)};let o=new Map;function a(e,t,i=0){return Math.max(Math.min(e,t),i)}let n={C:(e,t)=>e.bezierCurveTo(t[0],t[1],t[2],t[3],t[4],t[5]),L:(e,t)=>e.lineTo(t[0],t[1]),M:(e,t)=>e.moveTo(t[0],t[1])};function h(e,t,i,s,r,o,n,l=0,c=0){let d=e.map(e=>parseFloat(e)||parseInt(e));if(d.length<2)throw Error("Too few arguments for instruction");for(let e=0;e<d.length;e+=2)d[e]*=t-l*n-c*n,o&&0!==d[e]&&(d[e]=a(Math.round(d[e]+.5)-.5,t,0)),d[e]+=s+l*n;for(let e=1;e<d.length;e+=2)d[e]*=i,o&&0!==d[e]&&(d[e]=a(Math.round(d[e]+.5)-.5,i,0)),d[e]+=r;return d}},56:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.observeDevicePixelDimensions=void 0;let s=i(859);t.observeDevicePixelDimensions=function(e,t,i){let r=new t.ResizeObserver(t=>{let s=t.find(t=>t.target===e);if(!s)return;if(!("devicePixelContentBoxSize"in s))return r?.disconnect(),void(r=void 0);let o=s.devicePixelContentBoxSize[0].inlineSize,a=s.devicePixelContentBoxSize[0].blockSize;o>0&&a>0&&i(o,a)});try{r.observe(e,{box:["device-pixel-content-box"]})}catch{r.disconnect(),r=void 0}return(0,s.toDisposable)(()=>r?.disconnect())}},374:(e,t)=>{function i(e){return 57508<=e&&e<=57558}function s(e){return e>=128512&&e<=128591||e>=127744&&e<=128511||e>=128640&&e<=128767||e>=9728&&e<=9983||e>=9984&&e<=10175||e>=65024&&e<=65039||e>=129280&&e<=129535||e>=127462&&e<=127487}Object.defineProperty(t,"__esModule",{value:!0}),t.computeNextVariantOffset=t.createRenderDimensions=t.treatGlyphAsBackgroundColor=t.allowRescaling=t.isEmoji=t.isRestrictedPowerlineGlyph=t.isPowerlineGlyph=t.throwIfFalsy=void 0,t.throwIfFalsy=function(e){if(!e)throw Error("value must not be falsy");return e},t.isPowerlineGlyph=i,t.isRestrictedPowerlineGlyph=function(e){return 57520<=e&&e<=57527},t.isEmoji=s,t.allowRescaling=function(e,t,r,o){return 1===t&&r>Math.ceil(1.5*o)&&void 0!==e&&e>255&&!s(e)&&!i(e)&&!(57344<=e&&e<=63743)},t.treatGlyphAsBackgroundColor=function(e){return i(e)||9472<=e&&e<=9631},t.createRenderDimensions=function(){return{css:{canvas:{width:0,height:0},cell:{width:0,height:0}},device:{canvas:{width:0,height:0},cell:{width:0,height:0},char:{width:0,height:0,left:0,top:0}}}},t.computeNextVariantOffset=function(e,t,i=0){return(e-(2*Math.round(t)-i))%(2*Math.round(t))}},296:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.createSelectionRenderModel=void 0;class i{constructor(){this.clear()}clear(){this.hasSelection=!1,this.columnSelectMode=!1,this.viewportStartRow=0,this.viewportEndRow=0,this.viewportCappedStartRow=0,this.viewportCappedEndRow=0,this.startCol=0,this.endCol=0,this.selectionStart=void 0,this.selectionEnd=void 0}update(e,t,i,s=!1){if(this.selectionStart=t,this.selectionEnd=i,!t||!i||t[0]===i[0]&&t[1]===i[1])return void this.clear();let r=e.buffers.active.ydisp,o=t[1]-r,a=i[1]-r,n=Math.max(o,0),h=Math.min(a,e.rows-1);n>=e.rows||h<0?this.clear():(this.hasSelection=!0,this.columnSelectMode=s,this.viewportStartRow=o,this.viewportEndRow=a,this.viewportCappedStartRow=n,this.viewportCappedEndRow=h,this.startCol=t[0],this.endCol=i[0])}isCellSelected(e,t,i){return!!this.hasSelection&&(i-=e.buffer.active.viewportY,this.columnSelectMode?this.startCol<=this.endCol?t>=this.startCol&&i>=this.viewportCappedStartRow&&t<this.endCol&&i<=this.viewportCappedEndRow:t<this.startCol&&i>=this.viewportCappedStartRow&&t>=this.endCol&&i<=this.viewportCappedEndRow:i>this.viewportStartRow&&i<this.viewportEndRow||this.viewportStartRow===this.viewportEndRow&&i===this.viewportStartRow&&t>=this.startCol&&t<this.endCol||this.viewportStartRow<this.viewportEndRow&&i===this.viewportEndRow&&t<this.endCol||this.viewportStartRow<this.viewportEndRow&&i===this.viewportStartRow&&t>=this.startCol)}}t.createSelectionRenderModel=function(){return new i}},509:(e,t,i)=>{let s;Object.defineProperty(t,"__esModule",{value:!0}),t.TextureAtlas=void 0;let r=i(237),o=i(860),a=i(374),n=i(160),h=i(345),l=i(485),c=i(385),d=i(147),_=i(855),u={texturePage:0,texturePosition:{x:0,y:0},texturePositionClipSpace:{x:0,y:0},offset:{x:0,y:0},size:{x:0,y:0},sizeClipSpace:{x:0,y:0}};class g{get pages(){return this._pages}constructor(e,t,i){this._document=e,this._config=t,this._unicodeService=i,this._didWarmUp=!1,this._cacheMap=new l.FourKeyMap,this._cacheMapCombined=new l.FourKeyMap,this._pages=[],this._activePages=[],this._workBoundingBox={top:0,left:0,bottom:0,right:0},this._workAttributeData=new d.AttributeData,this._textureSize=512,this._onAddTextureAtlasCanvas=new h.EventEmitter,this.onAddTextureAtlasCanvas=this._onAddTextureAtlasCanvas.event,this._onRemoveTextureAtlasCanvas=new h.EventEmitter,this.onRemoveTextureAtlasCanvas=this._onRemoveTextureAtlasCanvas.event,this._requestClearModel=!1,this._createNewPage(),this._tmpCanvas=x(e,4*this._config.deviceCellWidth+4,this._config.deviceCellHeight+4),this._tmpCtx=(0,a.throwIfFalsy)(this._tmpCanvas.getContext("2d",{alpha:this._config.allowTransparency,willReadFrequently:!0}))}dispose(){for(let e of this.pages)e.canvas.remove();this._onAddTextureAtlasCanvas.dispose()}warmUp(){this._didWarmUp||(this._doWarmUp(),this._didWarmUp=!0)}_doWarmUp(){let e=new c.IdleTaskQueue;for(let t=33;t<126;t++)e.enqueue(()=>{if(!this._cacheMap.get(t,_.DEFAULT_COLOR,_.DEFAULT_COLOR,_.DEFAULT_EXT)){let e=this._drawToCache(t,_.DEFAULT_COLOR,_.DEFAULT_COLOR,_.DEFAULT_EXT);this._cacheMap.set(t,_.DEFAULT_COLOR,_.DEFAULT_COLOR,_.DEFAULT_EXT,e)}})}beginFrame(){return this._requestClearModel}clearTexture(){if(0!==this._pages[0].currentRow.x||0!==this._pages[0].currentRow.y){for(let e of this._pages)e.clear();this._cacheMap.clear(),this._cacheMapCombined.clear(),this._didWarmUp=!1}}_createNewPage(){if(g.maxAtlasPages&&this._pages.length>=Math.max(4,g.maxAtlasPages)){let e=this._pages.filter(e=>2*e.canvas.width<=(g.maxTextureSize||4096)).sort((e,t)=>t.canvas.width!==e.canvas.width?t.canvas.width-e.canvas.width:t.percentageUsed-e.percentageUsed),t=-1,i=0;for(let s=0;s<e.length;s++)if(e[s].canvas.width!==i)t=s,i=e[s].canvas.width;else if(s-t==3)break;let s=e.slice(t,t+4),r=s.map(e=>e.glyphs[0].texturePage).sort((e,t)=>e>t?1:-1),o=this.pages.length-s.length,a=this._mergePages(s,o);a.version++;for(let e=r.length-1;e>=0;e--)this._deletePage(r[e]);this.pages.push(a),this._requestClearModel=!0,this._onAddTextureAtlasCanvas.fire(a.canvas)}let e=new f(this._document,this._textureSize);return this._pages.push(e),this._activePages.push(e),this._onAddTextureAtlasCanvas.fire(e.canvas),e}_mergePages(e,t){let i=2*e[0].canvas.width,s=new f(this._document,i,e);for(let[r,o]of e.entries()){let e=r*o.canvas.width%i,a=Math.floor(r/2)*o.canvas.height;for(let r of(s.ctx.drawImage(o.canvas,e,a),o.glyphs))r.texturePage=t,r.sizeClipSpace.x=r.size.x/i,r.sizeClipSpace.y=r.size.y/i,r.texturePosition.x+=e,r.texturePosition.y+=a,r.texturePositionClipSpace.x=r.texturePosition.x/i,r.texturePositionClipSpace.y=r.texturePosition.y/i;this._onRemoveTextureAtlasCanvas.fire(o.canvas);let n=this._activePages.indexOf(o);-1!==n&&this._activePages.splice(n,1)}return s}_deletePage(e){this._pages.splice(e,1);for(let t=e;t<this._pages.length;t++){let e=this._pages[t];for(let t of e.glyphs)t.texturePage--;e.version++}}getRasterizedGlyphCombinedChar(e,t,i,s,r){return this._getFromCacheMap(this._cacheMapCombined,e,t,i,s,r)}getRasterizedGlyph(e,t,i,s,r){return this._getFromCacheMap(this._cacheMap,e,t,i,s,r)}_getFromCacheMap(e,t,i,r,o,a=!1){return(s=e.get(t,i,r,o))||(s=this._drawToCache(t,i,r,o,a),e.set(t,i,r,o,s)),s}_getColorFromAnsiIndex(e){if(e>=this._config.colors.ansi.length)throw Error("No color found for idx "+e);return this._config.colors.ansi[e]}_getBackgroundColor(e,t,i,s){let r;if(this._config.allowTransparency)return n.NULL_COLOR;switch(e){case 0x1000000:case 0x2000000:r=this._getColorFromAnsiIndex(t);break;case 0x3000000:let o=d.AttributeData.toColorRGB(t);r=n.channels.toColor(o[0],o[1],o[2]);break;default:r=i?n.color.opaque(this._config.colors.foreground):this._config.colors.background}return r}_getForegroundColor(e,t,i,s,o,a,h,l,c,_){let u,g=this._getMinimumContrastColor(e,t,i,s,o,a,h,c,l,_);if(g)return g;switch(o){case 0x1000000:case 0x2000000:this._config.drawBoldTextInBrightColors&&c&&a<8&&(a+=8),u=this._getColorFromAnsiIndex(a);break;case 0x3000000:let f=d.AttributeData.toColorRGB(a);u=n.channels.toColor(f[0],f[1],f[2]);break;default:u=h?this._config.colors.background:this._config.colors.foreground}return this._config.allowTransparency&&(u=n.color.opaque(u)),l&&(u=n.color.multiplyOpacity(u,r.DIM_OPACITY)),u}_resolveBackgroundRgba(e,t,i){switch(e){case 0x1000000:case 0x2000000:return this._getColorFromAnsiIndex(t).rgba;case 0x3000000:return t<<8;default:return i?this._config.colors.foreground.rgba:this._config.colors.background.rgba}}_resolveForegroundRgba(e,t,i,s){switch(e){case 0x1000000:case 0x2000000:return this._config.drawBoldTextInBrightColors&&s&&t<8&&(t+=8),this._getColorFromAnsiIndex(t).rgba;case 0x3000000:return t<<8;default:return i?this._config.colors.background.rgba:this._config.colors.foreground.rgba}}_getMinimumContrastColor(e,t,i,s,r,o,a,h,l,c){if(1===this._config.minimumContrastRatio||c)return;let d=this._getContrastCache(l),_=d.getColor(e,s);if(void 0!==_)return _||void 0;let u=this._resolveBackgroundRgba(t,i,a),g=this._resolveForegroundRgba(r,o,a,h),f=n.rgba.ensureContrastRatio(u,g,this._config.minimumContrastRatio/(l?2:1));if(!f)return void d.setColor(e,s,null);let v=n.channels.toColor(f>>24&255,f>>16&255,f>>8&255);return d.setColor(e,s,v),v}_getContrastCache(e){return e?this._config.colors.halfContrastCache:this._config.colors.contrastCache}_drawToCache(e,t,i,s,n=!1){let h,l,c="number"==typeof e?String.fromCharCode(e):e,_=Math.min(this._config.deviceCellWidth*Math.max(c.length,2)+4,this._textureSize);this._tmpCanvas.width<_&&(this._tmpCanvas.width=_);let f=Math.min(this._config.deviceCellHeight+8,this._textureSize);if(this._tmpCanvas.height<f&&(this._tmpCanvas.height=f),this._tmpCtx.save(),this._workAttributeData.fg=i,this._workAttributeData.bg=t,this._workAttributeData.extended.ext=s,this._workAttributeData.isInvisible())return u;let x=!!this._workAttributeData.isBold(),p=!!this._workAttributeData.isInverse(),C=!!this._workAttributeData.isDim(),m=!!this._workAttributeData.isItalic(),L=!!this._workAttributeData.isUnderline(),w=!!this._workAttributeData.isStrikethrough(),b=!!this._workAttributeData.isOverline(),M=this._workAttributeData.getFgColor(),R=this._workAttributeData.getFgColorMode(),y=this._workAttributeData.getBgColor(),A=this._workAttributeData.getBgColorMode();if(p){let e=M;M=y,y=e;let t=R;R=A,A=t}let E=this._getBackgroundColor(A,y,p,C);this._tmpCtx.globalCompositeOperation="copy",this._tmpCtx.fillStyle=E.css,this._tmpCtx.fillRect(0,0,this._tmpCanvas.width,this._tmpCanvas.height),this._tmpCtx.globalCompositeOperation="source-over";let S=x?this._config.fontWeightBold:this._config.fontWeight;this._tmpCtx.font=`${m?"italic":""} ${S} ${this._config.fontSize*this._config.devicePixelRatio}px ${this._config.fontFamily}`,this._tmpCtx.textBaseline=r.TEXT_BASELINE;let T=1===c.length&&(0,a.isPowerlineGlyph)(c.charCodeAt(0)),D=1===c.length&&(0,a.isRestrictedPowerlineGlyph)(c.charCodeAt(0)),B=this._getForegroundColor(t,A,y,i,R,M,p,C,x,(0,a.treatGlyphAsBackgroundColor)(c.charCodeAt(0)));this._tmpCtx.fillStyle=B.css;let F=4*!D,P=!1;!1!==this._config.customGlyphs&&(P=(0,o.tryDrawCustomChar)(this._tmpCtx,c,F,F,this._config.deviceCellWidth,this._config.deviceCellHeight,this._config.fontSize,this._config.devicePixelRatio));let I,O=!T;if(I="number"==typeof e?this._unicodeService.wcwidth(e):this._unicodeService.getStringCellWidth(e),L){this._tmpCtx.save();let e=Math.max(1,Math.floor(this._config.fontSize*this._config.devicePixelRatio/15)),t=.5*(e%2==1);if(this._tmpCtx.lineWidth=e,this._workAttributeData.isUnderlineColorDefault())this._tmpCtx.strokeStyle=this._tmpCtx.fillStyle;else if(this._workAttributeData.isUnderlineColorRGB())O=!1,this._tmpCtx.strokeStyle=`rgb(${d.AttributeData.toColorRGB(this._workAttributeData.getUnderlineColor()).join(",")})`;else{O=!1;let e=this._workAttributeData.getUnderlineColor();this._config.drawBoldTextInBrightColors&&this._workAttributeData.isBold()&&e<8&&(e+=8),this._tmpCtx.strokeStyle=this._getColorFromAnsiIndex(e).css}this._tmpCtx.beginPath();let i=Math.ceil(F+this._config.deviceCharHeight)-t-(n?2*e:0),s=i+e,r=i+2*e,o=this._workAttributeData.getUnderlineVariantOffset();for(let n=0;n<I;n++){this._tmpCtx.save();let h=F+n*this._config.deviceCellWidth,l=F+(n+1)*this._config.deviceCellWidth,c=h+this._config.deviceCellWidth/2;switch(this._workAttributeData.extended.underlineStyle){case 2:this._tmpCtx.moveTo(h,i),this._tmpCtx.lineTo(l,i),this._tmpCtx.moveTo(h,r),this._tmpCtx.lineTo(l,r);break;case 3:let d=e<=1?r:Math.ceil(F+this._config.deviceCharHeight-e/2)-t,_=e<=1?i:Math.ceil(F+this._config.deviceCharHeight+e/2)-t,u=new Path2D;u.rect(h,i,this._config.deviceCellWidth,r-i),this._tmpCtx.clip(u),this._tmpCtx.moveTo(h-this._config.deviceCellWidth/2,s),this._tmpCtx.bezierCurveTo(h-this._config.deviceCellWidth/2,_,h,_,h,s),this._tmpCtx.bezierCurveTo(h,d,c,d,c,s),this._tmpCtx.bezierCurveTo(c,_,l,_,l,s),this._tmpCtx.bezierCurveTo(l,d,l+this._config.deviceCellWidth/2,d,l+this._config.deviceCellWidth/2,s);break;case 4:let g=0===o?0:o>=e?2*e-o:e-o;!1==!(o>=e)||0===g?(this._tmpCtx.setLineDash([Math.round(e),Math.round(e)]),this._tmpCtx.moveTo(h+g,i)):(this._tmpCtx.setLineDash([Math.round(e),Math.round(e)]),this._tmpCtx.moveTo(h,i),this._tmpCtx.lineTo(h+g,i),this._tmpCtx.moveTo(h+g+e,i)),this._tmpCtx.lineTo(l,i),o=(0,a.computeNextVariantOffset)(l-h,e,o);break;case 5:let f=l-h,v=Math.floor(.6*f),x=Math.floor(.3*f),p=f-v-x;this._tmpCtx.setLineDash([v,x,p]),this._tmpCtx.moveTo(h,i),this._tmpCtx.lineTo(l,i);break;default:this._tmpCtx.moveTo(h,i),this._tmpCtx.lineTo(l,i)}this._tmpCtx.stroke(),this._tmpCtx.restore()}if(this._tmpCtx.restore(),!P&&this._config.fontSize>=12&&!this._config.allowTransparency&&" "!==c){this._tmpCtx.save(),this._tmpCtx.textBaseline="alphabetic";let t=this._tmpCtx.measureText(c);if(this._tmpCtx.restore(),"actualBoundingBoxDescent"in t&&t.actualBoundingBoxDescent>0){this._tmpCtx.save();let t=new Path2D;t.rect(F,i-Math.ceil(e/2),this._config.deviceCellWidth*I,r-i+Math.ceil(e/2)),this._tmpCtx.clip(t),this._tmpCtx.lineWidth=3*this._config.devicePixelRatio,this._tmpCtx.strokeStyle=E.css,this._tmpCtx.strokeText(c,F,F+this._config.deviceCharHeight),this._tmpCtx.restore()}}}if(b){let e=Math.max(1,Math.floor(this._config.fontSize*this._config.devicePixelRatio/15)),t=.5*(e%2==1);this._tmpCtx.lineWidth=e,this._tmpCtx.strokeStyle=this._tmpCtx.fillStyle,this._tmpCtx.beginPath(),this._tmpCtx.moveTo(F,F+t),this._tmpCtx.lineTo(F+this._config.deviceCharWidth*I,F+t),this._tmpCtx.stroke()}if(P||this._tmpCtx.fillText(c,F,F+this._config.deviceCharHeight),"_"===c&&!this._config.allowTransparency){let e=v(this._tmpCtx.getImageData(F,F,this._config.deviceCellWidth,this._config.deviceCellHeight),E,B,O);if(e)for(let t=1;t<=5&&(this._tmpCtx.save(),this._tmpCtx.fillStyle=E.css,this._tmpCtx.fillRect(0,0,this._tmpCanvas.width,this._tmpCanvas.height),this._tmpCtx.restore(),this._tmpCtx.fillText(c,F,F+this._config.deviceCharHeight-t),e=v(this._tmpCtx.getImageData(F,F,this._config.deviceCellWidth,this._config.deviceCellHeight),E,B,O));t++);}if(w){let e=Math.max(1,Math.floor(this._config.fontSize*this._config.devicePixelRatio/10)),t=.5*(this._tmpCtx.lineWidth%2==1);this._tmpCtx.lineWidth=e,this._tmpCtx.strokeStyle=this._tmpCtx.fillStyle,this._tmpCtx.beginPath(),this._tmpCtx.moveTo(F,F+Math.floor(this._config.deviceCharHeight/2)-t),this._tmpCtx.lineTo(F+this._config.deviceCharWidth*I,F+Math.floor(this._config.deviceCharHeight/2)-t),this._tmpCtx.stroke()}this._tmpCtx.restore();let k=this._tmpCtx.getImageData(0,0,this._tmpCanvas.width,this._tmpCanvas.height);if(this._config.allowTransparency?function(e){for(let t=0;t<e.data.length;t+=4)if(e.data[t+3]>0)return!1;return!0}(k):v(k,E,B,O))return u;let $=this._findGlyphBoundingBox(k,this._workBoundingBox,_,D,P,F);for(;;){if(0===this._activePages.length){let e=this._createNewPage();h=e,(l=e.currentRow).height=$.size.y;break}for(let e of(l=(h=this._activePages[this._activePages.length-1]).currentRow,this._activePages))$.size.y<=e.currentRow.height&&(h=e,l=e.currentRow);for(let e=this._activePages.length-1;e>=0;e--)for(let t of this._activePages[e].fixedRows)t.height<=l.height&&$.size.y<=t.height&&(h=this._activePages[e],l=t);if(l.y+$.size.y>=h.canvas.height||l.height>$.size.y+2){let e=!1;if(h.currentRow.y+h.currentRow.height+$.size.y>=h.canvas.height){let t;for(let e of this._activePages)if(e.currentRow.y+e.currentRow.height+$.size.y<e.canvas.height){t=e;break}if(t)h=t;else if(g.maxAtlasPages&&this._pages.length>=g.maxAtlasPages&&l.y+$.size.y<=h.canvas.height&&l.height>=$.size.y&&l.x+$.size.x<=h.canvas.width)e=!0;else{let t=this._createNewPage();h=t,(l=t.currentRow).height=$.size.y,e=!0}}e||(h.currentRow.height>0&&h.fixedRows.push(h.currentRow),l={x:0,y:h.currentRow.y+h.currentRow.height,height:$.size.y},h.fixedRows.push(l),h.currentRow={x:0,y:l.y+l.height,height:0})}if(l.x+$.size.x<=h.canvas.width)break;l===h.currentRow?(l.x=0,l.y+=l.height,l.height=0):h.fixedRows.splice(h.fixedRows.indexOf(l),1)}return $.texturePage=this._pages.indexOf(h),$.texturePosition.x=l.x,$.texturePosition.y=l.y,$.texturePositionClipSpace.x=l.x/h.canvas.width,$.texturePositionClipSpace.y=l.y/h.canvas.height,$.sizeClipSpace.x/=h.canvas.width,$.sizeClipSpace.y/=h.canvas.height,l.height=Math.max(l.height,$.size.y),l.x+=$.size.x,h.ctx.putImageData(k,$.texturePosition.x-this._workBoundingBox.left,$.texturePosition.y-this._workBoundingBox.top,this._workBoundingBox.left,this._workBoundingBox.top,$.size.x,$.size.y),h.addGlyph($),h.version++,$}_findGlyphBoundingBox(e,t,i,s,r,o){t.top=0;let a=s?this._config.deviceCellHeight:this._tmpCanvas.height,n=s?this._config.deviceCellWidth:i,h=!1;for(let i=0;i<a;i++){for(let s=0;s<n;s++){let r=i*this._tmpCanvas.width*4+4*s+3;if(0!==e.data[r]){t.top=i,h=!0;break}}if(h)break}t.left=0,h=!1;for(let i=0;i<o+n;i++){for(let s=0;s<a;s++){let r=s*this._tmpCanvas.width*4+4*i+3;if(0!==e.data[r]){t.left=i,h=!0;break}}if(h)break}t.right=n,h=!1;for(let i=o+n-1;i>=o;i--){for(let s=0;s<a;s++){let r=s*this._tmpCanvas.width*4+4*i+3;if(0!==e.data[r]){t.right=i,h=!0;break}}if(h)break}t.bottom=a,h=!1;for(let i=a-1;i>=0;i--){for(let s=0;s<n;s++){let r=i*this._tmpCanvas.width*4+4*s+3;if(0!==e.data[r]){t.bottom=i,h=!0;break}}if(h)break}return{texturePage:0,texturePosition:{x:0,y:0},texturePositionClipSpace:{x:0,y:0},size:{x:t.right-t.left+1,y:t.bottom-t.top+1},sizeClipSpace:{x:t.right-t.left+1,y:t.bottom-t.top+1},offset:{x:-t.left+o+(s||r?Math.floor((this._config.deviceCellWidth-this._config.deviceCharWidth)/2):0),y:-t.top+o+(s||r?1===this._config.lineHeight?0:Math.round((this._config.deviceCellHeight-this._config.deviceCharHeight)/2):0)}}}}t.TextureAtlas=g;class f{get percentageUsed(){return this._usedPixels/(this.canvas.width*this.canvas.height)}get glyphs(){return this._glyphs}addGlyph(e){this._glyphs.push(e),this._usedPixels+=e.size.x*e.size.y}constructor(e,t,i){if(this._usedPixels=0,this._glyphs=[],this.version=0,this.currentRow={x:0,y:0,height:0},this.fixedRows=[],i)for(let e of i)this._glyphs.push(...e.glyphs),this._usedPixels+=e._usedPixels;this.canvas=x(e,t,t),this.ctx=(0,a.throwIfFalsy)(this.canvas.getContext("2d",{alpha:!0}))}clear(){this.ctx.clearRect(0,0,this.canvas.width,this.canvas.height),this.currentRow.x=0,this.currentRow.y=0,this.currentRow.height=0,this.fixedRows.length=0,this.version++}}function v(e,t,i,s){let r=t.rgba>>>24,o=t.rgba>>>16&255,a=t.rgba>>>8&255,n=Math.floor((Math.abs(r-(i.rgba>>>24))+Math.abs(o-(i.rgba>>>16&255))+Math.abs(a-(i.rgba>>>8&255)))/12),h=!0;for(let t=0;t<e.data.length;t+=4)e.data[t]===r&&e.data[t+1]===o&&e.data[t+2]===a||s&&Math.abs(e.data[t]-r)+Math.abs(e.data[t+1]-o)+Math.abs(e.data[t+2]-a)<n?e.data[t+3]=0:h=!1;return h}function x(e,t,i){let s=e.createElement("canvas");return s.width=t,s.height=i,s}},160:(e,t)=>{var i,s,r,o,a;Object.defineProperty(t,"__esModule",{value:!0}),t.contrastRatio=t.toPaddedHex=t.rgba=t.rgb=t.css=t.color=t.channels=t.NULL_COLOR=void 0;let n=0,h=0,l=0,c=0;function d(e){let t=e.toString(16);return t.length<2?"0"+t:t}function _(e,t){return e<t?(t+.05)/(e+.05):(e+.05)/(t+.05)}t.NULL_COLOR={css:"#00000000",rgba:0},function(e){e.toCss=function(e,t,i,s){return void 0!==s?`#${d(e)}${d(t)}${d(i)}${d(s)}`:`#${d(e)}${d(t)}${d(i)}`},e.toRgba=function(e,t,i,s=255){return(e<<24|t<<16|i<<8|s)>>>0},e.toColor=function(t,i,s,r){return{css:e.toCss(t,i,s,r),rgba:e.toRgba(t,i,s,r)}}}(i||(t.channels=i={})),function(e){function t(e,t){return c=Math.round(255*t),[n,h,l]=a.toChannels(e.rgba),{css:i.toCss(n,h,l,c),rgba:i.toRgba(n,h,l,c)}}e.blend=function(e,t){if(1==(c=(255&t.rgba)/255))return{css:t.css,rgba:t.rgba};let s=t.rgba>>24&255,r=t.rgba>>16&255,o=t.rgba>>8&255,a=e.rgba>>24&255,d=e.rgba>>16&255,_=e.rgba>>8&255;return n=a+Math.round((s-a)*c),h=d+Math.round((r-d)*c),l=_+Math.round((o-_)*c),{css:i.toCss(n,h,l),rgba:i.toRgba(n,h,l)}},e.isOpaque=function(e){return 255==(255&e.rgba)},e.ensureContrastRatio=function(e,t,s){let r=a.ensureContrastRatio(e.rgba,t.rgba,s);if(r)return i.toColor(r>>24&255,r>>16&255,r>>8&255)},e.opaque=function(e){let t=(255|e.rgba)>>>0;return[n,h,l]=a.toChannels(t),{css:i.toCss(n,h,l),rgba:t}},e.opacity=t,e.multiplyOpacity=function(e,i){return c=255&e.rgba,t(e,c*i/255)},e.toColorRGB=function(e){return[e.rgba>>24&255,e.rgba>>16&255,e.rgba>>8&255]}}(s||(t.color=s={})),function(e){let t,s;try{let e=document.createElement("canvas");e.width=1,e.height=1;let i=e.getContext("2d",{willReadFrequently:!0});i&&((t=i).globalCompositeOperation="copy",s=t.createLinearGradient(0,0,1,1))}catch{}e.toColor=function(e){if(e.match(/#[\da-f]{3,8}/i))switch(e.length){case 4:return n=parseInt(e.slice(1,2).repeat(2),16),h=parseInt(e.slice(2,3).repeat(2),16),l=parseInt(e.slice(3,4).repeat(2),16),i.toColor(n,h,l);case 5:return n=parseInt(e.slice(1,2).repeat(2),16),h=parseInt(e.slice(2,3).repeat(2),16),l=parseInt(e.slice(3,4).repeat(2),16),c=parseInt(e.slice(4,5).repeat(2),16),i.toColor(n,h,l,c);case 7:return{css:e,rgba:(parseInt(e.slice(1),16)<<8|255)>>>0};case 9:return{css:e,rgba:parseInt(e.slice(1),16)>>>0}}let r=e.match(/rgba?\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*(,\s*(0|1|\d?\.(\d+))\s*)?\)/);if(r)return n=parseInt(r[1]),h=parseInt(r[2]),l=parseInt(r[3]),c=Math.round(255*(void 0===r[5]?1:parseFloat(r[5]))),i.toColor(n,h,l,c);if(!t||!s||(t.fillStyle=s,t.fillStyle=e,"string"!=typeof t.fillStyle)||(t.fillRect(0,0,1,1),[n,h,l,c]=t.getImageData(0,0,1,1).data,255!==c))throw Error("css.toColor: Unsupported css format");return{rgba:i.toRgba(n,h,l,c),css:e}}}(r||(t.css=r={})),function(e){function t(e,t,i){let s=e/255,r=t/255,o=i/255;return .2126*(s<=.03928?s/12.92:Math.pow((s+.055)/1.055,2.4))+.7152*(r<=.03928?r/12.92:Math.pow((r+.055)/1.055,2.4))+.0722*(o<=.03928?o/12.92:Math.pow((o+.055)/1.055,2.4))}e.relativeLuminance=function(e){return t(e>>16&255,e>>8&255,255&e)},e.relativeLuminance2=t}(o||(t.rgb=o={})),function(e){function t(e,t,i){let s=e>>24&255,r=e>>16&255,a=e>>8&255,n=t>>24&255,h=t>>16&255,l=t>>8&255,c=_(o.relativeLuminance2(n,h,l),o.relativeLuminance2(s,r,a));for(;c<i&&(n>0||h>0||l>0);)n-=Math.max(0,Math.ceil(.1*n)),h-=Math.max(0,Math.ceil(.1*h)),l-=Math.max(0,Math.ceil(.1*l)),c=_(o.relativeLuminance2(n,h,l),o.relativeLuminance2(s,r,a));return(n<<24|h<<16|l<<8|255)>>>0}function s(e,t,i){let s=e>>24&255,r=e>>16&255,a=e>>8&255,n=t>>24&255,h=t>>16&255,l=t>>8&255,c=_(o.relativeLuminance2(n,h,l),o.relativeLuminance2(s,r,a));for(;c<i&&(n<255||h<255||l<255);)n=Math.min(255,n+Math.ceil(.1*(255-n))),h=Math.min(255,h+Math.ceil(.1*(255-h))),l=Math.min(255,l+Math.ceil(.1*(255-l))),c=_(o.relativeLuminance2(n,h,l),o.relativeLuminance2(s,r,a));return(n<<24|h<<16|l<<8|255)>>>0}e.blend=function(e,t){if(1==(c=(255&t)/255))return t;let s=e>>24&255,r=e>>16&255,o=e>>8&255;return n=s+Math.round(((t>>24&255)-s)*c),h=r+Math.round(((t>>16&255)-r)*c),l=o+Math.round(((t>>8&255)-o)*c),i.toRgba(n,h,l)},e.ensureContrastRatio=function(e,i,r){let a=o.relativeLuminance(e>>8),n=o.relativeLuminance(i>>8);if(_(a,n)<r){if(n<a){let n=t(e,i,r),h=_(a,o.relativeLuminance(n>>8));if(h<r){let t=s(e,i,r);return h>_(a,o.relativeLuminance(t>>8))?n:t}return n}let h=s(e,i,r),l=_(a,o.relativeLuminance(h>>8));if(l<r){let s=t(e,i,r);return l>_(a,o.relativeLuminance(s>>8))?h:s}return h}},e.reduceLuminance=t,e.increaseLuminance=s,e.toChannels=function(e){return[e>>24&255,e>>16&255,e>>8&255,255&e]}}(a||(t.rgba=a={})),t.toPaddedHex=d,t.contrastRatio=_},345:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.runAndSubscribe=t.forwardEvent=t.EventEmitter=void 0,t.EventEmitter=class{constructor(){this._listeners=[],this._disposed=!1}get event(){return this._event||(this._event=e=>(this._listeners.push(e),{dispose:()=>{if(!this._disposed){for(let t=0;t<this._listeners.length;t++)if(this._listeners[t]===e)return void this._listeners.splice(t,1)}}})),this._event}fire(e,t){let i=[];for(let e=0;e<this._listeners.length;e++)i.push(this._listeners[e]);for(let s=0;s<i.length;s++)i[s].call(void 0,e,t)}dispose(){this.clearListeners(),this._disposed=!0}clearListeners(){this._listeners&&(this._listeners.length=0)}},t.forwardEvent=function(e,t){return e(e=>t.fire(e))},t.runAndSubscribe=function(e,t){return t(void 0),e(e=>t(e))}},859:(e,t)=>{function i(e){for(let t of e)t.dispose();e.length=0}Object.defineProperty(t,"__esModule",{value:!0}),t.getDisposeArrayDisposable=t.disposeArray=t.toDisposable=t.MutableDisposable=t.Disposable=void 0,t.Disposable=class{constructor(){this._disposables=[],this._isDisposed=!1}dispose(){for(let e of(this._isDisposed=!0,this._disposables))e.dispose();this._disposables.length=0}register(e){return this._disposables.push(e),e}unregister(e){let t=this._disposables.indexOf(e);-1!==t&&this._disposables.splice(t,1)}},t.MutableDisposable=class{constructor(){this._isDisposed=!1}get value(){return this._isDisposed?void 0:this._value}set value(e){this._isDisposed||e===this._value||(this._value?.dispose(),this._value=e)}clear(){this.value=void 0}dispose(){this._isDisposed=!0,this._value?.dispose(),this._value=void 0}},t.toDisposable=function(e){return{dispose:e}},t.disposeArray=i,t.getDisposeArrayDisposable=function(e){return{dispose:()=>i(e)}}},485:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.FourKeyMap=t.TwoKeyMap=void 0;class i{constructor(){this._data={}}set(e,t,i){this._data[e]||(this._data[e]={}),this._data[e][t]=i}get(e,t){return this._data[e]?this._data[e][t]:void 0}clear(){this._data={}}}t.TwoKeyMap=i,t.FourKeyMap=class{constructor(){this._data=new i}set(e,t,s,r,o){this._data.get(e,t)||this._data.set(e,t,new i),this._data.get(e,t).set(s,r,o)}get(e,t,i,s){return this._data.get(e,t)?.get(i,s)}clear(){this._data.clear()}}},399:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.isChromeOS=t.isLinux=t.isWindows=t.isIphone=t.isIpad=t.isMac=t.getSafariVersion=t.isSafari=t.isLegacyEdge=t.isFirefox=t.isNode=void 0,t.isNode=void 0!==s&&"title"in s;let i=t.isNode?"node":navigator.userAgent,r=t.isNode?"node":navigator.platform;t.isFirefox=i.includes("Firefox"),t.isLegacyEdge=i.includes("Edge"),t.isSafari=/^((?!chrome|android).)*safari/i.test(i),t.getSafariVersion=function(){if(!t.isSafari)return 0;let e=i.match(/Version\/(\d+)/);return null===e||e.length<2?0:parseInt(e[1])},t.isMac=["Macintosh","MacIntel","MacPPC","Mac68K"].includes(r),t.isIpad="iPad"===r,t.isIphone="iPhone"===r,t.isWindows=["Windows","Win16","Win32","WinCE"].includes(r),t.isLinux=r.indexOf("Linux")>=0,t.isChromeOS=/\bCrOS\b/.test(i)},385:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.DebouncedIdleTask=t.IdleTaskQueue=t.PriorityTaskQueue=void 0;let s=i(399);class r{constructor(){this._tasks=[],this._i=0}enqueue(e){this._tasks.push(e),this._start()}flush(){for(;this._i<this._tasks.length;)this._tasks[this._i]()||this._i++;this.clear()}clear(){this._idleCallback&&(this._cancelCallback(this._idleCallback),this._idleCallback=void 0),this._i=0,this._tasks.length=0}_start(){this._idleCallback||(this._idleCallback=this._requestCallback(this._process.bind(this)))}_process(e){this._idleCallback=void 0;let t=0,i=0,s=e.timeRemaining(),r=0;for(;this._i<this._tasks.length;){if(t=Date.now(),this._tasks[this._i]()||this._i++,1.5*(i=Math.max(t=Math.max(1,Date.now()-t),i))>(r=e.timeRemaining()))return s-t<-20&&console.warn(`task queue exceeded allotted deadline by ${Math.abs(Math.round(s-t))}ms`),void this._start();s=r}this.clear()}}class o extends r{_requestCallback(e){return setTimeout(()=>e(this._createDeadline(16)))}_cancelCallback(e){clearTimeout(e)}_createDeadline(e){let t=Date.now()+e;return{timeRemaining:()=>Math.max(0,t-Date.now())}}}t.PriorityTaskQueue=o,t.IdleTaskQueue=!s.isNode&&"requestIdleCallback"in window?class extends r{_requestCallback(e){return requestIdleCallback(e)}_cancelCallback(e){cancelIdleCallback(e)}}:o,t.DebouncedIdleTask=class{constructor(){this._queue=new t.IdleTaskQueue}set(e){this._queue.clear(),this._queue.enqueue(e)}flush(){this._queue.flush()}}},147:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ExtendedAttrs=t.AttributeData=void 0;class i{constructor(){this.fg=0,this.bg=0,this.extended=new s}static toColorRGB(e){return[e>>>16&255,e>>>8&255,255&e]}static fromColorRGB(e){return(255&e[0])<<16|(255&e[1])<<8|255&e[2]}clone(){let e=new i;return e.fg=this.fg,e.bg=this.bg,e.extended=this.extended.clone(),e}isInverse(){return 0x4000000&this.fg}isBold(){return 0x8000000&this.fg}isUnderline(){return this.hasExtendedAttrs()&&0!==this.extended.underlineStyle?1:0x10000000&this.fg}isBlink(){return 0x20000000&this.fg}isInvisible(){return 0x40000000&this.fg}isItalic(){return 0x4000000&this.bg}isDim(){return 0x8000000&this.bg}isStrikethrough(){return 0x80000000&this.fg}isProtected(){return 0x20000000&this.bg}isOverline(){return 0x40000000&this.bg}getFgColorMode(){return 0x3000000&this.fg}getBgColorMode(){return 0x3000000&this.bg}isFgRGB(){return 0x3000000==(0x3000000&this.fg)}isBgRGB(){return 0x3000000==(0x3000000&this.bg)}isFgPalette(){return 0x1000000==(0x3000000&this.fg)||0x2000000==(0x3000000&this.fg)}isBgPalette(){return 0x1000000==(0x3000000&this.bg)||0x2000000==(0x3000000&this.bg)}isFgDefault(){return 0==(0x3000000&this.fg)}isBgDefault(){return 0==(0x3000000&this.bg)}isAttributeDefault(){return 0===this.fg&&0===this.bg}getFgColor(){switch(0x3000000&this.fg){case 0x1000000:case 0x2000000:return 255&this.fg;case 0x3000000:return 0xffffff&this.fg;default:return -1}}getBgColor(){switch(0x3000000&this.bg){case 0x1000000:case 0x2000000:return 255&this.bg;case 0x3000000:return 0xffffff&this.bg;default:return -1}}hasExtendedAttrs(){return 0x10000000&this.bg}updateExtended(){this.extended.isEmpty()?this.bg&=-0x10000001:this.bg|=0x10000000}getUnderlineColor(){if(0x10000000&this.bg&&~this.extended.underlineColor)switch(0x3000000&this.extended.underlineColor){case 0x1000000:case 0x2000000:return 255&this.extended.underlineColor;case 0x3000000:return 0xffffff&this.extended.underlineColor}return this.getFgColor()}getUnderlineColorMode(){return 0x10000000&this.bg&&~this.extended.underlineColor?0x3000000&this.extended.underlineColor:this.getFgColorMode()}isUnderlineColorRGB(){return 0x10000000&this.bg&&~this.extended.underlineColor?0x3000000==(0x3000000&this.extended.underlineColor):this.isFgRGB()}isUnderlineColorPalette(){return 0x10000000&this.bg&&~this.extended.underlineColor?0x1000000==(0x3000000&this.extended.underlineColor)||0x2000000==(0x3000000&this.extended.underlineColor):this.isFgPalette()}isUnderlineColorDefault(){return 0x10000000&this.bg&&~this.extended.underlineColor?0==(0x3000000&this.extended.underlineColor):this.isFgDefault()}getUnderlineStyle(){return 0x10000000&this.fg?0x10000000&this.bg?this.extended.underlineStyle:1:0}getUnderlineVariantOffset(){return this.extended.underlineVariantOffset}}t.AttributeData=i;class s{get ext(){return this._urlId?-0x1c000001&this._ext|this.underlineStyle<<26:this._ext}set ext(e){this._ext=e}get underlineStyle(){return this._urlId?5:(0x1c000000&this._ext)>>26}set underlineStyle(e){this._ext&=-0x1c000001,this._ext|=e<<26&0x1c000000}get underlineColor(){return 0x3ffffff&this._ext}set underlineColor(e){this._ext&=-0x4000000,this._ext|=0x3ffffff&e}get urlId(){return this._urlId}set urlId(e){this._urlId=e}get underlineVariantOffset(){let e=(0xe0000000&this._ext)>>29;return e<0?0xfffffff8^e:e}set underlineVariantOffset(e){this._ext&=0x1fffffff,this._ext|=e<<29&0xe0000000}constructor(e=0,t=0){this._ext=0,this._urlId=0,this._ext=e,this._urlId=t}clone(){return new s(this._ext,this._urlId)}isEmpty(){return 0===this.underlineStyle&&0===this._urlId}}t.ExtendedAttrs=s},782:(e,t,i)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CellData=void 0;let s=i(133),r=i(855),o=i(147);class a extends o.AttributeData{constructor(){super(...arguments),this.content=0,this.fg=0,this.bg=0,this.extended=new o.ExtendedAttrs,this.combinedData=""}static fromCharData(e){let t=new a;return t.setFromCharData(e),t}isCombined(){return 2097152&this.content}getWidth(){return this.content>>22}getChars(){return 2097152&this.content?this.combinedData:2097151&this.content?(0,s.stringFromCodePoint)(2097151&this.content):""}getCode(){return this.isCombined()?this.combinedData.charCodeAt(this.combinedData.length-1):2097151&this.content}setFromCharData(e){this.fg=e[r.CHAR_DATA_ATTR_INDEX],this.bg=0;let t=!1;if(e[r.CHAR_DATA_CHAR_INDEX].length>2)t=!0;else if(2===e[r.CHAR_DATA_CHAR_INDEX].length){let i=e[r.CHAR_DATA_CHAR_INDEX].charCodeAt(0);if(55296<=i&&i<=56319){let s=e[r.CHAR_DATA_CHAR_INDEX].charCodeAt(1);56320<=s&&s<=57343?this.content=1024*(i-55296)+s-56320+65536|e[r.CHAR_DATA_WIDTH_INDEX]<<22:t=!0}else t=!0}else this.content=e[r.CHAR_DATA_CHAR_INDEX].charCodeAt(0)|e[r.CHAR_DATA_WIDTH_INDEX]<<22;t&&(this.combinedData=e[r.CHAR_DATA_CHAR_INDEX],this.content=2097152|e[r.CHAR_DATA_WIDTH_INDEX]<<22)}getAsCharData(){return[this.fg,this.getChars(),this.getWidth(),this.getCode()]}}t.CellData=a},855:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.WHITESPACE_CELL_CODE=t.WHITESPACE_CELL_WIDTH=t.WHITESPACE_CELL_CHAR=t.NULL_CELL_CODE=t.NULL_CELL_WIDTH=t.NULL_CELL_CHAR=t.CHAR_DATA_CODE_INDEX=t.CHAR_DATA_WIDTH_INDEX=t.CHAR_DATA_CHAR_INDEX=t.CHAR_DATA_ATTR_INDEX=t.DEFAULT_EXT=t.DEFAULT_ATTR=t.DEFAULT_COLOR=void 0,t.DEFAULT_COLOR=0,t.DEFAULT_ATTR=256|t.DEFAULT_COLOR<<9,t.DEFAULT_EXT=0,t.CHAR_DATA_ATTR_INDEX=0,t.CHAR_DATA_CHAR_INDEX=1,t.CHAR_DATA_WIDTH_INDEX=2,t.CHAR_DATA_CODE_INDEX=3,t.NULL_CELL_CHAR="",t.NULL_CELL_WIDTH=1,t.NULL_CELL_CODE=0,t.WHITESPACE_CELL_CHAR=" ",t.WHITESPACE_CELL_WIDTH=1,t.WHITESPACE_CELL_CODE=32},133:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.Utf8ToUtf32=t.StringToUtf32=t.utf32ToString=t.stringFromCodePoint=void 0,t.stringFromCodePoint=function(e){return e>65535?String.fromCharCode(55296+((e-=65536)>>10))+String.fromCharCode(e%1024+56320):String.fromCharCode(e)},t.utf32ToString=function(e,t=0,i=e.length){let s="";for(let r=t;r<i;++r){let t=e[r];t>65535?(t-=65536,s+=String.fromCharCode(55296+(t>>10))+String.fromCharCode(t%1024+56320)):s+=String.fromCharCode(t)}return s},t.StringToUtf32=class{constructor(){this._interim=0}clear(){this._interim=0}decode(e,t){let i=e.length;if(!i)return 0;let s=0,r=0;if(this._interim){let i=e.charCodeAt(r++);56320<=i&&i<=57343?t[s++]=1024*(this._interim-55296)+i-56320+65536:(t[s++]=this._interim,t[s++]=i),this._interim=0}for(let o=r;o<i;++o){let r=e.charCodeAt(o);if(55296<=r&&r<=56319){if(++o>=i)return this._interim=r,s;let a=e.charCodeAt(o);56320<=a&&a<=57343?t[s++]=1024*(r-55296)+a-56320+65536:(t[s++]=r,t[s++]=a)}else 65279!==r&&(t[s++]=r)}return s}},t.Utf8ToUtf32=class{constructor(){this.interim=new Uint8Array(3)}clear(){this.interim.fill(0)}decode(e,t){let i=e.length;if(!i)return 0;let s,r,o,a,n=0,h=0,l=0;if(this.interim[0]){let s=!1,r=this.interim[0];r&=192==(224&r)?31:224==(240&r)?15:7;let o,a=0;for(;(o=63&this.interim[++a])&&a<4;)r<<=6,r|=o;let h=192==(224&this.interim[0])?2:224==(240&this.interim[0])?3:4,c=h-a;for(;l<c;){if(l>=i)return 0;if(128!=(192&(o=e[l++]))){l--,s=!0;break}this.interim[a++]=o,r<<=6,r|=63&o}s||(2===h?r<128?l--:t[n++]=r:3===h?r<2048||r>=55296&&r<=57343||65279===r||(t[n++]=r):r<65536||r>1114111||(t[n++]=r)),this.interim.fill(0)}let c=i-4,d=l;for(;d<i;){for(;!(!(d<c)||128&(s=e[d])||128&(r=e[d+1])||128&(o=e[d+2])||128&(a=e[d+3]));)t[n++]=s,t[n++]=r,t[n++]=o,t[n++]=a,d+=4;if((s=e[d++])<128)t[n++]=s;else if(192==(224&s)){if(d>=i)return this.interim[0]=s,n;if(128!=(192&(r=e[d++]))||(h=(31&s)<<6|63&r)<128){d--;continue}t[n++]=h}else if(224==(240&s)){if(d>=i)return this.interim[0]=s,n;if(128!=(192&(r=e[d++]))){d--;continue}if(d>=i)return this.interim[0]=s,this.interim[1]=r,n;if(128!=(192&(o=e[d++]))){d--;continue}if((h=(15&s)<<12|(63&r)<<6|63&o)<2048||h>=55296&&h<=57343||65279===h)continue;t[n++]=h}else if(240==(248&s)){if(d>=i)return this.interim[0]=s,n;if(128!=(192&(r=e[d++]))){d--;continue}if(d>=i)return this.interim[0]=s,this.interim[1]=r,n;if(128!=(192&(o=e[d++]))){d--;continue}if(d>=i)return this.interim[0]=s,this.interim[1]=r,this.interim[2]=o,n;if(128!=(192&(a=e[d++]))){d--;continue}if((h=(7&s)<<18|(63&r)<<12|(63&o)<<6|63&a)<65536||h>1114111)continue;t[n++]=h}}return n}}},776:function(e,t,i){var s=this&&this.__decorate||function(e,t,i,s){var r,o=arguments.length,a=o<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,s);else for(var n=e.length-1;n>=0;n--)(r=e[n])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a},r=this&&this.__param||function(e,t){return function(i,s){t(i,s,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.traceCall=t.setTraceLogger=t.LogService=void 0;let o=i(859),a=i(97),n={trace:a.LogLevelEnum.TRACE,debug:a.LogLevelEnum.DEBUG,info:a.LogLevelEnum.INFO,warn:a.LogLevelEnum.WARN,error:a.LogLevelEnum.ERROR,off:a.LogLevelEnum.OFF},h,l=t.LogService=class extends o.Disposable{get logLevel(){return this._logLevel}constructor(e){super(),this._optionsService=e,this._logLevel=a.LogLevelEnum.OFF,this._updateLogLevel(),this.register(this._optionsService.onSpecificOptionChange("logLevel",()=>this._updateLogLevel())),h=this}_updateLogLevel(){this._logLevel=n[this._optionsService.rawOptions.logLevel]}_evalLazyOptionalParams(e){for(let t=0;t<e.length;t++)"function"==typeof e[t]&&(e[t]=e[t]())}_log(e,t,i){this._evalLazyOptionalParams(i),e.call(console,(this._optionsService.options.logger?"":"xterm.js: ")+t,...i)}trace(e,...t){this._logLevel<=a.LogLevelEnum.TRACE&&this._log(this._optionsService.options.logger?.trace.bind(this._optionsService.options.logger)??console.log,e,t)}debug(e,...t){this._logLevel<=a.LogLevelEnum.DEBUG&&this._log(this._optionsService.options.logger?.debug.bind(this._optionsService.options.logger)??console.log,e,t)}info(e,...t){this._logLevel<=a.LogLevelEnum.INFO&&this._log(this._optionsService.options.logger?.info.bind(this._optionsService.options.logger)??console.info,e,t)}warn(e,...t){this._logLevel<=a.LogLevelEnum.WARN&&this._log(this._optionsService.options.logger?.warn.bind(this._optionsService.options.logger)??console.warn,e,t)}error(e,...t){this._logLevel<=a.LogLevelEnum.ERROR&&this._log(this._optionsService.options.logger?.error.bind(this._optionsService.options.logger)??console.error,e,t)}};t.LogService=l=s([r(0,a.IOptionsService)],l),t.setTraceLogger=function(e){h=e},t.traceCall=function(e,t,i){if("function"!=typeof i.value)throw Error("not supported");let s=i.value;i.value=function(...e){if(h.logLevel!==a.LogLevelEnum.TRACE)return s.apply(this,e);h.trace(`GlyphRenderer#${s.name}(${e.map(e=>JSON.stringify(e)).join(", ")})`);let t=s.apply(this,e);return h.trace(`GlyphRenderer#${s.name} return`,t),t}}},726:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.createDecorator=t.getServiceDependencies=t.serviceRegistry=void 0;let i="di$target",s="di$dependencies";t.serviceRegistry=new Map,t.getServiceDependencies=function(e){return e[s]||[]},t.createDecorator=function(e){if(t.serviceRegistry.has(e))return t.serviceRegistry.get(e);let r=function(e,t,o){if(3!=arguments.length)throw Error("@IServiceName-decorator can only be used to decorate a parameter");e[i]===e?e[s].push({id:r,index:o}):(e[s]=[{id:r,index:o}],e[i]=e)};return r.toString=()=>e,t.serviceRegistry.set(e,r),r}},97:(e,t,i)=>{var s;Object.defineProperty(t,"__esModule",{value:!0}),t.IDecorationService=t.IUnicodeService=t.IOscLinkService=t.IOptionsService=t.ILogService=t.LogLevelEnum=t.IInstantiationService=t.ICharsetService=t.ICoreService=t.ICoreMouseService=t.IBufferService=void 0;let r=i(726);t.IBufferService=(0,r.createDecorator)("BufferService"),t.ICoreMouseService=(0,r.createDecorator)("CoreMouseService"),t.ICoreService=(0,r.createDecorator)("CoreService"),t.ICharsetService=(0,r.createDecorator)("CharsetService"),t.IInstantiationService=(0,r.createDecorator)("InstantiationService"),function(e){e[e.TRACE=0]="TRACE",e[e.DEBUG=1]="DEBUG",e[e.INFO=2]="INFO",e[e.WARN=3]="WARN",e[e.ERROR=4]="ERROR",e[e.OFF=5]="OFF"}(s||(t.LogLevelEnum=s={})),t.ILogService=(0,r.createDecorator)("LogService"),t.IOptionsService=(0,r.createDecorator)("OptionsService"),t.IOscLinkService=(0,r.createDecorator)("OscLinkService"),t.IUnicodeService=(0,r.createDecorator)("UnicodeService"),t.IDecorationService=(0,r.createDecorator)("DecorationService")}},t={};function i(s){var r=t[s];if(void 0!==r)return r.exports;var o=t[s]={exports:{}};return e[s].call(o.exports,o,o.exports,i),o.exports}var r={};return(()=>{Object.defineProperty(r,"__esModule",{value:!0}),r.WebglAddon=void 0;let e=i(345),t=i(859),s=i(399),o=i(666),a=i(776);class n extends t.Disposable{constructor(t){if(s.isSafari&&16>(0,s.getSafariVersion)()&&!document.createElement("canvas").getContext("webgl2",{antialias:!1,depth:!1,preserveDrawingBuffer:!0}))throw Error("Webgl2 is only supported on Safari 16 and above");super(),this._preserveDrawingBuffer=t,this._onChangeTextureAtlas=this.register(new e.EventEmitter),this.onChangeTextureAtlas=this._onChangeTextureAtlas.event,this._onAddTextureAtlasCanvas=this.register(new e.EventEmitter),this.onAddTextureAtlasCanvas=this._onAddTextureAtlasCanvas.event,this._onRemoveTextureAtlasCanvas=this.register(new e.EventEmitter),this.onRemoveTextureAtlasCanvas=this._onRemoveTextureAtlasCanvas.event,this._onContextLoss=this.register(new e.EventEmitter),this.onContextLoss=this._onContextLoss.event}activate(i){let s=i._core;if(!i.element)return void this.register(s.onWillOpen(()=>this.activate(i)));this._terminal=i;let r=s.coreService,n=s.optionsService,h=s._renderService,l=s._characterJoinerService,c=s._charSizeService,d=s._coreBrowserService,_=s._decorationService,u=s._logService,g=s._themeService;(0,a.setTraceLogger)(u),this._renderer=this.register(new o.WebglRenderer(i,l,c,d,r,_,n,g,this._preserveDrawingBuffer)),this.register((0,e.forwardEvent)(this._renderer.onContextLoss,this._onContextLoss)),this.register((0,e.forwardEvent)(this._renderer.onChangeTextureAtlas,this._onChangeTextureAtlas)),this.register((0,e.forwardEvent)(this._renderer.onAddTextureAtlasCanvas,this._onAddTextureAtlasCanvas)),this.register((0,e.forwardEvent)(this._renderer.onRemoveTextureAtlasCanvas,this._onRemoveTextureAtlasCanvas)),h.setRenderer(this._renderer),this.register((0,t.toDisposable)(()=>{let e=this._terminal._core._renderService;e.setRenderer(this._terminal._core._createRenderer()),e.handleResize(i.cols,i.rows)}))}get textureAtlas(){return this._renderer?.textureAtlas}clearTextureAtlas(){this._renderer?.clearTextureAtlas()}}r.WebglAddon=n})(),r})()}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[440],{12509:(e,o,l)=>{l.d(o,{w:()=>n});let n=(0,l(7620).createContext)(null);n.displayName="@mantine/modals/ModalsContext"},17670:(e,o,l)=>{l.d(o,{Y:()=>P});var n=l(54568),t=l(7620),r=l(24547),a=l(3492),d=l(39589),c=l(30602),s=l(97628),u=l(24249),i=l(95075);function p(e){let{id:o,cancelProps:l,confirmProps:t,labels:r={cancel:"",confirm:""},closeOnConfirm:a=!0,closeOnCancel:d=!0,groupProps:p,onCancel:m,onConfirm:f,children:C}=e,{cancel:x,confirm:P}=r,y=(0,i.U)();return(0,n.jsxs)(n.Fragment,{children:[C&&(0,n.jsx)(c.Box,{mb:"md",children:C}),(0,n.jsxs)(s.Group,{mt:C?0:"md",justify:"flex-end",...p,children:[(0,n.jsx)(u.Button,{variant:"default",...l,onClick:e=>{"function"==typeof(null==l?void 0:l.onClick)&&(null==l||l.onClick(e)),"function"==typeof m&&m(),d&&y.closeModal(o)},children:(null==l?void 0:l.children)||x}),(0,n.jsx)(u.Button,{...t,onClick:e=>{"function"==typeof(null==t?void 0:t.onClick)&&(null==t||t.onClick(e)),"function"==typeof f&&f(),a&&y.closeModal(o)},children:(null==t?void 0:t.children)||P})]})]})}var m=l(12509),f=l(42625);function C(e,o){var l,n,t,r;o&&"confirm"===e.type&&(null==(t=(r=e.props).onCancel)||t.call(r)),null==(l=(n=e.props).onClose)||l.call(n)}function x(e,o){switch(o.type){case"OPEN":return{current:o.modal,modals:[...e.modals,o.modal]};case"CLOSE":{let l=e.modals.find(e=>e.id===o.modalId);if(!l)return e;C(l,o.canceled);let n=e.modals.filter(e=>e.id!==o.modalId);return{current:n[n.length-1]||e.current,modals:n}}case"CLOSE_ALL":if(!e.modals.length)return e;return e.modals.concat().reverse().forEach(e=>{C(e,o.canceled)}),{current:e.current,modals:[]};case"UPDATE":{var l;let{modalId:n,newProps:t}=o,r=e.modals.map(e=>e.id!==n?e:"content"===e.type||"confirm"===e.type?{...e,props:{...e.props,...t}}:"context"===e.type?{...e,props:{...e.props,...t,innerProps:{...e.props.innerProps,...t.innerProps}}}:e),a=(null==(l=e.current)?void 0:l.id)===n&&r.find(e=>e.id===n)||e.current;return{...e,modals:r,current:a}}default:return e}}function P(e){let{children:o,modalProps:l,labels:c,modals:s}=e,[u,i]=(0,t.useReducer)(x,{modals:[],current:null}),C=(0,t.useRef)(u);C.current=u;let P=(0,t.useCallback)(e=>{i({type:"CLOSE_ALL",canceled:e})},[C,i]),y=(0,t.useCallback)(e=>{let{modalId:o,...l}=e,n=o||(0,d.randomId)();return i({type:"OPEN",modal:{id:n,type:"content",props:l}}),n},[i]),h=(0,t.useCallback)(e=>{let{modalId:o,...l}=e,n=o||(0,d.randomId)();return i({type:"OPEN",modal:{id:n,type:"confirm",props:l}}),n},[i]),v=(0,t.useCallback)((e,o)=>{let{modalId:l,...n}=o,t=l||(0,d.randomId)();return i({type:"OPEN",modal:{id:t,type:"context",props:n,ctx:e}}),t},[i]),M=(0,t.useCallback)((e,o)=>{i({type:"CLOSE",modalId:e,canceled:o})},[C,i]),k=(0,t.useCallback)(e=>{let{modalId:o,...l}=e;i({type:"UPDATE",modalId:o,newProps:l})},[i]),E=(0,t.useCallback)(e=>{let{modalId:o,...l}=e;i({type:"UPDATE",modalId:o,newProps:l})},[i]);(0,f.Fj)({openModal:y,openConfirmModal:h,openContextModal:e=>{let{modal:o,...l}=e;return v(o,l)},closeModal:M,closeContextModal:M,closeAllModals:P,updateModal:k,updateContextModal:E});let b={modalProps:l||{},modals:u.modals,openModal:y,openConfirmModal:h,openContextModal:v,closeModal:M,closeContextModal:M,closeAll:P,updateModal:k,updateContextModal:E},{modalProps:j,content:w}=(()=>{let e=C.current.current;switch(null==e?void 0:e.type){case"context":{let{innerProps:o,...l}=e.props,t=s[e.ctx];return{modalProps:l,content:(0,n.jsx)(t,{innerProps:o,context:b,id:e.id})}}case"confirm":{let{modalProps:o,confirmProps:l}=function(e){if(!e)return{confirmProps:{},modalProps:{}};let{id:o,children:l,onCancel:n,onConfirm:t,closeOnConfirm:r,closeOnCancel:a,cancelProps:d,confirmProps:c,groupProps:s,labels:u,...i}=e;return{confirmProps:{id:o,children:l,onCancel:n,onConfirm:t,closeOnConfirm:r,closeOnCancel:a,cancelProps:d,confirmProps:c,groupProps:s,labels:u},modalProps:{id:o,...i}}}(e.props);return{modalProps:o,content:(0,n.jsx)(p,{...l,id:e.id,labels:e.props.labels||c})}}case"content":{let{children:o,...l}=e.props;return{modalProps:l,content:o}}default:return{modalProps:{},content:null}}})();return(0,n.jsxs)(m.w.Provider,{value:b,children:[(0,n.jsx)(r.Modal,{zIndex:(0,a.getDefaultZIndex)("modal")+1,...l,...j,opened:u.modals.length>0,onClose:()=>{var e;return M(null==(e=u.current)?void 0:e.id)},children:w}),o]})}},75440:(e,o,l)=>{l.r(o),l.d(o,{ModalsProvider:()=>n.Y,closeAllModals:()=>r.s7,closeModal:()=>r.Oo,modals:()=>r.jQ,openConfirmModal:()=>r.GE,openContextModal:()=>r.n9,openModal:()=>r.qf,updateContextModal:()=>r.eQ,updateModal:()=>r.zb,useModals:()=>t.U});var n=l(17670),t=l(95075),r=l(42625)},95075:(e,o,l)=>{l.d(o,{U:()=>r});var n=l(7620),t=l(12509);function r(){let e=(0,n.useContext)(t.w);if(!e)throw Error("[@mantine/modals] useModals hook was called outside of context, wrap your app with ModalsProvider component");return e}}}]);
|