Skip to content

Commit 751e3c5

Browse files
committed
refactor(router): update imports and repository references
- Update import paths for auth repository and related packages - Replace HtAuthRepository with AuthRepository in router and authentication bloc - Update package paths to reflect new project structure
1 parent 68b8a08 commit 751e3c5

File tree

1 file changed

+22
-21
lines changed

1 file changed

+22
-21
lines changed

lib/router/router.dart

Lines changed: 22 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,34 @@
1+
import 'package:auth_repository/auth_repository.dart';
12
import 'package:flutter/material.dart';
23
import 'package:flutter_bloc/flutter_bloc.dart';
4+
import 'package:flutter_news_app_web_dashboard_full_source_code/app/bloc/app_bloc.dart';
5+
import 'package:flutter_news_app_web_dashboard_full_source_code/app/config/config.dart'
6+
as local_config;
7+
import 'package:flutter_news_app_web_dashboard_full_source_code/app/view/app_shell.dart';
8+
import 'package:flutter_news_app_web_dashboard_full_source_code/app_configuration/view/app_configuration_page.dart';
9+
import 'package:flutter_news_app_web_dashboard_full_source_code/authentication/bloc/authentication_bloc.dart';
10+
import 'package:flutter_news_app_web_dashboard_full_source_code/authentication/view/authentication_page.dart';
11+
import 'package:flutter_news_app_web_dashboard_full_source_code/authentication/view/email_code_verification_page.dart';
12+
import 'package:flutter_news_app_web_dashboard_full_source_code/authentication/view/request_code_page.dart';
13+
import 'package:flutter_news_app_web_dashboard_full_source_code/content_management/view/content_management_page.dart';
14+
import 'package:flutter_news_app_web_dashboard_full_source_code/content_management/view/create_headline_page.dart';
15+
import 'package:flutter_news_app_web_dashboard_full_source_code/content_management/view/create_source_page.dart';
16+
import 'package:flutter_news_app_web_dashboard_full_source_code/content_management/view/create_topic_page.dart';
17+
import 'package:flutter_news_app_web_dashboard_full_source_code/content_management/view/edit_headline_page.dart';
18+
import 'package:flutter_news_app_web_dashboard_full_source_code/content_management/view/edit_source_page.dart';
19+
import 'package:flutter_news_app_web_dashboard_full_source_code/content_management/view/edit_topic_page.dart';
20+
import 'package:flutter_news_app_web_dashboard_full_source_code/dashboard/view/dashboard_page.dart';
21+
import 'package:flutter_news_app_web_dashboard_full_source_code/router/routes.dart';
22+
import 'package:flutter_news_app_web_dashboard_full_source_code/settings/view/settings_page.dart';
323
import 'package:go_router/go_router.dart';
4-
import 'package:ht_auth_repository/ht_auth_repository.dart';
5-
import 'package:ht_dashboard/app/bloc/app_bloc.dart';
6-
import 'package:ht_dashboard/app/config/config.dart' as local_config;
7-
import 'package:ht_dashboard/app/view/app_shell.dart';
8-
import 'package:ht_dashboard/app_configuration/view/app_configuration_page.dart';
9-
import 'package:ht_dashboard/authentication/bloc/authentication_bloc.dart';
10-
import 'package:ht_dashboard/authentication/view/authentication_page.dart';
11-
import 'package:ht_dashboard/authentication/view/email_code_verification_page.dart';
12-
import 'package:ht_dashboard/authentication/view/request_code_page.dart';
13-
import 'package:ht_dashboard/content_management/view/content_management_page.dart';
14-
import 'package:ht_dashboard/content_management/view/create_headline_page.dart';
15-
import 'package:ht_dashboard/content_management/view/create_source_page.dart';
16-
import 'package:ht_dashboard/content_management/view/create_topic_page.dart';
17-
import 'package:ht_dashboard/content_management/view/edit_headline_page.dart';
18-
import 'package:ht_dashboard/content_management/view/edit_source_page.dart';
19-
import 'package:ht_dashboard/content_management/view/edit_topic_page.dart';
20-
import 'package:ht_dashboard/dashboard/view/dashboard_page.dart';
21-
import 'package:ht_dashboard/router/routes.dart';
22-
import 'package:ht_dashboard/settings/view/settings_page.dart';
2324

2425
/// Creates and configures the GoRouter instance for the application.
2526
///
2627
/// Requires an [authStatusNotifier] to trigger route re-evaluation when
2728
/// authentication state changes.
2829
GoRouter createRouter({
2930
required ValueNotifier<AppStatus> authStatusNotifier,
30-
required HtAuthRepository htAuthenticationRepository,
31+
required AuthRepository authenticationRepository,
3132
required local_config.AppEnvironment environment,
3233
}) {
3334
return GoRouter(
@@ -99,7 +100,7 @@ GoRouter createRouter({
99100
builder: (BuildContext context, GoRouterState state) {
100101
return BlocProvider(
101102
create: (context) => AuthenticationBloc(
102-
authenticationRepository: context.read<HtAuthRepository>(),
103+
authenticationRepository: context.read<AuthRepository>(),
103104
),
104105
child: const AuthenticationPage(),
105106
);

0 commit comments

Comments
 (0)