Skip to content

Commit

Permalink
Merge pull request #1552 from GetStream/fix/progress-indicator
Browse files Browse the repository at this point in the history
  • Loading branch information
xsahil03x committed May 16, 2023
2 parents 94221ec + b9ce77f commit 6081f25
Show file tree
Hide file tree
Showing 14 changed files with 23 additions and 19 deletions.
8 changes: 4 additions & 4 deletions packages/stream_chat_flutter/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
- [[#1546]](https://github.com/GetStream/stream-chat-flutter/issues/1546)
Fixed `StreamMessageInputTheme.linkHighlightColor` returning null for default theme.
- [[#1548]](https://github.com/GetStream/stream-chat-flutter/issues/1548) Fixed `StreamMessageInput` urlRegex only
matching the
lowercase `http(s)|ftp`.
matching the lowercase `http(s)|ftp`.
- [[#1542]](https://github.com/GetStream/stream-chat-flutter/issues/1542) Handle error thrown in `StreamMessageInput`
when unable to fetch a
link preview.
when unable to fetch a link preview.
- [[#1540]](https://github.com/GetStream/stream-chat-flutter/issues/1540) Use `CircularProgressIndicator.adaptive`
instead of material indicator.

## 6.1.0

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ class _FileTypeImage extends StatelessWidget {
child: SizedBox(
width: 20,
height: 20,
child: CircularProgressIndicator(),
child: CircularProgressIndicator.adaptive(),
),
),
),
Expand All @@ -210,7 +210,7 @@ class _FileTypeImage extends StatelessWidget {
child: SizedBox(
width: 20,
height: 20,
child: CircularProgressIndicator(),
child: CircularProgressIndicator.adaptive(),
),
),
),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ class StreamGiphyAttachment extends StreamAttachmentWidget {
width: constraints?.maxHeight,
height: constraints?.maxWidth,
child: const Center(
child: CircularProgressIndicator(),
child: CircularProgressIndicator.adaptive(),
),
),
imageUrl: imageUrl,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -345,9 +345,11 @@ class AttachmentActionsModal extends StatelessWidget {
child: Stack(
fit: StackFit.expand,
children: [
CircularProgressIndicator(
CircularProgressIndicator.adaptive(
strokeWidth: 8,
color: theme.colorTheme.accentPrimary,
valueColor: AlwaysStoppedAnimation<Color>(
theme.colorTheme.accentPrimary,
),
),
Center(
child: Text(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ class _ConnectingTitleState extends StatelessWidget {
height: 16,
width: 16,
child: Center(
child: CircularProgressIndicator(),
child: CircularProgressIndicator.adaptive(),
),
),
const SizedBox(width: 10),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ class _ConnectingTitleState extends StatelessWidget {
height: 16,
width: 16,
child: Center(
child: CircularProgressIndicator(),
child: CircularProgressIndicator.adaptive(),
),
),
const SizedBox(width: 10),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -337,7 +337,7 @@ class _FullScreenMediaState extends State<StreamFullScreenMedia> {
final controller = videoPackages[attachment.id]!;
if (!controller.initialized) {
return const Center(
child: CircularProgressIndicator(),
child: CircularProgressIndicator.adaptive(),
);
}
return InkWell(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ class StreamUploadProgressIndicator extends StatelessWidget {
SizedBox(
height: 16,
width: 16,
child: CircularProgressIndicator(
child: CircularProgressIndicator.adaptive(
strokeWidth: 3,
valueColor: AlwaysStoppedAnimation(progressIndicatorColor),
),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -303,7 +303,7 @@ class _ParseAttachments extends StatelessWidget {
width: size.width,
height: size.height,
child: const Center(
child: CircularProgressIndicator(),
child: CircularProgressIndicator.adaptive(),
),
);
},
Expand Down Expand Up @@ -394,7 +394,7 @@ class _VideoAttachmentThumbnailState extends State<_VideoAttachmentThumbnail> {
width: 32,
child: _controller.value.isInitialized
? VideoPlayer(_controller)
: const CircularProgressIndicator(),
: const CircularProgressIndicator.adaptive(),
);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ class LoadingIndicator extends StatelessWidget {
const Center(
child: Padding(
padding: EdgeInsets.all(8),
child: CircularProgressIndicator(),
child: CircularProgressIndicator.adaptive(),
),
);
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -432,7 +432,7 @@ class _StreamMessageListViewState extends State<StreamMessageListView> {
messageFilter: widget.messageFilter,
loadingBuilder: widget.loadingBuilder ??
(context) => const Center(
child: CircularProgressIndicator(),
child: CircularProgressIndicator.adaptive(),
),
emptyBuilder: widget.emptyBuilder ??
(context) => Center(
Expand Down
2 changes: 2 additions & 0 deletions packages/stream_chat_flutter_core/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
- Updated `stream_chat` dependency to [`6.1.0`](https://pub.dev/packages/stream_chat/changelog).
- [[#1356]](https://github.com/GetStream/stream-chat-flutter/issues/1356) Channel doesn't auto display again after being
hidden.
- [[#1540]](https://github.com/GetStream/stream-chat-flutter/issues/1540) Use `CircularProgressIndicator.adaptive`
instead of material indicator.

## 6.0.0

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ bool Function(Message) defaultMessageFilter(String currentUserId) =>
/// },
/// loadingBuilder: (context) {
/// return Center(
/// child: CircularProgressIndicator(),
/// child: CircularProgressIndicator.adaptive(),
/// );
/// },
/// messageListBuilder: (context, list) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -445,7 +445,7 @@ class StreamChannelState extends State<StreamChannel> {
final dataLoaded = snapshot.data?.every((it) => it) == true;
if (widget.showLoading && !dataLoaded) {
return const Center(
child: CircularProgressIndicator(),
child: CircularProgressIndicator.adaptive(),
);
}
return widget.child;
Expand Down

0 comments on commit 6081f25

Please sign in to comment.