From 1fea256128087563a1f5966445cda10fad8451bf Mon Sep 17 00:00:00 2001 From: AbsoluteC2H6O Date: Thu, 24 Apr 2025 11:19:50 -0400 Subject: [PATCH 1/7] roldown(migration): First migration to rolldown First bundle creation. --- README.md | 2 +- bun.lock | 45 + package-lock.json | 18814 +++++++++++++++++++++++++++++++++++++++++++ package.json | 5 +- resetup.ps1 | 1 + rolldown.config.js | 8 + rollup.config.js | 39 - 7 files changed, 18872 insertions(+), 42 deletions(-) create mode 100644 package-lock.json create mode 100644 rolldown.config.js delete mode 100644 rollup.config.js diff --git a/README.md b/README.md index dc4fac9..f31e247 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ Purger plugin for rollup hand crafted to match vue3-ui needs ## Usage -Import plugin and register plugin in _rollup.config.js_ +Import plugin and register plugin in rolldown.config.js\_ import vue3uiPurge from "@pathscale/rollup-plugin-vue3-ui-css-purge"; diff --git a/bun.lock b/bun.lock index 95af73b..8d73d5a 100644 --- a/bun.lock +++ b/bun.lock @@ -57,6 +57,7 @@ "jest-circus": "^26.6.3", "lint-staged": "^10.5.3", "prettier": "^2.2.1", + "rolldown": "1.0.0-beta.8", "rollup-plugin-dts": "^2.0.1", "rollup-plugin-node-externals": "^2.2.0", "rollup-plugin-styles": "^3.12.1", @@ -332,6 +333,12 @@ "@commitlint/types": ["@commitlint/types@11.0.0", "", {}, "sha512-VoNqai1vR5anRF5Tuh/+SWDFk7xi7oMwHrHrbm1BprYXjB2RJsWLhUrStMssDxEl5lW/z3EUdg8RvH/IUBccSQ=="], + "@emnapi/core": ["@emnapi/core@1.4.3", "https://registry.npmmirror.com/@emnapi/core/-/core-1.4.3.tgz", { "dependencies": { "@emnapi/wasi-threads": "1.0.2", "tslib": "^2.4.0" } }, "sha512-4m62DuCE07lw01soJwPiBGC0nAww0Q+RY70VZ+n49yDIO13yyinhbWCeNnaob0lakDtWQzSdtNWzJeOJt2ma+g=="], + + "@emnapi/runtime": ["@emnapi/runtime@1.4.3", "https://registry.npmmirror.com/@emnapi/runtime/-/runtime-1.4.3.tgz", { "dependencies": { "tslib": "^2.4.0" } }, "sha512-pBPWdu6MLKROBX05wSNKcNb++m5Er+KQ9QkB+WVM+pW2Kx9hoSrVTnu3BdkI5eBLZoKu/J6mW/B6i6bJB2ytXQ=="], + + "@emnapi/wasi-threads": ["@emnapi/wasi-threads@1.0.2", "https://registry.npmmirror.com/@emnapi/wasi-threads/-/wasi-threads-1.0.2.tgz", { "dependencies": { "tslib": "^2.4.0" } }, "sha512-5n3nTJblwRi8LlXkJ9eBzu+kZR8Yxcc7ubakyQTFzPMtIhFpUBRbsnc2Dv88IZDIbCDlBiWrknhB4Lsz7mg6BA=="], + "@eslint/eslintrc": ["@eslint/eslintrc@0.4.3", "", { "dependencies": { "ajv": "^6.12.4", "debug": "^4.1.1", "espree": "^7.3.0", "globals": "^13.9.0", "ignore": "^4.0.6", "import-fresh": "^3.2.1", "js-yaml": "^3.13.1", "minimatch": "^3.0.4", "strip-json-comments": "^3.1.1" } }, "sha512-J6KFFz5QCYUJq3pf0mjEcCJVERbzv71PUIDczuh9JkwGEzced6CO5ADLHB1rbf/+oPBtoPfMYNOpGDzCANlbXw=="], "@fullhuman/postcss-purgecss": ["@fullhuman/postcss-purgecss@3.1.3", "", { "dependencies": { "purgecss": "^3.1.3" } }, "sha512-kwOXw8fZ0Lt1QmeOOrd+o4Ibvp4UTEBFQbzvWldjlKv5n+G9sXfIPn1hh63IQIL8K8vbvv1oYMJiIUbuy9bGaA=="], @@ -376,6 +383,8 @@ "@jridgewell/trace-mapping": ["@jridgewell/trace-mapping@0.3.25", "", { "dependencies": { "@jridgewell/resolve-uri": "^3.1.0", "@jridgewell/sourcemap-codec": "^1.4.14" } }, "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ=="], + "@napi-rs/wasm-runtime": ["@napi-rs/wasm-runtime@0.2.9", "https://registry.npmmirror.com/@napi-rs/wasm-runtime/-/wasm-runtime-0.2.9.tgz", { "dependencies": { "@emnapi/core": "^1.4.0", "@emnapi/runtime": "^1.4.0", "@tybys/wasm-util": "^0.9.0" } }, "sha512-OKRBiajrrxB9ATokgEQoG87Z25c67pCpYcCwmXYX8PBftC9pBfN18gnm/fh1wurSLEKIAt+QRFLFCQISrb66Jg=="], + "@nicolo-ribaudo/eslint-scope-5-internals": ["@nicolo-ribaudo/eslint-scope-5-internals@5.1.1-v1", "", { "dependencies": { "eslint-scope": "5.1.1" } }, "sha512-54/JRvkLIzzDWshCWfuhadfrfZVPiElY8Fcgmg1HroEly/EDSszzhBAsarCux+D/kOslTRquNzuyGSmUSTTHGg=="], "@nodelib/fs.scandir": ["@nodelib/fs.scandir@2.1.5", "", { "dependencies": { "@nodelib/fs.stat": "2.0.5", "run-parallel": "^1.1.9" } }, "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g=="], @@ -408,10 +417,36 @@ "@octokit/types": ["@octokit/types@6.41.0", "", { "dependencies": { "@octokit/openapi-types": "^12.11.0" } }, "sha512-eJ2jbzjdijiL3B4PrSQaSjuF2sPEQPVCPzBvTHJD9Nz+9dw2SGH4K4xeQJ77YfTq5bRQ+bD8wT11JbeDPmxmGg=="], + "@oxc-project/types": ["@oxc-project/types@0.65.0", "https://registry.npmmirror.com/@oxc-project/types/-/types-0.65.0.tgz", {}, "sha512-7MpMzyXCcwxrTxJ4L0siy63Ds/LA8LAM4szumTFiynxTJkfrIZEV4PyR4Th0CqFZQ+oNi8WvW3Dr1MLy7o9qPQ=="], + "@pathscale/bulma-extensions-css-var": ["@pathscale/bulma-extensions-css-var@0.0.49-3", "", {}, "sha512-hjG+sCvDO9d2VhIznekHgWBmqsdCRwhm/ddOLthUDH0OywYpVQxGppI1IoDzcmpDsd3qUuRgdQ3vwrCsgbafTQ=="], "@pathscale/vue3-ui": ["@pathscale/vue3-ui@0.8.156", "", { "peerDependencies": { "vue": "3.0.7" } }, "sha512-bgIy9EsMKkGLN2zGiqVlod0wvxFGa/Eh8s64hkqzAIID2WfWIi2txKZzjwLdJnk7Dfo3lTwVDfdhh92M3+XLTw=="], + "@rolldown/binding-darwin-arm64": ["@rolldown/binding-darwin-arm64@1.0.0-beta.8", "https://registry.npmmirror.com/@rolldown/binding-darwin-arm64/-/binding-darwin-arm64-1.0.0-beta.8.tgz", { "os": "darwin", "cpu": "arm64" }, "sha512-4cwzBnUvPUVdjUMo9uFkcTvj+Z6IXaN/YJSz1RuI/DG5+vlQ9wYfKeDkvb1nsrhi4ZJ99OInOw1Vh/n2ReX8rA=="], + + "@rolldown/binding-darwin-x64": ["@rolldown/binding-darwin-x64@1.0.0-beta.8", "https://registry.npmmirror.com/@rolldown/binding-darwin-x64/-/binding-darwin-x64-1.0.0-beta.8.tgz", { "os": "darwin", "cpu": "x64" }, "sha512-BYI7UXc0UqjdpmEyNpxulv8cYbTdL7zLzIr6GDdIvHH7fe/pKTmC9GpvkpF/j2cyP0SUKTd6ExX7nFDNDqKMBw=="], + + "@rolldown/binding-freebsd-x64": ["@rolldown/binding-freebsd-x64@1.0.0-beta.8", "https://registry.npmmirror.com/@rolldown/binding-freebsd-x64/-/binding-freebsd-x64-1.0.0-beta.8.tgz", { "os": "freebsd", "cpu": "x64" }, "sha512-KsX/nuGiuNugIeBelN7M7c/8kzcAW6IfH080z9IrIrlCaGa+xwjqMAf7JuYLZo82uokFq8nql0YpQIazFwFR0Q=="], + + "@rolldown/binding-linux-arm-gnueabihf": ["@rolldown/binding-linux-arm-gnueabihf@1.0.0-beta.8", "https://registry.npmmirror.com/@rolldown/binding-linux-arm-gnueabihf/-/binding-linux-arm-gnueabihf-1.0.0-beta.8.tgz", { "os": "linux", "cpu": "arm" }, "sha512-IzmoAB9J9iOnoC2Nb6AlyIPPULcbLb0qtJDq21+95u/qiE2GYtI5M4aNudbAIdyv0MU4SAdhkG2sXjMo79H/Zg=="], + + "@rolldown/binding-linux-arm64-gnu": ["@rolldown/binding-linux-arm64-gnu@1.0.0-beta.8", "https://registry.npmmirror.com/@rolldown/binding-linux-arm64-gnu/-/binding-linux-arm64-gnu-1.0.0-beta.8.tgz", { "os": "linux", "cpu": "arm64" }, "sha512-nGtOvVKMywOlqoFiMJgILgCpdVcPe0psH1oCWtieMyFFU/v2h2ucjstAEeCOe+JfMVVA7OpdNoWKc54Y1V7gGw=="], + + "@rolldown/binding-linux-arm64-musl": ["@rolldown/binding-linux-arm64-musl@1.0.0-beta.8", "https://registry.npmmirror.com/@rolldown/binding-linux-arm64-musl/-/binding-linux-arm64-musl-1.0.0-beta.8.tgz", { "os": "linux", "cpu": "arm64" }, "sha512-paTZphpweKHNwlIu0JTAJCddn/psFzNUaKeGEY4vTQEqDcewKp9SsxN7240ao1eqTYy6TMFJiX6Ej2ym93MkSQ=="], + + "@rolldown/binding-linux-x64-gnu": ["@rolldown/binding-linux-x64-gnu@1.0.0-beta.8", "https://registry.npmmirror.com/@rolldown/binding-linux-x64-gnu/-/binding-linux-x64-gnu-1.0.0-beta.8.tgz", { "os": "linux", "cpu": "x64" }, "sha512-Pdt5iaG/wlWTvEz1lZ3kDkmVXM7DxQXPFZUX/UjDnUyxf4vSgxszbSx1tiNdU0D9v1IISgBapANSwJOGtF1lWw=="], + + "@rolldown/binding-linux-x64-musl": ["@rolldown/binding-linux-x64-musl@1.0.0-beta.8", "https://registry.npmmirror.com/@rolldown/binding-linux-x64-musl/-/binding-linux-x64-musl-1.0.0-beta.8.tgz", { "os": "linux", "cpu": "x64" }, "sha512-8LoLgKq+Wb030p+tzw0JrOrbJrR2wmqfARX1CHIhge8LBoxd2lfHtWfkg23qRa1S8So/nBZBhrQsg2kXUkpwxw=="], + + "@rolldown/binding-wasm32-wasi": ["@rolldown/binding-wasm32-wasi@1.0.0-beta.8", "https://registry.npmmirror.com/@rolldown/binding-wasm32-wasi/-/binding-wasm32-wasi-1.0.0-beta.8.tgz", { "dependencies": { "@napi-rs/wasm-runtime": "^0.2.4" }, "cpu": "none" }, "sha512-+2y9Omf9tZRR44Y4EYqm3/Zq2f4Tv+Gh8NsExFWM6WpQZI3HyIB07lrTNQfOJgKSsAiUisnbjiPVTkiH5miy1w=="], + + "@rolldown/binding-win32-arm64-msvc": ["@rolldown/binding-win32-arm64-msvc@1.0.0-beta.8", "https://registry.npmmirror.com/@rolldown/binding-win32-arm64-msvc/-/binding-win32-arm64-msvc-1.0.0-beta.8.tgz", { "os": "win32", "cpu": "arm64" }, "sha512-bt5AOleb2yp+Br9Yzew+jbSEGjLoqGwknH0xhK8QkhXKx31sJLseaP7nFXr6JaEbmL4DVmAVgrOcyLzLbR6+Mw=="], + + "@rolldown/binding-win32-ia32-msvc": ["@rolldown/binding-win32-ia32-msvc@1.0.0-beta.8", "https://registry.npmmirror.com/@rolldown/binding-win32-ia32-msvc/-/binding-win32-ia32-msvc-1.0.0-beta.8.tgz", { "os": "win32", "cpu": "ia32" }, "sha512-Fa1OH6eUWtjBNNkKiSSq1fHVMuiqQ+Bi9uMNJz7gBFgjNiAB9k9rQr0j9eF1k4H6lXFkuoN5P7pXty6aBh93Cw=="], + + "@rolldown/binding-win32-x64-msvc": ["@rolldown/binding-win32-x64-msvc@1.0.0-beta.8", "https://registry.npmmirror.com/@rolldown/binding-win32-x64-msvc/-/binding-win32-x64-msvc-1.0.0-beta.8.tgz", { "os": "win32", "cpu": "x64" }, "sha512-hR81d84Poe6oIxaz4PnWBLVF0VuqtRfISIyXQAgk2etu2udrKnWKr3A+xqXe9ELjbLlRYGvEm2dlw/cldO9Kxg=="], + "@rollup/plugin-babel": ["@rollup/plugin-babel@5.3.1", "", { "dependencies": { "@babel/helper-module-imports": "^7.10.4", "@rollup/pluginutils": "^3.1.0" }, "peerDependencies": { "@babel/core": "^7.0.0", "@types/babel__core": "^7.1.9", "rollup": "^1.20.0||^2.0.0" }, "optionalPeers": ["@types/babel__core"] }, "sha512-WFfdLWU/xVWKeRQnKmIAQULUI7Il0gZnBIH/ZFO069wYIfPu+8zrfp/KMW0atmELoRDq8FbiP3VCss9MhCut7Q=="], "@rollup/plugin-commonjs": ["@rollup/plugin-commonjs@17.1.0", "", { "dependencies": { "@rollup/pluginutils": "^3.1.0", "commondir": "^1.0.1", "estree-walker": "^2.0.1", "glob": "^7.1.6", "is-reference": "^1.2.1", "magic-string": "^0.25.7", "resolve": "^1.17.0" }, "peerDependencies": { "rollup": "^2.30.0" } }, "sha512-PoMdXCw0ZyvjpCMT5aV4nkL0QywxP29sODQsSGeDpr/oI49Qq9tRtAsb/LbYbDzFlOydVEqHmmZWFtXJEAX9ew=="], @@ -448,6 +483,8 @@ "@tootallnate/once": ["@tootallnate/once@1.1.2", "", {}, "sha512-RbzJvlNzmRq5c3O09UipeuXno4tA1FE6ikOjxZK0tuxVv3412l64l5t1W5pj4+rJq9vpkm/kwiR07aZXnsKPxw=="], + "@tybys/wasm-util": ["@tybys/wasm-util@0.9.0", "https://registry.npmmirror.com/@tybys/wasm-util/-/wasm-util-0.9.0.tgz", { "dependencies": { "tslib": "^2.4.0" } }, "sha512-6+7nlbMVX/PVDCwaIQ8nTOPveOcFLSt8GcXdx8hD0bt39uWxYT88uXzqTd4fTvqta7oeUJqudepapKNt2DYJFw=="], + "@types/babel__core": ["@types/babel__core@7.20.5", "", { "dependencies": { "@babel/parser": "^7.20.7", "@babel/types": "^7.20.7", "@types/babel__generator": "*", "@types/babel__template": "*", "@types/babel__traverse": "*" } }, "sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA=="], "@types/babel__generator": ["@types/babel__generator@7.27.0", "", { "dependencies": { "@babel/types": "^7.0.0" } }, "sha512-ufFd2Xi92OAVPYsy+P4n7/U7e68fex0+Ee8gSG9KX7eo084CWiQ4sdxktvdl0bOPupXtVJPY19zk6EwWqUQ8lg=="], @@ -518,6 +555,8 @@ "@typescript-eslint/visitor-keys": ["@typescript-eslint/visitor-keys@4.33.0", "", { "dependencies": { "@typescript-eslint/types": "4.33.0", "eslint-visitor-keys": "^2.0.0" } }, "sha512-uqi/2aSz9g2ftcHWf8uLPJA70rUv6yuMW5Bohw+bwcuzaxQIHaKFZCKGoGXIrc9vkTJ3+0txM73K0Hq3d5wgIg=="], + "@valibot/to-json-schema": ["@valibot/to-json-schema@1.0.0", "https://registry.npmmirror.com/@valibot/to-json-schema/-/to-json-schema-1.0.0.tgz", { "peerDependencies": { "valibot": "^1.0.0" } }, "sha512-/9crJgPptVsGCL6X+JPDQyaJwkalSZ/52WuF8DiRUxJgcmpNdzYRfZ+gqMEP8W3CTVfuMWPqqvIgfwJ97f9Etw=="], + "@vue/compiler-core": ["@vue/compiler-core@3.0.7", "", { "dependencies": { "@babel/parser": "^7.12.0", "@babel/types": "^7.12.0", "@vue/shared": "3.0.7", "estree-walker": "^2.0.1", "source-map": "^0.6.1" } }, "sha512-JFohgBXoyUc3mdeI2WxlhjQZ5fakfemJkZHX8Gu/nFbEg3+lKVUZmNKWmmnp9aOzJQZKoj77LjmFxiP+P+7lMQ=="], "@vue/compiler-dom": ["@vue/compiler-dom@3.0.7", "", { "dependencies": { "@vue/compiler-core": "3.0.7", "@vue/shared": "3.0.7" } }, "sha512-VnIH9EbWQm/Tkcp+8dCaNVsVvhm/vxCrIKWRkXY9215hTqOqQOvejT8IMjd2kc++nIsYMsdQk6H9qqBvoLe/Cw=="], @@ -564,6 +603,8 @@ "ansicolors": ["ansicolors@0.3.2", "", {}, "sha512-QXu7BPrP29VllRxH8GwB7x5iX5qWKAAMLqKQGWTeLWVlNHNOpVMJ91dsxQAIWXpjuW5wqvxu3Jd/nRjrJ+0pqg=="], + "ansis": ["ansis@3.17.0", "https://registry.npmmirror.com/ansis/-/ansis-3.17.0.tgz", {}, "sha512-0qWUglt9JEqLFr3w1I1pbrChn1grhaiAR2ocX1PP/flRmxgtwTzPFFFnfIlD6aMOLQZgSuCRlidD70lvx8yhzg=="], + "anymatch": ["anymatch@3.1.3", "", { "dependencies": { "normalize-path": "^3.0.0", "picomatch": "^2.0.4" } }, "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw=="], "argparse": ["argparse@1.0.10", "", { "dependencies": { "sprintf-js": "~1.0.2" } }, "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg=="], @@ -1814,6 +1855,8 @@ "rimraf": ["rimraf@3.0.2", "", { "dependencies": { "glob": "^7.1.3" }, "bin": { "rimraf": "bin.js" } }, "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA=="], + "rolldown": ["rolldown@1.0.0-beta.8", "https://registry.npmmirror.com/rolldown/-/rolldown-1.0.0-beta.8.tgz", { "dependencies": { "@oxc-project/types": "0.65.0", "@valibot/to-json-schema": "1.0.0", "ansis": "^3.17.0", "valibot": "1.0.0" }, "optionalDependencies": { "@rolldown/binding-darwin-arm64": "1.0.0-beta.8", "@rolldown/binding-darwin-x64": "1.0.0-beta.8", "@rolldown/binding-freebsd-x64": "1.0.0-beta.8", "@rolldown/binding-linux-arm-gnueabihf": "1.0.0-beta.8", "@rolldown/binding-linux-arm64-gnu": "1.0.0-beta.8", "@rolldown/binding-linux-arm64-musl": "1.0.0-beta.8", "@rolldown/binding-linux-x64-gnu": "1.0.0-beta.8", "@rolldown/binding-linux-x64-musl": "1.0.0-beta.8", "@rolldown/binding-wasm32-wasi": "1.0.0-beta.8", "@rolldown/binding-win32-arm64-msvc": "1.0.0-beta.8", "@rolldown/binding-win32-ia32-msvc": "1.0.0-beta.8", "@rolldown/binding-win32-x64-msvc": "1.0.0-beta.8" }, "peerDependencies": { "@oxc-project/runtime": "0.65.0" }, "optionalPeers": ["@oxc-project/runtime"], "bin": { "rolldown": "bin/cli.mjs" } }, "sha512-lwctoQjonOosxGhVbuoIARk8TNO2roqAh/ArhNmT/e/INMN+fzO0++yCypVZLZczOdgTARrYmsOEnTgMOt9sSg=="], + "rollup": ["rollup@2.79.2", "", { "optionalDependencies": { "fsevents": "~2.3.2" }, "bin": { "rollup": "dist/bin/rollup" } }, "sha512-fS6iqSPZDs3dr/y7Od6y5nha8dW1YnbgtsyotCVvoFGKbERG++CVRFv1meyGDE1SNItQA8BrnCw7ScdAhRJ3XQ=="], "rollup-plugin-dts": ["rollup-plugin-dts@2.0.1", "", { "dependencies": { "magic-string": "^0.25.7" }, "optionalDependencies": { "@babel/code-frame": "^7.10.4" }, "peerDependencies": { "rollup": "^2.34.2", "typescript": "^4.1.2" } }, "sha512-y38NSXIY37YExCumbGBTL5dXg7pL7XD+Kbe98iEHWFN9yiKJf7t4kKBOkml5ylUDjQIXBnNClGDeRktc1T5dmA=="], @@ -2110,6 +2153,8 @@ "v8-to-istanbul": ["v8-to-istanbul@7.1.2", "", { "dependencies": { "@types/istanbul-lib-coverage": "^2.0.1", "convert-source-map": "^1.6.0", "source-map": "^0.7.3" } }, "sha512-TxNb7YEUwkLXCQYeudi6lgQ/SZrzNO4kMdlqVxaZPUIUjCv6iSSypUQX70kNBSERpQ8fk48+d61FXk+tgqcWow=="], + "valibot": ["valibot@1.0.0", "https://registry.npmmirror.com/valibot/-/valibot-1.0.0.tgz", { "peerDependencies": { "typescript": ">=5" }, "optionalPeers": ["typescript"] }, "sha512-1Hc0ihzWxBar6NGeZv7fPLY0QuxFMyxwYR2sF1Blu7Wq7EnremwY2W02tit2ij2VJT8HcSkHAQqmFfl77f73Yw=="], + "validate-npm-package-license": ["validate-npm-package-license@3.0.4", "", { "dependencies": { "spdx-correct": "^3.0.0", "spdx-expression-parse": "^3.0.0" } }, "sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew=="], "vendors": ["vendors@1.0.4", "", {}, "sha512-/juG65kTL4Cy2su4P8HjtkTxk6VmJDiOPBufWniqQ6wknac6jNiXS9vU+hO3wgusiyqWlzTbVHi0dyJqRONg3w=="], diff --git a/package-lock.json b/package-lock.json new file mode 100644 index 0000000..8de86ef --- /dev/null +++ b/package-lock.json @@ -0,0 +1,18814 @@ +{ + "name": "@pathscale/rollup-plugin-vue3-ui-css-purge", + "version": "0.0.41", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "@pathscale/rollup-plugin-vue3-ui-css-purge", + "version": "0.0.41", + "license": "MIT", + "dependencies": { + "@babel/parser": "^7.12.11", + "@babel/traverse": "^7.12.12", + "@fullhuman/postcss-purgecss": "^3.1.3", + "@rollup/pluginutils": "^4.1.0", + "fs-extra": "^9.0.1", + "htmlparser2": "^6.0.0", + "postcss": "^8.2.2", + "postcss-color-converter": "^1.0.1", + "query-string": "^6.13.8", + "resolve": "^1.19.0", + "rollup": "^2.35.1", + "tslib": "^2.0.3" + }, + "devDependencies": { + "@babel/core": "^7.12.10", + "@babel/plugin-proposal-class-properties": "^7.12.1", + "@babel/preset-env": "^7.12.11", + "@bulvar/bulma": "^0.11.24", + "@commitlint/cli": "^11.0.0", + "@commitlint/config-angular": "^11.0.0", + "@commitlint/prompt-cli": "^11.0.0", + "@pathscale/bulma-extensions-css-var": "0.0.49-3", + "@pathscale/vue3-ui": "^0.8.146", + "@rollup/plugin-babel": "^5.2.2", + "@rollup/plugin-commonjs": "^17.0.0", + "@rollup/plugin-json": "^4.1.0", + "@rollup/plugin-node-resolve": "^11.0.1", + "@rollup/plugin-replace": "^2.3.4", + "@rollup/plugin-typescript": "^8.1.0", + "@semantic-release/changelog": "^5.0.1", + "@semantic-release/git": "^9.0.0", + "@types/fs-extra": "^9.0.6", + "@types/htmlparser2": "^3.10.2", + "@types/jest": "^26.0.19", + "@types/node": "*", + "@types/resolve": "^1.17.1", + "@typescript-eslint/eslint-plugin": "^4.11.1", + "@typescript-eslint/parser": "^4.11.1", + "@vue/compiler-sfc": "3.0.7", + "builtin-modules": "^3.2.0", + "eslint": "^7.16.0", + "eslint-config-prettier": "^7.1.0", + "eslint-import-resolver-node": "^0.3.4", + "eslint-plugin-import": "^2.22.1", + "eslint-plugin-jest": "^24.1.3", + "eslint-plugin-node": "^11.1.0", + "eslint-plugin-unicorn": "^25.0.1", + "fast-glob": "^3.2.4", + "husky": "^4.3.6", + "jest": "^26.6.3", + "jest-circus": "^26.6.3", + "lint-staged": "^10.5.3", + "prettier": "^2.2.1", + "rolldown": "1.0.0-beta.8", + "rollup-plugin-dts": "^2.0.1", + "rollup-plugin-node-externals": "^2.2.0", + "rollup-plugin-styles": "^3.12.1", + "rollup-plugin-vue": "^6.0.0", + "semantic-release": "^17.3.1", + "shx": "^0.3.3", + "ts-jest": "^26.4.4", + "typescript": "^4.1.3", + "vue": "3.0.7" + }, + "engines": { + "node": ">=10" + }, + "peerDependencies": { + "rollup": "^2.2.0", + "typescript": "^4.0.0" + } + }, + "node_modules/@ampproject/remapping": { + "version": "2.3.0", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.24" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@babel/code-frame": { + "version": "7.26.2", + "license": "MIT", + "dependencies": { + "@babel/helper-validator-identifier": "^7.25.9", + "js-tokens": "^4.0.0", + "picocolors": "^1.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/compat-data": { + "version": "7.26.8", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/core": { + "version": "7.26.10", + "dev": true, + "license": "MIT", + "dependencies": { + "@ampproject/remapping": "^2.2.0", + "@babel/code-frame": "^7.26.2", + "@babel/generator": "^7.26.10", + "@babel/helper-compilation-targets": "^7.26.5", + "@babel/helper-module-transforms": "^7.26.0", + "@babel/helpers": "^7.26.10", + "@babel/parser": "^7.26.10", + "@babel/template": "^7.26.9", + "@babel/traverse": "^7.26.10", + "@babel/types": "^7.26.10", + "convert-source-map": "^2.0.0", + "debug": "^4.1.0", + "gensync": "^1.0.0-beta.2", + "json5": "^2.2.3", + "semver": "^6.3.1" + }, + "engines": { + "node": ">=6.9.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/babel" + } + }, + "node_modules/@babel/eslint-parser": { + "version": "7.27.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@nicolo-ribaudo/eslint-scope-5-internals": "5.1.1-v1", + "eslint-visitor-keys": "^2.1.0", + "semver": "^6.3.1" + }, + "engines": { + "node": "^10.13.0 || ^12.13.0 || >=14.0.0" + }, + "peerDependencies": { + "@babel/core": "^7.11.0", + "eslint": "^7.5.0 || ^8.0.0 || ^9.0.0" + } + }, + "node_modules/@babel/generator": { + "version": "7.27.0", + "license": "MIT", + "dependencies": { + "@babel/parser": "^7.27.0", + "@babel/types": "^7.27.0", + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.25", + "jsesc": "^3.0.2" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-annotate-as-pure": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/types": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-compilation-targets": { + "version": "7.27.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/compat-data": "^7.26.8", + "@babel/helper-validator-option": "^7.25.9", + "browserslist": "^4.24.0", + "lru-cache": "^5.1.1", + "semver": "^6.3.1" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-create-class-features-plugin": { + "version": "7.27.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.25.9", + "@babel/helper-member-expression-to-functions": "^7.25.9", + "@babel/helper-optimise-call-expression": "^7.25.9", + "@babel/helper-replace-supers": "^7.26.5", + "@babel/helper-skip-transparent-expression-wrappers": "^7.25.9", + "@babel/traverse": "^7.27.0", + "semver": "^6.3.1" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-create-regexp-features-plugin": { + "version": "7.27.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.25.9", + "regexpu-core": "^6.2.0", + "semver": "^6.3.1" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-define-polyfill-provider": { + "version": "0.6.4", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-compilation-targets": "^7.22.6", + "@babel/helper-plugin-utils": "^7.22.5", + "debug": "^4.1.1", + "lodash.debounce": "^4.0.8", + "resolve": "^1.14.2" + }, + "peerDependencies": { + "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" + } + }, + "node_modules/@babel/helper-member-expression-to-functions": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/traverse": "^7.25.9", + "@babel/types": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-module-imports": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/traverse": "^7.25.9", + "@babel/types": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-module-transforms": { + "version": "7.26.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-module-imports": "^7.25.9", + "@babel/helper-validator-identifier": "^7.25.9", + "@babel/traverse": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-optimise-call-expression": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/types": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-plugin-utils": { + "version": "7.26.5", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-remap-async-to-generator": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.25.9", + "@babel/helper-wrap-function": "^7.25.9", + "@babel/traverse": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-replace-supers": { + "version": "7.26.5", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-member-expression-to-functions": "^7.25.9", + "@babel/helper-optimise-call-expression": "^7.25.9", + "@babel/traverse": "^7.26.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-skip-transparent-expression-wrappers": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/traverse": "^7.25.9", + "@babel/types": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-string-parser": { + "version": "7.25.9", + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-identifier": { + "version": "7.25.9", + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-option": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-wrap-function": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/template": "^7.25.9", + "@babel/traverse": "^7.25.9", + "@babel/types": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helpers": { + "version": "7.27.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/template": "^7.27.0", + "@babel/types": "^7.27.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/highlight": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-validator-identifier": "^7.25.9", + "chalk": "^2.4.2", + "js-tokens": "^4.0.0", + "picocolors": "^1.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/highlight/node_modules/chalk": { + "version": "2.4.2", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/@babel/highlight/node_modules/chalk/node_modules/ansi-styles": { + "version": "3.2.1", + "dev": true, + "license": "MIT", + "dependencies": { + "color-convert": "^1.9.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/@babel/highlight/node_modules/chalk/node_modules/ansi-styles/node_modules/color-convert": { + "version": "1.9.3", + "dev": true, + "license": "MIT", + "dependencies": { + "color-name": "1.1.3" + } + }, + "node_modules/@babel/highlight/node_modules/chalk/node_modules/ansi-styles/node_modules/color-convert/node_modules/color-name": { + "version": "1.1.3", + "dev": true, + "license": "MIT" + }, + "node_modules/@babel/highlight/node_modules/chalk/node_modules/escape-string-regexp": { + "version": "1.0.5", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/@babel/highlight/node_modules/chalk/node_modules/supports-color": { + "version": "5.5.0", + "dev": true, + "license": "MIT", + "dependencies": { + "has-flag": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/@babel/highlight/node_modules/chalk/node_modules/supports-color/node_modules/has-flag": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/@babel/parser": { + "version": "7.27.0", + "license": "MIT", + "dependencies": { + "@babel/types": "^7.27.0" + }, + "bin": { + "parser": "bin/babel-parser.js" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@babel/plugin-bugfix-firefox-class-in-computed-class-key": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9", + "@babel/traverse": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/plugin-bugfix-safari-class-field-initializer-scope": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9", + "@babel/helper-skip-transparent-expression-wrappers": "^7.25.9", + "@babel/plugin-transform-optional-chaining": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.13.0" + } + }, + "node_modules/@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9", + "@babel/traverse": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/plugin-proposal-class-properties": { + "version": "7.18.6", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-create-class-features-plugin": "^7.18.6", + "@babel/helper-plugin-utils": "^7.18.6" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-proposal-private-property-in-object": { + "version": "7.21.0-placeholder-for-preset-env.2", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-async-generators": { + "version": "7.8.4", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-bigint": { + "version": "7.8.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-class-properties": { + "version": "7.12.13", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.12.13" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-class-static-block": { + "version": "7.14.5", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-import-assertions": { + "version": "7.26.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-import-attributes": { + "version": "7.26.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-import-meta": { + "version": "7.10.4", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.10.4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-json-strings": { + "version": "7.8.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-logical-assignment-operators": { + "version": "7.10.4", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.10.4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-nullish-coalescing-operator": { + "version": "7.8.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-numeric-separator": { + "version": "7.10.4", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.10.4" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-object-rest-spread": { + "version": "7.8.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-optional-catch-binding": { + "version": "7.8.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-optional-chaining": { + "version": "7.8.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.8.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-private-property-in-object": { + "version": "7.14.5", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-top-level-await": { + "version": "7.14.5", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.14.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-syntax-unicode-sets-regex": { + "version": "7.18.6", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.18.6", + "@babel/helper-plugin-utils": "^7.18.6" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/plugin-transform-arrow-functions": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-async-generator-functions": { + "version": "7.26.8", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.26.5", + "@babel/helper-remap-async-to-generator": "^7.25.9", + "@babel/traverse": "^7.26.8" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-async-to-generator": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-module-imports": "^7.25.9", + "@babel/helper-plugin-utils": "^7.25.9", + "@babel/helper-remap-async-to-generator": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-block-scoped-functions": { + "version": "7.26.5", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.26.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-block-scoping": { + "version": "7.27.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.26.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-class-properties": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-create-class-features-plugin": "^7.25.9", + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-class-static-block": { + "version": "7.26.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-create-class-features-plugin": "^7.25.9", + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.12.0" + } + }, + "node_modules/@babel/plugin-transform-classes": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.25.9", + "@babel/helper-compilation-targets": "^7.25.9", + "@babel/helper-plugin-utils": "^7.25.9", + "@babel/helper-replace-supers": "^7.25.9", + "@babel/traverse": "^7.25.9", + "globals": "^11.1.0" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-classes/node_modules/globals": { + "version": "11.12.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/@babel/plugin-transform-computed-properties": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9", + "@babel/template": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-destructuring": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-dotall-regex": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.25.9", + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-duplicate-keys": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-duplicate-named-capturing-groups-regex": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.25.9", + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/plugin-transform-dynamic-import": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-exponentiation-operator": { + "version": "7.26.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-export-namespace-from": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-for-of": { + "version": "7.26.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.26.5", + "@babel/helper-skip-transparent-expression-wrappers": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-function-name": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-compilation-targets": "^7.25.9", + "@babel/helper-plugin-utils": "^7.25.9", + "@babel/traverse": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-json-strings": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-literals": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-logical-assignment-operators": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-member-expression-literals": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-modules-amd": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-module-transforms": "^7.25.9", + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-modules-commonjs": { + "version": "7.26.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-module-transforms": "^7.26.0", + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-modules-systemjs": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-module-transforms": "^7.25.9", + "@babel/helper-plugin-utils": "^7.25.9", + "@babel/helper-validator-identifier": "^7.25.9", + "@babel/traverse": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-modules-umd": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-module-transforms": "^7.25.9", + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-named-capturing-groups-regex": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.25.9", + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/plugin-transform-new-target": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-nullish-coalescing-operator": { + "version": "7.26.6", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.26.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-numeric-separator": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-object-rest-spread": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-compilation-targets": "^7.25.9", + "@babel/helper-plugin-utils": "^7.25.9", + "@babel/plugin-transform-parameters": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-object-super": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9", + "@babel/helper-replace-supers": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-optional-catch-binding": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-optional-chaining": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9", + "@babel/helper-skip-transparent-expression-wrappers": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-parameters": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-private-methods": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-create-class-features-plugin": "^7.25.9", + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-private-property-in-object": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.25.9", + "@babel/helper-create-class-features-plugin": "^7.25.9", + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-property-literals": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-regenerator": { + "version": "7.27.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.26.5", + "regenerator-transform": "^0.15.2" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-regexp-modifiers": { + "version": "7.26.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.25.9", + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/plugin-transform-reserved-words": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-shorthand-properties": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-spread": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9", + "@babel/helper-skip-transparent-expression-wrappers": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-sticky-regex": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-template-literals": { + "version": "7.26.8", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.26.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-typeof-symbol": { + "version": "7.27.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.26.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-unicode-escapes": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-unicode-property-regex": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.25.9", + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-unicode-regex": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.25.9", + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-unicode-sets-regex": { + "version": "7.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-create-regexp-features-plugin": "^7.25.9", + "@babel/helper-plugin-utils": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/preset-env": { + "version": "7.26.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/compat-data": "^7.26.8", + "@babel/helper-compilation-targets": "^7.26.5", + "@babel/helper-plugin-utils": "^7.26.5", + "@babel/helper-validator-option": "^7.25.9", + "@babel/plugin-bugfix-firefox-class-in-computed-class-key": "^7.25.9", + "@babel/plugin-bugfix-safari-class-field-initializer-scope": "^7.25.9", + "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression": "^7.25.9", + "@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining": "^7.25.9", + "@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly": "^7.25.9", + "@babel/plugin-proposal-private-property-in-object": "7.21.0-placeholder-for-preset-env.2", + "@babel/plugin-syntax-import-assertions": "^7.26.0", + "@babel/plugin-syntax-import-attributes": "^7.26.0", + "@babel/plugin-syntax-unicode-sets-regex": "^7.18.6", + "@babel/plugin-transform-arrow-functions": "^7.25.9", + "@babel/plugin-transform-async-generator-functions": "^7.26.8", + "@babel/plugin-transform-async-to-generator": "^7.25.9", + "@babel/plugin-transform-block-scoped-functions": "^7.26.5", + "@babel/plugin-transform-block-scoping": "^7.25.9", + "@babel/plugin-transform-class-properties": "^7.25.9", + "@babel/plugin-transform-class-static-block": "^7.26.0", + "@babel/plugin-transform-classes": "^7.25.9", + "@babel/plugin-transform-computed-properties": "^7.25.9", + "@babel/plugin-transform-destructuring": "^7.25.9", + "@babel/plugin-transform-dotall-regex": "^7.25.9", + "@babel/plugin-transform-duplicate-keys": "^7.25.9", + "@babel/plugin-transform-duplicate-named-capturing-groups-regex": "^7.25.9", + "@babel/plugin-transform-dynamic-import": "^7.25.9", + "@babel/plugin-transform-exponentiation-operator": "^7.26.3", + "@babel/plugin-transform-export-namespace-from": "^7.25.9", + "@babel/plugin-transform-for-of": "^7.26.9", + "@babel/plugin-transform-function-name": "^7.25.9", + "@babel/plugin-transform-json-strings": "^7.25.9", + "@babel/plugin-transform-literals": "^7.25.9", + "@babel/plugin-transform-logical-assignment-operators": "^7.25.9", + "@babel/plugin-transform-member-expression-literals": "^7.25.9", + "@babel/plugin-transform-modules-amd": "^7.25.9", + "@babel/plugin-transform-modules-commonjs": "^7.26.3", + "@babel/plugin-transform-modules-systemjs": "^7.25.9", + "@babel/plugin-transform-modules-umd": "^7.25.9", + "@babel/plugin-transform-named-capturing-groups-regex": "^7.25.9", + "@babel/plugin-transform-new-target": "^7.25.9", + "@babel/plugin-transform-nullish-coalescing-operator": "^7.26.6", + "@babel/plugin-transform-numeric-separator": "^7.25.9", + "@babel/plugin-transform-object-rest-spread": "^7.25.9", + "@babel/plugin-transform-object-super": "^7.25.9", + "@babel/plugin-transform-optional-catch-binding": "^7.25.9", + "@babel/plugin-transform-optional-chaining": "^7.25.9", + "@babel/plugin-transform-parameters": "^7.25.9", + "@babel/plugin-transform-private-methods": "^7.25.9", + "@babel/plugin-transform-private-property-in-object": "^7.25.9", + "@babel/plugin-transform-property-literals": "^7.25.9", + "@babel/plugin-transform-regenerator": "^7.25.9", + "@babel/plugin-transform-regexp-modifiers": "^7.26.0", + "@babel/plugin-transform-reserved-words": "^7.25.9", + "@babel/plugin-transform-shorthand-properties": "^7.25.9", + "@babel/plugin-transform-spread": "^7.25.9", + "@babel/plugin-transform-sticky-regex": "^7.25.9", + "@babel/plugin-transform-template-literals": "^7.26.8", + "@babel/plugin-transform-typeof-symbol": "^7.26.7", + "@babel/plugin-transform-unicode-escapes": "^7.25.9", + "@babel/plugin-transform-unicode-property-regex": "^7.25.9", + "@babel/plugin-transform-unicode-regex": "^7.25.9", + "@babel/plugin-transform-unicode-sets-regex": "^7.25.9", + "@babel/preset-modules": "0.1.6-no-external-plugins", + "babel-plugin-polyfill-corejs2": "^0.4.10", + "babel-plugin-polyfill-corejs3": "^0.11.0", + "babel-plugin-polyfill-regenerator": "^0.6.1", + "core-js-compat": "^3.40.0", + "semver": "^6.3.1" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/preset-modules": { + "version": "0.1.6-no-external-plugins", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.0.0", + "@babel/types": "^7.4.4", + "esutils": "^2.0.2" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0 || ^8.0.0-0 <8.0.0" + } + }, + "node_modules/@babel/runtime": { + "version": "7.27.0", + "dev": true, + "license": "MIT", + "dependencies": { + "regenerator-runtime": "^0.14.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/template": { + "version": "7.27.0", + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.26.2", + "@babel/parser": "^7.27.0", + "@babel/types": "^7.27.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/traverse": { + "version": "7.27.0", + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.26.2", + "@babel/generator": "^7.27.0", + "@babel/parser": "^7.27.0", + "@babel/template": "^7.27.0", + "@babel/types": "^7.27.0", + "debug": "^4.3.1", + "globals": "^11.1.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/traverse/node_modules/globals": { + "version": "11.12.0", + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/@babel/types": { + "version": "7.27.0", + "license": "MIT", + "dependencies": { + "@babel/helper-string-parser": "^7.25.9", + "@babel/helper-validator-identifier": "^7.25.9" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@bcoe/v8-coverage": { + "version": "0.2.3", + "dev": true, + "license": "MIT" + }, + "node_modules/@bulvar/bulma": { + "version": "0.11.24", + "dev": true, + "license": "MIT" + }, + "node_modules/@cnakazawa/watch": { + "version": "1.0.4", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "exec-sh": "^0.3.2", + "minimist": "^1.2.0" + }, + "bin": { + "watch": "cli.js" + }, + "engines": { + "node": ">=0.1.95" + } + }, + "node_modules/@colors/colors": { + "version": "1.5.0", + "dev": true, + "license": "MIT", + "optional": true, + "engines": { + "node": ">=0.1.90" + } + }, + "node_modules/@commitlint/cli": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/runtime": "^7.11.2", + "@commitlint/format": "^11.0.0", + "@commitlint/lint": "^11.0.0", + "@commitlint/load": "^11.0.0", + "@commitlint/read": "^11.0.0", + "chalk": "4.1.0", + "core-js": "^3.6.1", + "get-stdin": "8.0.0", + "lodash": "^4.17.19", + "resolve-from": "5.0.0", + "resolve-global": "1.0.0", + "yargs": "^15.1.0" + }, + "bin": { + "commitlint": "cli.js" + }, + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@commitlint/config-angular": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@commitlint/config-angular-type-enum": "^11.0.0" + }, + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@commitlint/config-angular-type-enum": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@commitlint/ensure": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@commitlint/types": "^11.0.0", + "lodash": "^4.17.19" + }, + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@commitlint/execute-rule": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@commitlint/format": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@commitlint/types": "^11.0.0", + "chalk": "^4.0.0" + }, + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@commitlint/is-ignored": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@commitlint/types": "^11.0.0", + "semver": "7.3.2" + }, + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@commitlint/is-ignored/node_modules/semver": { + "version": "7.3.2", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@commitlint/lint": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@commitlint/is-ignored": "^11.0.0", + "@commitlint/parse": "^11.0.0", + "@commitlint/rules": "^11.0.0", + "@commitlint/types": "^11.0.0" + }, + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@commitlint/load": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@commitlint/execute-rule": "^11.0.0", + "@commitlint/resolve-extends": "^11.0.0", + "@commitlint/types": "^11.0.0", + "chalk": "4.1.0", + "cosmiconfig": "^7.0.0", + "lodash": "^4.17.19", + "resolve-from": "^5.0.0" + }, + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@commitlint/message": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@commitlint/parse": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "conventional-changelog-angular": "^5.0.0", + "conventional-commits-parser": "^3.0.0" + }, + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@commitlint/prompt": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/runtime": "^7.11.2", + "@commitlint/load": "^11.0.0", + "chalk": "^4.0.0", + "lodash": "^4.17.19", + "throat": "^5.0.0", + "vorpal": "^1.12.0" + }, + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@commitlint/prompt-cli": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@commitlint/prompt": "^11.0.0", + "execa": "^4.0.0" + }, + "bin": { + "commit": "cli.js" + }, + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@commitlint/read": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@commitlint/top-level": "^11.0.0", + "fs-extra": "^9.0.0", + "git-raw-commits": "^2.0.0" + }, + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@commitlint/resolve-extends": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "import-fresh": "^3.0.0", + "lodash": "^4.17.19", + "resolve-from": "^5.0.0", + "resolve-global": "^1.0.0" + }, + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@commitlint/rules": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@commitlint/ensure": "^11.0.0", + "@commitlint/message": "^11.0.0", + "@commitlint/to-lines": "^11.0.0", + "@commitlint/types": "^11.0.0" + }, + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@commitlint/to-lines": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@commitlint/top-level": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "find-up": "^5.0.0" + }, + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@commitlint/top-level/node_modules/find-up": { + "version": "5.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "locate-path": "^6.0.0", + "path-exists": "^4.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@commitlint/top-level/node_modules/find-up/node_modules/locate-path": { + "version": "6.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "p-locate": "^5.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@commitlint/top-level/node_modules/find-up/node_modules/locate-path/node_modules/p-locate": { + "version": "5.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "p-limit": "^3.0.2" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@commitlint/top-level/node_modules/find-up/node_modules/locate-path/node_modules/p-locate/node_modules/p-limit": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "yocto-queue": "^0.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@commitlint/types": { + "version": "11.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=v10.22.0" + } + }, + "node_modules/@eslint/eslintrc": { + "version": "0.4.3", + "dev": true, + "license": "MIT", + "dependencies": { + "ajv": "^6.12.4", + "debug": "^4.1.1", + "espree": "^7.3.0", + "globals": "^13.9.0", + "ignore": "^4.0.6", + "import-fresh": "^3.2.1", + "js-yaml": "^3.13.1", + "minimatch": "^3.0.4", + "strip-json-comments": "^3.1.1" + }, + "engines": { + "node": "^10.12.0 || >=12.0.0" + } + }, + "node_modules/@eslint/eslintrc/node_modules/ignore": { + "version": "4.0.6", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 4" + } + }, + "node_modules/@fullhuman/postcss-purgecss": { + "version": "3.1.3", + "license": "MIT", + "dependencies": { + "purgecss": "^3.1.3" + } + }, + "node_modules/@humanwhocodes/config-array": { + "version": "0.5.0", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "@humanwhocodes/object-schema": "^1.2.0", + "debug": "^4.1.1", + "minimatch": "^3.0.4" + }, + "engines": { + "node": ">=10.10.0" + } + }, + "node_modules/@humanwhocodes/object-schema": { + "version": "1.2.1", + "dev": true, + "license": "BSD-3-Clause" + }, + "node_modules/@istanbuljs/load-nyc-config": { + "version": "1.1.0", + "dev": true, + "license": "ISC", + "dependencies": { + "camelcase": "^5.3.1", + "find-up": "^4.1.0", + "get-package-type": "^0.1.0", + "js-yaml": "^3.13.1", + "resolve-from": "^5.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/@istanbuljs/schema": { + "version": "0.1.3", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/@jest/console": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^26.6.2", + "@types/node": "*", + "chalk": "^4.0.0", + "jest-message-util": "^26.6.2", + "jest-util": "^26.6.2", + "slash": "^3.0.0" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/@jest/core": { + "version": "26.6.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/console": "^26.6.2", + "@jest/reporters": "^26.6.2", + "@jest/test-result": "^26.6.2", + "@jest/transform": "^26.6.2", + "@jest/types": "^26.6.2", + "@types/node": "*", + "ansi-escapes": "^4.2.1", + "chalk": "^4.0.0", + "exit": "^0.1.2", + "graceful-fs": "^4.2.4", + "jest-changed-files": "^26.6.2", + "jest-config": "^26.6.3", + "jest-haste-map": "^26.6.2", + "jest-message-util": "^26.6.2", + "jest-regex-util": "^26.0.0", + "jest-resolve": "^26.6.2", + "jest-resolve-dependencies": "^26.6.3", + "jest-runner": "^26.6.3", + "jest-runtime": "^26.6.3", + "jest-snapshot": "^26.6.2", + "jest-util": "^26.6.2", + "jest-validate": "^26.6.2", + "jest-watcher": "^26.6.2", + "micromatch": "^4.0.2", + "p-each-series": "^2.1.0", + "rimraf": "^3.0.0", + "slash": "^3.0.0", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/@jest/environment": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/fake-timers": "^26.6.2", + "@jest/types": "^26.6.2", + "@types/node": "*", + "jest-mock": "^26.6.2" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/@jest/fake-timers": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^26.6.2", + "@sinonjs/fake-timers": "^6.0.1", + "@types/node": "*", + "jest-message-util": "^26.6.2", + "jest-mock": "^26.6.2", + "jest-util": "^26.6.2" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/@jest/globals": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/environment": "^26.6.2", + "@jest/types": "^26.6.2", + "expect": "^26.6.2" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/@jest/reporters": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@bcoe/v8-coverage": "^0.2.3", + "@jest/console": "^26.6.2", + "@jest/test-result": "^26.6.2", + "@jest/transform": "^26.6.2", + "@jest/types": "^26.6.2", + "chalk": "^4.0.0", + "collect-v8-coverage": "^1.0.0", + "exit": "^0.1.2", + "glob": "^7.1.2", + "graceful-fs": "^4.2.4", + "istanbul-lib-coverage": "^3.0.0", + "istanbul-lib-instrument": "^4.0.3", + "istanbul-lib-report": "^3.0.0", + "istanbul-lib-source-maps": "^4.0.0", + "istanbul-reports": "^3.0.2", + "jest-haste-map": "^26.6.2", + "jest-resolve": "^26.6.2", + "jest-util": "^26.6.2", + "jest-worker": "^26.6.2", + "slash": "^3.0.0", + "source-map": "^0.6.0", + "string-length": "^4.0.1", + "terminal-link": "^2.0.0", + "v8-to-istanbul": "^7.0.0" + }, + "engines": { + "node": ">= 10.14.2" + }, + "optionalDependencies": { + "node-notifier": "^8.0.0" + } + }, + "node_modules/@jest/source-map": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "callsites": "^3.0.0", + "graceful-fs": "^4.2.4", + "source-map": "^0.6.0" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/@jest/test-result": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/console": "^26.6.2", + "@jest/types": "^26.6.2", + "@types/istanbul-lib-coverage": "^2.0.0", + "collect-v8-coverage": "^1.0.0" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/@jest/test-sequencer": { + "version": "26.6.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/test-result": "^26.6.2", + "graceful-fs": "^4.2.4", + "jest-haste-map": "^26.6.2", + "jest-runner": "^26.6.3", + "jest-runtime": "^26.6.3" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/@jest/transform": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/core": "^7.1.0", + "@jest/types": "^26.6.2", + "babel-plugin-istanbul": "^6.0.0", + "chalk": "^4.0.0", + "convert-source-map": "^1.4.0", + "fast-json-stable-stringify": "^2.0.0", + "graceful-fs": "^4.2.4", + "jest-haste-map": "^26.6.2", + "jest-regex-util": "^26.0.0", + "jest-util": "^26.6.2", + "micromatch": "^4.0.2", + "pirates": "^4.0.1", + "slash": "^3.0.0", + "source-map": "^0.6.1", + "write-file-atomic": "^3.0.0" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/@jest/transform/node_modules/convert-source-map": { + "version": "1.9.0", + "dev": true, + "license": "MIT" + }, + "node_modules/@jest/types": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/istanbul-lib-coverage": "^2.0.0", + "@types/istanbul-reports": "^3.0.0", + "@types/node": "*", + "@types/yargs": "^15.0.0", + "chalk": "^4.0.0" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/@jridgewell/gen-mapping": { + "version": "0.3.8", + "license": "MIT", + "dependencies": { + "@jridgewell/set-array": "^1.2.1", + "@jridgewell/sourcemap-codec": "^1.4.10", + "@jridgewell/trace-mapping": "^0.3.24" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/resolve-uri": { + "version": "3.1.2", + "license": "MIT", + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/set-array": { + "version": "1.2.1", + "license": "MIT", + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/sourcemap-codec": { + "version": "1.5.0", + "license": "MIT" + }, + "node_modules/@jridgewell/trace-mapping": { + "version": "0.3.25", + "license": "MIT", + "dependencies": { + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" + } + }, + "node_modules/@nicolo-ribaudo/eslint-scope-5-internals": { + "version": "5.1.1-v1", + "dev": true, + "license": "MIT", + "dependencies": { + "eslint-scope": "5.1.1" + } + }, + "node_modules/@nodelib/fs.scandir": { + "version": "2.1.5", + "dev": true, + "license": "MIT", + "dependencies": { + "@nodelib/fs.stat": "2.0.5", + "run-parallel": "^1.1.9" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@nodelib/fs.stat": { + "version": "2.0.5", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 8" + } + }, + "node_modules/@nodelib/fs.walk": { + "version": "1.2.8", + "dev": true, + "license": "MIT", + "dependencies": { + "@nodelib/fs.scandir": "2.1.5", + "fastq": "^1.6.0" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@octokit/auth-token": { + "version": "2.5.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@octokit/types": "^6.0.3" + } + }, + "node_modules/@octokit/core": { + "version": "3.6.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@octokit/auth-token": "^2.4.4", + "@octokit/graphql": "^4.5.8", + "@octokit/request": "^5.6.3", + "@octokit/request-error": "^2.0.5", + "@octokit/types": "^6.0.3", + "before-after-hook": "^2.2.0", + "universal-user-agent": "^6.0.0" + } + }, + "node_modules/@octokit/endpoint": { + "version": "6.0.12", + "dev": true, + "license": "MIT", + "dependencies": { + "@octokit/types": "^6.0.3", + "is-plain-object": "^5.0.0", + "universal-user-agent": "^6.0.0" + } + }, + "node_modules/@octokit/graphql": { + "version": "4.8.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@octokit/request": "^5.6.0", + "@octokit/types": "^6.0.3", + "universal-user-agent": "^6.0.0" + } + }, + "node_modules/@octokit/openapi-types": { + "version": "12.11.0", + "dev": true, + "license": "MIT" + }, + "node_modules/@octokit/plugin-paginate-rest": { + "version": "2.21.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@octokit/types": "^6.40.0" + }, + "peerDependencies": { + "@octokit/core": ">=2" + } + }, + "node_modules/@octokit/plugin-request-log": { + "version": "1.0.4", + "dev": true, + "license": "MIT", + "peerDependencies": { + "@octokit/core": ">=3" + } + }, + "node_modules/@octokit/plugin-rest-endpoint-methods": { + "version": "5.16.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@octokit/types": "^6.39.0", + "deprecation": "^2.3.1" + }, + "peerDependencies": { + "@octokit/core": ">=3" + } + }, + "node_modules/@octokit/request": { + "version": "5.6.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@octokit/endpoint": "^6.0.1", + "@octokit/request-error": "^2.1.0", + "@octokit/types": "^6.16.1", + "is-plain-object": "^5.0.0", + "node-fetch": "^2.6.7", + "universal-user-agent": "^6.0.0" + } + }, + "node_modules/@octokit/request-error": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@octokit/types": "^6.0.3", + "deprecation": "^2.0.0", + "once": "^1.4.0" + } + }, + "node_modules/@octokit/rest": { + "version": "18.12.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@octokit/core": "^3.5.1", + "@octokit/plugin-paginate-rest": "^2.16.8", + "@octokit/plugin-request-log": "^1.0.4", + "@octokit/plugin-rest-endpoint-methods": "^5.12.0" + } + }, + "node_modules/@octokit/types": { + "version": "6.41.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@octokit/openapi-types": "^12.11.0" + } + }, + "node_modules/@oxc-project/types": { + "version": "0.65.0", + "dev": true, + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/Boshen" + } + }, + "node_modules/@pathscale/bulma-extensions-css-var": { + "version": "0.0.49-3", + "dev": true, + "license": "MIT" + }, + "node_modules/@pathscale/vue3-ui": { + "version": "0.8.156", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "vue": "3.0.7" + } + }, + "node_modules/@rolldown/binding-linux-x64-gnu": { + "version": "1.0.0-beta.8", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rolldown/binding-linux-x64-musl": { + "version": "1.0.0-beta.8", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/plugin-babel": { + "version": "5.3.1", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-module-imports": "^7.10.4", + "@rollup/pluginutils": "^3.1.0" + }, + "engines": { + "node": ">= 10.0.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0", + "@types/babel__core": "^7.1.9", + "rollup": "^1.20.0||^2.0.0" + }, + "peerDependenciesMeta": { + "@types/babel__core": { + "optional": true + } + } + }, + "node_modules/@rollup/plugin-babel/node_modules/@rollup/pluginutils": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/estree": "0.0.39", + "estree-walker": "^1.0.1", + "picomatch": "^2.2.2" + }, + "engines": { + "node": ">= 8.0.0" + }, + "peerDependencies": { + "rollup": "^1.20.0||^2.0.0" + } + }, + "node_modules/@rollup/plugin-babel/node_modules/@rollup/pluginutils/node_modules/estree-walker": { + "version": "1.0.1", + "dev": true, + "license": "MIT" + }, + "node_modules/@rollup/plugin-commonjs": { + "version": "17.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@rollup/pluginutils": "^3.1.0", + "commondir": "^1.0.1", + "estree-walker": "^2.0.1", + "glob": "^7.1.6", + "is-reference": "^1.2.1", + "magic-string": "^0.25.7", + "resolve": "^1.17.0" + }, + "engines": { + "node": ">= 8.0.0" + }, + "peerDependencies": { + "rollup": "^2.30.0" + } + }, + "node_modules/@rollup/plugin-commonjs/node_modules/@rollup/pluginutils": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/estree": "0.0.39", + "estree-walker": "^1.0.1", + "picomatch": "^2.2.2" + }, + "engines": { + "node": ">= 8.0.0" + }, + "peerDependencies": { + "rollup": "^1.20.0||^2.0.0" + } + }, + "node_modules/@rollup/plugin-commonjs/node_modules/@rollup/pluginutils/node_modules/estree-walker": { + "version": "1.0.1", + "dev": true, + "license": "MIT" + }, + "node_modules/@rollup/plugin-json": { + "version": "4.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@rollup/pluginutils": "^3.0.8" + }, + "peerDependencies": { + "rollup": "^1.20.0 || ^2.0.0" + } + }, + "node_modules/@rollup/plugin-json/node_modules/@rollup/pluginutils": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/estree": "0.0.39", + "estree-walker": "^1.0.1", + "picomatch": "^2.2.2" + }, + "engines": { + "node": ">= 8.0.0" + }, + "peerDependencies": { + "rollup": "^1.20.0||^2.0.0" + } + }, + "node_modules/@rollup/plugin-json/node_modules/@rollup/pluginutils/node_modules/estree-walker": { + "version": "1.0.1", + "dev": true, + "license": "MIT" + }, + "node_modules/@rollup/plugin-node-resolve": { + "version": "11.2.1", + "dev": true, + "license": "MIT", + "dependencies": { + "@rollup/pluginutils": "^3.1.0", + "@types/resolve": "1.17.1", + "builtin-modules": "^3.1.0", + "deepmerge": "^4.2.2", + "is-module": "^1.0.0", + "resolve": "^1.19.0" + }, + "engines": { + "node": ">= 10.0.0" + }, + "peerDependencies": { + "rollup": "^1.20.0||^2.0.0" + } + }, + "node_modules/@rollup/plugin-node-resolve/node_modules/@rollup/pluginutils": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/estree": "0.0.39", + "estree-walker": "^1.0.1", + "picomatch": "^2.2.2" + }, + "engines": { + "node": ">= 8.0.0" + }, + "peerDependencies": { + "rollup": "^1.20.0||^2.0.0" + } + }, + "node_modules/@rollup/plugin-node-resolve/node_modules/@rollup/pluginutils/node_modules/estree-walker": { + "version": "1.0.1", + "dev": true, + "license": "MIT" + }, + "node_modules/@rollup/plugin-node-resolve/node_modules/@types/resolve": { + "version": "1.17.1", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@rollup/plugin-replace": { + "version": "2.4.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@rollup/pluginutils": "^3.1.0", + "magic-string": "^0.25.7" + }, + "peerDependencies": { + "rollup": "^1.20.0 || ^2.0.0" + } + }, + "node_modules/@rollup/plugin-replace/node_modules/@rollup/pluginutils": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/estree": "0.0.39", + "estree-walker": "^1.0.1", + "picomatch": "^2.2.2" + }, + "engines": { + "node": ">= 8.0.0" + }, + "peerDependencies": { + "rollup": "^1.20.0||^2.0.0" + } + }, + "node_modules/@rollup/plugin-replace/node_modules/@rollup/pluginutils/node_modules/estree-walker": { + "version": "1.0.1", + "dev": true, + "license": "MIT" + }, + "node_modules/@rollup/plugin-typescript": { + "version": "8.5.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@rollup/pluginutils": "^3.1.0", + "resolve": "^1.17.0" + }, + "engines": { + "node": ">=8.0.0" + }, + "peerDependencies": { + "rollup": "^2.14.0", + "tslib": "*", + "typescript": ">=3.7.0" + }, + "peerDependenciesMeta": { + "tslib": { + "optional": true + } + } + }, + "node_modules/@rollup/plugin-typescript/node_modules/@rollup/pluginutils": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/estree": "0.0.39", + "estree-walker": "^1.0.1", + "picomatch": "^2.2.2" + }, + "engines": { + "node": ">= 8.0.0" + }, + "peerDependencies": { + "rollup": "^1.20.0||^2.0.0" + } + }, + "node_modules/@rollup/plugin-typescript/node_modules/@rollup/pluginutils/node_modules/estree-walker": { + "version": "1.0.1", + "dev": true, + "license": "MIT" + }, + "node_modules/@rollup/pluginutils": { + "version": "4.2.1", + "license": "MIT", + "dependencies": { + "estree-walker": "^2.0.1", + "picomatch": "^2.2.2" + }, + "engines": { + "node": ">= 8.0.0" + } + }, + "node_modules/@rtsao/scc": { + "version": "1.1.0", + "dev": true, + "license": "MIT" + }, + "node_modules/@semantic-release/changelog": { + "version": "5.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "@semantic-release/error": "^2.1.0", + "aggregate-error": "^3.0.0", + "fs-extra": "^9.0.0", + "lodash": "^4.17.4" + }, + "engines": { + "node": ">=10.18" + }, + "peerDependencies": { + "semantic-release": ">=15.8.0 <18.0.0" + } + }, + "node_modules/@semantic-release/commit-analyzer": { + "version": "8.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "conventional-changelog-angular": "^5.0.0", + "conventional-commits-filter": "^2.0.0", + "conventional-commits-parser": "^3.0.7", + "debug": "^4.0.0", + "import-from": "^3.0.0", + "lodash": "^4.17.4", + "micromatch": "^4.0.2" + }, + "engines": { + "node": ">=10.18" + }, + "peerDependencies": { + "semantic-release": ">=16.0.0 <18.0.0" + } + }, + "node_modules/@semantic-release/error": { + "version": "2.2.0", + "dev": true, + "license": "MIT" + }, + "node_modules/@semantic-release/git": { + "version": "9.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "@semantic-release/error": "^2.1.0", + "aggregate-error": "^3.0.0", + "debug": "^4.0.0", + "dir-glob": "^3.0.0", + "execa": "^5.0.0", + "lodash": "^4.17.4", + "micromatch": "^4.0.0", + "p-reduce": "^2.0.0" + }, + "engines": { + "node": ">=10.18" + }, + "peerDependencies": { + "semantic-release": ">=16.0.0 <18.0.0" + } + }, + "node_modules/@semantic-release/git/node_modules/execa": { + "version": "5.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "cross-spawn": "^7.0.3", + "get-stream": "^6.0.0", + "human-signals": "^2.1.0", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.1", + "onetime": "^5.1.2", + "signal-exit": "^3.0.3", + "strip-final-newline": "^2.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/execa?sponsor=1" + } + }, + "node_modules/@semantic-release/git/node_modules/execa/node_modules/human-signals": { + "version": "2.1.0", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": ">=10.17.0" + } + }, + "node_modules/@semantic-release/github": { + "version": "7.2.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@octokit/rest": "^18.0.0", + "@semantic-release/error": "^2.2.0", + "aggregate-error": "^3.0.0", + "bottleneck": "^2.18.1", + "debug": "^4.0.0", + "dir-glob": "^3.0.0", + "fs-extra": "^10.0.0", + "globby": "^11.0.0", + "http-proxy-agent": "^4.0.0", + "https-proxy-agent": "^5.0.0", + "issue-parser": "^6.0.0", + "lodash": "^4.17.4", + "mime": "^2.4.3", + "p-filter": "^2.0.0", + "p-retry": "^4.0.0", + "url-join": "^4.0.0" + }, + "engines": { + "node": ">=10.18" + }, + "peerDependencies": { + "semantic-release": ">=16.0.0 <18.0.0" + } + }, + "node_modules/@semantic-release/github/node_modules/fs-extra": { + "version": "10.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/@semantic-release/npm": { + "version": "7.1.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@semantic-release/error": "^2.2.0", + "aggregate-error": "^3.0.0", + "execa": "^5.0.0", + "fs-extra": "^10.0.0", + "lodash": "^4.17.15", + "nerf-dart": "^1.0.0", + "normalize-url": "^6.0.0", + "npm": "^7.0.0", + "rc": "^1.2.8", + "read-pkg": "^5.0.0", + "registry-auth-token": "^4.0.0", + "semver": "^7.1.2", + "tempy": "^1.0.0" + }, + "engines": { + "node": ">=10.19" + }, + "peerDependencies": { + "semantic-release": ">=16.0.0 <18.0.0" + } + }, + "node_modules/@semantic-release/npm/node_modules/execa": { + "version": "5.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "cross-spawn": "^7.0.3", + "get-stream": "^6.0.0", + "human-signals": "^2.1.0", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.1", + "onetime": "^5.1.2", + "signal-exit": "^3.0.3", + "strip-final-newline": "^2.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/execa?sponsor=1" + } + }, + "node_modules/@semantic-release/npm/node_modules/execa/node_modules/human-signals": { + "version": "2.1.0", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": ">=10.17.0" + } + }, + "node_modules/@semantic-release/npm/node_modules/fs-extra": { + "version": "10.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/@semantic-release/npm/node_modules/semver": { + "version": "7.7.1", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@semantic-release/release-notes-generator": { + "version": "9.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "conventional-changelog-angular": "^5.0.0", + "conventional-changelog-writer": "^4.0.0", + "conventional-commits-filter": "^2.0.0", + "conventional-commits-parser": "^3.0.0", + "debug": "^4.0.0", + "get-stream": "^6.0.0", + "import-from": "^3.0.0", + "into-stream": "^6.0.0", + "lodash": "^4.17.4", + "read-pkg-up": "^7.0.0" + }, + "engines": { + "node": ">=10.18" + }, + "peerDependencies": { + "semantic-release": ">=15.8.0 <18.0.0" + } + }, + "node_modules/@sinonjs/commons": { + "version": "1.8.6", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "type-detect": "4.0.8" + } + }, + "node_modules/@sinonjs/fake-timers": { + "version": "6.0.1", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "@sinonjs/commons": "^1.7.0" + } + }, + "node_modules/@tootallnate/once": { + "version": "1.1.2", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 6" + } + }, + "node_modules/@types/babel__core": { + "version": "7.20.5", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/parser": "^7.20.7", + "@babel/types": "^7.20.7", + "@types/babel__generator": "*", + "@types/babel__template": "*", + "@types/babel__traverse": "*" + } + }, + "node_modules/@types/babel__generator": { + "version": "7.27.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/types": "^7.0.0" + } + }, + "node_modules/@types/babel__template": { + "version": "7.4.4", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/parser": "^7.1.0", + "@babel/types": "^7.0.0" + } + }, + "node_modules/@types/babel__traverse": { + "version": "7.20.7", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/types": "^7.20.7" + } + }, + "node_modules/@types/cssnano": { + "version": "4.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "postcss": "5 - 7" + } + }, + "node_modules/@types/cssnano/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/@types/cssnano/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/@types/domhandler": { + "version": "2.4.5", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/domutils": { + "version": "2.1.0", + "deprecated": "This is a stub types definition. domutils provides its own type definitions, so you do not need this installed.", + "dev": true, + "license": "MIT", + "dependencies": { + "domutils": "*" + } + }, + "node_modules/@types/estree": { + "version": "0.0.39", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/fs-extra": { + "version": "9.0.13", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/graceful-fs": { + "version": "4.1.9", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "*" + } + }, + "node_modules/@types/htmlparser2": { + "version": "3.10.7", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/domhandler": "^2.4.3", + "@types/domutils": "*", + "@types/node": "*", + "domhandler": "^2.4.0" + } + }, + "node_modules/@types/istanbul-lib-coverage": { + "version": "2.0.6", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/istanbul-lib-report": { + "version": "3.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/istanbul-lib-coverage": "*" + } + }, + "node_modules/@types/istanbul-reports": { + "version": "3.0.4", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/istanbul-lib-report": "*" + } + }, + "node_modules/@types/jest": { + "version": "26.0.24", + "dev": true, + "license": "MIT", + "dependencies": { + "jest-diff": "^26.0.0", + "pretty-format": "^26.0.0" + } + }, + "node_modules/@types/json-schema": { + "version": "7.0.15", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/json5": { + "version": "0.0.29", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/minimist": { + "version": "1.2.5", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/node": { + "version": "22.14.0", + "dev": true, + "license": "MIT", + "dependencies": { + "undici-types": "~6.21.0" + } + }, + "node_modules/@types/normalize-package-data": { + "version": "2.4.4", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/parse-json": { + "version": "4.0.2", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/prettier": { + "version": "2.7.3", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/q": { + "version": "1.5.8", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/resolve": { + "version": "1.20.6", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/retry": { + "version": "0.12.0", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/stack-utils": { + "version": "2.0.3", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/yargs": { + "version": "15.0.19", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/yargs-parser": "*" + } + }, + "node_modules/@types/yargs-parser": { + "version": "21.0.3", + "dev": true, + "license": "MIT" + }, + "node_modules/@typescript-eslint/eslint-plugin": { + "version": "4.33.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@typescript-eslint/experimental-utils": "4.33.0", + "@typescript-eslint/scope-manager": "4.33.0", + "debug": "^4.3.1", + "functional-red-black-tree": "^1.0.1", + "ignore": "^5.1.8", + "regexpp": "^3.1.0", + "semver": "^7.3.5", + "tsutils": "^3.21.0" + }, + "engines": { + "node": "^10.12.0 || >=12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependencies": { + "@typescript-eslint/parser": "^4.0.0", + "eslint": "^5.0.0 || ^6.0.0 || ^7.0.0" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, + "node_modules/@typescript-eslint/eslint-plugin/node_modules/semver": { + "version": "7.7.1", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@typescript-eslint/experimental-utils": { + "version": "4.33.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/json-schema": "^7.0.7", + "@typescript-eslint/scope-manager": "4.33.0", + "@typescript-eslint/types": "4.33.0", + "@typescript-eslint/typescript-estree": "4.33.0", + "eslint-scope": "^5.1.1", + "eslint-utils": "^3.0.0" + }, + "engines": { + "node": "^10.12.0 || >=12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependencies": { + "eslint": "*" + } + }, + "node_modules/@typescript-eslint/experimental-utils/node_modules/eslint-utils": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "eslint-visitor-keys": "^2.0.0" + }, + "engines": { + "node": "^10.0.0 || ^12.0.0 || >= 14.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/mysticatea" + }, + "peerDependencies": { + "eslint": ">=5" + } + }, + "node_modules/@typescript-eslint/parser": { + "version": "4.33.0", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "@typescript-eslint/scope-manager": "4.33.0", + "@typescript-eslint/types": "4.33.0", + "@typescript-eslint/typescript-estree": "4.33.0", + "debug": "^4.3.1" + }, + "engines": { + "node": "^10.12.0 || >=12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependencies": { + "eslint": "^5.0.0 || ^6.0.0 || ^7.0.0" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, + "node_modules/@typescript-eslint/scope-manager": { + "version": "4.33.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@typescript-eslint/types": "4.33.0", + "@typescript-eslint/visitor-keys": "4.33.0" + }, + "engines": { + "node": "^8.10.0 || ^10.13.0 || >=11.10.1" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "node_modules/@typescript-eslint/types": { + "version": "4.33.0", + "dev": true, + "license": "MIT", + "engines": { + "node": "^8.10.0 || ^10.13.0 || >=11.10.1" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "node_modules/@typescript-eslint/typescript-estree": { + "version": "4.33.0", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "@typescript-eslint/types": "4.33.0", + "@typescript-eslint/visitor-keys": "4.33.0", + "debug": "^4.3.1", + "globby": "^11.0.3", + "is-glob": "^4.0.1", + "semver": "^7.3.5", + "tsutils": "^3.21.0" + }, + "engines": { + "node": "^10.12.0 || >=12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, + "node_modules/@typescript-eslint/typescript-estree/node_modules/semver": { + "version": "7.7.1", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@typescript-eslint/visitor-keys": { + "version": "4.33.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@typescript-eslint/types": "4.33.0", + "eslint-visitor-keys": "^2.0.0" + }, + "engines": { + "node": "^8.10.0 || ^10.13.0 || >=11.10.1" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/typescript-eslint" + } + }, + "node_modules/@valibot/to-json-schema": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "peerDependencies": { + "valibot": "^1.0.0" + } + }, + "node_modules/@vue/compiler-core": { + "version": "3.0.7", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/parser": "^7.12.0", + "@babel/types": "^7.12.0", + "@vue/shared": "3.0.7", + "estree-walker": "^2.0.1", + "source-map": "^0.6.1" + } + }, + "node_modules/@vue/compiler-dom": { + "version": "3.0.7", + "dev": true, + "license": "MIT", + "dependencies": { + "@vue/compiler-core": "3.0.7", + "@vue/shared": "3.0.7" + } + }, + "node_modules/@vue/compiler-sfc": { + "version": "3.0.7", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/parser": "^7.12.0", + "@babel/types": "^7.12.0", + "@vue/compiler-core": "3.0.7", + "@vue/compiler-dom": "3.0.7", + "@vue/compiler-ssr": "3.0.7", + "@vue/shared": "3.0.7", + "consolidate": "^0.16.0", + "estree-walker": "^2.0.1", + "hash-sum": "^2.0.0", + "lru-cache": "^5.1.1", + "magic-string": "^0.25.7", + "merge-source-map": "^1.1.0", + "postcss": "^8.1.10", + "postcss-modules": "^4.0.0", + "postcss-selector-parser": "^6.0.4", + "source-map": "^0.6.1" + }, + "peerDependencies": { + "vue": "3.0.7" + } + }, + "node_modules/@vue/compiler-ssr": { + "version": "3.0.7", + "dev": true, + "license": "MIT", + "dependencies": { + "@vue/compiler-dom": "3.0.7", + "@vue/shared": "3.0.7" + } + }, + "node_modules/@vue/reactivity": { + "version": "3.0.7", + "dev": true, + "license": "MIT", + "dependencies": { + "@vue/shared": "3.0.7" + } + }, + "node_modules/@vue/runtime-core": { + "version": "3.0.7", + "dev": true, + "license": "MIT", + "dependencies": { + "@vue/reactivity": "3.0.7", + "@vue/shared": "3.0.7" + } + }, + "node_modules/@vue/runtime-dom": { + "version": "3.0.7", + "dev": true, + "license": "MIT", + "dependencies": { + "@vue/runtime-core": "3.0.7", + "@vue/shared": "3.0.7", + "csstype": "^2.6.8" + } + }, + "node_modules/@vue/shared": { + "version": "3.0.7", + "dev": true, + "license": "MIT" + }, + "node_modules/abab": { + "version": "2.0.6", + "dev": true, + "license": "BSD-3-Clause" + }, + "node_modules/acorn": { + "version": "7.4.1", + "dev": true, + "license": "MIT", + "bin": { + "acorn": "bin/acorn" + }, + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/acorn-globals": { + "version": "6.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "acorn": "^7.1.1", + "acorn-walk": "^7.1.1" + } + }, + "node_modules/acorn-jsx": { + "version": "5.3.2", + "dev": true, + "license": "MIT", + "peerDependencies": { + "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" + } + }, + "node_modules/acorn-walk": { + "version": "7.2.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/agent-base": { + "version": "6.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "debug": "4" + }, + "engines": { + "node": ">= 6.0.0" + } + }, + "node_modules/aggregate-error": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "clean-stack": "^2.0.0", + "indent-string": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/ajv": { + "version": "6.12.6", + "dev": true, + "license": "MIT", + "dependencies": { + "fast-deep-equal": "^3.1.1", + "fast-json-stable-stringify": "^2.0.0", + "json-schema-traverse": "^0.4.1", + "uri-js": "^4.2.2" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" + } + }, + "node_modules/alphanum-sort": { + "version": "1.0.2", + "dev": true, + "license": "MIT" + }, + "node_modules/ansi-colors": { + "version": "4.1.3", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/ansi-escapes": { + "version": "4.3.2", + "dev": true, + "license": "MIT", + "dependencies": { + "type-fest": "^0.21.3" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/ansi-escapes/node_modules/type-fest": { + "version": "0.21.3", + "dev": true, + "license": "(MIT OR CC0-1.0)", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/ansi-regex": { + "version": "5.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/ansi-styles": { + "version": "4.3.0", + "dev": true, + "license": "MIT", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/ansicolors": { + "version": "0.3.2", + "dev": true, + "license": "MIT" + }, + "node_modules/ansis": { + "version": "3.17.0", + "dev": true, + "license": "ISC", + "engines": { + "node": ">=14" + } + }, + "node_modules/anymatch": { + "version": "3.1.3", + "dev": true, + "license": "ISC", + "dependencies": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/argparse": { + "version": "1.0.10", + "dev": true, + "license": "MIT", + "dependencies": { + "sprintf-js": "~1.0.2" + } + }, + "node_modules/argv-formatter": { + "version": "1.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/arr-diff": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/arr-flatten": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/arr-union": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/array-buffer-byte-length": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.3", + "is-array-buffer": "^3.0.5" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/array-ify": { + "version": "1.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/array-includes": { + "version": "3.1.8", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.7", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.2", + "es-object-atoms": "^1.0.0", + "get-intrinsic": "^1.2.4", + "is-string": "^1.0.7" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/array-union": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/array-unique": { + "version": "0.3.2", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/array.prototype.findlastindex": { + "version": "1.2.6", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.8", + "call-bound": "^1.0.4", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.9", + "es-errors": "^1.3.0", + "es-object-atoms": "^1.1.1", + "es-shim-unscopables": "^1.1.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/array.prototype.flat": { + "version": "1.3.3", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.8", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.5", + "es-shim-unscopables": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/array.prototype.flatmap": { + "version": "1.3.3", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.8", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.5", + "es-shim-unscopables": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/array.prototype.reduce": { + "version": "1.0.8", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.8", + "call-bound": "^1.0.4", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.9", + "es-array-method-boxes-properly": "^1.0.0", + "es-errors": "^1.3.0", + "es-object-atoms": "^1.1.1", + "is-string": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/arraybuffer.prototype.slice": { + "version": "1.0.4", + "dev": true, + "license": "MIT", + "dependencies": { + "array-buffer-byte-length": "^1.0.1", + "call-bind": "^1.0.8", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.5", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.6", + "is-array-buffer": "^3.0.4" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/arrify": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/assign-symbols": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/astral-regex": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/async-function": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/asynckit": { + "version": "0.4.0", + "dev": true, + "license": "MIT" + }, + "node_modules/at-least-node": { + "version": "1.0.0", + "license": "ISC", + "engines": { + "node": ">= 4.0.0" + } + }, + "node_modules/atob": { + "version": "2.1.2", + "dev": true, + "license": "(MIT OR Apache-2.0)", + "bin": { + "atob": "bin/atob.js" + }, + "engines": { + "node": ">= 4.5.0" + } + }, + "node_modules/available-typed-arrays": { + "version": "1.0.7", + "dev": true, + "license": "MIT", + "dependencies": { + "possible-typed-array-names": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/babel-jest": { + "version": "26.6.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/transform": "^26.6.2", + "@jest/types": "^26.6.2", + "@types/babel__core": "^7.1.7", + "babel-plugin-istanbul": "^6.0.0", + "babel-preset-jest": "^26.6.2", + "chalk": "^4.0.0", + "graceful-fs": "^4.2.4", + "slash": "^3.0.0" + }, + "engines": { + "node": ">= 10.14.2" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/babel-plugin-istanbul": { + "version": "6.1.1", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "@babel/helper-plugin-utils": "^7.0.0", + "@istanbuljs/load-nyc-config": "^1.0.0", + "@istanbuljs/schema": "^0.1.2", + "istanbul-lib-instrument": "^5.0.4", + "test-exclude": "^6.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/babel-plugin-istanbul/node_modules/istanbul-lib-instrument": { + "version": "5.2.1", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "@babel/core": "^7.12.3", + "@babel/parser": "^7.14.7", + "@istanbuljs/schema": "^0.1.2", + "istanbul-lib-coverage": "^3.2.0", + "semver": "^6.3.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/babel-plugin-jest-hoist": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/template": "^7.3.3", + "@babel/types": "^7.3.3", + "@types/babel__core": "^7.0.0", + "@types/babel__traverse": "^7.0.6" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/babel-plugin-polyfill-corejs2": { + "version": "0.4.13", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/compat-data": "^7.22.6", + "@babel/helper-define-polyfill-provider": "^0.6.4", + "semver": "^6.3.1" + }, + "peerDependencies": { + "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" + } + }, + "node_modules/babel-plugin-polyfill-corejs3": { + "version": "0.11.1", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-define-polyfill-provider": "^0.6.3", + "core-js-compat": "^3.40.0" + }, + "peerDependencies": { + "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" + } + }, + "node_modules/babel-plugin-polyfill-regenerator": { + "version": "0.6.4", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-define-polyfill-provider": "^0.6.4" + }, + "peerDependencies": { + "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" + } + }, + "node_modules/babel-polyfill": { + "version": "6.26.0", + "dev": true, + "license": "MIT", + "dependencies": { + "babel-runtime": "^6.26.0", + "core-js": "^2.5.0", + "regenerator-runtime": "^0.10.5" + } + }, + "node_modules/babel-polyfill/node_modules/core-js": { + "version": "2.6.12", + "dev": true, + "hasInstallScript": true, + "license": "MIT" + }, + "node_modules/babel-polyfill/node_modules/regenerator-runtime": { + "version": "0.10.5", + "dev": true, + "license": "MIT" + }, + "node_modules/babel-preset-current-node-syntax": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/plugin-syntax-async-generators": "^7.8.4", + "@babel/plugin-syntax-bigint": "^7.8.3", + "@babel/plugin-syntax-class-properties": "^7.12.13", + "@babel/plugin-syntax-class-static-block": "^7.14.5", + "@babel/plugin-syntax-import-attributes": "^7.24.7", + "@babel/plugin-syntax-import-meta": "^7.10.4", + "@babel/plugin-syntax-json-strings": "^7.8.3", + "@babel/plugin-syntax-logical-assignment-operators": "^7.10.4", + "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3", + "@babel/plugin-syntax-numeric-separator": "^7.10.4", + "@babel/plugin-syntax-object-rest-spread": "^7.8.3", + "@babel/plugin-syntax-optional-catch-binding": "^7.8.3", + "@babel/plugin-syntax-optional-chaining": "^7.8.3", + "@babel/plugin-syntax-private-property-in-object": "^7.14.5", + "@babel/plugin-syntax-top-level-await": "^7.14.5" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/babel-preset-jest": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "babel-plugin-jest-hoist": "^26.6.2", + "babel-preset-current-node-syntax": "^1.0.0" + }, + "engines": { + "node": ">= 10.14.2" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/babel-runtime": { + "version": "6.26.0", + "dev": true, + "license": "MIT", + "dependencies": { + "core-js": "^2.4.0", + "regenerator-runtime": "^0.11.0" + } + }, + "node_modules/babel-runtime/node_modules/core-js": { + "version": "2.6.12", + "dev": true, + "hasInstallScript": true, + "license": "MIT" + }, + "node_modules/babel-runtime/node_modules/regenerator-runtime": { + "version": "0.11.1", + "dev": true, + "license": "MIT" + }, + "node_modules/balanced-match": { + "version": "1.0.2", + "license": "MIT" + }, + "node_modules/base": { + "version": "0.11.2", + "dev": true, + "license": "MIT", + "dependencies": { + "cache-base": "^1.0.1", + "class-utils": "^0.3.5", + "component-emitter": "^1.2.1", + "define-property": "^1.0.0", + "isobject": "^3.0.1", + "mixin-deep": "^1.2.0", + "pascalcase": "^0.1.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/base/node_modules/define-property": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "is-descriptor": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/before-after-hook": { + "version": "2.2.3", + "dev": true, + "license": "Apache-2.0" + }, + "node_modules/bluebird": { + "version": "3.7.2", + "dev": true, + "license": "MIT" + }, + "node_modules/boolbase": { + "version": "1.0.0", + "dev": true, + "license": "ISC" + }, + "node_modules/bottleneck": { + "version": "2.19.5", + "dev": true, + "license": "MIT" + }, + "node_modules/brace-expansion": { + "version": "1.1.11", + "license": "MIT", + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/braces": { + "version": "3.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "fill-range": "^7.1.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/browser-process-hrtime": { + "version": "1.0.0", + "dev": true, + "license": "BSD-2-Clause" + }, + "node_modules/browserslist": { + "version": "4.24.4", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "dependencies": { + "caniuse-lite": "^1.0.30001688", + "electron-to-chromium": "^1.5.73", + "node-releases": "^2.0.19", + "update-browserslist-db": "^1.1.1" + }, + "bin": { + "browserslist": "cli.js" + }, + "engines": { + "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7" + } + }, + "node_modules/bs-logger": { + "version": "0.2.6", + "dev": true, + "license": "MIT", + "dependencies": { + "fast-json-stable-stringify": "2.x" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/bser": { + "version": "2.1.1", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "node-int64": "^0.4.0" + } + }, + "node_modules/buffer-from": { + "version": "1.1.2", + "dev": true, + "license": "MIT" + }, + "node_modules/builtin-modules": { + "version": "3.3.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/cache-base": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "collection-visit": "^1.0.0", + "component-emitter": "^1.2.1", + "get-value": "^2.0.6", + "has-value": "^1.0.0", + "isobject": "^3.0.1", + "set-value": "^2.0.0", + "to-object-path": "^0.3.0", + "union-value": "^1.0.0", + "unset-value": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/call-bind": { + "version": "1.0.8", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind-apply-helpers": "^1.0.0", + "es-define-property": "^1.0.0", + "get-intrinsic": "^1.2.4", + "set-function-length": "^1.2.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/call-bind-apply-helpers": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0", + "function-bind": "^1.1.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/call-bound": { + "version": "1.0.4", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind-apply-helpers": "^1.0.2", + "get-intrinsic": "^1.3.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/caller-callsite": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "callsites": "^2.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/caller-callsite/node_modules/callsites": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/caller-path": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "caller-callsite": "^2.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/callsites": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/camelcase": { + "version": "5.3.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/camelcase-keys": { + "version": "6.2.2", + "dev": true, + "license": "MIT", + "dependencies": { + "camelcase": "^5.3.1", + "map-obj": "^4.0.0", + "quick-lru": "^4.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/caniuse-api": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "browserslist": "^4.0.0", + "caniuse-lite": "^1.0.0", + "lodash.memoize": "^4.1.2", + "lodash.uniq": "^4.5.0" + } + }, + "node_modules/caniuse-lite": { + "version": "1.0.30001713", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/caniuse-lite" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "CC-BY-4.0" + }, + "node_modules/capture-exit": { + "version": "2.0.0", + "dev": true, + "license": "ISC", + "dependencies": { + "rsvp": "^4.8.4" + }, + "engines": { + "node": "6.* || 8.* || >= 10.*" + } + }, + "node_modules/cardinal": { + "version": "2.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "ansicolors": "~0.3.2", + "redeyed": "~2.1.0" + }, + "bin": { + "cdl": "bin/cdl.js" + } + }, + "node_modules/chalk": { + "version": "4.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/char-regex": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + } + }, + "node_modules/ci-info": { + "version": "2.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/cjs-module-lexer": { + "version": "0.6.0", + "dev": true, + "license": "MIT" + }, + "node_modules/class-utils": { + "version": "0.3.6", + "dev": true, + "license": "MIT", + "dependencies": { + "arr-union": "^3.1.0", + "define-property": "^0.2.5", + "isobject": "^3.0.0", + "static-extend": "^0.1.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/class-utils/node_modules/define-property": { + "version": "0.2.5", + "dev": true, + "license": "MIT", + "dependencies": { + "is-descriptor": "^0.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/class-utils/node_modules/define-property/node_modules/is-descriptor": { + "version": "0.1.7", + "dev": true, + "license": "MIT", + "dependencies": { + "is-accessor-descriptor": "^1.0.1", + "is-data-descriptor": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/clean-regexp": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "escape-string-regexp": "^1.0.5" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/clean-regexp/node_modules/escape-string-regexp": { + "version": "1.0.5", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/clean-stack": { + "version": "2.2.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/cli-cursor": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "restore-cursor": "^3.1.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/cli-table3": { + "version": "0.6.5", + "dev": true, + "license": "MIT", + "dependencies": { + "string-width": "^4.2.0" + }, + "engines": { + "node": "10.* || >= 12.*" + }, + "optionalDependencies": { + "@colors/colors": "1.5.0" + } + }, + "node_modules/cli-truncate": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "slice-ansi": "^3.0.0", + "string-width": "^4.2.0" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/cli-truncate/node_modules/slice-ansi": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.0.0", + "astral-regex": "^2.0.0", + "is-fullwidth-code-point": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/cli-width": { + "version": "1.1.1", + "dev": true, + "license": "ISC" + }, + "node_modules/cliui": { + "version": "6.0.0", + "dev": true, + "license": "ISC", + "dependencies": { + "string-width": "^4.2.0", + "strip-ansi": "^6.0.0", + "wrap-ansi": "^6.2.0" + } + }, + "node_modules/cliui/node_modules/wrap-ansi": { + "version": "6.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/co": { + "version": "4.6.0", + "dev": true, + "license": "MIT", + "engines": { + "iojs": ">= 1.0.0", + "node": ">= 0.12.0" + } + }, + "node_modules/coa": { + "version": "2.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/q": "^1.5.1", + "chalk": "^2.4.1", + "q": "^1.1.2" + }, + "engines": { + "node": ">= 4.0" + } + }, + "node_modules/coa/node_modules/chalk": { + "version": "2.4.2", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/coa/node_modules/chalk/node_modules/ansi-styles": { + "version": "3.2.1", + "dev": true, + "license": "MIT", + "dependencies": { + "color-convert": "^1.9.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/coa/node_modules/chalk/node_modules/ansi-styles/node_modules/color-convert": { + "version": "1.9.3", + "dev": true, + "license": "MIT", + "dependencies": { + "color-name": "1.1.3" + } + }, + "node_modules/coa/node_modules/chalk/node_modules/ansi-styles/node_modules/color-convert/node_modules/color-name": { + "version": "1.1.3", + "dev": true, + "license": "MIT" + }, + "node_modules/coa/node_modules/chalk/node_modules/escape-string-regexp": { + "version": "1.0.5", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/coa/node_modules/chalk/node_modules/supports-color": { + "version": "5.5.0", + "dev": true, + "license": "MIT", + "dependencies": { + "has-flag": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/coa/node_modules/chalk/node_modules/supports-color/node_modules/has-flag": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/code-point-at": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/collect-v8-coverage": { + "version": "1.0.2", + "dev": true, + "license": "MIT" + }, + "node_modules/collection-visit": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "map-visit": "^1.0.0", + "object-visit": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/color": { + "version": "3.2.1", + "dev": true, + "license": "MIT", + "dependencies": { + "color-convert": "^1.9.3", + "color-string": "^1.6.0" + } + }, + "node_modules/color-convert": { + "version": "2.0.1", + "license": "MIT", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/color-name": { + "version": "1.1.4", + "license": "MIT" + }, + "node_modules/color-string": { + "version": "1.9.1", + "dev": true, + "license": "MIT", + "dependencies": { + "color-name": "^1.0.0", + "simple-swizzle": "^0.2.2" + } + }, + "node_modules/color/node_modules/color-convert": { + "version": "1.9.3", + "dev": true, + "license": "MIT", + "dependencies": { + "color-name": "1.1.3" + } + }, + "node_modules/color/node_modules/color-convert/node_modules/color-name": { + "version": "1.1.3", + "dev": true, + "license": "MIT" + }, + "node_modules/colorette": { + "version": "2.0.20", + "dev": true, + "license": "MIT" + }, + "node_modules/combined-stream": { + "version": "1.0.8", + "dev": true, + "license": "MIT", + "dependencies": { + "delayed-stream": "~1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/commander": { + "version": "6.2.1", + "license": "MIT", + "engines": { + "node": ">= 6" + } + }, + "node_modules/commondir": { + "version": "1.0.1", + "dev": true, + "license": "MIT" + }, + "node_modules/compare-func": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "array-ify": "^1.0.0", + "dot-prop": "^5.1.0" + } + }, + "node_modules/compare-versions": { + "version": "3.6.0", + "dev": true, + "license": "MIT" + }, + "node_modules/component-emitter": { + "version": "1.3.1", + "dev": true, + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/concat-map": { + "version": "0.0.1", + "license": "MIT" + }, + "node_modules/consolidate": { + "version": "0.16.0", + "dev": true, + "license": "MIT", + "dependencies": { + "bluebird": "^3.7.2" + }, + "engines": { + "node": ">= 0.10.0" + } + }, + "node_modules/conventional-changelog-angular": { + "version": "5.0.13", + "dev": true, + "license": "ISC", + "dependencies": { + "compare-func": "^2.0.0", + "q": "^1.5.1" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/conventional-changelog-writer": { + "version": "4.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "compare-func": "^2.0.0", + "conventional-commits-filter": "^2.0.7", + "dateformat": "^3.0.0", + "handlebars": "^4.7.6", + "json-stringify-safe": "^5.0.1", + "lodash": "^4.17.15", + "meow": "^8.0.0", + "semver": "^6.0.0", + "split": "^1.0.0", + "through2": "^4.0.0" + }, + "bin": { + "conventional-changelog-writer": "cli.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/conventional-changelog-writer/node_modules/through2": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "readable-stream": "3" + } + }, + "node_modules/conventional-changelog-writer/node_modules/through2/node_modules/readable-stream": { + "version": "3.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/conventional-commits-filter": { + "version": "2.0.7", + "dev": true, + "license": "MIT", + "dependencies": { + "lodash.ismatch": "^4.4.0", + "modify-values": "^1.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/conventional-commits-parser": { + "version": "3.2.4", + "dev": true, + "license": "MIT", + "dependencies": { + "is-text-path": "^1.0.1", + "JSONStream": "^1.0.4", + "lodash": "^4.17.15", + "meow": "^8.0.0", + "split2": "^3.0.0", + "through2": "^4.0.0" + }, + "bin": { + "conventional-commits-parser": "cli.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/conventional-commits-parser/node_modules/split2": { + "version": "3.2.2", + "dev": true, + "license": "ISC", + "dependencies": { + "readable-stream": "^3.0.0" + } + }, + "node_modules/conventional-commits-parser/node_modules/split2/node_modules/readable-stream": { + "version": "3.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/conventional-commits-parser/node_modules/through2": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "readable-stream": "3" + } + }, + "node_modules/conventional-commits-parser/node_modules/through2/node_modules/readable-stream": { + "version": "3.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/convert-source-map": { + "version": "2.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/copy-descriptor": { + "version": "0.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/core-js": { + "version": "3.41.0", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/core-js" + } + }, + "node_modules/core-js-compat": { + "version": "3.41.0", + "dev": true, + "license": "MIT", + "dependencies": { + "browserslist": "^4.24.4" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/core-js" + } + }, + "node_modules/core-util-is": { + "version": "1.0.3", + "dev": true, + "license": "MIT" + }, + "node_modules/cosmiconfig": { + "version": "7.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/parse-json": "^4.0.0", + "import-fresh": "^3.2.1", + "parse-json": "^5.0.0", + "path-type": "^4.0.0", + "yaml": "^1.10.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/cross-spawn": { + "version": "7.0.6", + "dev": true, + "license": "MIT", + "dependencies": { + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/crypto-random-string": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/css-color-names": { + "version": "0.0.4", + "dev": true, + "license": "MIT", + "engines": { + "node": "*" + } + }, + "node_modules/css-declaration-sorter": { + "version": "4.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "postcss": "^7.0.1", + "timsort": "^0.3.0" + }, + "engines": { + "node": ">4" + } + }, + "node_modules/css-declaration-sorter/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/css-declaration-sorter/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/css-select": { + "version": "2.1.0", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "boolbase": "^1.0.0", + "css-what": "^3.2.1", + "domutils": "^1.7.0", + "nth-check": "^1.0.2" + } + }, + "node_modules/css-select-base-adapter": { + "version": "0.1.1", + "dev": true, + "license": "MIT" + }, + "node_modules/css-select/node_modules/domutils": { + "version": "1.7.0", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "dom-serializer": "0", + "domelementtype": "1" + } + }, + "node_modules/css-select/node_modules/domutils/node_modules/dom-serializer": { + "version": "0.2.2", + "dev": true, + "license": "MIT", + "dependencies": { + "domelementtype": "^2.0.1", + "entities": "^2.0.0" + } + }, + "node_modules/css-select/node_modules/domutils/node_modules/dom-serializer/node_modules/domelementtype": { + "version": "2.3.0", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/fb55" + } + ], + "license": "BSD-2-Clause" + }, + "node_modules/css-select/node_modules/domutils/node_modules/domelementtype": { + "version": "1.3.1", + "dev": true, + "license": "BSD-2-Clause" + }, + "node_modules/css-tree": { + "version": "1.0.0-alpha.37", + "dev": true, + "license": "MIT", + "dependencies": { + "mdn-data": "2.0.4", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/css-what": { + "version": "3.4.2", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">= 6" + }, + "funding": { + "url": "https://github.com/sponsors/fb55" + } + }, + "node_modules/cssesc": { + "version": "3.0.0", + "license": "MIT", + "bin": { + "cssesc": "bin/cssesc" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/cssnano": { + "version": "4.1.11", + "dev": true, + "license": "MIT", + "dependencies": { + "cosmiconfig": "^5.0.0", + "cssnano-preset-default": "^4.0.8", + "is-resolvable": "^1.0.0", + "postcss": "^7.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/cssnano-preset-default": { + "version": "4.0.8", + "dev": true, + "license": "MIT", + "dependencies": { + "css-declaration-sorter": "^4.0.1", + "cssnano-util-raw-cache": "^4.0.1", + "postcss": "^7.0.0", + "postcss-calc": "^7.0.1", + "postcss-colormin": "^4.0.3", + "postcss-convert-values": "^4.0.1", + "postcss-discard-comments": "^4.0.2", + "postcss-discard-duplicates": "^4.0.2", + "postcss-discard-empty": "^4.0.1", + "postcss-discard-overridden": "^4.0.1", + "postcss-merge-longhand": "^4.0.11", + "postcss-merge-rules": "^4.0.3", + "postcss-minify-font-values": "^4.0.2", + "postcss-minify-gradients": "^4.0.2", + "postcss-minify-params": "^4.0.2", + "postcss-minify-selectors": "^4.0.2", + "postcss-normalize-charset": "^4.0.1", + "postcss-normalize-display-values": "^4.0.2", + "postcss-normalize-positions": "^4.0.2", + "postcss-normalize-repeat-style": "^4.0.2", + "postcss-normalize-string": "^4.0.2", + "postcss-normalize-timing-functions": "^4.0.2", + "postcss-normalize-unicode": "^4.0.1", + "postcss-normalize-url": "^4.0.1", + "postcss-normalize-whitespace": "^4.0.2", + "postcss-ordered-values": "^4.1.2", + "postcss-reduce-initial": "^4.0.3", + "postcss-reduce-transforms": "^4.0.2", + "postcss-svgo": "^4.0.3", + "postcss-unique-selectors": "^4.0.1" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/cssnano-preset-default/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/cssnano-preset-default/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/cssnano-util-get-arguments": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/cssnano-util-get-match": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/cssnano-util-raw-cache": { + "version": "4.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "postcss": "^7.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/cssnano-util-raw-cache/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/cssnano-util-raw-cache/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/cssnano-util-same-parent": { + "version": "4.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/cssnano/node_modules/cosmiconfig": { + "version": "5.2.1", + "dev": true, + "license": "MIT", + "dependencies": { + "import-fresh": "^2.0.0", + "is-directory": "^0.3.1", + "js-yaml": "^3.13.1", + "parse-json": "^4.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/cssnano/node_modules/cosmiconfig/node_modules/import-fresh": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "caller-path": "^2.0.0", + "resolve-from": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/cssnano/node_modules/cosmiconfig/node_modules/import-fresh/node_modules/resolve-from": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/cssnano/node_modules/cosmiconfig/node_modules/parse-json": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "error-ex": "^1.3.1", + "json-parse-better-errors": "^1.0.1" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/cssnano/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/cssnano/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/csso": { + "version": "4.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "css-tree": "^1.1.2" + }, + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/csso/node_modules/css-tree": { + "version": "1.1.3", + "dev": true, + "license": "MIT", + "dependencies": { + "mdn-data": "2.0.14", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/csso/node_modules/css-tree/node_modules/mdn-data": { + "version": "2.0.14", + "dev": true, + "license": "CC0-1.0" + }, + "node_modules/cssom": { + "version": "0.4.4", + "dev": true, + "license": "MIT" + }, + "node_modules/cssstyle": { + "version": "2.3.0", + "dev": true, + "license": "MIT", + "dependencies": { + "cssom": "~0.3.6" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/cssstyle/node_modules/cssom": { + "version": "0.3.8", + "dev": true, + "license": "MIT" + }, + "node_modules/csstype": { + "version": "2.6.21", + "dev": true, + "license": "MIT" + }, + "node_modules/dargs": { + "version": "7.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/data-urls": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "abab": "^2.0.3", + "whatwg-mimetype": "^2.3.0", + "whatwg-url": "^8.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/data-view-buffer": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.3", + "es-errors": "^1.3.0", + "is-data-view": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/data-view-byte-length": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.3", + "es-errors": "^1.3.0", + "is-data-view": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/inspect-js" + } + }, + "node_modules/data-view-byte-offset": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.2", + "es-errors": "^1.3.0", + "is-data-view": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/dateformat": { + "version": "3.0.3", + "dev": true, + "license": "MIT", + "engines": { + "node": "*" + } + }, + "node_modules/debug": { + "version": "4.4.0", + "license": "MIT", + "dependencies": { + "ms": "^2.1.3" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/decamelize": { + "version": "1.2.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/decamelize-keys": { + "version": "1.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "decamelize": "^1.1.0", + "map-obj": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/decamelize-keys/node_modules/map-obj": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/decimal.js": { + "version": "10.5.0", + "dev": true, + "license": "MIT" + }, + "node_modules/decode-uri-component": { + "version": "0.2.2", + "license": "MIT", + "engines": { + "node": ">=0.10" + } + }, + "node_modules/dedent": { + "version": "0.7.0", + "dev": true, + "license": "MIT" + }, + "node_modules/deep-extend": { + "version": "0.6.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4.0.0" + } + }, + "node_modules/deep-is": { + "version": "0.1.4", + "dev": true, + "license": "MIT" + }, + "node_modules/deepmerge": { + "version": "4.3.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/define-data-property": { + "version": "1.1.4", + "dev": true, + "license": "MIT", + "dependencies": { + "es-define-property": "^1.0.0", + "es-errors": "^1.3.0", + "gopd": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/define-properties": { + "version": "1.2.1", + "dev": true, + "license": "MIT", + "dependencies": { + "define-data-property": "^1.0.1", + "has-property-descriptors": "^1.0.0", + "object-keys": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/define-property": { + "version": "2.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "is-descriptor": "^1.0.2", + "isobject": "^3.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/del": { + "version": "6.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "globby": "^11.0.1", + "graceful-fs": "^4.2.4", + "is-glob": "^4.0.1", + "is-path-cwd": "^2.2.0", + "is-path-inside": "^3.0.2", + "p-map": "^4.0.0", + "rimraf": "^3.0.2", + "slash": "^3.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/delayed-stream": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/deprecation": { + "version": "2.3.1", + "dev": true, + "license": "ISC" + }, + "node_modules/detect-newline": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/diff-sequences": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/dir-glob": { + "version": "3.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "path-type": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/doctrine": { + "version": "3.0.0", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "esutils": "^2.0.2" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/dom-serializer": { + "version": "1.4.1", + "license": "MIT", + "dependencies": { + "domelementtype": "^2.0.1", + "domhandler": "^4.2.0", + "entities": "^2.0.0" + }, + "funding": { + "url": "https://github.com/cheeriojs/dom-serializer?sponsor=1" + } + }, + "node_modules/dom-serializer/node_modules/domhandler": { + "version": "4.3.1", + "license": "BSD-2-Clause", + "dependencies": { + "domelementtype": "^2.2.0" + }, + "engines": { + "node": ">= 4" + }, + "funding": { + "url": "https://github.com/fb55/domhandler?sponsor=1" + } + }, + "node_modules/domelementtype": { + "version": "2.3.0", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/fb55" + } + ], + "license": "BSD-2-Clause" + }, + "node_modules/domexception": { + "version": "2.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "webidl-conversions": "^5.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/domexception/node_modules/webidl-conversions": { + "version": "5.0.0", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=8" + } + }, + "node_modules/domhandler": { + "version": "2.4.2", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "domelementtype": "1" + } + }, + "node_modules/domhandler/node_modules/domelementtype": { + "version": "1.3.1", + "dev": true, + "license": "BSD-2-Clause" + }, + "node_modules/domutils": { + "version": "2.8.0", + "license": "BSD-2-Clause", + "dependencies": { + "dom-serializer": "^1.0.1", + "domelementtype": "^2.2.0", + "domhandler": "^4.2.0" + }, + "funding": { + "url": "https://github.com/fb55/domutils?sponsor=1" + } + }, + "node_modules/domutils/node_modules/domhandler": { + "version": "4.3.1", + "license": "BSD-2-Clause", + "dependencies": { + "domelementtype": "^2.2.0" + }, + "engines": { + "node": ">= 4" + }, + "funding": { + "url": "https://github.com/fb55/domhandler?sponsor=1" + } + }, + "node_modules/dot-prop": { + "version": "5.3.0", + "dev": true, + "license": "MIT", + "dependencies": { + "is-obj": "^2.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/dot-prop/node_modules/is-obj": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/dunder-proto": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind-apply-helpers": "^1.0.1", + "es-errors": "^1.3.0", + "gopd": "^1.2.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/duplexer2": { + "version": "0.1.4", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "readable-stream": "^2.0.2" + } + }, + "node_modules/electron-to-chromium": { + "version": "1.5.136", + "dev": true, + "license": "ISC" + }, + "node_modules/emittery": { + "version": "0.7.2", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/emittery?sponsor=1" + } + }, + "node_modules/emoji-regex": { + "version": "8.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/end-of-stream": { + "version": "1.4.4", + "dev": true, + "license": "MIT", + "dependencies": { + "once": "^1.4.0" + } + }, + "node_modules/enquirer": { + "version": "2.4.1", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-colors": "^4.1.1", + "strip-ansi": "^6.0.1" + }, + "engines": { + "node": ">=8.6" + } + }, + "node_modules/entities": { + "version": "2.2.0", + "license": "BSD-2-Clause", + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, + "node_modules/env-ci": { + "version": "5.5.0", + "dev": true, + "license": "MIT", + "dependencies": { + "execa": "^5.0.0", + "fromentries": "^1.3.2", + "java-properties": "^1.0.0" + }, + "engines": { + "node": ">=10.17" + } + }, + "node_modules/env-ci/node_modules/execa": { + "version": "5.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "cross-spawn": "^7.0.3", + "get-stream": "^6.0.0", + "human-signals": "^2.1.0", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.1", + "onetime": "^5.1.2", + "signal-exit": "^3.0.3", + "strip-final-newline": "^2.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/execa?sponsor=1" + } + }, + "node_modules/env-ci/node_modules/execa/node_modules/human-signals": { + "version": "2.1.0", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": ">=10.17.0" + } + }, + "node_modules/error-ex": { + "version": "1.3.2", + "dev": true, + "license": "MIT", + "dependencies": { + "is-arrayish": "^0.2.1" + } + }, + "node_modules/es-abstract": { + "version": "1.23.9", + "dev": true, + "license": "MIT", + "dependencies": { + "array-buffer-byte-length": "^1.0.2", + "arraybuffer.prototype.slice": "^1.0.4", + "available-typed-arrays": "^1.0.7", + "call-bind": "^1.0.8", + "call-bound": "^1.0.3", + "data-view-buffer": "^1.0.2", + "data-view-byte-length": "^1.0.2", + "data-view-byte-offset": "^1.0.1", + "es-define-property": "^1.0.1", + "es-errors": "^1.3.0", + "es-object-atoms": "^1.0.0", + "es-set-tostringtag": "^2.1.0", + "es-to-primitive": "^1.3.0", + "function.prototype.name": "^1.1.8", + "get-intrinsic": "^1.2.7", + "get-proto": "^1.0.0", + "get-symbol-description": "^1.1.0", + "globalthis": "^1.0.4", + "gopd": "^1.2.0", + "has-property-descriptors": "^1.0.2", + "has-proto": "^1.2.0", + "has-symbols": "^1.1.0", + "hasown": "^2.0.2", + "internal-slot": "^1.1.0", + "is-array-buffer": "^3.0.5", + "is-callable": "^1.2.7", + "is-data-view": "^1.0.2", + "is-regex": "^1.2.1", + "is-shared-array-buffer": "^1.0.4", + "is-string": "^1.1.1", + "is-typed-array": "^1.1.15", + "is-weakref": "^1.1.0", + "math-intrinsics": "^1.1.0", + "object-inspect": "^1.13.3", + "object-keys": "^1.1.1", + "object.assign": "^4.1.7", + "own-keys": "^1.0.1", + "regexp.prototype.flags": "^1.5.3", + "safe-array-concat": "^1.1.3", + "safe-push-apply": "^1.0.0", + "safe-regex-test": "^1.1.0", + "set-proto": "^1.0.0", + "string.prototype.trim": "^1.2.10", + "string.prototype.trimend": "^1.0.9", + "string.prototype.trimstart": "^1.0.8", + "typed-array-buffer": "^1.0.3", + "typed-array-byte-length": "^1.0.3", + "typed-array-byte-offset": "^1.0.4", + "typed-array-length": "^1.0.7", + "unbox-primitive": "^1.1.0", + "which-typed-array": "^1.1.18" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/es-array-method-boxes-properly": { + "version": "1.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/es-define-property": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-errors": { + "version": "1.3.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-object-atoms": { + "version": "1.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-set-tostringtag": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.6", + "has-tostringtag": "^1.0.2", + "hasown": "^2.0.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-shim-unscopables": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "hasown": "^2.0.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-to-primitive": { + "version": "1.3.0", + "dev": true, + "license": "MIT", + "dependencies": { + "is-callable": "^1.2.7", + "is-date-object": "^1.0.5", + "is-symbol": "^1.0.4" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/escalade": { + "version": "3.2.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/escape-string-regexp": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/escodegen": { + "version": "2.1.0", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "esprima": "^4.0.1", + "estraverse": "^5.2.0", + "esutils": "^2.0.2" + }, + "bin": { + "escodegen": "bin/escodegen.js", + "esgenerate": "bin/esgenerate.js" + }, + "engines": { + "node": ">=6.0" + }, + "optionalDependencies": { + "source-map": "~0.6.1" + } + }, + "node_modules/escodegen/node_modules/estraverse": { + "version": "5.3.0", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=4.0" + } + }, + "node_modules/eslint": { + "version": "7.32.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/code-frame": "7.12.11", + "@eslint/eslintrc": "^0.4.3", + "@humanwhocodes/config-array": "^0.5.0", + "ajv": "^6.10.0", + "chalk": "^4.0.0", + "cross-spawn": "^7.0.2", + "debug": "^4.0.1", + "doctrine": "^3.0.0", + "enquirer": "^2.3.5", + "escape-string-regexp": "^4.0.0", + "eslint-scope": "^5.1.1", + "eslint-utils": "^2.1.0", + "eslint-visitor-keys": "^2.0.0", + "espree": "^7.3.1", + "esquery": "^1.4.0", + "esutils": "^2.0.2", + "fast-deep-equal": "^3.1.3", + "file-entry-cache": "^6.0.1", + "functional-red-black-tree": "^1.0.1", + "glob-parent": "^5.1.2", + "globals": "^13.6.0", + "ignore": "^4.0.6", + "import-fresh": "^3.0.0", + "imurmurhash": "^0.1.4", + "is-glob": "^4.0.0", + "js-yaml": "^3.13.1", + "json-stable-stringify-without-jsonify": "^1.0.1", + "levn": "^0.4.1", + "lodash.merge": "^4.6.2", + "minimatch": "^3.0.4", + "natural-compare": "^1.4.0", + "optionator": "^0.9.1", + "progress": "^2.0.0", + "regexpp": "^3.1.0", + "semver": "^7.2.1", + "strip-ansi": "^6.0.0", + "strip-json-comments": "^3.1.0", + "table": "^6.0.9", + "text-table": "^0.2.0", + "v8-compile-cache": "^2.0.3" + }, + "bin": { + "eslint": "bin/eslint.js" + }, + "engines": { + "node": "^10.12.0 || >=12.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" + } + }, + "node_modules/eslint-ast-utils": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "lodash.get": "^4.4.2", + "lodash.zip": "^4.2.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/eslint-config-prettier": { + "version": "7.2.0", + "dev": true, + "license": "MIT", + "bin": { + "eslint-config-prettier": "bin/cli.js" + }, + "peerDependencies": { + "eslint": ">=7.0.0" + } + }, + "node_modules/eslint-import-resolver-node": { + "version": "0.3.9", + "dev": true, + "license": "MIT", + "dependencies": { + "debug": "^3.2.7", + "is-core-module": "^2.13.0", + "resolve": "^1.22.4" + } + }, + "node_modules/eslint-import-resolver-node/node_modules/debug": { + "version": "3.2.7", + "dev": true, + "license": "MIT", + "dependencies": { + "ms": "^2.1.1" + } + }, + "node_modules/eslint-module-utils": { + "version": "2.12.0", + "dev": true, + "license": "MIT", + "dependencies": { + "debug": "^3.2.7" + }, + "engines": { + "node": ">=4" + }, + "peerDependenciesMeta": { + "eslint": { + "optional": true + } + } + }, + "node_modules/eslint-module-utils/node_modules/debug": { + "version": "3.2.7", + "dev": true, + "license": "MIT", + "dependencies": { + "ms": "^2.1.1" + } + }, + "node_modules/eslint-plugin-es": { + "version": "3.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "eslint-utils": "^2.0.0", + "regexpp": "^3.0.0" + }, + "engines": { + "node": ">=8.10.0" + }, + "funding": { + "url": "https://github.com/sponsors/mysticatea" + }, + "peerDependencies": { + "eslint": ">=4.19.1" + } + }, + "node_modules/eslint-plugin-import": { + "version": "2.31.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@rtsao/scc": "^1.1.0", + "array-includes": "^3.1.8", + "array.prototype.findlastindex": "^1.2.5", + "array.prototype.flat": "^1.3.2", + "array.prototype.flatmap": "^1.3.2", + "debug": "^3.2.7", + "doctrine": "^2.1.0", + "eslint-import-resolver-node": "^0.3.9", + "eslint-module-utils": "^2.12.0", + "hasown": "^2.0.2", + "is-core-module": "^2.15.1", + "is-glob": "^4.0.3", + "minimatch": "^3.1.2", + "object.fromentries": "^2.0.8", + "object.groupby": "^1.0.3", + "object.values": "^1.2.0", + "semver": "^6.3.1", + "string.prototype.trimend": "^1.0.8", + "tsconfig-paths": "^3.15.0" + }, + "engines": { + "node": ">=4" + }, + "peerDependencies": { + "eslint": "^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8 || ^9" + } + }, + "node_modules/eslint-plugin-import/node_modules/debug": { + "version": "3.2.7", + "dev": true, + "license": "MIT", + "dependencies": { + "ms": "^2.1.1" + } + }, + "node_modules/eslint-plugin-import/node_modules/doctrine": { + "version": "2.1.0", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "esutils": "^2.0.2" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/eslint-plugin-jest": { + "version": "24.7.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@typescript-eslint/experimental-utils": "^4.0.1" + }, + "engines": { + "node": ">=10" + }, + "peerDependencies": { + "@typescript-eslint/eslint-plugin": ">= 4", + "eslint": ">=5" + }, + "peerDependenciesMeta": { + "@typescript-eslint/eslint-plugin": { + "optional": true + } + } + }, + "node_modules/eslint-plugin-node": { + "version": "11.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "eslint-plugin-es": "^3.0.0", + "eslint-utils": "^2.0.0", + "ignore": "^5.1.1", + "minimatch": "^3.0.4", + "resolve": "^1.10.1", + "semver": "^6.1.0" + }, + "engines": { + "node": ">=8.10.0" + }, + "peerDependencies": { + "eslint": ">=5.16.0" + } + }, + "node_modules/eslint-plugin-unicorn": { + "version": "25.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "ci-info": "^2.0.0", + "clean-regexp": "^1.0.0", + "eslint-ast-utils": "^1.1.0", + "eslint-template-visitor": "^2.2.1", + "eslint-utils": "^2.1.0", + "import-modules": "^2.0.0", + "lodash": "^4.17.20", + "pluralize": "^8.0.0", + "read-pkg-up": "^7.0.1", + "regexp-tree": "^0.1.21", + "reserved-words": "^0.1.2", + "safe-regex": "^2.1.1", + "semver": "^7.3.4" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/eslint-plugin-unicorn?sponsor=1" + }, + "peerDependencies": { + "eslint": ">=7.15.0" + } + }, + "node_modules/eslint-plugin-unicorn/node_modules/semver": { + "version": "7.7.1", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/eslint-scope": { + "version": "5.1.1", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "esrecurse": "^4.3.0", + "estraverse": "^4.1.1" + }, + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/eslint-template-visitor": { + "version": "2.3.2", + "dev": true, + "license": "GPL-3.0-or-later OR MIT", + "dependencies": { + "@babel/core": "^7.12.16", + "@babel/eslint-parser": "^7.12.16", + "eslint-visitor-keys": "^2.0.0", + "esquery": "^1.3.1", + "multimap": "^1.1.0" + }, + "peerDependencies": { + "eslint": ">=7.0.0" + } + }, + "node_modules/eslint-utils": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "eslint-visitor-keys": "^1.1.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/mysticatea" + } + }, + "node_modules/eslint-utils/node_modules/eslint-visitor-keys": { + "version": "1.3.0", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": ">=4" + } + }, + "node_modules/eslint-visitor-keys": { + "version": "2.1.0", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": ">=10" + } + }, + "node_modules/eslint/node_modules/@babel/code-frame": { + "version": "7.12.11", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/highlight": "^7.10.4" + } + }, + "node_modules/eslint/node_modules/ignore": { + "version": "4.0.6", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 4" + } + }, + "node_modules/eslint/node_modules/semver": { + "version": "7.7.1", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/espree": { + "version": "7.3.1", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "acorn": "^7.4.0", + "acorn-jsx": "^5.3.1", + "eslint-visitor-keys": "^1.3.0" + }, + "engines": { + "node": "^10.12.0 || >=12.0.0" + } + }, + "node_modules/espree/node_modules/eslint-visitor-keys": { + "version": "1.3.0", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": ">=4" + } + }, + "node_modules/esprima": { + "version": "4.0.1", + "dev": true, + "license": "BSD-2-Clause", + "bin": { + "esparse": "bin/esparse.js", + "esvalidate": "bin/esvalidate.js" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/esquery": { + "version": "1.6.0", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "estraverse": "^5.1.0" + }, + "engines": { + "node": ">=0.10" + } + }, + "node_modules/esquery/node_modules/estraverse": { + "version": "5.3.0", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=4.0" + } + }, + "node_modules/esrecurse": { + "version": "4.3.0", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "estraverse": "^5.2.0" + }, + "engines": { + "node": ">=4.0" + } + }, + "node_modules/esrecurse/node_modules/estraverse": { + "version": "5.3.0", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=4.0" + } + }, + "node_modules/estraverse": { + "version": "4.3.0", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=4.0" + } + }, + "node_modules/estree-walker": { + "version": "2.0.2", + "license": "MIT" + }, + "node_modules/esutils": { + "version": "2.0.3", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/eventemitter3": { + "version": "4.0.7", + "dev": true, + "license": "MIT" + }, + "node_modules/exec-sh": { + "version": "0.3.6", + "dev": true, + "license": "MIT" + }, + "node_modules/execa": { + "version": "4.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "cross-spawn": "^7.0.0", + "get-stream": "^5.0.0", + "human-signals": "^1.1.1", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.0", + "onetime": "^5.1.0", + "signal-exit": "^3.0.2", + "strip-final-newline": "^2.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/execa?sponsor=1" + } + }, + "node_modules/execa/node_modules/get-stream": { + "version": "5.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "pump": "^3.0.0" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/exit": { + "version": "0.1.2", + "dev": true, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/exit-hook": { + "version": "1.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/expand-brackets": { + "version": "2.1.4", + "dev": true, + "license": "MIT", + "dependencies": { + "debug": "^2.3.3", + "define-property": "^0.2.5", + "extend-shallow": "^2.0.1", + "posix-character-classes": "^0.1.0", + "regex-not": "^1.0.0", + "snapdragon": "^0.8.1", + "to-regex": "^3.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/expand-brackets/node_modules/debug": { + "version": "2.6.9", + "dev": true, + "license": "MIT", + "dependencies": { + "ms": "2.0.0" + } + }, + "node_modules/expand-brackets/node_modules/debug/node_modules/ms": { + "version": "2.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/expand-brackets/node_modules/define-property": { + "version": "0.2.5", + "dev": true, + "license": "MIT", + "dependencies": { + "is-descriptor": "^0.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/expand-brackets/node_modules/define-property/node_modules/is-descriptor": { + "version": "0.1.7", + "dev": true, + "license": "MIT", + "dependencies": { + "is-accessor-descriptor": "^1.0.1", + "is-data-descriptor": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/expand-brackets/node_modules/extend-shallow": { + "version": "2.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "is-extendable": "^0.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/expand-brackets/node_modules/extend-shallow/node_modules/is-extendable": { + "version": "0.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/expect": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^26.6.2", + "ansi-styles": "^4.0.0", + "jest-get-type": "^26.3.0", + "jest-matcher-utils": "^26.6.2", + "jest-message-util": "^26.6.2", + "jest-regex-util": "^26.0.0" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/extend-shallow": { + "version": "3.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "assign-symbols": "^1.0.0", + "is-extendable": "^1.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/extglob": { + "version": "2.0.4", + "dev": true, + "license": "MIT", + "dependencies": { + "array-unique": "^0.3.2", + "define-property": "^1.0.0", + "expand-brackets": "^2.1.4", + "extend-shallow": "^2.0.1", + "fragment-cache": "^0.2.1", + "regex-not": "^1.0.0", + "snapdragon": "^0.8.1", + "to-regex": "^3.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/extglob/node_modules/define-property": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "is-descriptor": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/extglob/node_modules/extend-shallow": { + "version": "2.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "is-extendable": "^0.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/extglob/node_modules/extend-shallow/node_modules/is-extendable": { + "version": "0.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/fast-deep-equal": { + "version": "3.1.3", + "dev": true, + "license": "MIT" + }, + "node_modules/fast-glob": { + "version": "3.3.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@nodelib/fs.stat": "^2.0.2", + "@nodelib/fs.walk": "^1.2.3", + "glob-parent": "^5.1.2", + "merge2": "^1.3.0", + "micromatch": "^4.0.8" + }, + "engines": { + "node": ">=8.6.0" + } + }, + "node_modules/fast-json-stable-stringify": { + "version": "2.1.0", + "dev": true, + "license": "MIT" + }, + "node_modules/fast-levenshtein": { + "version": "2.0.6", + "dev": true, + "license": "MIT" + }, + "node_modules/fast-uri": { + "version": "3.0.6", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/fastify" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/fastify" + } + ], + "license": "BSD-3-Clause" + }, + "node_modules/fastq": { + "version": "1.19.1", + "dev": true, + "license": "ISC", + "dependencies": { + "reusify": "^1.0.4" + } + }, + "node_modules/fb-watchman": { + "version": "2.0.2", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "bser": "2.1.1" + } + }, + "node_modules/figures": { + "version": "3.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "escape-string-regexp": "^1.0.5" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/figures/node_modules/escape-string-regexp": { + "version": "1.0.5", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/file-entry-cache": { + "version": "6.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "flat-cache": "^3.0.4" + }, + "engines": { + "node": "^10.12.0 || >=12.0.0" + } + }, + "node_modules/fill-range": { + "version": "7.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "to-regex-range": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/filter-obj": { + "version": "1.1.0", + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/find-up": { + "version": "4.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "locate-path": "^5.0.0", + "path-exists": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/find-versions": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "semver-regex": "^3.1.2" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/flat-cache": { + "version": "3.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "flatted": "^3.2.9", + "keyv": "^4.5.3", + "rimraf": "^3.0.2" + }, + "engines": { + "node": "^10.12.0 || >=12.0.0" + } + }, + "node_modules/flatted": { + "version": "3.3.3", + "dev": true, + "license": "ISC" + }, + "node_modules/for-each": { + "version": "0.3.5", + "dev": true, + "license": "MIT", + "dependencies": { + "is-callable": "^1.2.7" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/for-in": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/form-data": { + "version": "3.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "asynckit": "^0.4.0", + "combined-stream": "^1.0.8", + "es-set-tostringtag": "^2.1.0", + "mime-types": "^2.1.35" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/fragment-cache": { + "version": "0.2.1", + "dev": true, + "license": "MIT", + "dependencies": { + "map-cache": "^0.2.2" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/from2": { + "version": "2.3.0", + "dev": true, + "license": "MIT", + "dependencies": { + "inherits": "^2.0.1", + "readable-stream": "^2.0.0" + } + }, + "node_modules/fromentries": { + "version": "1.3.2", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT" + }, + "node_modules/fs-extra": { + "version": "9.1.0", + "license": "MIT", + "dependencies": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/fs.realpath": { + "version": "1.0.0", + "license": "ISC" + }, + "node_modules/function-bind": { + "version": "1.1.2", + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/function.prototype.name": { + "version": "1.1.8", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.8", + "call-bound": "^1.0.3", + "define-properties": "^1.2.1", + "functions-have-names": "^1.2.3", + "hasown": "^2.0.2", + "is-callable": "^1.2.7" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/functional-red-black-tree": { + "version": "1.0.1", + "dev": true, + "license": "MIT" + }, + "node_modules/functions-have-names": { + "version": "1.2.3", + "dev": true, + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/generic-names": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "loader-utils": "^3.2.0" + } + }, + "node_modules/gensync": { + "version": "1.0.0-beta.2", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/get-caller-file": { + "version": "2.0.5", + "dev": true, + "license": "ISC", + "engines": { + "node": "6.* || 8.* || >= 10.*" + } + }, + "node_modules/get-intrinsic": { + "version": "1.3.0", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind-apply-helpers": "^1.0.2", + "es-define-property": "^1.0.1", + "es-errors": "^1.3.0", + "es-object-atoms": "^1.1.1", + "function-bind": "^1.1.2", + "get-proto": "^1.0.1", + "gopd": "^1.2.0", + "has-symbols": "^1.1.0", + "hasown": "^2.0.2", + "math-intrinsics": "^1.1.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-own-enumerable-property-symbols": { + "version": "3.0.2", + "dev": true, + "license": "ISC" + }, + "node_modules/get-package-type": { + "version": "0.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/get-proto": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "dunder-proto": "^1.0.1", + "es-object-atoms": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/get-stdin": { + "version": "8.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/get-stream": { + "version": "6.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/get-symbol-description": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.3", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.6" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-value": { + "version": "2.0.6", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/git-log-parser": { + "version": "1.2.1", + "dev": true, + "license": "MIT", + "dependencies": { + "argv-formatter": "~1.0.0", + "spawn-error-forwarder": "~1.0.0", + "split2": "~1.0.0", + "stream-combiner2": "~1.1.1", + "through2": "~2.0.0", + "traverse": "0.6.8" + } + }, + "node_modules/git-raw-commits": { + "version": "2.0.11", + "dev": true, + "license": "MIT", + "dependencies": { + "dargs": "^7.0.0", + "lodash": "^4.17.15", + "meow": "^8.0.0", + "split2": "^3.0.0", + "through2": "^4.0.0" + }, + "bin": { + "git-raw-commits": "cli.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/git-raw-commits/node_modules/split2": { + "version": "3.2.2", + "dev": true, + "license": "ISC", + "dependencies": { + "readable-stream": "^3.0.0" + } + }, + "node_modules/git-raw-commits/node_modules/split2/node_modules/readable-stream": { + "version": "3.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/git-raw-commits/node_modules/through2": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "readable-stream": "3" + } + }, + "node_modules/git-raw-commits/node_modules/through2/node_modules/readable-stream": { + "version": "3.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/glob": { + "version": "7.2.3", + "license": "ISC", + "dependencies": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/glob-parent": { + "version": "5.1.2", + "dev": true, + "license": "ISC", + "dependencies": { + "is-glob": "^4.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/global-dirs": { + "version": "0.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "ini": "^1.3.4" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/globals": { + "version": "13.24.0", + "dev": true, + "license": "MIT", + "dependencies": { + "type-fest": "^0.20.2" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/globalthis": { + "version": "1.0.4", + "dev": true, + "license": "MIT", + "dependencies": { + "define-properties": "^1.2.1", + "gopd": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/globby": { + "version": "11.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "array-union": "^2.1.0", + "dir-glob": "^3.0.1", + "fast-glob": "^3.2.9", + "ignore": "^5.2.0", + "merge2": "^1.4.1", + "slash": "^3.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/gopd": { + "version": "1.2.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/graceful-fs": { + "version": "4.2.11", + "license": "ISC" + }, + "node_modules/growly": { + "version": "1.3.0", + "dev": true, + "license": "MIT", + "optional": true + }, + "node_modules/handlebars": { + "version": "4.7.8", + "dev": true, + "license": "MIT", + "dependencies": { + "minimist": "^1.2.5", + "neo-async": "^2.6.2", + "source-map": "^0.6.1", + "wordwrap": "^1.0.0" + }, + "bin": { + "handlebars": "bin/handlebars" + }, + "engines": { + "node": ">=0.4.7" + }, + "optionalDependencies": { + "uglify-js": "^3.1.4" + } + }, + "node_modules/hard-rejection": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/has": { + "version": "1.0.4", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4.0" + } + }, + "node_modules/has-ansi": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-regex": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/has-ansi/node_modules/ansi-regex": { + "version": "2.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/has-bigints": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-flag": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/has-property-descriptors": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "es-define-property": "^1.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-proto": { + "version": "1.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "dunder-proto": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-symbols": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-tostringtag": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "has-symbols": "^1.0.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-value": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "get-value": "^2.0.6", + "has-values": "^1.0.0", + "isobject": "^3.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/has-values": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "is-number": "^3.0.0", + "kind-of": "^4.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/has-values/node_modules/is-number": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "kind-of": "^3.0.2" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/has-values/node_modules/is-number/node_modules/kind-of": { + "version": "3.2.2", + "dev": true, + "license": "MIT", + "dependencies": { + "is-buffer": "^1.1.5" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/has-values/node_modules/kind-of": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "is-buffer": "^1.1.5" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/hash-sum": { + "version": "2.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/hasown": { + "version": "2.0.2", + "license": "MIT", + "dependencies": { + "function-bind": "^1.1.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/hex-color-regex": { + "version": "1.1.0", + "dev": true, + "license": "MIT" + }, + "node_modules/hook-std": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/hosted-git-info": { + "version": "4.1.0", + "dev": true, + "license": "ISC", + "dependencies": { + "lru-cache": "^6.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/hosted-git-info/node_modules/lru-cache": { + "version": "6.0.0", + "dev": true, + "license": "ISC", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/hosted-git-info/node_modules/lru-cache/node_modules/yallist": { + "version": "4.0.0", + "dev": true, + "license": "ISC" + }, + "node_modules/hsl-regex": { + "version": "1.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/hsla-regex": { + "version": "1.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/html-encoding-sniffer": { + "version": "2.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "whatwg-encoding": "^1.0.5" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/html-escaper": { + "version": "2.0.2", + "dev": true, + "license": "MIT" + }, + "node_modules/htmlparser2": { + "version": "6.1.0", + "funding": [ + "https://github.com/fb55/htmlparser2?sponsor=1", + { + "type": "github", + "url": "https://github.com/sponsors/fb55" + } + ], + "license": "MIT", + "dependencies": { + "domelementtype": "^2.0.1", + "domhandler": "^4.0.0", + "domutils": "^2.5.2", + "entities": "^2.0.0" + } + }, + "node_modules/htmlparser2/node_modules/domhandler": { + "version": "4.3.1", + "license": "BSD-2-Clause", + "dependencies": { + "domelementtype": "^2.2.0" + }, + "engines": { + "node": ">= 4" + }, + "funding": { + "url": "https://github.com/fb55/domhandler?sponsor=1" + } + }, + "node_modules/http-proxy-agent": { + "version": "4.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "@tootallnate/once": "1", + "agent-base": "6", + "debug": "4" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/https-proxy-agent": { + "version": "5.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "agent-base": "6", + "debug": "4" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/human-signals": { + "version": "1.1.1", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": ">=8.12.0" + } + }, + "node_modules/husky": { + "version": "4.3.8", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "dependencies": { + "chalk": "^4.0.0", + "ci-info": "^2.0.0", + "compare-versions": "^3.6.0", + "cosmiconfig": "^7.0.0", + "find-versions": "^4.0.0", + "opencollective-postinstall": "^2.0.2", + "pkg-dir": "^5.0.0", + "please-upgrade-node": "^3.2.0", + "slash": "^3.0.0", + "which-pm-runs": "^1.0.0" + }, + "bin": { + "husky-run": "bin/run.js", + "husky-upgrade": "lib/upgrader/bin.js" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/husky" + } + }, + "node_modules/iconv-lite": { + "version": "0.4.24", + "dev": true, + "license": "MIT", + "dependencies": { + "safer-buffer": ">= 2.1.2 < 3" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/icss-replace-symbols": { + "version": "1.1.0", + "dev": true, + "license": "ISC" + }, + "node_modules/icss-utils": { + "version": "5.1.0", + "dev": true, + "license": "ISC", + "engines": { + "node": "^10 || ^12 || >= 14" + }, + "peerDependencies": { + "postcss": "^8.1.0" + } + }, + "node_modules/ignore": { + "version": "5.3.2", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 4" + } + }, + "node_modules/import-fresh": { + "version": "3.3.1", + "dev": true, + "license": "MIT", + "dependencies": { + "parent-module": "^1.0.0", + "resolve-from": "^4.0.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/import-fresh/node_modules/resolve-from": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/import-from": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "resolve-from": "^5.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/import-local": { + "version": "3.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "pkg-dir": "^4.2.0", + "resolve-cwd": "^3.0.0" + }, + "bin": { + "import-local-fixture": "fixtures/cli.js" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/import-local/node_modules/pkg-dir": { + "version": "4.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "find-up": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/import-modules": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/imurmurhash": { + "version": "0.1.4", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.8.19" + } + }, + "node_modules/in-publish": { + "version": "2.0.1", + "dev": true, + "license": "ISC", + "bin": { + "in-install": "in-install.js", + "in-publish": "in-publish.js", + "not-in-install": "not-in-install.js", + "not-in-publish": "not-in-publish.js" + } + }, + "node_modules/indent-string": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/indexes-of": { + "version": "1.0.1", + "dev": true, + "license": "MIT" + }, + "node_modules/inflight": { + "version": "1.0.6", + "license": "ISC", + "dependencies": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "node_modules/inherits": { + "version": "2.0.4", + "license": "ISC" + }, + "node_modules/ini": { + "version": "1.3.8", + "dev": true, + "license": "ISC" + }, + "node_modules/inquirer": { + "version": "0.11.0", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-escapes": "^1.1.0", + "ansi-regex": "^2.0.0", + "chalk": "^1.0.0", + "cli-cursor": "^1.0.1", + "cli-width": "^1.0.1", + "figures": "^1.3.5", + "lodash": "^3.3.1", + "readline2": "^1.0.1", + "run-async": "^0.1.0", + "rx-lite": "^3.1.2", + "strip-ansi": "^3.0.0", + "through": "^2.3.6" + } + }, + "node_modules/inquirer/node_modules/ansi-escapes": { + "version": "1.4.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/inquirer/node_modules/ansi-regex": { + "version": "2.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/inquirer/node_modules/chalk": { + "version": "1.1.3", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/inquirer/node_modules/chalk/node_modules/ansi-styles": { + "version": "2.2.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/inquirer/node_modules/chalk/node_modules/escape-string-regexp": { + "version": "1.0.5", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/inquirer/node_modules/chalk/node_modules/supports-color": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/inquirer/node_modules/cli-cursor": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "restore-cursor": "^1.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/inquirer/node_modules/cli-cursor/node_modules/restore-cursor": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "exit-hook": "^1.0.0", + "onetime": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/inquirer/node_modules/cli-cursor/node_modules/restore-cursor/node_modules/onetime": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/inquirer/node_modules/figures": { + "version": "1.7.0", + "dev": true, + "license": "MIT", + "dependencies": { + "escape-string-regexp": "^1.0.5", + "object-assign": "^4.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/inquirer/node_modules/figures/node_modules/escape-string-regexp": { + "version": "1.0.5", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/inquirer/node_modules/lodash": { + "version": "3.10.1", + "dev": true, + "license": "MIT" + }, + "node_modules/inquirer/node_modules/strip-ansi": { + "version": "3.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-regex": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/internal-slot": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0", + "hasown": "^2.0.2", + "side-channel": "^1.1.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/interpret": { + "version": "1.4.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.10" + } + }, + "node_modules/into-stream": { + "version": "6.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "from2": "^2.3.0", + "p-is-promise": "^3.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-absolute-url": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-accessor-descriptor": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "hasown": "^2.0.0" + }, + "engines": { + "node": ">= 0.10" + } + }, + "node_modules/is-array-buffer": { + "version": "3.0.5", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.8", + "call-bound": "^1.0.3", + "get-intrinsic": "^1.2.6" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-arrayish": { + "version": "0.2.1", + "dev": true, + "license": "MIT" + }, + "node_modules/is-async-function": { + "version": "2.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "async-function": "^1.0.0", + "call-bound": "^1.0.3", + "get-proto": "^1.0.1", + "has-tostringtag": "^1.0.2", + "safe-regex-test": "^1.1.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-bigint": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "has-bigints": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-boolean-object": { + "version": "1.2.2", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.3", + "has-tostringtag": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-buffer": { + "version": "1.1.6", + "dev": true, + "license": "MIT" + }, + "node_modules/is-callable": { + "version": "1.2.7", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-ci": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "ci-info": "^2.0.0" + }, + "bin": { + "is-ci": "bin.js" + } + }, + "node_modules/is-color-stop": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "css-color-names": "^0.0.4", + "hex-color-regex": "^1.1.0", + "hsl-regex": "^1.0.0", + "hsla-regex": "^1.0.0", + "rgb-regex": "^1.0.1", + "rgba-regex": "^1.0.0" + } + }, + "node_modules/is-core-module": { + "version": "2.16.1", + "license": "MIT", + "dependencies": { + "hasown": "^2.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-data-descriptor": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "hasown": "^2.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/is-data-view": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.2", + "get-intrinsic": "^1.2.6", + "is-typed-array": "^1.1.13" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-date-object": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.2", + "has-tostringtag": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-descriptor": { + "version": "1.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "is-accessor-descriptor": "^1.0.1", + "is-data-descriptor": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/is-directory": { + "version": "0.3.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-docker": { + "version": "2.2.1", + "dev": true, + "license": "MIT", + "optional": true, + "bin": { + "is-docker": "cli.js" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-extendable": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "is-plain-object": "^2.0.4" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-extendable/node_modules/is-plain-object": { + "version": "2.0.4", + "dev": true, + "license": "MIT", + "dependencies": { + "isobject": "^3.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-extglob": { + "version": "2.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-finalizationregistry": { + "version": "1.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-fullwidth-code-point": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/is-generator-fn": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/is-generator-function": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.3", + "get-proto": "^1.0.0", + "has-tostringtag": "^1.0.2", + "safe-regex-test": "^1.1.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-glob": { + "version": "4.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "is-extglob": "^2.1.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-map": { + "version": "2.0.3", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-module": { + "version": "1.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/is-number": { + "version": "7.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.12.0" + } + }, + "node_modules/is-number-object": { + "version": "1.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.3", + "has-tostringtag": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-obj": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-path-cwd": { + "version": "2.2.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/is-path-inside": { + "version": "3.0.3", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/is-plain-obj": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-plain-object": { + "version": "5.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-potential-custom-element-name": { + "version": "1.0.1", + "dev": true, + "license": "MIT" + }, + "node_modules/is-reference": { + "version": "1.2.1", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/estree": "*" + } + }, + "node_modules/is-regex": { + "version": "1.2.1", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.2", + "gopd": "^1.2.0", + "has-tostringtag": "^1.0.2", + "hasown": "^2.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-regexp": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-resolvable": { + "version": "1.1.0", + "dev": true, + "license": "ISC" + }, + "node_modules/is-set": { + "version": "2.0.3", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-shared-array-buffer": { + "version": "1.0.4", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-stream": { + "version": "2.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-string": { + "version": "1.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.3", + "has-tostringtag": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-symbol": { + "version": "1.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.2", + "has-symbols": "^1.1.0", + "safe-regex-test": "^1.1.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-text-path": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "text-extensions": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-typed-array": { + "version": "1.1.15", + "dev": true, + "license": "MIT", + "dependencies": { + "which-typed-array": "^1.1.16" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-typedarray": { + "version": "1.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/is-unicode-supported": { + "version": "0.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-url-superb": { + "version": "4.0.0", + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-weakmap": { + "version": "2.0.2", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-weakref": { + "version": "1.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-weakset": { + "version": "2.0.4", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.3", + "get-intrinsic": "^1.2.6" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-windows": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-wsl": { + "version": "2.2.0", + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "is-docker": "^2.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/isarray": { + "version": "2.0.5", + "dev": true, + "license": "MIT" + }, + "node_modules/isexe": { + "version": "2.0.0", + "dev": true, + "license": "ISC" + }, + "node_modules/isobject": { + "version": "3.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/issue-parser": { + "version": "6.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "lodash.capitalize": "^4.2.1", + "lodash.escaperegexp": "^4.1.2", + "lodash.isplainobject": "^4.0.6", + "lodash.isstring": "^4.0.1", + "lodash.uniqby": "^4.7.0" + }, + "engines": { + "node": ">=10.13" + } + }, + "node_modules/istanbul-lib-coverage": { + "version": "3.2.2", + "dev": true, + "license": "BSD-3-Clause", + "engines": { + "node": ">=8" + } + }, + "node_modules/istanbul-lib-instrument": { + "version": "4.0.3", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "@babel/core": "^7.7.5", + "@istanbuljs/schema": "^0.1.2", + "istanbul-lib-coverage": "^3.0.0", + "semver": "^6.3.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/istanbul-lib-report": { + "version": "3.0.1", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "istanbul-lib-coverage": "^3.0.0", + "make-dir": "^4.0.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/istanbul-lib-source-maps": { + "version": "4.0.1", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "debug": "^4.1.1", + "istanbul-lib-coverage": "^3.0.0", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/istanbul-reports": { + "version": "3.1.7", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "html-escaper": "^2.0.0", + "istanbul-lib-report": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/java-properties": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.6.0" + } + }, + "node_modules/jest": { + "version": "26.6.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/core": "^26.6.3", + "import-local": "^3.0.2", + "jest-cli": "^26.6.3" + }, + "bin": { + "jest": "bin/jest.js" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-changed-files": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^26.6.2", + "execa": "^4.0.0", + "throat": "^5.0.0" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-circus": { + "version": "26.6.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/traverse": "^7.1.0", + "@jest/environment": "^26.6.2", + "@jest/test-result": "^26.6.2", + "@jest/types": "^26.6.2", + "@types/babel__traverse": "^7.0.4", + "@types/node": "*", + "chalk": "^4.0.0", + "co": "^4.6.0", + "dedent": "^0.7.0", + "expect": "^26.6.2", + "is-generator-fn": "^2.0.0", + "jest-each": "^26.6.2", + "jest-matcher-utils": "^26.6.2", + "jest-message-util": "^26.6.2", + "jest-runner": "^26.6.3", + "jest-runtime": "^26.6.3", + "jest-snapshot": "^26.6.2", + "jest-util": "^26.6.2", + "pretty-format": "^26.6.2", + "stack-utils": "^2.0.2", + "throat": "^5.0.0" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-cli": { + "version": "26.6.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/core": "^26.6.3", + "@jest/test-result": "^26.6.2", + "@jest/types": "^26.6.2", + "chalk": "^4.0.0", + "exit": "^0.1.2", + "graceful-fs": "^4.2.4", + "import-local": "^3.0.2", + "is-ci": "^2.0.0", + "jest-config": "^26.6.3", + "jest-util": "^26.6.2", + "jest-validate": "^26.6.2", + "prompts": "^2.0.1", + "yargs": "^15.4.1" + }, + "bin": { + "jest": "bin/jest.js" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-config": { + "version": "26.6.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/core": "^7.1.0", + "@jest/test-sequencer": "^26.6.3", + "@jest/types": "^26.6.2", + "babel-jest": "^26.6.3", + "chalk": "^4.0.0", + "deepmerge": "^4.2.2", + "glob": "^7.1.1", + "graceful-fs": "^4.2.4", + "jest-environment-jsdom": "^26.6.2", + "jest-environment-node": "^26.6.2", + "jest-get-type": "^26.3.0", + "jest-jasmine2": "^26.6.3", + "jest-regex-util": "^26.0.0", + "jest-resolve": "^26.6.2", + "jest-util": "^26.6.2", + "jest-validate": "^26.6.2", + "micromatch": "^4.0.2", + "pretty-format": "^26.6.2" + }, + "engines": { + "node": ">= 10.14.2" + }, + "peerDependencies": { + "ts-node": ">=9.0.0" + }, + "peerDependenciesMeta": { + "ts-node": { + "optional": true + } + } + }, + "node_modules/jest-diff": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "chalk": "^4.0.0", + "diff-sequences": "^26.6.2", + "jest-get-type": "^26.3.0", + "pretty-format": "^26.6.2" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-docblock": { + "version": "26.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "detect-newline": "^3.0.0" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-each": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^26.6.2", + "chalk": "^4.0.0", + "jest-get-type": "^26.3.0", + "jest-util": "^26.6.2", + "pretty-format": "^26.6.2" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-environment-jsdom": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/environment": "^26.6.2", + "@jest/fake-timers": "^26.6.2", + "@jest/types": "^26.6.2", + "@types/node": "*", + "jest-mock": "^26.6.2", + "jest-util": "^26.6.2", + "jsdom": "^16.4.0" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-environment-node": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/environment": "^26.6.2", + "@jest/fake-timers": "^26.6.2", + "@jest/types": "^26.6.2", + "@types/node": "*", + "jest-mock": "^26.6.2", + "jest-util": "^26.6.2" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-get-type": { + "version": "26.3.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-haste-map": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^26.6.2", + "@types/graceful-fs": "^4.1.2", + "@types/node": "*", + "anymatch": "^3.0.3", + "fb-watchman": "^2.0.0", + "graceful-fs": "^4.2.4", + "jest-regex-util": "^26.0.0", + "jest-serializer": "^26.6.2", + "jest-util": "^26.6.2", + "jest-worker": "^26.6.2", + "micromatch": "^4.0.2", + "sane": "^4.0.3", + "walker": "^1.0.7" + }, + "engines": { + "node": ">= 10.14.2" + }, + "optionalDependencies": { + "fsevents": "^2.1.2" + } + }, + "node_modules/jest-jasmine2": { + "version": "26.6.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/traverse": "^7.1.0", + "@jest/environment": "^26.6.2", + "@jest/source-map": "^26.6.2", + "@jest/test-result": "^26.6.2", + "@jest/types": "^26.6.2", + "@types/node": "*", + "chalk": "^4.0.0", + "co": "^4.6.0", + "expect": "^26.6.2", + "is-generator-fn": "^2.0.0", + "jest-each": "^26.6.2", + "jest-matcher-utils": "^26.6.2", + "jest-message-util": "^26.6.2", + "jest-runtime": "^26.6.3", + "jest-snapshot": "^26.6.2", + "jest-util": "^26.6.2", + "pretty-format": "^26.6.2", + "throat": "^5.0.0" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-leak-detector": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "jest-get-type": "^26.3.0", + "pretty-format": "^26.6.2" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-matcher-utils": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "chalk": "^4.0.0", + "jest-diff": "^26.6.2", + "jest-get-type": "^26.3.0", + "pretty-format": "^26.6.2" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-message-util": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.0.0", + "@jest/types": "^26.6.2", + "@types/stack-utils": "^2.0.0", + "chalk": "^4.0.0", + "graceful-fs": "^4.2.4", + "micromatch": "^4.0.2", + "pretty-format": "^26.6.2", + "slash": "^3.0.0", + "stack-utils": "^2.0.2" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-mock": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^26.6.2", + "@types/node": "*" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-pnp-resolver": { + "version": "1.2.3", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + }, + "peerDependencies": { + "jest-resolve": "*" + }, + "peerDependenciesMeta": { + "jest-resolve": { + "optional": true + } + } + }, + "node_modules/jest-regex-util": { + "version": "26.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-resolve": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^26.6.2", + "chalk": "^4.0.0", + "graceful-fs": "^4.2.4", + "jest-pnp-resolver": "^1.2.2", + "jest-util": "^26.6.2", + "read-pkg-up": "^7.0.1", + "resolve": "^1.18.1", + "slash": "^3.0.0" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-resolve-dependencies": { + "version": "26.6.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^26.6.2", + "jest-regex-util": "^26.0.0", + "jest-snapshot": "^26.6.2" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-runner": { + "version": "26.6.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/console": "^26.6.2", + "@jest/environment": "^26.6.2", + "@jest/test-result": "^26.6.2", + "@jest/types": "^26.6.2", + "@types/node": "*", + "chalk": "^4.0.0", + "emittery": "^0.7.1", + "exit": "^0.1.2", + "graceful-fs": "^4.2.4", + "jest-config": "^26.6.3", + "jest-docblock": "^26.0.0", + "jest-haste-map": "^26.6.2", + "jest-leak-detector": "^26.6.2", + "jest-message-util": "^26.6.2", + "jest-resolve": "^26.6.2", + "jest-runtime": "^26.6.3", + "jest-util": "^26.6.2", + "jest-worker": "^26.6.2", + "source-map-support": "^0.5.6", + "throat": "^5.0.0" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-runtime": { + "version": "26.6.3", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/console": "^26.6.2", + "@jest/environment": "^26.6.2", + "@jest/fake-timers": "^26.6.2", + "@jest/globals": "^26.6.2", + "@jest/source-map": "^26.6.2", + "@jest/test-result": "^26.6.2", + "@jest/transform": "^26.6.2", + "@jest/types": "^26.6.2", + "@types/yargs": "^15.0.0", + "chalk": "^4.0.0", + "cjs-module-lexer": "^0.6.0", + "collect-v8-coverage": "^1.0.0", + "exit": "^0.1.2", + "glob": "^7.1.3", + "graceful-fs": "^4.2.4", + "jest-config": "^26.6.3", + "jest-haste-map": "^26.6.2", + "jest-message-util": "^26.6.2", + "jest-mock": "^26.6.2", + "jest-regex-util": "^26.0.0", + "jest-resolve": "^26.6.2", + "jest-snapshot": "^26.6.2", + "jest-util": "^26.6.2", + "jest-validate": "^26.6.2", + "slash": "^3.0.0", + "strip-bom": "^4.0.0", + "yargs": "^15.4.1" + }, + "bin": { + "jest-runtime": "bin/jest-runtime.js" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-runtime/node_modules/strip-bom": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/jest-serializer": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "*", + "graceful-fs": "^4.2.4" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-snapshot": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/types": "^7.0.0", + "@jest/types": "^26.6.2", + "@types/babel__traverse": "^7.0.4", + "@types/prettier": "^2.0.0", + "chalk": "^4.0.0", + "expect": "^26.6.2", + "graceful-fs": "^4.2.4", + "jest-diff": "^26.6.2", + "jest-get-type": "^26.3.0", + "jest-haste-map": "^26.6.2", + "jest-matcher-utils": "^26.6.2", + "jest-message-util": "^26.6.2", + "jest-resolve": "^26.6.2", + "natural-compare": "^1.4.0", + "pretty-format": "^26.6.2", + "semver": "^7.3.2" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-snapshot/node_modules/semver": { + "version": "7.7.1", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/jest-util": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^26.6.2", + "@types/node": "*", + "chalk": "^4.0.0", + "graceful-fs": "^4.2.4", + "is-ci": "^2.0.0", + "micromatch": "^4.0.2" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-validate": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^26.6.2", + "camelcase": "^6.0.0", + "chalk": "^4.0.0", + "jest-get-type": "^26.3.0", + "leven": "^3.1.0", + "pretty-format": "^26.6.2" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-validate/node_modules/camelcase": { + "version": "6.3.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/jest-watcher": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/test-result": "^26.6.2", + "@jest/types": "^26.6.2", + "@types/node": "*", + "ansi-escapes": "^4.2.1", + "chalk": "^4.0.0", + "jest-util": "^26.6.2", + "string-length": "^4.0.1" + }, + "engines": { + "node": ">= 10.14.2" + } + }, + "node_modules/jest-worker": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/node": "*", + "merge-stream": "^2.0.0", + "supports-color": "^7.0.0" + }, + "engines": { + "node": ">= 10.13.0" + } + }, + "node_modules/js-tokens": { + "version": "4.0.0", + "license": "MIT" + }, + "node_modules/js-yaml": { + "version": "3.14.1", + "dev": true, + "license": "MIT", + "dependencies": { + "argparse": "^1.0.7", + "esprima": "^4.0.0" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" + } + }, + "node_modules/jsdom": { + "version": "16.7.0", + "dev": true, + "license": "MIT", + "dependencies": { + "abab": "^2.0.5", + "acorn": "^8.2.4", + "acorn-globals": "^6.0.0", + "cssom": "^0.4.4", + "cssstyle": "^2.3.0", + "data-urls": "^2.0.0", + "decimal.js": "^10.2.1", + "domexception": "^2.0.1", + "escodegen": "^2.0.0", + "form-data": "^3.0.0", + "html-encoding-sniffer": "^2.0.1", + "http-proxy-agent": "^4.0.1", + "https-proxy-agent": "^5.0.0", + "is-potential-custom-element-name": "^1.0.1", + "nwsapi": "^2.2.0", + "parse5": "6.0.1", + "saxes": "^5.0.1", + "symbol-tree": "^3.2.4", + "tough-cookie": "^4.0.0", + "w3c-hr-time": "^1.0.2", + "w3c-xmlserializer": "^2.0.0", + "webidl-conversions": "^6.1.0", + "whatwg-encoding": "^1.0.5", + "whatwg-mimetype": "^2.3.0", + "whatwg-url": "^8.5.0", + "ws": "^7.4.6", + "xml-name-validator": "^3.0.0" + }, + "engines": { + "node": ">=10" + }, + "peerDependencies": { + "canvas": "^2.5.0" + }, + "peerDependenciesMeta": { + "canvas": { + "optional": true + } + } + }, + "node_modules/jsdom/node_modules/acorn": { + "version": "8.14.1", + "dev": true, + "license": "MIT", + "bin": { + "acorn": "bin/acorn" + }, + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/jsesc": { + "version": "3.1.0", + "license": "MIT", + "bin": { + "jsesc": "bin/jsesc" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/json-buffer": { + "version": "3.0.1", + "dev": true, + "license": "MIT" + }, + "node_modules/json-parse-better-errors": { + "version": "1.0.2", + "dev": true, + "license": "MIT" + }, + "node_modules/json-parse-even-better-errors": { + "version": "2.3.1", + "dev": true, + "license": "MIT" + }, + "node_modules/json-schema-traverse": { + "version": "0.4.1", + "dev": true, + "license": "MIT" + }, + "node_modules/json-stable-stringify-without-jsonify": { + "version": "1.0.1", + "dev": true, + "license": "MIT" + }, + "node_modules/json-stringify-safe": { + "version": "5.0.1", + "dev": true, + "license": "ISC" + }, + "node_modules/json5": { + "version": "2.2.3", + "dev": true, + "license": "MIT", + "bin": { + "json5": "lib/cli.js" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/jsonfile": { + "version": "6.1.0", + "license": "MIT", + "dependencies": { + "universalify": "^2.0.0" + }, + "optionalDependencies": { + "graceful-fs": "^4.1.6" + } + }, + "node_modules/jsonparse": { + "version": "1.3.1", + "dev": true, + "engines": [ + "node >= 0.2.0" + ], + "license": "MIT" + }, + "node_modules/JSONStream": { + "version": "1.3.5", + "dev": true, + "license": "(MIT OR Apache-2.0)", + "dependencies": { + "jsonparse": "^1.2.0", + "through": ">=2.2.7 <3" + }, + "bin": { + "JSONStream": "bin.js" + }, + "engines": { + "node": "*" + } + }, + "node_modules/keyv": { + "version": "4.5.4", + "dev": true, + "license": "MIT", + "dependencies": { + "json-buffer": "3.0.1" + } + }, + "node_modules/kind-of": { + "version": "6.0.3", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/kleur": { + "version": "3.0.3", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/leven": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/levn": { + "version": "0.4.1", + "dev": true, + "license": "MIT", + "dependencies": { + "prelude-ls": "^1.2.1", + "type-check": "~0.4.0" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/lines-and-columns": { + "version": "1.2.4", + "dev": true, + "license": "MIT" + }, + "node_modules/lint-staged": { + "version": "10.5.4", + "dev": true, + "license": "MIT", + "dependencies": { + "chalk": "^4.1.0", + "cli-truncate": "^2.1.0", + "commander": "^6.2.0", + "cosmiconfig": "^7.0.0", + "debug": "^4.2.0", + "dedent": "^0.7.0", + "enquirer": "^2.3.6", + "execa": "^4.1.0", + "listr2": "^3.2.2", + "log-symbols": "^4.0.0", + "micromatch": "^4.0.2", + "normalize-path": "^3.0.0", + "please-upgrade-node": "^3.2.0", + "string-argv": "0.3.1", + "stringify-object": "^3.3.0" + }, + "bin": { + "lint-staged": "bin/lint-staged.js" + }, + "funding": { + "url": "https://opencollective.com/lint-staged" + } + }, + "node_modules/listr2": { + "version": "3.14.0", + "dev": true, + "license": "MIT", + "dependencies": { + "cli-truncate": "^2.1.0", + "colorette": "^2.0.16", + "log-update": "^4.0.0", + "p-map": "^4.0.0", + "rfdc": "^1.3.0", + "rxjs": "^7.5.1", + "through": "^2.3.8", + "wrap-ansi": "^7.0.0" + }, + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "enquirer": ">= 2.3.0 < 3" + }, + "peerDependenciesMeta": { + "enquirer": { + "optional": true + } + } + }, + "node_modules/load-json-file": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "graceful-fs": "^4.1.2", + "parse-json": "^4.0.0", + "pify": "^3.0.0", + "strip-bom": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/load-json-file/node_modules/parse-json": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "error-ex": "^1.3.1", + "json-parse-better-errors": "^1.0.1" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/loader-utils": { + "version": "3.3.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 12.13.0" + } + }, + "node_modules/locate-path": { + "version": "5.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "p-locate": "^4.1.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/lodash": { + "version": "4.17.21", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.camelcase": { + "version": "4.3.0", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.capitalize": { + "version": "4.2.1", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.debounce": { + "version": "4.0.8", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.escaperegexp": { + "version": "4.1.2", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.get": { + "version": "4.4.2", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.ismatch": { + "version": "4.4.0", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.isplainobject": { + "version": "4.0.6", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.isstring": { + "version": "4.0.1", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.memoize": { + "version": "4.1.2", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.merge": { + "version": "4.6.2", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.truncate": { + "version": "4.4.2", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.uniq": { + "version": "4.5.0", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.uniqby": { + "version": "4.7.0", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.zip": { + "version": "4.2.0", + "dev": true, + "license": "MIT" + }, + "node_modules/log-symbols": { + "version": "4.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "chalk": "^4.1.0", + "is-unicode-supported": "^0.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/log-update": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-escapes": "^4.3.0", + "cli-cursor": "^3.1.0", + "slice-ansi": "^4.0.0", + "wrap-ansi": "^6.2.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/log-update/node_modules/wrap-ansi": { + "version": "6.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/lru-cache": { + "version": "5.1.1", + "dev": true, + "license": "ISC", + "dependencies": { + "yallist": "^3.0.2" + } + }, + "node_modules/magic-string": { + "version": "0.25.9", + "dev": true, + "license": "MIT", + "dependencies": { + "sourcemap-codec": "^1.4.8" + } + }, + "node_modules/make-dir": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "semver": "^7.5.3" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/make-dir/node_modules/semver": { + "version": "7.7.1", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/make-error": { + "version": "1.3.6", + "dev": true, + "license": "ISC" + }, + "node_modules/makeerror": { + "version": "1.0.12", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "tmpl": "1.0.5" + } + }, + "node_modules/map-cache": { + "version": "0.2.2", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/map-obj": { + "version": "4.3.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/map-visit": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "object-visit": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/marked": { + "version": "2.1.3", + "dev": true, + "license": "MIT", + "bin": { + "marked": "bin/marked" + }, + "engines": { + "node": ">= 10" + } + }, + "node_modules/marked-terminal": { + "version": "4.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-escapes": "^4.3.1", + "cardinal": "^2.1.1", + "chalk": "^4.1.0", + "cli-table3": "^0.6.0", + "node-emoji": "^1.10.0", + "supports-hyperlinks": "^2.1.0" + }, + "peerDependencies": { + "marked": "^1.0.0 || ^2.0.0" + } + }, + "node_modules/math-intrinsics": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/mdn-data": { + "version": "2.0.4", + "dev": true, + "license": "CC0-1.0" + }, + "node_modules/meow": { + "version": "8.1.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/minimist": "^1.2.0", + "camelcase-keys": "^6.2.2", + "decamelize-keys": "^1.1.0", + "hard-rejection": "^2.1.0", + "minimist-options": "4.1.0", + "normalize-package-data": "^3.0.0", + "read-pkg-up": "^7.0.1", + "redent": "^3.0.0", + "trim-newlines": "^3.0.0", + "type-fest": "^0.18.0", + "yargs-parser": "^20.2.3" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/meow/node_modules/normalize-package-data": { + "version": "3.0.3", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "hosted-git-info": "^4.0.1", + "is-core-module": "^2.5.0", + "semver": "^7.3.4", + "validate-npm-package-license": "^3.0.1" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/meow/node_modules/normalize-package-data/node_modules/semver": { + "version": "7.7.1", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/meow/node_modules/type-fest": { + "version": "0.18.1", + "dev": true, + "license": "(MIT OR CC0-1.0)", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/merge-source-map": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "source-map": "^0.6.1" + } + }, + "node_modules/merge-stream": { + "version": "2.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/merge2": { + "version": "1.4.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 8" + } + }, + "node_modules/micromatch": { + "version": "4.0.8", + "dev": true, + "license": "MIT", + "dependencies": { + "braces": "^3.0.3", + "picomatch": "^2.3.1" + }, + "engines": { + "node": ">=8.6" + } + }, + "node_modules/mime": { + "version": "2.6.0", + "dev": true, + "license": "MIT", + "bin": { + "mime": "cli.js" + }, + "engines": { + "node": ">=4.0.0" + } + }, + "node_modules/mime-db": { + "version": "1.52.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mime-types": { + "version": "2.1.35", + "dev": true, + "license": "MIT", + "dependencies": { + "mime-db": "1.52.0" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mimic-fn": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/min-indent": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/minimatch": { + "version": "3.1.2", + "license": "ISC", + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/minimist": { + "version": "1.2.8", + "dev": true, + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/minimist-options": { + "version": "4.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "arrify": "^1.0.1", + "is-plain-obj": "^1.1.0", + "kind-of": "^6.0.3" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/mixin-deep": { + "version": "1.3.2", + "dev": true, + "license": "MIT", + "dependencies": { + "for-in": "^1.0.2", + "is-extendable": "^1.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/mkdirp": { + "version": "1.0.4", + "dev": true, + "license": "MIT", + "bin": { + "mkdirp": "bin/cmd.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/modify-values": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/ms": { + "version": "2.1.3", + "license": "MIT" + }, + "node_modules/multimap": { + "version": "1.1.0", + "dev": true, + "license": "MIT" + }, + "node_modules/mute-stream": { + "version": "0.0.5", + "dev": true, + "license": "ISC" + }, + "node_modules/nanoid": { + "version": "3.3.11", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "bin": { + "nanoid": "bin/nanoid.cjs" + }, + "engines": { + "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" + } + }, + "node_modules/nanomatch": { + "version": "1.2.13", + "dev": true, + "license": "MIT", + "dependencies": { + "arr-diff": "^4.0.0", + "array-unique": "^0.3.2", + "define-property": "^2.0.2", + "extend-shallow": "^3.0.2", + "fragment-cache": "^0.2.1", + "is-windows": "^1.0.2", + "kind-of": "^6.0.2", + "object.pick": "^1.3.0", + "regex-not": "^1.0.0", + "snapdragon": "^0.8.1", + "to-regex": "^3.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/natural-compare": { + "version": "1.4.0", + "dev": true, + "license": "MIT" + }, + "node_modules/neo-async": { + "version": "2.6.2", + "dev": true, + "license": "MIT" + }, + "node_modules/nerf-dart": { + "version": "1.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/nice-try": { + "version": "1.0.5", + "dev": true, + "license": "MIT" + }, + "node_modules/node-emoji": { + "version": "1.11.0", + "dev": true, + "license": "MIT", + "dependencies": { + "lodash": "^4.17.21" + } + }, + "node_modules/node-fetch": { + "version": "2.7.0", + "dev": true, + "license": "MIT", + "dependencies": { + "whatwg-url": "^5.0.0" + }, + "engines": { + "node": "4.x || >=6.0.0" + }, + "peerDependencies": { + "encoding": "^0.1.0" + }, + "peerDependenciesMeta": { + "encoding": { + "optional": true + } + } + }, + "node_modules/node-fetch/node_modules/whatwg-url": { + "version": "5.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "tr46": "~0.0.3", + "webidl-conversions": "^3.0.0" + } + }, + "node_modules/node-fetch/node_modules/whatwg-url/node_modules/tr46": { + "version": "0.0.3", + "dev": true, + "license": "MIT" + }, + "node_modules/node-fetch/node_modules/whatwg-url/node_modules/webidl-conversions": { + "version": "3.0.1", + "dev": true, + "license": "BSD-2-Clause" + }, + "node_modules/node-int64": { + "version": "0.4.0", + "dev": true, + "license": "MIT" + }, + "node_modules/node-localstorage": { + "version": "0.6.0", + "dev": true, + "engines": { + "node": ">=0.10" + } + }, + "node_modules/node-notifier": { + "version": "8.0.2", + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "growly": "^1.3.0", + "is-wsl": "^2.2.0", + "semver": "^7.3.2", + "shellwords": "^0.1.1", + "uuid": "^8.3.0", + "which": "^2.0.2" + } + }, + "node_modules/node-notifier/node_modules/semver": { + "version": "7.7.1", + "dev": true, + "license": "ISC", + "optional": true, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/node-releases": { + "version": "2.0.19", + "dev": true, + "license": "MIT" + }, + "node_modules/normalize-package-data": { + "version": "2.5.0", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "hosted-git-info": "^2.1.4", + "resolve": "^1.10.0", + "semver": "2 || 3 || 4 || 5", + "validate-npm-package-license": "^3.0.1" + } + }, + "node_modules/normalize-package-data/node_modules/hosted-git-info": { + "version": "2.8.9", + "dev": true, + "license": "ISC" + }, + "node_modules/normalize-package-data/node_modules/semver": { + "version": "5.7.2", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver" + } + }, + "node_modules/normalize-path": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/normalize-url": { + "version": "6.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/npm": { + "version": "7.24.2", + "bundleDependencies": [ + "@isaacs/string-locale-compare", + "@npmcli/arborist", + "@npmcli/ci-detect", + "@npmcli/config", + "@npmcli/map-workspaces", + "@npmcli/package-json", + "@npmcli/run-script", + "abbrev", + "ansicolors", + "ansistyles", + "archy", + "cacache", + "chalk", + "chownr", + "cli-columns", + "cli-table3", + "columnify", + "fastest-levenshtein", + "glob", + "graceful-fs", + "hosted-git-info", + "ini", + "init-package-json", + "is-cidr", + "json-parse-even-better-errors", + "libnpmaccess", + "libnpmdiff", + "libnpmexec", + "libnpmfund", + "libnpmhook", + "libnpmorg", + "libnpmpack", + "libnpmpublish", + "libnpmsearch", + "libnpmteam", + "libnpmversion", + "make-fetch-happen", + "minipass", + "minipass-pipeline", + "mkdirp", + "mkdirp-infer-owner", + "ms", + "node-gyp", + "nopt", + "npm-audit-report", + "npm-install-checks", + "npm-package-arg", + "npm-pick-manifest", + "npm-profile", + "npm-registry-fetch", + "npm-user-validate", + "npmlog", + "opener", + "pacote", + "parse-conflict-json", + "qrcode-terminal", + "read", + "read-package-json", + "read-package-json-fast", + "readdir-scoped-modules", + "rimraf", + "semver", + "ssri", + "tar", + "text-table", + "tiny-relative-date", + "treeverse", + "validate-npm-package-name", + "which", + "write-file-atomic" + ], + "dev": true, + "license": "Artistic-2.0", + "workspaces": [ + "docs", + "packages/*" + ], + "dependencies": { + "@isaacs/string-locale-compare": "^1.1.0", + "@npmcli/arborist": "^2.9.0", + "@npmcli/ci-detect": "^1.2.0", + "@npmcli/config": "^2.3.0", + "@npmcli/map-workspaces": "^1.0.4", + "@npmcli/package-json": "^1.0.1", + "@npmcli/run-script": "^1.8.6", + "abbrev": "~1.1.1", + "ansicolors": "~0.3.2", + "ansistyles": "~0.1.3", + "archy": "~1.0.0", + "cacache": "^15.3.0", + "chalk": "^4.1.2", + "chownr": "^2.0.0", + "cli-columns": "^3.1.2", + "cli-table3": "^0.6.0", + "columnify": "~1.5.4", + "fastest-levenshtein": "^1.0.12", + "glob": "^7.2.0", + "graceful-fs": "^4.2.8", + "hosted-git-info": "^4.0.2", + "ini": "^2.0.0", + "init-package-json": "^2.0.5", + "is-cidr": "^4.0.2", + "json-parse-even-better-errors": "^2.3.1", + "libnpmaccess": "^4.0.2", + "libnpmdiff": "^2.0.4", + "libnpmexec": "^2.0.1", + "libnpmfund": "^1.1.0", + "libnpmhook": "^6.0.2", + "libnpmorg": "^2.0.2", + "libnpmpack": "^2.0.1", + "libnpmpublish": "^4.0.1", + "libnpmsearch": "^3.1.1", + "libnpmteam": "^2.0.3", + "libnpmversion": "^1.2.1", + "make-fetch-happen": "^9.1.0", + "minipass": "^3.1.3", + "minipass-pipeline": "^1.2.4", + "mkdirp": "^1.0.4", + "mkdirp-infer-owner": "^2.0.0", + "ms": "^2.1.2", + "node-gyp": "^7.1.2", + "nopt": "^5.0.0", + "npm-audit-report": "^2.1.5", + "npm-install-checks": "^4.0.0", + "npm-package-arg": "^8.1.5", + "npm-pick-manifest": "^6.1.1", + "npm-profile": "^5.0.3", + "npm-registry-fetch": "^11.0.0", + "npm-user-validate": "^1.0.1", + "npmlog": "^5.0.1", + "opener": "^1.5.2", + "pacote": "^11.3.5", + "parse-conflict-json": "^1.1.1", + "qrcode-terminal": "^0.12.0", + "read": "~1.0.7", + "read-package-json": "^4.1.1", + "read-package-json-fast": "^2.0.3", + "readdir-scoped-modules": "^1.1.0", + "rimraf": "^3.0.2", + "semver": "^7.3.5", + "ssri": "^8.0.1", + "tar": "^6.1.11", + "text-table": "~0.2.0", + "tiny-relative-date": "^1.3.0", + "treeverse": "^1.0.4", + "validate-npm-package-name": "~3.0.0", + "which": "^2.0.2", + "write-file-atomic": "^3.0.3" + }, + "bin": { + "npm": "bin/npm-cli.js", + "npx": "bin/npx-cli.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm-run-path": { + "version": "4.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "path-key": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/npm/node_modules/@gar/promisify": { + "version": "1.1.2", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/@isaacs/string-locale-compare": { + "version": "1.1.0", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/@npmcli/arborist": { + "version": "2.9.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "@isaacs/string-locale-compare": "^1.0.1", + "@npmcli/installed-package-contents": "^1.0.7", + "@npmcli/map-workspaces": "^1.0.2", + "@npmcli/metavuln-calculator": "^1.1.0", + "@npmcli/move-file": "^1.1.0", + "@npmcli/name-from-folder": "^1.0.1", + "@npmcli/node-gyp": "^1.0.1", + "@npmcli/package-json": "^1.0.1", + "@npmcli/run-script": "^1.8.2", + "bin-links": "^2.2.1", + "cacache": "^15.0.3", + "common-ancestor-path": "^1.0.1", + "json-parse-even-better-errors": "^2.3.1", + "json-stringify-nice": "^1.1.4", + "mkdirp": "^1.0.4", + "mkdirp-infer-owner": "^2.0.0", + "npm-install-checks": "^4.0.0", + "npm-package-arg": "^8.1.5", + "npm-pick-manifest": "^6.1.0", + "npm-registry-fetch": "^11.0.0", + "pacote": "^11.3.5", + "parse-conflict-json": "^1.1.1", + "proc-log": "^1.0.0", + "promise-all-reject-late": "^1.0.0", + "promise-call-limit": "^1.0.1", + "read-package-json-fast": "^2.0.2", + "readdir-scoped-modules": "^1.1.0", + "rimraf": "^3.0.2", + "semver": "^7.3.5", + "ssri": "^8.0.1", + "treeverse": "^1.0.4", + "walk-up-path": "^1.0.0" + }, + "bin": { + "arborist": "bin/index.js" + }, + "engines": { + "node": ">= 10" + } + }, + "node_modules/npm/node_modules/@npmcli/ci-detect": { + "version": "1.3.0", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/@npmcli/config": { + "version": "2.3.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "ini": "^2.0.0", + "mkdirp-infer-owner": "^2.0.0", + "nopt": "^5.0.0", + "semver": "^7.3.4", + "walk-up-path": "^1.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/@npmcli/disparity-colors": { + "version": "1.0.1", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "ansi-styles": "^4.3.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/@npmcli/fs": { + "version": "1.0.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "@gar/promisify": "^1.0.1", + "semver": "^7.3.5" + } + }, + "node_modules/npm/node_modules/@npmcli/git": { + "version": "2.1.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "@npmcli/promise-spawn": "^1.3.2", + "lru-cache": "^6.0.0", + "mkdirp": "^1.0.4", + "npm-pick-manifest": "^6.1.1", + "promise-inflight": "^1.0.1", + "promise-retry": "^2.0.1", + "semver": "^7.3.5", + "which": "^2.0.2" + } + }, + "node_modules/npm/node_modules/@npmcli/installed-package-contents": { + "version": "1.0.7", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "npm-bundled": "^1.1.1", + "npm-normalize-package-bin": "^1.0.1" + }, + "bin": { + "installed-package-contents": "index.js" + }, + "engines": { + "node": ">= 10" + } + }, + "node_modules/npm/node_modules/@npmcli/map-workspaces": { + "version": "1.0.4", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "@npmcli/name-from-folder": "^1.0.1", + "glob": "^7.1.6", + "minimatch": "^3.0.4", + "read-package-json-fast": "^2.0.1" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/@npmcli/metavuln-calculator": { + "version": "1.1.1", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "cacache": "^15.0.5", + "pacote": "^11.1.11", + "semver": "^7.3.2" + } + }, + "node_modules/npm/node_modules/@npmcli/move-file": { + "version": "1.1.2", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "mkdirp": "^1.0.4", + "rimraf": "^3.0.2" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/@npmcli/name-from-folder": { + "version": "1.0.1", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/@npmcli/node-gyp": { + "version": "1.0.2", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/@npmcli/package-json": { + "version": "1.0.1", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "json-parse-even-better-errors": "^2.3.1" + } + }, + "node_modules/npm/node_modules/@npmcli/promise-spawn": { + "version": "1.3.2", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "infer-owner": "^1.0.4" + } + }, + "node_modules/npm/node_modules/@npmcli/run-script": { + "version": "1.8.6", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "@npmcli/node-gyp": "^1.0.2", + "@npmcli/promise-spawn": "^1.3.2", + "node-gyp": "^7.1.0", + "read-package-json-fast": "^2.0.1" + } + }, + "node_modules/npm/node_modules/@tootallnate/once": { + "version": "1.1.2", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">= 6" + } + }, + "node_modules/npm/node_modules/abbrev": { + "version": "1.1.1", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/agent-base": { + "version": "6.0.2", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "debug": "4" + }, + "engines": { + "node": ">= 6.0.0" + } + }, + "node_modules/npm/node_modules/agentkeepalive": { + "version": "4.1.4", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "debug": "^4.1.0", + "depd": "^1.1.2", + "humanize-ms": "^1.2.1" + }, + "engines": { + "node": ">= 8.0.0" + } + }, + "node_modules/npm/node_modules/aggregate-error": { + "version": "3.1.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "clean-stack": "^2.0.0", + "indent-string": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/npm/node_modules/ajv": { + "version": "6.12.6", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "fast-deep-equal": "^3.1.1", + "fast-json-stable-stringify": "^2.0.0", + "json-schema-traverse": "^0.4.1", + "uri-js": "^4.2.2" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" + } + }, + "node_modules/npm/node_modules/ansi-regex": { + "version": "2.1.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/npm/node_modules/ansi-styles": { + "version": "4.3.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/npm/node_modules/ansicolors": { + "version": "0.3.2", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/ansistyles": { + "version": "0.1.3", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/aproba": { + "version": "2.0.0", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/archy": { + "version": "1.0.0", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/are-we-there-yet": { + "version": "1.1.6", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "delegates": "^1.0.0", + "readable-stream": "^3.6.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/asap": { + "version": "2.0.6", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/asn1": { + "version": "0.2.4", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "safer-buffer": "~2.1.0" + } + }, + "node_modules/npm/node_modules/assert-plus": { + "version": "1.0.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=0.8" + } + }, + "node_modules/npm/node_modules/asynckit": { + "version": "0.4.0", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/aws-sign2": { + "version": "0.7.0", + "dev": true, + "inBundle": true, + "license": "Apache-2.0", + "engines": { + "node": "*" + } + }, + "node_modules/npm/node_modules/aws4": { + "version": "1.11.0", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/balanced-match": { + "version": "1.0.2", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/bcrypt-pbkdf": { + "version": "1.0.2", + "dev": true, + "inBundle": true, + "license": "BSD-3-Clause", + "dependencies": { + "tweetnacl": "^0.14.3" + } + }, + "node_modules/npm/node_modules/bin-links": { + "version": "2.2.1", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "cmd-shim": "^4.0.1", + "mkdirp": "^1.0.3", + "npm-normalize-package-bin": "^1.0.0", + "read-cmd-shim": "^2.0.0", + "rimraf": "^3.0.0", + "write-file-atomic": "^3.0.3" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/binary-extensions": { + "version": "2.2.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/npm/node_modules/brace-expansion": { + "version": "1.1.11", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/npm/node_modules/builtins": { + "version": "1.0.3", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/cacache": { + "version": "15.3.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "@npmcli/fs": "^1.0.0", + "@npmcli/move-file": "^1.0.1", + "chownr": "^2.0.0", + "fs-minipass": "^2.0.0", + "glob": "^7.1.4", + "infer-owner": "^1.0.4", + "lru-cache": "^6.0.0", + "minipass": "^3.1.1", + "minipass-collect": "^1.0.2", + "minipass-flush": "^1.0.5", + "minipass-pipeline": "^1.2.2", + "mkdirp": "^1.0.3", + "p-map": "^4.0.0", + "promise-inflight": "^1.0.1", + "rimraf": "^3.0.2", + "ssri": "^8.0.1", + "tar": "^6.0.2", + "unique-filename": "^1.1.1" + }, + "engines": { + "node": ">= 10" + } + }, + "node_modules/npm/node_modules/caseless": { + "version": "0.12.0", + "dev": true, + "inBundle": true, + "license": "Apache-2.0" + }, + "node_modules/npm/node_modules/chalk": { + "version": "4.1.2", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/npm/node_modules/chownr": { + "version": "2.0.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/cidr-regex": { + "version": "3.1.1", + "dev": true, + "inBundle": true, + "license": "BSD-2-Clause", + "dependencies": { + "ip-regex": "^4.1.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/clean-stack": { + "version": "2.2.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/npm/node_modules/cli-columns": { + "version": "3.1.2", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "string-width": "^2.0.0", + "strip-ansi": "^3.0.1" + }, + "engines": { + "node": ">= 4" + } + }, + "node_modules/npm/node_modules/cli-table3": { + "version": "0.6.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "object-assign": "^4.1.0", + "string-width": "^4.2.0" + }, + "engines": { + "node": "10.* || >= 12.*" + }, + "optionalDependencies": { + "colors": "^1.1.2" + } + }, + "node_modules/npm/node_modules/cli-table3/node_modules/ansi-regex": { + "version": "5.0.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/npm/node_modules/cli-table3/node_modules/is-fullwidth-code-point": { + "version": "3.0.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/npm/node_modules/cli-table3/node_modules/string-width": { + "version": "4.2.2", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/npm/node_modules/cli-table3/node_modules/strip-ansi": { + "version": "6.0.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "ansi-regex": "^5.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/npm/node_modules/clone": { + "version": "1.0.4", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=0.8" + } + }, + "node_modules/npm/node_modules/cmd-shim": { + "version": "4.1.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "mkdirp-infer-owner": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/code-point-at": { + "version": "1.1.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/npm/node_modules/color-convert": { + "version": "2.0.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/npm/node_modules/color-name": { + "version": "1.1.4", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/color-support": { + "version": "1.1.3", + "dev": true, + "inBundle": true, + "license": "ISC", + "bin": { + "color-support": "bin.js" + } + }, + "node_modules/npm/node_modules/colors": { + "version": "1.4.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "optional": true, + "engines": { + "node": ">=0.1.90" + } + }, + "node_modules/npm/node_modules/columnify": { + "version": "1.5.4", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "strip-ansi": "^3.0.0", + "wcwidth": "^1.0.0" + } + }, + "node_modules/npm/node_modules/combined-stream": { + "version": "1.0.8", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "delayed-stream": "~1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/npm/node_modules/common-ancestor-path": { + "version": "1.0.1", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/concat-map": { + "version": "0.0.1", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/console-control-strings": { + "version": "1.1.0", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/core-util-is": { + "version": "1.0.2", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/dashdash": { + "version": "1.14.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "assert-plus": "^1.0.0" + }, + "engines": { + "node": ">=0.10" + } + }, + "node_modules/npm/node_modules/debug": { + "version": "4.3.2", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "ms": "2.1.2" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/npm/node_modules/debug/node_modules/ms": { + "version": "2.1.2", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/debuglog": { + "version": "1.0.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": "*" + } + }, + "node_modules/npm/node_modules/defaults": { + "version": "1.0.3", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "clone": "^1.0.2" + } + }, + "node_modules/npm/node_modules/delayed-stream": { + "version": "1.0.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/npm/node_modules/delegates": { + "version": "1.0.0", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/depd": { + "version": "1.1.2", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/npm/node_modules/dezalgo": { + "version": "1.0.3", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "asap": "^2.0.0", + "wrappy": "1" + } + }, + "node_modules/npm/node_modules/diff": { + "version": "5.0.0", + "dev": true, + "inBundle": true, + "license": "BSD-3-Clause", + "engines": { + "node": ">=0.3.1" + } + }, + "node_modules/npm/node_modules/ecc-jsbn": { + "version": "0.1.2", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "jsbn": "~0.1.0", + "safer-buffer": "^2.1.0" + } + }, + "node_modules/npm/node_modules/emoji-regex": { + "version": "8.0.0", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/encoding": { + "version": "0.1.13", + "dev": true, + "inBundle": true, + "license": "MIT", + "optional": true, + "dependencies": { + "iconv-lite": "^0.6.2" + } + }, + "node_modules/npm/node_modules/env-paths": { + "version": "2.2.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/npm/node_modules/err-code": { + "version": "2.0.3", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/extend": { + "version": "3.0.2", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/extsprintf": { + "version": "1.3.0", + "dev": true, + "engines": [ + "node >=0.6.0" + ], + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/fast-deep-equal": { + "version": "3.1.3", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/fast-json-stable-stringify": { + "version": "2.1.0", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/fastest-levenshtein": { + "version": "1.0.12", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/forever-agent": { + "version": "0.6.1", + "dev": true, + "inBundle": true, + "license": "Apache-2.0", + "engines": { + "node": "*" + } + }, + "node_modules/npm/node_modules/fs-minipass": { + "version": "2.1.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "minipass": "^3.0.0" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/npm/node_modules/fs.realpath": { + "version": "1.0.0", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/function-bind": { + "version": "1.1.1", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/gauge": { + "version": "3.0.1", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "aproba": "^1.0.3 || ^2.0.0", + "color-support": "^1.1.2", + "console-control-strings": "^1.0.0", + "has-unicode": "^2.0.1", + "object-assign": "^4.1.1", + "signal-exit": "^3.0.0", + "string-width": "^1.0.1 || ^2.0.0", + "strip-ansi": "^3.0.1 || ^4.0.0", + "wide-align": "^1.1.2" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/getpass": { + "version": "0.1.7", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "assert-plus": "^1.0.0" + } + }, + "node_modules/npm/node_modules/glob": { + "version": "7.2.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + }, + "engines": { + "node": "*" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/npm/node_modules/graceful-fs": { + "version": "4.2.8", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/har-schema": { + "version": "2.0.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "engines": { + "node": ">=4" + } + }, + "node_modules/npm/node_modules/har-validator": { + "version": "5.1.5", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "ajv": "^6.12.3", + "har-schema": "^2.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/npm/node_modules/has": { + "version": "1.0.3", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "function-bind": "^1.1.1" + }, + "engines": { + "node": ">= 0.4.0" + } + }, + "node_modules/npm/node_modules/has-flag": { + "version": "4.0.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/npm/node_modules/has-unicode": { + "version": "2.0.1", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/hosted-git-info": { + "version": "4.0.2", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "lru-cache": "^6.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/http-cache-semantics": { + "version": "4.1.0", + "dev": true, + "inBundle": true, + "license": "BSD-2-Clause" + }, + "node_modules/npm/node_modules/http-proxy-agent": { + "version": "4.0.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "@tootallnate/once": "1", + "agent-base": "6", + "debug": "4" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/npm/node_modules/http-signature": { + "version": "1.2.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "assert-plus": "^1.0.0", + "jsprim": "^1.2.2", + "sshpk": "^1.7.0" + }, + "engines": { + "node": ">=0.8", + "npm": ">=1.3.7" + } + }, + "node_modules/npm/node_modules/https-proxy-agent": { + "version": "5.0.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "agent-base": "6", + "debug": "4" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/npm/node_modules/humanize-ms": { + "version": "1.2.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "ms": "^2.0.0" + } + }, + "node_modules/npm/node_modules/iconv-lite": { + "version": "0.6.3", + "dev": true, + "inBundle": true, + "license": "MIT", + "optional": true, + "dependencies": { + "safer-buffer": ">= 2.1.2 < 3.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/npm/node_modules/ignore-walk": { + "version": "3.0.4", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "minimatch": "^3.0.4" + } + }, + "node_modules/npm/node_modules/imurmurhash": { + "version": "0.1.4", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=0.8.19" + } + }, + "node_modules/npm/node_modules/indent-string": { + "version": "4.0.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/npm/node_modules/infer-owner": { + "version": "1.0.4", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/inflight": { + "version": "1.0.6", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "node_modules/npm/node_modules/inherits": { + "version": "2.0.4", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/ini": { + "version": "2.0.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/init-package-json": { + "version": "2.0.5", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "npm-package-arg": "^8.1.5", + "promzard": "^0.3.0", + "read": "~1.0.1", + "read-package-json": "^4.1.1", + "semver": "^7.3.5", + "validate-npm-package-license": "^3.0.4", + "validate-npm-package-name": "^3.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/ip": { + "version": "1.1.5", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/ip-regex": { + "version": "4.3.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/npm/node_modules/is-cidr": { + "version": "4.0.2", + "dev": true, + "inBundle": true, + "license": "BSD-2-Clause", + "dependencies": { + "cidr-regex": "^3.1.1" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/is-core-module": { + "version": "2.7.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "has": "^1.0.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/npm/node_modules/is-fullwidth-code-point": { + "version": "2.0.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/npm/node_modules/is-lambda": { + "version": "1.0.1", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/is-typedarray": { + "version": "1.0.0", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/isexe": { + "version": "2.0.0", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/isstream": { + "version": "0.1.2", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/jsbn": { + "version": "0.1.1", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/json-parse-even-better-errors": { + "version": "2.3.1", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/json-schema": { + "version": "0.2.3", + "dev": true, + "inBundle": true + }, + "node_modules/npm/node_modules/json-schema-traverse": { + "version": "0.4.1", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/json-stringify-nice": { + "version": "1.1.4", + "dev": true, + "inBundle": true, + "license": "ISC", + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/npm/node_modules/json-stringify-safe": { + "version": "5.0.1", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/jsonparse": { + "version": "1.3.1", + "dev": true, + "engines": [ + "node >= 0.2.0" + ], + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/jsprim": { + "version": "1.4.1", + "dev": true, + "engines": [ + "node >=0.6.0" + ], + "inBundle": true, + "license": "MIT", + "dependencies": { + "assert-plus": "1.0.0", + "extsprintf": "1.3.0", + "json-schema": "0.2.3", + "verror": "1.10.0" + } + }, + "node_modules/npm/node_modules/just-diff": { + "version": "3.1.1", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/just-diff-apply": { + "version": "3.0.0", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/libnpmaccess": { + "version": "4.0.3", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "aproba": "^2.0.0", + "minipass": "^3.1.1", + "npm-package-arg": "^8.1.2", + "npm-registry-fetch": "^11.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/libnpmdiff": { + "version": "2.0.4", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "@npmcli/disparity-colors": "^1.0.1", + "@npmcli/installed-package-contents": "^1.0.7", + "binary-extensions": "^2.2.0", + "diff": "^5.0.0", + "minimatch": "^3.0.4", + "npm-package-arg": "^8.1.4", + "pacote": "^11.3.4", + "tar": "^6.1.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/libnpmexec": { + "version": "2.0.1", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "@npmcli/arborist": "^2.3.0", + "@npmcli/ci-detect": "^1.3.0", + "@npmcli/run-script": "^1.8.4", + "chalk": "^4.1.0", + "mkdirp-infer-owner": "^2.0.0", + "npm-package-arg": "^8.1.2", + "pacote": "^11.3.1", + "proc-log": "^1.0.0", + "read": "^1.0.7", + "read-package-json-fast": "^2.0.2", + "walk-up-path": "^1.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/libnpmfund": { + "version": "1.1.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "@npmcli/arborist": "^2.5.0" + } + }, + "node_modules/npm/node_modules/libnpmhook": { + "version": "6.0.3", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "aproba": "^2.0.0", + "npm-registry-fetch": "^11.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/libnpmorg": { + "version": "2.0.3", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "aproba": "^2.0.0", + "npm-registry-fetch": "^11.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/libnpmpack": { + "version": "2.0.1", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "@npmcli/run-script": "^1.8.3", + "npm-package-arg": "^8.1.0", + "pacote": "^11.2.6" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/libnpmpublish": { + "version": "4.0.2", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "normalize-package-data": "^3.0.2", + "npm-package-arg": "^8.1.2", + "npm-registry-fetch": "^11.0.0", + "semver": "^7.1.3", + "ssri": "^8.0.1" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/libnpmsearch": { + "version": "3.1.2", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "npm-registry-fetch": "^11.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/libnpmteam": { + "version": "2.0.4", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "aproba": "^2.0.0", + "npm-registry-fetch": "^11.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/libnpmversion": { + "version": "1.2.1", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "@npmcli/git": "^2.0.7", + "@npmcli/run-script": "^1.8.4", + "json-parse-even-better-errors": "^2.3.1", + "semver": "^7.3.5", + "stringify-package": "^1.0.1" + } + }, + "node_modules/npm/node_modules/lru-cache": { + "version": "6.0.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/make-fetch-happen": { + "version": "9.1.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "agentkeepalive": "^4.1.3", + "cacache": "^15.2.0", + "http-cache-semantics": "^4.1.0", + "http-proxy-agent": "^4.0.1", + "https-proxy-agent": "^5.0.0", + "is-lambda": "^1.0.1", + "lru-cache": "^6.0.0", + "minipass": "^3.1.3", + "minipass-collect": "^1.0.2", + "minipass-fetch": "^1.3.2", + "minipass-flush": "^1.0.5", + "minipass-pipeline": "^1.2.4", + "negotiator": "^0.6.2", + "promise-retry": "^2.0.1", + "socks-proxy-agent": "^6.0.0", + "ssri": "^8.0.0" + }, + "engines": { + "node": ">= 10" + } + }, + "node_modules/npm/node_modules/mime-db": { + "version": "1.49.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/npm/node_modules/mime-types": { + "version": "2.1.32", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "mime-db": "1.49.0" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/npm/node_modules/minimatch": { + "version": "3.0.4", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/npm/node_modules/minipass": { + "version": "3.1.5", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/npm/node_modules/minipass-collect": { + "version": "1.0.2", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "minipass": "^3.0.0" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/npm/node_modules/minipass-fetch": { + "version": "1.4.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "minipass": "^3.1.0", + "minipass-sized": "^1.0.3", + "minizlib": "^2.0.0" + }, + "engines": { + "node": ">=8" + }, + "optionalDependencies": { + "encoding": "^0.1.12" + } + }, + "node_modules/npm/node_modules/minipass-flush": { + "version": "1.0.5", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "minipass": "^3.0.0" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/npm/node_modules/minipass-json-stream": { + "version": "1.0.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "jsonparse": "^1.3.1", + "minipass": "^3.0.0" + } + }, + "node_modules/npm/node_modules/minipass-pipeline": { + "version": "1.2.4", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "minipass": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/npm/node_modules/minipass-sized": { + "version": "1.0.3", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "minipass": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/npm/node_modules/minizlib": { + "version": "2.1.2", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "minipass": "^3.0.0", + "yallist": "^4.0.0" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/npm/node_modules/mkdirp": { + "version": "1.0.4", + "dev": true, + "inBundle": true, + "license": "MIT", + "bin": { + "mkdirp": "bin/cmd.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/mkdirp-infer-owner": { + "version": "2.0.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "chownr": "^2.0.0", + "infer-owner": "^1.0.4", + "mkdirp": "^1.0.3" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/ms": { + "version": "2.1.3", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/mute-stream": { + "version": "0.0.8", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/negotiator": { + "version": "0.6.2", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/npm/node_modules/node-gyp": { + "version": "7.1.2", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "env-paths": "^2.2.0", + "glob": "^7.1.4", + "graceful-fs": "^4.2.3", + "nopt": "^5.0.0", + "npmlog": "^4.1.2", + "request": "^2.88.2", + "rimraf": "^3.0.2", + "semver": "^7.3.2", + "tar": "^6.0.2", + "which": "^2.0.2" + }, + "bin": { + "node-gyp": "bin/node-gyp.js" + }, + "engines": { + "node": ">= 10.12.0" + } + }, + "node_modules/npm/node_modules/node-gyp/node_modules/aproba": { + "version": "1.2.0", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/node-gyp/node_modules/gauge": { + "version": "2.7.4", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "aproba": "^1.0.3", + "console-control-strings": "^1.0.0", + "has-unicode": "^2.0.0", + "object-assign": "^4.1.0", + "signal-exit": "^3.0.0", + "string-width": "^1.0.1", + "strip-ansi": "^3.0.1", + "wide-align": "^1.1.0" + } + }, + "node_modules/npm/node_modules/node-gyp/node_modules/is-fullwidth-code-point": { + "version": "1.0.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "number-is-nan": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/npm/node_modules/node-gyp/node_modules/npmlog": { + "version": "4.1.2", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "are-we-there-yet": "~1.1.2", + "console-control-strings": "~1.1.0", + "gauge": "~2.7.3", + "set-blocking": "~2.0.0" + } + }, + "node_modules/npm/node_modules/node-gyp/node_modules/string-width": { + "version": "1.0.2", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "code-point-at": "^1.0.0", + "is-fullwidth-code-point": "^1.0.0", + "strip-ansi": "^3.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/npm/node_modules/nopt": { + "version": "5.0.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "abbrev": "1" + }, + "bin": { + "nopt": "bin/nopt.js" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/npm/node_modules/normalize-package-data": { + "version": "3.0.3", + "dev": true, + "inBundle": true, + "license": "BSD-2-Clause", + "dependencies": { + "hosted-git-info": "^4.0.1", + "is-core-module": "^2.5.0", + "semver": "^7.3.4", + "validate-npm-package-license": "^3.0.1" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/npm-audit-report": { + "version": "2.1.5", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "chalk": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/npm-bundled": { + "version": "1.1.2", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "npm-normalize-package-bin": "^1.0.1" + } + }, + "node_modules/npm/node_modules/npm-install-checks": { + "version": "4.0.0", + "dev": true, + "inBundle": true, + "license": "BSD-2-Clause", + "dependencies": { + "semver": "^7.1.1" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/npm-normalize-package-bin": { + "version": "1.0.1", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/npm-package-arg": { + "version": "8.1.5", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "hosted-git-info": "^4.0.1", + "semver": "^7.3.4", + "validate-npm-package-name": "^3.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/npm-packlist": { + "version": "2.2.2", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "glob": "^7.1.6", + "ignore-walk": "^3.0.3", + "npm-bundled": "^1.1.1", + "npm-normalize-package-bin": "^1.0.1" + }, + "bin": { + "npm-packlist": "bin/index.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/npm-pick-manifest": { + "version": "6.1.1", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "npm-install-checks": "^4.0.0", + "npm-normalize-package-bin": "^1.0.1", + "npm-package-arg": "^8.1.2", + "semver": "^7.3.4" + } + }, + "node_modules/npm/node_modules/npm-profile": { + "version": "5.0.4", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "npm-registry-fetch": "^11.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/npm-registry-fetch": { + "version": "11.0.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "make-fetch-happen": "^9.0.1", + "minipass": "^3.1.3", + "minipass-fetch": "^1.3.0", + "minipass-json-stream": "^1.0.1", + "minizlib": "^2.0.0", + "npm-package-arg": "^8.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/npm-user-validate": { + "version": "1.0.1", + "dev": true, + "inBundle": true, + "license": "BSD-2-Clause" + }, + "node_modules/npm/node_modules/npmlog": { + "version": "5.0.1", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "are-we-there-yet": "^2.0.0", + "console-control-strings": "^1.1.0", + "gauge": "^3.0.0", + "set-blocking": "^2.0.0" + } + }, + "node_modules/npm/node_modules/npmlog/node_modules/are-we-there-yet": { + "version": "2.0.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "delegates": "^1.0.0", + "readable-stream": "^3.6.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/number-is-nan": { + "version": "1.0.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/npm/node_modules/oauth-sign": { + "version": "0.9.0", + "dev": true, + "inBundle": true, + "license": "Apache-2.0", + "engines": { + "node": "*" + } + }, + "node_modules/npm/node_modules/object-assign": { + "version": "4.1.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/npm/node_modules/once": { + "version": "1.4.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "wrappy": "1" + } + }, + "node_modules/npm/node_modules/opener": { + "version": "1.5.2", + "dev": true, + "inBundle": true, + "license": "(WTFPL OR MIT)", + "bin": { + "opener": "bin/opener-bin.js" + } + }, + "node_modules/npm/node_modules/p-map": { + "version": "4.0.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "aggregate-error": "^3.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/npm/node_modules/pacote": { + "version": "11.3.5", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "@npmcli/git": "^2.1.0", + "@npmcli/installed-package-contents": "^1.0.6", + "@npmcli/promise-spawn": "^1.2.0", + "@npmcli/run-script": "^1.8.2", + "cacache": "^15.0.5", + "chownr": "^2.0.0", + "fs-minipass": "^2.1.0", + "infer-owner": "^1.0.4", + "minipass": "^3.1.3", + "mkdirp": "^1.0.3", + "npm-package-arg": "^8.0.1", + "npm-packlist": "^2.1.4", + "npm-pick-manifest": "^6.0.0", + "npm-registry-fetch": "^11.0.0", + "promise-retry": "^2.0.1", + "read-package-json-fast": "^2.0.1", + "rimraf": "^3.0.2", + "ssri": "^8.0.1", + "tar": "^6.1.0" + }, + "bin": { + "pacote": "lib/bin.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/parse-conflict-json": { + "version": "1.1.1", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "json-parse-even-better-errors": "^2.3.0", + "just-diff": "^3.0.1", + "just-diff-apply": "^3.0.0" + } + }, + "node_modules/npm/node_modules/path-is-absolute": { + "version": "1.0.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/npm/node_modules/performance-now": { + "version": "2.1.0", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/proc-log": { + "version": "1.0.0", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/promise-all-reject-late": { + "version": "1.0.1", + "dev": true, + "inBundle": true, + "license": "ISC", + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/npm/node_modules/promise-call-limit": { + "version": "1.0.1", + "dev": true, + "inBundle": true, + "license": "ISC", + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/npm/node_modules/promise-inflight": { + "version": "1.0.1", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/promise-retry": { + "version": "2.0.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "err-code": "^2.0.2", + "retry": "^0.12.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/promzard": { + "version": "0.3.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "read": "1" + } + }, + "node_modules/npm/node_modules/psl": { + "version": "1.8.0", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/punycode": { + "version": "2.1.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/npm/node_modules/qrcode-terminal": { + "version": "0.12.0", + "dev": true, + "inBundle": true, + "bin": { + "qrcode-terminal": "bin/qrcode-terminal.js" + } + }, + "node_modules/npm/node_modules/qs": { + "version": "6.5.2", + "dev": true, + "inBundle": true, + "license": "BSD-3-Clause", + "engines": { + "node": ">=0.6" + } + }, + "node_modules/npm/node_modules/read": { + "version": "1.0.7", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "mute-stream": "~0.0.4" + }, + "engines": { + "node": ">=0.8" + } + }, + "node_modules/npm/node_modules/read-cmd-shim": { + "version": "2.0.0", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/read-package-json": { + "version": "4.1.1", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "glob": "^7.1.1", + "json-parse-even-better-errors": "^2.3.0", + "normalize-package-data": "^3.0.0", + "npm-normalize-package-bin": "^1.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/read-package-json-fast": { + "version": "2.0.3", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "json-parse-even-better-errors": "^2.3.0", + "npm-normalize-package-bin": "^1.0.1" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/readable-stream": { + "version": "3.6.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/npm/node_modules/readdir-scoped-modules": { + "version": "1.1.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "debuglog": "^1.0.1", + "dezalgo": "^1.0.0", + "graceful-fs": "^4.1.2", + "once": "^1.3.0" + } + }, + "node_modules/npm/node_modules/request": { + "version": "2.88.2", + "dev": true, + "inBundle": true, + "license": "Apache-2.0", + "dependencies": { + "aws-sign2": "~0.7.0", + "aws4": "^1.8.0", + "caseless": "~0.12.0", + "combined-stream": "~1.0.6", + "extend": "~3.0.2", + "forever-agent": "~0.6.1", + "form-data": "~2.3.2", + "har-validator": "~5.1.3", + "http-signature": "~1.2.0", + "is-typedarray": "~1.0.0", + "isstream": "~0.1.2", + "json-stringify-safe": "~5.0.1", + "mime-types": "~2.1.19", + "oauth-sign": "~0.9.0", + "performance-now": "^2.1.0", + "qs": "~6.5.2", + "safe-buffer": "^5.1.2", + "tough-cookie": "~2.5.0", + "tunnel-agent": "^0.6.0", + "uuid": "^3.3.2" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/npm/node_modules/request/node_modules/form-data": { + "version": "2.3.3", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "asynckit": "^0.4.0", + "combined-stream": "^1.0.6", + "mime-types": "^2.1.12" + }, + "engines": { + "node": ">= 0.12" + } + }, + "node_modules/npm/node_modules/request/node_modules/tough-cookie": { + "version": "2.5.0", + "dev": true, + "inBundle": true, + "license": "BSD-3-Clause", + "dependencies": { + "psl": "^1.1.28", + "punycode": "^2.1.1" + }, + "engines": { + "node": ">=0.8" + } + }, + "node_modules/npm/node_modules/retry": { + "version": "0.12.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">= 4" + } + }, + "node_modules/npm/node_modules/rimraf": { + "version": "3.0.2", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "glob": "^7.1.3" + }, + "bin": { + "rimraf": "bin.js" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/npm/node_modules/safe-buffer": { + "version": "5.2.1", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/safer-buffer": { + "version": "2.1.2", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/semver": { + "version": "7.3.5", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/npm/node_modules/set-blocking": { + "version": "2.0.0", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/signal-exit": { + "version": "3.0.3", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/smart-buffer": { + "version": "4.2.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">= 6.0.0", + "npm": ">= 3.0.0" + } + }, + "node_modules/npm/node_modules/socks": { + "version": "2.6.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "ip": "^1.1.5", + "smart-buffer": "^4.1.0" + }, + "engines": { + "node": ">= 10.13.0", + "npm": ">= 3.0.0" + } + }, + "node_modules/npm/node_modules/socks-proxy-agent": { + "version": "6.1.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "agent-base": "^6.0.2", + "debug": "^4.3.1", + "socks": "^2.6.1" + }, + "engines": { + "node": ">= 10" + } + }, + "node_modules/npm/node_modules/spdx-correct": { + "version": "3.1.1", + "dev": true, + "inBundle": true, + "license": "Apache-2.0", + "dependencies": { + "spdx-expression-parse": "^3.0.0", + "spdx-license-ids": "^3.0.0" + } + }, + "node_modules/npm/node_modules/spdx-exceptions": { + "version": "2.3.0", + "dev": true, + "inBundle": true, + "license": "CC-BY-3.0" + }, + "node_modules/npm/node_modules/spdx-expression-parse": { + "version": "3.0.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "spdx-exceptions": "^2.1.0", + "spdx-license-ids": "^3.0.0" + } + }, + "node_modules/npm/node_modules/spdx-license-ids": { + "version": "3.0.10", + "dev": true, + "inBundle": true, + "license": "CC0-1.0" + }, + "node_modules/npm/node_modules/sshpk": { + "version": "1.16.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "asn1": "~0.2.3", + "assert-plus": "^1.0.0", + "bcrypt-pbkdf": "^1.0.0", + "dashdash": "^1.12.0", + "ecc-jsbn": "~0.1.1", + "getpass": "^0.1.1", + "jsbn": "~0.1.0", + "safer-buffer": "^2.0.2", + "tweetnacl": "~0.14.0" + }, + "bin": { + "sshpk-conv": "bin/sshpk-conv", + "sshpk-sign": "bin/sshpk-sign", + "sshpk-verify": "bin/sshpk-verify" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/npm/node_modules/ssri": { + "version": "8.0.1", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "minipass": "^3.1.1" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/npm/node_modules/string_decoder": { + "version": "1.3.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "safe-buffer": "~5.2.0" + } + }, + "node_modules/npm/node_modules/string-width": { + "version": "2.1.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^4.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/npm/node_modules/string-width/node_modules/ansi-regex": { + "version": "3.0.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/npm/node_modules/string-width/node_modules/strip-ansi": { + "version": "4.0.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "ansi-regex": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/npm/node_modules/stringify-package": { + "version": "1.0.1", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/strip-ansi": { + "version": "3.0.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "ansi-regex": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/npm/node_modules/supports-color": { + "version": "7.2.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/npm/node_modules/tar": { + "version": "6.1.11", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "chownr": "^2.0.0", + "fs-minipass": "^2.0.0", + "minipass": "^3.0.0", + "minizlib": "^2.1.1", + "mkdirp": "^1.0.3", + "yallist": "^4.0.0" + }, + "engines": { + "node": ">= 10" + } + }, + "node_modules/npm/node_modules/text-table": { + "version": "0.2.0", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/tiny-relative-date": { + "version": "1.3.0", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/treeverse": { + "version": "1.0.4", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/tunnel-agent": { + "version": "0.6.0", + "dev": true, + "inBundle": true, + "license": "Apache-2.0", + "dependencies": { + "safe-buffer": "^5.0.1" + }, + "engines": { + "node": "*" + } + }, + "node_modules/npm/node_modules/tweetnacl": { + "version": "0.14.5", + "dev": true, + "inBundle": true, + "license": "Unlicense" + }, + "node_modules/npm/node_modules/typedarray-to-buffer": { + "version": "3.1.5", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "is-typedarray": "^1.0.0" + } + }, + "node_modules/npm/node_modules/unique-filename": { + "version": "1.1.1", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "unique-slug": "^2.0.0" + } + }, + "node_modules/npm/node_modules/unique-slug": { + "version": "2.0.2", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "imurmurhash": "^0.1.4" + } + }, + "node_modules/npm/node_modules/uri-js": { + "version": "4.4.1", + "dev": true, + "inBundle": true, + "license": "BSD-2-Clause", + "dependencies": { + "punycode": "^2.1.0" + } + }, + "node_modules/npm/node_modules/util-deprecate": { + "version": "1.0.2", + "dev": true, + "inBundle": true, + "license": "MIT" + }, + "node_modules/npm/node_modules/uuid": { + "version": "3.4.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "bin": { + "uuid": "bin/uuid" + } + }, + "node_modules/npm/node_modules/validate-npm-package-license": { + "version": "3.0.4", + "dev": true, + "inBundle": true, + "license": "Apache-2.0", + "dependencies": { + "spdx-correct": "^3.0.0", + "spdx-expression-parse": "^3.0.0" + } + }, + "node_modules/npm/node_modules/validate-npm-package-name": { + "version": "3.0.0", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "builtins": "^1.0.3" + } + }, + "node_modules/npm/node_modules/verror": { + "version": "1.10.0", + "dev": true, + "engines": [ + "node >=0.6.0" + ], + "inBundle": true, + "license": "MIT", + "dependencies": { + "assert-plus": "^1.0.0", + "core-util-is": "1.0.2", + "extsprintf": "^1.2.0" + } + }, + "node_modules/npm/node_modules/walk-up-path": { + "version": "1.0.0", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/wcwidth": { + "version": "1.0.1", + "dev": true, + "inBundle": true, + "license": "MIT", + "dependencies": { + "defaults": "^1.0.3" + } + }, + "node_modules/npm/node_modules/which": { + "version": "2.0.2", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "isexe": "^2.0.0" + }, + "bin": { + "node-which": "bin/node-which" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/npm/node_modules/wide-align": { + "version": "1.1.3", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "string-width": "^1.0.2 || 2" + } + }, + "node_modules/npm/node_modules/wrappy": { + "version": "1.0.2", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/npm/node_modules/write-file-atomic": { + "version": "3.0.3", + "dev": true, + "inBundle": true, + "license": "ISC", + "dependencies": { + "imurmurhash": "^0.1.4", + "is-typedarray": "^1.0.0", + "signal-exit": "^3.0.2", + "typedarray-to-buffer": "^3.1.5" + } + }, + "node_modules/npm/node_modules/yallist": { + "version": "4.0.0", + "dev": true, + "inBundle": true, + "license": "ISC" + }, + "node_modules/nth-check": { + "version": "1.0.2", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "boolbase": "~1.0.0" + } + }, + "node_modules/number-is-nan": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/nwsapi": { + "version": "2.2.20", + "dev": true, + "license": "MIT" + }, + "node_modules/object-assign": { + "version": "4.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/object-copy": { + "version": "0.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "copy-descriptor": "^0.1.0", + "define-property": "^0.2.5", + "kind-of": "^3.0.3" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/object-copy/node_modules/define-property": { + "version": "0.2.5", + "dev": true, + "license": "MIT", + "dependencies": { + "is-descriptor": "^0.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/object-copy/node_modules/define-property/node_modules/is-descriptor": { + "version": "0.1.7", + "dev": true, + "license": "MIT", + "dependencies": { + "is-accessor-descriptor": "^1.0.1", + "is-data-descriptor": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/object-copy/node_modules/kind-of": { + "version": "3.2.2", + "dev": true, + "license": "MIT", + "dependencies": { + "is-buffer": "^1.1.5" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/object-inspect": { + "version": "1.13.4", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/object-keys": { + "version": "1.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/object-visit": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "isobject": "^3.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/object.assign": { + "version": "4.1.7", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.8", + "call-bound": "^1.0.3", + "define-properties": "^1.2.1", + "es-object-atoms": "^1.0.0", + "has-symbols": "^1.1.0", + "object-keys": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/object.fromentries": { + "version": "2.0.8", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.7", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.2", + "es-object-atoms": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/object.getownpropertydescriptors": { + "version": "2.1.8", + "dev": true, + "license": "MIT", + "dependencies": { + "array.prototype.reduce": "^1.0.6", + "call-bind": "^1.0.7", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.2", + "es-object-atoms": "^1.0.0", + "gopd": "^1.0.1", + "safe-array-concat": "^1.1.2" + }, + "engines": { + "node": ">= 0.8" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/object.groupby": { + "version": "1.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.7", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/object.pick": { + "version": "1.3.0", + "dev": true, + "license": "MIT", + "dependencies": { + "isobject": "^3.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/object.values": { + "version": "1.2.1", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.8", + "call-bound": "^1.0.3", + "define-properties": "^1.2.1", + "es-object-atoms": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/once": { + "version": "1.4.0", + "license": "ISC", + "dependencies": { + "wrappy": "1" + } + }, + "node_modules/onetime": { + "version": "5.1.2", + "dev": true, + "license": "MIT", + "dependencies": { + "mimic-fn": "^2.1.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/opencollective-postinstall": { + "version": "2.0.3", + "dev": true, + "license": "MIT", + "bin": { + "opencollective-postinstall": "index.js" + } + }, + "node_modules/optionator": { + "version": "0.9.4", + "dev": true, + "license": "MIT", + "dependencies": { + "deep-is": "^0.1.3", + "fast-levenshtein": "^2.0.6", + "levn": "^0.4.1", + "prelude-ls": "^1.2.1", + "type-check": "^0.4.0", + "word-wrap": "^1.2.5" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/own-keys": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "get-intrinsic": "^1.2.6", + "object-keys": "^1.1.1", + "safe-push-apply": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/p-each-series": { + "version": "2.2.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-filter": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "p-map": "^2.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/p-filter/node_modules/p-map": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/p-finally": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/p-is-promise": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/p-limit": { + "version": "2.3.0", + "dev": true, + "license": "MIT", + "dependencies": { + "p-try": "^2.0.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-locate": { + "version": "4.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "p-limit": "^2.2.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/p-map": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "aggregate-error": "^3.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-queue": { + "version": "6.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "eventemitter3": "^4.0.4", + "p-timeout": "^3.2.0" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-reduce": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/p-retry": { + "version": "4.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/retry": "0.12.0", + "retry": "^0.13.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/p-timeout": { + "version": "3.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "p-finally": "^1.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/p-try": { + "version": "2.2.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/parent-module": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "callsites": "^3.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/parse-json": { + "version": "5.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.0.0", + "error-ex": "^1.3.1", + "json-parse-even-better-errors": "^2.3.0", + "lines-and-columns": "^1.1.6" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/parse5": { + "version": "6.0.1", + "dev": true, + "license": "MIT" + }, + "node_modules/pascalcase": { + "version": "0.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/path-exists": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/path-is-absolute": { + "version": "1.0.1", + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/path-key": { + "version": "3.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/path-parse": { + "version": "1.0.7", + "license": "MIT" + }, + "node_modules/path-type": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/picocolors": { + "version": "1.1.1", + "license": "ISC" + }, + "node_modules/picomatch": { + "version": "2.3.1", + "license": "MIT", + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/pify": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/pirates": { + "version": "4.0.7", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 6" + } + }, + "node_modules/pkg-conf": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "find-up": "^2.0.0", + "load-json-file": "^4.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/pkg-conf/node_modules/find-up": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "locate-path": "^2.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/pkg-conf/node_modules/find-up/node_modules/locate-path": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "p-locate": "^2.0.0", + "path-exists": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/pkg-conf/node_modules/find-up/node_modules/locate-path/node_modules/p-locate": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "p-limit": "^1.1.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/pkg-conf/node_modules/find-up/node_modules/locate-path/node_modules/p-locate/node_modules/p-limit": { + "version": "1.3.0", + "dev": true, + "license": "MIT", + "dependencies": { + "p-try": "^1.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/pkg-conf/node_modules/find-up/node_modules/locate-path/node_modules/p-locate/node_modules/p-limit/node_modules/p-try": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/pkg-conf/node_modules/find-up/node_modules/locate-path/node_modules/path-exists": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/pkg-dir": { + "version": "5.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "find-up": "^5.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/pkg-dir/node_modules/find-up": { + "version": "5.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "locate-path": "^6.0.0", + "path-exists": "^4.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/pkg-dir/node_modules/find-up/node_modules/locate-path": { + "version": "6.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "p-locate": "^5.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/pkg-dir/node_modules/find-up/node_modules/locate-path/node_modules/p-locate": { + "version": "5.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "p-limit": "^3.0.2" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/pkg-dir/node_modules/find-up/node_modules/locate-path/node_modules/p-locate/node_modules/p-limit": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "yocto-queue": "^0.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/please-upgrade-node": { + "version": "3.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "semver-compare": "^1.0.0" + } + }, + "node_modules/pluralize": { + "version": "8.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/posix-character-classes": { + "version": "0.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/possible-typed-array-names": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/postcss": { + "version": "8.5.3", + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "dependencies": { + "nanoid": "^3.3.8", + "picocolors": "^1.1.1", + "source-map-js": "^1.2.1" + }, + "engines": { + "node": "^10 || ^12 || >=14" + } + }, + "node_modules/postcss-calc": { + "version": "7.0.5", + "dev": true, + "license": "MIT", + "dependencies": { + "postcss": "^7.0.27", + "postcss-selector-parser": "^6.0.2", + "postcss-value-parser": "^4.0.2" + } + }, + "node_modules/postcss-calc/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-calc/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-color-converter": { + "version": "1.1.2", + "license": "MIT", + "dependencies": { + "color-convert": "~2.0.1", + "color-name": "~1.1.4", + "postcss-values-parser": "^5.0.0" + }, + "engines": { + "node": ">=8.3.0" + }, + "peerDependencies": { + "postcss": "^8.0.0" + } + }, + "node_modules/postcss-colormin": { + "version": "4.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "browserslist": "^4.0.0", + "color": "^3.0.0", + "has": "^1.0.0", + "postcss": "^7.0.0", + "postcss-value-parser": "^3.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-colormin/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-colormin/node_modules/postcss-value-parser": { + "version": "3.3.1", + "dev": true, + "license": "MIT" + }, + "node_modules/postcss-colormin/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-convert-values": { + "version": "4.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "postcss": "^7.0.0", + "postcss-value-parser": "^3.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-convert-values/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-convert-values/node_modules/postcss-value-parser": { + "version": "3.3.1", + "dev": true, + "license": "MIT" + }, + "node_modules/postcss-convert-values/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-discard-comments": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "postcss": "^7.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-discard-comments/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-discard-comments/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-discard-duplicates": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "postcss": "^7.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-discard-duplicates/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-discard-duplicates/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-discard-empty": { + "version": "4.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "postcss": "^7.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-discard-empty/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-discard-empty/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-discard-overridden": { + "version": "4.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "postcss": "^7.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-discard-overridden/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-discard-overridden/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-merge-longhand": { + "version": "4.0.11", + "dev": true, + "license": "MIT", + "dependencies": { + "css-color-names": "0.0.4", + "postcss": "^7.0.0", + "postcss-value-parser": "^3.0.0", + "stylehacks": "^4.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-merge-longhand/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-merge-longhand/node_modules/postcss-value-parser": { + "version": "3.3.1", + "dev": true, + "license": "MIT" + }, + "node_modules/postcss-merge-longhand/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-merge-rules": { + "version": "4.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "browserslist": "^4.0.0", + "caniuse-api": "^3.0.0", + "cssnano-util-same-parent": "^4.0.0", + "postcss": "^7.0.0", + "postcss-selector-parser": "^3.0.0", + "vendors": "^1.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-merge-rules/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-merge-rules/node_modules/postcss-selector-parser": { + "version": "3.1.2", + "dev": true, + "license": "MIT", + "dependencies": { + "dot-prop": "^5.2.0", + "indexes-of": "^1.0.1", + "uniq": "^1.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/postcss-merge-rules/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-minify-font-values": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "postcss": "^7.0.0", + "postcss-value-parser": "^3.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-minify-font-values/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-minify-font-values/node_modules/postcss-value-parser": { + "version": "3.3.1", + "dev": true, + "license": "MIT" + }, + "node_modules/postcss-minify-font-values/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-minify-gradients": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "cssnano-util-get-arguments": "^4.0.0", + "is-color-stop": "^1.0.0", + "postcss": "^7.0.0", + "postcss-value-parser": "^3.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-minify-gradients/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-minify-gradients/node_modules/postcss-value-parser": { + "version": "3.3.1", + "dev": true, + "license": "MIT" + }, + "node_modules/postcss-minify-gradients/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-minify-params": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "alphanum-sort": "^1.0.0", + "browserslist": "^4.0.0", + "cssnano-util-get-arguments": "^4.0.0", + "postcss": "^7.0.0", + "postcss-value-parser": "^3.0.0", + "uniqs": "^2.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-minify-params/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-minify-params/node_modules/postcss-value-parser": { + "version": "3.3.1", + "dev": true, + "license": "MIT" + }, + "node_modules/postcss-minify-params/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-minify-selectors": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "alphanum-sort": "^1.0.0", + "has": "^1.0.0", + "postcss": "^7.0.0", + "postcss-selector-parser": "^3.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-minify-selectors/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-minify-selectors/node_modules/postcss-selector-parser": { + "version": "3.1.2", + "dev": true, + "license": "MIT", + "dependencies": { + "dot-prop": "^5.2.0", + "indexes-of": "^1.0.1", + "uniq": "^1.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/postcss-minify-selectors/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-modules": { + "version": "4.3.1", + "dev": true, + "license": "MIT", + "dependencies": { + "generic-names": "^4.0.0", + "icss-replace-symbols": "^1.1.0", + "lodash.camelcase": "^4.3.0", + "postcss-modules-extract-imports": "^3.0.0", + "postcss-modules-local-by-default": "^4.0.0", + "postcss-modules-scope": "^3.0.0", + "postcss-modules-values": "^4.0.0", + "string-hash": "^1.1.1" + }, + "peerDependencies": { + "postcss": "^8.0.0" + } + }, + "node_modules/postcss-modules-extract-imports": { + "version": "3.1.0", + "dev": true, + "license": "ISC", + "engines": { + "node": "^10 || ^12 || >= 14" + }, + "peerDependencies": { + "postcss": "^8.1.0" + } + }, + "node_modules/postcss-modules-local-by-default": { + "version": "4.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "icss-utils": "^5.0.0", + "postcss-selector-parser": "^7.0.0", + "postcss-value-parser": "^4.1.0" + }, + "engines": { + "node": "^10 || ^12 || >= 14" + }, + "peerDependencies": { + "postcss": "^8.1.0" + } + }, + "node_modules/postcss-modules-local-by-default/node_modules/postcss-selector-parser": { + "version": "7.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "cssesc": "^3.0.0", + "util-deprecate": "^1.0.2" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/postcss-modules-scope": { + "version": "3.2.1", + "dev": true, + "license": "ISC", + "dependencies": { + "postcss-selector-parser": "^7.0.0" + }, + "engines": { + "node": "^10 || ^12 || >= 14" + }, + "peerDependencies": { + "postcss": "^8.1.0" + } + }, + "node_modules/postcss-modules-scope/node_modules/postcss-selector-parser": { + "version": "7.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "cssesc": "^3.0.0", + "util-deprecate": "^1.0.2" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/postcss-modules-values": { + "version": "4.0.0", + "dev": true, + "license": "ISC", + "dependencies": { + "icss-utils": "^5.0.0" + }, + "engines": { + "node": "^10 || ^12 || >= 14" + }, + "peerDependencies": { + "postcss": "^8.1.0" + } + }, + "node_modules/postcss-normalize-charset": { + "version": "4.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "postcss": "^7.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-normalize-charset/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-normalize-charset/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-normalize-display-values": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "cssnano-util-get-match": "^4.0.0", + "postcss": "^7.0.0", + "postcss-value-parser": "^3.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-normalize-display-values/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-normalize-display-values/node_modules/postcss-value-parser": { + "version": "3.3.1", + "dev": true, + "license": "MIT" + }, + "node_modules/postcss-normalize-display-values/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-normalize-positions": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "cssnano-util-get-arguments": "^4.0.0", + "has": "^1.0.0", + "postcss": "^7.0.0", + "postcss-value-parser": "^3.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-normalize-positions/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-normalize-positions/node_modules/postcss-value-parser": { + "version": "3.3.1", + "dev": true, + "license": "MIT" + }, + "node_modules/postcss-normalize-positions/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-normalize-repeat-style": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "cssnano-util-get-arguments": "^4.0.0", + "cssnano-util-get-match": "^4.0.0", + "postcss": "^7.0.0", + "postcss-value-parser": "^3.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-normalize-repeat-style/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-normalize-repeat-style/node_modules/postcss-value-parser": { + "version": "3.3.1", + "dev": true, + "license": "MIT" + }, + "node_modules/postcss-normalize-repeat-style/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-normalize-string": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "has": "^1.0.0", + "postcss": "^7.0.0", + "postcss-value-parser": "^3.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-normalize-string/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-normalize-string/node_modules/postcss-value-parser": { + "version": "3.3.1", + "dev": true, + "license": "MIT" + }, + "node_modules/postcss-normalize-string/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-normalize-timing-functions": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "cssnano-util-get-match": "^4.0.0", + "postcss": "^7.0.0", + "postcss-value-parser": "^3.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-normalize-timing-functions/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-normalize-timing-functions/node_modules/postcss-value-parser": { + "version": "3.3.1", + "dev": true, + "license": "MIT" + }, + "node_modules/postcss-normalize-timing-functions/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-normalize-unicode": { + "version": "4.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "browserslist": "^4.0.0", + "postcss": "^7.0.0", + "postcss-value-parser": "^3.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-normalize-unicode/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-normalize-unicode/node_modules/postcss-value-parser": { + "version": "3.3.1", + "dev": true, + "license": "MIT" + }, + "node_modules/postcss-normalize-unicode/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-normalize-url": { + "version": "4.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "is-absolute-url": "^2.0.0", + "normalize-url": "^3.0.0", + "postcss": "^7.0.0", + "postcss-value-parser": "^3.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-normalize-url/node_modules/normalize-url": { + "version": "3.3.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/postcss-normalize-url/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-normalize-url/node_modules/postcss-value-parser": { + "version": "3.3.1", + "dev": true, + "license": "MIT" + }, + "node_modules/postcss-normalize-url/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-normalize-whitespace": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "postcss": "^7.0.0", + "postcss-value-parser": "^3.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-normalize-whitespace/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-normalize-whitespace/node_modules/postcss-value-parser": { + "version": "3.3.1", + "dev": true, + "license": "MIT" + }, + "node_modules/postcss-normalize-whitespace/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-ordered-values": { + "version": "4.1.2", + "dev": true, + "license": "MIT", + "dependencies": { + "cssnano-util-get-arguments": "^4.0.0", + "postcss": "^7.0.0", + "postcss-value-parser": "^3.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-ordered-values/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-ordered-values/node_modules/postcss-value-parser": { + "version": "3.3.1", + "dev": true, + "license": "MIT" + }, + "node_modules/postcss-ordered-values/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-reduce-initial": { + "version": "4.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "browserslist": "^4.0.0", + "caniuse-api": "^3.0.0", + "has": "^1.0.0", + "postcss": "^7.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-reduce-initial/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-reduce-initial/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-reduce-transforms": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "cssnano-util-get-match": "^4.0.0", + "has": "^1.0.0", + "postcss": "^7.0.0", + "postcss-value-parser": "^3.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-reduce-transforms/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-reduce-transforms/node_modules/postcss-value-parser": { + "version": "3.3.1", + "dev": true, + "license": "MIT" + }, + "node_modules/postcss-reduce-transforms/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-selector-parser": { + "version": "6.1.2", + "license": "MIT", + "dependencies": { + "cssesc": "^3.0.0", + "util-deprecate": "^1.0.2" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/postcss-svgo": { + "version": "4.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "postcss": "^7.0.0", + "postcss-value-parser": "^3.0.0", + "svgo": "^1.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-svgo/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-svgo/node_modules/postcss-value-parser": { + "version": "3.3.1", + "dev": true, + "license": "MIT" + }, + "node_modules/postcss-svgo/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-unique-selectors": { + "version": "4.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "alphanum-sort": "^1.0.0", + "postcss": "^7.0.0", + "uniqs": "^2.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/postcss-unique-selectors/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/postcss-unique-selectors/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss-value-parser": { + "version": "4.2.0", + "dev": true, + "license": "MIT" + }, + "node_modules/postcss-values-parser": { + "version": "5.0.0", + "license": "MPL-2.0", + "dependencies": { + "color-name": "^1.1.4", + "is-url-superb": "^4.0.0", + "quote-unquote": "^1.0.0" + }, + "engines": { + "node": ">=10" + }, + "peerDependencies": { + "postcss": "^8.0.9" + } + }, + "node_modules/prelude-ls": { + "version": "1.2.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/prettier": { + "version": "2.8.8", + "dev": true, + "license": "MIT", + "bin": { + "prettier": "bin-prettier.js" + }, + "engines": { + "node": ">=10.13.0" + }, + "funding": { + "url": "https://github.com/prettier/prettier?sponsor=1" + } + }, + "node_modules/pretty-format": { + "version": "26.6.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@jest/types": "^26.6.2", + "ansi-regex": "^5.0.0", + "ansi-styles": "^4.0.0", + "react-is": "^17.0.1" + }, + "engines": { + "node": ">= 10" + } + }, + "node_modules/process-nextick-args": { + "version": "2.0.1", + "dev": true, + "license": "MIT" + }, + "node_modules/progress": { + "version": "2.0.3", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/prompts": { + "version": "2.4.2", + "dev": true, + "license": "MIT", + "dependencies": { + "kleur": "^3.0.3", + "sisteransi": "^1.0.5" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/psl": { + "version": "1.15.0", + "dev": true, + "license": "MIT", + "dependencies": { + "punycode": "^2.3.1" + }, + "funding": { + "url": "https://github.com/sponsors/lupomontero" + } + }, + "node_modules/pump": { + "version": "3.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "end-of-stream": "^1.1.0", + "once": "^1.3.1" + } + }, + "node_modules/punycode": { + "version": "2.3.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/purgecss": { + "version": "3.1.3", + "license": "MIT", + "dependencies": { + "commander": "^6.0.0", + "glob": "^7.0.0", + "postcss": "^8.2.1", + "postcss-selector-parser": "^6.0.2" + }, + "bin": { + "purgecss": "bin/purgecss.js" + } + }, + "node_modules/q": { + "version": "1.5.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.6.0", + "teleport": ">=0.2.0" + } + }, + "node_modules/query-string": { + "version": "6.14.1", + "license": "MIT", + "dependencies": { + "decode-uri-component": "^0.2.0", + "filter-obj": "^1.1.0", + "split-on-first": "^1.0.0", + "strict-uri-encode": "^2.0.0" + }, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/querystringify": { + "version": "2.2.0", + "dev": true, + "license": "MIT" + }, + "node_modules/queue-microtask": { + "version": "1.2.3", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT" + }, + "node_modules/quick-lru": { + "version": "4.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/quote-unquote": { + "version": "1.0.0", + "license": "MIT" + }, + "node_modules/rc": { + "version": "1.2.8", + "dev": true, + "license": "(BSD-2-Clause OR MIT OR Apache-2.0)", + "dependencies": { + "deep-extend": "^0.6.0", + "ini": "~1.3.0", + "minimist": "^1.2.0", + "strip-json-comments": "~2.0.1" + }, + "bin": { + "rc": "cli.js" + } + }, + "node_modules/rc/node_modules/strip-json-comments": { + "version": "2.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/react-is": { + "version": "17.0.2", + "dev": true, + "license": "MIT" + }, + "node_modules/read-pkg": { + "version": "5.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/normalize-package-data": "^2.4.0", + "normalize-package-data": "^2.5.0", + "parse-json": "^5.0.0", + "type-fest": "^0.6.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/read-pkg-up": { + "version": "7.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "find-up": "^4.1.0", + "read-pkg": "^5.2.0", + "type-fest": "^0.8.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/read-pkg-up/node_modules/type-fest": { + "version": "0.8.1", + "dev": true, + "license": "(MIT OR CC0-1.0)", + "engines": { + "node": ">=8" + } + }, + "node_modules/read-pkg/node_modules/type-fest": { + "version": "0.6.0", + "dev": true, + "license": "(MIT OR CC0-1.0)", + "engines": { + "node": ">=8" + } + }, + "node_modules/readable-stream": { + "version": "2.3.8", + "dev": true, + "license": "MIT", + "dependencies": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "node_modules/readable-stream/node_modules/isarray": { + "version": "1.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/readline2": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "code-point-at": "^1.0.0", + "is-fullwidth-code-point": "^1.0.0", + "mute-stream": "0.0.5" + } + }, + "node_modules/readline2/node_modules/is-fullwidth-code-point": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "number-is-nan": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/rechoir": { + "version": "0.6.2", + "dev": true, + "dependencies": { + "resolve": "^1.1.6" + }, + "engines": { + "node": ">= 0.10" + } + }, + "node_modules/redent": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "indent-string": "^4.0.0", + "strip-indent": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/redeyed": { + "version": "2.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "esprima": "~4.0.0" + } + }, + "node_modules/reflect.getprototypeof": { + "version": "1.0.10", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.8", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.9", + "es-errors": "^1.3.0", + "es-object-atoms": "^1.0.0", + "get-intrinsic": "^1.2.7", + "get-proto": "^1.0.1", + "which-builtin-type": "^1.2.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/regenerate": { + "version": "1.4.2", + "dev": true, + "license": "MIT" + }, + "node_modules/regenerate-unicode-properties": { + "version": "10.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "regenerate": "^1.4.2" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/regenerator-runtime": { + "version": "0.14.1", + "dev": true, + "license": "MIT" + }, + "node_modules/regenerator-transform": { + "version": "0.15.2", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/runtime": "^7.8.4" + } + }, + "node_modules/regex-not": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "extend-shallow": "^3.0.2", + "safe-regex": "^1.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/regex-not/node_modules/safe-regex": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "ret": "~0.1.10" + } + }, + "node_modules/regexp-tree": { + "version": "0.1.27", + "dev": true, + "license": "MIT", + "bin": { + "regexp-tree": "bin/regexp-tree" + } + }, + "node_modules/regexp.prototype.flags": { + "version": "1.5.4", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.8", + "define-properties": "^1.2.1", + "es-errors": "^1.3.0", + "get-proto": "^1.0.1", + "gopd": "^1.2.0", + "set-function-name": "^2.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/regexpp": { + "version": "3.2.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/mysticatea" + } + }, + "node_modules/regexpu-core": { + "version": "6.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "regenerate": "^1.4.2", + "regenerate-unicode-properties": "^10.2.0", + "regjsgen": "^0.8.0", + "regjsparser": "^0.12.0", + "unicode-match-property-ecmascript": "^2.0.0", + "unicode-match-property-value-ecmascript": "^2.1.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/registry-auth-token": { + "version": "4.2.2", + "dev": true, + "license": "MIT", + "dependencies": { + "rc": "1.2.8" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/regjsgen": { + "version": "0.8.0", + "dev": true, + "license": "MIT" + }, + "node_modules/regjsparser": { + "version": "0.12.0", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "jsesc": "~3.0.2" + }, + "bin": { + "regjsparser": "bin/parser" + } + }, + "node_modules/regjsparser/node_modules/jsesc": { + "version": "3.0.2", + "dev": true, + "license": "MIT", + "bin": { + "jsesc": "bin/jsesc" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/remove-trailing-separator": { + "version": "1.1.0", + "dev": true, + "license": "ISC" + }, + "node_modules/repeat-element": { + "version": "1.1.4", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/repeat-string": { + "version": "1.6.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10" + } + }, + "node_modules/require-directory": { + "version": "2.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/require-from-string": { + "version": "2.0.2", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/require-main-filename": { + "version": "2.0.0", + "dev": true, + "license": "ISC" + }, + "node_modules/requires-port": { + "version": "1.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/reserved-words": { + "version": "0.1.2", + "dev": true, + "license": "MIT" + }, + "node_modules/resolve": { + "version": "1.22.10", + "license": "MIT", + "dependencies": { + "is-core-module": "^2.16.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + }, + "bin": { + "resolve": "bin/resolve" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/resolve-cwd": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "resolve-from": "^5.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/resolve-from": { + "version": "5.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/resolve-global": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "global-dirs": "^0.1.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/resolve-url": { + "version": "0.2.1", + "dev": true, + "license": "MIT" + }, + "node_modules/restore-cursor": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "onetime": "^5.1.0", + "signal-exit": "^3.0.2" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/ret": { + "version": "0.1.15", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.12" + } + }, + "node_modules/retry": { + "version": "0.13.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 4" + } + }, + "node_modules/reusify": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "engines": { + "iojs": ">=1.0.0", + "node": ">=0.10.0" + } + }, + "node_modules/rfdc": { + "version": "1.4.1", + "dev": true, + "license": "MIT" + }, + "node_modules/rgb-regex": { + "version": "1.0.1", + "dev": true, + "license": "MIT" + }, + "node_modules/rgba-regex": { + "version": "1.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/rimraf": { + "version": "3.0.2", + "dev": true, + "license": "ISC", + "dependencies": { + "glob": "^7.1.3" + }, + "bin": { + "rimraf": "bin.js" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/rolldown": { + "version": "1.0.0-beta.8", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "dependencies": { + "@oxc-project/types": "0.65.0", + "@valibot/to-json-schema": "1.0.0", + "ansis": "^3.17.0", + "valibot": "1.0.0" + }, + "bin": { + "rolldown": "bin/cli.mjs" + }, + "optionalDependencies": { + "@rolldown/binding-darwin-arm64": "1.0.0-beta.8", + "@rolldown/binding-darwin-x64": "1.0.0-beta.8", + "@rolldown/binding-freebsd-x64": "1.0.0-beta.8", + "@rolldown/binding-linux-arm-gnueabihf": "1.0.0-beta.8", + "@rolldown/binding-linux-arm64-gnu": "1.0.0-beta.8", + "@rolldown/binding-linux-arm64-musl": "1.0.0-beta.8", + "@rolldown/binding-linux-x64-gnu": "1.0.0-beta.8", + "@rolldown/binding-linux-x64-musl": "1.0.0-beta.8", + "@rolldown/binding-wasm32-wasi": "1.0.0-beta.8", + "@rolldown/binding-win32-arm64-msvc": "1.0.0-beta.8", + "@rolldown/binding-win32-ia32-msvc": "1.0.0-beta.8", + "@rolldown/binding-win32-x64-msvc": "1.0.0-beta.8" + }, + "peerDependencies": { + "@oxc-project/runtime": "0.65.0" + }, + "peerDependenciesMeta": { + "@oxc-project/runtime": { + "optional": true + } + } + }, + "node_modules/rollup": { + "version": "2.79.2", + "license": "MIT", + "bin": { + "rollup": "dist/bin/rollup" + }, + "engines": { + "node": ">=10.0.0" + }, + "optionalDependencies": { + "fsevents": "~2.3.2" + } + }, + "node_modules/rollup-plugin-dts": { + "version": "2.0.1", + "dev": true, + "license": "LGPL-3.0", + "dependencies": { + "magic-string": "^0.25.7" + }, + "funding": { + "url": "https://github.com/sponsors/Swatinem" + }, + "optionalDependencies": { + "@babel/code-frame": "^7.10.4" + }, + "peerDependencies": { + "rollup": "^2.34.2", + "typescript": "^4.1.2" + } + }, + "node_modules/rollup-plugin-node-externals": { + "version": "2.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "find-up": "^4.1.0" + }, + "engines": { + "node": ">=8.0.0" + }, + "peerDependencies": { + "builtin-modules": "^3.1.0" + } + }, + "node_modules/rollup-plugin-styles": { + "version": "3.14.1", + "dev": true, + "license": "MIT", + "dependencies": { + "@rollup/pluginutils": "^4.1.0", + "@types/cssnano": "^4.0.0", + "cosmiconfig": "^7.0.0", + "cssnano": "^4.1.10", + "fs-extra": "^9.1.0", + "icss-utils": "^5.1.0", + "mime-types": "^2.1.28", + "p-queue": "^6.6.2", + "postcss": "^8.2.4", + "postcss-modules-extract-imports": "^3.0.0", + "postcss-modules-local-by-default": "^4.0.0", + "postcss-modules-scope": "^3.0.0", + "postcss-modules-values": "^4.0.0", + "postcss-value-parser": "^4.1.0", + "query-string": "^6.13.8", + "resolve": "^1.19.0", + "source-map": "^0.7.3", + "tslib": "^2.1.0" + }, + "engines": { + "node": ">=10" + }, + "peerDependencies": { + "rollup": "^2.2.0" + } + }, + "node_modules/rollup-plugin-styles/node_modules/source-map": { + "version": "0.7.4", + "dev": true, + "license": "BSD-3-Clause", + "engines": { + "node": ">= 8" + } + }, + "node_modules/rollup-plugin-vue": { + "version": "6.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "debug": "^4.1.1", + "hash-sum": "^2.0.0", + "rollup-pluginutils": "^2.8.2" + }, + "peerDependencies": { + "@vue/compiler-sfc": "*" + } + }, + "node_modules/rollup-pluginutils": { + "version": "2.8.2", + "dev": true, + "license": "MIT", + "dependencies": { + "estree-walker": "^0.6.1" + } + }, + "node_modules/rollup-pluginutils/node_modules/estree-walker": { + "version": "0.6.1", + "dev": true, + "license": "MIT" + }, + "node_modules/rsvp": { + "version": "4.8.5", + "dev": true, + "license": "MIT", + "engines": { + "node": "6.* || >= 7.*" + } + }, + "node_modules/run-async": { + "version": "0.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "once": "^1.3.0" + } + }, + "node_modules/run-parallel": { + "version": "1.2.0", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT", + "dependencies": { + "queue-microtask": "^1.2.2" + } + }, + "node_modules/rx-lite": { + "version": "3.1.2", + "dev": true + }, + "node_modules/rxjs": { + "version": "7.8.2", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "tslib": "^2.1.0" + } + }, + "node_modules/safe-array-concat": { + "version": "1.1.3", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.8", + "call-bound": "^1.0.2", + "get-intrinsic": "^1.2.6", + "has-symbols": "^1.1.0", + "isarray": "^2.0.5" + }, + "engines": { + "node": ">=0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/safe-buffer": { + "version": "5.1.2", + "dev": true, + "license": "MIT" + }, + "node_modules/safe-push-apply": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0", + "isarray": "^2.0.5" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/safe-regex": { + "version": "2.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "regexp-tree": "~0.1.1" + } + }, + "node_modules/safe-regex-test": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.2", + "es-errors": "^1.3.0", + "is-regex": "^1.2.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/safer-buffer": { + "version": "2.1.2", + "dev": true, + "license": "MIT" + }, + "node_modules/sane": { + "version": "4.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@cnakazawa/watch": "^1.0.3", + "anymatch": "^2.0.0", + "capture-exit": "^2.0.0", + "exec-sh": "^0.3.2", + "execa": "^1.0.0", + "fb-watchman": "^2.0.0", + "micromatch": "^3.1.4", + "minimist": "^1.1.1", + "walker": "~1.0.5" + }, + "bin": { + "sane": "src/cli.js" + }, + "engines": { + "node": "6.* || 8.* || >= 10.*" + } + }, + "node_modules/sane/node_modules/anymatch": { + "version": "2.0.0", + "dev": true, + "license": "ISC", + "dependencies": { + "micromatch": "^3.1.4", + "normalize-path": "^2.1.1" + } + }, + "node_modules/sane/node_modules/anymatch/node_modules/normalize-path": { + "version": "2.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "remove-trailing-separator": "^1.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/sane/node_modules/execa": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "cross-spawn": "^6.0.0", + "get-stream": "^4.0.0", + "is-stream": "^1.1.0", + "npm-run-path": "^2.0.0", + "p-finally": "^1.0.0", + "signal-exit": "^3.0.0", + "strip-eof": "^1.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/sane/node_modules/execa/node_modules/cross-spawn": { + "version": "6.0.6", + "dev": true, + "license": "MIT", + "dependencies": { + "nice-try": "^1.0.4", + "path-key": "^2.0.1", + "semver": "^5.5.0", + "shebang-command": "^1.2.0", + "which": "^1.2.9" + }, + "engines": { + "node": ">=4.8" + } + }, + "node_modules/sane/node_modules/execa/node_modules/cross-spawn/node_modules/path-key": { + "version": "2.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/sane/node_modules/execa/node_modules/cross-spawn/node_modules/semver": { + "version": "5.7.2", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver" + } + }, + "node_modules/sane/node_modules/execa/node_modules/cross-spawn/node_modules/shebang-command": { + "version": "1.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "shebang-regex": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/sane/node_modules/execa/node_modules/cross-spawn/node_modules/shebang-command/node_modules/shebang-regex": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/sane/node_modules/execa/node_modules/cross-spawn/node_modules/which": { + "version": "1.3.1", + "dev": true, + "license": "ISC", + "dependencies": { + "isexe": "^2.0.0" + }, + "bin": { + "which": "bin/which" + } + }, + "node_modules/sane/node_modules/execa/node_modules/get-stream": { + "version": "4.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "pump": "^3.0.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/sane/node_modules/execa/node_modules/is-stream": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/sane/node_modules/execa/node_modules/npm-run-path": { + "version": "2.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "path-key": "^2.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/sane/node_modules/execa/node_modules/npm-run-path/node_modules/path-key": { + "version": "2.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/sane/node_modules/micromatch": { + "version": "3.1.10", + "dev": true, + "license": "MIT", + "dependencies": { + "arr-diff": "^4.0.0", + "array-unique": "^0.3.2", + "braces": "^2.3.1", + "define-property": "^2.0.2", + "extend-shallow": "^3.0.2", + "extglob": "^2.0.4", + "fragment-cache": "^0.2.1", + "kind-of": "^6.0.2", + "nanomatch": "^1.2.9", + "object.pick": "^1.3.0", + "regex-not": "^1.0.0", + "snapdragon": "^0.8.1", + "to-regex": "^3.0.2" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/sane/node_modules/micromatch/node_modules/braces": { + "version": "2.3.2", + "dev": true, + "license": "MIT", + "dependencies": { + "arr-flatten": "^1.1.0", + "array-unique": "^0.3.2", + "extend-shallow": "^2.0.1", + "fill-range": "^4.0.0", + "isobject": "^3.0.1", + "repeat-element": "^1.1.2", + "snapdragon": "^0.8.1", + "snapdragon-node": "^2.0.1", + "split-string": "^3.0.2", + "to-regex": "^3.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/sane/node_modules/micromatch/node_modules/braces/node_modules/extend-shallow": { + "version": "2.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "is-extendable": "^0.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/sane/node_modules/micromatch/node_modules/braces/node_modules/extend-shallow/node_modules/is-extendable": { + "version": "0.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/sane/node_modules/micromatch/node_modules/braces/node_modules/fill-range": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "extend-shallow": "^2.0.1", + "is-number": "^3.0.0", + "repeat-string": "^1.6.1", + "to-regex-range": "^2.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/sane/node_modules/micromatch/node_modules/braces/node_modules/fill-range/node_modules/is-number": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "kind-of": "^3.0.2" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/sane/node_modules/micromatch/node_modules/braces/node_modules/fill-range/node_modules/is-number/node_modules/kind-of": { + "version": "3.2.2", + "dev": true, + "license": "MIT", + "dependencies": { + "is-buffer": "^1.1.5" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/sane/node_modules/micromatch/node_modules/braces/node_modules/fill-range/node_modules/to-regex-range": { + "version": "2.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "is-number": "^3.0.0", + "repeat-string": "^1.6.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/sax": { + "version": "1.2.4", + "dev": true, + "license": "ISC" + }, + "node_modules/saxes": { + "version": "5.0.1", + "dev": true, + "license": "ISC", + "dependencies": { + "xmlchars": "^2.2.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/semantic-release": { + "version": "17.4.7", + "dev": true, + "license": "MIT", + "dependencies": { + "@semantic-release/commit-analyzer": "^8.0.0", + "@semantic-release/error": "^2.2.0", + "@semantic-release/github": "^7.0.0", + "@semantic-release/npm": "^7.0.0", + "@semantic-release/release-notes-generator": "^9.0.0", + "aggregate-error": "^3.0.0", + "cosmiconfig": "^7.0.0", + "debug": "^4.0.0", + "env-ci": "^5.0.0", + "execa": "^5.0.0", + "figures": "^3.0.0", + "find-versions": "^4.0.0", + "get-stream": "^6.0.0", + "git-log-parser": "^1.2.0", + "hook-std": "^2.0.0", + "hosted-git-info": "^4.0.0", + "lodash": "^4.17.21", + "marked": "^2.0.0", + "marked-terminal": "^4.1.1", + "micromatch": "^4.0.2", + "p-each-series": "^2.1.0", + "p-reduce": "^2.0.0", + "read-pkg-up": "^7.0.0", + "resolve-from": "^5.0.0", + "semver": "^7.3.2", + "semver-diff": "^3.1.1", + "signale": "^1.2.1", + "yargs": "^16.2.0" + }, + "bin": { + "semantic-release": "bin/semantic-release.js" + }, + "engines": { + "node": ">=10.19" + } + }, + "node_modules/semantic-release/node_modules/execa": { + "version": "5.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "cross-spawn": "^7.0.3", + "get-stream": "^6.0.0", + "human-signals": "^2.1.0", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.1", + "onetime": "^5.1.2", + "signal-exit": "^3.0.3", + "strip-final-newline": "^2.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/execa?sponsor=1" + } + }, + "node_modules/semantic-release/node_modules/execa/node_modules/human-signals": { + "version": "2.1.0", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": ">=10.17.0" + } + }, + "node_modules/semantic-release/node_modules/semver": { + "version": "7.7.1", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/semantic-release/node_modules/yargs": { + "version": "16.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "cliui": "^7.0.2", + "escalade": "^3.1.1", + "get-caller-file": "^2.0.5", + "require-directory": "^2.1.1", + "string-width": "^4.2.0", + "y18n": "^5.0.5", + "yargs-parser": "^20.2.2" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/semantic-release/node_modules/yargs/node_modules/cliui": { + "version": "7.0.4", + "dev": true, + "license": "ISC", + "dependencies": { + "string-width": "^4.2.0", + "strip-ansi": "^6.0.0", + "wrap-ansi": "^7.0.0" + } + }, + "node_modules/semantic-release/node_modules/yargs/node_modules/y18n": { + "version": "5.0.8", + "dev": true, + "license": "ISC", + "engines": { + "node": ">=10" + } + }, + "node_modules/semver": { + "version": "6.3.1", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + } + }, + "node_modules/semver-compare": { + "version": "1.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/semver-diff": { + "version": "3.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "semver": "^6.3.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/semver-regex": { + "version": "3.1.4", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/set-blocking": { + "version": "2.0.0", + "dev": true, + "license": "ISC" + }, + "node_modules/set-function-length": { + "version": "1.2.2", + "dev": true, + "license": "MIT", + "dependencies": { + "define-data-property": "^1.1.4", + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "get-intrinsic": "^1.2.4", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/set-function-name": { + "version": "2.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "define-data-property": "^1.1.4", + "es-errors": "^1.3.0", + "functions-have-names": "^1.2.3", + "has-property-descriptors": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/set-proto": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "dunder-proto": "^1.0.1", + "es-errors": "^1.3.0", + "es-object-atoms": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/set-value": { + "version": "2.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "extend-shallow": "^2.0.1", + "is-extendable": "^0.1.1", + "is-plain-object": "^2.0.3", + "split-string": "^3.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/set-value/node_modules/extend-shallow": { + "version": "2.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "is-extendable": "^0.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/set-value/node_modules/is-extendable": { + "version": "0.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/set-value/node_modules/is-plain-object": { + "version": "2.0.4", + "dev": true, + "license": "MIT", + "dependencies": { + "isobject": "^3.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/shebang-command": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "shebang-regex": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/shebang-regex": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/shelljs": { + "version": "0.8.5", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "glob": "^7.0.0", + "interpret": "^1.0.0", + "rechoir": "^0.6.2" + }, + "bin": { + "shjs": "bin/shjs" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/shellwords": { + "version": "0.1.1", + "dev": true, + "license": "MIT", + "optional": true + }, + "node_modules/shx": { + "version": "0.3.4", + "dev": true, + "license": "MIT", + "dependencies": { + "minimist": "^1.2.3", + "shelljs": "^0.8.5" + }, + "bin": { + "shx": "lib/cli.js" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/side-channel": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0", + "object-inspect": "^1.13.3", + "side-channel-list": "^1.0.0", + "side-channel-map": "^1.0.1", + "side-channel-weakmap": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/side-channel-list": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0", + "object-inspect": "^1.13.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/side-channel-map": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.2", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.5", + "object-inspect": "^1.13.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/side-channel-weakmap": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.2", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.5", + "object-inspect": "^1.13.3", + "side-channel-map": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/signal-exit": { + "version": "3.0.7", + "dev": true, + "license": "ISC" + }, + "node_modules/signale": { + "version": "1.4.0", + "dev": true, + "license": "MIT", + "dependencies": { + "chalk": "^2.3.2", + "figures": "^2.0.0", + "pkg-conf": "^2.1.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/signale/node_modules/chalk": { + "version": "2.4.2", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/signale/node_modules/chalk/node_modules/ansi-styles": { + "version": "3.2.1", + "dev": true, + "license": "MIT", + "dependencies": { + "color-convert": "^1.9.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/signale/node_modules/chalk/node_modules/ansi-styles/node_modules/color-convert": { + "version": "1.9.3", + "dev": true, + "license": "MIT", + "dependencies": { + "color-name": "1.1.3" + } + }, + "node_modules/signale/node_modules/chalk/node_modules/ansi-styles/node_modules/color-convert/node_modules/color-name": { + "version": "1.1.3", + "dev": true, + "license": "MIT" + }, + "node_modules/signale/node_modules/chalk/node_modules/escape-string-regexp": { + "version": "1.0.5", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/signale/node_modules/chalk/node_modules/supports-color": { + "version": "5.5.0", + "dev": true, + "license": "MIT", + "dependencies": { + "has-flag": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/signale/node_modules/chalk/node_modules/supports-color/node_modules/has-flag": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/signale/node_modules/figures": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "escape-string-regexp": "^1.0.5" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/signale/node_modules/figures/node_modules/escape-string-regexp": { + "version": "1.0.5", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/simple-swizzle": { + "version": "0.2.2", + "dev": true, + "license": "MIT", + "dependencies": { + "is-arrayish": "^0.3.1" + } + }, + "node_modules/simple-swizzle/node_modules/is-arrayish": { + "version": "0.3.2", + "dev": true, + "license": "MIT" + }, + "node_modules/sisteransi": { + "version": "1.0.5", + "dev": true, + "license": "MIT" + }, + "node_modules/slash": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/slice-ansi": { + "version": "4.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.0.0", + "astral-regex": "^2.0.0", + "is-fullwidth-code-point": "^3.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/slice-ansi?sponsor=1" + } + }, + "node_modules/snapdragon": { + "version": "0.8.2", + "dev": true, + "license": "MIT", + "dependencies": { + "base": "^0.11.1", + "debug": "^2.2.0", + "define-property": "^0.2.5", + "extend-shallow": "^2.0.1", + "map-cache": "^0.2.2", + "source-map": "^0.5.6", + "source-map-resolve": "^0.5.0", + "use": "^3.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/snapdragon-node": { + "version": "2.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "define-property": "^1.0.0", + "isobject": "^3.0.0", + "snapdragon-util": "^3.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/snapdragon-node/node_modules/define-property": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "is-descriptor": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/snapdragon-util": { + "version": "3.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "kind-of": "^3.2.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/snapdragon-util/node_modules/kind-of": { + "version": "3.2.2", + "dev": true, + "license": "MIT", + "dependencies": { + "is-buffer": "^1.1.5" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/snapdragon/node_modules/debug": { + "version": "2.6.9", + "dev": true, + "license": "MIT", + "dependencies": { + "ms": "2.0.0" + } + }, + "node_modules/snapdragon/node_modules/debug/node_modules/ms": { + "version": "2.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/snapdragon/node_modules/define-property": { + "version": "0.2.5", + "dev": true, + "license": "MIT", + "dependencies": { + "is-descriptor": "^0.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/snapdragon/node_modules/define-property/node_modules/is-descriptor": { + "version": "0.1.7", + "dev": true, + "license": "MIT", + "dependencies": { + "is-accessor-descriptor": "^1.0.1", + "is-data-descriptor": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/snapdragon/node_modules/extend-shallow": { + "version": "2.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "is-extendable": "^0.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/snapdragon/node_modules/extend-shallow/node_modules/is-extendable": { + "version": "0.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/snapdragon/node_modules/source-map": { + "version": "0.5.7", + "dev": true, + "license": "BSD-3-Clause", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/source-map": { + "version": "0.6.1", + "dev": true, + "license": "BSD-3-Clause", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/source-map-js": { + "version": "1.2.1", + "license": "BSD-3-Clause", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/source-map-resolve": { + "version": "0.5.3", + "dev": true, + "license": "MIT", + "dependencies": { + "atob": "^2.1.2", + "decode-uri-component": "^0.2.0", + "resolve-url": "^0.2.1", + "source-map-url": "^0.4.0", + "urix": "^0.1.0" + } + }, + "node_modules/source-map-support": { + "version": "0.5.21", + "dev": true, + "license": "MIT", + "dependencies": { + "buffer-from": "^1.0.0", + "source-map": "^0.6.0" + } + }, + "node_modules/source-map-url": { + "version": "0.4.1", + "dev": true, + "license": "MIT" + }, + "node_modules/sourcemap-codec": { + "version": "1.4.8", + "dev": true, + "license": "MIT" + }, + "node_modules/spawn-error-forwarder": { + "version": "1.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/spdx-correct": { + "version": "3.2.0", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "spdx-expression-parse": "^3.0.0", + "spdx-license-ids": "^3.0.0" + } + }, + "node_modules/spdx-exceptions": { + "version": "2.5.0", + "dev": true, + "license": "CC-BY-3.0" + }, + "node_modules/spdx-expression-parse": { + "version": "3.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "spdx-exceptions": "^2.1.0", + "spdx-license-ids": "^3.0.0" + } + }, + "node_modules/spdx-license-ids": { + "version": "3.0.21", + "dev": true, + "license": "CC0-1.0" + }, + "node_modules/split": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "through": "2" + }, + "engines": { + "node": "*" + } + }, + "node_modules/split-on-first": { + "version": "1.1.0", + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/split-string": { + "version": "3.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "extend-shallow": "^3.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/split2": { + "version": "1.0.0", + "dev": true, + "license": "ISC", + "dependencies": { + "through2": "~2.0.0" + } + }, + "node_modules/sprintf-js": { + "version": "1.0.3", + "dev": true, + "license": "BSD-3-Clause" + }, + "node_modules/stable": { + "version": "0.1.8", + "dev": true, + "license": "MIT" + }, + "node_modules/stack-utils": { + "version": "2.0.6", + "dev": true, + "license": "MIT", + "dependencies": { + "escape-string-regexp": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/stack-utils/node_modules/escape-string-regexp": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/static-extend": { + "version": "0.1.2", + "dev": true, + "license": "MIT", + "dependencies": { + "define-property": "^0.2.5", + "object-copy": "^0.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/static-extend/node_modules/define-property": { + "version": "0.2.5", + "dev": true, + "license": "MIT", + "dependencies": { + "is-descriptor": "^0.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/static-extend/node_modules/define-property/node_modules/is-descriptor": { + "version": "0.1.7", + "dev": true, + "license": "MIT", + "dependencies": { + "is-accessor-descriptor": "^1.0.1", + "is-data-descriptor": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/stream-combiner2": { + "version": "1.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "duplexer2": "~0.1.0", + "readable-stream": "^2.0.2" + } + }, + "node_modules/strict-uri-encode": { + "version": "2.0.0", + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/string_decoder": { + "version": "1.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "safe-buffer": "~5.1.0" + } + }, + "node_modules/string-argv": { + "version": "0.3.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.6.19" + } + }, + "node_modules/string-hash": { + "version": "1.1.3", + "dev": true, + "license": "CC0-1.0" + }, + "node_modules/string-length": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "char-regex": "^1.0.2", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/string-width": { + "version": "4.2.3", + "dev": true, + "license": "MIT", + "dependencies": { + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/string.prototype.trim": { + "version": "1.2.10", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.8", + "call-bound": "^1.0.2", + "define-data-property": "^1.1.4", + "define-properties": "^1.2.1", + "es-abstract": "^1.23.5", + "es-object-atoms": "^1.0.0", + "has-property-descriptors": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/string.prototype.trimend": { + "version": "1.0.9", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.8", + "call-bound": "^1.0.2", + "define-properties": "^1.2.1", + "es-object-atoms": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/string.prototype.trimstart": { + "version": "1.0.8", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.7", + "define-properties": "^1.2.1", + "es-object-atoms": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/stringify-object": { + "version": "3.3.0", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "get-own-enumerable-property-symbols": "^3.0.0", + "is-obj": "^1.0.1", + "is-regexp": "^1.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/strip-ansi": { + "version": "6.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-bom": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/strip-eof": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/strip-final-newline": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/strip-indent": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "min-indent": "^1.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-json-comments": { + "version": "3.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/stylehacks": { + "version": "4.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "browserslist": "^4.0.0", + "postcss": "^7.0.0", + "postcss-selector-parser": "^3.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/stylehacks/node_modules/postcss": { + "version": "7.0.39", + "dev": true, + "license": "MIT", + "dependencies": { + "picocolors": "^0.2.1", + "source-map": "^0.6.1" + }, + "engines": { + "node": ">=6.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + } + }, + "node_modules/stylehacks/node_modules/postcss-selector-parser": { + "version": "3.1.2", + "dev": true, + "license": "MIT", + "dependencies": { + "dot-prop": "^5.2.0", + "indexes-of": "^1.0.1", + "uniq": "^1.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/stylehacks/node_modules/postcss/node_modules/picocolors": { + "version": "0.2.1", + "dev": true, + "license": "ISC" + }, + "node_modules/supports-color": { + "version": "7.2.0", + "dev": true, + "license": "MIT", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/supports-hyperlinks": { + "version": "2.3.0", + "dev": true, + "license": "MIT", + "dependencies": { + "has-flag": "^4.0.0", + "supports-color": "^7.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/supports-preserve-symlinks-flag": { + "version": "1.0.0", + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/svgo": { + "version": "1.3.2", + "dev": true, + "license": "MIT", + "dependencies": { + "chalk": "^2.4.1", + "coa": "^2.0.2", + "css-select": "^2.0.0", + "css-select-base-adapter": "^0.1.1", + "css-tree": "1.0.0-alpha.37", + "csso": "^4.0.2", + "js-yaml": "^3.13.1", + "mkdirp": "~0.5.1", + "object.values": "^1.1.0", + "sax": "~1.2.4", + "stable": "^0.1.8", + "unquote": "~1.1.1", + "util.promisify": "~1.0.0" + }, + "bin": { + "svgo": "bin/svgo" + }, + "engines": { + "node": ">=4.0.0" + } + }, + "node_modules/svgo/node_modules/chalk": { + "version": "2.4.2", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/svgo/node_modules/chalk/node_modules/ansi-styles": { + "version": "3.2.1", + "dev": true, + "license": "MIT", + "dependencies": { + "color-convert": "^1.9.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/svgo/node_modules/chalk/node_modules/ansi-styles/node_modules/color-convert": { + "version": "1.9.3", + "dev": true, + "license": "MIT", + "dependencies": { + "color-name": "1.1.3" + } + }, + "node_modules/svgo/node_modules/chalk/node_modules/ansi-styles/node_modules/color-convert/node_modules/color-name": { + "version": "1.1.3", + "dev": true, + "license": "MIT" + }, + "node_modules/svgo/node_modules/chalk/node_modules/escape-string-regexp": { + "version": "1.0.5", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/svgo/node_modules/chalk/node_modules/supports-color": { + "version": "5.5.0", + "dev": true, + "license": "MIT", + "dependencies": { + "has-flag": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/svgo/node_modules/chalk/node_modules/supports-color/node_modules/has-flag": { + "version": "3.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/svgo/node_modules/mkdirp": { + "version": "0.5.6", + "dev": true, + "license": "MIT", + "dependencies": { + "minimist": "^1.2.6" + }, + "bin": { + "mkdirp": "bin/cmd.js" + } + }, + "node_modules/symbol-tree": { + "version": "3.2.4", + "dev": true, + "license": "MIT" + }, + "node_modules/table": { + "version": "6.9.0", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "ajv": "^8.0.1", + "lodash.truncate": "^4.4.2", + "slice-ansi": "^4.0.0", + "string-width": "^4.2.3", + "strip-ansi": "^6.0.1" + }, + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/table/node_modules/ajv": { + "version": "8.17.1", + "dev": true, + "license": "MIT", + "dependencies": { + "fast-deep-equal": "^3.1.3", + "fast-uri": "^3.0.1", + "json-schema-traverse": "^1.0.0", + "require-from-string": "^2.0.2" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" + } + }, + "node_modules/table/node_modules/ajv/node_modules/json-schema-traverse": { + "version": "1.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/temp-dir": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/tempy": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "del": "^6.0.0", + "is-stream": "^2.0.0", + "temp-dir": "^2.0.0", + "type-fest": "^0.16.0", + "unique-string": "^2.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/tempy/node_modules/type-fest": { + "version": "0.16.0", + "dev": true, + "license": "(MIT OR CC0-1.0)", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/terminal-link": { + "version": "2.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-escapes": "^4.2.1", + "supports-hyperlinks": "^2.0.0" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/test-exclude": { + "version": "6.0.0", + "dev": true, + "license": "ISC", + "dependencies": { + "@istanbuljs/schema": "^0.1.2", + "glob": "^7.1.4", + "minimatch": "^3.0.4" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/text-extensions": { + "version": "1.9.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10" + } + }, + "node_modules/text-table": { + "version": "0.2.0", + "dev": true, + "license": "MIT" + }, + "node_modules/throat": { + "version": "5.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/through": { + "version": "2.3.8", + "dev": true, + "license": "MIT" + }, + "node_modules/through2": { + "version": "2.0.5", + "dev": true, + "license": "MIT", + "dependencies": { + "readable-stream": "~2.3.6", + "xtend": "~4.0.1" + } + }, + "node_modules/timsort": { + "version": "0.3.0", + "dev": true, + "license": "MIT" + }, + "node_modules/tmpl": { + "version": "1.0.5", + "dev": true, + "license": "BSD-3-Clause" + }, + "node_modules/to-object-path": { + "version": "0.3.0", + "dev": true, + "license": "MIT", + "dependencies": { + "kind-of": "^3.0.2" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/to-object-path/node_modules/kind-of": { + "version": "3.2.2", + "dev": true, + "license": "MIT", + "dependencies": { + "is-buffer": "^1.1.5" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/to-regex": { + "version": "3.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "define-property": "^2.0.2", + "extend-shallow": "^3.0.2", + "regex-not": "^1.0.2", + "safe-regex": "^1.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/to-regex-range": { + "version": "5.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "is-number": "^7.0.0" + }, + "engines": { + "node": ">=8.0" + } + }, + "node_modules/to-regex/node_modules/safe-regex": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "ret": "~0.1.10" + } + }, + "node_modules/tough-cookie": { + "version": "4.1.4", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "psl": "^1.1.33", + "punycode": "^2.1.1", + "universalify": "^0.2.0", + "url-parse": "^1.5.3" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/tough-cookie/node_modules/universalify": { + "version": "0.2.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 4.0.0" + } + }, + "node_modules/tr46": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "punycode": "^2.1.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/traverse": { + "version": "0.6.8", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/trim-newlines": { + "version": "3.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/ts-jest": { + "version": "26.5.6", + "dev": true, + "license": "MIT", + "dependencies": { + "bs-logger": "0.x", + "buffer-from": "1.x", + "fast-json-stable-stringify": "2.x", + "jest-util": "^26.1.0", + "json5": "2.x", + "lodash": "4.x", + "make-error": "1.x", + "mkdirp": "1.x", + "semver": "7.x", + "yargs-parser": "20.x" + }, + "bin": { + "ts-jest": "cli.js" + }, + "engines": { + "node": ">= 10" + }, + "peerDependencies": { + "jest": ">=26 <27", + "typescript": ">=3.8 <5.0" + } + }, + "node_modules/ts-jest/node_modules/semver": { + "version": "7.7.1", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/tsconfig-paths": { + "version": "3.15.0", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/json5": "^0.0.29", + "json5": "^1.0.2", + "minimist": "^1.2.6", + "strip-bom": "^3.0.0" + } + }, + "node_modules/tsconfig-paths/node_modules/json5": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "minimist": "^1.2.0" + }, + "bin": { + "json5": "lib/cli.js" + } + }, + "node_modules/tslib": { + "version": "2.8.1", + "license": "0BSD" + }, + "node_modules/tsutils": { + "version": "3.21.0", + "dev": true, + "license": "MIT", + "dependencies": { + "tslib": "^1.8.1" + }, + "engines": { + "node": ">= 6" + }, + "peerDependencies": { + "typescript": ">=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta" + } + }, + "node_modules/tsutils/node_modules/tslib": { + "version": "1.14.1", + "dev": true, + "license": "0BSD" + }, + "node_modules/type-check": { + "version": "0.4.0", + "dev": true, + "license": "MIT", + "dependencies": { + "prelude-ls": "^1.2.1" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/type-detect": { + "version": "4.0.8", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/type-fest": { + "version": "0.20.2", + "dev": true, + "license": "(MIT OR CC0-1.0)", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/typed-array-buffer": { + "version": "1.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.3", + "es-errors": "^1.3.0", + "is-typed-array": "^1.1.14" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/typed-array-byte-length": { + "version": "1.0.3", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.8", + "for-each": "^0.3.3", + "gopd": "^1.2.0", + "has-proto": "^1.2.0", + "is-typed-array": "^1.1.14" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/typed-array-byte-offset": { + "version": "1.0.4", + "dev": true, + "license": "MIT", + "dependencies": { + "available-typed-arrays": "^1.0.7", + "call-bind": "^1.0.8", + "for-each": "^0.3.3", + "gopd": "^1.2.0", + "has-proto": "^1.2.0", + "is-typed-array": "^1.1.15", + "reflect.getprototypeof": "^1.0.9" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/typed-array-length": { + "version": "1.0.7", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind": "^1.0.7", + "for-each": "^0.3.3", + "gopd": "^1.0.1", + "is-typed-array": "^1.1.13", + "possible-typed-array-names": "^1.0.0", + "reflect.getprototypeof": "^1.0.6" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/typedarray-to-buffer": { + "version": "3.1.5", + "dev": true, + "license": "MIT", + "dependencies": { + "is-typedarray": "^1.0.0" + } + }, + "node_modules/typescript": { + "version": "4.9.5", + "dev": true, + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=4.2.0" + } + }, + "node_modules/uglify-js": { + "version": "3.19.3", + "dev": true, + "license": "BSD-2-Clause", + "optional": true, + "bin": { + "uglifyjs": "bin/uglifyjs" + }, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/unbox-primitive": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.3", + "has-bigints": "^1.0.2", + "has-symbols": "^1.1.0", + "which-boxed-primitive": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/undici-types": { + "version": "6.21.0", + "dev": true, + "license": "MIT" + }, + "node_modules/unicode-canonical-property-names-ecmascript": { + "version": "2.0.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/unicode-match-property-ecmascript": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "unicode-canonical-property-names-ecmascript": "^2.0.0", + "unicode-property-aliases-ecmascript": "^2.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/unicode-match-property-value-ecmascript": { + "version": "2.2.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/unicode-property-aliases-ecmascript": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/union-value": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "arr-union": "^3.1.0", + "get-value": "^2.0.6", + "is-extendable": "^0.1.1", + "set-value": "^2.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/union-value/node_modules/is-extendable": { + "version": "0.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/uniq": { + "version": "1.0.1", + "dev": true, + "license": "MIT" + }, + "node_modules/uniqs": { + "version": "2.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/unique-string": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "crypto-random-string": "^2.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/universal-user-agent": { + "version": "6.0.1", + "dev": true, + "license": "ISC" + }, + "node_modules/universalify": { + "version": "2.0.1", + "license": "MIT", + "engines": { + "node": ">= 10.0.0" + } + }, + "node_modules/unquote": { + "version": "1.1.1", + "dev": true, + "license": "MIT" + }, + "node_modules/unset-value": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "has-value": "^0.3.1", + "isobject": "^3.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/unset-value/node_modules/has-value": { + "version": "0.3.1", + "dev": true, + "license": "MIT", + "dependencies": { + "get-value": "^2.0.3", + "has-values": "^0.1.4", + "isobject": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/unset-value/node_modules/has-value/node_modules/has-values": { + "version": "0.1.4", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/unset-value/node_modules/has-value/node_modules/isobject": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "isarray": "1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/unset-value/node_modules/has-value/node_modules/isobject/node_modules/isarray": { + "version": "1.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/update-browserslist-db": { + "version": "1.1.3", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "dependencies": { + "escalade": "^3.2.0", + "picocolors": "^1.1.1" + }, + "bin": { + "update-browserslist-db": "cli.js" + }, + "peerDependencies": { + "browserslist": ">= 4.21.0" + } + }, + "node_modules/uri-js": { + "version": "4.4.1", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "punycode": "^2.1.0" + } + }, + "node_modules/urix": { + "version": "0.1.0", + "dev": true, + "license": "MIT" + }, + "node_modules/url-join": { + "version": "4.0.1", + "dev": true, + "license": "MIT" + }, + "node_modules/url-parse": { + "version": "1.5.10", + "dev": true, + "license": "MIT", + "dependencies": { + "querystringify": "^2.1.1", + "requires-port": "^1.0.0" + } + }, + "node_modules/use": { + "version": "3.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/util-deprecate": { + "version": "1.0.2", + "license": "MIT" + }, + "node_modules/util.promisify": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "define-properties": "^1.1.3", + "es-abstract": "^1.17.2", + "has-symbols": "^1.0.1", + "object.getownpropertydescriptors": "^2.1.0" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/uuid": { + "version": "8.3.2", + "dev": true, + "license": "MIT", + "optional": true, + "bin": { + "uuid": "dist/bin/uuid" + } + }, + "node_modules/v8-compile-cache": { + "version": "2.4.0", + "dev": true, + "license": "MIT" + }, + "node_modules/v8-to-istanbul": { + "version": "7.1.2", + "dev": true, + "license": "ISC", + "dependencies": { + "@types/istanbul-lib-coverage": "^2.0.1", + "convert-source-map": "^1.6.0", + "source-map": "^0.7.3" + }, + "engines": { + "node": ">=10.10.0" + } + }, + "node_modules/v8-to-istanbul/node_modules/convert-source-map": { + "version": "1.9.0", + "dev": true, + "license": "MIT" + }, + "node_modules/v8-to-istanbul/node_modules/source-map": { + "version": "0.7.4", + "dev": true, + "license": "BSD-3-Clause", + "engines": { + "node": ">= 8" + } + }, + "node_modules/valibot": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "peerDependencies": { + "typescript": ">=5" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, + "node_modules/validate-npm-package-license": { + "version": "3.0.4", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "spdx-correct": "^3.0.0", + "spdx-expression-parse": "^3.0.0" + } + }, + "node_modules/vendors": { + "version": "1.0.4", + "dev": true, + "license": "MIT", + "funding": { + "type": "github", + "url": "https://github.com/sponsors/wooorm" + } + }, + "node_modules/vorpal": { + "version": "1.12.0", + "dev": true, + "license": "MIT", + "dependencies": { + "babel-polyfill": "^6.3.14", + "chalk": "^1.1.0", + "in-publish": "^2.0.0", + "inquirer": "0.11.0", + "lodash": "^4.5.1", + "log-update": "^1.0.2", + "minimist": "^1.2.0", + "node-localstorage": "^0.6.0", + "strip-ansi": "^3.0.0", + "wrap-ansi": "^2.0.0" + }, + "engines": { + "iojs": ">= 1.0.0", + "node": ">= 0.10.0" + } + }, + "node_modules/vorpal/node_modules/chalk": { + "version": "1.1.3", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/vorpal/node_modules/chalk/node_modules/ansi-styles": { + "version": "2.2.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/vorpal/node_modules/chalk/node_modules/escape-string-regexp": { + "version": "1.0.5", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/vorpal/node_modules/chalk/node_modules/supports-color": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/vorpal/node_modules/log-update": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-escapes": "^1.0.0", + "cli-cursor": "^1.0.2" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/vorpal/node_modules/log-update/node_modules/ansi-escapes": { + "version": "1.4.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/vorpal/node_modules/log-update/node_modules/cli-cursor": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "restore-cursor": "^1.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/vorpal/node_modules/log-update/node_modules/cli-cursor/node_modules/restore-cursor": { + "version": "1.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "exit-hook": "^1.0.0", + "onetime": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/vorpal/node_modules/log-update/node_modules/cli-cursor/node_modules/restore-cursor/node_modules/onetime": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/vorpal/node_modules/strip-ansi": { + "version": "3.0.1", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-regex": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/vorpal/node_modules/strip-ansi/node_modules/ansi-regex": { + "version": "2.1.1", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/vorpal/node_modules/wrap-ansi": { + "version": "2.1.0", + "dev": true, + "license": "MIT", + "dependencies": { + "string-width": "^1.0.1", + "strip-ansi": "^3.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/vorpal/node_modules/wrap-ansi/node_modules/string-width": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "code-point-at": "^1.0.0", + "is-fullwidth-code-point": "^1.0.0", + "strip-ansi": "^3.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/vorpal/node_modules/wrap-ansi/node_modules/string-width/node_modules/is-fullwidth-code-point": { + "version": "1.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "number-is-nan": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/vue": { + "version": "3.0.7", + "dev": true, + "license": "MIT", + "dependencies": { + "@vue/compiler-dom": "3.0.7", + "@vue/runtime-dom": "3.0.7", + "@vue/shared": "3.0.7" + } + }, + "node_modules/w3c-hr-time": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "browser-process-hrtime": "^1.0.0" + } + }, + "node_modules/w3c-xmlserializer": { + "version": "2.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "xml-name-validator": "^3.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/walker": { + "version": "1.0.8", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "makeerror": "1.0.12" + } + }, + "node_modules/webidl-conversions": { + "version": "6.1.0", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=10.4" + } + }, + "node_modules/whatwg-encoding": { + "version": "1.0.5", + "dev": true, + "license": "MIT", + "dependencies": { + "iconv-lite": "0.4.24" + } + }, + "node_modules/whatwg-mimetype": { + "version": "2.3.0", + "dev": true, + "license": "MIT" + }, + "node_modules/whatwg-url": { + "version": "8.7.0", + "dev": true, + "license": "MIT", + "dependencies": { + "lodash": "^4.7.0", + "tr46": "^2.1.0", + "webidl-conversions": "^6.1.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/which": { + "version": "2.0.2", + "dev": true, + "license": "ISC", + "dependencies": { + "isexe": "^2.0.0" + }, + "bin": { + "node-which": "bin/node-which" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/which-boxed-primitive": { + "version": "1.1.1", + "dev": true, + "license": "MIT", + "dependencies": { + "is-bigint": "^1.1.0", + "is-boolean-object": "^1.2.1", + "is-number-object": "^1.1.1", + "is-string": "^1.1.1", + "is-symbol": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/which-builtin-type": { + "version": "1.2.1", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.2", + "function.prototype.name": "^1.1.6", + "has-tostringtag": "^1.0.2", + "is-async-function": "^2.0.0", + "is-date-object": "^1.1.0", + "is-finalizationregistry": "^1.1.0", + "is-generator-function": "^1.0.10", + "is-regex": "^1.2.1", + "is-weakref": "^1.0.2", + "isarray": "^2.0.5", + "which-boxed-primitive": "^1.1.0", + "which-collection": "^1.0.2", + "which-typed-array": "^1.1.16" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/which-collection": { + "version": "1.0.2", + "dev": true, + "license": "MIT", + "dependencies": { + "is-map": "^2.0.3", + "is-set": "^2.0.3", + "is-weakmap": "^2.0.2", + "is-weakset": "^2.0.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/which-module": { + "version": "2.0.1", + "dev": true, + "license": "ISC" + }, + "node_modules/which-pm-runs": { + "version": "1.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/which-typed-array": { + "version": "1.1.19", + "dev": true, + "license": "MIT", + "dependencies": { + "available-typed-arrays": "^1.0.7", + "call-bind": "^1.0.8", + "call-bound": "^1.0.4", + "for-each": "^0.3.5", + "get-proto": "^1.0.1", + "gopd": "^1.2.0", + "has-tostringtag": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/word-wrap": { + "version": "1.2.5", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/wordwrap": { + "version": "1.0.0", + "dev": true, + "license": "MIT" + }, + "node_modules/wrap-ansi": { + "version": "7.0.0", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/wrap-ansi?sponsor=1" + } + }, + "node_modules/wrappy": { + "version": "1.0.2", + "license": "ISC" + }, + "node_modules/write-file-atomic": { + "version": "3.0.3", + "dev": true, + "license": "ISC", + "dependencies": { + "imurmurhash": "^0.1.4", + "is-typedarray": "^1.0.0", + "signal-exit": "^3.0.2", + "typedarray-to-buffer": "^3.1.5" + } + }, + "node_modules/ws": { + "version": "7.5.10", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8.3.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": "^5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + }, + "node_modules/xml-name-validator": { + "version": "3.0.0", + "dev": true, + "license": "Apache-2.0" + }, + "node_modules/xmlchars": { + "version": "2.2.0", + "dev": true, + "license": "MIT" + }, + "node_modules/xtend": { + "version": "4.0.2", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.4" + } + }, + "node_modules/y18n": { + "version": "4.0.3", + "dev": true, + "license": "ISC" + }, + "node_modules/yallist": { + "version": "3.1.1", + "dev": true, + "license": "ISC" + }, + "node_modules/yaml": { + "version": "1.10.2", + "dev": true, + "license": "ISC", + "engines": { + "node": ">= 6" + } + }, + "node_modules/yargs": { + "version": "15.4.1", + "dev": true, + "license": "MIT", + "dependencies": { + "cliui": "^6.0.0", + "decamelize": "^1.2.0", + "find-up": "^4.1.0", + "get-caller-file": "^2.0.1", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^4.2.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^18.1.2" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/yargs-parser": { + "version": "20.2.9", + "dev": true, + "license": "ISC", + "engines": { + "node": ">=10" + } + }, + "node_modules/yargs/node_modules/yargs-parser": { + "version": "18.1.3", + "dev": true, + "license": "ISC", + "dependencies": { + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/yocto-queue": { + "version": "0.1.0", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + } + } +} diff --git a/package.json b/package.json index 85d50ea..f87075a 100644 --- a/package.json +++ b/package.json @@ -28,7 +28,7 @@ ], "scripts": { "prebuild": "shx rm -rf dist", - "build": "rollup -c --environment NODE_ENV:production", + "build": "rolldown -c rolldown.config.js", "commit": "commit", "prelint": "prettier -l --write .", "lint": "eslint --ext .ts,.js --fix .", @@ -55,11 +55,11 @@ "@babel/core": "^7.12.10", "@babel/plugin-proposal-class-properties": "^7.12.1", "@babel/preset-env": "^7.12.11", + "@bulvar/bulma": "^0.11.24", "@commitlint/cli": "^11.0.0", "@commitlint/config-angular": "^11.0.0", "@commitlint/prompt-cli": "^11.0.0", "@pathscale/bulma-extensions-css-var": "0.0.49-3", - "@bulvar/bulma": "^0.11.24", "@pathscale/vue3-ui": "^0.8.146", "@rollup/plugin-babel": "^5.2.2", "@rollup/plugin-commonjs": "^17.0.0", @@ -91,6 +91,7 @@ "jest-circus": "^26.6.3", "lint-staged": "^10.5.3", "prettier": "^2.2.1", + "rolldown": "1.0.0-beta.8", "rollup-plugin-dts": "^2.0.1", "rollup-plugin-node-externals": "^2.2.0", "rollup-plugin-styles": "^3.12.1", diff --git a/resetup.ps1 b/resetup.ps1 index 2ad32cb..d2d598e 100644 --- a/resetup.ps1 +++ b/resetup.ps1 @@ -13,6 +13,7 @@ $nextList = @( "vuex" "vue-router" "rollup-plugin-vue" + "rolldown-plugin-vue" "@vue/compiler-sfc" "@pathscale/vue3-ui" diff --git a/rolldown.config.js b/rolldown.config.js new file mode 100644 index 0000000..9cd62fe --- /dev/null +++ b/rolldown.config.js @@ -0,0 +1,8 @@ +import { defineConfig } from "rolldown"; + +export default defineConfig({ + input: "src/index.ts", + output: { + file: "bundle.js", + }, +}); diff --git a/rollup.config.js b/rollup.config.js deleted file mode 100644 index fcacc22..0000000 --- a/rollup.config.js +++ /dev/null @@ -1,39 +0,0 @@ -/* eslint node/no-unsupported-features/es-syntax: ["error", { ignores: ["modules"] }] */ -// eslint-disable-next-line import/no-named-as-default -import babel from "@rollup/plugin-babel"; -import commonjs from "@rollup/plugin-commonjs"; -import dts from "rollup-plugin-dts"; -import externals from "rollup-plugin-node-externals"; -import json from "@rollup/plugin-json"; -import replace from "@rollup/plugin-replace"; -import resolve from "@rollup/plugin-node-resolve"; -import typescript from "@rollup/plugin-typescript"; - -import pkg from "./package.json"; -const extensions = [".ts", ".mjs", ".js", ".json"]; - -export default [ - // Bundle - { - input: "src/index.ts", - output: [ - { format: "cjs", file: pkg.main }, - { format: "es", file: pkg.module }, - ], - plugins: [ - externals({ deps: true }), - replace({ "process.env.NODE_ENV": JSON.stringify(process.env.NODE_ENV) }), - json(), - resolve({ preferBuiltins: true, extensions }), - commonjs(), - typescript(), - babel({ babelHelpers: "bundled", extensions }), - ], - }, - // Declaration - { - input: "src/index.ts", - output: { format: "es", file: pkg.types }, - plugins: [externals({ deps: true }), dts({ respectExternal: true })], - }, -]; From 729b81e18fd00a4046fa2608fee1711c444f18c1 Mon Sep 17 00:00:00 2001 From: AbsoluteC2H6O Date: Thu, 24 Apr 2025 18:24:38 -0400 Subject: [PATCH 2/7] roldown(migration): Added nodePolyfills plugin Completed integration with nodepolyfills plugin. --- __tests__/helpers/index.ts | 58 +- bun.lock | 3 + bundle.js | 111577 ++++++++++++++++++++++++++++++++++ package.json | 1 + rolldown.config.js | 5 +- 5 files changed, 111620 insertions(+), 24 deletions(-) create mode 100644 bundle.js diff --git a/__tests__/helpers/index.ts b/__tests__/helpers/index.ts index a0bcb1c..a9b04d9 100644 --- a/__tests__/helpers/index.ts +++ b/__tests__/helpers/index.ts @@ -11,6 +11,8 @@ import resolve from "@rollup/plugin-node-resolve"; import vue from "rollup-plugin-vue"; import styles from "rollup-plugin-styles"; import externals from "rollup-plugin-node-externals"; +import { rolldown } from 'rolldown' +import nodePolyfills from '@rolldown/plugin-node-polyfills' export interface WriteData { input: string | string[]; @@ -45,32 +47,44 @@ export const fixture = (...args: string[]): string => export async function write(data: WriteData): Promise { const outDir = fixture("dist", data.outDir ?? data.title ?? ""); const input = Array.isArray(data.input) ? data.input.map(i => fixture(i)) : fixture(data.input); - const bundle = await rollup({ - ...data.inputOpts, + // const bundle = await rollup({ + // ...data.inputOpts, + // input, + // plugins: [ + // externals({ deps: true }), + // json(), + // resolve({ + // preferBuiltins: true, + // dedupe: [ + // "vue", + // "@vue/compiler-core", + // "@vue/compiler-dom", + // "@vue/compiler-sfc", + // "@vue/compiler-ssr", + // "@vue/reactivity", + // "@vue/runtime-core", + // "@vue/runtime-dom", + // "@vue/shared", + // ], + // }), + // vue3ui({ debug: true }), + // vue({ preprocessStyles: false }), + // styles({ mode: "extract" }), + // ], + // }); + const bundle = await rolldown({ + // ... other config input, plugins: [ - externals({ deps: true }), - json(), - resolve({ - preferBuiltins: true, - dedupe: [ - "vue", - "@vue/compiler-core", - "@vue/compiler-dom", - "@vue/compiler-sfc", - "@vue/compiler-ssr", - "@vue/reactivity", - "@vue/runtime-core", - "@vue/runtime-dom", - "@vue/shared", - ], + nodePolyfills({ + // Optional configuration + include: ['fs', 'path'], // Only polyfill specific modules + exclude: ['crypto'], // Exclude modules from polyfilling }), - vue3ui({ debug: true }), - vue({ preprocessStyles: false }), - styles({ mode: "extract" }), + // ... other plugins ], - }); - + platform: 'node' // Important for Node.js polyfilling + }) const { output } = await bundle.write({ ...data.outputOpts, dir: data.outputOpts?.file ? undefined : outDir, diff --git a/bun.lock b/bun.lock index 8d73d5a..1fae327 100644 --- a/bun.lock +++ b/bun.lock @@ -27,6 +27,7 @@ "@commitlint/prompt-cli": "^11.0.0", "@pathscale/bulma-extensions-css-var": "0.0.49-3", "@pathscale/vue3-ui": "^0.8.146", + "@rolldown/plugin-node-polyfills": "1.0.0", "@rollup/plugin-babel": "^5.2.2", "@rollup/plugin-commonjs": "^17.0.0", "@rollup/plugin-json": "^4.1.0", @@ -447,6 +448,8 @@ "@rolldown/binding-win32-x64-msvc": ["@rolldown/binding-win32-x64-msvc@1.0.0-beta.8", "https://registry.npmmirror.com/@rolldown/binding-win32-x64-msvc/-/binding-win32-x64-msvc-1.0.0-beta.8.tgz", { "os": "win32", "cpu": "x64" }, "sha512-hR81d84Poe6oIxaz4PnWBLVF0VuqtRfISIyXQAgk2etu2udrKnWKr3A+xqXe9ELjbLlRYGvEm2dlw/cldO9Kxg=="], + "@rolldown/plugin-node-polyfills": ["@rolldown/plugin-node-polyfills@1.0.0", "https://registry.npmmirror.com/@rolldown/plugin-node-polyfills/-/plugin-node-polyfills-1.0.0.tgz", {}, "sha512-JUmEhvz+B6+0AaeUGvZ7SnJec7wpwYqZ+FcAng1I3UVGYKA1uSmE1H4vKHUewU665Nb37znDd9N4o/iImmKeVg=="], + "@rollup/plugin-babel": ["@rollup/plugin-babel@5.3.1", "", { "dependencies": { "@babel/helper-module-imports": "^7.10.4", "@rollup/pluginutils": "^3.1.0" }, "peerDependencies": { "@babel/core": "^7.0.0", "@types/babel__core": "^7.1.9", "rollup": "^1.20.0||^2.0.0" }, "optionalPeers": ["@types/babel__core"] }, "sha512-WFfdLWU/xVWKeRQnKmIAQULUI7Il0gZnBIH/ZFO069wYIfPu+8zrfp/KMW0atmELoRDq8FbiP3VCss9MhCut7Q=="], "@rollup/plugin-commonjs": ["@rollup/plugin-commonjs@17.1.0", "", { "dependencies": { "@rollup/pluginutils": "^3.1.0", "commondir": "^1.0.1", "estree-walker": "^2.0.1", "glob": "^7.1.6", "is-reference": "^1.2.1", "magic-string": "^0.25.7", "resolve": "^1.17.0" }, "peerDependencies": { "rollup": "^2.30.0" } }, "sha512-PoMdXCw0ZyvjpCMT5aV4nkL0QywxP29sODQsSGeDpr/oI49Qq9tRtAsb/LbYbDzFlOydVEqHmmZWFtXJEAX9ew=="], diff --git a/bundle.js b/bundle.js new file mode 100644 index 0000000..e671ff4 --- /dev/null +++ b/bundle.js @@ -0,0 +1,111577 @@ +import path, { isAbsolute, posix, resolve, win32 } from "path"; +import { access, constants, readFile } from "fs"; +import { inspect, promisify } from "util"; + +//#region rolldown:runtime +var __create = Object.create; +var __defProp = Object.defineProperty; +var __getOwnPropDesc = Object.getOwnPropertyDescriptor; +var __getOwnPropNames = Object.getOwnPropertyNames; +var __getProtoOf = Object.getPrototypeOf; +var __hasOwnProp = Object.prototype.hasOwnProperty; +var __esm = (fn, res) => function() { + return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res; +}; +var __commonJS = (cb$1, mod$1) => function() { + return mod$1 || (0, cb$1[__getOwnPropNames(cb$1)[0]])((mod$1 = { exports: {} }).exports, mod$1), mod$1.exports; +}; +var __export = (target, all) => { + for (var name in all) __defProp(target, name, { + get: all[name], + enumerable: true + }); +}; +var __copyProps = (to, from, except, desc) => { + if (from && typeof from === "object" || typeof from === "function") for (var keys$2 = __getOwnPropNames(from), i$5 = 0, n$3 = keys$2.length, key; i$5 < n$3; i$5++) { + key = keys$2[i$5]; + if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, { + get: ((k$1) => from[k$1]).bind(null, key), + enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable + }); + } + return to; +}; +var __toESM = (mod$1, isNodeMode, target) => (target = mod$1 != null ? __create(__getProtoOf(mod$1)) : {}, __copyProps(isNodeMode || !mod$1 || !mod$1.__esModule ? __defProp(target, "default", { + value: mod$1, + enumerable: true +}) : target, mod$1)); +var __toCommonJS = (mod$1) => __copyProps(__defProp({}, "__esModule", { value: true }), mod$1); +var __require = /* @__PURE__ */ ((x$2) => typeof require !== "undefined" ? require : typeof Proxy !== "undefined" ? new Proxy(x$2, { get: (a, b$1) => (typeof require !== "undefined" ? require : a)[b$1] }) : x$2)(function(x$2) { + if (typeof require !== "undefined") return require.apply(this, arguments); + throw Error("Calling `require` for \"" + x$2 + "\" in an environment that doesn't expose the `require` function."); +}); + +//#endregion +//#region node_modules/strict-uri-encode/index.js +var require_strict_uri_encode = __commonJS({ "node_modules/strict-uri-encode/index.js"(exports, module) { + module.exports = (str$3) => encodeURIComponent(str$3).replace(/[!'()*]/g, (x$2) => `%${x$2.charCodeAt(0).toString(16).toUpperCase()}`); +} }); + +//#endregion +//#region node_modules/decode-uri-component/index.js +var require_decode_uri_component = __commonJS({ "node_modules/decode-uri-component/index.js"(exports, module) { + var token = "%[a-f0-9]{2}"; + var singleMatcher = new RegExp("(" + token + ")|([^%]+?)", "gi"); + var multiMatcher = new RegExp("(" + token + ")+", "gi"); + function decodeComponents(components, split) { + try { + return [decodeURIComponent(components.join(""))]; + } catch (err) {} + if (components.length === 1) return components; + split = split || 1; + var left = components.slice(0, split); + var right = components.slice(split); + return Array.prototype.concat.call([], decodeComponents(left), decodeComponents(right)); + } + function decode$2(input) { + try { + return decodeURIComponent(input); + } catch (err) { + var tokens$3 = input.match(singleMatcher) || []; + for (var i$5 = 1; i$5 < tokens$3.length; i$5++) { + input = decodeComponents(tokens$3, i$5).join(""); + tokens$3 = input.match(singleMatcher) || []; + } + return input; + } + } + function customDecodeURIComponent(input) { + var replaceMap = { + "%FE%FF": "��", + "%FF%FE": "��" + }; + var match = multiMatcher.exec(input); + while (match) { + try { + replaceMap[match[0]] = decodeURIComponent(match[0]); + } catch (err) { + var result$1 = decode$2(match[0]); + if (result$1 !== match[0]) replaceMap[match[0]] = result$1; + } + match = multiMatcher.exec(input); + } + replaceMap["%C2"] = "�"; + var entries = Object.keys(replaceMap); + for (var i$5 = 0; i$5 < entries.length; i$5++) { + var key = entries[i$5]; + input = input.replace(new RegExp(key, "g"), replaceMap[key]); + } + return input; + } + module.exports = function(encodedURI) { + if (typeof encodedURI !== "string") throw new TypeError("Expected `encodedURI` to be of type `string`, got `" + typeof encodedURI + "`"); + try { + encodedURI = encodedURI.replace(/\+/g, " "); + return decodeURIComponent(encodedURI); + } catch (err) { + return customDecodeURIComponent(encodedURI); + } + }; +} }); + +//#endregion +//#region node_modules/split-on-first/index.js +var require_split_on_first = __commonJS({ "node_modules/split-on-first/index.js"(exports, module) { + module.exports = (string$3, separator) => { + if (!(typeof string$3 === "string" && typeof separator === "string")) throw new TypeError("Expected the arguments to be of type `string`"); + if (separator === "") return [string$3]; + const separatorIndex = string$3.indexOf(separator); + if (separatorIndex === -1) return [string$3]; + return [string$3.slice(0, separatorIndex), string$3.slice(separatorIndex + separator.length)]; + }; +} }); + +//#endregion +//#region node_modules/filter-obj/index.js +var require_filter_obj = __commonJS({ "node_modules/filter-obj/index.js"(exports, module) { + module.exports = function(obj, predicate) { + var ret = {}; + var keys$2 = Object.keys(obj); + var isArr = Array.isArray(predicate); + for (var i$5 = 0; i$5 < keys$2.length; i$5++) { + var key = keys$2[i$5]; + var val = obj[key]; + if (isArr ? predicate.indexOf(key) !== -1 : predicate(key, val, obj)) ret[key] = val; + } + return ret; + }; +} }); + +//#endregion +//#region node_modules/query-string/index.js +var require_query_string = __commonJS({ "node_modules/query-string/index.js"(exports) { + const strictUriEncode = require_strict_uri_encode(); + const decodeComponent = require_decode_uri_component(); + const splitOnFirst = require_split_on_first(); + const filterObject = require_filter_obj(); + const isNullOrUndefined = (value) => value === null || value === void 0; + function encoderForArrayFormat(options) { + switch (options.arrayFormat) { + case "index": return (key) => (result$1, value) => { + const index$1 = result$1.length; + if (value === void 0 || options.skipNull && value === null || options.skipEmptyString && value === "") return result$1; + if (value === null) return [...result$1, [ + encode$2(key, options), + "[", + index$1, + "]" + ].join("")]; + return [...result$1, [ + encode$2(key, options), + "[", + encode$2(index$1, options), + "]=", + encode$2(value, options) + ].join("")]; + }; + case "bracket": return (key) => (result$1, value) => { + if (value === void 0 || options.skipNull && value === null || options.skipEmptyString && value === "") return result$1; + if (value === null) return [...result$1, [encode$2(key, options), "[]"].join("")]; + return [...result$1, [ + encode$2(key, options), + "[]=", + encode$2(value, options) + ].join("")]; + }; + case "comma": + case "separator": return (key) => (result$1, value) => { + if (value === null || value === void 0 || value.length === 0) return result$1; + if (result$1.length === 0) return [[ + encode$2(key, options), + "=", + encode$2(value, options) + ].join("")]; + return [[result$1, encode$2(value, options)].join(options.arrayFormatSeparator)]; + }; + default: return (key) => (result$1, value) => { + if (value === void 0 || options.skipNull && value === null || options.skipEmptyString && value === "") return result$1; + if (value === null) return [...result$1, encode$2(key, options)]; + return [...result$1, [ + encode$2(key, options), + "=", + encode$2(value, options) + ].join("")]; + }; + } + } + function parserForArrayFormat(options) { + let result$1; + switch (options.arrayFormat) { + case "index": return (key, value, accumulator) => { + result$1 = /\[(\d*)\]$/.exec(key); + key = key.replace(/\[\d*\]$/, ""); + if (!result$1) { + accumulator[key] = value; + return; + } + if (accumulator[key] === void 0) accumulator[key] = {}; + accumulator[key][result$1[1]] = value; + }; + case "bracket": return (key, value, accumulator) => { + result$1 = /(\[\])$/.exec(key); + key = key.replace(/\[\]$/, ""); + if (!result$1) { + accumulator[key] = value; + return; + } + if (accumulator[key] === void 0) { + accumulator[key] = [value]; + return; + } + accumulator[key] = [].concat(accumulator[key], value); + }; + case "comma": + case "separator": return (key, value, accumulator) => { + const isArray$5 = typeof value === "string" && value.includes(options.arrayFormatSeparator); + const isEncodedArray = typeof value === "string" && !isArray$5 && decode$1(value, options).includes(options.arrayFormatSeparator); + value = isEncodedArray ? decode$1(value, options) : value; + const newValue = isArray$5 || isEncodedArray ? value.split(options.arrayFormatSeparator).map((item) => decode$1(item, options)) : value === null ? value : decode$1(value, options); + accumulator[key] = newValue; + }; + default: return (key, value, accumulator) => { + if (accumulator[key] === void 0) { + accumulator[key] = value; + return; + } + accumulator[key] = [].concat(accumulator[key], value); + }; + } + } + function validateArrayFormatSeparator(value) { + if (typeof value !== "string" || value.length !== 1) throw new TypeError("arrayFormatSeparator must be single character string"); + } + function encode$2(value, options) { + if (options.encode) return options.strict ? strictUriEncode(value) : encodeURIComponent(value); + return value; + } + function decode$1(value, options) { + if (options.decode) return decodeComponent(value); + return value; + } + function keysSorter(input) { + if (Array.isArray(input)) return input.sort(); + if (typeof input === "object") return keysSorter(Object.keys(input)).sort((a, b$1) => Number(a) - Number(b$1)).map((key) => input[key]); + return input; + } + function removeHash(input) { + const hashStart = input.indexOf("#"); + if (hashStart !== -1) input = input.slice(0, hashStart); + return input; + } + function getHash(url$1) { + let hash$2 = ""; + const hashStart = url$1.indexOf("#"); + if (hashStart !== -1) hash$2 = url$1.slice(hashStart); + return hash$2; + } + function extract(input) { + input = removeHash(input); + const queryStart = input.indexOf("?"); + if (queryStart === -1) return ""; + return input.slice(queryStart + 1); + } + function parseValue(value, options) { + if (options.parseNumbers && !Number.isNaN(Number(value)) && typeof value === "string" && value.trim() !== "") value = Number(value); + else if (options.parseBooleans && value !== null && (value.toLowerCase() === "true" || value.toLowerCase() === "false")) value = value.toLowerCase() === "true"; + return value; + } + function parse$16(query, options) { + options = Object.assign({ + decode: true, + sort: true, + arrayFormat: "none", + arrayFormatSeparator: ",", + parseNumbers: false, + parseBooleans: false + }, options); + validateArrayFormatSeparator(options.arrayFormatSeparator); + const formatter = parserForArrayFormat(options); + const ret = Object.create(null); + if (typeof query !== "string") return ret; + query = query.trim().replace(/^[?#&]/, ""); + if (!query) return ret; + for (const param of query.split("&")) { + if (param === "") continue; + let [key, value] = splitOnFirst(options.decode ? param.replace(/\+/g, " ") : param, "="); + value = value === void 0 ? null : ["comma", "separator"].includes(options.arrayFormat) ? value : decode$1(value, options); + formatter(decode$1(key, options), value, ret); + } + for (const key of Object.keys(ret)) { + const value = ret[key]; + if (typeof value === "object" && value !== null) for (const k$1 of Object.keys(value)) value[k$1] = parseValue(value[k$1], options); + else ret[key] = parseValue(value, options); + } + if (options.sort === false) return ret; + return (options.sort === true ? Object.keys(ret).sort() : Object.keys(ret).sort(options.sort)).reduce((result$1, key) => { + const value = ret[key]; + if (Boolean(value) && typeof value === "object" && !Array.isArray(value)) result$1[key] = keysSorter(value); + else result$1[key] = value; + return result$1; + }, Object.create(null)); + } + exports.extract = extract; + exports.parse = parse$16; + exports.stringify = (object$3, options) => { + if (!object$3) return ""; + options = Object.assign({ + encode: true, + strict: true, + arrayFormat: "none", + arrayFormatSeparator: "," + }, options); + validateArrayFormatSeparator(options.arrayFormatSeparator); + const shouldFilter = (key) => options.skipNull && isNullOrUndefined(object$3[key]) || options.skipEmptyString && object$3[key] === ""; + const formatter = encoderForArrayFormat(options); + const objectCopy = {}; + for (const key of Object.keys(object$3)) if (!shouldFilter(key)) objectCopy[key] = object$3[key]; + const keys$2 = Object.keys(objectCopy); + if (options.sort !== false) keys$2.sort(options.sort); + return keys$2.map((key) => { + const value = object$3[key]; + if (value === void 0) return ""; + if (value === null) return encode$2(key, options); + if (Array.isArray(value)) return value.reduce(formatter(key), []).join("&"); + return encode$2(key, options) + "=" + encode$2(value, options); + }).filter((x$2) => x$2.length > 0).join("&"); + }; + exports.parseUrl = (url$1, options) => { + options = Object.assign({ decode: true }, options); + const [url_, hash$2] = splitOnFirst(url$1, "#"); + return Object.assign({ + url: url_.split("?")[0] || "", + query: parse$16(extract(url$1), options) + }, options && options.parseFragmentIdentifier && hash$2 ? { fragmentIdentifier: decode$1(hash$2, options) } : {}); + }; + exports.stringifyUrl = (object$3, options) => { + options = Object.assign({ + encode: true, + strict: true + }, options); + const url$1 = removeHash(object$3.url).split("?")[0] || ""; + const queryFromUrl = exports.extract(object$3.url); + const parsedQueryFromUrl = exports.parse(queryFromUrl, { sort: false }); + const query = Object.assign(parsedQueryFromUrl, object$3.query); + let queryString = exports.stringify(query, options); + if (queryString) queryString = `?${queryString}`; + let hash$2 = getHash(object$3.url); + if (object$3.fragmentIdentifier) hash$2 = `#${encode$2(object$3.fragmentIdentifier, options)}`; + return `${url$1}${queryString}${hash$2}`; + }; + exports.pick = (input, filter$3, options) => { + options = Object.assign({ parseFragmentIdentifier: true }, options); + const { url: url$1, query, fragmentIdentifier } = exports.parseUrl(input, options); + return exports.stringifyUrl({ + url: url$1, + query: filterObject(query, filter$3), + fragmentIdentifier + }, options); + }; + exports.exclude = (input, filter$3, options) => { + const exclusionFilter = Array.isArray(filter$3) ? (key) => !filter$3.includes(key) : (key, value) => !filter$3(key, value); + return exports.pick(input, exclusionFilter, options); + }; +} }); + +//#endregion +//#region node_modules/universalify/index.js +var require_universalify = __commonJS({ "node_modules/universalify/index.js"(exports) { + exports.fromCallback = function(fn) { + return Object.defineProperty(function(...args) { + if (typeof args[args.length - 1] === "function") fn.apply(this, args); + else return new Promise((resolve$5, reject$1) => { + args.push((err, res) => err != null ? reject$1(err) : resolve$5(res)); + fn.apply(this, args); + }); + }, "name", { value: fn.name }); + }; + exports.fromPromise = function(fn) { + return Object.defineProperty(function(...args) { + const cb$1 = args[args.length - 1]; + if (typeof cb$1 !== "function") return fn.apply(this, args); + else { + args.pop(); + fn.apply(this, args).then((r) => cb$1(null, r), cb$1); + } + }, "name", { value: fn.name }); + }; +} }); + +//#endregion +//#region node_modules/graceful-fs/polyfills.js +var require_polyfills = __commonJS({ "node_modules/graceful-fs/polyfills.js"(exports, module) { + var constants$3 = __require("constants"); + var origCwd = process.cwd; + var cwd = null; + var platform = process.env.GRACEFUL_FS_PLATFORM || process.platform; + process.cwd = function() { + if (!cwd) cwd = origCwd.call(process); + return cwd; + }; + try { + process.cwd(); + } catch (er) {} + if (typeof process.chdir === "function") { + var chdir = process.chdir; + process.chdir = function(d$2) { + cwd = null; + chdir.call(process, d$2); + }; + if (Object.setPrototypeOf) Object.setPrototypeOf(process.chdir, chdir); + } + module.exports = patch$1; + function patch$1(fs$25) { + if (constants$3.hasOwnProperty("O_SYMLINK") && process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)) patchLchmod(fs$25); + if (!fs$25.lutimes) patchLutimes(fs$25); + fs$25.chown = chownFix(fs$25.chown); + fs$25.fchown = chownFix(fs$25.fchown); + fs$25.lchown = chownFix(fs$25.lchown); + fs$25.chmod = chmodFix(fs$25.chmod); + fs$25.fchmod = chmodFix(fs$25.fchmod); + fs$25.lchmod = chmodFix(fs$25.lchmod); + fs$25.chownSync = chownFixSync(fs$25.chownSync); + fs$25.fchownSync = chownFixSync(fs$25.fchownSync); + fs$25.lchownSync = chownFixSync(fs$25.lchownSync); + fs$25.chmodSync = chmodFixSync(fs$25.chmodSync); + fs$25.fchmodSync = chmodFixSync(fs$25.fchmodSync); + fs$25.lchmodSync = chmodFixSync(fs$25.lchmodSync); + fs$25.stat = statFix(fs$25.stat); + fs$25.fstat = statFix(fs$25.fstat); + fs$25.lstat = statFix(fs$25.lstat); + fs$25.statSync = statFixSync(fs$25.statSync); + fs$25.fstatSync = statFixSync(fs$25.fstatSync); + fs$25.lstatSync = statFixSync(fs$25.lstatSync); + if (fs$25.chmod && !fs$25.lchmod) { + fs$25.lchmod = function(path$28, mode, cb$1) { + if (cb$1) process.nextTick(cb$1); + }; + fs$25.lchmodSync = function() {}; + } + if (fs$25.chown && !fs$25.lchown) { + fs$25.lchown = function(path$28, uid$1, gid, cb$1) { + if (cb$1) process.nextTick(cb$1); + }; + fs$25.lchownSync = function() {}; + } + if (platform === "win32") fs$25.rename = typeof fs$25.rename !== "function" ? fs$25.rename : function(fs$rename) { + function rename$2(from, to, cb$1) { + var start = Date.now(); + var backoff = 0; + fs$rename(from, to, function CB(er) { + if (er && (er.code === "EACCES" || er.code === "EPERM" || er.code === "EBUSY") && Date.now() - start < 6e4) { + setTimeout(function() { + fs$25.stat(to, function(stater, st) { + if (stater && stater.code === "ENOENT") fs$rename(from, to, CB); + else cb$1(er); + }); + }, backoff); + if (backoff < 100) backoff += 10; + return; + } + if (cb$1) cb$1(er); + }); + } + if (Object.setPrototypeOf) Object.setPrototypeOf(rename$2, fs$rename); + return rename$2; + }(fs$25.rename); + fs$25.read = typeof fs$25.read !== "function" ? fs$25.read : function(fs$read) { + function read$1(fd, buffer, offset, length, position, callback_) { + var callback; + if (callback_ && typeof callback_ === "function") { + var eagCounter = 0; + callback = function(er, _$2, __) { + if (er && er.code === "EAGAIN" && eagCounter < 10) { + eagCounter++; + return fs$read.call(fs$25, fd, buffer, offset, length, position, callback); + } + callback_.apply(this, arguments); + }; + } + return fs$read.call(fs$25, fd, buffer, offset, length, position, callback); + } + if (Object.setPrototypeOf) Object.setPrototypeOf(read$1, fs$read); + return read$1; + }(fs$25.read); + fs$25.readSync = typeof fs$25.readSync !== "function" ? fs$25.readSync : function(fs$readSync) { + return function(fd, buffer, offset, length, position) { + var eagCounter = 0; + while (true) try { + return fs$readSync.call(fs$25, fd, buffer, offset, length, position); + } catch (er) { + if (er.code === "EAGAIN" && eagCounter < 10) { + eagCounter++; + continue; + } + throw er; + } + }; + }(fs$25.readSync); + function patchLchmod(fs$26) { + fs$26.lchmod = function(path$28, mode, callback) { + fs$26.open(path$28, constants$3.O_WRONLY | constants$3.O_SYMLINK, mode, function(err, fd) { + if (err) { + if (callback) callback(err); + return; + } + fs$26.fchmod(fd, mode, function(err$1) { + fs$26.close(fd, function(err2) { + if (callback) callback(err$1 || err2); + }); + }); + }); + }; + fs$26.lchmodSync = function(path$28, mode) { + var fd = fs$26.openSync(path$28, constants$3.O_WRONLY | constants$3.O_SYMLINK, mode); + var threw = true; + var ret; + try { + ret = fs$26.fchmodSync(fd, mode); + threw = false; + } finally { + if (threw) try { + fs$26.closeSync(fd); + } catch (er) {} + else fs$26.closeSync(fd); + } + return ret; + }; + } + function patchLutimes(fs$26) { + if (constants$3.hasOwnProperty("O_SYMLINK") && fs$26.futimes) { + fs$26.lutimes = function(path$28, at$3, mt, cb$1) { + fs$26.open(path$28, constants$3.O_SYMLINK, function(er, fd) { + if (er) { + if (cb$1) cb$1(er); + return; + } + fs$26.futimes(fd, at$3, mt, function(er$1) { + fs$26.close(fd, function(er2) { + if (cb$1) cb$1(er$1 || er2); + }); + }); + }); + }; + fs$26.lutimesSync = function(path$28, at$3, mt) { + var fd = fs$26.openSync(path$28, constants$3.O_SYMLINK); + var ret; + var threw = true; + try { + ret = fs$26.futimesSync(fd, at$3, mt); + threw = false; + } finally { + if (threw) try { + fs$26.closeSync(fd); + } catch (er) {} + else fs$26.closeSync(fd); + } + return ret; + }; + } else if (fs$26.futimes) { + fs$26.lutimes = function(_a, _b, _c, cb$1) { + if (cb$1) process.nextTick(cb$1); + }; + fs$26.lutimesSync = function() {}; + } + } + function chmodFix(orig) { + if (!orig) return orig; + return function(target, mode, cb$1) { + return orig.call(fs$25, target, mode, function(er) { + if (chownErOk(er)) er = null; + if (cb$1) cb$1.apply(this, arguments); + }); + }; + } + function chmodFixSync(orig) { + if (!orig) return orig; + return function(target, mode) { + try { + return orig.call(fs$25, target, mode); + } catch (er) { + if (!chownErOk(er)) throw er; + } + }; + } + function chownFix(orig) { + if (!orig) return orig; + return function(target, uid$1, gid, cb$1) { + return orig.call(fs$25, target, uid$1, gid, function(er) { + if (chownErOk(er)) er = null; + if (cb$1) cb$1.apply(this, arguments); + }); + }; + } + function chownFixSync(orig) { + if (!orig) return orig; + return function(target, uid$1, gid) { + try { + return orig.call(fs$25, target, uid$1, gid); + } catch (er) { + if (!chownErOk(er)) throw er; + } + }; + } + function statFix(orig) { + if (!orig) return orig; + return function(target, options, cb$1) { + if (typeof options === "function") { + cb$1 = options; + options = null; + } + function callback(er, stats) { + if (stats) { + if (stats.uid < 0) stats.uid += 4294967296; + if (stats.gid < 0) stats.gid += 4294967296; + } + if (cb$1) cb$1.apply(this, arguments); + } + return options ? orig.call(fs$25, target, options, callback) : orig.call(fs$25, target, callback); + }; + } + function statFixSync(orig) { + if (!orig) return orig; + return function(target, options) { + var stats = options ? orig.call(fs$25, target, options) : orig.call(fs$25, target); + if (stats) { + if (stats.uid < 0) stats.uid += 4294967296; + if (stats.gid < 0) stats.gid += 4294967296; + } + return stats; + }; + } + function chownErOk(er) { + if (!er) return true; + if (er.code === "ENOSYS") return true; + var nonroot = !process.getuid || process.getuid() !== 0; + if (nonroot) { + if (er.code === "EINVAL" || er.code === "EPERM") return true; + } + return false; + } + } +} }); + +//#endregion +//#region node_modules/graceful-fs/legacy-streams.js +var require_legacy_streams = __commonJS({ "node_modules/graceful-fs/legacy-streams.js"(exports, module) { + var Stream = __require("stream").Stream; + module.exports = legacy$1; + function legacy$1(fs$25) { + return { + ReadStream, + WriteStream + }; + function ReadStream(path$28, options) { + if (!(this instanceof ReadStream)) return new ReadStream(path$28, options); + Stream.call(this); + var self$1 = this; + this.path = path$28; + this.fd = null; + this.readable = true; + this.paused = false; + this.flags = "r"; + this.mode = 438; + this.bufferSize = 64 * 1024; + options = options || {}; + var keys$2 = Object.keys(options); + for (var index$1 = 0, length = keys$2.length; index$1 < length; index$1++) { + var key = keys$2[index$1]; + this[key] = options[key]; + } + if (this.encoding) this.setEncoding(this.encoding); + if (this.start !== void 0) { + if ("number" !== typeof this.start) throw TypeError("start must be a Number"); + if (this.end === void 0) this.end = Infinity; + else if ("number" !== typeof this.end) throw TypeError("end must be a Number"); + if (this.start > this.end) throw new Error("start must be <= end"); + this.pos = this.start; + } + if (this.fd !== null) { + process.nextTick(function() { + self$1._read(); + }); + return; + } + fs$25.open(this.path, this.flags, this.mode, function(err, fd) { + if (err) { + self$1.emit("error", err); + self$1.readable = false; + return; + } + self$1.fd = fd; + self$1.emit("open", fd); + self$1._read(); + }); + } + function WriteStream(path$28, options) { + if (!(this instanceof WriteStream)) return new WriteStream(path$28, options); + Stream.call(this); + this.path = path$28; + this.fd = null; + this.writable = true; + this.flags = "w"; + this.encoding = "binary"; + this.mode = 438; + this.bytesWritten = 0; + options = options || {}; + var keys$2 = Object.keys(options); + for (var index$1 = 0, length = keys$2.length; index$1 < length; index$1++) { + var key = keys$2[index$1]; + this[key] = options[key]; + } + if (this.start !== void 0) { + if ("number" !== typeof this.start) throw TypeError("start must be a Number"); + if (this.start < 0) throw new Error("start must be >= zero"); + this.pos = this.start; + } + this.busy = false; + this._queue = []; + if (this.fd === null) { + this._open = fs$25.open; + this._queue.push([ + this._open, + this.path, + this.flags, + this.mode, + void 0 + ]); + this.flush(); + } + } + } +} }); + +//#endregion +//#region node_modules/graceful-fs/clone.js +var require_clone$1 = __commonJS({ "node_modules/graceful-fs/clone.js"(exports, module) { + module.exports = clone$4; + var getPrototypeOf = Object.getPrototypeOf || function(obj) { + return obj.__proto__; + }; + function clone$4(obj) { + if (obj === null || typeof obj !== "object") return obj; + if (obj instanceof Object) var copy$2 = { __proto__: getPrototypeOf(obj) }; + else var copy$2 = Object.create(null); + Object.getOwnPropertyNames(obj).forEach(function(key) { + Object.defineProperty(copy$2, key, Object.getOwnPropertyDescriptor(obj, key)); + }); + return copy$2; + } +} }); + +//#endregion +//#region node_modules/graceful-fs/graceful-fs.js +var require_graceful_fs = __commonJS({ "node_modules/graceful-fs/graceful-fs.js"(exports, module) { + var fs$24 = __require("fs"); + var polyfills = require_polyfills(); + var legacy = require_legacy_streams(); + var clone$3 = require_clone$1(); + var util$8 = __require("util"); + /* istanbul ignore next - node 0.x polyfill */ + var gracefulQueue; + var previousSymbol; + /* istanbul ignore else - node 0.x polyfill */ + if (typeof Symbol === "function" && typeof Symbol.for === "function") { + gracefulQueue = Symbol.for("graceful-fs.queue"); + previousSymbol = Symbol.for("graceful-fs.previous"); + } else { + gracefulQueue = "___graceful-fs.queue"; + previousSymbol = "___graceful-fs.previous"; + } + function noop$3() {} + function publishQueue(context, queue$1) { + Object.defineProperty(context, gracefulQueue, { get: function() { + return queue$1; + } }); + } + var debug$1 = noop$3; + if (util$8.debuglog) debug$1 = util$8.debuglog("gfs4"); + else if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || "")) debug$1 = function() { + var m$2 = util$8.format.apply(util$8, arguments); + m$2 = "GFS4: " + m$2.split(/\n/).join("\nGFS4: "); + console.error(m$2); + }; + if (!fs$24[gracefulQueue]) { + var queue = global[gracefulQueue] || []; + publishQueue(fs$24, queue); + fs$24.close = function(fs$close) { + function close(fd, cb$1) { + return fs$close.call(fs$24, fd, function(err) { + if (!err) resetQueue(); + if (typeof cb$1 === "function") cb$1.apply(this, arguments); + }); + } + Object.defineProperty(close, previousSymbol, { value: fs$close }); + return close; + }(fs$24.close); + fs$24.closeSync = function(fs$closeSync) { + function closeSync(fd) { + fs$closeSync.apply(fs$24, arguments); + resetQueue(); + } + Object.defineProperty(closeSync, previousSymbol, { value: fs$closeSync }); + return closeSync; + }(fs$24.closeSync); + if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || "")) process.on("exit", function() { + debug$1(fs$24[gracefulQueue]); + __require("assert").equal(fs$24[gracefulQueue].length, 0); + }); + } + if (!global[gracefulQueue]) publishQueue(global, fs$24[gracefulQueue]); + module.exports = patch(clone$3(fs$24)); + if (process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH && !fs$24.__patched) { + module.exports = patch(fs$24); + fs$24.__patched = true; + } + function patch(fs$25) { + polyfills(fs$25); + fs$25.gracefulify = patch; + fs$25.createReadStream = createReadStream; + fs$25.createWriteStream = createWriteStream; + var fs$readFile = fs$25.readFile; + fs$25.readFile = readFile$2; + function readFile$2(path$28, options, cb$1) { + if (typeof options === "function") cb$1 = options, options = null; + return go$readFile(path$28, options, cb$1); + function go$readFile(path$29, options$1, cb$2, startTime) { + return fs$readFile(path$29, options$1, function(err) { + if (err && (err.code === "EMFILE" || err.code === "ENFILE")) enqueue([ + go$readFile, + [ + path$29, + options$1, + cb$2 + ], + err, + startTime || Date.now(), + Date.now() + ]); + else if (typeof cb$2 === "function") cb$2.apply(this, arguments); + }); + } + } + var fs$writeFile = fs$25.writeFile; + fs$25.writeFile = writeFile$1; + function writeFile$1(path$28, data$2, options, cb$1) { + if (typeof options === "function") cb$1 = options, options = null; + return go$writeFile(path$28, data$2, options, cb$1); + function go$writeFile(path$29, data$3, options$1, cb$2, startTime) { + return fs$writeFile(path$29, data$3, options$1, function(err) { + if (err && (err.code === "EMFILE" || err.code === "ENFILE")) enqueue([ + go$writeFile, + [ + path$29, + data$3, + options$1, + cb$2 + ], + err, + startTime || Date.now(), + Date.now() + ]); + else if (typeof cb$2 === "function") cb$2.apply(this, arguments); + }); + } + } + var fs$appendFile = fs$25.appendFile; + if (fs$appendFile) fs$25.appendFile = appendFile; + function appendFile(path$28, data$2, options, cb$1) { + if (typeof options === "function") cb$1 = options, options = null; + return go$appendFile(path$28, data$2, options, cb$1); + function go$appendFile(path$29, data$3, options$1, cb$2, startTime) { + return fs$appendFile(path$29, data$3, options$1, function(err) { + if (err && (err.code === "EMFILE" || err.code === "ENFILE")) enqueue([ + go$appendFile, + [ + path$29, + data$3, + options$1, + cb$2 + ], + err, + startTime || Date.now(), + Date.now() + ]); + else if (typeof cb$2 === "function") cb$2.apply(this, arguments); + }); + } + } + var fs$copyFile = fs$25.copyFile; + if (fs$copyFile) fs$25.copyFile = copyFile$2; + function copyFile$2(src, dest, flags, cb$1) { + if (typeof flags === "function") { + cb$1 = flags; + flags = 0; + } + return go$copyFile(src, dest, flags, cb$1); + function go$copyFile(src$1, dest$1, flags$1, cb$2, startTime) { + return fs$copyFile(src$1, dest$1, flags$1, function(err) { + if (err && (err.code === "EMFILE" || err.code === "ENFILE")) enqueue([ + go$copyFile, + [ + src$1, + dest$1, + flags$1, + cb$2 + ], + err, + startTime || Date.now(), + Date.now() + ]); + else if (typeof cb$2 === "function") cb$2.apply(this, arguments); + }); + } + } + var fs$readdir = fs$25.readdir; + fs$25.readdir = readdir; + var noReaddirOptionVersions = /^v[0-5]\./; + function readdir(path$28, options, cb$1) { + if (typeof options === "function") cb$1 = options, options = null; + var go$readdir = noReaddirOptionVersions.test(process.version) ? function go$readdir$1(path$29, options$1, cb$2, startTime) { + return fs$readdir(path$29, fs$readdirCallback(path$29, options$1, cb$2, startTime)); + } : function go$readdir$1(path$29, options$1, cb$2, startTime) { + return fs$readdir(path$29, options$1, fs$readdirCallback(path$29, options$1, cb$2, startTime)); + }; + return go$readdir(path$28, options, cb$1); + function fs$readdirCallback(path$29, options$1, cb$2, startTime) { + return function(err, files) { + if (err && (err.code === "EMFILE" || err.code === "ENFILE")) enqueue([ + go$readdir, + [ + path$29, + options$1, + cb$2 + ], + err, + startTime || Date.now(), + Date.now() + ]); + else { + if (files && files.sort) files.sort(); + if (typeof cb$2 === "function") cb$2.call(this, err, files); + } + }; + } + } + if (process.version.substr(0, 4) === "v0.8") { + var legStreams = legacy(fs$25); + ReadStream = legStreams.ReadStream; + WriteStream = legStreams.WriteStream; + } + var fs$ReadStream = fs$25.ReadStream; + if (fs$ReadStream) { + ReadStream.prototype = Object.create(fs$ReadStream.prototype); + ReadStream.prototype.open = ReadStream$open; + } + var fs$WriteStream = fs$25.WriteStream; + if (fs$WriteStream) { + WriteStream.prototype = Object.create(fs$WriteStream.prototype); + WriteStream.prototype.open = WriteStream$open; + } + Object.defineProperty(fs$25, "ReadStream", { + get: function() { + return ReadStream; + }, + set: function(val) { + ReadStream = val; + }, + enumerable: true, + configurable: true + }); + Object.defineProperty(fs$25, "WriteStream", { + get: function() { + return WriteStream; + }, + set: function(val) { + WriteStream = val; + }, + enumerable: true, + configurable: true + }); + var FileReadStream = ReadStream; + Object.defineProperty(fs$25, "FileReadStream", { + get: function() { + return FileReadStream; + }, + set: function(val) { + FileReadStream = val; + }, + enumerable: true, + configurable: true + }); + var FileWriteStream = WriteStream; + Object.defineProperty(fs$25, "FileWriteStream", { + get: function() { + return FileWriteStream; + }, + set: function(val) { + FileWriteStream = val; + }, + enumerable: true, + configurable: true + }); + function ReadStream(path$28, options) { + if (this instanceof ReadStream) return fs$ReadStream.apply(this, arguments), this; + else return ReadStream.apply(Object.create(ReadStream.prototype), arguments); + } + function ReadStream$open() { + var that = this; + open(that.path, that.flags, that.mode, function(err, fd) { + if (err) { + if (that.autoClose) that.destroy(); + that.emit("error", err); + } else { + that.fd = fd; + that.emit("open", fd); + that.read(); + } + }); + } + function WriteStream(path$28, options) { + if (this instanceof WriteStream) return fs$WriteStream.apply(this, arguments), this; + else return WriteStream.apply(Object.create(WriteStream.prototype), arguments); + } + function WriteStream$open() { + var that = this; + open(that.path, that.flags, that.mode, function(err, fd) { + if (err) { + that.destroy(); + that.emit("error", err); + } else { + that.fd = fd; + that.emit("open", fd); + } + }); + } + function createReadStream(path$28, options) { + return new fs$25.ReadStream(path$28, options); + } + function createWriteStream(path$28, options) { + return new fs$25.WriteStream(path$28, options); + } + var fs$open = fs$25.open; + fs$25.open = open; + function open(path$28, flags, mode, cb$1) { + if (typeof mode === "function") cb$1 = mode, mode = null; + return go$open(path$28, flags, mode, cb$1); + function go$open(path$29, flags$1, mode$1, cb$2, startTime) { + return fs$open(path$29, flags$1, mode$1, function(err, fd) { + if (err && (err.code === "EMFILE" || err.code === "ENFILE")) enqueue([ + go$open, + [ + path$29, + flags$1, + mode$1, + cb$2 + ], + err, + startTime || Date.now(), + Date.now() + ]); + else if (typeof cb$2 === "function") cb$2.apply(this, arguments); + }); + } + } + return fs$25; + } + function enqueue(elem) { + debug$1("ENQUEUE", elem[0].name, elem[1]); + fs$24[gracefulQueue].push(elem); + retry(); + } + var retryTimer; + function resetQueue() { + var now = Date.now(); + for (var i$5 = 0; i$5 < fs$24[gracefulQueue].length; ++i$5) if (fs$24[gracefulQueue][i$5].length > 2) { + fs$24[gracefulQueue][i$5][3] = now; + fs$24[gracefulQueue][i$5][4] = now; + } + retry(); + } + function retry() { + clearTimeout(retryTimer); + retryTimer = void 0; + if (fs$24[gracefulQueue].length === 0) return; + var elem = fs$24[gracefulQueue].shift(); + var fn = elem[0]; + var args = elem[1]; + var err = elem[2]; + var startTime = elem[3]; + var lastTime = elem[4]; + if (startTime === void 0) { + debug$1("RETRY", fn.name, args); + fn.apply(null, args); + } else if (Date.now() - startTime >= 6e4) { + debug$1("TIMEOUT", fn.name, args); + var cb$1 = args.pop(); + if (typeof cb$1 === "function") cb$1.call(null, err); + } else { + var sinceAttempt = Date.now() - lastTime; + var sinceStart = Math.max(lastTime - startTime, 1); + var desiredDelay = Math.min(sinceStart * 1.2, 100); + if (sinceAttempt >= desiredDelay) { + debug$1("RETRY", fn.name, args); + fn.apply(null, args.concat([startTime])); + } else fs$24[gracefulQueue].push(elem); + } + if (retryTimer === void 0) retryTimer = setTimeout(retry, 0); + } +} }); + +//#endregion +//#region node_modules/fs-extra/lib/fs/index.js +var require_fs$1 = __commonJS({ "node_modules/fs-extra/lib/fs/index.js"(exports) { + const u$13 = require_universalify().fromCallback; + const fs$23 = require_graceful_fs(); + const api = [ + "access", + "appendFile", + "chmod", + "chown", + "close", + "copyFile", + "fchmod", + "fchown", + "fdatasync", + "fstat", + "fsync", + "ftruncate", + "futimes", + "lchmod", + "lchown", + "link", + "lstat", + "mkdir", + "mkdtemp", + "open", + "opendir", + "readdir", + "readFile", + "readlink", + "realpath", + "rename", + "rm", + "rmdir", + "stat", + "symlink", + "truncate", + "unlink", + "utimes", + "writeFile" + ].filter((key) => { + return typeof fs$23[key] === "function"; + }); + Object.keys(fs$23).forEach((key) => { + if (key === "promises") return; + exports[key] = fs$23[key]; + }); + api.forEach((method) => { + exports[method] = u$13(fs$23[method]); + }); + exports.exists = function(filename, callback) { + if (typeof callback === "function") return fs$23.exists(filename, callback); + return new Promise((resolve$5) => { + return fs$23.exists(filename, resolve$5); + }); + }; + exports.read = function(fd, buffer, offset, length, position, callback) { + if (typeof callback === "function") return fs$23.read(fd, buffer, offset, length, position, callback); + return new Promise((resolve$5, reject$1) => { + fs$23.read(fd, buffer, offset, length, position, (err, bytesRead, buffer$1) => { + if (err) return reject$1(err); + resolve$5({ + bytesRead, + buffer: buffer$1 + }); + }); + }); + }; + exports.write = function(fd, buffer, ...args) { + if (typeof args[args.length - 1] === "function") return fs$23.write(fd, buffer, ...args); + return new Promise((resolve$5, reject$1) => { + fs$23.write(fd, buffer, ...args, (err, bytesWritten, buffer$1) => { + if (err) return reject$1(err); + resolve$5({ + bytesWritten, + buffer: buffer$1 + }); + }); + }); + }; + if (typeof fs$23.writev === "function") exports.writev = function(fd, buffers, ...args) { + if (typeof args[args.length - 1] === "function") return fs$23.writev(fd, buffers, ...args); + return new Promise((resolve$5, reject$1) => { + fs$23.writev(fd, buffers, ...args, (err, bytesWritten, buffers$1) => { + if (err) return reject$1(err); + resolve$5({ + bytesWritten, + buffers: buffers$1 + }); + }); + }); + }; + if (typeof fs$23.realpath.native === "function") exports.realpath.native = u$13(fs$23.realpath.native); +} }); + +//#endregion +//#region node_modules/at-least-node/index.js +var require_at_least_node = __commonJS({ "node_modules/at-least-node/index.js"(exports, module) { + module.exports = (r) => { + const n$3 = process.versions.node.split(".").map((x$2) => parseInt(x$2, 10)); + r = r.split(".").map((x$2) => parseInt(x$2, 10)); + return n$3[0] > r[0] || n$3[0] === r[0] && (n$3[1] > r[1] || n$3[1] === r[1] && n$3[2] >= r[2]); + }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/mkdirs/make-dir.js +var require_make_dir = __commonJS({ "node_modules/fs-extra/lib/mkdirs/make-dir.js"(exports, module) { + const fs$22 = require_fs$1(); + const path$27 = __require("path"); + const atLeastNode$1 = require_at_least_node(); + const useNativeRecursiveOption = atLeastNode$1("10.12.0"); + const checkPath = (pth) => { + if (process.platform === "win32") { + const pathHasInvalidWinCharacters = /[<>:"|?*]/.test(pth.replace(path$27.parse(pth).root, "")); + if (pathHasInvalidWinCharacters) { + const error = new Error(`Path contains invalid characters: ${pth}`); + error.code = "EINVAL"; + throw error; + } + } + }; + const processOptions = (options) => { + const defaults$2 = { mode: 511 }; + if (typeof options === "number") options = { mode: options }; + return { + ...defaults$2, + ...options + }; + }; + const permissionError = (pth) => { + const error = new Error(`operation not permitted, mkdir '${pth}'`); + error.code = "EPERM"; + error.errno = -4048; + error.path = pth; + error.syscall = "mkdir"; + return error; + }; + module.exports.makeDir = async (input, options) => { + checkPath(input); + options = processOptions(options); + if (useNativeRecursiveOption) { + const pth = path$27.resolve(input); + return fs$22.mkdir(pth, { + mode: options.mode, + recursive: true + }); + } + const make$1 = async (pth) => { + try { + await fs$22.mkdir(pth, options.mode); + } catch (error) { + if (error.code === "EPERM") throw error; + if (error.code === "ENOENT") { + if (path$27.dirname(pth) === pth) throw permissionError(pth); + if (error.message.includes("null bytes")) throw error; + await make$1(path$27.dirname(pth)); + return make$1(pth); + } + try { + const stats = await fs$22.stat(pth); + if (!stats.isDirectory()) throw new Error("The path is not a directory"); + } catch { + throw error; + } + } + }; + return make$1(path$27.resolve(input)); + }; + module.exports.makeDirSync = (input, options) => { + checkPath(input); + options = processOptions(options); + if (useNativeRecursiveOption) { + const pth = path$27.resolve(input); + return fs$22.mkdirSync(pth, { + mode: options.mode, + recursive: true + }); + } + const make$1 = (pth) => { + try { + fs$22.mkdirSync(pth, options.mode); + } catch (error) { + if (error.code === "EPERM") throw error; + if (error.code === "ENOENT") { + if (path$27.dirname(pth) === pth) throw permissionError(pth); + if (error.message.includes("null bytes")) throw error; + make$1(path$27.dirname(pth)); + return make$1(pth); + } + try { + if (!fs$22.statSync(pth).isDirectory()) throw new Error("The path is not a directory"); + } catch { + throw error; + } + } + }; + return make$1(path$27.resolve(input)); + }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/mkdirs/index.js +var require_mkdirs = __commonJS({ "node_modules/fs-extra/lib/mkdirs/index.js"(exports, module) { + const u$12 = require_universalify().fromPromise; + const { makeDir: _makeDir, makeDirSync } = require_make_dir(); + const makeDir = u$12(_makeDir); + module.exports = { + mkdirs: makeDir, + mkdirsSync: makeDirSync, + mkdirp: makeDir, + mkdirpSync: makeDirSync, + ensureDir: makeDir, + ensureDirSync: makeDirSync + }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/util/utimes.js +var require_utimes = __commonJS({ "node_modules/fs-extra/lib/util/utimes.js"(exports, module) { + const fs$21 = require_graceful_fs(); + function utimesMillis$1(path$28, atime, mtime, callback) { + fs$21.open(path$28, "r+", (err, fd) => { + if (err) return callback(err); + fs$21.futimes(fd, atime, mtime, (futimesErr) => { + fs$21.close(fd, (closeErr) => { + if (callback) callback(futimesErr || closeErr); + }); + }); + }); + } + function utimesMillisSync$1(path$28, atime, mtime) { + const fd = fs$21.openSync(path$28, "r+"); + fs$21.futimesSync(fd, atime, mtime); + return fs$21.closeSync(fd); + } + module.exports = { + utimesMillis: utimesMillis$1, + utimesMillisSync: utimesMillisSync$1 + }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/util/stat.js +var require_stat = __commonJS({ "node_modules/fs-extra/lib/util/stat.js"(exports, module) { + const fs$20 = require_fs$1(); + const path$26 = __require("path"); + const util$7 = __require("util"); + const atLeastNode = require_at_least_node(); + const nodeSupportsBigInt = atLeastNode("10.5.0"); + const stat$4 = (file$2) => nodeSupportsBigInt ? fs$20.stat(file$2, { bigint: true }) : fs$20.stat(file$2); + const statSync = (file$2) => nodeSupportsBigInt ? fs$20.statSync(file$2, { bigint: true }) : fs$20.statSync(file$2); + function getStats$2(src, dest) { + return Promise.all([stat$4(src), stat$4(dest).catch((err) => { + if (err.code === "ENOENT") return null; + throw err; + })]).then(([srcStat, destStat]) => ({ + srcStat, + destStat + })); + } + function getStatsSync(src, dest) { + let destStat; + const srcStat = statSync(src); + try { + destStat = statSync(dest); + } catch (err) { + if (err.code === "ENOENT") return { + srcStat, + destStat: null + }; + throw err; + } + return { + srcStat, + destStat + }; + } + function checkPaths(src, dest, funcName, cb$1) { + util$7.callbackify(getStats$2)(src, dest, (err, stats) => { + if (err) return cb$1(err); + const { srcStat, destStat } = stats; + if (destStat && areIdentical(srcStat, destStat)) return cb$1(new Error("Source and destination must not be the same.")); + if (srcStat.isDirectory() && isSrcSubdir(src, dest)) return cb$1(new Error(errMsg(src, dest, funcName))); + return cb$1(null, { + srcStat, + destStat + }); + }); + } + function checkPathsSync(src, dest, funcName) { + const { srcStat, destStat } = getStatsSync(src, dest); + if (destStat && areIdentical(srcStat, destStat)) throw new Error("Source and destination must not be the same."); + if (srcStat.isDirectory() && isSrcSubdir(src, dest)) throw new Error(errMsg(src, dest, funcName)); + return { + srcStat, + destStat + }; + } + function checkParentPaths(src, srcStat, dest, funcName, cb$1) { + const srcParent = path$26.resolve(path$26.dirname(src)); + const destParent = path$26.resolve(path$26.dirname(dest)); + if (destParent === srcParent || destParent === path$26.parse(destParent).root) return cb$1(); + const callback = (err, destStat) => { + if (err) { + if (err.code === "ENOENT") return cb$1(); + return cb$1(err); + } + if (areIdentical(srcStat, destStat)) return cb$1(new Error(errMsg(src, dest, funcName))); + return checkParentPaths(src, srcStat, destParent, funcName, cb$1); + }; + if (nodeSupportsBigInt) fs$20.stat(destParent, { bigint: true }, callback); + else fs$20.stat(destParent, callback); + } + function checkParentPathsSync(src, srcStat, dest, funcName) { + const srcParent = path$26.resolve(path$26.dirname(src)); + const destParent = path$26.resolve(path$26.dirname(dest)); + if (destParent === srcParent || destParent === path$26.parse(destParent).root) return; + let destStat; + try { + destStat = statSync(destParent); + } catch (err) { + if (err.code === "ENOENT") return; + throw err; + } + if (areIdentical(srcStat, destStat)) throw new Error(errMsg(src, dest, funcName)); + return checkParentPathsSync(src, srcStat, destParent, funcName); + } + function areIdentical(srcStat, destStat) { + if (destStat.ino && destStat.dev && destStat.ino === srcStat.ino && destStat.dev === srcStat.dev) { + if (nodeSupportsBigInt || destStat.ino < Number.MAX_SAFE_INTEGER) return true; + if (destStat.size === srcStat.size && destStat.mode === srcStat.mode && destStat.nlink === srcStat.nlink && destStat.atimeMs === srcStat.atimeMs && destStat.mtimeMs === srcStat.mtimeMs && destStat.ctimeMs === srcStat.ctimeMs && destStat.birthtimeMs === srcStat.birthtimeMs) return true; + } + return false; + } + function isSrcSubdir(src, dest) { + const srcArr = path$26.resolve(src).split(path$26.sep).filter((i$5) => i$5); + const destArr = path$26.resolve(dest).split(path$26.sep).filter((i$5) => i$5); + return srcArr.reduce((acc, cur, i$5) => acc && destArr[i$5] === cur, true); + } + function errMsg(src, dest, funcName) { + return `Cannot ${funcName} '${src}' to a subdirectory of itself, '${dest}'.`; + } + module.exports = { + checkPaths, + checkPathsSync, + checkParentPaths, + checkParentPathsSync, + isSrcSubdir + }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/copy-sync/copy-sync.js +var require_copy_sync$1 = __commonJS({ "node_modules/fs-extra/lib/copy-sync/copy-sync.js"(exports, module) { + const fs$19 = require_graceful_fs(); + const path$25 = __require("path"); + const mkdirsSync$1 = require_mkdirs().mkdirsSync; + const utimesMillisSync = require_utimes().utimesMillisSync; + const stat$3 = require_stat(); + function copySync$1(src, dest, opts) { + if (typeof opts === "function") opts = { filter: opts }; + opts = opts || {}; + opts.clobber = "clobber" in opts ? !!opts.clobber : true; + opts.overwrite = "overwrite" in opts ? !!opts.overwrite : opts.clobber; + if (opts.preserveTimestamps && process.arch === "ia32") console.warn(`fs-extra: Using the preserveTimestamps option in 32-bit node is not recommended;\n + see https://github.com/jprichardson/node-fs-extra/issues/269`); + const { srcStat, destStat } = stat$3.checkPathsSync(src, dest, "copy"); + stat$3.checkParentPathsSync(src, srcStat, dest, "copy"); + return handleFilterAndCopy(destStat, src, dest, opts); + } + function handleFilterAndCopy(destStat, src, dest, opts) { + if (opts.filter && !opts.filter(src, dest)) return; + const destParent = path$25.dirname(dest); + if (!fs$19.existsSync(destParent)) mkdirsSync$1(destParent); + return startCopy$1(destStat, src, dest, opts); + } + function startCopy$1(destStat, src, dest, opts) { + if (opts.filter && !opts.filter(src, dest)) return; + return getStats$1(destStat, src, dest, opts); + } + function getStats$1(destStat, src, dest, opts) { + const statSync$1 = opts.dereference ? fs$19.statSync : fs$19.lstatSync; + const srcStat = statSync$1(src); + if (srcStat.isDirectory()) return onDir$1(srcStat, destStat, src, dest, opts); + else if (srcStat.isFile() || srcStat.isCharacterDevice() || srcStat.isBlockDevice()) return onFile$1(srcStat, destStat, src, dest, opts); + else if (srcStat.isSymbolicLink()) return onLink$1(destStat, src, dest, opts); + } + function onFile$1(srcStat, destStat, src, dest, opts) { + if (!destStat) return copyFile$1(srcStat, src, dest, opts); + return mayCopyFile$1(srcStat, src, dest, opts); + } + function mayCopyFile$1(srcStat, src, dest, opts) { + if (opts.overwrite) { + fs$19.unlinkSync(dest); + return copyFile$1(srcStat, src, dest, opts); + } else if (opts.errorOnExist) throw new Error(`'${dest}' already exists`); + } + function copyFile$1(srcStat, src, dest, opts) { + fs$19.copyFileSync(src, dest); + if (opts.preserveTimestamps) handleTimestamps(srcStat.mode, src, dest); + return setDestMode$1(dest, srcStat.mode); + } + function handleTimestamps(srcMode, src, dest) { + if (fileIsNotWritable$1(srcMode)) makeFileWritable$1(dest, srcMode); + return setDestTimestamps$1(src, dest); + } + function fileIsNotWritable$1(srcMode) { + return (srcMode & 128) === 0; + } + function makeFileWritable$1(dest, srcMode) { + return setDestMode$1(dest, srcMode | 128); + } + function setDestMode$1(dest, srcMode) { + return fs$19.chmodSync(dest, srcMode); + } + function setDestTimestamps$1(src, dest) { + const updatedSrcStat = fs$19.statSync(src); + return utimesMillisSync(dest, updatedSrcStat.atime, updatedSrcStat.mtime); + } + function onDir$1(srcStat, destStat, src, dest, opts) { + if (!destStat) return mkDirAndCopy$1(srcStat.mode, src, dest, opts); + if (destStat && !destStat.isDirectory()) throw new Error(`Cannot overwrite non-directory '${dest}' with directory '${src}'.`); + return copyDir$1(src, dest, opts); + } + function mkDirAndCopy$1(srcMode, src, dest, opts) { + fs$19.mkdirSync(dest); + copyDir$1(src, dest, opts); + return setDestMode$1(dest, srcMode); + } + function copyDir$1(src, dest, opts) { + fs$19.readdirSync(src).forEach((item) => copyDirItem$1(item, src, dest, opts)); + } + function copyDirItem$1(item, src, dest, opts) { + const srcItem = path$25.join(src, item); + const destItem = path$25.join(dest, item); + const { destStat } = stat$3.checkPathsSync(srcItem, destItem, "copy"); + return startCopy$1(destStat, srcItem, destItem, opts); + } + function onLink$1(destStat, src, dest, opts) { + let resolvedSrc = fs$19.readlinkSync(src); + if (opts.dereference) resolvedSrc = path$25.resolve(process.cwd(), resolvedSrc); + if (!destStat) return fs$19.symlinkSync(resolvedSrc, dest); + else { + let resolvedDest; + try { + resolvedDest = fs$19.readlinkSync(dest); + } catch (err) { + if (err.code === "EINVAL" || err.code === "UNKNOWN") return fs$19.symlinkSync(resolvedSrc, dest); + throw err; + } + if (opts.dereference) resolvedDest = path$25.resolve(process.cwd(), resolvedDest); + if (stat$3.isSrcSubdir(resolvedSrc, resolvedDest)) throw new Error(`Cannot copy '${resolvedSrc}' to a subdirectory of itself, '${resolvedDest}'.`); + if (fs$19.statSync(dest).isDirectory() && stat$3.isSrcSubdir(resolvedDest, resolvedSrc)) throw new Error(`Cannot overwrite '${resolvedDest}' with '${resolvedSrc}'.`); + return copyLink$1(resolvedSrc, dest); + } + } + function copyLink$1(resolvedSrc, dest) { + fs$19.unlinkSync(dest); + return fs$19.symlinkSync(resolvedSrc, dest); + } + module.exports = copySync$1; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/copy-sync/index.js +var require_copy_sync = __commonJS({ "node_modules/fs-extra/lib/copy-sync/index.js"(exports, module) { + module.exports = { copySync: require_copy_sync$1() }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/path-exists/index.js +var require_path_exists = __commonJS({ "node_modules/fs-extra/lib/path-exists/index.js"(exports, module) { + const u$11 = require_universalify().fromPromise; + const fs$18 = require_fs$1(); + function pathExists$6(path$28) { + return fs$18.access(path$28).then(() => true).catch(() => false); + } + module.exports = { + pathExists: u$11(pathExists$6), + pathExistsSync: fs$18.existsSync + }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/copy/copy.js +var require_copy$1 = __commonJS({ "node_modules/fs-extra/lib/copy/copy.js"(exports, module) { + const fs$17 = require_graceful_fs(); + const path$24 = __require("path"); + const mkdirs$1 = require_mkdirs().mkdirs; + const pathExists$5 = require_path_exists().pathExists; + const utimesMillis = require_utimes().utimesMillis; + const stat$2 = require_stat(); + function copy$1(src, dest, opts, cb$1) { + if (typeof opts === "function" && !cb$1) { + cb$1 = opts; + opts = {}; + } else if (typeof opts === "function") opts = { filter: opts }; + cb$1 = cb$1 || function() {}; + opts = opts || {}; + opts.clobber = "clobber" in opts ? !!opts.clobber : true; + opts.overwrite = "overwrite" in opts ? !!opts.overwrite : opts.clobber; + if (opts.preserveTimestamps && process.arch === "ia32") console.warn(`fs-extra: Using the preserveTimestamps option in 32-bit node is not recommended;\n + see https://github.com/jprichardson/node-fs-extra/issues/269`); + stat$2.checkPaths(src, dest, "copy", (err, stats) => { + if (err) return cb$1(err); + const { srcStat, destStat } = stats; + stat$2.checkParentPaths(src, srcStat, dest, "copy", (err$1) => { + if (err$1) return cb$1(err$1); + if (opts.filter) return handleFilter(checkParentDir, destStat, src, dest, opts, cb$1); + return checkParentDir(destStat, src, dest, opts, cb$1); + }); + }); + } + function checkParentDir(destStat, src, dest, opts, cb$1) { + const destParent = path$24.dirname(dest); + pathExists$5(destParent, (err, dirExists) => { + if (err) return cb$1(err); + if (dirExists) return startCopy(destStat, src, dest, opts, cb$1); + mkdirs$1(destParent, (err$1) => { + if (err$1) return cb$1(err$1); + return startCopy(destStat, src, dest, opts, cb$1); + }); + }); + } + function handleFilter(onInclude, destStat, src, dest, opts, cb$1) { + Promise.resolve(opts.filter(src, dest)).then((include) => { + if (include) return onInclude(destStat, src, dest, opts, cb$1); + return cb$1(); + }, (error) => cb$1(error)); + } + function startCopy(destStat, src, dest, opts, cb$1) { + if (opts.filter) return handleFilter(getStats, destStat, src, dest, opts, cb$1); + return getStats(destStat, src, dest, opts, cb$1); + } + function getStats(destStat, src, dest, opts, cb$1) { + const stat$5 = opts.dereference ? fs$17.stat : fs$17.lstat; + stat$5(src, (err, srcStat) => { + if (err) return cb$1(err); + if (srcStat.isDirectory()) return onDir(srcStat, destStat, src, dest, opts, cb$1); + else if (srcStat.isFile() || srcStat.isCharacterDevice() || srcStat.isBlockDevice()) return onFile(srcStat, destStat, src, dest, opts, cb$1); + else if (srcStat.isSymbolicLink()) return onLink(destStat, src, dest, opts, cb$1); + }); + } + function onFile(srcStat, destStat, src, dest, opts, cb$1) { + if (!destStat) return copyFile(srcStat, src, dest, opts, cb$1); + return mayCopyFile(srcStat, src, dest, opts, cb$1); + } + function mayCopyFile(srcStat, src, dest, opts, cb$1) { + if (opts.overwrite) fs$17.unlink(dest, (err) => { + if (err) return cb$1(err); + return copyFile(srcStat, src, dest, opts, cb$1); + }); + else if (opts.errorOnExist) return cb$1(new Error(`'${dest}' already exists`)); + else return cb$1(); + } + function copyFile(srcStat, src, dest, opts, cb$1) { + fs$17.copyFile(src, dest, (err) => { + if (err) return cb$1(err); + if (opts.preserveTimestamps) return handleTimestampsAndMode(srcStat.mode, src, dest, cb$1); + return setDestMode(dest, srcStat.mode, cb$1); + }); + } + function handleTimestampsAndMode(srcMode, src, dest, cb$1) { + if (fileIsNotWritable(srcMode)) return makeFileWritable(dest, srcMode, (err) => { + if (err) return cb$1(err); + return setDestTimestampsAndMode(srcMode, src, dest, cb$1); + }); + return setDestTimestampsAndMode(srcMode, src, dest, cb$1); + } + function fileIsNotWritable(srcMode) { + return (srcMode & 128) === 0; + } + function makeFileWritable(dest, srcMode, cb$1) { + return setDestMode(dest, srcMode | 128, cb$1); + } + function setDestTimestampsAndMode(srcMode, src, dest, cb$1) { + setDestTimestamps(src, dest, (err) => { + if (err) return cb$1(err); + return setDestMode(dest, srcMode, cb$1); + }); + } + function setDestMode(dest, srcMode, cb$1) { + return fs$17.chmod(dest, srcMode, cb$1); + } + function setDestTimestamps(src, dest, cb$1) { + fs$17.stat(src, (err, updatedSrcStat) => { + if (err) return cb$1(err); + return utimesMillis(dest, updatedSrcStat.atime, updatedSrcStat.mtime, cb$1); + }); + } + function onDir(srcStat, destStat, src, dest, opts, cb$1) { + if (!destStat) return mkDirAndCopy(srcStat.mode, src, dest, opts, cb$1); + if (destStat && !destStat.isDirectory()) return cb$1(new Error(`Cannot overwrite non-directory '${dest}' with directory '${src}'.`)); + return copyDir(src, dest, opts, cb$1); + } + function mkDirAndCopy(srcMode, src, dest, opts, cb$1) { + fs$17.mkdir(dest, (err) => { + if (err) return cb$1(err); + copyDir(src, dest, opts, (err$1) => { + if (err$1) return cb$1(err$1); + return setDestMode(dest, srcMode, cb$1); + }); + }); + } + function copyDir(src, dest, opts, cb$1) { + fs$17.readdir(src, (err, items) => { + if (err) return cb$1(err); + return copyDirItems(items, src, dest, opts, cb$1); + }); + } + function copyDirItems(items, src, dest, opts, cb$1) { + const item = items.pop(); + if (!item) return cb$1(); + return copyDirItem(items, item, src, dest, opts, cb$1); + } + function copyDirItem(items, item, src, dest, opts, cb$1) { + const srcItem = path$24.join(src, item); + const destItem = path$24.join(dest, item); + stat$2.checkPaths(srcItem, destItem, "copy", (err, stats) => { + if (err) return cb$1(err); + const { destStat } = stats; + startCopy(destStat, srcItem, destItem, opts, (err$1) => { + if (err$1) return cb$1(err$1); + return copyDirItems(items, src, dest, opts, cb$1); + }); + }); + } + function onLink(destStat, src, dest, opts, cb$1) { + fs$17.readlink(src, (err, resolvedSrc) => { + if (err) return cb$1(err); + if (opts.dereference) resolvedSrc = path$24.resolve(process.cwd(), resolvedSrc); + if (!destStat) return fs$17.symlink(resolvedSrc, dest, cb$1); + else fs$17.readlink(dest, (err$1, resolvedDest) => { + if (err$1) { + if (err$1.code === "EINVAL" || err$1.code === "UNKNOWN") return fs$17.symlink(resolvedSrc, dest, cb$1); + return cb$1(err$1); + } + if (opts.dereference) resolvedDest = path$24.resolve(process.cwd(), resolvedDest); + if (stat$2.isSrcSubdir(resolvedSrc, resolvedDest)) return cb$1(new Error(`Cannot copy '${resolvedSrc}' to a subdirectory of itself, '${resolvedDest}'.`)); + if (destStat.isDirectory() && stat$2.isSrcSubdir(resolvedDest, resolvedSrc)) return cb$1(new Error(`Cannot overwrite '${resolvedDest}' with '${resolvedSrc}'.`)); + return copyLink(resolvedSrc, dest, cb$1); + }); + }); + } + function copyLink(resolvedSrc, dest, cb$1) { + fs$17.unlink(dest, (err) => { + if (err) return cb$1(err); + return fs$17.symlink(resolvedSrc, dest, cb$1); + }); + } + module.exports = copy$1; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/copy/index.js +var require_copy = __commonJS({ "node_modules/fs-extra/lib/copy/index.js"(exports, module) { + const u$10 = require_universalify().fromCallback; + module.exports = { copy: u$10(require_copy$1()) }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/remove/rimraf.js +var require_rimraf = __commonJS({ "node_modules/fs-extra/lib/remove/rimraf.js"(exports, module) { + const fs$16 = require_graceful_fs(); + const path$23 = __require("path"); + const assert$5 = __require("assert"); + const isWindows$2 = process.platform === "win32"; + function defaults$1(options) { + const methods$1 = [ + "unlink", + "chmod", + "stat", + "lstat", + "rmdir", + "readdir" + ]; + methods$1.forEach((m$2) => { + options[m$2] = options[m$2] || fs$16[m$2]; + m$2 = m$2 + "Sync"; + options[m$2] = options[m$2] || fs$16[m$2]; + }); + options.maxBusyTries = options.maxBusyTries || 3; + } + function rimraf$1(p$1, options, cb$1) { + let busyTries = 0; + if (typeof options === "function") { + cb$1 = options; + options = {}; + } + assert$5(p$1, "rimraf: missing path"); + assert$5.strictEqual(typeof p$1, "string", "rimraf: path should be a string"); + assert$5.strictEqual(typeof cb$1, "function", "rimraf: callback function required"); + assert$5(options, "rimraf: invalid options argument provided"); + assert$5.strictEqual(typeof options, "object", "rimraf: options should be object"); + defaults$1(options); + rimraf_(p$1, options, function CB(er) { + if (er) { + if ((er.code === "EBUSY" || er.code === "ENOTEMPTY" || er.code === "EPERM") && busyTries < options.maxBusyTries) { + busyTries++; + const time = busyTries * 100; + return setTimeout(() => rimraf_(p$1, options, CB), time); + } + if (er.code === "ENOENT") er = null; + } + cb$1(er); + }); + } + function rimraf_(p$1, options, cb$1) { + assert$5(p$1); + assert$5(options); + assert$5(typeof cb$1 === "function"); + options.lstat(p$1, (er, st) => { + if (er && er.code === "ENOENT") return cb$1(null); + if (er && er.code === "EPERM" && isWindows$2) return fixWinEPERM(p$1, options, er, cb$1); + if (st && st.isDirectory()) return rmdir(p$1, options, er, cb$1); + options.unlink(p$1, (er$1) => { + if (er$1) { + if (er$1.code === "ENOENT") return cb$1(null); + if (er$1.code === "EPERM") return isWindows$2 ? fixWinEPERM(p$1, options, er$1, cb$1) : rmdir(p$1, options, er$1, cb$1); + if (er$1.code === "EISDIR") return rmdir(p$1, options, er$1, cb$1); + } + return cb$1(er$1); + }); + }); + } + function fixWinEPERM(p$1, options, er, cb$1) { + assert$5(p$1); + assert$5(options); + assert$5(typeof cb$1 === "function"); + options.chmod(p$1, 438, (er2) => { + if (er2) cb$1(er2.code === "ENOENT" ? null : er); + else options.stat(p$1, (er3, stats) => { + if (er3) cb$1(er3.code === "ENOENT" ? null : er); + else if (stats.isDirectory()) rmdir(p$1, options, er, cb$1); + else options.unlink(p$1, cb$1); + }); + }); + } + function fixWinEPERMSync(p$1, options, er) { + let stats; + assert$5(p$1); + assert$5(options); + try { + options.chmodSync(p$1, 438); + } catch (er2) { + if (er2.code === "ENOENT") return; + else throw er; + } + try { + stats = options.statSync(p$1); + } catch (er3) { + if (er3.code === "ENOENT") return; + else throw er; + } + if (stats.isDirectory()) rmdirSync(p$1, options, er); + else options.unlinkSync(p$1); + } + function rmdir(p$1, options, originalEr, cb$1) { + assert$5(p$1); + assert$5(options); + assert$5(typeof cb$1 === "function"); + options.rmdir(p$1, (er) => { + if (er && (er.code === "ENOTEMPTY" || er.code === "EEXIST" || er.code === "EPERM")) rmkids(p$1, options, cb$1); + else if (er && er.code === "ENOTDIR") cb$1(originalEr); + else cb$1(er); + }); + } + function rmkids(p$1, options, cb$1) { + assert$5(p$1); + assert$5(options); + assert$5(typeof cb$1 === "function"); + options.readdir(p$1, (er, files) => { + if (er) return cb$1(er); + let n$3 = files.length; + let errState; + if (n$3 === 0) return options.rmdir(p$1, cb$1); + files.forEach((f$1) => { + rimraf$1(path$23.join(p$1, f$1), options, (er$1) => { + if (errState) return; + if (er$1) return cb$1(errState = er$1); + if (--n$3 === 0) options.rmdir(p$1, cb$1); + }); + }); + }); + } + function rimrafSync(p$1, options) { + let st; + options = options || {}; + defaults$1(options); + assert$5(p$1, "rimraf: missing path"); + assert$5.strictEqual(typeof p$1, "string", "rimraf: path should be a string"); + assert$5(options, "rimraf: missing options"); + assert$5.strictEqual(typeof options, "object", "rimraf: options should be object"); + try { + st = options.lstatSync(p$1); + } catch (er) { + if (er.code === "ENOENT") return; + if (er.code === "EPERM" && isWindows$2) fixWinEPERMSync(p$1, options, er); + } + try { + if (st && st.isDirectory()) rmdirSync(p$1, options, null); + else options.unlinkSync(p$1); + } catch (er) { + if (er.code === "ENOENT") return; + else if (er.code === "EPERM") return isWindows$2 ? fixWinEPERMSync(p$1, options, er) : rmdirSync(p$1, options, er); + else if (er.code !== "EISDIR") throw er; + rmdirSync(p$1, options, er); + } + } + function rmdirSync(p$1, options, originalEr) { + assert$5(p$1); + assert$5(options); + try { + options.rmdirSync(p$1); + } catch (er) { + if (er.code === "ENOTDIR") throw originalEr; + else if (er.code === "ENOTEMPTY" || er.code === "EEXIST" || er.code === "EPERM") rmkidsSync(p$1, options); + else if (er.code !== "ENOENT") throw er; + } + } + function rmkidsSync(p$1, options) { + assert$5(p$1); + assert$5(options); + options.readdirSync(p$1).forEach((f$1) => rimrafSync(path$23.join(p$1, f$1), options)); + if (isWindows$2) { + const startTime = Date.now(); + do + try { + const ret = options.rmdirSync(p$1, options); + return ret; + } catch {} + while (Date.now() - startTime < 500); + } else { + const ret = options.rmdirSync(p$1, options); + return ret; + } + } + module.exports = rimraf$1; + rimraf$1.sync = rimrafSync; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/remove/index.js +var require_remove = __commonJS({ "node_modules/fs-extra/lib/remove/index.js"(exports, module) { + const u$9 = require_universalify().fromCallback; + const rimraf = require_rimraf(); + module.exports = { + remove: u$9(rimraf), + removeSync: rimraf.sync + }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/empty/index.js +var require_empty = __commonJS({ "node_modules/fs-extra/lib/empty/index.js"(exports, module) { + const u$8 = require_universalify().fromCallback; + const fs$15 = require_graceful_fs(); + const path$22 = __require("path"); + const mkdir$3 = require_mkdirs(); + const remove$3 = require_remove(); + const emptyDir = u$8(function emptyDir$1(dir, callback) { + callback = callback || function() {}; + fs$15.readdir(dir, (err, items) => { + if (err) return mkdir$3.mkdirs(dir, callback); + items = items.map((item) => path$22.join(dir, item)); + deleteItem(); + function deleteItem() { + const item = items.pop(); + if (!item) return callback(); + remove$3.remove(item, (err$1) => { + if (err$1) return callback(err$1); + deleteItem(); + }); + } + }); + }); + function emptyDirSync(dir) { + let items; + try { + items = fs$15.readdirSync(dir); + } catch { + return mkdir$3.mkdirsSync(dir); + } + items.forEach((item) => { + item = path$22.join(dir, item); + remove$3.removeSync(item); + }); + } + module.exports = { + emptyDirSync, + emptydirSync: emptyDirSync, + emptyDir, + emptydir: emptyDir + }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/ensure/file.js +var require_file = __commonJS({ "node_modules/fs-extra/lib/ensure/file.js"(exports, module) { + const u$7 = require_universalify().fromCallback; + const path$21 = __require("path"); + const fs$14 = require_graceful_fs(); + const mkdir$2 = require_mkdirs(); + function createFile(file$2, callback) { + function makeFile() { + fs$14.writeFile(file$2, "", (err) => { + if (err) return callback(err); + callback(); + }); + } + fs$14.stat(file$2, (err, stats) => { + if (!err && stats.isFile()) return callback(); + const dir = path$21.dirname(file$2); + fs$14.stat(dir, (err$1, stats$1) => { + if (err$1) { + if (err$1.code === "ENOENT") return mkdir$2.mkdirs(dir, (err$2) => { + if (err$2) return callback(err$2); + makeFile(); + }); + return callback(err$1); + } + if (stats$1.isDirectory()) makeFile(); + else fs$14.readdir(dir, (err$2) => { + if (err$2) return callback(err$2); + }); + }); + }); + } + function createFileSync(file$2) { + let stats; + try { + stats = fs$14.statSync(file$2); + } catch {} + if (stats && stats.isFile()) return; + const dir = path$21.dirname(file$2); + try { + if (!fs$14.statSync(dir).isDirectory()) fs$14.readdirSync(dir); + } catch (err) { + if (err && err.code === "ENOENT") mkdir$2.mkdirsSync(dir); + else throw err; + } + fs$14.writeFileSync(file$2, ""); + } + module.exports = { + createFile: u$7(createFile), + createFileSync + }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/ensure/link.js +var require_link = __commonJS({ "node_modules/fs-extra/lib/ensure/link.js"(exports, module) { + const u$6 = require_universalify().fromCallback; + const path$20 = __require("path"); + const fs$13 = require_graceful_fs(); + const mkdir$1 = require_mkdirs(); + const pathExists$4 = require_path_exists().pathExists; + function createLink(srcpath, dstpath, callback) { + function makeLink(srcpath$1, dstpath$1) { + fs$13.link(srcpath$1, dstpath$1, (err) => { + if (err) return callback(err); + callback(null); + }); + } + pathExists$4(dstpath, (err, destinationExists) => { + if (err) return callback(err); + if (destinationExists) return callback(null); + fs$13.lstat(srcpath, (err$1) => { + if (err$1) { + err$1.message = err$1.message.replace("lstat", "ensureLink"); + return callback(err$1); + } + const dir = path$20.dirname(dstpath); + pathExists$4(dir, (err$2, dirExists) => { + if (err$2) return callback(err$2); + if (dirExists) return makeLink(srcpath, dstpath); + mkdir$1.mkdirs(dir, (err$3) => { + if (err$3) return callback(err$3); + makeLink(srcpath, dstpath); + }); + }); + }); + }); + } + function createLinkSync(srcpath, dstpath) { + const destinationExists = fs$13.existsSync(dstpath); + if (destinationExists) return void 0; + try { + fs$13.lstatSync(srcpath); + } catch (err) { + err.message = err.message.replace("lstat", "ensureLink"); + throw err; + } + const dir = path$20.dirname(dstpath); + const dirExists = fs$13.existsSync(dir); + if (dirExists) return fs$13.linkSync(srcpath, dstpath); + mkdir$1.mkdirsSync(dir); + return fs$13.linkSync(srcpath, dstpath); + } + module.exports = { + createLink: u$6(createLink), + createLinkSync + }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/ensure/symlink-paths.js +var require_symlink_paths = __commonJS({ "node_modules/fs-extra/lib/ensure/symlink-paths.js"(exports, module) { + const path$19 = __require("path"); + const fs$12 = require_graceful_fs(); + const pathExists$3 = require_path_exists().pathExists; + /** + * Function that returns two types of paths, one relative to symlink, and one + * relative to the current working directory. Checks if path is absolute or + * relative. If the path is relative, this function checks if the path is + * relative to symlink or relative to current working directory. This is an + * initiative to find a smarter `srcpath` to supply when building symlinks. + * This allows you to determine which path to use out of one of three possible + * types of source paths. The first is an absolute path. This is detected by + * `path.isAbsolute()`. When an absolute path is provided, it is checked to + * see if it exists. If it does it's used, if not an error is returned + * (callback)/ thrown (sync). The other two options for `srcpath` are a + * relative url. By default Node's `fs.symlink` works by creating a symlink + * using `dstpath` and expects the `srcpath` to be relative to the newly + * created symlink. If you provide a `srcpath` that does not exist on the file + * system it results in a broken symlink. To minimize this, the function + * checks to see if the 'relative to symlink' source file exists, and if it + * does it will use it. If it does not, it checks if there's a file that + * exists that is relative to the current working directory, if does its used. + * This preserves the expectations of the original fs.symlink spec and adds + * the ability to pass in `relative to current working direcotry` paths. + */ + function symlinkPaths$1(srcpath, dstpath, callback) { + if (path$19.isAbsolute(srcpath)) return fs$12.lstat(srcpath, (err) => { + if (err) { + err.message = err.message.replace("lstat", "ensureSymlink"); + return callback(err); + } + return callback(null, { + toCwd: srcpath, + toDst: srcpath + }); + }); + else { + const dstdir = path$19.dirname(dstpath); + const relativeToDst = path$19.join(dstdir, srcpath); + return pathExists$3(relativeToDst, (err, exists) => { + if (err) return callback(err); + if (exists) return callback(null, { + toCwd: relativeToDst, + toDst: srcpath + }); + else return fs$12.lstat(srcpath, (err$1) => { + if (err$1) { + err$1.message = err$1.message.replace("lstat", "ensureSymlink"); + return callback(err$1); + } + return callback(null, { + toCwd: srcpath, + toDst: path$19.relative(dstdir, srcpath) + }); + }); + }); + } + } + function symlinkPathsSync$1(srcpath, dstpath) { + let exists; + if (path$19.isAbsolute(srcpath)) { + exists = fs$12.existsSync(srcpath); + if (!exists) throw new Error("absolute srcpath does not exist"); + return { + toCwd: srcpath, + toDst: srcpath + }; + } else { + const dstdir = path$19.dirname(dstpath); + const relativeToDst = path$19.join(dstdir, srcpath); + exists = fs$12.existsSync(relativeToDst); + if (exists) return { + toCwd: relativeToDst, + toDst: srcpath + }; + else { + exists = fs$12.existsSync(srcpath); + if (!exists) throw new Error("relative srcpath does not exist"); + return { + toCwd: srcpath, + toDst: path$19.relative(dstdir, srcpath) + }; + } + } + } + module.exports = { + symlinkPaths: symlinkPaths$1, + symlinkPathsSync: symlinkPathsSync$1 + }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/ensure/symlink-type.js +var require_symlink_type = __commonJS({ "node_modules/fs-extra/lib/ensure/symlink-type.js"(exports, module) { + const fs$11 = require_graceful_fs(); + function symlinkType$1(srcpath, type, callback) { + callback = typeof type === "function" ? type : callback; + type = typeof type === "function" ? false : type; + if (type) return callback(null, type); + fs$11.lstat(srcpath, (err, stats) => { + if (err) return callback(null, "file"); + type = stats && stats.isDirectory() ? "dir" : "file"; + callback(null, type); + }); + } + function symlinkTypeSync$1(srcpath, type) { + let stats; + if (type) return type; + try { + stats = fs$11.lstatSync(srcpath); + } catch { + return "file"; + } + return stats && stats.isDirectory() ? "dir" : "file"; + } + module.exports = { + symlinkType: symlinkType$1, + symlinkTypeSync: symlinkTypeSync$1 + }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/ensure/symlink.js +var require_symlink = __commonJS({ "node_modules/fs-extra/lib/ensure/symlink.js"(exports, module) { + const u$5 = require_universalify().fromCallback; + const path$18 = __require("path"); + const fs$10 = require_graceful_fs(); + const _mkdirs = require_mkdirs(); + const mkdirs = _mkdirs.mkdirs; + const mkdirsSync = _mkdirs.mkdirsSync; + const _symlinkPaths = require_symlink_paths(); + const symlinkPaths = _symlinkPaths.symlinkPaths; + const symlinkPathsSync = _symlinkPaths.symlinkPathsSync; + const _symlinkType = require_symlink_type(); + const symlinkType = _symlinkType.symlinkType; + const symlinkTypeSync = _symlinkType.symlinkTypeSync; + const pathExists$2 = require_path_exists().pathExists; + function createSymlink(srcpath, dstpath, type, callback) { + callback = typeof type === "function" ? type : callback; + type = typeof type === "function" ? false : type; + pathExists$2(dstpath, (err, destinationExists) => { + if (err) return callback(err); + if (destinationExists) return callback(null); + symlinkPaths(srcpath, dstpath, (err$1, relative$2) => { + if (err$1) return callback(err$1); + srcpath = relative$2.toDst; + symlinkType(relative$2.toCwd, type, (err$2, type$1) => { + if (err$2) return callback(err$2); + const dir = path$18.dirname(dstpath); + pathExists$2(dir, (err$3, dirExists) => { + if (err$3) return callback(err$3); + if (dirExists) return fs$10.symlink(srcpath, dstpath, type$1, callback); + mkdirs(dir, (err$4) => { + if (err$4) return callback(err$4); + fs$10.symlink(srcpath, dstpath, type$1, callback); + }); + }); + }); + }); + }); + } + function createSymlinkSync(srcpath, dstpath, type) { + const destinationExists = fs$10.existsSync(dstpath); + if (destinationExists) return void 0; + const relative$2 = symlinkPathsSync(srcpath, dstpath); + srcpath = relative$2.toDst; + type = symlinkTypeSync(relative$2.toCwd, type); + const dir = path$18.dirname(dstpath); + const exists = fs$10.existsSync(dir); + if (exists) return fs$10.symlinkSync(srcpath, dstpath, type); + mkdirsSync(dir); + return fs$10.symlinkSync(srcpath, dstpath, type); + } + module.exports = { + createSymlink: u$5(createSymlink), + createSymlinkSync + }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/ensure/index.js +var require_ensure = __commonJS({ "node_modules/fs-extra/lib/ensure/index.js"(exports, module) { + const file$1 = require_file(); + const link$1 = require_link(); + const symlink = require_symlink(); + module.exports = { + createFile: file$1.createFile, + createFileSync: file$1.createFileSync, + ensureFile: file$1.createFile, + ensureFileSync: file$1.createFileSync, + createLink: link$1.createLink, + createLinkSync: link$1.createLinkSync, + ensureLink: link$1.createLink, + ensureLinkSync: link$1.createLinkSync, + createSymlink: symlink.createSymlink, + createSymlinkSync: symlink.createSymlinkSync, + ensureSymlink: symlink.createSymlink, + ensureSymlinkSync: symlink.createSymlinkSync + }; +} }); + +//#endregion +//#region node_modules/jsonfile/utils.js +var require_utils$4 = __commonJS({ "node_modules/jsonfile/utils.js"(exports, module) { + function stringify$16(obj, { EOL = "\n", finalEOL = true, replacer: replacer$1 = null, spaces } = {}) { + const EOF = finalEOL ? EOL : ""; + const str$3 = JSON.stringify(obj, replacer$1, spaces); + return str$3.replace(/\n/g, EOL) + EOF; + } + function stripBom$1(content) { + if (Buffer.isBuffer(content)) content = content.toString("utf8"); + return content.replace(/^\uFEFF/, ""); + } + module.exports = { + stringify: stringify$16, + stripBom: stripBom$1 + }; +} }); + +//#endregion +//#region node_modules/jsonfile/index.js +var require_jsonfile$1 = __commonJS({ "node_modules/jsonfile/index.js"(exports, module) { + let _fs$2; + try { + _fs$2 = require_graceful_fs(); + } catch (_$2) { + _fs$2 = __require("fs"); + } + const universalify = require_universalify(); + const { stringify: stringify$15, stripBom } = require_utils$4(); + async function _readFile(file$2, options = {}) { + if (typeof options === "string") options = { encoding: options }; + const fs$25 = options.fs || _fs$2; + const shouldThrow = "throws" in options ? options.throws : true; + let data$2 = await universalify.fromCallback(fs$25.readFile)(file$2, options); + data$2 = stripBom(data$2); + let obj; + try { + obj = JSON.parse(data$2, options ? options.reviver : null); + } catch (err) { + if (shouldThrow) { + err.message = `${file$2}: ${err.message}`; + throw err; + } else return null; + } + return obj; + } + const readFile$1 = universalify.fromPromise(_readFile); + function readFileSync$1(file$2, options = {}) { + if (typeof options === "string") options = { encoding: options }; + const fs$25 = options.fs || _fs$2; + const shouldThrow = "throws" in options ? options.throws : true; + try { + let content = fs$25.readFileSync(file$2, options); + content = stripBom(content); + return JSON.parse(content, options.reviver); + } catch (err) { + if (shouldThrow) { + err.message = `${file$2}: ${err.message}`; + throw err; + } else return null; + } + } + async function _writeFile(file$2, obj, options = {}) { + const fs$25 = options.fs || _fs$2; + const str$3 = stringify$15(obj, options); + await universalify.fromCallback(fs$25.writeFile)(file$2, str$3, options); + } + const writeFile = universalify.fromPromise(_writeFile); + function writeFileSync(file$2, obj, options = {}) { + const fs$25 = options.fs || _fs$2; + const str$3 = stringify$15(obj, options); + return fs$25.writeFileSync(file$2, str$3, options); + } + const jsonfile = { + readFile: readFile$1, + readFileSync: readFileSync$1, + writeFile, + writeFileSync + }; + module.exports = jsonfile; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/json/jsonfile.js +var require_jsonfile = __commonJS({ "node_modules/fs-extra/lib/json/jsonfile.js"(exports, module) { + const jsonFile$1 = require_jsonfile$1(); + module.exports = { + readJson: jsonFile$1.readFile, + readJsonSync: jsonFile$1.readFileSync, + writeJson: jsonFile$1.writeFile, + writeJsonSync: jsonFile$1.writeFileSync + }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/output/index.js +var require_output = __commonJS({ "node_modules/fs-extra/lib/output/index.js"(exports, module) { + const u$4 = require_universalify().fromCallback; + const fs$9 = require_graceful_fs(); + const path$17 = __require("path"); + const mkdir = require_mkdirs(); + const pathExists$1 = require_path_exists().pathExists; + function outputFile$1(file$2, data$2, encoding, callback) { + if (typeof encoding === "function") { + callback = encoding; + encoding = "utf8"; + } + const dir = path$17.dirname(file$2); + pathExists$1(dir, (err, itDoes) => { + if (err) return callback(err); + if (itDoes) return fs$9.writeFile(file$2, data$2, encoding, callback); + mkdir.mkdirs(dir, (err$1) => { + if (err$1) return callback(err$1); + fs$9.writeFile(file$2, data$2, encoding, callback); + }); + }); + } + function outputFileSync$1(file$2, ...args) { + const dir = path$17.dirname(file$2); + if (fs$9.existsSync(dir)) return fs$9.writeFileSync(file$2, ...args); + mkdir.mkdirsSync(dir); + fs$9.writeFileSync(file$2, ...args); + } + module.exports = { + outputFile: u$4(outputFile$1), + outputFileSync: outputFileSync$1 + }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/json/output-json.js +var require_output_json = __commonJS({ "node_modules/fs-extra/lib/json/output-json.js"(exports, module) { + const { stringify: stringify$14 } = require_utils$4(); + const { outputFile } = require_output(); + async function outputJson(file$2, data$2, options = {}) { + const str$3 = stringify$14(data$2, options); + await outputFile(file$2, str$3, options); + } + module.exports = outputJson; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/json/output-json-sync.js +var require_output_json_sync = __commonJS({ "node_modules/fs-extra/lib/json/output-json-sync.js"(exports, module) { + const { stringify: stringify$13 } = require_utils$4(); + const { outputFileSync } = require_output(); + function outputJsonSync(file$2, data$2, options) { + const str$3 = stringify$13(data$2, options); + outputFileSync(file$2, str$3, options); + } + module.exports = outputJsonSync; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/json/index.js +var require_json = __commonJS({ "node_modules/fs-extra/lib/json/index.js"(exports, module) { + const u$3 = require_universalify().fromPromise; + const jsonFile = require_jsonfile(); + jsonFile.outputJson = u$3(require_output_json()); + jsonFile.outputJsonSync = require_output_json_sync(); + jsonFile.outputJSON = jsonFile.outputJson; + jsonFile.outputJSONSync = jsonFile.outputJsonSync; + jsonFile.writeJSON = jsonFile.writeJson; + jsonFile.writeJSONSync = jsonFile.writeJsonSync; + jsonFile.readJSON = jsonFile.readJson; + jsonFile.readJSONSync = jsonFile.readJsonSync; + module.exports = jsonFile; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/move-sync/move-sync.js +var require_move_sync$1 = __commonJS({ "node_modules/fs-extra/lib/move-sync/move-sync.js"(exports, module) { + const fs$8 = require_graceful_fs(); + const path$16 = __require("path"); + const copySync = require_copy_sync().copySync; + const removeSync = require_remove().removeSync; + const mkdirpSync = require_mkdirs().mkdirpSync; + const stat$1 = require_stat(); + function moveSync(src, dest, opts) { + opts = opts || {}; + const overwrite = opts.overwrite || opts.clobber || false; + const { srcStat } = stat$1.checkPathsSync(src, dest, "move"); + stat$1.checkParentPathsSync(src, srcStat, dest, "move"); + mkdirpSync(path$16.dirname(dest)); + return doRename$1(src, dest, overwrite); + } + function doRename$1(src, dest, overwrite) { + if (overwrite) { + removeSync(dest); + return rename$1(src, dest, overwrite); + } + if (fs$8.existsSync(dest)) throw new Error("dest already exists."); + return rename$1(src, dest, overwrite); + } + function rename$1(src, dest, overwrite) { + try { + fs$8.renameSync(src, dest); + } catch (err) { + if (err.code !== "EXDEV") throw err; + return moveAcrossDevice$1(src, dest, overwrite); + } + } + function moveAcrossDevice$1(src, dest, overwrite) { + const opts = { + overwrite, + errorOnExist: true + }; + copySync(src, dest, opts); + return removeSync(src); + } + module.exports = moveSync; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/move-sync/index.js +var require_move_sync = __commonJS({ "node_modules/fs-extra/lib/move-sync/index.js"(exports, module) { + module.exports = { moveSync: require_move_sync$1() }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/move/move.js +var require_move$1 = __commonJS({ "node_modules/fs-extra/lib/move/move.js"(exports, module) { + const fs$7 = require_graceful_fs(); + const path$15 = __require("path"); + const copy = require_copy().copy; + const remove$2 = require_remove().remove; + const mkdirp = require_mkdirs().mkdirp; + const pathExists = require_path_exists().pathExists; + const stat = require_stat(); + function move(src, dest, opts, cb$1) { + if (typeof opts === "function") { + cb$1 = opts; + opts = {}; + } + const overwrite = opts.overwrite || opts.clobber || false; + stat.checkPaths(src, dest, "move", (err, stats) => { + if (err) return cb$1(err); + const { srcStat } = stats; + stat.checkParentPaths(src, srcStat, dest, "move", (err$1) => { + if (err$1) return cb$1(err$1); + mkdirp(path$15.dirname(dest), (err$2) => { + if (err$2) return cb$1(err$2); + return doRename(src, dest, overwrite, cb$1); + }); + }); + }); + } + function doRename(src, dest, overwrite, cb$1) { + if (overwrite) return remove$2(dest, (err) => { + if (err) return cb$1(err); + return rename(src, dest, overwrite, cb$1); + }); + pathExists(dest, (err, destExists) => { + if (err) return cb$1(err); + if (destExists) return cb$1(new Error("dest already exists.")); + return rename(src, dest, overwrite, cb$1); + }); + } + function rename(src, dest, overwrite, cb$1) { + fs$7.rename(src, dest, (err) => { + if (!err) return cb$1(); + if (err.code !== "EXDEV") return cb$1(err); + return moveAcrossDevice(src, dest, overwrite, cb$1); + }); + } + function moveAcrossDevice(src, dest, overwrite, cb$1) { + const opts = { + overwrite, + errorOnExist: true + }; + copy(src, dest, opts, (err) => { + if (err) return cb$1(err); + return remove$2(src, cb$1); + }); + } + module.exports = move; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/move/index.js +var require_move = __commonJS({ "node_modules/fs-extra/lib/move/index.js"(exports, module) { + const u$2 = require_universalify().fromCallback; + module.exports = { move: u$2(require_move$1()) }; +} }); + +//#endregion +//#region node_modules/fs-extra/lib/index.js +var require_lib$19 = __commonJS({ "node_modules/fs-extra/lib/index.js"(exports, module) { + module.exports = { + ...require_fs$1(), + ...require_copy_sync(), + ...require_copy(), + ...require_empty(), + ...require_ensure(), + ...require_json(), + ...require_mkdirs(), + ...require_move_sync(), + ...require_move(), + ...require_output(), + ...require_path_exists(), + ...require_remove() + }; + const fs$6 = __require("fs"); + if (Object.getOwnPropertyDescriptor(fs$6, "promises")) Object.defineProperty(module.exports, "promises", { get() { + return fs$6.promises; + } }); +} }); +var import_lib$3 = __toESM(require_lib$19()); + +//#endregion +//#region node_modules/picocolors/picocolors.browser.js +var require_picocolors_browser = __commonJS({ "node_modules/picocolors/picocolors.browser.js"(exports, module) { + var x$1 = String; + var create$6 = function() { + return { + isColorSupported: false, + reset: x$1, + bold: x$1, + dim: x$1, + italic: x$1, + underline: x$1, + inverse: x$1, + hidden: x$1, + strikethrough: x$1, + black: x$1, + red: x$1, + green: x$1, + yellow: x$1, + blue: x$1, + magenta: x$1, + cyan: x$1, + white: x$1, + gray: x$1, + bgBlack: x$1, + bgRed: x$1, + bgGreen: x$1, + bgYellow: x$1, + bgBlue: x$1, + bgMagenta: x$1, + bgCyan: x$1, + bgWhite: x$1, + blackBright: x$1, + redBright: x$1, + greenBright: x$1, + yellowBright: x$1, + blueBright: x$1, + magentaBright: x$1, + cyanBright: x$1, + whiteBright: x$1, + bgBlackBright: x$1, + bgRedBright: x$1, + bgGreenBright: x$1, + bgYellowBright: x$1, + bgBlueBright: x$1, + bgMagentaBright: x$1, + bgCyanBright: x$1, + bgWhiteBright: x$1 + }; + }; + module.exports = create$6(); + module.exports.createColors = create$6; +} }); + +//#endregion +//#region (ignored) node_modules/postcss/lib/terminal-highlight +var require_terminal_highlight = __commonJS({ "node_modules/postcss/lib/terminal-highlight"() {} }); + +//#endregion +//#region node_modules/postcss/lib/css-syntax-error.js +var require_css_syntax_error = __commonJS({ "node_modules/postcss/lib/css-syntax-error.js"(exports, module) { + let pico = require_picocolors_browser(); + let terminalHighlight$1 = require_terminal_highlight(); + var CssSyntaxError$4 = class CssSyntaxError$4 extends Error { + constructor(message, line, column, source, file$2, plugin$2) { + super(message); + this.name = "CssSyntaxError"; + this.reason = message; + if (file$2) this.file = file$2; + if (source) this.source = source; + if (plugin$2) this.plugin = plugin$2; + if (typeof line !== "undefined" && typeof column !== "undefined") if (typeof line === "number") { + this.line = line; + this.column = column; + } else { + this.line = line.line; + this.column = line.column; + this.endLine = column.line; + this.endColumn = column.column; + } + this.setMessage(); + if (Error.captureStackTrace) Error.captureStackTrace(this, CssSyntaxError$4); + } + setMessage() { + this.message = this.plugin ? this.plugin + ": " : ""; + this.message += this.file ? this.file : ""; + if (typeof this.line !== "undefined") this.message += ":" + this.line + ":" + this.column; + this.message += ": " + this.reason; + } + showSourceCode(color) { + if (!this.source) return ""; + let css = this.source; + if (color == null) color = pico.isColorSupported; + let aside = (text) => text; + let mark$1 = (text) => text; + let highlight$1 = (text) => text; + if (color) { + let { bold, gray, red } = pico.createColors(true); + mark$1 = (text) => bold(red(text)); + aside = (text) => gray(text); + if (terminalHighlight$1) highlight$1 = (text) => terminalHighlight$1(text); + } + let lines = css.split(/\r?\n/); + let start = Math.max(this.line - 3, 0); + let end = Math.min(this.line + 2, lines.length); + let maxWidth = String(end).length; + return lines.slice(start, end).map((line, index$1) => { + let number = start + 1 + index$1; + let gutter = " " + (" " + number).slice(-maxWidth) + " | "; + if (number === this.line) { + if (line.length > 160) { + let padding = 20; + let subLineStart = Math.max(0, this.column - padding); + let subLineEnd = Math.max(this.column + padding, this.endColumn + padding); + let subLine = line.slice(subLineStart, subLineEnd); + let spacing$1 = aside(gutter.replace(/\d/g, " ")) + line.slice(0, Math.min(this.column - 1, padding - 1)).replace(/[^\t]/g, " "); + return mark$1(">") + aside(gutter) + highlight$1(subLine) + "\n " + spacing$1 + mark$1("^"); + } + let spacing = aside(gutter.replace(/\d/g, " ")) + line.slice(0, this.column - 1).replace(/[^\t]/g, " "); + return mark$1(">") + aside(gutter) + highlight$1(line) + "\n " + spacing + mark$1("^"); + } + return " " + aside(gutter) + highlight$1(line); + }).join("\n"); + } + toString() { + let code$1 = this.showSourceCode(); + if (code$1) code$1 = "\n\n" + code$1 + "\n"; + return this.name + ": " + this.message + code$1; + } + }; + module.exports = CssSyntaxError$4; + CssSyntaxError$4.default = CssSyntaxError$4; +} }); + +//#endregion +//#region node_modules/postcss/lib/stringifier.js +var require_stringifier = __commonJS({ "node_modules/postcss/lib/stringifier.js"(exports, module) { + const DEFAULT_RAW = { + after: "\n", + beforeClose: "\n", + beforeComment: "\n", + beforeDecl: "\n", + beforeOpen: " ", + beforeRule: "\n", + colon: ": ", + commentLeft: " ", + commentRight: " ", + emptyBody: "", + indent: " ", + semicolon: false + }; + function capitalize$2(str$3) { + return str$3[0].toUpperCase() + str$3.slice(1); + } + var Stringifier$3 = class { + constructor(builder) { + this.builder = builder; + } + atrule(node, semicolon$3) { + let name = "@" + node.name; + let params = node.params ? this.rawValue(node, "params") : ""; + if (typeof node.raws.afterName !== "undefined") name += node.raws.afterName; + else if (params) name += " "; + if (node.nodes) this.block(node, name + params); + else { + let end = (node.raws.between || "") + (semicolon$3 ? ";" : ""); + this.builder(name + params + end, node); + } + } + beforeAfter(node, detect) { + let value; + if (node.type === "decl") value = this.raw(node, null, "beforeDecl"); + else if (node.type === "comment") value = this.raw(node, null, "beforeComment"); + else if (detect === "before") value = this.raw(node, null, "beforeRule"); + else value = this.raw(node, null, "beforeClose"); + let buf = node.parent; + let depth$1 = 0; + while (buf && buf.type !== "root") { + depth$1 += 1; + buf = buf.parent; + } + if (value.includes("\n")) { + let indent = this.raw(node, null, "indent"); + if (indent.length) for (let step = 0; step < depth$1; step++) value += indent; + } + return value; + } + block(node, start) { + let between = this.raw(node, "between", "beforeOpen"); + this.builder(start + between + "{", node, "start"); + let after$1; + if (node.nodes && node.nodes.length) { + this.body(node); + after$1 = this.raw(node, "after"); + } else after$1 = this.raw(node, "after", "emptyBody"); + if (after$1) this.builder(after$1); + this.builder("}", node, "end"); + } + body(node) { + let last$3 = node.nodes.length - 1; + while (last$3 > 0) { + if (node.nodes[last$3].type !== "comment") break; + last$3 -= 1; + } + let semicolon$3 = this.raw(node, "semicolon"); + for (let i$5 = 0; i$5 < node.nodes.length; i$5++) { + let child = node.nodes[i$5]; + let before$1 = this.raw(child, "before"); + if (before$1) this.builder(before$1); + this.stringify(child, last$3 !== i$5 || semicolon$3); + } + } + comment(node) { + let left = this.raw(node, "left", "commentLeft"); + let right = this.raw(node, "right", "commentRight"); + this.builder("/*" + left + node.text + right + "*/", node); + } + decl(node, semicolon$3) { + let between = this.raw(node, "between", "colon"); + let string$3 = node.prop + between + this.rawValue(node, "value"); + if (node.important) string$3 += node.raws.important || " !important"; + if (semicolon$3) string$3 += ";"; + this.builder(string$3, node); + } + document(node) { + this.body(node); + } + raw(node, own, detect) { + let value; + if (!detect) detect = own; + if (own) { + value = node.raws[own]; + if (typeof value !== "undefined") return value; + } + let parent = node.parent; + if (detect === "before") { + if (!parent || parent.type === "root" && parent.first === node) return ""; + if (parent && parent.type === "document") return ""; + } + if (!parent) return DEFAULT_RAW[detect]; + let root$6 = node.root(); + if (!root$6.rawCache) root$6.rawCache = {}; + if (typeof root$6.rawCache[detect] !== "undefined") return root$6.rawCache[detect]; + if (detect === "before" || detect === "after") return this.beforeAfter(node, detect); + else { + let method = "raw" + capitalize$2(detect); + if (this[method]) value = this[method](root$6, node); + else root$6.walk((i$5) => { + value = i$5.raws[own]; + if (typeof value !== "undefined") return false; + }); + } + if (typeof value === "undefined") value = DEFAULT_RAW[detect]; + root$6.rawCache[detect] = value; + return value; + } + rawBeforeClose(root$6) { + let value; + root$6.walk((i$5) => { + if (i$5.nodes && i$5.nodes.length > 0) { + if (typeof i$5.raws.after !== "undefined") { + value = i$5.raws.after; + if (value.includes("\n")) value = value.replace(/[^\n]+$/, ""); + return false; + } + } + }); + if (value) value = value.replace(/\S/g, ""); + return value; + } + rawBeforeComment(root$6, node) { + let value; + root$6.walkComments((i$5) => { + if (typeof i$5.raws.before !== "undefined") { + value = i$5.raws.before; + if (value.includes("\n")) value = value.replace(/[^\n]+$/, ""); + return false; + } + }); + if (typeof value === "undefined") value = this.raw(node, null, "beforeDecl"); + else if (value) value = value.replace(/\S/g, ""); + return value; + } + rawBeforeDecl(root$6, node) { + let value; + root$6.walkDecls((i$5) => { + if (typeof i$5.raws.before !== "undefined") { + value = i$5.raws.before; + if (value.includes("\n")) value = value.replace(/[^\n]+$/, ""); + return false; + } + }); + if (typeof value === "undefined") value = this.raw(node, null, "beforeRule"); + else if (value) value = value.replace(/\S/g, ""); + return value; + } + rawBeforeOpen(root$6) { + let value; + root$6.walk((i$5) => { + if (i$5.type !== "decl") { + value = i$5.raws.between; + if (typeof value !== "undefined") return false; + } + }); + return value; + } + rawBeforeRule(root$6) { + let value; + root$6.walk((i$5) => { + if (i$5.nodes && (i$5.parent !== root$6 || root$6.first !== i$5)) { + if (typeof i$5.raws.before !== "undefined") { + value = i$5.raws.before; + if (value.includes("\n")) value = value.replace(/[^\n]+$/, ""); + return false; + } + } + }); + if (value) value = value.replace(/\S/g, ""); + return value; + } + rawColon(root$6) { + let value; + root$6.walkDecls((i$5) => { + if (typeof i$5.raws.between !== "undefined") { + value = i$5.raws.between.replace(/[^\s:]/g, ""); + return false; + } + }); + return value; + } + rawEmptyBody(root$6) { + let value; + root$6.walk((i$5) => { + if (i$5.nodes && i$5.nodes.length === 0) { + value = i$5.raws.after; + if (typeof value !== "undefined") return false; + } + }); + return value; + } + rawIndent(root$6) { + if (root$6.raws.indent) return root$6.raws.indent; + let value; + root$6.walk((i$5) => { + let p$1 = i$5.parent; + if (p$1 && p$1 !== root$6 && p$1.parent && p$1.parent === root$6) { + if (typeof i$5.raws.before !== "undefined") { + let parts = i$5.raws.before.split("\n"); + value = parts[parts.length - 1]; + value = value.replace(/\S/g, ""); + return false; + } + } + }); + return value; + } + rawSemicolon(root$6) { + let value; + root$6.walk((i$5) => { + if (i$5.nodes && i$5.nodes.length && i$5.last.type === "decl") { + value = i$5.raws.semicolon; + if (typeof value !== "undefined") return false; + } + }); + return value; + } + rawValue(node, prop) { + let value = node[prop]; + let raw = node.raws[prop]; + if (raw && raw.value === value) return raw.raw; + return value; + } + root(node) { + this.body(node); + if (node.raws.after) this.builder(node.raws.after); + } + rule(node) { + this.block(node, this.rawValue(node, "selector")); + if (node.raws.ownSemicolon) this.builder(node.raws.ownSemicolon, node, "end"); + } + stringify(node, semicolon$3) { + /* c8 ignore start */ + if (!this[node.type]) throw new Error("Unknown AST node type " + node.type + ". Maybe you need to change PostCSS stringifier."); + /* c8 ignore stop */ + this[node.type](node, semicolon$3); + } + }; + module.exports = Stringifier$3; + Stringifier$3.default = Stringifier$3; +} }); + +//#endregion +//#region node_modules/postcss/lib/stringify.js +var require_stringify$2 = __commonJS({ "node_modules/postcss/lib/stringify.js"(exports, module) { + let Stringifier$2 = require_stringifier(); + function stringify$12(node, builder) { + let str$3 = new Stringifier$2(builder); + str$3.stringify(node); + } + module.exports = stringify$12; + stringify$12.default = stringify$12; +} }); + +//#endregion +//#region node_modules/postcss/lib/symbols.js +var require_symbols = __commonJS({ "node_modules/postcss/lib/symbols.js"(exports, module) { + module.exports.isClean = Symbol("isClean"); + module.exports.my = Symbol("my"); +} }); + +//#endregion +//#region node_modules/postcss/lib/node.js +var require_node$6 = __commonJS({ "node_modules/postcss/lib/node.js"(exports, module) { + let CssSyntaxError$3 = require_css_syntax_error(); + let Stringifier$1 = require_stringifier(); + let stringify$11 = require_stringify$2(); + let { isClean: isClean$2, my: my$2 } = require_symbols(); + function cloneNode$12(obj, parent) { + let cloned = new obj.constructor(); + for (let i$5 in obj) { + if (!Object.prototype.hasOwnProperty.call(obj, i$5)) + /* c8 ignore next 2 */ + continue; + if (i$5 === "proxyCache") continue; + let value = obj[i$5]; + let type = typeof value; + if (i$5 === "parent" && type === "object") { + if (parent) cloned[i$5] = parent; + } else if (i$5 === "source") cloned[i$5] = value; + else if (Array.isArray(value)) cloned[i$5] = value.map((j) => cloneNode$12(j, cloned)); + else { + if (type === "object" && value !== null) value = cloneNode$12(value); + cloned[i$5] = value; + } + } + return cloned; + } + function sourceOffset(inputCSS, position) { + if (position && typeof position.offset !== "undefined") return position.offset; + let column = 1; + let line = 1; + let offset = 0; + for (let i$5 = 0; i$5 < inputCSS.length; i$5++) { + if (line === position.line && column === position.column) { + offset = i$5; + break; + } + if (inputCSS[i$5] === "\n") { + column = 1; + line += 1; + } else column += 1; + } + return offset; + } + var Node$19 = class { + get proxyOf() { + return this; + } + constructor(defaults$2 = {}) { + this.raws = {}; + this[isClean$2] = false; + this[my$2] = true; + for (let name in defaults$2) if (name === "nodes") { + this.nodes = []; + for (let node of defaults$2[name]) if (typeof node.clone === "function") this.append(node.clone()); + else this.append(node); + } else this[name] = defaults$2[name]; + } + addToError(error) { + error.postcssNode = this; + if (error.stack && this.source && /\n\s{4}at /.test(error.stack)) { + let s$1 = this.source; + error.stack = error.stack.replace(/\n\s{4}at /, `$&${s$1.input.from}:${s$1.start.line}:${s$1.start.column}$&`); + } + return error; + } + after(add) { + this.parent.insertAfter(this, add); + return this; + } + assign(overrides = {}) { + for (let name in overrides) this[name] = overrides[name]; + return this; + } + before(add) { + this.parent.insertBefore(this, add); + return this; + } + cleanRaws(keepBetween) { + delete this.raws.before; + delete this.raws.after; + if (!keepBetween) delete this.raws.between; + } + clone(overrides = {}) { + let cloned = cloneNode$12(this); + for (let name in overrides) cloned[name] = overrides[name]; + return cloned; + } + cloneAfter(overrides = {}) { + let cloned = this.clone(overrides); + this.parent.insertAfter(this, cloned); + return cloned; + } + cloneBefore(overrides = {}) { + let cloned = this.clone(overrides); + this.parent.insertBefore(this, cloned); + return cloned; + } + error(message, opts = {}) { + if (this.source) { + let { end, start } = this.rangeBy(opts); + return this.source.input.error(message, { + column: start.column, + line: start.line + }, { + column: end.column, + line: end.line + }, opts); + } + return new CssSyntaxError$3(message); + } + getProxyProcessor() { + return { + get(node, prop) { + if (prop === "proxyOf") return node; + else if (prop === "root") return () => node.root().toProxy(); + else return node[prop]; + }, + set(node, prop, value) { + if (node[prop] === value) return true; + node[prop] = value; + if (prop === "prop" || prop === "value" || prop === "name" || prop === "params" || prop === "important" || prop === "text") node.markDirty(); + return true; + } + }; + } + /* c8 ignore next 3 */ + markClean() { + this[isClean$2] = true; + } + markDirty() { + if (this[isClean$2]) { + this[isClean$2] = false; + let next = this; + while (next = next.parent) next[isClean$2] = false; + } + } + next() { + if (!this.parent) return void 0; + let index$1 = this.parent.index(this); + return this.parent.nodes[index$1 + 1]; + } + positionBy(opts) { + let pos = this.source.start; + if (opts.index) pos = this.positionInside(opts.index); + else if (opts.word) { + let inputString = "document" in this.source.input ? this.source.input.document : this.source.input.css; + let stringRepresentation = inputString.slice(sourceOffset(inputString, this.source.start), sourceOffset(inputString, this.source.end)); + let index$1 = stringRepresentation.indexOf(opts.word); + if (index$1 !== -1) pos = this.positionInside(index$1); + } + return pos; + } + positionInside(index$1) { + let column = this.source.start.column; + let line = this.source.start.line; + let inputString = "document" in this.source.input ? this.source.input.document : this.source.input.css; + let offset = sourceOffset(inputString, this.source.start); + let end = offset + index$1; + for (let i$5 = offset; i$5 < end; i$5++) if (inputString[i$5] === "\n") { + column = 1; + line += 1; + } else column += 1; + return { + column, + line + }; + } + prev() { + if (!this.parent) return void 0; + let index$1 = this.parent.index(this); + return this.parent.nodes[index$1 - 1]; + } + rangeBy(opts) { + let start = { + column: this.source.start.column, + line: this.source.start.line + }; + let end = this.source.end ? { + column: this.source.end.column + 1, + line: this.source.end.line + } : { + column: start.column + 1, + line: start.line + }; + if (opts.word) { + let inputString = "document" in this.source.input ? this.source.input.document : this.source.input.css; + let stringRepresentation = inputString.slice(sourceOffset(inputString, this.source.start), sourceOffset(inputString, this.source.end)); + let index$1 = stringRepresentation.indexOf(opts.word); + if (index$1 !== -1) { + start = this.positionInside(index$1); + end = this.positionInside(index$1 + opts.word.length); + } + } else { + if (opts.start) start = { + column: opts.start.column, + line: opts.start.line + }; + else if (opts.index) start = this.positionInside(opts.index); + if (opts.end) end = { + column: opts.end.column, + line: opts.end.line + }; + else if (typeof opts.endIndex === "number") end = this.positionInside(opts.endIndex); + else if (opts.index) end = this.positionInside(opts.index + 1); + } + if (end.line < start.line || end.line === start.line && end.column <= start.column) end = { + column: start.column + 1, + line: start.line + }; + return { + end, + start + }; + } + raw(prop, defaultType) { + let str$3 = new Stringifier$1(); + return str$3.raw(this, prop, defaultType); + } + remove() { + if (this.parent) this.parent.removeChild(this); + this.parent = void 0; + return this; + } + replaceWith(...nodes$1) { + if (this.parent) { + let bookmark = this; + let foundSelf = false; + for (let node of nodes$1) if (node === this) foundSelf = true; + else if (foundSelf) { + this.parent.insertAfter(bookmark, node); + bookmark = node; + } else this.parent.insertBefore(bookmark, node); + if (!foundSelf) this.remove(); + } + return this; + } + root() { + let result$1 = this; + while (result$1.parent && result$1.parent.type !== "document") result$1 = result$1.parent; + return result$1; + } + toJSON(_$2, inputs) { + let fixed = {}; + let emitInputs = inputs == null; + inputs = inputs || new Map(); + let inputsNextIndex = 0; + for (let name in this) { + if (!Object.prototype.hasOwnProperty.call(this, name)) + /* c8 ignore next 2 */ + continue; + if (name === "parent" || name === "proxyCache") continue; + let value = this[name]; + if (Array.isArray(value)) fixed[name] = value.map((i$5) => { + if (typeof i$5 === "object" && i$5.toJSON) return i$5.toJSON(null, inputs); + else return i$5; + }); + else if (typeof value === "object" && value.toJSON) fixed[name] = value.toJSON(null, inputs); + else if (name === "source") { + let inputId = inputs.get(value.input); + if (inputId == null) { + inputId = inputsNextIndex; + inputs.set(value.input, inputsNextIndex); + inputsNextIndex++; + } + fixed[name] = { + end: value.end, + inputId, + start: value.start + }; + } else fixed[name] = value; + } + if (emitInputs) fixed.inputs = [...inputs.keys()].map((input) => input.toJSON()); + return fixed; + } + toProxy() { + if (!this.proxyCache) this.proxyCache = new Proxy(this, this.getProxyProcessor()); + return this.proxyCache; + } + toString(stringifier = stringify$11) { + if (stringifier.stringify) stringifier = stringifier.stringify; + let result$1 = ""; + stringifier(this, (i$5) => { + result$1 += i$5; + }); + return result$1; + } + warn(result$1, text, opts) { + let data$2 = { node: this }; + for (let i$5 in opts) data$2[i$5] = opts[i$5]; + return result$1.warn(text, data$2); + } + }; + module.exports = Node$19; + Node$19.default = Node$19; +} }); + +//#endregion +//#region node_modules/postcss/lib/comment.js +var require_comment$3 = __commonJS({ "node_modules/postcss/lib/comment.js"(exports, module) { + let Node$18 = require_node$6(); + var Comment$12 = class extends Node$18 { + constructor(defaults$2) { + super(defaults$2); + this.type = "comment"; + } + }; + module.exports = Comment$12; + Comment$12.default = Comment$12; +} }); + +//#endregion +//#region node_modules/postcss/lib/declaration.js +var require_declaration = __commonJS({ "node_modules/postcss/lib/declaration.js"(exports, module) { + let Node$17 = require_node$6(); + var Declaration$5 = class extends Node$17 { + get variable() { + return this.prop.startsWith("--") || this.prop[0] === "$"; + } + constructor(defaults$2) { + if (defaults$2 && typeof defaults$2.value !== "undefined" && typeof defaults$2.value !== "string") defaults$2 = { + ...defaults$2, + value: String(defaults$2.value) + }; + super(defaults$2); + this.type = "decl"; + } + }; + module.exports = Declaration$5; + Declaration$5.default = Declaration$5; +} }); + +//#endregion +//#region node_modules/postcss/lib/container.js +var require_container$3 = __commonJS({ "node_modules/postcss/lib/container.js"(exports, module) { + let Comment$11 = require_comment$3(); + let Declaration$4 = require_declaration(); + let Node$16 = require_node$6(); + let { isClean: isClean$1, my: my$1 } = require_symbols(); + let AtRule$6, parse$15, Root$10, Rule$5; + function cleanSource(nodes$1) { + return nodes$1.map((i$5) => { + if (i$5.nodes) i$5.nodes = cleanSource(i$5.nodes); + delete i$5.source; + return i$5; + }); + } + function markTreeDirty(node) { + node[isClean$1] = false; + if (node.proxyOf.nodes) for (let i$5 of node.proxyOf.nodes) markTreeDirty(i$5); + } + var Container$15 = class Container$15 extends Node$16 { + get first() { + if (!this.proxyOf.nodes) return void 0; + return this.proxyOf.nodes[0]; + } + get last() { + if (!this.proxyOf.nodes) return void 0; + return this.proxyOf.nodes[this.proxyOf.nodes.length - 1]; + } + append(...children) { + for (let child of children) { + let nodes$1 = this.normalize(child, this.last); + for (let node of nodes$1) this.proxyOf.nodes.push(node); + } + this.markDirty(); + return this; + } + cleanRaws(keepBetween) { + super.cleanRaws(keepBetween); + if (this.nodes) for (let node of this.nodes) node.cleanRaws(keepBetween); + } + each(callback) { + if (!this.proxyOf.nodes) return void 0; + let iterator = this.getIterator(); + let index$1, result$1; + while (this.indexes[iterator] < this.proxyOf.nodes.length) { + index$1 = this.indexes[iterator]; + result$1 = callback(this.proxyOf.nodes[index$1], index$1); + if (result$1 === false) break; + this.indexes[iterator] += 1; + } + delete this.indexes[iterator]; + return result$1; + } + every(condition) { + return this.nodes.every(condition); + } + getIterator() { + if (!this.lastEach) this.lastEach = 0; + if (!this.indexes) this.indexes = {}; + this.lastEach += 1; + let iterator = this.lastEach; + this.indexes[iterator] = 0; + return iterator; + } + getProxyProcessor() { + return { + get(node, prop) { + if (prop === "proxyOf") return node; + else if (!node[prop]) return node[prop]; + else if (prop === "each" || typeof prop === "string" && prop.startsWith("walk")) return (...args) => { + return node[prop](...args.map((i$5) => { + if (typeof i$5 === "function") return (child, index$1) => i$5(child.toProxy(), index$1); + else return i$5; + })); + }; + else if (prop === "every" || prop === "some") return (cb$1) => { + return node[prop]((child, ...other) => cb$1(child.toProxy(), ...other)); + }; + else if (prop === "root") return () => node.root().toProxy(); + else if (prop === "nodes") return node.nodes.map((i$5) => i$5.toProxy()); + else if (prop === "first" || prop === "last") return node[prop].toProxy(); + else return node[prop]; + }, + set(node, prop, value) { + if (node[prop] === value) return true; + node[prop] = value; + if (prop === "name" || prop === "params" || prop === "selector") node.markDirty(); + return true; + } + }; + } + index(child) { + if (typeof child === "number") return child; + if (child.proxyOf) child = child.proxyOf; + return this.proxyOf.nodes.indexOf(child); + } + insertAfter(exist, add) { + let existIndex = this.index(exist); + let nodes$1 = this.normalize(add, this.proxyOf.nodes[existIndex]).reverse(); + existIndex = this.index(exist); + for (let node of nodes$1) this.proxyOf.nodes.splice(existIndex + 1, 0, node); + let index$1; + for (let id$4 in this.indexes) { + index$1 = this.indexes[id$4]; + if (existIndex < index$1) this.indexes[id$4] = index$1 + nodes$1.length; + } + this.markDirty(); + return this; + } + insertBefore(exist, add) { + let existIndex = this.index(exist); + let type = existIndex === 0 ? "prepend" : false; + let nodes$1 = this.normalize(add, this.proxyOf.nodes[existIndex], type).reverse(); + existIndex = this.index(exist); + for (let node of nodes$1) this.proxyOf.nodes.splice(existIndex, 0, node); + let index$1; + for (let id$4 in this.indexes) { + index$1 = this.indexes[id$4]; + if (existIndex <= index$1) this.indexes[id$4] = index$1 + nodes$1.length; + } + this.markDirty(); + return this; + } + normalize(nodes$1, sample$1) { + if (typeof nodes$1 === "string") nodes$1 = cleanSource(parse$15(nodes$1).nodes); + else if (typeof nodes$1 === "undefined") nodes$1 = []; + else if (Array.isArray(nodes$1)) { + nodes$1 = nodes$1.slice(0); + for (let i$5 of nodes$1) if (i$5.parent) i$5.parent.removeChild(i$5, "ignore"); + } else if (nodes$1.type === "root" && this.type !== "document") { + nodes$1 = nodes$1.nodes.slice(0); + for (let i$5 of nodes$1) if (i$5.parent) i$5.parent.removeChild(i$5, "ignore"); + } else if (nodes$1.type) nodes$1 = [nodes$1]; + else if (nodes$1.prop) { + if (typeof nodes$1.value === "undefined") throw new Error("Value field is missed in node creation"); + else if (typeof nodes$1.value !== "string") nodes$1.value = String(nodes$1.value); + nodes$1 = [new Declaration$4(nodes$1)]; + } else if (nodes$1.selector || nodes$1.selectors) nodes$1 = [new Rule$5(nodes$1)]; + else if (nodes$1.name) nodes$1 = [new AtRule$6(nodes$1)]; + else if (nodes$1.text) nodes$1 = [new Comment$11(nodes$1)]; + else throw new Error("Unknown node type in node creation"); + let processed = nodes$1.map((i$5) => { + /* c8 ignore next */ + if (!i$5[my$1]) Container$15.rebuild(i$5); + i$5 = i$5.proxyOf; + if (i$5.parent) i$5.parent.removeChild(i$5); + if (i$5[isClean$1]) markTreeDirty(i$5); + if (!i$5.raws) i$5.raws = {}; + if (typeof i$5.raws.before === "undefined") { + if (sample$1 && typeof sample$1.raws.before !== "undefined") i$5.raws.before = sample$1.raws.before.replace(/\S/g, ""); + } + i$5.parent = this.proxyOf; + return i$5; + }); + return processed; + } + prepend(...children) { + children = children.reverse(); + for (let child of children) { + let nodes$1 = this.normalize(child, this.first, "prepend").reverse(); + for (let node of nodes$1) this.proxyOf.nodes.unshift(node); + for (let id$4 in this.indexes) this.indexes[id$4] = this.indexes[id$4] + nodes$1.length; + } + this.markDirty(); + return this; + } + push(child) { + child.parent = this; + this.proxyOf.nodes.push(child); + return this; + } + removeAll() { + for (let node of this.proxyOf.nodes) node.parent = void 0; + this.proxyOf.nodes = []; + this.markDirty(); + return this; + } + removeChild(child) { + child = this.index(child); + this.proxyOf.nodes[child].parent = void 0; + this.proxyOf.nodes.splice(child, 1); + let index$1; + for (let id$4 in this.indexes) { + index$1 = this.indexes[id$4]; + if (index$1 >= child) this.indexes[id$4] = index$1 - 1; + } + this.markDirty(); + return this; + } + replaceValues(pattern, opts, callback) { + if (!callback) { + callback = opts; + opts = {}; + } + this.walkDecls((decl$1) => { + if (opts.props && !opts.props.includes(decl$1.prop)) return; + if (opts.fast && !decl$1.value.includes(opts.fast)) return; + decl$1.value = decl$1.value.replace(pattern, callback); + }); + this.markDirty(); + return this; + } + some(condition) { + return this.nodes.some(condition); + } + walk(callback) { + return this.each((child, i$5) => { + let result$1; + try { + result$1 = callback(child, i$5); + } catch (e) { + throw child.addToError(e); + } + if (result$1 !== false && child.walk) result$1 = child.walk(callback); + return result$1; + }); + } + walkAtRules(name, callback) { + if (!callback) { + callback = name; + return this.walk((child, i$5) => { + if (child.type === "atrule") return callback(child, i$5); + }); + } + if (name instanceof RegExp) return this.walk((child, i$5) => { + if (child.type === "atrule" && name.test(child.name)) return callback(child, i$5); + }); + return this.walk((child, i$5) => { + if (child.type === "atrule" && child.name === name) return callback(child, i$5); + }); + } + walkComments(callback) { + return this.walk((child, i$5) => { + if (child.type === "comment") return callback(child, i$5); + }); + } + walkDecls(prop, callback) { + if (!callback) { + callback = prop; + return this.walk((child, i$5) => { + if (child.type === "decl") return callback(child, i$5); + }); + } + if (prop instanceof RegExp) return this.walk((child, i$5) => { + if (child.type === "decl" && prop.test(child.prop)) return callback(child, i$5); + }); + return this.walk((child, i$5) => { + if (child.type === "decl" && child.prop === prop) return callback(child, i$5); + }); + } + walkRules(selector$3, callback) { + if (!callback) { + callback = selector$3; + return this.walk((child, i$5) => { + if (child.type === "rule") return callback(child, i$5); + }); + } + if (selector$3 instanceof RegExp) return this.walk((child, i$5) => { + if (child.type === "rule" && selector$3.test(child.selector)) return callback(child, i$5); + }); + return this.walk((child, i$5) => { + if (child.type === "rule" && child.selector === selector$3) return callback(child, i$5); + }); + } + }; + Container$15.registerParse = (dependant) => { + parse$15 = dependant; + }; + Container$15.registerRule = (dependant) => { + Rule$5 = dependant; + }; + Container$15.registerAtRule = (dependant) => { + AtRule$6 = dependant; + }; + Container$15.registerRoot = (dependant) => { + Root$10 = dependant; + }; + module.exports = Container$15; + Container$15.default = Container$15; + /* c8 ignore start */ + Container$15.rebuild = (node) => { + if (node.type === "atrule") Object.setPrototypeOf(node, AtRule$6.prototype); + else if (node.type === "rule") Object.setPrototypeOf(node, Rule$5.prototype); + else if (node.type === "decl") Object.setPrototypeOf(node, Declaration$4.prototype); + else if (node.type === "comment") Object.setPrototypeOf(node, Comment$11.prototype); + else if (node.type === "root") Object.setPrototypeOf(node, Root$10.prototype); + node[my$1] = true; + if (node.nodes) node.nodes.forEach((child) => { + Container$15.rebuild(child); + }); + }; +} }); +/* c8 ignore stop */ + +//#endregion +//#region node_modules/postcss/lib/at-rule.js +var require_at_rule = __commonJS({ "node_modules/postcss/lib/at-rule.js"(exports, module) { + let Container$14 = require_container$3(); + var AtRule$5 = class extends Container$14 { + constructor(defaults$2) { + super(defaults$2); + this.type = "atrule"; + } + append(...children) { + if (!this.proxyOf.nodes) this.nodes = []; + return super.append(...children); + } + prepend(...children) { + if (!this.proxyOf.nodes) this.nodes = []; + return super.prepend(...children); + } + }; + module.exports = AtRule$5; + AtRule$5.default = AtRule$5; + Container$14.registerAtRule(AtRule$5); +} }); + +//#endregion +//#region node_modules/postcss/lib/document.js +var require_document = __commonJS({ "node_modules/postcss/lib/document.js"(exports, module) { + let Container$13 = require_container$3(); + let LazyResult$4, Processor$7; + var Document$6 = class extends Container$13 { + constructor(defaults$2) { + super({ + type: "document", + ...defaults$2 + }); + if (!this.nodes) this.nodes = []; + } + toResult(opts = {}) { + let lazy = new LazyResult$4(new Processor$7(), this, opts); + return lazy.stringify(); + } + }; + Document$6.registerLazyResult = (dependant) => { + LazyResult$4 = dependant; + }; + Document$6.registerProcessor = (dependant) => { + Processor$7 = dependant; + }; + module.exports = Document$6; + Document$6.default = Document$6; +} }); + +//#endregion +//#region node_modules/nanoid/non-secure/index.cjs +var require_non_secure = __commonJS({ "node_modules/nanoid/non-secure/index.cjs"(exports, module) { + let urlAlphabet = "useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict"; + let customAlphabet = (alphabet, defaultSize = 21) => { + return (size$1 = defaultSize) => { + let id$4 = ""; + let i$5 = size$1 | 0; + while (i$5--) id$4 += alphabet[Math.random() * alphabet.length | 0]; + return id$4; + }; + }; + let nanoid$1 = (size$1 = 21) => { + let id$4 = ""; + let i$5 = size$1 | 0; + while (i$5--) id$4 += urlAlphabet[Math.random() * 64 | 0]; + return id$4; + }; + module.exports = { + nanoid: nanoid$1, + customAlphabet + }; +} }); + +//#endregion +//#region (ignored) node_modules/postcss/lib +var require_lib$18 = __commonJS({ "node_modules/postcss/lib"() {} }); + +//#endregion +//#region node_modules/postcss/lib/previous-map.js +var require_previous_map = __commonJS({ "node_modules/postcss/lib/previous-map.js"(exports, module) { + let { existsSync, readFileSync } = require_lib$18(); + let { dirname: dirname$2, join: join$2 } = require_lib$18(); + let { SourceMapConsumer: SourceMapConsumer$4, SourceMapGenerator: SourceMapGenerator$5 } = require_lib$18(); + function fromBase64(str$3) { + if (Buffer) return Buffer.from(str$3, "base64").toString(); + else + /* c8 ignore next 2 */ + return window.atob(str$3); + } + var PreviousMap$2 = class { + constructor(css, opts) { + if (opts.map === false) return; + this.loadAnnotation(css); + this.inline = this.startWith(this.annotation, "data:"); + let prev = opts.map ? opts.map.prev : void 0; + let text = this.loadMap(opts.from, prev); + if (!this.mapFile && opts.from) this.mapFile = opts.from; + if (this.mapFile) this.root = dirname$2(this.mapFile); + if (text) this.text = text; + } + consumer() { + if (!this.consumerCache) this.consumerCache = new SourceMapConsumer$4(this.text); + return this.consumerCache; + } + decodeInline(text) { + let baseCharsetUri = /^data:application\/json;charset=utf-?8;base64,/; + let baseUri = /^data:application\/json;base64,/; + let charsetUri = /^data:application\/json;charset=utf-?8,/; + let uri = /^data:application\/json,/; + let uriMatch = text.match(charsetUri) || text.match(uri); + if (uriMatch) return decodeURIComponent(text.substr(uriMatch[0].length)); + let baseUriMatch = text.match(baseCharsetUri) || text.match(baseUri); + if (baseUriMatch) return fromBase64(text.substr(baseUriMatch[0].length)); + let encoding = text.match(/data:application\/json;([^,]+),/)[1]; + throw new Error("Unsupported source map encoding " + encoding); + } + getAnnotationURL(sourceMapString) { + return sourceMapString.replace(/^\/\*\s*# sourceMappingURL=/, "").trim(); + } + isMap(map$1) { + if (typeof map$1 !== "object") return false; + return typeof map$1.mappings === "string" || typeof map$1._mappings === "string" || Array.isArray(map$1.sections); + } + loadAnnotation(css) { + let comments = css.match(/\/\*\s*# sourceMappingURL=/g); + if (!comments) return; + let start = css.lastIndexOf(comments.pop()); + let end = css.indexOf("*/", start); + if (start > -1 && end > -1) this.annotation = this.getAnnotationURL(css.substring(start, end)); + } + loadFile(path$28) { + this.root = dirname$2(path$28); + if (existsSync(path$28)) { + this.mapFile = path$28; + return readFileSync(path$28, "utf-8").toString().trim(); + } + } + loadMap(file$2, prev) { + if (prev === false) return false; + if (prev) if (typeof prev === "string") return prev; + else if (typeof prev === "function") { + let prevPath = prev(file$2); + if (prevPath) { + let map$1 = this.loadFile(prevPath); + if (!map$1) throw new Error("Unable to load previous source map: " + prevPath.toString()); + return map$1; + } + } else if (prev instanceof SourceMapConsumer$4) return SourceMapGenerator$5.fromSourceMap(prev).toString(); + else if (prev instanceof SourceMapGenerator$5) return prev.toString(); + else if (this.isMap(prev)) return JSON.stringify(prev); + else throw new Error("Unsupported previous source map format: " + prev.toString()); + else if (this.inline) return this.decodeInline(this.annotation); + else if (this.annotation) { + let map$1 = this.annotation; + if (file$2) map$1 = join$2(dirname$2(file$2), map$1); + return this.loadFile(map$1); + } + } + startWith(string$3, start) { + if (!string$3) return false; + return string$3.substr(0, start.length) === start; + } + withContent() { + return !!(this.consumer().sourcesContent && this.consumer().sourcesContent.length > 0); + } + }; + module.exports = PreviousMap$2; + PreviousMap$2.default = PreviousMap$2; +} }); + +//#endregion +//#region node_modules/postcss/lib/input.js +var require_input = __commonJS({ "node_modules/postcss/lib/input.js"(exports, module) { + let { nanoid } = require_non_secure(); + let { isAbsolute: isAbsolute$5, resolve: resolve$4 } = require_lib$18(); + let { SourceMapConsumer: SourceMapConsumer$3, SourceMapGenerator: SourceMapGenerator$4 } = require_lib$18(); + let { fileURLToPath, pathToFileURL: pathToFileURL$1 } = require_lib$18(); + let CssSyntaxError$2 = require_css_syntax_error(); + let PreviousMap$1 = require_previous_map(); + let terminalHighlight = require_terminal_highlight(); + let fromOffsetCache = Symbol("fromOffsetCache"); + let sourceMapAvailable$1 = Boolean(SourceMapConsumer$3 && SourceMapGenerator$4); + let pathAvailable$1 = Boolean(resolve$4 && isAbsolute$5); + var Input$7 = class { + get from() { + return this.file || this.id; + } + constructor(css, opts = {}) { + if (css === null || typeof css === "undefined" || typeof css === "object" && !css.toString) throw new Error(`PostCSS received ${css} instead of CSS string`); + this.css = css.toString(); + if (this.css[0] === "" || this.css[0] === "￾") { + this.hasBOM = true; + this.css = this.css.slice(1); + } else this.hasBOM = false; + this.document = this.css; + if (opts.document) this.document = opts.document.toString(); + if (opts.from) if (!pathAvailable$1 || /^\w+:\/\//.test(opts.from) || isAbsolute$5(opts.from)) this.file = opts.from; + else this.file = resolve$4(opts.from); + if (pathAvailable$1 && sourceMapAvailable$1) { + let map$1 = new PreviousMap$1(this.css, opts); + if (map$1.text) { + this.map = map$1; + let file$2 = map$1.consumer().file; + if (!this.file && file$2) this.file = this.mapResolve(file$2); + } + } + if (!this.file) this.id = ""; + if (this.map) this.map.file = this.from; + } + error(message, line, column, opts = {}) { + let endColumn, endLine, result$1; + if (line && typeof line === "object") { + let start = line; + let end = column; + if (typeof start.offset === "number") { + let pos = this.fromOffset(start.offset); + line = pos.line; + column = pos.col; + } else { + line = start.line; + column = start.column; + } + if (typeof end.offset === "number") { + let pos = this.fromOffset(end.offset); + endLine = pos.line; + endColumn = pos.col; + } else { + endLine = end.line; + endColumn = end.column; + } + } else if (!column) { + let pos = this.fromOffset(line); + line = pos.line; + column = pos.col; + } + let origin = this.origin(line, column, endLine, endColumn); + if (origin) result$1 = new CssSyntaxError$2(message, origin.endLine === void 0 ? origin.line : { + column: origin.column, + line: origin.line + }, origin.endLine === void 0 ? origin.column : { + column: origin.endColumn, + line: origin.endLine + }, origin.source, origin.file, opts.plugin); + else result$1 = new CssSyntaxError$2(message, endLine === void 0 ? line : { + column, + line + }, endLine === void 0 ? column : { + column: endColumn, + line: endLine + }, this.css, this.file, opts.plugin); + result$1.input = { + column, + endColumn, + endLine, + line, + source: this.css + }; + if (this.file) { + if (pathToFileURL$1) result$1.input.url = pathToFileURL$1(this.file).toString(); + result$1.input.file = this.file; + } + return result$1; + } + fromOffset(offset) { + let lastLine, lineToIndex; + if (!this[fromOffsetCache]) { + let lines = this.css.split("\n"); + lineToIndex = new Array(lines.length); + let prevIndex = 0; + for (let i$5 = 0, l$1 = lines.length; i$5 < l$1; i$5++) { + lineToIndex[i$5] = prevIndex; + prevIndex += lines[i$5].length + 1; + } + this[fromOffsetCache] = lineToIndex; + } else lineToIndex = this[fromOffsetCache]; + lastLine = lineToIndex[lineToIndex.length - 1]; + let min$1 = 0; + if (offset >= lastLine) min$1 = lineToIndex.length - 1; + else { + let max$2 = lineToIndex.length - 2; + let mid; + while (min$1 < max$2) { + mid = min$1 + (max$2 - min$1 >> 1); + if (offset < lineToIndex[mid]) max$2 = mid - 1; + else if (offset >= lineToIndex[mid + 1]) min$1 = mid + 1; + else { + min$1 = mid; + break; + } + } + } + return { + col: offset - lineToIndex[min$1] + 1, + line: min$1 + 1 + }; + } + mapResolve(file$2) { + if (/^\w+:\/\//.test(file$2)) return file$2; + return resolve$4(this.map.consumer().sourceRoot || this.map.root || ".", file$2); + } + origin(line, column, endLine, endColumn) { + if (!this.map) return false; + let consumer = this.map.consumer(); + let from = consumer.originalPositionFor({ + column, + line + }); + if (!from.source) return false; + let to; + if (typeof endLine === "number") to = consumer.originalPositionFor({ + column: endColumn, + line: endLine + }); + let fromUrl; + if (isAbsolute$5(from.source)) fromUrl = pathToFileURL$1(from.source); + else fromUrl = new URL(from.source, this.map.consumer().sourceRoot || pathToFileURL$1(this.map.mapFile)); + let result$1 = { + column: from.column, + endColumn: to && to.column, + endLine: to && to.line, + line: from.line, + url: fromUrl.toString() + }; + if (fromUrl.protocol === "file:") if (fileURLToPath) result$1.file = fileURLToPath(fromUrl); + else + /* c8 ignore next 2 */ + throw new Error(`file: protocol is not available in this PostCSS build`); + let source = consumer.sourceContentFor(from.source); + if (source) result$1.source = source; + return result$1; + } + toJSON() { + let json = {}; + for (let name of [ + "hasBOM", + "css", + "file", + "id" + ]) if (this[name] != null) json[name] = this[name]; + if (this.map) { + json.map = { ...this.map }; + if (json.map.consumerCache) json.map.consumerCache = void 0; + } + return json; + } + }; + module.exports = Input$7; + Input$7.default = Input$7; + if (terminalHighlight && terminalHighlight.registerInput) terminalHighlight.registerInput(Input$7); +} }); + +//#endregion +//#region node_modules/postcss/lib/root.js +var require_root$3 = __commonJS({ "node_modules/postcss/lib/root.js"(exports, module) { + let Container$12 = require_container$3(); + let LazyResult$3, Processor$6; + var Root$9 = class extends Container$12 { + constructor(defaults$2) { + super(defaults$2); + this.type = "root"; + if (!this.nodes) this.nodes = []; + } + normalize(child, sample$1, type) { + let nodes$1 = super.normalize(child); + if (sample$1) { + if (type === "prepend") if (this.nodes.length > 1) sample$1.raws.before = this.nodes[1].raws.before; + else delete sample$1.raws.before; + else if (this.first !== sample$1) for (let node of nodes$1) node.raws.before = sample$1.raws.before; + } + return nodes$1; + } + removeChild(child, ignore) { + let index$1 = this.index(child); + if (!ignore && index$1 === 0 && this.nodes.length > 1) this.nodes[1].raws.before = this.nodes[index$1].raws.before; + return super.removeChild(child); + } + toResult(opts = {}) { + let lazy = new LazyResult$3(new Processor$6(), this, opts); + return lazy.stringify(); + } + }; + Root$9.registerLazyResult = (dependant) => { + LazyResult$3 = dependant; + }; + Root$9.registerProcessor = (dependant) => { + Processor$6 = dependant; + }; + module.exports = Root$9; + Root$9.default = Root$9; + Container$12.registerRoot(Root$9); +} }); + +//#endregion +//#region node_modules/postcss/lib/list.js +var require_list = __commonJS({ "node_modules/postcss/lib/list.js"(exports, module) { + let list$3 = { + comma(string$3) { + return list$3.split(string$3, [","], true); + }, + space(string$3) { + let spaces = [ + " ", + "\n", + " " + ]; + return list$3.split(string$3, spaces); + }, + split(string$3, separators, last$3) { + let array = []; + let current = ""; + let split = false; + let func = 0; + let inQuote = false; + let prevQuote = ""; + let escape$2 = false; + for (let letter of string$3) { + if (escape$2) escape$2 = false; + else if (letter === "\\") escape$2 = true; + else if (inQuote) { + if (letter === prevQuote) inQuote = false; + } else if (letter === "\"" || letter === "'") { + inQuote = true; + prevQuote = letter; + } else if (letter === "(") func += 1; + else if (letter === ")") { + if (func > 0) func -= 1; + } else if (func === 0) { + if (separators.includes(letter)) split = true; + } + if (split) { + if (current !== "") array.push(current.trim()); + current = ""; + split = false; + } else current += letter; + } + if (last$3 || current !== "") array.push(current.trim()); + return array; + } + }; + module.exports = list$3; + list$3.default = list$3; +} }); + +//#endregion +//#region node_modules/postcss/lib/rule.js +var require_rule = __commonJS({ "node_modules/postcss/lib/rule.js"(exports, module) { + let Container$11 = require_container$3(); + let list$2 = require_list(); + var Rule$4 = class extends Container$11 { + get selectors() { + return list$2.comma(this.selector); + } + set selectors(values$1) { + let match = this.selector ? this.selector.match(/,\s*/) : null; + let sep$1 = match ? match[0] : "," + this.raw("between", "beforeOpen"); + this.selector = values$1.join(sep$1); + } + constructor(defaults$2) { + super(defaults$2); + this.type = "rule"; + if (!this.nodes) this.nodes = []; + } + }; + module.exports = Rule$4; + Rule$4.default = Rule$4; + Container$11.registerRule(Rule$4); +} }); + +//#endregion +//#region node_modules/postcss/lib/fromJSON.js +var require_fromJSON = __commonJS({ "node_modules/postcss/lib/fromJSON.js"(exports, module) { + let AtRule$4 = require_at_rule(); + let Comment$10 = require_comment$3(); + let Declaration$3 = require_declaration(); + let Input$6 = require_input(); + let PreviousMap = require_previous_map(); + let Root$8 = require_root$3(); + let Rule$3 = require_rule(); + function fromJSON$2(json, inputs) { + if (Array.isArray(json)) return json.map((n$3) => fromJSON$2(n$3)); + let { inputs: ownInputs,...defaults$2 } = json; + if (ownInputs) { + inputs = []; + for (let input of ownInputs) { + let inputHydrated = { + ...input, + __proto__: Input$6.prototype + }; + if (inputHydrated.map) inputHydrated.map = { + ...inputHydrated.map, + __proto__: PreviousMap.prototype + }; + inputs.push(inputHydrated); + } + } + if (defaults$2.nodes) defaults$2.nodes = json.nodes.map((n$3) => fromJSON$2(n$3, inputs)); + if (defaults$2.source) { + let { inputId,...source } = defaults$2.source; + defaults$2.source = source; + if (inputId != null) defaults$2.source.input = inputs[inputId]; + } + if (defaults$2.type === "root") return new Root$8(defaults$2); + else if (defaults$2.type === "decl") return new Declaration$3(defaults$2); + else if (defaults$2.type === "rule") return new Rule$3(defaults$2); + else if (defaults$2.type === "comment") return new Comment$10(defaults$2); + else if (defaults$2.type === "atrule") return new AtRule$4(defaults$2); + else throw new Error("Unknown node type: " + json.type); + } + module.exports = fromJSON$2; + fromJSON$2.default = fromJSON$2; +} }); + +//#endregion +//#region node_modules/postcss/lib/map-generator.js +var require_map_generator = __commonJS({ "node_modules/postcss/lib/map-generator.js"(exports, module) { + let { dirname: dirname$1, relative: relative$1, resolve: resolve$3, sep } = require_lib$18(); + let { SourceMapConsumer: SourceMapConsumer$2, SourceMapGenerator: SourceMapGenerator$3 } = require_lib$18(); + let { pathToFileURL } = require_lib$18(); + let Input$5 = require_input(); + let sourceMapAvailable = Boolean(SourceMapConsumer$2 && SourceMapGenerator$3); + let pathAvailable = Boolean(dirname$1 && resolve$3 && relative$1 && sep); + var MapGenerator$2 = class { + constructor(stringify$17, root$6, opts, cssString) { + this.stringify = stringify$17; + this.mapOpts = opts.map || {}; + this.root = root$6; + this.opts = opts; + this.css = cssString; + this.originalCSS = cssString; + this.usesFileUrls = !this.mapOpts.from && this.mapOpts.absolute; + this.memoizedFileURLs = new Map(); + this.memoizedPaths = new Map(); + this.memoizedURLs = new Map(); + } + addAnnotation() { + let content; + if (this.isInline()) content = "data:application/json;base64," + this.toBase64(this.map.toString()); + else if (typeof this.mapOpts.annotation === "string") content = this.mapOpts.annotation; + else if (typeof this.mapOpts.annotation === "function") content = this.mapOpts.annotation(this.opts.to, this.root); + else content = this.outputFile() + ".map"; + let eol = "\n"; + if (this.css.includes("\r\n")) eol = "\r\n"; + this.css += eol + "/*# sourceMappingURL=" + content + " */"; + } + applyPrevMaps() { + for (let prev of this.previous()) { + let from = this.toUrl(this.path(prev.file)); + let root$6 = prev.root || dirname$1(prev.file); + let map$1; + if (this.mapOpts.sourcesContent === false) { + map$1 = new SourceMapConsumer$2(prev.text); + if (map$1.sourcesContent) map$1.sourcesContent = null; + } else map$1 = prev.consumer(); + this.map.applySourceMap(map$1, from, this.toUrl(this.path(root$6))); + } + } + clearAnnotation() { + if (this.mapOpts.annotation === false) return; + if (this.root) { + let node; + for (let i$5 = this.root.nodes.length - 1; i$5 >= 0; i$5--) { + node = this.root.nodes[i$5]; + if (node.type !== "comment") continue; + if (node.text.startsWith("# sourceMappingURL=")) this.root.removeChild(i$5); + } + } else if (this.css) this.css = this.css.replace(/\n*\/\*#[\S\s]*?\*\/$/gm, ""); + } + generate() { + this.clearAnnotation(); + if (pathAvailable && sourceMapAvailable && this.isMap()) return this.generateMap(); + else { + let result$1 = ""; + this.stringify(this.root, (i$5) => { + result$1 += i$5; + }); + return [result$1]; + } + } + generateMap() { + if (this.root) this.generateString(); + else if (this.previous().length === 1) { + let prev = this.previous()[0].consumer(); + prev.file = this.outputFile(); + this.map = SourceMapGenerator$3.fromSourceMap(prev, { ignoreInvalidMapping: true }); + } else { + this.map = new SourceMapGenerator$3({ + file: this.outputFile(), + ignoreInvalidMapping: true + }); + this.map.addMapping({ + generated: { + column: 0, + line: 1 + }, + original: { + column: 0, + line: 1 + }, + source: this.opts.from ? this.toUrl(this.path(this.opts.from)) : "" + }); + } + if (this.isSourcesContent()) this.setSourcesContent(); + if (this.root && this.previous().length > 0) this.applyPrevMaps(); + if (this.isAnnotation()) this.addAnnotation(); + if (this.isInline()) return [this.css]; + else return [this.css, this.map]; + } + generateString() { + this.css = ""; + this.map = new SourceMapGenerator$3({ + file: this.outputFile(), + ignoreInvalidMapping: true + }); + let line = 1; + let column = 1; + let noSource = ""; + let mapping = { + generated: { + column: 0, + line: 0 + }, + original: { + column: 0, + line: 0 + }, + source: "" + }; + let last$3, lines; + this.stringify(this.root, (str$3, node, type) => { + this.css += str$3; + if (node && type !== "end") { + mapping.generated.line = line; + mapping.generated.column = column - 1; + if (node.source && node.source.start) { + mapping.source = this.sourcePath(node); + mapping.original.line = node.source.start.line; + mapping.original.column = node.source.start.column - 1; + this.map.addMapping(mapping); + } else { + mapping.source = noSource; + mapping.original.line = 1; + mapping.original.column = 0; + this.map.addMapping(mapping); + } + } + lines = str$3.match(/\n/g); + if (lines) { + line += lines.length; + last$3 = str$3.lastIndexOf("\n"); + column = str$3.length - last$3; + } else column += str$3.length; + if (node && type !== "start") { + let p$1 = node.parent || { raws: {} }; + let childless = node.type === "decl" || node.type === "atrule" && !node.nodes; + if (!childless || node !== p$1.last || p$1.raws.semicolon) if (node.source && node.source.end) { + mapping.source = this.sourcePath(node); + mapping.original.line = node.source.end.line; + mapping.original.column = node.source.end.column - 1; + mapping.generated.line = line; + mapping.generated.column = column - 2; + this.map.addMapping(mapping); + } else { + mapping.source = noSource; + mapping.original.line = 1; + mapping.original.column = 0; + mapping.generated.line = line; + mapping.generated.column = column - 1; + this.map.addMapping(mapping); + } + } + }); + } + isAnnotation() { + if (this.isInline()) return true; + if (typeof this.mapOpts.annotation !== "undefined") return this.mapOpts.annotation; + if (this.previous().length) return this.previous().some((i$5) => i$5.annotation); + return true; + } + isInline() { + if (typeof this.mapOpts.inline !== "undefined") return this.mapOpts.inline; + let annotation = this.mapOpts.annotation; + if (typeof annotation !== "undefined" && annotation !== true) return false; + if (this.previous().length) return this.previous().some((i$5) => i$5.inline); + return true; + } + isMap() { + if (typeof this.opts.map !== "undefined") return !!this.opts.map; + return this.previous().length > 0; + } + isSourcesContent() { + if (typeof this.mapOpts.sourcesContent !== "undefined") return this.mapOpts.sourcesContent; + if (this.previous().length) return this.previous().some((i$5) => i$5.withContent()); + return true; + } + outputFile() { + if (this.opts.to) return this.path(this.opts.to); + else if (this.opts.from) return this.path(this.opts.from); + else return "to.css"; + } + path(file$2) { + if (this.mapOpts.absolute) return file$2; + if (file$2.charCodeAt(0) === 60) return file$2; + if (/^\w+:\/\//.test(file$2)) return file$2; + let cached = this.memoizedPaths.get(file$2); + if (cached) return cached; + let from = this.opts.to ? dirname$1(this.opts.to) : "."; + if (typeof this.mapOpts.annotation === "string") from = dirname$1(resolve$3(from, this.mapOpts.annotation)); + let path$28 = relative$1(from, file$2); + this.memoizedPaths.set(file$2, path$28); + return path$28; + } + previous() { + if (!this.previousMaps) { + this.previousMaps = []; + if (this.root) this.root.walk((node) => { + if (node.source && node.source.input.map) { + let map$1 = node.source.input.map; + if (!this.previousMaps.includes(map$1)) this.previousMaps.push(map$1); + } + }); + else { + let input = new Input$5(this.originalCSS, this.opts); + if (input.map) this.previousMaps.push(input.map); + } + } + return this.previousMaps; + } + setSourcesContent() { + let already = {}; + if (this.root) this.root.walk((node) => { + if (node.source) { + let from = node.source.input.from; + if (from && !already[from]) { + already[from] = true; + let fromUrl = this.usesFileUrls ? this.toFileUrl(from) : this.toUrl(this.path(from)); + this.map.setSourceContent(fromUrl, node.source.input.css); + } + } + }); + else if (this.css) { + let from = this.opts.from ? this.toUrl(this.path(this.opts.from)) : ""; + this.map.setSourceContent(from, this.css); + } + } + sourcePath(node) { + if (this.mapOpts.from) return this.toUrl(this.mapOpts.from); + else if (this.usesFileUrls) return this.toFileUrl(node.source.input.from); + else return this.toUrl(this.path(node.source.input.from)); + } + toBase64(str$3) { + if (Buffer) return Buffer.from(str$3).toString("base64"); + else return window.btoa(unescape(encodeURIComponent(str$3))); + } + toFileUrl(path$28) { + let cached = this.memoizedFileURLs.get(path$28); + if (cached) return cached; + if (pathToFileURL) { + let fileURL = pathToFileURL(path$28).toString(); + this.memoizedFileURLs.set(path$28, fileURL); + return fileURL; + } else throw new Error("`map.absolute` option is not available in this PostCSS build"); + } + toUrl(path$28) { + let cached = this.memoizedURLs.get(path$28); + if (cached) return cached; + if (sep === "\\") path$28 = path$28.replace(/\\/g, "/"); + let url$1 = encodeURI(path$28).replace(/[#?]/g, encodeURIComponent); + this.memoizedURLs.set(path$28, url$1); + return url$1; + } + }; + module.exports = MapGenerator$2; +} }); + +//#endregion +//#region node_modules/postcss/lib/tokenize.js +var require_tokenize$4 = __commonJS({ "node_modules/postcss/lib/tokenize.js"(exports, module) { + const SINGLE_QUOTE = "'".charCodeAt(0); + const DOUBLE_QUOTE = "\"".charCodeAt(0); + const BACKSLASH = "\\".charCodeAt(0); + const SLASH = "/".charCodeAt(0); + const NEWLINE$2 = "\n".charCodeAt(0); + const SPACE = " ".charCodeAt(0); + const FEED = "\f".charCodeAt(0); + const TAB = " ".charCodeAt(0); + const CR = "\r".charCodeAt(0); + const OPEN_SQUARE = "[".charCodeAt(0); + const CLOSE_SQUARE = "]".charCodeAt(0); + const OPEN_PARENTHESES = "(".charCodeAt(0); + const CLOSE_PARENTHESES = ")".charCodeAt(0); + const OPEN_CURLY = "{".charCodeAt(0); + const CLOSE_CURLY = "}".charCodeAt(0); + const SEMICOLON = ";".charCodeAt(0); + const ASTERISK = "*".charCodeAt(0); + const COLON = ":".charCodeAt(0); + const AT = "@".charCodeAt(0); + const RE_AT_END = /[\t\n\f\r "#'()/;[\\\]{}]/g; + const RE_WORD_END = /[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g; + const RE_BAD_BRACKET = /.[\r\n"'(/\\]/; + const RE_HEX_ESCAPE = /[\da-f]/i; + module.exports = function tokenizer$2(input, options = {}) { + let css = input.css.valueOf(); + let ignore = options.ignoreErrors; + let code$1, content, escape$2, next, quote; + let currentToken, escaped, escapePos, n$3, prev; + let length = css.length; + let pos = 0; + let buffer = []; + let returned = []; + function position() { + return pos; + } + function unclosed(what) { + throw input.error("Unclosed " + what, pos); + } + function endOfFile() { + return returned.length === 0 && pos >= length; + } + function nextToken(opts) { + if (returned.length) return returned.pop(); + if (pos >= length) return; + let ignoreUnclosed = opts ? opts.ignoreUnclosed : false; + code$1 = css.charCodeAt(pos); + switch (code$1) { + case NEWLINE$2: + case SPACE: + case TAB: + case CR: + case FEED: { + next = pos; + do { + next += 1; + code$1 = css.charCodeAt(next); + } while (code$1 === SPACE || code$1 === NEWLINE$2 || code$1 === TAB || code$1 === CR || code$1 === FEED); + currentToken = ["space", css.slice(pos, next)]; + pos = next - 1; + break; + } + case OPEN_SQUARE: + case CLOSE_SQUARE: + case OPEN_CURLY: + case CLOSE_CURLY: + case COLON: + case SEMICOLON: + case CLOSE_PARENTHESES: { + let controlChar = String.fromCharCode(code$1); + currentToken = [ + controlChar, + controlChar, + pos + ]; + break; + } + case OPEN_PARENTHESES: { + prev = buffer.length ? buffer.pop()[1] : ""; + n$3 = css.charCodeAt(pos + 1); + if (prev === "url" && n$3 !== SINGLE_QUOTE && n$3 !== DOUBLE_QUOTE && n$3 !== SPACE && n$3 !== NEWLINE$2 && n$3 !== TAB && n$3 !== FEED && n$3 !== CR) { + next = pos; + do { + escaped = false; + next = css.indexOf(")", next + 1); + if (next === -1) if (ignore || ignoreUnclosed) { + next = pos; + break; + } else unclosed("bracket"); + escapePos = next; + while (css.charCodeAt(escapePos - 1) === BACKSLASH) { + escapePos -= 1; + escaped = !escaped; + } + } while (escaped); + currentToken = [ + "brackets", + css.slice(pos, next + 1), + pos, + next + ]; + pos = next; + } else { + next = css.indexOf(")", pos + 1); + content = css.slice(pos, next + 1); + if (next === -1 || RE_BAD_BRACKET.test(content)) currentToken = [ + "(", + "(", + pos + ]; + else { + currentToken = [ + "brackets", + content, + pos, + next + ]; + pos = next; + } + } + break; + } + case SINGLE_QUOTE: + case DOUBLE_QUOTE: { + quote = code$1 === SINGLE_QUOTE ? "'" : "\""; + next = pos; + do { + escaped = false; + next = css.indexOf(quote, next + 1); + if (next === -1) if (ignore || ignoreUnclosed) { + next = pos + 1; + break; + } else unclosed("string"); + escapePos = next; + while (css.charCodeAt(escapePos - 1) === BACKSLASH) { + escapePos -= 1; + escaped = !escaped; + } + } while (escaped); + currentToken = [ + "string", + css.slice(pos, next + 1), + pos, + next + ]; + pos = next; + break; + } + case AT: { + RE_AT_END.lastIndex = pos + 1; + RE_AT_END.test(css); + if (RE_AT_END.lastIndex === 0) next = css.length - 1; + else next = RE_AT_END.lastIndex - 2; + currentToken = [ + "at-word", + css.slice(pos, next + 1), + pos, + next + ]; + pos = next; + break; + } + case BACKSLASH: { + next = pos; + escape$2 = true; + while (css.charCodeAt(next + 1) === BACKSLASH) { + next += 1; + escape$2 = !escape$2; + } + code$1 = css.charCodeAt(next + 1); + if (escape$2 && code$1 !== SLASH && code$1 !== SPACE && code$1 !== NEWLINE$2 && code$1 !== TAB && code$1 !== CR && code$1 !== FEED) { + next += 1; + if (RE_HEX_ESCAPE.test(css.charAt(next))) { + while (RE_HEX_ESCAPE.test(css.charAt(next + 1))) next += 1; + if (css.charCodeAt(next + 1) === SPACE) next += 1; + } + } + currentToken = [ + "word", + css.slice(pos, next + 1), + pos, + next + ]; + pos = next; + break; + } + default: { + if (code$1 === SLASH && css.charCodeAt(pos + 1) === ASTERISK) { + next = css.indexOf("*/", pos + 2) + 1; + if (next === 0) if (ignore || ignoreUnclosed) next = css.length; + else unclosed("comment"); + currentToken = [ + "comment", + css.slice(pos, next + 1), + pos, + next + ]; + pos = next; + } else { + RE_WORD_END.lastIndex = pos + 1; + RE_WORD_END.test(css); + if (RE_WORD_END.lastIndex === 0) next = css.length - 1; + else next = RE_WORD_END.lastIndex - 2; + currentToken = [ + "word", + css.slice(pos, next + 1), + pos, + next + ]; + buffer.push(currentToken); + pos = next; + } + break; + } + } + pos++; + return currentToken; + } + function back(token$1) { + returned.push(token$1); + } + return { + back, + endOfFile, + nextToken, + position + }; + }; +} }); + +//#endregion +//#region node_modules/postcss/lib/parser.js +var require_parser$5 = __commonJS({ "node_modules/postcss/lib/parser.js"(exports, module) { + let AtRule$3 = require_at_rule(); + let Comment$9 = require_comment$3(); + let Declaration$2 = require_declaration(); + let Root$7 = require_root$3(); + let Rule$2 = require_rule(); + let tokenizer$1 = require_tokenize$4(); + const SAFE_COMMENT_NEIGHBOR = { + empty: true, + space: true + }; + function findLastWithPosition(tokens$3) { + for (let i$5 = tokens$3.length - 1; i$5 >= 0; i$5--) { + let token$1 = tokens$3[i$5]; + let pos = token$1[3] || token$1[2]; + if (pos) return pos; + } + } + var Parser$9 = class { + constructor(input) { + this.input = input; + this.root = new Root$7(); + this.current = this.root; + this.spaces = ""; + this.semicolon = false; + this.createTokenizer(); + this.root.source = { + input, + start: { + column: 1, + line: 1, + offset: 0 + } + }; + } + atrule(token$1) { + let node = new AtRule$3(); + node.name = token$1[1].slice(1); + if (node.name === "") this.unnamedAtrule(node, token$1); + this.init(node, token$1[2]); + let type; + let prev; + let shift; + let last$3 = false; + let open = false; + let params = []; + let brackets$1 = []; + while (!this.tokenizer.endOfFile()) { + token$1 = this.tokenizer.nextToken(); + type = token$1[0]; + if (type === "(" || type === "[") brackets$1.push(type === "(" ? ")" : "]"); + else if (type === "{" && brackets$1.length > 0) brackets$1.push("}"); + else if (type === brackets$1[brackets$1.length - 1]) brackets$1.pop(); + if (brackets$1.length === 0) if (type === ";") { + node.source.end = this.getPosition(token$1[2]); + node.source.end.offset++; + this.semicolon = true; + break; + } else if (type === "{") { + open = true; + break; + } else if (type === "}") { + if (params.length > 0) { + shift = params.length - 1; + prev = params[shift]; + while (prev && prev[0] === "space") prev = params[--shift]; + if (prev) { + node.source.end = this.getPosition(prev[3] || prev[2]); + node.source.end.offset++; + } + } + this.end(token$1); + break; + } else params.push(token$1); + else params.push(token$1); + if (this.tokenizer.endOfFile()) { + last$3 = true; + break; + } + } + node.raws.between = this.spacesAndCommentsFromEnd(params); + if (params.length) { + node.raws.afterName = this.spacesAndCommentsFromStart(params); + this.raw(node, "params", params); + if (last$3) { + token$1 = params[params.length - 1]; + node.source.end = this.getPosition(token$1[3] || token$1[2]); + node.source.end.offset++; + this.spaces = node.raws.between; + node.raws.between = ""; + } + } else { + node.raws.afterName = ""; + node.params = ""; + } + if (open) { + node.nodes = []; + this.current = node; + } + } + checkMissedSemicolon(tokens$3) { + let colon$4 = this.colon(tokens$3); + if (colon$4 === false) return; + let founded = 0; + let token$1; + for (let j = colon$4 - 1; j >= 0; j--) { + token$1 = tokens$3[j]; + if (token$1[0] !== "space") { + founded += 1; + if (founded === 2) break; + } + } + throw this.input.error("Missed semicolon", token$1[0] === "word" ? token$1[3] + 1 : token$1[2]); + } + colon(tokens$3) { + let brackets$1 = 0; + let prev, token$1, type; + for (let [i$5, element] of tokens$3.entries()) { + token$1 = element; + type = token$1[0]; + if (type === "(") brackets$1 += 1; + if (type === ")") brackets$1 -= 1; + if (brackets$1 === 0 && type === ":") if (!prev) this.doubleColon(token$1); + else if (prev[0] === "word" && prev[1] === "progid") continue; + else return i$5; + prev = token$1; + } + return false; + } + comment(token$1) { + let node = new Comment$9(); + this.init(node, token$1[2]); + node.source.end = this.getPosition(token$1[3] || token$1[2]); + node.source.end.offset++; + let text = token$1[1].slice(2, -2); + if (/^\s*$/.test(text)) { + node.text = ""; + node.raws.left = text; + node.raws.right = ""; + } else { + let match = text.match(/^(\s*)([^]*\S)(\s*)$/); + node.text = match[2]; + node.raws.left = match[1]; + node.raws.right = match[3]; + } + } + createTokenizer() { + this.tokenizer = tokenizer$1(this.input); + } + decl(tokens$3, customProperty) { + let node = new Declaration$2(); + this.init(node, tokens$3[0][2]); + let last$3 = tokens$3[tokens$3.length - 1]; + if (last$3[0] === ";") { + this.semicolon = true; + tokens$3.pop(); + } + node.source.end = this.getPosition(last$3[3] || last$3[2] || findLastWithPosition(tokens$3)); + node.source.end.offset++; + while (tokens$3[0][0] !== "word") { + if (tokens$3.length === 1) this.unknownWord(tokens$3); + node.raws.before += tokens$3.shift()[1]; + } + node.source.start = this.getPosition(tokens$3[0][2]); + node.prop = ""; + while (tokens$3.length) { + let type = tokens$3[0][0]; + if (type === ":" || type === "space" || type === "comment") break; + node.prop += tokens$3.shift()[1]; + } + node.raws.between = ""; + let token$1; + while (tokens$3.length) { + token$1 = tokens$3.shift(); + if (token$1[0] === ":") { + node.raws.between += token$1[1]; + break; + } else { + if (token$1[0] === "word" && /\w/.test(token$1[1])) this.unknownWord([token$1]); + node.raws.between += token$1[1]; + } + } + if (node.prop[0] === "_" || node.prop[0] === "*") { + node.raws.before += node.prop[0]; + node.prop = node.prop.slice(1); + } + let firstSpaces = []; + let next; + while (tokens$3.length) { + next = tokens$3[0][0]; + if (next !== "space" && next !== "comment") break; + firstSpaces.push(tokens$3.shift()); + } + this.precheckMissedSemicolon(tokens$3); + for (let i$5 = tokens$3.length - 1; i$5 >= 0; i$5--) { + token$1 = tokens$3[i$5]; + if (token$1[1].toLowerCase() === "!important") { + node.important = true; + let string$3 = this.stringFrom(tokens$3, i$5); + string$3 = this.spacesFromEnd(tokens$3) + string$3; + if (string$3 !== " !important") node.raws.important = string$3; + break; + } else if (token$1[1].toLowerCase() === "important") { + let cache$3 = tokens$3.slice(0); + let str$3 = ""; + for (let j = i$5; j > 0; j--) { + let type = cache$3[j][0]; + if (str$3.trim().startsWith("!") && type !== "space") break; + str$3 = cache$3.pop()[1] + str$3; + } + if (str$3.trim().startsWith("!")) { + node.important = true; + node.raws.important = str$3; + tokens$3 = cache$3; + } + } + if (token$1[0] !== "space" && token$1[0] !== "comment") break; + } + let hasWord = tokens$3.some((i$5) => i$5[0] !== "space" && i$5[0] !== "comment"); + if (hasWord) { + node.raws.between += firstSpaces.map((i$5) => i$5[1]).join(""); + firstSpaces = []; + } + this.raw(node, "value", firstSpaces.concat(tokens$3), customProperty); + if (node.value.includes(":") && !customProperty) this.checkMissedSemicolon(tokens$3); + } + doubleColon(token$1) { + throw this.input.error("Double colon", { offset: token$1[2] }, { offset: token$1[2] + token$1[1].length }); + } + emptyRule(token$1) { + let node = new Rule$2(); + this.init(node, token$1[2]); + node.selector = ""; + node.raws.between = ""; + this.current = node; + } + end(token$1) { + if (this.current.nodes && this.current.nodes.length) this.current.raws.semicolon = this.semicolon; + this.semicolon = false; + this.current.raws.after = (this.current.raws.after || "") + this.spaces; + this.spaces = ""; + if (this.current.parent) { + this.current.source.end = this.getPosition(token$1[2]); + this.current.source.end.offset++; + this.current = this.current.parent; + } else this.unexpectedClose(token$1); + } + endFile() { + if (this.current.parent) this.unclosedBlock(); + if (this.current.nodes && this.current.nodes.length) this.current.raws.semicolon = this.semicolon; + this.current.raws.after = (this.current.raws.after || "") + this.spaces; + this.root.source.end = this.getPosition(this.tokenizer.position()); + } + freeSemicolon(token$1) { + this.spaces += token$1[1]; + if (this.current.nodes) { + let prev = this.current.nodes[this.current.nodes.length - 1]; + if (prev && prev.type === "rule" && !prev.raws.ownSemicolon) { + prev.raws.ownSemicolon = this.spaces; + this.spaces = ""; + prev.source.end = this.getPosition(token$1[2]); + prev.source.end.offset += prev.raws.ownSemicolon.length; + } + } + } + getPosition(offset) { + let pos = this.input.fromOffset(offset); + return { + column: pos.col, + line: pos.line, + offset + }; + } + init(node, offset) { + this.current.push(node); + node.source = { + input: this.input, + start: this.getPosition(offset) + }; + node.raws.before = this.spaces; + this.spaces = ""; + if (node.type !== "comment") this.semicolon = false; + } + other(start) { + let end = false; + let type = null; + let colon$4 = false; + let bracket = null; + let brackets$1 = []; + let customProperty = start[1].startsWith("--"); + let tokens$3 = []; + let token$1 = start; + while (token$1) { + type = token$1[0]; + tokens$3.push(token$1); + if (type === "(" || type === "[") { + if (!bracket) bracket = token$1; + brackets$1.push(type === "(" ? ")" : "]"); + } else if (customProperty && colon$4 && type === "{") { + if (!bracket) bracket = token$1; + brackets$1.push("}"); + } else if (brackets$1.length === 0) { + if (type === ";") if (colon$4) { + this.decl(tokens$3, customProperty); + return; + } else break; + else if (type === "{") { + this.rule(tokens$3); + return; + } else if (type === "}") { + this.tokenizer.back(tokens$3.pop()); + end = true; + break; + } else if (type === ":") colon$4 = true; + } else if (type === brackets$1[brackets$1.length - 1]) { + brackets$1.pop(); + if (brackets$1.length === 0) bracket = null; + } + token$1 = this.tokenizer.nextToken(); + } + if (this.tokenizer.endOfFile()) end = true; + if (brackets$1.length > 0) this.unclosedBracket(bracket); + if (end && colon$4) { + if (!customProperty) while (tokens$3.length) { + token$1 = tokens$3[tokens$3.length - 1][0]; + if (token$1 !== "space" && token$1 !== "comment") break; + this.tokenizer.back(tokens$3.pop()); + } + this.decl(tokens$3, customProperty); + } else this.unknownWord(tokens$3); + } + parse() { + let token$1; + while (!this.tokenizer.endOfFile()) { + token$1 = this.tokenizer.nextToken(); + switch (token$1[0]) { + case "space": + this.spaces += token$1[1]; + break; + case ";": + this.freeSemicolon(token$1); + break; + case "}": + this.end(token$1); + break; + case "comment": + this.comment(token$1); + break; + case "at-word": + this.atrule(token$1); + break; + case "{": + this.emptyRule(token$1); + break; + default: + this.other(token$1); + break; + } + } + this.endFile(); + } + precheckMissedSemicolon() {} + raw(node, prop, tokens$3, customProperty) { + let token$1, type; + let length = tokens$3.length; + let value = ""; + let clean = true; + let next, prev; + for (let i$5 = 0; i$5 < length; i$5 += 1) { + token$1 = tokens$3[i$5]; + type = token$1[0]; + if (type === "space" && i$5 === length - 1 && !customProperty) clean = false; + else if (type === "comment") { + prev = tokens$3[i$5 - 1] ? tokens$3[i$5 - 1][0] : "empty"; + next = tokens$3[i$5 + 1] ? tokens$3[i$5 + 1][0] : "empty"; + if (!SAFE_COMMENT_NEIGHBOR[prev] && !SAFE_COMMENT_NEIGHBOR[next]) if (value.slice(-1) === ",") clean = false; + else value += token$1[1]; + else clean = false; + } else value += token$1[1]; + } + if (!clean) { + let raw = tokens$3.reduce((all, i$5) => all + i$5[1], ""); + node.raws[prop] = { + raw, + value + }; + } + node[prop] = value; + } + rule(tokens$3) { + tokens$3.pop(); + let node = new Rule$2(); + this.init(node, tokens$3[0][2]); + node.raws.between = this.spacesAndCommentsFromEnd(tokens$3); + this.raw(node, "selector", tokens$3); + this.current = node; + } + spacesAndCommentsFromEnd(tokens$3) { + let lastTokenType; + let spaces = ""; + while (tokens$3.length) { + lastTokenType = tokens$3[tokens$3.length - 1][0]; + if (lastTokenType !== "space" && lastTokenType !== "comment") break; + spaces = tokens$3.pop()[1] + spaces; + } + return spaces; + } + spacesAndCommentsFromStart(tokens$3) { + let next; + let spaces = ""; + while (tokens$3.length) { + next = tokens$3[0][0]; + if (next !== "space" && next !== "comment") break; + spaces += tokens$3.shift()[1]; + } + return spaces; + } + spacesFromEnd(tokens$3) { + let lastTokenType; + let spaces = ""; + while (tokens$3.length) { + lastTokenType = tokens$3[tokens$3.length - 1][0]; + if (lastTokenType !== "space") break; + spaces = tokens$3.pop()[1] + spaces; + } + return spaces; + } + stringFrom(tokens$3, from) { + let result$1 = ""; + for (let i$5 = from; i$5 < tokens$3.length; i$5++) result$1 += tokens$3[i$5][1]; + tokens$3.splice(from, tokens$3.length - from); + return result$1; + } + unclosedBlock() { + let pos = this.current.source.start; + throw this.input.error("Unclosed block", pos.line, pos.column); + } + unclosedBracket(bracket) { + throw this.input.error("Unclosed bracket", { offset: bracket[2] }, { offset: bracket[2] + 1 }); + } + unexpectedClose(token$1) { + throw this.input.error("Unexpected }", { offset: token$1[2] }, { offset: token$1[2] + 1 }); + } + unknownWord(tokens$3) { + throw this.input.error("Unknown word " + tokens$3[0][1], { offset: tokens$3[0][2] }, { offset: tokens$3[0][2] + tokens$3[0][1].length }); + } + unnamedAtrule(node, token$1) { + throw this.input.error("At-rule without name", { offset: token$1[2] }, { offset: token$1[2] + token$1[1].length }); + } + }; + module.exports = Parser$9; +} }); + +//#endregion +//#region node_modules/postcss/lib/parse.js +var require_parse$3 = __commonJS({ "node_modules/postcss/lib/parse.js"(exports, module) { + let Container$10 = require_container$3(); + let Input$4 = require_input(); + let Parser$8 = require_parser$5(); + function parse$14(css, opts) { + let input = new Input$4(css, opts); + let parser$4 = new Parser$8(input); + try { + parser$4.parse(); + } catch (e) { + if (e.name === "CssSyntaxError" && opts && opts.from) { + if (/\.scss$/i.test(opts.from)) e.message += "\nYou tried to parse SCSS with the standard CSS parser; try again with the postcss-scss parser"; + else if (/\.sass/i.test(opts.from)) e.message += "\nYou tried to parse Sass with the standard CSS parser; try again with the postcss-sass parser"; + else if (/\.less$/i.test(opts.from)) e.message += "\nYou tried to parse Less with the standard CSS parser; try again with the postcss-less parser"; + } + throw e; + } + return parser$4.root; + } + module.exports = parse$14; + parse$14.default = parse$14; + Container$10.registerParse(parse$14); +} }); + +//#endregion +//#region node_modules/postcss/lib/warning.js +var require_warning = __commonJS({ "node_modules/postcss/lib/warning.js"(exports, module) { + var Warning$3 = class { + constructor(text, opts = {}) { + this.type = "warning"; + this.text = text; + if (opts.node && opts.node.source) { + let range$3 = opts.node.rangeBy(opts); + this.line = range$3.start.line; + this.column = range$3.start.column; + this.endLine = range$3.end.line; + this.endColumn = range$3.end.column; + } + for (let opt in opts) this[opt] = opts[opt]; + } + toString() { + if (this.node) return this.node.error(this.text, { + index: this.index, + plugin: this.plugin, + word: this.word + }).message; + if (this.plugin) return this.plugin + ": " + this.text; + return this.text; + } + }; + module.exports = Warning$3; + Warning$3.default = Warning$3; +} }); + +//#endregion +//#region node_modules/postcss/lib/result.js +var require_result = __commonJS({ "node_modules/postcss/lib/result.js"(exports, module) { + let Warning$2 = require_warning(); + var Result$4 = class { + get content() { + return this.css; + } + constructor(processor, root$6, opts) { + this.processor = processor; + this.messages = []; + this.root = root$6; + this.opts = opts; + this.css = void 0; + this.map = void 0; + } + toString() { + return this.css; + } + warn(text, opts = {}) { + if (!opts.plugin) { + if (this.lastPlugin && this.lastPlugin.postcssPlugin) opts.plugin = this.lastPlugin.postcssPlugin; + } + let warning = new Warning$2(text, opts); + this.messages.push(warning); + return warning; + } + warnings() { + return this.messages.filter((i$5) => i$5.type === "warning"); + } + }; + module.exports = Result$4; + Result$4.default = Result$4; +} }); + +//#endregion +//#region node_modules/postcss/lib/warn-once.js +var require_warn_once = __commonJS({ "node_modules/postcss/lib/warn-once.js"(exports, module) { + let printed = {}; + module.exports = function warnOnce$3(message) { + if (printed[message]) return; + printed[message] = true; + if (typeof console !== "undefined" && console.warn) console.warn(message); + }; +} }); + +//#endregion +//#region node_modules/postcss/lib/lazy-result.js +var require_lazy_result = __commonJS({ "node_modules/postcss/lib/lazy-result.js"(exports, module) { + let Container$9 = require_container$3(); + let Document$5 = require_document(); + let MapGenerator$1 = require_map_generator(); + let parse$13 = require_parse$3(); + let Result$3 = require_result(); + let Root$6 = require_root$3(); + let stringify$10 = require_stringify$2(); + let { isClean, my } = require_symbols(); + let warnOnce$2 = require_warn_once(); + const TYPE_TO_CLASS_NAME = { + atrule: "AtRule", + comment: "Comment", + decl: "Declaration", + document: "Document", + root: "Root", + rule: "Rule" + }; + const PLUGIN_PROPS = { + AtRule: true, + AtRuleExit: true, + Comment: true, + CommentExit: true, + Declaration: true, + DeclarationExit: true, + Document: true, + DocumentExit: true, + Once: true, + OnceExit: true, + postcssPlugin: true, + prepare: true, + Root: true, + RootExit: true, + Rule: true, + RuleExit: true + }; + const NOT_VISITORS = { + Once: true, + postcssPlugin: true, + prepare: true + }; + const CHILDREN = 0; + function isPromise$1(obj) { + return typeof obj === "object" && typeof obj.then === "function"; + } + function getEvents(node) { + let key = false; + let type = TYPE_TO_CLASS_NAME[node.type]; + if (node.type === "decl") key = node.prop.toLowerCase(); + else if (node.type === "atrule") key = node.name.toLowerCase(); + if (key && node.append) return [ + type, + type + "-" + key, + CHILDREN, + type + "Exit", + type + "Exit-" + key + ]; + else if (key) return [ + type, + type + "-" + key, + type + "Exit", + type + "Exit-" + key + ]; + else if (node.append) return [ + type, + CHILDREN, + type + "Exit" + ]; + else return [type, type + "Exit"]; + } + function toStack(node) { + let events; + if (node.type === "document") events = [ + "Document", + CHILDREN, + "DocumentExit" + ]; + else if (node.type === "root") events = [ + "Root", + CHILDREN, + "RootExit" + ]; + else events = getEvents(node); + return { + eventIndex: 0, + events, + iterator: 0, + node, + visitorIndex: 0, + visitors: [] + }; + } + function cleanMarks(node) { + node[isClean] = false; + if (node.nodes) node.nodes.forEach((i$5) => cleanMarks(i$5)); + return node; + } + let postcss$2 = {}; + var LazyResult$2 = class LazyResult$2 { + get content() { + return this.stringify().content; + } + get css() { + return this.stringify().css; + } + get map() { + return this.stringify().map; + } + get messages() { + return this.sync().messages; + } + get opts() { + return this.result.opts; + } + get processor() { + return this.result.processor; + } + get root() { + return this.sync().root; + } + get [Symbol.toStringTag]() { + return "LazyResult"; + } + constructor(processor, css, opts) { + this.stringified = false; + this.processed = false; + let root$6; + if (typeof css === "object" && css !== null && (css.type === "root" || css.type === "document")) root$6 = cleanMarks(css); + else if (css instanceof LazyResult$2 || css instanceof Result$3) { + root$6 = cleanMarks(css.root); + if (css.map) { + if (typeof opts.map === "undefined") opts.map = {}; + if (!opts.map.inline) opts.map.inline = false; + opts.map.prev = css.map; + } + } else { + let parser$4 = parse$13; + if (opts.syntax) parser$4 = opts.syntax.parse; + if (opts.parser) parser$4 = opts.parser; + if (parser$4.parse) parser$4 = parser$4.parse; + try { + root$6 = parser$4(css, opts); + } catch (error) { + this.processed = true; + this.error = error; + } + if (root$6 && !root$6[my]) + /* c8 ignore next 2 */ + Container$9.rebuild(root$6); + } + this.result = new Result$3(processor, root$6, opts); + this.helpers = { + ...postcss$2, + postcss: postcss$2, + result: this.result + }; + this.plugins = this.processor.plugins.map((plugin$2) => { + if (typeof plugin$2 === "object" && plugin$2.prepare) return { + ...plugin$2, + ...plugin$2.prepare(this.result) + }; + else return plugin$2; + }); + } + async() { + if (this.error) return Promise.reject(this.error); + if (this.processed) return Promise.resolve(this.result); + if (!this.processing) this.processing = this.runAsync(); + return this.processing; + } + catch(onRejected) { + return this.async().catch(onRejected); + } + finally(onFinally) { + return this.async().then(onFinally, onFinally); + } + getAsyncError() { + throw new Error("Use process(css).then(cb) to work with async plugins"); + } + handleError(error, node) { + let plugin$2 = this.result.lastPlugin; + try { + if (node) node.addToError(error); + this.error = error; + if (error.name === "CssSyntaxError" && !error.plugin) { + error.plugin = plugin$2.postcssPlugin; + error.setMessage(); + } else if (plugin$2.postcssVersion) { + let pluginName = plugin$2.postcssPlugin; + let pluginVer = plugin$2.postcssVersion; + let runtimeVer = this.result.processor.version; + let a = pluginVer.split("."); + let b$1 = runtimeVer.split("."); + if (a[0] !== b$1[0] || parseInt(a[1]) > parseInt(b$1[1])) console.error("Unknown error from PostCSS plugin. Your current PostCSS version is " + runtimeVer + ", but " + pluginName + " uses " + pluginVer + ". Perhaps this is the source of the error below."); + } + } catch (err) { + /* c8 ignore next 3 */ + if (console && console.error) console.error(err); + } + return error; + } + prepareVisitors() { + this.listeners = {}; + let add = (plugin$2, type, cb$1) => { + if (!this.listeners[type]) this.listeners[type] = []; + this.listeners[type].push([plugin$2, cb$1]); + }; + for (let plugin$2 of this.plugins) if (typeof plugin$2 === "object") for (let event in plugin$2) { + if (!PLUGIN_PROPS[event] && /^[A-Z]/.test(event)) throw new Error(`Unknown event ${event} in ${plugin$2.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`); + if (!NOT_VISITORS[event]) { + if (typeof plugin$2[event] === "object") for (let filter$3 in plugin$2[event]) if (filter$3 === "*") add(plugin$2, event, plugin$2[event][filter$3]); + else add(plugin$2, event + "-" + filter$3.toLowerCase(), plugin$2[event][filter$3]); + else if (typeof plugin$2[event] === "function") add(plugin$2, event, plugin$2[event]); + } + } + this.hasListener = Object.keys(this.listeners).length > 0; + } + async runAsync() { + this.plugin = 0; + for (let i$5 = 0; i$5 < this.plugins.length; i$5++) { + let plugin$2 = this.plugins[i$5]; + let promise = this.runOnRoot(plugin$2); + if (isPromise$1(promise)) try { + await promise; + } catch (error) { + throw this.handleError(error); + } + } + this.prepareVisitors(); + if (this.hasListener) { + let root$6 = this.result.root; + while (!root$6[isClean]) { + root$6[isClean] = true; + let stack = [toStack(root$6)]; + while (stack.length > 0) { + let promise = this.visitTick(stack); + if (isPromise$1(promise)) try { + await promise; + } catch (e) { + let node = stack[stack.length - 1].node; + throw this.handleError(e, node); + } + } + } + if (this.listeners.OnceExit) for (let [plugin$2, visitor] of this.listeners.OnceExit) { + this.result.lastPlugin = plugin$2; + try { + if (root$6.type === "document") { + let roots = root$6.nodes.map((subRoot) => visitor(subRoot, this.helpers)); + await Promise.all(roots); + } else await visitor(root$6, this.helpers); + } catch (e) { + throw this.handleError(e); + } + } + } + this.processed = true; + return this.stringify(); + } + runOnRoot(plugin$2) { + this.result.lastPlugin = plugin$2; + try { + if (typeof plugin$2 === "object" && plugin$2.Once) { + if (this.result.root.type === "document") { + let roots = this.result.root.nodes.map((root$6) => plugin$2.Once(root$6, this.helpers)); + if (isPromise$1(roots[0])) return Promise.all(roots); + return roots; + } + return plugin$2.Once(this.result.root, this.helpers); + } else if (typeof plugin$2 === "function") return plugin$2(this.result.root, this.result); + } catch (error) { + throw this.handleError(error); + } + } + stringify() { + if (this.error) throw this.error; + if (this.stringified) return this.result; + this.stringified = true; + this.sync(); + let opts = this.result.opts; + let str$3 = stringify$10; + if (opts.syntax) str$3 = opts.syntax.stringify; + if (opts.stringifier) str$3 = opts.stringifier; + if (str$3.stringify) str$3 = str$3.stringify; + let map$1 = new MapGenerator$1(str$3, this.result.root, this.result.opts); + let data$2 = map$1.generate(); + this.result.css = data$2[0]; + this.result.map = data$2[1]; + return this.result; + } + sync() { + if (this.error) throw this.error; + if (this.processed) return this.result; + this.processed = true; + if (this.processing) throw this.getAsyncError(); + for (let plugin$2 of this.plugins) { + let promise = this.runOnRoot(plugin$2); + if (isPromise$1(promise)) throw this.getAsyncError(); + } + this.prepareVisitors(); + if (this.hasListener) { + let root$6 = this.result.root; + while (!root$6[isClean]) { + root$6[isClean] = true; + this.walkSync(root$6); + } + if (this.listeners.OnceExit) if (root$6.type === "document") for (let subRoot of root$6.nodes) this.visitSync(this.listeners.OnceExit, subRoot); + else this.visitSync(this.listeners.OnceExit, root$6); + } + return this.result; + } + then(onFulfilled, onRejected) { + if (!("from" in this.opts)) warnOnce$2("Without `from` option PostCSS could generate wrong source map and will not find Browserslist config. Set it to CSS file path or to `undefined` to prevent this warning."); + return this.async().then(onFulfilled, onRejected); + } + toString() { + return this.css; + } + visitSync(visitors$1, node) { + for (let [plugin$2, visitor] of visitors$1) { + this.result.lastPlugin = plugin$2; + let promise; + try { + promise = visitor(node, this.helpers); + } catch (e) { + throw this.handleError(e, node.proxyOf); + } + if (node.type !== "root" && node.type !== "document" && !node.parent) return true; + if (isPromise$1(promise)) throw this.getAsyncError(); + } + } + visitTick(stack) { + let visit$1 = stack[stack.length - 1]; + let { node, visitors: visitors$1 } = visit$1; + if (node.type !== "root" && node.type !== "document" && !node.parent) { + stack.pop(); + return; + } + if (visitors$1.length > 0 && visit$1.visitorIndex < visitors$1.length) { + let [plugin$2, visitor] = visitors$1[visit$1.visitorIndex]; + visit$1.visitorIndex += 1; + if (visit$1.visitorIndex === visitors$1.length) { + visit$1.visitors = []; + visit$1.visitorIndex = 0; + } + this.result.lastPlugin = plugin$2; + try { + return visitor(node.toProxy(), this.helpers); + } catch (e) { + throw this.handleError(e, node); + } + } + if (visit$1.iterator !== 0) { + let iterator = visit$1.iterator; + let child; + while (child = node.nodes[node.indexes[iterator]]) { + node.indexes[iterator] += 1; + if (!child[isClean]) { + child[isClean] = true; + stack.push(toStack(child)); + return; + } + } + visit$1.iterator = 0; + delete node.indexes[iterator]; + } + let events = visit$1.events; + while (visit$1.eventIndex < events.length) { + let event = events[visit$1.eventIndex]; + visit$1.eventIndex += 1; + if (event === CHILDREN) { + if (node.nodes && node.nodes.length) { + node[isClean] = true; + visit$1.iterator = node.getIterator(); + } + return; + } else if (this.listeners[event]) { + visit$1.visitors = this.listeners[event]; + return; + } + } + stack.pop(); + } + walkSync(node) { + node[isClean] = true; + let events = getEvents(node); + for (let event of events) if (event === CHILDREN) { + if (node.nodes) node.each((child) => { + if (!child[isClean]) this.walkSync(child); + }); + } else { + let visitors$1 = this.listeners[event]; + if (visitors$1) { + if (this.visitSync(visitors$1, node.toProxy())) return; + } + } + } + warnings() { + return this.sync().warnings(); + } + }; + LazyResult$2.registerPostcss = (dependant) => { + postcss$2 = dependant; + }; + module.exports = LazyResult$2; + LazyResult$2.default = LazyResult$2; + Root$6.registerLazyResult(LazyResult$2); + Document$5.registerLazyResult(LazyResult$2); +} }); + +//#endregion +//#region node_modules/postcss/lib/no-work-result.js +var require_no_work_result = __commonJS({ "node_modules/postcss/lib/no-work-result.js"(exports, module) { + let MapGenerator = require_map_generator(); + let parse$12 = require_parse$3(); + const Result$2 = require_result(); + let stringify$9 = require_stringify$2(); + let warnOnce$1 = require_warn_once(); + var NoWorkResult$1 = class { + get content() { + return this.result.css; + } + get css() { + return this.result.css; + } + get map() { + return this.result.map; + } + get messages() { + return []; + } + get opts() { + return this.result.opts; + } + get processor() { + return this.result.processor; + } + get root() { + if (this._root) return this._root; + let root$6; + let parser$4 = parse$12; + try { + root$6 = parser$4(this._css, this._opts); + } catch (error) { + this.error = error; + } + if (this.error) throw this.error; + else { + this._root = root$6; + return root$6; + } + } + get [Symbol.toStringTag]() { + return "NoWorkResult"; + } + constructor(processor, css, opts) { + css = css.toString(); + this.stringified = false; + this._processor = processor; + this._css = css; + this._opts = opts; + this._map = void 0; + let root$6; + let str$3 = stringify$9; + this.result = new Result$2(this._processor, root$6, this._opts); + this.result.css = css; + let self$1 = this; + Object.defineProperty(this.result, "root", { get() { + return self$1.root; + } }); + let map$1 = new MapGenerator(str$3, root$6, this._opts, css); + if (map$1.isMap()) { + let [generatedCSS, generatedMap] = map$1.generate(); + if (generatedCSS) this.result.css = generatedCSS; + if (generatedMap) this.result.map = generatedMap; + } else { + map$1.clearAnnotation(); + this.result.css = map$1.css; + } + } + async() { + if (this.error) return Promise.reject(this.error); + return Promise.resolve(this.result); + } + catch(onRejected) { + return this.async().catch(onRejected); + } + finally(onFinally) { + return this.async().then(onFinally, onFinally); + } + sync() { + if (this.error) throw this.error; + return this.result; + } + then(onFulfilled, onRejected) { + if (!("from" in this._opts)) warnOnce$1("Without `from` option PostCSS could generate wrong source map and will not find Browserslist config. Set it to CSS file path or to `undefined` to prevent this warning."); + return this.async().then(onFulfilled, onRejected); + } + toString() { + return this._css; + } + warnings() { + return []; + } + }; + module.exports = NoWorkResult$1; + NoWorkResult$1.default = NoWorkResult$1; +} }); + +//#endregion +//#region node_modules/postcss/lib/processor.js +var require_processor$3 = __commonJS({ "node_modules/postcss/lib/processor.js"(exports, module) { + let Document$4 = require_document(); + let LazyResult$1 = require_lazy_result(); + let NoWorkResult = require_no_work_result(); + let Root$5 = require_root$3(); + var Processor$5 = class { + constructor(plugins = []) { + this.version = "8.5.3"; + this.plugins = this.normalize(plugins); + } + normalize(plugins) { + let normalized = []; + for (let i$5 of plugins) { + if (i$5.postcss === true) i$5 = i$5(); + else if (i$5.postcss) i$5 = i$5.postcss; + if (typeof i$5 === "object" && Array.isArray(i$5.plugins)) normalized = normalized.concat(i$5.plugins); + else if (typeof i$5 === "object" && i$5.postcssPlugin) normalized.push(i$5); + else if (typeof i$5 === "function") normalized.push(i$5); + else if (typeof i$5 === "object" && (i$5.parse || i$5.stringify)) throw new Error("PostCSS syntaxes cannot be used as plugins. Instead, please use one of the syntax/parser/stringifier options as outlined in your PostCSS runner documentation."); + else throw new Error(i$5 + " is not a PostCSS plugin"); + } + return normalized; + } + process(css, opts = {}) { + if (!this.plugins.length && !opts.parser && !opts.stringifier && !opts.syntax) return new NoWorkResult(this, css, opts); + else return new LazyResult$1(this, css, opts); + } + use(plugin$2) { + this.plugins = this.plugins.concat(this.normalize([plugin$2])); + return this; + } + }; + module.exports = Processor$5; + Processor$5.default = Processor$5; + Root$5.registerProcessor(Processor$5); + Document$4.registerProcessor(Processor$5); +} }); + +//#endregion +//#region node_modules/postcss/lib/postcss.js +var require_postcss = __commonJS({ "node_modules/postcss/lib/postcss.js"(exports, module) { + let AtRule$2 = require_at_rule(); + let Comment$8 = require_comment$3(); + let Container$8 = require_container$3(); + let CssSyntaxError$1 = require_css_syntax_error(); + let Declaration$1 = require_declaration(); + let Document$3 = require_document(); + let fromJSON$1 = require_fromJSON(); + let Input$3 = require_input(); + let LazyResult = require_lazy_result(); + let list$1 = require_list(); + let Node$15 = require_node$6(); + let parse$11 = require_parse$3(); + let Processor$4 = require_processor$3(); + let Result$1 = require_result(); + let Root$4 = require_root$3(); + let Rule$1 = require_rule(); + let stringify$8 = require_stringify$2(); + let Warning$1 = require_warning(); + function postcss$1(...plugins) { + if (plugins.length === 1 && Array.isArray(plugins[0])) plugins = plugins[0]; + return new Processor$4(plugins); + } + postcss$1.plugin = function plugin$2(name, initializer) { + let warningPrinted = false; + function creator(...args) { + if (console && console.warn && !warningPrinted) { + warningPrinted = true; + console.warn(name + ": postcss.plugin was deprecated. Migration guide:\nhttps://evilmartians.com/chronicles/postcss-8-plugin-migration"); + if (process.env.LANG && process.env.LANG.startsWith("cn")) + /* c8 ignore next 7 */ + console.warn(name + ": 里面 postcss.plugin 被弃用. 迁移指南:\nhttps://www.w3ctech.com/topic/2226"); + } + let transformer = initializer(...args); + transformer.postcssPlugin = name; + transformer.postcssVersion = new Processor$4().version; + return transformer; + } + let cache$3; + Object.defineProperty(creator, "postcss", { get() { + if (!cache$3) cache$3 = creator(); + return cache$3; + } }); + creator.process = function(css, processOpts, pluginOpts) { + return postcss$1([creator(pluginOpts)]).process(css, processOpts); + }; + return creator; + }; + postcss$1.stringify = stringify$8; + postcss$1.parse = parse$11; + postcss$1.fromJSON = fromJSON$1; + postcss$1.list = list$1; + postcss$1.comment = (defaults$2) => new Comment$8(defaults$2); + postcss$1.atRule = (defaults$2) => new AtRule$2(defaults$2); + postcss$1.decl = (defaults$2) => new Declaration$1(defaults$2); + postcss$1.rule = (defaults$2) => new Rule$1(defaults$2); + postcss$1.root = (defaults$2) => new Root$4(defaults$2); + postcss$1.document = (defaults$2) => new Document$3(defaults$2); + postcss$1.CssSyntaxError = CssSyntaxError$1; + postcss$1.Declaration = Declaration$1; + postcss$1.Container = Container$8; + postcss$1.Processor = Processor$4; + postcss$1.Document = Document$3; + postcss$1.Comment = Comment$8; + postcss$1.Warning = Warning$1; + postcss$1.AtRule = AtRule$2; + postcss$1.Result = Result$1; + postcss$1.Input = Input$3; + postcss$1.Rule = Rule$1; + postcss$1.Root = Root$4; + postcss$1.Node = Node$15; + LazyResult.registerPostcss(postcss$1); + module.exports = postcss$1; + postcss$1.default = postcss$1; +} }); +var import_postcss = __toESM(require_postcss(), 1); + +//#endregion +//#region node_modules/postcss/lib/postcss.mjs +var postcss_default = import_postcss.default; +const stringify$7 = import_postcss.default.stringify; +const fromJSON = import_postcss.default.fromJSON; +const plugin$1 = import_postcss.default.plugin; +const parse$10 = import_postcss.default.parse; +const list = import_postcss.default.list; +const document$1 = import_postcss.default.document; +const comment$6 = import_postcss.default.comment; +const atRule = import_postcss.default.atRule; +const rule = import_postcss.default.rule; +const decl = import_postcss.default.decl; +const root$5 = import_postcss.default.root; +const CssSyntaxError = import_postcss.default.CssSyntaxError; +const Declaration = import_postcss.default.Declaration; +const Container$7 = import_postcss.default.Container; +const Processor$3 = import_postcss.default.Processor; +const Document$2 = import_postcss.default.Document; +const Comment$7 = import_postcss.default.Comment; +const Warning = import_postcss.default.Warning; +const AtRule$1 = import_postcss.default.AtRule; +const Result = import_postcss.default.Result; +const Input$2 = import_postcss.default.Input; +const Rule = import_postcss.default.Rule; +const Root$3 = import_postcss.default.Root; +const Node$14 = import_postcss.default.Node; + +//#endregion +//#region node_modules/postcss-values-parser/lib/walker.js +var require_walker = __commonJS({ "node_modules/postcss-values-parser/lib/walker.js"(exports, module) { + const Container$6 = require_container$3(); + const registerWalker$9 = (constructor) => { + let walkerName = `walk${constructor.name}`; + if (walkerName.lastIndexOf("s") !== walkerName.length - 1) walkerName += "s"; + /* istanbul ignore next */ + if (Container$6.prototype[walkerName]) return; + Container$6.prototype[walkerName] = function walker(callback) { + return this.walkType(constructor, callback); + }; + }; + Container$6.prototype.walkType = function walkType(type, callback) { + /* istanbul ignore next */ + if (!type || !callback) throw new Error("Parameters {type} and {callback} are required."); + const isTypeCallable = typeof type === "function"; + return this.walk((node, index$1) => { + if (isTypeCallable && node instanceof type || !isTypeCallable && node.type === type) return callback.call(this, node, index$1); + }); + }; + module.exports = { registerWalker: registerWalker$9 }; +} }); + +//#endregion +//#region node_modules/postcss-values-parser/lib/ValuesStringifier.js +var require_ValuesStringifier = __commonJS({ "node_modules/postcss-values-parser/lib/ValuesStringifier.js"(exports, module) { + const Stringifier = require_stringifier(); + module.exports = class ValuesStringifier extends Stringifier { + static stringify(node, builder) { + const stringifier = new ValuesStringifier(builder); + stringifier.stringify(node); + } + basic(node, value) { + const print = value || node.value; + const after$1 = node.raws.after ? this.raw(node, "after") || "" : ""; + this.builder(print, node, "start"); + this.builder(after$1, node, "end"); + } + atword(...args) { + this.atrule(...args); + } + comment(node) { + if (node.inline) { + const left = this.raw(node, "left", "commentLeft"); + const right = this.raw(node, "right", "commentRight"); + this.builder(`//${left}${node.text}${right}`, node); + } else super.comment(node); + } + func(node) { + const after$1 = this.raw(node, "after") || ""; + this.builder(`${node.name}(`, node, "start"); + for (const child of node.nodes) { + const before$1 = child.raws.before ? this.raw(child, "before") : ""; + if (before$1) this.builder(before$1); + this.stringify(child); + } + this.builder(`)${after$1}`, node, "end"); + } + interpolation(node) { + this.basic(node, node.prefix + node.params); + } + numeric(node) { + const print = node.value + node.unit; + this.basic(node, print); + } + operator(node) { + this.basic(node); + } + punctuation(node) { + this.basic(node); + } + quoted(node) { + this.basic(node); + } + unicodeRange(node) { + this.basic(node); + } + word(node) { + this.basic(node); + } + }; +} }); + +//#endregion +//#region node_modules/postcss-values-parser/lib/nodes/AtWord.js +var require_AtWord = __commonJS({ "node_modules/postcss-values-parser/lib/nodes/AtWord.js"(exports, module) { + const AtRule = require_node$6(); + const { registerWalker: registerWalker$8 } = require_walker(); + const { stringify: stringify$6 } = require_ValuesStringifier(); + var AtWord$1 = class extends AtRule { + toString(stringifier = stringify$6) { + return super.toString(stringifier); + } + }; + registerWalker$8(AtWord$1); + module.exports = AtWord$1; +} }); + +//#endregion +//#region node_modules/postcss-values-parser/lib/nodes/Comment.js +var require_Comment = __commonJS({ "node_modules/postcss-values-parser/lib/nodes/Comment.js"(exports, module) { + const PostCssComment = require_comment$3(); + const { stringify: stringify$5 } = require_ValuesStringifier(); + const inlineRegex = /(\/\/)/; + var Comment$6 = class extends PostCssComment { + static testInline(token$1) { + return inlineRegex.test(token$1[1]); + } + static tokenizeNext(tokens$3, parser$4) { + const [first$1] = tokens$3; + const newlineIndex = tokens$3.findIndex((t$7) => /\n/.test(t$7[1])); + let bits = tokens$3; + let rest$1 = []; + if (newlineIndex >= 0) { + bits = tokens$3.slice(0, newlineIndex); + rest$1 = tokens$3.slice(newlineIndex); + } + bits = bits.map((t$7) => t$7[1]); + const text = bits.concat("~~").join(""); + const last$3 = bits[bits.length - 1]; + const newToken = [ + "comment", + text, + first$1[2], + first$1[3], + last$3[2], + last$3[3] + ]; + parser$4.back([newToken, ...rest$1]); + } + static tokenizeInline(tokens$3, parser$4) { + const [first$1, ...rest$1] = tokens$3; + const bits = first$1[1].split(/(\/\/.+)/).filter((t$7) => !!t$7); + const newTokens = []; + const [, , startLine, , endLine] = first$1; + let [, , , startChar, , endChar] = first$1; + for (let bit of bits) { + const comment$7 = bit.slice(0, 2) === "//"; + const type = comment$7 ? "comment" : "word"; + if (comment$7) bit += "~~"; + if (bit !== bits[0]) startChar = endChar + 1; + endChar = startChar + bit.length - 1; + newTokens.push([ + type, + bit, + startLine, + startChar, + endLine, + endChar + ]); + } + parser$4.back(newTokens.concat(rest$1)); + } + toString(stringifier = stringify$5) { + return super.toString(stringifier); + } + }; + module.exports = Comment$6; +} }); + +//#endregion +//#region node_modules/postcss-values-parser/lib/tokenize.js +var require_tokenize$3 = __commonJS({ "node_modules/postcss-values-parser/lib/tokenize.js"(exports, module) { + const Input$1 = require_input(); + const tokenizer = require_tokenize$4(); + const operators$1 = [ + "*", + "-", + "%", + "+", + "/" + ]; + const operRegex$1 = /([*/])/g; + const brackets = (token$1, tokenize$4) => { + const [, , startLine, startChar, endLine, endChar] = token$1; + const part = token$1[1].slice(1, token$1[1].length - 1); + const subTokens = getTokens$2(part); + for (const sub of subTokens) if (sub[0] !== "space") { + const length = sub[5] - sub[3]; + sub[2] = startLine; + sub[3] += startChar; + sub[4] += endLine - 1; + sub[5] = sub[3] + length; + } + const tokens$3 = [[ + "(", + "(", + startLine, + startChar, + startLine, + startChar + ], ...subTokens]; + tokens$3.push([ + ")", + ")", + startLine, + endChar, + endLine, + endChar + ]); + for (const tokn of tokens$3.reverse()) tokenize$4.back(tokn); + }; + const comma$4 = (token$1, tokenize$4) => { + const bits = token$1[1].split(/([,])/); + const tokens$3 = []; + const [, , startLine, , endLine] = token$1; + let [, , , startChar, , endChar] = token$1; + for (let bit of bits) { + bit = bit || ","; + const name = bit === "," ? "comma" : "word"; + if (bit !== bits[0]) startChar = endChar + 1; + endChar = startChar + bit.length - 1; + tokens$3.push([ + name, + bit, + startLine, + startChar, + endLine, + endChar + ]); + } + for (const tokn of tokens$3.reverse()) tokenize$4.back(tokn); + }; + const getTokens$2 = (what) => { + const input = new Input$1(what, {}); + const tokenize$4 = wrapTokenizer(input); + const result$1 = []; + while (!tokenize$4.endOfFile()) { + const token$1 = tokenize$4.nextToken(); + result$1.push(token$1); + } + return result$1; + }; + const operator = (token$1, tokenize$4) => { + const [, value, startLine, , endLine, endChar] = token$1; + const parts = value.split(operRegex$1); + let [, , , startChar] = token$1; + const tokens$3 = parts.map((part) => { + const type = operators$1.includes(part) ? "operator" : "word"; + const newToken = [ + type, + part, + startLine, + startChar, + endLine, + endChar + ]; + startChar += part.length; + return newToken; + }); + for (const tokn of tokens$3.reverse()) tokenize$4.back(tokn); + }; + const wrapTokenizer = (...args) => { + const tokenize$4 = tokenizer(...args); + const ogNextToken = tokenize$4.nextToken; + tokenize$4.nextToken = (...nextArgs) => { + let token$1 = ogNextToken(...nextArgs); + if (!token$1) return token$1; + const [type, value] = token$1; + if (type === "brackets") { + brackets(token$1, tokenize$4); + token$1 = ogNextToken(...nextArgs); + } else if (type === "word") { + if (operators$1.includes(value)) token$1[0] = "operator"; + else if (operRegex$1.test(value)) { + operator(token$1, tokenize$4); + token$1 = ogNextToken(...nextArgs); + } else if (value.length > 1 && value.includes(",")) { + comma$4(token$1, tokenize$4); + token$1 = ogNextToken(...nextArgs); + } + } + return token$1; + }; + return tokenize$4; + }; + module.exports = { + getTokens: getTokens$2, + tokenizer: wrapTokenizer + }; +} }); + +//#endregion +//#region node_modules/postcss-values-parser/lib/nodes/Container.js +var require_Container = __commonJS({ "node_modules/postcss-values-parser/lib/nodes/Container.js"(exports, module) { + const PostCssContainer = require_container$3(); + const { stringify: stringify$4 } = require_ValuesStringifier(); + var Container$5 = class extends PostCssContainer { + toString(stringifier = stringify$4) { + return super.toString(stringifier); + } + }; + module.exports = Container$5; +} }); + +//#endregion +//#region node_modules/postcss-values-parser/lib/nodes/Node.js +var require_Node = __commonJS({ "node_modules/postcss-values-parser/lib/nodes/Node.js"(exports, module) { + const PostCssNode = require_node$6(); + const { stringify: stringify$3 } = require_ValuesStringifier(); + var Node$13 = class extends PostCssNode { + toString(stringifier = stringify$3) { + return super.toString(stringifier || {}); + } + }; + module.exports = Node$13; +} }); + +//#endregion +//#region node_modules/postcss-values-parser/lib/nodes/Punctuation.js +var require_Punctuation = __commonJS({ "node_modules/postcss-values-parser/lib/nodes/Punctuation.js"(exports, module) { + const { getTokens: getTokens$1 } = require_tokenize$3(); + const { registerWalker: registerWalker$7 } = require_walker(); + const Node$12 = require_Node(); + /** + * @desc Punctuation nodes can contain: + * , : ( ) { } [ ] + */ + var Punctuation$2 = class Punctuation$2 extends Node$12 { + constructor(options) { + super(options); + this.type = "punctuation"; + } + static get chars() { + return [ + ",", + ":", + "(", + ")", + "[", + "]", + "{", + "}" + ]; + } + static fromTokens(tokens$3, parser$4) { + parser$4.fromFirst(tokens$3, Punctuation$2); + } + static tokenizeBrackets(tokens$3, parser$4) { + const [first$1, ...rest$1] = tokens$3; + const bits = first$1[1].split(/([()])/g).filter((t$7) => !!t$7); + const newTokens = []; + const [, , startLine, , endLine] = first$1; + let [, , , startChar, , endChar] = first$1; + for (const bit of bits) { + let type = bit === "(" ? "(" : bit === ")" ? ")" : "word"; + if (/^\s+$/.test(bit)) type = "space"; + if (bit !== bits[0]) startChar = endChar + 1; + endChar = startChar + bit.length - 1; + if (type === "word") { + const wordTokens = getTokens$1(bit); + for (const token$1 of wordTokens) { + token$1[3] += startChar - 1; + newTokens.push(token$1); + } + } else newTokens.push([ + type, + bit, + startLine, + startChar, + endLine, + endChar + ]); + } + parser$4.back(newTokens.concat(rest$1)); + } + static tokenizeCommas(tokens$3, parser$4) { + const [first$1, ...rest$1] = tokens$3; + const bits = first$1[1].split(/([,])/g).filter((t$7) => !!t$7); + const newTokens = []; + const [, , startLine, , endLine] = first$1; + let [, , , startChar, , endChar] = first$1; + for (const bit of bits) { + if (bit !== bits[0]) startChar = endChar + 1; + endChar = startChar + bit.length - 1; + newTokens.push([ + "word", + bit, + startLine, + startChar, + endLine, + endChar + ]); + } + parser$4.back(newTokens.concat(rest$1)); + } + }; + registerWalker$7(Punctuation$2); + module.exports = Punctuation$2; +} }); + +//#endregion +//#region node_modules/postcss-values-parser/lib/nodes/Func.js +var require_Func = __commonJS({ "node_modules/postcss-values-parser/lib/nodes/Func.js"(exports, module) { + const { getTokens } = require_tokenize$3(); + const { registerWalker: registerWalker$6 } = require_walker(); + const Container$4 = require_Container(); + const Punctuation$1 = require_Punctuation(); + const cssFunctions = [ + "annotation", + "attr", + "blur", + "brightness", + "calc", + "character-variant", + "circle", + "contrast", + "cubic-bezier", + "dir", + "drop-shadow", + "element", + "ellipse", + "grayscale", + "hsl", + "hsla", + "hue-rotate", + "image", + "inset", + "invert", + "lang", + "linear-gradient", + "matrix", + "matrix3d", + "minmax", + "not", + "nth-child", + "nth-last-child", + "nth-last-of-type", + "nth-of-type", + "opacity", + "ornaments", + "perspective", + "polygon", + "radial-gradient", + "rect", + "repeat", + "repeating-linear-gradient", + "repeating-radial-gradient", + "rgb", + "rgba", + "rotate", + "rotatex", + "rotatey", + "rotatez", + "rotate3d", + "saturate", + "scale", + "scalex", + "scaley", + "scalez", + "scale3d", + "sepia", + "skew", + "skewx", + "skewy", + "steps", + "styleset", + "stylistic", + "swash", + "symbols", + "translate", + "translatex", + "translatey", + "translatez", + "translate3d", + "url", + "var" + ]; + const vendorPrefixes = [ + "-webkit-", + "-moz-", + "-ms-", + "-o-" + ]; + const reFunctions = new RegExp(`^(${vendorPrefixes.join("|")})?(${cssFunctions.join("|")})`, "i"); + const rePunctuation = new RegExp(`^(\\${Punctuation$1.chars.join("|\\")})`); + const reColorFunctions = /^(hsla?|hwb|lab|lch|rgba?)$/i; + const reVar = /^var$/i; + const reVarPrefix = /^--[^\s]+$/; + var Func$2 = class Func$2 extends Container$4 { + constructor(options = {}) { + super(options); + this.type = "func"; + this.isColor = false; + this.isVar = false; + this.name = options.name || ""; + if (!this.nodes) this.nodes = []; + } + static test(tokens$3) { + return tokens$3.length > 1 && tokens$3[0][0] === "word" && !rePunctuation.test(tokens$3[0][1]) && (tokens$3[1][0] === "brackets" || tokens$3[1][0] === "("); + } + static fromTokens(tokens$3, parser$4) { + const [[, , startLine, startChar]] = tokens$3; + const [name, brackets$1] = tokens$3.splice(0, 2); + const node = new Func$2({ name: name[1] }); + let foundParens = 0; + let expectedParens = 1; + let lastToken = brackets$1; + if (!reFunctions.test(node.name) && !/^[a-zA-Z\-]+$/.test(node.name)) { + const nameTokens = getTokens(node.name); + tokens$3.unshift(...nameTokens, brackets$1); + parser$4.back(tokens$3); + return; + } + parser$4.init(node, startLine, startChar); + parser$4.current = node; + if (brackets$1[0] === "brackets") expectedParens = brackets$1[1].match(/[(]/g).length - 1; + const rightTokens = []; + for (const token$1 of tokens$3) if (foundParens < expectedParens) { + if (token$1[1] === ")") foundParens += 1; + else if (token$1[1] === "(") expectedParens += 1; + brackets$1[1] += token$1[1]; + lastToken = token$1; + } else rightTokens.push(token$1); + if (foundParens !== expectedParens) parser$4.unclosedBracket(brackets$1); + [, node.params] = brackets$1; + const params = brackets$1[1].slice(1, -1); + if (params.length) { + let opts = parser$4.options; + if (node.name === "url") opts = Object.assign({}, parser$4.options, { ignoreUnknownWords: true }); + opts.parentNode = node; + const { parse: parse$17 } = require_lib$17(); + const root$6 = parse$17(params, opts); + const { nodes: children } = root$6; + for (const child of children) node.push(child); + if (root$6.raws.after) node.last.raws.after = root$6.raws.after; + } + parser$4.end(lastToken); + parser$4.back(rightTokens); + const { lastNode } = parser$4; + const { nodes: nodes$1 } = node; + lastNode.isColor = reColorFunctions.test(lastNode.name); + lastNode.isVar = reVar.test(lastNode.name) && nodes$1.length && reVarPrefix.test(nodes$1[0].value); + } + }; + registerWalker$6(Func$2); + module.exports = Func$2; +} }); + +//#endregion +//#region node_modules/postcss-values-parser/lib/nodes/Interpolation.js +var require_Interpolation = __commonJS({ "node_modules/postcss-values-parser/lib/nodes/Interpolation.js"(exports, module) { + const { registerWalker: registerWalker$5 } = require_walker(); + const Container$3 = require_Container(); + var Interpolation$1 = class Interpolation$1 extends Container$3 { + constructor(options = {}) { + super(options); + this.type = "interpolation"; + this.prefix = options.prefix || ""; + if (!this.nodes) this.nodes = []; + } + static test(tokens$3, parser$4) { + const { prefix: prefix$1 } = parser$4.options.interpolation; + const [first$1, next] = tokens$3; + return tokens$3.length > 1 && first$1[0] === "word" && prefix$1 === first$1[1] && next[0] === "{"; + } + static fromTokens(tokens$3, parser$4) { + const [[, , startLine, startChar]] = tokens$3; + const [first$1] = tokens$3.splice(0, 2); + const [, prefix$1] = first$1; + const node = new Interpolation$1({ prefix: prefix$1 }); + const rightTokens = []; + let closed = false; + let lastToken; + let brackets$1 = "{"; + parser$4.init(node, startLine, startChar); + parser$4.current = node; + for (const token$1 of tokens$3) if (closed) rightTokens.push(token$1); + else { + if (token$1[1] === "}") closed = true; + brackets$1 += token$1[1]; + lastToken = token$1; + } + if (!closed) parser$4.unclosedBracket(first$1); + node.params = brackets$1; + const params = brackets$1.slice(1, -1); + if (params.length) { + const { parse: parse$17 } = require_lib$17(); + const { nodes: children } = parse$17(params, parser$4.options); + for (const child of children) node.push(child); + } + parser$4.end(lastToken); + parser$4.back(rightTokens); + } + }; + registerWalker$5(Interpolation$1); + module.exports = Interpolation$1; +} }); + +//#endregion +//#region node_modules/postcss-values-parser/lib/nodes/Numeric.js +var require_Numeric = __commonJS({ "node_modules/postcss-values-parser/lib/nodes/Numeric.js"(exports, module) { + const { registerWalker: registerWalker$4 } = require_walker(); + const Node$11 = require_Node(); + /** A Number is: + * 1. None or one plus or minus symbol; then + * 2. Either, + * 2.1. One or more digits; and / or, + * 2.2. One period symbol; followed by, + * 2.2.1. One or more digits; + * then, + * 3. If one "e" letter, + * 3.1. One "e" letter; followed by, + * 3.1.1. None or one plus or minus symbol; followed by, + * 3.1.1.1. One or more digits. + * @see https://drafts.csswg.org/css-syntax/#consume-a-number + */ + const numberRegex = /^([+-]?(?:\d+(?:\.\d*)?|\.\d+)(?:[Ee][+-]?\d+)?)$/; + /** A Unit is: + * 1. Either, + * 1.1. One dash; followed by, + * 1.1.1. One letter, non-ASCII, underscore, dash; or, + * 1.1.2. One escape slash; followed by, + * 1.1.2.1 One non-newline; + * or, + * 1.2. One letter, non-ASCII, underscore; or, + * 1.3. One escape slash; followed by, + * 1.3.1. One non-newline; + * then, + * 2. Zero or more of; + * 2.1 One letter, non-ASCII, underscore, dash; then / or, + * 2.2 One escape slash; followed by, + * 2.2.1. One non-newline. + * @see https://drafts.csswg.org/css-syntax/#consume-numeric-token + */ + const unitRegex = /^(-?(?:[-A-Z_a-z]|[^\x00-\x7F]|\\[^\n\f\r])(?:[-\w]|[^\x00-\x7F]|\\[^\n\f\r])*|%)$/; + /** A Numeric is: + * 1. One Number; followed by, + * 1.1 Zero or one Unit. + */ + const numericRegex = new RegExp(`^${numberRegex.source.slice(1, -1) + unitRegex.source.slice(1, -1)}?$`); + var Numeric$1 = class Numeric$1 extends Node$11 { + constructor(options = {}) { + super(options); + this.type = "numeric"; + this.unit = options.unit || ""; + } + static fromTokens(tokens$3, parser$4) { + parser$4.fromFirst(tokens$3, Numeric$1); + const [[, rawValue]] = tokens$3; + const [, value, unit = ""] = rawValue.match(numericRegex); + const { lastNode } = parser$4; + lastNode.unit = unit; + lastNode.value = value; + } + static test(what) { + return numericRegex.test(what); + } + }; + registerWalker$4(Numeric$1); + module.exports = Numeric$1; +} }); + +//#endregion +//#region node_modules/postcss-values-parser/lib/nodes/Operator.js +var require_Operator = __commonJS({ "node_modules/postcss-values-parser/lib/nodes/Operator.js"(exports, module) { + const { registerWalker: registerWalker$3 } = require_walker(); + const Node$10 = require_Node(); + const operators = [ + "+", + "-", + "/", + "*", + "%" + ]; + const operRegex = new RegExp(`([/|*}])`); + var Operator$1 = class Operator$1 extends Node$10 { + constructor(options) { + super(options); + this.type = "operator"; + } + static get chars() { + return operators; + } + static fromTokens(tokens$3, parser$4) { + parser$4.fromFirst(tokens$3, Operator$1); + } + static get regex() { + return operRegex; + } + static tokenize(tokens$3, parser$4) { + const [first$1, ...rest$1] = tokens$3; + const [, value, startLine, , endLine, endChar] = first$1; + const parts = value.split(operRegex).filter((t$7) => !!t$7); + let [, , , startChar] = first$1; + const newTokens = parts.map((part) => { + const newToken = [ + "word", + part, + startLine, + startChar, + endLine, + endChar + ]; + startChar += part.length; + return newToken; + }); + parser$4.back(newTokens.concat(rest$1)); + } + }; + registerWalker$3(Operator$1); + module.exports = Operator$1; +} }); + +//#endregion +//#region node_modules/quote-unquote/index.js +var require_quote_unquote = __commonJS({ "node_modules/quote-unquote/index.js"(exports) { + var single = exports.single = function(s$1) { + return "'" + s$1.replace(/\\|'/g, function(m$2) { + return "\\" + m$2; + }) + "'"; + }; + var double = exports.double = function(s$1) { + return "\"" + s$1.replace(/\\|"/g, function(m$2) { + return "\\" + m$2; + }) + "\""; + }; + exports.quote = function(s$1) { + return /'/.test(s$1) ? double(s$1) : single(s$1); + }; + exports.unquote = function(s$1) { + var quote = s$1[0]; + var single$1 = quote === "'"; + return s$1.substring(1, s$1.length - 1).replace(/\\\\/g, "\\").replace(single$1 ? /\\'/g : /\\"/g, quote); + }; +} }); + +//#endregion +//#region node_modules/postcss-values-parser/lib/nodes/Quoted.js +var require_Quoted = __commonJS({ "node_modules/postcss-values-parser/lib/nodes/Quoted.js"(exports, module) { + const { unquote: unquote$1 } = require_quote_unquote(); + const { registerWalker: registerWalker$2 } = require_walker(); + const Node$9 = require_Node(); + var Quoted$1 = class Quoted$1 extends Node$9 { + constructor(options) { + super(options); + this.type = "quoted"; + this.contents = unquote$1(options.value); + [this.quote] = options.value; + } + static fromTokens(tokens$3, parser$4) { + parser$4.fromFirst(tokens$3, Quoted$1); + } + }; + registerWalker$2(Quoted$1); + module.exports = Quoted$1; +} }); + +//#endregion +//#region node_modules/postcss-values-parser/lib/nodes/UnicodeRange.js +var require_UnicodeRange = __commonJS({ "node_modules/postcss-values-parser/lib/nodes/UnicodeRange.js"(exports, module) { + const { registerWalker: registerWalker$1 } = require_walker(); + const Node$8 = require_Node(); + var UnicodeRange$1 = class UnicodeRange$1 extends Node$8 { + constructor(options) { + super(options); + this.type = "unicodeRange"; + } + static fromTokens(tokens$3, parser$4) { + parser$4.fromFirst(tokens$3, UnicodeRange$1); + } + static test(what) { + return /U\+(\d|\w)+(-\w+)?(\?+)?/.test(what); + } + }; + registerWalker$1(UnicodeRange$1); + module.exports = UnicodeRange$1; +} }); + +//#endregion +//#region node_modules/color-name/index.js +var require_color_name = __commonJS({ "node_modules/color-name/index.js"(exports, module) { + module.exports = { + "aliceblue": [ + 240, + 248, + 255 + ], + "antiquewhite": [ + 250, + 235, + 215 + ], + "aqua": [ + 0, + 255, + 255 + ], + "aquamarine": [ + 127, + 255, + 212 + ], + "azure": [ + 240, + 255, + 255 + ], + "beige": [ + 245, + 245, + 220 + ], + "bisque": [ + 255, + 228, + 196 + ], + "black": [ + 0, + 0, + 0 + ], + "blanchedalmond": [ + 255, + 235, + 205 + ], + "blue": [ + 0, + 0, + 255 + ], + "blueviolet": [ + 138, + 43, + 226 + ], + "brown": [ + 165, + 42, + 42 + ], + "burlywood": [ + 222, + 184, + 135 + ], + "cadetblue": [ + 95, + 158, + 160 + ], + "chartreuse": [ + 127, + 255, + 0 + ], + "chocolate": [ + 210, + 105, + 30 + ], + "coral": [ + 255, + 127, + 80 + ], + "cornflowerblue": [ + 100, + 149, + 237 + ], + "cornsilk": [ + 255, + 248, + 220 + ], + "crimson": [ + 220, + 20, + 60 + ], + "cyan": [ + 0, + 255, + 255 + ], + "darkblue": [ + 0, + 0, + 139 + ], + "darkcyan": [ + 0, + 139, + 139 + ], + "darkgoldenrod": [ + 184, + 134, + 11 + ], + "darkgray": [ + 169, + 169, + 169 + ], + "darkgreen": [ + 0, + 100, + 0 + ], + "darkgrey": [ + 169, + 169, + 169 + ], + "darkkhaki": [ + 189, + 183, + 107 + ], + "darkmagenta": [ + 139, + 0, + 139 + ], + "darkolivegreen": [ + 85, + 107, + 47 + ], + "darkorange": [ + 255, + 140, + 0 + ], + "darkorchid": [ + 153, + 50, + 204 + ], + "darkred": [ + 139, + 0, + 0 + ], + "darksalmon": [ + 233, + 150, + 122 + ], + "darkseagreen": [ + 143, + 188, + 143 + ], + "darkslateblue": [ + 72, + 61, + 139 + ], + "darkslategray": [ + 47, + 79, + 79 + ], + "darkslategrey": [ + 47, + 79, + 79 + ], + "darkturquoise": [ + 0, + 206, + 209 + ], + "darkviolet": [ + 148, + 0, + 211 + ], + "deeppink": [ + 255, + 20, + 147 + ], + "deepskyblue": [ + 0, + 191, + 255 + ], + "dimgray": [ + 105, + 105, + 105 + ], + "dimgrey": [ + 105, + 105, + 105 + ], + "dodgerblue": [ + 30, + 144, + 255 + ], + "firebrick": [ + 178, + 34, + 34 + ], + "floralwhite": [ + 255, + 250, + 240 + ], + "forestgreen": [ + 34, + 139, + 34 + ], + "fuchsia": [ + 255, + 0, + 255 + ], + "gainsboro": [ + 220, + 220, + 220 + ], + "ghostwhite": [ + 248, + 248, + 255 + ], + "gold": [ + 255, + 215, + 0 + ], + "goldenrod": [ + 218, + 165, + 32 + ], + "gray": [ + 128, + 128, + 128 + ], + "green": [ + 0, + 128, + 0 + ], + "greenyellow": [ + 173, + 255, + 47 + ], + "grey": [ + 128, + 128, + 128 + ], + "honeydew": [ + 240, + 255, + 240 + ], + "hotpink": [ + 255, + 105, + 180 + ], + "indianred": [ + 205, + 92, + 92 + ], + "indigo": [ + 75, + 0, + 130 + ], + "ivory": [ + 255, + 255, + 240 + ], + "khaki": [ + 240, + 230, + 140 + ], + "lavender": [ + 230, + 230, + 250 + ], + "lavenderblush": [ + 255, + 240, + 245 + ], + "lawngreen": [ + 124, + 252, + 0 + ], + "lemonchiffon": [ + 255, + 250, + 205 + ], + "lightblue": [ + 173, + 216, + 230 + ], + "lightcoral": [ + 240, + 128, + 128 + ], + "lightcyan": [ + 224, + 255, + 255 + ], + "lightgoldenrodyellow": [ + 250, + 250, + 210 + ], + "lightgray": [ + 211, + 211, + 211 + ], + "lightgreen": [ + 144, + 238, + 144 + ], + "lightgrey": [ + 211, + 211, + 211 + ], + "lightpink": [ + 255, + 182, + 193 + ], + "lightsalmon": [ + 255, + 160, + 122 + ], + "lightseagreen": [ + 32, + 178, + 170 + ], + "lightskyblue": [ + 135, + 206, + 250 + ], + "lightslategray": [ + 119, + 136, + 153 + ], + "lightslategrey": [ + 119, + 136, + 153 + ], + "lightsteelblue": [ + 176, + 196, + 222 + ], + "lightyellow": [ + 255, + 255, + 224 + ], + "lime": [ + 0, + 255, + 0 + ], + "limegreen": [ + 50, + 205, + 50 + ], + "linen": [ + 250, + 240, + 230 + ], + "magenta": [ + 255, + 0, + 255 + ], + "maroon": [ + 128, + 0, + 0 + ], + "mediumaquamarine": [ + 102, + 205, + 170 + ], + "mediumblue": [ + 0, + 0, + 205 + ], + "mediumorchid": [ + 186, + 85, + 211 + ], + "mediumpurple": [ + 147, + 112, + 219 + ], + "mediumseagreen": [ + 60, + 179, + 113 + ], + "mediumslateblue": [ + 123, + 104, + 238 + ], + "mediumspringgreen": [ + 0, + 250, + 154 + ], + "mediumturquoise": [ + 72, + 209, + 204 + ], + "mediumvioletred": [ + 199, + 21, + 133 + ], + "midnightblue": [ + 25, + 25, + 112 + ], + "mintcream": [ + 245, + 255, + 250 + ], + "mistyrose": [ + 255, + 228, + 225 + ], + "moccasin": [ + 255, + 228, + 181 + ], + "navajowhite": [ + 255, + 222, + 173 + ], + "navy": [ + 0, + 0, + 128 + ], + "oldlace": [ + 253, + 245, + 230 + ], + "olive": [ + 128, + 128, + 0 + ], + "olivedrab": [ + 107, + 142, + 35 + ], + "orange": [ + 255, + 165, + 0 + ], + "orangered": [ + 255, + 69, + 0 + ], + "orchid": [ + 218, + 112, + 214 + ], + "palegoldenrod": [ + 238, + 232, + 170 + ], + "palegreen": [ + 152, + 251, + 152 + ], + "paleturquoise": [ + 175, + 238, + 238 + ], + "palevioletred": [ + 219, + 112, + 147 + ], + "papayawhip": [ + 255, + 239, + 213 + ], + "peachpuff": [ + 255, + 218, + 185 + ], + "peru": [ + 205, + 133, + 63 + ], + "pink": [ + 255, + 192, + 203 + ], + "plum": [ + 221, + 160, + 221 + ], + "powderblue": [ + 176, + 224, + 230 + ], + "purple": [ + 128, + 0, + 128 + ], + "rebeccapurple": [ + 102, + 51, + 153 + ], + "red": [ + 255, + 0, + 0 + ], + "rosybrown": [ + 188, + 143, + 143 + ], + "royalblue": [ + 65, + 105, + 225 + ], + "saddlebrown": [ + 139, + 69, + 19 + ], + "salmon": [ + 250, + 128, + 114 + ], + "sandybrown": [ + 244, + 164, + 96 + ], + "seagreen": [ + 46, + 139, + 87 + ], + "seashell": [ + 255, + 245, + 238 + ], + "sienna": [ + 160, + 82, + 45 + ], + "silver": [ + 192, + 192, + 192 + ], + "skyblue": [ + 135, + 206, + 235 + ], + "slateblue": [ + 106, + 90, + 205 + ], + "slategray": [ + 112, + 128, + 144 + ], + "slategrey": [ + 112, + 128, + 144 + ], + "snow": [ + 255, + 250, + 250 + ], + "springgreen": [ + 0, + 255, + 127 + ], + "steelblue": [ + 70, + 130, + 180 + ], + "tan": [ + 210, + 180, + 140 + ], + "teal": [ + 0, + 128, + 128 + ], + "thistle": [ + 216, + 191, + 216 + ], + "tomato": [ + 255, + 99, + 71 + ], + "turquoise": [ + 64, + 224, + 208 + ], + "violet": [ + 238, + 130, + 238 + ], + "wheat": [ + 245, + 222, + 179 + ], + "white": [ + 255, + 255, + 255 + ], + "whitesmoke": [ + 245, + 245, + 245 + ], + "yellow": [ + 255, + 255, + 0 + ], + "yellowgreen": [ + 154, + 205, + 50 + ] + }; +} }); + +//#endregion +//#region node_modules/is-url-superb/index.js +var require_is_url_superb = __commonJS({ "node_modules/is-url-superb/index.js"(exports, module) { + module.exports = (string$3) => { + if (typeof string$3 !== "string") throw new TypeError("Expected a string"); + try { + new URL(string$3); + return true; + } catch { + return false; + } + }; +} }); + +//#endregion +//#region node_modules/postcss-values-parser/lib/nodes/Word.js +var require_Word = __commonJS({ "node_modules/postcss-values-parser/lib/nodes/Word.js"(exports, module) { + const colors$1 = require_color_name(); + const isUrl = require_is_url_superb(); + const { registerWalker } = require_walker(); + const Node$7 = require_Node(); + const escapeRegex = /^\\(.+)/; + const hexRegex = /^#(.+)/; + const colorRegex = /^#([0-9a-f]{3}|[0-9a-f]{4}|[0-9a-f]{6}|[0-9a-f]{8})$/i; + const colorNames$1 = Object.keys(colors$1); + var Word$1 = class Word$1 extends Node$7 { + constructor(options) { + super(options); + this.type = "word"; + this.isColor = false; + this.isHex = false; + this.isUrl = false; + this.isVariable = false; + } + static fromTokens(tokens$3, parser$4) { + parser$4.fromFirst(tokens$3, Word$1); + const { lastNode } = parser$4; + const { value } = lastNode; + lastNode.isColor = colorRegex.test(value) || colorNames$1.includes(value.toLowerCase()); + lastNode.isHex = hexRegex.test(value); + lastNode.isUrl = value.startsWith("//") ? isUrl(`http:${value}`) : isUrl(value); + lastNode.isVariable = Word$1.testVariable(tokens$3[0], parser$4); + } + static testEscaped(tokens$3) { + const [first$1, next] = tokens$3; + const [type, value] = first$1; + return type === "word" && (escapeRegex.test(value) || value === "\\" && next && !/^\s+$/.test(next[1])); + } + static testHex(token$1) { + const [type, value] = token$1; + return type === "word" && hexRegex.test(value); + } + static testVariable(token$1, parser$4) { + const [type, value] = token$1; + const { prefixes } = parser$4.options.variables; + const varRegex = new RegExp(`^(${prefixes.join("|")})`); + return type === "word" && varRegex.test(value); + } + static testWord(tokens$3, parser$4) { + const [token$1] = tokens$3; + return Word$1.testEscaped(tokens$3) || Word$1.testHex(token$1) || Word$1.testVariable(token$1, parser$4); + } + }; + registerWalker(Word$1); + module.exports = Word$1; +} }); + +//#endregion +//#region node_modules/postcss-values-parser/lib/ValuesParser.js +var require_ValuesParser = __commonJS({ "node_modules/postcss-values-parser/lib/ValuesParser.js"(exports, module) { + const Parser$7 = require_parser$5(); + const AtWord = require_AtWord(); + const Comment$5 = require_Comment(); + const Func$1 = require_Func(); + const Interpolation = require_Interpolation(); + const Numeric = require_Numeric(); + const Operator = require_Operator(); + const Punctuation = require_Punctuation(); + const Quoted = require_Quoted(); + const UnicodeRange = require_UnicodeRange(); + const Word = require_Word(); + const defaults = { + ignoreUnknownWords: false, + interpolation: false, + parentNode: null, + variables: { prefixes: ["--"] } + }; + module.exports = class ValuesParser extends Parser$7 { + constructor(input, opts = {}) { + super(input); + this.lastNode = null; + this.options = Object.assign({}, defaults, opts); + this.parentNode = this.options.parentNode; + } + back(tokens$3) { + for (const token$1 of tokens$3.reverse()) this.tokenizer.back(token$1); + } + comment(token$1) { + super.comment(token$1); + const inline = Comment$5.testInline(token$1); + const node = this.lastNode; + node.inline = inline; + Object.setPrototypeOf(node, Comment$5.prototype); + } + fromFirst(tokens$3, Constructor) { + const [first$1] = tokens$3; + const [, value, startLine, startChar] = first$1; + const node = new Constructor({ value }); + this.init(node, startLine, startChar); + this.current = node; + this.end(first$1); + this.back(tokens$3.slice(1)); + } + init(node, line, column) { + super.init(node, line, column); + this.lastNode = node; + } + other(start) { + const brackets$1 = []; + const tokens$3 = []; + let token$1 = start; + let type = null; + let bracket = null; + while (token$1) { + [type] = token$1; + tokens$3.push(token$1); + if (type === "(" || type === "[") { + if (!bracket) bracket = token$1; + brackets$1.push(type === "(" ? ")" : "]"); + } else if (type === brackets$1[brackets$1.length - 1]) { + brackets$1.pop(); + if (brackets$1.length === 0) bracket = null; + } + token$1 = this.tokenizer.nextToken(); + } + if (brackets$1.length > 0) this.unclosedBracket(bracket); + this.unknownWord(tokens$3); + } + parse() { + let token$1; + while (!this.tokenizer.endOfFile()) { + token$1 = this.tokenizer.nextToken(); + switch (token$1[0]) { + case "space": + this.spaces += token$1[1]; + break; + case "comment": + this.comment(token$1); + break; + case "at-word": + this.atrule(token$1); + Object.setPrototypeOf(this.lastNode, AtWord.prototype); + this.lastNode.type = "atword"; + break; + default: + this.other(token$1); + break; + } + } + this.endFile(); + } + unknownWord(tokens$3) { + const [first$1] = tokens$3; + const [type, value] = first$1; + if (Punctuation.chars.includes(type)) Punctuation.fromTokens(tokens$3, this); + else if (Func$1.test(tokens$3)) Func$1.fromTokens(tokens$3, this); + else if (this.options.interpolation && Interpolation.test(tokens$3, this)) Interpolation.fromTokens(tokens$3, this); + else if (type === "brackets") Punctuation.tokenizeBrackets(tokens$3, this); + else if (type === "comma") Punctuation.fromTokens(tokens$3, this); + else if (type === "operator") Operator.fromTokens(tokens$3, this); + else if (type === "string") Quoted.fromTokens(tokens$3, this); + else if (type === "word") if (value === ",") Punctuation.fromTokens(tokens$3, this); + else if (value === "//") Comment$5.tokenizeNext(tokens$3, this); + else if (Comment$5.testInline(first$1)) { + const { parentNode } = this; + if (parentNode && parentNode.type === "func" && parentNode.name === "url") Word.fromTokens(tokens$3, this); + else Comment$5.tokenizeInline(tokens$3, this); + } else if (value.includes(",")) Punctuation.tokenizeCommas(tokens$3, this); + else if (Word.testWord(tokens$3, this)) Word.fromTokens(tokens$3, this); + else if (Numeric.test(value)) Numeric.fromTokens(tokens$3, this); + else if (UnicodeRange.test(value)) UnicodeRange.fromTokens(tokens$3, this); + else if (Operator.chars.includes(value)) Operator.fromTokens(tokens$3, this); + else if (/^[\w-]+$/.test(value)) Word.fromTokens(tokens$3, this); + else if (Operator.regex.test(value)) Operator.tokenize(tokens$3, this); + else if (this.options.ignoreUnknownWords) Word.fromTokens(tokens$3, this); + else super.unknownWord(tokens$3); + else + /* istanbul ignore next */ + super.unknownWord(tokens$3); + } + }; +} }); + +//#endregion +//#region node_modules/postcss-values-parser/lib/index.js +var require_lib$17 = __commonJS({ "node_modules/postcss-values-parser/lib/index.js"(exports, module) { + const Input = require_input(); + const Parser$6 = require_ValuesParser(); + const { stringify: stringify$2 } = require_ValuesStringifier(); + module.exports = { + parse(css, options) { + const input = new Input(css, options); + const parser$4 = new Parser$6(input, options); + parser$4.parse(); + const { root: root$6 } = parser$4; + const ogToString = root$6.toString; + function toString$6(stringifier) { + return ogToString.bind(root$6)(stringifier || module.exports.stringify); + } + root$6.toString = toString$6.bind(root$6); + return parser$4.root; + }, + stringify: stringify$2, + nodeToString(node) { + let result$1 = ""; + module.exports.stringify(node, (bit) => { + result$1 += bit; + }); + return result$1; + } + }; +} }); + +//#endregion +//#region node_modules/color-convert/conversions.js +var require_conversions = __commonJS({ "node_modules/color-convert/conversions.js"(exports, module) { + const cssKeywords = require_color_name(); + const reverseKeywords = {}; + for (const key of Object.keys(cssKeywords)) reverseKeywords[cssKeywords[key]] = key; + const convert$2 = { + rgb: { + channels: 3, + labels: "rgb" + }, + hsl: { + channels: 3, + labels: "hsl" + }, + hsv: { + channels: 3, + labels: "hsv" + }, + hwb: { + channels: 3, + labels: "hwb" + }, + cmyk: { + channels: 4, + labels: "cmyk" + }, + xyz: { + channels: 3, + labels: "xyz" + }, + lab: { + channels: 3, + labels: "lab" + }, + lch: { + channels: 3, + labels: "lch" + }, + hex: { + channels: 1, + labels: ["hex"] + }, + keyword: { + channels: 1, + labels: ["keyword"] + }, + ansi16: { + channels: 1, + labels: ["ansi16"] + }, + ansi256: { + channels: 1, + labels: ["ansi256"] + }, + hcg: { + channels: 3, + labels: [ + "h", + "c", + "g" + ] + }, + apple: { + channels: 3, + labels: [ + "r16", + "g16", + "b16" + ] + }, + gray: { + channels: 1, + labels: ["gray"] + } + }; + module.exports = convert$2; + for (const model of Object.keys(convert$2)) { + if (!("channels" in convert$2[model])) throw new Error("missing channels property: " + model); + if (!("labels" in convert$2[model])) throw new Error("missing channel labels property: " + model); + if (convert$2[model].labels.length !== convert$2[model].channels) throw new Error("channel and label counts mismatch: " + model); + const { channels, labels } = convert$2[model]; + delete convert$2[model].channels; + delete convert$2[model].labels; + Object.defineProperty(convert$2[model], "channels", { value: channels }); + Object.defineProperty(convert$2[model], "labels", { value: labels }); + } + convert$2.rgb.hsl = function(rgb) { + const r = rgb[0] / 255; + const g$1 = rgb[1] / 255; + const b$1 = rgb[2] / 255; + const min$1 = Math.min(r, g$1, b$1); + const max$2 = Math.max(r, g$1, b$1); + const delta = max$2 - min$1; + let h$2; + let s$1; + if (max$2 === min$1) h$2 = 0; + else if (r === max$2) h$2 = (g$1 - b$1) / delta; + else if (g$1 === max$2) h$2 = 2 + (b$1 - r) / delta; + else if (b$1 === max$2) h$2 = 4 + (r - g$1) / delta; + h$2 = Math.min(h$2 * 60, 360); + if (h$2 < 0) h$2 += 360; + const l$1 = (min$1 + max$2) / 2; + if (max$2 === min$1) s$1 = 0; + else if (l$1 <= .5) s$1 = delta / (max$2 + min$1); + else s$1 = delta / (2 - max$2 - min$1); + return [ + h$2, + s$1 * 100, + l$1 * 100 + ]; + }; + convert$2.rgb.hsv = function(rgb) { + let rdif; + let gdif; + let bdif; + let h$2; + let s$1; + const r = rgb[0] / 255; + const g$1 = rgb[1] / 255; + const b$1 = rgb[2] / 255; + const v$1 = Math.max(r, g$1, b$1); + const diff = v$1 - Math.min(r, g$1, b$1); + const diffc = function(c$2) { + return (v$1 - c$2) / 6 / diff + 1 / 2; + }; + if (diff === 0) { + h$2 = 0; + s$1 = 0; + } else { + s$1 = diff / v$1; + rdif = diffc(r); + gdif = diffc(g$1); + bdif = diffc(b$1); + if (r === v$1) h$2 = bdif - gdif; + else if (g$1 === v$1) h$2 = 1 / 3 + rdif - bdif; + else if (b$1 === v$1) h$2 = 2 / 3 + gdif - rdif; + if (h$2 < 0) h$2 += 1; + else if (h$2 > 1) h$2 -= 1; + } + return [ + h$2 * 360, + s$1 * 100, + v$1 * 100 + ]; + }; + convert$2.rgb.hwb = function(rgb) { + const r = rgb[0]; + const g$1 = rgb[1]; + let b$1 = rgb[2]; + const h$2 = convert$2.rgb.hsl(rgb)[0]; + const w$2 = 1 / 255 * Math.min(r, Math.min(g$1, b$1)); + b$1 = 1 - 1 / 255 * Math.max(r, Math.max(g$1, b$1)); + return [ + h$2, + w$2 * 100, + b$1 * 100 + ]; + }; + convert$2.rgb.cmyk = function(rgb) { + const r = rgb[0] / 255; + const g$1 = rgb[1] / 255; + const b$1 = rgb[2] / 255; + const k$1 = Math.min(1 - r, 1 - g$1, 1 - b$1); + const c$2 = (1 - r - k$1) / (1 - k$1) || 0; + const m$2 = (1 - g$1 - k$1) / (1 - k$1) || 0; + const y$2 = (1 - b$1 - k$1) / (1 - k$1) || 0; + return [ + c$2 * 100, + m$2 * 100, + y$2 * 100, + k$1 * 100 + ]; + }; + function comparativeDistance(x$2, y$2) { + return (x$2[0] - y$2[0]) ** 2 + (x$2[1] - y$2[1]) ** 2 + (x$2[2] - y$2[2]) ** 2; + } + convert$2.rgb.keyword = function(rgb) { + const reversed = reverseKeywords[rgb]; + if (reversed) return reversed; + let currentClosestDistance = Infinity; + let currentClosestKeyword; + for (const keyword of Object.keys(cssKeywords)) { + const value = cssKeywords[keyword]; + const distance = comparativeDistance(rgb, value); + if (distance < currentClosestDistance) { + currentClosestDistance = distance; + currentClosestKeyword = keyword; + } + } + return currentClosestKeyword; + }; + convert$2.keyword.rgb = function(keyword) { + return cssKeywords[keyword]; + }; + convert$2.rgb.xyz = function(rgb) { + let r = rgb[0] / 255; + let g$1 = rgb[1] / 255; + let b$1 = rgb[2] / 255; + r = r > .04045 ? ((r + .055) / 1.055) ** 2.4 : r / 12.92; + g$1 = g$1 > .04045 ? ((g$1 + .055) / 1.055) ** 2.4 : g$1 / 12.92; + b$1 = b$1 > .04045 ? ((b$1 + .055) / 1.055) ** 2.4 : b$1 / 12.92; + const x$2 = r * .4124 + g$1 * .3576 + b$1 * .1805; + const y$2 = r * .2126 + g$1 * .7152 + b$1 * .0722; + const z = r * .0193 + g$1 * .1192 + b$1 * .9505; + return [ + x$2 * 100, + y$2 * 100, + z * 100 + ]; + }; + convert$2.rgb.lab = function(rgb) { + const xyz = convert$2.rgb.xyz(rgb); + let x$2 = xyz[0]; + let y$2 = xyz[1]; + let z = xyz[2]; + x$2 /= 95.047; + y$2 /= 100; + z /= 108.883; + x$2 = x$2 > .008856 ? x$2 ** (1 / 3) : 7.787 * x$2 + 16 / 116; + y$2 = y$2 > .008856 ? y$2 ** (1 / 3) : 7.787 * y$2 + 16 / 116; + z = z > .008856 ? z ** (1 / 3) : 7.787 * z + 16 / 116; + const l$1 = 116 * y$2 - 16; + const a = 500 * (x$2 - y$2); + const b$1 = 200 * (y$2 - z); + return [ + l$1, + a, + b$1 + ]; + }; + convert$2.hsl.rgb = function(hsl) { + const h$2 = hsl[0] / 360; + const s$1 = hsl[1] / 100; + const l$1 = hsl[2] / 100; + let t2; + let t3; + let val; + if (s$1 === 0) { + val = l$1 * 255; + return [ + val, + val, + val + ]; + } + if (l$1 < .5) t2 = l$1 * (1 + s$1); + else t2 = l$1 + s$1 - l$1 * s$1; + const t1 = 2 * l$1 - t2; + const rgb = [ + 0, + 0, + 0 + ]; + for (let i$5 = 0; i$5 < 3; i$5++) { + t3 = h$2 + 1 / 3 * -(i$5 - 1); + if (t3 < 0) t3++; + if (t3 > 1) t3--; + if (6 * t3 < 1) val = t1 + (t2 - t1) * 6 * t3; + else if (2 * t3 < 1) val = t2; + else if (3 * t3 < 2) val = t1 + (t2 - t1) * (2 / 3 - t3) * 6; + else val = t1; + rgb[i$5] = val * 255; + } + return rgb; + }; + convert$2.hsl.hsv = function(hsl) { + const h$2 = hsl[0]; + let s$1 = hsl[1] / 100; + let l$1 = hsl[2] / 100; + let smin = s$1; + const lmin = Math.max(l$1, .01); + l$1 *= 2; + s$1 *= l$1 <= 1 ? l$1 : 2 - l$1; + smin *= lmin <= 1 ? lmin : 2 - lmin; + const v$1 = (l$1 + s$1) / 2; + const sv = l$1 === 0 ? 2 * smin / (lmin + smin) : 2 * s$1 / (l$1 + s$1); + return [ + h$2, + sv * 100, + v$1 * 100 + ]; + }; + convert$2.hsv.rgb = function(hsv) { + const h$2 = hsv[0] / 60; + const s$1 = hsv[1] / 100; + let v$1 = hsv[2] / 100; + const hi = Math.floor(h$2) % 6; + const f$1 = h$2 - Math.floor(h$2); + const p$1 = 255 * v$1 * (1 - s$1); + const q = 255 * v$1 * (1 - s$1 * f$1); + const t$7 = 255 * v$1 * (1 - s$1 * (1 - f$1)); + v$1 *= 255; + switch (hi) { + case 0: return [ + v$1, + t$7, + p$1 + ]; + case 1: return [ + q, + v$1, + p$1 + ]; + case 2: return [ + p$1, + v$1, + t$7 + ]; + case 3: return [ + p$1, + q, + v$1 + ]; + case 4: return [ + t$7, + p$1, + v$1 + ]; + case 5: return [ + v$1, + p$1, + q + ]; + } + }; + convert$2.hsv.hsl = function(hsv) { + const h$2 = hsv[0]; + const s$1 = hsv[1] / 100; + const v$1 = hsv[2] / 100; + const vmin = Math.max(v$1, .01); + let sl; + let l$1; + l$1 = (2 - s$1) * v$1; + const lmin = (2 - s$1) * vmin; + sl = s$1 * vmin; + sl /= lmin <= 1 ? lmin : 2 - lmin; + sl = sl || 0; + l$1 /= 2; + return [ + h$2, + sl * 100, + l$1 * 100 + ]; + }; + convert$2.hwb.rgb = function(hwb) { + const h$2 = hwb[0] / 360; + let wh = hwb[1] / 100; + let bl = hwb[2] / 100; + const ratio = wh + bl; + let f$1; + if (ratio > 1) { + wh /= ratio; + bl /= ratio; + } + const i$5 = Math.floor(6 * h$2); + const v$1 = 1 - bl; + f$1 = 6 * h$2 - i$5; + if ((i$5 & 1) !== 0) f$1 = 1 - f$1; + const n$3 = wh + f$1 * (v$1 - wh); + let r; + let g$1; + let b$1; + switch (i$5) { + default: + case 6: + case 0: + r = v$1; + g$1 = n$3; + b$1 = wh; + break; + case 1: + r = n$3; + g$1 = v$1; + b$1 = wh; + break; + case 2: + r = wh; + g$1 = v$1; + b$1 = n$3; + break; + case 3: + r = wh; + g$1 = n$3; + b$1 = v$1; + break; + case 4: + r = n$3; + g$1 = wh; + b$1 = v$1; + break; + case 5: + r = v$1; + g$1 = wh; + b$1 = n$3; + break; + } + return [ + r * 255, + g$1 * 255, + b$1 * 255 + ]; + }; + convert$2.cmyk.rgb = function(cmyk) { + const c$2 = cmyk[0] / 100; + const m$2 = cmyk[1] / 100; + const y$2 = cmyk[2] / 100; + const k$1 = cmyk[3] / 100; + const r = 1 - Math.min(1, c$2 * (1 - k$1) + k$1); + const g$1 = 1 - Math.min(1, m$2 * (1 - k$1) + k$1); + const b$1 = 1 - Math.min(1, y$2 * (1 - k$1) + k$1); + return [ + r * 255, + g$1 * 255, + b$1 * 255 + ]; + }; + convert$2.xyz.rgb = function(xyz) { + const x$2 = xyz[0] / 100; + const y$2 = xyz[1] / 100; + const z = xyz[2] / 100; + let r; + let g$1; + let b$1; + r = x$2 * 3.2406 + y$2 * -1.5372 + z * -.4986; + g$1 = x$2 * -.9689 + y$2 * 1.8758 + z * .0415; + b$1 = x$2 * .0557 + y$2 * -.204 + z * 1.057; + r = r > .0031308 ? 1.055 * r ** (1 / 2.4) - .055 : r * 12.92; + g$1 = g$1 > .0031308 ? 1.055 * g$1 ** (1 / 2.4) - .055 : g$1 * 12.92; + b$1 = b$1 > .0031308 ? 1.055 * b$1 ** (1 / 2.4) - .055 : b$1 * 12.92; + r = Math.min(Math.max(0, r), 1); + g$1 = Math.min(Math.max(0, g$1), 1); + b$1 = Math.min(Math.max(0, b$1), 1); + return [ + r * 255, + g$1 * 255, + b$1 * 255 + ]; + }; + convert$2.xyz.lab = function(xyz) { + let x$2 = xyz[0]; + let y$2 = xyz[1]; + let z = xyz[2]; + x$2 /= 95.047; + y$2 /= 100; + z /= 108.883; + x$2 = x$2 > .008856 ? x$2 ** (1 / 3) : 7.787 * x$2 + 16 / 116; + y$2 = y$2 > .008856 ? y$2 ** (1 / 3) : 7.787 * y$2 + 16 / 116; + z = z > .008856 ? z ** (1 / 3) : 7.787 * z + 16 / 116; + const l$1 = 116 * y$2 - 16; + const a = 500 * (x$2 - y$2); + const b$1 = 200 * (y$2 - z); + return [ + l$1, + a, + b$1 + ]; + }; + convert$2.lab.xyz = function(lab) { + const l$1 = lab[0]; + const a = lab[1]; + const b$1 = lab[2]; + let x$2; + let y$2; + let z; + y$2 = (l$1 + 16) / 116; + x$2 = a / 500 + y$2; + z = y$2 - b$1 / 200; + const y2 = y$2 ** 3; + const x2 = x$2 ** 3; + const z2 = z ** 3; + y$2 = y2 > .008856 ? y2 : (y$2 - 16 / 116) / 7.787; + x$2 = x2 > .008856 ? x2 : (x$2 - 16 / 116) / 7.787; + z = z2 > .008856 ? z2 : (z - 16 / 116) / 7.787; + x$2 *= 95.047; + y$2 *= 100; + z *= 108.883; + return [ + x$2, + y$2, + z + ]; + }; + convert$2.lab.lch = function(lab) { + const l$1 = lab[0]; + const a = lab[1]; + const b$1 = lab[2]; + let h$2; + const hr = Math.atan2(b$1, a); + h$2 = hr * 360 / 2 / Math.PI; + if (h$2 < 0) h$2 += 360; + const c$2 = Math.sqrt(a * a + b$1 * b$1); + return [ + l$1, + c$2, + h$2 + ]; + }; + convert$2.lch.lab = function(lch) { + const l$1 = lch[0]; + const c$2 = lch[1]; + const h$2 = lch[2]; + const hr = h$2 / 360 * 2 * Math.PI; + const a = c$2 * Math.cos(hr); + const b$1 = c$2 * Math.sin(hr); + return [ + l$1, + a, + b$1 + ]; + }; + convert$2.rgb.ansi16 = function(args, saturation = null) { + const [r, g$1, b$1] = args; + let value = saturation === null ? convert$2.rgb.hsv(args)[2] : saturation; + value = Math.round(value / 50); + if (value === 0) return 30; + let ansi = 30 + (Math.round(b$1 / 255) << 2 | Math.round(g$1 / 255) << 1 | Math.round(r / 255)); + if (value === 2) ansi += 60; + return ansi; + }; + convert$2.hsv.ansi16 = function(args) { + return convert$2.rgb.ansi16(convert$2.hsv.rgb(args), args[2]); + }; + convert$2.rgb.ansi256 = function(args) { + const r = args[0]; + const g$1 = args[1]; + const b$1 = args[2]; + if (r === g$1 && g$1 === b$1) { + if (r < 8) return 16; + if (r > 248) return 231; + return Math.round((r - 8) / 247 * 24) + 232; + } + const ansi = 16 + 36 * Math.round(r / 255 * 5) + 6 * Math.round(g$1 / 255 * 5) + Math.round(b$1 / 255 * 5); + return ansi; + }; + convert$2.ansi16.rgb = function(args) { + let color = args % 10; + if (color === 0 || color === 7) { + if (args > 50) color += 3.5; + color = color / 10.5 * 255; + return [ + color, + color, + color + ]; + } + const mult = (~~(args > 50) + 1) * .5; + const r = (color & 1) * mult * 255; + const g$1 = (color >> 1 & 1) * mult * 255; + const b$1 = (color >> 2 & 1) * mult * 255; + return [ + r, + g$1, + b$1 + ]; + }; + convert$2.ansi256.rgb = function(args) { + if (args >= 232) { + const c$2 = (args - 232) * 10 + 8; + return [ + c$2, + c$2, + c$2 + ]; + } + args -= 16; + let rem; + const r = Math.floor(args / 36) / 5 * 255; + const g$1 = Math.floor((rem = args % 36) / 6) / 5 * 255; + const b$1 = rem % 6 / 5 * 255; + return [ + r, + g$1, + b$1 + ]; + }; + convert$2.rgb.hex = function(args) { + const integer = ((Math.round(args[0]) & 255) << 16) + ((Math.round(args[1]) & 255) << 8) + (Math.round(args[2]) & 255); + const string$3 = integer.toString(16).toUpperCase(); + return "000000".substring(string$3.length) + string$3; + }; + convert$2.hex.rgb = function(args) { + const match = args.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i); + if (!match) return [ + 0, + 0, + 0 + ]; + let colorString = match[0]; + if (match[0].length === 3) colorString = colorString.split("").map((char) => { + return char + char; + }).join(""); + const integer = parseInt(colorString, 16); + const r = integer >> 16 & 255; + const g$1 = integer >> 8 & 255; + const b$1 = integer & 255; + return [ + r, + g$1, + b$1 + ]; + }; + convert$2.rgb.hcg = function(rgb) { + const r = rgb[0] / 255; + const g$1 = rgb[1] / 255; + const b$1 = rgb[2] / 255; + const max$2 = Math.max(Math.max(r, g$1), b$1); + const min$1 = Math.min(Math.min(r, g$1), b$1); + const chroma = max$2 - min$1; + let grayscale; + let hue; + if (chroma < 1) grayscale = min$1 / (1 - chroma); + else grayscale = 0; + if (chroma <= 0) hue = 0; + else if (max$2 === r) hue = (g$1 - b$1) / chroma % 6; + else if (max$2 === g$1) hue = 2 + (b$1 - r) / chroma; + else hue = 4 + (r - g$1) / chroma; + hue /= 6; + hue %= 1; + return [ + hue * 360, + chroma * 100, + grayscale * 100 + ]; + }; + convert$2.hsl.hcg = function(hsl) { + const s$1 = hsl[1] / 100; + const l$1 = hsl[2] / 100; + const c$2 = l$1 < .5 ? 2 * s$1 * l$1 : 2 * s$1 * (1 - l$1); + let f$1 = 0; + if (c$2 < 1) f$1 = (l$1 - .5 * c$2) / (1 - c$2); + return [ + hsl[0], + c$2 * 100, + f$1 * 100 + ]; + }; + convert$2.hsv.hcg = function(hsv) { + const s$1 = hsv[1] / 100; + const v$1 = hsv[2] / 100; + const c$2 = s$1 * v$1; + let f$1 = 0; + if (c$2 < 1) f$1 = (v$1 - c$2) / (1 - c$2); + return [ + hsv[0], + c$2 * 100, + f$1 * 100 + ]; + }; + convert$2.hcg.rgb = function(hcg) { + const h$2 = hcg[0] / 360; + const c$2 = hcg[1] / 100; + const g$1 = hcg[2] / 100; + if (c$2 === 0) return [ + g$1 * 255, + g$1 * 255, + g$1 * 255 + ]; + const pure = [ + 0, + 0, + 0 + ]; + const hi = h$2 % 1 * 6; + const v$1 = hi % 1; + const w$2 = 1 - v$1; + let mg = 0; + switch (Math.floor(hi)) { + case 0: + pure[0] = 1; + pure[1] = v$1; + pure[2] = 0; + break; + case 1: + pure[0] = w$2; + pure[1] = 1; + pure[2] = 0; + break; + case 2: + pure[0] = 0; + pure[1] = 1; + pure[2] = v$1; + break; + case 3: + pure[0] = 0; + pure[1] = w$2; + pure[2] = 1; + break; + case 4: + pure[0] = v$1; + pure[1] = 0; + pure[2] = 1; + break; + default: + pure[0] = 1; + pure[1] = 0; + pure[2] = w$2; + } + mg = (1 - c$2) * g$1; + return [ + (c$2 * pure[0] + mg) * 255, + (c$2 * pure[1] + mg) * 255, + (c$2 * pure[2] + mg) * 255 + ]; + }; + convert$2.hcg.hsv = function(hcg) { + const c$2 = hcg[1] / 100; + const g$1 = hcg[2] / 100; + const v$1 = c$2 + g$1 * (1 - c$2); + let f$1 = 0; + if (v$1 > 0) f$1 = c$2 / v$1; + return [ + hcg[0], + f$1 * 100, + v$1 * 100 + ]; + }; + convert$2.hcg.hsl = function(hcg) { + const c$2 = hcg[1] / 100; + const g$1 = hcg[2] / 100; + const l$1 = g$1 * (1 - c$2) + .5 * c$2; + let s$1 = 0; + if (l$1 > 0 && l$1 < .5) s$1 = c$2 / (2 * l$1); + else if (l$1 >= .5 && l$1 < 1) s$1 = c$2 / (2 * (1 - l$1)); + return [ + hcg[0], + s$1 * 100, + l$1 * 100 + ]; + }; + convert$2.hcg.hwb = function(hcg) { + const c$2 = hcg[1] / 100; + const g$1 = hcg[2] / 100; + const v$1 = c$2 + g$1 * (1 - c$2); + return [ + hcg[0], + (v$1 - c$2) * 100, + (1 - v$1) * 100 + ]; + }; + convert$2.hwb.hcg = function(hwb) { + const w$2 = hwb[1] / 100; + const b$1 = hwb[2] / 100; + const v$1 = 1 - b$1; + const c$2 = v$1 - w$2; + let g$1 = 0; + if (c$2 < 1) g$1 = (v$1 - c$2) / (1 - c$2); + return [ + hwb[0], + c$2 * 100, + g$1 * 100 + ]; + }; + convert$2.apple.rgb = function(apple) { + return [ + apple[0] / 65535 * 255, + apple[1] / 65535 * 255, + apple[2] / 65535 * 255 + ]; + }; + convert$2.rgb.apple = function(rgb) { + return [ + rgb[0] / 255 * 65535, + rgb[1] / 255 * 65535, + rgb[2] / 255 * 65535 + ]; + }; + convert$2.gray.rgb = function(args) { + return [ + args[0] / 100 * 255, + args[0] / 100 * 255, + args[0] / 100 * 255 + ]; + }; + convert$2.gray.hsl = function(args) { + return [ + 0, + 0, + args[0] + ]; + }; + convert$2.gray.hsv = convert$2.gray.hsl; + convert$2.gray.hwb = function(gray) { + return [ + 0, + 100, + gray[0] + ]; + }; + convert$2.gray.cmyk = function(gray) { + return [ + 0, + 0, + 0, + gray[0] + ]; + }; + convert$2.gray.lab = function(gray) { + return [ + gray[0], + 0, + 0 + ]; + }; + convert$2.gray.hex = function(gray) { + const val = Math.round(gray[0] / 100 * 255) & 255; + const integer = (val << 16) + (val << 8) + val; + const string$3 = integer.toString(16).toUpperCase(); + return "000000".substring(string$3.length) + string$3; + }; + convert$2.rgb.gray = function(rgb) { + const val = (rgb[0] + rgb[1] + rgb[2]) / 3; + return [val / 255 * 100]; + }; +} }); + +//#endregion +//#region node_modules/color-convert/route.js +var require_route = __commonJS({ "node_modules/color-convert/route.js"(exports, module) { + const conversions$1 = require_conversions(); + function buildGraph() { + const graph = {}; + const models$1 = Object.keys(conversions$1); + for (let len = models$1.length, i$5 = 0; i$5 < len; i$5++) graph[models$1[i$5]] = { + distance: -1, + parent: null + }; + return graph; + } + function deriveBFS(fromModel) { + const graph = buildGraph(); + const queue$1 = [fromModel]; + graph[fromModel].distance = 0; + while (queue$1.length) { + const current = queue$1.pop(); + const adjacents = Object.keys(conversions$1[current]); + for (let len = adjacents.length, i$5 = 0; i$5 < len; i$5++) { + const adjacent = adjacents[i$5]; + const node = graph[adjacent]; + if (node.distance === -1) { + node.distance = graph[current].distance + 1; + node.parent = current; + queue$1.unshift(adjacent); + } + } + } + return graph; + } + function link(from, to) { + return function(args) { + return to(from(args)); + }; + } + function wrapConversion(toModel, graph) { + const path$28 = [graph[toModel].parent, toModel]; + let fn = conversions$1[graph[toModel].parent][toModel]; + let cur = graph[toModel].parent; + while (graph[cur].parent) { + path$28.unshift(graph[cur].parent); + fn = link(conversions$1[graph[cur].parent][cur], fn); + cur = graph[cur].parent; + } + fn.conversion = path$28; + return fn; + } + module.exports = function(fromModel) { + const graph = deriveBFS(fromModel); + const conversion = {}; + const models$1 = Object.keys(graph); + for (let len = models$1.length, i$5 = 0; i$5 < len; i$5++) { + const toModel = models$1[i$5]; + const node = graph[toModel]; + if (node.parent === null) continue; + conversion[toModel] = wrapConversion(toModel, graph); + } + return conversion; + }; +} }); + +//#endregion +//#region node_modules/color-convert/index.js +var require_color_convert = __commonJS({ "node_modules/color-convert/index.js"(exports, module) { + const conversions = require_conversions(); + const route = require_route(); + const convert$1 = {}; + const models = Object.keys(conversions); + function wrapRaw(fn) { + const wrappedFn = function(...args) { + const arg0 = args[0]; + if (arg0 === void 0 || arg0 === null) return arg0; + if (arg0.length > 1) args = arg0; + return fn(args); + }; + if ("conversion" in fn) wrappedFn.conversion = fn.conversion; + return wrappedFn; + } + function wrapRounded(fn) { + const wrappedFn = function(...args) { + const arg0 = args[0]; + if (arg0 === void 0 || arg0 === null) return arg0; + if (arg0.length > 1) args = arg0; + const result$1 = fn(args); + if (typeof result$1 === "object") for (let len = result$1.length, i$5 = 0; i$5 < len; i$5++) result$1[i$5] = Math.round(result$1[i$5]); + return result$1; + }; + if ("conversion" in fn) wrappedFn.conversion = fn.conversion; + return wrappedFn; + } + models.forEach((fromModel) => { + convert$1[fromModel] = {}; + Object.defineProperty(convert$1[fromModel], "channels", { value: conversions[fromModel].channels }); + Object.defineProperty(convert$1[fromModel], "labels", { value: conversions[fromModel].labels }); + const routes = route(fromModel); + const routeModels = Object.keys(routes); + routeModels.forEach((toModel) => { + const fn = routes[toModel]; + convert$1[fromModel][toModel] = wrapRounded(fn); + convert$1[fromModel][toModel].raw = wrapRaw(fn); + }); + }); + module.exports = convert$1; +} }); + +//#endregion +//#region node_modules/postcss-color-converter/src/constants.js +var require_constants$2 = __commonJS({ "node_modules/postcss-color-converter/src/constants.js"(exports, module) { + module.exports = { + DEFAULT_HEX_ALPHA: "ff", + DEFAULT_ALPHA: 1, + HEX_COLOR: "hex", + RGB_COLOR: "rgb", + HSL_COLOR: "hsl", + KEYWORD_COLOR: "keyword" + }; +} }); + +//#endregion +//#region node_modules/postcss-color-converter/src/utils.js +var require_utils$3 = __commonJS({ "node_modules/postcss-color-converter/src/utils.js"(exports, module) { + const convert = require_color_convert(); + const { DEFAULT_HEX_ALPHA: DEFAULT_HEX_ALPHA$1, HEX_COLOR: HEX_COLOR$2, RGB_COLOR: RGB_COLOR$2, HSL_COLOR: HSL_COLOR$2, KEYWORD_COLOR: KEYWORD_COLOR$2 } = require_constants$2(); + const parseHEXAColor$1 = (color) => { + const newColor = color.slice(1); + let hexColor; + let hexAlpha; + switch (newColor.length) { + case 4: + hexAlpha = newColor.slice(-1) + newColor.slice(-1); + hexColor = newColor.slice(0, -1); + break; + case 8: + hexAlpha = newColor.slice(-2); + hexColor = newColor.slice(0, -2); + break; + case 3: + case 6: + hexAlpha = DEFAULT_HEX_ALPHA$1; + hexColor = newColor; + break; + } + return { + hexColor, + hexAlpha + }; + }; + const convertHEXAlphaValueToNumber$1 = (value) => Number((parseInt(value, 16) / 255).toFixed(2)).toString(); + const convertNumberAlphaValueToHEX = (value) => { + let result$1 = Math.round(value * 255).toString(16); + if (result$1 == "0") result$1 = "00"; + return result$1; + }; + const getHEXColorStr$1 = (inputColorFormat, color, alpha) => alpha ? `#${convert[inputColorFormat].hex(color)}${convertNumberAlphaValueToHEX(+alpha)}`.toLowerCase() : `#${convert[inputColorFormat].hex(color)}`.toLowerCase(); + const getRGBColorArr = (color, inputColorFormat) => inputColorFormat !== RGB_COLOR$2 ? convert[inputColorFormat].rgb(color) : color; + const getRGBColorStr$1 = (inputColorFormat, color, alpha, isUseModernSyntax) => { + const colorStr = getRGBColorArr(color, inputColorFormat).join(isUseModernSyntax ? " " : ", "); + if (isUseModernSyntax) return `rgb(${colorStr}${alpha ? ` / ${alpha}` : ""})`; + return alpha ? `rgba(${colorStr}, ${alpha})` : `rgb(${colorStr})`; + }; + const getHSLArr = (color, inputColorFormat) => { + const colorArr = inputColorFormat !== HSL_COLOR$2 ? convert[inputColorFormat].hsl(color) : color; + return [ + colorArr[0].toString(), + `${colorArr[1]}%`, + `${colorArr[2]}%` + ]; + }; + const getHSLColorStr$1 = (inputColorFormat, color, alpha, isUseModernSyntax) => { + const colorStr = getHSLArr(color, inputColorFormat).join(isUseModernSyntax ? " " : ", "); + if (isUseModernSyntax) return `hsl(${colorStr}${alpha ? ` / ${alpha}` : ""})`; + return alpha ? `hsla(${colorStr}, ${alpha})` : `hsl(${colorStr})`; + }; + module.exports = { + parseHEXAColor: parseHEXAColor$1, + getRGBColorStr: getRGBColorStr$1, + getHSLColorStr: getHSLColorStr$1, + getHEXColorStr: getHEXColorStr$1, + convertHEXAlphaValueToNumber: convertHEXAlphaValueToNumber$1, + convertNumberAlphaValueToHEX + }; +} }); + +//#endregion +//#region node_modules/postcss-color-converter/src/converts.js +var require_converts = __commonJS({ "node_modules/postcss-color-converter/src/converts.js"(exports, module) { + const { parseHEXAColor, getRGBColorStr, getHSLColorStr, getHEXColorStr, convertHEXAlphaValueToNumber } = require_utils$3(); + const { DEFAULT_HEX_ALPHA, DEFAULT_ALPHA, HEX_COLOR: HEX_COLOR$1, RGB_COLOR: RGB_COLOR$1, HSL_COLOR: HSL_COLOR$1, KEYWORD_COLOR: KEYWORD_COLOR$1 } = require_constants$2(); + const convertingHEXColor$1 = (node, options) => { + const colorObj = parseHEXAColor(node.value); + if (options.outputColorFormat === RGB_COLOR$1) node.value = getRGBColorStr(HEX_COLOR$1, colorObj.hexColor, options.alwaysAlpha || colorObj.hexAlpha !== DEFAULT_HEX_ALPHA ? convertHEXAlphaValueToNumber(colorObj.hexAlpha) : false); + else if (options.outputColorFormat === HSL_COLOR$1) node.value = getHSLColorStr(HEX_COLOR$1, colorObj.hexColor, options.alwaysAlpha || colorObj.hexAlpha !== DEFAULT_HEX_ALPHA ? convertHEXAlphaValueToNumber(colorObj.hexAlpha) : false); + return node; + }; + const convertingRGBColor$1 = (node, options) => { + const newNode = node.clone({ type: "word" }); + const isModernSyntax = !node.nodes.join(" ").includes(","); + let r, g$1, b$1, a; + if (!isModernSyntax) [r, , g$1, , b$1, , a] = node.nodes; + else [r, g$1, b$1, , a] = node.nodes; + if (options.outputColorFormat === HEX_COLOR$1) newNode.value = getHEXColorStr(RGB_COLOR$1, [ + +r.value, + +g$1.value, + +b$1.value + ], a && +a.value !== DEFAULT_ALPHA && a.value); + else if (options.outputColorFormat === HSL_COLOR$1) newNode.value = getHSLColorStr(RGB_COLOR$1, [ + +r.value, + +g$1.value, + +b$1.value + ], a && a.value || options.alwaysAlpha && DEFAULT_ALPHA, isModernSyntax); + else if (options.outputColorFormat === RGB_COLOR$1) newNode.value = getRGBColorStr(RGB_COLOR$1, [ + +r.value, + +g$1.value, + +b$1.value + ], a && a.value || options.alwaysAlpha && DEFAULT_ALPHA, isModernSyntax); + node.replaceWith(newNode); + return node; + }; + const convertingHSLColor$1 = (node, options) => { + const newNode = node.clone({ type: "word" }); + let h$2, s$1, l$1, a; + const isModernSyntax = !node.nodes.join(" ").includes(","); + if (!isModernSyntax) [h$2, , s$1, , l$1, , a] = node.nodes; + else [h$2, s$1, l$1, , a] = node.nodes; + if (options.outputColorFormat === HEX_COLOR$1) newNode.value = getHEXColorStr(HSL_COLOR$1, [ + +h$2.value, + +s$1.value, + +l$1.value + ], a && +a.value !== DEFAULT_ALPHA && a.value); + else if (options.outputColorFormat === RGB_COLOR$1) newNode.value = getRGBColorStr(HSL_COLOR$1, [ + +h$2.value, + +s$1.value, + +l$1.value + ], a && a.value || options.alwaysAlpha && DEFAULT_ALPHA, isModernSyntax); + else if (options.outputColorFormat === HSL_COLOR$1) newNode.value = getHSLColorStr(HSL_COLOR$1, [ + +h$2.value, + +s$1.value, + +l$1.value + ], a && a.value || options.alwaysAlpha && DEFAULT_ALPHA, isModernSyntax); + node.replaceWith(newNode); + return node; + }; + const convertingKeywordColor$1 = (node, options) => { + if (options.outputColorFormat === HEX_COLOR$1) node.value = getHEXColorStr(KEYWORD_COLOR$1, node.value); + else if (options.outputColorFormat === RGB_COLOR$1) node.value = getRGBColorStr(KEYWORD_COLOR$1, node.value, options.alwaysAlpha && DEFAULT_ALPHA, options.isUseModernSyntax); + else if (options.outputColorFormat === HSL_COLOR$1) node.value = getHSLColorStr(KEYWORD_COLOR$1, node.value, options.alwaysAlpha && DEFAULT_ALPHA, options.isUseModernSyntax); + return node; + }; + module.exports = { + convertingHEXColor: convertingHEXColor$1, + convertingRGBColor: convertingRGBColor$1, + convertingHSLColor: convertingHSLColor$1, + convertingKeywordColor: convertingKeywordColor$1 + }; +} }); + +//#endregion +//#region node_modules/postcss-color-converter/index.js +var require_postcss_color_converter = __commonJS({ "node_modules/postcss-color-converter/index.js"(exports, module) { + const valueParser$1 = require_lib$17(); + const colors = require_color_name(); + const { convertingHEXColor, convertingRGBColor, convertingHSLColor, convertingKeywordColor } = require_converts(); + const { HEX_COLOR, RGB_COLOR, HSL_COLOR, KEYWORD_COLOR } = require_constants$2(); + const colorNames = Object.keys(colors); + const colorFormats = [ + HEX_COLOR, + RGB_COLOR, + HSL_COLOR, + KEYWORD_COLOR + ]; + const propsWithColorRegExp = /(background|border|shadow|color|fill|outline|@|--|\$)/; + const ignoredValuesRegExp = /(url)/; + const specValuesInParamsRegExp = /(\$|calc|var)/; + const defaultOptions = { + outputColorFormat: "", + alwaysAlpha: false, + ignore: [] + }; + module.exports = (options = {}) => { + const currentOptions = { + ...defaultOptions, + ...options + }; + if (!currentOptions.outputColorFormat) throw new Error(`'outputColorFormat' option is undefined.`); + if (!colorFormats.includes(currentOptions.outputColorFormat)) throw new Error(`The specified value of 'outputColorFormat' is not contained in [${colorFormats.join()}].`); + return { + postcssPlugin: "postcss-color-converter", + Declaration(decl$1) { + if (decl$1.prop && propsWithColorRegExp.test(decl$1.prop) && decl$1.value && !ignoredValuesRegExp.test(decl$1.value)) { + let valueObj = valueParser$1.parse(decl$1.value, { ignoreUnknownWords: true }); + valueObj.walk((node) => { + if (node.isColor) { + if (!currentOptions.ignore.includes(HEX_COLOR) && currentOptions.outputColorFormat !== HEX_COLOR && node.isHex) node = convertingHEXColor(node, currentOptions); + else if (!currentOptions.ignore.includes(RGB_COLOR) && (currentOptions.alwaysAlpha || currentOptions.outputColorFormat !== RGB_COLOR) && (node.name === "rgb" || node.name === "rgba") && !specValuesInParamsRegExp.test(node.params)) node = convertingRGBColor(node, currentOptions); + else if (!currentOptions.ignore.includes(HSL_COLOR) && (currentOptions.alwaysAlpha || currentOptions.outputColorFormat !== HSL_COLOR) && (node.name === "hsl" || node.name === "hsla") && !specValuesInParamsRegExp.test(node.params)) node = convertingHSLColor(node, currentOptions); + else if (!currentOptions.ignore.includes(KEYWORD_COLOR) && colorNames.includes(node.value)) node = convertingKeywordColor(node, currentOptions); + } + }); + decl$1.value = valueObj.toString(); + } + } + }; + }; + module.exports.postcss = true; +} }); +var import_postcss_color_converter = __toESM(require_postcss_color_converter()); + +//#endregion +//#region node_modules/resolve/lib/homedir.js +var require_homedir = __commonJS({ "node_modules/resolve/lib/homedir.js"(exports, module) { + var os = __require("os"); + module.exports = os.homedir || function homedir$2() { + var home = process.env.HOME; + var user = process.env.LOGNAME || process.env.USER || process.env.LNAME || process.env.USERNAME; + if (process.platform === "win32") return process.env.USERPROFILE || process.env.HOMEDRIVE + process.env.HOMEPATH || home || null; + if (process.platform === "darwin") return home || (user ? "/Users/" + user : null); + if (process.platform === "linux") return home || (process.getuid() === 0 ? "/root" : user ? "/home/" + user : null); + return home || null; + }; +} }); + +//#endregion +//#region node_modules/resolve/lib/caller.js +var require_caller = __commonJS({ "node_modules/resolve/lib/caller.js"(exports, module) { + module.exports = function() { + var origPrepareStackTrace = Error.prepareStackTrace; + Error.prepareStackTrace = function(_$2, stack$1) { + return stack$1; + }; + var stack = new Error().stack; + Error.prepareStackTrace = origPrepareStackTrace; + return stack[2].getFileName(); + }; +} }); + +//#endregion +//#region node_modules/path-parse/index.js +var require_path_parse = __commonJS({ "node_modules/path-parse/index.js"(exports, module) { + var isWindows$1 = process.platform === "win32"; + var splitWindowsRe = /^(((?:[a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/]+[^\\\/]+)?[\\\/]?)(?:[^\\\/]*[\\\/])*)((\.{1,2}|[^\\\/]+?|)(\.[^.\/\\]*|))[\\\/]*$/; + var win32$3 = {}; + function win32SplitPath(filename) { + return splitWindowsRe.exec(filename).slice(1); + } + win32$3.parse = function(pathString) { + if (typeof pathString !== "string") throw new TypeError("Parameter 'pathString' must be a string, not " + typeof pathString); + var allParts = win32SplitPath(pathString); + if (!allParts || allParts.length !== 5) throw new TypeError("Invalid path '" + pathString + "'"); + return { + root: allParts[1], + dir: allParts[0] === allParts[1] ? allParts[0] : allParts[0].slice(0, -1), + base: allParts[2], + ext: allParts[4], + name: allParts[3] + }; + }; + var splitPathRe = /^((\/?)(?:[^\/]*\/)*)((\.{1,2}|[^\/]+?|)(\.[^.\/]*|))[\/]*$/; + var posix$2 = {}; + function posixSplitPath(filename) { + return splitPathRe.exec(filename).slice(1); + } + posix$2.parse = function(pathString) { + if (typeof pathString !== "string") throw new TypeError("Parameter 'pathString' must be a string, not " + typeof pathString); + var allParts = posixSplitPath(pathString); + if (!allParts || allParts.length !== 5) throw new TypeError("Invalid path '" + pathString + "'"); + return { + root: allParts[1], + dir: allParts[0].slice(0, -1), + base: allParts[2], + ext: allParts[4], + name: allParts[3] + }; + }; + if (isWindows$1) module.exports = win32$3.parse; + else module.exports = posix$2.parse; + module.exports.posix = posix$2.parse; + module.exports.win32 = win32$3.parse; +} }); + +//#endregion +//#region node_modules/resolve/lib/node-modules-paths.js +var require_node_modules_paths = __commonJS({ "node_modules/resolve/lib/node-modules-paths.js"(exports, module) { + var path$14 = __require("path"); + var parse$9 = path$14.parse || require_path_parse(); + var getNodeModulesDirs = function getNodeModulesDirs$1(absoluteStart, modules) { + var prefix$1 = "/"; + if (/^([A-Za-z]:)/.test(absoluteStart)) prefix$1 = ""; + else if (/^\\\\/.test(absoluteStart)) prefix$1 = "\\\\"; + var paths = [absoluteStart]; + var parsed = parse$9(absoluteStart); + while (parsed.dir !== paths[paths.length - 1]) { + paths.push(parsed.dir); + parsed = parse$9(parsed.dir); + } + return paths.reduce(function(dirs, aPath) { + return dirs.concat(modules.map(function(moduleDir) { + return path$14.resolve(prefix$1, aPath, moduleDir); + })); + }, []); + }; + module.exports = function nodeModulesPaths$2(start, opts, request) { + var modules = opts && opts.moduleDirectory ? [].concat(opts.moduleDirectory) : ["node_modules"]; + if (opts && typeof opts.paths === "function") return opts.paths(request, start, function() { + return getNodeModulesDirs(start, modules); + }, opts); + var dirs = getNodeModulesDirs(start, modules); + return opts && opts.paths ? dirs.concat(opts.paths) : dirs; + }; +} }); + +//#endregion +//#region node_modules/resolve/lib/normalize-options.js +var require_normalize_options = __commonJS({ "node_modules/resolve/lib/normalize-options.js"(exports, module) { + module.exports = function(x$2, opts) { + /** + * This file is purposefully a passthrough. It's expected that third-party + * environments will override it at runtime in order to inject special logic + * into `resolve` (by manipulating the options). One such example is the PnP + * code path in Yarn. + */ + return opts || {}; + }; +} }); + +//#endregion +//#region node_modules/function-bind/implementation.js +var require_implementation = __commonJS({ "node_modules/function-bind/implementation.js"(exports, module) { + var ERROR_MESSAGE = "Function.prototype.bind called on incompatible "; + var toStr = Object.prototype.toString; + var max$1 = Math.max; + var funcType = "[object Function]"; + var concatty = function concatty$1(a, b$1) { + var arr = []; + for (var i$5 = 0; i$5 < a.length; i$5 += 1) arr[i$5] = a[i$5]; + for (var j = 0; j < b$1.length; j += 1) arr[j + a.length] = b$1[j]; + return arr; + }; + var slicy = function slicy$1(arrLike, offset) { + var arr = []; + for (var i$5 = offset || 0, j = 0; i$5 < arrLike.length; i$5 += 1, j += 1) arr[j] = arrLike[i$5]; + return arr; + }; + var joiny = function(arr, joiner) { + var str$3 = ""; + for (var i$5 = 0; i$5 < arr.length; i$5 += 1) { + str$3 += arr[i$5]; + if (i$5 + 1 < arr.length) str$3 += joiner; + } + return str$3; + }; + module.exports = function bind$1(that) { + var target = this; + if (typeof target !== "function" || toStr.apply(target) !== funcType) throw new TypeError(ERROR_MESSAGE + target); + var args = slicy(arguments, 1); + var bound; + var binder = function() { + if (this instanceof bound) { + var result$1 = target.apply(this, concatty(args, arguments)); + if (Object(result$1) === result$1) return result$1; + return this; + } + return target.apply(that, concatty(args, arguments)); + }; + var boundLength = max$1(0, target.length - args.length); + var boundArgs = []; + for (var i$5 = 0; i$5 < boundLength; i$5++) boundArgs[i$5] = "$" + i$5; + bound = Function("binder", "return function (" + joiny(boundArgs, ",") + "){ return binder.apply(this,arguments); }")(binder); + if (target.prototype) { + var Empty = function Empty$1() {}; + Empty.prototype = target.prototype; + bound.prototype = new Empty(); + Empty.prototype = null; + } + return bound; + }; +} }); + +//#endregion +//#region node_modules/function-bind/index.js +var require_function_bind = __commonJS({ "node_modules/function-bind/index.js"(exports, module) { + var implementation = require_implementation(); + module.exports = Function.prototype.bind || implementation; +} }); + +//#endregion +//#region node_modules/hasown/index.js +var require_hasown = __commonJS({ "node_modules/hasown/index.js"(exports, module) { + var call$1 = Function.prototype.call; + var $hasOwn = Object.prototype.hasOwnProperty; + var bind = require_function_bind(); + /** @type {import('.')} */ + module.exports = bind.call(call$1, $hasOwn); +} }); + +//#endregion +//#region node_modules/is-core-module/core.json +var require_core$3 = __commonJS({ "node_modules/is-core-module/core.json"(exports, module) { + module.exports = { + "assert": true, + "node:assert": [">= 14.18 && < 15", ">= 16"], + "assert/strict": ">= 15", + "node:assert/strict": ">= 16", + "async_hooks": ">= 8", + "node:async_hooks": [">= 14.18 && < 15", ">= 16"], + "buffer_ieee754": ">= 0.5 && < 0.9.7", + "buffer": true, + "node:buffer": [">= 14.18 && < 15", ">= 16"], + "child_process": true, + "node:child_process": [">= 14.18 && < 15", ">= 16"], + "cluster": ">= 0.5", + "node:cluster": [">= 14.18 && < 15", ">= 16"], + "console": true, + "node:console": [">= 14.18 && < 15", ">= 16"], + "constants": true, + "node:constants": [">= 14.18 && < 15", ">= 16"], + "crypto": true, + "node:crypto": [">= 14.18 && < 15", ">= 16"], + "_debug_agent": ">= 1 && < 8", + "_debugger": "< 8", + "dgram": true, + "node:dgram": [">= 14.18 && < 15", ">= 16"], + "diagnostics_channel": [">= 14.17 && < 15", ">= 15.1"], + "node:diagnostics_channel": [">= 14.18 && < 15", ">= 16"], + "dns": true, + "node:dns": [">= 14.18 && < 15", ">= 16"], + "dns/promises": ">= 15", + "node:dns/promises": ">= 16", + "domain": ">= 0.7.12", + "node:domain": [">= 14.18 && < 15", ">= 16"], + "events": true, + "node:events": [">= 14.18 && < 15", ">= 16"], + "freelist": "< 6", + "fs": true, + "node:fs": [">= 14.18 && < 15", ">= 16"], + "fs/promises": [">= 10 && < 10.1", ">= 14"], + "node:fs/promises": [">= 14.18 && < 15", ">= 16"], + "_http_agent": ">= 0.11.1", + "node:_http_agent": [">= 14.18 && < 15", ">= 16"], + "_http_client": ">= 0.11.1", + "node:_http_client": [">= 14.18 && < 15", ">= 16"], + "_http_common": ">= 0.11.1", + "node:_http_common": [">= 14.18 && < 15", ">= 16"], + "_http_incoming": ">= 0.11.1", + "node:_http_incoming": [">= 14.18 && < 15", ">= 16"], + "_http_outgoing": ">= 0.11.1", + "node:_http_outgoing": [">= 14.18 && < 15", ">= 16"], + "_http_server": ">= 0.11.1", + "node:_http_server": [">= 14.18 && < 15", ">= 16"], + "http": true, + "node:http": [">= 14.18 && < 15", ">= 16"], + "http2": ">= 8.8", + "node:http2": [">= 14.18 && < 15", ">= 16"], + "https": true, + "node:https": [">= 14.18 && < 15", ">= 16"], + "inspector": ">= 8", + "node:inspector": [">= 14.18 && < 15", ">= 16"], + "inspector/promises": [">= 19"], + "node:inspector/promises": [">= 19"], + "_linklist": "< 8", + "module": true, + "node:module": [">= 14.18 && < 15", ">= 16"], + "net": true, + "node:net": [">= 14.18 && < 15", ">= 16"], + "node-inspect/lib/_inspect": ">= 7.6 && < 12", + "node-inspect/lib/internal/inspect_client": ">= 7.6 && < 12", + "node-inspect/lib/internal/inspect_repl": ">= 7.6 && < 12", + "os": true, + "node:os": [">= 14.18 && < 15", ">= 16"], + "path": true, + "node:path": [">= 14.18 && < 15", ">= 16"], + "path/posix": ">= 15.3", + "node:path/posix": ">= 16", + "path/win32": ">= 15.3", + "node:path/win32": ">= 16", + "perf_hooks": ">= 8.5", + "node:perf_hooks": [">= 14.18 && < 15", ">= 16"], + "process": ">= 1", + "node:process": [">= 14.18 && < 15", ">= 16"], + "punycode": ">= 0.5", + "node:punycode": [">= 14.18 && < 15", ">= 16"], + "querystring": true, + "node:querystring": [">= 14.18 && < 15", ">= 16"], + "readline": true, + "node:readline": [">= 14.18 && < 15", ">= 16"], + "readline/promises": ">= 17", + "node:readline/promises": ">= 17", + "repl": true, + "node:repl": [">= 14.18 && < 15", ">= 16"], + "node:sea": [">= 20.12 && < 21", ">= 21.7"], + "smalloc": ">= 0.11.5 && < 3", + "node:sqlite": [">= 22.13 && < 23", ">= 23.4"], + "_stream_duplex": ">= 0.9.4", + "node:_stream_duplex": [">= 14.18 && < 15", ">= 16"], + "_stream_transform": ">= 0.9.4", + "node:_stream_transform": [">= 14.18 && < 15", ">= 16"], + "_stream_wrap": ">= 1.4.1", + "node:_stream_wrap": [">= 14.18 && < 15", ">= 16"], + "_stream_passthrough": ">= 0.9.4", + "node:_stream_passthrough": [">= 14.18 && < 15", ">= 16"], + "_stream_readable": ">= 0.9.4", + "node:_stream_readable": [">= 14.18 && < 15", ">= 16"], + "_stream_writable": ">= 0.9.4", + "node:_stream_writable": [">= 14.18 && < 15", ">= 16"], + "stream": true, + "node:stream": [">= 14.18 && < 15", ">= 16"], + "stream/consumers": ">= 16.7", + "node:stream/consumers": ">= 16.7", + "stream/promises": ">= 15", + "node:stream/promises": ">= 16", + "stream/web": ">= 16.5", + "node:stream/web": ">= 16.5", + "string_decoder": true, + "node:string_decoder": [">= 14.18 && < 15", ">= 16"], + "sys": [">= 0.4 && < 0.7", ">= 0.8"], + "node:sys": [">= 14.18 && < 15", ">= 16"], + "test/reporters": ">= 19.9 && < 20.2", + "node:test/reporters": [ + ">= 18.17 && < 19", + ">= 19.9", + ">= 20" + ], + "test/mock_loader": ">= 22.3 && < 22.7", + "node:test/mock_loader": ">= 22.3 && < 22.7", + "node:test": [">= 16.17 && < 17", ">= 18"], + "timers": true, + "node:timers": [">= 14.18 && < 15", ">= 16"], + "timers/promises": ">= 15", + "node:timers/promises": ">= 16", + "_tls_common": ">= 0.11.13", + "node:_tls_common": [">= 14.18 && < 15", ">= 16"], + "_tls_legacy": ">= 0.11.3 && < 10", + "_tls_wrap": ">= 0.11.3", + "node:_tls_wrap": [">= 14.18 && < 15", ">= 16"], + "tls": true, + "node:tls": [">= 14.18 && < 15", ">= 16"], + "trace_events": ">= 10", + "node:trace_events": [">= 14.18 && < 15", ">= 16"], + "tty": true, + "node:tty": [">= 14.18 && < 15", ">= 16"], + "url": true, + "node:url": [">= 14.18 && < 15", ">= 16"], + "util": true, + "node:util": [">= 14.18 && < 15", ">= 16"], + "util/types": ">= 15.3", + "node:util/types": ">= 16", + "v8/tools/arguments": ">= 10 && < 12", + "v8/tools/codemap": [">= 4.4 && < 5", ">= 5.2 && < 12"], + "v8/tools/consarray": [">= 4.4 && < 5", ">= 5.2 && < 12"], + "v8/tools/csvparser": [">= 4.4 && < 5", ">= 5.2 && < 12"], + "v8/tools/logreader": [">= 4.4 && < 5", ">= 5.2 && < 12"], + "v8/tools/profile_view": [">= 4.4 && < 5", ">= 5.2 && < 12"], + "v8/tools/splaytree": [">= 4.4 && < 5", ">= 5.2 && < 12"], + "v8": ">= 1", + "node:v8": [">= 14.18 && < 15", ">= 16"], + "vm": true, + "node:vm": [">= 14.18 && < 15", ">= 16"], + "wasi": [ + ">= 13.4 && < 13.5", + ">= 18.17 && < 19", + ">= 20" + ], + "node:wasi": [">= 18.17 && < 19", ">= 20"], + "worker_threads": ">= 11.7", + "node:worker_threads": [">= 14.18 && < 15", ">= 16"], + "zlib": ">= 0.5", + "node:zlib": [">= 14.18 && < 15", ">= 16"] + }; +} }); + +//#endregion +//#region node_modules/is-core-module/index.js +var require_is_core_module = __commonJS({ "node_modules/is-core-module/index.js"(exports, module) { + var hasOwn$2 = require_hasown(); + function specifierIncluded(current, specifier) { + var nodeParts = current.split("."); + var parts = specifier.split(" "); + var op = parts.length > 1 ? parts[0] : "="; + var versionParts = (parts.length > 1 ? parts[1] : parts[0]).split("."); + for (var i$5 = 0; i$5 < 3; ++i$5) { + var cur = parseInt(nodeParts[i$5] || 0, 10); + var ver = parseInt(versionParts[i$5] || 0, 10); + if (cur === ver) continue; + if (op === "<") return cur < ver; + if (op === ">=") return cur >= ver; + return false; + } + return op === ">="; + } + function matchesRange(current, range$3) { + var specifiers = range$3.split(/ ?&& ?/); + if (specifiers.length === 0) return false; + for (var i$5 = 0; i$5 < specifiers.length; ++i$5) if (!specifierIncluded(current, specifiers[i$5])) return false; + return true; + } + function versionIncluded(nodeVersion, specifierValue) { + if (typeof specifierValue === "boolean") return specifierValue; + var current = typeof nodeVersion === "undefined" ? process.versions && process.versions.node : nodeVersion; + if (typeof current !== "string") throw new TypeError(typeof nodeVersion === "undefined" ? "Unable to determine current node version" : "If provided, a valid node version is required"); + if (specifierValue && typeof specifierValue === "object") { + for (var i$5 = 0; i$5 < specifierValue.length; ++i$5) if (matchesRange(current, specifierValue[i$5])) return true; + return false; + } + return matchesRange(current, specifierValue); + } + var data$1 = require_core$3(); + module.exports = function isCore$2(x$2, nodeVersion) { + return hasOwn$2(data$1, x$2) && versionIncluded(nodeVersion, data$1[x$2]); + }; +} }); + +//#endregion +//#region node_modules/resolve/lib/async.js +var require_async = __commonJS({ "node_modules/resolve/lib/async.js"(exports, module) { + var fs$5 = __require("fs"); + var getHomedir$1 = require_homedir(); + var path$13 = __require("path"); + var caller$1 = require_caller(); + var nodeModulesPaths$1 = require_node_modules_paths(); + var normalizeOptions$3 = require_normalize_options(); + var isCore$1 = require_is_core_module(); + var realpathFS$1 = process.platform !== "win32" && fs$5.realpath && typeof fs$5.realpath.native === "function" ? fs$5.realpath.native : fs$5.realpath; + var homedir$1 = getHomedir$1(); + var defaultPaths$1 = function() { + return [path$13.join(homedir$1, ".node_modules"), path$13.join(homedir$1, ".node_libraries")]; + }; + var defaultIsFile$1 = function isFile$1(file$2, cb$1) { + fs$5.stat(file$2, function(err, stat$5) { + if (!err) return cb$1(null, stat$5.isFile() || stat$5.isFIFO()); + if (err.code === "ENOENT" || err.code === "ENOTDIR") return cb$1(null, false); + return cb$1(err); + }); + }; + var defaultIsDir$1 = function isDirectory(dir, cb$1) { + fs$5.stat(dir, function(err, stat$5) { + if (!err) return cb$1(null, stat$5.isDirectory()); + if (err.code === "ENOENT" || err.code === "ENOTDIR") return cb$1(null, false); + return cb$1(err); + }); + }; + var defaultRealpath = function realpath$1(x$2, cb$1) { + realpathFS$1(x$2, function(realpathErr, realPath) { + if (realpathErr && realpathErr.code !== "ENOENT") cb$1(realpathErr); + else cb$1(null, realpathErr ? x$2 : realPath); + }); + }; + var maybeRealpath = function maybeRealpath$1(realpath$1, x$2, opts, cb$1) { + if (opts && opts.preserveSymlinks === false) realpath$1(x$2, cb$1); + else cb$1(null, x$2); + }; + var defaultReadPackage = function defaultReadPackage$1(readFile$2, pkgfile, cb$1) { + readFile$2(pkgfile, function(readFileErr, body) { + if (readFileErr) cb$1(readFileErr); + else try { + var pkg = JSON.parse(body); + cb$1(null, pkg); + } catch (jsonErr) { + cb$1(null); + } + }); + }; + var getPackageCandidates$1 = function getPackageCandidates$2(x$2, start, opts) { + var dirs = nodeModulesPaths$1(start, opts, x$2); + for (var i$5 = 0; i$5 < dirs.length; i$5++) dirs[i$5] = path$13.join(dirs[i$5], x$2); + return dirs; + }; + module.exports = function resolve$5(x$2, options, callback) { + var cb$1 = callback; + var opts = options; + if (typeof options === "function") { + cb$1 = opts; + opts = {}; + } + if (typeof x$2 !== "string") { + var err = new TypeError("Path must be a string."); + return process.nextTick(function() { + cb$1(err); + }); + } + opts = normalizeOptions$3(x$2, opts); + var isFile$1 = opts.isFile || defaultIsFile$1; + var isDirectory = opts.isDirectory || defaultIsDir$1; + var readFile$2 = opts.readFile || fs$5.readFile; + var realpath$1 = opts.realpath || defaultRealpath; + var readPackage = opts.readPackage || defaultReadPackage; + if (opts.readFile && opts.readPackage) { + var conflictErr = new TypeError("`readFile` and `readPackage` are mutually exclusive."); + return process.nextTick(function() { + cb$1(conflictErr); + }); + } + var packageIterator = opts.packageIterator; + var extensions = opts.extensions || [".js"]; + var includeCoreModules = opts.includeCoreModules !== false; + var basedir = opts.basedir || path$13.dirname(caller$1()); + var parent = opts.filename || basedir; + opts.paths = opts.paths || defaultPaths$1(); + var absoluteStart = path$13.resolve(basedir); + maybeRealpath(realpath$1, absoluteStart, opts, function(err$1, realStart) { + if (err$1) cb$1(err$1); + else init(realStart); + }); + var res; + function init(basedir$1) { + if (/^(?:\.\.?(?:\/|$)|\/|([A-Za-z]:)?[/\\])/.test(x$2)) { + res = path$13.resolve(basedir$1, x$2); + if (x$2 === "." || x$2 === ".." || x$2.slice(-1) === "/") res += "/"; + if (/\/$/.test(x$2) && res === basedir$1) loadAsDirectory(res, opts.package, onfile); + else loadAsFile(res, opts.package, onfile); + } else if (includeCoreModules && isCore$1(x$2)) return cb$1(null, x$2); + else loadNodeModules(x$2, basedir$1, function(err$1, n$3, pkg) { + if (err$1) cb$1(err$1); + else if (n$3) return maybeRealpath(realpath$1, n$3, opts, function(err$2, realN) { + if (err$2) cb$1(err$2); + else cb$1(null, realN, pkg); + }); + else { + var moduleError = new Error("Cannot find module '" + x$2 + "' from '" + parent + "'"); + moduleError.code = "MODULE_NOT_FOUND"; + cb$1(moduleError); + } + }); + } + function onfile(err$1, m$2, pkg) { + if (err$1) cb$1(err$1); + else if (m$2) cb$1(null, m$2, pkg); + else loadAsDirectory(res, function(err$2, d$2, pkg$1) { + if (err$2) cb$1(err$2); + else if (d$2) maybeRealpath(realpath$1, d$2, opts, function(err$3, realD) { + if (err$3) cb$1(err$3); + else cb$1(null, realD, pkg$1); + }); + else { + var moduleError = new Error("Cannot find module '" + x$2 + "' from '" + parent + "'"); + moduleError.code = "MODULE_NOT_FOUND"; + cb$1(moduleError); + } + }); + } + function loadAsFile(x$3, thePackage, callback$1) { + var loadAsFilePackage = thePackage; + var cb$2 = callback$1; + if (typeof loadAsFilePackage === "function") { + cb$2 = loadAsFilePackage; + loadAsFilePackage = void 0; + } + var exts = [""].concat(extensions); + load$1(exts, x$3, loadAsFilePackage); + function load$1(exts$1, x$4, loadPackage) { + if (exts$1.length === 0) return cb$2(null, void 0, loadPackage); + var file$2 = x$4 + exts$1[0]; + var pkg = loadPackage; + if (pkg) onpkg(null, pkg); + else loadpkg(path$13.dirname(file$2), onpkg); + function onpkg(err$1, pkg_, dir) { + pkg = pkg_; + if (err$1) return cb$2(err$1); + if (dir && pkg && opts.pathFilter) { + var rfile = path$13.relative(dir, file$2); + var rel = rfile.slice(0, rfile.length - exts$1[0].length); + var r = opts.pathFilter(pkg, x$4, rel); + if (r) return load$1([""].concat(extensions.slice()), path$13.resolve(dir, r), pkg); + } + isFile$1(file$2, onex); + } + function onex(err$1, ex) { + if (err$1) return cb$2(err$1); + if (ex) return cb$2(null, file$2, pkg); + load$1(exts$1.slice(1), x$4, pkg); + } + } + } + function loadpkg(dir, cb$2) { + if (dir === "" || dir === "/") return cb$2(null); + if (process.platform === "win32" && /^\w:[/\\]*$/.test(dir)) return cb$2(null); + if (/[/\\]node_modules[/\\]*$/.test(dir)) return cb$2(null); + maybeRealpath(realpath$1, dir, opts, function(unwrapErr, pkgdir) { + if (unwrapErr) return loadpkg(path$13.dirname(dir), cb$2); + var pkgfile = path$13.join(pkgdir, "package.json"); + isFile$1(pkgfile, function(err$1, ex) { + if (!ex) return loadpkg(path$13.dirname(dir), cb$2); + readPackage(readFile$2, pkgfile, function(err$2, pkgParam) { + if (err$2) cb$2(err$2); + var pkg = pkgParam; + if (pkg && opts.packageFilter) pkg = opts.packageFilter(pkg, pkgfile); + cb$2(null, pkg, dir); + }); + }); + }); + } + function loadAsDirectory(x$3, loadAsDirectoryPackage, callback$1) { + var cb$2 = callback$1; + var fpkg = loadAsDirectoryPackage; + if (typeof fpkg === "function") { + cb$2 = fpkg; + fpkg = opts.package; + } + maybeRealpath(realpath$1, x$3, opts, function(unwrapErr, pkgdir) { + if (unwrapErr) return cb$2(unwrapErr); + var pkgfile = path$13.join(pkgdir, "package.json"); + isFile$1(pkgfile, function(err$1, ex) { + if (err$1) return cb$2(err$1); + if (!ex) return loadAsFile(path$13.join(x$3, "index"), fpkg, cb$2); + readPackage(readFile$2, pkgfile, function(err$2, pkgParam) { + if (err$2) return cb$2(err$2); + var pkg = pkgParam; + if (pkg && opts.packageFilter) pkg = opts.packageFilter(pkg, pkgfile); + if (pkg && pkg.main) { + if (typeof pkg.main !== "string") { + var mainError = new TypeError("package “" + pkg.name + "” `main` must be a string"); + mainError.code = "INVALID_PACKAGE_MAIN"; + return cb$2(mainError); + } + if (pkg.main === "." || pkg.main === "./") pkg.main = "index"; + loadAsFile(path$13.resolve(x$3, pkg.main), pkg, function(err$3, m$2, pkg$1) { + if (err$3) return cb$2(err$3); + if (m$2) return cb$2(null, m$2, pkg$1); + if (!pkg$1) return loadAsFile(path$13.join(x$3, "index"), pkg$1, cb$2); + var dir = path$13.resolve(x$3, pkg$1.main); + loadAsDirectory(dir, pkg$1, function(err$4, n$3, pkg$2) { + if (err$4) return cb$2(err$4); + if (n$3) return cb$2(null, n$3, pkg$2); + loadAsFile(path$13.join(x$3, "index"), pkg$2, cb$2); + }); + }); + return; + } + loadAsFile(path$13.join(x$3, "/index"), pkg, cb$2); + }); + }); + }); + } + function processDirs(cb$2, dirs) { + if (dirs.length === 0) return cb$2(null, void 0); + var dir = dirs[0]; + isDirectory(path$13.dirname(dir), isdir); + function isdir(err$1, isdir$1) { + if (err$1) return cb$2(err$1); + if (!isdir$1) return processDirs(cb$2, dirs.slice(1)); + loadAsFile(dir, opts.package, onfile$1); + } + function onfile$1(err$1, m$2, pkg) { + if (err$1) return cb$2(err$1); + if (m$2) return cb$2(null, m$2, pkg); + loadAsDirectory(dir, opts.package, ondir); + } + function ondir(err$1, n$3, pkg) { + if (err$1) return cb$2(err$1); + if (n$3) return cb$2(null, n$3, pkg); + processDirs(cb$2, dirs.slice(1)); + } + } + function loadNodeModules(x$3, start, cb$2) { + var thunk = function() { + return getPackageCandidates$1(x$3, start, opts); + }; + processDirs(cb$2, packageIterator ? packageIterator(x$3, start, thunk, opts) : thunk()); + } + }; +} }); + +//#endregion +//#region node_modules/resolve/lib/core.json +var require_core$2 = __commonJS({ "node_modules/resolve/lib/core.json"(exports, module) { + module.exports = { + "assert": true, + "node:assert": [">= 14.18 && < 15", ">= 16"], + "assert/strict": ">= 15", + "node:assert/strict": ">= 16", + "async_hooks": ">= 8", + "node:async_hooks": [">= 14.18 && < 15", ">= 16"], + "buffer_ieee754": ">= 0.5 && < 0.9.7", + "buffer": true, + "node:buffer": [">= 14.18 && < 15", ">= 16"], + "child_process": true, + "node:child_process": [">= 14.18 && < 15", ">= 16"], + "cluster": ">= 0.5", + "node:cluster": [">= 14.18 && < 15", ">= 16"], + "console": true, + "node:console": [">= 14.18 && < 15", ">= 16"], + "constants": true, + "node:constants": [">= 14.18 && < 15", ">= 16"], + "crypto": true, + "node:crypto": [">= 14.18 && < 15", ">= 16"], + "_debug_agent": ">= 1 && < 8", + "_debugger": "< 8", + "dgram": true, + "node:dgram": [">= 14.18 && < 15", ">= 16"], + "diagnostics_channel": [">= 14.17 && < 15", ">= 15.1"], + "node:diagnostics_channel": [">= 14.18 && < 15", ">= 16"], + "dns": true, + "node:dns": [">= 14.18 && < 15", ">= 16"], + "dns/promises": ">= 15", + "node:dns/promises": ">= 16", + "domain": ">= 0.7.12", + "node:domain": [">= 14.18 && < 15", ">= 16"], + "events": true, + "node:events": [">= 14.18 && < 15", ">= 16"], + "freelist": "< 6", + "fs": true, + "node:fs": [">= 14.18 && < 15", ">= 16"], + "fs/promises": [">= 10 && < 10.1", ">= 14"], + "node:fs/promises": [">= 14.18 && < 15", ">= 16"], + "_http_agent": ">= 0.11.1", + "node:_http_agent": [">= 14.18 && < 15", ">= 16"], + "_http_client": ">= 0.11.1", + "node:_http_client": [">= 14.18 && < 15", ">= 16"], + "_http_common": ">= 0.11.1", + "node:_http_common": [">= 14.18 && < 15", ">= 16"], + "_http_incoming": ">= 0.11.1", + "node:_http_incoming": [">= 14.18 && < 15", ">= 16"], + "_http_outgoing": ">= 0.11.1", + "node:_http_outgoing": [">= 14.18 && < 15", ">= 16"], + "_http_server": ">= 0.11.1", + "node:_http_server": [">= 14.18 && < 15", ">= 16"], + "http": true, + "node:http": [">= 14.18 && < 15", ">= 16"], + "http2": ">= 8.8", + "node:http2": [">= 14.18 && < 15", ">= 16"], + "https": true, + "node:https": [">= 14.18 && < 15", ">= 16"], + "inspector": ">= 8", + "node:inspector": [">= 14.18 && < 15", ">= 16"], + "inspector/promises": [">= 19"], + "node:inspector/promises": [">= 19"], + "_linklist": "< 8", + "module": true, + "node:module": [">= 14.18 && < 15", ">= 16"], + "net": true, + "node:net": [">= 14.18 && < 15", ">= 16"], + "node-inspect/lib/_inspect": ">= 7.6 && < 12", + "node-inspect/lib/internal/inspect_client": ">= 7.6 && < 12", + "node-inspect/lib/internal/inspect_repl": ">= 7.6 && < 12", + "os": true, + "node:os": [">= 14.18 && < 15", ">= 16"], + "path": true, + "node:path": [">= 14.18 && < 15", ">= 16"], + "path/posix": ">= 15.3", + "node:path/posix": ">= 16", + "path/win32": ">= 15.3", + "node:path/win32": ">= 16", + "perf_hooks": ">= 8.5", + "node:perf_hooks": [">= 14.18 && < 15", ">= 16"], + "process": ">= 1", + "node:process": [">= 14.18 && < 15", ">= 16"], + "punycode": ">= 0.5", + "node:punycode": [">= 14.18 && < 15", ">= 16"], + "querystring": true, + "node:querystring": [">= 14.18 && < 15", ">= 16"], + "readline": true, + "node:readline": [">= 14.18 && < 15", ">= 16"], + "readline/promises": ">= 17", + "node:readline/promises": ">= 17", + "repl": true, + "node:repl": [">= 14.18 && < 15", ">= 16"], + "node:sea": [">= 20.12 && < 21", ">= 21.7"], + "smalloc": ">= 0.11.5 && < 3", + "node:sqlite": ">= 23.4", + "_stream_duplex": ">= 0.9.4", + "node:_stream_duplex": [">= 14.18 && < 15", ">= 16"], + "_stream_transform": ">= 0.9.4", + "node:_stream_transform": [">= 14.18 && < 15", ">= 16"], + "_stream_wrap": ">= 1.4.1", + "node:_stream_wrap": [">= 14.18 && < 15", ">= 16"], + "_stream_passthrough": ">= 0.9.4", + "node:_stream_passthrough": [">= 14.18 && < 15", ">= 16"], + "_stream_readable": ">= 0.9.4", + "node:_stream_readable": [">= 14.18 && < 15", ">= 16"], + "_stream_writable": ">= 0.9.4", + "node:_stream_writable": [">= 14.18 && < 15", ">= 16"], + "stream": true, + "node:stream": [">= 14.18 && < 15", ">= 16"], + "stream/consumers": ">= 16.7", + "node:stream/consumers": ">= 16.7", + "stream/promises": ">= 15", + "node:stream/promises": ">= 16", + "stream/web": ">= 16.5", + "node:stream/web": ">= 16.5", + "string_decoder": true, + "node:string_decoder": [">= 14.18 && < 15", ">= 16"], + "sys": [">= 0.4 && < 0.7", ">= 0.8"], + "node:sys": [">= 14.18 && < 15", ">= 16"], + "test/reporters": ">= 19.9 && < 20.2", + "node:test/reporters": [ + ">= 18.17 && < 19", + ">= 19.9", + ">= 20" + ], + "test/mock_loader": ">= 22.3 && < 22.7", + "node:test/mock_loader": ">= 22.3 && < 22.7", + "node:test": [">= 16.17 && < 17", ">= 18"], + "timers": true, + "node:timers": [">= 14.18 && < 15", ">= 16"], + "timers/promises": ">= 15", + "node:timers/promises": ">= 16", + "_tls_common": ">= 0.11.13", + "node:_tls_common": [">= 14.18 && < 15", ">= 16"], + "_tls_legacy": ">= 0.11.3 && < 10", + "_tls_wrap": ">= 0.11.3", + "node:_tls_wrap": [">= 14.18 && < 15", ">= 16"], + "tls": true, + "node:tls": [">= 14.18 && < 15", ">= 16"], + "trace_events": ">= 10", + "node:trace_events": [">= 14.18 && < 15", ">= 16"], + "tty": true, + "node:tty": [">= 14.18 && < 15", ">= 16"], + "url": true, + "node:url": [">= 14.18 && < 15", ">= 16"], + "util": true, + "node:util": [">= 14.18 && < 15", ">= 16"], + "util/types": ">= 15.3", + "node:util/types": ">= 16", + "v8/tools/arguments": ">= 10 && < 12", + "v8/tools/codemap": [">= 4.4 && < 5", ">= 5.2 && < 12"], + "v8/tools/consarray": [">= 4.4 && < 5", ">= 5.2 && < 12"], + "v8/tools/csvparser": [">= 4.4 && < 5", ">= 5.2 && < 12"], + "v8/tools/logreader": [">= 4.4 && < 5", ">= 5.2 && < 12"], + "v8/tools/profile_view": [">= 4.4 && < 5", ">= 5.2 && < 12"], + "v8/tools/splaytree": [">= 4.4 && < 5", ">= 5.2 && < 12"], + "v8": ">= 1", + "node:v8": [">= 14.18 && < 15", ">= 16"], + "vm": true, + "node:vm": [">= 14.18 && < 15", ">= 16"], + "wasi": [ + ">= 13.4 && < 13.5", + ">= 18.17 && < 19", + ">= 20" + ], + "node:wasi": [">= 18.17 && < 19", ">= 20"], + "worker_threads": ">= 11.7", + "node:worker_threads": [">= 14.18 && < 15", ">= 16"], + "zlib": ">= 0.5", + "node:zlib": [">= 14.18 && < 15", ">= 16"] + }; +} }); + +//#endregion +//#region node_modules/resolve/lib/core.js +var require_core$1 = __commonJS({ "node_modules/resolve/lib/core.js"(exports, module) { + var isCoreModule$1 = require_is_core_module(); + var data = require_core$2(); + var core = {}; + for (var mod in data) if (Object.prototype.hasOwnProperty.call(data, mod)) core[mod] = isCoreModule$1(mod); + module.exports = core; +} }); + +//#endregion +//#region node_modules/resolve/lib/is-core.js +var require_is_core = __commonJS({ "node_modules/resolve/lib/is-core.js"(exports, module) { + var isCoreModule = require_is_core_module(); + module.exports = function isCore$2(x$2) { + return isCoreModule(x$2); + }; +} }); + +//#endregion +//#region node_modules/resolve/lib/sync.js +var require_sync$1 = __commonJS({ "node_modules/resolve/lib/sync.js"(exports, module) { + var isCore = require_is_core_module(); + var fs$4 = __require("fs"); + var path$12 = __require("path"); + var getHomedir = require_homedir(); + var caller = require_caller(); + var nodeModulesPaths = require_node_modules_paths(); + var normalizeOptions$2 = require_normalize_options(); + var realpathFS = process.platform !== "win32" && fs$4.realpathSync && typeof fs$4.realpathSync.native === "function" ? fs$4.realpathSync.native : fs$4.realpathSync; + var homedir = getHomedir(); + var defaultPaths = function() { + return [path$12.join(homedir, ".node_modules"), path$12.join(homedir, ".node_libraries")]; + }; + var defaultIsFile = function isFile$1(file$2) { + try { + var stat$5 = fs$4.statSync(file$2, { throwIfNoEntry: false }); + } catch (e) { + if (e && (e.code === "ENOENT" || e.code === "ENOTDIR")) return false; + throw e; + } + return !!stat$5 && (stat$5.isFile() || stat$5.isFIFO()); + }; + var defaultIsDir = function isDirectory(dir) { + try { + var stat$5 = fs$4.statSync(dir, { throwIfNoEntry: false }); + } catch (e) { + if (e && (e.code === "ENOENT" || e.code === "ENOTDIR")) return false; + throw e; + } + return !!stat$5 && stat$5.isDirectory(); + }; + var defaultRealpathSync = function realpathSync$1(x$2) { + try { + return realpathFS(x$2); + } catch (realpathErr) { + if (realpathErr.code !== "ENOENT") throw realpathErr; + } + return x$2; + }; + var maybeRealpathSync = function maybeRealpathSync$1(realpathSync$1, x$2, opts) { + if (opts && opts.preserveSymlinks === false) return realpathSync$1(x$2); + return x$2; + }; + var defaultReadPackageSync = function defaultReadPackageSync$1(readFileSync$2, pkgfile) { + var body = readFileSync$2(pkgfile); + try { + var pkg = JSON.parse(body); + return pkg; + } catch (jsonErr) {} + }; + var getPackageCandidates = function getPackageCandidates$2(x$2, start, opts) { + var dirs = nodeModulesPaths(start, opts, x$2); + for (var i$5 = 0; i$5 < dirs.length; i$5++) dirs[i$5] = path$12.join(dirs[i$5], x$2); + return dirs; + }; + module.exports = function resolveSync(x$2, options) { + if (typeof x$2 !== "string") throw new TypeError("Path must be a string."); + var opts = normalizeOptions$2(x$2, options); + var isFile$1 = opts.isFile || defaultIsFile; + var readFileSync$2 = opts.readFileSync || fs$4.readFileSync; + var isDirectory = opts.isDirectory || defaultIsDir; + var realpathSync$1 = opts.realpathSync || defaultRealpathSync; + var readPackageSync = opts.readPackageSync || defaultReadPackageSync; + if (opts.readFileSync && opts.readPackageSync) throw new TypeError("`readFileSync` and `readPackageSync` are mutually exclusive."); + var packageIterator = opts.packageIterator; + var extensions = opts.extensions || [".js"]; + var includeCoreModules = opts.includeCoreModules !== false; + var basedir = opts.basedir || path$12.dirname(caller()); + var parent = opts.filename || basedir; + opts.paths = opts.paths || defaultPaths(); + var absoluteStart = maybeRealpathSync(realpathSync$1, path$12.resolve(basedir), opts); + if (/^(?:\.\.?(?:\/|$)|\/|([A-Za-z]:)?[/\\])/.test(x$2)) { + var res = path$12.resolve(absoluteStart, x$2); + if (x$2 === "." || x$2 === ".." || x$2.slice(-1) === "/") res += "/"; + var m$2 = loadAsFileSync(res) || loadAsDirectorySync(res); + if (m$2) return maybeRealpathSync(realpathSync$1, m$2, opts); + } else if (includeCoreModules && isCore(x$2)) return x$2; + else { + var n$3 = loadNodeModulesSync(x$2, absoluteStart); + if (n$3) return maybeRealpathSync(realpathSync$1, n$3, opts); + } + var err = new Error("Cannot find module '" + x$2 + "' from '" + parent + "'"); + err.code = "MODULE_NOT_FOUND"; + throw err; + function loadAsFileSync(x$3) { + var pkg = loadpkg(path$12.dirname(x$3)); + if (pkg && pkg.dir && pkg.pkg && opts.pathFilter) { + var rfile = path$12.relative(pkg.dir, x$3); + var r = opts.pathFilter(pkg.pkg, x$3, rfile); + if (r) x$3 = path$12.resolve(pkg.dir, r); + } + if (isFile$1(x$3)) return x$3; + for (var i$5 = 0; i$5 < extensions.length; i$5++) { + var file$2 = x$3 + extensions[i$5]; + if (isFile$1(file$2)) return file$2; + } + } + function loadpkg(dir) { + if (dir === "" || dir === "/") return; + if (process.platform === "win32" && /^\w:[/\\]*$/.test(dir)) return; + if (/[/\\]node_modules[/\\]*$/.test(dir)) return; + var pkgfile = path$12.join(maybeRealpathSync(realpathSync$1, dir, opts), "package.json"); + if (!isFile$1(pkgfile)) return loadpkg(path$12.dirname(dir)); + var pkg = readPackageSync(readFileSync$2, pkgfile); + if (pkg && opts.packageFilter) pkg = opts.packageFilter( + pkg, + /*pkgfile,*/ + dir +); + return { + pkg, + dir + }; + } + function loadAsDirectorySync(x$3) { + var pkgfile = path$12.join(maybeRealpathSync(realpathSync$1, x$3, opts), "/package.json"); + if (isFile$1(pkgfile)) { + try { + var pkg = readPackageSync(readFileSync$2, pkgfile); + } catch (e) {} + if (pkg && opts.packageFilter) pkg = opts.packageFilter( + pkg, + /*pkgfile,*/ + x$3 +); + if (pkg && pkg.main) { + if (typeof pkg.main !== "string") { + var mainError = new TypeError("package “" + pkg.name + "” `main` must be a string"); + mainError.code = "INVALID_PACKAGE_MAIN"; + throw mainError; + } + if (pkg.main === "." || pkg.main === "./") pkg.main = "index"; + try { + var m$3 = loadAsFileSync(path$12.resolve(x$3, pkg.main)); + if (m$3) return m$3; + var n$4 = loadAsDirectorySync(path$12.resolve(x$3, pkg.main)); + if (n$4) return n$4; + } catch (e) {} + } + } + return loadAsFileSync(path$12.join(x$3, "/index")); + } + function loadNodeModulesSync(x$3, start) { + var thunk = function() { + return getPackageCandidates(x$3, start, opts); + }; + var dirs = packageIterator ? packageIterator(x$3, start, thunk, opts) : thunk(); + for (var i$5 = 0; i$5 < dirs.length; i$5++) { + var dir = dirs[i$5]; + if (isDirectory(path$12.dirname(dir))) { + var m$3 = loadAsFileSync(dir); + if (m$3) return m$3; + var n$4 = loadAsDirectorySync(dir); + if (n$4) return n$4; + } + } + } + }; +} }); + +//#endregion +//#region node_modules/resolve/index.js +var require_resolve = __commonJS({ "node_modules/resolve/index.js"(exports, module) { + var async = require_async(); + async.core = require_core$1(); + async.isCore = require_is_core(); + async.sync = require_sync$1(); + module.exports = async; +} }); +var import_resolve = __toESM(require_resolve()); + +//#endregion +//#region src/utils.ts +function normalizePath$1(...paths) { + const f$1 = path.join(...paths).replace(/\\/g, "/"); + if (/^\.[/\\]/.test(paths[0])) return `./${f$1}`; + return f$1; +} +const relativePath = (from, to) => normalizePath$1(path.relative(from, to)); +const humanlizePath = (file$2) => relativePath(process.cwd(), file$2); +const resolveId = async (id$4, options = {}) => new Promise((resolve$5) => (0, import_resolve.default)(id$4, options, (err, res) => err ? resolve$5() : resolve$5(res))); +/** Every project is expected to have a main file which imports both vue3-ui css packages */ +const isMain = (code$1) => new RegExp("import.*@bulvar/bulma/css/bulma.css").test(code$1) && new RegExp("import.*@pathscale/bulma-extensions").test(code$1); +const getDeclaredVariables = (code$1) => code$1.match(/(?<=--)(.*?)(?=:)/g) ?? []; +const isVariableUsed = (v$1, code$1) => code$1.includes(`var(--${v$1})`); +/** The imports are nuked and replaced with an import for a fake file that will be dynamically created by the plugin */ +const injectFakeBundle = (code$1) => `import './vue3-ui-bundle.css'; + ${code$1.replace(/import.*@bulvar\/bulma\/css\/bulma\.css.*/gi, "").replace(/import.*@pathscale\/bulma-extensions.*/gi, "").replace(/import.*user\.css.*/gi, "")}`; +const makeVue3UiBundle = async (id$4) => { + const bulmaCSSFile = await resolveId("@bulvar/bulma/css/bulma.css"); + if (!bulmaCSSFile) throw new Error("TRANSFORM - BULMA CSS NOT FOUND"); + const extensionsCSSFile = await resolveId("@pathscale/bulma-extensions-css-var"); + if (!extensionsCSSFile) throw new Error("TRANSFORM - EXTENSIONS CSS NOT FOUND"); + let bulmaCSS = await import_lib$3.default.readFile(bulmaCSSFile, "utf-8"); + const extensionsCSS = await import_lib$3.default.readFile(extensionsCSSFile, "utf-8"); + const userCSSFile = normalizePath$1(path.dirname(id$4), "user.css"); + if (!await import_lib$3.default.pathExists(userCSSFile)) return bulmaCSS + extensionsCSS; + let userCSS = await import_lib$3.default.readFile(userCSSFile, "utf-8"); + console.log(`TRANSFORM - USER CSS FOUND (${humanlizePath(userCSSFile)})`); + userCSS = postcss_default((0, import_postcss_color_converter.default)({ outputColorFormat: "hsl" })).process(userCSS).css; + userCSS = userCSS.replace(/\/\*[^*]*\*+([^*/][^*]*\*+)*\//gi, ""); + userCSS = userCSS.replace(/--(.*):\shsl\((\d*),\s*(\d*)%,\s*(\d*)%\);?/gi, (_$2, name, h$2, s$1, l$1) => `${_$2.endsWith(";") ? _$2 : _$2.slice(0, -1)} + --${name}-h: ${h$2}; + --${name}-s: ${s$1}%; + --${name}-l: ${l$1}%; + --${name}-a: 1;`); + const vars = getDeclaredVariables(userCSS); + for (const v$1 of vars) { + const decl$1 = new RegExp(`.*${v$1}:.*`); + bulmaCSS = bulmaCSS.replace(decl$1, decl$1.exec(userCSS)?.[0] ?? ""); + } + return bulmaCSS + extensionsCSS; +}; +const kebabCase = (s$1) => { + const str$3 = s$1.slice(1).replace(/[A-Z]/g, (m$2) => `-${m$2.toLowerCase()}`); + return s$1.charAt(0).toLowerCase() + str$3; +}; +const camelCase$1 = (s$1) => { + const str$3 = s$1.slice(1).replace(/-([a-z])/g, (_$2, $1) => $1.toUpperCase()); + return s$1.charAt(0).toLowerCase() + str$3; +}; +const pascalCase = (s$1) => { + const str$3 = s$1.slice(1).replace(/-([a-z])/g, (_$2, $1) => $1.toUpperCase()); + return s$1.charAt(0).toUpperCase() + str$3; +}; + +//#endregion +//#region node_modules/@vue/shared/dist/shared.esm-bundler.js +var shared_esm_bundler_exports = {}; +__export(shared_esm_bundler_exports, { + EMPTY_ARR: () => EMPTY_ARR, + EMPTY_OBJ: () => EMPTY_OBJ, + NO: () => NO, + NOOP: () => NOOP, + PatchFlagNames: () => PatchFlagNames, + babelParserDefaultPlugins: () => babelParserDefaultPlugins, + camelize: () => camelize, + capitalize: () => capitalize$1, + def: () => def, + escapeHtml: () => escapeHtml, + escapeHtmlComment: () => escapeHtmlComment, + extend: () => extend$3, + generateCodeFrame: () => generateCodeFrame, + getGlobalThis: () => getGlobalThis, + hasChanged: () => hasChanged, + hasOwn: () => hasOwn$1, + hyphenate: () => hyphenate, + invokeArrayFns: () => invokeArrayFns, + isArray: () => isArray$4, + isBooleanAttr: () => isBooleanAttr, + isDate: () => isDate, + isFunction: () => isFunction$9, + isGloballyWhitelisted: () => isGloballyWhitelisted, + isHTMLTag: () => isHTMLTag, + isIntegerKey: () => isIntegerKey, + isKnownAttr: () => isKnownAttr, + isMap: () => isMap$1, + isModelListener: () => isModelListener, + isNoUnitNumericStyleProp: () => isNoUnitNumericStyleProp, + isObject: () => isObject$4, + isOn: () => isOn, + isPlainObject: () => isPlainObject$1, + isPromise: () => isPromise, + isReservedProp: () => isReservedProp, + isSSRSafeAttrName: () => isSSRSafeAttrName, + isSVGTag: () => isSVGTag, + isSet: () => isSet$1, + isSpecialBooleanAttr: () => isSpecialBooleanAttr, + isString: () => isString$4, + isSymbol: () => isSymbol$1, + isVoidTag: () => isVoidTag, + looseEqual: () => looseEqual, + looseIndexOf: () => looseIndexOf, + makeMap: () => makeMap, + normalizeClass: () => normalizeClass, + normalizeStyle: () => normalizeStyle, + objectToString: () => objectToString$2, + parseStringStyle: () => parseStringStyle, + propsToAttrMap: () => propsToAttrMap, + remove: () => remove$1, + slotFlagsText: () => slotFlagsText, + stringifyStyle: () => stringifyStyle, + toDisplayString: () => toDisplayString, + toHandlerKey: () => toHandlerKey, + toNumber: () => toNumber, + toRawType: () => toRawType, + toTypeString: () => toTypeString +}); +/** + +* Make a map and return a function for checking if a key + +* is in that map. + +* IMPORTANT: all calls of this function must be prefixed with + +* \/\*#\_\_PURE\_\_\*\/ + +* So that rollup can tree-shake them if necessary. + +*/ +function makeMap(str$3, expectsLowerCase) { + const map$1 = Object.create(null); + const list$4 = str$3.split(","); + for (let i$5 = 0; i$5 < list$4.length; i$5++) map$1[list$4[i$5]] = true; + return expectsLowerCase ? (val) => !!map$1[val.toLowerCase()] : (val) => !!map$1[val]; +} +function generateCodeFrame(source, start = 0, end = source.length) { + const lines = source.split(/\r?\n/); + let count = 0; + const res = []; + for (let i$5 = 0; i$5 < lines.length; i$5++) { + count += lines[i$5].length + 1; + if (count >= start) { + for (let j = i$5 - range$2; j <= i$5 + range$2 || end > count; j++) { + if (j < 0 || j >= lines.length) continue; + const line = j + 1; + res.push(`${line}${" ".repeat(Math.max(3 - String(line).length, 0))}| ${lines[j]}`); + const lineLength = lines[j].length; + if (j === i$5) { + const pad$1 = start - (count - lineLength) + 1; + const length = Math.max(1, end > count ? lineLength - pad$1 : end - start); + res.push(` | ` + " ".repeat(pad$1) + "^".repeat(length)); + } else if (j > i$5) { + if (end > count) { + const length = Math.max(Math.min(end - count, lineLength), 1); + res.push(` | ` + "^".repeat(length)); + } + count += lineLength + 1; + } + } + break; + } + } + return res.join("\n"); +} +function isSSRSafeAttrName(name) { + if (attrValidationCache.hasOwnProperty(name)) return attrValidationCache[name]; + const isUnsafe = unsafeAttrCharRE.test(name); + if (isUnsafe) console.error(`unsafe attribute name: ${name}`); + return attrValidationCache[name] = !isUnsafe; +} +function normalizeStyle(value) { + if (isArray$4(value)) { + const res = {}; + for (let i$5 = 0; i$5 < value.length; i$5++) { + const item = value[i$5]; + const normalized = normalizeStyle(isString$4(item) ? parseStringStyle(item) : item); + if (normalized) for (const key in normalized) res[key] = normalized[key]; + } + return res; + } else if (isObject$4(value)) return value; +} +function parseStringStyle(cssText) { + const ret = {}; + cssText.split(listDelimiterRE).forEach((item) => { + if (item) { + const tmp = item.split(propertyDelimiterRE); + tmp.length > 1 && (ret[tmp[0].trim()] = tmp[1].trim()); + } + }); + return ret; +} +function stringifyStyle(styles) { + let ret = ""; + if (!styles) return ret; + for (const key in styles) { + const value = styles[key]; + const normalizedKey = key.startsWith(`--`) ? key : hyphenate(key); + if (isString$4(value) || typeof value === "number" && isNoUnitNumericStyleProp(normalizedKey)) ret += `${normalizedKey}:${value};`; + } + return ret; +} +function normalizeClass(value) { + let res = ""; + if (isString$4(value)) res = value; + else if (isArray$4(value)) for (let i$5 = 0; i$5 < value.length; i$5++) { + const normalized = normalizeClass(value[i$5]); + if (normalized) res += normalized + " "; + } + else if (isObject$4(value)) { + for (const name in value) if (value[name]) res += name + " "; + } + return res.trim(); +} +function escapeHtml(string$3) { + const str$3 = "" + string$3; + const match = escapeRE.exec(str$3); + if (!match) return str$3; + let html = ""; + let escaped; + let index$1; + let lastIndex = 0; + for (index$1 = match.index; index$1 < str$3.length; index$1++) { + switch (str$3.charCodeAt(index$1)) { + case 34: + escaped = """; + break; + case 38: + escaped = "&"; + break; + case 39: + escaped = "'"; + break; + case 60: + escaped = "<"; + break; + case 62: + escaped = ">"; + break; + default: continue; + } + if (lastIndex !== index$1) html += str$3.substring(lastIndex, index$1); + lastIndex = index$1 + 1; + html += escaped; + } + return lastIndex !== index$1 ? html + str$3.substring(lastIndex, index$1) : html; +} +function escapeHtmlComment(src) { + return src.replace(commentStripRE, ""); +} +function looseCompareArrays(a, b$1) { + if (a.length !== b$1.length) return false; + let equal = true; + for (let i$5 = 0; equal && i$5 < a.length; i$5++) equal = looseEqual(a[i$5], b$1[i$5]); + return equal; +} +function looseEqual(a, b$1) { + if (a === b$1) return true; + let aValidType = isDate(a); + let bValidType = isDate(b$1); + if (aValidType || bValidType) return aValidType && bValidType ? a.getTime() === b$1.getTime() : false; + aValidType = isArray$4(a); + bValidType = isArray$4(b$1); + if (aValidType || bValidType) return aValidType && bValidType ? looseCompareArrays(a, b$1) : false; + aValidType = isObject$4(a); + bValidType = isObject$4(b$1); + if (aValidType || bValidType) { + /* istanbul ignore if: this if will probably never be called */ + if (!aValidType || !bValidType) return false; + const aKeysCount = Object.keys(a).length; + const bKeysCount = Object.keys(b$1).length; + if (aKeysCount !== bKeysCount) return false; + for (const key in a) { + const aHasKey = a.hasOwnProperty(key); + const bHasKey = b$1.hasOwnProperty(key); + if (aHasKey && !bHasKey || !aHasKey && bHasKey || !looseEqual(a[key], b$1[key])) return false; + } + } + return String(a) === String(b$1); +} +function looseIndexOf(arr, val) { + return arr.findIndex((item) => looseEqual(item, val)); +} +var PatchFlagNames, slotFlagsText, GLOBALS_WHITE_LISTED, isGloballyWhitelisted, range$2, specialBooleanAttrs, isSpecialBooleanAttr, isBooleanAttr, unsafeAttrCharRE, attrValidationCache, propsToAttrMap, isNoUnitNumericStyleProp, isKnownAttr, listDelimiterRE, propertyDelimiterRE, HTML_TAGS, SVG_TAGS, VOID_TAGS, isHTMLTag, isSVGTag, isVoidTag, escapeRE, commentStripRE, toDisplayString, replacer, babelParserDefaultPlugins, EMPTY_OBJ, EMPTY_ARR, NOOP, NO, onRE, isOn, isModelListener, extend$3, remove$1, hasOwnProperty$5, hasOwn$1, isArray$4, isMap$1, isSet$1, isDate, isFunction$9, isString$4, isSymbol$1, isObject$4, isPromise, objectToString$2, toTypeString, toRawType, isPlainObject$1, isIntegerKey, isReservedProp, cacheStringFunction$1, camelizeRE$1, camelize, hyphenateRE, hyphenate, capitalize$1, toHandlerKey, hasChanged, invokeArrayFns, def, toNumber, _globalThis, getGlobalThis; +var init_shared_esm_bundler = __esm({ "node_modules/@vue/shared/dist/shared.esm-bundler.js"() { + PatchFlagNames = { + [1]: `TEXT`, + [2]: `CLASS`, + [4]: `STYLE`, + [8]: `PROPS`, + [16]: `FULL_PROPS`, + [32]: `HYDRATE_EVENTS`, + [64]: `STABLE_FRAGMENT`, + [128]: `KEYED_FRAGMENT`, + [256]: `UNKEYED_FRAGMENT`, + [512]: `NEED_PATCH`, + [1024]: `DYNAMIC_SLOTS`, + [2048]: `DEV_ROOT_FRAGMENT`, + [-1]: `HOISTED`, + [-2]: `BAIL` + }; + slotFlagsText = { + [1]: "STABLE", + [2]: "DYNAMIC", + [3]: "FORWARDED" + }; + GLOBALS_WHITE_LISTED = "Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt"; + isGloballyWhitelisted = /* @__PURE__ */ makeMap(GLOBALS_WHITE_LISTED); + range$2 = 2; + specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`; + isSpecialBooleanAttr = /* @__PURE__ */ makeMap(specialBooleanAttrs); + isBooleanAttr = /* @__PURE__ */ makeMap(specialBooleanAttrs + ",async,autofocus,autoplay,controls,default,defer,disabled,hidden,loop,open,required,reversed,scoped,seamless,checked,muted,multiple,selected"); + unsafeAttrCharRE = /[>/="'\u0009\u000a\u000c\u0020]/; + attrValidationCache = {}; + propsToAttrMap = { + acceptCharset: "accept-charset", + className: "class", + htmlFor: "for", + httpEquiv: "http-equiv" + }; + isNoUnitNumericStyleProp = /* @__PURE__ */ makeMap("animation-iteration-count,border-image-outset,border-image-slice,border-image-width,box-flex,box-flex-group,box-ordinal-group,column-count,columns,flex,flex-grow,flex-positive,flex-shrink,flex-negative,flex-order,grid-row,grid-row-end,grid-row-span,grid-row-start,grid-column,grid-column-end,grid-column-span,grid-column-start,font-weight,line-clamp,line-height,opacity,order,orphans,tab-size,widows,z-index,zoom,fill-opacity,flood-opacity,stop-opacity,stroke-dasharray,stroke-dashoffset,stroke-miterlimit,stroke-opacity,stroke-width"); + isKnownAttr = /* @__PURE__ */ makeMap("accept,accept-charset,accesskey,action,align,allow,alt,async,autocapitalize,autocomplete,autofocus,autoplay,background,bgcolor,border,buffered,capture,challenge,charset,checked,cite,class,code,codebase,color,cols,colspan,content,contenteditable,contextmenu,controls,coords,crossorigin,csp,data,datetime,decoding,default,defer,dir,dirname,disabled,download,draggable,dropzone,enctype,enterkeyhint,for,form,formaction,formenctype,formmethod,formnovalidate,formtarget,headers,height,hidden,high,href,hreflang,http-equiv,icon,id,importance,integrity,ismap,itemprop,keytype,kind,label,lang,language,loading,list,loop,low,manifest,max,maxlength,minlength,media,min,multiple,muted,name,novalidate,open,optimum,pattern,ping,placeholder,poster,preload,radiogroup,readonly,referrerpolicy,rel,required,reversed,rows,rowspan,sandbox,scope,scoped,selected,shape,size,sizes,slot,span,spellcheck,src,srcdoc,srclang,srcset,start,step,style,summary,tabindex,target,title,translate,type,usemap,value,width,wrap"); + listDelimiterRE = /;(?![^(]*\))/g; + propertyDelimiterRE = /:(.+)/; + HTML_TAGS = "html,body,base,head,link,meta,style,title,address,article,aside,footer,header,h1,h2,h3,h4,h5,h6,hgroup,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,rtc,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,summary,template,blockquote,iframe,tfoot"; + SVG_TAGS = "svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,feDistanceLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,text,textPath,title,tspan,unknown,use,view"; + VOID_TAGS = "area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr"; + isHTMLTag = /* @__PURE__ */ makeMap(HTML_TAGS); + isSVGTag = /* @__PURE__ */ makeMap(SVG_TAGS); + isVoidTag = /* @__PURE__ */ makeMap(VOID_TAGS); + escapeRE = /["'&<>]/; + commentStripRE = /^-?>||--!>| { + return val == null ? "" : isObject$4(val) ? JSON.stringify(val, replacer, 2) : String(val); + }; + replacer = (_key, val) => { + if (isMap$1(val)) return { [`Map(${val.size})`]: [...val.entries()].reduce((entries, [key, val$1]) => { + entries[`${key} =>`] = val$1; + return entries; + }, {}) }; + else if (isSet$1(val)) return { [`Set(${val.size})`]: [...val.values()] }; + else if (isObject$4(val) && !isArray$4(val) && !isPlainObject$1(val)) return String(val); + return val; + }; + babelParserDefaultPlugins = [ + "bigInt", + "optionalChaining", + "nullishCoalescingOperator" + ]; + EMPTY_OBJ = Object.freeze({}); + EMPTY_ARR = Object.freeze([]); + NOOP = () => {}; + NO = () => false; + onRE = /^on[^a-z]/; + isOn = (key) => onRE.test(key); + isModelListener = (key) => key.startsWith("onUpdate:"); + extend$3 = Object.assign; + remove$1 = (arr, el) => { + const i$5 = arr.indexOf(el); + if (i$5 > -1) arr.splice(i$5, 1); + }; + hasOwnProperty$5 = Object.prototype.hasOwnProperty; + hasOwn$1 = (val, key) => hasOwnProperty$5.call(val, key); + isArray$4 = Array.isArray; + isMap$1 = (val) => toTypeString(val) === "[object Map]"; + isSet$1 = (val) => toTypeString(val) === "[object Set]"; + isDate = (val) => val instanceof Date; + isFunction$9 = (val) => typeof val === "function"; + isString$4 = (val) => typeof val === "string"; + isSymbol$1 = (val) => typeof val === "symbol"; + isObject$4 = (val) => val !== null && typeof val === "object"; + isPromise = (val) => { + return isObject$4(val) && isFunction$9(val.then) && isFunction$9(val.catch); + }; + objectToString$2 = Object.prototype.toString; + toTypeString = (value) => objectToString$2.call(value); + toRawType = (value) => { + return toTypeString(value).slice(8, -1); + }; + isPlainObject$1 = (val) => toTypeString(val) === "[object Object]"; + isIntegerKey = (key) => isString$4(key) && key !== "NaN" && key[0] !== "-" && "" + parseInt(key, 10) === key; + isReservedProp = /* @__PURE__ */ makeMap( + // the leading comma is intentional so empty string "" is also included + ",key,ref,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted" +); + cacheStringFunction$1 = (fn) => { + const cache$3 = Object.create(null); + return (str$3) => { + const hit = cache$3[str$3]; + return hit || (cache$3[str$3] = fn(str$3)); + }; + }; + camelizeRE$1 = /-(\w)/g; + camelize = cacheStringFunction$1((str$3) => { + return str$3.replace(camelizeRE$1, (_$2, c$2) => c$2 ? c$2.toUpperCase() : ""); + }); + hyphenateRE = /\B([A-Z])/g; + hyphenate = cacheStringFunction$1((str$3) => str$3.replace(hyphenateRE, "-$1").toLowerCase()); + capitalize$1 = cacheStringFunction$1((str$3) => str$3.charAt(0).toUpperCase() + str$3.slice(1)); + toHandlerKey = cacheStringFunction$1((str$3) => str$3 ? `on${capitalize$1(str$3)}` : ``); + hasChanged = (value, oldValue) => value !== oldValue && (value === value || oldValue === oldValue); + invokeArrayFns = (fns, arg) => { + for (let i$5 = 0; i$5 < fns.length; i$5++) fns[i$5](arg); + }; + def = (obj, key, value) => { + Object.defineProperty(obj, key, { + configurable: true, + enumerable: false, + value + }); + }; + toNumber = (val) => { + const n$3 = parseFloat(val); + return isNaN(n$3) ? val : n$3; + }; + getGlobalThis = () => { + return _globalThis || (_globalThis = typeof globalThis !== "undefined" ? globalThis : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : {}); + }; +} }); + +//#endregion +//#region node_modules/@vue/compiler-core/dist/compiler-core.esm-bundler.js +var compiler_core_esm_bundler_exports = {}; +__export(compiler_core_esm_bundler_exports, { + BASE_TRANSITION: () => BASE_TRANSITION, + CAMELIZE: () => CAMELIZE, + CAPITALIZE: () => CAPITALIZE, + CREATE_BLOCK: () => CREATE_BLOCK, + CREATE_COMMENT: () => CREATE_COMMENT, + CREATE_SLOTS: () => CREATE_SLOTS, + CREATE_STATIC: () => CREATE_STATIC, + CREATE_TEXT: () => CREATE_TEXT, + CREATE_VNODE: () => CREATE_VNODE, + FRAGMENT: () => FRAGMENT, + IS_REF: () => IS_REF, + KEEP_ALIVE: () => KEEP_ALIVE, + MERGE_PROPS: () => MERGE_PROPS, + OPEN_BLOCK: () => OPEN_BLOCK, + POP_SCOPE_ID: () => POP_SCOPE_ID, + PUSH_SCOPE_ID: () => PUSH_SCOPE_ID, + RENDER_LIST: () => RENDER_LIST, + RENDER_SLOT: () => RENDER_SLOT, + RESOLVE_COMPONENT: () => RESOLVE_COMPONENT, + RESOLVE_DIRECTIVE: () => RESOLVE_DIRECTIVE, + RESOLVE_DYNAMIC_COMPONENT: () => RESOLVE_DYNAMIC_COMPONENT, + SET_BLOCK_TRACKING: () => SET_BLOCK_TRACKING, + SUSPENSE: () => SUSPENSE, + TELEPORT: () => TELEPORT, + TO_DISPLAY_STRING: () => TO_DISPLAY_STRING, + TO_HANDLERS: () => TO_HANDLERS, + TO_HANDLER_KEY: () => TO_HANDLER_KEY, + UNREF: () => UNREF, + WITH_CTX: () => WITH_CTX, + WITH_DIRECTIVES: () => WITH_DIRECTIVES, + WITH_SCOPE_ID: () => WITH_SCOPE_ID, + advancePositionWithClone: () => advancePositionWithClone, + advancePositionWithMutation: () => advancePositionWithMutation, + assert: () => assert$4, + baseCompile: () => baseCompile, + baseParse: () => baseParse, + buildProps: () => buildProps, + buildSlots: () => buildSlots, + createArrayExpression: () => createArrayExpression, + createAssignmentExpression: () => createAssignmentExpression, + createBlockStatement: () => createBlockStatement, + createCacheExpression: () => createCacheExpression, + createCallExpression: () => createCallExpression, + createCompilerError: () => createCompilerError, + createCompoundExpression: () => createCompoundExpression, + createConditionalExpression: () => createConditionalExpression, + createForLoopParams: () => createForLoopParams, + createFunctionExpression: () => createFunctionExpression, + createIfStatement: () => createIfStatement, + createInterpolation: () => createInterpolation, + createObjectExpression: () => createObjectExpression, + createObjectProperty: () => createObjectProperty, + createReturnStatement: () => createReturnStatement, + createRoot: () => createRoot, + createSequenceExpression: () => createSequenceExpression, + createSimpleExpression: () => createSimpleExpression, + createStructuralDirectiveTransform: () => createStructuralDirectiveTransform, + createTemplateLiteral: () => createTemplateLiteral, + createTransformContext: () => createTransformContext, + createVNodeCall: () => createVNodeCall, + findDir: () => findDir, + findProp: () => findProp, + generate: () => generate$1, + generateCodeFrame: () => generateCodeFrame, + getBaseTransformPreset: () => getBaseTransformPreset, + getInnerRange: () => getInnerRange, + hasDynamicKeyVBind: () => hasDynamicKeyVBind, + hasScopeRef: () => hasScopeRef, + helperNameMap: () => helperNameMap, + injectProp: () => injectProp, + isBindKey: () => isBindKey, + isBuiltInType: () => isBuiltInType, + isCoreComponent: () => isCoreComponent, + isMemberExpression: () => isMemberExpression$7, + isSimpleIdentifier: () => isSimpleIdentifier, + isSlotOutlet: () => isSlotOutlet, + isStaticExp: () => isStaticExp, + isTemplateNode: () => isTemplateNode, + isText: () => isText$2, + isVSlot: () => isVSlot, + locStub: () => locStub, + noopDirectiveTransform: () => noopDirectiveTransform, + processExpression: () => processExpression, + processFor: () => processFor, + processIf: () => processIf, + processSlotOutlet: () => processSlotOutlet, + registerRuntimeHelpers: () => registerRuntimeHelpers, + resolveComponentType: () => resolveComponentType, + toValidAssetId: () => toValidAssetId, + trackSlotScopes: () => trackSlotScopes, + trackVForSlotScopes: () => trackVForSlotScopes, + transform: () => transform, + transformBind: () => transformBind, + transformElement: () => transformElement, + transformExpression: () => transformExpression, + transformModel: () => transformModel, + transformOn: () => transformOn, + traverseNode: () => traverseNode$1 +}); +function defaultOnError(error) { + throw error; +} +function createCompilerError(code$1, loc, messages, additionalMessage) { + const msg = (messages || errorMessages)[code$1] + (additionalMessage || ``); + const error = new SyntaxError(String(msg)); + error.code = code$1; + error.loc = loc; + return error; +} +function registerRuntimeHelpers(helpers) { + Object.getOwnPropertySymbols(helpers).forEach((s$1) => { + helperNameMap[s$1] = helpers[s$1]; + }); +} +function createRoot(children, loc = locStub) { + return { + type: 0, + children, + helpers: [], + components: [], + directives: [], + hoists: [], + imports: [], + cached: 0, + temps: 0, + codegenNode: void 0, + loc + }; +} +function createVNodeCall(context, tag$3, props, children, patchFlag, dynamicProps, directives, isBlock$1 = false, disableTracking = false, loc = locStub) { + if (context) { + if (isBlock$1) { + context.helper(OPEN_BLOCK); + context.helper(CREATE_BLOCK); + } else context.helper(CREATE_VNODE); + if (directives) context.helper(WITH_DIRECTIVES); + } + return { + type: 13, + tag: tag$3, + props, + children, + patchFlag, + dynamicProps, + directives, + isBlock: isBlock$1, + disableTracking, + loc + }; +} +function createArrayExpression(elements, loc = locStub) { + return { + type: 17, + loc, + elements + }; +} +function createObjectExpression(properties, loc = locStub) { + return { + type: 15, + loc, + properties + }; +} +function createObjectProperty(key, value) { + return { + type: 16, + loc: locStub, + key: isString$4(key) ? createSimpleExpression(key, true) : key, + value + }; +} +function createSimpleExpression(content, isStatic$1, loc = locStub, constType = 0) { + return { + type: 4, + loc, + content, + isStatic: isStatic$1, + constType: isStatic$1 ? 3 : constType + }; +} +function createInterpolation(content, loc) { + return { + type: 5, + loc, + content: isString$4(content) ? createSimpleExpression(content, false, loc) : content + }; +} +function createCompoundExpression(children, loc = locStub) { + return { + type: 8, + loc, + children + }; +} +function createCallExpression(callee, args = [], loc = locStub) { + return { + type: 14, + loc, + callee, + arguments: args + }; +} +function createFunctionExpression(params, returns = void 0, newline$3 = false, isSlot = false, loc = locStub) { + return { + type: 18, + params, + returns, + newline: newline$3, + isSlot, + loc + }; +} +function createConditionalExpression(test, consequent, alternate, newline$3 = true) { + return { + type: 19, + test, + consequent, + alternate, + newline: newline$3, + loc: locStub + }; +} +function createCacheExpression(index$1, value, isVNode = false) { + return { + type: 20, + index: index$1, + value, + isVNode, + loc: locStub + }; +} +function createBlockStatement(body) { + return { + type: 21, + body, + loc: locStub + }; +} +function createTemplateLiteral(elements) { + return { + type: 22, + elements, + loc: locStub + }; +} +function createIfStatement(test, consequent, alternate) { + return { + type: 23, + test, + consequent, + alternate, + loc: locStub + }; +} +function createAssignmentExpression(left, right) { + return { + type: 24, + left, + right, + loc: locStub + }; +} +function createSequenceExpression(expressions) { + return { + type: 25, + expressions, + loc: locStub + }; +} +function createReturnStatement(returns) { + return { + type: 26, + returns, + loc: locStub + }; +} +function isCoreComponent(tag$3) { + if (isBuiltInType(tag$3, "Teleport")) return TELEPORT; + else if (isBuiltInType(tag$3, "Suspense")) return SUSPENSE; + else if (isBuiltInType(tag$3, "KeepAlive")) return KEEP_ALIVE; + else if (isBuiltInType(tag$3, "BaseTransition")) return BASE_TRANSITION; +} +function getInnerRange(loc, offset, length) { + const source = loc.source.substr(offset, length); + const newLoc = { + source, + start: advancePositionWithClone(loc.start, loc.source, offset), + end: loc.end + }; + if (length != null) newLoc.end = advancePositionWithClone(loc.start, loc.source, offset + length); + return newLoc; +} +function advancePositionWithClone(pos, source, numberOfCharacters = source.length) { + return advancePositionWithMutation(extend$3({}, pos), source, numberOfCharacters); +} +function advancePositionWithMutation(pos, source, numberOfCharacters = source.length) { + let linesCount = 0; + let lastNewLinePos = -1; + for (let i$5 = 0; i$5 < numberOfCharacters; i$5++) if (source.charCodeAt(i$5) === 10) { + linesCount++; + lastNewLinePos = i$5; + } + pos.offset += numberOfCharacters; + pos.line += linesCount; + pos.column = lastNewLinePos === -1 ? pos.column + numberOfCharacters : numberOfCharacters - lastNewLinePos; + return pos; +} +function assert$4(condition, msg) { + /* istanbul ignore if */ + if (!condition) throw new Error(msg || `unexpected compiler condition`); +} +function findDir(node, name, allowEmpty = false) { + for (let i$5 = 0; i$5 < node.props.length; i$5++) { + const p$1 = node.props[i$5]; + if (p$1.type === 7 && (allowEmpty || p$1.exp) && (isString$4(name) ? p$1.name === name : name.test(p$1.name))) return p$1; + } +} +function findProp(node, name, dynamicOnly = false, allowEmpty = false) { + for (let i$5 = 0; i$5 < node.props.length; i$5++) { + const p$1 = node.props[i$5]; + if (p$1.type === 6) { + if (dynamicOnly) continue; + if (p$1.name === name && (p$1.value || allowEmpty)) return p$1; + } else if (p$1.name === "bind" && (p$1.exp || allowEmpty) && isBindKey(p$1.arg, name)) return p$1; + } +} +function isBindKey(arg, name) { + return !!(arg && isStaticExp(arg) && arg.content === name); +} +function hasDynamicKeyVBind(node) { + return node.props.some((p$1) => p$1.type === 7 && p$1.name === "bind" && (!p$1.arg || p$1.arg.type !== 4 || !p$1.arg.isStatic)); +} +function isText$2(node) { + return node.type === 5 || node.type === 2; +} +function isVSlot(p$1) { + return p$1.type === 7 && p$1.name === "slot"; +} +function isTemplateNode(node) { + return node.type === 1 && node.tagType === 3; +} +function isSlotOutlet(node) { + return node.type === 1 && node.tagType === 2; +} +function injectProp(node, prop, context) { + let propsWithInjection; + const props = node.type === 13 ? node.props : node.arguments[2]; + if (props == null || isString$4(props)) propsWithInjection = createObjectExpression([prop]); + else if (props.type === 14) { + const first$1 = props.arguments[0]; + if (!isString$4(first$1) && first$1.type === 15) first$1.properties.unshift(prop); + else if (props.callee === TO_HANDLERS) propsWithInjection = createCallExpression(context.helper(MERGE_PROPS), [createObjectExpression([prop]), props]); + else props.arguments.unshift(createObjectExpression([prop])); + !propsWithInjection && (propsWithInjection = props); + } else if (props.type === 15) { + let alreadyExists = false; + if (prop.key.type === 4) { + const propKeyName = prop.key.content; + alreadyExists = props.properties.some((p$1) => p$1.key.type === 4 && p$1.key.content === propKeyName); + } + if (!alreadyExists) props.properties.unshift(prop); + propsWithInjection = props; + } else propsWithInjection = createCallExpression(context.helper(MERGE_PROPS), [createObjectExpression([prop]), props]); + if (node.type === 13) node.props = propsWithInjection; + else node.arguments[2] = propsWithInjection; +} +function toValidAssetId(name, type) { + return `_${type}_${name.replace(/[^\w]/g, "_")}`; +} +function hasScopeRef(node, ids) { + if (!node || Object.keys(ids).length === 0) return false; + switch (node.type) { + case 1: + for (let i$5 = 0; i$5 < node.props.length; i$5++) { + const p$1 = node.props[i$5]; + if (p$1.type === 7 && (hasScopeRef(p$1.arg, ids) || hasScopeRef(p$1.exp, ids))) return true; + } + return node.children.some((c$2) => hasScopeRef(c$2, ids)); + case 11: + if (hasScopeRef(node.source, ids)) return true; + return node.children.some((c$2) => hasScopeRef(c$2, ids)); + case 9: return node.branches.some((b$1) => hasScopeRef(b$1, ids)); + case 10: + if (hasScopeRef(node.condition, ids)) return true; + return node.children.some((c$2) => hasScopeRef(c$2, ids)); + case 4: return !node.isStatic && isSimpleIdentifier(node.content) && !!ids[node.content]; + case 8: return node.children.some((c$2) => isObject$4(c$2) && hasScopeRef(c$2, ids)); + case 5: + case 12: return hasScopeRef(node.content, ids); + case 2: + case 3: return false; + default: return false; + } +} +function baseParse(content, options = {}) { + const context = createParserContext(content, options); + const start = getCursor(context); + return createRoot(parseChildren(context, 0, []), getSelection(context, start)); +} +function createParserContext(content, rawOptions) { + const options = extend$3({}, defaultParserOptions); + for (const key in rawOptions) options[key] = rawOptions[key] || defaultParserOptions[key]; + return { + options, + column: 1, + line: 1, + offset: 0, + originalSource: content, + source: content, + inPre: false, + inVPre: false + }; +} +function parseChildren(context, mode, ancestors) { + const parent = last$2(ancestors); + const ns = parent ? parent.ns : 0; + const nodes$1 = []; + while (!isEnd(context, mode, ancestors)) { + const s$1 = context.source; + let node = void 0; + if (mode === 0 || mode === 1) { + if (!context.inVPre && startsWith(s$1, context.options.delimiters[0])) node = parseInterpolation(context, mode); + else if (mode === 0 && s$1[0] === "<") if (s$1.length === 1) emitError(context, 5, 1); + else if (s$1[1] === "!") if (startsWith(s$1, "`"])]); + } + function processIfBranch(branch, context, disableNestedFragments = false) { + const { children } = branch; + const needFragmentWrapper = !disableNestedFragments && (children.length !== 1 || children[0].type !== 1) && !(children.length === 1 && children[0].type === 11); + return processChildrenAsStatement(children, context, needFragmentWrapper); + } + const ssrTransformFor = compilerDom.createStructuralDirectiveTransform("for", compilerDom.processFor); + function ssrProcessFor(node, context, disableNestedFragments = false) { + const needFragmentWrapper = !disableNestedFragments && (node.children.length !== 1 || node.children[0].type !== 1); + const renderLoop = compilerDom.createFunctionExpression(compilerDom.createForLoopParams(node.parseResult)); + renderLoop.body = processChildrenAsStatement(node.children, context, needFragmentWrapper); + if (!disableNestedFragments) context.pushStringPart(``); + context.pushStatement(compilerDom.createCallExpression(context.helper(SSR_RENDER_LIST), [node.source, renderLoop])); + if (!disableNestedFragments) context.pushStringPart(``); + } + const ssrTransformSlotOutlet = (node, context) => { + if (compilerDom.isSlotOutlet(node)) { + const { slotName, slotProps } = compilerDom.processSlotOutlet(node, context); + node.ssrCodegenNode = compilerDom.createCallExpression(context.helper(SSR_RENDER_SLOT), [ + `_ctx.$slots`, + slotName, + slotProps || `{}`, + `null`, + `_push`, + `_parent` + ]); + } + }; + function ssrProcessSlotOutlet(node, context) { + const renderCall = node.ssrCodegenNode; + if (node.children.length) { + const fallbackRenderFn = compilerDom.createFunctionExpression([]); + fallbackRenderFn.body = processChildrenAsStatement(node.children, context); + renderCall.arguments[3] = fallbackRenderFn; + } + context.pushStatement(node.ssrCodegenNode); + } + function createSSRCompilerError(code$1, loc) { + return compilerDom.createCompilerError(code$1, loc, SSRErrorMessages); + } + const SSRErrorMessages = { + [60]: `Custom directive is missing corresponding SSR transform and will be ignored.`, + [61]: `Unsafe attribute name for SSR.`, + [62]: `Missing the 'to' prop on teleport element.`, + [63]: `Invalid AST node during SSR transform.` + }; + function ssrProcessTeleport(node, context) { + const targetProp = compilerDom.findProp(node, "to"); + if (!targetProp) { + context.onError(createSSRCompilerError(62, node.loc)); + return; + } + let target; + if (targetProp.type === 6) target = targetProp.value && compilerDom.createSimpleExpression(targetProp.value.content, true); + else target = targetProp.exp; + if (!target) { + context.onError(createSSRCompilerError(62, targetProp.loc)); + return; + } + const disabledProp = compilerDom.findProp( + node, + "disabled", + false, + true + /* allow empty */ +); + const disabled = disabledProp ? disabledProp.type === 6 ? `true` : disabledProp.exp || `false` : `false`; + const contentRenderFn = compilerDom.createFunctionExpression([`_push`], void 0, true, false, node.loc); + contentRenderFn.body = processChildrenAsStatement(node.children, context); + context.pushStatement(compilerDom.createCallExpression(context.helper(SSR_RENDER_TELEPORT), [ + `_push`, + contentRenderFn, + target, + disabled, + `_parent` + ])); + } + const wipMap = new WeakMap(); + function ssrTransformSuspense(node, context) { + return () => { + if (node.children.length) { + const wipEntry = { + slotsExp: null, + wipSlots: [] + }; + wipMap.set(node, wipEntry); + wipEntry.slotsExp = compilerDom.buildSlots(node, context, (_props, children, loc) => { + const fn = compilerDom.createFunctionExpression([], void 0, true, false, loc); + wipEntry.wipSlots.push({ + fn, + children + }); + return fn; + }).slots; + } + }; + } + function ssrProcessSuspense(node, context) { + const wipEntry = wipMap.get(node); + if (!wipEntry) return; + const { slotsExp, wipSlots } = wipEntry; + for (let i$5 = 0; i$5 < wipSlots.length; i$5++) { + const { fn, children } = wipSlots[i$5]; + fn.body = processChildrenAsStatement(children, context); + } + context.pushStatement(compilerDom.createCallExpression(context.helper(SSR_RENDER_SUSPENSE), [`_push`, slotsExp])); + } + function ssrProcessTransitionGroup(node, context) { + const tag$3 = compilerDom.findProp(node, "tag"); + if (tag$3) if (tag$3.type === 7) { + context.pushStringPart(`<`); + context.pushStringPart(tag$3.exp); + context.pushStringPart(`>`); + processChildren( + node.children, + context, + false, + /** + + * TransitionGroup has the special runtime behavior of flattening and + + * concatenating all children into a single fragment (in order for them to + + * be pathced using the same key map) so we need to account for that here + + * by disabling nested fragment wrappers from being generated. + + */ + true +); + context.pushStringPart(``); + } else { + context.pushStringPart(`<${tag$3.value.content}>`); + processChildren(node.children, context, false, true); + context.pushStringPart(``); + } + else processChildren(node.children, context, true, true); + } + const wipMap$1 = new WeakMap(); + const componentTypeMap = new WeakMap(); + const ssrTransformComponent = (node, context) => { + if (node.type !== 1 || node.tagType !== 1) return; + const component = compilerDom.resolveComponentType( + node, + context, + true + /* ssr */ +); + componentTypeMap.set(node, component); + if (shared$1.isSymbol(component)) { + if (component === compilerDom.SUSPENSE) return ssrTransformSuspense(node, context); + return; + } + const vnodeBranches = []; + const clonedNode = clone$2(node); + return function ssrPostTransformComponent() { + if (clonedNode.children.length) compilerDom.buildSlots(clonedNode, context, (props$1, children) => { + vnodeBranches.push(createVNodeSlotBranch(props$1, children, context)); + return compilerDom.createFunctionExpression(void 0); + }); + const props = node.props.length > 0 ? compilerDom.buildProps(node, context).props || `null` : `null`; + const wipEntries = []; + wipMap$1.set(node, wipEntries); + const buildSSRSlotFn = (props$1, children, loc) => { + const fn = compilerDom.createFunctionExpression([ + props$1 || `_`, + `_push`, + `_parent`, + `_scopeId` + ], void 0, true, true, loc); + wipEntries.push({ + fn, + children, + vnodeBranch: vnodeBranches[wipEntries.length] + }); + return fn; + }; + const slots = node.children.length ? compilerDom.buildSlots(node, context, buildSSRSlotFn).slots : `null`; + if (typeof component !== "string") node.ssrCodegenNode = compilerDom.createCallExpression(context.helper(SSR_RENDER_VNODE), [ + `_push`, + compilerDom.createCallExpression(context.helper(compilerDom.CREATE_VNODE), [ + component, + props, + slots + ]), + `_parent` + ]); + else node.ssrCodegenNode = compilerDom.createCallExpression(context.helper(SSR_RENDER_COMPONENT), [ + component, + props, + slots, + `_parent` + ]); + }; + }; + function ssrProcessComponent(node, context) { + const component = componentTypeMap.get(node); + if (!node.ssrCodegenNode) if (component === compilerDom.TELEPORT) return ssrProcessTeleport(node, context); + else if (component === compilerDom.SUSPENSE) return ssrProcessSuspense(node, context); + else if (component === compilerDom.TRANSITION_GROUP) return ssrProcessTransitionGroup(node, context); + else processChildren(node.children, context); + else { + const wipEntries = wipMap$1.get(node) || []; + for (let i$5 = 0; i$5 < wipEntries.length; i$5++) { + const { fn, children, vnodeBranch } = wipEntries[i$5]; + fn.body = compilerDom.createIfStatement(compilerDom.createSimpleExpression(`_push`, false), processChildrenAsStatement( + children, + context, + false, + true + /* withSlotScopeId */ +), vnodeBranch); + } + if (typeof component === "string") context.pushStatement(compilerDom.createCallExpression(`_push`, [node.ssrCodegenNode])); + else context.pushStatement(node.ssrCodegenNode); + } + } + const rawOptionsMap = new WeakMap(); + const [baseNodeTransforms, baseDirectiveTransforms] = compilerDom.getBaseTransformPreset(true); + const vnodeNodeTransforms = [...baseNodeTransforms, ...compilerDom.DOMNodeTransforms]; + const vnodeDirectiveTransforms = { + ...baseDirectiveTransforms, + ...compilerDom.DOMDirectiveTransforms + }; + function createVNodeSlotBranch(props, children, parentContext) { + const rawOptions = rawOptionsMap.get(parentContext.root); + const subOptions = { + ...rawOptions, + nodeTransforms: [...vnodeNodeTransforms, ...rawOptions.nodeTransforms || []], + directiveTransforms: { + ...vnodeDirectiveTransforms, + ...rawOptions.directiveTransforms || {} + } + }; + const wrapperNode = { + type: 1, + ns: 0, + tag: "template", + tagType: 3, + isSelfClosing: false, + props: [{ + type: 7, + name: "slot", + exp: props, + arg: void 0, + modifiers: [], + loc: compilerDom.locStub + }], + children, + loc: compilerDom.locStub, + codegenNode: void 0 + }; + subTransform(wrapperNode, subOptions, parentContext); + return compilerDom.createReturnStatement(children); + } + function subTransform(node, options, parentContext) { + const childRoot = compilerDom.createRoot([node]); + const childContext = compilerDom.createTransformContext(childRoot, options); + childContext.ssr = false; + childContext.scopes = { ...parentContext.scopes }; + childContext.identifiers = { ...parentContext.identifiers }; + compilerDom.traverseNode(childRoot, childContext); + [ + "helpers", + "components", + "directives" + ].forEach((key) => { + childContext[key].forEach((value) => { + parentContext[key].add(value); + }); + }); + } + function clone$2(v$1) { + if (shared$1.isArray(v$1)) return v$1.map(clone$2); + else if (shared$1.isObject(v$1)) { + const res = {}; + for (const key in v$1) res[key] = clone$2(v$1[key]); + return res; + } else return v$1; + } + const rawChildrenMap = new WeakMap(); + const ssrTransformElement = (node, context) => { + if (node.type !== 1 || node.tagType !== 0) return; + return function ssrPostTransformElement() { + const openTag = [`<${node.tag}`]; + const needTagForRuntime = node.tag === "textarea" || node.tag.indexOf("-") > 0; + const hasDynamicVBind = compilerDom.hasDynamicKeyVBind(node); + if (hasDynamicVBind) { + const { props } = compilerDom.buildProps( + node, + context, + node.props, + true + /* ssr */ +); + if (props) { + const propsExp = compilerDom.createCallExpression(context.helper(SSR_RENDER_ATTRS), [props]); + if (node.tag === "textarea") { + const existingText = node.children[0]; + if (!existingText || existingText.type !== 5) { + const tempId = `_temp${context.temps++}`; + propsExp.arguments = [compilerDom.createAssignmentExpression(compilerDom.createSimpleExpression(tempId, false), props)]; + rawChildrenMap.set(node, compilerDom.createCallExpression(context.helper(SSR_INTERPOLATE), [compilerDom.createConditionalExpression(compilerDom.createSimpleExpression(`"value" in ${tempId}`, false), compilerDom.createSimpleExpression(`${tempId}.value`, false), compilerDom.createSimpleExpression(existingText ? existingText.content : ``, true), false)])); + } + } else if (node.tag === "input") { + const vModel = findVModel(node); + if (vModel) { + const tempId = `_temp${context.temps++}`; + const tempExp = compilerDom.createSimpleExpression(tempId, false); + propsExp.arguments = [compilerDom.createSequenceExpression([compilerDom.createAssignmentExpression(tempExp, props), compilerDom.createCallExpression(context.helper(compilerDom.MERGE_PROPS), [tempExp, compilerDom.createCallExpression(context.helper(SSR_GET_DYNAMIC_MODEL_PROPS), [tempExp, vModel.exp])])])]; + } + } + if (needTagForRuntime) propsExp.arguments.push(`"${node.tag}"`); + openTag.push(propsExp); + } + } + let dynamicClassBinding = void 0; + let staticClassBinding = void 0; + let dynamicStyleBinding = void 0; + for (let i$5 = 0; i$5 < node.props.length; i$5++) { + const prop = node.props[i$5]; + if (node.tag === "input" && isTrueFalseValue(prop)) continue; + if (prop.type === 7) if (prop.name === "html" && prop.exp) rawChildrenMap.set(node, prop.exp); + else if (prop.name === "text" && prop.exp) node.children = [compilerDom.createInterpolation(prop.exp, prop.loc)]; + else if (prop.name === "slot") context.onError(compilerDom.createCompilerError(39, prop.loc)); + else if (isTextareaWithValue(node, prop) && prop.exp) { + if (!hasDynamicVBind) node.children = [compilerDom.createInterpolation(prop.exp, prop.loc)]; + } else { + const directiveTransform = context.directiveTransforms[prop.name]; + if (!directiveTransform) context.onError(createSSRCompilerError(60, prop.loc)); + else if (!hasDynamicVBind) { + const { props, ssrTagParts } = directiveTransform(prop, node, context); + if (ssrTagParts) openTag.push(...ssrTagParts); + for (let j = 0; j < props.length; j++) { + const { key, value } = props[j]; + if (compilerDom.isStaticExp(key)) { + let attrName = key.content; + if (attrName === "key" || attrName === "ref") continue; + if (attrName === "class") openTag.push(` class="`, dynamicClassBinding = compilerDom.createCallExpression(context.helper(SSR_RENDER_CLASS), [value]), `"`); + else if (attrName === "style") if (dynamicStyleBinding) mergeCall(dynamicStyleBinding, value); + else openTag.push(` style="`, dynamicStyleBinding = compilerDom.createCallExpression(context.helper(SSR_RENDER_STYLE), [value]), `"`); + else { + attrName = node.tag.indexOf("-") > 0 ? attrName : shared$1.propsToAttrMap[attrName] || attrName.toLowerCase(); + if (shared$1.isBooleanAttr(attrName)) openTag.push(compilerDom.createConditionalExpression( + value, + compilerDom.createSimpleExpression(" " + attrName, true), + compilerDom.createSimpleExpression("", true), + false + /* no newline */ +)); + else if (shared$1.isSSRSafeAttrName(attrName)) openTag.push(compilerDom.createCallExpression(context.helper(SSR_RENDER_ATTR), [key, value])); + else context.onError(createSSRCompilerError(61, key.loc)); + } + } else { + const args = [key, value]; + if (needTagForRuntime) args.push(`"${node.tag}"`); + openTag.push(compilerDom.createCallExpression(context.helper(SSR_RENDER_DYNAMIC_ATTR), args)); + } + } + } + } + else if (node.tag === "textarea" && prop.name === "value" && prop.value) rawChildrenMap.set(node, shared$1.escapeHtml(prop.value.content)); + else if (!hasDynamicVBind) { + if (prop.name === "key" || prop.name === "ref") continue; + if (prop.name === "class" && prop.value) staticClassBinding = JSON.stringify(prop.value.content); + openTag.push(` ${prop.name}` + (prop.value ? `="${shared$1.escapeHtml(prop.value.content)}"` : ``)); + } + } + if (dynamicClassBinding && staticClassBinding) { + mergeCall(dynamicClassBinding, staticClassBinding); + removeStaticBinding(openTag, "class"); + } + if (context.scopeId) openTag.push(` ${context.scopeId}`); + node.ssrCodegenNode = compilerDom.createTemplateLiteral(openTag); + }; + }; + function isTrueFalseValue(prop) { + if (prop.type === 7) return prop.name === "bind" && prop.arg && compilerDom.isStaticExp(prop.arg) && (prop.arg.content === "true-value" || prop.arg.content === "false-value"); + else return prop.name === "true-value" || prop.name === "false-value"; + } + function isTextareaWithValue(node, prop) { + return !!(node.tag === "textarea" && prop.name === "bind" && compilerDom.isBindKey(prop.arg, "value")); + } + function mergeCall(call$2, arg) { + const existing = call$2.arguments[0]; + if (existing.type === 17) existing.elements.push(arg); + else call$2.arguments[0] = compilerDom.createArrayExpression([existing, arg]); + } + function removeStaticBinding(tag$3, binding) { + const regExp = new RegExp(`^ ${binding}=".+"$`); + const i$5 = tag$3.findIndex((e) => typeof e === "string" && regExp.test(e)); + if (i$5 > -1) tag$3.splice(i$5, 1); + } + function findVModel(node) { + return node.props.find((p$1) => p$1.type === 7 && p$1.name === "model" && p$1.exp); + } + function ssrProcessElement(node, context) { + const isVoidTag$1 = context.options.isVoidTag || shared$1.NO; + const elementsToAdd = node.ssrCodegenNode.elements; + for (let j = 0; j < elementsToAdd.length; j++) context.pushStringPart(elementsToAdd[j]); + if (context.withSlotScopeId) context.pushStringPart(compilerDom.createSimpleExpression(`_scopeId`, false)); + context.pushStringPart(`>`); + const rawChildren = rawChildrenMap.get(node); + if (rawChildren) context.pushStringPart(rawChildren); + else if (node.children.length) processChildren(node.children, context); + if (!isVoidTag$1(node.tag)) context.pushStringPart(``); + } + function ssrCodegenTransform(ast, options) { + const context = createSSRTransformContext(ast, options); + if (options.ssrCssVars) { + const varsExp = compilerDom.processExpression(compilerDom.createSimpleExpression(options.ssrCssVars, false), compilerDom.createTransformContext(compilerDom.createRoot([]), options)); + context.body.push(compilerDom.createCompoundExpression([ + `const _cssVars = { style: `, + varsExp, + `}` + ])); + } + const isFragment$1 = ast.children.length > 1 && ast.children.some((c$2) => !compilerDom.isText(c$2)); + processChildren(ast.children, context, isFragment$1); + ast.codegenNode = compilerDom.createBlockStatement(context.body); + ast.ssrHelpers = Array.from(new Set([...ast.helpers.filter((h$2) => h$2 in ssrHelpers), ...context.helpers])); + ast.helpers = ast.helpers.filter((h$2) => !(h$2 in ssrHelpers)); + } + function createSSRTransformContext(root$6, options, helpers = new Set(), withSlotScopeId = false) { + const body = []; + let currentString = null; + return { + root: root$6, + options, + body, + helpers, + withSlotScopeId, + onError: options.onError || ((e) => { + throw e; + }), + helper(name) { + helpers.add(name); + return name; + }, + pushStringPart(part) { + if (!currentString) { + const currentCall = compilerDom.createCallExpression(`_push`); + body.push(currentCall); + currentString = compilerDom.createTemplateLiteral([]); + currentCall.arguments.push(currentString); + } + const bufferedElements = currentString.elements; + const lastItem = bufferedElements[bufferedElements.length - 1]; + if (shared$1.isString(part) && shared$1.isString(lastItem)) bufferedElements[bufferedElements.length - 1] += part; + else bufferedElements.push(part); + }, + pushStatement(statement$2) { + currentString = null; + body.push(statement$2); + } + }; + } + function createChildContext(parent, withSlotScopeId = parent.withSlotScopeId) { + return createSSRTransformContext(parent.root, parent.options, parent.helpers, withSlotScopeId); + } + function processChildren(children, context, asFragment = false, disableNestedFragments = false) { + if (asFragment) context.pushStringPart(``); + for (let i$5 = 0; i$5 < children.length; i$5++) { + const child = children[i$5]; + switch (child.type) { + case 1: + switch (child.tagType) { + case 0: + ssrProcessElement(child, context); + break; + case 1: + ssrProcessComponent(child, context); + break; + case 2: + ssrProcessSlotOutlet(child, context); + break; + case 3: break; + default: + context.onError(createSSRCompilerError(63, child.loc)); + const exhaustiveCheck$1 = child; + return exhaustiveCheck$1; + } + break; + case 2: + context.pushStringPart(shared$1.escapeHtml(child.content)); + break; + case 3: + context.pushStringPart(``); + break; + case 5: + context.pushStringPart(compilerDom.createCallExpression(context.helper(SSR_INTERPOLATE), [child.content])); + break; + case 9: + ssrProcessIf(child, context, disableNestedFragments); + break; + case 11: + ssrProcessFor(child, context, disableNestedFragments); + break; + case 10: break; + case 12: + case 8: break; + default: + context.onError(createSSRCompilerError(63, child.loc)); + const exhaustiveCheck = child; + return exhaustiveCheck; + } + } + if (asFragment) context.pushStringPart(``); + } + function processChildrenAsStatement(children, parentContext, asFragment = false, withSlotScopeId = parentContext.withSlotScopeId) { + const childContext = createChildContext(parentContext, withSlotScopeId); + processChildren(children, childContext, asFragment); + return compilerDom.createBlockStatement(childContext.body); + } + const ssrTransformModel = (dir, node, context) => { + const model = dir.exp; + function checkDuplicatedValue() { + const value = compilerDom.findProp(node, "value"); + if (value) context.onError(compilerDom.createDOMCompilerError(56, value.loc)); + } + if (node.tagType === 0) { + const res = { props: [] }; + const defaultProps = [compilerDom.createObjectProperty(`value`, model)]; + if (node.tag === "input") { + const type = compilerDom.findProp(node, "type"); + if (type) { + const value = findValueBinding(node); + if (type.type === 7) res.ssrTagParts = [compilerDom.createCallExpression(context.helper(SSR_RENDER_DYNAMIC_MODEL), [ + type.exp, + model, + value + ])]; + else if (type.value) switch (type.value.content) { + case "radio": + res.props = [compilerDom.createObjectProperty(`checked`, compilerDom.createCallExpression(context.helper(SSR_LOOSE_EQUAL), [model, value]))]; + break; + case "checkbox": + const trueValueBinding = compilerDom.findProp(node, "true-value"); + if (trueValueBinding) { + const trueValue = trueValueBinding.type === 6 ? JSON.stringify(trueValueBinding.value.content) : trueValueBinding.exp; + res.props = [compilerDom.createObjectProperty(`checked`, compilerDom.createCallExpression(context.helper(SSR_LOOSE_EQUAL), [model, trueValue]))]; + } else res.props = [compilerDom.createObjectProperty(`checked`, compilerDom.createConditionalExpression(compilerDom.createCallExpression(`Array.isArray`, [model]), compilerDom.createCallExpression(context.helper(SSR_LOOSE_CONTAIN), [model, value]), model))]; + break; + case "file": + context.onError(compilerDom.createDOMCompilerError(55, dir.loc)); + break; + default: + checkDuplicatedValue(); + res.props = defaultProps; + break; + } + } else if (compilerDom.hasDynamicKeyVBind(node)); + else { + checkDuplicatedValue(); + res.props = defaultProps; + } + } else if (node.tag === "textarea") { + checkDuplicatedValue(); + node.children = [compilerDom.createInterpolation(model, model.loc)]; + } else if (node.tag === "select"); + else context.onError(compilerDom.createDOMCompilerError(53, dir.loc)); + return res; + } else return compilerDom.transformModel(dir, node, context); + }; + function findValueBinding(node) { + const valueBinding = compilerDom.findProp(node, "value"); + return valueBinding ? valueBinding.type === 7 ? valueBinding.exp : compilerDom.createSimpleExpression(valueBinding.value.content, true) : compilerDom.createSimpleExpression(`null`, false); + } + const ssrTransformShow = (dir, node, context) => { + if (!dir.exp) context.onError(compilerDom.createDOMCompilerError( + 57 + /* X_V_SHOW_NO_EXPRESSION */ +)); + return { props: [compilerDom.createObjectProperty(`style`, compilerDom.createConditionalExpression( + dir.exp, + compilerDom.createSimpleExpression(`null`, false), + compilerDom.createObjectExpression([compilerDom.createObjectProperty(`display`, compilerDom.createSimpleExpression(`none`, true))]), + false + /* no newline */ +))] }; + }; + const hasSingleChild = (node) => node.children.filter( + (n$3) => n$3.type !== 3 + /* COMMENT */ +).length === 1; + const ssrInjectFallthroughAttrs = (node, context) => { + if (node.type === 0) context.identifiers._attrs = 1; + const parent = context.parent; + if (!parent || parent.type !== 0) return; + if (node.type === 10 && hasSingleChild(node)) injectFallthroughAttrs(node.children[0]); + else if (hasSingleChild(parent)) injectFallthroughAttrs(node); + }; + function injectFallthroughAttrs(node) { + if (node.type === 1 && (node.tagType === 0 || node.tagType === 1) && !compilerDom.findDir(node, "for")) node.props.push({ + type: 7, + name: "bind", + arg: void 0, + exp: compilerDom.createSimpleExpression(`_attrs`, false), + modifiers: [], + loc: compilerDom.locStub + }); + } + const ssrInjectCssVars = (node, context) => { + if (!context.ssrCssVars) return; + if (node.type === 0) context.identifiers._cssVars = 1; + const parent = context.parent; + if (!parent || parent.type !== 0) return; + if (node.type === 10) for (const child of node.children) injectCssVars(child); + else injectCssVars(node); + }; + function injectCssVars(node) { + if (node.type === 1 && (node.tagType === 0 || node.tagType === 1) && !compilerDom.findDir(node, "for")) if (compilerDom.isBuiltInType(node.tag, "Suspense")) for (const child of node.children) if (child.type === 1 && child.tagType === 3) child.children.forEach(injectCssVars); + else injectCssVars(child); + else node.props.push({ + type: 7, + name: "bind", + arg: void 0, + exp: compilerDom.createSimpleExpression(`_cssVars`, false), + modifiers: [], + loc: compilerDom.locStub + }); + } + function compile$1(template$2, options = {}) { + options = { + ...options, + ...compilerDom.parserOptions, + ssr: true, + scopeId: options.mode === "function" ? null : options.scopeId, + prefixIdentifiers: true, + cacheHandlers: false, + hoistStatic: false + }; + const ast = compilerDom.baseParse(template$2, options); + rawOptionsMap.set(ast, options); + compilerDom.transform(ast, { + ...options, + nodeTransforms: [ + ssrTransformIf, + ssrTransformFor, + compilerDom.trackVForSlotScopes, + compilerDom.transformExpression, + ssrTransformSlotOutlet, + ssrInjectFallthroughAttrs, + ssrInjectCssVars, + ssrTransformElement, + ssrTransformComponent, + compilerDom.trackSlotScopes, + compilerDom.transformStyle, + ...options.nodeTransforms || [] + ], + directiveTransforms: { + bind: compilerDom.transformBind, + model: ssrTransformModel, + show: ssrTransformShow, + on: compilerDom.noopDirectiveTransform, + cloak: compilerDom.noopDirectiveTransform, + once: compilerDom.noopDirectiveTransform, + ...options.directiveTransforms || {} + } + }); + ssrCodegenTransform(ast, options); + return compilerDom.generate(ast, options); + } + exports.compile = compile$1; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/util/unesc.js +var require_unesc$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/util/unesc.js"(exports, module) { + exports.__esModule = true; + exports["default"] = unesc$2; + /** + * + * @param {string} str + * @returns {[string, number]|undefined} + */ + function gobbleHex$2(str$3) { + var lower = str$3.toLowerCase(); + var hex$3 = ""; + var spaceTerminated = false; + for (var i$5 = 0; i$5 < 6 && lower[i$5] !== void 0; i$5++) { + var code$1 = lower.charCodeAt(i$5); + var valid = code$1 >= 97 && code$1 <= 102 || code$1 >= 48 && code$1 <= 57; + spaceTerminated = code$1 === 32; + if (!valid) break; + hex$3 += lower[i$5]; + } + if (hex$3.length === 0) return void 0; + var codePoint = parseInt(hex$3, 16); + var isSurrogate = codePoint >= 55296 && codePoint <= 57343; + if (isSurrogate || codePoint === 0 || codePoint > 1114111) return ["�", hex$3.length + (spaceTerminated ? 1 : 0)]; + return [String.fromCodePoint(codePoint), hex$3.length + (spaceTerminated ? 1 : 0)]; + } + var CONTAINS_ESCAPE$2 = /\\/; + function unesc$2(str$3) { + var needToProcess = CONTAINS_ESCAPE$2.test(str$3); + if (!needToProcess) return str$3; + var ret = ""; + for (var i$5 = 0; i$5 < str$3.length; i$5++) { + if (str$3[i$5] === "\\") { + var gobbled = gobbleHex$2(str$3.slice(i$5 + 1, i$5 + 7)); + if (gobbled !== void 0) { + ret += gobbled[0]; + i$5 += gobbled[1]; + continue; + } + if (str$3[i$5 + 1] === "\\") { + ret += "\\"; + i$5++; + continue; + } + if (str$3.length === i$5 + 1) ret += str$3[i$5]; + continue; + } + ret += str$3[i$5]; + } + return ret; + } + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/util/getProp.js +var require_getProp$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/util/getProp.js"(exports, module) { + exports.__esModule = true; + exports["default"] = getProp$2; + function getProp$2(obj) { + for (var _len = arguments.length, props = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) props[_key - 1] = arguments[_key]; + while (props.length > 0) { + var prop = props.shift(); + if (!obj[prop]) return void 0; + obj = obj[prop]; + } + return obj; + } + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/util/ensureObject.js +var require_ensureObject$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/util/ensureObject.js"(exports, module) { + exports.__esModule = true; + exports["default"] = ensureObject$2; + function ensureObject$2(obj) { + for (var _len = arguments.length, props = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) props[_key - 1] = arguments[_key]; + while (props.length > 0) { + var prop = props.shift(); + if (!obj[prop]) obj[prop] = {}; + obj = obj[prop]; + } + } + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/util/stripComments.js +var require_stripComments$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/util/stripComments.js"(exports, module) { + exports.__esModule = true; + exports["default"] = stripComments$2; + function stripComments$2(str$3) { + var s$1 = ""; + var commentStart = str$3.indexOf("/*"); + var lastEnd = 0; + while (commentStart >= 0) { + s$1 = s$1 + str$3.slice(lastEnd, commentStart); + var commentEnd = str$3.indexOf("*/", commentStart + 2); + if (commentEnd < 0) return s$1; + lastEnd = commentEnd + 2; + commentStart = str$3.indexOf("/*", lastEnd); + } + s$1 = s$1 + str$3.slice(lastEnd); + return s$1; + } + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/util/index.js +var require_util$3 = __commonJS({ "node_modules/postcss-selector-parser/dist/util/index.js"(exports) { + exports.__esModule = true; + exports.unesc = exports.stripComments = exports.getProp = exports.ensureObject = void 0; + var _unesc$5 = _interopRequireDefault$78(require_unesc$2()); + exports.unesc = _unesc$5["default"]; + var _getProp$2 = _interopRequireDefault$78(require_getProp$2()); + exports.getProp = _getProp$2["default"]; + var _ensureObject$2 = _interopRequireDefault$78(require_ensureObject$2()); + exports.ensureObject = _ensureObject$2["default"]; + var _stripComments$2 = _interopRequireDefault$78(require_stripComments$2()); + exports.stripComments = _stripComments$2["default"]; + function _interopRequireDefault$78(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/node.js +var require_node$5 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/node.js"(exports, module) { + exports.__esModule = true; + exports["default"] = void 0; + var _util$13 = require_util$3(); + function _defineProperties$20(target, props) { + for (var i$5 = 0; i$5 < props.length; i$5++) { + var descriptor = props[i$5]; + descriptor.enumerable = descriptor.enumerable || false; + descriptor.configurable = true; + if ("value" in descriptor) descriptor.writable = true; + Object.defineProperty(target, descriptor.key, descriptor); + } + } + function _createClass$20(Constructor, protoProps, staticProps) { + if (protoProps) _defineProperties$20(Constructor.prototype, protoProps); + if (staticProps) _defineProperties$20(Constructor, staticProps); + Object.defineProperty(Constructor, "prototype", { writable: false }); + return Constructor; + } + var cloneNode$11 = function cloneNode$13(obj, parent) { + if (typeof obj !== "object" || obj === null) return obj; + var cloned = new obj.constructor(); + for (var i$5 in obj) { + if (!obj.hasOwnProperty(i$5)) continue; + var value = obj[i$5]; + var type = typeof value; + if (i$5 === "parent" && type === "object") { + if (parent) cloned[i$5] = parent; + } else if (value instanceof Array) cloned[i$5] = value.map(function(j) { + return cloneNode$13(j, cloned); + }); + else cloned[i$5] = cloneNode$13(value, cloned); + } + return cloned; + }; + var Node$6 = /* @__PURE__ */ function() { + function Node$20(opts) { + if (opts === void 0) opts = {}; + Object.assign(this, opts); + this.spaces = this.spaces || {}; + this.spaces.before = this.spaces.before || ""; + this.spaces.after = this.spaces.after || ""; + } + var _proto = Node$20.prototype; + _proto.remove = function remove$4() { + if (this.parent) this.parent.removeChild(this); + this.parent = void 0; + return this; + }; + _proto.replaceWith = function replaceWith$1() { + if (this.parent) { + for (var index$1 in arguments) this.parent.insertBefore(this, arguments[index$1]); + this.remove(); + } + return this; + }; + _proto.next = function next() { + return this.parent.at(this.parent.index(this) + 1); + }; + _proto.prev = function prev() { + return this.parent.at(this.parent.index(this) - 1); + }; + _proto.clone = function clone$5(overrides) { + if (overrides === void 0) overrides = {}; + var cloned = cloneNode$11(this); + for (var name in overrides) cloned[name] = overrides[name]; + return cloned; + }; + _proto.appendToPropertyAndEscape = function appendToPropertyAndEscape(name, value, valueEscaped) { + if (!this.raws) this.raws = {}; + var originalValue = this[name]; + var originalEscaped = this.raws[name]; + this[name] = originalValue + value; + if (originalEscaped || valueEscaped !== value) this.raws[name] = (originalEscaped || originalValue) + valueEscaped; + else delete this.raws[name]; + }; + _proto.setPropertyAndEscape = function setPropertyAndEscape(name, value, valueEscaped) { + if (!this.raws) this.raws = {}; + this[name] = value; + this.raws[name] = valueEscaped; + }; + _proto.setPropertyWithoutEscape = function setPropertyWithoutEscape(name, value) { + this[name] = value; + if (this.raws) delete this.raws[name]; + }; + _proto.isAtPosition = function isAtPosition(line, column) { + if (this.source && this.source.start && this.source.end) { + if (this.source.start.line > line) return false; + if (this.source.end.line < line) return false; + if (this.source.start.line === line && this.source.start.column > column) return false; + if (this.source.end.line === line && this.source.end.column < column) return false; + return true; + } + return void 0; + }; + _proto.stringifyProperty = function stringifyProperty(name) { + return this.raws && this.raws[name] || this[name]; + }; + _proto.valueToString = function valueToString() { + return String(this.stringifyProperty("value")); + }; + _proto.toString = function toString$6() { + return [ + this.rawSpaceBefore, + this.valueToString(), + this.rawSpaceAfter + ].join(""); + }; + _createClass$20(Node$20, [{ + key: "rawSpaceBefore", + get: function get$3() { + var rawSpace = this.raws && this.raws.spaces && this.raws.spaces.before; + if (rawSpace === void 0) rawSpace = this.spaces && this.spaces.before; + return rawSpace || ""; + }, + set: function set(raw) { + (0, _util$13.ensureObject)(this, "raws", "spaces"); + this.raws.spaces.before = raw; + } + }, { + key: "rawSpaceAfter", + get: function get$3() { + var rawSpace = this.raws && this.raws.spaces && this.raws.spaces.after; + if (rawSpace === void 0) rawSpace = this.spaces.after; + return rawSpace || ""; + }, + set: function set(raw) { + (0, _util$13.ensureObject)(this, "raws", "spaces"); + this.raws.spaces.after = raw; + } + }]); + return Node$20; + }(); + exports["default"] = Node$6; + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/types.js +var require_types$3 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/types.js"(exports) { + exports.__esModule = true; + exports.UNIVERSAL = exports.TAG = exports.STRING = exports.SELECTOR = exports.ROOT = exports.PSEUDO = exports.NESTING = exports.ID = exports.COMMENT = exports.COMBINATOR = exports.CLASS = exports.ATTRIBUTE = void 0; + var TAG$2 = "tag"; + exports.TAG = TAG$2; + var STRING$2 = "string"; + exports.STRING = STRING$2; + var SELECTOR$2 = "selector"; + exports.SELECTOR = SELECTOR$2; + var ROOT$2 = "root"; + exports.ROOT = ROOT$2; + var PSEUDO$2 = "pseudo"; + exports.PSEUDO = PSEUDO$2; + var NESTING$2 = "nesting"; + exports.NESTING = NESTING$2; + var ID$5 = "id"; + exports.ID = ID$5; + var COMMENT$2 = "comment"; + exports.COMMENT = COMMENT$2; + var COMBINATOR$2 = "combinator"; + exports.COMBINATOR = COMBINATOR$2; + var CLASS$2 = "class"; + exports.CLASS = CLASS$2; + var ATTRIBUTE$2 = "attribute"; + exports.ATTRIBUTE = ATTRIBUTE$2; + var UNIVERSAL$2 = "universal"; + exports.UNIVERSAL = UNIVERSAL$2; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/container.js +var require_container$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/container.js"(exports, module) { + exports.__esModule = true; + exports["default"] = void 0; + var _node$23 = _interopRequireDefault$77(require_node$5()); + var types$6 = _interopRequireWildcard$14(require_types$3()); + function _getRequireWildcardCache$11(nodeInterop) { + if (typeof WeakMap !== "function") return null; + var cacheBabelInterop = new WeakMap(); + var cacheNodeInterop = new WeakMap(); + return (_getRequireWildcardCache$11 = function _getRequireWildcardCache$12(nodeInterop$1) { + return nodeInterop$1 ? cacheNodeInterop : cacheBabelInterop; + })(nodeInterop); + } + function _interopRequireWildcard$14(obj, nodeInterop) { + if (!nodeInterop && obj && obj.__esModule) return obj; + if (obj === null || typeof obj !== "object" && typeof obj !== "function") return { "default": obj }; + var cache$3 = _getRequireWildcardCache$11(nodeInterop); + if (cache$3 && cache$3.has(obj)) return cache$3.get(obj); + var newObj = {}; + var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; + for (var key in obj) if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { + var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; + if (desc && (desc.get || desc.set)) Object.defineProperty(newObj, key, desc); + else newObj[key] = obj[key]; + } + newObj["default"] = obj; + if (cache$3) cache$3.set(obj, newObj); + return newObj; + } + function _interopRequireDefault$77(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + function _createForOfIteratorHelperLoose$2(o, allowArrayLike) { + var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; + if (it) return (it = it.call(o)).next.bind(it); + if (Array.isArray(o) || (it = _unsupportedIterableToArray$2(o)) || allowArrayLike && o && typeof o.length === "number") { + if (it) o = it; + var i$5 = 0; + return function() { + if (i$5 >= o.length) return { done: true }; + return { + done: false, + value: o[i$5++] + }; + }; + } + throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); + } + function _unsupportedIterableToArray$2(o, minLen) { + if (!o) return; + if (typeof o === "string") return _arrayLikeToArray$2(o, minLen); + var n$3 = Object.prototype.toString.call(o).slice(8, -1); + if (n$3 === "Object" && o.constructor) n$3 = o.constructor.name; + if (n$3 === "Map" || n$3 === "Set") return Array.from(o); + if (n$3 === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n$3)) return _arrayLikeToArray$2(o, minLen); + } + function _arrayLikeToArray$2(arr, len) { + if (len == null || len > arr.length) len = arr.length; + for (var i$5 = 0, arr2 = new Array(len); i$5 < len; i$5++) arr2[i$5] = arr[i$5]; + return arr2; + } + function _defineProperties$19(target, props) { + for (var i$5 = 0; i$5 < props.length; i$5++) { + var descriptor = props[i$5]; + descriptor.enumerable = descriptor.enumerable || false; + descriptor.configurable = true; + if ("value" in descriptor) descriptor.writable = true; + Object.defineProperty(target, descriptor.key, descriptor); + } + } + function _createClass$19(Constructor, protoProps, staticProps) { + if (protoProps) _defineProperties$19(Constructor.prototype, protoProps); + if (staticProps) _defineProperties$19(Constructor, staticProps); + Object.defineProperty(Constructor, "prototype", { writable: false }); + return Constructor; + } + function _inheritsLoose$41(subClass, superClass) { + subClass.prototype = Object.create(superClass.prototype); + subClass.prototype.constructor = subClass; + _setPrototypeOf$41(subClass, superClass); + } + function _setPrototypeOf$41(o, p$1) { + _setPrototypeOf$41 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf$42(o$1, p$2) { + o$1.__proto__ = p$2; + return o$1; + }; + return _setPrototypeOf$41(o, p$1); + } + var Container$2 = /* @__PURE__ */ function(_Node) { + _inheritsLoose$41(Container$16, _Node); + function Container$16(opts) { + var _this; + _this = _Node.call(this, opts) || this; + if (!_this.nodes) _this.nodes = []; + return _this; + } + var _proto = Container$16.prototype; + _proto.append = function append$1(selector$3) { + selector$3.parent = this; + this.nodes.push(selector$3); + return this; + }; + _proto.prepend = function prepend$1(selector$3) { + selector$3.parent = this; + this.nodes.unshift(selector$3); + return this; + }; + _proto.at = function at$3(index$1) { + return this.nodes[index$1]; + }; + _proto.index = function index$1(child) { + if (typeof child === "number") return child; + return this.nodes.indexOf(child); + }; + _proto.removeChild = function removeChild(child) { + child = this.index(child); + this.at(child).parent = void 0; + this.nodes.splice(child, 1); + var index$1; + for (var id$4 in this.indexes) { + index$1 = this.indexes[id$4]; + if (index$1 >= child) this.indexes[id$4] = index$1 - 1; + } + return this; + }; + _proto.removeAll = function removeAll() { + for (var _iterator = _createForOfIteratorHelperLoose$2(this.nodes), _step; !(_step = _iterator()).done;) { + var node = _step.value; + node.parent = void 0; + } + this.nodes = []; + return this; + }; + _proto.empty = function empty() { + return this.removeAll(); + }; + _proto.insertAfter = function insertAfter$1(oldNode, newNode) { + newNode.parent = this; + var oldIndex = this.index(oldNode); + this.nodes.splice(oldIndex + 1, 0, newNode); + newNode.parent = this; + var index$1; + for (var id$4 in this.indexes) { + index$1 = this.indexes[id$4]; + if (oldIndex <= index$1) this.indexes[id$4] = index$1 + 1; + } + return this; + }; + _proto.insertBefore = function insertBefore$1(oldNode, newNode) { + newNode.parent = this; + var oldIndex = this.index(oldNode); + this.nodes.splice(oldIndex, 0, newNode); + newNode.parent = this; + var index$1; + for (var id$4 in this.indexes) { + index$1 = this.indexes[id$4]; + if (index$1 <= oldIndex) this.indexes[id$4] = index$1 + 1; + } + return this; + }; + _proto._findChildAtPosition = function _findChildAtPosition(line, col) { + var found = void 0; + this.each(function(node) { + if (node.atPosition) { + var foundChild = node.atPosition(line, col); + if (foundChild) { + found = foundChild; + return false; + } + } else if (node.isAtPosition(line, col)) { + found = node; + return false; + } + }); + return found; + }; + _proto.atPosition = function atPosition(line, col) { + if (this.isAtPosition(line, col)) return this._findChildAtPosition(line, col) || this; + else return void 0; + }; + _proto._inferEndPosition = function _inferEndPosition() { + if (this.last && this.last.source && this.last.source.end) { + this.source = this.source || {}; + this.source.end = this.source.end || {}; + Object.assign(this.source.end, this.last.source.end); + } + }; + _proto.each = function each$1(callback) { + if (!this.lastEach) this.lastEach = 0; + if (!this.indexes) this.indexes = {}; + this.lastEach++; + var id$4 = this.lastEach; + this.indexes[id$4] = 0; + if (!this.length) return void 0; + var index$1, result$1; + while (this.indexes[id$4] < this.length) { + index$1 = this.indexes[id$4]; + result$1 = callback(this.at(index$1), index$1); + if (result$1 === false) break; + this.indexes[id$4] += 1; + } + delete this.indexes[id$4]; + if (result$1 === false) return false; + }; + _proto.walk = function walk$2(callback) { + return this.each(function(node, i$5) { + var result$1 = callback(node, i$5); + if (result$1 !== false && node.length) result$1 = node.walk(callback); + if (result$1 === false) return false; + }); + }; + _proto.walkAttributes = function walkAttributes(callback) { + var _this2 = this; + return this.walk(function(selector$3) { + if (selector$3.type === types$6.ATTRIBUTE) return callback.call(_this2, selector$3); + }); + }; + _proto.walkClasses = function walkClasses(callback) { + var _this3 = this; + return this.walk(function(selector$3) { + if (selector$3.type === types$6.CLASS) return callback.call(_this3, selector$3); + }); + }; + _proto.walkCombinators = function walkCombinators(callback) { + var _this4 = this; + return this.walk(function(selector$3) { + if (selector$3.type === types$6.COMBINATOR) return callback.call(_this4, selector$3); + }); + }; + _proto.walkComments = function walkComments(callback) { + var _this5 = this; + return this.walk(function(selector$3) { + if (selector$3.type === types$6.COMMENT) return callback.call(_this5, selector$3); + }); + }; + _proto.walkIds = function walkIds(callback) { + var _this6 = this; + return this.walk(function(selector$3) { + if (selector$3.type === types$6.ID) return callback.call(_this6, selector$3); + }); + }; + _proto.walkNesting = function walkNesting(callback) { + var _this7 = this; + return this.walk(function(selector$3) { + if (selector$3.type === types$6.NESTING) return callback.call(_this7, selector$3); + }); + }; + _proto.walkPseudos = function walkPseudos(callback) { + var _this8 = this; + return this.walk(function(selector$3) { + if (selector$3.type === types$6.PSEUDO) return callback.call(_this8, selector$3); + }); + }; + _proto.walkTags = function walkTags(callback) { + var _this9 = this; + return this.walk(function(selector$3) { + if (selector$3.type === types$6.TAG) return callback.call(_this9, selector$3); + }); + }; + _proto.walkUniversals = function walkUniversals(callback) { + var _this10 = this; + return this.walk(function(selector$3) { + if (selector$3.type === types$6.UNIVERSAL) return callback.call(_this10, selector$3); + }); + }; + _proto.split = function split(callback) { + var _this11 = this; + var current = []; + return this.reduce(function(memo, node, index$1) { + var split$1 = callback.call(_this11, node); + current.push(node); + if (split$1) { + memo.push(current); + current = []; + } else if (index$1 === _this11.length - 1) memo.push(current); + return memo; + }, []); + }; + _proto.map = function map$1(callback) { + return this.nodes.map(callback); + }; + _proto.reduce = function reduce(callback, memo) { + return this.nodes.reduce(callback, memo); + }; + _proto.every = function every$1(callback) { + return this.nodes.every(callback); + }; + _proto.some = function some$1(callback) { + return this.nodes.some(callback); + }; + _proto.filter = function filter$3(callback) { + return this.nodes.filter(callback); + }; + _proto.sort = function sort(callback) { + return this.nodes.sort(callback); + }; + _proto.toString = function toString$6() { + return this.map(String).join(""); + }; + _createClass$19(Container$16, [ + { + key: "first", + get: function get$3() { + return this.at(0); + } + }, + { + key: "last", + get: function get$3() { + return this.at(this.length - 1); + } + }, + { + key: "length", + get: function get$3() { + return this.nodes.length; + } + } + ]); + return Container$16; + }(_node$23["default"]); + exports["default"] = Container$2; + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/root.js +var require_root$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/root.js"(exports, module) { + exports.__esModule = true; + exports["default"] = void 0; + var _container$8 = _interopRequireDefault$76(require_container$2()); + var _types$42 = require_types$3(); + function _interopRequireDefault$76(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + function _defineProperties$18(target, props) { + for (var i$5 = 0; i$5 < props.length; i$5++) { + var descriptor = props[i$5]; + descriptor.enumerable = descriptor.enumerable || false; + descriptor.configurable = true; + if ("value" in descriptor) descriptor.writable = true; + Object.defineProperty(target, descriptor.key, descriptor); + } + } + function _createClass$18(Constructor, protoProps, staticProps) { + if (protoProps) _defineProperties$18(Constructor.prototype, protoProps); + if (staticProps) _defineProperties$18(Constructor, staticProps); + Object.defineProperty(Constructor, "prototype", { writable: false }); + return Constructor; + } + function _inheritsLoose$40(subClass, superClass) { + subClass.prototype = Object.create(superClass.prototype); + subClass.prototype.constructor = subClass; + _setPrototypeOf$40(subClass, superClass); + } + function _setPrototypeOf$40(o, p$1) { + _setPrototypeOf$40 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf$42(o$1, p$2) { + o$1.__proto__ = p$2; + return o$1; + }; + return _setPrototypeOf$40(o, p$1); + } + var Root$2 = /* @__PURE__ */ function(_Container) { + _inheritsLoose$40(Root$11, _Container); + function Root$11(opts) { + var _this; + _this = _Container.call(this, opts) || this; + _this.type = _types$42.ROOT; + return _this; + } + var _proto = Root$11.prototype; + _proto.toString = function toString$6() { + var str$3 = this.reduce(function(memo, selector$3) { + memo.push(String(selector$3)); + return memo; + }, []).join(","); + return this.trailingComma ? str$3 + "," : str$3; + }; + _proto.error = function error(message, options) { + if (this._error) return this._error(message, options); + else return new Error(message); + }; + _createClass$18(Root$11, [{ + key: "errorGenerator", + set: function set(handler) { + this._error = handler; + } + }]); + return Root$11; + }(_container$8["default"]); + exports["default"] = Root$2; + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/selector.js +var require_selector$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/selector.js"(exports, module) { + exports.__esModule = true; + exports["default"] = void 0; + var _container$7 = _interopRequireDefault$75(require_container$2()); + var _types$41 = require_types$3(); + function _interopRequireDefault$75(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + function _inheritsLoose$39(subClass, superClass) { + subClass.prototype = Object.create(superClass.prototype); + subClass.prototype.constructor = subClass; + _setPrototypeOf$39(subClass, superClass); + } + function _setPrototypeOf$39(o, p$1) { + _setPrototypeOf$39 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf$42(o$1, p$2) { + o$1.__proto__ = p$2; + return o$1; + }; + return _setPrototypeOf$39(o, p$1); + } + var Selector$2 = /* @__PURE__ */ function(_Container) { + _inheritsLoose$39(Selector$3, _Container); + function Selector$3(opts) { + var _this; + _this = _Container.call(this, opts) || this; + _this.type = _types$41.SELECTOR; + return _this; + } + return Selector$3; + }(_container$7["default"]); + exports["default"] = Selector$2; + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/cssesc/cssesc.js +var require_cssesc = __commonJS({ "node_modules/cssesc/cssesc.js"(exports, module) { + var object$2 = {}; + var hasOwnProperty$4 = object$2.hasOwnProperty; + var merge$4 = function merge$5(options, defaults$2) { + if (!options) return defaults$2; + var result$1 = {}; + for (var key in defaults$2) result$1[key] = hasOwnProperty$4.call(options, key) ? options[key] : defaults$2[key]; + return result$1; + }; + var regexAnySingleEscape = /[ -,\.\/:-@\[-\^`\{-~]/; + var regexSingleEscape$1 = /[ -,\.\/:-@\[\]\^`\{-~]/; + var regexExcessiveSpaces = /(^|\\+)?(\\[A-F0-9]{1,6})\x20(?![a-fA-F0-9\x20])/g; + var cssesc = function cssesc$1(string$3, options) { + options = merge$4(options, cssesc$1.options); + if (options.quotes != "single" && options.quotes != "double") options.quotes = "single"; + var quote = options.quotes == "double" ? "\"" : "'"; + var isIdentifier$15 = options.isIdentifier; + var firstChar = string$3.charAt(0); + var output = ""; + var counter = 0; + var length = string$3.length; + while (counter < length) { + var character = string$3.charAt(counter++); + var codePoint = character.charCodeAt(); + var value = void 0; + if (codePoint < 32 || codePoint > 126) { + if (codePoint >= 55296 && codePoint <= 56319 && counter < length) { + var extra = string$3.charCodeAt(counter++); + if ((extra & 64512) == 56320) codePoint = ((codePoint & 1023) << 10) + (extra & 1023) + 65536; + else counter--; + } + value = "\\" + codePoint.toString(16).toUpperCase() + " "; + } else if (options.escapeEverything) if (regexAnySingleEscape.test(character)) value = "\\" + character; + else value = "\\" + codePoint.toString(16).toUpperCase() + " "; + else if (/[\t\n\f\r\x0B]/.test(character)) value = "\\" + codePoint.toString(16).toUpperCase() + " "; + else if (character == "\\" || !isIdentifier$15 && (character == "\"" && quote == character || character == "'" && quote == character) || isIdentifier$15 && regexSingleEscape$1.test(character)) value = "\\" + character; + else value = character; + output += value; + } + if (isIdentifier$15) { + if (/^-[-\d]/.test(output)) output = "\\-" + output.slice(1); + else if (/\d/.test(firstChar)) output = "\\3" + firstChar + " " + output.slice(1); + } + output = output.replace(regexExcessiveSpaces, function($0, $1, $2) { + if ($1 && $1.length % 2) return $0; + return ($1 || "") + $2; + }); + if (!isIdentifier$15 && options.wrap) return quote + output + quote; + return output; + }; + cssesc.options = { + "escapeEverything": false, + "isIdentifier": false, + "quotes": "single", + "wrap": false + }; + cssesc.version = "3.0.0"; + module.exports = cssesc; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/className.js +var require_className$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/className.js"(exports, module) { + exports.__esModule = true; + exports["default"] = void 0; + var _cssesc$8 = _interopRequireDefault$74(require_cssesc()); + var _util$12 = require_util$3(); + var _node$22 = _interopRequireDefault$74(require_node$5()); + var _types$40 = require_types$3(); + function _interopRequireDefault$74(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + function _defineProperties$17(target, props) { + for (var i$5 = 0; i$5 < props.length; i$5++) { + var descriptor = props[i$5]; + descriptor.enumerable = descriptor.enumerable || false; + descriptor.configurable = true; + if ("value" in descriptor) descriptor.writable = true; + Object.defineProperty(target, descriptor.key, descriptor); + } + } + function _createClass$17(Constructor, protoProps, staticProps) { + if (protoProps) _defineProperties$17(Constructor.prototype, protoProps); + if (staticProps) _defineProperties$17(Constructor, staticProps); + Object.defineProperty(Constructor, "prototype", { writable: false }); + return Constructor; + } + function _inheritsLoose$38(subClass, superClass) { + subClass.prototype = Object.create(superClass.prototype); + subClass.prototype.constructor = subClass; + _setPrototypeOf$38(subClass, superClass); + } + function _setPrototypeOf$38(o, p$1) { + _setPrototypeOf$38 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf$42(o$1, p$2) { + o$1.__proto__ = p$2; + return o$1; + }; + return _setPrototypeOf$38(o, p$1); + } + var ClassName$2 = /* @__PURE__ */ function(_Node) { + _inheritsLoose$38(ClassName$3, _Node); + function ClassName$3(opts) { + var _this; + _this = _Node.call(this, opts) || this; + _this.type = _types$40.CLASS; + _this._constructed = true; + return _this; + } + var _proto = ClassName$3.prototype; + _proto.valueToString = function valueToString() { + return "." + _Node.prototype.valueToString.call(this); + }; + _createClass$17(ClassName$3, [{ + key: "value", + get: function get$3() { + return this._value; + }, + set: function set(v$1) { + if (this._constructed) { + var escaped = (0, _cssesc$8["default"])(v$1, { isIdentifier: true }); + if (escaped !== v$1) { + (0, _util$12.ensureObject)(this, "raws"); + this.raws.value = escaped; + } else if (this.raws) delete this.raws.value; + } + this._value = v$1; + } + }]); + return ClassName$3; + }(_node$22["default"]); + exports["default"] = ClassName$2; + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/comment.js +var require_comment$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/comment.js"(exports, module) { + exports.__esModule = true; + exports["default"] = void 0; + var _node$21 = _interopRequireDefault$73(require_node$5()); + var _types$39 = require_types$3(); + function _interopRequireDefault$73(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + function _inheritsLoose$37(subClass, superClass) { + subClass.prototype = Object.create(superClass.prototype); + subClass.prototype.constructor = subClass; + _setPrototypeOf$37(subClass, superClass); + } + function _setPrototypeOf$37(o, p$1) { + _setPrototypeOf$37 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf$42(o$1, p$2) { + o$1.__proto__ = p$2; + return o$1; + }; + return _setPrototypeOf$37(o, p$1); + } + var Comment$4 = /* @__PURE__ */ function(_Node) { + _inheritsLoose$37(Comment$13, _Node); + function Comment$13(opts) { + var _this; + _this = _Node.call(this, opts) || this; + _this.type = _types$39.COMMENT; + return _this; + } + return Comment$13; + }(_node$21["default"]); + exports["default"] = Comment$4; + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/id.js +var require_id$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/id.js"(exports, module) { + exports.__esModule = true; + exports["default"] = void 0; + var _node$20 = _interopRequireDefault$72(require_node$5()); + var _types$38 = require_types$3(); + function _interopRequireDefault$72(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + function _inheritsLoose$36(subClass, superClass) { + subClass.prototype = Object.create(superClass.prototype); + subClass.prototype.constructor = subClass; + _setPrototypeOf$36(subClass, superClass); + } + function _setPrototypeOf$36(o, p$1) { + _setPrototypeOf$36 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf$42(o$1, p$2) { + o$1.__proto__ = p$2; + return o$1; + }; + return _setPrototypeOf$36(o, p$1); + } + var ID$4 = /* @__PURE__ */ function(_Node) { + _inheritsLoose$36(ID$6, _Node); + function ID$6(opts) { + var _this; + _this = _Node.call(this, opts) || this; + _this.type = _types$38.ID; + return _this; + } + var _proto = ID$6.prototype; + _proto.valueToString = function valueToString() { + return "#" + _Node.prototype.valueToString.call(this); + }; + return ID$6; + }(_node$20["default"]); + exports["default"] = ID$4; + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/namespace.js +var require_namespace$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/namespace.js"(exports, module) { + exports.__esModule = true; + exports["default"] = void 0; + var _cssesc$7 = _interopRequireDefault$71(require_cssesc()); + var _util$11 = require_util$3(); + var _node$19 = _interopRequireDefault$71(require_node$5()); + function _interopRequireDefault$71(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + function _defineProperties$16(target, props) { + for (var i$5 = 0; i$5 < props.length; i$5++) { + var descriptor = props[i$5]; + descriptor.enumerable = descriptor.enumerable || false; + descriptor.configurable = true; + if ("value" in descriptor) descriptor.writable = true; + Object.defineProperty(target, descriptor.key, descriptor); + } + } + function _createClass$16(Constructor, protoProps, staticProps) { + if (protoProps) _defineProperties$16(Constructor.prototype, protoProps); + if (staticProps) _defineProperties$16(Constructor, staticProps); + Object.defineProperty(Constructor, "prototype", { writable: false }); + return Constructor; + } + function _inheritsLoose$35(subClass, superClass) { + subClass.prototype = Object.create(superClass.prototype); + subClass.prototype.constructor = subClass; + _setPrototypeOf$35(subClass, superClass); + } + function _setPrototypeOf$35(o, p$1) { + _setPrototypeOf$35 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf$42(o$1, p$2) { + o$1.__proto__ = p$2; + return o$1; + }; + return _setPrototypeOf$35(o, p$1); + } + var Namespace$2 = /* @__PURE__ */ function(_Node) { + _inheritsLoose$35(Namespace$3, _Node); + function Namespace$3() { + return _Node.apply(this, arguments) || this; + } + var _proto = Namespace$3.prototype; + _proto.qualifiedName = function qualifiedName(value) { + if (this.namespace) return this.namespaceString + "|" + value; + else return value; + }; + _proto.valueToString = function valueToString() { + return this.qualifiedName(_Node.prototype.valueToString.call(this)); + }; + _createClass$16(Namespace$3, [ + { + key: "namespace", + get: function get$3() { + return this._namespace; + }, + set: function set(namespace) { + if (namespace === true || namespace === "*" || namespace === "&") { + this._namespace = namespace; + if (this.raws) delete this.raws.namespace; + return; + } + var escaped = (0, _cssesc$7["default"])(namespace, { isIdentifier: true }); + this._namespace = namespace; + if (escaped !== namespace) { + (0, _util$11.ensureObject)(this, "raws"); + this.raws.namespace = escaped; + } else if (this.raws) delete this.raws.namespace; + } + }, + { + key: "ns", + get: function get$3() { + return this._namespace; + }, + set: function set(namespace) { + this.namespace = namespace; + } + }, + { + key: "namespaceString", + get: function get$3() { + if (this.namespace) { + var ns = this.stringifyProperty("namespace"); + if (ns === true) return ""; + else return ns; + } else return ""; + } + } + ]); + return Namespace$3; + }(_node$19["default"]); + exports["default"] = Namespace$2; + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/tag.js +var require_tag$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/tag.js"(exports, module) { + exports.__esModule = true; + exports["default"] = void 0; + var _namespace$8 = _interopRequireDefault$70(require_namespace$2()); + var _types$37 = require_types$3(); + function _interopRequireDefault$70(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + function _inheritsLoose$34(subClass, superClass) { + subClass.prototype = Object.create(superClass.prototype); + subClass.prototype.constructor = subClass; + _setPrototypeOf$34(subClass, superClass); + } + function _setPrototypeOf$34(o, p$1) { + _setPrototypeOf$34 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf$42(o$1, p$2) { + o$1.__proto__ = p$2; + return o$1; + }; + return _setPrototypeOf$34(o, p$1); + } + var Tag$2 = /* @__PURE__ */ function(_Namespace) { + _inheritsLoose$34(Tag$3, _Namespace); + function Tag$3(opts) { + var _this; + _this = _Namespace.call(this, opts) || this; + _this.type = _types$37.TAG; + return _this; + } + return Tag$3; + }(_namespace$8["default"]); + exports["default"] = Tag$2; + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/string.js +var require_string$3 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/string.js"(exports, module) { + exports.__esModule = true; + exports["default"] = void 0; + var _node$18 = _interopRequireDefault$69(require_node$5()); + var _types$36 = require_types$3(); + function _interopRequireDefault$69(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + function _inheritsLoose$33(subClass, superClass) { + subClass.prototype = Object.create(superClass.prototype); + subClass.prototype.constructor = subClass; + _setPrototypeOf$33(subClass, superClass); + } + function _setPrototypeOf$33(o, p$1) { + _setPrototypeOf$33 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf$42(o$1, p$2) { + o$1.__proto__ = p$2; + return o$1; + }; + return _setPrototypeOf$33(o, p$1); + } + var String$3 = /* @__PURE__ */ function(_Node) { + _inheritsLoose$33(String$4, _Node); + function String$4(opts) { + var _this; + _this = _Node.call(this, opts) || this; + _this.type = _types$36.STRING; + return _this; + } + return String$4; + }(_node$18["default"]); + exports["default"] = String$3; + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/pseudo.js +var require_pseudo$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/pseudo.js"(exports, module) { + exports.__esModule = true; + exports["default"] = void 0; + var _container$6 = _interopRequireDefault$68(require_container$2()); + var _types$35 = require_types$3(); + function _interopRequireDefault$68(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + function _inheritsLoose$32(subClass, superClass) { + subClass.prototype = Object.create(superClass.prototype); + subClass.prototype.constructor = subClass; + _setPrototypeOf$32(subClass, superClass); + } + function _setPrototypeOf$32(o, p$1) { + _setPrototypeOf$32 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf$42(o$1, p$2) { + o$1.__proto__ = p$2; + return o$1; + }; + return _setPrototypeOf$32(o, p$1); + } + var Pseudo$2 = /* @__PURE__ */ function(_Container) { + _inheritsLoose$32(Pseudo$3, _Container); + function Pseudo$3(opts) { + var _this; + _this = _Container.call(this, opts) || this; + _this.type = _types$35.PSEUDO; + return _this; + } + var _proto = Pseudo$3.prototype; + _proto.toString = function toString$6() { + var params = this.length ? "(" + this.map(String).join(",") + ")" : ""; + return [ + this.rawSpaceBefore, + this.stringifyProperty("value"), + params, + this.rawSpaceAfter + ].join(""); + }; + return Pseudo$3; + }(_container$6["default"]); + exports["default"] = Pseudo$2; + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/util-deprecate/browser.js +var require_browser$1 = __commonJS({ "node_modules/util-deprecate/browser.js"(exports, module) { + /** + * Module exports. + */ + module.exports = deprecate$3; + /** + * Mark that a method should not be used. + * Returns a modified function which warns once by default. + * + * If `localStorage.noDeprecation = true` is set, then it is a no-op. + * + * If `localStorage.throwDeprecation = true` is set, then deprecated functions + * will throw an Error when invoked. + * + * If `localStorage.traceDeprecation = true` is set, then deprecated functions + * will invoke `console.trace()` instead of `console.error()`. + * + * @param {Function} fn - the function to deprecate + * @param {String} msg - the string to print to the console when `fn` is invoked + * @returns {Function} a new "deprecated" version of `fn` + * @api public + */ + function deprecate$3(fn, msg) { + if (config("noDeprecation")) return fn; + var warned$1 = false; + function deprecated() { + if (!warned$1) { + if (config("throwDeprecation")) throw new Error(msg); + else if (config("traceDeprecation")) console.trace(msg); + else console.warn(msg); + warned$1 = true; + } + return fn.apply(this, arguments); + } + return deprecated; + } + /** + * Checks `localStorage` for boolean values for the given `name`. + * + * @param {String} name + * @returns {Boolean} + * @api private + */ + function config(name) { + try { + if (!global.localStorage) return false; + } catch (_$2) { + return false; + } + var val = global.localStorage[name]; + if (null == val) return false; + return String(val).toLowerCase() === "true"; + } +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/attribute.js +var require_attribute$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/attribute.js"(exports) { + exports.__esModule = true; + exports["default"] = void 0; + exports.unescapeValue = unescapeValue$2; + var _cssesc$6 = _interopRequireDefault$67(require_cssesc()); + var _unesc$4 = _interopRequireDefault$67(require_unesc$2()); + var _namespace$7 = _interopRequireDefault$67(require_namespace$2()); + var _types$34 = require_types$3(); + var _CSSESC_QUOTE_OPTIONS$2; + function _interopRequireDefault$67(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + function _defineProperties$15(target, props) { + for (var i$5 = 0; i$5 < props.length; i$5++) { + var descriptor = props[i$5]; + descriptor.enumerable = descriptor.enumerable || false; + descriptor.configurable = true; + if ("value" in descriptor) descriptor.writable = true; + Object.defineProperty(target, descriptor.key, descriptor); + } + } + function _createClass$15(Constructor, protoProps, staticProps) { + if (protoProps) _defineProperties$15(Constructor.prototype, protoProps); + if (staticProps) _defineProperties$15(Constructor, staticProps); + Object.defineProperty(Constructor, "prototype", { writable: false }); + return Constructor; + } + function _inheritsLoose$31(subClass, superClass) { + subClass.prototype = Object.create(superClass.prototype); + subClass.prototype.constructor = subClass; + _setPrototypeOf$31(subClass, superClass); + } + function _setPrototypeOf$31(o, p$1) { + _setPrototypeOf$31 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf$42(o$1, p$2) { + o$1.__proto__ = p$2; + return o$1; + }; + return _setPrototypeOf$31(o, p$1); + } + var deprecate$2 = require_browser$1(); + var WRAPPED_IN_QUOTES$2 = /^('|")([^]*)\1$/; + var warnOfDeprecatedValueAssignment$2 = deprecate$2(function() {}, "Assigning an attribute a value containing characters that might need to be escaped is deprecated. Call attribute.setValue() instead."); + var warnOfDeprecatedQuotedAssignment$2 = deprecate$2(function() {}, "Assigning attr.quoted is deprecated and has no effect. Assign to attr.quoteMark instead."); + var warnOfDeprecatedConstructor$2 = deprecate$2(function() {}, "Constructing an Attribute selector with a value without specifying quoteMark is deprecated. Note: The value should be unescaped now."); + function unescapeValue$2(value) { + var deprecatedUsage = false; + var quoteMark = null; + var unescaped = value; + var m$2 = unescaped.match(WRAPPED_IN_QUOTES$2); + if (m$2) { + quoteMark = m$2[1]; + unescaped = m$2[2]; + } + unescaped = (0, _unesc$4["default"])(unescaped); + if (unescaped !== value) deprecatedUsage = true; + return { + deprecatedUsage, + unescaped, + quoteMark + }; + } + function handleDeprecatedContructorOpts$2(opts) { + if (opts.quoteMark !== void 0) return opts; + if (opts.value === void 0) return opts; + warnOfDeprecatedConstructor$2(); + var _unescapeValue = unescapeValue$2(opts.value), quoteMark = _unescapeValue.quoteMark, unescaped = _unescapeValue.unescaped; + if (!opts.raws) opts.raws = {}; + if (opts.raws.value === void 0) opts.raws.value = opts.value; + opts.value = unescaped; + opts.quoteMark = quoteMark; + return opts; + } + var Attribute$2 = /* @__PURE__ */ function(_Namespace) { + _inheritsLoose$31(Attribute$3, _Namespace); + function Attribute$3(opts) { + var _this; + if (opts === void 0) opts = {}; + _this = _Namespace.call(this, handleDeprecatedContructorOpts$2(opts)) || this; + _this.type = _types$34.ATTRIBUTE; + _this.raws = _this.raws || {}; + Object.defineProperty(_this.raws, "unquoted", { + get: deprecate$2(function() { + return _this.value; + }, "attr.raws.unquoted is deprecated. Call attr.value instead."), + set: deprecate$2(function() { + return _this.value; + }, "Setting attr.raws.unquoted is deprecated and has no effect. attr.value is unescaped by default now.") + }); + _this._constructed = true; + return _this; + } + /** + * Returns the Attribute's value quoted such that it would be legal to use + * in the value of a css file. The original value's quotation setting + * used for stringification is left unchanged. See `setValue(value, options)` + * if you want to control the quote settings of a new value for the attribute. + * + * You can also change the quotation used for the current value by setting quoteMark. + * + * Options: + * * quoteMark {'"' | "'" | null} - Use this value to quote the value. If this + * option is not set, the original value for quoteMark will be used. If + * indeterminate, a double quote is used. The legal values are: + * * `null` - the value will be unquoted and characters will be escaped as necessary. + * * `'` - the value will be quoted with a single quote and single quotes are escaped. + * * `"` - the value will be quoted with a double quote and double quotes are escaped. + * * preferCurrentQuoteMark {boolean} - if true, prefer the source quote mark + * over the quoteMark option value. + * * smart {boolean} - if true, will select a quote mark based on the value + * and the other options specified here. See the `smartQuoteMark()` + * method. + **/ + var _proto = Attribute$3.prototype; + _proto.getQuotedValue = function getQuotedValue(options) { + if (options === void 0) options = {}; + var quoteMark = this._determineQuoteMark(options); + var cssescopts = CSSESC_QUOTE_OPTIONS$2[quoteMark]; + var escaped = (0, _cssesc$6["default"])(this._value, cssescopts); + return escaped; + }; + _proto._determineQuoteMark = function _determineQuoteMark(options) { + return options.smart ? this.smartQuoteMark(options) : this.preferredQuoteMark(options); + }; + _proto.setValue = function setValue(value, options) { + if (options === void 0) options = {}; + this._value = value; + this._quoteMark = this._determineQuoteMark(options); + this._syncRawValue(); + }; + _proto.smartQuoteMark = function smartQuoteMark(options) { + var v$1 = this.value; + var numSingleQuotes = v$1.replace(/[^']/g, "").length; + var numDoubleQuotes = v$1.replace(/[^"]/g, "").length; + if (numSingleQuotes + numDoubleQuotes === 0) { + var escaped = (0, _cssesc$6["default"])(v$1, { isIdentifier: true }); + if (escaped === v$1) return Attribute$3.NO_QUOTE; + else { + var pref = this.preferredQuoteMark(options); + if (pref === Attribute$3.NO_QUOTE) { + var quote = this.quoteMark || options.quoteMark || Attribute$3.DOUBLE_QUOTE; + var opts = CSSESC_QUOTE_OPTIONS$2[quote]; + var quoteValue = (0, _cssesc$6["default"])(v$1, opts); + if (quoteValue.length < escaped.length) return quote; + } + return pref; + } + } else if (numDoubleQuotes === numSingleQuotes) return this.preferredQuoteMark(options); + else if (numDoubleQuotes < numSingleQuotes) return Attribute$3.DOUBLE_QUOTE; + else return Attribute$3.SINGLE_QUOTE; + }; + _proto.preferredQuoteMark = function preferredQuoteMark(options) { + var quoteMark = options.preferCurrentQuoteMark ? this.quoteMark : options.quoteMark; + if (quoteMark === void 0) quoteMark = options.preferCurrentQuoteMark ? options.quoteMark : this.quoteMark; + if (quoteMark === void 0) quoteMark = Attribute$3.DOUBLE_QUOTE; + return quoteMark; + }; + _proto._syncRawValue = function _syncRawValue() { + var rawValue = (0, _cssesc$6["default"])(this._value, CSSESC_QUOTE_OPTIONS$2[this.quoteMark]); + if (rawValue === this._value) { + if (this.raws) delete this.raws.value; + } else this.raws.value = rawValue; + }; + _proto._handleEscapes = function _handleEscapes(prop, value) { + if (this._constructed) { + var escaped = (0, _cssesc$6["default"])(value, { isIdentifier: true }); + if (escaped !== value) this.raws[prop] = escaped; + else delete this.raws[prop]; + } + }; + _proto._spacesFor = function _spacesFor(name) { + var attrSpaces = { + before: "", + after: "" + }; + var spaces = this.spaces[name] || {}; + var rawSpaces = this.raws.spaces && this.raws.spaces[name] || {}; + return Object.assign(attrSpaces, spaces, rawSpaces); + }; + _proto._stringFor = function _stringFor(name, spaceName, concat) { + if (spaceName === void 0) spaceName = name; + if (concat === void 0) concat = defaultAttrConcat$2; + var attrSpaces = this._spacesFor(spaceName); + return concat(this.stringifyProperty(name), attrSpaces); + }; + _proto.offsetOf = function offsetOf(name) { + var count = 1; + var attributeSpaces = this._spacesFor("attribute"); + count += attributeSpaces.before.length; + if (name === "namespace" || name === "ns") return this.namespace ? count : -1; + if (name === "attributeNS") return count; + count += this.namespaceString.length; + if (this.namespace) count += 1; + if (name === "attribute") return count; + count += this.stringifyProperty("attribute").length; + count += attributeSpaces.after.length; + var operatorSpaces = this._spacesFor("operator"); + count += operatorSpaces.before.length; + var operator$1 = this.stringifyProperty("operator"); + if (name === "operator") return operator$1 ? count : -1; + count += operator$1.length; + count += operatorSpaces.after.length; + var valueSpaces = this._spacesFor("value"); + count += valueSpaces.before.length; + var value = this.stringifyProperty("value"); + if (name === "value") return value ? count : -1; + count += value.length; + count += valueSpaces.after.length; + var insensitiveSpaces = this._spacesFor("insensitive"); + count += insensitiveSpaces.before.length; + if (name === "insensitive") return this.insensitive ? count : -1; + return -1; + }; + _proto.toString = function toString$6() { + var _this2 = this; + var selector$3 = [this.rawSpaceBefore, "["]; + selector$3.push(this._stringFor("qualifiedAttribute", "attribute")); + if (this.operator && (this.value || this.value === "")) { + selector$3.push(this._stringFor("operator")); + selector$3.push(this._stringFor("value")); + selector$3.push(this._stringFor("insensitiveFlag", "insensitive", function(attrValue, attrSpaces) { + if (attrValue.length > 0 && !_this2.quoted && attrSpaces.before.length === 0 && !(_this2.spaces.value && _this2.spaces.value.after)) attrSpaces.before = " "; + return defaultAttrConcat$2(attrValue, attrSpaces); + })); + } + selector$3.push("]"); + selector$3.push(this.rawSpaceAfter); + return selector$3.join(""); + }; + _createClass$15(Attribute$3, [ + { + key: "quoted", + get: function get$3() { + var qm = this.quoteMark; + return qm === "'" || qm === "\""; + }, + set: function set(value) { + warnOfDeprecatedQuotedAssignment$2(); + } + }, + { + key: "quoteMark", + get: function get$3() { + return this._quoteMark; + }, + set: function set(quoteMark) { + if (!this._constructed) { + this._quoteMark = quoteMark; + return; + } + if (this._quoteMark !== quoteMark) { + this._quoteMark = quoteMark; + this._syncRawValue(); + } + } + }, + { + key: "qualifiedAttribute", + get: function get$3() { + return this.qualifiedName(this.raws.attribute || this.attribute); + } + }, + { + key: "insensitiveFlag", + get: function get$3() { + return this.insensitive ? "i" : ""; + } + }, + { + key: "value", + get: function get$3() { + return this._value; + }, + set: function set(v$1) { + if (this._constructed) { + var _unescapeValue2 = unescapeValue$2(v$1), deprecatedUsage = _unescapeValue2.deprecatedUsage, unescaped = _unescapeValue2.unescaped, quoteMark = _unescapeValue2.quoteMark; + if (deprecatedUsage) warnOfDeprecatedValueAssignment$2(); + if (unescaped === this._value && quoteMark === this._quoteMark) return; + this._value = unescaped; + this._quoteMark = quoteMark; + this._syncRawValue(); + } else this._value = v$1; + } + }, + { + key: "insensitive", + get: function get$3() { + return this._insensitive; + }, + set: function set(insensitive) { + if (!insensitive) { + this._insensitive = false; + if (this.raws && (this.raws.insensitiveFlag === "I" || this.raws.insensitiveFlag === "i")) this.raws.insensitiveFlag = void 0; + } + this._insensitive = insensitive; + } + }, + { + key: "attribute", + get: function get$3() { + return this._attribute; + }, + set: function set(name) { + this._handleEscapes("attribute", name); + this._attribute = name; + } + } + ]); + return Attribute$3; + }(_namespace$7["default"]); + exports["default"] = Attribute$2; + Attribute$2.NO_QUOTE = null; + Attribute$2.SINGLE_QUOTE = "'"; + Attribute$2.DOUBLE_QUOTE = "\""; + var CSSESC_QUOTE_OPTIONS$2 = (_CSSESC_QUOTE_OPTIONS$2 = { + "'": { + quotes: "single", + wrap: true + }, + "\"": { + quotes: "double", + wrap: true + } + }, _CSSESC_QUOTE_OPTIONS$2[null] = { isIdentifier: true }, _CSSESC_QUOTE_OPTIONS$2); + function defaultAttrConcat$2(attrValue, attrSpaces) { + return "" + attrSpaces.before + attrValue + attrSpaces.after; + } +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/universal.js +var require_universal$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/universal.js"(exports, module) { + exports.__esModule = true; + exports["default"] = void 0; + var _namespace$6 = _interopRequireDefault$66(require_namespace$2()); + var _types$33 = require_types$3(); + function _interopRequireDefault$66(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + function _inheritsLoose$30(subClass, superClass) { + subClass.prototype = Object.create(superClass.prototype); + subClass.prototype.constructor = subClass; + _setPrototypeOf$30(subClass, superClass); + } + function _setPrototypeOf$30(o, p$1) { + _setPrototypeOf$30 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf$42(o$1, p$2) { + o$1.__proto__ = p$2; + return o$1; + }; + return _setPrototypeOf$30(o, p$1); + } + var Universal$2 = /* @__PURE__ */ function(_Namespace) { + _inheritsLoose$30(Universal$3, _Namespace); + function Universal$3(opts) { + var _this; + _this = _Namespace.call(this, opts) || this; + _this.type = _types$33.UNIVERSAL; + _this.value = "*"; + return _this; + } + return Universal$3; + }(_namespace$6["default"]); + exports["default"] = Universal$2; + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/combinator.js +var require_combinator$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/combinator.js"(exports, module) { + exports.__esModule = true; + exports["default"] = void 0; + var _node$17 = _interopRequireDefault$65(require_node$5()); + var _types$32 = require_types$3(); + function _interopRequireDefault$65(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + function _inheritsLoose$29(subClass, superClass) { + subClass.prototype = Object.create(superClass.prototype); + subClass.prototype.constructor = subClass; + _setPrototypeOf$29(subClass, superClass); + } + function _setPrototypeOf$29(o, p$1) { + _setPrototypeOf$29 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf$42(o$1, p$2) { + o$1.__proto__ = p$2; + return o$1; + }; + return _setPrototypeOf$29(o, p$1); + } + var Combinator$2 = /* @__PURE__ */ function(_Node) { + _inheritsLoose$29(Combinator$3, _Node); + function Combinator$3(opts) { + var _this; + _this = _Node.call(this, opts) || this; + _this.type = _types$32.COMBINATOR; + return _this; + } + return Combinator$3; + }(_node$17["default"]); + exports["default"] = Combinator$2; + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/nesting.js +var require_nesting$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/nesting.js"(exports, module) { + exports.__esModule = true; + exports["default"] = void 0; + var _node$16 = _interopRequireDefault$64(require_node$5()); + var _types$31 = require_types$3(); + function _interopRequireDefault$64(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + function _inheritsLoose$28(subClass, superClass) { + subClass.prototype = Object.create(superClass.prototype); + subClass.prototype.constructor = subClass; + _setPrototypeOf$28(subClass, superClass); + } + function _setPrototypeOf$28(o, p$1) { + _setPrototypeOf$28 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf$42(o$1, p$2) { + o$1.__proto__ = p$2; + return o$1; + }; + return _setPrototypeOf$28(o, p$1); + } + var Nesting$2 = /* @__PURE__ */ function(_Node) { + _inheritsLoose$28(Nesting$3, _Node); + function Nesting$3(opts) { + var _this; + _this = _Node.call(this, opts) || this; + _this.type = _types$31.NESTING; + _this.value = "&"; + return _this; + } + return Nesting$3; + }(_node$16["default"]); + exports["default"] = Nesting$2; + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/sortAscending.js +var require_sortAscending$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/sortAscending.js"(exports, module) { + exports.__esModule = true; + exports["default"] = sortAscending$2; + function sortAscending$2(list$4) { + return list$4.sort(function(a, b$1) { + return a - b$1; + }); + } + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/tokenTypes.js +var require_tokenTypes$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/tokenTypes.js"(exports) { + exports.__esModule = true; + exports.word = exports.tilde = exports.tab = exports.str = exports.space = exports.slash = exports.singleQuote = exports.semicolon = exports.plus = exports.pipe = exports.openSquare = exports.openParenthesis = exports.newline = exports.greaterThan = exports.feed = exports.equals = exports.doubleQuote = exports.dollar = exports.cr = exports.comment = exports.comma = exports.combinator = exports.colon = exports.closeSquare = exports.closeParenthesis = exports.caret = exports.bang = exports.backslash = exports.at = exports.asterisk = exports.ampersand = void 0; + var ampersand$2 = 38; + exports.ampersand = ampersand$2; + var asterisk$2 = 42; + exports.asterisk = asterisk$2; + var at$2 = 64; + exports.at = at$2; + var comma$3 = 44; + exports.comma = comma$3; + var colon$3 = 58; + exports.colon = colon$3; + var semicolon$2 = 59; + exports.semicolon = semicolon$2; + var openParenthesis$2 = 40; + exports.openParenthesis = openParenthesis$2; + var closeParenthesis$2 = 41; + exports.closeParenthesis = closeParenthesis$2; + var openSquare$2 = 91; + exports.openSquare = openSquare$2; + var closeSquare$2 = 93; + exports.closeSquare = closeSquare$2; + var dollar$2 = 36; + exports.dollar = dollar$2; + var tilde$2 = 126; + exports.tilde = tilde$2; + var caret$2 = 94; + exports.caret = caret$2; + var plus$4 = 43; + exports.plus = plus$4; + var equals$2 = 61; + exports.equals = equals$2; + var pipe$2 = 124; + exports.pipe = pipe$2; + var greaterThan$2 = 62; + exports.greaterThan = greaterThan$2; + var space$2 = 32; + exports.space = space$2; + var singleQuote$3 = 39; + exports.singleQuote = singleQuote$3; + var doubleQuote$3 = 34; + exports.doubleQuote = doubleQuote$3; + var slash$3 = 47; + exports.slash = slash$3; + var bang$2 = 33; + exports.bang = bang$2; + var backslash$3 = 92; + exports.backslash = backslash$3; + var cr$2 = 13; + exports.cr = cr$2; + var feed$2 = 12; + exports.feed = feed$2; + var newline$2 = 10; + exports.newline = newline$2; + var tab$2 = 9; + exports.tab = tab$2; + var str$2 = singleQuote$3; + exports.str = str$2; + var comment$5 = -1; + exports.comment = comment$5; + var word$2 = -2; + exports.word = word$2; + var combinator$5 = -3; + exports.combinator = combinator$5; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/tokenize.js +var require_tokenize$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/tokenize.js"(exports) { + exports.__esModule = true; + exports.FIELDS = void 0; + exports["default"] = tokenize$3; + var t$6 = _interopRequireWildcard$13(require_tokenTypes$2()); + var _unescapable$2, _wordDelimiters$2; + function _getRequireWildcardCache$10(nodeInterop) { + if (typeof WeakMap !== "function") return null; + var cacheBabelInterop = new WeakMap(); + var cacheNodeInterop = new WeakMap(); + return (_getRequireWildcardCache$10 = function _getRequireWildcardCache$12(nodeInterop$1) { + return nodeInterop$1 ? cacheNodeInterop : cacheBabelInterop; + })(nodeInterop); + } + function _interopRequireWildcard$13(obj, nodeInterop) { + if (!nodeInterop && obj && obj.__esModule) return obj; + if (obj === null || typeof obj !== "object" && typeof obj !== "function") return { "default": obj }; + var cache$3 = _getRequireWildcardCache$10(nodeInterop); + if (cache$3 && cache$3.has(obj)) return cache$3.get(obj); + var newObj = {}; + var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; + for (var key in obj) if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { + var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; + if (desc && (desc.get || desc.set)) Object.defineProperty(newObj, key, desc); + else newObj[key] = obj[key]; + } + newObj["default"] = obj; + if (cache$3) cache$3.set(obj, newObj); + return newObj; + } + var unescapable$2 = (_unescapable$2 = {}, _unescapable$2[t$6.tab] = true, _unescapable$2[t$6.newline] = true, _unescapable$2[t$6.cr] = true, _unescapable$2[t$6.feed] = true, _unescapable$2); + var wordDelimiters$2 = (_wordDelimiters$2 = {}, _wordDelimiters$2[t$6.space] = true, _wordDelimiters$2[t$6.tab] = true, _wordDelimiters$2[t$6.newline] = true, _wordDelimiters$2[t$6.cr] = true, _wordDelimiters$2[t$6.feed] = true, _wordDelimiters$2[t$6.ampersand] = true, _wordDelimiters$2[t$6.asterisk] = true, _wordDelimiters$2[t$6.bang] = true, _wordDelimiters$2[t$6.comma] = true, _wordDelimiters$2[t$6.colon] = true, _wordDelimiters$2[t$6.semicolon] = true, _wordDelimiters$2[t$6.openParenthesis] = true, _wordDelimiters$2[t$6.closeParenthesis] = true, _wordDelimiters$2[t$6.openSquare] = true, _wordDelimiters$2[t$6.closeSquare] = true, _wordDelimiters$2[t$6.singleQuote] = true, _wordDelimiters$2[t$6.doubleQuote] = true, _wordDelimiters$2[t$6.plus] = true, _wordDelimiters$2[t$6.pipe] = true, _wordDelimiters$2[t$6.tilde] = true, _wordDelimiters$2[t$6.greaterThan] = true, _wordDelimiters$2[t$6.equals] = true, _wordDelimiters$2[t$6.dollar] = true, _wordDelimiters$2[t$6.caret] = true, _wordDelimiters$2[t$6.slash] = true, _wordDelimiters$2); + var hex$2 = {}; + var hexChars$2 = "0123456789abcdefABCDEF"; + for (var i$4 = 0; i$4 < hexChars$2.length; i$4++) hex$2[hexChars$2.charCodeAt(i$4)] = true; + /** + * Returns the last index of the bar css word + * @param {string} css The string in which the word begins + * @param {number} start The index into the string where word's first letter occurs + */ + function consumeWord$2(css, start) { + var next = start; + var code$1; + do { + code$1 = css.charCodeAt(next); + if (wordDelimiters$2[code$1]) return next - 1; + else if (code$1 === t$6.backslash) next = consumeEscape$2(css, next) + 1; + else next++; + } while (next < css.length); + return next - 1; + } + /** + * Returns the last index of the escape sequence + * @param {string} css The string in which the sequence begins + * @param {number} start The index into the string where escape character (`\`) occurs. + */ + function consumeEscape$2(css, start) { + var next = start; + var code$1 = css.charCodeAt(next + 1); + if (unescapable$2[code$1]) {} else if (hex$2[code$1]) { + var hexDigits = 0; + do { + next++; + hexDigits++; + code$1 = css.charCodeAt(next + 1); + } while (hex$2[code$1] && hexDigits < 6); + if (hexDigits < 6 && code$1 === t$6.space) next++; + } else next++; + return next; + } + var FIELDS$2 = { + TYPE: 0, + START_LINE: 1, + START_COL: 2, + END_LINE: 3, + END_COL: 4, + START_POS: 5, + END_POS: 6 + }; + exports.FIELDS = FIELDS$2; + function tokenize$3(input) { + var tokens$3 = []; + var css = input.css.valueOf(); + var _css = css, length = _css.length; + var offset = -1; + var line = 1; + var start = 0; + var end = 0; + var code$1, content, endColumn, endLine, escaped, escapePos, last$3, lines, next, nextLine, nextOffset, quote, tokenType; + function unclosed(what, fix) { + if (input.safe) { + css += fix; + next = css.length - 1; + } else throw input.error("Unclosed " + what, line, start - offset, start); + } + while (start < length) { + code$1 = css.charCodeAt(start); + if (code$1 === t$6.newline) { + offset = start; + line += 1; + } + switch (code$1) { + case t$6.space: + case t$6.tab: + case t$6.newline: + case t$6.cr: + case t$6.feed: + next = start; + do { + next += 1; + code$1 = css.charCodeAt(next); + if (code$1 === t$6.newline) { + offset = next; + line += 1; + } + } while (code$1 === t$6.space || code$1 === t$6.newline || code$1 === t$6.tab || code$1 === t$6.cr || code$1 === t$6.feed); + tokenType = t$6.space; + endLine = line; + endColumn = next - offset - 1; + end = next; + break; + case t$6.plus: + case t$6.greaterThan: + case t$6.tilde: + case t$6.pipe: + next = start; + do { + next += 1; + code$1 = css.charCodeAt(next); + } while (code$1 === t$6.plus || code$1 === t$6.greaterThan || code$1 === t$6.tilde || code$1 === t$6.pipe); + tokenType = t$6.combinator; + endLine = line; + endColumn = start - offset; + end = next; + break; + case t$6.asterisk: + case t$6.ampersand: + case t$6.bang: + case t$6.comma: + case t$6.equals: + case t$6.dollar: + case t$6.caret: + case t$6.openSquare: + case t$6.closeSquare: + case t$6.colon: + case t$6.semicolon: + case t$6.openParenthesis: + case t$6.closeParenthesis: + next = start; + tokenType = code$1; + endLine = line; + endColumn = start - offset; + end = next + 1; + break; + case t$6.singleQuote: + case t$6.doubleQuote: + quote = code$1 === t$6.singleQuote ? "'" : "\""; + next = start; + do { + escaped = false; + next = css.indexOf(quote, next + 1); + if (next === -1) unclosed("quote", quote); + escapePos = next; + while (css.charCodeAt(escapePos - 1) === t$6.backslash) { + escapePos -= 1; + escaped = !escaped; + } + } while (escaped); + tokenType = t$6.str; + endLine = line; + endColumn = start - offset; + end = next + 1; + break; + default: + if (code$1 === t$6.slash && css.charCodeAt(start + 1) === t$6.asterisk) { + next = css.indexOf("*/", start + 2) + 1; + if (next === 0) unclosed("comment", "*/"); + content = css.slice(start, next + 1); + lines = content.split("\n"); + last$3 = lines.length - 1; + if (last$3 > 0) { + nextLine = line + last$3; + nextOffset = next - lines[last$3].length; + } else { + nextLine = line; + nextOffset = offset; + } + tokenType = t$6.comment; + line = nextLine; + endLine = nextLine; + endColumn = next - nextOffset; + } else if (code$1 === t$6.slash) { + next = start; + tokenType = code$1; + endLine = line; + endColumn = start - offset; + end = next + 1; + } else { + next = consumeWord$2(css, start); + tokenType = t$6.word; + endLine = line; + endColumn = next - offset; + } + end = next + 1; + break; + } + tokens$3.push([ + tokenType, + line, + start - offset, + endLine, + endColumn, + start, + end + ]); + if (nextOffset) { + offset = nextOffset; + nextOffset = null; + } + start = end; + } + return tokens$3; + } +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/parser.js +var require_parser$4 = __commonJS({ "node_modules/postcss-selector-parser/dist/parser.js"(exports, module) { + exports.__esModule = true; + exports["default"] = void 0; + var _root$5 = _interopRequireDefault$63(require_root$2()); + var _selector$5 = _interopRequireDefault$63(require_selector$2()); + var _className$5 = _interopRequireDefault$63(require_className$2()); + var _comment$5 = _interopRequireDefault$63(require_comment$2()); + var _id$5 = _interopRequireDefault$63(require_id$2()); + var _tag$5 = _interopRequireDefault$63(require_tag$2()); + var _string$6 = _interopRequireDefault$63(require_string$3()); + var _pseudo$5 = _interopRequireDefault$63(require_pseudo$2()); + var _attribute$5 = _interopRequireWildcard$12(require_attribute$2()); + var _universal$5 = _interopRequireDefault$63(require_universal$2()); + var _combinator$5 = _interopRequireDefault$63(require_combinator$2()); + var _nesting$5 = _interopRequireDefault$63(require_nesting$2()); + var _sortAscending$2 = _interopRequireDefault$63(require_sortAscending$2()); + var _tokenize$2 = _interopRequireWildcard$12(require_tokenize$2()); + var tokens$2 = _interopRequireWildcard$12(require_tokenTypes$2()); + var types$5 = _interopRequireWildcard$12(require_types$3()); + var _util$10 = require_util$3(); + var _WHITESPACE_TOKENS$2, _Object$assign$2; + function _getRequireWildcardCache$9(nodeInterop) { + if (typeof WeakMap !== "function") return null; + var cacheBabelInterop = new WeakMap(); + var cacheNodeInterop = new WeakMap(); + return (_getRequireWildcardCache$9 = function _getRequireWildcardCache$12(nodeInterop$1) { + return nodeInterop$1 ? cacheNodeInterop : cacheBabelInterop; + })(nodeInterop); + } + function _interopRequireWildcard$12(obj, nodeInterop) { + if (!nodeInterop && obj && obj.__esModule) return obj; + if (obj === null || typeof obj !== "object" && typeof obj !== "function") return { "default": obj }; + var cache$3 = _getRequireWildcardCache$9(nodeInterop); + if (cache$3 && cache$3.has(obj)) return cache$3.get(obj); + var newObj = {}; + var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; + for (var key in obj) if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { + var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; + if (desc && (desc.get || desc.set)) Object.defineProperty(newObj, key, desc); + else newObj[key] = obj[key]; + } + newObj["default"] = obj; + if (cache$3) cache$3.set(obj, newObj); + return newObj; + } + function _interopRequireDefault$63(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + function _defineProperties$14(target, props) { + for (var i$5 = 0; i$5 < props.length; i$5++) { + var descriptor = props[i$5]; + descriptor.enumerable = descriptor.enumerable || false; + descriptor.configurable = true; + if ("value" in descriptor) descriptor.writable = true; + Object.defineProperty(target, descriptor.key, descriptor); + } + } + function _createClass$14(Constructor, protoProps, staticProps) { + if (protoProps) _defineProperties$14(Constructor.prototype, protoProps); + if (staticProps) _defineProperties$14(Constructor, staticProps); + Object.defineProperty(Constructor, "prototype", { writable: false }); + return Constructor; + } + var WHITESPACE_TOKENS$2 = (_WHITESPACE_TOKENS$2 = {}, _WHITESPACE_TOKENS$2[tokens$2.space] = true, _WHITESPACE_TOKENS$2[tokens$2.cr] = true, _WHITESPACE_TOKENS$2[tokens$2.feed] = true, _WHITESPACE_TOKENS$2[tokens$2.newline] = true, _WHITESPACE_TOKENS$2[tokens$2.tab] = true, _WHITESPACE_TOKENS$2); + var WHITESPACE_EQUIV_TOKENS$2 = Object.assign({}, WHITESPACE_TOKENS$2, (_Object$assign$2 = {}, _Object$assign$2[tokens$2.comment] = true, _Object$assign$2)); + function tokenStart$2(token$1) { + return { + line: token$1[_tokenize$2.FIELDS.START_LINE], + column: token$1[_tokenize$2.FIELDS.START_COL] + }; + } + function tokenEnd$2(token$1) { + return { + line: token$1[_tokenize$2.FIELDS.END_LINE], + column: token$1[_tokenize$2.FIELDS.END_COL] + }; + } + function getSource$4(startLine, startColumn, endLine, endColumn) { + return { + start: { + line: startLine, + column: startColumn + }, + end: { + line: endLine, + column: endColumn + } + }; + } + function getTokenSource$2(token$1) { + return getSource$4(token$1[_tokenize$2.FIELDS.START_LINE], token$1[_tokenize$2.FIELDS.START_COL], token$1[_tokenize$2.FIELDS.END_LINE], token$1[_tokenize$2.FIELDS.END_COL]); + } + function getTokenSourceSpan$2(startToken, endToken) { + if (!startToken) return void 0; + return getSource$4(startToken[_tokenize$2.FIELDS.START_LINE], startToken[_tokenize$2.FIELDS.START_COL], endToken[_tokenize$2.FIELDS.END_LINE], endToken[_tokenize$2.FIELDS.END_COL]); + } + function unescapeProp$2(node, prop) { + var value = node[prop]; + if (typeof value !== "string") return; + if (value.indexOf("\\") !== -1) { + (0, _util$10.ensureObject)(node, "raws"); + node[prop] = (0, _util$10.unesc)(value); + if (node.raws[prop] === void 0) node.raws[prop] = value; + } + return node; + } + function indexesOf$2(array, item) { + var i$5 = -1; + var indexes = []; + while ((i$5 = array.indexOf(item, i$5 + 1)) !== -1) indexes.push(i$5); + return indexes; + } + function uniqs$2() { + var list$4 = Array.prototype.concat.apply([], arguments); + return list$4.filter(function(item, i$5) { + return i$5 === list$4.indexOf(item); + }); + } + var Parser$5 = /* @__PURE__ */ function() { + function Parser$10(rule$1, options) { + if (options === void 0) options = {}; + this.rule = rule$1; + this.options = Object.assign({ + lossy: false, + safe: false + }, options); + this.position = 0; + this.css = typeof this.rule === "string" ? this.rule : this.rule.selector; + this.tokens = (0, _tokenize$2["default"])({ + css: this.css, + error: this._errorGenerator(), + safe: this.options.safe + }); + var rootSource = getTokenSourceSpan$2(this.tokens[0], this.tokens[this.tokens.length - 1]); + this.root = new _root$5["default"]({ source: rootSource }); + this.root.errorGenerator = this._errorGenerator(); + var selector$3 = new _selector$5["default"]({ + source: { start: { + line: 1, + column: 1 + } }, + sourceIndex: 0 + }); + this.root.append(selector$3); + this.current = selector$3; + this.loop(); + } + var _proto = Parser$10.prototype; + _proto._errorGenerator = function _errorGenerator() { + var _this = this; + return function(message, errorOptions) { + if (typeof _this.rule === "string") return new Error(message); + return _this.rule.error(message, errorOptions); + }; + }; + _proto.attribute = function attribute$3() { + var attr = []; + var startingToken = this.currToken; + this.position++; + while (this.position < this.tokens.length && this.currToken[_tokenize$2.FIELDS.TYPE] !== tokens$2.closeSquare) { + attr.push(this.currToken); + this.position++; + } + if (this.currToken[_tokenize$2.FIELDS.TYPE] !== tokens$2.closeSquare) return this.expected("closing square bracket", this.currToken[_tokenize$2.FIELDS.START_POS]); + var len = attr.length; + var node = { + source: getSource$4(startingToken[1], startingToken[2], this.currToken[3], this.currToken[4]), + sourceIndex: startingToken[_tokenize$2.FIELDS.START_POS] + }; + if (len === 1 && !~[tokens$2.word].indexOf(attr[0][_tokenize$2.FIELDS.TYPE])) return this.expected("attribute", attr[0][_tokenize$2.FIELDS.START_POS]); + var pos = 0; + var spaceBefore = ""; + var commentBefore = ""; + var lastAdded = null; + var spaceAfterMeaningfulToken = false; + while (pos < len) { + var token$1 = attr[pos]; + var content = this.content(token$1); + var next = attr[pos + 1]; + switch (token$1[_tokenize$2.FIELDS.TYPE]) { + case tokens$2.space: + spaceAfterMeaningfulToken = true; + if (this.options.lossy) break; + if (lastAdded) { + (0, _util$10.ensureObject)(node, "spaces", lastAdded); + var prevContent = node.spaces[lastAdded].after || ""; + node.spaces[lastAdded].after = prevContent + content; + var existingComment = (0, _util$10.getProp)(node, "raws", "spaces", lastAdded, "after") || null; + if (existingComment) node.raws.spaces[lastAdded].after = existingComment + content; + } else { + spaceBefore = spaceBefore + content; + commentBefore = commentBefore + content; + } + break; + case tokens$2.asterisk: + if (next[_tokenize$2.FIELDS.TYPE] === tokens$2.equals) { + node.operator = content; + lastAdded = "operator"; + } else if ((!node.namespace || lastAdded === "namespace" && !spaceAfterMeaningfulToken) && next) { + if (spaceBefore) { + (0, _util$10.ensureObject)(node, "spaces", "attribute"); + node.spaces.attribute.before = spaceBefore; + spaceBefore = ""; + } + if (commentBefore) { + (0, _util$10.ensureObject)(node, "raws", "spaces", "attribute"); + node.raws.spaces.attribute.before = spaceBefore; + commentBefore = ""; + } + node.namespace = (node.namespace || "") + content; + var rawValue = (0, _util$10.getProp)(node, "raws", "namespace") || null; + if (rawValue) node.raws.namespace += content; + lastAdded = "namespace"; + } + spaceAfterMeaningfulToken = false; + break; + case tokens$2.dollar: if (lastAdded === "value") { + var oldRawValue = (0, _util$10.getProp)(node, "raws", "value"); + node.value += "$"; + if (oldRawValue) node.raws.value = oldRawValue + "$"; + break; + } + case tokens$2.caret: + if (next[_tokenize$2.FIELDS.TYPE] === tokens$2.equals) { + node.operator = content; + lastAdded = "operator"; + } + spaceAfterMeaningfulToken = false; + break; + case tokens$2.combinator: + if (content === "~" && next[_tokenize$2.FIELDS.TYPE] === tokens$2.equals) { + node.operator = content; + lastAdded = "operator"; + } + if (content !== "|") { + spaceAfterMeaningfulToken = false; + break; + } + if (next[_tokenize$2.FIELDS.TYPE] === tokens$2.equals) { + node.operator = content; + lastAdded = "operator"; + } else if (!node.namespace && !node.attribute) node.namespace = true; + spaceAfterMeaningfulToken = false; + break; + case tokens$2.word: + if (next && this.content(next) === "|" && attr[pos + 2] && attr[pos + 2][_tokenize$2.FIELDS.TYPE] !== tokens$2.equals && !node.operator && !node.namespace) { + node.namespace = content; + lastAdded = "namespace"; + } else if (!node.attribute || lastAdded === "attribute" && !spaceAfterMeaningfulToken) { + if (spaceBefore) { + (0, _util$10.ensureObject)(node, "spaces", "attribute"); + node.spaces.attribute.before = spaceBefore; + spaceBefore = ""; + } + if (commentBefore) { + (0, _util$10.ensureObject)(node, "raws", "spaces", "attribute"); + node.raws.spaces.attribute.before = commentBefore; + commentBefore = ""; + } + node.attribute = (node.attribute || "") + content; + var _rawValue = (0, _util$10.getProp)(node, "raws", "attribute") || null; + if (_rawValue) node.raws.attribute += content; + lastAdded = "attribute"; + } else if (!node.value && node.value !== "" || lastAdded === "value" && !(spaceAfterMeaningfulToken || node.quoteMark)) { + var _unescaped = (0, _util$10.unesc)(content); + var _oldRawValue = (0, _util$10.getProp)(node, "raws", "value") || ""; + var oldValue = node.value || ""; + node.value = oldValue + _unescaped; + node.quoteMark = null; + if (_unescaped !== content || _oldRawValue) { + (0, _util$10.ensureObject)(node, "raws"); + node.raws.value = (_oldRawValue || oldValue) + content; + } + lastAdded = "value"; + } else { + var insensitive = content === "i" || content === "I"; + if ((node.value || node.value === "") && (node.quoteMark || spaceAfterMeaningfulToken)) { + node.insensitive = insensitive; + if (!insensitive || content === "I") { + (0, _util$10.ensureObject)(node, "raws"); + node.raws.insensitiveFlag = content; + } + lastAdded = "insensitive"; + if (spaceBefore) { + (0, _util$10.ensureObject)(node, "spaces", "insensitive"); + node.spaces.insensitive.before = spaceBefore; + spaceBefore = ""; + } + if (commentBefore) { + (0, _util$10.ensureObject)(node, "raws", "spaces", "insensitive"); + node.raws.spaces.insensitive.before = commentBefore; + commentBefore = ""; + } + } else if (node.value || node.value === "") { + lastAdded = "value"; + node.value += content; + if (node.raws.value) node.raws.value += content; + } + } + spaceAfterMeaningfulToken = false; + break; + case tokens$2.str: + if (!node.attribute || !node.operator) return this.error("Expected an attribute followed by an operator preceding the string.", { index: token$1[_tokenize$2.FIELDS.START_POS] }); + var _unescapeValue = (0, _attribute$5.unescapeValue)(content), unescaped = _unescapeValue.unescaped, quoteMark = _unescapeValue.quoteMark; + node.value = unescaped; + node.quoteMark = quoteMark; + lastAdded = "value"; + (0, _util$10.ensureObject)(node, "raws"); + node.raws.value = content; + spaceAfterMeaningfulToken = false; + break; + case tokens$2.equals: + if (!node.attribute) return this.expected("attribute", token$1[_tokenize$2.FIELDS.START_POS], content); + if (node.value) return this.error("Unexpected \"=\" found; an operator was already defined.", { index: token$1[_tokenize$2.FIELDS.START_POS] }); + node.operator = node.operator ? node.operator + content : content; + lastAdded = "operator"; + spaceAfterMeaningfulToken = false; + break; + case tokens$2.comment: + if (lastAdded) if (spaceAfterMeaningfulToken || next && next[_tokenize$2.FIELDS.TYPE] === tokens$2.space || lastAdded === "insensitive") { + var lastComment = (0, _util$10.getProp)(node, "spaces", lastAdded, "after") || ""; + var rawLastComment = (0, _util$10.getProp)(node, "raws", "spaces", lastAdded, "after") || lastComment; + (0, _util$10.ensureObject)(node, "raws", "spaces", lastAdded); + node.raws.spaces[lastAdded].after = rawLastComment + content; + } else { + var lastValue = node[lastAdded] || ""; + var rawLastValue = (0, _util$10.getProp)(node, "raws", lastAdded) || lastValue; + (0, _util$10.ensureObject)(node, "raws"); + node.raws[lastAdded] = rawLastValue + content; + } + else commentBefore = commentBefore + content; + break; + default: return this.error("Unexpected \"" + content + "\" found.", { index: token$1[_tokenize$2.FIELDS.START_POS] }); + } + pos++; + } + unescapeProp$2(node, "attribute"); + unescapeProp$2(node, "namespace"); + this.newNode(new _attribute$5["default"](node)); + this.position++; + }; + _proto.parseWhitespaceEquivalentTokens = function parseWhitespaceEquivalentTokens(stopPosition) { + if (stopPosition < 0) stopPosition = this.tokens.length; + var startPosition = this.position; + var nodes$1 = []; + var space$3 = ""; + var lastComment = void 0; + do + if (WHITESPACE_TOKENS$2[this.currToken[_tokenize$2.FIELDS.TYPE]]) { + if (!this.options.lossy) space$3 += this.content(); + } else if (this.currToken[_tokenize$2.FIELDS.TYPE] === tokens$2.comment) { + var spaces = {}; + if (space$3) { + spaces.before = space$3; + space$3 = ""; + } + lastComment = new _comment$5["default"]({ + value: this.content(), + source: getTokenSource$2(this.currToken), + sourceIndex: this.currToken[_tokenize$2.FIELDS.START_POS], + spaces + }); + nodes$1.push(lastComment); + } + while (++this.position < stopPosition); + if (space$3) { + if (lastComment) lastComment.spaces.after = space$3; + else if (!this.options.lossy) { + var firstToken = this.tokens[startPosition]; + var lastToken = this.tokens[this.position - 1]; + nodes$1.push(new _string$6["default"]({ + value: "", + source: getSource$4(firstToken[_tokenize$2.FIELDS.START_LINE], firstToken[_tokenize$2.FIELDS.START_COL], lastToken[_tokenize$2.FIELDS.END_LINE], lastToken[_tokenize$2.FIELDS.END_COL]), + sourceIndex: firstToken[_tokenize$2.FIELDS.START_POS], + spaces: { + before: space$3, + after: "" + } + })); + } + } + return nodes$1; + }; + _proto.convertWhitespaceNodesToSpace = function convertWhitespaceNodesToSpace(nodes$1, requiredSpace) { + var _this2 = this; + if (requiredSpace === void 0) requiredSpace = false; + var space$3 = ""; + var rawSpace = ""; + nodes$1.forEach(function(n$3) { + var spaceBefore = _this2.lossySpace(n$3.spaces.before, requiredSpace); + var rawSpaceBefore = _this2.lossySpace(n$3.rawSpaceBefore, requiredSpace); + space$3 += spaceBefore + _this2.lossySpace(n$3.spaces.after, requiredSpace && spaceBefore.length === 0); + rawSpace += spaceBefore + n$3.value + _this2.lossySpace(n$3.rawSpaceAfter, requiredSpace && rawSpaceBefore.length === 0); + }); + if (rawSpace === space$3) rawSpace = void 0; + var result$1 = { + space: space$3, + rawSpace + }; + return result$1; + }; + _proto.isNamedCombinator = function isNamedCombinator(position) { + if (position === void 0) position = this.position; + return this.tokens[position + 0] && this.tokens[position + 0][_tokenize$2.FIELDS.TYPE] === tokens$2.slash && this.tokens[position + 1] && this.tokens[position + 1][_tokenize$2.FIELDS.TYPE] === tokens$2.word && this.tokens[position + 2] && this.tokens[position + 2][_tokenize$2.FIELDS.TYPE] === tokens$2.slash; + }; + _proto.namedCombinator = function namedCombinator() { + if (this.isNamedCombinator()) { + var nameRaw = this.content(this.tokens[this.position + 1]); + var name = (0, _util$10.unesc)(nameRaw).toLowerCase(); + var raws = {}; + if (name !== nameRaw) raws.value = "/" + nameRaw + "/"; + var node = new _combinator$5["default"]({ + value: "/" + name + "/", + source: getSource$4(this.currToken[_tokenize$2.FIELDS.START_LINE], this.currToken[_tokenize$2.FIELDS.START_COL], this.tokens[this.position + 2][_tokenize$2.FIELDS.END_LINE], this.tokens[this.position + 2][_tokenize$2.FIELDS.END_COL]), + sourceIndex: this.currToken[_tokenize$2.FIELDS.START_POS], + raws + }); + this.position = this.position + 3; + return node; + } else this.unexpected(); + }; + _proto.combinator = function combinator$6() { + var _this3 = this; + if (this.content() === "|") return this.namespace(); + var nextSigTokenPos = this.locateNextMeaningfulToken(this.position); + if (nextSigTokenPos < 0 || this.tokens[nextSigTokenPos][_tokenize$2.FIELDS.TYPE] === tokens$2.comma || this.tokens[nextSigTokenPos][_tokenize$2.FIELDS.TYPE] === tokens$2.closeParenthesis) { + var nodes$1 = this.parseWhitespaceEquivalentTokens(nextSigTokenPos); + if (nodes$1.length > 0) { + var last$3 = this.current.last; + if (last$3) { + var _this$convertWhitespa = this.convertWhitespaceNodesToSpace(nodes$1), space$3 = _this$convertWhitespa.space, rawSpace = _this$convertWhitespa.rawSpace; + if (rawSpace !== void 0) last$3.rawSpaceAfter += rawSpace; + last$3.spaces.after += space$3; + } else nodes$1.forEach(function(n$3) { + return _this3.newNode(n$3); + }); + } + return; + } + var firstToken = this.currToken; + var spaceOrDescendantSelectorNodes = void 0; + if (nextSigTokenPos > this.position) spaceOrDescendantSelectorNodes = this.parseWhitespaceEquivalentTokens(nextSigTokenPos); + var node; + if (this.isNamedCombinator()) node = this.namedCombinator(); + else if (this.currToken[_tokenize$2.FIELDS.TYPE] === tokens$2.combinator) { + node = new _combinator$5["default"]({ + value: this.content(), + source: getTokenSource$2(this.currToken), + sourceIndex: this.currToken[_tokenize$2.FIELDS.START_POS] + }); + this.position++; + } else if (WHITESPACE_TOKENS$2[this.currToken[_tokenize$2.FIELDS.TYPE]]) {} else if (!spaceOrDescendantSelectorNodes) this.unexpected(); + if (node) { + if (spaceOrDescendantSelectorNodes) { + var _this$convertWhitespa2 = this.convertWhitespaceNodesToSpace(spaceOrDescendantSelectorNodes), _space = _this$convertWhitespa2.space, _rawSpace = _this$convertWhitespa2.rawSpace; + node.spaces.before = _space; + node.rawSpaceBefore = _rawSpace; + } + } else { + var _this$convertWhitespa3 = this.convertWhitespaceNodesToSpace(spaceOrDescendantSelectorNodes, true), _space2 = _this$convertWhitespa3.space, _rawSpace2 = _this$convertWhitespa3.rawSpace; + if (!_rawSpace2) _rawSpace2 = _space2; + var spaces = {}; + var raws = { spaces: {} }; + if (_space2.endsWith(" ") && _rawSpace2.endsWith(" ")) { + spaces.before = _space2.slice(0, _space2.length - 1); + raws.spaces.before = _rawSpace2.slice(0, _rawSpace2.length - 1); + } else if (_space2.startsWith(" ") && _rawSpace2.startsWith(" ")) { + spaces.after = _space2.slice(1); + raws.spaces.after = _rawSpace2.slice(1); + } else raws.value = _rawSpace2; + node = new _combinator$5["default"]({ + value: " ", + source: getTokenSourceSpan$2(firstToken, this.tokens[this.position - 1]), + sourceIndex: firstToken[_tokenize$2.FIELDS.START_POS], + spaces, + raws + }); + } + if (this.currToken && this.currToken[_tokenize$2.FIELDS.TYPE] === tokens$2.space) { + node.spaces.after = this.optionalSpace(this.content()); + this.position++; + } + return this.newNode(node); + }; + _proto.comma = function comma$5() { + if (this.position === this.tokens.length - 1) { + this.root.trailingComma = true; + this.position++; + return; + } + this.current._inferEndPosition(); + var selector$3 = new _selector$5["default"]({ + source: { start: tokenStart$2(this.tokens[this.position + 1]) }, + sourceIndex: this.tokens[this.position + 1][_tokenize$2.FIELDS.START_POS] + }); + this.current.parent.append(selector$3); + this.current = selector$3; + this.position++; + }; + _proto.comment = function comment$7() { + var current = this.currToken; + this.newNode(new _comment$5["default"]({ + value: this.content(), + source: getTokenSource$2(current), + sourceIndex: current[_tokenize$2.FIELDS.START_POS] + })); + this.position++; + }; + _proto.error = function error(message, opts) { + throw this.root.error(message, opts); + }; + _proto.missingBackslash = function missingBackslash() { + return this.error("Expected a backslash preceding the semicolon.", { index: this.currToken[_tokenize$2.FIELDS.START_POS] }); + }; + _proto.missingParenthesis = function missingParenthesis() { + return this.expected("opening parenthesis", this.currToken[_tokenize$2.FIELDS.START_POS]); + }; + _proto.missingSquareBracket = function missingSquareBracket() { + return this.expected("opening square bracket", this.currToken[_tokenize$2.FIELDS.START_POS]); + }; + _proto.unexpected = function unexpected() { + return this.error("Unexpected '" + this.content() + "'. Escaping special characters with \\ may help.", this.currToken[_tokenize$2.FIELDS.START_POS]); + }; + _proto.unexpectedPipe = function unexpectedPipe() { + return this.error("Unexpected '|'.", this.currToken[_tokenize$2.FIELDS.START_POS]); + }; + _proto.namespace = function namespace() { + var before$1 = this.prevToken && this.content(this.prevToken) || true; + if (this.nextToken[_tokenize$2.FIELDS.TYPE] === tokens$2.word) { + this.position++; + return this.word(before$1); + } else if (this.nextToken[_tokenize$2.FIELDS.TYPE] === tokens$2.asterisk) { + this.position++; + return this.universal(before$1); + } + this.unexpectedPipe(); + }; + _proto.nesting = function nesting$3() { + if (this.nextToken) { + var nextContent = this.content(this.nextToken); + if (nextContent === "|") { + this.position++; + return; + } + } + var current = this.currToken; + this.newNode(new _nesting$5["default"]({ + value: this.content(), + source: getTokenSource$2(current), + sourceIndex: current[_tokenize$2.FIELDS.START_POS] + })); + this.position++; + }; + _proto.parentheses = function parentheses() { + var last$3 = this.current.last; + var unbalanced = 1; + this.position++; + if (last$3 && last$3.type === types$5.PSEUDO) { + var selector$3 = new _selector$5["default"]({ + source: { start: tokenStart$2(this.tokens[this.position]) }, + sourceIndex: this.tokens[this.position][_tokenize$2.FIELDS.START_POS] + }); + var cache$3 = this.current; + last$3.append(selector$3); + this.current = selector$3; + while (this.position < this.tokens.length && unbalanced) { + if (this.currToken[_tokenize$2.FIELDS.TYPE] === tokens$2.openParenthesis) unbalanced++; + if (this.currToken[_tokenize$2.FIELDS.TYPE] === tokens$2.closeParenthesis) unbalanced--; + if (unbalanced) this.parse(); + else { + this.current.source.end = tokenEnd$2(this.currToken); + this.current.parent.source.end = tokenEnd$2(this.currToken); + this.position++; + } + } + this.current = cache$3; + } else { + var parenStart = this.currToken; + var parenValue = "("; + var parenEnd; + while (this.position < this.tokens.length && unbalanced) { + if (this.currToken[_tokenize$2.FIELDS.TYPE] === tokens$2.openParenthesis) unbalanced++; + if (this.currToken[_tokenize$2.FIELDS.TYPE] === tokens$2.closeParenthesis) unbalanced--; + parenEnd = this.currToken; + parenValue += this.parseParenthesisToken(this.currToken); + this.position++; + } + if (last$3) last$3.appendToPropertyAndEscape("value", parenValue, parenValue); + else this.newNode(new _string$6["default"]({ + value: parenValue, + source: getSource$4(parenStart[_tokenize$2.FIELDS.START_LINE], parenStart[_tokenize$2.FIELDS.START_COL], parenEnd[_tokenize$2.FIELDS.END_LINE], parenEnd[_tokenize$2.FIELDS.END_COL]), + sourceIndex: parenStart[_tokenize$2.FIELDS.START_POS] + })); + } + if (unbalanced) return this.expected("closing parenthesis", this.currToken[_tokenize$2.FIELDS.START_POS]); + }; + _proto.pseudo = function pseudo$3() { + var _this4 = this; + var pseudoStr = ""; + var startingToken = this.currToken; + while (this.currToken && this.currToken[_tokenize$2.FIELDS.TYPE] === tokens$2.colon) { + pseudoStr += this.content(); + this.position++; + } + if (!this.currToken) return this.expected(["pseudo-class", "pseudo-element"], this.position - 1); + if (this.currToken[_tokenize$2.FIELDS.TYPE] === tokens$2.word) this.splitWord(false, function(first$1, length) { + pseudoStr += first$1; + _this4.newNode(new _pseudo$5["default"]({ + value: pseudoStr, + source: getTokenSourceSpan$2(startingToken, _this4.currToken), + sourceIndex: startingToken[_tokenize$2.FIELDS.START_POS] + })); + if (length > 1 && _this4.nextToken && _this4.nextToken[_tokenize$2.FIELDS.TYPE] === tokens$2.openParenthesis) _this4.error("Misplaced parenthesis.", { index: _this4.nextToken[_tokenize$2.FIELDS.START_POS] }); + }); + else return this.expected(["pseudo-class", "pseudo-element"], this.currToken[_tokenize$2.FIELDS.START_POS]); + }; + _proto.space = function space$3() { + var content = this.content(); + if (this.position === 0 || this.prevToken[_tokenize$2.FIELDS.TYPE] === tokens$2.comma || this.prevToken[_tokenize$2.FIELDS.TYPE] === tokens$2.openParenthesis || this.current.nodes.every(function(node) { + return node.type === "comment"; + })) { + this.spaces = this.optionalSpace(content); + this.position++; + } else if (this.position === this.tokens.length - 1 || this.nextToken[_tokenize$2.FIELDS.TYPE] === tokens$2.comma || this.nextToken[_tokenize$2.FIELDS.TYPE] === tokens$2.closeParenthesis) { + this.current.last.spaces.after = this.optionalSpace(content); + this.position++; + } else this.combinator(); + }; + _proto.string = function string$3() { + var current = this.currToken; + this.newNode(new _string$6["default"]({ + value: this.content(), + source: getTokenSource$2(current), + sourceIndex: current[_tokenize$2.FIELDS.START_POS] + })); + this.position++; + }; + _proto.universal = function universal$3(namespace) { + var nextToken = this.nextToken; + if (nextToken && this.content(nextToken) === "|") { + this.position++; + return this.namespace(); + } + var current = this.currToken; + this.newNode(new _universal$5["default"]({ + value: this.content(), + source: getTokenSource$2(current), + sourceIndex: current[_tokenize$2.FIELDS.START_POS] + }), namespace); + this.position++; + }; + _proto.splitWord = function splitWord(namespace, firstCallback) { + var _this5 = this; + var nextToken = this.nextToken; + var word$3 = this.content(); + while (nextToken && ~[ + tokens$2.dollar, + tokens$2.caret, + tokens$2.equals, + tokens$2.word + ].indexOf(nextToken[_tokenize$2.FIELDS.TYPE])) { + this.position++; + var current = this.content(); + word$3 += current; + if (current.lastIndexOf("\\") === current.length - 1) { + var next = this.nextToken; + if (next && next[_tokenize$2.FIELDS.TYPE] === tokens$2.space) { + word$3 += this.requiredSpace(this.content(next)); + this.position++; + } + } + nextToken = this.nextToken; + } + var hasClass = indexesOf$2(word$3, ".").filter(function(i$5) { + var escapedDot = word$3[i$5 - 1] === "\\"; + var isKeyframesPercent = /^\d+\.\d+%$/.test(word$3); + return !escapedDot && !isKeyframesPercent; + }); + var hasId = indexesOf$2(word$3, "#").filter(function(i$5) { + return word$3[i$5 - 1] !== "\\"; + }); + var interpolations = indexesOf$2(word$3, "#{"); + if (interpolations.length) hasId = hasId.filter(function(hashIndex) { + return !~interpolations.indexOf(hashIndex); + }); + var indices = (0, _sortAscending$2["default"])(uniqs$2([0].concat(hasClass, hasId))); + indices.forEach(function(ind, i$5) { + var index$1 = indices[i$5 + 1] || word$3.length; + var value = word$3.slice(ind, index$1); + if (i$5 === 0 && firstCallback) return firstCallback.call(_this5, value, indices.length); + var node; + var current$1 = _this5.currToken; + var sourceIndex = current$1[_tokenize$2.FIELDS.START_POS] + indices[i$5]; + var source = getSource$4(current$1[1], current$1[2] + ind, current$1[3], current$1[2] + (index$1 - 1)); + if (~hasClass.indexOf(ind)) { + var classNameOpts = { + value: value.slice(1), + source, + sourceIndex + }; + node = new _className$5["default"](unescapeProp$2(classNameOpts, "value")); + } else if (~hasId.indexOf(ind)) { + var idOpts = { + value: value.slice(1), + source, + sourceIndex + }; + node = new _id$5["default"](unescapeProp$2(idOpts, "value")); + } else { + var tagOpts = { + value, + source, + sourceIndex + }; + unescapeProp$2(tagOpts, "value"); + node = new _tag$5["default"](tagOpts); + } + _this5.newNode(node, namespace); + namespace = null; + }); + this.position++; + }; + _proto.word = function word$3(namespace) { + var nextToken = this.nextToken; + if (nextToken && this.content(nextToken) === "|") { + this.position++; + return this.namespace(); + } + return this.splitWord(namespace); + }; + _proto.loop = function loop() { + while (this.position < this.tokens.length) this.parse(true); + this.current._inferEndPosition(); + return this.root; + }; + _proto.parse = function parse$17(throwOnParenthesis) { + switch (this.currToken[_tokenize$2.FIELDS.TYPE]) { + case tokens$2.space: + this.space(); + break; + case tokens$2.comment: + this.comment(); + break; + case tokens$2.openParenthesis: + this.parentheses(); + break; + case tokens$2.closeParenthesis: + if (throwOnParenthesis) this.missingParenthesis(); + break; + case tokens$2.openSquare: + this.attribute(); + break; + case tokens$2.dollar: + case tokens$2.caret: + case tokens$2.equals: + case tokens$2.word: + this.word(); + break; + case tokens$2.colon: + this.pseudo(); + break; + case tokens$2.comma: + this.comma(); + break; + case tokens$2.asterisk: + this.universal(); + break; + case tokens$2.ampersand: + this.nesting(); + break; + case tokens$2.slash: + case tokens$2.combinator: + this.combinator(); + break; + case tokens$2.str: + this.string(); + break; + case tokens$2.closeSquare: this.missingSquareBracket(); + case tokens$2.semicolon: this.missingBackslash(); + default: this.unexpected(); + } + }; + _proto.expected = function expected(description, index$1, found) { + if (Array.isArray(description)) { + var last$3 = description.pop(); + description = description.join(", ") + " or " + last$3; + } + var an = /^[aeiou]/.test(description[0]) ? "an" : "a"; + if (!found) return this.error("Expected " + an + " " + description + ".", { index: index$1 }); + return this.error("Expected " + an + " " + description + ", found \"" + found + "\" instead.", { index: index$1 }); + }; + _proto.requiredSpace = function requiredSpace(space$3) { + return this.options.lossy ? " " : space$3; + }; + _proto.optionalSpace = function optionalSpace(space$3) { + return this.options.lossy ? "" : space$3; + }; + _proto.lossySpace = function lossySpace(space$3, required) { + if (this.options.lossy) return required ? " " : ""; + else return space$3; + }; + _proto.parseParenthesisToken = function parseParenthesisToken(token$1) { + var content = this.content(token$1); + if (token$1[_tokenize$2.FIELDS.TYPE] === tokens$2.space) return this.requiredSpace(content); + else return content; + }; + _proto.newNode = function newNode(node, namespace) { + if (namespace) { + if (/^ +$/.test(namespace)) { + if (!this.options.lossy) this.spaces = (this.spaces || "") + namespace; + namespace = true; + } + node.namespace = namespace; + unescapeProp$2(node, "namespace"); + } + if (this.spaces) { + node.spaces.before = this.spaces; + this.spaces = ""; + } + return this.current.append(node); + }; + _proto.content = function content(token$1) { + if (token$1 === void 0) token$1 = this.currToken; + return this.css.slice(token$1[_tokenize$2.FIELDS.START_POS], token$1[_tokenize$2.FIELDS.END_POS]); + }; + /** + * returns the index of the next non-whitespace, non-comment token. + * returns -1 if no meaningful token is found. + */ + _proto.locateNextMeaningfulToken = function locateNextMeaningfulToken(startPosition) { + if (startPosition === void 0) startPosition = this.position + 1; + var searchPosition = startPosition; + while (searchPosition < this.tokens.length) if (WHITESPACE_EQUIV_TOKENS$2[this.tokens[searchPosition][_tokenize$2.FIELDS.TYPE]]) { + searchPosition++; + continue; + } else return searchPosition; + return -1; + }; + _createClass$14(Parser$10, [ + { + key: "currToken", + get: function get$3() { + return this.tokens[this.position]; + } + }, + { + key: "nextToken", + get: function get$3() { + return this.tokens[this.position + 1]; + } + }, + { + key: "prevToken", + get: function get$3() { + return this.tokens[this.position - 1]; + } + } + ]); + return Parser$10; + }(); + exports["default"] = Parser$5; + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/processor.js +var require_processor$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/processor.js"(exports, module) { + exports.__esModule = true; + exports["default"] = void 0; + var _parser$7 = _interopRequireDefault$62(require_parser$4()); + function _interopRequireDefault$62(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + var Processor$2 = /* @__PURE__ */ function() { + function Processor$8(func, options) { + this.func = func || function noop$4() {}; + this.funcRes = null; + this.options = options; + } + var _proto = Processor$8.prototype; + _proto._shouldUpdateSelector = function _shouldUpdateSelector(rule$1, options) { + if (options === void 0) options = {}; + var merged = Object.assign({}, this.options, options); + if (merged.updateSelector === false) return false; + else return typeof rule$1 !== "string"; + }; + _proto._isLossy = function _isLossy(options) { + if (options === void 0) options = {}; + var merged = Object.assign({}, this.options, options); + if (merged.lossless === false) return true; + else return false; + }; + _proto._root = function _root$6(rule$1, options) { + if (options === void 0) options = {}; + var parser$4 = new _parser$7["default"](rule$1, this._parseOptions(options)); + return parser$4.root; + }; + _proto._parseOptions = function _parseOptions(options) { + return { lossy: this._isLossy(options) }; + }; + _proto._run = function _run(rule$1, options) { + var _this = this; + if (options === void 0) options = {}; + return new Promise(function(resolve$5, reject$1) { + try { + var root$6 = _this._root(rule$1, options); + Promise.resolve(_this.func(root$6)).then(function(transform$1) { + var string$3 = void 0; + if (_this._shouldUpdateSelector(rule$1, options)) { + string$3 = root$6.toString(); + rule$1.selector = string$3; + } + return { + transform: transform$1, + root: root$6, + string: string$3 + }; + }).then(resolve$5, reject$1); + } catch (e) { + reject$1(e); + return; + } + }); + }; + _proto._runSync = function _runSync(rule$1, options) { + if (options === void 0) options = {}; + var root$6 = this._root(rule$1, options); + var transform$1 = this.func(root$6); + if (transform$1 && typeof transform$1.then === "function") throw new Error("Selector processor returned a promise to a synchronous call."); + var string$3 = void 0; + if (options.updateSelector && typeof rule$1 !== "string") { + string$3 = root$6.toString(); + rule$1.selector = string$3; + } + return { + transform: transform$1, + root: root$6, + string: string$3 + }; + }; + _proto.ast = function ast(rule$1, options) { + return this._run(rule$1, options).then(function(result$1) { + return result$1.root; + }); + }; + _proto.astSync = function astSync(rule$1, options) { + return this._runSync(rule$1, options).root; + }; + _proto.transform = function transform$1(rule$1, options) { + return this._run(rule$1, options).then(function(result$1) { + return result$1.transform; + }); + }; + _proto.transformSync = function transformSync(rule$1, options) { + return this._runSync(rule$1, options).transform; + }; + _proto.process = function process$1(rule$1, options) { + return this._run(rule$1, options).then(function(result$1) { + return result$1.string || result$1.root.toString(); + }); + }; + _proto.processSync = function processSync(rule$1, options) { + var result$1 = this._runSync(rule$1, options); + return result$1.string || result$1.root.toString(); + }; + return Processor$8; + }(); + exports["default"] = Processor$2; + module.exports = exports.default; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/constructors.js +var require_constructors$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/constructors.js"(exports) { + exports.__esModule = true; + exports.universal = exports.tag = exports.string = exports.selector = exports.root = exports.pseudo = exports.nesting = exports.id = exports.comment = exports.combinator = exports.className = exports.attribute = void 0; + var _attribute$4 = _interopRequireDefault$61(require_attribute$2()); + var _className$4 = _interopRequireDefault$61(require_className$2()); + var _combinator$4 = _interopRequireDefault$61(require_combinator$2()); + var _comment$4 = _interopRequireDefault$61(require_comment$2()); + var _id$4 = _interopRequireDefault$61(require_id$2()); + var _nesting$4 = _interopRequireDefault$61(require_nesting$2()); + var _pseudo$4 = _interopRequireDefault$61(require_pseudo$2()); + var _root$4 = _interopRequireDefault$61(require_root$2()); + var _selector$4 = _interopRequireDefault$61(require_selector$2()); + var _string$5 = _interopRequireDefault$61(require_string$3()); + var _tag$4 = _interopRequireDefault$61(require_tag$2()); + var _universal$4 = _interopRequireDefault$61(require_universal$2()); + function _interopRequireDefault$61(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + var attribute$2 = function attribute$3(opts) { + return new _attribute$4["default"](opts); + }; + exports.attribute = attribute$2; + var className$2 = function className$3(opts) { + return new _className$4["default"](opts); + }; + exports.className = className$2; + var combinator$4 = function combinator$6(opts) { + return new _combinator$4["default"](opts); + }; + exports.combinator = combinator$4; + var comment$4 = function comment$7(opts) { + return new _comment$4["default"](opts); + }; + exports.comment = comment$4; + var id$3 = function id$4(opts) { + return new _id$4["default"](opts); + }; + exports.id = id$3; + var nesting$2 = function nesting$3(opts) { + return new _nesting$4["default"](opts); + }; + exports.nesting = nesting$2; + var pseudo$2 = function pseudo$3(opts) { + return new _pseudo$4["default"](opts); + }; + exports.pseudo = pseudo$2; + var root$4 = function root$6(opts) { + return new _root$4["default"](opts); + }; + exports.root = root$4; + var selector$2 = function selector$3(opts) { + return new _selector$4["default"](opts); + }; + exports.selector = selector$2; + var string$2 = function string$3(opts) { + return new _string$5["default"](opts); + }; + exports.string = string$2; + var tag$2 = function tag$3(opts) { + return new _tag$4["default"](opts); + }; + exports.tag = tag$2; + var universal$2 = function universal$3(opts) { + return new _universal$4["default"](opts); + }; + exports.universal = universal$2; +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/guards.js +var require_guards$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/guards.js"(exports) { + exports.__esModule = true; + exports.isComment = exports.isCombinator = exports.isClassName = exports.isAttribute = void 0; + exports.isContainer = isContainer$2; + exports.isIdentifier = void 0; + exports.isNamespace = isNamespace$2; + exports.isNesting = void 0; + exports.isNode = isNode$3; + exports.isPseudo = void 0; + exports.isPseudoClass = isPseudoClass$2; + exports.isPseudoElement = isPseudoElement$2; + exports.isUniversal = exports.isTag = exports.isString = exports.isSelector = exports.isRoot = void 0; + var _types$30 = require_types$3(); + var _IS_TYPE$2; + var IS_TYPE$2 = (_IS_TYPE$2 = {}, _IS_TYPE$2[_types$30.ATTRIBUTE] = true, _IS_TYPE$2[_types$30.CLASS] = true, _IS_TYPE$2[_types$30.COMBINATOR] = true, _IS_TYPE$2[_types$30.COMMENT] = true, _IS_TYPE$2[_types$30.ID] = true, _IS_TYPE$2[_types$30.NESTING] = true, _IS_TYPE$2[_types$30.PSEUDO] = true, _IS_TYPE$2[_types$30.ROOT] = true, _IS_TYPE$2[_types$30.SELECTOR] = true, _IS_TYPE$2[_types$30.STRING] = true, _IS_TYPE$2[_types$30.TAG] = true, _IS_TYPE$2[_types$30.UNIVERSAL] = true, _IS_TYPE$2); + function isNode$3(node) { + return typeof node === "object" && IS_TYPE$2[node.type]; + } + function isNodeType$3(type, node) { + return isNode$3(node) && node.type === type; + } + var isAttribute$2 = isNodeType$3.bind(null, _types$30.ATTRIBUTE); + exports.isAttribute = isAttribute$2; + var isClassName$2 = isNodeType$3.bind(null, _types$30.CLASS); + exports.isClassName = isClassName$2; + var isCombinator$2 = isNodeType$3.bind(null, _types$30.COMBINATOR); + exports.isCombinator = isCombinator$2; + var isComment$4 = isNodeType$3.bind(null, _types$30.COMMENT); + exports.isComment = isComment$4; + var isIdentifier$14 = isNodeType$3.bind(null, _types$30.ID); + exports.isIdentifier = isIdentifier$14; + var isNesting$2 = isNodeType$3.bind(null, _types$30.NESTING); + exports.isNesting = isNesting$2; + var isPseudo$2 = isNodeType$3.bind(null, _types$30.PSEUDO); + exports.isPseudo = isPseudo$2; + var isRoot$2 = isNodeType$3.bind(null, _types$30.ROOT); + exports.isRoot = isRoot$2; + var isSelector$2 = isNodeType$3.bind(null, _types$30.SELECTOR); + exports.isSelector = isSelector$2; + var isString$3 = isNodeType$3.bind(null, _types$30.STRING); + exports.isString = isString$3; + var isTag$5 = isNodeType$3.bind(null, _types$30.TAG); + exports.isTag = isTag$5; + var isUniversal$2 = isNodeType$3.bind(null, _types$30.UNIVERSAL); + exports.isUniversal = isUniversal$2; + function isPseudoElement$2(node) { + return isPseudo$2(node) && node.value && (node.value.startsWith("::") || node.value.toLowerCase() === ":before" || node.value.toLowerCase() === ":after" || node.value.toLowerCase() === ":first-letter" || node.value.toLowerCase() === ":first-line"); + } + function isPseudoClass$2(node) { + return isPseudo$2(node) && !isPseudoElement$2(node); + } + function isContainer$2(node) { + return !!(isNode$3(node) && node.walk); + } + function isNamespace$2(node) { + return isAttribute$2(node) || isTag$5(node); + } +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/selectors/index.js +var require_selectors$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/selectors/index.js"(exports) { + exports.__esModule = true; + var _types$29 = require_types$3(); + Object.keys(_types$29).forEach(function(key) { + if (key === "default" || key === "__esModule") return; + if (key in exports && exports[key] === _types$29[key]) return; + exports[key] = _types$29[key]; + }); + var _constructors$2 = require_constructors$2(); + Object.keys(_constructors$2).forEach(function(key) { + if (key === "default" || key === "__esModule") return; + if (key in exports && exports[key] === _constructors$2[key]) return; + exports[key] = _constructors$2[key]; + }); + var _guards$2 = require_guards$2(); + Object.keys(_guards$2).forEach(function(key) { + if (key === "default" || key === "__esModule") return; + if (key in exports && exports[key] === _guards$2[key]) return; + exports[key] = _guards$2[key]; + }); +} }); + +//#endregion +//#region node_modules/postcss-selector-parser/dist/index.js +var require_dist$2 = __commonJS({ "node_modules/postcss-selector-parser/dist/index.js"(exports, module) { + exports.__esModule = true; + exports["default"] = void 0; + var _processor$2 = _interopRequireDefault$60(require_processor$2()); + var selectors$2 = _interopRequireWildcard$11(require_selectors$2()); + function _getRequireWildcardCache$8(nodeInterop) { + if (typeof WeakMap !== "function") return null; + var cacheBabelInterop = new WeakMap(); + var cacheNodeInterop = new WeakMap(); + return (_getRequireWildcardCache$8 = function _getRequireWildcardCache$12(nodeInterop$1) { + return nodeInterop$1 ? cacheNodeInterop : cacheBabelInterop; + })(nodeInterop); + } + function _interopRequireWildcard$11(obj, nodeInterop) { + if (!nodeInterop && obj && obj.__esModule) return obj; + if (obj === null || typeof obj !== "object" && typeof obj !== "function") return { "default": obj }; + var cache$3 = _getRequireWildcardCache$8(nodeInterop); + if (cache$3 && cache$3.has(obj)) return cache$3.get(obj); + var newObj = {}; + var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; + for (var key in obj) if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { + var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; + if (desc && (desc.get || desc.set)) Object.defineProperty(newObj, key, desc); + else newObj[key] = obj[key]; + } + newObj["default"] = obj; + if (cache$3) cache$3.set(obj, newObj); + return newObj; + } + function _interopRequireDefault$60(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + var parser$3 = function parser$4(processor) { + return new _processor$2["default"](processor); + }; + Object.assign(parser$3, selectors$2); + delete parser$3.__esModule; + var _default$13 = parser$3; + exports["default"] = _default$13; + module.exports = exports.default; +} }); +var import_dist = __toESM(require_dist$2()); + +//#endregion +//#region node_modules/merge-source-map/index.js +var require_merge_source_map = __commonJS({ "node_modules/merge-source-map/index.js"(exports, module) { + var sourceMap$1 = require_source_map$1(); + var SourceMapConsumer = sourceMap$1.SourceMapConsumer; + var SourceMapGenerator = sourceMap$1.SourceMapGenerator; + module.exports = merge$3; + /** + * Merge old source map and new source map and return merged. + * If old or new source map value is falsy, return another one as it is. + * + * @param {object|string} [oldMap] old source map object + * @param {object|string} [newmap] new source map object + * @return {object|undefined} merged source map object, or undefined when both old and new source map are undefined + */ + function merge$3(oldMap, newMap) { + if (!oldMap) return newMap; + if (!newMap) return oldMap; + var oldMapConsumer = new SourceMapConsumer(oldMap); + var newMapConsumer = new SourceMapConsumer(newMap); + var mergedMapGenerator = new SourceMapGenerator(); + newMapConsumer.eachMapping(function(m$2) { + if (m$2.originalLine == null) return; + var origPosInOldMap = oldMapConsumer.originalPositionFor({ + line: m$2.originalLine, + column: m$2.originalColumn + }); + if (origPosInOldMap.source == null) return; + mergedMapGenerator.addMapping({ + original: { + line: origPosInOldMap.line, + column: origPosInOldMap.column + }, + generated: { + line: m$2.generatedLine, + column: m$2.generatedColumn + }, + source: origPosInOldMap.source, + name: origPosInOldMap.name + }); + }); + var consumers = [oldMapConsumer, newMapConsumer]; + consumers.forEach(function(consumer) { + consumer.sources.forEach(function(sourceFile) { + mergedMapGenerator._sources.add(sourceFile); + var sourceContent = consumer.sourceContentFor(sourceFile); + if (sourceContent != null) mergedMapGenerator.setSourceContent(sourceFile, sourceContent); + }); + }); + mergedMapGenerator._sourceRoot = oldMap.sourceRoot; + mergedMapGenerator._file = oldMap.file; + return JSON.parse(mergedMapGenerator.toString()); + } +} }); + +//#endregion +//#region node_modules/sourcemap-codec/dist/sourcemap-codec.es.js +function encode$1(decoded) { + var sourceFileIndex = 0; + var sourceCodeLine = 0; + var sourceCodeColumn = 0; + var nameIndex = 0; + var mappings$1 = ""; + for (var i$5 = 0; i$5 < decoded.length; i$5++) { + var line = decoded[i$5]; + if (i$5 > 0) mappings$1 += ";"; + if (line.length === 0) continue; + var generatedCodeColumn = 0; + var lineMappings = []; + for (var _i = 0, line_1 = line; _i < line_1.length; _i++) { + var segment = line_1[_i]; + var segmentMappings = encodeInteger(segment[0] - generatedCodeColumn); + generatedCodeColumn = segment[0]; + if (segment.length > 1) { + segmentMappings += encodeInteger(segment[1] - sourceFileIndex) + encodeInteger(segment[2] - sourceCodeLine) + encodeInteger(segment[3] - sourceCodeColumn); + sourceFileIndex = segment[1]; + sourceCodeLine = segment[2]; + sourceCodeColumn = segment[3]; + } + if (segment.length === 5) { + segmentMappings += encodeInteger(segment[4] - nameIndex); + nameIndex = segment[4]; + } + lineMappings.push(segmentMappings); + } + mappings$1 += lineMappings.join(","); + } + return mappings$1; +} +function encodeInteger(num) { + var result$1 = ""; + num = num < 0 ? -num << 1 | 1 : num << 1; + do { + var clamped = num & 31; + num >>>= 5; + if (num > 0) clamped |= 32; + result$1 += chars[clamped]; + } while (num > 0); + return result$1; +} +var charToInteger, chars; +var init_sourcemap_codec_es = __esm({ "node_modules/sourcemap-codec/dist/sourcemap-codec.es.js"() { + charToInteger = {}; + chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="; + for (var i$3 = 0; i$3 < chars.length; i$3++) charToInteger[chars.charCodeAt(i$3)] = i$3; +} }); + +//#endregion +//#region node_modules/magic-string/dist/magic-string.es.js +var magic_string_es_exports = {}; +__export(magic_string_es_exports, { + Bundle: () => Bundle, + SourceMap: () => SourceMap$2, + default: () => MagicString$1 +}); +function guessIndent(code$1) { + var lines = code$1.split("\n"); + var tabbed = lines.filter(function(line) { + return /^\t+/.test(line); + }); + var spaced = lines.filter(function(line) { + return /^ {2,}/.test(line); + }); + if (tabbed.length === 0 && spaced.length === 0) return null; + if (tabbed.length >= spaced.length) return " "; + var min$1 = spaced.reduce(function(previous, current) { + var numSpaces = /^ +/.exec(current)[0].length; + return Math.min(numSpaces, previous); + }, Infinity); + return new Array(min$1 + 1).join(" "); +} +function getRelativePath(from, to) { + var fromParts = from.split(/[/\\]/); + var toParts = to.split(/[/\\]/); + fromParts.pop(); + while (fromParts[0] === toParts[0]) { + fromParts.shift(); + toParts.shift(); + } + if (fromParts.length) { + var i$5 = fromParts.length; + while (i$5--) fromParts[i$5] = ".."; + } + return fromParts.concat(toParts).join("/"); +} +function isObject$3(thing) { + return toString$4.call(thing) === "[object Object]"; +} +function getLocator(source) { + var originalLines = source.split("\n"); + var lineOffsets = []; + for (var i$5 = 0, pos = 0; i$5 < originalLines.length; i$5++) { + lineOffsets.push(pos); + pos += originalLines[i$5].length + 1; + } + return function locate(index$1) { + var i$6 = 0; + var j = lineOffsets.length; + while (i$6 < j) { + var m$2 = i$6 + j >> 1; + if (index$1 < lineOffsets[m$2]) j = m$2; + else i$6 = m$2 + 1; + } + var line = i$6 - 1; + var column = index$1 - lineOffsets[line]; + return { + line, + column + }; + }; +} +var BitSet, Chunk, btoa, SourceMap$2, toString$4, Mappings, n$2, warned, MagicString$1, hasOwnProp, Bundle; +var init_magic_string_es = __esm({ "node_modules/magic-string/dist/magic-string.es.js"() { + init_sourcemap_codec_es(); + BitSet = function BitSet$1(arg) { + this.bits = arg instanceof BitSet$1 ? arg.bits.slice() : []; + }; + BitSet.prototype.add = function add(n$3) { + this.bits[n$3 >> 5] |= 1 << (n$3 & 31); + }; + BitSet.prototype.has = function has$3(n$3) { + return !!(this.bits[n$3 >> 5] & 1 << (n$3 & 31)); + }; + Chunk = function Chunk$1(start, end, content) { + this.start = start; + this.end = end; + this.original = content; + this.intro = ""; + this.outro = ""; + this.content = content; + this.storeName = false; + this.edited = false; + Object.defineProperties(this, { + previous: { + writable: true, + value: null + }, + next: { + writable: true, + value: null + } + }); + }; + Chunk.prototype.appendLeft = function appendLeft(content) { + this.outro += content; + }; + Chunk.prototype.appendRight = function appendRight(content) { + this.intro = this.intro + content; + }; + Chunk.prototype.clone = function clone$5() { + var chunk$1 = new Chunk(this.start, this.end, this.original); + chunk$1.intro = this.intro; + chunk$1.outro = this.outro; + chunk$1.content = this.content; + chunk$1.storeName = this.storeName; + chunk$1.edited = this.edited; + return chunk$1; + }; + Chunk.prototype.contains = function contains$1(index$1) { + return this.start < index$1 && index$1 < this.end; + }; + Chunk.prototype.eachNext = function eachNext(fn) { + var chunk$1 = this; + while (chunk$1) { + fn(chunk$1); + chunk$1 = chunk$1.next; + } + }; + Chunk.prototype.eachPrevious = function eachPrevious(fn) { + var chunk$1 = this; + while (chunk$1) { + fn(chunk$1); + chunk$1 = chunk$1.previous; + } + }; + Chunk.prototype.edit = function edit(content, storeName, contentOnly) { + this.content = content; + if (!contentOnly) { + this.intro = ""; + this.outro = ""; + } + this.storeName = storeName; + this.edited = true; + return this; + }; + Chunk.prototype.prependLeft = function prependLeft(content) { + this.outro = content + this.outro; + }; + Chunk.prototype.prependRight = function prependRight(content) { + this.intro = content + this.intro; + }; + Chunk.prototype.split = function split(index$1) { + var sliceIndex = index$1 - this.start; + var originalBefore = this.original.slice(0, sliceIndex); + var originalAfter = this.original.slice(sliceIndex); + this.original = originalBefore; + var newChunk = new Chunk(index$1, this.end, originalAfter); + newChunk.outro = this.outro; + this.outro = ""; + this.end = index$1; + if (this.edited) { + newChunk.edit("", false); + this.content = ""; + } else this.content = originalBefore; + newChunk.next = this.next; + if (newChunk.next) newChunk.next.previous = newChunk; + newChunk.previous = this; + this.next = newChunk; + return newChunk; + }; + Chunk.prototype.toString = function toString$6() { + return this.intro + this.content + this.outro; + }; + Chunk.prototype.trimEnd = function trimEnd(rx) { + this.outro = this.outro.replace(rx, ""); + if (this.outro.length) return true; + var trimmed = this.content.replace(rx, ""); + if (trimmed.length) { + if (trimmed !== this.content) this.split(this.start + trimmed.length).edit("", void 0, true); + return true; + } else { + this.edit("", void 0, true); + this.intro = this.intro.replace(rx, ""); + if (this.intro.length) return true; + } + }; + Chunk.prototype.trimStart = function trimStart(rx) { + this.intro = this.intro.replace(rx, ""); + if (this.intro.length) return true; + var trimmed = this.content.replace(rx, ""); + if (trimmed.length) { + if (trimmed !== this.content) { + this.split(this.end - trimmed.length); + this.edit("", void 0, true); + } + return true; + } else { + this.edit("", void 0, true); + this.outro = this.outro.replace(rx, ""); + if (this.outro.length) return true; + } + }; + btoa = function() { + throw new Error("Unsupported environment: `window.btoa` or `Buffer` should be supported."); + }; + if (typeof window !== "undefined" && typeof window.btoa === "function") btoa = function(str$3) { + return window.btoa(unescape(encodeURIComponent(str$3))); + }; + else if (typeof Buffer === "function") btoa = function(str$3) { + return Buffer.from(str$3, "utf-8").toString("base64"); + }; + SourceMap$2 = function SourceMap$3(properties) { + this.version = 3; + this.file = properties.file; + this.sources = properties.sources; + this.sourcesContent = properties.sourcesContent; + this.names = properties.names; + this.mappings = encode$1(properties.mappings); + }; + SourceMap$2.prototype.toString = function toString$6() { + return JSON.stringify(this); + }; + SourceMap$2.prototype.toUrl = function toUrl() { + return "data:application/json;charset=utf-8;base64," + btoa(this.toString()); + }; + toString$4 = Object.prototype.toString; + Mappings = function Mappings$1(hires) { + this.hires = hires; + this.generatedCodeLine = 0; + this.generatedCodeColumn = 0; + this.raw = []; + this.rawSegments = this.raw[this.generatedCodeLine] = []; + this.pending = null; + }; + Mappings.prototype.addEdit = function addEdit(sourceIndex, content, loc, nameIndex) { + if (content.length) { + var segment = [ + this.generatedCodeColumn, + sourceIndex, + loc.line, + loc.column + ]; + if (nameIndex >= 0) segment.push(nameIndex); + this.rawSegments.push(segment); + } else if (this.pending) this.rawSegments.push(this.pending); + this.advance(content); + this.pending = null; + }; + Mappings.prototype.addUneditedChunk = function addUneditedChunk(sourceIndex, chunk$1, original, loc, sourcemapLocations) { + var originalCharIndex = chunk$1.start; + var first$1 = true; + while (originalCharIndex < chunk$1.end) { + if (this.hires || first$1 || sourcemapLocations.has(originalCharIndex)) this.rawSegments.push([ + this.generatedCodeColumn, + sourceIndex, + loc.line, + loc.column + ]); + if (original[originalCharIndex] === "\n") { + loc.line += 1; + loc.column = 0; + this.generatedCodeLine += 1; + this.raw[this.generatedCodeLine] = this.rawSegments = []; + this.generatedCodeColumn = 0; + first$1 = true; + } else { + loc.column += 1; + this.generatedCodeColumn += 1; + first$1 = false; + } + originalCharIndex += 1; + } + this.pending = null; + }; + Mappings.prototype.advance = function advance(str$3) { + if (!str$3) return; + var lines = str$3.split("\n"); + if (lines.length > 1) { + for (var i$5 = 0; i$5 < lines.length - 1; i$5++) { + this.generatedCodeLine++; + this.raw[this.generatedCodeLine] = this.rawSegments = []; + } + this.generatedCodeColumn = 0; + } + this.generatedCodeColumn += lines[lines.length - 1].length; + }; + n$2 = "\n"; + warned = { + insertLeft: false, + insertRight: false, + storeName: false + }; + MagicString$1 = function MagicString$2(string$3, options) { + if (options === void 0) options = {}; + var chunk$1 = new Chunk(0, string$3.length, string$3); + Object.defineProperties(this, { + original: { + writable: true, + value: string$3 + }, + outro: { + writable: true, + value: "" + }, + intro: { + writable: true, + value: "" + }, + firstChunk: { + writable: true, + value: chunk$1 + }, + lastChunk: { + writable: true, + value: chunk$1 + }, + lastSearchedChunk: { + writable: true, + value: chunk$1 + }, + byStart: { + writable: true, + value: {} + }, + byEnd: { + writable: true, + value: {} + }, + filename: { + writable: true, + value: options.filename + }, + indentExclusionRanges: { + writable: true, + value: options.indentExclusionRanges + }, + sourcemapLocations: { + writable: true, + value: new BitSet() + }, + storedNames: { + writable: true, + value: {} + }, + indentStr: { + writable: true, + value: guessIndent(string$3) + } + }); + this.byStart[0] = chunk$1; + this.byEnd[string$3.length] = chunk$1; + }; + MagicString$1.prototype.addSourcemapLocation = function addSourcemapLocation(char) { + this.sourcemapLocations.add(char); + }; + MagicString$1.prototype.append = function append$1(content) { + if (typeof content !== "string") throw new TypeError("outro content must be a string"); + this.outro += content; + return this; + }; + MagicString$1.prototype.appendLeft = function appendLeft(index$1, content) { + if (typeof content !== "string") throw new TypeError("inserted content must be a string"); + this._split(index$1); + var chunk$1 = this.byEnd[index$1]; + if (chunk$1) chunk$1.appendLeft(content); + else this.intro += content; + return this; + }; + MagicString$1.prototype.appendRight = function appendRight(index$1, content) { + if (typeof content !== "string") throw new TypeError("inserted content must be a string"); + this._split(index$1); + var chunk$1 = this.byStart[index$1]; + if (chunk$1) chunk$1.appendRight(content); + else this.outro += content; + return this; + }; + MagicString$1.prototype.clone = function clone$5() { + var cloned = new MagicString$1(this.original, { filename: this.filename }); + var originalChunk = this.firstChunk; + var clonedChunk = cloned.firstChunk = cloned.lastSearchedChunk = originalChunk.clone(); + while (originalChunk) { + cloned.byStart[clonedChunk.start] = clonedChunk; + cloned.byEnd[clonedChunk.end] = clonedChunk; + var nextOriginalChunk = originalChunk.next; + var nextClonedChunk = nextOriginalChunk && nextOriginalChunk.clone(); + if (nextClonedChunk) { + clonedChunk.next = nextClonedChunk; + nextClonedChunk.previous = clonedChunk; + clonedChunk = nextClonedChunk; + } + originalChunk = nextOriginalChunk; + } + cloned.lastChunk = clonedChunk; + if (this.indentExclusionRanges) cloned.indentExclusionRanges = this.indentExclusionRanges.slice(); + cloned.sourcemapLocations = new BitSet(this.sourcemapLocations); + cloned.intro = this.intro; + cloned.outro = this.outro; + return cloned; + }; + MagicString$1.prototype.generateDecodedMap = function generateDecodedMap(options) { + var this$1$1 = this; + options = options || {}; + var sourceIndex = 0; + var names = Object.keys(this.storedNames); + var mappings$1 = new Mappings(options.hires); + var locate = getLocator(this.original); + if (this.intro) mappings$1.advance(this.intro); + this.firstChunk.eachNext(function(chunk$1) { + var loc = locate(chunk$1.start); + if (chunk$1.intro.length) mappings$1.advance(chunk$1.intro); + if (chunk$1.edited) mappings$1.addEdit(sourceIndex, chunk$1.content, loc, chunk$1.storeName ? names.indexOf(chunk$1.original) : -1); + else mappings$1.addUneditedChunk(sourceIndex, chunk$1, this$1$1.original, loc, this$1$1.sourcemapLocations); + if (chunk$1.outro.length) mappings$1.advance(chunk$1.outro); + }); + return { + file: options.file ? options.file.split(/[/\\]/).pop() : null, + sources: [options.source ? getRelativePath(options.file || "", options.source) : null], + sourcesContent: options.includeContent ? [this.original] : [null], + names, + mappings: mappings$1.raw + }; + }; + MagicString$1.prototype.generateMap = function generateMap(options) { + return new SourceMap$2(this.generateDecodedMap(options)); + }; + MagicString$1.prototype.getIndentString = function getIndentString() { + return this.indentStr === null ? " " : this.indentStr; + }; + MagicString$1.prototype.indent = function indent(indentStr, options) { + var pattern = /^[^\r\n]/gm; + if (isObject$3(indentStr)) { + options = indentStr; + indentStr = void 0; + } + indentStr = indentStr !== void 0 ? indentStr : this.indentStr || " "; + if (indentStr === "") return this; + options = options || {}; + var isExcluded = {}; + if (options.exclude) { + var exclusions = typeof options.exclude[0] === "number" ? [options.exclude] : options.exclude; + exclusions.forEach(function(exclusion) { + for (var i$5 = exclusion[0]; i$5 < exclusion[1]; i$5 += 1) isExcluded[i$5] = true; + }); + } + var shouldIndentNextCharacter = options.indentStart !== false; + var replacer$1 = function(match) { + if (shouldIndentNextCharacter) return "" + indentStr + match; + shouldIndentNextCharacter = true; + return match; + }; + this.intro = this.intro.replace(pattern, replacer$1); + var charIndex = 0; + var chunk$1 = this.firstChunk; + while (chunk$1) { + var end = chunk$1.end; + if (chunk$1.edited) { + if (!isExcluded[charIndex]) { + chunk$1.content = chunk$1.content.replace(pattern, replacer$1); + if (chunk$1.content.length) shouldIndentNextCharacter = chunk$1.content[chunk$1.content.length - 1] === "\n"; + } + } else { + charIndex = chunk$1.start; + while (charIndex < end) { + if (!isExcluded[charIndex]) { + var char = this.original[charIndex]; + if (char === "\n") shouldIndentNextCharacter = true; + else if (char !== "\r" && shouldIndentNextCharacter) { + shouldIndentNextCharacter = false; + if (charIndex === chunk$1.start) chunk$1.prependRight(indentStr); + else { + this._splitChunk(chunk$1, charIndex); + chunk$1 = chunk$1.next; + chunk$1.prependRight(indentStr); + } + } + } + charIndex += 1; + } + } + charIndex = chunk$1.end; + chunk$1 = chunk$1.next; + } + this.outro = this.outro.replace(pattern, replacer$1); + return this; + }; + MagicString$1.prototype.insert = function insert$1() { + throw new Error("magicString.insert(...) is deprecated. Use prependRight(...) or appendLeft(...)"); + }; + MagicString$1.prototype.insertLeft = function insertLeft(index$1, content) { + if (!warned.insertLeft) { + console.warn("magicString.insertLeft(...) is deprecated. Use magicString.appendLeft(...) instead"); + warned.insertLeft = true; + } + return this.appendLeft(index$1, content); + }; + MagicString$1.prototype.insertRight = function insertRight(index$1, content) { + if (!warned.insertRight) { + console.warn("magicString.insertRight(...) is deprecated. Use magicString.prependRight(...) instead"); + warned.insertRight = true; + } + return this.prependRight(index$1, content); + }; + MagicString$1.prototype.move = function move$1(start, end, index$1) { + if (index$1 >= start && index$1 <= end) throw new Error("Cannot move a selection inside itself"); + this._split(start); + this._split(end); + this._split(index$1); + var first$1 = this.byStart[start]; + var last$3 = this.byEnd[end]; + var oldLeft = first$1.previous; + var oldRight = last$3.next; + var newRight = this.byStart[index$1]; + if (!newRight && last$3 === this.lastChunk) return this; + var newLeft = newRight ? newRight.previous : this.lastChunk; + if (oldLeft) oldLeft.next = oldRight; + if (oldRight) oldRight.previous = oldLeft; + if (newLeft) newLeft.next = first$1; + if (newRight) newRight.previous = last$3; + if (!first$1.previous) this.firstChunk = last$3.next; + if (!last$3.next) { + this.lastChunk = first$1.previous; + this.lastChunk.next = null; + } + first$1.previous = newLeft; + last$3.next = newRight || null; + if (!newLeft) this.firstChunk = first$1; + if (!newRight) this.lastChunk = last$3; + return this; + }; + MagicString$1.prototype.overwrite = function overwrite(start, end, content, options) { + if (typeof content !== "string") throw new TypeError("replacement content must be a string"); + while (start < 0) start += this.original.length; + while (end < 0) end += this.original.length; + if (end > this.original.length) throw new Error("end is out of bounds"); + if (start === end) throw new Error("Cannot overwrite a zero-length range – use appendLeft or prependRight instead"); + this._split(start); + this._split(end); + if (options === true) { + if (!warned.storeName) { + console.warn("The final argument to magicString.overwrite(...) should be an options object. See https://github.com/rich-harris/magic-string"); + warned.storeName = true; + } + options = { storeName: true }; + } + var storeName = options !== void 0 ? options.storeName : false; + var contentOnly = options !== void 0 ? options.contentOnly : false; + if (storeName) { + var original = this.original.slice(start, end); + Object.defineProperty(this.storedNames, original, { + writable: true, + value: true, + enumerable: true + }); + } + var first$1 = this.byStart[start]; + var last$3 = this.byEnd[end]; + if (first$1) { + var chunk$1 = first$1; + while (chunk$1 !== last$3) { + if (chunk$1.next !== this.byStart[chunk$1.end]) throw new Error("Cannot overwrite across a split point"); + chunk$1 = chunk$1.next; + chunk$1.edit("", false); + } + first$1.edit(content, storeName, contentOnly); + } else { + var newChunk = new Chunk(start, end, "").edit(content, storeName); + last$3.next = newChunk; + newChunk.previous = last$3; + } + return this; + }; + MagicString$1.prototype.prepend = function prepend$1(content) { + if (typeof content !== "string") throw new TypeError("outro content must be a string"); + this.intro = content + this.intro; + return this; + }; + MagicString$1.prototype.prependLeft = function prependLeft(index$1, content) { + if (typeof content !== "string") throw new TypeError("inserted content must be a string"); + this._split(index$1); + var chunk$1 = this.byEnd[index$1]; + if (chunk$1) chunk$1.prependLeft(content); + else this.intro = content + this.intro; + return this; + }; + MagicString$1.prototype.prependRight = function prependRight(index$1, content) { + if (typeof content !== "string") throw new TypeError("inserted content must be a string"); + this._split(index$1); + var chunk$1 = this.byStart[index$1]; + if (chunk$1) chunk$1.prependRight(content); + else this.outro = content + this.outro; + return this; + }; + MagicString$1.prototype.remove = function remove$4(start, end) { + while (start < 0) start += this.original.length; + while (end < 0) end += this.original.length; + if (start === end) return this; + if (start < 0 || end > this.original.length) throw new Error("Character is out of bounds"); + if (start > end) throw new Error("end must be greater than start"); + this._split(start); + this._split(end); + var chunk$1 = this.byStart[start]; + while (chunk$1) { + chunk$1.intro = ""; + chunk$1.outro = ""; + chunk$1.edit(""); + chunk$1 = end > chunk$1.end ? this.byStart[chunk$1.end] : null; + } + return this; + }; + MagicString$1.prototype.lastChar = function lastChar() { + if (this.outro.length) return this.outro[this.outro.length - 1]; + var chunk$1 = this.lastChunk; + do { + if (chunk$1.outro.length) return chunk$1.outro[chunk$1.outro.length - 1]; + if (chunk$1.content.length) return chunk$1.content[chunk$1.content.length - 1]; + if (chunk$1.intro.length) return chunk$1.intro[chunk$1.intro.length - 1]; + } while (chunk$1 = chunk$1.previous); + if (this.intro.length) return this.intro[this.intro.length - 1]; + return ""; + }; + MagicString$1.prototype.lastLine = function lastLine() { + var lineIndex = this.outro.lastIndexOf(n$2); + if (lineIndex !== -1) return this.outro.substr(lineIndex + 1); + var lineStr = this.outro; + var chunk$1 = this.lastChunk; + do { + if (chunk$1.outro.length > 0) { + lineIndex = chunk$1.outro.lastIndexOf(n$2); + if (lineIndex !== -1) return chunk$1.outro.substr(lineIndex + 1) + lineStr; + lineStr = chunk$1.outro + lineStr; + } + if (chunk$1.content.length > 0) { + lineIndex = chunk$1.content.lastIndexOf(n$2); + if (lineIndex !== -1) return chunk$1.content.substr(lineIndex + 1) + lineStr; + lineStr = chunk$1.content + lineStr; + } + if (chunk$1.intro.length > 0) { + lineIndex = chunk$1.intro.lastIndexOf(n$2); + if (lineIndex !== -1) return chunk$1.intro.substr(lineIndex + 1) + lineStr; + lineStr = chunk$1.intro + lineStr; + } + } while (chunk$1 = chunk$1.previous); + lineIndex = this.intro.lastIndexOf(n$2); + if (lineIndex !== -1) return this.intro.substr(lineIndex + 1) + lineStr; + return this.intro + lineStr; + }; + MagicString$1.prototype.slice = function slice$3(start, end) { + if (start === void 0) start = 0; + if (end === void 0) end = this.original.length; + while (start < 0) start += this.original.length; + while (end < 0) end += this.original.length; + var result$1 = ""; + var chunk$1 = this.firstChunk; + while (chunk$1 && (chunk$1.start > start || chunk$1.end <= start)) { + if (chunk$1.start < end && chunk$1.end >= end) return result$1; + chunk$1 = chunk$1.next; + } + if (chunk$1 && chunk$1.edited && chunk$1.start !== start) throw new Error("Cannot use replaced character " + start + " as slice start anchor."); + var startChunk = chunk$1; + while (chunk$1) { + if (chunk$1.intro && (startChunk !== chunk$1 || chunk$1.start === start)) result$1 += chunk$1.intro; + var containsEnd = chunk$1.start < end && chunk$1.end >= end; + if (containsEnd && chunk$1.edited && chunk$1.end !== end) throw new Error("Cannot use replaced character " + end + " as slice end anchor."); + var sliceStart = startChunk === chunk$1 ? start - chunk$1.start : 0; + var sliceEnd = containsEnd ? chunk$1.content.length + end - chunk$1.end : chunk$1.content.length; + result$1 += chunk$1.content.slice(sliceStart, sliceEnd); + if (chunk$1.outro && (!containsEnd || chunk$1.end === end)) result$1 += chunk$1.outro; + if (containsEnd) break; + chunk$1 = chunk$1.next; + } + return result$1; + }; + MagicString$1.prototype.snip = function snip(start, end) { + var clone$5 = this.clone(); + clone$5.remove(0, start); + clone$5.remove(end, clone$5.original.length); + return clone$5; + }; + MagicString$1.prototype._split = function _split(index$1) { + if (this.byStart[index$1] || this.byEnd[index$1]) return; + var chunk$1 = this.lastSearchedChunk; + var searchForward = index$1 > chunk$1.end; + while (chunk$1) { + if (chunk$1.contains(index$1)) return this._splitChunk(chunk$1, index$1); + chunk$1 = searchForward ? this.byStart[chunk$1.end] : this.byEnd[chunk$1.start]; + } + }; + MagicString$1.prototype._splitChunk = function _splitChunk(chunk$1, index$1) { + if (chunk$1.edited && chunk$1.content.length) { + var loc = getLocator(this.original)(index$1); + throw new Error("Cannot split a chunk that has already been edited (" + loc.line + ":" + loc.column + " – \"" + chunk$1.original + "\")"); + } + var newChunk = chunk$1.split(index$1); + this.byEnd[index$1] = chunk$1; + this.byStart[index$1] = newChunk; + this.byEnd[newChunk.end] = newChunk; + if (chunk$1 === this.lastChunk) this.lastChunk = newChunk; + this.lastSearchedChunk = chunk$1; + return true; + }; + MagicString$1.prototype.toString = function toString$6() { + var str$3 = this.intro; + var chunk$1 = this.firstChunk; + while (chunk$1) { + str$3 += chunk$1.toString(); + chunk$1 = chunk$1.next; + } + return str$3 + this.outro; + }; + MagicString$1.prototype.isEmpty = function isEmpty$2() { + var chunk$1 = this.firstChunk; + do + if (chunk$1.intro.length && chunk$1.intro.trim() || chunk$1.content.length && chunk$1.content.trim() || chunk$1.outro.length && chunk$1.outro.trim()) return false; + while (chunk$1 = chunk$1.next); + return true; + }; + MagicString$1.prototype.length = function length() { + var chunk$1 = this.firstChunk; + var length$1 = 0; + do + length$1 += chunk$1.intro.length + chunk$1.content.length + chunk$1.outro.length; + while (chunk$1 = chunk$1.next); + return length$1; + }; + MagicString$1.prototype.trimLines = function trimLines() { + return this.trim("[\\r\\n]"); + }; + MagicString$1.prototype.trim = function trim$1(charType) { + return this.trimStart(charType).trimEnd(charType); + }; + MagicString$1.prototype.trimEndAborted = function trimEndAborted(charType) { + var rx = new RegExp((charType || "\\s") + "+$"); + this.outro = this.outro.replace(rx, ""); + if (this.outro.length) return true; + var chunk$1 = this.lastChunk; + do { + var end = chunk$1.end; + var aborted = chunk$1.trimEnd(rx); + if (chunk$1.end !== end) { + if (this.lastChunk === chunk$1) this.lastChunk = chunk$1.next; + this.byEnd[chunk$1.end] = chunk$1; + this.byStart[chunk$1.next.start] = chunk$1.next; + this.byEnd[chunk$1.next.end] = chunk$1.next; + } + if (aborted) return true; + chunk$1 = chunk$1.previous; + } while (chunk$1); + return false; + }; + MagicString$1.prototype.trimEnd = function trimEnd(charType) { + this.trimEndAborted(charType); + return this; + }; + MagicString$1.prototype.trimStartAborted = function trimStartAborted(charType) { + var rx = new RegExp("^" + (charType || "\\s") + "+"); + this.intro = this.intro.replace(rx, ""); + if (this.intro.length) return true; + var chunk$1 = this.firstChunk; + do { + var end = chunk$1.end; + var aborted = chunk$1.trimStart(rx); + if (chunk$1.end !== end) { + if (chunk$1 === this.lastChunk) this.lastChunk = chunk$1.next; + this.byEnd[chunk$1.end] = chunk$1; + this.byStart[chunk$1.next.start] = chunk$1.next; + this.byEnd[chunk$1.next.end] = chunk$1.next; + } + if (aborted) return true; + chunk$1 = chunk$1.next; + } while (chunk$1); + return false; + }; + MagicString$1.prototype.trimStart = function trimStart(charType) { + this.trimStartAborted(charType); + return this; + }; + hasOwnProp = Object.prototype.hasOwnProperty; + Bundle = function Bundle$1(options) { + if (options === void 0) options = {}; + this.intro = options.intro || ""; + this.separator = options.separator !== void 0 ? options.separator : "\n"; + this.sources = []; + this.uniqueSources = []; + this.uniqueSourceIndexByFilename = {}; + }; + Bundle.prototype.addSource = function addSource(source) { + if (source instanceof MagicString$1) return this.addSource({ + content: source, + filename: source.filename, + separator: this.separator + }); + if (!isObject$3(source) || !source.content) throw new Error("bundle.addSource() takes an object with a `content` property, which should be an instance of MagicString, and an optional `filename`"); + [ + "filename", + "indentExclusionRanges", + "separator" + ].forEach(function(option) { + if (!hasOwnProp.call(source, option)) source[option] = source.content[option]; + }); + if (source.separator === void 0) source.separator = this.separator; + if (source.filename) if (!hasOwnProp.call(this.uniqueSourceIndexByFilename, source.filename)) { + this.uniqueSourceIndexByFilename[source.filename] = this.uniqueSources.length; + this.uniqueSources.push({ + filename: source.filename, + content: source.content.original + }); + } else { + var uniqueSource = this.uniqueSources[this.uniqueSourceIndexByFilename[source.filename]]; + if (source.content.original !== uniqueSource.content) throw new Error("Illegal source: same filename (" + source.filename + "), different contents"); + } + this.sources.push(source); + return this; + }; + Bundle.prototype.append = function append$1(str$3, options) { + this.addSource({ + content: new MagicString$1(str$3), + separator: options && options.separator || "" + }); + return this; + }; + Bundle.prototype.clone = function clone$5() { + var bundle = new Bundle({ + intro: this.intro, + separator: this.separator + }); + this.sources.forEach(function(source) { + bundle.addSource({ + filename: source.filename, + content: source.content.clone(), + separator: source.separator + }); + }); + return bundle; + }; + Bundle.prototype.generateDecodedMap = function generateDecodedMap(options) { + var this$1$1 = this; + if (options === void 0) options = {}; + var names = []; + this.sources.forEach(function(source) { + Object.keys(source.content.storedNames).forEach(function(name) { + if (!~names.indexOf(name)) names.push(name); + }); + }); + var mappings$1 = new Mappings(options.hires); + if (this.intro) mappings$1.advance(this.intro); + this.sources.forEach(function(source, i$5) { + if (i$5 > 0) mappings$1.advance(this$1$1.separator); + var sourceIndex = source.filename ? this$1$1.uniqueSourceIndexByFilename[source.filename] : -1; + var magicString = source.content; + var locate = getLocator(magicString.original); + if (magicString.intro) mappings$1.advance(magicString.intro); + magicString.firstChunk.eachNext(function(chunk$1) { + var loc = locate(chunk$1.start); + if (chunk$1.intro.length) mappings$1.advance(chunk$1.intro); + if (source.filename) if (chunk$1.edited) mappings$1.addEdit(sourceIndex, chunk$1.content, loc, chunk$1.storeName ? names.indexOf(chunk$1.original) : -1); + else mappings$1.addUneditedChunk(sourceIndex, chunk$1, magicString.original, loc, magicString.sourcemapLocations); + else mappings$1.advance(chunk$1.content); + if (chunk$1.outro.length) mappings$1.advance(chunk$1.outro); + }); + if (magicString.outro) mappings$1.advance(magicString.outro); + }); + return { + file: options.file ? options.file.split(/[/\\]/).pop() : null, + sources: this.uniqueSources.map(function(source) { + return options.file ? getRelativePath(options.file, source.filename) : source.filename; + }), + sourcesContent: this.uniqueSources.map(function(source) { + return options.includeContent ? source.content : null; + }), + names, + mappings: mappings$1.raw + }; + }; + Bundle.prototype.generateMap = function generateMap(options) { + return new SourceMap$2(this.generateDecodedMap(options)); + }; + Bundle.prototype.getIndentString = function getIndentString() { + var indentStringCounts = {}; + this.sources.forEach(function(source) { + var indentStr = source.content.indentStr; + if (indentStr === null) return; + if (!indentStringCounts[indentStr]) indentStringCounts[indentStr] = 0; + indentStringCounts[indentStr] += 1; + }); + return Object.keys(indentStringCounts).sort(function(a, b$1) { + return indentStringCounts[a] - indentStringCounts[b$1]; + })[0] || " "; + }; + Bundle.prototype.indent = function indent(indentStr) { + var this$1$1 = this; + if (!arguments.length) indentStr = this.getIndentString(); + if (indentStr === "") return this; + var trailingNewline = !this.intro || this.intro.slice(-1) === "\n"; + this.sources.forEach(function(source, i$5) { + var separator = source.separator !== void 0 ? source.separator : this$1$1.separator; + var indentStart = trailingNewline || i$5 > 0 && /\r?\n$/.test(separator); + source.content.indent(indentStr, { + exclude: source.indentExclusionRanges, + indentStart + }); + trailingNewline = source.content.lastChar() === "\n"; + }); + if (this.intro) this.intro = indentStr + this.intro.replace(/^[^\n]/gm, function(match, index$1) { + return index$1 > 0 ? indentStr + match : match; + }); + return this; + }; + Bundle.prototype.prepend = function prepend$1(str$3) { + this.intro = str$3 + this.intro; + return this; + }; + Bundle.prototype.toString = function toString$6() { + var this$1$1 = this; + var body = this.sources.map(function(source, i$5) { + var separator = source.separator !== void 0 ? source.separator : this$1$1.separator; + var str$3 = (i$5 > 0 ? separator : "") + source.content.toString(); + return str$3; + }).join(""); + return this.intro + body; + }; + Bundle.prototype.isEmpty = function isEmpty$2() { + if (this.intro.length && this.intro.trim()) return false; + if (this.sources.some(function(source) { + return !source.content.isEmpty(); + })) return false; + return true; + }; + Bundle.prototype.length = function length() { + return this.sources.reduce(function(length$1, source) { + return length$1 + source.content.length(); + }, this.intro.length); + }; + Bundle.prototype.trimLines = function trimLines() { + return this.trim("[\\r\\n]"); + }; + Bundle.prototype.trim = function trim$1(charType) { + return this.trimStart(charType).trimEnd(charType); + }; + Bundle.prototype.trimStart = function trimStart(charType) { + var rx = new RegExp("^" + (charType || "\\s") + "+"); + this.intro = this.intro.replace(rx, ""); + if (!this.intro) { + var source; + var i$5 = 0; + do { + source = this.sources[i$5++]; + if (!source) break; + } while (!source.content.trimStartAborted(charType)); + } + return this; + }; + Bundle.prototype.trimEnd = function trimEnd(charType) { + var rx = new RegExp((charType || "\\s") + "+$"); + var source; + var i$5 = this.sources.length - 1; + do { + source = this.sources[i$5--]; + if (!source) { + this.intro = this.intro.replace(rx, ""); + break; + } + } while (!source.content.trimEndAborted(charType)); + return this; + }; +} }); + +//#endregion +//#region node_modules/@babel/parser/lib/index.js +var require_lib$16 = __commonJS({ "node_modules/@babel/parser/lib/index.js"(exports) { + Object.defineProperty(exports, "__esModule", { value: true }); + function _objectWithoutPropertiesLoose$1(r, e) { + if (null == r) return {}; + var t$7 = {}; + for (var n$3 in r) if ({}.hasOwnProperty.call(r, n$3)) { + if (-1 !== e.indexOf(n$3)) continue; + t$7[n$3] = r[n$3]; + } + return t$7; + } + var Position = class { + constructor(line, col, index$1) { + this.line = void 0; + this.column = void 0; + this.index = void 0; + this.line = line; + this.column = col; + this.index = index$1; + } + }; + var SourceLocation$1 = class { + constructor(start, end) { + this.start = void 0; + this.end = void 0; + this.filename = void 0; + this.identifierName = void 0; + this.start = start; + this.end = end; + } + }; + function createPositionWithColumnOffset(position, columnOffset) { + const { line, column, index: index$1 } = position; + return new Position(line, column + columnOffset, index$1 + columnOffset); + } + const code = "BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED"; + var ModuleErrors = { + ImportMetaOutsideModule: { + message: `import.meta may appear only with 'sourceType: "module"'`, + code + }, + ImportOutsideModule: { + message: `'import' and 'export' may appear only with 'sourceType: "module"'`, + code + } + }; + const NodeDescriptions = { + ArrayPattern: "array destructuring pattern", + AssignmentExpression: "assignment expression", + AssignmentPattern: "assignment expression", + ArrowFunctionExpression: "arrow function expression", + ConditionalExpression: "conditional expression", + CatchClause: "catch clause", + ForOfStatement: "for-of statement", + ForInStatement: "for-in statement", + ForStatement: "for-loop", + FormalParameters: "function parameter list", + Identifier: "identifier", + ImportSpecifier: "import specifier", + ImportDefaultSpecifier: "import default specifier", + ImportNamespaceSpecifier: "import namespace specifier", + ObjectPattern: "object destructuring pattern", + ParenthesizedExpression: "parenthesized expression", + RestElement: "rest element", + UpdateExpression: { + true: "prefix operation", + false: "postfix operation" + }, + VariableDeclarator: "variable declaration", + YieldExpression: "yield expression" + }; + const toNodeDescription = (node) => node.type === "UpdateExpression" ? NodeDescriptions.UpdateExpression[`${node.prefix}`] : NodeDescriptions[node.type]; + var StandardErrors = { + AccessorIsGenerator: ({ kind }) => `A ${kind}ter cannot be a generator.`, + ArgumentsInClass: "'arguments' is only allowed in functions and class methods.", + AsyncFunctionInSingleStatementContext: "Async functions can only be declared at the top level or inside a block.", + AwaitBindingIdentifier: "Can not use 'await' as identifier inside an async function.", + AwaitBindingIdentifierInStaticBlock: "Can not use 'await' as identifier inside a static block.", + AwaitExpressionFormalParameter: "'await' is not allowed in async function parameters.", + AwaitUsingNotInAsyncContext: "'await using' is only allowed within async functions and at the top levels of modules.", + AwaitNotInAsyncContext: "'await' is only allowed within async functions and at the top levels of modules.", + BadGetterArity: "A 'get' accessor must not have any formal parameters.", + BadSetterArity: "A 'set' accessor must have exactly one formal parameter.", + BadSetterRestParameter: "A 'set' accessor function argument must not be a rest parameter.", + ConstructorClassField: "Classes may not have a field named 'constructor'.", + ConstructorClassPrivateField: "Classes may not have a private field named '#constructor'.", + ConstructorIsAccessor: "Class constructor may not be an accessor.", + ConstructorIsAsync: "Constructor can't be an async function.", + ConstructorIsGenerator: "Constructor can't be a generator.", + DeclarationMissingInitializer: ({ kind }) => `Missing initializer in ${kind} declaration.`, + DecoratorArgumentsOutsideParentheses: "Decorator arguments must be moved inside parentheses: use '@(decorator(args))' instead of '@(decorator)(args)'.", + DecoratorBeforeExport: "Decorators must be placed *before* the 'export' keyword. Remove the 'decoratorsBeforeExport: true' option to use the 'export @decorator class {}' syntax.", + DecoratorsBeforeAfterExport: "Decorators can be placed *either* before or after the 'export' keyword, but not in both locations at the same time.", + DecoratorConstructor: "Decorators can't be used with a constructor. Did you mean '@dec class { ... }'?", + DecoratorExportClass: "Decorators must be placed *after* the 'export' keyword. Remove the 'decoratorsBeforeExport: false' option to use the '@decorator export class {}' syntax.", + DecoratorSemicolon: "Decorators must not be followed by a semicolon.", + DecoratorStaticBlock: "Decorators can't be used with a static block.", + DeferImportRequiresNamespace: "Only `import defer * as x from \"./module\"` is valid.", + DeletePrivateField: "Deleting a private field is not allowed.", + DestructureNamedImport: "ES2015 named imports do not destructure. Use another statement for destructuring after the import.", + DuplicateConstructor: "Duplicate constructor in the same class.", + DuplicateDefaultExport: "Only one default export allowed per module.", + DuplicateExport: ({ exportName }) => `\`${exportName}\` has already been exported. Exported identifiers must be unique.`, + DuplicateProto: "Redefinition of __proto__ property.", + DuplicateRegExpFlags: "Duplicate regular expression flag.", + DynamicImportPhaseRequiresImportExpressions: ({ phase }) => `'import.${phase}(...)' can only be parsed when using the 'createImportExpressions' option.`, + ElementAfterRest: "Rest element must be last element.", + EscapedCharNotAnIdentifier: "Invalid Unicode escape.", + ExportBindingIsString: ({ localName, exportName }) => `A string literal cannot be used as an exported binding without \`from\`.\n- Did you mean \`export { '${localName}' as '${exportName}' } from 'some-module'\`?`, + ExportDefaultFromAsIdentifier: "'from' is not allowed as an identifier after 'export default'.", + ForInOfLoopInitializer: ({ type }) => `'${type === "ForInStatement" ? "for-in" : "for-of"}' loop variable declaration may not have an initializer.`, + ForInUsing: "For-in loop may not start with 'using' declaration.", + ForOfAsync: "The left-hand side of a for-of loop may not be 'async'.", + ForOfLet: "The left-hand side of a for-of loop may not start with 'let'.", + GeneratorInSingleStatementContext: "Generators can only be declared at the top level or inside a block.", + IllegalBreakContinue: ({ type }) => `Unsyntactic ${type === "BreakStatement" ? "break" : "continue"}.`, + IllegalLanguageModeDirective: "Illegal 'use strict' directive in function with non-simple parameter list.", + IllegalReturn: "'return' outside of function.", + ImportAttributesUseAssert: "The `assert` keyword in import attributes is deprecated and it has been replaced by the `with` keyword. You can enable the `deprecatedImportAssert` parser plugin to suppress this error.", + ImportBindingIsString: ({ importName }) => `A string literal cannot be used as an imported binding.\n- Did you mean \`import { "${importName}" as foo }\`?`, + ImportCallArity: `\`import()\` requires exactly one or two arguments.`, + ImportCallNotNewExpression: "Cannot use new with import(...).", + ImportCallSpreadArgument: "`...` is not allowed in `import()`.", + ImportJSONBindingNotDefault: "A JSON module can only be imported with `default`.", + ImportReflectionHasAssertion: "`import module x` cannot have assertions.", + ImportReflectionNotBinding: "Only `import module x from \"./module\"` is valid.", + IncompatibleRegExpUVFlags: "The 'u' and 'v' regular expression flags cannot be enabled at the same time.", + InvalidBigIntLiteral: "Invalid BigIntLiteral.", + InvalidCodePoint: "Code point out of bounds.", + InvalidCoverInitializedName: "Invalid shorthand property initializer.", + InvalidDecimal: "Invalid decimal.", + InvalidDigit: ({ radix }) => `Expected number in radix ${radix}.`, + InvalidEscapeSequence: "Bad character escape sequence.", + InvalidEscapeSequenceTemplate: "Invalid escape sequence in template.", + InvalidEscapedReservedWord: ({ reservedWord }) => `Escape sequence in keyword ${reservedWord}.`, + InvalidIdentifier: ({ identifierName }) => `Invalid identifier ${identifierName}.`, + InvalidLhs: ({ ancestor }) => `Invalid left-hand side in ${toNodeDescription(ancestor)}.`, + InvalidLhsBinding: ({ ancestor }) => `Binding invalid left-hand side in ${toNodeDescription(ancestor)}.`, + InvalidLhsOptionalChaining: ({ ancestor }) => `Invalid optional chaining in the left-hand side of ${toNodeDescription(ancestor)}.`, + InvalidNumber: "Invalid number.", + InvalidOrMissingExponent: "Floating-point numbers require a valid exponent after the 'e'.", + InvalidOrUnexpectedToken: ({ unexpected }) => `Unexpected character '${unexpected}'.`, + InvalidParenthesizedAssignment: "Invalid parenthesized assignment pattern.", + InvalidPrivateFieldResolution: ({ identifierName }) => `Private name #${identifierName} is not defined.`, + InvalidPropertyBindingPattern: "Binding member expression.", + InvalidRecordProperty: "Only properties and spread elements are allowed in record definitions.", + InvalidRestAssignmentPattern: "Invalid rest operator's argument.", + LabelRedeclaration: ({ labelName }) => `Label '${labelName}' is already declared.`, + LetInLexicalBinding: "'let' is disallowed as a lexically bound name.", + LineTerminatorBeforeArrow: "No line break is allowed before '=>'.", + MalformedRegExpFlags: "Invalid regular expression flag.", + MissingClassName: "A class name is required.", + MissingEqInAssignment: "Only '=' operator can be used for specifying default value.", + MissingSemicolon: "Missing semicolon.", + MissingPlugin: ({ missingPlugin }) => `This experimental syntax requires enabling the parser plugin: ${missingPlugin.map((name) => JSON.stringify(name)).join(", ")}.`, + MissingOneOfPlugins: ({ missingPlugin }) => `This experimental syntax requires enabling one of the following parser plugin(s): ${missingPlugin.map((name) => JSON.stringify(name)).join(", ")}.`, + MissingUnicodeEscape: "Expecting Unicode escape sequence \\uXXXX.", + MixingCoalesceWithLogical: "Nullish coalescing operator(??) requires parens when mixing with logical operators.", + ModuleAttributeDifferentFromType: "The only accepted module attribute is `type`.", + ModuleAttributeInvalidValue: "Only string literals are allowed as module attribute values.", + ModuleAttributesWithDuplicateKeys: ({ key }) => `Duplicate key "${key}" is not allowed in module attributes.`, + ModuleExportNameHasLoneSurrogate: ({ surrogateCharCode }) => `An export name cannot include a lone surrogate, found '\\u${surrogateCharCode.toString(16)}'.`, + ModuleExportUndefined: ({ localName }) => `Export '${localName}' is not defined.`, + MultipleDefaultsInSwitch: "Multiple default clauses.", + NewlineAfterThrow: "Illegal newline after throw.", + NoCatchOrFinally: "Missing catch or finally clause.", + NumberIdentifier: "Identifier directly after number.", + NumericSeparatorInEscapeSequence: "Numeric separators are not allowed inside unicode escape sequences or hex escape sequences.", + ObsoleteAwaitStar: "'await*' has been removed from the async functions proposal. Use Promise.all() instead.", + OptionalChainingNoNew: "Constructors in/after an Optional Chain are not allowed.", + OptionalChainingNoTemplate: "Tagged Template Literals are not allowed in optionalChain.", + OverrideOnConstructor: "'override' modifier cannot appear on a constructor declaration.", + ParamDupe: "Argument name clash.", + PatternHasAccessor: "Object pattern can't contain getter or setter.", + PatternHasMethod: "Object pattern can't contain methods.", + PrivateInExpectedIn: ({ identifierName }) => `Private names are only allowed in property accesses (\`obj.#${identifierName}\`) or in \`in\` expressions (\`#${identifierName} in obj\`).`, + PrivateNameRedeclaration: ({ identifierName }) => `Duplicate private name #${identifierName}.`, + RecordExpressionBarIncorrectEndSyntaxType: "Record expressions ending with '|}' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'bar'.", + RecordExpressionBarIncorrectStartSyntaxType: "Record expressions starting with '{|' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'bar'.", + RecordExpressionHashIncorrectStartSyntaxType: "Record expressions starting with '#{' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'hash'.", + RecordNoProto: "'__proto__' is not allowed in Record expressions.", + RestTrailingComma: "Unexpected trailing comma after rest element.", + SloppyFunction: "In non-strict mode code, functions can only be declared at top level or inside a block.", + SloppyFunctionAnnexB: "In non-strict mode code, functions can only be declared at top level, inside a block, or as the body of an if statement.", + SourcePhaseImportRequiresDefault: "Only `import source x from \"./module\"` is valid.", + StaticPrototype: "Classes may not have static property named prototype.", + SuperNotAllowed: "`super()` is only valid inside a class constructor of a subclass. Maybe a typo in the method name ('constructor') or not extending another class?", + SuperPrivateField: "Private fields can't be accessed on super.", + TrailingDecorator: "Decorators must be attached to a class element.", + TupleExpressionBarIncorrectEndSyntaxType: "Tuple expressions ending with '|]' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'bar'.", + TupleExpressionBarIncorrectStartSyntaxType: "Tuple expressions starting with '[|' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'bar'.", + TupleExpressionHashIncorrectStartSyntaxType: "Tuple expressions starting with '#[' are only allowed when the 'syntaxType' option of the 'recordAndTuple' plugin is set to 'hash'.", + UnexpectedArgumentPlaceholder: "Unexpected argument placeholder.", + UnexpectedAwaitAfterPipelineBody: "Unexpected \"await\" after pipeline body; await must have parentheses in minimal proposal.", + UnexpectedDigitAfterHash: "Unexpected digit after hash token.", + UnexpectedImportExport: "'import' and 'export' may only appear at the top level.", + UnexpectedKeyword: ({ keyword }) => `Unexpected keyword '${keyword}'.`, + UnexpectedLeadingDecorator: "Leading decorators must be attached to a class declaration.", + UnexpectedLexicalDeclaration: "Lexical declaration cannot appear in a single-statement context.", + UnexpectedNewTarget: "`new.target` can only be used in functions or class properties.", + UnexpectedNumericSeparator: "A numeric separator is only allowed between two digits.", + UnexpectedPrivateField: "Unexpected private name.", + UnexpectedReservedWord: ({ reservedWord }) => `Unexpected reserved word '${reservedWord}'.`, + UnexpectedSuper: "'super' is only allowed in object methods and classes.", + UnexpectedToken: ({ expected, unexpected }) => `Unexpected token${unexpected ? ` '${unexpected}'.` : ""}${expected ? `, expected "${expected}"` : ""}`, + UnexpectedTokenUnaryExponentiation: "Illegal expression. Wrap left hand side or entire exponentiation in parentheses.", + UnexpectedUsingDeclaration: "Using declaration cannot appear in the top level when source type is `script`.", + UnsupportedBind: "Binding should be performed on object property.", + UnsupportedDecoratorExport: "A decorated export must export a class declaration.", + UnsupportedDefaultExport: "Only expressions, functions or classes are allowed as the `default` export.", + UnsupportedImport: "`import` can only be used in `import()` or `import.meta`.", + UnsupportedMetaProperty: ({ target, onlyValidPropertyName }) => `The only valid meta property for ${target} is ${target}.${onlyValidPropertyName}.`, + UnsupportedParameterDecorator: "Decorators cannot be used to decorate parameters.", + UnsupportedPropertyDecorator: "Decorators cannot be used to decorate object literal properties.", + UnsupportedSuper: "'super' can only be used with function calls (i.e. super()) or in property accesses (i.e. super.prop or super[prop]).", + UnterminatedComment: "Unterminated comment.", + UnterminatedRegExp: "Unterminated regular expression.", + UnterminatedString: "Unterminated string constant.", + UnterminatedTemplate: "Unterminated template.", + UsingDeclarationExport: "Using declaration cannot be exported.", + UsingDeclarationHasBindingPattern: "Using declaration cannot have destructuring patterns.", + VarRedeclaration: ({ identifierName }) => `Identifier '${identifierName}' has already been declared.`, + YieldBindingIdentifier: "Can not use 'yield' as identifier inside a generator.", + YieldInParameter: "Yield expression is not allowed in formal parameters.", + YieldNotInGeneratorFunction: "'yield' is only allowed within generator functions.", + ZeroDigitNumericSeparator: "Numeric separator can not be used after leading 0." + }; + var StrictModeErrors = { + StrictDelete: "Deleting local variable in strict mode.", + StrictEvalArguments: ({ referenceName }) => `Assigning to '${referenceName}' in strict mode.`, + StrictEvalArgumentsBinding: ({ bindingName }) => `Binding '${bindingName}' in strict mode.`, + StrictFunction: "In strict mode code, functions can only be declared at top level or inside a block.", + StrictNumericEscape: "The only valid numeric escape in strict mode is '\\0'.", + StrictOctalLiteral: "Legacy octal literals are not allowed in strict mode.", + StrictWith: "'with' in strict mode." + }; + const UnparenthesizedPipeBodyDescriptions = new Set([ + "ArrowFunctionExpression", + "AssignmentExpression", + "ConditionalExpression", + "YieldExpression" + ]); + var PipelineOperatorErrors = Object.assign({ + PipeBodyIsTighter: "Unexpected yield after pipeline body; any yield expression acting as Hack-style pipe body must be parenthesized due to its loose operator precedence.", + PipeTopicRequiresHackPipes: "Topic reference is used, but the pipelineOperator plugin was not passed a \"proposal\": \"hack\" or \"smart\" option.", + PipeTopicUnbound: "Topic reference is unbound; it must be inside a pipe body.", + PipeTopicUnconfiguredToken: ({ token: token$1 }) => `Invalid topic token ${token$1}. In order to use ${token$1} as a topic reference, the pipelineOperator plugin must be configured with { "proposal": "hack", "topicToken": "${token$1}" }.`, + PipeTopicUnused: "Hack-style pipe body does not contain a topic reference; Hack-style pipes must use topic at least once.", + PipeUnparenthesizedBody: ({ type }) => `Hack-style pipe body cannot be an unparenthesized ${toNodeDescription({ type })}; please wrap it in parentheses.` + }, { + PipelineBodyNoArrow: "Unexpected arrow \"=>\" after pipeline body; arrow function in pipeline body must be parenthesized.", + PipelineBodySequenceExpression: "Pipeline body may not be a comma-separated sequence expression.", + PipelineHeadSequenceExpression: "Pipeline head should not be a comma-separated sequence expression.", + PipelineTopicUnused: "Pipeline is in topic style but does not use topic reference.", + PrimaryTopicNotAllowed: "Topic reference was used in a lexical context without topic binding.", + PrimaryTopicRequiresSmartPipeline: "Topic reference is used, but the pipelineOperator plugin was not passed a \"proposal\": \"hack\" or \"smart\" option." + }); + const _excluded$1 = ["message"]; + function defineHidden(obj, key, value) { + Object.defineProperty(obj, key, { + enumerable: false, + configurable: true, + value + }); + } + function toParseErrorConstructor({ toMessage, code: code$1, reasonCode, syntaxPlugin }) { + const hasMissingPlugin = reasonCode === "MissingPlugin" || reasonCode === "MissingOneOfPlugins"; + { + const oldReasonCodes = { + AccessorCannotDeclareThisParameter: "AccesorCannotDeclareThisParameter", + AccessorCannotHaveTypeParameters: "AccesorCannotHaveTypeParameters", + ConstInitializerMustBeStringOrNumericLiteralOrLiteralEnumReference: "ConstInitiailizerMustBeStringOrNumericLiteralOrLiteralEnumReference", + SetAccessorCannotHaveOptionalParameter: "SetAccesorCannotHaveOptionalParameter", + SetAccessorCannotHaveRestParameter: "SetAccesorCannotHaveRestParameter", + SetAccessorCannotHaveReturnType: "SetAccesorCannotHaveReturnType" + }; + if (oldReasonCodes[reasonCode]) reasonCode = oldReasonCodes[reasonCode]; + } + return function constructor(loc, details) { + const error = new SyntaxError(); + error.code = code$1; + error.reasonCode = reasonCode; + error.loc = loc; + error.pos = loc.index; + error.syntaxPlugin = syntaxPlugin; + if (hasMissingPlugin) error.missingPlugin = details.missingPlugin; + defineHidden(error, "clone", function clone$5(overrides = {}) { + var _overrides$loc; + const { line, column, index: index$1 } = (_overrides$loc = overrides.loc) != null ? _overrides$loc : loc; + return constructor(new Position(line, column, index$1), Object.assign({}, details, overrides.details)); + }); + defineHidden(error, "details", details); + Object.defineProperty(error, "message", { + configurable: true, + get() { + const message = `${toMessage(details)} (${loc.line}:${loc.column})`; + this.message = message; + return message; + }, + set(value) { + Object.defineProperty(this, "message", { + value, + writable: true + }); + } + }); + return error; + }; + } + function ParseErrorEnum(argument, syntaxPlugin) { + if (Array.isArray(argument)) return (parseErrorTemplates) => ParseErrorEnum(parseErrorTemplates, argument[0]); + const ParseErrorConstructors = {}; + for (const reasonCode of Object.keys(argument)) { + const template$2 = argument[reasonCode]; + const _ref = typeof template$2 === "string" ? { message: () => template$2 } : typeof template$2 === "function" ? { message: template$2 } : template$2, { message } = _ref, rest$1 = _objectWithoutPropertiesLoose$1(_ref, _excluded$1); + const toMessage = typeof message === "string" ? () => message : message; + ParseErrorConstructors[reasonCode] = toParseErrorConstructor(Object.assign({ + code: "BABEL_PARSER_SYNTAX_ERROR", + reasonCode, + toMessage + }, syntaxPlugin ? { syntaxPlugin } : {}, rest$1)); + } + return ParseErrorConstructors; + } + const Errors = Object.assign({}, ParseErrorEnum(ModuleErrors), ParseErrorEnum(StandardErrors), ParseErrorEnum(StrictModeErrors), ParseErrorEnum`pipelineOperator`(PipelineOperatorErrors)); + function createDefaultOptions() { + return { + sourceType: "script", + sourceFilename: void 0, + startIndex: 0, + startColumn: 0, + startLine: 1, + allowAwaitOutsideFunction: false, + allowReturnOutsideFunction: false, + allowNewTargetOutsideFunction: false, + allowImportExportEverywhere: false, + allowSuperOutsideMethod: false, + allowUndeclaredExports: false, + allowYieldOutsideFunction: false, + plugins: [], + strictMode: null, + ranges: false, + tokens: false, + createImportExpressions: false, + createParenthesizedExpressions: false, + errorRecovery: false, + attachComment: true, + annexB: true + }; + } + function getOptions(opts) { + const options = createDefaultOptions(); + if (opts == null) return options; + if (opts.annexB != null && opts.annexB !== false) throw new Error("The `annexB` option can only be set to `false`."); + for (const key of Object.keys(options)) if (opts[key] != null) options[key] = opts[key]; + if (options.startLine === 1) { + if (opts.startIndex == null && options.startColumn > 0) options.startIndex = options.startColumn; + else if (opts.startColumn == null && options.startIndex > 0) options.startColumn = options.startIndex; + } else if (opts.startColumn == null || opts.startIndex == null) { + if (opts.startIndex != null) throw new Error("With a `startLine > 1` you must also specify `startIndex` and `startColumn`."); + } + return options; + } + const { defineProperty } = Object; + const toUnenumerable = (object$3, key) => { + if (object$3) defineProperty(object$3, key, { + enumerable: false, + value: object$3[key] + }); + }; + function toESTreeLocation(node) { + toUnenumerable(node.loc.start, "index"); + toUnenumerable(node.loc.end, "index"); + return node; + } + var estree = (superClass) => class ESTreeParserMixin extends superClass { + parse() { + const file$2 = toESTreeLocation(super.parse()); + if (this.optionFlags & 256) file$2.tokens = file$2.tokens.map(toESTreeLocation); + return file$2; + } + parseRegExpLiteral({ pattern, flags }) { + let regex = null; + try { + regex = new RegExp(pattern, flags); + } catch (_$2) {} + const node = this.estreeParseLiteral(regex); + node.regex = { + pattern, + flags + }; + return node; + } + parseBigIntLiteral(value) { + let bigInt; + try { + bigInt = BigInt(value); + } catch (_unused) { + bigInt = null; + } + const node = this.estreeParseLiteral(bigInt); + node.bigint = String(node.value || value); + return node; + } + parseDecimalLiteral(value) { + const decimal = null; + const node = this.estreeParseLiteral(decimal); + node.decimal = String(node.value || value); + return node; + } + estreeParseLiteral(value) { + return this.parseLiteral(value, "Literal"); + } + parseStringLiteral(value) { + return this.estreeParseLiteral(value); + } + parseNumericLiteral(value) { + return this.estreeParseLiteral(value); + } + parseNullLiteral() { + return this.estreeParseLiteral(null); + } + parseBooleanLiteral(value) { + return this.estreeParseLiteral(value); + } + directiveToStmt(directive$1) { + const expression$2 = directive$1.value; + delete directive$1.value; + expression$2.type = "Literal"; + expression$2.raw = expression$2.extra.raw; + expression$2.value = expression$2.extra.expressionValue; + const stmt = directive$1; + stmt.type = "ExpressionStatement"; + stmt.expression = expression$2; + stmt.directive = expression$2.extra.rawValue; + delete expression$2.extra; + return stmt; + } + initFunction(node, isAsync) { + super.initFunction(node, isAsync); + node.expression = false; + } + checkDeclaration(node) { + if (node != null && this.isObjectProperty(node)) this.checkDeclaration(node.value); + else super.checkDeclaration(node); + } + getObjectOrClassMethodParams(method) { + return method.value.params; + } + isValidDirective(stmt) { + var _stmt$expression$extr; + return stmt.type === "ExpressionStatement" && stmt.expression.type === "Literal" && typeof stmt.expression.value === "string" && !((_stmt$expression$extr = stmt.expression.extra) != null && _stmt$expression$extr.parenthesized); + } + parseBlockBody(node, allowDirectives, topLevel, end, afterBlockParse) { + super.parseBlockBody(node, allowDirectives, topLevel, end, afterBlockParse); + const directiveStatements = node.directives.map((d$2) => this.directiveToStmt(d$2)); + node.body = directiveStatements.concat(node.body); + delete node.directives; + } + parsePrivateName() { + const node = super.parsePrivateName(); + if (!this.getPluginOption("estree", "classFeatures")) return node; + return this.convertPrivateNameToPrivateIdentifier(node); + } + convertPrivateNameToPrivateIdentifier(node) { + const name = super.getPrivateNameSV(node); + node = node; + delete node.id; + node.name = name; + node.type = "PrivateIdentifier"; + return node; + } + isPrivateName(node) { + if (!this.getPluginOption("estree", "classFeatures")) return super.isPrivateName(node); + return node.type === "PrivateIdentifier"; + } + getPrivateNameSV(node) { + if (!this.getPluginOption("estree", "classFeatures")) return super.getPrivateNameSV(node); + return node.name; + } + parseLiteral(value, type) { + const node = super.parseLiteral(value, type); + node.raw = node.extra.raw; + delete node.extra; + return node; + } + parseFunctionBody(node, allowExpression, isMethod$2 = false) { + super.parseFunctionBody(node, allowExpression, isMethod$2); + node.expression = node.body.type !== "BlockStatement"; + } + parseMethod(node, isGenerator, isAsync, isConstructor, allowDirectSuper, type, inClassScope = false) { + let funcNode = this.startNode(); + funcNode.kind = node.kind; + funcNode = super.parseMethod(funcNode, isGenerator, isAsync, isConstructor, allowDirectSuper, type, inClassScope); + funcNode.type = "FunctionExpression"; + delete funcNode.kind; + node.value = funcNode; + const { typeParameters } = node; + if (typeParameters) { + delete node.typeParameters; + funcNode.typeParameters = typeParameters; + this.resetStartLocationFromNode(funcNode, typeParameters); + } + if (type === "ClassPrivateMethod") node.computed = false; + return this.finishNode(node, "MethodDefinition"); + } + nameIsConstructor(key) { + if (key.type === "Literal") return key.value === "constructor"; + return super.nameIsConstructor(key); + } + parseClassProperty(...args) { + const propertyNode = super.parseClassProperty(...args); + if (!this.getPluginOption("estree", "classFeatures")) return propertyNode; + propertyNode.type = "PropertyDefinition"; + return propertyNode; + } + parseClassPrivateProperty(...args) { + const propertyNode = super.parseClassPrivateProperty(...args); + if (!this.getPluginOption("estree", "classFeatures")) return propertyNode; + propertyNode.type = "PropertyDefinition"; + propertyNode.computed = false; + return propertyNode; + } + parseClassAccessorProperty(node) { + const accessorPropertyNode = super.parseClassAccessorProperty(node); + if (!this.getPluginOption("estree", "classFeatures")) return accessorPropertyNode; + accessorPropertyNode.type = "AccessorProperty"; + return accessorPropertyNode; + } + parseObjectMethod(prop, isGenerator, isAsync, isPattern$2, isAccessor$1) { + const node = super.parseObjectMethod(prop, isGenerator, isAsync, isPattern$2, isAccessor$1); + if (node) { + node.type = "Property"; + if (node.kind === "method") node.kind = "init"; + node.shorthand = false; + } + return node; + } + parseObjectProperty(prop, startLoc, isPattern$2, refExpressionErrors) { + const node = super.parseObjectProperty(prop, startLoc, isPattern$2, refExpressionErrors); + if (node) { + node.kind = "init"; + node.type = "Property"; + } + return node; + } + isValidLVal(type, isUnparenthesizedInAssign, binding) { + return type === "Property" ? "value" : super.isValidLVal(type, isUnparenthesizedInAssign, binding); + } + isAssignable(node, isBinding$2) { + if (node != null && this.isObjectProperty(node)) return this.isAssignable(node.value, isBinding$2); + return super.isAssignable(node, isBinding$2); + } + toAssignable(node, isLHS = false) { + if (node != null && this.isObjectProperty(node)) { + const { key, value } = node; + if (this.isPrivateName(key)) this.classScope.usePrivateName(this.getPrivateNameSV(key), key.loc.start); + this.toAssignable(value, isLHS); + } else super.toAssignable(node, isLHS); + } + toAssignableObjectExpressionProp(prop, isLast, isLHS) { + if (prop.type === "Property" && (prop.kind === "get" || prop.kind === "set")) this.raise(Errors.PatternHasAccessor, prop.key); + else if (prop.type === "Property" && prop.method) this.raise(Errors.PatternHasMethod, prop.key); + else super.toAssignableObjectExpressionProp(prop, isLast, isLHS); + } + finishCallExpression(unfinished, optional) { + const node = super.finishCallExpression(unfinished, optional); + if (node.callee.type === "Import") { + var _ref, _ref2; + node.type = "ImportExpression"; + node.source = node.arguments[0]; + node.options = (_ref = node.arguments[1]) != null ? _ref : null; + node.attributes = (_ref2 = node.arguments[1]) != null ? _ref2 : null; + delete node.arguments; + delete node.callee; + } + return node; + } + toReferencedArguments(node) { + if (node.type === "ImportExpression") return; + super.toReferencedArguments(node); + } + parseExport(unfinished, decorators) { + const exportStartLoc = this.state.lastTokStartLoc; + const node = super.parseExport(unfinished, decorators); + switch (node.type) { + case "ExportAllDeclaration": + node.exported = null; + break; + case "ExportNamedDeclaration": if (node.specifiers.length === 1 && node.specifiers[0].type === "ExportNamespaceSpecifier") { + node.type = "ExportAllDeclaration"; + node.exported = node.specifiers[0].exported; + delete node.specifiers; + } + case "ExportDefaultDeclaration": + { + var _declaration$decorato; + const { declaration } = node; + if ((declaration == null ? void 0 : declaration.type) === "ClassDeclaration" && ((_declaration$decorato = declaration.decorators) == null ? void 0 : _declaration$decorato.length) > 0 && declaration.start === node.start) this.resetStartLocation(node, exportStartLoc); + } + break; + } + return node; + } + parseSubscript(base$1, startLoc, noCalls, state) { + const node = super.parseSubscript(base$1, startLoc, noCalls, state); + if (state.optionalChainMember) { + if (node.type === "OptionalMemberExpression" || node.type === "OptionalCallExpression") node.type = node.type.substring(8); + if (state.stop) { + const chain$2 = this.startNodeAtNode(node); + chain$2.expression = node; + return this.finishNode(chain$2, "ChainExpression"); + } + } else if (node.type === "MemberExpression" || node.type === "CallExpression") node.optional = false; + return node; + } + isOptionalMemberExpression(node) { + if (node.type === "ChainExpression") return node.expression.type === "MemberExpression"; + return super.isOptionalMemberExpression(node); + } + hasPropertyAsPrivateName(node) { + if (node.type === "ChainExpression") node = node.expression; + return super.hasPropertyAsPrivateName(node); + } + isObjectProperty(node) { + return node.type === "Property" && node.kind === "init" && !node.method; + } + isObjectMethod(node) { + return node.type === "Property" && (node.method || node.kind === "get" || node.kind === "set"); + } + finishNodeAt(node, type, endLoc) { + return toESTreeLocation(super.finishNodeAt(node, type, endLoc)); + } + resetStartLocation(node, startLoc) { + super.resetStartLocation(node, startLoc); + toESTreeLocation(node); + } + resetEndLocation(node, endLoc = this.state.lastTokEndLoc) { + super.resetEndLocation(node, endLoc); + toESTreeLocation(node); + } + }; + var TokContext = class { + constructor(token$1, preserveSpace) { + this.token = void 0; + this.preserveSpace = void 0; + this.token = token$1; + this.preserveSpace = !!preserveSpace; + } + }; + const types$4 = { + brace: new TokContext("{"), + j_oTag: new TokContext("...", true) + }; + types$4.template = new TokContext("`", true); + const beforeExpr = true; + const startsExpr = true; + const isLoop$1 = true; + const isAssign = true; + const prefix = true; + const postfix = true; + var ExportedTokenType = class { + constructor(label, conf = {}) { + this.label = void 0; + this.keyword = void 0; + this.beforeExpr = void 0; + this.startsExpr = void 0; + this.rightAssociative = void 0; + this.isLoop = void 0; + this.isAssign = void 0; + this.prefix = void 0; + this.postfix = void 0; + this.binop = void 0; + this.label = label; + this.keyword = conf.keyword; + this.beforeExpr = !!conf.beforeExpr; + this.startsExpr = !!conf.startsExpr; + this.rightAssociative = !!conf.rightAssociative; + this.isLoop = !!conf.isLoop; + this.isAssign = !!conf.isAssign; + this.prefix = !!conf.prefix; + this.postfix = !!conf.postfix; + this.binop = conf.binop != null ? conf.binop : null; + this.updateContext = null; + } + }; + const keywords$1 = new Map(); + function createKeyword(name, options = {}) { + options.keyword = name; + const token$1 = createToken(name, options); + keywords$1.set(name, token$1); + return token$1; + } + function createBinop(name, binop) { + return createToken(name, { + beforeExpr, + binop + }); + } + let tokenTypeCounter = -1; + const tokenTypes = []; + const tokenLabels = []; + const tokenBinops = []; + const tokenBeforeExprs = []; + const tokenStartsExprs = []; + const tokenPrefixes = []; + function createToken(name, options = {}) { + var _options$binop, _options$beforeExpr, _options$startsExpr, _options$prefix; + ++tokenTypeCounter; + tokenLabels.push(name); + tokenBinops.push((_options$binop = options.binop) != null ? _options$binop : -1); + tokenBeforeExprs.push((_options$beforeExpr = options.beforeExpr) != null ? _options$beforeExpr : false); + tokenStartsExprs.push((_options$startsExpr = options.startsExpr) != null ? _options$startsExpr : false); + tokenPrefixes.push((_options$prefix = options.prefix) != null ? _options$prefix : false); + tokenTypes.push(new ExportedTokenType(name, options)); + return tokenTypeCounter; + } + function createKeywordLike(name, options = {}) { + var _options$binop2, _options$beforeExpr2, _options$startsExpr2, _options$prefix2; + ++tokenTypeCounter; + keywords$1.set(name, tokenTypeCounter); + tokenLabels.push(name); + tokenBinops.push((_options$binop2 = options.binop) != null ? _options$binop2 : -1); + tokenBeforeExprs.push((_options$beforeExpr2 = options.beforeExpr) != null ? _options$beforeExpr2 : false); + tokenStartsExprs.push((_options$startsExpr2 = options.startsExpr) != null ? _options$startsExpr2 : false); + tokenPrefixes.push((_options$prefix2 = options.prefix) != null ? _options$prefix2 : false); + tokenTypes.push(new ExportedTokenType("name", options)); + return tokenTypeCounter; + } + const tt = { + bracketL: createToken("[", { + beforeExpr, + startsExpr + }), + bracketHashL: createToken("#[", { + beforeExpr, + startsExpr + }), + bracketBarL: createToken("[|", { + beforeExpr, + startsExpr + }), + bracketR: createToken("]"), + bracketBarR: createToken("|]"), + braceL: createToken("{", { + beforeExpr, + startsExpr + }), + braceBarL: createToken("{|", { + beforeExpr, + startsExpr + }), + braceHashL: createToken("#{", { + beforeExpr, + startsExpr + }), + braceR: createToken("}"), + braceBarR: createToken("|}"), + parenL: createToken("(", { + beforeExpr, + startsExpr + }), + parenR: createToken(")"), + comma: createToken(",", { beforeExpr }), + semi: createToken(";", { beforeExpr }), + colon: createToken(":", { beforeExpr }), + doubleColon: createToken("::", { beforeExpr }), + dot: createToken("."), + question: createToken("?", { beforeExpr }), + questionDot: createToken("?."), + arrow: createToken("=>", { beforeExpr }), + template: createToken("template"), + ellipsis: createToken("...", { beforeExpr }), + backQuote: createToken("`", { startsExpr }), + dollarBraceL: createToken("${", { + beforeExpr, + startsExpr + }), + templateTail: createToken("...`", { startsExpr }), + templateNonTail: createToken("...${", { + beforeExpr, + startsExpr + }), + at: createToken("@"), + hash: createToken("#", { startsExpr }), + interpreterDirective: createToken("#!..."), + eq: createToken("=", { + beforeExpr, + isAssign + }), + assign: createToken("_=", { + beforeExpr, + isAssign + }), + slashAssign: createToken("_=", { + beforeExpr, + isAssign + }), + xorAssign: createToken("_=", { + beforeExpr, + isAssign + }), + moduloAssign: createToken("_=", { + beforeExpr, + isAssign + }), + incDec: createToken("++/--", { + prefix, + postfix, + startsExpr + }), + bang: createToken("!", { + beforeExpr, + prefix, + startsExpr + }), + tilde: createToken("~", { + beforeExpr, + prefix, + startsExpr + }), + doubleCaret: createToken("^^", { startsExpr }), + doubleAt: createToken("@@", { startsExpr }), + pipeline: createBinop("|>", 0), + nullishCoalescing: createBinop("??", 1), + logicalOR: createBinop("||", 1), + logicalAND: createBinop("&&", 2), + bitwiseOR: createBinop("|", 3), + bitwiseXOR: createBinop("^", 4), + bitwiseAND: createBinop("&", 5), + equality: createBinop("==/!=/===/!==", 6), + lt: createBinop("/<=/>=", 7), + gt: createBinop("/<=/>=", 7), + relational: createBinop("/<=/>=", 7), + bitShift: createBinop("<>/>>>", 8), + bitShiftL: createBinop("<>/>>>", 8), + bitShiftR: createBinop("<>/>>>", 8), + plusMin: createToken("+/-", { + beforeExpr, + binop: 9, + prefix, + startsExpr + }), + modulo: createToken("%", { + binop: 10, + startsExpr + }), + star: createToken("*", { binop: 10 }), + slash: createBinop("/", 10), + exponent: createToken("**", { + beforeExpr, + binop: 11, + rightAssociative: true + }), + _in: createKeyword("in", { + beforeExpr, + binop: 7 + }), + _instanceof: createKeyword("instanceof", { + beforeExpr, + binop: 7 + }), + _break: createKeyword("break"), + _case: createKeyword("case", { beforeExpr }), + _catch: createKeyword("catch"), + _continue: createKeyword("continue"), + _debugger: createKeyword("debugger"), + _default: createKeyword("default", { beforeExpr }), + _else: createKeyword("else", { beforeExpr }), + _finally: createKeyword("finally"), + _function: createKeyword("function", { startsExpr }), + _if: createKeyword("if"), + _return: createKeyword("return", { beforeExpr }), + _switch: createKeyword("switch"), + _throw: createKeyword("throw", { + beforeExpr, + prefix, + startsExpr + }), + _try: createKeyword("try"), + _var: createKeyword("var"), + _const: createKeyword("const"), + _with: createKeyword("with"), + _new: createKeyword("new", { + beforeExpr, + startsExpr + }), + _this: createKeyword("this", { startsExpr }), + _super: createKeyword("super", { startsExpr }), + _class: createKeyword("class", { startsExpr }), + _extends: createKeyword("extends", { beforeExpr }), + _export: createKeyword("export"), + _import: createKeyword("import", { startsExpr }), + _null: createKeyword("null", { startsExpr }), + _true: createKeyword("true", { startsExpr }), + _false: createKeyword("false", { startsExpr }), + _typeof: createKeyword("typeof", { + beforeExpr, + prefix, + startsExpr + }), + _void: createKeyword("void", { + beforeExpr, + prefix, + startsExpr + }), + _delete: createKeyword("delete", { + beforeExpr, + prefix, + startsExpr + }), + _do: createKeyword("do", { + isLoop: isLoop$1, + beforeExpr + }), + _for: createKeyword("for", { isLoop: isLoop$1 }), + _while: createKeyword("while", { isLoop: isLoop$1 }), + _as: createKeywordLike("as", { startsExpr }), + _assert: createKeywordLike("assert", { startsExpr }), + _async: createKeywordLike("async", { startsExpr }), + _await: createKeywordLike("await", { startsExpr }), + _defer: createKeywordLike("defer", { startsExpr }), + _from: createKeywordLike("from", { startsExpr }), + _get: createKeywordLike("get", { startsExpr }), + _let: createKeywordLike("let", { startsExpr }), + _meta: createKeywordLike("meta", { startsExpr }), + _of: createKeywordLike("of", { startsExpr }), + _sent: createKeywordLike("sent", { startsExpr }), + _set: createKeywordLike("set", { startsExpr }), + _source: createKeywordLike("source", { startsExpr }), + _static: createKeywordLike("static", { startsExpr }), + _using: createKeywordLike("using", { startsExpr }), + _yield: createKeywordLike("yield", { startsExpr }), + _asserts: createKeywordLike("asserts", { startsExpr }), + _checks: createKeywordLike("checks", { startsExpr }), + _exports: createKeywordLike("exports", { startsExpr }), + _global: createKeywordLike("global", { startsExpr }), + _implements: createKeywordLike("implements", { startsExpr }), + _intrinsic: createKeywordLike("intrinsic", { startsExpr }), + _infer: createKeywordLike("infer", { startsExpr }), + _is: createKeywordLike("is", { startsExpr }), + _mixins: createKeywordLike("mixins", { startsExpr }), + _proto: createKeywordLike("proto", { startsExpr }), + _require: createKeywordLike("require", { startsExpr }), + _satisfies: createKeywordLike("satisfies", { startsExpr }), + _keyof: createKeywordLike("keyof", { startsExpr }), + _readonly: createKeywordLike("readonly", { startsExpr }), + _unique: createKeywordLike("unique", { startsExpr }), + _abstract: createKeywordLike("abstract", { startsExpr }), + _declare: createKeywordLike("declare", { startsExpr }), + _enum: createKeywordLike("enum", { startsExpr }), + _module: createKeywordLike("module", { startsExpr }), + _namespace: createKeywordLike("namespace", { startsExpr }), + _interface: createKeywordLike("interface", { startsExpr }), + _type: createKeywordLike("type", { startsExpr }), + _opaque: createKeywordLike("opaque", { startsExpr }), + name: createToken("name", { startsExpr }), + placeholder: createToken("%%", { startsExpr: true }), + string: createToken("string", { startsExpr }), + num: createToken("num", { startsExpr }), + bigint: createToken("bigint", { startsExpr }), + decimal: createToken("decimal", { startsExpr }), + regexp: createToken("regexp", { startsExpr }), + privateName: createToken("#name", { startsExpr }), + eof: createToken("eof"), + jsxName: createToken("jsxName"), + jsxText: createToken("jsxText", { beforeExpr: true }), + jsxTagStart: createToken("jsxTagStart", { startsExpr: true }), + jsxTagEnd: createToken("jsxTagEnd") + }; + function tokenIsIdentifier(token$1) { + return token$1 >= 93 && token$1 <= 133; + } + function tokenKeywordOrIdentifierIsKeyword(token$1) { + return token$1 <= 92; + } + function tokenIsKeywordOrIdentifier(token$1) { + return token$1 >= 58 && token$1 <= 133; + } + function tokenIsLiteralPropertyName(token$1) { + return token$1 >= 58 && token$1 <= 137; + } + function tokenComesBeforeExpression(token$1) { + return tokenBeforeExprs[token$1]; + } + function tokenCanStartExpression(token$1) { + return tokenStartsExprs[token$1]; + } + function tokenIsAssignment(token$1) { + return token$1 >= 29 && token$1 <= 33; + } + function tokenIsFlowInterfaceOrTypeOrOpaque(token$1) { + return token$1 >= 129 && token$1 <= 131; + } + function tokenIsLoop(token$1) { + return token$1 >= 90 && token$1 <= 92; + } + function tokenIsKeyword(token$1) { + return token$1 >= 58 && token$1 <= 92; + } + function tokenIsOperator(token$1) { + return token$1 >= 39 && token$1 <= 59; + } + function tokenIsPostfix(token$1) { + return token$1 === 34; + } + function tokenIsPrefix(token$1) { + return tokenPrefixes[token$1]; + } + function tokenIsTSTypeOperator(token$1) { + return token$1 >= 121 && token$1 <= 123; + } + function tokenIsTSDeclarationStart(token$1) { + return token$1 >= 124 && token$1 <= 130; + } + function tokenLabelName(token$1) { + return tokenLabels[token$1]; + } + function tokenOperatorPrecedence(token$1) { + return tokenBinops[token$1]; + } + function tokenIsRightAssociative(token$1) { + return token$1 === 57; + } + function tokenIsTemplate(token$1) { + return token$1 >= 24 && token$1 <= 25; + } + function getExportedToken(token$1) { + return tokenTypes[token$1]; + } + { + tokenTypes[8].updateContext = (context) => { + context.pop(); + }; + tokenTypes[5].updateContext = tokenTypes[7].updateContext = tokenTypes[23].updateContext = (context) => { + context.push(types$4.brace); + }; + tokenTypes[22].updateContext = (context) => { + if (context[context.length - 1] === types$4.template) context.pop(); + else context.push(types$4.template); + }; + tokenTypes[143].updateContext = (context) => { + context.push(types$4.j_expr, types$4.j_oTag); + }; + } + let nonASCIIidentifierStartChars$1 = "ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙՠ-ֈא-תׯ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࡠ-ࡪࡰ-ࢇࢉ-ࢎࢠ-ࣉऄ-हऽॐक़-ॡॱ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱৼਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡૹଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘ-ౚౝౠౡಀಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽೝೞೠೡೱೲഄ-ഌഎ-ഐഒ-ഺഽൎൔ-ൖൟ-ൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄຆ-ຊຌ-ຣລວ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜑᜟ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡸᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭌᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᲀ-ᲊᲐ-ᲺᲽ-Ჿᳩ-ᳬᳮ-ᳳᳵᳶᳺᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕ℘-ℝℤΩℨK-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々-〇〡-〩〱-〵〸-〼ぁ-ゖ゛-ゟァ-ヺー-ヿㄅ-ㄯㄱ-ㆎㆠ-ㆿㇰ-ㇿ㐀-䶿一-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚝꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ-ꟍꟐꟑꟓꟕ-Ƛꟲ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꣽꣾꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꧠ-ꧤꧦ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭩꭰ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ"; + let nonASCIIidentifierChars$1 = "·̀-ͯ·҃-֑҇-ׇֽֿׁׂׅׄؐ-ًؚ-٩ٰۖ-ۜ۟-۪ۤۧۨ-ۭ۰-۹ܑܰ-݊ަ-ް߀-߉߫-߽߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛ࢗ-࢟࣊-ࣣ࣡-ःऺ-़ा-ॏ॑-ॗॢॣ०-९ঁ-ঃ়া-ৄেৈো-্ৗৢৣ০-৯৾ਁ-ਃ਼ਾ-ੂੇੈੋ-੍ੑ੦-ੱੵઁ-ઃ઼ા-ૅે-ૉો-્ૢૣ૦-૯ૺ-૿ଁ-ଃ଼ା-ୄେୈୋ-୍୕-ୗୢୣ୦-୯ஂா-ூெ-ைொ-்ௗ௦-௯ఀ-ఄ఼ా-ౄె-ైొ-్ౕౖౢౣ౦-౯ಁ-ಃ಼ಾ-ೄೆ-ೈೊ-್ೕೖೢೣ೦-೯ೳഀ-ഃ഻഼ാ-ൄെ-ൈൊ-്ൗൢൣ൦-൯ඁ-ඃ්ා-ුූෘ-ෟ෦-෯ෲෳัิ-ฺ็-๎๐-๙ັິ-ຼ່-໎໐-໙༘༙༠-༩༹༵༷༾༿ཱ-྄྆྇ྍ-ྗྙ-ྼ࿆ါ-ှ၀-၉ၖ-ၙၞ-ၠၢ-ၤၧ-ၭၱ-ၴႂ-ႍႏ-ႝ፝-፟፩-፱ᜒ-᜕ᜲ-᜴ᝒᝓᝲᝳ឴-៓៝០-៩᠋-᠍᠏-᠙ᢩᤠ-ᤫᤰ-᤻᥆-᥏᧐-᧚ᨗ-ᨛᩕ-ᩞ᩠-᩿᩼-᪉᪐-᪙᪰-᪽ᪿ-ᫎᬀ-ᬄ᬴-᭄᭐-᭙᭫-᭳ᮀ-ᮂᮡ-ᮭ᮰-᮹᯦-᯳ᰤ-᰷᱀-᱉᱐-᱙᳐-᳔᳒-᳨᳭᳴᳷-᳹᷀-᷿‌‍‿⁀⁔⃐-⃥⃜⃡-⃰⳯-⵿⳱ⷠ-〪ⷿ-゙゚〯・꘠-꘩꙯ꙴ-꙽ꚞꚟ꛰꛱ꠂ꠆ꠋꠣ-ꠧ꠬ꢀꢁꢴ-ꣅ꣐-꣙꣠-꣱ꣿ-꤉ꤦ-꤭ꥇ-꥓ꦀ-ꦃ꦳-꧀꧐-꧙ꧥ꧰-꧹ꨩ-ꨶꩃꩌꩍ꩐-꩙ꩻ-ꩽꪰꪲ-ꪴꪷꪸꪾ꪿꫁ꫫ-ꫯꫵ꫶ꯣ-ꯪ꯬꯭꯰-꯹ﬞ︀-️︠-︯︳︴﹍-﹏0-9_・"; + const nonASCIIidentifierStart$1 = new RegExp("[" + nonASCIIidentifierStartChars$1 + "]"); + const nonASCIIidentifier$1 = new RegExp("[" + nonASCIIidentifierStartChars$1 + nonASCIIidentifierChars$1 + "]"); + nonASCIIidentifierStartChars$1 = nonASCIIidentifierChars$1 = null; + const astralIdentifierStartCodes$1 = [ + 0, + 11, + 2, + 25, + 2, + 18, + 2, + 1, + 2, + 14, + 3, + 13, + 35, + 122, + 70, + 52, + 268, + 28, + 4, + 48, + 48, + 31, + 14, + 29, + 6, + 37, + 11, + 29, + 3, + 35, + 5, + 7, + 2, + 4, + 43, + 157, + 19, + 35, + 5, + 35, + 5, + 39, + 9, + 51, + 13, + 10, + 2, + 14, + 2, + 6, + 2, + 1, + 2, + 10, + 2, + 14, + 2, + 6, + 2, + 1, + 4, + 51, + 13, + 310, + 10, + 21, + 11, + 7, + 25, + 5, + 2, + 41, + 2, + 8, + 70, + 5, + 3, + 0, + 2, + 43, + 2, + 1, + 4, + 0, + 3, + 22, + 11, + 22, + 10, + 30, + 66, + 18, + 2, + 1, + 11, + 21, + 11, + 25, + 71, + 55, + 7, + 1, + 65, + 0, + 16, + 3, + 2, + 2, + 2, + 28, + 43, + 28, + 4, + 28, + 36, + 7, + 2, + 27, + 28, + 53, + 11, + 21, + 11, + 18, + 14, + 17, + 111, + 72, + 56, + 50, + 14, + 50, + 14, + 35, + 39, + 27, + 10, + 22, + 251, + 41, + 7, + 1, + 17, + 2, + 60, + 28, + 11, + 0, + 9, + 21, + 43, + 17, + 47, + 20, + 28, + 22, + 13, + 52, + 58, + 1, + 3, + 0, + 14, + 44, + 33, + 24, + 27, + 35, + 30, + 0, + 3, + 0, + 9, + 34, + 4, + 0, + 13, + 47, + 15, + 3, + 22, + 0, + 2, + 0, + 36, + 17, + 2, + 24, + 20, + 1, + 64, + 6, + 2, + 0, + 2, + 3, + 2, + 14, + 2, + 9, + 8, + 46, + 39, + 7, + 3, + 1, + 3, + 21, + 2, + 6, + 2, + 1, + 2, + 4, + 4, + 0, + 19, + 0, + 13, + 4, + 31, + 9, + 2, + 0, + 3, + 0, + 2, + 37, + 2, + 0, + 26, + 0, + 2, + 0, + 45, + 52, + 19, + 3, + 21, + 2, + 31, + 47, + 21, + 1, + 2, + 0, + 185, + 46, + 42, + 3, + 37, + 47, + 21, + 0, + 60, + 42, + 14, + 0, + 72, + 26, + 38, + 6, + 186, + 43, + 117, + 63, + 32, + 7, + 3, + 0, + 3, + 7, + 2, + 1, + 2, + 23, + 16, + 0, + 2, + 0, + 95, + 7, + 3, + 38, + 17, + 0, + 2, + 0, + 29, + 0, + 11, + 39, + 8, + 0, + 22, + 0, + 12, + 45, + 20, + 0, + 19, + 72, + 200, + 32, + 32, + 8, + 2, + 36, + 18, + 0, + 50, + 29, + 113, + 6, + 2, + 1, + 2, + 37, + 22, + 0, + 26, + 5, + 2, + 1, + 2, + 31, + 15, + 0, + 328, + 18, + 16, + 0, + 2, + 12, + 2, + 33, + 125, + 0, + 80, + 921, + 103, + 110, + 18, + 195, + 2637, + 96, + 16, + 1071, + 18, + 5, + 26, + 3994, + 6, + 582, + 6842, + 29, + 1763, + 568, + 8, + 30, + 18, + 78, + 18, + 29, + 19, + 47, + 17, + 3, + 32, + 20, + 6, + 18, + 433, + 44, + 212, + 63, + 129, + 74, + 6, + 0, + 67, + 12, + 65, + 1, + 2, + 0, + 29, + 6135, + 9, + 1237, + 42, + 9, + 8936, + 3, + 2, + 6, + 2, + 1, + 2, + 290, + 16, + 0, + 30, + 2, + 3, + 0, + 15, + 3, + 9, + 395, + 2309, + 106, + 6, + 12, + 4, + 8, + 8, + 9, + 5991, + 84, + 2, + 70, + 2, + 1, + 3, + 0, + 3, + 1, + 3, + 3, + 2, + 11, + 2, + 0, + 2, + 6, + 2, + 64, + 2, + 3, + 3, + 7, + 2, + 6, + 2, + 27, + 2, + 3, + 2, + 4, + 2, + 0, + 4, + 6, + 2, + 339, + 3, + 24, + 2, + 24, + 2, + 30, + 2, + 24, + 2, + 30, + 2, + 24, + 2, + 30, + 2, + 24, + 2, + 30, + 2, + 24, + 2, + 7, + 1845, + 30, + 7, + 5, + 262, + 61, + 147, + 44, + 11, + 6, + 17, + 0, + 322, + 29, + 19, + 43, + 485, + 27, + 229, + 29, + 3, + 0, + 496, + 6, + 2, + 3, + 2, + 1, + 2, + 14, + 2, + 196, + 60, + 67, + 8, + 0, + 1205, + 3, + 2, + 26, + 2, + 1, + 2, + 0, + 3, + 0, + 2, + 9, + 2, + 3, + 2, + 0, + 2, + 0, + 7, + 0, + 5, + 0, + 2, + 0, + 2, + 0, + 2, + 2, + 2, + 1, + 2, + 0, + 3, + 0, + 2, + 0, + 2, + 0, + 2, + 0, + 2, + 0, + 2, + 1, + 2, + 0, + 3, + 3, + 2, + 6, + 2, + 3, + 2, + 3, + 2, + 0, + 2, + 9, + 2, + 16, + 6, + 2, + 2, + 4, + 2, + 16, + 4421, + 42719, + 33, + 4153, + 7, + 221, + 3, + 5761, + 15, + 7472, + 16, + 621, + 2467, + 541, + 1507, + 4938, + 6, + 4191 + ]; + const astralIdentifierCodes$1 = [ + 509, + 0, + 227, + 0, + 150, + 4, + 294, + 9, + 1368, + 2, + 2, + 1, + 6, + 3, + 41, + 2, + 5, + 0, + 166, + 1, + 574, + 3, + 9, + 9, + 7, + 9, + 32, + 4, + 318, + 1, + 80, + 3, + 71, + 10, + 50, + 3, + 123, + 2, + 54, + 14, + 32, + 10, + 3, + 1, + 11, + 3, + 46, + 10, + 8, + 0, + 46, + 9, + 7, + 2, + 37, + 13, + 2, + 9, + 6, + 1, + 45, + 0, + 13, + 2, + 49, + 13, + 9, + 3, + 2, + 11, + 83, + 11, + 7, + 0, + 3, + 0, + 158, + 11, + 6, + 9, + 7, + 3, + 56, + 1, + 2, + 6, + 3, + 1, + 3, + 2, + 10, + 0, + 11, + 1, + 3, + 6, + 4, + 4, + 68, + 8, + 2, + 0, + 3, + 0, + 2, + 3, + 2, + 4, + 2, + 0, + 15, + 1, + 83, + 17, + 10, + 9, + 5, + 0, + 82, + 19, + 13, + 9, + 214, + 6, + 3, + 8, + 28, + 1, + 83, + 16, + 16, + 9, + 82, + 12, + 9, + 9, + 7, + 19, + 58, + 14, + 5, + 9, + 243, + 14, + 166, + 9, + 71, + 5, + 2, + 1, + 3, + 3, + 2, + 0, + 2, + 1, + 13, + 9, + 120, + 6, + 3, + 6, + 4, + 0, + 29, + 9, + 41, + 6, + 2, + 3, + 9, + 0, + 10, + 10, + 47, + 15, + 343, + 9, + 54, + 7, + 2, + 7, + 17, + 9, + 57, + 21, + 2, + 13, + 123, + 5, + 4, + 0, + 2, + 1, + 2, + 6, + 2, + 0, + 9, + 9, + 49, + 4, + 2, + 1, + 2, + 4, + 9, + 9, + 330, + 3, + 10, + 1, + 2, + 0, + 49, + 6, + 4, + 4, + 14, + 10, + 5350, + 0, + 7, + 14, + 11465, + 27, + 2343, + 9, + 87, + 9, + 39, + 4, + 60, + 6, + 26, + 9, + 535, + 9, + 470, + 0, + 2, + 54, + 8, + 3, + 82, + 0, + 12, + 1, + 19628, + 1, + 4178, + 9, + 519, + 45, + 3, + 22, + 543, + 4, + 4, + 5, + 9, + 7, + 3, + 6, + 31, + 3, + 149, + 2, + 1418, + 49, + 513, + 54, + 5, + 49, + 9, + 0, + 15, + 0, + 23, + 4, + 2, + 14, + 1361, + 6, + 2, + 16, + 3, + 6, + 2, + 1, + 2, + 4, + 101, + 0, + 161, + 6, + 10, + 9, + 357, + 0, + 62, + 13, + 499, + 13, + 245, + 1, + 2, + 9, + 726, + 6, + 110, + 6, + 6, + 9, + 4759, + 9, + 787719, + 239 + ]; + function isInAstralSet$1(code$1, set) { + let pos = 65536; + for (let i$5 = 0, length = set.length; i$5 < length; i$5 += 2) { + pos += set[i$5]; + if (pos > code$1) return false; + pos += set[i$5 + 1]; + if (pos >= code$1) return true; + } + return false; + } + function isIdentifierStart$1(code$1) { + if (code$1 < 65) return code$1 === 36; + if (code$1 <= 90) return true; + if (code$1 < 97) return code$1 === 95; + if (code$1 <= 122) return true; + if (code$1 <= 65535) return code$1 >= 170 && nonASCIIidentifierStart$1.test(String.fromCharCode(code$1)); + return isInAstralSet$1(code$1, astralIdentifierStartCodes$1); + } + function isIdentifierChar$1(code$1) { + if (code$1 < 48) return code$1 === 36; + if (code$1 < 58) return true; + if (code$1 < 65) return false; + if (code$1 <= 90) return true; + if (code$1 < 97) return code$1 === 95; + if (code$1 <= 122) return true; + if (code$1 <= 65535) return code$1 >= 170 && nonASCIIidentifier$1.test(String.fromCharCode(code$1)); + return isInAstralSet$1(code$1, astralIdentifierStartCodes$1) || isInAstralSet$1(code$1, astralIdentifierCodes$1); + } + const reservedWords$2 = { + keyword: [ + "break", + "case", + "catch", + "continue", + "debugger", + "default", + "do", + "else", + "finally", + "for", + "function", + "if", + "return", + "switch", + "throw", + "try", + "var", + "const", + "while", + "with", + "new", + "this", + "super", + "class", + "extends", + "export", + "import", + "null", + "true", + "false", + "in", + "instanceof", + "typeof", + "void", + "delete" + ], + strict: [ + "implements", + "interface", + "let", + "package", + "private", + "protected", + "public", + "static", + "yield" + ], + strictBind: ["eval", "arguments"] + }; + const keywords$2 = new Set(reservedWords$2.keyword); + const reservedWordsStrictSet$1 = new Set(reservedWords$2.strict); + const reservedWordsStrictBindSet$1 = new Set(reservedWords$2.strictBind); + function isReservedWord$1(word$3, inModule) { + return inModule && word$3 === "await" || word$3 === "enum"; + } + function isStrictReservedWord$1(word$3, inModule) { + return isReservedWord$1(word$3, inModule) || reservedWordsStrictSet$1.has(word$3); + } + function isStrictBindOnlyReservedWord$1(word$3) { + return reservedWordsStrictBindSet$1.has(word$3); + } + function isStrictBindReservedWord$1(word$3, inModule) { + return isStrictReservedWord$1(word$3, inModule) || isStrictBindOnlyReservedWord$1(word$3); + } + function isKeyword$1(word$3) { + return keywords$2.has(word$3); + } + function isIteratorStart(current, next, next2) { + return current === 64 && next === 64 && isIdentifierStart$1(next2); + } + const reservedWordLikeSet = new Set([ + "break", + "case", + "catch", + "continue", + "debugger", + "default", + "do", + "else", + "finally", + "for", + "function", + "if", + "return", + "switch", + "throw", + "try", + "var", + "const", + "while", + "with", + "new", + "this", + "super", + "class", + "extends", + "export", + "import", + "null", + "true", + "false", + "in", + "instanceof", + "typeof", + "void", + "delete", + "implements", + "interface", + "let", + "package", + "private", + "protected", + "public", + "static", + "yield", + "eval", + "arguments", + "enum", + "await" + ]); + function canBeReservedWord(word$3) { + return reservedWordLikeSet.has(word$3); + } + var Scope$2 = class { + constructor(flags) { + this.flags = 0; + this.names = new Map(); + this.firstLexicalName = ""; + this.flags = flags; + } + }; + var ScopeHandler = class { + constructor(parser$4, inModule) { + this.parser = void 0; + this.scopeStack = []; + this.inModule = void 0; + this.undefinedExports = new Map(); + this.parser = parser$4; + this.inModule = inModule; + } + get inTopLevel() { + return (this.currentScope().flags & 1) > 0; + } + get inFunction() { + return (this.currentVarScopeFlags() & 2) > 0; + } + get allowSuper() { + return (this.currentThisScopeFlags() & 16) > 0; + } + get allowDirectSuper() { + return (this.currentThisScopeFlags() & 32) > 0; + } + get inClass() { + return (this.currentThisScopeFlags() & 64) > 0; + } + get inClassAndNotInNonArrowFunction() { + const flags = this.currentThisScopeFlags(); + return (flags & 64) > 0 && (flags & 2) === 0; + } + get inStaticBlock() { + for (let i$5 = this.scopeStack.length - 1;; i$5--) { + const { flags } = this.scopeStack[i$5]; + if (flags & 128) return true; + if (flags & 451) return false; + } + } + get inNonArrowFunction() { + return (this.currentThisScopeFlags() & 2) > 0; + } + get treatFunctionsAsVar() { + return this.treatFunctionsAsVarInScope(this.currentScope()); + } + createScope(flags) { + return new Scope$2(flags); + } + enter(flags) { + this.scopeStack.push(this.createScope(flags)); + } + exit() { + const scope$1 = this.scopeStack.pop(); + return scope$1.flags; + } + treatFunctionsAsVarInScope(scope$1) { + return !!(scope$1.flags & 130 || !this.parser.inModule && scope$1.flags & 1); + } + declareName(name, bindingType, loc) { + let scope$1 = this.currentScope(); + if (bindingType & 8 || bindingType & 16) { + this.checkRedeclarationInScope(scope$1, name, bindingType, loc); + let type = scope$1.names.get(name) || 0; + if (bindingType & 16) type = type | 4; + else { + if (!scope$1.firstLexicalName) scope$1.firstLexicalName = name; + type = type | 2; + } + scope$1.names.set(name, type); + if (bindingType & 8) this.maybeExportDefined(scope$1, name); + } else if (bindingType & 4) for (let i$5 = this.scopeStack.length - 1; i$5 >= 0; --i$5) { + scope$1 = this.scopeStack[i$5]; + this.checkRedeclarationInScope(scope$1, name, bindingType, loc); + scope$1.names.set(name, (scope$1.names.get(name) || 0) | 1); + this.maybeExportDefined(scope$1, name); + if (scope$1.flags & 387) break; + } + if (this.parser.inModule && scope$1.flags & 1) this.undefinedExports.delete(name); + } + maybeExportDefined(scope$1, name) { + if (this.parser.inModule && scope$1.flags & 1) this.undefinedExports.delete(name); + } + checkRedeclarationInScope(scope$1, name, bindingType, loc) { + if (this.isRedeclaredInScope(scope$1, name, bindingType)) this.parser.raise(Errors.VarRedeclaration, loc, { identifierName: name }); + } + isRedeclaredInScope(scope$1, name, bindingType) { + if (!(bindingType & 1)) return false; + if (bindingType & 8) return scope$1.names.has(name); + const type = scope$1.names.get(name); + if (bindingType & 16) return (type & 2) > 0 || !this.treatFunctionsAsVarInScope(scope$1) && (type & 1) > 0; + return (type & 2) > 0 && !(scope$1.flags & 8 && scope$1.firstLexicalName === name) || !this.treatFunctionsAsVarInScope(scope$1) && (type & 4) > 0; + } + checkLocalExport(id$4) { + const { name } = id$4; + const topLevelScope = this.scopeStack[0]; + if (!topLevelScope.names.has(name)) this.undefinedExports.set(name, id$4.loc.start); + } + currentScope() { + return this.scopeStack[this.scopeStack.length - 1]; + } + currentVarScopeFlags() { + for (let i$5 = this.scopeStack.length - 1;; i$5--) { + const { flags } = this.scopeStack[i$5]; + if (flags & 387) return flags; + } + } + currentThisScopeFlags() { + for (let i$5 = this.scopeStack.length - 1;; i$5--) { + const { flags } = this.scopeStack[i$5]; + if (flags & 451 && !(flags & 4)) return flags; + } + } + }; + var FlowScope = class extends Scope$2 { + constructor(...args) { + super(...args); + this.declareFunctions = new Set(); + } + }; + var FlowScopeHandler = class extends ScopeHandler { + createScope(flags) { + return new FlowScope(flags); + } + declareName(name, bindingType, loc) { + const scope$1 = this.currentScope(); + if (bindingType & 2048) { + this.checkRedeclarationInScope(scope$1, name, bindingType, loc); + this.maybeExportDefined(scope$1, name); + scope$1.declareFunctions.add(name); + return; + } + super.declareName(name, bindingType, loc); + } + isRedeclaredInScope(scope$1, name, bindingType) { + if (super.isRedeclaredInScope(scope$1, name, bindingType)) return true; + if (bindingType & 2048 && !scope$1.declareFunctions.has(name)) { + const type = scope$1.names.get(name); + return (type & 4) > 0 || (type & 2) > 0; + } + return false; + } + checkLocalExport(id$4) { + if (!this.scopeStack[0].declareFunctions.has(id$4.name)) super.checkLocalExport(id$4); + } + }; + var BaseParser = class { + constructor() { + this.sawUnambiguousESM = false; + this.ambiguousScriptDifferentAst = false; + } + sourceToOffsetPos(sourcePos) { + return sourcePos + this.startIndex; + } + offsetToSourcePos(offsetPos) { + return offsetPos - this.startIndex; + } + hasPlugin(pluginConfig) { + if (typeof pluginConfig === "string") return this.plugins.has(pluginConfig); + else { + const [pluginName, pluginOptions] = pluginConfig; + if (!this.hasPlugin(pluginName)) return false; + const actualOptions = this.plugins.get(pluginName); + for (const key of Object.keys(pluginOptions)) if ((actualOptions == null ? void 0 : actualOptions[key]) !== pluginOptions[key]) return false; + return true; + } + } + getPluginOption(plugin$2, name) { + var _this$plugins$get; + return (_this$plugins$get = this.plugins.get(plugin$2)) == null ? void 0 : _this$plugins$get[name]; + } + }; + function setTrailingComments(node, comments) { + if (node.trailingComments === void 0) node.trailingComments = comments; + else node.trailingComments.unshift(...comments); + } + function setLeadingComments(node, comments) { + if (node.leadingComments === void 0) node.leadingComments = comments; + else node.leadingComments.unshift(...comments); + } + function setInnerComments(node, comments) { + if (node.innerComments === void 0) node.innerComments = comments; + else node.innerComments.unshift(...comments); + } + function adjustInnerComments(node, elements, commentWS) { + let lastElement = null; + let i$5 = elements.length; + while (lastElement === null && i$5 > 0) lastElement = elements[--i$5]; + if (lastElement === null || lastElement.start > commentWS.start) setInnerComments(node, commentWS.comments); + else setTrailingComments(lastElement, commentWS.comments); + } + var CommentsParser = class extends BaseParser { + addComment(comment$7) { + if (this.filename) comment$7.loc.filename = this.filename; + const { commentsLen } = this.state; + if (this.comments.length !== commentsLen) this.comments.length = commentsLen; + this.comments.push(comment$7); + this.state.commentsLen++; + } + processComment(node) { + const { commentStack } = this.state; + const commentStackLength = commentStack.length; + if (commentStackLength === 0) return; + let i$5 = commentStackLength - 1; + const lastCommentWS = commentStack[i$5]; + if (lastCommentWS.start === node.end) { + lastCommentWS.leadingNode = node; + i$5--; + } + const { start: nodeStart } = node; + for (; i$5 >= 0; i$5--) { + const commentWS = commentStack[i$5]; + const commentEnd = commentWS.end; + if (commentEnd > nodeStart) { + commentWS.containingNode = node; + this.finalizeComment(commentWS); + commentStack.splice(i$5, 1); + } else { + if (commentEnd === nodeStart) commentWS.trailingNode = node; + break; + } + } + } + finalizeComment(commentWS) { + const { comments } = commentWS; + if (commentWS.leadingNode !== null || commentWS.trailingNode !== null) { + if (commentWS.leadingNode !== null) setTrailingComments(commentWS.leadingNode, comments); + if (commentWS.trailingNode !== null) setLeadingComments(commentWS.trailingNode, comments); + } else { + const { containingNode: node, start: commentStart } = commentWS; + if (this.input.charCodeAt(this.offsetToSourcePos(commentStart) - 1) === 44) switch (node.type) { + case "ObjectExpression": + case "ObjectPattern": + case "RecordExpression": + adjustInnerComments(node, node.properties, commentWS); + break; + case "CallExpression": + case "OptionalCallExpression": + adjustInnerComments(node, node.arguments, commentWS); + break; + case "FunctionDeclaration": + case "FunctionExpression": + case "ArrowFunctionExpression": + case "ObjectMethod": + case "ClassMethod": + case "ClassPrivateMethod": + adjustInnerComments(node, node.params, commentWS); + break; + case "ArrayExpression": + case "ArrayPattern": + case "TupleExpression": + adjustInnerComments(node, node.elements, commentWS); + break; + case "ExportNamedDeclaration": + case "ImportDeclaration": + adjustInnerComments(node, node.specifiers, commentWS); + break; + case "TSEnumDeclaration": + adjustInnerComments(node, node.members, commentWS); + break; + case "TSEnumBody": + adjustInnerComments(node, node.members, commentWS); + break; + default: setInnerComments(node, comments); + } + else setInnerComments(node, comments); + } + } + finalizeRemainingComments() { + const { commentStack } = this.state; + for (let i$5 = commentStack.length - 1; i$5 >= 0; i$5--) this.finalizeComment(commentStack[i$5]); + this.state.commentStack = []; + } + resetPreviousNodeTrailingComments(node) { + const { commentStack } = this.state; + const { length } = commentStack; + if (length === 0) return; + const commentWS = commentStack[length - 1]; + if (commentWS.leadingNode === node) commentWS.leadingNode = null; + } + resetPreviousIdentifierLeadingComments(node) { + const { commentStack } = this.state; + const { length } = commentStack; + if (length === 0) return; + if (commentStack[length - 1].trailingNode === node) commentStack[length - 1].trailingNode = null; + else if (length >= 2 && commentStack[length - 2].trailingNode === node) commentStack[length - 2].trailingNode = null; + } + takeSurroundingComments(node, start, end) { + const { commentStack } = this.state; + const commentStackLength = commentStack.length; + if (commentStackLength === 0) return; + let i$5 = commentStackLength - 1; + for (; i$5 >= 0; i$5--) { + const commentWS = commentStack[i$5]; + const commentEnd = commentWS.end; + const commentStart = commentWS.start; + if (commentStart === end) commentWS.leadingNode = node; + else if (commentEnd === start) commentWS.trailingNode = node; + else if (commentEnd < start) break; + } + } + }; + const lineBreak = /\r\n|[\r\n\u2028\u2029]/; + const lineBreakG = new RegExp(lineBreak.source, "g"); + function isNewLine(code$1) { + switch (code$1) { + case 10: + case 13: + case 8232: + case 8233: return true; + default: return false; + } + } + function hasNewLine(input, start, end) { + for (let i$5 = start; i$5 < end; i$5++) if (isNewLine(input.charCodeAt(i$5))) return true; + return false; + } + const skipWhiteSpace = /(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g; + const skipWhiteSpaceInLine = /(?:[^\S\n\r\u2028\u2029]|\/\/.*|\/\*.*?\*\/)*/g; + function isWhitespace(code$1) { + switch (code$1) { + case 9: + case 11: + case 12: + case 32: + case 160: + case 5760: + case 8192: + case 8193: + case 8194: + case 8195: + case 8196: + case 8197: + case 8198: + case 8199: + case 8200: + case 8201: + case 8202: + case 8239: + case 8287: + case 12288: + case 65279: return true; + default: return false; + } + } + var State = class State { + constructor() { + this.flags = 1024; + this.startIndex = void 0; + this.curLine = void 0; + this.lineStart = void 0; + this.startLoc = void 0; + this.endLoc = void 0; + this.errors = []; + this.potentialArrowAt = -1; + this.noArrowAt = []; + this.noArrowParamsConversionAt = []; + this.topicContext = { + maxNumOfResolvableTopics: 0, + maxTopicIndex: null + }; + this.labels = []; + this.commentsLen = 0; + this.commentStack = []; + this.pos = 0; + this.type = 140; + this.value = null; + this.start = 0; + this.end = 0; + this.lastTokEndLoc = null; + this.lastTokStartLoc = null; + this.context = [types$4.brace]; + this.firstInvalidTemplateEscapePos = null; + this.strictErrors = new Map(); + this.tokensLength = 0; + } + get strict() { + return (this.flags & 1) > 0; + } + set strict(v$1) { + if (v$1) this.flags |= 1; + else this.flags &= -2; + } + init({ strictMode, sourceType, startIndex, startLine, startColumn }) { + this.strict = strictMode === false ? false : strictMode === true ? true : sourceType === "module"; + this.startIndex = startIndex; + this.curLine = startLine; + this.lineStart = -startColumn; + this.startLoc = this.endLoc = new Position(startLine, startColumn, startIndex); + } + get maybeInArrowParameters() { + return (this.flags & 2) > 0; + } + set maybeInArrowParameters(v$1) { + if (v$1) this.flags |= 2; + else this.flags &= -3; + } + get inType() { + return (this.flags & 4) > 0; + } + set inType(v$1) { + if (v$1) this.flags |= 4; + else this.flags &= -5; + } + get noAnonFunctionType() { + return (this.flags & 8) > 0; + } + set noAnonFunctionType(v$1) { + if (v$1) this.flags |= 8; + else this.flags &= -9; + } + get hasFlowComment() { + return (this.flags & 16) > 0; + } + set hasFlowComment(v$1) { + if (v$1) this.flags |= 16; + else this.flags &= -17; + } + get isAmbientContext() { + return (this.flags & 32) > 0; + } + set isAmbientContext(v$1) { + if (v$1) this.flags |= 32; + else this.flags &= -33; + } + get inAbstractClass() { + return (this.flags & 64) > 0; + } + set inAbstractClass(v$1) { + if (v$1) this.flags |= 64; + else this.flags &= -65; + } + get inDisallowConditionalTypesContext() { + return (this.flags & 128) > 0; + } + set inDisallowConditionalTypesContext(v$1) { + if (v$1) this.flags |= 128; + else this.flags &= -129; + } + get soloAwait() { + return (this.flags & 256) > 0; + } + set soloAwait(v$1) { + if (v$1) this.flags |= 256; + else this.flags &= -257; + } + get inFSharpPipelineDirectBody() { + return (this.flags & 512) > 0; + } + set inFSharpPipelineDirectBody(v$1) { + if (v$1) this.flags |= 512; + else this.flags &= -513; + } + get canStartJSXElement() { + return (this.flags & 1024) > 0; + } + set canStartJSXElement(v$1) { + if (v$1) this.flags |= 1024; + else this.flags &= -1025; + } + get containsEsc() { + return (this.flags & 2048) > 0; + } + set containsEsc(v$1) { + if (v$1) this.flags |= 2048; + else this.flags &= -2049; + } + get hasTopLevelAwait() { + return (this.flags & 4096) > 0; + } + set hasTopLevelAwait(v$1) { + if (v$1) this.flags |= 4096; + else this.flags &= -4097; + } + curPosition() { + return new Position(this.curLine, this.pos - this.lineStart, this.pos + this.startIndex); + } + clone() { + const state = new State(); + state.flags = this.flags; + state.startIndex = this.startIndex; + state.curLine = this.curLine; + state.lineStart = this.lineStart; + state.startLoc = this.startLoc; + state.endLoc = this.endLoc; + state.errors = this.errors.slice(); + state.potentialArrowAt = this.potentialArrowAt; + state.noArrowAt = this.noArrowAt.slice(); + state.noArrowParamsConversionAt = this.noArrowParamsConversionAt.slice(); + state.topicContext = this.topicContext; + state.labels = this.labels.slice(); + state.commentsLen = this.commentsLen; + state.commentStack = this.commentStack.slice(); + state.pos = this.pos; + state.type = this.type; + state.value = this.value; + state.start = this.start; + state.end = this.end; + state.lastTokEndLoc = this.lastTokEndLoc; + state.lastTokStartLoc = this.lastTokStartLoc; + state.context = this.context.slice(); + state.firstInvalidTemplateEscapePos = this.firstInvalidTemplateEscapePos; + state.strictErrors = this.strictErrors; + state.tokensLength = this.tokensLength; + return state; + } + }; + var _isDigit$1 = function isDigit(code$1) { + return code$1 >= 48 && code$1 <= 57; + }; + const forbiddenNumericSeparatorSiblings$1 = { + decBinOct: new Set([ + 46, + 66, + 69, + 79, + 95, + 98, + 101, + 111 + ]), + hex: new Set([ + 46, + 88, + 95, + 120 + ]) + }; + const isAllowedNumericSeparatorSibling$1 = { + bin: (ch) => ch === 48 || ch === 49, + oct: (ch) => ch >= 48 && ch <= 55, + dec: (ch) => ch >= 48 && ch <= 57, + hex: (ch) => ch >= 48 && ch <= 57 || ch >= 65 && ch <= 70 || ch >= 97 && ch <= 102 + }; + function readStringContents$1(type, input, pos, lineStart, curLine, errors) { + const initialPos = pos; + const initialLineStart = lineStart; + const initialCurLine = curLine; + let out = ""; + let firstInvalidLoc = null; + let chunkStart = pos; + const { length } = input; + for (;;) { + if (pos >= length) { + errors.unterminated(initialPos, initialLineStart, initialCurLine); + out += input.slice(chunkStart, pos); + break; + } + const ch = input.charCodeAt(pos); + if (isStringEnd$1(type, ch, input, pos)) { + out += input.slice(chunkStart, pos); + break; + } + if (ch === 92) { + out += input.slice(chunkStart, pos); + const res = readEscapedChar$1(input, pos, lineStart, curLine, type === "template", errors); + if (res.ch === null && !firstInvalidLoc) firstInvalidLoc = { + pos, + lineStart, + curLine + }; + else out += res.ch; + ({pos, lineStart, curLine} = res); + chunkStart = pos; + } else if (ch === 8232 || ch === 8233) { + ++pos; + ++curLine; + lineStart = pos; + } else if (ch === 10 || ch === 13) if (type === "template") { + out += input.slice(chunkStart, pos) + "\n"; + ++pos; + if (ch === 13 && input.charCodeAt(pos) === 10) ++pos; + ++curLine; + chunkStart = lineStart = pos; + } else errors.unterminated(initialPos, initialLineStart, initialCurLine); + else ++pos; + } + return { + pos, + str: out, + firstInvalidLoc, + lineStart, + curLine, + containsInvalid: !!firstInvalidLoc + }; + } + function isStringEnd$1(type, ch, input, pos) { + if (type === "template") return ch === 96 || ch === 36 && input.charCodeAt(pos + 1) === 123; + return ch === (type === "double" ? 34 : 39); + } + function readEscapedChar$1(input, pos, lineStart, curLine, inTemplate, errors) { + const throwOnInvalid = !inTemplate; + pos++; + const res = (ch$1) => ({ + pos, + ch: ch$1, + lineStart, + curLine + }); + const ch = input.charCodeAt(pos++); + switch (ch) { + case 110: return res("\n"); + case 114: return res("\r"); + case 120: { + let code$1; + ({code: code$1, pos} = readHexChar$1(input, pos, lineStart, curLine, 2, false, throwOnInvalid, errors)); + return res(code$1 === null ? null : String.fromCharCode(code$1)); + } + case 117: { + let code$1; + ({code: code$1, pos} = readCodePoint$1(input, pos, lineStart, curLine, throwOnInvalid, errors)); + return res(code$1 === null ? null : String.fromCodePoint(code$1)); + } + case 116: return res(" "); + case 98: return res("\b"); + case 118: return res("\v"); + case 102: return res("\f"); + case 13: if (input.charCodeAt(pos) === 10) ++pos; + case 10: + lineStart = pos; + ++curLine; + case 8232: + case 8233: return res(""); + case 56: + case 57: if (inTemplate) return res(null); + else errors.strictNumericEscape(pos - 1, lineStart, curLine); + default: + if (ch >= 48 && ch <= 55) { + const startPos = pos - 1; + const match = /^[0-7]+/.exec(input.slice(startPos, pos + 2)); + let octalStr = match[0]; + let octal = parseInt(octalStr, 8); + if (octal > 255) { + octalStr = octalStr.slice(0, -1); + octal = parseInt(octalStr, 8); + } + pos += octalStr.length - 1; + const next = input.charCodeAt(pos); + if (octalStr !== "0" || next === 56 || next === 57) if (inTemplate) return res(null); + else errors.strictNumericEscape(startPos, lineStart, curLine); + return res(String.fromCharCode(octal)); + } + return res(String.fromCharCode(ch)); + } + } + function readHexChar$1(input, pos, lineStart, curLine, len, forceLen, throwOnInvalid, errors) { + const initialPos = pos; + let n$3; + ({n: n$3, pos} = readInt$1(input, pos, lineStart, curLine, 16, len, forceLen, false, errors, !throwOnInvalid)); + if (n$3 === null) if (throwOnInvalid) errors.invalidEscapeSequence(initialPos, lineStart, curLine); + else pos = initialPos - 1; + return { + code: n$3, + pos + }; + } + function readInt$1(input, pos, lineStart, curLine, radix, len, forceLen, allowNumSeparator, errors, bailOnError) { + const start = pos; + const forbiddenSiblings = radix === 16 ? forbiddenNumericSeparatorSiblings$1.hex : forbiddenNumericSeparatorSiblings$1.decBinOct; + const isAllowedSibling = radix === 16 ? isAllowedNumericSeparatorSibling$1.hex : radix === 10 ? isAllowedNumericSeparatorSibling$1.dec : radix === 8 ? isAllowedNumericSeparatorSibling$1.oct : isAllowedNumericSeparatorSibling$1.bin; + let invalid = false; + let total = 0; + for (let i$5 = 0, e = len == null ? Infinity : len; i$5 < e; ++i$5) { + const code$1 = input.charCodeAt(pos); + let val; + if (code$1 === 95 && allowNumSeparator !== "bail") { + const prev = input.charCodeAt(pos - 1); + const next = input.charCodeAt(pos + 1); + if (!allowNumSeparator) { + if (bailOnError) return { + n: null, + pos + }; + errors.numericSeparatorInEscapeSequence(pos, lineStart, curLine); + } else if (Number.isNaN(next) || !isAllowedSibling(next) || forbiddenSiblings.has(prev) || forbiddenSiblings.has(next)) { + if (bailOnError) return { + n: null, + pos + }; + errors.unexpectedNumericSeparator(pos, lineStart, curLine); + } + ++pos; + continue; + } + if (code$1 >= 97) val = code$1 - 97 + 10; + else if (code$1 >= 65) val = code$1 - 65 + 10; + else if (_isDigit$1(code$1)) val = code$1 - 48; + else val = Infinity; + if (val >= radix) if (val <= 9 && bailOnError) return { + n: null, + pos + }; + else if (val <= 9 && errors.invalidDigit(pos, lineStart, curLine, radix)) val = 0; + else if (forceLen) { + val = 0; + invalid = true; + } else break; + ++pos; + total = total * radix + val; + } + if (pos === start || len != null && pos - start !== len || invalid) return { + n: null, + pos + }; + return { + n: total, + pos + }; + } + function readCodePoint$1(input, pos, lineStart, curLine, throwOnInvalid, errors) { + const ch = input.charCodeAt(pos); + let code$1; + if (ch === 123) { + ++pos; + ({code: code$1, pos} = readHexChar$1(input, pos, lineStart, curLine, input.indexOf("}", pos) - pos, true, throwOnInvalid, errors)); + ++pos; + if (code$1 !== null && code$1 > 1114111) if (throwOnInvalid) errors.invalidCodePoint(pos, lineStart, curLine); + else return { + code: null, + pos + }; + } else ({code: code$1, pos} = readHexChar$1(input, pos, lineStart, curLine, 4, false, throwOnInvalid, errors)); + return { + code: code$1, + pos + }; + } + function buildPosition(pos, lineStart, curLine) { + return new Position(curLine, pos - lineStart, pos); + } + const VALID_REGEX_FLAGS = new Set([ + 103, + 109, + 115, + 105, + 121, + 117, + 100, + 118 + ]); + var Token = class { + constructor(state) { + const startIndex = state.startIndex || 0; + this.type = state.type; + this.value = state.value; + this.start = startIndex + state.start; + this.end = startIndex + state.end; + this.loc = new SourceLocation$1(state.startLoc, state.endLoc); + } + }; + var Tokenizer$1 = class extends CommentsParser { + constructor(options, input) { + super(); + this.isLookahead = void 0; + this.tokens = []; + this.errorHandlers_readInt = { + invalidDigit: (pos, lineStart, curLine, radix) => { + if (!(this.optionFlags & 2048)) return false; + this.raise(Errors.InvalidDigit, buildPosition(pos, lineStart, curLine), { radix }); + return true; + }, + numericSeparatorInEscapeSequence: this.errorBuilder(Errors.NumericSeparatorInEscapeSequence), + unexpectedNumericSeparator: this.errorBuilder(Errors.UnexpectedNumericSeparator) + }; + this.errorHandlers_readCodePoint = Object.assign({}, this.errorHandlers_readInt, { + invalidEscapeSequence: this.errorBuilder(Errors.InvalidEscapeSequence), + invalidCodePoint: this.errorBuilder(Errors.InvalidCodePoint) + }); + this.errorHandlers_readStringContents_string = Object.assign({}, this.errorHandlers_readCodePoint, { + strictNumericEscape: (pos, lineStart, curLine) => { + this.recordStrictModeErrors(Errors.StrictNumericEscape, buildPosition(pos, lineStart, curLine)); + }, + unterminated: (pos, lineStart, curLine) => { + throw this.raise(Errors.UnterminatedString, buildPosition(pos - 1, lineStart, curLine)); + } + }); + this.errorHandlers_readStringContents_template = Object.assign({}, this.errorHandlers_readCodePoint, { + strictNumericEscape: this.errorBuilder(Errors.StrictNumericEscape), + unterminated: (pos, lineStart, curLine) => { + throw this.raise(Errors.UnterminatedTemplate, buildPosition(pos, lineStart, curLine)); + } + }); + this.state = new State(); + this.state.init(options); + this.input = input; + this.length = input.length; + this.comments = []; + this.isLookahead = false; + } + pushToken(token$1) { + this.tokens.length = this.state.tokensLength; + this.tokens.push(token$1); + ++this.state.tokensLength; + } + next() { + this.checkKeywordEscapes(); + if (this.optionFlags & 256) this.pushToken(new Token(this.state)); + this.state.lastTokEndLoc = this.state.endLoc; + this.state.lastTokStartLoc = this.state.startLoc; + this.nextToken(); + } + eat(type) { + if (this.match(type)) { + this.next(); + return true; + } else return false; + } + match(type) { + return this.state.type === type; + } + createLookaheadState(state) { + return { + pos: state.pos, + value: null, + type: state.type, + start: state.start, + end: state.end, + context: [this.curContext()], + inType: state.inType, + startLoc: state.startLoc, + lastTokEndLoc: state.lastTokEndLoc, + curLine: state.curLine, + lineStart: state.lineStart, + curPosition: state.curPosition + }; + } + lookahead() { + const old$1 = this.state; + this.state = this.createLookaheadState(old$1); + this.isLookahead = true; + this.nextToken(); + this.isLookahead = false; + const curr = this.state; + this.state = old$1; + return curr; + } + nextTokenStart() { + return this.nextTokenStartSince(this.state.pos); + } + nextTokenStartSince(pos) { + skipWhiteSpace.lastIndex = pos; + return skipWhiteSpace.test(this.input) ? skipWhiteSpace.lastIndex : pos; + } + lookaheadCharCode() { + return this.input.charCodeAt(this.nextTokenStart()); + } + nextTokenInLineStart() { + return this.nextTokenInLineStartSince(this.state.pos); + } + nextTokenInLineStartSince(pos) { + skipWhiteSpaceInLine.lastIndex = pos; + return skipWhiteSpaceInLine.test(this.input) ? skipWhiteSpaceInLine.lastIndex : pos; + } + lookaheadInLineCharCode() { + return this.input.charCodeAt(this.nextTokenInLineStart()); + } + codePointAtPos(pos) { + let cp = this.input.charCodeAt(pos); + if ((cp & 64512) === 55296 && ++pos < this.input.length) { + const trail = this.input.charCodeAt(pos); + if ((trail & 64512) === 56320) cp = 65536 + ((cp & 1023) << 10) + (trail & 1023); + } + return cp; + } + setStrict(strict) { + this.state.strict = strict; + if (strict) { + this.state.strictErrors.forEach(([toParseError, at$3]) => this.raise(toParseError, at$3)); + this.state.strictErrors.clear(); + } + } + curContext() { + return this.state.context[this.state.context.length - 1]; + } + nextToken() { + this.skipSpace(); + this.state.start = this.state.pos; + if (!this.isLookahead) this.state.startLoc = this.state.curPosition(); + if (this.state.pos >= this.length) { + this.finishToken(140); + return; + } + this.getTokenFromCode(this.codePointAtPos(this.state.pos)); + } + skipBlockComment(commentEnd) { + let startLoc; + if (!this.isLookahead) startLoc = this.state.curPosition(); + const start = this.state.pos; + const end = this.input.indexOf(commentEnd, start + 2); + if (end === -1) throw this.raise(Errors.UnterminatedComment, this.state.curPosition()); + this.state.pos = end + commentEnd.length; + lineBreakG.lastIndex = start + 2; + while (lineBreakG.test(this.input) && lineBreakG.lastIndex <= end) { + ++this.state.curLine; + this.state.lineStart = lineBreakG.lastIndex; + } + if (this.isLookahead) return; + const comment$7 = { + type: "CommentBlock", + value: this.input.slice(start + 2, end), + start: this.sourceToOffsetPos(start), + end: this.sourceToOffsetPos(end + commentEnd.length), + loc: new SourceLocation$1(startLoc, this.state.curPosition()) + }; + if (this.optionFlags & 256) this.pushToken(comment$7); + return comment$7; + } + skipLineComment(startSkip) { + const start = this.state.pos; + let startLoc; + if (!this.isLookahead) startLoc = this.state.curPosition(); + let ch = this.input.charCodeAt(this.state.pos += startSkip); + if (this.state.pos < this.length) while (!isNewLine(ch) && ++this.state.pos < this.length) ch = this.input.charCodeAt(this.state.pos); + if (this.isLookahead) return; + const end = this.state.pos; + const value = this.input.slice(start + startSkip, end); + const comment$7 = { + type: "CommentLine", + value, + start: this.sourceToOffsetPos(start), + end: this.sourceToOffsetPos(end), + loc: new SourceLocation$1(startLoc, this.state.curPosition()) + }; + if (this.optionFlags & 256) this.pushToken(comment$7); + return comment$7; + } + skipSpace() { + const spaceStart = this.state.pos; + const comments = this.optionFlags & 4096 ? [] : null; + loop: while (this.state.pos < this.length) { + const ch = this.input.charCodeAt(this.state.pos); + switch (ch) { + case 32: + case 160: + case 9: + ++this.state.pos; + break; + case 13: if (this.input.charCodeAt(this.state.pos + 1) === 10) ++this.state.pos; + case 10: + case 8232: + case 8233: + ++this.state.pos; + ++this.state.curLine; + this.state.lineStart = this.state.pos; + break; + case 47: + switch (this.input.charCodeAt(this.state.pos + 1)) { + case 42: { + const comment$7 = this.skipBlockComment("*/"); + if (comment$7 !== void 0) { + this.addComment(comment$7); + comments?.push(comment$7); + } + break; + } + case 47: { + const comment$7 = this.skipLineComment(2); + if (comment$7 !== void 0) { + this.addComment(comment$7); + comments?.push(comment$7); + } + break; + } + default: break loop; + } + break; + default: if (isWhitespace(ch)) ++this.state.pos; + else if (ch === 45 && !this.inModule && this.optionFlags & 8192) { + const pos = this.state.pos; + if (this.input.charCodeAt(pos + 1) === 45 && this.input.charCodeAt(pos + 2) === 62 && (spaceStart === 0 || this.state.lineStart > spaceStart)) { + const comment$7 = this.skipLineComment(3); + if (comment$7 !== void 0) { + this.addComment(comment$7); + comments?.push(comment$7); + } + } else break loop; + } else if (ch === 60 && !this.inModule && this.optionFlags & 8192) { + const pos = this.state.pos; + if (this.input.charCodeAt(pos + 1) === 33 && this.input.charCodeAt(pos + 2) === 45 && this.input.charCodeAt(pos + 3) === 45) { + const comment$7 = this.skipLineComment(4); + if (comment$7 !== void 0) { + this.addComment(comment$7); + comments?.push(comment$7); + } + } else break loop; + } else break loop; + } + } + if ((comments == null ? void 0 : comments.length) > 0) { + const end = this.state.pos; + const commentWhitespace = { + start: this.sourceToOffsetPos(spaceStart), + end: this.sourceToOffsetPos(end), + comments, + leadingNode: null, + trailingNode: null, + containingNode: null + }; + this.state.commentStack.push(commentWhitespace); + } + } + finishToken(type, val) { + this.state.end = this.state.pos; + this.state.endLoc = this.state.curPosition(); + const prevType = this.state.type; + this.state.type = type; + this.state.value = val; + if (!this.isLookahead) this.updateContext(prevType); + } + replaceToken(type) { + this.state.type = type; + this.updateContext(); + } + readToken_numberSign() { + if (this.state.pos === 0 && this.readToken_interpreter()) return; + const nextPos = this.state.pos + 1; + const next = this.codePointAtPos(nextPos); + if (next >= 48 && next <= 57) throw this.raise(Errors.UnexpectedDigitAfterHash, this.state.curPosition()); + if (next === 123 || next === 91 && this.hasPlugin("recordAndTuple")) { + this.expectPlugin("recordAndTuple"); + if (this.getPluginOption("recordAndTuple", "syntaxType") === "bar") throw this.raise(next === 123 ? Errors.RecordExpressionHashIncorrectStartSyntaxType : Errors.TupleExpressionHashIncorrectStartSyntaxType, this.state.curPosition()); + this.state.pos += 2; + if (next === 123) this.finishToken(7); + else this.finishToken(1); + } else if (isIdentifierStart$1(next)) { + ++this.state.pos; + this.finishToken(139, this.readWord1(next)); + } else if (next === 92) { + ++this.state.pos; + this.finishToken(139, this.readWord1()); + } else this.finishOp(27, 1); + } + readToken_dot() { + const next = this.input.charCodeAt(this.state.pos + 1); + if (next >= 48 && next <= 57) { + this.readNumber(true); + return; + } + if (next === 46 && this.input.charCodeAt(this.state.pos + 2) === 46) { + this.state.pos += 3; + this.finishToken(21); + } else { + ++this.state.pos; + this.finishToken(16); + } + } + readToken_slash() { + const next = this.input.charCodeAt(this.state.pos + 1); + if (next === 61) this.finishOp(31, 2); + else this.finishOp(56, 1); + } + readToken_interpreter() { + if (this.state.pos !== 0 || this.length < 2) return false; + let ch = this.input.charCodeAt(this.state.pos + 1); + if (ch !== 33) return false; + const start = this.state.pos; + this.state.pos += 1; + while (!isNewLine(ch) && ++this.state.pos < this.length) ch = this.input.charCodeAt(this.state.pos); + const value = this.input.slice(start + 2, this.state.pos); + this.finishToken(28, value); + return true; + } + readToken_mult_modulo(code$1) { + let type = code$1 === 42 ? 55 : 54; + let width = 1; + let next = this.input.charCodeAt(this.state.pos + 1); + if (code$1 === 42 && next === 42) { + width++; + next = this.input.charCodeAt(this.state.pos + 2); + type = 57; + } + if (next === 61 && !this.state.inType) { + width++; + type = code$1 === 37 ? 33 : 30; + } + this.finishOp(type, width); + } + readToken_pipe_amp(code$1) { + const next = this.input.charCodeAt(this.state.pos + 1); + if (next === code$1) { + if (this.input.charCodeAt(this.state.pos + 2) === 61) this.finishOp(30, 3); + else this.finishOp(code$1 === 124 ? 41 : 42, 2); + return; + } + if (code$1 === 124) { + if (next === 62) { + this.finishOp(39, 2); + return; + } + if (this.hasPlugin("recordAndTuple") && next === 125) { + if (this.getPluginOption("recordAndTuple", "syntaxType") !== "bar") throw this.raise(Errors.RecordExpressionBarIncorrectEndSyntaxType, this.state.curPosition()); + this.state.pos += 2; + this.finishToken(9); + return; + } + if (this.hasPlugin("recordAndTuple") && next === 93) { + if (this.getPluginOption("recordAndTuple", "syntaxType") !== "bar") throw this.raise(Errors.TupleExpressionBarIncorrectEndSyntaxType, this.state.curPosition()); + this.state.pos += 2; + this.finishToken(4); + return; + } + } + if (next === 61) { + this.finishOp(30, 2); + return; + } + this.finishOp(code$1 === 124 ? 43 : 45, 1); + } + readToken_caret() { + const next = this.input.charCodeAt(this.state.pos + 1); + if (next === 61 && !this.state.inType) this.finishOp(32, 2); + else if (next === 94 && this.hasPlugin(["pipelineOperator", { + proposal: "hack", + topicToken: "^^" + }])) { + this.finishOp(37, 2); + const lookaheadCh = this.input.codePointAt(this.state.pos); + if (lookaheadCh === 94) this.unexpected(); + } else this.finishOp(44, 1); + } + readToken_atSign() { + const next = this.input.charCodeAt(this.state.pos + 1); + if (next === 64 && this.hasPlugin(["pipelineOperator", { + proposal: "hack", + topicToken: "@@" + }])) this.finishOp(38, 2); + else this.finishOp(26, 1); + } + readToken_plus_min(code$1) { + const next = this.input.charCodeAt(this.state.pos + 1); + if (next === code$1) { + this.finishOp(34, 2); + return; + } + if (next === 61) this.finishOp(30, 2); + else this.finishOp(53, 1); + } + readToken_lt() { + const { pos } = this.state; + const next = this.input.charCodeAt(pos + 1); + if (next === 60) { + if (this.input.charCodeAt(pos + 2) === 61) { + this.finishOp(30, 3); + return; + } + this.finishOp(51, 2); + return; + } + if (next === 61) { + this.finishOp(49, 2); + return; + } + this.finishOp(47, 1); + } + readToken_gt() { + const { pos } = this.state; + const next = this.input.charCodeAt(pos + 1); + if (next === 62) { + const size$1 = this.input.charCodeAt(pos + 2) === 62 ? 3 : 2; + if (this.input.charCodeAt(pos + size$1) === 61) { + this.finishOp(30, size$1 + 1); + return; + } + this.finishOp(52, size$1); + return; + } + if (next === 61) { + this.finishOp(49, 2); + return; + } + this.finishOp(48, 1); + } + readToken_eq_excl(code$1) { + const next = this.input.charCodeAt(this.state.pos + 1); + if (next === 61) { + this.finishOp(46, this.input.charCodeAt(this.state.pos + 2) === 61 ? 3 : 2); + return; + } + if (code$1 === 61 && next === 62) { + this.state.pos += 2; + this.finishToken(19); + return; + } + this.finishOp(code$1 === 61 ? 29 : 35, 1); + } + readToken_question() { + const next = this.input.charCodeAt(this.state.pos + 1); + const next2 = this.input.charCodeAt(this.state.pos + 2); + if (next === 63) if (next2 === 61) this.finishOp(30, 3); + else this.finishOp(40, 2); + else if (next === 46 && !(next2 >= 48 && next2 <= 57)) { + this.state.pos += 2; + this.finishToken(18); + } else { + ++this.state.pos; + this.finishToken(17); + } + } + getTokenFromCode(code$1) { + switch (code$1) { + case 46: + this.readToken_dot(); + return; + case 40: + ++this.state.pos; + this.finishToken(10); + return; + case 41: + ++this.state.pos; + this.finishToken(11); + return; + case 59: + ++this.state.pos; + this.finishToken(13); + return; + case 44: + ++this.state.pos; + this.finishToken(12); + return; + case 91: + if (this.hasPlugin("recordAndTuple") && this.input.charCodeAt(this.state.pos + 1) === 124) { + if (this.getPluginOption("recordAndTuple", "syntaxType") !== "bar") throw this.raise(Errors.TupleExpressionBarIncorrectStartSyntaxType, this.state.curPosition()); + this.state.pos += 2; + this.finishToken(2); + } else { + ++this.state.pos; + this.finishToken(0); + } + return; + case 93: + ++this.state.pos; + this.finishToken(3); + return; + case 123: + if (this.hasPlugin("recordAndTuple") && this.input.charCodeAt(this.state.pos + 1) === 124) { + if (this.getPluginOption("recordAndTuple", "syntaxType") !== "bar") throw this.raise(Errors.RecordExpressionBarIncorrectStartSyntaxType, this.state.curPosition()); + this.state.pos += 2; + this.finishToken(6); + } else { + ++this.state.pos; + this.finishToken(5); + } + return; + case 125: + ++this.state.pos; + this.finishToken(8); + return; + case 58: + if (this.hasPlugin("functionBind") && this.input.charCodeAt(this.state.pos + 1) === 58) this.finishOp(15, 2); + else { + ++this.state.pos; + this.finishToken(14); + } + return; + case 63: + this.readToken_question(); + return; + case 96: + this.readTemplateToken(); + return; + case 48: { + const next = this.input.charCodeAt(this.state.pos + 1); + if (next === 120 || next === 88) { + this.readRadixNumber(16); + return; + } + if (next === 111 || next === 79) { + this.readRadixNumber(8); + return; + } + if (next === 98 || next === 66) { + this.readRadixNumber(2); + return; + } + } + case 49: + case 50: + case 51: + case 52: + case 53: + case 54: + case 55: + case 56: + case 57: + this.readNumber(false); + return; + case 34: + case 39: + this.readString(code$1); + return; + case 47: + this.readToken_slash(); + return; + case 37: + case 42: + this.readToken_mult_modulo(code$1); + return; + case 124: + case 38: + this.readToken_pipe_amp(code$1); + return; + case 94: + this.readToken_caret(); + return; + case 43: + case 45: + this.readToken_plus_min(code$1); + return; + case 60: + this.readToken_lt(); + return; + case 62: + this.readToken_gt(); + return; + case 61: + case 33: + this.readToken_eq_excl(code$1); + return; + case 126: + this.finishOp(36, 1); + return; + case 64: + this.readToken_atSign(); + return; + case 35: + this.readToken_numberSign(); + return; + case 92: + this.readWord(); + return; + default: if (isIdentifierStart$1(code$1)) { + this.readWord(code$1); + return; + } + } + throw this.raise(Errors.InvalidOrUnexpectedToken, this.state.curPosition(), { unexpected: String.fromCodePoint(code$1) }); + } + finishOp(type, size$1) { + const str$3 = this.input.slice(this.state.pos, this.state.pos + size$1); + this.state.pos += size$1; + this.finishToken(type, str$3); + } + readRegexp() { + const startLoc = this.state.startLoc; + const start = this.state.start + 1; + let escaped, inClass; + let { pos } = this.state; + for (;; ++pos) { + if (pos >= this.length) throw this.raise(Errors.UnterminatedRegExp, createPositionWithColumnOffset(startLoc, 1)); + const ch = this.input.charCodeAt(pos); + if (isNewLine(ch)) throw this.raise(Errors.UnterminatedRegExp, createPositionWithColumnOffset(startLoc, 1)); + if (escaped) escaped = false; + else { + if (ch === 91) inClass = true; + else if (ch === 93 && inClass) inClass = false; + else if (ch === 47 && !inClass) break; + escaped = ch === 92; + } + } + const content = this.input.slice(start, pos); + ++pos; + let mods = ""; + const nextPos = () => createPositionWithColumnOffset(startLoc, pos + 2 - start); + while (pos < this.length) { + const cp = this.codePointAtPos(pos); + const char = String.fromCharCode(cp); + if (VALID_REGEX_FLAGS.has(cp)) { + if (cp === 118) { + if (mods.includes("u")) this.raise(Errors.IncompatibleRegExpUVFlags, nextPos()); + } else if (cp === 117) { + if (mods.includes("v")) this.raise(Errors.IncompatibleRegExpUVFlags, nextPos()); + } + if (mods.includes(char)) this.raise(Errors.DuplicateRegExpFlags, nextPos()); + } else if (isIdentifierChar$1(cp) || cp === 92) this.raise(Errors.MalformedRegExpFlags, nextPos()); + else break; + ++pos; + mods += char; + } + this.state.pos = pos; + this.finishToken(138, { + pattern: content, + flags: mods + }); + } + readInt(radix, len, forceLen = false, allowNumSeparator = true) { + const { n: n$3, pos } = readInt$1(this.input, this.state.pos, this.state.lineStart, this.state.curLine, radix, len, forceLen, allowNumSeparator, this.errorHandlers_readInt, false); + this.state.pos = pos; + return n$3; + } + readRadixNumber(radix) { + const start = this.state.pos; + const startLoc = this.state.curPosition(); + let isBigInt$1 = false; + this.state.pos += 2; + const val = this.readInt(radix); + if (val == null) this.raise(Errors.InvalidDigit, createPositionWithColumnOffset(startLoc, 2), { radix }); + const next = this.input.charCodeAt(this.state.pos); + if (next === 110) { + ++this.state.pos; + isBigInt$1 = true; + } else if (next === 109) throw this.raise(Errors.InvalidDecimal, startLoc); + if (isIdentifierStart$1(this.codePointAtPos(this.state.pos))) throw this.raise(Errors.NumberIdentifier, this.state.curPosition()); + if (isBigInt$1) { + const str$3 = this.input.slice(start, this.state.pos).replace(/[_n]/g, ""); + this.finishToken(136, str$3); + return; + } + this.finishToken(135, val); + } + readNumber(startsWithDot) { + const start = this.state.pos; + const startLoc = this.state.curPosition(); + let isFloat = false; + let isBigInt$1 = false; + let hasExponent = false; + let isOctal = false; + if (!startsWithDot && this.readInt(10) === null) this.raise(Errors.InvalidNumber, this.state.curPosition()); + const hasLeadingZero = this.state.pos - start >= 2 && this.input.charCodeAt(start) === 48; + if (hasLeadingZero) { + const integer = this.input.slice(start, this.state.pos); + this.recordStrictModeErrors(Errors.StrictOctalLiteral, startLoc); + if (!this.state.strict) { + const underscorePos = integer.indexOf("_"); + if (underscorePos > 0) this.raise(Errors.ZeroDigitNumericSeparator, createPositionWithColumnOffset(startLoc, underscorePos)); + } + isOctal = hasLeadingZero && !/[89]/.test(integer); + } + let next = this.input.charCodeAt(this.state.pos); + if (next === 46 && !isOctal) { + ++this.state.pos; + this.readInt(10); + isFloat = true; + next = this.input.charCodeAt(this.state.pos); + } + if ((next === 69 || next === 101) && !isOctal) { + next = this.input.charCodeAt(++this.state.pos); + if (next === 43 || next === 45) ++this.state.pos; + if (this.readInt(10) === null) this.raise(Errors.InvalidOrMissingExponent, startLoc); + isFloat = true; + hasExponent = true; + next = this.input.charCodeAt(this.state.pos); + } + if (next === 110) { + if (isFloat || hasLeadingZero) this.raise(Errors.InvalidBigIntLiteral, startLoc); + ++this.state.pos; + isBigInt$1 = true; + } + if (next === 109) { + this.expectPlugin("decimal", this.state.curPosition()); + if (hasExponent || hasLeadingZero) this.raise(Errors.InvalidDecimal, startLoc); + ++this.state.pos; + var isDecimal = true; + } + if (isIdentifierStart$1(this.codePointAtPos(this.state.pos))) throw this.raise(Errors.NumberIdentifier, this.state.curPosition()); + const str$3 = this.input.slice(start, this.state.pos).replace(/[_mn]/g, ""); + if (isBigInt$1) { + this.finishToken(136, str$3); + return; + } + if (isDecimal) { + this.finishToken(137, str$3); + return; + } + const val = isOctal ? parseInt(str$3, 8) : parseFloat(str$3); + this.finishToken(135, val); + } + readCodePoint(throwOnInvalid) { + const { code: code$1, pos } = readCodePoint$1(this.input, this.state.pos, this.state.lineStart, this.state.curLine, throwOnInvalid, this.errorHandlers_readCodePoint); + this.state.pos = pos; + return code$1; + } + readString(quote) { + const { str: str$3, pos, curLine, lineStart } = readStringContents$1(quote === 34 ? "double" : "single", this.input, this.state.pos + 1, this.state.lineStart, this.state.curLine, this.errorHandlers_readStringContents_string); + this.state.pos = pos + 1; + this.state.lineStart = lineStart; + this.state.curLine = curLine; + this.finishToken(134, str$3); + } + readTemplateContinuation() { + if (!this.match(8)) this.unexpected(null, 8); + this.state.pos--; + this.readTemplateToken(); + } + readTemplateToken() { + const opening = this.input[this.state.pos]; + const { str: str$3, firstInvalidLoc, pos, curLine, lineStart } = readStringContents$1("template", this.input, this.state.pos + 1, this.state.lineStart, this.state.curLine, this.errorHandlers_readStringContents_template); + this.state.pos = pos + 1; + this.state.lineStart = lineStart; + this.state.curLine = curLine; + if (firstInvalidLoc) this.state.firstInvalidTemplateEscapePos = new Position(firstInvalidLoc.curLine, firstInvalidLoc.pos - firstInvalidLoc.lineStart, this.sourceToOffsetPos(firstInvalidLoc.pos)); + if (this.input.codePointAt(pos) === 96) this.finishToken(24, firstInvalidLoc ? null : opening + str$3 + "`"); + else { + this.state.pos++; + this.finishToken(25, firstInvalidLoc ? null : opening + str$3 + "${"); + } + } + recordStrictModeErrors(toParseError, at$3) { + const index$1 = at$3.index; + if (this.state.strict && !this.state.strictErrors.has(index$1)) this.raise(toParseError, at$3); + else this.state.strictErrors.set(index$1, [toParseError, at$3]); + } + readWord1(firstCode) { + this.state.containsEsc = false; + let word$3 = ""; + const start = this.state.pos; + let chunkStart = this.state.pos; + if (firstCode !== void 0) this.state.pos += firstCode <= 65535 ? 1 : 2; + while (this.state.pos < this.length) { + const ch = this.codePointAtPos(this.state.pos); + if (isIdentifierChar$1(ch)) this.state.pos += ch <= 65535 ? 1 : 2; + else if (ch === 92) { + this.state.containsEsc = true; + word$3 += this.input.slice(chunkStart, this.state.pos); + const escStart = this.state.curPosition(); + const identifierCheck = this.state.pos === start ? isIdentifierStart$1 : isIdentifierChar$1; + if (this.input.charCodeAt(++this.state.pos) !== 117) { + this.raise(Errors.MissingUnicodeEscape, this.state.curPosition()); + chunkStart = this.state.pos - 1; + continue; + } + ++this.state.pos; + const esc = this.readCodePoint(true); + if (esc !== null) { + if (!identifierCheck(esc)) this.raise(Errors.EscapedCharNotAnIdentifier, escStart); + word$3 += String.fromCodePoint(esc); + } + chunkStart = this.state.pos; + } else break; + } + return word$3 + this.input.slice(chunkStart, this.state.pos); + } + readWord(firstCode) { + const word$3 = this.readWord1(firstCode); + const type = keywords$1.get(word$3); + if (type !== void 0) this.finishToken(type, tokenLabelName(type)); + else this.finishToken(132, word$3); + } + checkKeywordEscapes() { + const { type } = this.state; + if (tokenIsKeyword(type) && this.state.containsEsc) this.raise(Errors.InvalidEscapedReservedWord, this.state.startLoc, { reservedWord: tokenLabelName(type) }); + } + raise(toParseError, at$3, details = {}) { + const loc = at$3 instanceof Position ? at$3 : at$3.loc.start; + const error = toParseError(loc, details); + if (!(this.optionFlags & 2048)) throw error; + if (!this.isLookahead) this.state.errors.push(error); + return error; + } + raiseOverwrite(toParseError, at$3, details = {}) { + const loc = at$3 instanceof Position ? at$3 : at$3.loc.start; + const pos = loc.index; + const errors = this.state.errors; + for (let i$5 = errors.length - 1; i$5 >= 0; i$5--) { + const error = errors[i$5]; + if (error.loc.index === pos) return errors[i$5] = toParseError(loc, details); + if (error.loc.index < pos) break; + } + return this.raise(toParseError, at$3, details); + } + updateContext(prevType) {} + unexpected(loc, type) { + throw this.raise(Errors.UnexpectedToken, loc != null ? loc : this.state.startLoc, { expected: type ? tokenLabelName(type) : null }); + } + expectPlugin(pluginName, loc) { + if (this.hasPlugin(pluginName)) return true; + throw this.raise(Errors.MissingPlugin, loc != null ? loc : this.state.startLoc, { missingPlugin: [pluginName] }); + } + expectOnePlugin(pluginNames) { + if (!pluginNames.some((name) => this.hasPlugin(name))) throw this.raise(Errors.MissingOneOfPlugins, this.state.startLoc, { missingPlugin: pluginNames }); + } + errorBuilder(error) { + return (pos, lineStart, curLine) => { + this.raise(error, buildPosition(pos, lineStart, curLine)); + }; + } + }; + var ClassScope = class { + constructor() { + this.privateNames = new Set(); + this.loneAccessors = new Map(); + this.undefinedPrivateNames = new Map(); + } + }; + var ClassScopeHandler = class { + constructor(parser$4) { + this.parser = void 0; + this.stack = []; + this.undefinedPrivateNames = new Map(); + this.parser = parser$4; + } + current() { + return this.stack[this.stack.length - 1]; + } + enter() { + this.stack.push(new ClassScope()); + } + exit() { + const oldClassScope = this.stack.pop(); + const current = this.current(); + for (const [name, loc] of Array.from(oldClassScope.undefinedPrivateNames)) if (current) { + if (!current.undefinedPrivateNames.has(name)) current.undefinedPrivateNames.set(name, loc); + } else this.parser.raise(Errors.InvalidPrivateFieldResolution, loc, { identifierName: name }); + } + declarePrivateName(name, elementType, loc) { + const { privateNames, loneAccessors, undefinedPrivateNames } = this.current(); + let redefined = privateNames.has(name); + if (elementType & 3) { + const accessor = redefined && loneAccessors.get(name); + if (accessor) { + const oldStatic = accessor & 4; + const newStatic = elementType & 4; + const oldKind = accessor & 3; + const newKind = elementType & 3; + redefined = oldKind === newKind || oldStatic !== newStatic; + if (!redefined) loneAccessors.delete(name); + } else if (!redefined) loneAccessors.set(name, elementType); + } + if (redefined) this.parser.raise(Errors.PrivateNameRedeclaration, loc, { identifierName: name }); + privateNames.add(name); + undefinedPrivateNames.delete(name); + } + usePrivateName(name, loc) { + let classScope; + for (classScope of this.stack) if (classScope.privateNames.has(name)) return; + if (classScope) classScope.undefinedPrivateNames.set(name, loc); + else this.parser.raise(Errors.InvalidPrivateFieldResolution, loc, { identifierName: name }); + } + }; + var ExpressionScope = class { + constructor(type = 0) { + this.type = type; + } + canBeArrowParameterDeclaration() { + return this.type === 2 || this.type === 1; + } + isCertainlyParameterDeclaration() { + return this.type === 3; + } + }; + var ArrowHeadParsingScope = class extends ExpressionScope { + constructor(type) { + super(type); + this.declarationErrors = new Map(); + } + recordDeclarationError(ParsingErrorClass, at$3) { + const index$1 = at$3.index; + this.declarationErrors.set(index$1, [ParsingErrorClass, at$3]); + } + clearDeclarationError(index$1) { + this.declarationErrors.delete(index$1); + } + iterateErrors(iterator) { + this.declarationErrors.forEach(iterator); + } + }; + var ExpressionScopeHandler = class { + constructor(parser$4) { + this.parser = void 0; + this.stack = [new ExpressionScope()]; + this.parser = parser$4; + } + enter(scope$1) { + this.stack.push(scope$1); + } + exit() { + this.stack.pop(); + } + recordParameterInitializerError(toParseError, node) { + const origin = node.loc.start; + const { stack } = this; + let i$5 = stack.length - 1; + let scope$1 = stack[i$5]; + while (!scope$1.isCertainlyParameterDeclaration()) { + if (scope$1.canBeArrowParameterDeclaration()) scope$1.recordDeclarationError(toParseError, origin); + else return; + scope$1 = stack[--i$5]; + } + this.parser.raise(toParseError, origin); + } + recordArrowParameterBindingError(error, node) { + const { stack } = this; + const scope$1 = stack[stack.length - 1]; + const origin = node.loc.start; + if (scope$1.isCertainlyParameterDeclaration()) this.parser.raise(error, origin); + else if (scope$1.canBeArrowParameterDeclaration()) scope$1.recordDeclarationError(error, origin); + else return; + } + recordAsyncArrowParametersError(at$3) { + const { stack } = this; + let i$5 = stack.length - 1; + let scope$1 = stack[i$5]; + while (scope$1.canBeArrowParameterDeclaration()) { + if (scope$1.type === 2) scope$1.recordDeclarationError(Errors.AwaitBindingIdentifier, at$3); + scope$1 = stack[--i$5]; + } + } + validateAsPattern() { + const { stack } = this; + const currentScope = stack[stack.length - 1]; + if (!currentScope.canBeArrowParameterDeclaration()) return; + currentScope.iterateErrors(([toParseError, loc]) => { + this.parser.raise(toParseError, loc); + let i$5 = stack.length - 2; + let scope$1 = stack[i$5]; + while (scope$1.canBeArrowParameterDeclaration()) { + scope$1.clearDeclarationError(loc.index); + scope$1 = stack[--i$5]; + } + }); + } + }; + function newParameterDeclarationScope() { + return new ExpressionScope(3); + } + function newArrowHeadScope() { + return new ArrowHeadParsingScope(1); + } + function newAsyncArrowScope() { + return new ArrowHeadParsingScope(2); + } + function newExpressionScope() { + return new ExpressionScope(); + } + var ProductionParameterHandler = class { + constructor() { + this.stacks = []; + } + enter(flags) { + this.stacks.push(flags); + } + exit() { + this.stacks.pop(); + } + currentFlags() { + return this.stacks[this.stacks.length - 1]; + } + get hasAwait() { + return (this.currentFlags() & 2) > 0; + } + get hasYield() { + return (this.currentFlags() & 1) > 0; + } + get hasReturn() { + return (this.currentFlags() & 4) > 0; + } + get hasIn() { + return (this.currentFlags() & 8) > 0; + } + }; + function functionFlags(isAsync, isGenerator) { + return (isAsync ? 2 : 0) | (isGenerator ? 1 : 0); + } + var UtilParser = class extends Tokenizer$1 { + addExtra(node, key, value, enumerable = true) { + if (!node) return; + let { extra } = node; + if (extra == null) { + extra = {}; + node.extra = extra; + } + if (enumerable) extra[key] = value; + else Object.defineProperty(extra, key, { + enumerable, + value + }); + } + isContextual(token$1) { + return this.state.type === token$1 && !this.state.containsEsc; + } + isUnparsedContextual(nameStart, name) { + const nameEnd = nameStart + name.length; + if (this.input.slice(nameStart, nameEnd) === name) { + const nextCh = this.input.charCodeAt(nameEnd); + return !(isIdentifierChar$1(nextCh) || (nextCh & 64512) === 55296); + } + return false; + } + isLookaheadContextual(name) { + const next = this.nextTokenStart(); + return this.isUnparsedContextual(next, name); + } + eatContextual(token$1) { + if (this.isContextual(token$1)) { + this.next(); + return true; + } + return false; + } + expectContextual(token$1, toParseError) { + if (!this.eatContextual(token$1)) { + if (toParseError != null) throw this.raise(toParseError, this.state.startLoc); + this.unexpected(null, token$1); + } + } + canInsertSemicolon() { + return this.match(140) || this.match(8) || this.hasPrecedingLineBreak(); + } + hasPrecedingLineBreak() { + return hasNewLine(this.input, this.offsetToSourcePos(this.state.lastTokEndLoc.index), this.state.start); + } + hasFollowingLineBreak() { + return hasNewLine(this.input, this.state.end, this.nextTokenStart()); + } + isLineTerminator() { + return this.eat(13) || this.canInsertSemicolon(); + } + semicolon(allowAsi = true) { + if (allowAsi ? this.isLineTerminator() : this.eat(13)) return; + this.raise(Errors.MissingSemicolon, this.state.lastTokEndLoc); + } + expect(type, loc) { + if (!this.eat(type)) this.unexpected(loc, type); + } + tryParse(fn, oldState = this.state.clone()) { + const abortSignal = { node: null }; + try { + const node = fn((node$1 = null) => { + abortSignal.node = node$1; + throw abortSignal; + }); + if (this.state.errors.length > oldState.errors.length) { + const failState = this.state; + this.state = oldState; + this.state.tokensLength = failState.tokensLength; + return { + node, + error: failState.errors[oldState.errors.length], + thrown: false, + aborted: false, + failState + }; + } + return { + node, + error: null, + thrown: false, + aborted: false, + failState: null + }; + } catch (error) { + const failState = this.state; + this.state = oldState; + if (error instanceof SyntaxError) return { + node: null, + error, + thrown: true, + aborted: false, + failState + }; + if (error === abortSignal) return { + node: abortSignal.node, + error: null, + thrown: false, + aborted: true, + failState + }; + throw error; + } + } + checkExpressionErrors(refExpressionErrors, andThrow) { + if (!refExpressionErrors) return false; + const { shorthandAssignLoc, doubleProtoLoc, privateKeyLoc, optionalParametersLoc } = refExpressionErrors; + const hasErrors = !!shorthandAssignLoc || !!doubleProtoLoc || !!optionalParametersLoc || !!privateKeyLoc; + if (!andThrow) return hasErrors; + if (shorthandAssignLoc != null) this.raise(Errors.InvalidCoverInitializedName, shorthandAssignLoc); + if (doubleProtoLoc != null) this.raise(Errors.DuplicateProto, doubleProtoLoc); + if (privateKeyLoc != null) this.raise(Errors.UnexpectedPrivateField, privateKeyLoc); + if (optionalParametersLoc != null) this.unexpected(optionalParametersLoc); + } + isLiteralPropertyName() { + return tokenIsLiteralPropertyName(this.state.type); + } + isPrivateName(node) { + return node.type === "PrivateName"; + } + getPrivateNameSV(node) { + return node.id.name; + } + hasPropertyAsPrivateName(node) { + return (node.type === "MemberExpression" || node.type === "OptionalMemberExpression") && this.isPrivateName(node.property); + } + isObjectProperty(node) { + return node.type === "ObjectProperty"; + } + isObjectMethod(node) { + return node.type === "ObjectMethod"; + } + initializeScopes(inModule = this.options.sourceType === "module") { + const oldLabels = this.state.labels; + this.state.labels = []; + const oldExportedIdentifiers = this.exportedIdentifiers; + this.exportedIdentifiers = new Set(); + const oldInModule = this.inModule; + this.inModule = inModule; + const oldScope = this.scope; + const ScopeHandler$1 = this.getScopeHandler(); + this.scope = new ScopeHandler$1(this, inModule); + const oldProdParam = this.prodParam; + this.prodParam = new ProductionParameterHandler(); + const oldClassScope = this.classScope; + this.classScope = new ClassScopeHandler(this); + const oldExpressionScope = this.expressionScope; + this.expressionScope = new ExpressionScopeHandler(this); + return () => { + this.state.labels = oldLabels; + this.exportedIdentifiers = oldExportedIdentifiers; + this.inModule = oldInModule; + this.scope = oldScope; + this.prodParam = oldProdParam; + this.classScope = oldClassScope; + this.expressionScope = oldExpressionScope; + }; + } + enterInitialScopes() { + let paramFlags = 0; + if (this.inModule) paramFlags |= 2; + if (this.optionFlags & 32) paramFlags |= 1; + this.scope.enter(1); + this.prodParam.enter(paramFlags); + } + checkDestructuringPrivate(refExpressionErrors) { + const { privateKeyLoc } = refExpressionErrors; + if (privateKeyLoc !== null) this.expectPlugin("destructuringPrivate", privateKeyLoc); + } + }; + var ExpressionErrors = class { + constructor() { + this.shorthandAssignLoc = null; + this.doubleProtoLoc = null; + this.privateKeyLoc = null; + this.optionalParametersLoc = null; + } + }; + var Node$5 = class { + constructor(parser$4, pos, loc) { + this.type = ""; + this.start = pos; + this.end = 0; + this.loc = new SourceLocation$1(loc); + if ((parser$4 == null ? void 0 : parser$4.optionFlags) & 128) this.range = [pos, 0]; + if (parser$4 != null && parser$4.filename) this.loc.filename = parser$4.filename; + } + }; + const NodePrototype = Node$5.prototype; + NodePrototype.__clone = function() { + const newNode = new Node$5(void 0, this.start, this.loc.start); + const keys$2 = Object.keys(this); + for (let i$5 = 0, length = keys$2.length; i$5 < length; i$5++) { + const key = keys$2[i$5]; + if (key !== "leadingComments" && key !== "trailingComments" && key !== "innerComments") newNode[key] = this[key]; + } + return newNode; + }; + function clonePlaceholder(node) { + return cloneIdentifier(node); + } + function cloneIdentifier(node) { + const { type, start, end, loc, range: range$3, extra, name } = node; + const cloned = Object.create(NodePrototype); + cloned.type = type; + cloned.start = start; + cloned.end = end; + cloned.loc = loc; + cloned.range = range$3; + cloned.extra = extra; + cloned.name = name; + if (type === "Placeholder") cloned.expectedNode = node.expectedNode; + return cloned; + } + function cloneStringLiteral(node) { + const { type, start, end, loc, range: range$3, extra } = node; + if (type === "Placeholder") return clonePlaceholder(node); + const cloned = Object.create(NodePrototype); + cloned.type = type; + cloned.start = start; + cloned.end = end; + cloned.loc = loc; + cloned.range = range$3; + if (node.raw !== void 0) cloned.raw = node.raw; + else cloned.extra = extra; + cloned.value = node.value; + return cloned; + } + var NodeUtils = class extends UtilParser { + startNode() { + const loc = this.state.startLoc; + return new Node$5(this, loc.index, loc); + } + startNodeAt(loc) { + return new Node$5(this, loc.index, loc); + } + startNodeAtNode(type) { + return this.startNodeAt(type.loc.start); + } + finishNode(node, type) { + return this.finishNodeAt(node, type, this.state.lastTokEndLoc); + } + finishNodeAt(node, type, endLoc) { + node.type = type; + node.end = endLoc.index; + node.loc.end = endLoc; + if (this.optionFlags & 128) node.range[1] = endLoc.index; + if (this.optionFlags & 4096) this.processComment(node); + return node; + } + resetStartLocation(node, startLoc) { + node.start = startLoc.index; + node.loc.start = startLoc; + if (this.optionFlags & 128) node.range[0] = startLoc.index; + } + resetEndLocation(node, endLoc = this.state.lastTokEndLoc) { + node.end = endLoc.index; + node.loc.end = endLoc; + if (this.optionFlags & 128) node.range[1] = endLoc.index; + } + resetStartLocationFromNode(node, locationNode) { + this.resetStartLocation(node, locationNode.loc.start); + } + }; + const reservedTypes = new Set([ + "_", + "any", + "bool", + "boolean", + "empty", + "extends", + "false", + "interface", + "mixed", + "null", + "number", + "static", + "string", + "true", + "typeof", + "void" + ]); + const FlowErrors = ParseErrorEnum`flow`({ + AmbiguousConditionalArrow: "Ambiguous expression: wrap the arrow functions in parentheses to disambiguate.", + AmbiguousDeclareModuleKind: "Found both `declare module.exports` and `declare export` in the same module. Modules can only have 1 since they are either an ES module or they are a CommonJS module.", + AssignReservedType: ({ reservedType }) => `Cannot overwrite reserved type ${reservedType}.`, + DeclareClassElement: "The `declare` modifier can only appear on class fields.", + DeclareClassFieldInitializer: "Initializers are not allowed in fields with the `declare` modifier.", + DuplicateDeclareModuleExports: "Duplicate `declare module.exports` statement.", + EnumBooleanMemberNotInitialized: ({ memberName, enumName }) => `Boolean enum members need to be initialized. Use either \`${memberName} = true,\` or \`${memberName} = false,\` in enum \`${enumName}\`.`, + EnumDuplicateMemberName: ({ memberName, enumName }) => `Enum member names need to be unique, but the name \`${memberName}\` has already been used before in enum \`${enumName}\`.`, + EnumInconsistentMemberValues: ({ enumName }) => `Enum \`${enumName}\` has inconsistent member initializers. Either use no initializers, or consistently use literals (either booleans, numbers, or strings) for all member initializers.`, + EnumInvalidExplicitType: ({ invalidEnumType, enumName }) => `Enum type \`${invalidEnumType}\` is not valid. Use one of \`boolean\`, \`number\`, \`string\`, or \`symbol\` in enum \`${enumName}\`.`, + EnumInvalidExplicitTypeUnknownSupplied: ({ enumName }) => `Supplied enum type is not valid. Use one of \`boolean\`, \`number\`, \`string\`, or \`symbol\` in enum \`${enumName}\`.`, + EnumInvalidMemberInitializerPrimaryType: ({ enumName, memberName, explicitType }) => `Enum \`${enumName}\` has type \`${explicitType}\`, so the initializer of \`${memberName}\` needs to be a ${explicitType} literal.`, + EnumInvalidMemberInitializerSymbolType: ({ enumName, memberName }) => `Symbol enum members cannot be initialized. Use \`${memberName},\` in enum \`${enumName}\`.`, + EnumInvalidMemberInitializerUnknownType: ({ enumName, memberName }) => `The enum member initializer for \`${memberName}\` needs to be a literal (either a boolean, number, or string) in enum \`${enumName}\`.`, + EnumInvalidMemberName: ({ enumName, memberName, suggestion }) => `Enum member names cannot start with lowercase 'a' through 'z'. Instead of using \`${memberName}\`, consider using \`${suggestion}\`, in enum \`${enumName}\`.`, + EnumNumberMemberNotInitialized: ({ enumName, memberName }) => `Number enum members need to be initialized, e.g. \`${memberName} = 1\` in enum \`${enumName}\`.`, + EnumStringMemberInconsistentlyInitialized: ({ enumName }) => `String enum members need to consistently either all use initializers, or use no initializers, in enum \`${enumName}\`.`, + GetterMayNotHaveThisParam: "A getter cannot have a `this` parameter.", + ImportReflectionHasImportType: "An `import module` declaration can not use `type` or `typeof` keyword.", + ImportTypeShorthandOnlyInPureImport: "The `type` and `typeof` keywords on named imports can only be used on regular `import` statements. It cannot be used with `import type` or `import typeof` statements.", + InexactInsideExact: "Explicit inexact syntax cannot appear inside an explicit exact object type.", + InexactInsideNonObject: "Explicit inexact syntax cannot appear in class or interface definitions.", + InexactVariance: "Explicit inexact syntax cannot have variance.", + InvalidNonTypeImportInDeclareModule: "Imports within a `declare module` body must always be `import type` or `import typeof`.", + MissingTypeParamDefault: "Type parameter declaration needs a default, since a preceding type parameter declaration has a default.", + NestedDeclareModule: "`declare module` cannot be used inside another `declare module`.", + NestedFlowComment: "Cannot have a flow comment inside another flow comment.", + PatternIsOptional: Object.assign({ message: "A binding pattern parameter cannot be optional in an implementation signature." }, { reasonCode: "OptionalBindingPattern" }), + SetterMayNotHaveThisParam: "A setter cannot have a `this` parameter.", + SpreadVariance: "Spread properties cannot have variance.", + ThisParamAnnotationRequired: "A type annotation is required for the `this` parameter.", + ThisParamBannedInConstructor: "Constructors cannot have a `this` parameter; constructors don't bind `this` like other functions.", + ThisParamMayNotBeOptional: "The `this` parameter cannot be optional.", + ThisParamMustBeFirst: "The `this` parameter must be the first function parameter.", + ThisParamNoDefault: "The `this` parameter may not have a default value.", + TypeBeforeInitializer: "Type annotations must come before default assignments, e.g. instead of `age = 25: number` use `age: number = 25`.", + TypeCastInPattern: "The type cast expression is expected to be wrapped with parenthesis.", + UnexpectedExplicitInexactInObject: "Explicit inexact syntax must appear at the end of an inexact object.", + UnexpectedReservedType: ({ reservedType }) => `Unexpected reserved type ${reservedType}.`, + UnexpectedReservedUnderscore: "`_` is only allowed as a type argument to call or new.", + UnexpectedSpaceBetweenModuloChecks: "Spaces between `%` and `checks` are not allowed here.", + UnexpectedSpreadType: "Spread operator cannot appear in class or interface definitions.", + UnexpectedSubtractionOperand: "Unexpected token, expected \"number\" or \"bigint\".", + UnexpectedTokenAfterTypeParameter: "Expected an arrow function after this type parameter declaration.", + UnexpectedTypeParameterBeforeAsyncArrowFunction: "Type parameters must come after the async keyword, e.g. instead of ` async () => {}`, use `async () => {}`.", + UnsupportedDeclareExportKind: ({ unsupportedExportKind, suggestion }) => `\`declare export ${unsupportedExportKind}\` is not supported. Use \`${suggestion}\` instead.`, + UnsupportedStatementInDeclareModule: "Only declares and type imports are allowed inside declare module.", + UnterminatedFlowComment: "Unterminated flow-comment." + }); + function isEsModuleType(bodyElement) { + return bodyElement.type === "DeclareExportAllDeclaration" || bodyElement.type === "DeclareExportDeclaration" && (!bodyElement.declaration || bodyElement.declaration.type !== "TypeAlias" && bodyElement.declaration.type !== "InterfaceDeclaration"); + } + function hasTypeImportKind(node) { + return node.importKind === "type" || node.importKind === "typeof"; + } + const exportSuggestions = { + const: "declare export var", + let: "declare export var", + type: "export type", + interface: "export interface" + }; + function partition(list$4, test) { + const list1 = []; + const list2 = []; + for (let i$5 = 0; i$5 < list$4.length; i$5++) (test(list$4[i$5], i$5, list$4) ? list1 : list2).push(list$4[i$5]); + return [list1, list2]; + } + const FLOW_PRAGMA_REGEX = /\*?\s*@((?:no)?flow)\b/; + var flow = (superClass) => class FlowParserMixin extends superClass { + constructor(...args) { + super(...args); + this.flowPragma = void 0; + } + getScopeHandler() { + return FlowScopeHandler; + } + shouldParseTypes() { + return this.getPluginOption("flow", "all") || this.flowPragma === "flow"; + } + finishToken(type, val) { + if (type !== 134 && type !== 13 && type !== 28) { + if (this.flowPragma === void 0) this.flowPragma = null; + } + super.finishToken(type, val); + } + addComment(comment$7) { + if (this.flowPragma === void 0) { + const matches = FLOW_PRAGMA_REGEX.exec(comment$7.value); + if (!matches); + else if (matches[1] === "flow") this.flowPragma = "flow"; + else if (matches[1] === "noflow") this.flowPragma = "noflow"; + else throw new Error("Unexpected flow pragma"); + } + super.addComment(comment$7); + } + flowParseTypeInitialiser(tok) { + const oldInType = this.state.inType; + this.state.inType = true; + this.expect(tok || 14); + const type = this.flowParseType(); + this.state.inType = oldInType; + return type; + } + flowParsePredicate() { + const node = this.startNode(); + const moduloLoc = this.state.startLoc; + this.next(); + this.expectContextual(110); + if (this.state.lastTokStartLoc.index > moduloLoc.index + 1) this.raise(FlowErrors.UnexpectedSpaceBetweenModuloChecks, moduloLoc); + if (this.eat(10)) { + node.value = super.parseExpression(); + this.expect(11); + return this.finishNode(node, "DeclaredPredicate"); + } else return this.finishNode(node, "InferredPredicate"); + } + flowParseTypeAndPredicateInitialiser() { + const oldInType = this.state.inType; + this.state.inType = true; + this.expect(14); + let type = null; + let predicate = null; + if (this.match(54)) { + this.state.inType = oldInType; + predicate = this.flowParsePredicate(); + } else { + type = this.flowParseType(); + this.state.inType = oldInType; + if (this.match(54)) predicate = this.flowParsePredicate(); + } + return [type, predicate]; + } + flowParseDeclareClass(node) { + this.next(); + this.flowParseInterfaceish(node, true); + return this.finishNode(node, "DeclareClass"); + } + flowParseDeclareFunction(node) { + this.next(); + const id$4 = node.id = this.parseIdentifier(); + const typeNode = this.startNode(); + const typeContainer = this.startNode(); + if (this.match(47)) typeNode.typeParameters = this.flowParseTypeParameterDeclaration(); + else typeNode.typeParameters = null; + this.expect(10); + const tmp = this.flowParseFunctionTypeParams(); + typeNode.params = tmp.params; + typeNode.rest = tmp.rest; + typeNode.this = tmp._this; + this.expect(11); + [typeNode.returnType, node.predicate] = this.flowParseTypeAndPredicateInitialiser(); + typeContainer.typeAnnotation = this.finishNode(typeNode, "FunctionTypeAnnotation"); + id$4.typeAnnotation = this.finishNode(typeContainer, "TypeAnnotation"); + this.resetEndLocation(id$4); + this.semicolon(); + this.scope.declareName(node.id.name, 2048, node.id.loc.start); + return this.finishNode(node, "DeclareFunction"); + } + flowParseDeclare(node, insideModule) { + if (this.match(80)) return this.flowParseDeclareClass(node); + else if (this.match(68)) return this.flowParseDeclareFunction(node); + else if (this.match(74)) return this.flowParseDeclareVariable(node); + else if (this.eatContextual(127)) if (this.match(16)) return this.flowParseDeclareModuleExports(node); + else { + if (insideModule) this.raise(FlowErrors.NestedDeclareModule, this.state.lastTokStartLoc); + return this.flowParseDeclareModule(node); + } + else if (this.isContextual(130)) return this.flowParseDeclareTypeAlias(node); + else if (this.isContextual(131)) return this.flowParseDeclareOpaqueType(node); + else if (this.isContextual(129)) return this.flowParseDeclareInterface(node); + else if (this.match(82)) return this.flowParseDeclareExportDeclaration(node, insideModule); + else this.unexpected(); + } + flowParseDeclareVariable(node) { + this.next(); + node.id = this.flowParseTypeAnnotatableIdentifier(true); + this.scope.declareName(node.id.name, 5, node.id.loc.start); + this.semicolon(); + return this.finishNode(node, "DeclareVariable"); + } + flowParseDeclareModule(node) { + this.scope.enter(0); + if (this.match(134)) node.id = super.parseExprAtom(); + else node.id = this.parseIdentifier(); + const bodyNode = node.body = this.startNode(); + const body = bodyNode.body = []; + this.expect(5); + while (!this.match(8)) { + let bodyNode$1 = this.startNode(); + if (this.match(83)) { + this.next(); + if (!this.isContextual(130) && !this.match(87)) this.raise(FlowErrors.InvalidNonTypeImportInDeclareModule, this.state.lastTokStartLoc); + super.parseImport(bodyNode$1); + } else { + this.expectContextual(125, FlowErrors.UnsupportedStatementInDeclareModule); + bodyNode$1 = this.flowParseDeclare(bodyNode$1, true); + } + body.push(bodyNode$1); + } + this.scope.exit(); + this.expect(8); + this.finishNode(bodyNode, "BlockStatement"); + let kind = null; + let hasModuleExport = false; + body.forEach((bodyElement) => { + if (isEsModuleType(bodyElement)) { + if (kind === "CommonJS") this.raise(FlowErrors.AmbiguousDeclareModuleKind, bodyElement); + kind = "ES"; + } else if (bodyElement.type === "DeclareModuleExports") { + if (hasModuleExport) this.raise(FlowErrors.DuplicateDeclareModuleExports, bodyElement); + if (kind === "ES") this.raise(FlowErrors.AmbiguousDeclareModuleKind, bodyElement); + kind = "CommonJS"; + hasModuleExport = true; + } + }); + node.kind = kind || "CommonJS"; + return this.finishNode(node, "DeclareModule"); + } + flowParseDeclareExportDeclaration(node, insideModule) { + this.expect(82); + if (this.eat(65)) { + if (this.match(68) || this.match(80)) node.declaration = this.flowParseDeclare(this.startNode()); + else { + node.declaration = this.flowParseType(); + this.semicolon(); + } + node.default = true; + return this.finishNode(node, "DeclareExportDeclaration"); + } else { + if (this.match(75) || this.isLet() || (this.isContextual(130) || this.isContextual(129)) && !insideModule) { + const label = this.state.value; + throw this.raise(FlowErrors.UnsupportedDeclareExportKind, this.state.startLoc, { + unsupportedExportKind: label, + suggestion: exportSuggestions[label] + }); + } + if (this.match(74) || this.match(68) || this.match(80) || this.isContextual(131)) { + node.declaration = this.flowParseDeclare(this.startNode()); + node.default = false; + return this.finishNode(node, "DeclareExportDeclaration"); + } else if (this.match(55) || this.match(5) || this.isContextual(129) || this.isContextual(130) || this.isContextual(131)) { + node = this.parseExport(node, null); + if (node.type === "ExportNamedDeclaration") { + node.type = "ExportDeclaration"; + node.default = false; + delete node.exportKind; + } + node.type = "Declare" + node.type; + return node; + } + } + this.unexpected(); + } + flowParseDeclareModuleExports(node) { + this.next(); + this.expectContextual(111); + node.typeAnnotation = this.flowParseTypeAnnotation(); + this.semicolon(); + return this.finishNode(node, "DeclareModuleExports"); + } + flowParseDeclareTypeAlias(node) { + this.next(); + const finished = this.flowParseTypeAlias(node); + finished.type = "DeclareTypeAlias"; + return finished; + } + flowParseDeclareOpaqueType(node) { + this.next(); + const finished = this.flowParseOpaqueType(node, true); + finished.type = "DeclareOpaqueType"; + return finished; + } + flowParseDeclareInterface(node) { + this.next(); + this.flowParseInterfaceish(node, false); + return this.finishNode(node, "DeclareInterface"); + } + flowParseInterfaceish(node, isClass$2) { + node.id = this.flowParseRestrictedIdentifier(!isClass$2, true); + this.scope.declareName(node.id.name, isClass$2 ? 17 : 8201, node.id.loc.start); + if (this.match(47)) node.typeParameters = this.flowParseTypeParameterDeclaration(); + else node.typeParameters = null; + node.extends = []; + if (this.eat(81)) do + node.extends.push(this.flowParseInterfaceExtends()); + while (!isClass$2 && this.eat(12)); + if (isClass$2) { + node.implements = []; + node.mixins = []; + if (this.eatContextual(117)) do + node.mixins.push(this.flowParseInterfaceExtends()); + while (this.eat(12)); + if (this.eatContextual(113)) do + node.implements.push(this.flowParseInterfaceExtends()); + while (this.eat(12)); + } + node.body = this.flowParseObjectType({ + allowStatic: isClass$2, + allowExact: false, + allowSpread: false, + allowProto: isClass$2, + allowInexact: false + }); + } + flowParseInterfaceExtends() { + const node = this.startNode(); + node.id = this.flowParseQualifiedTypeIdentifier(); + if (this.match(47)) node.typeParameters = this.flowParseTypeParameterInstantiation(); + else node.typeParameters = null; + return this.finishNode(node, "InterfaceExtends"); + } + flowParseInterface(node) { + this.flowParseInterfaceish(node, false); + return this.finishNode(node, "InterfaceDeclaration"); + } + checkNotUnderscore(word$3) { + if (word$3 === "_") this.raise(FlowErrors.UnexpectedReservedUnderscore, this.state.startLoc); + } + checkReservedType(word$3, startLoc, declaration) { + if (!reservedTypes.has(word$3)) return; + this.raise(declaration ? FlowErrors.AssignReservedType : FlowErrors.UnexpectedReservedType, startLoc, { reservedType: word$3 }); + } + flowParseRestrictedIdentifier(liberal, declaration) { + this.checkReservedType(this.state.value, this.state.startLoc, declaration); + return this.parseIdentifier(liberal); + } + flowParseTypeAlias(node) { + node.id = this.flowParseRestrictedIdentifier(false, true); + this.scope.declareName(node.id.name, 8201, node.id.loc.start); + if (this.match(47)) node.typeParameters = this.flowParseTypeParameterDeclaration(); + else node.typeParameters = null; + node.right = this.flowParseTypeInitialiser(29); + this.semicolon(); + return this.finishNode(node, "TypeAlias"); + } + flowParseOpaqueType(node, declare) { + this.expectContextual(130); + node.id = this.flowParseRestrictedIdentifier(true, true); + this.scope.declareName(node.id.name, 8201, node.id.loc.start); + if (this.match(47)) node.typeParameters = this.flowParseTypeParameterDeclaration(); + else node.typeParameters = null; + node.supertype = null; + if (this.match(14)) node.supertype = this.flowParseTypeInitialiser(14); + node.impltype = null; + if (!declare) node.impltype = this.flowParseTypeInitialiser(29); + this.semicolon(); + return this.finishNode(node, "OpaqueType"); + } + flowParseTypeParameter(requireDefault = false) { + const nodeStartLoc = this.state.startLoc; + const node = this.startNode(); + const variance$1 = this.flowParseVariance(); + const ident = this.flowParseTypeAnnotatableIdentifier(); + node.name = ident.name; + node.variance = variance$1; + node.bound = ident.typeAnnotation; + if (this.match(29)) { + this.eat(29); + node.default = this.flowParseType(); + } else if (requireDefault) this.raise(FlowErrors.MissingTypeParamDefault, nodeStartLoc); + return this.finishNode(node, "TypeParameter"); + } + flowParseTypeParameterDeclaration() { + const oldInType = this.state.inType; + const node = this.startNode(); + node.params = []; + this.state.inType = true; + if (this.match(47) || this.match(143)) this.next(); + else this.unexpected(); + let defaultRequired = false; + do { + const typeParameter$1 = this.flowParseTypeParameter(defaultRequired); + node.params.push(typeParameter$1); + if (typeParameter$1.default) defaultRequired = true; + if (!this.match(48)) this.expect(12); + } while (!this.match(48)); + this.expect(48); + this.state.inType = oldInType; + return this.finishNode(node, "TypeParameterDeclaration"); + } + flowInTopLevelContext(cb$1) { + if (this.curContext() !== types$4.brace) { + const oldContext = this.state.context; + this.state.context = [oldContext[0]]; + try { + return cb$1(); + } finally { + this.state.context = oldContext; + } + } else return cb$1(); + } + flowParseTypeParameterInstantiationInExpression() { + if (this.reScan_lt() !== 47) return; + return this.flowParseTypeParameterInstantiation(); + } + flowParseTypeParameterInstantiation() { + const node = this.startNode(); + const oldInType = this.state.inType; + this.state.inType = true; + node.params = []; + this.flowInTopLevelContext(() => { + this.expect(47); + const oldNoAnonFunctionType = this.state.noAnonFunctionType; + this.state.noAnonFunctionType = false; + while (!this.match(48)) { + node.params.push(this.flowParseType()); + if (!this.match(48)) this.expect(12); + } + this.state.noAnonFunctionType = oldNoAnonFunctionType; + }); + this.state.inType = oldInType; + if (!this.state.inType && this.curContext() === types$4.brace) this.reScan_lt_gt(); + this.expect(48); + return this.finishNode(node, "TypeParameterInstantiation"); + } + flowParseTypeParameterInstantiationCallOrNew() { + if (this.reScan_lt() !== 47) return; + const node = this.startNode(); + const oldInType = this.state.inType; + node.params = []; + this.state.inType = true; + this.expect(47); + while (!this.match(48)) { + node.params.push(this.flowParseTypeOrImplicitInstantiation()); + if (!this.match(48)) this.expect(12); + } + this.expect(48); + this.state.inType = oldInType; + return this.finishNode(node, "TypeParameterInstantiation"); + } + flowParseInterfaceType() { + const node = this.startNode(); + this.expectContextual(129); + node.extends = []; + if (this.eat(81)) do + node.extends.push(this.flowParseInterfaceExtends()); + while (this.eat(12)); + node.body = this.flowParseObjectType({ + allowStatic: false, + allowExact: false, + allowSpread: false, + allowProto: false, + allowInexact: false + }); + return this.finishNode(node, "InterfaceTypeAnnotation"); + } + flowParseObjectPropertyKey() { + return this.match(135) || this.match(134) ? super.parseExprAtom() : this.parseIdentifier(true); + } + flowParseObjectTypeIndexer(node, isStatic$1, variance$1) { + node.static = isStatic$1; + if (this.lookahead().type === 14) { + node.id = this.flowParseObjectPropertyKey(); + node.key = this.flowParseTypeInitialiser(); + } else { + node.id = null; + node.key = this.flowParseType(); + } + this.expect(3); + node.value = this.flowParseTypeInitialiser(); + node.variance = variance$1; + return this.finishNode(node, "ObjectTypeIndexer"); + } + flowParseObjectTypeInternalSlot(node, isStatic$1) { + node.static = isStatic$1; + node.id = this.flowParseObjectPropertyKey(); + this.expect(3); + this.expect(3); + if (this.match(47) || this.match(10)) { + node.method = true; + node.optional = false; + node.value = this.flowParseObjectTypeMethodish(this.startNodeAt(node.loc.start)); + } else { + node.method = false; + if (this.eat(17)) node.optional = true; + node.value = this.flowParseTypeInitialiser(); + } + return this.finishNode(node, "ObjectTypeInternalSlot"); + } + flowParseObjectTypeMethodish(node) { + node.params = []; + node.rest = null; + node.typeParameters = null; + node.this = null; + if (this.match(47)) node.typeParameters = this.flowParseTypeParameterDeclaration(); + this.expect(10); + if (this.match(78)) { + node.this = this.flowParseFunctionTypeParam(true); + node.this.name = null; + if (!this.match(11)) this.expect(12); + } + while (!this.match(11) && !this.match(21)) { + node.params.push(this.flowParseFunctionTypeParam(false)); + if (!this.match(11)) this.expect(12); + } + if (this.eat(21)) node.rest = this.flowParseFunctionTypeParam(false); + this.expect(11); + node.returnType = this.flowParseTypeInitialiser(); + return this.finishNode(node, "FunctionTypeAnnotation"); + } + flowParseObjectTypeCallProperty(node, isStatic$1) { + const valueNode = this.startNode(); + node.static = isStatic$1; + node.value = this.flowParseObjectTypeMethodish(valueNode); + return this.finishNode(node, "ObjectTypeCallProperty"); + } + flowParseObjectType({ allowStatic, allowExact, allowSpread, allowProto, allowInexact }) { + const oldInType = this.state.inType; + this.state.inType = true; + const nodeStart = this.startNode(); + nodeStart.callProperties = []; + nodeStart.properties = []; + nodeStart.indexers = []; + nodeStart.internalSlots = []; + let endDelim; + let exact; + let inexact = false; + if (allowExact && this.match(6)) { + this.expect(6); + endDelim = 9; + exact = true; + } else { + this.expect(5); + endDelim = 8; + exact = false; + } + nodeStart.exact = exact; + while (!this.match(endDelim)) { + let isStatic$1 = false; + let protoStartLoc = null; + let inexactStartLoc = null; + const node = this.startNode(); + if (allowProto && this.isContextual(118)) { + const lookahead = this.lookahead(); + if (lookahead.type !== 14 && lookahead.type !== 17) { + this.next(); + protoStartLoc = this.state.startLoc; + allowStatic = false; + } + } + if (allowStatic && this.isContextual(106)) { + const lookahead = this.lookahead(); + if (lookahead.type !== 14 && lookahead.type !== 17) { + this.next(); + isStatic$1 = true; + } + } + const variance$1 = this.flowParseVariance(); + if (this.eat(0)) { + if (protoStartLoc != null) this.unexpected(protoStartLoc); + if (this.eat(0)) { + if (variance$1) this.unexpected(variance$1.loc.start); + nodeStart.internalSlots.push(this.flowParseObjectTypeInternalSlot(node, isStatic$1)); + } else nodeStart.indexers.push(this.flowParseObjectTypeIndexer(node, isStatic$1, variance$1)); + } else if (this.match(10) || this.match(47)) { + if (protoStartLoc != null) this.unexpected(protoStartLoc); + if (variance$1) this.unexpected(variance$1.loc.start); + nodeStart.callProperties.push(this.flowParseObjectTypeCallProperty(node, isStatic$1)); + } else { + let kind = "init"; + if (this.isContextual(99) || this.isContextual(104)) { + const lookahead = this.lookahead(); + if (tokenIsLiteralPropertyName(lookahead.type)) { + kind = this.state.value; + this.next(); + } + } + const propOrInexact = this.flowParseObjectTypeProperty(node, isStatic$1, protoStartLoc, variance$1, kind, allowSpread, allowInexact != null ? allowInexact : !exact); + if (propOrInexact === null) { + inexact = true; + inexactStartLoc = this.state.lastTokStartLoc; + } else nodeStart.properties.push(propOrInexact); + } + this.flowObjectTypeSemicolon(); + if (inexactStartLoc && !this.match(8) && !this.match(9)) this.raise(FlowErrors.UnexpectedExplicitInexactInObject, inexactStartLoc); + } + this.expect(endDelim); + if (allowSpread) nodeStart.inexact = inexact; + const out = this.finishNode(nodeStart, "ObjectTypeAnnotation"); + this.state.inType = oldInType; + return out; + } + flowParseObjectTypeProperty(node, isStatic$1, protoStartLoc, variance$1, kind, allowSpread, allowInexact) { + if (this.eat(21)) { + const isInexactToken = this.match(12) || this.match(13) || this.match(8) || this.match(9); + if (isInexactToken) { + if (!allowSpread) this.raise(FlowErrors.InexactInsideNonObject, this.state.lastTokStartLoc); + else if (!allowInexact) this.raise(FlowErrors.InexactInsideExact, this.state.lastTokStartLoc); + if (variance$1) this.raise(FlowErrors.InexactVariance, variance$1); + return null; + } + if (!allowSpread) this.raise(FlowErrors.UnexpectedSpreadType, this.state.lastTokStartLoc); + if (protoStartLoc != null) this.unexpected(protoStartLoc); + if (variance$1) this.raise(FlowErrors.SpreadVariance, variance$1); + node.argument = this.flowParseType(); + return this.finishNode(node, "ObjectTypeSpreadProperty"); + } else { + node.key = this.flowParseObjectPropertyKey(); + node.static = isStatic$1; + node.proto = protoStartLoc != null; + node.kind = kind; + let optional = false; + if (this.match(47) || this.match(10)) { + node.method = true; + if (protoStartLoc != null) this.unexpected(protoStartLoc); + if (variance$1) this.unexpected(variance$1.loc.start); + node.value = this.flowParseObjectTypeMethodish(this.startNodeAt(node.loc.start)); + if (kind === "get" || kind === "set") this.flowCheckGetterSetterParams(node); + if (!allowSpread && node.key.name === "constructor" && node.value.this) this.raise(FlowErrors.ThisParamBannedInConstructor, node.value.this); + } else { + if (kind !== "init") this.unexpected(); + node.method = false; + if (this.eat(17)) optional = true; + node.value = this.flowParseTypeInitialiser(); + node.variance = variance$1; + } + node.optional = optional; + return this.finishNode(node, "ObjectTypeProperty"); + } + } + flowCheckGetterSetterParams(property$1) { + const paramCount = property$1.kind === "get" ? 0 : 1; + const length = property$1.value.params.length + (property$1.value.rest ? 1 : 0); + if (property$1.value.this) this.raise(property$1.kind === "get" ? FlowErrors.GetterMayNotHaveThisParam : FlowErrors.SetterMayNotHaveThisParam, property$1.value.this); + if (length !== paramCount) this.raise(property$1.kind === "get" ? Errors.BadGetterArity : Errors.BadSetterArity, property$1); + if (property$1.kind === "set" && property$1.value.rest) this.raise(Errors.BadSetterRestParameter, property$1); + } + flowObjectTypeSemicolon() { + if (!this.eat(13) && !this.eat(12) && !this.match(8) && !this.match(9)) this.unexpected(); + } + flowParseQualifiedTypeIdentifier(startLoc, id$4) { + startLoc != null || (startLoc = this.state.startLoc); + let node = id$4 || this.flowParseRestrictedIdentifier(true); + while (this.eat(16)) { + const node2 = this.startNodeAt(startLoc); + node2.qualification = node; + node2.id = this.flowParseRestrictedIdentifier(true); + node = this.finishNode(node2, "QualifiedTypeIdentifier"); + } + return node; + } + flowParseGenericType(startLoc, id$4) { + const node = this.startNodeAt(startLoc); + node.typeParameters = null; + node.id = this.flowParseQualifiedTypeIdentifier(startLoc, id$4); + if (this.match(47)) node.typeParameters = this.flowParseTypeParameterInstantiation(); + return this.finishNode(node, "GenericTypeAnnotation"); + } + flowParseTypeofType() { + const node = this.startNode(); + this.expect(87); + node.argument = this.flowParsePrimaryType(); + return this.finishNode(node, "TypeofTypeAnnotation"); + } + flowParseTupleType() { + const node = this.startNode(); + node.types = []; + this.expect(0); + while (this.state.pos < this.length && !this.match(3)) { + node.types.push(this.flowParseType()); + if (this.match(3)) break; + this.expect(12); + } + this.expect(3); + return this.finishNode(node, "TupleTypeAnnotation"); + } + flowParseFunctionTypeParam(first$1) { + let name = null; + let optional = false; + let typeAnnotation$1 = null; + const node = this.startNode(); + const lh = this.lookahead(); + const isThis = this.state.type === 78; + if (lh.type === 14 || lh.type === 17) { + if (isThis && !first$1) this.raise(FlowErrors.ThisParamMustBeFirst, node); + name = this.parseIdentifier(isThis); + if (this.eat(17)) { + optional = true; + if (isThis) this.raise(FlowErrors.ThisParamMayNotBeOptional, node); + } + typeAnnotation$1 = this.flowParseTypeInitialiser(); + } else typeAnnotation$1 = this.flowParseType(); + node.name = name; + node.optional = optional; + node.typeAnnotation = typeAnnotation$1; + return this.finishNode(node, "FunctionTypeParam"); + } + reinterpretTypeAsFunctionTypeParam(type) { + const node = this.startNodeAt(type.loc.start); + node.name = null; + node.optional = false; + node.typeAnnotation = type; + return this.finishNode(node, "FunctionTypeParam"); + } + flowParseFunctionTypeParams(params = []) { + let rest$1 = null; + let _this = null; + if (this.match(78)) { + _this = this.flowParseFunctionTypeParam(true); + _this.name = null; + if (!this.match(11)) this.expect(12); + } + while (!this.match(11) && !this.match(21)) { + params.push(this.flowParseFunctionTypeParam(false)); + if (!this.match(11)) this.expect(12); + } + if (this.eat(21)) rest$1 = this.flowParseFunctionTypeParam(false); + return { + params, + rest: rest$1, + _this + }; + } + flowIdentToTypeAnnotation(startLoc, node, id$4) { + switch (id$4.name) { + case "any": return this.finishNode(node, "AnyTypeAnnotation"); + case "bool": + case "boolean": return this.finishNode(node, "BooleanTypeAnnotation"); + case "mixed": return this.finishNode(node, "MixedTypeAnnotation"); + case "empty": return this.finishNode(node, "EmptyTypeAnnotation"); + case "number": return this.finishNode(node, "NumberTypeAnnotation"); + case "string": return this.finishNode(node, "StringTypeAnnotation"); + case "symbol": return this.finishNode(node, "SymbolTypeAnnotation"); + default: + this.checkNotUnderscore(id$4.name); + return this.flowParseGenericType(startLoc, id$4); + } + } + flowParsePrimaryType() { + const startLoc = this.state.startLoc; + const node = this.startNode(); + let tmp; + let type; + let isGroupedType = false; + const oldNoAnonFunctionType = this.state.noAnonFunctionType; + switch (this.state.type) { + case 5: return this.flowParseObjectType({ + allowStatic: false, + allowExact: false, + allowSpread: true, + allowProto: false, + allowInexact: true + }); + case 6: return this.flowParseObjectType({ + allowStatic: false, + allowExact: true, + allowSpread: true, + allowProto: false, + allowInexact: false + }); + case 0: + this.state.noAnonFunctionType = false; + type = this.flowParseTupleType(); + this.state.noAnonFunctionType = oldNoAnonFunctionType; + return type; + case 47: { + const node$1 = this.startNode(); + node$1.typeParameters = this.flowParseTypeParameterDeclaration(); + this.expect(10); + tmp = this.flowParseFunctionTypeParams(); + node$1.params = tmp.params; + node$1.rest = tmp.rest; + node$1.this = tmp._this; + this.expect(11); + this.expect(19); + node$1.returnType = this.flowParseType(); + return this.finishNode(node$1, "FunctionTypeAnnotation"); + } + case 10: { + const node$1 = this.startNode(); + this.next(); + if (!this.match(11) && !this.match(21)) if (tokenIsIdentifier(this.state.type) || this.match(78)) { + const token$1 = this.lookahead().type; + isGroupedType = token$1 !== 17 && token$1 !== 14; + } else isGroupedType = true; + if (isGroupedType) { + this.state.noAnonFunctionType = false; + type = this.flowParseType(); + this.state.noAnonFunctionType = oldNoAnonFunctionType; + if (this.state.noAnonFunctionType || !(this.match(12) || this.match(11) && this.lookahead().type === 19)) { + this.expect(11); + return type; + } else this.eat(12); + } + if (type) tmp = this.flowParseFunctionTypeParams([this.reinterpretTypeAsFunctionTypeParam(type)]); + else tmp = this.flowParseFunctionTypeParams(); + node$1.params = tmp.params; + node$1.rest = tmp.rest; + node$1.this = tmp._this; + this.expect(11); + this.expect(19); + node$1.returnType = this.flowParseType(); + node$1.typeParameters = null; + return this.finishNode(node$1, "FunctionTypeAnnotation"); + } + case 134: return this.parseLiteral(this.state.value, "StringLiteralTypeAnnotation"); + case 85: + case 86: + node.value = this.match(85); + this.next(); + return this.finishNode(node, "BooleanLiteralTypeAnnotation"); + case 53: + if (this.state.value === "-") { + this.next(); + if (this.match(135)) return this.parseLiteralAtNode(-this.state.value, "NumberLiteralTypeAnnotation", node); + if (this.match(136)) return this.parseLiteralAtNode(-this.state.value, "BigIntLiteralTypeAnnotation", node); + throw this.raise(FlowErrors.UnexpectedSubtractionOperand, this.state.startLoc); + } + this.unexpected(); + return; + case 135: return this.parseLiteral(this.state.value, "NumberLiteralTypeAnnotation"); + case 136: return this.parseLiteral(this.state.value, "BigIntLiteralTypeAnnotation"); + case 88: + this.next(); + return this.finishNode(node, "VoidTypeAnnotation"); + case 84: + this.next(); + return this.finishNode(node, "NullLiteralTypeAnnotation"); + case 78: + this.next(); + return this.finishNode(node, "ThisTypeAnnotation"); + case 55: + this.next(); + return this.finishNode(node, "ExistsTypeAnnotation"); + case 87: return this.flowParseTypeofType(); + default: if (tokenIsKeyword(this.state.type)) { + const label = tokenLabelName(this.state.type); + this.next(); + return super.createIdentifier(node, label); + } else if (tokenIsIdentifier(this.state.type)) { + if (this.isContextual(129)) return this.flowParseInterfaceType(); + return this.flowIdentToTypeAnnotation(startLoc, node, this.parseIdentifier()); + } + } + this.unexpected(); + } + flowParsePostfixType() { + const startLoc = this.state.startLoc; + let type = this.flowParsePrimaryType(); + let seenOptionalIndexedAccess = false; + while ((this.match(0) || this.match(18)) && !this.canInsertSemicolon()) { + const node = this.startNodeAt(startLoc); + const optional = this.eat(18); + seenOptionalIndexedAccess = seenOptionalIndexedAccess || optional; + this.expect(0); + if (!optional && this.match(3)) { + node.elementType = type; + this.next(); + type = this.finishNode(node, "ArrayTypeAnnotation"); + } else { + node.objectType = type; + node.indexType = this.flowParseType(); + this.expect(3); + if (seenOptionalIndexedAccess) { + node.optional = optional; + type = this.finishNode(node, "OptionalIndexedAccessType"); + } else type = this.finishNode(node, "IndexedAccessType"); + } + } + return type; + } + flowParsePrefixType() { + const node = this.startNode(); + if (this.eat(17)) { + node.typeAnnotation = this.flowParsePrefixType(); + return this.finishNode(node, "NullableTypeAnnotation"); + } else return this.flowParsePostfixType(); + } + flowParseAnonFunctionWithoutParens() { + const param = this.flowParsePrefixType(); + if (!this.state.noAnonFunctionType && this.eat(19)) { + const node = this.startNodeAt(param.loc.start); + node.params = [this.reinterpretTypeAsFunctionTypeParam(param)]; + node.rest = null; + node.this = null; + node.returnType = this.flowParseType(); + node.typeParameters = null; + return this.finishNode(node, "FunctionTypeAnnotation"); + } + return param; + } + flowParseIntersectionType() { + const node = this.startNode(); + this.eat(45); + const type = this.flowParseAnonFunctionWithoutParens(); + node.types = [type]; + while (this.eat(45)) node.types.push(this.flowParseAnonFunctionWithoutParens()); + return node.types.length === 1 ? type : this.finishNode(node, "IntersectionTypeAnnotation"); + } + flowParseUnionType() { + const node = this.startNode(); + this.eat(43); + const type = this.flowParseIntersectionType(); + node.types = [type]; + while (this.eat(43)) node.types.push(this.flowParseIntersectionType()); + return node.types.length === 1 ? type : this.finishNode(node, "UnionTypeAnnotation"); + } + flowParseType() { + const oldInType = this.state.inType; + this.state.inType = true; + const type = this.flowParseUnionType(); + this.state.inType = oldInType; + return type; + } + flowParseTypeOrImplicitInstantiation() { + if (this.state.type === 132 && this.state.value === "_") { + const startLoc = this.state.startLoc; + const node = this.parseIdentifier(); + return this.flowParseGenericType(startLoc, node); + } else return this.flowParseType(); + } + flowParseTypeAnnotation() { + const node = this.startNode(); + node.typeAnnotation = this.flowParseTypeInitialiser(); + return this.finishNode(node, "TypeAnnotation"); + } + flowParseTypeAnnotatableIdentifier(allowPrimitiveOverride) { + const ident = allowPrimitiveOverride ? this.parseIdentifier() : this.flowParseRestrictedIdentifier(); + if (this.match(14)) { + ident.typeAnnotation = this.flowParseTypeAnnotation(); + this.resetEndLocation(ident); + } + return ident; + } + typeCastToParameter(node) { + node.expression.typeAnnotation = node.typeAnnotation; + this.resetEndLocation(node.expression, node.typeAnnotation.loc.end); + return node.expression; + } + flowParseVariance() { + let variance$1 = null; + if (this.match(53)) { + variance$1 = this.startNode(); + if (this.state.value === "+") variance$1.kind = "plus"; + else variance$1.kind = "minus"; + this.next(); + return this.finishNode(variance$1, "Variance"); + } + return variance$1; + } + parseFunctionBody(node, allowExpressionBody, isMethod$2 = false) { + if (allowExpressionBody) { + this.forwardNoArrowParamsConversionAt(node, () => super.parseFunctionBody(node, true, isMethod$2)); + return; + } + super.parseFunctionBody(node, false, isMethod$2); + } + parseFunctionBodyAndFinish(node, type, isMethod$2 = false) { + if (this.match(14)) { + const typeNode = this.startNode(); + [typeNode.typeAnnotation, node.predicate] = this.flowParseTypeAndPredicateInitialiser(); + node.returnType = typeNode.typeAnnotation ? this.finishNode(typeNode, "TypeAnnotation") : null; + } + return super.parseFunctionBodyAndFinish(node, type, isMethod$2); + } + parseStatementLike(flags) { + if (this.state.strict && this.isContextual(129)) { + const lookahead = this.lookahead(); + if (tokenIsKeywordOrIdentifier(lookahead.type)) { + const node = this.startNode(); + this.next(); + return this.flowParseInterface(node); + } + } else if (this.isContextual(126)) { + const node = this.startNode(); + this.next(); + return this.flowParseEnumDeclaration(node); + } + const stmt = super.parseStatementLike(flags); + if (this.flowPragma === void 0 && !this.isValidDirective(stmt)) this.flowPragma = null; + return stmt; + } + parseExpressionStatement(node, expr, decorators) { + if (expr.type === "Identifier") { + if (expr.name === "declare") { + if (this.match(80) || tokenIsIdentifier(this.state.type) || this.match(68) || this.match(74) || this.match(82)) return this.flowParseDeclare(node); + } else if (tokenIsIdentifier(this.state.type)) { + if (expr.name === "interface") return this.flowParseInterface(node); + else if (expr.name === "type") return this.flowParseTypeAlias(node); + else if (expr.name === "opaque") return this.flowParseOpaqueType(node, false); + } + } + return super.parseExpressionStatement(node, expr, decorators); + } + shouldParseExportDeclaration() { + const { type } = this.state; + if (type === 126 || tokenIsFlowInterfaceOrTypeOrOpaque(type)) return !this.state.containsEsc; + return super.shouldParseExportDeclaration(); + } + isExportDefaultSpecifier() { + const { type } = this.state; + if (type === 126 || tokenIsFlowInterfaceOrTypeOrOpaque(type)) return this.state.containsEsc; + return super.isExportDefaultSpecifier(); + } + parseExportDefaultExpression() { + if (this.isContextual(126)) { + const node = this.startNode(); + this.next(); + return this.flowParseEnumDeclaration(node); + } + return super.parseExportDefaultExpression(); + } + parseConditional(expr, startLoc, refExpressionErrors) { + if (!this.match(17)) return expr; + if (this.state.maybeInArrowParameters) { + const nextCh = this.lookaheadCharCode(); + if (nextCh === 44 || nextCh === 61 || nextCh === 58 || nextCh === 41) { + this.setOptionalParametersError(refExpressionErrors); + return expr; + } + } + this.expect(17); + const state = this.state.clone(); + const originalNoArrowAt = this.state.noArrowAt; + const node = this.startNodeAt(startLoc); + let { consequent, failed } = this.tryParseConditionalConsequent(); + let [valid, invalid] = this.getArrowLikeExpressions(consequent); + if (failed || invalid.length > 0) { + const noArrowAt = [...originalNoArrowAt]; + if (invalid.length > 0) { + this.state = state; + this.state.noArrowAt = noArrowAt; + for (let i$5 = 0; i$5 < invalid.length; i$5++) noArrowAt.push(invalid[i$5].start); + ({consequent, failed} = this.tryParseConditionalConsequent()); + [valid, invalid] = this.getArrowLikeExpressions(consequent); + } + if (failed && valid.length > 1) this.raise(FlowErrors.AmbiguousConditionalArrow, state.startLoc); + if (failed && valid.length === 1) { + this.state = state; + noArrowAt.push(valid[0].start); + this.state.noArrowAt = noArrowAt; + ({consequent, failed} = this.tryParseConditionalConsequent()); + } + } + this.getArrowLikeExpressions(consequent, true); + this.state.noArrowAt = originalNoArrowAt; + this.expect(14); + node.test = expr; + node.consequent = consequent; + node.alternate = this.forwardNoArrowParamsConversionAt(node, () => this.parseMaybeAssign(void 0, void 0)); + return this.finishNode(node, "ConditionalExpression"); + } + tryParseConditionalConsequent() { + this.state.noArrowParamsConversionAt.push(this.state.start); + const consequent = this.parseMaybeAssignAllowIn(); + const failed = !this.match(14); + this.state.noArrowParamsConversionAt.pop(); + return { + consequent, + failed + }; + } + getArrowLikeExpressions(node, disallowInvalid) { + const stack = [node]; + const arrows = []; + while (stack.length !== 0) { + const node$1 = stack.pop(); + if (node$1.type === "ArrowFunctionExpression" && node$1.body.type !== "BlockStatement") { + if (node$1.typeParameters || !node$1.returnType) this.finishArrowValidation(node$1); + else arrows.push(node$1); + stack.push(node$1.body); + } else if (node$1.type === "ConditionalExpression") { + stack.push(node$1.consequent); + stack.push(node$1.alternate); + } + } + if (disallowInvalid) { + arrows.forEach((node$1) => this.finishArrowValidation(node$1)); + return [arrows, []]; + } + return partition(arrows, (node$1) => node$1.params.every((param) => this.isAssignable(param, true))); + } + finishArrowValidation(node) { + var _node$extra; + this.toAssignableList(node.params, (_node$extra = node.extra) == null ? void 0 : _node$extra.trailingCommaLoc, false); + this.scope.enter(6); + super.checkParams(node, false, true); + this.scope.exit(); + } + forwardNoArrowParamsConversionAt(node, parse$17) { + let result$1; + if (this.state.noArrowParamsConversionAt.includes(this.offsetToSourcePos(node.start))) { + this.state.noArrowParamsConversionAt.push(this.state.start); + result$1 = parse$17(); + this.state.noArrowParamsConversionAt.pop(); + } else result$1 = parse$17(); + return result$1; + } + parseParenItem(node, startLoc) { + const newNode = super.parseParenItem(node, startLoc); + if (this.eat(17)) { + newNode.optional = true; + this.resetEndLocation(node); + } + if (this.match(14)) { + const typeCastNode = this.startNodeAt(startLoc); + typeCastNode.expression = newNode; + typeCastNode.typeAnnotation = this.flowParseTypeAnnotation(); + return this.finishNode(typeCastNode, "TypeCastExpression"); + } + return newNode; + } + assertModuleNodeAllowed(node) { + if (node.type === "ImportDeclaration" && (node.importKind === "type" || node.importKind === "typeof") || node.type === "ExportNamedDeclaration" && node.exportKind === "type" || node.type === "ExportAllDeclaration" && node.exportKind === "type") return; + super.assertModuleNodeAllowed(node); + } + parseExportDeclaration(node) { + if (this.isContextual(130)) { + node.exportKind = "type"; + const declarationNode = this.startNode(); + this.next(); + if (this.match(5)) { + node.specifiers = this.parseExportSpecifiers(true); + super.parseExportFrom(node); + return null; + } else return this.flowParseTypeAlias(declarationNode); + } else if (this.isContextual(131)) { + node.exportKind = "type"; + const declarationNode = this.startNode(); + this.next(); + return this.flowParseOpaqueType(declarationNode, false); + } else if (this.isContextual(129)) { + node.exportKind = "type"; + const declarationNode = this.startNode(); + this.next(); + return this.flowParseInterface(declarationNode); + } else if (this.isContextual(126)) { + node.exportKind = "value"; + const declarationNode = this.startNode(); + this.next(); + return this.flowParseEnumDeclaration(declarationNode); + } else return super.parseExportDeclaration(node); + } + eatExportStar(node) { + if (super.eatExportStar(node)) return true; + if (this.isContextual(130) && this.lookahead().type === 55) { + node.exportKind = "type"; + this.next(); + this.next(); + return true; + } + return false; + } + maybeParseExportNamespaceSpecifier(node) { + const { startLoc } = this.state; + const hasNamespace = super.maybeParseExportNamespaceSpecifier(node); + if (hasNamespace && node.exportKind === "type") this.unexpected(startLoc); + return hasNamespace; + } + parseClassId(node, isStatement$10, optionalId) { + super.parseClassId(node, isStatement$10, optionalId); + if (this.match(47)) node.typeParameters = this.flowParseTypeParameterDeclaration(); + } + parseClassMember(classBody$1, member, state) { + const { startLoc } = this.state; + if (this.isContextual(125)) { + if (super.parseClassMemberFromModifier(classBody$1, member)) return; + member.declare = true; + } + super.parseClassMember(classBody$1, member, state); + if (member.declare) { + if (member.type !== "ClassProperty" && member.type !== "ClassPrivateProperty" && member.type !== "PropertyDefinition") this.raise(FlowErrors.DeclareClassElement, startLoc); + else if (member.value) this.raise(FlowErrors.DeclareClassFieldInitializer, member.value); + } + } + isIterator(word$3) { + return word$3 === "iterator" || word$3 === "asyncIterator"; + } + readIterator() { + const word$3 = super.readWord1(); + const fullWord = "@@" + word$3; + if (!this.isIterator(word$3) || !this.state.inType) this.raise(Errors.InvalidIdentifier, this.state.curPosition(), { identifierName: fullWord }); + this.finishToken(132, fullWord); + } + getTokenFromCode(code$1) { + const next = this.input.charCodeAt(this.state.pos + 1); + if (code$1 === 123 && next === 124) this.finishOp(6, 2); + else if (this.state.inType && (code$1 === 62 || code$1 === 60)) this.finishOp(code$1 === 62 ? 48 : 47, 1); + else if (this.state.inType && code$1 === 63) if (next === 46) this.finishOp(18, 2); + else this.finishOp(17, 1); + else if (isIteratorStart(code$1, next, this.input.charCodeAt(this.state.pos + 2))) { + this.state.pos += 2; + this.readIterator(); + } else super.getTokenFromCode(code$1); + } + isAssignable(node, isBinding$2) { + if (node.type === "TypeCastExpression") return this.isAssignable(node.expression, isBinding$2); + else return super.isAssignable(node, isBinding$2); + } + toAssignable(node, isLHS = false) { + if (!isLHS && node.type === "AssignmentExpression" && node.left.type === "TypeCastExpression") node.left = this.typeCastToParameter(node.left); + super.toAssignable(node, isLHS); + } + toAssignableList(exprList, trailingCommaLoc, isLHS) { + for (let i$5 = 0; i$5 < exprList.length; i$5++) { + const expr = exprList[i$5]; + if ((expr == null ? void 0 : expr.type) === "TypeCastExpression") exprList[i$5] = this.typeCastToParameter(expr); + } + super.toAssignableList(exprList, trailingCommaLoc, isLHS); + } + toReferencedList(exprList, isParenthesizedExpr) { + for (let i$5 = 0; i$5 < exprList.length; i$5++) { + var _expr$extra; + const expr = exprList[i$5]; + if (expr && expr.type === "TypeCastExpression" && !((_expr$extra = expr.extra) != null && _expr$extra.parenthesized) && (exprList.length > 1 || !isParenthesizedExpr)) this.raise(FlowErrors.TypeCastInPattern, expr.typeAnnotation); + } + return exprList; + } + parseArrayLike(close, canBePattern, isTuple, refExpressionErrors) { + const node = super.parseArrayLike(close, canBePattern, isTuple, refExpressionErrors); + if (canBePattern && !this.state.maybeInArrowParameters) this.toReferencedList(node.elements); + return node; + } + isValidLVal(type, isParenthesized, binding) { + return type === "TypeCastExpression" || super.isValidLVal(type, isParenthesized, binding); + } + parseClassProperty(node) { + if (this.match(14)) node.typeAnnotation = this.flowParseTypeAnnotation(); + return super.parseClassProperty(node); + } + parseClassPrivateProperty(node) { + if (this.match(14)) node.typeAnnotation = this.flowParseTypeAnnotation(); + return super.parseClassPrivateProperty(node); + } + isClassMethod() { + return this.match(47) || super.isClassMethod(); + } + isClassProperty() { + return this.match(14) || super.isClassProperty(); + } + isNonstaticConstructor(method) { + return !this.match(14) && super.isNonstaticConstructor(method); + } + pushClassMethod(classBody$1, method, isGenerator, isAsync, isConstructor, allowsDirectSuper) { + if (method.variance) this.unexpected(method.variance.loc.start); + delete method.variance; + if (this.match(47)) method.typeParameters = this.flowParseTypeParameterDeclaration(); + super.pushClassMethod(classBody$1, method, isGenerator, isAsync, isConstructor, allowsDirectSuper); + if (method.params && isConstructor) { + const params = method.params; + if (params.length > 0 && this.isThisParam(params[0])) this.raise(FlowErrors.ThisParamBannedInConstructor, method); + } else if (method.type === "MethodDefinition" && isConstructor && method.value.params) { + const params = method.value.params; + if (params.length > 0 && this.isThisParam(params[0])) this.raise(FlowErrors.ThisParamBannedInConstructor, method); + } + } + pushClassPrivateMethod(classBody$1, method, isGenerator, isAsync) { + if (method.variance) this.unexpected(method.variance.loc.start); + delete method.variance; + if (this.match(47)) method.typeParameters = this.flowParseTypeParameterDeclaration(); + super.pushClassPrivateMethod(classBody$1, method, isGenerator, isAsync); + } + parseClassSuper(node) { + super.parseClassSuper(node); + if (node.superClass && (this.match(47) || this.match(51))) node.superTypeParameters = this.flowParseTypeParameterInstantiationInExpression(); + if (this.isContextual(113)) { + this.next(); + const implemented = node.implements = []; + do { + const node$1 = this.startNode(); + node$1.id = this.flowParseRestrictedIdentifier(true); + if (this.match(47)) node$1.typeParameters = this.flowParseTypeParameterInstantiation(); + else node$1.typeParameters = null; + implemented.push(this.finishNode(node$1, "ClassImplements")); + } while (this.eat(12)); + } + } + checkGetterSetterParams(method) { + super.checkGetterSetterParams(method); + const params = this.getObjectOrClassMethodParams(method); + if (params.length > 0) { + const param = params[0]; + if (this.isThisParam(param) && method.kind === "get") this.raise(FlowErrors.GetterMayNotHaveThisParam, param); + else if (this.isThisParam(param)) this.raise(FlowErrors.SetterMayNotHaveThisParam, param); + } + } + parsePropertyNamePrefixOperator(node) { + node.variance = this.flowParseVariance(); + } + parseObjPropValue(prop, startLoc, isGenerator, isAsync, isPattern$2, isAccessor$1, refExpressionErrors) { + if (prop.variance) this.unexpected(prop.variance.loc.start); + delete prop.variance; + let typeParameters; + if (this.match(47) && !isAccessor$1) { + typeParameters = this.flowParseTypeParameterDeclaration(); + if (!this.match(10)) this.unexpected(); + } + const result$1 = super.parseObjPropValue(prop, startLoc, isGenerator, isAsync, isPattern$2, isAccessor$1, refExpressionErrors); + if (typeParameters) (result$1.value || result$1).typeParameters = typeParameters; + return result$1; + } + parseFunctionParamType(param) { + if (this.eat(17)) { + if (param.type !== "Identifier") this.raise(FlowErrors.PatternIsOptional, param); + if (this.isThisParam(param)) this.raise(FlowErrors.ThisParamMayNotBeOptional, param); + param.optional = true; + } + if (this.match(14)) param.typeAnnotation = this.flowParseTypeAnnotation(); + else if (this.isThisParam(param)) this.raise(FlowErrors.ThisParamAnnotationRequired, param); + if (this.match(29) && this.isThisParam(param)) this.raise(FlowErrors.ThisParamNoDefault, param); + this.resetEndLocation(param); + return param; + } + parseMaybeDefault(startLoc, left) { + const node = super.parseMaybeDefault(startLoc, left); + if (node.type === "AssignmentPattern" && node.typeAnnotation && node.right.start < node.typeAnnotation.start) this.raise(FlowErrors.TypeBeforeInitializer, node.typeAnnotation); + return node; + } + checkImportReflection(node) { + super.checkImportReflection(node); + if (node.module && node.importKind !== "value") this.raise(FlowErrors.ImportReflectionHasImportType, node.specifiers[0].loc.start); + } + parseImportSpecifierLocal(node, specifier, type) { + specifier.local = hasTypeImportKind(node) ? this.flowParseRestrictedIdentifier(true, true) : this.parseIdentifier(); + node.specifiers.push(this.finishImportSpecifier(specifier, type)); + } + isPotentialImportPhase(isExport) { + if (super.isPotentialImportPhase(isExport)) return true; + if (this.isContextual(130)) { + if (!isExport) return true; + const ch = this.lookaheadCharCode(); + return ch === 123 || ch === 42; + } + return !isExport && this.isContextual(87); + } + applyImportPhase(node, isExport, phase, loc) { + super.applyImportPhase(node, isExport, phase, loc); + if (isExport) { + if (!phase && this.match(65)) return; + node.exportKind = phase === "type" ? phase : "value"; + } else { + if (phase === "type" && this.match(55)) this.unexpected(); + node.importKind = phase === "type" || phase === "typeof" ? phase : "value"; + } + } + parseImportSpecifier(specifier, importedIsString, isInTypeOnlyImport, isMaybeTypeOnly, bindingType) { + const firstIdent = specifier.imported; + let specifierTypeKind = null; + if (firstIdent.type === "Identifier") { + if (firstIdent.name === "type") specifierTypeKind = "type"; + else if (firstIdent.name === "typeof") specifierTypeKind = "typeof"; + } + let isBinding$2 = false; + if (this.isContextual(93) && !this.isLookaheadContextual("as")) { + const as_ident = this.parseIdentifier(true); + if (specifierTypeKind !== null && !tokenIsKeywordOrIdentifier(this.state.type)) { + specifier.imported = as_ident; + specifier.importKind = specifierTypeKind; + specifier.local = cloneIdentifier(as_ident); + } else { + specifier.imported = firstIdent; + specifier.importKind = null; + specifier.local = this.parseIdentifier(); + } + } else { + if (specifierTypeKind !== null && tokenIsKeywordOrIdentifier(this.state.type)) { + specifier.imported = this.parseIdentifier(true); + specifier.importKind = specifierTypeKind; + } else { + if (importedIsString) throw this.raise(Errors.ImportBindingIsString, specifier, { importName: firstIdent.value }); + specifier.imported = firstIdent; + specifier.importKind = null; + } + if (this.eatContextual(93)) specifier.local = this.parseIdentifier(); + else { + isBinding$2 = true; + specifier.local = cloneIdentifier(specifier.imported); + } + } + const specifierIsTypeImport = hasTypeImportKind(specifier); + if (isInTypeOnlyImport && specifierIsTypeImport) this.raise(FlowErrors.ImportTypeShorthandOnlyInPureImport, specifier); + if (isInTypeOnlyImport || specifierIsTypeImport) this.checkReservedType(specifier.local.name, specifier.local.loc.start, true); + if (isBinding$2 && !isInTypeOnlyImport && !specifierIsTypeImport) this.checkReservedWord(specifier.local.name, specifier.loc.start, true, true); + return this.finishImportSpecifier(specifier, "ImportSpecifier"); + } + parseBindingAtom() { + switch (this.state.type) { + case 78: return this.parseIdentifier(true); + default: return super.parseBindingAtom(); + } + } + parseFunctionParams(node, isConstructor) { + const kind = node.kind; + if (kind !== "get" && kind !== "set" && this.match(47)) node.typeParameters = this.flowParseTypeParameterDeclaration(); + super.parseFunctionParams(node, isConstructor); + } + parseVarId(decl$1, kind) { + super.parseVarId(decl$1, kind); + if (this.match(14)) { + decl$1.id.typeAnnotation = this.flowParseTypeAnnotation(); + this.resetEndLocation(decl$1.id); + } + } + parseAsyncArrowFromCallExpression(node, call$2) { + if (this.match(14)) { + const oldNoAnonFunctionType = this.state.noAnonFunctionType; + this.state.noAnonFunctionType = true; + node.returnType = this.flowParseTypeAnnotation(); + this.state.noAnonFunctionType = oldNoAnonFunctionType; + } + return super.parseAsyncArrowFromCallExpression(node, call$2); + } + shouldParseAsyncArrow() { + return this.match(14) || super.shouldParseAsyncArrow(); + } + parseMaybeAssign(refExpressionErrors, afterLeftParse) { + var _jsx$1; + let state = null; + let jsx$1; + if (this.hasPlugin("jsx") && (this.match(143) || this.match(47))) { + state = this.state.clone(); + jsx$1 = this.tryParse(() => super.parseMaybeAssign(refExpressionErrors, afterLeftParse), state); + if (!jsx$1.error) return jsx$1.node; + const { context } = this.state; + const currentContext = context[context.length - 1]; + if (currentContext === types$4.j_oTag || currentContext === types$4.j_expr) context.pop(); + } + if ((_jsx$1 = jsx$1) != null && _jsx$1.error || this.match(47)) { + var _jsx2, _jsx3; + state = state || this.state.clone(); + let typeParameters; + const arrow = this.tryParse((abort) => { + var _arrowExpression$extr; + typeParameters = this.flowParseTypeParameterDeclaration(); + const arrowExpression$1 = this.forwardNoArrowParamsConversionAt(typeParameters, () => { + const result$1 = super.parseMaybeAssign(refExpressionErrors, afterLeftParse); + this.resetStartLocationFromNode(result$1, typeParameters); + return result$1; + }); + if ((_arrowExpression$extr = arrowExpression$1.extra) != null && _arrowExpression$extr.parenthesized) abort(); + const expr = this.maybeUnwrapTypeCastExpression(arrowExpression$1); + if (expr.type !== "ArrowFunctionExpression") abort(); + expr.typeParameters = typeParameters; + this.resetStartLocationFromNode(expr, typeParameters); + return arrowExpression$1; + }, state); + let arrowExpression = null; + if (arrow.node && this.maybeUnwrapTypeCastExpression(arrow.node).type === "ArrowFunctionExpression") { + if (!arrow.error && !arrow.aborted) { + if (arrow.node.async) this.raise(FlowErrors.UnexpectedTypeParameterBeforeAsyncArrowFunction, typeParameters); + return arrow.node; + } + arrowExpression = arrow.node; + } + if ((_jsx2 = jsx$1) != null && _jsx2.node) { + this.state = jsx$1.failState; + return jsx$1.node; + } + if (arrowExpression) { + this.state = arrow.failState; + return arrowExpression; + } + if ((_jsx3 = jsx$1) != null && _jsx3.thrown) throw jsx$1.error; + if (arrow.thrown) throw arrow.error; + throw this.raise(FlowErrors.UnexpectedTokenAfterTypeParameter, typeParameters); + } + return super.parseMaybeAssign(refExpressionErrors, afterLeftParse); + } + parseArrow(node) { + if (this.match(14)) { + const result$1 = this.tryParse(() => { + const oldNoAnonFunctionType = this.state.noAnonFunctionType; + this.state.noAnonFunctionType = true; + const typeNode = this.startNode(); + [typeNode.typeAnnotation, node.predicate] = this.flowParseTypeAndPredicateInitialiser(); + this.state.noAnonFunctionType = oldNoAnonFunctionType; + if (this.canInsertSemicolon()) this.unexpected(); + if (!this.match(19)) this.unexpected(); + return typeNode; + }); + if (result$1.thrown) return null; + if (result$1.error) this.state = result$1.failState; + node.returnType = result$1.node.typeAnnotation ? this.finishNode(result$1.node, "TypeAnnotation") : null; + } + return super.parseArrow(node); + } + shouldParseArrow(params) { + return this.match(14) || super.shouldParseArrow(params); + } + setArrowFunctionParameters(node, params) { + if (this.state.noArrowParamsConversionAt.includes(this.offsetToSourcePos(node.start))) node.params = params; + else super.setArrowFunctionParameters(node, params); + } + checkParams(node, allowDuplicates, isArrowFunction, strictModeChanged = true) { + if (isArrowFunction && this.state.noArrowParamsConversionAt.includes(this.offsetToSourcePos(node.start))) return; + for (let i$5 = 0; i$5 < node.params.length; i$5++) if (this.isThisParam(node.params[i$5]) && i$5 > 0) this.raise(FlowErrors.ThisParamMustBeFirst, node.params[i$5]); + super.checkParams(node, allowDuplicates, isArrowFunction, strictModeChanged); + } + parseParenAndDistinguishExpression(canBeArrow) { + return super.parseParenAndDistinguishExpression(canBeArrow && !this.state.noArrowAt.includes(this.sourceToOffsetPos(this.state.start))); + } + parseSubscripts(base$1, startLoc, noCalls) { + if (base$1.type === "Identifier" && base$1.name === "async" && this.state.noArrowAt.includes(startLoc.index)) { + this.next(); + const node = this.startNodeAt(startLoc); + node.callee = base$1; + node.arguments = super.parseCallExpressionArguments(11); + base$1 = this.finishNode(node, "CallExpression"); + } else if (base$1.type === "Identifier" && base$1.name === "async" && this.match(47)) { + const state = this.state.clone(); + const arrow = this.tryParse((abort) => this.parseAsyncArrowWithTypeParameters(startLoc) || abort(), state); + if (!arrow.error && !arrow.aborted) return arrow.node; + const result$1 = this.tryParse(() => super.parseSubscripts(base$1, startLoc, noCalls), state); + if (result$1.node && !result$1.error) return result$1.node; + if (arrow.node) { + this.state = arrow.failState; + return arrow.node; + } + if (result$1.node) { + this.state = result$1.failState; + return result$1.node; + } + throw arrow.error || result$1.error; + } + return super.parseSubscripts(base$1, startLoc, noCalls); + } + parseSubscript(base$1, startLoc, noCalls, subscriptState) { + if (this.match(18) && this.isLookaheadToken_lt()) { + subscriptState.optionalChainMember = true; + if (noCalls) { + subscriptState.stop = true; + return base$1; + } + this.next(); + const node = this.startNodeAt(startLoc); + node.callee = base$1; + node.typeArguments = this.flowParseTypeParameterInstantiationInExpression(); + this.expect(10); + node.arguments = this.parseCallExpressionArguments(11); + node.optional = true; + return this.finishCallExpression(node, true); + } else if (!noCalls && this.shouldParseTypes() && (this.match(47) || this.match(51))) { + const node = this.startNodeAt(startLoc); + node.callee = base$1; + const result$1 = this.tryParse(() => { + node.typeArguments = this.flowParseTypeParameterInstantiationCallOrNew(); + this.expect(10); + node.arguments = super.parseCallExpressionArguments(11); + if (subscriptState.optionalChainMember) node.optional = false; + return this.finishCallExpression(node, subscriptState.optionalChainMember); + }); + if (result$1.node) { + if (result$1.error) this.state = result$1.failState; + return result$1.node; + } + } + return super.parseSubscript(base$1, startLoc, noCalls, subscriptState); + } + parseNewCallee(node) { + super.parseNewCallee(node); + let targs = null; + if (this.shouldParseTypes() && this.match(47)) targs = this.tryParse(() => this.flowParseTypeParameterInstantiationCallOrNew()).node; + node.typeArguments = targs; + } + parseAsyncArrowWithTypeParameters(startLoc) { + const node = this.startNodeAt(startLoc); + this.parseFunctionParams(node, false); + if (!this.parseArrow(node)) return; + return super.parseArrowExpression(node, void 0, true); + } + readToken_mult_modulo(code$1) { + const next = this.input.charCodeAt(this.state.pos + 1); + if (code$1 === 42 && next === 47 && this.state.hasFlowComment) { + this.state.hasFlowComment = false; + this.state.pos += 2; + this.nextToken(); + return; + } + super.readToken_mult_modulo(code$1); + } + readToken_pipe_amp(code$1) { + const next = this.input.charCodeAt(this.state.pos + 1); + if (code$1 === 124 && next === 125) { + this.finishOp(9, 2); + return; + } + super.readToken_pipe_amp(code$1); + } + parseTopLevel(file$2, program$3) { + const fileNode = super.parseTopLevel(file$2, program$3); + if (this.state.hasFlowComment) this.raise(FlowErrors.UnterminatedFlowComment, this.state.curPosition()); + return fileNode; + } + skipBlockComment() { + if (this.hasPlugin("flowComments") && this.skipFlowComment()) { + if (this.state.hasFlowComment) throw this.raise(FlowErrors.NestedFlowComment, this.state.startLoc); + this.hasFlowCommentCompletion(); + const commentSkip = this.skipFlowComment(); + if (commentSkip) { + this.state.pos += commentSkip; + this.state.hasFlowComment = true; + } + return; + } + return super.skipBlockComment(this.state.hasFlowComment ? "*-/" : "*/"); + } + skipFlowComment() { + const { pos } = this.state; + let shiftToFirstNonWhiteSpace = 2; + while ([32, 9].includes(this.input.charCodeAt(pos + shiftToFirstNonWhiteSpace))) shiftToFirstNonWhiteSpace++; + const ch2 = this.input.charCodeAt(shiftToFirstNonWhiteSpace + pos); + const ch3 = this.input.charCodeAt(shiftToFirstNonWhiteSpace + pos + 1); + if (ch2 === 58 && ch3 === 58) return shiftToFirstNonWhiteSpace + 2; + if (this.input.slice(shiftToFirstNonWhiteSpace + pos, shiftToFirstNonWhiteSpace + pos + 12) === "flow-include") return shiftToFirstNonWhiteSpace + 12; + if (ch2 === 58 && ch3 !== 58) return shiftToFirstNonWhiteSpace; + return false; + } + hasFlowCommentCompletion() { + const end = this.input.indexOf("*/", this.state.pos); + if (end === -1) throw this.raise(Errors.UnterminatedComment, this.state.curPosition()); + } + flowEnumErrorBooleanMemberNotInitialized(loc, { enumName, memberName }) { + this.raise(FlowErrors.EnumBooleanMemberNotInitialized, loc, { + memberName, + enumName + }); + } + flowEnumErrorInvalidMemberInitializer(loc, enumContext) { + return this.raise(!enumContext.explicitType ? FlowErrors.EnumInvalidMemberInitializerUnknownType : enumContext.explicitType === "symbol" ? FlowErrors.EnumInvalidMemberInitializerSymbolType : FlowErrors.EnumInvalidMemberInitializerPrimaryType, loc, enumContext); + } + flowEnumErrorNumberMemberNotInitialized(loc, details) { + this.raise(FlowErrors.EnumNumberMemberNotInitialized, loc, details); + } + flowEnumErrorStringMemberInconsistentlyInitialized(node, details) { + this.raise(FlowErrors.EnumStringMemberInconsistentlyInitialized, node, details); + } + flowEnumMemberInit() { + const startLoc = this.state.startLoc; + const endOfInit = () => this.match(12) || this.match(8); + switch (this.state.type) { + case 135: { + const literal = this.parseNumericLiteral(this.state.value); + if (endOfInit()) return { + type: "number", + loc: literal.loc.start, + value: literal + }; + return { + type: "invalid", + loc: startLoc + }; + } + case 134: { + const literal = this.parseStringLiteral(this.state.value); + if (endOfInit()) return { + type: "string", + loc: literal.loc.start, + value: literal + }; + return { + type: "invalid", + loc: startLoc + }; + } + case 85: + case 86: { + const literal = this.parseBooleanLiteral(this.match(85)); + if (endOfInit()) return { + type: "boolean", + loc: literal.loc.start, + value: literal + }; + return { + type: "invalid", + loc: startLoc + }; + } + default: return { + type: "invalid", + loc: startLoc + }; + } + } + flowEnumMemberRaw() { + const loc = this.state.startLoc; + const id$4 = this.parseIdentifier(true); + const init = this.eat(29) ? this.flowEnumMemberInit() : { + type: "none", + loc + }; + return { + id: id$4, + init + }; + } + flowEnumCheckExplicitTypeMismatch(loc, context, expectedType) { + const { explicitType } = context; + if (explicitType === null) return; + if (explicitType !== expectedType) this.flowEnumErrorInvalidMemberInitializer(loc, context); + } + flowEnumMembers({ enumName, explicitType }) { + const seenNames = new Set(); + const members = { + booleanMembers: [], + numberMembers: [], + stringMembers: [], + defaultedMembers: [] + }; + let hasUnknownMembers = false; + while (!this.match(8)) { + if (this.eat(21)) { + hasUnknownMembers = true; + break; + } + const memberNode = this.startNode(); + const { id: id$4, init } = this.flowEnumMemberRaw(); + const memberName = id$4.name; + if (memberName === "") continue; + if (/^[a-z]/.test(memberName)) this.raise(FlowErrors.EnumInvalidMemberName, id$4, { + memberName, + suggestion: memberName[0].toUpperCase() + memberName.slice(1), + enumName + }); + if (seenNames.has(memberName)) this.raise(FlowErrors.EnumDuplicateMemberName, id$4, { + memberName, + enumName + }); + seenNames.add(memberName); + const context = { + enumName, + explicitType, + memberName + }; + memberNode.id = id$4; + switch (init.type) { + case "boolean": { + this.flowEnumCheckExplicitTypeMismatch(init.loc, context, "boolean"); + memberNode.init = init.value; + members.booleanMembers.push(this.finishNode(memberNode, "EnumBooleanMember")); + break; + } + case "number": { + this.flowEnumCheckExplicitTypeMismatch(init.loc, context, "number"); + memberNode.init = init.value; + members.numberMembers.push(this.finishNode(memberNode, "EnumNumberMember")); + break; + } + case "string": { + this.flowEnumCheckExplicitTypeMismatch(init.loc, context, "string"); + memberNode.init = init.value; + members.stringMembers.push(this.finishNode(memberNode, "EnumStringMember")); + break; + } + case "invalid": throw this.flowEnumErrorInvalidMemberInitializer(init.loc, context); + case "none": switch (explicitType) { + case "boolean": + this.flowEnumErrorBooleanMemberNotInitialized(init.loc, context); + break; + case "number": + this.flowEnumErrorNumberMemberNotInitialized(init.loc, context); + break; + default: members.defaultedMembers.push(this.finishNode(memberNode, "EnumDefaultedMember")); + } + } + if (!this.match(8)) this.expect(12); + } + return { + members, + hasUnknownMembers + }; + } + flowEnumStringMembers(initializedMembers, defaultedMembers, { enumName }) { + if (initializedMembers.length === 0) return defaultedMembers; + else if (defaultedMembers.length === 0) return initializedMembers; + else if (defaultedMembers.length > initializedMembers.length) { + for (const member of initializedMembers) this.flowEnumErrorStringMemberInconsistentlyInitialized(member, { enumName }); + return defaultedMembers; + } else { + for (const member of defaultedMembers) this.flowEnumErrorStringMemberInconsistentlyInitialized(member, { enumName }); + return initializedMembers; + } + } + flowEnumParseExplicitType({ enumName }) { + if (!this.eatContextual(102)) return null; + if (!tokenIsIdentifier(this.state.type)) throw this.raise(FlowErrors.EnumInvalidExplicitTypeUnknownSupplied, this.state.startLoc, { enumName }); + const { value } = this.state; + this.next(); + if (value !== "boolean" && value !== "number" && value !== "string" && value !== "symbol") this.raise(FlowErrors.EnumInvalidExplicitType, this.state.startLoc, { + enumName, + invalidEnumType: value + }); + return value; + } + flowEnumBody(node, id$4) { + const enumName = id$4.name; + const nameLoc = id$4.loc.start; + const explicitType = this.flowEnumParseExplicitType({ enumName }); + this.expect(5); + const { members, hasUnknownMembers } = this.flowEnumMembers({ + enumName, + explicitType + }); + node.hasUnknownMembers = hasUnknownMembers; + switch (explicitType) { + case "boolean": + node.explicitType = true; + node.members = members.booleanMembers; + this.expect(8); + return this.finishNode(node, "EnumBooleanBody"); + case "number": + node.explicitType = true; + node.members = members.numberMembers; + this.expect(8); + return this.finishNode(node, "EnumNumberBody"); + case "string": + node.explicitType = true; + node.members = this.flowEnumStringMembers(members.stringMembers, members.defaultedMembers, { enumName }); + this.expect(8); + return this.finishNode(node, "EnumStringBody"); + case "symbol": + node.members = members.defaultedMembers; + this.expect(8); + return this.finishNode(node, "EnumSymbolBody"); + default: { + const empty = () => { + node.members = []; + this.expect(8); + return this.finishNode(node, "EnumStringBody"); + }; + node.explicitType = false; + const boolsLen = members.booleanMembers.length; + const numsLen = members.numberMembers.length; + const strsLen = members.stringMembers.length; + const defaultedLen = members.defaultedMembers.length; + if (!boolsLen && !numsLen && !strsLen && !defaultedLen) return empty(); + else if (!boolsLen && !numsLen) { + node.members = this.flowEnumStringMembers(members.stringMembers, members.defaultedMembers, { enumName }); + this.expect(8); + return this.finishNode(node, "EnumStringBody"); + } else if (!numsLen && !strsLen && boolsLen >= defaultedLen) { + for (const member of members.defaultedMembers) this.flowEnumErrorBooleanMemberNotInitialized(member.loc.start, { + enumName, + memberName: member.id.name + }); + node.members = members.booleanMembers; + this.expect(8); + return this.finishNode(node, "EnumBooleanBody"); + } else if (!boolsLen && !strsLen && numsLen >= defaultedLen) { + for (const member of members.defaultedMembers) this.flowEnumErrorNumberMemberNotInitialized(member.loc.start, { + enumName, + memberName: member.id.name + }); + node.members = members.numberMembers; + this.expect(8); + return this.finishNode(node, "EnumNumberBody"); + } else { + this.raise(FlowErrors.EnumInconsistentMemberValues, nameLoc, { enumName }); + return empty(); + } + } + } + } + flowParseEnumDeclaration(node) { + const id$4 = this.parseIdentifier(); + node.id = id$4; + node.body = this.flowEnumBody(this.startNode(), id$4); + return this.finishNode(node, "EnumDeclaration"); + } + jsxParseOpeningElementAfterName(node) { + if (this.shouldParseTypes()) { + if (this.match(47) || this.match(51)) node.typeArguments = this.flowParseTypeParameterInstantiationInExpression(); + } + return super.jsxParseOpeningElementAfterName(node); + } + isLookaheadToken_lt() { + const next = this.nextTokenStart(); + if (this.input.charCodeAt(next) === 60) { + const afterNext = this.input.charCodeAt(next + 1); + return afterNext !== 60 && afterNext !== 61; + } + return false; + } + reScan_lt_gt() { + const { type } = this.state; + if (type === 47) { + this.state.pos -= 1; + this.readToken_lt(); + } else if (type === 48) { + this.state.pos -= 1; + this.readToken_gt(); + } + } + reScan_lt() { + const { type } = this.state; + if (type === 51) { + this.state.pos -= 2; + this.finishOp(47, 1); + return 47; + } + return type; + } + maybeUnwrapTypeCastExpression(node) { + return node.type === "TypeCastExpression" ? node.expression : node; + } + }; + const entities = { + __proto__: null, + quot: "\"", + amp: "&", + apos: "'", + lt: "<", + gt: ">", + nbsp: "\xA0", + iexcl: "¡", + cent: "¢", + pound: "£", + curren: "¤", + yen: "¥", + brvbar: "¦", + sect: "§", + uml: "¨", + copy: "©", + ordf: "ª", + laquo: "«", + not: "¬", + shy: "­", + reg: "®", + macr: "¯", + deg: "°", + plusmn: "±", + sup2: "²", + sup3: "³", + acute: "´", + micro: "µ", + para: "¶", + middot: "·", + cedil: "¸", + sup1: "¹", + ordm: "º", + raquo: "»", + frac14: "¼", + frac12: "½", + frac34: "¾", + iquest: "¿", + Agrave: "À", + Aacute: "Á", + Acirc: "Â", + Atilde: "Ã", + Auml: "Ä", + Aring: "Å", + AElig: "Æ", + Ccedil: "Ç", + Egrave: "È", + Eacute: "É", + Ecirc: "Ê", + Euml: "Ë", + Igrave: "Ì", + Iacute: "Í", + Icirc: "Î", + Iuml: "Ï", + ETH: "Ð", + Ntilde: "Ñ", + Ograve: "Ò", + Oacute: "Ó", + Ocirc: "Ô", + Otilde: "Õ", + Ouml: "Ö", + times: "×", + Oslash: "Ø", + Ugrave: "Ù", + Uacute: "Ú", + Ucirc: "Û", + Uuml: "Ü", + Yacute: "Ý", + THORN: "Þ", + szlig: "ß", + agrave: "à", + aacute: "á", + acirc: "â", + atilde: "ã", + auml: "ä", + aring: "å", + aelig: "æ", + ccedil: "ç", + egrave: "è", + eacute: "é", + ecirc: "ê", + euml: "ë", + igrave: "ì", + iacute: "í", + icirc: "î", + iuml: "ï", + eth: "ð", + ntilde: "ñ", + ograve: "ò", + oacute: "ó", + ocirc: "ô", + otilde: "õ", + ouml: "ö", + divide: "÷", + oslash: "ø", + ugrave: "ù", + uacute: "ú", + ucirc: "û", + uuml: "ü", + yacute: "ý", + thorn: "þ", + yuml: "ÿ", + OElig: "Œ", + oelig: "œ", + Scaron: "Š", + scaron: "š", + Yuml: "Ÿ", + fnof: "ƒ", + circ: "ˆ", + tilde: "˜", + Alpha: "Α", + Beta: "Β", + Gamma: "Γ", + Delta: "Δ", + Epsilon: "Ε", + Zeta: "Ζ", + Eta: "Η", + Theta: "Θ", + Iota: "Ι", + Kappa: "Κ", + Lambda: "Λ", + Mu: "Μ", + Nu: "Ν", + Xi: "Ξ", + Omicron: "Ο", + Pi: "Π", + Rho: "Ρ", + Sigma: "Σ", + Tau: "Τ", + Upsilon: "Υ", + Phi: "Φ", + Chi: "Χ", + Psi: "Ψ", + Omega: "Ω", + alpha: "α", + beta: "β", + gamma: "γ", + delta: "δ", + epsilon: "ε", + zeta: "ζ", + eta: "η", + theta: "θ", + iota: "ι", + kappa: "κ", + lambda: "λ", + mu: "μ", + nu: "ν", + xi: "ξ", + omicron: "ο", + pi: "π", + rho: "ρ", + sigmaf: "ς", + sigma: "σ", + tau: "τ", + upsilon: "υ", + phi: "φ", + chi: "χ", + psi: "ψ", + omega: "ω", + thetasym: "ϑ", + upsih: "ϒ", + piv: "ϖ", + ensp: " ", + emsp: " ", + thinsp: " ", + zwnj: "‌", + zwj: "‍", + lrm: "‎", + rlm: "‏", + ndash: "–", + mdash: "—", + lsquo: "‘", + rsquo: "’", + sbquo: "‚", + ldquo: "“", + rdquo: "”", + bdquo: "„", + dagger: "†", + Dagger: "‡", + bull: "•", + hellip: "…", + permil: "‰", + prime: "′", + Prime: "″", + lsaquo: "‹", + rsaquo: "›", + oline: "‾", + frasl: "⁄", + euro: "€", + image: "ℑ", + weierp: "℘", + real: "ℜ", + trade: "™", + alefsym: "ℵ", + larr: "←", + uarr: "↑", + rarr: "→", + darr: "↓", + harr: "↔", + crarr: "↵", + lArr: "⇐", + uArr: "⇑", + rArr: "⇒", + dArr: "⇓", + hArr: "⇔", + forall: "∀", + part: "∂", + exist: "∃", + empty: "∅", + nabla: "∇", + isin: "∈", + notin: "∉", + ni: "∋", + prod: "∏", + sum: "∑", + minus: "−", + lowast: "∗", + radic: "√", + prop: "∝", + infin: "∞", + ang: "∠", + and: "∧", + or: "∨", + cap: "∩", + cup: "∪", + int: "∫", + there4: "∴", + sim: "∼", + cong: "≅", + asymp: "≈", + ne: "≠", + equiv: "≡", + le: "≤", + ge: "≥", + sub: "⊂", + sup: "⊃", + nsub: "⊄", + sube: "⊆", + supe: "⊇", + oplus: "⊕", + otimes: "⊗", + perp: "⊥", + sdot: "⋅", + lceil: "⌈", + rceil: "⌉", + lfloor: "⌊", + rfloor: "⌋", + lang: "〈", + rang: "〉", + loz: "◊", + spades: "♠", + clubs: "♣", + hearts: "♥", + diams: "♦" + }; + const JsxErrors = ParseErrorEnum`jsx`({ + AttributeIsEmpty: "JSX attributes must only be assigned a non-empty expression.", + MissingClosingTagElement: ({ openingTagName }) => `Expected corresponding JSX closing tag for <${openingTagName}>.`, + MissingClosingTagFragment: "Expected corresponding JSX closing tag for <>.", + UnexpectedSequenceExpression: "Sequence expressions cannot be directly nested inside JSX. Did you mean to wrap it in parentheses (...)?", + UnexpectedToken: ({ unexpected, HTMLEntity }) => `Unexpected token \`${unexpected}\`. Did you mean \`${HTMLEntity}\` or \`{'${unexpected}'}\`?`, + UnsupportedJsxValue: "JSX value should be either an expression or a quoted JSX text.", + UnterminatedJsxContent: "Unterminated JSX contents.", + UnwrappedAdjacentJSXElements: "Adjacent JSX elements must be wrapped in an enclosing tag. Did you want a JSX fragment <>...?" + }); + function isFragment(object$3) { + return object$3 ? object$3.type === "JSXOpeningFragment" || object$3.type === "JSXClosingFragment" : false; + } + function getQualifiedJSXName(object$3) { + if (object$3.type === "JSXIdentifier") return object$3.name; + if (object$3.type === "JSXNamespacedName") return object$3.namespace.name + ":" + object$3.name.name; + if (object$3.type === "JSXMemberExpression") return getQualifiedJSXName(object$3.object) + "." + getQualifiedJSXName(object$3.property); + throw new Error("Node had unexpected type: " + object$3.type); + } + var jsx = (superClass) => class JSXParserMixin extends superClass { + jsxReadToken() { + let out = ""; + let chunkStart = this.state.pos; + for (;;) { + if (this.state.pos >= this.length) throw this.raise(JsxErrors.UnterminatedJsxContent, this.state.startLoc); + const ch = this.input.charCodeAt(this.state.pos); + switch (ch) { + case 60: + case 123: + if (this.state.pos === this.state.start) { + if (ch === 60 && this.state.canStartJSXElement) { + ++this.state.pos; + this.finishToken(143); + } else super.getTokenFromCode(ch); + return; + } + out += this.input.slice(chunkStart, this.state.pos); + this.finishToken(142, out); + return; + case 38: + out += this.input.slice(chunkStart, this.state.pos); + out += this.jsxReadEntity(); + chunkStart = this.state.pos; + break; + case 62: + case 125: + default: if (isNewLine(ch)) { + out += this.input.slice(chunkStart, this.state.pos); + out += this.jsxReadNewLine(true); + chunkStart = this.state.pos; + } else ++this.state.pos; + } + } + } + jsxReadNewLine(normalizeCRLF) { + const ch = this.input.charCodeAt(this.state.pos); + let out; + ++this.state.pos; + if (ch === 13 && this.input.charCodeAt(this.state.pos) === 10) { + ++this.state.pos; + out = normalizeCRLF ? "\n" : "\r\n"; + } else out = String.fromCharCode(ch); + ++this.state.curLine; + this.state.lineStart = this.state.pos; + return out; + } + jsxReadString(quote) { + let out = ""; + let chunkStart = ++this.state.pos; + for (;;) { + if (this.state.pos >= this.length) throw this.raise(Errors.UnterminatedString, this.state.startLoc); + const ch = this.input.charCodeAt(this.state.pos); + if (ch === quote) break; + if (ch === 38) { + out += this.input.slice(chunkStart, this.state.pos); + out += this.jsxReadEntity(); + chunkStart = this.state.pos; + } else if (isNewLine(ch)) { + out += this.input.slice(chunkStart, this.state.pos); + out += this.jsxReadNewLine(false); + chunkStart = this.state.pos; + } else ++this.state.pos; + } + out += this.input.slice(chunkStart, this.state.pos++); + this.finishToken(134, out); + } + jsxReadEntity() { + const startPos = ++this.state.pos; + if (this.codePointAtPos(this.state.pos) === 35) { + ++this.state.pos; + let radix = 10; + if (this.codePointAtPos(this.state.pos) === 120) { + radix = 16; + ++this.state.pos; + } + const codePoint = this.readInt(radix, void 0, false, "bail"); + if (codePoint !== null && this.codePointAtPos(this.state.pos) === 59) { + ++this.state.pos; + return String.fromCodePoint(codePoint); + } + } else { + let count = 0; + let semi = false; + while (count++ < 10 && this.state.pos < this.length && !(semi = this.codePointAtPos(this.state.pos) === 59)) ++this.state.pos; + if (semi) { + const desc = this.input.slice(startPos, this.state.pos); + const entity = entities[desc]; + ++this.state.pos; + if (entity) return entity; + } + } + this.state.pos = startPos; + return "&"; + } + jsxReadWord() { + let ch; + const start = this.state.pos; + do + ch = this.input.charCodeAt(++this.state.pos); + while (isIdentifierChar$1(ch) || ch === 45); + this.finishToken(141, this.input.slice(start, this.state.pos)); + } + jsxParseIdentifier() { + const node = this.startNode(); + if (this.match(141)) node.name = this.state.value; + else if (tokenIsKeyword(this.state.type)) node.name = tokenLabelName(this.state.type); + else this.unexpected(); + this.next(); + return this.finishNode(node, "JSXIdentifier"); + } + jsxParseNamespacedName() { + const startLoc = this.state.startLoc; + const name = this.jsxParseIdentifier(); + if (!this.eat(14)) return name; + const node = this.startNodeAt(startLoc); + node.namespace = name; + node.name = this.jsxParseIdentifier(); + return this.finishNode(node, "JSXNamespacedName"); + } + jsxParseElementName() { + const startLoc = this.state.startLoc; + let node = this.jsxParseNamespacedName(); + if (node.type === "JSXNamespacedName") return node; + while (this.eat(16)) { + const newNode = this.startNodeAt(startLoc); + newNode.object = node; + newNode.property = this.jsxParseIdentifier(); + node = this.finishNode(newNode, "JSXMemberExpression"); + } + return node; + } + jsxParseAttributeValue() { + let node; + switch (this.state.type) { + case 5: + node = this.startNode(); + this.setContext(types$4.brace); + this.next(); + node = this.jsxParseExpressionContainer(node, types$4.j_oTag); + if (node.expression.type === "JSXEmptyExpression") this.raise(JsxErrors.AttributeIsEmpty, node); + return node; + case 143: + case 134: return this.parseExprAtom(); + default: throw this.raise(JsxErrors.UnsupportedJsxValue, this.state.startLoc); + } + } + jsxParseEmptyExpression() { + const node = this.startNodeAt(this.state.lastTokEndLoc); + return this.finishNodeAt(node, "JSXEmptyExpression", this.state.startLoc); + } + jsxParseSpreadChild(node) { + this.next(); + node.expression = this.parseExpression(); + this.setContext(types$4.j_expr); + this.state.canStartJSXElement = true; + this.expect(8); + return this.finishNode(node, "JSXSpreadChild"); + } + jsxParseExpressionContainer(node, previousContext) { + if (this.match(8)) node.expression = this.jsxParseEmptyExpression(); + else { + const expression$2 = this.parseExpression(); + node.expression = expression$2; + } + this.setContext(previousContext); + this.state.canStartJSXElement = true; + this.expect(8); + return this.finishNode(node, "JSXExpressionContainer"); + } + jsxParseAttribute() { + const node = this.startNode(); + if (this.match(5)) { + this.setContext(types$4.brace); + this.next(); + this.expect(21); + node.argument = this.parseMaybeAssignAllowIn(); + this.setContext(types$4.j_oTag); + this.state.canStartJSXElement = true; + this.expect(8); + return this.finishNode(node, "JSXSpreadAttribute"); + } + node.name = this.jsxParseNamespacedName(); + node.value = this.eat(29) ? this.jsxParseAttributeValue() : null; + return this.finishNode(node, "JSXAttribute"); + } + jsxParseOpeningElementAt(startLoc) { + const node = this.startNodeAt(startLoc); + if (this.eat(144)) return this.finishNode(node, "JSXOpeningFragment"); + node.name = this.jsxParseElementName(); + return this.jsxParseOpeningElementAfterName(node); + } + jsxParseOpeningElementAfterName(node) { + const attributes = []; + while (!this.match(56) && !this.match(144)) attributes.push(this.jsxParseAttribute()); + node.attributes = attributes; + node.selfClosing = this.eat(56); + this.expect(144); + return this.finishNode(node, "JSXOpeningElement"); + } + jsxParseClosingElementAt(startLoc) { + const node = this.startNodeAt(startLoc); + if (this.eat(144)) return this.finishNode(node, "JSXClosingFragment"); + node.name = this.jsxParseElementName(); + this.expect(144); + return this.finishNode(node, "JSXClosingElement"); + } + jsxParseElementAt(startLoc) { + const node = this.startNodeAt(startLoc); + const children = []; + const openingElement = this.jsxParseOpeningElementAt(startLoc); + let closingElement = null; + if (!openingElement.selfClosing) { + contents: for (;;) switch (this.state.type) { + case 143: + startLoc = this.state.startLoc; + this.next(); + if (this.eat(56)) { + closingElement = this.jsxParseClosingElementAt(startLoc); + break contents; + } + children.push(this.jsxParseElementAt(startLoc)); + break; + case 142: + children.push(this.parseLiteral(this.state.value, "JSXText")); + break; + case 5: { + const node$1 = this.startNode(); + this.setContext(types$4.brace); + this.next(); + if (this.match(21)) children.push(this.jsxParseSpreadChild(node$1)); + else children.push(this.jsxParseExpressionContainer(node$1, types$4.j_expr)); + break; + } + default: this.unexpected(); + } + if (isFragment(openingElement) && !isFragment(closingElement) && closingElement !== null) this.raise(JsxErrors.MissingClosingTagFragment, closingElement); + else if (!isFragment(openingElement) && isFragment(closingElement)) this.raise(JsxErrors.MissingClosingTagElement, closingElement, { openingTagName: getQualifiedJSXName(openingElement.name) }); + else if (!isFragment(openingElement) && !isFragment(closingElement)) { + if (getQualifiedJSXName(closingElement.name) !== getQualifiedJSXName(openingElement.name)) this.raise(JsxErrors.MissingClosingTagElement, closingElement, { openingTagName: getQualifiedJSXName(openingElement.name) }); + } + } + if (isFragment(openingElement)) { + node.openingFragment = openingElement; + node.closingFragment = closingElement; + } else { + node.openingElement = openingElement; + node.closingElement = closingElement; + } + node.children = children; + if (this.match(47)) throw this.raise(JsxErrors.UnwrappedAdjacentJSXElements, this.state.startLoc); + return isFragment(openingElement) ? this.finishNode(node, "JSXFragment") : this.finishNode(node, "JSXElement"); + } + jsxParseElement() { + const startLoc = this.state.startLoc; + this.next(); + return this.jsxParseElementAt(startLoc); + } + setContext(newContext) { + const { context } = this.state; + context[context.length - 1] = newContext; + } + parseExprAtom(refExpressionErrors) { + if (this.match(143)) return this.jsxParseElement(); + else if (this.match(47) && this.input.charCodeAt(this.state.pos) !== 33) { + this.replaceToken(143); + return this.jsxParseElement(); + } else return super.parseExprAtom(refExpressionErrors); + } + skipSpace() { + const curContext = this.curContext(); + if (!curContext.preserveSpace) super.skipSpace(); + } + getTokenFromCode(code$1) { + const context = this.curContext(); + if (context === types$4.j_expr) { + this.jsxReadToken(); + return; + } + if (context === types$4.j_oTag || context === types$4.j_cTag) { + if (isIdentifierStart$1(code$1)) { + this.jsxReadWord(); + return; + } + if (code$1 === 62) { + ++this.state.pos; + this.finishToken(144); + return; + } + if ((code$1 === 34 || code$1 === 39) && context === types$4.j_oTag) { + this.jsxReadString(code$1); + return; + } + } + if (code$1 === 60 && this.state.canStartJSXElement && this.input.charCodeAt(this.state.pos + 1) !== 33) { + ++this.state.pos; + this.finishToken(143); + return; + } + super.getTokenFromCode(code$1); + } + updateContext(prevType) { + const { context, type } = this.state; + if (type === 56 && prevType === 143) { + context.splice(-2, 2, types$4.j_cTag); + this.state.canStartJSXElement = false; + } else if (type === 143) context.push(types$4.j_oTag); + else if (type === 144) { + const out = context[context.length - 1]; + if (out === types$4.j_oTag && prevType === 56 || out === types$4.j_cTag) { + context.pop(); + this.state.canStartJSXElement = context[context.length - 1] === types$4.j_expr; + } else { + this.setContext(types$4.j_expr); + this.state.canStartJSXElement = true; + } + } else this.state.canStartJSXElement = tokenComesBeforeExpression(type); + } + }; + var TypeScriptScope = class extends Scope$2 { + constructor(...args) { + super(...args); + this.tsNames = new Map(); + } + }; + var TypeScriptScopeHandler = class extends ScopeHandler { + constructor(...args) { + super(...args); + this.importsStack = []; + } + createScope(flags) { + this.importsStack.push(new Set()); + return new TypeScriptScope(flags); + } + enter(flags) { + if (flags === 256) this.importsStack.push(new Set()); + super.enter(flags); + } + exit() { + const flags = super.exit(); + if (flags === 256) this.importsStack.pop(); + return flags; + } + hasImport(name, allowShadow) { + const len = this.importsStack.length; + if (this.importsStack[len - 1].has(name)) return true; + if (!allowShadow && len > 1) { + for (let i$5 = 0; i$5 < len - 1; i$5++) if (this.importsStack[i$5].has(name)) return true; + } + return false; + } + declareName(name, bindingType, loc) { + if (bindingType & 4096) { + if (this.hasImport(name, true)) this.parser.raise(Errors.VarRedeclaration, loc, { identifierName: name }); + this.importsStack[this.importsStack.length - 1].add(name); + return; + } + const scope$1 = this.currentScope(); + let type = scope$1.tsNames.get(name) || 0; + if (bindingType & 1024) { + this.maybeExportDefined(scope$1, name); + scope$1.tsNames.set(name, type | 16); + return; + } + super.declareName(name, bindingType, loc); + if (bindingType & 2) { + if (!(bindingType & 1)) { + this.checkRedeclarationInScope(scope$1, name, bindingType, loc); + this.maybeExportDefined(scope$1, name); + } + type = type | 1; + } + if (bindingType & 256) type = type | 2; + if (bindingType & 512) type = type | 4; + if (bindingType & 128) type = type | 8; + if (type) scope$1.tsNames.set(name, type); + } + isRedeclaredInScope(scope$1, name, bindingType) { + const type = scope$1.tsNames.get(name); + if ((type & 2) > 0) { + if (bindingType & 256) { + const isConst = !!(bindingType & 512); + const wasConst = (type & 4) > 0; + return isConst !== wasConst; + } + return true; + } + if (bindingType & 128 && (type & 8) > 0) if (scope$1.names.get(name) & 2) return !!(bindingType & 1); + else return false; + if (bindingType & 2 && (type & 1) > 0) return true; + return super.isRedeclaredInScope(scope$1, name, bindingType); + } + checkLocalExport(id$4) { + const { name } = id$4; + if (this.hasImport(name)) return; + const len = this.scopeStack.length; + for (let i$5 = len - 1; i$5 >= 0; i$5--) { + const scope$1 = this.scopeStack[i$5]; + const type = scope$1.tsNames.get(name); + if ((type & 1) > 0 || (type & 16) > 0) return; + } + super.checkLocalExport(id$4); + } + }; + const unwrapParenthesizedExpression = (node) => { + return node.type === "ParenthesizedExpression" ? unwrapParenthesizedExpression(node.expression) : node; + }; + var LValParser = class extends NodeUtils { + toAssignable(node, isLHS = false) { + var _node$extra, _node$extra3; + let parenthesized = void 0; + if (node.type === "ParenthesizedExpression" || (_node$extra = node.extra) != null && _node$extra.parenthesized) { + parenthesized = unwrapParenthesizedExpression(node); + if (isLHS) { + if (parenthesized.type === "Identifier") this.expressionScope.recordArrowParameterBindingError(Errors.InvalidParenthesizedAssignment, node); + else if (parenthesized.type !== "MemberExpression" && !this.isOptionalMemberExpression(parenthesized)) this.raise(Errors.InvalidParenthesizedAssignment, node); + } else this.raise(Errors.InvalidParenthesizedAssignment, node); + } + switch (node.type) { + case "Identifier": + case "ObjectPattern": + case "ArrayPattern": + case "AssignmentPattern": + case "RestElement": break; + case "ObjectExpression": + node.type = "ObjectPattern"; + for (let i$5 = 0, length = node.properties.length, last$3 = length - 1; i$5 < length; i$5++) { + var _node$extra2; + const prop = node.properties[i$5]; + const isLast = i$5 === last$3; + this.toAssignableObjectExpressionProp(prop, isLast, isLHS); + if (isLast && prop.type === "RestElement" && (_node$extra2 = node.extra) != null && _node$extra2.trailingCommaLoc) this.raise(Errors.RestTrailingComma, node.extra.trailingCommaLoc); + } + break; + case "ObjectProperty": { + const { key, value } = node; + if (this.isPrivateName(key)) this.classScope.usePrivateName(this.getPrivateNameSV(key), key.loc.start); + this.toAssignable(value, isLHS); + break; + } + case "SpreadElement": throw new Error("Internal @babel/parser error (this is a bug, please report it). SpreadElement should be converted by .toAssignable's caller."); + case "ArrayExpression": + node.type = "ArrayPattern"; + this.toAssignableList(node.elements, (_node$extra3 = node.extra) == null ? void 0 : _node$extra3.trailingCommaLoc, isLHS); + break; + case "AssignmentExpression": + if (node.operator !== "=") this.raise(Errors.MissingEqInAssignment, node.left.loc.end); + node.type = "AssignmentPattern"; + delete node.operator; + this.toAssignable(node.left, isLHS); + break; + case "ParenthesizedExpression": + this.toAssignable(parenthesized, isLHS); + break; + } + } + toAssignableObjectExpressionProp(prop, isLast, isLHS) { + if (prop.type === "ObjectMethod") this.raise(prop.kind === "get" || prop.kind === "set" ? Errors.PatternHasAccessor : Errors.PatternHasMethod, prop.key); + else if (prop.type === "SpreadElement") { + prop.type = "RestElement"; + const arg = prop.argument; + this.checkToRestConversion(arg, false); + this.toAssignable(arg, isLHS); + if (!isLast) this.raise(Errors.RestTrailingComma, prop); + } else this.toAssignable(prop, isLHS); + } + toAssignableList(exprList, trailingCommaLoc, isLHS) { + const end = exprList.length - 1; + for (let i$5 = 0; i$5 <= end; i$5++) { + const elt = exprList[i$5]; + if (!elt) continue; + this.toAssignableListItem(exprList, i$5, isLHS); + if (elt.type === "RestElement") { + if (i$5 < end) this.raise(Errors.RestTrailingComma, elt); + else if (trailingCommaLoc) this.raise(Errors.RestTrailingComma, trailingCommaLoc); + } + } + } + toAssignableListItem(exprList, index$1, isLHS) { + const node = exprList[index$1]; + if (node.type === "SpreadElement") { + node.type = "RestElement"; + const arg = node.argument; + this.checkToRestConversion(arg, true); + this.toAssignable(arg, isLHS); + } else this.toAssignable(node, isLHS); + } + isAssignable(node, isBinding$2) { + switch (node.type) { + case "Identifier": + case "ObjectPattern": + case "ArrayPattern": + case "AssignmentPattern": + case "RestElement": return true; + case "ObjectExpression": { + const last$3 = node.properties.length - 1; + return node.properties.every((prop, i$5) => { + return prop.type !== "ObjectMethod" && (i$5 === last$3 || prop.type !== "SpreadElement") && this.isAssignable(prop); + }); + } + case "ObjectProperty": return this.isAssignable(node.value); + case "SpreadElement": return this.isAssignable(node.argument); + case "ArrayExpression": return node.elements.every((element) => element === null || this.isAssignable(element)); + case "AssignmentExpression": return node.operator === "="; + case "ParenthesizedExpression": return this.isAssignable(node.expression); + case "MemberExpression": + case "OptionalMemberExpression": return !isBinding$2; + default: return false; + } + } + toReferencedList(exprList, isParenthesizedExpr) { + return exprList; + } + toReferencedListDeep(exprList, isParenthesizedExpr) { + this.toReferencedList(exprList, isParenthesizedExpr); + for (const expr of exprList) if ((expr == null ? void 0 : expr.type) === "ArrayExpression") this.toReferencedListDeep(expr.elements); + } + parseSpread(refExpressionErrors) { + const node = this.startNode(); + this.next(); + node.argument = this.parseMaybeAssignAllowIn(refExpressionErrors, void 0); + return this.finishNode(node, "SpreadElement"); + } + parseRestBinding() { + const node = this.startNode(); + this.next(); + node.argument = this.parseBindingAtom(); + return this.finishNode(node, "RestElement"); + } + parseBindingAtom() { + switch (this.state.type) { + case 0: { + const node = this.startNode(); + this.next(); + node.elements = this.parseBindingList(3, 93, 1); + return this.finishNode(node, "ArrayPattern"); + } + case 5: return this.parseObjectLike(8, true); + } + return this.parseIdentifier(); + } + parseBindingList(close, closeCharCode, flags) { + const allowEmpty = flags & 1; + const elts = []; + let first$1 = true; + while (!this.eat(close)) { + if (first$1) first$1 = false; + else this.expect(12); + if (allowEmpty && this.match(12)) elts.push(null); + else if (this.eat(close)) break; + else if (this.match(21)) { + let rest$1 = this.parseRestBinding(); + if (this.hasPlugin("flow") || flags & 2) rest$1 = this.parseFunctionParamType(rest$1); + elts.push(rest$1); + if (!this.checkCommaAfterRest(closeCharCode)) { + this.expect(close); + break; + } + } else { + const decorators = []; + if (flags & 2) { + if (this.match(26) && this.hasPlugin("decorators")) this.raise(Errors.UnsupportedParameterDecorator, this.state.startLoc); + while (this.match(26)) decorators.push(this.parseDecorator()); + } + elts.push(this.parseBindingElement(flags, decorators)); + } + } + return elts; + } + parseBindingRestProperty(prop) { + this.next(); + prop.argument = this.parseIdentifier(); + this.checkCommaAfterRest(125); + return this.finishNode(prop, "RestElement"); + } + parseBindingProperty() { + const { type, startLoc } = this.state; + if (type === 21) return this.parseBindingRestProperty(this.startNode()); + const prop = this.startNode(); + if (type === 139) { + this.expectPlugin("destructuringPrivate", startLoc); + this.classScope.usePrivateName(this.state.value, startLoc); + prop.key = this.parsePrivateName(); + } else this.parsePropertyName(prop); + prop.method = false; + return this.parseObjPropValue(prop, startLoc, false, false, true, false); + } + parseBindingElement(flags, decorators) { + const left = this.parseMaybeDefault(); + if (this.hasPlugin("flow") || flags & 2) this.parseFunctionParamType(left); + const elt = this.parseMaybeDefault(left.loc.start, left); + if (decorators.length) left.decorators = decorators; + return elt; + } + parseFunctionParamType(param) { + return param; + } + parseMaybeDefault(startLoc, left) { + startLoc != null || (startLoc = this.state.startLoc); + left = left != null ? left : this.parseBindingAtom(); + if (!this.eat(29)) return left; + const node = this.startNodeAt(startLoc); + node.left = left; + node.right = this.parseMaybeAssignAllowIn(); + return this.finishNode(node, "AssignmentPattern"); + } + isValidLVal(type, isUnparenthesizedInAssign, binding) { + switch (type) { + case "AssignmentPattern": return "left"; + case "RestElement": return "argument"; + case "ObjectProperty": return "value"; + case "ParenthesizedExpression": return "expression"; + case "ArrayPattern": return "elements"; + case "ObjectPattern": return "properties"; + } + return false; + } + isOptionalMemberExpression(expression$2) { + return expression$2.type === "OptionalMemberExpression"; + } + checkLVal(expression$2, ancestor, binding = 64, checkClashes = false, strictModeChanged = false, hasParenthesizedAncestor = false) { + var _expression$extra; + const type = expression$2.type; + if (this.isObjectMethod(expression$2)) return; + const isOptionalMemberExpression$3 = this.isOptionalMemberExpression(expression$2); + if (isOptionalMemberExpression$3 || type === "MemberExpression") { + if (isOptionalMemberExpression$3) { + this.expectPlugin("optionalChainingAssign", expression$2.loc.start); + if (ancestor.type !== "AssignmentExpression") this.raise(Errors.InvalidLhsOptionalChaining, expression$2, { ancestor }); + } + if (binding !== 64) this.raise(Errors.InvalidPropertyBindingPattern, expression$2); + return; + } + if (type === "Identifier") { + this.checkIdentifier(expression$2, binding, strictModeChanged); + const { name } = expression$2; + if (checkClashes) if (checkClashes.has(name)) this.raise(Errors.ParamDupe, expression$2); + else checkClashes.add(name); + return; + } + const validity = this.isValidLVal(type, !(hasParenthesizedAncestor || (_expression$extra = expression$2.extra) != null && _expression$extra.parenthesized) && ancestor.type === "AssignmentExpression", binding); + if (validity === true) return; + if (validity === false) { + const ParseErrorClass = binding === 64 ? Errors.InvalidLhs : Errors.InvalidLhsBinding; + this.raise(ParseErrorClass, expression$2, { ancestor }); + return; + } + let key, isParenthesizedExpression$2; + if (typeof validity === "string") { + key = validity; + isParenthesizedExpression$2 = type === "ParenthesizedExpression"; + } else [key, isParenthesizedExpression$2] = validity; + const nextAncestor = type === "ArrayPattern" || type === "ObjectPattern" ? { type } : ancestor; + const val = expression$2[key]; + if (Array.isArray(val)) { + for (const child of val) if (child) this.checkLVal(child, nextAncestor, binding, checkClashes, strictModeChanged, isParenthesizedExpression$2); + } else if (val) this.checkLVal(val, nextAncestor, binding, checkClashes, strictModeChanged, isParenthesizedExpression$2); + } + checkIdentifier(at$3, bindingType, strictModeChanged = false) { + if (this.state.strict && (strictModeChanged ? isStrictBindReservedWord$1(at$3.name, this.inModule) : isStrictBindOnlyReservedWord$1(at$3.name))) if (bindingType === 64) this.raise(Errors.StrictEvalArguments, at$3, { referenceName: at$3.name }); + else this.raise(Errors.StrictEvalArgumentsBinding, at$3, { bindingName: at$3.name }); + if (bindingType & 8192 && at$3.name === "let") this.raise(Errors.LetInLexicalBinding, at$3); + if (!(bindingType & 64)) this.declareNameFromIdentifier(at$3, bindingType); + } + declareNameFromIdentifier(identifier$6, binding) { + this.scope.declareName(identifier$6.name, binding, identifier$6.loc.start); + } + checkToRestConversion(node, allowPattern) { + switch (node.type) { + case "ParenthesizedExpression": + this.checkToRestConversion(node.expression, allowPattern); + break; + case "Identifier": + case "MemberExpression": break; + case "ArrayExpression": + case "ObjectExpression": if (allowPattern) break; + default: this.raise(Errors.InvalidRestAssignmentPattern, node); + } + } + checkCommaAfterRest(close) { + if (!this.match(12)) return false; + this.raise(this.lookaheadCharCode() === close ? Errors.RestTrailingComma : Errors.ElementAfterRest, this.state.startLoc); + return true; + } + }; + function nonNull(x$2) { + if (x$2 == null) throw new Error(`Unexpected ${x$2} value.`); + return x$2; + } + function assert$3(x$2) { + if (!x$2) throw new Error("Assert fail"); + } + const TSErrors = ParseErrorEnum`typescript`({ + AbstractMethodHasImplementation: ({ methodName }) => `Method '${methodName}' cannot have an implementation because it is marked abstract.`, + AbstractPropertyHasInitializer: ({ propertyName }) => `Property '${propertyName}' cannot have an initializer because it is marked abstract.`, + AccessorCannotBeOptional: "An 'accessor' property cannot be declared optional.", + AccessorCannotDeclareThisParameter: "'get' and 'set' accessors cannot declare 'this' parameters.", + AccessorCannotHaveTypeParameters: "An accessor cannot have type parameters.", + ClassMethodHasDeclare: "Class methods cannot have the 'declare' modifier.", + ClassMethodHasReadonly: "Class methods cannot have the 'readonly' modifier.", + ConstInitializerMustBeStringOrNumericLiteralOrLiteralEnumReference: "A 'const' initializer in an ambient context must be a string or numeric literal or literal enum reference.", + ConstructorHasTypeParameters: "Type parameters cannot appear on a constructor declaration.", + DeclareAccessor: ({ kind }) => `'declare' is not allowed in ${kind}ters.`, + DeclareClassFieldHasInitializer: "Initializers are not allowed in ambient contexts.", + DeclareFunctionHasImplementation: "An implementation cannot be declared in ambient contexts.", + DuplicateAccessibilityModifier: ({ modifier }) => `Accessibility modifier already seen.`, + DuplicateModifier: ({ modifier }) => `Duplicate modifier: '${modifier}'.`, + EmptyHeritageClauseType: ({ token: token$1 }) => `'${token$1}' list cannot be empty.`, + EmptyTypeArguments: "Type argument list cannot be empty.", + EmptyTypeParameters: "Type parameter list cannot be empty.", + ExpectedAmbientAfterExportDeclare: "'export declare' must be followed by an ambient declaration.", + ImportAliasHasImportType: "An import alias can not use 'import type'.", + ImportReflectionHasImportType: "An `import module` declaration can not use `type` modifier", + IncompatibleModifiers: ({ modifiers }) => `'${modifiers[0]}' modifier cannot be used with '${modifiers[1]}' modifier.`, + IndexSignatureHasAbstract: "Index signatures cannot have the 'abstract' modifier.", + IndexSignatureHasAccessibility: ({ modifier }) => `Index signatures cannot have an accessibility modifier ('${modifier}').`, + IndexSignatureHasDeclare: "Index signatures cannot have the 'declare' modifier.", + IndexSignatureHasOverride: "'override' modifier cannot appear on an index signature.", + IndexSignatureHasStatic: "Index signatures cannot have the 'static' modifier.", + InitializerNotAllowedInAmbientContext: "Initializers are not allowed in ambient contexts.", + InvalidHeritageClauseType: ({ token: token$1 }) => `'${token$1}' list can only include identifiers or qualified-names with optional type arguments.`, + InvalidModifierOnTypeMember: ({ modifier }) => `'${modifier}' modifier cannot appear on a type member.`, + InvalidModifierOnTypeParameter: ({ modifier }) => `'${modifier}' modifier cannot appear on a type parameter.`, + InvalidModifierOnTypeParameterPositions: ({ modifier }) => `'${modifier}' modifier can only appear on a type parameter of a class, interface or type alias.`, + InvalidModifiersOrder: ({ orderedModifiers }) => `'${orderedModifiers[0]}' modifier must precede '${orderedModifiers[1]}' modifier.`, + InvalidPropertyAccessAfterInstantiationExpression: "Invalid property access after an instantiation expression. You can either wrap the instantiation expression in parentheses, or delete the type arguments.", + InvalidTupleMemberLabel: "Tuple members must be labeled with a simple identifier.", + MissingInterfaceName: "'interface' declarations must be followed by an identifier.", + NonAbstractClassHasAbstractMethod: "Abstract methods can only appear within an abstract class.", + NonClassMethodPropertyHasAbstractModifer: "'abstract' modifier can only appear on a class, method, or property declaration.", + OptionalTypeBeforeRequired: "A required element cannot follow an optional element.", + OverrideNotInSubClass: "This member cannot have an 'override' modifier because its containing class does not extend another class.", + PatternIsOptional: "A binding pattern parameter cannot be optional in an implementation signature.", + PrivateElementHasAbstract: "Private elements cannot have the 'abstract' modifier.", + PrivateElementHasAccessibility: ({ modifier }) => `Private elements cannot have an accessibility modifier ('${modifier}').`, + ReadonlyForMethodSignature: "'readonly' modifier can only appear on a property declaration or index signature.", + ReservedArrowTypeParam: "This syntax is reserved in files with the .mts or .cts extension. Add a trailing comma, as in `() => ...`.", + ReservedTypeAssertion: "This syntax is reserved in files with the .mts or .cts extension. Use an `as` expression instead.", + SetAccessorCannotHaveOptionalParameter: "A 'set' accessor cannot have an optional parameter.", + SetAccessorCannotHaveRestParameter: "A 'set' accessor cannot have rest parameter.", + SetAccessorCannotHaveReturnType: "A 'set' accessor cannot have a return type annotation.", + SingleTypeParameterWithoutTrailingComma: ({ typeParameterName }) => `Single type parameter ${typeParameterName} should have a trailing comma. Example usage: <${typeParameterName},>.`, + StaticBlockCannotHaveModifier: "Static class blocks cannot have any modifier.", + TupleOptionalAfterType: "A labeled tuple optional element must be declared using a question mark after the name and before the colon (`name?: type`), rather than after the type (`name: type?`).", + TypeAnnotationAfterAssign: "Type annotations must come before default assignments, e.g. instead of `age = 25: number` use `age: number = 25`.", + TypeImportCannotSpecifyDefaultAndNamed: "A type-only import can specify a default import or named bindings, but not both.", + TypeModifierIsUsedInTypeExports: "The 'type' modifier cannot be used on a named export when 'export type' is used on its export statement.", + TypeModifierIsUsedInTypeImports: "The 'type' modifier cannot be used on a named import when 'import type' is used on its import statement.", + UnexpectedParameterModifier: "A parameter property is only allowed in a constructor implementation.", + UnexpectedReadonly: "'readonly' type modifier is only permitted on array and tuple literal types.", + UnexpectedTypeAnnotation: "Did not expect a type annotation here.", + UnexpectedTypeCastInParameter: "Unexpected type cast in parameter position.", + UnsupportedImportTypeArgument: "Argument in a type import must be a string literal.", + UnsupportedParameterPropertyKind: "A parameter property may not be declared using a binding pattern.", + UnsupportedSignatureParameterKind: ({ type }) => `Name in a signature must be an Identifier, ObjectPattern or ArrayPattern, instead got ${type}.` + }); + function keywordTypeFromName(value) { + switch (value) { + case "any": return "TSAnyKeyword"; + case "boolean": return "TSBooleanKeyword"; + case "bigint": return "TSBigIntKeyword"; + case "never": return "TSNeverKeyword"; + case "number": return "TSNumberKeyword"; + case "object": return "TSObjectKeyword"; + case "string": return "TSStringKeyword"; + case "symbol": return "TSSymbolKeyword"; + case "undefined": return "TSUndefinedKeyword"; + case "unknown": return "TSUnknownKeyword"; + default: return void 0; + } + } + function tsIsAccessModifier(modifier) { + return modifier === "private" || modifier === "public" || modifier === "protected"; + } + function tsIsVarianceAnnotations(modifier) { + return modifier === "in" || modifier === "out"; + } + var typescript = (superClass) => class TypeScriptParserMixin extends superClass { + constructor(...args) { + super(...args); + this.tsParseInOutModifiers = this.tsParseModifiers.bind(this, { + allowedModifiers: ["in", "out"], + disallowedModifiers: [ + "const", + "public", + "private", + "protected", + "readonly", + "declare", + "abstract", + "override" + ], + errorTemplate: TSErrors.InvalidModifierOnTypeParameter + }); + this.tsParseConstModifier = this.tsParseModifiers.bind(this, { + allowedModifiers: ["const"], + disallowedModifiers: ["in", "out"], + errorTemplate: TSErrors.InvalidModifierOnTypeParameterPositions + }); + this.tsParseInOutConstModifiers = this.tsParseModifiers.bind(this, { + allowedModifiers: [ + "in", + "out", + "const" + ], + disallowedModifiers: [ + "public", + "private", + "protected", + "readonly", + "declare", + "abstract", + "override" + ], + errorTemplate: TSErrors.InvalidModifierOnTypeParameter + }); + } + getScopeHandler() { + return TypeScriptScopeHandler; + } + tsIsIdentifier() { + return tokenIsIdentifier(this.state.type); + } + tsTokenCanFollowModifier() { + return this.match(0) || this.match(5) || this.match(55) || this.match(21) || this.match(139) || this.isLiteralPropertyName(); + } + tsNextTokenOnSameLineAndCanFollowModifier() { + this.next(); + if (this.hasPrecedingLineBreak()) return false; + return this.tsTokenCanFollowModifier(); + } + tsNextTokenCanFollowModifier() { + if (this.match(106)) { + this.next(); + return this.tsTokenCanFollowModifier(); + } + return this.tsNextTokenOnSameLineAndCanFollowModifier(); + } + tsParseModifier(allowedModifiers, stopOnStartOfClassStaticBlock) { + if (!tokenIsIdentifier(this.state.type) && this.state.type !== 58 && this.state.type !== 75) return void 0; + const modifier = this.state.value; + if (allowedModifiers.includes(modifier)) { + if (stopOnStartOfClassStaticBlock && this.tsIsStartOfStaticBlocks()) return void 0; + if (this.tsTryParse(this.tsNextTokenCanFollowModifier.bind(this))) return modifier; + } + return void 0; + } + tsParseModifiers({ allowedModifiers, disallowedModifiers, stopOnStartOfClassStaticBlock, errorTemplate = TSErrors.InvalidModifierOnTypeMember }, modified) { + const enforceOrder = (loc, modifier, before$1, after$1) => { + if (modifier === before$1 && modified[after$1]) this.raise(TSErrors.InvalidModifiersOrder, loc, { orderedModifiers: [before$1, after$1] }); + }; + const incompatible = (loc, modifier, mod1, mod2) => { + if (modified[mod1] && modifier === mod2 || modified[mod2] && modifier === mod1) this.raise(TSErrors.IncompatibleModifiers, loc, { modifiers: [mod1, mod2] }); + }; + for (;;) { + const { startLoc } = this.state; + const modifier = this.tsParseModifier(allowedModifiers.concat(disallowedModifiers != null ? disallowedModifiers : []), stopOnStartOfClassStaticBlock); + if (!modifier) break; + if (tsIsAccessModifier(modifier)) if (modified.accessibility) this.raise(TSErrors.DuplicateAccessibilityModifier, startLoc, { modifier }); + else { + enforceOrder(startLoc, modifier, modifier, "override"); + enforceOrder(startLoc, modifier, modifier, "static"); + enforceOrder(startLoc, modifier, modifier, "readonly"); + modified.accessibility = modifier; + } + else if (tsIsVarianceAnnotations(modifier)) { + if (modified[modifier]) this.raise(TSErrors.DuplicateModifier, startLoc, { modifier }); + modified[modifier] = true; + enforceOrder(startLoc, modifier, "in", "out"); + } else { + if (hasOwnProperty.call(modified, modifier)) this.raise(TSErrors.DuplicateModifier, startLoc, { modifier }); + else { + enforceOrder(startLoc, modifier, "static", "readonly"); + enforceOrder(startLoc, modifier, "static", "override"); + enforceOrder(startLoc, modifier, "override", "readonly"); + enforceOrder(startLoc, modifier, "abstract", "override"); + incompatible(startLoc, modifier, "declare", "override"); + incompatible(startLoc, modifier, "static", "abstract"); + } + modified[modifier] = true; + } + if (disallowedModifiers != null && disallowedModifiers.includes(modifier)) this.raise(errorTemplate, startLoc, { modifier }); + } + } + tsIsListTerminator(kind) { + switch (kind) { + case "EnumMembers": + case "TypeMembers": return this.match(8); + case "HeritageClauseElement": return this.match(5); + case "TupleElementTypes": return this.match(3); + case "TypeParametersOrArguments": return this.match(48); + } + } + tsParseList(kind, parseElement$1) { + const result$1 = []; + while (!this.tsIsListTerminator(kind)) result$1.push(parseElement$1()); + return result$1; + } + tsParseDelimitedList(kind, parseElement$1, refTrailingCommaPos) { + return nonNull(this.tsParseDelimitedListWorker(kind, parseElement$1, true, refTrailingCommaPos)); + } + tsParseDelimitedListWorker(kind, parseElement$1, expectSuccess, refTrailingCommaPos) { + const result$1 = []; + let trailingCommaPos = -1; + for (;;) { + if (this.tsIsListTerminator(kind)) break; + trailingCommaPos = -1; + const element = parseElement$1(); + if (element == null) return void 0; + result$1.push(element); + if (this.eat(12)) { + trailingCommaPos = this.state.lastTokStartLoc.index; + continue; + } + if (this.tsIsListTerminator(kind)) break; + if (expectSuccess) this.expect(12); + return void 0; + } + if (refTrailingCommaPos) refTrailingCommaPos.value = trailingCommaPos; + return result$1; + } + tsParseBracketedList(kind, parseElement$1, bracket, skipFirstToken, refTrailingCommaPos) { + if (!skipFirstToken) if (bracket) this.expect(0); + else this.expect(47); + const result$1 = this.tsParseDelimitedList(kind, parseElement$1, refTrailingCommaPos); + if (bracket) this.expect(3); + else this.expect(48); + return result$1; + } + tsParseImportType() { + const node = this.startNode(); + this.expect(83); + this.expect(10); + if (!this.match(134)) { + this.raise(TSErrors.UnsupportedImportTypeArgument, this.state.startLoc); + node.argument = super.parseExprAtom(); + } else node.argument = this.parseStringLiteral(this.state.value); + if (this.eat(12) && !this.match(11)) { + node.options = super.parseMaybeAssignAllowIn(); + this.eat(12); + } else node.options = null; + this.expect(11); + if (this.eat(16)) node.qualifier = this.tsParseEntityName(3); + if (this.match(47)) node.typeParameters = this.tsParseTypeArguments(); + return this.finishNode(node, "TSImportType"); + } + tsParseEntityName(flags) { + let entity; + if (flags & 1 && this.match(78)) if (flags & 2) entity = this.parseIdentifier(true); + else { + const node = this.startNode(); + this.next(); + entity = this.finishNode(node, "ThisExpression"); + } + else entity = this.parseIdentifier(!!(flags & 1)); + while (this.eat(16)) { + const node = this.startNodeAtNode(entity); + node.left = entity; + node.right = this.parseIdentifier(!!(flags & 1)); + entity = this.finishNode(node, "TSQualifiedName"); + } + return entity; + } + tsParseTypeReference() { + const node = this.startNode(); + node.typeName = this.tsParseEntityName(1); + if (!this.hasPrecedingLineBreak() && this.match(47)) node.typeParameters = this.tsParseTypeArguments(); + return this.finishNode(node, "TSTypeReference"); + } + tsParseThisTypePredicate(lhs) { + this.next(); + const node = this.startNodeAtNode(lhs); + node.parameterName = lhs; + node.typeAnnotation = this.tsParseTypeAnnotation(false); + node.asserts = false; + return this.finishNode(node, "TSTypePredicate"); + } + tsParseThisTypeNode() { + const node = this.startNode(); + this.next(); + return this.finishNode(node, "TSThisType"); + } + tsParseTypeQuery() { + const node = this.startNode(); + this.expect(87); + if (this.match(83)) node.exprName = this.tsParseImportType(); + else node.exprName = this.tsParseEntityName(3); + if (!this.hasPrecedingLineBreak() && this.match(47)) node.typeParameters = this.tsParseTypeArguments(); + return this.finishNode(node, "TSTypeQuery"); + } + tsParseTypeParameter(parseModifiers) { + const node = this.startNode(); + parseModifiers(node); + node.name = this.tsParseTypeParameterName(); + node.constraint = this.tsEatThenParseType(81); + node.default = this.tsEatThenParseType(29); + return this.finishNode(node, "TSTypeParameter"); + } + tsTryParseTypeParameters(parseModifiers) { + if (this.match(47)) return this.tsParseTypeParameters(parseModifiers); + } + tsParseTypeParameters(parseModifiers) { + const node = this.startNode(); + if (this.match(47) || this.match(143)) this.next(); + else this.unexpected(); + const refTrailingCommaPos = { value: -1 }; + node.params = this.tsParseBracketedList("TypeParametersOrArguments", this.tsParseTypeParameter.bind(this, parseModifiers), false, true, refTrailingCommaPos); + if (node.params.length === 0) this.raise(TSErrors.EmptyTypeParameters, node); + if (refTrailingCommaPos.value !== -1) this.addExtra(node, "trailingComma", refTrailingCommaPos.value); + return this.finishNode(node, "TSTypeParameterDeclaration"); + } + tsFillSignature(returnToken, signature) { + const returnTokenRequired = returnToken === 19; + const paramsKey = "parameters"; + const returnTypeKey = "typeAnnotation"; + signature.typeParameters = this.tsTryParseTypeParameters(this.tsParseConstModifier); + this.expect(10); + signature[paramsKey] = this.tsParseBindingListForSignature(); + if (returnTokenRequired) signature[returnTypeKey] = this.tsParseTypeOrTypePredicateAnnotation(returnToken); + else if (this.match(returnToken)) signature[returnTypeKey] = this.tsParseTypeOrTypePredicateAnnotation(returnToken); + } + tsParseBindingListForSignature() { + const list$4 = super.parseBindingList(11, 41, 2); + for (const pattern of list$4) { + const { type } = pattern; + if (type === "AssignmentPattern" || type === "TSParameterProperty") this.raise(TSErrors.UnsupportedSignatureParameterKind, pattern, { type }); + } + return list$4; + } + tsParseTypeMemberSemicolon() { + if (!this.eat(12) && !this.isLineTerminator()) this.expect(13); + } + tsParseSignatureMember(kind, node) { + this.tsFillSignature(14, node); + this.tsParseTypeMemberSemicolon(); + return this.finishNode(node, kind); + } + tsIsUnambiguouslyIndexSignature() { + this.next(); + if (tokenIsIdentifier(this.state.type)) { + this.next(); + return this.match(14); + } + return false; + } + tsTryParseIndexSignature(node) { + if (!(this.match(0) && this.tsLookAhead(this.tsIsUnambiguouslyIndexSignature.bind(this)))) return; + this.expect(0); + const id$4 = this.parseIdentifier(); + id$4.typeAnnotation = this.tsParseTypeAnnotation(); + this.resetEndLocation(id$4); + this.expect(3); + node.parameters = [id$4]; + const type = this.tsTryParseTypeAnnotation(); + if (type) node.typeAnnotation = type; + this.tsParseTypeMemberSemicolon(); + return this.finishNode(node, "TSIndexSignature"); + } + tsParsePropertyOrMethodSignature(node, readonly) { + if (this.eat(17)) node.optional = true; + const nodeAny = node; + if (this.match(10) || this.match(47)) { + if (readonly) this.raise(TSErrors.ReadonlyForMethodSignature, node); + const method = nodeAny; + if (method.kind && this.match(47)) this.raise(TSErrors.AccessorCannotHaveTypeParameters, this.state.curPosition()); + this.tsFillSignature(14, method); + this.tsParseTypeMemberSemicolon(); + const paramsKey = "parameters"; + const returnTypeKey = "typeAnnotation"; + if (method.kind === "get") { + if (method[paramsKey].length > 0) { + this.raise(Errors.BadGetterArity, this.state.curPosition()); + if (this.isThisParam(method[paramsKey][0])) this.raise(TSErrors.AccessorCannotDeclareThisParameter, this.state.curPosition()); + } + } else if (method.kind === "set") { + if (method[paramsKey].length !== 1) this.raise(Errors.BadSetterArity, this.state.curPosition()); + else { + const firstParameter = method[paramsKey][0]; + if (this.isThisParam(firstParameter)) this.raise(TSErrors.AccessorCannotDeclareThisParameter, this.state.curPosition()); + if (firstParameter.type === "Identifier" && firstParameter.optional) this.raise(TSErrors.SetAccessorCannotHaveOptionalParameter, this.state.curPosition()); + if (firstParameter.type === "RestElement") this.raise(TSErrors.SetAccessorCannotHaveRestParameter, this.state.curPosition()); + } + if (method[returnTypeKey]) this.raise(TSErrors.SetAccessorCannotHaveReturnType, method[returnTypeKey]); + } else method.kind = "method"; + return this.finishNode(method, "TSMethodSignature"); + } else { + const property$1 = nodeAny; + if (readonly) property$1.readonly = true; + const type = this.tsTryParseTypeAnnotation(); + if (type) property$1.typeAnnotation = type; + this.tsParseTypeMemberSemicolon(); + return this.finishNode(property$1, "TSPropertySignature"); + } + } + tsParseTypeMember() { + const node = this.startNode(); + if (this.match(10) || this.match(47)) return this.tsParseSignatureMember("TSCallSignatureDeclaration", node); + if (this.match(77)) { + const id$4 = this.startNode(); + this.next(); + if (this.match(10) || this.match(47)) return this.tsParseSignatureMember("TSConstructSignatureDeclaration", node); + else { + node.key = this.createIdentifier(id$4, "new"); + return this.tsParsePropertyOrMethodSignature(node, false); + } + } + this.tsParseModifiers({ + allowedModifiers: ["readonly"], + disallowedModifiers: [ + "declare", + "abstract", + "private", + "protected", + "public", + "static", + "override" + ] + }, node); + const idx = this.tsTryParseIndexSignature(node); + if (idx) return idx; + super.parsePropertyName(node); + if (!node.computed && node.key.type === "Identifier" && (node.key.name === "get" || node.key.name === "set") && this.tsTokenCanFollowModifier()) { + node.kind = node.key.name; + super.parsePropertyName(node); + } + return this.tsParsePropertyOrMethodSignature(node, !!node.readonly); + } + tsParseTypeLiteral() { + const node = this.startNode(); + node.members = this.tsParseObjectTypeMembers(); + return this.finishNode(node, "TSTypeLiteral"); + } + tsParseObjectTypeMembers() { + this.expect(5); + const members = this.tsParseList("TypeMembers", this.tsParseTypeMember.bind(this)); + this.expect(8); + return members; + } + tsIsStartOfMappedType() { + this.next(); + if (this.eat(53)) return this.isContextual(122); + if (this.isContextual(122)) this.next(); + if (!this.match(0)) return false; + this.next(); + if (!this.tsIsIdentifier()) return false; + this.next(); + return this.match(58); + } + tsParseMappedType() { + const node = this.startNode(); + this.expect(5); + if (this.match(53)) { + node.readonly = this.state.value; + this.next(); + this.expectContextual(122); + } else if (this.eatContextual(122)) node.readonly = true; + this.expect(0); + { + const typeParameter$1 = this.startNode(); + typeParameter$1.name = this.tsParseTypeParameterName(); + typeParameter$1.constraint = this.tsExpectThenParseType(58); + node.typeParameter = this.finishNode(typeParameter$1, "TSTypeParameter"); + } + node.nameType = this.eatContextual(93) ? this.tsParseType() : null; + this.expect(3); + if (this.match(53)) { + node.optional = this.state.value; + this.next(); + this.expect(17); + } else if (this.eat(17)) node.optional = true; + node.typeAnnotation = this.tsTryParseType(); + this.semicolon(); + this.expect(8); + return this.finishNode(node, "TSMappedType"); + } + tsParseTupleType() { + const node = this.startNode(); + node.elementTypes = this.tsParseBracketedList("TupleElementTypes", this.tsParseTupleElementType.bind(this), true, false); + let seenOptionalElement = false; + node.elementTypes.forEach((elementNode) => { + const { type } = elementNode; + if (seenOptionalElement && type !== "TSRestType" && type !== "TSOptionalType" && !(type === "TSNamedTupleMember" && elementNode.optional)) this.raise(TSErrors.OptionalTypeBeforeRequired, elementNode); + seenOptionalElement || (seenOptionalElement = type === "TSNamedTupleMember" && elementNode.optional || type === "TSOptionalType"); + }); + return this.finishNode(node, "TSTupleType"); + } + tsParseTupleElementType() { + const restStartLoc = this.state.startLoc; + const rest$1 = this.eat(21); + const { startLoc } = this.state; + let labeled; + let label; + let optional; + let type; + const isWord = tokenIsKeywordOrIdentifier(this.state.type); + const chAfterWord = isWord ? this.lookaheadCharCode() : null; + if (chAfterWord === 58) { + labeled = true; + optional = false; + label = this.parseIdentifier(true); + this.expect(14); + type = this.tsParseType(); + } else if (chAfterWord === 63) { + optional = true; + const wordName = this.state.value; + const typeOrLabel = this.tsParseNonArrayType(); + if (this.lookaheadCharCode() === 58) { + labeled = true; + label = this.createIdentifier(this.startNodeAt(startLoc), wordName); + this.expect(17); + this.expect(14); + type = this.tsParseType(); + } else { + labeled = false; + type = typeOrLabel; + this.expect(17); + } + } else { + type = this.tsParseType(); + optional = this.eat(17); + labeled = this.eat(14); + } + if (labeled) { + let labeledNode; + if (label) { + labeledNode = this.startNodeAt(startLoc); + labeledNode.optional = optional; + labeledNode.label = label; + labeledNode.elementType = type; + if (this.eat(17)) { + labeledNode.optional = true; + this.raise(TSErrors.TupleOptionalAfterType, this.state.lastTokStartLoc); + } + } else { + labeledNode = this.startNodeAt(startLoc); + labeledNode.optional = optional; + this.raise(TSErrors.InvalidTupleMemberLabel, type); + labeledNode.label = type; + labeledNode.elementType = this.tsParseType(); + } + type = this.finishNode(labeledNode, "TSNamedTupleMember"); + } else if (optional) { + const optionalTypeNode = this.startNodeAt(startLoc); + optionalTypeNode.typeAnnotation = type; + type = this.finishNode(optionalTypeNode, "TSOptionalType"); + } + if (rest$1) { + const restNode = this.startNodeAt(restStartLoc); + restNode.typeAnnotation = type; + type = this.finishNode(restNode, "TSRestType"); + } + return type; + } + tsParseParenthesizedType() { + const node = this.startNode(); + this.expect(10); + node.typeAnnotation = this.tsParseType(); + this.expect(11); + return this.finishNode(node, "TSParenthesizedType"); + } + tsParseFunctionOrConstructorType(type, abstract) { + const node = this.startNode(); + if (type === "TSConstructorType") { + node.abstract = !!abstract; + if (abstract) this.next(); + this.next(); + } + this.tsInAllowConditionalTypesContext(() => this.tsFillSignature(19, node)); + return this.finishNode(node, type); + } + tsParseLiteralTypeNode() { + const node = this.startNode(); + switch (this.state.type) { + case 135: + case 136: + case 134: + case 85: + case 86: + node.literal = super.parseExprAtom(); + break; + default: this.unexpected(); + } + return this.finishNode(node, "TSLiteralType"); + } + tsParseTemplateLiteralType() { + { + const node = this.startNode(); + node.literal = super.parseTemplate(false); + return this.finishNode(node, "TSLiteralType"); + } + } + parseTemplateSubstitution() { + if (this.state.inType) return this.tsParseType(); + return super.parseTemplateSubstitution(); + } + tsParseThisTypeOrThisTypePredicate() { + const thisKeyword = this.tsParseThisTypeNode(); + if (this.isContextual(116) && !this.hasPrecedingLineBreak()) return this.tsParseThisTypePredicate(thisKeyword); + else return thisKeyword; + } + tsParseNonArrayType() { + switch (this.state.type) { + case 134: + case 135: + case 136: + case 85: + case 86: return this.tsParseLiteralTypeNode(); + case 53: + if (this.state.value === "-") { + const node = this.startNode(); + const nextToken = this.lookahead(); + if (nextToken.type !== 135 && nextToken.type !== 136) this.unexpected(); + node.literal = this.parseMaybeUnary(); + return this.finishNode(node, "TSLiteralType"); + } + break; + case 78: return this.tsParseThisTypeOrThisTypePredicate(); + case 87: return this.tsParseTypeQuery(); + case 83: return this.tsParseImportType(); + case 5: return this.tsLookAhead(this.tsIsStartOfMappedType.bind(this)) ? this.tsParseMappedType() : this.tsParseTypeLiteral(); + case 0: return this.tsParseTupleType(); + case 10: return this.tsParseParenthesizedType(); + case 25: + case 24: return this.tsParseTemplateLiteralType(); + default: { + const { type } = this.state; + if (tokenIsIdentifier(type) || type === 88 || type === 84) { + const nodeType = type === 88 ? "TSVoidKeyword" : type === 84 ? "TSNullKeyword" : keywordTypeFromName(this.state.value); + if (nodeType !== void 0 && this.lookaheadCharCode() !== 46) { + const node = this.startNode(); + this.next(); + return this.finishNode(node, nodeType); + } + return this.tsParseTypeReference(); + } + } + } + this.unexpected(); + } + tsParseArrayTypeOrHigher() { + const { startLoc } = this.state; + let type = this.tsParseNonArrayType(); + while (!this.hasPrecedingLineBreak() && this.eat(0)) if (this.match(3)) { + const node = this.startNodeAt(startLoc); + node.elementType = type; + this.expect(3); + type = this.finishNode(node, "TSArrayType"); + } else { + const node = this.startNodeAt(startLoc); + node.objectType = type; + node.indexType = this.tsParseType(); + this.expect(3); + type = this.finishNode(node, "TSIndexedAccessType"); + } + return type; + } + tsParseTypeOperator() { + const node = this.startNode(); + const operator$1 = this.state.value; + this.next(); + node.operator = operator$1; + node.typeAnnotation = this.tsParseTypeOperatorOrHigher(); + if (operator$1 === "readonly") this.tsCheckTypeAnnotationForReadOnly(node); + return this.finishNode(node, "TSTypeOperator"); + } + tsCheckTypeAnnotationForReadOnly(node) { + switch (node.typeAnnotation.type) { + case "TSTupleType": + case "TSArrayType": return; + default: this.raise(TSErrors.UnexpectedReadonly, node); + } + } + tsParseInferType() { + const node = this.startNode(); + this.expectContextual(115); + const typeParameter$1 = this.startNode(); + typeParameter$1.name = this.tsParseTypeParameterName(); + typeParameter$1.constraint = this.tsTryParse(() => this.tsParseConstraintForInferType()); + node.typeParameter = this.finishNode(typeParameter$1, "TSTypeParameter"); + return this.finishNode(node, "TSInferType"); + } + tsParseConstraintForInferType() { + if (this.eat(81)) { + const constraint = this.tsInDisallowConditionalTypesContext(() => this.tsParseType()); + if (this.state.inDisallowConditionalTypesContext || !this.match(17)) return constraint; + } + } + tsParseTypeOperatorOrHigher() { + const isTypeOperator = tokenIsTSTypeOperator(this.state.type) && !this.state.containsEsc; + return isTypeOperator ? this.tsParseTypeOperator() : this.isContextual(115) ? this.tsParseInferType() : this.tsInAllowConditionalTypesContext(() => this.tsParseArrayTypeOrHigher()); + } + tsParseUnionOrIntersectionType(kind, parseConstituentType, operator$1) { + const node = this.startNode(); + const hasLeadingOperator = this.eat(operator$1); + const types$7 = []; + do + types$7.push(parseConstituentType()); + while (this.eat(operator$1)); + if (types$7.length === 1 && !hasLeadingOperator) return types$7[0]; + node.types = types$7; + return this.finishNode(node, kind); + } + tsParseIntersectionTypeOrHigher() { + return this.tsParseUnionOrIntersectionType("TSIntersectionType", this.tsParseTypeOperatorOrHigher.bind(this), 45); + } + tsParseUnionTypeOrHigher() { + return this.tsParseUnionOrIntersectionType("TSUnionType", this.tsParseIntersectionTypeOrHigher.bind(this), 43); + } + tsIsStartOfFunctionType() { + if (this.match(47)) return true; + return this.match(10) && this.tsLookAhead(this.tsIsUnambiguouslyStartOfFunctionType.bind(this)); + } + tsSkipParameterStart() { + if (tokenIsIdentifier(this.state.type) || this.match(78)) { + this.next(); + return true; + } + if (this.match(5)) { + const { errors } = this.state; + const previousErrorCount = errors.length; + try { + this.parseObjectLike(8, true); + return errors.length === previousErrorCount; + } catch (_unused) { + return false; + } + } + if (this.match(0)) { + this.next(); + const { errors } = this.state; + const previousErrorCount = errors.length; + try { + super.parseBindingList(3, 93, 1); + return errors.length === previousErrorCount; + } catch (_unused2) { + return false; + } + } + return false; + } + tsIsUnambiguouslyStartOfFunctionType() { + this.next(); + if (this.match(11) || this.match(21)) return true; + if (this.tsSkipParameterStart()) { + if (this.match(14) || this.match(12) || this.match(17) || this.match(29)) return true; + if (this.match(11)) { + this.next(); + if (this.match(19)) return true; + } + } + return false; + } + tsParseTypeOrTypePredicateAnnotation(returnToken) { + return this.tsInType(() => { + const t$7 = this.startNode(); + this.expect(returnToken); + const node = this.startNode(); + const asserts = !!this.tsTryParse(this.tsParseTypePredicateAsserts.bind(this)); + if (asserts && this.match(78)) { + let thisTypePredicate = this.tsParseThisTypeOrThisTypePredicate(); + if (thisTypePredicate.type === "TSThisType") { + node.parameterName = thisTypePredicate; + node.asserts = true; + node.typeAnnotation = null; + thisTypePredicate = this.finishNode(node, "TSTypePredicate"); + } else { + this.resetStartLocationFromNode(thisTypePredicate, node); + thisTypePredicate.asserts = true; + } + t$7.typeAnnotation = thisTypePredicate; + return this.finishNode(t$7, "TSTypeAnnotation"); + } + const typePredicateVariable = this.tsIsIdentifier() && this.tsTryParse(this.tsParseTypePredicatePrefix.bind(this)); + if (!typePredicateVariable) { + if (!asserts) return this.tsParseTypeAnnotation(false, t$7); + node.parameterName = this.parseIdentifier(); + node.asserts = asserts; + node.typeAnnotation = null; + t$7.typeAnnotation = this.finishNode(node, "TSTypePredicate"); + return this.finishNode(t$7, "TSTypeAnnotation"); + } + const type = this.tsParseTypeAnnotation(false); + node.parameterName = typePredicateVariable; + node.typeAnnotation = type; + node.asserts = asserts; + t$7.typeAnnotation = this.finishNode(node, "TSTypePredicate"); + return this.finishNode(t$7, "TSTypeAnnotation"); + }); + } + tsTryParseTypeOrTypePredicateAnnotation() { + if (this.match(14)) return this.tsParseTypeOrTypePredicateAnnotation(14); + } + tsTryParseTypeAnnotation() { + if (this.match(14)) return this.tsParseTypeAnnotation(); + } + tsTryParseType() { + return this.tsEatThenParseType(14); + } + tsParseTypePredicatePrefix() { + const id$4 = this.parseIdentifier(); + if (this.isContextual(116) && !this.hasPrecedingLineBreak()) { + this.next(); + return id$4; + } + } + tsParseTypePredicateAsserts() { + if (this.state.type !== 109) return false; + const containsEsc = this.state.containsEsc; + this.next(); + if (!tokenIsIdentifier(this.state.type) && !this.match(78)) return false; + if (containsEsc) this.raise(Errors.InvalidEscapedReservedWord, this.state.lastTokStartLoc, { reservedWord: "asserts" }); + return true; + } + tsParseTypeAnnotation(eatColon = true, t$7 = this.startNode()) { + this.tsInType(() => { + if (eatColon) this.expect(14); + t$7.typeAnnotation = this.tsParseType(); + }); + return this.finishNode(t$7, "TSTypeAnnotation"); + } + tsParseType() { + assert$3(this.state.inType); + const type = this.tsParseNonConditionalType(); + if (this.state.inDisallowConditionalTypesContext || this.hasPrecedingLineBreak() || !this.eat(81)) return type; + const node = this.startNodeAtNode(type); + node.checkType = type; + node.extendsType = this.tsInDisallowConditionalTypesContext(() => this.tsParseNonConditionalType()); + this.expect(17); + node.trueType = this.tsInAllowConditionalTypesContext(() => this.tsParseType()); + this.expect(14); + node.falseType = this.tsInAllowConditionalTypesContext(() => this.tsParseType()); + return this.finishNode(node, "TSConditionalType"); + } + isAbstractConstructorSignature() { + return this.isContextual(124) && this.lookahead().type === 77; + } + tsParseNonConditionalType() { + if (this.tsIsStartOfFunctionType()) return this.tsParseFunctionOrConstructorType("TSFunctionType"); + if (this.match(77)) return this.tsParseFunctionOrConstructorType("TSConstructorType"); + else if (this.isAbstractConstructorSignature()) return this.tsParseFunctionOrConstructorType("TSConstructorType", true); + return this.tsParseUnionTypeOrHigher(); + } + tsParseTypeAssertion() { + if (this.getPluginOption("typescript", "disallowAmbiguousJSXLike")) this.raise(TSErrors.ReservedTypeAssertion, this.state.startLoc); + const node = this.startNode(); + node.typeAnnotation = this.tsInType(() => { + this.next(); + return this.match(75) ? this.tsParseTypeReference() : this.tsParseType(); + }); + this.expect(48); + node.expression = this.parseMaybeUnary(); + return this.finishNode(node, "TSTypeAssertion"); + } + tsParseHeritageClause(token$1) { + const originalStartLoc = this.state.startLoc; + const delimitedList = this.tsParseDelimitedList("HeritageClauseElement", () => { + { + const node = this.startNode(); + node.expression = this.tsParseEntityName(3); + if (this.match(47)) node.typeParameters = this.tsParseTypeArguments(); + return this.finishNode(node, "TSExpressionWithTypeArguments"); + } + }); + if (!delimitedList.length) this.raise(TSErrors.EmptyHeritageClauseType, originalStartLoc, { token: token$1 }); + return delimitedList; + } + tsParseInterfaceDeclaration(node, properties = {}) { + if (this.hasFollowingLineBreak()) return null; + this.expectContextual(129); + if (properties.declare) node.declare = true; + if (tokenIsIdentifier(this.state.type)) { + node.id = this.parseIdentifier(); + this.checkIdentifier(node.id, 130); + } else { + node.id = null; + this.raise(TSErrors.MissingInterfaceName, this.state.startLoc); + } + node.typeParameters = this.tsTryParseTypeParameters(this.tsParseInOutConstModifiers); + if (this.eat(81)) node.extends = this.tsParseHeritageClause("extends"); + const body = this.startNode(); + body.body = this.tsInType(this.tsParseObjectTypeMembers.bind(this)); + node.body = this.finishNode(body, "TSInterfaceBody"); + return this.finishNode(node, "TSInterfaceDeclaration"); + } + tsParseTypeAliasDeclaration(node) { + node.id = this.parseIdentifier(); + this.checkIdentifier(node.id, 2); + node.typeAnnotation = this.tsInType(() => { + node.typeParameters = this.tsTryParseTypeParameters(this.tsParseInOutModifiers); + this.expect(29); + if (this.isContextual(114) && this.lookahead().type !== 16) { + const node$1 = this.startNode(); + this.next(); + return this.finishNode(node$1, "TSIntrinsicKeyword"); + } + return this.tsParseType(); + }); + this.semicolon(); + return this.finishNode(node, "TSTypeAliasDeclaration"); + } + tsInTopLevelContext(cb$1) { + if (this.curContext() !== types$4.brace) { + const oldContext = this.state.context; + this.state.context = [oldContext[0]]; + try { + return cb$1(); + } finally { + this.state.context = oldContext; + } + } else return cb$1(); + } + tsInType(cb$1) { + const oldInType = this.state.inType; + this.state.inType = true; + try { + return cb$1(); + } finally { + this.state.inType = oldInType; + } + } + tsInDisallowConditionalTypesContext(cb$1) { + const oldInDisallowConditionalTypesContext = this.state.inDisallowConditionalTypesContext; + this.state.inDisallowConditionalTypesContext = true; + try { + return cb$1(); + } finally { + this.state.inDisallowConditionalTypesContext = oldInDisallowConditionalTypesContext; + } + } + tsInAllowConditionalTypesContext(cb$1) { + const oldInDisallowConditionalTypesContext = this.state.inDisallowConditionalTypesContext; + this.state.inDisallowConditionalTypesContext = false; + try { + return cb$1(); + } finally { + this.state.inDisallowConditionalTypesContext = oldInDisallowConditionalTypesContext; + } + } + tsEatThenParseType(token$1) { + if (this.match(token$1)) return this.tsNextThenParseType(); + } + tsExpectThenParseType(token$1) { + return this.tsInType(() => { + this.expect(token$1); + return this.tsParseType(); + }); + } + tsNextThenParseType() { + return this.tsInType(() => { + this.next(); + return this.tsParseType(); + }); + } + tsParseEnumMember() { + const node = this.startNode(); + node.id = this.match(134) ? super.parseStringLiteral(this.state.value) : this.parseIdentifier(true); + if (this.eat(29)) node.initializer = super.parseMaybeAssignAllowIn(); + return this.finishNode(node, "TSEnumMember"); + } + tsParseEnumDeclaration(node, properties = {}) { + if (properties.const) node.const = true; + if (properties.declare) node.declare = true; + this.expectContextual(126); + node.id = this.parseIdentifier(); + this.checkIdentifier(node.id, node.const ? 8971 : 8459); + { + this.expect(5); + node.members = this.tsParseDelimitedList("EnumMembers", this.tsParseEnumMember.bind(this)); + this.expect(8); + } + return this.finishNode(node, "TSEnumDeclaration"); + } + tsParseEnumBody() { + const node = this.startNode(); + this.expect(5); + node.members = this.tsParseDelimitedList("EnumMembers", this.tsParseEnumMember.bind(this)); + this.expect(8); + return this.finishNode(node, "TSEnumBody"); + } + tsParseModuleBlock() { + const node = this.startNode(); + this.scope.enter(0); + this.expect(5); + super.parseBlockOrModuleBlockBody(node.body = [], void 0, true, 8); + this.scope.exit(); + return this.finishNode(node, "TSModuleBlock"); + } + tsParseModuleOrNamespaceDeclaration(node, nested = false) { + node.id = this.parseIdentifier(); + if (!nested) this.checkIdentifier(node.id, 1024); + if (this.eat(16)) { + const inner = this.startNode(); + this.tsParseModuleOrNamespaceDeclaration(inner, true); + node.body = inner; + } else { + this.scope.enter(256); + this.prodParam.enter(0); + node.body = this.tsParseModuleBlock(); + this.prodParam.exit(); + this.scope.exit(); + } + return this.finishNode(node, "TSModuleDeclaration"); + } + tsParseAmbientExternalModuleDeclaration(node) { + if (this.isContextual(112)) { + node.kind = "global"; + node.global = true; + node.id = this.parseIdentifier(); + } else if (this.match(134)) { + node.kind = "module"; + node.id = super.parseStringLiteral(this.state.value); + } else this.unexpected(); + if (this.match(5)) { + this.scope.enter(256); + this.prodParam.enter(0); + node.body = this.tsParseModuleBlock(); + this.prodParam.exit(); + this.scope.exit(); + } else this.semicolon(); + return this.finishNode(node, "TSModuleDeclaration"); + } + tsParseImportEqualsDeclaration(node, maybeDefaultIdentifier, isExport) { + node.isExport = isExport || false; + node.id = maybeDefaultIdentifier || this.parseIdentifier(); + this.checkIdentifier(node.id, 4096); + this.expect(29); + const moduleReference = this.tsParseModuleReference(); + if (node.importKind === "type" && moduleReference.type !== "TSExternalModuleReference") this.raise(TSErrors.ImportAliasHasImportType, moduleReference); + node.moduleReference = moduleReference; + this.semicolon(); + return this.finishNode(node, "TSImportEqualsDeclaration"); + } + tsIsExternalModuleReference() { + return this.isContextual(119) && this.lookaheadCharCode() === 40; + } + tsParseModuleReference() { + return this.tsIsExternalModuleReference() ? this.tsParseExternalModuleReference() : this.tsParseEntityName(0); + } + tsParseExternalModuleReference() { + const node = this.startNode(); + this.expectContextual(119); + this.expect(10); + if (!this.match(134)) this.unexpected(); + node.expression = super.parseExprAtom(); + this.expect(11); + this.sawUnambiguousESM = true; + return this.finishNode(node, "TSExternalModuleReference"); + } + tsLookAhead(f$1) { + const state = this.state.clone(); + const res = f$1(); + this.state = state; + return res; + } + tsTryParseAndCatch(f$1) { + const result$1 = this.tryParse((abort) => f$1() || abort()); + if (result$1.aborted || !result$1.node) return; + if (result$1.error) this.state = result$1.failState; + return result$1.node; + } + tsTryParse(f$1) { + const state = this.state.clone(); + const result$1 = f$1(); + if (result$1 !== void 0 && result$1 !== false) return result$1; + this.state = state; + } + tsTryParseDeclare(nany) { + if (this.isLineTerminator()) return; + let startType = this.state.type; + let kind; + if (this.isContextual(100)) { + startType = 74; + kind = "let"; + } + return this.tsInAmbientContext(() => { + switch (startType) { + case 68: + nany.declare = true; + return super.parseFunctionStatement(nany, false, false); + case 80: + nany.declare = true; + return this.parseClass(nany, true, false); + case 126: return this.tsParseEnumDeclaration(nany, { declare: true }); + case 112: return this.tsParseAmbientExternalModuleDeclaration(nany); + case 75: + case 74: + if (!this.match(75) || !this.isLookaheadContextual("enum")) { + nany.declare = true; + return this.parseVarStatement(nany, kind || this.state.value, true); + } + this.expect(75); + return this.tsParseEnumDeclaration(nany, { + const: true, + declare: true + }); + case 129: { + const result$1 = this.tsParseInterfaceDeclaration(nany, { declare: true }); + if (result$1) return result$1; + } + default: if (tokenIsIdentifier(startType)) return this.tsParseDeclaration(nany, this.state.value, true, null); + } + }); + } + tsTryParseExportDeclaration() { + return this.tsParseDeclaration(this.startNode(), this.state.value, true, null); + } + tsParseExpressionStatement(node, expr, decorators) { + switch (expr.name) { + case "declare": { + const declaration = this.tsTryParseDeclare(node); + if (declaration) declaration.declare = true; + return declaration; + } + case "global": + if (this.match(5)) { + this.scope.enter(256); + this.prodParam.enter(0); + const mod$1 = node; + mod$1.kind = "global"; + node.global = true; + mod$1.id = expr; + mod$1.body = this.tsParseModuleBlock(); + this.scope.exit(); + this.prodParam.exit(); + return this.finishNode(mod$1, "TSModuleDeclaration"); + } + break; + default: return this.tsParseDeclaration(node, expr.name, false, decorators); + } + } + tsParseDeclaration(node, value, next, decorators) { + switch (value) { + case "abstract": + if (this.tsCheckLineTerminator(next) && (this.match(80) || tokenIsIdentifier(this.state.type))) return this.tsParseAbstractDeclaration(node, decorators); + break; + case "module": + if (this.tsCheckLineTerminator(next)) { + if (this.match(134)) return this.tsParseAmbientExternalModuleDeclaration(node); + else if (tokenIsIdentifier(this.state.type)) { + node.kind = "module"; + return this.tsParseModuleOrNamespaceDeclaration(node); + } + } + break; + case "namespace": + if (this.tsCheckLineTerminator(next) && tokenIsIdentifier(this.state.type)) { + node.kind = "namespace"; + return this.tsParseModuleOrNamespaceDeclaration(node); + } + break; + case "type": + if (this.tsCheckLineTerminator(next) && tokenIsIdentifier(this.state.type)) return this.tsParseTypeAliasDeclaration(node); + break; + } + } + tsCheckLineTerminator(next) { + if (next) { + if (this.hasFollowingLineBreak()) return false; + this.next(); + return true; + } + return !this.isLineTerminator(); + } + tsTryParseGenericAsyncArrowFunction(startLoc) { + if (!this.match(47)) return; + const oldMaybeInArrowParameters = this.state.maybeInArrowParameters; + this.state.maybeInArrowParameters = true; + const res = this.tsTryParseAndCatch(() => { + const node = this.startNodeAt(startLoc); + node.typeParameters = this.tsParseTypeParameters(this.tsParseConstModifier); + super.parseFunctionParams(node); + node.returnType = this.tsTryParseTypeOrTypePredicateAnnotation(); + this.expect(19); + return node; + }); + this.state.maybeInArrowParameters = oldMaybeInArrowParameters; + if (!res) return; + return super.parseArrowExpression(res, null, true); + } + tsParseTypeArgumentsInExpression() { + if (this.reScan_lt() !== 47) return; + return this.tsParseTypeArguments(); + } + tsParseTypeArguments() { + const node = this.startNode(); + node.params = this.tsInType(() => this.tsInTopLevelContext(() => { + this.expect(47); + return this.tsParseDelimitedList("TypeParametersOrArguments", this.tsParseType.bind(this)); + })); + if (node.params.length === 0) this.raise(TSErrors.EmptyTypeArguments, node); + else if (!this.state.inType && this.curContext() === types$4.brace) this.reScan_lt_gt(); + this.expect(48); + return this.finishNode(node, "TSTypeParameterInstantiation"); + } + tsIsDeclarationStart() { + return tokenIsTSDeclarationStart(this.state.type); + } + isExportDefaultSpecifier() { + if (this.tsIsDeclarationStart()) return false; + return super.isExportDefaultSpecifier(); + } + parseBindingElement(flags, decorators) { + const startLoc = this.state.startLoc; + const modified = {}; + this.tsParseModifiers({ allowedModifiers: [ + "public", + "private", + "protected", + "override", + "readonly" + ] }, modified); + const accessibility = modified.accessibility; + const override = modified.override; + const readonly = modified.readonly; + if (!(flags & 4) && (accessibility || readonly || override)) this.raise(TSErrors.UnexpectedParameterModifier, startLoc); + const left = this.parseMaybeDefault(); + if (flags & 2) this.parseFunctionParamType(left); + const elt = this.parseMaybeDefault(left.loc.start, left); + if (accessibility || readonly || override) { + const pp = this.startNodeAt(startLoc); + if (decorators.length) pp.decorators = decorators; + if (accessibility) pp.accessibility = accessibility; + if (readonly) pp.readonly = readonly; + if (override) pp.override = override; + if (elt.type !== "Identifier" && elt.type !== "AssignmentPattern") this.raise(TSErrors.UnsupportedParameterPropertyKind, pp); + pp.parameter = elt; + return this.finishNode(pp, "TSParameterProperty"); + } + if (decorators.length) left.decorators = decorators; + return elt; + } + isSimpleParameter(node) { + return node.type === "TSParameterProperty" && super.isSimpleParameter(node.parameter) || super.isSimpleParameter(node); + } + tsDisallowOptionalPattern(node) { + for (const param of node.params) if (param.type !== "Identifier" && param.optional && !this.state.isAmbientContext) this.raise(TSErrors.PatternIsOptional, param); + } + setArrowFunctionParameters(node, params, trailingCommaLoc) { + super.setArrowFunctionParameters(node, params, trailingCommaLoc); + this.tsDisallowOptionalPattern(node); + } + parseFunctionBodyAndFinish(node, type, isMethod$2 = false) { + if (this.match(14)) node.returnType = this.tsParseTypeOrTypePredicateAnnotation(14); + const bodilessType = type === "FunctionDeclaration" ? "TSDeclareFunction" : type === "ClassMethod" || type === "ClassPrivateMethod" ? "TSDeclareMethod" : void 0; + if (bodilessType && !this.match(5) && this.isLineTerminator()) return this.finishNode(node, bodilessType); + if (bodilessType === "TSDeclareFunction" && this.state.isAmbientContext) { + this.raise(TSErrors.DeclareFunctionHasImplementation, node); + if (node.declare) return super.parseFunctionBodyAndFinish(node, bodilessType, isMethod$2); + } + this.tsDisallowOptionalPattern(node); + return super.parseFunctionBodyAndFinish(node, type, isMethod$2); + } + registerFunctionStatementId(node) { + if (!node.body && node.id) this.checkIdentifier(node.id, 1024); + else super.registerFunctionStatementId(node); + } + tsCheckForInvalidTypeCasts(items) { + items.forEach((node) => { + if ((node == null ? void 0 : node.type) === "TSTypeCastExpression") this.raise(TSErrors.UnexpectedTypeAnnotation, node.typeAnnotation); + }); + } + toReferencedList(exprList, isInParens) { + this.tsCheckForInvalidTypeCasts(exprList); + return exprList; + } + parseArrayLike(close, canBePattern, isTuple, refExpressionErrors) { + const node = super.parseArrayLike(close, canBePattern, isTuple, refExpressionErrors); + if (node.type === "ArrayExpression") this.tsCheckForInvalidTypeCasts(node.elements); + return node; + } + parseSubscript(base$1, startLoc, noCalls, state) { + if (!this.hasPrecedingLineBreak() && this.match(35)) { + this.state.canStartJSXElement = false; + this.next(); + const nonNullExpression = this.startNodeAt(startLoc); + nonNullExpression.expression = base$1; + return this.finishNode(nonNullExpression, "TSNonNullExpression"); + } + let isOptionalCall = false; + if (this.match(18) && this.lookaheadCharCode() === 60) { + if (noCalls) { + state.stop = true; + return base$1; + } + state.optionalChainMember = isOptionalCall = true; + this.next(); + } + if (this.match(47) || this.match(51)) { + let missingParenErrorLoc; + const result$1 = this.tsTryParseAndCatch(() => { + if (!noCalls && this.atPossibleAsyncArrow(base$1)) { + const asyncArrowFn = this.tsTryParseGenericAsyncArrowFunction(startLoc); + if (asyncArrowFn) return asyncArrowFn; + } + const typeArguments = this.tsParseTypeArgumentsInExpression(); + if (!typeArguments) return; + if (isOptionalCall && !this.match(10)) { + missingParenErrorLoc = this.state.curPosition(); + return; + } + if (tokenIsTemplate(this.state.type)) { + const result$2 = super.parseTaggedTemplateExpression(base$1, startLoc, state); + result$2.typeParameters = typeArguments; + return result$2; + } + if (!noCalls && this.eat(10)) { + const node$1 = this.startNodeAt(startLoc); + node$1.callee = base$1; + node$1.arguments = this.parseCallExpressionArguments(11); + this.tsCheckForInvalidTypeCasts(node$1.arguments); + node$1.typeParameters = typeArguments; + if (state.optionalChainMember) node$1.optional = isOptionalCall; + return this.finishCallExpression(node$1, state.optionalChainMember); + } + const tokenType = this.state.type; + if (tokenType === 48 || tokenType === 52 || tokenType !== 10 && tokenCanStartExpression(tokenType) && !this.hasPrecedingLineBreak()) return; + const node = this.startNodeAt(startLoc); + node.expression = base$1; + node.typeParameters = typeArguments; + return this.finishNode(node, "TSInstantiationExpression"); + }); + if (missingParenErrorLoc) this.unexpected(missingParenErrorLoc, 10); + if (result$1) { + if (result$1.type === "TSInstantiationExpression" && (this.match(16) || this.match(18) && this.lookaheadCharCode() !== 40)) this.raise(TSErrors.InvalidPropertyAccessAfterInstantiationExpression, this.state.startLoc); + return result$1; + } + } + return super.parseSubscript(base$1, startLoc, noCalls, state); + } + parseNewCallee(node) { + var _callee$extra; + super.parseNewCallee(node); + const { callee } = node; + if (callee.type === "TSInstantiationExpression" && !((_callee$extra = callee.extra) != null && _callee$extra.parenthesized)) { + node.typeParameters = callee.typeParameters; + node.callee = callee.expression; + } + } + parseExprOp(left, leftStartLoc, minPrec) { + let isSatisfies; + if (tokenOperatorPrecedence(58) > minPrec && !this.hasPrecedingLineBreak() && (this.isContextual(93) || (isSatisfies = this.isContextual(120)))) { + const node = this.startNodeAt(leftStartLoc); + node.expression = left; + node.typeAnnotation = this.tsInType(() => { + this.next(); + if (this.match(75)) { + if (isSatisfies) this.raise(Errors.UnexpectedKeyword, this.state.startLoc, { keyword: "const" }); + return this.tsParseTypeReference(); + } + return this.tsParseType(); + }); + this.finishNode(node, isSatisfies ? "TSSatisfiesExpression" : "TSAsExpression"); + this.reScan_lt_gt(); + return this.parseExprOp(node, leftStartLoc, minPrec); + } + return super.parseExprOp(left, leftStartLoc, minPrec); + } + checkReservedWord(word$3, startLoc, checkKeywords, isBinding$2) { + if (!this.state.isAmbientContext) super.checkReservedWord(word$3, startLoc, checkKeywords, isBinding$2); + } + checkImportReflection(node) { + super.checkImportReflection(node); + if (node.module && node.importKind !== "value") this.raise(TSErrors.ImportReflectionHasImportType, node.specifiers[0].loc.start); + } + checkDuplicateExports() {} + isPotentialImportPhase(isExport) { + if (super.isPotentialImportPhase(isExport)) return true; + if (this.isContextual(130)) { + const ch = this.lookaheadCharCode(); + return isExport ? ch === 123 || ch === 42 : ch !== 61; + } + return !isExport && this.isContextual(87); + } + applyImportPhase(node, isExport, phase, loc) { + super.applyImportPhase(node, isExport, phase, loc); + if (isExport) node.exportKind = phase === "type" ? "type" : "value"; + else node.importKind = phase === "type" || phase === "typeof" ? phase : "value"; + } + parseImport(node) { + if (this.match(134)) { + node.importKind = "value"; + return super.parseImport(node); + } + let importNode; + if (tokenIsIdentifier(this.state.type) && this.lookaheadCharCode() === 61) { + node.importKind = "value"; + return this.tsParseImportEqualsDeclaration(node); + } else if (this.isContextual(130)) { + const maybeDefaultIdentifier = this.parseMaybeImportPhase(node, false); + if (this.lookaheadCharCode() === 61) return this.tsParseImportEqualsDeclaration(node, maybeDefaultIdentifier); + else importNode = super.parseImportSpecifiersAndAfter(node, maybeDefaultIdentifier); + } else importNode = super.parseImport(node); + if (importNode.importKind === "type" && importNode.specifiers.length > 1 && importNode.specifiers[0].type === "ImportDefaultSpecifier") this.raise(TSErrors.TypeImportCannotSpecifyDefaultAndNamed, importNode); + return importNode; + } + parseExport(node, decorators) { + if (this.match(83)) { + const nodeImportEquals = node; + this.next(); + let maybeDefaultIdentifier = null; + if (this.isContextual(130) && this.isPotentialImportPhase(false)) maybeDefaultIdentifier = this.parseMaybeImportPhase(nodeImportEquals, false); + else nodeImportEquals.importKind = "value"; + const declaration = this.tsParseImportEqualsDeclaration(nodeImportEquals, maybeDefaultIdentifier, true); + return declaration; + } else if (this.eat(29)) { + const assign = node; + assign.expression = super.parseExpression(); + this.semicolon(); + this.sawUnambiguousESM = true; + return this.finishNode(assign, "TSExportAssignment"); + } else if (this.eatContextual(93)) { + const decl$1 = node; + this.expectContextual(128); + decl$1.id = this.parseIdentifier(); + this.semicolon(); + return this.finishNode(decl$1, "TSNamespaceExportDeclaration"); + } else return super.parseExport(node, decorators); + } + isAbstractClass() { + return this.isContextual(124) && this.lookahead().type === 80; + } + parseExportDefaultExpression() { + if (this.isAbstractClass()) { + const cls = this.startNode(); + this.next(); + cls.abstract = true; + return this.parseClass(cls, true, true); + } + if (this.match(129)) { + const result$1 = this.tsParseInterfaceDeclaration(this.startNode()); + if (result$1) return result$1; + } + return super.parseExportDefaultExpression(); + } + parseVarStatement(node, kind, allowMissingInitializer = false) { + const { isAmbientContext } = this.state; + const declaration = super.parseVarStatement(node, kind, allowMissingInitializer || isAmbientContext); + if (!isAmbientContext) return declaration; + for (const { id: id$4, init } of declaration.declarations) { + if (!init) continue; + if (kind !== "const" || !!id$4.typeAnnotation) this.raise(TSErrors.InitializerNotAllowedInAmbientContext, init); + else if (!isValidAmbientConstInitializer(init, this.hasPlugin("estree"))) this.raise(TSErrors.ConstInitializerMustBeStringOrNumericLiteralOrLiteralEnumReference, init); + } + return declaration; + } + parseStatementContent(flags, decorators) { + if (this.match(75) && this.isLookaheadContextual("enum")) { + const node = this.startNode(); + this.expect(75); + return this.tsParseEnumDeclaration(node, { const: true }); + } + if (this.isContextual(126)) return this.tsParseEnumDeclaration(this.startNode()); + if (this.isContextual(129)) { + const result$1 = this.tsParseInterfaceDeclaration(this.startNode()); + if (result$1) return result$1; + } + return super.parseStatementContent(flags, decorators); + } + parseAccessModifier() { + return this.tsParseModifier([ + "public", + "protected", + "private" + ]); + } + tsHasSomeModifiers(member, modifiers) { + return modifiers.some((modifier) => { + if (tsIsAccessModifier(modifier)) return member.accessibility === modifier; + return !!member[modifier]; + }); + } + tsIsStartOfStaticBlocks() { + return this.isContextual(106) && this.lookaheadCharCode() === 123; + } + parseClassMember(classBody$1, member, state) { + const modifiers = [ + "declare", + "private", + "public", + "protected", + "override", + "abstract", + "readonly", + "static" + ]; + this.tsParseModifiers({ + allowedModifiers: modifiers, + disallowedModifiers: ["in", "out"], + stopOnStartOfClassStaticBlock: true, + errorTemplate: TSErrors.InvalidModifierOnTypeParameterPositions + }, member); + const callParseClassMemberWithIsStatic = () => { + if (this.tsIsStartOfStaticBlocks()) { + this.next(); + this.next(); + if (this.tsHasSomeModifiers(member, modifiers)) this.raise(TSErrors.StaticBlockCannotHaveModifier, this.state.curPosition()); + super.parseClassStaticBlock(classBody$1, member); + } else this.parseClassMemberWithIsStatic(classBody$1, member, state, !!member.static); + }; + if (member.declare) this.tsInAmbientContext(callParseClassMemberWithIsStatic); + else callParseClassMemberWithIsStatic(); + } + parseClassMemberWithIsStatic(classBody$1, member, state, isStatic$1) { + const idx = this.tsTryParseIndexSignature(member); + if (idx) { + classBody$1.body.push(idx); + if (member.abstract) this.raise(TSErrors.IndexSignatureHasAbstract, member); + if (member.accessibility) this.raise(TSErrors.IndexSignatureHasAccessibility, member, { modifier: member.accessibility }); + if (member.declare) this.raise(TSErrors.IndexSignatureHasDeclare, member); + if (member.override) this.raise(TSErrors.IndexSignatureHasOverride, member); + return; + } + if (!this.state.inAbstractClass && member.abstract) this.raise(TSErrors.NonAbstractClassHasAbstractMethod, member); + if (member.override) { + if (!state.hadSuperClass) this.raise(TSErrors.OverrideNotInSubClass, member); + } + super.parseClassMemberWithIsStatic(classBody$1, member, state, isStatic$1); + } + parsePostMemberNameModifiers(methodOrProp) { + const optional = this.eat(17); + if (optional) methodOrProp.optional = true; + if (methodOrProp.readonly && this.match(10)) this.raise(TSErrors.ClassMethodHasReadonly, methodOrProp); + if (methodOrProp.declare && this.match(10)) this.raise(TSErrors.ClassMethodHasDeclare, methodOrProp); + } + parseExpressionStatement(node, expr, decorators) { + const decl$1 = expr.type === "Identifier" ? this.tsParseExpressionStatement(node, expr, decorators) : void 0; + return decl$1 || super.parseExpressionStatement(node, expr, decorators); + } + shouldParseExportDeclaration() { + if (this.tsIsDeclarationStart()) return true; + return super.shouldParseExportDeclaration(); + } + parseConditional(expr, startLoc, refExpressionErrors) { + if (!this.match(17)) return expr; + if (this.state.maybeInArrowParameters) { + const nextCh = this.lookaheadCharCode(); + if (nextCh === 44 || nextCh === 61 || nextCh === 58 || nextCh === 41) { + this.setOptionalParametersError(refExpressionErrors); + return expr; + } + } + return super.parseConditional(expr, startLoc, refExpressionErrors); + } + parseParenItem(node, startLoc) { + const newNode = super.parseParenItem(node, startLoc); + if (this.eat(17)) { + newNode.optional = true; + this.resetEndLocation(node); + } + if (this.match(14)) { + const typeCastNode = this.startNodeAt(startLoc); + typeCastNode.expression = node; + typeCastNode.typeAnnotation = this.tsParseTypeAnnotation(); + return this.finishNode(typeCastNode, "TSTypeCastExpression"); + } + return node; + } + parseExportDeclaration(node) { + if (!this.state.isAmbientContext && this.isContextual(125)) return this.tsInAmbientContext(() => this.parseExportDeclaration(node)); + const startLoc = this.state.startLoc; + const isDeclare = this.eatContextual(125); + if (isDeclare && (this.isContextual(125) || !this.shouldParseExportDeclaration())) throw this.raise(TSErrors.ExpectedAmbientAfterExportDeclare, this.state.startLoc); + const isIdentifier$15 = tokenIsIdentifier(this.state.type); + const declaration = isIdentifier$15 && this.tsTryParseExportDeclaration() || super.parseExportDeclaration(node); + if (!declaration) return null; + if (declaration.type === "TSInterfaceDeclaration" || declaration.type === "TSTypeAliasDeclaration" || isDeclare) node.exportKind = "type"; + if (isDeclare && declaration.type !== "TSImportEqualsDeclaration") { + this.resetStartLocation(declaration, startLoc); + declaration.declare = true; + } + return declaration; + } + parseClassId(node, isStatement$10, optionalId, bindingType) { + if ((!isStatement$10 || optionalId) && this.isContextual(113)) return; + super.parseClassId(node, isStatement$10, optionalId, node.declare ? 1024 : 8331); + const typeParameters = this.tsTryParseTypeParameters(this.tsParseInOutConstModifiers); + if (typeParameters) node.typeParameters = typeParameters; + } + parseClassPropertyAnnotation(node) { + if (!node.optional) { + if (this.eat(35)) node.definite = true; + else if (this.eat(17)) node.optional = true; + } + const type = this.tsTryParseTypeAnnotation(); + if (type) node.typeAnnotation = type; + } + parseClassProperty(node) { + this.parseClassPropertyAnnotation(node); + if (this.state.isAmbientContext && !(node.readonly && !node.typeAnnotation) && this.match(29)) this.raise(TSErrors.DeclareClassFieldHasInitializer, this.state.startLoc); + if (node.abstract && this.match(29)) { + const { key } = node; + this.raise(TSErrors.AbstractPropertyHasInitializer, this.state.startLoc, { propertyName: key.type === "Identifier" && !node.computed ? key.name : `[${this.input.slice(this.offsetToSourcePos(key.start), this.offsetToSourcePos(key.end))}]` }); + } + return super.parseClassProperty(node); + } + parseClassPrivateProperty(node) { + if (node.abstract) this.raise(TSErrors.PrivateElementHasAbstract, node); + if (node.accessibility) this.raise(TSErrors.PrivateElementHasAccessibility, node, { modifier: node.accessibility }); + this.parseClassPropertyAnnotation(node); + return super.parseClassPrivateProperty(node); + } + parseClassAccessorProperty(node) { + this.parseClassPropertyAnnotation(node); + if (node.optional) this.raise(TSErrors.AccessorCannotBeOptional, node); + return super.parseClassAccessorProperty(node); + } + pushClassMethod(classBody$1, method, isGenerator, isAsync, isConstructor, allowsDirectSuper) { + const typeParameters = this.tsTryParseTypeParameters(this.tsParseConstModifier); + if (typeParameters && isConstructor) this.raise(TSErrors.ConstructorHasTypeParameters, typeParameters); + const { declare = false, kind } = method; + if (declare && (kind === "get" || kind === "set")) this.raise(TSErrors.DeclareAccessor, method, { kind }); + if (typeParameters) method.typeParameters = typeParameters; + super.pushClassMethod(classBody$1, method, isGenerator, isAsync, isConstructor, allowsDirectSuper); + } + pushClassPrivateMethod(classBody$1, method, isGenerator, isAsync) { + const typeParameters = this.tsTryParseTypeParameters(this.tsParseConstModifier); + if (typeParameters) method.typeParameters = typeParameters; + super.pushClassPrivateMethod(classBody$1, method, isGenerator, isAsync); + } + declareClassPrivateMethodInScope(node, kind) { + if (node.type === "TSDeclareMethod") return; + if (node.type === "MethodDefinition" && !hasOwnProperty.call(node.value, "body")) return; + super.declareClassPrivateMethodInScope(node, kind); + } + parseClassSuper(node) { + super.parseClassSuper(node); + if (node.superClass && (this.match(47) || this.match(51))) node.superTypeParameters = this.tsParseTypeArgumentsInExpression(); + if (this.eatContextual(113)) node.implements = this.tsParseHeritageClause("implements"); + } + parseObjPropValue(prop, startLoc, isGenerator, isAsync, isPattern$2, isAccessor$1, refExpressionErrors) { + const typeParameters = this.tsTryParseTypeParameters(this.tsParseConstModifier); + if (typeParameters) prop.typeParameters = typeParameters; + return super.parseObjPropValue(prop, startLoc, isGenerator, isAsync, isPattern$2, isAccessor$1, refExpressionErrors); + } + parseFunctionParams(node, isConstructor) { + const typeParameters = this.tsTryParseTypeParameters(this.tsParseConstModifier); + if (typeParameters) node.typeParameters = typeParameters; + super.parseFunctionParams(node, isConstructor); + } + parseVarId(decl$1, kind) { + super.parseVarId(decl$1, kind); + if (decl$1.id.type === "Identifier" && !this.hasPrecedingLineBreak() && this.eat(35)) decl$1.definite = true; + const type = this.tsTryParseTypeAnnotation(); + if (type) { + decl$1.id.typeAnnotation = type; + this.resetEndLocation(decl$1.id); + } + } + parseAsyncArrowFromCallExpression(node, call$2) { + if (this.match(14)) node.returnType = this.tsParseTypeAnnotation(); + return super.parseAsyncArrowFromCallExpression(node, call$2); + } + parseMaybeAssign(refExpressionErrors, afterLeftParse) { + var _jsx$1, _jsx2, _typeCast, _jsx3, _typeCast2; + let state; + let jsx$1; + let typeCast; + if (this.hasPlugin("jsx") && (this.match(143) || this.match(47))) { + state = this.state.clone(); + jsx$1 = this.tryParse(() => super.parseMaybeAssign(refExpressionErrors, afterLeftParse), state); + if (!jsx$1.error) return jsx$1.node; + const { context } = this.state; + const currentContext = context[context.length - 1]; + if (currentContext === types$4.j_oTag || currentContext === types$4.j_expr) context.pop(); + } + if (!((_jsx$1 = jsx$1) != null && _jsx$1.error) && !this.match(47)) return super.parseMaybeAssign(refExpressionErrors, afterLeftParse); + if (!state || state === this.state) state = this.state.clone(); + let typeParameters; + const arrow = this.tryParse((abort) => { + var _expr$extra, _typeParameters; + typeParameters = this.tsParseTypeParameters(this.tsParseConstModifier); + const expr = super.parseMaybeAssign(refExpressionErrors, afterLeftParse); + if (expr.type !== "ArrowFunctionExpression" || (_expr$extra = expr.extra) != null && _expr$extra.parenthesized) abort(); + if (((_typeParameters = typeParameters) == null ? void 0 : _typeParameters.params.length) !== 0) this.resetStartLocationFromNode(expr, typeParameters); + expr.typeParameters = typeParameters; + return expr; + }, state); + if (!arrow.error && !arrow.aborted) { + if (typeParameters) this.reportReservedArrowTypeParam(typeParameters); + return arrow.node; + } + if (!jsx$1) { + assert$3(!this.hasPlugin("jsx")); + typeCast = this.tryParse(() => super.parseMaybeAssign(refExpressionErrors, afterLeftParse), state); + if (!typeCast.error) return typeCast.node; + } + if ((_jsx2 = jsx$1) != null && _jsx2.node) { + this.state = jsx$1.failState; + return jsx$1.node; + } + if (arrow.node) { + this.state = arrow.failState; + if (typeParameters) this.reportReservedArrowTypeParam(typeParameters); + return arrow.node; + } + if ((_typeCast = typeCast) != null && _typeCast.node) { + this.state = typeCast.failState; + return typeCast.node; + } + throw ((_jsx3 = jsx$1) == null ? void 0 : _jsx3.error) || arrow.error || ((_typeCast2 = typeCast) == null ? void 0 : _typeCast2.error); + } + reportReservedArrowTypeParam(node) { + var _node$extra2; + if (node.params.length === 1 && !node.params[0].constraint && !((_node$extra2 = node.extra) != null && _node$extra2.trailingComma) && this.getPluginOption("typescript", "disallowAmbiguousJSXLike")) this.raise(TSErrors.ReservedArrowTypeParam, node); + } + parseMaybeUnary(refExpressionErrors, sawUnary) { + if (!this.hasPlugin("jsx") && this.match(47)) return this.tsParseTypeAssertion(); + return super.parseMaybeUnary(refExpressionErrors, sawUnary); + } + parseArrow(node) { + if (this.match(14)) { + const result$1 = this.tryParse((abort) => { + const returnType = this.tsParseTypeOrTypePredicateAnnotation(14); + if (this.canInsertSemicolon() || !this.match(19)) abort(); + return returnType; + }); + if (result$1.aborted) return; + if (!result$1.thrown) { + if (result$1.error) this.state = result$1.failState; + node.returnType = result$1.node; + } + } + return super.parseArrow(node); + } + parseFunctionParamType(param) { + if (this.eat(17)) param.optional = true; + const type = this.tsTryParseTypeAnnotation(); + if (type) param.typeAnnotation = type; + this.resetEndLocation(param); + return param; + } + isAssignable(node, isBinding$2) { + switch (node.type) { + case "TSTypeCastExpression": return this.isAssignable(node.expression, isBinding$2); + case "TSParameterProperty": return true; + default: return super.isAssignable(node, isBinding$2); + } + } + toAssignable(node, isLHS = false) { + switch (node.type) { + case "ParenthesizedExpression": + this.toAssignableParenthesizedExpression(node, isLHS); + break; + case "TSAsExpression": + case "TSSatisfiesExpression": + case "TSNonNullExpression": + case "TSTypeAssertion": + if (isLHS) this.expressionScope.recordArrowParameterBindingError(TSErrors.UnexpectedTypeCastInParameter, node); + else this.raise(TSErrors.UnexpectedTypeCastInParameter, node); + this.toAssignable(node.expression, isLHS); + break; + case "AssignmentExpression": if (!isLHS && node.left.type === "TSTypeCastExpression") node.left = this.typeCastToParameter(node.left); + default: super.toAssignable(node, isLHS); + } + } + toAssignableParenthesizedExpression(node, isLHS) { + switch (node.expression.type) { + case "TSAsExpression": + case "TSSatisfiesExpression": + case "TSNonNullExpression": + case "TSTypeAssertion": + case "ParenthesizedExpression": + this.toAssignable(node.expression, isLHS); + break; + default: super.toAssignable(node, isLHS); + } + } + checkToRestConversion(node, allowPattern) { + switch (node.type) { + case "TSAsExpression": + case "TSSatisfiesExpression": + case "TSTypeAssertion": + case "TSNonNullExpression": + this.checkToRestConversion(node.expression, false); + break; + default: super.checkToRestConversion(node, allowPattern); + } + } + isValidLVal(type, isUnparenthesizedInAssign, binding) { + switch (type) { + case "TSTypeCastExpression": return true; + case "TSParameterProperty": return "parameter"; + case "TSNonNullExpression": return "expression"; + case "TSAsExpression": + case "TSSatisfiesExpression": + case "TSTypeAssertion": return (binding !== 64 || !isUnparenthesizedInAssign) && ["expression", true]; + default: return super.isValidLVal(type, isUnparenthesizedInAssign, binding); + } + } + parseBindingAtom() { + if (this.state.type === 78) return this.parseIdentifier(true); + return super.parseBindingAtom(); + } + parseMaybeDecoratorArguments(expr, startLoc) { + if (this.match(47) || this.match(51)) { + const typeArguments = this.tsParseTypeArgumentsInExpression(); + if (this.match(10)) { + const call$2 = super.parseMaybeDecoratorArguments(expr, startLoc); + call$2.typeParameters = typeArguments; + return call$2; + } + this.unexpected(null, 10); + } + return super.parseMaybeDecoratorArguments(expr, startLoc); + } + checkCommaAfterRest(close) { + if (this.state.isAmbientContext && this.match(12) && this.lookaheadCharCode() === close) { + this.next(); + return false; + } + return super.checkCommaAfterRest(close); + } + isClassMethod() { + return this.match(47) || super.isClassMethod(); + } + isClassProperty() { + return this.match(35) || this.match(14) || super.isClassProperty(); + } + parseMaybeDefault(startLoc, left) { + const node = super.parseMaybeDefault(startLoc, left); + if (node.type === "AssignmentPattern" && node.typeAnnotation && node.right.start < node.typeAnnotation.start) this.raise(TSErrors.TypeAnnotationAfterAssign, node.typeAnnotation); + return node; + } + getTokenFromCode(code$1) { + if (this.state.inType) { + if (code$1 === 62) { + this.finishOp(48, 1); + return; + } + if (code$1 === 60) { + this.finishOp(47, 1); + return; + } + } + super.getTokenFromCode(code$1); + } + reScan_lt_gt() { + const { type } = this.state; + if (type === 47) { + this.state.pos -= 1; + this.readToken_lt(); + } else if (type === 48) { + this.state.pos -= 1; + this.readToken_gt(); + } + } + reScan_lt() { + const { type } = this.state; + if (type === 51) { + this.state.pos -= 2; + this.finishOp(47, 1); + return 47; + } + return type; + } + toAssignableListItem(exprList, index$1, isLHS) { + const node = exprList[index$1]; + if (node.type === "TSTypeCastExpression") exprList[index$1] = this.typeCastToParameter(node); + super.toAssignableListItem(exprList, index$1, isLHS); + } + typeCastToParameter(node) { + node.expression.typeAnnotation = node.typeAnnotation; + this.resetEndLocation(node.expression, node.typeAnnotation.loc.end); + return node.expression; + } + shouldParseArrow(params) { + if (this.match(14)) return params.every((expr) => this.isAssignable(expr, true)); + return super.shouldParseArrow(params); + } + shouldParseAsyncArrow() { + return this.match(14) || super.shouldParseAsyncArrow(); + } + canHaveLeadingDecorator() { + return super.canHaveLeadingDecorator() || this.isAbstractClass(); + } + jsxParseOpeningElementAfterName(node) { + if (this.match(47) || this.match(51)) { + const typeArguments = this.tsTryParseAndCatch(() => this.tsParseTypeArgumentsInExpression()); + if (typeArguments) node.typeParameters = typeArguments; + } + return super.jsxParseOpeningElementAfterName(node); + } + getGetterSetterExpectedParamCount(method) { + const baseCount = super.getGetterSetterExpectedParamCount(method); + const params = this.getObjectOrClassMethodParams(method); + const firstParam = params[0]; + const hasContextParam = firstParam && this.isThisParam(firstParam); + return hasContextParam ? baseCount + 1 : baseCount; + } + parseCatchClauseParam() { + const param = super.parseCatchClauseParam(); + const type = this.tsTryParseTypeAnnotation(); + if (type) { + param.typeAnnotation = type; + this.resetEndLocation(param); + } + return param; + } + tsInAmbientContext(cb$1) { + const { isAmbientContext: oldIsAmbientContext, strict: oldStrict } = this.state; + this.state.isAmbientContext = true; + this.state.strict = false; + try { + return cb$1(); + } finally { + this.state.isAmbientContext = oldIsAmbientContext; + this.state.strict = oldStrict; + } + } + parseClass(node, isStatement$10, optionalId) { + const oldInAbstractClass = this.state.inAbstractClass; + this.state.inAbstractClass = !!node.abstract; + try { + return super.parseClass(node, isStatement$10, optionalId); + } finally { + this.state.inAbstractClass = oldInAbstractClass; + } + } + tsParseAbstractDeclaration(node, decorators) { + if (this.match(80)) { + node.abstract = true; + return this.maybeTakeDecorators(decorators, this.parseClass(node, true, false)); + } else if (this.isContextual(129)) { + if (!this.hasFollowingLineBreak()) { + node.abstract = true; + this.raise(TSErrors.NonClassMethodPropertyHasAbstractModifer, node); + return this.tsParseInterfaceDeclaration(node); + } + } else this.unexpected(null, 80); + } + parseMethod(node, isGenerator, isAsync, isConstructor, allowDirectSuper, type, inClassScope) { + const method = super.parseMethod(node, isGenerator, isAsync, isConstructor, allowDirectSuper, type, inClassScope); + if (method.abstract) { + const hasEstreePlugin = this.hasPlugin("estree"); + const methodFn = hasEstreePlugin ? method.value : method; + if (methodFn.body) { + const { key } = method; + this.raise(TSErrors.AbstractMethodHasImplementation, method, { methodName: key.type === "Identifier" && !method.computed ? key.name : `[${this.input.slice(this.offsetToSourcePos(key.start), this.offsetToSourcePos(key.end))}]` }); + } + } + return method; + } + tsParseTypeParameterName() { + const typeName = this.parseIdentifier(); + return typeName.name; + } + shouldParseAsAmbientContext() { + return !!this.getPluginOption("typescript", "dts"); + } + parse() { + if (this.shouldParseAsAmbientContext()) this.state.isAmbientContext = true; + return super.parse(); + } + getExpression() { + if (this.shouldParseAsAmbientContext()) this.state.isAmbientContext = true; + return super.getExpression(); + } + parseExportSpecifier(node, isString$5, isInTypeExport, isMaybeTypeOnly) { + if (!isString$5 && isMaybeTypeOnly) { + this.parseTypeOnlyImportExportSpecifier(node, false, isInTypeExport); + return this.finishNode(node, "ExportSpecifier"); + } + node.exportKind = "value"; + return super.parseExportSpecifier(node, isString$5, isInTypeExport, isMaybeTypeOnly); + } + parseImportSpecifier(specifier, importedIsString, isInTypeOnlyImport, isMaybeTypeOnly, bindingType) { + if (!importedIsString && isMaybeTypeOnly) { + this.parseTypeOnlyImportExportSpecifier(specifier, true, isInTypeOnlyImport); + return this.finishNode(specifier, "ImportSpecifier"); + } + specifier.importKind = "value"; + return super.parseImportSpecifier(specifier, importedIsString, isInTypeOnlyImport, isMaybeTypeOnly, isInTypeOnlyImport ? 4098 : 4096); + } + parseTypeOnlyImportExportSpecifier(node, isImport$1, isInTypeOnlyImportExport) { + const leftOfAsKey = isImport$1 ? "imported" : "local"; + const rightOfAsKey = isImport$1 ? "local" : "exported"; + let leftOfAs = node[leftOfAsKey]; + let rightOfAs; + let hasTypeSpecifier = false; + let canParseAsKeyword = true; + const loc = leftOfAs.loc.start; + if (this.isContextual(93)) { + const firstAs = this.parseIdentifier(); + if (this.isContextual(93)) { + const secondAs = this.parseIdentifier(); + if (tokenIsKeywordOrIdentifier(this.state.type)) { + hasTypeSpecifier = true; + leftOfAs = firstAs; + rightOfAs = isImport$1 ? this.parseIdentifier() : this.parseModuleExportName(); + canParseAsKeyword = false; + } else { + rightOfAs = secondAs; + canParseAsKeyword = false; + } + } else if (tokenIsKeywordOrIdentifier(this.state.type)) { + canParseAsKeyword = false; + rightOfAs = isImport$1 ? this.parseIdentifier() : this.parseModuleExportName(); + } else { + hasTypeSpecifier = true; + leftOfAs = firstAs; + } + } else if (tokenIsKeywordOrIdentifier(this.state.type)) { + hasTypeSpecifier = true; + if (isImport$1) { + leftOfAs = this.parseIdentifier(true); + if (!this.isContextual(93)) this.checkReservedWord(leftOfAs.name, leftOfAs.loc.start, true, true); + } else leftOfAs = this.parseModuleExportName(); + } + if (hasTypeSpecifier && isInTypeOnlyImportExport) this.raise(isImport$1 ? TSErrors.TypeModifierIsUsedInTypeImports : TSErrors.TypeModifierIsUsedInTypeExports, loc); + node[leftOfAsKey] = leftOfAs; + node[rightOfAsKey] = rightOfAs; + const kindKey = isImport$1 ? "importKind" : "exportKind"; + node[kindKey] = hasTypeSpecifier ? "type" : "value"; + if (canParseAsKeyword && this.eatContextual(93)) node[rightOfAsKey] = isImport$1 ? this.parseIdentifier() : this.parseModuleExportName(); + if (!node[rightOfAsKey]) node[rightOfAsKey] = cloneIdentifier(node[leftOfAsKey]); + if (isImport$1) this.checkIdentifier(node[rightOfAsKey], hasTypeSpecifier ? 4098 : 4096); + } + }; + function isPossiblyLiteralEnum(expression$2) { + if (expression$2.type !== "MemberExpression") return false; + const { computed, property: property$1 } = expression$2; + if (computed && property$1.type !== "StringLiteral" && (property$1.type !== "TemplateLiteral" || property$1.expressions.length > 0)) return false; + return isUncomputedMemberExpressionChain(expression$2.object); + } + function isValidAmbientConstInitializer(expression$2, estree$1) { + var _expression$extra; + const { type } = expression$2; + if ((_expression$extra = expression$2.extra) != null && _expression$extra.parenthesized) return false; + if (estree$1) { + if (type === "Literal") { + const { value } = expression$2; + if (typeof value === "string" || typeof value === "boolean") return true; + } + } else if (type === "StringLiteral" || type === "BooleanLiteral") return true; + if (isNumber$1(expression$2, estree$1) || isNegativeNumber(expression$2, estree$1)) return true; + if (type === "TemplateLiteral" && expression$2.expressions.length === 0) return true; + if (isPossiblyLiteralEnum(expression$2)) return true; + return false; + } + function isNumber$1(expression$2, estree$1) { + if (estree$1) return expression$2.type === "Literal" && (typeof expression$2.value === "number" || "bigint" in expression$2); + return expression$2.type === "NumericLiteral" || expression$2.type === "BigIntLiteral"; + } + function isNegativeNumber(expression$2, estree$1) { + if (expression$2.type === "UnaryExpression") { + const { operator: operator$1, argument } = expression$2; + if (operator$1 === "-" && isNumber$1(argument, estree$1)) return true; + } + return false; + } + function isUncomputedMemberExpressionChain(expression$2) { + if (expression$2.type === "Identifier") return true; + if (expression$2.type !== "MemberExpression" || expression$2.computed) return false; + return isUncomputedMemberExpressionChain(expression$2.object); + } + const PlaceholderErrors = ParseErrorEnum`placeholders`({ + ClassNameIsRequired: "A class name is required.", + UnexpectedSpace: "Unexpected space in placeholder." + }); + var placeholders = (superClass) => class PlaceholdersParserMixin extends superClass { + parsePlaceholder(expectedNode) { + if (this.match(133)) { + const node = this.startNode(); + this.next(); + this.assertNoSpace(); + node.name = super.parseIdentifier(true); + this.assertNoSpace(); + this.expect(133); + return this.finishPlaceholder(node, expectedNode); + } + } + finishPlaceholder(node, expectedNode) { + let placeholder$1 = node; + if (!placeholder$1.expectedNode || !placeholder$1.type) placeholder$1 = this.finishNode(placeholder$1, "Placeholder"); + placeholder$1.expectedNode = expectedNode; + return placeholder$1; + } + getTokenFromCode(code$1) { + if (code$1 === 37 && this.input.charCodeAt(this.state.pos + 1) === 37) this.finishOp(133, 2); + else super.getTokenFromCode(code$1); + } + parseExprAtom(refExpressionErrors) { + return this.parsePlaceholder("Expression") || super.parseExprAtom(refExpressionErrors); + } + parseIdentifier(liberal) { + return this.parsePlaceholder("Identifier") || super.parseIdentifier(liberal); + } + checkReservedWord(word$3, startLoc, checkKeywords, isBinding$2) { + if (word$3 !== void 0) super.checkReservedWord(word$3, startLoc, checkKeywords, isBinding$2); + } + parseBindingAtom() { + return this.parsePlaceholder("Pattern") || super.parseBindingAtom(); + } + isValidLVal(type, isParenthesized, binding) { + return type === "Placeholder" || super.isValidLVal(type, isParenthesized, binding); + } + toAssignable(node, isLHS) { + if (node && node.type === "Placeholder" && node.expectedNode === "Expression") node.expectedNode = "Pattern"; + else super.toAssignable(node, isLHS); + } + chStartsBindingIdentifier(ch, pos) { + if (super.chStartsBindingIdentifier(ch, pos)) return true; + const nextToken = this.lookahead(); + if (nextToken.type === 133) return true; + return false; + } + verifyBreakContinue(node, isBreak) { + if (node.label && node.label.type === "Placeholder") return; + super.verifyBreakContinue(node, isBreak); + } + parseExpressionStatement(node, expr) { + var _expr$extra; + if (expr.type !== "Placeholder" || (_expr$extra = expr.extra) != null && _expr$extra.parenthesized) return super.parseExpressionStatement(node, expr); + if (this.match(14)) { + const stmt = node; + stmt.label = this.finishPlaceholder(expr, "Identifier"); + this.next(); + stmt.body = super.parseStatementOrSloppyAnnexBFunctionDeclaration(); + return this.finishNode(stmt, "LabeledStatement"); + } + this.semicolon(); + const stmtPlaceholder = node; + stmtPlaceholder.name = expr.name; + return this.finishPlaceholder(stmtPlaceholder, "Statement"); + } + parseBlock(allowDirectives, createNewLexicalScope, afterBlockParse) { + return this.parsePlaceholder("BlockStatement") || super.parseBlock(allowDirectives, createNewLexicalScope, afterBlockParse); + } + parseFunctionId(requireId) { + return this.parsePlaceholder("Identifier") || super.parseFunctionId(requireId); + } + parseClass(node, isStatement$10, optionalId) { + const type = isStatement$10 ? "ClassDeclaration" : "ClassExpression"; + this.next(); + const oldStrict = this.state.strict; + const placeholder$1 = this.parsePlaceholder("Identifier"); + if (placeholder$1) if (this.match(81) || this.match(133) || this.match(5)) node.id = placeholder$1; + else if (optionalId || !isStatement$10) { + node.id = null; + node.body = this.finishPlaceholder(placeholder$1, "ClassBody"); + return this.finishNode(node, type); + } else throw this.raise(PlaceholderErrors.ClassNameIsRequired, this.state.startLoc); + else this.parseClassId(node, isStatement$10, optionalId); + super.parseClassSuper(node); + node.body = this.parsePlaceholder("ClassBody") || super.parseClassBody(!!node.superClass, oldStrict); + return this.finishNode(node, type); + } + parseExport(node, decorators) { + const placeholder$1 = this.parsePlaceholder("Identifier"); + if (!placeholder$1) return super.parseExport(node, decorators); + const node2 = node; + if (!this.isContextual(98) && !this.match(12)) { + node2.specifiers = []; + node2.source = null; + node2.declaration = this.finishPlaceholder(placeholder$1, "Declaration"); + return this.finishNode(node2, "ExportNamedDeclaration"); + } + this.expectPlugin("exportDefaultFrom"); + const specifier = this.startNode(); + specifier.exported = placeholder$1; + node2.specifiers = [this.finishNode(specifier, "ExportDefaultSpecifier")]; + return super.parseExport(node2, decorators); + } + isExportDefaultSpecifier() { + if (this.match(65)) { + const next = this.nextTokenStart(); + if (this.isUnparsedContextual(next, "from")) { + if (this.input.startsWith(tokenLabelName(133), this.nextTokenStartSince(next + 4))) return true; + } + } + return super.isExportDefaultSpecifier(); + } + maybeParseExportDefaultSpecifier(node, maybeDefaultIdentifier) { + var _specifiers; + if ((_specifiers = node.specifiers) != null && _specifiers.length) return true; + return super.maybeParseExportDefaultSpecifier(node, maybeDefaultIdentifier); + } + checkExport(node) { + const { specifiers } = node; + if (specifiers != null && specifiers.length) node.specifiers = specifiers.filter((node$1) => node$1.exported.type === "Placeholder"); + super.checkExport(node); + node.specifiers = specifiers; + } + parseImport(node) { + const placeholder$1 = this.parsePlaceholder("Identifier"); + if (!placeholder$1) return super.parseImport(node); + node.specifiers = []; + if (!this.isContextual(98) && !this.match(12)) { + node.source = this.finishPlaceholder(placeholder$1, "StringLiteral"); + this.semicolon(); + return this.finishNode(node, "ImportDeclaration"); + } + const specifier = this.startNodeAtNode(placeholder$1); + specifier.local = placeholder$1; + node.specifiers.push(this.finishNode(specifier, "ImportDefaultSpecifier")); + if (this.eat(12)) { + const hasStarImport = this.maybeParseStarImportSpecifier(node); + if (!hasStarImport) this.parseNamedImportSpecifiers(node); + } + this.expectContextual(98); + node.source = this.parseImportSource(); + this.semicolon(); + return this.finishNode(node, "ImportDeclaration"); + } + parseImportSource() { + return this.parsePlaceholder("StringLiteral") || super.parseImportSource(); + } + assertNoSpace() { + if (this.state.start > this.offsetToSourcePos(this.state.lastTokEndLoc.index)) this.raise(PlaceholderErrors.UnexpectedSpace, this.state.lastTokEndLoc); + } + }; + var v8intrinsic = (superClass) => class V8IntrinsicMixin extends superClass { + parseV8Intrinsic() { + if (this.match(54)) { + const v8IntrinsicStartLoc = this.state.startLoc; + const node = this.startNode(); + this.next(); + if (tokenIsIdentifier(this.state.type)) { + const name = this.parseIdentifierName(); + const identifier$6 = this.createIdentifier(node, name); + identifier$6.type = "V8IntrinsicIdentifier"; + if (this.match(10)) return identifier$6; + } + this.unexpected(v8IntrinsicStartLoc); + } + } + parseExprAtom(refExpressionErrors) { + return this.parseV8Intrinsic() || super.parseExprAtom(refExpressionErrors); + } + }; + const PIPELINE_PROPOSALS = [ + "minimal", + "fsharp", + "hack", + "smart" + ]; + const TOPIC_TOKENS = [ + "^^", + "@@", + "^", + "%", + "#" + ]; + function validatePlugins(pluginsMap) { + if (pluginsMap.has("decorators")) { + if (pluginsMap.has("decorators-legacy")) throw new Error("Cannot use the decorators and decorators-legacy plugin together"); + const decoratorsBeforeExport = pluginsMap.get("decorators").decoratorsBeforeExport; + if (decoratorsBeforeExport != null && typeof decoratorsBeforeExport !== "boolean") throw new Error("'decoratorsBeforeExport' must be a boolean, if specified."); + const allowCallParenthesized = pluginsMap.get("decorators").allowCallParenthesized; + if (allowCallParenthesized != null && typeof allowCallParenthesized !== "boolean") throw new Error("'allowCallParenthesized' must be a boolean."); + } + if (pluginsMap.has("flow") && pluginsMap.has("typescript")) throw new Error("Cannot combine flow and typescript plugins."); + if (pluginsMap.has("placeholders") && pluginsMap.has("v8intrinsic")) throw new Error("Cannot combine placeholders and v8intrinsic plugins."); + if (pluginsMap.has("pipelineOperator")) { + var _pluginsMap$get; + const proposal = pluginsMap.get("pipelineOperator").proposal; + if (!PIPELINE_PROPOSALS.includes(proposal)) { + const proposalList = PIPELINE_PROPOSALS.map((p$1) => `"${p$1}"`).join(", "); + throw new Error(`"pipelineOperator" requires "proposal" option whose value must be one of: ${proposalList}.`); + } + const tupleSyntaxIsHash = ((_pluginsMap$get = pluginsMap.get("recordAndTuple")) == null ? void 0 : _pluginsMap$get.syntaxType) === "hash"; + if (proposal === "hack") { + if (pluginsMap.has("placeholders")) throw new Error("Cannot combine placeholders plugin and Hack-style pipes."); + if (pluginsMap.has("v8intrinsic")) throw new Error("Cannot combine v8intrinsic plugin and Hack-style pipes."); + const topicToken = pluginsMap.get("pipelineOperator").topicToken; + if (!TOPIC_TOKENS.includes(topicToken)) { + const tokenList = TOPIC_TOKENS.map((t$7) => `"${t$7}"`).join(", "); + throw new Error(`"pipelineOperator" in "proposal": "hack" mode also requires a "topicToken" option whose value must be one of: ${tokenList}.`); + } + if (topicToken === "#" && tupleSyntaxIsHash) throw new Error(`Plugin conflict between \`["pipelineOperator", { proposal: "hack", topicToken: "#" }]\` and \`${JSON.stringify(["recordAndTuple", pluginsMap.get("recordAndTuple")])}\`.`); + } else if (proposal === "smart" && tupleSyntaxIsHash) throw new Error(`Plugin conflict between \`["pipelineOperator", { proposal: "smart" }]\` and \`${JSON.stringify(["recordAndTuple", pluginsMap.get("recordAndTuple")])}\`.`); + } + if (pluginsMap.has("moduleAttributes")) { + if (pluginsMap.has("deprecatedImportAssert") || pluginsMap.has("importAssertions")) throw new Error("Cannot combine importAssertions, deprecatedImportAssert and moduleAttributes plugins."); + const moduleAttributesVersionPluginOption = pluginsMap.get("moduleAttributes").version; + if (moduleAttributesVersionPluginOption !== "may-2020") throw new Error("The 'moduleAttributes' plugin requires a 'version' option, representing the last proposal update. Currently, the only supported value is 'may-2020'."); + } + if (pluginsMap.has("importAssertions")) { + if (pluginsMap.has("deprecatedImportAssert")) throw new Error("Cannot combine importAssertions and deprecatedImportAssert plugins."); + } + if (!pluginsMap.has("deprecatedImportAssert") && pluginsMap.has("importAttributes") && pluginsMap.get("importAttributes").deprecatedAssertSyntax) pluginsMap.set("deprecatedImportAssert", {}); + if (pluginsMap.has("recordAndTuple")) { + const syntaxType = pluginsMap.get("recordAndTuple").syntaxType; + if (syntaxType != null) { + const RECORD_AND_TUPLE_SYNTAX_TYPES = ["hash", "bar"]; + if (!RECORD_AND_TUPLE_SYNTAX_TYPES.includes(syntaxType)) throw new Error("The 'syntaxType' option of the 'recordAndTuple' plugin must be one of: " + RECORD_AND_TUPLE_SYNTAX_TYPES.map((p$1) => `'${p$1}'`).join(", ")); + } + } + if (pluginsMap.has("asyncDoExpressions") && !pluginsMap.has("doExpressions")) { + const error = new Error("'asyncDoExpressions' requires 'doExpressions', please add 'doExpressions' to parser plugins."); + error.missingPlugins = "doExpressions"; + throw error; + } + if (pluginsMap.has("optionalChainingAssign") && pluginsMap.get("optionalChainingAssign").version !== "2023-07") throw new Error("The 'optionalChainingAssign' plugin requires a 'version' option, representing the last proposal update. Currently, the only supported value is '2023-07'."); + } + const mixinPlugins = { + estree, + jsx, + flow, + typescript, + v8intrinsic, + placeholders + }; + const mixinPluginNames = Object.keys(mixinPlugins); + var ExpressionParser = class extends LValParser { + checkProto(prop, isRecord, sawProto, refExpressionErrors) { + if (prop.type === "SpreadElement" || this.isObjectMethod(prop) || prop.computed || prop.shorthand) return sawProto; + const key = prop.key; + const name = key.type === "Identifier" ? key.name : key.value; + if (name === "__proto__") { + if (isRecord) { + this.raise(Errors.RecordNoProto, key); + return true; + } + if (sawProto) if (refExpressionErrors) { + if (refExpressionErrors.doubleProtoLoc === null) refExpressionErrors.doubleProtoLoc = key.loc.start; + } else this.raise(Errors.DuplicateProto, key); + return true; + } + return sawProto; + } + shouldExitDescending(expr, potentialArrowAt) { + return expr.type === "ArrowFunctionExpression" && this.offsetToSourcePos(expr.start) === potentialArrowAt; + } + getExpression() { + this.enterInitialScopes(); + this.nextToken(); + const expr = this.parseExpression(); + if (!this.match(140)) this.unexpected(); + this.finalizeRemainingComments(); + expr.comments = this.comments; + expr.errors = this.state.errors; + if (this.optionFlags & 256) expr.tokens = this.tokens; + return expr; + } + parseExpression(disallowIn, refExpressionErrors) { + if (disallowIn) return this.disallowInAnd(() => this.parseExpressionBase(refExpressionErrors)); + return this.allowInAnd(() => this.parseExpressionBase(refExpressionErrors)); + } + parseExpressionBase(refExpressionErrors) { + const startLoc = this.state.startLoc; + const expr = this.parseMaybeAssign(refExpressionErrors); + if (this.match(12)) { + const node = this.startNodeAt(startLoc); + node.expressions = [expr]; + while (this.eat(12)) node.expressions.push(this.parseMaybeAssign(refExpressionErrors)); + this.toReferencedList(node.expressions); + return this.finishNode(node, "SequenceExpression"); + } + return expr; + } + parseMaybeAssignDisallowIn(refExpressionErrors, afterLeftParse) { + return this.disallowInAnd(() => this.parseMaybeAssign(refExpressionErrors, afterLeftParse)); + } + parseMaybeAssignAllowIn(refExpressionErrors, afterLeftParse) { + return this.allowInAnd(() => this.parseMaybeAssign(refExpressionErrors, afterLeftParse)); + } + setOptionalParametersError(refExpressionErrors) { + refExpressionErrors.optionalParametersLoc = this.state.startLoc; + } + parseMaybeAssign(refExpressionErrors, afterLeftParse) { + const startLoc = this.state.startLoc; + const isYield = this.isContextual(108); + if (isYield) { + if (this.prodParam.hasYield) { + this.next(); + let left$1 = this.parseYield(startLoc); + if (afterLeftParse) left$1 = afterLeftParse.call(this, left$1, startLoc); + return left$1; + } + } + let ownExpressionErrors; + if (refExpressionErrors) ownExpressionErrors = false; + else { + refExpressionErrors = new ExpressionErrors(); + ownExpressionErrors = true; + } + const { type } = this.state; + if (type === 10 || tokenIsIdentifier(type)) this.state.potentialArrowAt = this.state.start; + let left = this.parseMaybeConditional(refExpressionErrors); + if (afterLeftParse) left = afterLeftParse.call(this, left, startLoc); + if (tokenIsAssignment(this.state.type)) { + const node = this.startNodeAt(startLoc); + const operator$1 = this.state.value; + node.operator = operator$1; + if (this.match(29)) { + this.toAssignable(left, true); + node.left = left; + const startIndex = startLoc.index; + if (refExpressionErrors.doubleProtoLoc != null && refExpressionErrors.doubleProtoLoc.index >= startIndex) refExpressionErrors.doubleProtoLoc = null; + if (refExpressionErrors.shorthandAssignLoc != null && refExpressionErrors.shorthandAssignLoc.index >= startIndex) refExpressionErrors.shorthandAssignLoc = null; + if (refExpressionErrors.privateKeyLoc != null && refExpressionErrors.privateKeyLoc.index >= startIndex) { + this.checkDestructuringPrivate(refExpressionErrors); + refExpressionErrors.privateKeyLoc = null; + } + } else node.left = left; + this.next(); + node.right = this.parseMaybeAssign(); + this.checkLVal(left, this.finishNode(node, "AssignmentExpression")); + return node; + } else if (ownExpressionErrors) this.checkExpressionErrors(refExpressionErrors, true); + if (isYield) { + const { type: type$1 } = this.state; + const startsExpr$1 = this.hasPlugin("v8intrinsic") ? tokenCanStartExpression(type$1) : tokenCanStartExpression(type$1) && !this.match(54); + if (startsExpr$1 && !this.isAmbiguousPrefixOrIdentifier()) { + this.raiseOverwrite(Errors.YieldNotInGeneratorFunction, startLoc); + return this.parseYield(startLoc); + } + } + return left; + } + parseMaybeConditional(refExpressionErrors) { + const startLoc = this.state.startLoc; + const potentialArrowAt = this.state.potentialArrowAt; + const expr = this.parseExprOps(refExpressionErrors); + if (this.shouldExitDescending(expr, potentialArrowAt)) return expr; + return this.parseConditional(expr, startLoc, refExpressionErrors); + } + parseConditional(expr, startLoc, refExpressionErrors) { + if (this.eat(17)) { + const node = this.startNodeAt(startLoc); + node.test = expr; + node.consequent = this.parseMaybeAssignAllowIn(); + this.expect(14); + node.alternate = this.parseMaybeAssign(); + return this.finishNode(node, "ConditionalExpression"); + } + return expr; + } + parseMaybeUnaryOrPrivate(refExpressionErrors) { + return this.match(139) ? this.parsePrivateName() : this.parseMaybeUnary(refExpressionErrors); + } + parseExprOps(refExpressionErrors) { + const startLoc = this.state.startLoc; + const potentialArrowAt = this.state.potentialArrowAt; + const expr = this.parseMaybeUnaryOrPrivate(refExpressionErrors); + if (this.shouldExitDescending(expr, potentialArrowAt)) return expr; + return this.parseExprOp(expr, startLoc, -1); + } + parseExprOp(left, leftStartLoc, minPrec) { + if (this.isPrivateName(left)) { + const value = this.getPrivateNameSV(left); + if (minPrec >= tokenOperatorPrecedence(58) || !this.prodParam.hasIn || !this.match(58)) this.raise(Errors.PrivateInExpectedIn, left, { identifierName: value }); + this.classScope.usePrivateName(value, left.loc.start); + } + const op = this.state.type; + if (tokenIsOperator(op) && (this.prodParam.hasIn || !this.match(58))) { + let prec = tokenOperatorPrecedence(op); + if (prec > minPrec) { + if (op === 39) { + this.expectPlugin("pipelineOperator"); + if (this.state.inFSharpPipelineDirectBody) return left; + this.checkPipelineAtInfixOperator(left, leftStartLoc); + } + const node = this.startNodeAt(leftStartLoc); + node.left = left; + node.operator = this.state.value; + const logical = op === 41 || op === 42; + const coalesce = op === 40; + if (coalesce) prec = tokenOperatorPrecedence(42); + this.next(); + if (op === 39 && this.hasPlugin(["pipelineOperator", { proposal: "minimal" }])) { + if (this.state.type === 96 && this.prodParam.hasAwait) throw this.raise(Errors.UnexpectedAwaitAfterPipelineBody, this.state.startLoc); + } + node.right = this.parseExprOpRightExpr(op, prec); + const finishedNode = this.finishNode(node, logical || coalesce ? "LogicalExpression" : "BinaryExpression"); + const nextOp = this.state.type; + if (coalesce && (nextOp === 41 || nextOp === 42) || logical && nextOp === 40) throw this.raise(Errors.MixingCoalesceWithLogical, this.state.startLoc); + return this.parseExprOp(finishedNode, leftStartLoc, minPrec); + } + } + return left; + } + parseExprOpRightExpr(op, prec) { + const startLoc = this.state.startLoc; + switch (op) { + case 39: + switch (this.getPluginOption("pipelineOperator", "proposal")) { + case "hack": return this.withTopicBindingContext(() => { + return this.parseHackPipeBody(); + }); + case "fsharp": return this.withSoloAwaitPermittingContext(() => { + return this.parseFSharpPipelineBody(prec); + }); + } + if (this.getPluginOption("pipelineOperator", "proposal") === "smart") return this.withTopicBindingContext(() => { + if (this.prodParam.hasYield && this.isContextual(108)) throw this.raise(Errors.PipeBodyIsTighter, this.state.startLoc); + return this.parseSmartPipelineBodyInStyle(this.parseExprOpBaseRightExpr(op, prec), startLoc); + }); + default: return this.parseExprOpBaseRightExpr(op, prec); + } + } + parseExprOpBaseRightExpr(op, prec) { + const startLoc = this.state.startLoc; + return this.parseExprOp(this.parseMaybeUnaryOrPrivate(), startLoc, tokenIsRightAssociative(op) ? prec - 1 : prec); + } + parseHackPipeBody() { + var _body$extra; + const { startLoc } = this.state; + const body = this.parseMaybeAssign(); + const requiredParentheses = UnparenthesizedPipeBodyDescriptions.has(body.type); + if (requiredParentheses && !((_body$extra = body.extra) != null && _body$extra.parenthesized)) this.raise(Errors.PipeUnparenthesizedBody, startLoc, { type: body.type }); + if (!this.topicReferenceWasUsedInCurrentContext()) this.raise(Errors.PipeTopicUnused, startLoc); + return body; + } + checkExponentialAfterUnary(node) { + if (this.match(57)) this.raise(Errors.UnexpectedTokenUnaryExponentiation, node.argument); + } + parseMaybeUnary(refExpressionErrors, sawUnary) { + const startLoc = this.state.startLoc; + const isAwait = this.isContextual(96); + if (isAwait && this.recordAwaitIfAllowed()) { + this.next(); + const expr$1 = this.parseAwait(startLoc); + if (!sawUnary) this.checkExponentialAfterUnary(expr$1); + return expr$1; + } + const update = this.match(34); + const node = this.startNode(); + if (tokenIsPrefix(this.state.type)) { + node.operator = this.state.value; + node.prefix = true; + if (this.match(72)) this.expectPlugin("throwExpressions"); + const isDelete = this.match(89); + this.next(); + node.argument = this.parseMaybeUnary(null, true); + this.checkExpressionErrors(refExpressionErrors, true); + if (this.state.strict && isDelete) { + const arg = node.argument; + if (arg.type === "Identifier") this.raise(Errors.StrictDelete, node); + else if (this.hasPropertyAsPrivateName(arg)) this.raise(Errors.DeletePrivateField, node); + } + if (!update) { + if (!sawUnary) this.checkExponentialAfterUnary(node); + return this.finishNode(node, "UnaryExpression"); + } + } + const expr = this.parseUpdate(node, update, refExpressionErrors); + if (isAwait) { + const { type } = this.state; + const startsExpr$1 = this.hasPlugin("v8intrinsic") ? tokenCanStartExpression(type) : tokenCanStartExpression(type) && !this.match(54); + if (startsExpr$1 && !this.isAmbiguousPrefixOrIdentifier()) { + this.raiseOverwrite(Errors.AwaitNotInAsyncContext, startLoc); + return this.parseAwait(startLoc); + } + } + return expr; + } + parseUpdate(node, update, refExpressionErrors) { + if (update) { + const updateExpressionNode = node; + this.checkLVal(updateExpressionNode.argument, this.finishNode(updateExpressionNode, "UpdateExpression")); + return node; + } + const startLoc = this.state.startLoc; + let expr = this.parseExprSubscripts(refExpressionErrors); + if (this.checkExpressionErrors(refExpressionErrors, false)) return expr; + while (tokenIsPostfix(this.state.type) && !this.canInsertSemicolon()) { + const node$1 = this.startNodeAt(startLoc); + node$1.operator = this.state.value; + node$1.prefix = false; + node$1.argument = expr; + this.next(); + this.checkLVal(expr, expr = this.finishNode(node$1, "UpdateExpression")); + } + return expr; + } + parseExprSubscripts(refExpressionErrors) { + const startLoc = this.state.startLoc; + const potentialArrowAt = this.state.potentialArrowAt; + const expr = this.parseExprAtom(refExpressionErrors); + if (this.shouldExitDescending(expr, potentialArrowAt)) return expr; + return this.parseSubscripts(expr, startLoc); + } + parseSubscripts(base$1, startLoc, noCalls) { + const state = { + optionalChainMember: false, + maybeAsyncArrow: this.atPossibleAsyncArrow(base$1), + stop: false + }; + do { + base$1 = this.parseSubscript(base$1, startLoc, noCalls, state); + state.maybeAsyncArrow = false; + } while (!state.stop); + return base$1; + } + parseSubscript(base$1, startLoc, noCalls, state) { + const { type } = this.state; + if (!noCalls && type === 15) return this.parseBind(base$1, startLoc, noCalls, state); + else if (tokenIsTemplate(type)) return this.parseTaggedTemplateExpression(base$1, startLoc, state); + let optional = false; + if (type === 18) { + if (noCalls) { + this.raise(Errors.OptionalChainingNoNew, this.state.startLoc); + if (this.lookaheadCharCode() === 40) { + state.stop = true; + return base$1; + } + } + state.optionalChainMember = optional = true; + this.next(); + } + if (!noCalls && this.match(10)) return this.parseCoverCallAndAsyncArrowHead(base$1, startLoc, state, optional); + else { + const computed = this.eat(0); + if (computed || optional || this.eat(16)) return this.parseMember(base$1, startLoc, state, computed, optional); + else { + state.stop = true; + return base$1; + } + } + } + parseMember(base$1, startLoc, state, computed, optional) { + const node = this.startNodeAt(startLoc); + node.object = base$1; + node.computed = computed; + if (computed) { + node.property = this.parseExpression(); + this.expect(3); + } else if (this.match(139)) { + if (base$1.type === "Super") this.raise(Errors.SuperPrivateField, startLoc); + this.classScope.usePrivateName(this.state.value, this.state.startLoc); + node.property = this.parsePrivateName(); + } else node.property = this.parseIdentifier(true); + if (state.optionalChainMember) { + node.optional = optional; + return this.finishNode(node, "OptionalMemberExpression"); + } else return this.finishNode(node, "MemberExpression"); + } + parseBind(base$1, startLoc, noCalls, state) { + const node = this.startNodeAt(startLoc); + node.object = base$1; + this.next(); + node.callee = this.parseNoCallExpr(); + state.stop = true; + return this.parseSubscripts(this.finishNode(node, "BindExpression"), startLoc, noCalls); + } + parseCoverCallAndAsyncArrowHead(base$1, startLoc, state, optional) { + const oldMaybeInArrowParameters = this.state.maybeInArrowParameters; + let refExpressionErrors = null; + this.state.maybeInArrowParameters = true; + this.next(); + const node = this.startNodeAt(startLoc); + node.callee = base$1; + const { maybeAsyncArrow, optionalChainMember } = state; + if (maybeAsyncArrow) { + this.expressionScope.enter(newAsyncArrowScope()); + refExpressionErrors = new ExpressionErrors(); + } + if (optionalChainMember) node.optional = optional; + if (optional) node.arguments = this.parseCallExpressionArguments(11); + else node.arguments = this.parseCallExpressionArguments(11, base$1.type !== "Super", node, refExpressionErrors); + let finishedNode = this.finishCallExpression(node, optionalChainMember); + if (maybeAsyncArrow && this.shouldParseAsyncArrow() && !optional) { + state.stop = true; + this.checkDestructuringPrivate(refExpressionErrors); + this.expressionScope.validateAsPattern(); + this.expressionScope.exit(); + finishedNode = this.parseAsyncArrowFromCallExpression(this.startNodeAt(startLoc), finishedNode); + } else { + if (maybeAsyncArrow) { + this.checkExpressionErrors(refExpressionErrors, true); + this.expressionScope.exit(); + } + this.toReferencedArguments(finishedNode); + } + this.state.maybeInArrowParameters = oldMaybeInArrowParameters; + return finishedNode; + } + toReferencedArguments(node, isParenthesizedExpr) { + this.toReferencedListDeep(node.arguments, isParenthesizedExpr); + } + parseTaggedTemplateExpression(base$1, startLoc, state) { + const node = this.startNodeAt(startLoc); + node.tag = base$1; + node.quasi = this.parseTemplate(true); + if (state.optionalChainMember) this.raise(Errors.OptionalChainingNoTemplate, startLoc); + return this.finishNode(node, "TaggedTemplateExpression"); + } + atPossibleAsyncArrow(base$1) { + return base$1.type === "Identifier" && base$1.name === "async" && this.state.lastTokEndLoc.index === base$1.end && !this.canInsertSemicolon() && base$1.end - base$1.start === 5 && this.offsetToSourcePos(base$1.start) === this.state.potentialArrowAt; + } + finishCallExpression(node, optional) { + if (node.callee.type === "Import") { + if (node.arguments.length === 0 || node.arguments.length > 2) this.raise(Errors.ImportCallArity, node); + else for (const arg of node.arguments) if (arg.type === "SpreadElement") this.raise(Errors.ImportCallSpreadArgument, arg); + } + return this.finishNode(node, optional ? "OptionalCallExpression" : "CallExpression"); + } + parseCallExpressionArguments(close, allowPlaceholder, nodeForExtra, refExpressionErrors) { + const elts = []; + let first$1 = true; + const oldInFSharpPipelineDirectBody = this.state.inFSharpPipelineDirectBody; + this.state.inFSharpPipelineDirectBody = false; + while (!this.eat(close)) { + if (first$1) first$1 = false; + else { + this.expect(12); + if (this.match(close)) { + if (nodeForExtra) this.addTrailingCommaExtraToNode(nodeForExtra); + this.next(); + break; + } + } + elts.push(this.parseExprListItem(false, refExpressionErrors, allowPlaceholder)); + } + this.state.inFSharpPipelineDirectBody = oldInFSharpPipelineDirectBody; + return elts; + } + shouldParseAsyncArrow() { + return this.match(19) && !this.canInsertSemicolon(); + } + parseAsyncArrowFromCallExpression(node, call$2) { + var _call$extra; + this.resetPreviousNodeTrailingComments(call$2); + this.expect(19); + this.parseArrowExpression(node, call$2.arguments, true, (_call$extra = call$2.extra) == null ? void 0 : _call$extra.trailingCommaLoc); + if (call$2.innerComments) setInnerComments(node, call$2.innerComments); + if (call$2.callee.trailingComments) setInnerComments(node, call$2.callee.trailingComments); + return node; + } + parseNoCallExpr() { + const startLoc = this.state.startLoc; + return this.parseSubscripts(this.parseExprAtom(), startLoc, true); + } + parseExprAtom(refExpressionErrors) { + let node; + let decorators = null; + const { type } = this.state; + switch (type) { + case 79: return this.parseSuper(); + case 83: + node = this.startNode(); + this.next(); + if (this.match(16)) return this.parseImportMetaProperty(node); + if (this.match(10)) if (this.optionFlags & 512) return this.parseImportCall(node); + else return this.finishNode(node, "Import"); + else { + this.raise(Errors.UnsupportedImport, this.state.lastTokStartLoc); + return this.finishNode(node, "Import"); + } + case 78: + node = this.startNode(); + this.next(); + return this.finishNode(node, "ThisExpression"); + case 90: return this.parseDo(this.startNode(), false); + case 56: + case 31: { + this.readRegexp(); + return this.parseRegExpLiteral(this.state.value); + } + case 135: return this.parseNumericLiteral(this.state.value); + case 136: return this.parseBigIntLiteral(this.state.value); + case 134: return this.parseStringLiteral(this.state.value); + case 84: return this.parseNullLiteral(); + case 85: return this.parseBooleanLiteral(true); + case 86: return this.parseBooleanLiteral(false); + case 10: { + const canBeArrow = this.state.potentialArrowAt === this.state.start; + return this.parseParenAndDistinguishExpression(canBeArrow); + } + case 2: + case 1: return this.parseArrayLike(this.state.type === 2 ? 4 : 3, false, true); + case 0: return this.parseArrayLike(3, true, false, refExpressionErrors); + case 6: + case 7: return this.parseObjectLike(this.state.type === 6 ? 9 : 8, false, true); + case 5: return this.parseObjectLike(8, false, false, refExpressionErrors); + case 68: return this.parseFunctionOrFunctionSent(); + case 26: decorators = this.parseDecorators(); + case 80: return this.parseClass(this.maybeTakeDecorators(decorators, this.startNode()), false); + case 77: return this.parseNewOrNewTarget(); + case 25: + case 24: return this.parseTemplate(false); + case 15: { + node = this.startNode(); + this.next(); + node.object = null; + const callee = node.callee = this.parseNoCallExpr(); + if (callee.type === "MemberExpression") return this.finishNode(node, "BindExpression"); + else throw this.raise(Errors.UnsupportedBind, callee); + } + case 139: { + this.raise(Errors.PrivateInExpectedIn, this.state.startLoc, { identifierName: this.state.value }); + return this.parsePrivateName(); + } + case 33: return this.parseTopicReferenceThenEqualsSign(54, "%"); + case 32: return this.parseTopicReferenceThenEqualsSign(44, "^"); + case 37: + case 38: return this.parseTopicReference("hack"); + case 44: + case 54: + case 27: { + const pipeProposal = this.getPluginOption("pipelineOperator", "proposal"); + if (pipeProposal) return this.parseTopicReference(pipeProposal); + this.unexpected(); + break; + } + case 47: { + const lookaheadCh = this.input.codePointAt(this.nextTokenStart()); + if (isIdentifierStart$1(lookaheadCh) || lookaheadCh === 62) this.expectOnePlugin([ + "jsx", + "flow", + "typescript" + ]); + else this.unexpected(); + break; + } + default: + if (type === 137) return this.parseDecimalLiteral(this.state.value); + if (tokenIsIdentifier(type)) { + if (this.isContextual(127) && this.lookaheadInLineCharCode() === 123) return this.parseModuleExpression(); + const canBeArrow = this.state.potentialArrowAt === this.state.start; + const containsEsc = this.state.containsEsc; + const id$4 = this.parseIdentifier(); + if (!containsEsc && id$4.name === "async" && !this.canInsertSemicolon()) { + const { type: type$1 } = this.state; + if (type$1 === 68) { + this.resetPreviousNodeTrailingComments(id$4); + this.next(); + return this.parseAsyncFunctionExpression(this.startNodeAtNode(id$4)); + } else if (tokenIsIdentifier(type$1)) if (this.lookaheadCharCode() === 61) return this.parseAsyncArrowUnaryFunction(this.startNodeAtNode(id$4)); + else return id$4; + else if (type$1 === 90) { + this.resetPreviousNodeTrailingComments(id$4); + return this.parseDo(this.startNodeAtNode(id$4), true); + } + } + if (canBeArrow && this.match(19) && !this.canInsertSemicolon()) { + this.next(); + return this.parseArrowExpression(this.startNodeAtNode(id$4), [id$4], false); + } + return id$4; + } else this.unexpected(); + } + } + parseTopicReferenceThenEqualsSign(topicTokenType, topicTokenValue) { + const pipeProposal = this.getPluginOption("pipelineOperator", "proposal"); + if (pipeProposal) { + this.state.type = topicTokenType; + this.state.value = topicTokenValue; + this.state.pos--; + this.state.end--; + this.state.endLoc = createPositionWithColumnOffset(this.state.endLoc, -1); + return this.parseTopicReference(pipeProposal); + } else this.unexpected(); + } + parseTopicReference(pipeProposal) { + const node = this.startNode(); + const startLoc = this.state.startLoc; + const tokenType = this.state.type; + this.next(); + return this.finishTopicReference(node, startLoc, pipeProposal, tokenType); + } + finishTopicReference(node, startLoc, pipeProposal, tokenType) { + if (this.testTopicReferenceConfiguration(pipeProposal, startLoc, tokenType)) if (pipeProposal === "hack") { + if (!this.topicReferenceIsAllowedInCurrentContext()) this.raise(Errors.PipeTopicUnbound, startLoc); + this.registerTopicReference(); + return this.finishNode(node, "TopicReference"); + } else { + if (!this.topicReferenceIsAllowedInCurrentContext()) this.raise(Errors.PrimaryTopicNotAllowed, startLoc); + this.registerTopicReference(); + return this.finishNode(node, "PipelinePrimaryTopicReference"); + } + else throw this.raise(Errors.PipeTopicUnconfiguredToken, startLoc, { token: tokenLabelName(tokenType) }); + } + testTopicReferenceConfiguration(pipeProposal, startLoc, tokenType) { + switch (pipeProposal) { + case "hack": return this.hasPlugin(["pipelineOperator", { topicToken: tokenLabelName(tokenType) }]); + case "smart": return tokenType === 27; + default: throw this.raise(Errors.PipeTopicRequiresHackPipes, startLoc); + } + } + parseAsyncArrowUnaryFunction(node) { + this.prodParam.enter(functionFlags(true, this.prodParam.hasYield)); + const params = [this.parseIdentifier()]; + this.prodParam.exit(); + if (this.hasPrecedingLineBreak()) this.raise(Errors.LineTerminatorBeforeArrow, this.state.curPosition()); + this.expect(19); + return this.parseArrowExpression(node, params, true); + } + parseDo(node, isAsync) { + this.expectPlugin("doExpressions"); + if (isAsync) this.expectPlugin("asyncDoExpressions"); + node.async = isAsync; + this.next(); + const oldLabels = this.state.labels; + this.state.labels = []; + if (isAsync) { + this.prodParam.enter(2); + node.body = this.parseBlock(); + this.prodParam.exit(); + } else node.body = this.parseBlock(); + this.state.labels = oldLabels; + return this.finishNode(node, "DoExpression"); + } + parseSuper() { + const node = this.startNode(); + this.next(); + if (this.match(10) && !this.scope.allowDirectSuper && !(this.optionFlags & 16)) this.raise(Errors.SuperNotAllowed, node); + else if (!this.scope.allowSuper && !(this.optionFlags & 16)) this.raise(Errors.UnexpectedSuper, node); + if (!this.match(10) && !this.match(0) && !this.match(16)) this.raise(Errors.UnsupportedSuper, node); + return this.finishNode(node, "Super"); + } + parsePrivateName() { + const node = this.startNode(); + const id$4 = this.startNodeAt(createPositionWithColumnOffset(this.state.startLoc, 1)); + const name = this.state.value; + this.next(); + node.id = this.createIdentifier(id$4, name); + return this.finishNode(node, "PrivateName"); + } + parseFunctionOrFunctionSent() { + const node = this.startNode(); + this.next(); + if (this.prodParam.hasYield && this.match(16)) { + const meta = this.createIdentifier(this.startNodeAtNode(node), "function"); + this.next(); + if (this.match(103)) this.expectPlugin("functionSent"); + else if (!this.hasPlugin("functionSent")) this.unexpected(); + return this.parseMetaProperty(node, meta, "sent"); + } + return this.parseFunction(node); + } + parseMetaProperty(node, meta, propertyName) { + node.meta = meta; + const containsEsc = this.state.containsEsc; + node.property = this.parseIdentifier(true); + if (node.property.name !== propertyName || containsEsc) this.raise(Errors.UnsupportedMetaProperty, node.property, { + target: meta.name, + onlyValidPropertyName: propertyName + }); + return this.finishNode(node, "MetaProperty"); + } + parseImportMetaProperty(node) { + const id$4 = this.createIdentifier(this.startNodeAtNode(node), "import"); + this.next(); + if (this.isContextual(101)) { + if (!this.inModule) this.raise(Errors.ImportMetaOutsideModule, id$4); + this.sawUnambiguousESM = true; + } else if (this.isContextual(105) || this.isContextual(97)) { + const isSource = this.isContextual(105); + this.expectPlugin(isSource ? "sourcePhaseImports" : "deferredImportEvaluation"); + if (!(this.optionFlags & 512)) throw this.raise(Errors.DynamicImportPhaseRequiresImportExpressions, this.state.startLoc, { phase: this.state.value }); + this.next(); + node.phase = isSource ? "source" : "defer"; + return this.parseImportCall(node); + } + return this.parseMetaProperty(node, id$4, "meta"); + } + parseLiteralAtNode(value, type, node) { + this.addExtra(node, "rawValue", value); + this.addExtra(node, "raw", this.input.slice(this.offsetToSourcePos(node.start), this.state.end)); + node.value = value; + this.next(); + return this.finishNode(node, type); + } + parseLiteral(value, type) { + const node = this.startNode(); + return this.parseLiteralAtNode(value, type, node); + } + parseStringLiteral(value) { + return this.parseLiteral(value, "StringLiteral"); + } + parseNumericLiteral(value) { + return this.parseLiteral(value, "NumericLiteral"); + } + parseBigIntLiteral(value) { + return this.parseLiteral(value, "BigIntLiteral"); + } + parseDecimalLiteral(value) { + return this.parseLiteral(value, "DecimalLiteral"); + } + parseRegExpLiteral(value) { + const node = this.startNode(); + this.addExtra(node, "raw", this.input.slice(this.offsetToSourcePos(node.start), this.state.end)); + node.pattern = value.pattern; + node.flags = value.flags; + this.next(); + return this.finishNode(node, "RegExpLiteral"); + } + parseBooleanLiteral(value) { + const node = this.startNode(); + node.value = value; + this.next(); + return this.finishNode(node, "BooleanLiteral"); + } + parseNullLiteral() { + const node = this.startNode(); + this.next(); + return this.finishNode(node, "NullLiteral"); + } + parseParenAndDistinguishExpression(canBeArrow) { + const startLoc = this.state.startLoc; + let val; + this.next(); + this.expressionScope.enter(newArrowHeadScope()); + const oldMaybeInArrowParameters = this.state.maybeInArrowParameters; + const oldInFSharpPipelineDirectBody = this.state.inFSharpPipelineDirectBody; + this.state.maybeInArrowParameters = true; + this.state.inFSharpPipelineDirectBody = false; + const innerStartLoc = this.state.startLoc; + const exprList = []; + const refExpressionErrors = new ExpressionErrors(); + let first$1 = true; + let spreadStartLoc; + let optionalCommaStartLoc; + while (!this.match(11)) { + if (first$1) first$1 = false; + else { + this.expect(12, refExpressionErrors.optionalParametersLoc === null ? null : refExpressionErrors.optionalParametersLoc); + if (this.match(11)) { + optionalCommaStartLoc = this.state.startLoc; + break; + } + } + if (this.match(21)) { + const spreadNodeStartLoc = this.state.startLoc; + spreadStartLoc = this.state.startLoc; + exprList.push(this.parseParenItem(this.parseRestBinding(), spreadNodeStartLoc)); + if (!this.checkCommaAfterRest(41)) break; + } else exprList.push(this.parseMaybeAssignAllowIn(refExpressionErrors, this.parseParenItem)); + } + const innerEndLoc = this.state.lastTokEndLoc; + this.expect(11); + this.state.maybeInArrowParameters = oldMaybeInArrowParameters; + this.state.inFSharpPipelineDirectBody = oldInFSharpPipelineDirectBody; + let arrowNode = this.startNodeAt(startLoc); + if (canBeArrow && this.shouldParseArrow(exprList) && (arrowNode = this.parseArrow(arrowNode))) { + this.checkDestructuringPrivate(refExpressionErrors); + this.expressionScope.validateAsPattern(); + this.expressionScope.exit(); + this.parseArrowExpression(arrowNode, exprList, false); + return arrowNode; + } + this.expressionScope.exit(); + if (!exprList.length) this.unexpected(this.state.lastTokStartLoc); + if (optionalCommaStartLoc) this.unexpected(optionalCommaStartLoc); + if (spreadStartLoc) this.unexpected(spreadStartLoc); + this.checkExpressionErrors(refExpressionErrors, true); + this.toReferencedListDeep(exprList, true); + if (exprList.length > 1) { + val = this.startNodeAt(innerStartLoc); + val.expressions = exprList; + this.finishNode(val, "SequenceExpression"); + this.resetEndLocation(val, innerEndLoc); + } else val = exprList[0]; + return this.wrapParenthesis(startLoc, val); + } + wrapParenthesis(startLoc, expression$2) { + if (!(this.optionFlags & 1024)) { + this.addExtra(expression$2, "parenthesized", true); + this.addExtra(expression$2, "parenStart", startLoc.index); + this.takeSurroundingComments(expression$2, startLoc.index, this.state.lastTokEndLoc.index); + return expression$2; + } + const parenExpression = this.startNodeAt(startLoc); + parenExpression.expression = expression$2; + return this.finishNode(parenExpression, "ParenthesizedExpression"); + } + shouldParseArrow(params) { + return !this.canInsertSemicolon(); + } + parseArrow(node) { + if (this.eat(19)) return node; + } + parseParenItem(node, startLoc) { + return node; + } + parseNewOrNewTarget() { + const node = this.startNode(); + this.next(); + if (this.match(16)) { + const meta = this.createIdentifier(this.startNodeAtNode(node), "new"); + this.next(); + const metaProp = this.parseMetaProperty(node, meta, "target"); + if (!this.scope.inNonArrowFunction && !this.scope.inClass && !(this.optionFlags & 4)) this.raise(Errors.UnexpectedNewTarget, metaProp); + return metaProp; + } + return this.parseNew(node); + } + parseNew(node) { + this.parseNewCallee(node); + if (this.eat(10)) { + const args = this.parseExprList(11); + this.toReferencedList(args); + node.arguments = args; + } else node.arguments = []; + return this.finishNode(node, "NewExpression"); + } + parseNewCallee(node) { + const isImport$1 = this.match(83); + const callee = this.parseNoCallExpr(); + node.callee = callee; + if (isImport$1 && (callee.type === "Import" || callee.type === "ImportExpression")) this.raise(Errors.ImportCallNotNewExpression, callee); + } + parseTemplateElement(isTagged) { + const { start, startLoc, end, value } = this.state; + const elemStart = start + 1; + const elem = this.startNodeAt(createPositionWithColumnOffset(startLoc, 1)); + if (value === null) { + if (!isTagged) this.raise(Errors.InvalidEscapeSequenceTemplate, createPositionWithColumnOffset(this.state.firstInvalidTemplateEscapePos, 1)); + } + const isTail = this.match(24); + const endOffset = isTail ? -1 : -2; + const elemEnd = end + endOffset; + elem.value = { + raw: this.input.slice(elemStart, elemEnd).replace(/\r\n?/g, "\n"), + cooked: value === null ? null : value.slice(1, endOffset) + }; + elem.tail = isTail; + this.next(); + const finishedNode = this.finishNode(elem, "TemplateElement"); + this.resetEndLocation(finishedNode, createPositionWithColumnOffset(this.state.lastTokEndLoc, endOffset)); + return finishedNode; + } + parseTemplate(isTagged) { + const node = this.startNode(); + let curElt = this.parseTemplateElement(isTagged); + const quasis = [curElt]; + const substitutions = []; + while (!curElt.tail) { + substitutions.push(this.parseTemplateSubstitution()); + this.readTemplateContinuation(); + quasis.push(curElt = this.parseTemplateElement(isTagged)); + } + node.expressions = substitutions; + node.quasis = quasis; + return this.finishNode(node, "TemplateLiteral"); + } + parseTemplateSubstitution() { + return this.parseExpression(); + } + parseObjectLike(close, isPattern$2, isRecord, refExpressionErrors) { + if (isRecord) this.expectPlugin("recordAndTuple"); + const oldInFSharpPipelineDirectBody = this.state.inFSharpPipelineDirectBody; + this.state.inFSharpPipelineDirectBody = false; + let sawProto = false; + let first$1 = true; + const node = this.startNode(); + node.properties = []; + this.next(); + while (!this.match(close)) { + if (first$1) first$1 = false; + else { + this.expect(12); + if (this.match(close)) { + this.addTrailingCommaExtraToNode(node); + break; + } + } + let prop; + if (isPattern$2) prop = this.parseBindingProperty(); + else { + prop = this.parsePropertyDefinition(refExpressionErrors); + sawProto = this.checkProto(prop, isRecord, sawProto, refExpressionErrors); + } + if (isRecord && !this.isObjectProperty(prop) && prop.type !== "SpreadElement") this.raise(Errors.InvalidRecordProperty, prop); + if (prop.shorthand) this.addExtra(prop, "shorthand", true); + node.properties.push(prop); + } + this.next(); + this.state.inFSharpPipelineDirectBody = oldInFSharpPipelineDirectBody; + let type = "ObjectExpression"; + if (isPattern$2) type = "ObjectPattern"; + else if (isRecord) type = "RecordExpression"; + return this.finishNode(node, type); + } + addTrailingCommaExtraToNode(node) { + this.addExtra(node, "trailingComma", this.state.lastTokStartLoc.index); + this.addExtra(node, "trailingCommaLoc", this.state.lastTokStartLoc, false); + } + maybeAsyncOrAccessorProp(prop) { + return !prop.computed && prop.key.type === "Identifier" && (this.isLiteralPropertyName() || this.match(0) || this.match(55)); + } + parsePropertyDefinition(refExpressionErrors) { + let decorators = []; + if (this.match(26)) { + if (this.hasPlugin("decorators")) this.raise(Errors.UnsupportedPropertyDecorator, this.state.startLoc); + while (this.match(26)) decorators.push(this.parseDecorator()); + } + const prop = this.startNode(); + let isAsync = false; + let isAccessor$1 = false; + let startLoc; + if (this.match(21)) { + if (decorators.length) this.unexpected(); + return this.parseSpread(); + } + if (decorators.length) { + prop.decorators = decorators; + decorators = []; + } + prop.method = false; + if (refExpressionErrors) startLoc = this.state.startLoc; + let isGenerator = this.eat(55); + this.parsePropertyNamePrefixOperator(prop); + const containsEsc = this.state.containsEsc; + this.parsePropertyName(prop, refExpressionErrors); + if (!isGenerator && !containsEsc && this.maybeAsyncOrAccessorProp(prop)) { + const { key } = prop; + const keyName = key.name; + if (keyName === "async" && !this.hasPrecedingLineBreak()) { + isAsync = true; + this.resetPreviousNodeTrailingComments(key); + isGenerator = this.eat(55); + this.parsePropertyName(prop); + } + if (keyName === "get" || keyName === "set") { + isAccessor$1 = true; + this.resetPreviousNodeTrailingComments(key); + prop.kind = keyName; + if (this.match(55)) { + isGenerator = true; + this.raise(Errors.AccessorIsGenerator, this.state.curPosition(), { kind: keyName }); + this.next(); + } + this.parsePropertyName(prop); + } + } + return this.parseObjPropValue(prop, startLoc, isGenerator, isAsync, false, isAccessor$1, refExpressionErrors); + } + getGetterSetterExpectedParamCount(method) { + return method.kind === "get" ? 0 : 1; + } + getObjectOrClassMethodParams(method) { + return method.params; + } + checkGetterSetterParams(method) { + var _params$1; + const paramCount = this.getGetterSetterExpectedParamCount(method); + const params = this.getObjectOrClassMethodParams(method); + if (params.length !== paramCount) this.raise(method.kind === "get" ? Errors.BadGetterArity : Errors.BadSetterArity, method); + if (method.kind === "set" && ((_params$1 = params[params.length - 1]) == null ? void 0 : _params$1.type) === "RestElement") this.raise(Errors.BadSetterRestParameter, method); + } + parseObjectMethod(prop, isGenerator, isAsync, isPattern$2, isAccessor$1) { + if (isAccessor$1) { + const finishedProp = this.parseMethod(prop, isGenerator, false, false, false, "ObjectMethod"); + this.checkGetterSetterParams(finishedProp); + return finishedProp; + } + if (isAsync || isGenerator || this.match(10)) { + if (isPattern$2) this.unexpected(); + prop.kind = "method"; + prop.method = true; + return this.parseMethod(prop, isGenerator, isAsync, false, false, "ObjectMethod"); + } + } + parseObjectProperty(prop, startLoc, isPattern$2, refExpressionErrors) { + prop.shorthand = false; + if (this.eat(14)) { + prop.value = isPattern$2 ? this.parseMaybeDefault(this.state.startLoc) : this.parseMaybeAssignAllowIn(refExpressionErrors); + return this.finishNode(prop, "ObjectProperty"); + } + if (!prop.computed && prop.key.type === "Identifier") { + this.checkReservedWord(prop.key.name, prop.key.loc.start, true, false); + if (isPattern$2) prop.value = this.parseMaybeDefault(startLoc, cloneIdentifier(prop.key)); + else if (this.match(29)) { + const shorthandAssignLoc = this.state.startLoc; + if (refExpressionErrors != null) { + if (refExpressionErrors.shorthandAssignLoc === null) refExpressionErrors.shorthandAssignLoc = shorthandAssignLoc; + } else this.raise(Errors.InvalidCoverInitializedName, shorthandAssignLoc); + prop.value = this.parseMaybeDefault(startLoc, cloneIdentifier(prop.key)); + } else prop.value = cloneIdentifier(prop.key); + prop.shorthand = true; + return this.finishNode(prop, "ObjectProperty"); + } + } + parseObjPropValue(prop, startLoc, isGenerator, isAsync, isPattern$2, isAccessor$1, refExpressionErrors) { + const node = this.parseObjectMethod(prop, isGenerator, isAsync, isPattern$2, isAccessor$1) || this.parseObjectProperty(prop, startLoc, isPattern$2, refExpressionErrors); + if (!node) this.unexpected(); + return node; + } + parsePropertyName(prop, refExpressionErrors) { + if (this.eat(0)) { + prop.computed = true; + prop.key = this.parseMaybeAssignAllowIn(); + this.expect(3); + } else { + const { type, value } = this.state; + let key; + if (tokenIsKeywordOrIdentifier(type)) key = this.parseIdentifier(true); + else switch (type) { + case 135: + key = this.parseNumericLiteral(value); + break; + case 134: + key = this.parseStringLiteral(value); + break; + case 136: + key = this.parseBigIntLiteral(value); + break; + case 139: { + const privateKeyLoc = this.state.startLoc; + if (refExpressionErrors != null) { + if (refExpressionErrors.privateKeyLoc === null) refExpressionErrors.privateKeyLoc = privateKeyLoc; + } else this.raise(Errors.UnexpectedPrivateField, privateKeyLoc); + key = this.parsePrivateName(); + break; + } + default: + if (type === 137) { + key = this.parseDecimalLiteral(value); + break; + } + this.unexpected(); + } + prop.key = key; + if (type !== 139) prop.computed = false; + } + } + initFunction(node, isAsync) { + node.id = null; + node.generator = false; + node.async = isAsync; + } + parseMethod(node, isGenerator, isAsync, isConstructor, allowDirectSuper, type, inClassScope = false) { + this.initFunction(node, isAsync); + node.generator = isGenerator; + this.scope.enter(18 | (inClassScope ? 64 : 0) | (allowDirectSuper ? 32 : 0)); + this.prodParam.enter(functionFlags(isAsync, node.generator)); + this.parseFunctionParams(node, isConstructor); + const finishedNode = this.parseFunctionBodyAndFinish(node, type, true); + this.prodParam.exit(); + this.scope.exit(); + return finishedNode; + } + parseArrayLike(close, canBePattern, isTuple, refExpressionErrors) { + if (isTuple) this.expectPlugin("recordAndTuple"); + const oldInFSharpPipelineDirectBody = this.state.inFSharpPipelineDirectBody; + this.state.inFSharpPipelineDirectBody = false; + const node = this.startNode(); + this.next(); + node.elements = this.parseExprList(close, !isTuple, refExpressionErrors, node); + this.state.inFSharpPipelineDirectBody = oldInFSharpPipelineDirectBody; + return this.finishNode(node, isTuple ? "TupleExpression" : "ArrayExpression"); + } + parseArrowExpression(node, params, isAsync, trailingCommaLoc) { + this.scope.enter(6); + let flags = functionFlags(isAsync, false); + if (!this.match(5) && this.prodParam.hasIn) flags |= 8; + this.prodParam.enter(flags); + this.initFunction(node, isAsync); + const oldMaybeInArrowParameters = this.state.maybeInArrowParameters; + if (params) { + this.state.maybeInArrowParameters = true; + this.setArrowFunctionParameters(node, params, trailingCommaLoc); + } + this.state.maybeInArrowParameters = false; + this.parseFunctionBody(node, true); + this.prodParam.exit(); + this.scope.exit(); + this.state.maybeInArrowParameters = oldMaybeInArrowParameters; + return this.finishNode(node, "ArrowFunctionExpression"); + } + setArrowFunctionParameters(node, params, trailingCommaLoc) { + this.toAssignableList(params, trailingCommaLoc, false); + node.params = params; + } + parseFunctionBodyAndFinish(node, type, isMethod$2 = false) { + this.parseFunctionBody(node, false, isMethod$2); + return this.finishNode(node, type); + } + parseFunctionBody(node, allowExpression, isMethod$2 = false) { + const isExpression$6 = allowExpression && !this.match(5); + this.expressionScope.enter(newExpressionScope()); + if (isExpression$6) { + node.body = this.parseMaybeAssign(); + this.checkParams(node, false, allowExpression, false); + } else { + const oldStrict = this.state.strict; + const oldLabels = this.state.labels; + this.state.labels = []; + this.prodParam.enter(this.prodParam.currentFlags() | 4); + node.body = this.parseBlock(true, false, (hasStrictModeDirective) => { + const nonSimple = !this.isSimpleParamList(node.params); + if (hasStrictModeDirective && nonSimple) this.raise(Errors.IllegalLanguageModeDirective, (node.kind === "method" || node.kind === "constructor") && !!node.key ? node.key.loc.end : node); + const strictModeChanged = !oldStrict && this.state.strict; + this.checkParams(node, !this.state.strict && !allowExpression && !isMethod$2 && !nonSimple, allowExpression, strictModeChanged); + if (this.state.strict && node.id) this.checkIdentifier(node.id, 65, strictModeChanged); + }); + this.prodParam.exit(); + this.state.labels = oldLabels; + } + this.expressionScope.exit(); + } + isSimpleParameter(node) { + return node.type === "Identifier"; + } + isSimpleParamList(params) { + for (let i$5 = 0, len = params.length; i$5 < len; i$5++) if (!this.isSimpleParameter(params[i$5])) return false; + return true; + } + checkParams(node, allowDuplicates, isArrowFunction, strictModeChanged = true) { + const checkClashes = !allowDuplicates && new Set(); + const formalParameters = { type: "FormalParameters" }; + for (const param of node.params) this.checkLVal(param, formalParameters, 5, checkClashes, strictModeChanged); + } + parseExprList(close, allowEmpty, refExpressionErrors, nodeForExtra) { + const elts = []; + let first$1 = true; + while (!this.eat(close)) { + if (first$1) first$1 = false; + else { + this.expect(12); + if (this.match(close)) { + if (nodeForExtra) this.addTrailingCommaExtraToNode(nodeForExtra); + this.next(); + break; + } + } + elts.push(this.parseExprListItem(allowEmpty, refExpressionErrors)); + } + return elts; + } + parseExprListItem(allowEmpty, refExpressionErrors, allowPlaceholder) { + let elt; + if (this.match(12)) { + if (!allowEmpty) this.raise(Errors.UnexpectedToken, this.state.curPosition(), { unexpected: "," }); + elt = null; + } else if (this.match(21)) { + const spreadNodeStartLoc = this.state.startLoc; + elt = this.parseParenItem(this.parseSpread(refExpressionErrors), spreadNodeStartLoc); + } else if (this.match(17)) { + this.expectPlugin("partialApplication"); + if (!allowPlaceholder) this.raise(Errors.UnexpectedArgumentPlaceholder, this.state.startLoc); + const node = this.startNode(); + this.next(); + elt = this.finishNode(node, "ArgumentPlaceholder"); + } else elt = this.parseMaybeAssignAllowIn(refExpressionErrors, this.parseParenItem); + return elt; + } + parseIdentifier(liberal) { + const node = this.startNode(); + const name = this.parseIdentifierName(liberal); + return this.createIdentifier(node, name); + } + createIdentifier(node, name) { + node.name = name; + node.loc.identifierName = name; + return this.finishNode(node, "Identifier"); + } + parseIdentifierName(liberal) { + let name; + const { startLoc, type } = this.state; + if (tokenIsKeywordOrIdentifier(type)) name = this.state.value; + else this.unexpected(); + const tokenIsKeyword$1 = tokenKeywordOrIdentifierIsKeyword(type); + if (liberal) { + if (tokenIsKeyword$1) this.replaceToken(132); + } else this.checkReservedWord(name, startLoc, tokenIsKeyword$1, false); + this.next(); + return name; + } + checkReservedWord(word$3, startLoc, checkKeywords, isBinding$2) { + if (word$3.length > 10) return; + if (!canBeReservedWord(word$3)) return; + if (checkKeywords && isKeyword$1(word$3)) { + this.raise(Errors.UnexpectedKeyword, startLoc, { keyword: word$3 }); + return; + } + const reservedTest = !this.state.strict ? isReservedWord$1 : isBinding$2 ? isStrictBindReservedWord$1 : isStrictReservedWord$1; + if (reservedTest(word$3, this.inModule)) { + this.raise(Errors.UnexpectedReservedWord, startLoc, { reservedWord: word$3 }); + return; + } else if (word$3 === "yield") { + if (this.prodParam.hasYield) { + this.raise(Errors.YieldBindingIdentifier, startLoc); + return; + } + } else if (word$3 === "await") { + if (this.prodParam.hasAwait) { + this.raise(Errors.AwaitBindingIdentifier, startLoc); + return; + } + if (this.scope.inStaticBlock) { + this.raise(Errors.AwaitBindingIdentifierInStaticBlock, startLoc); + return; + } + this.expressionScope.recordAsyncArrowParametersError(startLoc); + } else if (word$3 === "arguments") { + if (this.scope.inClassAndNotInNonArrowFunction) { + this.raise(Errors.ArgumentsInClass, startLoc); + return; + } + } + } + recordAwaitIfAllowed() { + const isAwaitAllowed = this.prodParam.hasAwait || this.optionFlags & 1 && !this.scope.inFunction; + if (isAwaitAllowed && !this.scope.inFunction) this.state.hasTopLevelAwait = true; + return isAwaitAllowed; + } + parseAwait(startLoc) { + const node = this.startNodeAt(startLoc); + this.expressionScope.recordParameterInitializerError(Errors.AwaitExpressionFormalParameter, node); + if (this.eat(55)) this.raise(Errors.ObsoleteAwaitStar, node); + if (!this.scope.inFunction && !(this.optionFlags & 1)) if (this.isAmbiguousPrefixOrIdentifier()) this.ambiguousScriptDifferentAst = true; + else this.sawUnambiguousESM = true; + if (!this.state.soloAwait) node.argument = this.parseMaybeUnary(null, true); + return this.finishNode(node, "AwaitExpression"); + } + isAmbiguousPrefixOrIdentifier() { + if (this.hasPrecedingLineBreak()) return true; + const { type } = this.state; + return type === 53 || type === 10 || type === 0 || tokenIsTemplate(type) || type === 102 && !this.state.containsEsc || type === 138 || type === 56 || this.hasPlugin("v8intrinsic") && type === 54; + } + parseYield(startLoc) { + const node = this.startNodeAt(startLoc); + this.expressionScope.recordParameterInitializerError(Errors.YieldInParameter, node); + let delegating = false; + let argument = null; + if (!this.hasPrecedingLineBreak()) { + delegating = this.eat(55); + switch (this.state.type) { + case 13: + case 140: + case 8: + case 11: + case 3: + case 9: + case 14: + case 12: if (!delegating) break; + default: argument = this.parseMaybeAssign(); + } + } + node.delegate = delegating; + node.argument = argument; + return this.finishNode(node, "YieldExpression"); + } + parseImportCall(node) { + this.next(); + node.source = this.parseMaybeAssignAllowIn(); + node.options = null; + if (this.eat(12)) { + if (!this.match(11)) { + node.options = this.parseMaybeAssignAllowIn(); + if (this.eat(12) && !this.match(11)) { + do + this.parseMaybeAssignAllowIn(); + while (this.eat(12) && !this.match(11)); + this.raise(Errors.ImportCallArity, node); + } + } + } + this.expect(11); + return this.finishNode(node, "ImportExpression"); + } + checkPipelineAtInfixOperator(left, leftStartLoc) { + if (this.hasPlugin(["pipelineOperator", { proposal: "smart" }])) { + if (left.type === "SequenceExpression") this.raise(Errors.PipelineHeadSequenceExpression, leftStartLoc); + } + } + parseSmartPipelineBodyInStyle(childExpr, startLoc) { + if (this.isSimpleReference(childExpr)) { + const bodyNode = this.startNodeAt(startLoc); + bodyNode.callee = childExpr; + return this.finishNode(bodyNode, "PipelineBareFunction"); + } else { + const bodyNode = this.startNodeAt(startLoc); + this.checkSmartPipeTopicBodyEarlyErrors(startLoc); + bodyNode.expression = childExpr; + return this.finishNode(bodyNode, "PipelineTopicExpression"); + } + } + isSimpleReference(expression$2) { + switch (expression$2.type) { + case "MemberExpression": return !expression$2.computed && this.isSimpleReference(expression$2.object); + case "Identifier": return true; + default: return false; + } + } + checkSmartPipeTopicBodyEarlyErrors(startLoc) { + if (this.match(19)) throw this.raise(Errors.PipelineBodyNoArrow, this.state.startLoc); + if (!this.topicReferenceWasUsedInCurrentContext()) this.raise(Errors.PipelineTopicUnused, startLoc); + } + withTopicBindingContext(callback) { + const outerContextTopicState = this.state.topicContext; + this.state.topicContext = { + maxNumOfResolvableTopics: 1, + maxTopicIndex: null + }; + try { + return callback(); + } finally { + this.state.topicContext = outerContextTopicState; + } + } + withSmartMixTopicForbiddingContext(callback) { + if (this.hasPlugin(["pipelineOperator", { proposal: "smart" }])) { + const outerContextTopicState = this.state.topicContext; + this.state.topicContext = { + maxNumOfResolvableTopics: 0, + maxTopicIndex: null + }; + try { + return callback(); + } finally { + this.state.topicContext = outerContextTopicState; + } + } else return callback(); + } + withSoloAwaitPermittingContext(callback) { + const outerContextSoloAwaitState = this.state.soloAwait; + this.state.soloAwait = true; + try { + return callback(); + } finally { + this.state.soloAwait = outerContextSoloAwaitState; + } + } + allowInAnd(callback) { + const flags = this.prodParam.currentFlags(); + const prodParamToSet = 8 & ~flags; + if (prodParamToSet) { + this.prodParam.enter(flags | 8); + try { + return callback(); + } finally { + this.prodParam.exit(); + } + } + return callback(); + } + disallowInAnd(callback) { + const flags = this.prodParam.currentFlags(); + const prodParamToClear = 8 & flags; + if (prodParamToClear) { + this.prodParam.enter(flags & -9); + try { + return callback(); + } finally { + this.prodParam.exit(); + } + } + return callback(); + } + registerTopicReference() { + this.state.topicContext.maxTopicIndex = 0; + } + topicReferenceIsAllowedInCurrentContext() { + return this.state.topicContext.maxNumOfResolvableTopics >= 1; + } + topicReferenceWasUsedInCurrentContext() { + return this.state.topicContext.maxTopicIndex != null && this.state.topicContext.maxTopicIndex >= 0; + } + parseFSharpPipelineBody(prec) { + const startLoc = this.state.startLoc; + this.state.potentialArrowAt = this.state.start; + const oldInFSharpPipelineDirectBody = this.state.inFSharpPipelineDirectBody; + this.state.inFSharpPipelineDirectBody = true; + const ret = this.parseExprOp(this.parseMaybeUnaryOrPrivate(), startLoc, prec); + this.state.inFSharpPipelineDirectBody = oldInFSharpPipelineDirectBody; + return ret; + } + parseModuleExpression() { + this.expectPlugin("moduleBlocks"); + const node = this.startNode(); + this.next(); + if (!this.match(5)) this.unexpected(null, 5); + const program$3 = this.startNodeAt(this.state.endLoc); + this.next(); + const revertScopes = this.initializeScopes(true); + this.enterInitialScopes(); + try { + node.body = this.parseProgram(program$3, 8, "module"); + } finally { + revertScopes(); + } + return this.finishNode(node, "ModuleExpression"); + } + parsePropertyNamePrefixOperator(prop) {} + }; + const loopLabel = { kind: 1 }, switchLabel = { kind: 2 }; + const loneSurrogate = /[\uD800-\uDFFF]/u; + const keywordRelationalOperator = /in(?:stanceof)?/y; + function babel7CompatTokens(tokens$3, input, startIndex) { + for (let i$5 = 0; i$5 < tokens$3.length; i$5++) { + const token$1 = tokens$3[i$5]; + const { type } = token$1; + if (typeof type === "number") { + { + if (type === 139) { + const { loc, start, value, end } = token$1; + const hashEndPos = start + 1; + const hashEndLoc = createPositionWithColumnOffset(loc.start, 1); + tokens$3.splice(i$5, 1, new Token({ + type: getExportedToken(27), + value: "#", + start, + end: hashEndPos, + startLoc: loc.start, + endLoc: hashEndLoc + }), new Token({ + type: getExportedToken(132), + value, + start: hashEndPos, + end, + startLoc: hashEndLoc, + endLoc: loc.end + })); + i$5++; + continue; + } + if (tokenIsTemplate(type)) { + const { loc, start, value, end } = token$1; + const backquoteEnd = start + 1; + const backquoteEndLoc = createPositionWithColumnOffset(loc.start, 1); + let startToken; + if (input.charCodeAt(start - startIndex) === 96) startToken = new Token({ + type: getExportedToken(22), + value: "`", + start, + end: backquoteEnd, + startLoc: loc.start, + endLoc: backquoteEndLoc + }); + else startToken = new Token({ + type: getExportedToken(8), + value: "}", + start, + end: backquoteEnd, + startLoc: loc.start, + endLoc: backquoteEndLoc + }); + let templateValue, templateElementEnd, templateElementEndLoc, endToken; + if (type === 24) { + templateElementEnd = end - 1; + templateElementEndLoc = createPositionWithColumnOffset(loc.end, -1); + templateValue = value === null ? null : value.slice(1, -1); + endToken = new Token({ + type: getExportedToken(22), + value: "`", + start: templateElementEnd, + end, + startLoc: templateElementEndLoc, + endLoc: loc.end + }); + } else { + templateElementEnd = end - 2; + templateElementEndLoc = createPositionWithColumnOffset(loc.end, -2); + templateValue = value === null ? null : value.slice(1, -2); + endToken = new Token({ + type: getExportedToken(23), + value: "${", + start: templateElementEnd, + end, + startLoc: templateElementEndLoc, + endLoc: loc.end + }); + } + tokens$3.splice(i$5, 1, startToken, new Token({ + type: getExportedToken(20), + value: templateValue, + start: backquoteEnd, + end: templateElementEnd, + startLoc: backquoteEndLoc, + endLoc: templateElementEndLoc + }), endToken); + i$5 += 2; + continue; + } + } + token$1.type = getExportedToken(type); + } + } + return tokens$3; + } + var StatementParser = class extends ExpressionParser { + parseTopLevel(file$2, program$3) { + file$2.program = this.parseProgram(program$3); + file$2.comments = this.comments; + if (this.optionFlags & 256) file$2.tokens = babel7CompatTokens(this.tokens, this.input, this.startIndex); + return this.finishNode(file$2, "File"); + } + parseProgram(program$3, end = 140, sourceType = this.options.sourceType) { + program$3.sourceType = sourceType; + program$3.interpreter = this.parseInterpreterDirective(); + this.parseBlockBody(program$3, true, true, end); + if (this.inModule) { + if (!(this.optionFlags & 64) && this.scope.undefinedExports.size > 0) for (const [localName, at$3] of Array.from(this.scope.undefinedExports)) this.raise(Errors.ModuleExportUndefined, at$3, { localName }); + this.addExtra(program$3, "topLevelAwait", this.state.hasTopLevelAwait); + } + let finishedProgram; + if (end === 140) finishedProgram = this.finishNode(program$3, "Program"); + else finishedProgram = this.finishNodeAt(program$3, "Program", createPositionWithColumnOffset(this.state.startLoc, -1)); + return finishedProgram; + } + stmtToDirective(stmt) { + const directive$1 = stmt; + directive$1.type = "Directive"; + directive$1.value = directive$1.expression; + delete directive$1.expression; + const directiveLiteral$1 = directive$1.value; + const expressionValue = directiveLiteral$1.value; + const raw = this.input.slice(this.offsetToSourcePos(directiveLiteral$1.start), this.offsetToSourcePos(directiveLiteral$1.end)); + const val = directiveLiteral$1.value = raw.slice(1, -1); + this.addExtra(directiveLiteral$1, "raw", raw); + this.addExtra(directiveLiteral$1, "rawValue", val); + this.addExtra(directiveLiteral$1, "expressionValue", expressionValue); + directiveLiteral$1.type = "DirectiveLiteral"; + return directive$1; + } + parseInterpreterDirective() { + if (!this.match(28)) return null; + const node = this.startNode(); + node.value = this.state.value; + this.next(); + return this.finishNode(node, "InterpreterDirective"); + } + isLet() { + if (!this.isContextual(100)) return false; + return this.hasFollowingBindingAtom(); + } + chStartsBindingIdentifier(ch, pos) { + if (isIdentifierStart$1(ch)) { + keywordRelationalOperator.lastIndex = pos; + if (keywordRelationalOperator.test(this.input)) { + const endCh = this.codePointAtPos(keywordRelationalOperator.lastIndex); + if (!isIdentifierChar$1(endCh) && endCh !== 92) return false; + } + return true; + } else if (ch === 92) return true; + else return false; + } + chStartsBindingPattern(ch) { + return ch === 91 || ch === 123; + } + hasFollowingBindingAtom() { + const next = this.nextTokenStart(); + const nextCh = this.codePointAtPos(next); + return this.chStartsBindingPattern(nextCh) || this.chStartsBindingIdentifier(nextCh, next); + } + hasInLineFollowingBindingIdentifierOrBrace() { + const next = this.nextTokenInLineStart(); + const nextCh = this.codePointAtPos(next); + return nextCh === 123 || this.chStartsBindingIdentifier(nextCh, next); + } + startsUsingForOf() { + const { type, containsEsc } = this.lookahead(); + if (type === 102 && !containsEsc) return false; + else if (tokenIsIdentifier(type) && !this.hasFollowingLineBreak()) { + this.expectPlugin("explicitResourceManagement"); + return true; + } + } + startsAwaitUsing() { + let next = this.nextTokenInLineStart(); + if (this.isUnparsedContextual(next, "using")) { + next = this.nextTokenInLineStartSince(next + 5); + const nextCh = this.codePointAtPos(next); + if (this.chStartsBindingIdentifier(nextCh, next)) { + this.expectPlugin("explicitResourceManagement"); + return true; + } + } + return false; + } + parseModuleItem() { + return this.parseStatementLike(15); + } + parseStatementListItem() { + return this.parseStatementLike(6 | (!this.options.annexB || this.state.strict ? 0 : 8)); + } + parseStatementOrSloppyAnnexBFunctionDeclaration(allowLabeledFunction = false) { + let flags = 0; + if (this.options.annexB && !this.state.strict) { + flags |= 4; + if (allowLabeledFunction) flags |= 8; + } + return this.parseStatementLike(flags); + } + parseStatement() { + return this.parseStatementLike(0); + } + parseStatementLike(flags) { + let decorators = null; + if (this.match(26)) decorators = this.parseDecorators(true); + return this.parseStatementContent(flags, decorators); + } + parseStatementContent(flags, decorators) { + const startType = this.state.type; + const node = this.startNode(); + const allowDeclaration = !!(flags & 2); + const allowFunctionDeclaration = !!(flags & 4); + const topLevel = flags & 1; + switch (startType) { + case 60: return this.parseBreakContinueStatement(node, true); + case 63: return this.parseBreakContinueStatement(node, false); + case 64: return this.parseDebuggerStatement(node); + case 90: return this.parseDoWhileStatement(node); + case 91: return this.parseForStatement(node); + case 68: + if (this.lookaheadCharCode() === 46) break; + if (!allowFunctionDeclaration) this.raise(this.state.strict ? Errors.StrictFunction : this.options.annexB ? Errors.SloppyFunctionAnnexB : Errors.SloppyFunction, this.state.startLoc); + return this.parseFunctionStatement(node, false, !allowDeclaration && allowFunctionDeclaration); + case 80: + if (!allowDeclaration) this.unexpected(); + return this.parseClass(this.maybeTakeDecorators(decorators, node), true); + case 69: return this.parseIfStatement(node); + case 70: return this.parseReturnStatement(node); + case 71: return this.parseSwitchStatement(node); + case 72: return this.parseThrowStatement(node); + case 73: return this.parseTryStatement(node); + case 96: + if (!this.state.containsEsc && this.startsAwaitUsing()) { + if (!this.recordAwaitIfAllowed()) this.raise(Errors.AwaitUsingNotInAsyncContext, node); + else if (!allowDeclaration) this.raise(Errors.UnexpectedLexicalDeclaration, node); + this.next(); + return this.parseVarStatement(node, "await using"); + } + break; + case 107: + if (this.state.containsEsc || !this.hasInLineFollowingBindingIdentifierOrBrace()) break; + this.expectPlugin("explicitResourceManagement"); + if (!this.scope.inModule && this.scope.inTopLevel) this.raise(Errors.UnexpectedUsingDeclaration, this.state.startLoc); + else if (!allowDeclaration) this.raise(Errors.UnexpectedLexicalDeclaration, this.state.startLoc); + return this.parseVarStatement(node, "using"); + case 100: { + if (this.state.containsEsc) break; + const next = this.nextTokenStart(); + const nextCh = this.codePointAtPos(next); + if (nextCh !== 91) { + if (!allowDeclaration && this.hasFollowingLineBreak()) break; + if (!this.chStartsBindingIdentifier(nextCh, next) && nextCh !== 123) break; + } + } + case 75: if (!allowDeclaration) this.raise(Errors.UnexpectedLexicalDeclaration, this.state.startLoc); + case 74: { + const kind = this.state.value; + return this.parseVarStatement(node, kind); + } + case 92: return this.parseWhileStatement(node); + case 76: return this.parseWithStatement(node); + case 5: return this.parseBlock(); + case 13: return this.parseEmptyStatement(node); + case 83: { + const nextTokenCharCode = this.lookaheadCharCode(); + if (nextTokenCharCode === 40 || nextTokenCharCode === 46) break; + } + case 82: { + if (!(this.optionFlags & 8) && !topLevel) this.raise(Errors.UnexpectedImportExport, this.state.startLoc); + this.next(); + let result$1; + if (startType === 83) result$1 = this.parseImport(node); + else result$1 = this.parseExport(node, decorators); + this.assertModuleNodeAllowed(result$1); + return result$1; + } + default: if (this.isAsyncFunction()) { + if (!allowDeclaration) this.raise(Errors.AsyncFunctionInSingleStatementContext, this.state.startLoc); + this.next(); + return this.parseFunctionStatement(node, true, !allowDeclaration && allowFunctionDeclaration); + } + } + const maybeName = this.state.value; + const expr = this.parseExpression(); + if (tokenIsIdentifier(startType) && expr.type === "Identifier" && this.eat(14)) return this.parseLabeledStatement(node, maybeName, expr, flags); + else return this.parseExpressionStatement(node, expr, decorators); + } + assertModuleNodeAllowed(node) { + if (!(this.optionFlags & 8) && !this.inModule) this.raise(Errors.ImportOutsideModule, node); + } + decoratorsEnabledBeforeExport() { + if (this.hasPlugin("decorators-legacy")) return true; + return this.hasPlugin("decorators") && this.getPluginOption("decorators", "decoratorsBeforeExport") !== false; + } + maybeTakeDecorators(maybeDecorators, classNode, exportNode) { + if (maybeDecorators) { + var _classNode$decorators; + if ((_classNode$decorators = classNode.decorators) != null && _classNode$decorators.length) { + if (typeof this.getPluginOption("decorators", "decoratorsBeforeExport") !== "boolean") this.raise(Errors.DecoratorsBeforeAfterExport, classNode.decorators[0]); + classNode.decorators.unshift(...maybeDecorators); + } else classNode.decorators = maybeDecorators; + this.resetStartLocationFromNode(classNode, maybeDecorators[0]); + if (exportNode) this.resetStartLocationFromNode(exportNode, classNode); + } + return classNode; + } + canHaveLeadingDecorator() { + return this.match(80); + } + parseDecorators(allowExport) { + const decorators = []; + do + decorators.push(this.parseDecorator()); + while (this.match(26)); + if (this.match(82)) { + if (!allowExport) this.unexpected(); + if (!this.decoratorsEnabledBeforeExport()) this.raise(Errors.DecoratorExportClass, this.state.startLoc); + } else if (!this.canHaveLeadingDecorator()) throw this.raise(Errors.UnexpectedLeadingDecorator, this.state.startLoc); + return decorators; + } + parseDecorator() { + this.expectOnePlugin(["decorators", "decorators-legacy"]); + const node = this.startNode(); + this.next(); + if (this.hasPlugin("decorators")) { + const startLoc = this.state.startLoc; + let expr; + if (this.match(10)) { + const startLoc$1 = this.state.startLoc; + this.next(); + expr = this.parseExpression(); + this.expect(11); + expr = this.wrapParenthesis(startLoc$1, expr); + const paramsStartLoc = this.state.startLoc; + node.expression = this.parseMaybeDecoratorArguments(expr, startLoc$1); + if (this.getPluginOption("decorators", "allowCallParenthesized") === false && node.expression !== expr) this.raise(Errors.DecoratorArgumentsOutsideParentheses, paramsStartLoc); + } else { + expr = this.parseIdentifier(false); + while (this.eat(16)) { + const node$1 = this.startNodeAt(startLoc); + node$1.object = expr; + if (this.match(139)) { + this.classScope.usePrivateName(this.state.value, this.state.startLoc); + node$1.property = this.parsePrivateName(); + } else node$1.property = this.parseIdentifier(true); + node$1.computed = false; + expr = this.finishNode(node$1, "MemberExpression"); + } + node.expression = this.parseMaybeDecoratorArguments(expr, startLoc); + } + } else node.expression = this.parseExprSubscripts(); + return this.finishNode(node, "Decorator"); + } + parseMaybeDecoratorArguments(expr, startLoc) { + if (this.eat(10)) { + const node = this.startNodeAt(startLoc); + node.callee = expr; + node.arguments = this.parseCallExpressionArguments(11); + this.toReferencedList(node.arguments); + return this.finishNode(node, "CallExpression"); + } + return expr; + } + parseBreakContinueStatement(node, isBreak) { + this.next(); + if (this.isLineTerminator()) node.label = null; + else { + node.label = this.parseIdentifier(); + this.semicolon(); + } + this.verifyBreakContinue(node, isBreak); + return this.finishNode(node, isBreak ? "BreakStatement" : "ContinueStatement"); + } + verifyBreakContinue(node, isBreak) { + let i$5; + for (i$5 = 0; i$5 < this.state.labels.length; ++i$5) { + const lab = this.state.labels[i$5]; + if (node.label == null || lab.name === node.label.name) { + if (lab.kind != null && (isBreak || lab.kind === 1)) break; + if (node.label && isBreak) break; + } + } + if (i$5 === this.state.labels.length) { + const type = isBreak ? "BreakStatement" : "ContinueStatement"; + this.raise(Errors.IllegalBreakContinue, node, { type }); + } + } + parseDebuggerStatement(node) { + this.next(); + this.semicolon(); + return this.finishNode(node, "DebuggerStatement"); + } + parseHeaderExpression() { + this.expect(10); + const val = this.parseExpression(); + this.expect(11); + return val; + } + parseDoWhileStatement(node) { + this.next(); + this.state.labels.push(loopLabel); + node.body = this.withSmartMixTopicForbiddingContext(() => this.parseStatement()); + this.state.labels.pop(); + this.expect(92); + node.test = this.parseHeaderExpression(); + this.eat(13); + return this.finishNode(node, "DoWhileStatement"); + } + parseForStatement(node) { + this.next(); + this.state.labels.push(loopLabel); + let awaitAt = null; + if (this.isContextual(96) && this.recordAwaitIfAllowed()) { + awaitAt = this.state.startLoc; + this.next(); + } + this.scope.enter(0); + this.expect(10); + if (this.match(13)) { + if (awaitAt !== null) this.unexpected(awaitAt); + return this.parseFor(node, null); + } + const startsWithLet = this.isContextual(100); + { + const startsWithAwaitUsing = this.isContextual(96) && this.startsAwaitUsing(); + const starsWithUsingDeclaration = startsWithAwaitUsing || this.isContextual(107) && this.startsUsingForOf(); + const isLetOrUsing = startsWithLet && this.hasFollowingBindingAtom() || starsWithUsingDeclaration; + if (this.match(74) || this.match(75) || isLetOrUsing) { + const initNode = this.startNode(); + let kind; + if (startsWithAwaitUsing) { + kind = "await using"; + if (!this.recordAwaitIfAllowed()) this.raise(Errors.AwaitUsingNotInAsyncContext, this.state.startLoc); + this.next(); + } else kind = this.state.value; + this.next(); + this.parseVar(initNode, true, kind); + const init$1 = this.finishNode(initNode, "VariableDeclaration"); + const isForIn = this.match(58); + if (isForIn && starsWithUsingDeclaration) this.raise(Errors.ForInUsing, init$1); + if ((isForIn || this.isContextual(102)) && init$1.declarations.length === 1) return this.parseForIn(node, init$1, awaitAt); + if (awaitAt !== null) this.unexpected(awaitAt); + return this.parseFor(node, init$1); + } + } + const startsWithAsync = this.isContextual(95); + const refExpressionErrors = new ExpressionErrors(); + const init = this.parseExpression(true, refExpressionErrors); + const isForOf = this.isContextual(102); + if (isForOf) { + if (startsWithLet) this.raise(Errors.ForOfLet, init); + if (awaitAt === null && startsWithAsync && init.type === "Identifier") this.raise(Errors.ForOfAsync, init); + } + if (isForOf || this.match(58)) { + this.checkDestructuringPrivate(refExpressionErrors); + this.toAssignable(init, true); + const type = isForOf ? "ForOfStatement" : "ForInStatement"; + this.checkLVal(init, { type }); + return this.parseForIn(node, init, awaitAt); + } else this.checkExpressionErrors(refExpressionErrors, true); + if (awaitAt !== null) this.unexpected(awaitAt); + return this.parseFor(node, init); + } + parseFunctionStatement(node, isAsync, isHangingDeclaration) { + this.next(); + return this.parseFunction(node, 1 | (isHangingDeclaration ? 2 : 0) | (isAsync ? 8 : 0)); + } + parseIfStatement(node) { + this.next(); + node.test = this.parseHeaderExpression(); + node.consequent = this.parseStatementOrSloppyAnnexBFunctionDeclaration(); + node.alternate = this.eat(66) ? this.parseStatementOrSloppyAnnexBFunctionDeclaration() : null; + return this.finishNode(node, "IfStatement"); + } + parseReturnStatement(node) { + if (!this.prodParam.hasReturn && !(this.optionFlags & 2)) this.raise(Errors.IllegalReturn, this.state.startLoc); + this.next(); + if (this.isLineTerminator()) node.argument = null; + else { + node.argument = this.parseExpression(); + this.semicolon(); + } + return this.finishNode(node, "ReturnStatement"); + } + parseSwitchStatement(node) { + this.next(); + node.discriminant = this.parseHeaderExpression(); + const cases = node.cases = []; + this.expect(5); + this.state.labels.push(switchLabel); + this.scope.enter(0); + let cur; + for (let sawDefault; !this.match(8);) if (this.match(61) || this.match(65)) { + const isCase = this.match(61); + if (cur) this.finishNode(cur, "SwitchCase"); + cases.push(cur = this.startNode()); + cur.consequent = []; + this.next(); + if (isCase) cur.test = this.parseExpression(); + else { + if (sawDefault) this.raise(Errors.MultipleDefaultsInSwitch, this.state.lastTokStartLoc); + sawDefault = true; + cur.test = null; + } + this.expect(14); + } else if (cur) cur.consequent.push(this.parseStatementListItem()); + else this.unexpected(); + this.scope.exit(); + if (cur) this.finishNode(cur, "SwitchCase"); + this.next(); + this.state.labels.pop(); + return this.finishNode(node, "SwitchStatement"); + } + parseThrowStatement(node) { + this.next(); + if (this.hasPrecedingLineBreak()) this.raise(Errors.NewlineAfterThrow, this.state.lastTokEndLoc); + node.argument = this.parseExpression(); + this.semicolon(); + return this.finishNode(node, "ThrowStatement"); + } + parseCatchClauseParam() { + const param = this.parseBindingAtom(); + this.scope.enter(this.options.annexB && param.type === "Identifier" ? 8 : 0); + this.checkLVal(param, { type: "CatchClause" }, 9); + return param; + } + parseTryStatement(node) { + this.next(); + node.block = this.parseBlock(); + node.handler = null; + if (this.match(62)) { + const clause = this.startNode(); + this.next(); + if (this.match(10)) { + this.expect(10); + clause.param = this.parseCatchClauseParam(); + this.expect(11); + } else { + clause.param = null; + this.scope.enter(0); + } + clause.body = this.withSmartMixTopicForbiddingContext(() => this.parseBlock(false, false)); + this.scope.exit(); + node.handler = this.finishNode(clause, "CatchClause"); + } + node.finalizer = this.eat(67) ? this.parseBlock() : null; + if (!node.handler && !node.finalizer) this.raise(Errors.NoCatchOrFinally, node); + return this.finishNode(node, "TryStatement"); + } + parseVarStatement(node, kind, allowMissingInitializer = false) { + this.next(); + this.parseVar(node, false, kind, allowMissingInitializer); + this.semicolon(); + return this.finishNode(node, "VariableDeclaration"); + } + parseWhileStatement(node) { + this.next(); + node.test = this.parseHeaderExpression(); + this.state.labels.push(loopLabel); + node.body = this.withSmartMixTopicForbiddingContext(() => this.parseStatement()); + this.state.labels.pop(); + return this.finishNode(node, "WhileStatement"); + } + parseWithStatement(node) { + if (this.state.strict) this.raise(Errors.StrictWith, this.state.startLoc); + this.next(); + node.object = this.parseHeaderExpression(); + node.body = this.withSmartMixTopicForbiddingContext(() => this.parseStatement()); + return this.finishNode(node, "WithStatement"); + } + parseEmptyStatement(node) { + this.next(); + return this.finishNode(node, "EmptyStatement"); + } + parseLabeledStatement(node, maybeName, expr, flags) { + for (const label of this.state.labels) if (label.name === maybeName) this.raise(Errors.LabelRedeclaration, expr, { labelName: maybeName }); + const kind = tokenIsLoop(this.state.type) ? 1 : this.match(71) ? 2 : null; + for (let i$5 = this.state.labels.length - 1; i$5 >= 0; i$5--) { + const label = this.state.labels[i$5]; + if (label.statementStart === node.start) { + label.statementStart = this.sourceToOffsetPos(this.state.start); + label.kind = kind; + } else break; + } + this.state.labels.push({ + name: maybeName, + kind, + statementStart: this.sourceToOffsetPos(this.state.start) + }); + node.body = flags & 8 ? this.parseStatementOrSloppyAnnexBFunctionDeclaration(true) : this.parseStatement(); + this.state.labels.pop(); + node.label = expr; + return this.finishNode(node, "LabeledStatement"); + } + parseExpressionStatement(node, expr, decorators) { + node.expression = expr; + this.semicolon(); + return this.finishNode(node, "ExpressionStatement"); + } + parseBlock(allowDirectives = false, createNewLexicalScope = true, afterBlockParse) { + const node = this.startNode(); + if (allowDirectives) this.state.strictErrors.clear(); + this.expect(5); + if (createNewLexicalScope) this.scope.enter(0); + this.parseBlockBody(node, allowDirectives, false, 8, afterBlockParse); + if (createNewLexicalScope) this.scope.exit(); + return this.finishNode(node, "BlockStatement"); + } + isValidDirective(stmt) { + return stmt.type === "ExpressionStatement" && stmt.expression.type === "StringLiteral" && !stmt.expression.extra.parenthesized; + } + parseBlockBody(node, allowDirectives, topLevel, end, afterBlockParse) { + const body = node.body = []; + const directives = node.directives = []; + this.parseBlockOrModuleBlockBody(body, allowDirectives ? directives : void 0, topLevel, end, afterBlockParse); + } + parseBlockOrModuleBlockBody(body, directives, topLevel, end, afterBlockParse) { + const oldStrict = this.state.strict; + let hasStrictModeDirective = false; + let parsedNonDirective = false; + while (!this.match(end)) { + const stmt = topLevel ? this.parseModuleItem() : this.parseStatementListItem(); + if (directives && !parsedNonDirective) { + if (this.isValidDirective(stmt)) { + const directive$1 = this.stmtToDirective(stmt); + directives.push(directive$1); + if (!hasStrictModeDirective && directive$1.value.value === "use strict") { + hasStrictModeDirective = true; + this.setStrict(true); + } + continue; + } + parsedNonDirective = true; + this.state.strictErrors.clear(); + } + body.push(stmt); + } + afterBlockParse?.call(this, hasStrictModeDirective); + if (!oldStrict) this.setStrict(false); + this.next(); + } + parseFor(node, init) { + node.init = init; + this.semicolon(false); + node.test = this.match(13) ? null : this.parseExpression(); + this.semicolon(false); + node.update = this.match(11) ? null : this.parseExpression(); + this.expect(11); + node.body = this.withSmartMixTopicForbiddingContext(() => this.parseStatement()); + this.scope.exit(); + this.state.labels.pop(); + return this.finishNode(node, "ForStatement"); + } + parseForIn(node, init, awaitAt) { + const isForIn = this.match(58); + this.next(); + if (isForIn) { + if (awaitAt !== null) this.unexpected(awaitAt); + } else node.await = awaitAt !== null; + if (init.type === "VariableDeclaration" && init.declarations[0].init != null && (!isForIn || !this.options.annexB || this.state.strict || init.kind !== "var" || init.declarations[0].id.type !== "Identifier")) this.raise(Errors.ForInOfLoopInitializer, init, { type: isForIn ? "ForInStatement" : "ForOfStatement" }); + if (init.type === "AssignmentPattern") this.raise(Errors.InvalidLhs, init, { ancestor: { type: "ForStatement" } }); + node.left = init; + node.right = isForIn ? this.parseExpression() : this.parseMaybeAssignAllowIn(); + this.expect(11); + node.body = this.withSmartMixTopicForbiddingContext(() => this.parseStatement()); + this.scope.exit(); + this.state.labels.pop(); + return this.finishNode(node, isForIn ? "ForInStatement" : "ForOfStatement"); + } + parseVar(node, isFor$2, kind, allowMissingInitializer = false) { + const declarations = node.declarations = []; + node.kind = kind; + for (;;) { + const decl$1 = this.startNode(); + this.parseVarId(decl$1, kind); + decl$1.init = !this.eat(29) ? null : isFor$2 ? this.parseMaybeAssignDisallowIn() : this.parseMaybeAssignAllowIn(); + if (decl$1.init === null && !allowMissingInitializer) { + if (decl$1.id.type !== "Identifier" && !(isFor$2 && (this.match(58) || this.isContextual(102)))) this.raise(Errors.DeclarationMissingInitializer, this.state.lastTokEndLoc, { kind: "destructuring" }); + else if ((kind === "const" || kind === "using" || kind === "await using") && !(this.match(58) || this.isContextual(102))) this.raise(Errors.DeclarationMissingInitializer, this.state.lastTokEndLoc, { kind }); + } + declarations.push(this.finishNode(decl$1, "VariableDeclarator")); + if (!this.eat(12)) break; + } + return node; + } + parseVarId(decl$1, kind) { + const id$4 = this.parseBindingAtom(); + if (kind === "using" || kind === "await using") { + if (id$4.type === "ArrayPattern" || id$4.type === "ObjectPattern") this.raise(Errors.UsingDeclarationHasBindingPattern, id$4.loc.start); + } + this.checkLVal(id$4, { type: "VariableDeclarator" }, kind === "var" ? 5 : 8201); + decl$1.id = id$4; + } + parseAsyncFunctionExpression(node) { + return this.parseFunction(node, 8); + } + parseFunction(node, flags = 0) { + const hangingDeclaration = flags & 2; + const isDeclaration$1 = !!(flags & 1); + const requireId = isDeclaration$1 && !(flags & 4); + const isAsync = !!(flags & 8); + this.initFunction(node, isAsync); + if (this.match(55)) { + if (hangingDeclaration) this.raise(Errors.GeneratorInSingleStatementContext, this.state.startLoc); + this.next(); + node.generator = true; + } + if (isDeclaration$1) node.id = this.parseFunctionId(requireId); + const oldMaybeInArrowParameters = this.state.maybeInArrowParameters; + this.state.maybeInArrowParameters = false; + this.scope.enter(2); + this.prodParam.enter(functionFlags(isAsync, node.generator)); + if (!isDeclaration$1) node.id = this.parseFunctionId(); + this.parseFunctionParams(node, false); + this.withSmartMixTopicForbiddingContext(() => { + this.parseFunctionBodyAndFinish(node, isDeclaration$1 ? "FunctionDeclaration" : "FunctionExpression"); + }); + this.prodParam.exit(); + this.scope.exit(); + if (isDeclaration$1 && !hangingDeclaration) this.registerFunctionStatementId(node); + this.state.maybeInArrowParameters = oldMaybeInArrowParameters; + return node; + } + parseFunctionId(requireId) { + return requireId || tokenIsIdentifier(this.state.type) ? this.parseIdentifier() : null; + } + parseFunctionParams(node, isConstructor) { + this.expect(10); + this.expressionScope.enter(newParameterDeclarationScope()); + node.params = this.parseBindingList(11, 41, 2 | (isConstructor ? 4 : 0)); + this.expressionScope.exit(); + } + registerFunctionStatementId(node) { + if (!node.id) return; + this.scope.declareName(node.id.name, !this.options.annexB || this.state.strict || node.generator || node.async ? this.scope.treatFunctionsAsVar ? 5 : 8201 : 17, node.id.loc.start); + } + parseClass(node, isStatement$10, optionalId) { + this.next(); + const oldStrict = this.state.strict; + this.state.strict = true; + this.parseClassId(node, isStatement$10, optionalId); + this.parseClassSuper(node); + node.body = this.parseClassBody(!!node.superClass, oldStrict); + return this.finishNode(node, isStatement$10 ? "ClassDeclaration" : "ClassExpression"); + } + isClassProperty() { + return this.match(29) || this.match(13) || this.match(8); + } + isClassMethod() { + return this.match(10); + } + nameIsConstructor(key) { + return key.type === "Identifier" && key.name === "constructor" || key.type === "StringLiteral" && key.value === "constructor"; + } + isNonstaticConstructor(method) { + return !method.computed && !method.static && this.nameIsConstructor(method.key); + } + parseClassBody(hadSuperClass, oldStrict) { + this.classScope.enter(); + const state = { + hadConstructor: false, + hadSuperClass + }; + let decorators = []; + const classBody$1 = this.startNode(); + classBody$1.body = []; + this.expect(5); + this.withSmartMixTopicForbiddingContext(() => { + while (!this.match(8)) { + if (this.eat(13)) { + if (decorators.length > 0) throw this.raise(Errors.DecoratorSemicolon, this.state.lastTokEndLoc); + continue; + } + if (this.match(26)) { + decorators.push(this.parseDecorator()); + continue; + } + const member = this.startNode(); + if (decorators.length) { + member.decorators = decorators; + this.resetStartLocationFromNode(member, decorators[0]); + decorators = []; + } + this.parseClassMember(classBody$1, member, state); + if (member.kind === "constructor" && member.decorators && member.decorators.length > 0) this.raise(Errors.DecoratorConstructor, member); + } + }); + this.state.strict = oldStrict; + this.next(); + if (decorators.length) throw this.raise(Errors.TrailingDecorator, this.state.startLoc); + this.classScope.exit(); + return this.finishNode(classBody$1, "ClassBody"); + } + parseClassMemberFromModifier(classBody$1, member) { + const key = this.parseIdentifier(true); + if (this.isClassMethod()) { + const method = member; + method.kind = "method"; + method.computed = false; + method.key = key; + method.static = false; + this.pushClassMethod(classBody$1, method, false, false, false, false); + return true; + } else if (this.isClassProperty()) { + const prop = member; + prop.computed = false; + prop.key = key; + prop.static = false; + classBody$1.body.push(this.parseClassProperty(prop)); + return true; + } + this.resetPreviousNodeTrailingComments(key); + return false; + } + parseClassMember(classBody$1, member, state) { + const isStatic$1 = this.isContextual(106); + if (isStatic$1) { + if (this.parseClassMemberFromModifier(classBody$1, member)) return; + if (this.eat(5)) { + this.parseClassStaticBlock(classBody$1, member); + return; + } + } + this.parseClassMemberWithIsStatic(classBody$1, member, state, isStatic$1); + } + parseClassMemberWithIsStatic(classBody$1, member, state, isStatic$1) { + const publicMethod = member; + const privateMethod = member; + const publicProp = member; + const privateProp = member; + const accessorProp = member; + const method = publicMethod; + const publicMember = publicMethod; + member.static = isStatic$1; + this.parsePropertyNamePrefixOperator(member); + if (this.eat(55)) { + method.kind = "method"; + const isPrivateName$2 = this.match(139); + this.parseClassElementName(method); + if (isPrivateName$2) { + this.pushClassPrivateMethod(classBody$1, privateMethod, true, false); + return; + } + if (this.isNonstaticConstructor(publicMethod)) this.raise(Errors.ConstructorIsGenerator, publicMethod.key); + this.pushClassMethod(classBody$1, publicMethod, true, false, false, false); + return; + } + const isContextual = !this.state.containsEsc && tokenIsIdentifier(this.state.type); + const key = this.parseClassElementName(member); + const maybeContextualKw = isContextual ? key.name : null; + const isPrivate$1 = this.isPrivateName(key); + const maybeQuestionTokenStartLoc = this.state.startLoc; + this.parsePostMemberNameModifiers(publicMember); + if (this.isClassMethod()) { + method.kind = "method"; + if (isPrivate$1) { + this.pushClassPrivateMethod(classBody$1, privateMethod, false, false); + return; + } + const isConstructor = this.isNonstaticConstructor(publicMethod); + let allowsDirectSuper = false; + if (isConstructor) { + publicMethod.kind = "constructor"; + if (state.hadConstructor && !this.hasPlugin("typescript")) this.raise(Errors.DuplicateConstructor, key); + if (isConstructor && this.hasPlugin("typescript") && member.override) this.raise(Errors.OverrideOnConstructor, key); + state.hadConstructor = true; + allowsDirectSuper = state.hadSuperClass; + } + this.pushClassMethod(classBody$1, publicMethod, false, false, isConstructor, allowsDirectSuper); + } else if (this.isClassProperty()) if (isPrivate$1) this.pushClassPrivateProperty(classBody$1, privateProp); + else this.pushClassProperty(classBody$1, publicProp); + else if (maybeContextualKw === "async" && !this.isLineTerminator()) { + this.resetPreviousNodeTrailingComments(key); + const isGenerator = this.eat(55); + if (publicMember.optional) this.unexpected(maybeQuestionTokenStartLoc); + method.kind = "method"; + const isPrivate$2 = this.match(139); + this.parseClassElementName(method); + this.parsePostMemberNameModifiers(publicMember); + if (isPrivate$2) this.pushClassPrivateMethod(classBody$1, privateMethod, isGenerator, true); + else { + if (this.isNonstaticConstructor(publicMethod)) this.raise(Errors.ConstructorIsAsync, publicMethod.key); + this.pushClassMethod(classBody$1, publicMethod, isGenerator, true, false, false); + } + } else if ((maybeContextualKw === "get" || maybeContextualKw === "set") && !(this.match(55) && this.isLineTerminator())) { + this.resetPreviousNodeTrailingComments(key); + method.kind = maybeContextualKw; + const isPrivate$2 = this.match(139); + this.parseClassElementName(publicMethod); + if (isPrivate$2) this.pushClassPrivateMethod(classBody$1, privateMethod, false, false); + else { + if (this.isNonstaticConstructor(publicMethod)) this.raise(Errors.ConstructorIsAccessor, publicMethod.key); + this.pushClassMethod(classBody$1, publicMethod, false, false, false, false); + } + this.checkGetterSetterParams(publicMethod); + } else if (maybeContextualKw === "accessor" && !this.isLineTerminator()) { + this.expectPlugin("decoratorAutoAccessors"); + this.resetPreviousNodeTrailingComments(key); + const isPrivate$2 = this.match(139); + this.parseClassElementName(publicProp); + this.pushClassAccessorProperty(classBody$1, accessorProp, isPrivate$2); + } else if (this.isLineTerminator()) if (isPrivate$1) this.pushClassPrivateProperty(classBody$1, privateProp); + else this.pushClassProperty(classBody$1, publicProp); + else this.unexpected(); + } + parseClassElementName(member) { + const { type, value } = this.state; + if ((type === 132 || type === 134) && member.static && value === "prototype") this.raise(Errors.StaticPrototype, this.state.startLoc); + if (type === 139) { + if (value === "constructor") this.raise(Errors.ConstructorClassPrivateField, this.state.startLoc); + const key = this.parsePrivateName(); + member.key = key; + return key; + } + this.parsePropertyName(member); + return member.key; + } + parseClassStaticBlock(classBody$1, member) { + var _member$decorators; + this.scope.enter(208); + const oldLabels = this.state.labels; + this.state.labels = []; + this.prodParam.enter(0); + const body = member.body = []; + this.parseBlockOrModuleBlockBody(body, void 0, false, 8); + this.prodParam.exit(); + this.scope.exit(); + this.state.labels = oldLabels; + classBody$1.body.push(this.finishNode(member, "StaticBlock")); + if ((_member$decorators = member.decorators) != null && _member$decorators.length) this.raise(Errors.DecoratorStaticBlock, member); + } + pushClassProperty(classBody$1, prop) { + if (!prop.computed && this.nameIsConstructor(prop.key)) this.raise(Errors.ConstructorClassField, prop.key); + classBody$1.body.push(this.parseClassProperty(prop)); + } + pushClassPrivateProperty(classBody$1, prop) { + const node = this.parseClassPrivateProperty(prop); + classBody$1.body.push(node); + this.classScope.declarePrivateName(this.getPrivateNameSV(node.key), 0, node.key.loc.start); + } + pushClassAccessorProperty(classBody$1, prop, isPrivate$1) { + if (!isPrivate$1 && !prop.computed && this.nameIsConstructor(prop.key)) this.raise(Errors.ConstructorClassField, prop.key); + const node = this.parseClassAccessorProperty(prop); + classBody$1.body.push(node); + if (isPrivate$1) this.classScope.declarePrivateName(this.getPrivateNameSV(node.key), 0, node.key.loc.start); + } + pushClassMethod(classBody$1, method, isGenerator, isAsync, isConstructor, allowsDirectSuper) { + classBody$1.body.push(this.parseMethod(method, isGenerator, isAsync, isConstructor, allowsDirectSuper, "ClassMethod", true)); + } + pushClassPrivateMethod(classBody$1, method, isGenerator, isAsync) { + const node = this.parseMethod(method, isGenerator, isAsync, false, false, "ClassPrivateMethod", true); + classBody$1.body.push(node); + const kind = node.kind === "get" ? node.static ? 6 : 2 : node.kind === "set" ? node.static ? 5 : 1 : 0; + this.declareClassPrivateMethodInScope(node, kind); + } + declareClassPrivateMethodInScope(node, kind) { + this.classScope.declarePrivateName(this.getPrivateNameSV(node.key), kind, node.key.loc.start); + } + parsePostMemberNameModifiers(methodOrProp) {} + parseClassPrivateProperty(node) { + this.parseInitializer(node); + this.semicolon(); + return this.finishNode(node, "ClassPrivateProperty"); + } + parseClassProperty(node) { + this.parseInitializer(node); + this.semicolon(); + return this.finishNode(node, "ClassProperty"); + } + parseClassAccessorProperty(node) { + this.parseInitializer(node); + this.semicolon(); + return this.finishNode(node, "ClassAccessorProperty"); + } + parseInitializer(node) { + this.scope.enter(80); + this.expressionScope.enter(newExpressionScope()); + this.prodParam.enter(0); + node.value = this.eat(29) ? this.parseMaybeAssignAllowIn() : null; + this.expressionScope.exit(); + this.prodParam.exit(); + this.scope.exit(); + } + parseClassId(node, isStatement$10, optionalId, bindingType = 8331) { + if (tokenIsIdentifier(this.state.type)) { + node.id = this.parseIdentifier(); + if (isStatement$10) this.declareNameFromIdentifier(node.id, bindingType); + } else if (optionalId || !isStatement$10) node.id = null; + else throw this.raise(Errors.MissingClassName, this.state.startLoc); + } + parseClassSuper(node) { + node.superClass = this.eat(81) ? this.parseExprSubscripts() : null; + } + parseExport(node, decorators) { + const maybeDefaultIdentifier = this.parseMaybeImportPhase(node, true); + const hasDefault = this.maybeParseExportDefaultSpecifier(node, maybeDefaultIdentifier); + const parseAfterDefault = !hasDefault || this.eat(12); + const hasStar = parseAfterDefault && this.eatExportStar(node); + const hasNamespace = hasStar && this.maybeParseExportNamespaceSpecifier(node); + const parseAfterNamespace = parseAfterDefault && (!hasNamespace || this.eat(12)); + const isFromRequired = hasDefault || hasStar; + if (hasStar && !hasNamespace) { + if (hasDefault) this.unexpected(); + if (decorators) throw this.raise(Errors.UnsupportedDecoratorExport, node); + this.parseExportFrom(node, true); + this.sawUnambiguousESM = true; + return this.finishNode(node, "ExportAllDeclaration"); + } + const hasSpecifiers = this.maybeParseExportNamedSpecifiers(node); + if (hasDefault && parseAfterDefault && !hasStar && !hasSpecifiers) this.unexpected(null, 5); + if (hasNamespace && parseAfterNamespace) this.unexpected(null, 98); + let hasDeclaration; + if (isFromRequired || hasSpecifiers) { + hasDeclaration = false; + if (decorators) throw this.raise(Errors.UnsupportedDecoratorExport, node); + this.parseExportFrom(node, isFromRequired); + } else hasDeclaration = this.maybeParseExportDeclaration(node); + if (isFromRequired || hasSpecifiers || hasDeclaration) { + var _node2$declaration; + const node2 = node; + this.checkExport(node2, true, false, !!node2.source); + if (((_node2$declaration = node2.declaration) == null ? void 0 : _node2$declaration.type) === "ClassDeclaration") this.maybeTakeDecorators(decorators, node2.declaration, node2); + else if (decorators) throw this.raise(Errors.UnsupportedDecoratorExport, node); + this.sawUnambiguousESM = true; + return this.finishNode(node2, "ExportNamedDeclaration"); + } + if (this.eat(65)) { + const node2 = node; + const decl$1 = this.parseExportDefaultExpression(); + node2.declaration = decl$1; + if (decl$1.type === "ClassDeclaration") this.maybeTakeDecorators(decorators, decl$1, node2); + else if (decorators) throw this.raise(Errors.UnsupportedDecoratorExport, node); + this.checkExport(node2, true, true); + this.sawUnambiguousESM = true; + return this.finishNode(node2, "ExportDefaultDeclaration"); + } + this.unexpected(null, 5); + } + eatExportStar(node) { + return this.eat(55); + } + maybeParseExportDefaultSpecifier(node, maybeDefaultIdentifier) { + if (maybeDefaultIdentifier || this.isExportDefaultSpecifier()) { + this.expectPlugin("exportDefaultFrom", maybeDefaultIdentifier == null ? void 0 : maybeDefaultIdentifier.loc.start); + const id$4 = maybeDefaultIdentifier || this.parseIdentifier(true); + const specifier = this.startNodeAtNode(id$4); + specifier.exported = id$4; + node.specifiers = [this.finishNode(specifier, "ExportDefaultSpecifier")]; + return true; + } + return false; + } + maybeParseExportNamespaceSpecifier(node) { + if (this.isContextual(93)) { + var _ref, _ref$specifiers; + (_ref$specifiers = (_ref = node).specifiers) != null || (_ref.specifiers = []); + const specifier = this.startNodeAt(this.state.lastTokStartLoc); + this.next(); + specifier.exported = this.parseModuleExportName(); + node.specifiers.push(this.finishNode(specifier, "ExportNamespaceSpecifier")); + return true; + } + return false; + } + maybeParseExportNamedSpecifiers(node) { + if (this.match(5)) { + const node2 = node; + if (!node2.specifiers) node2.specifiers = []; + const isTypeExport = node2.exportKind === "type"; + node2.specifiers.push(...this.parseExportSpecifiers(isTypeExport)); + node2.source = null; + if (this.hasPlugin("importAssertions")) node2.assertions = []; + else node2.attributes = []; + node2.declaration = null; + return true; + } + return false; + } + maybeParseExportDeclaration(node) { + if (this.shouldParseExportDeclaration()) { + node.specifiers = []; + node.source = null; + if (this.hasPlugin("importAssertions")) node.assertions = []; + else node.attributes = []; + node.declaration = this.parseExportDeclaration(node); + return true; + } + return false; + } + isAsyncFunction() { + if (!this.isContextual(95)) return false; + const next = this.nextTokenInLineStart(); + return this.isUnparsedContextual(next, "function"); + } + parseExportDefaultExpression() { + const expr = this.startNode(); + if (this.match(68)) { + this.next(); + return this.parseFunction(expr, 5); + } else if (this.isAsyncFunction()) { + this.next(); + this.next(); + return this.parseFunction(expr, 13); + } + if (this.match(80)) return this.parseClass(expr, true, true); + if (this.match(26)) { + if (this.hasPlugin("decorators") && this.getPluginOption("decorators", "decoratorsBeforeExport") === true) this.raise(Errors.DecoratorBeforeExport, this.state.startLoc); + return this.parseClass(this.maybeTakeDecorators(this.parseDecorators(false), this.startNode()), true, true); + } + if (this.match(75) || this.match(74) || this.isLet()) throw this.raise(Errors.UnsupportedDefaultExport, this.state.startLoc); + const res = this.parseMaybeAssignAllowIn(); + this.semicolon(); + return res; + } + parseExportDeclaration(node) { + if (this.match(80)) { + const node$1 = this.parseClass(this.startNode(), true, false); + return node$1; + } + return this.parseStatementListItem(); + } + isExportDefaultSpecifier() { + const { type } = this.state; + if (tokenIsIdentifier(type)) { + if (type === 95 && !this.state.containsEsc || type === 100) return false; + if ((type === 130 || type === 129) && !this.state.containsEsc) { + const { type: nextType } = this.lookahead(); + if (tokenIsIdentifier(nextType) && nextType !== 98 || nextType === 5) { + this.expectOnePlugin(["flow", "typescript"]); + return false; + } + } + } else if (!this.match(65)) return false; + const next = this.nextTokenStart(); + const hasFrom = this.isUnparsedContextual(next, "from"); + if (this.input.charCodeAt(next) === 44 || tokenIsIdentifier(this.state.type) && hasFrom) return true; + if (this.match(65) && hasFrom) { + const nextAfterFrom = this.input.charCodeAt(this.nextTokenStartSince(next + 4)); + return nextAfterFrom === 34 || nextAfterFrom === 39; + } + return false; + } + parseExportFrom(node, expect) { + if (this.eatContextual(98)) { + node.source = this.parseImportSource(); + this.checkExport(node); + this.maybeParseImportAttributes(node); + this.checkJSONModuleImport(node); + } else if (expect) this.unexpected(); + this.semicolon(); + } + shouldParseExportDeclaration() { + const { type } = this.state; + if (type === 26) { + this.expectOnePlugin(["decorators", "decorators-legacy"]); + if (this.hasPlugin("decorators")) { + if (this.getPluginOption("decorators", "decoratorsBeforeExport") === true) this.raise(Errors.DecoratorBeforeExport, this.state.startLoc); + return true; + } + } + if (this.isContextual(107)) { + this.raise(Errors.UsingDeclarationExport, this.state.startLoc); + return true; + } + if (this.isContextual(96) && this.startsAwaitUsing()) { + this.raise(Errors.UsingDeclarationExport, this.state.startLoc); + return true; + } + return type === 74 || type === 75 || type === 68 || type === 80 || this.isLet() || this.isAsyncFunction(); + } + checkExport(node, checkNames, isDefault, isFrom) { + if (checkNames) { + var _node$specifiers; + if (isDefault) { + this.checkDuplicateExports(node, "default"); + if (this.hasPlugin("exportDefaultFrom")) { + var _declaration$extra; + const declaration = node.declaration; + if (declaration.type === "Identifier" && declaration.name === "from" && declaration.end - declaration.start === 4 && !((_declaration$extra = declaration.extra) != null && _declaration$extra.parenthesized)) this.raise(Errors.ExportDefaultFromAsIdentifier, declaration); + } + } else if ((_node$specifiers = node.specifiers) != null && _node$specifiers.length) for (const specifier of node.specifiers) { + const { exported } = specifier; + const exportName = exported.type === "Identifier" ? exported.name : exported.value; + this.checkDuplicateExports(specifier, exportName); + if (!isFrom && specifier.local) { + const { local } = specifier; + if (local.type !== "Identifier") this.raise(Errors.ExportBindingIsString, specifier, { + localName: local.value, + exportName + }); + else { + this.checkReservedWord(local.name, local.loc.start, true, false); + this.scope.checkLocalExport(local); + } + } + } + else if (node.declaration) { + const decl$1 = node.declaration; + if (decl$1.type === "FunctionDeclaration" || decl$1.type === "ClassDeclaration") { + const { id: id$4 } = decl$1; + if (!id$4) throw new Error("Assertion failure"); + this.checkDuplicateExports(node, id$4.name); + } else if (decl$1.type === "VariableDeclaration") for (const declaration of decl$1.declarations) this.checkDeclaration(declaration.id); + } + } + } + checkDeclaration(node) { + if (node.type === "Identifier") this.checkDuplicateExports(node, node.name); + else if (node.type === "ObjectPattern") for (const prop of node.properties) this.checkDeclaration(prop); + else if (node.type === "ArrayPattern") { + for (const elem of node.elements) if (elem) this.checkDeclaration(elem); + } else if (node.type === "ObjectProperty") this.checkDeclaration(node.value); + else if (node.type === "RestElement") this.checkDeclaration(node.argument); + else if (node.type === "AssignmentPattern") this.checkDeclaration(node.left); + } + checkDuplicateExports(node, exportName) { + if (this.exportedIdentifiers.has(exportName)) if (exportName === "default") this.raise(Errors.DuplicateDefaultExport, node); + else this.raise(Errors.DuplicateExport, node, { exportName }); + this.exportedIdentifiers.add(exportName); + } + parseExportSpecifiers(isInTypeExport) { + const nodes$1 = []; + let first$1 = true; + this.expect(5); + while (!this.eat(8)) { + if (first$1) first$1 = false; + else { + this.expect(12); + if (this.eat(8)) break; + } + const isMaybeTypeOnly = this.isContextual(130); + const isString$5 = this.match(134); + const node = this.startNode(); + node.local = this.parseModuleExportName(); + nodes$1.push(this.parseExportSpecifier(node, isString$5, isInTypeExport, isMaybeTypeOnly)); + } + return nodes$1; + } + parseExportSpecifier(node, isString$5, isInTypeExport, isMaybeTypeOnly) { + if (this.eatContextual(93)) node.exported = this.parseModuleExportName(); + else if (isString$5) node.exported = cloneStringLiteral(node.local); + else if (!node.exported) node.exported = cloneIdentifier(node.local); + return this.finishNode(node, "ExportSpecifier"); + } + parseModuleExportName() { + if (this.match(134)) { + const result$1 = this.parseStringLiteral(this.state.value); + const surrogate = loneSurrogate.exec(result$1.value); + if (surrogate) this.raise(Errors.ModuleExportNameHasLoneSurrogate, result$1, { surrogateCharCode: surrogate[0].charCodeAt(0) }); + return result$1; + } + return this.parseIdentifier(true); + } + isJSONModuleImport(node) { + if (node.assertions != null) return node.assertions.some(({ key, value }) => { + return value.value === "json" && (key.type === "Identifier" ? key.name === "type" : key.value === "type"); + }); + return false; + } + checkImportReflection(node) { + const { specifiers } = node; + const singleBindingType = specifiers.length === 1 ? specifiers[0].type : null; + if (node.phase === "source") { + if (singleBindingType !== "ImportDefaultSpecifier") this.raise(Errors.SourcePhaseImportRequiresDefault, specifiers[0].loc.start); + } else if (node.phase === "defer") { + if (singleBindingType !== "ImportNamespaceSpecifier") this.raise(Errors.DeferImportRequiresNamespace, specifiers[0].loc.start); + } else if (node.module) { + var _node$assertions; + if (singleBindingType !== "ImportDefaultSpecifier") this.raise(Errors.ImportReflectionNotBinding, specifiers[0].loc.start); + if (((_node$assertions = node.assertions) == null ? void 0 : _node$assertions.length) > 0) this.raise(Errors.ImportReflectionHasAssertion, specifiers[0].loc.start); + } + } + checkJSONModuleImport(node) { + if (this.isJSONModuleImport(node) && node.type !== "ExportAllDeclaration") { + const { specifiers } = node; + if (specifiers != null) { + const nonDefaultNamedSpecifier = specifiers.find((specifier) => { + let imported; + if (specifier.type === "ExportSpecifier") imported = specifier.local; + else if (specifier.type === "ImportSpecifier") imported = specifier.imported; + if (imported !== void 0) return imported.type === "Identifier" ? imported.name !== "default" : imported.value !== "default"; + }); + if (nonDefaultNamedSpecifier !== void 0) this.raise(Errors.ImportJSONBindingNotDefault, nonDefaultNamedSpecifier.loc.start); + } + } + } + isPotentialImportPhase(isExport) { + if (isExport) return false; + return this.isContextual(105) || this.isContextual(97) || this.isContextual(127); + } + applyImportPhase(node, isExport, phase, loc) { + if (isExport) return; + if (phase === "module") { + this.expectPlugin("importReflection", loc); + node.module = true; + } else if (this.hasPlugin("importReflection")) node.module = false; + if (phase === "source") { + this.expectPlugin("sourcePhaseImports", loc); + node.phase = "source"; + } else if (phase === "defer") { + this.expectPlugin("deferredImportEvaluation", loc); + node.phase = "defer"; + } else if (this.hasPlugin("sourcePhaseImports")) node.phase = null; + } + parseMaybeImportPhase(node, isExport) { + if (!this.isPotentialImportPhase(isExport)) { + this.applyImportPhase(node, isExport, null); + return null; + } + const phaseIdentifier = this.parseIdentifier(true); + const { type } = this.state; + const isImportPhase = tokenIsKeywordOrIdentifier(type) ? type !== 98 || this.lookaheadCharCode() === 102 : type !== 12; + if (isImportPhase) { + this.resetPreviousIdentifierLeadingComments(phaseIdentifier); + this.applyImportPhase(node, isExport, phaseIdentifier.name, phaseIdentifier.loc.start); + return null; + } else { + this.applyImportPhase(node, isExport, null); + return phaseIdentifier; + } + } + isPrecedingIdImportPhase(phase) { + const { type } = this.state; + return tokenIsIdentifier(type) ? type !== 98 || this.lookaheadCharCode() === 102 : type !== 12; + } + parseImport(node) { + if (this.match(134)) return this.parseImportSourceAndAttributes(node); + return this.parseImportSpecifiersAndAfter(node, this.parseMaybeImportPhase(node, false)); + } + parseImportSpecifiersAndAfter(node, maybeDefaultIdentifier) { + node.specifiers = []; + const hasDefault = this.maybeParseDefaultImportSpecifier(node, maybeDefaultIdentifier); + const parseNext = !hasDefault || this.eat(12); + const hasStar = parseNext && this.maybeParseStarImportSpecifier(node); + if (parseNext && !hasStar) this.parseNamedImportSpecifiers(node); + this.expectContextual(98); + return this.parseImportSourceAndAttributes(node); + } + parseImportSourceAndAttributes(node) { + var _node$specifiers2; + (_node$specifiers2 = node.specifiers) != null || (node.specifiers = []); + node.source = this.parseImportSource(); + this.maybeParseImportAttributes(node); + this.checkImportReflection(node); + this.checkJSONModuleImport(node); + this.semicolon(); + this.sawUnambiguousESM = true; + return this.finishNode(node, "ImportDeclaration"); + } + parseImportSource() { + if (!this.match(134)) this.unexpected(); + return this.parseExprAtom(); + } + parseImportSpecifierLocal(node, specifier, type) { + specifier.local = this.parseIdentifier(); + node.specifiers.push(this.finishImportSpecifier(specifier, type)); + } + finishImportSpecifier(specifier, type, bindingType = 8201) { + this.checkLVal(specifier.local, { type }, bindingType); + return this.finishNode(specifier, type); + } + parseImportAttributes() { + this.expect(5); + const attrs = []; + const attrNames = new Set(); + do { + if (this.match(8)) break; + const node = this.startNode(); + const keyName = this.state.value; + if (attrNames.has(keyName)) this.raise(Errors.ModuleAttributesWithDuplicateKeys, this.state.startLoc, { key: keyName }); + attrNames.add(keyName); + if (this.match(134)) node.key = this.parseStringLiteral(keyName); + else node.key = this.parseIdentifier(true); + this.expect(14); + if (!this.match(134)) throw this.raise(Errors.ModuleAttributeInvalidValue, this.state.startLoc); + node.value = this.parseStringLiteral(this.state.value); + attrs.push(this.finishNode(node, "ImportAttribute")); + } while (this.eat(12)); + this.expect(8); + return attrs; + } + parseModuleAttributes() { + const attrs = []; + const attributes = new Set(); + do { + const node = this.startNode(); + node.key = this.parseIdentifier(true); + if (node.key.name !== "type") this.raise(Errors.ModuleAttributeDifferentFromType, node.key); + if (attributes.has(node.key.name)) this.raise(Errors.ModuleAttributesWithDuplicateKeys, node.key, { key: node.key.name }); + attributes.add(node.key.name); + this.expect(14); + if (!this.match(134)) throw this.raise(Errors.ModuleAttributeInvalidValue, this.state.startLoc); + node.value = this.parseStringLiteral(this.state.value); + attrs.push(this.finishNode(node, "ImportAttribute")); + } while (this.eat(12)); + return attrs; + } + maybeParseImportAttributes(node) { + let attributes; + var useWith = false; + if (this.match(76)) { + if (this.hasPrecedingLineBreak() && this.lookaheadCharCode() === 40) return; + this.next(); + if (this.hasPlugin("moduleAttributes")) { + attributes = this.parseModuleAttributes(); + this.addExtra(node, "deprecatedWithLegacySyntax", true); + } else attributes = this.parseImportAttributes(); + useWith = true; + } else if (this.isContextual(94) && !this.hasPrecedingLineBreak()) { + if (!this.hasPlugin("deprecatedImportAssert") && !this.hasPlugin("importAssertions")) this.raise(Errors.ImportAttributesUseAssert, this.state.startLoc); + if (!this.hasPlugin("importAssertions")) this.addExtra(node, "deprecatedAssertSyntax", true); + this.next(); + attributes = this.parseImportAttributes(); + } else attributes = []; + if (!useWith && this.hasPlugin("importAssertions")) node.assertions = attributes; + else node.attributes = attributes; + } + maybeParseDefaultImportSpecifier(node, maybeDefaultIdentifier) { + if (maybeDefaultIdentifier) { + const specifier = this.startNodeAtNode(maybeDefaultIdentifier); + specifier.local = maybeDefaultIdentifier; + node.specifiers.push(this.finishImportSpecifier(specifier, "ImportDefaultSpecifier")); + return true; + } else if (tokenIsKeywordOrIdentifier(this.state.type)) { + this.parseImportSpecifierLocal(node, this.startNode(), "ImportDefaultSpecifier"); + return true; + } + return false; + } + maybeParseStarImportSpecifier(node) { + if (this.match(55)) { + const specifier = this.startNode(); + this.next(); + this.expectContextual(93); + this.parseImportSpecifierLocal(node, specifier, "ImportNamespaceSpecifier"); + return true; + } + return false; + } + parseNamedImportSpecifiers(node) { + let first$1 = true; + this.expect(5); + while (!this.eat(8)) { + if (first$1) first$1 = false; + else { + if (this.eat(14)) throw this.raise(Errors.DestructureNamedImport, this.state.startLoc); + this.expect(12); + if (this.eat(8)) break; + } + const specifier = this.startNode(); + const importedIsString = this.match(134); + const isMaybeTypeOnly = this.isContextual(130); + specifier.imported = this.parseModuleExportName(); + const importSpecifier$1 = this.parseImportSpecifier(specifier, importedIsString, node.importKind === "type" || node.importKind === "typeof", isMaybeTypeOnly, void 0); + node.specifiers.push(importSpecifier$1); + } + } + parseImportSpecifier(specifier, importedIsString, isInTypeOnlyImport, isMaybeTypeOnly, bindingType) { + if (this.eatContextual(93)) specifier.local = this.parseIdentifier(); + else { + const { imported } = specifier; + if (importedIsString) throw this.raise(Errors.ImportBindingIsString, specifier, { importName: imported.value }); + this.checkReservedWord(imported.name, specifier.loc.start, true, true); + if (!specifier.local) specifier.local = cloneIdentifier(imported); + } + return this.finishImportSpecifier(specifier, "ImportSpecifier", bindingType); + } + isThisParam(param) { + return param.type === "Identifier" && param.name === "this"; + } + }; + var Parser$4 = class extends StatementParser { + constructor(options, input, pluginsMap) { + options = getOptions(options); + super(options, input); + this.options = options; + this.initializeScopes(); + this.plugins = pluginsMap; + this.filename = options.sourceFilename; + this.startIndex = options.startIndex; + let optionFlags = 0; + if (options.allowAwaitOutsideFunction) optionFlags |= 1; + if (options.allowReturnOutsideFunction) optionFlags |= 2; + if (options.allowImportExportEverywhere) optionFlags |= 8; + if (options.allowSuperOutsideMethod) optionFlags |= 16; + if (options.allowUndeclaredExports) optionFlags |= 64; + if (options.allowNewTargetOutsideFunction) optionFlags |= 4; + if (options.allowYieldOutsideFunction) optionFlags |= 32; + if (options.ranges) optionFlags |= 128; + if (options.tokens) optionFlags |= 256; + if (options.createImportExpressions) optionFlags |= 512; + if (options.createParenthesizedExpressions) optionFlags |= 1024; + if (options.errorRecovery) optionFlags |= 2048; + if (options.attachComment) optionFlags |= 4096; + if (options.annexB) optionFlags |= 8192; + this.optionFlags = optionFlags; + } + getScopeHandler() { + return ScopeHandler; + } + parse() { + this.enterInitialScopes(); + const file$2 = this.startNode(); + const program$3 = this.startNode(); + this.nextToken(); + file$2.errors = null; + this.parseTopLevel(file$2, program$3); + file$2.errors = this.state.errors; + file$2.comments.length = this.state.commentsLen; + return file$2; + } + }; + function parse$7(input, options) { + var _options$3; + if (((_options$3 = options) == null ? void 0 : _options$3.sourceType) === "unambiguous") { + options = Object.assign({}, options); + try { + options.sourceType = "module"; + const parser$4 = getParser(options, input); + const ast = parser$4.parse(); + if (parser$4.sawUnambiguousESM) return ast; + if (parser$4.ambiguousScriptDifferentAst) try { + options.sourceType = "script"; + return getParser(options, input).parse(); + } catch (_unused) {} + else ast.program.sourceType = "script"; + return ast; + } catch (moduleError) { + try { + options.sourceType = "script"; + return getParser(options, input).parse(); + } catch (_unused2) {} + throw moduleError; + } + } else return getParser(options, input).parse(); + } + function parseExpression(input, options) { + const parser$4 = getParser(options, input); + if (parser$4.options.strictMode) parser$4.state.strict = true; + return parser$4.getExpression(); + } + function generateExportedTokenTypes(internalTokenTypes) { + const tokenTypes$1 = {}; + for (const typeName of Object.keys(internalTokenTypes)) tokenTypes$1[typeName] = getExportedToken(internalTokenTypes[typeName]); + return tokenTypes$1; + } + const tokTypes = generateExportedTokenTypes(tt); + function getParser(options, input) { + let cls = Parser$4; + const pluginsMap = new Map(); + if (options != null && options.plugins) { + for (const plugin$2 of options.plugins) { + let name, opts; + if (typeof plugin$2 === "string") name = plugin$2; + else [name, opts] = plugin$2; + if (!pluginsMap.has(name)) pluginsMap.set(name, opts || {}); + } + validatePlugins(pluginsMap); + cls = getParserClass(pluginsMap); + } + return new cls(options, input, pluginsMap); + } + const parserClassCache = new Map(); + function getParserClass(pluginsMap) { + const pluginList = []; + for (const name of mixinPluginNames) if (pluginsMap.has(name)) pluginList.push(name); + const key = pluginList.join("|"); + let cls = parserClassCache.get(key); + if (!cls) { + cls = Parser$4; + for (const plugin$2 of pluginList) cls = mixinPlugins[plugin$2](cls); + parserClassCache.set(key, cls); + } + return cls; + } + exports.parse = parse$7; + exports.parseExpression = parseExpression; + exports.tokTypes = tokTypes; +} }); +var import_lib$2 = __toESM(require_lib$16()); + +//#endregion +//#region node_modules/estree-walker/dist/umd/estree-walker.js +var require_estree_walker = __commonJS({ "node_modules/estree-walker/dist/umd/estree-walker.js"(exports, module) { + (function(global$1, factory) { + typeof exports === "object" && typeof module !== "undefined" ? factory(exports) : typeof define === "function" && define.amd ? define(["exports"], factory) : (global$1 = global$1 || self, factory(global$1.estreeWalker = {})); + })(exports, function(exports$1) { + "use strict"; + /** @typedef { import('estree').BaseNode} BaseNode */ + /** @typedef {{ + skip: () => void; + remove: () => void; + replace: (node: BaseNode) => void; + }} WalkerContext */ + class WalkerBase { + constructor() { + /** @type {boolean} */ + this.should_skip = false; + /** @type {boolean} */ + this.should_remove = false; + /** @type {BaseNode | null} */ + this.replacement = null; + /** @type {WalkerContext} */ + this.context = { + skip: () => this.should_skip = true, + remove: () => this.should_remove = true, + replace: (node) => this.replacement = node + }; + } + /** + * + * @param {any} parent + * @param {string} prop + * @param {number} index + * @param {BaseNode} node + */ + replace(parent, prop, index$1, node) { + if (parent) if (index$1 !== null) parent[prop][index$1] = node; + else parent[prop] = node; + } + /** + * + * @param {any} parent + * @param {string} prop + * @param {number} index + */ + remove(parent, prop, index$1) { + if (parent) if (index$1 !== null) parent[prop].splice(index$1, 1); + else delete parent[prop]; + } + } + /** @typedef { import('estree').BaseNode} BaseNode */ + /** @typedef { import('./walker.js').WalkerContext} WalkerContext */ + /** @typedef {( + * this: WalkerContext, + * node: BaseNode, + * parent: BaseNode, + * key: string, + * index: number + * ) => void} SyncHandler */ + class SyncWalker extends WalkerBase { + /** + * + * @param {SyncHandler} enter + * @param {SyncHandler} leave + */ + constructor(enter, leave) { + super(); + /** @type {SyncHandler} */ + this.enter = enter; + /** @type {SyncHandler} */ + this.leave = leave; + } + /** + * + * @param {BaseNode} node + * @param {BaseNode} parent + * @param {string} [prop] + * @param {number} [index] + * @returns {BaseNode} + */ + visit(node, parent, prop, index$1) { + if (node) { + if (this.enter) { + const _should_skip = this.should_skip; + const _should_remove = this.should_remove; + const _replacement$1 = this.replacement; + this.should_skip = false; + this.should_remove = false; + this.replacement = null; + this.enter.call(this.context, node, parent, prop, index$1); + if (this.replacement) { + node = this.replacement; + this.replace(parent, prop, index$1, node); + } + if (this.should_remove) this.remove(parent, prop, index$1); + const skipped = this.should_skip; + const removed = this.should_remove; + this.should_skip = _should_skip; + this.should_remove = _should_remove; + this.replacement = _replacement$1; + if (skipped) return node; + if (removed) return null; + } + for (const key in node) { + const value = node[key]; + if (typeof value !== "object") continue; + else if (Array.isArray(value)) { + for (let i$5 = 0; i$5 < value.length; i$5 += 1) if (value[i$5] !== null && typeof value[i$5].type === "string") { + if (!this.visit(value[i$5], node, key, i$5)) i$5--; + } + } else if (value !== null && typeof value.type === "string") this.visit(value, node, key, null); + } + if (this.leave) { + const _replacement$1 = this.replacement; + const _should_remove = this.should_remove; + this.replacement = null; + this.should_remove = false; + this.leave.call(this.context, node, parent, prop, index$1); + if (this.replacement) { + node = this.replacement; + this.replace(parent, prop, index$1, node); + } + if (this.should_remove) this.remove(parent, prop, index$1); + const removed = this.should_remove; + this.replacement = _replacement$1; + this.should_remove = _should_remove; + if (removed) return null; + } + } + return node; + } + } + /** @typedef { import('estree').BaseNode} BaseNode */ + /** @typedef { import('./walker').WalkerContext} WalkerContext */ + /** @typedef {( + * this: WalkerContext, + * node: BaseNode, + * parent: BaseNode, + * key: string, + * index: number + * ) => Promise} AsyncHandler */ + class AsyncWalker extends WalkerBase { + /** + * + * @param {AsyncHandler} enter + * @param {AsyncHandler} leave + */ + constructor(enter, leave) { + super(); + /** @type {AsyncHandler} */ + this.enter = enter; + /** @type {AsyncHandler} */ + this.leave = leave; + } + /** + * + * @param {BaseNode} node + * @param {BaseNode} parent + * @param {string} [prop] + * @param {number} [index] + * @returns {Promise} + */ + async visit(node, parent, prop, index$1) { + if (node) { + if (this.enter) { + const _should_skip = this.should_skip; + const _should_remove = this.should_remove; + const _replacement$1 = this.replacement; + this.should_skip = false; + this.should_remove = false; + this.replacement = null; + await this.enter.call(this.context, node, parent, prop, index$1); + if (this.replacement) { + node = this.replacement; + this.replace(parent, prop, index$1, node); + } + if (this.should_remove) this.remove(parent, prop, index$1); + const skipped = this.should_skip; + const removed = this.should_remove; + this.should_skip = _should_skip; + this.should_remove = _should_remove; + this.replacement = _replacement$1; + if (skipped) return node; + if (removed) return null; + } + for (const key in node) { + const value = node[key]; + if (typeof value !== "object") continue; + else if (Array.isArray(value)) { + for (let i$5 = 0; i$5 < value.length; i$5 += 1) if (value[i$5] !== null && typeof value[i$5].type === "string") { + if (!await this.visit(value[i$5], node, key, i$5)) i$5--; + } + } else if (value !== null && typeof value.type === "string") await this.visit(value, node, key, null); + } + if (this.leave) { + const _replacement$1 = this.replacement; + const _should_remove = this.should_remove; + this.replacement = null; + this.should_remove = false; + await this.leave.call(this.context, node, parent, prop, index$1); + if (this.replacement) { + node = this.replacement; + this.replace(parent, prop, index$1, node); + } + if (this.should_remove) this.remove(parent, prop, index$1); + const removed = this.should_remove; + this.replacement = _replacement$1; + this.should_remove = _should_remove; + if (removed) return null; + } + } + return node; + } + } + /** @typedef { import('estree').BaseNode} BaseNode */ + /** @typedef { import('./sync.js').SyncHandler} SyncHandler */ + /** @typedef { import('./async.js').AsyncHandler} AsyncHandler */ + /** + * + * @param {BaseNode} ast + * @param {{ + * enter?: SyncHandler + * leave?: SyncHandler + * }} walker + * @returns {BaseNode} + */ + function walk$2(ast, { enter, leave }) { + const instance = new SyncWalker(enter, leave); + return instance.visit(ast, null); + } + /** + * + * @param {BaseNode} ast + * @param {{ + * enter?: AsyncHandler + * leave?: AsyncHandler + * }} walker + * @returns {Promise} + */ + async function asyncWalk(ast, { enter, leave }) { + const instance = new AsyncWalker(enter, leave); + return await instance.visit(ast, null); + } + exports$1.asyncWalk = asyncWalk; + exports$1.walk = walk$2; + Object.defineProperty(exports$1, "__esModule", { value: true }); + }); +} }); + +//#endregion +//#region node_modules/yallist/iterator.js +var require_iterator = __commonJS({ "node_modules/yallist/iterator.js"(exports, module) { + module.exports = function(Yallist$2) { + Yallist$2.prototype[Symbol.iterator] = function* () { + for (let walker = this.head; walker; walker = walker.next) yield walker.value; + }; + }; +} }); + +//#endregion +//#region node_modules/yallist/yallist.js +var require_yallist = __commonJS({ "node_modules/yallist/yallist.js"(exports, module) { + module.exports = Yallist$1; + Yallist$1.Node = Node$4; + Yallist$1.create = Yallist$1; + function Yallist$1(list$4) { + var self$1 = this; + if (!(self$1 instanceof Yallist$1)) self$1 = new Yallist$1(); + self$1.tail = null; + self$1.head = null; + self$1.length = 0; + if (list$4 && typeof list$4.forEach === "function") list$4.forEach(function(item) { + self$1.push(item); + }); + else if (arguments.length > 0) for (var i$5 = 0, l$1 = arguments.length; i$5 < l$1; i$5++) self$1.push(arguments[i$5]); + return self$1; + } + Yallist$1.prototype.removeNode = function(node) { + if (node.list !== this) throw new Error("removing node which does not belong to this list"); + var next = node.next; + var prev = node.prev; + if (next) next.prev = prev; + if (prev) prev.next = next; + if (node === this.head) this.head = next; + if (node === this.tail) this.tail = prev; + node.list.length--; + node.next = null; + node.prev = null; + node.list = null; + return next; + }; + Yallist$1.prototype.unshiftNode = function(node) { + if (node === this.head) return; + if (node.list) node.list.removeNode(node); + var head = this.head; + node.list = this; + node.next = head; + if (head) head.prev = node; + this.head = node; + if (!this.tail) this.tail = node; + this.length++; + }; + Yallist$1.prototype.pushNode = function(node) { + if (node === this.tail) return; + if (node.list) node.list.removeNode(node); + var tail = this.tail; + node.list = this; + node.prev = tail; + if (tail) tail.next = node; + this.tail = node; + if (!this.head) this.head = node; + this.length++; + }; + Yallist$1.prototype.push = function() { + for (var i$5 = 0, l$1 = arguments.length; i$5 < l$1; i$5++) push$1(this, arguments[i$5]); + return this.length; + }; + Yallist$1.prototype.unshift = function() { + for (var i$5 = 0, l$1 = arguments.length; i$5 < l$1; i$5++) unshift(this, arguments[i$5]); + return this.length; + }; + Yallist$1.prototype.pop = function() { + if (!this.tail) return void 0; + var res = this.tail.value; + this.tail = this.tail.prev; + if (this.tail) this.tail.next = null; + else this.head = null; + this.length--; + return res; + }; + Yallist$1.prototype.shift = function() { + if (!this.head) return void 0; + var res = this.head.value; + this.head = this.head.next; + if (this.head) this.head.prev = null; + else this.tail = null; + this.length--; + return res; + }; + Yallist$1.prototype.forEach = function(fn, thisp) { + thisp = thisp || this; + for (var walker = this.head, i$5 = 0; walker !== null; i$5++) { + fn.call(thisp, walker.value, i$5, this); + walker = walker.next; + } + }; + Yallist$1.prototype.forEachReverse = function(fn, thisp) { + thisp = thisp || this; + for (var walker = this.tail, i$5 = this.length - 1; walker !== null; i$5--) { + fn.call(thisp, walker.value, i$5, this); + walker = walker.prev; + } + }; + Yallist$1.prototype.get = function(n$3) { + for (var i$5 = 0, walker = this.head; walker !== null && i$5 < n$3; i$5++) walker = walker.next; + if (i$5 === n$3 && walker !== null) return walker.value; + }; + Yallist$1.prototype.getReverse = function(n$3) { + for (var i$5 = 0, walker = this.tail; walker !== null && i$5 < n$3; i$5++) walker = walker.prev; + if (i$5 === n$3 && walker !== null) return walker.value; + }; + Yallist$1.prototype.map = function(fn, thisp) { + thisp = thisp || this; + var res = new Yallist$1(); + for (var walker = this.head; walker !== null;) { + res.push(fn.call(thisp, walker.value, this)); + walker = walker.next; + } + return res; + }; + Yallist$1.prototype.mapReverse = function(fn, thisp) { + thisp = thisp || this; + var res = new Yallist$1(); + for (var walker = this.tail; walker !== null;) { + res.push(fn.call(thisp, walker.value, this)); + walker = walker.prev; + } + return res; + }; + Yallist$1.prototype.reduce = function(fn, initial$1) { + var acc; + var walker = this.head; + if (arguments.length > 1) acc = initial$1; + else if (this.head) { + walker = this.head.next; + acc = this.head.value; + } else throw new TypeError("Reduce of empty list with no initial value"); + for (var i$5 = 0; walker !== null; i$5++) { + acc = fn(acc, walker.value, i$5); + walker = walker.next; + } + return acc; + }; + Yallist$1.prototype.reduceReverse = function(fn, initial$1) { + var acc; + var walker = this.tail; + if (arguments.length > 1) acc = initial$1; + else if (this.tail) { + walker = this.tail.prev; + acc = this.tail.value; + } else throw new TypeError("Reduce of empty list with no initial value"); + for (var i$5 = this.length - 1; walker !== null; i$5--) { + acc = fn(acc, walker.value, i$5); + walker = walker.prev; + } + return acc; + }; + Yallist$1.prototype.toArray = function() { + var arr = new Array(this.length); + for (var i$5 = 0, walker = this.head; walker !== null; i$5++) { + arr[i$5] = walker.value; + walker = walker.next; + } + return arr; + }; + Yallist$1.prototype.toArrayReverse = function() { + var arr = new Array(this.length); + for (var i$5 = 0, walker = this.tail; walker !== null; i$5++) { + arr[i$5] = walker.value; + walker = walker.prev; + } + return arr; + }; + Yallist$1.prototype.slice = function(from, to) { + to = to || this.length; + if (to < 0) to += this.length; + from = from || 0; + if (from < 0) from += this.length; + var ret = new Yallist$1(); + if (to < from || to < 0) return ret; + if (from < 0) from = 0; + if (to > this.length) to = this.length; + for (var i$5 = 0, walker = this.head; walker !== null && i$5 < from; i$5++) walker = walker.next; + for (; walker !== null && i$5 < to; i$5++, walker = walker.next) ret.push(walker.value); + return ret; + }; + Yallist$1.prototype.sliceReverse = function(from, to) { + to = to || this.length; + if (to < 0) to += this.length; + from = from || 0; + if (from < 0) from += this.length; + var ret = new Yallist$1(); + if (to < from || to < 0) return ret; + if (from < 0) from = 0; + if (to > this.length) to = this.length; + for (var i$5 = this.length, walker = this.tail; walker !== null && i$5 > to; i$5--) walker = walker.prev; + for (; walker !== null && i$5 > from; i$5--, walker = walker.prev) ret.push(walker.value); + return ret; + }; + Yallist$1.prototype.splice = function(start, deleteCount) { + if (start > this.length) start = this.length - 1; + if (start < 0) start = this.length + start; + for (var i$5 = 0, walker = this.head; walker !== null && i$5 < start; i$5++) walker = walker.next; + var ret = []; + for (var i$5 = 0; walker && i$5 < deleteCount; i$5++) { + ret.push(walker.value); + walker = this.removeNode(walker); + } + if (walker === null) walker = this.tail; + if (walker !== this.head && walker !== this.tail) walker = walker.prev; + for (var i$5 = 2; i$5 < arguments.length; i$5++) walker = insert(this, walker, arguments[i$5]); + return ret; + }; + Yallist$1.prototype.reverse = function() { + var head = this.head; + var tail = this.tail; + for (var walker = head; walker !== null; walker = walker.prev) { + var p$1 = walker.prev; + walker.prev = walker.next; + walker.next = p$1; + } + this.head = tail; + this.tail = head; + return this; + }; + function insert(self$1, node, value) { + var inserted = node === self$1.head ? new Node$4(value, null, node, self$1) : new Node$4(value, node, node.next, self$1); + if (inserted.next === null) self$1.tail = inserted; + if (inserted.prev === null) self$1.head = inserted; + self$1.length++; + return inserted; + } + function push$1(self$1, item) { + self$1.tail = new Node$4(item, self$1.tail, null, self$1); + if (!self$1.head) self$1.head = self$1.tail; + self$1.length++; + } + function unshift(self$1, item) { + self$1.head = new Node$4(item, null, self$1.head, self$1); + if (!self$1.tail) self$1.tail = self$1.head; + self$1.length++; + } + function Node$4(value, prev, next, list$4) { + if (!(this instanceof Node$4)) return new Node$4(value, prev, next, list$4); + this.list = list$4; + this.value = value; + if (prev) { + prev.next = this; + this.prev = prev; + } else this.prev = null; + if (next) { + next.prev = this; + this.next = next; + } else this.next = null; + } + try { + require_iterator()(Yallist$1); + } catch (er) {} +} }); + +//#endregion +//#region node_modules/lru-cache/index.js +var require_lru_cache = __commonJS({ "node_modules/lru-cache/index.js"(exports, module) { + const Yallist = require_yallist(); + const MAX = Symbol("max"); + const LENGTH = Symbol("length"); + const LENGTH_CALCULATOR = Symbol("lengthCalculator"); + const ALLOW_STALE = Symbol("allowStale"); + const MAX_AGE = Symbol("maxAge"); + const DISPOSE = Symbol("dispose"); + const NO_DISPOSE_ON_SET = Symbol("noDisposeOnSet"); + const LRU_LIST = Symbol("lruList"); + const CACHE = Symbol("cache"); + const UPDATE_AGE_ON_GET = Symbol("updateAgeOnGet"); + const naiveLength = () => 1; + var LRUCache = class { + constructor(options) { + if (typeof options === "number") options = { max: options }; + if (!options) options = {}; + if (options.max && (typeof options.max !== "number" || options.max < 0)) throw new TypeError("max must be a non-negative number"); + const max$2 = this[MAX] = options.max || Infinity; + const lc = options.length || naiveLength; + this[LENGTH_CALCULATOR] = typeof lc !== "function" ? naiveLength : lc; + this[ALLOW_STALE] = options.stale || false; + if (options.maxAge && typeof options.maxAge !== "number") throw new TypeError("maxAge must be a number"); + this[MAX_AGE] = options.maxAge || 0; + this[DISPOSE] = options.dispose; + this[NO_DISPOSE_ON_SET] = options.noDisposeOnSet || false; + this[UPDATE_AGE_ON_GET] = options.updateAgeOnGet || false; + this.reset(); + } + set max(mL) { + if (typeof mL !== "number" || mL < 0) throw new TypeError("max must be a non-negative number"); + this[MAX] = mL || Infinity; + trim(this); + } + get max() { + return this[MAX]; + } + set allowStale(allowStale) { + this[ALLOW_STALE] = !!allowStale; + } + get allowStale() { + return this[ALLOW_STALE]; + } + set maxAge(mA) { + if (typeof mA !== "number") throw new TypeError("maxAge must be a non-negative number"); + this[MAX_AGE] = mA; + trim(this); + } + get maxAge() { + return this[MAX_AGE]; + } + set lengthCalculator(lC) { + if (typeof lC !== "function") lC = naiveLength; + if (lC !== this[LENGTH_CALCULATOR]) { + this[LENGTH_CALCULATOR] = lC; + this[LENGTH] = 0; + this[LRU_LIST].forEach((hit) => { + hit.length = this[LENGTH_CALCULATOR](hit.value, hit.key); + this[LENGTH] += hit.length; + }); + } + trim(this); + } + get lengthCalculator() { + return this[LENGTH_CALCULATOR]; + } + get length() { + return this[LENGTH]; + } + get itemCount() { + return this[LRU_LIST].length; + } + rforEach(fn, thisp) { + thisp = thisp || this; + for (let walker = this[LRU_LIST].tail; walker !== null;) { + const prev = walker.prev; + forEachStep(this, fn, walker, thisp); + walker = prev; + } + } + forEach(fn, thisp) { + thisp = thisp || this; + for (let walker = this[LRU_LIST].head; walker !== null;) { + const next = walker.next; + forEachStep(this, fn, walker, thisp); + walker = next; + } + } + keys() { + return this[LRU_LIST].toArray().map((k$1) => k$1.key); + } + values() { + return this[LRU_LIST].toArray().map((k$1) => k$1.value); + } + reset() { + if (this[DISPOSE] && this[LRU_LIST] && this[LRU_LIST].length) this[LRU_LIST].forEach((hit) => this[DISPOSE](hit.key, hit.value)); + this[CACHE] = new Map(); + this[LRU_LIST] = new Yallist(); + this[LENGTH] = 0; + } + dump() { + return this[LRU_LIST].map((hit) => isStale(this, hit) ? false : { + k: hit.key, + v: hit.value, + e: hit.now + (hit.maxAge || 0) + }).toArray().filter((h$2) => h$2); + } + dumpLru() { + return this[LRU_LIST]; + } + set(key, value, maxAge) { + maxAge = maxAge || this[MAX_AGE]; + if (maxAge && typeof maxAge !== "number") throw new TypeError("maxAge must be a number"); + const now = maxAge ? Date.now() : 0; + const len = this[LENGTH_CALCULATOR](value, key); + if (this[CACHE].has(key)) { + if (len > this[MAX]) { + del(this, this[CACHE].get(key)); + return false; + } + const node = this[CACHE].get(key); + const item = node.value; + if (this[DISPOSE]) { + if (!this[NO_DISPOSE_ON_SET]) this[DISPOSE](key, item.value); + } + item.now = now; + item.maxAge = maxAge; + item.value = value; + this[LENGTH] += len - item.length; + item.length = len; + this.get(key); + trim(this); + return true; + } + const hit = new Entry(key, value, len, now, maxAge); + if (hit.length > this[MAX]) { + if (this[DISPOSE]) this[DISPOSE](key, value); + return false; + } + this[LENGTH] += hit.length; + this[LRU_LIST].unshift(hit); + this[CACHE].set(key, this[LRU_LIST].head); + trim(this); + return true; + } + has(key) { + if (!this[CACHE].has(key)) return false; + const hit = this[CACHE].get(key).value; + return !isStale(this, hit); + } + get(key) { + return get$2(this, key, true); + } + peek(key) { + return get$2(this, key, false); + } + pop() { + const node = this[LRU_LIST].tail; + if (!node) return null; + del(this, node); + return node.value; + } + del(key) { + del(this, this[CACHE].get(key)); + } + load(arr) { + this.reset(); + const now = Date.now(); + for (let l$1 = arr.length - 1; l$1 >= 0; l$1--) { + const hit = arr[l$1]; + const expiresAt = hit.e || 0; + if (expiresAt === 0) this.set(hit.k, hit.v); + else { + const maxAge = expiresAt - now; + if (maxAge > 0) this.set(hit.k, hit.v, maxAge); + } + } + } + prune() { + this[CACHE].forEach((value, key) => get$2(this, key, false)); + } + }; + const get$2 = (self$1, key, doUse) => { + const node = self$1[CACHE].get(key); + if (node) { + const hit = node.value; + if (isStale(self$1, hit)) { + del(self$1, node); + if (!self$1[ALLOW_STALE]) return void 0; + } else if (doUse) { + if (self$1[UPDATE_AGE_ON_GET]) node.value.now = Date.now(); + self$1[LRU_LIST].unshiftNode(node); + } + return hit.value; + } + }; + const isStale = (self$1, hit) => { + if (!hit || !hit.maxAge && !self$1[MAX_AGE]) return false; + const diff = Date.now() - hit.now; + return hit.maxAge ? diff > hit.maxAge : self$1[MAX_AGE] && diff > self$1[MAX_AGE]; + }; + const trim = (self$1) => { + if (self$1[LENGTH] > self$1[MAX]) for (let walker = self$1[LRU_LIST].tail; self$1[LENGTH] > self$1[MAX] && walker !== null;) { + const prev = walker.prev; + del(self$1, walker); + walker = prev; + } + }; + const del = (self$1, node) => { + if (node) { + const hit = node.value; + if (self$1[DISPOSE]) self$1[DISPOSE](hit.key, hit.value); + self$1[LENGTH] -= hit.length; + self$1[CACHE].delete(hit.key); + self$1[LRU_LIST].removeNode(node); + } + }; + var Entry = class { + constructor(key, value, length, now, maxAge) { + this.key = key; + this.value = value; + this.length = length; + this.now = now; + this.maxAge = maxAge || 0; + } + }; + const forEachStep = (self$1, fn, node, thisp) => { + let hit = node.value; + if (isStale(self$1, hit)) { + del(self$1, node); + if (!self$1[ALLOW_STALE]) hit = void 0; + } + if (hit) fn.call(thisp, hit.value, hit.key, self$1); + }; + module.exports = LRUCache; +} }); + +//#endregion +//#region node_modules/bluebird/js/browser/bluebird.js +var require_bluebird = __commonJS({ "node_modules/bluebird/js/browser/bluebird.js"(exports, module) { + /* @preserve + * The MIT License (MIT) + * + * Copyright (c) 2013-2018 Petka Antonov + * + * 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. + * + */ + /** + * bluebird build version 3.7.2 + * Features enabled: core, race, call_get, generators, map, nodeify, promisify, props, reduce, settle, some, using, timers, filter, any, each + */ + (function(e) { + if ("object" == typeof exports && "undefined" != typeof module) module.exports = e(); + else if ("function" == typeof define && define.amd) define([], e); + else { + var f$1; + "undefined" != typeof window ? f$1 = window : "undefined" != typeof global ? f$1 = global : "undefined" != typeof self && (f$1 = self), f$1.Promise = e(); + } + })(function() { + var define$1, module$1, exports$1; + return function e(t$7, n$3, r) { + function s$1(o$1, u$14) { + if (!n$3[o$1]) { + if (!t$7[o$1]) { + var a = typeof _dereq_ == "function" && _dereq_; + if (!u$14 && a) return a(o$1, !0); + if (i$5) return i$5(o$1, !0); + var f$1 = new Error("Cannot find module '" + o$1 + "'"); + throw f$1.code = "MODULE_NOT_FOUND", f$1; + } + var l$1 = n$3[o$1] = { exports: {} }; + t$7[o$1][0].call(l$1.exports, function(e$1) { + var n$4 = t$7[o$1][1][e$1]; + return s$1(n$4 ? n$4 : e$1); + }, l$1, l$1.exports, e, t$7, n$3, r); + } + return n$3[o$1].exports; + } + var i$5 = typeof _dereq_ == "function" && _dereq_; + for (var o = 0; o < r.length; o++) s$1(r[o]); + return s$1; + }({ + 1: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2) { + var SomePromiseArray = Promise$2._SomePromiseArray; + function any(promises) { + var ret = new SomePromiseArray(promises); + var promise = ret.promise(); + ret.setHowMany(1); + ret.setUnwrap(); + ret.init(); + return promise; + } + Promise$2.any = function(promises) { + return any(promises); + }; + Promise$2.prototype.any = function() { + return any(this); + }; + }; + }, {}], + 2: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + var firstLineError; + try { + throw new Error(); + } catch (e) { + firstLineError = e; + } + var schedule = _dereq_$1("./schedule"); + var Queue = _dereq_$1("./queue"); + function Async() { + this._customScheduler = false; + this._isTickUsed = false; + this._lateQueue = new Queue(16); + this._normalQueue = new Queue(16); + this._haveDrainedQueues = false; + var self$1 = this; + this.drainQueues = function() { + self$1._drainQueues(); + }; + this._schedule = schedule; + } + Async.prototype.setScheduler = function(fn) { + var prev = this._schedule; + this._schedule = fn; + this._customScheduler = true; + return prev; + }; + Async.prototype.hasCustomScheduler = function() { + return this._customScheduler; + }; + Async.prototype.haveItemsQueued = function() { + return this._isTickUsed || this._haveDrainedQueues; + }; + Async.prototype.fatalError = function(e, isNode$4) { + if (isNode$4) { + process.stderr.write("Fatal " + (e instanceof Error ? e.stack : e) + "\n"); + process.exit(2); + } else this.throwLater(e); + }; + Async.prototype.throwLater = function(fn, arg) { + if (arguments.length === 1) { + arg = fn; + fn = function() { + throw arg; + }; + } + if (typeof setTimeout !== "undefined") setTimeout(function() { + fn(arg); + }, 0); + else try { + this._schedule(function() { + fn(arg); + }); + } catch (e) { + throw new Error("No async scheduler available\n\n See http://goo.gl/MqrFmX\n"); + } + }; + function AsyncInvokeLater(fn, receiver, arg) { + this._lateQueue.push(fn, receiver, arg); + this._queueTick(); + } + function AsyncInvoke(fn, receiver, arg) { + this._normalQueue.push(fn, receiver, arg); + this._queueTick(); + } + function AsyncSettlePromises(promise) { + this._normalQueue._pushOne(promise); + this._queueTick(); + } + Async.prototype.invokeLater = AsyncInvokeLater; + Async.prototype.invoke = AsyncInvoke; + Async.prototype.settlePromises = AsyncSettlePromises; + function _drainQueue(queue$1) { + while (queue$1.length() > 0) _drainQueueStep(queue$1); + } + function _drainQueueStep(queue$1) { + var fn = queue$1.shift(); + if (typeof fn !== "function") fn._settlePromises(); + else { + var receiver = queue$1.shift(); + var arg = queue$1.shift(); + fn.call(receiver, arg); + } + } + Async.prototype._drainQueues = function() { + _drainQueue(this._normalQueue); + this._reset(); + this._haveDrainedQueues = true; + _drainQueue(this._lateQueue); + }; + Async.prototype._queueTick = function() { + if (!this._isTickUsed) { + this._isTickUsed = true; + this._schedule(this.drainQueues); + } + }; + Async.prototype._reset = function() { + this._isTickUsed = false; + }; + module$2.exports = Async; + module$2.exports.firstLineError = firstLineError; + }, { + "./queue": 26, + "./schedule": 29 + }], + 3: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, INTERNAL, tryConvertToPromise, debug$2) { + var calledBind = false; + var rejectThis = function(_$2, e) { + this._reject(e); + }; + var targetRejected = function(e, context) { + context.promiseRejectionQueued = true; + context.bindingPromise._then(rejectThis, rejectThis, null, this, e); + }; + var bindingResolved = function(thisArg, context) { + if ((this._bitField & 50397184) === 0) this._resolveCallback(context.target); + }; + var bindingRejected = function(e, context) { + if (!context.promiseRejectionQueued) this._reject(e); + }; + Promise$2.prototype.bind = function(thisArg) { + if (!calledBind) { + calledBind = true; + Promise$2.prototype._propagateFrom = debug$2.propagateFromFunction(); + Promise$2.prototype._boundValue = debug$2.boundValueFunction(); + } + var maybePromise = tryConvertToPromise(thisArg); + var ret = new Promise$2(INTERNAL); + ret._propagateFrom(this, 1); + var target = this._target(); + ret._setBoundTo(maybePromise); + if (maybePromise instanceof Promise$2) { + var context = { + promiseRejectionQueued: false, + promise: ret, + target, + bindingPromise: maybePromise + }; + target._then(INTERNAL, targetRejected, void 0, ret, context); + maybePromise._then(bindingResolved, bindingRejected, void 0, ret, context); + ret._setOnCancel(maybePromise); + } else ret._resolveCallback(target); + return ret; + }; + Promise$2.prototype._setBoundTo = function(obj) { + if (obj !== void 0) { + this._bitField = this._bitField | 2097152; + this._boundTo = obj; + } else this._bitField = this._bitField & -2097153; + }; + Promise$2.prototype._isBound = function() { + return (this._bitField & 2097152) === 2097152; + }; + Promise$2.bind = function(thisArg, value) { + return Promise$2.resolve(value).bind(thisArg); + }; + }; + }, {}], + 4: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + var old$1; + if (typeof Promise !== "undefined") old$1 = Promise; + function noConflict() { + try { + if (Promise === bluebird) Promise = old$1; + } catch (e) {} + return bluebird; + } + var bluebird = _dereq_$1("./promise")(); + bluebird.noConflict = noConflict; + module$2.exports = bluebird; + }, { "./promise": 22 }], + 5: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + var cr$3 = Object.create; + if (cr$3) { + var callerCache = cr$3(null); + var getterCache = cr$3(null); + callerCache[" size"] = getterCache[" size"] = 0; + } + module$2.exports = function(Promise$2) { + var util$9 = _dereq_$1("./util"); + var canEvaluate = util$9.canEvaluate; + var isIdentifier$15 = util$9.isIdentifier; + var getMethodCaller; + var getGetter; + if (0) var makeMethodCaller, makeGetter, getCompiled; + function ensureMethod(obj, methodName) { + var fn; + if (obj != null) fn = obj[methodName]; + if (typeof fn !== "function") { + var message = "Object " + util$9.classString(obj) + " has no method '" + util$9.toString(methodName) + "'"; + throw new Promise$2.TypeError(message); + } + return fn; + } + function caller$2(obj) { + var methodName = this.pop(); + var fn = ensureMethod(obj, methodName); + return fn.apply(obj, this); + } + Promise$2.prototype.call = function(methodName) { + var args = [].slice.call(arguments, 1); + if (0) var maybeCaller; + args.push(methodName); + return this._then(caller$2, void 0, void 0, args, void 0); + }; + function namedGetter(obj) { + return obj[this]; + } + function indexedGetter(obj) { + var index$1 = +this; + if (index$1 < 0) index$1 = Math.max(0, index$1 + obj.length); + return obj[index$1]; + } + Promise$2.prototype.get = function(propertyName) { + var isIndex = typeof propertyName === "number"; + var getter; + if (!isIndex) if (canEvaluate) { + var maybeGetter = getGetter(propertyName); + getter = maybeGetter !== null ? maybeGetter : namedGetter; + } else getter = namedGetter; + else getter = indexedGetter; + return this._then(getter, void 0, void 0, propertyName, void 0); + }; + }; + }, { "./util": 36 }], + 6: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, PromiseArray, apiRejection, debug$2) { + var util$9 = _dereq_$1("./util"); + var tryCatch = util$9.tryCatch; + var errorObj = util$9.errorObj; + var async$1 = Promise$2._async; + Promise$2.prototype["break"] = Promise$2.prototype.cancel = function() { + if (!debug$2.cancellation()) return this._warn("cancellation is disabled"); + var promise = this; + var child = promise; + while (promise._isCancellable()) { + if (!promise._cancelBy(child)) { + if (child._isFollowing()) child._followee().cancel(); + else child._cancelBranched(); + break; + } + var parent = promise._cancellationParent; + if (parent == null || !parent._isCancellable()) { + if (promise._isFollowing()) promise._followee().cancel(); + else promise._cancelBranched(); + break; + } else { + if (promise._isFollowing()) promise._followee().cancel(); + promise._setWillBeCancelled(); + child = promise; + promise = parent; + } + } + }; + Promise$2.prototype._branchHasCancelled = function() { + this._branchesRemainingToCancel--; + }; + Promise$2.prototype._enoughBranchesHaveCancelled = function() { + return this._branchesRemainingToCancel === void 0 || this._branchesRemainingToCancel <= 0; + }; + Promise$2.prototype._cancelBy = function(canceller) { + if (canceller === this) { + this._branchesRemainingToCancel = 0; + this._invokeOnCancel(); + return true; + } else { + this._branchHasCancelled(); + if (this._enoughBranchesHaveCancelled()) { + this._invokeOnCancel(); + return true; + } + } + return false; + }; + Promise$2.prototype._cancelBranched = function() { + if (this._enoughBranchesHaveCancelled()) this._cancel(); + }; + Promise$2.prototype._cancel = function() { + if (!this._isCancellable()) return; + this._setCancelled(); + async$1.invoke(this._cancelPromises, this, void 0); + }; + Promise$2.prototype._cancelPromises = function() { + if (this._length() > 0) this._settlePromises(); + }; + Promise$2.prototype._unsetOnCancel = function() { + this._onCancelField = void 0; + }; + Promise$2.prototype._isCancellable = function() { + return this.isPending() && !this._isCancelled(); + }; + Promise$2.prototype.isCancellable = function() { + return this.isPending() && !this.isCancelled(); + }; + Promise$2.prototype._doInvokeOnCancel = function(onCancelCallback, internalOnly) { + if (util$9.isArray(onCancelCallback)) for (var i$5 = 0; i$5 < onCancelCallback.length; ++i$5) this._doInvokeOnCancel(onCancelCallback[i$5], internalOnly); + else if (onCancelCallback !== void 0) if (typeof onCancelCallback === "function") { + if (!internalOnly) { + var e = tryCatch(onCancelCallback).call(this._boundValue()); + if (e === errorObj) { + this._attachExtraTrace(e.e); + async$1.throwLater(e.e); + } + } + } else onCancelCallback._resultCancelled(this); + }; + Promise$2.prototype._invokeOnCancel = function() { + var onCancelCallback = this._onCancel(); + this._unsetOnCancel(); + async$1.invoke(this._doInvokeOnCancel, this, onCancelCallback); + }; + Promise$2.prototype._invokeInternalOnCancel = function() { + if (this._isCancellable()) { + this._doInvokeOnCancel(this._onCancel(), true); + this._unsetOnCancel(); + } + }; + Promise$2.prototype._resultCancelled = function() { + this.cancel(); + }; + }; + }, { "./util": 36 }], + 7: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(NEXT_FILTER) { + var util$9 = _dereq_$1("./util"); + var getKeys = _dereq_$1("./es5").keys; + var tryCatch = util$9.tryCatch; + var errorObj = util$9.errorObj; + function catchFilter(instances, cb$1, promise) { + return function(e) { + var boundTo = promise._boundValue(); + predicateLoop: for (var i$5 = 0; i$5 < instances.length; ++i$5) { + var item = instances[i$5]; + if (item === Error || item != null && item.prototype instanceof Error) { + if (e instanceof item) return tryCatch(cb$1).call(boundTo, e); + } else if (typeof item === "function") { + var matchesPredicate = tryCatch(item).call(boundTo, e); + if (matchesPredicate === errorObj) return matchesPredicate; + else if (matchesPredicate) return tryCatch(cb$1).call(boundTo, e); + } else if (util$9.isObject(e)) { + var keys$2 = getKeys(item); + for (var j = 0; j < keys$2.length; ++j) { + var key = keys$2[j]; + if (item[key] != e[key]) continue predicateLoop; + } + return tryCatch(cb$1).call(boundTo, e); + } + } + return NEXT_FILTER; + }; + } + return catchFilter; + }; + }, { + "./es5": 13, + "./util": 36 + }], + 8: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2) { + var longStackTraces = false; + var contextStack = []; + Promise$2.prototype._promiseCreated = function() {}; + Promise$2.prototype._pushContext = function() {}; + Promise$2.prototype._popContext = function() { + return null; + }; + Promise$2._peekContext = Promise$2.prototype._peekContext = function() {}; + function Context() { + this._trace = new Context.CapturedTrace(peekContext()); + } + Context.prototype._pushContext = function() { + if (this._trace !== void 0) { + this._trace._promiseCreated = null; + contextStack.push(this._trace); + } + }; + Context.prototype._popContext = function() { + if (this._trace !== void 0) { + var trace = contextStack.pop(); + var ret = trace._promiseCreated; + trace._promiseCreated = null; + return ret; + } + return null; + }; + function createContext() { + if (longStackTraces) return new Context(); + } + function peekContext() { + var lastIndex = contextStack.length - 1; + if (lastIndex >= 0) return contextStack[lastIndex]; + return void 0; + } + Context.CapturedTrace = null; + Context.create = createContext; + Context.deactivateLongStackTraces = function() {}; + Context.activateLongStackTraces = function() { + var Promise_pushContext = Promise$2.prototype._pushContext; + var Promise_popContext = Promise$2.prototype._popContext; + var Promise_PeekContext = Promise$2._peekContext; + var Promise_peekContext = Promise$2.prototype._peekContext; + var Promise_promiseCreated = Promise$2.prototype._promiseCreated; + Context.deactivateLongStackTraces = function() { + Promise$2.prototype._pushContext = Promise_pushContext; + Promise$2.prototype._popContext = Promise_popContext; + Promise$2._peekContext = Promise_PeekContext; + Promise$2.prototype._peekContext = Promise_peekContext; + Promise$2.prototype._promiseCreated = Promise_promiseCreated; + longStackTraces = false; + }; + longStackTraces = true; + Promise$2.prototype._pushContext = Context.prototype._pushContext; + Promise$2.prototype._popContext = Context.prototype._popContext; + Promise$2._peekContext = Promise$2.prototype._peekContext = peekContext; + Promise$2.prototype._promiseCreated = function() { + var ctx = this._peekContext(); + if (ctx && ctx._promiseCreated == null) ctx._promiseCreated = this; + }; + }; + return Context; + }; + }, {}], + 9: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, Context, enableAsyncHooks, disableAsyncHooks) { + var async$1 = Promise$2._async; + var Warning$4 = _dereq_$1("./errors").Warning; + var util$9 = _dereq_$1("./util"); + var es5 = _dereq_$1("./es5"); + var canAttachTrace = util$9.canAttachTrace; + var unhandledRejectionHandled; + var possiblyUnhandledRejection; + var bluebirdFramePattern = /[\\\/]bluebird[\\\/]js[\\\/](release|debug|instrumented)/; + var nodeFramePattern = /\((?:timers\.js):\d+:\d+\)/; + var parseLinePattern = /[\/<\(](.+?):(\d+):(\d+)\)?\s*$/; + var stackFramePattern = null; + var formatStack = null; + var indentStackFrames = false; + var printWarning; + var debugging = !!(util$9.env("BLUEBIRD_DEBUG") != 0 && true); + var warnings$1 = !!(util$9.env("BLUEBIRD_WARNINGS") != 0 && (debugging || util$9.env("BLUEBIRD_WARNINGS"))); + var longStackTraces = !!(util$9.env("BLUEBIRD_LONG_STACK_TRACES") != 0 && (debugging || util$9.env("BLUEBIRD_LONG_STACK_TRACES"))); + var wForgottenReturn = util$9.env("BLUEBIRD_W_FORGOTTEN_RETURN") != 0 && (warnings$1 || !!util$9.env("BLUEBIRD_W_FORGOTTEN_RETURN")); + var deferUnhandledRejectionCheck; + (function() { + var promises = []; + function unhandledRejectionCheck() { + for (var i$5 = 0; i$5 < promises.length; ++i$5) promises[i$5]._notifyUnhandledRejection(); + unhandledRejectionClear(); + } + function unhandledRejectionClear() { + promises.length = 0; + } + deferUnhandledRejectionCheck = function(promise) { + promises.push(promise); + setTimeout(unhandledRejectionCheck, 1); + }; + es5.defineProperty(Promise$2, "_unhandledRejectionCheck", { value: unhandledRejectionCheck }); + es5.defineProperty(Promise$2, "_unhandledRejectionClear", { value: unhandledRejectionClear }); + })(); + Promise$2.prototype.suppressUnhandledRejections = function() { + var target = this._target(); + target._bitField = target._bitField & -1048577 | 524288; + }; + Promise$2.prototype._ensurePossibleRejectionHandled = function() { + if ((this._bitField & 524288) !== 0) return; + this._setRejectionIsUnhandled(); + deferUnhandledRejectionCheck(this); + }; + Promise$2.prototype._notifyUnhandledRejectionIsHandled = function() { + fireRejectionEvent("rejectionHandled", unhandledRejectionHandled, void 0, this); + }; + Promise$2.prototype._setReturnedNonUndefined = function() { + this._bitField = this._bitField | 268435456; + }; + Promise$2.prototype._returnedNonUndefined = function() { + return (this._bitField & 268435456) !== 0; + }; + Promise$2.prototype._notifyUnhandledRejection = function() { + if (this._isRejectionUnhandled()) { + var reason = this._settledValue(); + this._setUnhandledRejectionIsNotified(); + fireRejectionEvent("unhandledRejection", possiblyUnhandledRejection, reason, this); + } + }; + Promise$2.prototype._setUnhandledRejectionIsNotified = function() { + this._bitField = this._bitField | 262144; + }; + Promise$2.prototype._unsetUnhandledRejectionIsNotified = function() { + this._bitField = this._bitField & -262145; + }; + Promise$2.prototype._isUnhandledRejectionNotified = function() { + return (this._bitField & 262144) > 0; + }; + Promise$2.prototype._setRejectionIsUnhandled = function() { + this._bitField = this._bitField | 1048576; + }; + Promise$2.prototype._unsetRejectionIsUnhandled = function() { + this._bitField = this._bitField & -1048577; + if (this._isUnhandledRejectionNotified()) { + this._unsetUnhandledRejectionIsNotified(); + this._notifyUnhandledRejectionIsHandled(); + } + }; + Promise$2.prototype._isRejectionUnhandled = function() { + return (this._bitField & 1048576) > 0; + }; + Promise$2.prototype._warn = function(message, shouldUseOwnTrace, promise) { + return warn$1(message, shouldUseOwnTrace, promise || this); + }; + Promise$2.onPossiblyUnhandledRejection = function(fn) { + var context = Promise$2._getContext(); + possiblyUnhandledRejection = util$9.contextBind(context, fn); + }; + Promise$2.onUnhandledRejectionHandled = function(fn) { + var context = Promise$2._getContext(); + unhandledRejectionHandled = util$9.contextBind(context, fn); + }; + var disableLongStackTraces = function() {}; + Promise$2.longStackTraces = function() { + if (async$1.haveItemsQueued() && !config$1.longStackTraces) throw new Error("cannot enable long stack traces after promises have been created\n\n See http://goo.gl/MqrFmX\n"); + if (!config$1.longStackTraces && longStackTracesIsSupported()) { + var Promise_captureStackTrace = Promise$2.prototype._captureStackTrace; + var Promise_attachExtraTrace = Promise$2.prototype._attachExtraTrace; + var Promise_dereferenceTrace = Promise$2.prototype._dereferenceTrace; + config$1.longStackTraces = true; + disableLongStackTraces = function() { + if (async$1.haveItemsQueued() && !config$1.longStackTraces) throw new Error("cannot enable long stack traces after promises have been created\n\n See http://goo.gl/MqrFmX\n"); + Promise$2.prototype._captureStackTrace = Promise_captureStackTrace; + Promise$2.prototype._attachExtraTrace = Promise_attachExtraTrace; + Promise$2.prototype._dereferenceTrace = Promise_dereferenceTrace; + Context.deactivateLongStackTraces(); + config$1.longStackTraces = false; + }; + Promise$2.prototype._captureStackTrace = longStackTracesCaptureStackTrace; + Promise$2.prototype._attachExtraTrace = longStackTracesAttachExtraTrace; + Promise$2.prototype._dereferenceTrace = longStackTracesDereferenceTrace; + Context.activateLongStackTraces(); + } + }; + Promise$2.hasLongStackTraces = function() { + return config$1.longStackTraces && longStackTracesIsSupported(); + }; + var legacyHandlers = { + unhandledrejection: { + before: function() { + var ret = util$9.global.onunhandledrejection; + util$9.global.onunhandledrejection = null; + return ret; + }, + after: function(fn) { + util$9.global.onunhandledrejection = fn; + } + }, + rejectionhandled: { + before: function() { + var ret = util$9.global.onrejectionhandled; + util$9.global.onrejectionhandled = null; + return ret; + }, + after: function(fn) { + util$9.global.onrejectionhandled = fn; + } + } + }; + var fireDomEvent = function() { + var dispatch = function(legacy$2, e) { + if (legacy$2) { + var fn; + try { + fn = legacy$2.before(); + return !util$9.global.dispatchEvent(e); + } finally { + legacy$2.after(fn); + } + } else return !util$9.global.dispatchEvent(e); + }; + try { + if (typeof CustomEvent === "function") { + var event = new CustomEvent("CustomEvent"); + util$9.global.dispatchEvent(event); + return function(name, event$1) { + name = name.toLowerCase(); + var eventData = { + detail: event$1, + cancelable: true + }; + var domEvent = new CustomEvent(name, eventData); + es5.defineProperty(domEvent, "promise", { value: event$1.promise }); + es5.defineProperty(domEvent, "reason", { value: event$1.reason }); + return dispatch(legacyHandlers[name], domEvent); + }; + } else if (typeof Event === "function") { + var event = new Event("CustomEvent"); + util$9.global.dispatchEvent(event); + return function(name, event$1) { + name = name.toLowerCase(); + var domEvent = new Event(name, { cancelable: true }); + domEvent.detail = event$1; + es5.defineProperty(domEvent, "promise", { value: event$1.promise }); + es5.defineProperty(domEvent, "reason", { value: event$1.reason }); + return dispatch(legacyHandlers[name], domEvent); + }; + } else { + var event = document.createEvent("CustomEvent"); + event.initCustomEvent("testingtheevent", false, true, {}); + util$9.global.dispatchEvent(event); + return function(name, event$1) { + name = name.toLowerCase(); + var domEvent = document.createEvent("CustomEvent"); + domEvent.initCustomEvent(name, false, true, event$1); + return dispatch(legacyHandlers[name], domEvent); + }; + } + } catch (e) {} + return function() { + return false; + }; + }(); + var fireGlobalEvent = function() { + if (util$9.isNode) return function() { + return process.emit.apply(process, arguments); + }; + else { + if (!util$9.global) return function() { + return false; + }; + return function(name) { + var methodName = "on" + name.toLowerCase(); + var method = util$9.global[methodName]; + if (!method) return false; + method.apply(util$9.global, [].slice.call(arguments, 1)); + return true; + }; + } + }(); + function generatePromiseLifecycleEventObject(name, promise) { + return { promise }; + } + var eventToObjectGenerator = { + promiseCreated: generatePromiseLifecycleEventObject, + promiseFulfilled: generatePromiseLifecycleEventObject, + promiseRejected: generatePromiseLifecycleEventObject, + promiseResolved: generatePromiseLifecycleEventObject, + promiseCancelled: generatePromiseLifecycleEventObject, + promiseChained: function(name, promise, child) { + return { + promise, + child + }; + }, + warning: function(name, warning) { + return { warning }; + }, + unhandledRejection: function(name, reason, promise) { + return { + reason, + promise + }; + }, + rejectionHandled: generatePromiseLifecycleEventObject + }; + var activeFireEvent = function(name) { + var globalEventFired = false; + try { + globalEventFired = fireGlobalEvent.apply(null, arguments); + } catch (e) { + async$1.throwLater(e); + globalEventFired = true; + } + var domEventFired = false; + try { + domEventFired = fireDomEvent(name, eventToObjectGenerator[name].apply(null, arguments)); + } catch (e) { + async$1.throwLater(e); + domEventFired = true; + } + return domEventFired || globalEventFired; + }; + Promise$2.config = function(opts) { + opts = Object(opts); + if ("longStackTraces" in opts) { + if (opts.longStackTraces) Promise$2.longStackTraces(); + else if (!opts.longStackTraces && Promise$2.hasLongStackTraces()) disableLongStackTraces(); + } + if ("warnings" in opts) { + var warningsOption = opts.warnings; + config$1.warnings = !!warningsOption; + wForgottenReturn = config$1.warnings; + if (util$9.isObject(warningsOption)) { + if ("wForgottenReturn" in warningsOption) wForgottenReturn = !!warningsOption.wForgottenReturn; + } + } + if ("cancellation" in opts && opts.cancellation && !config$1.cancellation) { + if (async$1.haveItemsQueued()) throw new Error("cannot enable cancellation after promises are in use"); + Promise$2.prototype._clearCancellationData = cancellationClearCancellationData; + Promise$2.prototype._propagateFrom = cancellationPropagateFrom; + Promise$2.prototype._onCancel = cancellationOnCancel; + Promise$2.prototype._setOnCancel = cancellationSetOnCancel; + Promise$2.prototype._attachCancellationCallback = cancellationAttachCancellationCallback; + Promise$2.prototype._execute = cancellationExecute; + propagateFromFunction = cancellationPropagateFrom; + config$1.cancellation = true; + } + if ("monitoring" in opts) { + if (opts.monitoring && !config$1.monitoring) { + config$1.monitoring = true; + Promise$2.prototype._fireEvent = activeFireEvent; + } else if (!opts.monitoring && config$1.monitoring) { + config$1.monitoring = false; + Promise$2.prototype._fireEvent = defaultFireEvent; + } + } + if ("asyncHooks" in opts && util$9.nodeSupportsAsyncResource) { + var prev = config$1.asyncHooks; + var cur = !!opts.asyncHooks; + if (prev !== cur) { + config$1.asyncHooks = cur; + if (cur) enableAsyncHooks(); + else disableAsyncHooks(); + } + } + return Promise$2; + }; + function defaultFireEvent() { + return false; + } + Promise$2.prototype._fireEvent = defaultFireEvent; + Promise$2.prototype._execute = function(executor, resolve$5, reject$1) { + try { + executor(resolve$5, reject$1); + } catch (e) { + return e; + } + }; + Promise$2.prototype._onCancel = function() {}; + Promise$2.prototype._setOnCancel = function(handler) {}; + Promise$2.prototype._attachCancellationCallback = function(onCancel) {}; + Promise$2.prototype._captureStackTrace = function() {}; + Promise$2.prototype._attachExtraTrace = function() {}; + Promise$2.prototype._dereferenceTrace = function() {}; + Promise$2.prototype._clearCancellationData = function() {}; + Promise$2.prototype._propagateFrom = function(parent, flags) {}; + function cancellationExecute(executor, resolve$5, reject$1) { + var promise = this; + try { + executor(resolve$5, reject$1, function(onCancel) { + if (typeof onCancel !== "function") throw new TypeError("onCancel must be a function, got: " + util$9.toString(onCancel)); + promise._attachCancellationCallback(onCancel); + }); + } catch (e) { + return e; + } + } + function cancellationAttachCancellationCallback(onCancel) { + if (!this._isCancellable()) return this; + var previousOnCancel = this._onCancel(); + if (previousOnCancel !== void 0) if (util$9.isArray(previousOnCancel)) previousOnCancel.push(onCancel); + else this._setOnCancel([previousOnCancel, onCancel]); + else this._setOnCancel(onCancel); + } + function cancellationOnCancel() { + return this._onCancelField; + } + function cancellationSetOnCancel(onCancel) { + this._onCancelField = onCancel; + } + function cancellationClearCancellationData() { + this._cancellationParent = void 0; + this._onCancelField = void 0; + } + function cancellationPropagateFrom(parent, flags) { + if ((flags & 1) !== 0) { + this._cancellationParent = parent; + var branchesRemainingToCancel = parent._branchesRemainingToCancel; + if (branchesRemainingToCancel === void 0) branchesRemainingToCancel = 0; + parent._branchesRemainingToCancel = branchesRemainingToCancel + 1; + } + if ((flags & 2) !== 0 && parent._isBound()) this._setBoundTo(parent._boundTo); + } + function bindingPropagateFrom(parent, flags) { + if ((flags & 2) !== 0 && parent._isBound()) this._setBoundTo(parent._boundTo); + } + var propagateFromFunction = bindingPropagateFrom; + function boundValueFunction() { + var ret = this._boundTo; + if (ret !== void 0) { + if (ret instanceof Promise$2) if (ret.isFulfilled()) return ret.value(); + else return void 0; + } + return ret; + } + function longStackTracesCaptureStackTrace() { + this._trace = new CapturedTrace(this._peekContext()); + } + function longStackTracesAttachExtraTrace(error, ignoreSelf) { + if (canAttachTrace(error)) { + var trace = this._trace; + if (trace !== void 0) { + if (ignoreSelf) trace = trace._parent; + } + if (trace !== void 0) trace.attachExtraTrace(error); + else if (!error.__stackCleaned__) { + var parsed = parseStackAndMessage(error); + util$9.notEnumerableProp(error, "stack", parsed.message + "\n" + parsed.stack.join("\n")); + util$9.notEnumerableProp(error, "__stackCleaned__", true); + } + } + } + function longStackTracesDereferenceTrace() { + this._trace = void 0; + } + function checkForgottenReturns(returnValue, promiseCreated, name, promise, parent) { + if (returnValue === void 0 && promiseCreated !== null && wForgottenReturn) { + if (parent !== void 0 && parent._returnedNonUndefined()) return; + if ((promise._bitField & 65535) === 0) return; + if (name) name = name + " "; + var handlerLine = ""; + var creatorLine = ""; + if (promiseCreated._trace) { + var traceLines = promiseCreated._trace.stack.split("\n"); + var stack = cleanStack(traceLines); + for (var i$5 = stack.length - 1; i$5 >= 0; --i$5) { + var line = stack[i$5]; + if (!nodeFramePattern.test(line)) { + var lineMatches = line.match(parseLinePattern); + if (lineMatches) handlerLine = "at " + lineMatches[1] + ":" + lineMatches[2] + ":" + lineMatches[3] + " "; + break; + } + } + if (stack.length > 0) { + var firstUserLine = stack[0]; + for (var i$5 = 0; i$5 < traceLines.length; ++i$5) if (traceLines[i$5] === firstUserLine) { + if (i$5 > 0) creatorLine = "\n" + traceLines[i$5 - 1]; + break; + } + } + } + var msg = "a promise was created in a " + name + "handler " + handlerLine + "but was not returned from it, see http://goo.gl/rRqMUw" + creatorLine; + promise._warn(msg, true, promiseCreated); + } + } + function deprecated(name, replacement) { + var message = name + " is deprecated and will be removed in a future version."; + if (replacement) message += " Use " + replacement + " instead."; + return warn$1(message); + } + function warn$1(message, shouldUseOwnTrace, promise) { + if (!config$1.warnings) return; + var warning = new Warning$4(message); + var ctx; + if (shouldUseOwnTrace) promise._attachExtraTrace(warning); + else if (config$1.longStackTraces && (ctx = Promise$2._peekContext())) ctx.attachExtraTrace(warning); + else { + var parsed = parseStackAndMessage(warning); + warning.stack = parsed.message + "\n" + parsed.stack.join("\n"); + } + if (!activeFireEvent("warning", warning)) formatAndLogError(warning, "", true); + } + function reconstructStack(message, stacks) { + for (var i$5 = 0; i$5 < stacks.length - 1; ++i$5) { + stacks[i$5].push("From previous event:"); + stacks[i$5] = stacks[i$5].join("\n"); + } + if (i$5 < stacks.length) stacks[i$5] = stacks[i$5].join("\n"); + return message + "\n" + stacks.join("\n"); + } + function removeDuplicateOrEmptyJumps(stacks) { + for (var i$5 = 0; i$5 < stacks.length; ++i$5) if (stacks[i$5].length === 0 || i$5 + 1 < stacks.length && stacks[i$5][0] === stacks[i$5 + 1][0]) { + stacks.splice(i$5, 1); + i$5--; + } + } + function removeCommonRoots(stacks) { + var current = stacks[0]; + for (var i$5 = 1; i$5 < stacks.length; ++i$5) { + var prev = stacks[i$5]; + var currentLastIndex = current.length - 1; + var currentLastLine = current[currentLastIndex]; + var commonRootMeetPoint = -1; + for (var j = prev.length - 1; j >= 0; --j) if (prev[j] === currentLastLine) { + commonRootMeetPoint = j; + break; + } + for (var j = commonRootMeetPoint; j >= 0; --j) { + var line = prev[j]; + if (current[currentLastIndex] === line) { + current.pop(); + currentLastIndex--; + } else break; + } + current = prev; + } + } + function cleanStack(stack) { + var ret = []; + for (var i$5 = 0; i$5 < stack.length; ++i$5) { + var line = stack[i$5]; + var isTraceLine = " (No stack trace)" === line || stackFramePattern.test(line); + var isInternalFrame = isTraceLine && shouldIgnore(line); + if (isTraceLine && !isInternalFrame) { + if (indentStackFrames && line.charAt(0) !== " ") line = " " + line; + ret.push(line); + } + } + return ret; + } + function stackFramesAsArray(error) { + var stack = error.stack.replace(/\s+$/g, "").split("\n"); + for (var i$5 = 0; i$5 < stack.length; ++i$5) { + var line = stack[i$5]; + if (" (No stack trace)" === line || stackFramePattern.test(line)) break; + } + if (i$5 > 0 && error.name != "SyntaxError") stack = stack.slice(i$5); + return stack; + } + function parseStackAndMessage(error) { + var stack = error.stack; + var message = error.toString(); + stack = typeof stack === "string" && stack.length > 0 ? stackFramesAsArray(error) : [" (No stack trace)"]; + return { + message, + stack: error.name == "SyntaxError" ? stack : cleanStack(stack) + }; + } + function formatAndLogError(error, title, isSoft) { + if (typeof console !== "undefined") { + var message; + if (util$9.isObject(error)) { + var stack = error.stack; + message = title + formatStack(stack, error); + } else message = title + String(error); + if (typeof printWarning === "function") printWarning(message, isSoft); + else if (typeof console.log === "function" || typeof console.log === "object") console.log(message); + } + } + function fireRejectionEvent(name, localHandler, reason, promise) { + var localEventFired = false; + try { + if (typeof localHandler === "function") { + localEventFired = true; + if (name === "rejectionHandled") localHandler(promise); + else localHandler(reason, promise); + } + } catch (e) { + async$1.throwLater(e); + } + if (name === "unhandledRejection") { + if (!activeFireEvent(name, reason, promise) && !localEventFired) formatAndLogError(reason, "Unhandled rejection "); + } else activeFireEvent(name, promise); + } + function formatNonError(obj) { + var str$3; + if (typeof obj === "function") str$3 = "[function " + (obj.name || "anonymous") + "]"; + else { + str$3 = obj && typeof obj.toString === "function" ? obj.toString() : util$9.toString(obj); + var ruselessToString = /\[object [a-zA-Z0-9$_]+\]/; + if (ruselessToString.test(str$3)) try { + var newStr = JSON.stringify(obj); + str$3 = newStr; + } catch (e) {} + if (str$3.length === 0) str$3 = "(empty array)"; + } + return "(<" + snip(str$3) + ">, no stack trace)"; + } + function snip(str$3) { + var maxChars = 41; + if (str$3.length < maxChars) return str$3; + return str$3.substr(0, maxChars - 3) + "..."; + } + function longStackTracesIsSupported() { + return typeof captureStackTrace === "function"; + } + var shouldIgnore = function() { + return false; + }; + var parseLineInfoRegex = /[\/<\(]([^:\/]+):(\d+):(?:\d+)\)?\s*$/; + function parseLineInfo(line) { + var matches = line.match(parseLineInfoRegex); + if (matches) return { + fileName: matches[1], + line: parseInt(matches[2], 10) + }; + } + function setBounds(firstLineError, lastLineError) { + if (!longStackTracesIsSupported()) return; + var firstStackLines = (firstLineError.stack || "").split("\n"); + var lastStackLines = (lastLineError.stack || "").split("\n"); + var firstIndex = -1; + var lastIndex = -1; + var firstFileName; + var lastFileName; + for (var i$5 = 0; i$5 < firstStackLines.length; ++i$5) { + var result$1 = parseLineInfo(firstStackLines[i$5]); + if (result$1) { + firstFileName = result$1.fileName; + firstIndex = result$1.line; + break; + } + } + for (var i$5 = 0; i$5 < lastStackLines.length; ++i$5) { + var result$1 = parseLineInfo(lastStackLines[i$5]); + if (result$1) { + lastFileName = result$1.fileName; + lastIndex = result$1.line; + break; + } + } + if (firstIndex < 0 || lastIndex < 0 || !firstFileName || !lastFileName || firstFileName !== lastFileName || firstIndex >= lastIndex) return; + shouldIgnore = function(line) { + if (bluebirdFramePattern.test(line)) return true; + var info = parseLineInfo(line); + if (info) { + if (info.fileName === firstFileName && firstIndex <= info.line && info.line <= lastIndex) return true; + } + return false; + }; + } + function CapturedTrace(parent) { + this._parent = parent; + this._promisesCreated = 0; + var length = this._length = 1 + (parent === void 0 ? 0 : parent._length); + captureStackTrace(this, CapturedTrace); + if (length > 32) this.uncycle(); + } + util$9.inherits(CapturedTrace, Error); + Context.CapturedTrace = CapturedTrace; + CapturedTrace.prototype.uncycle = function() { + var length = this._length; + if (length < 2) return; + var nodes$1 = []; + var stackToIndex = {}; + for (var i$5 = 0, node = this; node !== void 0; ++i$5) { + nodes$1.push(node); + node = node._parent; + } + length = this._length = i$5; + for (var i$5 = length - 1; i$5 >= 0; --i$5) { + var stack = nodes$1[i$5].stack; + if (stackToIndex[stack] === void 0) stackToIndex[stack] = i$5; + } + for (var i$5 = 0; i$5 < length; ++i$5) { + var currentStack = nodes$1[i$5].stack; + var index$1 = stackToIndex[currentStack]; + if (index$1 !== void 0 && index$1 !== i$5) { + if (index$1 > 0) { + nodes$1[index$1 - 1]._parent = void 0; + nodes$1[index$1 - 1]._length = 1; + } + nodes$1[i$5]._parent = void 0; + nodes$1[i$5]._length = 1; + var cycleEdgeNode = i$5 > 0 ? nodes$1[i$5 - 1] : this; + if (index$1 < length - 1) { + cycleEdgeNode._parent = nodes$1[index$1 + 1]; + cycleEdgeNode._parent.uncycle(); + cycleEdgeNode._length = cycleEdgeNode._parent._length + 1; + } else { + cycleEdgeNode._parent = void 0; + cycleEdgeNode._length = 1; + } + var currentChildLength = cycleEdgeNode._length + 1; + for (var j = i$5 - 2; j >= 0; --j) { + nodes$1[j]._length = currentChildLength; + currentChildLength++; + } + return; + } + } + }; + CapturedTrace.prototype.attachExtraTrace = function(error) { + if (error.__stackCleaned__) return; + this.uncycle(); + var parsed = parseStackAndMessage(error); + var message = parsed.message; + var stacks = [parsed.stack]; + var trace = this; + while (trace !== void 0) { + stacks.push(cleanStack(trace.stack.split("\n"))); + trace = trace._parent; + } + removeCommonRoots(stacks); + removeDuplicateOrEmptyJumps(stacks); + util$9.notEnumerableProp(error, "stack", reconstructStack(message, stacks)); + util$9.notEnumerableProp(error, "__stackCleaned__", true); + }; + var captureStackTrace = function stackDetection() { + var v8stackFramePattern = /^\s*at\s*/; + var v8stackFormatter = function(stack, error) { + if (typeof stack === "string") return stack; + if (error.name !== void 0 && error.message !== void 0) return error.toString(); + return formatNonError(error); + }; + if (typeof Error.stackTraceLimit === "number" && typeof Error.captureStackTrace === "function") { + Error.stackTraceLimit += 6; + stackFramePattern = v8stackFramePattern; + formatStack = v8stackFormatter; + var captureStackTrace$1 = Error.captureStackTrace; + shouldIgnore = function(line) { + return bluebirdFramePattern.test(line); + }; + return function(receiver, ignoreUntil) { + Error.stackTraceLimit += 6; + captureStackTrace$1(receiver, ignoreUntil); + Error.stackTraceLimit -= 6; + }; + } + var err = new Error(); + if (typeof err.stack === "string" && err.stack.split("\n")[0].indexOf("stackDetection@") >= 0) { + stackFramePattern = /@/; + formatStack = v8stackFormatter; + indentStackFrames = true; + return function captureStackTrace$2(o) { + o.stack = new Error().stack; + }; + } + var hasStackAfterThrow; + try { + throw new Error(); + } catch (e) { + hasStackAfterThrow = "stack" in e; + } + if (!("stack" in err) && hasStackAfterThrow && typeof Error.stackTraceLimit === "number") { + stackFramePattern = v8stackFramePattern; + formatStack = v8stackFormatter; + return function captureStackTrace$2(o) { + Error.stackTraceLimit += 6; + try { + throw new Error(); + } catch (e) { + o.stack = e.stack; + } + Error.stackTraceLimit -= 6; + }; + } + formatStack = function(stack, error) { + if (typeof stack === "string") return stack; + if ((typeof error === "object" || typeof error === "function") && error.name !== void 0 && error.message !== void 0) return error.toString(); + return formatNonError(error); + }; + return null; + }([]); + if (typeof console !== "undefined" && typeof console.warn !== "undefined") { + printWarning = function(message) { + console.warn(message); + }; + if (util$9.isNode && process.stderr.isTTY) printWarning = function(message, isSoft) { + var color = isSoft ? "\x1B[33m" : "\x1B[31m"; + console.warn(color + message + "\x1B[0m\n"); + }; + else if (!util$9.isNode && typeof new Error().stack === "string") printWarning = function(message, isSoft) { + console.warn("%c" + message, isSoft ? "color: darkorange" : "color: red"); + }; + } + var config$1 = { + warnings: warnings$1, + longStackTraces: false, + cancellation: false, + monitoring: false, + asyncHooks: false + }; + if (longStackTraces) Promise$2.longStackTraces(); + return { + asyncHooks: function() { + return config$1.asyncHooks; + }, + longStackTraces: function() { + return config$1.longStackTraces; + }, + warnings: function() { + return config$1.warnings; + }, + cancellation: function() { + return config$1.cancellation; + }, + monitoring: function() { + return config$1.monitoring; + }, + propagateFromFunction: function() { + return propagateFromFunction; + }, + boundValueFunction: function() { + return boundValueFunction; + }, + checkForgottenReturns, + setBounds, + warn: warn$1, + deprecated, + CapturedTrace, + fireDomEvent, + fireGlobalEvent + }; + }; + }, { + "./errors": 12, + "./es5": 13, + "./util": 36 + }], + 10: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2) { + function returner() { + return this.value; + } + function thrower() { + throw this.reason; + } + Promise$2.prototype["return"] = Promise$2.prototype.thenReturn = function(value) { + if (value instanceof Promise$2) value.suppressUnhandledRejections(); + return this._then(returner, void 0, void 0, { value }, void 0); + }; + Promise$2.prototype["throw"] = Promise$2.prototype.thenThrow = function(reason) { + return this._then(thrower, void 0, void 0, { reason }, void 0); + }; + Promise$2.prototype.catchThrow = function(reason) { + if (arguments.length <= 1) return this._then(void 0, thrower, void 0, { reason }, void 0); + else { + var _reason = arguments[1]; + var handler = function() { + throw _reason; + }; + return this.caught(reason, handler); + } + }; + Promise$2.prototype.catchReturn = function(value) { + if (arguments.length <= 1) { + if (value instanceof Promise$2) value.suppressUnhandledRejections(); + return this._then(void 0, returner, void 0, { value }, void 0); + } else { + var _value = arguments[1]; + if (_value instanceof Promise$2) _value.suppressUnhandledRejections(); + var handler = function() { + return _value; + }; + return this.caught(value, handler); + } + }; + }; + }, {}], + 11: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, INTERNAL) { + var PromiseReduce = Promise$2.reduce; + var PromiseAll = Promise$2.all; + function promiseAllThis() { + return PromiseAll(this); + } + function PromiseMapSeries(promises, fn) { + return PromiseReduce(promises, fn, INTERNAL, INTERNAL); + } + Promise$2.prototype.each = function(fn) { + return PromiseReduce(this, fn, INTERNAL, 0)._then(promiseAllThis, void 0, void 0, this, void 0); + }; + Promise$2.prototype.mapSeries = function(fn) { + return PromiseReduce(this, fn, INTERNAL, INTERNAL); + }; + Promise$2.each = function(promises, fn) { + return PromiseReduce(promises, fn, INTERNAL, 0)._then(promiseAllThis, void 0, void 0, promises, void 0); + }; + Promise$2.mapSeries = PromiseMapSeries; + }; + }, {}], + 12: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + var es5 = _dereq_$1("./es5"); + var Objectfreeze = es5.freeze; + var util$9 = _dereq_$1("./util"); + var inherits$3 = util$9.inherits; + var notEnumerableProp = util$9.notEnumerableProp; + function subError(nameProperty, defaultMessage) { + function SubError(message) { + if (!(this instanceof SubError)) return new SubError(message); + notEnumerableProp(this, "message", typeof message === "string" ? message : defaultMessage); + notEnumerableProp(this, "name", nameProperty); + if (Error.captureStackTrace) Error.captureStackTrace(this, this.constructor); + else Error.call(this); + } + inherits$3(SubError, Error); + return SubError; + } + var _TypeError, _RangeError; + var Warning$4 = subError("Warning", "warning"); + var CancellationError = subError("CancellationError", "cancellation error"); + var TimeoutError = subError("TimeoutError", "timeout error"); + var AggregateError = subError("AggregateError", "aggregate error"); + try { + _TypeError = TypeError; + _RangeError = RangeError; + } catch (e) { + _TypeError = subError("TypeError", "type error"); + _RangeError = subError("RangeError", "range error"); + } + var methods$1 = "join pop push shift unshift slice filter forEach some every map indexOf lastIndexOf reduce reduceRight sort reverse".split(" "); + for (var i$5 = 0; i$5 < methods$1.length; ++i$5) if (typeof Array.prototype[methods$1[i$5]] === "function") AggregateError.prototype[methods$1[i$5]] = Array.prototype[methods$1[i$5]]; + es5.defineProperty(AggregateError.prototype, "length", { + value: 0, + configurable: false, + writable: true, + enumerable: true + }); + AggregateError.prototype["isOperational"] = true; + var level = 0; + AggregateError.prototype.toString = function() { + var indent = Array(level * 4 + 1).join(" "); + var ret = "\n" + indent + "AggregateError of:\n"; + level++; + indent = Array(level * 4 + 1).join(" "); + for (var i$6 = 0; i$6 < this.length; ++i$6) { + var str$3 = this[i$6] === this ? "[Circular AggregateError]" : this[i$6] + ""; + var lines = str$3.split("\n"); + for (var j = 0; j < lines.length; ++j) lines[j] = indent + lines[j]; + str$3 = lines.join("\n"); + ret += str$3 + "\n"; + } + level--; + return ret; + }; + function OperationalError(message) { + if (!(this instanceof OperationalError)) return new OperationalError(message); + notEnumerableProp(this, "name", "OperationalError"); + notEnumerableProp(this, "message", message); + this.cause = message; + this["isOperational"] = true; + if (message instanceof Error) { + notEnumerableProp(this, "message", message.message); + notEnumerableProp(this, "stack", message.stack); + } else if (Error.captureStackTrace) Error.captureStackTrace(this, this.constructor); + } + inherits$3(OperationalError, Error); + var errorTypes = Error["__BluebirdErrorTypes__"]; + if (!errorTypes) { + errorTypes = Objectfreeze({ + CancellationError, + TimeoutError, + OperationalError, + RejectionError: OperationalError, + AggregateError + }); + es5.defineProperty(Error, "__BluebirdErrorTypes__", { + value: errorTypes, + writable: false, + enumerable: false, + configurable: false + }); + } + module$2.exports = { + Error, + TypeError: _TypeError, + RangeError: _RangeError, + CancellationError: errorTypes.CancellationError, + OperationalError: errorTypes.OperationalError, + TimeoutError: errorTypes.TimeoutError, + AggregateError: errorTypes.AggregateError, + Warning: Warning$4 + }; + }, { + "./es5": 13, + "./util": 36 + }], + 13: [function(_dereq_$1, module$2, exports$2) { + var isES5 = function() { + "use strict"; + return this === void 0; + }(); + if (isES5) module$2.exports = { + freeze: Object.freeze, + defineProperty: Object.defineProperty, + getDescriptor: Object.getOwnPropertyDescriptor, + keys: Object.keys, + names: Object.getOwnPropertyNames, + getPrototypeOf: Object.getPrototypeOf, + isArray: Array.isArray, + isES5, + propertyIsWritable: function(obj, prop) { + var descriptor = Object.getOwnPropertyDescriptor(obj, prop); + return !!(!descriptor || descriptor.writable || descriptor.set); + } + }; + else { + var has$3 = {}.hasOwnProperty; + var str$3 = {}.toString; + var proto = {}.constructor.prototype; + var ObjectKeys = function(o) { + var ret = []; + for (var key in o) if (has$3.call(o, key)) ret.push(key); + return ret; + }; + var ObjectGetDescriptor = function(o, key) { + return { value: o[key] }; + }; + var ObjectDefineProperty = function(o, key, desc) { + o[key] = desc.value; + return o; + }; + var ObjectFreeze = function(obj) { + return obj; + }; + var ObjectGetPrototypeOf = function(obj) { + try { + return Object(obj).constructor.prototype; + } catch (e) { + return proto; + } + }; + var ArrayIsArray = function(obj) { + try { + return str$3.call(obj) === "[object Array]"; + } catch (e) { + return false; + } + }; + module$2.exports = { + isArray: ArrayIsArray, + keys: ObjectKeys, + names: ObjectKeys, + defineProperty: ObjectDefineProperty, + getDescriptor: ObjectGetDescriptor, + freeze: ObjectFreeze, + getPrototypeOf: ObjectGetPrototypeOf, + isES5, + propertyIsWritable: function() { + return true; + } + }; + } + }, {}], + 14: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, INTERNAL) { + var PromiseMap = Promise$2.map; + Promise$2.prototype.filter = function(fn, options) { + return PromiseMap(this, fn, options, INTERNAL); + }; + Promise$2.filter = function(promises, fn, options) { + return PromiseMap(promises, fn, options, INTERNAL); + }; + }; + }, {}], + 15: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, tryConvertToPromise, NEXT_FILTER) { + var util$9 = _dereq_$1("./util"); + var CancellationError = Promise$2.CancellationError; + var errorObj = util$9.errorObj; + var catchFilter = _dereq_$1("./catch_filter")(NEXT_FILTER); + function PassThroughHandlerContext(promise, type, handler) { + this.promise = promise; + this.type = type; + this.handler = handler; + this.called = false; + this.cancelPromise = null; + } + PassThroughHandlerContext.prototype.isFinallyHandler = function() { + return this.type === 0; + }; + function FinallyHandlerCancelReaction(finallyHandler$1) { + this.finallyHandler = finallyHandler$1; + } + FinallyHandlerCancelReaction.prototype._resultCancelled = function() { + checkCancel(this.finallyHandler); + }; + function checkCancel(ctx, reason) { + if (ctx.cancelPromise != null) { + if (arguments.length > 1) ctx.cancelPromise._reject(reason); + else ctx.cancelPromise._cancel(); + ctx.cancelPromise = null; + return true; + } + return false; + } + function succeed() { + return finallyHandler.call(this, this.promise._target()._settledValue()); + } + function fail(reason) { + if (checkCancel(this, reason)) return; + errorObj.e = reason; + return errorObj; + } + function finallyHandler(reasonOrValue) { + var promise = this.promise; + var handler = this.handler; + if (!this.called) { + this.called = true; + var ret = this.isFinallyHandler() ? handler.call(promise._boundValue()) : handler.call(promise._boundValue(), reasonOrValue); + if (ret === NEXT_FILTER) return ret; + else if (ret !== void 0) { + promise._setReturnedNonUndefined(); + var maybePromise = tryConvertToPromise(ret, promise); + if (maybePromise instanceof Promise$2) { + if (this.cancelPromise != null) { + if (maybePromise._isCancelled()) { + var reason = new CancellationError("late cancellation observer"); + promise._attachExtraTrace(reason); + errorObj.e = reason; + return errorObj; + } else if (maybePromise.isPending()) maybePromise._attachCancellationCallback(new FinallyHandlerCancelReaction(this)); + } + return maybePromise._then(succeed, fail, void 0, this, void 0); + } + } + } + if (promise.isRejected()) { + checkCancel(this); + errorObj.e = reasonOrValue; + return errorObj; + } else { + checkCancel(this); + return reasonOrValue; + } + } + Promise$2.prototype._passThrough = function(handler, type, success, fail$1) { + if (typeof handler !== "function") return this.then(); + return this._then(success, fail$1, void 0, new PassThroughHandlerContext(this, type, handler), void 0); + }; + Promise$2.prototype.lastly = Promise$2.prototype["finally"] = function(handler) { + return this._passThrough(handler, 0, finallyHandler, finallyHandler); + }; + Promise$2.prototype.tap = function(handler) { + return this._passThrough(handler, 1, finallyHandler); + }; + Promise$2.prototype.tapCatch = function(handlerOrPredicate) { + var len = arguments.length; + if (len === 1) return this._passThrough(handlerOrPredicate, 1, void 0, finallyHandler); + else { + var catchInstances = new Array(len - 1), j = 0, i$5; + for (i$5 = 0; i$5 < len - 1; ++i$5) { + var item = arguments[i$5]; + if (util$9.isObject(item)) catchInstances[j++] = item; + else return Promise$2.reject(new TypeError("tapCatch statement predicate: expecting an object but got " + util$9.classString(item))); + } + catchInstances.length = j; + var handler = arguments[i$5]; + return this._passThrough(catchFilter(catchInstances, handler, this), 1, void 0, finallyHandler); + } + }; + return PassThroughHandlerContext; + }; + }, { + "./catch_filter": 7, + "./util": 36 + }], + 16: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, apiRejection, INTERNAL, tryConvertToPromise, Proxyable, debug$2) { + var errors = _dereq_$1("./errors"); + var TypeError$1 = errors.TypeError; + var util$9 = _dereq_$1("./util"); + var errorObj = util$9.errorObj; + var tryCatch = util$9.tryCatch; + var yieldHandlers = []; + function promiseFromYieldHandler(value, yieldHandlers$1, traceParent) { + for (var i$5 = 0; i$5 < yieldHandlers$1.length; ++i$5) { + traceParent._pushContext(); + var result$1 = tryCatch(yieldHandlers$1[i$5])(value); + traceParent._popContext(); + if (result$1 === errorObj) { + traceParent._pushContext(); + var ret = Promise$2.reject(errorObj.e); + traceParent._popContext(); + return ret; + } + var maybePromise = tryConvertToPromise(result$1, traceParent); + if (maybePromise instanceof Promise$2) return maybePromise; + } + return null; + } + function PromiseSpawn(generatorFunction, receiver, yieldHandler, stack) { + if (debug$2.cancellation()) { + var internal = new Promise$2(INTERNAL); + var _finallyPromise = this._finallyPromise = new Promise$2(INTERNAL); + this._promise = internal.lastly(function() { + return _finallyPromise; + }); + internal._captureStackTrace(); + internal._setOnCancel(this); + } else { + var promise = this._promise = new Promise$2(INTERNAL); + promise._captureStackTrace(); + } + this._stack = stack; + this._generatorFunction = generatorFunction; + this._receiver = receiver; + this._generator = void 0; + this._yieldHandlers = typeof yieldHandler === "function" ? [yieldHandler].concat(yieldHandlers) : yieldHandlers; + this._yieldedPromise = null; + this._cancellationPhase = false; + } + util$9.inherits(PromiseSpawn, Proxyable); + PromiseSpawn.prototype._isResolved = function() { + return this._promise === null; + }; + PromiseSpawn.prototype._cleanup = function() { + this._promise = this._generator = null; + if (debug$2.cancellation() && this._finallyPromise !== null) { + this._finallyPromise._fulfill(); + this._finallyPromise = null; + } + }; + PromiseSpawn.prototype._promiseCancelled = function() { + if (this._isResolved()) return; + var implementsReturn = typeof this._generator["return"] !== "undefined"; + var result$1; + if (!implementsReturn) { + var reason = new Promise$2.CancellationError("generator .return() sentinel"); + Promise$2.coroutine.returnSentinel = reason; + this._promise._attachExtraTrace(reason); + this._promise._pushContext(); + result$1 = tryCatch(this._generator["throw"]).call(this._generator, reason); + this._promise._popContext(); + } else { + this._promise._pushContext(); + result$1 = tryCatch(this._generator["return"]).call(this._generator, void 0); + this._promise._popContext(); + } + this._cancellationPhase = true; + this._yieldedPromise = null; + this._continue(result$1); + }; + PromiseSpawn.prototype._promiseFulfilled = function(value) { + this._yieldedPromise = null; + this._promise._pushContext(); + var result$1 = tryCatch(this._generator.next).call(this._generator, value); + this._promise._popContext(); + this._continue(result$1); + }; + PromiseSpawn.prototype._promiseRejected = function(reason) { + this._yieldedPromise = null; + this._promise._attachExtraTrace(reason); + this._promise._pushContext(); + var result$1 = tryCatch(this._generator["throw"]).call(this._generator, reason); + this._promise._popContext(); + this._continue(result$1); + }; + PromiseSpawn.prototype._resultCancelled = function() { + if (this._yieldedPromise instanceof Promise$2) { + var promise = this._yieldedPromise; + this._yieldedPromise = null; + promise.cancel(); + } + }; + PromiseSpawn.prototype.promise = function() { + return this._promise; + }; + PromiseSpawn.prototype._run = function() { + this._generator = this._generatorFunction.call(this._receiver); + this._receiver = this._generatorFunction = void 0; + this._promiseFulfilled(void 0); + }; + PromiseSpawn.prototype._continue = function(result$1) { + var promise = this._promise; + if (result$1 === errorObj) { + this._cleanup(); + if (this._cancellationPhase) return promise.cancel(); + else return promise._rejectCallback(result$1.e, false); + } + var value = result$1.value; + if (result$1.done === true) { + this._cleanup(); + if (this._cancellationPhase) return promise.cancel(); + else return promise._resolveCallback(value); + } else { + var maybePromise = tryConvertToPromise(value, this._promise); + if (!(maybePromise instanceof Promise$2)) { + maybePromise = promiseFromYieldHandler(maybePromise, this._yieldHandlers, this._promise); + if (maybePromise === null) { + this._promiseRejected(new TypeError$1("A value %s was yielded that could not be treated as a promise\n\n See http://goo.gl/MqrFmX\n\n".replace("%s", String(value)) + "From coroutine:\n" + this._stack.split("\n").slice(1, -7).join("\n"))); + return; + } + } + maybePromise = maybePromise._target(); + var bitField = maybePromise._bitField; + if ((bitField & 50397184) === 0) { + this._yieldedPromise = maybePromise; + maybePromise._proxy(this, null); + } else if ((bitField & 33554432) !== 0) Promise$2._async.invoke(this._promiseFulfilled, this, maybePromise._value()); + else if ((bitField & 16777216) !== 0) Promise$2._async.invoke(this._promiseRejected, this, maybePromise._reason()); + else this._promiseCancelled(); + } + }; + Promise$2.coroutine = function(generatorFunction, options) { + if (typeof generatorFunction !== "function") throw new TypeError$1("generatorFunction must be a function\n\n See http://goo.gl/MqrFmX\n"); + var yieldHandler = Object(options).yieldHandler; + var PromiseSpawn$ = PromiseSpawn; + var stack = new Error().stack; + return function() { + var generator$1 = generatorFunction.apply(this, arguments); + var spawn = new PromiseSpawn$(void 0, void 0, yieldHandler, stack); + var ret = spawn.promise(); + spawn._generator = generator$1; + spawn._promiseFulfilled(void 0); + return ret; + }; + }; + Promise$2.coroutine.addYieldHandler = function(fn) { + if (typeof fn !== "function") throw new TypeError$1("expecting a function but got " + util$9.classString(fn)); + yieldHandlers.push(fn); + }; + Promise$2.spawn = function(generatorFunction) { + debug$2.deprecated("Promise.spawn()", "Promise.coroutine()"); + if (typeof generatorFunction !== "function") return apiRejection("generatorFunction must be a function\n\n See http://goo.gl/MqrFmX\n"); + var spawn = new PromiseSpawn(generatorFunction, this); + var ret = spawn.promise(); + spawn._run(Promise$2.spawn); + return ret; + }; + }; + }, { + "./errors": 12, + "./util": 36 + }], + 17: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, PromiseArray, tryConvertToPromise, INTERNAL, async$1) { + var util$9 = _dereq_$1("./util"); + var canEvaluate = util$9.canEvaluate; + var tryCatch = util$9.tryCatch; + var errorObj = util$9.errorObj; + var reject$1; + if (0) var thenCallback, promiseSetter, generateHolderClass, holderClasses, thenCallbacks, promiseSetters, i$5; + Promise$2.join = function() { + var last$3 = arguments.length - 1; + var fn; + if (last$3 > 0 && typeof arguments[last$3] === "function") { + fn = arguments[last$3]; + if (0) var ret, HolderClass, holder, callbacks, i$6, maybePromise, bitField, context; + } + var args = [].slice.call(arguments); + if (fn) args.pop(); + var ret = new PromiseArray(args).promise(); + return fn !== void 0 ? ret.spread(fn) : ret; + }; + }; + }, { "./util": 36 }], + 18: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, PromiseArray, apiRejection, tryConvertToPromise, INTERNAL, debug$2) { + var util$9 = _dereq_$1("./util"); + var tryCatch = util$9.tryCatch; + var errorObj = util$9.errorObj; + var async$1 = Promise$2._async; + function MappingPromiseArray(promises, fn, limit, _filter) { + this.constructor$(promises); + this._promise._captureStackTrace(); + var context = Promise$2._getContext(); + this._callback = util$9.contextBind(context, fn); + this._preservedValues = _filter === INTERNAL ? new Array(this.length()) : null; + this._limit = limit; + this._inFlight = 0; + this._queue = []; + async$1.invoke(this._asyncInit, this, void 0); + if (util$9.isArray(promises)) for (var i$5 = 0; i$5 < promises.length; ++i$5) { + var maybePromise = promises[i$5]; + if (maybePromise instanceof Promise$2) maybePromise.suppressUnhandledRejections(); + } + } + util$9.inherits(MappingPromiseArray, PromiseArray); + MappingPromiseArray.prototype._asyncInit = function() { + this._init$(void 0, -2); + }; + MappingPromiseArray.prototype._init = function() {}; + MappingPromiseArray.prototype._promiseFulfilled = function(value, index$1) { + var values$1 = this._values; + var length = this.length(); + var preservedValues = this._preservedValues; + var limit = this._limit; + if (index$1 < 0) { + index$1 = index$1 * -1 - 1; + values$1[index$1] = value; + if (limit >= 1) { + this._inFlight--; + this._drainQueue(); + if (this._isResolved()) return true; + } + } else { + if (limit >= 1 && this._inFlight >= limit) { + values$1[index$1] = value; + this._queue.push(index$1); + return false; + } + if (preservedValues !== null) preservedValues[index$1] = value; + var promise = this._promise; + var callback = this._callback; + var receiver = promise._boundValue(); + promise._pushContext(); + var ret = tryCatch(callback).call(receiver, value, index$1, length); + var promiseCreated = promise._popContext(); + debug$2.checkForgottenReturns(ret, promiseCreated, preservedValues !== null ? "Promise.filter" : "Promise.map", promise); + if (ret === errorObj) { + this._reject(ret.e); + return true; + } + var maybePromise = tryConvertToPromise(ret, this._promise); + if (maybePromise instanceof Promise$2) { + maybePromise = maybePromise._target(); + var bitField = maybePromise._bitField; + if ((bitField & 50397184) === 0) { + if (limit >= 1) this._inFlight++; + values$1[index$1] = maybePromise; + maybePromise._proxy(this, (index$1 + 1) * -1); + return false; + } else if ((bitField & 33554432) !== 0) ret = maybePromise._value(); + else if ((bitField & 16777216) !== 0) { + this._reject(maybePromise._reason()); + return true; + } else { + this._cancel(); + return true; + } + } + values$1[index$1] = ret; + } + var totalResolved = ++this._totalResolved; + if (totalResolved >= length) { + if (preservedValues !== null) this._filter(values$1, preservedValues); + else this._resolve(values$1); + return true; + } + return false; + }; + MappingPromiseArray.prototype._drainQueue = function() { + var queue$1 = this._queue; + var limit = this._limit; + var values$1 = this._values; + while (queue$1.length > 0 && this._inFlight < limit) { + if (this._isResolved()) return; + var index$1 = queue$1.pop(); + this._promiseFulfilled(values$1[index$1], index$1); + } + }; + MappingPromiseArray.prototype._filter = function(booleans, values$1) { + var len = values$1.length; + var ret = new Array(len); + var j = 0; + for (var i$5 = 0; i$5 < len; ++i$5) if (booleans[i$5]) ret[j++] = values$1[i$5]; + ret.length = j; + this._resolve(ret); + }; + MappingPromiseArray.prototype.preservedValues = function() { + return this._preservedValues; + }; + function map$1(promises, fn, options, _filter) { + if (typeof fn !== "function") return apiRejection("expecting a function but got " + util$9.classString(fn)); + var limit = 0; + if (options !== void 0) if (typeof options === "object" && options !== null) { + if (typeof options.concurrency !== "number") return Promise$2.reject(new TypeError("'concurrency' must be a number but it is " + util$9.classString(options.concurrency))); + limit = options.concurrency; + } else return Promise$2.reject(new TypeError("options argument must be an object but it is " + util$9.classString(options))); + limit = typeof limit === "number" && isFinite(limit) && limit >= 1 ? limit : 0; + return new MappingPromiseArray(promises, fn, limit, _filter).promise(); + } + Promise$2.prototype.map = function(fn, options) { + return map$1(this, fn, options, null); + }; + Promise$2.map = function(promises, fn, options, _filter) { + return map$1(promises, fn, options, _filter); + }; + }; + }, { "./util": 36 }], + 19: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, INTERNAL, tryConvertToPromise, apiRejection, debug$2) { + var util$9 = _dereq_$1("./util"); + var tryCatch = util$9.tryCatch; + Promise$2.method = function(fn) { + if (typeof fn !== "function") throw new Promise$2.TypeError("expecting a function but got " + util$9.classString(fn)); + return function() { + var ret = new Promise$2(INTERNAL); + ret._captureStackTrace(); + ret._pushContext(); + var value = tryCatch(fn).apply(this, arguments); + var promiseCreated = ret._popContext(); + debug$2.checkForgottenReturns(value, promiseCreated, "Promise.method", ret); + ret._resolveFromSyncValue(value); + return ret; + }; + }; + Promise$2.attempt = Promise$2["try"] = function(fn) { + if (typeof fn !== "function") return apiRejection("expecting a function but got " + util$9.classString(fn)); + var ret = new Promise$2(INTERNAL); + ret._captureStackTrace(); + ret._pushContext(); + var value; + if (arguments.length > 1) { + debug$2.deprecated("calling Promise.try with more than 1 argument"); + var arg = arguments[1]; + var ctx = arguments[2]; + value = util$9.isArray(arg) ? tryCatch(fn).apply(ctx, arg) : tryCatch(fn).call(ctx, arg); + } else value = tryCatch(fn)(); + var promiseCreated = ret._popContext(); + debug$2.checkForgottenReturns(value, promiseCreated, "Promise.try", ret); + ret._resolveFromSyncValue(value); + return ret; + }; + Promise$2.prototype._resolveFromSyncValue = function(value) { + if (value === util$9.errorObj) this._rejectCallback(value.e, false); + else this._resolveCallback(value, true); + }; + }; + }, { "./util": 36 }], + 20: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + var util$9 = _dereq_$1("./util"); + var maybeWrapAsError = util$9.maybeWrapAsError; + var errors = _dereq_$1("./errors"); + var OperationalError = errors.OperationalError; + var es5 = _dereq_$1("./es5"); + function isUntypedError(obj) { + return obj instanceof Error && es5.getPrototypeOf(obj) === Error.prototype; + } + var rErrorKey = /^(?:name|message|stack|cause)$/; + function wrapAsOperationalError(obj) { + var ret; + if (isUntypedError(obj)) { + ret = new OperationalError(obj); + ret.name = obj.name; + ret.message = obj.message; + ret.stack = obj.stack; + var keys$2 = es5.keys(obj); + for (var i$5 = 0; i$5 < keys$2.length; ++i$5) { + var key = keys$2[i$5]; + if (!rErrorKey.test(key)) ret[key] = obj[key]; + } + return ret; + } + util$9.markAsOriginatingFromRejection(obj); + return obj; + } + function nodebackForPromise(promise, multiArgs) { + return function(err, value) { + if (promise === null) return; + if (err) { + var wrapped = wrapAsOperationalError(maybeWrapAsError(err)); + promise._attachExtraTrace(wrapped); + promise._reject(wrapped); + } else if (!multiArgs) promise._fulfill(value); + else { + var args = [].slice.call(arguments, 1); + promise._fulfill(args); + } + promise = null; + }; + } + module$2.exports = nodebackForPromise; + }, { + "./errors": 12, + "./es5": 13, + "./util": 36 + }], + 21: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2) { + var util$9 = _dereq_$1("./util"); + var async$1 = Promise$2._async; + var tryCatch = util$9.tryCatch; + var errorObj = util$9.errorObj; + function spreadAdapter(val, nodeback) { + var promise = this; + if (!util$9.isArray(val)) return successAdapter.call(promise, val, nodeback); + var ret = tryCatch(nodeback).apply(promise._boundValue(), [null].concat(val)); + if (ret === errorObj) async$1.throwLater(ret.e); + } + function successAdapter(val, nodeback) { + var promise = this; + var receiver = promise._boundValue(); + var ret = val === void 0 ? tryCatch(nodeback).call(receiver, null) : tryCatch(nodeback).call(receiver, null, val); + if (ret === errorObj) async$1.throwLater(ret.e); + } + function errorAdapter(reason, nodeback) { + var promise = this; + if (!reason) { + var newReason = new Error(reason + ""); + newReason.cause = reason; + reason = newReason; + } + var ret = tryCatch(nodeback).call(promise._boundValue(), reason); + if (ret === errorObj) async$1.throwLater(ret.e); + } + Promise$2.prototype.asCallback = Promise$2.prototype.nodeify = function(nodeback, options) { + if (typeof nodeback == "function") { + var adapter = successAdapter; + if (options !== void 0 && Object(options).spread) adapter = spreadAdapter; + this._then(adapter, errorAdapter, void 0, this, nodeback); + } + return this; + }; + }; + }, { "./util": 36 }], + 22: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function() { + var makeSelfResolutionError = function() { + return new TypeError$1("circular promise resolution chain\n\n See http://goo.gl/MqrFmX\n"); + }; + var reflectHandler = function() { + return new Promise$2.PromiseInspection(this._target()); + }; + var apiRejection = function(msg) { + return Promise$2.reject(new TypeError$1(msg)); + }; + function Proxyable() {} + var UNDEFINED_BINDING = {}; + var util$9 = _dereq_$1("./util"); + util$9.setReflectHandler(reflectHandler); + var getDomain = function() { + var domain = process.domain; + if (domain === void 0) return null; + return domain; + }; + var getContextDefault = function() { + return null; + }; + var getContextDomain = function() { + return { + domain: getDomain(), + async: null + }; + }; + var AsyncResource = util$9.isNode && util$9.nodeSupportsAsyncResource ? _dereq_$1("async_hooks").AsyncResource : null; + var getContextAsyncHooks = function() { + return { + domain: getDomain(), + async: new AsyncResource("Bluebird::Promise") + }; + }; + var getContext = util$9.isNode ? getContextDomain : getContextDefault; + util$9.notEnumerableProp(Promise$2, "_getContext", getContext); + var enableAsyncHooks = function() { + getContext = getContextAsyncHooks; + util$9.notEnumerableProp(Promise$2, "_getContext", getContextAsyncHooks); + }; + var disableAsyncHooks = function() { + getContext = getContextDomain; + util$9.notEnumerableProp(Promise$2, "_getContext", getContextDomain); + }; + var es5 = _dereq_$1("./es5"); + var Async = _dereq_$1("./async"); + var async$1 = new Async(); + es5.defineProperty(Promise$2, "_async", { value: async$1 }); + var errors = _dereq_$1("./errors"); + var TypeError$1 = Promise$2.TypeError = errors.TypeError; + Promise$2.RangeError = errors.RangeError; + var CancellationError = Promise$2.CancellationError = errors.CancellationError; + Promise$2.TimeoutError = errors.TimeoutError; + Promise$2.OperationalError = errors.OperationalError; + Promise$2.RejectionError = errors.OperationalError; + Promise$2.AggregateError = errors.AggregateError; + var INTERNAL = function() {}; + var APPLY = {}; + var NEXT_FILTER = {}; + var tryConvertToPromise = _dereq_$1("./thenables")(Promise$2, INTERNAL); + var PromiseArray = _dereq_$1("./promise_array")(Promise$2, INTERNAL, tryConvertToPromise, apiRejection, Proxyable); + var Context = _dereq_$1("./context")(Promise$2); + var createContext = Context.create; + var debug$2 = _dereq_$1("./debuggability")(Promise$2, Context, enableAsyncHooks, disableAsyncHooks); + var CapturedTrace = debug$2.CapturedTrace; + var PassThroughHandlerContext = _dereq_$1("./finally")(Promise$2, tryConvertToPromise, NEXT_FILTER); + var catchFilter = _dereq_$1("./catch_filter")(NEXT_FILTER); + var nodebackForPromise = _dereq_$1("./nodeback"); + var errorObj = util$9.errorObj; + var tryCatch = util$9.tryCatch; + function check(self$1, executor) { + if (self$1 == null || self$1.constructor !== Promise$2) throw new TypeError$1("the promise constructor cannot be invoked directly\n\n See http://goo.gl/MqrFmX\n"); + if (typeof executor !== "function") throw new TypeError$1("expecting a function but got " + util$9.classString(executor)); + } + function Promise$2(executor) { + if (executor !== INTERNAL) check(this, executor); + this._bitField = 0; + this._fulfillmentHandler0 = void 0; + this._rejectionHandler0 = void 0; + this._promise0 = void 0; + this._receiver0 = void 0; + this._resolveFromExecutor(executor); + this._promiseCreated(); + this._fireEvent("promiseCreated", this); + } + Promise$2.prototype.toString = function() { + return "[object Promise]"; + }; + Promise$2.prototype.caught = Promise$2.prototype["catch"] = function(fn) { + var len = arguments.length; + if (len > 1) { + var catchInstances = new Array(len - 1), j = 0, i$5; + for (i$5 = 0; i$5 < len - 1; ++i$5) { + var item = arguments[i$5]; + if (util$9.isObject(item)) catchInstances[j++] = item; + else return apiRejection("Catch statement predicate: expecting an object but got " + util$9.classString(item)); + } + catchInstances.length = j; + fn = arguments[i$5]; + if (typeof fn !== "function") throw new TypeError$1("The last argument to .catch() must be a function, got " + util$9.toString(fn)); + return this.then(void 0, catchFilter(catchInstances, fn, this)); + } + return this.then(void 0, fn); + }; + Promise$2.prototype.reflect = function() { + return this._then(reflectHandler, reflectHandler, void 0, this, void 0); + }; + Promise$2.prototype.then = function(didFulfill, didReject) { + if (debug$2.warnings() && arguments.length > 0 && typeof didFulfill !== "function" && typeof didReject !== "function") { + var msg = ".then() only accepts functions but was passed: " + util$9.classString(didFulfill); + if (arguments.length > 1) msg += ", " + util$9.classString(didReject); + this._warn(msg); + } + return this._then(didFulfill, didReject, void 0, void 0, void 0); + }; + Promise$2.prototype.done = function(didFulfill, didReject) { + var promise = this._then(didFulfill, didReject, void 0, void 0, void 0); + promise._setIsFinal(); + }; + Promise$2.prototype.spread = function(fn) { + if (typeof fn !== "function") return apiRejection("expecting a function but got " + util$9.classString(fn)); + return this.all()._then(fn, void 0, void 0, APPLY, void 0); + }; + Promise$2.prototype.toJSON = function() { + var ret = { + isFulfilled: false, + isRejected: false, + fulfillmentValue: void 0, + rejectionReason: void 0 + }; + if (this.isFulfilled()) { + ret.fulfillmentValue = this.value(); + ret.isFulfilled = true; + } else if (this.isRejected()) { + ret.rejectionReason = this.reason(); + ret.isRejected = true; + } + return ret; + }; + Promise$2.prototype.all = function() { + if (arguments.length > 0) this._warn(".all() was passed arguments but it does not take any"); + return new PromiseArray(this).promise(); + }; + Promise$2.prototype.error = function(fn) { + return this.caught(util$9.originatesFromRejection, fn); + }; + Promise$2.getNewLibraryCopy = module$2.exports; + Promise$2.is = function(val) { + return val instanceof Promise$2; + }; + Promise$2.fromNode = Promise$2.fromCallback = function(fn) { + var ret = new Promise$2(INTERNAL); + ret._captureStackTrace(); + var multiArgs = arguments.length > 1 ? !!Object(arguments[1]).multiArgs : false; + var result$1 = tryCatch(fn)(nodebackForPromise(ret, multiArgs)); + if (result$1 === errorObj) ret._rejectCallback(result$1.e, true); + if (!ret._isFateSealed()) ret._setAsyncGuaranteed(); + return ret; + }; + Promise$2.all = function(promises) { + return new PromiseArray(promises).promise(); + }; + Promise$2.cast = function(obj) { + var ret = tryConvertToPromise(obj); + if (!(ret instanceof Promise$2)) { + ret = new Promise$2(INTERNAL); + ret._captureStackTrace(); + ret._setFulfilled(); + ret._rejectionHandler0 = obj; + } + return ret; + }; + Promise$2.resolve = Promise$2.fulfilled = Promise$2.cast; + Promise$2.reject = Promise$2.rejected = function(reason) { + var ret = new Promise$2(INTERNAL); + ret._captureStackTrace(); + ret._rejectCallback(reason, true); + return ret; + }; + Promise$2.setScheduler = function(fn) { + if (typeof fn !== "function") throw new TypeError$1("expecting a function but got " + util$9.classString(fn)); + return async$1.setScheduler(fn); + }; + Promise$2.prototype._then = function(didFulfill, didReject, _$2, receiver, internalData) { + var haveInternalData = internalData !== void 0; + var promise = haveInternalData ? internalData : new Promise$2(INTERNAL); + var target = this._target(); + var bitField = target._bitField; + if (!haveInternalData) { + promise._propagateFrom(this, 3); + promise._captureStackTrace(); + if (receiver === void 0 && (this._bitField & 2097152) !== 0) if (!((bitField & 50397184) === 0)) receiver = this._boundValue(); + else receiver = target === this ? void 0 : this._boundTo; + this._fireEvent("promiseChained", this, promise); + } + var context = getContext(); + if (!((bitField & 50397184) === 0)) { + var handler, value, settler = target._settlePromiseCtx; + if ((bitField & 33554432) !== 0) { + value = target._rejectionHandler0; + handler = didFulfill; + } else if ((bitField & 16777216) !== 0) { + value = target._fulfillmentHandler0; + handler = didReject; + target._unsetRejectionIsUnhandled(); + } else { + settler = target._settlePromiseLateCancellationObserver; + value = new CancellationError("late cancellation observer"); + target._attachExtraTrace(value); + handler = didReject; + } + async$1.invoke(settler, target, { + handler: util$9.contextBind(context, handler), + promise, + receiver, + value + }); + } else target._addCallbacks(didFulfill, didReject, promise, receiver, context); + return promise; + }; + Promise$2.prototype._length = function() { + return this._bitField & 65535; + }; + Promise$2.prototype._isFateSealed = function() { + return (this._bitField & 117506048) !== 0; + }; + Promise$2.prototype._isFollowing = function() { + return (this._bitField & 67108864) === 67108864; + }; + Promise$2.prototype._setLength = function(len) { + this._bitField = this._bitField & -65536 | len & 65535; + }; + Promise$2.prototype._setFulfilled = function() { + this._bitField = this._bitField | 33554432; + this._fireEvent("promiseFulfilled", this); + }; + Promise$2.prototype._setRejected = function() { + this._bitField = this._bitField | 16777216; + this._fireEvent("promiseRejected", this); + }; + Promise$2.prototype._setFollowing = function() { + this._bitField = this._bitField | 67108864; + this._fireEvent("promiseResolved", this); + }; + Promise$2.prototype._setIsFinal = function() { + this._bitField = this._bitField | 4194304; + }; + Promise$2.prototype._isFinal = function() { + return (this._bitField & 4194304) > 0; + }; + Promise$2.prototype._unsetCancelled = function() { + this._bitField = this._bitField & -65537; + }; + Promise$2.prototype._setCancelled = function() { + this._bitField = this._bitField | 65536; + this._fireEvent("promiseCancelled", this); + }; + Promise$2.prototype._setWillBeCancelled = function() { + this._bitField = this._bitField | 8388608; + }; + Promise$2.prototype._setAsyncGuaranteed = function() { + if (async$1.hasCustomScheduler()) return; + var bitField = this._bitField; + this._bitField = bitField | (bitField & 536870912) >> 2 ^ 134217728; + }; + Promise$2.prototype._setNoAsyncGuarantee = function() { + this._bitField = (this._bitField | 536870912) & -134217729; + }; + Promise$2.prototype._receiverAt = function(index$1) { + var ret = index$1 === 0 ? this._receiver0 : this[index$1 * 4 - 4 + 3]; + if (ret === UNDEFINED_BINDING) return void 0; + else if (ret === void 0 && this._isBound()) return this._boundValue(); + return ret; + }; + Promise$2.prototype._promiseAt = function(index$1) { + return this[index$1 * 4 - 4 + 2]; + }; + Promise$2.prototype._fulfillmentHandlerAt = function(index$1) { + return this[index$1 * 4 - 4 + 0]; + }; + Promise$2.prototype._rejectionHandlerAt = function(index$1) { + return this[index$1 * 4 - 4 + 1]; + }; + Promise$2.prototype._boundValue = function() {}; + Promise$2.prototype._migrateCallback0 = function(follower) { + var bitField = follower._bitField; + var fulfill = follower._fulfillmentHandler0; + var reject$1 = follower._rejectionHandler0; + var promise = follower._promise0; + var receiver = follower._receiverAt(0); + if (receiver === void 0) receiver = UNDEFINED_BINDING; + this._addCallbacks(fulfill, reject$1, promise, receiver, null); + }; + Promise$2.prototype._migrateCallbackAt = function(follower, index$1) { + var fulfill = follower._fulfillmentHandlerAt(index$1); + var reject$1 = follower._rejectionHandlerAt(index$1); + var promise = follower._promiseAt(index$1); + var receiver = follower._receiverAt(index$1); + if (receiver === void 0) receiver = UNDEFINED_BINDING; + this._addCallbacks(fulfill, reject$1, promise, receiver, null); + }; + Promise$2.prototype._addCallbacks = function(fulfill, reject$1, promise, receiver, context) { + var index$1 = this._length(); + if (index$1 >= 65531) { + index$1 = 0; + this._setLength(0); + } + if (index$1 === 0) { + this._promise0 = promise; + this._receiver0 = receiver; + if (typeof fulfill === "function") this._fulfillmentHandler0 = util$9.contextBind(context, fulfill); + if (typeof reject$1 === "function") this._rejectionHandler0 = util$9.contextBind(context, reject$1); + } else { + var base$1 = index$1 * 4 - 4; + this[base$1 + 2] = promise; + this[base$1 + 3] = receiver; + if (typeof fulfill === "function") this[base$1 + 0] = util$9.contextBind(context, fulfill); + if (typeof reject$1 === "function") this[base$1 + 1] = util$9.contextBind(context, reject$1); + } + this._setLength(index$1 + 1); + return index$1; + }; + Promise$2.prototype._proxy = function(proxyable, arg) { + this._addCallbacks(void 0, void 0, arg, proxyable, null); + }; + Promise$2.prototype._resolveCallback = function(value, shouldBind) { + if ((this._bitField & 117506048) !== 0) return; + if (value === this) return this._rejectCallback(makeSelfResolutionError(), false); + var maybePromise = tryConvertToPromise(value, this); + if (!(maybePromise instanceof Promise$2)) return this._fulfill(value); + if (shouldBind) this._propagateFrom(maybePromise, 2); + var promise = maybePromise._target(); + if (promise === this) { + this._reject(makeSelfResolutionError()); + return; + } + var bitField = promise._bitField; + if ((bitField & 50397184) === 0) { + var len = this._length(); + if (len > 0) promise._migrateCallback0(this); + for (var i$5 = 1; i$5 < len; ++i$5) promise._migrateCallbackAt(this, i$5); + this._setFollowing(); + this._setLength(0); + this._setFollowee(maybePromise); + } else if ((bitField & 33554432) !== 0) this._fulfill(promise._value()); + else if ((bitField & 16777216) !== 0) this._reject(promise._reason()); + else { + var reason = new CancellationError("late cancellation observer"); + promise._attachExtraTrace(reason); + this._reject(reason); + } + }; + Promise$2.prototype._rejectCallback = function(reason, synchronous, ignoreNonErrorWarnings) { + var trace = util$9.ensureErrorObject(reason); + var hasStack = trace === reason; + if (!hasStack && !ignoreNonErrorWarnings && debug$2.warnings()) { + var message = "a promise was rejected with a non-error: " + util$9.classString(reason); + this._warn(message, true); + } + this._attachExtraTrace(trace, synchronous ? hasStack : false); + this._reject(reason); + }; + Promise$2.prototype._resolveFromExecutor = function(executor) { + if (executor === INTERNAL) return; + var promise = this; + this._captureStackTrace(); + this._pushContext(); + var synchronous = true; + var r = this._execute(executor, function(value) { + promise._resolveCallback(value); + }, function(reason) { + promise._rejectCallback(reason, synchronous); + }); + synchronous = false; + this._popContext(); + if (r !== void 0) promise._rejectCallback(r, true); + }; + Promise$2.prototype._settlePromiseFromHandler = function(handler, receiver, value, promise) { + var bitField = promise._bitField; + if ((bitField & 65536) !== 0) return; + promise._pushContext(); + var x$2; + if (receiver === APPLY) if (!value || typeof value.length !== "number") { + x$2 = errorObj; + x$2.e = new TypeError$1("cannot .spread() a non-array: " + util$9.classString(value)); + } else x$2 = tryCatch(handler).apply(this._boundValue(), value); + else x$2 = tryCatch(handler).call(receiver, value); + var promiseCreated = promise._popContext(); + bitField = promise._bitField; + if ((bitField & 65536) !== 0) return; + if (x$2 === NEXT_FILTER) promise._reject(value); + else if (x$2 === errorObj) promise._rejectCallback(x$2.e, false); + else { + debug$2.checkForgottenReturns(x$2, promiseCreated, "", promise, this); + promise._resolveCallback(x$2); + } + }; + Promise$2.prototype._target = function() { + var ret = this; + while (ret._isFollowing()) ret = ret._followee(); + return ret; + }; + Promise$2.prototype._followee = function() { + return this._rejectionHandler0; + }; + Promise$2.prototype._setFollowee = function(promise) { + this._rejectionHandler0 = promise; + }; + Promise$2.prototype._settlePromise = function(promise, handler, receiver, value) { + var isPromise$2 = promise instanceof Promise$2; + var bitField = this._bitField; + var asyncGuaranteed = (bitField & 134217728) !== 0; + if ((bitField & 65536) !== 0) { + if (isPromise$2) promise._invokeInternalOnCancel(); + if (receiver instanceof PassThroughHandlerContext && receiver.isFinallyHandler()) { + receiver.cancelPromise = promise; + if (tryCatch(handler).call(receiver, value) === errorObj) promise._reject(errorObj.e); + } else if (handler === reflectHandler) promise._fulfill(reflectHandler.call(receiver)); + else if (receiver instanceof Proxyable) receiver._promiseCancelled(promise); + else if (isPromise$2 || promise instanceof PromiseArray) promise._cancel(); + else receiver.cancel(); + } else if (typeof handler === "function") if (!isPromise$2) handler.call(receiver, value, promise); + else { + if (asyncGuaranteed) promise._setAsyncGuaranteed(); + this._settlePromiseFromHandler(handler, receiver, value, promise); + } + else if (receiver instanceof Proxyable) { + if (!receiver._isResolved()) if ((bitField & 33554432) !== 0) receiver._promiseFulfilled(value, promise); + else receiver._promiseRejected(value, promise); + } else if (isPromise$2) { + if (asyncGuaranteed) promise._setAsyncGuaranteed(); + if ((bitField & 33554432) !== 0) promise._fulfill(value); + else promise._reject(value); + } + }; + Promise$2.prototype._settlePromiseLateCancellationObserver = function(ctx) { + var handler = ctx.handler; + var promise = ctx.promise; + var receiver = ctx.receiver; + var value = ctx.value; + if (typeof handler === "function") if (!(promise instanceof Promise$2)) handler.call(receiver, value, promise); + else this._settlePromiseFromHandler(handler, receiver, value, promise); + else if (promise instanceof Promise$2) promise._reject(value); + }; + Promise$2.prototype._settlePromiseCtx = function(ctx) { + this._settlePromise(ctx.promise, ctx.handler, ctx.receiver, ctx.value); + }; + Promise$2.prototype._settlePromise0 = function(handler, value, bitField) { + var promise = this._promise0; + var receiver = this._receiverAt(0); + this._promise0 = void 0; + this._receiver0 = void 0; + this._settlePromise(promise, handler, receiver, value); + }; + Promise$2.prototype._clearCallbackDataAtIndex = function(index$1) { + var base$1 = index$1 * 4 - 4; + this[base$1 + 2] = this[base$1 + 3] = this[base$1 + 0] = this[base$1 + 1] = void 0; + }; + Promise$2.prototype._fulfill = function(value) { + var bitField = this._bitField; + if ((bitField & 117506048) >>> 16) return; + if (value === this) { + var err = makeSelfResolutionError(); + this._attachExtraTrace(err); + return this._reject(err); + } + this._setFulfilled(); + this._rejectionHandler0 = value; + if ((bitField & 65535) > 0) { + if ((bitField & 134217728) !== 0) this._settlePromises(); + else async$1.settlePromises(this); + this._dereferenceTrace(); + } + }; + Promise$2.prototype._reject = function(reason) { + var bitField = this._bitField; + if ((bitField & 117506048) >>> 16) return; + this._setRejected(); + this._fulfillmentHandler0 = reason; + if (this._isFinal()) return async$1.fatalError(reason, util$9.isNode); + if ((bitField & 65535) > 0) async$1.settlePromises(this); + else this._ensurePossibleRejectionHandled(); + }; + Promise$2.prototype._fulfillPromises = function(len, value) { + for (var i$5 = 1; i$5 < len; i$5++) { + var handler = this._fulfillmentHandlerAt(i$5); + var promise = this._promiseAt(i$5); + var receiver = this._receiverAt(i$5); + this._clearCallbackDataAtIndex(i$5); + this._settlePromise(promise, handler, receiver, value); + } + }; + Promise$2.prototype._rejectPromises = function(len, reason) { + for (var i$5 = 1; i$5 < len; i$5++) { + var handler = this._rejectionHandlerAt(i$5); + var promise = this._promiseAt(i$5); + var receiver = this._receiverAt(i$5); + this._clearCallbackDataAtIndex(i$5); + this._settlePromise(promise, handler, receiver, reason); + } + }; + Promise$2.prototype._settlePromises = function() { + var bitField = this._bitField; + var len = bitField & 65535; + if (len > 0) { + if ((bitField & 16842752) !== 0) { + var reason = this._fulfillmentHandler0; + this._settlePromise0(this._rejectionHandler0, reason, bitField); + this._rejectPromises(len, reason); + } else { + var value = this._rejectionHandler0; + this._settlePromise0(this._fulfillmentHandler0, value, bitField); + this._fulfillPromises(len, value); + } + this._setLength(0); + } + this._clearCancellationData(); + }; + Promise$2.prototype._settledValue = function() { + var bitField = this._bitField; + if ((bitField & 33554432) !== 0) return this._rejectionHandler0; + else if ((bitField & 16777216) !== 0) return this._fulfillmentHandler0; + }; + if (typeof Symbol !== "undefined" && Symbol.toStringTag) es5.defineProperty(Promise$2.prototype, Symbol.toStringTag, { get: function() { + return "Object"; + } }); + function deferResolve(v$1) { + this.promise._resolveCallback(v$1); + } + function deferReject(v$1) { + this.promise._rejectCallback(v$1, false); + } + Promise$2.defer = Promise$2.pending = function() { + debug$2.deprecated("Promise.defer", "new Promise"); + var promise = new Promise$2(INTERNAL); + return { + promise, + resolve: deferResolve, + reject: deferReject + }; + }; + util$9.notEnumerableProp(Promise$2, "_makeSelfResolutionError", makeSelfResolutionError); + _dereq_$1("./method")(Promise$2, INTERNAL, tryConvertToPromise, apiRejection, debug$2); + _dereq_$1("./bind")(Promise$2, INTERNAL, tryConvertToPromise, debug$2); + _dereq_$1("./cancel")(Promise$2, PromiseArray, apiRejection, debug$2); + _dereq_$1("./direct_resolve")(Promise$2); + _dereq_$1("./synchronous_inspection")(Promise$2); + _dereq_$1("./join")(Promise$2, PromiseArray, tryConvertToPromise, INTERNAL, async$1); + Promise$2.Promise = Promise$2; + Promise$2.version = "3.7.2"; + _dereq_$1("./call_get.js")(Promise$2); + _dereq_$1("./generators.js")(Promise$2, apiRejection, INTERNAL, tryConvertToPromise, Proxyable, debug$2); + _dereq_$1("./map.js")(Promise$2, PromiseArray, apiRejection, tryConvertToPromise, INTERNAL, debug$2); + _dereq_$1("./nodeify.js")(Promise$2); + _dereq_$1("./promisify.js")(Promise$2, INTERNAL); + _dereq_$1("./props.js")(Promise$2, PromiseArray, tryConvertToPromise, apiRejection); + _dereq_$1("./race.js")(Promise$2, INTERNAL, tryConvertToPromise, apiRejection); + _dereq_$1("./reduce.js")(Promise$2, PromiseArray, apiRejection, tryConvertToPromise, INTERNAL, debug$2); + _dereq_$1("./settle.js")(Promise$2, PromiseArray, debug$2); + _dereq_$1("./some.js")(Promise$2, PromiseArray, apiRejection); + _dereq_$1("./timers.js")(Promise$2, INTERNAL, debug$2); + _dereq_$1("./using.js")(Promise$2, apiRejection, tryConvertToPromise, createContext, INTERNAL, debug$2); + _dereq_$1("./any.js")(Promise$2); + _dereq_$1("./each.js")(Promise$2, INTERNAL); + _dereq_$1("./filter.js")(Promise$2, INTERNAL); + util$9.toFastProperties(Promise$2); + util$9.toFastProperties(Promise$2.prototype); + function fillTypes(value) { + var p$1 = new Promise$2(INTERNAL); + p$1._fulfillmentHandler0 = value; + p$1._rejectionHandler0 = value; + p$1._promise0 = value; + p$1._receiver0 = value; + } + fillTypes({ a: 1 }); + fillTypes({ b: 2 }); + fillTypes({ c: 3 }); + fillTypes(1); + fillTypes(function() {}); + fillTypes(void 0); + fillTypes(false); + fillTypes(new Promise$2(INTERNAL)); + debug$2.setBounds(Async.firstLineError, util$9.lastLineError); + return Promise$2; + }; + }, { + "./any.js": 1, + "./async": 2, + "./bind": 3, + "./call_get.js": 5, + "./cancel": 6, + "./catch_filter": 7, + "./context": 8, + "./debuggability": 9, + "./direct_resolve": 10, + "./each.js": 11, + "./errors": 12, + "./es5": 13, + "./filter.js": 14, + "./finally": 15, + "./generators.js": 16, + "./join": 17, + "./map.js": 18, + "./method": 19, + "./nodeback": 20, + "./nodeify.js": 21, + "./promise_array": 23, + "./promisify.js": 24, + "./props.js": 25, + "./race.js": 27, + "./reduce.js": 28, + "./settle.js": 30, + "./some.js": 31, + "./synchronous_inspection": 32, + "./thenables": 33, + "./timers.js": 34, + "./using.js": 35, + "./util": 36, + "async_hooks": void 0 + }], + 23: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, INTERNAL, tryConvertToPromise, apiRejection, Proxyable) { + var util$9 = _dereq_$1("./util"); + var isArray$5 = util$9.isArray; + function toResolutionValue(val) { + switch (val) { + case -2: return []; + case -3: return {}; + case -6: return new Map(); + } + } + function PromiseArray(values$1) { + var promise = this._promise = new Promise$2(INTERNAL); + if (values$1 instanceof Promise$2) { + promise._propagateFrom(values$1, 3); + values$1.suppressUnhandledRejections(); + } + promise._setOnCancel(this); + this._values = values$1; + this._length = 0; + this._totalResolved = 0; + this._init(void 0, -2); + } + util$9.inherits(PromiseArray, Proxyable); + PromiseArray.prototype.length = function() { + return this._length; + }; + PromiseArray.prototype.promise = function() { + return this._promise; + }; + PromiseArray.prototype._init = function init(_$2, resolveValueIfEmpty) { + var values$1 = tryConvertToPromise(this._values, this._promise); + if (values$1 instanceof Promise$2) { + values$1 = values$1._target(); + var bitField = values$1._bitField; + this._values = values$1; + if ((bitField & 50397184) === 0) { + this._promise._setAsyncGuaranteed(); + return values$1._then(init, this._reject, void 0, this, resolveValueIfEmpty); + } else if ((bitField & 33554432) !== 0) values$1 = values$1._value(); + else if ((bitField & 16777216) !== 0) return this._reject(values$1._reason()); + else return this._cancel(); + } + values$1 = util$9.asArray(values$1); + if (values$1 === null) { + var err = apiRejection("expecting an array or an iterable object but got " + util$9.classString(values$1)).reason(); + this._promise._rejectCallback(err, false); + return; + } + if (values$1.length === 0) { + if (resolveValueIfEmpty === -5) this._resolveEmptyArray(); + else this._resolve(toResolutionValue(resolveValueIfEmpty)); + return; + } + this._iterate(values$1); + }; + PromiseArray.prototype._iterate = function(values$1) { + var len = this.getActualLength(values$1.length); + this._length = len; + this._values = this.shouldCopyValues() ? new Array(len) : this._values; + var result$1 = this._promise; + var isResolved = false; + var bitField = null; + for (var i$5 = 0; i$5 < len; ++i$5) { + var maybePromise = tryConvertToPromise(values$1[i$5], result$1); + if (maybePromise instanceof Promise$2) { + maybePromise = maybePromise._target(); + bitField = maybePromise._bitField; + } else bitField = null; + if (isResolved) { + if (bitField !== null) maybePromise.suppressUnhandledRejections(); + } else if (bitField !== null) if ((bitField & 50397184) === 0) { + maybePromise._proxy(this, i$5); + this._values[i$5] = maybePromise; + } else if ((bitField & 33554432) !== 0) isResolved = this._promiseFulfilled(maybePromise._value(), i$5); + else if ((bitField & 16777216) !== 0) isResolved = this._promiseRejected(maybePromise._reason(), i$5); + else isResolved = this._promiseCancelled(i$5); + else isResolved = this._promiseFulfilled(maybePromise, i$5); + } + if (!isResolved) result$1._setAsyncGuaranteed(); + }; + PromiseArray.prototype._isResolved = function() { + return this._values === null; + }; + PromiseArray.prototype._resolve = function(value) { + this._values = null; + this._promise._fulfill(value); + }; + PromiseArray.prototype._cancel = function() { + if (this._isResolved() || !this._promise._isCancellable()) return; + this._values = null; + this._promise._cancel(); + }; + PromiseArray.prototype._reject = function(reason) { + this._values = null; + this._promise._rejectCallback(reason, false); + }; + PromiseArray.prototype._promiseFulfilled = function(value, index$1) { + this._values[index$1] = value; + var totalResolved = ++this._totalResolved; + if (totalResolved >= this._length) { + this._resolve(this._values); + return true; + } + return false; + }; + PromiseArray.prototype._promiseCancelled = function() { + this._cancel(); + return true; + }; + PromiseArray.prototype._promiseRejected = function(reason) { + this._totalResolved++; + this._reject(reason); + return true; + }; + PromiseArray.prototype._resultCancelled = function() { + if (this._isResolved()) return; + var values$1 = this._values; + this._cancel(); + if (values$1 instanceof Promise$2) values$1.cancel(); + else for (var i$5 = 0; i$5 < values$1.length; ++i$5) if (values$1[i$5] instanceof Promise$2) values$1[i$5].cancel(); + }; + PromiseArray.prototype.shouldCopyValues = function() { + return true; + }; + PromiseArray.prototype.getActualLength = function(len) { + return len; + }; + return PromiseArray; + }; + }, { "./util": 36 }], + 24: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, INTERNAL) { + var THIS = {}; + var util$9 = _dereq_$1("./util"); + var nodebackForPromise = _dereq_$1("./nodeback"); + var withAppended = util$9.withAppended; + var maybeWrapAsError = util$9.maybeWrapAsError; + var canEvaluate = util$9.canEvaluate; + var TypeError$1 = _dereq_$1("./errors").TypeError; + var defaultSuffix = "Async"; + var defaultPromisified = { __isPromisified__: true }; + var noCopyProps = [ + "arity", + "length", + "name", + "arguments", + "caller", + "callee", + "prototype", + "__isPromisified__" + ]; + var noCopyPropsPattern = new RegExp("^(?:" + noCopyProps.join("|") + ")$"); + var defaultFilter = function(name) { + return util$9.isIdentifier(name) && name.charAt(0) !== "_" && name !== "constructor"; + }; + function propsFilter(key) { + return !noCopyPropsPattern.test(key); + } + function isPromisified(fn) { + try { + return fn.__isPromisified__ === true; + } catch (e) { + return false; + } + } + function hasPromisified(obj, key, suffix) { + var val = util$9.getDataPropertyOrDefault(obj, key + suffix, defaultPromisified); + return val ? isPromisified(val) : false; + } + function checkValid(ret, suffix, suffixRegexp) { + for (var i$5 = 0; i$5 < ret.length; i$5 += 2) { + var key = ret[i$5]; + if (suffixRegexp.test(key)) { + var keyWithoutAsyncSuffix = key.replace(suffixRegexp, ""); + for (var j = 0; j < ret.length; j += 2) if (ret[j] === keyWithoutAsyncSuffix) throw new TypeError$1("Cannot promisify an API that has normal methods with '%s'-suffix\n\n See http://goo.gl/MqrFmX\n".replace("%s", suffix)); + } + } + } + function promisifiableMethods(obj, suffix, suffixRegexp, filter$3) { + var keys$2 = util$9.inheritedDataKeys(obj); + var ret = []; + for (var i$5 = 0; i$5 < keys$2.length; ++i$5) { + var key = keys$2[i$5]; + var value = obj[key]; + var passesDefaultFilter = filter$3 === defaultFilter ? true : defaultFilter(key, value, obj); + if (typeof value === "function" && !isPromisified(value) && !hasPromisified(obj, key, suffix) && filter$3(key, value, obj, passesDefaultFilter)) ret.push(key, value); + } + checkValid(ret, suffix, suffixRegexp); + return ret; + } + var escapeIdentRegex = function(str$3) { + return str$3.replace(/([$])/, "\\$"); + }; + var makeNodePromisifiedEval; + if (0) var switchCaseArgumentOrder, argumentSequence, parameterDeclaration, parameterCount; + function makeNodePromisifiedClosure(callback, receiver, _$2, fn, __, multiArgs) { + var defaultThis = function() { + return this; + }(); + var method = callback; + if (typeof method === "string") callback = fn; + function promisified() { + var _receiver = receiver; + if (receiver === THIS) _receiver = this; + var promise = new Promise$2(INTERNAL); + promise._captureStackTrace(); + var cb$1 = typeof method === "string" && this !== defaultThis ? this[method] : callback; + var fn$1 = nodebackForPromise(promise, multiArgs); + try { + cb$1.apply(_receiver, withAppended(arguments, fn$1)); + } catch (e) { + promise._rejectCallback(maybeWrapAsError(e), true, true); + } + if (!promise._isFateSealed()) promise._setAsyncGuaranteed(); + return promise; + } + util$9.notEnumerableProp(promisified, "__isPromisified__", true); + return promisified; + } + var makeNodePromisified = canEvaluate ? makeNodePromisifiedEval : makeNodePromisifiedClosure; + function promisifyAll(obj, suffix, filter$3, promisifier, multiArgs) { + var suffixRegexp = new RegExp(escapeIdentRegex(suffix) + "$"); + var methods$1 = promisifiableMethods(obj, suffix, suffixRegexp, filter$3); + for (var i$5 = 0, len = methods$1.length; i$5 < len; i$5 += 2) { + var key = methods$1[i$5]; + var fn = methods$1[i$5 + 1]; + var promisifiedKey = key + suffix; + if (promisifier === makeNodePromisified) obj[promisifiedKey] = makeNodePromisified(key, THIS, key, fn, suffix, multiArgs); + else { + var promisified = promisifier(fn, function() { + return makeNodePromisified(key, THIS, key, fn, suffix, multiArgs); + }); + util$9.notEnumerableProp(promisified, "__isPromisified__", true); + obj[promisifiedKey] = promisified; + } + } + util$9.toFastProperties(obj); + return obj; + } + function promisify$2(callback, receiver, multiArgs) { + return makeNodePromisified(callback, receiver, void 0, callback, null, multiArgs); + } + Promise$2.promisify = function(fn, options) { + if (typeof fn !== "function") throw new TypeError$1("expecting a function but got " + util$9.classString(fn)); + if (isPromisified(fn)) return fn; + options = Object(options); + var receiver = options.context === void 0 ? THIS : options.context; + var multiArgs = !!options.multiArgs; + var ret = promisify$2(fn, receiver, multiArgs); + util$9.copyDescriptors(fn, ret, propsFilter); + return ret; + }; + Promise$2.promisifyAll = function(target, options) { + if (typeof target !== "function" && typeof target !== "object") throw new TypeError$1("the target of promisifyAll must be an object or a function\n\n See http://goo.gl/MqrFmX\n"); + options = Object(options); + var multiArgs = !!options.multiArgs; + var suffix = options.suffix; + if (typeof suffix !== "string") suffix = defaultSuffix; + var filter$3 = options.filter; + if (typeof filter$3 !== "function") filter$3 = defaultFilter; + var promisifier = options.promisifier; + if (typeof promisifier !== "function") promisifier = makeNodePromisified; + if (!util$9.isIdentifier(suffix)) throw new RangeError("suffix must be a valid identifier\n\n See http://goo.gl/MqrFmX\n"); + var keys$2 = util$9.inheritedDataKeys(target); + for (var i$5 = 0; i$5 < keys$2.length; ++i$5) { + var value = target[keys$2[i$5]]; + if (keys$2[i$5] !== "constructor" && util$9.isClass(value)) { + promisifyAll(value.prototype, suffix, filter$3, promisifier, multiArgs); + promisifyAll(value, suffix, filter$3, promisifier, multiArgs); + } + } + return promisifyAll(target, suffix, filter$3, promisifier, multiArgs); + }; + }; + }, { + "./errors": 12, + "./nodeback": 20, + "./util": 36 + }], + 25: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, PromiseArray, tryConvertToPromise, apiRejection) { + var util$9 = _dereq_$1("./util"); + var isObject$5 = util$9.isObject; + var es5 = _dereq_$1("./es5"); + var Es6Map; + if (typeof Map === "function") Es6Map = Map; + var mapToEntries = function() { + var index$1 = 0; + var size$1 = 0; + function extractEntry(value, key) { + this[index$1] = value; + this[index$1 + size$1] = key; + index$1++; + } + return function mapToEntries$1(map$1) { + size$1 = map$1.size; + index$1 = 0; + var ret = new Array(map$1.size * 2); + map$1.forEach(extractEntry, ret); + return ret; + }; + }(); + var entriesToMap = function(entries) { + var ret = new Es6Map(); + var length = entries.length / 2 | 0; + for (var i$5 = 0; i$5 < length; ++i$5) { + var key = entries[length + i$5]; + var value = entries[i$5]; + ret.set(key, value); + } + return ret; + }; + function PropertiesPromiseArray(obj) { + var isMap$2 = false; + var entries; + if (Es6Map !== void 0 && obj instanceof Es6Map) { + entries = mapToEntries(obj); + isMap$2 = true; + } else { + var keys$2 = es5.keys(obj); + var len = keys$2.length; + entries = new Array(len * 2); + for (var i$5 = 0; i$5 < len; ++i$5) { + var key = keys$2[i$5]; + entries[i$5] = obj[key]; + entries[i$5 + len] = key; + } + } + this.constructor$(entries); + this._isMap = isMap$2; + this._init$(void 0, isMap$2 ? -6 : -3); + } + util$9.inherits(PropertiesPromiseArray, PromiseArray); + PropertiesPromiseArray.prototype._init = function() {}; + PropertiesPromiseArray.prototype._promiseFulfilled = function(value, index$1) { + this._values[index$1] = value; + var totalResolved = ++this._totalResolved; + if (totalResolved >= this._length) { + var val; + if (this._isMap) val = entriesToMap(this._values); + else { + val = {}; + var keyOffset = this.length(); + for (var i$5 = 0, len = this.length(); i$5 < len; ++i$5) val[this._values[i$5 + keyOffset]] = this._values[i$5]; + } + this._resolve(val); + return true; + } + return false; + }; + PropertiesPromiseArray.prototype.shouldCopyValues = function() { + return false; + }; + PropertiesPromiseArray.prototype.getActualLength = function(len) { + return len >> 1; + }; + function props(promises) { + var ret; + var castValue = tryConvertToPromise(promises); + if (!isObject$5(castValue)) return apiRejection("cannot await properties of a non-object\n\n See http://goo.gl/MqrFmX\n"); + else if (castValue instanceof Promise$2) ret = castValue._then(Promise$2.props, void 0, void 0, void 0, void 0); + else ret = new PropertiesPromiseArray(castValue).promise(); + if (castValue instanceof Promise$2) ret._propagateFrom(castValue, 2); + return ret; + } + Promise$2.prototype.props = function() { + return props(this); + }; + Promise$2.props = function(promises) { + return props(promises); + }; + }; + }, { + "./es5": 13, + "./util": 36 + }], + 26: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + function arrayMove(src, srcIndex, dst, dstIndex, len) { + for (var j = 0; j < len; ++j) { + dst[j + dstIndex] = src[j + srcIndex]; + src[j + srcIndex] = void 0; + } + } + function Queue(capacity) { + this._capacity = capacity; + this._length = 0; + this._front = 0; + } + Queue.prototype._willBeOverCapacity = function(size$1) { + return this._capacity < size$1; + }; + Queue.prototype._pushOne = function(arg) { + var length = this.length(); + this._checkCapacity(length + 1); + var i$5 = this._front + length & this._capacity - 1; + this[i$5] = arg; + this._length = length + 1; + }; + Queue.prototype.push = function(fn, receiver, arg) { + var length = this.length() + 3; + if (this._willBeOverCapacity(length)) { + this._pushOne(fn); + this._pushOne(receiver); + this._pushOne(arg); + return; + } + var j = this._front + length - 3; + this._checkCapacity(length); + var wrapMask = this._capacity - 1; + this[j + 0 & wrapMask] = fn; + this[j + 1 & wrapMask] = receiver; + this[j + 2 & wrapMask] = arg; + this._length = length; + }; + Queue.prototype.shift = function() { + var front = this._front, ret = this[front]; + this[front] = void 0; + this._front = front + 1 & this._capacity - 1; + this._length--; + return ret; + }; + Queue.prototype.length = function() { + return this._length; + }; + Queue.prototype._checkCapacity = function(size$1) { + if (this._capacity < size$1) this._resizeTo(this._capacity << 1); + }; + Queue.prototype._resizeTo = function(capacity) { + var oldCapacity = this._capacity; + this._capacity = capacity; + var front = this._front; + var length = this._length; + var moveItemsCount = front + length & oldCapacity - 1; + arrayMove(this, 0, this, oldCapacity, moveItemsCount); + }; + module$2.exports = Queue; + }, {}], + 27: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, INTERNAL, tryConvertToPromise, apiRejection) { + var util$9 = _dereq_$1("./util"); + var raceLater = function(promise) { + return promise.then(function(array) { + return race(array, promise); + }); + }; + function race(promises, parent) { + var maybePromise = tryConvertToPromise(promises); + if (maybePromise instanceof Promise$2) return raceLater(maybePromise); + else { + promises = util$9.asArray(promises); + if (promises === null) return apiRejection("expecting an array or an iterable object but got " + util$9.classString(promises)); + } + var ret = new Promise$2(INTERNAL); + if (parent !== void 0) ret._propagateFrom(parent, 3); + var fulfill = ret._fulfill; + var reject$1 = ret._reject; + for (var i$5 = 0, len = promises.length; i$5 < len; ++i$5) { + var val = promises[i$5]; + if (val === void 0 && !(i$5 in promises)) continue; + Promise$2.cast(val)._then(fulfill, reject$1, void 0, ret, null); + } + return ret; + } + Promise$2.race = function(promises) { + return race(promises, void 0); + }; + Promise$2.prototype.race = function() { + return race(this, void 0); + }; + }; + }, { "./util": 36 }], + 28: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, PromiseArray, apiRejection, tryConvertToPromise, INTERNAL, debug$2) { + var util$9 = _dereq_$1("./util"); + var tryCatch = util$9.tryCatch; + function ReductionPromiseArray(promises, fn, initialValue, _each) { + this.constructor$(promises); + var context = Promise$2._getContext(); + this._fn = util$9.contextBind(context, fn); + if (initialValue !== void 0) { + initialValue = Promise$2.resolve(initialValue); + initialValue._attachCancellationCallback(this); + } + this._initialValue = initialValue; + this._currentCancellable = null; + if (_each === INTERNAL) this._eachValues = Array(this._length); + else if (_each === 0) this._eachValues = null; + else this._eachValues = void 0; + this._promise._captureStackTrace(); + this._init$(void 0, -5); + } + util$9.inherits(ReductionPromiseArray, PromiseArray); + ReductionPromiseArray.prototype._gotAccum = function(accum) { + if (this._eachValues !== void 0 && this._eachValues !== null && accum !== INTERNAL) this._eachValues.push(accum); + }; + ReductionPromiseArray.prototype._eachComplete = function(value) { + if (this._eachValues !== null) this._eachValues.push(value); + return this._eachValues; + }; + ReductionPromiseArray.prototype._init = function() {}; + ReductionPromiseArray.prototype._resolveEmptyArray = function() { + this._resolve(this._eachValues !== void 0 ? this._eachValues : this._initialValue); + }; + ReductionPromiseArray.prototype.shouldCopyValues = function() { + return false; + }; + ReductionPromiseArray.prototype._resolve = function(value) { + this._promise._resolveCallback(value); + this._values = null; + }; + ReductionPromiseArray.prototype._resultCancelled = function(sender) { + if (sender === this._initialValue) return this._cancel(); + if (this._isResolved()) return; + this._resultCancelled$(); + if (this._currentCancellable instanceof Promise$2) this._currentCancellable.cancel(); + if (this._initialValue instanceof Promise$2) this._initialValue.cancel(); + }; + ReductionPromiseArray.prototype._iterate = function(values$1) { + this._values = values$1; + var value; + var i$5; + var length = values$1.length; + if (this._initialValue !== void 0) { + value = this._initialValue; + i$5 = 0; + } else { + value = Promise$2.resolve(values$1[0]); + i$5 = 1; + } + this._currentCancellable = value; + for (var j = i$5; j < length; ++j) { + var maybePromise = values$1[j]; + if (maybePromise instanceof Promise$2) maybePromise.suppressUnhandledRejections(); + } + if (!value.isRejected()) for (; i$5 < length; ++i$5) { + var ctx = { + accum: null, + value: values$1[i$5], + index: i$5, + length, + array: this + }; + value = value._then(gotAccum, void 0, void 0, ctx, void 0); + if ((i$5 & 127) === 0) value._setNoAsyncGuarantee(); + } + if (this._eachValues !== void 0) value = value._then(this._eachComplete, void 0, void 0, this, void 0); + value._then(completed, completed, void 0, value, this); + }; + Promise$2.prototype.reduce = function(fn, initialValue) { + return reduce(this, fn, initialValue, null); + }; + Promise$2.reduce = function(promises, fn, initialValue, _each) { + return reduce(promises, fn, initialValue, _each); + }; + function completed(valueOrReason, array) { + if (this.isFulfilled()) array._resolve(valueOrReason); + else array._reject(valueOrReason); + } + function reduce(promises, fn, initialValue, _each) { + if (typeof fn !== "function") return apiRejection("expecting a function but got " + util$9.classString(fn)); + var array = new ReductionPromiseArray(promises, fn, initialValue, _each); + return array.promise(); + } + function gotAccum(accum) { + this.accum = accum; + this.array._gotAccum(accum); + var value = tryConvertToPromise(this.value, this.array._promise); + if (value instanceof Promise$2) { + this.array._currentCancellable = value; + return value._then(gotValue, void 0, void 0, this, void 0); + } else return gotValue.call(this, value); + } + function gotValue(value) { + var array = this.array; + var promise = array._promise; + var fn = tryCatch(array._fn); + promise._pushContext(); + var ret; + if (array._eachValues !== void 0) ret = fn.call(promise._boundValue(), value, this.index, this.length); + else ret = fn.call(promise._boundValue(), this.accum, value, this.index, this.length); + if (ret instanceof Promise$2) array._currentCancellable = ret; + var promiseCreated = promise._popContext(); + debug$2.checkForgottenReturns(ret, promiseCreated, array._eachValues !== void 0 ? "Promise.each" : "Promise.reduce", promise); + return ret; + } + }; + }, { "./util": 36 }], + 29: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + var util$9 = _dereq_$1("./util"); + var schedule; + var noAsyncScheduler = function() { + throw new Error("No async scheduler available\n\n See http://goo.gl/MqrFmX\n"); + }; + var NativePromise = util$9.getNativePromise(); + if (util$9.isNode && typeof MutationObserver === "undefined") { + var GlobalSetImmediate = global.setImmediate; + var ProcessNextTick = process.nextTick; + schedule = util$9.isRecentNode ? function(fn) { + GlobalSetImmediate.call(global, fn); + } : function(fn) { + ProcessNextTick.call(process, fn); + }; + } else if (typeof NativePromise === "function" && typeof NativePromise.resolve === "function") { + var nativePromise = NativePromise.resolve(); + schedule = function(fn) { + nativePromise.then(fn); + }; + } else if (typeof MutationObserver !== "undefined" && !(typeof window !== "undefined" && window.navigator && (window.navigator.standalone || window.cordova)) && "classList" in document.documentElement) schedule = function() { + var div = document.createElement("div"); + var opts = { attributes: true }; + var toggleScheduled = false; + var div2 = document.createElement("div"); + var o2 = new MutationObserver(function() { + div.classList.toggle("foo"); + toggleScheduled = false; + }); + o2.observe(div2, opts); + var scheduleToggle = function() { + if (toggleScheduled) return; + toggleScheduled = true; + div2.classList.toggle("foo"); + }; + return function schedule$1(fn) { + var o = new MutationObserver(function() { + o.disconnect(); + fn(); + }); + o.observe(div, opts); + scheduleToggle(); + }; + }(); + else if (typeof setImmediate !== "undefined") schedule = function(fn) { + setImmediate(fn); + }; + else if (typeof setTimeout !== "undefined") schedule = function(fn) { + setTimeout(fn, 0); + }; + else schedule = noAsyncScheduler; + module$2.exports = schedule; + }, { "./util": 36 }], + 30: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, PromiseArray, debug$2) { + var PromiseInspection = Promise$2.PromiseInspection; + var util$9 = _dereq_$1("./util"); + function SettledPromiseArray(values$1) { + this.constructor$(values$1); + } + util$9.inherits(SettledPromiseArray, PromiseArray); + SettledPromiseArray.prototype._promiseResolved = function(index$1, inspection) { + this._values[index$1] = inspection; + var totalResolved = ++this._totalResolved; + if (totalResolved >= this._length) { + this._resolve(this._values); + return true; + } + return false; + }; + SettledPromiseArray.prototype._promiseFulfilled = function(value, index$1) { + var ret = new PromiseInspection(); + ret._bitField = 33554432; + ret._settledValueField = value; + return this._promiseResolved(index$1, ret); + }; + SettledPromiseArray.prototype._promiseRejected = function(reason, index$1) { + var ret = new PromiseInspection(); + ret._bitField = 16777216; + ret._settledValueField = reason; + return this._promiseResolved(index$1, ret); + }; + Promise$2.settle = function(promises) { + debug$2.deprecated(".settle()", ".reflect()"); + return new SettledPromiseArray(promises).promise(); + }; + Promise$2.allSettled = function(promises) { + return new SettledPromiseArray(promises).promise(); + }; + Promise$2.prototype.settle = function() { + return Promise$2.settle(this); + }; + }; + }, { "./util": 36 }], + 31: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, PromiseArray, apiRejection) { + var util$9 = _dereq_$1("./util"); + var RangeError$1 = _dereq_$1("./errors").RangeError; + var AggregateError = _dereq_$1("./errors").AggregateError; + var isArray$5 = util$9.isArray; + var CANCELLATION = {}; + function SomePromiseArray(values$1) { + this.constructor$(values$1); + this._howMany = 0; + this._unwrap = false; + this._initialized = false; + } + util$9.inherits(SomePromiseArray, PromiseArray); + SomePromiseArray.prototype._init = function() { + if (!this._initialized) return; + if (this._howMany === 0) { + this._resolve([]); + return; + } + this._init$(void 0, -5); + var isArrayResolved = isArray$5(this._values); + if (!this._isResolved() && isArrayResolved && this._howMany > this._canPossiblyFulfill()) this._reject(this._getRangeError(this.length())); + }; + SomePromiseArray.prototype.init = function() { + this._initialized = true; + this._init(); + }; + SomePromiseArray.prototype.setUnwrap = function() { + this._unwrap = true; + }; + SomePromiseArray.prototype.howMany = function() { + return this._howMany; + }; + SomePromiseArray.prototype.setHowMany = function(count) { + this._howMany = count; + }; + SomePromiseArray.prototype._promiseFulfilled = function(value) { + this._addFulfilled(value); + if (this._fulfilled() === this.howMany()) { + this._values.length = this.howMany(); + if (this.howMany() === 1 && this._unwrap) this._resolve(this._values[0]); + else this._resolve(this._values); + return true; + } + return false; + }; + SomePromiseArray.prototype._promiseRejected = function(reason) { + this._addRejected(reason); + return this._checkOutcome(); + }; + SomePromiseArray.prototype._promiseCancelled = function() { + if (this._values instanceof Promise$2 || this._values == null) return this._cancel(); + this._addRejected(CANCELLATION); + return this._checkOutcome(); + }; + SomePromiseArray.prototype._checkOutcome = function() { + if (this.howMany() > this._canPossiblyFulfill()) { + var e = new AggregateError(); + for (var i$5 = this.length(); i$5 < this._values.length; ++i$5) if (this._values[i$5] !== CANCELLATION) e.push(this._values[i$5]); + if (e.length > 0) this._reject(e); + else this._cancel(); + return true; + } + return false; + }; + SomePromiseArray.prototype._fulfilled = function() { + return this._totalResolved; + }; + SomePromiseArray.prototype._rejected = function() { + return this._values.length - this.length(); + }; + SomePromiseArray.prototype._addRejected = function(reason) { + this._values.push(reason); + }; + SomePromiseArray.prototype._addFulfilled = function(value) { + this._values[this._totalResolved++] = value; + }; + SomePromiseArray.prototype._canPossiblyFulfill = function() { + return this.length() - this._rejected(); + }; + SomePromiseArray.prototype._getRangeError = function(count) { + var message = "Input array must contain at least " + this._howMany + " items but contains only " + count + " items"; + return new RangeError$1(message); + }; + SomePromiseArray.prototype._resolveEmptyArray = function() { + this._reject(this._getRangeError(0)); + }; + function some$1(promises, howMany) { + if ((howMany | 0) !== howMany || howMany < 0) return apiRejection("expecting a positive integer\n\n See http://goo.gl/MqrFmX\n"); + var ret = new SomePromiseArray(promises); + var promise = ret.promise(); + ret.setHowMany(howMany); + ret.init(); + return promise; + } + Promise$2.some = function(promises, howMany) { + return some$1(promises, howMany); + }; + Promise$2.prototype.some = function(howMany) { + return some$1(this, howMany); + }; + Promise$2._SomePromiseArray = SomePromiseArray; + }; + }, { + "./errors": 12, + "./util": 36 + }], + 32: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2) { + function PromiseInspection(promise) { + if (promise !== void 0) { + promise = promise._target(); + this._bitField = promise._bitField; + this._settledValueField = promise._isFateSealed() ? promise._settledValue() : void 0; + } else { + this._bitField = 0; + this._settledValueField = void 0; + } + } + PromiseInspection.prototype._settledValue = function() { + return this._settledValueField; + }; + var value = PromiseInspection.prototype.value = function() { + if (!this.isFulfilled()) throw new TypeError("cannot get fulfillment value of a non-fulfilled promise\n\n See http://goo.gl/MqrFmX\n"); + return this._settledValue(); + }; + var reason = PromiseInspection.prototype.error = PromiseInspection.prototype.reason = function() { + if (!this.isRejected()) throw new TypeError("cannot get rejection reason of a non-rejected promise\n\n See http://goo.gl/MqrFmX\n"); + return this._settledValue(); + }; + var isFulfilled = PromiseInspection.prototype.isFulfilled = function() { + return (this._bitField & 33554432) !== 0; + }; + var isRejected = PromiseInspection.prototype.isRejected = function() { + return (this._bitField & 16777216) !== 0; + }; + var isPending = PromiseInspection.prototype.isPending = function() { + return (this._bitField & 50397184) === 0; + }; + var isResolved = PromiseInspection.prototype.isResolved = function() { + return (this._bitField & 50331648) !== 0; + }; + PromiseInspection.prototype.isCancelled = function() { + return (this._bitField & 8454144) !== 0; + }; + Promise$2.prototype.__isCancelled = function() { + return (this._bitField & 65536) === 65536; + }; + Promise$2.prototype._isCancelled = function() { + return this._target().__isCancelled(); + }; + Promise$2.prototype.isCancelled = function() { + return (this._target()._bitField & 8454144) !== 0; + }; + Promise$2.prototype.isPending = function() { + return isPending.call(this._target()); + }; + Promise$2.prototype.isRejected = function() { + return isRejected.call(this._target()); + }; + Promise$2.prototype.isFulfilled = function() { + return isFulfilled.call(this._target()); + }; + Promise$2.prototype.isResolved = function() { + return isResolved.call(this._target()); + }; + Promise$2.prototype.value = function() { + return value.call(this._target()); + }; + Promise$2.prototype.reason = function() { + var target = this._target(); + target._unsetRejectionIsUnhandled(); + return reason.call(target); + }; + Promise$2.prototype._value = function() { + return this._settledValue(); + }; + Promise$2.prototype._reason = function() { + this._unsetRejectionIsUnhandled(); + return this._settledValue(); + }; + Promise$2.PromiseInspection = PromiseInspection; + }; + }, {}], + 33: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, INTERNAL) { + var util$9 = _dereq_$1("./util"); + var errorObj = util$9.errorObj; + var isObject$5 = util$9.isObject; + function tryConvertToPromise(obj, context) { + if (isObject$5(obj)) { + if (obj instanceof Promise$2) return obj; + var then = getThen(obj); + if (then === errorObj) { + if (context) context._pushContext(); + var ret = Promise$2.reject(then.e); + if (context) context._popContext(); + return ret; + } else if (typeof then === "function") { + if (isAnyBluebirdPromise(obj)) { + var ret = new Promise$2(INTERNAL); + obj._then(ret._fulfill, ret._reject, void 0, ret, null); + return ret; + } + return doThenable(obj, then, context); + } + } + return obj; + } + function doGetThen(obj) { + return obj.then; + } + function getThen(obj) { + try { + return doGetThen(obj); + } catch (e) { + errorObj.e = e; + return errorObj; + } + } + var hasProp = {}.hasOwnProperty; + function isAnyBluebirdPromise(obj) { + try { + return hasProp.call(obj, "_promise0"); + } catch (e) { + return false; + } + } + function doThenable(x$2, then, context) { + var promise = new Promise$2(INTERNAL); + var ret = promise; + if (context) context._pushContext(); + promise._captureStackTrace(); + if (context) context._popContext(); + var synchronous = true; + var result$1 = util$9.tryCatch(then).call(x$2, resolve$5, reject$1); + synchronous = false; + if (promise && result$1 === errorObj) { + promise._rejectCallback(result$1.e, true, true); + promise = null; + } + function resolve$5(value) { + if (!promise) return; + promise._resolveCallback(value); + promise = null; + } + function reject$1(reason) { + if (!promise) return; + promise._rejectCallback(reason, synchronous, true); + promise = null; + } + return ret; + } + return tryConvertToPromise; + }; + }, { "./util": 36 }], + 34: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, INTERNAL, debug$2) { + var util$9 = _dereq_$1("./util"); + var TimeoutError = Promise$2.TimeoutError; + function HandleWrapper(handle) { + this.handle = handle; + } + HandleWrapper.prototype._resultCancelled = function() { + clearTimeout(this.handle); + }; + var afterValue = function(value) { + return delay(+this).thenReturn(value); + }; + var delay = Promise$2.delay = function(ms, value) { + var ret; + var handle; + if (value !== void 0) { + ret = Promise$2.resolve(value)._then(afterValue, null, null, ms, void 0); + if (debug$2.cancellation() && value instanceof Promise$2) ret._setOnCancel(value); + } else { + ret = new Promise$2(INTERNAL); + handle = setTimeout(function() { + ret._fulfill(); + }, +ms); + if (debug$2.cancellation()) ret._setOnCancel(new HandleWrapper(handle)); + ret._captureStackTrace(); + } + ret._setAsyncGuaranteed(); + return ret; + }; + Promise$2.prototype.delay = function(ms) { + return delay(ms, this); + }; + var afterTimeout = function(promise, message, parent) { + var err; + if (typeof message !== "string") if (message instanceof Error) err = message; + else err = new TimeoutError("operation timed out"); + else err = new TimeoutError(message); + util$9.markAsOriginatingFromRejection(err); + promise._attachExtraTrace(err); + promise._reject(err); + if (parent != null) parent.cancel(); + }; + function successClear(value) { + clearTimeout(this.handle); + return value; + } + function failureClear(reason) { + clearTimeout(this.handle); + throw reason; + } + Promise$2.prototype.timeout = function(ms, message) { + ms = +ms; + var ret, parent; + var handleWrapper = new HandleWrapper(setTimeout(function timeoutTimeout() { + if (ret.isPending()) afterTimeout(ret, message, parent); + }, ms)); + if (debug$2.cancellation()) { + parent = this.then(); + ret = parent._then(successClear, failureClear, void 0, handleWrapper, void 0); + ret._setOnCancel(handleWrapper); + } else ret = this._then(successClear, failureClear, void 0, handleWrapper, void 0); + return ret; + }; + }; + }, { "./util": 36 }], + 35: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + module$2.exports = function(Promise$2, apiRejection, tryConvertToPromise, createContext, INTERNAL, debug$2) { + var util$9 = _dereq_$1("./util"); + var TypeError$1 = _dereq_$1("./errors").TypeError; + var inherits$3 = _dereq_$1("./util").inherits; + var errorObj = util$9.errorObj; + var tryCatch = util$9.tryCatch; + var NULL = {}; + function thrower(e) { + setTimeout(function() { + throw e; + }, 0); + } + function castPreservingDisposable(thenable) { + var maybePromise = tryConvertToPromise(thenable); + if (maybePromise !== thenable && typeof thenable._isDisposable === "function" && typeof thenable._getDisposer === "function" && thenable._isDisposable()) maybePromise._setDisposable(thenable._getDisposer()); + return maybePromise; + } + function dispose(resources, inspection) { + var i$5 = 0; + var len = resources.length; + var ret = new Promise$2(INTERNAL); + function iterator() { + if (i$5 >= len) return ret._fulfill(); + var maybePromise = castPreservingDisposable(resources[i$5++]); + if (maybePromise instanceof Promise$2 && maybePromise._isDisposable()) { + try { + maybePromise = tryConvertToPromise(maybePromise._getDisposer().tryDispose(inspection), resources.promise); + } catch (e) { + return thrower(e); + } + if (maybePromise instanceof Promise$2) return maybePromise._then(iterator, thrower, null, null, null); + } + iterator(); + } + iterator(); + return ret; + } + function Disposer(data$2, promise, context) { + this._data = data$2; + this._promise = promise; + this._context = context; + } + Disposer.prototype.data = function() { + return this._data; + }; + Disposer.prototype.promise = function() { + return this._promise; + }; + Disposer.prototype.resource = function() { + if (this.promise().isFulfilled()) return this.promise().value(); + return NULL; + }; + Disposer.prototype.tryDispose = function(inspection) { + var resource = this.resource(); + var context = this._context; + if (context !== void 0) context._pushContext(); + var ret = resource !== NULL ? this.doDispose(resource, inspection) : null; + if (context !== void 0) context._popContext(); + this._promise._unsetDisposable(); + this._data = null; + return ret; + }; + Disposer.isDisposer = function(d$2) { + return d$2 != null && typeof d$2.resource === "function" && typeof d$2.tryDispose === "function"; + }; + function FunctionDisposer(fn, promise, context) { + this.constructor$(fn, promise, context); + } + inherits$3(FunctionDisposer, Disposer); + FunctionDisposer.prototype.doDispose = function(resource, inspection) { + var fn = this.data(); + return fn.call(resource, resource, inspection); + }; + function maybeUnwrapDisposer(value) { + if (Disposer.isDisposer(value)) { + this.resources[this.index]._setDisposable(value); + return value.promise(); + } + return value; + } + function ResourceList(length) { + this.length = length; + this.promise = null; + this[length - 1] = null; + } + ResourceList.prototype._resultCancelled = function() { + var len = this.length; + for (var i$5 = 0; i$5 < len; ++i$5) { + var item = this[i$5]; + if (item instanceof Promise$2) item.cancel(); + } + }; + Promise$2.using = function() { + var len = arguments.length; + if (len < 2) return apiRejection("you must pass at least 2 arguments to Promise.using"); + var fn = arguments[len - 1]; + if (typeof fn !== "function") return apiRejection("expecting a function but got " + util$9.classString(fn)); + var input; + var spreadArgs = true; + if (len === 2 && Array.isArray(arguments[0])) { + input = arguments[0]; + len = input.length; + spreadArgs = false; + } else { + input = arguments; + len--; + } + var resources = new ResourceList(len); + for (var i$5 = 0; i$5 < len; ++i$5) { + var resource = input[i$5]; + if (Disposer.isDisposer(resource)) { + var disposer = resource; + resource = resource.promise(); + resource._setDisposable(disposer); + } else { + var maybePromise = tryConvertToPromise(resource); + if (maybePromise instanceof Promise$2) resource = maybePromise._then(maybeUnwrapDisposer, null, null, { + resources, + index: i$5 + }, void 0); + } + resources[i$5] = resource; + } + var reflectedResources = new Array(resources.length); + for (var i$5 = 0; i$5 < reflectedResources.length; ++i$5) reflectedResources[i$5] = Promise$2.resolve(resources[i$5]).reflect(); + var resultPromise = Promise$2.all(reflectedResources).then(function(inspections) { + for (var i$6 = 0; i$6 < inspections.length; ++i$6) { + var inspection = inspections[i$6]; + if (inspection.isRejected()) { + errorObj.e = inspection.error(); + return errorObj; + } else if (!inspection.isFulfilled()) { + resultPromise.cancel(); + return; + } + inspections[i$6] = inspection.value(); + } + promise._pushContext(); + fn = tryCatch(fn); + var ret = spreadArgs ? fn.apply(void 0, inspections) : fn(inspections); + var promiseCreated = promise._popContext(); + debug$2.checkForgottenReturns(ret, promiseCreated, "Promise.using", promise); + return ret; + }); + var promise = resultPromise.lastly(function() { + var inspection = new Promise$2.PromiseInspection(resultPromise); + return dispose(resources, inspection); + }); + resources.promise = promise; + promise._setOnCancel(resources); + return promise; + }; + Promise$2.prototype._setDisposable = function(disposer) { + this._bitField = this._bitField | 131072; + this._disposer = disposer; + }; + Promise$2.prototype._isDisposable = function() { + return (this._bitField & 131072) > 0; + }; + Promise$2.prototype._getDisposer = function() { + return this._disposer; + }; + Promise$2.prototype._unsetDisposable = function() { + this._bitField = this._bitField & -131073; + this._disposer = void 0; + }; + Promise$2.prototype.disposer = function(fn) { + if (typeof fn === "function") return new FunctionDisposer(fn, this, createContext()); + throw new TypeError$1(); + }; + }; + }, { + "./errors": 12, + "./util": 36 + }], + 36: [function(_dereq_$1, module$2, exports$2) { + "use strict"; + var es5 = _dereq_$1("./es5"); + var canEvaluate = typeof navigator == "undefined"; + var errorObj = { e: {} }; + var tryCatchTarget; + var globalObject = typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : this !== void 0 ? this : null; + function tryCatcher() { + try { + var target = tryCatchTarget; + tryCatchTarget = null; + return target.apply(this, arguments); + } catch (e) { + errorObj.e = e; + return errorObj; + } + } + function tryCatch(fn) { + tryCatchTarget = fn; + return tryCatcher; + } + var inherits$3 = function(Child, Parent) { + var hasProp = {}.hasOwnProperty; + function T() { + this.constructor = Child; + this.constructor$ = Parent; + for (var propertyName in Parent.prototype) if (hasProp.call(Parent.prototype, propertyName) && propertyName.charAt(propertyName.length - 1) !== "$") this[propertyName + "$"] = Parent.prototype[propertyName]; + } + T.prototype = Parent.prototype; + Child.prototype = new T(); + return Child.prototype; + }; + function isPrimitive(val) { + return val == null || val === true || val === false || typeof val === "string" || typeof val === "number"; + } + function isObject$5(value) { + return typeof value === "function" || typeof value === "object" && value !== null; + } + function maybeWrapAsError(maybeError) { + if (!isPrimitive(maybeError)) return maybeError; + return new Error(safeToString(maybeError)); + } + function withAppended(target, appendee) { + var len = target.length; + var ret$1 = new Array(len + 1); + var i$5; + for (i$5 = 0; i$5 < len; ++i$5) ret$1[i$5] = target[i$5]; + ret$1[i$5] = appendee; + return ret$1; + } + function getDataPropertyOrDefault(obj, key, defaultValue) { + if (es5.isES5) { + var desc = Object.getOwnPropertyDescriptor(obj, key); + if (desc != null) return desc.get == null && desc.set == null ? desc.value : defaultValue; + } else return {}.hasOwnProperty.call(obj, key) ? obj[key] : void 0; + } + function notEnumerableProp(obj, name, value) { + if (isPrimitive(obj)) return obj; + var descriptor = { + value, + configurable: true, + enumerable: false, + writable: true + }; + es5.defineProperty(obj, name, descriptor); + return obj; + } + function thrower(r) { + throw r; + } + var inheritedDataKeys = function() { + var excludedPrototypes = [ + Array.prototype, + Object.prototype, + Function.prototype + ]; + var isExcludedProto = function(val) { + for (var i$5 = 0; i$5 < excludedPrototypes.length; ++i$5) if (excludedPrototypes[i$5] === val) return true; + return false; + }; + if (es5.isES5) { + var getKeys = Object.getOwnPropertyNames; + return function(obj) { + var ret$1 = []; + var visitedKeys = Object.create(null); + while (obj != null && !isExcludedProto(obj)) { + var keys$2; + try { + keys$2 = getKeys(obj); + } catch (e) { + return ret$1; + } + for (var i$5 = 0; i$5 < keys$2.length; ++i$5) { + var key = keys$2[i$5]; + if (visitedKeys[key]) continue; + visitedKeys[key] = true; + var desc = Object.getOwnPropertyDescriptor(obj, key); + if (desc != null && desc.get == null && desc.set == null) ret$1.push(key); + } + obj = es5.getPrototypeOf(obj); + } + return ret$1; + }; + } else { + var hasProp = {}.hasOwnProperty; + return function(obj) { + if (isExcludedProto(obj)) return []; + var ret$1 = []; + enumeration: for (var key in obj) if (hasProp.call(obj, key)) ret$1.push(key); + else { + for (var i$5 = 0; i$5 < excludedPrototypes.length; ++i$5) if (hasProp.call(excludedPrototypes[i$5], key)) continue enumeration; + ret$1.push(key); + } + return ret$1; + }; + } + }(); + var thisAssignmentPattern = /this\s*\.\s*\S+\s*=/; + function isClass$2(fn) { + try { + if (typeof fn === "function") { + var keys$2 = es5.names(fn.prototype); + var hasMethods = es5.isES5 && keys$2.length > 1; + var hasMethodsOtherThanConstructor = keys$2.length > 0 && !(keys$2.length === 1 && keys$2[0] === "constructor"); + var hasThisAssignmentAndStaticMethods = thisAssignmentPattern.test(fn + "") && es5.names(fn).length > 0; + if (hasMethods || hasMethodsOtherThanConstructor || hasThisAssignmentAndStaticMethods) return true; + } + return false; + } catch (e) { + return false; + } + } + function toFastProperties(obj) { + function FakeConstructor() {} + FakeConstructor.prototype = obj; + var receiver = new FakeConstructor(); + function ic() { + return typeof receiver.foo; + } + ic(); + ic(); + return obj; + } + var rident = /^[a-z$_][a-z$_0-9]*$/i; + function isIdentifier$15(str$3) { + return rident.test(str$3); + } + function filledRange(count, prefix$1, suffix) { + var ret$1 = new Array(count); + for (var i$5 = 0; i$5 < count; ++i$5) ret$1[i$5] = prefix$1 + i$5 + suffix; + return ret$1; + } + function safeToString(obj) { + try { + return obj + ""; + } catch (e) { + return "[no string representation]"; + } + } + function isError(obj) { + return obj instanceof Error || obj !== null && typeof obj === "object" && typeof obj.message === "string" && typeof obj.name === "string"; + } + function markAsOriginatingFromRejection(e) { + try { + notEnumerableProp(e, "isOperational", true); + } catch (ignore) {} + } + function originatesFromRejection(e) { + if (e == null) return false; + return e instanceof Error["__BluebirdErrorTypes__"].OperationalError || e["isOperational"] === true; + } + function canAttachTrace(obj) { + return isError(obj) && es5.propertyIsWritable(obj, "stack"); + } + var ensureErrorObject = function() { + if (!("stack" in new Error())) return function(value) { + if (canAttachTrace(value)) return value; + try { + throw new Error(safeToString(value)); + } catch (err) { + return err; + } + }; + else return function(value) { + if (canAttachTrace(value)) return value; + return new Error(safeToString(value)); + }; + }(); + function classString(obj) { + return {}.toString.call(obj); + } + function copyDescriptors(from, to, filter$3) { + var keys$2 = es5.names(from); + for (var i$5 = 0; i$5 < keys$2.length; ++i$5) { + var key = keys$2[i$5]; + if (filter$3(key)) try { + es5.defineProperty(to, key, es5.getDescriptor(from, key)); + } catch (ignore) {} + } + } + var asArray = function(v$1) { + if (es5.isArray(v$1)) return v$1; + return null; + }; + if (typeof Symbol !== "undefined" && Symbol.iterator) { + var ArrayFrom = typeof Array.from === "function" ? function(v$1) { + return Array.from(v$1); + } : function(v$1) { + var ret$1 = []; + var it = v$1[Symbol.iterator](); + var itResult; + while (!(itResult = it.next()).done) ret$1.push(itResult.value); + return ret$1; + }; + asArray = function(v$1) { + if (es5.isArray(v$1)) return v$1; + else if (v$1 != null && typeof v$1[Symbol.iterator] === "function") return ArrayFrom(v$1); + return null; + }; + } + var isNode$4 = typeof process !== "undefined" && classString(process).toLowerCase() === "[object process]"; + var hasEnvVariables = typeof process !== "undefined" && typeof process.env !== "undefined"; + function env(key) { + return hasEnvVariables ? process.env[key] : void 0; + } + function getNativePromise() { + if (typeof Promise === "function") try { + var promise = new Promise(function() {}); + if (classString(promise) === "[object Promise]") return Promise; + } catch (e) {} + } + var reflectHandler; + function contextBind(ctx, cb$1) { + if (ctx === null || typeof cb$1 !== "function" || cb$1 === reflectHandler) return cb$1; + if (ctx.domain !== null) cb$1 = ctx.domain.bind(cb$1); + var async$1 = ctx.async; + if (async$1 !== null) { + var old$1 = cb$1; + cb$1 = function() { + var args = new Array(2).concat([].slice.call(arguments)); + args[0] = old$1; + args[1] = this; + return async$1.runInAsyncScope.apply(async$1, args); + }; + } + return cb$1; + } + var ret = { + setReflectHandler: function(fn) { + reflectHandler = fn; + }, + isClass: isClass$2, + isIdentifier: isIdentifier$15, + inheritedDataKeys, + getDataPropertyOrDefault, + thrower, + isArray: es5.isArray, + asArray, + notEnumerableProp, + isPrimitive, + isObject: isObject$5, + isError, + canEvaluate, + errorObj, + tryCatch, + inherits: inherits$3, + withAppended, + maybeWrapAsError, + toFastProperties, + filledRange, + toString: safeToString, + canAttachTrace, + ensureErrorObject, + originatesFromRejection, + markAsOriginatingFromRejection, + classString, + copyDescriptors, + isNode: isNode$4, + hasEnvVariables, + env, + global: globalObject, + getNativePromise, + contextBind + }; + ret.isRecentNode = ret.isNode && function() { + var version$1; + if (process.versions && process.versions.node) version$1 = process.versions.node.split(".").map(Number); + else if (process.version) version$1 = process.version.split(".").map(Number); + return version$1[0] === 0 && version$1[1] > 10 || version$1[0] > 0; + }(); + ret.nodeSupportsAsyncResource = ret.isNode && function() { + var supportsAsync = false; + try { + var res = _dereq_$1("async_hooks").AsyncResource; + supportsAsync = typeof res.prototype.runInAsyncScope === "function"; + } catch (e) { + supportsAsync = false; + } + return supportsAsync; + }(); + if (ret.isNode) ret.toFastProperties(process); + try { + throw new Error(); + } catch (e) { + ret.lastLineError = e; + } + module$2.exports = ret; + }, { + "./es5": 13, + "async_hooks": void 0 + }] + }, {}, [4])(4); + }); + if (typeof window !== "undefined" && window !== null) window.P = window.Promise; + else if (typeof self !== "undefined" && self !== null) self.P = self.Promise; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/utils.js +var require_utils$2 = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/utils.js"(exports) { + exports.__esModule = true; + exports.extend = extend$2; + exports.indexOf = indexOf; + exports.escapeExpression = escapeExpression; + exports.isEmpty = isEmpty$1; + exports.createFrame = createFrame; + exports.blockParams = blockParams; + exports.appendContextPath = appendContextPath; + var escape$1 = { + "&": "&", + "<": "<", + ">": ">", + "\"": """, + "'": "'", + "`": "`", + "=": "=" + }; + var badChars = /[&<>"'`=]/g, possible = /[&<>"'`=]/; + function escapeChar$1(chr) { + return escape$1[chr]; + } + function extend$2(obj) { + for (var i$5 = 1; i$5 < arguments.length; i$5++) for (var key in arguments[i$5]) if (Object.prototype.hasOwnProperty.call(arguments[i$5], key)) obj[key] = arguments[i$5][key]; + return obj; + } + var toString$3 = Object.prototype.toString; + exports.toString = toString$3; + var isFunction$8 = function isFunction$10(value) { + return typeof value === "function"; + }; + /* istanbul ignore next */ + if (isFunction$8(/x/)) exports.isFunction = isFunction$8 = function(value) { + return typeof value === "function" && toString$3.call(value) === "[object Function]"; + }; + exports.isFunction = isFunction$8; + /* istanbul ignore next */ + var isArray$3 = Array.isArray || function(value) { + return value && typeof value === "object" ? toString$3.call(value) === "[object Array]" : false; + }; + exports.isArray = isArray$3; + function indexOf(array, value) { + for (var i$5 = 0, len = array.length; i$5 < len; i$5++) if (array[i$5] === value) return i$5; + return -1; + } + function escapeExpression(string$3) { + if (typeof string$3 !== "string") { + if (string$3 && string$3.toHTML) return string$3.toHTML(); + else if (string$3 == null) return ""; + else if (!string$3) return string$3 + ""; + string$3 = "" + string$3; + } + if (!possible.test(string$3)) return string$3; + return string$3.replace(badChars, escapeChar$1); + } + function isEmpty$1(value) { + if (!value && value !== 0) return true; + else if (isArray$3(value) && value.length === 0) return true; + else return false; + } + function createFrame(object$3) { + var frame = extend$2({}, object$3); + frame._parent = object$3; + return frame; + } + function blockParams(params, ids) { + params.path = ids; + return params; + } + function appendContextPath(contextPath, id$4) { + return (contextPath ? contextPath + "." : "") + id$4; + } +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/exception.js +var require_exception = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/exception.js"(exports, module) { + exports.__esModule = true; + var errorProps = [ + "description", + "fileName", + "lineNumber", + "endLineNumber", + "message", + "name", + "number", + "stack" + ]; + function Exception(message, node) { + var loc = node && node.loc, line = void 0, endLineNumber = void 0, column = void 0, endColumn = void 0; + if (loc) { + line = loc.start.line; + endLineNumber = loc.end.line; + column = loc.start.column; + endColumn = loc.end.column; + message += " - " + line + ":" + column; + } + var tmp = Error.prototype.constructor.call(this, message); + for (var idx = 0; idx < errorProps.length; idx++) this[errorProps[idx]] = tmp[errorProps[idx]]; + /* istanbul ignore else */ + if (Error.captureStackTrace) Error.captureStackTrace(this, Exception); + try { + if (loc) { + this.lineNumber = line; + this.endLineNumber = endLineNumber; + /* istanbul ignore next */ + if (Object.defineProperty) { + Object.defineProperty(this, "column", { + value: column, + enumerable: true + }); + Object.defineProperty(this, "endColumn", { + value: endColumn, + enumerable: true + }); + } else { + this.column = column; + this.endColumn = endColumn; + } + } + } catch (nop) {} + } + Exception.prototype = new Error(); + exports["default"] = Exception; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/helpers/block-helper-missing.js +var require_block_helper_missing = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/helpers/block-helper-missing.js"(exports, module) { + exports.__esModule = true; + var _utils$20 = require_utils$2(); + exports["default"] = function(instance) { + instance.registerHelper("blockHelperMissing", function(context, options) { + var inverse = options.inverse, fn = options.fn; + if (context === true) return fn(this); + else if (context === false || context == null) return inverse(this); + else if (_utils$20.isArray(context)) if (context.length > 0) { + if (options.ids) options.ids = [options.name]; + return instance.helpers.each(context, options); + } else return inverse(this); + else { + if (options.data && options.ids) { + var data$2 = _utils$20.createFrame(options.data); + data$2.contextPath = _utils$20.appendContextPath(options.data.contextPath, options.name); + options = { data: data$2 }; + } + return fn(context, options); + } + }); + }; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/helpers/each.js +var require_each = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/helpers/each.js"(exports, module) { + exports.__esModule = true; + // istanbul ignore next + function _interopRequireDefault$59(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + var _utils$19 = require_utils$2(); + var _exception$9 = require_exception(); + var _exception2$9 = _interopRequireDefault$59(_exception$9); + exports["default"] = function(instance) { + instance.registerHelper("each", function(context, options) { + if (!options) throw new _exception2$9["default"]("Must pass iterator to #each"); + var fn = options.fn, inverse = options.inverse, i$5 = 0, ret = "", data$2 = void 0, contextPath = void 0; + if (options.data && options.ids) contextPath = _utils$19.appendContextPath(options.data.contextPath, options.ids[0]) + "."; + if (_utils$19.isFunction(context)) context = context.call(this); + if (options.data) data$2 = _utils$19.createFrame(options.data); + function execIteration(field, index$1, last$3) { + if (data$2) { + data$2.key = field; + data$2.index = index$1; + data$2.first = index$1 === 0; + data$2.last = !!last$3; + if (contextPath) data$2.contextPath = contextPath + field; + } + ret = ret + fn(context[field], { + data: data$2, + blockParams: _utils$19.blockParams([context[field], field], [contextPath + field, null]) + }); + } + if (context && typeof context === "object") if (_utils$19.isArray(context)) { + for (var j = context.length; i$5 < j; i$5++) if (i$5 in context) execIteration(i$5, i$5, i$5 === context.length - 1); + } else if (typeof Symbol === "function" && context[Symbol.iterator]) { + var newContext = []; + var iterator = context[Symbol.iterator](); + for (var it = iterator.next(); !it.done; it = iterator.next()) newContext.push(it.value); + context = newContext; + for (var j = context.length; i$5 < j; i$5++) execIteration(i$5, i$5, i$5 === context.length - 1); + } else (function() { + var priorKey = void 0; + Object.keys(context).forEach(function(key) { + if (priorKey !== void 0) execIteration(priorKey, i$5 - 1); + priorKey = key; + i$5++; + }); + if (priorKey !== void 0) execIteration(priorKey, i$5 - 1, true); + })(); + if (i$5 === 0) ret = inverse(this); + return ret; + }); + }; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/helpers/helper-missing.js +var require_helper_missing = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/helpers/helper-missing.js"(exports, module) { + exports.__esModule = true; + // istanbul ignore next + function _interopRequireDefault$58(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + var _exception$8 = require_exception(); + var _exception2$8 = _interopRequireDefault$58(_exception$8); + exports["default"] = function(instance) { + instance.registerHelper("helperMissing", function() { + if (arguments.length === 1) return void 0; + else throw new _exception2$8["default"]("Missing helper: \"" + arguments[arguments.length - 1].name + "\""); + }); + }; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/helpers/if.js +var require_if = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/helpers/if.js"(exports, module) { + exports.__esModule = true; + // istanbul ignore next + function _interopRequireDefault$57(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + var _utils$18 = require_utils$2(); + var _exception$7 = require_exception(); + var _exception2$7 = _interopRequireDefault$57(_exception$7); + exports["default"] = function(instance) { + instance.registerHelper("if", function(conditional, options) { + if (arguments.length != 2) throw new _exception2$7["default"]("#if requires exactly one argument"); + if (_utils$18.isFunction(conditional)) conditional = conditional.call(this); + if (!options.hash.includeZero && !conditional || _utils$18.isEmpty(conditional)) return options.inverse(this); + else return options.fn(this); + }); + instance.registerHelper("unless", function(conditional, options) { + if (arguments.length != 2) throw new _exception2$7["default"]("#unless requires exactly one argument"); + return instance.helpers["if"].call(this, conditional, { + fn: options.inverse, + inverse: options.fn, + hash: options.hash + }); + }); + }; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/helpers/log.js +var require_log = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/helpers/log.js"(exports, module) { + exports.__esModule = true; + exports["default"] = function(instance) { + instance.registerHelper("log", function() { + var args = [void 0], options = arguments[arguments.length - 1]; + for (var i$5 = 0; i$5 < arguments.length - 1; i$5++) args.push(arguments[i$5]); + var level = 1; + if (options.hash.level != null) level = options.hash.level; + else if (options.data && options.data.level != null) level = options.data.level; + args[0] = level; + instance.log.apply(instance, args); + }); + }; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/helpers/lookup.js +var require_lookup = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/helpers/lookup.js"(exports, module) { + exports.__esModule = true; + exports["default"] = function(instance) { + instance.registerHelper("lookup", function(obj, field, options) { + if (!obj) return obj; + return options.lookupProperty(obj, field); + }); + }; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/helpers/with.js +var require_with = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/helpers/with.js"(exports, module) { + exports.__esModule = true; + // istanbul ignore next + function _interopRequireDefault$56(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + var _utils$17 = require_utils$2(); + var _exception$6 = require_exception(); + var _exception2$6 = _interopRequireDefault$56(_exception$6); + exports["default"] = function(instance) { + instance.registerHelper("with", function(context, options) { + if (arguments.length != 2) throw new _exception2$6["default"]("#with requires exactly one argument"); + if (_utils$17.isFunction(context)) context = context.call(this); + var fn = options.fn; + if (!_utils$17.isEmpty(context)) { + var data$2 = options.data; + if (options.data && options.ids) { + data$2 = _utils$17.createFrame(options.data); + data$2.contextPath = _utils$17.appendContextPath(options.data.contextPath, options.ids[0]); + } + return fn(context, { + data: data$2, + blockParams: _utils$17.blockParams([context], [data$2 && data$2.contextPath]) + }); + } else return options.inverse(this); + }); + }; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/helpers.js +var require_helpers$2 = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/helpers.js"(exports) { + exports.__esModule = true; + exports.registerDefaultHelpers = registerDefaultHelpers; + exports.moveHelperToHooks = moveHelperToHooks; + // istanbul ignore next + function _interopRequireDefault$55(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + var _helpersBlockHelperMissing = require_block_helper_missing(); + var _helpersBlockHelperMissing2 = _interopRequireDefault$55(_helpersBlockHelperMissing); + var _helpersEach = require_each(); + var _helpersEach2 = _interopRequireDefault$55(_helpersEach); + var _helpersHelperMissing = require_helper_missing(); + var _helpersHelperMissing2 = _interopRequireDefault$55(_helpersHelperMissing); + var _helpersIf = require_if(); + var _helpersIf2 = _interopRequireDefault$55(_helpersIf); + var _helpersLog = require_log(); + var _helpersLog2 = _interopRequireDefault$55(_helpersLog); + var _helpersLookup = require_lookup(); + var _helpersLookup2 = _interopRequireDefault$55(_helpersLookup); + var _helpersWith = require_with(); + var _helpersWith2 = _interopRequireDefault$55(_helpersWith); + function registerDefaultHelpers(instance) { + _helpersBlockHelperMissing2["default"](instance); + _helpersEach2["default"](instance); + _helpersHelperMissing2["default"](instance); + _helpersIf2["default"](instance); + _helpersLog2["default"](instance); + _helpersLookup2["default"](instance); + _helpersWith2["default"](instance); + } + function moveHelperToHooks(instance, helperName, keepHelper) { + if (instance.helpers[helperName]) { + instance.hooks[helperName] = instance.helpers[helperName]; + if (!keepHelper) delete instance.helpers[helperName]; + } + } +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/decorators/inline.js +var require_inline = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/decorators/inline.js"(exports, module) { + exports.__esModule = true; + var _utils$16 = require_utils$2(); + exports["default"] = function(instance) { + instance.registerDecorator("inline", function(fn, props, container, options) { + var ret = fn; + if (!props.partials) { + props.partials = {}; + ret = function(context, options$1) { + var original = container.partials; + container.partials = _utils$16.extend({}, original, props.partials); + var ret$1 = fn(context, options$1); + container.partials = original; + return ret$1; + }; + } + props.partials[options.args[0]] = options.fn; + return ret; + }); + }; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/decorators.js +var require_decorators = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/decorators.js"(exports) { + exports.__esModule = true; + exports.registerDefaultDecorators = registerDefaultDecorators; + // istanbul ignore next + function _interopRequireDefault$54(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + var _decoratorsInline = require_inline(); + var _decoratorsInline2 = _interopRequireDefault$54(_decoratorsInline); + function registerDefaultDecorators(instance) { + _decoratorsInline2["default"](instance); + } +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/logger.js +var require_logger = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/logger.js"(exports, module) { + exports.__esModule = true; + var _utils$15 = require_utils$2(); + var logger = { + methodMap: [ + "debug", + "info", + "warn", + "error" + ], + level: "info", + lookupLevel: function lookupLevel(level) { + if (typeof level === "string") { + var levelMap = _utils$15.indexOf(logger.methodMap, level.toLowerCase()); + if (levelMap >= 0) level = levelMap; + else level = parseInt(level, 10); + } + return level; + }, + log: function log$1(level) { + level = logger.lookupLevel(level); + if (typeof console !== "undefined" && logger.lookupLevel(logger.level) <= level) { + var method = logger.methodMap[level]; + if (!console[method]) method = "log"; + for (var _len = arguments.length, message = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) message[_key - 1] = arguments[_key]; + console[method].apply(console, message); + } + } + }; + exports["default"] = logger; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/internal/create-new-lookup-object.js +var require_create_new_lookup_object = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/internal/create-new-lookup-object.js"(exports) { + exports.__esModule = true; + exports.createNewLookupObject = createNewLookupObject; + var _utils$14 = require_utils$2(); + /** + * Create a new object with "null"-prototype to avoid truthy results on prototype properties. + * The resulting object can be used with "object[property]" to check if a property exists + * @param {...object} sources a varargs parameter of source objects that will be merged + * @returns {object} + */ + function createNewLookupObject() { + for (var _len = arguments.length, sources = Array(_len), _key = 0; _key < _len; _key++) sources[_key] = arguments[_key]; + return _utils$14.extend.apply(void 0, [Object.create(null)].concat(sources)); + } +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/internal/proto-access.js +var require_proto_access = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/internal/proto-access.js"(exports) { + exports.__esModule = true; + exports.createProtoAccessControl = createProtoAccessControl; + exports.resultIsAllowed = resultIsAllowed; + exports.resetLoggedProperties = resetLoggedProperties; + // istanbul ignore next + function _interopRequireDefault$53(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + var _createNewLookupObject = require_create_new_lookup_object(); + var _logger$1 = require_logger(); + var _logger2$1 = _interopRequireDefault$53(_logger$1); + var loggedProperties = Object.create(null); + function createProtoAccessControl(runtimeOptions) { + var defaultMethodWhiteList = Object.create(null); + defaultMethodWhiteList["constructor"] = false; + defaultMethodWhiteList["__defineGetter__"] = false; + defaultMethodWhiteList["__defineSetter__"] = false; + defaultMethodWhiteList["__lookupGetter__"] = false; + var defaultPropertyWhiteList = Object.create(null); + defaultPropertyWhiteList["__proto__"] = false; + return { + properties: { + whitelist: _createNewLookupObject.createNewLookupObject(defaultPropertyWhiteList, runtimeOptions.allowedProtoProperties), + defaultValue: runtimeOptions.allowProtoPropertiesByDefault + }, + methods: { + whitelist: _createNewLookupObject.createNewLookupObject(defaultMethodWhiteList, runtimeOptions.allowedProtoMethods), + defaultValue: runtimeOptions.allowProtoMethodsByDefault + } + }; + } + function resultIsAllowed(result$1, protoAccessControl, propertyName) { + if (typeof result$1 === "function") return checkWhiteList(protoAccessControl.methods, propertyName); + else return checkWhiteList(protoAccessControl.properties, propertyName); + } + function checkWhiteList(protoAccessControlForType, propertyName) { + if (protoAccessControlForType.whitelist[propertyName] !== void 0) return protoAccessControlForType.whitelist[propertyName] === true; + if (protoAccessControlForType.defaultValue !== void 0) return protoAccessControlForType.defaultValue; + logUnexpecedPropertyAccessOnce(propertyName); + return false; + } + function logUnexpecedPropertyAccessOnce(propertyName) { + if (loggedProperties[propertyName] !== true) { + loggedProperties[propertyName] = true; + _logger2$1["default"].log("error", "Handlebars: Access has been denied to resolve the property \"" + propertyName + "\" because it is not an \"own property\" of its parent.\nYou can add a runtime option to disable the check or this warning:\nSee https://handlebarsjs.com/api-reference/runtime-options.html#options-to-control-prototype-access for details"); + } + } + function resetLoggedProperties() { + Object.keys(loggedProperties).forEach(function(propertyName) { + delete loggedProperties[propertyName]; + }); + } +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/base.js +var require_base$2 = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/base.js"(exports) { + exports.__esModule = true; + exports.HandlebarsEnvironment = HandlebarsEnvironment; + // istanbul ignore next + function _interopRequireDefault$52(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + var _utils$13 = require_utils$2(); + var _exception$5 = require_exception(); + var _exception2$5 = _interopRequireDefault$52(_exception$5); + var _helpers$2 = require_helpers$2(); + var _decorators = require_decorators(); + var _logger = require_logger(); + var _logger2 = _interopRequireDefault$52(_logger); + var _internalProtoAccess$1 = require_proto_access(); + var VERSION$1 = "4.7.8"; + exports.VERSION = VERSION$1; + var COMPILER_REVISION = 8; + exports.COMPILER_REVISION = COMPILER_REVISION; + var LAST_COMPATIBLE_COMPILER_REVISION = 7; + exports.LAST_COMPATIBLE_COMPILER_REVISION = LAST_COMPATIBLE_COMPILER_REVISION; + var REVISION_CHANGES = { + 1: "<= 1.0.rc.2", + 2: "== 1.0.0-rc.3", + 3: "== 1.0.0-rc.4", + 4: "== 1.x.x", + 5: "== 2.0.0-alpha.x", + 6: ">= 2.0.0-beta.1", + 7: ">= 4.0.0 <4.3.0", + 8: ">= 4.3.0" + }; + exports.REVISION_CHANGES = REVISION_CHANGES; + var objectType = "[object Object]"; + function HandlebarsEnvironment(helpers, partials, decorators) { + this.helpers = helpers || {}; + this.partials = partials || {}; + this.decorators = decorators || {}; + _helpers$2.registerDefaultHelpers(this); + _decorators.registerDefaultDecorators(this); + } + HandlebarsEnvironment.prototype = { + constructor: HandlebarsEnvironment, + logger: _logger2["default"], + log: _logger2["default"].log, + registerHelper: function registerHelper(name, fn) { + if (_utils$13.toString.call(name) === objectType) { + if (fn) throw new _exception2$5["default"]("Arg not supported with multiple helpers"); + _utils$13.extend(this.helpers, name); + } else this.helpers[name] = fn; + }, + unregisterHelper: function unregisterHelper(name) { + delete this.helpers[name]; + }, + registerPartial: function registerPartial(name, partial$1) { + if (_utils$13.toString.call(name) === objectType) _utils$13.extend(this.partials, name); + else { + if (typeof partial$1 === "undefined") throw new _exception2$5["default"]("Attempting to register a partial called \"" + name + "\" as undefined"); + this.partials[name] = partial$1; + } + }, + unregisterPartial: function unregisterPartial(name) { + delete this.partials[name]; + }, + registerDecorator: function registerDecorator(name, fn) { + if (_utils$13.toString.call(name) === objectType) { + if (fn) throw new _exception2$5["default"]("Arg not supported with multiple decorators"); + _utils$13.extend(this.decorators, name); + } else this.decorators[name] = fn; + }, + unregisterDecorator: function unregisterDecorator(name) { + delete this.decorators[name]; + }, + resetLoggedPropertyAccesses: function resetLoggedPropertyAccesses() { + _internalProtoAccess$1.resetLoggedProperties(); + } + }; + var log = _logger2["default"].log; + exports.log = log; + exports.createFrame = _utils$13.createFrame; + exports.logger = _logger2["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/safe-string.js +var require_safe_string = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/safe-string.js"(exports, module) { + exports.__esModule = true; + function SafeString(string$3) { + this.string = string$3; + } + SafeString.prototype.toString = SafeString.prototype.toHTML = function() { + return "" + this.string; + }; + exports["default"] = SafeString; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/internal/wrapHelper.js +var require_wrapHelper = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/internal/wrapHelper.js"(exports) { + exports.__esModule = true; + exports.wrapHelper = wrapHelper; + function wrapHelper(helper, transformOptionsFn) { + if (typeof helper !== "function") return helper; + var wrapper = function wrapper$1() { + var options = arguments[arguments.length - 1]; + arguments[arguments.length - 1] = transformOptionsFn(options); + return helper.apply(this, arguments); + }; + return wrapper; + } +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/runtime.js +var require_runtime = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/runtime.js"(exports) { + exports.__esModule = true; + exports.checkRevision = checkRevision; + exports.template = template$1; + exports.wrapProgram = wrapProgram; + exports.resolvePartial = resolvePartial; + exports.invokePartial = invokePartial; + exports.noop = noop$2; + // istanbul ignore next + function _interopRequireDefault$51(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + // istanbul ignore next + function _interopRequireWildcard$10(obj) { + if (obj && obj.__esModule) return obj; + else { + var newObj = {}; + if (obj != null) { + for (var key in obj) if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; + } + newObj["default"] = obj; + return newObj; + } + } + var _utils$12 = require_utils$2(); + var Utils$1 = _interopRequireWildcard$10(_utils$12); + var _exception$4 = require_exception(); + var _exception2$4 = _interopRequireDefault$51(_exception$4); + var _base$2 = require_base$2(); + var _helpers$1 = require_helpers$2(); + var _internalWrapHelper = require_wrapHelper(); + var _internalProtoAccess = require_proto_access(); + function checkRevision(compilerInfo) { + var compilerRevision = compilerInfo && compilerInfo[0] || 1, currentRevision = _base$2.COMPILER_REVISION; + if (compilerRevision >= _base$2.LAST_COMPATIBLE_COMPILER_REVISION && compilerRevision <= _base$2.COMPILER_REVISION) return; + if (compilerRevision < _base$2.LAST_COMPATIBLE_COMPILER_REVISION) { + var runtimeVersions = _base$2.REVISION_CHANGES[currentRevision], compilerVersions = _base$2.REVISION_CHANGES[compilerRevision]; + throw new _exception2$4["default"]("Template was precompiled with an older version of Handlebars than the current runtime. Please update your precompiler to a newer version (" + runtimeVersions + ") or downgrade your runtime to an older version (" + compilerVersions + ")."); + } else throw new _exception2$4["default"]("Template was precompiled with a newer version of Handlebars than the current runtime. Please update your runtime to a newer version (" + compilerInfo[1] + ")."); + } + function template$1(templateSpec, env) { + /* istanbul ignore next */ + if (!env) throw new _exception2$4["default"]("No environment passed to template"); + if (!templateSpec || !templateSpec.main) throw new _exception2$4["default"]("Unknown template object: " + typeof templateSpec); + templateSpec.main.decorator = templateSpec.main_d; + env.VM.checkRevision(templateSpec.compiler); + var templateWasPrecompiledWithCompilerV7 = templateSpec.compiler && templateSpec.compiler[0] === 7; + function invokePartialWrapper(partial$1, context, options) { + if (options.hash) { + context = Utils$1.extend({}, context, options.hash); + if (options.ids) options.ids[0] = true; + } + partial$1 = env.VM.resolvePartial.call(this, partial$1, context, options); + var extendedOptions = Utils$1.extend({}, options, { + hooks: this.hooks, + protoAccessControl: this.protoAccessControl + }); + var result$1 = env.VM.invokePartial.call(this, partial$1, context, extendedOptions); + if (result$1 == null && env.compile) { + options.partials[options.name] = env.compile(partial$1, templateSpec.compilerOptions, env); + result$1 = options.partials[options.name](context, extendedOptions); + } + if (result$1 != null) { + if (options.indent) { + var lines = result$1.split("\n"); + for (var i$5 = 0, l$1 = lines.length; i$5 < l$1; i$5++) { + if (!lines[i$5] && i$5 + 1 === l$1) break; + lines[i$5] = options.indent + lines[i$5]; + } + result$1 = lines.join("\n"); + } + return result$1; + } else throw new _exception2$4["default"]("The partial " + options.name + " could not be compiled when running in runtime-only mode"); + } + var container = { + strict: function strict(obj, name, loc) { + if (!obj || !(name in obj)) throw new _exception2$4["default"]("\"" + name + "\" not defined in " + obj, { loc }); + return container.lookupProperty(obj, name); + }, + lookupProperty: function lookupProperty(parent, propertyName) { + var result$1 = parent[propertyName]; + if (result$1 == null) return result$1; + if (Object.prototype.hasOwnProperty.call(parent, propertyName)) return result$1; + if (_internalProtoAccess.resultIsAllowed(result$1, container.protoAccessControl, propertyName)) return result$1; + return void 0; + }, + lookup: function lookup(depths, name) { + var len = depths.length; + for (var i$5 = 0; i$5 < len; i$5++) { + var result$1 = depths[i$5] && container.lookupProperty(depths[i$5], name); + if (result$1 != null) return depths[i$5][name]; + } + }, + lambda: function lambda(current, context) { + return typeof current === "function" ? current.call(context) : current; + }, + escapeExpression: Utils$1.escapeExpression, + invokePartial: invokePartialWrapper, + fn: function fn(i$5) { + var ret$1 = templateSpec[i$5]; + ret$1.decorator = templateSpec[i$5 + "_d"]; + return ret$1; + }, + programs: [], + program: function program$3(i$5, data$2, declaredBlockParams, blockParams$1, depths) { + var programWrapper = this.programs[i$5], fn = this.fn(i$5); + if (data$2 || depths || blockParams$1 || declaredBlockParams) programWrapper = wrapProgram(this, i$5, fn, data$2, declaredBlockParams, blockParams$1, depths); + else if (!programWrapper) programWrapper = this.programs[i$5] = wrapProgram(this, i$5, fn); + return programWrapper; + }, + data: function data$2(value, depth$1) { + while (value && depth$1--) value = value._parent; + return value; + }, + mergeIfNeeded: function mergeIfNeeded(param, common$2) { + var obj = param || common$2; + if (param && common$2 && param !== common$2) obj = Utils$1.extend({}, common$2, param); + return obj; + }, + nullContext: Object.seal({}), + noop: env.VM.noop, + compilerInfo: templateSpec.compiler + }; + function ret(context) { + var options = arguments.length <= 1 || arguments[1] === void 0 ? {} : arguments[1]; + var data$2 = options.data; + ret._setup(options); + if (!options.partial && templateSpec.useData) data$2 = initData(context, data$2); + var depths = void 0, blockParams$1 = templateSpec.useBlockParams ? [] : void 0; + if (templateSpec.useDepths) if (options.depths) depths = context != options.depths[0] ? [context].concat(options.depths) : options.depths; + else depths = [context]; + function main(context$1) { + return "" + templateSpec.main(container, context$1, container.helpers, container.partials, data$2, blockParams$1, depths); + } + main = executeDecorators(templateSpec.main, main, container, options.depths || [], data$2, blockParams$1); + return main(context, options); + } + ret.isTop = true; + ret._setup = function(options) { + if (!options.partial) { + var mergedHelpers = Utils$1.extend({}, env.helpers, options.helpers); + wrapHelpersToPassLookupProperty(mergedHelpers, container); + container.helpers = mergedHelpers; + if (templateSpec.usePartial) container.partials = container.mergeIfNeeded(options.partials, env.partials); + if (templateSpec.usePartial || templateSpec.useDecorators) container.decorators = Utils$1.extend({}, env.decorators, options.decorators); + container.hooks = {}; + container.protoAccessControl = _internalProtoAccess.createProtoAccessControl(options); + var keepHelperInHelpers = options.allowCallsToHelperMissing || templateWasPrecompiledWithCompilerV7; + _helpers$1.moveHelperToHooks(container, "helperMissing", keepHelperInHelpers); + _helpers$1.moveHelperToHooks(container, "blockHelperMissing", keepHelperInHelpers); + } else { + container.protoAccessControl = options.protoAccessControl; + container.helpers = options.helpers; + container.partials = options.partials; + container.decorators = options.decorators; + container.hooks = options.hooks; + } + }; + ret._child = function(i$5, data$2, blockParams$1, depths) { + if (templateSpec.useBlockParams && !blockParams$1) throw new _exception2$4["default"]("must pass block params"); + if (templateSpec.useDepths && !depths) throw new _exception2$4["default"]("must pass parent depths"); + return wrapProgram(container, i$5, templateSpec[i$5], data$2, 0, blockParams$1, depths); + }; + return ret; + } + function wrapProgram(container, i$5, fn, data$2, declaredBlockParams, blockParams$1, depths) { + function prog(context) { + var options = arguments.length <= 1 || arguments[1] === void 0 ? {} : arguments[1]; + var currentDepths = depths; + if (depths && context != depths[0] && !(context === container.nullContext && depths[0] === null)) currentDepths = [context].concat(depths); + return fn(container, context, container.helpers, container.partials, options.data || data$2, blockParams$1 && [options.blockParams].concat(blockParams$1), currentDepths); + } + prog = executeDecorators(fn, prog, container, depths, data$2, blockParams$1); + prog.program = i$5; + prog.depth = depths ? depths.length : 0; + prog.blockParams = declaredBlockParams || 0; + return prog; + } + /** + * This is currently part of the official API, therefore implementation details should not be changed. + */ + function resolvePartial(partial$1, context, options) { + if (!partial$1) if (options.name === "@partial-block") partial$1 = options.data["partial-block"]; + else partial$1 = options.partials[options.name]; + else if (!partial$1.call && !options.name) { + options.name = partial$1; + partial$1 = options.partials[partial$1]; + } + return partial$1; + } + function invokePartial(partial$1, context, options) { + var currentPartialBlock = options.data && options.data["partial-block"]; + options.partial = true; + if (options.ids) options.data.contextPath = options.ids[0] || options.data.contextPath; + var partialBlock = void 0; + if (options.fn && options.fn !== noop$2) (function() { + options.data = _base$2.createFrame(options.data); + var fn = options.fn; + partialBlock = options.data["partial-block"] = function partialBlockWrapper(context$1) { + var options$1 = arguments.length <= 1 || arguments[1] === void 0 ? {} : arguments[1]; + options$1.data = _base$2.createFrame(options$1.data); + options$1.data["partial-block"] = currentPartialBlock; + return fn(context$1, options$1); + }; + if (fn.partials) options.partials = Utils$1.extend({}, options.partials, fn.partials); + })(); + if (partial$1 === void 0 && partialBlock) partial$1 = partialBlock; + if (partial$1 === void 0) throw new _exception2$4["default"]("The partial " + options.name + " could not be found"); + else if (partial$1 instanceof Function) return partial$1(context, options); + } + function noop$2() { + return ""; + } + function initData(context, data$2) { + if (!data$2 || !("root" in data$2)) { + data$2 = data$2 ? _base$2.createFrame(data$2) : {}; + data$2.root = context; + } + return data$2; + } + function executeDecorators(fn, prog, container, depths, data$2, blockParams$1) { + if (fn.decorator) { + var props = {}; + prog = fn.decorator(prog, props, container, depths && depths[0], data$2, blockParams$1, depths); + Utils$1.extend(prog, props); + } + return prog; + } + function wrapHelpersToPassLookupProperty(mergedHelpers, container) { + Object.keys(mergedHelpers).forEach(function(helperName) { + var helper = mergedHelpers[helperName]; + mergedHelpers[helperName] = passLookupPropertyOption(helper, container); + }); + } + function passLookupPropertyOption(helper, container) { + var lookupProperty = container.lookupProperty; + return _internalWrapHelper.wrapHelper(helper, function(options) { + return Utils$1.extend({ lookupProperty }, options); + }); + } +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/no-conflict.js +var require_no_conflict = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/no-conflict.js"(exports, module) { + exports.__esModule = true; + exports["default"] = function(Handlebars) { + /* istanbul ignore next */ + (function() { + if (typeof globalThis === "object") return; + Object.prototype.__defineGetter__("__magic__", function() { + return this; + }); + __magic__.globalThis = __magic__; + delete Object.prototype.__magic__; + })(); + var $Handlebars = globalThis.Handlebars; + /* istanbul ignore next */ + Handlebars.noConflict = function() { + if (globalThis.Handlebars === Handlebars) globalThis.Handlebars = $Handlebars; + return Handlebars; + }; + }; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars.runtime.js +var require_handlebars_runtime = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars.runtime.js"(exports, module) { + exports.__esModule = true; + // istanbul ignore next + function _interopRequireDefault$50(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + // istanbul ignore next + function _interopRequireWildcard$9(obj) { + if (obj && obj.__esModule) return obj; + else { + var newObj = {}; + if (obj != null) { + for (var key in obj) if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; + } + newObj["default"] = obj; + return newObj; + } + } + var _handlebarsBase = require_base$2(); + var base = _interopRequireWildcard$9(_handlebarsBase); + var _handlebarsSafeString = require_safe_string(); + var _handlebarsSafeString2 = _interopRequireDefault$50(_handlebarsSafeString); + var _handlebarsException = require_exception(); + var _handlebarsException2 = _interopRequireDefault$50(_handlebarsException); + var _handlebarsUtils = require_utils$2(); + var Utils = _interopRequireWildcard$9(_handlebarsUtils); + var _handlebarsRuntime$1 = require_runtime(); + var runtime = _interopRequireWildcard$9(_handlebarsRuntime$1); + var _handlebarsNoConflict$1 = require_no_conflict(); + var _handlebarsNoConflict2$1 = _interopRequireDefault$50(_handlebarsNoConflict$1); + function create$5() { + var hb = new base.HandlebarsEnvironment(); + Utils.extend(hb, base); + hb.SafeString = _handlebarsSafeString2["default"]; + hb.Exception = _handlebarsException2["default"]; + hb.Utils = Utils; + hb.escapeExpression = Utils.escapeExpression; + hb.VM = runtime; + hb.template = function(spec) { + return runtime.template(spec, hb); + }; + return hb; + } + var inst$1 = create$5(); + inst$1.create = create$5; + _handlebarsNoConflict2$1["default"](inst$1); + inst$1["default"] = inst$1; + exports["default"] = inst$1; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/compiler/ast.js +var require_ast = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/compiler/ast.js"(exports, module) { + exports.__esModule = true; + var AST = { helpers: { + helperExpression: function helperExpression(node) { + return node.type === "SubExpression" || (node.type === "MustacheStatement" || node.type === "BlockStatement") && !!(node.params && node.params.length || node.hash); + }, + scopedId: function scopedId(path$28) { + return /^\.|this\b/.test(path$28.original); + }, + simpleId: function simpleId(path$28) { + return path$28.parts.length === 1 && !AST.helpers.scopedId(path$28) && !path$28.depth; + } + } }; + exports["default"] = AST; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/compiler/parser.js +var require_parser$3 = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/compiler/parser.js"(exports, module) { + exports.__esModule = true; + var handlebars = function() { + var parser$4 = { + trace: function trace() {}, + yy: {}, + symbols_: { + "error": 2, + "root": 3, + "program": 4, + "EOF": 5, + "program_repetition0": 6, + "statement": 7, + "mustache": 8, + "block": 9, + "rawBlock": 10, + "partial": 11, + "partialBlock": 12, + "content": 13, + "COMMENT": 14, + "CONTENT": 15, + "openRawBlock": 16, + "rawBlock_repetition0": 17, + "END_RAW_BLOCK": 18, + "OPEN_RAW_BLOCK": 19, + "helperName": 20, + "openRawBlock_repetition0": 21, + "openRawBlock_option0": 22, + "CLOSE_RAW_BLOCK": 23, + "openBlock": 24, + "block_option0": 25, + "closeBlock": 26, + "openInverse": 27, + "block_option1": 28, + "OPEN_BLOCK": 29, + "openBlock_repetition0": 30, + "openBlock_option0": 31, + "openBlock_option1": 32, + "CLOSE": 33, + "OPEN_INVERSE": 34, + "openInverse_repetition0": 35, + "openInverse_option0": 36, + "openInverse_option1": 37, + "openInverseChain": 38, + "OPEN_INVERSE_CHAIN": 39, + "openInverseChain_repetition0": 40, + "openInverseChain_option0": 41, + "openInverseChain_option1": 42, + "inverseAndProgram": 43, + "INVERSE": 44, + "inverseChain": 45, + "inverseChain_option0": 46, + "OPEN_ENDBLOCK": 47, + "OPEN": 48, + "mustache_repetition0": 49, + "mustache_option0": 50, + "OPEN_UNESCAPED": 51, + "mustache_repetition1": 52, + "mustache_option1": 53, + "CLOSE_UNESCAPED": 54, + "OPEN_PARTIAL": 55, + "partialName": 56, + "partial_repetition0": 57, + "partial_option0": 58, + "openPartialBlock": 59, + "OPEN_PARTIAL_BLOCK": 60, + "openPartialBlock_repetition0": 61, + "openPartialBlock_option0": 62, + "param": 63, + "sexpr": 64, + "OPEN_SEXPR": 65, + "sexpr_repetition0": 66, + "sexpr_option0": 67, + "CLOSE_SEXPR": 68, + "hash": 69, + "hash_repetition_plus0": 70, + "hashSegment": 71, + "ID": 72, + "EQUALS": 73, + "blockParams": 74, + "OPEN_BLOCK_PARAMS": 75, + "blockParams_repetition_plus0": 76, + "CLOSE_BLOCK_PARAMS": 77, + "path": 78, + "dataName": 79, + "STRING": 80, + "NUMBER": 81, + "BOOLEAN": 82, + "UNDEFINED": 83, + "NULL": 84, + "DATA": 85, + "pathSegments": 86, + "SEP": 87, + "$accept": 0, + "$end": 1 + }, + terminals_: { + 2: "error", + 5: "EOF", + 14: "COMMENT", + 15: "CONTENT", + 18: "END_RAW_BLOCK", + 19: "OPEN_RAW_BLOCK", + 23: "CLOSE_RAW_BLOCK", + 29: "OPEN_BLOCK", + 33: "CLOSE", + 34: "OPEN_INVERSE", + 39: "OPEN_INVERSE_CHAIN", + 44: "INVERSE", + 47: "OPEN_ENDBLOCK", + 48: "OPEN", + 51: "OPEN_UNESCAPED", + 54: "CLOSE_UNESCAPED", + 55: "OPEN_PARTIAL", + 60: "OPEN_PARTIAL_BLOCK", + 65: "OPEN_SEXPR", + 68: "CLOSE_SEXPR", + 72: "ID", + 73: "EQUALS", + 75: "OPEN_BLOCK_PARAMS", + 77: "CLOSE_BLOCK_PARAMS", + 80: "STRING", + 81: "NUMBER", + 82: "BOOLEAN", + 83: "UNDEFINED", + 84: "NULL", + 85: "DATA", + 87: "SEP" + }, + productions_: [ + 0, + [3, 2], + [4, 1], + [7, 1], + [7, 1], + [7, 1], + [7, 1], + [7, 1], + [7, 1], + [7, 1], + [13, 1], + [10, 3], + [16, 5], + [9, 4], + [9, 4], + [24, 6], + [27, 6], + [38, 6], + [43, 2], + [45, 3], + [45, 1], + [26, 3], + [8, 5], + [8, 5], + [11, 5], + [12, 3], + [59, 5], + [63, 1], + [63, 1], + [64, 5], + [69, 1], + [71, 3], + [74, 3], + [20, 1], + [20, 1], + [20, 1], + [20, 1], + [20, 1], + [20, 1], + [20, 1], + [56, 1], + [56, 1], + [79, 2], + [78, 1], + [86, 3], + [86, 1], + [6, 0], + [6, 2], + [17, 0], + [17, 2], + [21, 0], + [21, 2], + [22, 0], + [22, 1], + [25, 0], + [25, 1], + [28, 0], + [28, 1], + [30, 0], + [30, 2], + [31, 0], + [31, 1], + [32, 0], + [32, 1], + [35, 0], + [35, 2], + [36, 0], + [36, 1], + [37, 0], + [37, 1], + [40, 0], + [40, 2], + [41, 0], + [41, 1], + [42, 0], + [42, 1], + [46, 0], + [46, 1], + [49, 0], + [49, 2], + [50, 0], + [50, 1], + [52, 0], + [52, 2], + [53, 0], + [53, 1], + [57, 0], + [57, 2], + [58, 0], + [58, 1], + [61, 0], + [61, 2], + [62, 0], + [62, 1], + [66, 0], + [66, 2], + [67, 0], + [67, 1], + [70, 1], + [70, 2], + [76, 1], + [76, 2] + ], + performAction: function anonymous(yytext, yyleng, yylineno, yy$1, yystate, $$, _$) { + var $0 = $$.length - 1; + switch (yystate) { + case 1: return $$[$0 - 1]; + case 2: + this.$ = yy$1.prepareProgram($$[$0]); + break; + case 3: + this.$ = $$[$0]; + break; + case 4: + this.$ = $$[$0]; + break; + case 5: + this.$ = $$[$0]; + break; + case 6: + this.$ = $$[$0]; + break; + case 7: + this.$ = $$[$0]; + break; + case 8: + this.$ = $$[$0]; + break; + case 9: + this.$ = { + type: "CommentStatement", + value: yy$1.stripComment($$[$0]), + strip: yy$1.stripFlags($$[$0], $$[$0]), + loc: yy$1.locInfo(this._$) + }; + break; + case 10: + this.$ = { + type: "ContentStatement", + original: $$[$0], + value: $$[$0], + loc: yy$1.locInfo(this._$) + }; + break; + case 11: + this.$ = yy$1.prepareRawBlock($$[$0 - 2], $$[$0 - 1], $$[$0], this._$); + break; + case 12: + this.$ = { + path: $$[$0 - 3], + params: $$[$0 - 2], + hash: $$[$0 - 1] + }; + break; + case 13: + this.$ = yy$1.prepareBlock($$[$0 - 3], $$[$0 - 2], $$[$0 - 1], $$[$0], false, this._$); + break; + case 14: + this.$ = yy$1.prepareBlock($$[$0 - 3], $$[$0 - 2], $$[$0 - 1], $$[$0], true, this._$); + break; + case 15: + this.$ = { + open: $$[$0 - 5], + path: $$[$0 - 4], + params: $$[$0 - 3], + hash: $$[$0 - 2], + blockParams: $$[$0 - 1], + strip: yy$1.stripFlags($$[$0 - 5], $$[$0]) + }; + break; + case 16: + this.$ = { + path: $$[$0 - 4], + params: $$[$0 - 3], + hash: $$[$0 - 2], + blockParams: $$[$0 - 1], + strip: yy$1.stripFlags($$[$0 - 5], $$[$0]) + }; + break; + case 17: + this.$ = { + path: $$[$0 - 4], + params: $$[$0 - 3], + hash: $$[$0 - 2], + blockParams: $$[$0 - 1], + strip: yy$1.stripFlags($$[$0 - 5], $$[$0]) + }; + break; + case 18: + this.$ = { + strip: yy$1.stripFlags($$[$0 - 1], $$[$0 - 1]), + program: $$[$0] + }; + break; + case 19: + var inverse = yy$1.prepareBlock($$[$0 - 2], $$[$0 - 1], $$[$0], $$[$0], false, this._$), program$3 = yy$1.prepareProgram([inverse], $$[$0 - 1].loc); + program$3.chained = true; + this.$ = { + strip: $$[$0 - 2].strip, + program: program$3, + chain: true + }; + break; + case 20: + this.$ = $$[$0]; + break; + case 21: + this.$ = { + path: $$[$0 - 1], + strip: yy$1.stripFlags($$[$0 - 2], $$[$0]) + }; + break; + case 22: + this.$ = yy$1.prepareMustache($$[$0 - 3], $$[$0 - 2], $$[$0 - 1], $$[$0 - 4], yy$1.stripFlags($$[$0 - 4], $$[$0]), this._$); + break; + case 23: + this.$ = yy$1.prepareMustache($$[$0 - 3], $$[$0 - 2], $$[$0 - 1], $$[$0 - 4], yy$1.stripFlags($$[$0 - 4], $$[$0]), this._$); + break; + case 24: + this.$ = { + type: "PartialStatement", + name: $$[$0 - 3], + params: $$[$0 - 2], + hash: $$[$0 - 1], + indent: "", + strip: yy$1.stripFlags($$[$0 - 4], $$[$0]), + loc: yy$1.locInfo(this._$) + }; + break; + case 25: + this.$ = yy$1.preparePartialBlock($$[$0 - 2], $$[$0 - 1], $$[$0], this._$); + break; + case 26: + this.$ = { + path: $$[$0 - 3], + params: $$[$0 - 2], + hash: $$[$0 - 1], + strip: yy$1.stripFlags($$[$0 - 4], $$[$0]) + }; + break; + case 27: + this.$ = $$[$0]; + break; + case 28: + this.$ = $$[$0]; + break; + case 29: + this.$ = { + type: "SubExpression", + path: $$[$0 - 3], + params: $$[$0 - 2], + hash: $$[$0 - 1], + loc: yy$1.locInfo(this._$) + }; + break; + case 30: + this.$ = { + type: "Hash", + pairs: $$[$0], + loc: yy$1.locInfo(this._$) + }; + break; + case 31: + this.$ = { + type: "HashPair", + key: yy$1.id($$[$0 - 2]), + value: $$[$0], + loc: yy$1.locInfo(this._$) + }; + break; + case 32: + this.$ = yy$1.id($$[$0 - 1]); + break; + case 33: + this.$ = $$[$0]; + break; + case 34: + this.$ = $$[$0]; + break; + case 35: + this.$ = { + type: "StringLiteral", + value: $$[$0], + original: $$[$0], + loc: yy$1.locInfo(this._$) + }; + break; + case 36: + this.$ = { + type: "NumberLiteral", + value: Number($$[$0]), + original: Number($$[$0]), + loc: yy$1.locInfo(this._$) + }; + break; + case 37: + this.$ = { + type: "BooleanLiteral", + value: $$[$0] === "true", + original: $$[$0] === "true", + loc: yy$1.locInfo(this._$) + }; + break; + case 38: + this.$ = { + type: "UndefinedLiteral", + original: void 0, + value: void 0, + loc: yy$1.locInfo(this._$) + }; + break; + case 39: + this.$ = { + type: "NullLiteral", + original: null, + value: null, + loc: yy$1.locInfo(this._$) + }; + break; + case 40: + this.$ = $$[$0]; + break; + case 41: + this.$ = $$[$0]; + break; + case 42: + this.$ = yy$1.preparePath(true, $$[$0], this._$); + break; + case 43: + this.$ = yy$1.preparePath(false, $$[$0], this._$); + break; + case 44: + $$[$0 - 2].push({ + part: yy$1.id($$[$0]), + original: $$[$0], + separator: $$[$0 - 1] + }); + this.$ = $$[$0 - 2]; + break; + case 45: + this.$ = [{ + part: yy$1.id($$[$0]), + original: $$[$0] + }]; + break; + case 46: + this.$ = []; + break; + case 47: + $$[$0 - 1].push($$[$0]); + break; + case 48: + this.$ = []; + break; + case 49: + $$[$0 - 1].push($$[$0]); + break; + case 50: + this.$ = []; + break; + case 51: + $$[$0 - 1].push($$[$0]); + break; + case 58: + this.$ = []; + break; + case 59: + $$[$0 - 1].push($$[$0]); + break; + case 64: + this.$ = []; + break; + case 65: + $$[$0 - 1].push($$[$0]); + break; + case 70: + this.$ = []; + break; + case 71: + $$[$0 - 1].push($$[$0]); + break; + case 78: + this.$ = []; + break; + case 79: + $$[$0 - 1].push($$[$0]); + break; + case 82: + this.$ = []; + break; + case 83: + $$[$0 - 1].push($$[$0]); + break; + case 86: + this.$ = []; + break; + case 87: + $$[$0 - 1].push($$[$0]); + break; + case 90: + this.$ = []; + break; + case 91: + $$[$0 - 1].push($$[$0]); + break; + case 94: + this.$ = []; + break; + case 95: + $$[$0 - 1].push($$[$0]); + break; + case 98: + this.$ = [$$[$0]]; + break; + case 99: + $$[$0 - 1].push($$[$0]); + break; + case 100: + this.$ = [$$[$0]]; + break; + case 101: + $$[$0 - 1].push($$[$0]); + break; + } + }, + table: [ + { + 3: 1, + 4: 2, + 5: [2, 46], + 6: 3, + 14: [2, 46], + 15: [2, 46], + 19: [2, 46], + 29: [2, 46], + 34: [2, 46], + 48: [2, 46], + 51: [2, 46], + 55: [2, 46], + 60: [2, 46] + }, + { 1: [3] }, + { 5: [1, 4] }, + { + 5: [2, 2], + 7: 5, + 8: 6, + 9: 7, + 10: 8, + 11: 9, + 12: 10, + 13: 11, + 14: [1, 12], + 15: [1, 20], + 16: 17, + 19: [1, 23], + 24: 15, + 27: 16, + 29: [1, 21], + 34: [1, 22], + 39: [2, 2], + 44: [2, 2], + 47: [2, 2], + 48: [1, 13], + 51: [1, 14], + 55: [1, 18], + 59: 19, + 60: [1, 24] + }, + { 1: [2, 1] }, + { + 5: [2, 47], + 14: [2, 47], + 15: [2, 47], + 19: [2, 47], + 29: [2, 47], + 34: [2, 47], + 39: [2, 47], + 44: [2, 47], + 47: [2, 47], + 48: [2, 47], + 51: [2, 47], + 55: [2, 47], + 60: [2, 47] + }, + { + 5: [2, 3], + 14: [2, 3], + 15: [2, 3], + 19: [2, 3], + 29: [2, 3], + 34: [2, 3], + 39: [2, 3], + 44: [2, 3], + 47: [2, 3], + 48: [2, 3], + 51: [2, 3], + 55: [2, 3], + 60: [2, 3] + }, + { + 5: [2, 4], + 14: [2, 4], + 15: [2, 4], + 19: [2, 4], + 29: [2, 4], + 34: [2, 4], + 39: [2, 4], + 44: [2, 4], + 47: [2, 4], + 48: [2, 4], + 51: [2, 4], + 55: [2, 4], + 60: [2, 4] + }, + { + 5: [2, 5], + 14: [2, 5], + 15: [2, 5], + 19: [2, 5], + 29: [2, 5], + 34: [2, 5], + 39: [2, 5], + 44: [2, 5], + 47: [2, 5], + 48: [2, 5], + 51: [2, 5], + 55: [2, 5], + 60: [2, 5] + }, + { + 5: [2, 6], + 14: [2, 6], + 15: [2, 6], + 19: [2, 6], + 29: [2, 6], + 34: [2, 6], + 39: [2, 6], + 44: [2, 6], + 47: [2, 6], + 48: [2, 6], + 51: [2, 6], + 55: [2, 6], + 60: [2, 6] + }, + { + 5: [2, 7], + 14: [2, 7], + 15: [2, 7], + 19: [2, 7], + 29: [2, 7], + 34: [2, 7], + 39: [2, 7], + 44: [2, 7], + 47: [2, 7], + 48: [2, 7], + 51: [2, 7], + 55: [2, 7], + 60: [2, 7] + }, + { + 5: [2, 8], + 14: [2, 8], + 15: [2, 8], + 19: [2, 8], + 29: [2, 8], + 34: [2, 8], + 39: [2, 8], + 44: [2, 8], + 47: [2, 8], + 48: [2, 8], + 51: [2, 8], + 55: [2, 8], + 60: [2, 8] + }, + { + 5: [2, 9], + 14: [2, 9], + 15: [2, 9], + 19: [2, 9], + 29: [2, 9], + 34: [2, 9], + 39: [2, 9], + 44: [2, 9], + 47: [2, 9], + 48: [2, 9], + 51: [2, 9], + 55: [2, 9], + 60: [2, 9] + }, + { + 20: 25, + 72: [1, 35], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { + 20: 36, + 72: [1, 35], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { + 4: 37, + 6: 3, + 14: [2, 46], + 15: [2, 46], + 19: [2, 46], + 29: [2, 46], + 34: [2, 46], + 39: [2, 46], + 44: [2, 46], + 47: [2, 46], + 48: [2, 46], + 51: [2, 46], + 55: [2, 46], + 60: [2, 46] + }, + { + 4: 38, + 6: 3, + 14: [2, 46], + 15: [2, 46], + 19: [2, 46], + 29: [2, 46], + 34: [2, 46], + 44: [2, 46], + 47: [2, 46], + 48: [2, 46], + 51: [2, 46], + 55: [2, 46], + 60: [2, 46] + }, + { + 15: [2, 48], + 17: 39, + 18: [2, 48] + }, + { + 20: 41, + 56: 40, + 64: 42, + 65: [1, 43], + 72: [1, 35], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { + 4: 44, + 6: 3, + 14: [2, 46], + 15: [2, 46], + 19: [2, 46], + 29: [2, 46], + 34: [2, 46], + 47: [2, 46], + 48: [2, 46], + 51: [2, 46], + 55: [2, 46], + 60: [2, 46] + }, + { + 5: [2, 10], + 14: [2, 10], + 15: [2, 10], + 18: [2, 10], + 19: [2, 10], + 29: [2, 10], + 34: [2, 10], + 39: [2, 10], + 44: [2, 10], + 47: [2, 10], + 48: [2, 10], + 51: [2, 10], + 55: [2, 10], + 60: [2, 10] + }, + { + 20: 45, + 72: [1, 35], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { + 20: 46, + 72: [1, 35], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { + 20: 47, + 72: [1, 35], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { + 20: 41, + 56: 48, + 64: 42, + 65: [1, 43], + 72: [1, 35], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { + 33: [2, 78], + 49: 49, + 65: [2, 78], + 72: [2, 78], + 80: [2, 78], + 81: [2, 78], + 82: [2, 78], + 83: [2, 78], + 84: [2, 78], + 85: [2, 78] + }, + { + 23: [2, 33], + 33: [2, 33], + 54: [2, 33], + 65: [2, 33], + 68: [2, 33], + 72: [2, 33], + 75: [2, 33], + 80: [2, 33], + 81: [2, 33], + 82: [2, 33], + 83: [2, 33], + 84: [2, 33], + 85: [2, 33] + }, + { + 23: [2, 34], + 33: [2, 34], + 54: [2, 34], + 65: [2, 34], + 68: [2, 34], + 72: [2, 34], + 75: [2, 34], + 80: [2, 34], + 81: [2, 34], + 82: [2, 34], + 83: [2, 34], + 84: [2, 34], + 85: [2, 34] + }, + { + 23: [2, 35], + 33: [2, 35], + 54: [2, 35], + 65: [2, 35], + 68: [2, 35], + 72: [2, 35], + 75: [2, 35], + 80: [2, 35], + 81: [2, 35], + 82: [2, 35], + 83: [2, 35], + 84: [2, 35], + 85: [2, 35] + }, + { + 23: [2, 36], + 33: [2, 36], + 54: [2, 36], + 65: [2, 36], + 68: [2, 36], + 72: [2, 36], + 75: [2, 36], + 80: [2, 36], + 81: [2, 36], + 82: [2, 36], + 83: [2, 36], + 84: [2, 36], + 85: [2, 36] + }, + { + 23: [2, 37], + 33: [2, 37], + 54: [2, 37], + 65: [2, 37], + 68: [2, 37], + 72: [2, 37], + 75: [2, 37], + 80: [2, 37], + 81: [2, 37], + 82: [2, 37], + 83: [2, 37], + 84: [2, 37], + 85: [2, 37] + }, + { + 23: [2, 38], + 33: [2, 38], + 54: [2, 38], + 65: [2, 38], + 68: [2, 38], + 72: [2, 38], + 75: [2, 38], + 80: [2, 38], + 81: [2, 38], + 82: [2, 38], + 83: [2, 38], + 84: [2, 38], + 85: [2, 38] + }, + { + 23: [2, 39], + 33: [2, 39], + 54: [2, 39], + 65: [2, 39], + 68: [2, 39], + 72: [2, 39], + 75: [2, 39], + 80: [2, 39], + 81: [2, 39], + 82: [2, 39], + 83: [2, 39], + 84: [2, 39], + 85: [2, 39] + }, + { + 23: [2, 43], + 33: [2, 43], + 54: [2, 43], + 65: [2, 43], + 68: [2, 43], + 72: [2, 43], + 75: [2, 43], + 80: [2, 43], + 81: [2, 43], + 82: [2, 43], + 83: [2, 43], + 84: [2, 43], + 85: [2, 43], + 87: [1, 50] + }, + { + 72: [1, 35], + 86: 51 + }, + { + 23: [2, 45], + 33: [2, 45], + 54: [2, 45], + 65: [2, 45], + 68: [2, 45], + 72: [2, 45], + 75: [2, 45], + 80: [2, 45], + 81: [2, 45], + 82: [2, 45], + 83: [2, 45], + 84: [2, 45], + 85: [2, 45], + 87: [2, 45] + }, + { + 52: 52, + 54: [2, 82], + 65: [2, 82], + 72: [2, 82], + 80: [2, 82], + 81: [2, 82], + 82: [2, 82], + 83: [2, 82], + 84: [2, 82], + 85: [2, 82] + }, + { + 25: 53, + 38: 55, + 39: [1, 57], + 43: 56, + 44: [1, 58], + 45: 54, + 47: [2, 54] + }, + { + 28: 59, + 43: 60, + 44: [1, 58], + 47: [2, 56] + }, + { + 13: 62, + 15: [1, 20], + 18: [1, 61] + }, + { + 33: [2, 86], + 57: 63, + 65: [2, 86], + 72: [2, 86], + 80: [2, 86], + 81: [2, 86], + 82: [2, 86], + 83: [2, 86], + 84: [2, 86], + 85: [2, 86] + }, + { + 33: [2, 40], + 65: [2, 40], + 72: [2, 40], + 80: [2, 40], + 81: [2, 40], + 82: [2, 40], + 83: [2, 40], + 84: [2, 40], + 85: [2, 40] + }, + { + 33: [2, 41], + 65: [2, 41], + 72: [2, 41], + 80: [2, 41], + 81: [2, 41], + 82: [2, 41], + 83: [2, 41], + 84: [2, 41], + 85: [2, 41] + }, + { + 20: 64, + 72: [1, 35], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { + 26: 65, + 47: [1, 66] + }, + { + 30: 67, + 33: [2, 58], + 65: [2, 58], + 72: [2, 58], + 75: [2, 58], + 80: [2, 58], + 81: [2, 58], + 82: [2, 58], + 83: [2, 58], + 84: [2, 58], + 85: [2, 58] + }, + { + 33: [2, 64], + 35: 68, + 65: [2, 64], + 72: [2, 64], + 75: [2, 64], + 80: [2, 64], + 81: [2, 64], + 82: [2, 64], + 83: [2, 64], + 84: [2, 64], + 85: [2, 64] + }, + { + 21: 69, + 23: [2, 50], + 65: [2, 50], + 72: [2, 50], + 80: [2, 50], + 81: [2, 50], + 82: [2, 50], + 83: [2, 50], + 84: [2, 50], + 85: [2, 50] + }, + { + 33: [2, 90], + 61: 70, + 65: [2, 90], + 72: [2, 90], + 80: [2, 90], + 81: [2, 90], + 82: [2, 90], + 83: [2, 90], + 84: [2, 90], + 85: [2, 90] + }, + { + 20: 74, + 33: [2, 80], + 50: 71, + 63: 72, + 64: 75, + 65: [1, 43], + 69: 73, + 70: 76, + 71: 77, + 72: [1, 78], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { 72: [1, 79] }, + { + 23: [2, 42], + 33: [2, 42], + 54: [2, 42], + 65: [2, 42], + 68: [2, 42], + 72: [2, 42], + 75: [2, 42], + 80: [2, 42], + 81: [2, 42], + 82: [2, 42], + 83: [2, 42], + 84: [2, 42], + 85: [2, 42], + 87: [1, 50] + }, + { + 20: 74, + 53: 80, + 54: [2, 84], + 63: 81, + 64: 75, + 65: [1, 43], + 69: 82, + 70: 76, + 71: 77, + 72: [1, 78], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { + 26: 83, + 47: [1, 66] + }, + { 47: [2, 55] }, + { + 4: 84, + 6: 3, + 14: [2, 46], + 15: [2, 46], + 19: [2, 46], + 29: [2, 46], + 34: [2, 46], + 39: [2, 46], + 44: [2, 46], + 47: [2, 46], + 48: [2, 46], + 51: [2, 46], + 55: [2, 46], + 60: [2, 46] + }, + { 47: [2, 20] }, + { + 20: 85, + 72: [1, 35], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { + 4: 86, + 6: 3, + 14: [2, 46], + 15: [2, 46], + 19: [2, 46], + 29: [2, 46], + 34: [2, 46], + 47: [2, 46], + 48: [2, 46], + 51: [2, 46], + 55: [2, 46], + 60: [2, 46] + }, + { + 26: 87, + 47: [1, 66] + }, + { 47: [2, 57] }, + { + 5: [2, 11], + 14: [2, 11], + 15: [2, 11], + 19: [2, 11], + 29: [2, 11], + 34: [2, 11], + 39: [2, 11], + 44: [2, 11], + 47: [2, 11], + 48: [2, 11], + 51: [2, 11], + 55: [2, 11], + 60: [2, 11] + }, + { + 15: [2, 49], + 18: [2, 49] + }, + { + 20: 74, + 33: [2, 88], + 58: 88, + 63: 89, + 64: 75, + 65: [1, 43], + 69: 90, + 70: 76, + 71: 77, + 72: [1, 78], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { + 65: [2, 94], + 66: 91, + 68: [2, 94], + 72: [2, 94], + 80: [2, 94], + 81: [2, 94], + 82: [2, 94], + 83: [2, 94], + 84: [2, 94], + 85: [2, 94] + }, + { + 5: [2, 25], + 14: [2, 25], + 15: [2, 25], + 19: [2, 25], + 29: [2, 25], + 34: [2, 25], + 39: [2, 25], + 44: [2, 25], + 47: [2, 25], + 48: [2, 25], + 51: [2, 25], + 55: [2, 25], + 60: [2, 25] + }, + { + 20: 92, + 72: [1, 35], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { + 20: 74, + 31: 93, + 33: [2, 60], + 63: 94, + 64: 75, + 65: [1, 43], + 69: 95, + 70: 76, + 71: 77, + 72: [1, 78], + 75: [2, 60], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { + 20: 74, + 33: [2, 66], + 36: 96, + 63: 97, + 64: 75, + 65: [1, 43], + 69: 98, + 70: 76, + 71: 77, + 72: [1, 78], + 75: [2, 66], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { + 20: 74, + 22: 99, + 23: [2, 52], + 63: 100, + 64: 75, + 65: [1, 43], + 69: 101, + 70: 76, + 71: 77, + 72: [1, 78], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { + 20: 74, + 33: [2, 92], + 62: 102, + 63: 103, + 64: 75, + 65: [1, 43], + 69: 104, + 70: 76, + 71: 77, + 72: [1, 78], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { 33: [1, 105] }, + { + 33: [2, 79], + 65: [2, 79], + 72: [2, 79], + 80: [2, 79], + 81: [2, 79], + 82: [2, 79], + 83: [2, 79], + 84: [2, 79], + 85: [2, 79] + }, + { 33: [2, 81] }, + { + 23: [2, 27], + 33: [2, 27], + 54: [2, 27], + 65: [2, 27], + 68: [2, 27], + 72: [2, 27], + 75: [2, 27], + 80: [2, 27], + 81: [2, 27], + 82: [2, 27], + 83: [2, 27], + 84: [2, 27], + 85: [2, 27] + }, + { + 23: [2, 28], + 33: [2, 28], + 54: [2, 28], + 65: [2, 28], + 68: [2, 28], + 72: [2, 28], + 75: [2, 28], + 80: [2, 28], + 81: [2, 28], + 82: [2, 28], + 83: [2, 28], + 84: [2, 28], + 85: [2, 28] + }, + { + 23: [2, 30], + 33: [2, 30], + 54: [2, 30], + 68: [2, 30], + 71: 106, + 72: [1, 107], + 75: [2, 30] + }, + { + 23: [2, 98], + 33: [2, 98], + 54: [2, 98], + 68: [2, 98], + 72: [2, 98], + 75: [2, 98] + }, + { + 23: [2, 45], + 33: [2, 45], + 54: [2, 45], + 65: [2, 45], + 68: [2, 45], + 72: [2, 45], + 73: [1, 108], + 75: [2, 45], + 80: [2, 45], + 81: [2, 45], + 82: [2, 45], + 83: [2, 45], + 84: [2, 45], + 85: [2, 45], + 87: [2, 45] + }, + { + 23: [2, 44], + 33: [2, 44], + 54: [2, 44], + 65: [2, 44], + 68: [2, 44], + 72: [2, 44], + 75: [2, 44], + 80: [2, 44], + 81: [2, 44], + 82: [2, 44], + 83: [2, 44], + 84: [2, 44], + 85: [2, 44], + 87: [2, 44] + }, + { 54: [1, 109] }, + { + 54: [2, 83], + 65: [2, 83], + 72: [2, 83], + 80: [2, 83], + 81: [2, 83], + 82: [2, 83], + 83: [2, 83], + 84: [2, 83], + 85: [2, 83] + }, + { 54: [2, 85] }, + { + 5: [2, 13], + 14: [2, 13], + 15: [2, 13], + 19: [2, 13], + 29: [2, 13], + 34: [2, 13], + 39: [2, 13], + 44: [2, 13], + 47: [2, 13], + 48: [2, 13], + 51: [2, 13], + 55: [2, 13], + 60: [2, 13] + }, + { + 38: 55, + 39: [1, 57], + 43: 56, + 44: [1, 58], + 45: 111, + 46: 110, + 47: [2, 76] + }, + { + 33: [2, 70], + 40: 112, + 65: [2, 70], + 72: [2, 70], + 75: [2, 70], + 80: [2, 70], + 81: [2, 70], + 82: [2, 70], + 83: [2, 70], + 84: [2, 70], + 85: [2, 70] + }, + { 47: [2, 18] }, + { + 5: [2, 14], + 14: [2, 14], + 15: [2, 14], + 19: [2, 14], + 29: [2, 14], + 34: [2, 14], + 39: [2, 14], + 44: [2, 14], + 47: [2, 14], + 48: [2, 14], + 51: [2, 14], + 55: [2, 14], + 60: [2, 14] + }, + { 33: [1, 113] }, + { + 33: [2, 87], + 65: [2, 87], + 72: [2, 87], + 80: [2, 87], + 81: [2, 87], + 82: [2, 87], + 83: [2, 87], + 84: [2, 87], + 85: [2, 87] + }, + { 33: [2, 89] }, + { + 20: 74, + 63: 115, + 64: 75, + 65: [1, 43], + 67: 114, + 68: [2, 96], + 69: 116, + 70: 76, + 71: 77, + 72: [1, 78], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { 33: [1, 117] }, + { + 32: 118, + 33: [2, 62], + 74: 119, + 75: [1, 120] + }, + { + 33: [2, 59], + 65: [2, 59], + 72: [2, 59], + 75: [2, 59], + 80: [2, 59], + 81: [2, 59], + 82: [2, 59], + 83: [2, 59], + 84: [2, 59], + 85: [2, 59] + }, + { + 33: [2, 61], + 75: [2, 61] + }, + { + 33: [2, 68], + 37: 121, + 74: 122, + 75: [1, 120] + }, + { + 33: [2, 65], + 65: [2, 65], + 72: [2, 65], + 75: [2, 65], + 80: [2, 65], + 81: [2, 65], + 82: [2, 65], + 83: [2, 65], + 84: [2, 65], + 85: [2, 65] + }, + { + 33: [2, 67], + 75: [2, 67] + }, + { 23: [1, 123] }, + { + 23: [2, 51], + 65: [2, 51], + 72: [2, 51], + 80: [2, 51], + 81: [2, 51], + 82: [2, 51], + 83: [2, 51], + 84: [2, 51], + 85: [2, 51] + }, + { 23: [2, 53] }, + { 33: [1, 124] }, + { + 33: [2, 91], + 65: [2, 91], + 72: [2, 91], + 80: [2, 91], + 81: [2, 91], + 82: [2, 91], + 83: [2, 91], + 84: [2, 91], + 85: [2, 91] + }, + { 33: [2, 93] }, + { + 5: [2, 22], + 14: [2, 22], + 15: [2, 22], + 19: [2, 22], + 29: [2, 22], + 34: [2, 22], + 39: [2, 22], + 44: [2, 22], + 47: [2, 22], + 48: [2, 22], + 51: [2, 22], + 55: [2, 22], + 60: [2, 22] + }, + { + 23: [2, 99], + 33: [2, 99], + 54: [2, 99], + 68: [2, 99], + 72: [2, 99], + 75: [2, 99] + }, + { 73: [1, 108] }, + { + 20: 74, + 63: 125, + 64: 75, + 65: [1, 43], + 72: [1, 35], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { + 5: [2, 23], + 14: [2, 23], + 15: [2, 23], + 19: [2, 23], + 29: [2, 23], + 34: [2, 23], + 39: [2, 23], + 44: [2, 23], + 47: [2, 23], + 48: [2, 23], + 51: [2, 23], + 55: [2, 23], + 60: [2, 23] + }, + { 47: [2, 19] }, + { 47: [2, 77] }, + { + 20: 74, + 33: [2, 72], + 41: 126, + 63: 127, + 64: 75, + 65: [1, 43], + 69: 128, + 70: 76, + 71: 77, + 72: [1, 78], + 75: [2, 72], + 78: 26, + 79: 27, + 80: [1, 28], + 81: [1, 29], + 82: [1, 30], + 83: [1, 31], + 84: [1, 32], + 85: [1, 34], + 86: 33 + }, + { + 5: [2, 24], + 14: [2, 24], + 15: [2, 24], + 19: [2, 24], + 29: [2, 24], + 34: [2, 24], + 39: [2, 24], + 44: [2, 24], + 47: [2, 24], + 48: [2, 24], + 51: [2, 24], + 55: [2, 24], + 60: [2, 24] + }, + { 68: [1, 129] }, + { + 65: [2, 95], + 68: [2, 95], + 72: [2, 95], + 80: [2, 95], + 81: [2, 95], + 82: [2, 95], + 83: [2, 95], + 84: [2, 95], + 85: [2, 95] + }, + { 68: [2, 97] }, + { + 5: [2, 21], + 14: [2, 21], + 15: [2, 21], + 19: [2, 21], + 29: [2, 21], + 34: [2, 21], + 39: [2, 21], + 44: [2, 21], + 47: [2, 21], + 48: [2, 21], + 51: [2, 21], + 55: [2, 21], + 60: [2, 21] + }, + { 33: [1, 130] }, + { 33: [2, 63] }, + { + 72: [1, 132], + 76: 131 + }, + { 33: [1, 133] }, + { 33: [2, 69] }, + { + 15: [2, 12], + 18: [2, 12] + }, + { + 14: [2, 26], + 15: [2, 26], + 19: [2, 26], + 29: [2, 26], + 34: [2, 26], + 47: [2, 26], + 48: [2, 26], + 51: [2, 26], + 55: [2, 26], + 60: [2, 26] + }, + { + 23: [2, 31], + 33: [2, 31], + 54: [2, 31], + 68: [2, 31], + 72: [2, 31], + 75: [2, 31] + }, + { + 33: [2, 74], + 42: 134, + 74: 135, + 75: [1, 120] + }, + { + 33: [2, 71], + 65: [2, 71], + 72: [2, 71], + 75: [2, 71], + 80: [2, 71], + 81: [2, 71], + 82: [2, 71], + 83: [2, 71], + 84: [2, 71], + 85: [2, 71] + }, + { + 33: [2, 73], + 75: [2, 73] + }, + { + 23: [2, 29], + 33: [2, 29], + 54: [2, 29], + 65: [2, 29], + 68: [2, 29], + 72: [2, 29], + 75: [2, 29], + 80: [2, 29], + 81: [2, 29], + 82: [2, 29], + 83: [2, 29], + 84: [2, 29], + 85: [2, 29] + }, + { + 14: [2, 15], + 15: [2, 15], + 19: [2, 15], + 29: [2, 15], + 34: [2, 15], + 39: [2, 15], + 44: [2, 15], + 47: [2, 15], + 48: [2, 15], + 51: [2, 15], + 55: [2, 15], + 60: [2, 15] + }, + { + 72: [1, 137], + 77: [1, 136] + }, + { + 72: [2, 100], + 77: [2, 100] + }, + { + 14: [2, 16], + 15: [2, 16], + 19: [2, 16], + 29: [2, 16], + 34: [2, 16], + 44: [2, 16], + 47: [2, 16], + 48: [2, 16], + 51: [2, 16], + 55: [2, 16], + 60: [2, 16] + }, + { 33: [1, 138] }, + { 33: [2, 75] }, + { 33: [2, 32] }, + { + 72: [2, 101], + 77: [2, 101] + }, + { + 14: [2, 17], + 15: [2, 17], + 19: [2, 17], + 29: [2, 17], + 34: [2, 17], + 39: [2, 17], + 44: [2, 17], + 47: [2, 17], + 48: [2, 17], + 51: [2, 17], + 55: [2, 17], + 60: [2, 17] + } + ], + defaultActions: { + 4: [2, 1], + 54: [2, 55], + 56: [2, 20], + 60: [2, 57], + 73: [2, 81], + 82: [2, 85], + 86: [2, 18], + 90: [2, 89], + 101: [2, 53], + 104: [2, 93], + 110: [2, 19], + 111: [2, 77], + 116: [2, 97], + 119: [2, 63], + 122: [2, 69], + 135: [2, 75], + 136: [2, 32] + }, + parseError: function parseError(str$3, hash$2) { + throw new Error(str$3); + }, + parse: function parse$17(input) { + var self$1 = this, stack = [0], vstack = [null], lstack = [], table = this.table, yytext = "", yylineno = 0, yyleng = 0, recovering = 0, TERROR = 2, EOF = 1; + this.lexer.setInput(input); + this.lexer.yy = this.yy; + this.yy.lexer = this.lexer; + this.yy.parser = this; + if (typeof this.lexer.yylloc == "undefined") this.lexer.yylloc = {}; + var yyloc = this.lexer.yylloc; + lstack.push(yyloc); + var ranges = this.lexer.options && this.lexer.options.ranges; + if (typeof this.yy.parseError === "function") this.parseError = this.yy.parseError; + function popStack(n$3) { + stack.length = stack.length - 2 * n$3; + vstack.length = vstack.length - n$3; + lstack.length = lstack.length - n$3; + } + function lex() { + var token$1; + token$1 = self$1.lexer.lex() || 1; + if (typeof token$1 !== "number") token$1 = self$1.symbols_[token$1] || token$1; + return token$1; + } + var symbol, preErrorSymbol, state, action, a, r, yyval = {}, p$1, len, newState, expected; + while (true) { + state = stack[stack.length - 1]; + if (this.defaultActions[state]) action = this.defaultActions[state]; + else { + if (symbol === null || typeof symbol == "undefined") symbol = lex(); + action = table[state] && table[state][symbol]; + } + if (typeof action === "undefined" || !action.length || !action[0]) { + var errStr = ""; + if (!recovering) { + expected = []; + for (p$1 in table[state]) if (this.terminals_[p$1] && p$1 > 2) expected.push("'" + this.terminals_[p$1] + "'"); + if (this.lexer.showPosition) errStr = "Parse error on line " + (yylineno + 1) + ":\n" + this.lexer.showPosition() + "\nExpecting " + expected.join(", ") + ", got '" + (this.terminals_[symbol] || symbol) + "'"; + else errStr = "Parse error on line " + (yylineno + 1) + ": Unexpected " + (symbol == 1 ? "end of input" : "'" + (this.terminals_[symbol] || symbol) + "'"); + this.parseError(errStr, { + text: this.lexer.match, + token: this.terminals_[symbol] || symbol, + line: this.lexer.yylineno, + loc: yyloc, + expected + }); + } + } + if (action[0] instanceof Array && action.length > 1) throw new Error("Parse Error: multiple actions possible at state: " + state + ", token: " + symbol); + switch (action[0]) { + case 1: + stack.push(symbol); + vstack.push(this.lexer.yytext); + lstack.push(this.lexer.yylloc); + stack.push(action[1]); + symbol = null; + if (!preErrorSymbol) { + yyleng = this.lexer.yyleng; + yytext = this.lexer.yytext; + yylineno = this.lexer.yylineno; + yyloc = this.lexer.yylloc; + if (recovering > 0) recovering--; + } else { + symbol = preErrorSymbol; + preErrorSymbol = null; + } + break; + case 2: + len = this.productions_[action[1]][1]; + yyval.$ = vstack[vstack.length - len]; + yyval._$ = { + first_line: lstack[lstack.length - (len || 1)].first_line, + last_line: lstack[lstack.length - 1].last_line, + first_column: lstack[lstack.length - (len || 1)].first_column, + last_column: lstack[lstack.length - 1].last_column + }; + if (ranges) yyval._$.range = [lstack[lstack.length - (len || 1)].range[0], lstack[lstack.length - 1].range[1]]; + r = this.performAction.call(yyval, yytext, yyleng, yylineno, this.yy, action[1], vstack, lstack); + if (typeof r !== "undefined") return r; + if (len) { + stack = stack.slice(0, -1 * len * 2); + vstack = vstack.slice(0, -1 * len); + lstack = lstack.slice(0, -1 * len); + } + stack.push(this.productions_[action[1]][0]); + vstack.push(yyval.$); + lstack.push(yyval._$); + newState = table[stack[stack.length - 2]][stack[stack.length - 1]]; + stack.push(newState); + break; + case 3: return true; + } + } + return true; + } + }; + var lexer = function() { + var lexer$1 = { + EOF: 1, + parseError: function parseError(str$3, hash$2) { + if (this.yy.parser) this.yy.parser.parseError(str$3, hash$2); + else throw new Error(str$3); + }, + setInput: function setInput(input) { + this._input = input; + this._more = this._less = this.done = false; + this.yylineno = this.yyleng = 0; + this.yytext = this.matched = this.match = ""; + this.conditionStack = ["INITIAL"]; + this.yylloc = { + first_line: 1, + first_column: 0, + last_line: 1, + last_column: 0 + }; + if (this.options.ranges) this.yylloc.range = [0, 0]; + this.offset = 0; + return this; + }, + input: function input() { + var ch = this._input[0]; + this.yytext += ch; + this.yyleng++; + this.offset++; + this.match += ch; + this.matched += ch; + var lines = ch.match(/(?:\r\n?|\n).*/g); + if (lines) { + this.yylineno++; + this.yylloc.last_line++; + } else this.yylloc.last_column++; + if (this.options.ranges) this.yylloc.range[1]++; + this._input = this._input.slice(1); + return ch; + }, + unput: function unput(ch) { + var len = ch.length; + var lines = ch.split(/(?:\r\n?|\n)/g); + this._input = ch + this._input; + this.yytext = this.yytext.substr(0, this.yytext.length - len - 1); + this.offset -= len; + var oldLines = this.match.split(/(?:\r\n?|\n)/g); + this.match = this.match.substr(0, this.match.length - 1); + this.matched = this.matched.substr(0, this.matched.length - 1); + if (lines.length - 1) this.yylineno -= lines.length - 1; + var r = this.yylloc.range; + this.yylloc = { + first_line: this.yylloc.first_line, + last_line: this.yylineno + 1, + first_column: this.yylloc.first_column, + last_column: lines ? (lines.length === oldLines.length ? this.yylloc.first_column : 0) + oldLines[oldLines.length - lines.length].length - lines[0].length : this.yylloc.first_column - len + }; + if (this.options.ranges) this.yylloc.range = [r[0], r[0] + this.yyleng - len]; + return this; + }, + more: function more() { + this._more = true; + return this; + }, + less: function less$1(n$3) { + this.unput(this.match.slice(n$3)); + }, + pastInput: function pastInput() { + var past = this.matched.substr(0, this.matched.length - this.match.length); + return (past.length > 20 ? "..." : "") + past.substr(-20).replace(/\n/g, ""); + }, + upcomingInput: function upcomingInput() { + var next = this.match; + if (next.length < 20) next += this._input.substr(0, 20 - next.length); + return (next.substr(0, 20) + (next.length > 20 ? "..." : "")).replace(/\n/g, ""); + }, + showPosition: function showPosition() { + var pre = this.pastInput(); + var c$2 = new Array(pre.length + 1).join("-"); + return pre + this.upcomingInput() + "\n" + c$2 + "^"; + }, + next: function next() { + if (this.done) return this.EOF; + if (!this._input) this.done = true; + var token$1, match, tempMatch, index$1, col, lines; + if (!this._more) { + this.yytext = ""; + this.match = ""; + } + var rules = this._currentRules(); + for (var i$5 = 0; i$5 < rules.length; i$5++) { + tempMatch = this._input.match(this.rules[rules[i$5]]); + if (tempMatch && (!match || tempMatch[0].length > match[0].length)) { + match = tempMatch; + index$1 = i$5; + if (!this.options.flex) break; + } + } + if (match) { + lines = match[0].match(/(?:\r\n?|\n).*/g); + if (lines) this.yylineno += lines.length; + this.yylloc = { + first_line: this.yylloc.last_line, + last_line: this.yylineno + 1, + first_column: this.yylloc.last_column, + last_column: lines ? lines[lines.length - 1].length - lines[lines.length - 1].match(/\r?\n?/)[0].length : this.yylloc.last_column + match[0].length + }; + this.yytext += match[0]; + this.match += match[0]; + this.matches = match; + this.yyleng = this.yytext.length; + if (this.options.ranges) this.yylloc.range = [this.offset, this.offset += this.yyleng]; + this._more = false; + this._input = this._input.slice(match[0].length); + this.matched += match[0]; + token$1 = this.performAction.call(this, this.yy, this, rules[index$1], this.conditionStack[this.conditionStack.length - 1]); + if (this.done && this._input) this.done = false; + if (token$1) return token$1; + else return; + } + if (this._input === "") return this.EOF; + else return this.parseError("Lexical error on line " + (this.yylineno + 1) + ". Unrecognized text.\n" + this.showPosition(), { + text: "", + token: null, + line: this.yylineno + }); + }, + lex: function lex() { + var r = this.next(); + if (typeof r !== "undefined") return r; + else return this.lex(); + }, + begin: function begin(condition) { + this.conditionStack.push(condition); + }, + popState: function popState() { + return this.conditionStack.pop(); + }, + _currentRules: function _currentRules() { + return this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules; + }, + topState: function topState() { + return this.conditionStack[this.conditionStack.length - 2]; + }, + pushState: function begin(condition) { + this.begin(condition); + } + }; + lexer$1.options = {}; + lexer$1.performAction = function anonymous(yy$1, yy_, $avoiding_name_collisions, YY_START) { + function strip(start, end) { + return yy_.yytext = yy_.yytext.substring(start, yy_.yyleng - end + start); + } + var YYSTATE = YY_START; + switch ($avoiding_name_collisions) { + case 0: + if (yy_.yytext.slice(-2) === "\\\\") { + strip(0, 1); + this.begin("mu"); + } else if (yy_.yytext.slice(-1) === "\\") { + strip(0, 1); + this.begin("emu"); + } else this.begin("mu"); + if (yy_.yytext) return 15; + break; + case 1: return 15; + case 2: + this.popState(); + return 15; + case 3: + this.begin("raw"); + return 15; + case 4: + this.popState(); + if (this.conditionStack[this.conditionStack.length - 1] === "raw") return 15; + else { + strip(5, 9); + return "END_RAW_BLOCK"; + } + break; + case 5: return 15; + case 6: + this.popState(); + return 14; + case 7: return 65; + case 8: return 68; + case 9: return 19; + case 10: + this.popState(); + this.begin("raw"); + return 23; + case 11: return 55; + case 12: return 60; + case 13: return 29; + case 14: return 47; + case 15: + this.popState(); + return 44; + case 16: + this.popState(); + return 44; + case 17: return 34; + case 18: return 39; + case 19: return 51; + case 20: return 48; + case 21: + this.unput(yy_.yytext); + this.popState(); + this.begin("com"); + break; + case 22: + this.popState(); + return 14; + case 23: return 48; + case 24: return 73; + case 25: return 72; + case 26: return 72; + case 27: return 87; + case 28: break; + case 29: + this.popState(); + return 54; + case 30: + this.popState(); + return 33; + case 31: + yy_.yytext = strip(1, 2).replace(/\\"/g, "\""); + return 80; + case 32: + yy_.yytext = strip(1, 2).replace(/\\'/g, "'"); + return 80; + case 33: return 85; + case 34: return 82; + case 35: return 82; + case 36: return 83; + case 37: return 84; + case 38: return 81; + case 39: return 75; + case 40: return 77; + case 41: return 72; + case 42: + yy_.yytext = yy_.yytext.replace(/\\([\\\]])/g, "$1"); + return 72; + case 43: return "INVALID"; + case 44: return 5; + } + }; + lexer$1.rules = [ + /^(?:[^\x00]*?(?=(\{\{)))/, + /^(?:[^\x00]+)/, + /^(?:[^\x00]{2,}?(?=(\{\{|\\\{\{|\\\\\{\{|$)))/, + /^(?:\{\{\{\{(?=[^/]))/, + /^(?:\{\{\{\{\/[^\s!"#%-,\.\/;->@\[-\^`\{-~]+(?=[=}\s\/.])\}\}\}\})/, + /^(?:[^\x00]+?(?=(\{\{\{\{)))/, + /^(?:[\s\S]*?--(~)?\}\})/, + /^(?:\()/, + /^(?:\))/, + /^(?:\{\{\{\{)/, + /^(?:\}\}\}\})/, + /^(?:\{\{(~)?>)/, + /^(?:\{\{(~)?#>)/, + /^(?:\{\{(~)?#\*?)/, + /^(?:\{\{(~)?\/)/, + /^(?:\{\{(~)?\^\s*(~)?\}\})/, + /^(?:\{\{(~)?\s*else\s*(~)?\}\})/, + /^(?:\{\{(~)?\^)/, + /^(?:\{\{(~)?\s*else\b)/, + /^(?:\{\{(~)?\{)/, + /^(?:\{\{(~)?&)/, + /^(?:\{\{(~)?!--)/, + /^(?:\{\{(~)?![\s\S]*?\}\})/, + /^(?:\{\{(~)?\*?)/, + /^(?:=)/, + /^(?:\.\.)/, + /^(?:\.(?=([=~}\s\/.)|])))/, + /^(?:[\/.])/, + /^(?:\s+)/, + /^(?:\}(~)?\}\})/, + /^(?:(~)?\}\})/, + /^(?:"(\\["]|[^"])*")/, + /^(?:'(\\[']|[^'])*')/, + /^(?:@)/, + /^(?:true(?=([~}\s)])))/, + /^(?:false(?=([~}\s)])))/, + /^(?:undefined(?=([~}\s)])))/, + /^(?:null(?=([~}\s)])))/, + /^(?:-?[0-9]+(?:\.[0-9]+)?(?=([~}\s)])))/, + /^(?:as\s+\|)/, + /^(?:\|)/, + /^(?:([^\s!"#%-,\.\/;->@\[-\^`\{-~]+(?=([=~}\s\/.)|]))))/, + /^(?:\[(\\\]|[^\]])*\])/, + /^(?:.)/, + /^(?:$)/ + ]; + lexer$1.conditions = { + "mu": { + "rules": [ + 7, + 8, + 9, + 10, + 11, + 12, + 13, + 14, + 15, + 16, + 17, + 18, + 19, + 20, + 21, + 22, + 23, + 24, + 25, + 26, + 27, + 28, + 29, + 30, + 31, + 32, + 33, + 34, + 35, + 36, + 37, + 38, + 39, + 40, + 41, + 42, + 43, + 44 + ], + "inclusive": false + }, + "emu": { + "rules": [2], + "inclusive": false + }, + "com": { + "rules": [6], + "inclusive": false + }, + "raw": { + "rules": [ + 3, + 4, + 5 + ], + "inclusive": false + }, + "INITIAL": { + "rules": [ + 0, + 1, + 44 + ], + "inclusive": true + } + }; + return lexer$1; + }(); + parser$4.lexer = lexer; + function Parser$10() { + this.yy = {}; + } + Parser$10.prototype = parser$4; + parser$4.Parser = Parser$10; + return new Parser$10(); + }(); + exports["default"] = handlebars; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/compiler/visitor.js +var require_visitor = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/compiler/visitor.js"(exports, module) { + exports.__esModule = true; + // istanbul ignore next + function _interopRequireDefault$49(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + var _exception$3 = require_exception(); + var _exception2$3 = _interopRequireDefault$49(_exception$3); + function Visitor() { + this.parents = []; + } + Visitor.prototype = { + constructor: Visitor, + mutating: false, + acceptKey: function acceptKey(node, name) { + var value = this.accept(node[name]); + if (this.mutating) { + if (value && !Visitor.prototype[value.type]) throw new _exception2$3["default"]("Unexpected node type \"" + value.type + "\" found when accepting " + name + " on " + node.type); + node[name] = value; + } + }, + acceptRequired: function acceptRequired(node, name) { + this.acceptKey(node, name); + if (!node[name]) throw new _exception2$3["default"](node.type + " requires " + name); + }, + acceptArray: function acceptArray(array) { + for (var i$5 = 0, l$1 = array.length; i$5 < l$1; i$5++) { + this.acceptKey(array, i$5); + if (!array[i$5]) { + array.splice(i$5, 1); + i$5--; + l$1--; + } + } + }, + accept: function accept(object$3) { + if (!object$3) return; + /* istanbul ignore next: Sanity code */ + if (!this[object$3.type]) throw new _exception2$3["default"]("Unknown type: " + object$3.type, object$3); + if (this.current) this.parents.unshift(this.current); + this.current = object$3; + var ret = this[object$3.type](object$3); + this.current = this.parents.shift(); + if (!this.mutating || ret) return ret; + else if (ret !== false) return object$3; + }, + Program: function Program$1(program$3) { + this.acceptArray(program$3.body); + }, + MustacheStatement: visitSubExpression, + Decorator: visitSubExpression, + BlockStatement: visitBlock, + DecoratorBlock: visitBlock, + PartialStatement: visitPartial, + PartialBlockStatement: function PartialBlockStatement(partial$1) { + visitPartial.call(this, partial$1); + this.acceptKey(partial$1, "program"); + }, + ContentStatement: function ContentStatement() {}, + CommentStatement: function CommentStatement() {}, + SubExpression: visitSubExpression, + PathExpression: function PathExpression() {}, + StringLiteral: function StringLiteral$2() {}, + NumberLiteral: function NumberLiteral$1() {}, + BooleanLiteral: function BooleanLiteral$2() {}, + UndefinedLiteral: function UndefinedLiteral() {}, + NullLiteral: function NullLiteral$2() {}, + Hash: function Hash(hash$2) { + this.acceptArray(hash$2.pairs); + }, + HashPair: function HashPair(pair) { + this.acceptRequired(pair, "value"); + } + }; + function visitSubExpression(mustache) { + this.acceptRequired(mustache, "path"); + this.acceptArray(mustache.params); + this.acceptKey(mustache, "hash"); + } + function visitBlock(block) { + visitSubExpression.call(this, block); + this.acceptKey(block, "program"); + this.acceptKey(block, "inverse"); + } + function visitPartial(partial$1) { + this.acceptRequired(partial$1, "name"); + this.acceptArray(partial$1.params); + this.acceptKey(partial$1, "hash"); + } + exports["default"] = Visitor; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/compiler/whitespace-control.js +var require_whitespace_control = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/compiler/whitespace-control.js"(exports, module) { + exports.__esModule = true; + // istanbul ignore next + function _interopRequireDefault$48(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + var _visitor = require_visitor(); + var _visitor2 = _interopRequireDefault$48(_visitor); + function WhitespaceControl() { + var options = arguments.length <= 0 || arguments[0] === void 0 ? {} : arguments[0]; + this.options = options; + } + WhitespaceControl.prototype = new _visitor2["default"](); + WhitespaceControl.prototype.Program = function(program$3) { + var doStandalone = !this.options.ignoreStandalone; + var isRoot$3 = !this.isRootSeen; + this.isRootSeen = true; + var body = program$3.body; + for (var i$5 = 0, l$1 = body.length; i$5 < l$1; i$5++) { + var current = body[i$5], strip = this.accept(current); + if (!strip) continue; + var _isPrevWhitespace = isPrevWhitespace(body, i$5, isRoot$3), _isNextWhitespace = isNextWhitespace(body, i$5, isRoot$3), openStandalone = strip.openStandalone && _isPrevWhitespace, closeStandalone = strip.closeStandalone && _isNextWhitespace, inlineStandalone = strip.inlineStandalone && _isPrevWhitespace && _isNextWhitespace; + if (strip.close) omitRight(body, i$5, true); + if (strip.open) omitLeft(body, i$5, true); + if (doStandalone && inlineStandalone) { + omitRight(body, i$5); + if (omitLeft(body, i$5)) { + if (current.type === "PartialStatement") current.indent = /([ \t]+$)/.exec(body[i$5 - 1].original)[1]; + } + } + if (doStandalone && openStandalone) { + omitRight((current.program || current.inverse).body); + omitLeft(body, i$5); + } + if (doStandalone && closeStandalone) { + omitRight(body, i$5); + omitLeft((current.inverse || current.program).body); + } + } + return program$3; + }; + WhitespaceControl.prototype.BlockStatement = WhitespaceControl.prototype.DecoratorBlock = WhitespaceControl.prototype.PartialBlockStatement = function(block) { + this.accept(block.program); + this.accept(block.inverse); + var program$3 = block.program || block.inverse, inverse = block.program && block.inverse, firstInverse = inverse, lastInverse = inverse; + if (inverse && inverse.chained) { + firstInverse = inverse.body[0].program; + while (lastInverse.chained) lastInverse = lastInverse.body[lastInverse.body.length - 1].program; + } + var strip = { + open: block.openStrip.open, + close: block.closeStrip.close, + openStandalone: isNextWhitespace(program$3.body), + closeStandalone: isPrevWhitespace((firstInverse || program$3).body) + }; + if (block.openStrip.close) omitRight(program$3.body, null, true); + if (inverse) { + var inverseStrip = block.inverseStrip; + if (inverseStrip.open) omitLeft(program$3.body, null, true); + if (inverseStrip.close) omitRight(firstInverse.body, null, true); + if (block.closeStrip.open) omitLeft(lastInverse.body, null, true); + if (!this.options.ignoreStandalone && isPrevWhitespace(program$3.body) && isNextWhitespace(firstInverse.body)) { + omitLeft(program$3.body); + omitRight(firstInverse.body); + } + } else if (block.closeStrip.open) omitLeft(program$3.body, null, true); + return strip; + }; + WhitespaceControl.prototype.Decorator = WhitespaceControl.prototype.MustacheStatement = function(mustache) { + return mustache.strip; + }; + WhitespaceControl.prototype.PartialStatement = WhitespaceControl.prototype.CommentStatement = function(node) { + /* istanbul ignore next */ + var strip = node.strip || {}; + return { + inlineStandalone: true, + open: strip.open, + close: strip.close + }; + }; + function isPrevWhitespace(body, i$5, isRoot$3) { + if (i$5 === void 0) i$5 = body.length; + var prev = body[i$5 - 1], sibling = body[i$5 - 2]; + if (!prev) return isRoot$3; + if (prev.type === "ContentStatement") return (sibling || !isRoot$3 ? /\r?\n\s*?$/ : /(^|\r?\n)\s*?$/).test(prev.original); + } + function isNextWhitespace(body, i$5, isRoot$3) { + if (i$5 === void 0) i$5 = -1; + var next = body[i$5 + 1], sibling = body[i$5 + 2]; + if (!next) return isRoot$3; + if (next.type === "ContentStatement") return (sibling || !isRoot$3 ? /^\s*?\r?\n/ : /^\s*?(\r?\n|$)/).test(next.original); + } + function omitRight(body, i$5, multiple) { + var current = body[i$5 == null ? 0 : i$5 + 1]; + if (!current || current.type !== "ContentStatement" || !multiple && current.rightStripped) return; + var original = current.value; + current.value = current.value.replace(multiple ? /^\s+/ : /^[ \t]*\r?\n?/, ""); + current.rightStripped = current.value !== original; + } + function omitLeft(body, i$5, multiple) { + var current = body[i$5 == null ? body.length - 1 : i$5 - 1]; + if (!current || current.type !== "ContentStatement" || !multiple && current.leftStripped) return; + var original = current.value; + current.value = current.value.replace(multiple ? /\s+$/ : /[ \t]+$/, ""); + current.leftStripped = current.value !== original; + return current.leftStripped; + } + exports["default"] = WhitespaceControl; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/compiler/helpers.js +var require_helpers$1 = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/compiler/helpers.js"(exports) { + exports.__esModule = true; + exports.SourceLocation = SourceLocation; + exports.id = id$2; + exports.stripFlags = stripFlags; + exports.stripComment = stripComment; + exports.preparePath = preparePath; + exports.prepareMustache = prepareMustache; + exports.prepareRawBlock = prepareRawBlock; + exports.prepareBlock = prepareBlock; + exports.prepareProgram = prepareProgram; + exports.preparePartialBlock = preparePartialBlock; + // istanbul ignore next + function _interopRequireDefault$47(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + var _exception$2 = require_exception(); + var _exception2$2 = _interopRequireDefault$47(_exception$2); + function validateClose(open, close) { + close = close.path ? close.path.original : close; + if (open.path.original !== close) { + var errorNode = { loc: open.path.loc }; + throw new _exception2$2["default"](open.path.original + " doesn't match " + close, errorNode); + } + } + function SourceLocation(source, locInfo) { + this.source = source; + this.start = { + line: locInfo.first_line, + column: locInfo.first_column + }; + this.end = { + line: locInfo.last_line, + column: locInfo.last_column + }; + } + function id$2(token$1) { + if (/^\[.*\]$/.test(token$1)) return token$1.substring(1, token$1.length - 1); + else return token$1; + } + function stripFlags(open, close) { + return { + open: open.charAt(2) === "~", + close: close.charAt(close.length - 3) === "~" + }; + } + function stripComment(comment$7) { + return comment$7.replace(/^\{\{~?!-?-?/, "").replace(/-?-?~?\}\}$/, ""); + } + function preparePath(data$2, parts, loc) { + loc = this.locInfo(loc); + var original = data$2 ? "@" : "", dig = [], depth$1 = 0; + for (var i$5 = 0, l$1 = parts.length; i$5 < l$1; i$5++) { + var part = parts[i$5].part, isLiteral$5 = parts[i$5].original !== part; + original += (parts[i$5].separator || "") + part; + if (!isLiteral$5 && (part === ".." || part === "." || part === "this")) { + if (dig.length > 0) throw new _exception2$2["default"]("Invalid path: " + original, { loc }); + else if (part === "..") depth$1++; + } else dig.push(part); + } + return { + type: "PathExpression", + data: data$2, + depth: depth$1, + parts: dig, + original, + loc + }; + } + function prepareMustache(path$28, params, hash$2, open, strip, locInfo) { + var escapeFlag = open.charAt(3) || open.charAt(2), escaped = escapeFlag !== "{" && escapeFlag !== "&"; + var decorator$1 = /\*/.test(open); + return { + type: decorator$1 ? "Decorator" : "MustacheStatement", + path: path$28, + params, + hash: hash$2, + escaped, + strip, + loc: this.locInfo(locInfo) + }; + } + function prepareRawBlock(openRawBlock, contents, close, locInfo) { + validateClose(openRawBlock, close); + locInfo = this.locInfo(locInfo); + var program$3 = { + type: "Program", + body: contents, + strip: {}, + loc: locInfo + }; + return { + type: "BlockStatement", + path: openRawBlock.path, + params: openRawBlock.params, + hash: openRawBlock.hash, + program: program$3, + openStrip: {}, + inverseStrip: {}, + closeStrip: {}, + loc: locInfo + }; + } + function prepareBlock(openBlock, program$3, inverseAndProgram, close, inverted, locInfo) { + if (close && close.path) validateClose(openBlock, close); + var decorator$1 = /\*/.test(openBlock.open); + program$3.blockParams = openBlock.blockParams; + var inverse = void 0, inverseStrip = void 0; + if (inverseAndProgram) { + if (decorator$1) throw new _exception2$2["default"]("Unexpected inverse block on decorator", inverseAndProgram); + if (inverseAndProgram.chain) inverseAndProgram.program.body[0].closeStrip = close.strip; + inverseStrip = inverseAndProgram.strip; + inverse = inverseAndProgram.program; + } + if (inverted) { + inverted = inverse; + inverse = program$3; + program$3 = inverted; + } + return { + type: decorator$1 ? "DecoratorBlock" : "BlockStatement", + path: openBlock.path, + params: openBlock.params, + hash: openBlock.hash, + program: program$3, + inverse, + openStrip: openBlock.strip, + inverseStrip, + closeStrip: close && close.strip, + loc: this.locInfo(locInfo) + }; + } + function prepareProgram(statements$2, loc) { + if (!loc && statements$2.length) { + var firstLoc = statements$2[0].loc, lastLoc = statements$2[statements$2.length - 1].loc; + /* istanbul ignore else */ + if (firstLoc && lastLoc) loc = { + source: firstLoc.source, + start: { + line: firstLoc.start.line, + column: firstLoc.start.column + }, + end: { + line: lastLoc.end.line, + column: lastLoc.end.column + } + }; + } + return { + type: "Program", + body: statements$2, + strip: {}, + loc + }; + } + function preparePartialBlock(open, program$3, close, locInfo) { + validateClose(open, close); + return { + type: "PartialBlockStatement", + name: open.path, + params: open.params, + hash: open.hash, + program: program$3, + openStrip: open.strip, + closeStrip: close && close.strip, + loc: this.locInfo(locInfo) + }; + } +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/compiler/base.js +var require_base$1 = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/compiler/base.js"(exports) { + exports.__esModule = true; + exports.parseWithoutProcessing = parseWithoutProcessing; + exports.parse = parse$6; + // istanbul ignore next + function _interopRequireWildcard$8(obj) { + if (obj && obj.__esModule) return obj; + else { + var newObj = {}; + if (obj != null) { + for (var key in obj) if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; + } + newObj["default"] = obj; + return newObj; + } + } + // istanbul ignore next + function _interopRequireDefault$46(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + var _parser$6 = require_parser$3(); + var _parser2$2 = _interopRequireDefault$46(_parser$6); + var _whitespaceControl = require_whitespace_control(); + var _whitespaceControl2 = _interopRequireDefault$46(_whitespaceControl); + var _helpers = require_helpers$1(); + var Helpers = _interopRequireWildcard$8(_helpers); + var _utils$11 = require_utils$2(); + exports.parser = _parser2$2["default"]; + var yy = {}; + _utils$11.extend(yy, Helpers); + function parseWithoutProcessing(input, options) { + if (input.type === "Program") return input; + _parser2$2["default"].yy = yy; + yy.locInfo = function(locInfo) { + return new yy.SourceLocation(options && options.srcName, locInfo); + }; + var ast = _parser2$2["default"].parse(input); + return ast; + } + function parse$6(input, options) { + var ast = parseWithoutProcessing(input, options); + var strip = new _whitespaceControl2["default"](options); + return strip.accept(ast); + } +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/compiler/compiler.js +var require_compiler = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/compiler/compiler.js"(exports) { + exports.__esModule = true; + exports.Compiler = Compiler; + exports.precompile = precompile; + exports.compile = compile; + // istanbul ignore next + function _interopRequireDefault$45(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + var _exception$1 = require_exception(); + var _exception2$1 = _interopRequireDefault$45(_exception$1); + var _utils$10 = require_utils$2(); + var _ast = require_ast(); + var _ast2 = _interopRequireDefault$45(_ast); + var slice$2 = [].slice; + function Compiler() {} + Compiler.prototype = { + compiler: Compiler, + equals: function equals$3(other) { + var len = this.opcodes.length; + if (other.opcodes.length !== len) return false; + for (var i$5 = 0; i$5 < len; i$5++) { + var opcode = this.opcodes[i$5], otherOpcode = other.opcodes[i$5]; + if (opcode.opcode !== otherOpcode.opcode || !argEquals(opcode.args, otherOpcode.args)) return false; + } + len = this.children.length; + for (var i$5 = 0; i$5 < len; i$5++) if (!this.children[i$5].equals(other.children[i$5])) return false; + return true; + }, + guid: 0, + compile: function compile$3(program$3, options) { + this.sourceNode = []; + this.opcodes = []; + this.children = []; + this.options = options; + this.stringParams = options.stringParams; + this.trackIds = options.trackIds; + options.blockParams = options.blockParams || []; + options.knownHelpers = _utils$10.extend(Object.create(null), { + helperMissing: true, + blockHelperMissing: true, + each: true, + "if": true, + unless: true, + "with": true, + log: true, + lookup: true + }, options.knownHelpers); + return this.accept(program$3); + }, + compileProgram: function compileProgram(program$3) { + var childCompiler = new this.compiler(), result$1 = childCompiler.compile(program$3, this.options), guid = this.guid++; + this.usePartial = this.usePartial || result$1.usePartial; + this.children[guid] = result$1; + this.useDepths = this.useDepths || result$1.useDepths; + return guid; + }, + accept: function accept(node) { + /* istanbul ignore next: Sanity code */ + if (!this[node.type]) throw new _exception2$1["default"]("Unknown type: " + node.type, node); + this.sourceNode.unshift(node); + var ret = this[node.type](node); + this.sourceNode.shift(); + return ret; + }, + Program: function Program$1(program$3) { + this.options.blockParams.unshift(program$3.blockParams); + var body = program$3.body, bodyLength = body.length; + for (var i$5 = 0; i$5 < bodyLength; i$5++) this.accept(body[i$5]); + this.options.blockParams.shift(); + this.isSimple = bodyLength === 1; + this.blockParams = program$3.blockParams ? program$3.blockParams.length : 0; + return this; + }, + BlockStatement: function BlockStatement$1(block) { + transformLiteralToPath(block); + var program$3 = block.program, inverse = block.inverse; + program$3 = program$3 && this.compileProgram(program$3); + inverse = inverse && this.compileProgram(inverse); + var type = this.classifySexpr(block); + if (type === "helper") this.helperSexpr(block, program$3, inverse); + else if (type === "simple") { + this.simpleSexpr(block); + this.opcode("pushProgram", program$3); + this.opcode("pushProgram", inverse); + this.opcode("emptyHash"); + this.opcode("blockValue", block.path.original); + } else { + this.ambiguousSexpr(block, program$3, inverse); + this.opcode("pushProgram", program$3); + this.opcode("pushProgram", inverse); + this.opcode("emptyHash"); + this.opcode("ambiguousBlockValue"); + } + this.opcode("append"); + }, + DecoratorBlock: function DecoratorBlock(decorator$1) { + var program$3 = decorator$1.program && this.compileProgram(decorator$1.program); + var params = this.setupFullMustacheParams(decorator$1, program$3, void 0), path$28 = decorator$1.path; + this.useDecorators = true; + this.opcode("registerDecorator", params.length, path$28.original); + }, + PartialStatement: function PartialStatement(partial$1) { + this.usePartial = true; + var program$3 = partial$1.program; + if (program$3) program$3 = this.compileProgram(partial$1.program); + var params = partial$1.params; + if (params.length > 1) throw new _exception2$1["default"]("Unsupported number of partial arguments: " + params.length, partial$1); + else if (!params.length) if (this.options.explicitPartialContext) this.opcode("pushLiteral", "undefined"); + else params.push({ + type: "PathExpression", + parts: [], + depth: 0 + }); + var partialName = partial$1.name.original, isDynamic = partial$1.name.type === "SubExpression"; + if (isDynamic) this.accept(partial$1.name); + this.setupFullMustacheParams(partial$1, program$3, void 0, true); + var indent = partial$1.indent || ""; + if (this.options.preventIndent && indent) { + this.opcode("appendContent", indent); + indent = ""; + } + this.opcode("invokePartial", isDynamic, partialName, indent); + this.opcode("append"); + }, + PartialBlockStatement: function PartialBlockStatement(partialBlock) { + this.PartialStatement(partialBlock); + }, + MustacheStatement: function MustacheStatement(mustache) { + this.SubExpression(mustache); + if (mustache.escaped && !this.options.noEscape) this.opcode("appendEscaped"); + else this.opcode("append"); + }, + Decorator: function Decorator$1(decorator$1) { + this.DecoratorBlock(decorator$1); + }, + ContentStatement: function ContentStatement(content) { + if (content.value) this.opcode("appendContent", content.value); + }, + CommentStatement: function CommentStatement() {}, + SubExpression: function SubExpression(sexpr) { + transformLiteralToPath(sexpr); + var type = this.classifySexpr(sexpr); + if (type === "simple") this.simpleSexpr(sexpr); + else if (type === "helper") this.helperSexpr(sexpr); + else this.ambiguousSexpr(sexpr); + }, + ambiguousSexpr: function ambiguousSexpr(sexpr, program$3, inverse) { + var path$28 = sexpr.path, name = path$28.parts[0], isBlock$1 = program$3 != null || inverse != null; + this.opcode("getContext", path$28.depth); + this.opcode("pushProgram", program$3); + this.opcode("pushProgram", inverse); + path$28.strict = true; + this.accept(path$28); + this.opcode("invokeAmbiguous", name, isBlock$1); + }, + simpleSexpr: function simpleSexpr(sexpr) { + var path$28 = sexpr.path; + path$28.strict = true; + this.accept(path$28); + this.opcode("resolvePossibleLambda"); + }, + helperSexpr: function helperSexpr(sexpr, program$3, inverse) { + var params = this.setupFullMustacheParams(sexpr, program$3, inverse), path$28 = sexpr.path, name = path$28.parts[0]; + if (this.options.knownHelpers[name]) this.opcode("invokeKnownHelper", params.length, name); + else if (this.options.knownHelpersOnly) throw new _exception2$1["default"]("You specified knownHelpersOnly, but used the unknown helper " + name, sexpr); + else { + path$28.strict = true; + path$28.falsy = true; + this.accept(path$28); + this.opcode("invokeHelper", params.length, path$28.original, _ast2["default"].helpers.simpleId(path$28)); + } + }, + PathExpression: function PathExpression(path$28) { + this.addDepth(path$28.depth); + this.opcode("getContext", path$28.depth); + var name = path$28.parts[0], scoped = _ast2["default"].helpers.scopedId(path$28), blockParamId = !path$28.depth && !scoped && this.blockParamIndex(name); + if (blockParamId) this.opcode("lookupBlockParam", blockParamId, path$28.parts); + else if (!name) this.opcode("pushContext"); + else if (path$28.data) { + this.options.data = true; + this.opcode("lookupData", path$28.depth, path$28.parts, path$28.strict); + } else this.opcode("lookupOnContext", path$28.parts, path$28.falsy, path$28.strict, scoped); + }, + StringLiteral: function StringLiteral$2(string$3) { + this.opcode("pushString", string$3.value); + }, + NumberLiteral: function NumberLiteral$1(number) { + this.opcode("pushLiteral", number.value); + }, + BooleanLiteral: function BooleanLiteral$2(bool$1) { + this.opcode("pushLiteral", bool$1.value); + }, + UndefinedLiteral: function UndefinedLiteral() { + this.opcode("pushLiteral", "undefined"); + }, + NullLiteral: function NullLiteral$2() { + this.opcode("pushLiteral", "null"); + }, + Hash: function Hash(hash$2) { + var pairs$1 = hash$2.pairs, i$5 = 0, l$1 = pairs$1.length; + this.opcode("pushHash"); + for (; i$5 < l$1; i$5++) this.pushParam(pairs$1[i$5].value); + while (i$5--) this.opcode("assignToHash", pairs$1[i$5].key); + this.opcode("popHash"); + }, + opcode: function opcode(name) { + this.opcodes.push({ + opcode: name, + args: slice$2.call(arguments, 1), + loc: this.sourceNode[0].loc + }); + }, + addDepth: function addDepth(depth$1) { + if (!depth$1) return; + this.useDepths = true; + }, + classifySexpr: function classifySexpr(sexpr) { + var isSimple = _ast2["default"].helpers.simpleId(sexpr.path); + var isBlockParam = isSimple && !!this.blockParamIndex(sexpr.path.parts[0]); + var isHelper$1 = !isBlockParam && _ast2["default"].helpers.helperExpression(sexpr); + var isEligible = !isBlockParam && (isHelper$1 || isSimple); + if (isEligible && !isHelper$1) { + var _name = sexpr.path.parts[0], options = this.options; + if (options.knownHelpers[_name]) isHelper$1 = true; + else if (options.knownHelpersOnly) isEligible = false; + } + if (isHelper$1) return "helper"; + else if (isEligible) return "ambiguous"; + else return "simple"; + }, + pushParams: function pushParams(params) { + for (var i$5 = 0, l$1 = params.length; i$5 < l$1; i$5++) this.pushParam(params[i$5]); + }, + pushParam: function pushParam(val) { + var value = val.value != null ? val.value : val.original || ""; + if (this.stringParams) { + if (value.replace) value = value.replace(/^(\.?\.\/)*/g, "").replace(/\//g, "."); + if (val.depth) this.addDepth(val.depth); + this.opcode("getContext", val.depth || 0); + this.opcode("pushStringParam", value, val.type); + if (val.type === "SubExpression") this.accept(val); + } else { + if (this.trackIds) { + var blockParamIndex = void 0; + if (val.parts && !_ast2["default"].helpers.scopedId(val) && !val.depth) blockParamIndex = this.blockParamIndex(val.parts[0]); + if (blockParamIndex) { + var blockParamChild = val.parts.slice(1).join("."); + this.opcode("pushId", "BlockParam", blockParamIndex, blockParamChild); + } else { + value = val.original || value; + if (value.replace) value = value.replace(/^this(?:\.|$)/, "").replace(/^\.\//, "").replace(/^\.$/, ""); + this.opcode("pushId", val.type, value); + } + } + this.accept(val); + } + }, + setupFullMustacheParams: function setupFullMustacheParams(sexpr, program$3, inverse, omitEmpty) { + var params = sexpr.params; + this.pushParams(params); + this.opcode("pushProgram", program$3); + this.opcode("pushProgram", inverse); + if (sexpr.hash) this.accept(sexpr.hash); + else this.opcode("emptyHash", omitEmpty); + return params; + }, + blockParamIndex: function blockParamIndex(name) { + for (var depth$1 = 0, len = this.options.blockParams.length; depth$1 < len; depth$1++) { + var blockParams$1 = this.options.blockParams[depth$1], param = blockParams$1 && _utils$10.indexOf(blockParams$1, name); + if (blockParams$1 && param >= 0) return [depth$1, param]; + } + } + }; + function precompile(input, options, env) { + if (input == null || typeof input !== "string" && input.type !== "Program") throw new _exception2$1["default"]("You must pass a string or Handlebars AST to Handlebars.precompile. You passed " + input); + options = options || {}; + if (!("data" in options)) options.data = true; + if (options.compat) options.useDepths = true; + var ast = env.parse(input, options), environment = new env.Compiler().compile(ast, options); + return new env.JavaScriptCompiler().compile(environment, options); + } + function compile(input, options, env) { + if (options === void 0) options = {}; + if (input == null || typeof input !== "string" && input.type !== "Program") throw new _exception2$1["default"]("You must pass a string or Handlebars AST to Handlebars.compile. You passed " + input); + options = _utils$10.extend({}, options); + if (!("data" in options)) options.data = true; + if (options.compat) options.useDepths = true; + var compiled = void 0; + function compileInput() { + var ast = env.parse(input, options), environment = new env.Compiler().compile(ast, options), templateSpec = new env.JavaScriptCompiler().compile(environment, options, void 0, true); + return env.template(templateSpec); + } + function ret(context, execOptions) { + if (!compiled) compiled = compileInput(); + return compiled.call(this, context, execOptions); + } + ret._setup = function(setupOptions) { + if (!compiled) compiled = compileInput(); + return compiled._setup(setupOptions); + }; + ret._child = function(i$5, data$2, blockParams$1, depths) { + if (!compiled) compiled = compileInput(); + return compiled._child(i$5, data$2, blockParams$1, depths); + }; + return ret; + } + function argEquals(a, b$1) { + if (a === b$1) return true; + if (_utils$10.isArray(a) && _utils$10.isArray(b$1) && a.length === b$1.length) { + for (var i$5 = 0; i$5 < a.length; i$5++) if (!argEquals(a[i$5], b$1[i$5])) return false; + return true; + } + } + function transformLiteralToPath(sexpr) { + if (!sexpr.path.parts) { + var literal = sexpr.path; + sexpr.path = { + type: "PathExpression", + data: false, + depth: 0, + parts: [literal.original + ""], + original: literal.original + "", + loc: literal.loc + }; + } + } +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/compiler/code-gen.js +var require_code_gen = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/compiler/code-gen.js"(exports, module) { + exports.__esModule = true; + var _utils$9 = require_utils$2(); + var SourceNode = void 0; + try { + /* istanbul ignore next */ + if (typeof define !== "function" || !define.amd) { + var SourceMap$1 = require_source_map$1(); + SourceNode = SourceMap$1.SourceNode; + } + } catch (err) {} + /* istanbul ignore if: tested but not covered in istanbul due to dist build */ + if (!SourceNode) { + SourceNode = function(line, column, srcFile, chunks) { + this.src = ""; + if (chunks) this.add(chunks); + }; + /* istanbul ignore next */ + SourceNode.prototype = { + add: function add(chunks) { + if (_utils$9.isArray(chunks)) chunks = chunks.join(""); + this.src += chunks; + }, + prepend: function prepend$1(chunks) { + if (_utils$9.isArray(chunks)) chunks = chunks.join(""); + this.src = chunks + this.src; + }, + toStringWithSourceMap: function toStringWithSourceMap() { + return { code: this.toString() }; + }, + toString: function toString$6() { + return this.src; + } + }; + } + function castChunk(chunk$1, codeGen, loc) { + if (_utils$9.isArray(chunk$1)) { + var ret = []; + for (var i$5 = 0, len = chunk$1.length; i$5 < len; i$5++) ret.push(codeGen.wrap(chunk$1[i$5], loc)); + return ret; + } else if (typeof chunk$1 === "boolean" || typeof chunk$1 === "number") return chunk$1 + ""; + return chunk$1; + } + function CodeGen(srcFile) { + this.srcFile = srcFile; + this.source = []; + } + CodeGen.prototype = { + isEmpty: function isEmpty$2() { + return !this.source.length; + }, + prepend: function prepend$1(source, loc) { + this.source.unshift(this.wrap(source, loc)); + }, + push: function push$2(source, loc) { + this.source.push(this.wrap(source, loc)); + }, + merge: function merge$5() { + var source = this.empty(); + this.each(function(line) { + source.add([ + " ", + line, + "\n" + ]); + }); + return source; + }, + each: function each$1(iter) { + for (var i$5 = 0, len = this.source.length; i$5 < len; i$5++) iter(this.source[i$5]); + }, + empty: function empty() { + var loc = this.currentLocation || { start: {} }; + return new SourceNode(loc.start.line, loc.start.column, this.srcFile); + }, + wrap: function wrap$1(chunk$1) { + var loc = arguments.length <= 1 || arguments[1] === void 0 ? this.currentLocation || { start: {} } : arguments[1]; + if (chunk$1 instanceof SourceNode) return chunk$1; + chunk$1 = castChunk(chunk$1, this, loc); + return new SourceNode(loc.start.line, loc.start.column, this.srcFile, chunk$1); + }, + functionCall: function functionCall(fn, type, params) { + params = this.generateList(params); + return this.wrap([ + fn, + type ? "." + type + "(" : "(", + params, + ")" + ]); + }, + quotedString: function quotedString(str$3) { + return "\"" + (str$3 + "").replace(/\\/g, "\\\\").replace(/"/g, "\\\"").replace(/\n/g, "\\n").replace(/\r/g, "\\r").replace(/\u2028/g, "\\u2028").replace(/\u2029/g, "\\u2029") + "\""; + }, + objectLiteral: function objectLiteral(obj) { + // istanbul ignore next + var _this = this; + var pairs$1 = []; + Object.keys(obj).forEach(function(key) { + var value = castChunk(obj[key], _this); + if (value !== "undefined") pairs$1.push([ + _this.quotedString(key), + ":", + value + ]); + }); + var ret = this.generateList(pairs$1); + ret.prepend("{"); + ret.add("}"); + return ret; + }, + generateList: function generateList(entries) { + var ret = this.empty(); + for (var i$5 = 0, len = entries.length; i$5 < len; i$5++) { + if (i$5) ret.add(","); + ret.add(castChunk(entries[i$5], this)); + } + return ret; + }, + generateArray: function generateArray(entries) { + var ret = this.generateList(entries); + ret.prepend("["); + ret.add("]"); + return ret; + } + }; + exports["default"] = CodeGen; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars/compiler/javascript-compiler.js +var require_javascript_compiler = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars/compiler/javascript-compiler.js"(exports, module) { + exports.__esModule = true; + // istanbul ignore next + function _interopRequireDefault$44(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + var _base$1 = require_base$2(); + var _exception = require_exception(); + var _exception2 = _interopRequireDefault$44(_exception); + var _utils$8 = require_utils$2(); + var _codeGen = require_code_gen(); + var _codeGen2 = _interopRequireDefault$44(_codeGen); + function Literal(value) { + this.value = value; + } + function JavaScriptCompiler() {} + JavaScriptCompiler.prototype = { + nameLookup: function nameLookup(parent, name) { + return this.internalNameLookup(parent, name); + }, + depthedLookup: function depthedLookup(name) { + return [ + this.aliasable("container.lookup"), + "(depths, ", + JSON.stringify(name), + ")" + ]; + }, + compilerInfo: function compilerInfo() { + var revision = _base$1.COMPILER_REVISION, versions = _base$1.REVISION_CHANGES[revision]; + return [revision, versions]; + }, + appendToBuffer: function appendToBuffer(source, location, explicit) { + if (!_utils$8.isArray(source)) source = [source]; + source = this.source.wrap(source, location); + if (this.environment.isSimple) return [ + "return ", + source, + ";" + ]; + else if (explicit) return [ + "buffer += ", + source, + ";" + ]; + else { + source.appendToBuffer = true; + return source; + } + }, + initializeBuffer: function initializeBuffer() { + return this.quotedString(""); + }, + internalNameLookup: function internalNameLookup(parent, name) { + this.lookupPropertyFunctionIsUsed = true; + return [ + "lookupProperty(", + parent, + ",", + JSON.stringify(name), + ")" + ]; + }, + lookupPropertyFunctionIsUsed: false, + compile: function compile$3(environment, options, context, asObject) { + this.environment = environment; + this.options = options; + this.stringParams = this.options.stringParams; + this.trackIds = this.options.trackIds; + this.precompile = !asObject; + this.name = this.environment.name; + this.isChild = !!context; + this.context = context || { + decorators: [], + programs: [], + environments: [] + }; + this.preamble(); + this.stackSlot = 0; + this.stackVars = []; + this.aliases = {}; + this.registers = { list: [] }; + this.hashes = []; + this.compileStack = []; + this.inlineStack = []; + this.blockParams = []; + this.compileChildren(environment, options); + this.useDepths = this.useDepths || environment.useDepths || environment.useDecorators || this.options.compat; + this.useBlockParams = this.useBlockParams || environment.useBlockParams; + var opcodes = environment.opcodes, opcode = void 0, firstLoc = void 0, i$5 = void 0, l$1 = void 0; + for (i$5 = 0, l$1 = opcodes.length; i$5 < l$1; i$5++) { + opcode = opcodes[i$5]; + this.source.currentLocation = opcode.loc; + firstLoc = firstLoc || opcode.loc; + this[opcode.opcode].apply(this, opcode.args); + } + this.source.currentLocation = firstLoc; + this.pushSource(""); + /* istanbul ignore next */ + if (this.stackSlot || this.inlineStack.length || this.compileStack.length) throw new _exception2["default"]("Compile completed with content left on stack"); + if (!this.decorators.isEmpty()) { + this.useDecorators = true; + this.decorators.prepend([ + "var decorators = container.decorators, ", + this.lookupPropertyFunctionVarDeclaration(), + ";\n" + ]); + this.decorators.push("return fn;"); + if (asObject) this.decorators = Function.apply(this, [ + "fn", + "props", + "container", + "depth0", + "data", + "blockParams", + "depths", + this.decorators.merge() + ]); + else { + this.decorators.prepend("function(fn, props, container, depth0, data, blockParams, depths) {\n"); + this.decorators.push("}\n"); + this.decorators = this.decorators.merge(); + } + } else this.decorators = void 0; + var fn = this.createFunctionContext(asObject); + if (!this.isChild) { + var ret = { + compiler: this.compilerInfo(), + main: fn + }; + if (this.decorators) { + ret.main_d = this.decorators; + ret.useDecorators = true; + } + var _context$9 = this.context; + var programs = _context$9.programs; + var decorators = _context$9.decorators; + for (i$5 = 0, l$1 = programs.length; i$5 < l$1; i$5++) if (programs[i$5]) { + ret[i$5] = programs[i$5]; + if (decorators[i$5]) { + ret[i$5 + "_d"] = decorators[i$5]; + ret.useDecorators = true; + } + } + if (this.environment.usePartial) ret.usePartial = true; + if (this.options.data) ret.useData = true; + if (this.useDepths) ret.useDepths = true; + if (this.useBlockParams) ret.useBlockParams = true; + if (this.options.compat) ret.compat = true; + if (!asObject) { + ret.compiler = JSON.stringify(ret.compiler); + this.source.currentLocation = { start: { + line: 1, + column: 0 + } }; + ret = this.objectLiteral(ret); + if (options.srcName) { + ret = ret.toStringWithSourceMap({ file: options.destName }); + ret.map = ret.map && ret.map.toString(); + } else ret = ret.toString(); + } else ret.compilerOptions = this.options; + return ret; + } else return fn; + }, + preamble: function preamble() { + this.lastContext = 0; + this.source = new _codeGen2["default"](this.options.srcName); + this.decorators = new _codeGen2["default"](this.options.srcName); + }, + createFunctionContext: function createFunctionContext(asObject) { + // istanbul ignore next + var _this = this; + var varDeclarations = ""; + var locals = this.stackVars.concat(this.registers.list); + if (locals.length > 0) varDeclarations += ", " + locals.join(", "); + var aliasCount = 0; + Object.keys(this.aliases).forEach(function(alias) { + var node = _this.aliases[alias]; + if (node.children && node.referenceCount > 1) { + varDeclarations += ", alias" + ++aliasCount + "=" + alias; + node.children[0] = "alias" + aliasCount; + } + }); + if (this.lookupPropertyFunctionIsUsed) varDeclarations += ", " + this.lookupPropertyFunctionVarDeclaration(); + var params = [ + "container", + "depth0", + "helpers", + "partials", + "data" + ]; + if (this.useBlockParams || this.useDepths) params.push("blockParams"); + if (this.useDepths) params.push("depths"); + var source = this.mergeSource(varDeclarations); + if (asObject) { + params.push(source); + return Function.apply(this, params); + } else return this.source.wrap([ + "function(", + params.join(","), + ") {\n ", + source, + "}" + ]); + }, + mergeSource: function mergeSource(varDeclarations) { + var isSimple = this.environment.isSimple, appendOnly = !this.forceBuffer, appendFirst = void 0, sourceSeen = void 0, bufferStart = void 0, bufferEnd = void 0; + this.source.each(function(line) { + if (line.appendToBuffer) { + if (bufferStart) line.prepend(" + "); + else bufferStart = line; + bufferEnd = line; + } else { + if (bufferStart) { + if (!sourceSeen) appendFirst = true; + else bufferStart.prepend("buffer += "); + bufferEnd.add(";"); + bufferStart = bufferEnd = void 0; + } + sourceSeen = true; + if (!isSimple) appendOnly = false; + } + }); + if (appendOnly) { + if (bufferStart) { + bufferStart.prepend("return "); + bufferEnd.add(";"); + } else if (!sourceSeen) this.source.push("return \"\";"); + } else { + varDeclarations += ", buffer = " + (appendFirst ? "" : this.initializeBuffer()); + if (bufferStart) { + bufferStart.prepend("return buffer + "); + bufferEnd.add(";"); + } else this.source.push("return buffer;"); + } + if (varDeclarations) this.source.prepend("var " + varDeclarations.substring(2) + (appendFirst ? "" : ";\n")); + return this.source.merge(); + }, + lookupPropertyFunctionVarDeclaration: function lookupPropertyFunctionVarDeclaration() { + return "\n lookupProperty = container.lookupProperty || function(parent, propertyName) {\n if (Object.prototype.hasOwnProperty.call(parent, propertyName)) {\n return parent[propertyName];\n }\n return undefined\n }\n ".trim(); + }, + blockValue: function blockValue(name) { + var blockHelperMissing = this.aliasable("container.hooks.blockHelperMissing"), params = [this.contextName(0)]; + this.setupHelperArgs(name, 0, params); + var blockName = this.popStack(); + params.splice(1, 0, blockName); + this.push(this.source.functionCall(blockHelperMissing, "call", params)); + }, + ambiguousBlockValue: function ambiguousBlockValue() { + var blockHelperMissing = this.aliasable("container.hooks.blockHelperMissing"), params = [this.contextName(0)]; + this.setupHelperArgs("", 0, params, true); + this.flushInline(); + var current = this.topStack(); + params.splice(1, 0, current); + this.pushSource([ + "if (!", + this.lastHelper, + ") { ", + current, + " = ", + this.source.functionCall(blockHelperMissing, "call", params), + "}" + ]); + }, + appendContent: function appendContent(content) { + if (this.pendingContent) content = this.pendingContent + content; + else this.pendingLocation = this.source.currentLocation; + this.pendingContent = content; + }, + append: function append$1() { + if (this.isInline()) { + this.replaceStack(function(current) { + return [ + " != null ? ", + current, + " : \"\"" + ]; + }); + this.pushSource(this.appendToBuffer(this.popStack())); + } else { + var local = this.popStack(); + this.pushSource([ + "if (", + local, + " != null) { ", + this.appendToBuffer(local, void 0, true), + " }" + ]); + if (this.environment.isSimple) this.pushSource([ + "else { ", + this.appendToBuffer("''", void 0, true), + " }" + ]); + } + }, + appendEscaped: function appendEscaped() { + this.pushSource(this.appendToBuffer([ + this.aliasable("container.escapeExpression"), + "(", + this.popStack(), + ")" + ])); + }, + getContext: function getContext(depth$1) { + this.lastContext = depth$1; + }, + pushContext: function pushContext$1() { + this.pushStackLiteral(this.contextName(this.lastContext)); + }, + lookupOnContext: function lookupOnContext(parts, falsy, strict, scoped) { + var i$5 = 0; + if (!scoped && this.options.compat && !this.lastContext) this.push(this.depthedLookup(parts[i$5++])); + else this.pushContext(); + this.resolvePath("context", parts, i$5, falsy, strict); + }, + lookupBlockParam: function lookupBlockParam(blockParamId, parts) { + this.useBlockParams = true; + this.push([ + "blockParams[", + blockParamId[0], + "][", + blockParamId[1], + "]" + ]); + this.resolvePath("context", parts, 1); + }, + lookupData: function lookupData(depth$1, parts, strict) { + if (!depth$1) this.pushStackLiteral("data"); + else this.pushStackLiteral("container.data(data, " + depth$1 + ")"); + this.resolvePath("data", parts, 0, true, strict); + }, + resolvePath: function resolvePath(type, parts, i$5, falsy, strict) { + // istanbul ignore next + var _this2 = this; + if (this.options.strict || this.options.assumeObjects) { + this.push(strictLookup(this.options.strict && strict, this, parts, i$5, type)); + return; + } + var len = parts.length; + for (; i$5 < len; i$5++) this.replaceStack(function(current) { + var lookup = _this2.nameLookup(current, parts[i$5], type); + if (!falsy) return [ + " != null ? ", + lookup, + " : ", + current + ]; + else return [" && ", lookup]; + }); + }, + resolvePossibleLambda: function resolvePossibleLambda() { + this.push([ + this.aliasable("container.lambda"), + "(", + this.popStack(), + ", ", + this.contextName(0), + ")" + ]); + }, + pushStringParam: function pushStringParam(string$3, type) { + this.pushContext(); + this.pushString(type); + if (type !== "SubExpression") if (typeof string$3 === "string") this.pushString(string$3); + else this.pushStackLiteral(string$3); + }, + emptyHash: function emptyHash(omitEmpty) { + if (this.trackIds) this.push("{}"); + if (this.stringParams) { + this.push("{}"); + this.push("{}"); + } + this.pushStackLiteral(omitEmpty ? "undefined" : "{}"); + }, + pushHash: function pushHash() { + if (this.hash) this.hashes.push(this.hash); + this.hash = { + values: {}, + types: [], + contexts: [], + ids: [] + }; + }, + popHash: function popHash() { + var hash$2 = this.hash; + this.hash = this.hashes.pop(); + if (this.trackIds) this.push(this.objectLiteral(hash$2.ids)); + if (this.stringParams) { + this.push(this.objectLiteral(hash$2.contexts)); + this.push(this.objectLiteral(hash$2.types)); + } + this.push(this.objectLiteral(hash$2.values)); + }, + pushString: function pushString(string$3) { + this.pushStackLiteral(this.quotedString(string$3)); + }, + pushLiteral: function pushLiteral(value) { + this.pushStackLiteral(value); + }, + pushProgram: function pushProgram(guid) { + if (guid != null) this.pushStackLiteral(this.programExpression(guid)); + else this.pushStackLiteral(null); + }, + registerDecorator: function registerDecorator(paramSize, name) { + var foundDecorator = this.nameLookup("decorators", name, "decorator"), options = this.setupHelperArgs(name, paramSize); + this.decorators.push([ + "fn = ", + this.decorators.functionCall(foundDecorator, "", [ + "fn", + "props", + "container", + options + ]), + " || fn;" + ]); + }, + invokeHelper: function invokeHelper(paramSize, name, isSimple) { + var nonHelper = this.popStack(), helper = this.setupHelper(paramSize, name); + var possibleFunctionCalls = []; + if (isSimple) possibleFunctionCalls.push(helper.name); + possibleFunctionCalls.push(nonHelper); + if (!this.options.strict) possibleFunctionCalls.push(this.aliasable("container.hooks.helperMissing")); + var functionLookupCode = [ + "(", + this.itemsSeparatedBy(possibleFunctionCalls, "||"), + ")" + ]; + var functionCall = this.source.functionCall(functionLookupCode, "call", helper.callParams); + this.push(functionCall); + }, + itemsSeparatedBy: function itemsSeparatedBy(items, separator) { + var result$1 = []; + result$1.push(items[0]); + for (var i$5 = 1; i$5 < items.length; i$5++) result$1.push(separator, items[i$5]); + return result$1; + }, + invokeKnownHelper: function invokeKnownHelper(paramSize, name) { + var helper = this.setupHelper(paramSize, name); + this.push(this.source.functionCall(helper.name, "call", helper.callParams)); + }, + invokeAmbiguous: function invokeAmbiguous(name, helperCall) { + this.useRegister("helper"); + var nonHelper = this.popStack(); + this.emptyHash(); + var helper = this.setupHelper(0, name, helperCall); + var helperName = this.lastHelper = this.nameLookup("helpers", name, "helper"); + var lookup = [ + "(", + "(helper = ", + helperName, + " || ", + nonHelper, + ")" + ]; + if (!this.options.strict) { + lookup[0] = "(helper = "; + lookup.push(" != null ? helper : ", this.aliasable("container.hooks.helperMissing")); + } + this.push([ + "(", + lookup, + helper.paramsInit ? ["),(", helper.paramsInit] : [], + "),", + "(typeof helper === ", + this.aliasable("\"function\""), + " ? ", + this.source.functionCall("helper", "call", helper.callParams), + " : helper))" + ]); + }, + invokePartial: function invokePartial$1(isDynamic, name, indent) { + var params = [], options = this.setupParams(name, 1, params); + if (isDynamic) { + name = this.popStack(); + delete options.name; + } + if (indent) options.indent = JSON.stringify(indent); + options.helpers = "helpers"; + options.partials = "partials"; + options.decorators = "container.decorators"; + if (!isDynamic) params.unshift(this.nameLookup("partials", name, "partial")); + else params.unshift(name); + if (this.options.compat) options.depths = "depths"; + options = this.objectLiteral(options); + params.push(options); + this.push(this.source.functionCall("container.invokePartial", "", params)); + }, + assignToHash: function assignToHash(key) { + var value = this.popStack(), context = void 0, type = void 0, id$4 = void 0; + if (this.trackIds) id$4 = this.popStack(); + if (this.stringParams) { + type = this.popStack(); + context = this.popStack(); + } + var hash$2 = this.hash; + if (context) hash$2.contexts[key] = context; + if (type) hash$2.types[key] = type; + if (id$4) hash$2.ids[key] = id$4; + hash$2.values[key] = value; + }, + pushId: function pushId(type, name, child) { + if (type === "BlockParam") this.pushStackLiteral("blockParams[" + name[0] + "].path[" + name[1] + "]" + (child ? " + " + JSON.stringify("." + child) : "")); + else if (type === "PathExpression") this.pushString(name); + else if (type === "SubExpression") this.pushStackLiteral("true"); + else this.pushStackLiteral("null"); + }, + compiler: JavaScriptCompiler, + compileChildren: function compileChildren(environment, options) { + var children = environment.children, child = void 0, compiler = void 0; + for (var i$5 = 0, l$1 = children.length; i$5 < l$1; i$5++) { + child = children[i$5]; + compiler = new this.compiler(); + var existing = this.matchExistingProgram(child); + if (existing == null) { + this.context.programs.push(""); + var index$1 = this.context.programs.length; + child.index = index$1; + child.name = "program" + index$1; + this.context.programs[index$1] = compiler.compile(child, options, this.context, !this.precompile); + this.context.decorators[index$1] = compiler.decorators; + this.context.environments[index$1] = child; + this.useDepths = this.useDepths || compiler.useDepths; + this.useBlockParams = this.useBlockParams || compiler.useBlockParams; + child.useDepths = this.useDepths; + child.useBlockParams = this.useBlockParams; + } else { + child.index = existing.index; + child.name = "program" + existing.index; + this.useDepths = this.useDepths || existing.useDepths; + this.useBlockParams = this.useBlockParams || existing.useBlockParams; + } + } + }, + matchExistingProgram: function matchExistingProgram(child) { + for (var i$5 = 0, len = this.context.environments.length; i$5 < len; i$5++) { + var environment = this.context.environments[i$5]; + if (environment && environment.equals(child)) return environment; + } + }, + programExpression: function programExpression(guid) { + var child = this.environment.children[guid], programParams = [ + child.index, + "data", + child.blockParams + ]; + if (this.useBlockParams || this.useDepths) programParams.push("blockParams"); + if (this.useDepths) programParams.push("depths"); + return "container.program(" + programParams.join(", ") + ")"; + }, + useRegister: function useRegister(name) { + if (!this.registers[name]) { + this.registers[name] = true; + this.registers.list.push(name); + } + }, + push: function push$2(expr) { + if (!(expr instanceof Literal)) expr = this.source.wrap(expr); + this.inlineStack.push(expr); + return expr; + }, + pushStackLiteral: function pushStackLiteral(item) { + this.push(new Literal(item)); + }, + pushSource: function pushSource(source) { + if (this.pendingContent) { + this.source.push(this.appendToBuffer(this.source.quotedString(this.pendingContent), this.pendingLocation)); + this.pendingContent = void 0; + } + if (source) this.source.push(source); + }, + replaceStack: function replaceStack(callback) { + var prefix$1 = ["("], stack = void 0, createdStack = void 0, usedLiteral = void 0; + /* istanbul ignore next */ + if (!this.isInline()) throw new _exception2["default"]("replaceStack on non-inline"); + var top = this.popStack(true); + if (top instanceof Literal) { + stack = [top.value]; + prefix$1 = ["(", stack]; + usedLiteral = true; + } else { + createdStack = true; + var _name = this.incrStack(); + prefix$1 = [ + "((", + this.push(_name), + " = ", + top, + ")" + ]; + stack = this.topStack(); + } + var item = callback.call(this, stack); + if (!usedLiteral) this.popStack(); + if (createdStack) this.stackSlot--; + this.push(prefix$1.concat(item, ")")); + }, + incrStack: function incrStack() { + this.stackSlot++; + if (this.stackSlot > this.stackVars.length) this.stackVars.push("stack" + this.stackSlot); + return this.topStackName(); + }, + topStackName: function topStackName() { + return "stack" + this.stackSlot; + }, + flushInline: function flushInline() { + var inlineStack = this.inlineStack; + this.inlineStack = []; + for (var i$5 = 0, len = inlineStack.length; i$5 < len; i$5++) { + var entry = inlineStack[i$5]; + /* istanbul ignore if */ + if (entry instanceof Literal) this.compileStack.push(entry); + else { + var stack = this.incrStack(); + this.pushSource([ + stack, + " = ", + entry, + ";" + ]); + this.compileStack.push(stack); + } + } + }, + isInline: function isInline() { + return this.inlineStack.length; + }, + popStack: function popStack(wrapped) { + var inline = this.isInline(), item = (inline ? this.inlineStack : this.compileStack).pop(); + if (!wrapped && item instanceof Literal) return item.value; + else { + if (!inline) { + /* istanbul ignore next */ + if (!this.stackSlot) throw new _exception2["default"]("Invalid stack pop"); + this.stackSlot--; + } + return item; + } + }, + topStack: function topStack() { + var stack = this.isInline() ? this.inlineStack : this.compileStack, item = stack[stack.length - 1]; + /* istanbul ignore if */ + if (item instanceof Literal) return item.value; + else return item; + }, + contextName: function contextName(context) { + if (this.useDepths && context) return "depths[" + context + "]"; + else return "depth" + context; + }, + quotedString: function quotedString(str$3) { + return this.source.quotedString(str$3); + }, + objectLiteral: function objectLiteral(obj) { + return this.source.objectLiteral(obj); + }, + aliasable: function aliasable(name) { + var ret = this.aliases[name]; + if (ret) { + ret.referenceCount++; + return ret; + } + ret = this.aliases[name] = this.source.wrap(name); + ret.aliasable = true; + ret.referenceCount = 1; + return ret; + }, + setupHelper: function setupHelper(paramSize, name, blockHelper) { + var params = [], paramsInit = this.setupHelperArgs(name, paramSize, params, blockHelper); + var foundHelper = this.nameLookup("helpers", name, "helper"), callContext = this.aliasable(this.contextName(0) + " != null ? " + this.contextName(0) + " : (container.nullContext || {})"); + return { + params, + paramsInit, + name: foundHelper, + callParams: [callContext].concat(params) + }; + }, + setupParams: function setupParams(helper, paramSize, params) { + var options = {}, contexts = [], types$7 = [], ids = [], objectArgs = !params, param = void 0; + if (objectArgs) params = []; + options.name = this.quotedString(helper); + options.hash = this.popStack(); + if (this.trackIds) options.hashIds = this.popStack(); + if (this.stringParams) { + options.hashTypes = this.popStack(); + options.hashContexts = this.popStack(); + } + var inverse = this.popStack(), program$3 = this.popStack(); + if (program$3 || inverse) { + options.fn = program$3 || "container.noop"; + options.inverse = inverse || "container.noop"; + } + var i$5 = paramSize; + while (i$5--) { + param = this.popStack(); + params[i$5] = param; + if (this.trackIds) ids[i$5] = this.popStack(); + if (this.stringParams) { + types$7[i$5] = this.popStack(); + contexts[i$5] = this.popStack(); + } + } + if (objectArgs) options.args = this.source.generateArray(params); + if (this.trackIds) options.ids = this.source.generateArray(ids); + if (this.stringParams) { + options.types = this.source.generateArray(types$7); + options.contexts = this.source.generateArray(contexts); + } + if (this.options.data) options.data = "data"; + if (this.useBlockParams) options.blockParams = "blockParams"; + return options; + }, + setupHelperArgs: function setupHelperArgs(helper, paramSize, params, useRegister) { + var options = this.setupParams(helper, paramSize, params); + options.loc = JSON.stringify(this.source.currentLocation); + options = this.objectLiteral(options); + if (useRegister) { + this.useRegister("options"); + params.push("options"); + return ["options=", options]; + } else if (params) { + params.push(options); + return ""; + } else return options; + } + }; + (function() { + var reservedWords$3 = "break else new var case finally return void catch for switch while continue function this with default if throw delete in try do instanceof typeof abstract enum int short boolean export interface static byte extends long super char final native synchronized class float package throws const goto private transient debugger implements protected volatile double import public let yield await null true false".split(" "); + var compilerWords = JavaScriptCompiler.RESERVED_WORDS = {}; + for (var i$5 = 0, l$1 = reservedWords$3.length; i$5 < l$1; i$5++) compilerWords[reservedWords$3[i$5]] = true; + })(); + /** + * @deprecated May be removed in the next major version + */ + JavaScriptCompiler.isValidJavaScriptVariableName = function(name) { + return !JavaScriptCompiler.RESERVED_WORDS[name] && /^[a-zA-Z_$][0-9a-zA-Z_$]*$/.test(name); + }; + function strictLookup(requireTerminal, compiler, parts, i$5, type) { + var stack = compiler.popStack(), len = parts.length; + if (requireTerminal) len--; + for (; i$5 < len; i$5++) stack = compiler.nameLookup(stack, parts[i$5], type); + if (requireTerminal) return [ + compiler.aliasable("container.strict"), + "(", + stack, + ", ", + compiler.quotedString(parts[i$5]), + ", ", + JSON.stringify(compiler.source.currentLocation), + " )" + ]; + else return stack; + } + exports["default"] = JavaScriptCompiler; + module.exports = exports["default"]; +} }); + +//#endregion +//#region node_modules/handlebars/dist/cjs/handlebars.js +var require_handlebars = __commonJS({ "node_modules/handlebars/dist/cjs/handlebars.js"(exports, module) { + exports.__esModule = true; + // istanbul ignore next + function _interopRequireDefault$43(obj) { + return obj && obj.__esModule ? obj : { "default": obj }; + } + var _handlebarsRuntime = require_handlebars_runtime(); + var _handlebarsRuntime2 = _interopRequireDefault$43(_handlebarsRuntime); + var _handlebarsCompilerAst = require_ast(); + var _handlebarsCompilerAst2 = _interopRequireDefault$43(_handlebarsCompilerAst); + var _handlebarsCompilerBase = require_base$1(); + var _handlebarsCompilerCompiler = require_compiler(); + var _handlebarsCompilerJavascriptCompiler = require_javascript_compiler(); + var _handlebarsCompilerJavascriptCompiler2 = _interopRequireDefault$43(_handlebarsCompilerJavascriptCompiler); + var _handlebarsCompilerVisitor = require_visitor(); + var _handlebarsCompilerVisitor2 = _interopRequireDefault$43(_handlebarsCompilerVisitor); + var _handlebarsNoConflict = require_no_conflict(); + var _handlebarsNoConflict2 = _interopRequireDefault$43(_handlebarsNoConflict); + var _create = _handlebarsRuntime2["default"].create; + function create$4() { + var hb = _create(); + hb.compile = function(input, options) { + return _handlebarsCompilerCompiler.compile(input, options, hb); + }; + hb.precompile = function(input, options) { + return _handlebarsCompilerCompiler.precompile(input, options, hb); + }; + hb.AST = _handlebarsCompilerAst2["default"]; + hb.Compiler = _handlebarsCompilerCompiler.Compiler; + hb.JavaScriptCompiler = _handlebarsCompilerJavascriptCompiler2["default"]; + hb.Parser = _handlebarsCompilerBase.parser; + hb.parse = _handlebarsCompilerBase.parse; + hb.parseWithoutProcessing = _handlebarsCompilerBase.parseWithoutProcessing; + return hb; + } + var inst = create$4(); + inst.create = create$4; + _handlebarsNoConflict2["default"](inst); + inst.Visitor = _handlebarsCompilerVisitor2["default"]; + inst["default"] = inst; + exports["default"] = inst; + module.exports = exports["default"]; +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_setup.js +var VERSION, root$3, ArrayProto, ObjProto, SymbolProto, push, slice$1, toString$2, hasOwnProperty$3, supportsArrayBuffer, supportsDataView, nativeIsArray, nativeKeys, nativeCreate, nativeIsView, _isNaN, _isFinite, hasEnumBug, nonEnumerableProps, MAX_ARRAY_INDEX; +var init__setup = __esm({ "../../node_modules/underscore/modules/_setup.js"() { + VERSION = "1.12.1"; + root$3 = typeof self == "object" && self.self === self && self || typeof global == "object" && global.global === global && global || Function("return this")() || {}; + ArrayProto = Array.prototype; + ObjProto = Object.prototype; + SymbolProto = typeof Symbol !== "undefined" ? Symbol.prototype : null; + push = ArrayProto.push; + slice$1 = ArrayProto.slice; + toString$2 = ObjProto.toString; + hasOwnProperty$3 = ObjProto.hasOwnProperty; + supportsArrayBuffer = typeof ArrayBuffer !== "undefined"; + supportsDataView = typeof DataView !== "undefined"; + nativeIsArray = Array.isArray; + nativeKeys = Object.keys; + nativeCreate = Object.create; + nativeIsView = supportsArrayBuffer && ArrayBuffer.isView; + _isNaN = isNaN; + _isFinite = isFinite; + hasEnumBug = !{ toString: null }.propertyIsEnumerable("toString"); + nonEnumerableProps = [ + "valueOf", + "isPrototypeOf", + "toString", + "propertyIsEnumerable", + "hasOwnProperty", + "toLocaleString" + ]; + MAX_ARRAY_INDEX = Math.pow(2, 53) - 1; +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/restArguments.js +function restArguments(func, startIndex) { + startIndex = startIndex == null ? func.length - 1 : +startIndex; + return function() { + var length = Math.max(arguments.length - startIndex, 0), rest$1 = Array(length), index$1 = 0; + for (; index$1 < length; index$1++) rest$1[index$1] = arguments[index$1 + startIndex]; + switch (startIndex) { + case 0: return func.call(this, rest$1); + case 1: return func.call(this, arguments[0], rest$1); + case 2: return func.call(this, arguments[0], arguments[1], rest$1); + } + var args = Array(startIndex + 1); + for (index$1 = 0; index$1 < startIndex; index$1++) args[index$1] = arguments[index$1]; + args[startIndex] = rest$1; + return func.apply(this, args); + }; +} +var init_restArguments = __esm({ "../../node_modules/underscore/modules/restArguments.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isObject.js +function isObject$2(obj) { + var type = typeof obj; + return type === "function" || type === "object" && !!obj; +} +var init_isObject = __esm({ "../../node_modules/underscore/modules/isObject.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isNull.js +function isNull(obj) { + return obj === null; +} +var init_isNull = __esm({ "../../node_modules/underscore/modules/isNull.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isUndefined.js +function isUndefined(obj) { + return obj === void 0; +} +var init_isUndefined = __esm({ "../../node_modules/underscore/modules/isUndefined.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isBoolean.js +function isBoolean(obj) { + return obj === true || obj === false || toString$2.call(obj) === "[object Boolean]"; +} +var init_isBoolean = __esm({ "../../node_modules/underscore/modules/isBoolean.js"() { + init__setup(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isElement.js +function isElement(obj) { + return !!(obj && obj.nodeType === 1); +} +var init_isElement = __esm({ "../../node_modules/underscore/modules/isElement.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_tagTester.js +function tagTester(name) { + var tag$3 = "[object " + name + "]"; + return function(obj) { + return toString$2.call(obj) === tag$3; + }; +} +var init__tagTester = __esm({ "../../node_modules/underscore/modules/_tagTester.js"() { + init__setup(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isString.js +var isString_default; +var init_isString = __esm({ "../../node_modules/underscore/modules/isString.js"() { + init__tagTester(); + isString_default = tagTester("String"); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isNumber.js +var isNumber_default; +var init_isNumber = __esm({ "../../node_modules/underscore/modules/isNumber.js"() { + init__tagTester(); + isNumber_default = tagTester("Number"); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isDate.js +var isDate_default; +var init_isDate = __esm({ "../../node_modules/underscore/modules/isDate.js"() { + init__tagTester(); + isDate_default = tagTester("Date"); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isRegExp.js +var isRegExp_default; +var init_isRegExp = __esm({ "../../node_modules/underscore/modules/isRegExp.js"() { + init__tagTester(); + isRegExp_default = tagTester("RegExp"); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isError.js +var isError_default; +var init_isError = __esm({ "../../node_modules/underscore/modules/isError.js"() { + init__tagTester(); + isError_default = tagTester("Error"); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isSymbol.js +var isSymbol_default; +var init_isSymbol = __esm({ "../../node_modules/underscore/modules/isSymbol.js"() { + init__tagTester(); + isSymbol_default = tagTester("Symbol"); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isArrayBuffer.js +var isArrayBuffer_default; +var init_isArrayBuffer = __esm({ "../../node_modules/underscore/modules/isArrayBuffer.js"() { + init__tagTester(); + isArrayBuffer_default = tagTester("ArrayBuffer"); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isFunction.js +var isFunction$7, nodelist, isFunction_default; +var init_isFunction = __esm({ "../../node_modules/underscore/modules/isFunction.js"() { + init__tagTester(); + init__setup(); + isFunction$7 = tagTester("Function"); + nodelist = root$3.document && root$3.document.childNodes; + if (typeof /./ != "function" && typeof Int8Array != "object" && typeof nodelist != "function") isFunction$7 = function(obj) { + return typeof obj == "function" || false; + }; + isFunction_default = isFunction$7; +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_hasObjectTag.js +var _hasObjectTag_default; +var init__hasObjectTag = __esm({ "../../node_modules/underscore/modules/_hasObjectTag.js"() { + init__tagTester(); + _hasObjectTag_default = tagTester("Object"); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_stringTagBug.js +var hasStringTagBug, isIE11; +var init__stringTagBug = __esm({ "../../node_modules/underscore/modules/_stringTagBug.js"() { + init__setup(); + init__hasObjectTag(); + hasStringTagBug = supportsDataView && _hasObjectTag_default(new DataView(new ArrayBuffer(8))); + isIE11 = typeof Map !== "undefined" && _hasObjectTag_default(new Map()); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isDataView.js +function ie10IsDataView(obj) { + return obj != null && isFunction_default(obj.getInt8) && isArrayBuffer_default(obj.buffer); +} +var isDataView, isDataView_default; +var init_isDataView = __esm({ "../../node_modules/underscore/modules/isDataView.js"() { + init__tagTester(); + init_isFunction(); + init_isArrayBuffer(); + init__stringTagBug(); + isDataView = tagTester("DataView"); + isDataView_default = hasStringTagBug ? ie10IsDataView : isDataView; +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isArray.js +var isArray_default; +var init_isArray = __esm({ "../../node_modules/underscore/modules/isArray.js"() { + init__setup(); + init__tagTester(); + isArray_default = nativeIsArray || tagTester("Array"); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_has.js +function has$1(obj, key) { + return obj != null && hasOwnProperty$3.call(obj, key); +} +var init__has = __esm({ "../../node_modules/underscore/modules/_has.js"() { + init__setup(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isArguments.js +var isArguments, isArguments_default; +var init_isArguments = __esm({ "../../node_modules/underscore/modules/isArguments.js"() { + init__tagTester(); + init__has(); + isArguments = tagTester("Arguments"); + (function() { + if (!isArguments(arguments)) isArguments = function(obj) { + return has$1(obj, "callee"); + }; + })(); + isArguments_default = isArguments; +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isFinite.js +function isFinite$1(obj) { + return !isSymbol_default(obj) && _isFinite(obj) && !isNaN(parseFloat(obj)); +} +var init_isFinite = __esm({ "../../node_modules/underscore/modules/isFinite.js"() { + init__setup(); + init_isSymbol(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isNaN.js +function isNaN$1(obj) { + return isNumber_default(obj) && _isNaN(obj); +} +var init_isNaN = __esm({ "../../node_modules/underscore/modules/isNaN.js"() { + init__setup(); + init_isNumber(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/constant.js +function constant(value) { + return function() { + return value; + }; +} +var init_constant = __esm({ "../../node_modules/underscore/modules/constant.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_createSizePropertyCheck.js +function createSizePropertyCheck(getSizeProperty) { + return function(collection) { + var sizeProperty = getSizeProperty(collection); + return typeof sizeProperty == "number" && sizeProperty >= 0 && sizeProperty <= MAX_ARRAY_INDEX; + }; +} +var init__createSizePropertyCheck = __esm({ "../../node_modules/underscore/modules/_createSizePropertyCheck.js"() { + init__setup(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_shallowProperty.js +function shallowProperty(key) { + return function(obj) { + return obj == null ? void 0 : obj[key]; + }; +} +var init__shallowProperty = __esm({ "../../node_modules/underscore/modules/_shallowProperty.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_getByteLength.js +var _getByteLength_default; +var init__getByteLength = __esm({ "../../node_modules/underscore/modules/_getByteLength.js"() { + init__shallowProperty(); + _getByteLength_default = shallowProperty("byteLength"); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_isBufferLike.js +var _isBufferLike_default; +var init__isBufferLike = __esm({ "../../node_modules/underscore/modules/_isBufferLike.js"() { + init__createSizePropertyCheck(); + init__getByteLength(); + _isBufferLike_default = createSizePropertyCheck(_getByteLength_default); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isTypedArray.js +function isTypedArray(obj) { + return nativeIsView ? nativeIsView(obj) && !isDataView_default(obj) : _isBufferLike_default(obj) && typedArrayPattern.test(toString$2.call(obj)); +} +var typedArrayPattern, isTypedArray_default; +var init_isTypedArray = __esm({ "../../node_modules/underscore/modules/isTypedArray.js"() { + init__setup(); + init_isDataView(); + init_constant(); + init__isBufferLike(); + typedArrayPattern = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/; + isTypedArray_default = supportsArrayBuffer ? isTypedArray : constant(false); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_getLength.js +var _getLength_default; +var init__getLength = __esm({ "../../node_modules/underscore/modules/_getLength.js"() { + init__shallowProperty(); + _getLength_default = shallowProperty("length"); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_collectNonEnumProps.js +function emulatedSet(keys$2) { + var hash$2 = {}; + for (var l$1 = keys$2.length, i$5 = 0; i$5 < l$1; ++i$5) hash$2[keys$2[i$5]] = true; + return { + contains: function(key) { + return hash$2[key]; + }, + push: function(key) { + hash$2[key] = true; + return keys$2.push(key); + } + }; +} +function collectNonEnumProps(obj, keys$2) { + keys$2 = emulatedSet(keys$2); + var nonEnumIdx = nonEnumerableProps.length; + var constructor = obj.constructor; + var proto = isFunction_default(constructor) && constructor.prototype || ObjProto; + var prop = "constructor"; + if (has$1(obj, prop) && !keys$2.contains(prop)) keys$2.push(prop); + while (nonEnumIdx--) { + prop = nonEnumerableProps[nonEnumIdx]; + if (prop in obj && obj[prop] !== proto[prop] && !keys$2.contains(prop)) keys$2.push(prop); + } +} +var init__collectNonEnumProps = __esm({ "../../node_modules/underscore/modules/_collectNonEnumProps.js"() { + init__setup(); + init_isFunction(); + init__has(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/keys.js +function keys$1(obj) { + if (!isObject$2(obj)) return []; + if (nativeKeys) return nativeKeys(obj); + var keys$2 = []; + for (var key in obj) if (has$1(obj, key)) keys$2.push(key); + if (hasEnumBug) collectNonEnumProps(obj, keys$2); + return keys$2; +} +var init_keys = __esm({ "../../node_modules/underscore/modules/keys.js"() { + init_isObject(); + init__setup(); + init__has(); + init__collectNonEnumProps(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isEmpty.js +function isEmpty(obj) { + if (obj == null) return true; + var length = _getLength_default(obj); + if (typeof length == "number" && (isArray_default(obj) || isString_default(obj) || isArguments_default(obj))) return length === 0; + return _getLength_default(keys$1(obj)) === 0; +} +var init_isEmpty = __esm({ "../../node_modules/underscore/modules/isEmpty.js"() { + init__getLength(); + init_isArray(); + init_isString(); + init_isArguments(); + init_keys(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isMatch.js +function isMatch(object$3, attrs) { + var _keys = keys$1(attrs), length = _keys.length; + if (object$3 == null) return !length; + var obj = Object(object$3); + for (var i$5 = 0; i$5 < length; i$5++) { + var key = _keys[i$5]; + if (attrs[key] !== obj[key] || !(key in obj)) return false; + } + return true; +} +var init_isMatch = __esm({ "../../node_modules/underscore/modules/isMatch.js"() { + init_keys(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/underscore.js +function _$1(obj) { + if (obj instanceof _$1) return obj; + if (!(this instanceof _$1)) return new _$1(obj); + this._wrapped = obj; +} +var init_underscore = __esm({ "../../node_modules/underscore/modules/underscore.js"() { + init__setup(); + _$1.VERSION = VERSION; + _$1.prototype.value = function() { + return this._wrapped; + }; + _$1.prototype.valueOf = _$1.prototype.toJSON = _$1.prototype.value; + _$1.prototype.toString = function() { + return String(this._wrapped); + }; +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_toBufferView.js +function toBufferView(bufferSource) { + return new Uint8Array(bufferSource.buffer || bufferSource, bufferSource.byteOffset || 0, _getByteLength_default(bufferSource)); +} +var init__toBufferView = __esm({ "../../node_modules/underscore/modules/_toBufferView.js"() { + init__getByteLength(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isEqual.js +function eq(a, b$1, aStack, bStack) { + if (a === b$1) return a !== 0 || 1 / a === 1 / b$1; + if (a == null || b$1 == null) return false; + if (a !== a) return b$1 !== b$1; + var type = typeof a; + if (type !== "function" && type !== "object" && typeof b$1 != "object") return false; + return deepEq(a, b$1, aStack, bStack); +} +function deepEq(a, b$1, aStack, bStack) { + if (a instanceof _$1) a = a._wrapped; + if (b$1 instanceof _$1) b$1 = b$1._wrapped; + var className$3 = toString$2.call(a); + if (className$3 !== toString$2.call(b$1)) return false; + if (hasStringTagBug && className$3 == "[object Object]" && isDataView_default(a)) { + if (!isDataView_default(b$1)) return false; + className$3 = tagDataView; + } + switch (className$3) { + case "[object RegExp]": + case "[object String]": return "" + a === "" + b$1; + case "[object Number]": + if (+a !== +a) return +b$1 !== +b$1; + return +a === 0 ? 1 / +a === 1 / b$1 : +a === +b$1; + case "[object Date]": + case "[object Boolean]": return +a === +b$1; + case "[object Symbol]": return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b$1); + case "[object ArrayBuffer]": + case tagDataView: return deepEq(toBufferView(a), toBufferView(b$1), aStack, bStack); + } + var areArrays = className$3 === "[object Array]"; + if (!areArrays && isTypedArray_default(a)) { + var byteLength = _getByteLength_default(a); + if (byteLength !== _getByteLength_default(b$1)) return false; + if (a.buffer === b$1.buffer && a.byteOffset === b$1.byteOffset) return true; + areArrays = true; + } + if (!areArrays) { + if (typeof a != "object" || typeof b$1 != "object") return false; + var aCtor = a.constructor, bCtor = b$1.constructor; + if (aCtor !== bCtor && !(isFunction_default(aCtor) && aCtor instanceof aCtor && isFunction_default(bCtor) && bCtor instanceof bCtor) && "constructor" in a && "constructor" in b$1) return false; + } + aStack = aStack || []; + bStack = bStack || []; + var length = aStack.length; + while (length--) if (aStack[length] === a) return bStack[length] === b$1; + aStack.push(a); + bStack.push(b$1); + if (areArrays) { + length = a.length; + if (length !== b$1.length) return false; + while (length--) if (!eq(a[length], b$1[length], aStack, bStack)) return false; + } else { + var _keys = keys$1(a), key; + length = _keys.length; + if (keys$1(b$1).length !== length) return false; + while (length--) { + key = _keys[length]; + if (!(has$1(b$1, key) && eq(a[key], b$1[key], aStack, bStack))) return false; + } + } + aStack.pop(); + bStack.pop(); + return true; +} +function isEqual(a, b$1) { + return eq(a, b$1); +} +var tagDataView; +var init_isEqual = __esm({ "../../node_modules/underscore/modules/isEqual.js"() { + init_underscore(); + init__setup(); + init__getByteLength(); + init_isTypedArray(); + init_isFunction(); + init__stringTagBug(); + init_isDataView(); + init_keys(); + init__has(); + init__toBufferView(); + tagDataView = "[object DataView]"; +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/allKeys.js +function allKeys(obj) { + if (!isObject$2(obj)) return []; + var keys$2 = []; + for (var key in obj) keys$2.push(key); + if (hasEnumBug) collectNonEnumProps(obj, keys$2); + return keys$2; +} +var init_allKeys = __esm({ "../../node_modules/underscore/modules/allKeys.js"() { + init_isObject(); + init__setup(); + init__collectNonEnumProps(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_methodFingerprint.js +function ie11fingerprint(methods$1) { + var length = _getLength_default(methods$1); + return function(obj) { + if (obj == null) return false; + var keys$2 = allKeys(obj); + if (_getLength_default(keys$2)) return false; + for (var i$5 = 0; i$5 < length; i$5++) if (!isFunction_default(obj[methods$1[i$5]])) return false; + return methods$1 !== weakMapMethods || !isFunction_default(obj[forEachName]); + }; +} +var forEachName, hasName, commonInit, mapTail, mapMethods, weakMapMethods, setMethods; +var init__methodFingerprint = __esm({ "../../node_modules/underscore/modules/_methodFingerprint.js"() { + init__getLength(); + init_isFunction(); + init_allKeys(); + forEachName = "forEach", hasName = "has", commonInit = ["clear", "delete"], mapTail = [ + "get", + hasName, + "set" + ]; + mapMethods = commonInit.concat(forEachName, mapTail); + weakMapMethods = commonInit.concat(mapTail); + setMethods = ["add"].concat(commonInit, forEachName, hasName); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isMap.js +var isMap_default; +var init_isMap = __esm({ "../../node_modules/underscore/modules/isMap.js"() { + init__tagTester(); + init__stringTagBug(); + init__methodFingerprint(); + isMap_default = isIE11 ? ie11fingerprint(mapMethods) : tagTester("Map"); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isWeakMap.js +var isWeakMap_default; +var init_isWeakMap = __esm({ "../../node_modules/underscore/modules/isWeakMap.js"() { + init__tagTester(); + init__stringTagBug(); + init__methodFingerprint(); + isWeakMap_default = isIE11 ? ie11fingerprint(weakMapMethods) : tagTester("WeakMap"); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isSet.js +var isSet_default; +var init_isSet = __esm({ "../../node_modules/underscore/modules/isSet.js"() { + init__tagTester(); + init__stringTagBug(); + init__methodFingerprint(); + isSet_default = isIE11 ? ie11fingerprint(setMethods) : tagTester("Set"); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/isWeakSet.js +var isWeakSet_default; +var init_isWeakSet = __esm({ "../../node_modules/underscore/modules/isWeakSet.js"() { + init__tagTester(); + isWeakSet_default = tagTester("WeakSet"); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/values.js +function values(obj) { + var _keys = keys$1(obj); + var length = _keys.length; + var values$1 = Array(length); + for (var i$5 = 0; i$5 < length; i$5++) values$1[i$5] = obj[_keys[i$5]]; + return values$1; +} +var init_values = __esm({ "../../node_modules/underscore/modules/values.js"() { + init_keys(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/pairs.js +function pairs(obj) { + var _keys = keys$1(obj); + var length = _keys.length; + var pairs$1 = Array(length); + for (var i$5 = 0; i$5 < length; i$5++) pairs$1[i$5] = [_keys[i$5], obj[_keys[i$5]]]; + return pairs$1; +} +var init_pairs = __esm({ "../../node_modules/underscore/modules/pairs.js"() { + init_keys(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/invert.js +function invert(obj) { + var result$1 = {}; + var _keys = keys$1(obj); + for (var i$5 = 0, length = _keys.length; i$5 < length; i$5++) result$1[obj[_keys[i$5]]] = _keys[i$5]; + return result$1; +} +var init_invert = __esm({ "../../node_modules/underscore/modules/invert.js"() { + init_keys(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/functions.js +function functions(obj) { + var names = []; + for (var key in obj) if (isFunction_default(obj[key])) names.push(key); + return names.sort(); +} +var init_functions = __esm({ "../../node_modules/underscore/modules/functions.js"() { + init_isFunction(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_createAssigner.js +function createAssigner(keysFunc, defaults$2) { + return function(obj) { + var length = arguments.length; + if (defaults$2) obj = Object(obj); + if (length < 2 || obj == null) return obj; + for (var index$1 = 1; index$1 < length; index$1++) { + var source = arguments[index$1], keys$2 = keysFunc(source), l$1 = keys$2.length; + for (var i$5 = 0; i$5 < l$1; i$5++) { + var key = keys$2[i$5]; + if (!defaults$2 || obj[key] === void 0) obj[key] = source[key]; + } + } + return obj; + }; +} +var init__createAssigner = __esm({ "../../node_modules/underscore/modules/_createAssigner.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/extend.js +var extend_default; +var init_extend = __esm({ "../../node_modules/underscore/modules/extend.js"() { + init__createAssigner(); + init_allKeys(); + extend_default = createAssigner(allKeys); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/extendOwn.js +var extendOwn_default; +var init_extendOwn = __esm({ "../../node_modules/underscore/modules/extendOwn.js"() { + init__createAssigner(); + init_keys(); + extendOwn_default = createAssigner(keys$1); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/defaults.js +var defaults_default; +var init_defaults = __esm({ "../../node_modules/underscore/modules/defaults.js"() { + init__createAssigner(); + init_allKeys(); + defaults_default = createAssigner(allKeys, true); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_baseCreate.js +function ctor() { + return function() {}; +} +function baseCreate(prototype) { + if (!isObject$2(prototype)) return {}; + if (nativeCreate) return nativeCreate(prototype); + var Ctor = ctor(); + Ctor.prototype = prototype; + var result$1 = new Ctor(); + Ctor.prototype = null; + return result$1; +} +var init__baseCreate = __esm({ "../../node_modules/underscore/modules/_baseCreate.js"() { + init_isObject(); + init__setup(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/create.js +function create$3(prototype, props) { + var result$1 = baseCreate(prototype); + if (props) extendOwn_default(result$1, props); + return result$1; +} +var init_create = __esm({ "../../node_modules/underscore/modules/create.js"() { + init__baseCreate(); + init_extendOwn(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/clone.js +function clone$1(obj) { + if (!isObject$2(obj)) return obj; + return isArray_default(obj) ? obj.slice() : extend_default({}, obj); +} +var init_clone = __esm({ "../../node_modules/underscore/modules/clone.js"() { + init_isObject(); + init_isArray(); + init_extend(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/tap.js +function tap(obj, interceptor) { + interceptor(obj); + return obj; +} +var init_tap = __esm({ "../../node_modules/underscore/modules/tap.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/toPath.js +function toPath(path$28) { + return isArray_default(path$28) ? path$28 : [path$28]; +} +var init_toPath = __esm({ "../../node_modules/underscore/modules/toPath.js"() { + init_underscore(); + init_isArray(); + _$1.toPath = toPath; +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_toPath.js +function toPath$1(path$28) { + return _$1.toPath(path$28); +} +var init__toPath = __esm({ "../../node_modules/underscore/modules/_toPath.js"() { + init_underscore(); + init_toPath(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_deepGet.js +function deepGet(obj, path$28) { + var length = path$28.length; + for (var i$5 = 0; i$5 < length; i$5++) { + if (obj == null) return void 0; + obj = obj[path$28[i$5]]; + } + return length ? obj : void 0; +} +var init__deepGet = __esm({ "../../node_modules/underscore/modules/_deepGet.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/get.js +function get$1(object$3, path$28, defaultValue) { + var value = deepGet(object$3, toPath$1(path$28)); + return isUndefined(value) ? defaultValue : value; +} +var init_get = __esm({ "../../node_modules/underscore/modules/get.js"() { + init__toPath(); + init__deepGet(); + init_isUndefined(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/has.js +function has(obj, path$28) { + path$28 = toPath$1(path$28); + var length = path$28.length; + for (var i$5 = 0; i$5 < length; i$5++) { + var key = path$28[i$5]; + if (!has$1(obj, key)) return false; + obj = obj[key]; + } + return !!length; +} +var init_has = __esm({ "../../node_modules/underscore/modules/has.js"() { + init__has(); + init__toPath(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/identity.js +function identity(value) { + return value; +} +var init_identity = __esm({ "../../node_modules/underscore/modules/identity.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/matcher.js +function matcher(attrs) { + attrs = extendOwn_default({}, attrs); + return function(obj) { + return isMatch(obj, attrs); + }; +} +var init_matcher = __esm({ "../../node_modules/underscore/modules/matcher.js"() { + init_extendOwn(); + init_isMatch(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/property.js +function property(path$28) { + path$28 = toPath$1(path$28); + return function(obj) { + return deepGet(obj, path$28); + }; +} +var init_property = __esm({ "../../node_modules/underscore/modules/property.js"() { + init__deepGet(); + init__toPath(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_optimizeCb.js +function optimizeCb(func, context, argCount) { + if (context === void 0) return func; + switch (argCount == null ? 3 : argCount) { + case 1: return function(value) { + return func.call(context, value); + }; + case 3: return function(value, index$1, collection) { + return func.call(context, value, index$1, collection); + }; + case 4: return function(accumulator, value, index$1, collection) { + return func.call(context, accumulator, value, index$1, collection); + }; + } + return function() { + return func.apply(context, arguments); + }; +} +var init__optimizeCb = __esm({ "../../node_modules/underscore/modules/_optimizeCb.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_baseIteratee.js +function baseIteratee(value, context, argCount) { + if (value == null) return identity; + if (isFunction_default(value)) return optimizeCb(value, context, argCount); + if (isObject$2(value) && !isArray_default(value)) return matcher(value); + return property(value); +} +var init__baseIteratee = __esm({ "../../node_modules/underscore/modules/_baseIteratee.js"() { + init_identity(); + init_isFunction(); + init_isObject(); + init_isArray(); + init_matcher(); + init_property(); + init__optimizeCb(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/iteratee.js +function iteratee(value, context) { + return baseIteratee(value, context, Infinity); +} +var init_iteratee = __esm({ "../../node_modules/underscore/modules/iteratee.js"() { + init_underscore(); + init__baseIteratee(); + _$1.iteratee = iteratee; +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_cb.js +function cb(value, context, argCount) { + if (_$1.iteratee !== iteratee) return _$1.iteratee(value, context); + return baseIteratee(value, context, argCount); +} +var init__cb = __esm({ "../../node_modules/underscore/modules/_cb.js"() { + init_underscore(); + init__baseIteratee(); + init_iteratee(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/mapObject.js +function mapObject(obj, iteratee$1, context) { + iteratee$1 = cb(iteratee$1, context); + var _keys = keys$1(obj), length = _keys.length, results = {}; + for (var index$1 = 0; index$1 < length; index$1++) { + var currentKey = _keys[index$1]; + results[currentKey] = iteratee$1(obj[currentKey], currentKey, obj); + } + return results; +} +var init_mapObject = __esm({ "../../node_modules/underscore/modules/mapObject.js"() { + init__cb(); + init_keys(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/noop.js +function noop$1() {} +var init_noop = __esm({ "../../node_modules/underscore/modules/noop.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/propertyOf.js +function propertyOf(obj) { + if (obj == null) return noop$1; + return function(path$28) { + return get$1(obj, path$28); + }; +} +var init_propertyOf = __esm({ "../../node_modules/underscore/modules/propertyOf.js"() { + init_noop(); + init_get(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/times.js +function times(n$3, iteratee$1, context) { + var accum = Array(Math.max(0, n$3)); + iteratee$1 = optimizeCb(iteratee$1, context, 1); + for (var i$5 = 0; i$5 < n$3; i$5++) accum[i$5] = iteratee$1(i$5); + return accum; +} +var init_times = __esm({ "../../node_modules/underscore/modules/times.js"() { + init__optimizeCb(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/random.js +function random(min$1, max$2) { + if (max$2 == null) { + max$2 = min$1; + min$1 = 0; + } + return min$1 + Math.floor(Math.random() * (max$2 - min$1 + 1)); +} +var init_random = __esm({ "../../node_modules/underscore/modules/random.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/now.js +var now_default; +var init_now = __esm({ "../../node_modules/underscore/modules/now.js"() { + now_default = Date.now || function() { + return new Date().getTime(); + }; +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_createEscaper.js +function createEscaper(map$1) { + var escaper = function(match) { + return map$1[match]; + }; + var source = "(?:" + keys$1(map$1).join("|") + ")"; + var testRegexp = RegExp(source); + var replaceRegexp = RegExp(source, "g"); + return function(string$3) { + string$3 = string$3 == null ? "" : "" + string$3; + return testRegexp.test(string$3) ? string$3.replace(replaceRegexp, escaper) : string$3; + }; +} +var init__createEscaper = __esm({ "../../node_modules/underscore/modules/_createEscaper.js"() { + init_keys(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_escapeMap.js +var _escapeMap_default; +var init__escapeMap = __esm({ "../../node_modules/underscore/modules/_escapeMap.js"() { + _escapeMap_default = { + "&": "&", + "<": "<", + ">": ">", + "\"": """, + "'": "'", + "`": "`" + }; +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/escape.js +var escape_default; +var init_escape = __esm({ "../../node_modules/underscore/modules/escape.js"() { + init__createEscaper(); + init__escapeMap(); + escape_default = createEscaper(_escapeMap_default); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_unescapeMap.js +var _unescapeMap_default; +var init__unescapeMap = __esm({ "../../node_modules/underscore/modules/_unescapeMap.js"() { + init_invert(); + init__escapeMap(); + _unescapeMap_default = invert(_escapeMap_default); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/unescape.js +var unescape_default; +var init_unescape = __esm({ "../../node_modules/underscore/modules/unescape.js"() { + init__createEscaper(); + init__unescapeMap(); + unescape_default = createEscaper(_unescapeMap_default); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/templateSettings.js +var templateSettings_default; +var init_templateSettings = __esm({ "../../node_modules/underscore/modules/templateSettings.js"() { + init_underscore(); + templateSettings_default = _$1.templateSettings = { + evaluate: /<%([\s\S]+?)%>/g, + interpolate: /<%=([\s\S]+?)%>/g, + escape: /<%-([\s\S]+?)%>/g + }; +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/template.js +function escapeChar(match) { + return "\\" + escapes[match]; +} +function template(text, settings, oldSettings) { + if (!settings && oldSettings) settings = oldSettings; + settings = defaults_default({}, settings, _$1.templateSettings); + var matcher$1 = RegExp([ + (settings.escape || noMatch).source, + (settings.interpolate || noMatch).source, + (settings.evaluate || noMatch).source + ].join("|") + "|$", "g"); + var index$1 = 0; + var source = "__p+='"; + text.replace(matcher$1, function(match, escape$2, interpolate, evaluate$1, offset) { + source += text.slice(index$1, offset).replace(escapeRegExp, escapeChar); + index$1 = offset + match.length; + if (escape$2) source += "'+\n((__t=(" + escape$2 + "))==null?'':_.escape(__t))+\n'"; + else if (interpolate) source += "'+\n((__t=(" + interpolate + "))==null?'':__t)+\n'"; + else if (evaluate$1) source += "';\n" + evaluate$1 + "\n__p+='"; + return match; + }); + source += "';\n"; + var argument = settings.variable; + if (argument) { + if (!bareIdentifier.test(argument)) throw new Error(argument); + } else { + source = "with(obj||{}){\n" + source + "}\n"; + argument = "obj"; + } + source = "var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n" + source + "return __p;\n"; + var render$1; + try { + render$1 = new Function(argument, "_", source); + } catch (e) { + e.source = source; + throw e; + } + var template$2 = function(data$2) { + return render$1.call(this, data$2, _$1); + }; + template$2.source = "function(" + argument + "){\n" + source + "}"; + return template$2; +} +var noMatch, escapes, escapeRegExp, bareIdentifier; +var init_template = __esm({ "../../node_modules/underscore/modules/template.js"() { + init_defaults(); + init_underscore(); + init_templateSettings(); + noMatch = /(.)^/; + escapes = { + "'": "'", + "\\": "\\", + "\r": "r", + "\n": "n", + "\u2028": "u2028", + "\u2029": "u2029" + }; + escapeRegExp = /\\|'|\r|\n|\u2028|\u2029/g; + bareIdentifier = /^\s*(\w|\$)+\s*$/; +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/result.js +function result(obj, path$28, fallback) { + path$28 = toPath$1(path$28); + var length = path$28.length; + if (!length) return isFunction_default(fallback) ? fallback.call(obj) : fallback; + for (var i$5 = 0; i$5 < length; i$5++) { + var prop = obj == null ? void 0 : obj[path$28[i$5]]; + if (prop === void 0) { + prop = fallback; + i$5 = length; + } + obj = isFunction_default(prop) ? prop.call(obj) : prop; + } + return obj; +} +var init_result = __esm({ "../../node_modules/underscore/modules/result.js"() { + init_isFunction(); + init__toPath(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/uniqueId.js +function uniqueId(prefix$1) { + var id$4 = ++idCounter + ""; + return prefix$1 ? prefix$1 + id$4 : id$4; +} +var idCounter; +var init_uniqueId = __esm({ "../../node_modules/underscore/modules/uniqueId.js"() { + idCounter = 0; +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/chain.js +function chain$1(obj) { + var instance = _$1(obj); + instance._chain = true; + return instance; +} +var init_chain = __esm({ "../../node_modules/underscore/modules/chain.js"() { + init_underscore(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_executeBound.js +function executeBound(sourceFunc, boundFunc, context, callingContext, args) { + if (!(callingContext instanceof boundFunc)) return sourceFunc.apply(context, args); + var self$1 = baseCreate(sourceFunc.prototype); + var result$1 = sourceFunc.apply(self$1, args); + if (isObject$2(result$1)) return result$1; + return self$1; +} +var init__executeBound = __esm({ "../../node_modules/underscore/modules/_executeBound.js"() { + init__baseCreate(); + init_isObject(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/partial.js +var partial, partial_default; +var init_partial = __esm({ "../../node_modules/underscore/modules/partial.js"() { + init_restArguments(); + init__executeBound(); + init_underscore(); + partial = restArguments(function(func, boundArgs) { + var placeholder$1 = partial.placeholder; + var bound = function() { + var position = 0, length = boundArgs.length; + var args = Array(length); + for (var i$5 = 0; i$5 < length; i$5++) args[i$5] = boundArgs[i$5] === placeholder$1 ? arguments[position++] : boundArgs[i$5]; + while (position < arguments.length) args.push(arguments[position++]); + return executeBound(func, bound, this, this, args); + }; + return bound; + }); + partial.placeholder = _$1; + partial_default = partial; +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/bind.js +var bind_default; +var init_bind = __esm({ "../../node_modules/underscore/modules/bind.js"() { + init_restArguments(); + init_isFunction(); + init__executeBound(); + bind_default = restArguments(function(func, context, args) { + if (!isFunction_default(func)) throw new TypeError("Bind must be called on a function"); + var bound = restArguments(function(callArgs) { + return executeBound(func, bound, context, this, args.concat(callArgs)); + }); + return bound; + }); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_isArrayLike.js +var _isArrayLike_default; +var init__isArrayLike = __esm({ "../../node_modules/underscore/modules/_isArrayLike.js"() { + init__createSizePropertyCheck(); + init__getLength(); + _isArrayLike_default = createSizePropertyCheck(_getLength_default); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_flatten.js +function flatten$1(input, depth$1, strict, output) { + output = output || []; + if (!depth$1 && depth$1 !== 0) depth$1 = Infinity; + else if (depth$1 <= 0) return output.concat(input); + var idx = output.length; + for (var i$5 = 0, length = _getLength_default(input); i$5 < length; i$5++) { + var value = input[i$5]; + if (_isArrayLike_default(value) && (isArray_default(value) || isArguments_default(value))) if (depth$1 > 1) { + flatten$1(value, depth$1 - 1, strict, output); + idx = output.length; + } else { + var j = 0, len = value.length; + while (j < len) output[idx++] = value[j++]; + } + else if (!strict) output[idx++] = value; + } + return output; +} +var init__flatten = __esm({ "../../node_modules/underscore/modules/_flatten.js"() { + init__getLength(); + init__isArrayLike(); + init_isArray(); + init_isArguments(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/bindAll.js +var bindAll_default; +var init_bindAll = __esm({ "../../node_modules/underscore/modules/bindAll.js"() { + init_restArguments(); + init__flatten(); + init_bind(); + bindAll_default = restArguments(function(obj, keys$2) { + keys$2 = flatten$1(keys$2, false, false); + var index$1 = keys$2.length; + if (index$1 < 1) throw new Error("bindAll must be passed function names"); + while (index$1--) { + var key = keys$2[index$1]; + obj[key] = bind_default(obj[key], obj); + } + return obj; + }); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/memoize.js +function memoize(func, hasher) { + var memoize$1 = function(key) { + var cache$3 = memoize$1.cache; + var address = "" + (hasher ? hasher.apply(this, arguments) : key); + if (!has$1(cache$3, address)) cache$3[address] = func.apply(this, arguments); + return cache$3[address]; + }; + memoize$1.cache = {}; + return memoize$1; +} +var init_memoize = __esm({ "../../node_modules/underscore/modules/memoize.js"() { + init__has(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/delay.js +var delay_default; +var init_delay = __esm({ "../../node_modules/underscore/modules/delay.js"() { + init_restArguments(); + delay_default = restArguments(function(func, wait, args) { + return setTimeout(function() { + return func.apply(null, args); + }, wait); + }); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/defer.js +var defer_default; +var init_defer = __esm({ "../../node_modules/underscore/modules/defer.js"() { + init_partial(); + init_delay(); + init_underscore(); + defer_default = partial_default(delay_default, _$1, 1); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/throttle.js +function throttle(func, wait, options) { + var timeout, context, args, result$1; + var previous = 0; + if (!options) options = {}; + var later = function() { + previous = options.leading === false ? 0 : now_default(); + timeout = null; + result$1 = func.apply(context, args); + if (!timeout) context = args = null; + }; + var throttled = function() { + var _now = now_default(); + if (!previous && options.leading === false) previous = _now; + var remaining = wait - (_now - previous); + context = this; + args = arguments; + if (remaining <= 0 || remaining > wait) { + if (timeout) { + clearTimeout(timeout); + timeout = null; + } + previous = _now; + result$1 = func.apply(context, args); + if (!timeout) context = args = null; + } else if (!timeout && options.trailing !== false) timeout = setTimeout(later, remaining); + return result$1; + }; + throttled.cancel = function() { + clearTimeout(timeout); + previous = 0; + timeout = context = args = null; + }; + return throttled; +} +var init_throttle = __esm({ "../../node_modules/underscore/modules/throttle.js"() { + init_now(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/debounce.js +function debounce(func, wait, immediate) { + var timeout, previous, args, result$1, context; + var later = function() { + var passed = now_default() - previous; + if (wait > passed) timeout = setTimeout(later, wait - passed); + else { + timeout = null; + if (!immediate) result$1 = func.apply(context, args); + if (!timeout) args = context = null; + } + }; + var debounced = restArguments(function(_args) { + context = this; + args = _args; + previous = now_default(); + if (!timeout) { + timeout = setTimeout(later, wait); + if (immediate) result$1 = func.apply(context, args); + } + return result$1; + }); + debounced.cancel = function() { + clearTimeout(timeout); + timeout = args = context = null; + }; + return debounced; +} +var init_debounce = __esm({ "../../node_modules/underscore/modules/debounce.js"() { + init_restArguments(); + init_now(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/wrap.js +function wrap(func, wrapper) { + return partial_default(wrapper, func); +} +var init_wrap = __esm({ "../../node_modules/underscore/modules/wrap.js"() { + init_partial(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/negate.js +function negate(predicate) { + return function() { + return !predicate.apply(this, arguments); + }; +} +var init_negate = __esm({ "../../node_modules/underscore/modules/negate.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/compose.js +function compose$1() { + var args = arguments; + var start = args.length - 1; + return function() { + var i$5 = start; + var result$1 = args[start].apply(this, arguments); + while (i$5--) result$1 = args[i$5].call(this, result$1); + return result$1; + }; +} +var init_compose = __esm({ "../../node_modules/underscore/modules/compose.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/after.js +function after(times$1, func) { + return function() { + if (--times$1 < 1) return func.apply(this, arguments); + }; +} +var init_after = __esm({ "../../node_modules/underscore/modules/after.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/before.js +function before(times$1, func) { + var memo; + return function() { + if (--times$1 > 0) memo = func.apply(this, arguments); + if (times$1 <= 1) func = null; + return memo; + }; +} +var init_before = __esm({ "../../node_modules/underscore/modules/before.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/once.js +var once_default; +var init_once = __esm({ "../../node_modules/underscore/modules/once.js"() { + init_partial(); + init_before(); + once_default = partial_default(before, 2); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/findKey.js +function findKey(obj, predicate, context) { + predicate = cb(predicate, context); + var _keys = keys$1(obj), key; + for (var i$5 = 0, length = _keys.length; i$5 < length; i$5++) { + key = _keys[i$5]; + if (predicate(obj[key], key, obj)) return key; + } +} +var init_findKey = __esm({ "../../node_modules/underscore/modules/findKey.js"() { + init__cb(); + init_keys(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_createPredicateIndexFinder.js +function createPredicateIndexFinder(dir) { + return function(array, predicate, context) { + predicate = cb(predicate, context); + var length = _getLength_default(array); + var index$1 = dir > 0 ? 0 : length - 1; + for (; index$1 >= 0 && index$1 < length; index$1 += dir) if (predicate(array[index$1], index$1, array)) return index$1; + return -1; + }; +} +var init__createPredicateIndexFinder = __esm({ "../../node_modules/underscore/modules/_createPredicateIndexFinder.js"() { + init__cb(); + init__getLength(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/findIndex.js +var findIndex_default; +var init_findIndex = __esm({ "../../node_modules/underscore/modules/findIndex.js"() { + init__createPredicateIndexFinder(); + findIndex_default = createPredicateIndexFinder(1); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/findLastIndex.js +var findLastIndex_default; +var init_findLastIndex = __esm({ "../../node_modules/underscore/modules/findLastIndex.js"() { + init__createPredicateIndexFinder(); + findLastIndex_default = createPredicateIndexFinder(-1); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/sortedIndex.js +function sortedIndex(array, obj, iteratee$1, context) { + iteratee$1 = cb(iteratee$1, context, 1); + var value = iteratee$1(obj); + var low = 0, high = _getLength_default(array); + while (low < high) { + var mid = Math.floor((low + high) / 2); + if (iteratee$1(array[mid]) < value) low = mid + 1; + else high = mid; + } + return low; +} +var init_sortedIndex = __esm({ "../../node_modules/underscore/modules/sortedIndex.js"() { + init__cb(); + init__getLength(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_createIndexFinder.js +function createIndexFinder(dir, predicateFind, sortedIndex$1) { + return function(array, item, idx) { + var i$5 = 0, length = _getLength_default(array); + if (typeof idx == "number") if (dir > 0) i$5 = idx >= 0 ? idx : Math.max(idx + length, i$5); + else length = idx >= 0 ? Math.min(idx + 1, length) : idx + length + 1; + else if (sortedIndex$1 && idx && length) { + idx = sortedIndex$1(array, item); + return array[idx] === item ? idx : -1; + } + if (item !== item) { + idx = predicateFind(slice$1.call(array, i$5, length), isNaN$1); + return idx >= 0 ? idx + i$5 : -1; + } + for (idx = dir > 0 ? i$5 : length - 1; idx >= 0 && idx < length; idx += dir) if (array[idx] === item) return idx; + return -1; + }; +} +var init__createIndexFinder = __esm({ "../../node_modules/underscore/modules/_createIndexFinder.js"() { + init__getLength(); + init__setup(); + init_isNaN(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/indexOf.js +var indexOf_default; +var init_indexOf = __esm({ "../../node_modules/underscore/modules/indexOf.js"() { + init_sortedIndex(); + init_findIndex(); + init__createIndexFinder(); + indexOf_default = createIndexFinder(1, findIndex_default, sortedIndex); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/lastIndexOf.js +var lastIndexOf_default; +var init_lastIndexOf = __esm({ "../../node_modules/underscore/modules/lastIndexOf.js"() { + init_findLastIndex(); + init__createIndexFinder(); + lastIndexOf_default = createIndexFinder(-1, findLastIndex_default); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/find.js +function find$2(obj, predicate, context) { + var keyFinder = _isArrayLike_default(obj) ? findIndex_default : findKey; + var key = keyFinder(obj, predicate, context); + if (key !== void 0 && key !== -1) return obj[key]; +} +var init_find = __esm({ "../../node_modules/underscore/modules/find.js"() { + init__isArrayLike(); + init_findIndex(); + init_findKey(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/findWhere.js +function findWhere(obj, attrs) { + return find$2(obj, matcher(attrs)); +} +var init_findWhere = __esm({ "../../node_modules/underscore/modules/findWhere.js"() { + init_find(); + init_matcher(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/each.js +function each(obj, iteratee$1, context) { + iteratee$1 = optimizeCb(iteratee$1, context); + var i$5, length; + if (_isArrayLike_default(obj)) for (i$5 = 0, length = obj.length; i$5 < length; i$5++) iteratee$1(obj[i$5], i$5, obj); + else { + var _keys = keys$1(obj); + for (i$5 = 0, length = _keys.length; i$5 < length; i$5++) iteratee$1(obj[_keys[i$5]], _keys[i$5], obj); + } + return obj; +} +var init_each = __esm({ "../../node_modules/underscore/modules/each.js"() { + init__optimizeCb(); + init__isArrayLike(); + init_keys(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/map.js +function map(obj, iteratee$1, context) { + iteratee$1 = cb(iteratee$1, context); + var _keys = !_isArrayLike_default(obj) && keys$1(obj), length = (_keys || obj).length, results = Array(length); + for (var index$1 = 0; index$1 < length; index$1++) { + var currentKey = _keys ? _keys[index$1] : index$1; + results[index$1] = iteratee$1(obj[currentKey], currentKey, obj); + } + return results; +} +var init_map = __esm({ "../../node_modules/underscore/modules/map.js"() { + init__cb(); + init__isArrayLike(); + init_keys(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_createReduce.js +function createReduce(dir) { + var reducer = function(obj, iteratee$1, memo, initial$1) { + var _keys = !_isArrayLike_default(obj) && keys$1(obj), length = (_keys || obj).length, index$1 = dir > 0 ? 0 : length - 1; + if (!initial$1) { + memo = obj[_keys ? _keys[index$1] : index$1]; + index$1 += dir; + } + for (; index$1 >= 0 && index$1 < length; index$1 += dir) { + var currentKey = _keys ? _keys[index$1] : index$1; + memo = iteratee$1(memo, obj[currentKey], currentKey, obj); + } + return memo; + }; + return function(obj, iteratee$1, memo, context) { + var initial$1 = arguments.length >= 3; + return reducer(obj, optimizeCb(iteratee$1, context, 4), memo, initial$1); + }; +} +var init__createReduce = __esm({ "../../node_modules/underscore/modules/_createReduce.js"() { + init__isArrayLike(); + init_keys(); + init__optimizeCb(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/reduce.js +var reduce_default; +var init_reduce = __esm({ "../../node_modules/underscore/modules/reduce.js"() { + init__createReduce(); + reduce_default = createReduce(1); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/reduceRight.js +var reduceRight_default; +var init_reduceRight = __esm({ "../../node_modules/underscore/modules/reduceRight.js"() { + init__createReduce(); + reduceRight_default = createReduce(-1); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/filter.js +function filter$2(obj, predicate, context) { + var results = []; + predicate = cb(predicate, context); + each(obj, function(value, index$1, list$4) { + if (predicate(value, index$1, list$4)) results.push(value); + }); + return results; +} +var init_filter = __esm({ "../../node_modules/underscore/modules/filter.js"() { + init__cb(); + init_each(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/reject.js +function reject(obj, predicate, context) { + return filter$2(obj, negate(cb(predicate)), context); +} +var init_reject = __esm({ "../../node_modules/underscore/modules/reject.js"() { + init_filter(); + init_negate(); + init__cb(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/every.js +function every(obj, predicate, context) { + predicate = cb(predicate, context); + var _keys = !_isArrayLike_default(obj) && keys$1(obj), length = (_keys || obj).length; + for (var index$1 = 0; index$1 < length; index$1++) { + var currentKey = _keys ? _keys[index$1] : index$1; + if (!predicate(obj[currentKey], currentKey, obj)) return false; + } + return true; +} +var init_every = __esm({ "../../node_modules/underscore/modules/every.js"() { + init__cb(); + init__isArrayLike(); + init_keys(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/some.js +function some(obj, predicate, context) { + predicate = cb(predicate, context); + var _keys = !_isArrayLike_default(obj) && keys$1(obj), length = (_keys || obj).length; + for (var index$1 = 0; index$1 < length; index$1++) { + var currentKey = _keys ? _keys[index$1] : index$1; + if (predicate(obj[currentKey], currentKey, obj)) return true; + } + return false; +} +var init_some = __esm({ "../../node_modules/underscore/modules/some.js"() { + init__cb(); + init__isArrayLike(); + init_keys(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/contains.js +function contains(obj, item, fromIndex, guard) { + if (!_isArrayLike_default(obj)) obj = values(obj); + if (typeof fromIndex != "number" || guard) fromIndex = 0; + return indexOf_default(obj, item, fromIndex) >= 0; +} +var init_contains = __esm({ "../../node_modules/underscore/modules/contains.js"() { + init__isArrayLike(); + init_values(); + init_indexOf(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/invoke.js +var invoke_default; +var init_invoke = __esm({ "../../node_modules/underscore/modules/invoke.js"() { + init_restArguments(); + init_isFunction(); + init_map(); + init__deepGet(); + init__toPath(); + invoke_default = restArguments(function(obj, path$28, args) { + var contextPath, func; + if (isFunction_default(path$28)) func = path$28; + else { + path$28 = toPath$1(path$28); + contextPath = path$28.slice(0, -1); + path$28 = path$28[path$28.length - 1]; + } + return map(obj, function(context) { + var method = func; + if (!method) { + if (contextPath && contextPath.length) context = deepGet(context, contextPath); + if (context == null) return void 0; + method = context[path$28]; + } + return method == null ? method : method.apply(context, args); + }); + }); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/pluck.js +function pluck(obj, key) { + return map(obj, property(key)); +} +var init_pluck = __esm({ "../../node_modules/underscore/modules/pluck.js"() { + init_map(); + init_property(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/where.js +function where(obj, attrs) { + return filter$2(obj, matcher(attrs)); +} +var init_where = __esm({ "../../node_modules/underscore/modules/where.js"() { + init_filter(); + init_matcher(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/max.js +function max(obj, iteratee$1, context) { + var result$1 = -Infinity, lastComputed = -Infinity, value, computed; + if (iteratee$1 == null || typeof iteratee$1 == "number" && typeof obj[0] != "object" && obj != null) { + obj = _isArrayLike_default(obj) ? obj : values(obj); + for (var i$5 = 0, length = obj.length; i$5 < length; i$5++) { + value = obj[i$5]; + if (value != null && value > result$1) result$1 = value; + } + } else { + iteratee$1 = cb(iteratee$1, context); + each(obj, function(v$1, index$1, list$4) { + computed = iteratee$1(v$1, index$1, list$4); + if (computed > lastComputed || computed === -Infinity && result$1 === -Infinity) { + result$1 = v$1; + lastComputed = computed; + } + }); + } + return result$1; +} +var init_max = __esm({ "../../node_modules/underscore/modules/max.js"() { + init__isArrayLike(); + init_values(); + init__cb(); + init_each(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/min.js +function min(obj, iteratee$1, context) { + var result$1 = Infinity, lastComputed = Infinity, value, computed; + if (iteratee$1 == null || typeof iteratee$1 == "number" && typeof obj[0] != "object" && obj != null) { + obj = _isArrayLike_default(obj) ? obj : values(obj); + for (var i$5 = 0, length = obj.length; i$5 < length; i$5++) { + value = obj[i$5]; + if (value != null && value < result$1) result$1 = value; + } + } else { + iteratee$1 = cb(iteratee$1, context); + each(obj, function(v$1, index$1, list$4) { + computed = iteratee$1(v$1, index$1, list$4); + if (computed < lastComputed || computed === Infinity && result$1 === Infinity) { + result$1 = v$1; + lastComputed = computed; + } + }); + } + return result$1; +} +var init_min = __esm({ "../../node_modules/underscore/modules/min.js"() { + init__isArrayLike(); + init_values(); + init__cb(); + init_each(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/sample.js +function sample(obj, n$3, guard) { + if (n$3 == null || guard) { + if (!_isArrayLike_default(obj)) obj = values(obj); + return obj[random(obj.length - 1)]; + } + var sample$1 = _isArrayLike_default(obj) ? clone$1(obj) : values(obj); + var length = _getLength_default(sample$1); + n$3 = Math.max(Math.min(n$3, length), 0); + var last$3 = length - 1; + for (var index$1 = 0; index$1 < n$3; index$1++) { + var rand = random(index$1, last$3); + var temp = sample$1[index$1]; + sample$1[index$1] = sample$1[rand]; + sample$1[rand] = temp; + } + return sample$1.slice(0, n$3); +} +var init_sample = __esm({ "../../node_modules/underscore/modules/sample.js"() { + init__isArrayLike(); + init_clone(); + init_values(); + init__getLength(); + init_random(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/shuffle.js +function shuffle(obj) { + return sample(obj, Infinity); +} +var init_shuffle = __esm({ "../../node_modules/underscore/modules/shuffle.js"() { + init_sample(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/sortBy.js +function sortBy(obj, iteratee$1, context) { + var index$1 = 0; + iteratee$1 = cb(iteratee$1, context); + return pluck(map(obj, function(value, key, list$4) { + return { + value, + index: index$1++, + criteria: iteratee$1(value, key, list$4) + }; + }).sort(function(left, right) { + var a = left.criteria; + var b$1 = right.criteria; + if (a !== b$1) { + if (a > b$1 || a === void 0) return 1; + if (a < b$1 || b$1 === void 0) return -1; + } + return left.index - right.index; + }), "value"); +} +var init_sortBy = __esm({ "../../node_modules/underscore/modules/sortBy.js"() { + init__cb(); + init_pluck(); + init_map(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_group.js +function group(behavior, partition$1) { + return function(obj, iteratee$1, context) { + var result$1 = partition$1 ? [[], []] : {}; + iteratee$1 = cb(iteratee$1, context); + each(obj, function(value, index$1) { + var key = iteratee$1(value, index$1, obj); + behavior(result$1, value, key); + }); + return result$1; + }; +} +var init__group = __esm({ "../../node_modules/underscore/modules/_group.js"() { + init__cb(); + init_each(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/groupBy.js +var groupBy_default; +var init_groupBy = __esm({ "../../node_modules/underscore/modules/groupBy.js"() { + init__group(); + init__has(); + groupBy_default = group(function(result$1, value, key) { + if (has$1(result$1, key)) result$1[key].push(value); + else result$1[key] = [value]; + }); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/indexBy.js +var indexBy_default; +var init_indexBy = __esm({ "../../node_modules/underscore/modules/indexBy.js"() { + init__group(); + indexBy_default = group(function(result$1, value, key) { + result$1[key] = value; + }); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/countBy.js +var countBy_default; +var init_countBy = __esm({ "../../node_modules/underscore/modules/countBy.js"() { + init__group(); + init__has(); + countBy_default = group(function(result$1, value, key) { + if (has$1(result$1, key)) result$1[key]++; + else result$1[key] = 1; + }); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/partition.js +var partition_default; +var init_partition = __esm({ "../../node_modules/underscore/modules/partition.js"() { + init__group(); + partition_default = group(function(result$1, value, pass) { + result$1[pass ? 0 : 1].push(value); + }, true); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/toArray.js +function toArray(obj) { + if (!obj) return []; + if (isArray_default(obj)) return slice$1.call(obj); + if (isString_default(obj)) return obj.match(reStrSymbol); + if (_isArrayLike_default(obj)) return map(obj, identity); + return values(obj); +} +var reStrSymbol; +var init_toArray = __esm({ "../../node_modules/underscore/modules/toArray.js"() { + init_isArray(); + init__setup(); + init_isString(); + init__isArrayLike(); + init_map(); + init_identity(); + init_values(); + reStrSymbol = /[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g; +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/size.js +function size(obj) { + if (obj == null) return 0; + return _isArrayLike_default(obj) ? obj.length : keys$1(obj).length; +} +var init_size = __esm({ "../../node_modules/underscore/modules/size.js"() { + init__isArrayLike(); + init_keys(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_keyInObj.js +function keyInObj(value, key, obj) { + return key in obj; +} +var init__keyInObj = __esm({ "../../node_modules/underscore/modules/_keyInObj.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/pick.js +var pick_default; +var init_pick = __esm({ "../../node_modules/underscore/modules/pick.js"() { + init_restArguments(); + init_isFunction(); + init__optimizeCb(); + init_allKeys(); + init__keyInObj(); + init__flatten(); + pick_default = restArguments(function(obj, keys$2) { + var result$1 = {}, iteratee$1 = keys$2[0]; + if (obj == null) return result$1; + if (isFunction_default(iteratee$1)) { + if (keys$2.length > 1) iteratee$1 = optimizeCb(iteratee$1, keys$2[1]); + keys$2 = allKeys(obj); + } else { + iteratee$1 = keyInObj; + keys$2 = flatten$1(keys$2, false, false); + obj = Object(obj); + } + for (var i$5 = 0, length = keys$2.length; i$5 < length; i$5++) { + var key = keys$2[i$5]; + var value = obj[key]; + if (iteratee$1(value, key, obj)) result$1[key] = value; + } + return result$1; + }); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/omit.js +var omit_default; +var init_omit = __esm({ "../../node_modules/underscore/modules/omit.js"() { + init_restArguments(); + init_isFunction(); + init_negate(); + init_map(); + init__flatten(); + init_contains(); + init_pick(); + omit_default = restArguments(function(obj, keys$2) { + var iteratee$1 = keys$2[0], context; + if (isFunction_default(iteratee$1)) { + iteratee$1 = negate(iteratee$1); + if (keys$2.length > 1) context = keys$2[1]; + } else { + keys$2 = map(flatten$1(keys$2, false, false), String); + iteratee$1 = function(value, key) { + return !contains(keys$2, key); + }; + } + return pick_default(obj, iteratee$1, context); + }); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/initial.js +function initial(array, n$3, guard) { + return slice$1.call(array, 0, Math.max(0, array.length - (n$3 == null || guard ? 1 : n$3))); +} +var init_initial = __esm({ "../../node_modules/underscore/modules/initial.js"() { + init__setup(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/first.js +function first(array, n$3, guard) { + if (array == null || array.length < 1) return n$3 == null || guard ? void 0 : []; + if (n$3 == null || guard) return array[0]; + return initial(array, array.length - n$3); +} +var init_first = __esm({ "../../node_modules/underscore/modules/first.js"() { + init_initial(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/rest.js +function rest(array, n$3, guard) { + return slice$1.call(array, n$3 == null || guard ? 1 : n$3); +} +var init_rest = __esm({ "../../node_modules/underscore/modules/rest.js"() { + init__setup(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/last.js +function last$1(array, n$3, guard) { + if (array == null || array.length < 1) return n$3 == null || guard ? void 0 : []; + if (n$3 == null || guard) return array[array.length - 1]; + return rest(array, Math.max(0, array.length - n$3)); +} +var init_last = __esm({ "../../node_modules/underscore/modules/last.js"() { + init_rest(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/compact.js +function compact(array) { + return filter$2(array, Boolean); +} +var init_compact = __esm({ "../../node_modules/underscore/modules/compact.js"() { + init_filter(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/flatten.js +function flatten(array, depth$1) { + return flatten$1(array, depth$1, false); +} +var init_flatten = __esm({ "../../node_modules/underscore/modules/flatten.js"() { + init__flatten(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/difference.js +var difference_default; +var init_difference = __esm({ "../../node_modules/underscore/modules/difference.js"() { + init_restArguments(); + init__flatten(); + init_filter(); + init_contains(); + difference_default = restArguments(function(array, rest$1) { + rest$1 = flatten$1(rest$1, true, true); + return filter$2(array, function(value) { + return !contains(rest$1, value); + }); + }); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/without.js +var without_default; +var init_without = __esm({ "../../node_modules/underscore/modules/without.js"() { + init_restArguments(); + init_difference(); + without_default = restArguments(function(array, otherArrays) { + return difference_default(array, otherArrays); + }); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/uniq.js +function uniq(array, isSorted, iteratee$1, context) { + if (!isBoolean(isSorted)) { + context = iteratee$1; + iteratee$1 = isSorted; + isSorted = false; + } + if (iteratee$1 != null) iteratee$1 = cb(iteratee$1, context); + var result$1 = []; + var seen$1 = []; + for (var i$5 = 0, length = _getLength_default(array); i$5 < length; i$5++) { + var value = array[i$5], computed = iteratee$1 ? iteratee$1(value, i$5, array) : value; + if (isSorted && !iteratee$1) { + if (!i$5 || seen$1 !== computed) result$1.push(value); + seen$1 = computed; + } else if (iteratee$1) { + if (!contains(seen$1, computed)) { + seen$1.push(computed); + result$1.push(value); + } + } else if (!contains(result$1, value)) result$1.push(value); + } + return result$1; +} +var init_uniq = __esm({ "../../node_modules/underscore/modules/uniq.js"() { + init_isBoolean(); + init__cb(); + init__getLength(); + init_contains(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/union.js +var union_default; +var init_union = __esm({ "../../node_modules/underscore/modules/union.js"() { + init_restArguments(); + init_uniq(); + init__flatten(); + union_default = restArguments(function(arrays) { + return uniq(flatten$1(arrays, true, true)); + }); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/intersection.js +function intersection(array) { + var result$1 = []; + var argsLength = arguments.length; + for (var i$5 = 0, length = _getLength_default(array); i$5 < length; i$5++) { + var item = array[i$5]; + if (contains(result$1, item)) continue; + var j; + for (j = 1; j < argsLength; j++) if (!contains(arguments[j], item)) break; + if (j === argsLength) result$1.push(item); + } + return result$1; +} +var init_intersection = __esm({ "../../node_modules/underscore/modules/intersection.js"() { + init__getLength(); + init_contains(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/unzip.js +function unzip(array) { + var length = array && max(array, _getLength_default).length || 0; + var result$1 = Array(length); + for (var index$1 = 0; index$1 < length; index$1++) result$1[index$1] = pluck(array, index$1); + return result$1; +} +var init_unzip = __esm({ "../../node_modules/underscore/modules/unzip.js"() { + init_max(); + init__getLength(); + init_pluck(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/zip.js +var zip_default; +var init_zip = __esm({ "../../node_modules/underscore/modules/zip.js"() { + init_restArguments(); + init_unzip(); + zip_default = restArguments(unzip); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/object.js +function object$1(list$4, values$1) { + var result$1 = {}; + for (var i$5 = 0, length = _getLength_default(list$4); i$5 < length; i$5++) if (values$1) result$1[list$4[i$5]] = values$1[i$5]; + else result$1[list$4[i$5][0]] = list$4[i$5][1]; + return result$1; +} +var init_object = __esm({ "../../node_modules/underscore/modules/object.js"() { + init__getLength(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/range.js +function range$1(start, stop$1, step) { + if (stop$1 == null) { + stop$1 = start || 0; + start = 0; + } + if (!step) step = stop$1 < start ? -1 : 1; + var length = Math.max(Math.ceil((stop$1 - start) / step), 0); + var range$3 = Array(length); + for (var idx = 0; idx < length; idx++, start += step) range$3[idx] = start; + return range$3; +} +var init_range = __esm({ "../../node_modules/underscore/modules/range.js"() {} }); + +//#endregion +//#region ../../node_modules/underscore/modules/chunk.js +function chunk(array, count) { + if (count == null || count < 1) return []; + var result$1 = []; + var i$5 = 0, length = array.length; + while (i$5 < length) result$1.push(slice$1.call(array, i$5, i$5 += count)); + return result$1; +} +var init_chunk = __esm({ "../../node_modules/underscore/modules/chunk.js"() { + init__setup(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/_chainResult.js +function chainResult(instance, obj) { + return instance._chain ? _$1(obj).chain() : obj; +} +var init__chainResult = __esm({ "../../node_modules/underscore/modules/_chainResult.js"() { + init_underscore(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/mixin.js +function mixin(obj) { + each(functions(obj), function(name) { + var func = _$1[name] = obj[name]; + _$1.prototype[name] = function() { + var args = [this._wrapped]; + push.apply(args, arguments); + return chainResult(this, func.apply(_$1, args)); + }; + }); + return _$1; +} +var init_mixin = __esm({ "../../node_modules/underscore/modules/mixin.js"() { + init_underscore(); + init_each(); + init_functions(); + init__setup(); + init__chainResult(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/underscore-array-methods.js +var underscore_array_methods_default; +var init_underscore_array_methods = __esm({ "../../node_modules/underscore/modules/underscore-array-methods.js"() { + init_underscore(); + init_each(); + init__setup(); + init__chainResult(); + each([ + "pop", + "push", + "reverse", + "shift", + "sort", + "splice", + "unshift" + ], function(name) { + var method = ArrayProto[name]; + _$1.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) { + method.apply(obj, arguments); + if ((name === "shift" || name === "splice") && obj.length === 0) delete obj[0]; + } + return chainResult(this, obj); + }; + }); + each([ + "concat", + "join", + "slice" + ], function(name) { + var method = ArrayProto[name]; + _$1.prototype[name] = function() { + var obj = this._wrapped; + if (obj != null) obj = method.apply(obj, arguments); + return chainResult(this, obj); + }; + }); + underscore_array_methods_default = _$1; +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/index.js +var modules_exports = {}; +__export(modules_exports, { + VERSION: () => VERSION, + after: () => after, + all: () => every, + allKeys: () => allKeys, + any: () => some, + assign: () => extendOwn_default, + before: () => before, + bind: () => bind_default, + bindAll: () => bindAll_default, + chain: () => chain$1, + chunk: () => chunk, + clone: () => clone$1, + collect: () => map, + compact: () => compact, + compose: () => compose$1, + constant: () => constant, + contains: () => contains, + countBy: () => countBy_default, + create: () => create$3, + debounce: () => debounce, + default: () => underscore_array_methods_default, + defaults: () => defaults_default, + defer: () => defer_default, + delay: () => delay_default, + detect: () => find$2, + difference: () => difference_default, + drop: () => rest, + each: () => each, + escape: () => escape_default, + every: () => every, + extend: () => extend_default, + extendOwn: () => extendOwn_default, + filter: () => filter$2, + find: () => find$2, + findIndex: () => findIndex_default, + findKey: () => findKey, + findLastIndex: () => findLastIndex_default, + findWhere: () => findWhere, + first: () => first, + flatten: () => flatten, + foldl: () => reduce_default, + foldr: () => reduceRight_default, + forEach: () => each, + functions: () => functions, + get: () => get$1, + groupBy: () => groupBy_default, + has: () => has, + head: () => first, + identity: () => identity, + include: () => contains, + includes: () => contains, + indexBy: () => indexBy_default, + indexOf: () => indexOf_default, + initial: () => initial, + inject: () => reduce_default, + intersection: () => intersection, + invert: () => invert, + invoke: () => invoke_default, + isArguments: () => isArguments_default, + isArray: () => isArray_default, + isArrayBuffer: () => isArrayBuffer_default, + isBoolean: () => isBoolean, + isDataView: () => isDataView_default, + isDate: () => isDate_default, + isElement: () => isElement, + isEmpty: () => isEmpty, + isEqual: () => isEqual, + isError: () => isError_default, + isFinite: () => isFinite$1, + isFunction: () => isFunction_default, + isMap: () => isMap_default, + isMatch: () => isMatch, + isNaN: () => isNaN$1, + isNull: () => isNull, + isNumber: () => isNumber_default, + isObject: () => isObject$2, + isRegExp: () => isRegExp_default, + isSet: () => isSet_default, + isString: () => isString_default, + isSymbol: () => isSymbol_default, + isTypedArray: () => isTypedArray_default, + isUndefined: () => isUndefined, + isWeakMap: () => isWeakMap_default, + isWeakSet: () => isWeakSet_default, + iteratee: () => iteratee, + keys: () => keys$1, + last: () => last$1, + lastIndexOf: () => lastIndexOf_default, + map: () => map, + mapObject: () => mapObject, + matcher: () => matcher, + matches: () => matcher, + max: () => max, + memoize: () => memoize, + methods: () => functions, + min: () => min, + mixin: () => mixin, + negate: () => negate, + noop: () => noop$1, + now: () => now_default, + object: () => object$1, + omit: () => omit_default, + once: () => once_default, + pairs: () => pairs, + partial: () => partial_default, + partition: () => partition_default, + pick: () => pick_default, + pluck: () => pluck, + property: () => property, + propertyOf: () => propertyOf, + random: () => random, + range: () => range$1, + reduce: () => reduce_default, + reduceRight: () => reduceRight_default, + reject: () => reject, + rest: () => rest, + restArguments: () => restArguments, + result: () => result, + sample: () => sample, + select: () => filter$2, + shuffle: () => shuffle, + size: () => size, + some: () => some, + sortBy: () => sortBy, + sortedIndex: () => sortedIndex, + tail: () => rest, + take: () => first, + tap: () => tap, + template: () => template, + templateSettings: () => templateSettings_default, + throttle: () => throttle, + times: () => times, + toArray: () => toArray, + toPath: () => toPath, + transpose: () => unzip, + unescape: () => unescape_default, + union: () => union_default, + uniq: () => uniq, + unique: () => uniq, + uniqueId: () => uniqueId, + unzip: () => unzip, + values: () => values, + where: () => where, + without: () => without_default, + wrap: () => wrap, + zip: () => zip_default +}); +var init_modules = __esm({ "../../node_modules/underscore/modules/index.js"() { + init__setup(); + init_restArguments(); + init_isObject(); + init_isNull(); + init_isUndefined(); + init_isBoolean(); + init_isElement(); + init_isString(); + init_isNumber(); + init_isDate(); + init_isRegExp(); + init_isError(); + init_isSymbol(); + init_isArrayBuffer(); + init_isDataView(); + init_isArray(); + init_isFunction(); + init_isArguments(); + init_isFinite(); + init_isNaN(); + init_isTypedArray(); + init_isEmpty(); + init_isMatch(); + init_isEqual(); + init_isMap(); + init_isWeakMap(); + init_isSet(); + init_isWeakSet(); + init_keys(); + init_allKeys(); + init_values(); + init_pairs(); + init_invert(); + init_functions(); + init_extend(); + init_extendOwn(); + init_defaults(); + init_create(); + init_clone(); + init_tap(); + init_get(); + init_has(); + init_mapObject(); + init_identity(); + init_constant(); + init_noop(); + init_toPath(); + init_property(); + init_propertyOf(); + init_matcher(); + init_times(); + init_random(); + init_now(); + init_escape(); + init_unescape(); + init_templateSettings(); + init_template(); + init_result(); + init_uniqueId(); + init_chain(); + init_iteratee(); + init_partial(); + init_bind(); + init_bindAll(); + init_memoize(); + init_delay(); + init_defer(); + init_throttle(); + init_debounce(); + init_wrap(); + init_negate(); + init_compose(); + init_after(); + init_before(); + init_once(); + init_findKey(); + init_findIndex(); + init_findLastIndex(); + init_sortedIndex(); + init_indexOf(); + init_lastIndexOf(); + init_find(); + init_findWhere(); + init_each(); + init_map(); + init_reduce(); + init_reduceRight(); + init_filter(); + init_reject(); + init_every(); + init_some(); + init_contains(); + init_invoke(); + init_pluck(); + init_where(); + init_max(); + init_min(); + init_shuffle(); + init_sample(); + init_sortBy(); + init_groupBy(); + init_indexBy(); + init_countBy(); + init_partition(); + init_toArray(); + init_size(); + init_pick(); + init_omit(); + init_first(); + init_initial(); + init_last(); + init_rest(); + init_compact(); + init_flatten(); + init_without(); + init_uniq(); + init_union(); + init_intersection(); + init_difference(); + init_unzip(); + init_zip(); + init_object(); + init_range(); + init_chunk(); + init_mixin(); + init_underscore_array_methods(); +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/index-default.js +var _, index_default_default; +var init_index_default = __esm({ "../../node_modules/underscore/modules/index-default.js"() { + init_modules(); + _ = mixin(modules_exports); + _._ = _; + index_default_default = _; +} }); + +//#endregion +//#region ../../node_modules/underscore/modules/index-all.js +var index_all_exports = {}; +__export(index_all_exports, { + VERSION: () => VERSION, + after: () => after, + all: () => every, + allKeys: () => allKeys, + any: () => some, + assign: () => extendOwn_default, + before: () => before, + bind: () => bind_default, + bindAll: () => bindAll_default, + chain: () => chain$1, + chunk: () => chunk, + clone: () => clone$1, + collect: () => map, + compact: () => compact, + compose: () => compose$1, + constant: () => constant, + contains: () => contains, + countBy: () => countBy_default, + create: () => create$3, + debounce: () => debounce, + default: () => index_default_default, + defaults: () => defaults_default, + defer: () => defer_default, + delay: () => delay_default, + detect: () => find$2, + difference: () => difference_default, + drop: () => rest, + each: () => each, + escape: () => escape_default, + every: () => every, + extend: () => extend_default, + extendOwn: () => extendOwn_default, + filter: () => filter$2, + find: () => find$2, + findIndex: () => findIndex_default, + findKey: () => findKey, + findLastIndex: () => findLastIndex_default, + findWhere: () => findWhere, + first: () => first, + flatten: () => flatten, + foldl: () => reduce_default, + foldr: () => reduceRight_default, + forEach: () => each, + functions: () => functions, + get: () => get$1, + groupBy: () => groupBy_default, + has: () => has, + head: () => first, + identity: () => identity, + include: () => contains, + includes: () => contains, + indexBy: () => indexBy_default, + indexOf: () => indexOf_default, + initial: () => initial, + inject: () => reduce_default, + intersection: () => intersection, + invert: () => invert, + invoke: () => invoke_default, + isArguments: () => isArguments_default, + isArray: () => isArray_default, + isArrayBuffer: () => isArrayBuffer_default, + isBoolean: () => isBoolean, + isDataView: () => isDataView_default, + isDate: () => isDate_default, + isElement: () => isElement, + isEmpty: () => isEmpty, + isEqual: () => isEqual, + isError: () => isError_default, + isFinite: () => isFinite$1, + isFunction: () => isFunction_default, + isMap: () => isMap_default, + isMatch: () => isMatch, + isNaN: () => isNaN$1, + isNull: () => isNull, + isNumber: () => isNumber_default, + isObject: () => isObject$2, + isRegExp: () => isRegExp_default, + isSet: () => isSet_default, + isString: () => isString_default, + isSymbol: () => isSymbol_default, + isTypedArray: () => isTypedArray_default, + isUndefined: () => isUndefined, + isWeakMap: () => isWeakMap_default, + isWeakSet: () => isWeakSet_default, + iteratee: () => iteratee, + keys: () => keys$1, + last: () => last$1, + lastIndexOf: () => lastIndexOf_default, + map: () => map, + mapObject: () => mapObject, + matcher: () => matcher, + matches: () => matcher, + max: () => max, + memoize: () => memoize, + methods: () => functions, + min: () => min, + mixin: () => mixin, + negate: () => negate, + noop: () => noop$1, + now: () => now_default, + object: () => object$1, + omit: () => omit_default, + once: () => once_default, + pairs: () => pairs, + partial: () => partial_default, + partition: () => partition_default, + pick: () => pick_default, + pluck: () => pluck, + property: () => property, + propertyOf: () => propertyOf, + random: () => random, + range: () => range$1, + reduce: () => reduce_default, + reduceRight: () => reduceRight_default, + reject: () => reject, + rest: () => rest, + restArguments: () => restArguments, + result: () => result, + sample: () => sample, + select: () => filter$2, + shuffle: () => shuffle, + size: () => size, + some: () => some, + sortBy: () => sortBy, + sortedIndex: () => sortedIndex, + tail: () => rest, + take: () => first, + tap: () => tap, + template: () => template, + templateSettings: () => templateSettings_default, + throttle: () => throttle, + times: () => times, + toArray: () => toArray, + toPath: () => toPath, + transpose: () => unzip, + unescape: () => unescape_default, + union: () => union_default, + uniq: () => uniq, + unique: () => uniq, + uniqueId: () => uniqueId, + unzip: () => unzip, + values: () => values, + where: () => where, + without: () => without_default, + wrap: () => wrap, + zip: () => zip_default +}); +var init_index_all = __esm({ "../../node_modules/underscore/modules/index-all.js"() { + init_index_default(); + init_modules(); +} }); + +//#endregion +//#region node_modules/lodash/lodash.js +var require_lodash$1 = __commonJS({ "node_modules/lodash/lodash.js"(exports, module) { + (function() { + /** Used as a safe reference for `undefined` in pre-ES5 environments. */ + var undefined$1; + /** Used as the semantic version number. */ + var VERSION$2 = "4.17.21"; + /** Used as the size to enable large array optimizations. */ + var LARGE_ARRAY_SIZE = 200; + /** Error message constants. */ + var CORE_ERROR_TEXT = "Unsupported core-js use. Try https://npms.io/search?q=ponyfill.", FUNC_ERROR_TEXT = "Expected a function", INVALID_TEMPL_VAR_ERROR_TEXT = "Invalid `variable` option passed into `_.template`"; + /** Used to stand-in for `undefined` hash values. */ + var HASH_UNDEFINED = "__lodash_hash_undefined__"; + /** Used as the maximum memoize cache size. */ + var MAX_MEMOIZE_SIZE = 500; + /** Used as the internal argument placeholder. */ + var PLACEHOLDER = "__lodash_placeholder__"; + /** Used to compose bitmasks for cloning. */ + var CLONE_DEEP_FLAG = 1, CLONE_FLAT_FLAG = 2, CLONE_SYMBOLS_FLAG = 4; + /** Used to compose bitmasks for value comparisons. */ + var COMPARE_PARTIAL_FLAG = 1, COMPARE_UNORDERED_FLAG = 2; + /** Used to compose bitmasks for function metadata. */ + var WRAP_BIND_FLAG = 1, WRAP_BIND_KEY_FLAG = 2, WRAP_CURRY_BOUND_FLAG = 4, WRAP_CURRY_FLAG = 8, WRAP_CURRY_RIGHT_FLAG = 16, WRAP_PARTIAL_FLAG = 32, WRAP_PARTIAL_RIGHT_FLAG = 64, WRAP_ARY_FLAG = 128, WRAP_REARG_FLAG = 256, WRAP_FLIP_FLAG = 512; + /** Used as default options for `_.truncate`. */ + var DEFAULT_TRUNC_LENGTH = 30, DEFAULT_TRUNC_OMISSION = "..."; + /** Used to detect hot functions by number of calls within a span of milliseconds. */ + var HOT_COUNT = 800, HOT_SPAN = 16; + /** Used to indicate the type of lazy iteratees. */ + var LAZY_FILTER_FLAG = 1, LAZY_MAP_FLAG = 2, LAZY_WHILE_FLAG = 3; + /** Used as references for various `Number` constants. */ + var INFINITY$1 = Infinity, MAX_SAFE_INTEGER = 9007199254740991, MAX_INTEGER = 17976931348623157e292, NAN = NaN; + /** Used as references for the maximum length and index of an array. */ + var MAX_ARRAY_LENGTH = 4294967295, MAX_ARRAY_INDEX$1 = MAX_ARRAY_LENGTH - 1, HALF_MAX_ARRAY_LENGTH = MAX_ARRAY_LENGTH >>> 1; + /** Used to associate wrap methods with their bit flags. */ + var wrapFlags = [ + ["ary", WRAP_ARY_FLAG], + ["bind", WRAP_BIND_FLAG], + ["bindKey", WRAP_BIND_KEY_FLAG], + ["curry", WRAP_CURRY_FLAG], + ["curryRight", WRAP_CURRY_RIGHT_FLAG], + ["flip", WRAP_FLIP_FLAG], + ["partial", WRAP_PARTIAL_FLAG], + ["partialRight", WRAP_PARTIAL_RIGHT_FLAG], + ["rearg", WRAP_REARG_FLAG] + ]; + /** `Object#toString` result references. */ + var argsTag = "[object Arguments]", arrayTag = "[object Array]", asyncTag = "[object AsyncFunction]", boolTag = "[object Boolean]", dateTag = "[object Date]", domExcTag = "[object DOMException]", errorTag = "[object Error]", funcTag = "[object Function]", genTag = "[object GeneratorFunction]", mapTag = "[object Map]", numberTag = "[object Number]", nullTag = "[object Null]", objectTag = "[object Object]", promiseTag = "[object Promise]", proxyTag = "[object Proxy]", regexpTag = "[object RegExp]", setTag = "[object Set]", stringTag = "[object String]", symbolTag$1 = "[object Symbol]", undefinedTag = "[object Undefined]", weakMapTag = "[object WeakMap]", weakSetTag = "[object WeakSet]"; + 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 match empty string literals in compiled template source. */ + var reEmptyStringLeading = /\b__p \+= '';/g, reEmptyStringMiddle = /\b(__p \+=) '' \+/g, reEmptyStringTrailing = /(__e\(.*?\)|\b__t\)) \+\n'';/g; + /** Used to match HTML entities and HTML characters. */ + var reEscapedHtml = /&(?:amp|lt|gt|quot|#39);/g, reUnescapedHtml = /[&<>"']/g, reHasEscapedHtml = RegExp(reEscapedHtml.source), reHasUnescapedHtml = RegExp(reUnescapedHtml.source); + /** Used to match template delimiters. */ + var reEscape = /<%-([\s\S]+?)%>/g, reEvaluate = /<%([\s\S]+?)%>/g, reInterpolate = /<%=([\s\S]+?)%>/g; + /** Used to match property names within property paths. */ + var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, reIsPlainProp = /^\w*$/, rePropName = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g; + /** + * Used to match `RegExp` + * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns). + */ + var reRegExpChar = /[\\^$.*+?()[\]{}|]/g, reHasRegExpChar = RegExp(reRegExpChar.source); + /** Used to match leading whitespace. */ + var reTrimStart = /^\s+/; + /** Used to match a single whitespace character. */ + var reWhitespace$2 = /\s/; + /** Used to match wrap detail comments. */ + var reWrapComment = /\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/, reWrapDetails = /\{\n\/\* \[wrapped with (.+)\] \*/, reSplitDetails = /,? & /; + /** Used to match words composed of alphanumeric characters. */ + var reAsciiWord$1 = /[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g; + /** + * Used to validate the `validate` option in `_.template` variable. + * + * Forbids characters which could potentially change the meaning of the function argument definition: + * - "()," (modification of function parameters) + * - "=" (default value) + * - "[]{}" (destructuring of function parameters) + * - "/" (beginning of a comment) + * - whitespace + */ + var reForbiddenIdentifierChars = /[()=,{}\[\]\/\s]/; + /** Used to match backslashes in property paths. */ + var reEscapeChar = /\\(\\)?/g; + /** + * Used to match + * [ES template delimiters](http://ecma-international.org/ecma-262/7.0/#sec-template-literal-lexical-components). + */ + var reEsTemplate = /\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g; + /** Used to match `RegExp` flags from their coerced string values. */ + var reFlags = /\w*$/; + /** 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; + /** Used to detect host constructors (Safari). */ + var reIsHostCtor = /^\[object .+?Constructor\]$/; + /** Used to detect octal string values. */ + var reIsOctal = /^0o[0-7]+$/i; + /** Used to detect unsigned integer values. */ + var reIsUint = /^(?:0|[1-9]\d*)$/; + /** Used to match Latin Unicode letters (excluding mathematical operators). */ + var reLatin$1 = /[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g; + /** Used to ensure capturing order of template delimiters. */ + var reNoMatch = /($^)/; + /** Used to match unescaped characters in compiled string literals. */ + var reUnescapedString = /['\n\r\u2028\u2029\\]/g; + /** Used to compose unicode character classes. */ + var rsAstralRange$1 = "\\ud800-\\udfff", rsComboMarksRange$1 = "\\u0300-\\u036f", reComboHalfMarksRange = "\\ufe20-\\ufe2f", rsComboSymbolsRange$1 = "\\u20d0-\\u20ff", rsComboRange = rsComboMarksRange$1 + reComboHalfMarksRange + rsComboSymbolsRange$1, rsDingbatRange$1 = "\\u2700-\\u27bf", rsLowerRange$1 = "a-z\\xdf-\\xf6\\xf8-\\xff", rsMathOpRange$1 = "\\xac\\xb1\\xd7\\xf7", rsNonCharRange$1 = "\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf", rsPunctuationRange$1 = "\\u2000-\\u206f", rsSpaceRange$1 = " \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000", rsUpperRange$1 = "A-Z\\xc0-\\xd6\\xd8-\\xde", rsVarRange$1 = "\\ufe0e\\ufe0f", rsBreakRange$1 = rsMathOpRange$1 + rsNonCharRange$1 + rsPunctuationRange$1 + rsSpaceRange$1; + /** Used to compose unicode capture groups. */ + var rsApos$1 = "['’]", rsAstral$1 = "[" + rsAstralRange$1 + "]", rsBreak$1 = "[" + rsBreakRange$1 + "]", rsCombo$1 = "[" + rsComboRange + "]", rsDigits$1 = "\\d+", rsDingbat$1 = "[" + rsDingbatRange$1 + "]", rsLower$1 = "[" + rsLowerRange$1 + "]", rsMisc$1 = "[^" + rsAstralRange$1 + rsBreakRange$1 + rsDigits$1 + rsDingbatRange$1 + rsLowerRange$1 + rsUpperRange$1 + "]", rsFitz$1 = "\\ud83c[\\udffb-\\udfff]", rsModifier$1 = "(?:" + rsCombo$1 + "|" + rsFitz$1 + ")", rsNonAstral$1 = "[^" + rsAstralRange$1 + "]", rsRegional$1 = "(?:\\ud83c[\\udde6-\\uddff]){2}", rsSurrPair$1 = "[\\ud800-\\udbff][\\udc00-\\udfff]", rsUpper$1 = "[" + rsUpperRange$1 + "]", rsZWJ$1 = "\\u200d"; + /** Used to compose unicode regexes. */ + var rsMiscLower = "(?:" + rsLower$1 + "|" + rsMisc$1 + ")", rsMiscUpper = "(?:" + rsUpper$1 + "|" + rsMisc$1 + ")", rsOptContrLower = "(?:" + rsApos$1 + "(?:d|ll|m|re|s|t|ve))?", rsOptContrUpper = "(?:" + rsApos$1 + "(?:D|LL|M|RE|S|T|VE))?", reOptMod$1 = rsModifier$1 + "?", rsOptVar$1 = "[" + rsVarRange$1 + "]?", rsOptJoin$1 = "(?:" + rsZWJ$1 + "(?:" + [ + rsNonAstral$1, + rsRegional$1, + rsSurrPair$1 + ].join("|") + ")" + rsOptVar$1 + reOptMod$1 + ")*", rsOrdLower = "\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])", rsOrdUpper = "\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])", rsSeq$1 = rsOptVar$1 + reOptMod$1 + rsOptJoin$1, rsEmoji$1 = "(?:" + [ + rsDingbat$1, + rsRegional$1, + rsSurrPair$1 + ].join("|") + ")" + rsSeq$1, rsSymbol$1 = "(?:" + [ + rsNonAstral$1 + rsCombo$1 + "?", + rsCombo$1, + rsRegional$1, + rsSurrPair$1, + rsAstral$1 + ].join("|") + ")"; + /** Used to match apostrophes. */ + var reApos$1 = RegExp(rsApos$1, "g"); + /** + * Used to match [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks) and + * [combining diacritical marks for symbols](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks_for_Symbols). + */ + var reComboMark$1 = RegExp(rsCombo$1, "g"); + /** Used to match [string symbols](https://mathiasbynens.be/notes/javascript-unicode). */ + var reUnicode$1 = RegExp(rsFitz$1 + "(?=" + rsFitz$1 + ")|" + rsSymbol$1 + rsSeq$1, "g"); + /** Used to match complex or compound words. */ + var reUnicodeWord$1 = RegExp([ + rsUpper$1 + "?" + rsLower$1 + "+" + rsOptContrLower + "(?=" + [ + rsBreak$1, + rsUpper$1, + "$" + ].join("|") + ")", + rsMiscUpper + "+" + rsOptContrUpper + "(?=" + [ + rsBreak$1, + rsUpper$1 + rsMiscLower, + "$" + ].join("|") + ")", + rsUpper$1 + "?" + rsMiscLower + "+" + rsOptContrLower, + rsUpper$1 + "+" + rsOptContrUpper, + rsOrdUpper, + rsOrdLower, + rsDigits$1, + rsEmoji$1 + ].join("|"), "g"); + /** Used to detect strings with [zero-width joiners or code points from the astral planes](http://eev.ee/blog/2015/09/12/dark-corners-of-unicode/). */ + var reHasUnicode$1 = RegExp("[" + rsZWJ$1 + rsAstralRange$1 + rsComboRange + rsVarRange$1 + "]"); + /** Used to detect strings that need a more robust regexp to match words. */ + var reHasUnicodeWord$1 = /[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/; + /** Used to assign default `context` object properties. */ + var contextProps = [ + "Array", + "Buffer", + "DataView", + "Date", + "Error", + "Float32Array", + "Float64Array", + "Function", + "Int8Array", + "Int16Array", + "Int32Array", + "Map", + "Math", + "Object", + "Promise", + "RegExp", + "Set", + "String", + "Symbol", + "TypeError", + "Uint8Array", + "Uint8ClampedArray", + "Uint16Array", + "Uint32Array", + "WeakMap", + "_", + "clearTimeout", + "isFinite", + "parseInt", + "setTimeout" + ]; + /** Used to make template sourceURLs easier to identify. */ + var templateCounter = -1; + /** 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; + /** Used to identify `toStringTag` values supported by `_.clone`. */ + var cloneableTags = {}; + cloneableTags[argsTag] = cloneableTags[arrayTag] = cloneableTags[arrayBufferTag] = cloneableTags[dataViewTag] = cloneableTags[boolTag] = cloneableTags[dateTag] = cloneableTags[float32Tag] = cloneableTags[float64Tag] = cloneableTags[int8Tag] = cloneableTags[int16Tag] = cloneableTags[int32Tag] = cloneableTags[mapTag] = cloneableTags[numberTag] = cloneableTags[objectTag] = cloneableTags[regexpTag] = cloneableTags[setTag] = cloneableTags[stringTag] = cloneableTags[symbolTag$1] = cloneableTags[uint8Tag] = cloneableTags[uint8ClampedTag] = cloneableTags[uint16Tag] = cloneableTags[uint32Tag] = true; + cloneableTags[errorTag] = cloneableTags[funcTag] = cloneableTags[weakMapTag] = false; + /** Used to map Latin Unicode letters to basic Latin letters. */ + var deburredLetters$1 = { + "À": "A", + "Á": "A", + "Â": "A", + "Ã": "A", + "Ä": "A", + "Å": "A", + "à": "a", + "á": "a", + "â": "a", + "ã": "a", + "ä": "a", + "å": "a", + "Ç": "C", + "ç": "c", + "Ð": "D", + "ð": "d", + "È": "E", + "É": "E", + "Ê": "E", + "Ë": "E", + "è": "e", + "é": "e", + "ê": "e", + "ë": "e", + "Ì": "I", + "Í": "I", + "Î": "I", + "Ï": "I", + "ì": "i", + "í": "i", + "î": "i", + "ï": "i", + "Ñ": "N", + "ñ": "n", + "Ò": "O", + "Ó": "O", + "Ô": "O", + "Õ": "O", + "Ö": "O", + "Ø": "O", + "ò": "o", + "ó": "o", + "ô": "o", + "õ": "o", + "ö": "o", + "ø": "o", + "Ù": "U", + "Ú": "U", + "Û": "U", + "Ü": "U", + "ù": "u", + "ú": "u", + "û": "u", + "ü": "u", + "Ý": "Y", + "ý": "y", + "ÿ": "y", + "Æ": "Ae", + "æ": "ae", + "Þ": "Th", + "þ": "th", + "ß": "ss", + "Ā": "A", + "Ă": "A", + "Ą": "A", + "ā": "a", + "ă": "a", + "ą": "a", + "Ć": "C", + "Ĉ": "C", + "Ċ": "C", + "Č": "C", + "ć": "c", + "ĉ": "c", + "ċ": "c", + "č": "c", + "Ď": "D", + "Đ": "D", + "ď": "d", + "đ": "d", + "Ē": "E", + "Ĕ": "E", + "Ė": "E", + "Ę": "E", + "Ě": "E", + "ē": "e", + "ĕ": "e", + "ė": "e", + "ę": "e", + "ě": "e", + "Ĝ": "G", + "Ğ": "G", + "Ġ": "G", + "Ģ": "G", + "ĝ": "g", + "ğ": "g", + "ġ": "g", + "ģ": "g", + "Ĥ": "H", + "Ħ": "H", + "ĥ": "h", + "ħ": "h", + "Ĩ": "I", + "Ī": "I", + "Ĭ": "I", + "Į": "I", + "İ": "I", + "ĩ": "i", + "ī": "i", + "ĭ": "i", + "į": "i", + "ı": "i", + "Ĵ": "J", + "ĵ": "j", + "Ķ": "K", + "ķ": "k", + "ĸ": "k", + "Ĺ": "L", + "Ļ": "L", + "Ľ": "L", + "Ŀ": "L", + "Ł": "L", + "ĺ": "l", + "ļ": "l", + "ľ": "l", + "ŀ": "l", + "ł": "l", + "Ń": "N", + "Ņ": "N", + "Ň": "N", + "Ŋ": "N", + "ń": "n", + "ņ": "n", + "ň": "n", + "ŋ": "n", + "Ō": "O", + "Ŏ": "O", + "Ő": "O", + "ō": "o", + "ŏ": "o", + "ő": "o", + "Ŕ": "R", + "Ŗ": "R", + "Ř": "R", + "ŕ": "r", + "ŗ": "r", + "ř": "r", + "Ś": "S", + "Ŝ": "S", + "Ş": "S", + "Š": "S", + "ś": "s", + "ŝ": "s", + "ş": "s", + "š": "s", + "Ţ": "T", + "Ť": "T", + "Ŧ": "T", + "ţ": "t", + "ť": "t", + "ŧ": "t", + "Ũ": "U", + "Ū": "U", + "Ŭ": "U", + "Ů": "U", + "Ű": "U", + "Ų": "U", + "ũ": "u", + "ū": "u", + "ŭ": "u", + "ů": "u", + "ű": "u", + "ų": "u", + "Ŵ": "W", + "ŵ": "w", + "Ŷ": "Y", + "ŷ": "y", + "Ÿ": "Y", + "Ź": "Z", + "Ż": "Z", + "Ž": "Z", + "ź": "z", + "ż": "z", + "ž": "z", + "IJ": "IJ", + "ij": "ij", + "Œ": "Oe", + "œ": "oe", + "ʼn": "'n", + "ſ": "s" + }; + /** Used to map characters to HTML entities. */ + var htmlEscapes = { + "&": "&", + "<": "<", + ">": ">", + "\"": """, + "'": "'" + }; + /** Used to map HTML entities to characters. */ + var htmlUnescapes = { + "&": "&", + "<": "<", + ">": ">", + """: "\"", + "'": "'" + }; + /** Used to escape characters for inclusion in compiled string literals. */ + var stringEscapes = { + "\\": "\\", + "'": "'", + "\n": "n", + "\r": "r", + "\u2028": "u2028", + "\u2029": "u2029" + }; + /** Built-in method references without a dependency on `root`. */ + var freeParseFloat = parseFloat, freeParseInt = parseInt; + /** Detect free variable `global` from Node.js. */ + var freeGlobal$1 = typeof global == "object" && global && global.Object === Object && global; + /** Detect free variable `self`. */ + var freeSelf$1 = typeof self == "object" && self && self.Object === Object && self; + /** Used as a reference to the global object. */ + var root$6 = freeGlobal$1 || freeSelf$1 || Function("return this")(); + /** Detect free variable `exports`. */ + var freeExports = typeof exports == "object" && exports && !exports.nodeType && exports; + /** Detect free variable `module`. */ + var freeModule = freeExports && typeof module == "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$1.process; + /** Used to access faster Node.js helpers. */ + var nodeUtil = function() { + try { + var types$7 = freeModule && freeModule.require && freeModule.require("util").types; + if (types$7) return types$7; + return freeProcess && freeProcess.binding && freeProcess.binding("util"); + } catch (e) {} + }(); + var nodeIsArrayBuffer = nodeUtil && nodeUtil.isArrayBuffer, nodeIsDate = nodeUtil && nodeUtil.isDate, nodeIsMap = nodeUtil && nodeUtil.isMap, nodeIsRegExp = nodeUtil && nodeUtil.isRegExp, nodeIsSet = nodeUtil && nodeUtil.isSet, nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray; + /** + * 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); + } + /** + * A specialized version of `baseAggregator` for arrays. + * + * @private + * @param {Array} [array] The array to iterate over. + * @param {Function} setter The function to set `accumulator` values. + * @param {Function} iteratee The iteratee to transform keys. + * @param {Object} accumulator The initial aggregated object. + * @returns {Function} Returns `accumulator`. + */ + function arrayAggregator(array, setter, iteratee$1, accumulator) { + var index$1 = -1, length = array == null ? 0 : array.length; + while (++index$1 < length) { + var value = array[index$1]; + setter(accumulator, value, iteratee$1(value), array); + } + return accumulator; + } + /** + * A specialized version of `_.forEach` 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 `array`. + */ + function arrayEach(array, iteratee$1) { + var index$1 = -1, length = array == null ? 0 : array.length; + while (++index$1 < length) if (iteratee$1(array[index$1], index$1, array) === false) break; + return array; + } + /** + * A specialized version of `_.forEachRight` 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 `array`. + */ + function arrayEachRight(array, iteratee$1) { + var length = array == null ? 0 : array.length; + while (length--) if (iteratee$1(array[length], length, array) === false) break; + return array; + } + /** + * A specialized version of `_.every` for arrays without support for + * iteratee shorthands. + * + * @private + * @param {Array} [array] The array to iterate over. + * @param {Function} predicate The function invoked per iteration. + * @returns {boolean} Returns `true` if all elements pass the predicate check, + * else `false`. + */ + function arrayEvery(array, predicate) { + var index$1 = -1, length = array == null ? 0 : array.length; + while (++index$1 < length) if (!predicate(array[index$1], index$1, array)) return false; + return true; + } + /** + * A specialized version of `_.filter` for arrays without support for + * iteratee shorthands. + * + * @private + * @param {Array} [array] The array to iterate over. + * @param {Function} predicate The function invoked per iteration. + * @returns {Array} Returns the new filtered array. + */ + function arrayFilter(array, predicate) { + var index$1 = -1, length = array == null ? 0 : array.length, resIndex = 0, result$1 = []; + while (++index$1 < length) { + var value = array[index$1]; + if (predicate(value, index$1, array)) result$1[resIndex++] = value; + } + return result$1; + } + /** + * 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; + } + /** + * 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 = -1, length = array == null ? 0 : array.length; + while (++index$1 < length) if (comparator(value, array[index$1])) return true; + return false; + } + /** + * 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$1) { + var index$1 = -1, length = array == null ? 0 : array.length, result$1 = Array(length); + while (++index$1 < length) result$1[index$1] = iteratee$1(array[index$1], index$1, array); + return result$1; + } + /** + * 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$1) { + var index$1 = -1, length = values$1.length, offset = array.length; + while (++index$1 < length) array[offset + index$1] = values$1[index$1]; + return array; + } + /** + * A specialized version of `_.reduce` for arrays without support for + * iteratee shorthands. + * + * @private + * @param {Array} [array] The array to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @param {*} [accumulator] The initial value. + * @param {boolean} [initAccum] Specify using the first element of `array` as + * the initial value. + * @returns {*} Returns the accumulated value. + */ + function arrayReduce$1(array, iteratee$1, accumulator, initAccum) { + var index$1 = -1, length = array == null ? 0 : array.length; + if (initAccum && length) accumulator = array[++index$1]; + while (++index$1 < length) accumulator = iteratee$1(accumulator, array[index$1], index$1, array); + return accumulator; + } + /** + * A specialized version of `_.reduceRight` for arrays without support for + * iteratee shorthands. + * + * @private + * @param {Array} [array] The array to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @param {*} [accumulator] The initial value. + * @param {boolean} [initAccum] Specify using the last element of `array` as + * the initial value. + * @returns {*} Returns the accumulated value. + */ + function arrayReduceRight(array, iteratee$1, accumulator, initAccum) { + var length = array == null ? 0 : array.length; + if (initAccum && length) accumulator = array[--length]; + while (length--) accumulator = iteratee$1(accumulator, array[length], length, array); + return accumulator; + } + /** + * A specialized version of `_.some` for arrays without support for iteratee + * shorthands. + * + * @private + * @param {Array} [array] The array to iterate over. + * @param {Function} predicate The function invoked per iteration. + * @returns {boolean} Returns `true` if any element passes the predicate check, + * else `false`. + */ + function arraySome(array, predicate) { + var index$1 = -1, length = array == null ? 0 : array.length; + while (++index$1 < length) if (predicate(array[index$1], index$1, array)) return true; + return false; + } + /** + * Gets the size of an ASCII `string`. + * + * @private + * @param {string} string The string inspect. + * @returns {number} Returns the string size. + */ + var asciiSize = baseProperty("length"); + /** + * Converts an ASCII `string` to an array. + * + * @private + * @param {string} string The string to convert. + * @returns {Array} Returns the converted array. + */ + function asciiToArray$1(string$3) { + return string$3.split(""); + } + /** + * Splits an ASCII `string` into an array of its words. + * + * @private + * @param {string} The string to inspect. + * @returns {Array} Returns the words of `string`. + */ + function asciiWords$1(string$3) { + return string$3.match(reAsciiWord$1) || []; + } + /** + * The base implementation of methods like `_.findKey` and `_.findLastKey`, + * without support for iteratee shorthands, which iterates over `collection` + * using `eachFunc`. + * + * @private + * @param {Array|Object} collection The collection to inspect. + * @param {Function} predicate The function invoked per iteration. + * @param {Function} eachFunc The function to iterate over `collection`. + * @returns {*} Returns the found element or its key, else `undefined`. + */ + function baseFindKey(collection, predicate, eachFunc) { + var result$1; + eachFunc(collection, function(value, key, collection$1) { + if (predicate(value, key, collection$1)) { + result$1 = key; + return false; + } + }); + return result$1; + } + /** + * 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$1 = fromIndex + (fromRight ? 1 : -1); + while (fromRight ? index$1-- : ++index$1 < length) if (predicate(array[index$1], index$1, array)) return index$1; + return -1; + } + /** + * 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); + } + /** + * This function is like `baseIndexOf` except that it accepts a comparator. + * + * @private + * @param {Array} array The array to inspect. + * @param {*} value The value to search for. + * @param {number} fromIndex The index to search from. + * @param {Function} comparator The comparator invoked per element. + * @returns {number} Returns the index of the matched value, else `-1`. + */ + function baseIndexOfWith(array, value, fromIndex, comparator) { + var index$1 = fromIndex - 1, length = array.length; + while (++index$1 < length) if (comparator(array[index$1], value)) return index$1; + return -1; + } + /** + * 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; + } + /** + * The base implementation of `_.mean` and `_.meanBy` without support for + * iteratee shorthands. + * + * @private + * @param {Array} array The array to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @returns {number} Returns the mean. + */ + function baseMean(array, iteratee$1) { + var length = array == null ? 0 : array.length; + return length ? baseSum(array, iteratee$1) / length : NAN; + } + /** + * The base implementation of `_.property` without support for deep paths. + * + * @private + * @param {string} key The key of the property to get. + * @returns {Function} Returns the new accessor function. + */ + function baseProperty(key) { + return function(object$3) { + return object$3 == null ? undefined$1 : object$3[key]; + }; + } + /** + * The base implementation of `_.propertyOf` without support for deep paths. + * + * @private + * @param {Object} object The object to query. + * @returns {Function} Returns the new accessor function. + */ + function basePropertyOf$1(object$3) { + return function(key) { + return object$3 == null ? undefined$1 : object$3[key]; + }; + } + /** + * The base implementation of `_.reduce` and `_.reduceRight`, without support + * for iteratee shorthands, which iterates over `collection` using `eachFunc`. + * + * @private + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @param {*} accumulator The initial value. + * @param {boolean} initAccum Specify using the first or last element of + * `collection` as the initial value. + * @param {Function} eachFunc The function to iterate over `collection`. + * @returns {*} Returns the accumulated value. + */ + function baseReduce(collection, iteratee$1, accumulator, initAccum, eachFunc) { + eachFunc(collection, function(value, index$1, collection$1) { + accumulator = initAccum ? (initAccum = false, value) : iteratee$1(accumulator, value, index$1, collection$1); + }); + return accumulator; + } + /** + * The base implementation of `_.sortBy` which uses `comparer` to define the + * sort order of `array` and replaces criteria objects with their corresponding + * values. + * + * @private + * @param {Array} array The array to sort. + * @param {Function} comparer The function to define sort order. + * @returns {Array} Returns `array`. + */ + function baseSortBy(array, comparer) { + var length = array.length; + array.sort(comparer); + while (length--) array[length] = array[length].value; + return array; + } + /** + * The base implementation of `_.sum` and `_.sumBy` without support for + * iteratee shorthands. + * + * @private + * @param {Array} array The array to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @returns {number} Returns the sum. + */ + function baseSum(array, iteratee$1) { + var result$1, index$1 = -1, length = array.length; + while (++index$1 < length) { + var current = iteratee$1(array[index$1]); + if (current !== undefined$1) result$1 = result$1 === undefined$1 ? current : result$1 + current; + } + return result$1; + } + /** + * 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$3, iteratee$1) { + var index$1 = -1, result$1 = Array(n$3); + while (++index$1 < n$3) result$1[index$1] = iteratee$1(index$1); + return result$1; + } + /** + * The base implementation of `_.toPairs` and `_.toPairsIn` which creates an array + * of key-value pairs for `object` 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 key-value pairs. + */ + function baseToPairs(object$3, props) { + return arrayMap(props, function(key) { + return [key, object$3[key]]; + }); + } + /** + * The base implementation of `_.trim`. + * + * @private + * @param {string} string The string to trim. + * @returns {string} Returns the trimmed string. + */ + function baseTrim(string$3) { + return string$3 ? string$3.slice(0, trimmedEndIndex(string$3) + 1).replace(reTrimStart, "") : string$3; + } + /** + * 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); + }; + } + /** + * 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$3, props) { + return arrayMap(props, function(key) { + return object$3[key]; + }); + } + /** + * 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$3, key) { + return cache$3.has(key); + } + /** + * Used by `_.trim` and `_.trimStart` to get the index of the first string symbol + * that is not found in the character symbols. + * + * @private + * @param {Array} strSymbols The string symbols to inspect. + * @param {Array} chrSymbols The character symbols to find. + * @returns {number} Returns the index of the first unmatched string symbol. + */ + function charsStartIndex(strSymbols, chrSymbols) { + var index$1 = -1, length = strSymbols.length; + while (++index$1 < length && baseIndexOf(chrSymbols, strSymbols[index$1], 0) > -1); + return index$1; + } + /** + * Used by `_.trim` and `_.trimEnd` to get the index of the last string symbol + * that is not found in the character symbols. + * + * @private + * @param {Array} strSymbols The string symbols to inspect. + * @param {Array} chrSymbols The character symbols to find. + * @returns {number} Returns the index of the last unmatched string symbol. + */ + function charsEndIndex(strSymbols, chrSymbols) { + var index$1 = strSymbols.length; + while (index$1-- && baseIndexOf(chrSymbols, strSymbols[index$1], 0) > -1); + return index$1; + } + /** + * Gets the number of `placeholder` occurrences in `array`. + * + * @private + * @param {Array} array The array to inspect. + * @param {*} placeholder The placeholder to search for. + * @returns {number} Returns the placeholder count. + */ + function countHolders(array, placeholder$1) { + var length = array.length, result$1 = 0; + while (length--) if (array[length] === placeholder$1) ++result$1; + return result$1; + } + /** + * Used by `_.deburr` to convert Latin-1 Supplement and Latin Extended-A + * letters to basic Latin letters. + * + * @private + * @param {string} letter The matched letter to deburr. + * @returns {string} Returns the deburred letter. + */ + var deburrLetter$1 = basePropertyOf$1(deburredLetters$1); + /** + * Used by `_.escape` to convert characters to HTML entities. + * + * @private + * @param {string} chr The matched character to escape. + * @returns {string} Returns the escaped character. + */ + var escapeHtmlChar = basePropertyOf$1(htmlEscapes); + /** + * Used by `_.template` to escape characters for inclusion in compiled string literals. + * + * @private + * @param {string} chr The matched character to escape. + * @returns {string} Returns the escaped character. + */ + function escapeStringChar(chr) { + return "\\" + stringEscapes[chr]; + } + /** + * Gets the value at `key` of `object`. + * + * @private + * @param {Object} [object] The object to query. + * @param {string} key The key of the property to get. + * @returns {*} Returns the property value. + */ + function getValue(object$3, key) { + return object$3 == null ? undefined$1 : object$3[key]; + } + /** + * Checks if `string` contains Unicode symbols. + * + * @private + * @param {string} string The string to inspect. + * @returns {boolean} Returns `true` if a symbol is found, else `false`. + */ + function hasUnicode$1(string$3) { + return reHasUnicode$1.test(string$3); + } + /** + * Checks if `string` contains a word composed of Unicode symbols. + * + * @private + * @param {string} string The string to inspect. + * @returns {boolean} Returns `true` if a word is found, else `false`. + */ + function hasUnicodeWord$1(string$3) { + return reHasUnicodeWord$1.test(string$3); + } + /** + * Converts `iterator` to an array. + * + * @private + * @param {Object} iterator The iterator to convert. + * @returns {Array} Returns the converted array. + */ + function iteratorToArray(iterator) { + var data$2, result$1 = []; + while (!(data$2 = iterator.next()).done) result$1.push(data$2.value); + return result$1; + } + /** + * Converts `map` to its key-value pairs. + * + * @private + * @param {Object} map The map to convert. + * @returns {Array} Returns the key-value pairs. + */ + function mapToArray(map$1) { + var index$1 = -1, result$1 = Array(map$1.size); + map$1.forEach(function(value, key) { + result$1[++index$1] = [key, value]; + }); + return result$1; + } + /** + * 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$1) { + return function(arg) { + return func(transform$1(arg)); + }; + } + /** + * Replaces all `placeholder` elements in `array` with an internal placeholder + * and returns an array of their indexes. + * + * @private + * @param {Array} array The array to modify. + * @param {*} placeholder The placeholder to replace. + * @returns {Array} Returns the new array of placeholder indexes. + */ + function replaceHolders(array, placeholder$1) { + var index$1 = -1, length = array.length, resIndex = 0, result$1 = []; + while (++index$1 < length) { + var value = array[index$1]; + if (value === placeholder$1 || value === PLACEHOLDER) { + array[index$1] = PLACEHOLDER; + result$1[resIndex++] = index$1; + } + } + return result$1; + } + /** + * 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 = -1, result$1 = Array(set.size); + set.forEach(function(value) { + result$1[++index$1] = value; + }); + return result$1; + } + /** + * Converts `set` to its value-value pairs. + * + * @private + * @param {Object} set The set to convert. + * @returns {Array} Returns the value-value pairs. + */ + function setToPairs(set) { + var index$1 = -1, result$1 = Array(set.size); + set.forEach(function(value) { + result$1[++index$1] = [value, value]; + }); + return result$1; + } + /** + * 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$1 = fromIndex - 1, length = array.length; + while (++index$1 < length) if (array[index$1] === value) return index$1; + return -1; + } + /** + * A specialized version of `_.lastIndexOf` 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 strictLastIndexOf(array, value, fromIndex) { + var index$1 = fromIndex + 1; + while (index$1--) if (array[index$1] === value) return index$1; + return index$1; + } + /** + * Gets the number of symbols in `string`. + * + * @private + * @param {string} string The string to inspect. + * @returns {number} Returns the string size. + */ + function stringSize(string$3) { + return hasUnicode$1(string$3) ? unicodeSize(string$3) : asciiSize(string$3); + } + /** + * Converts `string` to an array. + * + * @private + * @param {string} string The string to convert. + * @returns {Array} Returns the converted array. + */ + function stringToArray$1(string$3) { + return hasUnicode$1(string$3) ? unicodeToArray$1(string$3) : asciiToArray$1(string$3); + } + /** + * Used by `_.trim` and `_.trimEnd` to get the index of the last non-whitespace + * character of `string`. + * + * @private + * @param {string} string The string to inspect. + * @returns {number} Returns the index of the last non-whitespace character. + */ + function trimmedEndIndex(string$3) { + var index$1 = string$3.length; + while (index$1-- && reWhitespace$2.test(string$3.charAt(index$1))); + return index$1; + } + /** + * Used by `_.unescape` to convert HTML entities to characters. + * + * @private + * @param {string} chr The matched character to unescape. + * @returns {string} Returns the unescaped character. + */ + var unescapeHtmlChar = basePropertyOf$1(htmlUnescapes); + /** + * Gets the size of a Unicode `string`. + * + * @private + * @param {string} string The string inspect. + * @returns {number} Returns the string size. + */ + function unicodeSize(string$3) { + var result$1 = reUnicode$1.lastIndex = 0; + while (reUnicode$1.test(string$3)) ++result$1; + return result$1; + } + /** + * Converts a Unicode `string` to an array. + * + * @private + * @param {string} string The string to convert. + * @returns {Array} Returns the converted array. + */ + function unicodeToArray$1(string$3) { + return string$3.match(reUnicode$1) || []; + } + /** + * Splits a Unicode `string` into an array of its words. + * + * @private + * @param {string} The string to inspect. + * @returns {Array} Returns the words of `string`. + */ + function unicodeWords$1(string$3) { + return string$3.match(reUnicodeWord$1) || []; + } + /** + * Create a new pristine `lodash` function using the `context` object. + * + * @static + * @memberOf _ + * @since 1.1.0 + * @category Util + * @param {Object} [context=root] The context object. + * @returns {Function} Returns a new `lodash` function. + * @example + * + * _.mixin({ 'foo': _.constant('foo') }); + * + * var lodash = _.runInContext(); + * lodash.mixin({ 'bar': lodash.constant('bar') }); + * + * _.isFunction(_.foo); + * // => true + * _.isFunction(_.bar); + * // => false + * + * lodash.isFunction(lodash.foo); + * // => false + * lodash.isFunction(lodash.bar); + * // => true + * + * // Create a suped-up `defer` in Node.js. + * var defer = _.runInContext({ 'setTimeout': setImmediate }).defer; + */ + var runInContext = function runInContext$1(context) { + context = context == null ? root$6 : _$2.defaults(root$6.Object(), context, _$2.pick(root$6, contextProps)); + /** Built-in constructor references. */ + var Array$1 = context.Array, Date$1 = context.Date, Error$1 = context.Error, Function$1 = context.Function, Math$1 = context.Math, Object$1 = context.Object, RegExp$1 = context.RegExp, String$4 = context.String, TypeError$1 = context.TypeError; + /** Used for built-in method references. */ + var arrayProto = Array$1.prototype, funcProto = Function$1.prototype, objectProto$1 = Object$1.prototype; + /** Used to detect overreaching core-js shims. */ + var coreJsData = context["__core-js_shared__"]; + /** Used to resolve the decompiled source of functions. */ + var funcToString = funcProto.toString; + /** Used to check objects for own properties. */ + var hasOwnProperty$6 = objectProto$1.hasOwnProperty; + /** Used to generate unique IDs. */ + var idCounter$1 = 0; + /** Used to detect methods masquerading as native. */ + var maskSrcKey = function() { + var uid$1 = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || ""); + return uid$1 ? "Symbol(src)_1." + uid$1 : ""; + }(); + /** + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) + * of values. + */ + var nativeObjectToString = objectProto$1.toString; + /** Used to infer the `Object` constructor. */ + var objectCtorString = funcToString.call(Object$1); + /** Used to restore the original `_` reference in `_.noConflict`. */ + var oldDash = root$6._; + /** Used to detect if a method is native. */ + var reIsNative = RegExp$1("^" + funcToString.call(hasOwnProperty$6).replace(reRegExpChar, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"); + /** Built-in value references. */ + var Buffer$2 = moduleExports ? context.Buffer : undefined$1, Symbol$2 = context.Symbol, Uint8Array$1 = context.Uint8Array, allocUnsafe = Buffer$2 ? Buffer$2.allocUnsafe : undefined$1, getPrototype = overArg(Object$1.getPrototypeOf, Object$1), objectCreate = Object$1.create, propertyIsEnumerable = objectProto$1.propertyIsEnumerable, splice = arrayProto.splice, spreadableSymbol = Symbol$2 ? Symbol$2.isConcatSpreadable : undefined$1, symIterator = Symbol$2 ? Symbol$2.iterator : undefined$1, symToStringTag = Symbol$2 ? Symbol$2.toStringTag : undefined$1; + var defineProperty$1 = function() { + try { + var func = getNative(Object$1, "defineProperty"); + func({}, "", {}); + return func; + } catch (e) {} + }(); + /** Mocked built-ins. */ + var ctxClearTimeout = context.clearTimeout !== root$6.clearTimeout && context.clearTimeout, ctxNow = Date$1 && Date$1.now !== root$6.Date.now && Date$1.now, ctxSetTimeout = context.setTimeout !== root$6.setTimeout && context.setTimeout; + var nativeCeil = Math$1.ceil, nativeFloor = Math$1.floor, nativeGetSymbols = Object$1.getOwnPropertySymbols, nativeIsBuffer = Buffer$2 ? Buffer$2.isBuffer : undefined$1, nativeIsFinite = context.isFinite, nativeJoin = arrayProto.join, nativeKeys$1 = overArg(Object$1.keys, Object$1), nativeMax = Math$1.max, nativeMin = Math$1.min, nativeNow = Date$1.now, nativeParseInt = context.parseInt, nativeRandom = Math$1.random, nativeReverse = arrayProto.reverse; + var DataView$1 = getNative(context, "DataView"), Map$1 = getNative(context, "Map"), Promise$2 = getNative(context, "Promise"), Set$1 = getNative(context, "Set"), WeakMap$1 = getNative(context, "WeakMap"), nativeCreate$1 = getNative(Object$1, "create"); + /** Used to store function metadata. */ + var metaMap = WeakMap$1 && new WeakMap$1(); + /** Used to lookup unminified function names. */ + var realNames = {}; + /** Used to detect maps, sets, and weakmaps. */ + var dataViewCtorString = toSource(DataView$1), mapCtorString = toSource(Map$1), promiseCtorString = toSource(Promise$2), setCtorString = toSource(Set$1), weakMapCtorString = toSource(WeakMap$1); + /** Used to convert symbols to primitives and strings. */ + var symbolProto$1 = Symbol$2 ? Symbol$2.prototype : undefined$1, symbolValueOf = symbolProto$1 ? symbolProto$1.valueOf : undefined$1, symbolToString$1 = symbolProto$1 ? symbolProto$1.toString : undefined$1; + /** + * Creates a `lodash` object which wraps `value` to enable implicit method + * chain sequences. Methods that operate on and return arrays, collections, + * and functions can be chained together. Methods that retrieve a single value + * or may return a primitive value will automatically end the chain sequence + * and return the unwrapped value. Otherwise, the value must be unwrapped + * with `_#value`. + * + * Explicit chain sequences, which must be unwrapped with `_#value`, may be + * enabled using `_.chain`. + * + * The execution of chained methods is lazy, that is, it's deferred until + * `_#value` is implicitly or explicitly called. + * + * Lazy evaluation allows several methods to support shortcut fusion. + * Shortcut fusion is an optimization to merge iteratee calls; this avoids + * the creation of intermediate arrays and can greatly reduce the number of + * iteratee executions. Sections of a chain sequence qualify for shortcut + * fusion if the section is applied to an array and iteratees accept only + * one argument. The heuristic for whether a section qualifies for shortcut + * fusion is subject to change. + * + * Chaining is supported in custom builds as long as the `_#value` method is + * directly or indirectly included in the build. + * + * In addition to lodash methods, wrappers have `Array` and `String` methods. + * + * The wrapper `Array` methods are: + * `concat`, `join`, `pop`, `push`, `shift`, `sort`, `splice`, and `unshift` + * + * The wrapper `String` methods are: + * `replace` and `split` + * + * The wrapper methods that support shortcut fusion are: + * `at`, `compact`, `drop`, `dropRight`, `dropWhile`, `filter`, `find`, + * `findLast`, `head`, `initial`, `last`, `map`, `reject`, `reverse`, `slice`, + * `tail`, `take`, `takeRight`, `takeRightWhile`, `takeWhile`, and `toArray` + * + * The chainable wrapper methods are: + * `after`, `ary`, `assign`, `assignIn`, `assignInWith`, `assignWith`, `at`, + * `before`, `bind`, `bindAll`, `bindKey`, `castArray`, `chain`, `chunk`, + * `commit`, `compact`, `concat`, `conforms`, `constant`, `countBy`, `create`, + * `curry`, `debounce`, `defaults`, `defaultsDeep`, `defer`, `delay`, + * `difference`, `differenceBy`, `differenceWith`, `drop`, `dropRight`, + * `dropRightWhile`, `dropWhile`, `extend`, `extendWith`, `fill`, `filter`, + * `flatMap`, `flatMapDeep`, `flatMapDepth`, `flatten`, `flattenDeep`, + * `flattenDepth`, `flip`, `flow`, `flowRight`, `fromPairs`, `functions`, + * `functionsIn`, `groupBy`, `initial`, `intersection`, `intersectionBy`, + * `intersectionWith`, `invert`, `invertBy`, `invokeMap`, `iteratee`, `keyBy`, + * `keys`, `keysIn`, `map`, `mapKeys`, `mapValues`, `matches`, `matchesProperty`, + * `memoize`, `merge`, `mergeWith`, `method`, `methodOf`, `mixin`, `negate`, + * `nthArg`, `omit`, `omitBy`, `once`, `orderBy`, `over`, `overArgs`, + * `overEvery`, `overSome`, `partial`, `partialRight`, `partition`, `pick`, + * `pickBy`, `plant`, `property`, `propertyOf`, `pull`, `pullAll`, `pullAllBy`, + * `pullAllWith`, `pullAt`, `push`, `range`, `rangeRight`, `rearg`, `reject`, + * `remove`, `rest`, `reverse`, `sampleSize`, `set`, `setWith`, `shuffle`, + * `slice`, `sort`, `sortBy`, `splice`, `spread`, `tail`, `take`, `takeRight`, + * `takeRightWhile`, `takeWhile`, `tap`, `throttle`, `thru`, `toArray`, + * `toPairs`, `toPairsIn`, `toPath`, `toPlainObject`, `transform`, `unary`, + * `union`, `unionBy`, `unionWith`, `uniq`, `uniqBy`, `uniqWith`, `unset`, + * `unshift`, `unzip`, `unzipWith`, `update`, `updateWith`, `values`, + * `valuesIn`, `without`, `wrap`, `xor`, `xorBy`, `xorWith`, `zip`, + * `zipObject`, `zipObjectDeep`, and `zipWith` + * + * The wrapper methods that are **not** chainable by default are: + * `add`, `attempt`, `camelCase`, `capitalize`, `ceil`, `clamp`, `clone`, + * `cloneDeep`, `cloneDeepWith`, `cloneWith`, `conformsTo`, `deburr`, + * `defaultTo`, `divide`, `each`, `eachRight`, `endsWith`, `eq`, `escape`, + * `escapeRegExp`, `every`, `find`, `findIndex`, `findKey`, `findLast`, + * `findLastIndex`, `findLastKey`, `first`, `floor`, `forEach`, `forEachRight`, + * `forIn`, `forInRight`, `forOwn`, `forOwnRight`, `get`, `gt`, `gte`, `has`, + * `hasIn`, `head`, `identity`, `includes`, `indexOf`, `inRange`, `invoke`, + * `isArguments`, `isArray`, `isArrayBuffer`, `isArrayLike`, `isArrayLikeObject`, + * `isBoolean`, `isBuffer`, `isDate`, `isElement`, `isEmpty`, `isEqual`, + * `isEqualWith`, `isError`, `isFinite`, `isFunction`, `isInteger`, `isLength`, + * `isMap`, `isMatch`, `isMatchWith`, `isNaN`, `isNative`, `isNil`, `isNull`, + * `isNumber`, `isObject`, `isObjectLike`, `isPlainObject`, `isRegExp`, + * `isSafeInteger`, `isSet`, `isString`, `isUndefined`, `isTypedArray`, + * `isWeakMap`, `isWeakSet`, `join`, `kebabCase`, `last`, `lastIndexOf`, + * `lowerCase`, `lowerFirst`, `lt`, `lte`, `max`, `maxBy`, `mean`, `meanBy`, + * `min`, `minBy`, `multiply`, `noConflict`, `noop`, `now`, `nth`, `pad`, + * `padEnd`, `padStart`, `parseInt`, `pop`, `random`, `reduce`, `reduceRight`, + * `repeat`, `result`, `round`, `runInContext`, `sample`, `shift`, `size`, + * `snakeCase`, `some`, `sortedIndex`, `sortedIndexBy`, `sortedLastIndex`, + * `sortedLastIndexBy`, `startCase`, `startsWith`, `stubArray`, `stubFalse`, + * `stubObject`, `stubString`, `stubTrue`, `subtract`, `sum`, `sumBy`, + * `template`, `times`, `toFinite`, `toInteger`, `toJSON`, `toLength`, + * `toLower`, `toNumber`, `toSafeInteger`, `toString`, `toUpper`, `trim`, + * `trimEnd`, `trimStart`, `truncate`, `unescape`, `uniqueId`, `upperCase`, + * `upperFirst`, `value`, and `words` + * + * @name _ + * @constructor + * @category Seq + * @param {*} value The value to wrap in a `lodash` instance. + * @returns {Object} Returns the new `lodash` wrapper instance. + * @example + * + * function square(n) { + * return n * n; + * } + * + * var wrapped = _([1, 2, 3]); + * + * // Returns an unwrapped value. + * wrapped.reduce(_.add); + * // => 6 + * + * // Returns a wrapped value. + * var squares = wrapped.map(square); + * + * _.isArray(squares); + * // => false + * + * _.isArray(squares.value()); + * // => true + */ + function lodash(value) { + if (isObjectLike$1(value) && !isArray$5(value) && !(value instanceof LazyWrapper)) { + if (value instanceof LodashWrapper) return value; + if (hasOwnProperty$6.call(value, "__wrapped__")) return wrapperClone(value); + } + return new LodashWrapper(value); + } + /** + * The base implementation of `_.create` without support for assigning + * properties to the created object. + * + * @private + * @param {Object} proto The object to inherit from. + * @returns {Object} Returns the new object. + */ + var baseCreate$1 = function() { + function object$3() {} + return function(proto) { + if (!isObject$5(proto)) return {}; + if (objectCreate) return objectCreate(proto); + object$3.prototype = proto; + var result$2 = new object$3(); + object$3.prototype = undefined$1; + return result$2; + }; + }(); + /** + * The function whose prototype chain sequence wrappers inherit from. + * + * @private + */ + function baseLodash() {} + /** + * The base constructor for creating `lodash` wrapper objects. + * + * @private + * @param {*} value The value to wrap. + * @param {boolean} [chainAll] Enable explicit method chain sequences. + */ + function LodashWrapper(value, chainAll) { + this.__wrapped__ = value; + this.__actions__ = []; + this.__chain__ = !!chainAll; + this.__index__ = 0; + this.__values__ = undefined$1; + } + /** + * By default, the template delimiters used by lodash are like those in + * embedded Ruby (ERB) as well as ES2015 template strings. Change the + * following template settings to use alternative delimiters. + * + * @static + * @memberOf _ + * @type {Object} + */ + lodash.templateSettings = { + "escape": reEscape, + "evaluate": reEvaluate, + "interpolate": reInterpolate, + "variable": "", + "imports": { "_": lodash } + }; + lodash.prototype = baseLodash.prototype; + lodash.prototype.constructor = lodash; + LodashWrapper.prototype = baseCreate$1(baseLodash.prototype); + LodashWrapper.prototype.constructor = LodashWrapper; + /** + * Creates a lazy wrapper object which wraps `value` to enable lazy evaluation. + * + * @private + * @constructor + * @param {*} value The value to wrap. + */ + function LazyWrapper(value) { + this.__wrapped__ = value; + this.__actions__ = []; + this.__dir__ = 1; + this.__filtered__ = false; + this.__iteratees__ = []; + this.__takeCount__ = MAX_ARRAY_LENGTH; + this.__views__ = []; + } + /** + * Creates a clone of the lazy wrapper object. + * + * @private + * @name clone + * @memberOf LazyWrapper + * @returns {Object} Returns the cloned `LazyWrapper` object. + */ + function lazyClone() { + var result$2 = new LazyWrapper(this.__wrapped__); + result$2.__actions__ = copyArray(this.__actions__); + result$2.__dir__ = this.__dir__; + result$2.__filtered__ = this.__filtered__; + result$2.__iteratees__ = copyArray(this.__iteratees__); + result$2.__takeCount__ = this.__takeCount__; + result$2.__views__ = copyArray(this.__views__); + return result$2; + } + /** + * Reverses the direction of lazy iteration. + * + * @private + * @name reverse + * @memberOf LazyWrapper + * @returns {Object} Returns the new reversed `LazyWrapper` object. + */ + function lazyReverse() { + if (this.__filtered__) { + var result$2 = new LazyWrapper(this); + result$2.__dir__ = -1; + result$2.__filtered__ = true; + } else { + result$2 = this.clone(); + result$2.__dir__ *= -1; + } + return result$2; + } + /** + * Extracts the unwrapped value from its lazy wrapper. + * + * @private + * @name value + * @memberOf LazyWrapper + * @returns {*} Returns the unwrapped value. + */ + function lazyValue() { + var array = this.__wrapped__.value(), dir = this.__dir__, isArr = isArray$5(array), isRight = dir < 0, arrLength = isArr ? array.length : 0, view = getView(0, arrLength, this.__views__), start = view.start, end = view.end, length = end - start, index$1 = isRight ? end : start - 1, iteratees = this.__iteratees__, iterLength = iteratees.length, resIndex = 0, takeCount = nativeMin(length, this.__takeCount__); + if (!isArr || !isRight && arrLength == length && takeCount == length) return baseWrapperValue(array, this.__actions__); + var result$2 = []; + outer: while (length-- && resIndex < takeCount) { + index$1 += dir; + var iterIndex = -1, value = array[index$1]; + while (++iterIndex < iterLength) { + var data$2 = iteratees[iterIndex], iteratee$2 = data$2.iteratee, type = data$2.type, computed = iteratee$2(value); + if (type == LAZY_MAP_FLAG) value = computed; + else if (!computed) if (type == LAZY_FILTER_FLAG) continue outer; + else break outer; + } + result$2[resIndex++] = value; + } + return result$2; + } + LazyWrapper.prototype = baseCreate$1(baseLodash.prototype); + LazyWrapper.prototype.constructor = LazyWrapper; + /** + * Creates a hash object. + * + * @private + * @constructor + * @param {Array} [entries] The key-value pairs to cache. + */ + function Hash(entries) { + var index$1 = -1, length = entries == null ? 0 : entries.length; + this.clear(); + while (++index$1 < length) { + var entry = entries[index$1]; + this.set(entry[0], entry[1]); + } + } + /** + * Removes all key-value entries from the hash. + * + * @private + * @name clear + * @memberOf Hash + */ + function hashClear() { + this.__data__ = nativeCreate$1 ? nativeCreate$1(null) : {}; + this.size = 0; + } + /** + * 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`. + */ + function hashDelete(key) { + var result$2 = this.has(key) && delete this.__data__[key]; + this.size -= result$2 ? 1 : 0; + return result$2; + } + /** + * 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$2 = this.__data__; + if (nativeCreate$1) { + var result$2 = data$2[key]; + return result$2 === HASH_UNDEFINED ? undefined$1 : result$2; + } + return hasOwnProperty$6.call(data$2, key) ? data$2[key] : undefined$1; + } + /** + * 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$2 = this.__data__; + return nativeCreate$1 ? data$2[key] !== undefined$1 : hasOwnProperty$6.call(data$2, key); + } + /** + * 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$2 = this.__data__; + this.size += this.has(key) ? 0 : 1; + data$2[key] = nativeCreate$1 && value === undefined$1 ? HASH_UNDEFINED : value; + return this; + } + Hash.prototype.clear = hashClear; + Hash.prototype["delete"] = hashDelete; + Hash.prototype.get = hashGet; + Hash.prototype.has = hashHas; + Hash.prototype.set = hashSet; + /** + * Creates an list cache object. + * + * @private + * @constructor + * @param {Array} [entries] The key-value pairs to cache. + */ + function ListCache(entries) { + var index$1 = -1, length = entries == null ? 0 : entries.length; + this.clear(); + while (++index$1 < length) { + var entry = entries[index$1]; + this.set(entry[0], entry[1]); + } + } + /** + * Removes all key-value entries from the list cache. + * + * @private + * @name clear + * @memberOf ListCache + */ + function listCacheClear() { + this.__data__ = []; + this.size = 0; + } + /** + * 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$2 = this.__data__, index$1 = assocIndexOf(data$2, key); + if (index$1 < 0) return false; + var lastIndex = data$2.length - 1; + if (index$1 == lastIndex) data$2.pop(); + else splice.call(data$2, index$1, 1); + --this.size; + return true; + } + /** + * 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$2 = this.__data__, index$1 = assocIndexOf(data$2, key); + return index$1 < 0 ? undefined$1 : data$2[index$1][1]; + } + /** + * 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; + } + /** + * 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$2 = this.__data__, index$1 = assocIndexOf(data$2, key); + if (index$1 < 0) { + ++this.size; + data$2.push([key, value]); + } else data$2[index$1][1] = value; + return this; + } + ListCache.prototype.clear = listCacheClear; + ListCache.prototype["delete"] = listCacheDelete; + ListCache.prototype.get = listCacheGet; + ListCache.prototype.has = listCacheHas; + ListCache.prototype.set = listCacheSet; + /** + * 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 = -1, length = entries == null ? 0 : entries.length; + this.clear(); + while (++index$1 < length) { + var entry = entries[index$1]; + this.set(entry[0], entry[1]); + } + } + /** + * 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$1 || ListCache)(), + "string": new Hash() + }; + } + /** + * 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$2 = getMapData(this, key)["delete"](key); + this.size -= result$2 ? 1 : 0; + return result$2; + } + /** + * 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); + } + /** + * 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); + } + /** + * 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$2 = getMapData(this, key), size$2 = data$2.size; + data$2.set(key, value); + this.size += data$2.size == size$2 ? 0 : 1; + return this; + } + MapCache.prototype.clear = mapCacheClear; + MapCache.prototype["delete"] = mapCacheDelete; + MapCache.prototype.get = mapCacheGet; + MapCache.prototype.has = mapCacheHas; + MapCache.prototype.set = mapCacheSet; + /** + * + * Creates an array cache object to store unique values. + * + * @private + * @constructor + * @param {Array} [values] The values to cache. + */ + function SetCache(values$2) { + var index$1 = -1, length = values$2 == null ? 0 : values$2.length; + this.__data__ = new MapCache(); + while (++index$1 < length) this.add(values$2[index$1]); + } + /** + * 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; + } + /** + * 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); + } + SetCache.prototype.add = SetCache.prototype.push = setCacheAdd; + SetCache.prototype.has = setCacheHas; + /** + * Creates a stack cache object to store key-value pairs. + * + * @private + * @constructor + * @param {Array} [entries] The key-value pairs to cache. + */ + function Stack(entries) { + var data$2 = this.__data__ = new ListCache(entries); + this.size = data$2.size; + } + /** + * Removes all key-value entries from the stack. + * + * @private + * @name clear + * @memberOf Stack + */ + function stackClear() { + this.__data__ = new ListCache(); + this.size = 0; + } + /** + * Removes `key` and its value from the stack. + * + * @private + * @name delete + * @memberOf Stack + * @param {string} key The key of the value to remove. + * @returns {boolean} Returns `true` if the entry was removed, else `false`. + */ + function stackDelete(key) { + var data$2 = this.__data__, result$2 = data$2["delete"](key); + this.size = data$2.size; + return result$2; + } + /** + * Gets the stack value for `key`. + * + * @private + * @name get + * @memberOf Stack + * @param {string} key The key of the value to get. + * @returns {*} Returns the entry value. + */ + function stackGet(key) { + return this.__data__.get(key); + } + /** + * Checks if a stack value for `key` exists. + * + * @private + * @name has + * @memberOf Stack + * @param {string} key The key of the entry to check. + * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`. + */ + function stackHas(key) { + return this.__data__.has(key); + } + /** + * Sets the stack `key` to `value`. + * + * @private + * @name set + * @memberOf Stack + * @param {string} key The key of the value to set. + * @param {*} value The value to set. + * @returns {Object} Returns the stack cache instance. + */ + function stackSet(key, value) { + var data$2 = this.__data__; + if (data$2 instanceof ListCache) { + var pairs$1 = data$2.__data__; + if (!Map$1 || pairs$1.length < LARGE_ARRAY_SIZE - 1) { + pairs$1.push([key, value]); + this.size = ++data$2.size; + return this; + } + data$2 = this.__data__ = new MapCache(pairs$1); + } + data$2.set(key, value); + this.size = data$2.size; + return this; + } + Stack.prototype.clear = stackClear; + Stack.prototype["delete"] = stackDelete; + Stack.prototype.get = stackGet; + Stack.prototype.has = stackHas; + Stack.prototype.set = stackSet; + /** + * 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$5(value), isArg = !isArr && isArguments$1(value), isBuff = !isArr && !isArg && isBuffer$1(value), isType$3 = !isArr && !isArg && !isBuff && isTypedArray$1(value), skipIndexes = isArr || isArg || isBuff || isType$3, result$2 = skipIndexes ? baseTimes(value.length, String$4) : [], length = result$2.length; + for (var key in value) if ((inherited || hasOwnProperty$6.call(value, key)) && !(skipIndexes && (key == "length" || isBuff && (key == "offset" || key == "parent") || isType$3 && (key == "buffer" || key == "byteLength" || key == "byteOffset") || isIndex(key, length)))) result$2.push(key); + return result$2; + } + /** + * A specialized version of `_.sample` for arrays. + * + * @private + * @param {Array} array The array to sample. + * @returns {*} Returns the random element. + */ + function arraySample(array) { + var length = array.length; + return length ? array[baseRandom(0, length - 1)] : undefined$1; + } + /** + * A specialized version of `_.sampleSize` for arrays. + * + * @private + * @param {Array} array The array to sample. + * @param {number} n The number of elements to sample. + * @returns {Array} Returns the random elements. + */ + function arraySampleSize(array, n$3) { + return shuffleSelf(copyArray(array), baseClamp(n$3, 0, array.length)); + } + /** + * A specialized version of `_.shuffle` for arrays. + * + * @private + * @param {Array} array The array to shuffle. + * @returns {Array} Returns the new shuffled array. + */ + function arrayShuffle(array) { + return shuffleSelf(copyArray(array)); + } + /** + * This function is like `assignValue` except that it doesn't assign + * `undefined` values. + * + * @private + * @param {Object} object The object to modify. + * @param {string} key The key of the property to assign. + * @param {*} value The value to assign. + */ + function assignMergeValue(object$3, key, value) { + if (value !== undefined$1 && !eq$1(object$3[key], value) || value === undefined$1 && !(key in object$3)) baseAssignValue(object$3, key, value); + } + /** + * Assigns `value` to `key` of `object` if the existing value is not equivalent + * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) + * for equality comparisons. + * + * @private + * @param {Object} object The object to modify. + * @param {string} key The key of the property to assign. + * @param {*} value The value to assign. + */ + function assignValue(object$3, key, value) { + var objValue = object$3[key]; + if (!(hasOwnProperty$6.call(object$3, key) && eq$1(objValue, value)) || value === undefined$1 && !(key in object$3)) baseAssignValue(object$3, key, value); + } + /** + * 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$1(array[length][0], key)) return length; + return -1; + } + /** + * Aggregates elements of `collection` on `accumulator` with keys transformed + * by `iteratee` and values set by `setter`. + * + * @private + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} setter The function to set `accumulator` values. + * @param {Function} iteratee The iteratee to transform keys. + * @param {Object} accumulator The initial aggregated object. + * @returns {Function} Returns `accumulator`. + */ + function baseAggregator(collection, setter, iteratee$2, accumulator) { + baseEach(collection, function(value, key, collection$1) { + setter(accumulator, value, iteratee$2(value), collection$1); + }); + return accumulator; + } + /** + * The base implementation of `_.assign` without support for multiple sources + * or `customizer` functions. + * + * @private + * @param {Object} object The destination object. + * @param {Object} source The source object. + * @returns {Object} Returns `object`. + */ + function baseAssign(object$3, source) { + return object$3 && copyObject(source, keys$2(source), object$3); + } + /** + * The base implementation of `_.assignIn` without support for multiple sources + * or `customizer` functions. + * + * @private + * @param {Object} object The destination object. + * @param {Object} source The source object. + * @returns {Object} Returns `object`. + */ + function baseAssignIn(object$3, source) { + return object$3 && copyObject(source, keysIn(source), object$3); + } + /** + * The base implementation of `assignValue` and `assignMergeValue` without + * value checks. + * + * @private + * @param {Object} object The object to modify. + * @param {string} key The key of the property to assign. + * @param {*} value The value to assign. + */ + function baseAssignValue(object$3, key, value) { + if (key == "__proto__" && defineProperty$1) defineProperty$1(object$3, key, { + "configurable": true, + "enumerable": true, + "value": value, + "writable": true + }); + else object$3[key] = value; + } + /** + * The base implementation of `_.at` without support for individual paths. + * + * @private + * @param {Object} object The object to iterate over. + * @param {string[]} paths The property paths to pick. + * @returns {Array} Returns the picked elements. + */ + function baseAt(object$3, paths) { + var index$1 = -1, length = paths.length, result$2 = Array$1(length), skip$1 = object$3 == null; + while (++index$1 < length) result$2[index$1] = skip$1 ? undefined$1 : get$3(object$3, paths[index$1]); + return result$2; + } + /** + * The base implementation of `_.clamp` which doesn't coerce arguments. + * + * @private + * @param {number} number The number to clamp. + * @param {number} [lower] The lower bound. + * @param {number} upper The upper bound. + * @returns {number} Returns the clamped number. + */ + function baseClamp(number, lower, upper) { + if (number === number) { + if (upper !== undefined$1) number = number <= upper ? number : upper; + if (lower !== undefined$1) number = number >= lower ? number : lower; + } + return number; + } + /** + * The base implementation of `_.clone` and `_.cloneDeep` which tracks + * traversed objects. + * + * @private + * @param {*} value The value to clone. + * @param {boolean} bitmask The bitmask flags. + * 1 - Deep clone + * 2 - Flatten inherited properties + * 4 - Clone symbols + * @param {Function} [customizer] The function to customize cloning. + * @param {string} [key] The key of `value`. + * @param {Object} [object] The parent object of `value`. + * @param {Object} [stack] Tracks traversed objects and their clone counterparts. + * @returns {*} Returns the cloned value. + */ + function baseClone(value, bitmask, customizer, key, object$3, stack) { + var result$2, isDeep = bitmask & CLONE_DEEP_FLAG, isFlat = bitmask & CLONE_FLAT_FLAG, isFull = bitmask & CLONE_SYMBOLS_FLAG; + if (customizer) result$2 = object$3 ? customizer(value, key, object$3, stack) : customizer(value); + if (result$2 !== undefined$1) return result$2; + if (!isObject$5(value)) return value; + var isArr = isArray$5(value); + if (isArr) { + result$2 = initCloneArray(value); + if (!isDeep) return copyArray(value, result$2); + } else { + var tag$3 = getTag(value), isFunc = tag$3 == funcTag || tag$3 == genTag; + if (isBuffer$1(value)) return cloneBuffer(value, isDeep); + if (tag$3 == objectTag || tag$3 == argsTag || isFunc && !object$3) { + result$2 = isFlat || isFunc ? {} : initCloneObject(value); + if (!isDeep) return isFlat ? copySymbolsIn(value, baseAssignIn(result$2, value)) : copySymbols(value, baseAssign(result$2, value)); + } else { + if (!cloneableTags[tag$3]) return object$3 ? value : {}; + result$2 = initCloneByTag(value, tag$3, isDeep); + } + } + stack || (stack = new Stack()); + var stacked = stack.get(value); + if (stacked) return stacked; + stack.set(value, result$2); + if (isSet$2(value)) value.forEach(function(subValue) { + result$2.add(baseClone(subValue, bitmask, customizer, subValue, value, stack)); + }); + else if (isMap$2(value)) value.forEach(function(subValue, key$1) { + result$2.set(key$1, baseClone(subValue, bitmask, customizer, key$1, value, stack)); + }); + var keysFunc = isFull ? isFlat ? getAllKeysIn : getAllKeys : isFlat ? keysIn : keys$2; + var props = isArr ? undefined$1 : keysFunc(value); + arrayEach(props || value, function(subValue, key$1) { + if (props) { + key$1 = subValue; + subValue = value[key$1]; + } + assignValue(result$2, key$1, baseClone(subValue, bitmask, customizer, key$1, value, stack)); + }); + return result$2; + } + /** + * The base implementation of `_.conforms` which doesn't clone `source`. + * + * @private + * @param {Object} source The object of property predicates to conform to. + * @returns {Function} Returns the new spec function. + */ + function baseConforms(source) { + var props = keys$2(source); + return function(object$3) { + return baseConformsTo(object$3, source, props); + }; + } + /** + * The base implementation of `_.conformsTo` which accepts `props` to check. + * + * @private + * @param {Object} object The object to inspect. + * @param {Object} source The object of property predicates to conform to. + * @returns {boolean} Returns `true` if `object` conforms, else `false`. + */ + function baseConformsTo(object$3, source, props) { + var length = props.length; + if (object$3 == null) return !length; + object$3 = Object$1(object$3); + while (length--) { + var key = props[length], predicate = source[key], value = object$3[key]; + if (value === undefined$1 && !(key in object$3) || !predicate(value)) return false; + } + return true; + } + /** + * The base implementation of `_.delay` and `_.defer` which accepts `args` + * to provide to `func`. + * + * @private + * @param {Function} func The function to delay. + * @param {number} wait The number of milliseconds to delay invocation. + * @param {Array} args The arguments to provide to `func`. + * @returns {number|Object} Returns the timer id or timeout object. + */ + function baseDelay(func, wait, args) { + if (typeof func != "function") throw new TypeError$1(FUNC_ERROR_TEXT); + return setTimeout$1(function() { + func.apply(undefined$1, args); + }, wait); + } + /** + * 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$2, iteratee$2, comparator) { + var index$1 = -1, includes$1 = arrayIncludes, isCommon = true, length = array.length, result$2 = [], valuesLength = values$2.length; + if (!length) return result$2; + if (iteratee$2) values$2 = arrayMap(values$2, baseUnary(iteratee$2)); + if (comparator) { + includes$1 = arrayIncludesWith; + isCommon = false; + } else if (values$2.length >= LARGE_ARRAY_SIZE) { + includes$1 = cacheHas; + isCommon = false; + values$2 = new SetCache(values$2); + } + outer: while (++index$1 < length) { + var value = array[index$1], computed = iteratee$2 == null ? value : iteratee$2(value); + value = comparator || value !== 0 ? value : 0; + if (isCommon && computed === computed) { + var valuesIndex = valuesLength; + while (valuesIndex--) if (values$2[valuesIndex] === computed) continue outer; + result$2.push(value); + } else if (!includes$1(values$2, computed, comparator)) result$2.push(value); + } + return result$2; + } + /** + * The base implementation of `_.forEach` without support for iteratee shorthands. + * + * @private + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @returns {Array|Object} Returns `collection`. + */ + var baseEach = createBaseEach(baseForOwn); + /** + * The base implementation of `_.forEachRight` without support for iteratee shorthands. + * + * @private + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @returns {Array|Object} Returns `collection`. + */ + var baseEachRight = createBaseEach(baseForOwnRight, true); + /** + * The base implementation of `_.every` without support for iteratee shorthands. + * + * @private + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} predicate The function invoked per iteration. + * @returns {boolean} Returns `true` if all elements pass the predicate check, + * else `false` + */ + function baseEvery(collection, predicate) { + var result$2 = true; + baseEach(collection, function(value, index$1, collection$1) { + result$2 = !!predicate(value, index$1, collection$1); + return result$2; + }); + return result$2; + } + /** + * The base implementation of methods like `_.max` and `_.min` which accepts a + * `comparator` to determine the extremum value. + * + * @private + * @param {Array} array The array to iterate over. + * @param {Function} iteratee The iteratee invoked per iteration. + * @param {Function} comparator The comparator used to compare values. + * @returns {*} Returns the extremum value. + */ + function baseExtremum(array, iteratee$2, comparator) { + var index$1 = -1, length = array.length; + while (++index$1 < length) { + var value = array[index$1], current = iteratee$2(value); + if (current != null && (computed === undefined$1 ? current === current && !isSymbol$2(current) : comparator(current, computed))) var computed = current, result$2 = value; + } + return result$2; + } + /** + * The base implementation of `_.fill` without an iteratee call guard. + * + * @private + * @param {Array} array The array to fill. + * @param {*} value The value to fill `array` with. + * @param {number} [start=0] The start position. + * @param {number} [end=array.length] The end position. + * @returns {Array} Returns `array`. + */ + function baseFill(array, value, start, end) { + var length = array.length; + start = toInteger(start); + if (start < 0) start = -start > length ? 0 : length + start; + end = end === undefined$1 || end > length ? length : toInteger(end); + if (end < 0) end += length; + end = start > end ? 0 : toLength(end); + while (start < end) array[start++] = value; + return array; + } + /** + * The base implementation of `_.filter` without support for iteratee shorthands. + * + * @private + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} predicate The function invoked per iteration. + * @returns {Array} Returns the new filtered array. + */ + function baseFilter(collection, predicate) { + var result$2 = []; + baseEach(collection, function(value, index$1, collection$1) { + if (predicate(value, index$1, collection$1)) result$2.push(value); + }); + return result$2; + } + /** + * 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$1, predicate, isStrict, result$2) { + var index$1 = -1, length = array.length; + predicate || (predicate = isFlattenable); + result$2 || (result$2 = []); + while (++index$1 < length) { + var value = array[index$1]; + if (depth$1 > 0 && predicate(value)) if (depth$1 > 1) baseFlatten(value, depth$1 - 1, predicate, isStrict, result$2); + else arrayPush(result$2, value); + else if (!isStrict) result$2[result$2.length] = value; + } + return result$2; + } + /** + * The base implementation of `baseForOwn` which iterates over `object` + * properties returned by `keysFunc` and invokes `iteratee` for each property. + * Iteratee functions may exit iteration early by explicitly returning `false`. + * + * @private + * @param {Object} object The object to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @param {Function} keysFunc The function to get the keys of `object`. + * @returns {Object} Returns `object`. + */ + var baseFor = createBaseFor(); + /** + * This function is like `baseFor` except that it iterates over properties + * in the opposite order. + * + * @private + * @param {Object} object The object to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @param {Function} keysFunc The function to get the keys of `object`. + * @returns {Object} Returns `object`. + */ + var baseForRight = createBaseFor(true); + /** + * The base implementation of `_.forOwn` without support for iteratee shorthands. + * + * @private + * @param {Object} object The object to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @returns {Object} Returns `object`. + */ + function baseForOwn(object$3, iteratee$2) { + return object$3 && baseFor(object$3, iteratee$2, keys$2); + } + /** + * The base implementation of `_.forOwnRight` without support for iteratee shorthands. + * + * @private + * @param {Object} object The object to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @returns {Object} Returns `object`. + */ + function baseForOwnRight(object$3, iteratee$2) { + return object$3 && baseForRight(object$3, iteratee$2, keys$2); + } + /** + * The base implementation of `_.functions` which creates an array of + * `object` function property names filtered from `props`. + * + * @private + * @param {Object} object The object to inspect. + * @param {Array} props The property names to filter. + * @returns {Array} Returns the function names. + */ + function baseFunctions(object$3, props) { + return arrayFilter(props, function(key) { + return isFunction$10(object$3[key]); + }); + } + /** + * The base implementation of `_.get` without support for default values. + * + * @private + * @param {Object} object The object to query. + * @param {Array|string} path The path of the property to get. + * @returns {*} Returns the resolved value. + */ + function baseGet(object$3, path$28) { + path$28 = castPath(path$28, object$3); + var index$1 = 0, length = path$28.length; + while (object$3 != null && index$1 < length) object$3 = object$3[toKey(path$28[index$1++])]; + return index$1 && index$1 == length ? object$3 : undefined$1; + } + /** + * The base implementation of `getAllKeys` and `getAllKeysIn` which uses + * `keysFunc` and `symbolsFunc` to get the enumerable property names and + * symbols of `object`. + * + * @private + * @param {Object} object The object to query. + * @param {Function} keysFunc The function to get the keys of `object`. + * @param {Function} symbolsFunc The function to get the symbols of `object`. + * @returns {Array} Returns the array of property names and symbols. + */ + function baseGetAllKeys(object$3, keysFunc, symbolsFunc) { + var result$2 = keysFunc(object$3); + return isArray$5(object$3) ? result$2 : arrayPush(result$2, symbolsFunc(object$3)); + } + /** + * 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$1 ? undefinedTag : nullTag; + return symToStringTag && symToStringTag in Object$1(value) ? getRawTag(value) : objectToString$3(value); + } + /** + * The base implementation of `_.gt` which doesn't coerce arguments. + * + * @private + * @param {*} value The value to compare. + * @param {*} other The other value to compare. + * @returns {boolean} Returns `true` if `value` is greater than `other`, + * else `false`. + */ + function baseGt(value, other) { + return value > other; + } + /** + * The base implementation of `_.has` without support for deep paths. + * + * @private + * @param {Object} [object] The object to query. + * @param {Array|string} key The key to check. + * @returns {boolean} Returns `true` if `key` exists, else `false`. + */ + function baseHas(object$3, key) { + return object$3 != null && hasOwnProperty$6.call(object$3, key); + } + /** + * The base implementation of `_.hasIn` without support for deep paths. + * + * @private + * @param {Object} [object] The object to query. + * @param {Array|string} key The key to check. + * @returns {boolean} Returns `true` if `key` exists, else `false`. + */ + function baseHasIn(object$3, key) { + return object$3 != null && key in Object$1(object$3); + } + /** + * The base implementation of `_.inRange` which doesn't coerce arguments. + * + * @private + * @param {number} number The number to check. + * @param {number} start The start of the range. + * @param {number} end The end of the range. + * @returns {boolean} Returns `true` if `number` is in the range, else `false`. + */ + function baseInRange(number, start, end) { + return number >= nativeMin(start, end) && number < nativeMax(start, end); + } + /** + * The base implementation of methods like `_.intersection`, without support + * for iteratee shorthands, that accepts an array of arrays to inspect. + * + * @private + * @param {Array} arrays The arrays to inspect. + * @param {Function} [iteratee] The iteratee invoked per element. + * @param {Function} [comparator] The comparator invoked per element. + * @returns {Array} Returns the new array of shared values. + */ + function baseIntersection(arrays, iteratee$2, comparator) { + var includes$1 = comparator ? arrayIncludesWith : arrayIncludes, length = arrays[0].length, othLength = arrays.length, othIndex = othLength, caches = Array$1(othLength), maxLength = Infinity, result$2 = []; + while (othIndex--) { + var array = arrays[othIndex]; + if (othIndex && iteratee$2) array = arrayMap(array, baseUnary(iteratee$2)); + maxLength = nativeMin(array.length, maxLength); + caches[othIndex] = !comparator && (iteratee$2 || length >= 120 && array.length >= 120) ? new SetCache(othIndex && array) : undefined$1; + } + array = arrays[0]; + var index$1 = -1, seen$1 = caches[0]; + outer: while (++index$1 < length && result$2.length < maxLength) { + var value = array[index$1], computed = iteratee$2 ? iteratee$2(value) : value; + value = comparator || value !== 0 ? value : 0; + if (!(seen$1 ? cacheHas(seen$1, computed) : includes$1(result$2, computed, comparator))) { + othIndex = othLength; + while (--othIndex) { + var cache$3 = caches[othIndex]; + if (!(cache$3 ? cacheHas(cache$3, computed) : includes$1(arrays[othIndex], computed, comparator))) continue outer; + } + if (seen$1) seen$1.push(computed); + result$2.push(value); + } + } + return result$2; + } + /** + * The base implementation of `_.invert` and `_.invertBy` which inverts + * `object` with values transformed by `iteratee` and set by `setter`. + * + * @private + * @param {Object} object The object to iterate over. + * @param {Function} setter The function to set `accumulator` values. + * @param {Function} iteratee The iteratee to transform values. + * @param {Object} accumulator The initial inverted object. + * @returns {Function} Returns `accumulator`. + */ + function baseInverter(object$3, setter, iteratee$2, accumulator) { + baseForOwn(object$3, function(value, key, object$4) { + setter(accumulator, iteratee$2(value), key, object$4); + }); + return accumulator; + } + /** + * The base implementation of `_.invoke` without support for individual + * method arguments. + * + * @private + * @param {Object} object The object to query. + * @param {Array|string} path The path of the method to invoke. + * @param {Array} args The arguments to invoke the method with. + * @returns {*} Returns the result of the invoked method. + */ + function baseInvoke(object$3, path$28, args) { + path$28 = castPath(path$28, object$3); + object$3 = parent(object$3, path$28); + var func = object$3 == null ? object$3 : object$3[toKey(last$3(path$28))]; + return func == null ? undefined$1 : apply(func, object$3, args); + } + /** + * 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$1(value) && baseGetTag(value) == argsTag; + } + /** + * The base implementation of `_.isArrayBuffer` without Node.js optimizations. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an array buffer, else `false`. + */ + function baseIsArrayBuffer(value) { + return isObjectLike$1(value) && baseGetTag(value) == arrayBufferTag; + } + /** + * The base implementation of `_.isDate` without Node.js optimizations. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a date object, else `false`. + */ + function baseIsDate(value) { + return isObjectLike$1(value) && baseGetTag(value) == dateTag; + } + /** + * The base implementation of `_.isEqual` which supports partial comparisons + * and tracks traversed objects. + * + * @private + * @param {*} value The value to compare. + * @param {*} other The other value to compare. + * @param {boolean} bitmask The bitmask flags. + * 1 - Unordered comparison + * 2 - Partial comparison + * @param {Function} [customizer] The function to customize comparisons. + * @param {Object} [stack] Tracks traversed `value` and `other` objects. + * @returns {boolean} Returns `true` if the values are equivalent, else `false`. + */ + function baseIsEqual(value, other, bitmask, customizer, stack) { + if (value === other) return true; + if (value == null || other == null || !isObjectLike$1(value) && !isObjectLike$1(other)) return value !== value && other !== other; + return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack); + } + /** + * A specialized version of `baseIsEqual` for arrays and objects which performs + * deep comparisons and tracks traversed objects enabling objects with circular + * references to be compared. + * + * @private + * @param {Object} object The object to compare. + * @param {Object} other The other object to compare. + * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details. + * @param {Function} customizer The function to customize comparisons. + * @param {Function} equalFunc The function to determine equivalents of values. + * @param {Object} [stack] Tracks traversed `object` and `other` objects. + * @returns {boolean} Returns `true` if the objects are equivalent, else `false`. + */ + function baseIsEqualDeep(object$3, other, bitmask, customizer, equalFunc, stack) { + var objIsArr = isArray$5(object$3), othIsArr = isArray$5(other), objTag = objIsArr ? arrayTag : getTag(object$3), othTag = othIsArr ? arrayTag : getTag(other); + objTag = objTag == argsTag ? objectTag : objTag; + othTag = othTag == argsTag ? objectTag : othTag; + var objIsObj = objTag == objectTag, othIsObj = othTag == objectTag, isSameTag = objTag == othTag; + if (isSameTag && isBuffer$1(object$3)) { + if (!isBuffer$1(other)) return false; + objIsArr = true; + objIsObj = false; + } + if (isSameTag && !objIsObj) { + stack || (stack = new Stack()); + return objIsArr || isTypedArray$1(object$3) ? equalArrays(object$3, other, bitmask, customizer, equalFunc, stack) : equalByTag(object$3, other, objTag, bitmask, customizer, equalFunc, stack); + } + if (!(bitmask & COMPARE_PARTIAL_FLAG)) { + var objIsWrapped = objIsObj && hasOwnProperty$6.call(object$3, "__wrapped__"), othIsWrapped = othIsObj && hasOwnProperty$6.call(other, "__wrapped__"); + if (objIsWrapped || othIsWrapped) { + var objUnwrapped = objIsWrapped ? object$3.value() : object$3, othUnwrapped = othIsWrapped ? other.value() : other; + stack || (stack = new Stack()); + return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack); + } + } + if (!isSameTag) return false; + stack || (stack = new Stack()); + return equalObjects(object$3, other, bitmask, customizer, equalFunc, stack); + } + /** + * The base implementation of `_.isMap` without Node.js optimizations. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a map, else `false`. + */ + function baseIsMap(value) { + return isObjectLike$1(value) && getTag(value) == mapTag; + } + /** + * The base implementation of `_.isMatch` without support for iteratee shorthands. + * + * @private + * @param {Object} object The object to inspect. + * @param {Object} source The object of property values to match. + * @param {Array} matchData The property names, values, and compare flags to match. + * @param {Function} [customizer] The function to customize comparisons. + * @returns {boolean} Returns `true` if `object` is a match, else `false`. + */ + function baseIsMatch(object$3, source, matchData, customizer) { + var index$1 = matchData.length, length = index$1, noCustomizer = !customizer; + if (object$3 == null) return !length; + object$3 = Object$1(object$3); + while (index$1--) { + var data$2 = matchData[index$1]; + if (noCustomizer && data$2[2] ? data$2[1] !== object$3[data$2[0]] : !(data$2[0] in object$3)) return false; + } + while (++index$1 < length) { + data$2 = matchData[index$1]; + var key = data$2[0], objValue = object$3[key], srcValue = data$2[1]; + if (noCustomizer && data$2[2]) { + if (objValue === undefined$1 && !(key in object$3)) return false; + } else { + var stack = new Stack(); + if (customizer) var result$2 = customizer(objValue, srcValue, key, object$3, source, stack); + if (!(result$2 === undefined$1 ? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG, customizer, stack) : result$2)) return false; + } + } + return true; + } + /** + * 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$5(value) || isMasked(value)) return false; + var pattern = isFunction$10(value) ? reIsNative : reIsHostCtor; + return pattern.test(toSource(value)); + } + /** + * The base implementation of `_.isRegExp` without Node.js optimizations. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a regexp, else `false`. + */ + function baseIsRegExp(value) { + return isObjectLike$1(value) && baseGetTag(value) == regexpTag; + } + /** + * The base implementation of `_.isSet` without Node.js optimizations. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a set, else `false`. + */ + function baseIsSet(value) { + return isObjectLike$1(value) && getTag(value) == setTag; + } + /** + * 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$1(value) && isLength(value.length) && !!typedArrayTags[baseGetTag(value)]; + } + /** + * The base implementation of `_.iteratee`. + * + * @private + * @param {*} [value=_.identity] The value to convert to an iteratee. + * @returns {Function} Returns the iteratee. + */ + function baseIteratee$1(value) { + if (typeof value == "function") return value; + if (value == null) return identity$2; + if (typeof value == "object") return isArray$5(value) ? baseMatchesProperty(value[0], value[1]) : baseMatches(value); + return property$1(value); + } + /** + * 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$3) { + if (!isPrototype(object$3)) return nativeKeys$1(object$3); + var result$2 = []; + for (var key in Object$1(object$3)) if (hasOwnProperty$6.call(object$3, key) && key != "constructor") result$2.push(key); + return result$2; + } + /** + * 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$3) { + if (!isObject$5(object$3)) return nativeKeysIn(object$3); + var isProto = isPrototype(object$3), result$2 = []; + for (var key in object$3) if (!(key == "constructor" && (isProto || !hasOwnProperty$6.call(object$3, key)))) result$2.push(key); + return result$2; + } + /** + * The base implementation of `_.lt` which doesn't coerce arguments. + * + * @private + * @param {*} value The value to compare. + * @param {*} other The other value to compare. + * @returns {boolean} Returns `true` if `value` is less than `other`, + * else `false`. + */ + function baseLt(value, other) { + return value < other; + } + /** + * The base implementation of `_.map` without support for iteratee shorthands. + * + * @private + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @returns {Array} Returns the new mapped array. + */ + function baseMap(collection, iteratee$2) { + var index$1 = -1, result$2 = isArrayLike(collection) ? Array$1(collection.length) : []; + baseEach(collection, function(value, key, collection$1) { + result$2[++index$1] = iteratee$2(value, key, collection$1); + }); + return result$2; + } + /** + * The base implementation of `_.matches` which doesn't clone `source`. + * + * @private + * @param {Object} source The object of property values to match. + * @returns {Function} Returns the new spec function. + */ + function baseMatches(source) { + var matchData = getMatchData(source); + if (matchData.length == 1 && matchData[0][2]) return matchesStrictComparable(matchData[0][0], matchData[0][1]); + return function(object$3) { + return object$3 === source || baseIsMatch(object$3, source, matchData); + }; + } + /** + * The base implementation of `_.matchesProperty` which doesn't clone `srcValue`. + * + * @private + * @param {string} path The path of the property to get. + * @param {*} srcValue The value to match. + * @returns {Function} Returns the new spec function. + */ + function baseMatchesProperty(path$28, srcValue) { + if (isKey(path$28) && isStrictComparable(srcValue)) return matchesStrictComparable(toKey(path$28), srcValue); + return function(object$3) { + var objValue = get$3(object$3, path$28); + return objValue === undefined$1 && objValue === srcValue ? hasIn(object$3, path$28) : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG); + }; + } + /** + * The base implementation of `_.merge` without support for multiple sources. + * + * @private + * @param {Object} object The destination object. + * @param {Object} source The source object. + * @param {number} srcIndex The index of `source`. + * @param {Function} [customizer] The function to customize merged values. + * @param {Object} [stack] Tracks traversed source values and their merged + * counterparts. + */ + function baseMerge(object$3, source, srcIndex, customizer, stack) { + if (object$3 === source) return; + baseFor(source, function(srcValue, key) { + stack || (stack = new Stack()); + if (isObject$5(srcValue)) baseMergeDeep(object$3, source, key, srcIndex, baseMerge, customizer, stack); + else { + var newValue = customizer ? customizer(safeGet(object$3, key), srcValue, key + "", object$3, source, stack) : undefined$1; + if (newValue === undefined$1) newValue = srcValue; + assignMergeValue(object$3, key, newValue); + } + }, keysIn); + } + /** + * A specialized version of `baseMerge` for arrays and objects which performs + * deep merges and tracks traversed objects enabling objects with circular + * references to be merged. + * + * @private + * @param {Object} object The destination object. + * @param {Object} source The source object. + * @param {string} key The key of the value to merge. + * @param {number} srcIndex The index of `source`. + * @param {Function} mergeFunc The function to merge values. + * @param {Function} [customizer] The function to customize assigned values. + * @param {Object} [stack] Tracks traversed source values and their merged + * counterparts. + */ + function baseMergeDeep(object$3, source, key, srcIndex, mergeFunc, customizer, stack) { + var objValue = safeGet(object$3, key), srcValue = safeGet(source, key), stacked = stack.get(srcValue); + if (stacked) { + assignMergeValue(object$3, key, stacked); + return; + } + var newValue = customizer ? customizer(objValue, srcValue, key + "", object$3, source, stack) : undefined$1; + var isCommon = newValue === undefined$1; + if (isCommon) { + var isArr = isArray$5(srcValue), isBuff = !isArr && isBuffer$1(srcValue), isTyped = !isArr && !isBuff && isTypedArray$1(srcValue); + newValue = srcValue; + if (isArr || isBuff || isTyped) if (isArray$5(objValue)) newValue = objValue; + else if (isArrayLikeObject(objValue)) newValue = copyArray(objValue); + else if (isBuff) { + isCommon = false; + newValue = cloneBuffer(srcValue, true); + } else if (isTyped) { + isCommon = false; + newValue = cloneTypedArray(srcValue, true); + } else newValue = []; + else if (isPlainObject$2(srcValue) || isArguments$1(srcValue)) { + newValue = objValue; + if (isArguments$1(objValue)) newValue = toPlainObject(objValue); + else if (!isObject$5(objValue) || isFunction$10(objValue)) newValue = initCloneObject(srcValue); + } else isCommon = false; + } + if (isCommon) { + stack.set(srcValue, newValue); + mergeFunc(newValue, srcValue, srcIndex, customizer, stack); + stack["delete"](srcValue); + } + assignMergeValue(object$3, key, newValue); + } + /** + * The base implementation of `_.nth` which doesn't coerce arguments. + * + * @private + * @param {Array} array The array to query. + * @param {number} n The index of the element to return. + * @returns {*} Returns the nth element of `array`. + */ + function baseNth(array, n$3) { + var length = array.length; + if (!length) return; + n$3 += n$3 < 0 ? length : 0; + return isIndex(n$3, length) ? array[n$3] : undefined$1; + } + /** + * The base implementation of `_.orderBy` without param guards. + * + * @private + * @param {Array|Object} collection The collection to iterate over. + * @param {Function[]|Object[]|string[]} iteratees The iteratees to sort by. + * @param {string[]} orders The sort orders of `iteratees`. + * @returns {Array} Returns the new sorted array. + */ + function baseOrderBy(collection, iteratees, orders) { + if (iteratees.length) iteratees = arrayMap(iteratees, function(iteratee$2) { + if (isArray$5(iteratee$2)) return function(value) { + return baseGet(value, iteratee$2.length === 1 ? iteratee$2[0] : iteratee$2); + }; + return iteratee$2; + }); + else iteratees = [identity$2]; + var index$1 = -1; + iteratees = arrayMap(iteratees, baseUnary(getIteratee())); + var result$2 = baseMap(collection, function(value, key, collection$1) { + var criteria = arrayMap(iteratees, function(iteratee$2) { + return iteratee$2(value); + }); + return { + "criteria": criteria, + "index": ++index$1, + "value": value + }; + }); + return baseSortBy(result$2, function(object$3, other) { + return compareMultiple(object$3, other, orders); + }); + } + /** + * The base implementation of `_.pick` without support for individual + * property identifiers. + * + * @private + * @param {Object} object The source object. + * @param {string[]} paths The property paths to pick. + * @returns {Object} Returns the new object. + */ + function basePick(object$3, paths) { + return basePickBy(object$3, paths, function(value, path$28) { + return hasIn(object$3, path$28); + }); + } + /** + * The base implementation of `_.pickBy` without support for iteratee shorthands. + * + * @private + * @param {Object} object The source object. + * @param {string[]} paths The property paths to pick. + * @param {Function} predicate The function invoked per property. + * @returns {Object} Returns the new object. + */ + function basePickBy(object$3, paths, predicate) { + var index$1 = -1, length = paths.length, result$2 = {}; + while (++index$1 < length) { + var path$28 = paths[index$1], value = baseGet(object$3, path$28); + if (predicate(value, path$28)) baseSet(result$2, castPath(path$28, object$3), value); + } + return result$2; + } + /** + * A specialized version of `baseProperty` which supports deep paths. + * + * @private + * @param {Array|string} path The path of the property to get. + * @returns {Function} Returns the new accessor function. + */ + function basePropertyDeep(path$28) { + return function(object$3) { + return baseGet(object$3, path$28); + }; + } + /** + * The base implementation of `_.pullAllBy` without support for iteratee + * shorthands. + * + * @private + * @param {Array} array The array to modify. + * @param {Array} values The values to remove. + * @param {Function} [iteratee] The iteratee invoked per element. + * @param {Function} [comparator] The comparator invoked per element. + * @returns {Array} Returns `array`. + */ + function basePullAll(array, values$2, iteratee$2, comparator) { + var indexOf$2 = comparator ? baseIndexOfWith : baseIndexOf, index$1 = -1, length = values$2.length, seen$1 = array; + if (array === values$2) values$2 = copyArray(values$2); + if (iteratee$2) seen$1 = arrayMap(array, baseUnary(iteratee$2)); + while (++index$1 < length) { + var fromIndex = 0, value = values$2[index$1], computed = iteratee$2 ? iteratee$2(value) : value; + while ((fromIndex = indexOf$2(seen$1, computed, fromIndex, comparator)) > -1) { + if (seen$1 !== array) splice.call(seen$1, fromIndex, 1); + splice.call(array, fromIndex, 1); + } + } + return array; + } + /** + * The base implementation of `_.pullAt` without support for individual + * indexes or capturing the removed elements. + * + * @private + * @param {Array} array The array to modify. + * @param {number[]} indexes The indexes of elements to remove. + * @returns {Array} Returns `array`. + */ + function basePullAt(array, indexes) { + var length = array ? indexes.length : 0, lastIndex = length - 1; + while (length--) { + var index$1 = indexes[length]; + if (length == lastIndex || index$1 !== previous) { + var previous = index$1; + if (isIndex(index$1)) splice.call(array, index$1, 1); + else baseUnset(array, index$1); + } + } + return array; + } + /** + * The base implementation of `_.random` without support for returning + * floating-point numbers. + * + * @private + * @param {number} lower The lower bound. + * @param {number} upper The upper bound. + * @returns {number} Returns the random number. + */ + function baseRandom(lower, upper) { + return lower + nativeFloor(nativeRandom() * (upper - lower + 1)); + } + /** + * The base implementation of `_.range` and `_.rangeRight` which doesn't + * coerce arguments. + * + * @private + * @param {number} start The start of the range. + * @param {number} end The end of the range. + * @param {number} step The value to increment or decrement by. + * @param {boolean} [fromRight] Specify iterating from right to left. + * @returns {Array} Returns the range of numbers. + */ + function baseRange(start, end, step, fromRight) { + var index$1 = -1, length = nativeMax(nativeCeil((end - start) / (step || 1)), 0), result$2 = Array$1(length); + while (length--) { + result$2[fromRight ? length : ++index$1] = start; + start += step; + } + return result$2; + } + /** + * The base implementation of `_.repeat` which doesn't coerce arguments. + * + * @private + * @param {string} string The string to repeat. + * @param {number} n The number of times to repeat the string. + * @returns {string} Returns the repeated string. + */ + function baseRepeat(string$3, n$3) { + var result$2 = ""; + if (!string$3 || n$3 < 1 || n$3 > MAX_SAFE_INTEGER) return result$2; + do { + if (n$3 % 2) result$2 += string$3; + n$3 = nativeFloor(n$3 / 2); + if (n$3) string$3 += string$3; + } while (n$3); + return result$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$2), func + ""); + } + /** + * The base implementation of `_.sample`. + * + * @private + * @param {Array|Object} collection The collection to sample. + * @returns {*} Returns the random element. + */ + function baseSample(collection) { + return arraySample(values$1(collection)); + } + /** + * The base implementation of `_.sampleSize` without param guards. + * + * @private + * @param {Array|Object} collection The collection to sample. + * @param {number} n The number of elements to sample. + * @returns {Array} Returns the random elements. + */ + function baseSampleSize(collection, n$3) { + var array = values$1(collection); + return shuffleSelf(array, baseClamp(n$3, 0, array.length)); + } + /** + * The base implementation of `_.set`. + * + * @private + * @param {Object} object The object to modify. + * @param {Array|string} path The path of the property to set. + * @param {*} value The value to set. + * @param {Function} [customizer] The function to customize path creation. + * @returns {Object} Returns `object`. + */ + function baseSet(object$3, path$28, value, customizer) { + if (!isObject$5(object$3)) return object$3; + path$28 = castPath(path$28, object$3); + var index$1 = -1, length = path$28.length, lastIndex = length - 1, nested = object$3; + while (nested != null && ++index$1 < length) { + var key = toKey(path$28[index$1]), newValue = value; + if (key === "__proto__" || key === "constructor" || key === "prototype") return object$3; + if (index$1 != lastIndex) { + var objValue = nested[key]; + newValue = customizer ? customizer(objValue, key, nested) : undefined$1; + if (newValue === undefined$1) newValue = isObject$5(objValue) ? objValue : isIndex(path$28[index$1 + 1]) ? [] : {}; + } + assignValue(nested, key, newValue); + nested = nested[key]; + } + return object$3; + } + /** + * The base implementation of `setData` without support for hot loop shorting. + * + * @private + * @param {Function} func The function to associate metadata with. + * @param {*} data The metadata. + * @returns {Function} Returns `func`. + */ + var baseSetData = !metaMap ? identity$2 : function(func, data$2) { + metaMap.set(func, data$2); + return func; + }; + /** + * 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$1 ? identity$2 : function(func, string$3) { + return defineProperty$1(func, "toString", { + "configurable": true, + "enumerable": false, + "value": constant$1(string$3), + "writable": true + }); + }; + /** + * The base implementation of `_.shuffle`. + * + * @private + * @param {Array|Object} collection The collection to shuffle. + * @returns {Array} Returns the new shuffled array. + */ + function baseShuffle(collection) { + return shuffleSelf(values$1(collection)); + } + /** + * The base implementation of `_.slice` without an iteratee call guard. + * + * @private + * @param {Array} array The array to slice. + * @param {number} [start=0] The start position. + * @param {number} [end=array.length] The end position. + * @returns {Array} Returns the slice of `array`. + */ + function baseSlice$1(array, start, end) { + var index$1 = -1, length = array.length; + if (start < 0) start = -start > length ? 0 : length + start; + end = end > length ? length : end; + if (end < 0) end += length; + length = start > end ? 0 : end - start >>> 0; + start >>>= 0; + var result$2 = Array$1(length); + while (++index$1 < length) result$2[index$1] = array[index$1 + start]; + return result$2; + } + /** + * The base implementation of `_.some` without support for iteratee shorthands. + * + * @private + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} predicate The function invoked per iteration. + * @returns {boolean} Returns `true` if any element passes the predicate check, + * else `false`. + */ + function baseSome(collection, predicate) { + var result$2; + baseEach(collection, function(value, index$1, collection$1) { + result$2 = predicate(value, index$1, collection$1); + return !result$2; + }); + return !!result$2; + } + /** + * The base implementation of `_.sortedIndex` and `_.sortedLastIndex` which + * performs a binary search of `array` to determine the index at which `value` + * should be inserted into `array` in order to maintain its sort order. + * + * @private + * @param {Array} array The sorted array to inspect. + * @param {*} value The value to evaluate. + * @param {boolean} [retHighest] Specify returning the highest qualified index. + * @returns {number} Returns the index at which `value` should be inserted + * into `array`. + */ + function baseSortedIndex(array, value, retHighest) { + var low = 0, high = array == null ? low : array.length; + if (typeof value == "number" && value === value && high <= HALF_MAX_ARRAY_LENGTH) { + while (low < high) { + var mid = low + high >>> 1, computed = array[mid]; + if (computed !== null && !isSymbol$2(computed) && (retHighest ? computed <= value : computed < value)) low = mid + 1; + else high = mid; + } + return high; + } + return baseSortedIndexBy(array, value, identity$2, retHighest); + } + /** + * The base implementation of `_.sortedIndexBy` and `_.sortedLastIndexBy` + * which invokes `iteratee` for `value` and each element of `array` to compute + * their sort ranking. The iteratee is invoked with one argument; (value). + * + * @private + * @param {Array} array The sorted array to inspect. + * @param {*} value The value to evaluate. + * @param {Function} iteratee The iteratee invoked per element. + * @param {boolean} [retHighest] Specify returning the highest qualified index. + * @returns {number} Returns the index at which `value` should be inserted + * into `array`. + */ + function baseSortedIndexBy(array, value, iteratee$2, retHighest) { + var low = 0, high = array == null ? 0 : array.length; + if (high === 0) return 0; + value = iteratee$2(value); + var valIsNaN = value !== value, valIsNull = value === null, valIsSymbol = isSymbol$2(value), valIsUndefined = value === undefined$1; + while (low < high) { + var mid = nativeFloor((low + high) / 2), computed = iteratee$2(array[mid]), othIsDefined = computed !== undefined$1, othIsNull = computed === null, othIsReflexive = computed === computed, othIsSymbol = isSymbol$2(computed); + if (valIsNaN) var setLow = retHighest || othIsReflexive; + else if (valIsUndefined) setLow = othIsReflexive && (retHighest || othIsDefined); + else if (valIsNull) setLow = othIsReflexive && othIsDefined && (retHighest || !othIsNull); + else if (valIsSymbol) setLow = othIsReflexive && othIsDefined && !othIsNull && (retHighest || !othIsSymbol); + else if (othIsNull || othIsSymbol) setLow = false; + else setLow = retHighest ? computed <= value : computed < value; + if (setLow) low = mid + 1; + else high = mid; + } + return nativeMin(high, MAX_ARRAY_INDEX$1); + } + /** + * The base implementation of `_.sortedUniq` and `_.sortedUniqBy` without + * support for iteratee shorthands. + * + * @private + * @param {Array} array The array to inspect. + * @param {Function} [iteratee] The iteratee invoked per element. + * @returns {Array} Returns the new duplicate free array. + */ + function baseSortedUniq(array, iteratee$2) { + var index$1 = -1, length = array.length, resIndex = 0, result$2 = []; + while (++index$1 < length) { + var value = array[index$1], computed = iteratee$2 ? iteratee$2(value) : value; + if (!index$1 || !eq$1(computed, seen$1)) { + var seen$1 = computed; + result$2[resIndex++] = value === 0 ? 0 : value; + } + } + return result$2; + } + /** + * The base implementation of `_.toNumber` which doesn't ensure correct + * conversions of binary, hexadecimal, or octal string values. + * + * @private + * @param {*} value The value to process. + * @returns {number} Returns the number. + */ + function baseToNumber(value) { + if (typeof value == "number") return value; + if (isSymbol$2(value)) return NAN; + return +value; + } + /** + * The base implementation of `_.toString` which doesn't convert nullish + * values to empty strings. + * + * @private + * @param {*} value The value to process. + * @returns {string} Returns the string. + */ + function baseToString$1(value) { + if (typeof value == "string") return value; + if (isArray$5(value)) return arrayMap(value, baseToString$1) + ""; + if (isSymbol$2(value)) return symbolToString$1 ? symbolToString$1.call(value) : ""; + var result$2 = value + ""; + return result$2 == "0" && 1 / value == -INFINITY$1 ? "-0" : result$2; + } + /** + * 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$2, comparator) { + var index$1 = -1, includes$1 = arrayIncludes, length = array.length, isCommon = true, result$2 = [], seen$1 = result$2; + if (comparator) { + isCommon = false; + includes$1 = arrayIncludesWith; + } else if (length >= LARGE_ARRAY_SIZE) { + var set$1 = iteratee$2 ? null : createSet(array); + if (set$1) return setToArray(set$1); + isCommon = false; + includes$1 = cacheHas; + seen$1 = new SetCache(); + } else seen$1 = iteratee$2 ? [] : result$2; + outer: while (++index$1 < length) { + var value = array[index$1], computed = iteratee$2 ? iteratee$2(value) : value; + value = comparator || value !== 0 ? value : 0; + if (isCommon && computed === computed) { + var seenIndex = seen$1.length; + while (seenIndex--) if (seen$1[seenIndex] === computed) continue outer; + if (iteratee$2) seen$1.push(computed); + result$2.push(value); + } else if (!includes$1(seen$1, computed, comparator)) { + if (seen$1 !== result$2) seen$1.push(computed); + result$2.push(value); + } + } + return result$2; + } + /** + * The base implementation of `_.unset`. + * + * @private + * @param {Object} object The object to modify. + * @param {Array|string} path The property path to unset. + * @returns {boolean} Returns `true` if the property is deleted, else `false`. + */ + function baseUnset(object$3, path$28) { + path$28 = castPath(path$28, object$3); + object$3 = parent(object$3, path$28); + return object$3 == null || delete object$3[toKey(last$3(path$28))]; + } + /** + * The base implementation of `_.update`. + * + * @private + * @param {Object} object The object to modify. + * @param {Array|string} path The path of the property to update. + * @param {Function} updater The function to produce the updated value. + * @param {Function} [customizer] The function to customize path creation. + * @returns {Object} Returns `object`. + */ + function baseUpdate(object$3, path$28, updater, customizer) { + return baseSet(object$3, path$28, updater(baseGet(object$3, path$28)), customizer); + } + /** + * The base implementation of methods like `_.dropWhile` and `_.takeWhile` + * without support for iteratee shorthands. + * + * @private + * @param {Array} array The array to query. + * @param {Function} predicate The function invoked per iteration. + * @param {boolean} [isDrop] Specify dropping elements instead of taking them. + * @param {boolean} [fromRight] Specify iterating from right to left. + * @returns {Array} Returns the slice of `array`. + */ + function baseWhile(array, predicate, isDrop, fromRight) { + var length = array.length, index$1 = fromRight ? length : -1; + while ((fromRight ? index$1-- : ++index$1 < length) && predicate(array[index$1], index$1, array)); + return isDrop ? baseSlice$1(array, fromRight ? 0 : index$1, fromRight ? index$1 + 1 : length) : baseSlice$1(array, fromRight ? index$1 + 1 : 0, fromRight ? length : index$1); + } + /** + * The base implementation of `wrapperValue` which returns the result of + * performing a sequence of actions on the unwrapped `value`, where each + * successive action is supplied the return value of the previous. + * + * @private + * @param {*} value The unwrapped value. + * @param {Array} actions Actions to perform to resolve the unwrapped value. + * @returns {*} Returns the resolved value. + */ + function baseWrapperValue(value, actions) { + var result$2 = value; + if (result$2 instanceof LazyWrapper) result$2 = result$2.value(); + return arrayReduce$1(actions, function(result$3, action) { + return action.func.apply(action.thisArg, arrayPush([result$3], action.args)); + }, result$2); + } + /** + * The base implementation of methods like `_.xor`, without support for + * iteratee shorthands, that accepts an array of arrays to inspect. + * + * @private + * @param {Array} arrays The arrays to inspect. + * @param {Function} [iteratee] The iteratee invoked per element. + * @param {Function} [comparator] The comparator invoked per element. + * @returns {Array} Returns the new array of values. + */ + function baseXor(arrays, iteratee$2, comparator) { + var length = arrays.length; + if (length < 2) return length ? baseUniq(arrays[0]) : []; + var index$1 = -1, result$2 = Array$1(length); + while (++index$1 < length) { + var array = arrays[index$1], othIndex = -1; + while (++othIndex < length) if (othIndex != index$1) result$2[index$1] = baseDifference(result$2[index$1] || array, arrays[othIndex], iteratee$2, comparator); + } + return baseUniq(baseFlatten(result$2, 1), iteratee$2, comparator); + } + /** + * This base implementation of `_.zipObject` which assigns values using `assignFunc`. + * + * @private + * @param {Array} props The property identifiers. + * @param {Array} values The property values. + * @param {Function} assignFunc The function to assign values. + * @returns {Object} Returns the new object. + */ + function baseZipObject(props, values$2, assignFunc) { + var index$1 = -1, length = props.length, valsLength = values$2.length, result$2 = {}; + while (++index$1 < length) { + var value = index$1 < valsLength ? values$2[index$1] : undefined$1; + assignFunc(result$2, props[index$1], value); + } + return result$2; + } + /** + * Casts `value` to an empty array if it's not an array like object. + * + * @private + * @param {*} value The value to inspect. + * @returns {Array|Object} Returns the cast array-like object. + */ + function castArrayLikeObject(value) { + return isArrayLikeObject(value) ? value : []; + } + /** + * Casts `value` to `identity` if it's not a function. + * + * @private + * @param {*} value The value to inspect. + * @returns {Function} Returns cast function. + */ + function castFunction(value) { + return typeof value == "function" ? value : identity$2; + } + /** + * Casts `value` to a path array if it's not one. + * + * @private + * @param {*} value The value to inspect. + * @param {Object} [object] The object to query keys on. + * @returns {Array} Returns the cast property path array. + */ + function castPath(value, object$3) { + if (isArray$5(value)) return value; + return isKey(value, object$3) ? [value] : stringToPath(toString$6(value)); + } + /** + * A `baseRest` alias which can be replaced with `identity` by module + * replacement plugins. + * + * @private + * @type {Function} + * @param {Function} func The function to apply a rest parameter to. + * @returns {Function} Returns the new function. + */ + var castRest = baseRest; + /** + * Casts `array` to a slice if it's needed. + * + * @private + * @param {Array} array The array to inspect. + * @param {number} start The start position. + * @param {number} [end=array.length] The end position. + * @returns {Array} Returns the cast slice. + */ + function castSlice$1(array, start, end) { + var length = array.length; + end = end === undefined$1 ? length : end; + return !start && end >= length ? array : baseSlice$1(array, start, end); + } + /** + * A simple wrapper around the global [`clearTimeout`](https://mdn.io/clearTimeout). + * + * @private + * @param {number|Object} id The timer id or timeout object of the timer to clear. + */ + var clearTimeout$1 = ctxClearTimeout || function(id$4) { + return root$6.clearTimeout(id$4); + }; + /** + * Creates a clone of `buffer`. + * + * @private + * @param {Buffer} buffer The buffer to clone. + * @param {boolean} [isDeep] Specify a deep clone. + * @returns {Buffer} Returns the cloned buffer. + */ + function cloneBuffer(buffer, isDeep) { + if (isDeep) return buffer.slice(); + var length = buffer.length, result$2 = allocUnsafe ? allocUnsafe(length) : new buffer.constructor(length); + buffer.copy(result$2); + return result$2; + } + /** + * Creates a clone of `arrayBuffer`. + * + * @private + * @param {ArrayBuffer} arrayBuffer The array buffer to clone. + * @returns {ArrayBuffer} Returns the cloned array buffer. + */ + function cloneArrayBuffer(arrayBuffer) { + var result$2 = new arrayBuffer.constructor(arrayBuffer.byteLength); + new Uint8Array$1(result$2).set(new Uint8Array$1(arrayBuffer)); + return result$2; + } + /** + * Creates a clone of `dataView`. + * + * @private + * @param {Object} dataView The data view to clone. + * @param {boolean} [isDeep] Specify a deep clone. + * @returns {Object} Returns the cloned data view. + */ + function cloneDataView(dataView, isDeep) { + var buffer = isDeep ? cloneArrayBuffer(dataView.buffer) : dataView.buffer; + return new dataView.constructor(buffer, dataView.byteOffset, dataView.byteLength); + } + /** + * Creates a clone of `regexp`. + * + * @private + * @param {Object} regexp The regexp to clone. + * @returns {Object} Returns the cloned regexp. + */ + function cloneRegExp(regexp) { + var result$2 = new regexp.constructor(regexp.source, reFlags.exec(regexp)); + result$2.lastIndex = regexp.lastIndex; + return result$2; + } + /** + * Creates a clone of the `symbol` object. + * + * @private + * @param {Object} symbol The symbol object to clone. + * @returns {Object} Returns the cloned symbol object. + */ + function cloneSymbol(symbol) { + return symbolValueOf ? Object$1(symbolValueOf.call(symbol)) : {}; + } + /** + * Creates a clone of `typedArray`. + * + * @private + * @param {Object} typedArray The typed array to clone. + * @param {boolean} [isDeep] Specify a deep clone. + * @returns {Object} Returns the cloned typed array. + */ + function cloneTypedArray(typedArray, isDeep) { + var buffer = isDeep ? cloneArrayBuffer(typedArray.buffer) : typedArray.buffer; + return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length); + } + /** + * Compares values to sort them in ascending order. + * + * @private + * @param {*} value The value to compare. + * @param {*} other The other value to compare. + * @returns {number} Returns the sort order indicator for `value`. + */ + function compareAscending(value, other) { + if (value !== other) { + var valIsDefined = value !== undefined$1, valIsNull = value === null, valIsReflexive = value === value, valIsSymbol = isSymbol$2(value); + var othIsDefined = other !== undefined$1, othIsNull = other === null, othIsReflexive = other === other, othIsSymbol = isSymbol$2(other); + if (!othIsNull && !othIsSymbol && !valIsSymbol && value > other || valIsSymbol && othIsDefined && othIsReflexive && !othIsNull && !othIsSymbol || valIsNull && othIsDefined && othIsReflexive || !valIsDefined && othIsReflexive || !valIsReflexive) return 1; + if (!valIsNull && !valIsSymbol && !othIsSymbol && value < other || othIsSymbol && valIsDefined && valIsReflexive && !valIsNull && !valIsSymbol || othIsNull && valIsDefined && valIsReflexive || !othIsDefined && valIsReflexive || !othIsReflexive) return -1; + } + return 0; + } + /** + * Used by `_.orderBy` to compare multiple properties of a value to another + * and stable sort them. + * + * If `orders` is unspecified, all values are sorted in ascending order. Otherwise, + * specify an order of "desc" for descending or "asc" for ascending sort order + * of corresponding values. + * + * @private + * @param {Object} object The object to compare. + * @param {Object} other The other object to compare. + * @param {boolean[]|string[]} orders The order to sort by for each property. + * @returns {number} Returns the sort order indicator for `object`. + */ + function compareMultiple(object$3, other, orders) { + var index$1 = -1, objCriteria = object$3.criteria, othCriteria = other.criteria, length = objCriteria.length, ordersLength = orders.length; + while (++index$1 < length) { + var result$2 = compareAscending(objCriteria[index$1], othCriteria[index$1]); + if (result$2) { + if (index$1 >= ordersLength) return result$2; + var order = orders[index$1]; + return result$2 * (order == "desc" ? -1 : 1); + } + } + return object$3.index - other.index; + } + /** + * Creates an array that is the composition of partially applied arguments, + * placeholders, and provided arguments into a single array of arguments. + * + * @private + * @param {Array} args The provided arguments. + * @param {Array} partials The arguments to prepend to those provided. + * @param {Array} holders The `partials` placeholder indexes. + * @params {boolean} [isCurried] Specify composing for a curried function. + * @returns {Array} Returns the new array of composed arguments. + */ + function composeArgs(args, partials, holders, isCurried) { + var argsIndex = -1, argsLength = args.length, holdersLength = holders.length, leftIndex = -1, leftLength = partials.length, rangeLength = nativeMax(argsLength - holdersLength, 0), result$2 = Array$1(leftLength + rangeLength), isUncurried = !isCurried; + while (++leftIndex < leftLength) result$2[leftIndex] = partials[leftIndex]; + while (++argsIndex < holdersLength) if (isUncurried || argsIndex < argsLength) result$2[holders[argsIndex]] = args[argsIndex]; + while (rangeLength--) result$2[leftIndex++] = args[argsIndex++]; + return result$2; + } + /** + * This function is like `composeArgs` except that the arguments composition + * is tailored for `_.partialRight`. + * + * @private + * @param {Array} args The provided arguments. + * @param {Array} partials The arguments to append to those provided. + * @param {Array} holders The `partials` placeholder indexes. + * @params {boolean} [isCurried] Specify composing for a curried function. + * @returns {Array} Returns the new array of composed arguments. + */ + function composeArgsRight(args, partials, holders, isCurried) { + var argsIndex = -1, argsLength = args.length, holdersIndex = -1, holdersLength = holders.length, rightIndex = -1, rightLength = partials.length, rangeLength = nativeMax(argsLength - holdersLength, 0), result$2 = Array$1(rangeLength + rightLength), isUncurried = !isCurried; + while (++argsIndex < rangeLength) result$2[argsIndex] = args[argsIndex]; + var offset = argsIndex; + while (++rightIndex < rightLength) result$2[offset + rightIndex] = partials[rightIndex]; + while (++holdersIndex < holdersLength) if (isUncurried || argsIndex < argsLength) result$2[offset + holders[holdersIndex]] = args[argsIndex++]; + return result$2; + } + /** + * Copies the values of `source` to `array`. + * + * @private + * @param {Array} source The array to copy values from. + * @param {Array} [array=[]] The array to copy values to. + * @returns {Array} Returns `array`. + */ + function copyArray(source, array) { + var index$1 = -1, length = source.length; + array || (array = Array$1(length)); + while (++index$1 < length) array[index$1] = source[index$1]; + return array; + } + /** + * Copies properties of `source` to `object`. + * + * @private + * @param {Object} source The object to copy properties from. + * @param {Array} props The property identifiers to copy. + * @param {Object} [object={}] The object to copy properties to. + * @param {Function} [customizer] The function to customize copied values. + * @returns {Object} Returns `object`. + */ + function copyObject(source, props, object$3, customizer) { + var isNew = !object$3; + object$3 || (object$3 = {}); + var index$1 = -1, length = props.length; + while (++index$1 < length) { + var key = props[index$1]; + var newValue = customizer ? customizer(object$3[key], source[key], key, object$3, source) : undefined$1; + if (newValue === undefined$1) newValue = source[key]; + if (isNew) baseAssignValue(object$3, key, newValue); + else assignValue(object$3, key, newValue); + } + return object$3; + } + /** + * Copies own symbols of `source` to `object`. + * + * @private + * @param {Object} source The object to copy symbols from. + * @param {Object} [object={}] The object to copy symbols to. + * @returns {Object} Returns `object`. + */ + function copySymbols(source, object$3) { + return copyObject(source, getSymbols(source), object$3); + } + /** + * Copies own and inherited symbols of `source` to `object`. + * + * @private + * @param {Object} source The object to copy symbols from. + * @param {Object} [object={}] The object to copy symbols to. + * @returns {Object} Returns `object`. + */ + function copySymbolsIn(source, object$3) { + return copyObject(source, getSymbolsIn(source), object$3); + } + /** + * Creates a function like `_.groupBy`. + * + * @private + * @param {Function} setter The function to set accumulator values. + * @param {Function} [initializer] The accumulator object initializer. + * @returns {Function} Returns the new aggregator function. + */ + function createAggregator(setter, initializer) { + return function(collection, iteratee$2) { + var func = isArray$5(collection) ? arrayAggregator : baseAggregator, accumulator = initializer ? initializer() : {}; + return func(collection, setter, getIteratee(iteratee$2, 2), accumulator); + }; + } + /** + * Creates a function like `_.assign`. + * + * @private + * @param {Function} assigner The function to assign values. + * @returns {Function} Returns the new assigner function. + */ + function createAssigner$1(assigner) { + return baseRest(function(object$3, sources) { + var index$1 = -1, length = sources.length, customizer = length > 1 ? sources[length - 1] : undefined$1, guard = length > 2 ? sources[2] : undefined$1; + customizer = assigner.length > 3 && typeof customizer == "function" ? (length--, customizer) : undefined$1; + if (guard && isIterateeCall(sources[0], sources[1], guard)) { + customizer = length < 3 ? undefined$1 : customizer; + length = 1; + } + object$3 = Object$1(object$3); + while (++index$1 < length) { + var source = sources[index$1]; + if (source) assigner(object$3, source, index$1, customizer); + } + return object$3; + }); + } + /** + * Creates a `baseEach` or `baseEachRight` function. + * + * @private + * @param {Function} eachFunc The function to iterate over a collection. + * @param {boolean} [fromRight] Specify iterating from right to left. + * @returns {Function} Returns the new base function. + */ + function createBaseEach(eachFunc, fromRight) { + return function(collection, iteratee$2) { + if (collection == null) return collection; + if (!isArrayLike(collection)) return eachFunc(collection, iteratee$2); + var length = collection.length, index$1 = fromRight ? length : -1, iterable = Object$1(collection); + while (fromRight ? index$1-- : ++index$1 < length) if (iteratee$2(iterable[index$1], index$1, iterable) === false) break; + return collection; + }; + } + /** + * Creates a base function for methods like `_.forIn` and `_.forOwn`. + * + * @private + * @param {boolean} [fromRight] Specify iterating from right to left. + * @returns {Function} Returns the new base function. + */ + function createBaseFor(fromRight) { + return function(object$3, iteratee$2, keysFunc) { + var index$1 = -1, iterable = Object$1(object$3), props = keysFunc(object$3), length = props.length; + while (length--) { + var key = props[fromRight ? length : ++index$1]; + if (iteratee$2(iterable[key], key, iterable) === false) break; + } + return object$3; + }; + } + /** + * Creates a function that wraps `func` to invoke it with the optional `this` + * binding of `thisArg`. + * + * @private + * @param {Function} func The function to wrap. + * @param {number} bitmask The bitmask flags. See `createWrap` for more details. + * @param {*} [thisArg] The `this` binding of `func`. + * @returns {Function} Returns the new wrapped function. + */ + function createBind(func, bitmask, thisArg) { + var isBind = bitmask & WRAP_BIND_FLAG, Ctor = createCtor(func); + function wrapper() { + var fn = this && this !== root$6 && this instanceof wrapper ? Ctor : func; + return fn.apply(isBind ? thisArg : this, arguments); + } + return wrapper; + } + /** + * Creates a function like `_.lowerFirst`. + * + * @private + * @param {string} methodName The name of the `String` case method to use. + * @returns {Function} Returns the new case function. + */ + function createCaseFirst$1(methodName) { + return function(string$3) { + string$3 = toString$6(string$3); + var strSymbols = hasUnicode$1(string$3) ? stringToArray$1(string$3) : undefined$1; + var chr = strSymbols ? strSymbols[0] : string$3.charAt(0); + var trailing = strSymbols ? castSlice$1(strSymbols, 1).join("") : string$3.slice(1); + return chr[methodName]() + trailing; + }; + } + /** + * Creates a function like `_.camelCase`. + * + * @private + * @param {Function} callback The function to combine each word. + * @returns {Function} Returns the new compounder function. + */ + function createCompounder$1(callback) { + return function(string$3) { + return arrayReduce$1(words$1(deburr$1(string$3).replace(reApos$1, "")), callback, ""); + }; + } + /** + * Creates a function that produces an instance of `Ctor` regardless of + * whether it was invoked as part of a `new` expression or by `call` or `apply`. + * + * @private + * @param {Function} Ctor The constructor to wrap. + * @returns {Function} Returns the new wrapped function. + */ + function createCtor(Ctor) { + return function() { + var args = arguments; + switch (args.length) { + case 0: return new Ctor(); + case 1: return new Ctor(args[0]); + case 2: return new Ctor(args[0], args[1]); + case 3: return new Ctor(args[0], args[1], args[2]); + case 4: return new Ctor(args[0], args[1], args[2], args[3]); + case 5: return new Ctor(args[0], args[1], args[2], args[3], args[4]); + case 6: return new Ctor(args[0], args[1], args[2], args[3], args[4], args[5]); + case 7: return new Ctor(args[0], args[1], args[2], args[3], args[4], args[5], args[6]); + } + var thisBinding = baseCreate$1(Ctor.prototype), result$2 = Ctor.apply(thisBinding, args); + return isObject$5(result$2) ? result$2 : thisBinding; + }; + } + /** + * Creates a function that wraps `func` to enable currying. + * + * @private + * @param {Function} func The function to wrap. + * @param {number} bitmask The bitmask flags. See `createWrap` for more details. + * @param {number} arity The arity of `func`. + * @returns {Function} Returns the new wrapped function. + */ + function createCurry(func, bitmask, arity) { + var Ctor = createCtor(func); + function wrapper() { + var length = arguments.length, args = Array$1(length), index$1 = length, placeholder$1 = getHolder(wrapper); + while (index$1--) args[index$1] = arguments[index$1]; + var holders = length < 3 && args[0] !== placeholder$1 && args[length - 1] !== placeholder$1 ? [] : replaceHolders(args, placeholder$1); + length -= holders.length; + if (length < arity) return createRecurry(func, bitmask, createHybrid, wrapper.placeholder, undefined$1, args, holders, undefined$1, undefined$1, arity - length); + var fn = this && this !== root$6 && this instanceof wrapper ? Ctor : func; + return apply(fn, this, args); + } + return wrapper; + } + /** + * Creates a `_.find` or `_.findLast` function. + * + * @private + * @param {Function} findIndexFunc The function to find the collection index. + * @returns {Function} Returns the new find function. + */ + function createFind(findIndexFunc) { + return function(collection, predicate, fromIndex) { + var iterable = Object$1(collection); + if (!isArrayLike(collection)) { + var iteratee$2 = getIteratee(predicate, 3); + collection = keys$2(collection); + predicate = function(key) { + return iteratee$2(iterable[key], key, iterable); + }; + } + var index$1 = findIndexFunc(collection, predicate, fromIndex); + return index$1 > -1 ? iterable[iteratee$2 ? collection[index$1] : index$1] : undefined$1; + }; + } + /** + * Creates a `_.flow` or `_.flowRight` function. + * + * @private + * @param {boolean} [fromRight] Specify iterating from right to left. + * @returns {Function} Returns the new flow function. + */ + function createFlow(fromRight) { + return flatRest(function(funcs) { + var length = funcs.length, index$1 = length, prereq = LodashWrapper.prototype.thru; + if (fromRight) funcs.reverse(); + while (index$1--) { + var func = funcs[index$1]; + if (typeof func != "function") throw new TypeError$1(FUNC_ERROR_TEXT); + if (prereq && !wrapper && getFuncName(func) == "wrapper") var wrapper = new LodashWrapper([], true); + } + index$1 = wrapper ? index$1 : length; + while (++index$1 < length) { + func = funcs[index$1]; + var funcName = getFuncName(func), data$2 = funcName == "wrapper" ? getData(func) : undefined$1; + if (data$2 && isLaziable(data$2[0]) && data$2[1] == (WRAP_ARY_FLAG | WRAP_CURRY_FLAG | WRAP_PARTIAL_FLAG | WRAP_REARG_FLAG) && !data$2[4].length && data$2[9] == 1) wrapper = wrapper[getFuncName(data$2[0])].apply(wrapper, data$2[3]); + else wrapper = func.length == 1 && isLaziable(func) ? wrapper[funcName]() : wrapper.thru(func); + } + return function() { + var args = arguments, value = args[0]; + if (wrapper && args.length == 1 && isArray$5(value)) return wrapper.plant(value).value(); + var index$2 = 0, result$2 = length ? funcs[index$2].apply(this, args) : value; + while (++index$2 < length) result$2 = funcs[index$2].call(this, result$2); + return result$2; + }; + }); + } + /** + * Creates a function that wraps `func` to invoke it with optional `this` + * binding of `thisArg`, partial application, and currying. + * + * @private + * @param {Function|string} func The function or method name to wrap. + * @param {number} bitmask The bitmask flags. See `createWrap` for more details. + * @param {*} [thisArg] The `this` binding of `func`. + * @param {Array} [partials] The arguments to prepend to those provided to + * the new function. + * @param {Array} [holders] The `partials` placeholder indexes. + * @param {Array} [partialsRight] The arguments to append to those provided + * to the new function. + * @param {Array} [holdersRight] The `partialsRight` placeholder indexes. + * @param {Array} [argPos] The argument positions of the new function. + * @param {number} [ary] The arity cap of `func`. + * @param {number} [arity] The arity of `func`. + * @returns {Function} Returns the new wrapped function. + */ + function createHybrid(func, bitmask, thisArg, partials, holders, partialsRight, holdersRight, argPos, ary$1, arity) { + var isAry = bitmask & WRAP_ARY_FLAG, isBind = bitmask & WRAP_BIND_FLAG, isBindKey$1 = bitmask & WRAP_BIND_KEY_FLAG, isCurried = bitmask & (WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG), isFlip = bitmask & WRAP_FLIP_FLAG, Ctor = isBindKey$1 ? undefined$1 : createCtor(func); + function wrapper() { + var length = arguments.length, args = Array$1(length), index$1 = length; + while (index$1--) args[index$1] = arguments[index$1]; + if (isCurried) var placeholder$1 = getHolder(wrapper), holdersCount = countHolders(args, placeholder$1); + if (partials) args = composeArgs(args, partials, holders, isCurried); + if (partialsRight) args = composeArgsRight(args, partialsRight, holdersRight, isCurried); + length -= holdersCount; + if (isCurried && length < arity) { + var newHolders = replaceHolders(args, placeholder$1); + return createRecurry(func, bitmask, createHybrid, wrapper.placeholder, thisArg, args, newHolders, argPos, ary$1, arity - length); + } + var thisBinding = isBind ? thisArg : this, fn = isBindKey$1 ? thisBinding[func] : func; + length = args.length; + if (argPos) args = reorder(args, argPos); + else if (isFlip && length > 1) args.reverse(); + if (isAry && ary$1 < length) args.length = ary$1; + if (this && this !== root$6 && this instanceof wrapper) fn = Ctor || createCtor(fn); + return fn.apply(thisBinding, args); + } + return wrapper; + } + /** + * Creates a function like `_.invertBy`. + * + * @private + * @param {Function} setter The function to set accumulator values. + * @param {Function} toIteratee The function to resolve iteratees. + * @returns {Function} Returns the new inverter function. + */ + function createInverter(setter, toIteratee) { + return function(object$3, iteratee$2) { + return baseInverter(object$3, setter, toIteratee(iteratee$2), {}); + }; + } + /** + * Creates a function that performs a mathematical operation on two values. + * + * @private + * @param {Function} operator The function to perform the operation. + * @param {number} [defaultValue] The value used for `undefined` arguments. + * @returns {Function} Returns the new mathematical operation function. + */ + function createMathOperation(operator$1, defaultValue) { + return function(value, other) { + var result$2; + if (value === undefined$1 && other === undefined$1) return defaultValue; + if (value !== undefined$1) result$2 = value; + if (other !== undefined$1) { + if (result$2 === undefined$1) return other; + if (typeof value == "string" || typeof other == "string") { + value = baseToString$1(value); + other = baseToString$1(other); + } else { + value = baseToNumber(value); + other = baseToNumber(other); + } + result$2 = operator$1(value, other); + } + return result$2; + }; + } + /** + * Creates a function like `_.over`. + * + * @private + * @param {Function} arrayFunc The function to iterate over iteratees. + * @returns {Function} Returns the new over function. + */ + function createOver(arrayFunc) { + return flatRest(function(iteratees) { + iteratees = arrayMap(iteratees, baseUnary(getIteratee())); + return baseRest(function(args) { + var thisArg = this; + return arrayFunc(iteratees, function(iteratee$2) { + return apply(iteratee$2, thisArg, args); + }); + }); + }); + } + /** + * Creates the padding for `string` based on `length`. The `chars` string + * is truncated if the number of characters exceeds `length`. + * + * @private + * @param {number} length The padding length. + * @param {string} [chars=' '] The string used as padding. + * @returns {string} Returns the padding for `string`. + */ + function createPadding(length, chars$1) { + chars$1 = chars$1 === undefined$1 ? " " : baseToString$1(chars$1); + var charsLength = chars$1.length; + if (charsLength < 2) return charsLength ? baseRepeat(chars$1, length) : chars$1; + var result$2 = baseRepeat(chars$1, nativeCeil(length / stringSize(chars$1))); + return hasUnicode$1(chars$1) ? castSlice$1(stringToArray$1(result$2), 0, length).join("") : result$2.slice(0, length); + } + /** + * Creates a function that wraps `func` to invoke it with the `this` binding + * of `thisArg` and `partials` prepended to the arguments it receives. + * + * @private + * @param {Function} func The function to wrap. + * @param {number} bitmask The bitmask flags. See `createWrap` for more details. + * @param {*} thisArg The `this` binding of `func`. + * @param {Array} partials The arguments to prepend to those provided to + * the new function. + * @returns {Function} Returns the new wrapped function. + */ + function createPartial(func, bitmask, thisArg, partials) { + var isBind = bitmask & WRAP_BIND_FLAG, Ctor = createCtor(func); + function wrapper() { + var argsIndex = -1, argsLength = arguments.length, leftIndex = -1, leftLength = partials.length, args = Array$1(leftLength + argsLength), fn = this && this !== root$6 && this instanceof wrapper ? Ctor : func; + while (++leftIndex < leftLength) args[leftIndex] = partials[leftIndex]; + while (argsLength--) args[leftIndex++] = arguments[++argsIndex]; + return apply(fn, isBind ? thisArg : this, args); + } + return wrapper; + } + /** + * Creates a `_.range` or `_.rangeRight` function. + * + * @private + * @param {boolean} [fromRight] Specify iterating from right to left. + * @returns {Function} Returns the new range function. + */ + function createRange(fromRight) { + return function(start, end, step) { + if (step && typeof step != "number" && isIterateeCall(start, end, step)) end = step = undefined$1; + start = toFinite(start); + if (end === undefined$1) { + end = start; + start = 0; + } else end = toFinite(end); + step = step === undefined$1 ? start < end ? 1 : -1 : toFinite(step); + return baseRange(start, end, step, fromRight); + }; + } + /** + * Creates a function that performs a relational operation on two values. + * + * @private + * @param {Function} operator The function to perform the operation. + * @returns {Function} Returns the new relational operation function. + */ + function createRelationalOperation(operator$1) { + return function(value, other) { + if (!(typeof value == "string" && typeof other == "string")) { + value = toNumber$1(value); + other = toNumber$1(other); + } + return operator$1(value, other); + }; + } + /** + * Creates a function that wraps `func` to continue currying. + * + * @private + * @param {Function} func The function to wrap. + * @param {number} bitmask The bitmask flags. See `createWrap` for more details. + * @param {Function} wrapFunc The function to create the `func` wrapper. + * @param {*} placeholder The placeholder value. + * @param {*} [thisArg] The `this` binding of `func`. + * @param {Array} [partials] The arguments to prepend to those provided to + * the new function. + * @param {Array} [holders] The `partials` placeholder indexes. + * @param {Array} [argPos] The argument positions of the new function. + * @param {number} [ary] The arity cap of `func`. + * @param {number} [arity] The arity of `func`. + * @returns {Function} Returns the new wrapped function. + */ + function createRecurry(func, bitmask, wrapFunc, placeholder$1, thisArg, partials, holders, argPos, ary$1, arity) { + var isCurry = bitmask & WRAP_CURRY_FLAG, newHolders = isCurry ? holders : undefined$1, newHoldersRight = isCurry ? undefined$1 : holders, newPartials = isCurry ? partials : undefined$1, newPartialsRight = isCurry ? undefined$1 : partials; + bitmask |= isCurry ? WRAP_PARTIAL_FLAG : WRAP_PARTIAL_RIGHT_FLAG; + bitmask &= ~(isCurry ? WRAP_PARTIAL_RIGHT_FLAG : WRAP_PARTIAL_FLAG); + if (!(bitmask & WRAP_CURRY_BOUND_FLAG)) bitmask &= ~(WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG); + var newData = [ + func, + bitmask, + thisArg, + newPartials, + newHolders, + newPartialsRight, + newHoldersRight, + argPos, + ary$1, + arity + ]; + var result$2 = wrapFunc.apply(undefined$1, newData); + if (isLaziable(func)) setData(result$2, newData); + result$2.placeholder = placeholder$1; + return setWrapToString(result$2, func, bitmask); + } + /** + * Creates a function like `_.round`. + * + * @private + * @param {string} methodName The name of the `Math` method to use when rounding. + * @returns {Function} Returns the new round function. + */ + function createRound(methodName) { + var func = Math$1[methodName]; + return function(number, precision) { + number = toNumber$1(number); + precision = precision == null ? 0 : nativeMin(toInteger(precision), 292); + if (precision && nativeIsFinite(number)) { + var pair = (toString$6(number) + "e").split("e"), value = func(pair[0] + "e" + (+pair[1] + precision)); + pair = (toString$6(value) + "e").split("e"); + return +(pair[0] + "e" + (+pair[1] - precision)); + } + return func(number); + }; + } + /** + * 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 && 1 / setToArray(new Set$1([, -0]))[1] == INFINITY$1) ? noop$4 : function(values$2) { + return new Set$1(values$2); + }; + /** + * Creates a `_.toPairs` or `_.toPairsIn` function. + * + * @private + * @param {Function} keysFunc The function to get the keys of a given object. + * @returns {Function} Returns the new pairs function. + */ + function createToPairs(keysFunc) { + return function(object$3) { + var tag$3 = getTag(object$3); + if (tag$3 == mapTag) return mapToArray(object$3); + if (tag$3 == setTag) return setToPairs(object$3); + return baseToPairs(object$3, keysFunc(object$3)); + }; + } + /** + * Creates a function that either curries or invokes `func` with optional + * `this` binding and partially applied arguments. + * + * @private + * @param {Function|string} func The function or method name to wrap. + * @param {number} bitmask The bitmask flags. + * 1 - `_.bind` + * 2 - `_.bindKey` + * 4 - `_.curry` or `_.curryRight` of a bound function + * 8 - `_.curry` + * 16 - `_.curryRight` + * 32 - `_.partial` + * 64 - `_.partialRight` + * 128 - `_.rearg` + * 256 - `_.ary` + * 512 - `_.flip` + * @param {*} [thisArg] The `this` binding of `func`. + * @param {Array} [partials] The arguments to be partially applied. + * @param {Array} [holders] The `partials` placeholder indexes. + * @param {Array} [argPos] The argument positions of the new function. + * @param {number} [ary] The arity cap of `func`. + * @param {number} [arity] The arity of `func`. + * @returns {Function} Returns the new wrapped function. + */ + function createWrap(func, bitmask, thisArg, partials, holders, argPos, ary$1, arity) { + var isBindKey$1 = bitmask & WRAP_BIND_KEY_FLAG; + if (!isBindKey$1 && typeof func != "function") throw new TypeError$1(FUNC_ERROR_TEXT); + var length = partials ? partials.length : 0; + if (!length) { + bitmask &= ~(WRAP_PARTIAL_FLAG | WRAP_PARTIAL_RIGHT_FLAG); + partials = holders = undefined$1; + } + ary$1 = ary$1 === undefined$1 ? ary$1 : nativeMax(toInteger(ary$1), 0); + arity = arity === undefined$1 ? arity : toInteger(arity); + length -= holders ? holders.length : 0; + if (bitmask & WRAP_PARTIAL_RIGHT_FLAG) { + var partialsRight = partials, holdersRight = holders; + partials = holders = undefined$1; + } + var data$2 = isBindKey$1 ? undefined$1 : getData(func); + var newData = [ + func, + bitmask, + thisArg, + partials, + holders, + partialsRight, + holdersRight, + argPos, + ary$1, + arity + ]; + if (data$2) mergeData(newData, data$2); + func = newData[0]; + bitmask = newData[1]; + thisArg = newData[2]; + partials = newData[3]; + holders = newData[4]; + arity = newData[9] = newData[9] === undefined$1 ? isBindKey$1 ? 0 : func.length : nativeMax(newData[9] - length, 0); + if (!arity && bitmask & (WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG)) bitmask &= ~(WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG); + if (!bitmask || bitmask == WRAP_BIND_FLAG) var result$2 = createBind(func, bitmask, thisArg); + else if (bitmask == WRAP_CURRY_FLAG || bitmask == WRAP_CURRY_RIGHT_FLAG) result$2 = createCurry(func, bitmask, arity); + else if ((bitmask == WRAP_PARTIAL_FLAG || bitmask == (WRAP_BIND_FLAG | WRAP_PARTIAL_FLAG)) && !holders.length) result$2 = createPartial(func, bitmask, thisArg, partials); + else result$2 = createHybrid.apply(undefined$1, newData); + var setter = data$2 ? baseSetData : setData; + return setWrapToString(setter(result$2, newData), func, bitmask); + } + /** + * Used by `_.defaults` to customize its `_.assignIn` use to assign properties + * of source objects to the destination object for all destination properties + * that resolve to `undefined`. + * + * @private + * @param {*} objValue The destination value. + * @param {*} srcValue The source value. + * @param {string} key The key of the property to assign. + * @param {Object} object The parent object of `objValue`. + * @returns {*} Returns the value to assign. + */ + function customDefaultsAssignIn(objValue, srcValue, key, object$3) { + if (objValue === undefined$1 || eq$1(objValue, objectProto$1[key]) && !hasOwnProperty$6.call(object$3, key)) return srcValue; + return objValue; + } + /** + * Used by `_.defaultsDeep` to customize its `_.merge` use to merge source + * objects into destination objects that are passed thru. + * + * @private + * @param {*} objValue The destination value. + * @param {*} srcValue The source value. + * @param {string} key The key of the property to merge. + * @param {Object} object The parent object of `objValue`. + * @param {Object} source The parent object of `srcValue`. + * @param {Object} [stack] Tracks traversed source values and their merged + * counterparts. + * @returns {*} Returns the value to assign. + */ + function customDefaultsMerge(objValue, srcValue, key, object$3, source, stack) { + if (isObject$5(objValue) && isObject$5(srcValue)) { + stack.set(srcValue, objValue); + baseMerge(objValue, srcValue, undefined$1, customDefaultsMerge, stack); + stack["delete"](srcValue); + } + return objValue; + } + /** + * Used by `_.omit` to customize its `_.cloneDeep` use to only clone plain + * objects. + * + * @private + * @param {*} value The value to inspect. + * @param {string} key The key of the property to inspect. + * @returns {*} Returns the uncloned value or `undefined` to defer cloning to `_.cloneDeep`. + */ + function customOmitClone(value) { + return isPlainObject$2(value) ? undefined$1 : value; + } + /** + * A specialized version of `baseIsEqualDeep` for arrays with support for + * partial deep comparisons. + * + * @private + * @param {Array} array The array to compare. + * @param {Array} other The other array to compare. + * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details. + * @param {Function} customizer The function to customize comparisons. + * @param {Function} equalFunc The function to determine equivalents of values. + * @param {Object} stack Tracks traversed `array` and `other` objects. + * @returns {boolean} Returns `true` if the arrays are equivalent, else `false`. + */ + function equalArrays(array, other, bitmask, customizer, equalFunc, stack) { + var isPartial = bitmask & COMPARE_PARTIAL_FLAG, arrLength = array.length, othLength = other.length; + if (arrLength != othLength && !(isPartial && othLength > arrLength)) return false; + var arrStacked = stack.get(array); + var othStacked = stack.get(other); + if (arrStacked && othStacked) return arrStacked == other && othStacked == array; + var index$1 = -1, result$2 = true, seen$1 = bitmask & COMPARE_UNORDERED_FLAG ? new SetCache() : undefined$1; + stack.set(array, other); + stack.set(other, array); + while (++index$1 < arrLength) { + var arrValue = array[index$1], othValue = other[index$1]; + if (customizer) var compared = isPartial ? customizer(othValue, arrValue, index$1, other, array, stack) : customizer(arrValue, othValue, index$1, array, other, stack); + if (compared !== undefined$1) { + if (compared) continue; + result$2 = false; + break; + } + if (seen$1) { + if (!arraySome(other, function(othValue$1, othIndex) { + if (!cacheHas(seen$1, othIndex) && (arrValue === othValue$1 || equalFunc(arrValue, othValue$1, bitmask, customizer, stack))) return seen$1.push(othIndex); + })) { + result$2 = false; + break; + } + } else if (!(arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) { + result$2 = false; + break; + } + } + stack["delete"](array); + stack["delete"](other); + return result$2; + } + /** + * A specialized version of `baseIsEqualDeep` for comparing objects of + * the same `toStringTag`. + * + * **Note:** This function only supports comparing values with tags of + * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`. + * + * @private + * @param {Object} object The object to compare. + * @param {Object} other The other object to compare. + * @param {string} tag The `toStringTag` of the objects to compare. + * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details. + * @param {Function} customizer The function to customize comparisons. + * @param {Function} equalFunc The function to determine equivalents of values. + * @param {Object} stack Tracks traversed `object` and `other` objects. + * @returns {boolean} Returns `true` if the objects are equivalent, else `false`. + */ + function equalByTag(object$3, other, tag$3, bitmask, customizer, equalFunc, stack) { + switch (tag$3) { + case dataViewTag: + if (object$3.byteLength != other.byteLength || object$3.byteOffset != other.byteOffset) return false; + object$3 = object$3.buffer; + other = other.buffer; + case arrayBufferTag: + if (object$3.byteLength != other.byteLength || !equalFunc(new Uint8Array$1(object$3), new Uint8Array$1(other))) return false; + return true; + case boolTag: + case dateTag: + case numberTag: return eq$1(+object$3, +other); + case errorTag: return object$3.name == other.name && object$3.message == other.message; + case regexpTag: + case stringTag: return object$3 == other + ""; + case mapTag: var convert$3 = mapToArray; + case setTag: + var isPartial = bitmask & COMPARE_PARTIAL_FLAG; + convert$3 || (convert$3 = setToArray); + if (object$3.size != other.size && !isPartial) return false; + var stacked = stack.get(object$3); + if (stacked) return stacked == other; + bitmask |= COMPARE_UNORDERED_FLAG; + stack.set(object$3, other); + var result$2 = equalArrays(convert$3(object$3), convert$3(other), bitmask, customizer, equalFunc, stack); + stack["delete"](object$3); + return result$2; + case symbolTag$1: if (symbolValueOf) return symbolValueOf.call(object$3) == symbolValueOf.call(other); + } + return false; + } + /** + * A specialized version of `baseIsEqualDeep` for objects with support for + * partial deep comparisons. + * + * @private + * @param {Object} object The object to compare. + * @param {Object} other The other object to compare. + * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details. + * @param {Function} customizer The function to customize comparisons. + * @param {Function} equalFunc The function to determine equivalents of values. + * @param {Object} stack Tracks traversed `object` and `other` objects. + * @returns {boolean} Returns `true` if the objects are equivalent, else `false`. + */ + function equalObjects(object$3, other, bitmask, customizer, equalFunc, stack) { + var isPartial = bitmask & COMPARE_PARTIAL_FLAG, objProps = getAllKeys(object$3), objLength = objProps.length, othProps = getAllKeys(other), othLength = othProps.length; + if (objLength != othLength && !isPartial) return false; + var index$1 = objLength; + while (index$1--) { + var key = objProps[index$1]; + if (!(isPartial ? key in other : hasOwnProperty$6.call(other, key))) return false; + } + var objStacked = stack.get(object$3); + var othStacked = stack.get(other); + if (objStacked && othStacked) return objStacked == other && othStacked == object$3; + var result$2 = true; + stack.set(object$3, other); + stack.set(other, object$3); + var skipCtor = isPartial; + while (++index$1 < objLength) { + key = objProps[index$1]; + var objValue = object$3[key], othValue = other[key]; + if (customizer) var compared = isPartial ? customizer(othValue, objValue, key, other, object$3, stack) : customizer(objValue, othValue, key, object$3, other, stack); + if (!(compared === undefined$1 ? objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack) : compared)) { + result$2 = false; + break; + } + skipCtor || (skipCtor = key == "constructor"); + } + if (result$2 && !skipCtor) { + var objCtor = object$3.constructor, othCtor = other.constructor; + if (objCtor != othCtor && "constructor" in object$3 && "constructor" in other && !(typeof objCtor == "function" && objCtor instanceof objCtor && typeof othCtor == "function" && othCtor instanceof othCtor)) result$2 = false; + } + stack["delete"](object$3); + stack["delete"](other); + return result$2; + } + /** + * A specialized version of `baseRest` which flattens the rest array. + * + * @private + * @param {Function} func The function to apply a rest parameter to. + * @returns {Function} Returns the new function. + */ + function flatRest(func) { + return setToString(overRest(func, undefined$1, flatten$2), func + ""); + } + /** + * Creates an array of own enumerable property names and symbols of `object`. + * + * @private + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property names and symbols. + */ + function getAllKeys(object$3) { + return baseGetAllKeys(object$3, keys$2, getSymbols); + } + /** + * Creates an array of own and inherited enumerable property names and + * symbols of `object`. + * + * @private + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property names and symbols. + */ + function getAllKeysIn(object$3) { + return baseGetAllKeys(object$3, keysIn, getSymbolsIn); + } + /** + * Gets metadata for `func`. + * + * @private + * @param {Function} func The function to query. + * @returns {*} Returns the metadata for `func`. + */ + var getData = !metaMap ? noop$4 : function(func) { + return metaMap.get(func); + }; + /** + * Gets the name of `func`. + * + * @private + * @param {Function} func The function to query. + * @returns {string} Returns the function name. + */ + function getFuncName(func) { + var result$2 = func.name + "", array = realNames[result$2], length = hasOwnProperty$6.call(realNames, result$2) ? array.length : 0; + while (length--) { + var data$2 = array[length], otherFunc = data$2.func; + if (otherFunc == null || otherFunc == func) return data$2.name; + } + return result$2; + } + /** + * Gets the argument placeholder value for `func`. + * + * @private + * @param {Function} func The function to inspect. + * @returns {*} Returns the placeholder value. + */ + function getHolder(func) { + var object$3 = hasOwnProperty$6.call(lodash, "placeholder") ? lodash : func; + return object$3.placeholder; + } + /** + * Gets the appropriate "iteratee" function. If `_.iteratee` is customized, + * this function returns the custom method, otherwise it returns `baseIteratee`. + * If arguments are provided, the chosen function is invoked with them and + * its result is returned. + * + * @private + * @param {*} [value] The value to convert to an iteratee. + * @param {number} [arity] The arity of the created iteratee. + * @returns {Function} Returns the chosen function or its result. + */ + function getIteratee() { + var result$2 = lodash.iteratee || iteratee$1; + result$2 = result$2 === iteratee$1 ? baseIteratee$1 : result$2; + return arguments.length ? result$2(arguments[0], arguments[1]) : result$2; + } + /** + * 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$2, key) { + var data$2 = map$2.__data__; + return isKeyable(key) ? data$2[typeof key == "string" ? "string" : "hash"] : data$2.map; + } + /** + * Gets the property names, values, and compare flags of `object`. + * + * @private + * @param {Object} object The object to query. + * @returns {Array} Returns the match data of `object`. + */ + function getMatchData(object$3) { + var result$2 = keys$2(object$3), length = result$2.length; + while (length--) { + var key = result$2[length], value = object$3[key]; + result$2[length] = [ + key, + value, + isStrictComparable(value) + ]; + } + return result$2; + } + /** + * 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$3, key) { + var value = getValue(object$3, key); + return baseIsNative(value) ? value : undefined$1; + } + /** + * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values. + * + * @private + * @param {*} value The value to query. + * @returns {string} Returns the raw `toStringTag`. + */ + function getRawTag(value) { + var isOwn = hasOwnProperty$6.call(value, symToStringTag), tag$3 = value[symToStringTag]; + try { + value[symToStringTag] = undefined$1; + var unmasked = true; + } catch (e) {} + var result$2 = nativeObjectToString.call(value); + if (unmasked) if (isOwn) value[symToStringTag] = tag$3; + else delete value[symToStringTag]; + return result$2; + } + /** + * Creates an array of the own enumerable symbols of `object`. + * + * @private + * @param {Object} object The object to query. + * @returns {Array} Returns the array of symbols. + */ + var getSymbols = !nativeGetSymbols ? stubArray : function(object$3) { + if (object$3 == null) return []; + object$3 = Object$1(object$3); + return arrayFilter(nativeGetSymbols(object$3), function(symbol) { + return propertyIsEnumerable.call(object$3, symbol); + }); + }; + /** + * Creates an array of the own and inherited enumerable symbols of `object`. + * + * @private + * @param {Object} object The object to query. + * @returns {Array} Returns the array of symbols. + */ + var getSymbolsIn = !nativeGetSymbols ? stubArray : function(object$3) { + var result$2 = []; + while (object$3) { + arrayPush(result$2, getSymbols(object$3)); + object$3 = getPrototype(object$3); + } + return result$2; + }; + /** + * Gets the `toStringTag` of `value`. + * + * @private + * @param {*} value The value to query. + * @returns {string} Returns the `toStringTag`. + */ + var getTag = baseGetTag; + if (DataView$1 && getTag(new DataView$1(new ArrayBuffer(1))) != dataViewTag || Map$1 && getTag(new Map$1()) != mapTag || Promise$2 && getTag(Promise$2.resolve()) != promiseTag || Set$1 && getTag(new Set$1()) != setTag || WeakMap$1 && getTag(new WeakMap$1()) != weakMapTag) getTag = function(value) { + var result$2 = baseGetTag(value), Ctor = result$2 == objectTag ? value.constructor : undefined$1, ctorString = Ctor ? toSource(Ctor) : ""; + if (ctorString) switch (ctorString) { + case dataViewCtorString: return dataViewTag; + case mapCtorString: return mapTag; + case promiseCtorString: return promiseTag; + case setCtorString: return setTag; + case weakMapCtorString: return weakMapTag; + } + return result$2; + }; + /** + * Gets the view, applying any `transforms` to the `start` and `end` positions. + * + * @private + * @param {number} start The start of the view. + * @param {number} end The end of the view. + * @param {Array} transforms The transformations to apply to the view. + * @returns {Object} Returns an object containing the `start` and `end` + * positions of the view. + */ + function getView(start, end, transforms) { + var index$1 = -1, length = transforms.length; + while (++index$1 < length) { + var data$2 = transforms[index$1], size$2 = data$2.size; + switch (data$2.type) { + case "drop": + start += size$2; + break; + case "dropRight": + end -= size$2; + break; + case "take": + end = nativeMin(end, start + size$2); + break; + case "takeRight": + start = nativeMax(start, end - size$2); + break; + } + } + return { + "start": start, + "end": end + }; + } + /** + * Extracts wrapper details from the `source` body comment. + * + * @private + * @param {string} source The source to inspect. + * @returns {Array} Returns the wrapper details. + */ + function getWrapDetails(source) { + var match = source.match(reWrapDetails); + return match ? match[1].split(reSplitDetails) : []; + } + /** + * Checks if `path` exists on `object`. + * + * @private + * @param {Object} object The object to query. + * @param {Array|string} path The path to check. + * @param {Function} hasFunc The function to check properties. + * @returns {boolean} Returns `true` if `path` exists, else `false`. + */ + function hasPath(object$3, path$28, hasFunc) { + path$28 = castPath(path$28, object$3); + var index$1 = -1, length = path$28.length, result$2 = false; + while (++index$1 < length) { + var key = toKey(path$28[index$1]); + if (!(result$2 = object$3 != null && hasFunc(object$3, key))) break; + object$3 = object$3[key]; + } + if (result$2 || ++index$1 != length) return result$2; + length = object$3 == null ? 0 : object$3.length; + return !!length && isLength(length) && isIndex(key, length) && (isArray$5(object$3) || isArguments$1(object$3)); + } + /** + * Initializes an array clone. + * + * @private + * @param {Array} array The array to clone. + * @returns {Array} Returns the initialized clone. + */ + function initCloneArray(array) { + var length = array.length, result$2 = new array.constructor(length); + if (length && typeof array[0] == "string" && hasOwnProperty$6.call(array, "index")) { + result$2.index = array.index; + result$2.input = array.input; + } + return result$2; + } + /** + * Initializes an object clone. + * + * @private + * @param {Object} object The object to clone. + * @returns {Object} Returns the initialized clone. + */ + function initCloneObject(object$3) { + return typeof object$3.constructor == "function" && !isPrototype(object$3) ? baseCreate$1(getPrototype(object$3)) : {}; + } + /** + * Initializes an object clone based on its `toStringTag`. + * + * **Note:** This function only supports cloning values with tags of + * `Boolean`, `Date`, `Error`, `Map`, `Number`, `RegExp`, `Set`, or `String`. + * + * @private + * @param {Object} object The object to clone. + * @param {string} tag The `toStringTag` of the object to clone. + * @param {boolean} [isDeep] Specify a deep clone. + * @returns {Object} Returns the initialized clone. + */ + function initCloneByTag(object$3, tag$3, isDeep) { + var Ctor = object$3.constructor; + switch (tag$3) { + case arrayBufferTag: return cloneArrayBuffer(object$3); + case boolTag: + case dateTag: return new Ctor(+object$3); + case dataViewTag: return cloneDataView(object$3, isDeep); + case float32Tag: + case float64Tag: + case int8Tag: + case int16Tag: + case int32Tag: + case uint8Tag: + case uint8ClampedTag: + case uint16Tag: + case uint32Tag: return cloneTypedArray(object$3, isDeep); + case mapTag: return new Ctor(); + case numberTag: + case stringTag: return new Ctor(object$3); + case regexpTag: return cloneRegExp(object$3); + case setTag: return new Ctor(); + case symbolTag$1: return cloneSymbol(object$3); + } + } + /** + * Inserts wrapper `details` in a comment at the top of the `source` body. + * + * @private + * @param {string} source The source to modify. + * @returns {Array} details The details to insert. + * @returns {string} Returns the modified source. + */ + function insertWrapDetails(source, details) { + var length = details.length; + if (!length) return source; + var lastIndex = length - 1; + details[lastIndex] = (length > 1 ? "& " : "") + details[lastIndex]; + details = details.join(length > 2 ? ", " : " "); + return source.replace(reWrapComment, "{\n/* [wrapped with " + details + "] */\n"); + } + /** + * 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$5(value) || isArguments$1(value) || !!(spreadableSymbol && value && value[spreadableSymbol]); + } + /** + * 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; + return !!length && (type == "number" || type != "symbol" && reIsUint.test(value)) && value > -1 && value % 1 == 0 && value < length; + } + /** + * 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$1, object$3) { + if (!isObject$5(object$3)) return false; + var type = typeof index$1; + if (type == "number" ? isArrayLike(object$3) && isIndex(index$1, object$3.length) : type == "string" && index$1 in object$3) return eq$1(object$3[index$1], value); + return false; + } + /** + * Checks if `value` is a property name and not a property path. + * + * @private + * @param {*} value The value to check. + * @param {Object} [object] The object to query keys on. + * @returns {boolean} Returns `true` if `value` is a property name, else `false`. + */ + function isKey(value, object$3) { + if (isArray$5(value)) return false; + var type = typeof value; + if (type == "number" || type == "symbol" || type == "boolean" || value == null || isSymbol$2(value)) return true; + return reIsPlainProp.test(value) || !reIsDeepProp.test(value) || object$3 != null && value in Object$1(object$3); + } + /** + * 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; + } + /** + * Checks if `func` has a lazy counterpart. + * + * @private + * @param {Function} func The function to check. + * @returns {boolean} Returns `true` if `func` has a lazy counterpart, + * else `false`. + */ + function isLaziable(func) { + var funcName = getFuncName(func), other = lodash[funcName]; + if (typeof other != "function" || !(funcName in LazyWrapper.prototype)) return false; + if (func === other) return true; + var data$2 = getData(other); + return !!data$2 && func === data$2[0]; + } + /** + * 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; + } + /** + * Checks if `func` is capable of being masked. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `func` is maskable, else `false`. + */ + var isMaskable = coreJsData ? isFunction$10 : stubFalse; + /** + * 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$1; + return value === proto; + } + /** + * Checks if `value` is suitable for strict equality comparisons, i.e. `===`. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` if suitable for strict + * equality comparisons, else `false`. + */ + function isStrictComparable(value) { + return value === value && !isObject$5(value); + } + /** + * A specialized version of `matchesProperty` for source values suitable + * for strict equality comparisons, i.e. `===`. + * + * @private + * @param {string} key The key of the property to get. + * @param {*} srcValue The value to match. + * @returns {Function} Returns the new spec function. + */ + function matchesStrictComparable(key, srcValue) { + return function(object$3) { + if (object$3 == null) return false; + return object$3[key] === srcValue && (srcValue !== undefined$1 || key in Object$1(object$3)); + }; + } + /** + * A specialized version of `_.memoize` which clears the memoized function's + * cache when it exceeds `MAX_MEMOIZE_SIZE`. + * + * @private + * @param {Function} func The function to have its output memoized. + * @returns {Function} Returns the new memoized function. + */ + function memoizeCapped(func) { + var result$2 = memoize$1(func, function(key) { + if (cache$3.size === MAX_MEMOIZE_SIZE) cache$3.clear(); + return key; + }); + var cache$3 = result$2.cache; + return result$2; + } + /** + * Merges the function metadata of `source` into `data`. + * + * Merging metadata reduces the number of wrappers used to invoke a function. + * This is possible because methods like `_.bind`, `_.curry`, and `_.partial` + * may be applied regardless of execution order. Methods like `_.ary` and + * `_.rearg` modify function arguments, making the order in which they are + * executed important, preventing the merging of metadata. However, we make + * an exception for a safe combined case where curried functions have `_.ary` + * and or `_.rearg` applied. + * + * @private + * @param {Array} data The destination metadata. + * @param {Array} source The source metadata. + * @returns {Array} Returns `data`. + */ + function mergeData(data$2, source) { + var bitmask = data$2[1], srcBitmask = source[1], newBitmask = bitmask | srcBitmask, isCommon = newBitmask < (WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG | WRAP_ARY_FLAG); + var isCombo = srcBitmask == WRAP_ARY_FLAG && bitmask == WRAP_CURRY_FLAG || srcBitmask == WRAP_ARY_FLAG && bitmask == WRAP_REARG_FLAG && data$2[7].length <= source[8] || srcBitmask == (WRAP_ARY_FLAG | WRAP_REARG_FLAG) && source[7].length <= source[8] && bitmask == WRAP_CURRY_FLAG; + if (!(isCommon || isCombo)) return data$2; + if (srcBitmask & WRAP_BIND_FLAG) { + data$2[2] = source[2]; + newBitmask |= bitmask & WRAP_BIND_FLAG ? 0 : WRAP_CURRY_BOUND_FLAG; + } + var value = source[3]; + if (value) { + var partials = data$2[3]; + data$2[3] = partials ? composeArgs(partials, value, source[4]) : value; + data$2[4] = partials ? replaceHolders(data$2[3], PLACEHOLDER) : source[4]; + } + value = source[5]; + if (value) { + partials = data$2[5]; + data$2[5] = partials ? composeArgsRight(partials, value, source[6]) : value; + data$2[6] = partials ? replaceHolders(data$2[5], PLACEHOLDER) : source[6]; + } + value = source[7]; + if (value) data$2[7] = value; + if (srcBitmask & WRAP_ARY_FLAG) data$2[8] = data$2[8] == null ? source[8] : nativeMin(data$2[8], source[8]); + if (data$2[9] == null) data$2[9] = source[9]; + data$2[0] = source[0]; + data$2[1] = newBitmask; + return data$2; + } + /** + * 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$3) { + var result$2 = []; + if (object$3 != null) for (var key in Object$1(object$3)) result$2.push(key); + return result$2; + } + /** + * Converts `value` to a string using `Object.prototype.toString`. + * + * @private + * @param {*} value The value to convert. + * @returns {string} Returns the converted string. + */ + function objectToString$3(value) { + return nativeObjectToString.call(value); + } + /** + * 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$2) { + start = nativeMax(start === undefined$1 ? func.length - 1 : start, 0); + return function() { + var args = arguments, index$1 = -1, length = nativeMax(args.length - start, 0), array = Array$1(length); + while (++index$1 < length) array[index$1] = args[start + index$1]; + index$1 = -1; + var otherArgs = Array$1(start + 1); + while (++index$1 < start) otherArgs[index$1] = args[index$1]; + otherArgs[start] = transform$2(array); + return apply(func, this, otherArgs); + }; + } + /** + * Gets the parent value at `path` of `object`. + * + * @private + * @param {Object} object The object to query. + * @param {Array} path The path to get the parent value of. + * @returns {*} Returns the parent value. + */ + function parent(object$3, path$28) { + return path$28.length < 2 ? object$3 : baseGet(object$3, baseSlice$1(path$28, 0, -1)); + } + /** + * Reorder `array` according to the specified indexes where the element at + * the first index is assigned as the first element, the element at + * the second index is assigned as the second element, and so on. + * + * @private + * @param {Array} array The array to reorder. + * @param {Array} indexes The arranged array indexes. + * @returns {Array} Returns `array`. + */ + function reorder(array, indexes) { + var arrLength = array.length, length = nativeMin(indexes.length, arrLength), oldArray = copyArray(array); + while (length--) { + var index$1 = indexes[length]; + array[length] = isIndex(index$1, arrLength) ? oldArray[index$1] : undefined$1; + } + return array; + } + /** + * Gets the value at `key`, unless `key` is "__proto__" or "constructor". + * + * @private + * @param {Object} object The object to query. + * @param {string} key The key of the property to get. + * @returns {*} Returns the property value. + */ + function safeGet(object$3, key) { + if (key === "constructor" && typeof object$3[key] === "function") return; + if (key == "__proto__") return; + return object$3[key]; + } + /** + * Sets metadata for `func`. + * + * **Note:** If this function becomes hot, i.e. is invoked a lot in a short + * period of time, it will trip its breaker and transition to an identity + * function to avoid garbage collection pauses in V8. See + * [V8 issue 2070](https://bugs.chromium.org/p/v8/issues/detail?id=2070) + * for more details. + * + * @private + * @param {Function} func The function to associate metadata with. + * @param {*} data The metadata. + * @returns {Function} Returns `func`. + */ + var setData = shortOut(baseSetData); + /** + * A simple wrapper around the global [`setTimeout`](https://mdn.io/setTimeout). + * + * @private + * @param {Function} func The function to delay. + * @param {number} wait The number of milliseconds to delay invocation. + * @returns {number|Object} Returns the timer id or timeout object. + */ + var setTimeout$1 = ctxSetTimeout || function(func, wait) { + return root$6.setTimeout(func, wait); + }; + /** + * 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); + /** + * Sets the `toString` method of `wrapper` to mimic the source of `reference` + * with wrapper details in a comment at the top of the source body. + * + * @private + * @param {Function} wrapper The function to modify. + * @param {Function} reference The reference function. + * @param {number} bitmask The bitmask flags. See `createWrap` for more details. + * @returns {Function} Returns `wrapper`. + */ + function setWrapToString(wrapper, reference, bitmask) { + var source = reference + ""; + return setToString(wrapper, insertWrapDetails(source, updateWrapDetails(getWrapDetails(source), bitmask))); + } + /** + * 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; + 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$1, arguments); + }; + } + /** + * A specialized version of `_.shuffle` which mutates and sets the size of `array`. + * + * @private + * @param {Array} array The array to shuffle. + * @param {number} [size=array.length] The size of `array`. + * @returns {Array} Returns `array`. + */ + function shuffleSelf(array, size$2) { + var index$1 = -1, length = array.length, lastIndex = length - 1; + size$2 = size$2 === undefined$1 ? length : size$2; + while (++index$1 < size$2) { + var rand = baseRandom(index$1, lastIndex), value = array[rand]; + array[rand] = array[index$1]; + array[index$1] = value; + } + array.length = size$2; + return array; + } + /** + * Converts `string` to a property path array. + * + * @private + * @param {string} string The string to convert. + * @returns {Array} Returns the property path array. + */ + var stringToPath = memoizeCapped(function(string$3) { + var result$2 = []; + if (string$3.charCodeAt(0) === 46) result$2.push(""); + string$3.replace(rePropName, function(match, number, quote, subString) { + result$2.push(quote ? subString.replace(reEscapeChar, "$1") : number || match); + }); + return result$2; + }); + /** + * Converts `value` to a string key if it's not a string or symbol. + * + * @private + * @param {*} value The value to inspect. + * @returns {string|symbol} Returns the key. + */ + function toKey(value) { + if (typeof value == "string" || isSymbol$2(value)) return value; + var result$2 = value + ""; + return result$2 == "0" && 1 / value == -INFINITY$1 ? "-0" : result$2; + } + /** + * 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) {} + } + return ""; + } + /** + * Updates wrapper `details` based on `bitmask` flags. + * + * @private + * @returns {Array} details The details to modify. + * @param {number} bitmask The bitmask flags. See `createWrap` for more details. + * @returns {Array} Returns `details`. + */ + function updateWrapDetails(details, bitmask) { + arrayEach(wrapFlags, function(pair) { + var value = "_." + pair[0]; + if (bitmask & pair[1] && !arrayIncludes(details, value)) details.push(value); + }); + return details.sort(); + } + /** + * Creates a clone of `wrapper`. + * + * @private + * @param {Object} wrapper The wrapper to clone. + * @returns {Object} Returns the cloned wrapper. + */ + function wrapperClone(wrapper) { + if (wrapper instanceof LazyWrapper) return wrapper.clone(); + var result$2 = new LodashWrapper(wrapper.__wrapped__, wrapper.__chain__); + result$2.__actions__ = copyArray(wrapper.__actions__); + result$2.__index__ = wrapper.__index__; + result$2.__values__ = wrapper.__values__; + return result$2; + } + /** + * Creates an array of elements split into groups the length of `size`. + * If `array` can't be split evenly, the final chunk will be the remaining + * elements. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Array + * @param {Array} array The array to process. + * @param {number} [size=1] The length of each chunk + * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`. + * @returns {Array} Returns the new array of chunks. + * @example + * + * _.chunk(['a', 'b', 'c', 'd'], 2); + * // => [['a', 'b'], ['c', 'd']] + * + * _.chunk(['a', 'b', 'c', 'd'], 3); + * // => [['a', 'b', 'c'], ['d']] + */ + function chunk$1(array, size$2, guard) { + if (guard ? isIterateeCall(array, size$2, guard) : size$2 === undefined$1) size$2 = 1; + else size$2 = nativeMax(toInteger(size$2), 0); + var length = array == null ? 0 : array.length; + if (!length || size$2 < 1) return []; + var index$1 = 0, resIndex = 0, result$2 = Array$1(nativeCeil(length / size$2)); + while (index$1 < length) result$2[resIndex++] = baseSlice$1(array, index$1, index$1 += size$2); + return result$2; + } + /** + * Creates an array with all falsey values removed. The values `false`, `null`, + * `0`, `""`, `undefined`, and `NaN` are falsey. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Array + * @param {Array} array The array to compact. + * @returns {Array} Returns the new array of filtered values. + * @example + * + * _.compact([0, 1, false, 2, '', 3]); + * // => [1, 2, 3] + */ + function compact$1(array) { + var index$1 = -1, length = array == null ? 0 : array.length, resIndex = 0, result$2 = []; + while (++index$1 < length) { + var value = array[index$1]; + if (value) result$2[resIndex++] = value; + } + return result$2; + } + /** + * Creates a new array concatenating `array` with any additional arrays + * and/or values. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {Array} array The array to concatenate. + * @param {...*} [values] The values to concatenate. + * @returns {Array} Returns the new concatenated array. + * @example + * + * var array = [1]; + * var other = _.concat(array, 2, [3], [[4]]); + * + * console.log(other); + * // => [1, 2, 3, [4]] + * + * console.log(array); + * // => [1] + */ + function concat() { + var length = arguments.length; + if (!length) return []; + var args = Array$1(length - 1), array = arguments[0], index$1 = length; + while (index$1--) args[index$1 - 1] = arguments[index$1]; + return arrayPush(isArray$5(array) ? copyArray(array) : [array], baseFlatten(args, 1)); + } + /** + * 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$2) { + return isArrayLikeObject(array) ? baseDifference(array, baseFlatten(values$2, 1, isArrayLikeObject, true)) : []; + }); + /** + * This method is like `_.difference` except that it accepts `iteratee` which + * is invoked for each element of `array` and `values` to generate the criterion + * by which they're compared. The order and references of result values are + * determined by the first array. The iteratee is invoked with one argument: + * (value). + * + * **Note:** Unlike `_.pullAllBy`, this method returns a new array. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {Array} array The array to inspect. + * @param {...Array} [values] The values to exclude. + * @param {Function} [iteratee=_.identity] The iteratee invoked per element. + * @returns {Array} Returns the new array of filtered values. + * @example + * + * _.differenceBy([2.1, 1.2], [2.3, 3.4], Math.floor); + * // => [1.2] + * + * // The `_.property` iteratee shorthand. + * _.differenceBy([{ 'x': 2 }, { 'x': 1 }], [{ 'x': 1 }], 'x'); + * // => [{ 'x': 2 }] + */ + var differenceBy = baseRest(function(array, values$2) { + var iteratee$2 = last$3(values$2); + if (isArrayLikeObject(iteratee$2)) iteratee$2 = undefined$1; + return isArrayLikeObject(array) ? baseDifference(array, baseFlatten(values$2, 1, isArrayLikeObject, true), getIteratee(iteratee$2, 2)) : []; + }); + /** + * This method is like `_.difference` except that it accepts `comparator` + * which is invoked to compare elements of `array` to `values`. The order and + * references of result values are determined by the first array. The comparator + * is invoked with two arguments: (arrVal, othVal). + * + * **Note:** Unlike `_.pullAllWith`, this method returns a new array. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {Array} array The array to inspect. + * @param {...Array} [values] The values to exclude. + * @param {Function} [comparator] The comparator invoked per element. + * @returns {Array} Returns the new array of filtered values. + * @example + * + * var objects = [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }]; + * + * _.differenceWith(objects, [{ 'x': 1, 'y': 2 }], _.isEqual); + * // => [{ 'x': 2, 'y': 1 }] + */ + var differenceWith = baseRest(function(array, values$2) { + var comparator = last$3(values$2); + if (isArrayLikeObject(comparator)) comparator = undefined$1; + return isArrayLikeObject(array) ? baseDifference(array, baseFlatten(values$2, 1, isArrayLikeObject, true), undefined$1, comparator) : []; + }); + /** + * Creates a slice of `array` with `n` elements dropped from the beginning. + * + * @static + * @memberOf _ + * @since 0.5.0 + * @category Array + * @param {Array} array The array to query. + * @param {number} [n=1] The number of elements to drop. + * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`. + * @returns {Array} Returns the slice of `array`. + * @example + * + * _.drop([1, 2, 3]); + * // => [2, 3] + * + * _.drop([1, 2, 3], 2); + * // => [3] + * + * _.drop([1, 2, 3], 5); + * // => [] + * + * _.drop([1, 2, 3], 0); + * // => [1, 2, 3] + */ + function drop(array, n$3, guard) { + var length = array == null ? 0 : array.length; + if (!length) return []; + n$3 = guard || n$3 === undefined$1 ? 1 : toInteger(n$3); + return baseSlice$1(array, n$3 < 0 ? 0 : n$3, length); + } + /** + * Creates a slice of `array` with `n` elements dropped from the end. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Array + * @param {Array} array The array to query. + * @param {number} [n=1] The number of elements to drop. + * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`. + * @returns {Array} Returns the slice of `array`. + * @example + * + * _.dropRight([1, 2, 3]); + * // => [1, 2] + * + * _.dropRight([1, 2, 3], 2); + * // => [1] + * + * _.dropRight([1, 2, 3], 5); + * // => [] + * + * _.dropRight([1, 2, 3], 0); + * // => [1, 2, 3] + */ + function dropRight(array, n$3, guard) { + var length = array == null ? 0 : array.length; + if (!length) return []; + n$3 = guard || n$3 === undefined$1 ? 1 : toInteger(n$3); + n$3 = length - n$3; + return baseSlice$1(array, 0, n$3 < 0 ? 0 : n$3); + } + /** + * Creates a slice of `array` excluding elements dropped from the end. + * Elements are dropped until `predicate` returns falsey. The predicate is + * invoked with three arguments: (value, index, array). + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Array + * @param {Array} array The array to query. + * @param {Function} [predicate=_.identity] The function invoked per iteration. + * @returns {Array} Returns the slice of `array`. + * @example + * + * var users = [ + * { 'user': 'barney', 'active': true }, + * { 'user': 'fred', 'active': false }, + * { 'user': 'pebbles', 'active': false } + * ]; + * + * _.dropRightWhile(users, function(o) { return !o.active; }); + * // => objects for ['barney'] + * + * // The `_.matches` iteratee shorthand. + * _.dropRightWhile(users, { 'user': 'pebbles', 'active': false }); + * // => objects for ['barney', 'fred'] + * + * // The `_.matchesProperty` iteratee shorthand. + * _.dropRightWhile(users, ['active', false]); + * // => objects for ['barney'] + * + * // The `_.property` iteratee shorthand. + * _.dropRightWhile(users, 'active'); + * // => objects for ['barney', 'fred', 'pebbles'] + */ + function dropRightWhile(array, predicate) { + return array && array.length ? baseWhile(array, getIteratee(predicate, 3), true, true) : []; + } + /** + * Creates a slice of `array` excluding elements dropped from the beginning. + * Elements are dropped until `predicate` returns falsey. The predicate is + * invoked with three arguments: (value, index, array). + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Array + * @param {Array} array The array to query. + * @param {Function} [predicate=_.identity] The function invoked per iteration. + * @returns {Array} Returns the slice of `array`. + * @example + * + * var users = [ + * { 'user': 'barney', 'active': false }, + * { 'user': 'fred', 'active': false }, + * { 'user': 'pebbles', 'active': true } + * ]; + * + * _.dropWhile(users, function(o) { return !o.active; }); + * // => objects for ['pebbles'] + * + * // The `_.matches` iteratee shorthand. + * _.dropWhile(users, { 'user': 'barney', 'active': false }); + * // => objects for ['fred', 'pebbles'] + * + * // The `_.matchesProperty` iteratee shorthand. + * _.dropWhile(users, ['active', false]); + * // => objects for ['pebbles'] + * + * // The `_.property` iteratee shorthand. + * _.dropWhile(users, 'active'); + * // => objects for ['barney', 'fred', 'pebbles'] + */ + function dropWhile(array, predicate) { + return array && array.length ? baseWhile(array, getIteratee(predicate, 3), true) : []; + } + /** + * Fills elements of `array` with `value` from `start` up to, but not + * including, `end`. + * + * **Note:** This method mutates `array`. + * + * @static + * @memberOf _ + * @since 3.2.0 + * @category Array + * @param {Array} array The array to fill. + * @param {*} value The value to fill `array` with. + * @param {number} [start=0] The start position. + * @param {number} [end=array.length] The end position. + * @returns {Array} Returns `array`. + * @example + * + * var array = [1, 2, 3]; + * + * _.fill(array, 'a'); + * console.log(array); + * // => ['a', 'a', 'a'] + * + * _.fill(Array(3), 2); + * // => [2, 2, 2] + * + * _.fill([4, 6, 8, 10], '*', 1, 3); + * // => [4, '*', '*', 10] + */ + function fill(array, value, start, end) { + var length = array == null ? 0 : array.length; + if (!length) return []; + if (start && typeof start != "number" && isIterateeCall(array, value, start)) { + start = 0; + end = length; + } + return baseFill(array, value, start, end); + } + /** + * This method is like `_.find` except that it returns the index of the first + * element `predicate` returns truthy for instead of the element itself. + * + * @static + * @memberOf _ + * @since 1.1.0 + * @category Array + * @param {Array} array The array to inspect. + * @param {Function} [predicate=_.identity] The function invoked per iteration. + * @param {number} [fromIndex=0] The index to search from. + * @returns {number} Returns the index of the found element, else `-1`. + * @example + * + * var users = [ + * { 'user': 'barney', 'active': false }, + * { 'user': 'fred', 'active': false }, + * { 'user': 'pebbles', 'active': true } + * ]; + * + * _.findIndex(users, function(o) { return o.user == 'barney'; }); + * // => 0 + * + * // The `_.matches` iteratee shorthand. + * _.findIndex(users, { 'user': 'fred', 'active': false }); + * // => 1 + * + * // The `_.matchesProperty` iteratee shorthand. + * _.findIndex(users, ['active', false]); + * // => 0 + * + * // The `_.property` iteratee shorthand. + * _.findIndex(users, 'active'); + * // => 2 + */ + function findIndex(array, predicate, fromIndex) { + var length = array == null ? 0 : array.length; + if (!length) return -1; + var index$1 = fromIndex == null ? 0 : toInteger(fromIndex); + if (index$1 < 0) index$1 = nativeMax(length + index$1, 0); + return baseFindIndex(array, getIteratee(predicate, 3), index$1); + } + /** + * This method is like `_.findIndex` except that it iterates over elements + * of `collection` from right to left. + * + * @static + * @memberOf _ + * @since 2.0.0 + * @category Array + * @param {Array} array The array to inspect. + * @param {Function} [predicate=_.identity] The function invoked per iteration. + * @param {number} [fromIndex=array.length-1] The index to search from. + * @returns {number} Returns the index of the found element, else `-1`. + * @example + * + * var users = [ + * { 'user': 'barney', 'active': true }, + * { 'user': 'fred', 'active': false }, + * { 'user': 'pebbles', 'active': false } + * ]; + * + * _.findLastIndex(users, function(o) { return o.user == 'pebbles'; }); + * // => 2 + * + * // The `_.matches` iteratee shorthand. + * _.findLastIndex(users, { 'user': 'barney', 'active': true }); + * // => 0 + * + * // The `_.matchesProperty` iteratee shorthand. + * _.findLastIndex(users, ['active', false]); + * // => 2 + * + * // The `_.property` iteratee shorthand. + * _.findLastIndex(users, 'active'); + * // => 0 + */ + function findLastIndex(array, predicate, fromIndex) { + var length = array == null ? 0 : array.length; + if (!length) return -1; + var index$1 = length - 1; + if (fromIndex !== undefined$1) { + index$1 = toInteger(fromIndex); + index$1 = fromIndex < 0 ? nativeMax(length + index$1, 0) : nativeMin(index$1, length - 1); + } + return baseFindIndex(array, getIteratee(predicate, 3), index$1, true); + } + /** + * 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$2(array) { + var length = array == null ? 0 : array.length; + return length ? baseFlatten(array, 1) : []; + } + /** + * Recursively flattens `array`. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Array + * @param {Array} array The array to flatten. + * @returns {Array} Returns the new flattened array. + * @example + * + * _.flattenDeep([1, [2, [3, [4]], 5]]); + * // => [1, 2, 3, 4, 5] + */ + function flattenDeep(array) { + var length = array == null ? 0 : array.length; + return length ? baseFlatten(array, INFINITY$1) : []; + } + /** + * Recursively flatten `array` up to `depth` times. + * + * @static + * @memberOf _ + * @since 4.4.0 + * @category Array + * @param {Array} array The array to flatten. + * @param {number} [depth=1] The maximum recursion depth. + * @returns {Array} Returns the new flattened array. + * @example + * + * var array = [1, [2, [3, [4]], 5]]; + * + * _.flattenDepth(array, 1); + * // => [1, 2, [3, [4]], 5] + * + * _.flattenDepth(array, 2); + * // => [1, 2, 3, [4], 5] + */ + function flattenDepth(array, depth$1) { + var length = array == null ? 0 : array.length; + if (!length) return []; + depth$1 = depth$1 === undefined$1 ? 1 : toInteger(depth$1); + return baseFlatten(array, depth$1); + } + /** + * The inverse of `_.toPairs`; this method returns an object composed + * from key-value `pairs`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {Array} pairs The key-value pairs. + * @returns {Object} Returns the new object. + * @example + * + * _.fromPairs([['a', 1], ['b', 2]]); + * // => { 'a': 1, 'b': 2 } + */ + function fromPairs(pairs$1) { + var index$1 = -1, length = pairs$1 == null ? 0 : pairs$1.length, result$2 = {}; + while (++index$1 < length) { + var pair = pairs$1[index$1]; + result$2[pair[0]] = pair[1]; + } + return result$2; + } + /** + * Gets the first element of `array`. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @alias first + * @category Array + * @param {Array} array The array to query. + * @returns {*} Returns the first element of `array`. + * @example + * + * _.head([1, 2, 3]); + * // => 1 + * + * _.head([]); + * // => undefined + */ + function head(array) { + return array && array.length ? array[0] : undefined$1; + } + /** + * Gets the index at which the first occurrence of `value` is found in `array` + * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) + * for equality comparisons. If `fromIndex` is negative, it's used as the + * offset from the end of `array`. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Array + * @param {Array} array The array to inspect. + * @param {*} value The value to search for. + * @param {number} [fromIndex=0] The index to search from. + * @returns {number} Returns the index of the matched value, else `-1`. + * @example + * + * _.indexOf([1, 2, 1, 2], 2); + * // => 1 + * + * // Search from the `fromIndex`. + * _.indexOf([1, 2, 1, 2], 2, 2); + * // => 3 + */ + function indexOf$1(array, value, fromIndex) { + var length = array == null ? 0 : array.length; + if (!length) return -1; + var index$1 = fromIndex == null ? 0 : toInteger(fromIndex); + if (index$1 < 0) index$1 = nativeMax(length + index$1, 0); + return baseIndexOf(array, value, index$1); + } + /** + * Gets all but the last element of `array`. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Array + * @param {Array} array The array to query. + * @returns {Array} Returns the slice of `array`. + * @example + * + * _.initial([1, 2, 3]); + * // => [1, 2] + */ + function initial$1(array) { + var length = array == null ? 0 : array.length; + return length ? baseSlice$1(array, 0, -1) : []; + } + /** + * Creates an array of unique values that are included in all 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. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Array + * @param {...Array} [arrays] The arrays to inspect. + * @returns {Array} Returns the new array of intersecting values. + * @example + * + * _.intersection([2, 1], [2, 3]); + * // => [2] + */ + var intersection$1 = baseRest(function(arrays) { + var mapped = arrayMap(arrays, castArrayLikeObject); + return mapped.length && mapped[0] === arrays[0] ? baseIntersection(mapped) : []; + }); + /** + * This method is like `_.intersection` except that it accepts `iteratee` + * which is invoked for each element of each `arrays` to generate the criterion + * by which they're compared. The order and references of result values are + * determined by the first array. The iteratee is invoked with one argument: + * (value). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {...Array} [arrays] The arrays to inspect. + * @param {Function} [iteratee=_.identity] The iteratee invoked per element. + * @returns {Array} Returns the new array of intersecting values. + * @example + * + * _.intersectionBy([2.1, 1.2], [2.3, 3.4], Math.floor); + * // => [2.1] + * + * // The `_.property` iteratee shorthand. + * _.intersectionBy([{ 'x': 1 }], [{ 'x': 2 }, { 'x': 1 }], 'x'); + * // => [{ 'x': 1 }] + */ + var intersectionBy = baseRest(function(arrays) { + var iteratee$2 = last$3(arrays), mapped = arrayMap(arrays, castArrayLikeObject); + if (iteratee$2 === last$3(mapped)) iteratee$2 = undefined$1; + else mapped.pop(); + return mapped.length && mapped[0] === arrays[0] ? baseIntersection(mapped, getIteratee(iteratee$2, 2)) : []; + }); + /** + * This method is like `_.intersection` except that it accepts `comparator` + * which is invoked to compare elements of `arrays`. The order and references + * of result values are determined by the first array. The comparator is + * invoked with two arguments: (arrVal, othVal). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {...Array} [arrays] The arrays to inspect. + * @param {Function} [comparator] The comparator invoked per element. + * @returns {Array} Returns the new array of intersecting values. + * @example + * + * var objects = [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }]; + * var others = [{ 'x': 1, 'y': 1 }, { 'x': 1, 'y': 2 }]; + * + * _.intersectionWith(objects, others, _.isEqual); + * // => [{ 'x': 1, 'y': 2 }] + */ + var intersectionWith = baseRest(function(arrays) { + var comparator = last$3(arrays), mapped = arrayMap(arrays, castArrayLikeObject); + comparator = typeof comparator == "function" ? comparator : undefined$1; + if (comparator) mapped.pop(); + return mapped.length && mapped[0] === arrays[0] ? baseIntersection(mapped, undefined$1, comparator) : []; + }); + /** + * Converts all elements in `array` into a string separated by `separator`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {Array} array The array to convert. + * @param {string} [separator=','] The element separator. + * @returns {string} Returns the joined string. + * @example + * + * _.join(['a', 'b', 'c'], '~'); + * // => 'a~b~c' + */ + function join$3(array, separator) { + return array == null ? "" : nativeJoin.call(array, separator); + } + /** + * Gets the last element of `array`. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Array + * @param {Array} array The array to query. + * @returns {*} Returns the last element of `array`. + * @example + * + * _.last([1, 2, 3]); + * // => 3 + */ + function last$3(array) { + var length = array == null ? 0 : array.length; + return length ? array[length - 1] : undefined$1; + } + /** + * This method is like `_.indexOf` except that it iterates over elements of + * `array` from right to left. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Array + * @param {Array} array The array to inspect. + * @param {*} value The value to search for. + * @param {number} [fromIndex=array.length-1] The index to search from. + * @returns {number} Returns the index of the matched value, else `-1`. + * @example + * + * _.lastIndexOf([1, 2, 1, 2], 2); + * // => 3 + * + * // Search from the `fromIndex`. + * _.lastIndexOf([1, 2, 1, 2], 2, 2); + * // => 1 + */ + function lastIndexOf(array, value, fromIndex) { + var length = array == null ? 0 : array.length; + if (!length) return -1; + var index$1 = length; + if (fromIndex !== undefined$1) { + index$1 = toInteger(fromIndex); + index$1 = index$1 < 0 ? nativeMax(length + index$1, 0) : nativeMin(index$1, length - 1); + } + return value === value ? strictLastIndexOf(array, value, index$1) : baseFindIndex(array, baseIsNaN, index$1, true); + } + /** + * Gets the element at index `n` of `array`. If `n` is negative, the nth + * element from the end is returned. + * + * @static + * @memberOf _ + * @since 4.11.0 + * @category Array + * @param {Array} array The array to query. + * @param {number} [n=0] The index of the element to return. + * @returns {*} Returns the nth element of `array`. + * @example + * + * var array = ['a', 'b', 'c', 'd']; + * + * _.nth(array, 1); + * // => 'b' + * + * _.nth(array, -2); + * // => 'c'; + */ + function nth(array, n$3) { + return array && array.length ? baseNth(array, toInteger(n$3)) : undefined$1; + } + /** + * Removes all given values from `array` using + * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) + * for equality comparisons. + * + * **Note:** Unlike `_.without`, this method mutates `array`. Use `_.remove` + * to remove elements from an array by predicate. + * + * @static + * @memberOf _ + * @since 2.0.0 + * @category Array + * @param {Array} array The array to modify. + * @param {...*} [values] The values to remove. + * @returns {Array} Returns `array`. + * @example + * + * var array = ['a', 'b', 'c', 'a', 'b', 'c']; + * + * _.pull(array, 'a', 'c'); + * console.log(array); + * // => ['b', 'b'] + */ + var pull = baseRest(pullAll); + /** + * This method is like `_.pull` except that it accepts an array of values to remove. + * + * **Note:** Unlike `_.difference`, this method mutates `array`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {Array} array The array to modify. + * @param {Array} values The values to remove. + * @returns {Array} Returns `array`. + * @example + * + * var array = ['a', 'b', 'c', 'a', 'b', 'c']; + * + * _.pullAll(array, ['a', 'c']); + * console.log(array); + * // => ['b', 'b'] + */ + function pullAll(array, values$2) { + return array && array.length && values$2 && values$2.length ? basePullAll(array, values$2) : array; + } + /** + * This method is like `_.pullAll` except that it accepts `iteratee` which is + * invoked for each element of `array` and `values` to generate the criterion + * by which they're compared. The iteratee is invoked with one argument: (value). + * + * **Note:** Unlike `_.differenceBy`, this method mutates `array`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {Array} array The array to modify. + * @param {Array} values The values to remove. + * @param {Function} [iteratee=_.identity] The iteratee invoked per element. + * @returns {Array} Returns `array`. + * @example + * + * var array = [{ 'x': 1 }, { 'x': 2 }, { 'x': 3 }, { 'x': 1 }]; + * + * _.pullAllBy(array, [{ 'x': 1 }, { 'x': 3 }], 'x'); + * console.log(array); + * // => [{ 'x': 2 }] + */ + function pullAllBy(array, values$2, iteratee$2) { + return array && array.length && values$2 && values$2.length ? basePullAll(array, values$2, getIteratee(iteratee$2, 2)) : array; + } + /** + * This method is like `_.pullAll` except that it accepts `comparator` which + * is invoked to compare elements of `array` to `values`. The comparator is + * invoked with two arguments: (arrVal, othVal). + * + * **Note:** Unlike `_.differenceWith`, this method mutates `array`. + * + * @static + * @memberOf _ + * @since 4.6.0 + * @category Array + * @param {Array} array The array to modify. + * @param {Array} values The values to remove. + * @param {Function} [comparator] The comparator invoked per element. + * @returns {Array} Returns `array`. + * @example + * + * var array = [{ 'x': 1, 'y': 2 }, { 'x': 3, 'y': 4 }, { 'x': 5, 'y': 6 }]; + * + * _.pullAllWith(array, [{ 'x': 3, 'y': 4 }], _.isEqual); + * console.log(array); + * // => [{ 'x': 1, 'y': 2 }, { 'x': 5, 'y': 6 }] + */ + function pullAllWith(array, values$2, comparator) { + return array && array.length && values$2 && values$2.length ? basePullAll(array, values$2, undefined$1, comparator) : array; + } + /** + * Removes elements from `array` corresponding to `indexes` and returns an + * array of removed elements. + * + * **Note:** Unlike `_.at`, this method mutates `array`. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Array + * @param {Array} array The array to modify. + * @param {...(number|number[])} [indexes] The indexes of elements to remove. + * @returns {Array} Returns the new array of removed elements. + * @example + * + * var array = ['a', 'b', 'c', 'd']; + * var pulled = _.pullAt(array, [1, 3]); + * + * console.log(array); + * // => ['a', 'c'] + * + * console.log(pulled); + * // => ['b', 'd'] + */ + var pullAt = flatRest(function(array, indexes) { + var length = array == null ? 0 : array.length, result$2 = baseAt(array, indexes); + basePullAt(array, arrayMap(indexes, function(index$1) { + return isIndex(index$1, length) ? +index$1 : index$1; + }).sort(compareAscending)); + return result$2; + }); + /** + * Removes all elements from `array` that `predicate` returns truthy for + * and returns an array of the removed elements. The predicate is invoked + * with three arguments: (value, index, array). + * + * **Note:** Unlike `_.filter`, this method mutates `array`. Use `_.pull` + * to pull elements from an array by value. + * + * @static + * @memberOf _ + * @since 2.0.0 + * @category Array + * @param {Array} array The array to modify. + * @param {Function} [predicate=_.identity] The function invoked per iteration. + * @returns {Array} Returns the new array of removed elements. + * @example + * + * var array = [1, 2, 3, 4]; + * var evens = _.remove(array, function(n) { + * return n % 2 == 0; + * }); + * + * console.log(array); + * // => [1, 3] + * + * console.log(evens); + * // => [2, 4] + */ + function remove$4(array, predicate) { + var result$2 = []; + if (!(array && array.length)) return result$2; + var index$1 = -1, indexes = [], length = array.length; + predicate = getIteratee(predicate, 3); + while (++index$1 < length) { + var value = array[index$1]; + if (predicate(value, index$1, array)) { + result$2.push(value); + indexes.push(index$1); + } + } + basePullAt(array, indexes); + return result$2; + } + /** + * Reverses `array` so that the first element becomes the last, the second + * element becomes the second to last, and so on. + * + * **Note:** This method mutates `array` and is based on + * [`Array#reverse`](https://mdn.io/Array/reverse). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {Array} array The array to modify. + * @returns {Array} Returns `array`. + * @example + * + * var array = [1, 2, 3]; + * + * _.reverse(array); + * // => [3, 2, 1] + * + * console.log(array); + * // => [3, 2, 1] + */ + function reverse(array) { + return array == null ? array : nativeReverse.call(array); + } + /** + * Creates a slice of `array` from `start` up to, but not including, `end`. + * + * **Note:** This method is used instead of + * [`Array#slice`](https://mdn.io/Array/slice) to ensure dense arrays are + * returned. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Array + * @param {Array} array The array to slice. + * @param {number} [start=0] The start position. + * @param {number} [end=array.length] The end position. + * @returns {Array} Returns the slice of `array`. + */ + function slice$3(array, start, end) { + var length = array == null ? 0 : array.length; + if (!length) return []; + if (end && typeof end != "number" && isIterateeCall(array, start, end)) { + start = 0; + end = length; + } else { + start = start == null ? 0 : toInteger(start); + end = end === undefined$1 ? length : toInteger(end); + } + return baseSlice$1(array, start, end); + } + /** + * Uses a binary search to determine the lowest index at which `value` + * should be inserted into `array` in order to maintain its sort order. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Array + * @param {Array} array The sorted array to inspect. + * @param {*} value The value to evaluate. + * @returns {number} Returns the index at which `value` should be inserted + * into `array`. + * @example + * + * _.sortedIndex([30, 50], 40); + * // => 1 + */ + function sortedIndex$1(array, value) { + return baseSortedIndex(array, value); + } + /** + * This method is like `_.sortedIndex` except that it accepts `iteratee` + * which is invoked for `value` and each element of `array` to compute their + * sort ranking. The iteratee is invoked with one argument: (value). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {Array} array The sorted array to inspect. + * @param {*} value The value to evaluate. + * @param {Function} [iteratee=_.identity] The iteratee invoked per element. + * @returns {number} Returns the index at which `value` should be inserted + * into `array`. + * @example + * + * var objects = [{ 'x': 4 }, { 'x': 5 }]; + * + * _.sortedIndexBy(objects, { 'x': 4 }, function(o) { return o.x; }); + * // => 0 + * + * // The `_.property` iteratee shorthand. + * _.sortedIndexBy(objects, { 'x': 4 }, 'x'); + * // => 0 + */ + function sortedIndexBy(array, value, iteratee$2) { + return baseSortedIndexBy(array, value, getIteratee(iteratee$2, 2)); + } + /** + * This method is like `_.indexOf` except that it performs a binary + * search on a sorted `array`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {Array} array The array to inspect. + * @param {*} value The value to search for. + * @returns {number} Returns the index of the matched value, else `-1`. + * @example + * + * _.sortedIndexOf([4, 5, 5, 5, 6], 5); + * // => 1 + */ + function sortedIndexOf(array, value) { + var length = array == null ? 0 : array.length; + if (length) { + var index$1 = baseSortedIndex(array, value); + if (index$1 < length && eq$1(array[index$1], value)) return index$1; + } + return -1; + } + /** + * This method is like `_.sortedIndex` except that it returns the highest + * index at which `value` should be inserted into `array` in order to + * maintain its sort order. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Array + * @param {Array} array The sorted array to inspect. + * @param {*} value The value to evaluate. + * @returns {number} Returns the index at which `value` should be inserted + * into `array`. + * @example + * + * _.sortedLastIndex([4, 5, 5, 5, 6], 5); + * // => 4 + */ + function sortedLastIndex(array, value) { + return baseSortedIndex(array, value, true); + } + /** + * This method is like `_.sortedLastIndex` except that it accepts `iteratee` + * which is invoked for `value` and each element of `array` to compute their + * sort ranking. The iteratee is invoked with one argument: (value). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {Array} array The sorted array to inspect. + * @param {*} value The value to evaluate. + * @param {Function} [iteratee=_.identity] The iteratee invoked per element. + * @returns {number} Returns the index at which `value` should be inserted + * into `array`. + * @example + * + * var objects = [{ 'x': 4 }, { 'x': 5 }]; + * + * _.sortedLastIndexBy(objects, { 'x': 4 }, function(o) { return o.x; }); + * // => 1 + * + * // The `_.property` iteratee shorthand. + * _.sortedLastIndexBy(objects, { 'x': 4 }, 'x'); + * // => 1 + */ + function sortedLastIndexBy(array, value, iteratee$2) { + return baseSortedIndexBy(array, value, getIteratee(iteratee$2, 2), true); + } + /** + * This method is like `_.lastIndexOf` except that it performs a binary + * search on a sorted `array`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {Array} array The array to inspect. + * @param {*} value The value to search for. + * @returns {number} Returns the index of the matched value, else `-1`. + * @example + * + * _.sortedLastIndexOf([4, 5, 5, 5, 6], 5); + * // => 3 + */ + function sortedLastIndexOf(array, value) { + var length = array == null ? 0 : array.length; + if (length) { + var index$1 = baseSortedIndex(array, value, true) - 1; + if (eq$1(array[index$1], value)) return index$1; + } + return -1; + } + /** + * This method is like `_.uniq` except that it's designed and optimized + * for sorted arrays. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {Array} array The array to inspect. + * @returns {Array} Returns the new duplicate free array. + * @example + * + * _.sortedUniq([1, 1, 2]); + * // => [1, 2] + */ + function sortedUniq(array) { + return array && array.length ? baseSortedUniq(array) : []; + } + /** + * This method is like `_.uniqBy` except that it's designed and optimized + * for sorted arrays. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {Array} array The array to inspect. + * @param {Function} [iteratee] The iteratee invoked per element. + * @returns {Array} Returns the new duplicate free array. + * @example + * + * _.sortedUniqBy([1.1, 1.2, 2.3, 2.4], Math.floor); + * // => [1.1, 2.3] + */ + function sortedUniqBy(array, iteratee$2) { + return array && array.length ? baseSortedUniq(array, getIteratee(iteratee$2, 2)) : []; + } + /** + * Gets all but the first element of `array`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {Array} array The array to query. + * @returns {Array} Returns the slice of `array`. + * @example + * + * _.tail([1, 2, 3]); + * // => [2, 3] + */ + function tail(array) { + var length = array == null ? 0 : array.length; + return length ? baseSlice$1(array, 1, length) : []; + } + /** + * Creates a slice of `array` with `n` elements taken from the beginning. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Array + * @param {Array} array The array to query. + * @param {number} [n=1] The number of elements to take. + * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`. + * @returns {Array} Returns the slice of `array`. + * @example + * + * _.take([1, 2, 3]); + * // => [1] + * + * _.take([1, 2, 3], 2); + * // => [1, 2] + * + * _.take([1, 2, 3], 5); + * // => [1, 2, 3] + * + * _.take([1, 2, 3], 0); + * // => [] + */ + function take(array, n$3, guard) { + if (!(array && array.length)) return []; + n$3 = guard || n$3 === undefined$1 ? 1 : toInteger(n$3); + return baseSlice$1(array, 0, n$3 < 0 ? 0 : n$3); + } + /** + * Creates a slice of `array` with `n` elements taken from the end. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Array + * @param {Array} array The array to query. + * @param {number} [n=1] The number of elements to take. + * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`. + * @returns {Array} Returns the slice of `array`. + * @example + * + * _.takeRight([1, 2, 3]); + * // => [3] + * + * _.takeRight([1, 2, 3], 2); + * // => [2, 3] + * + * _.takeRight([1, 2, 3], 5); + * // => [1, 2, 3] + * + * _.takeRight([1, 2, 3], 0); + * // => [] + */ + function takeRight(array, n$3, guard) { + var length = array == null ? 0 : array.length; + if (!length) return []; + n$3 = guard || n$3 === undefined$1 ? 1 : toInteger(n$3); + n$3 = length - n$3; + return baseSlice$1(array, n$3 < 0 ? 0 : n$3, length); + } + /** + * Creates a slice of `array` with elements taken from the end. Elements are + * taken until `predicate` returns falsey. The predicate is invoked with + * three arguments: (value, index, array). + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Array + * @param {Array} array The array to query. + * @param {Function} [predicate=_.identity] The function invoked per iteration. + * @returns {Array} Returns the slice of `array`. + * @example + * + * var users = [ + * { 'user': 'barney', 'active': true }, + * { 'user': 'fred', 'active': false }, + * { 'user': 'pebbles', 'active': false } + * ]; + * + * _.takeRightWhile(users, function(o) { return !o.active; }); + * // => objects for ['fred', 'pebbles'] + * + * // The `_.matches` iteratee shorthand. + * _.takeRightWhile(users, { 'user': 'pebbles', 'active': false }); + * // => objects for ['pebbles'] + * + * // The `_.matchesProperty` iteratee shorthand. + * _.takeRightWhile(users, ['active', false]); + * // => objects for ['fred', 'pebbles'] + * + * // The `_.property` iteratee shorthand. + * _.takeRightWhile(users, 'active'); + * // => [] + */ + function takeRightWhile(array, predicate) { + return array && array.length ? baseWhile(array, getIteratee(predicate, 3), false, true) : []; + } + /** + * Creates a slice of `array` with elements taken from the beginning. Elements + * are taken until `predicate` returns falsey. The predicate is invoked with + * three arguments: (value, index, array). + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Array + * @param {Array} array The array to query. + * @param {Function} [predicate=_.identity] The function invoked per iteration. + * @returns {Array} Returns the slice of `array`. + * @example + * + * var users = [ + * { 'user': 'barney', 'active': false }, + * { 'user': 'fred', 'active': false }, + * { 'user': 'pebbles', 'active': true } + * ]; + * + * _.takeWhile(users, function(o) { return !o.active; }); + * // => objects for ['barney', 'fred'] + * + * // The `_.matches` iteratee shorthand. + * _.takeWhile(users, { 'user': 'barney', 'active': false }); + * // => objects for ['barney'] + * + * // The `_.matchesProperty` iteratee shorthand. + * _.takeWhile(users, ['active', false]); + * // => objects for ['barney', 'fred'] + * + * // The `_.property` iteratee shorthand. + * _.takeWhile(users, 'active'); + * // => [] + */ + function takeWhile(array, predicate) { + return array && array.length ? baseWhile(array, getIteratee(predicate, 3)) : []; + } + /** + * 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)); + }); + /** + * This method is like `_.union` except that it accepts `iteratee` which is + * invoked for each element of each `arrays` to generate the criterion by + * which uniqueness is computed. Result values are chosen from the first + * array in which the value occurs. The iteratee is invoked with one argument: + * (value). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {...Array} [arrays] The arrays to inspect. + * @param {Function} [iteratee=_.identity] The iteratee invoked per element. + * @returns {Array} Returns the new array of combined values. + * @example + * + * _.unionBy([2.1], [1.2, 2.3], Math.floor); + * // => [2.1, 1.2] + * + * // The `_.property` iteratee shorthand. + * _.unionBy([{ 'x': 1 }], [{ 'x': 2 }, { 'x': 1 }], 'x'); + * // => [{ 'x': 1 }, { 'x': 2 }] + */ + var unionBy = baseRest(function(arrays) { + var iteratee$2 = last$3(arrays); + if (isArrayLikeObject(iteratee$2)) iteratee$2 = undefined$1; + return baseUniq(baseFlatten(arrays, 1, isArrayLikeObject, true), getIteratee(iteratee$2, 2)); + }); + /** + * This method is like `_.union` except that it accepts `comparator` which + * is invoked to compare elements of `arrays`. Result values are chosen from + * the first array in which the value occurs. The comparator is invoked + * with two arguments: (arrVal, othVal). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {...Array} [arrays] The arrays to inspect. + * @param {Function} [comparator] The comparator invoked per element. + * @returns {Array} Returns the new array of combined values. + * @example + * + * var objects = [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }]; + * var others = [{ 'x': 1, 'y': 1 }, { 'x': 1, 'y': 2 }]; + * + * _.unionWith(objects, others, _.isEqual); + * // => [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }, { 'x': 1, 'y': 1 }] + */ + var unionWith = baseRest(function(arrays) { + var comparator = last$3(arrays); + comparator = typeof comparator == "function" ? comparator : undefined$1; + return baseUniq(baseFlatten(arrays, 1, isArrayLikeObject, true), undefined$1, comparator); + }); + /** + * Creates a duplicate-free version of an array, using + * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) + * for equality comparisons, in which only the first occurrence of each element + * is kept. The order of result values is determined by the order they occur + * in the array. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Array + * @param {Array} array The array to inspect. + * @returns {Array} Returns the new duplicate free array. + * @example + * + * _.uniq([2, 1, 2]); + * // => [2, 1] + */ + function uniq$1(array) { + return array && array.length ? baseUniq(array) : []; + } + /** + * This method is like `_.uniq` except that it accepts `iteratee` which is + * invoked for each element in `array` to generate the criterion by which + * uniqueness is computed. The order of result values is determined by the + * order they occur in the array. The iteratee is invoked with one argument: + * (value). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {Array} array The array to inspect. + * @param {Function} [iteratee=_.identity] The iteratee invoked per element. + * @returns {Array} Returns the new duplicate free array. + * @example + * + * _.uniqBy([2.1, 1.2, 2.3], Math.floor); + * // => [2.1, 1.2] + * + * // The `_.property` iteratee shorthand. + * _.uniqBy([{ 'x': 1 }, { 'x': 2 }, { 'x': 1 }], 'x'); + * // => [{ 'x': 1 }, { 'x': 2 }] + */ + function uniqBy(array, iteratee$2) { + return array && array.length ? baseUniq(array, getIteratee(iteratee$2, 2)) : []; + } + /** + * This method is like `_.uniq` except that it accepts `comparator` which + * is invoked to compare elements of `array`. The order of result values is + * determined by the order they occur in the array.The comparator is invoked + * with two arguments: (arrVal, othVal). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {Array} array The array to inspect. + * @param {Function} [comparator] The comparator invoked per element. + * @returns {Array} Returns the new duplicate free array. + * @example + * + * var objects = [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }, { 'x': 1, 'y': 2 }]; + * + * _.uniqWith(objects, _.isEqual); + * // => [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }] + */ + function uniqWith(array, comparator) { + comparator = typeof comparator == "function" ? comparator : undefined$1; + return array && array.length ? baseUniq(array, undefined$1, comparator) : []; + } + /** + * This method is like `_.zip` except that it accepts an array of grouped + * elements and creates an array regrouping the elements to their pre-zip + * configuration. + * + * @static + * @memberOf _ + * @since 1.2.0 + * @category Array + * @param {Array} array The array of grouped elements to process. + * @returns {Array} Returns the new array of regrouped elements. + * @example + * + * var zipped = _.zip(['a', 'b'], [1, 2], [true, false]); + * // => [['a', 1, true], ['b', 2, false]] + * + * _.unzip(zipped); + * // => [['a', 'b'], [1, 2], [true, false]] + */ + function unzip$1(array) { + if (!(array && array.length)) return []; + var length = 0; + array = arrayFilter(array, function(group$1) { + if (isArrayLikeObject(group$1)) { + length = nativeMax(group$1.length, length); + return true; + } + }); + return baseTimes(length, function(index$1) { + return arrayMap(array, baseProperty(index$1)); + }); + } + /** + * This method is like `_.unzip` except that it accepts `iteratee` to specify + * how regrouped values should be combined. The iteratee is invoked with the + * elements of each group: (...group). + * + * @static + * @memberOf _ + * @since 3.8.0 + * @category Array + * @param {Array} array The array of grouped elements to process. + * @param {Function} [iteratee=_.identity] The function to combine + * regrouped values. + * @returns {Array} Returns the new array of regrouped elements. + * @example + * + * var zipped = _.zip([1, 2], [10, 20], [100, 200]); + * // => [[1, 10, 100], [2, 20, 200]] + * + * _.unzipWith(zipped, _.add); + * // => [3, 30, 300] + */ + function unzipWith(array, iteratee$2) { + if (!(array && array.length)) return []; + var result$2 = unzip$1(array); + if (iteratee$2 == null) return result$2; + return arrayMap(result$2, function(group$1) { + return apply(iteratee$2, undefined$1, group$1); + }); + } + /** + * Creates an array excluding all given values using + * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) + * for equality comparisons. + * + * **Note:** Unlike `_.pull`, this method returns a new array. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Array + * @param {Array} array The array to inspect. + * @param {...*} [values] The values to exclude. + * @returns {Array} Returns the new array of filtered values. + * @see _.difference, _.xor + * @example + * + * _.without([2, 1, 2, 3], 1, 2); + * // => [3] + */ + var without = baseRest(function(array, values$2) { + return isArrayLikeObject(array) ? baseDifference(array, values$2) : []; + }); + /** + * Creates an array of unique values that is the + * [symmetric difference](https://en.wikipedia.org/wiki/Symmetric_difference) + * of the given arrays. The order of result values is determined by the order + * they occur in the arrays. + * + * @static + * @memberOf _ + * @since 2.4.0 + * @category Array + * @param {...Array} [arrays] The arrays to inspect. + * @returns {Array} Returns the new array of filtered values. + * @see _.difference, _.without + * @example + * + * _.xor([2, 1], [2, 3]); + * // => [1, 3] + */ + var xor = baseRest(function(arrays) { + return baseXor(arrayFilter(arrays, isArrayLikeObject)); + }); + /** + * This method is like `_.xor` except that it accepts `iteratee` which is + * invoked for each element of each `arrays` to generate the criterion by + * which by which they're compared. The order of result values is determined + * by the order they occur in the arrays. The iteratee is invoked with one + * argument: (value). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {...Array} [arrays] The arrays to inspect. + * @param {Function} [iteratee=_.identity] The iteratee invoked per element. + * @returns {Array} Returns the new array of filtered values. + * @example + * + * _.xorBy([2.1, 1.2], [2.3, 3.4], Math.floor); + * // => [1.2, 3.4] + * + * // The `_.property` iteratee shorthand. + * _.xorBy([{ 'x': 1 }], [{ 'x': 2 }, { 'x': 1 }], 'x'); + * // => [{ 'x': 2 }] + */ + var xorBy = baseRest(function(arrays) { + var iteratee$2 = last$3(arrays); + if (isArrayLikeObject(iteratee$2)) iteratee$2 = undefined$1; + return baseXor(arrayFilter(arrays, isArrayLikeObject), getIteratee(iteratee$2, 2)); + }); + /** + * This method is like `_.xor` except that it accepts `comparator` which is + * invoked to compare elements of `arrays`. The order of result values is + * determined by the order they occur in the arrays. The comparator is invoked + * with two arguments: (arrVal, othVal). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Array + * @param {...Array} [arrays] The arrays to inspect. + * @param {Function} [comparator] The comparator invoked per element. + * @returns {Array} Returns the new array of filtered values. + * @example + * + * var objects = [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }]; + * var others = [{ 'x': 1, 'y': 1 }, { 'x': 1, 'y': 2 }]; + * + * _.xorWith(objects, others, _.isEqual); + * // => [{ 'x': 2, 'y': 1 }, { 'x': 1, 'y': 1 }] + */ + var xorWith = baseRest(function(arrays) { + var comparator = last$3(arrays); + comparator = typeof comparator == "function" ? comparator : undefined$1; + return baseXor(arrayFilter(arrays, isArrayLikeObject), undefined$1, comparator); + }); + /** + * Creates an array of grouped elements, the first of which contains the + * first elements of the given arrays, the second of which contains the + * second elements of the given arrays, and so on. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Array + * @param {...Array} [arrays] The arrays to process. + * @returns {Array} Returns the new array of grouped elements. + * @example + * + * _.zip(['a', 'b'], [1, 2], [true, false]); + * // => [['a', 1, true], ['b', 2, false]] + */ + var zip = baseRest(unzip$1); + /** + * This method is like `_.fromPairs` except that it accepts two arrays, + * one of property identifiers and one of corresponding values. + * + * @static + * @memberOf _ + * @since 0.4.0 + * @category Array + * @param {Array} [props=[]] The property identifiers. + * @param {Array} [values=[]] The property values. + * @returns {Object} Returns the new object. + * @example + * + * _.zipObject(['a', 'b'], [1, 2]); + * // => { 'a': 1, 'b': 2 } + */ + function zipObject(props, values$2) { + return baseZipObject(props || [], values$2 || [], assignValue); + } + /** + * This method is like `_.zipObject` except that it supports property paths. + * + * @static + * @memberOf _ + * @since 4.1.0 + * @category Array + * @param {Array} [props=[]] The property identifiers. + * @param {Array} [values=[]] The property values. + * @returns {Object} Returns the new object. + * @example + * + * _.zipObjectDeep(['a.b[0].c', 'a.b[1].d'], [1, 2]); + * // => { 'a': { 'b': [{ 'c': 1 }, { 'd': 2 }] } } + */ + function zipObjectDeep(props, values$2) { + return baseZipObject(props || [], values$2 || [], baseSet); + } + /** + * This method is like `_.zip` except that it accepts `iteratee` to specify + * how grouped values should be combined. The iteratee is invoked with the + * elements of each group: (...group). + * + * @static + * @memberOf _ + * @since 3.8.0 + * @category Array + * @param {...Array} [arrays] The arrays to process. + * @param {Function} [iteratee=_.identity] The function to combine + * grouped values. + * @returns {Array} Returns the new array of grouped elements. + * @example + * + * _.zipWith([1, 2], [10, 20], [100, 200], function(a, b, c) { + * return a + b + c; + * }); + * // => [111, 222] + */ + var zipWith = baseRest(function(arrays) { + var length = arrays.length, iteratee$2 = length > 1 ? arrays[length - 1] : undefined$1; + iteratee$2 = typeof iteratee$2 == "function" ? (arrays.pop(), iteratee$2) : undefined$1; + return unzipWith(arrays, iteratee$2); + }); + /** + * Creates a `lodash` wrapper instance that wraps `value` with explicit method + * chain sequences enabled. The result of such sequences must be unwrapped + * with `_#value`. + * + * @static + * @memberOf _ + * @since 1.3.0 + * @category Seq + * @param {*} value The value to wrap. + * @returns {Object} Returns the new `lodash` wrapper instance. + * @example + * + * var users = [ + * { 'user': 'barney', 'age': 36 }, + * { 'user': 'fred', 'age': 40 }, + * { 'user': 'pebbles', 'age': 1 } + * ]; + * + * var youngest = _ + * .chain(users) + * .sortBy('age') + * .map(function(o) { + * return o.user + ' is ' + o.age; + * }) + * .head() + * .value(); + * // => 'pebbles is 1' + */ + function chain$2(value) { + var result$2 = lodash(value); + result$2.__chain__ = true; + return result$2; + } + /** + * This method invokes `interceptor` and returns `value`. The interceptor + * is invoked with one argument; (value). The purpose of this method is to + * "tap into" a method chain sequence in order to modify intermediate results. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Seq + * @param {*} value The value to provide to `interceptor`. + * @param {Function} interceptor The function to invoke. + * @returns {*} Returns `value`. + * @example + * + * _([1, 2, 3]) + * .tap(function(array) { + * // Mutate input array. + * array.pop(); + * }) + * .reverse() + * .value(); + * // => [2, 1] + */ + function tap$1(value, interceptor) { + interceptor(value); + return value; + } + /** + * This method is like `_.tap` except that it returns the result of `interceptor`. + * The purpose of this method is to "pass thru" values replacing intermediate + * results in a method chain sequence. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Seq + * @param {*} value The value to provide to `interceptor`. + * @param {Function} interceptor The function to invoke. + * @returns {*} Returns the result of `interceptor`. + * @example + * + * _(' abc ') + * .chain() + * .trim() + * .thru(function(value) { + * return [value]; + * }) + * .value(); + * // => ['abc'] + */ + function thru(value, interceptor) { + return interceptor(value); + } + /** + * This method is the wrapper version of `_.at`. + * + * @name at + * @memberOf _ + * @since 1.0.0 + * @category Seq + * @param {...(string|string[])} [paths] The property paths to pick. + * @returns {Object} Returns the new `lodash` wrapper instance. + * @example + * + * var object = { 'a': [{ 'b': { 'c': 3 } }, 4] }; + * + * _(object).at(['a[0].b.c', 'a[1]']).value(); + * // => [3, 4] + */ + var wrapperAt = flatRest(function(paths) { + var length = paths.length, start = length ? paths[0] : 0, value = this.__wrapped__, interceptor = function(object$3) { + return baseAt(object$3, paths); + }; + if (length > 1 || this.__actions__.length || !(value instanceof LazyWrapper) || !isIndex(start)) return this.thru(interceptor); + value = value.slice(start, +start + (length ? 1 : 0)); + value.__actions__.push({ + "func": thru, + "args": [interceptor], + "thisArg": undefined$1 + }); + return new LodashWrapper(value, this.__chain__).thru(function(array) { + if (length && !array.length) array.push(undefined$1); + return array; + }); + }); + /** + * Creates a `lodash` wrapper instance with explicit method chain sequences enabled. + * + * @name chain + * @memberOf _ + * @since 0.1.0 + * @category Seq + * @returns {Object} Returns the new `lodash` wrapper instance. + * @example + * + * var users = [ + * { 'user': 'barney', 'age': 36 }, + * { 'user': 'fred', 'age': 40 } + * ]; + * + * // A sequence without explicit chaining. + * _(users).head(); + * // => { 'user': 'barney', 'age': 36 } + * + * // A sequence with explicit chaining. + * _(users) + * .chain() + * .head() + * .pick('user') + * .value(); + * // => { 'user': 'barney' } + */ + function wrapperChain() { + return chain$2(this); + } + /** + * Executes the chain sequence and returns the wrapped result. + * + * @name commit + * @memberOf _ + * @since 3.2.0 + * @category Seq + * @returns {Object} Returns the new `lodash` wrapper instance. + * @example + * + * var array = [1, 2]; + * var wrapped = _(array).push(3); + * + * console.log(array); + * // => [1, 2] + * + * wrapped = wrapped.commit(); + * console.log(array); + * // => [1, 2, 3] + * + * wrapped.last(); + * // => 3 + * + * console.log(array); + * // => [1, 2, 3] + */ + function wrapperCommit() { + return new LodashWrapper(this.value(), this.__chain__); + } + /** + * Gets the next value on a wrapped object following the + * [iterator protocol](https://mdn.io/iteration_protocols#iterator). + * + * @name next + * @memberOf _ + * @since 4.0.0 + * @category Seq + * @returns {Object} Returns the next iterator value. + * @example + * + * var wrapped = _([1, 2]); + * + * wrapped.next(); + * // => { 'done': false, 'value': 1 } + * + * wrapped.next(); + * // => { 'done': false, 'value': 2 } + * + * wrapped.next(); + * // => { 'done': true, 'value': undefined } + */ + function wrapperNext() { + if (this.__values__ === undefined$1) this.__values__ = toArray$1(this.value()); + var done = this.__index__ >= this.__values__.length, value = done ? undefined$1 : this.__values__[this.__index__++]; + return { + "done": done, + "value": value + }; + } + /** + * Enables the wrapper to be iterable. + * + * @name Symbol.iterator + * @memberOf _ + * @since 4.0.0 + * @category Seq + * @returns {Object} Returns the wrapper object. + * @example + * + * var wrapped = _([1, 2]); + * + * wrapped[Symbol.iterator]() === wrapped; + * // => true + * + * Array.from(wrapped); + * // => [1, 2] + */ + function wrapperToIterator() { + return this; + } + /** + * Creates a clone of the chain sequence planting `value` as the wrapped value. + * + * @name plant + * @memberOf _ + * @since 3.2.0 + * @category Seq + * @param {*} value The value to plant. + * @returns {Object} Returns the new `lodash` wrapper instance. + * @example + * + * function square(n) { + * return n * n; + * } + * + * var wrapped = _([1, 2]).map(square); + * var other = wrapped.plant([3, 4]); + * + * other.value(); + * // => [9, 16] + * + * wrapped.value(); + * // => [1, 4] + */ + function wrapperPlant(value) { + var result$2, parent$1 = this; + while (parent$1 instanceof baseLodash) { + var clone$6 = wrapperClone(parent$1); + clone$6.__index__ = 0; + clone$6.__values__ = undefined$1; + if (result$2) previous.__wrapped__ = clone$6; + else result$2 = clone$6; + var previous = clone$6; + parent$1 = parent$1.__wrapped__; + } + previous.__wrapped__ = value; + return result$2; + } + /** + * This method is the wrapper version of `_.reverse`. + * + * **Note:** This method mutates the wrapped array. + * + * @name reverse + * @memberOf _ + * @since 0.1.0 + * @category Seq + * @returns {Object} Returns the new `lodash` wrapper instance. + * @example + * + * var array = [1, 2, 3]; + * + * _(array).reverse().value() + * // => [3, 2, 1] + * + * console.log(array); + * // => [3, 2, 1] + */ + function wrapperReverse() { + var value = this.__wrapped__; + if (value instanceof LazyWrapper) { + var wrapped = value; + if (this.__actions__.length) wrapped = new LazyWrapper(this); + wrapped = wrapped.reverse(); + wrapped.__actions__.push({ + "func": thru, + "args": [reverse], + "thisArg": undefined$1 + }); + return new LodashWrapper(wrapped, this.__chain__); + } + return this.thru(reverse); + } + /** + * Executes the chain sequence to resolve the unwrapped value. + * + * @name value + * @memberOf _ + * @since 0.1.0 + * @alias toJSON, valueOf + * @category Seq + * @returns {*} Returns the resolved unwrapped value. + * @example + * + * _([1, 2, 3]).value(); + * // => [1, 2, 3] + */ + function wrapperValue() { + return baseWrapperValue(this.__wrapped__, this.__actions__); + } + /** + * Creates an object composed of keys generated from the results of running + * each element of `collection` thru `iteratee`. The corresponding value of + * each key is the number of times the key was returned by `iteratee`. The + * iteratee is invoked with one argument: (value). + * + * @static + * @memberOf _ + * @since 0.5.0 + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} [iteratee=_.identity] The iteratee to transform keys. + * @returns {Object} Returns the composed aggregate object. + * @example + * + * _.countBy([6.1, 4.2, 6.3], Math.floor); + * // => { '4': 1, '6': 2 } + * + * // The `_.property` iteratee shorthand. + * _.countBy(['one', 'two', 'three'], 'length'); + * // => { '3': 2, '5': 1 } + */ + var countBy = createAggregator(function(result$2, value, key) { + if (hasOwnProperty$6.call(result$2, key)) ++result$2[key]; + else baseAssignValue(result$2, key, 1); + }); + /** + * Checks if `predicate` returns truthy for **all** elements of `collection`. + * Iteration is stopped once `predicate` returns falsey. The predicate is + * invoked with three arguments: (value, index|key, collection). + * + * **Note:** This method returns `true` for + * [empty collections](https://en.wikipedia.org/wiki/Empty_set) because + * [everything is true](https://en.wikipedia.org/wiki/Vacuous_truth) of + * elements of empty collections. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} [predicate=_.identity] The function invoked per iteration. + * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`. + * @returns {boolean} Returns `true` if all elements pass the predicate check, + * else `false`. + * @example + * + * _.every([true, 1, null, 'yes'], Boolean); + * // => false + * + * var users = [ + * { 'user': 'barney', 'age': 36, 'active': false }, + * { 'user': 'fred', 'age': 40, 'active': false } + * ]; + * + * // The `_.matches` iteratee shorthand. + * _.every(users, { 'user': 'barney', 'active': false }); + * // => false + * + * // The `_.matchesProperty` iteratee shorthand. + * _.every(users, ['active', false]); + * // => true + * + * // The `_.property` iteratee shorthand. + * _.every(users, 'active'); + * // => false + */ + function every$1(collection, predicate, guard) { + var func = isArray$5(collection) ? arrayEvery : baseEvery; + if (guard && isIterateeCall(collection, predicate, guard)) predicate = undefined$1; + return func(collection, getIteratee(predicate, 3)); + } + /** + * Iterates over elements of `collection`, returning an array of all elements + * `predicate` returns truthy for. The predicate is invoked with three + * arguments: (value, index|key, collection). + * + * **Note:** Unlike `_.remove`, this method returns a new array. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} [predicate=_.identity] The function invoked per iteration. + * @returns {Array} Returns the new filtered array. + * @see _.reject + * @example + * + * var users = [ + * { 'user': 'barney', 'age': 36, 'active': true }, + * { 'user': 'fred', 'age': 40, 'active': false } + * ]; + * + * _.filter(users, function(o) { return !o.active; }); + * // => objects for ['fred'] + * + * // The `_.matches` iteratee shorthand. + * _.filter(users, { 'age': 36, 'active': true }); + * // => objects for ['barney'] + * + * // The `_.matchesProperty` iteratee shorthand. + * _.filter(users, ['active', false]); + * // => objects for ['fred'] + * + * // The `_.property` iteratee shorthand. + * _.filter(users, 'active'); + * // => objects for ['barney'] + * + * // Combining several predicates using `_.overEvery` or `_.overSome`. + * _.filter(users, _.overSome([{ 'age': 36 }, ['age', 40]])); + * // => objects for ['fred', 'barney'] + */ + function filter$3(collection, predicate) { + var func = isArray$5(collection) ? arrayFilter : baseFilter; + return func(collection, getIteratee(predicate, 3)); + } + /** + * Iterates over elements of `collection`, returning the first element + * `predicate` returns truthy for. The predicate is invoked with three + * arguments: (value, index|key, collection). + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Collection + * @param {Array|Object} collection The collection to inspect. + * @param {Function} [predicate=_.identity] The function invoked per iteration. + * @param {number} [fromIndex=0] The index to search from. + * @returns {*} Returns the matched element, else `undefined`. + * @example + * + * var users = [ + * { 'user': 'barney', 'age': 36, 'active': true }, + * { 'user': 'fred', 'age': 40, 'active': false }, + * { 'user': 'pebbles', 'age': 1, 'active': true } + * ]; + * + * _.find(users, function(o) { return o.age < 40; }); + * // => object for 'barney' + * + * // The `_.matches` iteratee shorthand. + * _.find(users, { 'age': 1, 'active': true }); + * // => object for 'pebbles' + * + * // The `_.matchesProperty` iteratee shorthand. + * _.find(users, ['active', false]); + * // => object for 'fred' + * + * // The `_.property` iteratee shorthand. + * _.find(users, 'active'); + * // => object for 'barney' + */ + var find$3 = createFind(findIndex); + /** + * This method is like `_.find` except that it iterates over elements of + * `collection` from right to left. + * + * @static + * @memberOf _ + * @since 2.0.0 + * @category Collection + * @param {Array|Object} collection The collection to inspect. + * @param {Function} [predicate=_.identity] The function invoked per iteration. + * @param {number} [fromIndex=collection.length-1] The index to search from. + * @returns {*} Returns the matched element, else `undefined`. + * @example + * + * _.findLast([1, 2, 3, 4], function(n) { + * return n % 2 == 1; + * }); + * // => 3 + */ + var findLast = createFind(findLastIndex); + /** + * Creates a flattened array of values by running each element in `collection` + * thru `iteratee` and flattening the mapped results. The iteratee is invoked + * with three arguments: (value, index|key, collection). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} [iteratee=_.identity] The function invoked per iteration. + * @returns {Array} Returns the new flattened array. + * @example + * + * function duplicate(n) { + * return [n, n]; + * } + * + * _.flatMap([1, 2], duplicate); + * // => [1, 1, 2, 2] + */ + function flatMap(collection, iteratee$2) { + return baseFlatten(map$1(collection, iteratee$2), 1); + } + /** + * This method is like `_.flatMap` except that it recursively flattens the + * mapped results. + * + * @static + * @memberOf _ + * @since 4.7.0 + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} [iteratee=_.identity] The function invoked per iteration. + * @returns {Array} Returns the new flattened array. + * @example + * + * function duplicate(n) { + * return [[[n, n]]]; + * } + * + * _.flatMapDeep([1, 2], duplicate); + * // => [1, 1, 2, 2] + */ + function flatMapDeep(collection, iteratee$2) { + return baseFlatten(map$1(collection, iteratee$2), INFINITY$1); + } + /** + * This method is like `_.flatMap` except that it recursively flattens the + * mapped results up to `depth` times. + * + * @static + * @memberOf _ + * @since 4.7.0 + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} [iteratee=_.identity] The function invoked per iteration. + * @param {number} [depth=1] The maximum recursion depth. + * @returns {Array} Returns the new flattened array. + * @example + * + * function duplicate(n) { + * return [[[n, n]]]; + * } + * + * _.flatMapDepth([1, 2], duplicate, 2); + * // => [[1, 1], [2, 2]] + */ + function flatMapDepth(collection, iteratee$2, depth$1) { + depth$1 = depth$1 === undefined$1 ? 1 : toInteger(depth$1); + return baseFlatten(map$1(collection, iteratee$2), depth$1); + } + /** + * Iterates over elements of `collection` and invokes `iteratee` for each element. + * The iteratee is invoked with three arguments: (value, index|key, collection). + * Iteratee functions may exit iteration early by explicitly returning `false`. + * + * **Note:** As with other "Collections" methods, objects with a "length" + * property are iterated like arrays. To avoid this behavior use `_.forIn` + * or `_.forOwn` for object iteration. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @alias each + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} [iteratee=_.identity] The function invoked per iteration. + * @returns {Array|Object} Returns `collection`. + * @see _.forEachRight + * @example + * + * _.forEach([1, 2], function(value) { + * console.log(value); + * }); + * // => Logs `1` then `2`. + * + * _.forEach({ 'a': 1, 'b': 2 }, function(value, key) { + * console.log(key); + * }); + * // => Logs 'a' then 'b' (iteration order is not guaranteed). + */ + function forEach$1(collection, iteratee$2) { + var func = isArray$5(collection) ? arrayEach : baseEach; + return func(collection, getIteratee(iteratee$2, 3)); + } + /** + * This method is like `_.forEach` except that it iterates over elements of + * `collection` from right to left. + * + * @static + * @memberOf _ + * @since 2.0.0 + * @alias eachRight + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} [iteratee=_.identity] The function invoked per iteration. + * @returns {Array|Object} Returns `collection`. + * @see _.forEach + * @example + * + * _.forEachRight([1, 2], function(value) { + * console.log(value); + * }); + * // => Logs `2` then `1`. + */ + function forEachRight(collection, iteratee$2) { + var func = isArray$5(collection) ? arrayEachRight : baseEachRight; + return func(collection, getIteratee(iteratee$2, 3)); + } + /** + * Creates an object composed of keys generated from the results of running + * each element of `collection` thru `iteratee`. The order of grouped values + * is determined by the order they occur in `collection`. The corresponding + * value of each key is an array of elements responsible for generating the + * key. The iteratee is invoked with one argument: (value). + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} [iteratee=_.identity] The iteratee to transform keys. + * @returns {Object} Returns the composed aggregate object. + * @example + * + * _.groupBy([6.1, 4.2, 6.3], Math.floor); + * // => { '4': [4.2], '6': [6.1, 6.3] } + * + * // The `_.property` iteratee shorthand. + * _.groupBy(['one', 'two', 'three'], 'length'); + * // => { '3': ['one', 'two'], '5': ['three'] } + */ + var groupBy = createAggregator(function(result$2, value, key) { + if (hasOwnProperty$6.call(result$2, key)) result$2[key].push(value); + else baseAssignValue(result$2, key, [value]); + }); + /** + * 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$1(collection); + fromIndex = fromIndex && !guard ? toInteger(fromIndex) : 0; + var length = collection.length; + if (fromIndex < 0) fromIndex = nativeMax(length + fromIndex, 0); + return isString$5(collection) ? fromIndex <= length && collection.indexOf(value, fromIndex) > -1 : !!length && baseIndexOf(collection, value, fromIndex) > -1; + } + /** + * Invokes the method at `path` of each element in `collection`, returning + * an array of the results of each invoked method. Any additional arguments + * are provided to each invoked method. If `path` is a function, it's invoked + * for, and `this` bound to, each element in `collection`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {Array|Function|string} path The path of the method to invoke or + * the function invoked per iteration. + * @param {...*} [args] The arguments to invoke each method with. + * @returns {Array} Returns the array of results. + * @example + * + * _.invokeMap([[5, 1, 7], [3, 2, 1]], 'sort'); + * // => [[1, 5, 7], [1, 2, 3]] + * + * _.invokeMap([123, 456], String.prototype.split, ''); + * // => [['1', '2', '3'], ['4', '5', '6']] + */ + var invokeMap = baseRest(function(collection, path$28, args) { + var index$1 = -1, isFunc = typeof path$28 == "function", result$2 = isArrayLike(collection) ? Array$1(collection.length) : []; + baseEach(collection, function(value) { + result$2[++index$1] = isFunc ? apply(path$28, value, args) : baseInvoke(value, path$28, args); + }); + return result$2; + }); + /** + * Creates an object composed of keys generated from the results of running + * each element of `collection` thru `iteratee`. The corresponding value of + * each key is the last element responsible for generating the key. The + * iteratee is invoked with one argument: (value). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} [iteratee=_.identity] The iteratee to transform keys. + * @returns {Object} Returns the composed aggregate object. + * @example + * + * var array = [ + * { 'dir': 'left', 'code': 97 }, + * { 'dir': 'right', 'code': 100 } + * ]; + * + * _.keyBy(array, function(o) { + * return String.fromCharCode(o.code); + * }); + * // => { 'a': { 'dir': 'left', 'code': 97 }, 'd': { 'dir': 'right', 'code': 100 } } + * + * _.keyBy(array, 'dir'); + * // => { 'left': { 'dir': 'left', 'code': 97 }, 'right': { 'dir': 'right', 'code': 100 } } + */ + var keyBy = createAggregator(function(result$2, value, key) { + baseAssignValue(result$2, key, value); + }); + /** + * Creates an array of values by running each element in `collection` thru + * `iteratee`. The iteratee is invoked with three arguments: + * (value, index|key, collection). + * + * Many lodash methods are guarded to work as iteratees for methods like + * `_.every`, `_.filter`, `_.map`, `_.mapValues`, `_.reject`, and `_.some`. + * + * The guarded methods are: + * `ary`, `chunk`, `curry`, `curryRight`, `drop`, `dropRight`, `every`, + * `fill`, `invert`, `parseInt`, `random`, `range`, `rangeRight`, `repeat`, + * `sampleSize`, `slice`, `some`, `sortBy`, `split`, `take`, `takeRight`, + * `template`, `trim`, `trimEnd`, `trimStart`, and `words` + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} [iteratee=_.identity] The function invoked per iteration. + * @returns {Array} Returns the new mapped array. + * @example + * + * function square(n) { + * return n * n; + * } + * + * _.map([4, 8], square); + * // => [16, 64] + * + * _.map({ 'a': 4, 'b': 8 }, square); + * // => [16, 64] (iteration order is not guaranteed) + * + * var users = [ + * { 'user': 'barney' }, + * { 'user': 'fred' } + * ]; + * + * // The `_.property` iteratee shorthand. + * _.map(users, 'user'); + * // => ['barney', 'fred'] + */ + function map$1(collection, iteratee$2) { + var func = isArray$5(collection) ? arrayMap : baseMap; + return func(collection, getIteratee(iteratee$2, 3)); + } + /** + * This method is like `_.sortBy` except that it allows specifying the sort + * orders of the iteratees to sort by. If `orders` is unspecified, all values + * are sorted in ascending order. Otherwise, specify an order of "desc" for + * descending or "asc" for ascending sort order of corresponding values. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {Array[]|Function[]|Object[]|string[]} [iteratees=[_.identity]] + * The iteratees to sort by. + * @param {string[]} [orders] The sort orders of `iteratees`. + * @param- {Object} [guard] Enables use as an iteratee for methods like `_.reduce`. + * @returns {Array} Returns the new sorted array. + * @example + * + * var users = [ + * { 'user': 'fred', 'age': 48 }, + * { 'user': 'barney', 'age': 34 }, + * { 'user': 'fred', 'age': 40 }, + * { 'user': 'barney', 'age': 36 } + * ]; + * + * // Sort by `user` in ascending order and by `age` in descending order. + * _.orderBy(users, ['user', 'age'], ['asc', 'desc']); + * // => objects for [['barney', 36], ['barney', 34], ['fred', 48], ['fred', 40]] + */ + function orderBy(collection, iteratees, orders, guard) { + if (collection == null) return []; + if (!isArray$5(iteratees)) iteratees = iteratees == null ? [] : [iteratees]; + orders = guard ? undefined$1 : orders; + if (!isArray$5(orders)) orders = orders == null ? [] : [orders]; + return baseOrderBy(collection, iteratees, orders); + } + /** + * Creates an array of elements split into two groups, the first of which + * contains elements `predicate` returns truthy for, the second of which + * contains elements `predicate` returns falsey for. The predicate is + * invoked with one argument: (value). + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} [predicate=_.identity] The function invoked per iteration. + * @returns {Array} Returns the array of grouped elements. + * @example + * + * var users = [ + * { 'user': 'barney', 'age': 36, 'active': false }, + * { 'user': 'fred', 'age': 40, 'active': true }, + * { 'user': 'pebbles', 'age': 1, 'active': false } + * ]; + * + * _.partition(users, function(o) { return o.active; }); + * // => objects for [['fred'], ['barney', 'pebbles']] + * + * // The `_.matches` iteratee shorthand. + * _.partition(users, { 'age': 1, 'active': false }); + * // => objects for [['pebbles'], ['barney', 'fred']] + * + * // The `_.matchesProperty` iteratee shorthand. + * _.partition(users, ['active', false]); + * // => objects for [['barney', 'pebbles'], ['fred']] + * + * // The `_.property` iteratee shorthand. + * _.partition(users, 'active'); + * // => objects for [['fred'], ['barney', 'pebbles']] + */ + var partition$1 = createAggregator(function(result$2, value, key) { + result$2[key ? 0 : 1].push(value); + }, function() { + return [[], []]; + }); + /** + * Reduces `collection` to a value which is the accumulated result of running + * each element in `collection` thru `iteratee`, where each successive + * invocation is supplied the return value of the previous. If `accumulator` + * is not given, the first element of `collection` is used as the initial + * value. The iteratee is invoked with four arguments: + * (accumulator, value, index|key, collection). + * + * Many lodash methods are guarded to work as iteratees for methods like + * `_.reduce`, `_.reduceRight`, and `_.transform`. + * + * The guarded methods are: + * `assign`, `defaults`, `defaultsDeep`, `includes`, `merge`, `orderBy`, + * and `sortBy` + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} [iteratee=_.identity] The function invoked per iteration. + * @param {*} [accumulator] The initial value. + * @returns {*} Returns the accumulated value. + * @see _.reduceRight + * @example + * + * _.reduce([1, 2], function(sum, n) { + * return sum + n; + * }, 0); + * // => 3 + * + * _.reduce({ 'a': 1, 'b': 2, 'c': 1 }, function(result, value, key) { + * (result[value] || (result[value] = [])).push(key); + * return result; + * }, {}); + * // => { '1': ['a', 'c'], '2': ['b'] } (iteration order is not guaranteed) + */ + function reduce(collection, iteratee$2, accumulator) { + var func = isArray$5(collection) ? arrayReduce$1 : baseReduce, initAccum = arguments.length < 3; + return func(collection, getIteratee(iteratee$2, 4), accumulator, initAccum, baseEach); + } + /** + * This method is like `_.reduce` except that it iterates over elements of + * `collection` from right to left. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} [iteratee=_.identity] The function invoked per iteration. + * @param {*} [accumulator] The initial value. + * @returns {*} Returns the accumulated value. + * @see _.reduce + * @example + * + * var array = [[0, 1], [2, 3], [4, 5]]; + * + * _.reduceRight(array, function(flattened, other) { + * return flattened.concat(other); + * }, []); + * // => [4, 5, 2, 3, 0, 1] + */ + function reduceRight(collection, iteratee$2, accumulator) { + var func = isArray$5(collection) ? arrayReduceRight : baseReduce, initAccum = arguments.length < 3; + return func(collection, getIteratee(iteratee$2, 4), accumulator, initAccum, baseEachRight); + } + /** + * The opposite of `_.filter`; this method returns the elements of `collection` + * that `predicate` does **not** return truthy for. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} [predicate=_.identity] The function invoked per iteration. + * @returns {Array} Returns the new filtered array. + * @see _.filter + * @example + * + * var users = [ + * { 'user': 'barney', 'age': 36, 'active': false }, + * { 'user': 'fred', 'age': 40, 'active': true } + * ]; + * + * _.reject(users, function(o) { return !o.active; }); + * // => objects for ['fred'] + * + * // The `_.matches` iteratee shorthand. + * _.reject(users, { 'age': 40, 'active': true }); + * // => objects for ['barney'] + * + * // The `_.matchesProperty` iteratee shorthand. + * _.reject(users, ['active', false]); + * // => objects for ['fred'] + * + * // The `_.property` iteratee shorthand. + * _.reject(users, 'active'); + * // => objects for ['barney'] + */ + function reject$1(collection, predicate) { + var func = isArray$5(collection) ? arrayFilter : baseFilter; + return func(collection, negate$1(getIteratee(predicate, 3))); + } + /** + * Gets a random element from `collection`. + * + * @static + * @memberOf _ + * @since 2.0.0 + * @category Collection + * @param {Array|Object} collection The collection to sample. + * @returns {*} Returns the random element. + * @example + * + * _.sample([1, 2, 3, 4]); + * // => 2 + */ + function sample$1(collection) { + var func = isArray$5(collection) ? arraySample : baseSample; + return func(collection); + } + /** + * Gets `n` random elements at unique keys from `collection` up to the + * size of `collection`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Collection + * @param {Array|Object} collection The collection to sample. + * @param {number} [n=1] The number of elements to sample. + * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`. + * @returns {Array} Returns the random elements. + * @example + * + * _.sampleSize([1, 2, 3], 2); + * // => [3, 1] + * + * _.sampleSize([1, 2, 3], 4); + * // => [2, 3, 1] + */ + function sampleSize(collection, n$3, guard) { + if (guard ? isIterateeCall(collection, n$3, guard) : n$3 === undefined$1) n$3 = 1; + else n$3 = toInteger(n$3); + var func = isArray$5(collection) ? arraySampleSize : baseSampleSize; + return func(collection, n$3); + } + /** + * Creates an array of shuffled values, using a version of the + * [Fisher-Yates shuffle](https://en.wikipedia.org/wiki/Fisher-Yates_shuffle). + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Collection + * @param {Array|Object} collection The collection to shuffle. + * @returns {Array} Returns the new shuffled array. + * @example + * + * _.shuffle([1, 2, 3, 4]); + * // => [4, 1, 3, 2] + */ + function shuffle$1(collection) { + var func = isArray$5(collection) ? arrayShuffle : baseShuffle; + return func(collection); + } + /** + * Gets the size of `collection` by returning its length for array-like + * values or the number of own enumerable string keyed properties for objects. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Collection + * @param {Array|Object|string} collection The collection to inspect. + * @returns {number} Returns the collection size. + * @example + * + * _.size([1, 2, 3]); + * // => 3 + * + * _.size({ 'a': 1, 'b': 2 }); + * // => 2 + * + * _.size('pebbles'); + * // => 7 + */ + function size$1(collection) { + if (collection == null) return 0; + if (isArrayLike(collection)) return isString$5(collection) ? stringSize(collection) : collection.length; + var tag$3 = getTag(collection); + if (tag$3 == mapTag || tag$3 == setTag) return collection.size; + return baseKeys(collection).length; + } + /** + * Checks if `predicate` returns truthy for **any** element of `collection`. + * Iteration is stopped once `predicate` returns truthy. The predicate is + * invoked with three arguments: (value, index|key, collection). + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {Function} [predicate=_.identity] The function invoked per iteration. + * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`. + * @returns {boolean} Returns `true` if any element passes the predicate check, + * else `false`. + * @example + * + * _.some([null, 0, 'yes', false], Boolean); + * // => true + * + * var users = [ + * { 'user': 'barney', 'active': true }, + * { 'user': 'fred', 'active': false } + * ]; + * + * // The `_.matches` iteratee shorthand. + * _.some(users, { 'user': 'barney', 'active': false }); + * // => false + * + * // The `_.matchesProperty` iteratee shorthand. + * _.some(users, ['active', false]); + * // => true + * + * // The `_.property` iteratee shorthand. + * _.some(users, 'active'); + * // => true + */ + function some$1(collection, predicate, guard) { + var func = isArray$5(collection) ? arraySome : baseSome; + if (guard && isIterateeCall(collection, predicate, guard)) predicate = undefined$1; + return func(collection, getIteratee(predicate, 3)); + } + /** + * Creates an array of elements, sorted in ascending order by the results of + * running each element in a collection thru each iteratee. This method + * performs a stable sort, that is, it preserves the original sort order of + * equal elements. The iteratees are invoked with one argument: (value). + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Collection + * @param {Array|Object} collection The collection to iterate over. + * @param {...(Function|Function[])} [iteratees=[_.identity]] + * The iteratees to sort by. + * @returns {Array} Returns the new sorted array. + * @example + * + * var users = [ + * { 'user': 'fred', 'age': 48 }, + * { 'user': 'barney', 'age': 36 }, + * { 'user': 'fred', 'age': 30 }, + * { 'user': 'barney', 'age': 34 } + * ]; + * + * _.sortBy(users, [function(o) { return o.user; }]); + * // => objects for [['barney', 36], ['barney', 34], ['fred', 48], ['fred', 30]] + * + * _.sortBy(users, ['user', 'age']); + * // => objects for [['barney', 34], ['barney', 36], ['fred', 30], ['fred', 48]] + */ + var sortBy$1 = baseRest(function(collection, iteratees) { + if (collection == null) return []; + var length = iteratees.length; + if (length > 1 && isIterateeCall(collection, iteratees[0], iteratees[1])) iteratees = []; + else if (length > 2 && isIterateeCall(iteratees[0], iteratees[1], iteratees[2])) iteratees = [iteratees[0]]; + return baseOrderBy(collection, baseFlatten(iteratees, 1), []); + }); + /** + * Gets the timestamp of the number of milliseconds that have elapsed since + * the Unix epoch (1 January 1970 00:00:00 UTC). + * + * @static + * @memberOf _ + * @since 2.4.0 + * @category Date + * @returns {number} Returns the timestamp. + * @example + * + * _.defer(function(stamp) { + * console.log(_.now() - stamp); + * }, _.now()); + * // => Logs the number of milliseconds it took for the deferred invocation. + */ + var now = ctxNow || function() { + return root$6.Date.now(); + }; + /** + * The opposite of `_.before`; this method creates a function that invokes + * `func` once it's called `n` or more times. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Function + * @param {number} n The number of calls before `func` is invoked. + * @param {Function} func The function to restrict. + * @returns {Function} Returns the new restricted function. + * @example + * + * var saves = ['profile', 'settings']; + * + * var done = _.after(saves.length, function() { + * console.log('done saving!'); + * }); + * + * _.forEach(saves, function(type) { + * asyncSave({ 'type': type, 'complete': done }); + * }); + * // => Logs 'done saving!' after the two async saves have completed. + */ + function after$1(n$3, func) { + if (typeof func != "function") throw new TypeError$1(FUNC_ERROR_TEXT); + n$3 = toInteger(n$3); + return function() { + if (--n$3 < 1) return func.apply(this, arguments); + }; + } + /** + * Creates a function that invokes `func`, with up to `n` arguments, + * ignoring any additional arguments. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Function + * @param {Function} func The function to cap arguments for. + * @param {number} [n=func.length] The arity cap. + * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`. + * @returns {Function} Returns the new capped function. + * @example + * + * _.map(['6', '8', '10'], _.ary(parseInt, 1)); + * // => [6, 8, 10] + */ + function ary(func, n$3, guard) { + n$3 = guard ? undefined$1 : n$3; + n$3 = func && n$3 == null ? func.length : n$3; + return createWrap(func, WRAP_ARY_FLAG, undefined$1, undefined$1, undefined$1, undefined$1, n$3); + } + /** + * 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$1(n$3, func) { + var result$2; + if (typeof func != "function") throw new TypeError$1(FUNC_ERROR_TEXT); + n$3 = toInteger(n$3); + return function() { + if (--n$3 > 0) result$2 = func.apply(this, arguments); + if (n$3 <= 1) func = undefined$1; + return result$2; + }; + } + /** + * Creates a function that invokes `func` with the `this` binding of `thisArg` + * and `partials` prepended to the arguments it receives. + * + * The `_.bind.placeholder` value, which defaults to `_` in monolithic builds, + * may be used as a placeholder for partially applied arguments. + * + * **Note:** Unlike native `Function#bind`, this method doesn't set the "length" + * property of bound functions. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Function + * @param {Function} func The function to bind. + * @param {*} thisArg The `this` binding of `func`. + * @param {...*} [partials] The arguments to be partially applied. + * @returns {Function} Returns the new bound function. + * @example + * + * function greet(greeting, punctuation) { + * return greeting + ' ' + this.user + punctuation; + * } + * + * var object = { 'user': 'fred' }; + * + * var bound = _.bind(greet, object, 'hi'); + * bound('!'); + * // => 'hi fred!' + * + * // Bound with placeholders. + * var bound = _.bind(greet, object, _, '!'); + * bound('hi'); + * // => 'hi fred!' + */ + var bind$1 = baseRest(function(func, thisArg, partials) { + var bitmask = WRAP_BIND_FLAG; + if (partials.length) { + var holders = replaceHolders(partials, getHolder(bind$1)); + bitmask |= WRAP_PARTIAL_FLAG; + } + return createWrap(func, bitmask, thisArg, partials, holders); + }); + /** + * Creates a function that invokes the method at `object[key]` with `partials` + * prepended to the arguments it receives. + * + * This method differs from `_.bind` by allowing bound functions to reference + * methods that may be redefined or don't yet exist. See + * [Peter Michaux's article](http://peter.michaux.ca/articles/lazy-function-definition-pattern) + * for more details. + * + * The `_.bindKey.placeholder` value, which defaults to `_` in monolithic + * builds, may be used as a placeholder for partially applied arguments. + * + * @static + * @memberOf _ + * @since 0.10.0 + * @category Function + * @param {Object} object The object to invoke the method on. + * @param {string} key The key of the method. + * @param {...*} [partials] The arguments to be partially applied. + * @returns {Function} Returns the new bound function. + * @example + * + * var object = { + * 'user': 'fred', + * 'greet': function(greeting, punctuation) { + * return greeting + ' ' + this.user + punctuation; + * } + * }; + * + * var bound = _.bindKey(object, 'greet', 'hi'); + * bound('!'); + * // => 'hi fred!' + * + * object.greet = function(greeting, punctuation) { + * return greeting + 'ya ' + this.user + punctuation; + * }; + * + * bound('!'); + * // => 'hiya fred!' + * + * // Bound with placeholders. + * var bound = _.bindKey(object, 'greet', _, '!'); + * bound('hi'); + * // => 'hiya fred!' + */ + var bindKey = baseRest(function(object$3, key, partials) { + var bitmask = WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG; + if (partials.length) { + var holders = replaceHolders(partials, getHolder(bindKey)); + bitmask |= WRAP_PARTIAL_FLAG; + } + return createWrap(key, bitmask, object$3, partials, holders); + }); + /** + * Creates a function that accepts arguments of `func` and either invokes + * `func` returning its result, if at least `arity` number of arguments have + * been provided, or returns a function that accepts the remaining `func` + * arguments, and so on. The arity of `func` may be specified if `func.length` + * is not sufficient. + * + * The `_.curry.placeholder` value, which defaults to `_` in monolithic builds, + * may be used as a placeholder for provided arguments. + * + * **Note:** This method doesn't set the "length" property of curried functions. + * + * @static + * @memberOf _ + * @since 2.0.0 + * @category Function + * @param {Function} func The function to curry. + * @param {number} [arity=func.length] The arity of `func`. + * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`. + * @returns {Function} Returns the new curried function. + * @example + * + * var abc = function(a, b, c) { + * return [a, b, c]; + * }; + * + * var curried = _.curry(abc); + * + * curried(1)(2)(3); + * // => [1, 2, 3] + * + * curried(1, 2)(3); + * // => [1, 2, 3] + * + * curried(1, 2, 3); + * // => [1, 2, 3] + * + * // Curried with placeholders. + * curried(1)(_, 3)(2); + * // => [1, 2, 3] + */ + function curry(func, arity, guard) { + arity = guard ? undefined$1 : arity; + var result$2 = createWrap(func, WRAP_CURRY_FLAG, undefined$1, undefined$1, undefined$1, undefined$1, undefined$1, arity); + result$2.placeholder = curry.placeholder; + return result$2; + } + /** + * This method is like `_.curry` except that arguments are applied to `func` + * in the manner of `_.partialRight` instead of `_.partial`. + * + * The `_.curryRight.placeholder` value, which defaults to `_` in monolithic + * builds, may be used as a placeholder for provided arguments. + * + * **Note:** This method doesn't set the "length" property of curried functions. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Function + * @param {Function} func The function to curry. + * @param {number} [arity=func.length] The arity of `func`. + * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`. + * @returns {Function} Returns the new curried function. + * @example + * + * var abc = function(a, b, c) { + * return [a, b, c]; + * }; + * + * var curried = _.curryRight(abc); + * + * curried(3)(2)(1); + * // => [1, 2, 3] + * + * curried(2, 3)(1); + * // => [1, 2, 3] + * + * curried(1, 2, 3); + * // => [1, 2, 3] + * + * // Curried with placeholders. + * curried(3)(1, _)(2); + * // => [1, 2, 3] + */ + function curryRight(func, arity, guard) { + arity = guard ? undefined$1 : arity; + var result$2 = createWrap(func, WRAP_CURRY_RIGHT_FLAG, undefined$1, undefined$1, undefined$1, undefined$1, undefined$1, arity); + result$2.placeholder = curryRight.placeholder; + return result$2; + } + /** + * Creates a debounced function that delays invoking `func` until after `wait` + * milliseconds have elapsed since the last time the debounced function was + * invoked. The debounced function comes with a `cancel` method to cancel + * delayed `func` invocations and a `flush` method to immediately invoke them. + * Provide `options` to indicate whether `func` should be invoked on the + * leading and/or trailing edge of the `wait` timeout. The `func` is invoked + * with the last arguments provided to the debounced function. Subsequent + * calls to the debounced function return the result of the last `func` + * invocation. + * + * **Note:** If `leading` and `trailing` options are `true`, `func` is + * invoked on the trailing edge of the timeout only if the debounced function + * is invoked more than once during the `wait` timeout. + * + * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred + * until to the next tick, similar to `setTimeout` with a timeout of `0`. + * + * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/) + * for details over the differences between `_.debounce` and `_.throttle`. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Function + * @param {Function} func The function to debounce. + * @param {number} [wait=0] The number of milliseconds to delay. + * @param {Object} [options={}] The options object. + * @param {boolean} [options.leading=false] + * Specify invoking on the leading edge of the timeout. + * @param {number} [options.maxWait] + * The maximum time `func` is allowed to be delayed before it's invoked. + * @param {boolean} [options.trailing=true] + * Specify invoking on the trailing edge of the timeout. + * @returns {Function} Returns the new debounced function. + * @example + * + * // Avoid costly calculations while the window size is in flux. + * jQuery(window).on('resize', _.debounce(calculateLayout, 150)); + * + * // Invoke `sendMail` when clicked, debouncing subsequent calls. + * jQuery(element).on('click', _.debounce(sendMail, 300, { + * 'leading': true, + * 'trailing': false + * })); + * + * // Ensure `batchLog` is invoked once after 1 second of debounced calls. + * var debounced = _.debounce(batchLog, 250, { 'maxWait': 1000 }); + * var source = new EventSource('/stream'); + * jQuery(source).on('message', debounced); + * + * // Cancel the trailing debounced invocation. + * jQuery(window).on('popstate', debounced.cancel); + */ + function debounce$1(func, wait, options) { + var lastArgs, lastThis, maxWait, result$2, timerId, lastCallTime, lastInvokeTime = 0, leading = false, maxing = false, trailing = true; + if (typeof func != "function") throw new TypeError$1(FUNC_ERROR_TEXT); + wait = toNumber$1(wait) || 0; + if (isObject$5(options)) { + leading = !!options.leading; + maxing = "maxWait" in options; + maxWait = maxing ? nativeMax(toNumber$1(options.maxWait) || 0, wait) : maxWait; + trailing = "trailing" in options ? !!options.trailing : trailing; + } + function invokeFunc(time) { + var args = lastArgs, thisArg = lastThis; + lastArgs = lastThis = undefined$1; + lastInvokeTime = time; + result$2 = func.apply(thisArg, args); + return result$2; + } + function leadingEdge(time) { + lastInvokeTime = time; + timerId = setTimeout$1(timerExpired, wait); + return leading ? invokeFunc(time) : result$2; + } + function remainingWait(time) { + var timeSinceLastCall = time - lastCallTime, timeSinceLastInvoke = time - lastInvokeTime, timeWaiting = wait - timeSinceLastCall; + return maxing ? nativeMin(timeWaiting, maxWait - timeSinceLastInvoke) : timeWaiting; + } + function shouldInvoke(time) { + var timeSinceLastCall = time - lastCallTime, timeSinceLastInvoke = time - lastInvokeTime; + return lastCallTime === undefined$1 || timeSinceLastCall >= wait || timeSinceLastCall < 0 || maxing && timeSinceLastInvoke >= maxWait; + } + function timerExpired() { + var time = now(); + if (shouldInvoke(time)) return trailingEdge(time); + timerId = setTimeout$1(timerExpired, remainingWait(time)); + } + function trailingEdge(time) { + timerId = undefined$1; + if (trailing && lastArgs) return invokeFunc(time); + lastArgs = lastThis = undefined$1; + return result$2; + } + function cancel() { + if (timerId !== undefined$1) clearTimeout$1(timerId); + lastInvokeTime = 0; + lastArgs = lastCallTime = lastThis = timerId = undefined$1; + } + function flush() { + return timerId === undefined$1 ? result$2 : trailingEdge(now()); + } + function debounced() { + var time = now(), isInvoking = shouldInvoke(time); + lastArgs = arguments; + lastThis = this; + lastCallTime = time; + if (isInvoking) { + if (timerId === undefined$1) return leadingEdge(lastCallTime); + if (maxing) { + clearTimeout$1(timerId); + timerId = setTimeout$1(timerExpired, wait); + return invokeFunc(lastCallTime); + } + } + if (timerId === undefined$1) timerId = setTimeout$1(timerExpired, wait); + return result$2; + } + debounced.cancel = cancel; + debounced.flush = flush; + return debounced; + } + /** + * Defers invoking the `func` until the current call stack has cleared. Any + * additional arguments are provided to `func` when it's invoked. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Function + * @param {Function} func The function to defer. + * @param {...*} [args] The arguments to invoke `func` with. + * @returns {number} Returns the timer id. + * @example + * + * _.defer(function(text) { + * console.log(text); + * }, 'deferred'); + * // => Logs 'deferred' after one millisecond. + */ + var defer = baseRest(function(func, args) { + return baseDelay(func, 1, args); + }); + /** + * Invokes `func` after `wait` milliseconds. Any additional arguments are + * provided to `func` when it's invoked. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Function + * @param {Function} func The function to delay. + * @param {number} wait The number of milliseconds to delay invocation. + * @param {...*} [args] The arguments to invoke `func` with. + * @returns {number} Returns the timer id. + * @example + * + * _.delay(function(text) { + * console.log(text); + * }, 1000, 'later'); + * // => Logs 'later' after one second. + */ + var delay = baseRest(function(func, wait, args) { + return baseDelay(func, toNumber$1(wait) || 0, args); + }); + /** + * Creates a function that invokes `func` with arguments reversed. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Function + * @param {Function} func The function to flip arguments for. + * @returns {Function} Returns the new flipped function. + * @example + * + * var flipped = _.flip(function() { + * return _.toArray(arguments); + * }); + * + * flipped('a', 'b', 'c', 'd'); + * // => ['d', 'c', 'b', 'a'] + */ + function flip(func) { + return createWrap(func, WRAP_FLIP_FLAG); + } + /** + * Creates a function that memoizes the result of `func`. If `resolver` is + * provided, it determines the cache key for storing the result based on the + * arguments provided to the memoized function. By default, the first argument + * provided to the memoized function is used as the map cache key. The `func` + * is invoked with the `this` binding of the memoized function. + * + * **Note:** The cache is exposed as the `cache` property on the memoized + * function. Its creation may be customized by replacing the `_.memoize.Cache` + * constructor with one whose instances implement the + * [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object) + * method interface of `clear`, `delete`, `get`, `has`, and `set`. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Function + * @param {Function} func The function to have its output memoized. + * @param {Function} [resolver] The function to resolve the cache key. + * @returns {Function} Returns the new memoized function. + * @example + * + * var object = { 'a': 1, 'b': 2 }; + * var other = { 'c': 3, 'd': 4 }; + * + * var values = _.memoize(_.values); + * values(object); + * // => [1, 2] + * + * values(other); + * // => [3, 4] + * + * object.a = 2; + * values(object); + * // => [1, 2] + * + * // Modify the result cache. + * values.cache.set(object, ['a', 'b']); + * values(object); + * // => ['a', 'b'] + * + * // Replace `_.memoize.Cache`. + * _.memoize.Cache = WeakMap; + */ + function memoize$1(func, resolver) { + if (typeof func != "function" || resolver != null && typeof resolver != "function") throw new TypeError$1(FUNC_ERROR_TEXT); + var memoized = function() { + var args = arguments, key = resolver ? resolver.apply(this, args) : args[0], cache$3 = memoized.cache; + if (cache$3.has(key)) return cache$3.get(key); + var result$2 = func.apply(this, args); + memoized.cache = cache$3.set(key, result$2) || cache$3; + return result$2; + }; + memoized.cache = new (memoize$1.Cache || MapCache)(); + return memoized; + } + memoize$1.Cache = MapCache; + /** + * Creates a function that negates the result of the predicate `func`. The + * `func` predicate is invoked with the `this` binding and arguments of the + * created function. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Function + * @param {Function} predicate The predicate to negate. + * @returns {Function} Returns the new negated function. + * @example + * + * function isEven(n) { + * return n % 2 == 0; + * } + * + * _.filter([1, 2, 3, 4, 5, 6], _.negate(isEven)); + * // => [1, 3, 5] + */ + function negate$1(predicate) { + if (typeof predicate != "function") throw new TypeError$1(FUNC_ERROR_TEXT); + return function() { + var args = arguments; + switch (args.length) { + case 0: return !predicate.call(this); + case 1: return !predicate.call(this, args[0]); + case 2: return !predicate.call(this, args[0], args[1]); + case 3: return !predicate.call(this, args[0], args[1], args[2]); + } + return !predicate.apply(this, args); + }; + } + /** + * 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$3(func) { + return before$1(2, func); + } + /** + * Creates a function that invokes `func` with its arguments transformed. + * + * @static + * @since 4.0.0 + * @memberOf _ + * @category Function + * @param {Function} func The function to wrap. + * @param {...(Function|Function[])} [transforms=[_.identity]] + * The argument transforms. + * @returns {Function} Returns the new function. + * @example + * + * function doubled(n) { + * return n * 2; + * } + * + * function square(n) { + * return n * n; + * } + * + * var func = _.overArgs(function(x, y) { + * return [x, y]; + * }, [square, doubled]); + * + * func(9, 3); + * // => [81, 6] + * + * func(10, 5); + * // => [100, 10] + */ + var overArgs = castRest(function(func, transforms) { + transforms = transforms.length == 1 && isArray$5(transforms[0]) ? arrayMap(transforms[0], baseUnary(getIteratee())) : arrayMap(baseFlatten(transforms, 1), baseUnary(getIteratee())); + var funcsLength = transforms.length; + return baseRest(function(args) { + var index$1 = -1, length = nativeMin(args.length, funcsLength); + while (++index$1 < length) args[index$1] = transforms[index$1].call(this, args[index$1]); + return apply(func, this, args); + }); + }); + /** + * Creates a function that invokes `func` with `partials` prepended to the + * arguments it receives. This method is like `_.bind` except it does **not** + * alter the `this` binding. + * + * The `_.partial.placeholder` value, which defaults to `_` in monolithic + * builds, may be used as a placeholder for partially applied arguments. + * + * **Note:** This method doesn't set the "length" property of partially + * applied functions. + * + * @static + * @memberOf _ + * @since 0.2.0 + * @category Function + * @param {Function} func The function to partially apply arguments to. + * @param {...*} [partials] The arguments to be partially applied. + * @returns {Function} Returns the new partially applied function. + * @example + * + * function greet(greeting, name) { + * return greeting + ' ' + name; + * } + * + * var sayHelloTo = _.partial(greet, 'hello'); + * sayHelloTo('fred'); + * // => 'hello fred' + * + * // Partially applied with placeholders. + * var greetFred = _.partial(greet, _, 'fred'); + * greetFred('hi'); + * // => 'hi fred' + */ + var partial$1 = baseRest(function(func, partials) { + var holders = replaceHolders(partials, getHolder(partial$1)); + return createWrap(func, WRAP_PARTIAL_FLAG, undefined$1, partials, holders); + }); + /** + * This method is like `_.partial` except that partially applied arguments + * are appended to the arguments it receives. + * + * The `_.partialRight.placeholder` value, which defaults to `_` in monolithic + * builds, may be used as a placeholder for partially applied arguments. + * + * **Note:** This method doesn't set the "length" property of partially + * applied functions. + * + * @static + * @memberOf _ + * @since 1.0.0 + * @category Function + * @param {Function} func The function to partially apply arguments to. + * @param {...*} [partials] The arguments to be partially applied. + * @returns {Function} Returns the new partially applied function. + * @example + * + * function greet(greeting, name) { + * return greeting + ' ' + name; + * } + * + * var greetFred = _.partialRight(greet, 'fred'); + * greetFred('hi'); + * // => 'hi fred' + * + * // Partially applied with placeholders. + * var sayHelloTo = _.partialRight(greet, 'hello', _); + * sayHelloTo('fred'); + * // => 'hello fred' + */ + var partialRight = baseRest(function(func, partials) { + var holders = replaceHolders(partials, getHolder(partialRight)); + return createWrap(func, WRAP_PARTIAL_RIGHT_FLAG, undefined$1, partials, holders); + }); + /** + * Creates a function that invokes `func` with arguments arranged according + * to the specified `indexes` where the argument value at the first index is + * provided as the first argument, the argument value at the second index is + * provided as the second argument, and so on. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Function + * @param {Function} func The function to rearrange arguments for. + * @param {...(number|number[])} indexes The arranged argument indexes. + * @returns {Function} Returns the new function. + * @example + * + * var rearged = _.rearg(function(a, b, c) { + * return [a, b, c]; + * }, [2, 0, 1]); + * + * rearged('b', 'c', 'a') + * // => ['a', 'b', 'c'] + */ + var rearg = flatRest(function(func, indexes) { + return createWrap(func, WRAP_REARG_FLAG, undefined$1, undefined$1, undefined$1, indexes); + }); + /** + * Creates a function that invokes `func` with the `this` binding of the + * created function and arguments from `start` and beyond provided as + * an array. + * + * **Note:** This method is based on the + * [rest parameter](https://mdn.io/rest_parameters). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Function + * @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. + * @example + * + * var say = _.rest(function(what, names) { + * return what + ' ' + _.initial(names).join(', ') + + * (_.size(names) > 1 ? ', & ' : '') + _.last(names); + * }); + * + * say('hello', 'fred', 'barney', 'pebbles'); + * // => 'hello fred, barney, & pebbles' + */ + function rest$1(func, start) { + if (typeof func != "function") throw new TypeError$1(FUNC_ERROR_TEXT); + start = start === undefined$1 ? start : toInteger(start); + return baseRest(func, start); + } + /** + * Creates a function that invokes `func` with the `this` binding of the + * create function and an array of arguments much like + * [`Function#apply`](http://www.ecma-international.org/ecma-262/7.0/#sec-function.prototype.apply). + * + * **Note:** This method is based on the + * [spread operator](https://mdn.io/spread_operator). + * + * @static + * @memberOf _ + * @since 3.2.0 + * @category Function + * @param {Function} func The function to spread arguments over. + * @param {number} [start=0] The start position of the spread. + * @returns {Function} Returns the new function. + * @example + * + * var say = _.spread(function(who, what) { + * return who + ' says ' + what; + * }); + * + * say(['fred', 'hello']); + * // => 'fred says hello' + * + * var numbers = Promise.all([ + * Promise.resolve(40), + * Promise.resolve(36) + * ]); + * + * numbers.then(_.spread(function(x, y) { + * return x + y; + * })); + * // => a Promise of 76 + */ + function spread(func, start) { + if (typeof func != "function") throw new TypeError$1(FUNC_ERROR_TEXT); + start = start == null ? 0 : nativeMax(toInteger(start), 0); + return baseRest(function(args) { + var array = args[start], otherArgs = castSlice$1(args, 0, start); + if (array) arrayPush(otherArgs, array); + return apply(func, this, otherArgs); + }); + } + /** + * Creates a throttled function that only invokes `func` at most once per + * every `wait` milliseconds. The throttled function comes with a `cancel` + * method to cancel delayed `func` invocations and a `flush` method to + * immediately invoke them. Provide `options` to indicate whether `func` + * should be invoked on the leading and/or trailing edge of the `wait` + * timeout. The `func` is invoked with the last arguments provided to the + * throttled function. Subsequent calls to the throttled function return the + * result of the last `func` invocation. + * + * **Note:** If `leading` and `trailing` options are `true`, `func` is + * invoked on the trailing edge of the timeout only if the throttled function + * is invoked more than once during the `wait` timeout. + * + * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred + * until to the next tick, similar to `setTimeout` with a timeout of `0`. + * + * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/) + * for details over the differences between `_.throttle` and `_.debounce`. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Function + * @param {Function} func The function to throttle. + * @param {number} [wait=0] The number of milliseconds to throttle invocations to. + * @param {Object} [options={}] The options object. + * @param {boolean} [options.leading=true] + * Specify invoking on the leading edge of the timeout. + * @param {boolean} [options.trailing=true] + * Specify invoking on the trailing edge of the timeout. + * @returns {Function} Returns the new throttled function. + * @example + * + * // Avoid excessively updating the position while scrolling. + * jQuery(window).on('scroll', _.throttle(updatePosition, 100)); + * + * // Invoke `renewToken` when the click event is fired, but not more than once every 5 minutes. + * var throttled = _.throttle(renewToken, 300000, { 'trailing': false }); + * jQuery(element).on('click', throttled); + * + * // Cancel the trailing throttled invocation. + * jQuery(window).on('popstate', throttled.cancel); + */ + function throttle$1(func, wait, options) { + var leading = true, trailing = true; + if (typeof func != "function") throw new TypeError$1(FUNC_ERROR_TEXT); + if (isObject$5(options)) { + leading = "leading" in options ? !!options.leading : leading; + trailing = "trailing" in options ? !!options.trailing : trailing; + } + return debounce$1(func, wait, { + "leading": leading, + "maxWait": wait, + "trailing": trailing + }); + } + /** + * Creates a function that accepts up to one argument, ignoring any + * additional arguments. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Function + * @param {Function} func The function to cap arguments for. + * @returns {Function} Returns the new capped function. + * @example + * + * _.map(['6', '8', '10'], _.unary(parseInt)); + * // => [6, 8, 10] + */ + function unary(func) { + return ary(func, 1); + } + /** + * Creates a function that provides `value` to `wrapper` as its first + * argument. Any additional arguments provided to the function are appended + * to those provided to the `wrapper`. The wrapper is invoked with the `this` + * binding of the created function. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Function + * @param {*} value The value to wrap. + * @param {Function} [wrapper=identity] The wrapper function. + * @returns {Function} Returns the new function. + * @example + * + * var p = _.wrap(_.escape, function(func, text) { + * return '

' + func(text) + '

'; + * }); + * + * p('fred, barney, & pebbles'); + * // => '

fred, barney, & pebbles

' + */ + function wrap$1(value, wrapper) { + return partial$1(castFunction(wrapper), value); + } + /** + * Casts `value` as an array if it's not one. + * + * @static + * @memberOf _ + * @since 4.4.0 + * @category Lang + * @param {*} value The value to inspect. + * @returns {Array} Returns the cast array. + * @example + * + * _.castArray(1); + * // => [1] + * + * _.castArray({ 'a': 1 }); + * // => [{ 'a': 1 }] + * + * _.castArray('abc'); + * // => ['abc'] + * + * _.castArray(null); + * // => [null] + * + * _.castArray(undefined); + * // => [undefined] + * + * _.castArray(); + * // => [] + * + * var array = [1, 2, 3]; + * console.log(_.castArray(array) === array); + * // => true + */ + function castArray() { + if (!arguments.length) return []; + var value = arguments[0]; + return isArray$5(value) ? value : [value]; + } + /** + * Creates a shallow clone of `value`. + * + * **Note:** This method is loosely based on the + * [structured clone algorithm](https://mdn.io/Structured_clone_algorithm) + * and supports cloning arrays, array buffers, booleans, date objects, maps, + * numbers, `Object` objects, regexes, sets, strings, symbols, and typed + * arrays. The own enumerable properties of `arguments` objects are cloned + * as plain objects. An empty object is returned for uncloneable values such + * as error objects, functions, DOM nodes, and WeakMaps. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to clone. + * @returns {*} Returns the cloned value. + * @see _.cloneDeep + * @example + * + * var objects = [{ 'a': 1 }, { 'b': 2 }]; + * + * var shallow = _.clone(objects); + * console.log(shallow[0] === objects[0]); + * // => true + */ + function clone$5(value) { + return baseClone(value, CLONE_SYMBOLS_FLAG); + } + /** + * This method is like `_.clone` except that it accepts `customizer` which + * is invoked to produce the cloned value. If `customizer` returns `undefined`, + * cloning is handled by the method instead. The `customizer` is invoked with + * up to four arguments; (value [, index|key, object, stack]). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to clone. + * @param {Function} [customizer] The function to customize cloning. + * @returns {*} Returns the cloned value. + * @see _.cloneDeepWith + * @example + * + * function customizer(value) { + * if (_.isElement(value)) { + * return value.cloneNode(false); + * } + * } + * + * var el = _.cloneWith(document.body, customizer); + * + * console.log(el === document.body); + * // => false + * console.log(el.nodeName); + * // => 'BODY' + * console.log(el.childNodes.length); + * // => 0 + */ + function cloneWith(value, customizer) { + customizer = typeof customizer == "function" ? customizer : undefined$1; + return baseClone(value, CLONE_SYMBOLS_FLAG, customizer); + } + /** + * This method is like `_.clone` except that it recursively clones `value`. + * + * @static + * @memberOf _ + * @since 1.0.0 + * @category Lang + * @param {*} value The value to recursively clone. + * @returns {*} Returns the deep cloned value. + * @see _.clone + * @example + * + * var objects = [{ 'a': 1 }, { 'b': 2 }]; + * + * var deep = _.cloneDeep(objects); + * console.log(deep[0] === objects[0]); + * // => false + */ + function cloneDeep$1(value) { + return baseClone(value, CLONE_DEEP_FLAG | CLONE_SYMBOLS_FLAG); + } + /** + * This method is like `_.cloneWith` except that it recursively clones `value`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to recursively clone. + * @param {Function} [customizer] The function to customize cloning. + * @returns {*} Returns the deep cloned value. + * @see _.cloneWith + * @example + * + * function customizer(value) { + * if (_.isElement(value)) { + * return value.cloneNode(true); + * } + * } + * + * var el = _.cloneDeepWith(document.body, customizer); + * + * console.log(el === document.body); + * // => false + * console.log(el.nodeName); + * // => 'BODY' + * console.log(el.childNodes.length); + * // => 20 + */ + function cloneDeepWith(value, customizer) { + customizer = typeof customizer == "function" ? customizer : undefined$1; + return baseClone(value, CLONE_DEEP_FLAG | CLONE_SYMBOLS_FLAG, customizer); + } + /** + * Checks if `object` conforms to `source` by invoking the predicate + * properties of `source` with the corresponding property values of `object`. + * + * **Note:** This method is equivalent to `_.conforms` when `source` is + * partially applied. + * + * @static + * @memberOf _ + * @since 4.14.0 + * @category Lang + * @param {Object} object The object to inspect. + * @param {Object} source The object of property predicates to conform to. + * @returns {boolean} Returns `true` if `object` conforms, else `false`. + * @example + * + * var object = { 'a': 1, 'b': 2 }; + * + * _.conformsTo(object, { 'b': function(n) { return n > 1; } }); + * // => true + * + * _.conformsTo(object, { 'b': function(n) { return n > 2; } }); + * // => false + */ + function conformsTo(object$3, source) { + return source == null || baseConformsTo(object$3, source, keys$2(source)); + } + /** + * 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$1(value, other) { + return value === other || value !== value && other !== other; + } + /** + * Checks if `value` is greater than `other`. + * + * @static + * @memberOf _ + * @since 3.9.0 + * @category Lang + * @param {*} value The value to compare. + * @param {*} other The other value to compare. + * @returns {boolean} Returns `true` if `value` is greater than `other`, + * else `false`. + * @see _.lt + * @example + * + * _.gt(3, 1); + * // => true + * + * _.gt(3, 3); + * // => false + * + * _.gt(1, 3); + * // => false + */ + var gt = createRelationalOperation(baseGt); + /** + * Checks if `value` is greater than or equal to `other`. + * + * @static + * @memberOf _ + * @since 3.9.0 + * @category Lang + * @param {*} value The value to compare. + * @param {*} other The other value to compare. + * @returns {boolean} Returns `true` if `value` is greater than or equal to + * `other`, else `false`. + * @see _.lte + * @example + * + * _.gte(3, 1); + * // => true + * + * _.gte(3, 3); + * // => true + * + * _.gte(1, 3); + * // => false + */ + var gte$1 = createRelationalOperation(function(value, other) { + return value >= other; + }); + /** + * 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$1 = baseIsArguments(function() { + return arguments; + }()) ? baseIsArguments : function(value) { + return isObjectLike$1(value) && hasOwnProperty$6.call(value, "callee") && !propertyIsEnumerable.call(value, "callee"); + }; + /** + * 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$5 = Array$1.isArray; + /** + * Checks if `value` is classified as an `ArrayBuffer` object. + * + * @static + * @memberOf _ + * @since 4.3.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an array buffer, else `false`. + * @example + * + * _.isArrayBuffer(new ArrayBuffer(2)); + * // => true + * + * _.isArrayBuffer(new Array(2)); + * // => false + */ + var isArrayBuffer = nodeIsArrayBuffer ? baseUnary(nodeIsArrayBuffer) : baseIsArrayBuffer; + /** + * 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$10(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$1(value) && isArrayLike(value); + } + /** + * Checks if `value` is classified as a boolean primitive or object. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a boolean, else `false`. + * @example + * + * _.isBoolean(false); + * // => true + * + * _.isBoolean(null); + * // => false + */ + function isBoolean$1(value) { + return value === true || value === false || isObjectLike$1(value) && baseGetTag(value) == boolTag; + } + /** + * 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$1 = nativeIsBuffer || stubFalse; + /** + * Checks if `value` is classified as a `Date` object. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a date object, else `false`. + * @example + * + * _.isDate(new Date); + * // => true + * + * _.isDate('Mon April 23 2012'); + * // => false + */ + var isDate$1 = nodeIsDate ? baseUnary(nodeIsDate) : baseIsDate; + /** + * Checks if `value` is likely a DOM element. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a DOM element, else `false`. + * @example + * + * _.isElement(document.body); + * // => true + * + * _.isElement(''); + * // => false + */ + function isElement$1(value) { + return isObjectLike$1(value) && value.nodeType === 1 && !isPlainObject$2(value); + } + /** + * Checks if `value` is an empty object, collection, map, or set. + * + * Objects are considered empty if they have no own enumerable string keyed + * properties. + * + * Array-like values such as `arguments` objects, arrays, buffers, strings, or + * jQuery-like collections are considered empty if they have a `length` of `0`. + * Similarly, maps and sets are considered empty if they have a `size` of `0`. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is empty, else `false`. + * @example + * + * _.isEmpty(null); + * // => true + * + * _.isEmpty(true); + * // => true + * + * _.isEmpty(1); + * // => true + * + * _.isEmpty([1, 2, 3]); + * // => false + * + * _.isEmpty({ 'a': 1 }); + * // => false + */ + function isEmpty$2(value) { + if (value == null) return true; + if (isArrayLike(value) && (isArray$5(value) || typeof value == "string" || typeof value.splice == "function" || isBuffer$1(value) || isTypedArray$1(value) || isArguments$1(value))) return !value.length; + var tag$3 = getTag(value); + if (tag$3 == mapTag || tag$3 == setTag) return !value.size; + if (isPrototype(value)) return !baseKeys(value).length; + for (var key in value) if (hasOwnProperty$6.call(value, key)) return false; + return true; + } + /** + * Performs a deep comparison between two values to determine if they are + * equivalent. + * + * **Note:** This method supports comparing arrays, array buffers, booleans, + * date objects, error objects, maps, numbers, `Object` objects, regexes, + * sets, strings, symbols, and typed arrays. `Object` objects are compared + * by their own, not inherited, enumerable properties. Functions and DOM + * nodes are compared by strict equality, i.e. `===`. + * + * @static + * @memberOf _ + * @since 0.1.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 }; + * + * _.isEqual(object, other); + * // => true + * + * object === other; + * // => false + */ + function isEqual$1(value, other) { + return baseIsEqual(value, other); + } + /** + * This method is like `_.isEqual` except that it accepts `customizer` which + * is invoked to compare values. If `customizer` returns `undefined`, comparisons + * are handled by the method instead. The `customizer` is invoked with up to + * six arguments: (objValue, othValue [, index|key, object, other, stack]). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to compare. + * @param {*} other The other value to compare. + * @param {Function} [customizer] The function to customize comparisons. + * @returns {boolean} Returns `true` if the values are equivalent, else `false`. + * @example + * + * function isGreeting(value) { + * return /^h(?:i|ello)$/.test(value); + * } + * + * function customizer(objValue, othValue) { + * if (isGreeting(objValue) && isGreeting(othValue)) { + * return true; + * } + * } + * + * var array = ['hello', 'goodbye']; + * var other = ['hi', 'goodbye']; + * + * _.isEqualWith(array, other, customizer); + * // => true + */ + function isEqualWith(value, other, customizer) { + customizer = typeof customizer == "function" ? customizer : undefined$1; + var result$2 = customizer ? customizer(value, other) : undefined$1; + return result$2 === undefined$1 ? baseIsEqual(value, other, undefined$1, customizer) : !!result$2; + } + /** + * Checks if `value` is an `Error`, `EvalError`, `RangeError`, `ReferenceError`, + * `SyntaxError`, `TypeError`, or `URIError` object. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an error object, else `false`. + * @example + * + * _.isError(new Error); + * // => true + * + * _.isError(Error); + * // => false + */ + function isError(value) { + if (!isObjectLike$1(value)) return false; + var tag$3 = baseGetTag(value); + return tag$3 == errorTag || tag$3 == domExcTag || typeof value.message == "string" && typeof value.name == "string" && !isPlainObject$2(value); + } + /** + * Checks if `value` is a finite primitive number. + * + * **Note:** This method is based on + * [`Number.isFinite`](https://mdn.io/Number/isFinite). + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a finite number, else `false`. + * @example + * + * _.isFinite(3); + * // => true + * + * _.isFinite(Number.MIN_VALUE); + * // => true + * + * _.isFinite(Infinity); + * // => false + * + * _.isFinite('3'); + * // => false + */ + function isFinite$2(value) { + return typeof value == "number" && nativeIsFinite(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$10(value) { + if (!isObject$5(value)) return false; + var tag$3 = baseGetTag(value); + return tag$3 == funcTag || tag$3 == genTag || tag$3 == asyncTag || tag$3 == proxyTag; + } + /** + * 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); + } + /** + * 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; + } + /** + * 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$5(value) { + var type = typeof value; + return value != null && (type == "object" || type == "function"); + } + /** + * 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$1(value) { + return value != null && typeof value == "object"; + } + /** + * Checks if `value` is classified as a `Map` object. + * + * @static + * @memberOf _ + * @since 4.3.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a map, else `false`. + * @example + * + * _.isMap(new Map); + * // => true + * + * _.isMap(new WeakMap); + * // => false + */ + var isMap$2 = nodeIsMap ? baseUnary(nodeIsMap) : baseIsMap; + /** + * Performs a partial deep comparison between `object` and `source` to + * determine if `object` contains equivalent property values. + * + * **Note:** This method is equivalent to `_.matches` when `source` is + * partially applied. + * + * Partial comparisons will match empty array and empty object `source` + * values against any array or object value, respectively. See `_.isEqual` + * for a list of supported value comparisons. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Lang + * @param {Object} object The object to inspect. + * @param {Object} source The object of property values to match. + * @returns {boolean} Returns `true` if `object` is a match, else `false`. + * @example + * + * var object = { 'a': 1, 'b': 2 }; + * + * _.isMatch(object, { 'b': 2 }); + * // => true + * + * _.isMatch(object, { 'b': 1 }); + * // => false + */ + function isMatch$1(object$3, source) { + return object$3 === source || baseIsMatch(object$3, source, getMatchData(source)); + } + /** + * This method is like `_.isMatch` except that it accepts `customizer` which + * is invoked to compare values. If `customizer` returns `undefined`, comparisons + * are handled by the method instead. The `customizer` is invoked with five + * arguments: (objValue, srcValue, index|key, object, source). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {Object} object The object to inspect. + * @param {Object} source The object of property values to match. + * @param {Function} [customizer] The function to customize comparisons. + * @returns {boolean} Returns `true` if `object` is a match, else `false`. + * @example + * + * function isGreeting(value) { + * return /^h(?:i|ello)$/.test(value); + * } + * + * function customizer(objValue, srcValue) { + * if (isGreeting(objValue) && isGreeting(srcValue)) { + * return true; + * } + * } + * + * var object = { 'greeting': 'hello' }; + * var source = { 'greeting': 'hi' }; + * + * _.isMatchWith(object, source, customizer); + * // => true + */ + function isMatchWith(object$3, source, customizer) { + customizer = typeof customizer == "function" ? customizer : undefined$1; + return baseIsMatch(object$3, source, getMatchData(source), customizer); + } + /** + * Checks if `value` is `NaN`. + * + * **Note:** This method is based on + * [`Number.isNaN`](https://mdn.io/Number/isNaN) and is not the same as + * global [`isNaN`](https://mdn.io/isNaN) which returns `true` for + * `undefined` and other non-number values. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is `NaN`, else `false`. + * @example + * + * _.isNaN(NaN); + * // => true + * + * _.isNaN(new Number(NaN)); + * // => true + * + * isNaN(undefined); + * // => true + * + * _.isNaN(undefined); + * // => false + */ + function isNaN$2(value) { + return isNumber$2(value) && value != +value; + } + /** + * Checks if `value` is a pristine native function. + * + * **Note:** This method can't reliably detect native functions in the presence + * of the core-js package because core-js circumvents this kind of detection. + * Despite multiple requests, the core-js maintainer has made it clear: any + * attempt to fix the detection will be obstructed. As a result, we're left + * with little choice but to throw an error. Unfortunately, this also affects + * packages, like [babel-polyfill](https://www.npmjs.com/package/babel-polyfill), + * which rely on core-js. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a native function, + * else `false`. + * @example + * + * _.isNative(Array.prototype.push); + * // => true + * + * _.isNative(_); + * // => false + */ + function isNative(value) { + if (isMaskable(value)) throw new Error$1(CORE_ERROR_TEXT); + return baseIsNative(value); + } + /** + * Checks if `value` is `null`. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is `null`, else `false`. + * @example + * + * _.isNull(null); + * // => true + * + * _.isNull(void 0); + * // => false + */ + function isNull$1(value) { + return value === null; + } + /** + * Checks if `value` is `null` or `undefined`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is nullish, else `false`. + * @example + * + * _.isNil(null); + * // => true + * + * _.isNil(void 0); + * // => true + * + * _.isNil(NaN); + * // => false + */ + function isNil(value) { + return value == null; + } + /** + * 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 _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a number, else `false`. + * @example + * + * _.isNumber(3); + * // => true + * + * _.isNumber(Number.MIN_VALUE); + * // => true + * + * _.isNumber(Infinity); + * // => true + * + * _.isNumber('3'); + * // => false + */ + function isNumber$2(value) { + return typeof value == "number" || isObjectLike$1(value) && baseGetTag(value) == numberTag; + } + /** + * 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$2(value) { + if (!isObjectLike$1(value) || baseGetTag(value) != objectTag) return false; + var proto = getPrototype(value); + if (proto === null) return true; + var Ctor = hasOwnProperty$6.call(proto, "constructor") && proto.constructor; + return typeof Ctor == "function" && Ctor instanceof Ctor && funcToString.call(Ctor) == objectCtorString; + } + /** + * Checks if `value` is classified as a `RegExp` object. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a regexp, else `false`. + * @example + * + * _.isRegExp(/abc/); + * // => true + * + * _.isRegExp('/abc/'); + * // => false + */ + var isRegExp$1 = nodeIsRegExp ? baseUnary(nodeIsRegExp) : baseIsRegExp; + /** + * Checks if `value` is a safe integer. An integer is safe if it's an IEEE-754 + * double precision number which isn't the result of a rounded unsafe integer. + * + * **Note:** This method is based on + * [`Number.isSafeInteger`](https://mdn.io/Number/isSafeInteger). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a safe integer, else `false`. + * @example + * + * _.isSafeInteger(3); + * // => true + * + * _.isSafeInteger(Number.MIN_VALUE); + * // => false + * + * _.isSafeInteger(Infinity); + * // => false + * + * _.isSafeInteger('3'); + * // => false + */ + function isSafeInteger(value) { + return isInteger(value) && value >= -MAX_SAFE_INTEGER && value <= MAX_SAFE_INTEGER; + } + /** + * Checks if `value` is classified as a `Set` object. + * + * @static + * @memberOf _ + * @since 4.3.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a set, else `false`. + * @example + * + * _.isSet(new Set); + * // => true + * + * _.isSet(new WeakSet); + * // => false + */ + var isSet$2 = nodeIsSet ? baseUnary(nodeIsSet) : baseIsSet; + /** + * 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$5(value) { + return typeof value == "string" || !isArray$5(value) && isObjectLike$1(value) && baseGetTag(value) == stringTag; + } + /** + * 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$2(value) { + return typeof value == "symbol" || isObjectLike$1(value) && baseGetTag(value) == symbolTag$1; + } + /** + * 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$1 = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray; + /** + * Checks if `value` is `undefined`. + * + * @static + * @since 0.1.0 + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is `undefined`, else `false`. + * @example + * + * _.isUndefined(void 0); + * // => true + * + * _.isUndefined(null); + * // => false + */ + function isUndefined$1(value) { + return value === undefined$1; + } + /** + * Checks if `value` is classified as a `WeakMap` object. + * + * @static + * @memberOf _ + * @since 4.3.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a weak map, else `false`. + * @example + * + * _.isWeakMap(new WeakMap); + * // => true + * + * _.isWeakMap(new Map); + * // => false + */ + function isWeakMap(value) { + return isObjectLike$1(value) && getTag(value) == weakMapTag; + } + /** + * Checks if `value` is classified as a `WeakSet` object. + * + * @static + * @memberOf _ + * @since 4.3.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a weak set, else `false`. + * @example + * + * _.isWeakSet(new WeakSet); + * // => true + * + * _.isWeakSet(new Set); + * // => false + */ + function isWeakSet(value) { + return isObjectLike$1(value) && baseGetTag(value) == weakSetTag; + } + /** + * Checks if `value` is less than `other`. + * + * @static + * @memberOf _ + * @since 3.9.0 + * @category Lang + * @param {*} value The value to compare. + * @param {*} other The other value to compare. + * @returns {boolean} Returns `true` if `value` is less than `other`, + * else `false`. + * @see _.gt + * @example + * + * _.lt(1, 3); + * // => true + * + * _.lt(3, 3); + * // => false + * + * _.lt(3, 1); + * // => false + */ + var lt = createRelationalOperation(baseLt); + /** + * Checks if `value` is less than or equal to `other`. + * + * @static + * @memberOf _ + * @since 3.9.0 + * @category Lang + * @param {*} value The value to compare. + * @param {*} other The other value to compare. + * @returns {boolean} Returns `true` if `value` is less than or equal to + * `other`, else `false`. + * @see _.gte + * @example + * + * _.lte(1, 3); + * // => true + * + * _.lte(3, 3); + * // => true + * + * _.lte(3, 1); + * // => false + */ + var lte$1 = createRelationalOperation(function(value, other) { + return value <= other; + }); + /** + * Converts `value` to an array. + * + * @static + * @since 0.1.0 + * @memberOf _ + * @category Lang + * @param {*} value The value to convert. + * @returns {Array} Returns the converted array. + * @example + * + * _.toArray({ 'a': 1, 'b': 2 }); + * // => [1, 2] + * + * _.toArray('abc'); + * // => ['a', 'b', 'c'] + * + * _.toArray(1); + * // => [] + * + * _.toArray(null); + * // => [] + */ + function toArray$1(value) { + if (!value) return []; + if (isArrayLike(value)) return isString$5(value) ? stringToArray$1(value) : copyArray(value); + if (symIterator && value[symIterator]) return iteratorToArray(value[symIterator]()); + var tag$3 = getTag(value), func = tag$3 == mapTag ? mapToArray : tag$3 == setTag ? setToArray : values$1; + return func(value); + } + /** + * 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$1(value); + if (value === INFINITY$1 || value === -INFINITY$1) { + 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$2 = toFinite(value), remainder = result$2 % 1; + return result$2 === result$2 ? remainder ? result$2 - remainder : result$2 : 0; + } + /** + * Converts `value` to an integer suitable for use as the length of an + * array-like object. + * + * **Note:** This method is 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 convert. + * @returns {number} Returns the converted integer. + * @example + * + * _.toLength(3.2); + * // => 3 + * + * _.toLength(Number.MIN_VALUE); + * // => 0 + * + * _.toLength(Infinity); + * // => 4294967295 + * + * _.toLength('3.2'); + * // => 3 + */ + function toLength(value) { + return value ? baseClamp(toInteger(value), 0, MAX_ARRAY_LENGTH) : 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$1(value) { + if (typeof value == "number") return value; + if (isSymbol$2(value)) return NAN; + if (isObject$5(value)) { + var other = typeof value.valueOf == "function" ? value.valueOf() : value; + value = isObject$5(other) ? other + "" : other; + } + if (typeof value != "string") return value === 0 ? value : +value; + value = baseTrim(value); + var isBinary$3 = reIsBinary.test(value); + return isBinary$3 || reIsOctal.test(value) ? freeParseInt(value.slice(2), isBinary$3 ? 2 : 8) : reIsBadHex.test(value) ? NAN : +value; + } + /** + * Converts `value` to a plain object flattening inherited enumerable string + * keyed properties of `value` to own properties of the plain object. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {Object} Returns the converted plain object. + * @example + * + * function Foo() { + * this.b = 2; + * } + * + * Foo.prototype.c = 3; + * + * _.assign({ 'a': 1 }, new Foo); + * // => { 'a': 1, 'b': 2 } + * + * _.assign({ 'a': 1 }, _.toPlainObject(new Foo)); + * // => { 'a': 1, 'b': 2, 'c': 3 } + */ + function toPlainObject(value) { + return copyObject(value, keysIn(value)); + } + /** + * Converts `value` to a safe integer. A safe integer can be compared and + * represented correctly. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {number} Returns the converted integer. + * @example + * + * _.toSafeInteger(3.2); + * // => 3 + * + * _.toSafeInteger(Number.MIN_VALUE); + * // => 0 + * + * _.toSafeInteger(Infinity); + * // => 9007199254740991 + * + * _.toSafeInteger('3.2'); + * // => 3 + */ + function toSafeInteger(value) { + return value ? baseClamp(toInteger(value), -MAX_SAFE_INTEGER, MAX_SAFE_INTEGER) : value === 0 ? value : 0; + } + /** + * Converts `value` to a string. An empty string is returned for `null` + * and `undefined` values. The sign of `-0` is preserved. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {string} Returns the converted string. + * @example + * + * _.toString(null); + * // => '' + * + * _.toString(-0); + * // => '-0' + * + * _.toString([1, 2, 3]); + * // => '1,2,3' + */ + function toString$6(value) { + return value == null ? "" : baseToString$1(value); + } + /** + * Assigns own enumerable string keyed properties of source objects to the + * destination object. Source objects are applied from left to right. + * Subsequent sources overwrite property assignments of previous sources. + * + * **Note:** This method mutates `object` and is loosely based on + * [`Object.assign`](https://mdn.io/Object/assign). + * + * @static + * @memberOf _ + * @since 0.10.0 + * @category Object + * @param {Object} object The destination object. + * @param {...Object} [sources] The source objects. + * @returns {Object} Returns `object`. + * @see _.assignIn + * @example + * + * function Foo() { + * this.a = 1; + * } + * + * function Bar() { + * this.c = 3; + * } + * + * Foo.prototype.b = 2; + * Bar.prototype.d = 4; + * + * _.assign({ 'a': 0 }, new Foo, new Bar); + * // => { 'a': 1, 'c': 3 } + */ + var assign = createAssigner$1(function(object$3, source) { + if (isPrototype(source) || isArrayLike(source)) { + copyObject(source, keys$2(source), object$3); + return; + } + for (var key in source) if (hasOwnProperty$6.call(source, key)) assignValue(object$3, key, source[key]); + }); + /** + * This method is like `_.assign` except that it iterates over own and + * inherited source properties. + * + * **Note:** This method mutates `object`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @alias extend + * @category Object + * @param {Object} object The destination object. + * @param {...Object} [sources] The source objects. + * @returns {Object} Returns `object`. + * @see _.assign + * @example + * + * function Foo() { + * this.a = 1; + * } + * + * function Bar() { + * this.c = 3; + * } + * + * Foo.prototype.b = 2; + * Bar.prototype.d = 4; + * + * _.assignIn({ 'a': 0 }, new Foo, new Bar); + * // => { 'a': 1, 'b': 2, 'c': 3, 'd': 4 } + */ + var assignIn = createAssigner$1(function(object$3, source) { + copyObject(source, keysIn(source), object$3); + }); + /** + * This method is like `_.assignIn` except that it accepts `customizer` + * which is invoked to produce the assigned values. If `customizer` returns + * `undefined`, assignment is handled by the method instead. The `customizer` + * is invoked with five arguments: (objValue, srcValue, key, object, source). + * + * **Note:** This method mutates `object`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @alias extendWith + * @category Object + * @param {Object} object The destination object. + * @param {...Object} sources The source objects. + * @param {Function} [customizer] The function to customize assigned values. + * @returns {Object} Returns `object`. + * @see _.assignWith + * @example + * + * function customizer(objValue, srcValue) { + * return _.isUndefined(objValue) ? srcValue : objValue; + * } + * + * var defaults = _.partialRight(_.assignInWith, customizer); + * + * defaults({ 'a': 1 }, { 'b': 2 }, { 'a': 3 }); + * // => { 'a': 1, 'b': 2 } + */ + var assignInWith = createAssigner$1(function(object$3, source, srcIndex, customizer) { + copyObject(source, keysIn(source), object$3, customizer); + }); + /** + * This method is like `_.assign` except that it accepts `customizer` + * which is invoked to produce the assigned values. If `customizer` returns + * `undefined`, assignment is handled by the method instead. The `customizer` + * is invoked with five arguments: (objValue, srcValue, key, object, source). + * + * **Note:** This method mutates `object`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Object + * @param {Object} object The destination object. + * @param {...Object} sources The source objects. + * @param {Function} [customizer] The function to customize assigned values. + * @returns {Object} Returns `object`. + * @see _.assignInWith + * @example + * + * function customizer(objValue, srcValue) { + * return _.isUndefined(objValue) ? srcValue : objValue; + * } + * + * var defaults = _.partialRight(_.assignWith, customizer); + * + * defaults({ 'a': 1 }, { 'b': 2 }, { 'a': 3 }); + * // => { 'a': 1, 'b': 2 } + */ + var assignWith = createAssigner$1(function(object$3, source, srcIndex, customizer) { + copyObject(source, keys$2(source), object$3, customizer); + }); + /** + * Creates an array of values corresponding to `paths` of `object`. + * + * @static + * @memberOf _ + * @since 1.0.0 + * @category Object + * @param {Object} object The object to iterate over. + * @param {...(string|string[])} [paths] The property paths to pick. + * @returns {Array} Returns the picked values. + * @example + * + * var object = { 'a': [{ 'b': { 'c': 3 } }, 4] }; + * + * _.at(object, ['a[0].b.c', 'a[1]']); + * // => [3, 4] + */ + var at$3 = flatRest(baseAt); + /** + * Creates an object that inherits from the `prototype` object. If a + * `properties` object is given, its own enumerable string keyed properties + * are assigned to the created object. + * + * @static + * @memberOf _ + * @since 2.3.0 + * @category Object + * @param {Object} prototype The object to inherit from. + * @param {Object} [properties] The properties to assign to the object. + * @returns {Object} Returns the new object. + * @example + * + * function Shape() { + * this.x = 0; + * this.y = 0; + * } + * + * function Circle() { + * Shape.call(this); + * } + * + * Circle.prototype = _.create(Shape.prototype, { + * 'constructor': Circle + * }); + * + * var circle = new Circle; + * circle instanceof Circle; + * // => true + * + * circle instanceof Shape; + * // => true + */ + function create$7(prototype, properties) { + var result$2 = baseCreate$1(prototype); + return properties == null ? result$2 : baseAssign(result$2, properties); + } + /** + * 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$2 = baseRest(function(object$3, sources) { + object$3 = Object$1(object$3); + var index$1 = -1; + var length = sources.length; + var guard = length > 2 ? sources[2] : undefined$1; + if (guard && isIterateeCall(sources[0], sources[1], guard)) length = 1; + while (++index$1 < length) { + var source = sources[index$1]; + var props = keysIn(source); + var propsIndex = -1; + var propsLength = props.length; + while (++propsIndex < propsLength) { + var key = props[propsIndex]; + var value = object$3[key]; + if (value === undefined$1 || eq$1(value, objectProto$1[key]) && !hasOwnProperty$6.call(object$3, key)) object$3[key] = source[key]; + } + } + return object$3; + }); + /** + * This method is like `_.defaults` except that it recursively assigns + * default properties. + * + * **Note:** This method mutates `object`. + * + * @static + * @memberOf _ + * @since 3.10.0 + * @category Object + * @param {Object} object The destination object. + * @param {...Object} [sources] The source objects. + * @returns {Object} Returns `object`. + * @see _.defaults + * @example + * + * _.defaultsDeep({ 'a': { 'b': 2 } }, { 'a': { 'b': 1, 'c': 3 } }); + * // => { 'a': { 'b': 2, 'c': 3 } } + */ + var defaultsDeep = baseRest(function(args) { + args.push(undefined$1, customDefaultsMerge); + return apply(mergeWith, undefined$1, args); + }); + /** + * This method is like `_.find` except that it returns the key of the first + * element `predicate` returns truthy for instead of the element itself. + * + * @static + * @memberOf _ + * @since 1.1.0 + * @category Object + * @param {Object} object The object to inspect. + * @param {Function} [predicate=_.identity] The function invoked per iteration. + * @returns {string|undefined} Returns the key of the matched element, + * else `undefined`. + * @example + * + * var users = { + * 'barney': { 'age': 36, 'active': true }, + * 'fred': { 'age': 40, 'active': false }, + * 'pebbles': { 'age': 1, 'active': true } + * }; + * + * _.findKey(users, function(o) { return o.age < 40; }); + * // => 'barney' (iteration order is not guaranteed) + * + * // The `_.matches` iteratee shorthand. + * _.findKey(users, { 'age': 1, 'active': true }); + * // => 'pebbles' + * + * // The `_.matchesProperty` iteratee shorthand. + * _.findKey(users, ['active', false]); + * // => 'fred' + * + * // The `_.property` iteratee shorthand. + * _.findKey(users, 'active'); + * // => 'barney' + */ + function findKey$1(object$3, predicate) { + return baseFindKey(object$3, getIteratee(predicate, 3), baseForOwn); + } + /** + * This method is like `_.findKey` except that it iterates over elements of + * a collection in the opposite order. + * + * @static + * @memberOf _ + * @since 2.0.0 + * @category Object + * @param {Object} object The object to inspect. + * @param {Function} [predicate=_.identity] The function invoked per iteration. + * @returns {string|undefined} Returns the key of the matched element, + * else `undefined`. + * @example + * + * var users = { + * 'barney': { 'age': 36, 'active': true }, + * 'fred': { 'age': 40, 'active': false }, + * 'pebbles': { 'age': 1, 'active': true } + * }; + * + * _.findLastKey(users, function(o) { return o.age < 40; }); + * // => returns 'pebbles' assuming `_.findKey` returns 'barney' + * + * // The `_.matches` iteratee shorthand. + * _.findLastKey(users, { 'age': 36, 'active': true }); + * // => 'barney' + * + * // The `_.matchesProperty` iteratee shorthand. + * _.findLastKey(users, ['active', false]); + * // => 'fred' + * + * // The `_.property` iteratee shorthand. + * _.findLastKey(users, 'active'); + * // => 'pebbles' + */ + function findLastKey(object$3, predicate) { + return baseFindKey(object$3, getIteratee(predicate, 3), baseForOwnRight); + } + /** + * Iterates over own and inherited enumerable string keyed properties of an + * object and invokes `iteratee` for each property. The iteratee is invoked + * with three arguments: (value, key, object). Iteratee functions may exit + * iteration early by explicitly returning `false`. + * + * @static + * @memberOf _ + * @since 0.3.0 + * @category Object + * @param {Object} object The object to iterate over. + * @param {Function} [iteratee=_.identity] The function invoked per iteration. + * @returns {Object} Returns `object`. + * @see _.forInRight + * @example + * + * function Foo() { + * this.a = 1; + * this.b = 2; + * } + * + * Foo.prototype.c = 3; + * + * _.forIn(new Foo, function(value, key) { + * console.log(key); + * }); + * // => Logs 'a', 'b', then 'c' (iteration order is not guaranteed). + */ + function forIn(object$3, iteratee$2) { + return object$3 == null ? object$3 : baseFor(object$3, getIteratee(iteratee$2, 3), keysIn); + } + /** + * This method is like `_.forIn` except that it iterates over properties of + * `object` in the opposite order. + * + * @static + * @memberOf _ + * @since 2.0.0 + * @category Object + * @param {Object} object The object to iterate over. + * @param {Function} [iteratee=_.identity] The function invoked per iteration. + * @returns {Object} Returns `object`. + * @see _.forIn + * @example + * + * function Foo() { + * this.a = 1; + * this.b = 2; + * } + * + * Foo.prototype.c = 3; + * + * _.forInRight(new Foo, function(value, key) { + * console.log(key); + * }); + * // => Logs 'c', 'b', then 'a' assuming `_.forIn` logs 'a', 'b', then 'c'. + */ + function forInRight(object$3, iteratee$2) { + return object$3 == null ? object$3 : baseForRight(object$3, getIteratee(iteratee$2, 3), keysIn); + } + /** + * Iterates over own enumerable string keyed properties of an object and + * invokes `iteratee` for each property. The iteratee is invoked with three + * arguments: (value, key, object). Iteratee functions may exit iteration + * early by explicitly returning `false`. + * + * @static + * @memberOf _ + * @since 0.3.0 + * @category Object + * @param {Object} object The object to iterate over. + * @param {Function} [iteratee=_.identity] The function invoked per iteration. + * @returns {Object} Returns `object`. + * @see _.forOwnRight + * @example + * + * function Foo() { + * this.a = 1; + * this.b = 2; + * } + * + * Foo.prototype.c = 3; + * + * _.forOwn(new Foo, function(value, key) { + * console.log(key); + * }); + * // => Logs 'a' then 'b' (iteration order is not guaranteed). + */ + function forOwn$1(object$3, iteratee$2) { + return object$3 && baseForOwn(object$3, getIteratee(iteratee$2, 3)); + } + /** + * This method is like `_.forOwn` except that it iterates over properties of + * `object` in the opposite order. + * + * @static + * @memberOf _ + * @since 2.0.0 + * @category Object + * @param {Object} object The object to iterate over. + * @param {Function} [iteratee=_.identity] The function invoked per iteration. + * @returns {Object} Returns `object`. + * @see _.forOwn + * @example + * + * function Foo() { + * this.a = 1; + * this.b = 2; + * } + * + * Foo.prototype.c = 3; + * + * _.forOwnRight(new Foo, function(value, key) { + * console.log(key); + * }); + * // => Logs 'b' then 'a' assuming `_.forOwn` logs 'a' then 'b'. + */ + function forOwnRight(object$3, iteratee$2) { + return object$3 && baseForOwnRight(object$3, getIteratee(iteratee$2, 3)); + } + /** + * Creates an array of function property names from own enumerable properties + * of `object`. + * + * @static + * @since 0.1.0 + * @memberOf _ + * @category Object + * @param {Object} object The object to inspect. + * @returns {Array} Returns the function names. + * @see _.functionsIn + * @example + * + * function Foo() { + * this.a = _.constant('a'); + * this.b = _.constant('b'); + * } + * + * Foo.prototype.c = _.constant('c'); + * + * _.functions(new Foo); + * // => ['a', 'b'] + */ + function functions$1(object$3) { + return object$3 == null ? [] : baseFunctions(object$3, keys$2(object$3)); + } + /** + * Creates an array of function property names from own and inherited + * enumerable properties of `object`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Object + * @param {Object} object The object to inspect. + * @returns {Array} Returns the function names. + * @see _.functions + * @example + * + * function Foo() { + * this.a = _.constant('a'); + * this.b = _.constant('b'); + * } + * + * Foo.prototype.c = _.constant('c'); + * + * _.functionsIn(new Foo); + * // => ['a', 'b', 'c'] + */ + function functionsIn(object$3) { + return object$3 == null ? [] : baseFunctions(object$3, keysIn(object$3)); + } + /** + * Gets the value at `path` of `object`. If the resolved value is + * `undefined`, the `defaultValue` is returned in its place. + * + * @static + * @memberOf _ + * @since 3.7.0 + * @category Object + * @param {Object} object The object to query. + * @param {Array|string} path The path of the property to get. + * @param {*} [defaultValue] The value returned for `undefined` resolved values. + * @returns {*} Returns the resolved value. + * @example + * + * var object = { 'a': [{ 'b': { 'c': 3 } }] }; + * + * _.get(object, 'a[0].b.c'); + * // => 3 + * + * _.get(object, ['a', '0', 'b', 'c']); + * // => 3 + * + * _.get(object, 'a.b.c', 'default'); + * // => 'default' + */ + function get$3(object$3, path$28, defaultValue) { + var result$2 = object$3 == null ? undefined$1 : baseGet(object$3, path$28); + return result$2 === undefined$1 ? defaultValue : result$2; + } + /** + * Checks if `path` is a direct property of `object`. + * + * @static + * @since 0.1.0 + * @memberOf _ + * @category Object + * @param {Object} object The object to query. + * @param {Array|string} path The path to check. + * @returns {boolean} Returns `true` if `path` exists, else `false`. + * @example + * + * var object = { 'a': { 'b': 2 } }; + * var other = _.create({ 'a': _.create({ 'b': 2 }) }); + * + * _.has(object, 'a'); + * // => true + * + * _.has(object, 'a.b'); + * // => true + * + * _.has(object, ['a', 'b']); + * // => true + * + * _.has(other, 'a'); + * // => false + */ + function has$3(object$3, path$28) { + return object$3 != null && hasPath(object$3, path$28, baseHas); + } + /** + * Checks if `path` is a direct or inherited property of `object`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Object + * @param {Object} object The object to query. + * @param {Array|string} path The path to check. + * @returns {boolean} Returns `true` if `path` exists, else `false`. + * @example + * + * var object = _.create({ 'a': _.create({ 'b': 2 }) }); + * + * _.hasIn(object, 'a'); + * // => true + * + * _.hasIn(object, 'a.b'); + * // => true + * + * _.hasIn(object, ['a', 'b']); + * // => true + * + * _.hasIn(object, 'b'); + * // => false + */ + function hasIn(object$3, path$28) { + return object$3 != null && hasPath(object$3, path$28, baseHasIn); + } + /** + * Creates an object composed of the inverted keys and values of `object`. + * If `object` contains duplicate values, subsequent values overwrite + * property assignments of previous values. + * + * @static + * @memberOf _ + * @since 0.7.0 + * @category Object + * @param {Object} object The object to invert. + * @returns {Object} Returns the new inverted object. + * @example + * + * var object = { 'a': 1, 'b': 2, 'c': 1 }; + * + * _.invert(object); + * // => { '1': 'c', '2': 'b' } + */ + var invert$1 = createInverter(function(result$2, value, key) { + if (value != null && typeof value.toString != "function") value = nativeObjectToString.call(value); + result$2[value] = key; + }, constant$1(identity$2)); + /** + * This method is like `_.invert` except that the inverted object is generated + * from the results of running each element of `object` thru `iteratee`. The + * corresponding inverted value of each inverted key is an array of keys + * responsible for generating the inverted value. The iteratee is invoked + * with one argument: (value). + * + * @static + * @memberOf _ + * @since 4.1.0 + * @category Object + * @param {Object} object The object to invert. + * @param {Function} [iteratee=_.identity] The iteratee invoked per element. + * @returns {Object} Returns the new inverted object. + * @example + * + * var object = { 'a': 1, 'b': 2, 'c': 1 }; + * + * _.invertBy(object); + * // => { '1': ['a', 'c'], '2': ['b'] } + * + * _.invertBy(object, function(value) { + * return 'group' + value; + * }); + * // => { 'group1': ['a', 'c'], 'group2': ['b'] } + */ + var invertBy = createInverter(function(result$2, value, key) { + if (value != null && typeof value.toString != "function") value = nativeObjectToString.call(value); + if (hasOwnProperty$6.call(result$2, value)) result$2[value].push(key); + else result$2[value] = [key]; + }, getIteratee); + /** + * Invokes the method at `path` of `object`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Object + * @param {Object} object The object to query. + * @param {Array|string} path The path of the method to invoke. + * @param {...*} [args] The arguments to invoke the method with. + * @returns {*} Returns the result of the invoked method. + * @example + * + * var object = { 'a': [{ 'b': { 'c': [1, 2, 3, 4] } }] }; + * + * _.invoke(object, 'a[0].b.c.slice', 1, 3); + * // => [2, 3] + */ + var invoke = baseRest(baseInvoke); + /** + * 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$2(object$3) { + return isArrayLike(object$3) ? arrayLikeKeys(object$3) : baseKeys(object$3); + } + /** + * 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$3) { + return isArrayLike(object$3) ? arrayLikeKeys(object$3, true) : baseKeysIn(object$3); + } + /** + * The opposite of `_.mapValues`; this method creates an object with the + * same values as `object` and keys generated by running each own enumerable + * string keyed property of `object` thru `iteratee`. The iteratee is invoked + * with three arguments: (value, key, object). + * + * @static + * @memberOf _ + * @since 3.8.0 + * @category Object + * @param {Object} object The object to iterate over. + * @param {Function} [iteratee=_.identity] The function invoked per iteration. + * @returns {Object} Returns the new mapped object. + * @see _.mapValues + * @example + * + * _.mapKeys({ 'a': 1, 'b': 2 }, function(value, key) { + * return key + value; + * }); + * // => { 'a1': 1, 'b2': 2 } + */ + function mapKeys(object$3, iteratee$2) { + var result$2 = {}; + iteratee$2 = getIteratee(iteratee$2, 3); + baseForOwn(object$3, function(value, key, object$4) { + baseAssignValue(result$2, iteratee$2(value, key, object$4), value); + }); + return result$2; + } + /** + * Creates an object with the same keys as `object` and values generated + * by running each own enumerable string keyed property of `object` thru + * `iteratee`. The iteratee is invoked with three arguments: + * (value, key, object). + * + * @static + * @memberOf _ + * @since 2.4.0 + * @category Object + * @param {Object} object The object to iterate over. + * @param {Function} [iteratee=_.identity] The function invoked per iteration. + * @returns {Object} Returns the new mapped object. + * @see _.mapKeys + * @example + * + * var users = { + * 'fred': { 'user': 'fred', 'age': 40 }, + * 'pebbles': { 'user': 'pebbles', 'age': 1 } + * }; + * + * _.mapValues(users, function(o) { return o.age; }); + * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed) + * + * // The `_.property` iteratee shorthand. + * _.mapValues(users, 'age'); + * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed) + */ + function mapValues(object$3, iteratee$2) { + var result$2 = {}; + iteratee$2 = getIteratee(iteratee$2, 3); + baseForOwn(object$3, function(value, key, object$4) { + baseAssignValue(result$2, key, iteratee$2(value, key, object$4)); + }); + return result$2; + } + /** + * This method is like `_.assign` except that it recursively merges own and + * inherited enumerable string keyed properties of source objects into the + * destination object. Source properties that resolve to `undefined` are + * skipped if a destination value exists. Array and plain object properties + * are merged recursively. Other objects and value types are overridden by + * assignment. Source objects are applied from left to right. Subsequent + * sources overwrite property assignments of previous sources. + * + * **Note:** This method mutates `object`. + * + * @static + * @memberOf _ + * @since 0.5.0 + * @category Object + * @param {Object} object The destination object. + * @param {...Object} [sources] The source objects. + * @returns {Object} Returns `object`. + * @example + * + * var object = { + * 'a': [{ 'b': 2 }, { 'd': 4 }] + * }; + * + * var other = { + * 'a': [{ 'c': 3 }, { 'e': 5 }] + * }; + * + * _.merge(object, other); + * // => { 'a': [{ 'b': 2, 'c': 3 }, { 'd': 4, 'e': 5 }] } + */ + var merge$5 = createAssigner$1(function(object$3, source, srcIndex) { + baseMerge(object$3, source, srcIndex); + }); + /** + * This method is like `_.merge` except that it accepts `customizer` which + * is invoked to produce the merged values of the destination and source + * properties. If `customizer` returns `undefined`, merging is handled by the + * method instead. The `customizer` is invoked with six arguments: + * (objValue, srcValue, key, object, source, stack). + * + * **Note:** This method mutates `object`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Object + * @param {Object} object The destination object. + * @param {...Object} sources The source objects. + * @param {Function} customizer The function to customize assigned values. + * @returns {Object} Returns `object`. + * @example + * + * function customizer(objValue, srcValue) { + * if (_.isArray(objValue)) { + * return objValue.concat(srcValue); + * } + * } + * + * var object = { 'a': [1], 'b': [2] }; + * var other = { 'a': [3], 'b': [4] }; + * + * _.mergeWith(object, other, customizer); + * // => { 'a': [1, 3], 'b': [2, 4] } + */ + var mergeWith = createAssigner$1(function(object$3, source, srcIndex, customizer) { + baseMerge(object$3, source, srcIndex, customizer); + }); + /** + * The opposite of `_.pick`; this method creates an object composed of the + * own and inherited enumerable property paths of `object` that are not omitted. + * + * **Note:** This method is considerably slower than `_.pick`. + * + * @static + * @since 0.1.0 + * @memberOf _ + * @category Object + * @param {Object} object The source object. + * @param {...(string|string[])} [paths] The property paths to omit. + * @returns {Object} Returns the new object. + * @example + * + * var object = { 'a': 1, 'b': '2', 'c': 3 }; + * + * _.omit(object, ['a', 'c']); + * // => { 'b': '2' } + */ + var omit = flatRest(function(object$3, paths) { + var result$2 = {}; + if (object$3 == null) return result$2; + var isDeep = false; + paths = arrayMap(paths, function(path$28) { + path$28 = castPath(path$28, object$3); + isDeep || (isDeep = path$28.length > 1); + return path$28; + }); + copyObject(object$3, getAllKeysIn(object$3), result$2); + if (isDeep) result$2 = baseClone(result$2, CLONE_DEEP_FLAG | CLONE_FLAT_FLAG | CLONE_SYMBOLS_FLAG, customOmitClone); + var length = paths.length; + while (length--) baseUnset(result$2, paths[length]); + return result$2; + }); + /** + * The opposite of `_.pickBy`; this method creates an object composed of + * the own and inherited enumerable string keyed properties of `object` that + * `predicate` doesn't return truthy for. The predicate is invoked with two + * arguments: (value, key). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Object + * @param {Object} object The source object. + * @param {Function} [predicate=_.identity] The function invoked per property. + * @returns {Object} Returns the new object. + * @example + * + * var object = { 'a': 1, 'b': '2', 'c': 3 }; + * + * _.omitBy(object, _.isNumber); + * // => { 'b': '2' } + */ + function omitBy(object$3, predicate) { + return pickBy(object$3, negate$1(getIteratee(predicate))); + } + /** + * Creates an object composed of the picked `object` properties. + * + * @static + * @since 0.1.0 + * @memberOf _ + * @category Object + * @param {Object} object The source object. + * @param {...(string|string[])} [paths] The property paths to pick. + * @returns {Object} Returns the new object. + * @example + * + * var object = { 'a': 1, 'b': '2', 'c': 3 }; + * + * _.pick(object, ['a', 'c']); + * // => { 'a': 1, 'c': 3 } + */ + var pick = flatRest(function(object$3, paths) { + return object$3 == null ? {} : basePick(object$3, paths); + }); + /** + * Creates an object composed of the `object` properties `predicate` returns + * truthy for. The predicate is invoked with two arguments: (value, key). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Object + * @param {Object} object The source object. + * @param {Function} [predicate=_.identity] The function invoked per property. + * @returns {Object} Returns the new object. + * @example + * + * var object = { 'a': 1, 'b': '2', 'c': 3 }; + * + * _.pickBy(object, _.isNumber); + * // => { 'a': 1, 'c': 3 } + */ + function pickBy(object$3, predicate) { + if (object$3 == null) return {}; + var props = arrayMap(getAllKeysIn(object$3), function(prop) { + return [prop]; + }); + predicate = getIteratee(predicate); + return basePickBy(object$3, props, function(value, path$28) { + return predicate(value, path$28[0]); + }); + } + /** + * This method is like `_.get` except that if the resolved value is a + * function it's invoked with the `this` binding of its parent object and + * its result is returned. + * + * @static + * @since 0.1.0 + * @memberOf _ + * @category Object + * @param {Object} object The object to query. + * @param {Array|string} path The path of the property to resolve. + * @param {*} [defaultValue] The value returned for `undefined` resolved values. + * @returns {*} Returns the resolved value. + * @example + * + * var object = { 'a': [{ 'b': { 'c1': 3, 'c2': _.constant(4) } }] }; + * + * _.result(object, 'a[0].b.c1'); + * // => 3 + * + * _.result(object, 'a[0].b.c2'); + * // => 4 + * + * _.result(object, 'a[0].b.c3', 'default'); + * // => 'default' + * + * _.result(object, 'a[0].b.c3', _.constant('default')); + * // => 'default' + */ + function result$1(object$3, path$28, defaultValue) { + path$28 = castPath(path$28, object$3); + var index$1 = -1, length = path$28.length; + if (!length) { + length = 1; + object$3 = undefined$1; + } + while (++index$1 < length) { + var value = object$3 == null ? undefined$1 : object$3[toKey(path$28[index$1])]; + if (value === undefined$1) { + index$1 = length; + value = defaultValue; + } + object$3 = isFunction$10(value) ? value.call(object$3) : value; + } + return object$3; + } + /** + * Sets the value at `path` of `object`. If a portion of `path` doesn't exist, + * it's created. Arrays are created for missing index properties while objects + * are created for all other missing properties. Use `_.setWith` to customize + * `path` creation. + * + * **Note:** This method mutates `object`. + * + * @static + * @memberOf _ + * @since 3.7.0 + * @category Object + * @param {Object} object The object to modify. + * @param {Array|string} path The path of the property to set. + * @param {*} value The value to set. + * @returns {Object} Returns `object`. + * @example + * + * var object = { 'a': [{ 'b': { 'c': 3 } }] }; + * + * _.set(object, 'a[0].b.c', 4); + * console.log(object.a[0].b.c); + * // => 4 + * + * _.set(object, ['x', '0', 'y', 'z'], 5); + * console.log(object.x[0].y.z); + * // => 5 + */ + function set(object$3, path$28, value) { + return object$3 == null ? object$3 : baseSet(object$3, path$28, value); + } + /** + * This method is like `_.set` except that it accepts `customizer` which is + * invoked to produce the objects of `path`. If `customizer` returns `undefined` + * path creation is handled by the method instead. The `customizer` is invoked + * with three arguments: (nsValue, key, nsObject). + * + * **Note:** This method mutates `object`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Object + * @param {Object} object The object to modify. + * @param {Array|string} path The path of the property to set. + * @param {*} value The value to set. + * @param {Function} [customizer] The function to customize assigned values. + * @returns {Object} Returns `object`. + * @example + * + * var object = {}; + * + * _.setWith(object, '[0][1]', 'a', Object); + * // => { '0': { '1': 'a' } } + */ + function setWith(object$3, path$28, value, customizer) { + customizer = typeof customizer == "function" ? customizer : undefined$1; + return object$3 == null ? object$3 : baseSet(object$3, path$28, value, customizer); + } + /** + * Creates an array of own enumerable string keyed-value pairs for `object` + * which can be consumed by `_.fromPairs`. If `object` is a map or set, its + * entries are returned. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @alias entries + * @category Object + * @param {Object} object The object to query. + * @returns {Array} Returns the key-value pairs. + * @example + * + * function Foo() { + * this.a = 1; + * this.b = 2; + * } + * + * Foo.prototype.c = 3; + * + * _.toPairs(new Foo); + * // => [['a', 1], ['b', 2]] (iteration order is not guaranteed) + */ + var toPairs = createToPairs(keys$2); + /** + * Creates an array of own and inherited enumerable string keyed-value pairs + * for `object` which can be consumed by `_.fromPairs`. If `object` is a map + * or set, its entries are returned. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @alias entriesIn + * @category Object + * @param {Object} object The object to query. + * @returns {Array} Returns the key-value pairs. + * @example + * + * function Foo() { + * this.a = 1; + * this.b = 2; + * } + * + * Foo.prototype.c = 3; + * + * _.toPairsIn(new Foo); + * // => [['a', 1], ['b', 2], ['c', 3]] (iteration order is not guaranteed) + */ + var toPairsIn = createToPairs(keysIn); + /** + * An alternative to `_.reduce`; this method transforms `object` to a new + * `accumulator` object which is the result of running each of its own + * enumerable string keyed properties thru `iteratee`, with each invocation + * potentially mutating the `accumulator` object. If `accumulator` is not + * provided, a new object with the same `[[Prototype]]` will be used. The + * iteratee is invoked with four arguments: (accumulator, value, key, object). + * Iteratee functions may exit iteration early by explicitly returning `false`. + * + * @static + * @memberOf _ + * @since 1.3.0 + * @category Object + * @param {Object} object The object to iterate over. + * @param {Function} [iteratee=_.identity] The function invoked per iteration. + * @param {*} [accumulator] The custom accumulator value. + * @returns {*} Returns the accumulated value. + * @example + * + * _.transform([2, 3, 4], function(result, n) { + * result.push(n *= n); + * return n % 2 == 0; + * }, []); + * // => [4, 9] + * + * _.transform({ 'a': 1, 'b': 2, 'c': 1 }, function(result, value, key) { + * (result[value] || (result[value] = [])).push(key); + * }, {}); + * // => { '1': ['a', 'c'], '2': ['b'] } + */ + function transform$1(object$3, iteratee$2, accumulator) { + var isArr = isArray$5(object$3), isArrLike = isArr || isBuffer$1(object$3) || isTypedArray$1(object$3); + iteratee$2 = getIteratee(iteratee$2, 4); + if (accumulator == null) { + var Ctor = object$3 && object$3.constructor; + if (isArrLike) accumulator = isArr ? new Ctor() : []; + else if (isObject$5(object$3)) accumulator = isFunction$10(Ctor) ? baseCreate$1(getPrototype(object$3)) : {}; + else accumulator = {}; + } + (isArrLike ? arrayEach : baseForOwn)(object$3, function(value, index$1, object$4) { + return iteratee$2(accumulator, value, index$1, object$4); + }); + return accumulator; + } + /** + * Removes the property at `path` of `object`. + * + * **Note:** This method mutates `object`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Object + * @param {Object} object The object to modify. + * @param {Array|string} path The path of the property to unset. + * @returns {boolean} Returns `true` if the property is deleted, else `false`. + * @example + * + * var object = { 'a': [{ 'b': { 'c': 7 } }] }; + * _.unset(object, 'a[0].b.c'); + * // => true + * + * console.log(object); + * // => { 'a': [{ 'b': {} }] }; + * + * _.unset(object, ['a', '0', 'b', 'c']); + * // => true + * + * console.log(object); + * // => { 'a': [{ 'b': {} }] }; + */ + function unset(object$3, path$28) { + return object$3 == null ? true : baseUnset(object$3, path$28); + } + /** + * This method is like `_.set` except that accepts `updater` to produce the + * value to set. Use `_.updateWith` to customize `path` creation. The `updater` + * is invoked with one argument: (value). + * + * **Note:** This method mutates `object`. + * + * @static + * @memberOf _ + * @since 4.6.0 + * @category Object + * @param {Object} object The object to modify. + * @param {Array|string} path The path of the property to set. + * @param {Function} updater The function to produce the updated value. + * @returns {Object} Returns `object`. + * @example + * + * var object = { 'a': [{ 'b': { 'c': 3 } }] }; + * + * _.update(object, 'a[0].b.c', function(n) { return n * n; }); + * console.log(object.a[0].b.c); + * // => 9 + * + * _.update(object, 'x[0].y.z', function(n) { return n ? n + 1 : 0; }); + * console.log(object.x[0].y.z); + * // => 0 + */ + function update(object$3, path$28, updater) { + return object$3 == null ? object$3 : baseUpdate(object$3, path$28, castFunction(updater)); + } + /** + * This method is like `_.update` except that it accepts `customizer` which is + * invoked to produce the objects of `path`. If `customizer` returns `undefined` + * path creation is handled by the method instead. The `customizer` is invoked + * with three arguments: (nsValue, key, nsObject). + * + * **Note:** This method mutates `object`. + * + * @static + * @memberOf _ + * @since 4.6.0 + * @category Object + * @param {Object} object The object to modify. + * @param {Array|string} path The path of the property to set. + * @param {Function} updater The function to produce the updated value. + * @param {Function} [customizer] The function to customize assigned values. + * @returns {Object} Returns `object`. + * @example + * + * var object = {}; + * + * _.updateWith(object, '[0][1]', _.constant('a'), Object); + * // => { '0': { '1': 'a' } } + */ + function updateWith(object$3, path$28, updater, customizer) { + customizer = typeof customizer == "function" ? customizer : undefined$1; + return object$3 == null ? object$3 : baseUpdate(object$3, path$28, castFunction(updater), customizer); + } + /** + * 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$1(object$3) { + return object$3 == null ? [] : baseValues(object$3, keys$2(object$3)); + } + /** + * Creates an array of the own and inherited enumerable string keyed property + * values 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 values. + * @example + * + * function Foo() { + * this.a = 1; + * this.b = 2; + * } + * + * Foo.prototype.c = 3; + * + * _.valuesIn(new Foo); + * // => [1, 2, 3] (iteration order is not guaranteed) + */ + function valuesIn(object$3) { + return object$3 == null ? [] : baseValues(object$3, keysIn(object$3)); + } + /** + * Clamps `number` within the inclusive `lower` and `upper` bounds. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Number + * @param {number} number The number to clamp. + * @param {number} [lower] The lower bound. + * @param {number} upper The upper bound. + * @returns {number} Returns the clamped number. + * @example + * + * _.clamp(-10, -5, 5); + * // => -5 + * + * _.clamp(10, -5, 5); + * // => 5 + */ + function clamp(number, lower, upper) { + if (upper === undefined$1) { + upper = lower; + lower = undefined$1; + } + if (upper !== undefined$1) { + upper = toNumber$1(upper); + upper = upper === upper ? upper : 0; + } + if (lower !== undefined$1) { + lower = toNumber$1(lower); + lower = lower === lower ? lower : 0; + } + return baseClamp(toNumber$1(number), lower, upper); + } + /** + * Checks if `n` is between `start` and up to, but not including, `end`. If + * `end` is not specified, it's set to `start` with `start` then set to `0`. + * If `start` is greater than `end` the params are swapped to support + * negative ranges. + * + * @static + * @memberOf _ + * @since 3.3.0 + * @category Number + * @param {number} number The number to check. + * @param {number} [start=0] The start of the range. + * @param {number} end The end of the range. + * @returns {boolean} Returns `true` if `number` is in the range, else `false`. + * @see _.range, _.rangeRight + * @example + * + * _.inRange(3, 2, 4); + * // => true + * + * _.inRange(4, 8); + * // => true + * + * _.inRange(4, 2); + * // => false + * + * _.inRange(2, 2); + * // => false + * + * _.inRange(1.2, 2); + * // => true + * + * _.inRange(5.2, 4); + * // => false + * + * _.inRange(-3, -2, -6); + * // => true + */ + function inRange(number, start, end) { + start = toFinite(start); + if (end === undefined$1) { + end = start; + start = 0; + } else end = toFinite(end); + number = toNumber$1(number); + return baseInRange(number, start, end); + } + /** + * Produces a random number between the inclusive `lower` and `upper` bounds. + * If only one argument is provided a number between `0` and the given number + * is returned. If `floating` is `true`, or either `lower` or `upper` are + * floats, a floating-point number is returned instead of an integer. + * + * **Note:** JavaScript follows the IEEE-754 standard for resolving + * floating-point values which can produce unexpected results. + * + * @static + * @memberOf _ + * @since 0.7.0 + * @category Number + * @param {number} [lower=0] The lower bound. + * @param {number} [upper=1] The upper bound. + * @param {boolean} [floating] Specify returning a floating-point number. + * @returns {number} Returns the random number. + * @example + * + * _.random(0, 5); + * // => an integer between 0 and 5 + * + * _.random(5); + * // => also an integer between 0 and 5 + * + * _.random(5, true); + * // => a floating-point number between 0 and 5 + * + * _.random(1.2, 5.2); + * // => a floating-point number between 1.2 and 5.2 + */ + function random$1(lower, upper, floating) { + if (floating && typeof floating != "boolean" && isIterateeCall(lower, upper, floating)) upper = floating = undefined$1; + if (floating === undefined$1) { + if (typeof upper == "boolean") { + floating = upper; + upper = undefined$1; + } else if (typeof lower == "boolean") { + floating = lower; + lower = undefined$1; + } + } + if (lower === undefined$1 && upper === undefined$1) { + lower = 0; + upper = 1; + } else { + lower = toFinite(lower); + if (upper === undefined$1) { + upper = lower; + lower = 0; + } else upper = toFinite(upper); + } + if (lower > upper) { + var temp = lower; + lower = upper; + upper = temp; + } + if (floating || lower % 1 || upper % 1) { + var rand = nativeRandom(); + return nativeMin(lower + rand * (upper - lower + freeParseFloat("1e-" + ((rand + "").length - 1))), upper); + } + return baseRandom(lower, upper); + } + /** + * Converts `string` to [camel case](https://en.wikipedia.org/wiki/CamelCase). + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category String + * @param {string} [string=''] The string to convert. + * @returns {string} Returns the camel cased string. + * @example + * + * _.camelCase('Foo Bar'); + * // => 'fooBar' + * + * _.camelCase('--foo-bar--'); + * // => 'fooBar' + * + * _.camelCase('__FOO_BAR__'); + * // => 'fooBar' + */ + var camelCase$2 = createCompounder$1(function(result$2, word$3, index$1) { + word$3 = word$3.toLowerCase(); + return result$2 + (index$1 ? capitalize$3(word$3) : word$3); + }); + /** + * Converts the first character of `string` to upper case and the remaining + * to lower case. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category String + * @param {string} [string=''] The string to capitalize. + * @returns {string} Returns the capitalized string. + * @example + * + * _.capitalize('FRED'); + * // => 'Fred' + */ + function capitalize$3(string$3) { + return upperFirst$1(toString$6(string$3).toLowerCase()); + } + /** + * Deburrs `string` by converting + * [Latin-1 Supplement](https://en.wikipedia.org/wiki/Latin-1_Supplement_(Unicode_block)#Character_table) + * and [Latin Extended-A](https://en.wikipedia.org/wiki/Latin_Extended-A) + * letters to basic Latin letters and removing + * [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks). + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category String + * @param {string} [string=''] The string to deburr. + * @returns {string} Returns the deburred string. + * @example + * + * _.deburr('déjà vu'); + * // => 'deja vu' + */ + function deburr$1(string$3) { + string$3 = toString$6(string$3); + return string$3 && string$3.replace(reLatin$1, deburrLetter$1).replace(reComboMark$1, ""); + } + /** + * Checks if `string` ends with the given target string. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category String + * @param {string} [string=''] The string to inspect. + * @param {string} [target] The string to search for. + * @param {number} [position=string.length] The position to search up to. + * @returns {boolean} Returns `true` if `string` ends with `target`, + * else `false`. + * @example + * + * _.endsWith('abc', 'c'); + * // => true + * + * _.endsWith('abc', 'b'); + * // => false + * + * _.endsWith('abc', 'b', 2); + * // => true + */ + function endsWith(string$3, target, position) { + string$3 = toString$6(string$3); + target = baseToString$1(target); + var length = string$3.length; + position = position === undefined$1 ? length : baseClamp(toInteger(position), 0, length); + var end = position; + position -= target.length; + return position >= 0 && string$3.slice(position, end) == target; + } + /** + * Converts the characters "&", "<", ">", '"', and "'" in `string` to their + * corresponding HTML entities. + * + * **Note:** No other characters are escaped. To escape additional + * characters use a third-party library like [_he_](https://mths.be/he). + * + * Though the ">" character is escaped for symmetry, characters like + * ">" and "/" don't need escaping in HTML and have no special meaning + * unless they're part of a tag or unquoted attribute value. See + * [Mathias Bynens's article](https://mathiasbynens.be/notes/ambiguous-ampersands) + * (under "semi-related fun fact") for more details. + * + * When working with HTML you should always + * [quote attribute values](http://wonko.com/post/html-escaping) to reduce + * XSS vectors. + * + * @static + * @since 0.1.0 + * @memberOf _ + * @category String + * @param {string} [string=''] The string to escape. + * @returns {string} Returns the escaped string. + * @example + * + * _.escape('fred, barney, & pebbles'); + * // => 'fred, barney, & pebbles' + */ + function escape$2(string$3) { + string$3 = toString$6(string$3); + return string$3 && reHasUnescapedHtml.test(string$3) ? string$3.replace(reUnescapedHtml, escapeHtmlChar) : string$3; + } + /** + * Escapes the `RegExp` special characters "^", "$", "\", ".", "*", "+", + * "?", "(", ")", "[", "]", "{", "}", and "|" in `string`. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category String + * @param {string} [string=''] The string to escape. + * @returns {string} Returns the escaped string. + * @example + * + * _.escapeRegExp('[lodash](https://lodash.com/)'); + * // => '\[lodash\]\(https://lodash\.com/\)' + */ + function escapeRegExp$1(string$3) { + string$3 = toString$6(string$3); + return string$3 && reHasRegExpChar.test(string$3) ? string$3.replace(reRegExpChar, "\\$&") : string$3; + } + /** + * Converts `string` to + * [kebab case](https://en.wikipedia.org/wiki/Letter_case#Special_case_styles). + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category String + * @param {string} [string=''] The string to convert. + * @returns {string} Returns the kebab cased string. + * @example + * + * _.kebabCase('Foo Bar'); + * // => 'foo-bar' + * + * _.kebabCase('fooBar'); + * // => 'foo-bar' + * + * _.kebabCase('__FOO_BAR__'); + * // => 'foo-bar' + */ + var kebabCase$1 = createCompounder$1(function(result$2, word$3, index$1) { + return result$2 + (index$1 ? "-" : "") + word$3.toLowerCase(); + }); + /** + * Converts `string`, as space separated words, to lower case. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category String + * @param {string} [string=''] The string to convert. + * @returns {string} Returns the lower cased string. + * @example + * + * _.lowerCase('--Foo-Bar--'); + * // => 'foo bar' + * + * _.lowerCase('fooBar'); + * // => 'foo bar' + * + * _.lowerCase('__FOO_BAR__'); + * // => 'foo bar' + */ + var lowerCase = createCompounder$1(function(result$2, word$3, index$1) { + return result$2 + (index$1 ? " " : "") + word$3.toLowerCase(); + }); + /** + * Converts the first character of `string` to lower case. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category String + * @param {string} [string=''] The string to convert. + * @returns {string} Returns the converted string. + * @example + * + * _.lowerFirst('Fred'); + * // => 'fred' + * + * _.lowerFirst('FRED'); + * // => 'fRED' + */ + var lowerFirst = createCaseFirst$1("toLowerCase"); + /** + * Pads `string` on the left and right sides if it's shorter than `length`. + * Padding characters are truncated if they can't be evenly divided by `length`. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category String + * @param {string} [string=''] The string to pad. + * @param {number} [length=0] The padding length. + * @param {string} [chars=' '] The string used as padding. + * @returns {string} Returns the padded string. + * @example + * + * _.pad('abc', 8); + * // => ' abc ' + * + * _.pad('abc', 8, '_-'); + * // => '_-abc_-_' + * + * _.pad('abc', 3); + * // => 'abc' + */ + function pad$1(string$3, length, chars$1) { + string$3 = toString$6(string$3); + length = toInteger(length); + var strLength = length ? stringSize(string$3) : 0; + if (!length || strLength >= length) return string$3; + var mid = (length - strLength) / 2; + return createPadding(nativeFloor(mid), chars$1) + string$3 + createPadding(nativeCeil(mid), chars$1); + } + /** + * Pads `string` on the right side if it's shorter than `length`. Padding + * characters are truncated if they exceed `length`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category String + * @param {string} [string=''] The string to pad. + * @param {number} [length=0] The padding length. + * @param {string} [chars=' '] The string used as padding. + * @returns {string} Returns the padded string. + * @example + * + * _.padEnd('abc', 6); + * // => 'abc ' + * + * _.padEnd('abc', 6, '_-'); + * // => 'abc_-_' + * + * _.padEnd('abc', 3); + * // => 'abc' + */ + function padEnd(string$3, length, chars$1) { + string$3 = toString$6(string$3); + length = toInteger(length); + var strLength = length ? stringSize(string$3) : 0; + return length && strLength < length ? string$3 + createPadding(length - strLength, chars$1) : string$3; + } + /** + * Pads `string` on the left side if it's shorter than `length`. Padding + * characters are truncated if they exceed `length`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category String + * @param {string} [string=''] The string to pad. + * @param {number} [length=0] The padding length. + * @param {string} [chars=' '] The string used as padding. + * @returns {string} Returns the padded string. + * @example + * + * _.padStart('abc', 6); + * // => ' abc' + * + * _.padStart('abc', 6, '_-'); + * // => '_-_abc' + * + * _.padStart('abc', 3); + * // => 'abc' + */ + function padStart(string$3, length, chars$1) { + string$3 = toString$6(string$3); + length = toInteger(length); + var strLength = length ? stringSize(string$3) : 0; + return length && strLength < length ? createPadding(length - strLength, chars$1) + string$3 : string$3; + } + /** + * Converts `string` to an integer of the specified radix. If `radix` is + * `undefined` or `0`, a `radix` of `10` is used unless `value` is a + * hexadecimal, in which case a `radix` of `16` is used. + * + * **Note:** This method aligns with the + * [ES5 implementation](https://es5.github.io/#x15.1.2.2) of `parseInt`. + * + * @static + * @memberOf _ + * @since 1.1.0 + * @category String + * @param {string} string The string to convert. + * @param {number} [radix=10] The radix to interpret `value` by. + * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`. + * @returns {number} Returns the converted integer. + * @example + * + * _.parseInt('08'); + * // => 8 + * + * _.map(['6', '08', '10'], _.parseInt); + * // => [6, 8, 10] + */ + function parseInt$1(string$3, radix, guard) { + if (guard || radix == null) radix = 0; + else if (radix) radix = +radix; + return nativeParseInt(toString$6(string$3).replace(reTrimStart, ""), radix || 0); + } + /** + * Repeats the given string `n` times. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category String + * @param {string} [string=''] The string to repeat. + * @param {number} [n=1] The number of times to repeat the string. + * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`. + * @returns {string} Returns the repeated string. + * @example + * + * _.repeat('*', 3); + * // => '***' + * + * _.repeat('abc', 2); + * // => 'abcabc' + * + * _.repeat('abc', 0); + * // => '' + */ + function repeat(string$3, n$3, guard) { + if (guard ? isIterateeCall(string$3, n$3, guard) : n$3 === undefined$1) n$3 = 1; + else n$3 = toInteger(n$3); + return baseRepeat(toString$6(string$3), n$3); + } + /** + * Replaces matches for `pattern` in `string` with `replacement`. + * + * **Note:** This method is based on + * [`String#replace`](https://mdn.io/String/replace). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category String + * @param {string} [string=''] The string to modify. + * @param {RegExp|string} pattern The pattern to replace. + * @param {Function|string} replacement The match replacement. + * @returns {string} Returns the modified string. + * @example + * + * _.replace('Hi Fred', 'Fred', 'Barney'); + * // => 'Hi Barney' + */ + function replace() { + var args = arguments, string$3 = toString$6(args[0]); + return args.length < 3 ? string$3 : string$3.replace(args[1], args[2]); + } + /** + * Converts `string` to + * [snake case](https://en.wikipedia.org/wiki/Snake_case). + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category String + * @param {string} [string=''] The string to convert. + * @returns {string} Returns the snake cased string. + * @example + * + * _.snakeCase('Foo Bar'); + * // => 'foo_bar' + * + * _.snakeCase('fooBar'); + * // => 'foo_bar' + * + * _.snakeCase('--FOO-BAR--'); + * // => 'foo_bar' + */ + var snakeCase = createCompounder$1(function(result$2, word$3, index$1) { + return result$2 + (index$1 ? "_" : "") + word$3.toLowerCase(); + }); + /** + * Splits `string` by `separator`. + * + * **Note:** This method is based on + * [`String#split`](https://mdn.io/String/split). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category String + * @param {string} [string=''] The string to split. + * @param {RegExp|string} separator The separator pattern to split by. + * @param {number} [limit] The length to truncate results to. + * @returns {Array} Returns the string segments. + * @example + * + * _.split('a-b-c', '-', 2); + * // => ['a', 'b'] + */ + function split(string$3, separator, limit) { + if (limit && typeof limit != "number" && isIterateeCall(string$3, separator, limit)) separator = limit = undefined$1; + limit = limit === undefined$1 ? MAX_ARRAY_LENGTH : limit >>> 0; + if (!limit) return []; + string$3 = toString$6(string$3); + if (string$3 && (typeof separator == "string" || separator != null && !isRegExp$1(separator))) { + separator = baseToString$1(separator); + if (!separator && hasUnicode$1(string$3)) return castSlice$1(stringToArray$1(string$3), 0, limit); + } + return string$3.split(separator, limit); + } + /** + * Converts `string` to + * [start case](https://en.wikipedia.org/wiki/Letter_case#Stylistic_or_specialised_usage). + * + * @static + * @memberOf _ + * @since 3.1.0 + * @category String + * @param {string} [string=''] The string to convert. + * @returns {string} Returns the start cased string. + * @example + * + * _.startCase('--foo-bar--'); + * // => 'Foo Bar' + * + * _.startCase('fooBar'); + * // => 'Foo Bar' + * + * _.startCase('__FOO_BAR__'); + * // => 'FOO BAR' + */ + var startCase = createCompounder$1(function(result$2, word$3, index$1) { + return result$2 + (index$1 ? " " : "") + upperFirst$1(word$3); + }); + /** + * Checks if `string` starts with the given target string. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category String + * @param {string} [string=''] The string to inspect. + * @param {string} [target] The string to search for. + * @param {number} [position=0] The position to search from. + * @returns {boolean} Returns `true` if `string` starts with `target`, + * else `false`. + * @example + * + * _.startsWith('abc', 'a'); + * // => true + * + * _.startsWith('abc', 'b'); + * // => false + * + * _.startsWith('abc', 'b', 1); + * // => true + */ + function startsWith$1(string$3, target, position) { + string$3 = toString$6(string$3); + position = position == null ? 0 : baseClamp(toInteger(position), 0, string$3.length); + target = baseToString$1(target); + return string$3.slice(position, position + target.length) == target; + } + /** + * Creates a compiled template function that can interpolate data properties + * in "interpolate" delimiters, HTML-escape interpolated data properties in + * "escape" delimiters, and execute JavaScript in "evaluate" delimiters. Data + * properties may be accessed as free variables in the template. If a setting + * object is given, it takes precedence over `_.templateSettings` values. + * + * **Note:** In the development build `_.template` utilizes + * [sourceURLs](http://www.html5rocks.com/en/tutorials/developertools/sourcemaps/#toc-sourceurl) + * for easier debugging. + * + * For more information on precompiling templates see + * [lodash's custom builds documentation](https://lodash.com/custom-builds). + * + * For more information on Chrome extension sandboxes see + * [Chrome's extensions documentation](https://developer.chrome.com/extensions/sandboxingEval). + * + * @static + * @since 0.1.0 + * @memberOf _ + * @category String + * @param {string} [string=''] The template string. + * @param {Object} [options={}] The options object. + * @param {RegExp} [options.escape=_.templateSettings.escape] + * The HTML "escape" delimiter. + * @param {RegExp} [options.evaluate=_.templateSettings.evaluate] + * The "evaluate" delimiter. + * @param {Object} [options.imports=_.templateSettings.imports] + * An object to import into the template as free variables. + * @param {RegExp} [options.interpolate=_.templateSettings.interpolate] + * The "interpolate" delimiter. + * @param {string} [options.sourceURL='lodash.templateSources[n]'] + * The sourceURL of the compiled template. + * @param {string} [options.variable='obj'] + * The data object variable name. + * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`. + * @returns {Function} Returns the compiled template function. + * @example + * + * // Use the "interpolate" delimiter to create a compiled template. + * var compiled = _.template('hello <%= user %>!'); + * compiled({ 'user': 'fred' }); + * // => 'hello fred!' + * + * // Use the HTML "escape" delimiter to escape data property values. + * var compiled = _.template('<%- value %>'); + * compiled({ 'value': '