feat: Implement message management features including sending, deleting, updating, and reacting to messages
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_bloc/flutter_bloc.dart';
|
||||
import 'package:travel_mate/components/error/error_content.dart';
|
||||
import 'package:travel_mate/components/group/chat_group_content.dart';
|
||||
import '../../blocs/user/user_bloc.dart';
|
||||
import '../../blocs/user/user_state.dart' as user_state;
|
||||
import '../../blocs/group/group_bloc.dart';
|
||||
@@ -167,7 +168,6 @@ class _GroupContentState extends State<GroupContent> {
|
||||
),
|
||||
const SizedBox(height: 24),
|
||||
|
||||
// IMPORTANT: Utiliser un simple Column au lieu de GridView pour tester
|
||||
...groups.map((group) {
|
||||
return Padding(
|
||||
padding: const EdgeInsets.only(bottom: 12),
|
||||
@@ -289,24 +289,13 @@ class _GroupContentState extends State<GroupContent> {
|
||||
|
||||
void _openGroupChat(Group group) {
|
||||
try {
|
||||
// Afficher juste un message, pas de navigation pour l'instant
|
||||
if (mounted) {
|
||||
ScaffoldMessenger.of(context).showSnackBar(
|
||||
SnackBar(
|
||||
content: Text('Chat: ${group.name} (${group.members.length} membres)'),
|
||||
duration: const Duration(seconds: 2),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
// TODO: Navigation vers la page de chat
|
||||
// Navigator.push(
|
||||
// context,
|
||||
// MaterialPageRoute(
|
||||
// builder: (context) => GroupChatPage(group: group),
|
||||
// ),
|
||||
// );
|
||||
|
||||
// Navigation vers la page de chat
|
||||
Navigator.push(
|
||||
context,
|
||||
MaterialPageRoute(
|
||||
builder: (context) => ChatGroupContent(group: group),
|
||||
),
|
||||
);
|
||||
} catch (e) {
|
||||
_buildErrorState(e.toString(), '', false);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user