Merge pull request #1079 from GetStream/release/4.0.0-beta.2

chore(llc,core,ui): update pubspec and changelogs
This commit is contained in:
Salvatore Giordano
2022-04-14 11:45:36 +02:00
committed by GitHub
11 changed files with 115 additions and 28 deletions
+19 -3
View File
@@ -1,4 +1,21 @@
<<<<<<< HEAD ## 4.0.0-beta.2
🐞 Fixed
- Fixed reactions not working for threads in offline mode.
- [[#1046]](https://github.com/GetStream/stream-chat-flutter/issues/1046) After `/mute` command on reload cannot access
any channel.
- [[#1047]](https://github.com/GetStream/stream-chat-flutter/issues/1047) `own_capabilities` extraData missing after
channel update.
- [[#1054]](https://github.com/GetStream/stream-chat-flutter/issues/1054) Fix `Unsupported operation: Cannot remove from an unmodifiable list`.
- [[#1033]](https://github.com/GetStream/stream-chat-flutter/issues/1033) Hard delete from dashboard does not delete message from client.
- Send only `user_id` while reconnecting.
✅ Added
- Handle `event.message` in `channel.truncate` events
- Added additional parameters to `channel.truncate`
## 4.0.0-beta.0 ## 4.0.0-beta.0
✅ Added ✅ Added
@@ -8,13 +25,12 @@
🐞 Fixed 🐞 Fixed
- Minor fixes and improvements. - Minor fixes and improvements.
=======
## 3.6.1 ## 3.6.1
🐞 Fixed 🐞 Fixed
- [[#1081]](https://github.com/GetStream/stream-chat-flutter/issues/1081) Fixed a bug with user reconnection. - [[#1081]](https://github.com/GetStream/stream-chat-flutter/issues/1081) Fixed a bug with user reconnection.
>>>>>>> develop
## 3.6.0 ## 3.6.0
+1 -1
View File
@@ -3,4 +3,4 @@ import 'package:stream_chat/src/client/client.dart';
/// Current package version /// Current package version
/// Used in [StreamChatClient] to build the `x-stream-client` header /// Used in [StreamChatClient] to build the `x-stream-client` header
// ignore: constant_identifier_names // ignore: constant_identifier_names
const PACKAGE_VERSION = '4.0.0-beta.0'; const PACKAGE_VERSION = '4.0.0-beta.2';
+1 -1
View File
@@ -1,7 +1,7 @@
name: stream_chat name: stream_chat
homepage: https://getstream.io/ homepage: https://getstream.io/
description: The official Dart client for Stream Chat, a service for building chat applications. description: The official Dart client for Stream Chat, a service for building chat applications.
version: 4.0.0-beta.0 version: 4.0.0-beta.2
repository: https://github.com/GetStream/stream-chat-flutter repository: https://github.com/GetStream/stream-chat-flutter
issue_tracker: https://github.com/GetStream/stream-chat-flutter/issues issue_tracker: https://github.com/GetStream/stream-chat-flutter/issues
@@ -59,7 +59,10 @@ void main() {
}); });
test('`connect` successfully with the provided user', () async { test('`connect` successfully with the provided user', () async {
final user = OwnUser(id: 'test-user'); final user = OwnUser(
id: 'test-user',
name: 'test',
);
const connectionId = 'test-connection-id'; const connectionId = 'test-connection-id';
// Sends connect event to web-socket stream // Sends connect event to web-socket stream
final timer = Timer(const Duration(milliseconds: 300), () { final timer = Timer(const Duration(milliseconds: 300), () {
@@ -90,6 +93,44 @@ void main() {
addTearDown(timer.cancel); addTearDown(timer.cancel);
}); });
test('`connect` successfully without user details', () async {
final user = OwnUser(
id: 'test-user',
name: 'test',
);
const connectionId = 'test-connection-id';
// Sends connect event to web-socket stream
final timer = Timer(const Duration(milliseconds: 300), () {
final event = Event(
type: EventType.healthCheck,
connectionId: connectionId,
me: user,
);
webSocketSink.add(json.encode(event));
});
expectLater(
webSocket.connectionStatusStream,
emitsInOrder([
ConnectionStatus.disconnected,
ConnectionStatus.connecting,
ConnectionStatus.connected,
]),
);
final event = await webSocket.connect(
user,
includeUserDetails: true,
);
expect(event.type, EventType.healthCheck);
expect(event.connectionId, connectionId);
expect(event.me, isNotNull);
expect(event.me!.id, user.id);
addTearDown(timer.cancel);
});
test('`connect` should throw if already in connection attempt', () async { test('`connect` should throw if already in connection attempt', () async {
final user = OwnUser(id: 'test-user'); final user = OwnUser(id: 'test-user');
webSocket.connect(user); webSocket.connect(user);
+10 -2
View File
@@ -1,11 +1,19 @@
## Upcoming ## 4.0.0-beta.2
✅ Added ✅ Added
- Added support to pass `autoCorrect` to `StreamMessageInput` for the text input field - Added support to pass `autoCorrect` to `StreamMessageInput` for the text input field
- Added support to control the visibility of the default emoji suggestions overlay - Added support to control the visibility of the default emoji suggestions overlay in `StreamMessageInput`
- Added support to build custom widget for scrollToBottom in `StreamMessageListView` - Added support to build custom widget for scrollToBottom in `StreamMessageListView`
🐞 Fixed
- Minor fixes and improvements
-[[#892]](https://github.com/GetStream/stream-chat-flutter/issues/892): Fix default `initialAlignment` in `MessageListView`.
- Fix `MessageInputTheme.inputBackgroundColor` color not being used in some widgets of `MessageInput`
- Removed dependency on `visibility_detector`
- [[#1071]](https://github.com/GetStream/stream-chat-flutter/issues/1071): Fixed the way attachment actions were handled in full screen
## 4.0.0-beta.1 ## 4.0.0-beta.1
✅ Added ✅ Added
@@ -593,6 +593,7 @@ class StreamMessageInputState extends State<StreamMessageInput>
elevation: widget.elevation ?? elevation: widget.elevation ??
_streamChatTheme.messageInputTheme.elevation ?? _streamChatTheme.messageInputTheme.elevation ??
8, 8,
color: _messageInputTheme.inputBackgroundColor,
child: child, child: child,
); );
} }
@@ -789,6 +790,7 @@ class StreamMessageInputState extends State<StreamMessageInput>
gradient: _focusNode.hasFocus gradient: _focusNode.hasFocus
? _messageInputTheme.activeBorderGradient ? _messageInputTheme.activeBorderGradient
: _messageInputTheme.idleBorderGradient, : _messageInputTheme.idleBorderGradient,
color: _messageInputTheme.inputBackgroundColor,
), ),
child: Padding( child: Padding(
padding: const EdgeInsets.all(1.5), padding: const EdgeInsets.all(1.5),
+2 -6
View File
@@ -1,7 +1,7 @@
name: stream_chat_flutter name: stream_chat_flutter
homepage: https://github.com/GetStream/stream-chat-flutter homepage: https://github.com/GetStream/stream-chat-flutter
description: Stream Chat official Flutter SDK. Build your own chat experience using Dart and Flutter. description: Stream Chat official Flutter SDK. Build your own chat experience using Dart and Flutter.
version: 4.0.0-beta.1 version: 4.0.0-beta.2
repository: https://github.com/GetStream/stream-chat-flutter repository: https://github.com/GetStream/stream-chat-flutter
issue_tracker: https://github.com/GetStream/stream-chat-flutter/issues issue_tracker: https://github.com/GetStream/stream-chat-flutter/issues
@@ -36,11 +36,7 @@ dependencies:
rxdart: ^0.27.0 rxdart: ^0.27.0
share_plus: ^4.0.1 share_plus: ^4.0.1
shimmer: ^2.0.0 shimmer: ^2.0.0
<<<<<<< HEAD stream_chat_flutter_core: ^4.0.0-beta.2
stream_chat_flutter_core: ^4.0.0-beta.0
=======
stream_chat_flutter_core: ^3.6.1
>>>>>>> develop
substring_highlight: ^1.0.26 substring_highlight: ^1.0.26
url_launcher: ^6.0.3 url_launcher: ^6.0.3
video_player: ^2.1.0 video_player: ^2.1.0
@@ -452,15 +452,16 @@ void main() {
await tester.tap(find.text('Save Image')); await tester.tap(find.text('Save Image'));
imageDownloader.progressCallback!(0, 100); imageDownloader.progressCallback!(0, 100000);
await tester.pump(); await tester.pump();
expect(find.text('0%'), findsOneWidget); expect(find.text('0.00 MB'), findsOneWidget);
imageDownloader.progressCallback!(50, 100); imageDownloader.progressCallback!(50000, 100000);
await tester.pump(); await tester.pump();
expect(find.text('50%'), findsOneWidget); expect(find.text('0.05 MB'), findsOneWidget);
imageDownloader.progressCallback!(100, 100); imageDownloader.progressCallback!(100000, 100000);
imageDownloader.downloadedPathCallback!('path');
imageDownloader.completer.complete('path'); imageDownloader.completer.complete('path');
await tester.pump(); await tester.pump();
expect(find.byKey(const Key('completedIcon')), findsOneWidget); expect(find.byKey(const Key('completedIcon')), findsOneWidget);
@@ -510,15 +511,16 @@ void main() {
await tester.tap(find.text('Save Video')); await tester.tap(find.text('Save Video'));
fileDownloader.progressCallback!(0, 100); fileDownloader.progressCallback!(0, 100000);
await tester.pump(); await tester.pump();
expect(find.text('0%'), findsOneWidget); expect(find.text('0.00 MB'), findsOneWidget);
fileDownloader.progressCallback!(50, 100); fileDownloader.progressCallback!(50000, 100000);
await tester.pump(); await tester.pump();
expect(find.text('50%'), findsOneWidget); expect(find.text('0.05 MB'), findsOneWidget);
fileDownloader.progressCallback!(100, 100); fileDownloader.progressCallback!(100000, 100000);
fileDownloader.downloadedPathCallback!('path');
fileDownloader.completer.complete('path'); fileDownloader.completer.complete('path');
await tester.pump(); await tester.pump();
expect(find.byKey(const Key('completedIcon')), findsOneWidget); expect(find.byKey(const Key('completedIcon')), findsOneWidget);
@@ -66,7 +66,16 @@ void main() {
home: Builder( home: Builder(
builder: (context) { builder: (context) {
_context = context; _context = context;
final _message = Message(); final attachment = Attachment(
type: 'video',
title: 'video.mp4',
);
final _message = Message(
createdAt: DateTime.now(),
attachments: [
attachment,
],
);
return Scaffold( return Scaffold(
appBar: StreamGalleryHeader( appBar: StreamGalleryHeader(
message: _message, message: _message,
@@ -107,7 +116,16 @@ void main() {
home: Builder( home: Builder(
builder: (context) { builder: (context) {
_context = context; _context = context;
final _message = Message(); final attachment = Attachment(
type: 'video',
title: 'video.mp4',
);
final _message = Message(
createdAt: DateTime.now(),
attachments: [
attachment,
],
);
return Scaffold( return Scaffold(
appBar: StreamGalleryHeader( appBar: StreamGalleryHeader(
message: _message, message: _message,
@@ -1,3 +1,7 @@
## 4.0.0-beta.2
- Updated `stream_chat` dependency to [`4.0.0-beta.2`](https://pub.dev/packages/stream_chat/changelog).
## 4.0.0-beta.0 ## 4.0.0-beta.0
✅ Added ✅ Added
@@ -1,7 +1,7 @@
name: stream_chat_flutter_core name: stream_chat_flutter_core
homepage: https://github.com/GetStream/stream-chat-flutter homepage: https://github.com/GetStream/stream-chat-flutter
description: Stream Chat official Flutter SDK Core. Build your own chat experience using Dart and Flutter. description: Stream Chat official Flutter SDK Core. Build your own chat experience using Dart and Flutter.
version: 4.0.0-beta.0 version: 4.0.0-beta.2
repository: https://github.com/GetStream/stream-chat-flutter repository: https://github.com/GetStream/stream-chat-flutter
issue_tracker: https://github.com/GetStream/stream-chat-flutter/issues issue_tracker: https://github.com/GetStream/stream-chat-flutter/issues
@@ -17,7 +17,7 @@ dependencies:
freezed_annotation: ^1.0.0 freezed_annotation: ^1.0.0
meta: ^1.3.0 meta: ^1.3.0
rxdart: ^0.27.0 rxdart: ^0.27.0
stream_chat: ^4.0.0-beta.0 stream_chat: ^4.0.0-beta.2
dev_dependencies: dev_dependencies:
build_runner: ^2.0.1 build_runner: ^2.0.1