chore: Follow up search
This commit is contained in:
parent
e40e24e97d
commit
b20b599ce4
5 changed files with 32 additions and 25 deletions
|
|
@ -5,6 +5,7 @@ import 'package:intl/intl.dart';
|
|||
import 'package:matrix/matrix.dart';
|
||||
|
||||
import 'package:fluffychat/pages/chat/events/image_bubble.dart';
|
||||
import 'package:fluffychat/pages/chat/events/video_player.dart';
|
||||
import 'package:fluffychat/utils/matrix_sdk_extensions/matrix_locals.dart';
|
||||
|
||||
class ChatSearchImagesTab extends StatelessWidget {
|
||||
|
|
@ -146,14 +147,17 @@ class ChatSearchImagesTab extends StatelessWidget {
|
|||
crossAxisSpacing: padding,
|
||||
padding: const EdgeInsets.all(padding),
|
||||
crossAxisCount: 3,
|
||||
children: monthEvents
|
||||
.map(
|
||||
(event) => ImageBubble(
|
||||
event,
|
||||
fit: BoxFit.cover,
|
||||
),
|
||||
)
|
||||
.toList(),
|
||||
children: monthEvents.map(
|
||||
(event) {
|
||||
if (event.messageType == MessageTypes.Video) {
|
||||
return EventVideoPlayer(event);
|
||||
}
|
||||
return ImageBubble(
|
||||
event,
|
||||
fit: BoxFit.cover,
|
||||
);
|
||||
},
|
||||
).toList(),
|
||||
),
|
||||
],
|
||||
);
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ class ChatSearchView extends StatelessWidget {
|
|||
controller: controller.tabController,
|
||||
tabs: [
|
||||
Tab(child: Text(L10n.of(context)!.messages)),
|
||||
Tab(child: Text(L10n.of(context)!.photos)),
|
||||
Tab(child: Text(L10n.of(context)!.gallery)),
|
||||
Tab(child: Text(L10n.of(context)!.files)),
|
||||
],
|
||||
),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue