feat(ui): Show errors
This commit is contained in:
1 parent
04c0c1c0e2
commit
0eeac949ea
5 files changed
+75
-1
No files matched your search
@@ -4,7 +4,7 @@ import 'package:flutter/material.dart';
|
||||
import 'package:flutter_bloc/flutter_bloc.dart';
|
||||
import 'package:flutter_vibrate/flutter_vibrate.dart';
|
||||
import 'package:moxxyv2/i18n/strings.g.dart';
|
||||
//import 'package:moxxyv2/shared/error_types.dart';
|
||||
import 'package:moxxyv2/shared/error_types.dart';
|
||||
import 'package:moxxyv2/shared/helpers.dart';
|
||||
import 'package:moxxyv2/shared/models/message.dart';
|
||||
import 'package:moxxyv2/shared/warning_types.dart';
|
||||
@@ -323,6 +323,19 @@ class ChatBubbleState extends State<ChatBubble>
|
||||
},
|
||||
),
|
||||
] : [],
|
||||
...widget.message.errorMenuVisible ? [
|
||||
_buildMessageOption(
|
||||
Icons.info_outline,
|
||||
'Show Error',
|
||||
() {
|
||||
showInfoDialog(
|
||||
'Error',
|
||||
errorToTranslatableString(widget.message.errorType!),
|
||||
context,
|
||||
);
|
||||
},
|
||||
),
|
||||
] : [],
|
||||
...widget.message.isWarning() ? [
|
||||
_buildMessageOption(
|
||||
Icons.warning,
|
||||
|
||||
Reference in new issue
Block a user