feat: notification page

This commit is contained in:
efrilm 2025-08-29 16:33:12 +07:00
parent 4dc56662c8
commit dcf76b5fed
4 changed files with 432 additions and 137 deletions

View File

@ -4,6 +4,7 @@ import 'package:carousel_slider/carousel_slider.dart';
import '../../../../../common/theme/theme.dart'; import '../../../../../common/theme/theme.dart';
import '../../../../components/image/image.dart'; import '../../../../components/image/image.dart';
import '../../../../router/app_router.gr.dart';
import 'widgets/feature_section.dart'; import 'widgets/feature_section.dart';
import 'widgets/lottery_card.dart'; import 'widgets/lottery_card.dart';
import 'widgets/point_card.dart'; import 'widgets/point_card.dart';
@ -70,6 +71,8 @@ class _HomePageState extends State<HomePage> {
return Positioned( return Positioned(
top: MediaQuery.of(context).padding.top + 10, top: MediaQuery.of(context).padding.top + 10,
right: 16, right: 16,
child: GestureDetector(
onTap: () => context.router.push(NotificationRoute()),
child: Stack( child: Stack(
children: [ children: [
Container( Container(
@ -99,6 +102,7 @@ class _HomePageState extends State<HomePage> {
), ),
], ],
), ),
),
); );
} }

View File

