storybook 10.2.0-alpha.8 → 10.2.0-beta.0
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/dist/_browser-chunks/{Color-E5XDEOX4.js → Color-XESOIGZP.js} +57 -3
- package/dist/_browser-chunks/chunk-AFVOZMXQ.js +23 -0
- package/dist/_browser-chunks/{chunk-3PJE6VLG.js → chunk-ASKQZAOS.js} +1 -12
- package/dist/_browser-chunks/chunk-IYCKG66Y.js +171 -0
- package/dist/_browser-chunks/chunk-LCHBOIHN.js +64 -0
- package/dist/_browser-chunks/{chunk-IPA5A322.js → chunk-MEXTPDJG.js} +1 -1
- package/dist/_browser-chunks/{chunk-54PNNATT.js → chunk-NQJGOFZV.js} +18 -1
- package/dist/_browser-chunks/{chunk-VUZYLZ4B.js → chunk-QOXZ7W26.js} +31 -15
- package/dist/_browser-chunks/{chunk-LOTN4ZCW.js → chunk-SI6AKD4S.js} +2 -2
- package/dist/_browser-chunks/chunk-YK43Z22A.js +263 -0
- package/dist/_node-chunks/{builder-manager-2XASU3VS.js → builder-manager-JEJE63VV.js} +15 -12
- package/dist/_node-chunks/camelcase-HALRJETF.js +62 -0
- package/dist/_node-chunks/{chunk-5GRHJJHD.js → chunk-3SKE4CCB.js} +9 -9
- package/dist/_node-chunks/chunk-4UYAC7Y2.js +18 -0
- package/dist/_node-chunks/{chunk-S7FIFCTX.js → chunk-6UAQEBJX.js} +10 -10
- package/dist/_node-chunks/{chunk-ZKB7MQRR.js → chunk-72K4WVI5.js} +18 -14
- package/dist/_node-chunks/{chunk-6TJUL42C.js → chunk-7ZX5CX6B.js} +15 -69
- package/dist/_node-chunks/{chunk-LEZENLG7.js → chunk-ADTWC7QJ.js} +7 -7
- package/dist/_node-chunks/{chunk-2OC7H5MZ.js → chunk-APUXGW3Y.js} +7 -7
- package/dist/_node-chunks/{chunk-5WQXPM6D.js → chunk-AXDM43NU.js} +6 -6
- package/dist/_node-chunks/{chunk-LOXLI4XT.js → chunk-B422K4XV.js} +6 -6
- package/dist/_node-chunks/{chunk-3K6P75SS.js → chunk-BJOXVTWM.js} +12 -571
- package/dist/_node-chunks/{chunk-TTGXODEY.js → chunk-BLGRU6F5.js} +7 -7
- package/dist/_node-chunks/{chunk-2KSITKBI.js → chunk-CG47ALAV.js} +7 -7
- package/dist/_node-chunks/chunk-FH4FRUMP.js +23 -0
- package/dist/_node-chunks/{chunk-DTM4A3DJ.js → chunk-GBZ23FIZ.js} +125 -73
- package/dist/_node-chunks/{chunk-IJ34563N.js → chunk-IZ3ATSWZ.js} +5262 -1480
- package/dist/_node-chunks/{chunk-JWL5NLJU.js → chunk-IZFEBWVB.js} +6 -6
- package/dist/_node-chunks/{chunk-5BRYY6XB.js → chunk-KL5CKFPT.js} +9 -9
- package/dist/_node-chunks/{chunk-COGO4JMD.js → chunk-MLXCYULR.js} +7 -7
- package/dist/_node-chunks/{chunk-7B4JYHGV.js → chunk-MV2QM7P3.js} +6 -6
- package/dist/_node-chunks/chunk-PHX5XNP7.js +144 -0
- package/dist/_node-chunks/{chunk-VJFHZL2T.js → chunk-QL6L57W7.js} +533 -144
- package/dist/_node-chunks/{chunk-Q6WPGVIW.js → chunk-RPBXVPRB.js} +6 -6
- package/dist/_node-chunks/{chunk-DYQ6QR45.js → chunk-UH2GWMFP.js} +260 -162
- package/dist/_node-chunks/chunk-WNGL2VRJ.js +126 -0
- package/dist/_node-chunks/{chunk-WKC523P7.js → chunk-XAL452XB.js} +36 -14
- package/dist/_node-chunks/{chunk-UNHOAAXU.js → chunk-YVXXMWQO.js} +7 -7
- package/dist/_node-chunks/chunk-YYDL7JOC.js +61 -0
- package/dist/_node-chunks/{chunk-MLYPMYG5.js → chunk-Z7FLE2TR.js} +6 -6
- package/dist/_node-chunks/{globby-FWMT4OOQ.js → globby-4D4NBVG7.js} +11 -20
- package/dist/_node-chunks/{lib-YCGXIMW5.js → lib-RM2DWHZQ.js} +7 -7
- package/dist/_node-chunks/{mdx-N42X6CFJ-CRGM5LTU.js → mdx-N42X6CFJ-RAL72UTP.js} +8 -8
- package/dist/_node-chunks/{p-limit-UJIYI4QT.js → p-limit-6PUJQL5X.js} +18 -14
- package/dist/babel/index.js +10 -10
- package/dist/bin/core.js +12 -12
- package/dist/bin/dispatcher.js +11 -11
- package/dist/bin/loader.js +9 -9
- package/dist/cli/index.d.ts +1504 -424
- package/dist/cli/index.js +18 -18
- package/dist/common/index.d.ts +1319 -271
- package/dist/common/index.js +22 -22
- package/dist/components/index.d.ts +4 -1
- package/dist/components/index.js +228 -227
- package/dist/core-events/index.d.ts +23 -7
- package/dist/core-events/index.js +5 -1
- package/dist/core-server/index.d.ts +108 -4
- package/dist/core-server/index.js +3459 -3086
- package/dist/core-server/presets/common-manager.js +208 -160
- package/dist/core-server/presets/common-override-preset.js +11 -11
- package/dist/core-server/presets/common-preset.js +576 -4536
- package/dist/csf/index.d.ts +147 -15
- package/dist/csf/index.js +52 -23
- package/dist/csf-tools/index.d.ts +19 -1
- package/dist/csf-tools/index.js +11 -9
- package/dist/docs-tools/index.d.ts +2 -2
- package/dist/docs-tools/index.js +4 -5
- package/dist/manager/globals-runtime.js +2749 -6907
- package/dist/manager/runtime.js +2939 -2295
- package/dist/manager-api/index.d.ts +89 -21
- package/dist/manager-api/index.js +82 -23
- package/dist/mocking-utils/index.js +8 -8
- package/dist/node-logger/index.d.ts +1453 -108
- package/dist/node-logger/index.js +9 -9
- package/dist/preview/runtime.js +784 -5059
- package/dist/preview-api/index.d.ts +26 -1
- package/dist/preview-api/index.js +11 -8
- package/dist/router/index.js +5 -4
- package/dist/server-errors.js +11 -11
- package/dist/telemetry/index.d.ts +14 -2
- package/dist/telemetry/index.js +23 -22
- package/dist/theming/index.d.ts +5 -5
- package/dist/theming/index.js +21 -2
- package/dist/types/index.d.ts +24 -11
- package/dist/viewport/index.d.ts +5 -3
- package/dist/viewport/index.js +12 -3
- package/package.json +27 -26
- package/dist/_browser-chunks/chunk-2NDLAB5X.js +0 -363
- package/dist/_browser-chunks/chunk-CLSHX4VX.js +0 -4140
- package/dist/_browser-chunks/chunk-HPYUT3WS.js +0 -199
- package/dist/_browser-chunks/chunk-XCZK5QUJ.js +0 -0
- package/dist/_node-chunks/camelcase-KIWRHB2G.js +0 -37
- package/dist/_node-chunks/chunk-2ANLCK4Y.js +0 -18
- package/dist/_node-chunks/chunk-3TW66YXG.js +0 -70
- package/dist/_node-chunks/chunk-UFXCGC4W.js +0 -23
- package/dist/_node-chunks/chunk-X4YDIHYE.js +0 -61
- package/dist/_node-chunks/dist-GICI6ZHU.js +0 -121
|
@@ -1,199 +0,0 @@
|
|
|
1
|
-
// ../../node_modules/es-toolkit/dist/function/debounce.mjs
|
|
2
|
-
function debounce(func, debounceMs, { signal, edges } = {}) {
|
|
3
|
-
let pendingThis, pendingArgs = null, leading = edges != null && edges.includes("leading"), trailing = edges == null || edges.includes("trailing"), invoke = () => {
|
|
4
|
-
pendingArgs !== null && (func.apply(pendingThis, pendingArgs), pendingThis = void 0, pendingArgs = null);
|
|
5
|
-
}, onTimerEnd = () => {
|
|
6
|
-
trailing && invoke(), cancel();
|
|
7
|
-
}, timeoutId = null, schedule = () => {
|
|
8
|
-
timeoutId != null && clearTimeout(timeoutId), timeoutId = setTimeout(() => {
|
|
9
|
-
timeoutId = null, onTimerEnd();
|
|
10
|
-
}, debounceMs);
|
|
11
|
-
}, cancelTimer = () => {
|
|
12
|
-
timeoutId !== null && (clearTimeout(timeoutId), timeoutId = null);
|
|
13
|
-
}, cancel = () => {
|
|
14
|
-
cancelTimer(), pendingThis = void 0, pendingArgs = null;
|
|
15
|
-
}, flush = () => {
|
|
16
|
-
cancelTimer(), invoke();
|
|
17
|
-
}, debounced = function(...args) {
|
|
18
|
-
if (signal?.aborted)
|
|
19
|
-
return;
|
|
20
|
-
pendingThis = this, pendingArgs = args;
|
|
21
|
-
let isFirstCall = timeoutId == null;
|
|
22
|
-
schedule(), leading && isFirstCall && invoke();
|
|
23
|
-
};
|
|
24
|
-
return debounced.schedule = schedule, debounced.cancel = cancel, debounced.flush = flush, signal?.addEventListener("abort", cancel, { once: !0 }), debounced;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
// ../../node_modules/es-toolkit/dist/function/partial.mjs
|
|
28
|
-
function partial(func, ...partialArgs) {
|
|
29
|
-
return partialImpl(func, placeholderSymbol, ...partialArgs);
|
|
30
|
-
}
|
|
31
|
-
function partialImpl(func, placeholder, ...partialArgs) {
|
|
32
|
-
let partialed = function(...providedArgs) {
|
|
33
|
-
let providedArgsIndex = 0, substitutedArgs = partialArgs.slice().map((arg) => arg === placeholder ? providedArgs[providedArgsIndex++] : arg), remainingArgs = providedArgs.slice(providedArgsIndex);
|
|
34
|
-
return func.apply(this, substitutedArgs.concat(remainingArgs));
|
|
35
|
-
};
|
|
36
|
-
return func.prototype && (partialed.prototype = Object.create(func.prototype)), partialed;
|
|
37
|
-
}
|
|
38
|
-
var placeholderSymbol = Symbol("partial.placeholder");
|
|
39
|
-
partial.placeholder = placeholderSymbol;
|
|
40
|
-
|
|
41
|
-
// ../../node_modules/es-toolkit/dist/function/partialRight.mjs
|
|
42
|
-
function partialRight(func, ...partialArgs) {
|
|
43
|
-
return partialRightImpl(func, placeholderSymbol2, ...partialArgs);
|
|
44
|
-
}
|
|
45
|
-
function partialRightImpl(func, placeholder, ...partialArgs) {
|
|
46
|
-
let partialedRight = function(...providedArgs) {
|
|
47
|
-
let placeholderLength = partialArgs.filter((arg) => arg === placeholder).length, rangeLength = Math.max(providedArgs.length - placeholderLength, 0), remainingArgs = providedArgs.slice(0, rangeLength), providedArgsIndex = rangeLength, substitutedArgs = partialArgs.slice().map((arg) => arg === placeholder ? providedArgs[providedArgsIndex++] : arg);
|
|
48
|
-
return func.apply(this, remainingArgs.concat(substitutedArgs));
|
|
49
|
-
};
|
|
50
|
-
return func.prototype && (partialedRight.prototype = Object.create(func.prototype)), partialedRight;
|
|
51
|
-
}
|
|
52
|
-
var placeholderSymbol2 = Symbol("partialRight.placeholder");
|
|
53
|
-
partialRight.placeholder = placeholderSymbol2;
|
|
54
|
-
|
|
55
|
-
// ../../node_modules/es-toolkit/dist/function/asyncNoop.mjs
|
|
56
|
-
async function asyncNoop() {
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
// ../../node_modules/es-toolkit/dist/function/identity.mjs
|
|
60
|
-
function identity(x) {
|
|
61
|
-
return x;
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
// ../../node_modules/es-toolkit/dist/function/memoize.mjs
|
|
65
|
-
function memoize(fn, options = {}) {
|
|
66
|
-
let { cache = /* @__PURE__ */ new Map(), getCacheKey } = options, memoizedFn = function(arg) {
|
|
67
|
-
let key = getCacheKey ? getCacheKey(arg) : arg;
|
|
68
|
-
if (cache.has(key))
|
|
69
|
-
return cache.get(key);
|
|
70
|
-
let result = fn.call(this, arg);
|
|
71
|
-
return cache.set(key, result), result;
|
|
72
|
-
};
|
|
73
|
-
return memoizedFn.cache = cache, memoizedFn;
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
// ../../node_modules/es-toolkit/dist/function/once.mjs
|
|
77
|
-
function once(func) {
|
|
78
|
-
let called = !1, cache;
|
|
79
|
-
return function(...args) {
|
|
80
|
-
return called || (called = !0, cache = func(...args)), cache;
|
|
81
|
-
};
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
// ../../node_modules/es-toolkit/dist/error/AbortError.mjs
|
|
85
|
-
var AbortError = class extends Error {
|
|
86
|
-
constructor(message = "The operation was aborted") {
|
|
87
|
-
super(message), this.name = "AbortError";
|
|
88
|
-
}
|
|
89
|
-
};
|
|
90
|
-
|
|
91
|
-
// ../../node_modules/es-toolkit/dist/promise/delay.mjs
|
|
92
|
-
function delay(ms, { signal } = {}) {
|
|
93
|
-
return new Promise((resolve, reject) => {
|
|
94
|
-
let abortError = () => {
|
|
95
|
-
reject(new AbortError());
|
|
96
|
-
}, abortHandler = () => {
|
|
97
|
-
clearTimeout(timeoutId), abortError();
|
|
98
|
-
};
|
|
99
|
-
if (signal?.aborted)
|
|
100
|
-
return abortError();
|
|
101
|
-
let timeoutId = setTimeout(() => {
|
|
102
|
-
signal?.removeEventListener("abort", abortHandler), resolve();
|
|
103
|
-
}, ms);
|
|
104
|
-
signal?.addEventListener("abort", abortHandler, { once: !0 });
|
|
105
|
-
});
|
|
106
|
-
}
|
|
107
|
-
|
|
108
|
-
// ../../node_modules/es-toolkit/dist/function/retry.mjs
|
|
109
|
-
var DEFAULT_DELAY = 0, DEFAULT_RETRIES = Number.POSITIVE_INFINITY;
|
|
110
|
-
async function retry(func, _options) {
|
|
111
|
-
let delay$1, retries, signal;
|
|
112
|
-
typeof _options == "number" ? (delay$1 = DEFAULT_DELAY, retries = _options, signal = void 0) : (delay$1 = _options?.delay ?? DEFAULT_DELAY, retries = _options?.retries ?? DEFAULT_RETRIES, signal = _options?.signal);
|
|
113
|
-
let error;
|
|
114
|
-
for (let attempts = 0; attempts < retries; attempts++) {
|
|
115
|
-
if (signal?.aborted)
|
|
116
|
-
throw error ?? new Error("The retry operation was aborted due to an abort signal.");
|
|
117
|
-
try {
|
|
118
|
-
return await func();
|
|
119
|
-
} catch (err) {
|
|
120
|
-
error = err;
|
|
121
|
-
let currentDelay = typeof delay$1 == "function" ? delay$1(attempts) : delay$1;
|
|
122
|
-
await delay(currentDelay);
|
|
123
|
-
}
|
|
124
|
-
}
|
|
125
|
-
throw error;
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
// ../../node_modules/es-toolkit/dist/function/ary.mjs
|
|
129
|
-
function ary(func, n) {
|
|
130
|
-
return function(...args) {
|
|
131
|
-
return func.apply(this, args.slice(0, n));
|
|
132
|
-
};
|
|
133
|
-
}
|
|
134
|
-
|
|
135
|
-
// ../../node_modules/es-toolkit/dist/function/unary.mjs
|
|
136
|
-
function unary(func) {
|
|
137
|
-
return ary(func, 1);
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
// ../../node_modules/es-toolkit/dist/function/negate.mjs
|
|
141
|
-
function negate(func) {
|
|
142
|
-
return ((...args) => !func(...args));
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
// ../../node_modules/es-toolkit/dist/function/flow.mjs
|
|
146
|
-
function flow(...funcs) {
|
|
147
|
-
return function(...args) {
|
|
148
|
-
let result = funcs.length ? funcs[0].apply(this, args) : args[0];
|
|
149
|
-
for (let i = 1; i < funcs.length; i++)
|
|
150
|
-
result = funcs[i].call(this, result);
|
|
151
|
-
return result;
|
|
152
|
-
};
|
|
153
|
-
}
|
|
154
|
-
|
|
155
|
-
// ../../node_modules/es-toolkit/dist/function/flowRight.mjs
|
|
156
|
-
function flowRight(...funcs) {
|
|
157
|
-
return flow(...funcs.reverse());
|
|
158
|
-
}
|
|
159
|
-
|
|
160
|
-
// ../../node_modules/es-toolkit/dist/function/rest.mjs
|
|
161
|
-
function rest(func, startIndex = func.length - 1) {
|
|
162
|
-
return function(...args) {
|
|
163
|
-
let rest2 = args.slice(startIndex), params = args.slice(0, startIndex);
|
|
164
|
-
for (; params.length < startIndex; )
|
|
165
|
-
params.push(void 0);
|
|
166
|
-
return func.apply(this, [...params, rest2]);
|
|
167
|
-
};
|
|
168
|
-
}
|
|
169
|
-
|
|
170
|
-
// ../../node_modules/es-toolkit/dist/function/after.mjs
|
|
171
|
-
function after(n, func) {
|
|
172
|
-
if (!Number.isInteger(n) || n < 0)
|
|
173
|
-
throw new Error("n must be a non-negative integer.");
|
|
174
|
-
let counter = 0;
|
|
175
|
-
return (...args) => {
|
|
176
|
-
if (++counter >= n)
|
|
177
|
-
return func(...args);
|
|
178
|
-
};
|
|
179
|
-
}
|
|
180
|
-
|
|
181
|
-
export {
|
|
182
|
-
partialImpl,
|
|
183
|
-
partialRightImpl,
|
|
184
|
-
AbortError,
|
|
185
|
-
asyncNoop,
|
|
186
|
-
identity,
|
|
187
|
-
memoize,
|
|
188
|
-
once,
|
|
189
|
-
delay,
|
|
190
|
-
retry,
|
|
191
|
-
ary,
|
|
192
|
-
unary,
|
|
193
|
-
negate,
|
|
194
|
-
debounce,
|
|
195
|
-
flow,
|
|
196
|
-
flowRight,
|
|
197
|
-
rest,
|
|
198
|
-
after
|
|
199
|
-
};
|
|
File without changes
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import CJS_COMPAT_NODE_URL_3bfbtrdgjix from 'node:url';
|
|
2
|
-
import CJS_COMPAT_NODE_PATH_3bfbtrdgjix from 'node:path';
|
|
3
|
-
import CJS_COMPAT_NODE_MODULE_3bfbtrdgjix from "node:module";
|
|
4
|
-
|
|
5
|
-
var __filename = CJS_COMPAT_NODE_URL_3bfbtrdgjix.fileURLToPath(import.meta.url);
|
|
6
|
-
var __dirname = CJS_COMPAT_NODE_PATH_3bfbtrdgjix.dirname(__filename);
|
|
7
|
-
var require = CJS_COMPAT_NODE_MODULE_3bfbtrdgjix.createRequire(import.meta.url);
|
|
8
|
-
|
|
9
|
-
// ------------------------------------------------------------
|
|
10
|
-
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
-
// ------------------------------------------------------------
|
|
12
|
-
import "./chunk-5WQXPM6D.js";
|
|
13
|
-
|
|
14
|
-
// ../../node_modules/camelcase/index.js
|
|
15
|
-
var UPPERCASE = /[\p{Lu}]/u, LOWERCASE = /[\p{Ll}]/u, LEADING_CAPITAL = /^[\p{Lu}](?![\p{Lu}])/gu, IDENTIFIER = /([\p{Alpha}\p{N}_]|$)/u, SEPARATORS = /[_.\- ]+/, LEADING_SEPARATORS = new RegExp("^" + SEPARATORS.source), SEPARATORS_AND_IDENTIFIER = new RegExp(SEPARATORS.source + IDENTIFIER.source, "gu"), NUMBERS_AND_IDENTIFIER = new RegExp("\\d+" + IDENTIFIER.source, "gu"), preserveCamelCase = (string, toLowerCase, toUpperCase, preserveConsecutiveUppercase2) => {
|
|
16
|
-
let isLastCharLower = !1, isLastCharUpper = !1, isLastLastCharUpper = !1, isLastLastCharPreserved = !1;
|
|
17
|
-
for (let index = 0; index < string.length; index++) {
|
|
18
|
-
let character = string[index];
|
|
19
|
-
isLastLastCharPreserved = index > 2 ? string[index - 3] === "-" : !0, isLastCharLower && UPPERCASE.test(character) ? (string = string.slice(0, index) + "-" + string.slice(index), isLastCharLower = !1, isLastLastCharUpper = isLastCharUpper, isLastCharUpper = !0, index++) : isLastCharUpper && isLastLastCharUpper && LOWERCASE.test(character) && (!isLastLastCharPreserved || preserveConsecutiveUppercase2) ? (string = string.slice(0, index - 1) + "-" + string.slice(index - 1), isLastLastCharUpper = isLastCharUpper, isLastCharUpper = !1, isLastCharLower = !0) : (isLastCharLower = toLowerCase(character) === character && toUpperCase(character) !== character, isLastLastCharUpper = isLastCharUpper, isLastCharUpper = toUpperCase(character) === character && toLowerCase(character) !== character);
|
|
20
|
-
}
|
|
21
|
-
return string;
|
|
22
|
-
}, preserveConsecutiveUppercase = (input, toLowerCase) => (LEADING_CAPITAL.lastIndex = 0, input.replaceAll(LEADING_CAPITAL, (match) => toLowerCase(match))), postProcess = (input, toUpperCase) => (SEPARATORS_AND_IDENTIFIER.lastIndex = 0, NUMBERS_AND_IDENTIFIER.lastIndex = 0, input.replaceAll(NUMBERS_AND_IDENTIFIER, (match, pattern, offset) => ["_", "-"].includes(input.charAt(offset + match.length)) ? match : toUpperCase(match)).replaceAll(SEPARATORS_AND_IDENTIFIER, (_, identifier) => toUpperCase(identifier)));
|
|
23
|
-
function camelCase(input, options) {
|
|
24
|
-
if (!(typeof input == "string" || Array.isArray(input)))
|
|
25
|
-
throw new TypeError("Expected the input to be `string | string[]`");
|
|
26
|
-
if (options = {
|
|
27
|
-
pascalCase: !1,
|
|
28
|
-
preserveConsecutiveUppercase: !1,
|
|
29
|
-
...options
|
|
30
|
-
}, Array.isArray(input) ? input = input.map((x) => x.trim()).filter((x) => x.length).join("-") : input = input.trim(), input.length === 0)
|
|
31
|
-
return "";
|
|
32
|
-
let toLowerCase = options.locale === !1 ? (string) => string.toLowerCase() : (string) => string.toLocaleLowerCase(options.locale), toUpperCase = options.locale === !1 ? (string) => string.toUpperCase() : (string) => string.toLocaleUpperCase(options.locale);
|
|
33
|
-
return input.length === 1 ? SEPARATORS.test(input) ? "" : options.pascalCase ? toUpperCase(input) : toLowerCase(input) : (input !== toLowerCase(input) && (input = preserveCamelCase(input, toLowerCase, toUpperCase, options.preserveConsecutiveUppercase)), input = input.replace(LEADING_SEPARATORS, ""), input = options.preserveConsecutiveUppercase ? preserveConsecutiveUppercase(input, toLowerCase) : toLowerCase(input), options.pascalCase && (input = toUpperCase(input.charAt(0)) + input.slice(1)), postProcess(input, toUpperCase));
|
|
34
|
-
}
|
|
35
|
-
export {
|
|
36
|
-
camelCase as default
|
|
37
|
-
};
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import CJS_COMPAT_NODE_URL_3bfbtrdgjix from 'node:url';
|
|
2
|
-
import CJS_COMPAT_NODE_PATH_3bfbtrdgjix from 'node:path';
|
|
3
|
-
import CJS_COMPAT_NODE_MODULE_3bfbtrdgjix from "node:module";
|
|
4
|
-
|
|
5
|
-
var __filename = CJS_COMPAT_NODE_URL_3bfbtrdgjix.fileURLToPath(import.meta.url);
|
|
6
|
-
var __dirname = CJS_COMPAT_NODE_PATH_3bfbtrdgjix.dirname(__filename);
|
|
7
|
-
var require = CJS_COMPAT_NODE_MODULE_3bfbtrdgjix.createRequire(import.meta.url);
|
|
8
|
-
|
|
9
|
-
// ------------------------------------------------------------
|
|
10
|
-
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
-
// ------------------------------------------------------------
|
|
12
|
-
|
|
13
|
-
// package.json
|
|
14
|
-
var version = "10.2.0-alpha.8";
|
|
15
|
-
|
|
16
|
-
export {
|
|
17
|
-
version
|
|
18
|
-
};
|
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
import CJS_COMPAT_NODE_URL_3bfbtrdgjix from 'node:url';
|
|
2
|
-
import CJS_COMPAT_NODE_PATH_3bfbtrdgjix from 'node:path';
|
|
3
|
-
import CJS_COMPAT_NODE_MODULE_3bfbtrdgjix from "node:module";
|
|
4
|
-
|
|
5
|
-
var __filename = CJS_COMPAT_NODE_URL_3bfbtrdgjix.fileURLToPath(import.meta.url);
|
|
6
|
-
var __dirname = CJS_COMPAT_NODE_PATH_3bfbtrdgjix.dirname(__filename);
|
|
7
|
-
var require = CJS_COMPAT_NODE_MODULE_3bfbtrdgjix.createRequire(import.meta.url);
|
|
8
|
-
|
|
9
|
-
// ------------------------------------------------------------
|
|
10
|
-
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
-
// ------------------------------------------------------------
|
|
12
|
-
|
|
13
|
-
// ../../node_modules/empathic/resolve.mjs
|
|
14
|
-
import { createRequire } from "node:module";
|
|
15
|
-
import { isAbsolute, join, resolve } from "node:path";
|
|
16
|
-
import { fileURLToPath } from "node:url";
|
|
17
|
-
function absolute(input, root) {
|
|
18
|
-
return isAbsolute(input) ? input : resolve(root || ".", input);
|
|
19
|
-
}
|
|
20
|
-
function from(root, ident, silent) {
|
|
21
|
-
try {
|
|
22
|
-
let r = root instanceof URL || root.startsWith("file://") ? join(fileURLToPath(root), "noop.js") : join(absolute(root), "noop.js");
|
|
23
|
-
return createRequire(r).resolve(ident);
|
|
24
|
-
} catch (err) {
|
|
25
|
-
if (!silent) throw err;
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
// ../../node_modules/empathic/walk.mjs
|
|
30
|
-
import { dirname } from "node:path";
|
|
31
|
-
function up(base, options) {
|
|
32
|
-
let { last, cwd } = options || {}, tmp = absolute(base, cwd), root = absolute(last || "/", cwd), prev, arr = [];
|
|
33
|
-
for (; prev !== root && (arr.push(tmp), tmp = dirname(prev = tmp), tmp !== prev); )
|
|
34
|
-
;
|
|
35
|
-
return arr;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
// ../../node_modules/empathic/find.mjs
|
|
39
|
-
import { join as join2 } from "node:path";
|
|
40
|
-
import { existsSync, statSync } from "node:fs";
|
|
41
|
-
function up2(name, options) {
|
|
42
|
-
let dir, tmp, start = options && options.cwd || "";
|
|
43
|
-
for (dir of up(start, options))
|
|
44
|
-
if (tmp = join2(dir, name), existsSync(tmp)) return tmp;
|
|
45
|
-
}
|
|
46
|
-
function any(names, options) {
|
|
47
|
-
let dir, start = options && options.cwd || "", j = 0, len = names.length, tmp;
|
|
48
|
-
for (dir of up(start, options))
|
|
49
|
-
for (j = 0; j < len; j++)
|
|
50
|
-
if (tmp = join2(dir, names[j]), existsSync(tmp)) return tmp;
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
// ../../node_modules/tiny-invariant/dist/esm/tiny-invariant.js
|
|
54
|
-
var isProduction = process.env.NODE_ENV === "production", prefix = "Invariant failed";
|
|
55
|
-
function invariant(condition, message) {
|
|
56
|
-
if (!condition) {
|
|
57
|
-
if (isProduction)
|
|
58
|
-
throw new Error(prefix);
|
|
59
|
-
var provided = typeof message == "function" ? message() : message, value = provided ? "".concat(prefix, ": ").concat(provided) : prefix;
|
|
60
|
-
throw new Error(value);
|
|
61
|
-
}
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
export {
|
|
65
|
-
from,
|
|
66
|
-
up,
|
|
67
|
-
up2,
|
|
68
|
-
any,
|
|
69
|
-
invariant
|
|
70
|
-
};
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import CJS_COMPAT_NODE_URL_3bfbtrdgjix from 'node:url';
|
|
2
|
-
import CJS_COMPAT_NODE_PATH_3bfbtrdgjix from 'node:path';
|
|
3
|
-
import CJS_COMPAT_NODE_MODULE_3bfbtrdgjix from "node:module";
|
|
4
|
-
|
|
5
|
-
var __filename = CJS_COMPAT_NODE_URL_3bfbtrdgjix.fileURLToPath(import.meta.url);
|
|
6
|
-
var __dirname = CJS_COMPAT_NODE_PATH_3bfbtrdgjix.dirname(__filename);
|
|
7
|
-
var require = CJS_COMPAT_NODE_MODULE_3bfbtrdgjix.createRequire(import.meta.url);
|
|
8
|
-
|
|
9
|
-
// ------------------------------------------------------------
|
|
10
|
-
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
-
// ------------------------------------------------------------
|
|
12
|
-
import {
|
|
13
|
-
any
|
|
14
|
-
} from "./chunk-3TW66YXG.js";
|
|
15
|
-
|
|
16
|
-
// src/cli/detect.ts
|
|
17
|
-
async function detectPnp() {
|
|
18
|
-
return !!any([".pnp.js", ".pnp.cjs"]);
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
export {
|
|
22
|
-
detectPnp
|
|
23
|
-
};
|
|
@@ -1,61 +0,0 @@
|
|
|
1
|
-
import CJS_COMPAT_NODE_URL_3bfbtrdgjix from 'node:url';
|
|
2
|
-
import CJS_COMPAT_NODE_PATH_3bfbtrdgjix from 'node:path';
|
|
3
|
-
import CJS_COMPAT_NODE_MODULE_3bfbtrdgjix from "node:module";
|
|
4
|
-
|
|
5
|
-
var __filename = CJS_COMPAT_NODE_URL_3bfbtrdgjix.fileURLToPath(import.meta.url);
|
|
6
|
-
var __dirname = CJS_COMPAT_NODE_PATH_3bfbtrdgjix.dirname(__filename);
|
|
7
|
-
var require = CJS_COMPAT_NODE_MODULE_3bfbtrdgjix.createRequire(import.meta.url);
|
|
8
|
-
|
|
9
|
-
// ------------------------------------------------------------
|
|
10
|
-
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
-
// ------------------------------------------------------------
|
|
12
|
-
|
|
13
|
-
// src/common/versions.ts
|
|
14
|
-
var versions_default = {
|
|
15
|
-
"@storybook/addon-a11y": "10.2.0-alpha.8",
|
|
16
|
-
"@storybook/addon-docs": "10.2.0-alpha.8",
|
|
17
|
-
"@storybook/addon-links": "10.2.0-alpha.8",
|
|
18
|
-
"@storybook/addon-onboarding": "10.2.0-alpha.8",
|
|
19
|
-
"storybook-addon-pseudo-states": "10.2.0-alpha.8",
|
|
20
|
-
"@storybook/addon-themes": "10.2.0-alpha.8",
|
|
21
|
-
"@storybook/addon-vitest": "10.2.0-alpha.8",
|
|
22
|
-
"@storybook/builder-vite": "10.2.0-alpha.8",
|
|
23
|
-
"@storybook/builder-webpack5": "10.2.0-alpha.8",
|
|
24
|
-
storybook: "10.2.0-alpha.8",
|
|
25
|
-
"@storybook/angular": "10.2.0-alpha.8",
|
|
26
|
-
"@storybook/ember": "10.2.0-alpha.8",
|
|
27
|
-
"@storybook/html-vite": "10.2.0-alpha.8",
|
|
28
|
-
"@storybook/nextjs": "10.2.0-alpha.8",
|
|
29
|
-
"@storybook/nextjs-vite": "10.2.0-alpha.8",
|
|
30
|
-
"@storybook/preact-vite": "10.2.0-alpha.8",
|
|
31
|
-
"@storybook/react-native-web-vite": "10.2.0-alpha.8",
|
|
32
|
-
"@storybook/react-vite": "10.2.0-alpha.8",
|
|
33
|
-
"@storybook/react-webpack5": "10.2.0-alpha.8",
|
|
34
|
-
"@storybook/server-webpack5": "10.2.0-alpha.8",
|
|
35
|
-
"@storybook/svelte-vite": "10.2.0-alpha.8",
|
|
36
|
-
"@storybook/sveltekit": "10.2.0-alpha.8",
|
|
37
|
-
"@storybook/vue3-vite": "10.2.0-alpha.8",
|
|
38
|
-
"@storybook/web-components-vite": "10.2.0-alpha.8",
|
|
39
|
-
sb: "10.2.0-alpha.8",
|
|
40
|
-
"@storybook/cli": "10.2.0-alpha.8",
|
|
41
|
-
"@storybook/codemod": "10.2.0-alpha.8",
|
|
42
|
-
"@storybook/core-webpack": "10.2.0-alpha.8",
|
|
43
|
-
"create-storybook": "10.2.0-alpha.8",
|
|
44
|
-
"@storybook/csf-plugin": "10.2.0-alpha.8",
|
|
45
|
-
"eslint-plugin-storybook": "10.2.0-alpha.8",
|
|
46
|
-
"@storybook/react-dom-shim": "10.2.0-alpha.8",
|
|
47
|
-
"@storybook/preset-create-react-app": "10.2.0-alpha.8",
|
|
48
|
-
"@storybook/preset-react-webpack": "10.2.0-alpha.8",
|
|
49
|
-
"@storybook/preset-server-webpack": "10.2.0-alpha.8",
|
|
50
|
-
"@storybook/html": "10.2.0-alpha.8",
|
|
51
|
-
"@storybook/preact": "10.2.0-alpha.8",
|
|
52
|
-
"@storybook/react": "10.2.0-alpha.8",
|
|
53
|
-
"@storybook/server": "10.2.0-alpha.8",
|
|
54
|
-
"@storybook/svelte": "10.2.0-alpha.8",
|
|
55
|
-
"@storybook/vue3": "10.2.0-alpha.8",
|
|
56
|
-
"@storybook/web-components": "10.2.0-alpha.8"
|
|
57
|
-
};
|
|
58
|
-
|
|
59
|
-
export {
|
|
60
|
-
versions_default
|
|
61
|
-
};
|
|
@@ -1,121 +0,0 @@
|
|
|
1
|
-
import CJS_COMPAT_NODE_URL_3bfbtrdgjix from 'node:url';
|
|
2
|
-
import CJS_COMPAT_NODE_PATH_3bfbtrdgjix from 'node:path';
|
|
3
|
-
import CJS_COMPAT_NODE_MODULE_3bfbtrdgjix from "node:module";
|
|
4
|
-
|
|
5
|
-
var __filename = CJS_COMPAT_NODE_URL_3bfbtrdgjix.fileURLToPath(import.meta.url);
|
|
6
|
-
var __dirname = CJS_COMPAT_NODE_PATH_3bfbtrdgjix.dirname(__filename);
|
|
7
|
-
var require = CJS_COMPAT_NODE_MODULE_3bfbtrdgjix.createRequire(import.meta.url);
|
|
8
|
-
|
|
9
|
-
// ------------------------------------------------------------
|
|
10
|
-
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
-
// ------------------------------------------------------------
|
|
12
|
-
import {
|
|
13
|
-
toEstree
|
|
14
|
-
} from "./chunk-UNHOAAXU.js";
|
|
15
|
-
import "./chunk-5WQXPM6D.js";
|
|
16
|
-
|
|
17
|
-
// ../../node_modules/@storybook/docs-mdx/dist/index.js
|
|
18
|
-
var getAttr = (elt, what) => elt.attributes.find((n) => n.type === "JSXAttribute" && n.name.name === what), getAttrValue = (elt, what) => getAttr(elt, what)?.value, getAttrLiteral = (elt, what) => {
|
|
19
|
-
let attrValue = getAttrValue(elt, what);
|
|
20
|
-
if (attrValue) {
|
|
21
|
-
if (attrValue.type === "Literal")
|
|
22
|
-
return attrValue.value;
|
|
23
|
-
throw new Error(`Expected string literal ${what}, received ${attrValue.type}`);
|
|
24
|
-
}
|
|
25
|
-
}, getOf = (elt, varToImport) => {
|
|
26
|
-
let ofAttrValue = getAttrValue(elt, "of");
|
|
27
|
-
if (ofAttrValue)
|
|
28
|
-
if (ofAttrValue.type === "JSXExpressionContainer") {
|
|
29
|
-
let of = ofAttrValue.expression;
|
|
30
|
-
if (of?.type === "Identifier") {
|
|
31
|
-
let importName = varToImport[of.name];
|
|
32
|
-
if (importName)
|
|
33
|
-
return importName;
|
|
34
|
-
throw new Error(`Unknown identifier ${of.name}`);
|
|
35
|
-
} else
|
|
36
|
-
throw new Error(`Expected identifier, received ${of.type}`);
|
|
37
|
-
} else
|
|
38
|
-
throw new Error(`Expected JSX expression, received ${ofAttrValue.type}`);
|
|
39
|
-
}, getTags = (elt) => {
|
|
40
|
-
let tagsAttr = getAttr(elt, "tags");
|
|
41
|
-
if (!tagsAttr)
|
|
42
|
-
return;
|
|
43
|
-
let tagsContainer = tagsAttr.value;
|
|
44
|
-
if (tagsContainer.type === "JSXExpressionContainer") {
|
|
45
|
-
let tagsArray = tagsContainer.expression;
|
|
46
|
-
if (tagsArray.type === "ArrayExpression")
|
|
47
|
-
return tagsArray.elements.map((tag) => {
|
|
48
|
-
if (tag.type === "Literal" && typeof tag.value == "string")
|
|
49
|
-
return tag.value;
|
|
50
|
-
throw new Error(`Expected string literal tag, received ${tag.type}`);
|
|
51
|
-
});
|
|
52
|
-
throw new Error(`Expected tags array, received ${tagsArray.type}`);
|
|
53
|
-
} else
|
|
54
|
-
throw new Error(`Expected JSX expression tags, received ${tagsContainer.type}`);
|
|
55
|
-
}, getIsTemplate = (elt) => {
|
|
56
|
-
let isTemplateAttr = getAttr(elt, "isTemplate");
|
|
57
|
-
if (!isTemplateAttr)
|
|
58
|
-
return !1;
|
|
59
|
-
let isTemplate = isTemplateAttr.value;
|
|
60
|
-
if (isTemplate == null)
|
|
61
|
-
return !0;
|
|
62
|
-
if (isTemplate.type === "JSXExpressionContainer") {
|
|
63
|
-
let expression = isTemplate.expression;
|
|
64
|
-
if (expression.type === "Literal" && typeof expression.value == "boolean")
|
|
65
|
-
return expression.value;
|
|
66
|
-
throw new Error(`Expected boolean isTemplate, received ${typeof expression.value}`);
|
|
67
|
-
} else
|
|
68
|
-
throw new Error(`Expected expression isTemplate, received ${isTemplate.type}`);
|
|
69
|
-
}, extractTitle = (root, varToImport) => {
|
|
70
|
-
let result = { title: void 0, of: void 0, name: void 0, isTemplate: !1 }, fragments = root.body.filter(
|
|
71
|
-
(child) => child.type === "ExpressionStatement" && child.expression.type === "JSXFragment"
|
|
72
|
-
);
|
|
73
|
-
if (fragments.length > 1)
|
|
74
|
-
throw new Error("duplicate contents");
|
|
75
|
-
return fragments.length === 0 || fragments[0].expression.children.forEach((child) => {
|
|
76
|
-
if (child.type === "JSXElement") {
|
|
77
|
-
let { openingElement } = child;
|
|
78
|
-
if (openingElement.name.name === "Meta") {
|
|
79
|
-
if (result.title || result.name || result.of)
|
|
80
|
-
throw new Error("Meta can only be declared once");
|
|
81
|
-
result.title = getAttrLiteral(openingElement, "title"), result.name = getAttrLiteral(openingElement, "name"), result.of = getOf(openingElement, varToImport), result.isTemplate = getIsTemplate(openingElement), result.metaTags = getTags(openingElement);
|
|
82
|
-
}
|
|
83
|
-
} else if (child.type !== "JSXExpressionContainer")
|
|
84
|
-
throw new Error(`Unexpected JSX child: ${child.type}`);
|
|
85
|
-
}), result;
|
|
86
|
-
}, extractImports = (root) => {
|
|
87
|
-
let varToImport = {};
|
|
88
|
-
return root.body.forEach((child) => {
|
|
89
|
-
if (child.type === "ImportDeclaration") {
|
|
90
|
-
let { source, specifiers } = child;
|
|
91
|
-
if (source.type === "Literal")
|
|
92
|
-
specifiers.forEach((s) => {
|
|
93
|
-
varToImport[s.local.name] = source.value.toString();
|
|
94
|
-
});
|
|
95
|
-
else
|
|
96
|
-
throw new Error("MDX: unexpected import source");
|
|
97
|
-
}
|
|
98
|
-
}), varToImport;
|
|
99
|
-
}, plugin = (store) => (root) => {
|
|
100
|
-
let estree = toEstree(root), varToImport = extractImports(estree), { title, of, name, isTemplate, metaTags } = extractTitle(estree, varToImport);
|
|
101
|
-
return store.title = title, store.of = of, store.name = name, store.isTemplate = isTemplate, store.metaTags = metaTags, store.imports = Array.from(new Set(Object.values(varToImport))), root;
|
|
102
|
-
}, analyze = async (code) => {
|
|
103
|
-
let store = {
|
|
104
|
-
title: void 0,
|
|
105
|
-
of: void 0,
|
|
106
|
-
name: void 0,
|
|
107
|
-
isTemplate: !1,
|
|
108
|
-
metaTags: void 0,
|
|
109
|
-
imports: void 0
|
|
110
|
-
}, { compile } = await import("./mdx-N42X6CFJ-CRGM5LTU.js");
|
|
111
|
-
await compile(code, {
|
|
112
|
-
rehypePlugins: [[plugin, store]]
|
|
113
|
-
});
|
|
114
|
-
let { title, of, name, isTemplate, metaTags, imports = [] } = store;
|
|
115
|
-
return { title, of, name, isTemplate, metaTags, imports };
|
|
116
|
-
};
|
|
117
|
-
export {
|
|
118
|
-
analyze,
|
|
119
|
-
extractImports,
|
|
120
|
-
plugin
|
|
121
|
-
};
|