ember-storybook 0.0.0 → 0.1.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.
Files changed (69) hide show
  1. package/README.md +0 -5
  2. package/declarations/client/docs/block-params.d.ts +4 -0
  3. package/declarations/client/docs/block-params.d.ts.map +1 -0
  4. package/declarations/client/docs/blocks/blocks.d.ts +25 -0
  5. package/declarations/client/docs/blocks/blocks.d.ts.map +1 -0
  6. package/declarations/client/docs/blocks/element.d.ts +7 -0
  7. package/declarations/client/docs/blocks/element.d.ts.map +1 -0
  8. package/declarations/client/docs/blocks/style.d.ts +14 -0
  9. package/declarations/client/docs/blocks/style.d.ts.map +1 -0
  10. package/declarations/client/docs/blocks/subcomponents.d.ts +8 -0
  11. package/declarations/client/docs/blocks/subcomponents.d.ts.map +1 -0
  12. package/declarations/client/docs/blocks/ui.d.ts +22 -0
  13. package/declarations/client/docs/blocks/ui.d.ts.map +1 -0
  14. package/declarations/client/docs/config.d.ts +2 -1
  15. package/declarations/client/docs/config.d.ts.map +1 -1
  16. package/declarations/client/docs/extractArgTypes.d.ts +4 -0
  17. package/declarations/client/docs/extractArgTypes.d.ts.map +1 -0
  18. package/declarations/client/docs/extractArgTypes.test.d.ts +2 -0
  19. package/declarations/client/docs/extractArgTypes.test.d.ts.map +1 -0
  20. package/declarations/client/docs/page.d.ts +2 -0
  21. package/declarations/client/docs/page.d.ts.map +1 -0
  22. package/declarations/client/docs/signature.d.ts +13 -0
  23. package/declarations/client/docs/signature.d.ts.map +1 -0
  24. package/declarations/client/docs/signature.test.d.ts +2 -0
  25. package/declarations/client/docs/signature.test.d.ts.map +1 -0
  26. package/declarations/client/docs/source-decorator.d.ts +11 -0
  27. package/declarations/client/docs/source-decorator.d.ts.map +1 -0
  28. package/declarations/client/docs/source-decorator.test.d.ts +2 -0
  29. package/declarations/client/docs/source-decorator.test.d.ts.map +1 -0
  30. package/declarations/node/docgen/docgen.d.ts +3 -0
  31. package/declarations/node/docgen/docgen.d.ts.map +1 -0
  32. package/declarations/node/docgen/vite-plugin.d.ts +4 -0
  33. package/declarations/node/docgen/vite-plugin.d.ts.map +1 -0
  34. package/declarations/node/indexer.d.ts.map +1 -1
  35. package/declarations/node/meta/vite-plugin.d.ts +8 -0
  36. package/declarations/node/meta/vite-plugin.d.ts.map +1 -0
  37. package/declarations/node/parser.d.ts +65 -0
  38. package/declarations/node/parser.d.ts.map +1 -0
  39. package/declarations/node/parser.test.d.ts +2 -0
  40. package/declarations/node/parser.test.d.ts.map +1 -0
  41. package/declarations/node/shared.d.ts +11 -0
  42. package/declarations/node/shared.d.ts.map +1 -0
  43. package/declarations/node/source/vite-plugin.d.ts +4 -0
  44. package/declarations/node/source/vite-plugin.d.ts.map +1 -0
  45. package/declarations/node/test-support.d.ts +5 -0
  46. package/declarations/node/test-support.d.ts.map +1 -0
  47. package/declarations/node/types.d.ts +32 -0
  48. package/declarations/node/types.d.ts.map +1 -0
  49. package/declarations/node/vite-plugin-orchestrator.d.ts +8 -0
  50. package/declarations/node/vite-plugin-orchestrator.d.ts.map +1 -0
  51. package/declarations/node/vite-plugin.d.ts +3 -0
  52. package/declarations/node/vite-plugin.d.ts.map +1 -0
  53. package/declarations/preset.d.ts.map +1 -1
  54. package/dist/block-params-C68OkWMC.mjs +12 -0
  55. package/dist/block-params-C68OkWMC.mjs.map +1 -0
  56. package/dist/client/config.mjs +1 -1
  57. package/dist/client/docs/config.mjs +544 -20
  58. package/dist/client/docs/config.mjs.map +1 -1
  59. package/dist/client/index.mjs +2 -2
  60. package/dist/{client-CKraj5BI.mjs → client-n835-2Vu.mjs} +2 -2
  61. package/dist/{client-CKraj5BI.mjs.map → client-n835-2Vu.mjs.map} +1 -1
  62. package/dist/index.mjs +2 -2
  63. package/dist/preset.mjs +1318 -7
  64. package/dist/preset.mjs.map +1 -1
  65. package/dist/{render-BUq_AxtY.mjs → render-DRAVRbiI.mjs} +2 -1
  66. package/dist/{render-BUq_AxtY.mjs.map → render-DRAVRbiI.mjs.map} +1 -1
  67. package/package.json +24 -13
  68. package/declarations/client/docs/sourceDecorator.d.ts +0 -7
  69. package/declarations/client/docs/sourceDecorator.d.ts.map +0 -1