@ -0,0 +1,270 @@
import 'package:auto_route/auto_route.dart';
import 'package:flutter/material.dart';
import '../../../../../common/theme/theme.dart';
@RoutePage()
class NotificationPage extends StatelessWidget {
const NotificationPage({super.key});
@override
Widget build(BuildContext context) {
return Scaffold(
backgroundColor: AppColor.background,
appBar: AppBar(
title: Text(
'Notifikasi',
style: AppStyle.xl.copyWith(
fontWeight: FontWeight.w600,
color: AppColor.textPrimary,
),
),
backgroundColor: AppColor.backgroundLight,
elevation: 0,
iconTheme: IconThemeData(color: AppColor.textPrimary),
actions: [
TextButton(
onPressed: () => _markAllAsRead(context),
child: Text(
'Tandai Semua',
style: AppStyle.sm.copyWith(
color: AppColor.primary,
fontWeight: FontWeight.w600,
),
),
),
],
bottom: PreferredSize(
preferredSize: Size.fromHeight(1),
child: Container(height: 1, color: AppColor.borderLight),
),
),
body: ListView(
padding: EdgeInsets.symmetric(vertical: 8),
children: [
// Today Section
_buildSectionHeader('Hari Ini'),
_buildNotificationItem(
icon: Icons.local_offer,
iconColor: AppColor.primary,
iconBgColor: AppColor.primaryWithOpacity(0.1),
title: 'Voucher Baru Tersedia!',
subtitle: 'Dapatkan diskon 50% untuk pembelian pertama Anda',
time: '2 menit lalu',
isUnread: true,
),
_buildNotificationItem(
icon: Icons.shopping_bag,
iconColor: AppColor.success,
iconBgColor: AppColor.successWithOpacity(0.1),
title: 'Pesanan Sedang Dikirim',
subtitle: 'Pesanan #ORD-2024-001 sedang dalam perjalanan',
time: '1 jam lalu',
isUnread: true,
),
_buildNotificationItem(
icon: Icons.payment,
iconColor: AppColor.info,
iconBgColor: AppColor.info.withOpacity(0.1),
title: 'Pembayaran Berhasil',
subtitle:
'Pembayaran untuk pesanan #ORD-2024-001 telah dikonfirmasi',
time: '3 jam lalu',
isUnread: false,
),
// Yesterday Section
_buildSectionHeader('Kemarin'),
_buildNotificationItem(
icon: Icons.star,
iconColor: AppColor.warning,
iconBgColor: AppColor.warningWithOpacity(0.1),
title: 'Berikan Rating Produk',
subtitle: 'Bagaimana pengalaman Anda dengan produk yang dibeli?',
time: '1 hari lalu',
isUnread: false,
),
_buildNotificationItem(
icon: Icons.local_shipping,
iconColor: AppColor.success,
iconBgColor: AppColor.successWithOpacity(0.1),
title: 'Pesanan Telah Diterima',
subtitle: 'Pesanan #ORD-2024-002 telah sampai di tujuan',
time: '1 hari lalu',
isUnread: false,
),
// This Week Section
_buildSectionHeader('Minggu Ini'),
_buildNotificationItem(
icon: Icons.campaign,
iconColor: AppColor.primary,
iconBgColor: AppColor.primaryWithOpacity(0.1),
title: 'Flash Sale 12.12!',
subtitle: 'Jangan lewatkan flash sale dengan diskon hingga 70%',
time: '3 hari lalu',
isUnread: false,
),
_buildNotificationItem(
icon: Icons.card_giftcard,
iconColor: AppColor.secondary,
iconBgColor: AppColor.secondary.withOpacity(0.1),
title: 'Poin Reward Ditambahkan',
subtitle: 'Selamat! Anda mendapat 100 poin dari transaksi terakhir',
time: '5 hari lalu',
isUnread: false,
),
_buildNotificationItem(
icon: Icons.security,
iconColor: AppColor.textSecondary,
iconBgColor: AppColor.textSecondary.withOpacity(0.1),
title: 'Keamanan Akun',
subtitle: 'Login dari perangkat baru terdeteksi',
time: '6 hari lalu',
isUnread: false,
),
SizedBox(height: 16),
],
),
);
}
Widget _buildSectionHeader(String title) {
return Padding(
padding: EdgeInsets.fromLTRB(16, 16, 16, 8),
child: Text(
title,
style: AppStyle.md.copyWith(
fontWeight: FontWeight.w600,
color: AppColor.textSecondary,
),
),
);
}
Widget _buildNotificationItem({
required IconData icon,
required Color iconColor,
required Color iconBgColor,
required String title,
required String subtitle,
required String time,
required bool isUnread,
}) {
return Container(
margin: EdgeInsets.symmetric(horizontal: 16, vertical: 4),
padding: EdgeInsets.all(16),
decoration: BoxDecoration(
color: isUnread
? AppColor.primary.withOpacity(0.02)
: AppColor.backgroundLight,
borderRadius: BorderRadius.circular(12),
border: Border.all(
color: isUnread
? AppColor.primary.withOpacity(0.1)
: AppColor.borderLight,
),
),
child: InkWell(
onTap: () => _handleNotificationTap(title),
borderRadius: BorderRadius.circular(12),
child: Row(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
// Icon Container
Container(
width: 48,
height: 48,
decoration: BoxDecoration(
color: iconBgColor,
borderRadius: BorderRadius.circular(12),
),
child: Icon(icon, color: iconColor, size: 24),
),
SizedBox(width: 12),
// Content
Expanded(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Row(
children: [
Expanded(
child: Text(
title,
style: AppStyle.md.copyWith(
fontWeight: FontWeight.w600,
color: AppColor.textPrimary,
),
),
),
if (isUnread)
Container(
width: 8,
height: 8,
decoration: BoxDecoration(
color: AppColor.primary,
shape: BoxShape.circle,
),
),
],
),
SizedBox(height: 4),
Text(
subtitle,
style: AppStyle.sm.copyWith(
color: AppColor.textSecondary,
height: 1.4,
),
maxLines: 2,
overflow: TextOverflow.ellipsis,
),
SizedBox(height: 8),
Text(
time,
style: AppStyle.xs.copyWith(color: AppColor.textLight),
),
],
),
),
// Options Menu
IconButton(
onPressed: () => _showNotificationOptions(title),
icon: Icon(Icons.more_vert, color: AppColor.textLight, size: 20),
constraints: BoxConstraints(),
padding: EdgeInsets.all(4),
),
],
),
),
);
}
void _markAllAsRead(BuildContext context) {
ScaffoldMessenger.of(context).showSnackBar(
SnackBar(
content: Text(
'Semua notifikasi ditandai sebagai dibaca',
style: AppStyle.md.copyWith(color: AppColor.white),
),
backgroundColor: AppColor.success,
behavior: SnackBarBehavior.floating,
margin: EdgeInsets.all(16),
shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(12)),
),
);
}
void _handleNotificationTap(String title) {
// Handle notification tap - navigate to relevant page
print('Notification tapped: $title');
}
void _showNotificationOptions(String title) {
// Show bottom sheet or popup menu for notification options
print('Show options for: $title');
}
}

