@stencil/storybook-plugin 0.5.6 → 0.6.0-dev.1783515311.4f8a25b
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/README.md +42 -138
- package/dist/docs/{index.d.ts → index.d.mts} +2 -4
- package/dist/docs/index.d.mts.map +1 -0
- package/dist/{docs-DFb4MYCm.js → docs/index.mjs} +17 -30
- package/dist/docs/index.mjs.map +1 -0
- package/dist/{entry-preview-C1JSJAGq.js → entry-preview-6xYusSlJ.mjs} +19 -22
- package/dist/entry-preview-6xYusSlJ.mjs.map +1 -0
- package/dist/entry-preview-argtypes.d.mts +14 -0
- package/dist/entry-preview-argtypes.d.mts.map +1 -0
- package/dist/entry-preview-argtypes.mjs +165 -0
- package/dist/entry-preview-argtypes.mjs.map +1 -0
- package/dist/entry-preview-auto-docs.d.mts +1 -0
- package/dist/entry-preview-auto-docs.mjs +11 -0
- package/dist/entry-preview-auto-docs.mjs.map +1 -0
- package/dist/{entry-preview-docs.d.ts → entry-preview-docs.d.mts} +2 -4
- package/dist/entry-preview-docs.d.mts.map +1 -0
- package/dist/{entry-preview-docs.js → entry-preview-docs.mjs} +3 -4
- package/dist/entry-preview-docs.mjs.map +1 -0
- package/dist/{entry-preview.d.ts → entry-preview.d.mts} +2 -5
- package/dist/entry-preview.d.mts.map +1 -0
- package/dist/entry-preview.mjs +2 -0
- package/dist/framework-api-oAIB4EMV.mjs +27 -0
- package/dist/framework-api-oAIB4EMV.mjs.map +1 -0
- package/dist/index.d.mts +677 -0
- package/dist/index.d.mts.map +1 -0
- package/dist/index.mjs +32 -0
- package/dist/index.mjs.map +1 -0
- package/dist/node/{index.d.ts → index.d.mts} +2 -4
- package/dist/node/index.d.mts.map +1 -0
- package/dist/node/{index.js → index.mjs} +2 -2
- package/dist/node/index.mjs.map +1 -0
- package/dist/{preset.d.ts → preset.d.mts} +2 -4
- package/dist/preset.d.mts.map +1 -0
- package/dist/preset.mjs +35 -0
- package/dist/preset.mjs.map +1 -0
- package/dist/{rollup-parseAst-t-4tfMPG.d.ts → rollup-parseAst-DL0ij9mb.d.mts} +1 -1
- package/dist/rollup-parseAst-DL0ij9mb.d.mts.map +1 -0
- package/dist/{types-BZP9npQ9.d.cts → types-KTmT9_JX.d.mts} +2 -2
- package/dist/types-KTmT9_JX.d.mts.map +1 -0
- package/dist/wizard.d.mts +7 -0
- package/dist/wizard.d.mts.map +1 -0
- package/dist/wizard.mjs +159 -0
- package/dist/wizard.mjs.map +1 -0
- package/package.json +34 -35
- package/preset.js +1 -2
- package/dist/chunk-CsX-DzYB.cjs +0 -42
- package/dist/docs/index.cjs +0 -4
- package/dist/docs/index.d.cts +0 -15
- package/dist/docs/index.d.cts.map +0 -1
- package/dist/docs/index.d.ts.map +0 -1
- package/dist/docs/index.js +0 -3
- package/dist/docs-DFb4MYCm.js.map +0 -1
- package/dist/docs-ONVKsKI9.cjs +0 -97
- package/dist/docs-ONVKsKI9.cjs.map +0 -1
- package/dist/entry-preview-C0ipNwpw.cjs +0 -85
- package/dist/entry-preview-C0ipNwpw.cjs.map +0 -1
- package/dist/entry-preview-C1JSJAGq.js.map +0 -1
- package/dist/entry-preview-argtypes.cjs +0 -182
- package/dist/entry-preview-argtypes.cjs.map +0 -1
- package/dist/entry-preview-argtypes.d.cts +0 -19
- package/dist/entry-preview-argtypes.d.cts.map +0 -1
- package/dist/entry-preview-argtypes.d.ts +0 -19
- package/dist/entry-preview-argtypes.d.ts.map +0 -1
- package/dist/entry-preview-argtypes.js +0 -181
- package/dist/entry-preview-argtypes.js.map +0 -1
- package/dist/entry-preview-docs.cjs +0 -19
- package/dist/entry-preview-docs.cjs.map +0 -1
- package/dist/entry-preview-docs.d.cts +0 -11
- package/dist/entry-preview-docs.d.cts.map +0 -1
- package/dist/entry-preview-docs.d.ts.map +0 -1
- package/dist/entry-preview-docs.js.map +0 -1
- package/dist/entry-preview.cjs +0 -6
- package/dist/entry-preview.d.cts +0 -20
- package/dist/entry-preview.d.cts.map +0 -1
- package/dist/entry-preview.d.ts.map +0 -1
- package/dist/entry-preview.js +0 -3
- package/dist/index.cjs +0 -9
- package/dist/index.d.cts +0 -65
- package/dist/index.d.cts.map +0 -1
- package/dist/index.d.ts +0 -40
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js +0 -5
- package/dist/node/index.cjs +0 -9
- package/dist/node/index.cjs.map +0 -1
- package/dist/node/index.d.cts +0 -9
- package/dist/node/index.d.cts.map +0 -1
- package/dist/node/index.d.ts.map +0 -1
- package/dist/node/index.js.map +0 -1
- package/dist/preset.cjs +0 -35
- package/dist/preset.cjs.map +0 -1
- package/dist/preset.d.cts +0 -11
- package/dist/preset.d.cts.map +0 -1
- package/dist/preset.d.ts.map +0 -1
- package/dist/preset.js +0 -32
- package/dist/preset.js.map +0 -1
- package/dist/rollup-parseAst-t-4tfMPG.d.ts.map +0 -1
- package/dist/src-BBcTbcCa.js +0 -55
- package/dist/src-BBcTbcCa.js.map +0 -1
- package/dist/src-D0dJRYm2.cjs +0 -91
- package/dist/src-D0dJRYm2.cjs.map +0 -1
- package/dist/types-BZP9npQ9.d.cts.map +0 -1
- package/dist/types-DqHtEV5w.d.ts +0 -71
- package/dist/types-DqHtEV5w.d.ts.map +0 -1
package/dist/docs-ONVKsKI9.cjs
DELETED
|
@@ -1,97 +0,0 @@
|
|
|
1
|
-
const require_chunk = require('./chunk-CsX-DzYB.cjs');
|
|
2
|
-
const storybook_internal_docs_tools = require_chunk.__toESM(require("storybook/internal/docs-tools"));
|
|
3
|
-
const storybook_internal_preview_api = require_chunk.__toESM(require("storybook/internal/preview-api"));
|
|
4
|
-
|
|
5
|
-
//#region src/docs/render-vnode.ts
|
|
6
|
-
function kebabToPascal(str) {
|
|
7
|
-
return str.split("-").map((part) => part.charAt(0).toUpperCase() + part.slice(1)).join("");
|
|
8
|
-
}
|
|
9
|
-
function vnodeToString(node, options, indentLevel = 0) {
|
|
10
|
-
const LINE_WIDTH = 80;
|
|
11
|
-
const indent = " ".repeat(indentLevel);
|
|
12
|
-
const { mode } = options;
|
|
13
|
-
if (node.$text$ !== null) return indent + node.$text$;
|
|
14
|
-
if (node.$tag$ === null) return "";
|
|
15
|
-
const tag = mode === "jsx" && typeof node.$tag$ === "string" && node.$tag$.includes("-") ? kebabToPascal(node.$tag$) : String(node.$tag$);
|
|
16
|
-
const attrArray = node.$attrs$ ? Object.entries(node.$attrs$).filter(([_, value]) => value !== void 0).map(([key, value]) => {
|
|
17
|
-
let attrName = key;
|
|
18
|
-
if (mode === "jsx") {
|
|
19
|
-
const htmlToJsx = {
|
|
20
|
-
class: "className",
|
|
21
|
-
for: "htmlFor",
|
|
22
|
-
tabindex: "tabIndex"
|
|
23
|
-
};
|
|
24
|
-
attrName = htmlToJsx[key] || key;
|
|
25
|
-
}
|
|
26
|
-
if (typeof value === "function") return "";
|
|
27
|
-
if (typeof value === "boolean") return value ? attrName : "";
|
|
28
|
-
if (typeof value === "string") return `${attrName}="${value}"`;
|
|
29
|
-
if (mode === "jsx") return `${attrName}={${JSON.stringify(value)}}`;
|
|
30
|
-
return `${attrName}="${value}"`;
|
|
31
|
-
}).filter((attr) => attr.trim()) : [];
|
|
32
|
-
const children = node.$children$ ?? [];
|
|
33
|
-
if (children.length === 0) {
|
|
34
|
-
const attrsStr$1 = attrArray.length > 0 ? " " + attrArray.join(" ") : "";
|
|
35
|
-
const singleLine = mode === "jsx" ? `${indent}<${tag}${attrsStr$1} />` : `${indent}<${tag}${attrsStr$1}></${tag}>`;
|
|
36
|
-
if (singleLine.length <= LINE_WIDTH) return singleLine;
|
|
37
|
-
const attrIndent$1 = indent + " ";
|
|
38
|
-
const formattedAttrs$1 = attrArray.length > 0 ? "\n" + attrArray.map((attr) => `${attrIndent$1}${attr}`).join("\n") + "\n" + indent : "";
|
|
39
|
-
return mode === "jsx" ? `${indent}<${tag}${formattedAttrs$1}/>` : `${indent}<${tag}${formattedAttrs$1}></${tag}>`;
|
|
40
|
-
}
|
|
41
|
-
const attrsStr = attrArray.length > 0 ? " " + attrArray.join(" ") : "";
|
|
42
|
-
const openingTag = `${indent}<${tag}${attrsStr}>`;
|
|
43
|
-
if (openingTag.length <= LINE_WIDTH) {
|
|
44
|
-
const childrenString$1 = children.map((child) => vnodeToString(child, options, indentLevel + 1)).join("\n");
|
|
45
|
-
return `${openingTag}\n${childrenString$1}\n${indent}</${tag}>`;
|
|
46
|
-
}
|
|
47
|
-
const attrIndent = indent + " ";
|
|
48
|
-
const formattedAttrs = attrArray.length > 0 ? "\n" + attrArray.map((attr) => `${attrIndent}${attr}`).join("\n") + "\n" + indent : "";
|
|
49
|
-
const childrenString = children.map((child) => vnodeToString(child, options, indentLevel + 1)).join("\n");
|
|
50
|
-
return `${indent}<${tag}${formattedAttrs}>\n${childrenString}\n${indent}</${tag}>`;
|
|
51
|
-
}
|
|
52
|
-
const renderVNode = (vnode, mode) => {
|
|
53
|
-
return vnodeToString(vnode, { mode });
|
|
54
|
-
};
|
|
55
|
-
|
|
56
|
-
//#endregion
|
|
57
|
-
//#region src/docs/source-decorator.ts
|
|
58
|
-
const skip = (context) => {
|
|
59
|
-
const sourceParams = context?.parameters.docs?.source;
|
|
60
|
-
const isArgsStory = context?.parameters.__isArgsStory;
|
|
61
|
-
if (sourceParams.type === storybook_internal_docs_tools.SourceType.DYNAMIC) return false;
|
|
62
|
-
return !isArgsStory || sourceParams?.code || sourceParams?.type === storybook_internal_docs_tools.SourceType.CODE;
|
|
63
|
-
};
|
|
64
|
-
const sourceDecorator = (storyFn, context) => {
|
|
65
|
-
const story = storyFn();
|
|
66
|
-
(0, storybook_internal_preview_api.useEffect)(() => {
|
|
67
|
-
const renderedForSource = context?.parameters.docs?.source?.excludeDecorators ? context.originalStoryFn(context.args, context) : story;
|
|
68
|
-
if (skip(context)) return;
|
|
69
|
-
switch (context.parameters.docs.source.language) {
|
|
70
|
-
case "html": {
|
|
71
|
-
(0, storybook_internal_preview_api.emitTransformCode)(renderVNode(renderedForSource, "html"), context);
|
|
72
|
-
break;
|
|
73
|
-
}
|
|
74
|
-
case "jsx":
|
|
75
|
-
case "tsx": {
|
|
76
|
-
(0, storybook_internal_preview_api.emitTransformCode)(renderVNode(renderedForSource, "jsx"), context);
|
|
77
|
-
break;
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
});
|
|
81
|
-
return story;
|
|
82
|
-
};
|
|
83
|
-
|
|
84
|
-
//#endregion
|
|
85
|
-
Object.defineProperty(exports, 'renderVNode', {
|
|
86
|
-
enumerable: true,
|
|
87
|
-
get: function () {
|
|
88
|
-
return renderVNode;
|
|
89
|
-
}
|
|
90
|
-
});
|
|
91
|
-
Object.defineProperty(exports, 'sourceDecorator', {
|
|
92
|
-
enumerable: true,
|
|
93
|
-
get: function () {
|
|
94
|
-
return sourceDecorator;
|
|
95
|
-
}
|
|
96
|
-
});
|
|
97
|
-
//# sourceMappingURL=docs-ONVKsKI9.cjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"docs-ONVKsKI9.cjs","names":["str: string","node: VNode","options: RenderOptions","htmlToJsx: Record<string, string>","attrsStr","attrIndent","formattedAttrs","childrenString","vnode: VNode","mode: RenderMode","context: Parameters<DecoratorFunction<StencilRenderer<unknown>>>[1]","SourceType","sourceDecorator: DecoratorFunction<StencilRenderer<unknown>>"],"sources":["../src/docs/render-vnode.ts","../src/docs/source-decorator.ts"],"sourcesContent":["import { type VNode } from '@stencil/core';\n\ntype RenderMode = 'html' | 'jsx';\n\ninterface RenderOptions {\n mode: RenderMode;\n}\n\nfunction kebabToPascal(str: string): string {\n return str\n .split('-')\n .map((part) => part.charAt(0).toUpperCase() + part.slice(1))\n .join('');\n}\n\nfunction vnodeToString(node: VNode, options: RenderOptions, indentLevel = 0): string {\n const LINE_WIDTH = 80;\n const indent = ' '.repeat(indentLevel);\n const { mode } = options;\n\n if (node.$text$ !== null) {\n return indent + node.$text$;\n }\n\n if (node.$tag$ === null) {\n return '';\n }\n\n // Convert tag name based on mode\n // Only convert to PascalCase if it's a custom element (has a dash)\n const tag =\n mode === 'jsx' && typeof node.$tag$ === 'string' && node.$tag$.includes('-')\n ? kebabToPascal(node.$tag$)\n : String(node.$tag$);\n\n // Process attributes as array (without leading spaces)\n const attrArray = node.$attrs$\n ? Object.entries(node.$attrs$)\n .filter(([_, value]) => value !== undefined)\n .map(([key, value]) => {\n // Convert HTML attributes to JSX equivalents\n let attrName = key;\n if (mode === 'jsx') {\n // Common HTML to JSX attribute conversions\n const htmlToJsx: Record<string, string> = {\n class: 'className',\n for: 'htmlFor',\n tabindex: 'tabIndex',\n };\n attrName = htmlToJsx[key] || key;\n }\n\n if (typeof value === 'function') {\n // Hide event handlers from source code\n return '';\n }\n\n if (typeof value === 'boolean') {\n return value ? attrName : '';\n }\n\n if (typeof value === 'string') {\n return `${attrName}=\"${value}\"`;\n }\n\n // For JSX, use curly braces for non-string values\n if (mode === 'jsx') {\n return `${attrName}={${JSON.stringify(value)}}`;\n }\n\n // For HTML, convert to string\n return `${attrName}=\"${value}\"`;\n })\n .filter((attr) => attr.trim())\n : [];\n\n const children = node.$children$ ?? [];\n\n // Self-closing tags for JSX when no children\n if (children.length === 0) {\n const attrsStr = attrArray.length > 0 ? ' ' + attrArray.join(' ') : '';\n const singleLine = mode === 'jsx'\n ? `${indent}<${tag}${attrsStr} />`\n : `${indent}<${tag}${attrsStr}></${tag}>`;\n\n // If single line fits within LINE_WIDTH, use it\n if (singleLine.length <= LINE_WIDTH) {\n return singleLine;\n }\n\n // Otherwise, break attributes to multiple lines\n const attrIndent = indent + ' ';\n const formattedAttrs = attrArray.length > 0\n ? '\\n' + attrArray.map((attr) => `${attrIndent}${attr}`).join('\\n') + '\\n' + indent\n : '';\n\n return mode === 'jsx'\n ? `${indent}<${tag}${formattedAttrs}/>`\n : `${indent}<${tag}${formattedAttrs}></${tag}>`;\n }\n\n // Tags with children\n const attrsStr = attrArray.length > 0 ? ' ' + attrArray.join(' ') : '';\n const openingTag = `${indent}<${tag}${attrsStr}>`;\n\n // Check if opening tag fits on one line\n if (openingTag.length <= LINE_WIDTH) {\n const childrenString = children\n .map((child) => vnodeToString(child, options, indentLevel + 1))\n .join('\\n');\n return `${openingTag}\\n${childrenString}\\n${indent}</${tag}>`;\n }\n\n // Break opening tag to multiple lines\n const attrIndent = indent + ' ';\n const formattedAttrs = attrArray.length > 0\n ? '\\n' + attrArray.map((attr) => `${attrIndent}${attr}`).join('\\n') + '\\n' + indent\n : '';\n const childrenString = children\n .map((child) => vnodeToString(child, options, indentLevel + 1))\n .join('\\n');\n\n return `${indent}<${tag}${formattedAttrs}>\\n${childrenString}\\n${indent}</${tag}>`;\n}\n\nexport const renderVNode = (vnode: VNode, mode: RenderMode) => {\n return vnodeToString(vnode, { mode });\n};\n","import { SourceType } from 'storybook/internal/docs-tools';\nimport { emitTransformCode, useEffect } from 'storybook/internal/preview-api';\nimport type { AnnotatedStoryFn, Args, DecoratorFunction } from 'storybook/internal/types';\nimport type { StencilRenderer } from '../types';\nimport { renderVNode } from './render-vnode';\n\ntype StoryFn<TArgs = Args> = AnnotatedStoryFn<StencilRenderer<unknown>, TArgs>;\n\nconst skip = (context: Parameters<DecoratorFunction<StencilRenderer<unknown>>>[1]) => {\n const sourceParams = context?.parameters.docs?.source;\n const isArgsStory = context?.parameters.__isArgsStory;\n\n if (sourceParams.type === SourceType.DYNAMIC) return false;\n\n return !isArgsStory || sourceParams?.code || sourceParams?.type === SourceType.CODE;\n};\n\nexport const sourceDecorator: DecoratorFunction<StencilRenderer<unknown>> = (storyFn, context) => {\n const story = storyFn();\n\n useEffect(() => {\n const renderedForSource = context?.parameters.docs?.source?.excludeDecorators\n ? (context.originalStoryFn as StoryFn)(context.args, context)\n : story;\n\n if (skip(context)) return;\n\n switch (context.parameters.docs.source.language) {\n case 'html': {\n emitTransformCode(renderVNode(renderedForSource, 'html'), context);\n break;\n }\n case 'jsx':\n case 'tsx': {\n emitTransformCode(renderVNode(renderedForSource, 'jsx'), context);\n break;\n }\n }\n });\n\n return story;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;ACvHD,MAAM,OAAO,CAACC,YAAwE;CACpF,MAAM,eAAe,SAAS,WAAW,MAAM;CAC/C,MAAM,cAAc,SAAS,WAAW;AAExC,KAAI,aAAa,SAASC,yCAAW,QAAS,QAAO;AAErD,SAAQ,eAAe,cAAc,QAAQ,cAAc,SAASA,yCAAW;AAChF;AAED,MAAaC,kBAA+D,CAAC,SAAS,YAAY;CAChG,MAAM,QAAQ,SAAS;AAEvB,+CAAU,MAAM;EACd,MAAM,oBAAoB,SAAS,WAAW,MAAM,QAAQ,oBACxD,AAAC,QAAQ,gBAA4B,QAAQ,MAAM,QAAQ,GAC3D;AAEJ,MAAI,KAAK,QAAQ,CAAE;AAEnB,UAAQ,QAAQ,WAAW,KAAK,OAAO,UAAvC;GACE,KAAK,QAAQ;AACX,0DAAkB,YAAY,mBAAmB,OAAO,EAAE,QAAQ;AAClE;GACD;GACD,KAAK;GACL,KAAK,OAAO;AACV,0DAAkB,YAAY,mBAAmB,MAAM,EAAE,QAAQ;AACjE;GACD;EACF;CACF,EAAC;AAEF,QAAO;AACR"}
|
|
@@ -1,85 +0,0 @@
|
|
|
1
|
-
const require_chunk = require('./chunk-CsX-DzYB.cjs');
|
|
2
|
-
const storybook_internal_docs_tools = require_chunk.__toESM(require("storybook/internal/docs-tools"));
|
|
3
|
-
const storybook_preview_api = require_chunk.__toESM(require("storybook/preview-api"));
|
|
4
|
-
const __stencil_core = require_chunk.__toESM(require("@stencil/core"));
|
|
5
|
-
|
|
6
|
-
//#region src/render.ts
|
|
7
|
-
const render = (args, context) => {
|
|
8
|
-
const { component, parameters: parameters$1 } = context;
|
|
9
|
-
if (Array.isArray(component)) throw new Error("If your story does not contain a render function, you must provide a component property!");
|
|
10
|
-
if (typeof component === "string" && !customElements.get(component)) throw new Error(`Stencil component not found. If you are not lazy loading your components with \`defineCustomElements()\` in preview.ts, pass a constructor value for component in your story \`component: MyComponent\``);
|
|
11
|
-
else if (typeof component !== "string" && !customElements.getName(component)) throw new Error(`Stencil component not found. If you are lazy loading your components with \`defineCustomElements()\` in preview.ts, pass a string value for component in your story \`component: 'my-component'\``);
|
|
12
|
-
const cmpName = typeof component === "string" ? component : customElements.getName(component);
|
|
13
|
-
const children = Object.entries(parameters$1.slots || []).map(([key, value]) => {
|
|
14
|
-
const slot = key === "default" ? void 0 : key;
|
|
15
|
-
const child = typeof value === "string" ? (0, __stencil_core.h)(void 0, { slot }, value) : {
|
|
16
|
-
...value,
|
|
17
|
-
$attrs$: {
|
|
18
|
-
...value.$attrs$,
|
|
19
|
-
slot
|
|
20
|
-
}
|
|
21
|
-
};
|
|
22
|
-
child.$tag$ = child.$tag$ || (slot ? "span" : null);
|
|
23
|
-
return child.$tag$ ? child : child.$children$;
|
|
24
|
-
});
|
|
25
|
-
const Component = `${cmpName}`;
|
|
26
|
-
return (0, __stencil_core.h)(Component, { ...args }, children);
|
|
27
|
-
};
|
|
28
|
-
function renderToCanvas({ storyFn, showMain, storyContext }, canvasElement) {
|
|
29
|
-
const vdom = storyFn();
|
|
30
|
-
showMain();
|
|
31
|
-
/**
|
|
32
|
-
* If the component is not automatically registered after import, register it here
|
|
33
|
-
*/
|
|
34
|
-
if (storyContext.component && storyContext.component.is && !customElements.get(storyContext.component.is)) customElements.define(storyContext.component.is, storyContext.component);
|
|
35
|
-
if (canvasElement.firstChild) canvasElement.removeChild(canvasElement.firstChild);
|
|
36
|
-
const element = document.createElement("div");
|
|
37
|
-
canvasElement.appendChild(element);
|
|
38
|
-
(0, __stencil_core.render)(vdom, element);
|
|
39
|
-
(0, storybook_preview_api.simulatePageLoad)(element);
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
//#endregion
|
|
43
|
-
//#region src/entry-preview.ts
|
|
44
|
-
var entry_preview_exports = {};
|
|
45
|
-
require_chunk.__export(entry_preview_exports, {
|
|
46
|
-
argTypesEnhancers: () => argTypesEnhancers,
|
|
47
|
-
parameters: () => parameters,
|
|
48
|
-
render: () => render,
|
|
49
|
-
renderToCanvas: () => renderToCanvas
|
|
50
|
-
});
|
|
51
|
-
const parameters = { renderer: "stencil" };
|
|
52
|
-
const argTypesEnhancers = [storybook_internal_docs_tools.enhanceArgTypes];
|
|
53
|
-
|
|
54
|
-
//#endregion
|
|
55
|
-
Object.defineProperty(exports, 'argTypesEnhancers', {
|
|
56
|
-
enumerable: true,
|
|
57
|
-
get: function () {
|
|
58
|
-
return argTypesEnhancers;
|
|
59
|
-
}
|
|
60
|
-
});
|
|
61
|
-
Object.defineProperty(exports, 'entry_preview_exports', {
|
|
62
|
-
enumerable: true,
|
|
63
|
-
get: function () {
|
|
64
|
-
return entry_preview_exports;
|
|
65
|
-
}
|
|
66
|
-
});
|
|
67
|
-
Object.defineProperty(exports, 'parameters', {
|
|
68
|
-
enumerable: true,
|
|
69
|
-
get: function () {
|
|
70
|
-
return parameters;
|
|
71
|
-
}
|
|
72
|
-
});
|
|
73
|
-
Object.defineProperty(exports, 'render', {
|
|
74
|
-
enumerable: true,
|
|
75
|
-
get: function () {
|
|
76
|
-
return render;
|
|
77
|
-
}
|
|
78
|
-
});
|
|
79
|
-
Object.defineProperty(exports, 'renderToCanvas', {
|
|
80
|
-
enumerable: true,
|
|
81
|
-
get: function () {
|
|
82
|
-
return renderToCanvas;
|
|
83
|
-
}
|
|
84
|
-
});
|
|
85
|
-
//# sourceMappingURL=entry-preview-C0ipNwpw.cjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"entry-preview-C0ipNwpw.cjs","names":["render: ArgsStoryFn<StencilRenderer<unknown>>","children: any[]","parameters","canvasElement: StencilRenderer<unknown>['canvasElement']","parameters: Parameters","argTypesEnhancers: ArgTypesEnhancer[]","enhanceArgTypes"],"sources":["../src/render.ts","../src/entry-preview.ts"],"sourcesContent":["import { h, render as renderStencil, VNode } from '@stencil/core';\nimport { ArgsStoryFn, RenderContext } from 'storybook/internal/types';\nimport { simulatePageLoad } from 'storybook/preview-api';\n\nimport type { StencilRenderer } from './types';\n\nexport const render: ArgsStoryFn<StencilRenderer<unknown>> = (args, context) => {\n const { component, parameters } = context;\n\n if (Array.isArray(component)) {\n throw new Error('If your story does not contain a render function, you must provide a component property!');\n }\n if (typeof component === 'string' && !customElements.get(component)) {\n throw new Error(\n `Stencil component not found. If you are not lazy loading your components with \\`defineCustomElements()\\` in preview.ts, pass a constructor value for component in your story \\`component: MyComponent\\``,\n );\n } else if (typeof component !== 'string' && !customElements.getName(component)) {\n throw new Error(\n `Stencil component not found. If you are lazy loading your components with \\`defineCustomElements()\\` in preview.ts, pass a string value for component in your story \\`component: 'my-component'\\``,\n );\n }\n const cmpName = typeof component === 'string' ? component : customElements.getName(component);\n\n const children: any[] = Object.entries<VNode>(parameters.slots || []).map(([key, value]) => {\n // if the parameter key is 'default' don't give it a slot name so it renders just as a child\n const slot = key === 'default' ? undefined : key;\n // if the value it s a string, create a vnode with the string as the children\n const child =\n typeof value === 'string'\n ? h(undefined, { slot }, value)\n : {\n ...value,\n $attrs$: {\n ...value.$attrs$,\n slot,\n },\n };\n // if the value is a fragment and it is a named slot, create a span element with the slot name\n child.$tag$ = child.$tag$ || (slot ? 'span' : null);\n return child.$tag$ ? child : child.$children$;\n });\n\n const Component = `${cmpName}`;\n return h(Component, { ...args }, children);\n};\n\nexport function renderToCanvas(\n { storyFn, showMain, storyContext }: RenderContext<StencilRenderer<unknown>>,\n canvasElement: StencilRenderer<unknown>['canvasElement'],\n) {\n const vdom = storyFn();\n showMain();\n\n /**\n * If the component is not automatically registered after import, register it here\n */\n if (storyContext.component && storyContext.component.is && !customElements.get(storyContext.component.is)) {\n customElements.define(storyContext.component.is, storyContext.component);\n }\n\n if (canvasElement.firstChild) {\n canvasElement.removeChild(canvasElement.firstChild);\n }\n\n const element = document.createElement('div');\n canvasElement.appendChild(element);\n renderStencil(vdom, element);\n simulatePageLoad(element);\n}\n","import { enhanceArgTypes } from 'storybook/internal/docs-tools';\nimport type { ArgTypesEnhancer, Parameters } from 'storybook/internal/types';\n\nexport const parameters: Parameters = { render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6CAAiB,QAAQ;AAC1B;;;;;;;;;;;ACjED,MAAaC,aAAyB,EAAE,UAAU,UAAW;AAI7D,MAAaC,oBAAwC,CAACC,6CAAgB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"entry-preview-C1JSJAGq.js","names":["render: ArgsStoryFn<StencilRenderer<unknown>>","children: any[]","parameters","canvasElement: StencilRenderer<unknown>['canvasElement']","parameters: Parameters","argTypesEnhancers: ArgTypesEnhancer[]"],"sources":["../src/render.ts","../src/entry-preview.ts"],"sourcesContent":["import { h, render as renderStencil, VNode } from '@stencil/core';\nimport { ArgsStoryFn, RenderContext } from 'storybook/internal/types';\nimport { simulatePageLoad } from 'storybook/preview-api';\n\nimport type { StencilRenderer } from './types';\n\nexport const render: ArgsStoryFn<StencilRenderer<unknown>> = (args, context) => {\n const { component, parameters } = context;\n\n if (Array.isArray(component)) {\n throw new Error('If your story does not contain a render function, you must provide a component property!');\n }\n if (typeof component === 'string' && !customElements.get(component)) {\n throw new Error(\n `Stencil component not found. If you are not lazy loading your components with \\`defineCustomElements()\\` in preview.ts, pass a constructor value for component in your story \\`component: MyComponent\\``,\n );\n } else if (typeof component !== 'string' && !customElements.getName(component)) {\n throw new Error(\n `Stencil component not found. If you are lazy loading your components with \\`defineCustomElements()\\` in preview.ts, pass a string value for component in your story \\`component: 'my-component'\\``,\n );\n }\n const cmpName = typeof component === 'string' ? component : customElements.getName(component);\n\n const children: any[] = Object.entries<VNode>(parameters.slots || []).map(([key, value]) => {\n // if the parameter key is 'default' don't give it a slot name so it renders just as a child\n const slot = key === 'default' ? undefined : key;\n // if the value it s a string, create a vnode with the string as the children\n const child =\n typeof value === 'string'\n ? h(undefined, { slot }, value)\n : {\n ...value,\n $attrs$: {\n ...value.$attrs$,\n slot,\n },\n };\n // if the value is a fragment and it is a named slot, create a span element with the slot name\n child.$tag$ = child.$tag$ || (slot ? 'span' : null);\n return child.$tag$ ? child : child.$children$;\n });\n\n const Component = `${cmpName}`;\n return h(Component, { ...args }, children);\n};\n\nexport function renderToCanvas(\n { storyFn, showMain, storyContext }: RenderContext<StencilRenderer<unknown>>,\n canvasElement: StencilRenderer<unknown>['canvasElement'],\n) {\n const vdom = storyFn();\n showMain();\n\n /**\n * If the component is not automatically registered after import, register it here\n */\n if (storyContext.component && storyContext.component.is && !customElements.get(storyContext.component.is)) {\n customElements.define(storyContext.component.is, storyContext.component);\n }\n\n if (canvasElement.firstChild) {\n canvasElement.removeChild(canvasElement.firstChild);\n }\n\n const element = document.createElement('div');\n canvasElement.appendChild(element);\n renderStencil(vdom, element);\n simulatePageLoad(element);\n}\n","import { enhanceArgTypes } from 'storybook/internal/docs-tools';\nimport type { ArgTypesEnhancer, Parameters } from 'storybook/internal/types';\n\nexport const parameters: Parameters = { renderer: 'stencil' };\n\nexport { render, renderToCanvas } from './render';\n\nexport const argTypesEnhancers: ArgTypesEnhancer[] = [enhanceArgTypes];\n"],"mappings":";;;;;;;;;;;;;;;AAMA,MAAaA,WAAgD,CAAC,MAAM,YAAY;CAC9E,MAAM,EAAE,WAAW,0BAAY,GAAG;AAElC,KAAI,MAAM,QAAQ,UAAU,CAC1B,OAAM,IAAI,MAAM;AAElB,YAAW,cAAc,aAAa,eAAe,IAAI,UAAU,CACjE,OAAM,IAAI,OACP;iBAEa,cAAc,aAAa,eAAe,QAAQ,UAAU,CAC5E,OAAM,IAAI,OACP;CAGL,MAAM,iBAAiB,cAAc,WAAW,YAAY,eAAe,QAAQ,UAAU;CAE7F,MAAMC,WAAkB,OAAO,QAAeC,aAAW,SAAS,CAAE,EAAC,CAAC,IAAI,CAAC,CAAC,KAAK,MAAM,KAAK;EAE1F,MAAM,OAAO,QAAQ,qBAAwB;EAE7C,MAAM,eACG,UAAU,WACb,UAAa,EAAE,KAAM,GAAE,MAAM,GAC7B;GACE,GAAG;GACH,SAAS;IACP,GAAG,MAAM;IACT;GACD;EACF;AAEP,QAAM,QAAQ,MAAM,UAAU,OAAO,SAAS;AAC9C,SAAO,MAAM,QAAQ,QAAQ,MAAM;CACpC,EAAC;CAEF,MAAM,aAAa,EAAE,QAAQ;AAC7B,QAAO,EAAE,WAAW,EAAE,GAAG,KAAM,GAAE,SAAS;AAC3C;AAED,SAAgB,eACd,EAAE,SAAS,UAAU,cAAuD,EAC5EC,eACA;CACA,MAAM,OAAO,SAAS;AACtB,WAAU;;;;AAKV,KAAI,aAAa,aAAa,aAAa,UAAU,OAAO,eAAe,IAAI,aAAa,UAAU,GAAG,CACvG,gBAAe,OAAO,aAAa,UAAU,IAAI,aAAa,UAAU;AAG1E,KAAI,cAAc,WAChB,eAAc,YAAY,cAAc,WAAW;CAGrD,MAAM,UAAU,SAAS,cAAc,MAAM;AAC7C,eAAc,YAAY,QAAQ;AAClC,QAAc,MAAM,QAAQ;AAC5B,kBAAiB,QAAQ;AAC1B;;;;;;;;;;;ACjED,MAAaC,aAAyB,EAAE,UAAU,UAAW;AAI7D,MAAaC,oBAAwC,CAAC,eAAgB"}
|
|
@@ -1,182 +0,0 @@
|
|
|
1
|
-
const require_chunk = require('./chunk-CsX-DzYB.cjs');
|
|
2
|
-
const require_src = require('./src-D0dJRYm2.cjs');
|
|
3
|
-
require('./entry-preview-C0ipNwpw.cjs');
|
|
4
|
-
const storybook_internal_docs_tools = require_chunk.__toESM(require("storybook/internal/docs-tools"));
|
|
5
|
-
const storybook_internal_client_logger = require_chunk.__toESM(require("storybook/internal/client-logger"));
|
|
6
|
-
|
|
7
|
-
//#region src/docs/infer-type.ts
|
|
8
|
-
const inferSBType = (prop) => {
|
|
9
|
-
const scalarTypes = [
|
|
10
|
-
"string",
|
|
11
|
-
"number",
|
|
12
|
-
"boolean",
|
|
13
|
-
"symbol"
|
|
14
|
-
];
|
|
15
|
-
if (prop.type.toLowerCase() in scalarTypes) return {
|
|
16
|
-
name: prop.type.toLowerCase(),
|
|
17
|
-
raw: prop.type,
|
|
18
|
-
required: prop.required
|
|
19
|
-
};
|
|
20
|
-
if (/^\(.*\)\s*=>\s*.*$/.test(prop.type)) return {
|
|
21
|
-
name: "function",
|
|
22
|
-
raw: prop.type,
|
|
23
|
-
required: prop.required
|
|
24
|
-
};
|
|
25
|
-
return {
|
|
26
|
-
name: "other",
|
|
27
|
-
value: prop.type,
|
|
28
|
-
raw: prop.type,
|
|
29
|
-
required: prop.required
|
|
30
|
-
};
|
|
31
|
-
};
|
|
32
|
-
const mapPropOptions = (prop) => prop.values.filter((value) => ["string", "number"].includes(value.type)).map(({ value }) => value);
|
|
33
|
-
const inferControlType = (prop) => {
|
|
34
|
-
switch (prop.type) {
|
|
35
|
-
case "string":
|
|
36
|
-
case "string | undefined": return { type: "text" };
|
|
37
|
-
case "number":
|
|
38
|
-
case "number | undefined": return { type: "number" };
|
|
39
|
-
case "boolean":
|
|
40
|
-
case "boolean | undefined": return { type: "boolean" };
|
|
41
|
-
case "Date":
|
|
42
|
-
case "Date | string": return { type: "date" };
|
|
43
|
-
case "function":
|
|
44
|
-
case "function | undefined":
|
|
45
|
-
case "void":
|
|
46
|
-
case "void | undefined": return null;
|
|
47
|
-
default:
|
|
48
|
-
const values = mapPropOptions(prop);
|
|
49
|
-
if (values.length === 0) return { type: "object" };
|
|
50
|
-
if (values.length < 5) return { type: "radio" };
|
|
51
|
-
return { type: "select" };
|
|
52
|
-
}
|
|
53
|
-
};
|
|
54
|
-
|
|
55
|
-
//#endregion
|
|
56
|
-
//#region src/docs/custom-elements.ts
|
|
57
|
-
/**
|
|
58
|
-
* Formats docsTags (@deprecated, @see, @since) and appends them to the description
|
|
59
|
-
*/
|
|
60
|
-
const formatDocsTags = (docs, docsTags) => {
|
|
61
|
-
if (!docsTags || docsTags.length === 0) return docs;
|
|
62
|
-
const tagSections = [];
|
|
63
|
-
const deprecationSections = [];
|
|
64
|
-
const deprecatedTags = docsTags.filter((tag) => tag.name === "deprecated");
|
|
65
|
-
if (deprecatedTags.length > 0) deprecatedTags.forEach((tag) => {
|
|
66
|
-
if (tag.text) deprecationSections.push(`**⚠️ DEPRECATED:** ${tag.text}`);
|
|
67
|
-
else deprecationSections.push(`**⚠️ DEPRECATED**`);
|
|
68
|
-
});
|
|
69
|
-
const seeTags = docsTags.filter((tag) => tag.name === "see");
|
|
70
|
-
if (seeTags.length > 0) {
|
|
71
|
-
const seeLinks = seeTags.map((tag) => {
|
|
72
|
-
const url = tag.text?.trim();
|
|
73
|
-
return url ? `[${url}](${url})` : "";
|
|
74
|
-
}).filter(Boolean).join(", ");
|
|
75
|
-
if (seeLinks) tagSections.push(`**See:** ${seeLinks}`);
|
|
76
|
-
}
|
|
77
|
-
const sinceTags = docsTags.filter((tag) => tag.name === "since");
|
|
78
|
-
if (sinceTags.length > 0) {
|
|
79
|
-
const sinceText = sinceTags.map((tag) => tag.text).filter(Boolean).join(", ");
|
|
80
|
-
if (sinceText) tagSections.push(`**Since:** ${sinceText}`);
|
|
81
|
-
}
|
|
82
|
-
const allSections = [
|
|
83
|
-
...deprecationSections,
|
|
84
|
-
docs,
|
|
85
|
-
...tagSections
|
|
86
|
-
].filter(Boolean);
|
|
87
|
-
return allSections.join("\n\n");
|
|
88
|
-
};
|
|
89
|
-
const mapData = (data, category) => data.reduce((acc, item) => {
|
|
90
|
-
acc[item.name] = {
|
|
91
|
-
name: item.name,
|
|
92
|
-
description: formatDocsTags(item.docs, item.docsTags),
|
|
93
|
-
control: false,
|
|
94
|
-
table: { category }
|
|
95
|
-
};
|
|
96
|
-
return acc;
|
|
97
|
-
}, {});
|
|
98
|
-
const mapMethods = (methods) => methods.reduce((acc, method) => {
|
|
99
|
-
acc[method.name] = {
|
|
100
|
-
name: method.name,
|
|
101
|
-
description: formatDocsTags(method.docs, method.docsTags),
|
|
102
|
-
control: null,
|
|
103
|
-
type: { name: "function" },
|
|
104
|
-
table: {
|
|
105
|
-
category: "methods",
|
|
106
|
-
type: { summary: method.signature }
|
|
107
|
-
}
|
|
108
|
-
};
|
|
109
|
-
return acc;
|
|
110
|
-
}, {});
|
|
111
|
-
const mapEvent = (events) => events.reduce((acc, event) => {
|
|
112
|
-
let name = event.event.replace(/(-|_|:|\.|\s)+(.)?/g, (_match, _separator, chr) => {
|
|
113
|
-
return chr ? chr.toUpperCase() : "";
|
|
114
|
-
}).replace(/^([A-Z])/, (match) => match.toLowerCase());
|
|
115
|
-
name = `on${name.charAt(0).toUpperCase() + name.slice(1)}`;
|
|
116
|
-
acc[name] = {
|
|
117
|
-
name,
|
|
118
|
-
description: formatDocsTags(event.docs, event.docsTags),
|
|
119
|
-
control: null,
|
|
120
|
-
table: {
|
|
121
|
-
category: "events",
|
|
122
|
-
type: { summary: event.detail }
|
|
123
|
-
},
|
|
124
|
-
type: { name: "function" }
|
|
125
|
-
};
|
|
126
|
-
return acc;
|
|
127
|
-
}, {});
|
|
128
|
-
const mapProps = (props) => props.reduce((acc, prop) => {
|
|
129
|
-
acc[prop.name] = {
|
|
130
|
-
name: prop.attr || prop.name,
|
|
131
|
-
description: formatDocsTags(prop.docs, prop.docsTags),
|
|
132
|
-
control: inferControlType(prop),
|
|
133
|
-
table: {
|
|
134
|
-
category: "properties",
|
|
135
|
-
type: { summary: prop.complexType?.original },
|
|
136
|
-
defaultValue: { summary: prop.default }
|
|
137
|
-
},
|
|
138
|
-
options: mapPropOptions(prop),
|
|
139
|
-
type: inferSBType(prop)
|
|
140
|
-
};
|
|
141
|
-
return acc;
|
|
142
|
-
}, {});
|
|
143
|
-
const getMetaData = (tagName, manifest) => {
|
|
144
|
-
if (!require_src.isValidComponent(tagName) || !require_src.isValidMetaData(manifest)) return null;
|
|
145
|
-
const metaData = manifest.components.find((component) => component.tag.toUpperCase() === tagName.toUpperCase());
|
|
146
|
-
if (!metaData) storybook_internal_client_logger.logger.warn(`Component not found in custom-elements.json: ${tagName}`);
|
|
147
|
-
return metaData;
|
|
148
|
-
};
|
|
149
|
-
const extractArgTypesFromElements = (tagName, customElements) => {
|
|
150
|
-
const metaData = getMetaData(tagName, customElements);
|
|
151
|
-
return metaData && {
|
|
152
|
-
...mapProps(metaData.props),
|
|
153
|
-
...mapEvent(metaData.events),
|
|
154
|
-
...mapMethods(metaData.methods),
|
|
155
|
-
...mapData(metaData.slots, "slots"),
|
|
156
|
-
...mapData(metaData.parts, "parts"),
|
|
157
|
-
...mapData(metaData.styles, "styles")
|
|
158
|
-
};
|
|
159
|
-
};
|
|
160
|
-
const extractArgTypes = (component) => {
|
|
161
|
-
const cem = require_src.getCustomElements();
|
|
162
|
-
const tagName = typeof component === "string" ? component : component?.is;
|
|
163
|
-
return extractArgTypesFromElements(tagName, cem);
|
|
164
|
-
};
|
|
165
|
-
const extractComponentDescription = (component) => {
|
|
166
|
-
const tagName = typeof component === "string" ? component : component?.is;
|
|
167
|
-
const metaData = getMetaData(tagName, require_src.getCustomElements());
|
|
168
|
-
return metaData && metaData.docs;
|
|
169
|
-
};
|
|
170
|
-
|
|
171
|
-
//#endregion
|
|
172
|
-
//#region src/entry-preview-argtypes.ts
|
|
173
|
-
const parameters = { docs: {
|
|
174
|
-
extractArgTypes,
|
|
175
|
-
extractComponentDescription
|
|
176
|
-
} };
|
|
177
|
-
const argTypesEnhancers = [storybook_internal_docs_tools.enhanceArgTypes];
|
|
178
|
-
|
|
179
|
-
//#endregion
|
|
180
|
-
exports.argTypesEnhancers = argTypesEnhancers;
|
|
181
|
-
exports.parameters = parameters;
|
|
182
|
-
//# sourceMappingURL=entry-preview-argtypes.cjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"entry-preview-argtypes.cjs","names":["prop: JsonDocsProp","scalarTypes: SBScalarType['name'][]","docs: string","docsTags?: DocsTag[]","tagSections: string[]","deprecationSections: string[]","data: T[]","category: string","methods: JsonDocsMethod[]","events: JsonDocsEvent[]","chr: string","props: JsonDocsProp[]","tagName: string","manifest: JsonDocs","customElements: JsonDocs","component: any","argTypesEnhancers: ArgTypesEnhancer<StencilRenderer<unknown>>[]","enhanceArgTypes"],"sources":["../src/docs/infer-type.ts","../src/docs/custom-elements.ts","../src/entry-preview-argtypes.ts"],"sourcesContent":["import type { JsonDocsProp } from '@stencil/core/internal';\nimport type { InputType, SBScalarType, SBType } from 'storybook/internal/types';\n\nexport const inferSBType = (prop: JsonDocsProp): SBType => {\n const scalarTypes: SBScalarType['name'][] = ['string', 'number', 'boolean', 'symbol'];\n if (prop.type.toLowerCase() in scalarTypes) {\n return { name: prop.type.toLowerCase(), raw: prop.type, required: prop.required } as SBScalarType;\n }\n\n if (/^\\(.*\\)\\s*=>\\s*.*$/.test(prop.type)) {\n return { name: 'function', raw: prop.type, required: prop.required };\n }\n\n return { name: 'other', value: prop.type, raw: prop.type, required: prop.required };\n};\n\nexport const mapPropOptions = (prop: JsonDocsProp) =>\n prop.values.filter((value) => ['string', 'number'].includes(value.type)).map(({ value }) => value);\n\nexport const inferControlType = (prop: JsonDocsProp): InputType['control'] => {\n switch (prop.type) {\n case 'string':\n case 'string | undefined':\n return { type: 'text' };\n case 'number':\n case 'number | undefined':\n return { type: 'number' };\n case 'boolean':\n case 'boolean | undefined':\n return { type: 'boolean' };\n case 'Date':\n case 'Date | string':\n return { type: 'date' };\n case 'function':\n case 'function | undefined':\n case 'void':\n case 'void | undefined':\n return null;\n default:\n const values = mapPropOptions(prop);\n\n if (values.length === 0) {\n return { type: 'object' };\n }\n if (values.length < 5) {\n return { type: 'radio' };\n }\n return { type: 'select' };\n }\n};\n","import type {\n JsonDocs,\n JsonDocsEvent,\n JsonDocsMethod,\n JsonDocsPart,\n JsonDocsProp,\n JsonDocsSlot,\n JsonDocsStyle,\n} from '@stencil/core/internal';\nimport { logger } from 'storybook/internal/client-logger';\nimport type { ArgTypes } from 'storybook/internal/types';\n\nimport { getCustomElements, isValidComponent, isValidMetaData } from '..';\nimport { inferControlType, inferSBType, mapPropOptions } from './infer-type';\n\ninterface DocsTag {\n name: string;\n text?: string;\n}\n\n/**\n * Formats docsTags (@deprecated, @see, @since) and appends them to the description\n */\nconst formatDocsTags = (docs: string, docsTags?: DocsTag[]): string => {\n if (!docsTags || docsTags.length === 0) {\n return docs;\n }\n\n const tagSections: string[] = [];\n const deprecationSections: string[] = [];\n\n // Handle @deprecated tags - show at the top with emphasis\n const deprecatedTags = docsTags.filter((tag) => tag.name === 'deprecated');\n if (deprecatedTags.length > 0) {\n deprecatedTags.forEach((tag) => {\n if (tag.text) {\n deprecationSections.push(`**⚠️ DEPRECATED:** ${tag.text}`);\n } else {\n deprecationSections.push(`**⚠️ DEPRECATED**`);\n }\n });\n }\n\n // Handle @see tags - create links\n const seeTags = docsTags.filter((tag) => tag.name === 'see');\n if (seeTags.length > 0) {\n const seeLinks = seeTags\n .map((tag) => {\n const url = tag.text?.trim();\n return url ? `[${url}](${url})` : '';\n })\n .filter(Boolean)\n .join(', ');\n if (seeLinks) {\n tagSections.push(`**See:** ${seeLinks}`);\n }\n }\n\n // Handle @since tags\n const sinceTags = docsTags.filter((tag) => tag.name === 'since');\n if (sinceTags.length > 0) {\n const sinceText = sinceTags\n .map((tag) => tag.text)\n .filter(Boolean)\n .join(', ');\n if (sinceText) {\n tagSections.push(`**Since:** ${sinceText}`);\n }\n }\n\n // Combine all sections - deprecation first, then docs, then other tags\n const allSections = [...deprecationSections, docs, ...tagSections].filter(Boolean);\n\n return allSections.join('\\n\\n');\n};\n\nconst mapData = <T extends JsonDocsPart>(data: T[], category: string): ArgTypes =>\n data.reduce<ArgTypes>((acc, item) => {\n acc[item.name] = {\n name: item.name,\n description: formatDocsTags(item.docs, (item as any).docsTags as DocsTag[]),\n control: false,\n table: {\n category,\n },\n };\n return acc;\n }, {});\n\nconst mapMethods = (methods: JsonDocsMethod[]): ArgTypes =>\n methods.reduce<ArgTypes>((acc, method) => {\n acc[method.name] = {\n name: method.name,\n description: formatDocsTags(method.docs, method.docsTags as DocsTag[]),\n control: null,\n type: { name: 'function' },\n table: {\n category: 'methods',\n type: { summary: method.signature },\n },\n };\n return acc;\n }, {});\n\nconst mapEvent = (events: JsonDocsEvent[]): ArgTypes =>\n events.reduce<ArgTypes>((acc, event) => {\n let name = event.event\n .replace(/(-|_|:|\\.|\\s)+(.)?/g, (_match, _separator, chr: string) => {\n return chr ? chr.toUpperCase() : '';\n })\n .replace(/^([A-Z])/, (match) => match.toLowerCase());\n\n name = `on${name.charAt(0).toUpperCase() + name.slice(1)}`;\n\n acc[name] = {\n name,\n description: formatDocsTags(event.docs, event.docsTags as DocsTag[]),\n control: null,\n table: {\n category: 'events',\n type: { summary: event.detail },\n },\n type: { name: 'function' },\n };\n\n return acc;\n }, {});\n\nconst mapProps = (props: JsonDocsProp[]): ArgTypes =>\n props.reduce<ArgTypes>((acc, prop) => {\n acc[prop.name] = {\n name: prop.attr || prop.name,\n description: formatDocsTags(prop.docs, prop.docsTags as DocsTag[]),\n control: inferControlType(prop),\n table: {\n category: 'properties',\n type: { summary: prop.complexType?.original },\n defaultValue: { summary: prop.default },\n },\n options: mapPropOptions(prop),\n type: inferSBType(prop),\n };\n\n return acc;\n }, {});\n\nconst getMetaData = (tagName: string, manifest: JsonDocs) => {\n if (!isValidComponent(tagName) || !isValidMetaData(manifest)) {\n return null;\n }\n const metaData = manifest.components.find((component) => component.tag.toUpperCase() === tagName.toUpperCase());\n if (!metaData) {\n logger.warn(`Component not found in custom-elements.json: ${tagName}`);\n }\n return metaData;\n};\n\nexport const extractArgTypesFromElements = (tagName: string, customElements: JsonDocs) => {\n const metaData = getMetaData(tagName, customElements);\n return (\n metaData && {\n ...mapProps(metaData.props),\n ...mapEvent(metaData.events),\n ...mapMethods(metaData.methods),\n ...mapData<JsonDocsSlot>(metaData.slots, 'slots'),\n ...mapData<JsonDocsPart>(metaData.parts, 'parts'),\n ...mapData<JsonDocsStyle>(metaData.styles, 'styles'),\n }\n );\n};\n\nexport const extractArgTypes = (component: any) => {\n const cem = getCustomElements();\n // Handle both string references (lazy loading) and class references (auto-define)\n const tagName = typeof component === 'string' ? component : component?.is;\n return extractArgTypesFromElements(tagName, cem);\n};\n\nexport const extractComponentDescription = (component: any) => {\n // Handle both string references (lazy loading) and class references (auto-define)\n const tagName = typeof component === 'string' ? component : component?.is;\n const metaData = getMetaData(tagName, getCustomElements());\n return metaData && metaData.docs;\n};\n","import { enhanceArgTypes } from 'storybook/internal/docs-tools';\nimport type { ArgTypesEnhancer } from 'storybook/internal/types';\n\nimport { extractArgTypes, extractComponentDescription } from './docs/custom-elements';\nimport type { StencilRenderer } from './types';\n\nexport const parameters = {\n docs: {\n extractArgTypes,\n extractComponentDescription,\n },\n};\n\nexport const argTypesEnhancers: ArgTypesEnhancer<StencilRenderer<unknown>>[] = [enhanceArgTypes];"],"mappings":";;;;;;;AAGA,MAAa,cAAc,CAACA,SAA+B;CACzD,MAAMC,cAAsC;EAAC;EAAU;EAAU;EAAW;CAAS;AACrF,KAAI,KAAK,KAAK,aAAa,IAAI,YAC7B,QAAO;EAAE,MAAM,KAAK,KAAK,aAAa;EAAE,KAAK,KAAK;EAAM,UAAU,KAAK;CAAU;AAGnF,KAAI,qBAAqB,KAAK,KAAK,KAAK,CACtC,QAAO;EAAE,MAAM;EAAY,KAAK,KAAK;EAAM,UAAU,KAAK;CAAU;AAGtE,QAAO;EAAE,MAAM;EAAS,OAAO,KAAK;EAAM,KAAK,KAAK;EAAM,UAAU,KAAK;CAAU;AACpF;AAED,MAAa,iBAAiB,CAACD,SAC7B,KAAK,OAAO,OAAO,CAAC,UAAU,CAAC,UAAU,QAAS,EAAC,SAAS,MAAM,KAAK,CAAC,CAAC,IAAI,CAAC,EAAE,OAAO,KAAK,MAAM;AAEpG,MAAa,mBAAmB,CAACA,SAA6C;AAC5E,SAAQ,KAAK,MAAb;EACE,KAAK;EACL,KAAK,qBACH,QAAO,EAAE,MAAM,OAAQ;EACzB,KAAK;EACL,KAAK,qBACH,QAAO,EAAE,MAAM,SAAU;EAC3B,KAAK;EACL,KAAK,sBACH,QAAO,EAAE,MAAM,UAAW;EAC5B,KAAK;EACL,KAAK,gBACH,QAAO,EAAE,MAAM,OAAQ;EACzB,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK,mBACH,QAAO;EACT;GACE,MA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
-
import { ArgTypesEnhancer } from "storybook/internal/types";
|
|
3
|
-
import * as storybook_internal_csf0 from "storybook/internal/csf";
|
|
4
|
-
|
|
5
|
-
//#region src/entry-preview-argtypes.d.ts
|
|
6
|
-
declare const parameters: {
|
|
7
|
-
docs: {
|
|
8
|
-
extractArgTypes: (component: any) => {
|
|
9
|
-
[x: string]: storybook_internal_csf0.InputType;
|
|
10
|
-
};
|
|
11
|
-
extractComponentDescription: (component: any) => string;
|
|
12
|
-
};
|
|
13
|
-
};
|
|
14
|
-
declare const argTypesEnhancers: ArgTypesEnhancer<StencilRenderer<unknown>>[];
|
|
15
|
-
//# sourceMappingURL=entry-preview-argtypes.d.ts.map
|
|
16
|
-
|
|
17
|
-
//#endregion
|
|
18
|
-
export { argTypesEnhancers, parameters };
|
|
19
|
-
//# sourceMappingURL=entry-preview-argtypes.d.cts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"entry-preview-argtypes.d.cts","names":[],"sources":["../src/entry-preview-argtypes.ts"],"sourcesContent":[],"mappings":";;;;;cAMa;;;MAAA,CAAA,CAAA,EAAA,MAKZ,CAAA,EAAA,uBAAA,CAAA,SAAA;IAEY,CAAA;IAAmF,2BAAA,EAAA,CAAA,SAAA,EAAA,GAAA,EAAA,GAAA,MAAA;EAAA,CAAA;CAAhC;AAAhB,cAAnC,iBAAmC,EAAhB,gBAAgB,CAAC,eAAD,CAAA,OAAA,CAAA,CAAA,EAAA"}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { StencilRenderer } from "./types-DqHtEV5w.js";
|
|
2
|
-
import { ArgTypesEnhancer } from "storybook/internal/types";
|
|
3
|
-
import * as storybook_internal_csf0 from "storybook/internal/csf";
|
|
4
|
-
|
|
5
|
-
//#region src/entry-preview-argtypes.d.ts
|
|
6
|
-
declare const parameters: {
|
|
7
|
-
docs: {
|
|
8
|
-
extractArgTypes: (component: any) => {
|
|
9
|
-
[x: string]: storybook_internal_csf0.InputType;
|
|
10
|
-
};
|
|
11
|
-
extractComponentDescription: (component: any) => string;
|
|
12
|
-
};
|
|
13
|
-
};
|
|
14
|
-
declare const argTypesEnhancers: ArgTypesEnhancer<StencilRenderer<unknown>>[];
|
|
15
|
-
//# sourceMappingURL=entry-preview-argtypes.d.ts.map
|
|
16
|
-
|
|
17
|
-
//#endregion
|
|
18
|
-
export { argTypesEnhancers, parameters };
|
|
19
|
-
//# sourceMappingURL=entry-preview-argtypes.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"entry-preview-argtypes.d.ts","names":[],"sources":["../src/entry-preview-argtypes.ts"],"sourcesContent":[],"mappings":";;;;;cAMa;;;MAAA,CAAA,CAAA,EAAA,MAKZ,CAAA,EAAA,uBAAA,CAAA,SAAA;IAEY,CAAA;IAAmF,2BAAA,EAAA,CAAA,SAAA,EAAA,GAAA,EAAA,GAAA,MAAA;EAAA,CAAA;CAAhC;AAAhB,cAAnC,iBAAmC,EAAhB,gBAAgB,CAAC,eAAD,CAAA,OAAA,CAAA,CAAA,EAAA"}
|