@@ -9,6 +9,8 @@ export default {
99
1010const Template = ( args ) => < BetterImage { ...args } /> ;
1111
12+ const imageStyle = { height : 200 , width : 400 } ;
13+
1214const validSource = ( ) => ( {
1315 source : {
1416 uri : `https://unsplash.com/photos/yNvVnPcurD8/download?force=true&w=2400&bust=${ Math . random ( ) } ` ,
@@ -23,7 +25,7 @@ const validSource = () => ({
2325export const ValidImage = Template . bind ( { } ) ;
2426ValidImage . args = {
2527 ...validSource ( ) ,
26- viewStyle : { height : 400 , width : 400 } ,
28+ viewStyle : imageStyle ,
2729 resizeMode : 'contain' ,
2830} ;
2931
@@ -42,7 +44,7 @@ const inValidSource = () => ({
4244export const InvalidImage = Template . bind ( { } ) ;
4345InvalidImage . args = {
4446 ...inValidSource ( ) ,
45- viewStyle : { height : 400 , width : 400 } ,
47+ viewStyle : imageStyle ,
4648 resizeMode : 'contain' ,
4749} ;
4850
@@ -60,14 +62,14 @@ const invalidImageOnlySource = () => ({
6062export const InvalidImageButWithValidThumbnail = Template . bind ( { } ) ;
6163InvalidImageButWithValidThumbnail . args = {
6264 ...invalidImageOnlySource ( ) ,
63- viewStyle : { height : 400 , width : 400 } ,
65+ viewStyle : imageStyle ,
6466 resizeMode : 'contain' ,
6567} ;
6668
6769export const CustomImageFadeDuration = Template . bind ( { } ) ;
6870CustomImageFadeDuration . args = {
6971 ...validSource ( ) ,
70- viewStyle : { height : 400 , width : 400 } ,
72+ viewStyle : imageStyle ,
7173 resizeMode : 'contain' ,
7274 thumbnailFadeDuration : 250 ,
7375 imageFadeDuration : 2000 ,
0 commit comments