package/README.md CHANGED
@@ -10,11 +10,6 @@ So you can develop UI components in isolation without worrying about app specifi
10
10
 
11
11
  ## Getting Started
12
12
 
13
- ```sh
14
- cd my-ember-app
15
- npx storybook@latest init
16
- ```
17
-
18
13
  For more information visit: [storybook.js.org](https://storybook.js.org?ref=readme)
19
14
 
20
15
  ---
@@ -0,0 +1,4 @@
1
+ import type { BlockInfo, BlockParam } from 'ember-docgen';
2
+ /** Flatten the params union into plain block params, unwrapping yield hashes. */
3
+ export declare function unwrapBlockParams(params: BlockInfo['params']): BlockParam[];
4
+ //# sourceMappingURL=block-params.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"block-params.d.ts","sourceRoot":"","sources":["../../../src/client/docs/block-params.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,UAAU,EAAkB,MAAM,cAAc,CAAC;AAM1E,iFAAiF;AACjF,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,SAAS,CAAC,QAAQ,CAAC,GAAG,UAAU,EAAE,CAE3E"}
@@ -0,0 +1,25 @@
1
+ import type { BlockInfo } from 'ember-docgen';
2
+ export declare const ParamType: import("storybook/theming").StyledComponent<{
3
+ theme?: import("storybook/theming").Theme;
4
+ as?: React.ElementType;
5
+ }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, {}>;
6
+ export declare const ParamRow: import("storybook/theming").StyledComponent<{
7
+ theme?: import("storybook/theming").Theme;
8
+ as?: React.ElementType;
9
+ }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
10
+ export declare function BlocksTable({ blocks, subcomponentNames, defaultName }: {
11
+ blocks: Record<string, BlockInfo>;
12
+ subcomponentNames: Set<string>;
13
+ defaultName: string;
14
+ }): import("react").FunctionComponentElement<{
15
+ theme?: import("storybook/theming").Theme;
16
+ as?: React.ElementType;
17
+ } & import("react").ClassAttributes<HTMLTableElement> & import("react").TableHTMLAttributes<HTMLTableElement>> | undefined;
18
+ export declare function BlocksSection({ blocks, subcomponentNames }: {
19
+ blocks: Record<string, BlockInfo>;
20
+ subcomponentNames: Set<string>;
21
+ }): import("react").FunctionComponentElement<{
22
+ theme?: import("storybook/theming").Theme;
23
+ as?: React.ElementType;
24
+ } & import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement>>;
25
+ //# sourceMappingURL=blocks.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"blocks.d.ts","sourceRoot":"","sources":["../../../../src/client/docs/blocks/blocks.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,SAAS,EAA8B,MAAM,cAAc,CAAC;AAE1E,eAAO,MAAM,SAAS;;;mGAInB,CAAC;AAOJ,eAAO,MAAM,QAAQ;;;yGAIlB,CAAC;AA2HJ,wBAAgB,WAAW,CAAC,EAC1B,MAAM,EACN,iBAAiB,EACjB,WAAW,EACZ,EAAE;IACD,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;IAClC,iBAAiB,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;IAC/B,WAAW,EAAE,MAAM,CAAC;CACrB;;;2HA+BA;AAED,wBAAgB,aAAa,CAAC,EAC5B,MAAM,EACN,iBAAiB,EAClB,EAAE;IACD,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;IAClC,iBAAiB,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;CAChC;;;sGAUA"}
@@ -0,0 +1,7 @@
1
+ export declare function ElementBlock({ element }: {
2
+ element: string;
3
+ }): import("react").FunctionComponentElement<{
4
+ theme?: import("storybook/theming").Theme;
5
+ as?: React.ElementType;
6
+ } & import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement>> | undefined;
7
+ //# sourceMappingURL=element.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"element.d.ts","sourceRoot":"","sources":["../../../../src/client/docs/blocks/element.ts"],"names":[],"mappings":"AAmCA,wBAAgB,YAAY,CAAC,EAAE,OAAO,EAAE,EAAE;IAAE,OAAO,EAAE,MAAM,CAAA;CAAE;;;kHAgC5D"}
@@ -0,0 +1,14 @@
1
+ import { type Entry } from './ui';
2
+ export declare function PartsTable({ entries }: {
3
+ entries: Entry[];
4
+ }): import("react").FunctionComponentElement<{
5
+ theme?: import("storybook/theming").Theme;
6
+ as?: React.ElementType;
7
+ } & import("react").ClassAttributes<HTMLTableElement> & import("react").TableHTMLAttributes<HTMLTableElement>>;
8
+ export declare function CssPropertiesTable({ entries }: {
9
+ entries: Entry[];
10
+ }): import("react").FunctionComponentElement<{
11
+ theme?: import("storybook/theming").Theme;
12
+ as?: React.ElementType;
13
+ } & import("react").ClassAttributes<HTMLTableElement> & import("react").TableHTMLAttributes<HTMLTableElement>>;
14
+ //# sourceMappingURL=style.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"style.d.ts","sourceRoot":"","sources":["../../../../src/client/docs/blocks/style.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,KAAK,KAAK,EAAwC,MAAM,MAAM,CAAC;AAyBxE,wBAAgB,UAAU,CAAC,EAAE,OAAO,EAAE,EAAE;IAAE,OAAO,EAAE,KAAK,EAAE,CAAA;CAAE;;;+GAO3D;AAED,wBAAgB,kBAAkB,CAAC,EAAE,OAAO,EAAE,EAAE;IAAE,OAAO,EAAE,KAAK,EAAE,CAAA;CAAE;;;+GAOnE"}
@@ -0,0 +1,8 @@
1
+ import type { SubcomponentRef } from '../signature';
2
+ export declare function SubcomponentsArea({ components }: {
3
+ components: SubcomponentRef[];
4
+ }): import("react").FunctionComponentElement<{
5
+ theme?: import("storybook/theming").Theme;
6
+ as?: React.ElementType;
7
+ } & import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement>> | undefined;
8
+ //# sourceMappingURL=subcomponents.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"subcomponents.d.ts","sourceRoot":"","sources":["../../../../src/client/docs/blocks/subcomponents.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAgDpD,wBAAgB,iBAAiB,CAAC,EAAE,UAAU,EAAE,EAAE;IAAE,UAAU,EAAE,eAAe,EAAE,CAAA;CAAE;;;kHAmClF"}
@@ -0,0 +1,22 @@
1
+ import { type Theme } from 'storybook/theming';
2
+ export interface Entry {
3
+ name: string;
4
+ description?: string;
5
+ }
6
+ export declare function isHtmlElement(name: string): boolean;
7
+ export declare const TableWrapper: import("storybook/theming").StyledComponent<{
8
+ theme?: Theme;
9
+ as?: React.ElementType;
10
+ }, import("react").DetailedHTMLProps<import("react").TableHTMLAttributes<HTMLTableElement>, HTMLTableElement>, {}>;
11
+ export declare function renderHead(columns: string[]): import("react").DetailedReactHTMLElement<{
12
+ className: string;
13
+ }, HTMLElement>;
14
+ export declare function renderBody(entries: Entry[]): import("react").DetailedReactHTMLElement<{
15
+ className: string;
16
+ }, HTMLElement>;
17
+ export declare const H2: import("storybook/theming").StyledComponent<import("@storybook/addon-docs/blocks").HeadingProps & {
18
+ children?: import("react").ReactNode | undefined;
19
+ } & {
20
+ theme?: Theme;
21
+ }, {}, {}>;
22
+ //# sourceMappingURL=ui.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ui.d.ts","sourceRoot":"","sources":["../../../../src/client/docs/blocks/ui.ts"],"names":[],"mappings":"AAGA,OAAO,EAAU,KAAK,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAEvD,MAAM,WAAW,KAAK;IACpB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAID,wBAAgB,aAAa,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAEnD;AAID,eAAO,MAAM,YAAY;;;kHAmFtB,CAAC;AAEJ,wBAAgB,UAAU,CAAC,OAAO,EAAE,MAAM,EAAE;;gBAU3C;AAED,wBAAgB,UAAU,CAAC,OAAO,EAAE,KAAK,EAAE;;gBAiB1C;AAED,eAAO,MAAM,EAAE;;;;UAUZ,CAAC"}
@@ -1,5 +1,6 @@
1
1
  import type { EmberRenderer } from '../types';
2
- import type { DecoratorFunction, Parameters } from 'storybook/internal/types';
2
+ import type { DecoratorFunction, Parameters, StoryContextForEnhancers, StrictArgTypes } from 'storybook/internal/types';
3
+ export declare const argTypesEnhancers: ((context: StoryContextForEnhancers<EmberRenderer>) => StrictArgTypes)[];
3
4
  export declare const parameters: Parameters;
4
5
  export declare const decorators: DecoratorFunction<EmberRenderer>[];
5
6
  //# sourceMappingURL=config.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../src/client/docs/config.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAC9C,OAAO,KAAK,EAAE,iBAAiB,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAC;AAE9E,eAAO,MAAM,UAAU,EAAE,UAOxB,CAAC;AAEF,eAAO,MAAM,UAAU,EAAE,iBAAiB,CAAC,aAAa,CAAC,EAAsB,CAAC"}
1
+ {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../src/client/docs/config.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAE9C,OAAO,KAAK,EACV,iBAAiB,EACjB,UAAU,EACV,wBAAwB,EACxB,cAAc,EACf,MAAM,0BAA0B,CAAC;AAkBlC,eAAO,MAAM,iBAAiB,EAAE,CAAC,CAC/B,OAAO,EAAE,wBAAwB,CAAC,aAAa,CAAC,KAC7C,cAAc,CAAC,EA4BnB,CAAC;AAEF,eAAO,MAAM,UAAU,EAAE,UAQxB,CAAC;AAEF,eAAO,MAAM,UAAU,EAAE,iBAAiB,CAAC,aAAa,CAAC,EAAsB,CAAC"}
@@ -0,0 +1,4 @@
1
+ import type { ComponentSignature } from 'ember-docgen';
2
+ export declare function buildArgTypes(sig: ComponentSignature): Record<string, unknown>;
3
+ export declare function extractArgTypes(component: Record<string, unknown>): Record<string, unknown> | null;
4
+ //# sourceMappingURL=extractArgTypes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"extractArgTypes.d.ts","sourceRoot":"","sources":["../../../src/client/docs/extractArgTypes.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAe,kBAAkB,EAAE,MAAM,cAAc,CAAC;AA4DpE,wBAAgB,aAAa,CAAC,GAAG,EAAE,kBAAkB,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAoB9E;AAED,wBAAgB,eAAe,CAC7B,SAAS,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GACjC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,CAahC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=extractArgTypes.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"extractArgTypes.test.d.ts","sourceRoot":"","sources":["../../../src/client/docs/extractArgTypes.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,2 @@
1
+ export default function Page(): import("react").FunctionComponentElement<import("react").FragmentProps>;
2
+ //# sourceMappingURL=page.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"page.d.ts","sourceRoot":"","sources":["../../../src/client/docs/page.ts"],"names":[],"mappings":"AAgFA,MAAM,CAAC,OAAO,UAAU,IAAI,4EAwC3B"}
@@ -0,0 +1,13 @@
1
+ import type { EmberMeta } from '../../node/types';
2
+ import type { BlockInfo, ComponentSignature } from 'ember-docgen';
3
+ export interface SubcomponentRef {
4
+ name: string;
5
+ signature?: ComponentSignature;
6
+ importPath?: string;
7
+ }
8
+ export declare function applyModifiers(signature: ComponentSignature, modifiers?: {
9
+ name: string;
10
+ typeArgs: string[];
11
+ }[]): ComponentSignature;
12
+ export declare function collectSubcomponents(blocks: Record<string, BlockInfo>, data: EmberMeta): SubcomponentRef[];
13
+ //# sourceMappingURL=signature.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"signature.d.ts","sourceRoot":"","sources":["../../../src/client/docs/signature.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAiB,SAAS,EAAE,MAAM,kBAAkB,CAAC;AACjE,OAAO,KAAK,EAAE,SAAS,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAElE,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,CAAC,EAAE,kBAAkB,CAAC;IAC/B,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,wBAAgB,cAAc,CAC5B,SAAS,EAAE,kBAAkB,EAC7B,SAAS,CAAC,EAAE;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,EAAE,CAAA;CAAE,EAAE,GACjD,kBAAkB,CAsBpB;AAED,wBAAgB,oBAAoB,CAClC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,EACjC,IAAI,EAAE,SAAS,GACd,eAAe,EAAE,CAuCnB"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=signature.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"signature.test.d.ts","sourceRoot":"","sources":["../../../src/client/docs/signature.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,11 @@
1
+ import type { EmberRenderer } from '../types';
2
+ import type { ComponentSignature } from 'ember-docgen';
3
+ import type { Args, ArgTypes, DecoratorFunction } from 'storybook/internal/types';
4
+ export declare function toArgument(key: string, value: unknown, argTypes: ArgTypes): string | undefined;
5
+ export declare function generateBlockSourceCode(sig: ComponentSignature, args: Args, indent: string): string;
6
+ export declare function resolveTemplateArgs(template: string, args: Args): string;
7
+ export declare function generateSource(component: {
8
+ name?: string;
9
+ }, args: Args, argTypes: ArgTypes, storyId?: string): string | undefined;
10
+ export declare const sourceDecorator: DecoratorFunction<EmberRenderer>;
11
+ //# sourceMappingURL=source-decorator.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"source-decorator.d.ts","sourceRoot":"","sources":["../../../src/client/docs/source-decorator.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAC9C,OAAO,KAAK,EAAa,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAClE,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AA0BlF,wBAAgB,UAAU,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,QAAQ,GAAG,MAAM,GAAG,SAAS,CAsB9F;AAcD,wBAAgB,uBAAuB,CACrC,GAAG,EAAE,kBAAkB,EACvB,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,MAAM,GACb,MAAM,CA8BR;AAoCD,wBAAgB,mBAAmB,CAAC,QAAQ,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,GAAG,MAAM,CAexE;AAED,wBAAgB,cAAc,CAC5B,SAAS,EAAE;IAAE,IAAI,CAAC,EAAE,MAAM,CAAA;CAAE,EAC5B,IAAI,EAAE,IAAI,EACV,QAAQ,EAAE,QAAQ,EAClB,OAAO,CAAC,EAAE,MAAM,GACf,MAAM,GAAG,SAAS,CA4CpB;AAED,eAAO,MAAM,eAAe,EAAE,iBAAiB,CAAC,aAAa,CAoB5D,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=source-decorator.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"source-decorator.test.d.ts","sourceRoot":"","sources":["../../../src/client/docs/source-decorator.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ import type { ComponentSignatureMap } from 'ember-docgen';
2
+ export declare function runTypeDoc(entryPoints: string[]): Promise<ComponentSignatureMap>;
3
+ //# sourceMappingURL=docgen.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"docgen.d.ts","sourceRoot":"","sources":["../../../src/node/docgen/docgen.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,cAAc,CAAC;AAyC1D,wBAAsB,UAAU,CAAC,WAAW,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC,qBAAqB,CAAC,CAoCtF"}
@@ -0,0 +1,4 @@
1
+ import { type ContributorAPI } from '../vite-plugin-orchestrator';
2
+ import type { Plugin } from 'vite';
3
+ export declare function signaturesContributor(api: ContributorAPI): Plugin;
4
+ //# sourceMappingURL=vite-plugin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"vite-plugin.d.ts","sourceRoot":"","sources":["../../../src/node/docgen/vite-plugin.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAIlE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,MAAM,CAAC;AAoDnC,wBAAgB,qBAAqB,CAAC,GAAG,EAAE,cAAc,GAAG,MAAM,CA2GjE"}
@@ -1 +1 @@
1
- {"version":3,"file":"indexer.d.ts","sourceRoot":"","sources":["../../src/node/indexer.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,KAAK,UAAU,EAAW,MAAM,8BAA8B,CAAC;AAExE,OAAO,KAAK,EAAE,OAAO,EAA8B,MAAM,0BAA0B,CAAC;AAQpF,eAAO,MAAM,OAAO,GAAU,UAAU,MAAM,EAAE,SAAS,UAAU,4DAKlE,CAAC;AAEF,eAAO,MAAM,YAAY,EAAE,OAO1B,CAAC"}
1
+ {"version":3,"file":"indexer.d.ts","sourceRoot":"","sources":["../../src/node/indexer.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,KAAK,UAAU,EAAW,MAAM,8BAA8B,CAAC;AAIxE,OAAO,KAAK,EAAE,OAAO,EAA8B,MAAM,0BAA0B,CAAC;AAQpF,eAAO,MAAM,OAAO,GAAU,UAAU,MAAM,EAAE,SAAS,UAAU,4DAKlE,CAAC;AAEF,eAAO,MAAM,YAAY,EAAE,OAc1B,CAAC"}
@@ -0,0 +1,8 @@
1
+ import { type ContributorAPI } from '../vite-plugin-orchestrator';
2
+ import type { Plugin } from 'vite';
3
+ export interface ComponentMeta {
4
+ file?: string;
5
+ signatureName?: string;
6
+ }
7
+ export declare function metaContributor(api: ContributorAPI): Plugin;
8
+ //# sourceMappingURL=vite-plugin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"vite-plugin.d.ts","sourceRoot":"","sources":["../../../src/node/meta/vite-plugin.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAGlE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,MAAM,CAAC;AAEnC,MAAM,WAAW,aAAa;IAC5B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAuBD,wBAAgB,eAAe,CAAC,GAAG,EAAE,cAAc,GAAG,MAAM,CAkF3D"}
@@ -0,0 +1,65 @@
1
+ import { type StaticMeta, type StaticStory } from 'storybook/internal/csf-tools';
2
+ import { type ExportedName } from './shared';
3
+ import type { Program } from 'oxc-parser';
4
+ /**
5
+ * A map with contents of a component file:
6
+ *
7
+ * - `key`: The component name in the file
8
+ * - `value`:
9
+ * - `string`: The exported component name
10
+ * - `undefined`: Not exported
11
+ * - `Default`: default export
12
+ */
13
+ export type ComponentMap = Record<ExportedName, string>;
14
+ export declare function readAndPreprocess(filePath: string): {
15
+ rawCode: string;
16
+ processedCode: string;
17
+ };
18
+ export declare function parseProcessedCode(processedCode: string, filePath: string): Program;
19
+ /**
20
+ * Result of parsing a story file, covering all subsystem needs.
21
+ */
22
+ export interface StoryFile {
23
+ meta: StaticMeta;
24
+ component: {
25
+ /**
26
+ * Project-relative path to the component file.
27
+ * Set only when the component is imported from a local module.
28
+ */
29
+ file?: string;
30
+ /**
31
+ * The key to look up the component's signature in the component
32
+ * file's signatures record. Matches TypeDoc's deriveComponentName.
33
+ *
34
+ * - `"Greeting"` for `export const Greeting = ...`
35
+ * - `"Card"` for `export { Card as CardExport }`
36
+ * - `"Button"` for `export default class Button ...`
37
+ */
38
+ signatureName?: string;
39
+ /**
40
+ * The name used to invoke the component in generated source.
41
+ * Differs from `signatureName` for default exports, where the
42
+ * signature is keyed by the `__DEFAULT__` sentinel but the real
43
+ * component name (e.g. `"Button"`) is known from the component file.
44
+ */
45
+ name?: string;
46
+ };
47
+ stories: (StaticStory & {
48
+ inlineTemplate?: string;
49
+ })[];
50
+ }
51
+ /**
52
+ * Parse a component file and return a map of all declarations.
53
+ *
54
+ * Each key is the internal variable/class name, each value is:
55
+ * - `string` for named exports (the export name)
56
+ * - `Default` for `export default`
57
+ * - `undefined` for non-exported declarations
58
+ */
59
+ export declare function parseComponentFile(compPath: string): ComponentMap | undefined;
60
+ /**
61
+ * Parse a story file and return metadata about the component it references,
62
+ * including template sources for each named story export.
63
+ */
64
+ export declare function parseStoryFile(storyPath: string): StoryFile | undefined;
65
+ //# sourceMappingURL=parser.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"parser.d.ts","sourceRoot":"","sources":["../../src/node/parser.ts"],"names":[],"mappings":"AAKA,OAAO,EAAW,KAAK,UAAU,EAAE,KAAK,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAE1F,OAAO,EAAW,KAAK,YAAY,EAAqB,MAAM,UAAU,CAAC;AAEzE,OAAO,KAAK,EAAmB,OAAO,EAAsB,MAAM,YAAY,CAAC;AAE/E;;;;;;;;GAQG;AACH,MAAM,MAAM,YAAY,GAAG,MAAM,CAAC,YAAY,EAAE,MAAM,CAAC,CAAC;AAExD,wBAAgB,iBAAiB,CAAC,QAAQ,EAAE,MAAM,GAAG;IAAE,OAAO,EAAE,MAAM,CAAC;IAAC,aAAa,EAAE,MAAM,CAAA;CAAE,CAW9F;AAED,wBAAgB,kBAAkB,CAAC,aAAa,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,OAAO,CAKnF;AAED;;GAEG;AACH,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,UAAU,CAAC;IACjB,SAAS,EAAE;QACT;;;WAGG;QACH,IAAI,CAAC,EAAE,MAAM,CAAC;QAEd;;;;;;;WAOG;QACH,aAAa,CAAC,EAAE,MAAM,CAAC;QAEvB;;;;;WAKG;QACH,IAAI,CAAC,EAAE,MAAM,CAAC;KACf,CAAC;IAEF,OAAO,EAAE,CAAC,WAAW,GAAG;QAAE,cAAc,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC,EAAE,CAAC;CACxD;AAkDD;;;;;;;GAOG;AACH,wBAAgB,kBAAkB,CAAC,QAAQ,EAAE,MAAM,GAAG,YAAY,GAAG,SAAS,CAqE7E;AAED;;;GAGG;AACH,wBAAgB,cAAc,CAAC,SAAS,EAAE,MAAM,GAAG,SAAS,GAAG,SAAS,CA6GvE"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=parser.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"parser.test.d.ts","sourceRoot":"","sources":["../../src/node/parser.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,11 @@
1
+ import type { StoryFilePath } from './types';
2
+ export declare const PROJECT_ROOT: string;
3
+ export { Default } from 'ember-docgen';
4
+ export type ExportedName = string;
5
+ export declare function normalizeFilePath(absPath: string): string;
6
+ export declare function addStoryFileListener(listener: (filePath: string) => void): () => void;
7
+ export declare function registerStoryFile(filePath: string): void;
8
+ export declare function getStoryFiles(): StoryFilePath[];
9
+ export declare function isStoryFile(filePath: string): boolean;
10
+ export declare function isComponentFile(filePath: string): boolean;
11
+ //# sourceMappingURL=shared.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"shared.d.ts","sourceRoot":"","sources":["../../src/node/shared.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAI7C,eAAO,MAAM,YAAY,QAAgB,CAAC;AAE1C,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAEvC,MAAM,MAAM,YAAY,GAAG,MAAM,CAAC;AAElC,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAIzD;AAMD,wBAAgB,oBAAoB,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,IAAI,GAAG,MAAM,IAAI,CAMrF;AAED,wBAAgB,iBAAiB,CAAC,QAAQ,EAAE,MAAM,QAMjD;AAED,wBAAgB,aAAa,IAAI,aAAa,EAAE,CAE/C;AAED,wBAAgB,WAAW,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAErD;AAED,wBAAgB,eAAe,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAEzD"}
@@ -0,0 +1,4 @@
1
+ import { type ContributorAPI } from '../vite-plugin-orchestrator';
2
+ import type { Plugin } from 'vite';
3
+ export declare function sourceContributor(api: ContributorAPI): Plugin;
4
+ //# sourceMappingURL=vite-plugin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"vite-plugin.d.ts","sourceRoot":"","sources":["../../../src/node/source/vite-plugin.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAGlE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,MAAM,CAAC;AAEnC,wBAAgB,iBAAiB,CAAC,GAAG,EAAE,cAAc,GAAG,MAAM,CAiE7D"}
@@ -0,0 +1,5 @@
1
+ export declare function tempFixture(files: Record<string, string>): {
2
+ base: string;
3
+ [Symbol.dispose](): void;
4
+ };
5
+ //# sourceMappingURL=test-support.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"test-support.d.ts","sourceRoot":"","sources":["../../src/node/test-support.ts"],"names":[],"mappings":"AAIA,wBAAgB,WAAW,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC;;wBAYjC,IAAI;EAI3B"}
@@ -0,0 +1,32 @@
1
+ import type { ComponentMap } from './parser';
2
+ import type { ComponentSignature } from 'ember-docgen';
3
+ import type { StaticMeta } from 'storybook/internal/csf-tools';
4
+ export type StorySource = {
5
+ inlineTemplate?: string;
6
+ componentName?: string;
7
+ signatureName?: string;
8
+ };
9
+ export type StoryFile = {
10
+ meta: StaticMeta;
11
+ component: {
12
+ file?: string;
13
+ signatureName?: string;
14
+ };
15
+ source?: Record<string, StorySource>;
16
+ };
17
+ export type ComponentFile = {
18
+ meta: ComponentMap;
19
+ signatures: Record<string, ComponentSignature>;
20
+ };
21
+ /** The path to a story file, relative to the root of the project */
22
+ export type StoryFilePath = string;
23
+ /** The path to a component file, relative to the root of the project */
24
+ export type ComponentFilePath = string;
25
+ /**
26
+ * Represents the format for Ember Meta
27
+ *
28
+ * - key: filePath relative to project root
29
+ * - value: Metadata for that file
30
+ */
31
+ export type EmberMeta = Record<StoryFilePath | ComponentFilePath, StoryFile | ComponentFile>;
32
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/node/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AAC7C,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AACvD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAE/D,MAAM,MAAM,WAAW,GAAG;IACxB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB,CAAC;AAEF,MAAM,MAAM,SAAS,GAAG;IACtB,IAAI,EAAE,UAAU,CAAC;IACjB,SAAS,EAAE;QACT,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,aAAa,CAAC,EAAE,MAAM,CAAC;KACxB,CAAC;IACF,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,WAAW,CAAC,CAAC;CACtC,CAAC;AAEF,MAAM,MAAM,aAAa,GAAG;IAC1B,IAAI,EAAE,YAAY,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,kBAAkB,CAAC,CAAC;CAChD,CAAC;AAEF,oEAAoE;AACpE,MAAM,MAAM,aAAa,GAAG,MAAM,CAAC;AACnC,wEAAwE;AACxE,MAAM,MAAM,iBAAiB,GAAG,MAAM,CAAC;AAEvC;;;;;GAKG;AAEH,MAAM,MAAM,SAAS,GAAG,MAAM,CAAC,aAAa,GAAG,iBAAiB,EAAE,SAAS,GAAG,aAAa,CAAC,CAAC"}
@@ -0,0 +1,8 @@
1
+ import type { Plugin } from 'vite';
2
+ export interface ContributorAPI {
3
+ contribute(name: string, data: Record<string, unknown>): void;
4
+ getContributions(): Map<string, Record<string, unknown>>;
5
+ invalidate?: () => void;
6
+ }
7
+ export declare function emberStorybookVitePlugin(api: ContributorAPI): Plugin;
8
+ //# sourceMappingURL=vite-plugin-orchestrator.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"vite-plugin-orchestrator.d.ts","sourceRoot":"","sources":["../../src/node/vite-plugin-orchestrator.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAc,MAAM,EAAiB,MAAM,MAAM,CAAC;AAK9D,MAAM,WAAW,cAAc;IAC7B,UAAU,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,CAAC;IAC9D,gBAAgB,IAAI,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC;IACzD,UAAU,CAAC,EAAE,MAAM,IAAI,CAAC;CACzB;AAED,wBAAgB,wBAAwB,CAAC,GAAG,EAAE,cAAc,GAAG,MAAM,CA2EpE"}
@@ -0,0 +1,3 @@
1
+ import type { Plugin } from 'vite';
2
+ export declare function emberStorybookPlugin(): Plugin[];
3
+ //# sourceMappingURL=vite-plugin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"vite-plugin.d.ts","sourceRoot":"","sources":["../../src/node/vite-plugin.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,MAAM,CAAC;AAEnC,wBAAgB,oBAAoB,IAAI,MAAM,EAAE,CAiB/C"}
@@ -1 +1 @@
1
- {"version":3,"file":"preset.d.ts","sourceRoot":"","sources":["../src/preset.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,mBAAmB,EAAsB,MAAM,yBAAyB,CAAC;AAIvF,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AAC/C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAG/D,eAAO,MAAM,kBAAkB,EAAE,cAAc,CAAC,oBAAoB,CAkBnE,CAAC;AAEF,eAAO,MAAM,SAAS,EAAE,mBAAmB,CAAC,WAAW,CAkBtD,CAAC;AAEF,eAAO,MAAM,qBAAqB,EAAE,eAAe,CAAC,uBAAuB,CAE1E,CAAC;AAEF,eAAO,MAAM,IAAI,EAAE,cAAc,CAAC,MAAM,CAcvC,CAAC"}
1
+ {"version":3,"file":"preset.d.ts","sourceRoot":"","sources":["../src/preset.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,mBAAmB,EAAsB,MAAM,yBAAyB,CAAC;AAKvF,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AAC/C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAG/D,eAAO,MAAM,kBAAkB,EAAE,cAAc,CAAC,oBAAoB,CAkBnE,CAAC;AAEF,eAAO,MAAM,SAAS,EAAE,mBAAmB,CAAC,WAAW,CActD,CAAC;AAEF,eAAO,MAAM,qBAAqB,EAAE,eAAe,CAAC,uBAAuB,CAE1E,CAAC;AAEF,eAAO,MAAM,IAAI,EAAE,cAAc,CAAC,MAAM,CAcvC,CAAC"}
@@ -0,0 +1,12 @@
1
+ //#region src/client/docs/block-params.ts
2
+ function isBlockParam(param) {
3
+ return Object.hasOwn(param, "name") && Object.hasOwn(param, "type");
4
+ }
5
+ /** Flatten the params union into plain block params, unwrapping yield hashes. */
6
+ function unwrapBlockParams(params) {
7
+ return params.flatMap((param) => isBlockParam(param) ? [param] : Object.values(param));
8
+ }
9
+ //#endregion
10
+ export { unwrapBlockParams as t };
11
+
12
+ //# sourceMappingURL=block-params-C68OkWMC.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"block-params-C68OkWMC.mjs","names":["isBlockParam","param","Object","hasOwn","unwrapBlockParams","params","flatMap","values"],"sources":["../src/client/docs/block-params.ts"],"sourcesContent":["import type { BlockInfo, BlockParam, HashBlockParam } from 'ember-docgen';\n\nfunction isBlockParam(param: BlockParam | HashBlockParam): param is BlockParam {\n return Object.hasOwn(param, 'name') && Object.hasOwn(param, 'type');\n}\n\n/** Flatten the params union into plain block params, unwrapping yield hashes. */\nexport function unwrapBlockParams(params: BlockInfo['params']): BlockParam[] {\n return params.flatMap((param) => (isBlockParam(param) ? [param] : Object.values(param)));\n}\n"],"mappings":";AAEA,SAASA,aAAaC,OAAyD;CAC7E,OAAOC,OAAOC,OAAOF,OAAO,MAAM,KAAKC,OAAOC,OAAOF,OAAO,MAAM;AACpE;;AAGA,SAAgBG,kBAAkBC,QAA2C;CAC3E,OAAOA,OAAOC,SAASL,UAAWD,aAAaC,KAAK,IAAI,CAACA,KAAK,IAAIC,OAAOK,OAAON,KAAK,CAAE;AACzF"}
@@ -1,4 +1,4 @@
1
- import { n as renderToCanvas, t as render } from "../render-BUq_AxtY.mjs";
1
+ import { n as renderToCanvas, t as render } from "../render-DRAVRbiI.mjs";
2
2
  import { enhanceArgTypes } from "storybook/internal/docs-tools";
3
3
  //#region src/client/config.ts
4
4
  const parameters = {