auth_page_router.dart 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. import 'package:auto_route/auto_route.dart';
  2. import 'package:flutter/material.dart';
  3. import 'package:router/ext/auto_router_extensions.dart';
  4. import 'package:router/path/router_path.dart';
  5. import '../../modules/auth_login/auth_login_page.dart';
  6. import '../../modules/forgot_input/forgot_input_page.dart';
  7. import '../../modules/forgot_verify/forgot_verify_page.dart';
  8. import '../../modules/sign_up/sign_up_page.dart';
  9. import '../../modules/sing_up_verify/sign_up_verify_page.dart';
  10. import '../../modules/sing_up_success/sign_up_success_page.dart';
  11. import '../../modules/select_estate/select_estate_page.dart';
  12. import '../../modules/select_unit/select_unit_page.dart';
  13. import '../../modules/select_role/select_role_page.dart';
  14. import '../../modules/tenant_doc/tenant_doc_page.dart';
  15. part 'auth_page_router.gr.dart';
  16. /*\
  17. * 全局的通用页面的路由
  18. */
  19. @AutoRouterConfig(replaceInRouteName: 'Page|Screen,PageRoute')
  20. class AuthPageRouter extends _$AuthPageRouter {
  21. @override
  22. List<AutoRoute> get routes => [
  23. CustomRoute(page: AuthLoginPageRoute.page, path: RouterPath.authLogin, transitionsBuilder: applySlideTransition),
  24. CustomRoute(page: ForgotInputPageRoute.page, path: RouterPath.authForgotInput, transitionsBuilder: applySlideTransition),
  25. CustomRoute(page: ForgotVerifyPageRoute.page, path: RouterPath.authForgotVerify, transitionsBuilder: applySlideTransition),
  26. CustomRoute(page: SignUpPageRoute.page, path: RouterPath.authSignUp, transitionsBuilder: applySlideTransition),
  27. CustomRoute(page: SignUpVerifyPageRoute.page, path: RouterPath.authSignUpVerify, transitionsBuilder: applySlideTransition),
  28. CustomRoute(page: SignUpSuccessPageRoute.page, path: RouterPath.authSignUpSuccess, transitionsBuilder: applySlideTransition),
  29. CustomRoute(page: SelectEstatePageRoute.page, path: RouterPath.authSelectEstate, transitionsBuilder: applySlideTransition),
  30. CustomRoute(page: SelectUnitPageRoute.page, path: RouterPath.authSelectUnit, transitionsBuilder: applySlideTransition),
  31. CustomRoute(page: SelectRolePageRoute.page, path: RouterPath.authSelectRole, transitionsBuilder: applySlideTransition),
  32. CustomRoute(page: TenantDocPageRoute.page, path: RouterPath.authTenantDoc, transitionsBuilder: applySlideTransition),
  33. ];
  34. }