File tree Expand file tree Collapse file tree 2 files changed +4
-3
lines changed
addons/docs/template/stories/docs2 Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change 1- import { Meta } from ' @storybook/addon-docs' ;
1+ import { Meta , Subtitle } from ' @storybook/addon-docs' ;
22
33<Meta title = " Yabbadabbadooo" />
44
55# Docs with title
66
7+ <Subtitle >Subtitle</Subtitle >
8+
79hello docs
Original file line number Diff line number Diff line change @@ -9,8 +9,7 @@ interface SubtitleProps {
99
1010export const Subtitle : FunctionComponent < SubtitleProps > = ( { children } ) => {
1111 const docsContext = useContext ( DocsContext ) ;
12- const { parameters } = docsContext . storyById ( ) ;
13- const content = children || parameters ?. componentSubtitle ;
12+ const content = children || docsContext . storyById ( ) . parameters ?. componentSubtitle ;
1413
1514 return content ? (
1615 < PureSubtitle className = "sbdocs-subtitle sb-unstyled" > { content } </ PureSubtitle >
You can’t perform that action at this time.
0 commit comments