feat(notifications): added json parsing for notifications and tested impplementation of notifications layoute

This commit is contained in:
Username1548
2025-05-21 21:45:22 +07:00
parent c1e2b1c312
commit 272637078a
8 changed files with 203 additions and 116 deletions

View File

@@ -1,3 +1,4 @@
import 'package:eatvio_app/core/theme/theme_helper.dart';
import 'package:eatvio_app/features/notifications/models/notification_model.dart';
import 'package:flutter/material.dart';
@@ -6,9 +7,15 @@ class NotificationWidget extends StatelessWidget {
final BaseNotificationModel notification;
@override
Widget build(BuildContext context) {
// return (notification.type) {
// NotificationType.userSubscribedNotification => const _UserSubscribedNotification(),
// };
return Container();
return Container(
width: MediaQuery.sizeOf(context).width,
height: 60,
margin: const EdgeInsets.symmetric(horizontal: 16, vertical: 12),
decoration: BoxDecoration(
color: appTheme.green,
borderRadius: BorderRadius.circular(18),
),
child: Center(child: Text(notification.type.name)),
);
}
}