@storybook/vue3 11.0.0-beta.3 → 11.0.0-beta.4
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/{chunk-FBNGCEV4.js → chunk-B2JTNJGN.js} +2 -1
- package/dist/_node-chunks/{chunk-EXKPL3GN.js → chunk-7WHIMGTJ.js} +0 -12
- package/dist/_node-chunks/{chunk-YC7LL7PU.js → chunk-B2AO4N3K.js} +0 -12
- package/dist/_node-chunks/{chunk-W36MGWLZ.js → chunk-HCZJLA2R.js} +1 -12
- package/dist/_node-chunks/{chunk-3SJGJI3U.js → chunk-P5M6CRJS.js} +9 -14
- package/dist/_node-chunks/component-meta-FWIOHTOX.js +12 -0
- package/dist/_node-chunks/{parsers-IGXDWSPE.js → parsers-G5Q2PPX6.js} +0 -12
- package/dist/_node-chunks/vue-docgen-api-IRJAMTGH.js +5 -0
- package/dist/docgen/docgen-worker.js +3 -14
- package/dist/docgen/index.js +4 -15
- package/dist/entry-preview.js +1 -1
- package/dist/index.js +1 -1
- package/dist/preset.js +5 -16
- package/package.json +2 -2
- package/dist/_node-chunks/component-meta-INN5C3JN.js +0 -23
- package/dist/_node-chunks/vue-docgen-api-W5YSLRHZ.js +0 -17
|
@@ -161,6 +161,7 @@ var render = (props, context) => {
|
|
|
161
161
|
globalThis && globalThis.PLUGINS_SETUP_FUNCTIONS && await Promise.all([...globalThis.PLUGINS_SETUP_FUNCTIONS].map((fn) => fn(app, storyContext)));
|
|
162
162
|
}, map = /* @__PURE__ */ new Map();
|
|
163
163
|
async function renderToCanvas({ storyFn, forceRemount, showMain, showException, storyContext, id }, canvasElement) {
|
|
164
|
+
showMain();
|
|
164
165
|
let existingApp = map.get(canvasElement);
|
|
165
166
|
if (existingApp && !forceRemount) {
|
|
166
167
|
let element = storyFn(), args = getArgs(element, storyContext);
|
|
@@ -186,7 +187,7 @@ async function renderToCanvas({ storyFn, forceRemount, showMain, showException,
|
|
|
186
187
|
) ? setTimeout(() => {
|
|
187
188
|
throw e;
|
|
188
189
|
}, 0) : showException(e);
|
|
189
|
-
}, await runSetupFunctions(vueApp, storyContext), vueApp.mount(canvasElement),
|
|
190
|
+
}, await runSetupFunctions(vueApp, storyContext), vueApp.mount(canvasElement), () => {
|
|
190
191
|
teardown(vueApp, canvasElement);
|
|
191
192
|
};
|
|
192
193
|
}
|
|
@@ -1,15 +1,3 @@
|
|
|
1
|
-
import CJS_COMPAT_NODE_URL_zicg01r0ufl from 'node:url';
|
|
2
|
-
import CJS_COMPAT_NODE_PATH_zicg01r0ufl from 'node:path';
|
|
3
|
-
import CJS_COMPAT_NODE_MODULE_zicg01r0ufl from "node:module";
|
|
4
|
-
|
|
5
|
-
var __filename = CJS_COMPAT_NODE_URL_zicg01r0ufl.fileURLToPath(import.meta.url);
|
|
6
|
-
var __dirname = CJS_COMPAT_NODE_PATH_zicg01r0ufl.dirname(__filename);
|
|
7
|
-
var require = CJS_COMPAT_NODE_MODULE_zicg01r0ufl.createRequire(import.meta.url);
|
|
8
|
-
|
|
9
|
-
// ------------------------------------------------------------
|
|
10
|
-
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
-
// ------------------------------------------------------------
|
|
12
|
-
|
|
13
1
|
// src/docgen/component-docgen/component-meta/component-meta.ts
|
|
14
2
|
import { readFile, stat } from "node:fs/promises";
|
|
15
3
|
import { join, parse } from "node:path";
|
|
@@ -1,15 +1,3 @@
|
|
|
1
|
-
import CJS_COMPAT_NODE_URL_zicg01r0ufl from 'node:url';
|
|
2
|
-
import CJS_COMPAT_NODE_PATH_zicg01r0ufl from 'node:path';
|
|
3
|
-
import CJS_COMPAT_NODE_MODULE_zicg01r0ufl from "node:module";
|
|
4
|
-
|
|
5
|
-
var __filename = CJS_COMPAT_NODE_URL_zicg01r0ufl.fileURLToPath(import.meta.url);
|
|
6
|
-
var __dirname = CJS_COMPAT_NODE_PATH_zicg01r0ufl.dirname(__filename);
|
|
7
|
-
var require = CJS_COMPAT_NODE_MODULE_zicg01r0ufl.createRequire(import.meta.url);
|
|
8
|
-
|
|
9
|
-
// ------------------------------------------------------------
|
|
10
|
-
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
-
// ------------------------------------------------------------
|
|
12
|
-
|
|
13
1
|
// src/snippet-values.ts
|
|
14
2
|
var attributeOrder = (a, b) => a.localeCompare(b), slotOrder = (a, b) => a === "default" ? -1 : b === "default" ? 1 : a.localeCompare(b);
|
|
15
3
|
function quoteAttributeValue(value) {
|
|
@@ -1,14 +1,3 @@
|
|
|
1
|
-
import CJS_COMPAT_NODE_URL_zicg01r0ufl from 'node:url';
|
|
2
|
-
import CJS_COMPAT_NODE_PATH_zicg01r0ufl from 'node:path';
|
|
3
|
-
import CJS_COMPAT_NODE_MODULE_zicg01r0ufl from "node:module";
|
|
4
|
-
|
|
5
|
-
var __filename = CJS_COMPAT_NODE_URL_zicg01r0ufl.fileURLToPath(import.meta.url);
|
|
6
|
-
var __dirname = CJS_COMPAT_NODE_PATH_zicg01r0ufl.dirname(__filename);
|
|
7
|
-
var require = CJS_COMPAT_NODE_MODULE_zicg01r0ufl.createRequire(import.meta.url);
|
|
8
|
-
|
|
9
|
-
// ------------------------------------------------------------
|
|
10
|
-
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
-
// ------------------------------------------------------------
|
|
12
1
|
import {
|
|
13
2
|
attributeOrder,
|
|
14
3
|
escapeTextContent,
|
|
@@ -20,7 +9,7 @@ import {
|
|
|
20
9
|
slotContent,
|
|
21
10
|
slotOrder,
|
|
22
11
|
wrapSlotContent
|
|
23
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-B2AO4N3K.js";
|
|
24
13
|
|
|
25
14
|
// src/docgen/story-docs/build-story-docs.ts
|
|
26
15
|
import { readFile } from "node:fs/promises";
|
|
@@ -1,20 +1,9 @@
|
|
|
1
|
-
import CJS_COMPAT_NODE_URL_zicg01r0ufl from 'node:url';
|
|
2
|
-
import CJS_COMPAT_NODE_PATH_zicg01r0ufl from 'node:path';
|
|
3
|
-
import CJS_COMPAT_NODE_MODULE_zicg01r0ufl from "node:module";
|
|
4
|
-
|
|
5
|
-
var __filename = CJS_COMPAT_NODE_URL_zicg01r0ufl.fileURLToPath(import.meta.url);
|
|
6
|
-
var __dirname = CJS_COMPAT_NODE_PATH_zicg01r0ufl.dirname(__filename);
|
|
7
|
-
var require = CJS_COMPAT_NODE_MODULE_zicg01r0ufl.createRequire(import.meta.url);
|
|
8
|
-
|
|
9
|
-
// ------------------------------------------------------------
|
|
10
|
-
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
-
// ------------------------------------------------------------
|
|
12
1
|
import {
|
|
13
2
|
indent
|
|
14
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-B2AO4N3K.js";
|
|
15
4
|
import {
|
|
16
5
|
collectComponentMetaSources
|
|
17
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-7WHIMGTJ.js";
|
|
18
7
|
|
|
19
8
|
// src/docgen/component-docgen/arg-types/extractArgTypes.ts
|
|
20
9
|
import { convert, extractComponentProps, hasDocgen } from "storybook/internal/docs-tools";
|
|
@@ -338,6 +327,7 @@ import {
|
|
|
338
327
|
storyShapeError
|
|
339
328
|
} from "storybook/internal/csf-tools";
|
|
340
329
|
import {
|
|
330
|
+
componentPathFromStory,
|
|
341
331
|
extractDeclaredSubcomponents,
|
|
342
332
|
getComponentIdFromEntry,
|
|
343
333
|
getStoryImportPathFromEntry
|
|
@@ -395,6 +385,10 @@ var META_COMPONENT_NAME = /^[A-Za-z_$][\w$]*(\.[A-Za-z_$][\w$]*)*$/, NON_COMPONE
|
|
|
395
385
|
name: "No component import found",
|
|
396
386
|
message: `No component file found for the component declared in ${subject}. Import it into the story file.`
|
|
397
387
|
}),
|
|
388
|
+
"missing-export": (subject) => ({
|
|
389
|
+
name: "No component found",
|
|
390
|
+
message: `${subject} names an export that its module does not have. Check the name against the module's exports, and any barrel that re-exports it.`
|
|
391
|
+
}),
|
|
398
392
|
"unreadable-component-expression": (subject) => ({
|
|
399
393
|
name: "No component found",
|
|
400
394
|
message: `We could not follow ${subject} to a component. Storybook follows an imported name, a namespace-import property access, or a chain of property accesses and spreads through modules it can resolve.`
|
|
@@ -468,7 +462,8 @@ async function buildSubcomponentDocgen(csf, storyPath, storyFilePath, declared,
|
|
|
468
462
|
});
|
|
469
463
|
return "error" in extracted ? failure(extracted.error) : {
|
|
470
464
|
name: declared.componentName,
|
|
471
|
-
path
|
|
465
|
+
// Written like the story's index path, as in the other renderers, not as a machine path.
|
|
466
|
+
path: componentPathFromStory(storyFilePath, storyPath, extracted.path),
|
|
472
467
|
description: extracted.description,
|
|
473
468
|
summary: extracted.summary,
|
|
474
469
|
jsDocTags: extracted.jsDocTags,
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import {
|
|
2
|
+
CHECKER_OPTIONS,
|
|
3
|
+
applyVueDocgenApiTempFixes,
|
|
4
|
+
collectComponentMetaSources,
|
|
5
|
+
createVueComponentMetaChecker
|
|
6
|
+
} from "./chunk-7WHIMGTJ.js";
|
|
7
|
+
export {
|
|
8
|
+
CHECKER_OPTIONS,
|
|
9
|
+
applyVueDocgenApiTempFixes,
|
|
10
|
+
collectComponentMetaSources,
|
|
11
|
+
createVueComponentMetaChecker
|
|
12
|
+
};
|
|
@@ -1,15 +1,3 @@
|
|
|
1
|
-
import CJS_COMPAT_NODE_URL_zicg01r0ufl from 'node:url';
|
|
2
|
-
import CJS_COMPAT_NODE_PATH_zicg01r0ufl from 'node:path';
|
|
3
|
-
import CJS_COMPAT_NODE_MODULE_zicg01r0ufl from "node:module";
|
|
4
|
-
|
|
5
|
-
var __filename = CJS_COMPAT_NODE_URL_zicg01r0ufl.fileURLToPath(import.meta.url);
|
|
6
|
-
var __dirname = CJS_COMPAT_NODE_PATH_zicg01r0ufl.dirname(__filename);
|
|
7
|
-
var require = CJS_COMPAT_NODE_MODULE_zicg01r0ufl.createRequire(import.meta.url);
|
|
8
|
-
|
|
9
|
-
// ------------------------------------------------------------
|
|
10
|
-
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
-
// ------------------------------------------------------------
|
|
12
|
-
|
|
13
1
|
// src/parsers/vueImportParser.ts
|
|
14
2
|
import {
|
|
15
3
|
ChangeDetectionFailureError
|
|
@@ -1,21 +1,10 @@
|
|
|
1
|
-
import CJS_COMPAT_NODE_URL_zicg01r0ufl from 'node:url';
|
|
2
|
-
import CJS_COMPAT_NODE_PATH_zicg01r0ufl from 'node:path';
|
|
3
|
-
import CJS_COMPAT_NODE_MODULE_zicg01r0ufl from "node:module";
|
|
4
|
-
|
|
5
|
-
var __filename = CJS_COMPAT_NODE_URL_zicg01r0ufl.fileURLToPath(import.meta.url);
|
|
6
|
-
var __dirname = CJS_COMPAT_NODE_PATH_zicg01r0ufl.dirname(__filename);
|
|
7
|
-
var require = CJS_COMPAT_NODE_MODULE_zicg01r0ufl.createRequire(import.meta.url);
|
|
8
|
-
|
|
9
|
-
// ------------------------------------------------------------
|
|
10
|
-
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
-
// ------------------------------------------------------------
|
|
12
1
|
import {
|
|
13
2
|
buildDocgenPayload
|
|
14
|
-
} from "../_node-chunks/chunk-
|
|
15
|
-
import "../_node-chunks/chunk-
|
|
3
|
+
} from "../_node-chunks/chunk-P5M6CRJS.js";
|
|
4
|
+
import "../_node-chunks/chunk-B2AO4N3K.js";
|
|
16
5
|
import {
|
|
17
6
|
CHECKER_OPTIONS
|
|
18
|
-
} from "../_node-chunks/chunk-
|
|
7
|
+
} from "../_node-chunks/chunk-7WHIMGTJ.js";
|
|
19
8
|
|
|
20
9
|
// src/docgen/docgen-worker.ts
|
|
21
10
|
import { createLazyDocgenMiddleware, loadTypeScriptCompilerApi } from "storybook/internal/common";
|
package/dist/docgen/index.js
CHANGED
|
@@ -1,29 +1,18 @@
|
|
|
1
|
-
import CJS_COMPAT_NODE_URL_zicg01r0ufl from 'node:url';
|
|
2
|
-
import CJS_COMPAT_NODE_PATH_zicg01r0ufl from 'node:path';
|
|
3
|
-
import CJS_COMPAT_NODE_MODULE_zicg01r0ufl from "node:module";
|
|
4
|
-
|
|
5
|
-
var __filename = CJS_COMPAT_NODE_URL_zicg01r0ufl.fileURLToPath(import.meta.url);
|
|
6
|
-
var __dirname = CJS_COMPAT_NODE_PATH_zicg01r0ufl.dirname(__filename);
|
|
7
|
-
var require = CJS_COMPAT_NODE_MODULE_zicg01r0ufl.createRequire(import.meta.url);
|
|
8
|
-
|
|
9
|
-
// ------------------------------------------------------------
|
|
10
|
-
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
-
// ------------------------------------------------------------
|
|
12
1
|
import {
|
|
13
2
|
buildStoryDocsPayload
|
|
14
|
-
} from "../_node-chunks/chunk-
|
|
3
|
+
} from "../_node-chunks/chunk-HCZJLA2R.js";
|
|
15
4
|
import {
|
|
16
5
|
buildApiDescription,
|
|
17
6
|
buildDocgenPayload,
|
|
18
7
|
createNamedTypeDetailResolver,
|
|
19
8
|
extractArgTypes
|
|
20
|
-
} from "../_node-chunks/chunk-
|
|
21
|
-
import "../_node-chunks/chunk-
|
|
9
|
+
} from "../_node-chunks/chunk-P5M6CRJS.js";
|
|
10
|
+
import "../_node-chunks/chunk-B2AO4N3K.js";
|
|
22
11
|
import {
|
|
23
12
|
CHECKER_OPTIONS,
|
|
24
13
|
applyVueDocgenApiTempFixes,
|
|
25
14
|
collectComponentMetaSources
|
|
26
|
-
} from "../_node-chunks/chunk-
|
|
15
|
+
} from "../_node-chunks/chunk-7WHIMGTJ.js";
|
|
27
16
|
|
|
28
17
|
// src/docgen/story-docs/source-decorator/sourceDecorator.ts
|
|
29
18
|
import { SourceType } from "storybook/internal/docs-tools";
|
package/dist/entry-preview.js
CHANGED
package/dist/index.js
CHANGED
package/dist/preset.js
CHANGED
|
@@ -1,18 +1,7 @@
|
|
|
1
|
-
import CJS_COMPAT_NODE_URL_zicg01r0ufl from 'node:url';
|
|
2
|
-
import CJS_COMPAT_NODE_PATH_zicg01r0ufl from 'node:path';
|
|
3
|
-
import CJS_COMPAT_NODE_MODULE_zicg01r0ufl from "node:module";
|
|
4
|
-
|
|
5
|
-
var __filename = CJS_COMPAT_NODE_URL_zicg01r0ufl.fileURLToPath(import.meta.url);
|
|
6
|
-
var __dirname = CJS_COMPAT_NODE_PATH_zicg01r0ufl.dirname(__filename);
|
|
7
|
-
var require = CJS_COMPAT_NODE_MODULE_zicg01r0ufl.createRequire(import.meta.url);
|
|
8
|
-
|
|
9
|
-
// ------------------------------------------------------------
|
|
10
|
-
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
-
// ------------------------------------------------------------
|
|
12
1
|
import {
|
|
13
2
|
buildStoryDocsPayload
|
|
14
|
-
} from "./_node-chunks/chunk-
|
|
15
|
-
import "./_node-chunks/chunk-
|
|
3
|
+
} from "./_node-chunks/chunk-HCZJLA2R.js";
|
|
4
|
+
import "./_node-chunks/chunk-B2AO4N3K.js";
|
|
16
5
|
|
|
17
6
|
// src/preset.ts
|
|
18
7
|
import { fileURLToPath as fileURLToPath3 } from "node:url";
|
|
@@ -48,8 +37,8 @@ var experimental_storyDocsProvider = createWorkerGatedStoryDocsProvider({
|
|
|
48
37
|
|
|
49
38
|
// src/docgen/engine.ts
|
|
50
39
|
var experimental_vueDocgenEngine = async () => ({
|
|
51
|
-
componentMeta: () => import("./_node-chunks/component-meta-
|
|
52
|
-
vueDocgenApi: () => import("./_node-chunks/vue-docgen-api-
|
|
40
|
+
componentMeta: () => import("./_node-chunks/component-meta-FWIOHTOX.js"),
|
|
41
|
+
vueDocgenApi: () => import("./_node-chunks/vue-docgen-api-IRJAMTGH.js")
|
|
53
42
|
});
|
|
54
43
|
|
|
55
44
|
// src/preset.ts
|
|
@@ -62,7 +51,7 @@ var isDocgenProviderEnabled = (_existing, options) => isTypeScriptReadyForDocgen
|
|
|
62
51
|
docsEnabled ? [fileURLToPath3(import.meta.resolve("@storybook/vue3/entry-preview-docs"))] : []
|
|
63
52
|
);
|
|
64
53
|
}, experimental_importParsers = async (input = []) => {
|
|
65
|
-
let { vueImportParser } = await import("./_node-chunks/parsers-
|
|
54
|
+
let { vueImportParser } = await import("./_node-chunks/parsers-G5Q2PPX6.js");
|
|
66
55
|
return [...input, vueImportParser];
|
|
67
56
|
};
|
|
68
57
|
export {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@storybook/vue3",
|
|
3
|
-
"version": "11.0.0-beta.
|
|
3
|
+
"version": "11.0.0-beta.4",
|
|
4
4
|
"description": "Storybook Vue 3 renderer: Develop, document, and test UI components in isolation",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"storybook",
|
|
@@ -71,7 +71,7 @@
|
|
|
71
71
|
"vue-tsc": "latest"
|
|
72
72
|
},
|
|
73
73
|
"peerDependencies": {
|
|
74
|
-
"storybook": "^11.0.0-beta.
|
|
74
|
+
"storybook": "^11.0.0-beta.4",
|
|
75
75
|
"typescript": "^5.9.0 || ^6.0.0 || ^7.0.0",
|
|
76
76
|
"vue": "^3.0.0"
|
|
77
77
|
},
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import CJS_COMPAT_NODE_URL_zicg01r0ufl from 'node:url';
|
|
2
|
-
import CJS_COMPAT_NODE_PATH_zicg01r0ufl from 'node:path';
|
|
3
|
-
import CJS_COMPAT_NODE_MODULE_zicg01r0ufl from "node:module";
|
|
4
|
-
|
|
5
|
-
var __filename = CJS_COMPAT_NODE_URL_zicg01r0ufl.fileURLToPath(import.meta.url);
|
|
6
|
-
var __dirname = CJS_COMPAT_NODE_PATH_zicg01r0ufl.dirname(__filename);
|
|
7
|
-
var require = CJS_COMPAT_NODE_MODULE_zicg01r0ufl.createRequire(import.meta.url);
|
|
8
|
-
|
|
9
|
-
// ------------------------------------------------------------
|
|
10
|
-
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
-
// ------------------------------------------------------------
|
|
12
|
-
import {
|
|
13
|
-
CHECKER_OPTIONS,
|
|
14
|
-
applyVueDocgenApiTempFixes,
|
|
15
|
-
collectComponentMetaSources,
|
|
16
|
-
createVueComponentMetaChecker
|
|
17
|
-
} from "./chunk-EXKPL3GN.js";
|
|
18
|
-
export {
|
|
19
|
-
CHECKER_OPTIONS,
|
|
20
|
-
applyVueDocgenApiTempFixes,
|
|
21
|
-
collectComponentMetaSources,
|
|
22
|
-
createVueComponentMetaChecker
|
|
23
|
-
};
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import CJS_COMPAT_NODE_URL_zicg01r0ufl from 'node:url';
|
|
2
|
-
import CJS_COMPAT_NODE_PATH_zicg01r0ufl from 'node:path';
|
|
3
|
-
import CJS_COMPAT_NODE_MODULE_zicg01r0ufl from "node:module";
|
|
4
|
-
|
|
5
|
-
var __filename = CJS_COMPAT_NODE_URL_zicg01r0ufl.fileURLToPath(import.meta.url);
|
|
6
|
-
var __dirname = CJS_COMPAT_NODE_PATH_zicg01r0ufl.dirname(__filename);
|
|
7
|
-
var require = CJS_COMPAT_NODE_MODULE_zicg01r0ufl.createRequire(import.meta.url);
|
|
8
|
-
|
|
9
|
-
// ------------------------------------------------------------
|
|
10
|
-
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
|
11
|
-
// ------------------------------------------------------------
|
|
12
|
-
|
|
13
|
-
// src/docgen/vue-docgen-api.ts
|
|
14
|
-
import { parse } from "vue-docgen-api";
|
|
15
|
-
export {
|
|
16
|
-
parse
|
|
17
|
-
};
|