223 lines
6.4 KiB
Dart
223 lines
6.4 KiB
Dart
// GENERATED CODE - DO NOT MODIFY BY HAND
|
|
|
|
// **************************************************************************
|
|
// StackedNavigatorGenerator
|
|
// **************************************************************************
|
|
|
|
// ignore_for_file: no_leading_underscores_for_library_prefixes
|
|
import 'package:flutter/material.dart' as _i4;
|
|
import 'package:flutter/material.dart';
|
|
import 'package:stacked/stacked.dart' as _i1;
|
|
import 'package:stacked_services/stacked_services.dart' as _i7;
|
|
import 'package:traffic_light/ui/views/splash_screen/splash_screen_view.dart'
|
|
as _i2;
|
|
import 'package:traffic_light/ui/views/the_index/profil/profil_view.dart'
|
|
as _i6;
|
|
import 'package:traffic_light/ui/views/the_index/status_lampu/status_lampu_view.dart'
|
|
as _i5;
|
|
import 'package:traffic_light/ui/views/the_index/the_index_view.dart' as _i3;
|
|
|
|
class Routes {
|
|
static const splashScreenView = '/';
|
|
|
|
static const theIndexView = '/the-index-view';
|
|
|
|
static const all = <String>{
|
|
splashScreenView,
|
|
theIndexView,
|
|
};
|
|
}
|
|
|
|
class StackedRouter extends _i1.RouterBase {
|
|
final _routes = <_i1.RouteDef>[
|
|
_i1.RouteDef(
|
|
Routes.splashScreenView,
|
|
page: _i2.SplashScreenView,
|
|
),
|
|
_i1.RouteDef(
|
|
Routes.theIndexView,
|
|
page: _i3.TheIndexView,
|
|
),
|
|
];
|
|
|
|
final _pagesMap = <Type, _i1.StackedRouteFactory>{
|
|
_i2.SplashScreenView: (data) {
|
|
return _i4.MaterialPageRoute<dynamic>(
|
|
builder: (context) => const _i2.SplashScreenView(),
|
|
settings: data,
|
|
);
|
|
},
|
|
_i3.TheIndexView: (data) {
|
|
return _i4.MaterialPageRoute<dynamic>(
|
|
builder: (context) => const _i3.TheIndexView(),
|
|
settings: data,
|
|
);
|
|
},
|
|
};
|
|
|
|
@override
|
|
List<_i1.RouteDef> get routes => _routes;
|
|
|
|
@override
|
|
Map<Type, _i1.StackedRouteFactory> get pagesMap => _pagesMap;
|
|
}
|
|
|
|
class TheIndexViewRoutes {
|
|
static const statusLampuView = 'status-lampu-view';
|
|
|
|
static const profilView = 'profil-view';
|
|
|
|
static const all = <String>{
|
|
statusLampuView,
|
|
profilView,
|
|
};
|
|
}
|
|
|
|
class TheIndexViewRouter extends _i1.RouterBase {
|
|
final _routes = <_i1.RouteDef>[
|
|
_i1.RouteDef(
|
|
TheIndexViewRoutes.statusLampuView,
|
|
page: _i5.StatusLampuView,
|
|
),
|
|
_i1.RouteDef(
|
|
TheIndexViewRoutes.profilView,
|
|
page: _i6.ProfilView,
|
|
),
|
|
];
|
|
|
|
final _pagesMap = <Type, _i1.StackedRouteFactory>{
|
|
_i5.StatusLampuView: (data) {
|
|
return _i4.MaterialPageRoute<dynamic>(
|
|
builder: (context) => const _i5.StatusLampuView(),
|
|
settings: data,
|
|
);
|
|
},
|
|
_i6.ProfilView: (data) {
|
|
return _i4.MaterialPageRoute<dynamic>(
|
|
builder: (context) => const _i6.ProfilView(),
|
|
settings: data,
|
|
);
|
|
},
|
|
};
|
|
|
|
@override
|
|
List<_i1.RouteDef> get routes => _routes;
|
|
|
|
@override
|
|
Map<Type, _i1.StackedRouteFactory> get pagesMap => _pagesMap;
|
|
}
|
|
|
|
extension NavigatorStateExtension on _i7.NavigationService {
|
|
Future<dynamic> navigateToSplashScreenView([
|
|
int? routerId,
|
|
bool preventDuplicates = true,
|
|
Map<String, String>? parameters,
|
|
Widget Function(BuildContext, Animation<double>, Animation<double>, Widget)?
|
|
transition,
|
|
]) async {
|
|
return navigateTo<dynamic>(Routes.splashScreenView,
|
|
id: routerId,
|
|
preventDuplicates: preventDuplicates,
|
|
parameters: parameters,
|
|
transition: transition);
|
|
}
|
|
|
|
Future<dynamic> navigateToTheIndexView([
|
|
int? routerId,
|
|
bool preventDuplicates = true,
|
|
Map<String, String>? parameters,
|
|
Widget Function(BuildContext, Animation<double>, Animation<double>, Widget)?
|
|
transition,
|
|
]) async {
|
|
return navigateTo<dynamic>(Routes.theIndexView,
|
|
id: routerId,
|
|
preventDuplicates: preventDuplicates,
|
|
parameters: parameters,
|
|
transition: transition);
|
|
}
|
|
|
|
Future<dynamic> navigateToNestedStatusLampuViewInTheIndexViewRouter([
|
|
int? routerId,
|
|
bool preventDuplicates = true,
|
|
Map<String, String>? parameters,
|
|
Widget Function(BuildContext, Animation<double>, Animation<double>, Widget)?
|
|
transition,
|
|
]) async {
|
|
return navigateTo<dynamic>(TheIndexViewRoutes.statusLampuView,
|
|
id: routerId,
|
|
preventDuplicates: preventDuplicates,
|
|
parameters: parameters,
|
|
transition: transition);
|
|
}
|
|
|
|
Future<dynamic> navigateToNestedProfilViewInTheIndexViewRouter([
|
|
int? routerId,
|
|
bool preventDuplicates = true,
|
|
Map<String, String>? parameters,
|
|
Widget Function(BuildContext, Animation<double>, Animation<double>, Widget)?
|
|
transition,
|
|
]) async {
|
|
return navigateTo<dynamic>(TheIndexViewRoutes.profilView,
|
|
id: routerId,
|
|
preventDuplicates: preventDuplicates,
|
|
parameters: parameters,
|
|
transition: transition);
|
|
}
|
|
|
|
Future<dynamic> replaceWithSplashScreenView([
|
|
int? routerId,
|
|
bool preventDuplicates = true,
|
|
Map<String, String>? parameters,
|
|
Widget Function(BuildContext, Animation<double>, Animation<double>, Widget)?
|
|
transition,
|
|
]) async {
|
|
return replaceWith<dynamic>(Routes.splashScreenView,
|
|
id: routerId,
|
|
preventDuplicates: preventDuplicates,
|
|
parameters: parameters,
|
|
transition: transition);
|
|
}
|
|
|
|
Future<dynamic> replaceWithTheIndexView([
|
|
int? routerId,
|
|
bool preventDuplicates = true,
|
|
Map<String, String>? parameters,
|
|
Widget Function(BuildContext, Animation<double>, Animation<double>, Widget)?
|
|
transition,
|
|
]) async {
|
|
return replaceWith<dynamic>(Routes.theIndexView,
|
|
id: routerId,
|
|
preventDuplicates: preventDuplicates,
|
|
parameters: parameters,
|
|
transition: transition);
|
|
}
|
|
|
|
Future<dynamic> replaceWithNestedStatusLampuViewInTheIndexViewRouter([
|
|
int? routerId,
|
|
bool preventDuplicates = true,
|
|
Map<String, String>? parameters,
|
|
Widget Function(BuildContext, Animation<double>, Animation<double>, Widget)?
|
|
transition,
|
|
]) async {
|
|
return replaceWith<dynamic>(TheIndexViewRoutes.statusLampuView,
|
|
id: routerId,
|
|
preventDuplicates: preventDuplicates,
|
|
parameters: parameters,
|
|
transition: transition);
|
|
}
|
|
|
|
Future<dynamic> replaceWithNestedProfilViewInTheIndexViewRouter([
|
|
int? routerId,
|
|
bool preventDuplicates = true,
|
|
Map<String, String>? parameters,
|
|
Widget Function(BuildContext, Animation<double>, Animation<double>, Widget)?
|
|
transition,
|
|
]) async {
|
|
return replaceWith<dynamic>(TheIndexViewRoutes.profilView,
|
|
id: routerId,
|
|
preventDuplicates: preventDuplicates,
|
|
parameters: parameters,
|
|
transition: transition);
|
|
}
|
|
}
|