File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -22,6 +22,7 @@ interface Orientation {
2222}
2323
2424type SplitThemeOptions = Orientation & {
25+ /** Allows the format heading to be omitted on the split theme decorator */
2526 hideFormatHeading ?: boolean ;
2627} ;
2728
Original file line number Diff line number Diff line change @@ -2,12 +2,10 @@ import { css } from '@emotion/react';
22import { from } from '@guardian/source/foundations' ;
33import type { Meta , StoryObj } from '@storybook/react' ;
44import { userEvent , within } from '@storybook/test' ;
5- import { splitTheme } from '../../.storybook/decorators/splitThemeDecorator' ;
65import {
7- ArticleDesign ,
8- ArticleDisplay ,
9- ArticleSpecial ,
10- } from '../lib/articleFormat' ;
6+ defaultFormats ,
7+ splitTheme ,
8+ } from '../../.storybook/decorators/splitThemeDecorator' ;
119import { LabsSectionHeader } from './LabsSectionHeader' ;
1210
1311const meta = {
@@ -33,16 +31,10 @@ const meta = {
3331 </ div >
3432 ) ,
3533 decorators : [
36- splitTheme (
37- [
38- {
39- theme : ArticleSpecial . Labs ,
40- design : ArticleDesign . Feature ,
41- display : ArticleDisplay . Standard ,
42- } ,
43- ] ,
44- { orientation : 'vertical' , hideFormatHeading : true } ,
45- ) ,
34+ splitTheme ( [ defaultFormats [ 0 ] ] , {
35+ orientation : 'vertical' ,
36+ hideFormatHeading : true ,
37+ } ) ,
4638 ] ,
4739} satisfies Meta < typeof LabsSectionHeader > ;
4840export default meta ;
You can’t perform that action at this time.
0 commit comments