storybook 10.0.0-beta.1 → 10.0.0-beta.11
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/assets/server/openBrowser.applescript +94 -0
- package/dist/_browser-chunks/Color-KPLIACXP.js +1569 -0
- package/dist/_browser-chunks/{WithTooltip-ERFLZL6W.js → WithTooltip-SK46ZJ2J.js} +1 -1
- package/dist/_browser-chunks/{chunk-YY5GICNT.js → chunk-6E2SHJSL.js} +175 -32
- package/dist/_browser-chunks/{chunk-EOILZP2R.js → chunk-BOOOPFZF.js} +7 -2
- package/dist/_browser-chunks/{chunk-YWDKX534.js → chunk-FA42P6MO.js} +49 -4
- package/dist/_browser-chunks/chunk-G33S6YM3.js +521 -0
- package/dist/_browser-chunks/{chunk-MZNYTCNT.js → chunk-HMIIJ6UD.js} +6 -6
- package/dist/_browser-chunks/{chunk-4QPX7WIQ.js → chunk-JJZMHC3A.js} +57 -166
- package/dist/_browser-chunks/{chunk-MD2FTHCZ.js → chunk-JVSKG4YS.js} +3 -16
- package/dist/_browser-chunks/{chunk-E7VLET3C.js → chunk-KSCAWCCE.js} +3947 -4291
- package/dist/_browser-chunks/{chunk-PYK5ZTFK.js → chunk-PS3AOQI4.js} +48 -25
- package/dist/_browser-chunks/chunk-QK3L5AXO.js +372 -0
- package/dist/_browser-chunks/chunk-SHR3NNR3.js +5810 -0
- package/dist/_browser-chunks/{chunk-O5R5CGFA.js → chunk-TMDZCWME.js} +1 -2
- package/dist/_browser-chunks/chunk-VUAFL5XK.js +20 -0
- package/dist/_browser-chunks/{chunk-T7RCAJIX.js → chunk-Y3M7TW6K.js} +43 -47
- package/dist/_browser-chunks/{syntaxhighlighter-YYAA4CS4.js → syntaxhighlighter-R46XOLMC.js} +1 -1
- package/dist/_node-chunks/{builder-manager-EXW4ETLN.js → builder-manager-VLFDK43H.js} +45 -155
- package/dist/_node-chunks/camelcase-RENSEFK6.js +18 -0
- package/dist/_node-chunks/{chunk-5ZX5SJOP.js → chunk-4SPBIDJV.js} +162 -103
- package/dist/_node-chunks/{chunk-PMEEE3UE.js → chunk-4WZFG35Z.js} +30 -21
- package/dist/_node-chunks/{chunk-WP7DV5JT.js → chunk-5K7G6NFK.js} +583 -180
- package/dist/_node-chunks/{chunk-FZP2YGG3.js → chunk-5NSMDC6F.js} +7 -7
- package/dist/_node-chunks/{chunk-6CCUFDHU.js → chunk-5THWZTEL.js} +7 -7
- package/dist/_node-chunks/chunk-7MUMULSR.js +79 -0
- package/dist/_node-chunks/chunk-7QAAJL75.js +1540 -0
- package/dist/_node-chunks/{chunk-EO4S3VXL.js → chunk-DVY3VWHZ.js} +653 -775
- package/dist/_node-chunks/{chunk-WDKWVNL2.js → chunk-EBLOP2C5.js} +7 -7
- package/dist/_node-chunks/{chunk-EDBXIJN5.js → chunk-EF56ZUQY.js} +7 -7
- package/dist/_node-chunks/{chunk-F5J33SXQ.js → chunk-ER2UQBIA.js} +7 -7
- package/dist/_node-chunks/chunk-GHICGP2P.js +18 -0
- package/dist/_node-chunks/{chunk-4WNZYNQY.js → chunk-GYBN5GXT.js} +623 -750
- package/dist/_node-chunks/{chunk-2G5THETV.js → chunk-H2YBWE3T.js} +12 -12
- package/dist/_node-chunks/{camelcase-VZZFWA2L.js → chunk-HYMBYTGJ.js} +9 -8
- package/dist/_node-chunks/{chunk-SUMFFLGF.js → chunk-Q5IJJX3T.js} +6 -6
- package/dist/_node-chunks/{chunk-U45F2NP6.js → chunk-QLRMR54O.js} +7 -7
- package/dist/_node-chunks/{chunk-XTSBFCVE.js → chunk-QSNDRP62.js} +7 -7
- package/dist/_node-chunks/chunk-S2RQAF7K.js +4741 -0
- package/dist/_node-chunks/{chunk-2QZOLZDJ.js → chunk-SDZVOIZI.js} +9 -9
- package/dist/_node-chunks/{chunk-VNLBDN2Z.js → chunk-SGJZDMJW.js} +6 -6
- package/dist/_node-chunks/{chunk-PL2PKDRO.js → chunk-TJOIDMXP.js} +60 -102
- package/dist/_node-chunks/{chunk-ICPKUV5G.js → chunk-U2UIPLJI.js} +7 -7
- package/dist/_node-chunks/{chunk-3SGKBLOL.js → chunk-UAMXREF3.js} +8 -8
- package/dist/_node-chunks/{chunk-GVCXNIAA.js → chunk-UC6O5PNX.js} +399 -116
- package/dist/_node-chunks/{chunk-CM3UGTR5.js → chunk-VFUP6Z4J.js} +7 -7
- package/dist/_node-chunks/{chunk-3ZKQWDCG.js → chunk-XKPJCSPD.js} +223 -243
- package/dist/_node-chunks/{chunk-24TGL6EX.js → chunk-XWCQWB3R.js} +8 -8
- package/dist/_node-chunks/{chunk-QC5FE2D7.js → chunk-XYFEBEHY.js} +7 -7
- package/dist/_node-chunks/chunk-YAEIMHFX.js +62 -0
- package/dist/_node-chunks/{chunk-5V6QH7WC.js → chunk-ZHBCPKYD.js} +7 -7
- package/dist/_node-chunks/{dist-VZL6D6Y3.js → dist-A2RPEHEC.js} +9 -9
- package/dist/_node-chunks/{globby-GZXJJ4W6.js → globby-3TWPXGQS.js} +17 -13
- package/dist/_node-chunks/{lib-PHT5GCV2.js → lib-MUNM6ZJ6.js} +40 -16
- package/dist/_node-chunks/{mdx-N42X6CFJ-EPDIV4A2.js → mdx-N42X6CFJ-QQDHJZQ3.js} +8 -8
- package/dist/_node-chunks/{p-limit-AJIFSZTI.js → p-limit-FEN55OV6.js} +76 -10
- package/dist/_node-chunks/{plugin-3VI56CEF.js → plugin-ESAYNJ5V.js} +11 -11
- package/dist/_node-chunks/{plugin-AV4OEKYM.js → plugin-GDMP3JPR.js} +10 -10
- package/dist/_node-chunks/{webpack-inject-mocker-runtime-plugin-E7J5FKLA.js → webpack-inject-mocker-runtime-plugin-5AKTLYIV.js} +1307 -847
- package/dist/_node-chunks/{webpack-mock-plugin-VTYGW7HO.js → webpack-mock-plugin-AWGZ65AQ.js} +9 -9
- package/dist/babel/index.d.ts +1 -1
- package/dist/babel/index.js +11 -11
- package/dist/bin/core.js +638 -187
- package/dist/bin/dispatcher.js +11 -11
- package/dist/bin/loader.js +77 -12
- package/dist/cli/index.d.ts +62 -75
- package/dist/cli/index.js +67 -55
- package/dist/common/index.d.ts +3 -1
- package/dist/common/index.js +22 -22
- package/dist/components/index.d.ts +228 -1
- package/dist/components/index.js +74 -5738
- package/dist/core-events/index.d.ts +18 -2
- package/dist/core-events/index.js +7 -1
- package/dist/core-server/index.d.ts +515 -14
- package/dist/core-server/index.js +4647 -4182
- package/dist/core-server/presets/common-manager.js +1570 -1272
- package/dist/core-server/presets/common-override-preset.js +9 -9
- package/dist/core-server/presets/common-preset.js +691 -38
- package/dist/core-server/presets/webpack/loaders/storybook-mock-transform-loader.js +9 -9
- package/dist/core-server/presets/webpack/loaders/webpack-automock-loader.js +10 -10
- package/dist/csf/index.d.ts +9 -4
- package/dist/csf/index.js +50 -15
- package/dist/csf-tools/index.d.ts +47 -6
- package/dist/csf-tools/index.js +9 -9
- package/dist/docs-tools/index.js +4 -4
- package/dist/instrumenter/index.js +1 -1
- package/dist/manager/globals-runtime.js +9230 -18109
- package/dist/manager/globals.d.ts +0 -4
- package/dist/manager/globals.js +1 -6
- package/dist/manager/runtime.js +13194 -11367
- package/dist/manager-api/index.d.ts +513 -5
- package/dist/manager-api/index.js +364 -90
- package/dist/manager-errors.d.ts +501 -0
- package/dist/node-logger/index.d.ts +1 -1
- package/dist/node-logger/index.js +1136 -662
- package/dist/preview/globals.js +1 -1
- package/dist/preview/runtime.js +12103 -21579
- package/dist/preview-api/index.d.ts +70 -71
- package/dist/preview-api/index.js +10 -10
- package/dist/preview-errors.d.ts +501 -0
- package/dist/router/index.d.ts +668 -10
- package/dist/router/index.js +2 -2
- package/dist/server-errors.d.ts +501 -0
- package/dist/server-errors.js +10 -10
- package/dist/telemetry/index.d.ts +1 -1
- package/dist/telemetry/index.js +23 -25
- package/dist/test/index.js +1874 -4024
- package/dist/theming/index.d.ts +2 -2
- package/dist/theming/index.js +6 -6
- package/dist/types/index.d.ts +553 -16
- package/dist/viewport/index.d.ts +36 -4
- package/dist/viewport/index.js +1 -1
- package/package.json +9 -46
- package/dist/_browser-chunks/Color-SFYJJKWL.js +0 -605
- package/dist/_browser-chunks/chunk-DHO2SA6L.js +0 -12
- package/dist/_browser-chunks/chunk-WPHPDNUA.js +0 -974
- package/dist/_node-chunks/chunk-32JYCD74.js +0 -80
- package/dist/_node-chunks/chunk-GE6I3YYG.js +0 -62
- package/dist/_node-chunks/chunk-KXCNXWXI.js +0 -18
- package/dist/_node-chunks/chunk-LAUOYAOX.js +0 -87
- package/dist/_node-chunks/chunk-QJTT4OC2.js +0 -266
- package/dist/_node-chunks/chunk-V2ZF4DUD.js +0 -2377
- package/dist/_node-chunks/chunk-ZMV3WY6R.js +0 -9845
- package/dist/_node-chunks/default-browser-id-JNATP42X.js +0 -1719
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_91hxho9jtpf from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_91hxho9jtpf from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_91hxho9jtpf from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_91hxho9jtpf.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_91hxho9jtpf.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_91hxho9jtpf.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
@@ -12,7 +12,7 @@ var require = CJS_COMPAT_NODE_MODULE_nodb7gfupnb.createRequire(import.meta.url);
|
|
|
12
12
|
import {
|
|
13
13
|
__commonJS,
|
|
14
14
|
__name
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-Q5IJJX3T.js";
|
|
16
16
|
|
|
17
17
|
// ../node_modules/@jridgewell/resolve-uri/dist/resolve-uri.umd.js
|
|
18
18
|
var require_resolve_uri_umd = __commonJS({
|
|
@@ -210,14 +210,58 @@ var require_resolve_uri_umd = __commonJS({
|
|
|
210
210
|
var require_sourcemap_codec_umd = __commonJS({
|
|
211
211
|
"../node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.umd.js"(exports, module) {
|
|
212
212
|
(function(global, factory) {
|
|
213
|
-
typeof exports === "object" && typeof module !== "undefined"
|
|
214
|
-
|
|
213
|
+
if (typeof exports === "object" && typeof module !== "undefined") {
|
|
214
|
+
factory(module);
|
|
215
|
+
module.exports = def(module);
|
|
216
|
+
} else if (typeof define === "function" && define.amd) {
|
|
217
|
+
define(["module"], function(mod) {
|
|
218
|
+
factory.apply(this, arguments);
|
|
219
|
+
mod.exports = def(mod);
|
|
220
|
+
});
|
|
221
|
+
} else {
|
|
222
|
+
const mod = { exports: {} };
|
|
223
|
+
factory(mod);
|
|
224
|
+
global = typeof globalThis !== "undefined" ? globalThis : global || self;
|
|
225
|
+
global.sourcemapCodec = def(mod);
|
|
226
|
+
}
|
|
227
|
+
function def(m) {
|
|
228
|
+
return "default" in m.exports ? m.exports.default : m.exports;
|
|
229
|
+
}
|
|
230
|
+
__name(def, "def");
|
|
231
|
+
})(exports, function(module2) {
|
|
215
232
|
"use strict";
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
233
|
+
var __defProp = Object.defineProperty;
|
|
234
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
235
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
236
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
237
|
+
var __export = /* @__PURE__ */ __name((target, all) => {
|
|
238
|
+
for (var name in all)
|
|
239
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
240
|
+
}, "__export");
|
|
241
|
+
var __copyProps = /* @__PURE__ */ __name((to, from, except, desc) => {
|
|
242
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
243
|
+
for (let key of __getOwnPropNames(from))
|
|
244
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
245
|
+
__defProp(to, key, { get: /* @__PURE__ */ __name(() => from[key], "get"), enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
246
|
+
}
|
|
247
|
+
return to;
|
|
248
|
+
}, "__copyProps");
|
|
249
|
+
var __toCommonJS = /* @__PURE__ */ __name((mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod), "__toCommonJS");
|
|
250
|
+
var sourcemap_codec_exports = {};
|
|
251
|
+
__export(sourcemap_codec_exports, {
|
|
252
|
+
decode: /* @__PURE__ */ __name(() => decode, "decode"),
|
|
253
|
+
decodeGeneratedRanges: /* @__PURE__ */ __name(() => decodeGeneratedRanges, "decodeGeneratedRanges"),
|
|
254
|
+
decodeOriginalScopes: /* @__PURE__ */ __name(() => decodeOriginalScopes, "decodeOriginalScopes"),
|
|
255
|
+
encode: /* @__PURE__ */ __name(() => encode, "encode"),
|
|
256
|
+
encodeGeneratedRanges: /* @__PURE__ */ __name(() => encodeGeneratedRanges, "encodeGeneratedRanges"),
|
|
257
|
+
encodeOriginalScopes: /* @__PURE__ */ __name(() => encodeOriginalScopes, "encodeOriginalScopes")
|
|
258
|
+
});
|
|
259
|
+
module2.exports = __toCommonJS(sourcemap_codec_exports);
|
|
260
|
+
var comma = ",".charCodeAt(0);
|
|
261
|
+
var semicolon = ";".charCodeAt(0);
|
|
262
|
+
var chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
|
|
263
|
+
var intToChar = new Uint8Array(64);
|
|
264
|
+
var charToInt = new Uint8Array(128);
|
|
221
265
|
for (let i = 0; i < chars.length; i++) {
|
|
222
266
|
const c = chars.charCodeAt(i);
|
|
223
267
|
intToChar[i] = c;
|
|
@@ -247,21 +291,19 @@ var require_sourcemap_codec_umd = __commonJS({
|
|
|
247
291
|
do {
|
|
248
292
|
let clamped = delta & 31;
|
|
249
293
|
delta >>>= 5;
|
|
250
|
-
if (delta > 0)
|
|
251
|
-
clamped |= 32;
|
|
294
|
+
if (delta > 0) clamped |= 32;
|
|
252
295
|
builder.write(intToChar[clamped]);
|
|
253
296
|
} while (delta > 0);
|
|
254
297
|
return num;
|
|
255
298
|
}
|
|
256
299
|
__name(encodeInteger, "encodeInteger");
|
|
257
300
|
function hasMoreVlq(reader, max) {
|
|
258
|
-
if (reader.pos >= max)
|
|
259
|
-
return false;
|
|
301
|
+
if (reader.pos >= max) return false;
|
|
260
302
|
return reader.peek() !== comma;
|
|
261
303
|
}
|
|
262
304
|
__name(hasMoreVlq, "hasMoreVlq");
|
|
263
|
-
|
|
264
|
-
|
|
305
|
+
var bufLength = 1024 * 16;
|
|
306
|
+
var td = typeof TextDecoder !== "undefined" ? new TextDecoder() : typeof Buffer !== "undefined" ? {
|
|
265
307
|
decode(buf) {
|
|
266
308
|
const out = Buffer.from(buf.buffer, buf.byteOffset, buf.byteLength);
|
|
267
309
|
return out.toString();
|
|
@@ -275,7 +317,7 @@ var require_sourcemap_codec_umd = __commonJS({
|
|
|
275
317
|
return out;
|
|
276
318
|
}
|
|
277
319
|
};
|
|
278
|
-
|
|
320
|
+
var StringWriter = class {
|
|
279
321
|
static {
|
|
280
322
|
__name(this, "StringWriter");
|
|
281
323
|
}
|
|
@@ -296,8 +338,8 @@ var require_sourcemap_codec_umd = __commonJS({
|
|
|
296
338
|
const { buffer, out, pos } = this;
|
|
297
339
|
return pos > 0 ? out + td.decode(buffer.subarray(0, pos)) : out;
|
|
298
340
|
}
|
|
299
|
-
}
|
|
300
|
-
|
|
341
|
+
};
|
|
342
|
+
var StringReader = class {
|
|
301
343
|
static {
|
|
302
344
|
__name(this, "StringReader");
|
|
303
345
|
}
|
|
@@ -316,8 +358,8 @@ var require_sourcemap_codec_umd = __commonJS({
|
|
|
316
358
|
const idx = buffer.indexOf(char, pos);
|
|
317
359
|
return idx === -1 ? buffer.length : idx;
|
|
318
360
|
}
|
|
319
|
-
}
|
|
320
|
-
|
|
361
|
+
};
|
|
362
|
+
var EMPTY = [];
|
|
321
363
|
function decodeOriginalScopes(input) {
|
|
322
364
|
const { length } = input;
|
|
323
365
|
const reader = new StringReader(input);
|
|
@@ -363,15 +405,13 @@ var require_sourcemap_codec_umd = __commonJS({
|
|
|
363
405
|
function _encodeOriginalScopes(scopes, index, writer, state) {
|
|
364
406
|
const scope = scopes[index];
|
|
365
407
|
const { 0: startLine, 1: startColumn, 2: endLine, 3: endColumn, 4: kind, vars } = scope;
|
|
366
|
-
if (index > 0)
|
|
367
|
-
writer.write(comma);
|
|
408
|
+
if (index > 0) writer.write(comma);
|
|
368
409
|
state[0] = encodeInteger(writer, startLine, state[0]);
|
|
369
410
|
encodeInteger(writer, startColumn, 0);
|
|
370
411
|
encodeInteger(writer, kind, 0);
|
|
371
412
|
const fields = scope.length === 6 ? 1 : 0;
|
|
372
413
|
encodeInteger(writer, fields, 0);
|
|
373
|
-
if (scope.length === 6)
|
|
374
|
-
encodeInteger(writer, scope[5], 0);
|
|
414
|
+
if (scope.length === 6) encodeInteger(writer, scope[5], 0);
|
|
375
415
|
for (const v of vars) {
|
|
376
416
|
encodeInteger(writer, v, 0);
|
|
377
417
|
}
|
|
@@ -422,7 +462,10 @@ var require_sourcemap_codec_umd = __commonJS({
|
|
|
422
462
|
let range;
|
|
423
463
|
if (hasDefinition) {
|
|
424
464
|
const defSourcesIndex = decodeInteger(reader, definitionSourcesIndex);
|
|
425
|
-
definitionScopeIndex = decodeInteger(
|
|
465
|
+
definitionScopeIndex = decodeInteger(
|
|
466
|
+
reader,
|
|
467
|
+
definitionSourcesIndex === defSourcesIndex ? definitionScopeIndex : 0
|
|
468
|
+
);
|
|
426
469
|
definitionSourcesIndex = defSourcesIndex;
|
|
427
470
|
range = [genLine, genColumn, 0, 0, defSourcesIndex, definitionScopeIndex];
|
|
428
471
|
} else {
|
|
@@ -435,7 +478,10 @@ var require_sourcemap_codec_umd = __commonJS({
|
|
|
435
478
|
callsiteSourcesIndex = decodeInteger(reader, callsiteSourcesIndex);
|
|
436
479
|
const sameSource = prevCsi === callsiteSourcesIndex;
|
|
437
480
|
callsiteLine = decodeInteger(reader, sameSource ? callsiteLine : 0);
|
|
438
|
-
callsiteColumn = decodeInteger(
|
|
481
|
+
callsiteColumn = decodeInteger(
|
|
482
|
+
reader,
|
|
483
|
+
sameSource && prevLine === callsiteLine ? callsiteColumn : 0
|
|
484
|
+
);
|
|
439
485
|
callsite = [callsiteSourcesIndex, callsiteLine, callsiteColumn];
|
|
440
486
|
}
|
|
441
487
|
range.callsite = callsite;
|
|
@@ -472,8 +518,7 @@ var require_sourcemap_codec_umd = __commonJS({
|
|
|
472
518
|
}
|
|
473
519
|
__name(decodeGeneratedRanges, "decodeGeneratedRanges");
|
|
474
520
|
function encodeGeneratedRanges(ranges) {
|
|
475
|
-
if (ranges.length === 0)
|
|
476
|
-
return "";
|
|
521
|
+
if (ranges.length === 0) return "";
|
|
477
522
|
const writer = new StringWriter();
|
|
478
523
|
for (let i = 0; i < ranges.length; ) {
|
|
479
524
|
i = _encodeGeneratedRanges(ranges, i, writer, [0, 0, 0, 0, 0, 0, 0]);
|
|
@@ -483,7 +528,15 @@ var require_sourcemap_codec_umd = __commonJS({
|
|
|
483
528
|
__name(encodeGeneratedRanges, "encodeGeneratedRanges");
|
|
484
529
|
function _encodeGeneratedRanges(ranges, index, writer, state) {
|
|
485
530
|
const range = ranges[index];
|
|
486
|
-
const {
|
|
531
|
+
const {
|
|
532
|
+
0: startLine,
|
|
533
|
+
1: startColumn,
|
|
534
|
+
2: endLine,
|
|
535
|
+
3: endColumn,
|
|
536
|
+
isScope,
|
|
537
|
+
callsite,
|
|
538
|
+
bindings
|
|
539
|
+
} = range;
|
|
487
540
|
if (state[0] < startLine) {
|
|
488
541
|
catchupLine(writer, state[0], startLine);
|
|
489
542
|
state[0] = startLine;
|
|
@@ -516,8 +569,7 @@ var require_sourcemap_codec_umd = __commonJS({
|
|
|
516
569
|
}
|
|
517
570
|
if (bindings) {
|
|
518
571
|
for (const binding of bindings) {
|
|
519
|
-
if (binding.length > 1)
|
|
520
|
-
encodeInteger(writer, -binding.length, 0);
|
|
572
|
+
if (binding.length > 1) encodeInteger(writer, -binding.length, 0);
|
|
521
573
|
const expression = binding[0][0];
|
|
522
574
|
encodeInteger(writer, expression, 0);
|
|
523
575
|
let bindingStartLine = startLine;
|
|
@@ -573,8 +625,7 @@ var require_sourcemap_codec_umd = __commonJS({
|
|
|
573
625
|
while (reader.pos < semi) {
|
|
574
626
|
let seg;
|
|
575
627
|
genColumn = decodeInteger(reader, genColumn);
|
|
576
|
-
if (genColumn < lastCol)
|
|
577
|
-
sorted = false;
|
|
628
|
+
if (genColumn < lastCol) sorted = false;
|
|
578
629
|
lastCol = genColumn;
|
|
579
630
|
if (hasMoreVlq(reader, semi)) {
|
|
580
631
|
sourcesIndex = decodeInteger(reader, sourcesIndex);
|
|
@@ -592,8 +643,7 @@ var require_sourcemap_codec_umd = __commonJS({
|
|
|
592
643
|
line.push(seg);
|
|
593
644
|
reader.pos++;
|
|
594
645
|
}
|
|
595
|
-
if (!sorted)
|
|
596
|
-
sort(line);
|
|
646
|
+
if (!sorted) sort(line);
|
|
597
647
|
decoded.push(line);
|
|
598
648
|
reader.pos = semi + 1;
|
|
599
649
|
} while (reader.pos <= length);
|
|
@@ -616,36 +666,24 @@ var require_sourcemap_codec_umd = __commonJS({
|
|
|
616
666
|
let namesIndex = 0;
|
|
617
667
|
for (let i = 0; i < decoded.length; i++) {
|
|
618
668
|
const line = decoded[i];
|
|
619
|
-
if (i > 0)
|
|
620
|
-
|
|
621
|
-
if (line.length === 0)
|
|
622
|
-
continue;
|
|
669
|
+
if (i > 0) writer.write(semicolon);
|
|
670
|
+
if (line.length === 0) continue;
|
|
623
671
|
let genColumn = 0;
|
|
624
672
|
for (let j = 0; j < line.length; j++) {
|
|
625
673
|
const segment = line[j];
|
|
626
|
-
if (j > 0)
|
|
627
|
-
writer.write(comma);
|
|
674
|
+
if (j > 0) writer.write(comma);
|
|
628
675
|
genColumn = encodeInteger(writer, segment[0], genColumn);
|
|
629
|
-
if (segment.length === 1)
|
|
630
|
-
continue;
|
|
676
|
+
if (segment.length === 1) continue;
|
|
631
677
|
sourcesIndex = encodeInteger(writer, segment[1], sourcesIndex);
|
|
632
678
|
sourceLine = encodeInteger(writer, segment[2], sourceLine);
|
|
633
679
|
sourceColumn = encodeInteger(writer, segment[3], sourceColumn);
|
|
634
|
-
if (segment.length === 4)
|
|
635
|
-
continue;
|
|
680
|
+
if (segment.length === 4) continue;
|
|
636
681
|
namesIndex = encodeInteger(writer, segment[4], namesIndex);
|
|
637
682
|
}
|
|
638
683
|
}
|
|
639
684
|
return writer.flush();
|
|
640
685
|
}
|
|
641
686
|
__name(encode, "encode");
|
|
642
|
-
exports2.decode = decode;
|
|
643
|
-
exports2.decodeGeneratedRanges = decodeGeneratedRanges;
|
|
644
|
-
exports2.decodeOriginalScopes = decodeOriginalScopes;
|
|
645
|
-
exports2.encode = encode;
|
|
646
|
-
exports2.encodeGeneratedRanges = encodeGeneratedRanges;
|
|
647
|
-
exports2.encodeOriginalScopes = encodeOriginalScopes;
|
|
648
|
-
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
649
687
|
});
|
|
650
688
|
}
|
|
651
689
|
});
|
|
@@ -653,8 +691,25 @@ var require_sourcemap_codec_umd = __commonJS({
|
|
|
653
691
|
// ../node_modules/@jridgewell/trace-mapping/dist/trace-mapping.umd.js
|
|
654
692
|
var require_trace_mapping_umd = __commonJS({
|
|
655
693
|
"../node_modules/@jridgewell/trace-mapping/dist/trace-mapping.umd.js"(exports, module) {
|
|
656
|
-
(function(global, factory
|
|
657
|
-
typeof exports === "object" && typeof module !== "undefined"
|
|
694
|
+
(function(global, factory) {
|
|
695
|
+
if (typeof exports === "object" && typeof module !== "undefined") {
|
|
696
|
+
factory(module, require_resolve_uri_umd(), require_sourcemap_codec_umd());
|
|
697
|
+
module.exports = def(module);
|
|
698
|
+
} else if (typeof define === "function" && define.amd) {
|
|
699
|
+
define(["module", "@jridgewell/resolve-uri", "@jridgewell/sourcemap-codec"], function(mod) {
|
|
700
|
+
factory.apply(this, arguments);
|
|
701
|
+
mod.exports = def(mod);
|
|
702
|
+
});
|
|
703
|
+
} else {
|
|
704
|
+
const mod = { exports: {} };
|
|
705
|
+
factory(mod, global.resolveURI, global.sourcemapCodec);
|
|
706
|
+
global = typeof globalThis !== "undefined" ? globalThis : global || self;
|
|
707
|
+
global.traceMapping = def(mod);
|
|
708
|
+
}
|
|
709
|
+
function def(m) {
|
|
710
|
+
return "default" in m.exports ? m.exports.default : m.exports;
|
|
711
|
+
}
|
|
712
|
+
__name(def, "def");
|
|
658
713
|
})(exports, function(module2, require_resolveURI, require_sourcemapCodec) {
|
|
659
714
|
"use strict";
|
|
660
715
|
var __create = Object.create;
|
|
@@ -774,6 +829,31 @@ var require_trace_mapping_umd = __commonJS({
|
|
|
774
829
|
return a[COLUMN] - b[COLUMN];
|
|
775
830
|
}
|
|
776
831
|
__name(sortComparator, "sortComparator");
|
|
832
|
+
function buildBySources(decoded, memos) {
|
|
833
|
+
const sources = memos.map(() => []);
|
|
834
|
+
for (let i = 0; i < decoded.length; i++) {
|
|
835
|
+
const line = decoded[i];
|
|
836
|
+
for (let j = 0; j < line.length; j++) {
|
|
837
|
+
const seg = line[j];
|
|
838
|
+
if (seg.length === 1) continue;
|
|
839
|
+
const sourceIndex2 = seg[SOURCES_INDEX];
|
|
840
|
+
const sourceLine = seg[SOURCE_LINE];
|
|
841
|
+
const sourceColumn = seg[SOURCE_COLUMN];
|
|
842
|
+
const source = sources[sourceIndex2];
|
|
843
|
+
const segs = source[sourceLine] || (source[sourceLine] = []);
|
|
844
|
+
segs.push([sourceColumn, i, seg[COLUMN]]);
|
|
845
|
+
}
|
|
846
|
+
}
|
|
847
|
+
for (let i = 0; i < sources.length; i++) {
|
|
848
|
+
const source = sources[i];
|
|
849
|
+
for (let j = 0; j < source.length; j++) {
|
|
850
|
+
const line = source[j];
|
|
851
|
+
if (line) line.sort(sortComparator);
|
|
852
|
+
}
|
|
853
|
+
}
|
|
854
|
+
return sources;
|
|
855
|
+
}
|
|
856
|
+
__name(buildBySources, "buildBySources");
|
|
777
857
|
var found = false;
|
|
778
858
|
function binarySearch(haystack, needle, low, high) {
|
|
779
859
|
while (low <= high) {
|
|
@@ -835,42 +915,6 @@ var require_trace_mapping_umd = __commonJS({
|
|
|
835
915
|
return state.lastIndex = binarySearch(haystack, needle, low, high);
|
|
836
916
|
}
|
|
837
917
|
__name(memoizedBinarySearch, "memoizedBinarySearch");
|
|
838
|
-
function buildBySources(decoded, memos) {
|
|
839
|
-
const sources = memos.map(buildNullArray);
|
|
840
|
-
for (let i = 0; i < decoded.length; i++) {
|
|
841
|
-
const line = decoded[i];
|
|
842
|
-
for (let j = 0; j < line.length; j++) {
|
|
843
|
-
const seg = line[j];
|
|
844
|
-
if (seg.length === 1) continue;
|
|
845
|
-
const sourceIndex2 = seg[SOURCES_INDEX];
|
|
846
|
-
const sourceLine = seg[SOURCE_LINE];
|
|
847
|
-
const sourceColumn = seg[SOURCE_COLUMN];
|
|
848
|
-
const originalSource = sources[sourceIndex2];
|
|
849
|
-
const originalLine = originalSource[sourceLine] || (originalSource[sourceLine] = []);
|
|
850
|
-
const memo = memos[sourceIndex2];
|
|
851
|
-
let index = upperBound(
|
|
852
|
-
originalLine,
|
|
853
|
-
sourceColumn,
|
|
854
|
-
memoizedBinarySearch(originalLine, sourceColumn, memo, sourceLine)
|
|
855
|
-
);
|
|
856
|
-
memo.lastIndex = ++index;
|
|
857
|
-
insert(originalLine, index, [sourceColumn, i, seg[COLUMN]]);
|
|
858
|
-
}
|
|
859
|
-
}
|
|
860
|
-
return sources;
|
|
861
|
-
}
|
|
862
|
-
__name(buildBySources, "buildBySources");
|
|
863
|
-
function insert(array, index, value) {
|
|
864
|
-
for (let i = array.length; i > index; i--) {
|
|
865
|
-
array[i] = array[i - 1];
|
|
866
|
-
}
|
|
867
|
-
array[index] = value;
|
|
868
|
-
}
|
|
869
|
-
__name(insert, "insert");
|
|
870
|
-
function buildNullArray() {
|
|
871
|
-
return { __proto__: null };
|
|
872
|
-
}
|
|
873
|
-
__name(buildNullArray, "buildNullArray");
|
|
874
918
|
function parse(map) {
|
|
875
919
|
return typeof map === "string" ? JSON.parse(map) : map;
|
|
876
920
|
}
|
|
@@ -1202,7 +1246,7 @@ var require_trace_mapping_umd = __commonJS({
|
|
|
1202
1246
|
}
|
|
1203
1247
|
__name(sliceGeneratedPositions, "sliceGeneratedPositions");
|
|
1204
1248
|
function generatedPosition(map, source, line, column, bias, all) {
|
|
1205
|
-
var _a;
|
|
1249
|
+
var _a, _b;
|
|
1206
1250
|
line--;
|
|
1207
1251
|
if (line < 0) throw new Error(LINE_GTR_ZERO);
|
|
1208
1252
|
if (column < 0) throw new Error(COL_GTR_EQ_ZERO);
|
|
@@ -1210,13 +1254,11 @@ var require_trace_mapping_umd = __commonJS({
|
|
|
1210
1254
|
let sourceIndex2 = sources.indexOf(source);
|
|
1211
1255
|
if (sourceIndex2 === -1) sourceIndex2 = resolvedSources.indexOf(source);
|
|
1212
1256
|
if (sourceIndex2 === -1) return all ? [] : GMapping(null, null);
|
|
1213
|
-
const
|
|
1214
|
-
|
|
1215
|
-
cast(map)._bySourceMemos = sources.map(memoizedState)
|
|
1216
|
-
));
|
|
1257
|
+
const bySourceMemos = (_a = cast(map))._bySourceMemos || (_a._bySourceMemos = sources.map(memoizedState));
|
|
1258
|
+
const generated = (_b = cast(map))._bySources || (_b._bySources = buildBySources(decodedMappings(map), bySourceMemos));
|
|
1217
1259
|
const segments = generated[sourceIndex2][line];
|
|
1218
1260
|
if (segments == null) return all ? [] : GMapping(null, null);
|
|
1219
|
-
const memo =
|
|
1261
|
+
const memo = bySourceMemos[sourceIndex2];
|
|
1220
1262
|
if (all) return sliceGeneratedPositions(segments, memo, line, column, bias);
|
|
1221
1263
|
const index = traceSegmentInternal(segments, memo, line, column, bias);
|
|
1222
1264
|
if (index === -1) return GMapping(null, null);
|
|
@@ -1231,8 +1273,25 @@ var require_trace_mapping_umd = __commonJS({
|
|
|
1231
1273
|
// ../node_modules/@jridgewell/gen-mapping/dist/gen-mapping.umd.js
|
|
1232
1274
|
var require_gen_mapping_umd = __commonJS({
|
|
1233
1275
|
"../node_modules/@jridgewell/gen-mapping/dist/gen-mapping.umd.js"(exports, module) {
|
|
1234
|
-
(function(global, factory
|
|
1235
|
-
typeof exports === "object" && typeof module !== "undefined"
|
|
1276
|
+
(function(global, factory) {
|
|
1277
|
+
if (typeof exports === "object" && typeof module !== "undefined") {
|
|
1278
|
+
factory(module, require_sourcemap_codec_umd(), require_trace_mapping_umd());
|
|
1279
|
+
module.exports = def(module);
|
|
1280
|
+
} else if (typeof define === "function" && define.amd) {
|
|
1281
|
+
define(["module", "@jridgewell/sourcemap-codec", "@jridgewell/trace-mapping"], function(mod) {
|
|
1282
|
+
factory.apply(this, arguments);
|
|
1283
|
+
mod.exports = def(mod);
|
|
1284
|
+
});
|
|
1285
|
+
} else {
|
|
1286
|
+
const mod = { exports: {} };
|
|
1287
|
+
factory(mod, global.sourcemapCodec, global.traceMapping);
|
|
1288
|
+
global = typeof globalThis !== "undefined" ? globalThis : global || self;
|
|
1289
|
+
global.genMapping = def(mod);
|
|
1290
|
+
}
|
|
1291
|
+
function def(m) {
|
|
1292
|
+
return "default" in m.exports ? m.exports.default : m.exports;
|
|
1293
|
+
}
|
|
1294
|
+
__name(def, "def");
|
|
1236
1295
|
})(exports, function(module2, require_sourcemapCodec, require_traceMapping) {
|
|
1237
1296
|
"use strict";
|
|
1238
1297
|
var __create = Object.create;
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_91hxho9jtpf from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_91hxho9jtpf from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_91hxho9jtpf from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_91hxho9jtpf.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_91hxho9jtpf.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_91hxho9jtpf.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
11
|
// ------------------------------------------------------------
|
|
12
12
|
import {
|
|
13
13
|
__name
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-Q5IJJX3T.js";
|
|
15
15
|
|
|
16
16
|
// ../node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.mjs
|
|
17
17
|
var comma = ",".charCodeAt(0);
|
|
@@ -30,8 +30,7 @@ function encodeInteger(builder, num, relative) {
|
|
|
30
30
|
do {
|
|
31
31
|
let clamped = delta & 31;
|
|
32
32
|
delta >>>= 5;
|
|
33
|
-
if (delta > 0)
|
|
34
|
-
clamped |= 32;
|
|
33
|
+
if (delta > 0) clamped |= 32;
|
|
35
34
|
builder.write(intToChar[clamped]);
|
|
36
35
|
} while (delta > 0);
|
|
37
36
|
return num;
|
|
@@ -82,23 +81,18 @@ function encode(decoded) {
|
|
|
82
81
|
let namesIndex = 0;
|
|
83
82
|
for (let i = 0; i < decoded.length; i++) {
|
|
84
83
|
const line = decoded[i];
|
|
85
|
-
if (i > 0)
|
|
86
|
-
|
|
87
|
-
if (line.length === 0)
|
|
88
|
-
continue;
|
|
84
|
+
if (i > 0) writer.write(semicolon);
|
|
85
|
+
if (line.length === 0) continue;
|
|
89
86
|
let genColumn = 0;
|
|
90
87
|
for (let j = 0; j < line.length; j++) {
|
|
91
88
|
const segment = line[j];
|
|
92
|
-
if (j > 0)
|
|
93
|
-
writer.write(comma);
|
|
89
|
+
if (j > 0) writer.write(comma);
|
|
94
90
|
genColumn = encodeInteger(writer, segment[0], genColumn);
|
|
95
|
-
if (segment.length === 1)
|
|
96
|
-
continue;
|
|
91
|
+
if (segment.length === 1) continue;
|
|
97
92
|
sourcesIndex = encodeInteger(writer, segment[1], sourcesIndex);
|
|
98
93
|
sourceLine = encodeInteger(writer, segment[2], sourceLine);
|
|
99
94
|
sourceColumn = encodeInteger(writer, segment[3], sourceColumn);
|
|
100
|
-
if (segment.length === 4)
|
|
101
|
-
continue;
|
|
95
|
+
if (segment.length === 4) continue;
|
|
102
96
|
namesIndex = encodeInteger(writer, segment[4], namesIndex);
|
|
103
97
|
}
|
|
104
98
|
}
|
|
@@ -563,6 +557,9 @@ var MagicString = class _MagicString {
|
|
|
563
557
|
}
|
|
564
558
|
if (chunk.outro.length) mappings.advance(chunk.outro);
|
|
565
559
|
});
|
|
560
|
+
if (this.outro) {
|
|
561
|
+
mappings.advance(this.outro);
|
|
562
|
+
}
|
|
566
563
|
return {
|
|
567
564
|
file: options.file ? options.file.split(/[/\\]/).pop() : void 0,
|
|
568
565
|
sources: [
|
|
@@ -920,10 +917,13 @@ var MagicString = class _MagicString {
|
|
|
920
917
|
_split(index) {
|
|
921
918
|
if (this.byStart[index] || this.byEnd[index]) return;
|
|
922
919
|
let chunk = this.lastSearchedChunk;
|
|
920
|
+
let previousChunk = chunk;
|
|
923
921
|
const searchForward = index > chunk.end;
|
|
924
922
|
while (chunk) {
|
|
925
923
|
if (chunk.contains(index)) return this._splitChunk(chunk, index);
|
|
926
924
|
chunk = searchForward ? this.byStart[chunk.end] : this.byEnd[chunk.start];
|
|
925
|
+
if (chunk === previousChunk) return;
|
|
926
|
+
previousChunk = chunk;
|
|
927
927
|
}
|
|
928
928
|
}
|
|
929
929
|
_splitChunk(chunk, index) {
|
|
@@ -1072,7 +1072,12 @@ var MagicString = class _MagicString {
|
|
|
1072
1072
|
const { original } = this;
|
|
1073
1073
|
const index = original.indexOf(string);
|
|
1074
1074
|
if (index !== -1) {
|
|
1075
|
-
|
|
1075
|
+
if (typeof replacement === "function") {
|
|
1076
|
+
replacement = replacement(string, index, original);
|
|
1077
|
+
}
|
|
1078
|
+
if (string !== replacement) {
|
|
1079
|
+
this.overwrite(index, index + string.length, replacement);
|
|
1080
|
+
}
|
|
1076
1081
|
}
|
|
1077
1082
|
return this;
|
|
1078
1083
|
}
|
|
@@ -1087,7 +1092,11 @@ var MagicString = class _MagicString {
|
|
|
1087
1092
|
const stringLength = string.length;
|
|
1088
1093
|
for (let index = original.indexOf(string); index !== -1; index = original.indexOf(string, index + stringLength)) {
|
|
1089
1094
|
const previous = original.slice(index, index + stringLength);
|
|
1090
|
-
|
|
1095
|
+
let _replacement = replacement;
|
|
1096
|
+
if (typeof replacement === "function") {
|
|
1097
|
+
_replacement = replacement(previous, index, original);
|
|
1098
|
+
}
|
|
1099
|
+
if (previous !== _replacement) this.overwrite(index, index + stringLength, _replacement);
|
|
1091
1100
|
}
|
|
1092
1101
|
return this;
|
|
1093
1102
|
}
|