From f30410e2fb6ad84de85c72c13fdef5efaf7c3937 Mon Sep 17 00:00:00 2001 From: Luke Walton Date: Fri, 8 Mar 2024 13:45:48 +0000 Subject: [PATCH] fix: remove voice note option on web (#7) --- lib/src/components/organisms/chat/message_input.dart | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/src/components/organisms/chat/message_input.dart b/lib/src/components/organisms/chat/message_input.dart index 2950c13..2e71514 100644 --- a/lib/src/components/organisms/chat/message_input.dart +++ b/lib/src/components/organisms/chat/message_input.dart @@ -56,6 +56,9 @@ class ZdsMessageInput extends StatefulWidget { final void Function(List file)? onUploadFiles; /// Enables voice notes to be sent as messages + /// + /// Does not currently work on web. + /// /// Defaults to false final bool allowVoiceNotes; @@ -330,7 +333,7 @@ class ZdsMessageInputState extends State with SingleTickerProvi }, ), ), - if (widget.allowVoiceNotes) + if (widget.allowVoiceNotes && !kIsWeb) IconButton( icon: Icon(Icons.mic, size: 24, color: zetaColors.iconSubtle), tooltip: ComponentStrings.of(context).get(