Merge branch 'develop' into develop-fileMessagesWithText
This commit is contained in:
@@ -1,11 +1,11 @@
|
||||
import 'dart:io';
|
||||
|
||||
import 'package:better_open_file/better_open_file.dart';
|
||||
import 'package:filesize/filesize.dart';
|
||||
import 'package:flowder/flowder.dart';
|
||||
import 'package:flutter/foundation.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:jiffy/jiffy.dart';
|
||||
import 'package:open_filex/open_filex.dart';
|
||||
import '../../../widget/infoDialog.dart';
|
||||
import 'package:nextcloud/nextcloud.dart';
|
||||
import 'package:path_provider/path_provider.dart';
|
||||
|
@@ -3,26 +3,28 @@ import 'package:flutter/material.dart';
|
||||
import '../../../../../api/marianumcloud/talk/getParticipants/getParticipantsResponse.dart';
|
||||
import '../../../../../widget/userAvatar.dart';
|
||||
|
||||
class ParticipantsListView extends StatefulWidget {
|
||||
class ParticipantsListView extends StatelessWidget {
|
||||
final GetParticipantsResponse participantsResponse;
|
||||
const ParticipantsListView(this.participantsResponse, {super.key});
|
||||
|
||||
@override
|
||||
State<ParticipantsListView> createState() => _ParticipantsListViewState();
|
||||
}
|
||||
Widget build(BuildContext context) {
|
||||
final participants = participantsResponse.data.map((participant) => ListTile(
|
||||
leading: UserAvatar(id: participant.actorId),
|
||||
title: Text(participant.displayName),
|
||||
subtitle: participant.statusMessage != null ? Text(participant.statusMessage!) : null,
|
||||
)).toList();
|
||||
|
||||
class _ParticipantsListViewState extends State<ParticipantsListView> {
|
||||
@override
|
||||
Widget build(BuildContext context) => Scaffold(
|
||||
lastname(participant) => participant.title.toString().split(' ').last;
|
||||
participants.sort((a, b) => lastname(a).compareTo(lastname(b)));
|
||||
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
title: const Text('Teilnehmende'),
|
||||
),
|
||||
body: ListView(
|
||||
children: widget.participantsResponse.data.map((participant) => ListTile(
|
||||
leading: UserAvatar(id: participant.actorId),
|
||||
title: Text(participant.displayName),
|
||||
subtitle: participant.statusMessage != null ? Text(participant.statusMessage!) : null,
|
||||
)).toList(),
|
||||
children: participants,
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
@@ -1,4 +1,3 @@
|
||||
import 'package:better_open_file/better_open_file.dart';
|
||||
import 'package:bubble/bubble.dart';
|
||||
import 'package:emoji_picker_flutter/emoji_picker_flutter.dart' as emojis;
|
||||
import 'package:flowder/flowder.dart';
|
||||
@@ -6,6 +5,7 @@ import 'package:flutter/foundation.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:jiffy/jiffy.dart';
|
||||
import 'package:open_filex/open_filex.dart';
|
||||
import '../../../../extensions/text.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
|
||||
|
Reference in New Issue
Block a user