Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(): update story interface #3443

Merged
merged 1 commit into from
Sep 5, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 15 additions & 1 deletion etc/brick-types.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -2186,11 +2186,13 @@ export interface Story {
// (undocumented)
actions?: Action[];
// (undocumented)
alias?: string[];
// (undocumented)
author?: string;
// (undocumented)
category: string;
// (undocumented)
conf: StoryConf | StoryConf[] | mixConf[];
conf: StoryConf | StoryConf[] | mixConf[] | V3StoryConf;
// (undocumented)
deprecated?: boolean;
// (undocumented)
Expand All @@ -2208,6 +2210,8 @@ export interface Story {
// (undocumented)
previewColumns?: number;
// (undocumented)
source?: string;
// (undocumented)
storyId: string;
// (undocumented)
tags?: I18nData[];
Expand All @@ -2217,6 +2221,8 @@ export interface Story {
type: "brick" | "template";
// (undocumented)
useWidget?: string[];
// (undocumented)
v3Brick?: boolean;
}

// @public
Expand Down Expand Up @@ -2664,5 +2670,13 @@ export interface UseSingleBrickConf {
transformFrom?: string | string[];
}

// Warning: (ae-internal-missing-underscore) The name "V3StoryConf" should be prefixed with an underscore because the declaration is marked as @internal
//
// @internal (undocumented)
export interface V3StoryConf {
// (undocumented)
doc?: string;
}


```
10 changes: 9 additions & 1 deletion packages/brick-types/src/story.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,14 +46,19 @@ export interface SnippetConf {
/** @internal */
export type mixConf = StoryConf | SnippetConf;

/** @internal */
export interface V3StoryConf {
doc?: string;
}

/** @internal */
export interface Story {
category: string;
storyId: string;
deprecated?: boolean;
type: "brick" | "template";
text: I18nData;
conf: StoryConf | StoryConf[] | mixConf[];
conf: StoryConf | StoryConf[] | mixConf[] | V3StoryConf;
description?: I18nData;
tags?: I18nData[];
doc?: string | StoryDoc;
Expand All @@ -65,6 +70,9 @@ export interface Story {
originData?: BuilderCustomTemplateNode;
isCustomTemplate?: boolean;
useWidget?: string[];
v3Brick?: boolean;
source?: string;
alias?: string[];
}

/** @internal */
Expand Down
Loading