Skip to content

Commit 2933fd8

Browse files
committed
use command chip
1 parent f3a9780 commit 2933fd8

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

packages/stream_chat_flutter/lib/src/components/message_composer/stream_chat_message_composer.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -307,6 +307,8 @@ class DefaultStreamChatMessageComposer extends StatelessWidget {
307307
controller: inputController.textFieldController,
308308
placeholder: props.placeholder,
309309
focusNode: props.focusNode,
310+
command: inputController.message.command,
311+
onDismissCommand: () => inputController.command = null,
310312
),
311313
if (props.canAlsoSendToChannel)
312314
DmCheckboxListTile(

packages/stream_chat_flutter_core/lib/src/stream_message_input_controller.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ class StreamMessageInputController extends ValueNotifier<Message> {
182182
}
183183

184184
/// Sets a command for the message.
185-
set command(String command) {
185+
set command(String? command) {
186186
// Setting the command should also clear the text and attachments.
187187
message = message.copyWith(
188188
text: '',

0 commit comments

Comments
 (0)