File tree 2 files changed +10
-4
lines changed
2 files changed +10
-4
lines changed Original file line number Diff line number Diff line change @@ -38,12 +38,18 @@ class StyleView extends ConsumerWidget {
38
38
mainAxisSpacing: isMobile ? 15 : 20 ,
39
39
),
40
40
itemBuilder: (context, index) => prov.when (
41
- data: (data ) => InkWell (
41
+ data: (imagesList ) => InkWell (
42
42
onTap: () {
43
+ // fix weird character on windows
44
+ imagesList = imagesList
45
+ .map (
46
+ (item) => item.replaceAll ("%0D" , "" ),
47
+ )
48
+ .toList ();
43
49
// update the content image provider(will update the ui image)
44
50
context.read (styleProvider.notifier).setState (
45
51
CachedNetworkImageProvider (
46
- BUCKET_PREFIX + data [index],
52
+ BUCKET_PREFIX + imagesList [index],
47
53
),
48
54
);
49
55
@@ -53,7 +59,7 @@ class StyleView extends ConsumerWidget {
53
59
nav.pop ();
54
60
},
55
61
child: NetworkImageContainer (
56
- imgName: data [index],
62
+ imgName: imagesList [index],
57
63
),
58
64
),
59
65
loading: () => CupertinoActivityIndicator (),
Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ class NetworkImageContainer extends StatelessWidget {
14
14
return ClipRRect (
15
15
borderRadius: BorderRadius .circular (20 ),
16
16
child: CachedNetworkImage (
17
- imageUrl: BUCKET_PREFIX + imgName! ,
17
+ imageUrl: BUCKET_PREFIX + imgName! . replaceAll ( "%0D" , "" ) ,
18
18
placeholder: (context, url) => SizedBox (
19
19
height: height * 0.6 ,
20
20
width: height * 0.6 ,
You can’t perform that action at this time.
0 commit comments