feat: pin page
This commit is contained in:
@@ -15,5 +15,6 @@ class AppRouter extends RootStackRouter {
|
||||
AutoRoute(page: LoginRoute.page),
|
||||
AutoRoute(page: RegisterRoute.page),
|
||||
AutoRoute(page: OtpRoute.page),
|
||||
AutoRoute(page: PinRoute.page),
|
||||
];
|
||||
}
|
||||
|
||||
@@ -9,24 +9,26 @@
|
||||
// coverage:ignore-file
|
||||
|
||||
// ignore_for_file: no_leading_underscores_for_library_prefixes
|
||||
import 'package:auto_route/auto_route.dart' as _i6;
|
||||
import 'package:auto_route/auto_route.dart' as _i7;
|
||||
import 'package:enaklo/presentation/pages/auth/login/login_page.dart' as _i1;
|
||||
import 'package:enaklo/presentation/pages/auth/otp/otp_page.dart' as _i3;
|
||||
import 'package:enaklo/presentation/pages/auth/pin/pin_page.dart' as _i4;
|
||||
import 'package:enaklo/presentation/pages/auth/register/register_page.dart'
|
||||
as _i4;
|
||||
as _i5;
|
||||
import 'package:enaklo/presentation/pages/onboarding/onboarding_page.dart'
|
||||
as _i2;
|
||||
import 'package:enaklo/presentation/pages/splash/splash_page.dart' as _i5;
|
||||
import 'package:enaklo/presentation/pages/splash/splash_page.dart' as _i6;
|
||||
import 'package:flutter/material.dart' as _i8;
|
||||
|
||||
/// generated route for
|
||||
/// [_i1.LoginPage]
|
||||
class LoginRoute extends _i6.PageRouteInfo<void> {
|
||||
const LoginRoute({List<_i6.PageRouteInfo>? children})
|
||||
class LoginRoute extends _i7.PageRouteInfo<void> {
|
||||
const LoginRoute({List<_i7.PageRouteInfo>? children})
|
||||
: super(LoginRoute.name, initialChildren: children);
|
||||
|
||||
static const String name = 'LoginRoute';
|
||||
|
||||
static _i6.PageInfo page = _i6.PageInfo(
|
||||
static _i7.PageInfo page = _i7.PageInfo(
|
||||
name,
|
||||
builder: (data) {
|
||||
return const _i1.LoginPage();
|
||||
@@ -36,13 +38,13 @@ class LoginRoute extends _i6.PageRouteInfo<void> {
|
||||
|
||||
/// generated route for
|
||||
/// [_i2.OnboardingPage]
|
||||
class OnboardingRoute extends _i6.PageRouteInfo<void> {
|
||||
const OnboardingRoute({List<_i6.PageRouteInfo>? children})
|
||||
class OnboardingRoute extends _i7.PageRouteInfo<void> {
|
||||
const OnboardingRoute({List<_i7.PageRouteInfo>? children})
|
||||
: super(OnboardingRoute.name, initialChildren: children);
|
||||
|
||||
static const String name = 'OnboardingRoute';
|
||||
|
||||
static _i6.PageInfo page = _i6.PageInfo(
|
||||
static _i7.PageInfo page = _i7.PageInfo(
|
||||
name,
|
||||
builder: (data) {
|
||||
return const _i2.OnboardingPage();
|
||||
@@ -52,13 +54,13 @@ class OnboardingRoute extends _i6.PageRouteInfo<void> {
|
||||
|
||||
/// generated route for
|
||||
/// [_i3.OtpPage]
|
||||
class OtpRoute extends _i6.PageRouteInfo<void> {
|
||||
const OtpRoute({List<_i6.PageRouteInfo>? children})
|
||||
class OtpRoute extends _i7.PageRouteInfo<void> {
|
||||
const OtpRoute({List<_i7.PageRouteInfo>? children})
|
||||
: super(OtpRoute.name, initialChildren: children);
|
||||
|
||||
static const String name = 'OtpRoute';
|
||||
|
||||
static _i6.PageInfo page = _i6.PageInfo(
|
||||
static _i7.PageInfo page = _i7.PageInfo(
|
||||
name,
|
||||
builder: (data) {
|
||||
return const _i3.OtpPage();
|
||||
@@ -67,33 +69,79 @@ class OtpRoute extends _i6.PageRouteInfo<void> {
|
||||
}
|
||||
|
||||
/// generated route for
|
||||
/// [_i4.RegisterPage]
|
||||
class RegisterRoute extends _i6.PageRouteInfo<void> {
|
||||
const RegisterRoute({List<_i6.PageRouteInfo>? children})
|
||||
/// [_i4.PinPage]
|
||||
class PinRoute extends _i7.PageRouteInfo<PinRouteArgs> {
|
||||
PinRoute({
|
||||
_i8.Key? key,
|
||||
bool isCreatePin = true,
|
||||
String? title,
|
||||
List<_i7.PageRouteInfo>? children,
|
||||
}) : super(
|
||||
PinRoute.name,
|
||||
args: PinRouteArgs(key: key, isCreatePin: isCreatePin, title: title),
|
||||
initialChildren: children,
|
||||
);
|
||||
|
||||
static const String name = 'PinRoute';
|
||||
|
||||
static _i7.PageInfo page = _i7.PageInfo(
|
||||
name,
|
||||
builder: (data) {
|
||||
final args = data.argsAs<PinRouteArgs>(
|
||||
orElse: () => const PinRouteArgs(),
|
||||
);
|
||||
return _i4.PinPage(
|
||||
key: args.key,
|
||||
isCreatePin: args.isCreatePin,
|
||||
title: args.title,
|
||||
);
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
class PinRouteArgs {
|
||||
const PinRouteArgs({this.key, this.isCreatePin = true, this.title});
|
||||
|
||||
final _i8.Key? key;
|
||||
|
||||
final bool isCreatePin;
|
||||
|
||||
final String? title;
|
||||
|
||||
@override
|
||||
String toString() {
|
||||
return 'PinRouteArgs{key: $key, isCreatePin: $isCreatePin, title: $title}';
|
||||
}
|
||||
}
|
||||
|
||||
/// generated route for
|
||||
/// [_i5.RegisterPage]
|
||||
class RegisterRoute extends _i7.PageRouteInfo<void> {
|
||||
const RegisterRoute({List<_i7.PageRouteInfo>? children})
|
||||
: super(RegisterRoute.name, initialChildren: children);
|
||||
|
||||
static const String name = 'RegisterRoute';
|
||||
|
||||
static _i6.PageInfo page = _i6.PageInfo(
|
||||
static _i7.PageInfo page = _i7.PageInfo(
|
||||
name,
|
||||
builder: (data) {
|
||||
return const _i4.RegisterPage();
|
||||
return const _i5.RegisterPage();
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
/// generated route for
|
||||
/// [_i5.SplashPage]
|
||||
class SplashRoute extends _i6.PageRouteInfo<void> {
|
||||
const SplashRoute({List<_i6.PageRouteInfo>? children})
|
||||
/// [_i6.SplashPage]
|
||||
class SplashRoute extends _i7.PageRouteInfo<void> {
|
||||
const SplashRoute({List<_i7.PageRouteInfo>? children})
|
||||
: super(SplashRoute.name, initialChildren: children);
|
||||
|
||||
static const String name = 'SplashRoute';
|
||||
|
||||
static _i6.PageInfo page = _i6.PageInfo(
|
||||
static _i7.PageInfo page = _i7.PageInfo(
|
||||
name,
|
||||
builder: (data) {
|
||||
return const _i5.SplashPage();
|
||||
return const _i6.SplashPage();
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user