View File

@ -44,5 +44,8 @@ class AppRouter extends RootStackRouter {
// Voucher // Voucher
AutoRoute(page: VoucherDetailRoute.page), AutoRoute(page: VoucherDetailRoute.page),
// Notification
AutoRoute(page: NotificationRoute.page),
]; ];
} }

View File

@ -9,16 +9,16 @@
// coverage:ignore-file // coverage:ignore-file
// ignore_for_file: no_leading_underscores_for_library_prefixes // ignore_for_file: no_leading_underscores_for_library_prefixes
import 'package:auto_route/auto_route.dart' as _i21; import 'package:auto_route/auto_route.dart' as _i22;
import 'package:enaklo/presentation/pages/auth/create_password/create_password_page.dart' import 'package:enaklo/presentation/pages/auth/create_password/create_password_page.dart'
as _i1; as _i1;
import 'package:enaklo/presentation/pages/auth/login/login_page.dart' as _i5; import 'package:enaklo/presentation/pages/auth/login/login_page.dart' as _i5;
import 'package:enaklo/presentation/pages/auth/otp/otp_page.dart' as _i11; import 'package:enaklo/presentation/pages/auth/otp/otp_page.dart' as _i12;
import 'package:enaklo/presentation/pages/auth/password/password_page.dart' import 'package:enaklo/presentation/pages/auth/password/password_page.dart'
as _i12; as _i13;
import 'package:enaklo/presentation/pages/auth/pin/pin_page.dart' as _i13; import 'package:enaklo/presentation/pages/auth/pin/pin_page.dart' as _i14;
import 'package:enaklo/presentation/pages/auth/register/register_page.dart' import 'package:enaklo/presentation/pages/auth/register/register_page.dart'
as _i16; as _i17;
import 'package:enaklo/presentation/pages/draw/draw_page.dart' as _i3; import 'package:enaklo/presentation/pages/draw/draw_page.dart' as _i3;
import 'package:enaklo/presentation/pages/draw/pages/draw_detail/draw_detail_page.dart' import 'package:enaklo/presentation/pages/draw/pages/draw_detail/draw_detail_page.dart'
as _i2; as _i2;
@ -26,33 +26,35 @@ import 'package:enaklo/presentation/pages/main/main_page.dart' as _i6;
import 'package:enaklo/presentation/pages/main/pages/home/home_page.dart' import 'package:enaklo/presentation/pages/main/pages/home/home_page.dart'
as _i4; as _i4;
import 'package:enaklo/presentation/pages/main/pages/order/order_page.dart' import 'package:enaklo/presentation/pages/main/pages/order/order_page.dart'
as _i10; as _i11;
import 'package:enaklo/presentation/pages/main/pages/profile/profile_page.dart' import 'package:enaklo/presentation/pages/main/pages/profile/profile_page.dart'
as _i15; as _i16;
import 'package:enaklo/presentation/pages/main/pages/voucher/voucher_page.dart' import 'package:enaklo/presentation/pages/main/pages/voucher/voucher_page.dart'
as _i20; as _i21;
import 'package:enaklo/presentation/pages/merchant/merchant_page.dart' as _i8; import 'package:enaklo/presentation/pages/merchant/merchant_page.dart' as _i8;
import 'package:enaklo/presentation/pages/merchant/pages/merchant_detail/merchant_detail_page.dart' import 'package:enaklo/presentation/pages/merchant/pages/merchant_detail/merchant_detail_page.dart'
as _i7; as _i7;
import 'package:enaklo/presentation/pages/onboarding/onboarding_page.dart' import 'package:enaklo/presentation/pages/notification/notification_page.dart'
as _i9; as _i9;
import 'package:enaklo/presentation/pages/onboarding/onboarding_page.dart'
as _i10;
import 'package:enaklo/presentation/pages/reward/pages/product_redeem/product_redeem_page.dart' import 'package:enaklo/presentation/pages/reward/pages/product_redeem/product_redeem_page.dart'
as _i14; as _i15;
import 'package:enaklo/presentation/pages/reward/reward_page.dart' as _i17; import 'package:enaklo/presentation/pages/reward/reward_page.dart' as _i18;
import 'package:enaklo/presentation/pages/splash/splash_page.dart' as _i18; import 'package:enaklo/presentation/pages/splash/splash_page.dart' as _i19;
import 'package:enaklo/presentation/pages/voucher/voucher_detail/voucher_detail_page.dart' import 'package:enaklo/presentation/pages/voucher/voucher_detail/voucher_detail_page.dart'
as _i19; as _i20;
import 'package:flutter/material.dart' as _i22; import 'package:flutter/material.dart' as _i23;
/// generated route for /// generated route for
/// [_i1.CreatePasswordPage] /// [_i1.CreatePasswordPage]
class CreatePasswordRoute extends _i21.PageRouteInfo<void> { class CreatePasswordRoute extends _i22.PageRouteInfo<void> {
const CreatePasswordRoute({List<_i21.PageRouteInfo>? children}) const CreatePasswordRoute({List<_i22.PageRouteInfo>? children})
: super(CreatePasswordRoute.name, initialChildren: children); : super(CreatePasswordRoute.name, initialChildren: children);
static const String name = 'CreatePasswordRoute'; static const String name = 'CreatePasswordRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
return const _i1.CreatePasswordPage(); return const _i1.CreatePasswordPage();
@ -62,11 +64,11 @@ class CreatePasswordRoute extends _i21.PageRouteInfo<void> {
/// generated route for /// generated route for
/// [_i2.DrawDetailPage] /// [_i2.DrawDetailPage]
class DrawDetailRoute extends _i21.PageRouteInfo<DrawDetailRouteArgs> { class DrawDetailRoute extends _i22.PageRouteInfo<DrawDetailRouteArgs> {
DrawDetailRoute({ DrawDetailRoute({
_i22.Key? key, _i23.Key? key,
required _i3.DrawEvent drawEvent, required _i3.DrawEvent drawEvent,
List<_i21.PageRouteInfo>? children, List<_i22.PageRouteInfo>? children,
}) : super( }) : super(
DrawDetailRoute.name, DrawDetailRoute.name,
args: DrawDetailRouteArgs(key: key, drawEvent: drawEvent), args: DrawDetailRouteArgs(key: key, drawEvent: drawEvent),
@ -75,7 +77,7 @@ class DrawDetailRoute extends _i21.PageRouteInfo<DrawDetailRouteArgs> {
static const String name = 'DrawDetailRoute'; static const String name = 'DrawDetailRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
final args = data.argsAs<DrawDetailRouteArgs>(); final args = data.argsAs<DrawDetailRouteArgs>();
@ -87,7 +89,7 @@ class DrawDetailRoute extends _i21.PageRouteInfo<DrawDetailRouteArgs> {
class DrawDetailRouteArgs { class DrawDetailRouteArgs {
const DrawDetailRouteArgs({this.key, required this.drawEvent}); const DrawDetailRouteArgs({this.key, required this.drawEvent});
final _i22.Key? key; final _i23.Key? key;
final _i3.DrawEvent drawEvent; final _i3.DrawEvent drawEvent;
@ -99,13 +101,13 @@ class DrawDetailRouteArgs {
/// generated route for /// generated route for
/// [_i3.DrawPage] /// [_i3.DrawPage]
class DrawRoute extends _i21.PageRouteInfo<void> { class DrawRoute extends _i22.PageRouteInfo<void> {
const DrawRoute({List<_i21.PageRouteInfo>? children}) const DrawRoute({List<_i22.PageRouteInfo>? children})
: super(DrawRoute.name, initialChildren: children); : super(DrawRoute.name, initialChildren: children);
static const String name = 'DrawRoute'; static const String name = 'DrawRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
return const _i3.DrawPage(); return const _i3.DrawPage();
@ -115,13 +117,13 @@ class DrawRoute extends _i21.PageRouteInfo<void> {
/// generated route for /// generated route for
/// [_i4.HomePage] /// [_i4.HomePage]
class HomeRoute extends _i21.PageRouteInfo<void> { class HomeRoute extends _i22.PageRouteInfo<void> {
const HomeRoute({List<_i21.PageRouteInfo>? children}) const HomeRoute({List<_i22.PageRouteInfo>? children})
: super(HomeRoute.name, initialChildren: children); : super(HomeRoute.name, initialChildren: children);
static const String name = 'HomeRoute'; static const String name = 'HomeRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
return const _i4.HomePage(); return const _i4.HomePage();
@ -131,13 +133,13 @@ class HomeRoute extends _i21.PageRouteInfo<void> {
/// generated route for /// generated route for
/// [_i5.LoginPage] /// [_i5.LoginPage]
class LoginRoute extends _i21.PageRouteInfo<void> { class LoginRoute extends _i22.PageRouteInfo<void> {
const LoginRoute({List<_i21.PageRouteInfo>? children}) const LoginRoute({List<_i22.PageRouteInfo>? children})
: super(LoginRoute.name, initialChildren: children); : super(LoginRoute.name, initialChildren: children);
static const String name = 'LoginRoute'; static const String name = 'LoginRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
return const _i5.LoginPage(); return const _i5.LoginPage();
@ -147,13 +149,13 @@ class LoginRoute extends _i21.PageRouteInfo<void> {
/// generated route for /// generated route for
/// [_i6.MainPage] /// [_i6.MainPage]
class MainRoute extends _i21.PageRouteInfo<void> { class MainRoute extends _i22.PageRouteInfo<void> {
const MainRoute({List<_i21.PageRouteInfo>? children}) const MainRoute({List<_i22.PageRouteInfo>? children})
: super(MainRoute.name, initialChildren: children); : super(MainRoute.name, initialChildren: children);
static const String name = 'MainRoute'; static const String name = 'MainRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
return const _i6.MainPage(); return const _i6.MainPage();
@ -163,11 +165,11 @@ class MainRoute extends _i21.PageRouteInfo<void> {
/// generated route for /// generated route for
/// [_i7.MerchantDetailPage] /// [_i7.MerchantDetailPage]
class MerchantDetailRoute extends _i21.PageRouteInfo<MerchantDetailRouteArgs> { class MerchantDetailRoute extends _i22.PageRouteInfo<MerchantDetailRouteArgs> {
MerchantDetailRoute({ MerchantDetailRoute({
_i22.Key? key, _i23.Key? key,
required _i8.MerchantModel merchant, required _i8.MerchantModel merchant,
List<_i21.PageRouteInfo>? children, List<_i22.PageRouteInfo>? children,
}) : super( }) : super(
MerchantDetailRoute.name, MerchantDetailRoute.name,
args: MerchantDetailRouteArgs(key: key, merchant: merchant), args: MerchantDetailRouteArgs(key: key, merchant: merchant),
@ -176,7 +178,7 @@ class MerchantDetailRoute extends _i21.PageRouteInfo<MerchantDetailRouteArgs> {
static const String name = 'MerchantDetailRoute'; static const String name = 'MerchantDetailRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
final args = data.argsAs<MerchantDetailRouteArgs>(); final args = data.argsAs<MerchantDetailRouteArgs>();
@ -188,7 +190,7 @@ class MerchantDetailRoute extends _i21.PageRouteInfo<MerchantDetailRouteArgs> {
class MerchantDetailRouteArgs { class MerchantDetailRouteArgs {
const MerchantDetailRouteArgs({this.key, required this.merchant}); const MerchantDetailRouteArgs({this.key, required this.merchant});
final _i22.Key? key; final _i23.Key? key;
final _i8.MerchantModel merchant; final _i8.MerchantModel merchant;
@ -200,13 +202,13 @@ class MerchantDetailRouteArgs {
/// generated route for /// generated route for
/// [_i8.MerchantPage] /// [_i8.MerchantPage]
class MerchantRoute extends _i21.PageRouteInfo<void> { class MerchantRoute extends _i22.PageRouteInfo<void> {
const MerchantRoute({List<_i21.PageRouteInfo>? children}) const MerchantRoute({List<_i22.PageRouteInfo>? children})
: super(MerchantRoute.name, initialChildren: children); : super(MerchantRoute.name, initialChildren: children);
static const String name = 'MerchantRoute'; static const String name = 'MerchantRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
return const _i8.MerchantPage(); return const _i8.MerchantPage();
@ -215,77 +217,93 @@ class MerchantRoute extends _i21.PageRouteInfo<void> {
} }
/// generated route for /// generated route for
/// [_i9.OnboardingPage] /// [_i9.NotificationPage]
class OnboardingRoute extends _i21.PageRouteInfo<void> { class NotificationRoute extends _i22.PageRouteInfo<void> {
const OnboardingRoute({List<_i21.PageRouteInfo>? children}) const NotificationRoute({List<_i22.PageRouteInfo>? children})
: super(NotificationRoute.name, initialChildren: children);
static const String name = 'NotificationRoute';
static _i22.PageInfo page = _i22.PageInfo(
name,
builder: (data) {
return const _i9.NotificationPage();
},
);
}
/// generated route for
/// [_i10.OnboardingPage]
class OnboardingRoute extends _i22.PageRouteInfo<void> {
const OnboardingRoute({List<_i22.PageRouteInfo>? children})
: super(OnboardingRoute.name, initialChildren: children); : super(OnboardingRoute.name, initialChildren: children);
static const String name = 'OnboardingRoute'; static const String name = 'OnboardingRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
return const _i9.OnboardingPage(); return const _i10.OnboardingPage();
}, },
); );
} }
/// generated route for /// generated route for
/// [_i10.OrderPage] /// [_i11.OrderPage]
class OrderRoute extends _i21.PageRouteInfo<void> { class OrderRoute extends _i22.PageRouteInfo<void> {
const OrderRoute({List<_i21.PageRouteInfo>? children}) const OrderRoute({List<_i22.PageRouteInfo>? children})
: super(OrderRoute.name, initialChildren: children); : super(OrderRoute.name, initialChildren: children);
static const String name = 'OrderRoute'; static const String name = 'OrderRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
return const _i10.OrderPage(); return const _i11.OrderPage();
}, },
); );
} }
/// generated route for /// generated route for
/// [_i11.OtpPage] /// [_i12.OtpPage]
class OtpRoute extends _i21.PageRouteInfo<void> { class OtpRoute extends _i22.PageRouteInfo<void> {
const OtpRoute({List<_i21.PageRouteInfo>? children}) const OtpRoute({List<_i22.PageRouteInfo>? children})
: super(OtpRoute.name, initialChildren: children); : super(OtpRoute.name, initialChildren: children);
static const String name = 'OtpRoute'; static const String name = 'OtpRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
return const _i11.OtpPage(); return const _i12.OtpPage();
}, },
); );
} }
/// generated route for /// generated route for
/// [_i12.PasswordPage] /// [_i13.PasswordPage]
class PasswordRoute extends _i21.PageRouteInfo<void> { class PasswordRoute extends _i22.PageRouteInfo<void> {
const PasswordRoute({List<_i21.PageRouteInfo>? children}) const PasswordRoute({List<_i22.PageRouteInfo>? children})
: super(PasswordRoute.name, initialChildren: children); : super(PasswordRoute.name, initialChildren: children);
static const String name = 'PasswordRoute'; static const String name = 'PasswordRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
return const _i12.PasswordPage(); return const _i13.PasswordPage();
}, },
); );
} }
/// generated route for /// generated route for
/// [_i13.PinPage] /// [_i14.PinPage]
class PinRoute extends _i21.PageRouteInfo<PinRouteArgs> { class PinRoute extends _i22.PageRouteInfo<PinRouteArgs> {
PinRoute({ PinRoute({
_i22.Key? key, _i23.Key? key,
bool isCreatePin = true, bool isCreatePin = true,
String? title, String? title,
List<_i21.PageRouteInfo>? children, List<_i22.PageRouteInfo>? children,
}) : super( }) : super(
PinRoute.name, PinRoute.name,
args: PinRouteArgs(key: key, isCreatePin: isCreatePin, title: title), args: PinRouteArgs(key: key, isCreatePin: isCreatePin, title: title),
@ -294,13 +312,13 @@ class PinRoute extends _i21.PageRouteInfo<PinRouteArgs> {
static const String name = 'PinRoute'; static const String name = 'PinRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
final args = data.argsAs<PinRouteArgs>( final args = data.argsAs<PinRouteArgs>(
orElse: () => const PinRouteArgs(), orElse: () => const PinRouteArgs(),
); );
return _i13.PinPage( return _i14.PinPage(
key: args.key, key: args.key,
isCreatePin: args.isCreatePin, isCreatePin: args.isCreatePin,
title: args.title, title: args.title,
@ -312,7 +330,7 @@ class PinRoute extends _i21.PageRouteInfo<PinRouteArgs> {
class PinRouteArgs { class PinRouteArgs {
const PinRouteArgs({this.key, this.isCreatePin = true, this.title}); const PinRouteArgs({this.key, this.isCreatePin = true, this.title});
final _i22.Key? key; final _i23.Key? key;
final bool isCreatePin; final bool isCreatePin;
@ -325,14 +343,14 @@ class PinRouteArgs {
} }
/// generated route for /// generated route for
/// [_i14.ProductRedeemPage] /// [_i15.ProductRedeemPage]
class ProductRedeemRoute extends _i21.PageRouteInfo<ProductRedeemRouteArgs> { class ProductRedeemRoute extends _i22.PageRouteInfo<ProductRedeemRouteArgs> {
ProductRedeemRoute({ ProductRedeemRoute({
_i22.Key? key, _i23.Key? key,
required _i17.Product product, required _i18.Product product,
required _i17.Merchant merchant, required _i18.Merchant merchant,
required _i17.PointCard pointCard, required _i18.PointCard pointCard,
List<_i21.PageRouteInfo>? children, List<_i22.PageRouteInfo>? children,
}) : super( }) : super(
ProductRedeemRoute.name, ProductRedeemRoute.name,
args: ProductRedeemRouteArgs( args: ProductRedeemRouteArgs(
@ -346,11 +364,11 @@ class ProductRedeemRoute extends _i21.PageRouteInfo<ProductRedeemRouteArgs> {
static const String name = 'ProductRedeemRoute'; static const String name = 'ProductRedeemRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
final args = data.argsAs<ProductRedeemRouteArgs>(); final args = data.argsAs<ProductRedeemRouteArgs>();
return _i14.ProductRedeemPage( return _i15.ProductRedeemPage(
key: args.key, key: args.key,
product: args.product, product: args.product,
merchant: args.merchant, merchant: args.merchant,
@ -368,13 +386,13 @@ class ProductRedeemRouteArgs {
required this.pointCard, required this.pointCard,
}); });
final _i22.Key? key; final _i23.Key? key;
final _i17.Product product; final _i18.Product product;
final _i17.Merchant merchant; final _i18.Merchant merchant;
final _i17.PointCard pointCard; final _i18.PointCard pointCard;
@override @override
String toString() { String toString() {
@ -383,97 +401,97 @@ class ProductRedeemRouteArgs {
} }
/// generated route for /// generated route for
/// [_i15.ProfilePage] /// [_i16.ProfilePage]
class ProfileRoute extends _i21.PageRouteInfo<void> { class ProfileRoute extends _i22.PageRouteInfo<void> {
const ProfileRoute({List<_i21.PageRouteInfo>? children}) const ProfileRoute({List<_i22.PageRouteInfo>? children})
: super(ProfileRoute.name, initialChildren: children); : super(ProfileRoute.name, initialChildren: children);
static const String name = 'ProfileRoute'; static const String name = 'ProfileRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
return const _i15.ProfilePage(); return const _i16.ProfilePage();
}, },
); );
} }
/// generated route for /// generated route for
/// [_i16.RegisterPage] /// [_i17.RegisterPage]
class RegisterRoute extends _i21.PageRouteInfo<void> { class RegisterRoute extends _i22.PageRouteInfo<void> {
const RegisterRoute({List<_i21.PageRouteInfo>? children}) const RegisterRoute({List<_i22.PageRouteInfo>? children})
: super(RegisterRoute.name, initialChildren: children); : super(RegisterRoute.name, initialChildren: children);
static const String name = 'RegisterRoute'; static const String name = 'RegisterRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
return const _i16.RegisterPage(); return const _i17.RegisterPage();
}, },
); );
} }
/// generated route for /// generated route for
/// [_i17.RewardPage] /// [_i18.RewardPage]
class RewardRoute extends _i21.PageRouteInfo<void> { class RewardRoute extends _i22.PageRouteInfo<void> {
const RewardRoute({List<_i21.PageRouteInfo>? children}) const RewardRoute({List<_i22.PageRouteInfo>? children})
: super(RewardRoute.name, initialChildren: children); : super(RewardRoute.name, initialChildren: children);
static const String name = 'RewardRoute'; static const String name = 'RewardRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
return const _i17.RewardPage(); return const _i18.RewardPage();
}, },
); );
} }
/// generated route for /// generated route for
/// [_i18.SplashPage] /// [_i19.SplashPage]
class SplashRoute extends _i21.PageRouteInfo<void> { class SplashRoute extends _i22.PageRouteInfo<void> {
const SplashRoute({List<_i21.PageRouteInfo>? children}) const SplashRoute({List<_i22.PageRouteInfo>? children})
: super(SplashRoute.name, initialChildren: children); : super(SplashRoute.name, initialChildren: children);
static const String name = 'SplashRoute'; static const String name = 'SplashRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
return const _i18.SplashPage(); return const _i19.SplashPage();
}, },
); );
} }
/// generated route for /// generated route for
/// [_i19.VoucherDetailPage] /// [_i20.VoucherDetailPage]
class VoucherDetailRoute extends _i21.PageRouteInfo<void> { class VoucherDetailRoute extends _i22.PageRouteInfo<void> {
const VoucherDetailRoute({List<_i21.PageRouteInfo>? children}) const VoucherDetailRoute({List<_i22.PageRouteInfo>? children})
: super(VoucherDetailRoute.name, initialChildren: children); : super(VoucherDetailRoute.name, initialChildren: children);
static const String name = 'VoucherDetailRoute'; static const String name = 'VoucherDetailRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
return const _i19.VoucherDetailPage(); return const _i20.VoucherDetailPage();
}, },
); );
} }
/// generated route for /// generated route for
/// [_i20.VoucherPage] /// [_i21.VoucherPage]
class VoucherRoute extends _i21.PageRouteInfo<void> { class VoucherRoute extends _i22.PageRouteInfo<void> {
const VoucherRoute({List<_i21.PageRouteInfo>? children}) const VoucherRoute({List<_i22.PageRouteInfo>? children})
: super(VoucherRoute.name, initialChildren: children); : super(VoucherRoute.name, initialChildren: children);
static const String name = 'VoucherRoute'; static const String name = 'VoucherRoute';
static _i21.PageInfo page = _i21.PageInfo( static _i22.PageInfo page = _i22.PageInfo(
name, name,
builder: (data) { builder: (data) {
return const _i20.VoucherPage(); return const _i21.VoucherPage();
}, },
); );
} }