Skip to content
This repository was archived by the owner on Feb 22, 2023. It is now read-only.

Commit 4d17090

Browse files
🍱 Add resources/transparentImage.gif
1 parent 1d2638a commit 4d17090

File tree

4 files changed

+15
-4
lines changed

4 files changed

+15
-4
lines changed

packages/google_sign_in/google_sign_in/lib/widgets.dart

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,11 +115,13 @@ class GoogleUserCircleAvatar extends StatelessWidget {
115115
}
116116

117117
/// This is an transparent 1x1 gif image.
118+
///
119+
/// Those bytes come from `resources/transparentImage.dart`.
118120
final Uint8List _transparentImage = Uint8List.fromList(
119121
[
120122
0x47, 0x49, 0x46, 0x38, 0x39, 0x61, 0x01, 0x00, 0x01, 0x00, 0x80, 0x00, //
121-
0x00, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x21, 0xF9, 0x04, 0x01, 0x00, //
123+
0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0x21, 0xf9, 0x04, 0x01, 0x00, //
122124
0x00, 0x00, 0x00, 0x2C, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00, //
123-
0x00, 0x02, 0x02, 0x44, 0x01, 0x00, 0x3B
125+
0x00, 0x02, 0x01, 0x44, 0x00, 0x3B
124126
],
125127
);
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
`transparentImage.gif` is a 1x1 transparent gif which comes from [this wikimedia page](https://commons.wikimedia.org/wiki/File:Transparent.gif):
2+
3+
![](transparentImage.gif)
4+
5+
This is the image used a placeholder for the `GoogleCircleAvatar` widget.
6+
7+
The variable `_transparentImage` in `lib/widgets.dart` is the list of bytes of `transparentImage.gif`.
Loading

packages/google_sign_in/google_sign_in/test/widgets_test.dart

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,12 +53,14 @@ class _MockHttpRequest extends Fake implements HttpClientRequest {
5353
///
5454
/// This is an transparent 1x1 gif image.
5555
/// It doesn't have to match the placeholder used in [GoogleUserCircleAvatar].
56+
///
57+
/// Those bytes come from `resources/transparentImage.dart`.
5658
final Uint8List _transparentImage = Uint8List.fromList(
5759
[
5860
0x47, 0x49, 0x46, 0x38, 0x39, 0x61, 0x01, 0x00, 0x01, 0x00, 0x80, 0x00, //
59-
0x00, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x21, 0xF9, 0x04, 0x01, 0x00, //
61+
0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0x21, 0xf9, 0x04, 0x01, 0x00, //
6062
0x00, 0x00, 0x00, 0x2C, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00, //
61-
0x00, 0x02, 0x02, 0x44, 0x01, 0x00, 0x3B //
63+
0x00, 0x02, 0x01, 0x44, 0x00, 0x3B
6264
],
6365
);
6466

0 commit comments

Comments
 (0)