diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..f9c38f3 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,25 @@ +version: 2 +updates: + # --- NPM: security only ---- + - package-ecosystem: "npm" + directory: "/" + schedule: + interval: "weekly" + open-pull-requests-limit: 0 + groups: + npm-security: + applies-to: security-updates + patterns: [ "*" ] + labels: [ "security", "testing" ] + cooldown: + default-days: 7 + + - package-ecosystem: "github-actions" + directory: "/" + schedule: + interval: "weekly" + groups: + actions: + patterns: ["*"] + cooldown: + default-days: 7 diff --git a/.github/workflows/test-and-tag.yaml b/.github/workflows/test-and-tag.yaml index 2c8af95..e0945a2 100644 --- a/.github/workflows/test-and-tag.yaml +++ b/.github/workflows/test-and-tag.yaml @@ -1,4 +1,4 @@ -name: Build and Test +name: Build and Tag on: pull_request: paths-ignore: @@ -23,12 +23,8 @@ on: dry_run: description: 'If true, only calculate the new version and exit successfully.' required: false - type: boolean default: false -permissions: - contents: write - env: bump: ${{ github.event_name == 'pull_request' && 'none' || github.event_name == 'workflow_dispatch' && github.event.inputs.bump || 'patch' }} prerelease_version: ${{ github.event_name == 'pull_request' && format('pr{0}', github.event.number) || '' }} @@ -38,29 +34,56 @@ jobs: build: runs-on: ubuntu-latest container: node:24 + permissions: + contents: write + checks: write + pull-requests: write steps: - name: Checkout - uses: actions/checkout@12cd2235efa0937479335606d7c3ac9f6c0973b1 # v7 + uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 with: + ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.ref || github.ref }} fetch-depth: 0 - - - name: npm install - run: npm install - - - name: npm run build - run: npm run build - - - name: npm run test - run: npm run test || echo "Tests not yet implemented" + token: ${{ secrets.ACCESS_TOKEN_GITHUB }} + persist-credentials: true + + - name: Configure Git + run: | + git config --global user.email ${GITHUB_ACTOR}@users.noreply.github.com + git config --global user.name "github-actions[bot]" + git config --global --add safe.directory "$GITHUB_WORKSPACE" + + - name: Setup pnpm and Node.js + uses: pnpm/setup@84cb39b217b10273981911c288cd62326dc7c6d2 # v2.0.2 + + - name: pnpm install + run: pnpm install + + - name: pnpm run build + run: pnpm run build + + - name: pnpm run test + run: pnpm exec node --test --test-reporter=spec --test-reporter=junit --test-reporter-destination=stdout --test-reporter-destination=test-results.xml src/test.js + + - name: Publish Test Report + uses: mikepenz/action-junit-report@d9f48fc87bc235f7e214acf696ca5abc0a986f16 # v6.4.2 + if: ${{ !cancelled() }} + with: + report_paths: 'test-results.xml' + detailed_summary: true + include_passed: true + group_suite: true + resolve_ignore_classname: true + check_title_template: '{{TEST_NAME}}' + + - name: Remove Test Report + if: always() + run: rm -f test-results.xml - name: Commit and Push id: commit if: github.event_name == 'pull_request' run: | - git config --global user.email ${{ github.actor }}@users.noreply.github.com - git config --global user.name "github-actions[bot]" - git config --global --add safe.directory /__w/github-action-container-job/github-action-container-job - if [ -z "$(git status --porcelain)" ]; then echo "changed=0">> $GITHUB_OUTPUT echo "No changes" @@ -70,13 +93,14 @@ jobs: echo "changed=1">> $GITHUB_OUTPUT git add -A git commit -m "Build Release" - git push || echo "Push skipped (no permission or already up to date)" + git push - name: Generate Semantic Version - uses: enosix/github-action-generate-semver@4ab2e5251fb8c5b9b06eb65b22c0e25daba76311 # v4.0.1 + uses: enosix/github-action-generate-semver@0db52174578015a9471b9342427b97dc4e031cf2 # v5.0.0 with: github_token: ${{ secrets.GITHUB_TOKEN }} bump: ${{ env.bump }} prerelease_version: ${{ env.prerelease_version }} dry_run: ${{ env.dry_run }} + create_release: ${{ github.event_name == 'push' }} detect_bump: ${{ github.event_name == 'push' }} diff --git a/action.yml b/action.yml index efeb055..483f0c7 100644 --- a/action.yml +++ b/action.yml @@ -67,6 +67,10 @@ inputs: description: 'Preview payload and skip Azure calls' required: false default: 'false' + pull-logs: + description: 'Whether to pull logs from the job execution (true/false)' + required: false + default: 'false' log-analytics-workspace-id: description: 'Log Analytics Workspace ID for retrieving container logs' required: false @@ -78,6 +82,7 @@ outputs: runs: using: 'node24' main: 'dist/index.js' + post: 'dist/post.js/index.js' branding: icon: 'play' color: 'blue' diff --git a/dist/935.index.js b/dist/360.index.js similarity index 89% rename from dist/935.index.js rename to dist/360.index.js index 7c97223..3f2726b 100644 --- a/dist/935.index.js +++ b/dist/360.index.js @@ -1,8 +1,8 @@ -export const id = 935; -export const ids = [935]; +export const id = 360; +export const ids = [360]; export const modules = { -/***/ 36935: +/***/ 6360: /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => { // ESM COMPAT FLAG @@ -33,7 +33,7 @@ var promises_ = __webpack_require__(51455); var external_node_os_ = __webpack_require__(48161); // EXTERNAL MODULE: external "node:fs" var external_node_fs_ = __webpack_require__(73024); -;// CONCATENATED MODULE: ./node_modules/is-docker/index.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/is-docker@3.0.0/node_modules/is-docker/index.js let isDockerCached; @@ -64,7 +64,7 @@ function isDocker() { return isDockerCached; } -;// CONCATENATED MODULE: ./node_modules/is-inside-container/index.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/is-inside-container@1.0.0/node_modules/is-inside-container/index.js @@ -89,7 +89,7 @@ function isInsideContainer() { return cachedResult; } -;// CONCATENATED MODULE: ./node_modules/is-wsl/index.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/is-wsl@3.1.1/node_modules/is-wsl/index.js @@ -109,16 +109,25 @@ const isWsl = () => { } try { - return external_node_fs_.readFileSync('/proc/version', 'utf8').toLowerCase().includes('microsoft') - ? !isInsideContainer() : false; - } catch { - return false; + if (external_node_fs_.readFileSync('/proc/version', 'utf8').toLowerCase().includes('microsoft')) { + return !isInsideContainer(); + } + } catch {} + + // Fallback for custom kernels: check WSL-specific paths. + if ( + external_node_fs_.existsSync('/proc/sys/fs/binfmt_misc/WSLInterop') + || external_node_fs_.existsSync('/run/WSL') + ) { + return !isInsideContainer(); } + + return false; }; /* harmony default export */ const is_wsl = (external_node_process_.env.__IS_WSL_TEST__ ? isWsl : isWsl()); -;// CONCATENATED MODULE: ./node_modules/wsl-utils/index.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/wsl-utils@0.1.0/node_modules/wsl-utils/index.js @@ -177,7 +186,7 @@ const powerShellPath = async () => { -;// CONCATENATED MODULE: ./node_modules/define-lazy-prop/index.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/define-lazy-prop@3.0.0/node_modules/define-lazy-prop/index.js function defineLazyProperty(object, propertyName, valueGetter) { const define = value => Object.defineProperty(object, propertyName, {value, enumerable: true, writable: true}); @@ -197,7 +206,7 @@ function defineLazyProperty(object, propertyName, valueGetter) { return object; } -;// CONCATENATED MODULE: ./node_modules/default-browser-id/index.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/default-browser-id@5.0.1/node_modules/default-browser-id/index.js @@ -224,7 +233,7 @@ async function defaultBrowserId() { return browserId; } -;// CONCATENATED MODULE: ./node_modules/run-applescript/index.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/run-applescript@7.1.0/node_modules/run-applescript/index.js @@ -263,14 +272,14 @@ function runAppleScriptSync(script, {humanReadableOutput = true} = {}) { return stdout.trim(); } -;// CONCATENATED MODULE: ./node_modules/bundle-name/index.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/bundle-name@4.1.0/node_modules/bundle-name/index.js async function bundleName(bundleId) { return runAppleScript(`tell application "Finder" to set app_path to application file id "${bundleId}" as string\ntell application "System Events" to get value of property list item "CFBundleName" of property list file (app_path & ":Contents:Info.plist")`); } -;// CONCATENATED MODULE: ./node_modules/default-browser/windows.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/default-browser@5.5.0/node_modules/default-browser/windows.js @@ -318,15 +327,18 @@ async function defaultBrowser(_execFileAsync = windows_execFileAsync) { const {id} = match.groups; - const browser = windowsBrowserProgIds[id]; - if (!browser) { - throw new UnknownBrowserError(`Unknown browser ID: ${id}`); - } + // Windows can append a hash suffix to ProgIds using a dot or hyphen + // (e.g., `ChromeHTML.ABC123`, `FirefoxURL-6F193CCC56814779`). + // Try exact match first, then try without the suffix. + const dotIndex = id.lastIndexOf('.'); + const hyphenIndex = id.lastIndexOf('-'); + const baseIdByDot = dotIndex === -1 ? undefined : id.slice(0, dotIndex); + const baseIdByHyphen = hyphenIndex === -1 ? undefined : id.slice(0, hyphenIndex); - return browser; + return windowsBrowserProgIds[id] ?? windowsBrowserProgIds[baseIdByDot] ?? windowsBrowserProgIds[baseIdByHyphen] ?? {name: id, id}; } -;// CONCATENATED MODULE: ./node_modules/default-browser/index.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/default-browser@5.5.0/node_modules/default-browser/index.js @@ -362,7 +374,7 @@ async function default_browser_defaultBrowser() { throw new Error('Only macOS, Linux, and Windows are supported'); } -;// CONCATENATED MODULE: ./node_modules/open/index.js +;// CONCATENATED MODULE: ./node_modules/.pnpm/open@10.2.0/node_modules/open/index.js diff --git a/dist/index.js b/dist/index.js index 46460bb..63741c9 100644 --- a/dist/index.js +++ b/dist/index.js @@ -1,7 +1,7 @@ import { createRequire as __WEBPACK_EXTERNAL_createRequire } from "module"; /******/ var __webpack_modules__ = ({ -/***/ 89659: +/***/ 77708: /***/ (function(__unused_webpack_module, exports, __nccwpck_require__) { @@ -54,9 +54,9 @@ exports.getProxyUrl = getProxyUrl; exports.isHttps = isHttps; const http = __importStar(__nccwpck_require__(58611)); const https = __importStar(__nccwpck_require__(65692)); -const pm = __importStar(__nccwpck_require__(83335)); -const tunnel = __importStar(__nccwpck_require__(20770)); -const undici_1 = __nccwpck_require__(46752); +const pm = __importStar(__nccwpck_require__(48188)); +const tunnel = __importStar(__nccwpck_require__(30329)); +const undici_1 = __nccwpck_require__(51445); var HttpCodes; (function (HttpCodes) { HttpCodes[HttpCodes["OK"] = 200] = "OK"; @@ -744,7 +744,7 @@ const lowercaseKeys = (obj) => Object.keys(obj).reduce((c, k) => ((c[k.toLowerCa /***/ }), -/***/ 83335: +/***/ 48188: /***/ ((__unused_webpack_module, exports) => { @@ -844,7 +844,7 @@ class DecodedURL extends URL { /***/ }), -/***/ 37889: +/***/ 69113: /***/ (function(__unused_webpack_module, exports) { @@ -901,7 +901,7 @@ exports.ClientStreamingCall = ClientStreamingCall; /***/ }), -/***/ 71409: +/***/ 87961: /***/ ((__unused_webpack_module, exports) => { @@ -994,7 +994,7 @@ exports.Deferred = Deferred; /***/ }), -/***/ 36826: +/***/ 17090: /***/ (function(__unused_webpack_module, exports) { @@ -1050,7 +1050,7 @@ exports.DuplexStreamingCall = DuplexStreamingCall; /***/ }), -/***/ 44420: +/***/ 95980: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { var __webpack_unused_export__; @@ -1059,50 +1059,50 @@ var __webpack_unused_export__; // Note: we do not use `export * from ...` to help tree shakers, // webpack verbose output hints that this should be useful __webpack_unused_export__ = ({ value: true }); -var service_type_1 = __nccwpck_require__(56892); +var service_type_1 = __nccwpck_require__(31636); Object.defineProperty(exports, "C0", ({ enumerable: true, get: function () { return service_type_1.ServiceType; } })); -var reflection_info_1 = __nccwpck_require__(62496); +var reflection_info_1 = __nccwpck_require__(19768); __webpack_unused_export__ = ({ enumerable: true, get: function () { return reflection_info_1.readMethodOptions; } }); __webpack_unused_export__ = ({ enumerable: true, get: function () { return reflection_info_1.readMethodOption; } }); __webpack_unused_export__ = ({ enumerable: true, get: function () { return reflection_info_1.readServiceOption; } }); -var rpc_error_1 = __nccwpck_require__(78636); +var rpc_error_1 = __nccwpck_require__(15908); __webpack_unused_export__ = ({ enumerable: true, get: function () { return rpc_error_1.RpcError; } }); -var rpc_options_1 = __nccwpck_require__(28576); +var rpc_options_1 = __nccwpck_require__(91816); __webpack_unused_export__ = ({ enumerable: true, get: function () { return rpc_options_1.mergeRpcOptions; } }); -var rpc_output_stream_1 = __nccwpck_require__(72726); +var rpc_output_stream_1 = __nccwpck_require__(27374); __webpack_unused_export__ = ({ enumerable: true, get: function () { return rpc_output_stream_1.RpcOutputStreamController; } }); -var test_transport_1 = __nccwpck_require__(79122); +var test_transport_1 = __nccwpck_require__(28330); __webpack_unused_export__ = ({ enumerable: true, get: function () { return test_transport_1.TestTransport; } }); -var deferred_1 = __nccwpck_require__(71409); +var deferred_1 = __nccwpck_require__(87961); __webpack_unused_export__ = ({ enumerable: true, get: function () { return deferred_1.Deferred; } }); __webpack_unused_export__ = ({ enumerable: true, get: function () { return deferred_1.DeferredState; } }); -var duplex_streaming_call_1 = __nccwpck_require__(36826); +var duplex_streaming_call_1 = __nccwpck_require__(17090); __webpack_unused_export__ = ({ enumerable: true, get: function () { return duplex_streaming_call_1.DuplexStreamingCall; } }); -var client_streaming_call_1 = __nccwpck_require__(37889); +var client_streaming_call_1 = __nccwpck_require__(69113); __webpack_unused_export__ = ({ enumerable: true, get: function () { return client_streaming_call_1.ClientStreamingCall; } }); -var server_streaming_call_1 = __nccwpck_require__(46173); +var server_streaming_call_1 = __nccwpck_require__(12069); __webpack_unused_export__ = ({ enumerable: true, get: function () { return server_streaming_call_1.ServerStreamingCall; } }); -var unary_call_1 = __nccwpck_require__(29288); +var unary_call_1 = __nccwpck_require__(90368); __webpack_unused_export__ = ({ enumerable: true, get: function () { return unary_call_1.UnaryCall; } }); -var rpc_interceptor_1 = __nccwpck_require__(52849); +var rpc_interceptor_1 = __nccwpck_require__(86473); __webpack_unused_export__ = ({ enumerable: true, get: function () { return rpc_interceptor_1.stackIntercept; } }); __webpack_unused_export__ = ({ enumerable: true, get: function () { return rpc_interceptor_1.stackDuplexStreamingInterceptors; } }); __webpack_unused_export__ = ({ enumerable: true, get: function () { return rpc_interceptor_1.stackClientStreamingInterceptors; } }); __webpack_unused_export__ = ({ enumerable: true, get: function () { return rpc_interceptor_1.stackServerStreamingInterceptors; } }); __webpack_unused_export__ = ({ enumerable: true, get: function () { return rpc_interceptor_1.stackUnaryInterceptors; } }); -var server_call_context_1 = __nccwpck_require__(43352); +var server_call_context_1 = __nccwpck_require__(27072); __webpack_unused_export__ = ({ enumerable: true, get: function () { return server_call_context_1.ServerCallContextController; } }); /***/ }), -/***/ 62496: +/***/ 19768: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.readServiceOption = exports.readMethodOption = exports.readMethodOptions = exports.normalizeMethodInfo = void 0; -const runtime_1 = __nccwpck_require__(68886); +const runtime_1 = __nccwpck_require__(68140); /** * Turns PartialMethodInfo into MethodInfo. */ @@ -1160,7 +1160,7 @@ exports.readServiceOption = readServiceOption; /***/ }), -/***/ 78636: +/***/ 15908: /***/ ((__unused_webpack_module, exports) => { @@ -1203,13 +1203,13 @@ exports.RpcError = RpcError; /***/ }), -/***/ 52849: +/***/ 86473: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.stackDuplexStreamingInterceptors = exports.stackClientStreamingInterceptors = exports.stackServerStreamingInterceptors = exports.stackUnaryInterceptors = exports.stackIntercept = void 0; -const runtime_1 = __nccwpck_require__(68886); +const runtime_1 = __nccwpck_require__(68140); /** * Creates a "stack" of of all interceptors specified in the given `RpcOptions`. * Used by generated client implementations. @@ -1284,13 +1284,13 @@ exports.stackDuplexStreamingInterceptors = stackDuplexStreamingInterceptors; /***/ }), -/***/ 28576: +/***/ 91816: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.mergeRpcOptions = void 0; -const runtime_1 = __nccwpck_require__(68886); +const runtime_1 = __nccwpck_require__(68140); /** * Merges custom RPC options with defaults. Returns a new instance and keeps * the "defaults" and the "options" unmodified. @@ -1357,14 +1357,14 @@ function copy(a, into) { /***/ }), -/***/ 72726: +/***/ 27374: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.RpcOutputStreamController = void 0; -const deferred_1 = __nccwpck_require__(71409); -const runtime_1 = __nccwpck_require__(68886); +const deferred_1 = __nccwpck_require__(87961); +const runtime_1 = __nccwpck_require__(68140); /** * A `RpcOutputStream` that you control. */ @@ -1534,7 +1534,7 @@ exports.RpcOutputStreamController = RpcOutputStreamController; /***/ }), -/***/ 43352: +/***/ 27072: /***/ ((__unused_webpack_module, exports) => { @@ -1601,7 +1601,7 @@ exports.ServerCallContextController = ServerCallContextController; /***/ }), -/***/ 46173: +/***/ 12069: /***/ (function(__unused_webpack_module, exports) { @@ -1658,13 +1658,13 @@ exports.ServerStreamingCall = ServerStreamingCall; /***/ }), -/***/ 56892: +/***/ 31636: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.ServiceType = void 0; -const reflection_info_1 = __nccwpck_require__(62496); +const reflection_info_1 = __nccwpck_require__(19768); class ServiceType { constructor(typeName, methods, options) { this.typeName = typeName; @@ -1677,7 +1677,7 @@ exports.ServiceType = ServiceType; /***/ }), -/***/ 79122: +/***/ 28330: /***/ (function(__unused_webpack_module, exports, __nccwpck_require__) { @@ -1692,14 +1692,14 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge }; Object.defineProperty(exports, "__esModule", ({ value: true })); exports.TestTransport = void 0; -const rpc_error_1 = __nccwpck_require__(78636); -const runtime_1 = __nccwpck_require__(68886); -const rpc_output_stream_1 = __nccwpck_require__(72726); -const rpc_options_1 = __nccwpck_require__(28576); -const unary_call_1 = __nccwpck_require__(29288); -const server_streaming_call_1 = __nccwpck_require__(46173); -const client_streaming_call_1 = __nccwpck_require__(37889); -const duplex_streaming_call_1 = __nccwpck_require__(36826); +const rpc_error_1 = __nccwpck_require__(15908); +const runtime_1 = __nccwpck_require__(68140); +const rpc_output_stream_1 = __nccwpck_require__(27374); +const rpc_options_1 = __nccwpck_require__(91816); +const unary_call_1 = __nccwpck_require__(90368); +const server_streaming_call_1 = __nccwpck_require__(12069); +const client_streaming_call_1 = __nccwpck_require__(69113); +const duplex_streaming_call_1 = __nccwpck_require__(17090); /** * Transport for testing. */ @@ -2005,7 +2005,7 @@ class TestInputStream { /***/ }), -/***/ 29288: +/***/ 90368: /***/ (function(__unused_webpack_module, exports) { @@ -2061,7 +2061,7 @@ exports.UnaryCall = UnaryCall; /***/ }), -/***/ 8602: +/***/ 64828: /***/ ((__unused_webpack_module, exports) => { @@ -2111,7 +2111,7 @@ exports.assertFloat32 = assertFloat32; /***/ }), -/***/ 26335: +/***/ 20841: /***/ ((__unused_webpack_module, exports) => { @@ -2236,7 +2236,7 @@ exports.base64encode = base64encode; /***/ }), -/***/ 54816: +/***/ 98218: /***/ ((__unused_webpack_module, exports) => { @@ -2343,15 +2343,15 @@ var WireType; /***/ }), -/***/ 92889: +/***/ 49695: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.BinaryReader = exports.binaryReadOptions = void 0; -const binary_format_contract_1 = __nccwpck_require__(54816); -const pb_long_1 = __nccwpck_require__(61753); -const goog_varint_1 = __nccwpck_require__(93223); +const binary_format_contract_1 = __nccwpck_require__(98218); +const pb_long_1 = __nccwpck_require__(38819); +const goog_varint_1 = __nccwpck_require__(61605); const defaultsRead = { readUnknownField: true, readerFactory: bytes => new BinaryReader(bytes), @@ -2533,15 +2533,15 @@ exports.BinaryReader = BinaryReader; /***/ }), -/***/ 23957: +/***/ 70079: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.BinaryWriter = exports.binaryWriteOptions = void 0; -const pb_long_1 = __nccwpck_require__(61753); -const goog_varint_1 = __nccwpck_require__(93223); -const assert_1 = __nccwpck_require__(8602); +const pb_long_1 = __nccwpck_require__(38819); +const goog_varint_1 = __nccwpck_require__(61605); +const assert_1 = __nccwpck_require__(64828); const defaultsWrite = { writeUnknownFields: true, writerFactory: () => new BinaryWriter(), @@ -2772,7 +2772,7 @@ exports.BinaryWriter = BinaryWriter; /***/ }), -/***/ 70257: +/***/ 4903: /***/ ((__unused_webpack_module, exports) => { @@ -2866,7 +2866,7 @@ exports.listEnumNumbers = listEnumNumbers; /***/ }), -/***/ 93223: +/***/ 61605: /***/ ((__unused_webpack_module, exports) => { @@ -3147,7 +3147,7 @@ exports.varint32read = varint32read; /***/ }), -/***/ 68886: +/***/ 68140: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -3156,46 +3156,46 @@ exports.varint32read = varint32read; // webpack verbose output hints that this should be useful Object.defineProperty(exports, "__esModule", ({ value: true })); // Convenience JSON typings and corresponding type guards -var json_typings_1 = __nccwpck_require__(49999); +var json_typings_1 = __nccwpck_require__(13417); Object.defineProperty(exports, "typeofJsonValue", ({ enumerable: true, get: function () { return json_typings_1.typeofJsonValue; } })); Object.defineProperty(exports, "isJsonObject", ({ enumerable: true, get: function () { return json_typings_1.isJsonObject; } })); // Base 64 encoding -var base64_1 = __nccwpck_require__(26335); +var base64_1 = __nccwpck_require__(20841); Object.defineProperty(exports, "base64decode", ({ enumerable: true, get: function () { return base64_1.base64decode; } })); Object.defineProperty(exports, "base64encode", ({ enumerable: true, get: function () { return base64_1.base64encode; } })); // UTF8 encoding -var protobufjs_utf8_1 = __nccwpck_require__(58950); +var protobufjs_utf8_1 = __nccwpck_require__(49016); Object.defineProperty(exports, "utf8read", ({ enumerable: true, get: function () { return protobufjs_utf8_1.utf8read; } })); // Binary format contracts, options for reading and writing, for example -var binary_format_contract_1 = __nccwpck_require__(54816); +var binary_format_contract_1 = __nccwpck_require__(98218); Object.defineProperty(exports, "WireType", ({ enumerable: true, get: function () { return binary_format_contract_1.WireType; } })); Object.defineProperty(exports, "mergeBinaryOptions", ({ enumerable: true, get: function () { return binary_format_contract_1.mergeBinaryOptions; } })); Object.defineProperty(exports, "UnknownFieldHandler", ({ enumerable: true, get: function () { return binary_format_contract_1.UnknownFieldHandler; } })); // Standard IBinaryReader implementation -var binary_reader_1 = __nccwpck_require__(92889); +var binary_reader_1 = __nccwpck_require__(49695); Object.defineProperty(exports, "BinaryReader", ({ enumerable: true, get: function () { return binary_reader_1.BinaryReader; } })); Object.defineProperty(exports, "binaryReadOptions", ({ enumerable: true, get: function () { return binary_reader_1.binaryReadOptions; } })); // Standard IBinaryWriter implementation -var binary_writer_1 = __nccwpck_require__(23957); +var binary_writer_1 = __nccwpck_require__(70079); Object.defineProperty(exports, "BinaryWriter", ({ enumerable: true, get: function () { return binary_writer_1.BinaryWriter; } })); Object.defineProperty(exports, "binaryWriteOptions", ({ enumerable: true, get: function () { return binary_writer_1.binaryWriteOptions; } })); // Int64 and UInt64 implementations required for the binary format -var pb_long_1 = __nccwpck_require__(61753); +var pb_long_1 = __nccwpck_require__(38819); Object.defineProperty(exports, "PbLong", ({ enumerable: true, get: function () { return pb_long_1.PbLong; } })); Object.defineProperty(exports, "PbULong", ({ enumerable: true, get: function () { return pb_long_1.PbULong; } })); // JSON format contracts, options for reading and writing, for example -var json_format_contract_1 = __nccwpck_require__(29367); +var json_format_contract_1 = __nccwpck_require__(18069); Object.defineProperty(exports, "jsonReadOptions", ({ enumerable: true, get: function () { return json_format_contract_1.jsonReadOptions; } })); Object.defineProperty(exports, "jsonWriteOptions", ({ enumerable: true, get: function () { return json_format_contract_1.jsonWriteOptions; } })); Object.defineProperty(exports, "mergeJsonOptions", ({ enumerable: true, get: function () { return json_format_contract_1.mergeJsonOptions; } })); // Message type contract -var message_type_contract_1 = __nccwpck_require__(43785); +var message_type_contract_1 = __nccwpck_require__(69251); Object.defineProperty(exports, "MESSAGE_TYPE", ({ enumerable: true, get: function () { return message_type_contract_1.MESSAGE_TYPE; } })); // Message type implementation via reflection -var message_type_1 = __nccwpck_require__(15106); +var message_type_1 = __nccwpck_require__(69940); Object.defineProperty(exports, "MessageType", ({ enumerable: true, get: function () { return message_type_1.MessageType; } })); // Reflection info, generated by the plugin, exposed to the user, used by reflection ops -var reflection_info_1 = __nccwpck_require__(67910); +var reflection_info_1 = __nccwpck_require__(37048); Object.defineProperty(exports, "ScalarType", ({ enumerable: true, get: function () { return reflection_info_1.ScalarType; } })); Object.defineProperty(exports, "LongType", ({ enumerable: true, get: function () { return reflection_info_1.LongType; } })); Object.defineProperty(exports, "RepeatType", ({ enumerable: true, get: function () { return reflection_info_1.RepeatType; } })); @@ -3204,44 +3204,44 @@ Object.defineProperty(exports, "readFieldOptions", ({ enumerable: true, get: fun Object.defineProperty(exports, "readFieldOption", ({ enumerable: true, get: function () { return reflection_info_1.readFieldOption; } })); Object.defineProperty(exports, "readMessageOption", ({ enumerable: true, get: function () { return reflection_info_1.readMessageOption; } })); // Message operations via reflection -var reflection_type_check_1 = __nccwpck_require__(25167); +var reflection_type_check_1 = __nccwpck_require__(30073); Object.defineProperty(exports, "ReflectionTypeCheck", ({ enumerable: true, get: function () { return reflection_type_check_1.ReflectionTypeCheck; } })); -var reflection_create_1 = __nccwpck_require__(75726); +var reflection_create_1 = __nccwpck_require__(8892); Object.defineProperty(exports, "reflectionCreate", ({ enumerable: true, get: function () { return reflection_create_1.reflectionCreate; } })); -var reflection_scalar_default_1 = __nccwpck_require__(19526); +var reflection_scalar_default_1 = __nccwpck_require__(29348); Object.defineProperty(exports, "reflectionScalarDefault", ({ enumerable: true, get: function () { return reflection_scalar_default_1.reflectionScalarDefault; } })); -var reflection_merge_partial_1 = __nccwpck_require__(98044); +var reflection_merge_partial_1 = __nccwpck_require__(586); Object.defineProperty(exports, "reflectionMergePartial", ({ enumerable: true, get: function () { return reflection_merge_partial_1.reflectionMergePartial; } })); -var reflection_equals_1 = __nccwpck_require__(4827); +var reflection_equals_1 = __nccwpck_require__(8797); Object.defineProperty(exports, "reflectionEquals", ({ enumerable: true, get: function () { return reflection_equals_1.reflectionEquals; } })); -var reflection_binary_reader_1 = __nccwpck_require__(89611); +var reflection_binary_reader_1 = __nccwpck_require__(6537); Object.defineProperty(exports, "ReflectionBinaryReader", ({ enumerable: true, get: function () { return reflection_binary_reader_1.ReflectionBinaryReader; } })); -var reflection_binary_writer_1 = __nccwpck_require__(66907); +var reflection_binary_writer_1 = __nccwpck_require__(27685); Object.defineProperty(exports, "ReflectionBinaryWriter", ({ enumerable: true, get: function () { return reflection_binary_writer_1.ReflectionBinaryWriter; } })); -var reflection_json_reader_1 = __nccwpck_require__(46790); +var reflection_json_reader_1 = __nccwpck_require__(98944); Object.defineProperty(exports, "ReflectionJsonReader", ({ enumerable: true, get: function () { return reflection_json_reader_1.ReflectionJsonReader; } })); -var reflection_json_writer_1 = __nccwpck_require__(11094); +var reflection_json_writer_1 = __nccwpck_require__(57324); Object.defineProperty(exports, "ReflectionJsonWriter", ({ enumerable: true, get: function () { return reflection_json_writer_1.ReflectionJsonWriter; } })); -var reflection_contains_message_type_1 = __nccwpck_require__(59946); +var reflection_contains_message_type_1 = __nccwpck_require__(82092); Object.defineProperty(exports, "containsMessageType", ({ enumerable: true, get: function () { return reflection_contains_message_type_1.containsMessageType; } })); // Oneof helpers -var oneof_1 = __nccwpck_require__(18063); +var oneof_1 = __nccwpck_require__(69473); Object.defineProperty(exports, "isOneofGroup", ({ enumerable: true, get: function () { return oneof_1.isOneofGroup; } })); Object.defineProperty(exports, "setOneofValue", ({ enumerable: true, get: function () { return oneof_1.setOneofValue; } })); Object.defineProperty(exports, "getOneofValue", ({ enumerable: true, get: function () { return oneof_1.getOneofValue; } })); Object.defineProperty(exports, "clearOneofValue", ({ enumerable: true, get: function () { return oneof_1.clearOneofValue; } })); Object.defineProperty(exports, "getSelectedOneofValue", ({ enumerable: true, get: function () { return oneof_1.getSelectedOneofValue; } })); // Enum object type guard and reflection util, may be interesting to the user. -var enum_object_1 = __nccwpck_require__(70257); +var enum_object_1 = __nccwpck_require__(4903); Object.defineProperty(exports, "listEnumValues", ({ enumerable: true, get: function () { return enum_object_1.listEnumValues; } })); Object.defineProperty(exports, "listEnumNames", ({ enumerable: true, get: function () { return enum_object_1.listEnumNames; } })); Object.defineProperty(exports, "listEnumNumbers", ({ enumerable: true, get: function () { return enum_object_1.listEnumNumbers; } })); Object.defineProperty(exports, "isEnumObject", ({ enumerable: true, get: function () { return enum_object_1.isEnumObject; } })); // lowerCamelCase() is exported for plugin, rpc-runtime and other rpc packages -var lower_camel_case_1 = __nccwpck_require__(4073); +var lower_camel_case_1 = __nccwpck_require__(10023); Object.defineProperty(exports, "lowerCamelCase", ({ enumerable: true, get: function () { return lower_camel_case_1.lowerCamelCase; } })); // assertion functions are exported for plugin, may also be useful to user -var assert_1 = __nccwpck_require__(8602); +var assert_1 = __nccwpck_require__(64828); Object.defineProperty(exports, "assert", ({ enumerable: true, get: function () { return assert_1.assert; } })); Object.defineProperty(exports, "assertNever", ({ enumerable: true, get: function () { return assert_1.assertNever; } })); Object.defineProperty(exports, "assertInt32", ({ enumerable: true, get: function () { return assert_1.assertInt32; } })); @@ -3251,7 +3251,7 @@ Object.defineProperty(exports, "assertFloat32", ({ enumerable: true, get: functi /***/ }), -/***/ 29367: +/***/ 18069: /***/ ((__unused_webpack_module, exports) => { @@ -3293,7 +3293,7 @@ exports.mergeJsonOptions = mergeJsonOptions; /***/ }), -/***/ 49999: +/***/ 13417: /***/ ((__unused_webpack_module, exports) => { @@ -3325,7 +3325,7 @@ exports.isJsonObject = isJsonObject; /***/ }), -/***/ 4073: +/***/ 10023: /***/ ((__unused_webpack_module, exports) => { @@ -3367,7 +3367,7 @@ exports.lowerCamelCase = lowerCamelCase; /***/ }), -/***/ 43785: +/***/ 69251: /***/ ((__unused_webpack_module, exports) => { @@ -3384,26 +3384,26 @@ exports.MESSAGE_TYPE = Symbol.for("protobuf-ts/message-type"); /***/ }), -/***/ 15106: +/***/ 69940: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.MessageType = void 0; -const message_type_contract_1 = __nccwpck_require__(43785); -const reflection_info_1 = __nccwpck_require__(67910); -const reflection_type_check_1 = __nccwpck_require__(25167); -const reflection_json_reader_1 = __nccwpck_require__(46790); -const reflection_json_writer_1 = __nccwpck_require__(11094); -const reflection_binary_reader_1 = __nccwpck_require__(89611); -const reflection_binary_writer_1 = __nccwpck_require__(66907); -const reflection_create_1 = __nccwpck_require__(75726); -const reflection_merge_partial_1 = __nccwpck_require__(98044); -const json_typings_1 = __nccwpck_require__(49999); -const json_format_contract_1 = __nccwpck_require__(29367); -const reflection_equals_1 = __nccwpck_require__(4827); -const binary_writer_1 = __nccwpck_require__(23957); -const binary_reader_1 = __nccwpck_require__(92889); +const message_type_contract_1 = __nccwpck_require__(69251); +const reflection_info_1 = __nccwpck_require__(37048); +const reflection_type_check_1 = __nccwpck_require__(30073); +const reflection_json_reader_1 = __nccwpck_require__(98944); +const reflection_json_writer_1 = __nccwpck_require__(57324); +const reflection_binary_reader_1 = __nccwpck_require__(6537); +const reflection_binary_writer_1 = __nccwpck_require__(27685); +const reflection_create_1 = __nccwpck_require__(8892); +const reflection_merge_partial_1 = __nccwpck_require__(586); +const json_typings_1 = __nccwpck_require__(13417); +const json_format_contract_1 = __nccwpck_require__(18069); +const reflection_equals_1 = __nccwpck_require__(8797); +const binary_writer_1 = __nccwpck_require__(70079); +const binary_reader_1 = __nccwpck_require__(49695); const baseDescriptors = Object.getOwnPropertyDescriptors(Object.getPrototypeOf({})); const messageTypeDescriptor = baseDescriptors[message_type_contract_1.MESSAGE_TYPE] = {}; /** @@ -3568,7 +3568,7 @@ exports.MessageType = MessageType; /***/ }), -/***/ 18063: +/***/ 69473: /***/ ((__unused_webpack_module, exports) => { @@ -3689,13 +3689,13 @@ exports.getSelectedOneofValue = getSelectedOneofValue; /***/ }), -/***/ 61753: +/***/ 38819: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.PbLong = exports.PbULong = exports.detectBi = void 0; -const goog_varint_1 = __nccwpck_require__(93223); +const goog_varint_1 = __nccwpck_require__(61605); let BI; function detectBi() { const dv = new DataView(new ArrayBuffer(8)); @@ -3934,7 +3934,7 @@ PbLong.ZERO = new PbLong(0, 0); /***/ }), -/***/ 58950: +/***/ 49016: /***/ ((__unused_webpack_module, exports) => { @@ -4016,16 +4016,16 @@ exports.utf8read = utf8read; /***/ }), -/***/ 89611: +/***/ 6537: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.ReflectionBinaryReader = void 0; -const binary_format_contract_1 = __nccwpck_require__(54816); -const reflection_info_1 = __nccwpck_require__(67910); -const reflection_long_convert_1 = __nccwpck_require__(63402); -const reflection_scalar_default_1 = __nccwpck_require__(19526); +const binary_format_contract_1 = __nccwpck_require__(98218); +const reflection_info_1 = __nccwpck_require__(37048); +const reflection_long_convert_1 = __nccwpck_require__(5232); +const reflection_scalar_default_1 = __nccwpck_require__(29348); /** * Reads proto3 messages in binary format using reflection information. * @@ -4206,16 +4206,16 @@ exports.ReflectionBinaryReader = ReflectionBinaryReader; /***/ }), -/***/ 66907: +/***/ 27685: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.ReflectionBinaryWriter = void 0; -const binary_format_contract_1 = __nccwpck_require__(54816); -const reflection_info_1 = __nccwpck_require__(67910); -const assert_1 = __nccwpck_require__(8602); -const pb_long_1 = __nccwpck_require__(61753); +const binary_format_contract_1 = __nccwpck_require__(98218); +const reflection_info_1 = __nccwpck_require__(37048); +const assert_1 = __nccwpck_require__(64828); +const pb_long_1 = __nccwpck_require__(38819); /** * Writes proto3 messages in binary format using reflection information. * @@ -4446,13 +4446,13 @@ exports.ReflectionBinaryWriter = ReflectionBinaryWriter; /***/ }), -/***/ 59946: +/***/ 82092: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.containsMessageType = void 0; -const message_type_contract_1 = __nccwpck_require__(43785); +const message_type_contract_1 = __nccwpck_require__(69251); /** * Check if the provided object is a proto message. * @@ -4467,14 +4467,14 @@ exports.containsMessageType = containsMessageType; /***/ }), -/***/ 75726: +/***/ 8892: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.reflectionCreate = void 0; -const reflection_scalar_default_1 = __nccwpck_require__(19526); -const message_type_contract_1 = __nccwpck_require__(43785); +const reflection_scalar_default_1 = __nccwpck_require__(29348); +const message_type_contract_1 = __nccwpck_require__(69251); /** * Creates an instance of the generic message, using the field * information. @@ -4522,13 +4522,13 @@ exports.reflectionCreate = reflectionCreate; /***/ }), -/***/ 4827: +/***/ 8797: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.reflectionEquals = void 0; -const reflection_info_1 = __nccwpck_require__(67910); +const reflection_info_1 = __nccwpck_require__(37048); /** * Determines whether two message of the same type have the same field values. * Checks for deep equality, traversing repeated fields, oneof groups, maps @@ -4606,13 +4606,13 @@ function repeatedMsgEq(type, a, b) { /***/ }), -/***/ 67910: +/***/ 37048: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.readMessageOption = exports.readFieldOption = exports.readFieldOptions = exports.normalizeFieldInfo = exports.RepeatType = exports.LongType = exports.ScalarType = void 0; -const lower_camel_case_1 = __nccwpck_require__(4073); +const lower_camel_case_1 = __nccwpck_require__(10023); /** * Scalar value types. This is a subset of field types declared by protobuf * enum google.protobuf.FieldDescriptorProto.Type The types GROUP and MESSAGE @@ -4771,18 +4771,18 @@ exports.readMessageOption = readMessageOption; /***/ }), -/***/ 46790: +/***/ 98944: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.ReflectionJsonReader = void 0; -const json_typings_1 = __nccwpck_require__(49999); -const base64_1 = __nccwpck_require__(26335); -const reflection_info_1 = __nccwpck_require__(67910); -const pb_long_1 = __nccwpck_require__(61753); -const assert_1 = __nccwpck_require__(8602); -const reflection_long_convert_1 = __nccwpck_require__(63402); +const json_typings_1 = __nccwpck_require__(13417); +const base64_1 = __nccwpck_require__(20841); +const reflection_info_1 = __nccwpck_require__(37048); +const pb_long_1 = __nccwpck_require__(38819); +const assert_1 = __nccwpck_require__(64828); +const reflection_long_convert_1 = __nccwpck_require__(5232); /** * Reads proto3 messages in canonical JSON format using reflection information. * @@ -5095,16 +5095,16 @@ exports.ReflectionJsonReader = ReflectionJsonReader; /***/ }), -/***/ 11094: +/***/ 57324: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.ReflectionJsonWriter = void 0; -const base64_1 = __nccwpck_require__(26335); -const pb_long_1 = __nccwpck_require__(61753); -const reflection_info_1 = __nccwpck_require__(67910); -const assert_1 = __nccwpck_require__(8602); +const base64_1 = __nccwpck_require__(20841); +const pb_long_1 = __nccwpck_require__(38819); +const reflection_info_1 = __nccwpck_require__(37048); +const assert_1 = __nccwpck_require__(64828); /** * Writes proto3 messages in canonical JSON format using reflection * information. @@ -5332,13 +5332,13 @@ exports.ReflectionJsonWriter = ReflectionJsonWriter; /***/ }), -/***/ 63402: +/***/ 5232: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.reflectionLongConvert = void 0; -const reflection_info_1 = __nccwpck_require__(67910); +const reflection_info_1 = __nccwpck_require__(37048); /** * Utility method to convert a PbLong or PbUlong to a JavaScript * representation during runtime. @@ -5363,7 +5363,7 @@ exports.reflectionLongConvert = reflectionLongConvert; /***/ }), -/***/ 98044: +/***/ 586: /***/ ((__unused_webpack_module, exports) => { @@ -5460,15 +5460,15 @@ exports.reflectionMergePartial = reflectionMergePartial; /***/ }), -/***/ 19526: +/***/ 29348: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.reflectionScalarDefault = void 0; -const reflection_info_1 = __nccwpck_require__(67910); -const reflection_long_convert_1 = __nccwpck_require__(63402); -const pb_long_1 = __nccwpck_require__(61753); +const reflection_info_1 = __nccwpck_require__(37048); +const reflection_long_convert_1 = __nccwpck_require__(5232); +const pb_long_1 = __nccwpck_require__(38819); /** * Creates the default value for a scalar type. */ @@ -5504,14 +5504,14 @@ exports.reflectionScalarDefault = reflectionScalarDefault; /***/ }), -/***/ 25167: +/***/ 30073: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.ReflectionTypeCheck = void 0; -const reflection_info_1 = __nccwpck_require__(67910); -const oneof_1 = __nccwpck_require__(18063); +const reflection_info_1 = __nccwpck_require__(37048); +const oneof_1 = __nccwpck_require__(69473); // noinspection JSMethodCanBeStatic class ReflectionTypeCheck { constructor(info) { @@ -5741,7 +5741,7 @@ exports.ReflectionTypeCheck = ReflectionTypeCheck; /***/ }), -/***/ 17413: +/***/ 19914: /***/ ((module, exports, __nccwpck_require__) => { /** @@ -5752,7 +5752,7 @@ exports.ReflectionTypeCheck = ReflectionTypeCheck; Object.defineProperty(exports, "__esModule", ({ value: true })); -var eventTargetShim = __nccwpck_require__(16577); +var eventTargetShim = __nccwpck_require__(9876); /** * The signal class. @@ -5875,7 +5875,7 @@ module.exports.AbortSignal = AbortSignal /***/ }), -/***/ 15183: +/***/ 84455: /***/ (function(__unused_webpack_module, exports, __nccwpck_require__) { @@ -5947,7 +5947,7 @@ exports.req = req; /***/ }), -/***/ 98894: +/***/ 10646: /***/ (function(__unused_webpack_module, exports, __nccwpck_require__) { @@ -5982,7 +5982,7 @@ exports.Agent = void 0; const net = __importStar(__nccwpck_require__(69278)); const http = __importStar(__nccwpck_require__(58611)); const https_1 = __nccwpck_require__(65692); -__exportStar(__nccwpck_require__(15183), exports); +__exportStar(__nccwpck_require__(84455), exports); const INTERNAL = Symbol('AgentBaseInternalState'); class Agent extends http.Agent { constructor(opts) { @@ -6131,7 +6131,7 @@ exports.Agent = Agent; /***/ }), -/***/ 38816: +/***/ 6974: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /** @@ -6141,15 +6141,15 @@ exports.Agent = Agent; * Licensed under the MIT license. * https://github.com/archiverjs/node-archiver/blob/master/LICENSE-MIT */ -var fs = __nccwpck_require__(35744); +var fs = __nccwpck_require__(6768); var path = __nccwpck_require__(16928); -var flatten = __nccwpck_require__(97047); -var difference = __nccwpck_require__(57294); -var union = __nccwpck_require__(73270); -var isPlainObject = __nccwpck_require__(36542); +var flatten = __nccwpck_require__(44183); +var difference = __nccwpck_require__(11694); +var union = __nccwpck_require__(11350); +var isPlainObject = __nccwpck_require__(37406); -var glob = __nccwpck_require__(21363); +var glob = __nccwpck_require__(63360); var file = module.exports = {}; @@ -6347,7 +6347,7 @@ file.normalizeFilesArray = function(data) { /***/ }), -/***/ 53296: +/***/ 16090: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /** @@ -6357,18 +6357,18 @@ file.normalizeFilesArray = function(data) { * Licensed under the MIT license. * https://github.com/archiverjs/archiver-utils/blob/master/LICENSE */ -var fs = __nccwpck_require__(35744); +var fs = __nccwpck_require__(6768); var path = __nccwpck_require__(16928); -var isStream = __nccwpck_require__(96543); -var lazystream = __nccwpck_require__(32126); -var normalizePath = __nccwpck_require__(56133); -var defaults = __nccwpck_require__(7511); +var isStream = __nccwpck_require__(82198); +var lazystream = __nccwpck_require__(6889); +var normalizePath = __nccwpck_require__(52398); +var defaults = __nccwpck_require__(6391); var Stream = (__nccwpck_require__(2203).Stream); -var PassThrough = (__nccwpck_require__(29963).PassThrough); +var PassThrough = (__nccwpck_require__(48924).PassThrough); var utils = module.exports = {}; -utils.file = __nccwpck_require__(38816); +utils.file = __nccwpck_require__(6974); utils.collectStream = function(source, callback) { var collection = []; @@ -6509,7 +6509,7 @@ utils.walkdir = function(dirpath, base, callback) { /***/ }), -/***/ 99392: +/***/ 72709: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /** @@ -6519,7 +6519,7 @@ utils.walkdir = function(dirpath, base, callback) { * @license [MIT]{@link https://github.com/archiverjs/node-archiver/blob/master/LICENSE} * @copyright (c) 2012-2014 Chris Talkington, contributors. */ -var Archiver = __nccwpck_require__(50549); +var Archiver = __nccwpck_require__(77170); var formats = {}; @@ -6591,15 +6591,15 @@ vending.isRegisteredFormat = function (format) { return false; }; -vending.registerFormat('zip', __nccwpck_require__(22836)); -vending.registerFormat('tar', __nccwpck_require__(10396)); -vending.registerFormat('json', __nccwpck_require__(54693)); +vending.registerFormat('zip', __nccwpck_require__(92477)); +vending.registerFormat('tar', __nccwpck_require__(46125)); +vending.registerFormat('json', __nccwpck_require__(60602)); module.exports = vending; /***/ }), -/***/ 50549: +/***/ 77170: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /** @@ -6610,14 +6610,14 @@ module.exports = vending; * @copyright (c) 2012-2014 Chris Talkington, contributors. */ var fs = __nccwpck_require__(79896); -var glob = __nccwpck_require__(51364); -var async = __nccwpck_require__(97329); +var glob = __nccwpck_require__(15934); +var async = __nccwpck_require__(14113); var path = __nccwpck_require__(16928); -var util = __nccwpck_require__(53296); +var util = __nccwpck_require__(16090); var inherits = (__nccwpck_require__(39023).inherits); -var ArchiverError = __nccwpck_require__(13110); -var Transform = (__nccwpck_require__(29963).Transform); +var ArchiverError = __nccwpck_require__(4135); +var Transform = (__nccwpck_require__(48924).Transform); var win32 = process.platform === 'win32'; @@ -7580,7 +7580,7 @@ module.exports = Archiver; /***/ }), -/***/ 13110: +/***/ 4135: /***/ ((module, exports, __nccwpck_require__) => { /** @@ -7626,7 +7626,7 @@ exports = module.exports = ArchiverError; /***/ }), -/***/ 54693: +/***/ 60602: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /** @@ -7637,10 +7637,10 @@ exports = module.exports = ArchiverError; * @copyright (c) 2012-2014 Chris Talkington, contributors. */ var inherits = (__nccwpck_require__(39023).inherits); -var Transform = (__nccwpck_require__(29963).Transform); +var Transform = (__nccwpck_require__(48924).Transform); -var crc32 = __nccwpck_require__(84928); -var util = __nccwpck_require__(53296); +var crc32 = __nccwpck_require__(57212); +var util = __nccwpck_require__(16090); /** * @constructor @@ -7743,7 +7743,7 @@ module.exports = Json; /***/ }), -/***/ 10396: +/***/ 46125: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /** @@ -7755,8 +7755,8 @@ module.exports = Json; */ var zlib = __nccwpck_require__(43106); -var engine = __nccwpck_require__(56118); -var util = __nccwpck_require__(53296); +var engine = __nccwpck_require__(54620); +var util = __nccwpck_require__(16090); /** * @constructor @@ -7917,7 +7917,7 @@ module.exports = Tar; /***/ }), -/***/ 22836: +/***/ 92477: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /** @@ -7927,8 +7927,8 @@ module.exports = Tar; * @license [MIT]{@link https://github.com/archiverjs/node-archiver/blob/master/LICENSE} * @copyright (c) 2012-2014 Chris Talkington, contributors. */ -var engine = __nccwpck_require__(41622); -var util = __nccwpck_require__(53296); +var engine = __nccwpck_require__(60318); +var util = __nccwpck_require__(16090); /** * @constructor @@ -8044,7 +8044,7 @@ module.exports = Zip; /***/ }), -/***/ 97329: +/***/ 14113: /***/ (function(__unused_webpack_module, exports) { (function (global, factory) { @@ -14111,7 +14111,7 @@ module.exports = Zip; /***/ }), -/***/ 73057: +/***/ 82901: /***/ ((module) => { function isBuffer(value) { @@ -14306,7 +14306,7 @@ module.exports = { /***/ }), -/***/ 59380: +/***/ 90870: /***/ ((module) => { @@ -14375,13 +14375,13 @@ function range(a, b, str) { /***/ }), -/***/ 58769: +/***/ 52386: /***/ ((module, exports, __nccwpck_require__) => { -var Chainsaw = __nccwpck_require__(71710); +var Chainsaw = __nccwpck_require__(66428); var EventEmitter = (__nccwpck_require__(24434).EventEmitter); -var Buffers = __nccwpck_require__(86627); -var Vars = __nccwpck_require__(91259); +var Buffers = __nccwpck_require__(66869); +var Vars = __nccwpck_require__(78174); var Stream = (__nccwpck_require__(2203).Stream); exports = module.exports = function (bufOrEm, eventName) { @@ -14779,7 +14779,7 @@ function words (decode) { /***/ }), -/***/ 91259: +/***/ 78174: /***/ ((module) => { module.exports = function (store) { @@ -14814,7 +14814,7 @@ module.exports = function (store) { /***/ }), -/***/ 63251: +/***/ 9900: /***/ (function(module) { /** @@ -16344,10 +16344,10 @@ module.exports = function (store) { /***/ }), -/***/ 94691: +/***/ 20822: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var balanced = __nccwpck_require__(59380); +var balanced = __nccwpck_require__(90870); module.exports = expandTop; @@ -16357,6 +16357,20 @@ var escClose = '\0CLOSE'+Math.random()+'\0'; var escComma = '\0COMMA'+Math.random()+'\0'; var escPeriod = '\0PERIOD'+Math.random()+'\0'; +var EXPANSION_MAX = 100000 + +// `EXPANSION_MAX` caps the *number* of expansions, but not their length. An +// input like `'{a,b}'.repeat(1500)` stays under that count - its output is +// truncated to 100k results - while making every result ~1500 characters +// long. The result set, and the intermediate arrays built while combining +// brace sets, then grow large enough to exhaust memory and crash the process +// (CVE-2026-14257). `EXPANSION_MAX_LENGTH` bounds the total number of +// characters the accumulator may hold at any point, so memory stays flat no +// matter how many brace groups are chained. The limit sits well above any +// realistic expansion (100k results hitting `EXPANSION_MAX` measure ~1M +// characters) so legitimate input is unaffected. +var EXPANSION_MAX_LENGTH = 4000000 + function numeric(str) { return parseInt(str, 10) == str ? parseInt(str, 10) @@ -16410,10 +16424,14 @@ function parseCommaParts(str) { return parts; } -function expandTop(str) { +function expandTop(str, options) { if (!str) return []; + options = options || {}; + var max = options.max == null ? EXPANSION_MAX : options.max; + var maxLength = options.maxLength == null ? EXPANSION_MAX_LENGTH : options.maxLength; + // I don't know why Bash 4.3 does this, but it does. // Anything starting with {} will have the first two bytes preserved // but *only* at the top level, so {},a}b will not expand to anything, @@ -16424,7 +16442,7 @@ function expandTop(str) { str = '\\{\\}' + str.substr(2); } - return expand(escapeBraces(str), true).map(unescapeBraces); + return expand(escapeBraces(str), max, maxLength, true).map(unescapeBraces); } function embrace(str) { @@ -16441,24 +16459,144 @@ function gte(i, y) { return i >= y; } -function expand(str, isTop) { - var expansions = []; +// Build `{ acc[a] + pre + values[v] }` for every combination, capping the +// number of results at `max` and the total number of characters at `maxLength`. +// This is the one place output grows, so bounding it here keeps the single +// accumulator - and therefore memory - flat regardless of how many brace groups +// are combined (CVE-2026-14257). +function combine( + acc, + pre, + values, + max, + maxLength, + dropEmpties +) { + var out = [] + var length = 0 + for (var a = 0; a < acc.length; a++) { + for (var v = 0; v < values.length; v++) { + if (out.length >= max) return out + var expansion = acc[a] + pre + values[v] + // Bash drops empty results at the top level. Skip them before they count + // against `max`, so `max` bounds the number of *kept* results. + if (dropEmpties && !expansion) continue + if (length + expansion.length > maxLength) return out + out.push(expansion) + length += expansion.length + } + } + return out +} - var m = balanced('{', '}', str); - if (!m) return [str]; +// The expansion values of a single numeric (`1..5`) or alphabetic (`a..e..2`) +// sequence body. +function expandSequence( + body, + isAlphaSequence, + max, + maxLength +) { + var n = body.split(/\.\./) + var N = [] + // A sequence body always splits into two or three parts, but the compiler + // can't know that. + /* c8 ignore start */ + if (n[0] === undefined || n[1] === undefined) { + return N + } + /* c8 ignore stop */ + var x = numeric(n[0]) + var y = numeric(n[1]) + var width = Math.max(n[0].length, n[1].length) + var incr = + n.length === 3 && n[2] !== undefined ? + Math.max(Math.abs(numeric(n[2])), 1) + : 1 + var test = lte + var reverse = y < x + if (reverse) { + incr *= -1 + test = gte + } + var pad = n.some(isPadded) + + var length = 0 + for (var i = x; test(i, y) && N.length < max; i += incr) { + var c + if (isAlphaSequence) { + c = String.fromCharCode(i) + if (c === '\\') { + c = '' + } + } else { + c = String(i) + if (pad) { + var need = width - c.length + if (need > 0) { + var z = new Array(need + 1).join('0') + if (i < 0) { + c = '-' + z + c.slice(1) + } else { + c = z + c + } + } + } + } + if (length + c.length > maxLength) break + N.push(c) + length += c.length + } + return N +} - // no need to expand pre, since it is guaranteed to be free of brace-sets - var pre = m.pre; - var post = m.post.length - ? expand(m.post, false) - : ['']; +function expand( + str, + max, + maxLength, + isTop +) { + // Consume the string's top-level brace groups left to right, threading a + // running set of combined prefixes (`acc`). Expanding the tail iteratively - + // rather than recursing on `m.post` once per group - keeps the native stack + // depth constant, so deeply chained input (`'{a,b}'.repeat(3000)`) can no + // longer overflow the stack, and leaves a single accumulator whose size + // `maxLength` bounds directly (CVE-2026-14257). + var acc = [''] + + // Bash drops empty results, but only when the *first* top-level group is a + // comma set - a sequence like `{a..\}` may legitimately yield ''. The drop + // is on the final strings, so it is applied to whichever `combine` produces + // them (the one with no brace set left in the tail). + var dropEmpties = false + var firstGroup = true + + for (;;) { + const m = balanced('{', '}', str) + + // No brace set left: the rest of the string is literal. + if (!m) { + return combine(acc, str, [''], max, maxLength, dropEmpties) + } + + // no need to expand pre, since it is guaranteed to be free of brace-sets + const pre = m.pre - if (/\$$/.test(m.pre)) { - for (var k = 0; k < post.length; k++) { - var expansion = pre+ '{' + m.body + '}' + post[k]; - expansions.push(expansion); + if (/\$$/.test(pre)) { + acc = combine( + acc, + pre + '{' + m.body + '}', + [''], + max, + maxLength, + dropEmpties && !m.post.length + ) + firstGroup = false + if (!m.post.length) break + str = m.post + continue } - } else { + var isNumericSequence = /^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(m.body); var isAlphaSequence = /^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(m.body); var isSequence = isNumericSequence || isAlphaSequence; @@ -16467,94 +16605,91 @@ function expand(str, isTop) { // {a},b} if (m.post.match(/,(?!,).*\}/)) { str = m.pre + '{' + m.body + escClose + m.post; - return expand(str); + isTop = true; + continue; } - return [str]; + // Nothing here expands, so the whole remaining string is literal. + return combine( + acc, + pre + '{' + m.body + '}' + m.post, + [''], + max, + maxLength, + dropEmpties + ) + } + + if (firstGroup) { + dropEmpties = isTop && !isSequence + firstGroup = false } - var n; + var values; if (isSequence) { - n = m.body.split(/\.\./); + values = expandSequence(m.body, isAlphaSequence, max, maxLength); } else { - n = parseCommaParts(m.body); - if (n.length === 1) { + var n = parseCommaParts(m.body); + if (n.length === 1 && n[0] !== undefined) { // x{{a,b}}y ==> x{a}y x{b}y - n = expand(n[0], false).map(embrace); + n = expand(n[0], max, maxLength, false).map(embrace); + //XXX is this necessary? Can't seem to hit it in tests. + /* c8 ignore start */ if (n.length === 1) { - return post.map(function(p) { - return m.pre + n[0] + p; - }); + acc = combine( + acc, + pre + n[0], + [''], + max, + maxLength, + dropEmpties && !m.post.length + ) + if (!m.post.length) break + str = m.post + continue } + /* c8 ignore stop */ } - } - // at this point, n is the parts, and we know it's not a comma set - // with a single entry. - var N; - - if (isSequence) { - var x = numeric(n[0]); - var y = numeric(n[1]); - var width = Math.max(n[0].length, n[1].length) - var incr = n.length == 3 - ? Math.abs(numeric(n[2])) - : 1; - var test = lte; - var reverse = y < x; - if (reverse) { - incr *= -1; - test = gte; - } - var pad = n.some(isPadded); - - N = []; - - for (var i = x; test(i, y); i += incr) { - var c; - if (isAlphaSequence) { - c = String.fromCharCode(i); - if (c === '\\') - c = ''; - } else { - c = String(i); - if (pad) { - var need = width - c.length; - if (need > 0) { - var z = new Array(need + 1).join('0'); - if (i < 0) - c = '-' + z + c.slice(1); - else - c = z + c; - } - } + // Values that `combine` is going to drop as empty produce no result, so + // they must not count against `max` - otherwise `{a,,b}` with `max: 2` + // would stop at `['a', '']` and yield one result instead of two. Skipping + // them outright keeps `values` bounded while leaving `max` a bound on + // *kept* results. + var dropsEmpties = dropEmpties && !m.post.length && !pre + for (var d = 0; dropsEmpties && d < acc.length; d++) { + if (acc[d]) { + dropsEmpties = false } - N.push(c); } - } else { - N = []; - for (var j = 0; j < n.length; j++) { - N.push.apply(N, expand(n[j], false)); + values = [] + var valuesLength = 0 + outer: for (var j = 0; j < n.length; j++) { + var expanded = expand(n[j], max, maxLength, false) + for (var k = 0; k < expanded.length; k++) { + var v = expanded[k] + if (dropsEmpties && !v) continue + if (values.length >= max || valuesLength + v.length > maxLength) { + break outer + } + values.push(v) + valuesLength += v.length + } } } - for (var j = 0; j < N.length; j++) { - for (var k = 0; k < post.length; k++) { - var expansion = pre + N[j] + post[k]; - if (!isTop || isSequence || expansion) - expansions.push(expansion); - } - } + acc = combine(acc, pre, values, max, maxLength, dropEmpties && !m.post.length) + if (!m.post.length) break + str = m.post } - return expansions; + return acc } - /***/ }), -/***/ 39732: +/***/ 30715: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /*jshint node:true */ @@ -16602,7 +16737,7 @@ bufferEq.restore = function() { /***/ }), -/***/ 86627: +/***/ 66869: /***/ ((module) => { module.exports = Buffers; @@ -16878,10 +17013,10 @@ Buffers.prototype.toString = function(encoding, start, end) { /***/ }), -/***/ 71710: +/***/ 66428: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var Traverse = __nccwpck_require__(62958); +var Traverse = __nccwpck_require__(47441); var EventEmitter = (__nccwpck_require__(24434).EventEmitter); module.exports = Chainsaw; @@ -17030,7 +17165,7 @@ function upgradeChainsaw(saw) { /***/ }), -/***/ 96070: +/***/ 83998: /***/ ((module) => { /** @@ -17052,7 +17187,7 @@ ArchiveEntry.prototype.isDirectory = function() {}; /***/ }), -/***/ 36306: +/***/ 90586: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /** @@ -17063,11 +17198,11 @@ ArchiveEntry.prototype.isDirectory = function() {}; * https://github.com/archiverjs/node-compress-commons/blob/master/LICENSE-MIT */ var inherits = (__nccwpck_require__(39023).inherits); -var isStream = __nccwpck_require__(96543); -var Transform = (__nccwpck_require__(29963).Transform); +var isStream = __nccwpck_require__(82198); +var Transform = (__nccwpck_require__(48924).Transform); -var ArchiveEntry = __nccwpck_require__(96070); -var util = __nccwpck_require__(18300); +var ArchiveEntry = __nccwpck_require__(83998); +var util = __nccwpck_require__(53636); var ArchiveOutputStream = module.exports = function(options) { if (!(this instanceof ArchiveOutputStream)) { @@ -17176,7 +17311,7 @@ ArchiveOutputStream.prototype.write = function(chunk, cb) { /***/ }), -/***/ 94908: +/***/ 84964: /***/ ((module) => { /** @@ -17254,7 +17389,7 @@ module.exports = { /***/ }), -/***/ 97632: +/***/ 73368: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /** @@ -17264,7 +17399,7 @@ module.exports = { * Licensed under the MIT license. * https://github.com/archiverjs/node-compress-commons/blob/master/LICENSE-MIT */ -var zipUtil = __nccwpck_require__(6453); +var zipUtil = __nccwpck_require__(59229); var DATA_DESCRIPTOR_FLAG = 1 << 3; var ENCRYPTION_FLAG = 1 << 0; @@ -17361,7 +17496,7 @@ GeneralPurposeBit.prototype.usesUTF8ForNames = function() { /***/ }), -/***/ 23810: +/***/ 64666: /***/ ((module) => { /** @@ -17420,7 +17555,7 @@ module.exports = { /***/ }), -/***/ 6453: +/***/ 59229: /***/ ((module) => { /** @@ -17500,7 +17635,7 @@ util.toDosTime = function(d) { /***/ }), -/***/ 73380: +/***/ 84220: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /** @@ -17511,14 +17646,14 @@ util.toDosTime = function(d) { * https://github.com/archiverjs/node-compress-commons/blob/master/LICENSE-MIT */ var inherits = (__nccwpck_require__(39023).inherits); -var normalizePath = __nccwpck_require__(56133); +var normalizePath = __nccwpck_require__(52398); -var ArchiveEntry = __nccwpck_require__(96070); -var GeneralPurposeBit = __nccwpck_require__(97632); -var UnixStat = __nccwpck_require__(23810); +var ArchiveEntry = __nccwpck_require__(83998); +var GeneralPurposeBit = __nccwpck_require__(73368); +var UnixStat = __nccwpck_require__(64666); -var constants = __nccwpck_require__(94908); -var zipUtil = __nccwpck_require__(6453); +var constants = __nccwpck_require__(84964); +var zipUtil = __nccwpck_require__(59229); var ZipArchiveEntry = module.exports = function(name) { if (!(this instanceof ZipArchiveEntry)) { @@ -17920,7 +18055,7 @@ ZipArchiveEntry.prototype.isZip64 = function() { /***/ }), -/***/ 82132: +/***/ 24956: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /** @@ -17931,17 +18066,17 @@ ZipArchiveEntry.prototype.isZip64 = function() { * https://github.com/archiverjs/node-compress-commons/blob/master/LICENSE-MIT */ var inherits = (__nccwpck_require__(39023).inherits); -var crc32 = __nccwpck_require__(84891); -var {CRC32Stream} = __nccwpck_require__(82770); -var {DeflateCRC32Stream} = __nccwpck_require__(82770); +var crc32 = __nccwpck_require__(62095); +var {CRC32Stream} = __nccwpck_require__(62305); +var {DeflateCRC32Stream} = __nccwpck_require__(62305); -var ArchiveOutputStream = __nccwpck_require__(36306); -var ZipArchiveEntry = __nccwpck_require__(73380); -var GeneralPurposeBit = __nccwpck_require__(97632); +var ArchiveOutputStream = __nccwpck_require__(90586); +var ZipArchiveEntry = __nccwpck_require__(84220); +var GeneralPurposeBit = __nccwpck_require__(73368); -var constants = __nccwpck_require__(94908); -var util = __nccwpck_require__(18300); -var zipUtil = __nccwpck_require__(6453); +var constants = __nccwpck_require__(84964); +var util = __nccwpck_require__(53636); +var zipUtil = __nccwpck_require__(59229); var ZipArchiveOutputStream = module.exports = function(options) { if (!(this instanceof ZipArchiveOutputStream)) { @@ -18364,7 +18499,7 @@ ZipArchiveOutputStream.prototype.setComment = function(comment) { /***/ }), -/***/ 47544: +/***/ 93920: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /** @@ -18375,15 +18510,15 @@ ZipArchiveOutputStream.prototype.setComment = function(comment) { * https://github.com/archiverjs/node-compress-commons/blob/master/LICENSE-MIT */ module.exports = { - ArchiveEntry: __nccwpck_require__(96070), - ZipArchiveEntry: __nccwpck_require__(73380), - ArchiveOutputStream: __nccwpck_require__(36306), - ZipArchiveOutputStream: __nccwpck_require__(82132) + ArchiveEntry: __nccwpck_require__(83998), + ZipArchiveEntry: __nccwpck_require__(84220), + ArchiveOutputStream: __nccwpck_require__(90586), + ZipArchiveOutputStream: __nccwpck_require__(24956) }; /***/ }), -/***/ 18300: +/***/ 53636: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /** @@ -18394,8 +18529,8 @@ module.exports = { * https://github.com/archiverjs/node-compress-commons/blob/master/LICENSE-MIT */ var Stream = (__nccwpck_require__(2203).Stream); -var PassThrough = (__nccwpck_require__(29963).PassThrough); -var isStream = __nccwpck_require__(96543); +var PassThrough = (__nccwpck_require__(48924).PassThrough); +var isStream = __nccwpck_require__(82198); var util = module.exports = {}; @@ -18416,7 +18551,7 @@ util.normalizeInputSource = function(source) { /***/ }), -/***/ 45481: +/***/ 22465: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { // Copyright Joyent, Inc. and other Node contributors. @@ -18530,7 +18665,7 @@ function objectToString(o) { /***/ }), -/***/ 84891: +/***/ 62095: /***/ ((__unused_webpack_module, exports) => { /*! crc32.js (C) 2014-present SheetJS -- http://sheetjs.com */ @@ -18644,7 +18779,7 @@ CRC32.str = crc32_str; /***/ }), -/***/ 3662: +/***/ 17395: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /** @@ -18657,9 +18792,9 @@ CRC32.str = crc32_str; -const {Transform} = __nccwpck_require__(29963); +const {Transform} = __nccwpck_require__(48924); -const crc32 = __nccwpck_require__(84891); +const crc32 = __nccwpck_require__(62095); class CRC32Stream extends Transform { constructor(options) { @@ -18699,7 +18834,7 @@ module.exports = CRC32Stream; /***/ }), -/***/ 76252: +/***/ 12097: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /** @@ -18714,7 +18849,7 @@ module.exports = CRC32Stream; const {DeflateRaw} = __nccwpck_require__(43106); -const crc32 = __nccwpck_require__(84891); +const crc32 = __nccwpck_require__(62095); class DeflateCRC32Stream extends DeflateRaw { constructor(options) { @@ -18768,7 +18903,7 @@ module.exports = DeflateCRC32Stream; /***/ }), -/***/ 82770: +/***/ 62305: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /** @@ -18782,14 +18917,14 @@ module.exports = DeflateCRC32Stream; module.exports = { - CRC32Stream: __nccwpck_require__(3662), - DeflateCRC32Stream: __nccwpck_require__(76252) + CRC32Stream: __nccwpck_require__(17395), + DeflateCRC32Stream: __nccwpck_require__(12097) } /***/ }), -/***/ 6110: +/***/ 57451: /***/ ((module, exports, __nccwpck_require__) => { /* eslint-env browser */ @@ -19049,7 +19184,7 @@ function localstorage() { } } -module.exports = __nccwpck_require__(40897)(exports); +module.exports = __nccwpck_require__(63350)(exports); const {formatters} = module.exports; @@ -19068,7 +19203,7 @@ formatters.j = function (v) { /***/ }), -/***/ 40897: +/***/ 63350: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { @@ -19084,7 +19219,7 @@ function setup(env) { createDebug.disable = disable; createDebug.enable = enable; createDebug.enabled = enabled; - createDebug.humanize = __nccwpck_require__(70744); + createDebug.humanize = __nccwpck_require__(26647); createDebug.destroy = destroy; Object.keys(env).forEach(key => { @@ -19367,7 +19502,7 @@ module.exports = setup; /***/ }), -/***/ 2830: +/***/ 18263: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /** @@ -19376,15 +19511,15 @@ module.exports = setup; */ if (typeof process === 'undefined' || process.type === 'renderer' || process.browser === true || process.__nwjs) { - module.exports = __nccwpck_require__(6110); + module.exports = __nccwpck_require__(57451); } else { - module.exports = __nccwpck_require__(95108); + module.exports = __nccwpck_require__(76423); } /***/ }), -/***/ 95108: +/***/ 76423: /***/ ((module, exports, __nccwpck_require__) => { /** @@ -19418,7 +19553,7 @@ exports.colors = [6, 2, 3, 4, 5, 1]; try { // Optional dependency (as in, doesn't need to be installed, NOT like optionalDependencies in package.json) // eslint-disable-next-line import/no-extraneous-dependencies - const supportsColor = __nccwpck_require__(60075); + const supportsColor = __nccwpck_require__(84000); if (supportsColor && (supportsColor.stderr || supportsColor).level >= 2) { exports.colors = [ @@ -19626,7 +19761,7 @@ function init(debug) { } } -module.exports = __nccwpck_require__(40897)(exports); +module.exports = __nccwpck_require__(63350)(exports); const {formatters} = module.exports; @@ -19654,14 +19789,14 @@ formatters.O = function (v) { /***/ }), -/***/ 325: +/***/ 91454: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var Buffer = (__nccwpck_require__(93058).Buffer); +var Buffer = (__nccwpck_require__(65249).Buffer); -var getParamBytesForAlg = __nccwpck_require__(5028); +var getParamBytesForAlg = __nccwpck_require__(20883); var MAX_OCTET = 0x80, CLASS_UNIVERSAL = 0, @@ -19848,7 +19983,7 @@ module.exports = { /***/ }), -/***/ 5028: +/***/ 20883: /***/ ((module) => { @@ -19878,7 +20013,7 @@ module.exports = getParamBytesForAlg; /***/ }), -/***/ 16577: +/***/ 9876: /***/ ((module, exports) => { /** @@ -20756,7 +20891,7 @@ module.exports.defineEventAttribute = defineEventAttribute /***/ }), -/***/ 29580: +/***/ 19366: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { module.exports = __nccwpck_require__(24434) @@ -20764,7 +20899,7 @@ module.exports = __nccwpck_require__(24434) /***/ }), -/***/ 13587: +/***/ 44545: /***/ ((module) => { module.exports = class FixedFIFO { @@ -20810,10 +20945,10 @@ module.exports = class FixedFIFO { /***/ }), -/***/ 83867: +/***/ 19597: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const FixedFIFO = __nccwpck_require__(13587) +const FixedFIFO = __nccwpck_require__(44545) module.exports = class FastFIFO { constructor (hwm) { @@ -20865,7 +21000,7 @@ module.exports = class FastFIFO { /***/ }), -/***/ 73964: +/***/ 17340: /***/ ((module) => { @@ -20895,13 +21030,13 @@ function clone (obj) { /***/ }), -/***/ 35744: +/***/ 6768: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { var fs = __nccwpck_require__(79896) -var polyfills = __nccwpck_require__(83501) -var legacy = __nccwpck_require__(12270) -var clone = __nccwpck_require__(73964) +var polyfills = __nccwpck_require__(27805) +var legacy = __nccwpck_require__(90366) +var clone = __nccwpck_require__(17340) var util = __nccwpck_require__(39023) @@ -21350,7 +21485,7 @@ function retry () { /***/ }), -/***/ 12270: +/***/ 90366: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { var Stream = (__nccwpck_require__(2203).Stream) @@ -21475,7 +21610,7 @@ function legacy (fs) { /***/ }), -/***/ 83501: +/***/ 27805: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { var constants = __nccwpck_require__(49140) @@ -21837,7 +21972,7 @@ function patch (fs) { /***/ }), -/***/ 81970: +/***/ 74249: /***/ (function(__unused_webpack_module, exports, __nccwpck_require__) { @@ -21871,9 +22006,9 @@ Object.defineProperty(exports, "__esModule", ({ value: true })); exports.HttpProxyAgent = void 0; const net = __importStar(__nccwpck_require__(69278)); const tls = __importStar(__nccwpck_require__(64756)); -const debug_1 = __importDefault(__nccwpck_require__(2830)); +const debug_1 = __importDefault(__nccwpck_require__(18263)); const events_1 = __nccwpck_require__(24434); -const agent_base_1 = __nccwpck_require__(98894); +const agent_base_1 = __nccwpck_require__(10646); const url_1 = __nccwpck_require__(87016); const debug = (0, debug_1.default)('http-proxy-agent'); /** @@ -21991,7 +22126,7 @@ function omit(obj, ...keys) { /***/ }), -/***/ 3669: +/***/ 31475: /***/ (function(__unused_webpack_module, exports, __nccwpck_require__) { @@ -22026,10 +22161,10 @@ exports.HttpsProxyAgent = void 0; const net = __importStar(__nccwpck_require__(69278)); const tls = __importStar(__nccwpck_require__(64756)); const assert_1 = __importDefault(__nccwpck_require__(42613)); -const debug_1 = __importDefault(__nccwpck_require__(2830)); -const agent_base_1 = __nccwpck_require__(98894); +const debug_1 = __importDefault(__nccwpck_require__(18263)); +const agent_base_1 = __nccwpck_require__(10646); const url_1 = __nccwpck_require__(87016); -const parse_proxy_response_1 = __nccwpck_require__(37943); +const parse_proxy_response_1 = __nccwpck_require__(20625); const debug = (0, debug_1.default)('https-proxy-agent'); const setServernameFromNonIpHost = (options) => { if (options.servername === undefined && @@ -22177,7 +22312,7 @@ function omit(obj, ...keys) { /***/ }), -/***/ 37943: +/***/ 20625: /***/ (function(__unused_webpack_module, exports, __nccwpck_require__) { @@ -22186,7 +22321,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) { }; Object.defineProperty(exports, "__esModule", ({ value: true })); exports.parseProxyResponse = void 0; -const debug_1 = __importDefault(__nccwpck_require__(2830)); +const debug_1 = __importDefault(__nccwpck_require__(18263)); const debug = (0, debug_1.default)('https-proxy-agent:parse-proxy-response'); function parseProxyResponse(socket) { return new Promise((resolve, reject) => { @@ -22284,7 +22419,7 @@ exports.parseProxyResponse = parseProxyResponse; /***/ }), -/***/ 39598: +/***/ 76153: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { try { @@ -22294,13 +22429,13 @@ try { module.exports = util.inherits; } catch (e) { /* istanbul ignore next */ - module.exports = __nccwpck_require__(26589); + module.exports = __nccwpck_require__(2562); } /***/ }), -/***/ 26589: +/***/ 2562: /***/ ((module) => { if (typeof Object.create === 'function') { @@ -22334,7 +22469,7 @@ if (typeof Object.create === 'function') { /***/ }), -/***/ 96543: +/***/ 82198: /***/ ((module) => { @@ -22369,7 +22504,7 @@ module.exports = isStream; /***/ }), -/***/ 82513: +/***/ 92012: /***/ ((module) => { var toString = {}.toString; @@ -22381,10 +22516,10 @@ module.exports = Array.isArray || function (arr) { /***/ }), -/***/ 92047: +/***/ 83499: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var jws = __nccwpck_require__(33324); +var jws = __nccwpck_require__(63922); module.exports = function (jwt, options) { options = options || {}; @@ -22418,22 +22553,22 @@ module.exports = function (jwt, options) { /***/ }), -/***/ 69653: +/***/ 38457: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { module.exports = { - decode: __nccwpck_require__(92047), - verify: __nccwpck_require__(60772), - sign: __nccwpck_require__(14912), - JsonWebTokenError: __nccwpck_require__(26248), - NotBeforeError: __nccwpck_require__(91269), - TokenExpiredError: __nccwpck_require__(41241), + decode: __nccwpck_require__(83499), + verify: __nccwpck_require__(95728), + sign: __nccwpck_require__(28724), + JsonWebTokenError: __nccwpck_require__(91892), + NotBeforeError: __nccwpck_require__(44817), + TokenExpiredError: __nccwpck_require__(88013), }; /***/ }), -/***/ 26248: +/***/ 91892: /***/ ((module) => { var JsonWebTokenError = function (message, error) { @@ -22454,10 +22589,10 @@ module.exports = JsonWebTokenError; /***/ }), -/***/ 91269: +/***/ 44817: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var JsonWebTokenError = __nccwpck_require__(26248); +var JsonWebTokenError = __nccwpck_require__(91892); var NotBeforeError = function (message, date) { JsonWebTokenError.call(this, message); @@ -22473,10 +22608,10 @@ module.exports = NotBeforeError; /***/ }), -/***/ 41241: +/***/ 88013: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var JsonWebTokenError = __nccwpck_require__(26248); +var JsonWebTokenError = __nccwpck_require__(91892); var TokenExpiredError = function (message, expiredAt) { JsonWebTokenError.call(this, message); @@ -22492,40 +22627,40 @@ module.exports = TokenExpiredError; /***/ }), -/***/ 51136: +/***/ 86988: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const semver = __nccwpck_require__(62088); +const semver = __nccwpck_require__(24493); module.exports = semver.satisfies(process.version, '>=15.7.0'); /***/ }), -/***/ 3948: +/***/ 61344: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var semver = __nccwpck_require__(62088); +var semver = __nccwpck_require__(24493); module.exports = semver.satisfies(process.version, '^6.12.0 || >=8.0.0'); /***/ }), -/***/ 45318: +/***/ 31202: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const semver = __nccwpck_require__(62088); +const semver = __nccwpck_require__(24493); module.exports = semver.satisfies(process.version, '>=16.9.0'); /***/ }), -/***/ 96688: +/***/ 42692: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var ms = __nccwpck_require__(70744); +var ms = __nccwpck_require__(26647); module.exports = function (time, iat) { var timestamp = iat || Math.floor(Date.now() / 1000); @@ -22546,11 +22681,11 @@ module.exports = function (time, iat) { /***/ }), -/***/ 91006: +/***/ 13578: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const ASYMMETRIC_KEY_DETAILS_SUPPORTED = __nccwpck_require__(51136); -const RSA_PSS_KEY_DETAILS_SUPPORTED = __nccwpck_require__(45318); +const ASYMMETRIC_KEY_DETAILS_SUPPORTED = __nccwpck_require__(86988); +const RSA_PSS_KEY_DETAILS_SUPPORTED = __nccwpck_require__(31202); const allowedAlgorithmsForKeys = { 'ec': ['ES256', 'ES384', 'ES512'], @@ -22619,20 +22754,20 @@ module.exports = function(algorithm, key) { /***/ }), -/***/ 14912: +/***/ 28724: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const timespan = __nccwpck_require__(96688); -const PS_SUPPORTED = __nccwpck_require__(3948); -const validateAsymmetricKey = __nccwpck_require__(91006); -const jws = __nccwpck_require__(33324); -const includes = __nccwpck_require__(46248); -const isBoolean = __nccwpck_require__(1999); -const isInteger = __nccwpck_require__(39841); -const isNumber = __nccwpck_require__(80116); -const isPlainObject = __nccwpck_require__(29888); -const isString = __nccwpck_require__(56172); -const once = __nccwpck_require__(82192); +const timespan = __nccwpck_require__(42692); +const PS_SUPPORTED = __nccwpck_require__(61344); +const validateAsymmetricKey = __nccwpck_require__(13578); +const jws = __nccwpck_require__(63922); +const includes = __nccwpck_require__(95252); +const isBoolean = __nccwpck_require__(92771); +const isInteger = __nccwpck_require__(74367); +const isNumber = __nccwpck_require__(95011); +const isPlainObject = __nccwpck_require__(65341); +const isString = __nccwpck_require__(5250); +const once = __nccwpck_require__(63839); const { KeyObject, createSecretKey, createPrivateKey } = __nccwpck_require__(76982) const SUPPORTED_ALGS = ['RS256', 'RS384', 'RS512', 'ES256', 'ES384', 'ES512', 'HS256', 'HS384', 'HS512', 'none']; @@ -22879,17 +23014,17 @@ module.exports = function (payload, secretOrPrivateKey, options, callback) { /***/ }), -/***/ 60772: +/***/ 95728: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const JsonWebTokenError = __nccwpck_require__(26248); -const NotBeforeError = __nccwpck_require__(91269); -const TokenExpiredError = __nccwpck_require__(41241); -const decode = __nccwpck_require__(92047); -const timespan = __nccwpck_require__(96688); -const validateAsymmetricKey = __nccwpck_require__(91006); -const PS_SUPPORTED = __nccwpck_require__(3948); -const jws = __nccwpck_require__(33324); +const JsonWebTokenError = __nccwpck_require__(91892); +const NotBeforeError = __nccwpck_require__(44817); +const TokenExpiredError = __nccwpck_require__(88013); +const decode = __nccwpck_require__(83499); +const timespan = __nccwpck_require__(42692); +const validateAsymmetricKey = __nccwpck_require__(13578); +const PS_SUPPORTED = __nccwpck_require__(61344); +const jws = __nccwpck_require__(63922); const {KeyObject, createSecretKey, createPublicKey} = __nccwpck_require__(76982); const PUB_KEY_ALGS = ['RS256', 'RS384', 'RS512']; @@ -23149,12 +23284,12 @@ module.exports = function (jwtString, secretOrPublicKey, options, callback) { /***/ }), -/***/ 38622: +/***/ 56308: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var Buffer = (__nccwpck_require__(93058).Buffer); +var Buffer = (__nccwpck_require__(65249).Buffer); var crypto = __nccwpck_require__(76982); -var formatEcdsa = __nccwpck_require__(325); +var formatEcdsa = __nccwpck_require__(91454); var util = __nccwpck_require__(39023); var MSG_INVALID_ALGORITHM = '"%s" is not a valid algorithm.\n Supported algorithms are:\n "HS256", "HS384", "HS512", "RS256", "RS384", "RS512", "PS256", "PS384", "PS512", "ES256", "ES384", "ES512" and "none".' @@ -23297,7 +23432,7 @@ var timingSafeEqual = 'timingSafeEqual' in crypto ? function timingSafeEqual(a, return crypto.timingSafeEqual(a, b) } : function timingSafeEqual(a, b) { if (!bufferEqual) { - bufferEqual = __nccwpck_require__(39732); + bufferEqual = __nccwpck_require__(30715); } return bufferEqual(a, b) @@ -23407,7 +23542,7 @@ module.exports = function jwa(algorithm) { es: createECDSAVerifer, none: createNoneVerifier, } - var match = algorithm.match(/^(RS|PS|ES|HS)(256|384|512)$|^(none)$/i); + var match = algorithm.match(/^(RS|PS|ES|HS)(256|384|512)$|^(none)$/); if (!match) throw typeError(MSG_INVALID_ALGORITHM, algorithm); var algo = (match[1] || match[3]).toLowerCase(); @@ -23422,12 +23557,12 @@ module.exports = function jwa(algorithm) { /***/ }), -/***/ 33324: +/***/ 63922: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { /*global exports*/ -var SignStream = __nccwpck_require__(78600); -var VerifyStream = __nccwpck_require__(4368); +var SignStream = __nccwpck_require__(60414); +var VerifyStream = __nccwpck_require__(9470); var ALGORITHMS = [ 'HS256', 'HS384', 'HS512', @@ -23451,11 +23586,11 @@ exports.createVerify = function createVerify(opts) { /***/ }), -/***/ 41831: +/***/ 98353: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /*global module, process*/ -var Buffer = (__nccwpck_require__(93058).Buffer); +var Buffer = (__nccwpck_require__(65249).Buffer); var Stream = __nccwpck_require__(2203); var util = __nccwpck_require__(39023); @@ -23513,15 +23648,15 @@ module.exports = DataStream; /***/ }), -/***/ 78600: +/***/ 60414: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /*global module*/ -var Buffer = (__nccwpck_require__(93058).Buffer); -var DataStream = __nccwpck_require__(41831); -var jwa = __nccwpck_require__(38622); +var Buffer = (__nccwpck_require__(65249).Buffer); +var DataStream = __nccwpck_require__(98353); +var jwa = __nccwpck_require__(56308); var Stream = __nccwpck_require__(2203); -var toString = __nccwpck_require__(95126); +var toString = __nccwpck_require__(82176); var util = __nccwpck_require__(39023); function base64url(string, encoding) { @@ -23603,7 +23738,7 @@ module.exports = SignStream; /***/ }), -/***/ 95126: +/***/ 82176: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /*global module*/ @@ -23620,15 +23755,15 @@ module.exports = function toString(obj) { /***/ }), -/***/ 4368: +/***/ 9470: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /*global module*/ -var Buffer = (__nccwpck_require__(93058).Buffer); -var DataStream = __nccwpck_require__(41831); -var jwa = __nccwpck_require__(38622); +var Buffer = (__nccwpck_require__(65249).Buffer); +var DataStream = __nccwpck_require__(98353); +var jwa = __nccwpck_require__(56308); var Stream = __nccwpck_require__(2203); -var toString = __nccwpck_require__(95126); +var toString = __nccwpck_require__(82176); var util = __nccwpck_require__(39023); var JWS_REGEX = /^[a-zA-Z0-9\-_]+?\.[a-zA-Z0-9\-_]+?\.([a-zA-Z0-9\-_]+)?$/; @@ -23752,11 +23887,11 @@ module.exports = VerifyStream; /***/ }), -/***/ 32126: +/***/ 6889: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { var util = __nccwpck_require__(39023); -var PassThrough = __nccwpck_require__(1835); +var PassThrough = __nccwpck_require__(26614); module.exports = { Readable: Readable, @@ -23813,2889 +23948,2906 @@ function Writable(fn, options) { /***/ }), -/***/ 34793: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - -// Copyright Joyent, Inc. and other Node contributors. -// -// Permission is hereby granted, free of charge, to any person obtaining a -// copy of this software and associated documentation files (the -// "Software"), to deal in the Software without restriction, including -// without limitation the rights to use, copy, modify, merge, publish, -// distribute, sublicense, and/or sell copies of the Software, and to permit -// persons to whom the Software is furnished to do so, subject to the -// following conditions: -// -// The above copyright notice and this permission notice shall be included -// in all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN -// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE -// USE OR OTHER DEALINGS IN THE SOFTWARE. +/***/ 95252: +/***/ ((module) => { -// a duplex stream is just a stream that is both readable and writable. -// Since JS doesn't have multiple prototypal inheritance, this class -// prototypally inherits from Readable, and then parasitically from -// Writable. +/** + * lodash (Custom Build) + * Build: `lodash modularize exports="npm" -o ./` + * Copyright jQuery Foundation and other contributors + * Released under MIT license + * Based on Underscore.js 1.8.3 + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + */ +/** Used as references for various `Number` constants. */ +var INFINITY = 1 / 0, + MAX_SAFE_INTEGER = 9007199254740991, + MAX_INTEGER = 1.7976931348623157e+308, + NAN = 0 / 0; +/** `Object#toString` result references. */ +var argsTag = '[object Arguments]', + funcTag = '[object Function]', + genTag = '[object GeneratorFunction]', + stringTag = '[object String]', + symbolTag = '[object Symbol]'; -/**/ +/** Used to match leading and trailing whitespace. */ +var reTrim = /^\s+|\s+$/g; -var pna = __nccwpck_require__(41564); -/**/ +/** Used to detect bad signed hexadecimal string values. */ +var reIsBadHex = /^[-+]0x[0-9a-f]+$/i; -/**/ -var objectKeys = Object.keys || function (obj) { - var keys = []; - for (var key in obj) { - keys.push(key); - }return keys; -}; -/**/ +/** Used to detect binary string values. */ +var reIsBinary = /^0b[01]+$/i; -module.exports = Duplex; +/** Used to detect octal string values. */ +var reIsOctal = /^0o[0-7]+$/i; -/**/ -var util = Object.create(__nccwpck_require__(45481)); -util.inherits = __nccwpck_require__(39598); -/**/ +/** Used to detect unsigned integer values. */ +var reIsUint = /^(?:0|[1-9]\d*)$/; -var Readable = __nccwpck_require__(74559); -var Writable = __nccwpck_require__(54579); +/** Built-in method references without a dependency on `root`. */ +var freeParseInt = parseInt; -util.inherits(Duplex, Readable); +/** + * A specialized version of `_.map` for arrays without support for iteratee + * shorthands. + * + * @private + * @param {Array} [array] The array to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @returns {Array} Returns the new mapped array. + */ +function arrayMap(array, iteratee) { + var index = -1, + length = array ? array.length : 0, + result = Array(length); -{ - // avoid scope creep, the keys array can then be collected - var keys = objectKeys(Writable.prototype); - for (var v = 0; v < keys.length; v++) { - var method = keys[v]; - if (!Duplex.prototype[method]) Duplex.prototype[method] = Writable.prototype[method]; + while (++index < length) { + result[index] = iteratee(array[index], index, array); } + return result; } -function Duplex(options) { - if (!(this instanceof Duplex)) return new Duplex(options); - - Readable.call(this, options); - Writable.call(this, options); - - if (options && options.readable === false) this.readable = false; - - if (options && options.writable === false) this.writable = false; - - this.allowHalfOpen = true; - if (options && options.allowHalfOpen === false) this.allowHalfOpen = false; +/** + * The base implementation of `_.findIndex` and `_.findLastIndex` without + * support for iteratee shorthands. + * + * @private + * @param {Array} array The array to inspect. + * @param {Function} predicate The function invoked per iteration. + * @param {number} fromIndex The index to search from. + * @param {boolean} [fromRight] Specify iterating from right to left. + * @returns {number} Returns the index of the matched value, else `-1`. + */ +function baseFindIndex(array, predicate, fromIndex, fromRight) { + var length = array.length, + index = fromIndex + (fromRight ? 1 : -1); - this.once('end', onend); + while ((fromRight ? index-- : ++index < length)) { + if (predicate(array[index], index, array)) { + return index; + } + } + return -1; } -Object.defineProperty(Duplex.prototype, 'writableHighWaterMark', { - // making it explicit this property is not enumerable - // because otherwise some prototype manipulation in - // userland will fail - enumerable: false, - get: function () { - return this._writableState.highWaterMark; +/** + * The base implementation of `_.indexOf` without `fromIndex` bounds checks. + * + * @private + * @param {Array} array The array to inspect. + * @param {*} value The value to search for. + * @param {number} fromIndex The index to search from. + * @returns {number} Returns the index of the matched value, else `-1`. + */ +function baseIndexOf(array, value, fromIndex) { + if (value !== value) { + return baseFindIndex(array, baseIsNaN, fromIndex); } -}); - -// the no-half-open enforcer -function onend() { - // if we allow half-open state, or if the writable side ended, - // then we're ok. - if (this.allowHalfOpen || this._writableState.ended) return; + var index = fromIndex - 1, + length = array.length; - // no more data can be written. - // But allow more writes to happen in this tick. - pna.nextTick(onEndNT, this); + while (++index < length) { + if (array[index] === value) { + return index; + } + } + return -1; } -function onEndNT(self) { - self.end(); +/** + * The base implementation of `_.isNaN` without support for number objects. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is `NaN`, else `false`. + */ +function baseIsNaN(value) { + return value !== value; } -Object.defineProperty(Duplex.prototype, 'destroyed', { - get: function () { - if (this._readableState === undefined || this._writableState === undefined) { - return false; - } - return this._readableState.destroyed && this._writableState.destroyed; - }, - set: function (value) { - // we ignore the value if the stream - // has not been initialized yet - if (this._readableState === undefined || this._writableState === undefined) { - return; - } +/** + * The base implementation of `_.times` without support for iteratee shorthands + * or max array length checks. + * + * @private + * @param {number} n The number of times to invoke `iteratee`. + * @param {Function} iteratee The function invoked per iteration. + * @returns {Array} Returns the array of results. + */ +function baseTimes(n, iteratee) { + var index = -1, + result = Array(n); - // backward compatibility, the user is explicitly - // managing destroyed - this._readableState.destroyed = value; - this._writableState.destroyed = value; + while (++index < n) { + result[index] = iteratee(index); } -}); + return result; +} -Duplex.prototype._destroy = function (err, cb) { - this.push(null); - this.end(); +/** + * The base implementation of `_.values` and `_.valuesIn` which creates an + * array of `object` property values corresponding to the property names + * of `props`. + * + * @private + * @param {Object} object The object to query. + * @param {Array} props The property names to get values for. + * @returns {Object} Returns the array of property values. + */ +function baseValues(object, props) { + return arrayMap(props, function(key) { + return object[key]; + }); +} - pna.nextTick(cb, err); -}; +/** + * Creates a unary function that invokes `func` with its argument transformed. + * + * @private + * @param {Function} func The function to wrap. + * @param {Function} transform The argument transform. + * @returns {Function} Returns the new function. + */ +function overArg(func, transform) { + return function(arg) { + return func(transform(arg)); + }; +} -/***/ }), +/** Used for built-in method references. */ +var objectProto = Object.prototype; -/***/ 72029: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/** Used to check objects for own properties. */ +var hasOwnProperty = objectProto.hasOwnProperty; -// Copyright Joyent, Inc. and other Node contributors. -// -// Permission is hereby granted, free of charge, to any person obtaining a -// copy of this software and associated documentation files (the -// "Software"), to deal in the Software without restriction, including -// without limitation the rights to use, copy, modify, merge, publish, -// distribute, sublicense, and/or sell copies of the Software, and to permit -// persons to whom the Software is furnished to do so, subject to the -// following conditions: -// -// The above copyright notice and this permission notice shall be included -// in all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN -// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE -// USE OR OTHER DEALINGS IN THE SOFTWARE. +/** + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; -// a passthrough stream. -// basically just the most minimal sort of Transform stream. -// Every written chunk gets output as-is. +/** Built-in value references. */ +var propertyIsEnumerable = objectProto.propertyIsEnumerable; +/* Built-in method references for those with the same name as other `lodash` methods. */ +var nativeKeys = overArg(Object.keys, Object), + nativeMax = Math.max; +/** + * Creates an array of the enumerable property names of the array-like `value`. + * + * @private + * @param {*} value The value to query. + * @param {boolean} inherited Specify returning inherited property names. + * @returns {Array} Returns the array of property names. + */ +function arrayLikeKeys(value, inherited) { + // Safari 8.1 makes `arguments.callee` enumerable in strict mode. + // Safari 9 makes `arguments.length` enumerable in strict mode. + var result = (isArray(value) || isArguments(value)) + ? baseTimes(value.length, String) + : []; -module.exports = PassThrough; + var length = result.length, + skipIndexes = !!length; -var Transform = __nccwpck_require__(69343); + for (var key in value) { + if ((inherited || hasOwnProperty.call(value, key)) && + !(skipIndexes && (key == 'length' || isIndex(key, length)))) { + result.push(key); + } + } + return result; +} -/**/ -var util = Object.create(__nccwpck_require__(45481)); -util.inherits = __nccwpck_require__(39598); -/**/ +/** + * The base implementation of `_.keys` which doesn't treat sparse arrays as dense. + * + * @private + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property names. + */ +function baseKeys(object) { + if (!isPrototype(object)) { + return nativeKeys(object); + } + var result = []; + for (var key in Object(object)) { + if (hasOwnProperty.call(object, key) && key != 'constructor') { + result.push(key); + } + } + return result; +} -util.inherits(PassThrough, Transform); +/** + * Checks if `value` is a valid array-like index. + * + * @private + * @param {*} value The value to check. + * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index. + * @returns {boolean} Returns `true` if `value` is a valid index, else `false`. + */ +function isIndex(value, length) { + length = length == null ? MAX_SAFE_INTEGER : length; + return !!length && + (typeof value == 'number' || reIsUint.test(value)) && + (value > -1 && value % 1 == 0 && value < length); +} -function PassThrough(options) { - if (!(this instanceof PassThrough)) return new PassThrough(options); +/** + * Checks if `value` is likely a prototype object. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a prototype, else `false`. + */ +function isPrototype(value) { + var Ctor = value && value.constructor, + proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto; - Transform.call(this, options); + return value === proto; } -PassThrough.prototype._transform = function (chunk, encoding, cb) { - cb(null, chunk); -}; +/** + * Checks if `value` is in `collection`. If `collection` is a string, it's + * checked for a substring of `value`, otherwise + * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) + * is used for equality comparisons. If `fromIndex` is negative, it's used as + * the offset from the end of `collection`. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Collection + * @param {Array|Object|string} collection The collection to inspect. + * @param {*} value The value to search for. + * @param {number} [fromIndex=0] The index to search from. + * @param- {Object} [guard] Enables use as an iteratee for methods like `_.reduce`. + * @returns {boolean} Returns `true` if `value` is found, else `false`. + * @example + * + * _.includes([1, 2, 3], 1); + * // => true + * + * _.includes([1, 2, 3], 1, 2); + * // => false + * + * _.includes({ 'a': 1, 'b': 2 }, 1); + * // => true + * + * _.includes('abcd', 'bc'); + * // => true + */ +function includes(collection, value, fromIndex, guard) { + collection = isArrayLike(collection) ? collection : values(collection); + fromIndex = (fromIndex && !guard) ? toInteger(fromIndex) : 0; -/***/ }), + var length = collection.length; + if (fromIndex < 0) { + fromIndex = nativeMax(length + fromIndex, 0); + } + return isString(collection) + ? (fromIndex <= length && collection.indexOf(value, fromIndex) > -1) + : (!!length && baseIndexOf(collection, value, fromIndex) > -1); +} -/***/ 74559: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/** + * Checks if `value` is likely an `arguments` object. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an `arguments` object, + * else `false`. + * @example + * + * _.isArguments(function() { return arguments; }()); + * // => true + * + * _.isArguments([1, 2, 3]); + * // => false + */ +function isArguments(value) { + // Safari 8.1 makes `arguments.callee` enumerable in strict mode. + return isArrayLikeObject(value) && hasOwnProperty.call(value, 'callee') && + (!propertyIsEnumerable.call(value, 'callee') || objectToString.call(value) == argsTag); +} -// Copyright Joyent, Inc. and other Node contributors. -// -// Permission is hereby granted, free of charge, to any person obtaining a -// copy of this software and associated documentation files (the -// "Software"), to deal in the Software without restriction, including -// without limitation the rights to use, copy, modify, merge, publish, -// distribute, sublicense, and/or sell copies of the Software, and to permit -// persons to whom the Software is furnished to do so, subject to the -// following conditions: -// -// The above copyright notice and this permission notice shall be included -// in all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN -// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE -// USE OR OTHER DEALINGS IN THE SOFTWARE. +/** + * Checks if `value` is classified as an `Array` object. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an array, else `false`. + * @example + * + * _.isArray([1, 2, 3]); + * // => true + * + * _.isArray(document.body.children); + * // => false + * + * _.isArray('abc'); + * // => false + * + * _.isArray(_.noop); + * // => false + */ +var isArray = Array.isArray; +/** + * Checks if `value` is array-like. A value is considered array-like if it's + * not a function and has a `value.length` that's an integer greater than or + * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is array-like, else `false`. + * @example + * + * _.isArrayLike([1, 2, 3]); + * // => true + * + * _.isArrayLike(document.body.children); + * // => true + * + * _.isArrayLike('abc'); + * // => true + * + * _.isArrayLike(_.noop); + * // => false + */ +function isArrayLike(value) { + return value != null && isLength(value.length) && !isFunction(value); +} +/** + * This method is like `_.isArrayLike` except that it also checks if `value` + * is an object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an array-like object, + * else `false`. + * @example + * + * _.isArrayLikeObject([1, 2, 3]); + * // => true + * + * _.isArrayLikeObject(document.body.children); + * // => true + * + * _.isArrayLikeObject('abc'); + * // => false + * + * _.isArrayLikeObject(_.noop); + * // => false + */ +function isArrayLikeObject(value) { + return isObjectLike(value) && isArrayLike(value); +} -/**/ +/** + * Checks if `value` is classified as a `Function` object. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a function, else `false`. + * @example + * + * _.isFunction(_); + * // => true + * + * _.isFunction(/abc/); + * // => false + */ +function isFunction(value) { + // The use of `Object#toString` avoids issues with the `typeof` operator + // in Safari 8-9 which returns 'object' for typed array and other constructors. + var tag = isObject(value) ? objectToString.call(value) : ''; + return tag == funcTag || tag == genTag; +} -var pna = __nccwpck_require__(41564); -/**/ +/** + * Checks if `value` is a valid array-like length. + * + * **Note:** This method is loosely based on + * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a valid length, else `false`. + * @example + * + * _.isLength(3); + * // => true + * + * _.isLength(Number.MIN_VALUE); + * // => false + * + * _.isLength(Infinity); + * // => false + * + * _.isLength('3'); + * // => false + */ +function isLength(value) { + return typeof value == 'number' && + value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; +} -module.exports = Readable; +/** + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an object, else `false`. + * @example + * + * _.isObject({}); + * // => true + * + * _.isObject([1, 2, 3]); + * // => true + * + * _.isObject(_.noop); + * // => true + * + * _.isObject(null); + * // => false + */ +function isObject(value) { + var type = typeof value; + return !!value && (type == 'object' || type == 'function'); +} -/**/ -var isArray = __nccwpck_require__(82513); -/**/ +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} -/**/ -var Duplex; -/**/ +/** + * Checks if `value` is classified as a `String` primitive or object. + * + * @static + * @since 0.1.0 + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a string, else `false`. + * @example + * + * _.isString('abc'); + * // => true + * + * _.isString(1); + * // => false + */ +function isString(value) { + return typeof value == 'string' || + (!isArray(value) && isObjectLike(value) && objectToString.call(value) == stringTag); +} -Readable.ReadableState = ReadableState; +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} -/**/ -var EE = (__nccwpck_require__(24434).EventEmitter); +/** + * Converts `value` to a finite number. + * + * @static + * @memberOf _ + * @since 4.12.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {number} Returns the converted number. + * @example + * + * _.toFinite(3.2); + * // => 3.2 + * + * _.toFinite(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toFinite(Infinity); + * // => 1.7976931348623157e+308 + * + * _.toFinite('3.2'); + * // => 3.2 + */ +function toFinite(value) { + if (!value) { + return value === 0 ? value : 0; + } + value = toNumber(value); + if (value === INFINITY || value === -INFINITY) { + var sign = (value < 0 ? -1 : 1); + return sign * MAX_INTEGER; + } + return value === value ? value : 0; +} -var EElistenerCount = function (emitter, type) { - return emitter.listeners(type).length; -}; -/**/ +/** + * Converts `value` to an integer. + * + * **Note:** This method is loosely based on + * [`ToInteger`](http://www.ecma-international.org/ecma-262/7.0/#sec-tointeger). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {number} Returns the converted integer. + * @example + * + * _.toInteger(3.2); + * // => 3 + * + * _.toInteger(Number.MIN_VALUE); + * // => 0 + * + * _.toInteger(Infinity); + * // => 1.7976931348623157e+308 + * + * _.toInteger('3.2'); + * // => 3 + */ +function toInteger(value) { + var result = toFinite(value), + remainder = result % 1; -/**/ -var Stream = __nccwpck_require__(87137); -/**/ + return result === result ? (remainder ? result - remainder : result) : 0; +} -/**/ +/** + * Converts `value` to a number. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to process. + * @returns {number} Returns the number. + * @example + * + * _.toNumber(3.2); + * // => 3.2 + * + * _.toNumber(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toNumber(Infinity); + * // => Infinity + * + * _.toNumber('3.2'); + * // => 3.2 + */ +function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } + if (isObject(value)) { + var other = typeof value.valueOf == 'function' ? value.valueOf() : value; + value = isObject(other) ? (other + '') : other; + } + if (typeof value != 'string') { + return value === 0 ? value : +value; + } + value = value.replace(reTrim, ''); + var isBinary = reIsBinary.test(value); + return (isBinary || reIsOctal.test(value)) + ? freeParseInt(value.slice(2), isBinary ? 2 : 8) + : (reIsBadHex.test(value) ? NAN : +value); +} -var Buffer = (__nccwpck_require__(13644).Buffer); -var OurUint8Array = (typeof global !== 'undefined' ? global : typeof window !== 'undefined' ? window : typeof self !== 'undefined' ? self : {}).Uint8Array || function () {}; -function _uint8ArrayToBuffer(chunk) { - return Buffer.from(chunk); +/** + * Creates an array of the own enumerable property names of `object`. + * + * **Note:** Non-object values are coerced to objects. See the + * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys) + * for more details. + * + * @static + * @since 0.1.0 + * @memberOf _ + * @category Object + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property names. + * @example + * + * function Foo() { + * this.a = 1; + * this.b = 2; + * } + * + * Foo.prototype.c = 3; + * + * _.keys(new Foo); + * // => ['a', 'b'] (iteration order is not guaranteed) + * + * _.keys('hi'); + * // => ['0', '1'] + */ +function keys(object) { + return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object); } -function _isUint8Array(obj) { - return Buffer.isBuffer(obj) || obj instanceof OurUint8Array; + +/** + * Creates an array of the own enumerable string keyed property values of `object`. + * + * **Note:** Non-object values are coerced to objects. + * + * @static + * @since 0.1.0 + * @memberOf _ + * @category Object + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property values. + * @example + * + * function Foo() { + * this.a = 1; + * this.b = 2; + * } + * + * Foo.prototype.c = 3; + * + * _.values(new Foo); + * // => [1, 2] (iteration order is not guaranteed) + * + * _.values('hi'); + * // => ['h', 'i'] + */ +function values(object) { + return object ? baseValues(object, keys(object)) : []; } -/**/ +module.exports = includes; -/**/ -var util = Object.create(__nccwpck_require__(45481)); -util.inherits = __nccwpck_require__(39598); -/**/ -/**/ -var debugUtil = __nccwpck_require__(39023); -var debug = void 0; -if (debugUtil && debugUtil.debuglog) { - debug = debugUtil.debuglog('stream'); -} else { - debug = function () {}; -} -/**/ +/***/ }), -var BufferList = __nccwpck_require__(46127); -var destroyImpl = __nccwpck_require__(91031); -var StringDecoder; +/***/ 92771: +/***/ ((module) => { -util.inherits(Readable, Stream); +/** + * lodash 3.0.3 (Custom Build) + * Build: `lodash modularize exports="npm" -o ./` + * Copyright 2012-2016 The Dojo Foundation + * Based on Underscore.js 1.8.3 + * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + * Available under MIT license + */ -var kProxyEvents = ['error', 'close', 'destroy', 'pause', 'resume']; +/** `Object#toString` result references. */ +var boolTag = '[object Boolean]'; -function prependListener(emitter, event, fn) { - // Sadly this is not cacheable as some libraries bundle their own - // event emitter implementation with them. - if (typeof emitter.prependListener === 'function') return emitter.prependListener(event, fn); +/** Used for built-in method references. */ +var objectProto = Object.prototype; - // This is a hack to make sure that our error handler is attached before any - // userland ones. NEVER DO THIS. This is here only because this code needs - // to continue to work with older versions of Node.js that do not include - // the prependListener() method. The goal is to eventually remove this hack. - if (!emitter._events || !emitter._events[event]) emitter.on(event, fn);else if (isArray(emitter._events[event])) emitter._events[event].unshift(fn);else emitter._events[event] = [fn, emitter._events[event]]; +/** + * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; + +/** + * Checks if `value` is classified as a boolean primitive or object. + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @example + * + * _.isBoolean(false); + * // => true + * + * _.isBoolean(null); + * // => false + */ +function isBoolean(value) { + return value === true || value === false || + (isObjectLike(value) && objectToString.call(value) == boolTag); } -function ReadableState(options, stream) { - Duplex = Duplex || __nccwpck_require__(34793); +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} - options = options || {}; +module.exports = isBoolean; - // Duplex streams are both readable and writable, but share - // the same options object. - // However, some cases require setting options to different - // values for the readable and the writable sides of the duplex stream. - // These options can be provided separately as readableXXX and writableXXX. - var isDuplex = stream instanceof Duplex; - // object stream flag. Used to make read(n) ignore n and to - // make all the buffer merging and length checks go away - this.objectMode = !!options.objectMode; +/***/ }), - if (isDuplex) this.objectMode = this.objectMode || !!options.readableObjectMode; - - // the point at which it stops calling _read() to fill the buffer - // Note: 0 is a valid value, means "don't call _read preemptively ever" - var hwm = options.highWaterMark; - var readableHwm = options.readableHighWaterMark; - var defaultHwm = this.objectMode ? 16 : 16 * 1024; - - if (hwm || hwm === 0) this.highWaterMark = hwm;else if (isDuplex && (readableHwm || readableHwm === 0)) this.highWaterMark = readableHwm;else this.highWaterMark = defaultHwm; - - // cast to ints. - this.highWaterMark = Math.floor(this.highWaterMark); - - // A linked list is used to store data chunks instead of an array because the - // linked list can remove elements from the beginning faster than - // array.shift() - this.buffer = new BufferList(); - this.length = 0; - this.pipes = null; - this.pipesCount = 0; - this.flowing = null; - this.ended = false; - this.endEmitted = false; - this.reading = false; - - // a flag to be able to tell if the event 'readable'/'data' is emitted - // immediately, or on a later tick. We set this to true at first, because - // any actions that shouldn't happen until "later" should generally also - // not happen before the first read call. - this.sync = true; - - // whenever we return null, then we set a flag to say - // that we're awaiting a 'readable' event emission. - this.needReadable = false; - this.emittedReadable = false; - this.readableListening = false; - this.resumeScheduled = false; - - // has it been destroyed - this.destroyed = false; - - // Crypto is kind of old and crusty. Historically, its default string - // encoding is 'binary' so we have to make this configurable. - // Everything else in the universe uses 'utf8', though. - this.defaultEncoding = options.defaultEncoding || 'utf8'; - - // the number of writers that are awaiting a drain event in .pipe()s - this.awaitDrain = 0; - - // if true, a maybeReadMore has been scheduled - this.readingMore = false; - - this.decoder = null; - this.encoding = null; - if (options.encoding) { - if (!StringDecoder) StringDecoder = (__nccwpck_require__(50176)/* .StringDecoder */ .I); - this.decoder = new StringDecoder(options.encoding); - this.encoding = options.encoding; - } -} - -function Readable(options) { - Duplex = Duplex || __nccwpck_require__(34793); - - if (!(this instanceof Readable)) return new Readable(options); - - this._readableState = new ReadableState(options, this); - - // legacy - this.readable = true; - - if (options) { - if (typeof options.read === 'function') this._read = options.read; - - if (typeof options.destroy === 'function') this._destroy = options.destroy; - } - - Stream.call(this); -} - -Object.defineProperty(Readable.prototype, 'destroyed', { - get: function () { - if (this._readableState === undefined) { - return false; - } - return this._readableState.destroyed; - }, - set: function (value) { - // we ignore the value if the stream - // has not been initialized yet - if (!this._readableState) { - return; - } - - // backward compatibility, the user is explicitly - // managing destroyed - this._readableState.destroyed = value; - } -}); - -Readable.prototype.destroy = destroyImpl.destroy; -Readable.prototype._undestroy = destroyImpl.undestroy; -Readable.prototype._destroy = function (err, cb) { - this.push(null); - cb(err); -}; - -// Manually shove something into the read() buffer. -// This returns true if the highWaterMark has not been hit yet, -// similar to how Writable.write() returns true if you should -// write() some more. -Readable.prototype.push = function (chunk, encoding) { - var state = this._readableState; - var skipChunkCheck; - - if (!state.objectMode) { - if (typeof chunk === 'string') { - encoding = encoding || state.defaultEncoding; - if (encoding !== state.encoding) { - chunk = Buffer.from(chunk, encoding); - encoding = ''; - } - skipChunkCheck = true; - } - } else { - skipChunkCheck = true; - } - - return readableAddChunk(this, chunk, encoding, false, skipChunkCheck); -}; - -// Unshift should *always* be something directly out of read() -Readable.prototype.unshift = function (chunk) { - return readableAddChunk(this, chunk, null, true, false); -}; - -function readableAddChunk(stream, chunk, encoding, addToFront, skipChunkCheck) { - var state = stream._readableState; - if (chunk === null) { - state.reading = false; - onEofChunk(stream, state); - } else { - var er; - if (!skipChunkCheck) er = chunkInvalid(state, chunk); - if (er) { - stream.emit('error', er); - } else if (state.objectMode || chunk && chunk.length > 0) { - if (typeof chunk !== 'string' && !state.objectMode && Object.getPrototypeOf(chunk) !== Buffer.prototype) { - chunk = _uint8ArrayToBuffer(chunk); - } - - if (addToFront) { - if (state.endEmitted) stream.emit('error', new Error('stream.unshift() after end event'));else addChunk(stream, state, chunk, true); - } else if (state.ended) { - stream.emit('error', new Error('stream.push() after EOF')); - } else { - state.reading = false; - if (state.decoder && !encoding) { - chunk = state.decoder.write(chunk); - if (state.objectMode || chunk.length !== 0) addChunk(stream, state, chunk, false);else maybeReadMore(stream, state); - } else { - addChunk(stream, state, chunk, false); - } - } - } else if (!addToFront) { - state.reading = false; - } - } - - return needMoreData(state); -} - -function addChunk(stream, state, chunk, addToFront) { - if (state.flowing && state.length === 0 && !state.sync) { - stream.emit('data', chunk); - stream.read(0); - } else { - // update the buffer info. - state.length += state.objectMode ? 1 : chunk.length; - if (addToFront) state.buffer.unshift(chunk);else state.buffer.push(chunk); - - if (state.needReadable) emitReadable(stream); - } - maybeReadMore(stream, state); -} - -function chunkInvalid(state, chunk) { - var er; - if (!_isUint8Array(chunk) && typeof chunk !== 'string' && chunk !== undefined && !state.objectMode) { - er = new TypeError('Invalid non-string/buffer chunk'); - } - return er; -} - -// if it's past the high water mark, we can push in some more. -// Also, if we have no data yet, we can stand some -// more bytes. This is to work around cases where hwm=0, -// such as the repl. Also, if the push() triggered a -// readable event, and the user called read(largeNumber) such that -// needReadable was set, then we ought to push more, so that another -// 'readable' event will be triggered. -function needMoreData(state) { - return !state.ended && (state.needReadable || state.length < state.highWaterMark || state.length === 0); -} - -Readable.prototype.isPaused = function () { - return this._readableState.flowing === false; -}; - -// backwards compatibility. -Readable.prototype.setEncoding = function (enc) { - if (!StringDecoder) StringDecoder = (__nccwpck_require__(50176)/* .StringDecoder */ .I); - this._readableState.decoder = new StringDecoder(enc); - this._readableState.encoding = enc; - return this; -}; - -// Don't raise the hwm > 8MB -var MAX_HWM = 0x800000; -function computeNewHighWaterMark(n) { - if (n >= MAX_HWM) { - n = MAX_HWM; - } else { - // Get the next highest power of 2 to prevent increasing hwm excessively in - // tiny amounts - n--; - n |= n >>> 1; - n |= n >>> 2; - n |= n >>> 4; - n |= n >>> 8; - n |= n >>> 16; - n++; - } - return n; -} - -// This function is designed to be inlinable, so please take care when making -// changes to the function body. -function howMuchToRead(n, state) { - if (n <= 0 || state.length === 0 && state.ended) return 0; - if (state.objectMode) return 1; - if (n !== n) { - // Only flow one buffer at a time - if (state.flowing && state.length) return state.buffer.head.data.length;else return state.length; - } - // If we're asking for more than the current hwm, then raise the hwm. - if (n > state.highWaterMark) state.highWaterMark = computeNewHighWaterMark(n); - if (n <= state.length) return n; - // Don't have enough - if (!state.ended) { - state.needReadable = true; - return 0; - } - return state.length; -} - -// you can override either this method, or the async _read(n) below. -Readable.prototype.read = function (n) { - debug('read', n); - n = parseInt(n, 10); - var state = this._readableState; - var nOrig = n; - - if (n !== 0) state.emittedReadable = false; - - // if we're doing read(0) to trigger a readable event, but we - // already have a bunch of data in the buffer, then just trigger - // the 'readable' event and move on. - if (n === 0 && state.needReadable && (state.length >= state.highWaterMark || state.ended)) { - debug('read: emitReadable', state.length, state.ended); - if (state.length === 0 && state.ended) endReadable(this);else emitReadable(this); - return null; - } - - n = howMuchToRead(n, state); - - // if we've ended, and we're now clear, then finish it up. - if (n === 0 && state.ended) { - if (state.length === 0) endReadable(this); - return null; - } - - // All the actual chunk generation logic needs to be - // *below* the call to _read. The reason is that in certain - // synthetic stream cases, such as passthrough streams, _read - // may be a completely synchronous operation which may change - // the state of the read buffer, providing enough data when - // before there was *not* enough. - // - // So, the steps are: - // 1. Figure out what the state of things will be after we do - // a read from the buffer. - // - // 2. If that resulting state will trigger a _read, then call _read. - // Note that this may be asynchronous, or synchronous. Yes, it is - // deeply ugly to write APIs this way, but that still doesn't mean - // that the Readable class should behave improperly, as streams are - // designed to be sync/async agnostic. - // Take note if the _read call is sync or async (ie, if the read call - // has returned yet), so that we know whether or not it's safe to emit - // 'readable' etc. - // - // 3. Actually pull the requested chunks out of the buffer and return. - - // if we need a readable event, then we need to do some reading. - var doRead = state.needReadable; - debug('need readable', doRead); - - // if we currently have less than the highWaterMark, then also read some - if (state.length === 0 || state.length - n < state.highWaterMark) { - doRead = true; - debug('length less than watermark', doRead); - } - - // however, if we've ended, then there's no point, and if we're already - // reading, then it's unnecessary. - if (state.ended || state.reading) { - doRead = false; - debug('reading or ended', doRead); - } else if (doRead) { - debug('do read'); - state.reading = true; - state.sync = true; - // if the length is currently zero, then we *need* a readable event. - if (state.length === 0) state.needReadable = true; - // call internal read method - this._read(state.highWaterMark); - state.sync = false; - // If _read pushed data synchronously, then `reading` will be false, - // and we need to re-evaluate how much data we can return to the user. - if (!state.reading) n = howMuchToRead(nOrig, state); - } - - var ret; - if (n > 0) ret = fromList(n, state);else ret = null; - - if (ret === null) { - state.needReadable = true; - n = 0; - } else { - state.length -= n; - } - - if (state.length === 0) { - // If we have nothing in the buffer, then we want to know - // as soon as we *do* get something into the buffer. - if (!state.ended) state.needReadable = true; - - // If we tried to read() past the EOF, then emit end on the next tick. - if (nOrig !== n && state.ended) endReadable(this); - } - - if (ret !== null) this.emit('data', ret); - - return ret; -}; - -function onEofChunk(stream, state) { - if (state.ended) return; - if (state.decoder) { - var chunk = state.decoder.end(); - if (chunk && chunk.length) { - state.buffer.push(chunk); - state.length += state.objectMode ? 1 : chunk.length; - } - } - state.ended = true; - - // emit 'readable' now to make sure it gets picked up. - emitReadable(stream); -} - -// Don't emit readable right away in sync mode, because this can trigger -// another read() call => stack overflow. This way, it might trigger -// a nextTick recursion warning, but that's not so bad. -function emitReadable(stream) { - var state = stream._readableState; - state.needReadable = false; - if (!state.emittedReadable) { - debug('emitReadable', state.flowing); - state.emittedReadable = true; - if (state.sync) pna.nextTick(emitReadable_, stream);else emitReadable_(stream); - } -} - -function emitReadable_(stream) { - debug('emit readable'); - stream.emit('readable'); - flow(stream); -} - -// at this point, the user has presumably seen the 'readable' event, -// and called read() to consume some data. that may have triggered -// in turn another _read(n) call, in which case reading = true if -// it's in progress. -// However, if we're not ended, or reading, and the length < hwm, -// then go ahead and try to read some more preemptively. -function maybeReadMore(stream, state) { - if (!state.readingMore) { - state.readingMore = true; - pna.nextTick(maybeReadMore_, stream, state); - } -} - -function maybeReadMore_(stream, state) { - var len = state.length; - while (!state.reading && !state.flowing && !state.ended && state.length < state.highWaterMark) { - debug('maybeReadMore read 0'); - stream.read(0); - if (len === state.length) - // didn't get any data, stop spinning. - break;else len = state.length; - } - state.readingMore = false; -} - -// abstract method. to be overridden in specific implementation classes. -// call cb(er, data) where data is <= n in length. -// for virtual (non-string, non-buffer) streams, "length" is somewhat -// arbitrary, and perhaps not very meaningful. -Readable.prototype._read = function (n) { - this.emit('error', new Error('_read() is not implemented')); -}; - -Readable.prototype.pipe = function (dest, pipeOpts) { - var src = this; - var state = this._readableState; - - switch (state.pipesCount) { - case 0: - state.pipes = dest; - break; - case 1: - state.pipes = [state.pipes, dest]; - break; - default: - state.pipes.push(dest); - break; - } - state.pipesCount += 1; - debug('pipe count=%d opts=%j', state.pipesCount, pipeOpts); - - var doEnd = (!pipeOpts || pipeOpts.end !== false) && dest !== process.stdout && dest !== process.stderr; - - var endFn = doEnd ? onend : unpipe; - if (state.endEmitted) pna.nextTick(endFn);else src.once('end', endFn); - - dest.on('unpipe', onunpipe); - function onunpipe(readable, unpipeInfo) { - debug('onunpipe'); - if (readable === src) { - if (unpipeInfo && unpipeInfo.hasUnpiped === false) { - unpipeInfo.hasUnpiped = true; - cleanup(); - } - } - } - - function onend() { - debug('onend'); - dest.end(); - } - - // when the dest drains, it reduces the awaitDrain counter - // on the source. This would be more elegant with a .once() - // handler in flow(), but adding and removing repeatedly is - // too slow. - var ondrain = pipeOnDrain(src); - dest.on('drain', ondrain); - - var cleanedUp = false; - function cleanup() { - debug('cleanup'); - // cleanup event handlers once the pipe is broken - dest.removeListener('close', onclose); - dest.removeListener('finish', onfinish); - dest.removeListener('drain', ondrain); - dest.removeListener('error', onerror); - dest.removeListener('unpipe', onunpipe); - src.removeListener('end', onend); - src.removeListener('end', unpipe); - src.removeListener('data', ondata); - - cleanedUp = true; - - // if the reader is waiting for a drain event from this - // specific writer, then it would cause it to never start - // flowing again. - // So, if this is awaiting a drain, then we just call it now. - // If we don't know, then assume that we are waiting for one. - if (state.awaitDrain && (!dest._writableState || dest._writableState.needDrain)) ondrain(); - } - - // If the user pushes more data while we're writing to dest then we'll end up - // in ondata again. However, we only want to increase awaitDrain once because - // dest will only emit one 'drain' event for the multiple writes. - // => Introduce a guard on increasing awaitDrain. - var increasedAwaitDrain = false; - src.on('data', ondata); - function ondata(chunk) { - debug('ondata'); - increasedAwaitDrain = false; - var ret = dest.write(chunk); - if (false === ret && !increasedAwaitDrain) { - // If the user unpiped during `dest.write()`, it is possible - // to get stuck in a permanently paused state if that write - // also returned false. - // => Check whether `dest` is still a piping destination. - if ((state.pipesCount === 1 && state.pipes === dest || state.pipesCount > 1 && indexOf(state.pipes, dest) !== -1) && !cleanedUp) { - debug('false write response, pause', state.awaitDrain); - state.awaitDrain++; - increasedAwaitDrain = true; - } - src.pause(); - } - } - - // if the dest has an error, then stop piping into it. - // however, don't suppress the throwing behavior for this. - function onerror(er) { - debug('onerror', er); - unpipe(); - dest.removeListener('error', onerror); - if (EElistenerCount(dest, 'error') === 0) dest.emit('error', er); - } - - // Make sure our error handler is attached before userland ones. - prependListener(dest, 'error', onerror); - - // Both close and finish should trigger unpipe, but only once. - function onclose() { - dest.removeListener('finish', onfinish); - unpipe(); - } - dest.once('close', onclose); - function onfinish() { - debug('onfinish'); - dest.removeListener('close', onclose); - unpipe(); - } - dest.once('finish', onfinish); - - function unpipe() { - debug('unpipe'); - src.unpipe(dest); - } - - // tell the dest that it's being piped to - dest.emit('pipe', src); - - // start the flow if it hasn't been started already. - if (!state.flowing) { - debug('pipe resume'); - src.resume(); - } - - return dest; -}; - -function pipeOnDrain(src) { - return function () { - var state = src._readableState; - debug('pipeOnDrain', state.awaitDrain); - if (state.awaitDrain) state.awaitDrain--; - if (state.awaitDrain === 0 && EElistenerCount(src, 'data')) { - state.flowing = true; - flow(src); - } - }; -} - -Readable.prototype.unpipe = function (dest) { - var state = this._readableState; - var unpipeInfo = { hasUnpiped: false }; - - // if we're not piping anywhere, then do nothing. - if (state.pipesCount === 0) return this; - - // just one destination. most common case. - if (state.pipesCount === 1) { - // passed in one, but it's not the right one. - if (dest && dest !== state.pipes) return this; - - if (!dest) dest = state.pipes; - - // got a match. - state.pipes = null; - state.pipesCount = 0; - state.flowing = false; - if (dest) dest.emit('unpipe', this, unpipeInfo); - return this; - } - - // slow case. multiple pipe destinations. - - if (!dest) { - // remove all. - var dests = state.pipes; - var len = state.pipesCount; - state.pipes = null; - state.pipesCount = 0; - state.flowing = false; - - for (var i = 0; i < len; i++) { - dests[i].emit('unpipe', this, { hasUnpiped: false }); - }return this; - } - - // try to find the right one. - var index = indexOf(state.pipes, dest); - if (index === -1) return this; - - state.pipes.splice(index, 1); - state.pipesCount -= 1; - if (state.pipesCount === 1) state.pipes = state.pipes[0]; - - dest.emit('unpipe', this, unpipeInfo); - - return this; -}; - -// set up data events if they are asked for -// Ensure readable listeners eventually get something -Readable.prototype.on = function (ev, fn) { - var res = Stream.prototype.on.call(this, ev, fn); - - if (ev === 'data') { - // Start flowing on next tick if stream isn't explicitly paused - if (this._readableState.flowing !== false) this.resume(); - } else if (ev === 'readable') { - var state = this._readableState; - if (!state.endEmitted && !state.readableListening) { - state.readableListening = state.needReadable = true; - state.emittedReadable = false; - if (!state.reading) { - pna.nextTick(nReadingNextTick, this); - } else if (state.length) { - emitReadable(this); - } - } - } - - return res; -}; -Readable.prototype.addListener = Readable.prototype.on; - -function nReadingNextTick(self) { - debug('readable nexttick read 0'); - self.read(0); -} - -// pause() and resume() are remnants of the legacy readable stream API -// If the user uses them, then switch into old mode. -Readable.prototype.resume = function () { - var state = this._readableState; - if (!state.flowing) { - debug('resume'); - state.flowing = true; - resume(this, state); - } - return this; -}; - -function resume(stream, state) { - if (!state.resumeScheduled) { - state.resumeScheduled = true; - pna.nextTick(resume_, stream, state); - } -} - -function resume_(stream, state) { - if (!state.reading) { - debug('resume read 0'); - stream.read(0); - } - - state.resumeScheduled = false; - state.awaitDrain = 0; - stream.emit('resume'); - flow(stream); - if (state.flowing && !state.reading) stream.read(0); -} - -Readable.prototype.pause = function () { - debug('call pause flowing=%j', this._readableState.flowing); - if (false !== this._readableState.flowing) { - debug('pause'); - this._readableState.flowing = false; - this.emit('pause'); - } - return this; -}; - -function flow(stream) { - var state = stream._readableState; - debug('flow', state.flowing); - while (state.flowing && stream.read() !== null) {} -} - -// wrap an old-style stream as the async data source. -// This is *not* part of the readable stream interface. -// It is an ugly unfortunate mess of history. -Readable.prototype.wrap = function (stream) { - var _this = this; - - var state = this._readableState; - var paused = false; - - stream.on('end', function () { - debug('wrapped end'); - if (state.decoder && !state.ended) { - var chunk = state.decoder.end(); - if (chunk && chunk.length) _this.push(chunk); - } - - _this.push(null); - }); - - stream.on('data', function (chunk) { - debug('wrapped data'); - if (state.decoder) chunk = state.decoder.write(chunk); - - // don't skip over falsy values in objectMode - if (state.objectMode && (chunk === null || chunk === undefined)) return;else if (!state.objectMode && (!chunk || !chunk.length)) return; - - var ret = _this.push(chunk); - if (!ret) { - paused = true; - stream.pause(); - } - }); - - // proxy all the other methods. - // important when wrapping filters and duplexes. - for (var i in stream) { - if (this[i] === undefined && typeof stream[i] === 'function') { - this[i] = function (method) { - return function () { - return stream[method].apply(stream, arguments); - }; - }(i); - } - } +/***/ 74367: +/***/ ((module) => { - // proxy certain important events. - for (var n = 0; n < kProxyEvents.length; n++) { - stream.on(kProxyEvents[n], this.emit.bind(this, kProxyEvents[n])); - } +/** + * lodash (Custom Build) + * Build: `lodash modularize exports="npm" -o ./` + * Copyright jQuery Foundation and other contributors + * Released under MIT license + * Based on Underscore.js 1.8.3 + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + */ - // when we try to consume some more bytes, simply unpause the - // underlying stream. - this._read = function (n) { - debug('wrapped _read', n); - if (paused) { - paused = false; - stream.resume(); - } - }; +/** Used as references for various `Number` constants. */ +var INFINITY = 1 / 0, + MAX_INTEGER = 1.7976931348623157e+308, + NAN = 0 / 0; - return this; -}; +/** `Object#toString` result references. */ +var symbolTag = '[object Symbol]'; -Object.defineProperty(Readable.prototype, 'readableHighWaterMark', { - // making it explicit this property is not enumerable - // because otherwise some prototype manipulation in - // userland will fail - enumerable: false, - get: function () { - return this._readableState.highWaterMark; - } -}); +/** Used to match leading and trailing whitespace. */ +var reTrim = /^\s+|\s+$/g; -// exposed for testing purposes only. -Readable._fromList = fromList; +/** Used to detect bad signed hexadecimal string values. */ +var reIsBadHex = /^[-+]0x[0-9a-f]+$/i; -// Pluck off n bytes from an array of buffers. -// Length is the combined lengths of all the buffers in the list. -// This function is designed to be inlinable, so please take care when making -// changes to the function body. -function fromList(n, state) { - // nothing buffered - if (state.length === 0) return null; +/** Used to detect binary string values. */ +var reIsBinary = /^0b[01]+$/i; - var ret; - if (state.objectMode) ret = state.buffer.shift();else if (!n || n >= state.length) { - // read it all, truncate the list - if (state.decoder) ret = state.buffer.join('');else if (state.buffer.length === 1) ret = state.buffer.head.data;else ret = state.buffer.concat(state.length); - state.buffer.clear(); - } else { - // read part of list - ret = fromListPartial(n, state.buffer, state.decoder); - } +/** Used to detect octal string values. */ +var reIsOctal = /^0o[0-7]+$/i; - return ret; -} +/** Built-in method references without a dependency on `root`. */ +var freeParseInt = parseInt; -// Extracts only enough buffered data to satisfy the amount requested. -// This function is designed to be inlinable, so please take care when making -// changes to the function body. -function fromListPartial(n, list, hasStrings) { - var ret; - if (n < list.head.data.length) { - // slice is the same for buffers and strings - ret = list.head.data.slice(0, n); - list.head.data = list.head.data.slice(n); - } else if (n === list.head.data.length) { - // first chunk is a perfect match - ret = list.shift(); - } else { - // result spans more than one buffer - ret = hasStrings ? copyFromBufferString(n, list) : copyFromBuffer(n, list); - } - return ret; -} +/** Used for built-in method references. */ +var objectProto = Object.prototype; -// Copies a specified amount of characters from the list of buffered data -// chunks. -// This function is designed to be inlinable, so please take care when making -// changes to the function body. -function copyFromBufferString(n, list) { - var p = list.head; - var c = 1; - var ret = p.data; - n -= ret.length; - while (p = p.next) { - var str = p.data; - var nb = n > str.length ? str.length : n; - if (nb === str.length) ret += str;else ret += str.slice(0, n); - n -= nb; - if (n === 0) { - if (nb === str.length) { - ++c; - if (p.next) list.head = p.next;else list.head = list.tail = null; - } else { - list.head = p; - p.data = str.slice(nb); - } - break; - } - ++c; - } - list.length -= c; - return ret; -} +/** + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; -// Copies a specified amount of bytes from the list of buffered data chunks. -// This function is designed to be inlinable, so please take care when making -// changes to the function body. -function copyFromBuffer(n, list) { - var ret = Buffer.allocUnsafe(n); - var p = list.head; - var c = 1; - p.data.copy(ret); - n -= p.data.length; - while (p = p.next) { - var buf = p.data; - var nb = n > buf.length ? buf.length : n; - buf.copy(ret, ret.length - n, 0, nb); - n -= nb; - if (n === 0) { - if (nb === buf.length) { - ++c; - if (p.next) list.head = p.next;else list.head = list.tail = null; - } else { - list.head = p; - p.data = buf.slice(nb); - } - break; - } - ++c; - } - list.length -= c; - return ret; +/** + * Checks if `value` is an integer. + * + * **Note:** This method is based on + * [`Number.isInteger`](https://mdn.io/Number/isInteger). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an integer, else `false`. + * @example + * + * _.isInteger(3); + * // => true + * + * _.isInteger(Number.MIN_VALUE); + * // => false + * + * _.isInteger(Infinity); + * // => false + * + * _.isInteger('3'); + * // => false + */ +function isInteger(value) { + return typeof value == 'number' && value == toInteger(value); } -function endReadable(stream) { - var state = stream._readableState; - - // If we get here before consuming all the bytes, then that is a - // bug in node. Should never happen. - if (state.length > 0) throw new Error('"endReadable()" called on non-empty stream'); - - if (!state.endEmitted) { - state.ended = true; - pna.nextTick(endReadableNT, state, stream); - } +/** + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an object, else `false`. + * @example + * + * _.isObject({}); + * // => true + * + * _.isObject([1, 2, 3]); + * // => true + * + * _.isObject(_.noop); + * // => true + * + * _.isObject(null); + * // => false + */ +function isObject(value) { + var type = typeof value; + return !!value && (type == 'object' || type == 'function'); } -function endReadableNT(state, stream) { - // Check that we didn't get one last unshift. - if (!state.endEmitted && state.length === 0) { - state.endEmitted = true; - stream.readable = false; - stream.emit('end'); - } +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; } -function indexOf(xs, x) { - for (var i = 0, l = xs.length; i < l; i++) { - if (xs[i] === x) return i; - } - return -1; +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); } -/***/ }), - -/***/ 69343: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - -// Copyright Joyent, Inc. and other Node contributors. -// -// Permission is hereby granted, free of charge, to any person obtaining a -// copy of this software and associated documentation files (the -// "Software"), to deal in the Software without restriction, including -// without limitation the rights to use, copy, modify, merge, publish, -// distribute, sublicense, and/or sell copies of the Software, and to permit -// persons to whom the Software is furnished to do so, subject to the -// following conditions: -// -// The above copyright notice and this permission notice shall be included -// in all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN -// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE -// USE OR OTHER DEALINGS IN THE SOFTWARE. - -// a transform stream is a readable/writable stream where you do -// something with the data. Sometimes it's called a "filter", -// but that's not a great name for it, since that implies a thing where -// some bits pass through, and others are simply ignored. (That would -// be a valid example of a transform, of course.) -// -// While the output is causally related to the input, it's not a -// necessarily symmetric or synchronous transformation. For example, -// a zlib stream might take multiple plain-text writes(), and then -// emit a single compressed chunk some time in the future. -// -// Here's how this works: -// -// The Transform stream has all the aspects of the readable and writable -// stream classes. When you write(chunk), that calls _write(chunk,cb) -// internally, and returns false if there's a lot of pending writes -// buffered up. When you call read(), that calls _read(n) until -// there's enough pending readable data buffered up. -// -// In a transform stream, the written data is placed in a buffer. When -// _read(n) is called, it transforms the queued up data, calling the -// buffered _write cb's as it consumes chunks. If consuming a single -// written chunk would result in multiple output chunks, then the first -// outputted bit calls the readcb, and subsequent chunks just go into -// the read buffer, and will cause it to emit 'readable' if necessary. -// -// This way, back-pressure is actually determined by the reading side, -// since _read has to be called to start processing a new chunk. However, -// a pathological inflate type of transform can cause excessive buffering -// here. For example, imagine a stream where every byte of input is -// interpreted as an integer from 0-255, and then results in that many -// bytes of output. Writing the 4 bytes {ff,ff,ff,ff} would result in -// 1kb of data being output. In this case, you could write a very small -// amount of input, and end up with a very large amount of output. In -// such a pathological inflating mechanism, there'd be no way to tell -// the system to stop doing the transform. A single 4MB write could -// cause the system to run out of memory. -// -// However, even in such a pathological case, only a single written chunk -// would be consumed, and then the rest would wait (un-transformed) until -// the results of the previous transformed chunk were consumed. - - - -module.exports = Transform; - -var Duplex = __nccwpck_require__(34793); - -/**/ -var util = Object.create(__nccwpck_require__(45481)); -util.inherits = __nccwpck_require__(39598); -/**/ - -util.inherits(Transform, Duplex); - -function afterTransform(er, data) { - var ts = this._transformState; - ts.transforming = false; - - var cb = ts.writecb; - - if (!cb) { - return this.emit('error', new Error('write callback called multiple times')); - } - - ts.writechunk = null; - ts.writecb = null; - - if (data != null) // single equals check for both `null` and `undefined` - this.push(data); - - cb(er); - - var rs = this._readableState; - rs.reading = false; - if (rs.needReadable || rs.length < rs.highWaterMark) { - this._read(rs.highWaterMark); +/** + * Converts `value` to a finite number. + * + * @static + * @memberOf _ + * @since 4.12.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {number} Returns the converted number. + * @example + * + * _.toFinite(3.2); + * // => 3.2 + * + * _.toFinite(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toFinite(Infinity); + * // => 1.7976931348623157e+308 + * + * _.toFinite('3.2'); + * // => 3.2 + */ +function toFinite(value) { + if (!value) { + return value === 0 ? value : 0; } -} - -function Transform(options) { - if (!(this instanceof Transform)) return new Transform(options); - - Duplex.call(this, options); - - this._transformState = { - afterTransform: afterTransform.bind(this), - needTransform: false, - transforming: false, - writecb: null, - writechunk: null, - writeencoding: null - }; - - // start out asking for a readable event once data is transformed. - this._readableState.needReadable = true; - - // we have implemented the _read method, and done the other things - // that Readable wants before the first _read call, so unset the - // sync guard flag. - this._readableState.sync = false; - - if (options) { - if (typeof options.transform === 'function') this._transform = options.transform; - - if (typeof options.flush === 'function') this._flush = options.flush; + value = toNumber(value); + if (value === INFINITY || value === -INFINITY) { + var sign = (value < 0 ? -1 : 1); + return sign * MAX_INTEGER; } - - // When the writable side finishes, then flush out anything remaining. - this.on('prefinish', prefinish); + return value === value ? value : 0; } -function prefinish() { - var _this = this; +/** + * Converts `value` to an integer. + * + * **Note:** This method is loosely based on + * [`ToInteger`](http://www.ecma-international.org/ecma-262/7.0/#sec-tointeger). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {number} Returns the converted integer. + * @example + * + * _.toInteger(3.2); + * // => 3 + * + * _.toInteger(Number.MIN_VALUE); + * // => 0 + * + * _.toInteger(Infinity); + * // => 1.7976931348623157e+308 + * + * _.toInteger('3.2'); + * // => 3 + */ +function toInteger(value) { + var result = toFinite(value), + remainder = result % 1; - if (typeof this._flush === 'function') { - this._flush(function (er, data) { - done(_this, er, data); - }); - } else { - done(this, null, null); - } + return result === result ? (remainder ? result - remainder : result) : 0; } -Transform.prototype.push = function (chunk, encoding) { - this._transformState.needTransform = false; - return Duplex.prototype.push.call(this, chunk, encoding); -}; - -// This is the part where you do stuff! -// override this function in implementation classes. -// 'chunk' is an input chunk. -// -// Call `push(newChunk)` to pass along transformed output -// to the readable side. You may call 'push' zero or more times. -// -// Call `cb(err)` when you are done with this chunk. If you pass -// an error, then that'll put the hurt on the whole operation. If you -// never call cb(), then you'll never get another chunk. -Transform.prototype._transform = function (chunk, encoding, cb) { - throw new Error('_transform() is not implemented'); -}; - -Transform.prototype._write = function (chunk, encoding, cb) { - var ts = this._transformState; - ts.writecb = cb; - ts.writechunk = chunk; - ts.writeencoding = encoding; - if (!ts.transforming) { - var rs = this._readableState; - if (ts.needTransform || rs.needReadable || rs.length < rs.highWaterMark) this._read(rs.highWaterMark); +/** + * Converts `value` to a number. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to process. + * @returns {number} Returns the number. + * @example + * + * _.toNumber(3.2); + * // => 3.2 + * + * _.toNumber(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toNumber(Infinity); + * // => Infinity + * + * _.toNumber('3.2'); + * // => 3.2 + */ +function toNumber(value) { + if (typeof value == 'number') { + return value; } -}; - -// Doesn't matter what the args are here. -// _transform does all the work. -// That we got here means that the readable side wants more data. -Transform.prototype._read = function (n) { - var ts = this._transformState; - - if (ts.writechunk !== null && ts.writecb && !ts.transforming) { - ts.transforming = true; - this._transform(ts.writechunk, ts.writeencoding, ts.afterTransform); - } else { - // mark that we need a transform, so that any data that comes in - // will get processed, now that we've asked for it. - ts.needTransform = true; + if (isSymbol(value)) { + return NAN; } -}; + if (isObject(value)) { + var other = typeof value.valueOf == 'function' ? value.valueOf() : value; + value = isObject(other) ? (other + '') : other; + } + if (typeof value != 'string') { + return value === 0 ? value : +value; + } + value = value.replace(reTrim, ''); + var isBinary = reIsBinary.test(value); + return (isBinary || reIsOctal.test(value)) + ? freeParseInt(value.slice(2), isBinary ? 2 : 8) + : (reIsBadHex.test(value) ? NAN : +value); +} -Transform.prototype._destroy = function (err, cb) { - var _this2 = this; +module.exports = isInteger; - Duplex.prototype._destroy.call(this, err, function (err2) { - cb(err2); - _this2.emit('close'); - }); -}; -function done(stream, er, data) { - if (er) return stream.emit('error', er); +/***/ }), - if (data != null) // single equals check for both `null` and `undefined` - stream.push(data); +/***/ 95011: +/***/ ((module) => { - // if there's nothing in the write buffer, then that means - // that nothing more will ever be provided - if (stream._writableState.length) throw new Error('Calling transform done when ws.length != 0'); +/** + * lodash 3.0.3 (Custom Build) + * Build: `lodash modularize exports="npm" -o ./` + * Copyright 2012-2016 The Dojo Foundation + * Based on Underscore.js 1.8.3 + * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + * Available under MIT license + */ - if (stream._transformState.transforming) throw new Error('Calling transform done when still transforming'); +/** `Object#toString` result references. */ +var numberTag = '[object Number]'; - return stream.push(null); -} +/** Used for built-in method references. */ +var objectProto = Object.prototype; -/***/ }), +/** + * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; -/***/ 54579: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} -// Copyright Joyent, Inc. and other Node contributors. -// -// Permission is hereby granted, free of charge, to any person obtaining a -// copy of this software and associated documentation files (the -// "Software"), to deal in the Software without restriction, including -// without limitation the rights to use, copy, modify, merge, publish, -// distribute, sublicense, and/or sell copies of the Software, and to permit -// persons to whom the Software is furnished to do so, subject to the -// following conditions: -// -// The above copyright notice and this permission notice shall be included -// in all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN -// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE -// USE OR OTHER DEALINGS IN THE SOFTWARE. +/** + * Checks if `value` is classified as a `Number` primitive or object. + * + * **Note:** To exclude `Infinity`, `-Infinity`, and `NaN`, which are classified + * as numbers, use the `_.isFinite` method. + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @example + * + * _.isNumber(3); + * // => true + * + * _.isNumber(Number.MIN_VALUE); + * // => true + * + * _.isNumber(Infinity); + * // => true + * + * _.isNumber('3'); + * // => false + */ +function isNumber(value) { + return typeof value == 'number' || + (isObjectLike(value) && objectToString.call(value) == numberTag); +} -// A bit simpler than readable streams. -// Implement an async ._write(chunk, encoding, cb), and it'll handle all -// the drain event emission and buffering. +module.exports = isNumber; +/***/ }), -/**/ +/***/ 65341: +/***/ ((module) => { -var pna = __nccwpck_require__(41564); -/**/ +/** + * lodash (Custom Build) + * Build: `lodash modularize exports="npm" -o ./` + * Copyright jQuery Foundation and other contributors + * Released under MIT license + * Based on Underscore.js 1.8.3 + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + */ -module.exports = Writable; +/** `Object#toString` result references. */ +var objectTag = '[object Object]'; -/* */ -function WriteReq(chunk, encoding, cb) { - this.chunk = chunk; - this.encoding = encoding; - this.callback = cb; - this.next = null; +/** + * Checks if `value` is a host object in IE < 9. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a host object, else `false`. + */ +function isHostObject(value) { + // Many host objects are `Object` objects that can coerce to strings + // despite having improperly defined `toString` methods. + var result = false; + if (value != null && typeof value.toString != 'function') { + try { + result = !!(value + ''); + } catch (e) {} + } + return result; } -// It seems a linked list but it is not -// there will be only 2 of these for each stream -function CorkedRequest(state) { - var _this = this; - - this.next = null; - this.entry = null; - this.finish = function () { - onCorkedFinish(_this, state); +/** + * Creates a unary function that invokes `func` with its argument transformed. + * + * @private + * @param {Function} func The function to wrap. + * @param {Function} transform The argument transform. + * @returns {Function} Returns the new function. + */ +function overArg(func, transform) { + return function(arg) { + return func(transform(arg)); }; } -/* */ - -/**/ -var asyncWrite = !process.browser && ['v0.10', 'v0.9.'].indexOf(process.version.slice(0, 5)) > -1 ? setImmediate : pna.nextTick; -/**/ -/**/ -var Duplex; -/**/ +/** Used for built-in method references. */ +var funcProto = Function.prototype, + objectProto = Object.prototype; -Writable.WritableState = WritableState; +/** Used to resolve the decompiled source of functions. */ +var funcToString = funcProto.toString; -/**/ -var util = Object.create(__nccwpck_require__(45481)); -util.inherits = __nccwpck_require__(39598); -/**/ +/** Used to check objects for own properties. */ +var hasOwnProperty = objectProto.hasOwnProperty; -/**/ -var internalUtil = { - deprecate: __nccwpck_require__(24488) -}; -/**/ +/** Used to infer the `Object` constructor. */ +var objectCtorString = funcToString.call(Object); -/**/ -var Stream = __nccwpck_require__(87137); -/**/ +/** + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; -/**/ +/** Built-in value references. */ +var getPrototype = overArg(Object.getPrototypeOf, Object); -var Buffer = (__nccwpck_require__(13644).Buffer); -var OurUint8Array = (typeof global !== 'undefined' ? global : typeof window !== 'undefined' ? window : typeof self !== 'undefined' ? self : {}).Uint8Array || function () {}; -function _uint8ArrayToBuffer(chunk) { - return Buffer.from(chunk); +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; } -function _isUint8Array(obj) { - return Buffer.isBuffer(obj) || obj instanceof OurUint8Array; + +/** + * Checks if `value` is a plain object, that is, an object created by the + * `Object` constructor or one with a `[[Prototype]]` of `null`. + * + * @static + * @memberOf _ + * @since 0.8.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a plain object, else `false`. + * @example + * + * function Foo() { + * this.a = 1; + * } + * + * _.isPlainObject(new Foo); + * // => false + * + * _.isPlainObject([1, 2, 3]); + * // => false + * + * _.isPlainObject({ 'x': 0, 'y': 0 }); + * // => true + * + * _.isPlainObject(Object.create(null)); + * // => true + */ +function isPlainObject(value) { + if (!isObjectLike(value) || + objectToString.call(value) != objectTag || isHostObject(value)) { + return false; + } + var proto = getPrototype(value); + if (proto === null) { + return true; + } + var Ctor = hasOwnProperty.call(proto, 'constructor') && proto.constructor; + return (typeof Ctor == 'function' && + Ctor instanceof Ctor && funcToString.call(Ctor) == objectCtorString); } -/**/ +module.exports = isPlainObject; -var destroyImpl = __nccwpck_require__(91031); -util.inherits(Writable, Stream); +/***/ }), -function nop() {} +/***/ 5250: +/***/ ((module) => { -function WritableState(options, stream) { - Duplex = Duplex || __nccwpck_require__(34793); +/** + * lodash 4.0.1 (Custom Build) + * Build: `lodash modularize exports="npm" -o ./` + * Copyright 2012-2016 The Dojo Foundation + * Based on Underscore.js 1.8.3 + * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + * Available under MIT license + */ - options = options || {}; +/** `Object#toString` result references. */ +var stringTag = '[object String]'; - // Duplex streams are both readable and writable, but share - // the same options object. - // However, some cases require setting options to different - // values for the readable and the writable sides of the duplex stream. - // These options can be provided separately as readableXXX and writableXXX. - var isDuplex = stream instanceof Duplex; +/** Used for built-in method references. */ +var objectProto = Object.prototype; - // object stream flag to indicate whether or not this stream - // contains buffers or objects. - this.objectMode = !!options.objectMode; +/** + * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; - if (isDuplex) this.objectMode = this.objectMode || !!options.writableObjectMode; +/** + * Checks if `value` is classified as an `Array` object. + * + * @static + * @memberOf _ + * @type Function + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @example + * + * _.isArray([1, 2, 3]); + * // => true + * + * _.isArray(document.body.children); + * // => false + * + * _.isArray('abc'); + * // => false + * + * _.isArray(_.noop); + * // => false + */ +var isArray = Array.isArray; - // the point at which write() starts returning false - // Note: 0 is a valid value, means that we always return false if - // the entire buffer is not flushed immediately on write() - var hwm = options.highWaterMark; - var writableHwm = options.writableHighWaterMark; - var defaultHwm = this.objectMode ? 16 : 16 * 1024; +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} - if (hwm || hwm === 0) this.highWaterMark = hwm;else if (isDuplex && (writableHwm || writableHwm === 0)) this.highWaterMark = writableHwm;else this.highWaterMark = defaultHwm; +/** + * Checks if `value` is classified as a `String` primitive or object. + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @example + * + * _.isString('abc'); + * // => true + * + * _.isString(1); + * // => false + */ +function isString(value) { + return typeof value == 'string' || + (!isArray(value) && isObjectLike(value) && objectToString.call(value) == stringTag); +} - // cast to ints. - this.highWaterMark = Math.floor(this.highWaterMark); +module.exports = isString; - // if _final has been called - this.finalCalled = false; - // drain event flag. - this.needDrain = false; - // at the start of calling end() - this.ending = false; - // when end() has been called, and returned - this.ended = false; - // when 'finish' is emitted - this.finished = false; +/***/ }), - // has it been destroyed - this.destroyed = false; +/***/ 63839: +/***/ ((module) => { - // should we decode strings into buffers before passing to _write? - // this is here so that some node-core streams can optimize string - // handling at a lower level. - var noDecode = options.decodeStrings === false; - this.decodeStrings = !noDecode; +/** + * lodash (Custom Build) + * Build: `lodash modularize exports="npm" -o ./` + * Copyright jQuery Foundation and other contributors + * Released under MIT license + * Based on Underscore.js 1.8.3 + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + */ - // Crypto is kind of old and crusty. Historically, its default string - // encoding is 'binary' so we have to make this configurable. - // Everything else in the universe uses 'utf8', though. - this.defaultEncoding = options.defaultEncoding || 'utf8'; +/** Used as the `TypeError` message for "Functions" methods. */ +var FUNC_ERROR_TEXT = 'Expected a function'; - // not an actual buffer we keep track of, but a measurement - // of how much we're waiting to get pushed to some underlying - // socket or file. - this.length = 0; +/** Used as references for various `Number` constants. */ +var INFINITY = 1 / 0, + MAX_INTEGER = 1.7976931348623157e+308, + NAN = 0 / 0; - // a flag to see when we're in the middle of a write. - this.writing = false; +/** `Object#toString` result references. */ +var symbolTag = '[object Symbol]'; - // when true all writes will be buffered until .uncork() call - this.corked = 0; +/** Used to match leading and trailing whitespace. */ +var reTrim = /^\s+|\s+$/g; - // a flag to be able to tell if the onwrite cb is called immediately, - // or on a later tick. We set this to true at first, because any - // actions that shouldn't happen until "later" should generally also - // not happen before the first write call. - this.sync = true; +/** Used to detect bad signed hexadecimal string values. */ +var reIsBadHex = /^[-+]0x[0-9a-f]+$/i; - // a flag to know if we're processing previously buffered items, which - // may call the _write() callback in the same tick, so that we don't - // end up in an overlapped onwrite situation. - this.bufferProcessing = false; +/** Used to detect binary string values. */ +var reIsBinary = /^0b[01]+$/i; - // the callback that's passed to _write(chunk,cb) - this.onwrite = function (er) { - onwrite(stream, er); - }; +/** Used to detect octal string values. */ +var reIsOctal = /^0o[0-7]+$/i; - // the callback that the user supplies to write(chunk,encoding,cb) - this.writecb = null; +/** Built-in method references without a dependency on `root`. */ +var freeParseInt = parseInt; - // the amount that is being written when _write is called. - this.writelen = 0; +/** Used for built-in method references. */ +var objectProto = Object.prototype; - this.bufferedRequest = null; - this.lastBufferedRequest = null; +/** + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; - // number of pending user-supplied write callbacks - // this must be 0 before 'finish' can be emitted - this.pendingcb = 0; +/** + * Creates a function that invokes `func`, with the `this` binding and arguments + * of the created function, while it's called less than `n` times. Subsequent + * calls to the created function return the result of the last `func` invocation. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Function + * @param {number} n The number of calls at which `func` is no longer invoked. + * @param {Function} func The function to restrict. + * @returns {Function} Returns the new restricted function. + * @example + * + * jQuery(element).on('click', _.before(5, addContactToList)); + * // => Allows adding up to 4 contacts to the list. + */ +function before(n, func) { + var result; + if (typeof func != 'function') { + throw new TypeError(FUNC_ERROR_TEXT); + } + n = toInteger(n); + return function() { + if (--n > 0) { + result = func.apply(this, arguments); + } + if (n <= 1) { + func = undefined; + } + return result; + }; +} - // emit prefinish if the only thing we're waiting for is _write cbs - // This is relevant for synchronous Transform streams - this.prefinished = false; +/** + * Creates a function that is restricted to invoking `func` once. Repeat calls + * to the function return the value of the first invocation. The `func` is + * invoked with the `this` binding and arguments of the created function. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Function + * @param {Function} func The function to restrict. + * @returns {Function} Returns the new restricted function. + * @example + * + * var initialize = _.once(createApplication); + * initialize(); + * initialize(); + * // => `createApplication` is invoked once + */ +function once(func) { + return before(2, func); +} - // True if the error was already emitted and should not be thrown again - this.errorEmitted = false; +/** + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an object, else `false`. + * @example + * + * _.isObject({}); + * // => true + * + * _.isObject([1, 2, 3]); + * // => true + * + * _.isObject(_.noop); + * // => true + * + * _.isObject(null); + * // => false + */ +function isObject(value) { + var type = typeof value; + return !!value && (type == 'object' || type == 'function'); +} - // count buffered requests - this.bufferedRequestCount = 0; +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} - // allocate the first CorkedRequest, there is always - // one allocated and free to use, and we maintain at most two - this.corkedRequestsFree = new CorkedRequest(this); +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); } -WritableState.prototype.getBuffer = function getBuffer() { - var current = this.bufferedRequest; - var out = []; - while (current) { - out.push(current); - current = current.next; +/** + * Converts `value` to a finite number. + * + * @static + * @memberOf _ + * @since 4.12.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {number} Returns the converted number. + * @example + * + * _.toFinite(3.2); + * // => 3.2 + * + * _.toFinite(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toFinite(Infinity); + * // => 1.7976931348623157e+308 + * + * _.toFinite('3.2'); + * // => 3.2 + */ +function toFinite(value) { + if (!value) { + return value === 0 ? value : 0; } - return out; -}; + value = toNumber(value); + if (value === INFINITY || value === -INFINITY) { + var sign = (value < 0 ? -1 : 1); + return sign * MAX_INTEGER; + } + return value === value ? value : 0; +} -(function () { - try { - Object.defineProperty(WritableState.prototype, 'buffer', { - get: internalUtil.deprecate(function () { - return this.getBuffer(); - }, '_writableState.buffer is deprecated. Use _writableState.getBuffer ' + 'instead.', 'DEP0003') - }); - } catch (_) {} -})(); +/** + * Converts `value` to an integer. + * + * **Note:** This method is loosely based on + * [`ToInteger`](http://www.ecma-international.org/ecma-262/7.0/#sec-tointeger). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {number} Returns the converted integer. + * @example + * + * _.toInteger(3.2); + * // => 3 + * + * _.toInteger(Number.MIN_VALUE); + * // => 0 + * + * _.toInteger(Infinity); + * // => 1.7976931348623157e+308 + * + * _.toInteger('3.2'); + * // => 3 + */ +function toInteger(value) { + var result = toFinite(value), + remainder = result % 1; -// Test _writableState for inheritance to account for Duplex streams, -// whose prototype chain only points to Readable. -var realHasInstance; -if (typeof Symbol === 'function' && Symbol.hasInstance && typeof Function.prototype[Symbol.hasInstance] === 'function') { - realHasInstance = Function.prototype[Symbol.hasInstance]; - Object.defineProperty(Writable, Symbol.hasInstance, { - value: function (object) { - if (realHasInstance.call(this, object)) return true; - if (this !== Writable) return false; + return result === result ? (remainder ? result - remainder : result) : 0; +} - return object && object._writableState instanceof WritableState; - } - }); -} else { - realHasInstance = function (object) { - return object instanceof this; - }; +/** + * Converts `value` to a number. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to process. + * @returns {number} Returns the number. + * @example + * + * _.toNumber(3.2); + * // => 3.2 + * + * _.toNumber(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toNumber(Infinity); + * // => Infinity + * + * _.toNumber('3.2'); + * // => 3.2 + */ +function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } + if (isObject(value)) { + var other = typeof value.valueOf == 'function' ? value.valueOf() : value; + value = isObject(other) ? (other + '') : other; + } + if (typeof value != 'string') { + return value === 0 ? value : +value; + } + value = value.replace(reTrim, ''); + var isBinary = reIsBinary.test(value); + return (isBinary || reIsOctal.test(value)) + ? freeParseInt(value.slice(2), isBinary ? 2 : 8) + : (reIsBadHex.test(value) ? NAN : +value); } -function Writable(options) { - Duplex = Duplex || __nccwpck_require__(34793); +module.exports = once; - // Writable ctor is applied to Duplexes, too. - // `realHasInstance` is necessary because using plain `instanceof` - // would return false, as no `_writableState` property is attached. - // Trying to use the custom `instanceof` for Writable here will also break the - // Node.js LazyTransform implementation, which has a non-trivial getter for - // `_writableState` that would lead to infinite recursion. - if (!realHasInstance.call(Writable, this) && !(this instanceof Duplex)) { - return new Writable(options); - } +/***/ }), - this._writableState = new WritableState(options, this); +/***/ 3856: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - // legacy. - this.writable = true; +var hashClear = __nccwpck_require__(35795), + hashDelete = __nccwpck_require__(60007), + hashGet = __nccwpck_require__(12662), + hashHas = __nccwpck_require__(58405), + hashSet = __nccwpck_require__(37930); - if (options) { - if (typeof options.write === 'function') this._write = options.write; +/** + * Creates a hash object. + * + * @private + * @constructor + * @param {Array} [entries] The key-value pairs to cache. + */ +function Hash(entries) { + var index = -1, + length = entries == null ? 0 : entries.length; - if (typeof options.writev === 'function') this._writev = options.writev; + this.clear(); + while (++index < length) { + var entry = entries[index]; + this.set(entry[0], entry[1]); + } +} - if (typeof options.destroy === 'function') this._destroy = options.destroy; +// Add methods to `Hash`. +Hash.prototype.clear = hashClear; +Hash.prototype['delete'] = hashDelete; +Hash.prototype.get = hashGet; +Hash.prototype.has = hashHas; +Hash.prototype.set = hashSet; - if (typeof options.final === 'function') this._final = options.final; - } +module.exports = Hash; - Stream.call(this); -} -// Otherwise people can pipe Writable streams, which is just wrong. -Writable.prototype.pipe = function () { - this.emit('error', new Error('Cannot pipe, not readable')); -}; +/***/ }), -function writeAfterEnd(stream, cb) { - var er = new Error('write after end'); - // TODO: defer error events consistently everywhere, not just the cb - stream.emit('error', er); - pna.nextTick(cb, er); -} +/***/ 75796: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -// Checks that a user-supplied chunk is valid, especially for the particular -// mode the stream is in. Currently this means that `null` is never accepted -// and undefined/non-string values are only allowed in object mode. -function validChunk(stream, state, chunk, cb) { - var valid = true; - var er = false; +var listCacheClear = __nccwpck_require__(2479), + listCacheDelete = __nccwpck_require__(32299), + listCacheGet = __nccwpck_require__(61322), + listCacheHas = __nccwpck_require__(48942), + listCacheSet = __nccwpck_require__(68534); - if (chunk === null) { - er = new TypeError('May not write null values to stream'); - } else if (typeof chunk !== 'string' && chunk !== undefined && !state.objectMode) { - er = new TypeError('Invalid non-string/buffer chunk'); - } - if (er) { - stream.emit('error', er); - pna.nextTick(cb, er); - valid = false; +/** + * Creates an list cache object. + * + * @private + * @constructor + * @param {Array} [entries] The key-value pairs to cache. + */ +function ListCache(entries) { + var index = -1, + length = entries == null ? 0 : entries.length; + + this.clear(); + while (++index < length) { + var entry = entries[index]; + this.set(entry[0], entry[1]); } - return valid; } -Writable.prototype.write = function (chunk, encoding, cb) { - var state = this._writableState; - var ret = false; - var isBuf = !state.objectMode && _isUint8Array(chunk); +// Add methods to `ListCache`. +ListCache.prototype.clear = listCacheClear; +ListCache.prototype['delete'] = listCacheDelete; +ListCache.prototype.get = listCacheGet; +ListCache.prototype.has = listCacheHas; +ListCache.prototype.set = listCacheSet; - if (isBuf && !Buffer.isBuffer(chunk)) { - chunk = _uint8ArrayToBuffer(chunk); - } +module.exports = ListCache; - if (typeof encoding === 'function') { - cb = encoding; - encoding = null; - } - if (isBuf) encoding = 'buffer';else if (!encoding) encoding = state.defaultEncoding; +/***/ }), - if (typeof cb !== 'function') cb = nop; +/***/ 31456: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - if (state.ended) writeAfterEnd(this, cb);else if (isBuf || validChunk(this, state, chunk, cb)) { - state.pendingcb++; - ret = writeOrBuffer(this, state, isBuf, chunk, encoding, cb); - } +var getNative = __nccwpck_require__(39837), + root = __nccwpck_require__(64060); - return ret; -}; +/* Built-in method references that are verified to be native. */ +var Map = getNative(root, 'Map'); -Writable.prototype.cork = function () { - var state = this._writableState; +module.exports = Map; - state.corked++; -}; -Writable.prototype.uncork = function () { - var state = this._writableState; +/***/ }), - if (state.corked) { - state.corked--; +/***/ 44076: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - if (!state.writing && !state.corked && !state.bufferProcessing && state.bufferedRequest) clearBuffer(this, state); - } -}; +var mapCacheClear = __nccwpck_require__(45703), + mapCacheDelete = __nccwpck_require__(95027), + mapCacheGet = __nccwpck_require__(33714), + mapCacheHas = __nccwpck_require__(37862), + mapCacheSet = __nccwpck_require__(82462); -Writable.prototype.setDefaultEncoding = function setDefaultEncoding(encoding) { - // node::ParseEncoding() requires lower case. - if (typeof encoding === 'string') encoding = encoding.toLowerCase(); - if (!(['hex', 'utf8', 'utf-8', 'ascii', 'binary', 'base64', 'ucs2', 'ucs-2', 'utf16le', 'utf-16le', 'raw'].indexOf((encoding + '').toLowerCase()) > -1)) throw new TypeError('Unknown encoding: ' + encoding); - this._writableState.defaultEncoding = encoding; - return this; -}; +/** + * Creates a map cache object to store key-value pairs. + * + * @private + * @constructor + * @param {Array} [entries] The key-value pairs to cache. + */ +function MapCache(entries) { + var index = -1, + length = entries == null ? 0 : entries.length; -function decodeChunk(state, chunk, encoding) { - if (!state.objectMode && state.decodeStrings !== false && typeof chunk === 'string') { - chunk = Buffer.from(chunk, encoding); + this.clear(); + while (++index < length) { + var entry = entries[index]; + this.set(entry[0], entry[1]); } - return chunk; } -Object.defineProperty(Writable.prototype, 'writableHighWaterMark', { - // making it explicit this property is not enumerable - // because otherwise some prototype manipulation in - // userland will fail - enumerable: false, - get: function () { - return this._writableState.highWaterMark; - } -}); - -// if we're already writing something, then just put this -// in the queue, and wait our turn. Otherwise, call _write -// If we return false, then we need a drain event, so set that flag. -function writeOrBuffer(stream, state, isBuf, chunk, encoding, cb) { - if (!isBuf) { - var newChunk = decodeChunk(state, chunk, encoding); - if (chunk !== newChunk) { - isBuf = true; - encoding = 'buffer'; - chunk = newChunk; - } - } - var len = state.objectMode ? 1 : chunk.length; - - state.length += len; - - var ret = state.length < state.highWaterMark; - // we must ensure that previous needDrain will not be reset to false. - if (!ret) state.needDrain = true; - - if (state.writing || state.corked) { - var last = state.lastBufferedRequest; - state.lastBufferedRequest = { - chunk: chunk, - encoding: encoding, - isBuf: isBuf, - callback: cb, - next: null - }; - if (last) { - last.next = state.lastBufferedRequest; - } else { - state.bufferedRequest = state.lastBufferedRequest; - } - state.bufferedRequestCount += 1; - } else { - doWrite(stream, state, false, len, chunk, encoding, cb); - } +// Add methods to `MapCache`. +MapCache.prototype.clear = mapCacheClear; +MapCache.prototype['delete'] = mapCacheDelete; +MapCache.prototype.get = mapCacheGet; +MapCache.prototype.has = mapCacheHas; +MapCache.prototype.set = mapCacheSet; - return ret; -} +module.exports = MapCache; -function doWrite(stream, state, writev, len, chunk, encoding, cb) { - state.writelen = len; - state.writecb = cb; - state.writing = true; - state.sync = true; - if (writev) stream._writev(chunk, state.onwrite);else stream._write(chunk, encoding, state.onwrite); - state.sync = false; -} -function onwriteError(stream, state, sync, er, cb) { - --state.pendingcb; +/***/ }), - if (sync) { - // defer the callback if we are being called synchronously - // to avoid piling up things on the stack - pna.nextTick(cb, er); - // this can emit finish, and it will always happen - // after error - pna.nextTick(finishMaybe, stream, state); - stream._writableState.errorEmitted = true; - stream.emit('error', er); - } else { - // the caller expect this to happen before if - // it is async - cb(er); - stream._writableState.errorEmitted = true; - stream.emit('error', er); - // this can emit finish, but finish must - // always follow error - finishMaybe(stream, state); - } -} +/***/ 22842: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -function onwriteStateUpdate(state) { - state.writing = false; - state.writecb = null; - state.length -= state.writelen; - state.writelen = 0; -} +var getNative = __nccwpck_require__(39837), + root = __nccwpck_require__(64060); -function onwrite(stream, er) { - var state = stream._writableState; - var sync = state.sync; - var cb = state.writecb; +/* Built-in method references that are verified to be native. */ +var Set = getNative(root, 'Set'); - onwriteStateUpdate(state); +module.exports = Set; - if (er) onwriteError(stream, state, sync, er, cb);else { - // Check if we're actually ready to finish, but don't emit yet - var finished = needFinish(state); - if (!finished && !state.corked && !state.bufferProcessing && state.bufferedRequest) { - clearBuffer(stream, state); - } +/***/ }), - if (sync) { - /**/ - asyncWrite(afterWrite, stream, state, finished, cb); - /**/ - } else { - afterWrite(stream, state, finished, cb); - } - } -} +/***/ 88058: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -function afterWrite(stream, state, finished, cb) { - if (!finished) onwriteDrain(stream, state); - state.pendingcb--; - cb(); - finishMaybe(stream, state); -} +var MapCache = __nccwpck_require__(44076), + setCacheAdd = __nccwpck_require__(93343), + setCacheHas = __nccwpck_require__(80908); -// Must force callback to be called on nextTick, so that we don't -// emit 'drain' before the write() consumer gets the 'false' return -// value, and has a chance to attach a 'drain' listener. -function onwriteDrain(stream, state) { - if (state.length === 0 && state.needDrain) { - state.needDrain = false; - stream.emit('drain'); +/** + * + * Creates an array cache object to store unique values. + * + * @private + * @constructor + * @param {Array} [values] The values to cache. + */ +function SetCache(values) { + var index = -1, + length = values == null ? 0 : values.length; + + this.__data__ = new MapCache; + while (++index < length) { + this.add(values[index]); } } -// if there's something in the buffer waiting, then process it -function clearBuffer(stream, state) { - state.bufferProcessing = true; - var entry = state.bufferedRequest; +// Add methods to `SetCache`. +SetCache.prototype.add = SetCache.prototype.push = setCacheAdd; +SetCache.prototype.has = setCacheHas; - if (stream._writev && entry && entry.next) { - // Fast case, write everything using _writev() - var l = state.bufferedRequestCount; - var buffer = new Array(l); - var holder = state.corkedRequestsFree; - holder.entry = entry; +module.exports = SetCache; - var count = 0; - var allBuffers = true; - while (entry) { - buffer[count] = entry; - if (!entry.isBuf) allBuffers = false; - entry = entry.next; - count += 1; - } - buffer.allBuffers = allBuffers; - doWrite(stream, state, true, state.length, buffer, '', holder.finish); +/***/ }), - // doWrite is almost always async, defer these to save a bit of time - // as the hot path ends with doWrite - state.pendingcb++; - state.lastBufferedRequest = null; - if (holder.next) { - state.corkedRequestsFree = holder.next; - holder.next = null; - } else { - state.corkedRequestsFree = new CorkedRequest(state); - } - state.bufferedRequestCount = 0; - } else { - // Slow case, write chunks one-by-one - while (entry) { - var chunk = entry.chunk; - var encoding = entry.encoding; - var cb = entry.callback; - var len = state.objectMode ? 1 : chunk.length; +/***/ 85720: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - doWrite(stream, state, false, len, chunk, encoding, cb); - entry = entry.next; - state.bufferedRequestCount--; - // if we didn't call the onwrite immediately, then - // it means that we need to wait until it does. - // also, that means that the chunk and cb are currently - // being processed, so move the buffer counter past them. - if (state.writing) { - break; - } - } +var root = __nccwpck_require__(64060); - if (entry === null) state.lastBufferedRequest = null; - } +/** Built-in value references. */ +var Symbol = root.Symbol; - state.bufferedRequest = entry; - state.bufferProcessing = false; -} +module.exports = Symbol; -Writable.prototype._write = function (chunk, encoding, cb) { - cb(new Error('_write() is not implemented')); -}; -Writable.prototype._writev = null; +/***/ }), -Writable.prototype.end = function (chunk, encoding, cb) { - var state = this._writableState; +/***/ 67985: +/***/ ((module) => { - if (typeof chunk === 'function') { - cb = chunk; - chunk = null; - encoding = null; - } else if (typeof encoding === 'function') { - cb = encoding; - encoding = null; +/** + * A faster alternative to `Function#apply`, this function invokes `func` + * with the `this` binding of `thisArg` and the arguments of `args`. + * + * @private + * @param {Function} func The function to invoke. + * @param {*} thisArg The `this` binding of `func`. + * @param {Array} args The arguments to invoke `func` with. + * @returns {*} Returns the result of `func`. + */ +function apply(func, thisArg, args) { + switch (args.length) { + case 0: return func.call(thisArg); + case 1: return func.call(thisArg, args[0]); + case 2: return func.call(thisArg, args[0], args[1]); + case 3: return func.call(thisArg, args[0], args[1], args[2]); } + return func.apply(thisArg, args); +} - if (chunk !== null && chunk !== undefined) this.write(chunk, encoding); +module.exports = apply; - // .end() fully uncorks - if (state.corked) { - state.corked = 1; - this.uncork(); - } - // ignore unnecessary end() calls. - if (!state.ending) endWritable(this, state, cb); -}; +/***/ }), -function needFinish(state) { - return state.ending && state.length === 0 && state.bufferedRequest === null && !state.finished && !state.writing; -} -function callFinal(stream, state) { - stream._final(function (err) { - state.pendingcb--; - if (err) { - stream.emit('error', err); - } - state.prefinished = true; - stream.emit('prefinish'); - finishMaybe(stream, state); - }); -} -function prefinish(stream, state) { - if (!state.prefinished && !state.finalCalled) { - if (typeof stream._final === 'function') { - state.pendingcb++; - state.finalCalled = true; - pna.nextTick(callFinal, stream, state); - } else { - state.prefinished = true; - stream.emit('prefinish'); - } - } -} +/***/ 67270: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -function finishMaybe(stream, state) { - var need = needFinish(state); - if (need) { - prefinish(stream, state); - if (state.pendingcb === 0) { - state.finished = true; - stream.emit('finish'); - } - } - return need; -} +var baseIndexOf = __nccwpck_require__(85496); -function endWritable(stream, state, cb) { - state.ending = true; - finishMaybe(stream, state); - if (cb) { - if (state.finished) pna.nextTick(cb);else stream.once('finish', cb); - } - state.ended = true; - stream.writable = false; +/** + * A specialized version of `_.includes` for arrays without support for + * specifying an index to search from. + * + * @private + * @param {Array} [array] The array to inspect. + * @param {*} target The value to search for. + * @returns {boolean} Returns `true` if `target` is found, else `false`. + */ +function arrayIncludes(array, value) { + var length = array == null ? 0 : array.length; + return !!length && baseIndexOf(array, value, 0) > -1; } -function onCorkedFinish(corkReq, state, err) { - var entry = corkReq.entry; - corkReq.entry = null; - while (entry) { - var cb = entry.callback; - state.pendingcb--; - cb(err); - entry = entry.next; - } +module.exports = arrayIncludes; - // reuse the free corkReq. - state.corkedRequestsFree.next = corkReq; -} -Object.defineProperty(Writable.prototype, 'destroyed', { - get: function () { - if (this._writableState === undefined) { - return false; - } - return this._writableState.destroyed; - }, - set: function (value) { - // we ignore the value if the stream - // has not been initialized yet - if (!this._writableState) { - return; - } +/***/ }), - // backward compatibility, the user is explicitly - // managing destroyed - this._writableState.destroyed = value; +/***/ 81954: +/***/ ((module) => { + +/** + * This function is like `arrayIncludes` except that it accepts a comparator. + * + * @private + * @param {Array} [array] The array to inspect. + * @param {*} target The value to search for. + * @param {Function} comparator The comparator invoked per element. + * @returns {boolean} Returns `true` if `target` is found, else `false`. + */ +function arrayIncludesWith(array, value, comparator) { + var index = -1, + length = array == null ? 0 : array.length; + + while (++index < length) { + if (comparator(value, array[index])) { + return true; + } } -}); + return false; +} + +module.exports = arrayIncludesWith; -Writable.prototype.destroy = destroyImpl.destroy; -Writable.prototype._undestroy = destroyImpl.undestroy; -Writable.prototype._destroy = function (err, cb) { - this.end(); - cb(err); -}; /***/ }), -/***/ 46127: +/***/ 92400: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +var baseTimes = __nccwpck_require__(47027), + isArguments = __nccwpck_require__(16861), + isArray = __nccwpck_require__(24840), + isBuffer = __nccwpck_require__(59675), + isIndex = __nccwpck_require__(73254), + isTypedArray = __nccwpck_require__(55864); +/** Used for built-in method references. */ +var objectProto = Object.prototype; -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +/** Used to check objects for own properties. */ +var hasOwnProperty = objectProto.hasOwnProperty; -var Buffer = (__nccwpck_require__(13644).Buffer); -var util = __nccwpck_require__(39023); +/** + * Creates an array of the enumerable property names of the array-like `value`. + * + * @private + * @param {*} value The value to query. + * @param {boolean} inherited Specify returning inherited property names. + * @returns {Array} Returns the array of property names. + */ +function arrayLikeKeys(value, inherited) { + var isArr = isArray(value), + isArg = !isArr && isArguments(value), + isBuff = !isArr && !isArg && isBuffer(value), + isType = !isArr && !isArg && !isBuff && isTypedArray(value), + skipIndexes = isArr || isArg || isBuff || isType, + result = skipIndexes ? baseTimes(value.length, String) : [], + length = result.length; -function copyBuffer(src, target, offset) { - src.copy(target, offset); + for (var key in value) { + if ((inherited || hasOwnProperty.call(value, key)) && + !(skipIndexes && ( + // Safari 9 has enumerable `arguments.length` in strict mode. + key == 'length' || + // Node.js 0.10 has enumerable non-index properties on buffers. + (isBuff && (key == 'offset' || key == 'parent')) || + // PhantomJS 2 has enumerable non-index properties on typed arrays. + (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) || + // Skip index properties. + isIndex(key, length) + ))) { + result.push(key); + } + } + return result; } -module.exports = function () { - function BufferList() { - _classCallCheck(this, BufferList); +module.exports = arrayLikeKeys; - this.head = null; - this.tail = null; - this.length = 0; - } - BufferList.prototype.push = function push(v) { - var entry = { data: v, next: null }; - if (this.length > 0) this.tail.next = entry;else this.head = entry; - this.tail = entry; - ++this.length; - }; +/***/ }), - BufferList.prototype.unshift = function unshift(v) { - var entry = { data: v, next: this.head }; - if (this.length === 0) this.tail = entry; - this.head = entry; - ++this.length; - }; +/***/ 58377: +/***/ ((module) => { - BufferList.prototype.shift = function shift() { - if (this.length === 0) return; - var ret = this.head.data; - if (this.length === 1) this.head = this.tail = null;else this.head = this.head.next; - --this.length; - return ret; - }; +/** + * A specialized version of `_.map` for arrays without support for iteratee + * shorthands. + * + * @private + * @param {Array} [array] The array to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @returns {Array} Returns the new mapped array. + */ +function arrayMap(array, iteratee) { + var index = -1, + length = array == null ? 0 : array.length, + result = Array(length); - BufferList.prototype.clear = function clear() { - this.head = this.tail = null; - this.length = 0; - }; + while (++index < length) { + result[index] = iteratee(array[index], index, array); + } + return result; +} - BufferList.prototype.join = function join(s) { - if (this.length === 0) return ''; - var p = this.head; - var ret = '' + p.data; - while (p = p.next) { - ret += s + p.data; - }return ret; - }; +module.exports = arrayMap; - BufferList.prototype.concat = function concat(n) { - if (this.length === 0) return Buffer.alloc(0); - var ret = Buffer.allocUnsafe(n >>> 0); - var p = this.head; - var i = 0; - while (p) { - copyBuffer(p.data, ret, i); - i += p.data.length; - p = p.next; - } - return ret; - }; - return BufferList; -}(); +/***/ }), -if (util && util.inspect && util.inspect.custom) { - module.exports.prototype[util.inspect.custom] = function () { - var obj = util.inspect({ length: this.length }); - return this.constructor.name + ' ' + obj; - }; +/***/ 39691: +/***/ ((module) => { + +/** + * Appends the elements of `values` to `array`. + * + * @private + * @param {Array} array The array to modify. + * @param {Array} values The values to append. + * @returns {Array} Returns `array`. + */ +function arrayPush(array, values) { + var index = -1, + length = values.length, + offset = array.length; + + while (++index < length) { + array[offset + index] = values[index]; + } + return array; } +module.exports = arrayPush; + + /***/ }), -/***/ 91031: +/***/ 47048: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +var eq = __nccwpck_require__(35455); +/** + * Gets the index at which the `key` is found in `array` of key-value pairs. + * + * @private + * @param {Array} array The array to inspect. + * @param {*} key The key to search for. + * @returns {number} Returns the index of the matched value, else `-1`. + */ +function assocIndexOf(array, key) { + var length = array.length; + while (length--) { + if (eq(array[length][0], key)) { + return length; + } + } + return -1; +} -/**/ +module.exports = assocIndexOf; -var pna = __nccwpck_require__(41564); -/**/ -// undocumented cb() API, needed for core, not for public API -function destroy(err, cb) { - var _this = this; +/***/ }), - var readableDestroyed = this._readableState && this._readableState.destroyed; - var writableDestroyed = this._writableState && this._writableState.destroyed; +/***/ 26998: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - if (readableDestroyed || writableDestroyed) { - if (cb) { - cb(err); - } else if (err) { - if (!this._writableState) { - pna.nextTick(emitErrorNT, this, err); - } else if (!this._writableState.errorEmitted) { - this._writableState.errorEmitted = true; - pna.nextTick(emitErrorNT, this, err); - } - } +var SetCache = __nccwpck_require__(88058), + arrayIncludes = __nccwpck_require__(67270), + arrayIncludesWith = __nccwpck_require__(81954), + arrayMap = __nccwpck_require__(58377), + baseUnary = __nccwpck_require__(80786), + cacheHas = __nccwpck_require__(91750); - return this; - } +/** Used as the size to enable large array optimizations. */ +var LARGE_ARRAY_SIZE = 200; - // we set destroyed to true before firing error callbacks in order - // to make it re-entrance safe in case destroy() is called within callbacks +/** + * The base implementation of methods like `_.difference` without support + * for excluding multiple arrays or iteratee shorthands. + * + * @private + * @param {Array} array The array to inspect. + * @param {Array} values The values to exclude. + * @param {Function} [iteratee] The iteratee invoked per element. + * @param {Function} [comparator] The comparator invoked per element. + * @returns {Array} Returns the new array of filtered values. + */ +function baseDifference(array, values, iteratee, comparator) { + var index = -1, + includes = arrayIncludes, + isCommon = true, + length = array.length, + result = [], + valuesLength = values.length; - if (this._readableState) { - this._readableState.destroyed = true; + if (!length) { + return result; } - - // if this is a duplex stream mark the writable part as destroyed as well - if (this._writableState) { - this._writableState.destroyed = true; + if (iteratee) { + values = arrayMap(values, baseUnary(iteratee)); + } + if (comparator) { + includes = arrayIncludesWith; + isCommon = false; + } + else if (values.length >= LARGE_ARRAY_SIZE) { + includes = cacheHas; + isCommon = false; + values = new SetCache(values); } + outer: + while (++index < length) { + var value = array[index], + computed = iteratee == null ? value : iteratee(value); - this._destroy(err || null, function (err) { - if (!cb && err) { - if (!_this._writableState) { - pna.nextTick(emitErrorNT, _this, err); - } else if (!_this._writableState.errorEmitted) { - _this._writableState.errorEmitted = true; - pna.nextTick(emitErrorNT, _this, err); + value = (comparator || value !== 0) ? value : 0; + if (isCommon && computed === computed) { + var valuesIndex = valuesLength; + while (valuesIndex--) { + if (values[valuesIndex] === computed) { + continue outer; + } } - } else if (cb) { - cb(err); + result.push(value); } - }); - - return this; + else if (!includes(values, computed, comparator)) { + result.push(value); + } + } + return result; } -function undestroy() { - if (this._readableState) { - this._readableState.destroyed = false; - this._readableState.reading = false; - this._readableState.ended = false; - this._readableState.endEmitted = false; - } +module.exports = baseDifference; - if (this._writableState) { - this._writableState.destroyed = false; - this._writableState.ended = false; - this._writableState.ending = false; - this._writableState.finalCalled = false; - this._writableState.prefinished = false; - this._writableState.finished = false; - this._writableState.errorEmitted = false; + +/***/ }), + +/***/ 11684: +/***/ ((module) => { + +/** + * The base implementation of `_.findIndex` and `_.findLastIndex` without + * support for iteratee shorthands. + * + * @private + * @param {Array} array The array to inspect. + * @param {Function} predicate The function invoked per iteration. + * @param {number} fromIndex The index to search from. + * @param {boolean} [fromRight] Specify iterating from right to left. + * @returns {number} Returns the index of the matched value, else `-1`. + */ +function baseFindIndex(array, predicate, fromIndex, fromRight) { + var length = array.length, + index = fromIndex + (fromRight ? 1 : -1); + + while ((fromRight ? index-- : ++index < length)) { + if (predicate(array[index], index, array)) { + return index; + } } + return -1; } -function emitErrorNT(self, err) { - self.emit('error', err); -} +module.exports = baseFindIndex; -module.exports = { - destroy: destroy, - undestroy: undestroy -}; /***/ }), -/***/ 87137: +/***/ 57999: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -module.exports = __nccwpck_require__(2203); +var arrayPush = __nccwpck_require__(39691), + isFlattenable = __nccwpck_require__(52928); + +/** + * The base implementation of `_.flatten` with support for restricting flattening. + * + * @private + * @param {Array} array The array to flatten. + * @param {number} depth The maximum recursion depth. + * @param {boolean} [predicate=isFlattenable] The function invoked per iteration. + * @param {boolean} [isStrict] Restrict to values that pass `predicate` checks. + * @param {Array} [result=[]] The initial result value. + * @returns {Array} Returns the new flattened array. + */ +function baseFlatten(array, depth, predicate, isStrict, result) { + var index = -1, + length = array.length; + + predicate || (predicate = isFlattenable); + result || (result = []); + + while (++index < length) { + var value = array[index]; + if (depth > 0 && predicate(value)) { + if (depth > 1) { + // Recursively flatten arrays (susceptible to call stack limits). + baseFlatten(value, depth - 1, predicate, isStrict, result); + } else { + arrayPush(result, value); + } + } else if (!isStrict) { + result[result.length] = value; + } + } + return result; +} + +module.exports = baseFlatten; /***/ }), -/***/ 1835: +/***/ 61661: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -module.exports = __nccwpck_require__(73109).PassThrough +var Symbol = __nccwpck_require__(85720), + getRawTag = __nccwpck_require__(49180), + objectToString = __nccwpck_require__(3819); + +/** `Object#toString` result references. */ +var nullTag = '[object Null]', + undefinedTag = '[object Undefined]'; + +/** Built-in value references. */ +var symToStringTag = Symbol ? Symbol.toStringTag : undefined; + +/** + * The base implementation of `getTag` without fallbacks for buggy environments. + * + * @private + * @param {*} value The value to query. + * @returns {string} Returns the `toStringTag`. + */ +function baseGetTag(value) { + if (value == null) { + return value === undefined ? undefinedTag : nullTag; + } + return (symToStringTag && symToStringTag in Object(value)) + ? getRawTag(value) + : objectToString(value); +} + +module.exports = baseGetTag; /***/ }), -/***/ 73109: -/***/ ((module, exports, __nccwpck_require__) => { +/***/ 85496: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var Stream = __nccwpck_require__(2203); -if (process.env.READABLE_STREAM === 'disable' && Stream) { - module.exports = Stream; - exports = module.exports = Stream.Readable; - exports.Readable = Stream.Readable; - exports.Writable = Stream.Writable; - exports.Duplex = Stream.Duplex; - exports.Transform = Stream.Transform; - exports.PassThrough = Stream.PassThrough; - exports.Stream = Stream; -} else { - exports = module.exports = __nccwpck_require__(74559); - exports.Stream = Stream || exports; - exports.Readable = exports; - exports.Writable = __nccwpck_require__(54579); - exports.Duplex = __nccwpck_require__(34793); - exports.Transform = __nccwpck_require__(69343); - exports.PassThrough = __nccwpck_require__(72029); +var baseFindIndex = __nccwpck_require__(11684), + baseIsNaN = __nccwpck_require__(79760), + strictIndexOf = __nccwpck_require__(93152); + +/** + * The base implementation of `_.indexOf` without `fromIndex` bounds checks. + * + * @private + * @param {Array} array The array to inspect. + * @param {*} value The value to search for. + * @param {number} fromIndex The index to search from. + * @returns {number} Returns the index of the matched value, else `-1`. + */ +function baseIndexOf(array, value, fromIndex) { + return value === value + ? strictIndexOf(array, value, fromIndex) + : baseFindIndex(array, baseIsNaN, fromIndex); } +module.exports = baseIndexOf; + /***/ }), -/***/ 13644: -/***/ ((module, exports, __nccwpck_require__) => { +/***/ 76069: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -/* eslint-disable node/no-deprecated-api */ -var buffer = __nccwpck_require__(20181) -var Buffer = buffer.Buffer +var baseGetTag = __nccwpck_require__(61661), + isObjectLike = __nccwpck_require__(47677); -// alternative to using Object.keys for old browsers -function copyProps (src, dst) { - for (var key in src) { - dst[key] = src[key] - } -} -if (Buffer.from && Buffer.alloc && Buffer.allocUnsafe && Buffer.allocUnsafeSlow) { - module.exports = buffer -} else { - // Copy properties from require('buffer') - copyProps(buffer, exports) - exports.Buffer = SafeBuffer -} +/** `Object#toString` result references. */ +var argsTag = '[object Arguments]'; -function SafeBuffer (arg, encodingOrOffset, length) { - return Buffer(arg, encodingOrOffset, length) +/** + * The base implementation of `_.isArguments`. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an `arguments` object, + */ +function baseIsArguments(value) { + return isObjectLike(value) && baseGetTag(value) == argsTag; } -// Copy static methods from Buffer -copyProps(Buffer, SafeBuffer) +module.exports = baseIsArguments; -SafeBuffer.from = function (arg, encodingOrOffset, length) { - if (typeof arg === 'number') { - throw new TypeError('Argument must not be a number') - } - return Buffer(arg, encodingOrOffset, length) -} -SafeBuffer.alloc = function (size, fill, encoding) { - if (typeof size !== 'number') { - throw new TypeError('Argument must be a number') - } - var buf = Buffer(size) - if (fill !== undefined) { - if (typeof encoding === 'string') { - buf.fill(fill, encoding) - } else { - buf.fill(fill) - } - } else { - buf.fill(0) - } - return buf -} +/***/ }), -SafeBuffer.allocUnsafe = function (size) { - if (typeof size !== 'number') { - throw new TypeError('Argument must be a number') - } - return Buffer(size) -} +/***/ 79760: +/***/ ((module) => { -SafeBuffer.allocUnsafeSlow = function (size) { - if (typeof size !== 'number') { - throw new TypeError('Argument must be a number') - } - return buffer.SlowBuffer(size) +/** + * The base implementation of `_.isNaN` without support for number objects. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is `NaN`, else `false`. + */ +function baseIsNaN(value) { + return value !== value; } +module.exports = baseIsNaN; -/***/ }), -/***/ 50176: -/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { +/***/ }), -// Copyright Joyent, Inc. and other Node contributors. -// -// Permission is hereby granted, free of charge, to any person obtaining a -// copy of this software and associated documentation files (the -// "Software"), to deal in the Software without restriction, including -// without limitation the rights to use, copy, modify, merge, publish, -// distribute, sublicense, and/or sell copies of the Software, and to permit -// persons to whom the Software is furnished to do so, subject to the -// following conditions: -// -// The above copyright notice and this permission notice shall be included -// in all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN -// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE -// USE OR OTHER DEALINGS IN THE SOFTWARE. +/***/ 32974: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +var isFunction = __nccwpck_require__(57145), + isMasked = __nccwpck_require__(84789), + isObject = __nccwpck_require__(4962), + toSource = __nccwpck_require__(42024); +/** + * Used to match `RegExp` + * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns). + */ +var reRegExpChar = /[\\^$.*+?()[\]{}|]/g; -/**/ +/** Used to detect host constructors (Safari). */ +var reIsHostCtor = /^\[object .+?Constructor\]$/; -var Buffer = (__nccwpck_require__(13644).Buffer); -/**/ +/** Used for built-in method references. */ +var funcProto = Function.prototype, + objectProto = Object.prototype; -var isEncoding = Buffer.isEncoding || function (encoding) { - encoding = '' + encoding; - switch (encoding && encoding.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 true; - default: - return false; - } -}; +/** Used to resolve the decompiled source of functions. */ +var funcToString = funcProto.toString; -function _normalizeEncoding(enc) { - if (!enc) return 'utf8'; - var retried; - while (true) { - switch (enc) { - 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 enc; - default: - if (retried) return; // undefined - enc = ('' + enc).toLowerCase(); - retried = true; - } - } -}; +/** Used to check objects for own properties. */ +var hasOwnProperty = objectProto.hasOwnProperty; -// Do not cache `Buffer.isEncoding` when checking encoding names as some -// modules monkey-patch it to support additional encodings -function normalizeEncoding(enc) { - var nenc = _normalizeEncoding(enc); - if (typeof nenc !== 'string' && (Buffer.isEncoding === isEncoding || !isEncoding(enc))) throw new Error('Unknown encoding: ' + enc); - return nenc || enc; -} +/** Used to detect if a method is native. */ +var reIsNative = RegExp('^' + + funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\$&') + .replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$' +); -// StringDecoder provides an interface for efficiently splitting a series of -// buffers into a series of JS strings without breaking apart multi-byte -// characters. -exports.I = StringDecoder; -function StringDecoder(encoding) { - this.encoding = normalizeEncoding(encoding); - var nb; - switch (this.encoding) { - case 'utf16le': - this.text = utf16Text; - this.end = utf16End; - nb = 4; - break; - case 'utf8': - this.fillLast = utf8FillLast; - nb = 4; - break; - case 'base64': - this.text = base64Text; - this.end = base64End; - nb = 3; - break; - default: - this.write = simpleWrite; - this.end = simpleEnd; - return; +/** + * The base implementation of `_.isNative` without bad shim checks. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a native function, + * else `false`. + */ +function baseIsNative(value) { + if (!isObject(value) || isMasked(value)) { + return false; } - this.lastNeed = 0; - this.lastTotal = 0; - this.lastChar = Buffer.allocUnsafe(nb); + var pattern = isFunction(value) ? reIsNative : reIsHostCtor; + return pattern.test(toSource(value)); } -StringDecoder.prototype.write = function (buf) { - if (buf.length === 0) return ''; - var r; - var i; - if (this.lastNeed) { - r = this.fillLast(buf); - if (r === undefined) return ''; - i = this.lastNeed; - this.lastNeed = 0; - } else { - i = 0; - } - if (i < buf.length) return r ? r + this.text(buf, i) : this.text(buf, i); - return r || ''; -}; +module.exports = baseIsNative; -StringDecoder.prototype.end = utf8End; -// Returns only complete characters in a Buffer -StringDecoder.prototype.text = utf8Text; +/***/ }), -// Attempts to complete a partial non-UTF-8 character using bytes from a Buffer -StringDecoder.prototype.fillLast = function (buf) { - if (this.lastNeed <= buf.length) { - buf.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, this.lastNeed); - return this.lastChar.toString(this.encoding, 0, this.lastTotal); - } - buf.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, buf.length); - this.lastNeed -= buf.length; -}; +/***/ 4944: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -// Checks the type of a UTF-8 byte, whether it's ASCII, a leading byte, or a -// continuation byte. If an invalid byte is detected, -2 is returned. -function utf8CheckByte(byte) { - if (byte <= 0x7F) return 0;else if (byte >> 5 === 0x06) return 2;else if (byte >> 4 === 0x0E) return 3;else if (byte >> 3 === 0x1E) return 4; - return byte >> 6 === 0x02 ? -1 : -2; -} +var baseGetTag = __nccwpck_require__(61661), + isLength = __nccwpck_require__(24369), + isObjectLike = __nccwpck_require__(47677); -// Checks at most 3 bytes at the end of a Buffer in order to detect an -// incomplete multi-byte UTF-8 character. The total number of bytes (2, 3, or 4) -// needed to complete the UTF-8 character (if applicable) are returned. -function utf8CheckIncomplete(self, buf, i) { - var j = buf.length - 1; - if (j < i) return 0; - var nb = utf8CheckByte(buf[j]); - if (nb >= 0) { - if (nb > 0) self.lastNeed = nb - 1; - return nb; - } - if (--j < i || nb === -2) return 0; - nb = utf8CheckByte(buf[j]); - if (nb >= 0) { - if (nb > 0) self.lastNeed = nb - 2; - return nb; - } - if (--j < i || nb === -2) return 0; - nb = utf8CheckByte(buf[j]); - if (nb >= 0) { - if (nb > 0) { - if (nb === 2) nb = 0;else self.lastNeed = nb - 3; - } - return nb; - } - return 0; -} +/** `Object#toString` result references. */ +var argsTag = '[object Arguments]', + arrayTag = '[object Array]', + boolTag = '[object Boolean]', + dateTag = '[object Date]', + errorTag = '[object Error]', + funcTag = '[object Function]', + mapTag = '[object Map]', + numberTag = '[object Number]', + objectTag = '[object Object]', + regexpTag = '[object RegExp]', + setTag = '[object Set]', + stringTag = '[object String]', + weakMapTag = '[object WeakMap]'; + +var arrayBufferTag = '[object ArrayBuffer]', + dataViewTag = '[object DataView]', + float32Tag = '[object Float32Array]', + float64Tag = '[object Float64Array]', + int8Tag = '[object Int8Array]', + int16Tag = '[object Int16Array]', + int32Tag = '[object Int32Array]', + uint8Tag = '[object Uint8Array]', + uint8ClampedTag = '[object Uint8ClampedArray]', + uint16Tag = '[object Uint16Array]', + uint32Tag = '[object Uint32Array]'; + +/** Used to identify `toStringTag` values of typed arrays. */ +var typedArrayTags = {}; +typedArrayTags[float32Tag] = typedArrayTags[float64Tag] = +typedArrayTags[int8Tag] = typedArrayTags[int16Tag] = +typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] = +typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] = +typedArrayTags[uint32Tag] = true; +typedArrayTags[argsTag] = typedArrayTags[arrayTag] = +typedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] = +typedArrayTags[dataViewTag] = typedArrayTags[dateTag] = +typedArrayTags[errorTag] = typedArrayTags[funcTag] = +typedArrayTags[mapTag] = typedArrayTags[numberTag] = +typedArrayTags[objectTag] = typedArrayTags[regexpTag] = +typedArrayTags[setTag] = typedArrayTags[stringTag] = +typedArrayTags[weakMapTag] = false; -// Validates as many continuation bytes for a multi-byte UTF-8 character as -// needed or are available. If we see a non-continuation byte where we expect -// one, we "replace" the validated continuation bytes we've seen so far with -// a single UTF-8 replacement character ('\ufffd'), to match v8's UTF-8 decoding -// behavior. The continuation byte check is included three times in the case -// where all of the continuation bytes for a character exist in the same buffer. -// It is also done this way as a slight performance increase instead of using a -// loop. -function utf8CheckExtraBytes(self, buf, p) { - if ((buf[0] & 0xC0) !== 0x80) { - self.lastNeed = 0; - return '\ufffd'; - } - if (self.lastNeed > 1 && buf.length > 1) { - if ((buf[1] & 0xC0) !== 0x80) { - self.lastNeed = 1; - return '\ufffd'; - } - if (self.lastNeed > 2 && buf.length > 2) { - if ((buf[2] & 0xC0) !== 0x80) { - self.lastNeed = 2; - return '\ufffd'; - } - } - } +/** + * The base implementation of `_.isTypedArray` without Node.js optimizations. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a typed array, else `false`. + */ +function baseIsTypedArray(value) { + return isObjectLike(value) && + isLength(value.length) && !!typedArrayTags[baseGetTag(value)]; } -// Attempts to complete a multi-byte UTF-8 character using bytes from a Buffer. -function utf8FillLast(buf) { - var p = this.lastTotal - this.lastNeed; - var r = utf8CheckExtraBytes(this, buf, p); - if (r !== undefined) return r; - if (this.lastNeed <= buf.length) { - buf.copy(this.lastChar, p, 0, this.lastNeed); - return this.lastChar.toString(this.encoding, 0, this.lastTotal); - } - buf.copy(this.lastChar, p, 0, buf.length); - this.lastNeed -= buf.length; -} +module.exports = baseIsTypedArray; -// Returns all complete UTF-8 characters in a Buffer. If the Buffer ended on a -// partial character, the character's bytes are buffered until the required -// number of bytes are available. -function utf8Text(buf, i) { - var total = utf8CheckIncomplete(this, buf, i); - if (!this.lastNeed) return buf.toString('utf8', i); - this.lastTotal = total; - var end = buf.length - (total - this.lastNeed); - buf.copy(this.lastChar, 0, end); - return buf.toString('utf8', i, end); -} -// For UTF-8, a replacement character is added when ending on a partial -// character. -function utf8End(buf) { - var r = buf && buf.length ? this.write(buf) : ''; - if (this.lastNeed) return r + '\ufffd'; - return r; -} +/***/ }), -// UTF-16LE typically needs two bytes per character, but even if we have an even -// number of bytes available, we need to check if we end on a leading/high -// surrogate. In that case, we need to wait for the next two bytes in order to -// decode the last character properly. -function utf16Text(buf, i) { - if ((buf.length - i) % 2 === 0) { - var r = buf.toString('utf16le', i); - if (r) { - var c = r.charCodeAt(r.length - 1); - if (c >= 0xD800 && c <= 0xDBFF) { - this.lastNeed = 2; - this.lastTotal = 4; - this.lastChar[0] = buf[buf.length - 2]; - this.lastChar[1] = buf[buf.length - 1]; - return r.slice(0, -1); - } - } - return r; - } - this.lastNeed = 1; - this.lastTotal = 2; - this.lastChar[0] = buf[buf.length - 1]; - return buf.toString('utf16le', i, buf.length - 1); -} +/***/ 36046: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -// For UTF-16LE we do not explicitly append special replacement characters if we -// end on a partial character, we simply let v8 handle that. -function utf16End(buf) { - var r = buf && buf.length ? this.write(buf) : ''; - if (this.lastNeed) { - var end = this.lastTotal - this.lastNeed; - return r + this.lastChar.toString('utf16le', 0, end); - } - return r; -} +var isObject = __nccwpck_require__(4962), + isPrototype = __nccwpck_require__(44264), + nativeKeysIn = __nccwpck_require__(75000); -function base64Text(buf, i) { - var n = (buf.length - i) % 3; - if (n === 0) return buf.toString('base64', i); - this.lastNeed = 3 - n; - this.lastTotal = 3; - if (n === 1) { - this.lastChar[0] = buf[buf.length - 1]; - } else { - this.lastChar[0] = buf[buf.length - 2]; - this.lastChar[1] = buf[buf.length - 1]; +/** Used for built-in method references. */ +var objectProto = Object.prototype; + +/** Used to check objects for own properties. */ +var hasOwnProperty = objectProto.hasOwnProperty; + +/** + * The base implementation of `_.keysIn` which doesn't treat sparse arrays as dense. + * + * @private + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property names. + */ +function baseKeysIn(object) { + if (!isObject(object)) { + return nativeKeysIn(object); } - return buf.toString('base64', i, buf.length - n); -} + var isProto = isPrototype(object), + result = []; -function base64End(buf) { - var r = buf && buf.length ? this.write(buf) : ''; - if (this.lastNeed) return r + this.lastChar.toString('base64', 0, 3 - this.lastNeed); - return r; + for (var key in object) { + if (!(key == 'constructor' && (isProto || !hasOwnProperty.call(object, key)))) { + result.push(key); + } + } + return result; } -// Pass bytes on through for single-byte encodings (e.g. ascii, latin1, hex) -function simpleWrite(buf) { - return buf.toString(this.encoding); -} +module.exports = baseKeysIn; -function simpleEnd(buf) { - return buf && buf.length ? this.write(buf) : ''; -} /***/ }), -/***/ 46248: -/***/ ((module) => { +/***/ 13395: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var identity = __nccwpck_require__(22659), + overRest = __nccwpck_require__(89256), + setToString = __nccwpck_require__(87370); /** - * lodash (Custom Build) - * Build: `lodash modularize exports="npm" -o ./` - * Copyright jQuery Foundation and other contributors - * Released under MIT license - * Based on Underscore.js 1.8.3 - * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + * The base implementation of `_.rest` which doesn't validate or coerce arguments. + * + * @private + * @param {Function} func The function to apply a rest parameter to. + * @param {number} [start=func.length-1] The start position of the rest parameter. + * @returns {Function} Returns the new function. */ +function baseRest(func, start) { + return setToString(overRest(func, start, identity), func + ''); +} -/** Used as references for various `Number` constants. */ -var INFINITY = 1 / 0, - MAX_SAFE_INTEGER = 9007199254740991, - MAX_INTEGER = 1.7976931348623157e+308, - NAN = 0 / 0; +module.exports = baseRest; -/** `Object#toString` result references. */ -var argsTag = '[object Arguments]', - funcTag = '[object Function]', - genTag = '[object GeneratorFunction]', - stringTag = '[object String]', - symbolTag = '[object Symbol]'; -/** Used to match leading and trailing whitespace. */ -var reTrim = /^\s+|\s+$/g; +/***/ }), -/** Used to detect bad signed hexadecimal string values. */ -var reIsBadHex = /^[-+]0x[0-9a-f]+$/i; +/***/ 84793: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -/** Used to detect binary string values. */ -var reIsBinary = /^0b[01]+$/i; +var constant = __nccwpck_require__(89569), + defineProperty = __nccwpck_require__(99522), + identity = __nccwpck_require__(22659); -/** Used to detect octal string values. */ -var reIsOctal = /^0o[0-7]+$/i; +/** + * The base implementation of `setToString` without support for hot loop shorting. + * + * @private + * @param {Function} func The function to modify. + * @param {Function} string The `toString` result. + * @returns {Function} Returns `func`. + */ +var baseSetToString = !defineProperty ? identity : function(func, string) { + return defineProperty(func, 'toString', { + 'configurable': true, + 'enumerable': false, + 'value': constant(string), + 'writable': true + }); +}; -/** Used to detect unsigned integer values. */ -var reIsUint = /^(?:0|[1-9]\d*)$/; +module.exports = baseSetToString; -/** Built-in method references without a dependency on `root`. */ -var freeParseInt = parseInt; + +/***/ }), + +/***/ 47027: +/***/ ((module) => { /** - * A specialized version of `_.map` for arrays without support for iteratee - * shorthands. + * The base implementation of `_.times` without support for iteratee shorthands + * or max array length checks. * * @private - * @param {Array} [array] The array to iterate over. + * @param {number} n The number of times to invoke `iteratee`. * @param {Function} iteratee The function invoked per iteration. - * @returns {Array} Returns the new mapped array. + * @returns {Array} Returns the array of results. */ -function arrayMap(array, iteratee) { +function baseTimes(n, iteratee) { var index = -1, - length = array ? array.length : 0, - result = Array(length); + result = Array(n); - while (++index < length) { - result[index] = iteratee(array[index], index, array); + while (++index < n) { + result[index] = iteratee(index); } return result; } +module.exports = baseTimes; + + +/***/ }), + +/***/ 80786: +/***/ ((module) => { + /** - * The base implementation of `_.findIndex` and `_.findLastIndex` without - * support for iteratee shorthands. + * The base implementation of `_.unary` without support for storing metadata. * * @private - * @param {Array} array The array to inspect. - * @param {Function} predicate The function invoked per iteration. - * @param {number} fromIndex The index to search from. - * @param {boolean} [fromRight] Specify iterating from right to left. - * @returns {number} Returns the index of the matched value, else `-1`. + * @param {Function} func The function to cap arguments for. + * @returns {Function} Returns the new capped function. */ -function baseFindIndex(array, predicate, fromIndex, fromRight) { - var length = array.length, - index = fromIndex + (fromRight ? 1 : -1); - - while ((fromRight ? index-- : ++index < length)) { - if (predicate(array[index], index, array)) { - return index; - } - } - return -1; +function baseUnary(func) { + return function(value) { + return func(value); + }; } +module.exports = baseUnary; + + +/***/ }), + +/***/ 69380: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var SetCache = __nccwpck_require__(88058), + arrayIncludes = __nccwpck_require__(67270), + arrayIncludesWith = __nccwpck_require__(81954), + cacheHas = __nccwpck_require__(91750), + createSet = __nccwpck_require__(54130), + setToArray = __nccwpck_require__(42038); + +/** Used as the size to enable large array optimizations. */ +var LARGE_ARRAY_SIZE = 200; + /** - * The base implementation of `_.indexOf` without `fromIndex` bounds checks. + * The base implementation of `_.uniqBy` without support for iteratee shorthands. * * @private * @param {Array} array The array to inspect. - * @param {*} value The value to search for. - * @param {number} fromIndex The index to search from. - * @returns {number} Returns the index of the matched value, else `-1`. + * @param {Function} [iteratee] The iteratee invoked per element. + * @param {Function} [comparator] The comparator invoked per element. + * @returns {Array} Returns the new duplicate free array. */ -function baseIndexOf(array, value, fromIndex) { - if (value !== value) { - return baseFindIndex(array, baseIsNaN, fromIndex); - } - var index = fromIndex - 1, - length = array.length; +function baseUniq(array, iteratee, comparator) { + var index = -1, + includes = arrayIncludes, + length = array.length, + isCommon = true, + result = [], + seen = result; + if (comparator) { + isCommon = false; + includes = arrayIncludesWith; + } + else if (length >= LARGE_ARRAY_SIZE) { + var set = iteratee ? null : createSet(array); + if (set) { + return setToArray(set); + } + isCommon = false; + includes = cacheHas; + seen = new SetCache; + } + else { + seen = iteratee ? [] : result; + } + outer: while (++index < length) { - if (array[index] === value) { - return index; + var value = array[index], + computed = iteratee ? iteratee(value) : value; + + value = (comparator || value !== 0) ? value : 0; + if (isCommon && computed === computed) { + var seenIndex = seen.length; + while (seenIndex--) { + if (seen[seenIndex] === computed) { + continue outer; + } + } + if (iteratee) { + seen.push(computed); + } + result.push(value); + } + else if (!includes(seen, computed, comparator)) { + if (seen !== result) { + seen.push(computed); + } + result.push(value); } } - return -1; + return result; } +module.exports = baseUniq; + + +/***/ }), + +/***/ 91750: +/***/ ((module) => { + /** - * The base implementation of `_.isNaN` without support for number objects. + * Checks if a `cache` value for `key` exists. * * @private - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is `NaN`, else `false`. + * @param {Object} cache The cache to query. + * @param {string} key The key of the entry to check. + * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`. */ -function baseIsNaN(value) { - return value !== value; +function cacheHas(cache, key) { + return cache.has(key); } +module.exports = cacheHas; + + +/***/ }), + +/***/ 21500: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var root = __nccwpck_require__(64060); + +/** Used to detect overreaching core-js shims. */ +var coreJsData = root['__core-js_shared__']; + +module.exports = coreJsData; + + +/***/ }), + +/***/ 54130: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var Set = __nccwpck_require__(22842), + noop = __nccwpck_require__(67461), + setToArray = __nccwpck_require__(42038); + +/** Used as references for various `Number` constants. */ +var INFINITY = 1 / 0; + /** - * The base implementation of `_.times` without support for iteratee shorthands - * or max array length checks. + * Creates a set object of `values`. * * @private - * @param {number} n The number of times to invoke `iteratee`. - * @param {Function} iteratee The function invoked per iteration. - * @returns {Array} Returns the array of results. + * @param {Array} values The values to add to the set. + * @returns {Object} Returns the new set. */ -function baseTimes(n, iteratee) { - var index = -1, - result = Array(n); +var createSet = !(Set && (1 / setToArray(new Set([,-0]))[1]) == INFINITY) ? noop : function(values) { + return new Set(values); +}; - while (++index < n) { - result[index] = iteratee(index); - } - return result; -} +module.exports = createSet; + + +/***/ }), + +/***/ 99522: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var getNative = __nccwpck_require__(39837); + +var defineProperty = (function() { + try { + var func = getNative(Object, 'defineProperty'); + func({}, '', {}); + return func; + } catch (e) {} +}()); + +module.exports = defineProperty; + + +/***/ }), + +/***/ 12661: +/***/ ((module) => { + +/** Detect free variable `global` from Node.js. */ +var freeGlobal = typeof global == 'object' && global && global.Object === Object && global; + +module.exports = freeGlobal; + + +/***/ }), + +/***/ 21930: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var isKeyable = __nccwpck_require__(32829); /** - * The base implementation of `_.values` and `_.valuesIn` which creates an - * array of `object` property values corresponding to the property names - * of `props`. + * Gets the data for `map`. * * @private - * @param {Object} object The object to query. - * @param {Array} props The property names to get values for. - * @returns {Object} Returns the array of property values. + * @param {Object} map The map to query. + * @param {string} key The reference key. + * @returns {*} Returns the map data. */ -function baseValues(object, props) { - return arrayMap(props, function(key) { - return object[key]; - }); +function getMapData(map, key) { + var data = map.__data__; + return isKeyable(key) + ? data[typeof key == 'string' ? 'string' : 'hash'] + : data.map; } +module.exports = getMapData; + + +/***/ }), + +/***/ 39837: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var baseIsNative = __nccwpck_require__(32974), + getValue = __nccwpck_require__(88453); + /** - * Creates a unary function that invokes `func` with its argument transformed. + * Gets the native function at `key` of `object`. * * @private - * @param {Function} func The function to wrap. - * @param {Function} transform The argument transform. - * @returns {Function} Returns the new function. + * @param {Object} object The object to query. + * @param {string} key The key of the method to get. + * @returns {*} Returns the function if it's native, else `undefined`. */ -function overArg(func, transform) { - return function(arg) { - return func(transform(arg)); - }; +function getNative(object, key) { + var value = getValue(object, key); + return baseIsNative(value) ? value : undefined; } +module.exports = getNative; + + +/***/ }), + +/***/ 97490: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var overArg = __nccwpck_require__(76584); + +/** Built-in value references. */ +var getPrototype = overArg(Object.getPrototypeOf, Object); + +module.exports = getPrototype; + + +/***/ }), + +/***/ 49180: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var Symbol = __nccwpck_require__(85720); + /** Used for built-in method references. */ var objectProto = Object.prototype; @@ -26707,1191 +26859,1336 @@ var hasOwnProperty = objectProto.hasOwnProperty; * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) * of values. */ -var objectToString = objectProto.toString; +var nativeObjectToString = objectProto.toString; /** Built-in value references. */ -var propertyIsEnumerable = objectProto.propertyIsEnumerable; - -/* Built-in method references for those with the same name as other `lodash` methods. */ -var nativeKeys = overArg(Object.keys, Object), - nativeMax = Math.max; +var symToStringTag = Symbol ? Symbol.toStringTag : undefined; /** - * Creates an array of the enumerable property names of the array-like `value`. + * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values. * * @private * @param {*} value The value to query. - * @param {boolean} inherited Specify returning inherited property names. - * @returns {Array} Returns the array of property names. + * @returns {string} Returns the raw `toStringTag`. */ -function arrayLikeKeys(value, inherited) { - // Safari 8.1 makes `arguments.callee` enumerable in strict mode. - // Safari 9 makes `arguments.length` enumerable in strict mode. - var result = (isArray(value) || isArguments(value)) - ? baseTimes(value.length, String) - : []; +function getRawTag(value) { + var isOwn = hasOwnProperty.call(value, symToStringTag), + tag = value[symToStringTag]; - var length = result.length, - skipIndexes = !!length; + try { + value[symToStringTag] = undefined; + var unmasked = true; + } catch (e) {} - for (var key in value) { - if ((inherited || hasOwnProperty.call(value, key)) && - !(skipIndexes && (key == 'length' || isIndex(key, length)))) { - result.push(key); + var result = nativeObjectToString.call(value); + if (unmasked) { + if (isOwn) { + value[symToStringTag] = tag; + } else { + delete value[symToStringTag]; } } return result; } +module.exports = getRawTag; + + +/***/ }), + +/***/ 88453: +/***/ ((module) => { + /** - * The base implementation of `_.keys` which doesn't treat sparse arrays as dense. + * Gets the value at `key` of `object`. * * @private - * @param {Object} object The object to query. - * @returns {Array} Returns the array of property names. + * @param {Object} [object] The object to query. + * @param {string} key The key of the property to get. + * @returns {*} Returns the property value. */ -function baseKeys(object) { - if (!isPrototype(object)) { - return nativeKeys(object); - } - var result = []; - for (var key in Object(object)) { - if (hasOwnProperty.call(object, key) && key != 'constructor') { - result.push(key); - } - } - return result; +function getValue(object, key) { + return object == null ? undefined : object[key]; } +module.exports = getValue; + + +/***/ }), + +/***/ 35795: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var nativeCreate = __nccwpck_require__(93771); + /** - * Checks if `value` is a valid array-like index. + * Removes all key-value entries from the hash. * * @private - * @param {*} value The value to check. - * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index. - * @returns {boolean} Returns `true` if `value` is a valid index, else `false`. + * @name clear + * @memberOf Hash */ -function isIndex(value, length) { - length = length == null ? MAX_SAFE_INTEGER : length; - return !!length && - (typeof value == 'number' || reIsUint.test(value)) && - (value > -1 && value % 1 == 0 && value < length); +function hashClear() { + this.__data__ = nativeCreate ? nativeCreate(null) : {}; + this.size = 0; } +module.exports = hashClear; + + +/***/ }), + +/***/ 60007: +/***/ ((module) => { + /** - * Checks if `value` is likely a prototype object. + * Removes `key` and its value from the hash. * * @private - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a prototype, else `false`. + * @name delete + * @memberOf Hash + * @param {Object} hash The hash to modify. + * @param {string} key The key of the value to remove. + * @returns {boolean} Returns `true` if the entry was removed, else `false`. */ -function isPrototype(value) { - var Ctor = value && value.constructor, - proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto; - - return value === proto; +function hashDelete(key) { + var result = this.has(key) && delete this.__data__[key]; + this.size -= result ? 1 : 0; + return result; } +module.exports = hashDelete; + + +/***/ }), + +/***/ 12662: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var nativeCreate = __nccwpck_require__(93771); + +/** Used to stand-in for `undefined` hash values. */ +var HASH_UNDEFINED = '__lodash_hash_undefined__'; + +/** Used for built-in method references. */ +var objectProto = Object.prototype; + +/** Used to check objects for own properties. */ +var hasOwnProperty = objectProto.hasOwnProperty; + /** - * Checks if `value` is in `collection`. If `collection` is a string, it's - * checked for a substring of `value`, otherwise - * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) - * is used for equality comparisons. If `fromIndex` is negative, it's used as - * the offset from the end of `collection`. - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Collection - * @param {Array|Object|string} collection The collection to inspect. - * @param {*} value The value to search for. - * @param {number} [fromIndex=0] The index to search from. - * @param- {Object} [guard] Enables use as an iteratee for methods like `_.reduce`. - * @returns {boolean} Returns `true` if `value` is found, else `false`. - * @example - * - * _.includes([1, 2, 3], 1); - * // => true - * - * _.includes([1, 2, 3], 1, 2); - * // => false - * - * _.includes({ 'a': 1, 'b': 2 }, 1); - * // => true + * Gets the hash value for `key`. * - * _.includes('abcd', 'bc'); - * // => true + * @private + * @name get + * @memberOf Hash + * @param {string} key The key of the value to get. + * @returns {*} Returns the entry value. */ -function includes(collection, value, fromIndex, guard) { - collection = isArrayLike(collection) ? collection : values(collection); - fromIndex = (fromIndex && !guard) ? toInteger(fromIndex) : 0; - - var length = collection.length; - if (fromIndex < 0) { - fromIndex = nativeMax(length + fromIndex, 0); +function hashGet(key) { + var data = this.__data__; + if (nativeCreate) { + var result = data[key]; + return result === HASH_UNDEFINED ? undefined : result; } - return isString(collection) - ? (fromIndex <= length && collection.indexOf(value, fromIndex) > -1) - : (!!length && baseIndexOf(collection, value, fromIndex) > -1); + return hasOwnProperty.call(data, key) ? data[key] : undefined; } +module.exports = hashGet; + + +/***/ }), + +/***/ 58405: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var nativeCreate = __nccwpck_require__(93771); + +/** Used for built-in method references. */ +var objectProto = Object.prototype; + +/** Used to check objects for own properties. */ +var hasOwnProperty = objectProto.hasOwnProperty; + /** - * Checks if `value` is likely an `arguments` object. - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an `arguments` object, - * else `false`. - * @example + * Checks if a hash value for `key` exists. * - * _.isArguments(function() { return arguments; }()); - * // => true + * @private + * @name has + * @memberOf Hash + * @param {string} key The key of the entry to check. + * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`. + */ +function hashHas(key) { + var data = this.__data__; + return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key); +} + +module.exports = hashHas; + + +/***/ }), + +/***/ 37930: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var nativeCreate = __nccwpck_require__(93771); + +/** Used to stand-in for `undefined` hash values. */ +var HASH_UNDEFINED = '__lodash_hash_undefined__'; + +/** + * Sets the hash `key` to `value`. * - * _.isArguments([1, 2, 3]); - * // => false + * @private + * @name set + * @memberOf Hash + * @param {string} key The key of the value to set. + * @param {*} value The value to set. + * @returns {Object} Returns the hash instance. */ -function isArguments(value) { - // Safari 8.1 makes `arguments.callee` enumerable in strict mode. - return isArrayLikeObject(value) && hasOwnProperty.call(value, 'callee') && - (!propertyIsEnumerable.call(value, 'callee') || objectToString.call(value) == argsTag); +function hashSet(key, value) { + var data = this.__data__; + this.size += this.has(key) ? 0 : 1; + data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value; + return this; } +module.exports = hashSet; + + +/***/ }), + +/***/ 52928: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var Symbol = __nccwpck_require__(85720), + isArguments = __nccwpck_require__(16861), + isArray = __nccwpck_require__(24840); + +/** Built-in value references. */ +var spreadableSymbol = Symbol ? Symbol.isConcatSpreadable : undefined; + /** - * Checks if `value` is classified as an `Array` object. + * Checks if `value` is a flattenable `arguments` object or array. * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Lang + * @private * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an array, else `false`. - * @example - * - * _.isArray([1, 2, 3]); - * // => true - * - * _.isArray(document.body.children); - * // => false - * - * _.isArray('abc'); - * // => false - * - * _.isArray(_.noop); - * // => false + * @returns {boolean} Returns `true` if `value` is flattenable, else `false`. */ -var isArray = Array.isArray; +function isFlattenable(value) { + return isArray(value) || isArguments(value) || + !!(spreadableSymbol && value && value[spreadableSymbol]); +} + +module.exports = isFlattenable; + + +/***/ }), + +/***/ 73254: +/***/ ((module) => { + +/** Used as references for various `Number` constants. */ +var MAX_SAFE_INTEGER = 9007199254740991; + +/** Used to detect unsigned integer values. */ +var reIsUint = /^(?:0|[1-9]\d*)$/; /** - * Checks if `value` is array-like. A value is considered array-like if it's - * not a function and has a `value.length` that's an integer greater than or - * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`. + * Checks if `value` is a valid array-like index. * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang + * @private * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is array-like, else `false`. - * @example - * - * _.isArrayLike([1, 2, 3]); - * // => true - * - * _.isArrayLike(document.body.children); - * // => true - * - * _.isArrayLike('abc'); - * // => true - * - * _.isArrayLike(_.noop); - * // => false + * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index. + * @returns {boolean} Returns `true` if `value` is a valid index, else `false`. */ -function isArrayLike(value) { - return value != null && isLength(value.length) && !isFunction(value); +function isIndex(value, length) { + var type = typeof value; + length = length == null ? MAX_SAFE_INTEGER : length; + + return !!length && + (type == 'number' || + (type != 'symbol' && reIsUint.test(value))) && + (value > -1 && value % 1 == 0 && value < length); } +module.exports = isIndex; + + +/***/ }), + +/***/ 16885: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var eq = __nccwpck_require__(35455), + isArrayLike = __nccwpck_require__(77839), + isIndex = __nccwpck_require__(73254), + isObject = __nccwpck_require__(4962); + /** - * This method is like `_.isArrayLike` except that it also checks if `value` - * is an object. + * Checks if the given arguments are from an iteratee call. * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an array-like object, + * @private + * @param {*} value The potential iteratee value argument. + * @param {*} index The potential iteratee index or key argument. + * @param {*} object The potential iteratee object argument. + * @returns {boolean} Returns `true` if the arguments are from an iteratee call, * else `false`. - * @example - * - * _.isArrayLikeObject([1, 2, 3]); - * // => true - * - * _.isArrayLikeObject(document.body.children); - * // => true - * - * _.isArrayLikeObject('abc'); - * // => false - * - * _.isArrayLikeObject(_.noop); - * // => false */ -function isArrayLikeObject(value) { - return isObjectLike(value) && isArrayLike(value); +function isIterateeCall(value, index, object) { + if (!isObject(object)) { + return false; + } + var type = typeof index; + if (type == 'number' + ? (isArrayLike(object) && isIndex(index, object.length)) + : (type == 'string' && index in object) + ) { + return eq(object[index], value); + } + return false; } +module.exports = isIterateeCall; + + +/***/ }), + +/***/ 32829: +/***/ ((module) => { + /** - * Checks if `value` is classified as a `Function` object. + * Checks if `value` is suitable for use as unique object key. * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Lang + * @private * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a function, else `false`. - * @example - * - * _.isFunction(_); - * // => true - * - * _.isFunction(/abc/); - * // => false + * @returns {boolean} Returns `true` if `value` is suitable, else `false`. */ -function isFunction(value) { - // The use of `Object#toString` avoids issues with the `typeof` operator - // in Safari 8-9 which returns 'object' for typed array and other constructors. - var tag = isObject(value) ? objectToString.call(value) : ''; - return tag == funcTag || tag == genTag; +function isKeyable(value) { + var type = typeof value; + return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean') + ? (value !== '__proto__') + : (value === null); } +module.exports = isKeyable; + + +/***/ }), + +/***/ 84789: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var coreJsData = __nccwpck_require__(21500); + +/** Used to detect methods masquerading as native. */ +var maskSrcKey = (function() { + var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || ''); + return uid ? ('Symbol(src)_1.' + uid) : ''; +}()); + /** - * Checks if `value` is a valid array-like length. + * Checks if `func` has its source masked. * - * **Note:** This method is loosely based on - * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength). + * @private + * @param {Function} func The function to check. + * @returns {boolean} Returns `true` if `func` is masked, else `false`. + */ +function isMasked(func) { + return !!maskSrcKey && (maskSrcKey in func); +} + +module.exports = isMasked; + + +/***/ }), + +/***/ 44264: +/***/ ((module) => { + +/** Used for built-in method references. */ +var objectProto = Object.prototype; + +/** + * Checks if `value` is likely a prototype object. * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang + * @private * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a valid length, else `false`. - * @example - * - * _.isLength(3); - * // => true - * - * _.isLength(Number.MIN_VALUE); - * // => false + * @returns {boolean} Returns `true` if `value` is a prototype, else `false`. + */ +function isPrototype(value) { + var Ctor = value && value.constructor, + proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto; + + return value === proto; +} + +module.exports = isPrototype; + + +/***/ }), + +/***/ 2479: +/***/ ((module) => { + +/** + * Removes all key-value entries from the list cache. * - * _.isLength(Infinity); - * // => false + * @private + * @name clear + * @memberOf ListCache + */ +function listCacheClear() { + this.__data__ = []; + this.size = 0; +} + +module.exports = listCacheClear; + + +/***/ }), + +/***/ 32299: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var assocIndexOf = __nccwpck_require__(47048); + +/** Used for built-in method references. */ +var arrayProto = Array.prototype; + +/** Built-in value references. */ +var splice = arrayProto.splice; + +/** + * Removes `key` and its value from the list cache. * - * _.isLength('3'); - * // => false + * @private + * @name delete + * @memberOf ListCache + * @param {string} key The key of the value to remove. + * @returns {boolean} Returns `true` if the entry was removed, else `false`. */ -function isLength(value) { - return typeof value == 'number' && - value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; +function listCacheDelete(key) { + var data = this.__data__, + index = assocIndexOf(data, key); + + if (index < 0) { + return false; + } + var lastIndex = data.length - 1; + if (index == lastIndex) { + data.pop(); + } else { + splice.call(data, index, 1); + } + --this.size; + return true; } +module.exports = listCacheDelete; + + +/***/ }), + +/***/ 61322: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var assocIndexOf = __nccwpck_require__(47048); + /** - * Checks if `value` is the - * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) - * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(_.noop); - * // => true + * Gets the list cache value for `key`. * - * _.isObject(null); - * // => false + * @private + * @name get + * @memberOf ListCache + * @param {string} key The key of the value to get. + * @returns {*} Returns the entry value. */ -function isObject(value) { - var type = typeof value; - return !!value && (type == 'object' || type == 'function'); +function listCacheGet(key) { + var data = this.__data__, + index = assocIndexOf(data, key); + + return index < 0 ? undefined : data[index][1]; } +module.exports = listCacheGet; + + +/***/ }), + +/***/ 48942: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var assocIndexOf = __nccwpck_require__(47048); + /** - * Checks if `value` is object-like. A value is object-like if it's not `null` - * and has a `typeof` result of "object". - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is object-like, else `false`. - * @example - * - * _.isObjectLike({}); - * // => true - * - * _.isObjectLike([1, 2, 3]); - * // => true - * - * _.isObjectLike(_.noop); - * // => false + * Checks if a list cache value for `key` exists. * - * _.isObjectLike(null); - * // => false + * @private + * @name has + * @memberOf ListCache + * @param {string} key The key of the entry to check. + * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`. */ -function isObjectLike(value) { - return !!value && typeof value == 'object'; +function listCacheHas(key) { + return assocIndexOf(this.__data__, key) > -1; } +module.exports = listCacheHas; + + +/***/ }), + +/***/ 68534: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var assocIndexOf = __nccwpck_require__(47048); + /** - * Checks if `value` is classified as a `String` primitive or object. - * - * @static - * @since 0.1.0 - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a string, else `false`. - * @example - * - * _.isString('abc'); - * // => true + * Sets the list cache `key` to `value`. * - * _.isString(1); - * // => false + * @private + * @name set + * @memberOf ListCache + * @param {string} key The key of the value to set. + * @param {*} value The value to set. + * @returns {Object} Returns the list cache instance. */ -function isString(value) { - return typeof value == 'string' || - (!isArray(value) && isObjectLike(value) && objectToString.call(value) == stringTag); +function listCacheSet(key, value) { + var data = this.__data__, + index = assocIndexOf(data, key); + + if (index < 0) { + ++this.size; + data.push([key, value]); + } else { + data[index][1] = value; + } + return this; } +module.exports = listCacheSet; + + +/***/ }), + +/***/ 45703: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var Hash = __nccwpck_require__(3856), + ListCache = __nccwpck_require__(75796), + Map = __nccwpck_require__(31456); + /** - * Checks if `value` is classified as a `Symbol` primitive or object. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. - * @example - * - * _.isSymbol(Symbol.iterator); - * // => true + * Removes all key-value entries from the map. * - * _.isSymbol('abc'); - * // => false + * @private + * @name clear + * @memberOf MapCache */ -function isSymbol(value) { - return typeof value == 'symbol' || - (isObjectLike(value) && objectToString.call(value) == symbolTag); +function mapCacheClear() { + this.size = 0; + this.__data__ = { + 'hash': new Hash, + 'map': new (Map || ListCache), + 'string': new Hash + }; } +module.exports = mapCacheClear; + + +/***/ }), + +/***/ 95027: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var getMapData = __nccwpck_require__(21930); + /** - * Converts `value` to a finite number. - * - * @static - * @memberOf _ - * @since 4.12.0 - * @category Lang - * @param {*} value The value to convert. - * @returns {number} Returns the converted number. - * @example - * - * _.toFinite(3.2); - * // => 3.2 - * - * _.toFinite(Number.MIN_VALUE); - * // => 5e-324 - * - * _.toFinite(Infinity); - * // => 1.7976931348623157e+308 + * Removes `key` and its value from the map. * - * _.toFinite('3.2'); - * // => 3.2 + * @private + * @name delete + * @memberOf MapCache + * @param {string} key The key of the value to remove. + * @returns {boolean} Returns `true` if the entry was removed, else `false`. */ -function toFinite(value) { - if (!value) { - return value === 0 ? value : 0; - } - value = toNumber(value); - if (value === INFINITY || value === -INFINITY) { - var sign = (value < 0 ? -1 : 1); - return sign * MAX_INTEGER; - } - return value === value ? value : 0; +function mapCacheDelete(key) { + var result = getMapData(this, key)['delete'](key); + this.size -= result ? 1 : 0; + return result; } +module.exports = mapCacheDelete; + + +/***/ }), + +/***/ 33714: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var getMapData = __nccwpck_require__(21930); + /** - * Converts `value` to an integer. - * - * **Note:** This method is loosely based on - * [`ToInteger`](http://www.ecma-international.org/ecma-262/7.0/#sec-tointeger). - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to convert. - * @returns {number} Returns the converted integer. - * @example - * - * _.toInteger(3.2); - * // => 3 - * - * _.toInteger(Number.MIN_VALUE); - * // => 0 - * - * _.toInteger(Infinity); - * // => 1.7976931348623157e+308 + * Gets the map value for `key`. * - * _.toInteger('3.2'); - * // => 3 + * @private + * @name get + * @memberOf MapCache + * @param {string} key The key of the value to get. + * @returns {*} Returns the entry value. */ -function toInteger(value) { - var result = toFinite(value), - remainder = result % 1; - - return result === result ? (remainder ? result - remainder : result) : 0; +function mapCacheGet(key) { + return getMapData(this, key).get(key); } +module.exports = mapCacheGet; + + +/***/ }), + +/***/ 37862: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var getMapData = __nccwpck_require__(21930); + /** - * Converts `value` to a number. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to process. - * @returns {number} Returns the number. - * @example - * - * _.toNumber(3.2); - * // => 3.2 - * - * _.toNumber(Number.MIN_VALUE); - * // => 5e-324 - * - * _.toNumber(Infinity); - * // => Infinity + * Checks if a map value for `key` exists. * - * _.toNumber('3.2'); - * // => 3.2 + * @private + * @name has + * @memberOf MapCache + * @param {string} key The key of the entry to check. + * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`. */ -function toNumber(value) { - if (typeof value == 'number') { - return value; - } - if (isSymbol(value)) { - return NAN; - } - if (isObject(value)) { - var other = typeof value.valueOf == 'function' ? value.valueOf() : value; - value = isObject(other) ? (other + '') : other; - } - if (typeof value != 'string') { - return value === 0 ? value : +value; - } - value = value.replace(reTrim, ''); - var isBinary = reIsBinary.test(value); - return (isBinary || reIsOctal.test(value)) - ? freeParseInt(value.slice(2), isBinary ? 2 : 8) - : (reIsBadHex.test(value) ? NAN : +value); +function mapCacheHas(key) { + return getMapData(this, key).has(key); } +module.exports = mapCacheHas; + + +/***/ }), + +/***/ 82462: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var getMapData = __nccwpck_require__(21930); + /** - * Creates an array of the own enumerable property names of `object`. - * - * **Note:** Non-object values are coerced to objects. See the - * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys) - * for more details. - * - * @static - * @since 0.1.0 - * @memberOf _ - * @category Object - * @param {Object} object The object to query. - * @returns {Array} Returns the array of property names. - * @example - * - * function Foo() { - * this.a = 1; - * this.b = 2; - * } - * - * Foo.prototype.c = 3; - * - * _.keys(new Foo); - * // => ['a', 'b'] (iteration order is not guaranteed) + * Sets the map `key` to `value`. * - * _.keys('hi'); - * // => ['0', '1'] + * @private + * @name set + * @memberOf MapCache + * @param {string} key The key of the value to set. + * @param {*} value The value to set. + * @returns {Object} Returns the map cache instance. */ -function keys(object) { - return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object); +function mapCacheSet(key, value) { + var data = getMapData(this, key), + size = data.size; + + data.set(key, value); + this.size += data.size == size ? 0 : 1; + return this; } +module.exports = mapCacheSet; + + +/***/ }), + +/***/ 93771: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var getNative = __nccwpck_require__(39837); + +/* Built-in method references that are verified to be native. */ +var nativeCreate = getNative(Object, 'create'); + +module.exports = nativeCreate; + + +/***/ }), + +/***/ 75000: +/***/ ((module) => { + /** - * Creates an array of the own enumerable string keyed property values of `object`. - * - * **Note:** Non-object values are coerced to objects. + * This function is like + * [`Object.keys`](http://ecma-international.org/ecma-262/7.0/#sec-object.keys) + * except that it includes inherited enumerable properties. * - * @static - * @since 0.1.0 - * @memberOf _ - * @category Object + * @private * @param {Object} object The object to query. - * @returns {Array} Returns the array of property values. - * @example - * - * function Foo() { - * this.a = 1; - * this.b = 2; - * } - * - * Foo.prototype.c = 3; - * - * _.values(new Foo); - * // => [1, 2] (iteration order is not guaranteed) - * - * _.values('hi'); - * // => ['h', 'i'] + * @returns {Array} Returns the array of property names. */ -function values(object) { - return object ? baseValues(object, keys(object)) : []; +function nativeKeysIn(object) { + var result = []; + if (object != null) { + for (var key in Object(object)) { + result.push(key); + } + } + return result; } -module.exports = includes; +module.exports = nativeKeysIn; /***/ }), -/***/ 1999: -/***/ ((module) => { +/***/ 63508: +/***/ ((module, exports, __nccwpck_require__) => { -/** - * lodash 3.0.3 (Custom Build) - * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation - * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license - */ +/* module decorator */ module = __nccwpck_require__.nmd(module); +var freeGlobal = __nccwpck_require__(12661); -/** `Object#toString` result references. */ -var boolTag = '[object Boolean]'; +/** Detect free variable `exports`. */ +var freeExports = true && exports && !exports.nodeType && exports; + +/** Detect free variable `module`. */ +var freeModule = freeExports && "object" == 'object' && module && !module.nodeType && module; + +/** Detect the popular CommonJS extension `module.exports`. */ +var moduleExports = freeModule && freeModule.exports === freeExports; + +/** Detect free variable `process` from Node.js. */ +var freeProcess = moduleExports && freeGlobal.process; + +/** Used to access faster Node.js helpers. */ +var nodeUtil = (function() { + try { + // Use `util.types` for Node.js 10+. + var types = freeModule && freeModule.require && freeModule.require('util').types; + + if (types) { + return types; + } + + // Legacy `process.binding('util')` for Node.js < 10. + return freeProcess && freeProcess.binding && freeProcess.binding('util'); + } catch (e) {} +}()); + +module.exports = nodeUtil; + + +/***/ }), + +/***/ 3819: +/***/ ((module) => { /** Used for built-in method references. */ var objectProto = Object.prototype; /** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) * of values. */ -var objectToString = objectProto.toString; +var nativeObjectToString = objectProto.toString; /** - * Checks if `value` is classified as a boolean primitive or object. - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. - * @example - * - * _.isBoolean(false); - * // => true + * Converts `value` to a string using `Object.prototype.toString`. * - * _.isBoolean(null); - * // => false + * @private + * @param {*} value The value to convert. + * @returns {string} Returns the converted string. */ -function isBoolean(value) { - return value === true || value === false || - (isObjectLike(value) && objectToString.call(value) == boolTag); +function objectToString(value) { + return nativeObjectToString.call(value); } +module.exports = objectToString; + + +/***/ }), + +/***/ 76584: +/***/ ((module) => { + /** - * Checks if `value` is object-like. A value is object-like if it's not `null` - * and has a `typeof` result of "object". - * - * @static - * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is object-like, else `false`. - * @example - * - * _.isObjectLike({}); - * // => true - * - * _.isObjectLike([1, 2, 3]); - * // => true - * - * _.isObjectLike(_.noop); - * // => false + * Creates a unary function that invokes `func` with its argument transformed. * - * _.isObjectLike(null); - * // => false + * @private + * @param {Function} func The function to wrap. + * @param {Function} transform The argument transform. + * @returns {Function} Returns the new function. */ -function isObjectLike(value) { - return !!value && typeof value == 'object'; +function overArg(func, transform) { + return function(arg) { + return func(transform(arg)); + }; } -module.exports = isBoolean; +module.exports = overArg; /***/ }), -/***/ 39841: -/***/ ((module) => { +/***/ 89256: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var apply = __nccwpck_require__(67985); + +/* Built-in method references for those with the same name as other `lodash` methods. */ +var nativeMax = Math.max; /** - * lodash (Custom Build) - * Build: `lodash modularize exports="npm" -o ./` - * Copyright jQuery Foundation and other contributors - * Released under MIT license - * Based on Underscore.js 1.8.3 - * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + * A specialized version of `baseRest` which transforms the rest array. + * + * @private + * @param {Function} func The function to apply a rest parameter to. + * @param {number} [start=func.length-1] The start position of the rest parameter. + * @param {Function} transform The rest array transform. + * @returns {Function} Returns the new function. */ +function overRest(func, start, transform) { + start = nativeMax(start === undefined ? (func.length - 1) : start, 0); + return function() { + var args = arguments, + index = -1, + length = nativeMax(args.length - start, 0), + array = Array(length); -/** Used as references for various `Number` constants. */ -var INFINITY = 1 / 0, - MAX_INTEGER = 1.7976931348623157e+308, - NAN = 0 / 0; + while (++index < length) { + array[index] = args[start + index]; + } + index = -1; + var otherArgs = Array(start + 1); + while (++index < start) { + otherArgs[index] = args[index]; + } + otherArgs[start] = transform(array); + return apply(func, this, otherArgs); + }; +} -/** `Object#toString` result references. */ -var symbolTag = '[object Symbol]'; +module.exports = overRest; -/** Used to match leading and trailing whitespace. */ -var reTrim = /^\s+|\s+$/g; -/** Used to detect bad signed hexadecimal string values. */ -var reIsBadHex = /^[-+]0x[0-9a-f]+$/i; +/***/ }), -/** Used to detect binary string values. */ -var reIsBinary = /^0b[01]+$/i; +/***/ 64060: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -/** Used to detect octal string values. */ -var reIsOctal = /^0o[0-7]+$/i; +var freeGlobal = __nccwpck_require__(12661); -/** Built-in method references without a dependency on `root`. */ -var freeParseInt = parseInt; +/** Detect free variable `self`. */ +var freeSelf = typeof self == 'object' && self && self.Object === Object && self; -/** Used for built-in method references. */ -var objectProto = Object.prototype; +/** Used as a reference to the global object. */ +var root = freeGlobal || freeSelf || Function('return this')(); + +module.exports = root; + + +/***/ }), + +/***/ 93343: +/***/ ((module) => { + +/** Used to stand-in for `undefined` hash values. */ +var HASH_UNDEFINED = '__lodash_hash_undefined__'; /** - * Used to resolve the - * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) - * of values. + * Adds `value` to the array cache. + * + * @private + * @name add + * @memberOf SetCache + * @alias push + * @param {*} value The value to cache. + * @returns {Object} Returns the cache instance. */ -var objectToString = objectProto.toString; +function setCacheAdd(value) { + this.__data__.set(value, HASH_UNDEFINED); + return this; +} + +module.exports = setCacheAdd; + + +/***/ }), + +/***/ 80908: +/***/ ((module) => { /** - * Checks if `value` is an integer. - * - * **Note:** This method is based on - * [`Number.isInteger`](https://mdn.io/Number/isInteger). - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an integer, else `false`. - * @example - * - * _.isInteger(3); - * // => true - * - * _.isInteger(Number.MIN_VALUE); - * // => false - * - * _.isInteger(Infinity); - * // => false + * Checks if `value` is in the array cache. * - * _.isInteger('3'); - * // => false + * @private + * @name has + * @memberOf SetCache + * @param {*} value The value to search for. + * @returns {boolean} Returns `true` if `value` is found, else `false`. */ -function isInteger(value) { - return typeof value == 'number' && value == toInteger(value); +function setCacheHas(value) { + return this.__data__.has(value); } +module.exports = setCacheHas; + + +/***/ }), + +/***/ 42038: +/***/ ((module) => { + /** - * Checks if `value` is the - * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) - * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(_.noop); - * // => true + * Converts `set` to an array of its values. * - * _.isObject(null); - * // => false + * @private + * @param {Object} set The set to convert. + * @returns {Array} Returns the values. */ -function isObject(value) { - var type = typeof value; - return !!value && (type == 'object' || type == 'function'); +function setToArray(set) { + var index = -1, + result = Array(set.size); + + set.forEach(function(value) { + result[++index] = value; + }); + return result; } +module.exports = setToArray; + + +/***/ }), + +/***/ 87370: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var baseSetToString = __nccwpck_require__(84793), + shortOut = __nccwpck_require__(89526); + /** - * Checks if `value` is object-like. A value is object-like if it's not `null` - * and has a `typeof` result of "object". - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is object-like, else `false`. - * @example - * - * _.isObjectLike({}); - * // => true - * - * _.isObjectLike([1, 2, 3]); - * // => true + * Sets the `toString` method of `func` to return `string`. * - * _.isObjectLike(_.noop); - * // => false + * @private + * @param {Function} func The function to modify. + * @param {Function} string The `toString` result. + * @returns {Function} Returns `func`. + */ +var setToString = shortOut(baseSetToString); + +module.exports = setToString; + + +/***/ }), + +/***/ 89526: +/***/ ((module) => { + +/** Used to detect hot functions by number of calls within a span of milliseconds. */ +var HOT_COUNT = 800, + HOT_SPAN = 16; + +/* Built-in method references for those with the same name as other `lodash` methods. */ +var nativeNow = Date.now; + +/** + * Creates a function that'll short out and invoke `identity` instead + * of `func` when it's called `HOT_COUNT` or more times in `HOT_SPAN` + * milliseconds. * - * _.isObjectLike(null); - * // => false + * @private + * @param {Function} func The function to restrict. + * @returns {Function} Returns the new shortable function. */ -function isObjectLike(value) { - return !!value && typeof value == 'object'; +function shortOut(func) { + var count = 0, + lastCalled = 0; + + return function() { + var stamp = nativeNow(), + remaining = HOT_SPAN - (stamp - lastCalled); + + lastCalled = stamp; + if (remaining > 0) { + if (++count >= HOT_COUNT) { + return arguments[0]; + } + } else { + count = 0; + } + return func.apply(undefined, arguments); + }; } +module.exports = shortOut; + + +/***/ }), + +/***/ 93152: +/***/ ((module) => { + /** - * Checks if `value` is classified as a `Symbol` primitive or object. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. - * @example - * - * _.isSymbol(Symbol.iterator); - * // => true + * A specialized version of `_.indexOf` which performs strict equality + * comparisons of values, i.e. `===`. * - * _.isSymbol('abc'); - * // => false + * @private + * @param {Array} array The array to inspect. + * @param {*} value The value to search for. + * @param {number} fromIndex The index to search from. + * @returns {number} Returns the index of the matched value, else `-1`. */ -function isSymbol(value) { - return typeof value == 'symbol' || - (isObjectLike(value) && objectToString.call(value) == symbolTag); +function strictIndexOf(array, value, fromIndex) { + var index = fromIndex - 1, + length = array.length; + + while (++index < length) { + if (array[index] === value) { + return index; + } + } + return -1; } +module.exports = strictIndexOf; + + +/***/ }), + +/***/ 42024: +/***/ ((module) => { + +/** Used for built-in method references. */ +var funcProto = Function.prototype; + +/** Used to resolve the decompiled source of functions. */ +var funcToString = funcProto.toString; + /** - * Converts `value` to a finite number. - * - * @static - * @memberOf _ - * @since 4.12.0 - * @category Lang - * @param {*} value The value to convert. - * @returns {number} Returns the converted number. - * @example - * - * _.toFinite(3.2); - * // => 3.2 - * - * _.toFinite(Number.MIN_VALUE); - * // => 5e-324 - * - * _.toFinite(Infinity); - * // => 1.7976931348623157e+308 + * Converts `func` to its source code. * - * _.toFinite('3.2'); - * // => 3.2 + * @private + * @param {Function} func The function to convert. + * @returns {string} Returns the source code. */ -function toFinite(value) { - if (!value) { - return value === 0 ? value : 0; - } - value = toNumber(value); - if (value === INFINITY || value === -INFINITY) { - var sign = (value < 0 ? -1 : 1); - return sign * MAX_INTEGER; +function toSource(func) { + if (func != null) { + try { + return funcToString.call(func); + } catch (e) {} + try { + return (func + ''); + } catch (e) {} } - return value === value ? value : 0; + return ''; } +module.exports = toSource; + + +/***/ }), + +/***/ 89569: +/***/ ((module) => { + /** - * Converts `value` to an integer. - * - * **Note:** This method is loosely based on - * [`ToInteger`](http://www.ecma-international.org/ecma-262/7.0/#sec-tointeger). + * Creates a function that returns `value`. * * @static * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to convert. - * @returns {number} Returns the converted integer. + * @since 2.4.0 + * @category Util + * @param {*} value The value to return from the new function. + * @returns {Function} Returns the new constant function. * @example * - * _.toInteger(3.2); - * // => 3 - * - * _.toInteger(Number.MIN_VALUE); - * // => 0 + * var objects = _.times(2, _.constant({ 'a': 1 })); * - * _.toInteger(Infinity); - * // => 1.7976931348623157e+308 + * console.log(objects); + * // => [{ 'a': 1 }, { 'a': 1 }] * - * _.toInteger('3.2'); - * // => 3 + * console.log(objects[0] === objects[1]); + * // => true */ -function toInteger(value) { - var result = toFinite(value), - remainder = result % 1; - - return result === result ? (remainder ? result - remainder : result) : 0; +function constant(value) { + return function() { + return value; + }; } +module.exports = constant; + + +/***/ }), + +/***/ 6391: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var baseRest = __nccwpck_require__(13395), + eq = __nccwpck_require__(35455), + isIterateeCall = __nccwpck_require__(16885), + keysIn = __nccwpck_require__(14022); + +/** Used for built-in method references. */ +var objectProto = Object.prototype; + +/** Used to check objects for own properties. */ +var hasOwnProperty = objectProto.hasOwnProperty; + /** - * Converts `value` to a number. + * Assigns own and inherited enumerable string keyed properties of source + * objects to the destination object for all destination properties that + * resolve to `undefined`. Source objects are applied from left to right. + * Once a property is set, additional values of the same property are ignored. + * + * **Note:** This method mutates `object`. * * @static + * @since 0.1.0 * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to process. - * @returns {number} Returns the number. + * @category Object + * @param {Object} object The destination object. + * @param {...Object} [sources] The source objects. + * @returns {Object} Returns `object`. + * @see _.defaultsDeep * @example * - * _.toNumber(3.2); - * // => 3.2 - * - * _.toNumber(Number.MIN_VALUE); - * // => 5e-324 - * - * _.toNumber(Infinity); - * // => Infinity - * - * _.toNumber('3.2'); - * // => 3.2 + * _.defaults({ 'a': 1 }, { 'b': 2 }, { 'a': 3 }); + * // => { 'a': 1, 'b': 2 } */ -function toNumber(value) { - if (typeof value == 'number') { - return value; - } - if (isSymbol(value)) { - return NAN; - } - if (isObject(value)) { - var other = typeof value.valueOf == 'function' ? value.valueOf() : value; - value = isObject(other) ? (other + '') : other; - } - if (typeof value != 'string') { - return value === 0 ? value : +value; +var defaults = baseRest(function(object, sources) { + object = Object(object); + + var index = -1; + var length = sources.length; + var guard = length > 2 ? sources[2] : undefined; + + if (guard && isIterateeCall(sources[0], sources[1], guard)) { + length = 1; } - value = value.replace(reTrim, ''); - var isBinary = reIsBinary.test(value); - return (isBinary || reIsOctal.test(value)) - ? freeParseInt(value.slice(2), isBinary ? 2 : 8) - : (reIsBadHex.test(value) ? NAN : +value); -} -module.exports = isInteger; + while (++index < length) { + var source = sources[index]; + var props = keysIn(source); + var propsIndex = -1; + var propsLength = props.length; + while (++propsIndex < propsLength) { + var key = props[propsIndex]; + var value = object[key]; -/***/ }), + if (value === undefined || + (eq(value, objectProto[key]) && !hasOwnProperty.call(object, key))) { + object[key] = source[key]; + } + } + } -/***/ 80116: -/***/ ((module) => { + return object; +}); -/** - * lodash 3.0.3 (Custom Build) - * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation - * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license - */ +module.exports = defaults; -/** `Object#toString` result references. */ -var numberTag = '[object Number]'; -/** Used for built-in method references. */ -var objectProto = Object.prototype; +/***/ }), -/** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) - * of values. - */ -var objectToString = objectProto.toString; +/***/ 11694: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var baseDifference = __nccwpck_require__(26998), + baseFlatten = __nccwpck_require__(57999), + baseRest = __nccwpck_require__(13395), + isArrayLikeObject = __nccwpck_require__(92908); /** - * Checks if `value` is object-like. A value is object-like if it's not `null` - * and has a `typeof` result of "object". + * Creates an array of `array` values not included in the other given arrays + * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) + * for equality comparisons. The order and references of result values are + * determined by the first array. + * + * **Note:** Unlike `_.pullAll`, this method returns a new array. * * @static * @memberOf _ - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @since 0.1.0 + * @category Array + * @param {Array} array The array to inspect. + * @param {...Array} [values] The values to exclude. + * @returns {Array} Returns the new array of filtered values. + * @see _.without, _.xor * @example * - * _.isObjectLike({}); - * // => true - * - * _.isObjectLike([1, 2, 3]); - * // => true - * - * _.isObjectLike(_.noop); - * // => false - * - * _.isObjectLike(null); - * // => false + * _.difference([2, 1], [2, 3]); + * // => [1] */ -function isObjectLike(value) { - return !!value && typeof value == 'object'; -} +var difference = baseRest(function(array, values) { + return isArrayLikeObject(array) + ? baseDifference(array, baseFlatten(values, 1, isArrayLikeObject, true)) + : []; +}); + +module.exports = difference; + + +/***/ }), + +/***/ 35455: +/***/ ((module) => { /** - * Checks if `value` is classified as a `Number` primitive or object. - * - * **Note:** To exclude `Infinity`, `-Infinity`, and `NaN`, which are classified - * as numbers, use the `_.isFinite` method. + * Performs a + * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) + * comparison between two values to determine if they are equivalent. * * @static * @memberOf _ + * @since 4.0.0 * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @param {*} value The value to compare. + * @param {*} other The other value to compare. + * @returns {boolean} Returns `true` if the values are equivalent, else `false`. * @example * - * _.isNumber(3); - * // => true + * var object = { 'a': 1 }; + * var other = { 'a': 1 }; * - * _.isNumber(Number.MIN_VALUE); + * _.eq(object, object); * // => true * - * _.isNumber(Infinity); + * _.eq(object, other); + * // => false + * + * _.eq('a', 'a'); * // => true * - * _.isNumber('3'); + * _.eq('a', Object('a')); * // => false + * + * _.eq(NaN, NaN); + * // => true */ -function isNumber(value) { - return typeof value == 'number' || - (isObjectLike(value) && objectToString.call(value) == numberTag); +function eq(value, other) { + return value === other || (value !== value && other !== other); } -module.exports = isNumber; +module.exports = eq; /***/ }), -/***/ 29888: -/***/ ((module) => { - -/** - * lodash (Custom Build) - * Build: `lodash modularize exports="npm" -o ./` - * Copyright jQuery Foundation and other contributors - * Released under MIT license - * Based on Underscore.js 1.8.3 - * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - */ +/***/ 44183: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -/** `Object#toString` result references. */ -var objectTag = '[object Object]'; +var baseFlatten = __nccwpck_require__(57999); /** - * Checks if `value` is a host object in IE < 9. + * Flattens `array` a single level deep. * - * @private - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a host object, else `false`. - */ -function isHostObject(value) { - // Many host objects are `Object` objects that can coerce to strings - // despite having improperly defined `toString` methods. - var result = false; - if (value != null && typeof value.toString != 'function') { - try { - result = !!(value + ''); - } catch (e) {} - } - return result; -} - -/** - * Creates a unary function that invokes `func` with its argument transformed. + * @static + * @memberOf _ + * @since 0.1.0 + * @category Array + * @param {Array} array The array to flatten. + * @returns {Array} Returns the new flattened array. + * @example * - * @private - * @param {Function} func The function to wrap. - * @param {Function} transform The argument transform. - * @returns {Function} Returns the new function. + * _.flatten([1, [2, [3, [4]], 5]]); + * // => [1, 2, [3, [4]], 5] */ -function overArg(func, transform) { - return function(arg) { - return func(transform(arg)); - }; +function flatten(array) { + var length = array == null ? 0 : array.length; + return length ? baseFlatten(array, 1) : []; } -/** Used for built-in method references. */ -var funcProto = Function.prototype, - objectProto = Object.prototype; - -/** Used to resolve the decompiled source of functions. */ -var funcToString = funcProto.toString; - -/** Used to check objects for own properties. */ -var hasOwnProperty = objectProto.hasOwnProperty; +module.exports = flatten; -/** Used to infer the `Object` constructor. */ -var objectCtorString = funcToString.call(Object); -/** - * Used to resolve the - * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) - * of values. - */ -var objectToString = objectProto.toString; +/***/ }), -/** Built-in value references. */ -var getPrototype = overArg(Object.getPrototypeOf, Object); +/***/ 22659: +/***/ ((module) => { /** - * Checks if `value` is object-like. A value is object-like if it's not `null` - * and has a `typeof` result of "object". + * This method returns the first argument it receives. * * @static + * @since 0.1.0 * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @category Util + * @param {*} value Any value. + * @returns {*} Returns `value`. * @example * - * _.isObjectLike({}); - * // => true + * var object = { 'a': 1 }; * - * _.isObjectLike([1, 2, 3]); + * console.log(_.identity(object) === object); * // => true - * - * _.isObjectLike(_.noop); - * // => false - * - * _.isObjectLike(null); - * // => false */ -function isObjectLike(value) { - return !!value && typeof value == 'object'; +function identity(value) { + return value; } +module.exports = identity; + + +/***/ }), + +/***/ 16861: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var baseIsArguments = __nccwpck_require__(76069), + isObjectLike = __nccwpck_require__(47677); + +/** Used for built-in method references. */ +var objectProto = Object.prototype; + +/** Used to check objects for own properties. */ +var hasOwnProperty = objectProto.hasOwnProperty; + +/** Built-in value references. */ +var propertyIsEnumerable = objectProto.propertyIsEnumerable; + /** - * Checks if `value` is a plain object, that is, an object created by the - * `Object` constructor or one with a `[[Prototype]]` of `null`. + * Checks if `value` is likely an `arguments` object. * * @static * @memberOf _ - * @since 0.8.0 + * @since 0.1.0 * @category Lang * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a plain object, else `false`. + * @returns {boolean} Returns `true` if `value` is an `arguments` object, + * else `false`. * @example * - * function Foo() { - * this.a = 1; - * } - * - * _.isPlainObject(new Foo); - * // => false - * - * _.isPlainObject([1, 2, 3]); - * // => false - * - * _.isPlainObject({ 'x': 0, 'y': 0 }); + * _.isArguments(function() { return arguments; }()); * // => true * - * _.isPlainObject(Object.create(null)); - * // => true + * _.isArguments([1, 2, 3]); + * // => false */ -function isPlainObject(value) { - if (!isObjectLike(value) || - objectToString.call(value) != objectTag || isHostObject(value)) { - return false; - } - var proto = getPrototype(value); - if (proto === null) { - return true; - } - var Ctor = hasOwnProperty.call(proto, 'constructor') && proto.constructor; - return (typeof Ctor == 'function' && - Ctor instanceof Ctor && funcToString.call(Ctor) == objectCtorString); -} +var isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) { + return isObjectLike(value) && hasOwnProperty.call(value, 'callee') && + !propertyIsEnumerable.call(value, 'callee'); +}; -module.exports = isPlainObject; +module.exports = isArguments; /***/ }), -/***/ 56172: +/***/ 24840: /***/ ((module) => { -/** - * lodash 4.0.1 (Custom Build) - * Build: `lodash modularize exports="npm" -o ./` - * Copyright 2012-2016 The Dojo Foundation - * Based on Underscore.js 1.8.3 - * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - * Available under MIT license - */ - -/** `Object#toString` result references. */ -var stringTag = '[object String]'; - -/** Used for built-in method references. */ -var objectProto = Object.prototype; - -/** - * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) - * of values. - */ -var objectToString = objectProto.toString; - /** * Checks if `value` is classified as an `Array` object. * * @static * @memberOf _ - * @type Function + * @since 0.1.0 * @category Lang * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @returns {boolean} Returns `true` if `value` is an array, else `false`. * @example * * _.isArray([1, 2, 3]); @@ -27908,163 +28205,226 @@ var objectToString = objectProto.toString; */ var isArray = Array.isArray; +module.exports = isArray; + + +/***/ }), + +/***/ 77839: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var isFunction = __nccwpck_require__(57145), + isLength = __nccwpck_require__(24369); + /** - * Checks if `value` is object-like. A value is object-like if it's not `null` - * and has a `typeof` result of "object". + * Checks if `value` is array-like. A value is considered array-like if it's + * not a function and has a `value.length` that's an integer greater than or + * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`. * * @static * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @returns {boolean} Returns `true` if `value` is array-like, else `false`. * @example * - * _.isObjectLike({}); + * _.isArrayLike([1, 2, 3]); * // => true * - * _.isObjectLike([1, 2, 3]); + * _.isArrayLike(document.body.children); * // => true * - * _.isObjectLike(_.noop); - * // => false + * _.isArrayLike('abc'); + * // => true * - * _.isObjectLike(null); + * _.isArrayLike(_.noop); * // => false */ -function isObjectLike(value) { - return !!value && typeof value == 'object'; +function isArrayLike(value) { + return value != null && isLength(value.length) && !isFunction(value); } +module.exports = isArrayLike; + + +/***/ }), + +/***/ 92908: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var isArrayLike = __nccwpck_require__(77839), + isObjectLike = __nccwpck_require__(47677); + /** - * Checks if `value` is classified as a `String` primitive or object. + * This method is like `_.isArrayLike` except that it also checks if `value` + * is an object. * * @static * @memberOf _ + * @since 4.0.0 * @category Lang * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @returns {boolean} Returns `true` if `value` is an array-like object, + * else `false`. * @example * - * _.isString('abc'); + * _.isArrayLikeObject([1, 2, 3]); * // => true * - * _.isString(1); + * _.isArrayLikeObject(document.body.children); + * // => true + * + * _.isArrayLikeObject('abc'); + * // => false + * + * _.isArrayLikeObject(_.noop); * // => false */ -function isString(value) { - return typeof value == 'string' || - (!isArray(value) && isObjectLike(value) && objectToString.call(value) == stringTag); +function isArrayLikeObject(value) { + return isObjectLike(value) && isArrayLike(value); } -module.exports = isString; +module.exports = isArrayLikeObject; /***/ }), -/***/ 82192: -/***/ ((module) => { +/***/ 59675: +/***/ ((module, exports, __nccwpck_require__) => { -/** - * lodash (Custom Build) - * Build: `lodash modularize exports="npm" -o ./` - * Copyright jQuery Foundation and other contributors - * Released under MIT license - * Based on Underscore.js 1.8.3 - * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors - */ +/* module decorator */ module = __nccwpck_require__.nmd(module); +var root = __nccwpck_require__(64060), + stubFalse = __nccwpck_require__(72362); -/** Used as the `TypeError` message for "Functions" methods. */ -var FUNC_ERROR_TEXT = 'Expected a function'; +/** Detect free variable `exports`. */ +var freeExports = true && exports && !exports.nodeType && exports; -/** Used as references for various `Number` constants. */ -var INFINITY = 1 / 0, - MAX_INTEGER = 1.7976931348623157e+308, - NAN = 0 / 0; +/** Detect free variable `module`. */ +var freeModule = freeExports && "object" == 'object' && module && !module.nodeType && module; -/** `Object#toString` result references. */ -var symbolTag = '[object Symbol]'; +/** Detect the popular CommonJS extension `module.exports`. */ +var moduleExports = freeModule && freeModule.exports === freeExports; -/** Used to match leading and trailing whitespace. */ -var reTrim = /^\s+|\s+$/g; +/** Built-in value references. */ +var Buffer = moduleExports ? root.Buffer : undefined; -/** Used to detect bad signed hexadecimal string values. */ -var reIsBadHex = /^[-+]0x[0-9a-f]+$/i; +/* Built-in method references for those with the same name as other `lodash` methods. */ +var nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined; -/** Used to detect binary string values. */ -var reIsBinary = /^0b[01]+$/i; +/** + * Checks if `value` is a buffer. + * + * @static + * @memberOf _ + * @since 4.3.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a buffer, else `false`. + * @example + * + * _.isBuffer(new Buffer(2)); + * // => true + * + * _.isBuffer(new Uint8Array(2)); + * // => false + */ +var isBuffer = nativeIsBuffer || stubFalse; -/** Used to detect octal string values. */ -var reIsOctal = /^0o[0-7]+$/i; +module.exports = isBuffer; -/** Built-in method references without a dependency on `root`. */ -var freeParseInt = parseInt; -/** Used for built-in method references. */ -var objectProto = Object.prototype; +/***/ }), -/** - * Used to resolve the - * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) - * of values. - */ -var objectToString = objectProto.toString; +/***/ 57145: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var baseGetTag = __nccwpck_require__(61661), + isObject = __nccwpck_require__(4962); + +/** `Object#toString` result references. */ +var asyncTag = '[object AsyncFunction]', + funcTag = '[object Function]', + genTag = '[object GeneratorFunction]', + proxyTag = '[object Proxy]'; /** - * Creates a function that invokes `func`, with the `this` binding and arguments - * of the created function, while it's called less than `n` times. Subsequent - * calls to the created function return the result of the last `func` invocation. + * Checks if `value` is classified as a `Function` object. * * @static * @memberOf _ - * @since 3.0.0 - * @category Function - * @param {number} n The number of calls at which `func` is no longer invoked. - * @param {Function} func The function to restrict. - * @returns {Function} Returns the new restricted function. + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a function, else `false`. * @example * - * jQuery(element).on('click', _.before(5, addContactToList)); - * // => Allows adding up to 4 contacts to the list. + * _.isFunction(_); + * // => true + * + * _.isFunction(/abc/); + * // => false */ -function before(n, func) { - var result; - if (typeof func != 'function') { - throw new TypeError(FUNC_ERROR_TEXT); +function isFunction(value) { + if (!isObject(value)) { + return false; } - n = toInteger(n); - return function() { - if (--n > 0) { - result = func.apply(this, arguments); - } - if (n <= 1) { - func = undefined; - } - return result; - }; + // The use of `Object#toString` avoids issues with the `typeof` operator + // in Safari 9 which returns 'object' for typed arrays and other constructors. + var tag = baseGetTag(value); + return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag; } +module.exports = isFunction; + + +/***/ }), + +/***/ 24369: +/***/ ((module) => { + +/** Used as references for various `Number` constants. */ +var MAX_SAFE_INTEGER = 9007199254740991; + /** - * Creates a function that is restricted to invoking `func` once. Repeat calls - * to the function return the value of the first invocation. The `func` is - * invoked with the `this` binding and arguments of the created function. + * Checks if `value` is a valid array-like length. + * + * **Note:** This method is loosely based on + * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength). * * @static * @memberOf _ - * @since 0.1.0 - * @category Function - * @param {Function} func The function to restrict. - * @returns {Function} Returns the new restricted function. + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a valid length, else `false`. * @example * - * var initialize = _.once(createApplication); - * initialize(); - * initialize(); - * // => `createApplication` is invoked once + * _.isLength(3); + * // => true + * + * _.isLength(Number.MIN_VALUE); + * // => false + * + * _.isLength(Infinity); + * // => false + * + * _.isLength('3'); + * // => false */ -function once(func) { - return before(2, func); +function isLength(value) { + return typeof value == 'number' && + value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; } +module.exports = isLength; + + +/***/ }), + +/***/ 4962: +/***/ ((module) => { + /** * Checks if `value` is the * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) @@ -28092,9 +28452,17 @@ function once(func) { */ function isObject(value) { var type = typeof value; - return !!value && (type == 'object' || type == 'function'); + return value != null && (type == 'object' || type == 'function'); } +module.exports = isObject; + + +/***/ }), + +/***/ 47677: +/***/ ((module) => { + /** * Checks if `value` is object-like. A value is object-like if it's not `null` * and has a `typeof` result of "object". @@ -28120,3574 +28488,3984 @@ function isObject(value) { * // => false */ function isObjectLike(value) { - return !!value && typeof value == 'object'; + return value != null && typeof value == 'object'; } -/** - * Checks if `value` is classified as a `Symbol` primitive or object. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. - * @example - * - * _.isSymbol(Symbol.iterator); - * // => true - * - * _.isSymbol('abc'); - * // => false - */ -function isSymbol(value) { - return typeof value == 'symbol' || - (isObjectLike(value) && objectToString.call(value) == symbolTag); -} +module.exports = isObjectLike; -/** - * Converts `value` to a finite number. - * - * @static - * @memberOf _ - * @since 4.12.0 - * @category Lang - * @param {*} value The value to convert. - * @returns {number} Returns the converted number. - * @example - * - * _.toFinite(3.2); - * // => 3.2 - * - * _.toFinite(Number.MIN_VALUE); - * // => 5e-324 - * - * _.toFinite(Infinity); - * // => 1.7976931348623157e+308 - * - * _.toFinite('3.2'); - * // => 3.2 - */ -function toFinite(value) { - if (!value) { - return value === 0 ? value : 0; - } - value = toNumber(value); - if (value === INFINITY || value === -INFINITY) { - var sign = (value < 0 ? -1 : 1); - return sign * MAX_INTEGER; - } - return value === value ? value : 0; -} -/** - * Converts `value` to an integer. - * - * **Note:** This method is loosely based on - * [`ToInteger`](http://www.ecma-international.org/ecma-262/7.0/#sec-tointeger). - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to convert. - * @returns {number} Returns the converted integer. - * @example - * - * _.toInteger(3.2); - * // => 3 - * - * _.toInteger(Number.MIN_VALUE); - * // => 0 - * - * _.toInteger(Infinity); - * // => 1.7976931348623157e+308 - * - * _.toInteger('3.2'); - * // => 3 - */ -function toInteger(value) { - var result = toFinite(value), - remainder = result % 1; +/***/ }), - return result === result ? (remainder ? result - remainder : result) : 0; -} +/***/ 37406: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +var baseGetTag = __nccwpck_require__(61661), + getPrototype = __nccwpck_require__(97490), + isObjectLike = __nccwpck_require__(47677); + +/** `Object#toString` result references. */ +var objectTag = '[object Object]'; + +/** Used for built-in method references. */ +var funcProto = Function.prototype, + objectProto = Object.prototype; + +/** Used to resolve the decompiled source of functions. */ +var funcToString = funcProto.toString; + +/** Used to check objects for own properties. */ +var hasOwnProperty = objectProto.hasOwnProperty; + +/** Used to infer the `Object` constructor. */ +var objectCtorString = funcToString.call(Object); /** - * Converts `value` to a number. + * Checks if `value` is a plain object, that is, an object created by the + * `Object` constructor or one with a `[[Prototype]]` of `null`. * * @static * @memberOf _ - * @since 4.0.0 + * @since 0.8.0 * @category Lang - * @param {*} value The value to process. - * @returns {number} Returns the number. + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a plain object, else `false`. * @example * - * _.toNumber(3.2); - * // => 3.2 + * function Foo() { + * this.a = 1; + * } * - * _.toNumber(Number.MIN_VALUE); - * // => 5e-324 + * _.isPlainObject(new Foo); + * // => false * - * _.toNumber(Infinity); - * // => Infinity + * _.isPlainObject([1, 2, 3]); + * // => false * - * _.toNumber('3.2'); - * // => 3.2 - */ -function toNumber(value) { - if (typeof value == 'number') { - return value; - } - if (isSymbol(value)) { - return NAN; - } - if (isObject(value)) { - var other = typeof value.valueOf == 'function' ? value.valueOf() : value; - value = isObject(other) ? (other + '') : other; - } - if (typeof value != 'string') { - return value === 0 ? value : +value; - } - value = value.replace(reTrim, ''); - var isBinary = reIsBinary.test(value); - return (isBinary || reIsOctal.test(value)) - ? freeParseInt(value.slice(2), isBinary ? 2 : 8) - : (reIsBadHex.test(value) ? NAN : +value); -} - -module.exports = once; - - -/***/ }), - -/***/ 66320: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - -var hashClear = __nccwpck_require__(48051), - hashDelete = __nccwpck_require__(15431), - hashGet = __nccwpck_require__(26934), - hashHas = __nccwpck_require__(64306), - hashSet = __nccwpck_require__(17226); - -/** - * Creates a hash object. + * _.isPlainObject({ 'x': 0, 'y': 0 }); + * // => true * - * @private - * @constructor - * @param {Array} [entries] The key-value pairs to cache. + * _.isPlainObject(Object.create(null)); + * // => true */ -function Hash(entries) { - var index = -1, - length = entries == null ? 0 : entries.length; - - this.clear(); - while (++index < length) { - var entry = entries[index]; - this.set(entry[0], entry[1]); +function isPlainObject(value) { + if (!isObjectLike(value) || baseGetTag(value) != objectTag) { + return false; } -} - -// Add methods to `Hash`. -Hash.prototype.clear = hashClear; -Hash.prototype['delete'] = hashDelete; -Hash.prototype.get = hashGet; -Hash.prototype.has = hashHas; -Hash.prototype.set = hashSet; - -module.exports = Hash; - - -/***/ }), - -/***/ 68884: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - -var listCacheClear = __nccwpck_require__(99791), - listCacheDelete = __nccwpck_require__(24555), - listCacheGet = __nccwpck_require__(86634), - listCacheHas = __nccwpck_require__(8430), - listCacheSet = __nccwpck_require__(36918); - -/** - * Creates an list cache object. - * - * @private - * @constructor - * @param {Array} [entries] The key-value pairs to cache. - */ -function ListCache(entries) { - var index = -1, - length = entries == null ? 0 : entries.length; - - this.clear(); - while (++index < length) { - var entry = entries[index]; - this.set(entry[0], entry[1]); + var proto = getPrototype(value); + if (proto === null) { + return true; } + var Ctor = hasOwnProperty.call(proto, 'constructor') && proto.constructor; + return typeof Ctor == 'function' && Ctor instanceof Ctor && + funcToString.call(Ctor) == objectCtorString; } -// Add methods to `ListCache`. -ListCache.prototype.clear = listCacheClear; -ListCache.prototype['delete'] = listCacheDelete; -ListCache.prototype.get = listCacheGet; -ListCache.prototype.has = listCacheHas; -ListCache.prototype.set = listCacheSet; - -module.exports = ListCache; +module.exports = isPlainObject; /***/ }), -/***/ 98272: +/***/ 55864: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var getNative = __nccwpck_require__(68573), - root = __nccwpck_require__(6748); - -/* Built-in method references that are verified to be native. */ -var Map = getNative(root, 'Map'); - -module.exports = Map; - - -/***/ }), - -/***/ 79660: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +var baseIsTypedArray = __nccwpck_require__(4944), + baseUnary = __nccwpck_require__(80786), + nodeUtil = __nccwpck_require__(63508); -var mapCacheClear = __nccwpck_require__(88487), - mapCacheDelete = __nccwpck_require__(36275), - mapCacheGet = __nccwpck_require__(30130), - mapCacheHas = __nccwpck_require__(69254), - mapCacheSet = __nccwpck_require__(59806); +/* Node.js helper references. */ +var nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray; /** - * Creates a map cache object to store key-value pairs. + * Checks if `value` is classified as a typed array. * - * @private - * @constructor - * @param {Array} [entries] The key-value pairs to cache. - */ -function MapCache(entries) { - var index = -1, - length = entries == null ? 0 : entries.length; - - this.clear(); - while (++index < length) { - var entry = entries[index]; - this.set(entry[0], entry[1]); - } -} - -// Add methods to `MapCache`. -MapCache.prototype.clear = mapCacheClear; -MapCache.prototype['delete'] = mapCacheDelete; -MapCache.prototype.get = mapCacheGet; -MapCache.prototype.has = mapCacheHas; -MapCache.prototype.set = mapCacheSet; - -module.exports = MapCache; - - -/***/ }), - -/***/ 84986: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - -var getNative = __nccwpck_require__(68573), - root = __nccwpck_require__(6748); - -/* Built-in method references that are verified to be native. */ -var Set = getNative(root, 'Set'); - -module.exports = Set; - - -/***/ }), - -/***/ 23706: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - -var MapCache = __nccwpck_require__(79660), - setCacheAdd = __nccwpck_require__(44671), - setCacheHas = __nccwpck_require__(71884); - -/** + * @static + * @memberOf _ + * @since 3.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a typed array, else `false`. + * @example * - * Creates an array cache object to store unique values. + * _.isTypedArray(new Uint8Array); + * // => true * - * @private - * @constructor - * @param {Array} [values] The values to cache. + * _.isTypedArray([]); + * // => false */ -function SetCache(values) { - var index = -1, - length = values == null ? 0 : values.length; - - this.__data__ = new MapCache; - while (++index < length) { - this.add(values[index]); - } -} - -// Add methods to `SetCache`. -SetCache.prototype.add = SetCache.prototype.push = setCacheAdd; -SetCache.prototype.has = setCacheHas; +var isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray; -module.exports = SetCache; +module.exports = isTypedArray; /***/ }), -/***/ 38584: +/***/ 14022: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var root = __nccwpck_require__(6748); - -/** Built-in value references. */ -var Symbol = root.Symbol; - -module.exports = Symbol; - - -/***/ }), - -/***/ 59678: -/***/ ((module) => { +var arrayLikeKeys = __nccwpck_require__(92400), + baseKeysIn = __nccwpck_require__(36046), + isArrayLike = __nccwpck_require__(77839); /** - * A faster alternative to `Function#apply`, this function invokes `func` - * with the `this` binding of `thisArg` and the arguments of `args`. + * Creates an array of the own and inherited enumerable property names of `object`. * - * @private - * @param {Function} func The function to invoke. - * @param {*} thisArg The `this` binding of `func`. - * @param {Array} args The arguments to invoke `func` with. - * @returns {*} Returns the result of `func`. - */ -function apply(func, thisArg, args) { - switch (args.length) { - case 0: return func.call(thisArg); - case 1: return func.call(thisArg, args[0]); - case 2: return func.call(thisArg, args[0], args[1]); - case 3: return func.call(thisArg, args[0], args[1], args[2]); - } - return func.apply(thisArg, args); -} - -module.exports = apply; - - -/***/ }), - -/***/ 70534: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - -var baseIndexOf = __nccwpck_require__(84760); - -/** - * A specialized version of `_.includes` for arrays without support for - * specifying an index to search from. + * **Note:** Non-object values are coerced to objects. * - * @private - * @param {Array} [array] The array to inspect. - * @param {*} target The value to search for. - * @returns {boolean} Returns `true` if `target` is found, else `false`. - */ -function arrayIncludes(array, value) { - var length = array == null ? 0 : array.length; - return !!length && baseIndexOf(array, value, 0) > -1; -} - -module.exports = arrayIncludes; - - -/***/ }), - -/***/ 37314: -/***/ ((module) => { - -/** - * This function is like `arrayIncludes` except that it accepts a comparator. + * @static + * @memberOf _ + * @since 3.0.0 + * @category Object + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property names. + * @example * - * @private - * @param {Array} [array] The array to inspect. - * @param {*} target The value to search for. - * @param {Function} comparator The comparator invoked per element. - * @returns {boolean} Returns `true` if `target` is found, else `false`. - */ -function arrayIncludesWith(array, value, comparator) { - var index = -1, - length = array == null ? 0 : array.length; - - while (++index < length) { - if (comparator(value, array[index])) { - return true; - } - } - return false; -} - -module.exports = arrayIncludesWith; - - -/***/ }), - -/***/ 62000: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - -var baseTimes = __nccwpck_require__(21299), - isArguments = __nccwpck_require__(60541), - isArray = __nccwpck_require__(77192), - isBuffer = __nccwpck_require__(43739), - isIndex = __nccwpck_require__(37446), - isTypedArray = __nccwpck_require__(35000); - -/** Used for built-in method references. */ -var objectProto = Object.prototype; - -/** Used to check objects for own properties. */ -var hasOwnProperty = objectProto.hasOwnProperty; - -/** - * Creates an array of the enumerable property names of the array-like `value`. + * function Foo() { + * this.a = 1; + * this.b = 2; + * } * - * @private - * @param {*} value The value to query. - * @param {boolean} inherited Specify returning inherited property names. - * @returns {Array} Returns the array of property names. + * Foo.prototype.c = 3; + * + * _.keysIn(new Foo); + * // => ['a', 'b', 'c'] (iteration order is not guaranteed) */ -function arrayLikeKeys(value, inherited) { - var isArr = isArray(value), - isArg = !isArr && isArguments(value), - isBuff = !isArr && !isArg && isBuffer(value), - isType = !isArr && !isArg && !isBuff && isTypedArray(value), - skipIndexes = isArr || isArg || isBuff || isType, - result = skipIndexes ? baseTimes(value.length, String) : [], - length = result.length; - - for (var key in value) { - if ((inherited || hasOwnProperty.call(value, key)) && - !(skipIndexes && ( - // Safari 9 has enumerable `arguments.length` in strict mode. - key == 'length' || - // Node.js 0.10 has enumerable non-index properties on buffers. - (isBuff && (key == 'offset' || key == 'parent')) || - // PhantomJS 2 has enumerable non-index properties on typed arrays. - (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) || - // Skip index properties. - isIndex(key, length) - ))) { - result.push(key); - } - } - return result; +function keysIn(object) { + return isArrayLike(object) ? arrayLikeKeys(object, true) : baseKeysIn(object); } -module.exports = arrayLikeKeys; +module.exports = keysIn; /***/ }), -/***/ 56649: +/***/ 67461: /***/ ((module) => { /** - * A specialized version of `_.map` for arrays without support for iteratee - * shorthands. + * This method returns `undefined`. * - * @private - * @param {Array} [array] The array to iterate over. - * @param {Function} iteratee The function invoked per iteration. - * @returns {Array} Returns the new mapped array. + * @static + * @memberOf _ + * @since 2.3.0 + * @category Util + * @example + * + * _.times(2, _.noop); + * // => [undefined, undefined] */ -function arrayMap(array, iteratee) { - var index = -1, - length = array == null ? 0 : array.length, - result = Array(length); - - while (++index < length) { - result[index] = iteratee(array[index], index, array); - } - return result; +function noop() { + // No operation performed. } -module.exports = arrayMap; +module.exports = noop; /***/ }), -/***/ 50827: +/***/ 72362: /***/ ((module) => { /** - * Appends the elements of `values` to `array`. + * This method returns `false`. * - * @private - * @param {Array} array The array to modify. - * @param {Array} values The values to append. - * @returns {Array} Returns `array`. + * @static + * @memberOf _ + * @since 4.13.0 + * @category Util + * @returns {boolean} Returns `false`. + * @example + * + * _.times(2, _.stubFalse); + * // => [false, false] */ -function arrayPush(array, values) { - var index = -1, - length = values.length, - offset = array.length; - - while (++index < length) { - array[offset + index] = values[index]; - } - return array; +function stubFalse() { + return false; } -module.exports = arrayPush; +module.exports = stubFalse; /***/ }), -/***/ 74024: +/***/ 11350: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var eq = __nccwpck_require__(75199); +var baseFlatten = __nccwpck_require__(57999), + baseRest = __nccwpck_require__(13395), + baseUniq = __nccwpck_require__(69380), + isArrayLikeObject = __nccwpck_require__(92908); /** - * Gets the index at which the `key` is found in `array` of key-value pairs. + * Creates an array of unique values, in order, from all given arrays using + * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) + * for equality comparisons. * - * @private - * @param {Array} array The array to inspect. - * @param {*} key The key to search for. - * @returns {number} Returns the index of the matched value, else `-1`. + * @static + * @memberOf _ + * @since 0.1.0 + * @category Array + * @param {...Array} [arrays] The arrays to inspect. + * @returns {Array} Returns the new array of combined values. + * @example + * + * _.union([2], [1, 2]); + * // => [2, 1] */ -function assocIndexOf(array, key) { - var length = array.length; - while (length--) { - if (eq(array[length][0], key)) { - return length; - } - } - return -1; -} +var union = baseRest(function(arrays) { + return baseUniq(baseFlatten(arrays, 1, isArrayLikeObject, true)); +}); -module.exports = assocIndexOf; +module.exports = union; /***/ }), -/***/ 3126: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/***/ 99391: +/***/ ((module) => { -var SetCache = __nccwpck_require__(23706), - arrayIncludes = __nccwpck_require__(70534), - arrayIncludesWith = __nccwpck_require__(37314), - arrayMap = __nccwpck_require__(56649), - baseUnary = __nccwpck_require__(55506), - cacheHas = __nccwpck_require__(64486); +const isWindows = typeof process === 'object' && + process && + process.platform === 'win32' +module.exports = isWindows ? { sep: '\\' } : { sep: '/' } -/** Used as the size to enable large array optimizations. */ -var LARGE_ARRAY_SIZE = 200; -/** - * The base implementation of methods like `_.difference` without support - * for excluding multiple arrays or iteratee shorthands. - * - * @private - * @param {Array} array The array to inspect. - * @param {Array} values The values to exclude. - * @param {Function} [iteratee] The iteratee invoked per element. - * @param {Function} [comparator] The comparator invoked per element. - * @returns {Array} Returns the new array of filtered values. - */ -function baseDifference(array, values, iteratee, comparator) { - var index = -1, - includes = arrayIncludes, - isCommon = true, - length = array.length, - result = [], - valuesLength = values.length; +/***/ }), - if (!length) { - return result; - } - if (iteratee) { - values = arrayMap(values, baseUnary(iteratee)); - } - if (comparator) { - includes = arrayIncludesWith; - isCommon = false; - } - else if (values.length >= LARGE_ARRAY_SIZE) { - includes = cacheHas; - isCommon = false; - values = new SetCache(values); - } - outer: - while (++index < length) { - var value = array[index], - computed = iteratee == null ? value : iteratee(value); +/***/ 82278: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - value = (comparator || value !== 0) ? value : 0; - if (isCommon && computed === computed) { - var valuesIndex = valuesLength; - while (valuesIndex--) { - if (values[valuesIndex] === computed) { - continue outer; - } - } - result.push(value); - } - else if (!includes(values, computed, comparator)) { - result.push(value); - } +const minimatch = module.exports = (p, pattern, options = {}) => { + assertValidPattern(pattern) + + // shortcut: comments match nothing. + if (!options.nocomment && pattern.charAt(0) === '#') { + return false } - return result; + + return new Minimatch(pattern, options).match(p) } -module.exports = baseDifference; +module.exports = minimatch +const path = __nccwpck_require__(99391) +minimatch.sep = path.sep -/***/ }), +const GLOBSTAR = Symbol('globstar **') +minimatch.GLOBSTAR = GLOBSTAR +const expand = __nccwpck_require__(20822) -/***/ 35588: -/***/ ((module) => { +const plTypes = { + '!': { open: '(?:(?!(?:', close: '))[^/]*?)'}, + '?': { open: '(?:', close: ')?' }, + '+': { open: '(?:', close: ')+' }, + '*': { open: '(?:', close: ')*' }, + '@': { open: '(?:', close: ')' } +} -/** - * The base implementation of `_.findIndex` and `_.findLastIndex` without - * support for iteratee shorthands. - * - * @private - * @param {Array} array The array to inspect. - * @param {Function} predicate The function invoked per iteration. - * @param {number} fromIndex The index to search from. - * @param {boolean} [fromRight] Specify iterating from right to left. - * @returns {number} Returns the index of the matched value, else `-1`. - */ -function baseFindIndex(array, predicate, fromIndex, fromRight) { - var length = array.length, - index = fromIndex + (fromRight ? 1 : -1); +// any single thing other than / +// don't need to escape / when using new RegExp() +const qmark = '[^/]' - while ((fromRight ? index-- : ++index < length)) { - if (predicate(array[index], index, array)) { - return index; - } - } - return -1; -} +// * => any number of characters +const star = qmark + '*?' -module.exports = baseFindIndex; +// ** when dots are allowed. Anything goes, except .. and . +// not (^ or / followed by one or two dots followed by $ or /), +// followed by anything, any number of times. +const twoStarDot = '(?:(?!(?:\\\/|^)(?:\\.{1,2})($|\\\/)).)*?' +// not a ^ or / followed by a dot, +// followed by anything, any number of times. +const twoStarNoDot = '(?:(?!(?:\\\/|^)\\.).)*?' -/***/ }), +// "abc" -> { a:true, b:true, c:true } +const charSet = s => s.split('').reduce((set, c) => { + set[c] = true + return set +}, {}) -/***/ 63183: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +// characters that need to be escaped in RegExp. +const reSpecials = charSet('().*{}+?[]^$\\!') -var arrayPush = __nccwpck_require__(50827), - isFlattenable = __nccwpck_require__(45088); +// characters that indicate we have to add the pattern start +const addPatternStartSet = charSet('[.(') -/** - * The base implementation of `_.flatten` with support for restricting flattening. - * - * @private - * @param {Array} array The array to flatten. - * @param {number} depth The maximum recursion depth. - * @param {boolean} [predicate=isFlattenable] The function invoked per iteration. - * @param {boolean} [isStrict] Restrict to values that pass `predicate` checks. - * @param {Array} [result=[]] The initial result value. - * @returns {Array} Returns the new flattened array. - */ -function baseFlatten(array, depth, predicate, isStrict, result) { - var index = -1, - length = array.length; +// normalizes slashes. +const slashSplit = /\/+/ - predicate || (predicate = isFlattenable); - result || (result = []); +minimatch.filter = (pattern, options = {}) => + (p, i, list) => minimatch(p, pattern, options) - while (++index < length) { - var value = array[index]; - if (depth > 0 && predicate(value)) { - if (depth > 1) { - // Recursively flatten arrays (susceptible to call stack limits). - baseFlatten(value, depth - 1, predicate, isStrict, result); - } else { - arrayPush(result, value); - } - } else if (!isStrict) { - result[result.length] = value; +const ext = (a, b = {}) => { + const t = {} + Object.keys(a).forEach(k => t[k] = a[k]) + Object.keys(b).forEach(k => t[k] = b[k]) + return t +} + +minimatch.defaults = def => { + if (!def || typeof def !== 'object' || !Object.keys(def).length) { + return minimatch + } + + const orig = minimatch + + const m = (p, pattern, options) => orig(p, pattern, ext(def, options)) + m.Minimatch = class Minimatch extends orig.Minimatch { + constructor (pattern, options) { + super(pattern, ext(def, options)) } } - return result; -} + m.Minimatch.defaults = options => orig.defaults(ext(def, options)).Minimatch + m.filter = (pattern, options) => orig.filter(pattern, ext(def, options)) + m.defaults = options => orig.defaults(ext(def, options)) + m.makeRe = (pattern, options) => orig.makeRe(pattern, ext(def, options)) + m.braceExpand = (pattern, options) => orig.braceExpand(pattern, ext(def, options)) + m.match = (list, pattern, options) => orig.match(list, pattern, ext(def, options)) -module.exports = baseFlatten; + return m +} -/***/ }), -/***/ 29117: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var Symbol = __nccwpck_require__(38584), - getRawTag = __nccwpck_require__(95292), - objectToString = __nccwpck_require__(71723); -/** `Object#toString` result references. */ -var nullTag = '[object Null]', - undefinedTag = '[object Undefined]'; +// Brace expansion: +// a{b,c}d -> abd acd +// a{b,}c -> abc ac +// a{0..3}d -> a0d a1d a2d a3d +// a{b,c{d,e}f}g -> abg acdfg acefg +// a{b,c}d{e,f}g -> abdeg acdeg abdeg abdfg +// +// Invalid sets are not expanded. +// a{2..}b -> a{2..}b +// a{b}c -> a{b}c +minimatch.braceExpand = (pattern, options) => braceExpand(pattern, options) -/** Built-in value references. */ -var symToStringTag = Symbol ? Symbol.toStringTag : undefined; +const braceExpand = (pattern, options = {}) => { + assertValidPattern(pattern) -/** - * The base implementation of `getTag` without fallbacks for buggy environments. - * - * @private - * @param {*} value The value to query. - * @returns {string} Returns the `toStringTag`. - */ -function baseGetTag(value) { - if (value == null) { - return value === undefined ? undefinedTag : nullTag; + // Thanks to Yeting Li for + // improving this regexp to avoid a ReDOS vulnerability. + if (options.nobrace || !/\{(?:(?!\{).)*\}/.test(pattern)) { + // shortcut. no need to expand. + return [pattern] } - return (symToStringTag && symToStringTag in Object(value)) - ? getRawTag(value) - : objectToString(value); -} -module.exports = baseGetTag; + return expand(pattern) +} +const MAX_PATTERN_LENGTH = 1024 * 64 +const assertValidPattern = pattern => { + if (typeof pattern !== 'string') { + throw new TypeError('invalid pattern') + } -/***/ }), + if (pattern.length > MAX_PATTERN_LENGTH) { + throw new TypeError('pattern is too long') + } +} -/***/ 84760: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +// parse a component of the expanded set. +// At this point, no pattern may contain "/" in it +// so we're going to return a 2d array, where each entry is the full +// pattern, split on '/', and then turned into a regular expression. +// A regexp is made at the end which joins each array with an +// escaped /, and another full one which joins each regexp with |. +// +// Following the lead of Bash 4.1, note that "**" only has special meaning +// when it is the *only* thing in a path portion. Otherwise, any series +// of * is equivalent to a single *. Globstar behavior is enabled by +// default, and can be disabled by setting options.noglobstar. +const SUBPARSE = Symbol('subparse') -var baseFindIndex = __nccwpck_require__(35588), - baseIsNaN = __nccwpck_require__(34352), - strictIndexOf = __nccwpck_require__(95232); +minimatch.makeRe = (pattern, options) => + new Minimatch(pattern, options || {}).makeRe() -/** - * The base implementation of `_.indexOf` without `fromIndex` bounds checks. - * - * @private - * @param {Array} array The array to inspect. - * @param {*} value The value to search for. - * @param {number} fromIndex The index to search from. - * @returns {number} Returns the index of the matched value, else `-1`. - */ -function baseIndexOf(array, value, fromIndex) { - return value === value - ? strictIndexOf(array, value, fromIndex) - : baseFindIndex(array, baseIsNaN, fromIndex); +minimatch.match = (list, pattern, options = {}) => { + const mm = new Minimatch(pattern, options) + list = list.filter(f => mm.match(f)) + if (mm.options.nonull && !list.length) { + list.push(pattern) + } + return list } -module.exports = baseIndexOf; +// replace stuff like \* with * +const globUnescape = s => s.replace(/\\(.)/g, '$1') +const charUnescape = s => s.replace(/\\([^-\]])/g, '$1') +const regExpEscape = s => s.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, '\\$&') +const braExpEscape = s => s.replace(/[[\]\\]/g, '\\$&') +class Minimatch { + constructor (pattern, options) { + assertValidPattern(pattern) -/***/ }), + if (!options) options = {} -/***/ 93605: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + this.options = options + this.maxGlobstarRecursion = options.maxGlobstarRecursion !== undefined + ? options.maxGlobstarRecursion : 200 + this.set = [] + this.pattern = pattern + this.windowsPathsNoEscape = !!options.windowsPathsNoEscape || + options.allowWindowsEscape === false + if (this.windowsPathsNoEscape) { + this.pattern = this.pattern.replace(/\\/g, '/') + } + this.regexp = null + this.negate = false + this.comment = false + this.empty = false + this.partial = !!options.partial -var baseGetTag = __nccwpck_require__(29117), - isObjectLike = __nccwpck_require__(51645); + // make the set of regexps etc. + this.make() + } -/** `Object#toString` result references. */ -var argsTag = '[object Arguments]'; + debug () {} -/** - * The base implementation of `_.isArguments`. - * - * @private - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an `arguments` object, - */ -function baseIsArguments(value) { - return isObjectLike(value) && baseGetTag(value) == argsTag; -} + make () { + const pattern = this.pattern + const options = this.options -module.exports = baseIsArguments; + // empty patterns and comments match nothing. + if (!options.nocomment && pattern.charAt(0) === '#') { + this.comment = true + return + } + if (!pattern) { + this.empty = true + return + } + // step 1: figure out negation, etc. + this.parseNegate() -/***/ }), + // step 2: expand braces + let set = this.globSet = this.braceExpand() -/***/ 34352: -/***/ ((module) => { + if (options.debug) this.debug = (...args) => console.error(...args) -/** - * The base implementation of `_.isNaN` without support for number objects. - * - * @private - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is `NaN`, else `false`. - */ -function baseIsNaN(value) { - return value !== value; -} + this.debug(this.pattern, set) -module.exports = baseIsNaN; + // step 3: now we have a set, so turn each one into a series of path-portion + // matching patterns. + // These will be regexps, except in the case of "**", which is + // set to the GLOBSTAR object for globstar behavior, + // and will not contain any / characters + set = this.globParts = set.map(s => s.split(slashSplit)) + this.debug(this.pattern, set) -/***/ }), + // glob --> regexps + set = set.map((s, si, set) => s.map(this.parse, this)) -/***/ 92334: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + this.debug(this.pattern, set) -var isFunction = __nccwpck_require__(34329), - isMasked = __nccwpck_require__(46613), - isObject = __nccwpck_require__(96482), - toSource = __nccwpck_require__(57192); + // filter out everything that didn't compile properly. + set = set.filter(s => s.indexOf(false) === -1) -/** - * Used to match `RegExp` - * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns). - */ -var reRegExpChar = /[\\^$.*+?()[\]{}|]/g; + this.debug(this.pattern, set) -/** Used to detect host constructors (Safari). */ -var reIsHostCtor = /^\[object .+?Constructor\]$/; + this.set = set + } -/** Used for built-in method references. */ -var funcProto = Function.prototype, - objectProto = Object.prototype; + parseNegate () { + if (this.options.nonegate) return -/** Used to resolve the decompiled source of functions. */ -var funcToString = funcProto.toString; + const pattern = this.pattern + let negate = false + let negateOffset = 0 -/** Used to check objects for own properties. */ -var hasOwnProperty = objectProto.hasOwnProperty; + for (let i = 0; i < pattern.length && pattern.charAt(i) === '!'; i++) { + negate = !negate + negateOffset++ + } -/** Used to detect if a method is native. */ -var reIsNative = RegExp('^' + - funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\$&') - .replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$' -); + if (negateOffset) this.pattern = pattern.slice(negateOffset) + this.negate = negate + } -/** - * The base implementation of `_.isNative` without bad shim checks. - * - * @private - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a native function, - * else `false`. - */ -function baseIsNative(value) { - if (!isObject(value) || isMasked(value)) { - return false; + // set partial to true to test if, for example, + // "/a/b" matches the start of "/*/b/*/d" + // Partial means, if you run out of file before you run + // out of pattern, then that's fine, as long as all + // the parts match. + matchOne (file, pattern, partial) { + if (pattern.indexOf(GLOBSTAR) !== -1) { + return this._matchGlobstar(file, pattern, partial, 0, 0) + } + return this._matchOne(file, pattern, partial, 0, 0) } - var pattern = isFunction(value) ? reIsNative : reIsHostCtor; - return pattern.test(toSource(value)); -} -module.exports = baseIsNative; + _matchGlobstar (file, pattern, partial, fileIndex, patternIndex) { + // find first globstar from patternIndex + let firstgs = -1 + for (let i = patternIndex; i < pattern.length; i++) { + if (pattern[i] === GLOBSTAR) { firstgs = i; break } + } + // find last globstar + let lastgs = -1 + for (let i = pattern.length - 1; i >= 0; i--) { + if (pattern[i] === GLOBSTAR) { lastgs = i; break } + } -/***/ }), + const head = pattern.slice(patternIndex, firstgs) + const body = partial ? pattern.slice(firstgs + 1) : pattern.slice(firstgs + 1, lastgs) + const tail = partial ? [] : pattern.slice(lastgs + 1) -/***/ 16880: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + // check the head + if (head.length) { + const fileHead = file.slice(fileIndex, fileIndex + head.length) + if (!this._matchOne(fileHead, head, partial, 0, 0)) { + return false + } + fileIndex += head.length + } -var baseGetTag = __nccwpck_require__(29117), - isLength = __nccwpck_require__(56657), - isObjectLike = __nccwpck_require__(51645); + // check the tail + let fileTailMatch = 0 + if (tail.length) { + if (tail.length + fileIndex > file.length) return false -/** `Object#toString` result references. */ -var argsTag = '[object Arguments]', - arrayTag = '[object Array]', - boolTag = '[object Boolean]', - dateTag = '[object Date]', - errorTag = '[object Error]', - funcTag = '[object Function]', - mapTag = '[object Map]', - numberTag = '[object Number]', - objectTag = '[object Object]', - regexpTag = '[object RegExp]', - setTag = '[object Set]', - stringTag = '[object String]', - weakMapTag = '[object WeakMap]'; + const tailStart = file.length - tail.length + if (this._matchOne(file, tail, partial, tailStart, 0)) { + fileTailMatch = tail.length + } else { + // affordance for stuff like a/**/* matching a/b/ + if (file[file.length - 1] !== '' || + fileIndex + tail.length === file.length) { + return false + } + if (!this._matchOne(file, tail, partial, tailStart - 1, 0)) { + return false + } + fileTailMatch = tail.length + 1 + } + } -var arrayBufferTag = '[object ArrayBuffer]', - dataViewTag = '[object DataView]', - float32Tag = '[object Float32Array]', - float64Tag = '[object Float64Array]', - int8Tag = '[object Int8Array]', - int16Tag = '[object Int16Array]', - int32Tag = '[object Int32Array]', - uint8Tag = '[object Uint8Array]', - uint8ClampedTag = '[object Uint8ClampedArray]', - uint16Tag = '[object Uint16Array]', - uint32Tag = '[object Uint32Array]'; + // if body is empty (single ** between head and tail) + if (!body.length) { + let sawSome = !!fileTailMatch + for (let i = fileIndex; i < file.length - fileTailMatch; i++) { + const f = String(file[i]) + sawSome = true + if (f === '.' || f === '..' || + (!this.options.dot && f.charAt(0) === '.')) { + return false + } + } + return partial || sawSome + } -/** Used to identify `toStringTag` values of typed arrays. */ -var typedArrayTags = {}; -typedArrayTags[float32Tag] = typedArrayTags[float64Tag] = -typedArrayTags[int8Tag] = typedArrayTags[int16Tag] = -typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] = -typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] = -typedArrayTags[uint32Tag] = true; -typedArrayTags[argsTag] = typedArrayTags[arrayTag] = -typedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] = -typedArrayTags[dataViewTag] = typedArrayTags[dateTag] = -typedArrayTags[errorTag] = typedArrayTags[funcTag] = -typedArrayTags[mapTag] = typedArrayTags[numberTag] = -typedArrayTags[objectTag] = typedArrayTags[regexpTag] = -typedArrayTags[setTag] = typedArrayTags[stringTag] = -typedArrayTags[weakMapTag] = false; + // split body into segments at each GLOBSTAR + const bodySegments = [[[], 0]] + let currentBody = bodySegments[0] + let nonGsParts = 0 + const nonGsPartsSums = [0] + for (const b of body) { + if (b === GLOBSTAR) { + nonGsPartsSums.push(nonGsParts) + currentBody = [[], 0] + bodySegments.push(currentBody) + } else { + currentBody[0].push(b) + nonGsParts++ + } + } -/** - * The base implementation of `_.isTypedArray` without Node.js optimizations. - * - * @private - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a typed array, else `false`. - */ -function baseIsTypedArray(value) { - return isObjectLike(value) && - isLength(value.length) && !!typedArrayTags[baseGetTag(value)]; -} + let idx = bodySegments.length - 1 + const fileLength = file.length - fileTailMatch + for (const b of bodySegments) { + b[1] = fileLength - (nonGsPartsSums[idx--] + b[0].length) + } -module.exports = baseIsTypedArray; + return !!this._matchGlobStarBodySections( + file, bodySegments, fileIndex, 0, partial, 0, !!fileTailMatch + ) + } + // return false for "nope, not matching" + // return null for "not matching, cannot keep trying" + _matchGlobStarBodySections ( + file, bodySegments, fileIndex, bodyIndex, partial, globStarDepth, sawTail + ) { + const bs = bodySegments[bodyIndex] + if (!bs) { + // just make sure there are no bad dots + for (let i = fileIndex; i < file.length; i++) { + sawTail = true + const f = file[i] + if (f === '.' || f === '..' || + (!this.options.dot && f.charAt(0) === '.')) { + return false + } + } + return sawTail + } -/***/ }), + const [body, after] = bs + while (fileIndex <= after) { + const m = this._matchOne( + file.slice(0, fileIndex + body.length), + body, + partial, + fileIndex, + 0 + ) + // if limit exceeded, no match. intentional false negative, + // acceptable break in correctness for security. + if (m && globStarDepth < this.maxGlobstarRecursion) { + const sub = this._matchGlobStarBodySections( + file, bodySegments, + fileIndex + body.length, bodyIndex + 1, + partial, globStarDepth + 1, sawTail + ) + if (sub !== false) { + return sub + } + } + const f = file[fileIndex] + if (f === '.' || f === '..' || + (!this.options.dot && f.charAt(0) === '.')) { + return false + } + fileIndex++ + } + return partial || null + } -/***/ 82094: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + _matchOne (file, pattern, partial, fileIndex, patternIndex) { + let fi, pi, fl, pl + for ( + fi = fileIndex, pi = patternIndex, fl = file.length, pl = pattern.length + ; (fi < fl) && (pi < pl) + ; fi++, pi++ + ) { + this.debug('matchOne loop') + const p = pattern[pi] + const f = file[fi] -var isObject = __nccwpck_require__(96482), - isPrototype = __nccwpck_require__(55944), - nativeKeysIn = __nccwpck_require__(94008); + this.debug(pattern, p, f) -/** Used for built-in method references. */ -var objectProto = Object.prototype; + // should be impossible. + // some invalid regexp stuff in the set. + /* istanbul ignore if */ + if (p === false || p === GLOBSTAR) return false -/** Used to check objects for own properties. */ -var hasOwnProperty = objectProto.hasOwnProperty; + // something other than ** + // non-magic patterns just have to match exactly + // patterns with magic have been turned into regexps. + let hit + if (typeof p === 'string') { + hit = f === p + this.debug('string match', p, f, hit) + } else { + hit = f.match(p) + this.debug('pattern match', p, f, hit) + } -/** - * The base implementation of `_.keysIn` which doesn't treat sparse arrays as dense. - * - * @private - * @param {Object} object The object to query. - * @returns {Array} Returns the array of property names. - */ -function baseKeysIn(object) { - if (!isObject(object)) { - return nativeKeysIn(object); - } - var isProto = isPrototype(object), - result = []; + if (!hit) return false + } - for (var key in object) { - if (!(key == 'constructor' && (isProto || !hasOwnProperty.call(object, key)))) { - result.push(key); + // now either we fell off the end of the pattern, or we're done. + if (fi === fl && pi === pl) { + // ran out of pattern and filename at the same time. + // an exact hit! + return true + } else if (fi === fl) { + // ran out of file, but still had pattern left. + // this is ok if we're doing the match as part of + // a glob fs traversal. + return partial + } else /* istanbul ignore else */ if (pi === pl) { + // ran out of pattern, still have file left. + // this is only acceptable if we're on the very last + // empty segment of a file with a trailing slash. + // a/* should match a/b/ + return (fi === fl - 1) && (file[fi] === '') } + + // should be unreachable. + /* istanbul ignore next */ + throw new Error('wtf?') } - return result; -} -module.exports = baseKeysIn; + braceExpand () { + return braceExpand(this.pattern, this.options) + } + parse (pattern, isSub) { + assertValidPattern(pattern) -/***/ }), + const options = this.options -/***/ 22035: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + // shortcuts + if (pattern === '**') { + if (!options.noglobstar) + return GLOBSTAR + else + pattern = '*' + } + if (pattern === '') return '' -var identity = __nccwpck_require__(46851), - overRest = __nccwpck_require__(20168), - setToString = __nccwpck_require__(59402); + let re = '' + let hasMagic = false + let escaping = false + // ? => one single character + const patternListStack = [] + const negativeLists = [] + let stateChar + let inClass = false + let reClassStart = -1 + let classStart = -1 + let cs + let pl + let sp + // . and .. never match anything that doesn't start with ., + // even when options.dot is set. However, if the pattern + // starts with ., then traversal patterns can match. + let dotTravAllowed = pattern.charAt(0) === '.' + let dotFileAllowed = options.dot || dotTravAllowed + const patternStart = () => + dotTravAllowed + ? '' + : dotFileAllowed + ? '(?!(?:^|\\/)\\.{1,2}(?:$|\\/))' + : '(?!\\.)' + const subPatternStart = (p) => + p.charAt(0) === '.' + ? '' + : options.dot + ? '(?!(?:^|\\/)\\.{1,2}(?:$|\\/))' + : '(?!\\.)' -/** - * The base implementation of `_.rest` which doesn't validate or coerce arguments. - * - * @private - * @param {Function} func The function to apply a rest parameter to. - * @param {number} [start=func.length-1] The start position of the rest parameter. - * @returns {Function} Returns the new function. - */ -function baseRest(func, start) { - return setToString(overRest(func, start, identity), func + ''); -} -module.exports = baseRest; + const clearStateChar = () => { + if (stateChar) { + // we had some state-tracking character + // that wasn't consumed by this pass. + switch (stateChar) { + case '*': + re += star + hasMagic = true + break + case '?': + re += qmark + hasMagic = true + break + default: + re += '\\' + stateChar + break + } + this.debug('clearStateChar %j %j', stateChar, re) + stateChar = false + } + } + for (let i = 0, c; (i < pattern.length) && (c = pattern.charAt(i)); i++) { + this.debug('%s\t%s %s %j', pattern, i, re, c) -/***/ }), + // skip over any that are escaped. + if (escaping) { + /* istanbul ignore next - completely not allowed, even escaped. */ + if (c === '/') { + return false + } -/***/ 64953: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + if (reSpecials[c]) { + re += '\\' + } + re += c + escaping = false + continue + } -var constant = __nccwpck_require__(85089), - defineProperty = __nccwpck_require__(83106), - identity = __nccwpck_require__(46851); + switch (c) { + /* istanbul ignore next */ + case '/': { + // Should already be path-split by now. + return false + } -/** - * The base implementation of `setToString` without support for hot loop shorting. - * - * @private - * @param {Function} func The function to modify. - * @param {Function} string The `toString` result. - * @returns {Function} Returns `func`. - */ -var baseSetToString = !defineProperty ? identity : function(func, string) { - return defineProperty(func, 'toString', { - 'configurable': true, - 'enumerable': false, - 'value': constant(string), - 'writable': true - }); -}; + case '\\': + if (inClass && pattern.charAt(i + 1) === '-') { + re += c + continue + } -module.exports = baseSetToString; + clearStateChar() + escaping = true + continue + // the various stateChar values + // for the "extglob" stuff. + case '?': + case '*': + case '+': + case '@': + case '!': + this.debug('%s\t%s %s %j <-- stateChar', pattern, i, re, c) -/***/ }), + // all of those are literals inside a class, except that + // the glob [!a] means [^a] in regexp + if (inClass) { + this.debug(' in class') + if (c === '!' && i === classStart + 1) c = '^' + re += c + continue + } -/***/ 21299: -/***/ ((module) => { + // coalesce consecutive non-globstar * characters + if (c === '*' && stateChar === '*') continue -/** - * The base implementation of `_.times` without support for iteratee shorthands - * or max array length checks. - * - * @private - * @param {number} n The number of times to invoke `iteratee`. - * @param {Function} iteratee The function invoked per iteration. - * @returns {Array} Returns the array of results. - */ -function baseTimes(n, iteratee) { - var index = -1, - result = Array(n); + // if we already have a stateChar, then it means + // that there was something like ** or +? in there. + // Handle the stateChar, then proceed with this one. + this.debug('call clearStateChar %j', stateChar) + clearStateChar() + stateChar = c + // if extglob is disabled, then +(asdf|foo) isn't a thing. + // just clear the statechar *now*, rather than even diving into + // the patternList stuff. + if (options.noext) clearStateChar() + continue - while (++index < n) { - result[index] = iteratee(index); - } - return result; -} + case '(': { + if (inClass) { + re += '(' + continue + } -module.exports = baseTimes; + if (!stateChar) { + re += '\\(' + continue + } + const plEntry = { + type: stateChar, + start: i - 1, + reStart: re.length, + open: plTypes[stateChar].open, + close: plTypes[stateChar].close, + } + this.debug(this.pattern, '\t', plEntry) + patternListStack.push(plEntry) + // negation is (?:(?!(?:js)(?:))[^/]*) + re += plEntry.open + // next entry starts with a dot maybe? + if (plEntry.start === 0 && plEntry.type !== '!') { + dotTravAllowed = true + re += subPatternStart(pattern.slice(i + 1)) + } + this.debug('plType %j %j', stateChar, re) + stateChar = false + continue + } -/***/ }), + case ')': { + const plEntry = patternListStack[patternListStack.length - 1] + if (inClass || !plEntry) { + re += '\\)' + continue + } + patternListStack.pop() -/***/ 55506: -/***/ ((module) => { + // closing an extglob + clearStateChar() + hasMagic = true + pl = plEntry + // negation is (?:(?!js)[^/]*) + // The others are (?:) + re += pl.close + if (pl.type === '!') { + negativeLists.push(Object.assign(pl, { reEnd: re.length })) + } + continue + } -/** - * The base implementation of `_.unary` without support for storing metadata. - * - * @private - * @param {Function} func The function to cap arguments for. - * @returns {Function} Returns the new capped function. - */ -function baseUnary(func) { - return function(value) { - return func(value); - }; -} + case '|': { + const plEntry = patternListStack[patternListStack.length - 1] + if (inClass || !plEntry) { + re += '\\|' + continue + } -module.exports = baseUnary; + clearStateChar() + re += '|' + // next subpattern can start with a dot? + if (plEntry.start === 0 && plEntry.type !== '!') { + dotTravAllowed = true + re += subPatternStart(pattern.slice(i + 1)) + } + continue + } + // these are mostly the same in regexp and glob + case '[': + // swallow any state-tracking char before the [ + clearStateChar() -/***/ }), + if (inClass) { + re += '\\' + c + continue + } -/***/ 32772: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + inClass = true + classStart = i + reClassStart = re.length + re += c + continue -var SetCache = __nccwpck_require__(23706), - arrayIncludes = __nccwpck_require__(70534), - arrayIncludesWith = __nccwpck_require__(37314), - cacheHas = __nccwpck_require__(64486), - createSet = __nccwpck_require__(48242), - setToArray = __nccwpck_require__(11894); + case ']': + // a right bracket shall lose its special + // meaning and represent itself in + // a bracket expression if it occurs + // first in the list. -- POSIX.2 2.8.3.2 + if (i === classStart + 1 || !inClass) { + re += '\\' + c + continue + } -/** Used as the size to enable large array optimizations. */ -var LARGE_ARRAY_SIZE = 200; + // split where the last [ was, make sure we don't have + // an invalid re. if so, re-walk the contents of the + // would-be class to re-translate any characters that + // were passed through as-is + // TODO: It would probably be faster to determine this + // without a try/catch and a new RegExp, but it's tricky + // to do safely. For now, this is safe and works. + cs = pattern.substring(classStart + 1, i) + try { + RegExp('[' + braExpEscape(charUnescape(cs)) + ']') + // looks good, finish up the class. + re += c + } catch (er) { + // out of order ranges in JS are errors, but in glob syntax, + // they're just a range that matches nothing. + re = re.substring(0, reClassStart) + '(?:$.)' // match nothing ever + } + hasMagic = true + inClass = false + continue -/** - * The base implementation of `_.uniqBy` without support for iteratee shorthands. - * - * @private - * @param {Array} array The array to inspect. - * @param {Function} [iteratee] The iteratee invoked per element. - * @param {Function} [comparator] The comparator invoked per element. - * @returns {Array} Returns the new duplicate free array. - */ -function baseUniq(array, iteratee, comparator) { - var index = -1, - includes = arrayIncludes, - length = array.length, - isCommon = true, - result = [], - seen = result; + default: + // swallow any state char that wasn't consumed + clearStateChar() - if (comparator) { - isCommon = false; - includes = arrayIncludesWith; - } - else if (length >= LARGE_ARRAY_SIZE) { - var set = iteratee ? null : createSet(array); - if (set) { - return setToArray(set); + if (reSpecials[c] && !(c === '^' && inClass)) { + re += '\\' + } + + re += c + break + + } // switch + } // for + + // handle the case where we left a class open. + // "[abc" is valid, equivalent to "\[abc" + if (inClass) { + // split where the last [ was, and escape it + // this is a huge pita. We now have to re-walk + // the contents of the would-be class to re-translate + // any characters that were passed through as-is + cs = pattern.slice(classStart + 1) + sp = this.parse(cs, SUBPARSE) + re = re.substring(0, reClassStart) + '\\[' + sp[0] + hasMagic = hasMagic || sp[1] } - isCommon = false; - includes = cacheHas; - seen = new SetCache; - } - else { - seen = iteratee ? [] : result; - } - outer: - while (++index < length) { - var value = array[index], - computed = iteratee ? iteratee(value) : value; - value = (comparator || value !== 0) ? value : 0; - if (isCommon && computed === computed) { - var seenIndex = seen.length; - while (seenIndex--) { - if (seen[seenIndex] === computed) { - continue outer; + // handle the case where we had a +( thing at the *end* + // of the pattern. + // each pattern list stack adds 3 chars, and we need to go through + // and escape any | chars that were passed through as-is for the regexp. + // Go through and escape them, taking care not to double-escape any + // | chars that were already escaped. + for (pl = patternListStack.pop(); pl; pl = patternListStack.pop()) { + let tail + tail = re.slice(pl.reStart + pl.open.length) + this.debug('setting tail', re, pl) + // maybe some even number of \, then maybe 1 \, followed by a | + tail = tail.replace(/((?:\\{2}){0,64})(\\?)\|/g, (_, $1, $2) => { + /* istanbul ignore else - should already be done */ + if (!$2) { + // the | isn't already escaped, so escape it. + $2 = '\\' } - } - if (iteratee) { - seen.push(computed); - } - result.push(value); - } - else if (!includes(seen, computed, comparator)) { - if (seen !== result) { - seen.push(computed); - } - result.push(value); - } - } - return result; -} -module.exports = baseUniq; + // need to escape all those slashes *again*, without escaping the + // one that we need for escaping the | character. As it works out, + // escaping an even number of slashes can be done by simply repeating + // it exactly after itself. That's why this trick works. + // + // I am sorry that you have to see this. + return $1 + $1 + $2 + '|' + }) + this.debug('tail=%j\n %s', tail, tail, pl, re) + const t = pl.type === '*' ? star + : pl.type === '?' ? qmark + : '\\' + pl.type -/***/ }), + hasMagic = true + re = re.slice(0, pl.reStart) + t + '\\(' + tail + } -/***/ 64486: -/***/ ((module) => { + // handle trailing things that only matter at the very end. + clearStateChar() + if (escaping) { + // trailing \\ + re += '\\\\' + } -/** - * Checks if a `cache` value for `key` exists. - * - * @private - * @param {Object} cache The cache to query. - * @param {string} key The key of the entry to check. - * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`. - */ -function cacheHas(cache, key) { - return cache.has(key); -} + // only need to apply the nodot start if the re starts with + // something that could conceivably capture a dot + const addPatternStart = addPatternStartSet[re.charAt(0)] -module.exports = cacheHas; + // Hack to work around lack of negative lookbehind in JS + // A pattern like: *.!(x).!(y|z) needs to ensure that a name + // like 'a.xyz.yz' doesn't match. So, the first negative + // lookahead, has to look ALL the way ahead, to the end of + // the pattern. + for (let n = negativeLists.length - 1; n > -1; n--) { + const nl = negativeLists[n] + const nlBefore = re.slice(0, nl.reStart) + const nlFirst = re.slice(nl.reStart, nl.reEnd - 8) + let nlAfter = re.slice(nl.reEnd) + const nlLast = re.slice(nl.reEnd - 8, nl.reEnd) + nlAfter -/***/ }), + // Handle nested stuff like *(*.js|!(*.json)), where open parens + // mean that we should *not* include the ) in the bit that is considered + // "after" the negated section. + const closeParensBefore = nlBefore.split(')').length + const openParensBefore = nlBefore.split('(').length - closeParensBefore + let cleanAfter = nlAfter + for (let i = 0; i < openParensBefore; i++) { + cleanAfter = cleanAfter.replace(/\)[+*?]?/, '') + } + nlAfter = cleanAfter -/***/ 60252: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + const dollar = nlAfter === '' && isSub !== SUBPARSE ? '(?:$|\\/)' : '' -var root = __nccwpck_require__(6748); + re = nlBefore + nlFirst + nlAfter + dollar + nlLast + } -/** Used to detect overreaching core-js shims. */ -var coreJsData = root['__core-js_shared__']; + // if the re is not "" at this point, then we need to make sure + // it doesn't match against an empty path part. + // Otherwise a/* will match a/, which it should not. + if (re !== '' && hasMagic) { + re = '(?=.)' + re + } -module.exports = coreJsData; + if (addPatternStart) { + re = patternStart() + re + } + // parsing just a piece of a larger pattern. + if (isSub === SUBPARSE) { + return [re, hasMagic] + } -/***/ }), + // if it's nocase, and the lcase/uppercase don't match, it's magic + if (options.nocase && !hasMagic) { + hasMagic = pattern.toUpperCase() !== pattern.toLowerCase() + } -/***/ 48242: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + // skip the regexp for non-magical patterns + // unescape anything in it, though, so that it'll be + // an exact match against a file etc. + if (!hasMagic) { + return globUnescape(pattern) + } -var Set = __nccwpck_require__(84986), - noop = __nccwpck_require__(89029), - setToArray = __nccwpck_require__(11894); + const flags = options.nocase ? 'i' : '' + try { + return Object.assign(new RegExp('^' + re + '$', flags), { + _glob: pattern, + _src: re, + }) + } catch (er) /* istanbul ignore next - should be impossible */ { + // If it was an invalid regular expression, then it can't match + // anything. This trick looks for a character after the end of + // the string, which is of course impossible, except in multi-line + // mode, but it's not a /m regex. + return new RegExp('$.') + } + } -/** Used as references for various `Number` constants. */ -var INFINITY = 1 / 0; + makeRe () { + if (this.regexp || this.regexp === false) return this.regexp -/** - * Creates a set object of `values`. - * - * @private - * @param {Array} values The values to add to the set. - * @returns {Object} Returns the new set. - */ -var createSet = !(Set && (1 / setToArray(new Set([,-0]))[1]) == INFINITY) ? noop : function(values) { - return new Set(values); -}; + // at this point, this.set is a 2d array of partial + // pattern strings, or "**". + // + // It's better to use .match(). This function shouldn't + // be used, really, but it's pretty convenient sometimes, + // when you just want to work with a regex. + const set = this.set -module.exports = createSet; + if (!set.length) { + this.regexp = false + return this.regexp + } + const options = this.options + const twoStar = options.noglobstar ? star + : options.dot ? twoStarDot + : twoStarNoDot + const flags = options.nocase ? 'i' : '' -/***/ }), + // coalesce globstars and regexpify non-globstar patterns + // if it's the only item, then we just do one twoStar + // if it's the first, and there are more, prepend (\/|twoStar\/)? to next + // if it's the last, append (\/twoStar|) to previous + // if it's in the middle, append (\/|\/twoStar\/) to previous + // then filter out GLOBSTAR symbols + let re = set.map(pattern => { + pattern = pattern.map(p => + typeof p === 'string' ? regExpEscape(p) + : p === GLOBSTAR ? GLOBSTAR + : p._src + ).reduce((set, p) => { + if (!(set[set.length - 1] === GLOBSTAR && p === GLOBSTAR)) { + set.push(p) + } + return set + }, []) + pattern.forEach((p, i) => { + if (p !== GLOBSTAR || pattern[i-1] === GLOBSTAR) { + return + } + if (i === 0) { + if (pattern.length > 1) { + pattern[i+1] = '(?:\\\/|' + twoStar + '\\\/)?' + pattern[i+1] + } else { + pattern[i] = twoStar + } + } else if (i === pattern.length - 1) { + pattern[i-1] += '(?:\\\/|' + twoStar + ')?' + } else { + pattern[i-1] += '(?:\\\/|\\\/' + twoStar + '\\\/)' + pattern[i+1] + pattern[i+1] = GLOBSTAR + } + }) + return pattern.filter(p => p !== GLOBSTAR).join('/') + }).join('|') -/***/ 83106: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + // must match entire pattern + // ending in a * or ** will make it less strict. + re = '^(?:' + re + ')$' -var getNative = __nccwpck_require__(68573); + // can match anything, as long as it's not this. + if (this.negate) re = '^(?!' + re + ').*$' -var defineProperty = (function() { - try { - var func = getNative(Object, 'defineProperty'); - func({}, '', {}); - return func; - } catch (e) {} -}()); + try { + this.regexp = new RegExp(re, flags) + } catch (ex) /* istanbul ignore next - should be impossible */ { + this.regexp = false + } + return this.regexp + } -module.exports = defineProperty; + match (f, partial = this.partial) { + this.debug('match', f, this.pattern) + // short-circuit in the case of busted things. + // comments, etc. + if (this.comment) return false + if (this.empty) return f === '' + if (f === '/' && partial) return true -/***/ }), + const options = this.options -/***/ 78997: -/***/ ((module) => { + // windows: need to use /, not \ + if (path.sep !== '/') { + f = f.split(path.sep).join('/') + } -/** Detect free variable `global` from Node.js. */ -var freeGlobal = typeof global == 'object' && global && global.Object === Object && global; + // treat the test path as a set of pathparts. + f = f.split(slashSplit) + this.debug(this.pattern, 'split', f) -module.exports = freeGlobal; + // just ONE of the pattern sets in this.set needs to match + // in order for it to be valid. If negating, then just one + // match means that we have failed. + // Either way, return on the first hit. + const set = this.set + this.debug(this.pattern, 'set', set) -/***/ }), + // Find the basename of the path by looking for the last non-empty segment + let filename + for (let i = f.length - 1; i >= 0; i--) { + filename = f[i] + if (filename) break + } -/***/ 1194: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + for (let i = 0; i < set.length; i++) { + const pattern = set[i] + let file = f + if (options.matchBase && pattern.length === 1) { + file = [filename] + } + const hit = this.matchOne(file, pattern, partial) + if (hit) { + if (options.flipNegate) return true + return !this.negate + } + } -var isKeyable = __nccwpck_require__(93245); + // didn't get any hits. this is success if it's a negative + // pattern, failure otherwise. + if (options.flipNegate) return false + return this.negate + } -/** - * Gets the data for `map`. - * - * @private - * @param {Object} map The map to query. - * @param {string} key The reference key. - * @returns {*} Returns the map data. - */ -function getMapData(map, key) { - var data = map.__data__; - return isKeyable(key) - ? data[typeof key == 'string' ? 'string' : 'hash'] - : data.map; + static defaults (def) { + return minimatch.defaults(def).Minimatch + } } -module.exports = getMapData; +minimatch.Minimatch = Minimatch /***/ }), -/***/ 68573: +/***/ 15026: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var baseIsNative = __nccwpck_require__(92334), - getValue = __nccwpck_require__(8293); +var path = __nccwpck_require__(16928); +var fs = __nccwpck_require__(79896); +var _0777 = parseInt('0777', 8); -/** - * Gets the native function at `key` of `object`. - * - * @private - * @param {Object} object The object to query. - * @param {string} key The key of the method to get. - * @returns {*} Returns the function if it's native, else `undefined`. - */ -function getNative(object, key) { - var value = getValue(object, key); - return baseIsNative(value) ? value : undefined; -} +module.exports = mkdirP.mkdirp = mkdirP.mkdirP = mkdirP; -module.exports = getNative; +function mkdirP (p, opts, f, made) { + if (typeof opts === 'function') { + f = opts; + opts = {}; + } + else if (!opts || typeof opts !== 'object') { + opts = { mode: opts }; + } + + var mode = opts.mode; + var xfs = opts.fs || fs; + + if (mode === undefined) { + mode = _0777 + } + if (!made) made = null; + + var cb = f || /* istanbul ignore next */ function () {}; + p = path.resolve(p); + + xfs.mkdir(p, mode, function (er) { + if (!er) { + made = made || p; + return cb(null, made); + } + switch (er.code) { + case 'ENOENT': + /* istanbul ignore if */ + if (path.dirname(p) === p) return cb(er); + mkdirP(path.dirname(p), opts, function (er, made) { + /* istanbul ignore if */ + if (er) cb(er, made); + else mkdirP(p, opts, cb, made); + }); + break; + // In the case of any other error, just see if there's a dir + // there already. If so, then hooray! If not, then something + // is borked. + default: + xfs.stat(p, function (er2, stat) { + // if the stat fails, then that's super weird. + // let the original error be the failure reason. + if (er2 || !stat.isDirectory()) cb(er, made) + else cb(null, made); + }); + break; + } + }); +} -/***/ }), +mkdirP.sync = function sync (p, opts, made) { + if (!opts || typeof opts !== 'object') { + opts = { mode: opts }; + } + + var mode = opts.mode; + var xfs = opts.fs || fs; + + if (mode === undefined) { + mode = _0777 + } + if (!made) made = null; -/***/ 86194: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + p = path.resolve(p); -var overArg = __nccwpck_require__(61128); + try { + xfs.mkdirSync(p, mode); + made = made || p; + } + catch (err0) { + switch (err0.code) { + case 'ENOENT' : + made = sync(path.dirname(p), opts, made); + sync(p, opts, made); + break; -/** Built-in value references. */ -var getPrototype = overArg(Object.getPrototypeOf, Object); + // In the case of any other error, just see if there's a dir + // there already. If so, then hooray! If not, then something + // is borked. + default: + var stat; + try { + stat = xfs.statSync(p); + } + catch (err1) /* istanbul ignore next */ { + throw err0; + } + /* istanbul ignore if */ + if (!stat.isDirectory()) throw err0; + break; + } + } -module.exports = getPrototype; + return made; +}; /***/ }), -/***/ 95292: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - -var Symbol = __nccwpck_require__(38584); +/***/ 26647: +/***/ ((module) => { -/** Used for built-in method references. */ -var objectProto = Object.prototype; +/** + * Helpers. + */ -/** Used to check objects for own properties. */ -var hasOwnProperty = objectProto.hasOwnProperty; +var s = 1000; +var m = s * 60; +var h = m * 60; +var d = h * 24; +var w = d * 7; +var y = d * 365.25; /** - * Used to resolve the - * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) - * of values. + * Parse or format the given `val`. + * + * Options: + * + * - `long` verbose formatting [false] + * + * @param {String|Number} val + * @param {Object} [options] + * @throws {Error} throw an error if val is not a non-empty string or a number + * @return {String|Number} + * @api public */ -var nativeObjectToString = objectProto.toString; -/** Built-in value references. */ -var symToStringTag = Symbol ? Symbol.toStringTag : undefined; +module.exports = function (val, options) { + options = options || {}; + var type = typeof val; + if (type === 'string' && val.length > 0) { + return parse(val); + } else if (type === 'number' && isFinite(val)) { + return options.long ? fmtLong(val) : fmtShort(val); + } + throw new Error( + 'val is not a non-empty string or a valid number. val=' + + JSON.stringify(val) + ); +}; /** - * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values. + * Parse the given `str` and return milliseconds. * - * @private - * @param {*} value The value to query. - * @returns {string} Returns the raw `toStringTag`. + * @param {String} str + * @return {Number} + * @api private */ -function getRawTag(value) { - var isOwn = hasOwnProperty.call(value, symToStringTag), - tag = value[symToStringTag]; - - try { - value[symToStringTag] = undefined; - var unmasked = true; - } catch (e) {} - var result = nativeObjectToString.call(value); - if (unmasked) { - if (isOwn) { - value[symToStringTag] = tag; - } else { - delete value[symToStringTag]; - } +function parse(str) { + str = String(str); + if (str.length > 100) { + return; + } + var match = /^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec( + str + ); + if (!match) { + return; + } + var n = parseFloat(match[1]); + var type = (match[2] || 'ms').toLowerCase(); + switch (type) { + case 'years': + case 'year': + case 'yrs': + case 'yr': + case 'y': + return n * y; + case 'weeks': + case 'week': + case 'w': + return n * w; + case 'days': + case 'day': + case 'd': + return n * d; + case 'hours': + case 'hour': + case 'hrs': + case 'hr': + case 'h': + return n * h; + case 'minutes': + case 'minute': + case 'mins': + case 'min': + case 'm': + return n * m; + case 'seconds': + case 'second': + case 'secs': + case 'sec': + case 's': + return n * s; + case 'milliseconds': + case 'millisecond': + case 'msecs': + case 'msec': + case 'ms': + return n; + default: + return undefined; } - return result; } -module.exports = getRawTag; - - -/***/ }), - -/***/ 8293: -/***/ ((module) => { - /** - * Gets the value at `key` of `object`. + * Short format for `ms`. * - * @private - * @param {Object} [object] The object to query. - * @param {string} key The key of the property to get. - * @returns {*} Returns the property value. + * @param {Number} ms + * @return {String} + * @api private */ -function getValue(object, key) { - return object == null ? undefined : object[key]; -} - -module.exports = getValue; - - -/***/ }), - -/***/ 48051: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var nativeCreate = __nccwpck_require__(71563); +function fmtShort(ms) { + var msAbs = Math.abs(ms); + if (msAbs >= d) { + return Math.round(ms / d) + 'd'; + } + if (msAbs >= h) { + return Math.round(ms / h) + 'h'; + } + if (msAbs >= m) { + return Math.round(ms / m) + 'm'; + } + if (msAbs >= s) { + return Math.round(ms / s) + 's'; + } + return ms + 'ms'; +} /** - * Removes all key-value entries from the hash. + * Long format for `ms`. * - * @private - * @name clear - * @memberOf Hash + * @param {Number} ms + * @return {String} + * @api private */ -function hashClear() { - this.__data__ = nativeCreate ? nativeCreate(null) : {}; - this.size = 0; -} - -module.exports = hashClear; - - -/***/ }), -/***/ 15431: -/***/ ((module) => { +function fmtLong(ms) { + var msAbs = Math.abs(ms); + if (msAbs >= d) { + return plural(ms, msAbs, d, 'day'); + } + if (msAbs >= h) { + return plural(ms, msAbs, h, 'hour'); + } + if (msAbs >= m) { + return plural(ms, msAbs, m, 'minute'); + } + if (msAbs >= s) { + return plural(ms, msAbs, s, 'second'); + } + return ms + ' ms'; +} /** - * Removes `key` and its value from the hash. - * - * @private - * @name delete - * @memberOf Hash - * @param {Object} hash The hash to modify. - * @param {string} key The key of the value to remove. - * @returns {boolean} Returns `true` if the entry was removed, else `false`. + * Pluralization helper. */ -function hashDelete(key) { - var result = this.has(key) && delete this.__data__[key]; - this.size -= result ? 1 : 0; - return result; -} -module.exports = hashDelete; +function plural(ms, msAbs, n, name) { + var isPlural = msAbs >= n * 1.5; + return Math.round(ms / n) + ' ' + name + (isPlural ? 's' : ''); +} /***/ }), -/***/ 26934: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/***/ 52398: +/***/ ((module) => { -var nativeCreate = __nccwpck_require__(71563); +/*! + * normalize-path + * + * Copyright (c) 2014-2018, Jon Schlinkert. + * Released under the MIT License. + */ -/** Used to stand-in for `undefined` hash values. */ -var HASH_UNDEFINED = '__lodash_hash_undefined__'; +module.exports = function(path, stripTrailing) { + if (typeof path !== 'string') { + throw new TypeError('expected path to be a string'); + } -/** Used for built-in method references. */ -var objectProto = Object.prototype; + if (path === '\\' || path === '/') return '/'; -/** Used to check objects for own properties. */ -var hasOwnProperty = objectProto.hasOwnProperty; + var len = path.length; + if (len <= 1) return path; -/** - * Gets the hash value for `key`. - * - * @private - * @name get - * @memberOf Hash - * @param {string} key The key of the value to get. - * @returns {*} Returns the entry value. - */ -function hashGet(key) { - var data = this.__data__; - if (nativeCreate) { - var result = data[key]; - return result === HASH_UNDEFINED ? undefined : result; + // ensure that win32 namespaces has two leading slashes, so that the path is + // handled properly by the win32 version of path.parse() after being normalized + // https://msdn.microsoft.com/library/windows/desktop/aa365247(v=vs.85).aspx#namespaces + var prefix = ''; + if (len > 4 && path[3] === '\\') { + var ch = path[2]; + if ((ch === '?' || ch === '.') && path.slice(0, 2) === '\\\\') { + path = path.slice(2); + prefix = '//'; + } } - return hasOwnProperty.call(data, key) ? data[key] : undefined; -} -module.exports = hashGet; + var segs = path.split(/[/\\]+/); + if (stripTrailing !== false && segs[segs.length - 1] === '') { + segs.pop(); + } + return prefix + segs.join('/'); +}; /***/ }), -/***/ 64306: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/***/ 61710: +/***/ ((module) => { -var nativeCreate = __nccwpck_require__(71563); -/** Used for built-in method references. */ -var objectProto = Object.prototype; -/** Used to check objects for own properties. */ -var hasOwnProperty = objectProto.hasOwnProperty; +if (typeof process === 'undefined' || + !process.version || + process.version.indexOf('v0.') === 0 || + process.version.indexOf('v1.') === 0 && process.version.indexOf('v1.8.') !== 0) { + module.exports = { nextTick: nextTick }; +} else { + module.exports = process +} -/** - * Checks if a hash value for `key` exists. - * - * @private - * @name has - * @memberOf Hash - * @param {string} key The key of the entry to check. - * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`. - */ -function hashHas(key) { - var data = this.__data__; - return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key); +function nextTick(fn, arg1, arg2, arg3) { + if (typeof fn !== 'function') { + throw new TypeError('"callback" argument must be a function'); + } + var len = arguments.length; + var args, i; + switch (len) { + case 0: + case 1: + return process.nextTick(fn); + case 2: + return process.nextTick(function afterTickOne() { + fn.call(null, arg1); + }); + case 3: + return process.nextTick(function afterTickTwo() { + fn.call(null, arg1, arg2); + }); + case 4: + return process.nextTick(function afterTickThree() { + fn.call(null, arg1, arg2, arg3); + }); + default: + args = new Array(len - 1); + i = 0; + while (i < args.length) { + args[i++] = arguments[i]; + } + return process.nextTick(function afterTick() { + fn.apply(null, args); + }); + } } -module.exports = hashHas; /***/ }), -/***/ 17226: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - -var nativeCreate = __nccwpck_require__(71563); - -/** Used to stand-in for `undefined` hash values. */ -var HASH_UNDEFINED = '__lodash_hash_undefined__'; - -/** - * Sets the hash `key` to `value`. - * - * @private - * @name set - * @memberOf Hash - * @param {string} key The key of the value to set. - * @param {*} value The value to set. - * @returns {Object} Returns the hash instance. - */ -function hashSet(key, value) { - var data = this.__data__; - this.size += this.has(key) ? 0 : 1; - data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value; - return this; -} +/***/ 50180: +/***/ ((module) => { -module.exports = hashSet; +// for now just expose the builtin process global from node.js +module.exports = global.process; /***/ }), -/***/ 45088: +/***/ 7354: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var Symbol = __nccwpck_require__(38584), - isArguments = __nccwpck_require__(60541), - isArray = __nccwpck_require__(77192); +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. -/** Built-in value references. */ -var spreadableSymbol = Symbol ? Symbol.isConcatSpreadable : undefined; +// a duplex stream is just a stream that is both readable and writable. +// Since JS doesn't have multiple prototypal inheritance, this class +// prototypally inherits from Readable, and then parasitically from +// Writable. -/** - * Checks if `value` is a flattenable `arguments` object or array. - * - * @private - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is flattenable, else `false`. - */ -function isFlattenable(value) { - return isArray(value) || isArguments(value) || - !!(spreadableSymbol && value && value[spreadableSymbol]); -} -module.exports = isFlattenable; +/**/ -/***/ }), +var pna = __nccwpck_require__(61710); +/**/ -/***/ 37446: -/***/ ((module) => { +/**/ +var objectKeys = Object.keys || function (obj) { + var keys = []; + for (var key in obj) { + keys.push(key); + }return keys; +}; +/**/ -/** Used as references for various `Number` constants. */ -var MAX_SAFE_INTEGER = 9007199254740991; +module.exports = Duplex; -/** Used to detect unsigned integer values. */ -var reIsUint = /^(?:0|[1-9]\d*)$/; +/**/ +var util = Object.create(__nccwpck_require__(22465)); +util.inherits = __nccwpck_require__(76153); +/**/ -/** - * Checks if `value` is a valid array-like index. - * - * @private - * @param {*} value The value to check. - * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index. - * @returns {boolean} Returns `true` if `value` is a valid index, else `false`. - */ -function isIndex(value, length) { - var type = typeof value; - length = length == null ? MAX_SAFE_INTEGER : length; +var Readable = __nccwpck_require__(97576); +var Writable = __nccwpck_require__(2232); - return !!length && - (type == 'number' || - (type != 'symbol' && reIsUint.test(value))) && - (value > -1 && value % 1 == 0 && value < length); +util.inherits(Duplex, Readable); + +{ + // avoid scope creep, the keys array can then be collected + var keys = objectKeys(Writable.prototype); + for (var v = 0; v < keys.length; v++) { + var method = keys[v]; + if (!Duplex.prototype[method]) Duplex.prototype[method] = Writable.prototype[method]; + } } -module.exports = isIndex; +function Duplex(options) { + if (!(this instanceof Duplex)) return new Duplex(options); + Readable.call(this, options); + Writable.call(this, options); -/***/ }), + if (options && options.readable === false) this.readable = false; -/***/ 3349: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + if (options && options.writable === false) this.writable = false; -var eq = __nccwpck_require__(75199), - isArrayLike = __nccwpck_require__(75119), - isIndex = __nccwpck_require__(37446), - isObject = __nccwpck_require__(96482); + this.allowHalfOpen = true; + if (options && options.allowHalfOpen === false) this.allowHalfOpen = false; -/** - * Checks if the given arguments are from an iteratee call. - * - * @private - * @param {*} value The potential iteratee value argument. - * @param {*} index The potential iteratee index or key argument. - * @param {*} object The potential iteratee object argument. - * @returns {boolean} Returns `true` if the arguments are from an iteratee call, - * else `false`. - */ -function isIterateeCall(value, index, object) { - if (!isObject(object)) { - return false; - } - var type = typeof index; - if (type == 'number' - ? (isArrayLike(object) && isIndex(index, object.length)) - : (type == 'string' && index in object) - ) { - return eq(object[index], value); - } - return false; + this.once('end', onend); } -module.exports = isIterateeCall; - - -/***/ }), +Object.defineProperty(Duplex.prototype, 'writableHighWaterMark', { + // making it explicit this property is not enumerable + // because otherwise some prototype manipulation in + // userland will fail + enumerable: false, + get: function () { + return this._writableState.highWaterMark; + } +}); -/***/ 93245: -/***/ ((module) => { +// the no-half-open enforcer +function onend() { + // if we allow half-open state, or if the writable side ended, + // then we're ok. + if (this.allowHalfOpen || this._writableState.ended) return; -/** - * Checks if `value` is suitable for use as unique object key. - * - * @private - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is suitable, else `false`. - */ -function isKeyable(value) { - var type = typeof value; - return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean') - ? (value !== '__proto__') - : (value === null); + // no more data can be written. + // But allow more writes to happen in this tick. + pna.nextTick(onEndNT, this); } -module.exports = isKeyable; - - -/***/ }), +function onEndNT(self) { + self.end(); +} -/***/ 46613: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +Object.defineProperty(Duplex.prototype, 'destroyed', { + get: function () { + if (this._readableState === undefined || this._writableState === undefined) { + return false; + } + return this._readableState.destroyed && this._writableState.destroyed; + }, + set: function (value) { + // we ignore the value if the stream + // has not been initialized yet + if (this._readableState === undefined || this._writableState === undefined) { + return; + } -var coreJsData = __nccwpck_require__(60252); + // backward compatibility, the user is explicitly + // managing destroyed + this._readableState.destroyed = value; + this._writableState.destroyed = value; + } +}); -/** Used to detect methods masquerading as native. */ -var maskSrcKey = (function() { - var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || ''); - return uid ? ('Symbol(src)_1.' + uid) : ''; -}()); +Duplex.prototype._destroy = function (err, cb) { + this.push(null); + this.end(); -/** - * Checks if `func` has its source masked. - * - * @private - * @param {Function} func The function to check. - * @returns {boolean} Returns `true` if `func` is masked, else `false`. - */ -function isMasked(func) { - return !!maskSrcKey && (maskSrcKey in func); -} + pna.nextTick(cb, err); +}; -module.exports = isMasked; +/***/ }), +/***/ 96348: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -/***/ }), +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. -/***/ 55944: -/***/ ((module) => { +// a passthrough stream. +// basically just the most minimal sort of Transform stream. +// Every written chunk gets output as-is. -/** Used for built-in method references. */ -var objectProto = Object.prototype; -/** - * Checks if `value` is likely a prototype object. - * - * @private - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a prototype, else `false`. - */ -function isPrototype(value) { - var Ctor = value && value.constructor, - proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto; - return value === proto; -} +module.exports = PassThrough; -module.exports = isPrototype; +var Transform = __nccwpck_require__(34278); +/**/ +var util = Object.create(__nccwpck_require__(22465)); +util.inherits = __nccwpck_require__(76153); +/**/ -/***/ }), +util.inherits(PassThrough, Transform); -/***/ 99791: -/***/ ((module) => { +function PassThrough(options) { + if (!(this instanceof PassThrough)) return new PassThrough(options); -/** - * Removes all key-value entries from the list cache. - * - * @private - * @name clear - * @memberOf ListCache - */ -function listCacheClear() { - this.__data__ = []; - this.size = 0; + Transform.call(this, options); } -module.exports = listCacheClear; - +PassThrough.prototype._transform = function (chunk, encoding, cb) { + cb(null, chunk); +}; /***/ }), -/***/ 24555: +/***/ 97576: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var assocIndexOf = __nccwpck_require__(74024); - -/** Used for built-in method references. */ -var arrayProto = Array.prototype; - -/** Built-in value references. */ -var splice = arrayProto.splice; - -/** - * Removes `key` and its value from the list cache. - * - * @private - * @name delete - * @memberOf ListCache - * @param {string} key The key of the value to remove. - * @returns {boolean} Returns `true` if the entry was removed, else `false`. - */ -function listCacheDelete(key) { - var data = this.__data__, - index = assocIndexOf(data, key); - - if (index < 0) { - return false; - } - var lastIndex = data.length - 1; - if (index == lastIndex) { - data.pop(); - } else { - splice.call(data, index, 1); - } - --this.size; - return true; -} +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. -module.exports = listCacheDelete; -/***/ }), +/**/ -/***/ 86634: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +var pna = __nccwpck_require__(61710); +/**/ -var assocIndexOf = __nccwpck_require__(74024); +module.exports = Readable; -/** - * Gets the list cache value for `key`. - * - * @private - * @name get - * @memberOf ListCache - * @param {string} key The key of the value to get. - * @returns {*} Returns the entry value. - */ -function listCacheGet(key) { - var data = this.__data__, - index = assocIndexOf(data, key); +/**/ +var isArray = __nccwpck_require__(92012); +/**/ - return index < 0 ? undefined : data[index][1]; -} +/**/ +var Duplex; +/**/ -module.exports = listCacheGet; +Readable.ReadableState = ReadableState; +/**/ +var EE = (__nccwpck_require__(24434).EventEmitter); -/***/ }), +var EElistenerCount = function (emitter, type) { + return emitter.listeners(type).length; +}; +/**/ -/***/ 8430: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/**/ +var Stream = __nccwpck_require__(94324); +/**/ -var assocIndexOf = __nccwpck_require__(74024); +/**/ -/** - * Checks if a list cache value for `key` exists. - * - * @private - * @name has - * @memberOf ListCache - * @param {string} key The key of the entry to check. - * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`. - */ -function listCacheHas(key) { - return assocIndexOf(this.__data__, key) > -1; +var Buffer = (__nccwpck_require__(79253).Buffer); +var OurUint8Array = (typeof global !== 'undefined' ? global : typeof window !== 'undefined' ? window : typeof self !== 'undefined' ? self : {}).Uint8Array || function () {}; +function _uint8ArrayToBuffer(chunk) { + return Buffer.from(chunk); +} +function _isUint8Array(obj) { + return Buffer.isBuffer(obj) || obj instanceof OurUint8Array; } -module.exports = listCacheHas; - - -/***/ }), - -/***/ 36918: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - -var assocIndexOf = __nccwpck_require__(74024); +/**/ -/** - * Sets the list cache `key` to `value`. - * - * @private - * @name set - * @memberOf ListCache - * @param {string} key The key of the value to set. - * @param {*} value The value to set. - * @returns {Object} Returns the list cache instance. - */ -function listCacheSet(key, value) { - var data = this.__data__, - index = assocIndexOf(data, key); +/**/ +var util = Object.create(__nccwpck_require__(22465)); +util.inherits = __nccwpck_require__(76153); +/**/ - if (index < 0) { - ++this.size; - data.push([key, value]); - } else { - data[index][1] = value; - } - return this; +/**/ +var debugUtil = __nccwpck_require__(39023); +var debug = void 0; +if (debugUtil && debugUtil.debuglog) { + debug = debugUtil.debuglog('stream'); +} else { + debug = function () {}; } +/**/ -module.exports = listCacheSet; - +var BufferList = __nccwpck_require__(65866); +var destroyImpl = __nccwpck_require__(83716); +var StringDecoder; -/***/ }), +util.inherits(Readable, Stream); -/***/ 88487: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +var kProxyEvents = ['error', 'close', 'destroy', 'pause', 'resume']; -var Hash = __nccwpck_require__(66320), - ListCache = __nccwpck_require__(68884), - Map = __nccwpck_require__(98272); +function prependListener(emitter, event, fn) { + // Sadly this is not cacheable as some libraries bundle their own + // event emitter implementation with them. + if (typeof emitter.prependListener === 'function') return emitter.prependListener(event, fn); -/** - * Removes all key-value entries from the map. - * - * @private - * @name clear - * @memberOf MapCache - */ -function mapCacheClear() { - this.size = 0; - this.__data__ = { - 'hash': new Hash, - 'map': new (Map || ListCache), - 'string': new Hash - }; + // This is a hack to make sure that our error handler is attached before any + // userland ones. NEVER DO THIS. This is here only because this code needs + // to continue to work with older versions of Node.js that do not include + // the prependListener() method. The goal is to eventually remove this hack. + if (!emitter._events || !emitter._events[event]) emitter.on(event, fn);else if (isArray(emitter._events[event])) emitter._events[event].unshift(fn);else emitter._events[event] = [fn, emitter._events[event]]; } -module.exports = mapCacheClear; - - -/***/ }), +function ReadableState(options, stream) { + Duplex = Duplex || __nccwpck_require__(7354); -/***/ 36275: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + options = options || {}; -var getMapData = __nccwpck_require__(1194); + // Duplex streams are both readable and writable, but share + // the same options object. + // However, some cases require setting options to different + // values for the readable and the writable sides of the duplex stream. + // These options can be provided separately as readableXXX and writableXXX. + var isDuplex = stream instanceof Duplex; -/** - * Removes `key` and its value from the map. - * - * @private - * @name delete - * @memberOf MapCache - * @param {string} key The key of the value to remove. - * @returns {boolean} Returns `true` if the entry was removed, else `false`. - */ -function mapCacheDelete(key) { - var result = getMapData(this, key)['delete'](key); - this.size -= result ? 1 : 0; - return result; -} + // object stream flag. Used to make read(n) ignore n and to + // make all the buffer merging and length checks go away + this.objectMode = !!options.objectMode; -module.exports = mapCacheDelete; + if (isDuplex) this.objectMode = this.objectMode || !!options.readableObjectMode; + // the point at which it stops calling _read() to fill the buffer + // Note: 0 is a valid value, means "don't call _read preemptively ever" + var hwm = options.highWaterMark; + var readableHwm = options.readableHighWaterMark; + var defaultHwm = this.objectMode ? 16 : 16 * 1024; -/***/ }), + if (hwm || hwm === 0) this.highWaterMark = hwm;else if (isDuplex && (readableHwm || readableHwm === 0)) this.highWaterMark = readableHwm;else this.highWaterMark = defaultHwm; -/***/ 30130: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + // cast to ints. + this.highWaterMark = Math.floor(this.highWaterMark); -var getMapData = __nccwpck_require__(1194); + // A linked list is used to store data chunks instead of an array because the + // linked list can remove elements from the beginning faster than + // array.shift() + this.buffer = new BufferList(); + this.length = 0; + this.pipes = null; + this.pipesCount = 0; + this.flowing = null; + this.ended = false; + this.endEmitted = false; + this.reading = false; -/** - * Gets the map value for `key`. - * - * @private - * @name get - * @memberOf MapCache - * @param {string} key The key of the value to get. - * @returns {*} Returns the entry value. - */ -function mapCacheGet(key) { - return getMapData(this, key).get(key); -} + // a flag to be able to tell if the event 'readable'/'data' is emitted + // immediately, or on a later tick. We set this to true at first, because + // any actions that shouldn't happen until "later" should generally also + // not happen before the first read call. + this.sync = true; -module.exports = mapCacheGet; + // whenever we return null, then we set a flag to say + // that we're awaiting a 'readable' event emission. + this.needReadable = false; + this.emittedReadable = false; + this.readableListening = false; + this.resumeScheduled = false; + // has it been destroyed + this.destroyed = false; -/***/ }), + // Crypto is kind of old and crusty. Historically, its default string + // encoding is 'binary' so we have to make this configurable. + // Everything else in the universe uses 'utf8', though. + this.defaultEncoding = options.defaultEncoding || 'utf8'; -/***/ 69254: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + // the number of writers that are awaiting a drain event in .pipe()s + this.awaitDrain = 0; -var getMapData = __nccwpck_require__(1194); + // if true, a maybeReadMore has been scheduled + this.readingMore = false; -/** - * Checks if a map value for `key` exists. - * - * @private - * @name has - * @memberOf MapCache - * @param {string} key The key of the entry to check. - * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`. - */ -function mapCacheHas(key) { - return getMapData(this, key).has(key); + this.decoder = null; + this.encoding = null; + if (options.encoding) { + if (!StringDecoder) StringDecoder = (__nccwpck_require__(8112)/* .StringDecoder */ .I); + this.decoder = new StringDecoder(options.encoding); + this.encoding = options.encoding; + } } -module.exports = mapCacheHas; +function Readable(options) { + Duplex = Duplex || __nccwpck_require__(7354); + if (!(this instanceof Readable)) return new Readable(options); -/***/ }), + this._readableState = new ReadableState(options, this); -/***/ 59806: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + // legacy + this.readable = true; -var getMapData = __nccwpck_require__(1194); + if (options) { + if (typeof options.read === 'function') this._read = options.read; -/** - * Sets the map `key` to `value`. - * - * @private - * @name set - * @memberOf MapCache - * @param {string} key The key of the value to set. - * @param {*} value The value to set. - * @returns {Object} Returns the map cache instance. - */ -function mapCacheSet(key, value) { - var data = getMapData(this, key), - size = data.size; + if (typeof options.destroy === 'function') this._destroy = options.destroy; + } - data.set(key, value); - this.size += data.size == size ? 0 : 1; - return this; + Stream.call(this); } -module.exports = mapCacheSet; +Object.defineProperty(Readable.prototype, 'destroyed', { + get: function () { + if (this._readableState === undefined) { + return false; + } + return this._readableState.destroyed; + }, + set: function (value) { + // we ignore the value if the stream + // has not been initialized yet + if (!this._readableState) { + return; + } + // backward compatibility, the user is explicitly + // managing destroyed + this._readableState.destroyed = value; + } +}); -/***/ }), +Readable.prototype.destroy = destroyImpl.destroy; +Readable.prototype._undestroy = destroyImpl.undestroy; +Readable.prototype._destroy = function (err, cb) { + this.push(null); + cb(err); +}; -/***/ 71563: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +// Manually shove something into the read() buffer. +// This returns true if the highWaterMark has not been hit yet, +// similar to how Writable.write() returns true if you should +// write() some more. +Readable.prototype.push = function (chunk, encoding) { + var state = this._readableState; + var skipChunkCheck; + + if (!state.objectMode) { + if (typeof chunk === 'string') { + encoding = encoding || state.defaultEncoding; + if (encoding !== state.encoding) { + chunk = Buffer.from(chunk, encoding); + encoding = ''; + } + skipChunkCheck = true; + } + } else { + skipChunkCheck = true; + } -var getNative = __nccwpck_require__(68573); + return readableAddChunk(this, chunk, encoding, false, skipChunkCheck); +}; -/* Built-in method references that are verified to be native. */ -var nativeCreate = getNative(Object, 'create'); +// Unshift should *always* be something directly out of read() +Readable.prototype.unshift = function (chunk) { + return readableAddChunk(this, chunk, null, true, false); +}; -module.exports = nativeCreate; +function readableAddChunk(stream, chunk, encoding, addToFront, skipChunkCheck) { + var state = stream._readableState; + if (chunk === null) { + state.reading = false; + onEofChunk(stream, state); + } else { + var er; + if (!skipChunkCheck) er = chunkInvalid(state, chunk); + if (er) { + stream.emit('error', er); + } else if (state.objectMode || chunk && chunk.length > 0) { + if (typeof chunk !== 'string' && !state.objectMode && Object.getPrototypeOf(chunk) !== Buffer.prototype) { + chunk = _uint8ArrayToBuffer(chunk); + } + if (addToFront) { + if (state.endEmitted) stream.emit('error', new Error('stream.unshift() after end event'));else addChunk(stream, state, chunk, true); + } else if (state.ended) { + stream.emit('error', new Error('stream.push() after EOF')); + } else { + state.reading = false; + if (state.decoder && !encoding) { + chunk = state.decoder.write(chunk); + if (state.objectMode || chunk.length !== 0) addChunk(stream, state, chunk, false);else maybeReadMore(stream, state); + } else { + addChunk(stream, state, chunk, false); + } + } + } else if (!addToFront) { + state.reading = false; + } + } -/***/ }), + return needMoreData(state); +} -/***/ 94008: -/***/ ((module) => { +function addChunk(stream, state, chunk, addToFront) { + if (state.flowing && state.length === 0 && !state.sync) { + stream.emit('data', chunk); + stream.read(0); + } else { + // update the buffer info. + state.length += state.objectMode ? 1 : chunk.length; + if (addToFront) state.buffer.unshift(chunk);else state.buffer.push(chunk); -/** - * This function is like - * [`Object.keys`](http://ecma-international.org/ecma-262/7.0/#sec-object.keys) - * except that it includes inherited enumerable properties. - * - * @private - * @param {Object} object The object to query. - * @returns {Array} Returns the array of property names. - */ -function nativeKeysIn(object) { - var result = []; - if (object != null) { - for (var key in Object(object)) { - result.push(key); - } + if (state.needReadable) emitReadable(stream); } - return result; + maybeReadMore(stream, state); } -module.exports = nativeKeysIn; +function chunkInvalid(state, chunk) { + var er; + if (!_isUint8Array(chunk) && typeof chunk !== 'string' && chunk !== undefined && !state.objectMode) { + er = new TypeError('Invalid non-string/buffer chunk'); + } + return er; +} +// if it's past the high water mark, we can push in some more. +// Also, if we have no data yet, we can stand some +// more bytes. This is to work around cases where hwm=0, +// such as the repl. Also, if the push() triggered a +// readable event, and the user called read(largeNumber) such that +// needReadable was set, then we ought to push more, so that another +// 'readable' event will be triggered. +function needMoreData(state) { + return !state.ended && (state.needReadable || state.length < state.highWaterMark || state.length === 0); +} -/***/ }), +Readable.prototype.isPaused = function () { + return this._readableState.flowing === false; +}; -/***/ 88724: -/***/ ((module, exports, __nccwpck_require__) => { +// backwards compatibility. +Readable.prototype.setEncoding = function (enc) { + if (!StringDecoder) StringDecoder = (__nccwpck_require__(8112)/* .StringDecoder */ .I); + this._readableState.decoder = new StringDecoder(enc); + this._readableState.encoding = enc; + return this; +}; -/* module decorator */ module = __nccwpck_require__.nmd(module); -var freeGlobal = __nccwpck_require__(78997); +// Don't raise the hwm > 8MB +var MAX_HWM = 0x800000; +function computeNewHighWaterMark(n) { + if (n >= MAX_HWM) { + n = MAX_HWM; + } else { + // Get the next highest power of 2 to prevent increasing hwm excessively in + // tiny amounts + n--; + n |= n >>> 1; + n |= n >>> 2; + n |= n >>> 4; + n |= n >>> 8; + n |= n >>> 16; + n++; + } + return n; +} -/** Detect free variable `exports`. */ -var freeExports = true && exports && !exports.nodeType && exports; +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function howMuchToRead(n, state) { + if (n <= 0 || state.length === 0 && state.ended) return 0; + if (state.objectMode) return 1; + if (n !== n) { + // Only flow one buffer at a time + if (state.flowing && state.length) return state.buffer.head.data.length;else return state.length; + } + // If we're asking for more than the current hwm, then raise the hwm. + if (n > state.highWaterMark) state.highWaterMark = computeNewHighWaterMark(n); + if (n <= state.length) return n; + // Don't have enough + if (!state.ended) { + state.needReadable = true; + return 0; + } + return state.length; +} -/** Detect free variable `module`. */ -var freeModule = freeExports && "object" == 'object' && module && !module.nodeType && module; +// you can override either this method, or the async _read(n) below. +Readable.prototype.read = function (n) { + debug('read', n); + n = parseInt(n, 10); + var state = this._readableState; + var nOrig = n; -/** Detect the popular CommonJS extension `module.exports`. */ -var moduleExports = freeModule && freeModule.exports === freeExports; + if (n !== 0) state.emittedReadable = false; -/** Detect free variable `process` from Node.js. */ -var freeProcess = moduleExports && freeGlobal.process; + // if we're doing read(0) to trigger a readable event, but we + // already have a bunch of data in the buffer, then just trigger + // the 'readable' event and move on. + if (n === 0 && state.needReadable && (state.length >= state.highWaterMark || state.ended)) { + debug('read: emitReadable', state.length, state.ended); + if (state.length === 0 && state.ended) endReadable(this);else emitReadable(this); + return null; + } -/** Used to access faster Node.js helpers. */ -var nodeUtil = (function() { - try { - // Use `util.types` for Node.js 10+. - var types = freeModule && freeModule.require && freeModule.require('util').types; + n = howMuchToRead(n, state); - if (types) { - return types; - } + // if we've ended, and we're now clear, then finish it up. + if (n === 0 && state.ended) { + if (state.length === 0) endReadable(this); + return null; + } - // Legacy `process.binding('util')` for Node.js < 10. - return freeProcess && freeProcess.binding && freeProcess.binding('util'); - } catch (e) {} -}()); + // All the actual chunk generation logic needs to be + // *below* the call to _read. The reason is that in certain + // synthetic stream cases, such as passthrough streams, _read + // may be a completely synchronous operation which may change + // the state of the read buffer, providing enough data when + // before there was *not* enough. + // + // So, the steps are: + // 1. Figure out what the state of things will be after we do + // a read from the buffer. + // + // 2. If that resulting state will trigger a _read, then call _read. + // Note that this may be asynchronous, or synchronous. Yes, it is + // deeply ugly to write APIs this way, but that still doesn't mean + // that the Readable class should behave improperly, as streams are + // designed to be sync/async agnostic. + // Take note if the _read call is sync or async (ie, if the read call + // has returned yet), so that we know whether or not it's safe to emit + // 'readable' etc. + // + // 3. Actually pull the requested chunks out of the buffer and return. -module.exports = nodeUtil; + // if we need a readable event, then we need to do some reading. + var doRead = state.needReadable; + debug('need readable', doRead); + + // if we currently have less than the highWaterMark, then also read some + if (state.length === 0 || state.length - n < state.highWaterMark) { + doRead = true; + debug('length less than watermark', doRead); + } + // however, if we've ended, then there's no point, and if we're already + // reading, then it's unnecessary. + if (state.ended || state.reading) { + doRead = false; + debug('reading or ended', doRead); + } else if (doRead) { + debug('do read'); + state.reading = true; + state.sync = true; + // if the length is currently zero, then we *need* a readable event. + if (state.length === 0) state.needReadable = true; + // call internal read method + this._read(state.highWaterMark); + state.sync = false; + // If _read pushed data synchronously, then `reading` will be false, + // and we need to re-evaluate how much data we can return to the user. + if (!state.reading) n = howMuchToRead(nOrig, state); + } -/***/ }), + var ret; + if (n > 0) ret = fromList(n, state);else ret = null; -/***/ 71723: -/***/ ((module) => { + if (ret === null) { + state.needReadable = true; + n = 0; + } else { + state.length -= n; + } -/** Used for built-in method references. */ -var objectProto = Object.prototype; + if (state.length === 0) { + // If we have nothing in the buffer, then we want to know + // as soon as we *do* get something into the buffer. + if (!state.ended) state.needReadable = true; -/** - * Used to resolve the - * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) - * of values. - */ -var nativeObjectToString = objectProto.toString; + // If we tried to read() past the EOF, then emit end on the next tick. + if (nOrig !== n && state.ended) endReadable(this); + } -/** - * Converts `value` to a string using `Object.prototype.toString`. - * - * @private - * @param {*} value The value to convert. - * @returns {string} Returns the converted string. - */ -function objectToString(value) { - return nativeObjectToString.call(value); -} + if (ret !== null) this.emit('data', ret); -module.exports = objectToString; + return ret; +}; +function onEofChunk(stream, state) { + if (state.ended) return; + if (state.decoder) { + var chunk = state.decoder.end(); + if (chunk && chunk.length) { + state.buffer.push(chunk); + state.length += state.objectMode ? 1 : chunk.length; + } + } + state.ended = true; -/***/ }), + // emit 'readable' now to make sure it gets picked up. + emitReadable(stream); +} -/***/ 61128: -/***/ ((module) => { +// Don't emit readable right away in sync mode, because this can trigger +// another read() call => stack overflow. This way, it might trigger +// a nextTick recursion warning, but that's not so bad. +function emitReadable(stream) { + var state = stream._readableState; + state.needReadable = false; + if (!state.emittedReadable) { + debug('emitReadable', state.flowing); + state.emittedReadable = true; + if (state.sync) pna.nextTick(emitReadable_, stream);else emitReadable_(stream); + } +} -/** - * Creates a unary function that invokes `func` with its argument transformed. - * - * @private - * @param {Function} func The function to wrap. - * @param {Function} transform The argument transform. - * @returns {Function} Returns the new function. - */ -function overArg(func, transform) { - return function(arg) { - return func(transform(arg)); - }; +function emitReadable_(stream) { + debug('emit readable'); + stream.emit('readable'); + flow(stream); } -module.exports = overArg; +// at this point, the user has presumably seen the 'readable' event, +// and called read() to consume some data. that may have triggered +// in turn another _read(n) call, in which case reading = true if +// it's in progress. +// However, if we're not ended, or reading, and the length < hwm, +// then go ahead and try to read some more preemptively. +function maybeReadMore(stream, state) { + if (!state.readingMore) { + state.readingMore = true; + pna.nextTick(maybeReadMore_, stream, state); + } +} +function maybeReadMore_(stream, state) { + var len = state.length; + while (!state.reading && !state.flowing && !state.ended && state.length < state.highWaterMark) { + debug('maybeReadMore read 0'); + stream.read(0); + if (len === state.length) + // didn't get any data, stop spinning. + break;else len = state.length; + } + state.readingMore = false; +} -/***/ }), +// abstract method. to be overridden in specific implementation classes. +// call cb(er, data) where data is <= n in length. +// for virtual (non-string, non-buffer) streams, "length" is somewhat +// arbitrary, and perhaps not very meaningful. +Readable.prototype._read = function (n) { + this.emit('error', new Error('_read() is not implemented')); +}; -/***/ 20168: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +Readable.prototype.pipe = function (dest, pipeOpts) { + var src = this; + var state = this._readableState; -var apply = __nccwpck_require__(59678); + switch (state.pipesCount) { + case 0: + state.pipes = dest; + break; + case 1: + state.pipes = [state.pipes, dest]; + break; + default: + state.pipes.push(dest); + break; + } + state.pipesCount += 1; + debug('pipe count=%d opts=%j', state.pipesCount, pipeOpts); -/* Built-in method references for those with the same name as other `lodash` methods. */ -var nativeMax = Math.max; + var doEnd = (!pipeOpts || pipeOpts.end !== false) && dest !== process.stdout && dest !== process.stderr; -/** - * A specialized version of `baseRest` which transforms the rest array. - * - * @private - * @param {Function} func The function to apply a rest parameter to. - * @param {number} [start=func.length-1] The start position of the rest parameter. - * @param {Function} transform The rest array transform. - * @returns {Function} Returns the new function. - */ -function overRest(func, start, transform) { - start = nativeMax(start === undefined ? (func.length - 1) : start, 0); - return function() { - var args = arguments, - index = -1, - length = nativeMax(args.length - start, 0), - array = Array(length); + var endFn = doEnd ? onend : unpipe; + if (state.endEmitted) pna.nextTick(endFn);else src.once('end', endFn); - while (++index < length) { - array[index] = args[start + index]; - } - index = -1; - var otherArgs = Array(start + 1); - while (++index < start) { - otherArgs[index] = args[index]; + dest.on('unpipe', onunpipe); + function onunpipe(readable, unpipeInfo) { + debug('onunpipe'); + if (readable === src) { + if (unpipeInfo && unpipeInfo.hasUnpiped === false) { + unpipeInfo.hasUnpiped = true; + cleanup(); + } } - otherArgs[start] = transform(array); - return apply(func, this, otherArgs); - }; -} - -module.exports = overRest; + } + function onend() { + debug('onend'); + dest.end(); + } -/***/ }), + // when the dest drains, it reduces the awaitDrain counter + // on the source. This would be more elegant with a .once() + // handler in flow(), but adding and removing repeatedly is + // too slow. + var ondrain = pipeOnDrain(src); + dest.on('drain', ondrain); -/***/ 6748: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + var cleanedUp = false; + function cleanup() { + debug('cleanup'); + // cleanup event handlers once the pipe is broken + dest.removeListener('close', onclose); + dest.removeListener('finish', onfinish); + dest.removeListener('drain', ondrain); + dest.removeListener('error', onerror); + dest.removeListener('unpipe', onunpipe); + src.removeListener('end', onend); + src.removeListener('end', unpipe); + src.removeListener('data', ondata); -var freeGlobal = __nccwpck_require__(78997); + cleanedUp = true; -/** Detect free variable `self`. */ -var freeSelf = typeof self == 'object' && self && self.Object === Object && self; + // if the reader is waiting for a drain event from this + // specific writer, then it would cause it to never start + // flowing again. + // So, if this is awaiting a drain, then we just call it now. + // If we don't know, then assume that we are waiting for one. + if (state.awaitDrain && (!dest._writableState || dest._writableState.needDrain)) ondrain(); + } -/** Used as a reference to the global object. */ -var root = freeGlobal || freeSelf || Function('return this')(); + // If the user pushes more data while we're writing to dest then we'll end up + // in ondata again. However, we only want to increase awaitDrain once because + // dest will only emit one 'drain' event for the multiple writes. + // => Introduce a guard on increasing awaitDrain. + var increasedAwaitDrain = false; + src.on('data', ondata); + function ondata(chunk) { + debug('ondata'); + increasedAwaitDrain = false; + var ret = dest.write(chunk); + if (false === ret && !increasedAwaitDrain) { + // If the user unpiped during `dest.write()`, it is possible + // to get stuck in a permanently paused state if that write + // also returned false. + // => Check whether `dest` is still a piping destination. + if ((state.pipesCount === 1 && state.pipes === dest || state.pipesCount > 1 && indexOf(state.pipes, dest) !== -1) && !cleanedUp) { + debug('false write response, pause', state.awaitDrain); + state.awaitDrain++; + increasedAwaitDrain = true; + } + src.pause(); + } + } -module.exports = root; + // if the dest has an error, then stop piping into it. + // however, don't suppress the throwing behavior for this. + function onerror(er) { + debug('onerror', er); + unpipe(); + dest.removeListener('error', onerror); + if (EElistenerCount(dest, 'error') === 0) dest.emit('error', er); + } + // Make sure our error handler is attached before userland ones. + prependListener(dest, 'error', onerror); -/***/ }), + // Both close and finish should trigger unpipe, but only once. + function onclose() { + dest.removeListener('finish', onfinish); + unpipe(); + } + dest.once('close', onclose); + function onfinish() { + debug('onfinish'); + dest.removeListener('close', onclose); + unpipe(); + } + dest.once('finish', onfinish); -/***/ 44671: -/***/ ((module) => { + function unpipe() { + debug('unpipe'); + src.unpipe(dest); + } -/** Used to stand-in for `undefined` hash values. */ -var HASH_UNDEFINED = '__lodash_hash_undefined__'; + // tell the dest that it's being piped to + dest.emit('pipe', src); -/** - * Adds `value` to the array cache. - * - * @private - * @name add - * @memberOf SetCache - * @alias push - * @param {*} value The value to cache. - * @returns {Object} Returns the cache instance. - */ -function setCacheAdd(value) { - this.__data__.set(value, HASH_UNDEFINED); - return this; -} + // start the flow if it hasn't been started already. + if (!state.flowing) { + debug('pipe resume'); + src.resume(); + } -module.exports = setCacheAdd; + return dest; +}; +function pipeOnDrain(src) { + return function () { + var state = src._readableState; + debug('pipeOnDrain', state.awaitDrain); + if (state.awaitDrain) state.awaitDrain--; + if (state.awaitDrain === 0 && EElistenerCount(src, 'data')) { + state.flowing = true; + flow(src); + } + }; +} -/***/ }), +Readable.prototype.unpipe = function (dest) { + var state = this._readableState; + var unpipeInfo = { hasUnpiped: false }; -/***/ 71884: -/***/ ((module) => { + // if we're not piping anywhere, then do nothing. + if (state.pipesCount === 0) return this; -/** - * Checks if `value` is in the array cache. - * - * @private - * @name has - * @memberOf SetCache - * @param {*} value The value to search for. - * @returns {number} Returns `true` if `value` is found, else `false`. - */ -function setCacheHas(value) { - return this.__data__.has(value); -} + // just one destination. most common case. + if (state.pipesCount === 1) { + // passed in one, but it's not the right one. + if (dest && dest !== state.pipes) return this; -module.exports = setCacheHas; + if (!dest) dest = state.pipes; + // got a match. + state.pipes = null; + state.pipesCount = 0; + state.flowing = false; + if (dest) dest.emit('unpipe', this, unpipeInfo); + return this; + } -/***/ }), + // slow case. multiple pipe destinations. -/***/ 11894: -/***/ ((module) => { + if (!dest) { + // remove all. + var dests = state.pipes; + var len = state.pipesCount; + state.pipes = null; + state.pipesCount = 0; + state.flowing = false; -/** - * Converts `set` to an array of its values. - * - * @private - * @param {Object} set The set to convert. - * @returns {Array} Returns the values. - */ -function setToArray(set) { - var index = -1, - result = Array(set.size); + for (var i = 0; i < len; i++) { + dests[i].emit('unpipe', this, { hasUnpiped: false }); + }return this; + } - set.forEach(function(value) { - result[++index] = value; - }); - return result; -} + // try to find the right one. + var index = indexOf(state.pipes, dest); + if (index === -1) return this; -module.exports = setToArray; + state.pipes.splice(index, 1); + state.pipesCount -= 1; + if (state.pipesCount === 1) state.pipes = state.pipes[0]; + dest.emit('unpipe', this, unpipeInfo); -/***/ }), + return this; +}; -/***/ 59402: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +// set up data events if they are asked for +// Ensure readable listeners eventually get something +Readable.prototype.on = function (ev, fn) { + var res = Stream.prototype.on.call(this, ev, fn); -var baseSetToString = __nccwpck_require__(64953), - shortOut = __nccwpck_require__(83286); + if (ev === 'data') { + // Start flowing on next tick if stream isn't explicitly paused + if (this._readableState.flowing !== false) this.resume(); + } else if (ev === 'readable') { + var state = this._readableState; + if (!state.endEmitted && !state.readableListening) { + state.readableListening = state.needReadable = true; + state.emittedReadable = false; + if (!state.reading) { + pna.nextTick(nReadingNextTick, this); + } else if (state.length) { + emitReadable(this); + } + } + } -/** - * Sets the `toString` method of `func` to return `string`. - * - * @private - * @param {Function} func The function to modify. - * @param {Function} string The `toString` result. - * @returns {Function} Returns `func`. - */ -var setToString = shortOut(baseSetToString); + return res; +}; +Readable.prototype.addListener = Readable.prototype.on; -module.exports = setToString; +function nReadingNextTick(self) { + debug('readable nexttick read 0'); + self.read(0); +} +// pause() and resume() are remnants of the legacy readable stream API +// If the user uses them, then switch into old mode. +Readable.prototype.resume = function () { + var state = this._readableState; + if (!state.flowing) { + debug('resume'); + state.flowing = true; + resume(this, state); + } + return this; +}; -/***/ }), +function resume(stream, state) { + if (!state.resumeScheduled) { + state.resumeScheduled = true; + pna.nextTick(resume_, stream, state); + } +} -/***/ 83286: -/***/ ((module) => { +function resume_(stream, state) { + if (!state.reading) { + debug('resume read 0'); + stream.read(0); + } -/** Used to detect hot functions by number of calls within a span of milliseconds. */ -var HOT_COUNT = 800, - HOT_SPAN = 16; + state.resumeScheduled = false; + state.awaitDrain = 0; + stream.emit('resume'); + flow(stream); + if (state.flowing && !state.reading) stream.read(0); +} -/* Built-in method references for those with the same name as other `lodash` methods. */ -var nativeNow = Date.now; +Readable.prototype.pause = function () { + debug('call pause flowing=%j', this._readableState.flowing); + if (false !== this._readableState.flowing) { + debug('pause'); + this._readableState.flowing = false; + this.emit('pause'); + } + return this; +}; -/** - * Creates a function that'll short out and invoke `identity` instead - * of `func` when it's called `HOT_COUNT` or more times in `HOT_SPAN` - * milliseconds. - * - * @private - * @param {Function} func The function to restrict. - * @returns {Function} Returns the new shortable function. - */ -function shortOut(func) { - var count = 0, - lastCalled = 0; +function flow(stream) { + var state = stream._readableState; + debug('flow', state.flowing); + while (state.flowing && stream.read() !== null) {} +} - return function() { - var stamp = nativeNow(), - remaining = HOT_SPAN - (stamp - lastCalled); +// wrap an old-style stream as the async data source. +// This is *not* part of the readable stream interface. +// It is an ugly unfortunate mess of history. +Readable.prototype.wrap = function (stream) { + var _this = this; - lastCalled = stamp; - if (remaining > 0) { - if (++count >= HOT_COUNT) { - return arguments[0]; - } - } else { - count = 0; - } - return func.apply(undefined, arguments); - }; -} + var state = this._readableState; + var paused = false; -module.exports = shortOut; + stream.on('end', function () { + debug('wrapped end'); + if (state.decoder && !state.ended) { + var chunk = state.decoder.end(); + if (chunk && chunk.length) _this.push(chunk); + } + _this.push(null); + }); -/***/ }), + stream.on('data', function (chunk) { + debug('wrapped data'); + if (state.decoder) chunk = state.decoder.write(chunk); -/***/ 95232: -/***/ ((module) => { + // don't skip over falsy values in objectMode + if (state.objectMode && (chunk === null || chunk === undefined)) return;else if (!state.objectMode && (!chunk || !chunk.length)) return; -/** - * A specialized version of `_.indexOf` which performs strict equality - * comparisons of values, i.e. `===`. - * - * @private - * @param {Array} array The array to inspect. - * @param {*} value The value to search for. - * @param {number} fromIndex The index to search from. - * @returns {number} Returns the index of the matched value, else `-1`. - */ -function strictIndexOf(array, value, fromIndex) { - var index = fromIndex - 1, - length = array.length; + var ret = _this.push(chunk); + if (!ret) { + paused = true; + stream.pause(); + } + }); - while (++index < length) { - if (array[index] === value) { - return index; + // proxy all the other methods. + // important when wrapping filters and duplexes. + for (var i in stream) { + if (this[i] === undefined && typeof stream[i] === 'function') { + this[i] = function (method) { + return function () { + return stream[method].apply(stream, arguments); + }; + }(i); } } - return -1; -} -module.exports = strictIndexOf; + // proxy certain important events. + for (var n = 0; n < kProxyEvents.length; n++) { + stream.on(kProxyEvents[n], this.emit.bind(this, kProxyEvents[n])); + } + // when we try to consume some more bytes, simply unpause the + // underlying stream. + this._read = function (n) { + debug('wrapped _read', n); + if (paused) { + paused = false; + stream.resume(); + } + }; -/***/ }), + return this; +}; -/***/ 57192: -/***/ ((module) => { +Object.defineProperty(Readable.prototype, 'readableHighWaterMark', { + // making it explicit this property is not enumerable + // because otherwise some prototype manipulation in + // userland will fail + enumerable: false, + get: function () { + return this._readableState.highWaterMark; + } +}); -/** Used for built-in method references. */ -var funcProto = Function.prototype; +// exposed for testing purposes only. +Readable._fromList = fromList; -/** Used to resolve the decompiled source of functions. */ -var funcToString = funcProto.toString; +// Pluck off n bytes from an array of buffers. +// Length is the combined lengths of all the buffers in the list. +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function fromList(n, state) { + // nothing buffered + if (state.length === 0) return null; -/** - * Converts `func` to its source code. - * - * @private - * @param {Function} func The function to convert. - * @returns {string} Returns the source code. - */ -function toSource(func) { - if (func != null) { - try { - return funcToString.call(func); - } catch (e) {} - try { - return (func + ''); - } catch (e) {} + var ret; + if (state.objectMode) ret = state.buffer.shift();else if (!n || n >= state.length) { + // read it all, truncate the list + if (state.decoder) ret = state.buffer.join('');else if (state.buffer.length === 1) ret = state.buffer.head.data;else ret = state.buffer.concat(state.length); + state.buffer.clear(); + } else { + // read part of list + ret = fromListPartial(n, state.buffer, state.decoder); } - return ''; + + return ret; } -module.exports = toSource; +// Extracts only enough buffered data to satisfy the amount requested. +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function fromListPartial(n, list, hasStrings) { + var ret; + if (n < list.head.data.length) { + // slice is the same for buffers and strings + ret = list.head.data.slice(0, n); + list.head.data = list.head.data.slice(n); + } else if (n === list.head.data.length) { + // first chunk is a perfect match + ret = list.shift(); + } else { + // result spans more than one buffer + ret = hasStrings ? copyFromBufferString(n, list) : copyFromBuffer(n, list); + } + return ret; +} +// Copies a specified amount of characters from the list of buffered data +// chunks. +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function copyFromBufferString(n, list) { + var p = list.head; + var c = 1; + var ret = p.data; + n -= ret.length; + while (p = p.next) { + var str = p.data; + var nb = n > str.length ? str.length : n; + if (nb === str.length) ret += str;else ret += str.slice(0, n); + n -= nb; + if (n === 0) { + if (nb === str.length) { + ++c; + if (p.next) list.head = p.next;else list.head = list.tail = null; + } else { + list.head = p; + p.data = str.slice(nb); + } + break; + } + ++c; + } + list.length -= c; + return ret; +} -/***/ }), +// Copies a specified amount of bytes from the list of buffered data chunks. +// This function is designed to be inlinable, so please take care when making +// changes to the function body. +function copyFromBuffer(n, list) { + var ret = Buffer.allocUnsafe(n); + var p = list.head; + var c = 1; + p.data.copy(ret); + n -= p.data.length; + while (p = p.next) { + var buf = p.data; + var nb = n > buf.length ? buf.length : n; + buf.copy(ret, ret.length - n, 0, nb); + n -= nb; + if (n === 0) { + if (nb === buf.length) { + ++c; + if (p.next) list.head = p.next;else list.head = list.tail = null; + } else { + list.head = p; + p.data = buf.slice(nb); + } + break; + } + ++c; + } + list.length -= c; + return ret; +} -/***/ 85089: -/***/ ((module) => { +function endReadable(stream) { + var state = stream._readableState; -/** - * Creates a function that returns `value`. - * - * @static - * @memberOf _ - * @since 2.4.0 - * @category Util - * @param {*} value The value to return from the new function. - * @returns {Function} Returns the new constant function. - * @example - * - * var objects = _.times(2, _.constant({ 'a': 1 })); - * - * console.log(objects); - * // => [{ 'a': 1 }, { 'a': 1 }] - * - * console.log(objects[0] === objects[1]); - * // => true - */ -function constant(value) { - return function() { - return value; - }; + // If we get here before consuming all the bytes, then that is a + // bug in node. Should never happen. + if (state.length > 0) throw new Error('"endReadable()" called on non-empty stream'); + + if (!state.endEmitted) { + state.ended = true; + pna.nextTick(endReadableNT, state, stream); + } } -module.exports = constant; +function endReadableNT(state, stream) { + // Check that we didn't get one last unshift. + if (!state.endEmitted && state.length === 0) { + state.endEmitted = true; + stream.readable = false; + stream.emit('end'); + } +} +function indexOf(xs, x) { + for (var i = 0, l = xs.length; i < l; i++) { + if (xs[i] === x) return i; + } + return -1; +} /***/ }), -/***/ 7511: +/***/ 34278: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var baseRest = __nccwpck_require__(22035), - eq = __nccwpck_require__(75199), - isIterateeCall = __nccwpck_require__(3349), - keysIn = __nccwpck_require__(19430); +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +// a transform stream is a readable/writable stream where you do +// something with the data. Sometimes it's called a "filter", +// but that's not a great name for it, since that implies a thing where +// some bits pass through, and others are simply ignored. (That would +// be a valid example of a transform, of course.) +// +// While the output is causally related to the input, it's not a +// necessarily symmetric or synchronous transformation. For example, +// a zlib stream might take multiple plain-text writes(), and then +// emit a single compressed chunk some time in the future. +// +// Here's how this works: +// +// The Transform stream has all the aspects of the readable and writable +// stream classes. When you write(chunk), that calls _write(chunk,cb) +// internally, and returns false if there's a lot of pending writes +// buffered up. When you call read(), that calls _read(n) until +// there's enough pending readable data buffered up. +// +// In a transform stream, the written data is placed in a buffer. When +// _read(n) is called, it transforms the queued up data, calling the +// buffered _write cb's as it consumes chunks. If consuming a single +// written chunk would result in multiple output chunks, then the first +// outputted bit calls the readcb, and subsequent chunks just go into +// the read buffer, and will cause it to emit 'readable' if necessary. +// +// This way, back-pressure is actually determined by the reading side, +// since _read has to be called to start processing a new chunk. However, +// a pathological inflate type of transform can cause excessive buffering +// here. For example, imagine a stream where every byte of input is +// interpreted as an integer from 0-255, and then results in that many +// bytes of output. Writing the 4 bytes {ff,ff,ff,ff} would result in +// 1kb of data being output. In this case, you could write a very small +// amount of input, and end up with a very large amount of output. In +// such a pathological inflating mechanism, there'd be no way to tell +// the system to stop doing the transform. A single 4MB write could +// cause the system to run out of memory. +// +// However, even in such a pathological case, only a single written chunk +// would be consumed, and then the rest would wait (un-transformed) until +// the results of the previous transformed chunk were consumed. -/** Used for built-in method references. */ -var objectProto = Object.prototype; -/** Used to check objects for own properties. */ -var hasOwnProperty = objectProto.hasOwnProperty; -/** - * Assigns own and inherited enumerable string keyed properties of source - * objects to the destination object for all destination properties that - * resolve to `undefined`. Source objects are applied from left to right. - * Once a property is set, additional values of the same property are ignored. - * - * **Note:** This method mutates `object`. - * - * @static - * @since 0.1.0 - * @memberOf _ - * @category Object - * @param {Object} object The destination object. - * @param {...Object} [sources] The source objects. - * @returns {Object} Returns `object`. - * @see _.defaultsDeep - * @example - * - * _.defaults({ 'a': 1 }, { 'b': 2 }, { 'a': 3 }); - * // => { 'a': 1, 'b': 2 } - */ -var defaults = baseRest(function(object, sources) { - object = Object(object); +module.exports = Transform; - var index = -1; - var length = sources.length; - var guard = length > 2 ? sources[2] : undefined; +var Duplex = __nccwpck_require__(7354); - if (guard && isIterateeCall(sources[0], sources[1], guard)) { - length = 1; - } +/**/ +var util = Object.create(__nccwpck_require__(22465)); +util.inherits = __nccwpck_require__(76153); +/**/ - while (++index < length) { - var source = sources[index]; - var props = keysIn(source); - var propsIndex = -1; - var propsLength = props.length; +util.inherits(Transform, Duplex); - while (++propsIndex < propsLength) { - var key = props[propsIndex]; - var value = object[key]; +function afterTransform(er, data) { + var ts = this._transformState; + ts.transforming = false; - if (value === undefined || - (eq(value, objectProto[key]) && !hasOwnProperty.call(object, key))) { - object[key] = source[key]; - } - } + var cb = ts.writecb; + + if (!cb) { + return this.emit('error', new Error('write callback called multiple times')); } - return object; -}); + ts.writechunk = null; + ts.writecb = null; -module.exports = defaults; + if (data != null) // single equals check for both `null` and `undefined` + this.push(data); + cb(er); -/***/ }), + var rs = this._readableState; + rs.reading = false; + if (rs.needReadable || rs.length < rs.highWaterMark) { + this._read(rs.highWaterMark); + } +} -/***/ 57294: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +function Transform(options) { + if (!(this instanceof Transform)) return new Transform(options); -var baseDifference = __nccwpck_require__(3126), - baseFlatten = __nccwpck_require__(63183), - baseRest = __nccwpck_require__(22035), - isArrayLikeObject = __nccwpck_require__(97100); + Duplex.call(this, options); -/** - * Creates an array of `array` values not included in the other given arrays - * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) - * for equality comparisons. The order and references of result values are - * determined by the first array. - * - * **Note:** Unlike `_.pullAll`, this method returns a new array. - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Array - * @param {Array} array The array to inspect. - * @param {...Array} [values] The values to exclude. - * @returns {Array} Returns the new array of filtered values. - * @see _.without, _.xor - * @example - * - * _.difference([2, 1], [2, 3]); - * // => [1] - */ -var difference = baseRest(function(array, values) { - return isArrayLikeObject(array) - ? baseDifference(array, baseFlatten(values, 1, isArrayLikeObject, true)) - : []; -}); + this._transformState = { + afterTransform: afterTransform.bind(this), + needTransform: false, + transforming: false, + writecb: null, + writechunk: null, + writeencoding: null + }; -module.exports = difference; + // start out asking for a readable event once data is transformed. + this._readableState.needReadable = true; + // we have implemented the _read method, and done the other things + // that Readable wants before the first _read call, so unset the + // sync guard flag. + this._readableState.sync = false; -/***/ }), + if (options) { + if (typeof options.transform === 'function') this._transform = options.transform; -/***/ 75199: -/***/ ((module) => { + if (typeof options.flush === 'function') this._flush = options.flush; + } -/** - * Performs a - * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) - * comparison between two values to determine if they are equivalent. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to compare. - * @param {*} other The other value to compare. - * @returns {boolean} Returns `true` if the values are equivalent, else `false`. - * @example - * - * var object = { 'a': 1 }; - * var other = { 'a': 1 }; - * - * _.eq(object, object); - * // => true - * - * _.eq(object, other); - * // => false - * - * _.eq('a', 'a'); - * // => true - * - * _.eq('a', Object('a')); - * // => false - * - * _.eq(NaN, NaN); - * // => true - */ -function eq(value, other) { - return value === other || (value !== value && other !== other); + // When the writable side finishes, then flush out anything remaining. + this.on('prefinish', prefinish); } -module.exports = eq; +function prefinish() { + var _this = this; + if (typeof this._flush === 'function') { + this._flush(function (er, data) { + done(_this, er, data); + }); + } else { + done(this, null, null); + } +} -/***/ }), +Transform.prototype.push = function (chunk, encoding) { + this._transformState.needTransform = false; + return Duplex.prototype.push.call(this, chunk, encoding); +}; -/***/ 97047: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +// This is the part where you do stuff! +// override this function in implementation classes. +// 'chunk' is an input chunk. +// +// Call `push(newChunk)` to pass along transformed output +// to the readable side. You may call 'push' zero or more times. +// +// Call `cb(err)` when you are done with this chunk. If you pass +// an error, then that'll put the hurt on the whole operation. If you +// never call cb(), then you'll never get another chunk. +Transform.prototype._transform = function (chunk, encoding, cb) { + throw new Error('_transform() is not implemented'); +}; -var baseFlatten = __nccwpck_require__(63183); +Transform.prototype._write = function (chunk, encoding, cb) { + var ts = this._transformState; + ts.writecb = cb; + ts.writechunk = chunk; + ts.writeencoding = encoding; + if (!ts.transforming) { + var rs = this._readableState; + if (ts.needTransform || rs.needReadable || rs.length < rs.highWaterMark) this._read(rs.highWaterMark); + } +}; -/** - * Flattens `array` a single level deep. - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Array - * @param {Array} array The array to flatten. - * @returns {Array} Returns the new flattened array. - * @example - * - * _.flatten([1, [2, [3, [4]], 5]]); - * // => [1, 2, [3, [4]], 5] - */ -function flatten(array) { - var length = array == null ? 0 : array.length; - return length ? baseFlatten(array, 1) : []; -} +// Doesn't matter what the args are here. +// _transform does all the work. +// That we got here means that the readable side wants more data. +Transform.prototype._read = function (n) { + var ts = this._transformState; -module.exports = flatten; + if (ts.writechunk !== null && ts.writecb && !ts.transforming) { + ts.transforming = true; + this._transform(ts.writechunk, ts.writeencoding, ts.afterTransform); + } else { + // mark that we need a transform, so that any data that comes in + // will get processed, now that we've asked for it. + ts.needTransform = true; + } +}; +Transform.prototype._destroy = function (err, cb) { + var _this2 = this; -/***/ }), + Duplex.prototype._destroy.call(this, err, function (err2) { + cb(err2); + _this2.emit('close'); + }); +}; -/***/ 46851: -/***/ ((module) => { +function done(stream, er, data) { + if (er) return stream.emit('error', er); -/** - * This method returns the first argument it receives. - * - * @static - * @since 0.1.0 - * @memberOf _ - * @category Util - * @param {*} value Any value. - * @returns {*} Returns `value`. - * @example - * - * var object = { 'a': 1 }; - * - * console.log(_.identity(object) === object); - * // => true - */ -function identity(value) { - return value; -} + if (data != null) // single equals check for both `null` and `undefined` + stream.push(data); -module.exports = identity; + // if there's nothing in the write buffer, then that means + // that nothing more will ever be provided + if (stream._writableState.length) throw new Error('Calling transform done when ws.length != 0'); + if (stream._transformState.transforming) throw new Error('Calling transform done when still transforming'); + + return stream.push(null); +} /***/ }), -/***/ 60541: +/***/ 2232: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -var baseIsArguments = __nccwpck_require__(93605), - isObjectLike = __nccwpck_require__(51645); - -/** Used for built-in method references. */ -var objectProto = Object.prototype; - -/** Used to check objects for own properties. */ -var hasOwnProperty = objectProto.hasOwnProperty; - -/** Built-in value references. */ -var propertyIsEnumerable = objectProto.propertyIsEnumerable; - -/** - * Checks if `value` is likely an `arguments` object. - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an `arguments` object, - * else `false`. - * @example - * - * _.isArguments(function() { return arguments; }()); - * // => true - * - * _.isArguments([1, 2, 3]); - * // => false - */ -var isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) { - return isObjectLike(value) && hasOwnProperty.call(value, 'callee') && - !propertyIsEnumerable.call(value, 'callee'); -}; +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. -module.exports = isArguments; +// A bit simpler than readable streams. +// Implement an async ._write(chunk, encoding, cb), and it'll handle all +// the drain event emission and buffering. -/***/ }), -/***/ 77192: -/***/ ((module) => { +/**/ -/** - * Checks if `value` is classified as an `Array` object. - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an array, else `false`. - * @example - * - * _.isArray([1, 2, 3]); - * // => true - * - * _.isArray(document.body.children); - * // => false - * - * _.isArray('abc'); - * // => false - * - * _.isArray(_.noop); - * // => false - */ -var isArray = Array.isArray; +var pna = __nccwpck_require__(61710); +/**/ -module.exports = isArray; +module.exports = Writable; +/* */ +function WriteReq(chunk, encoding, cb) { + this.chunk = chunk; + this.encoding = encoding; + this.callback = cb; + this.next = null; +} -/***/ }), +// It seems a linked list but it is not +// there will be only 2 of these for each stream +function CorkedRequest(state) { + var _this = this; -/***/ 75119: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + this.next = null; + this.entry = null; + this.finish = function () { + onCorkedFinish(_this, state); + }; +} +/* */ -var isFunction = __nccwpck_require__(34329), - isLength = __nccwpck_require__(56657); +/**/ +var asyncWrite = !process.browser && ['v0.10', 'v0.9.'].indexOf(process.version.slice(0, 5)) > -1 ? setImmediate : pna.nextTick; +/**/ -/** - * Checks if `value` is array-like. A value is considered array-like if it's - * not a function and has a `value.length` that's an integer greater than or - * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is array-like, else `false`. - * @example - * - * _.isArrayLike([1, 2, 3]); - * // => true - * - * _.isArrayLike(document.body.children); - * // => true - * - * _.isArrayLike('abc'); - * // => true - * - * _.isArrayLike(_.noop); - * // => false - */ -function isArrayLike(value) { - return value != null && isLength(value.length) && !isFunction(value); -} +/**/ +var Duplex; +/**/ -module.exports = isArrayLike; +Writable.WritableState = WritableState; +/**/ +var util = Object.create(__nccwpck_require__(22465)); +util.inherits = __nccwpck_require__(76153); +/**/ -/***/ }), +/**/ +var internalUtil = { + deprecate: __nccwpck_require__(48728) +}; +/**/ -/***/ 97100: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { +/**/ +var Stream = __nccwpck_require__(94324); +/**/ -var isArrayLike = __nccwpck_require__(75119), - isObjectLike = __nccwpck_require__(51645); +/**/ -/** - * This method is like `_.isArrayLike` except that it also checks if `value` - * is an object. - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an array-like object, - * else `false`. - * @example - * - * _.isArrayLikeObject([1, 2, 3]); - * // => true - * - * _.isArrayLikeObject(document.body.children); - * // => true - * - * _.isArrayLikeObject('abc'); - * // => false - * - * _.isArrayLikeObject(_.noop); - * // => false - */ -function isArrayLikeObject(value) { - return isObjectLike(value) && isArrayLike(value); +var Buffer = (__nccwpck_require__(79253).Buffer); +var OurUint8Array = (typeof global !== 'undefined' ? global : typeof window !== 'undefined' ? window : typeof self !== 'undefined' ? self : {}).Uint8Array || function () {}; +function _uint8ArrayToBuffer(chunk) { + return Buffer.from(chunk); +} +function _isUint8Array(obj) { + return Buffer.isBuffer(obj) || obj instanceof OurUint8Array; } -module.exports = isArrayLikeObject; - +/**/ -/***/ }), +var destroyImpl = __nccwpck_require__(83716); -/***/ 43739: -/***/ ((module, exports, __nccwpck_require__) => { +util.inherits(Writable, Stream); -/* module decorator */ module = __nccwpck_require__.nmd(module); -var root = __nccwpck_require__(6748), - stubFalse = __nccwpck_require__(92074); +function nop() {} -/** Detect free variable `exports`. */ -var freeExports = true && exports && !exports.nodeType && exports; +function WritableState(options, stream) { + Duplex = Duplex || __nccwpck_require__(7354); -/** Detect free variable `module`. */ -var freeModule = freeExports && "object" == 'object' && module && !module.nodeType && module; + options = options || {}; -/** Detect the popular CommonJS extension `module.exports`. */ -var moduleExports = freeModule && freeModule.exports === freeExports; + // Duplex streams are both readable and writable, but share + // the same options object. + // However, some cases require setting options to different + // values for the readable and the writable sides of the duplex stream. + // These options can be provided separately as readableXXX and writableXXX. + var isDuplex = stream instanceof Duplex; -/** Built-in value references. */ -var Buffer = moduleExports ? root.Buffer : undefined; + // object stream flag to indicate whether or not this stream + // contains buffers or objects. + this.objectMode = !!options.objectMode; -/* Built-in method references for those with the same name as other `lodash` methods. */ -var nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined; + if (isDuplex) this.objectMode = this.objectMode || !!options.writableObjectMode; -/** - * Checks if `value` is a buffer. - * - * @static - * @memberOf _ - * @since 4.3.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a buffer, else `false`. - * @example - * - * _.isBuffer(new Buffer(2)); - * // => true - * - * _.isBuffer(new Uint8Array(2)); - * // => false - */ -var isBuffer = nativeIsBuffer || stubFalse; + // the point at which write() starts returning false + // Note: 0 is a valid value, means that we always return false if + // the entire buffer is not flushed immediately on write() + var hwm = options.highWaterMark; + var writableHwm = options.writableHighWaterMark; + var defaultHwm = this.objectMode ? 16 : 16 * 1024; -module.exports = isBuffer; + if (hwm || hwm === 0) this.highWaterMark = hwm;else if (isDuplex && (writableHwm || writableHwm === 0)) this.highWaterMark = writableHwm;else this.highWaterMark = defaultHwm; + // cast to ints. + this.highWaterMark = Math.floor(this.highWaterMark); -/***/ }), + // if _final has been called + this.finalCalled = false; -/***/ 34329: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + // drain event flag. + this.needDrain = false; + // at the start of calling end() + this.ending = false; + // when end() has been called, and returned + this.ended = false; + // when 'finish' is emitted + this.finished = false; -var baseGetTag = __nccwpck_require__(29117), - isObject = __nccwpck_require__(96482); + // has it been destroyed + this.destroyed = false; -/** `Object#toString` result references. */ -var asyncTag = '[object AsyncFunction]', - funcTag = '[object Function]', - genTag = '[object GeneratorFunction]', - proxyTag = '[object Proxy]'; + // should we decode strings into buffers before passing to _write? + // this is here so that some node-core streams can optimize string + // handling at a lower level. + var noDecode = options.decodeStrings === false; + this.decodeStrings = !noDecode; -/** - * Checks if `value` is classified as a `Function` object. - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a function, else `false`. - * @example - * - * _.isFunction(_); - * // => true - * - * _.isFunction(/abc/); - * // => false - */ -function isFunction(value) { - if (!isObject(value)) { - return false; - } - // The use of `Object#toString` avoids issues with the `typeof` operator - // in Safari 9 which returns 'object' for typed arrays and other constructors. - var tag = baseGetTag(value); - return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag; -} + // Crypto is kind of old and crusty. Historically, its default string + // encoding is 'binary' so we have to make this configurable. + // Everything else in the universe uses 'utf8', though. + this.defaultEncoding = options.defaultEncoding || 'utf8'; -module.exports = isFunction; + // not an actual buffer we keep track of, but a measurement + // of how much we're waiting to get pushed to some underlying + // socket or file. + this.length = 0; + // a flag to see when we're in the middle of a write. + this.writing = false; -/***/ }), + // when true all writes will be buffered until .uncork() call + this.corked = 0; -/***/ 56657: -/***/ ((module) => { + // a flag to be able to tell if the onwrite cb is called immediately, + // or on a later tick. We set this to true at first, because any + // actions that shouldn't happen until "later" should generally also + // not happen before the first write call. + this.sync = true; -/** Used as references for various `Number` constants. */ -var MAX_SAFE_INTEGER = 9007199254740991; + // a flag to know if we're processing previously buffered items, which + // may call the _write() callback in the same tick, so that we don't + // end up in an overlapped onwrite situation. + this.bufferProcessing = false; -/** - * Checks if `value` is a valid array-like length. - * - * **Note:** This method is loosely based on - * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength). - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a valid length, else `false`. - * @example - * - * _.isLength(3); - * // => true - * - * _.isLength(Number.MIN_VALUE); - * // => false - * - * _.isLength(Infinity); - * // => false - * - * _.isLength('3'); - * // => false - */ -function isLength(value) { - return typeof value == 'number' && - value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; -} + // the callback that's passed to _write(chunk,cb) + this.onwrite = function (er) { + onwrite(stream, er); + }; -module.exports = isLength; + // the callback that the user supplies to write(chunk,encoding,cb) + this.writecb = null; + // the amount that is being written when _write is called. + this.writelen = 0; -/***/ }), + this.bufferedRequest = null; + this.lastBufferedRequest = null; -/***/ 96482: -/***/ ((module) => { + // number of pending user-supplied write callbacks + // this must be 0 before 'finish' can be emitted + this.pendingcb = 0; -/** - * Checks if `value` is the - * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) - * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is an object, else `false`. - * @example - * - * _.isObject({}); - * // => true - * - * _.isObject([1, 2, 3]); - * // => true - * - * _.isObject(_.noop); - * // => true - * - * _.isObject(null); - * // => false - */ -function isObject(value) { - var type = typeof value; - return value != null && (type == 'object' || type == 'function'); -} + // emit prefinish if the only thing we're waiting for is _write cbs + // This is relevant for synchronous Transform streams + this.prefinished = false; -module.exports = isObject; + // True if the error was already emitted and should not be thrown again + this.errorEmitted = false; + // count buffered requests + this.bufferedRequestCount = 0; -/***/ }), + // allocate the first CorkedRequest, there is always + // one allocated and free to use, and we maintain at most two + this.corkedRequestsFree = new CorkedRequest(this); +} -/***/ 51645: -/***/ ((module) => { +WritableState.prototype.getBuffer = function getBuffer() { + var current = this.bufferedRequest; + var out = []; + while (current) { + out.push(current); + current = current.next; + } + return out; +}; -/** - * Checks if `value` is object-like. A value is object-like if it's not `null` - * and has a `typeof` result of "object". - * - * @static - * @memberOf _ - * @since 4.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is object-like, else `false`. - * @example - * - * _.isObjectLike({}); - * // => true - * - * _.isObjectLike([1, 2, 3]); - * // => true - * - * _.isObjectLike(_.noop); - * // => false - * - * _.isObjectLike(null); - * // => false - */ -function isObjectLike(value) { - return value != null && typeof value == 'object'; -} +(function () { + try { + Object.defineProperty(WritableState.prototype, 'buffer', { + get: internalUtil.deprecate(function () { + return this.getBuffer(); + }, '_writableState.buffer is deprecated. Use _writableState.getBuffer ' + 'instead.', 'DEP0003') + }); + } catch (_) {} +})(); -module.exports = isObjectLike; +// Test _writableState for inheritance to account for Duplex streams, +// whose prototype chain only points to Readable. +var realHasInstance; +if (typeof Symbol === 'function' && Symbol.hasInstance && typeof Function.prototype[Symbol.hasInstance] === 'function') { + realHasInstance = Function.prototype[Symbol.hasInstance]; + Object.defineProperty(Writable, Symbol.hasInstance, { + value: function (object) { + if (realHasInstance.call(this, object)) return true; + if (this !== Writable) return false; + return object && object._writableState instanceof WritableState; + } + }); +} else { + realHasInstance = function (object) { + return object instanceof this; + }; +} -/***/ }), +function Writable(options) { + Duplex = Duplex || __nccwpck_require__(7354); -/***/ 36542: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + // Writable ctor is applied to Duplexes, too. + // `realHasInstance` is necessary because using plain `instanceof` + // would return false, as no `_writableState` property is attached. -var baseGetTag = __nccwpck_require__(29117), - getPrototype = __nccwpck_require__(86194), - isObjectLike = __nccwpck_require__(51645); + // Trying to use the custom `instanceof` for Writable here will also break the + // Node.js LazyTransform implementation, which has a non-trivial getter for + // `_writableState` that would lead to infinite recursion. + if (!realHasInstance.call(Writable, this) && !(this instanceof Duplex)) { + return new Writable(options); + } -/** `Object#toString` result references. */ -var objectTag = '[object Object]'; + this._writableState = new WritableState(options, this); -/** Used for built-in method references. */ -var funcProto = Function.prototype, - objectProto = Object.prototype; + // legacy. + this.writable = true; -/** Used to resolve the decompiled source of functions. */ -var funcToString = funcProto.toString; + if (options) { + if (typeof options.write === 'function') this._write = options.write; -/** Used to check objects for own properties. */ -var hasOwnProperty = objectProto.hasOwnProperty; + if (typeof options.writev === 'function') this._writev = options.writev; -/** Used to infer the `Object` constructor. */ -var objectCtorString = funcToString.call(Object); + if (typeof options.destroy === 'function') this._destroy = options.destroy; -/** - * Checks if `value` is a plain object, that is, an object created by the - * `Object` constructor or one with a `[[Prototype]]` of `null`. - * - * @static - * @memberOf _ - * @since 0.8.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a plain object, else `false`. - * @example - * - * function Foo() { - * this.a = 1; - * } - * - * _.isPlainObject(new Foo); - * // => false - * - * _.isPlainObject([1, 2, 3]); - * // => false - * - * _.isPlainObject({ 'x': 0, 'y': 0 }); - * // => true - * - * _.isPlainObject(Object.create(null)); - * // => true - */ -function isPlainObject(value) { - if (!isObjectLike(value) || baseGetTag(value) != objectTag) { - return false; - } - var proto = getPrototype(value); - if (proto === null) { - return true; + if (typeof options.final === 'function') this._final = options.final; } - var Ctor = hasOwnProperty.call(proto, 'constructor') && proto.constructor; - return typeof Ctor == 'function' && Ctor instanceof Ctor && - funcToString.call(Ctor) == objectCtorString; + + Stream.call(this); } -module.exports = isPlainObject; +// Otherwise people can pipe Writable streams, which is just wrong. +Writable.prototype.pipe = function () { + this.emit('error', new Error('Cannot pipe, not readable')); +}; +function writeAfterEnd(stream, cb) { + var er = new Error('write after end'); + // TODO: defer error events consistently everywhere, not just the cb + stream.emit('error', er); + pna.nextTick(cb, er); +} -/***/ }), +// Checks that a user-supplied chunk is valid, especially for the particular +// mode the stream is in. Currently this means that `null` is never accepted +// and undefined/non-string values are only allowed in object mode. +function validChunk(stream, state, chunk, cb) { + var valid = true; + var er = false; -/***/ 35000: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + if (chunk === null) { + er = new TypeError('May not write null values to stream'); + } else if (typeof chunk !== 'string' && chunk !== undefined && !state.objectMode) { + er = new TypeError('Invalid non-string/buffer chunk'); + } + if (er) { + stream.emit('error', er); + pna.nextTick(cb, er); + valid = false; + } + return valid; +} -var baseIsTypedArray = __nccwpck_require__(16880), - baseUnary = __nccwpck_require__(55506), - nodeUtil = __nccwpck_require__(88724); +Writable.prototype.write = function (chunk, encoding, cb) { + var state = this._writableState; + var ret = false; + var isBuf = !state.objectMode && _isUint8Array(chunk); -/* Node.js helper references. */ -var nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray; + if (isBuf && !Buffer.isBuffer(chunk)) { + chunk = _uint8ArrayToBuffer(chunk); + } -/** - * Checks if `value` is classified as a typed array. - * - * @static - * @memberOf _ - * @since 3.0.0 - * @category Lang - * @param {*} value The value to check. - * @returns {boolean} Returns `true` if `value` is a typed array, else `false`. - * @example - * - * _.isTypedArray(new Uint8Array); - * // => true - * - * _.isTypedArray([]); - * // => false - */ -var isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray; + if (typeof encoding === 'function') { + cb = encoding; + encoding = null; + } -module.exports = isTypedArray; + if (isBuf) encoding = 'buffer';else if (!encoding) encoding = state.defaultEncoding; + if (typeof cb !== 'function') cb = nop; -/***/ }), + if (state.ended) writeAfterEnd(this, cb);else if (isBuf || validChunk(this, state, chunk, cb)) { + state.pendingcb++; + ret = writeOrBuffer(this, state, isBuf, chunk, encoding, cb); + } -/***/ 19430: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + return ret; +}; -var arrayLikeKeys = __nccwpck_require__(62000), - baseKeysIn = __nccwpck_require__(82094), - isArrayLike = __nccwpck_require__(75119); +Writable.prototype.cork = function () { + var state = this._writableState; -/** - * Creates an array of the own and inherited enumerable property names of `object`. - * - * **Note:** Non-object values are coerced to objects. - * - * @static - * @memberOf _ - * @since 3.0.0 - * @category Object - * @param {Object} object The object to query. - * @returns {Array} Returns the array of property names. - * @example - * - * function Foo() { - * this.a = 1; - * this.b = 2; - * } - * - * Foo.prototype.c = 3; - * - * _.keysIn(new Foo); - * // => ['a', 'b', 'c'] (iteration order is not guaranteed) - */ -function keysIn(object) { - return isArrayLike(object) ? arrayLikeKeys(object, true) : baseKeysIn(object); -} + state.corked++; +}; -module.exports = keysIn; +Writable.prototype.uncork = function () { + var state = this._writableState; + if (state.corked) { + state.corked--; -/***/ }), + if (!state.writing && !state.corked && !state.bufferProcessing && state.bufferedRequest) clearBuffer(this, state); + } +}; -/***/ 89029: -/***/ ((module) => { +Writable.prototype.setDefaultEncoding = function setDefaultEncoding(encoding) { + // node::ParseEncoding() requires lower case. + if (typeof encoding === 'string') encoding = encoding.toLowerCase(); + if (!(['hex', 'utf8', 'utf-8', 'ascii', 'binary', 'base64', 'ucs2', 'ucs-2', 'utf16le', 'utf-16le', 'raw'].indexOf((encoding + '').toLowerCase()) > -1)) throw new TypeError('Unknown encoding: ' + encoding); + this._writableState.defaultEncoding = encoding; + return this; +}; -/** - * This method returns `undefined`. - * - * @static - * @memberOf _ - * @since 2.3.0 - * @category Util - * @example - * - * _.times(2, _.noop); - * // => [undefined, undefined] - */ -function noop() { - // No operation performed. +function decodeChunk(state, chunk, encoding) { + if (!state.objectMode && state.decodeStrings !== false && typeof chunk === 'string') { + chunk = Buffer.from(chunk, encoding); + } + return chunk; } -module.exports = noop; +Object.defineProperty(Writable.prototype, 'writableHighWaterMark', { + // making it explicit this property is not enumerable + // because otherwise some prototype manipulation in + // userland will fail + enumerable: false, + get: function () { + return this._writableState.highWaterMark; + } +}); + +// if we're already writing something, then just put this +// in the queue, and wait our turn. Otherwise, call _write +// If we return false, then we need a drain event, so set that flag. +function writeOrBuffer(stream, state, isBuf, chunk, encoding, cb) { + if (!isBuf) { + var newChunk = decodeChunk(state, chunk, encoding); + if (chunk !== newChunk) { + isBuf = true; + encoding = 'buffer'; + chunk = newChunk; + } + } + var len = state.objectMode ? 1 : chunk.length; + state.length += len; -/***/ }), + var ret = state.length < state.highWaterMark; + // we must ensure that previous needDrain will not be reset to false. + if (!ret) state.needDrain = true; -/***/ 92074: -/***/ ((module) => { + if (state.writing || state.corked) { + var last = state.lastBufferedRequest; + state.lastBufferedRequest = { + chunk: chunk, + encoding: encoding, + isBuf: isBuf, + callback: cb, + next: null + }; + if (last) { + last.next = state.lastBufferedRequest; + } else { + state.bufferedRequest = state.lastBufferedRequest; + } + state.bufferedRequestCount += 1; + } else { + doWrite(stream, state, false, len, chunk, encoding, cb); + } -/** - * This method returns `false`. - * - * @static - * @memberOf _ - * @since 4.13.0 - * @category Util - * @returns {boolean} Returns `false`. - * @example - * - * _.times(2, _.stubFalse); - * // => [false, false] - */ -function stubFalse() { - return false; + return ret; } -module.exports = stubFalse; - +function doWrite(stream, state, writev, len, chunk, encoding, cb) { + state.writelen = len; + state.writecb = cb; + state.writing = true; + state.sync = true; + if (writev) stream._writev(chunk, state.onwrite);else stream._write(chunk, encoding, state.onwrite); + state.sync = false; +} -/***/ }), +function onwriteError(stream, state, sync, er, cb) { + --state.pendingcb; -/***/ 73270: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + if (sync) { + // defer the callback if we are being called synchronously + // to avoid piling up things on the stack + pna.nextTick(cb, er); + // this can emit finish, and it will always happen + // after error + pna.nextTick(finishMaybe, stream, state); + stream._writableState.errorEmitted = true; + stream.emit('error', er); + } else { + // the caller expect this to happen before if + // it is async + cb(er); + stream._writableState.errorEmitted = true; + stream.emit('error', er); + // this can emit finish, but finish must + // always follow error + finishMaybe(stream, state); + } +} -var baseFlatten = __nccwpck_require__(63183), - baseRest = __nccwpck_require__(22035), - baseUniq = __nccwpck_require__(32772), - isArrayLikeObject = __nccwpck_require__(97100); +function onwriteStateUpdate(state) { + state.writing = false; + state.writecb = null; + state.length -= state.writelen; + state.writelen = 0; +} -/** - * Creates an array of unique values, in order, from all given arrays using - * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) - * for equality comparisons. - * - * @static - * @memberOf _ - * @since 0.1.0 - * @category Array - * @param {...Array} [arrays] The arrays to inspect. - * @returns {Array} Returns the new array of combined values. - * @example - * - * _.union([2], [1, 2]); - * // => [2, 1] - */ -var union = baseRest(function(arrays) { - return baseUniq(baseFlatten(arrays, 1, isArrayLikeObject, true)); -}); +function onwrite(stream, er) { + var state = stream._writableState; + var sync = state.sync; + var cb = state.writecb; -module.exports = union; + onwriteStateUpdate(state); + if (er) onwriteError(stream, state, sync, er, cb);else { + // Check if we're actually ready to finish, but don't emit yet + var finished = needFinish(state); -/***/ }), + if (!finished && !state.corked && !state.bufferProcessing && state.bufferedRequest) { + clearBuffer(stream, state); + } -/***/ 4469: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + if (sync) { + /**/ + asyncWrite(afterWrite, stream, state, finished, cb); + /**/ + } else { + afterWrite(stream, state, finished, cb); + } + } +} -var path = __nccwpck_require__(16928); -var fs = __nccwpck_require__(79896); -var _0777 = parseInt('0777', 8); +function afterWrite(stream, state, finished, cb) { + if (!finished) onwriteDrain(stream, state); + state.pendingcb--; + cb(); + finishMaybe(stream, state); +} -module.exports = mkdirP.mkdirp = mkdirP.mkdirP = mkdirP; +// Must force callback to be called on nextTick, so that we don't +// emit 'drain' before the write() consumer gets the 'false' return +// value, and has a chance to attach a 'drain' listener. +function onwriteDrain(stream, state) { + if (state.length === 0 && state.needDrain) { + state.needDrain = false; + stream.emit('drain'); + } +} -function mkdirP (p, opts, f, made) { - if (typeof opts === 'function') { - f = opts; - opts = {}; - } - else if (!opts || typeof opts !== 'object') { - opts = { mode: opts }; - } - - var mode = opts.mode; - var xfs = opts.fs || fs; - - if (mode === undefined) { - mode = _0777 - } - if (!made) made = null; - - var cb = f || /* istanbul ignore next */ function () {}; - p = path.resolve(p); - - xfs.mkdir(p, mode, function (er) { - if (!er) { - made = made || p; - return cb(null, made); - } - switch (er.code) { - case 'ENOENT': - /* istanbul ignore if */ - if (path.dirname(p) === p) return cb(er); - mkdirP(path.dirname(p), opts, function (er, made) { - /* istanbul ignore if */ - if (er) cb(er, made); - else mkdirP(p, opts, cb, made); - }); - break; +// if there's something in the buffer waiting, then process it +function clearBuffer(stream, state) { + state.bufferProcessing = true; + var entry = state.bufferedRequest; - // In the case of any other error, just see if there's a dir - // there already. If so, then hooray! If not, then something - // is borked. - default: - xfs.stat(p, function (er2, stat) { - // if the stat fails, then that's super weird. - // let the original error be the failure reason. - if (er2 || !stat.isDirectory()) cb(er, made) - else cb(null, made); - }); - break; - } - }); -} + if (stream._writev && entry && entry.next) { + // Fast case, write everything using _writev() + var l = state.bufferedRequestCount; + var buffer = new Array(l); + var holder = state.corkedRequestsFree; + holder.entry = entry; -mkdirP.sync = function sync (p, opts, made) { - if (!opts || typeof opts !== 'object') { - opts = { mode: opts }; - } - - var mode = opts.mode; - var xfs = opts.fs || fs; - - if (mode === undefined) { - mode = _0777 + var count = 0; + var allBuffers = true; + while (entry) { + buffer[count] = entry; + if (!entry.isBuf) allBuffers = false; + entry = entry.next; + count += 1; } - if (!made) made = null; + buffer.allBuffers = allBuffers; - p = path.resolve(p); + doWrite(stream, state, true, state.length, buffer, '', holder.finish); - try { - xfs.mkdirSync(p, mode); - made = made || p; + // doWrite is almost always async, defer these to save a bit of time + // as the hot path ends with doWrite + state.pendingcb++; + state.lastBufferedRequest = null; + if (holder.next) { + state.corkedRequestsFree = holder.next; + holder.next = null; + } else { + state.corkedRequestsFree = new CorkedRequest(state); } - catch (err0) { - switch (err0.code) { - case 'ENOENT' : - made = sync(path.dirname(p), opts, made); - sync(p, opts, made); - break; + state.bufferedRequestCount = 0; + } else { + // Slow case, write chunks one-by-one + while (entry) { + var chunk = entry.chunk; + var encoding = entry.encoding; + var cb = entry.callback; + var len = state.objectMode ? 1 : chunk.length; - // In the case of any other error, just see if there's a dir - // there already. If so, then hooray! If not, then something - // is borked. - default: - var stat; - try { - stat = xfs.statSync(p); - } - catch (err1) /* istanbul ignore next */ { - throw err0; - } - /* istanbul ignore if */ - if (!stat.isDirectory()) throw err0; - break; - } + doWrite(stream, state, false, len, chunk, encoding, cb); + entry = entry.next; + state.bufferedRequestCount--; + // if we didn't call the onwrite immediately, then + // it means that we need to wait until it does. + // also, that means that the chunk and cb are currently + // being processed, so move the buffer counter past them. + if (state.writing) { + break; + } } - return made; -}; + if (entry === null) state.lastBufferedRequest = null; + } + state.bufferedRequest = entry; + state.bufferProcessing = false; +} -/***/ }), +Writable.prototype._write = function (chunk, encoding, cb) { + cb(new Error('_write() is not implemented')); +}; -/***/ 70744: -/***/ ((module) => { +Writable.prototype._writev = null; -/** - * Helpers. - */ +Writable.prototype.end = function (chunk, encoding, cb) { + var state = this._writableState; -var s = 1000; -var m = s * 60; -var h = m * 60; -var d = h * 24; -var w = d * 7; -var y = d * 365.25; + if (typeof chunk === 'function') { + cb = chunk; + chunk = null; + encoding = null; + } else if (typeof encoding === 'function') { + cb = encoding; + encoding = null; + } -/** - * Parse or format the given `val`. - * - * Options: - * - * - `long` verbose formatting [false] - * - * @param {String|Number} val - * @param {Object} [options] - * @throws {Error} throw an error if val is not a non-empty string or a number - * @return {String|Number} - * @api public - */ + if (chunk !== null && chunk !== undefined) this.write(chunk, encoding); -module.exports = function (val, options) { - options = options || {}; - var type = typeof val; - if (type === 'string' && val.length > 0) { - return parse(val); - } else if (type === 'number' && isFinite(val)) { - return options.long ? fmtLong(val) : fmtShort(val); + // .end() fully uncorks + if (state.corked) { + state.corked = 1; + this.uncork(); } - throw new Error( - 'val is not a non-empty string or a valid number. val=' + - JSON.stringify(val) - ); + + // ignore unnecessary end() calls. + if (!state.ending) endWritable(this, state, cb); }; -/** - * Parse the given `str` and return milliseconds. - * - * @param {String} str - * @return {Number} - * @api private - */ +function needFinish(state) { + return state.ending && state.length === 0 && state.bufferedRequest === null && !state.finished && !state.writing; +} +function callFinal(stream, state) { + stream._final(function (err) { + state.pendingcb--; + if (err) { + stream.emit('error', err); + } + state.prefinished = true; + stream.emit('prefinish'); + finishMaybe(stream, state); + }); +} +function prefinish(stream, state) { + if (!state.prefinished && !state.finalCalled) { + if (typeof stream._final === 'function') { + state.pendingcb++; + state.finalCalled = true; + pna.nextTick(callFinal, stream, state); + } else { + state.prefinished = true; + stream.emit('prefinish'); + } + } +} -function parse(str) { - str = String(str); - if (str.length > 100) { - return; +function finishMaybe(stream, state) { + var need = needFinish(state); + if (need) { + prefinish(stream, state); + if (state.pendingcb === 0) { + state.finished = true; + stream.emit('finish'); + } } - var match = /^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec( - str - ); - if (!match) { - return; + return need; +} + +function endWritable(stream, state, cb) { + state.ending = true; + finishMaybe(stream, state); + if (cb) { + if (state.finished) pna.nextTick(cb);else stream.once('finish', cb); } - var n = parseFloat(match[1]); - var type = (match[2] || 'ms').toLowerCase(); - switch (type) { - case 'years': - case 'year': - case 'yrs': - case 'yr': - case 'y': - return n * y; - case 'weeks': - case 'week': - case 'w': - return n * w; - case 'days': - case 'day': - case 'd': - return n * d; - case 'hours': - case 'hour': - case 'hrs': - case 'hr': - case 'h': - return n * h; - case 'minutes': - case 'minute': - case 'mins': - case 'min': - case 'm': - return n * m; - case 'seconds': - case 'second': - case 'secs': - case 'sec': - case 's': - return n * s; - case 'milliseconds': - case 'millisecond': - case 'msecs': - case 'msec': - case 'ms': - return n; - default: - return undefined; + state.ended = true; + stream.writable = false; +} + +function onCorkedFinish(corkReq, state, err) { + var entry = corkReq.entry; + corkReq.entry = null; + while (entry) { + var cb = entry.callback; + state.pendingcb--; + cb(err); + entry = entry.next; } + + // reuse the free corkReq. + state.corkedRequestsFree.next = corkReq; } -/** - * Short format for `ms`. - * - * @param {Number} ms - * @return {String} - * @api private - */ +Object.defineProperty(Writable.prototype, 'destroyed', { + get: function () { + if (this._writableState === undefined) { + return false; + } + return this._writableState.destroyed; + }, + set: function (value) { + // we ignore the value if the stream + // has not been initialized yet + if (!this._writableState) { + return; + } -function fmtShort(ms) { - var msAbs = Math.abs(ms); - if (msAbs >= d) { - return Math.round(ms / d) + 'd'; - } - if (msAbs >= h) { - return Math.round(ms / h) + 'h'; - } - if (msAbs >= m) { - return Math.round(ms / m) + 'm'; - } - if (msAbs >= s) { - return Math.round(ms / s) + 's'; + // backward compatibility, the user is explicitly + // managing destroyed + this._writableState.destroyed = value; } - return ms + 'ms'; +}); + +Writable.prototype.destroy = destroyImpl.destroy; +Writable.prototype._undestroy = destroyImpl.undestroy; +Writable.prototype._destroy = function (err, cb) { + this.end(); + cb(err); +}; + +/***/ }), + +/***/ 65866: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + + + +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +var Buffer = (__nccwpck_require__(79253).Buffer); +var util = __nccwpck_require__(39023); + +function copyBuffer(src, target, offset) { + src.copy(target, offset); } -/** - * Long format for `ms`. - * - * @param {Number} ms - * @return {String} - * @api private - */ +module.exports = function () { + function BufferList() { + _classCallCheck(this, BufferList); -function fmtLong(ms) { - var msAbs = Math.abs(ms); - if (msAbs >= d) { - return plural(ms, msAbs, d, 'day'); - } - if (msAbs >= h) { - return plural(ms, msAbs, h, 'hour'); - } - if (msAbs >= m) { - return plural(ms, msAbs, m, 'minute'); - } - if (msAbs >= s) { - return plural(ms, msAbs, s, 'second'); + this.head = null; + this.tail = null; + this.length = 0; } - return ms + ' ms'; -} -/** - * Pluralization helper. - */ + BufferList.prototype.push = function push(v) { + var entry = { data: v, next: null }; + if (this.length > 0) this.tail.next = entry;else this.head = entry; + this.tail = entry; + ++this.length; + }; -function plural(ms, msAbs, n, name) { - var isPlural = msAbs >= n * 1.5; - return Math.round(ms / n) + ' ' + name + (isPlural ? 's' : ''); -} + BufferList.prototype.unshift = function unshift(v) { + var entry = { data: v, next: this.head }; + if (this.length === 0) this.tail = entry; + this.head = entry; + ++this.length; + }; + + BufferList.prototype.shift = function shift() { + if (this.length === 0) return; + var ret = this.head.data; + if (this.length === 1) this.head = this.tail = null;else this.head = this.head.next; + --this.length; + return ret; + }; + + BufferList.prototype.clear = function clear() { + this.head = this.tail = null; + this.length = 0; + }; + + BufferList.prototype.join = function join(s) { + if (this.length === 0) return ''; + var p = this.head; + var ret = '' + p.data; + while (p = p.next) { + ret += s + p.data; + }return ret; + }; + + BufferList.prototype.concat = function concat(n) { + if (this.length === 0) return Buffer.alloc(0); + var ret = Buffer.allocUnsafe(n >>> 0); + var p = this.head; + var i = 0; + while (p) { + copyBuffer(p.data, ret, i); + i += p.data.length; + p = p.next; + } + return ret; + }; + + return BufferList; +}(); +if (util && util.inspect && util.inspect.custom) { + module.exports.prototype[util.inspect.custom] = function () { + var obj = util.inspect({ length: this.length }); + return this.constructor.name + ' ' + obj; + }; +} /***/ }), -/***/ 56133: -/***/ ((module) => { +/***/ 83716: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -/*! - * normalize-path - * - * Copyright (c) 2014-2018, Jon Schlinkert. - * Released under the MIT License. - */ -module.exports = function(path, stripTrailing) { - if (typeof path !== 'string') { - throw new TypeError('expected path to be a string'); - } - if (path === '\\' || path === '/') return '/'; +/**/ - var len = path.length; - if (len <= 1) return path; +var pna = __nccwpck_require__(61710); +/**/ - // ensure that win32 namespaces has two leading slashes, so that the path is - // handled properly by the win32 version of path.parse() after being normalized - // https://msdn.microsoft.com/library/windows/desktop/aa365247(v=vs.85).aspx#namespaces - var prefix = ''; - if (len > 4 && path[3] === '\\') { - var ch = path[2]; - if ((ch === '?' || ch === '.') && path.slice(0, 2) === '\\\\') { - path = path.slice(2); - prefix = '//'; +// undocumented cb() API, needed for core, not for public API +function destroy(err, cb) { + var _this = this; + + var readableDestroyed = this._readableState && this._readableState.destroyed; + var writableDestroyed = this._writableState && this._writableState.destroyed; + + if (readableDestroyed || writableDestroyed) { + if (cb) { + cb(err); + } else if (err) { + if (!this._writableState) { + pna.nextTick(emitErrorNT, this, err); + } else if (!this._writableState.errorEmitted) { + this._writableState.errorEmitted = true; + pna.nextTick(emitErrorNT, this, err); + } } - } - var segs = path.split(/[/\\]+/); - if (stripTrailing !== false && segs[segs.length - 1] === '') { - segs.pop(); + return this; } - return prefix + segs.join('/'); -}; - -/***/ }), + // we set destroyed to true before firing error callbacks in order + // to make it re-entrance safe in case destroy() is called within callbacks -/***/ 41564: -/***/ ((module) => { + if (this._readableState) { + this._readableState.destroyed = true; + } + // if this is a duplex stream mark the writable part as destroyed as well + if (this._writableState) { + this._writableState.destroyed = true; + } + this._destroy(err || null, function (err) { + if (!cb && err) { + if (!_this._writableState) { + pna.nextTick(emitErrorNT, _this, err); + } else if (!_this._writableState.errorEmitted) { + _this._writableState.errorEmitted = true; + pna.nextTick(emitErrorNT, _this, err); + } + } else if (cb) { + cb(err); + } + }); -if (typeof process === 'undefined' || - !process.version || - process.version.indexOf('v0.') === 0 || - process.version.indexOf('v1.') === 0 && process.version.indexOf('v1.8.') !== 0) { - module.exports = { nextTick: nextTick }; -} else { - module.exports = process + return this; } -function nextTick(fn, arg1, arg2, arg3) { - if (typeof fn !== 'function') { - throw new TypeError('"callback" argument must be a function'); +function undestroy() { + if (this._readableState) { + this._readableState.destroyed = false; + this._readableState.reading = false; + this._readableState.ended = false; + this._readableState.endEmitted = false; } - var len = arguments.length; - var args, i; - switch (len) { - case 0: - case 1: - return process.nextTick(fn); - case 2: - return process.nextTick(function afterTickOne() { - fn.call(null, arg1); - }); - case 3: - return process.nextTick(function afterTickTwo() { - fn.call(null, arg1, arg2); - }); - case 4: - return process.nextTick(function afterTickThree() { - fn.call(null, arg1, arg2, arg3); - }); - default: - args = new Array(len - 1); - i = 0; - while (i < args.length) { - args[i++] = arguments[i]; - } - return process.nextTick(function afterTick() { - fn.apply(null, args); - }); + + if (this._writableState) { + this._writableState.destroyed = false; + this._writableState.ended = false; + this._writableState.ending = false; + this._writableState.finalCalled = false; + this._writableState.prefinished = false; + this._writableState.finished = false; + this._writableState.errorEmitted = false; } } +function emitErrorNT(self, err) { + self.emit('error', err); +} + +module.exports = { + destroy: destroy, + undestroy: undestroy +}; + +/***/ }), + +/***/ 94324: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + +module.exports = __nccwpck_require__(2203); /***/ }), -/***/ 7945: -/***/ ((module) => { +/***/ 26614: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -// for now just expose the builtin process global from node.js -module.exports = global.process; +module.exports = __nccwpck_require__(52818).PassThrough + + +/***/ }), + +/***/ 52818: +/***/ ((module, exports, __nccwpck_require__) => { + +var Stream = __nccwpck_require__(2203); +if (process.env.READABLE_STREAM === 'disable' && Stream) { + module.exports = Stream; + exports = module.exports = Stream.Readable; + exports.Readable = Stream.Readable; + exports.Writable = Stream.Writable; + exports.Duplex = Stream.Duplex; + exports.Transform = Stream.Transform; + exports.PassThrough = Stream.PassThrough; + exports.Stream = Stream; +} else { + exports = module.exports = __nccwpck_require__(97576); + exports.Stream = Stream || exports; + exports.Readable = exports; + exports.Writable = __nccwpck_require__(2232); + exports.Duplex = __nccwpck_require__(7354); + exports.Transform = __nccwpck_require__(34278); + exports.PassThrough = __nccwpck_require__(96348); +} /***/ }), -/***/ 80652: +/***/ 72105: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { SymbolDispose } = __nccwpck_require__(50999) -const { AbortError, codes } = __nccwpck_require__(69220) -const { isNodeStream, isWebStream, kControllerErrorFunction } = __nccwpck_require__(83426) -const eos = __nccwpck_require__(36815) +const { SymbolDispose } = __nccwpck_require__(95512) +const { AbortError, codes } = __nccwpck_require__(79885) +const { isNodeStream, isWebStream, kControllerErrorFunction } = __nccwpck_require__(73289) +const eos = __nccwpck_require__(44356) const { ERR_INVALID_ARG_TYPE } = codes let addAbortListener @@ -31728,7 +32506,7 @@ module.exports.addAbortSignalNoValidate = function (signal, stream) { if (signal.aborted) { onAbort() } else { - addAbortListener = addAbortListener || (__nccwpck_require__(23539).addAbortListener) + addAbortListener = addAbortListener || (__nccwpck_require__(75806).addAbortListener) const disposable = addAbortListener(signal, onAbort) eos(stream, disposable[SymbolDispose]) } @@ -31738,14 +32516,14 @@ module.exports.addAbortSignalNoValidate = function (signal, stream) { /***/ }), -/***/ 77336: +/***/ 21195: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { StringPrototypeSlice, SymbolIterator, TypedArrayPrototypeSet, Uint8Array } = __nccwpck_require__(50999) +const { StringPrototypeSlice, SymbolIterator, TypedArrayPrototypeSet, Uint8Array } = __nccwpck_require__(95512) const { Buffer } = __nccwpck_require__(20181) -const { inspect } = __nccwpck_require__(23539) +const { inspect } = __nccwpck_require__(75806) module.exports = class BufferList { constructor() { this.head = null @@ -31902,14 +32680,14 @@ module.exports = class BufferList { /***/ }), -/***/ 64999: +/***/ 78256: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { pipeline } = __nccwpck_require__(16701) -const Duplex = __nccwpck_require__(94449) -const { destroyer } = __nccwpck_require__(65089) +const { pipeline } = __nccwpck_require__(84712) +const Duplex = __nccwpck_require__(60400) +const { destroyer } = __nccwpck_require__(13822) const { isNodeStream, isReadable, @@ -31918,12 +32696,12 @@ const { isTransformStream, isWritableStream, isReadableStream -} = __nccwpck_require__(83426) +} = __nccwpck_require__(73289) const { AbortError, codes: { ERR_INVALID_ARG_VALUE, ERR_MISSING_ARGS } -} = __nccwpck_require__(69220) -const eos = __nccwpck_require__(36815) +} = __nccwpck_require__(79885) +const eos = __nccwpck_require__(44356) module.exports = function compose(...streams) { if (streams.length === 0) { throw new ERR_MISSING_ARGS('streams') @@ -32103,14 +32881,14 @@ module.exports = function compose(...streams) { /***/ }), -/***/ 65089: +/***/ 13822: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /* replacement start */ -const process = __nccwpck_require__(7945) +const process = __nccwpck_require__(50180) /* replacement end */ @@ -32118,9 +32896,9 @@ const { aggregateTwoErrors, codes: { ERR_MULTIPLE_CALLBACK }, AbortError -} = __nccwpck_require__(69220) -const { Symbol } = __nccwpck_require__(50999) -const { kIsDestroyed, isDestroyed, isFinished, isServerRequest } = __nccwpck_require__(83426) +} = __nccwpck_require__(79885) +const { Symbol } = __nccwpck_require__(95512) +const { kIsDestroyed, isDestroyed, isFinished, isServerRequest } = __nccwpck_require__(73289) const kDestroy = Symbol('kDestroy') const kConstruct = Symbol('kConstruct') function checkError(err, w, r) { @@ -32400,7 +33178,7 @@ module.exports = { /***/ }), -/***/ 94449: +/***/ 60400: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { // Copyright Joyent, Inc. and other Node contributors. @@ -32436,10 +33214,10 @@ const { ObjectGetOwnPropertyDescriptor, ObjectKeys, ObjectSetPrototypeOf -} = __nccwpck_require__(50999) +} = __nccwpck_require__(95512) module.exports = Duplex -const Readable = __nccwpck_require__(17783) -const Writable = __nccwpck_require__(58939) +const Readable = __nccwpck_require__(406) +const Writable = __nccwpck_require__(34234) ObjectSetPrototypeOf(Duplex.prototype, Readable.prototype) ObjectSetPrototypeOf(Duplex, Readable) { @@ -32542,7 +33320,7 @@ Duplex.toWeb = function (duplex) { let duplexify Duplex.from = function (body) { if (!duplexify) { - duplexify = __nccwpck_require__(4599) + duplexify = __nccwpck_require__(68432) } return duplexify(body, 'body') } @@ -32550,12 +33328,12 @@ Duplex.from = function (body) { /***/ }), -/***/ 4599: +/***/ 68432: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /* replacement start */ -const process = __nccwpck_require__(7945) +const process = __nccwpck_require__(50180) /* replacement end */ @@ -32571,18 +33349,18 @@ const { isDuplexNodeStream, isReadableStream, isWritableStream -} = __nccwpck_require__(83426) -const eos = __nccwpck_require__(36815) +} = __nccwpck_require__(73289) +const eos = __nccwpck_require__(44356) const { AbortError, codes: { ERR_INVALID_ARG_TYPE, ERR_INVALID_RETURN_VALUE } -} = __nccwpck_require__(69220) -const { destroyer } = __nccwpck_require__(65089) -const Duplex = __nccwpck_require__(94449) -const Readable = __nccwpck_require__(17783) -const Writable = __nccwpck_require__(58939) -const { createDeferredPromise } = __nccwpck_require__(23539) -const from = __nccwpck_require__(4659) +} = __nccwpck_require__(79885) +const { destroyer } = __nccwpck_require__(13822) +const Duplex = __nccwpck_require__(60400) +const Readable = __nccwpck_require__(406) +const Writable = __nccwpck_require__(34234) +const { createDeferredPromise } = __nccwpck_require__(75806) +const from = __nccwpck_require__(17806) const Blob = globalThis.Blob || bufferModule.Blob const isBlob = typeof Blob !== 'undefined' @@ -32592,8 +33370,8 @@ const isBlob = : function isBlob(b) { return false } -const AbortController = globalThis.AbortController || (__nccwpck_require__(17413).AbortController) -const { FunctionPrototypeCall } = __nccwpck_require__(50999) +const AbortController = globalThis.AbortController || (__nccwpck_require__(19914).AbortController) +const { FunctionPrototypeCall } = __nccwpck_require__(95512) // This is needed for pre node 17. class Duplexify extends Duplex { @@ -32935,7 +33713,7 @@ function _duplexify(pair) { /***/ }), -/***/ 36815: +/***/ 44356: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { // Ported from https://github.com/mafintosh/end-of-stream with @@ -32945,15 +33723,15 @@ function _duplexify(pair) { /* replacement start */ -const process = __nccwpck_require__(7945) +const process = __nccwpck_require__(50180) /* replacement end */ -const { AbortError, codes } = __nccwpck_require__(69220) +const { AbortError, codes } = __nccwpck_require__(79885) const { ERR_INVALID_ARG_TYPE, ERR_STREAM_PREMATURE_CLOSE } = codes -const { kEmptyObject, once } = __nccwpck_require__(23539) -const { validateAbortSignal, validateFunction, validateObject, validateBoolean } = __nccwpck_require__(49554) -const { Promise, PromisePrototypeThen, SymbolDispose } = __nccwpck_require__(50999) +const { kEmptyObject, once } = __nccwpck_require__(75806) +const { validateAbortSignal, validateFunction, validateObject, validateBoolean } = __nccwpck_require__(46827) +const { Promise, PromisePrototypeThen, SymbolDispose } = __nccwpck_require__(95512) const { isClosed, isReadable, @@ -32969,7 +33747,7 @@ const { isNodeStream, willEmitClose: _willEmitClose, kIsClosedPromise -} = __nccwpck_require__(83426) +} = __nccwpck_require__(73289) let addAbortListener function isRequest(stream) { return stream.setHeader && typeof stream.abort === 'function' @@ -33155,7 +33933,7 @@ function eos(stream, options, callback) { if (options.signal.aborted) { process.nextTick(abort) } else { - addAbortListener = addAbortListener || (__nccwpck_require__(23539).addAbortListener) + addAbortListener = addAbortListener || (__nccwpck_require__(75806).addAbortListener) const disposable = addAbortListener(options.signal, abort) const originalCallback = callback callback = once((...args) => { @@ -33182,7 +33960,7 @@ function eosWeb(stream, options, callback) { if (options.signal.aborted) { process.nextTick(abort) } else { - addAbortListener = addAbortListener || (__nccwpck_require__(23539).addAbortListener) + addAbortListener = addAbortListener || (__nccwpck_require__(75806).addAbortListener) const disposable = addAbortListener(options.signal, abort) const originalCallback = callback callback = once((...args) => { @@ -33228,20 +34006,20 @@ module.exports.finished = finished /***/ }), -/***/ 4659: +/***/ 17806: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /* replacement start */ -const process = __nccwpck_require__(7945) +const process = __nccwpck_require__(50180) /* replacement end */ -const { PromisePrototypeThen, SymbolAsyncIterator, SymbolIterator } = __nccwpck_require__(50999) +const { PromisePrototypeThen, SymbolAsyncIterator, SymbolIterator } = __nccwpck_require__(95512) const { Buffer } = __nccwpck_require__(20181) -const { ERR_INVALID_ARG_TYPE, ERR_STREAM_NULL_VALUES } = (__nccwpck_require__(69220).codes) +const { ERR_INVALID_ARG_TYPE, ERR_STREAM_NULL_VALUES } = (__nccwpck_require__(79885).codes) function from(Readable, iterable, opts) { let iterator if (typeof iterable === 'string' || iterable instanceof Buffer) { @@ -33333,12 +34111,12 @@ module.exports = from /***/ }), -/***/ 84128: +/***/ 98321: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { ArrayIsArray, ObjectSetPrototypeOf } = __nccwpck_require__(50999) +const { ArrayIsArray, ObjectSetPrototypeOf } = __nccwpck_require__(95512) const { EventEmitter: EE } = __nccwpck_require__(24434) function Stream(opts) { EE.call(this, opts) @@ -33429,24 +34207,24 @@ module.exports = { /***/ }), -/***/ 11222: +/***/ 99509: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const AbortController = globalThis.AbortController || (__nccwpck_require__(17413).AbortController) +const AbortController = globalThis.AbortController || (__nccwpck_require__(19914).AbortController) const { codes: { ERR_INVALID_ARG_VALUE, ERR_INVALID_ARG_TYPE, ERR_MISSING_ARGS, ERR_OUT_OF_RANGE }, AbortError -} = __nccwpck_require__(69220) -const { validateAbortSignal, validateInteger, validateObject } = __nccwpck_require__(49554) -const kWeakHandler = (__nccwpck_require__(50999).Symbol)('kWeak') -const kResistStopPropagation = (__nccwpck_require__(50999).Symbol)('kResistStopPropagation') -const { finished } = __nccwpck_require__(36815) -const staticCompose = __nccwpck_require__(64999) -const { addAbortSignalNoValidate } = __nccwpck_require__(80652) -const { isWritable, isNodeStream } = __nccwpck_require__(83426) -const { deprecate } = __nccwpck_require__(23539) +} = __nccwpck_require__(79885) +const { validateAbortSignal, validateInteger, validateObject } = __nccwpck_require__(46827) +const kWeakHandler = (__nccwpck_require__(95512).Symbol)('kWeak') +const kResistStopPropagation = (__nccwpck_require__(95512).Symbol)('kResistStopPropagation') +const { finished } = __nccwpck_require__(44356) +const staticCompose = __nccwpck_require__(78256) +const { addAbortSignalNoValidate } = __nccwpck_require__(72105) +const { isWritable, isNodeStream } = __nccwpck_require__(73289) +const { deprecate } = __nccwpck_require__(75806) const { ArrayPrototypePush, Boolean, @@ -33458,7 +34236,7 @@ const { PromiseResolve, PromisePrototypeThen, Symbol -} = __nccwpck_require__(50999) +} = __nccwpck_require__(95512) const kEmpty = Symbol('kEmpty') const kEof = Symbol('kEof') function compose(stream, options) { @@ -33500,7 +34278,7 @@ function map(fn, options) { validateInteger(highWaterMark, 'options.highWaterMark', 0) highWaterMark += concurrency return async function* map() { - const signal = (__nccwpck_require__(23539).AbortSignalAny)( + const signal = (__nccwpck_require__(75806).AbortSignalAny)( [options === null || options === undefined ? undefined : options.signal].filter(Boolean) ) const stream = this @@ -33893,7 +34671,7 @@ module.exports.promiseReturningOperators = { /***/ }), -/***/ 19173: +/***/ 26578: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { // Copyright Joyent, Inc. and other Node contributors. @@ -33923,9 +34701,9 @@ module.exports.promiseReturningOperators = { -const { ObjectSetPrototypeOf } = __nccwpck_require__(50999) +const { ObjectSetPrototypeOf } = __nccwpck_require__(95512) module.exports = PassThrough -const Transform = __nccwpck_require__(12135) +const Transform = __nccwpck_require__(480) ObjectSetPrototypeOf(PassThrough.prototype, Transform.prototype) ObjectSetPrototypeOf(PassThrough, Transform) function PassThrough(options) { @@ -33939,23 +34717,23 @@ PassThrough.prototype._transform = function (chunk, encoding, cb) { /***/ }), -/***/ 16701: +/***/ 84712: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /* replacement start */ -const process = __nccwpck_require__(7945) +const process = __nccwpck_require__(50180) /* replacement end */ // Ported from https://github.com/mafintosh/pump with // permission from the author, Mathias Buus (@mafintosh). ;('use strict') -const { ArrayIsArray, Promise, SymbolAsyncIterator, SymbolDispose } = __nccwpck_require__(50999) -const eos = __nccwpck_require__(36815) -const { once } = __nccwpck_require__(23539) -const destroyImpl = __nccwpck_require__(65089) -const Duplex = __nccwpck_require__(94449) +const { ArrayIsArray, Promise, SymbolAsyncIterator, SymbolDispose } = __nccwpck_require__(95512) +const eos = __nccwpck_require__(44356) +const { once } = __nccwpck_require__(75806) +const destroyImpl = __nccwpck_require__(13822) +const Duplex = __nccwpck_require__(60400) const { aggregateTwoErrors, codes: { @@ -33966,8 +34744,8 @@ const { ERR_STREAM_PREMATURE_CLOSE }, AbortError -} = __nccwpck_require__(69220) -const { validateFunction, validateAbortSignal } = __nccwpck_require__(49554) +} = __nccwpck_require__(79885) +const { validateFunction, validateAbortSignal } = __nccwpck_require__(46827) const { isIterable, isReadable, @@ -33977,8 +34755,8 @@ const { isWebStream, isReadableStream, isReadableFinished -} = __nccwpck_require__(83426) -const AbortController = globalThis.AbortController || (__nccwpck_require__(17413).AbortController) +} = __nccwpck_require__(73289) +const AbortController = globalThis.AbortController || (__nccwpck_require__(19914).AbortController) let PassThrough let Readable let addAbortListener @@ -34024,7 +34802,7 @@ function makeAsyncIterable(val) { } async function* fromReadable(val) { if (!Readable) { - Readable = __nccwpck_require__(17783) + Readable = __nccwpck_require__(406) } yield* Readable.prototype[SymbolAsyncIterator].call(val) } @@ -34130,7 +34908,7 @@ function pipelineImpl(streams, callback, opts) { function abort() { finishImpl(new AbortError()) } - addAbortListener = addAbortListener || (__nccwpck_require__(23539).addAbortListener) + addAbortListener = addAbortListener || (__nccwpck_require__(75806).addAbortListener) let disposable if (outerSignal) { disposable = addAbortListener(outerSignal, abort) @@ -34221,7 +34999,7 @@ function pipelineImpl(streams, callback, opts) { } else { var _ret2 if (!PassThrough) { - PassThrough = __nccwpck_require__(19173) + PassThrough = __nccwpck_require__(26578) } // If the last argument to pipeline is not a stream @@ -34417,7 +35195,7 @@ module.exports = { /***/ }), -/***/ 17783: +/***/ 406: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { // Copyright Joyent, Inc. and other Node contributors. @@ -34445,7 +35223,7 @@ module.exports = { /* replacement start */ -const process = __nccwpck_require__(7945) +const process = __nccwpck_require__(50180) /* replacement end */ @@ -34462,20 +35240,20 @@ const { SymbolAsyncDispose, SymbolAsyncIterator, Symbol -} = __nccwpck_require__(50999) +} = __nccwpck_require__(95512) module.exports = Readable Readable.ReadableState = ReadableState const { EventEmitter: EE } = __nccwpck_require__(24434) -const { Stream, prependListener } = __nccwpck_require__(84128) +const { Stream, prependListener } = __nccwpck_require__(98321) const { Buffer } = __nccwpck_require__(20181) -const { addAbortSignal } = __nccwpck_require__(80652) -const eos = __nccwpck_require__(36815) -let debug = (__nccwpck_require__(23539).debuglog)('stream', (fn) => { +const { addAbortSignal } = __nccwpck_require__(72105) +const eos = __nccwpck_require__(44356) +let debug = (__nccwpck_require__(75806).debuglog)('stream', (fn) => { debug = fn }) -const BufferList = __nccwpck_require__(77336) -const destroyImpl = __nccwpck_require__(65089) -const { getHighWaterMark, getDefaultHighWaterMark } = __nccwpck_require__(54874) +const BufferList = __nccwpck_require__(21195) +const destroyImpl = __nccwpck_require__(13822) +const { getHighWaterMark, getDefaultHighWaterMark } = __nccwpck_require__(25873) const { aggregateTwoErrors, codes: { @@ -34486,11 +35264,11 @@ const { ERR_STREAM_UNSHIFT_AFTER_END_EVENT }, AbortError -} = __nccwpck_require__(69220) -const { validateObject } = __nccwpck_require__(49554) +} = __nccwpck_require__(79885) +const { validateObject } = __nccwpck_require__(46827) const kPaused = Symbol('kPaused') -const { StringDecoder } = __nccwpck_require__(80634) -const from = __nccwpck_require__(4659) +const { StringDecoder } = __nccwpck_require__(93243) +const from = __nccwpck_require__(17806) ObjectSetPrototypeOf(Readable.prototype, Stream.prototype) ObjectSetPrototypeOf(Readable, Stream) const nop = () => {} @@ -34571,7 +35349,7 @@ function ReadableState(options, stream, isDuplex) { // However, some cases require setting options to different // values for the readable and the writable sides of the duplex stream. // These options can be provided separately as readableXXX and writableXXX. - if (typeof isDuplex !== 'boolean') isDuplex = stream instanceof __nccwpck_require__(94449) + if (typeof isDuplex !== 'boolean') isDuplex = stream instanceof __nccwpck_require__(60400) // Bit map field to store ReadableState more effciently with 1 bit per field // instead of a V8 slot per field. @@ -34628,7 +35406,7 @@ function Readable(options) { // Checking for a Stream.Duplex instance is faster here instead of inside // the ReadableState constructor, at least with V8 6.5. - const isDuplex = this instanceof __nccwpck_require__(94449) + const isDuplex = this instanceof __nccwpck_require__(60400) this._readableState = new ReadableState(options, this, isDuplex) if (options) { if (typeof options.read === 'function') this._read = options.read @@ -35714,14 +36492,14 @@ Readable.wrap = function (src, options) { /***/ }), -/***/ 54874: +/***/ 25873: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { MathFloor, NumberIsInteger } = __nccwpck_require__(50999) -const { validateInteger } = __nccwpck_require__(49554) -const { ERR_INVALID_ARG_VALUE } = (__nccwpck_require__(69220).codes) +const { MathFloor, NumberIsInteger } = __nccwpck_require__(95512) +const { validateInteger } = __nccwpck_require__(46827) +const { ERR_INVALID_ARG_VALUE } = (__nccwpck_require__(79885).codes) let defaultHighWaterMarkBytes = 16 * 1024 let defaultHighWaterMarkObjectMode = 16 function highWaterMarkFrom(options, isDuplex, duplexKey) { @@ -35760,7 +36538,7 @@ module.exports = { /***/ }), -/***/ 12135: +/***/ 480: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { // Copyright Joyent, Inc. and other Node contributors. @@ -35828,11 +36606,11 @@ module.exports = { -const { ObjectSetPrototypeOf, Symbol } = __nccwpck_require__(50999) +const { ObjectSetPrototypeOf, Symbol } = __nccwpck_require__(95512) module.exports = Transform -const { ERR_METHOD_NOT_IMPLEMENTED } = (__nccwpck_require__(69220).codes) -const Duplex = __nccwpck_require__(94449) -const { getHighWaterMark } = __nccwpck_require__(54874) +const { ERR_METHOD_NOT_IMPLEMENTED } = (__nccwpck_require__(79885).codes) +const Duplex = __nccwpck_require__(60400) +const { getHighWaterMark } = __nccwpck_require__(25873) ObjectSetPrototypeOf(Transform.prototype, Duplex.prototype) ObjectSetPrototypeOf(Transform, Duplex) const kCallback = Symbol('kCallback') @@ -35947,12 +36725,12 @@ Transform.prototype._read = function () { /***/ }), -/***/ 83426: +/***/ 73289: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { SymbolAsyncIterator, SymbolIterator, SymbolFor } = __nccwpck_require__(50999) +const { SymbolAsyncIterator, SymbolIterator, SymbolFor } = __nccwpck_require__(95512) // We need to use SymbolFor to make these globally available // for interopt with readable-stream, i.e. readable-stream @@ -36281,7 +37059,7 @@ module.exports = { /***/ }), -/***/ 58939: +/***/ 34234: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { // Copyright Joyent, Inc. and other Node contributors. @@ -36313,7 +37091,7 @@ module.exports = { /* replacement start */ -const process = __nccwpck_require__(7945) +const process = __nccwpck_require__(50180) /* replacement end */ @@ -36327,15 +37105,15 @@ const { StringPrototypeToLowerCase, Symbol, SymbolHasInstance -} = __nccwpck_require__(50999) +} = __nccwpck_require__(95512) module.exports = Writable Writable.WritableState = WritableState const { EventEmitter: EE } = __nccwpck_require__(24434) -const Stream = (__nccwpck_require__(84128).Stream) +const Stream = (__nccwpck_require__(98321).Stream) const { Buffer } = __nccwpck_require__(20181) -const destroyImpl = __nccwpck_require__(65089) -const { addAbortSignal } = __nccwpck_require__(80652) -const { getHighWaterMark, getDefaultHighWaterMark } = __nccwpck_require__(54874) +const destroyImpl = __nccwpck_require__(13822) +const { addAbortSignal } = __nccwpck_require__(72105) +const { getHighWaterMark, getDefaultHighWaterMark } = __nccwpck_require__(25873) const { ERR_INVALID_ARG_TYPE, ERR_METHOD_NOT_IMPLEMENTED, @@ -36346,7 +37124,7 @@ const { ERR_STREAM_NULL_VALUES, ERR_STREAM_WRITE_AFTER_END, ERR_UNKNOWN_ENCODING -} = (__nccwpck_require__(69220).codes) +} = (__nccwpck_require__(79885).codes) const { errorOrDestroy } = destroyImpl ObjectSetPrototypeOf(Writable.prototype, Stream.prototype) ObjectSetPrototypeOf(Writable, Stream) @@ -36358,7 +37136,7 @@ function WritableState(options, stream, isDuplex) { // However, some cases require setting options to different // values for the readable and the writable sides of the duplex stream, // e.g. options.readableObjectMode vs. options.writableObjectMode, etc. - if (typeof isDuplex !== 'boolean') isDuplex = stream instanceof __nccwpck_require__(94449) + if (typeof isDuplex !== 'boolean') isDuplex = stream instanceof __nccwpck_require__(60400) // Object stream flag to indicate whether or not this stream // contains buffers or objects. @@ -36496,7 +37274,7 @@ function Writable(options) { // Checking for a Stream.Duplex instance is faster here instead of inside // the WritableState constructor, at least with V8 6.5. - const isDuplex = this instanceof __nccwpck_require__(94449) + const isDuplex = this instanceof __nccwpck_require__(60400) if (!isDuplex && !FunctionPrototypeSymbolHasInstance(Writable, this)) return new Writable(options) this._writableState = new WritableState(options, this, isDuplex) if (options) { @@ -37107,7 +37885,7 @@ Writable.toWeb = function (streamWritable) { /***/ }), -/***/ 49554: +/***/ 46827: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { /* eslint jsdoc/require-jsdoc: "error" */ @@ -37129,13 +37907,13 @@ const { String, StringPrototypeToUpperCase, StringPrototypeTrim -} = __nccwpck_require__(50999) +} = __nccwpck_require__(95512) const { hideStackFrames, codes: { ERR_SOCKET_BAD_PORT, ERR_INVALID_ARG_TYPE, ERR_INVALID_ARG_VALUE, ERR_OUT_OF_RANGE, ERR_UNKNOWN_SIGNAL } -} = __nccwpck_require__(69220) -const { normalizeEncoding } = __nccwpck_require__(23539) -const { isAsyncFunction, isArrayBufferView } = (__nccwpck_require__(23539).types) +} = __nccwpck_require__(79885) +const { normalizeEncoding } = __nccwpck_require__(75806) +const { isAsyncFunction, isArrayBufferView } = (__nccwpck_require__(75806).types) const signals = {} /** @@ -37644,13 +38422,13 @@ module.exports = { /***/ }), -/***/ 69220: +/***/ 79885: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { format, inspect } = __nccwpck_require__(43536) -const { AggregateError: CustomAggregateError } = __nccwpck_require__(50999) +const { format, inspect } = __nccwpck_require__(73293) +const { AggregateError: CustomAggregateError } = __nccwpck_require__(95512) /* This file is a reduced and adapted version of the main lib/internal/errors.js file defined at @@ -37994,7 +38772,7 @@ module.exports = { /***/ }), -/***/ 29963: +/***/ 48924: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { @@ -38028,8 +38806,8 @@ if (Stream && process.env.READABLE_STREAM === 'disable') { }) module.exports.Stream = Stream.Stream } else { - const CustomStream = __nccwpck_require__(12375) - const promises = __nccwpck_require__(65904) + const CustomStream = __nccwpck_require__(89204) + const promises = __nccwpck_require__(3161) const originalDestroy = CustomStream.Readable.destroy module.exports = CustomStream.Readable @@ -38066,7 +38844,7 @@ module.exports["default"] = module.exports /***/ }), -/***/ 50999: +/***/ 95512: /***/ ((module) => { @@ -38197,19 +38975,19 @@ module.exports = { /***/ }), -/***/ 23539: +/***/ 75806: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { const bufferModule = __nccwpck_require__(20181) -const { format, inspect } = __nccwpck_require__(43536) +const { format, inspect } = __nccwpck_require__(73293) const { codes: { ERR_INVALID_ARG_TYPE } -} = __nccwpck_require__(69220) -const { kResistStopPropagation, AggregateError, SymbolDispose } = __nccwpck_require__(50999) -const AbortSignal = globalThis.AbortSignal || (__nccwpck_require__(17413).AbortSignal) -const AbortController = globalThis.AbortController || (__nccwpck_require__(17413).AbortController) +} = __nccwpck_require__(79885) +const { kResistStopPropagation, AggregateError, SymbolDispose } = __nccwpck_require__(95512) +const AbortSignal = globalThis.AbortSignal || (__nccwpck_require__(19914).AbortSignal) +const AbortController = globalThis.AbortController || (__nccwpck_require__(19914).AbortController) const AsyncFunction = Object.getPrototypeOf(async function () {}).constructor const Blob = globalThis.Blob || bufferModule.Blob /* eslint-disable indent */ @@ -38343,1489 +39121,596 @@ module.exports = { { once: true } - ) - return ac.signal - } -} -module.exports.promisify.custom = Symbol.for('nodejs.util.promisify.custom') - - -/***/ }), - -/***/ 43536: -/***/ ((module) => { - - - -/* - This file is a reduced and adapted version of the main lib/internal/util/inspect.js file defined at - - https://github.com/nodejs/node/blob/main/lib/internal/util/inspect.js - - Don't try to replace with the original file and keep it up to date with the upstream file. -*/ -module.exports = { - format(format, ...args) { - // Simplified version of https://nodejs.org/api/util.html#utilformatformat-args - return format.replace(/%([sdifj])/g, function (...[_unused, type]) { - const replacement = args.shift() - if (type === 'f') { - return replacement.toFixed(6) - } else if (type === 'j') { - return JSON.stringify(replacement) - } else if (type === 's' && typeof replacement === 'object') { - const ctor = replacement.constructor !== Object ? replacement.constructor.name : '' - return `${ctor} {}`.trim() - } else { - return replacement.toString() - } - }) - }, - inspect(value) { - // Vastly simplified version of https://nodejs.org/api/util.html#utilinspectobject-options - switch (typeof value) { - case 'string': - if (value.includes("'")) { - if (!value.includes('"')) { - return `"${value}"` - } else if (!value.includes('`') && !value.includes('${')) { - return `\`${value}\`` - } - } - return `'${value}'` - case 'number': - if (isNaN(value)) { - return 'NaN' - } else if (Object.is(value, -0)) { - return String(value) - } - return value - case 'bigint': - return `${String(value)}n` - case 'boolean': - case 'undefined': - return String(value) - case 'object': - return '{}' - } - } -} - - -/***/ }), - -/***/ 12375: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - -// Copyright Joyent, Inc. and other Node contributors. -// -// Permission is hereby granted, free of charge, to any person obtaining a -// copy of this software and associated documentation files (the -// "Software"), to deal in the Software without restriction, including -// without limitation the rights to use, copy, modify, merge, publish, -// distribute, sublicense, and/or sell copies of the Software, and to permit -// persons to whom the Software is furnished to do so, subject to the -// following conditions: -// -// The above copyright notice and this permission notice shall be included -// in all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN -// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE -// USE OR OTHER DEALINGS IN THE SOFTWARE. - - - -/* replacement start */ - -const { Buffer } = __nccwpck_require__(20181) - -/* replacement end */ - -const { ObjectDefineProperty, ObjectKeys, ReflectApply } = __nccwpck_require__(50999) -const { - promisify: { custom: customPromisify } -} = __nccwpck_require__(23539) -const { streamReturningOperators, promiseReturningOperators } = __nccwpck_require__(11222) -const { - codes: { ERR_ILLEGAL_CONSTRUCTOR } -} = __nccwpck_require__(69220) -const compose = __nccwpck_require__(64999) -const { setDefaultHighWaterMark, getDefaultHighWaterMark } = __nccwpck_require__(54874) -const { pipeline } = __nccwpck_require__(16701) -const { destroyer } = __nccwpck_require__(65089) -const eos = __nccwpck_require__(36815) -const internalBuffer = {} -const promises = __nccwpck_require__(65904) -const utils = __nccwpck_require__(83426) -const Stream = (module.exports = __nccwpck_require__(84128).Stream) -Stream.isDestroyed = utils.isDestroyed -Stream.isDisturbed = utils.isDisturbed -Stream.isErrored = utils.isErrored -Stream.isReadable = utils.isReadable -Stream.isWritable = utils.isWritable -Stream.Readable = __nccwpck_require__(17783) -for (const key of ObjectKeys(streamReturningOperators)) { - const op = streamReturningOperators[key] - function fn(...args) { - if (new.target) { - throw ERR_ILLEGAL_CONSTRUCTOR() - } - return Stream.Readable.from(ReflectApply(op, this, args)) - } - ObjectDefineProperty(fn, 'name', { - __proto__: null, - value: op.name - }) - ObjectDefineProperty(fn, 'length', { - __proto__: null, - value: op.length - }) - ObjectDefineProperty(Stream.Readable.prototype, key, { - __proto__: null, - value: fn, - enumerable: false, - configurable: true, - writable: true - }) -} -for (const key of ObjectKeys(promiseReturningOperators)) { - const op = promiseReturningOperators[key] - function fn(...args) { - if (new.target) { - throw ERR_ILLEGAL_CONSTRUCTOR() - } - return ReflectApply(op, this, args) - } - ObjectDefineProperty(fn, 'name', { - __proto__: null, - value: op.name - }) - ObjectDefineProperty(fn, 'length', { - __proto__: null, - value: op.length - }) - ObjectDefineProperty(Stream.Readable.prototype, key, { - __proto__: null, - value: fn, - enumerable: false, - configurable: true, - writable: true - }) -} -Stream.Writable = __nccwpck_require__(58939) -Stream.Duplex = __nccwpck_require__(94449) -Stream.Transform = __nccwpck_require__(12135) -Stream.PassThrough = __nccwpck_require__(19173) -Stream.pipeline = pipeline -const { addAbortSignal } = __nccwpck_require__(80652) -Stream.addAbortSignal = addAbortSignal -Stream.finished = eos -Stream.destroy = destroyer -Stream.compose = compose -Stream.setDefaultHighWaterMark = setDefaultHighWaterMark -Stream.getDefaultHighWaterMark = getDefaultHighWaterMark -ObjectDefineProperty(Stream, 'promises', { - __proto__: null, - configurable: true, - enumerable: true, - get() { - return promises - } -}) -ObjectDefineProperty(pipeline, customPromisify, { - __proto__: null, - enumerable: true, - get() { - return promises.pipeline - } -}) -ObjectDefineProperty(eos, customPromisify, { - __proto__: null, - enumerable: true, - get() { - return promises.finished - } -}) - -// Backwards-compat with node 0.4.x -Stream.Stream = Stream -Stream._isUint8Array = function isUint8Array(value) { - return value instanceof Uint8Array -} -Stream._uint8ArrayToBuffer = function _uint8ArrayToBuffer(chunk) { - return Buffer.from(chunk.buffer, chunk.byteOffset, chunk.byteLength) -} - - -/***/ }), - -/***/ 65904: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - - - -const { ArrayPrototypePop, Promise } = __nccwpck_require__(50999) -const { isIterable, isNodeStream, isWebStream } = __nccwpck_require__(83426) -const { pipelineImpl: pl } = __nccwpck_require__(16701) -const { finished } = __nccwpck_require__(36815) -__nccwpck_require__(12375) -function pipeline(...streams) { - return new Promise((resolve, reject) => { - let signal - let end - const lastArg = streams[streams.length - 1] - if ( - lastArg && - typeof lastArg === 'object' && - !isNodeStream(lastArg) && - !isIterable(lastArg) && - !isWebStream(lastArg) - ) { - const options = ArrayPrototypePop(streams) - signal = options.signal - end = options.end - } - pl( - streams, - (err, value) => { - if (err) { - reject(err) - } else { - resolve(value) - } - }, - { - signal, - end - } - ) - }) -} -module.exports = { - finished, - pipeline -} - - -/***/ }), - -/***/ 51364: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - -module.exports = readdirGlob; - -const fs = __nccwpck_require__(79896); -const { EventEmitter } = __nccwpck_require__(24434); -const { Minimatch } = __nccwpck_require__(6944); -const { resolve } = __nccwpck_require__(16928); - -function readdir(dir, strict) { - return new Promise((resolve, reject) => { - fs.readdir(dir, {withFileTypes: true} ,(err, files) => { - if(err) { - switch (err.code) { - case 'ENOTDIR': // Not a directory - if(strict) { - reject(err); - } else { - resolve([]); - } - break; - case 'ENOTSUP': // Operation not supported - case 'ENOENT': // No such file or directory - case 'ENAMETOOLONG': // Filename too long - case 'UNKNOWN': - resolve([]); - break; - case 'ELOOP': // Too many levels of symbolic links - default: - reject(err); - break; - } - } else { - resolve(files); - } - }); - }); -} -function stat(file, followSymlinks) { - return new Promise((resolve, reject) => { - const statFunc = followSymlinks ? fs.stat : fs.lstat; - statFunc(file, (err, stats) => { - if(err) { - switch (err.code) { - case 'ENOENT': - if(followSymlinks) { - // Fallback to lstat to handle broken links as files - resolve(stat(file, false)); - } else { - resolve(null); - } - break; - default: - resolve(null); - break; - } - } else { - resolve(stats); - } - }); - }); -} - -async function* exploreWalkAsync(dir, path, followSymlinks, useStat, shouldSkip, strict) { - let files = await readdir(path + dir, strict); - for(const file of files) { - let name = file.name; - if(name === undefined) { - // undefined file.name means the `withFileTypes` options is not supported by node - // we have to call the stat function to know if file is directory or not. - name = file; - useStat = true; - } - const filename = dir + '/' + name; - const relative = filename.slice(1); // Remove the leading / - const absolute = path + '/' + relative; - let stats = null; - if(useStat || followSymlinks) { - stats = await stat(absolute, followSymlinks); - } - if(!stats && file.name !== undefined) { - stats = file; - } - if(stats === null) { - stats = { isDirectory: () => false }; - } - - if(stats.isDirectory()) { - if(!shouldSkip(relative)) { - yield {relative, absolute, stats}; - yield* exploreWalkAsync(filename, path, followSymlinks, useStat, shouldSkip, false); - } - } else { - yield {relative, absolute, stats}; - } - } -} -async function* explore(path, followSymlinks, useStat, shouldSkip) { - yield* exploreWalkAsync('', path, followSymlinks, useStat, shouldSkip, true); -} - - -function readOptions(options) { - return { - pattern: options.pattern, - dot: !!options.dot, - noglobstar: !!options.noglobstar, - matchBase: !!options.matchBase, - nocase: !!options.nocase, - ignore: options.ignore, - skip: options.skip, - - follow: !!options.follow, - stat: !!options.stat, - nodir: !!options.nodir, - mark: !!options.mark, - silent: !!options.silent, - absolute: !!options.absolute - }; -} - -class ReaddirGlob extends EventEmitter { - constructor(cwd, options, cb) { - super(); - if(typeof options === 'function') { - cb = options; - options = null; - } - - this.options = readOptions(options || {}); - - this.matchers = []; - if(this.options.pattern) { - const matchers = Array.isArray(this.options.pattern) ? this.options.pattern : [this.options.pattern]; - this.matchers = matchers.map( m => - new Minimatch(m, { - dot: this.options.dot, - noglobstar:this.options.noglobstar, - matchBase:this.options.matchBase, - nocase:this.options.nocase - }) - ); - } - - this.ignoreMatchers = []; - if(this.options.ignore) { - const ignorePatterns = Array.isArray(this.options.ignore) ? this.options.ignore : [this.options.ignore]; - this.ignoreMatchers = ignorePatterns.map( ignore => - new Minimatch(ignore, {dot: true}) - ); - } - - this.skipMatchers = []; - if(this.options.skip) { - const skipPatterns = Array.isArray(this.options.skip) ? this.options.skip : [this.options.skip]; - this.skipMatchers = skipPatterns.map( skip => - new Minimatch(skip, {dot: true}) - ); - } - - this.iterator = explore(resolve(cwd || '.'), this.options.follow, this.options.stat, this._shouldSkipDirectory.bind(this)); - this.paused = false; - this.inactive = false; - this.aborted = false; - - if(cb) { - this._matches = []; - this.on('match', match => this._matches.push(this.options.absolute ? match.absolute : match.relative)); - this.on('error', err => cb(err)); - this.on('end', () => cb(null, this._matches)); - } - - setTimeout( () => this._next(), 0); - } - - _shouldSkipDirectory(relative) { - //console.log(relative, this.skipMatchers.some(m => m.match(relative))); - return this.skipMatchers.some(m => m.match(relative)); - } - - _fileMatches(relative, isDirectory) { - const file = relative + (isDirectory ? '/' : ''); - return (this.matchers.length === 0 || this.matchers.some(m => m.match(file))) - && !this.ignoreMatchers.some(m => m.match(file)) - && (!this.options.nodir || !isDirectory); - } - - _next() { - if(!this.paused && !this.aborted) { - this.iterator.next() - .then((obj)=> { - if(!obj.done) { - const isDirectory = obj.value.stats.isDirectory(); - if(this._fileMatches(obj.value.relative, isDirectory )) { - let relative = obj.value.relative; - let absolute = obj.value.absolute; - if(this.options.mark && isDirectory) { - relative += '/'; - absolute += '/'; - } - if(this.options.stat) { - this.emit('match', {relative, absolute, stat:obj.value.stats}); - } else { - this.emit('match', {relative, absolute}); - } - } - this._next(this.iterator); - } else { - this.emit('end'); - } - }) - .catch((err) => { - this.abort(); - this.emit('error', err); - if(!err.code && !this.options.silent) { - console.error(err); - } - }); - } else { - this.inactive = true; - } - } - - abort() { - this.aborted = true; - } - - pause() { - this.paused = true; - } - - resume() { - this.paused = false; - if(this.inactive) { - this.inactive = false; - this._next(); - } - } -} - - -function readdirGlob(pattern, options, cb) { - return new ReaddirGlob(pattern, options, cb); -} -readdirGlob.ReaddirGlob = ReaddirGlob; - -/***/ }), - -/***/ 63669: -/***/ ((module) => { - -const isWindows = typeof process === 'object' && - process && - process.platform === 'win32' -module.exports = isWindows ? { sep: '\\' } : { sep: '/' } - - -/***/ }), - -/***/ 6944: -/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - -const minimatch = module.exports = (p, pattern, options = {}) => { - assertValidPattern(pattern) - - // shortcut: comments match nothing. - if (!options.nocomment && pattern.charAt(0) === '#') { - return false - } - - return new Minimatch(pattern, options).match(p) -} - -module.exports = minimatch - -const path = __nccwpck_require__(63669) -minimatch.sep = path.sep - -const GLOBSTAR = Symbol('globstar **') -minimatch.GLOBSTAR = GLOBSTAR -const expand = __nccwpck_require__(94691) - -const plTypes = { - '!': { open: '(?:(?!(?:', close: '))[^/]*?)'}, - '?': { open: '(?:', close: ')?' }, - '+': { open: '(?:', close: ')+' }, - '*': { open: '(?:', close: ')*' }, - '@': { open: '(?:', close: ')' } -} - -// any single thing other than / -// don't need to escape / when using new RegExp() -const qmark = '[^/]' - -// * => any number of characters -const star = qmark + '*?' - -// ** when dots are allowed. Anything goes, except .. and . -// not (^ or / followed by one or two dots followed by $ or /), -// followed by anything, any number of times. -const twoStarDot = '(?:(?!(?:\\\/|^)(?:\\.{1,2})($|\\\/)).)*?' - -// not a ^ or / followed by a dot, -// followed by anything, any number of times. -const twoStarNoDot = '(?:(?!(?:\\\/|^)\\.).)*?' - -// "abc" -> { a:true, b:true, c:true } -const charSet = s => s.split('').reduce((set, c) => { - set[c] = true - return set -}, {}) - -// characters that need to be escaped in RegExp. -const reSpecials = charSet('().*{}+?[]^$\\!') - -// characters that indicate we have to add the pattern start -const addPatternStartSet = charSet('[.(') - -// normalizes slashes. -const slashSplit = /\/+/ - -minimatch.filter = (pattern, options = {}) => - (p, i, list) => minimatch(p, pattern, options) - -const ext = (a, b = {}) => { - const t = {} - Object.keys(a).forEach(k => t[k] = a[k]) - Object.keys(b).forEach(k => t[k] = b[k]) - return t -} - -minimatch.defaults = def => { - if (!def || typeof def !== 'object' || !Object.keys(def).length) { - return minimatch - } - - const orig = minimatch - - const m = (p, pattern, options) => orig(p, pattern, ext(def, options)) - m.Minimatch = class Minimatch extends orig.Minimatch { - constructor (pattern, options) { - super(pattern, ext(def, options)) - } - } - m.Minimatch.defaults = options => orig.defaults(ext(def, options)).Minimatch - m.filter = (pattern, options) => orig.filter(pattern, ext(def, options)) - m.defaults = options => orig.defaults(ext(def, options)) - m.makeRe = (pattern, options) => orig.makeRe(pattern, ext(def, options)) - m.braceExpand = (pattern, options) => orig.braceExpand(pattern, ext(def, options)) - m.match = (list, pattern, options) => orig.match(list, pattern, ext(def, options)) - - return m -} - - - - - -// Brace expansion: -// a{b,c}d -> abd acd -// a{b,}c -> abc ac -// a{0..3}d -> a0d a1d a2d a3d -// a{b,c{d,e}f}g -> abg acdfg acefg -// a{b,c}d{e,f}g -> abdeg acdeg abdeg abdfg -// -// Invalid sets are not expanded. -// a{2..}b -> a{2..}b -// a{b}c -> a{b}c -minimatch.braceExpand = (pattern, options) => braceExpand(pattern, options) - -const braceExpand = (pattern, options = {}) => { - assertValidPattern(pattern) - - // Thanks to Yeting Li for - // improving this regexp to avoid a ReDOS vulnerability. - if (options.nobrace || !/\{(?:(?!\{).)*\}/.test(pattern)) { - // shortcut. no need to expand. - return [pattern] - } - - return expand(pattern) -} - -const MAX_PATTERN_LENGTH = 1024 * 64 -const assertValidPattern = pattern => { - if (typeof pattern !== 'string') { - throw new TypeError('invalid pattern') - } - - if (pattern.length > MAX_PATTERN_LENGTH) { - throw new TypeError('pattern is too long') - } -} - -// parse a component of the expanded set. -// At this point, no pattern may contain "/" in it -// so we're going to return a 2d array, where each entry is the full -// pattern, split on '/', and then turned into a regular expression. -// A regexp is made at the end which joins each array with an -// escaped /, and another full one which joins each regexp with |. -// -// Following the lead of Bash 4.1, note that "**" only has special meaning -// when it is the *only* thing in a path portion. Otherwise, any series -// of * is equivalent to a single *. Globstar behavior is enabled by -// default, and can be disabled by setting options.noglobstar. -const SUBPARSE = Symbol('subparse') - -minimatch.makeRe = (pattern, options) => - new Minimatch(pattern, options || {}).makeRe() - -minimatch.match = (list, pattern, options = {}) => { - const mm = new Minimatch(pattern, options) - list = list.filter(f => mm.match(f)) - if (mm.options.nonull && !list.length) { - list.push(pattern) - } - return list -} - -// replace stuff like \* with * -const globUnescape = s => s.replace(/\\(.)/g, '$1') -const charUnescape = s => s.replace(/\\([^-\]])/g, '$1') -const regExpEscape = s => s.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, '\\$&') -const braExpEscape = s => s.replace(/[[\]\\]/g, '\\$&') - -class Minimatch { - constructor (pattern, options) { - assertValidPattern(pattern) - - if (!options) options = {} - - this.options = options - this.set = [] - this.pattern = pattern - this.windowsPathsNoEscape = !!options.windowsPathsNoEscape || - options.allowWindowsEscape === false - if (this.windowsPathsNoEscape) { - this.pattern = this.pattern.replace(/\\/g, '/') - } - this.regexp = null - this.negate = false - this.comment = false - this.empty = false - this.partial = !!options.partial - - // make the set of regexps etc. - this.make() - } - - debug () {} - - make () { - const pattern = this.pattern - const options = this.options - - // empty patterns and comments match nothing. - if (!options.nocomment && pattern.charAt(0) === '#') { - this.comment = true - return - } - if (!pattern) { - this.empty = true - return - } - - // step 1: figure out negation, etc. - this.parseNegate() - - // step 2: expand braces - let set = this.globSet = this.braceExpand() - - if (options.debug) this.debug = (...args) => console.error(...args) - - this.debug(this.pattern, set) - - // step 3: now we have a set, so turn each one into a series of path-portion - // matching patterns. - // These will be regexps, except in the case of "**", which is - // set to the GLOBSTAR object for globstar behavior, - // and will not contain any / characters - set = this.globParts = set.map(s => s.split(slashSplit)) - - this.debug(this.pattern, set) - - // glob --> regexps - set = set.map((s, si, set) => s.map(this.parse, this)) - - this.debug(this.pattern, set) - - // filter out everything that didn't compile properly. - set = set.filter(s => s.indexOf(false) === -1) - - this.debug(this.pattern, set) - - this.set = set - } - - parseNegate () { - if (this.options.nonegate) return - - const pattern = this.pattern - let negate = false - let negateOffset = 0 - - for (let i = 0; i < pattern.length && pattern.charAt(i) === '!'; i++) { - negate = !negate - negateOffset++ - } - - if (negateOffset) this.pattern = pattern.slice(negateOffset) - this.negate = negate - } - - // set partial to true to test if, for example, - // "/a/b" matches the start of "/*/b/*/d" - // Partial means, if you run out of file before you run - // out of pattern, then that's fine, as long as all - // the parts match. - matchOne (file, pattern, partial) { - var options = this.options - - this.debug('matchOne', - { 'this': this, file: file, pattern: pattern }) - - this.debug('matchOne', file.length, pattern.length) - - for (var fi = 0, - pi = 0, - fl = file.length, - pl = pattern.length - ; (fi < fl) && (pi < pl) - ; fi++, pi++) { - this.debug('matchOne loop') - var p = pattern[pi] - var f = file[fi] - - this.debug(pattern, p, f) - - // should be impossible. - // some invalid regexp stuff in the set. - /* istanbul ignore if */ - if (p === false) return false - - if (p === GLOBSTAR) { - this.debug('GLOBSTAR', [pattern, p, f]) - - // "**" - // a/**/b/**/c would match the following: - // a/b/x/y/z/c - // a/x/y/z/b/c - // a/b/x/b/x/c - // a/b/c - // To do this, take the rest of the pattern after - // the **, and see if it would match the file remainder. - // If so, return success. - // If not, the ** "swallows" a segment, and try again. - // This is recursively awful. - // - // a/**/b/**/c matching a/b/x/y/z/c - // - a matches a - // - doublestar - // - matchOne(b/x/y/z/c, b/**/c) - // - b matches b - // - doublestar - // - matchOne(x/y/z/c, c) -> no - // - matchOne(y/z/c, c) -> no - // - matchOne(z/c, c) -> no - // - matchOne(c, c) yes, hit - var fr = fi - var pr = pi + 1 - if (pr === pl) { - this.debug('** at the end') - // a ** at the end will just swallow the rest. - // We have found a match. - // however, it will not swallow /.x, unless - // options.dot is set. - // . and .. are *never* matched by **, for explosively - // exponential reasons. - for (; fi < fl; fi++) { - if (file[fi] === '.' || file[fi] === '..' || - (!options.dot && file[fi].charAt(0) === '.')) return false - } - return true - } - - // ok, let's see if we can swallow whatever we can. - while (fr < fl) { - var swallowee = file[fr] - - this.debug('\nglobstar while', file, fr, pattern, pr, swallowee) - - // XXX remove this slice. Just pass the start index. - if (this.matchOne(file.slice(fr), pattern.slice(pr), partial)) { - this.debug('globstar found match!', fr, fl, swallowee) - // found a match. - return true - } else { - // can't swallow "." or ".." ever. - // can only swallow ".foo" when explicitly asked. - if (swallowee === '.' || swallowee === '..' || - (!options.dot && swallowee.charAt(0) === '.')) { - this.debug('dot detected!', file, fr, pattern, pr) - break - } - - // ** swallows a segment, and continue. - this.debug('globstar swallow a segment, and continue') - fr++ - } - } - - // no match was found. - // However, in partial mode, we can't say this is necessarily over. - // If there's more *pattern* left, then - /* istanbul ignore if */ - if (partial) { - // ran out of file - this.debug('\n>>> no match, partial?', file, fr, pattern, pr) - if (fr === fl) return true - } - return false - } - - // something other than ** - // non-magic patterns just have to match exactly - // patterns with magic have been turned into regexps. - var hit - if (typeof p === 'string') { - hit = f === p - this.debug('string match', p, f, hit) - } else { - hit = f.match(p) - this.debug('pattern match', p, f, hit) - } - - if (!hit) return false - } - - // Note: ending in / means that we'll get a final "" - // at the end of the pattern. This can only match a - // corresponding "" at the end of the file. - // If the file ends in /, then it can only match a - // a pattern that ends in /, unless the pattern just - // doesn't have any more for it. But, a/b/ should *not* - // match "a/b/*", even though "" matches against the - // [^/]*? pattern, except in partial mode, where it might - // simply not be reached yet. - // However, a/b/ should still satisfy a/* - - // now either we fell off the end of the pattern, or we're done. - if (fi === fl && pi === pl) { - // ran out of pattern and filename at the same time. - // an exact hit! - return true - } else if (fi === fl) { - // ran out of file, but still had pattern left. - // this is ok if we're doing the match as part of - // a glob fs traversal. - return partial - } else /* istanbul ignore else */ if (pi === pl) { - // ran out of pattern, still have file left. - // this is only acceptable if we're on the very last - // empty segment of a file with a trailing slash. - // a/* should match a/b/ - return (fi === fl - 1) && (file[fi] === '') - } - - // should be unreachable. - /* istanbul ignore next */ - throw new Error('wtf?') - } - - braceExpand () { - return braceExpand(this.pattern, this.options) - } - - parse (pattern, isSub) { - assertValidPattern(pattern) - - const options = this.options - - // shortcuts - if (pattern === '**') { - if (!options.noglobstar) - return GLOBSTAR - else - pattern = '*' - } - if (pattern === '') return '' - - let re = '' - let hasMagic = false - let escaping = false - // ? => one single character - const patternListStack = [] - const negativeLists = [] - let stateChar - let inClass = false - let reClassStart = -1 - let classStart = -1 - let cs - let pl - let sp - // . and .. never match anything that doesn't start with ., - // even when options.dot is set. However, if the pattern - // starts with ., then traversal patterns can match. - let dotTravAllowed = pattern.charAt(0) === '.' - let dotFileAllowed = options.dot || dotTravAllowed - const patternStart = () => - dotTravAllowed - ? '' - : dotFileAllowed - ? '(?!(?:^|\\/)\\.{1,2}(?:$|\\/))' - : '(?!\\.)' - const subPatternStart = (p) => - p.charAt(0) === '.' - ? '' - : options.dot - ? '(?!(?:^|\\/)\\.{1,2}(?:$|\\/))' - : '(?!\\.)' - - - const clearStateChar = () => { - if (stateChar) { - // we had some state-tracking character - // that wasn't consumed by this pass. - switch (stateChar) { - case '*': - re += star - hasMagic = true - break - case '?': - re += qmark - hasMagic = true - break - default: - re += '\\' + stateChar - break - } - this.debug('clearStateChar %j %j', stateChar, re) - stateChar = false - } - } - - for (let i = 0, c; (i < pattern.length) && (c = pattern.charAt(i)); i++) { - this.debug('%s\t%s %s %j', pattern, i, re, c) - - // skip over any that are escaped. - if (escaping) { - /* istanbul ignore next - completely not allowed, even escaped. */ - if (c === '/') { - return false - } - - if (reSpecials[c]) { - re += '\\' - } - re += c - escaping = false - continue - } - - switch (c) { - /* istanbul ignore next */ - case '/': { - // Should already be path-split by now. - return false - } + ) + return ac.signal + } +} +module.exports.promisify.custom = Symbol.for('nodejs.util.promisify.custom') - case '\\': - if (inClass && pattern.charAt(i + 1) === '-') { - re += c - continue - } - clearStateChar() - escaping = true - continue +/***/ }), - // the various stateChar values - // for the "extglob" stuff. - case '?': - case '*': - case '+': - case '@': - case '!': - this.debug('%s\t%s %s %j <-- stateChar', pattern, i, re, c) +/***/ 73293: +/***/ ((module) => { - // all of those are literals inside a class, except that - // the glob [!a] means [^a] in regexp - if (inClass) { - this.debug(' in class') - if (c === '!' && i === classStart + 1) c = '^' - re += c - continue - } - // if we already have a stateChar, then it means - // that there was something like ** or +? in there. - // Handle the stateChar, then proceed with this one. - this.debug('call clearStateChar %j', stateChar) - clearStateChar() - stateChar = c - // if extglob is disabled, then +(asdf|foo) isn't a thing. - // just clear the statechar *now*, rather than even diving into - // the patternList stuff. - if (options.noext) clearStateChar() - continue - case '(': { - if (inClass) { - re += '(' - continue - } +/* + This file is a reduced and adapted version of the main lib/internal/util/inspect.js file defined at - if (!stateChar) { - re += '\\(' - continue - } + https://github.com/nodejs/node/blob/main/lib/internal/util/inspect.js - const plEntry = { - type: stateChar, - start: i - 1, - reStart: re.length, - open: plTypes[stateChar].open, - close: plTypes[stateChar].close, - } - this.debug(this.pattern, '\t', plEntry) - patternListStack.push(plEntry) - // negation is (?:(?!(?:js)(?:))[^/]*) - re += plEntry.open - // next entry starts with a dot maybe? - if (plEntry.start === 0 && plEntry.type !== '!') { - dotTravAllowed = true - re += subPatternStart(pattern.slice(i + 1)) + Don't try to replace with the original file and keep it up to date with the upstream file. +*/ +module.exports = { + format(format, ...args) { + // Simplified version of https://nodejs.org/api/util.html#utilformatformat-args + return format.replace(/%([sdifj])/g, function (...[_unused, type]) { + const replacement = args.shift() + if (type === 'f') { + return replacement.toFixed(6) + } else if (type === 'j') { + return JSON.stringify(replacement) + } else if (type === 's' && typeof replacement === 'object') { + const ctor = replacement.constructor !== Object ? replacement.constructor.name : '' + return `${ctor} {}`.trim() + } else { + return replacement.toString() + } + }) + }, + inspect(value) { + // Vastly simplified version of https://nodejs.org/api/util.html#utilinspectobject-options + switch (typeof value) { + case 'string': + if (value.includes("'")) { + if (!value.includes('"')) { + return `"${value}"` + } else if (!value.includes('`') && !value.includes('${')) { + return `\`${value}\`` } - this.debug('plType %j %j', stateChar, re) - stateChar = false - continue } - - case ')': { - const plEntry = patternListStack[patternListStack.length - 1] - if (inClass || !plEntry) { - re += '\\)' - continue - } - patternListStack.pop() - - // closing an extglob - clearStateChar() - hasMagic = true - pl = plEntry - // negation is (?:(?!js)[^/]*) - // The others are (?:) - re += pl.close - if (pl.type === '!') { - negativeLists.push(Object.assign(pl, { reEnd: re.length })) - } - continue + return `'${value}'` + case 'number': + if (isNaN(value)) { + return 'NaN' + } else if (Object.is(value, -0)) { + return String(value) } + return value + case 'bigint': + return `${String(value)}n` + case 'boolean': + case 'undefined': + return String(value) + case 'object': + return '{}' + } + } +} - case '|': { - const plEntry = patternListStack[patternListStack.length - 1] - if (inClass || !plEntry) { - re += '\\|' - continue - } - clearStateChar() - re += '|' - // next subpattern can start with a dot? - if (plEntry.start === 0 && plEntry.type !== '!') { - dotTravAllowed = true - re += subPatternStart(pattern.slice(i + 1)) - } - continue - } +/***/ }), - // these are mostly the same in regexp and glob - case '[': - // swallow any state-tracking char before the [ - clearStateChar() +/***/ 89204: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - if (inClass) { - re += '\\' + c - continue - } +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. - inClass = true - classStart = i - reClassStart = re.length - re += c - continue - case ']': - // a right bracket shall lose its special - // meaning and represent itself in - // a bracket expression if it occurs - // first in the list. -- POSIX.2 2.8.3.2 - if (i === classStart + 1 || !inClass) { - re += '\\' + c - continue - } - // split where the last [ was, make sure we don't have - // an invalid re. if so, re-walk the contents of the - // would-be class to re-translate any characters that - // were passed through as-is - // TODO: It would probably be faster to determine this - // without a try/catch and a new RegExp, but it's tricky - // to do safely. For now, this is safe and works. - cs = pattern.substring(classStart + 1, i) - try { - RegExp('[' + braExpEscape(charUnescape(cs)) + ']') - // looks good, finish up the class. - re += c - } catch (er) { - // out of order ranges in JS are errors, but in glob syntax, - // they're just a range that matches nothing. - re = re.substring(0, reClassStart) + '(?:$.)' // match nothing ever - } - hasMagic = true - inClass = false - continue +/* replacement start */ - default: - // swallow any state char that wasn't consumed - clearStateChar() +const { Buffer } = __nccwpck_require__(20181) - if (reSpecials[c] && !(c === '^' && inClass)) { - re += '\\' - } +/* replacement end */ - re += c - break +const { ObjectDefineProperty, ObjectKeys, ReflectApply } = __nccwpck_require__(95512) +const { + promisify: { custom: customPromisify } +} = __nccwpck_require__(75806) +const { streamReturningOperators, promiseReturningOperators } = __nccwpck_require__(99509) +const { + codes: { ERR_ILLEGAL_CONSTRUCTOR } +} = __nccwpck_require__(79885) +const compose = __nccwpck_require__(78256) +const { setDefaultHighWaterMark, getDefaultHighWaterMark } = __nccwpck_require__(25873) +const { pipeline } = __nccwpck_require__(84712) +const { destroyer } = __nccwpck_require__(13822) +const eos = __nccwpck_require__(44356) +const internalBuffer = {} +const promises = __nccwpck_require__(3161) +const utils = __nccwpck_require__(73289) +const Stream = (module.exports = __nccwpck_require__(98321).Stream) +Stream.isDestroyed = utils.isDestroyed +Stream.isDisturbed = utils.isDisturbed +Stream.isErrored = utils.isErrored +Stream.isReadable = utils.isReadable +Stream.isWritable = utils.isWritable +Stream.Readable = __nccwpck_require__(406) +for (const key of ObjectKeys(streamReturningOperators)) { + const op = streamReturningOperators[key] + function fn(...args) { + if (new.target) { + throw ERR_ILLEGAL_CONSTRUCTOR() + } + return Stream.Readable.from(ReflectApply(op, this, args)) + } + ObjectDefineProperty(fn, 'name', { + __proto__: null, + value: op.name + }) + ObjectDefineProperty(fn, 'length', { + __proto__: null, + value: op.length + }) + ObjectDefineProperty(Stream.Readable.prototype, key, { + __proto__: null, + value: fn, + enumerable: false, + configurable: true, + writable: true + }) +} +for (const key of ObjectKeys(promiseReturningOperators)) { + const op = promiseReturningOperators[key] + function fn(...args) { + if (new.target) { + throw ERR_ILLEGAL_CONSTRUCTOR() + } + return ReflectApply(op, this, args) + } + ObjectDefineProperty(fn, 'name', { + __proto__: null, + value: op.name + }) + ObjectDefineProperty(fn, 'length', { + __proto__: null, + value: op.length + }) + ObjectDefineProperty(Stream.Readable.prototype, key, { + __proto__: null, + value: fn, + enumerable: false, + configurable: true, + writable: true + }) +} +Stream.Writable = __nccwpck_require__(34234) +Stream.Duplex = __nccwpck_require__(60400) +Stream.Transform = __nccwpck_require__(480) +Stream.PassThrough = __nccwpck_require__(26578) +Stream.pipeline = pipeline +const { addAbortSignal } = __nccwpck_require__(72105) +Stream.addAbortSignal = addAbortSignal +Stream.finished = eos +Stream.destroy = destroyer +Stream.compose = compose +Stream.setDefaultHighWaterMark = setDefaultHighWaterMark +Stream.getDefaultHighWaterMark = getDefaultHighWaterMark +ObjectDefineProperty(Stream, 'promises', { + __proto__: null, + configurable: true, + enumerable: true, + get() { + return promises + } +}) +ObjectDefineProperty(pipeline, customPromisify, { + __proto__: null, + enumerable: true, + get() { + return promises.pipeline + } +}) +ObjectDefineProperty(eos, customPromisify, { + __proto__: null, + enumerable: true, + get() { + return promises.finished + } +}) - } // switch - } // for +// Backwards-compat with node 0.4.x +Stream.Stream = Stream +Stream._isUint8Array = function isUint8Array(value) { + return value instanceof Uint8Array +} +Stream._uint8ArrayToBuffer = function _uint8ArrayToBuffer(chunk) { + return Buffer.from(chunk.buffer, chunk.byteOffset, chunk.byteLength) +} - // handle the case where we left a class open. - // "[abc" is valid, equivalent to "\[abc" - if (inClass) { - // split where the last [ was, and escape it - // this is a huge pita. We now have to re-walk - // the contents of the would-be class to re-translate - // any characters that were passed through as-is - cs = pattern.slice(classStart + 1) - sp = this.parse(cs, SUBPARSE) - re = re.substring(0, reClassStart) + '\\[' + sp[0] - hasMagic = hasMagic || sp[1] - } - // handle the case where we had a +( thing at the *end* - // of the pattern. - // each pattern list stack adds 3 chars, and we need to go through - // and escape any | chars that were passed through as-is for the regexp. - // Go through and escape them, taking care not to double-escape any - // | chars that were already escaped. - for (pl = patternListStack.pop(); pl; pl = patternListStack.pop()) { - let tail - tail = re.slice(pl.reStart + pl.open.length) - this.debug('setting tail', re, pl) - // maybe some even number of \, then maybe 1 \, followed by a | - tail = tail.replace(/((?:\\{2}){0,64})(\\?)\|/g, (_, $1, $2) => { - /* istanbul ignore else - should already be done */ - if (!$2) { - // the | isn't already escaped, so escape it. - $2 = '\\' - } +/***/ }), - // need to escape all those slashes *again*, without escaping the - // one that we need for escaping the | character. As it works out, - // escaping an even number of slashes can be done by simply repeating - // it exactly after itself. That's why this trick works. - // - // I am sorry that you have to see this. - return $1 + $1 + $2 + '|' - }) +/***/ 3161: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - this.debug('tail=%j\n %s', tail, tail, pl, re) - const t = pl.type === '*' ? star - : pl.type === '?' ? qmark - : '\\' + pl.type - hasMagic = true - re = re.slice(0, pl.reStart) + t + '\\(' + tail - } - // handle trailing things that only matter at the very end. - clearStateChar() - if (escaping) { - // trailing \\ - re += '\\\\' +const { ArrayPrototypePop, Promise } = __nccwpck_require__(95512) +const { isIterable, isNodeStream, isWebStream } = __nccwpck_require__(73289) +const { pipelineImpl: pl } = __nccwpck_require__(84712) +const { finished } = __nccwpck_require__(44356) +__nccwpck_require__(89204) +function pipeline(...streams) { + return new Promise((resolve, reject) => { + let signal + let end + const lastArg = streams[streams.length - 1] + if ( + lastArg && + typeof lastArg === 'object' && + !isNodeStream(lastArg) && + !isIterable(lastArg) && + !isWebStream(lastArg) + ) { + const options = ArrayPrototypePop(streams) + signal = options.signal + end = options.end } + pl( + streams, + (err, value) => { + if (err) { + reject(err) + } else { + resolve(value) + } + }, + { + signal, + end + } + ) + }) +} +module.exports = { + finished, + pipeline +} - // only need to apply the nodot start if the re starts with - // something that could conceivably capture a dot - const addPatternStart = addPatternStartSet[re.charAt(0)] - // Hack to work around lack of negative lookbehind in JS - // A pattern like: *.!(x).!(y|z) needs to ensure that a name - // like 'a.xyz.yz' doesn't match. So, the first negative - // lookahead, has to look ALL the way ahead, to the end of - // the pattern. - for (let n = negativeLists.length - 1; n > -1; n--) { - const nl = negativeLists[n] +/***/ }), - const nlBefore = re.slice(0, nl.reStart) - const nlFirst = re.slice(nl.reStart, nl.reEnd - 8) - let nlAfter = re.slice(nl.reEnd) - const nlLast = re.slice(nl.reEnd - 8, nl.reEnd) + nlAfter +/***/ 15934: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { - // Handle nested stuff like *(*.js|!(*.json)), where open parens - // mean that we should *not* include the ) in the bit that is considered - // "after" the negated section. - const closeParensBefore = nlBefore.split(')').length - const openParensBefore = nlBefore.split('(').length - closeParensBefore - let cleanAfter = nlAfter - for (let i = 0; i < openParensBefore; i++) { - cleanAfter = cleanAfter.replace(/\)[+*?]?/, '') - } - nlAfter = cleanAfter +module.exports = readdirGlob; - const dollar = nlAfter === '' && isSub !== SUBPARSE ? '(?:$|\\/)' : '' +const fs = __nccwpck_require__(79896); +const { EventEmitter } = __nccwpck_require__(24434); +const { Minimatch } = __nccwpck_require__(82278); +const { resolve } = __nccwpck_require__(16928); - re = nlBefore + nlFirst + nlAfter + dollar + nlLast - } +function readdir(dir, strict) { + return new Promise((resolve, reject) => { + fs.readdir(dir, {withFileTypes: true} ,(err, files) => { + if(err) { + switch (err.code) { + case 'ENOTDIR': // Not a directory + if(strict) { + reject(err); + } else { + resolve([]); + } + break; + case 'ENOTSUP': // Operation not supported + case 'ENOENT': // No such file or directory + case 'ENAMETOOLONG': // Filename too long + case 'UNKNOWN': + resolve([]); + break; + case 'ELOOP': // Too many levels of symbolic links + default: + reject(err); + break; + } + } else { + resolve(files); + } + }); + }); +} +function stat(file, followSymlinks) { + return new Promise((resolve, reject) => { + const statFunc = followSymlinks ? fs.stat : fs.lstat; + statFunc(file, (err, stats) => { + if(err) { + switch (err.code) { + case 'ENOENT': + if(followSymlinks) { + // Fallback to lstat to handle broken links as files + resolve(stat(file, false)); + } else { + resolve(null); + } + break; + default: + resolve(null); + break; + } + } else { + resolve(stats); + } + }); + }); +} - // if the re is not "" at this point, then we need to make sure - // it doesn't match against an empty path part. - // Otherwise a/* will match a/, which it should not. - if (re !== '' && hasMagic) { - re = '(?=.)' + re +async function* exploreWalkAsync(dir, path, followSymlinks, useStat, shouldSkip, strict) { + let files = await readdir(path + dir, strict); + for(const file of files) { + let name = file.name; + if(name === undefined) { + // undefined file.name means the `withFileTypes` options is not supported by node + // we have to call the stat function to know if file is directory or not. + name = file; + useStat = true; } - - if (addPatternStart) { - re = patternStart() + re + const filename = dir + '/' + name; + const relative = filename.slice(1); // Remove the leading / + const absolute = path + '/' + relative; + let stats = null; + if(useStat || followSymlinks) { + stats = await stat(absolute, followSymlinks); } - - // parsing just a piece of a larger pattern. - if (isSub === SUBPARSE) { - return [re, hasMagic] + if(!stats && file.name !== undefined) { + stats = file; + } + if(stats === null) { + stats = { isDirectory: () => false }; } - // if it's nocase, and the lcase/uppercase don't match, it's magic - if (options.nocase && !hasMagic) { - hasMagic = pattern.toUpperCase() !== pattern.toLowerCase() + if(stats.isDirectory()) { + if(!shouldSkip(relative)) { + yield {relative, absolute, stats}; + yield* exploreWalkAsync(filename, path, followSymlinks, useStat, shouldSkip, false); + } + } else { + yield {relative, absolute, stats}; } + } +} +async function* explore(path, followSymlinks, useStat, shouldSkip) { + yield* exploreWalkAsync('', path, followSymlinks, useStat, shouldSkip, true); +} - // skip the regexp for non-magical patterns - // unescape anything in it, though, so that it'll be - // an exact match against a file etc. - if (!hasMagic) { - return globUnescape(pattern) + +function readOptions(options) { + return { + pattern: options.pattern, + dot: !!options.dot, + noglobstar: !!options.noglobstar, + matchBase: !!options.matchBase, + nocase: !!options.nocase, + ignore: options.ignore, + skip: options.skip, + + follow: !!options.follow, + stat: !!options.stat, + nodir: !!options.nodir, + mark: !!options.mark, + silent: !!options.silent, + absolute: !!options.absolute + }; +} + +class ReaddirGlob extends EventEmitter { + constructor(cwd, options, cb) { + super(); + if(typeof options === 'function') { + cb = options; + options = null; } - const flags = options.nocase ? 'i' : '' - try { - return Object.assign(new RegExp('^' + re + '$', flags), { - _glob: pattern, - _src: re, - }) - } catch (er) /* istanbul ignore next - should be impossible */ { - // If it was an invalid regular expression, then it can't match - // anything. This trick looks for a character after the end of - // the string, which is of course impossible, except in multi-line - // mode, but it's not a /m regex. - return new RegExp('$.') + this.options = readOptions(options || {}); + + this.matchers = []; + if(this.options.pattern) { + const matchers = Array.isArray(this.options.pattern) ? this.options.pattern : [this.options.pattern]; + this.matchers = matchers.map( m => + new Minimatch(m, { + dot: this.options.dot, + noglobstar:this.options.noglobstar, + matchBase:this.options.matchBase, + nocase:this.options.nocase + }) + ); + } + + this.ignoreMatchers = []; + if(this.options.ignore) { + const ignorePatterns = Array.isArray(this.options.ignore) ? this.options.ignore : [this.options.ignore]; + this.ignoreMatchers = ignorePatterns.map( ignore => + new Minimatch(ignore, {dot: true}) + ); + } + + this.skipMatchers = []; + if(this.options.skip) { + const skipPatterns = Array.isArray(this.options.skip) ? this.options.skip : [this.options.skip]; + this.skipMatchers = skipPatterns.map( skip => + new Minimatch(skip, {dot: true}) + ); } - } - makeRe () { - if (this.regexp || this.regexp === false) return this.regexp + this.iterator = explore(resolve(cwd || '.'), this.options.follow, this.options.stat, this._shouldSkipDirectory.bind(this)); + this.paused = false; + this.inactive = false; + this.aborted = false; + + if(cb) { + this._matches = []; + this.on('match', match => this._matches.push(this.options.absolute ? match.absolute : match.relative)); + this.on('error', err => cb(err)); + this.on('end', () => cb(null, this._matches)); + } - // at this point, this.set is a 2d array of partial - // pattern strings, or "**". - // - // It's better to use .match(). This function shouldn't - // be used, really, but it's pretty convenient sometimes, - // when you just want to work with a regex. - const set = this.set + setTimeout( () => this._next(), 0); + } - if (!set.length) { - this.regexp = false - return this.regexp - } - const options = this.options + _shouldSkipDirectory(relative) { + //console.log(relative, this.skipMatchers.some(m => m.match(relative))); + return this.skipMatchers.some(m => m.match(relative)); + } - const twoStar = options.noglobstar ? star - : options.dot ? twoStarDot - : twoStarNoDot - const flags = options.nocase ? 'i' : '' + _fileMatches(relative, isDirectory) { + const file = relative + (isDirectory ? '/' : ''); + return (this.matchers.length === 0 || this.matchers.some(m => m.match(file))) + && !this.ignoreMatchers.some(m => m.match(file)) + && (!this.options.nodir || !isDirectory); + } - // coalesce globstars and regexpify non-globstar patterns - // if it's the only item, then we just do one twoStar - // if it's the first, and there are more, prepend (\/|twoStar\/)? to next - // if it's the last, append (\/twoStar|) to previous - // if it's in the middle, append (\/|\/twoStar\/) to previous - // then filter out GLOBSTAR symbols - let re = set.map(pattern => { - pattern = pattern.map(p => - typeof p === 'string' ? regExpEscape(p) - : p === GLOBSTAR ? GLOBSTAR - : p._src - ).reduce((set, p) => { - if (!(set[set.length - 1] === GLOBSTAR && p === GLOBSTAR)) { - set.push(p) - } - return set - }, []) - pattern.forEach((p, i) => { - if (p !== GLOBSTAR || pattern[i-1] === GLOBSTAR) { - return - } - if (i === 0) { - if (pattern.length > 1) { - pattern[i+1] = '(?:\\\/|' + twoStar + '\\\/)?' + pattern[i+1] - } else { - pattern[i] = twoStar + _next() { + if(!this.paused && !this.aborted) { + this.iterator.next() + .then((obj)=> { + if(!obj.done) { + const isDirectory = obj.value.stats.isDirectory(); + if(this._fileMatches(obj.value.relative, isDirectory )) { + let relative = obj.value.relative; + let absolute = obj.value.absolute; + if(this.options.mark && isDirectory) { + relative += '/'; + absolute += '/'; + } + if(this.options.stat) { + this.emit('match', {relative, absolute, stat:obj.value.stats}); + } else { + this.emit('match', {relative, absolute}); + } } - } else if (i === pattern.length - 1) { - pattern[i-1] += '(?:\\\/|' + twoStar + ')?' + this._next(this.iterator); } else { - pattern[i-1] += '(?:\\\/|\\\/' + twoStar + '\\\/)' + pattern[i+1] - pattern[i+1] = GLOBSTAR + this.emit('end'); } }) - return pattern.filter(p => p !== GLOBSTAR).join('/') - }).join('|') + .catch((err) => { + this.abort(); + this.emit('error', err); + if(!err.code && !this.options.silent) { + console.error(err); + } + }); + } else { + this.inactive = true; + } + } - // must match entire pattern - // ending in a * or ** will make it less strict. - re = '^(?:' + re + ')$' + abort() { + this.aborted = true; + } - // can match anything, as long as it's not this. - if (this.negate) re = '^(?!' + re + ').*$' + pause() { + this.paused = true; + } - try { - this.regexp = new RegExp(re, flags) - } catch (ex) /* istanbul ignore next - should be impossible */ { - this.regexp = false + resume() { + this.paused = false; + if(this.inactive) { + this.inactive = false; + this._next(); } - return this.regexp } +} - match (f, partial = this.partial) { - this.debug('match', f, this.pattern) - // short-circuit in the case of busted things. - // comments, etc. - if (this.comment) return false - if (this.empty) return f === '' - if (f === '/' && partial) return true +function readdirGlob(pattern, options, cb) { + return new ReaddirGlob(pattern, options, cb); +} +readdirGlob.ReaddirGlob = ReaddirGlob; - const options = this.options +/***/ }), - // windows: need to use /, not \ - if (path.sep !== '/') { - f = f.split(path.sep).join('/') - } +/***/ 79253: +/***/ ((module, exports, __nccwpck_require__) => { - // treat the test path as a set of pathparts. - f = f.split(slashSplit) - this.debug(this.pattern, 'split', f) +/* eslint-disable node/no-deprecated-api */ +var buffer = __nccwpck_require__(20181) +var Buffer = buffer.Buffer - // just ONE of the pattern sets in this.set needs to match - // in order for it to be valid. If negating, then just one - // match means that we have failed. - // Either way, return on the first hit. +// alternative to using Object.keys for old browsers +function copyProps (src, dst) { + for (var key in src) { + dst[key] = src[key] + } +} +if (Buffer.from && Buffer.alloc && Buffer.allocUnsafe && Buffer.allocUnsafeSlow) { + module.exports = buffer +} else { + // Copy properties from require('buffer') + copyProps(buffer, exports) + exports.Buffer = SafeBuffer +} - const set = this.set - this.debug(this.pattern, 'set', set) +function SafeBuffer (arg, encodingOrOffset, length) { + return Buffer(arg, encodingOrOffset, length) +} - // Find the basename of the path by looking for the last non-empty segment - let filename - for (let i = f.length - 1; i >= 0; i--) { - filename = f[i] - if (filename) break - } +// Copy static methods from Buffer +copyProps(Buffer, SafeBuffer) - for (let i = 0; i < set.length; i++) { - const pattern = set[i] - let file = f - if (options.matchBase && pattern.length === 1) { - file = [filename] - } - const hit = this.matchOne(file, pattern, partial) - if (hit) { - if (options.flipNegate) return true - return !this.negate - } - } +SafeBuffer.from = function (arg, encodingOrOffset, length) { + if (typeof arg === 'number') { + throw new TypeError('Argument must not be a number') + } + return Buffer(arg, encodingOrOffset, length) +} - // didn't get any hits. this is success if it's a negative - // pattern, failure otherwise. - if (options.flipNegate) return false - return this.negate +SafeBuffer.alloc = function (size, fill, encoding) { + if (typeof size !== 'number') { + throw new TypeError('Argument must be a number') + } + var buf = Buffer(size) + if (fill !== undefined) { + if (typeof encoding === 'string') { + buf.fill(fill, encoding) + } else { + buf.fill(fill) + } + } else { + buf.fill(0) } + return buf +} - static defaults (def) { - return minimatch.defaults(def).Minimatch +SafeBuffer.allocUnsafe = function (size) { + if (typeof size !== 'number') { + throw new TypeError('Argument must be a number') } + return Buffer(size) } -minimatch.Minimatch = Minimatch +SafeBuffer.allocUnsafeSlow = function (size) { + if (typeof size !== 'number') { + throw new TypeError('Argument must be a number') + } + return buffer.SlowBuffer(size) +} /***/ }), -/***/ 93058: +/***/ 65249: /***/ ((module, exports, __nccwpck_require__) => { /*! safe-buffer. MIT License. Feross Aboukhadijeh */ @@ -39897,7 +39782,7 @@ SafeBuffer.allocUnsafeSlow = function (size) { /***/ }), -/***/ 89379: +/***/ 93000: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { @@ -40037,17 +39922,17 @@ class Comparator { module.exports = Comparator -const parseOptions = __nccwpck_require__(70356) -const { safeRe: re, t } = __nccwpck_require__(95471) -const cmp = __nccwpck_require__(28646) -const debug = __nccwpck_require__(1159) -const SemVer = __nccwpck_require__(7163) -const Range = __nccwpck_require__(96782) +const parseOptions = __nccwpck_require__(77475) +const { safeRe: re, t } = __nccwpck_require__(44558) +const cmp = __nccwpck_require__(79911) +const debug = __nccwpck_require__(21584) +const SemVer = __nccwpck_require__(4364) +const Range = __nccwpck_require__(5135) /***/ }), -/***/ 96782: +/***/ 5135: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { @@ -40150,6 +40035,9 @@ class Range { } parseRange (range) { + // strip build metadata so it can't bleed into the version + range = range.replace(BUILDSTRIPRE, '') + // memoize range parsing for performance. // this is a very hot path, and fully deterministic. const memoOpts = @@ -40266,21 +40154,25 @@ class Range { module.exports = Range -const LRU = __nccwpck_require__(61383) +const LRU = __nccwpck_require__(30370) const cache = new LRU() -const parseOptions = __nccwpck_require__(70356) -const Comparator = __nccwpck_require__(89379) -const debug = __nccwpck_require__(1159) -const SemVer = __nccwpck_require__(7163) +const parseOptions = __nccwpck_require__(77475) +const Comparator = __nccwpck_require__(93000) +const debug = __nccwpck_require__(21584) +const SemVer = __nccwpck_require__(4364) const { safeRe: re, + src, t, comparatorTrimReplace, tildeTrimReplace, caretTrimReplace, -} = __nccwpck_require__(95471) -const { FLAG_INCLUDE_PRERELEASE, FLAG_LOOSE } = __nccwpck_require__(45101) +} = __nccwpck_require__(44558) +const { FLAG_INCLUDE_PRERELEASE, FLAG_LOOSE } = __nccwpck_require__(42962) + +// unbounded global build-metadata stripper used by parseRange +const BUILDSTRIPRE = new RegExp(src[t.BUILD], 'g') const isNullSet = c => c.value === '<0.0.0-0' const isAny = c => c.value === '' @@ -40322,6 +40214,11 @@ const parseComparator = (comp, options) => { const isX = id => !id || id.toLowerCase() === 'x' || id === '*' +const invalidXRangeOrder = (M, m, p) => ( + (isX(M) && !isX(m)) || + (isX(m) && p && !isX(p)) +) + // ~, ~> --> * (any, kinda silly) // ~2, ~2.x, ~2.x.x, ~>2, ~>2.x ~>2.x.x --> >=2.0.0 <3.0.0-0 // ~2.0, ~2.0.x, ~>2.0, ~>2.0.x --> >=2.0.0 <2.1.0-0 @@ -40339,6 +40236,10 @@ const replaceTildes = (comp, options) => { const replaceTilde = (comp, options) => { const r = options.loose ? re[t.TILDELOOSE] : re[t.TILDE] + // if we're including prereleases in the match, then the lower bound is + // -0, the lowest possible prerelease value, just like x-ranges and carets. + // this keeps `~1.2` equivalent to the `1.2.x` x-range it's documented as. + const z = options.includePrerelease ? '-0' : '' return comp.replace(r, (_, M, m, p, pr) => { debug('tilde', comp, _, M, m, p, pr) let ret @@ -40346,10 +40247,10 @@ const replaceTilde = (comp, options) => { if (isX(M)) { ret = '' } else if (isX(m)) { - ret = `>=${M}.0.0 <${+M + 1}.0.0-0` + ret = `>=${M}.0.0${z} <${+M + 1}.0.0-0` } else if (isX(p)) { // ~1.2 == >=1.2.0 <1.3.0-0 - ret = `>=${M}.${m}.0 <${M}.${+m + 1}.0-0` + ret = `>=${M}.${m}.0${z} <${M}.${+m + 1}.0-0` } else if (pr) { debug('replaceTilde pr', pr) ret = `>=${M}.${m}.${p}-${pr @@ -40418,10 +40319,10 @@ const replaceCaret = (comp, options) => { if (M === '0') { if (m === '0') { ret = `>=${M}.${m}.${p - }${z} <${M}.${m}.${+p + 1}-0` + } <${M}.${m}.${+p + 1}-0` } else { ret = `>=${M}.${m}.${p - }${z} <${M}.${+m + 1}.0-0` + } <${M}.${+m + 1}.0-0` } } else { ret = `>=${M}.${m}.${p @@ -40447,6 +40348,10 @@ const replaceXRange = (comp, options) => { const r = options.loose ? re[t.XRANGELOOSE] : re[t.XRANGE] return comp.replace(r, (ret, gtlt, M, m, p, pr) => { debug('xRange', comp, ret, gtlt, M, m, p, pr) + if (invalidXRangeOrder(M, m, p)) { + return comp + } + const xM = isX(M) const xm = xM || isX(m) const xp = xm || isX(p) @@ -40611,17 +40516,33 @@ const testSet = (set, version, options) => { /***/ }), -/***/ 7163: +/***/ 4364: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const debug = __nccwpck_require__(1159) -const { MAX_LENGTH, MAX_SAFE_INTEGER } = __nccwpck_require__(45101) -const { safeRe: re, t } = __nccwpck_require__(95471) +const debug = __nccwpck_require__(21584) +const { MAX_LENGTH, MAX_SAFE_INTEGER } = __nccwpck_require__(42962) +const { safeRe: re, t } = __nccwpck_require__(44558) + +const parseOptions = __nccwpck_require__(77475) +const { compareIdentifiers } = __nccwpck_require__(19003) + +const isPrereleaseIdentifier = (prerelease, identifier) => { + const identifiers = identifier.split('.') + if (identifiers.length > prerelease.length) { + return false + } + + for (let i = 0; i < identifiers.length; i++) { + if (compareIdentifiers(prerelease[i], identifiers[i]) !== 0) { + return false + } + } + + return true +} -const parseOptions = __nccwpck_require__(70356) -const { compareIdentifiers } = __nccwpck_require__(73348) class SemVer { constructor (version, options) { options = parseOptions(options) @@ -40925,8 +40846,9 @@ class SemVer { if (identifierBase === false) { prerelease = [identifier] } - if (compareIdentifiers(this.prerelease[0], identifier) === 0) { - if (isNaN(this.prerelease[1])) { + if (isPrereleaseIdentifier(this.prerelease, identifier)) { + const prereleaseBase = this.prerelease[identifier.split('.').length] + if (isNaN(prereleaseBase)) { this.prerelease = prerelease } } else { @@ -40951,12 +40873,12 @@ module.exports = SemVer /***/ }), -/***/ 1799: +/***/ 54638: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const parse = __nccwpck_require__(16353) +const parse = __nccwpck_require__(82824) const clean = (version, options) => { const s = parse(version.trim().replace(/^[=v]+/, ''), options) return s ? s.version : null @@ -40966,17 +40888,17 @@ module.exports = clean /***/ }), -/***/ 28646: +/***/ 79911: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const eq = __nccwpck_require__(55082) -const neq = __nccwpck_require__(4974) -const gt = __nccwpck_require__(16599) -const gte = __nccwpck_require__(41236) -const lt = __nccwpck_require__(3872) -const lte = __nccwpck_require__(56717) +const eq = __nccwpck_require__(92329) +const neq = __nccwpck_require__(97639) +const gt = __nccwpck_require__(63892) +const gte = __nccwpck_require__(37777) +const lt = __nccwpck_require__(69531) +const lte = __nccwpck_require__(39496) const cmp = (a, op, b, loose) => { switch (op) { @@ -41027,14 +40949,14 @@ module.exports = cmp /***/ }), -/***/ 35385: +/***/ 62466: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const SemVer = __nccwpck_require__(7163) -const parse = __nccwpck_require__(16353) -const { safeRe: re, t } = __nccwpck_require__(95471) +const SemVer = __nccwpck_require__(4364) +const parse = __nccwpck_require__(82824) +const { safeRe: re, t } = __nccwpck_require__(44558) const coerce = (version, options) => { if (version instanceof SemVer) { @@ -41096,12 +41018,12 @@ module.exports = coerce /***/ }), -/***/ 37648: +/***/ 12325: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const SemVer = __nccwpck_require__(7163) +const SemVer = __nccwpck_require__(4364) const compareBuild = (a, b, loose) => { const versionA = new SemVer(a, loose) const versionB = new SemVer(b, loose) @@ -41112,24 +41034,24 @@ module.exports = compareBuild /***/ }), -/***/ 56874: +/***/ 35419: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const compare = __nccwpck_require__(78469) +const compare = __nccwpck_require__(17512) const compareLoose = (a, b) => compare(a, b, true) module.exports = compareLoose /***/ }), -/***/ 78469: +/***/ 17512: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const SemVer = __nccwpck_require__(7163) +const SemVer = __nccwpck_require__(4364) const compare = (a, b, loose) => new SemVer(a, loose).compare(new SemVer(b, loose)) @@ -41138,12 +41060,12 @@ module.exports = compare /***/ }), -/***/ 70711: +/***/ 50848: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const parse = __nccwpck_require__(16353) +const parse = __nccwpck_require__(82824) const diff = (version1, version2) => { const v1 = parse(version1, null, true) @@ -41196,7 +41118,7 @@ const diff = (version1, version2) => { return prefix + 'patch' } - // high and low are preleases + // high and low are prereleases return 'prerelease' } @@ -41205,48 +41127,48 @@ module.exports = diff /***/ }), -/***/ 55082: +/***/ 92329: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const compare = __nccwpck_require__(78469) +const compare = __nccwpck_require__(17512) const eq = (a, b, loose) => compare(a, b, loose) === 0 module.exports = eq /***/ }), -/***/ 16599: +/***/ 63892: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const compare = __nccwpck_require__(78469) +const compare = __nccwpck_require__(17512) const gt = (a, b, loose) => compare(a, b, loose) > 0 module.exports = gt /***/ }), -/***/ 41236: +/***/ 37777: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const compare = __nccwpck_require__(78469) +const compare = __nccwpck_require__(17512) const gte = (a, b, loose) => compare(a, b, loose) >= 0 module.exports = gte /***/ }), -/***/ 62338: +/***/ 34647: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const SemVer = __nccwpck_require__(7163) +const SemVer = __nccwpck_require__(4364) const inc = (version, release, options, identifier, identifierBase) => { if (typeof (options) === 'string') { @@ -41269,72 +41191,72 @@ module.exports = inc /***/ }), -/***/ 3872: +/***/ 69531: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const compare = __nccwpck_require__(78469) +const compare = __nccwpck_require__(17512) const lt = (a, b, loose) => compare(a, b, loose) < 0 module.exports = lt /***/ }), -/***/ 56717: +/***/ 39496: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const compare = __nccwpck_require__(78469) +const compare = __nccwpck_require__(17512) const lte = (a, b, loose) => compare(a, b, loose) <= 0 module.exports = lte /***/ }), -/***/ 68511: +/***/ 63746: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const SemVer = __nccwpck_require__(7163) +const SemVer = __nccwpck_require__(4364) const major = (a, loose) => new SemVer(a, loose).major module.exports = major /***/ }), -/***/ 32603: +/***/ 43478: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const SemVer = __nccwpck_require__(7163) +const SemVer = __nccwpck_require__(4364) const minor = (a, loose) => new SemVer(a, loose).minor module.exports = minor /***/ }), -/***/ 4974: +/***/ 97639: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const compare = __nccwpck_require__(78469) +const compare = __nccwpck_require__(17512) const neq = (a, b, loose) => compare(a, b, loose) !== 0 module.exports = neq /***/ }), -/***/ 16353: +/***/ 82824: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const SemVer = __nccwpck_require__(7163) +const SemVer = __nccwpck_require__(4364) const parse = (version, options, throwErrors = false) => { if (version instanceof SemVer) { return version @@ -41354,24 +41276,24 @@ module.exports = parse /***/ }), -/***/ 48756: +/***/ 66309: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const SemVer = __nccwpck_require__(7163) +const SemVer = __nccwpck_require__(4364) const patch = (a, loose) => new SemVer(a, loose).patch module.exports = patch /***/ }), -/***/ 15714: +/***/ 9401: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const parse = __nccwpck_require__(16353) +const parse = __nccwpck_require__(82824) const prerelease = (version, options) => { const parsed = parse(version, options) return (parsed && parsed.prerelease.length) ? parsed.prerelease : null @@ -41381,36 +41303,36 @@ module.exports = prerelease /***/ }), -/***/ 32173: +/***/ 72778: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const compare = __nccwpck_require__(78469) +const compare = __nccwpck_require__(17512) const rcompare = (a, b, loose) => compare(b, a, loose) module.exports = rcompare /***/ }), -/***/ 87192: +/***/ 70141: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const compareBuild = __nccwpck_require__(37648) +const compareBuild = __nccwpck_require__(12325) const rsort = (list, loose) => list.sort((a, b) => compareBuild(b, a, loose)) module.exports = rsort /***/ }), -/***/ 68011: +/***/ 76366: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const Range = __nccwpck_require__(96782) +const Range = __nccwpck_require__(5135) const satisfies = (version, range, options) => { try { range = new Range(range, options) @@ -41424,24 +41346,79 @@ module.exports = satisfies /***/ }), -/***/ 29872: +/***/ 32639: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const compareBuild = __nccwpck_require__(37648) +const compareBuild = __nccwpck_require__(12325) const sort = (list, loose) => list.sort((a, b) => compareBuild(a, b, loose)) module.exports = sort /***/ }), -/***/ 58780: +/***/ 28937: +/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { + + + +const parse = __nccwpck_require__(82824) +const constants = __nccwpck_require__(42962) +const SemVer = __nccwpck_require__(4364) + +const truncate = (version, truncation, options) => { + if (!constants.RELEASE_TYPES.includes(truncation)) { + return null + } + + const clonedVersion = cloneInputVersion(version, options) + return clonedVersion && doTruncation(clonedVersion, truncation) +} + +const cloneInputVersion = (version, options) => { + const versionStringToParse = ( + version instanceof SemVer ? version.version : version + ) + + return parse(versionStringToParse, options) +} + +const doTruncation = (version, truncation) => { + if (isPrerelease(truncation)) { + return version.version + } + + version.prerelease = [] + + switch (truncation) { + case 'major': + version.minor = 0 + version.patch = 0 + break + case 'minor': + version.patch = 0 + break + } + + return version.format() +} + +const isPrerelease = (type) => { + return type.startsWith('pre') +} + +module.exports = truncate + + +/***/ }), + +/***/ 53569: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const parse = __nccwpck_require__(16353) +const parse = __nccwpck_require__(82824) const valid = (version, options) => { const v = parse(version, options) return v ? v.version : null @@ -41451,53 +41428,54 @@ module.exports = valid /***/ }), -/***/ 62088: +/***/ 24493: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { // just pre-load all the stuff that index.js lazily exports -const internalRe = __nccwpck_require__(95471) -const constants = __nccwpck_require__(45101) -const SemVer = __nccwpck_require__(7163) -const identifiers = __nccwpck_require__(73348) -const parse = __nccwpck_require__(16353) -const valid = __nccwpck_require__(58780) -const clean = __nccwpck_require__(1799) -const inc = __nccwpck_require__(62338) -const diff = __nccwpck_require__(70711) -const major = __nccwpck_require__(68511) -const minor = __nccwpck_require__(32603) -const patch = __nccwpck_require__(48756) -const prerelease = __nccwpck_require__(15714) -const compare = __nccwpck_require__(78469) -const rcompare = __nccwpck_require__(32173) -const compareLoose = __nccwpck_require__(56874) -const compareBuild = __nccwpck_require__(37648) -const sort = __nccwpck_require__(29872) -const rsort = __nccwpck_require__(87192) -const gt = __nccwpck_require__(16599) -const lt = __nccwpck_require__(3872) -const eq = __nccwpck_require__(55082) -const neq = __nccwpck_require__(4974) -const gte = __nccwpck_require__(41236) -const lte = __nccwpck_require__(56717) -const cmp = __nccwpck_require__(28646) -const coerce = __nccwpck_require__(35385) -const Comparator = __nccwpck_require__(89379) -const Range = __nccwpck_require__(96782) -const satisfies = __nccwpck_require__(68011) -const toComparators = __nccwpck_require__(54750) -const maxSatisfying = __nccwpck_require__(73193) -const minSatisfying = __nccwpck_require__(68595) -const minVersion = __nccwpck_require__(51866) -const validRange = __nccwpck_require__(64737) -const outside = __nccwpck_require__(10280) -const gtr = __nccwpck_require__(12276) -const ltr = __nccwpck_require__(15213) -const intersects = __nccwpck_require__(23465) -const simplifyRange = __nccwpck_require__(82028) -const subset = __nccwpck_require__(61489) +const internalRe = __nccwpck_require__(44558) +const constants = __nccwpck_require__(42962) +const SemVer = __nccwpck_require__(4364) +const identifiers = __nccwpck_require__(19003) +const parse = __nccwpck_require__(82824) +const valid = __nccwpck_require__(53569) +const clean = __nccwpck_require__(54638) +const inc = __nccwpck_require__(34647) +const diff = __nccwpck_require__(50848) +const major = __nccwpck_require__(63746) +const minor = __nccwpck_require__(43478) +const patch = __nccwpck_require__(66309) +const prerelease = __nccwpck_require__(9401) +const compare = __nccwpck_require__(17512) +const rcompare = __nccwpck_require__(72778) +const compareLoose = __nccwpck_require__(35419) +const compareBuild = __nccwpck_require__(12325) +const sort = __nccwpck_require__(32639) +const rsort = __nccwpck_require__(70141) +const gt = __nccwpck_require__(63892) +const lt = __nccwpck_require__(69531) +const eq = __nccwpck_require__(92329) +const neq = __nccwpck_require__(97639) +const gte = __nccwpck_require__(37777) +const lte = __nccwpck_require__(39496) +const cmp = __nccwpck_require__(79911) +const coerce = __nccwpck_require__(62466) +const truncate = __nccwpck_require__(28937) +const Comparator = __nccwpck_require__(93000) +const Range = __nccwpck_require__(5135) +const satisfies = __nccwpck_require__(76366) +const toComparators = __nccwpck_require__(47783) +const maxSatisfying = __nccwpck_require__(16852) +const minSatisfying = __nccwpck_require__(13702) +const minVersion = __nccwpck_require__(67877) +const validRange = __nccwpck_require__(12570) +const outside = __nccwpck_require__(51035) +const gtr = __nccwpck_require__(28219) +const ltr = __nccwpck_require__(65206) +const intersects = __nccwpck_require__(54116) +const simplifyRange = __nccwpck_require__(46037) +const subset = __nccwpck_require__(22288) module.exports = { parse, valid, @@ -41522,6 +41500,7 @@ module.exports = { lte, cmp, coerce, + truncate, Comparator, Range, satisfies, @@ -41549,7 +41528,7 @@ module.exports = { /***/ }), -/***/ 45101: +/***/ 42962: /***/ ((module) => { @@ -41593,7 +41572,7 @@ module.exports = { /***/ }), -/***/ 1159: +/***/ 21584: /***/ ((module) => { @@ -41611,7 +41590,7 @@ module.exports = debug /***/ }), -/***/ 73348: +/***/ 19003: /***/ ((module) => { @@ -41647,7 +41626,7 @@ module.exports = { /***/ }), -/***/ 61383: +/***/ 30370: /***/ ((module) => { @@ -41696,7 +41675,7 @@ module.exports = LRUCache /***/ }), -/***/ 70356: +/***/ 77475: /***/ ((module) => { @@ -41720,7 +41699,7 @@ module.exports = parseOptions /***/ }), -/***/ 95471: +/***/ 44558: /***/ ((module, exports, __nccwpck_require__) => { @@ -41729,8 +41708,8 @@ const { MAX_SAFE_COMPONENT_LENGTH, MAX_SAFE_BUILD_LENGTH, MAX_LENGTH, -} = __nccwpck_require__(45101) -const debug = __nccwpck_require__(1159) +} = __nccwpck_require__(42962) +const debug = __nccwpck_require__(21584) exports = module.exports = {} // The actual regexps go on exports.re @@ -41803,8 +41782,8 @@ createToken('MAINVERSIONLOOSE', `(${src[t.NUMERICIDENTIFIERLOOSE]})\\.` + // ## Pre-release Version Identifier // A numeric identifier, or a non-numeric identifier. -// Non-numberic identifiers include numberic identifiers but can be longer. -// Therefore non-numberic identifiers must go first. +// Non-numeric identifiers include numeric identifiers but can be longer. +// Therefore non-numeric identifiers must go first. createToken('PRERELEASEIDENTIFIER', `(?:${src[t.NONNUMERICIDENTIFIER] }|${src[t.NUMERICIDENTIFIER]})`) @@ -41861,7 +41840,7 @@ createToken('LOOSE', `^${src[t.LOOSEPLAIN]}$`) createToken('GTLT', '((?:<|>)?=?)') // Something like "2.*" or "1.2.x". -// Note that "x.x" is a valid xRange identifer, meaning "any version" +// Note that "x.x" is a valid xRange identifier, meaning "any version" // Only the first item is strictly required. createToken('XRANGEIDENTIFIERLOOSE', `${src[t.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`) createToken('XRANGEIDENTIFIER', `${src[t.NUMERICIDENTIFIER]}|x|X|\\*`) @@ -41950,25 +41929,25 @@ createToken('GTE0PRE', '^\\s*>=\\s*0\\.0\\.0-0\\s*$') /***/ }), -/***/ 12276: +/***/ 28219: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { // Determine if version is greater than all the versions possible in the range. -const outside = __nccwpck_require__(10280) +const outside = __nccwpck_require__(51035) const gtr = (version, range, options) => outside(version, range, '>', options) module.exports = gtr /***/ }), -/***/ 23465: +/***/ 54116: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const Range = __nccwpck_require__(96782) +const Range = __nccwpck_require__(5135) const intersects = (r1, r2, options) => { r1 = new Range(r1, options) r2 = new Range(r2, options) @@ -41979,12 +41958,12 @@ module.exports = intersects /***/ }), -/***/ 15213: +/***/ 65206: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const outside = __nccwpck_require__(10280) +const outside = __nccwpck_require__(51035) // Determine if version is less than all the versions possible in the range const ltr = (version, range, options) => outside(version, range, '<', options) module.exports = ltr @@ -41992,13 +41971,13 @@ module.exports = ltr /***/ }), -/***/ 73193: +/***/ 16852: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const SemVer = __nccwpck_require__(7163) -const Range = __nccwpck_require__(96782) +const SemVer = __nccwpck_require__(4364) +const Range = __nccwpck_require__(5135) const maxSatisfying = (versions, range, options) => { let max = null @@ -42026,13 +42005,13 @@ module.exports = maxSatisfying /***/ }), -/***/ 68595: +/***/ 13702: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const SemVer = __nccwpck_require__(7163) -const Range = __nccwpck_require__(96782) +const SemVer = __nccwpck_require__(4364) +const Range = __nccwpck_require__(5135) const minSatisfying = (versions, range, options) => { let min = null let minSV = null @@ -42059,14 +42038,14 @@ module.exports = minSatisfying /***/ }), -/***/ 51866: +/***/ 67877: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const SemVer = __nccwpck_require__(7163) -const Range = __nccwpck_require__(96782) -const gt = __nccwpck_require__(16599) +const SemVer = __nccwpck_require__(4364) +const Range = __nccwpck_require__(5135) +const gt = __nccwpck_require__(63892) const minVersion = (range, loose) => { range = new Range(range, loose) @@ -42129,20 +42108,20 @@ module.exports = minVersion /***/ }), -/***/ 10280: +/***/ 51035: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const SemVer = __nccwpck_require__(7163) -const Comparator = __nccwpck_require__(89379) +const SemVer = __nccwpck_require__(4364) +const Comparator = __nccwpck_require__(93000) const { ANY } = Comparator -const Range = __nccwpck_require__(96782) -const satisfies = __nccwpck_require__(68011) -const gt = __nccwpck_require__(16599) -const lt = __nccwpck_require__(3872) -const lte = __nccwpck_require__(56717) -const gte = __nccwpck_require__(41236) +const Range = __nccwpck_require__(5135) +const satisfies = __nccwpck_require__(76366) +const gt = __nccwpck_require__(63892) +const lt = __nccwpck_require__(69531) +const lte = __nccwpck_require__(39496) +const gte = __nccwpck_require__(37777) const outside = (version, range, hilo, options) => { version = new SemVer(version, options) @@ -42218,7 +42197,7 @@ module.exports = outside /***/ }), -/***/ 82028: +/***/ 46037: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { @@ -42226,8 +42205,8 @@ module.exports = outside // given a set of versions and a range, create a "simplified" range // that includes the same versions that the original range does // If the original range is shorter than the simplified one, return that. -const satisfies = __nccwpck_require__(68011) -const compare = __nccwpck_require__(78469) +const satisfies = __nccwpck_require__(76366) +const compare = __nccwpck_require__(17512) module.exports = (versions, range, options) => { const set = [] let first = null @@ -42274,16 +42253,16 @@ module.exports = (versions, range, options) => { /***/ }), -/***/ 61489: +/***/ 22288: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const Range = __nccwpck_require__(96782) -const Comparator = __nccwpck_require__(89379) +const Range = __nccwpck_require__(5135) +const Comparator = __nccwpck_require__(93000) const { ANY } = Comparator -const satisfies = __nccwpck_require__(68011) -const compare = __nccwpck_require__(78469) +const satisfies = __nccwpck_require__(76366) +const compare = __nccwpck_require__(17512) // Complex range `r1 || r2 || ...` is a subset of `R1 || R2 || ...` iff: // - Every simple range `r1, r2, ...` is a null set, OR @@ -42317,7 +42296,7 @@ const compare = __nccwpck_require__(78469) // - If LT // - If LT.semver is greater than any < or <= comp in C, return false // - If LT is <=, and LT.semver does not satisfy every C, return false -// - If GT.semver has a prerelease, and not in prerelease mode +// - If LT.semver has a prerelease, and not in prerelease mode // - If no C has a prerelease and the LT.semver tuple, return false // - Else return true @@ -42453,7 +42432,7 @@ const simpleSubset = (sub, dom, options) => { if (higher === c && higher !== gt) { return false } - } else if (gt.operator === '>=' && !satisfies(gt.semver, String(c), options)) { + } else if (gt.operator === '>=' && !c.test(gt.semver)) { return false } } @@ -42471,7 +42450,7 @@ const simpleSubset = (sub, dom, options) => { if (lower === c && lower !== lt) { return false } - } else if (lt.operator === '<=' && !satisfies(lt.semver, String(c), options)) { + } else if (lt.operator === '<=' && !c.test(lt.semver)) { return false } } @@ -42530,12 +42509,12 @@ module.exports = subset /***/ }), -/***/ 54750: +/***/ 47783: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const Range = __nccwpck_require__(96782) +const Range = __nccwpck_require__(5135) // Mostly just for testing and legacy API reasons const toComparators = (range, options) => @@ -42547,12 +42526,12 @@ module.exports = toComparators /***/ }), -/***/ 64737: +/***/ 12570: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const Range = __nccwpck_require__(96782) +const Range = __nccwpck_require__(5135) const validRange = (range, options) => { try { // Return '*' instead of '' so that truthiness works. @@ -42567,48 +42546,46 @@ module.exports = validRange /***/ }), -/***/ 36204: +/***/ 69045: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { EventEmitter } = __nccwpck_require__(29580) -const STREAM_DESTROYED = new Error('Stream was destroyed') -const PREMATURE_CLOSE = new Error('Premature close') +const { EventEmitter } = __nccwpck_require__(19366) +const FIFO = __nccwpck_require__(19597) +const TextDecoder = __nccwpck_require__(45795) -const FIFO = __nccwpck_require__(83867) -const TextDecoder = __nccwpck_require__(97934) +const StreamError = __nccwpck_require__(15586) // if we do a future major, expect queue microtask to be there always, for now a bit defensive -const qmt = typeof queueMicrotask === 'undefined' ? fn => global.process.nextTick(fn) : queueMicrotask - -/* eslint-disable no-multi-spaces */ +const qmt = + typeof queueMicrotask === 'undefined' ? (fn) => global.process.nextTick(fn) : queueMicrotask // 29 bits used total (4 from shared, 14 from read, and 11 from write) -const MAX = ((1 << 29) - 1) +const MAX = (1 << 29) - 1 // Shared state -const OPENING = 0b0001 +const OPENING = 0b0001 const PREDESTROYING = 0b0010 -const DESTROYING = 0b0100 -const DESTROYED = 0b1000 +const DESTROYING = 0b0100 +const DESTROYED = 0b1000 const NOT_OPENING = MAX ^ OPENING const NOT_PREDESTROYING = MAX ^ PREDESTROYING // Read state (4 bit offset from shared state) -const READ_ACTIVE = 0b00000000000001 << 4 -const READ_UPDATING = 0b00000000000010 << 4 -const READ_PRIMARY = 0b00000000000100 << 4 -const READ_QUEUED = 0b00000000001000 << 4 -const READ_RESUMED = 0b00000000010000 << 4 -const READ_PIPE_DRAINED = 0b00000000100000 << 4 -const READ_ENDING = 0b00000001000000 << 4 -const READ_EMIT_DATA = 0b00000010000000 << 4 -const READ_EMIT_READABLE = 0b00000100000000 << 4 +const READ_ACTIVE = 0b00000000000001 << 4 +const READ_UPDATING = 0b00000000000010 << 4 +const READ_PRIMARY = 0b00000000000100 << 4 +const READ_QUEUED = 0b00000000001000 << 4 +const READ_RESUMED = 0b00000000010000 << 4 +const READ_PIPE_DRAINED = 0b00000000100000 << 4 +const READ_ENDING = 0b00000001000000 << 4 +const READ_EMIT_DATA = 0b00000010000000 << 4 +const READ_EMIT_READABLE = 0b00000100000000 << 4 const READ_EMITTED_READABLE = 0b00001000000000 << 4 -const READ_DONE = 0b00010000000000 << 4 -const READ_NEXT_TICK = 0b00100000000000 << 4 -const READ_NEEDS_PUSH = 0b01000000000000 << 4 -const READ_READ_AHEAD = 0b10000000000000 << 4 +const READ_DONE = 0b00010000000000 << 4 +const READ_NEXT_TICK = 0b00100000000000 << 4 +const READ_NEEDS_PUSH = 0b01000000000000 << 4 +const READ_READ_AHEAD = 0b10000000000000 << 4 // Combined read state const READ_FLOWING = READ_RESUMED | READ_PIPE_DRAINED @@ -42617,40 +42594,40 @@ const READ_PRIMARY_AND_ACTIVE = READ_PRIMARY | READ_ACTIVE const READ_EMIT_READABLE_AND_QUEUED = READ_EMIT_READABLE | READ_QUEUED const READ_RESUMED_READ_AHEAD = READ_RESUMED | READ_READ_AHEAD -const READ_NOT_ACTIVE = MAX ^ READ_ACTIVE -const READ_NON_PRIMARY = MAX ^ READ_PRIMARY +const READ_NOT_ACTIVE = MAX ^ READ_ACTIVE +const READ_NON_PRIMARY = MAX ^ READ_PRIMARY const READ_NON_PRIMARY_AND_PUSHED = MAX ^ (READ_PRIMARY | READ_NEEDS_PUSH) -const READ_PUSHED = MAX ^ READ_NEEDS_PUSH -const READ_PAUSED = MAX ^ READ_RESUMED -const READ_NOT_QUEUED = MAX ^ (READ_QUEUED | READ_EMITTED_READABLE) -const READ_NOT_ENDING = MAX ^ READ_ENDING -const READ_PIPE_NOT_DRAINED = MAX ^ READ_FLOWING -const READ_NOT_NEXT_TICK = MAX ^ READ_NEXT_TICK -const READ_NOT_UPDATING = MAX ^ READ_UPDATING -const READ_NO_READ_AHEAD = MAX ^ READ_READ_AHEAD -const READ_PAUSED_NO_READ_AHEAD = MAX ^ READ_RESUMED_READ_AHEAD +const READ_PUSHED = MAX ^ READ_NEEDS_PUSH +const READ_PAUSED = MAX ^ READ_RESUMED +const READ_NOT_QUEUED = MAX ^ (READ_QUEUED | READ_EMITTED_READABLE) +const READ_NOT_ENDING = MAX ^ READ_ENDING +const READ_PIPE_NOT_DRAINED = MAX ^ READ_FLOWING +const READ_NOT_NEXT_TICK = MAX ^ READ_NEXT_TICK +const READ_NOT_UPDATING = MAX ^ READ_UPDATING +const READ_NO_READ_AHEAD = MAX ^ READ_READ_AHEAD +const READ_PAUSED_NO_READ_AHEAD = MAX ^ READ_RESUMED_READ_AHEAD // Write state (18 bit offset, 4 bit offset from shared state and 14 from read state) -const WRITE_ACTIVE = 0b00000000001 << 18 -const WRITE_UPDATING = 0b00000000010 << 18 -const WRITE_PRIMARY = 0b00000000100 << 18 -const WRITE_QUEUED = 0b00000001000 << 18 -const WRITE_UNDRAINED = 0b00000010000 << 18 -const WRITE_DONE = 0b00000100000 << 18 +const WRITE_ACTIVE = 0b00000000001 << 18 +const WRITE_UPDATING = 0b00000000010 << 18 +const WRITE_PRIMARY = 0b00000000100 << 18 +const WRITE_QUEUED = 0b00000001000 << 18 +const WRITE_UNDRAINED = 0b00000010000 << 18 +const WRITE_DONE = 0b00000100000 << 18 const WRITE_EMIT_DRAIN = 0b00001000000 << 18 -const WRITE_NEXT_TICK = 0b00010000000 << 18 -const WRITE_WRITING = 0b00100000000 << 18 -const WRITE_FINISHING = 0b01000000000 << 18 -const WRITE_CORKED = 0b10000000000 << 18 +const WRITE_NEXT_TICK = 0b00010000000 << 18 +const WRITE_WRITING = 0b00100000000 << 18 +const WRITE_FINISHING = 0b01000000000 << 18 +const WRITE_CORKED = 0b10000000000 << 18 -const WRITE_NOT_ACTIVE = MAX ^ (WRITE_ACTIVE | WRITE_WRITING) -const WRITE_NON_PRIMARY = MAX ^ WRITE_PRIMARY +const WRITE_NOT_ACTIVE = MAX ^ (WRITE_ACTIVE | WRITE_WRITING) +const WRITE_NON_PRIMARY = MAX ^ WRITE_PRIMARY const WRITE_NOT_FINISHING = MAX ^ (WRITE_ACTIVE | WRITE_FINISHING) -const WRITE_DRAINED = MAX ^ WRITE_UNDRAINED -const WRITE_NOT_QUEUED = MAX ^ WRITE_QUEUED +const WRITE_DRAINED = MAX ^ WRITE_UNDRAINED +const WRITE_NOT_QUEUED = MAX ^ WRITE_QUEUED const WRITE_NOT_NEXT_TICK = MAX ^ WRITE_NEXT_TICK -const WRITE_NOT_UPDATING = MAX ^ WRITE_UPDATING -const WRITE_NOT_CORKED = MAX ^ WRITE_CORKED +const WRITE_NOT_UPDATING = MAX ^ WRITE_UPDATING +const WRITE_NOT_CORKED = MAX ^ WRITE_CORKED // Combined shared state const ACTIVE = READ_ACTIVE | WRITE_ACTIVE @@ -42669,7 +42646,8 @@ const READ_PRIMARY_STATUS = OPEN_STATUS | READ_ENDING | READ_DONE const READ_STATUS = OPEN_STATUS | READ_DONE | READ_QUEUED const READ_ENDING_STATUS = OPEN_STATUS | READ_ENDING | READ_QUEUED const READ_READABLE_STATUS = OPEN_STATUS | READ_EMIT_READABLE | READ_QUEUED | READ_EMITTED_READABLE -const SHOULD_NOT_READ = OPEN_STATUS | READ_ACTIVE | READ_ENDING | READ_DONE | READ_NEEDS_PUSH | READ_READ_AHEAD +const SHOULD_NOT_READ = + OPEN_STATUS | READ_ACTIVE | READ_ENDING | READ_DONE | READ_NEEDS_PUSH | READ_READ_AHEAD const READ_BACKPRESSURE_STATUS = DESTROY_STATUS | READ_ENDING | READ_DONE const READ_UPDATE_SYNC_STATUS = READ_UPDATING | OPEN_STATUS | READ_NEXT_TICK | READ_PRIMARY const READ_NEXT_TICK_OR_OPENING = READ_NEXT_TICK | OPENING @@ -42690,7 +42668,10 @@ const WRITE_DROP_DATA = WRITE_FINISHING | WRITE_DONE | DESTROY_STATUS const asyncIterator = Symbol.asyncIterator || Symbol('asyncIterator') class WritableState { - constructor (stream, { highWaterMark = 16384, map = null, mapWritable, byteLength, byteLengthWritable } = {}) { + constructor( + stream, + { highWaterMark = 16384, map = null, mapWritable, byteLength, byteLengthWritable } = {} + ) { this.stream = stream this.queue = new FIFO() this.highWaterMark = highWaterMark @@ -42704,11 +42685,15 @@ class WritableState { this.afterUpdateNextTick = updateWriteNT.bind(this) } - get ended () { + get ending() { + return (this.stream._duplexState & WRITE_FINISHING) !== 0 + } + + get ended() { return (this.stream._duplexState & WRITE_DONE) !== 0 } - push (data) { + push(data) { if ((this.stream._duplexState & WRITE_DROP_DATA) !== 0) return false if (this.map !== null) data = this.map(data) @@ -42724,7 +42709,7 @@ class WritableState { return false } - shift () { + shift() { const data = this.queue.shift() this.buffered -= this.byteLength(data) @@ -42733,13 +42718,17 @@ class WritableState { return data } - end (data) { - if (typeof data === 'function') this.stream.once('finish', data) - else if (data !== undefined && data !== null) this.push(data) + end(data) { + if (typeof data === 'function') { + this.stream.once('finish', data) + } else if (data !== undefined && data !== null) { + this.push(data) + } + this.stream._duplexState = (this.stream._duplexState | WRITE_FINISHING) & WRITE_NON_PRIMARY } - autoBatch (data, cb) { + autoBatch(data, cb) { const buffer = [] const stream = this.stream @@ -42752,7 +42741,7 @@ class WritableState { stream._writev(buffer, cb) } - update () { + update() { const stream = this.stream stream._duplexState |= WRITE_UPDATING @@ -42770,7 +42759,7 @@ class WritableState { stream._duplexState &= WRITE_NOT_UPDATING } - updateNonPrimary () { + updateNonPrimary() { const stream = this.stream if ((stream._duplexState & WRITE_FINISHING_STATUS) === WRITE_FINISHING) { @@ -42793,18 +42782,21 @@ class WritableState { } } - continueUpdate () { + continueUpdate() { if ((this.stream._duplexState & WRITE_NEXT_TICK) === 0) return false this.stream._duplexState &= WRITE_NOT_NEXT_TICK return true } - updateCallback () { - if ((this.stream._duplexState & WRITE_UPDATE_SYNC_STATUS) === WRITE_PRIMARY) this.update() - else this.updateNextTick() + updateCallback() { + if ((this.stream._duplexState & WRITE_UPDATE_SYNC_STATUS) === WRITE_PRIMARY) { + this.update() + } else { + this.updateNextTick() + } } - updateNextTick () { + updateNextTick() { if ((this.stream._duplexState & WRITE_NEXT_TICK) !== 0) return this.stream._duplexState |= WRITE_NEXT_TICK if ((this.stream._duplexState & WRITE_UPDATING) === 0) qmt(this.afterUpdateNextTick) @@ -42812,7 +42804,10 @@ class WritableState { } class ReadableState { - constructor (stream, { highWaterMark = 16384, map = null, mapReadable, byteLength, byteLengthReadable } = {}) { + constructor( + stream, + { highWaterMark = 16384, map = null, mapReadable, byteLength, byteLengthReadable } = {} + ) { this.stream = stream this.queue = new FIFO() this.highWaterMark = highWaterMark === 0 ? 1 : highWaterMark @@ -42827,12 +42822,16 @@ class ReadableState { this.afterUpdateNextTick = updateReadNT.bind(this) } - get ended () { + get ending() { + return (this.stream._duplexState & READ_ENDING) !== 0 + } + + get ended() { return (this.stream._duplexState & READ_DONE) !== 0 } - pipe (pipeTo, cb) { - if (this.pipeTo !== null) throw new Error('Can only pipe to one destination') + pipe(pipeTo, cb) { + if (this.pipeTo !== null) throw StreamError.BAD_ARGUMENT('Can only pipe to one destination') if (typeof cb !== 'function') cb = null this.stream._duplexState |= READ_PIPE_DRAINED @@ -42858,7 +42857,7 @@ class ReadableState { pipeTo.emit('pipe', this.stream) } - push (data) { + push(data) { const stream = this.stream if (data === null) { @@ -42883,15 +42882,18 @@ class ReadableState { return this.buffered < this.highWaterMark } - shift () { + shift() { const data = this.queue.shift() this.buffered -= this.byteLength(data) - if (this.buffered === 0) this.stream._duplexState &= READ_NOT_QUEUED + if (this.buffered === 0) { + this.stream._duplexState &= READ_NOT_QUEUED + } + return data } - unshift (data) { + unshift(data) { const pending = [this.map !== null ? this.map(data) : data] while (this.buffered > 0) pending.push(this.shift()) @@ -42904,13 +42906,20 @@ class ReadableState { this.push(pending[pending.length - 1]) } - read () { + read() { const stream = this.stream if ((stream._duplexState & READ_STATUS) === READ_QUEUED) { const data = this.shift() - if (this.pipeTo !== null && this.pipeTo.write(data) === false) stream._duplexState &= READ_PIPE_NOT_DRAINED - if ((stream._duplexState & READ_EMIT_DATA) !== 0) stream.emit('data', data) + + if (this.pipeTo !== null && this.pipeTo.write(data) === false) { + stream._duplexState &= READ_PIPE_NOT_DRAINED + } + + if ((stream._duplexState & READ_EMIT_DATA) !== 0) { + stream.emit('data', data) + } + return data } @@ -42922,17 +42931,26 @@ class ReadableState { return null } - drain () { + drain() { const stream = this.stream - while ((stream._duplexState & READ_STATUS) === READ_QUEUED && (stream._duplexState & READ_FLOWING) !== 0) { + while ( + (stream._duplexState & READ_STATUS) === READ_QUEUED && + (stream._duplexState & READ_FLOWING) !== 0 + ) { const data = this.shift() - if (this.pipeTo !== null && this.pipeTo.write(data) === false) stream._duplexState &= READ_PIPE_NOT_DRAINED - if ((stream._duplexState & READ_EMIT_DATA) !== 0) stream.emit('data', data) + + if (this.pipeTo !== null && this.pipeTo.write(data) === false) { + stream._duplexState &= READ_PIPE_NOT_DRAINED + } + + if ((stream._duplexState & READ_EMIT_DATA) !== 0) { + stream.emit('data', data) + } } } - update () { + update() { const stream = this.stream stream._duplexState |= READ_UPDATING @@ -42940,7 +42958,10 @@ class ReadableState { do { this.drain() - while (this.buffered < this.highWaterMark && (stream._duplexState & SHOULD_NOT_READ) === READ_READ_AHEAD) { + while ( + this.buffered < this.highWaterMark && + (stream._duplexState & SHOULD_NOT_READ) === READ_READ_AHEAD + ) { stream._duplexState |= READ_ACTIVE_AND_NEEDS_PUSH stream._read(this.afterRead) this.drain() @@ -42951,20 +42972,28 @@ class ReadableState { stream.emit('readable') } - if ((stream._duplexState & READ_PRIMARY_AND_ACTIVE) === 0) this.updateNonPrimary() + if ((stream._duplexState & READ_PRIMARY_AND_ACTIVE) === 0) { + this.updateNonPrimary() + } } while (this.continueUpdate() === true) stream._duplexState &= READ_NOT_UPDATING } - updateNonPrimary () { + updateNonPrimary() { const stream = this.stream if ((stream._duplexState & READ_ENDING_STATUS) === READ_ENDING) { stream._duplexState = (stream._duplexState | READ_DONE) & READ_NOT_ENDING stream.emit('end') - if ((stream._duplexState & AUTO_DESTROY) === DONE) stream._duplexState |= DESTROYING - if (this.pipeTo !== null) this.pipeTo.end() + + if ((stream._duplexState & AUTO_DESTROY) === DONE) { + stream._duplexState |= DESTROYING + } + + if (this.pipeTo !== null) { + this.pipeTo.end() + } } if ((stream._duplexState & DESTROY_STATUS) === DESTROYING) { @@ -42981,24 +43010,27 @@ class ReadableState { } } - continueUpdate () { + continueUpdate() { if ((this.stream._duplexState & READ_NEXT_TICK) === 0) return false this.stream._duplexState &= READ_NOT_NEXT_TICK return true } - updateCallback () { - if ((this.stream._duplexState & READ_UPDATE_SYNC_STATUS) === READ_PRIMARY) this.update() - else this.updateNextTick() + updateCallback() { + if ((this.stream._duplexState & READ_UPDATE_SYNC_STATUS) === READ_PRIMARY) { + this.update() + } else { + this.updateNextTick() + } } - updateNextTickIfOpen () { + updateNextTickIfOpen() { if ((this.stream._duplexState & READ_NEXT_TICK_OR_OPENING) !== 0) return this.stream._duplexState |= READ_NEXT_TICK if ((this.stream._duplexState & READ_UPDATING) === 0) qmt(this.afterUpdateNextTick) } - updateNextTick () { + updateNextTick() { if ((this.stream._duplexState & READ_NEXT_TICK) !== 0) return this.stream._duplexState |= READ_NEXT_TICK if ((this.stream._duplexState & READ_UPDATING) === 0) qmt(this.afterUpdateNextTick) @@ -43006,7 +43038,7 @@ class ReadableState { } class TransformState { - constructor (stream) { + constructor(stream) { this.data = null this.afterTransform = afterTransform.bind(stream) this.afterFinal = null @@ -43014,7 +43046,7 @@ class TransformState { } class Pipeline { - constructor (src, dst, cb) { + constructor(src, dst, cb) { this.from = src this.to = dst this.afterPipe = cb @@ -43022,11 +43054,11 @@ class Pipeline { this.pipeToFinished = false } - finished () { + finished() { this.pipeToFinished = true } - done (stream, err) { + done(stream, err) { if (err) this.error = err if (stream === this.to) { @@ -43034,7 +43066,7 @@ class Pipeline { if (this.from !== null) { if ((this.from._duplexState & READ_DONE) === 0 || !this.pipeToFinished) { - this.from.destroy(this.error || new Error('Writable stream closed prematurely')) + this.from.destroy(this.error || StreamError.PREMATURE_CLOSE('Writable stream closed')) } return } @@ -43045,7 +43077,7 @@ class Pipeline { if (this.to !== null) { if ((stream._duplexState & READ_DONE) === 0) { - this.to.destroy(this.error || new Error('Readable stream closed before ending')) + this.to.destroy(this.error || StreamError.PREMATURE_CLOSE('Readable stream closed')) } return } @@ -43056,18 +43088,20 @@ class Pipeline { } } -function afterDrain () { +function afterDrain() { this.stream._duplexState |= READ_PIPE_DRAINED this.updateCallback() } -function afterFinal (err) { +function afterFinal(err) { const stream = this.stream if (err) stream.destroy(err) + if ((stream._duplexState & DESTROY_STATUS) === 0) { stream._duplexState |= WRITE_DONE stream.emit('finish') } + if ((stream._duplexState & AUTO_DESTROY) === DONE) { stream._duplexState |= DESTROYING } @@ -43075,30 +43109,41 @@ function afterFinal (err) { stream._duplexState &= WRITE_NOT_FINISHING // no need to wait the extra tick here, so we short circuit that - if ((stream._duplexState & WRITE_UPDATING) === 0) this.update() - else this.updateNextTick() + if ((stream._duplexState & WRITE_UPDATING) === 0) { + this.update() + } else { + this.updateNextTick() + } } -function afterDestroy (err) { +function afterDestroy(err) { const stream = this.stream - if (!err && this.error !== STREAM_DESTROYED) err = this.error + if (!err && !StreamError.isStreamDestroyed(this.error)) err = this.error if (err) stream.emit('error', err) + stream._duplexState |= DESTROYED stream.emit('close') const rs = stream._readableState const ws = stream._writableState - if (rs !== null && rs.pipeline !== null) rs.pipeline.done(stream, err) + if (rs !== null && rs.pipeline !== null) { + rs.pipeline.done(stream, err) + } if (ws !== null) { - while (ws.drains !== null && ws.drains.length > 0) ws.drains.shift().resolve(false) - if (ws.pipeline !== null) ws.pipeline.done(stream, err) + while (ws.drains !== null && ws.drains.length > 0) { + ws.drains.shift().resolve(false) + } + + if (ws.pipeline !== null) { + ws.pipeline.done(stream, err) + } } } -function afterWrite (err) { +function afterWrite(err) { const stream = this.stream if (err) stream.destroy(err) @@ -43108,6 +43153,7 @@ function afterWrite (err) { if ((stream._duplexState & WRITE_DRAIN_STATUS) === WRITE_UNDRAINED) { stream._duplexState &= WRITE_DRAINED + if ((stream._duplexState & WRITE_EMIT_DRAIN) === WRITE_EMIT_DRAIN) { stream.emit('drain') } @@ -43116,28 +43162,32 @@ function afterWrite (err) { this.updateCallback() } -function afterRead (err) { +function afterRead(err) { if (err) this.stream.destroy(err) this.stream._duplexState &= READ_NOT_ACTIVE - if (this.readAhead === false && (this.stream._duplexState & READ_RESUMED) === 0) this.stream._duplexState &= READ_NO_READ_AHEAD + + if (this.readAhead === false && (this.stream._duplexState & READ_RESUMED) === 0) { + this.stream._duplexState &= READ_NO_READ_AHEAD + } + this.updateCallback() } -function updateReadNT () { +function updateReadNT() { if ((this.stream._duplexState & READ_UPDATING) === 0) { this.stream._duplexState &= READ_NOT_NEXT_TICK this.update() } } -function updateWriteNT () { +function updateWriteNT() { if ((this.stream._duplexState & WRITE_UPDATING) === 0) { this.stream._duplexState &= WRITE_NOT_NEXT_TICK this.update() } } -function tickDrains (drains) { +function tickDrains(drains) { for (let i = 0; i < drains.length; i++) { // drains.writes are monotonic, so if one is 0 its always the first one if (--drains[i].writes === 0) { @@ -43147,14 +43197,20 @@ function tickDrains (drains) { } } -function afterOpen (err) { +function afterOpen(err) { const stream = this.stream if (err) stream.destroy(err) if ((stream._duplexState & DESTROYING) === 0) { - if ((stream._duplexState & READ_PRIMARY_STATUS) === 0) stream._duplexState |= READ_PRIMARY - if ((stream._duplexState & WRITE_PRIMARY_STATUS) === 0) stream._duplexState |= WRITE_PRIMARY + if ((stream._duplexState & READ_PRIMARY_STATUS) === 0) { + stream._duplexState |= READ_PRIMARY + } + + if ((stream._duplexState & WRITE_PRIMARY_STATUS) === 0) { + stream._duplexState |= WRITE_PRIMARY + } + stream.emit('open') } @@ -43169,15 +43225,15 @@ function afterOpen (err) { } } -function afterTransform (err, data) { +function afterTransform(err, data) { if (data !== undefined && data !== null) this.push(data) this._writableState.afterWrite(err) } -function newListener (name) { +function newListener(name) { if (this._readableState !== null) { if (name === 'data') { - this._duplexState |= (READ_EMIT_DATA | READ_RESUMED_READ_AHEAD) + this._duplexState |= READ_EMIT_DATA | READ_RESUMED_READ_AHEAD this._readableState.updateNextTick() } if (name === 'readable') { @@ -43195,7 +43251,7 @@ function newListener (name) { } class Stream extends EventEmitter { - constructor (opts) { + constructor(opts) { super() this._duplexState = 0 @@ -43206,51 +43262,50 @@ class Stream extends EventEmitter { if (opts.open) this._open = opts.open if (opts.destroy) this._destroy = opts.destroy if (opts.predestroy) this._predestroy = opts.predestroy - if (opts.signal) { - opts.signal.addEventListener('abort', abort.bind(this)) - } + if (opts.signal) opts.signal.addEventListener('abort', abort.bind(this)) } this.on('newListener', newListener) } - _open (cb) { + _open(cb) { cb(null) } - _destroy (cb) { + _destroy(cb) { cb(null) } - _predestroy () { + _predestroy() { // does nothing } - get readable () { + get readable() { return this._readableState !== null ? true : undefined } - get writable () { + get writable() { return this._writableState !== null ? true : undefined } - get destroyed () { + get destroyed() { return (this._duplexState & DESTROYED) !== 0 } - get destroying () { + get destroying() { return (this._duplexState & DESTROY_STATUS) !== 0 } - destroy (err) { + destroy(err) { if ((this._duplexState & DESTROY_STATUS) === 0) { - if (!err) err = STREAM_DESTROYED + if (!err) err = StreamError.STREAM_DESTROYED() this._duplexState = (this._duplexState | DESTROYING) & NON_PRIMARY if (this._readableState !== null) { this._readableState.highWaterMark = 0 this._readableState.error = err } + if (this._writableState !== null) { this._writableState.highWaterMark = 0 this._writableState.error = err @@ -43260,14 +43315,19 @@ class Stream extends EventEmitter { this._predestroy() this._duplexState &= NOT_PREDESTROYING - if (this._readableState !== null) this._readableState.updateNextTick() - if (this._writableState !== null) this._writableState.updateNextTick() + if (this._readableState !== null) { + this._readableState.updateNextTick() + } + + if (this._writableState !== null) { + this._writableState.updateNextTick() + } } } } class Readable extends Stream { - constructor (opts) { + constructor(opts) { super(opts) this._duplexState |= OPENING | WRITE_DONE | READ_READ_AHEAD @@ -43281,66 +43341,81 @@ class Readable extends Stream { } } - setEncoding (encoding) { + static deferred(fn, opts) { + const out = new PassThrough(opts) + + fn() + .then((src) => { + if (src === null) return out.end() + if (out.destroying) return + pipeline(src, out, noop) + }) + .catch((err) => out.destroy(err)) + + return out + } + + setEncoding(encoding) { const dec = new TextDecoder(encoding) const map = this._readableState.map || echo this._readableState.map = mapOrSkip return this - function mapOrSkip (data) { + function mapOrSkip(data) { const next = dec.push(data) return next === '' && (data.byteLength !== 0 || dec.remaining > 0) ? null : map(next) } } - _read (cb) { + _read(cb) { cb(null) } - pipe (dest, cb) { + pipe(dest, cb) { this._readableState.updateNextTick() this._readableState.pipe(dest, cb) return dest } - read () { + read() { this._readableState.updateNextTick() return this._readableState.read() } - push (data) { + push(data) { this._readableState.updateNextTickIfOpen() return this._readableState.push(data) } - unshift (data) { + unshift(data) { this._readableState.updateNextTickIfOpen() return this._readableState.unshift(data) } - resume () { + resume() { this._duplexState |= READ_RESUMED_READ_AHEAD this._readableState.updateNextTick() return this } - pause () { - this._duplexState &= (this._readableState.readAhead === false ? READ_PAUSED_NO_READ_AHEAD : READ_PAUSED) + pause() { + this._duplexState &= + this._readableState.readAhead === false ? READ_PAUSED_NO_READ_AHEAD : READ_PAUSED return this } - static _fromAsyncIterator (ite, opts) { + static _fromAsyncIterator(ite, opts) { let destroy const rs = new Readable({ ...opts, - read (cb) { + read(cb) { ite.next().then(push).then(cb.bind(null, null)).catch(cb) }, - predestroy () { + predestroy() { destroy = ite.return() }, - destroy (cb) { + destroy(cb) { if (!destroy) return cb(null) destroy.then(cb.bind(null, null)).catch(cb) } @@ -43348,13 +43423,13 @@ class Readable extends Stream { return rs - function push (data) { + function push(data) { if (data.done) rs.push(null) else rs.push(data.value) } } - static from (data, opts) { + static from(data, opts) { if (isReadStreamx(data)) return data if (data[asyncIterator]) return this._fromAsyncIterator(data[asyncIterator](), opts) if (!Array.isArray(data)) data = data === undefined ? [] : [data] @@ -43362,37 +43437,42 @@ class Readable extends Stream { let i = 0 return new Readable({ ...opts, - read (cb) { + read(cb) { this.push(i === data.length ? null : data[i++]) cb(null) } }) } - static isBackpressured (rs) { - return (rs._duplexState & READ_BACKPRESSURE_STATUS) !== 0 || rs._readableState.buffered >= rs._readableState.highWaterMark + static isBackpressured(rs) { + return ( + (rs._duplexState & READ_BACKPRESSURE_STATUS) !== 0 || + rs._readableState.buffered >= rs._readableState.highWaterMark + ) } - static isPaused (rs) { + static isPaused(rs) { return (rs._duplexState & READ_RESUMED) === 0 } - [asyncIterator] () { + [asyncIterator]() { const stream = this let error = null let promiseResolve = null let promiseReject = null - this.on('error', (err) => { error = err }) + this.on('error', (err) => { + error = err + }) this.on('readable', onreadable) this.on('close', onclose) return { - [asyncIterator] () { + [asyncIterator]() { return this }, - next () { + next() { return new Promise(function (resolve, reject) { promiseResolve = resolve promiseReject = reject @@ -43401,31 +43481,35 @@ class Readable extends Stream { else if ((stream._duplexState & DESTROYED) !== 0) ondata(null) }) }, - return () { + return() { return destroy(null) }, - throw (err) { + throw(err) { return destroy(err) } } - function onreadable () { + function onreadable() { if (promiseResolve !== null) ondata(stream.read()) } - function onclose () { + function onclose() { if (promiseResolve !== null) ondata(null) } - function ondata (data) { + function ondata(data) { if (promiseReject === null) return - if (error) promiseReject(error) - else if (data === null && (stream._duplexState & READ_DONE) === 0) promiseReject(STREAM_DESTROYED) - else promiseResolve({ value: data, done: data === null }) + if (error) { + promiseReject(error) + } else if (data === null && (stream._duplexState & READ_DONE) === 0) { + promiseReject(StreamError.STREAM_DESTROYED()) + } else { + promiseResolve({ value: data, done: data === null }) + } promiseReject = promiseResolve = null } - function destroy (err) { + function destroy(err) { stream.destroy(err) return new Promise((resolve, reject) => { if (stream._duplexState & DESTROYED) return resolve({ value: undefined, done: true }) @@ -43439,7 +43523,7 @@ class Readable extends Stream { } class Writable extends Stream { - constructor (opts) { + constructor(opts) { super(opts) this._duplexState |= OPENING | READ_DONE @@ -43453,57 +43537,60 @@ class Writable extends Stream { } } - cork () { + cork() { this._duplexState |= WRITE_CORKED } - uncork () { + uncork() { this._duplexState &= WRITE_NOT_CORKED this._writableState.updateNextTick() } - _writev (batch, cb) { + _writev(batch, cb) { cb(null) } - _write (data, cb) { + _write(data, cb) { this._writableState.autoBatch(data, cb) } - _final (cb) { + _final(cb) { cb(null) } - static isBackpressured (ws) { + static isBackpressured(ws) { return (ws._duplexState & WRITE_BACKPRESSURE_STATUS) !== 0 } - static drained (ws) { + static drained(ws) { if (ws.destroyed) return Promise.resolve(false) + const state = ws._writableState - const pending = (isWritev(ws) ? Math.min(1, state.queue.length) : state.queue.length) - const writes = pending + ((ws._duplexState & WRITE_WRITING) ? 1 : 0) + const pending = isWritev(ws) ? Math.min(1, state.queue.length) : state.queue.length + const writes = pending + (ws._duplexState & WRITE_WRITING ? 1 : 0) if (writes === 0) return Promise.resolve(true) + if (state.drains === null) state.drains = [] return new Promise((resolve) => { state.drains.push({ writes, resolve }) }) } - write (data) { + write(data) { this._writableState.updateNextTick() return this._writableState.push(data) } - end (data) { + end(data) { this._writableState.updateNextTick() this._writableState.end(data) return this } } -class Duplex extends Readable { // and Writable - constructor (opts) { +class Duplex extends Readable { + // and Writable + constructor(opts) { super(opts) this._duplexState = OPENING | (this._duplexState & READ_READ_AHEAD) @@ -43516,33 +43603,33 @@ class Duplex extends Readable { // and Writable } } - cork () { + cork() { this._duplexState |= WRITE_CORKED } - uncork () { + uncork() { this._duplexState &= WRITE_NOT_CORKED this._writableState.updateNextTick() } - _writev (batch, cb) { + _writev(batch, cb) { cb(null) } - _write (data, cb) { + _write(data, cb) { this._writableState.autoBatch(data, cb) } - _final (cb) { + _final(cb) { cb(null) } - write (data) { + write(data) { this._writableState.updateNextTick() return this._writableState.push(data) } - end (data) { + end(data) { this._writableState.updateNextTick() this._writableState.end(data) return this @@ -43550,7 +43637,7 @@ class Duplex extends Readable { // and Writable } class Transform extends Duplex { - constructor (opts) { + constructor(opts) { super(opts) this._transformState = new TransformState(this) @@ -43560,7 +43647,7 @@ class Transform extends Duplex { } } - _write (data, cb) { + _write(data, cb) { if (this._readableState.buffered >= this._readableState.highWaterMark) { this._transformState.data = data } else { @@ -43568,7 +43655,7 @@ class Transform extends Duplex { } } - _read (cb) { + _read(cb) { if (this._transformState.data !== null) { const data = this._transformState.data this._transformState.data = null @@ -43579,7 +43666,7 @@ class Transform extends Duplex { } } - destroy (err) { + destroy(err) { super.destroy(err) if (this._transformState.data !== null) { this._transformState.data = null @@ -43587,15 +43674,15 @@ class Transform extends Duplex { } } - _transform (data, cb) { + _transform(data, cb) { cb(null, data) } - _flush (cb) { + _flush(cb) { cb(null) } - _final (cb) { + _final(cb) { this._transformState.afterFinal = cb this._flush(transformAfterFlush.bind(this)) } @@ -43603,15 +43690,16 @@ class Transform extends Duplex { class PassThrough extends Transform {} -function transformAfterFlush (err, data) { +function transformAfterFlush(err, data) { const cb = this._transformState.afterFinal if (err) return cb(err) + if (data !== null && data !== undefined) this.push(data) this.push(null) cb(null) } -function pipelinePromise (...streams) { +function pipelinePromise(...streams) { return new Promise((resolve, reject) => { return pipeline(...streams, (err) => { if (err) return reject(err) @@ -43620,11 +43708,11 @@ function pipelinePromise (...streams) { }) } -function pipeline (stream, ...streams) { +function pipeline(stream, ...streams) { const all = Array.isArray(stream) ? [...stream, ...streams] : [stream, ...streams] - const done = (all.length && typeof all[all.length - 1] === 'function') ? all.pop() : null + const done = all.length && typeof all[all.length - 1] === 'function' ? all.pop() : null - if (all.length < 2) throw new Error('Pipeline requires at least 2 streams') + if (all.length < 2) throw StreamError.BAD_ARGUMENT('Pipeline requires at least 2 streams') let src = all[0] let dest = null @@ -43646,7 +43734,8 @@ function pipeline (stream, ...streams) { if (done) { let fin = false - const autoDestroy = isStreamx(dest) || !!(dest._writableState && dest._writableState.autoDestroy) + const autoDestroy = + isStreamx(dest) || !!(dest._writableState && dest._writableState.autoDestroy) dest.on('error', (err) => { if (error === null) error = err @@ -43658,23 +43747,27 @@ function pipeline (stream, ...streams) { }) if (autoDestroy) { - dest.on('close', () => done(error || (fin ? null : PREMATURE_CLOSE))) + dest.on('close', () => done(error || (fin ? null : StreamError.PREMATURE_CLOSE()))) } } return dest - function errorHandle (s, rd, wr, onerror) { + function errorHandle(s, rd, wr, onerror) { s.on('error', onerror) s.on('close', onclose) - function onclose () { - if (rd && s._readableState && !s._readableState.ended) return onerror(PREMATURE_CLOSE) - if (wr && s._writableState && !s._writableState.ended) return onerror(PREMATURE_CLOSE) + function onclose() { + if (rd && s._readableState && !s._readableState.ended) { + return onerror(StreamError.PREMATURE_CLOSE()) + } + if (wr && s._writableState && !s._writableState.ended) { + return onerror(StreamError.PREMATURE_CLOSE()) + } } } - function onerror (err) { + function onerror(err) { if (!err || error) return error = err @@ -43684,56 +43777,70 @@ function pipeline (stream, ...streams) { } } -function echo (s) { +function echo(s) { return s } -function isStream (stream) { +function isStream(stream) { return !!stream._readableState || !!stream._writableState } -function isStreamx (stream) { +function isStreamx(stream) { return typeof stream._duplexState === 'number' && isStream(stream) } -function isEnded (stream) { +function isEnding(stream) { + return !!stream._readableState && stream._readableState.ending +} + +function isEnded(stream) { return !!stream._readableState && stream._readableState.ended } -function isFinished (stream) { +function isFinishing(stream) { + return !!stream._writableState && stream._writableState.ending +} + +function isFinished(stream) { return !!stream._writableState && stream._writableState.ended } -function getStreamError (stream, opts = {}) { - const err = (stream._readableState && stream._readableState.error) || (stream._writableState && stream._writableState.error) +function getStreamError(stream, opts = {}) { + const err = + (stream._readableState && stream._readableState.error) || + (stream._writableState && stream._writableState.error) // avoid implicit errors by default - return (!opts.all && err === STREAM_DESTROYED) ? null : err + return !opts.all && StreamError.isStreamDestroyed(err) ? null : err } -function isReadStreamx (stream) { +function isReadStreamx(stream) { return isStreamx(stream) && stream.readable } -function isDisturbed (stream) { - return (stream._duplexState & OPENING) !== OPENING || (stream._duplexState & ACTIVE_OR_TICKING) !== 0 +function isDisturbed(stream) { + return ( + (stream._duplexState & OPENING) !== OPENING || + (stream._duplexState & DESTROYING) === DESTROYING || + (stream._duplexState & ACTIVE_OR_TICKING) !== 0 + ) } -function isTypedArray (data) { +function isTypedArray(data) { return typeof data === 'object' && data !== null && typeof data.byteLength === 'number' } -function defaultByteLength (data) { +function defaultByteLength(data) { return isTypedArray(data) ? data.byteLength : 1024 } -function noop () {} +function noop() {} -function abort () { - this.destroy(new Error('Stream aborted.')) +function abort() { + this.destroy(StreamError.ABORTED()) } -function isWritev (s) { +function isWritev(s) { return s._writev !== Writable.prototype._writev && s._writev !== Duplex.prototype._writev } @@ -43742,7 +43849,9 @@ module.exports = { pipelinePromise, isStream, isStreamx, + isEnding, isEnded, + isFinishing, isFinished, isDisturbed, getStreamError, @@ -43758,7 +43867,61 @@ module.exports = { /***/ }), -/***/ 80634: +/***/ 15586: +/***/ ((module) => { + +module.exports = class StreamError extends Error { + constructor(msg, code, fn = StreamError) { + super(msg) + + this.code = code + + if (Error.captureStackTrace) { + Error.captureStackTrace(this, fn) + } + } + + static isStreamDestroyed(err) { + return err && err.code === 'STREAM_DESTROYED' + } + + static isPrematureClose(err) { + return err && err.code === 'PREMATURE_CLOSE' + } + + static isAborted(err) { + return err && err.code === 'ABORTED' + } + + static isBadArgument(err) { + return err && err.code === 'BAD_ARGUMENT' + } + + get name() { + return 'StreamError' + } + + static STREAM_DESTROYED() { + return new StreamError('Stream was destroyed', 'STREAM_DESTROYED', StreamError.STREAM_DESTROYED) + } + + static PREMATURE_CLOSE(msg = 'Premature close') { + return new StreamError(msg, 'PREMATURE_CLOSE', StreamError.PREMATURE_CLOSE) + } + + static ABORTED() { + return new StreamError('Stream aborted', 'ABORTED', StreamError.ABORTED) + } + + static BAD_ARGUMENT(msg = 'Bad argument') { + return new StreamError(msg, 'BAD_ARGUMENT', StreamError.BAD_ARGUMENT) + } +} + + +/***/ }), + +/***/ 8112: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { // Copyright Joyent, Inc. and other Node contributors. @@ -43786,7 +43949,309 @@ module.exports = { /**/ -var Buffer = (__nccwpck_require__(93058).Buffer); +var Buffer = (__nccwpck_require__(79253).Buffer); +/**/ + +var isEncoding = Buffer.isEncoding || function (encoding) { + encoding = '' + encoding; + switch (encoding && encoding.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 true; + default: + return false; + } +}; + +function _normalizeEncoding(enc) { + if (!enc) return 'utf8'; + var retried; + while (true) { + switch (enc) { + 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 enc; + default: + if (retried) return; // undefined + enc = ('' + enc).toLowerCase(); + retried = true; + } + } +}; + +// Do not cache `Buffer.isEncoding` when checking encoding names as some +// modules monkey-patch it to support additional encodings +function normalizeEncoding(enc) { + var nenc = _normalizeEncoding(enc); + if (typeof nenc !== 'string' && (Buffer.isEncoding === isEncoding || !isEncoding(enc))) throw new Error('Unknown encoding: ' + enc); + return nenc || enc; +} + +// StringDecoder provides an interface for efficiently splitting a series of +// buffers into a series of JS strings without breaking apart multi-byte +// characters. +exports.I = StringDecoder; +function StringDecoder(encoding) { + this.encoding = normalizeEncoding(encoding); + var nb; + switch (this.encoding) { + case 'utf16le': + this.text = utf16Text; + this.end = utf16End; + nb = 4; + break; + case 'utf8': + this.fillLast = utf8FillLast; + nb = 4; + break; + case 'base64': + this.text = base64Text; + this.end = base64End; + nb = 3; + break; + default: + this.write = simpleWrite; + this.end = simpleEnd; + return; + } + this.lastNeed = 0; + this.lastTotal = 0; + this.lastChar = Buffer.allocUnsafe(nb); +} + +StringDecoder.prototype.write = function (buf) { + if (buf.length === 0) return ''; + var r; + var i; + if (this.lastNeed) { + r = this.fillLast(buf); + if (r === undefined) return ''; + i = this.lastNeed; + this.lastNeed = 0; + } else { + i = 0; + } + if (i < buf.length) return r ? r + this.text(buf, i) : this.text(buf, i); + return r || ''; +}; + +StringDecoder.prototype.end = utf8End; + +// Returns only complete characters in a Buffer +StringDecoder.prototype.text = utf8Text; + +// Attempts to complete a partial non-UTF-8 character using bytes from a Buffer +StringDecoder.prototype.fillLast = function (buf) { + if (this.lastNeed <= buf.length) { + buf.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, this.lastNeed); + return this.lastChar.toString(this.encoding, 0, this.lastTotal); + } + buf.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, buf.length); + this.lastNeed -= buf.length; +}; + +// Checks the type of a UTF-8 byte, whether it's ASCII, a leading byte, or a +// continuation byte. If an invalid byte is detected, -2 is returned. +function utf8CheckByte(byte) { + if (byte <= 0x7F) return 0;else if (byte >> 5 === 0x06) return 2;else if (byte >> 4 === 0x0E) return 3;else if (byte >> 3 === 0x1E) return 4; + return byte >> 6 === 0x02 ? -1 : -2; +} + +// Checks at most 3 bytes at the end of a Buffer in order to detect an +// incomplete multi-byte UTF-8 character. The total number of bytes (2, 3, or 4) +// needed to complete the UTF-8 character (if applicable) are returned. +function utf8CheckIncomplete(self, buf, i) { + var j = buf.length - 1; + if (j < i) return 0; + var nb = utf8CheckByte(buf[j]); + if (nb >= 0) { + if (nb > 0) self.lastNeed = nb - 1; + return nb; + } + if (--j < i || nb === -2) return 0; + nb = utf8CheckByte(buf[j]); + if (nb >= 0) { + if (nb > 0) self.lastNeed = nb - 2; + return nb; + } + if (--j < i || nb === -2) return 0; + nb = utf8CheckByte(buf[j]); + if (nb >= 0) { + if (nb > 0) { + if (nb === 2) nb = 0;else self.lastNeed = nb - 3; + } + return nb; + } + return 0; +} + +// Validates as many continuation bytes for a multi-byte UTF-8 character as +// needed or are available. If we see a non-continuation byte where we expect +// one, we "replace" the validated continuation bytes we've seen so far with +// a single UTF-8 replacement character ('\ufffd'), to match v8's UTF-8 decoding +// behavior. The continuation byte check is included three times in the case +// where all of the continuation bytes for a character exist in the same buffer. +// It is also done this way as a slight performance increase instead of using a +// loop. +function utf8CheckExtraBytes(self, buf, p) { + if ((buf[0] & 0xC0) !== 0x80) { + self.lastNeed = 0; + return '\ufffd'; + } + if (self.lastNeed > 1 && buf.length > 1) { + if ((buf[1] & 0xC0) !== 0x80) { + self.lastNeed = 1; + return '\ufffd'; + } + if (self.lastNeed > 2 && buf.length > 2) { + if ((buf[2] & 0xC0) !== 0x80) { + self.lastNeed = 2; + return '\ufffd'; + } + } + } +} + +// Attempts to complete a multi-byte UTF-8 character using bytes from a Buffer. +function utf8FillLast(buf) { + var p = this.lastTotal - this.lastNeed; + var r = utf8CheckExtraBytes(this, buf, p); + if (r !== undefined) return r; + if (this.lastNeed <= buf.length) { + buf.copy(this.lastChar, p, 0, this.lastNeed); + return this.lastChar.toString(this.encoding, 0, this.lastTotal); + } + buf.copy(this.lastChar, p, 0, buf.length); + this.lastNeed -= buf.length; +} + +// Returns all complete UTF-8 characters in a Buffer. If the Buffer ended on a +// partial character, the character's bytes are buffered until the required +// number of bytes are available. +function utf8Text(buf, i) { + var total = utf8CheckIncomplete(this, buf, i); + if (!this.lastNeed) return buf.toString('utf8', i); + this.lastTotal = total; + var end = buf.length - (total - this.lastNeed); + buf.copy(this.lastChar, 0, end); + return buf.toString('utf8', i, end); +} + +// For UTF-8, a replacement character is added when ending on a partial +// character. +function utf8End(buf) { + var r = buf && buf.length ? this.write(buf) : ''; + if (this.lastNeed) return r + '\ufffd'; + return r; +} + +// UTF-16LE typically needs two bytes per character, but even if we have an even +// number of bytes available, we need to check if we end on a leading/high +// surrogate. In that case, we need to wait for the next two bytes in order to +// decode the last character properly. +function utf16Text(buf, i) { + if ((buf.length - i) % 2 === 0) { + var r = buf.toString('utf16le', i); + if (r) { + var c = r.charCodeAt(r.length - 1); + if (c >= 0xD800 && c <= 0xDBFF) { + this.lastNeed = 2; + this.lastTotal = 4; + this.lastChar[0] = buf[buf.length - 2]; + this.lastChar[1] = buf[buf.length - 1]; + return r.slice(0, -1); + } + } + return r; + } + this.lastNeed = 1; + this.lastTotal = 2; + this.lastChar[0] = buf[buf.length - 1]; + return buf.toString('utf16le', i, buf.length - 1); +} + +// For UTF-16LE we do not explicitly append special replacement characters if we +// end on a partial character, we simply let v8 handle that. +function utf16End(buf) { + var r = buf && buf.length ? this.write(buf) : ''; + if (this.lastNeed) { + var end = this.lastTotal - this.lastNeed; + return r + this.lastChar.toString('utf16le', 0, end); + } + return r; +} + +function base64Text(buf, i) { + var n = (buf.length - i) % 3; + if (n === 0) return buf.toString('base64', i); + this.lastNeed = 3 - n; + this.lastTotal = 3; + if (n === 1) { + this.lastChar[0] = buf[buf.length - 1]; + } else { + this.lastChar[0] = buf[buf.length - 2]; + this.lastChar[1] = buf[buf.length - 1]; + } + return buf.toString('base64', i, buf.length - n); +} + +function base64End(buf) { + var r = buf && buf.length ? this.write(buf) : ''; + if (this.lastNeed) return r + this.lastChar.toString('base64', 0, 3 - this.lastNeed); + return r; +} + +// Pass bytes on through for single-byte encodings (e.g. ascii, latin1, hex) +function simpleWrite(buf) { + return buf.toString(this.encoding); +} + +function simpleEnd(buf) { + return buf && buf.length ? this.write(buf) : ''; +} + +/***/ }), + +/***/ 93243: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + + + +/**/ + +var Buffer = (__nccwpck_require__(65249).Buffer); /**/ var isEncoding = Buffer.isEncoding || function (encoding) { @@ -44060,7 +44525,7 @@ function simpleEnd(buf) { /***/ }), -/***/ 20775: +/***/ 45953: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { const constants = { // just for envs without fs @@ -44081,15 +44546,16 @@ try { /***/ }), -/***/ 35763: +/***/ 42309: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { Writable, Readable, getStreamError } = __nccwpck_require__(36204) -const FIFO = __nccwpck_require__(83867) -const b4a = __nccwpck_require__(73057) -const headers = __nccwpck_require__(88428) +const { Writable, Readable, getStreamError } = __nccwpck_require__(69045) +const FIFO = __nccwpck_require__(19597) +const b4a = __nccwpck_require__(82901) +const headers = __nccwpck_require__(45374) const EMPTY = b4a.alloc(0) +const MAX_HEADER_SIZE = 4 * 1024 * 1024 // arbitrary big number class BufferList { constructor () { @@ -44106,7 +44572,7 @@ class BufferList { } shiftFirst (size) { - return this._buffered === 0 ? null : this._next(size) + return this.buffered === 0 ? null : this._next(size) } shift (size) { @@ -44235,6 +44701,8 @@ class Extract extends Writable { if (!this._header) return true + this._header.byteOffset = this._buffer.shifted + switch (this._header.type) { case 'gnu-long-path': case 'gnu-long-link-path': @@ -44242,12 +44710,21 @@ class Extract extends Writable { case 'pax-header': this._longHeader = true this._missing = this._header.size + if (this._missing > MAX_HEADER_SIZE) { + this._continueWrite(new Error('Header exceeds max size')) + return false + } return true } this._locked = true this._applyLongHeaders() + if (!(this._header.size >= 0)) { + this._continueWrite(new Error('Invalid header')) + return false + } + if (this._header.size === 0 || this._header.type === 'directory') { this.emit('entry', this._header, this._createStream(), this._unlockBound) return true @@ -44494,10 +44971,10 @@ function overflow (size) { /***/ }), -/***/ 88428: +/***/ 45374: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { -const b4a = __nccwpck_require__(73057) +const b4a = __nccwpck_require__(82901) const ZEROS = '0000000000000000000' const SEVENS = '7777777777777777777' @@ -44636,6 +45113,7 @@ exports.decode = function decode (buf, filenameEncoding, allowUnknownFormat) { uid, gid, size, + byteOffset: 0, mtime: new Date(1000 * mtime), type, linkname, @@ -44822,23 +45300,23 @@ function addLength (str) { /***/ }), -/***/ 56118: +/***/ 54620: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { -exports.extract = __nccwpck_require__(35763) -exports.pack = __nccwpck_require__(80861) +exports.extract = __nccwpck_require__(42309) +exports.pack = __nccwpck_require__(60779) /***/ }), -/***/ 80861: +/***/ 60779: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { Readable, Writable, getStreamError } = __nccwpck_require__(36204) -const b4a = __nccwpck_require__(73057) +const { Readable, Writable, getStreamError } = __nccwpck_require__(69045) +const b4a = __nccwpck_require__(82901) -const constants = __nccwpck_require__(20775) -const headers = __nccwpck_require__(88428) +const constants = __nccwpck_require__(45953) +const headers = __nccwpck_require__(45374) const DMODE = 0o755 const FMODE = 0o644 @@ -45125,14 +45603,14 @@ function mapWritable (buf) { /***/ }), -/***/ 97934: +/***/ 45795: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const PassThroughDecoder = __nccwpck_require__(47256) -const UTF8Decoder = __nccwpck_require__(86414) +const PassThroughDecoder = __nccwpck_require__(38983) +const UTF8Decoder = __nccwpck_require__(77457) module.exports = class TextDecoder { - constructor (encoding = 'utf8') { + constructor(encoding = 'utf8') { this.encoding = normalizeEncoding(encoding) switch (this.encoding) { @@ -45147,21 +45625,21 @@ module.exports = class TextDecoder { } } - get remaining () { + get remaining() { return this.decoder.remaining } - push (data) { + push(data) { if (typeof data === 'string') return data return this.decoder.decode(data) } // For Node.js compatibility - write (data) { + write(data) { return this.push(data) } - end (data) { + end(data) { let result = '' if (data) result = this.push(data) result += this.decoder.flush() @@ -45169,7 +45647,7 @@ module.exports = class TextDecoder { } } -function normalizeEncoding (encoding) { +function normalizeEncoding(encoding) { encoding = encoding.toLowerCase() switch (encoding) { @@ -45191,30 +45669,30 @@ function normalizeEncoding (encoding) { default: throw new Error('Unknown encoding: ' + encoding) } -}; +} /***/ }), -/***/ 47256: +/***/ 38983: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const b4a = __nccwpck_require__(73057) +const b4a = __nccwpck_require__(82901) module.exports = class PassThroughDecoder { - constructor (encoding) { + constructor(encoding) { this.encoding = encoding } - get remaining () { + get remaining() { return 0 } - decode (tail) { - return b4a.toString(tail, this.encoding) + decode(data) { + return b4a.toString(data, this.encoding) } - flush () { + flush() { return '' } } @@ -45222,79 +45700,100 @@ module.exports = class PassThroughDecoder { /***/ }), -/***/ 86414: +/***/ 77457: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const b4a = __nccwpck_require__(73057) +const b4a = __nccwpck_require__(82901) /** * https://encoding.spec.whatwg.org/#utf-8-decoder */ module.exports = class UTF8Decoder { - constructor () { - this.codePoint = 0 - this.bytesSeen = 0 - this.bytesNeeded = 0 - this.lowerBoundary = 0x80 - this.upperBoundary = 0xbf + constructor() { + this._reset() } - get remaining () { + get remaining() { return this.bytesSeen } - decode (data) { - // If we have a fast path, just sniff if the last part is a boundary - if (this.bytesNeeded === 0) { - let isBoundary = true + decode(data) { + if (data.byteLength === 0) return '' - for (let i = Math.max(0, data.byteLength - 4), n = data.byteLength; i < n && isBoundary; i++) { - isBoundary = data[i] <= 0x7f + if (this.bytesNeeded === 0 && trailingIncomplete(data, 0) === 0) { + this.bytesSeen = trailingBytesSeen(data) + return b4a.toString(data, 'utf8') + } + + let result = '' + let start = 0 + + if (this.bytesNeeded > 0) { + while (start < data.byteLength) { + const byte = data[start] + + if (byte < this.lowerBoundary || byte > this.upperBoundary) { + result += '\ufffd' + this._reset() + break + } + + this.lowerBoundary = 0x80 + this.upperBoundary = 0xbf + this.codePoint = (this.codePoint << 6) | (byte & 0x3f) + this.bytesSeen++ + start++ + + if (this.bytesSeen === this.bytesNeeded) { + result += String.fromCodePoint(this.codePoint) + this._reset() + break + } } - if (isBoundary) return b4a.toString(data, 'utf8') + if (this.bytesNeeded > 0) return result } - let result = '' + const trailing = trailingIncomplete(data, start) + const end = data.byteLength - trailing + + if (end > start) result += b4a.toString(data, 'utf8', start, end) - for (let i = 0, n = data.byteLength; i < n; i++) { + for (let i = end; i < data.byteLength; i++) { const byte = data[i] if (this.bytesNeeded === 0) { if (byte <= 0x7f) { + this.bytesSeen = 0 result += String.fromCharCode(byte) + } else if (byte >= 0xc2 && byte <= 0xdf) { + this.bytesNeeded = 2 + this.bytesSeen = 1 + this.codePoint = byte & 0x1f + } else if (byte >= 0xe0 && byte <= 0xef) { + if (byte === 0xe0) this.lowerBoundary = 0xa0 + else if (byte === 0xed) this.upperBoundary = 0x9f + this.bytesNeeded = 3 + this.bytesSeen = 1 + this.codePoint = byte & 0xf + } else if (byte >= 0xf0 && byte <= 0xf4) { + if (byte === 0xf0) this.lowerBoundary = 0x90 + else if (byte === 0xf4) this.upperBoundary = 0x8f + this.bytesNeeded = 4 + this.bytesSeen = 1 + this.codePoint = byte & 0x7 } else { this.bytesSeen = 1 - - if (byte >= 0xc2 && byte <= 0xdf) { - this.bytesNeeded = 2 - this.codePoint = byte & 0x1f - } else if (byte >= 0xe0 && byte <= 0xef) { - if (byte === 0xe0) this.lowerBoundary = 0xa0 - else if (byte === 0xed) this.upperBoundary = 0x9f - this.bytesNeeded = 3 - this.codePoint = byte & 0xf - } else if (byte >= 0xf0 && byte <= 0xf4) { - if (byte === 0xf0) this.lowerBoundary = 0x90 - if (byte === 0xf4) this.upperBoundary = 0x8f - this.bytesNeeded = 4 - this.codePoint = byte & 0x7 - } else { - result += '\ufffd' - } + result += '\ufffd' } continue } if (byte < this.lowerBoundary || byte > this.upperBoundary) { - this.codePoint = 0 - this.bytesNeeded = 0 - this.bytesSeen = 0 - this.lowerBoundary = 0x80 - this.upperBoundary = 0xbf - result += '\ufffd' + i-- + this._reset() continue } @@ -45305,35 +45804,95 @@ module.exports = class UTF8Decoder { this.codePoint = (this.codePoint << 6) | (byte & 0x3f) this.bytesSeen++ - if (this.bytesSeen !== this.bytesNeeded) continue - - result += String.fromCodePoint(this.codePoint) - - this.codePoint = 0 - this.bytesNeeded = 0 - this.bytesSeen = 0 + if (this.bytesSeen === this.bytesNeeded) { + result += String.fromCodePoint(this.codePoint) + this._reset() + } } return result } - flush () { + flush() { const result = this.bytesNeeded > 0 ? '\ufffd' : '' + this._reset() + return result + } + _reset() { this.codePoint = 0 this.bytesNeeded = 0 this.bytesSeen = 0 this.lowerBoundary = 0x80 this.upperBoundary = 0xbf + } +} - return result +function trailingIncomplete(data, start) { + const len = data.byteLength + if (len <= start) return 0 + + const limit = Math.max(start, len - 4) + + let i = len - 1 + while (i > limit && (data[i] & 0xc0) === 0x80) i-- + + if (i < start) return 0 + + const byte = data[i] + + let needed + if (byte <= 0x7f) return 0 + if (byte >= 0xc2 && byte <= 0xdf) needed = 2 + else if (byte >= 0xe0 && byte <= 0xef) needed = 3 + else if (byte >= 0xf0 && byte <= 0xf4) needed = 4 + else return 0 + + const available = len - i + return available < needed ? available : 0 +} + +function trailingBytesSeen(data) { + const len = data.byteLength + if (len === 0) return 0 + + const last = data[len - 1] + + if (last <= 0x7f) return 0 + if ((last & 0xc0) !== 0x80) return 1 + + const limit = Math.max(0, len - 4) + + let i = len - 2 + while (i >= limit && (data[i] & 0xc0) === 0x80) i-- + + if (i < 0) return 1 + + const first = data[i] + + let needed + if (first >= 0xc2 && first <= 0xdf) needed = 2 + else if (first >= 0xe0 && first <= 0xef) needed = 3 + else if (first >= 0xf0 && first <= 0xf4) needed = 4 + else return 1 + + if (len - i !== needed) return 1 + + if (needed >= 3) { + const second = data[i + 1] + if (first === 0xe0 && second < 0xa0) return 1 + if (first === 0xed && second > 0x9f) return 1 + if (first === 0xf0 && second < 0x90) return 1 + if (first === 0xf4 && second > 0x8f) return 1 } + + return 0 } /***/ }), -/***/ 62958: +/***/ 47441: /***/ ((module) => { module.exports = Traverse; @@ -45662,15 +46221,15 @@ function copy (src) { /***/ }), -/***/ 20770: +/***/ 30329: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -module.exports = __nccwpck_require__(20218); +module.exports = __nccwpck_require__(44179); /***/ }), -/***/ 20218: +/***/ 44179: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { @@ -45941,33 +46500,33 @@ exports.debug = debug; // for test /***/ }), -/***/ 46752: +/***/ 51445: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const Client = __nccwpck_require__(23701) -const Dispatcher = __nccwpck_require__(30883) -const Pool = __nccwpck_require__(30628) -const BalancedPool = __nccwpck_require__(837) -const Agent = __nccwpck_require__(57405) -const ProxyAgent = __nccwpck_require__(76672) -const EnvHttpProxyAgent = __nccwpck_require__(53137) -const RetryAgent = __nccwpck_require__(30050) -const errors = __nccwpck_require__(68707) -const util = __nccwpck_require__(3440) +const Client = __nccwpck_require__(95548) +const Dispatcher = __nccwpck_require__(82414) +const Pool = __nccwpck_require__(67185) +const BalancedPool = __nccwpck_require__(35078) +const Agent = __nccwpck_require__(90754) +const ProxyAgent = __nccwpck_require__(58491) +const EnvHttpProxyAgent = __nccwpck_require__(97760) +const RetryAgent = __nccwpck_require__(94969) +const errors = __nccwpck_require__(61366) +const util = __nccwpck_require__(93865) const { InvalidArgumentError } = errors -const api = __nccwpck_require__(56615) -const buildConnector = __nccwpck_require__(59136) -const MockClient = __nccwpck_require__(47365) -const MockAgent = __nccwpck_require__(47501) -const MockPool = __nccwpck_require__(94004) -const mockErrors = __nccwpck_require__(52429) -const RetryHandler = __nccwpck_require__(17816) -const { getGlobalDispatcher, setGlobalDispatcher } = __nccwpck_require__(32581) -const DecoratorHandler = __nccwpck_require__(58155) -const RedirectHandler = __nccwpck_require__(8754) -const createRedirectInterceptor = __nccwpck_require__(25092) +const api = __nccwpck_require__(32390) +const buildConnector = __nccwpck_require__(70255) +const MockClient = __nccwpck_require__(15938) +const MockAgent = __nccwpck_require__(38292) +const MockPool = __nccwpck_require__(17695) +const mockErrors = __nccwpck_require__(86270) +const RetryHandler = __nccwpck_require__(67197) +const { getGlobalDispatcher, setGlobalDispatcher } = __nccwpck_require__(64010) +const DecoratorHandler = __nccwpck_require__(76006) +const RedirectHandler = __nccwpck_require__(75853) +const createRedirectInterceptor = __nccwpck_require__(2087) Object.assign(Dispatcher.prototype, api) @@ -45985,10 +46544,10 @@ module.exports.DecoratorHandler = DecoratorHandler module.exports.RedirectHandler = RedirectHandler module.exports.createRedirectInterceptor = createRedirectInterceptor module.exports.interceptors = { - redirect: __nccwpck_require__(21514), - retry: __nccwpck_require__(92026), - dump: __nccwpck_require__(88060), - dns: __nccwpck_require__(70379) + redirect: __nccwpck_require__(42969), + retry: __nccwpck_require__(83695), + dump: __nccwpck_require__(14743), + dns: __nccwpck_require__(22726) } module.exports.buildConnector = buildConnector @@ -46050,7 +46609,7 @@ function makeDispatcher (fn) { module.exports.setGlobalDispatcher = setGlobalDispatcher module.exports.getGlobalDispatcher = getGlobalDispatcher -const fetchImpl = (__nccwpck_require__(54398).fetch) +const fetchImpl = (__nccwpck_require__(4543).fetch) module.exports.fetch = async function fetch (init, options = undefined) { try { return await fetchImpl(init, options) @@ -46062,39 +46621,39 @@ module.exports.fetch = async function fetch (init, options = undefined) { throw err } } -module.exports.Headers = __nccwpck_require__(60660).Headers -module.exports.Response = __nccwpck_require__(99051).Response -module.exports.Request = __nccwpck_require__(9967).Request -module.exports.FormData = __nccwpck_require__(35910).FormData +module.exports.Headers = __nccwpck_require__(65841).Headers +module.exports.Response = __nccwpck_require__(26424).Response +module.exports.Request = __nccwpck_require__(55830).Request +module.exports.FormData = __nccwpck_require__(25069).FormData module.exports.File = globalThis.File ?? (__nccwpck_require__(4573).File) -module.exports.FileReader = __nccwpck_require__(48355).FileReader +module.exports.FileReader = __nccwpck_require__(95732).FileReader -const { setGlobalOrigin, getGlobalOrigin } = __nccwpck_require__(51059) +const { setGlobalOrigin, getGlobalOrigin } = __nccwpck_require__(68320) module.exports.setGlobalOrigin = setGlobalOrigin module.exports.getGlobalOrigin = getGlobalOrigin -const { CacheStorage } = __nccwpck_require__(3245) -const { kConstruct } = __nccwpck_require__(20109) +const { CacheStorage } = __nccwpck_require__(76734) +const { kConstruct } = __nccwpck_require__(93276) // Cache & CacheStorage are tightly coupled with fetch. Even if it may run // in an older version of Node, it doesn't have any use without fetch. module.exports.caches = new CacheStorage(kConstruct) -const { deleteCookie, getCookies, getSetCookies, setCookie } = __nccwpck_require__(79061) +const { deleteCookie, getCookies, getSetCookies, setCookie } = __nccwpck_require__(2724) module.exports.deleteCookie = deleteCookie module.exports.getCookies = getCookies module.exports.getSetCookies = getSetCookies module.exports.setCookie = setCookie -const { parseMIMEType, serializeAMimeType } = __nccwpck_require__(51900) +const { parseMIMEType, serializeAMimeType } = __nccwpck_require__(25859) module.exports.parseMIMEType = parseMIMEType module.exports.serializeAMimeType = serializeAMimeType -const { CloseEvent, ErrorEvent, MessageEvent } = __nccwpck_require__(15188) -module.exports.WebSocket = __nccwpck_require__(13726).WebSocket +const { CloseEvent, ErrorEvent, MessageEvent } = __nccwpck_require__(19643) +module.exports.WebSocket = __nccwpck_require__(9031).WebSocket module.exports.CloseEvent = CloseEvent module.exports.ErrorEvent = ErrorEvent module.exports.MessageEvent = MessageEvent @@ -46110,18 +46669,18 @@ module.exports.MockPool = MockPool module.exports.MockAgent = MockAgent module.exports.mockErrors = mockErrors -const { EventSource } = __nccwpck_require__(21238) +const { EventSource } = __nccwpck_require__(86559) module.exports.EventSource = EventSource /***/ }), -/***/ 80158: +/***/ 109: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { addAbortListener } = __nccwpck_require__(3440) -const { RequestAbortedError } = __nccwpck_require__(68707) +const { addAbortListener } = __nccwpck_require__(93865) +const { RequestAbortedError } = __nccwpck_require__(61366) const kListener = Symbol('kListener') const kSignal = Symbol('kSignal') @@ -46181,16 +46740,16 @@ module.exports = { /***/ }), -/***/ 34660: +/***/ 25985: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { const assert = __nccwpck_require__(34589) const { AsyncResource } = __nccwpck_require__(16698) -const { InvalidArgumentError, SocketError } = __nccwpck_require__(68707) -const util = __nccwpck_require__(3440) -const { addSignal, removeSignal } = __nccwpck_require__(80158) +const { InvalidArgumentError, SocketError } = __nccwpck_require__(61366) +const util = __nccwpck_require__(93865) +const { addSignal, removeSignal } = __nccwpck_require__(109) class ConnectHandler extends AsyncResource { constructor (opts, callback) { @@ -46296,7 +46855,7 @@ module.exports = connect /***/ }), -/***/ 76862: +/***/ 81161: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { @@ -46310,10 +46869,10 @@ const { InvalidArgumentError, InvalidReturnValueError, RequestAbortedError -} = __nccwpck_require__(68707) -const util = __nccwpck_require__(3440) +} = __nccwpck_require__(61366) +const util = __nccwpck_require__(93865) const { AsyncResource } = __nccwpck_require__(16698) -const { addSignal, removeSignal } = __nccwpck_require__(80158) +const { addSignal, removeSignal } = __nccwpck_require__(109) const assert = __nccwpck_require__(34589) const kResume = Symbol('resume') @@ -46554,16 +47113,16 @@ module.exports = pipeline /***/ }), -/***/ 14043: +/***/ 45170: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { const assert = __nccwpck_require__(34589) -const { Readable } = __nccwpck_require__(49927) -const { InvalidArgumentError, RequestAbortedError } = __nccwpck_require__(68707) -const util = __nccwpck_require__(3440) -const { getResolveErrorBodyCallback } = __nccwpck_require__(87655) +const { Readable } = __nccwpck_require__(54860) +const { InvalidArgumentError, RequestAbortedError } = __nccwpck_require__(61366) +const util = __nccwpck_require__(93865) +const { getResolveErrorBodyCallback } = __nccwpck_require__(43352) const { AsyncResource } = __nccwpck_require__(16698) class RequestHandler extends AsyncResource { @@ -46775,18 +47334,18 @@ module.exports.RequestHandler = RequestHandler /***/ }), -/***/ 3560: +/***/ 81591: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { const assert = __nccwpck_require__(34589) const { finished, PassThrough } = __nccwpck_require__(57075) -const { InvalidArgumentError, InvalidReturnValueError } = __nccwpck_require__(68707) -const util = __nccwpck_require__(3440) -const { getResolveErrorBodyCallback } = __nccwpck_require__(87655) +const { InvalidArgumentError, InvalidReturnValueError } = __nccwpck_require__(61366) +const util = __nccwpck_require__(93865) +const { getResolveErrorBodyCallback } = __nccwpck_require__(43352) const { AsyncResource } = __nccwpck_require__(16698) -const { addSignal, removeSignal } = __nccwpck_require__(80158) +const { addSignal, removeSignal } = __nccwpck_require__(109) class StreamHandler extends AsyncResource { constructor (opts, factory, callback) { @@ -47002,15 +47561,15 @@ module.exports = stream /***/ }), -/***/ 61882: +/***/ 61291: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { InvalidArgumentError, SocketError } = __nccwpck_require__(68707) +const { InvalidArgumentError, SocketError } = __nccwpck_require__(61366) const { AsyncResource } = __nccwpck_require__(16698) -const util = __nccwpck_require__(3440) -const { addSignal, removeSignal } = __nccwpck_require__(80158) +const util = __nccwpck_require__(93865) +const { addSignal, removeSignal } = __nccwpck_require__(109) const assert = __nccwpck_require__(34589) class UpgradeHandler extends AsyncResource { @@ -47117,21 +47676,21 @@ module.exports = upgrade /***/ }), -/***/ 56615: +/***/ 32390: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -module.exports.request = __nccwpck_require__(14043) -module.exports.stream = __nccwpck_require__(3560) -module.exports.pipeline = __nccwpck_require__(76862) -module.exports.upgrade = __nccwpck_require__(61882) -module.exports.connect = __nccwpck_require__(34660) +module.exports.request = __nccwpck_require__(45170) +module.exports.stream = __nccwpck_require__(81591) +module.exports.pipeline = __nccwpck_require__(81161) +module.exports.upgrade = __nccwpck_require__(61291) +module.exports.connect = __nccwpck_require__(25985) /***/ }), -/***/ 49927: +/***/ 54860: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { // Ported from https://github.com/nodejs/undici/pull/907 @@ -47140,9 +47699,9 @@ module.exports.connect = __nccwpck_require__(34660) const assert = __nccwpck_require__(34589) const { Readable } = __nccwpck_require__(57075) -const { RequestAbortedError, NotSupportedError, InvalidArgumentError, AbortError } = __nccwpck_require__(68707) -const util = __nccwpck_require__(3440) -const { ReadableStreamFrom } = __nccwpck_require__(3440) +const { RequestAbortedError, NotSupportedError, InvalidArgumentError, AbortError } = __nccwpck_require__(61366) +const util = __nccwpck_require__(93865) +const { ReadableStreamFrom } = __nccwpck_require__(93865) const kConsume = Symbol('kConsume') const kReading = Symbol('kReading') @@ -47523,15 +48082,15 @@ module.exports = { Readable: BodyReadable, chunksDecode } /***/ }), -/***/ 87655: +/***/ 43352: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { const assert = __nccwpck_require__(34589) const { ResponseStatusCodeError -} = __nccwpck_require__(68707) +} = __nccwpck_require__(61366) -const { chunksDecode } = __nccwpck_require__(49927) +const { chunksDecode } = __nccwpck_require__(54860) const CHUNK_LIMIT = 128 * 1024 async function getResolveErrorBodyCallback ({ callback, body, contentType, statusCode, statusMessage, headers }) { @@ -47623,16 +48182,16 @@ module.exports = { /***/ }), -/***/ 59136: +/***/ 70255: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { const net = __nccwpck_require__(77030) const assert = __nccwpck_require__(34589) -const util = __nccwpck_require__(3440) -const { InvalidArgumentError, ConnectTimeoutError } = __nccwpck_require__(68707) -const timers = __nccwpck_require__(96603) +const util = __nccwpck_require__(93865) +const { InvalidArgumentError, ConnectTimeoutError } = __nccwpck_require__(61366) +const timers = __nccwpck_require__(42366) function noop () {} @@ -47870,7 +48429,7 @@ module.exports = buildConnector /***/ }), -/***/ 10735: +/***/ 48808: /***/ ((module) => { @@ -47995,7 +48554,7 @@ module.exports = { /***/ }), -/***/ 42414: +/***/ 75997: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { @@ -48204,7 +48763,7 @@ module.exports = { /***/ }), -/***/ 68707: +/***/ 61366: /***/ ((module) => { @@ -48588,6 +49147,24 @@ class SecureProxyConnectionError extends UndiciError { [kSecureProxyConnectionError] = true } +const kMessageSizeExceededError = Symbol.for('undici.error.UND_ERR_WS_MESSAGE_SIZE_EXCEEDED') +class MessageSizeExceededError extends UndiciError { + constructor (message) { + super(message) + this.name = 'MessageSizeExceededError' + this.message = message || 'Max decompressed message size exceeded' + this.code = 'UND_ERR_WS_MESSAGE_SIZE_EXCEEDED' + } + + static [Symbol.hasInstance] (instance) { + return instance && instance[kMessageSizeExceededError] === true + } + + get [kMessageSizeExceededError] () { + return true + } +} + module.exports = { AbortError, HTTPParserError, @@ -48611,13 +49188,14 @@ module.exports = { ResponseExceededMaxSizeError, RequestRetryError, ResponseError, - SecureProxyConnectionError + SecureProxyConnectionError, + MessageSizeExceededError } /***/ }), -/***/ 44655: +/***/ 82468: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { @@ -48625,7 +49203,7 @@ module.exports = { const { InvalidArgumentError, NotSupportedError -} = __nccwpck_require__(68707) +} = __nccwpck_require__(61366) const assert = __nccwpck_require__(34589) const { isValidHTTPToken, @@ -48640,9 +49218,9 @@ const { validateHandler, getServerName, normalizedMethodRecords -} = __nccwpck_require__(3440) -const { channels } = __nccwpck_require__(42414) -const { headerNameLowerCasedRecord } = __nccwpck_require__(10735) +} = __nccwpck_require__(93865) +const { channels } = __nccwpck_require__(75997) +const { headerNameLowerCasedRecord } = __nccwpck_require__(48808) // Verifies that a given path is valid does not contain control chars \x00 to \x20 const invalidPathRegex = /[^\u0021-\u00ff]/ @@ -48688,6 +49266,10 @@ class Request { throw new InvalidArgumentError('upgrade must be a string') } + if (upgrade && !isValidHeaderValue(upgrade)) { + throw new InvalidArgumentError('invalid upgrade header') + } + if (headersTimeout != null && (!Number.isFinite(headersTimeout) || headersTimeout < 0)) { throw new InvalidArgumentError('invalid headersTimeout') } @@ -48968,7 +49550,13 @@ function processHeader (request, key, val) { } else if (typeof val[i] === 'object') { throw new InvalidArgumentError(`invalid ${key} header`) } else { - arr.push(`${val[i]}`) + // Coerce primitives (and reject unsafe coercions such as functions + // with a crafted toString/Symbol.toPrimitive). + const str = `${val[i]}` + if (!isValidHeaderValue(str)) { + throw new InvalidArgumentError(`invalid ${key} header`) + } + arr.push(str) } } val = arr @@ -48979,16 +49567,27 @@ function processHeader (request, key, val) { } else if (val === null) { val = '' } else { + // Coerce primitives (and reject unsafe coercions such as functions + // with a crafted toString/Symbol.toPrimitive). val = `${val}` + if (!isValidHeaderValue(val)) { + throw new InvalidArgumentError(`invalid ${key} header`) + } } - if (request.host === null && headerName === 'host') { + if (headerName === 'host') { + if (request.host !== null) { + throw new InvalidArgumentError('duplicate host header') + } if (typeof val !== 'string') { throw new InvalidArgumentError('invalid host header') } // Consumed by Client request.host = val - } else if (request.contentLength === null && headerName === 'content-length') { + } else if (headerName === 'content-length') { + if (request.contentLength !== null) { + throw new InvalidArgumentError('duplicate content-length header') + } request.contentLength = parseInt(val, 10) if (!Number.isFinite(request.contentLength)) { throw new InvalidArgumentError('invalid content-length header') @@ -49019,7 +49618,7 @@ module.exports = Request /***/ }), -/***/ 36443: +/***/ 77528: /***/ ((module) => { module.exports = { @@ -49093,7 +49692,7 @@ module.exports = { /***/ }), -/***/ 67752: +/***/ 92705: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { @@ -49101,7 +49700,7 @@ module.exports = { const { wellknownHeaderNames, headerNameLowerCasedRecord -} = __nccwpck_require__(10735) +} = __nccwpck_require__(48808) class TstNode { /** @type {any} */ @@ -49252,13 +49851,13 @@ module.exports = { /***/ }), -/***/ 3440: +/***/ 93865: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { const assert = __nccwpck_require__(34589) -const { kDestroyed, kBodyUsed, kListeners, kBody } = __nccwpck_require__(36443) +const { kDestroyed, kBodyUsed, kListeners, kBody } = __nccwpck_require__(77528) const { IncomingMessage } = __nccwpck_require__(37067) const stream = __nccwpck_require__(57075) const net = __nccwpck_require__(77030) @@ -49266,9 +49865,9 @@ const { Blob } = __nccwpck_require__(4573) const nodeUtil = __nccwpck_require__(57975) const { stringify } = __nccwpck_require__(41792) const { EventEmitter: EE } = __nccwpck_require__(78474) -const { InvalidArgumentError } = __nccwpck_require__(68707) -const { headerNameLowerCasedRecord } = __nccwpck_require__(10735) -const { tree } = __nccwpck_require__(67752) +const { InvalidArgumentError } = __nccwpck_require__(61366) +const { headerNameLowerCasedRecord } = __nccwpck_require__(48808) +const { tree } = __nccwpck_require__(92705) const [nodeMajor, nodeMinor] = process.versions.node.split('.').map(v => Number(v)) @@ -49978,18 +50577,18 @@ module.exports = { /***/ }), -/***/ 57405: +/***/ 90754: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { InvalidArgumentError } = __nccwpck_require__(68707) -const { kClients, kRunning, kClose, kDestroy, kDispatch, kInterceptors } = __nccwpck_require__(36443) -const DispatcherBase = __nccwpck_require__(21841) -const Pool = __nccwpck_require__(30628) -const Client = __nccwpck_require__(23701) -const util = __nccwpck_require__(3440) -const createRedirectInterceptor = __nccwpck_require__(25092) +const { InvalidArgumentError } = __nccwpck_require__(61366) +const { kClients, kRunning, kClose, kDestroy, kDispatch, kInterceptors } = __nccwpck_require__(77528) +const DispatcherBase = __nccwpck_require__(37758) +const Pool = __nccwpck_require__(67185) +const Client = __nccwpck_require__(95548) +const util = __nccwpck_require__(93865) +const createRedirectInterceptor = __nccwpck_require__(2087) const kOnConnect = Symbol('onConnect') const kOnDisconnect = Symbol('onDisconnect') @@ -50007,8 +50606,6 @@ function defaultFactory (origin, opts) { class Agent extends DispatcherBase { constructor ({ factory = defaultFactory, maxRedirections = 0, connect, ...options } = {}) { - super() - if (typeof factory !== 'function') { throw new InvalidArgumentError('factory must be a function.') } @@ -50021,6 +50618,8 @@ class Agent extends DispatcherBase { throw new InvalidArgumentError('maxRedirections must be a positive number') } + super(options) + if (connect && typeof connect !== 'function') { connect = { ...connect } } @@ -50114,7 +50713,7 @@ module.exports = Agent /***/ }), -/***/ 837: +/***/ 35078: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { @@ -50122,7 +50721,7 @@ module.exports = Agent const { BalancedPoolMissingUpstreamError, InvalidArgumentError -} = __nccwpck_require__(68707) +} = __nccwpck_require__(61366) const { PoolBase, kClients, @@ -50130,10 +50729,10 @@ const { kAddClient, kRemoveClient, kGetDispatcher -} = __nccwpck_require__(42128) -const Pool = __nccwpck_require__(30628) -const { kUrl, kInterceptors } = __nccwpck_require__(36443) -const { parseOrigin } = __nccwpck_require__(3440) +} = __nccwpck_require__(89131) +const Pool = __nccwpck_require__(67185) +const { kUrl, kInterceptors } = __nccwpck_require__(77528) +const { parseOrigin } = __nccwpck_require__(93865) const kFactory = Symbol('factory') const kOptions = Symbol('options') @@ -50330,7 +50929,7 @@ module.exports = BalancedPool /***/ }), -/***/ 637: +/***/ 75018: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { @@ -50338,13 +50937,14 @@ module.exports = BalancedPool /* global WebAssembly */ const assert = __nccwpck_require__(34589) -const util = __nccwpck_require__(3440) -const { channels } = __nccwpck_require__(42414) -const timers = __nccwpck_require__(96603) +const util = __nccwpck_require__(93865) +const { channels } = __nccwpck_require__(75997) +const timers = __nccwpck_require__(42366) const { RequestContentLengthMismatchError, ResponseContentLengthMismatchError, RequestAbortedError, + InvalidArgumentError, HeadersTimeoutError, HeadersOverflowError, SocketError, @@ -50352,7 +50952,7 @@ const { BodyTimeoutError, HTTPParserError, ResponseExceededMaxSizeError -} = __nccwpck_require__(68707) +} = __nccwpck_require__(61366) const { kUrl, kReset, @@ -50385,22 +50985,25 @@ const { kOnError, kResume, kHTTPContext -} = __nccwpck_require__(36443) +} = __nccwpck_require__(77528) -const constants = __nccwpck_require__(52824) +const constants = __nccwpck_require__(30195) const EMPTY_BUF = Buffer.alloc(0) const FastBuffer = Buffer[Symbol.species] const addListener = util.addListener const removeAllListeners = util.removeAllListeners +const kIdleSocketValidation = Symbol('kIdleSocketValidation') +const kIdleSocketValidationTimeout = Symbol('kIdleSocketValidationTimeout') +const kSocketUsed = Symbol('kSocketUsed') let extractBody async function lazyllhttp () { - const llhttpWasmData = process.env.JEST_WORKER_ID ? __nccwpck_require__(63870) : undefined + const llhttpWasmData = process.env.JEST_WORKER_ID ? __nccwpck_require__(84717) : undefined let mod try { - mod = await WebAssembly.compile(__nccwpck_require__(53434)) + mod = await WebAssembly.compile(__nccwpck_require__(71807)) } catch (e) { /* istanbul ignore next */ @@ -50408,7 +51011,7 @@ async function lazyllhttp () { // being enabled, but the occurring of this other error // * https://github.com/emscripten-core/emscripten/issues/11495 // got me to remove that check to avoid breaking Node 12. - mod = await WebAssembly.compile(llhttpWasmData || __nccwpck_require__(63870)) + mod = await WebAssembly.compile(llhttpWasmData || __nccwpck_require__(84717)) } return await WebAssembly.instantiate(mod, { @@ -50614,29 +51217,71 @@ class Parser { const offset = llhttp.llhttp_get_error_pos(this.ptr) - currentBufferPtr - if (ret === constants.ERROR.PAUSED_UPGRADE) { - this.onUpgrade(data.slice(offset)) - } else if (ret === constants.ERROR.PAUSED) { - this.paused = true - socket.unshift(data.slice(offset)) - } else if (ret !== constants.ERROR.OK) { - const ptr = llhttp.llhttp_get_error_reason(this.ptr) - let message = '' - /* istanbul ignore else: difficult to make a test case for */ - if (ptr) { - const len = new Uint8Array(llhttp.memory.buffer, ptr).indexOf(0) - message = - 'Response does not match the HTTP/1.1 protocol (' + - Buffer.from(llhttp.memory.buffer, ptr, len).toString() + - ')' - } - throw new HTTPParserError(message, constants.ERROR[ret], data.slice(offset)) + if (ret !== constants.ERROR.OK) { + const body = data.subarray(offset) + + if (ret === constants.ERROR.PAUSED_UPGRADE) { + this.onUpgrade(body) + } else if (ret === constants.ERROR.PAUSED) { + this.paused = true + socket.unshift(body) + } else { + throw this.createError(ret, body) + } } } catch (err) { util.destroy(socket, err) } } + finish () { + assert(currentParser === null) + assert(this.ptr != null) + assert(!this.paused) + + const { llhttp } = this + + let ret + + try { + currentParser = this + ret = llhttp.llhttp_finish(this.ptr) + } finally { + currentParser = null + } + + if (ret === constants.ERROR.OK) { + return null + } + + if (ret === constants.ERROR.PAUSED || ret === constants.ERROR.PAUSED_UPGRADE) { + this.paused = true + return null + } + + return this.createError(ret, EMPTY_BUF) + } + + createError (ret, data) { + const { llhttp, contentLength, bytesRead } = this + + if (contentLength && bytesRead !== parseInt(contentLength, 10)) { + return new ResponseContentLengthMismatchError() + } + + const ptr = llhttp.llhttp_get_error_reason(this.ptr) + let message = '' + if (ptr) { + const len = new Uint8Array(llhttp.memory.buffer, ptr).indexOf(0) + message = + 'Response does not match the HTTP/1.1 protocol (' + + Buffer.from(llhttp.memory.buffer, ptr, len).toString() + + ')' + } + + return new HTTPParserError(message, constants.ERROR[ret], data) + } + destroy () { assert(this.ptr != null) assert(currentParser == null) @@ -50664,6 +51309,11 @@ class Parser { return -1 } + if (client[kRunning] === 0) { + util.destroy(socket, new SocketError('bad response', util.getSocketInfo(socket))) + return -1 + } + const request = client[kQueue][client[kRunningIdx]] if (!request) { return -1 @@ -50767,6 +51417,11 @@ class Parser { return -1 } + if (client[kRunning] === 0) { + util.destroy(socket, new SocketError('bad response', util.getSocketInfo(socket))) + return -1 + } + const request = client[kQueue][client[kRunningIdx]] /* istanbul ignore next: difficult to make a test case for */ @@ -50940,6 +51595,7 @@ class Parser { request.onComplete(headers) client[kQueue][client[kRunningIdx]++] = null + socket[kSocketUsed] = true if (socket[kWriting]) { assert(client[kRunning] === 0) @@ -50998,6 +51654,9 @@ async function connectH1 (client, socket) { socket[kWriting] = false socket[kReset] = false socket[kBlocking] = false + socket[kIdleSocketValidation] = 0 + socket[kIdleSocketValidationTimeout] = null + socket[kSocketUsed] = false socket[kParser] = new Parser(client, socket, llhttpInstance) addListener(socket, 'error', function (err) { @@ -51008,8 +51667,11 @@ async function connectH1 (client, socket) { // On Mac OS, we get an ECONNRESET even if there is a full body to be forwarded // to the user. if (err.code === 'ECONNRESET' && parser.statusCode && !parser.shouldKeepAlive) { - // We treat all incoming data so for as a valid response. - parser.onMessageComplete() + const parserErr = parser.finish() + if (parserErr) { + this[kError] = parserErr + this[kClient][kOnError](parserErr) + } return } @@ -51028,8 +51690,10 @@ async function connectH1 (client, socket) { const parser = this[kParser] if (parser.statusCode && !parser.shouldKeepAlive) { - // We treat all incoming data so far as a valid response. - parser.onMessageComplete() + const parserErr = parser.finish() + if (parserErr) { + util.destroy(this, parserErr) + } return } @@ -51039,10 +51703,11 @@ async function connectH1 (client, socket) { const client = this[kClient] const parser = this[kParser] + clearIdleSocketValidation(this) + if (parser) { if (!this[kError] && parser.statusCode && !parser.shouldKeepAlive) { - // We treat all incoming data so far as a valid response. - parser.onMessageComplete() + this[kError] = parser.finish() || this[kError] } this[kParser].destroy() @@ -51105,7 +51770,7 @@ async function connectH1 (client, socket) { return socket.destroyed }, busy (request) { - if (socket[kWriting] || socket[kReset] || socket[kBlocking]) { + if (socket[kWriting] || socket[kReset] || socket[kBlocking] || socket[kIdleSocketValidation] === 1) { return true } @@ -51143,6 +51808,31 @@ async function connectH1 (client, socket) { } } +function clearIdleSocketValidation (socket) { + if (socket[kIdleSocketValidationTimeout]) { + clearTimeout(socket[kIdleSocketValidationTimeout]) + socket[kIdleSocketValidationTimeout] = null + } + + socket[kIdleSocketValidation] = 0 +} + +function scheduleIdleSocketValidation (client, socket) { + socket[kIdleSocketValidation] = 1 + socket[kIdleSocketValidationTimeout] = setTimeout(() => { + socket[kIdleSocketValidationTimeout] = null + socket[kIdleSocketValidation] = 2 + + if (client[kSocket] === socket && !socket.destroyed) { + client[kResume]() + } + }, 0) + socket[kIdleSocketValidationTimeout].unref?.() +} + +/** + * @param {import('./client.js')} client + */ function resumeH1 (client) { const socket = client[kSocket] @@ -51157,6 +51847,32 @@ function resumeH1 (client) { socket[kNoRef] = false } + if (client[kRunning] === 0 && client[kPending] > 0 && socket[kSocketUsed]) { + if (socket[kIdleSocketValidation] === 0) { + scheduleIdleSocketValidation(client, socket) + socket[kParser].readMore() + if (socket.destroyed) { + return + } + return + } + + if (socket[kIdleSocketValidation] === 1) { + socket[kParser].readMore() + if (socket.destroyed) { + return + } + return + } + } + + if (client[kRunning] === 0) { + socket[kParser].readMore() + if (socket.destroyed) { + return + } + } + if (client[kSize] === 0) { if (socket[kParser].timeoutType !== TIMEOUT_KEEP_ALIVE) { socket[kParser].setTimeout(client[kKeepAliveTimeoutValue], TIMEOUT_KEEP_ALIVE) @@ -51203,7 +51919,7 @@ function writeH1 (client, request) { if (util.isFormDataLike(body)) { if (!extractBody) { - extractBody = (__nccwpck_require__(84492).extractBody) + extractBody = (__nccwpck_require__(36847).extractBody) } const [bodyStream, contentType] = extractBody(body) @@ -51212,8 +51928,16 @@ function writeH1 (client, request) { } body = bodyStream.stream contentLength = bodyStream.length - } else if (util.isBlobLike(body) && request.contentType == null && body.type) { - headers.push('content-type', body.type) + } else if (util.isBlobLike(body) && request.contentType == null) { + const contentType = body.type + if (contentType) { + const contentTypeValue = `${contentType}` + if (!util.isValidHeaderValue(contentTypeValue)) { + util.errorRequest(client, request, new InvalidArgumentError('invalid content-type header')) + return false + } + headers.push('content-type', contentTypeValue) + } } if (body && typeof body.read === 'function') { @@ -51250,6 +51974,7 @@ function writeH1 (client, request) { } const socket = client[kSocket] + clearIdleSocketValidation(socket) const abort = (err) => { if (request.aborted || request.completed) { @@ -51707,20 +52432,20 @@ module.exports = connectH1 /***/ }), -/***/ 88788: +/***/ 52279: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { const assert = __nccwpck_require__(34589) const { pipeline } = __nccwpck_require__(57075) -const util = __nccwpck_require__(3440) +const util = __nccwpck_require__(93865) const { RequestContentLengthMismatchError, RequestAbortedError, SocketError, InformationalError -} = __nccwpck_require__(68707) +} = __nccwpck_require__(61366) const { kUrl, kReset, @@ -51739,7 +52464,7 @@ const { kResume, kSize, kHTTPContext -} = __nccwpck_require__(36443) +} = __nccwpck_require__(77528) const kOpenStreams = Symbol('open streams') @@ -52098,7 +52823,7 @@ function writeH2 (client, request) { let contentLength = util.bodyLength(body) if (util.isFormDataLike(body)) { - extractBody ??= (__nccwpck_require__(84492).extractBody) + extractBody ??= (__nccwpck_require__(36847).extractBody) const [bodyStream, contentType] = extractBody(body) headers['content-type'] = contentType @@ -52458,7 +53183,7 @@ module.exports = connectH2 /***/ }), -/***/ 23701: +/***/ 95548: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { // @ts-check @@ -52468,16 +53193,16 @@ module.exports = connectH2 const assert = __nccwpck_require__(34589) const net = __nccwpck_require__(77030) const http = __nccwpck_require__(37067) -const util = __nccwpck_require__(3440) -const { channels } = __nccwpck_require__(42414) -const Request = __nccwpck_require__(44655) -const DispatcherBase = __nccwpck_require__(21841) +const util = __nccwpck_require__(93865) +const { channels } = __nccwpck_require__(75997) +const Request = __nccwpck_require__(82468) +const DispatcherBase = __nccwpck_require__(37758) const { InvalidArgumentError, InformationalError, ClientDestroyedError -} = __nccwpck_require__(68707) -const buildConnector = __nccwpck_require__(59136) +} = __nccwpck_require__(61366) +const buildConnector = __nccwpck_require__(70255) const { kUrl, kServerName, @@ -52519,9 +53244,9 @@ const { kHTTPContext, kMaxConcurrentStreams, kResume -} = __nccwpck_require__(36443) -const connectH1 = __nccwpck_require__(637) -const connectH2 = __nccwpck_require__(88788) +} = __nccwpck_require__(77528) +const connectH1 = __nccwpck_require__(75018) +const connectH2 = __nccwpck_require__(52279) let deprecatedInterceptorWarned = false const kClosedResolve = Symbol('kClosedResolve') @@ -52569,9 +53294,10 @@ class Client extends DispatcherBase { autoSelectFamilyAttemptTimeout, // h2 maxConcurrentStreams, - allowH2 + allowH2, + webSocket } = {}) { - super() + super({ webSocket }) if (keepAlive !== undefined) { throw new InvalidArgumentError('unsupported keepAlive, use pipelining=0 instead') @@ -52827,7 +53553,7 @@ class Client extends DispatcherBase { } } -const createRedirectInterceptor = __nccwpck_require__(25092) +const createRedirectInterceptor = __nccwpck_require__(2087) function onError (client, err) { if ( @@ -53087,31 +53813,40 @@ module.exports = Client /***/ }), -/***/ 21841: +/***/ 37758: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const Dispatcher = __nccwpck_require__(30883) +const Dispatcher = __nccwpck_require__(82414) const { ClientDestroyedError, ClientClosedError, InvalidArgumentError -} = __nccwpck_require__(68707) -const { kDestroy, kClose, kClosed, kDestroyed, kDispatch, kInterceptors } = __nccwpck_require__(36443) +} = __nccwpck_require__(61366) +const { kDestroy, kClose, kClosed, kDestroyed, kDispatch, kInterceptors } = __nccwpck_require__(77528) const kOnDestroyed = Symbol('onDestroyed') const kOnClosed = Symbol('onClosed') const kInterceptedDispatch = Symbol('Intercepted Dispatch') +const kWebSocketOptions = Symbol('webSocketOptions') class DispatcherBase extends Dispatcher { - constructor () { + constructor (opts) { super() this[kDestroyed] = false this[kOnDestroyed] = null this[kClosed] = false this[kOnClosed] = [] + this[kWebSocketOptions] = opts?.webSocket ?? {} + } + + get webSocketOptions () { + return { + maxFragments: this[kWebSocketOptions].maxFragments ?? 131072, + maxPayloadSize: this[kWebSocketOptions].maxPayloadSize ?? 128 * 1024 * 1024 + } } get destroyed () { @@ -53284,7 +54019,7 @@ module.exports = DispatcherBase /***/ }), -/***/ 30883: +/***/ 82414: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { @@ -53356,15 +54091,15 @@ module.exports = Dispatcher /***/ }), -/***/ 53137: +/***/ 97760: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const DispatcherBase = __nccwpck_require__(21841) -const { kClose, kDestroy, kClosed, kDestroyed, kDispatch, kNoProxyAgent, kHttpProxyAgent, kHttpsProxyAgent } = __nccwpck_require__(36443) -const ProxyAgent = __nccwpck_require__(76672) -const Agent = __nccwpck_require__(57405) +const DispatcherBase = __nccwpck_require__(37758) +const { kClose, kDestroy, kClosed, kDestroyed, kDispatch, kNoProxyAgent, kHttpProxyAgent, kHttpsProxyAgent } = __nccwpck_require__(77528) +const ProxyAgent = __nccwpck_require__(58491) +const Agent = __nccwpck_require__(90754) const DEFAULT_PORTS = { 'http:': 80, @@ -53523,7 +54258,7 @@ module.exports = EnvHttpProxyAgent /***/ }), -/***/ 64660: +/***/ 57711: /***/ ((module) => { /* eslint-disable */ @@ -53647,15 +54382,15 @@ module.exports = class FixedQueue { /***/ }), -/***/ 42128: +/***/ 89131: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const DispatcherBase = __nccwpck_require__(21841) -const FixedQueue = __nccwpck_require__(64660) -const { kConnected, kSize, kRunning, kPending, kQueued, kBusy, kFree, kUrl, kClose, kDestroy, kDispatch } = __nccwpck_require__(36443) -const PoolStats = __nccwpck_require__(43246) +const DispatcherBase = __nccwpck_require__(37758) +const FixedQueue = __nccwpck_require__(57711) +const { kConnected, kSize, kRunning, kPending, kQueued, kBusy, kFree, kUrl, kClose, kDestroy, kDispatch } = __nccwpck_require__(77528) +const PoolStats = __nccwpck_require__(94951) const kClients = Symbol('clients') const kNeedDrain = Symbol('needDrain') @@ -53671,8 +54406,8 @@ const kRemoveClient = Symbol('remove client') const kStats = Symbol('stats') class PoolBase extends DispatcherBase { - constructor () { - super() + constructor (opts) { + super(opts) this[kQueue] = new FixedQueue() this[kClients] = [] @@ -53848,10 +54583,10 @@ module.exports = { /***/ }), -/***/ 43246: +/***/ 94951: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { kFree, kConnected, kPending, kQueued, kRunning, kSize } = __nccwpck_require__(36443) +const { kFree, kConnected, kPending, kQueued, kRunning, kSize } = __nccwpck_require__(77528) const kPool = Symbol('pool') class PoolStats { @@ -53889,7 +54624,7 @@ module.exports = PoolStats /***/ }), -/***/ 30628: +/***/ 67185: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { @@ -53900,14 +54635,14 @@ const { kNeedDrain, kAddClient, kGetDispatcher -} = __nccwpck_require__(42128) -const Client = __nccwpck_require__(23701) +} = __nccwpck_require__(89131) +const Client = __nccwpck_require__(95548) const { InvalidArgumentError -} = __nccwpck_require__(68707) -const util = __nccwpck_require__(3440) -const { kUrl, kInterceptors } = __nccwpck_require__(36443) -const buildConnector = __nccwpck_require__(59136) +} = __nccwpck_require__(61366) +const util = __nccwpck_require__(93865) +const { kUrl, kInterceptors } = __nccwpck_require__(77528) +const buildConnector = __nccwpck_require__(70255) const kOptions = Symbol('options') const kConnections = Symbol('connections') @@ -53931,8 +54666,6 @@ class Pool extends PoolBase { allowH2, ...options } = {}) { - super() - if (connections != null && (!Number.isFinite(connections) || connections < 0)) { throw new InvalidArgumentError('invalid connections') } @@ -53957,6 +54690,8 @@ class Pool extends PoolBase { }) } + super(options) + this[kInterceptors] = options.interceptors?.Pool && Array.isArray(options.interceptors.Pool) ? options.interceptors.Pool : [] @@ -54003,19 +54738,19 @@ module.exports = Pool /***/ }), -/***/ 76672: +/***/ 58491: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { kProxy, kClose, kDestroy, kDispatch, kInterceptors } = __nccwpck_require__(36443) +const { kProxy, kClose, kDestroy, kDispatch, kInterceptors } = __nccwpck_require__(77528) const { URL } = __nccwpck_require__(73136) -const Agent = __nccwpck_require__(57405) -const Pool = __nccwpck_require__(30628) -const DispatcherBase = __nccwpck_require__(21841) -const { InvalidArgumentError, RequestAbortedError, SecureProxyConnectionError } = __nccwpck_require__(68707) -const buildConnector = __nccwpck_require__(59136) -const Client = __nccwpck_require__(23701) +const Agent = __nccwpck_require__(90754) +const Pool = __nccwpck_require__(67185) +const DispatcherBase = __nccwpck_require__(37758) +const { InvalidArgumentError, RequestAbortedError, SecureProxyConnectionError } = __nccwpck_require__(61366) +const buildConnector = __nccwpck_require__(70255) +const Client = __nccwpck_require__(95548) const kAgent = Symbol('proxy agent') const kClient = Symbol('proxy client') @@ -54284,13 +55019,13 @@ module.exports = ProxyAgent /***/ }), -/***/ 30050: +/***/ 94969: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const Dispatcher = __nccwpck_require__(30883) -const RetryHandler = __nccwpck_require__(17816) +const Dispatcher = __nccwpck_require__(82414) +const RetryHandler = __nccwpck_require__(67197) class RetryAgent extends Dispatcher { #agent = null @@ -54326,7 +55061,7 @@ module.exports = RetryAgent /***/ }), -/***/ 32581: +/***/ 64010: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { @@ -54334,8 +55069,8 @@ module.exports = RetryAgent // We include a version number for the Dispatcher API. In case of breaking changes, // this version number must be increased to avoid conflicts. const globalDispatcher = Symbol.for('undici.globalDispatcher.1') -const { InvalidArgumentError } = __nccwpck_require__(68707) -const Agent = __nccwpck_require__(57405) +const { InvalidArgumentError } = __nccwpck_require__(61366) +const Agent = __nccwpck_require__(90754) if (getGlobalDispatcher() === undefined) { setGlobalDispatcher(new Agent()) @@ -54365,7 +55100,7 @@ module.exports = { /***/ }), -/***/ 58155: +/***/ 76006: /***/ ((module) => { @@ -54416,15 +55151,15 @@ module.exports = class DecoratorHandler { /***/ }), -/***/ 8754: +/***/ 75853: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const util = __nccwpck_require__(3440) -const { kBodyUsed } = __nccwpck_require__(36443) +const util = __nccwpck_require__(93865) +const { kBodyUsed } = __nccwpck_require__(77528) const assert = __nccwpck_require__(34589) -const { InvalidArgumentError } = __nccwpck_require__(68707) +const { InvalidArgumentError } = __nccwpck_require__(61366) const EE = __nccwpck_require__(78474) const redirectableStatusCodes = [300, 301, 302, 303, 307, 308] @@ -54655,26 +55390,48 @@ module.exports = RedirectHandler /***/ }), -/***/ 17816: +/***/ 67197: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { const assert = __nccwpck_require__(34589) -const { kRetryHandlerDefaultRetry } = __nccwpck_require__(36443) -const { RequestRetryError } = __nccwpck_require__(68707) +const { kRetryHandlerDefaultRetry } = __nccwpck_require__(77528) +const { RequestRetryError } = __nccwpck_require__(61366) const { isDisturbed, parseHeaders, parseRangeHeader, wrapRequestBody -} = __nccwpck_require__(3440) +} = __nccwpck_require__(93865) function calculateRetryAfterHeader (retryAfter) { const current = Date.now() return new Date(retryAfter).getTime() - current } +function validatePartialResponseContentLength (headers, range, statusCode, retryCount) { + const contentLength = headers['content-length'] + if (contentLength == null) { + return null + } + + if (!Number.isFinite(range.start) || !Number.isFinite(range.end)) { + return null + } + + const length = Number(contentLength) + const expectedLength = range.end - range.start + 1 + if (!Number.isFinite(length) || length !== expectedLength) { + return new RequestRetryError('Content-Length mismatch', statusCode, { + headers, + data: { count: retryCount } + }) + } + + return null +} + class RetryHandler { constructor (opts, handlers) { const { retryOptions, ...dispatchOpts } = opts @@ -54889,6 +55646,12 @@ class RetryHandler { return false } + const contentLengthError = validatePartialResponseContentLength(headers, contentRange, statusCode, this.retryCount) + if (contentLengthError != null) { + this.abort(contentLengthError) + return false + } + const { start, size, end = size - 1 } = contentRange assert(this.start === start, 'content-range mismatch') @@ -54912,6 +55675,12 @@ class RetryHandler { ) } + const contentLengthError = validatePartialResponseContentLength(headers, range, statusCode, this.retryCount) + if (contentLengthError != null) { + this.abort(contentLengthError) + return false + } + const { start, size, end = size - 1 } = range assert( start != null && Number.isFinite(start), @@ -55036,14 +55805,14 @@ module.exports = RetryHandler /***/ }), -/***/ 70379: +/***/ 22726: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { const { isIP } = __nccwpck_require__(77030) const { lookup } = __nccwpck_require__(40610) -const DecoratorHandler = __nccwpck_require__(58155) -const { InvalidArgumentError, InformationalError } = __nccwpck_require__(68707) +const DecoratorHandler = __nccwpck_require__(76006) +const { InvalidArgumentError, InformationalError } = __nccwpck_require__(61366) const maxInt = Math.pow(2, 31) - 1 class DNSInstance { @@ -55418,14 +56187,14 @@ module.exports = interceptorOpts => { /***/ }), -/***/ 88060: +/***/ 14743: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const util = __nccwpck_require__(3440) -const { InvalidArgumentError, RequestAbortedError } = __nccwpck_require__(68707) -const DecoratorHandler = __nccwpck_require__(58155) +const util = __nccwpck_require__(93865) +const { InvalidArgumentError, RequestAbortedError } = __nccwpck_require__(61366) +const DecoratorHandler = __nccwpck_require__(76006) class DumpHandler extends DecoratorHandler { #maxSize = 1024 * 1024 @@ -55548,12 +56317,12 @@ module.exports = createDumpInterceptor /***/ }), -/***/ 25092: +/***/ 2087: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const RedirectHandler = __nccwpck_require__(8754) +const RedirectHandler = __nccwpck_require__(75853) function createRedirectInterceptor ({ maxRedirections: defaultMaxRedirections }) { return (dispatch) => { @@ -55576,11 +56345,11 @@ module.exports = createRedirectInterceptor /***/ }), -/***/ 21514: +/***/ 42969: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const RedirectHandler = __nccwpck_require__(8754) +const RedirectHandler = __nccwpck_require__(75853) module.exports = opts => { const globalMaxRedirections = opts?.maxRedirections @@ -55607,11 +56376,11 @@ module.exports = opts => { /***/ }), -/***/ 92026: +/***/ 83695: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const RetryHandler = __nccwpck_require__(17816) +const RetryHandler = __nccwpck_require__(67197) module.exports = globalOpts => { return dispatch => { @@ -55633,13 +56402,13 @@ module.exports = globalOpts => { /***/ }), -/***/ 52824: +/***/ 30195: /***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { Object.defineProperty(exports, "__esModule", ({ value: true })); exports.SPECIAL_HEADERS = exports.HEADER_STATE = exports.MINOR = exports.MAJOR = exports.CONNECTION_TOKEN_CHARS = exports.HEADER_CHARS = exports.TOKEN = exports.STRICT_TOKEN = exports.HEX = exports.URL_CHAR = exports.STRICT_URL_CHAR = exports.USERINFO_CHARS = exports.MARK = exports.ALPHANUM = exports.NUM = exports.HEX_MAP = exports.NUM_MAP = exports.ALPHA = exports.FINISH = exports.H_METHOD_MAP = exports.METHOD_MAP = exports.METHODS_RTSP = exports.METHODS_ICE = exports.METHODS_HTTP = exports.METHODS = exports.LENIENT_FLAGS = exports.FLAGS = exports.TYPE = exports.ERROR = void 0; -const utils_1 = __nccwpck_require__(50172); +const utils_1 = __nccwpck_require__(53443); // C headers var ERROR; (function (ERROR) { @@ -55917,7 +56686,7 @@ exports.SPECIAL_HEADERS = { /***/ }), -/***/ 63870: +/***/ 84717: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { @@ -55929,7 +56698,7 @@ module.exports = Buffer.from('AGFzbQEAAAABJwdgAX8Bf2ADf39/AX9gAX8AYAJ/fwBgBH9/f3 /***/ }), -/***/ 53434: +/***/ 71807: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { @@ -55941,7 +56710,7 @@ module.exports = Buffer.from('AGFzbQEAAAABJwdgAX8Bf2ADf39/AX9gAX8AYAJ/fwBgBH9/f3 /***/ }), -/***/ 50172: +/***/ 53443: /***/ ((__unused_webpack_module, exports) => { @@ -55962,13 +56731,13 @@ exports.enumToMap = enumToMap; /***/ }), -/***/ 47501: +/***/ 38292: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { kClients } = __nccwpck_require__(36443) -const Agent = __nccwpck_require__(57405) +const { kClients } = __nccwpck_require__(77528) +const Agent = __nccwpck_require__(90754) const { kAgent, kMockAgentSet, @@ -55979,14 +56748,14 @@ const { kGetNetConnect, kOptions, kFactory -} = __nccwpck_require__(91117) -const MockClient = __nccwpck_require__(47365) -const MockPool = __nccwpck_require__(94004) -const { matchValue, buildMockOptions } = __nccwpck_require__(53397) -const { InvalidArgumentError, UndiciError } = __nccwpck_require__(68707) -const Dispatcher = __nccwpck_require__(30883) -const Pluralizer = __nccwpck_require__(91529) -const PendingInterceptorsFormatter = __nccwpck_require__(56142) +} = __nccwpck_require__(80832) +const MockClient = __nccwpck_require__(15938) +const MockPool = __nccwpck_require__(17695) +const { matchValue, buildMockOptions } = __nccwpck_require__(72276) +const { InvalidArgumentError, UndiciError } = __nccwpck_require__(61366) +const Dispatcher = __nccwpck_require__(82414) +const Pluralizer = __nccwpck_require__(78820) +const PendingInterceptorsFormatter = __nccwpck_require__(62595) class MockAgent extends Dispatcher { constructor (opts) { @@ -56129,14 +56898,14 @@ module.exports = MockAgent /***/ }), -/***/ 47365: +/***/ 15938: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { const { promisify } = __nccwpck_require__(57975) -const Client = __nccwpck_require__(23701) -const { buildMockDispatch } = __nccwpck_require__(53397) +const Client = __nccwpck_require__(95548) +const { buildMockDispatch } = __nccwpck_require__(72276) const { kDispatches, kMockAgent, @@ -56145,10 +56914,10 @@ const { kOrigin, kOriginalDispatch, kConnected -} = __nccwpck_require__(91117) -const { MockInterceptor } = __nccwpck_require__(31511) -const Symbols = __nccwpck_require__(36443) -const { InvalidArgumentError } = __nccwpck_require__(68707) +} = __nccwpck_require__(80832) +const { MockInterceptor } = __nccwpck_require__(37118) +const Symbols = __nccwpck_require__(77528) +const { InvalidArgumentError } = __nccwpck_require__(61366) /** * MockClient provides an API that extends the Client to influence the mockDispatches. @@ -56195,12 +56964,12 @@ module.exports = MockClient /***/ }), -/***/ 52429: +/***/ 86270: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { UndiciError } = __nccwpck_require__(68707) +const { UndiciError } = __nccwpck_require__(61366) const kMockNotMatchedError = Symbol.for('undici.error.UND_MOCK_ERR_MOCK_NOT_MATCHED') @@ -56230,12 +56999,12 @@ module.exports = { /***/ }), -/***/ 31511: +/***/ 37118: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { getResponseData, buildKey, addMockDispatch } = __nccwpck_require__(53397) +const { getResponseData, buildKey, addMockDispatch } = __nccwpck_require__(72276) const { kDispatches, kDispatchKey, @@ -56243,9 +57012,9 @@ const { kDefaultTrailers, kContentLength, kMockDispatch -} = __nccwpck_require__(91117) -const { InvalidArgumentError } = __nccwpck_require__(68707) -const { buildURL } = __nccwpck_require__(3440) +} = __nccwpck_require__(80832) +const { InvalidArgumentError } = __nccwpck_require__(61366) +const { buildURL } = __nccwpck_require__(93865) /** * Defines the scope API for an interceptor reply @@ -56444,14 +57213,14 @@ module.exports.MockScope = MockScope /***/ }), -/***/ 94004: +/***/ 17695: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { const { promisify } = __nccwpck_require__(57975) -const Pool = __nccwpck_require__(30628) -const { buildMockDispatch } = __nccwpck_require__(53397) +const Pool = __nccwpck_require__(67185) +const { buildMockDispatch } = __nccwpck_require__(72276) const { kDispatches, kMockAgent, @@ -56460,10 +57229,10 @@ const { kOrigin, kOriginalDispatch, kConnected -} = __nccwpck_require__(91117) -const { MockInterceptor } = __nccwpck_require__(31511) -const Symbols = __nccwpck_require__(36443) -const { InvalidArgumentError } = __nccwpck_require__(68707) +} = __nccwpck_require__(80832) +const { MockInterceptor } = __nccwpck_require__(37118) +const Symbols = __nccwpck_require__(77528) +const { InvalidArgumentError } = __nccwpck_require__(61366) /** * MockPool provides an API that extends the Pool to influence the mockDispatches. @@ -56510,7 +57279,7 @@ module.exports = MockPool /***/ }), -/***/ 91117: +/***/ 80832: /***/ ((module) => { @@ -56540,20 +57309,20 @@ module.exports = { /***/ }), -/***/ 53397: +/***/ 72276: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { MockNotMatchedError } = __nccwpck_require__(52429) +const { MockNotMatchedError } = __nccwpck_require__(86270) const { kDispatches, kMockAgent, kOriginalDispatch, kOrigin, kGetNetConnect -} = __nccwpck_require__(91117) -const { buildURL } = __nccwpck_require__(3440) +} = __nccwpck_require__(80832) +const { buildURL } = __nccwpck_require__(93865) const { STATUS_CODES } = __nccwpck_require__(37067) const { types: { @@ -56914,7 +57683,7 @@ module.exports = { /***/ }), -/***/ 56142: +/***/ 62595: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { @@ -56964,7 +57733,7 @@ module.exports = class PendingInterceptorsFormatter { /***/ }), -/***/ 91529: +/***/ 78820: /***/ ((module) => { @@ -57000,7 +57769,7 @@ module.exports = class Pluralizer { /***/ }), -/***/ 96603: +/***/ 42366: /***/ ((module) => { @@ -57430,20 +58199,20 @@ module.exports = { /***/ }), -/***/ 89634: +/***/ 5779: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { kConstruct } = __nccwpck_require__(20109) -const { urlEquals, getFieldValues } = __nccwpck_require__(76798) -const { kEnumerableProperty, isDisturbed } = __nccwpck_require__(3440) -const { webidl } = __nccwpck_require__(45893) -const { Response, cloneResponse, fromInnerResponse } = __nccwpck_require__(99051) -const { Request, fromInnerRequest } = __nccwpck_require__(9967) -const { kState } = __nccwpck_require__(93627) -const { fetching } = __nccwpck_require__(54398) -const { urlIsHttpHttpsScheme, createDeferredPromise, readAllBytes } = __nccwpck_require__(73168) +const { kConstruct } = __nccwpck_require__(93276) +const { urlEquals, getFieldValues } = __nccwpck_require__(21269) +const { kEnumerableProperty, isDisturbed } = __nccwpck_require__(93865) +const { webidl } = __nccwpck_require__(8834) +const { Response, cloneResponse, fromInnerResponse } = __nccwpck_require__(26424) +const { Request, fromInnerRequest } = __nccwpck_require__(55830) +const { kState } = __nccwpck_require__(84162) +const { fetching } = __nccwpck_require__(4543) +const { urlIsHttpHttpsScheme, createDeferredPromise, readAllBytes } = __nccwpck_require__(14783) const assert = __nccwpck_require__(34589) /** @@ -58296,15 +59065,15 @@ module.exports = { /***/ }), -/***/ 3245: +/***/ 76734: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { kConstruct } = __nccwpck_require__(20109) -const { Cache } = __nccwpck_require__(89634) -const { webidl } = __nccwpck_require__(45893) -const { kEnumerableProperty } = __nccwpck_require__(3440) +const { kConstruct } = __nccwpck_require__(93276) +const { Cache } = __nccwpck_require__(5779) +const { webidl } = __nccwpck_require__(8834) +const { kEnumerableProperty } = __nccwpck_require__(93865) class CacheStorage { /** @@ -58455,26 +59224,26 @@ module.exports = { /***/ }), -/***/ 20109: +/***/ 93276: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { module.exports = { - kConstruct: (__nccwpck_require__(36443).kConstruct) + kConstruct: (__nccwpck_require__(77528).kConstruct) } /***/ }), -/***/ 76798: +/***/ 21269: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { const assert = __nccwpck_require__(34589) -const { URLSerializer } = __nccwpck_require__(51900) -const { isValidHeaderName } = __nccwpck_require__(73168) +const { URLSerializer } = __nccwpck_require__(25859) +const { isValidHeaderName } = __nccwpck_require__(14783) /** * @see https://url.spec.whatwg.org/#concept-url-equals @@ -58519,7 +59288,7 @@ module.exports = { /***/ }), -/***/ 71276: +/***/ 59881: /***/ ((module) => { @@ -58538,15 +59307,15 @@ module.exports = { /***/ }), -/***/ 79061: +/***/ 2724: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { parseSetCookie } = __nccwpck_require__(11978) -const { stringify } = __nccwpck_require__(57797) -const { webidl } = __nccwpck_require__(45893) -const { Headers } = __nccwpck_require__(60660) +const { parseSetCookie } = __nccwpck_require__(61895) +const { stringify } = __nccwpck_require__(6630) +const { webidl } = __nccwpck_require__(8834) +const { Headers } = __nccwpck_require__(65841) /** * @typedef {Object} Cookie @@ -58729,14 +59498,14 @@ module.exports = { /***/ }), -/***/ 11978: +/***/ 61895: /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => { -const { maxNameValuePairSize, maxAttributeValueSize } = __nccwpck_require__(71276) -const { isCTLExcludingHtab } = __nccwpck_require__(57797) -const { collectASequenceOfCodePointsFast } = __nccwpck_require__(51900) +const { maxNameValuePairSize, maxAttributeValueSize } = __nccwpck_require__(59881) +const { isCTLExcludingHtab } = __nccwpck_require__(6630) +const { collectASequenceOfCodePointsFast } = __nccwpck_require__(25859) const assert = __nccwpck_require__(34589) /** @@ -59009,32 +59778,25 @@ function parseUnparsedAttributes (unparsedAttributes, cookieAttributeList = {}) // If the attribute-name case-insensitively matches the string // "SameSite", the user agent MUST process the cookie-av as follows: - // 1. Let enforcement be "Default". - let enforcement = 'Default' - const attributeValueLowercase = attributeValue.toLowerCase() - // 2. If cookie-av's attribute-value is a case-insensitive match for - // "None", set enforcement to "None". - if (attributeValueLowercase.includes('none')) { - enforcement = 'None' - } - - // 3. If cookie-av's attribute-value is a case-insensitive match for - // "Strict", set enforcement to "Strict". - if (attributeValueLowercase.includes('strict')) { - enforcement = 'Strict' - } - // 4. If cookie-av's attribute-value is a case-insensitive match for - // "Lax", set enforcement to "Lax". - if (attributeValueLowercase.includes('lax')) { - enforcement = 'Lax' + // 1. If cookie-av's attribute-value is a case-insensitive match for + // "None", append an attribute to the cookie-attribute-list with an + // attribute-name of "SameSite" and an attribute-value of "None". + if (attributeValueLowercase === 'none') { + cookieAttributeList.sameSite = 'None' + } else if (attributeValueLowercase === 'strict') { + // 2. If cookie-av's attribute-value is a case-insensitive match for + // "Strict", append an attribute to the cookie-attribute-list with + // an attribute-name of "SameSite" and an attribute-value of + // "Strict". + cookieAttributeList.sameSite = 'Strict' + } else if (attributeValueLowercase === 'lax') { + // 3. If cookie-av's attribute-value is a case-insensitive match for + // "Lax", append an attribute to the cookie-attribute-list with an + // attribute-name of "SameSite" and an attribute-value of "Lax". + cookieAttributeList.sameSite = 'Lax' } - - // 5. Append an attribute to the cookie-attribute-list with an - // attribute-name of "SameSite" and an attribute-value of - // enforcement. - cookieAttributeList.sameSite = enforcement } else { cookieAttributeList.unparsed ??= [] @@ -59053,7 +59815,7 @@ module.exports = { /***/ }), -/***/ 57797: +/***/ 6630: /***/ ((module) => { @@ -59163,7 +59925,7 @@ function validateCookiePath (path) { if ( code < 0x20 || // exclude CTLs (0-31) - code === 0x7F || // DEL + code > 0x7E || // exclude DEL and non-ascii code === 0x3B // ; ) { throw new Error('Invalid cookie path') @@ -59172,16 +59934,80 @@ function validateCookiePath (path) { } /** - * I have no idea why these values aren't allowed to be honest, - * but Deno tests these. - Khafra + * ::= | + * + * ::= any one of the 52 alphabetic characters A through Z in + * upper case and a through z in lower case + * + * ::= any one of the ten digits 0 through 9r + * + * @see https://www.rfc-editor.org/rfc/rfc1034#section-3.5 + * @param {number} code + */ +function isLetterOrDigit (code) { + return ( + (code >= 0x30 && code <= 0x39) || // 0-9 + (code >= 0x41 && code <= 0x5A) || // A-Z + (code >= 0x61 && code <= 0x7A) // a-z + ) +} + +/** + * Validates a cookie domain against the "preferred name syntax". + * + * ::= | " " + * ::=