Skip to content

Commit 9fe621f

Browse files
authored
Use min and max values in storybook breakpoints (#1736)
1 parent e754300 commit 9fe621f

File tree

1 file changed

+50
-8
lines changed

1 file changed

+50
-8
lines changed

docs/.storybook/preview.js

Lines changed: 50 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,33 +4,75 @@ import '../../src/base/index.scss'
44
import renderToHTML from '../src/stories/helpers/code-snippet-html-helper'
55

66
const customViewports = {
7-
widthSM: {
8-
name: 'width-sm',
7+
minXS: {
8+
name: 'XS (min)',
9+
styles: {
10+
width: '375px',
11+
height: '100%'
12+
}
13+
},
14+
maxXS: {
15+
name: 'XS (max)',
16+
styles: {
17+
width: '543px',
18+
height: '100%'
19+
}
20+
},
21+
minSM: {
22+
name: 'SM (min)',
923
styles: {
1024
width: '544px',
1125
height: '100%'
1226
}
1327
},
14-
widthMD: {
15-
name: 'width-md',
28+
maxSM: {
29+
name: 'SM (max)',
30+
styles: {
31+
width: '767px',
32+
height: '100%'
33+
}
34+
},
35+
minMD: {
36+
name: 'MD (min)',
1637
styles: {
1738
width: '768px',
1839
height: '100%'
1940
}
2041
},
21-
widthLG: {
22-
name: 'width-lg',
42+
maxMD: {
43+
name: 'MD (max)',
44+
styles: {
45+
width: '1011px',
46+
height: '100%'
47+
}
48+
},
49+
minLG: {
50+
name: 'LG (min)',
2351
styles: {
2452
width: '1012px',
2553
height: '100%'
2654
}
2755
},
28-
widthXL: {
29-
name: 'width-xl',
56+
maxLG: {
57+
name: 'LG (max)',
58+
styles: {
59+
width: '1279px',
60+
height: '100%'
61+
}
62+
},
63+
minXL: {
64+
name: 'XL (min)',
3065
styles: {
3166
width: '1280px',
3267
height: '100%'
3368
}
69+
},
70+
medXL: {
71+
name: 'XL (med)',
72+
styles: {
73+
width: '1440px',
74+
height: '100%'
75+
}
3476
}
3577
}
3678

0 commit comments

Comments
 (0)