File tree Expand file tree Collapse file tree 3 files changed +24
-9
lines changed Expand file tree Collapse file tree 3 files changed +24
-9
lines changed Original file line number Diff line number Diff line change 1313html {
1414 background : # fff ;
1515}
16- .content-wrapper {
17- padding : 16px ;
18- }
19- .content-wrapper > div > div : nth-child (2 ) {
20- padding : 16px ;
21- }
2216</ style >
Original file line number Diff line number Diff line change 1+ import 'core-js/stable' ;
2+ import { withScreenshot } from 'storycap' ;
3+ import wrapSLDS from './wrapSLDS' ;
4+
5+ let assetRoot ;
6+ if ( typeof location !== 'undefined' && location . hostname === 'mashmatrix.github.io' ) {
7+ assetRoot = '//mashmatrix.github.io/react-lightning-design-system/assets' ;
8+ }
9+
10+ const withSLDS = wrapSLDS ( { assetRoot } ) ;
11+
12+ export const decorators = [
13+ withScreenshot ,
14+ withSLDS ,
15+ ] ;
16+
17+ export const parameters = {
18+ // Global parameter is optional.
19+ screenshot : {
20+ // Put global screenshot parameters(e.g. viewport)
21+ } ,
22+ } ;
Original file line number Diff line number Diff line change 11import React from 'react' ;
2- import classnames from 'classnames' ;
32import { ComponentSettings } from '../src/scripts' ;
43
5- export default function wrapContent ( options ) {
4+ export default function wrapSLDS ( options ) {
65 return story => (
76 < ComponentSettings assetRoot = { options . assetRoot } portalClassName = 'slds' >
8- < div className = { classnames ( 'content-wrapper' , options . className ) } > { story ( ) } </ div >
7+ { story ( ) }
98 </ ComponentSettings >
109 ) ;
1110}
You can’t perform that action at this time.
0 commit comments