@ohos-ports/rsbuild-core 1.7.2-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +27 -0
- package/bin/rsbuild.js +20 -0
- package/compiled/@jridgewell/remapping/index.d.ts +1 -0
- package/compiled/@jridgewell/remapping/index.js +1222 -0
- package/compiled/@jridgewell/remapping/license +19 -0
- package/compiled/@jridgewell/remapping/package.json +1 -0
- package/compiled/@jridgewell/trace-mapping/index.d.ts +194 -0
- package/compiled/@jridgewell/trace-mapping/index.js +1408 -0
- package/compiled/@jridgewell/trace-mapping/license +19 -0
- package/compiled/@jridgewell/trace-mapping/package.json +1 -0
- package/compiled/chokidar/index.d.ts +384 -0
- package/compiled/chokidar/index.js +1793 -0
- package/compiled/chokidar/license +21 -0
- package/compiled/chokidar/package.json +1 -0
- package/compiled/connect/index.d.ts +90 -0
- package/compiled/connect/index.js +1240 -0
- package/compiled/connect/license +25 -0
- package/compiled/connect/package.json +1 -0
- package/compiled/cors/index.d.ts +56 -0
- package/compiled/cors/index.js +371 -0
- package/compiled/cors/license +22 -0
- package/compiled/cors/package.json +1 -0
- package/compiled/css-loader/api.js +85 -0
- package/compiled/css-loader/getUrl.js +26 -0
- package/compiled/css-loader/index.d.ts +1 -0
- package/compiled/css-loader/index.js +2 -0
- package/compiled/css-loader/license +20 -0
- package/compiled/css-loader/noSourceMaps.js +5 -0
- package/compiled/css-loader/package.json +1 -0
- package/compiled/css-loader/sourceMaps.js +16 -0
- package/compiled/html-rspack-plugin/default_index.ejs +9 -0
- package/compiled/html-rspack-plugin/index.d.ts +290 -0
- package/compiled/html-rspack-plugin/index.js +1602 -0
- package/compiled/html-rspack-plugin/license +20 -0
- package/compiled/html-rspack-plugin/loader.js +166 -0
- package/compiled/html-rspack-plugin/package.json +1 -0
- package/compiled/http-proxy-middleware/index.d.ts +319 -0
- package/compiled/http-proxy-middleware/index.js +5284 -0
- package/compiled/http-proxy-middleware/license +22 -0
- package/compiled/http-proxy-middleware/package.json +1 -0
- package/compiled/launch-editor-middleware/index.d.ts +1 -0
- package/compiled/launch-editor-middleware/index.js +719 -0
- package/compiled/launch-editor-middleware/license +21 -0
- package/compiled/launch-editor-middleware/package.json +1 -0
- package/compiled/memfs/index.d.ts +1462 -0
- package/compiled/memfs/index.js +1 -0
- package/compiled/memfs/license +201 -0
- package/compiled/memfs/package.json +1 -0
- package/compiled/mrmime/index.d.ts +4 -0
- package/compiled/mrmime/index.js +456 -0
- package/compiled/mrmime/package.json +1 -0
- package/compiled/picocolors/index.d.ts +55 -0
- package/compiled/picocolors/index.js +108 -0
- package/compiled/picocolors/license +15 -0
- package/compiled/picocolors/package.json +1 -0
- package/compiled/postcss/index.js +1 -0
- package/compiled/postcss/lib/at-rule.d.ts +140 -0
- package/compiled/postcss/lib/comment.d.ts +68 -0
- package/compiled/postcss/lib/container.d.ts +483 -0
- package/compiled/postcss/lib/css-syntax-error.d.ts +248 -0
- package/compiled/postcss/lib/declaration.d.ts +151 -0
- package/compiled/postcss/lib/document.d.ts +69 -0
- package/compiled/postcss/lib/fromJSON.d.ts +9 -0
- package/compiled/postcss/lib/input.d.ts +227 -0
- package/compiled/postcss/lib/lazy-result.d.ts +190 -0
- package/compiled/postcss/lib/list.d.ts +60 -0
- package/compiled/postcss/lib/no-work-result.d.ts +46 -0
- package/compiled/postcss/lib/node.d.ts +556 -0
- package/compiled/postcss/lib/parse.d.ts +9 -0
- package/compiled/postcss/lib/postcss.d.ts +458 -0
- package/compiled/postcss/lib/previous-map.d.ts +81 -0
- package/compiled/postcss/lib/processor.d.ts +115 -0
- package/compiled/postcss/lib/result.d.ts +205 -0
- package/compiled/postcss/lib/root.d.ts +87 -0
- package/compiled/postcss/lib/rule.d.ts +126 -0
- package/compiled/postcss/lib/source-map-js.d.ts +4 -0
- package/compiled/postcss/lib/stringifier.d.ts +46 -0
- package/compiled/postcss/lib/stringify.d.ts +9 -0
- package/compiled/postcss/lib/warning.d.ts +147 -0
- package/compiled/postcss/license +20 -0
- package/compiled/postcss/package.json +1 -0
- package/compiled/postcss-loader/index.d.ts +1 -0
- package/compiled/postcss-loader/index.js +720 -0
- package/compiled/postcss-loader/license +20 -0
- package/compiled/postcss-loader/package.json +1 -0
- package/compiled/rslog/index.d.ts +67 -0
- package/compiled/rslog/license +21 -0
- package/compiled/rslog/package.json +1 -0
- package/compiled/rspack-chain/license +22 -0
- package/compiled/rspack-chain/package.json +1 -0
- package/compiled/rspack-chain/types/index.d.ts +545 -0
- package/compiled/rspack-manifest-plugin/index.d.ts +48 -0
- package/compiled/rspack-manifest-plugin/index.js +409 -0
- package/compiled/rspack-manifest-plugin/license +21 -0
- package/compiled/rspack-manifest-plugin/package.json +1 -0
- package/compiled/sirv/index.d.ts +1 -0
- package/compiled/sirv/index.js +274 -0
- package/compiled/sirv/package.json +1 -0
- package/compiled/style-loader/index.d.ts +1 -0
- package/compiled/style-loader/index.js +427 -0
- package/compiled/style-loader/license +20 -0
- package/compiled/style-loader/package.json +1 -0
- package/compiled/style-loader/runtime/injectStylesIntoLinkTag.js +29 -0
- package/compiled/style-loader/runtime/injectStylesIntoStyleTag.js +84 -0
- package/compiled/style-loader/runtime/insertBySelector.js +34 -0
- package/compiled/style-loader/runtime/insertStyleElement.js +10 -0
- package/compiled/style-loader/runtime/isEqualLocals.js +28 -0
- package/compiled/style-loader/runtime/isOldIE.js +17 -0
- package/compiled/style-loader/runtime/setAttributesWithAttributes.js +13 -0
- package/compiled/style-loader/runtime/setAttributesWithAttributesAndNonce.js +9 -0
- package/compiled/style-loader/runtime/setAttributesWithoutAttributes.js +10 -0
- package/compiled/style-loader/runtime/singletonStyleDomAPI.js +86 -0
- package/compiled/style-loader/runtime/styleDomAPI.js +61 -0
- package/compiled/style-loader/runtime/styleTagTransform.js +14 -0
- package/compiled/tinyglobby/index.d.ts +46 -0
- package/compiled/tinyglobby/index.js +2664 -0
- package/compiled/tinyglobby/license +21 -0
- package/compiled/tinyglobby/package.json +1 -0
- package/compiled/webpack-bundle-analyzer/index.d.ts +160 -0
- package/compiled/webpack-bundle-analyzer/index.js +23 -0
- package/compiled/webpack-bundle-analyzer/license +20 -0
- package/compiled/webpack-bundle-analyzer/package.json +1 -0
- package/compiled/webpack-bundle-analyzer/public/viewer.js +16 -0
- package/compiled/webpack-bundle-analyzer/public/viewer.js.LICENSE.txt +10 -0
- package/compiled/webpack-merge/index.d.ts +31 -0
- package/compiled/webpack-merge/index.js +1200 -0
- package/compiled/webpack-merge/license +20 -0
- package/compiled/webpack-merge/package.json +1 -0
- package/compiled/ws/index.d.ts +437 -0
- package/compiled/ws/index.js +3161 -0
- package/compiled/ws/license +20 -0
- package/compiled/ws/package.json +1 -0
- package/dist/0~open.js +427 -0
- package/dist/0~range-parser.js +49 -0
- package/dist/0~range-parser.js.LICENSE.txt +6 -0
- package/dist/131.js +9305 -0
- package/dist/131.js.LICENSE.txt +26 -0
- package/dist/136.mjs +42 -0
- package/dist/2~open.cjs +436 -0
- package/dist/2~range-parser.cjs +52 -0
- package/dist/2~range-parser.cjs.LICENSE.txt +6 -0
- package/dist/client/59.js +22 -0
- package/dist/client/hmr.js +206 -0
- package/dist/client/overlay.js +203 -0
- package/dist/ignoreCssLoader.mjs +3 -0
- package/dist/index.cjs +9456 -0
- package/dist/index.cjs.LICENSE.txt +26 -0
- package/dist/index.js +1 -0
- package/dist/rslib-runtime.js +44 -0
- package/dist/transformLoader.mjs +1 -0
- package/dist/transformRawLoader.mjs +4 -0
- package/dist-types/cli/commands.d.ts +28 -0
- package/dist-types/cli/index.d.ts +1 -0
- package/dist-types/cli/init.d.ts +7 -0
- package/dist-types/client/hmr.d.ts +3 -0
- package/dist-types/client/log.d.ts +13 -0
- package/dist-types/client/overlay.d.ts +1 -0
- package/dist-types/configChain.d.ts +154 -0
- package/dist-types/constants.d.ts +52 -0
- package/dist-types/createContext.d.ts +11 -0
- package/dist-types/createRsbuild.d.ts +5 -0
- package/dist-types/defaultConfig.d.ts +25 -0
- package/dist-types/helpers/compiler.d.ts +5 -0
- package/dist-types/helpers/exitHook.d.ts +3 -0
- package/dist-types/helpers/format.d.ts +2 -0
- package/dist-types/helpers/fs.d.ts +17 -0
- package/dist-types/helpers/index.d.ts +29 -0
- package/dist-types/helpers/path.d.ts +26 -0
- package/dist-types/helpers/stats.d.ts +18 -0
- package/dist-types/helpers/url.d.ts +11 -0
- package/dist-types/helpers/vendors.d.ts +29 -0
- package/dist-types/helpers/version.d.ts +7 -0
- package/dist-types/hooks.d.ts +44 -0
- package/dist-types/index.d.ts +22 -0
- package/dist-types/initPlugins.d.ts +6 -0
- package/dist-types/inspectConfig.d.ts +35 -0
- package/dist-types/loadConfig.d.ts +60 -0
- package/dist-types/loadEnv.d.ts +63 -0
- package/dist-types/loader/ignoreCssLoader.d.ts +3 -0
- package/dist-types/loader/transformLoader.d.ts +8 -0
- package/dist-types/loader/transformRawLoader.d.ts +3 -0
- package/dist-types/logger.d.ts +19 -0
- package/dist-types/mergeConfig.d.ts +2 -0
- package/dist-types/package.json +1 -0
- package/dist-types/pluginHelper.d.ts +12 -0
- package/dist-types/pluginManager.d.ts +21 -0
- package/dist-types/plugins/appIcon.d.ts +2 -0
- package/dist-types/plugins/asset.d.ts +3 -0
- package/dist-types/plugins/basic.d.ts +5 -0
- package/dist-types/plugins/bundleAnalyzer.d.ts +2 -0
- package/dist-types/plugins/cache.d.ts +2 -0
- package/dist-types/plugins/cleanOutput.d.ts +2 -0
- package/dist-types/plugins/css.d.ts +4 -0
- package/dist-types/plugins/define.d.ts +2 -0
- package/dist-types/plugins/entry.d.ts +2 -0
- package/dist-types/plugins/esm.d.ts +2 -0
- package/dist-types/plugins/externals.d.ts +2 -0
- package/dist-types/plugins/fileSize.d.ts +6 -0
- package/dist-types/plugins/html.d.ts +9 -0
- package/dist-types/plugins/inlineChunk.d.ts +6 -0
- package/dist-types/plugins/lazyCompilation.d.ts +2 -0
- package/dist-types/plugins/manifest.d.ts +2 -0
- package/dist-types/plugins/minimize.d.ts +10 -0
- package/dist-types/plugins/moduleFederation.d.ts +2 -0
- package/dist-types/plugins/moment.d.ts +2 -0
- package/dist-types/plugins/nodeAddons.d.ts +2 -0
- package/dist-types/plugins/nonce.d.ts +2 -0
- package/dist-types/plugins/output.d.ts +2 -0
- package/dist-types/plugins/performance.d.ts +5 -0
- package/dist-types/plugins/progress.d.ts +2 -0
- package/dist-types/plugins/resolve.d.ts +2 -0
- package/dist-types/plugins/resourceHints.d.ts +2 -0
- package/dist-types/plugins/rsdoctor.d.ts +2 -0
- package/dist-types/plugins/rspackProfile.d.ts +2 -0
- package/dist-types/plugins/server.d.ts +2 -0
- package/dist-types/plugins/sourceMap.d.ts +2 -0
- package/dist-types/plugins/splitChunks.d.ts +4 -0
- package/dist-types/plugins/sri.d.ts +2 -0
- package/dist-types/plugins/swc.d.ts +5 -0
- package/dist-types/plugins/target.d.ts +2 -0
- package/dist-types/plugins/wasm.d.ts +2 -0
- package/dist-types/provider/build.d.ts +4 -0
- package/dist-types/provider/createCompiler.d.ts +6 -0
- package/dist-types/provider/helpers.d.ts +12 -0
- package/dist-types/provider/initConfigs.d.ts +19 -0
- package/dist-types/provider/provider.d.ts +2 -0
- package/dist-types/provider/rspackConfig.d.ts +8 -0
- package/dist-types/restart.d.ts +18 -0
- package/dist-types/rspack-plugins/RsbuildHtmlPlugin.d.ts +38 -0
- package/dist-types/rspack-plugins/resource-hints/HtmlResourceHintsPlugin.d.ts +32 -0
- package/dist-types/rspack-plugins/resource-hints/doesChunkBelongToHtml.d.ts +28 -0
- package/dist-types/rspack-plugins/resource-hints/extractChunks.d.ts +23 -0
- package/dist-types/rspack-plugins/resource-hints/getResourceType.d.ts +22 -0
- package/dist-types/rspack.d.ts +2 -0
- package/dist-types/server/ansiHTML.d.ts +4 -0
- package/dist-types/server/assets-middleware/getFileFromUrl.d.ts +12 -0
- package/dist-types/server/assets-middleware/index.d.ts +37 -0
- package/dist-types/server/assets-middleware/middleware.d.ts +2 -0
- package/dist-types/server/assets-middleware/parseTokenList.d.ts +1 -0
- package/dist-types/server/assets-middleware/setupOutputFileSystem.d.ts +3 -0
- package/dist-types/server/assets-middleware/setupWriteToDisk.d.ts +15 -0
- package/dist-types/server/browserLogs.d.ts +9 -0
- package/dist-types/server/buildManager.d.ts +33 -0
- package/dist-types/server/cliShortcuts.d.ts +10 -0
- package/dist-types/server/devMiddlewares.d.ts +21 -0
- package/dist-types/server/devServer.d.ts +79 -0
- package/dist-types/server/environment.d.ts +8 -0
- package/dist-types/server/gracefulShutdown.d.ts +10 -0
- package/dist-types/server/gzipMiddleware.d.ts +2 -0
- package/dist-types/server/helper.d.ts +91 -0
- package/dist-types/server/historyApiFallback.d.ts +2 -0
- package/dist-types/server/hmrFallback.d.ts +1 -0
- package/dist-types/server/httpServer.d.ts +7 -0
- package/dist-types/server/middlewares.d.ts +33 -0
- package/dist-types/server/open.d.ts +10 -0
- package/dist-types/server/overlay.d.ts +3 -0
- package/dist-types/server/prodServer.d.ts +24 -0
- package/dist-types/server/proxy.d.ts +6 -0
- package/dist-types/server/runner/asModule.d.ts +2 -0
- package/dist-types/server/runner/basic.d.ts +29 -0
- package/dist-types/server/runner/cjs.d.ts +10 -0
- package/dist-types/server/runner/esm.d.ts +6 -0
- package/dist-types/server/runner/index.d.ts +4 -0
- package/dist-types/server/runner/type.d.ts +42 -0
- package/dist-types/server/socketServer.d.ts +81 -0
- package/dist-types/server/watchFiles.d.ts +14 -0
- package/dist-types/types/config.d.ts +1882 -0
- package/dist-types/types/context.d.ts +110 -0
- package/dist-types/types/hooks.d.ts +275 -0
- package/dist-types/types/index.d.ts +8 -0
- package/dist-types/types/plugin.d.ts +585 -0
- package/dist-types/types/rsbuild.d.ts +286 -0
- package/dist-types/types/rspack.d.ts +16 -0
- package/dist-types/types/thirdParty.d.ts +186 -0
- package/dist-types/types/utils.d.ts +19 -0
- package/package.json +114 -0
- package/static/openChrome.applescript +95 -0
- package/types.d.ts +349 -0
|
@@ -0,0 +1,1222 @@
|
|
|
1
|
+
(() => {
|
|
2
|
+
var __webpack_modules__ = {
|
|
3
|
+
284: function (module, __unused_webpack_exports, __nccwpck_require__) {
|
|
4
|
+
module = __nccwpck_require__.nmd(module);
|
|
5
|
+
(function (global, factory) {
|
|
6
|
+
if (true) {
|
|
7
|
+
factory(module, __nccwpck_require__(73), __nccwpck_require__(462));
|
|
8
|
+
module.exports = def(module);
|
|
9
|
+
} else {
|
|
10
|
+
}
|
|
11
|
+
function def(m) {
|
|
12
|
+
return "default" in m.exports ? m.exports.default : m.exports;
|
|
13
|
+
}
|
|
14
|
+
})(this, function (module, require_sourcemapCodec, require_traceMapping) {
|
|
15
|
+
"use strict";
|
|
16
|
+
var __create = Object.create;
|
|
17
|
+
var __defProp = Object.defineProperty;
|
|
18
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
19
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
20
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
21
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
22
|
+
var __commonJS = (cb, mod) =>
|
|
23
|
+
function __require() {
|
|
24
|
+
return (
|
|
25
|
+
mod ||
|
|
26
|
+
(0, cb[__getOwnPropNames(cb)[0]])(
|
|
27
|
+
(mod = { exports: {} }).exports,
|
|
28
|
+
mod,
|
|
29
|
+
),
|
|
30
|
+
mod.exports
|
|
31
|
+
);
|
|
32
|
+
};
|
|
33
|
+
var __export = (target, all) => {
|
|
34
|
+
for (var name in all)
|
|
35
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
36
|
+
};
|
|
37
|
+
var __copyProps = (to, from, except, desc) => {
|
|
38
|
+
if (
|
|
39
|
+
(from && typeof from === "object") ||
|
|
40
|
+
typeof from === "function"
|
|
41
|
+
) {
|
|
42
|
+
for (let key of __getOwnPropNames(from))
|
|
43
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
44
|
+
__defProp(to, key, {
|
|
45
|
+
get: () => from[key],
|
|
46
|
+
enumerable:
|
|
47
|
+
!(desc = __getOwnPropDesc(from, key)) || desc.enumerable,
|
|
48
|
+
});
|
|
49
|
+
}
|
|
50
|
+
return to;
|
|
51
|
+
};
|
|
52
|
+
var __toESM = (mod, isNodeMode, target) => (
|
|
53
|
+
(target = mod != null ? __create(__getProtoOf(mod)) : {}),
|
|
54
|
+
__copyProps(
|
|
55
|
+
isNodeMode || !mod || !mod.__esModule
|
|
56
|
+
? __defProp(target, "default", { value: mod, enumerable: true })
|
|
57
|
+
: target,
|
|
58
|
+
mod,
|
|
59
|
+
)
|
|
60
|
+
);
|
|
61
|
+
var __toCommonJS = (mod) =>
|
|
62
|
+
__copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
63
|
+
var require_sourcemap_codec = __commonJS({
|
|
64
|
+
"umd:@jridgewell/sourcemap-codec"(exports, module2) {
|
|
65
|
+
module2.exports = require_sourcemapCodec;
|
|
66
|
+
},
|
|
67
|
+
});
|
|
68
|
+
var require_trace_mapping = __commonJS({
|
|
69
|
+
"umd:@jridgewell/trace-mapping"(exports, module2) {
|
|
70
|
+
module2.exports = require_traceMapping;
|
|
71
|
+
},
|
|
72
|
+
});
|
|
73
|
+
var gen_mapping_exports = {};
|
|
74
|
+
__export(gen_mapping_exports, {
|
|
75
|
+
GenMapping: () => GenMapping,
|
|
76
|
+
addMapping: () => addMapping,
|
|
77
|
+
addSegment: () => addSegment,
|
|
78
|
+
allMappings: () => allMappings,
|
|
79
|
+
fromMap: () => fromMap,
|
|
80
|
+
maybeAddMapping: () => maybeAddMapping,
|
|
81
|
+
maybeAddSegment: () => maybeAddSegment,
|
|
82
|
+
setIgnore: () => setIgnore,
|
|
83
|
+
setSourceContent: () => setSourceContent,
|
|
84
|
+
toDecodedMap: () => toDecodedMap,
|
|
85
|
+
toEncodedMap: () => toEncodedMap,
|
|
86
|
+
});
|
|
87
|
+
module.exports = __toCommonJS(gen_mapping_exports);
|
|
88
|
+
var SetArray = class {
|
|
89
|
+
constructor() {
|
|
90
|
+
this._indexes = { __proto__: null };
|
|
91
|
+
this.array = [];
|
|
92
|
+
}
|
|
93
|
+
};
|
|
94
|
+
function cast(set) {
|
|
95
|
+
return set;
|
|
96
|
+
}
|
|
97
|
+
function get(setarr, key) {
|
|
98
|
+
return cast(setarr)._indexes[key];
|
|
99
|
+
}
|
|
100
|
+
function put(setarr, key) {
|
|
101
|
+
const index = get(setarr, key);
|
|
102
|
+
if (index !== void 0) return index;
|
|
103
|
+
const { array, _indexes: indexes } = cast(setarr);
|
|
104
|
+
const length = array.push(key);
|
|
105
|
+
return (indexes[key] = length - 1);
|
|
106
|
+
}
|
|
107
|
+
function remove(setarr, key) {
|
|
108
|
+
const index = get(setarr, key);
|
|
109
|
+
if (index === void 0) return;
|
|
110
|
+
const { array, _indexes: indexes } = cast(setarr);
|
|
111
|
+
for (let i = index + 1; i < array.length; i++) {
|
|
112
|
+
const k = array[i];
|
|
113
|
+
array[i - 1] = k;
|
|
114
|
+
indexes[k]--;
|
|
115
|
+
}
|
|
116
|
+
indexes[key] = void 0;
|
|
117
|
+
array.pop();
|
|
118
|
+
}
|
|
119
|
+
var import_sourcemap_codec = __toESM(require_sourcemap_codec());
|
|
120
|
+
var import_trace_mapping = __toESM(require_trace_mapping());
|
|
121
|
+
var COLUMN = 0;
|
|
122
|
+
var SOURCES_INDEX = 1;
|
|
123
|
+
var SOURCE_LINE = 2;
|
|
124
|
+
var SOURCE_COLUMN = 3;
|
|
125
|
+
var NAMES_INDEX = 4;
|
|
126
|
+
var NO_NAME = -1;
|
|
127
|
+
var GenMapping = class {
|
|
128
|
+
constructor({ file, sourceRoot } = {}) {
|
|
129
|
+
this._names = new SetArray();
|
|
130
|
+
this._sources = new SetArray();
|
|
131
|
+
this._sourcesContent = [];
|
|
132
|
+
this._mappings = [];
|
|
133
|
+
this.file = file;
|
|
134
|
+
this.sourceRoot = sourceRoot;
|
|
135
|
+
this._ignoreList = new SetArray();
|
|
136
|
+
}
|
|
137
|
+
};
|
|
138
|
+
function cast2(map) {
|
|
139
|
+
return map;
|
|
140
|
+
}
|
|
141
|
+
function addSegment(
|
|
142
|
+
map,
|
|
143
|
+
genLine,
|
|
144
|
+
genColumn,
|
|
145
|
+
source,
|
|
146
|
+
sourceLine,
|
|
147
|
+
sourceColumn,
|
|
148
|
+
name,
|
|
149
|
+
content,
|
|
150
|
+
) {
|
|
151
|
+
return addSegmentInternal(
|
|
152
|
+
false,
|
|
153
|
+
map,
|
|
154
|
+
genLine,
|
|
155
|
+
genColumn,
|
|
156
|
+
source,
|
|
157
|
+
sourceLine,
|
|
158
|
+
sourceColumn,
|
|
159
|
+
name,
|
|
160
|
+
content,
|
|
161
|
+
);
|
|
162
|
+
}
|
|
163
|
+
function addMapping(map, mapping) {
|
|
164
|
+
return addMappingInternal(false, map, mapping);
|
|
165
|
+
}
|
|
166
|
+
var maybeAddSegment = (
|
|
167
|
+
map,
|
|
168
|
+
genLine,
|
|
169
|
+
genColumn,
|
|
170
|
+
source,
|
|
171
|
+
sourceLine,
|
|
172
|
+
sourceColumn,
|
|
173
|
+
name,
|
|
174
|
+
content,
|
|
175
|
+
) =>
|
|
176
|
+
addSegmentInternal(
|
|
177
|
+
true,
|
|
178
|
+
map,
|
|
179
|
+
genLine,
|
|
180
|
+
genColumn,
|
|
181
|
+
source,
|
|
182
|
+
sourceLine,
|
|
183
|
+
sourceColumn,
|
|
184
|
+
name,
|
|
185
|
+
content,
|
|
186
|
+
);
|
|
187
|
+
var maybeAddMapping = (map, mapping) =>
|
|
188
|
+
addMappingInternal(true, map, mapping);
|
|
189
|
+
function setSourceContent(map, source, content) {
|
|
190
|
+
const { _sources: sources, _sourcesContent: sourcesContent } =
|
|
191
|
+
cast2(map);
|
|
192
|
+
const index = put(sources, source);
|
|
193
|
+
sourcesContent[index] = content;
|
|
194
|
+
}
|
|
195
|
+
function setIgnore(map, source, ignore = true) {
|
|
196
|
+
const {
|
|
197
|
+
_sources: sources,
|
|
198
|
+
_sourcesContent: sourcesContent,
|
|
199
|
+
_ignoreList: ignoreList,
|
|
200
|
+
} = cast2(map);
|
|
201
|
+
const index = put(sources, source);
|
|
202
|
+
if (index === sourcesContent.length) sourcesContent[index] = null;
|
|
203
|
+
if (ignore) put(ignoreList, index);
|
|
204
|
+
else remove(ignoreList, index);
|
|
205
|
+
}
|
|
206
|
+
function toDecodedMap(map) {
|
|
207
|
+
const {
|
|
208
|
+
_mappings: mappings,
|
|
209
|
+
_sources: sources,
|
|
210
|
+
_sourcesContent: sourcesContent,
|
|
211
|
+
_names: names,
|
|
212
|
+
_ignoreList: ignoreList,
|
|
213
|
+
} = cast2(map);
|
|
214
|
+
removeEmptyFinalLines(mappings);
|
|
215
|
+
return {
|
|
216
|
+
version: 3,
|
|
217
|
+
file: map.file || void 0,
|
|
218
|
+
names: names.array,
|
|
219
|
+
sourceRoot: map.sourceRoot || void 0,
|
|
220
|
+
sources: sources.array,
|
|
221
|
+
sourcesContent,
|
|
222
|
+
mappings,
|
|
223
|
+
ignoreList: ignoreList.array,
|
|
224
|
+
};
|
|
225
|
+
}
|
|
226
|
+
function toEncodedMap(map) {
|
|
227
|
+
const decoded = toDecodedMap(map);
|
|
228
|
+
return Object.assign({}, decoded, {
|
|
229
|
+
mappings: (0, import_sourcemap_codec.encode)(decoded.mappings),
|
|
230
|
+
});
|
|
231
|
+
}
|
|
232
|
+
function fromMap(input) {
|
|
233
|
+
const map = new import_trace_mapping.TraceMap(input);
|
|
234
|
+
const gen = new GenMapping({
|
|
235
|
+
file: map.file,
|
|
236
|
+
sourceRoot: map.sourceRoot,
|
|
237
|
+
});
|
|
238
|
+
putAll(cast2(gen)._names, map.names);
|
|
239
|
+
putAll(cast2(gen)._sources, map.sources);
|
|
240
|
+
cast2(gen)._sourcesContent =
|
|
241
|
+
map.sourcesContent || map.sources.map(() => null);
|
|
242
|
+
cast2(gen)._mappings = (0, import_trace_mapping.decodedMappings)(map);
|
|
243
|
+
if (map.ignoreList) putAll(cast2(gen)._ignoreList, map.ignoreList);
|
|
244
|
+
return gen;
|
|
245
|
+
}
|
|
246
|
+
function allMappings(map) {
|
|
247
|
+
const out = [];
|
|
248
|
+
const {
|
|
249
|
+
_mappings: mappings,
|
|
250
|
+
_sources: sources,
|
|
251
|
+
_names: names,
|
|
252
|
+
} = cast2(map);
|
|
253
|
+
for (let i = 0; i < mappings.length; i++) {
|
|
254
|
+
const line = mappings[i];
|
|
255
|
+
for (let j = 0; j < line.length; j++) {
|
|
256
|
+
const seg = line[j];
|
|
257
|
+
const generated = { line: i + 1, column: seg[COLUMN] };
|
|
258
|
+
let source = void 0;
|
|
259
|
+
let original = void 0;
|
|
260
|
+
let name = void 0;
|
|
261
|
+
if (seg.length !== 1) {
|
|
262
|
+
source = sources.array[seg[SOURCES_INDEX]];
|
|
263
|
+
original = {
|
|
264
|
+
line: seg[SOURCE_LINE] + 1,
|
|
265
|
+
column: seg[SOURCE_COLUMN],
|
|
266
|
+
};
|
|
267
|
+
if (seg.length === 5) name = names.array[seg[NAMES_INDEX]];
|
|
268
|
+
}
|
|
269
|
+
out.push({ generated, source, original, name });
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
return out;
|
|
273
|
+
}
|
|
274
|
+
function addSegmentInternal(
|
|
275
|
+
skipable,
|
|
276
|
+
map,
|
|
277
|
+
genLine,
|
|
278
|
+
genColumn,
|
|
279
|
+
source,
|
|
280
|
+
sourceLine,
|
|
281
|
+
sourceColumn,
|
|
282
|
+
name,
|
|
283
|
+
content,
|
|
284
|
+
) {
|
|
285
|
+
const {
|
|
286
|
+
_mappings: mappings,
|
|
287
|
+
_sources: sources,
|
|
288
|
+
_sourcesContent: sourcesContent,
|
|
289
|
+
_names: names,
|
|
290
|
+
} = cast2(map);
|
|
291
|
+
const line = getIndex(mappings, genLine);
|
|
292
|
+
const index = getColumnIndex(line, genColumn);
|
|
293
|
+
if (!source) {
|
|
294
|
+
if (skipable && skipSourceless(line, index)) return;
|
|
295
|
+
return insert(line, index, [genColumn]);
|
|
296
|
+
}
|
|
297
|
+
assert(sourceLine);
|
|
298
|
+
assert(sourceColumn);
|
|
299
|
+
const sourcesIndex = put(sources, source);
|
|
300
|
+
const namesIndex = name ? put(names, name) : NO_NAME;
|
|
301
|
+
if (sourcesIndex === sourcesContent.length)
|
|
302
|
+
sourcesContent[sourcesIndex] = content != null ? content : null;
|
|
303
|
+
if (
|
|
304
|
+
skipable &&
|
|
305
|
+
skipSource(
|
|
306
|
+
line,
|
|
307
|
+
index,
|
|
308
|
+
sourcesIndex,
|
|
309
|
+
sourceLine,
|
|
310
|
+
sourceColumn,
|
|
311
|
+
namesIndex,
|
|
312
|
+
)
|
|
313
|
+
) {
|
|
314
|
+
return;
|
|
315
|
+
}
|
|
316
|
+
return insert(
|
|
317
|
+
line,
|
|
318
|
+
index,
|
|
319
|
+
name
|
|
320
|
+
? [genColumn, sourcesIndex, sourceLine, sourceColumn, namesIndex]
|
|
321
|
+
: [genColumn, sourcesIndex, sourceLine, sourceColumn],
|
|
322
|
+
);
|
|
323
|
+
}
|
|
324
|
+
function assert(_val) {}
|
|
325
|
+
function getIndex(arr, index) {
|
|
326
|
+
for (let i = arr.length; i <= index; i++) {
|
|
327
|
+
arr[i] = [];
|
|
328
|
+
}
|
|
329
|
+
return arr[index];
|
|
330
|
+
}
|
|
331
|
+
function getColumnIndex(line, genColumn) {
|
|
332
|
+
let index = line.length;
|
|
333
|
+
for (let i = index - 1; i >= 0; index = i--) {
|
|
334
|
+
const current = line[i];
|
|
335
|
+
if (genColumn >= current[COLUMN]) break;
|
|
336
|
+
}
|
|
337
|
+
return index;
|
|
338
|
+
}
|
|
339
|
+
function insert(array, index, value) {
|
|
340
|
+
for (let i = array.length; i > index; i--) {
|
|
341
|
+
array[i] = array[i - 1];
|
|
342
|
+
}
|
|
343
|
+
array[index] = value;
|
|
344
|
+
}
|
|
345
|
+
function removeEmptyFinalLines(mappings) {
|
|
346
|
+
const { length } = mappings;
|
|
347
|
+
let len = length;
|
|
348
|
+
for (let i = len - 1; i >= 0; len = i, i--) {
|
|
349
|
+
if (mappings[i].length > 0) break;
|
|
350
|
+
}
|
|
351
|
+
if (len < length) mappings.length = len;
|
|
352
|
+
}
|
|
353
|
+
function putAll(setarr, array) {
|
|
354
|
+
for (let i = 0; i < array.length; i++) put(setarr, array[i]);
|
|
355
|
+
}
|
|
356
|
+
function skipSourceless(line, index) {
|
|
357
|
+
if (index === 0) return true;
|
|
358
|
+
const prev = line[index - 1];
|
|
359
|
+
return prev.length === 1;
|
|
360
|
+
}
|
|
361
|
+
function skipSource(
|
|
362
|
+
line,
|
|
363
|
+
index,
|
|
364
|
+
sourcesIndex,
|
|
365
|
+
sourceLine,
|
|
366
|
+
sourceColumn,
|
|
367
|
+
namesIndex,
|
|
368
|
+
) {
|
|
369
|
+
if (index === 0) return false;
|
|
370
|
+
const prev = line[index - 1];
|
|
371
|
+
if (prev.length === 1) return false;
|
|
372
|
+
return (
|
|
373
|
+
sourcesIndex === prev[SOURCES_INDEX] &&
|
|
374
|
+
sourceLine === prev[SOURCE_LINE] &&
|
|
375
|
+
sourceColumn === prev[SOURCE_COLUMN] &&
|
|
376
|
+
namesIndex === (prev.length === 5 ? prev[NAMES_INDEX] : NO_NAME)
|
|
377
|
+
);
|
|
378
|
+
}
|
|
379
|
+
function addMappingInternal(skipable, map, mapping) {
|
|
380
|
+
const { generated, source, original, name, content } = mapping;
|
|
381
|
+
if (!source) {
|
|
382
|
+
return addSegmentInternal(
|
|
383
|
+
skipable,
|
|
384
|
+
map,
|
|
385
|
+
generated.line - 1,
|
|
386
|
+
generated.column,
|
|
387
|
+
null,
|
|
388
|
+
null,
|
|
389
|
+
null,
|
|
390
|
+
null,
|
|
391
|
+
null,
|
|
392
|
+
);
|
|
393
|
+
}
|
|
394
|
+
assert(original);
|
|
395
|
+
return addSegmentInternal(
|
|
396
|
+
skipable,
|
|
397
|
+
map,
|
|
398
|
+
generated.line - 1,
|
|
399
|
+
generated.column,
|
|
400
|
+
source,
|
|
401
|
+
original.line - 1,
|
|
402
|
+
original.column,
|
|
403
|
+
name,
|
|
404
|
+
content,
|
|
405
|
+
);
|
|
406
|
+
}
|
|
407
|
+
});
|
|
408
|
+
},
|
|
409
|
+
767: function (module, __unused_webpack_exports, __nccwpck_require__) {
|
|
410
|
+
module = __nccwpck_require__.nmd(module);
|
|
411
|
+
(function (global, factory) {
|
|
412
|
+
if (true) {
|
|
413
|
+
factory(module, __nccwpck_require__(284), __nccwpck_require__(462));
|
|
414
|
+
module.exports = def(module);
|
|
415
|
+
} else {
|
|
416
|
+
}
|
|
417
|
+
function def(m) {
|
|
418
|
+
return "default" in m.exports ? m.exports.default : m.exports;
|
|
419
|
+
}
|
|
420
|
+
})(this, function (module, require_genMapping, require_traceMapping) {
|
|
421
|
+
"use strict";
|
|
422
|
+
var __create = Object.create;
|
|
423
|
+
var __defProp = Object.defineProperty;
|
|
424
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
425
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
426
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
427
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
428
|
+
var __commonJS = (cb, mod) =>
|
|
429
|
+
function __require() {
|
|
430
|
+
return (
|
|
431
|
+
mod ||
|
|
432
|
+
(0, cb[__getOwnPropNames(cb)[0]])(
|
|
433
|
+
(mod = { exports: {} }).exports,
|
|
434
|
+
mod,
|
|
435
|
+
),
|
|
436
|
+
mod.exports
|
|
437
|
+
);
|
|
438
|
+
};
|
|
439
|
+
var __export = (target, all) => {
|
|
440
|
+
for (var name in all)
|
|
441
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
442
|
+
};
|
|
443
|
+
var __copyProps = (to, from, except, desc) => {
|
|
444
|
+
if (
|
|
445
|
+
(from && typeof from === "object") ||
|
|
446
|
+
typeof from === "function"
|
|
447
|
+
) {
|
|
448
|
+
for (let key of __getOwnPropNames(from))
|
|
449
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
450
|
+
__defProp(to, key, {
|
|
451
|
+
get: () => from[key],
|
|
452
|
+
enumerable:
|
|
453
|
+
!(desc = __getOwnPropDesc(from, key)) || desc.enumerable,
|
|
454
|
+
});
|
|
455
|
+
}
|
|
456
|
+
return to;
|
|
457
|
+
};
|
|
458
|
+
var __toESM = (mod, isNodeMode, target) => (
|
|
459
|
+
(target = mod != null ? __create(__getProtoOf(mod)) : {}),
|
|
460
|
+
__copyProps(
|
|
461
|
+
isNodeMode || !mod || !mod.__esModule
|
|
462
|
+
? __defProp(target, "default", { value: mod, enumerable: true })
|
|
463
|
+
: target,
|
|
464
|
+
mod,
|
|
465
|
+
)
|
|
466
|
+
);
|
|
467
|
+
var __toCommonJS = (mod) =>
|
|
468
|
+
__copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
469
|
+
var require_trace_mapping = __commonJS({
|
|
470
|
+
"umd:@jridgewell/trace-mapping"(exports, module2) {
|
|
471
|
+
module2.exports = require_traceMapping;
|
|
472
|
+
},
|
|
473
|
+
});
|
|
474
|
+
var require_gen_mapping = __commonJS({
|
|
475
|
+
"umd:@jridgewell/gen-mapping"(exports, module2) {
|
|
476
|
+
module2.exports = require_genMapping;
|
|
477
|
+
},
|
|
478
|
+
});
|
|
479
|
+
var remapping_exports = {};
|
|
480
|
+
__export(remapping_exports, { default: () => remapping });
|
|
481
|
+
module.exports = __toCommonJS(remapping_exports);
|
|
482
|
+
var import_trace_mapping2 = __toESM(require_trace_mapping());
|
|
483
|
+
var import_gen_mapping = __toESM(require_gen_mapping());
|
|
484
|
+
var import_trace_mapping = __toESM(require_trace_mapping());
|
|
485
|
+
var SOURCELESS_MAPPING = SegmentObject("", -1, -1, "", null, false);
|
|
486
|
+
var EMPTY_SOURCES = [];
|
|
487
|
+
function SegmentObject(source, line, column, name, content, ignore) {
|
|
488
|
+
return { source, line, column, name, content, ignore };
|
|
489
|
+
}
|
|
490
|
+
function Source(map, sources, source, content, ignore) {
|
|
491
|
+
return { map, sources, source, content, ignore };
|
|
492
|
+
}
|
|
493
|
+
function MapSource(map, sources) {
|
|
494
|
+
return Source(map, sources, "", null, false);
|
|
495
|
+
}
|
|
496
|
+
function OriginalSource(source, content, ignore) {
|
|
497
|
+
return Source(null, EMPTY_SOURCES, source, content, ignore);
|
|
498
|
+
}
|
|
499
|
+
function traceMappings(tree) {
|
|
500
|
+
const gen = new import_gen_mapping.GenMapping({
|
|
501
|
+
file: tree.map.file,
|
|
502
|
+
});
|
|
503
|
+
const { sources: rootSources, map } = tree;
|
|
504
|
+
const rootNames = map.names;
|
|
505
|
+
const rootMappings = (0, import_trace_mapping.decodedMappings)(map);
|
|
506
|
+
for (let i = 0; i < rootMappings.length; i++) {
|
|
507
|
+
const segments = rootMappings[i];
|
|
508
|
+
for (let j = 0; j < segments.length; j++) {
|
|
509
|
+
const segment = segments[j];
|
|
510
|
+
const genCol = segment[0];
|
|
511
|
+
let traced = SOURCELESS_MAPPING;
|
|
512
|
+
if (segment.length !== 1) {
|
|
513
|
+
const source2 = rootSources[segment[1]];
|
|
514
|
+
traced = originalPositionFor(
|
|
515
|
+
source2,
|
|
516
|
+
segment[2],
|
|
517
|
+
segment[3],
|
|
518
|
+
segment.length === 5 ? rootNames[segment[4]] : "",
|
|
519
|
+
);
|
|
520
|
+
if (traced == null) continue;
|
|
521
|
+
}
|
|
522
|
+
const { column, line, name, content, source, ignore } = traced;
|
|
523
|
+
(0, import_gen_mapping.maybeAddSegment)(
|
|
524
|
+
gen,
|
|
525
|
+
i,
|
|
526
|
+
genCol,
|
|
527
|
+
source,
|
|
528
|
+
line,
|
|
529
|
+
column,
|
|
530
|
+
name,
|
|
531
|
+
);
|
|
532
|
+
if (source && content != null)
|
|
533
|
+
(0, import_gen_mapping.setSourceContent)(gen, source, content);
|
|
534
|
+
if (ignore) (0, import_gen_mapping.setIgnore)(gen, source, true);
|
|
535
|
+
}
|
|
536
|
+
}
|
|
537
|
+
return gen;
|
|
538
|
+
}
|
|
539
|
+
function originalPositionFor(source, line, column, name) {
|
|
540
|
+
if (!source.map) {
|
|
541
|
+
return SegmentObject(
|
|
542
|
+
source.source,
|
|
543
|
+
line,
|
|
544
|
+
column,
|
|
545
|
+
name,
|
|
546
|
+
source.content,
|
|
547
|
+
source.ignore,
|
|
548
|
+
);
|
|
549
|
+
}
|
|
550
|
+
const segment = (0, import_trace_mapping.traceSegment)(
|
|
551
|
+
source.map,
|
|
552
|
+
line,
|
|
553
|
+
column,
|
|
554
|
+
);
|
|
555
|
+
if (segment == null) return null;
|
|
556
|
+
if (segment.length === 1) return SOURCELESS_MAPPING;
|
|
557
|
+
return originalPositionFor(
|
|
558
|
+
source.sources[segment[1]],
|
|
559
|
+
segment[2],
|
|
560
|
+
segment[3],
|
|
561
|
+
segment.length === 5 ? source.map.names[segment[4]] : name,
|
|
562
|
+
);
|
|
563
|
+
}
|
|
564
|
+
function asArray(value) {
|
|
565
|
+
if (Array.isArray(value)) return value;
|
|
566
|
+
return [value];
|
|
567
|
+
}
|
|
568
|
+
function buildSourceMapTree(input, loader) {
|
|
569
|
+
const maps = asArray(input).map(
|
|
570
|
+
(m) => new import_trace_mapping2.TraceMap(m, ""),
|
|
571
|
+
);
|
|
572
|
+
const map = maps.pop();
|
|
573
|
+
for (let i = 0; i < maps.length; i++) {
|
|
574
|
+
if (maps[i].sources.length > 1) {
|
|
575
|
+
throw new Error(
|
|
576
|
+
`Transformation map ${i} must have exactly one source file.\nDid you specify these with the most recent transformation maps first?`,
|
|
577
|
+
);
|
|
578
|
+
}
|
|
579
|
+
}
|
|
580
|
+
let tree = build(map, loader, "", 0);
|
|
581
|
+
for (let i = maps.length - 1; i >= 0; i--) {
|
|
582
|
+
tree = MapSource(maps[i], [tree]);
|
|
583
|
+
}
|
|
584
|
+
return tree;
|
|
585
|
+
}
|
|
586
|
+
function build(map, loader, importer, importerDepth) {
|
|
587
|
+
const { resolvedSources, sourcesContent, ignoreList } = map;
|
|
588
|
+
const depth = importerDepth + 1;
|
|
589
|
+
const children = resolvedSources.map((sourceFile, i) => {
|
|
590
|
+
const ctx = {
|
|
591
|
+
importer,
|
|
592
|
+
depth,
|
|
593
|
+
source: sourceFile || "",
|
|
594
|
+
content: void 0,
|
|
595
|
+
ignore: void 0,
|
|
596
|
+
};
|
|
597
|
+
const sourceMap = loader(ctx.source, ctx);
|
|
598
|
+
const { source, content, ignore } = ctx;
|
|
599
|
+
if (sourceMap)
|
|
600
|
+
return build(
|
|
601
|
+
new import_trace_mapping2.TraceMap(sourceMap, source),
|
|
602
|
+
loader,
|
|
603
|
+
source,
|
|
604
|
+
depth,
|
|
605
|
+
);
|
|
606
|
+
const sourceContent =
|
|
607
|
+
content !== void 0
|
|
608
|
+
? content
|
|
609
|
+
: sourcesContent
|
|
610
|
+
? sourcesContent[i]
|
|
611
|
+
: null;
|
|
612
|
+
const ignored =
|
|
613
|
+
ignore !== void 0
|
|
614
|
+
? ignore
|
|
615
|
+
: ignoreList
|
|
616
|
+
? ignoreList.includes(i)
|
|
617
|
+
: false;
|
|
618
|
+
return OriginalSource(source, sourceContent, ignored);
|
|
619
|
+
});
|
|
620
|
+
return MapSource(map, children);
|
|
621
|
+
}
|
|
622
|
+
var import_gen_mapping2 = __toESM(require_gen_mapping());
|
|
623
|
+
var SourceMap = class {
|
|
624
|
+
constructor(map, options) {
|
|
625
|
+
const out = options.decodedMappings
|
|
626
|
+
? (0, import_gen_mapping2.toDecodedMap)(map)
|
|
627
|
+
: (0, import_gen_mapping2.toEncodedMap)(map);
|
|
628
|
+
this.version = out.version;
|
|
629
|
+
this.file = out.file;
|
|
630
|
+
this.mappings = out.mappings;
|
|
631
|
+
this.names = out.names;
|
|
632
|
+
this.ignoreList = out.ignoreList;
|
|
633
|
+
this.sourceRoot = out.sourceRoot;
|
|
634
|
+
this.sources = out.sources;
|
|
635
|
+
if (!options.excludeContent) {
|
|
636
|
+
this.sourcesContent = out.sourcesContent;
|
|
637
|
+
}
|
|
638
|
+
}
|
|
639
|
+
toString() {
|
|
640
|
+
return JSON.stringify(this);
|
|
641
|
+
}
|
|
642
|
+
};
|
|
643
|
+
function remapping(input, loader, options) {
|
|
644
|
+
const opts =
|
|
645
|
+
typeof options === "object"
|
|
646
|
+
? options
|
|
647
|
+
: { excludeContent: !!options, decodedMappings: false };
|
|
648
|
+
const tree = buildSourceMapTree(input, loader);
|
|
649
|
+
return new SourceMap(traceMappings(tree), opts);
|
|
650
|
+
}
|
|
651
|
+
});
|
|
652
|
+
},
|
|
653
|
+
73: function (module, __unused_webpack_exports, __nccwpck_require__) {
|
|
654
|
+
module = __nccwpck_require__.nmd(module);
|
|
655
|
+
(function (global, factory) {
|
|
656
|
+
if (true) {
|
|
657
|
+
factory(module);
|
|
658
|
+
module.exports = def(module);
|
|
659
|
+
} else {
|
|
660
|
+
}
|
|
661
|
+
function def(m) {
|
|
662
|
+
return "default" in m.exports ? m.exports.default : m.exports;
|
|
663
|
+
}
|
|
664
|
+
})(this, function (module) {
|
|
665
|
+
"use strict";
|
|
666
|
+
var __defProp = Object.defineProperty;
|
|
667
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
668
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
669
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
670
|
+
var __export = (target, all) => {
|
|
671
|
+
for (var name in all)
|
|
672
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
673
|
+
};
|
|
674
|
+
var __copyProps = (to, from, except, desc) => {
|
|
675
|
+
if (
|
|
676
|
+
(from && typeof from === "object") ||
|
|
677
|
+
typeof from === "function"
|
|
678
|
+
) {
|
|
679
|
+
for (let key of __getOwnPropNames(from))
|
|
680
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
681
|
+
__defProp(to, key, {
|
|
682
|
+
get: () => from[key],
|
|
683
|
+
enumerable:
|
|
684
|
+
!(desc = __getOwnPropDesc(from, key)) || desc.enumerable,
|
|
685
|
+
});
|
|
686
|
+
}
|
|
687
|
+
return to;
|
|
688
|
+
};
|
|
689
|
+
var __toCommonJS = (mod) =>
|
|
690
|
+
__copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
691
|
+
var sourcemap_codec_exports = {};
|
|
692
|
+
__export(sourcemap_codec_exports, {
|
|
693
|
+
decode: () => decode,
|
|
694
|
+
decodeGeneratedRanges: () => decodeGeneratedRanges,
|
|
695
|
+
decodeOriginalScopes: () => decodeOriginalScopes,
|
|
696
|
+
encode: () => encode,
|
|
697
|
+
encodeGeneratedRanges: () => encodeGeneratedRanges,
|
|
698
|
+
encodeOriginalScopes: () => encodeOriginalScopes,
|
|
699
|
+
});
|
|
700
|
+
module.exports = __toCommonJS(sourcemap_codec_exports);
|
|
701
|
+
var comma = ",".charCodeAt(0);
|
|
702
|
+
var semicolon = ";".charCodeAt(0);
|
|
703
|
+
var chars =
|
|
704
|
+
"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
|
|
705
|
+
var intToChar = new Uint8Array(64);
|
|
706
|
+
var charToInt = new Uint8Array(128);
|
|
707
|
+
for (let i = 0; i < chars.length; i++) {
|
|
708
|
+
const c = chars.charCodeAt(i);
|
|
709
|
+
intToChar[i] = c;
|
|
710
|
+
charToInt[c] = i;
|
|
711
|
+
}
|
|
712
|
+
function decodeInteger(reader, relative) {
|
|
713
|
+
let value = 0;
|
|
714
|
+
let shift = 0;
|
|
715
|
+
let integer = 0;
|
|
716
|
+
do {
|
|
717
|
+
const c = reader.next();
|
|
718
|
+
integer = charToInt[c];
|
|
719
|
+
value |= (integer & 31) << shift;
|
|
720
|
+
shift += 5;
|
|
721
|
+
} while (integer & 32);
|
|
722
|
+
const shouldNegate = value & 1;
|
|
723
|
+
value >>>= 1;
|
|
724
|
+
if (shouldNegate) {
|
|
725
|
+
value = -2147483648 | -value;
|
|
726
|
+
}
|
|
727
|
+
return relative + value;
|
|
728
|
+
}
|
|
729
|
+
function encodeInteger(builder, num, relative) {
|
|
730
|
+
let delta = num - relative;
|
|
731
|
+
delta = delta < 0 ? (-delta << 1) | 1 : delta << 1;
|
|
732
|
+
do {
|
|
733
|
+
let clamped = delta & 31;
|
|
734
|
+
delta >>>= 5;
|
|
735
|
+
if (delta > 0) clamped |= 32;
|
|
736
|
+
builder.write(intToChar[clamped]);
|
|
737
|
+
} while (delta > 0);
|
|
738
|
+
return num;
|
|
739
|
+
}
|
|
740
|
+
function hasMoreVlq(reader, max) {
|
|
741
|
+
if (reader.pos >= max) return false;
|
|
742
|
+
return reader.peek() !== comma;
|
|
743
|
+
}
|
|
744
|
+
var bufLength = 1024 * 16;
|
|
745
|
+
var td =
|
|
746
|
+
typeof TextDecoder !== "undefined"
|
|
747
|
+
? new TextDecoder()
|
|
748
|
+
: typeof Buffer !== "undefined"
|
|
749
|
+
? {
|
|
750
|
+
decode(buf) {
|
|
751
|
+
const out = Buffer.from(
|
|
752
|
+
buf.buffer,
|
|
753
|
+
buf.byteOffset,
|
|
754
|
+
buf.byteLength,
|
|
755
|
+
);
|
|
756
|
+
return out.toString();
|
|
757
|
+
},
|
|
758
|
+
}
|
|
759
|
+
: {
|
|
760
|
+
decode(buf) {
|
|
761
|
+
let out = "";
|
|
762
|
+
for (let i = 0; i < buf.length; i++) {
|
|
763
|
+
out += String.fromCharCode(buf[i]);
|
|
764
|
+
}
|
|
765
|
+
return out;
|
|
766
|
+
},
|
|
767
|
+
};
|
|
768
|
+
var StringWriter = class {
|
|
769
|
+
constructor() {
|
|
770
|
+
this.pos = 0;
|
|
771
|
+
this.out = "";
|
|
772
|
+
this.buffer = new Uint8Array(bufLength);
|
|
773
|
+
}
|
|
774
|
+
write(v) {
|
|
775
|
+
const { buffer } = this;
|
|
776
|
+
buffer[this.pos++] = v;
|
|
777
|
+
if (this.pos === bufLength) {
|
|
778
|
+
this.out += td.decode(buffer);
|
|
779
|
+
this.pos = 0;
|
|
780
|
+
}
|
|
781
|
+
}
|
|
782
|
+
flush() {
|
|
783
|
+
const { buffer, out, pos } = this;
|
|
784
|
+
return pos > 0 ? out + td.decode(buffer.subarray(0, pos)) : out;
|
|
785
|
+
}
|
|
786
|
+
};
|
|
787
|
+
var StringReader = class {
|
|
788
|
+
constructor(buffer) {
|
|
789
|
+
this.pos = 0;
|
|
790
|
+
this.buffer = buffer;
|
|
791
|
+
}
|
|
792
|
+
next() {
|
|
793
|
+
return this.buffer.charCodeAt(this.pos++);
|
|
794
|
+
}
|
|
795
|
+
peek() {
|
|
796
|
+
return this.buffer.charCodeAt(this.pos);
|
|
797
|
+
}
|
|
798
|
+
indexOf(char) {
|
|
799
|
+
const { buffer, pos } = this;
|
|
800
|
+
const idx = buffer.indexOf(char, pos);
|
|
801
|
+
return idx === -1 ? buffer.length : idx;
|
|
802
|
+
}
|
|
803
|
+
};
|
|
804
|
+
var EMPTY = [];
|
|
805
|
+
function decodeOriginalScopes(input) {
|
|
806
|
+
const { length } = input;
|
|
807
|
+
const reader = new StringReader(input);
|
|
808
|
+
const scopes = [];
|
|
809
|
+
const stack = [];
|
|
810
|
+
let line = 0;
|
|
811
|
+
for (; reader.pos < length; reader.pos++) {
|
|
812
|
+
line = decodeInteger(reader, line);
|
|
813
|
+
const column = decodeInteger(reader, 0);
|
|
814
|
+
if (!hasMoreVlq(reader, length)) {
|
|
815
|
+
const last = stack.pop();
|
|
816
|
+
last[2] = line;
|
|
817
|
+
last[3] = column;
|
|
818
|
+
continue;
|
|
819
|
+
}
|
|
820
|
+
const kind = decodeInteger(reader, 0);
|
|
821
|
+
const fields = decodeInteger(reader, 0);
|
|
822
|
+
const hasName = fields & 1;
|
|
823
|
+
const scope = hasName
|
|
824
|
+
? [line, column, 0, 0, kind, decodeInteger(reader, 0)]
|
|
825
|
+
: [line, column, 0, 0, kind];
|
|
826
|
+
let vars = EMPTY;
|
|
827
|
+
if (hasMoreVlq(reader, length)) {
|
|
828
|
+
vars = [];
|
|
829
|
+
do {
|
|
830
|
+
const varsIndex = decodeInteger(reader, 0);
|
|
831
|
+
vars.push(varsIndex);
|
|
832
|
+
} while (hasMoreVlq(reader, length));
|
|
833
|
+
}
|
|
834
|
+
scope.vars = vars;
|
|
835
|
+
scopes.push(scope);
|
|
836
|
+
stack.push(scope);
|
|
837
|
+
}
|
|
838
|
+
return scopes;
|
|
839
|
+
}
|
|
840
|
+
function encodeOriginalScopes(scopes) {
|
|
841
|
+
const writer = new StringWriter();
|
|
842
|
+
for (let i = 0; i < scopes.length; ) {
|
|
843
|
+
i = _encodeOriginalScopes(scopes, i, writer, [0]);
|
|
844
|
+
}
|
|
845
|
+
return writer.flush();
|
|
846
|
+
}
|
|
847
|
+
function _encodeOriginalScopes(scopes, index, writer, state) {
|
|
848
|
+
const scope = scopes[index];
|
|
849
|
+
const {
|
|
850
|
+
0: startLine,
|
|
851
|
+
1: startColumn,
|
|
852
|
+
2: endLine,
|
|
853
|
+
3: endColumn,
|
|
854
|
+
4: kind,
|
|
855
|
+
vars,
|
|
856
|
+
} = scope;
|
|
857
|
+
if (index > 0) writer.write(comma);
|
|
858
|
+
state[0] = encodeInteger(writer, startLine, state[0]);
|
|
859
|
+
encodeInteger(writer, startColumn, 0);
|
|
860
|
+
encodeInteger(writer, kind, 0);
|
|
861
|
+
const fields = scope.length === 6 ? 1 : 0;
|
|
862
|
+
encodeInteger(writer, fields, 0);
|
|
863
|
+
if (scope.length === 6) encodeInteger(writer, scope[5], 0);
|
|
864
|
+
for (const v of vars) {
|
|
865
|
+
encodeInteger(writer, v, 0);
|
|
866
|
+
}
|
|
867
|
+
for (index++; index < scopes.length; ) {
|
|
868
|
+
const next = scopes[index];
|
|
869
|
+
const { 0: l, 1: c } = next;
|
|
870
|
+
if (l > endLine || (l === endLine && c >= endColumn)) {
|
|
871
|
+
break;
|
|
872
|
+
}
|
|
873
|
+
index = _encodeOriginalScopes(scopes, index, writer, state);
|
|
874
|
+
}
|
|
875
|
+
writer.write(comma);
|
|
876
|
+
state[0] = encodeInteger(writer, endLine, state[0]);
|
|
877
|
+
encodeInteger(writer, endColumn, 0);
|
|
878
|
+
return index;
|
|
879
|
+
}
|
|
880
|
+
function decodeGeneratedRanges(input) {
|
|
881
|
+
const { length } = input;
|
|
882
|
+
const reader = new StringReader(input);
|
|
883
|
+
const ranges = [];
|
|
884
|
+
const stack = [];
|
|
885
|
+
let genLine = 0;
|
|
886
|
+
let definitionSourcesIndex = 0;
|
|
887
|
+
let definitionScopeIndex = 0;
|
|
888
|
+
let callsiteSourcesIndex = 0;
|
|
889
|
+
let callsiteLine = 0;
|
|
890
|
+
let callsiteColumn = 0;
|
|
891
|
+
let bindingLine = 0;
|
|
892
|
+
let bindingColumn = 0;
|
|
893
|
+
do {
|
|
894
|
+
const semi = reader.indexOf(";");
|
|
895
|
+
let genColumn = 0;
|
|
896
|
+
for (; reader.pos < semi; reader.pos++) {
|
|
897
|
+
genColumn = decodeInteger(reader, genColumn);
|
|
898
|
+
if (!hasMoreVlq(reader, semi)) {
|
|
899
|
+
const last = stack.pop();
|
|
900
|
+
last[2] = genLine;
|
|
901
|
+
last[3] = genColumn;
|
|
902
|
+
continue;
|
|
903
|
+
}
|
|
904
|
+
const fields = decodeInteger(reader, 0);
|
|
905
|
+
const hasDefinition = fields & 1;
|
|
906
|
+
const hasCallsite = fields & 2;
|
|
907
|
+
const hasScope = fields & 4;
|
|
908
|
+
let callsite = null;
|
|
909
|
+
let bindings = EMPTY;
|
|
910
|
+
let range;
|
|
911
|
+
if (hasDefinition) {
|
|
912
|
+
const defSourcesIndex = decodeInteger(
|
|
913
|
+
reader,
|
|
914
|
+
definitionSourcesIndex,
|
|
915
|
+
);
|
|
916
|
+
definitionScopeIndex = decodeInteger(
|
|
917
|
+
reader,
|
|
918
|
+
definitionSourcesIndex === defSourcesIndex
|
|
919
|
+
? definitionScopeIndex
|
|
920
|
+
: 0,
|
|
921
|
+
);
|
|
922
|
+
definitionSourcesIndex = defSourcesIndex;
|
|
923
|
+
range = [
|
|
924
|
+
genLine,
|
|
925
|
+
genColumn,
|
|
926
|
+
0,
|
|
927
|
+
0,
|
|
928
|
+
defSourcesIndex,
|
|
929
|
+
definitionScopeIndex,
|
|
930
|
+
];
|
|
931
|
+
} else {
|
|
932
|
+
range = [genLine, genColumn, 0, 0];
|
|
933
|
+
}
|
|
934
|
+
range.isScope = !!hasScope;
|
|
935
|
+
if (hasCallsite) {
|
|
936
|
+
const prevCsi = callsiteSourcesIndex;
|
|
937
|
+
const prevLine = callsiteLine;
|
|
938
|
+
callsiteSourcesIndex = decodeInteger(
|
|
939
|
+
reader,
|
|
940
|
+
callsiteSourcesIndex,
|
|
941
|
+
);
|
|
942
|
+
const sameSource = prevCsi === callsiteSourcesIndex;
|
|
943
|
+
callsiteLine = decodeInteger(
|
|
944
|
+
reader,
|
|
945
|
+
sameSource ? callsiteLine : 0,
|
|
946
|
+
);
|
|
947
|
+
callsiteColumn = decodeInteger(
|
|
948
|
+
reader,
|
|
949
|
+
sameSource && prevLine === callsiteLine ? callsiteColumn : 0,
|
|
950
|
+
);
|
|
951
|
+
callsite = [callsiteSourcesIndex, callsiteLine, callsiteColumn];
|
|
952
|
+
}
|
|
953
|
+
range.callsite = callsite;
|
|
954
|
+
if (hasMoreVlq(reader, semi)) {
|
|
955
|
+
bindings = [];
|
|
956
|
+
do {
|
|
957
|
+
bindingLine = genLine;
|
|
958
|
+
bindingColumn = genColumn;
|
|
959
|
+
const expressionsCount = decodeInteger(reader, 0);
|
|
960
|
+
let expressionRanges;
|
|
961
|
+
if (expressionsCount < -1) {
|
|
962
|
+
expressionRanges = [[decodeInteger(reader, 0)]];
|
|
963
|
+
for (let i = -1; i > expressionsCount; i--) {
|
|
964
|
+
const prevBl = bindingLine;
|
|
965
|
+
bindingLine = decodeInteger(reader, bindingLine);
|
|
966
|
+
bindingColumn = decodeInteger(
|
|
967
|
+
reader,
|
|
968
|
+
bindingLine === prevBl ? bindingColumn : 0,
|
|
969
|
+
);
|
|
970
|
+
const expression = decodeInteger(reader, 0);
|
|
971
|
+
expressionRanges.push([
|
|
972
|
+
expression,
|
|
973
|
+
bindingLine,
|
|
974
|
+
bindingColumn,
|
|
975
|
+
]);
|
|
976
|
+
}
|
|
977
|
+
} else {
|
|
978
|
+
expressionRanges = [[expressionsCount]];
|
|
979
|
+
}
|
|
980
|
+
bindings.push(expressionRanges);
|
|
981
|
+
} while (hasMoreVlq(reader, semi));
|
|
982
|
+
}
|
|
983
|
+
range.bindings = bindings;
|
|
984
|
+
ranges.push(range);
|
|
985
|
+
stack.push(range);
|
|
986
|
+
}
|
|
987
|
+
genLine++;
|
|
988
|
+
reader.pos = semi + 1;
|
|
989
|
+
} while (reader.pos < length);
|
|
990
|
+
return ranges;
|
|
991
|
+
}
|
|
992
|
+
function encodeGeneratedRanges(ranges) {
|
|
993
|
+
if (ranges.length === 0) return "";
|
|
994
|
+
const writer = new StringWriter();
|
|
995
|
+
for (let i = 0; i < ranges.length; ) {
|
|
996
|
+
i = _encodeGeneratedRanges(
|
|
997
|
+
ranges,
|
|
998
|
+
i,
|
|
999
|
+
writer,
|
|
1000
|
+
[0, 0, 0, 0, 0, 0, 0],
|
|
1001
|
+
);
|
|
1002
|
+
}
|
|
1003
|
+
return writer.flush();
|
|
1004
|
+
}
|
|
1005
|
+
function _encodeGeneratedRanges(ranges, index, writer, state) {
|
|
1006
|
+
const range = ranges[index];
|
|
1007
|
+
const {
|
|
1008
|
+
0: startLine,
|
|
1009
|
+
1: startColumn,
|
|
1010
|
+
2: endLine,
|
|
1011
|
+
3: endColumn,
|
|
1012
|
+
isScope,
|
|
1013
|
+
callsite,
|
|
1014
|
+
bindings,
|
|
1015
|
+
} = range;
|
|
1016
|
+
if (state[0] < startLine) {
|
|
1017
|
+
catchupLine(writer, state[0], startLine);
|
|
1018
|
+
state[0] = startLine;
|
|
1019
|
+
state[1] = 0;
|
|
1020
|
+
} else if (index > 0) {
|
|
1021
|
+
writer.write(comma);
|
|
1022
|
+
}
|
|
1023
|
+
state[1] = encodeInteger(writer, range[1], state[1]);
|
|
1024
|
+
const fields =
|
|
1025
|
+
(range.length === 6 ? 1 : 0) |
|
|
1026
|
+
(callsite ? 2 : 0) |
|
|
1027
|
+
(isScope ? 4 : 0);
|
|
1028
|
+
encodeInteger(writer, fields, 0);
|
|
1029
|
+
if (range.length === 6) {
|
|
1030
|
+
const { 4: sourcesIndex, 5: scopesIndex } = range;
|
|
1031
|
+
if (sourcesIndex !== state[2]) {
|
|
1032
|
+
state[3] = 0;
|
|
1033
|
+
}
|
|
1034
|
+
state[2] = encodeInteger(writer, sourcesIndex, state[2]);
|
|
1035
|
+
state[3] = encodeInteger(writer, scopesIndex, state[3]);
|
|
1036
|
+
}
|
|
1037
|
+
if (callsite) {
|
|
1038
|
+
const {
|
|
1039
|
+
0: sourcesIndex,
|
|
1040
|
+
1: callLine,
|
|
1041
|
+
2: callColumn,
|
|
1042
|
+
} = range.callsite;
|
|
1043
|
+
if (sourcesIndex !== state[4]) {
|
|
1044
|
+
state[5] = 0;
|
|
1045
|
+
state[6] = 0;
|
|
1046
|
+
} else if (callLine !== state[5]) {
|
|
1047
|
+
state[6] = 0;
|
|
1048
|
+
}
|
|
1049
|
+
state[4] = encodeInteger(writer, sourcesIndex, state[4]);
|
|
1050
|
+
state[5] = encodeInteger(writer, callLine, state[5]);
|
|
1051
|
+
state[6] = encodeInteger(writer, callColumn, state[6]);
|
|
1052
|
+
}
|
|
1053
|
+
if (bindings) {
|
|
1054
|
+
for (const binding of bindings) {
|
|
1055
|
+
if (binding.length > 1) encodeInteger(writer, -binding.length, 0);
|
|
1056
|
+
const expression = binding[0][0];
|
|
1057
|
+
encodeInteger(writer, expression, 0);
|
|
1058
|
+
let bindingStartLine = startLine;
|
|
1059
|
+
let bindingStartColumn = startColumn;
|
|
1060
|
+
for (let i = 1; i < binding.length; i++) {
|
|
1061
|
+
const expRange = binding[i];
|
|
1062
|
+
bindingStartLine = encodeInteger(
|
|
1063
|
+
writer,
|
|
1064
|
+
expRange[1],
|
|
1065
|
+
bindingStartLine,
|
|
1066
|
+
);
|
|
1067
|
+
bindingStartColumn = encodeInteger(
|
|
1068
|
+
writer,
|
|
1069
|
+
expRange[2],
|
|
1070
|
+
bindingStartColumn,
|
|
1071
|
+
);
|
|
1072
|
+
encodeInteger(writer, expRange[0], 0);
|
|
1073
|
+
}
|
|
1074
|
+
}
|
|
1075
|
+
}
|
|
1076
|
+
for (index++; index < ranges.length; ) {
|
|
1077
|
+
const next = ranges[index];
|
|
1078
|
+
const { 0: l, 1: c } = next;
|
|
1079
|
+
if (l > endLine || (l === endLine && c >= endColumn)) {
|
|
1080
|
+
break;
|
|
1081
|
+
}
|
|
1082
|
+
index = _encodeGeneratedRanges(ranges, index, writer, state);
|
|
1083
|
+
}
|
|
1084
|
+
if (state[0] < endLine) {
|
|
1085
|
+
catchupLine(writer, state[0], endLine);
|
|
1086
|
+
state[0] = endLine;
|
|
1087
|
+
state[1] = 0;
|
|
1088
|
+
} else {
|
|
1089
|
+
writer.write(comma);
|
|
1090
|
+
}
|
|
1091
|
+
state[1] = encodeInteger(writer, endColumn, state[1]);
|
|
1092
|
+
return index;
|
|
1093
|
+
}
|
|
1094
|
+
function catchupLine(writer, lastLine, line) {
|
|
1095
|
+
do {
|
|
1096
|
+
writer.write(semicolon);
|
|
1097
|
+
} while (++lastLine < line);
|
|
1098
|
+
}
|
|
1099
|
+
function decode(mappings) {
|
|
1100
|
+
const { length } = mappings;
|
|
1101
|
+
const reader = new StringReader(mappings);
|
|
1102
|
+
const decoded = [];
|
|
1103
|
+
let genColumn = 0;
|
|
1104
|
+
let sourcesIndex = 0;
|
|
1105
|
+
let sourceLine = 0;
|
|
1106
|
+
let sourceColumn = 0;
|
|
1107
|
+
let namesIndex = 0;
|
|
1108
|
+
do {
|
|
1109
|
+
const semi = reader.indexOf(";");
|
|
1110
|
+
const line = [];
|
|
1111
|
+
let sorted = true;
|
|
1112
|
+
let lastCol = 0;
|
|
1113
|
+
genColumn = 0;
|
|
1114
|
+
while (reader.pos < semi) {
|
|
1115
|
+
let seg;
|
|
1116
|
+
genColumn = decodeInteger(reader, genColumn);
|
|
1117
|
+
if (genColumn < lastCol) sorted = false;
|
|
1118
|
+
lastCol = genColumn;
|
|
1119
|
+
if (hasMoreVlq(reader, semi)) {
|
|
1120
|
+
sourcesIndex = decodeInteger(reader, sourcesIndex);
|
|
1121
|
+
sourceLine = decodeInteger(reader, sourceLine);
|
|
1122
|
+
sourceColumn = decodeInteger(reader, sourceColumn);
|
|
1123
|
+
if (hasMoreVlq(reader, semi)) {
|
|
1124
|
+
namesIndex = decodeInteger(reader, namesIndex);
|
|
1125
|
+
seg = [
|
|
1126
|
+
genColumn,
|
|
1127
|
+
sourcesIndex,
|
|
1128
|
+
sourceLine,
|
|
1129
|
+
sourceColumn,
|
|
1130
|
+
namesIndex,
|
|
1131
|
+
];
|
|
1132
|
+
} else {
|
|
1133
|
+
seg = [genColumn, sourcesIndex, sourceLine, sourceColumn];
|
|
1134
|
+
}
|
|
1135
|
+
} else {
|
|
1136
|
+
seg = [genColumn];
|
|
1137
|
+
}
|
|
1138
|
+
line.push(seg);
|
|
1139
|
+
reader.pos++;
|
|
1140
|
+
}
|
|
1141
|
+
if (!sorted) sort(line);
|
|
1142
|
+
decoded.push(line);
|
|
1143
|
+
reader.pos = semi + 1;
|
|
1144
|
+
} while (reader.pos <= length);
|
|
1145
|
+
return decoded;
|
|
1146
|
+
}
|
|
1147
|
+
function sort(line) {
|
|
1148
|
+
line.sort(sortComparator);
|
|
1149
|
+
}
|
|
1150
|
+
function sortComparator(a, b) {
|
|
1151
|
+
return a[0] - b[0];
|
|
1152
|
+
}
|
|
1153
|
+
function encode(decoded) {
|
|
1154
|
+
const writer = new StringWriter();
|
|
1155
|
+
let sourcesIndex = 0;
|
|
1156
|
+
let sourceLine = 0;
|
|
1157
|
+
let sourceColumn = 0;
|
|
1158
|
+
let namesIndex = 0;
|
|
1159
|
+
for (let i = 0; i < decoded.length; i++) {
|
|
1160
|
+
const line = decoded[i];
|
|
1161
|
+
if (i > 0) writer.write(semicolon);
|
|
1162
|
+
if (line.length === 0) continue;
|
|
1163
|
+
let genColumn = 0;
|
|
1164
|
+
for (let j = 0; j < line.length; j++) {
|
|
1165
|
+
const segment = line[j];
|
|
1166
|
+
if (j > 0) writer.write(comma);
|
|
1167
|
+
genColumn = encodeInteger(writer, segment[0], genColumn);
|
|
1168
|
+
if (segment.length === 1) continue;
|
|
1169
|
+
sourcesIndex = encodeInteger(writer, segment[1], sourcesIndex);
|
|
1170
|
+
sourceLine = encodeInteger(writer, segment[2], sourceLine);
|
|
1171
|
+
sourceColumn = encodeInteger(writer, segment[3], sourceColumn);
|
|
1172
|
+
if (segment.length === 4) continue;
|
|
1173
|
+
namesIndex = encodeInteger(writer, segment[4], namesIndex);
|
|
1174
|
+
}
|
|
1175
|
+
}
|
|
1176
|
+
return writer.flush();
|
|
1177
|
+
}
|
|
1178
|
+
});
|
|
1179
|
+
},
|
|
1180
|
+
462: (module) => {
|
|
1181
|
+
"use strict";
|
|
1182
|
+
module.exports = require("../trace-mapping/index.js");
|
|
1183
|
+
},
|
|
1184
|
+
};
|
|
1185
|
+
var __webpack_module_cache__ = {};
|
|
1186
|
+
function __nccwpck_require__(moduleId) {
|
|
1187
|
+
var cachedModule = __webpack_module_cache__[moduleId];
|
|
1188
|
+
if (cachedModule !== undefined) {
|
|
1189
|
+
return cachedModule.exports;
|
|
1190
|
+
}
|
|
1191
|
+
var module = (__webpack_module_cache__[moduleId] = {
|
|
1192
|
+
id: moduleId,
|
|
1193
|
+
loaded: false,
|
|
1194
|
+
exports: {},
|
|
1195
|
+
});
|
|
1196
|
+
var threw = true;
|
|
1197
|
+
try {
|
|
1198
|
+
__webpack_modules__[moduleId].call(
|
|
1199
|
+
module.exports,
|
|
1200
|
+
module,
|
|
1201
|
+
module.exports,
|
|
1202
|
+
__nccwpck_require__,
|
|
1203
|
+
);
|
|
1204
|
+
threw = false;
|
|
1205
|
+
} finally {
|
|
1206
|
+
if (threw) delete __webpack_module_cache__[moduleId];
|
|
1207
|
+
}
|
|
1208
|
+
module.loaded = true;
|
|
1209
|
+
return module.exports;
|
|
1210
|
+
}
|
|
1211
|
+
(() => {
|
|
1212
|
+
__nccwpck_require__.nmd = (module) => {
|
|
1213
|
+
module.paths = [];
|
|
1214
|
+
if (!module.children) module.children = [];
|
|
1215
|
+
return module;
|
|
1216
|
+
};
|
|
1217
|
+
})();
|
|
1218
|
+
if (typeof __nccwpck_require__ !== "undefined")
|
|
1219
|
+
__nccwpck_require__.ab = __dirname + "/";
|
|
1220
|
+
var __webpack_exports__ = __nccwpck_require__(767);
|
|
1221
|
+
module.exports = __webpack_exports__;
|
|
1222
|
+
})();
|