From f46701e56169d45e5d5b371e521aa3cf548cc2f8 Mon Sep 17 00:00:00 2001 From: jideguru Date: Fri, 4 Aug 2023 12:11:25 +0100 Subject: [PATCH] rfact: more refactoring ofcourse --- lib/main.dart | 6 ++---- lib/src/features/book_details/book_details.dart | 2 +- lib/src/features/book_details/data/data.dart | 1 - .../data/repositories/book_details_repository.dart | 4 +--- .../notifier/book_details_notifier.dart | 0 .../notifier/book_details_notifier.g.dart | 0 .../{data => presentation}/notifier/notifiers.dart | 0 .../book_details/presentation/presentation.dart | 2 ++ .../ui}/screens/book_details_screen.dart | 0 .../{ => presentation/ui}/screens/screens.dart | 0 .../features/book_details/presentation/ui/ui.dart | 1 + .../features/common/application/application.dart | 1 + .../services/current_app_theme_service.dart | 4 +--- .../{data => application}/services/services.dart | 0 lib/src/features/common/common.dart | 5 +++-- lib/src/features/common/data/data.dart | 6 ++---- .../common/data/data_sources/data_sources.dart | 4 ++++ .../downloads/downloads_local_data_source_impl.dart | 3 +-- .../favorites/favorites_local_data_source.dart | 2 +- .../favorites/favorites_local_data_source_impl.dart | 4 +--- .../common/{ => data}/database/database.dart | 0 .../common/{ => data}/database/database_config.dart | 0 .../data/repositories/book/book_repository.dart | 3 +-- .../favorites/favorites_repository.dart | 4 +--- lib/src/features/common/domain/domain.dart | 1 + .../{data => domain}/models/category_feed.dart | 0 lib/src/features/common/domain/models/models.dart | 1 + .../current_app_theme_notifier.dart | 13 ++++++++++--- .../current_app_theme_notifier.g.dart | 0 .../notifiers/downloads/downloads_notifier.dart | 0 .../notifiers/downloads/downloads_notifier.g.dart | 0 .../notifiers/favorites/favorites_notifier.dart | 0 .../notifiers/favorites/favorites_notifier.g.dart | 0 .../{data => presentation}/notifiers/notifiers.dart | 0 .../features/common/presentation/presentation.dart | 3 +++ .../providers/database_provider.dart | 2 +- .../providers/dio_provider.dart | 0 .../{data => presentation}/providers/providers.dart | 0 .../providers/shared_preferences_provider.dart | 0 lib/src/features/common/presentation/ui/ui.dart | 1 + .../{ => presentation/ui}/widgets/book_card.dart | 0 .../{ => presentation/ui}/widgets/book_item.dart | 0 .../ui}/widgets/book_list_item.dart | 0 .../ui}/widgets/description_text.dart | 0 .../{ => presentation/ui}/widgets/empty_view.dart | 0 .../{ => presentation/ui}/widgets/error_widget.dart | 0 .../ui}/widgets/loading_widget.dart | 0 .../ui}/widgets/modal_dialogs/custom_alert.dart | 0 .../ui}/widgets/modal_dialogs/download_alert.dart | 0 .../widgets/modal_dialogs/exit_modal_dialog.dart | 0 .../ui}/widgets/modal_dialogs/modal_dialogs.dart | 0 .../ui}/widgets/responsive_widget.dart | 0 .../{ => presentation/ui}/widgets/widgets.dart | 0 lib/src/features/downloads/downloads.dart | 2 +- .../downloads/presentation/presentation.dart | 1 + .../ui}/screens/download_screen.dart | 0 .../{ => presentation/ui}/screens/screens.dart | 0 lib/src/features/downloads/presentation/ui/ui.dart | 1 + lib/src/features/explore/data/data.dart | 1 - .../data/repositories/explore_repository.dart | 4 +--- lib/src/features/explore/explore.dart | 2 +- .../notifiers/genre_feed/genre_feed_notifier.dart | 0 .../notifiers/genre_feed/genre_feed_notifier.g.dart | 0 .../{data => presentation}/notifiers/notifiers.dart | 0 .../presentation/presentation.dart} | 1 + .../ui}/screens/explore_screen.dart | 0 .../ui}/screens/explore_screen_large.dart | 0 .../ui}/screens/explore_screen_small.dart | 0 .../{ => presentation/ui}/screens/genre_screen.dart | 0 .../{ => presentation/ui}/screens/screens.dart | 0 lib/src/features/explore/presentation/ui/ui.dart | 1 + lib/src/features/favorites/favourites.dart | 2 +- .../favorites/presentation/presentation.dart | 1 + .../ui}/screens/favorites_screen.dart | 0 .../{ => presentation/ui}/screens/screens.dart | 0 lib/src/features/favorites/presentation/ui/ui.dart | 1 + lib/src/features/home/data/data.dart | 1 - .../home/data/repositories/home_repository.dart | 4 +--- lib/src/features/home/home.dart | 2 +- .../notifiers/home_feed_notifier.dart | 8 +++----- .../notifiers/home_feed_notifier.g.dart | 0 .../{data => presentation}/notifiers/notifiers.dart | 0 .../features/home/presentation/presentation.dart | 2 ++ .../{ => presentation/ui}/screens/home_screen.dart | 0 .../ui}/screens/home_screen_large.dart | 0 .../ui}/screens/home_screen_small.dart | 0 .../home/{ => presentation/ui}/screens/screens.dart | 0 lib/src/features/home/presentation/ui/ui.dart | 1 + .../settings/presentation/presentation.dart | 1 + .../ui}/screens/licenses_screen.dart | 0 .../{ => presentation/ui}/screens/screens.dart | 0 .../ui}/screens/settings_screen.dart | 0 .../ui}/screens/settings_screen_large.dart | 0 .../ui}/screens/settings_screen_small.dart | 0 lib/src/features/settings/presentation/ui/ui.dart | 1 + lib/src/features/settings/settings.dart | 2 +- .../features/splash/presentation/presentation.dart | 1 + .../{ => presentation/ui}/screens/screens.dart | 0 .../ui}/screens/splash_screen.dart | 0 lib/src/features/splash/presentation/ui/ui.dart | 1 + lib/src/features/splash/splash.dart | 2 +- .../notifiers/current_tab_notifier.dart | 0 .../{data => presentation}/notifiers/notifiers.dart | 0 .../features/tabs/presentation/presentation.dart | 2 ++ .../tabs/{ => presentation/ui}/screens/screens.dart | 0 .../{ => presentation/ui}/screens/tabs_screen.dart | 0 .../ui}/screens/tabs_screen_large.dart | 0 .../ui}/screens/tabs_screen_small.dart | 0 lib/src/features/tabs/presentation/ui/ui.dart | 1 + lib/src/features/tabs/tabs.dart | 3 +-- 110 files changed, 68 insertions(+), 54 deletions(-) rename lib/src/features/book_details/{data => presentation}/notifier/book_details_notifier.dart (100%) rename lib/src/features/book_details/{data => presentation}/notifier/book_details_notifier.g.dart (100%) rename lib/src/features/book_details/{data => presentation}/notifier/notifiers.dart (100%) create mode 100644 lib/src/features/book_details/presentation/presentation.dart rename lib/src/features/book_details/{ => presentation/ui}/screens/book_details_screen.dart (100%) rename lib/src/features/book_details/{ => presentation/ui}/screens/screens.dart (100%) create mode 100644 lib/src/features/book_details/presentation/ui/ui.dart create mode 100644 lib/src/features/common/application/application.dart rename lib/src/features/common/{data => application}/services/current_app_theme_service.dart (75%) rename lib/src/features/common/{data => application}/services/services.dart (100%) create mode 100644 lib/src/features/common/data/data_sources/data_sources.dart rename lib/src/features/common/{ => data}/database/database.dart (100%) rename lib/src/features/common/{ => data}/database/database_config.dart (100%) create mode 100644 lib/src/features/common/domain/domain.dart rename lib/src/features/common/{data => domain}/models/category_feed.dart (100%) create mode 100644 lib/src/features/common/domain/models/models.dart rename lib/src/features/common/{data => presentation}/notifiers/current_app_theme/current_app_theme_notifier.dart (71%) rename lib/src/features/common/{data => presentation}/notifiers/current_app_theme/current_app_theme_notifier.g.dart (100%) rename lib/src/features/common/{data => presentation}/notifiers/downloads/downloads_notifier.dart (100%) rename lib/src/features/common/{data => presentation}/notifiers/downloads/downloads_notifier.g.dart (100%) rename lib/src/features/common/{data => presentation}/notifiers/favorites/favorites_notifier.dart (100%) rename lib/src/features/common/{data => presentation}/notifiers/favorites/favorites_notifier.g.dart (100%) rename lib/src/features/common/{data => presentation}/notifiers/notifiers.dart (100%) create mode 100644 lib/src/features/common/presentation/presentation.dart rename lib/src/features/common/{data => presentation}/providers/database_provider.dart (86%) rename lib/src/features/common/{data => presentation}/providers/dio_provider.dart (100%) rename lib/src/features/common/{data => presentation}/providers/providers.dart (100%) rename lib/src/features/common/{data => presentation}/providers/shared_preferences_provider.dart (100%) create mode 100644 lib/src/features/common/presentation/ui/ui.dart rename lib/src/features/common/{ => presentation/ui}/widgets/book_card.dart (100%) rename lib/src/features/common/{ => presentation/ui}/widgets/book_item.dart (100%) rename lib/src/features/common/{ => presentation/ui}/widgets/book_list_item.dart (100%) rename lib/src/features/common/{ => presentation/ui}/widgets/description_text.dart (100%) rename lib/src/features/common/{ => presentation/ui}/widgets/empty_view.dart (100%) rename lib/src/features/common/{ => presentation/ui}/widgets/error_widget.dart (100%) rename lib/src/features/common/{ => presentation/ui}/widgets/loading_widget.dart (100%) rename lib/src/features/common/{ => presentation/ui}/widgets/modal_dialogs/custom_alert.dart (100%) rename lib/src/features/common/{ => presentation/ui}/widgets/modal_dialogs/download_alert.dart (100%) rename lib/src/features/common/{ => presentation/ui}/widgets/modal_dialogs/exit_modal_dialog.dart (100%) rename lib/src/features/common/{ => presentation/ui}/widgets/modal_dialogs/modal_dialogs.dart (100%) rename lib/src/features/common/{ => presentation/ui}/widgets/responsive_widget.dart (100%) rename lib/src/features/common/{ => presentation/ui}/widgets/widgets.dart (100%) create mode 100644 lib/src/features/downloads/presentation/presentation.dart rename lib/src/features/downloads/{ => presentation/ui}/screens/download_screen.dart (100%) rename lib/src/features/downloads/{ => presentation/ui}/screens/screens.dart (100%) create mode 100644 lib/src/features/downloads/presentation/ui/ui.dart rename lib/src/features/explore/{data => presentation}/notifiers/genre_feed/genre_feed_notifier.dart (100%) rename lib/src/features/explore/{data => presentation}/notifiers/genre_feed/genre_feed_notifier.g.dart (100%) rename lib/src/features/explore/{data => presentation}/notifiers/notifiers.dart (100%) rename lib/src/features/{tabs/data/data.dart => explore/presentation/presentation.dart} (62%) rename lib/src/features/explore/{ => presentation/ui}/screens/explore_screen.dart (100%) rename lib/src/features/explore/{ => presentation/ui}/screens/explore_screen_large.dart (100%) rename lib/src/features/explore/{ => presentation/ui}/screens/explore_screen_small.dart (100%) rename lib/src/features/explore/{ => presentation/ui}/screens/genre_screen.dart (100%) rename lib/src/features/explore/{ => presentation/ui}/screens/screens.dart (100%) create mode 100644 lib/src/features/explore/presentation/ui/ui.dart create mode 100644 lib/src/features/favorites/presentation/presentation.dart rename lib/src/features/favorites/{ => presentation/ui}/screens/favorites_screen.dart (100%) rename lib/src/features/favorites/{ => presentation/ui}/screens/screens.dart (100%) create mode 100644 lib/src/features/favorites/presentation/ui/ui.dart rename lib/src/features/home/{data => presentation}/notifiers/home_feed_notifier.dart (78%) rename lib/src/features/home/{data => presentation}/notifiers/home_feed_notifier.g.dart (100%) rename lib/src/features/home/{data => presentation}/notifiers/notifiers.dart (100%) create mode 100644 lib/src/features/home/presentation/presentation.dart rename lib/src/features/home/{ => presentation/ui}/screens/home_screen.dart (100%) rename lib/src/features/home/{ => presentation/ui}/screens/home_screen_large.dart (100%) rename lib/src/features/home/{ => presentation/ui}/screens/home_screen_small.dart (100%) rename lib/src/features/home/{ => presentation/ui}/screens/screens.dart (100%) create mode 100644 lib/src/features/home/presentation/ui/ui.dart create mode 100644 lib/src/features/settings/presentation/presentation.dart rename lib/src/features/settings/{ => presentation/ui}/screens/licenses_screen.dart (100%) rename lib/src/features/settings/{ => presentation/ui}/screens/screens.dart (100%) rename lib/src/features/settings/{ => presentation/ui}/screens/settings_screen.dart (100%) rename lib/src/features/settings/{ => presentation/ui}/screens/settings_screen_large.dart (100%) rename lib/src/features/settings/{ => presentation/ui}/screens/settings_screen_small.dart (100%) create mode 100644 lib/src/features/settings/presentation/ui/ui.dart create mode 100644 lib/src/features/splash/presentation/presentation.dart rename lib/src/features/splash/{ => presentation/ui}/screens/screens.dart (100%) rename lib/src/features/splash/{ => presentation/ui}/screens/splash_screen.dart (100%) create mode 100644 lib/src/features/splash/presentation/ui/ui.dart rename lib/src/features/tabs/{data => presentation}/notifiers/current_tab_notifier.dart (100%) rename lib/src/features/tabs/{data => presentation}/notifiers/notifiers.dart (100%) create mode 100644 lib/src/features/tabs/presentation/presentation.dart rename lib/src/features/tabs/{ => presentation/ui}/screens/screens.dart (100%) rename lib/src/features/tabs/{ => presentation/ui}/screens/tabs_screen.dart (100%) rename lib/src/features/tabs/{ => presentation/ui}/screens/tabs_screen_large.dart (100%) rename lib/src/features/tabs/{ => presentation/ui}/screens/tabs_screen_small.dart (100%) create mode 100644 lib/src/features/tabs/presentation/ui/ui.dart diff --git a/lib/main.dart b/lib/main.dart index c22f7cc..3424536 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -1,8 +1,5 @@ import 'package:flutter/material.dart'; -import 'package:flutter_ebook_app/src/features/common/constants/strings.dart'; -import 'package:flutter_ebook_app/src/features/common/data/local/local_storage.dart'; -import 'package:flutter_ebook_app/src/features/common/data/notifiers/current_app_theme/current_app_theme_notifier.dart'; -import 'package:flutter_ebook_app/src/features/common/database/database_config.dart'; +import 'package:flutter_ebook_app/src/features/features.dart'; import 'package:flutter_ebook_app/src/router/app_router.dart'; import 'package:flutter_ebook_app/src/theme/theme_config.dart'; import 'package:flutter_riverpod/flutter_riverpod.dart'; @@ -33,6 +30,7 @@ class MyApp extends ConsumerWidget { : ThemeConfig.lightTheme, ), darkTheme: themeData(ThemeConfig.darkTheme), + themeMode: currentAppTheme.value?.themeMode, routerConfig: _appRouter.config(), ); } diff --git a/lib/src/features/book_details/book_details.dart b/lib/src/features/book_details/book_details.dart index dd0d792..5a0d8b1 100644 --- a/lib/src/features/book_details/book_details.dart +++ b/lib/src/features/book_details/book_details.dart @@ -1,2 +1,2 @@ export 'data/data.dart'; -export 'screens/screens.dart'; +export 'presentation/presentation.dart'; diff --git a/lib/src/features/book_details/data/data.dart b/lib/src/features/book_details/data/data.dart index 283a3b3..d08598b 100644 --- a/lib/src/features/book_details/data/data.dart +++ b/lib/src/features/book_details/data/data.dart @@ -1,2 +1 @@ -export 'notifier/notifiers.dart'; export 'repositories/repositories.dart'; diff --git a/lib/src/features/book_details/data/repositories/book_details_repository.dart b/lib/src/features/book_details/data/repositories/book_details_repository.dart index 6a979de..4f694e0 100644 --- a/lib/src/features/book_details/data/repositories/book_details_repository.dart +++ b/lib/src/features/book_details/data/repositories/book_details_repository.dart @@ -1,6 +1,4 @@ -import 'package:flutter_ebook_app/src/features/common/constants/api.dart'; -import 'package:flutter_ebook_app/src/features/common/data/providers/dio_provider.dart'; -import 'package:flutter_ebook_app/src/features/common/data/repositories/book/book_repository.dart'; +import 'package:flutter_ebook_app/src/features/features.dart'; import 'package:flutter_riverpod/flutter_riverpod.dart'; class BookDetailsRepository extends BookRepository { diff --git a/lib/src/features/book_details/data/notifier/book_details_notifier.dart b/lib/src/features/book_details/presentation/notifier/book_details_notifier.dart similarity index 100% rename from lib/src/features/book_details/data/notifier/book_details_notifier.dart rename to lib/src/features/book_details/presentation/notifier/book_details_notifier.dart diff --git a/lib/src/features/book_details/data/notifier/book_details_notifier.g.dart b/lib/src/features/book_details/presentation/notifier/book_details_notifier.g.dart similarity index 100% rename from lib/src/features/book_details/data/notifier/book_details_notifier.g.dart rename to lib/src/features/book_details/presentation/notifier/book_details_notifier.g.dart diff --git a/lib/src/features/book_details/data/notifier/notifiers.dart b/lib/src/features/book_details/presentation/notifier/notifiers.dart similarity index 100% rename from lib/src/features/book_details/data/notifier/notifiers.dart rename to lib/src/features/book_details/presentation/notifier/notifiers.dart diff --git a/lib/src/features/book_details/presentation/presentation.dart b/lib/src/features/book_details/presentation/presentation.dart new file mode 100644 index 0000000..c07e723 --- /dev/null +++ b/lib/src/features/book_details/presentation/presentation.dart @@ -0,0 +1,2 @@ +export 'notifier/notifiers.dart'; +export 'ui/ui.dart'; diff --git a/lib/src/features/book_details/screens/book_details_screen.dart b/lib/src/features/book_details/presentation/ui/screens/book_details_screen.dart similarity index 100% rename from lib/src/features/book_details/screens/book_details_screen.dart rename to lib/src/features/book_details/presentation/ui/screens/book_details_screen.dart diff --git a/lib/src/features/book_details/screens/screens.dart b/lib/src/features/book_details/presentation/ui/screens/screens.dart similarity index 100% rename from lib/src/features/book_details/screens/screens.dart rename to lib/src/features/book_details/presentation/ui/screens/screens.dart diff --git a/lib/src/features/book_details/presentation/ui/ui.dart b/lib/src/features/book_details/presentation/ui/ui.dart new file mode 100644 index 0000000..80f5a18 --- /dev/null +++ b/lib/src/features/book_details/presentation/ui/ui.dart @@ -0,0 +1 @@ +export 'screens/screens.dart'; diff --git a/lib/src/features/common/application/application.dart b/lib/src/features/common/application/application.dart new file mode 100644 index 0000000..ce2099f --- /dev/null +++ b/lib/src/features/common/application/application.dart @@ -0,0 +1 @@ +export 'services/services.dart'; diff --git a/lib/src/features/common/data/services/current_app_theme_service.dart b/lib/src/features/common/application/services/current_app_theme_service.dart similarity index 75% rename from lib/src/features/common/data/services/current_app_theme_service.dart rename to lib/src/features/common/application/services/current_app_theme_service.dart index a352d1d..a0211fe 100644 --- a/lib/src/features/common/data/services/current_app_theme_service.dart +++ b/lib/src/features/common/application/services/current_app_theme_service.dart @@ -1,6 +1,4 @@ -import 'package:flutter_ebook_app/src/features/common/constants/shared_preferences_key.dart'; -import 'package:flutter_ebook_app/src/features/common/data/notifiers/current_app_theme/current_app_theme_notifier.dart'; -import 'package:flutter_ebook_app/src/features/common/data/providers/shared_preferences_provider.dart'; +import 'package:flutter_ebook_app/src/features/features.dart'; import 'package:flutter_riverpod/flutter_riverpod.dart'; import 'package:shared_preferences/shared_preferences.dart'; diff --git a/lib/src/features/common/data/services/services.dart b/lib/src/features/common/application/services/services.dart similarity index 100% rename from lib/src/features/common/data/services/services.dart rename to lib/src/features/common/application/services/services.dart diff --git a/lib/src/features/common/common.dart b/lib/src/features/common/common.dart index f2dd0b6..22ff590 100644 --- a/lib/src/features/common/common.dart +++ b/lib/src/features/common/common.dart @@ -1,5 +1,6 @@ +export 'application/application.dart'; export 'constants/constants.dart'; export 'data/data.dart'; -export 'database/database.dart'; +export 'domain/domain.dart'; export 'extensions/extensions.dart'; -export 'widgets/widgets.dart'; +export 'presentation/presentation.dart'; diff --git a/lib/src/features/common/data/data.dart b/lib/src/features/common/data/data.dart index cbbf8f8..7fab431 100644 --- a/lib/src/features/common/data/data.dart +++ b/lib/src/features/common/data/data.dart @@ -1,8 +1,6 @@ +export 'data_sources/data_sources.dart'; +export 'database/database.dart'; export 'failures/http_failure.dart'; export 'local/local_storage.dart'; -export 'models/category_feed.dart'; -export 'notifiers/notifiers.dart'; -export 'providers/providers.dart'; export 'remote/app_dio.dart'; export 'repositories/repositories.dart'; -export 'services/services.dart'; diff --git a/lib/src/features/common/data/data_sources/data_sources.dart b/lib/src/features/common/data/data_sources/data_sources.dart new file mode 100644 index 0000000..c7f9026 --- /dev/null +++ b/lib/src/features/common/data/data_sources/data_sources.dart @@ -0,0 +1,4 @@ +export 'downloads/downloads_local_data_source.dart'; +export 'downloads/downloads_local_data_source_impl.dart'; +export 'favorites/favorites_local_data_source.dart'; +export 'favorites/favorites_local_data_source_impl.dart'; diff --git a/lib/src/features/common/data/data_sources/downloads/downloads_local_data_source_impl.dart b/lib/src/features/common/data/data_sources/downloads/downloads_local_data_source_impl.dart index 7de8954..bfd196c 100644 --- a/lib/src/features/common/data/data_sources/downloads/downloads_local_data_source_impl.dart +++ b/lib/src/features/common/data/data_sources/downloads/downloads_local_data_source_impl.dart @@ -1,5 +1,4 @@ -import 'package:flutter_ebook_app/src/features/common/data/data_sources/downloads/downloads_local_data_source.dart'; -import 'package:flutter_ebook_app/src/features/common/data/providers/database_provider.dart'; +import 'package:flutter_ebook_app/src/features/features.dart'; import 'package:flutter_riverpod/flutter_riverpod.dart'; import 'package:sembast/sembast.dart'; diff --git a/lib/src/features/common/data/data_sources/favorites/favorites_local_data_source.dart b/lib/src/features/common/data/data_sources/favorites/favorites_local_data_source.dart index 8fc492e..f87f89c 100644 --- a/lib/src/features/common/data/data_sources/favorites/favorites_local_data_source.dart +++ b/lib/src/features/common/data/data_sources/favorites/favorites_local_data_source.dart @@ -1,4 +1,4 @@ -import 'package:flutter_ebook_app/src/features/common/data/models/category_feed.dart'; +import 'package:flutter_ebook_app/src/features/features.dart'; abstract class FavoritesLocalDataSource { const FavoritesLocalDataSource(); diff --git a/lib/src/features/common/data/data_sources/favorites/favorites_local_data_source_impl.dart b/lib/src/features/common/data/data_sources/favorites/favorites_local_data_source_impl.dart index 684e1f1..8bf6ef6 100644 --- a/lib/src/features/common/data/data_sources/favorites/favorites_local_data_source_impl.dart +++ b/lib/src/features/common/data/data_sources/favorites/favorites_local_data_source_impl.dart @@ -1,6 +1,4 @@ -import 'package:flutter_ebook_app/src/features/common/data/data_sources/favorites/favorites_local_data_source.dart'; -import 'package:flutter_ebook_app/src/features/common/data/models/category_feed.dart'; -import 'package:flutter_ebook_app/src/features/common/data/providers/database_provider.dart'; +import 'package:flutter_ebook_app/src/features/features.dart'; import 'package:flutter_riverpod/flutter_riverpod.dart'; import 'package:sembast/sembast.dart'; diff --git a/lib/src/features/common/database/database.dart b/lib/src/features/common/data/database/database.dart similarity index 100% rename from lib/src/features/common/database/database.dart rename to lib/src/features/common/data/database/database.dart diff --git a/lib/src/features/common/database/database_config.dart b/lib/src/features/common/data/database/database_config.dart similarity index 100% rename from lib/src/features/common/database/database_config.dart rename to lib/src/features/common/data/database/database_config.dart diff --git a/lib/src/features/common/data/repositories/book/book_repository.dart b/lib/src/features/common/data/repositories/book/book_repository.dart index 3080929..dbb4c36 100644 --- a/lib/src/features/common/data/repositories/book/book_repository.dart +++ b/lib/src/features/common/data/repositories/book/book_repository.dart @@ -1,8 +1,7 @@ import 'dart:convert'; import 'package:dio/dio.dart'; -import 'package:flutter_ebook_app/src/features/common/data/failures/http_failure.dart'; -import 'package:flutter_ebook_app/src/features/common/data/models/category_feed.dart'; +import 'package:flutter_ebook_app/src/features/features.dart'; import 'package:xml2json/xml2json.dart'; typedef BookRepositoryData = ({CategoryFeed? feed, HttpFailure? failure}); diff --git a/lib/src/features/common/data/repositories/favorites/favorites_repository.dart b/lib/src/features/common/data/repositories/favorites/favorites_repository.dart index 854f356..ca9c2d2 100644 --- a/lib/src/features/common/data/repositories/favorites/favorites_repository.dart +++ b/lib/src/features/common/data/repositories/favorites/favorites_repository.dart @@ -1,6 +1,4 @@ -import 'package:flutter_ebook_app/src/features/common/data/data_sources/favorites/favorites_local_data_source.dart'; -import 'package:flutter_ebook_app/src/features/common/data/data_sources/favorites/favorites_local_data_source_impl.dart'; -import 'package:flutter_ebook_app/src/features/common/data/models/category_feed.dart'; +import 'package:flutter_ebook_app/src/features/features.dart'; import 'package:flutter_riverpod/flutter_riverpod.dart'; abstract class FavoritesRepository { diff --git a/lib/src/features/common/domain/domain.dart b/lib/src/features/common/domain/domain.dart new file mode 100644 index 0000000..51b0215 --- /dev/null +++ b/lib/src/features/common/domain/domain.dart @@ -0,0 +1 @@ +export 'models/models.dart'; diff --git a/lib/src/features/common/data/models/category_feed.dart b/lib/src/features/common/domain/models/category_feed.dart similarity index 100% rename from lib/src/features/common/data/models/category_feed.dart rename to lib/src/features/common/domain/models/category_feed.dart diff --git a/lib/src/features/common/domain/models/models.dart b/lib/src/features/common/domain/models/models.dart new file mode 100644 index 0000000..5d2c29c --- /dev/null +++ b/lib/src/features/common/domain/models/models.dart @@ -0,0 +1 @@ +export 'category_feed.dart'; diff --git a/lib/src/features/common/data/notifiers/current_app_theme/current_app_theme_notifier.dart b/lib/src/features/common/presentation/notifiers/current_app_theme/current_app_theme_notifier.dart similarity index 71% rename from lib/src/features/common/data/notifiers/current_app_theme/current_app_theme_notifier.dart rename to lib/src/features/common/presentation/notifiers/current_app_theme/current_app_theme_notifier.dart index 43da206..f967b4f 100644 --- a/lib/src/features/common/data/notifiers/current_app_theme/current_app_theme_notifier.dart +++ b/lib/src/features/common/presentation/notifiers/current_app_theme/current_app_theme_notifier.dart @@ -1,6 +1,7 @@ import 'dart:async'; -import 'package:flutter_ebook_app/src/features/common/data/services/current_app_theme_service.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_ebook_app/src/features/features.dart'; import 'package:riverpod_annotation/riverpod_annotation.dart'; part 'current_app_theme_notifier.g.dart'; @@ -23,10 +24,16 @@ class CurrentAppThemeNotifier extends _$CurrentAppThemeNotifier { } @override - FutureOr build() { + Future build() async { _currentAppThemeService = ref.read(currentAppThemeServiceProvider); return _currentAppThemeService.getCurrentAppTheme(); } } -enum CurrentAppTheme { light, dark } +enum CurrentAppTheme { + light(ThemeMode.light), + dark(ThemeMode.dark); + + final ThemeMode themeMode; + const CurrentAppTheme(this.themeMode); +} diff --git a/lib/src/features/common/data/notifiers/current_app_theme/current_app_theme_notifier.g.dart b/lib/src/features/common/presentation/notifiers/current_app_theme/current_app_theme_notifier.g.dart similarity index 100% rename from lib/src/features/common/data/notifiers/current_app_theme/current_app_theme_notifier.g.dart rename to lib/src/features/common/presentation/notifiers/current_app_theme/current_app_theme_notifier.g.dart diff --git a/lib/src/features/common/data/notifiers/downloads/downloads_notifier.dart b/lib/src/features/common/presentation/notifiers/downloads/downloads_notifier.dart similarity index 100% rename from lib/src/features/common/data/notifiers/downloads/downloads_notifier.dart rename to lib/src/features/common/presentation/notifiers/downloads/downloads_notifier.dart diff --git a/lib/src/features/common/data/notifiers/downloads/downloads_notifier.g.dart b/lib/src/features/common/presentation/notifiers/downloads/downloads_notifier.g.dart similarity index 100% rename from lib/src/features/common/data/notifiers/downloads/downloads_notifier.g.dart rename to lib/src/features/common/presentation/notifiers/downloads/downloads_notifier.g.dart diff --git a/lib/src/features/common/data/notifiers/favorites/favorites_notifier.dart b/lib/src/features/common/presentation/notifiers/favorites/favorites_notifier.dart similarity index 100% rename from lib/src/features/common/data/notifiers/favorites/favorites_notifier.dart rename to lib/src/features/common/presentation/notifiers/favorites/favorites_notifier.dart diff --git a/lib/src/features/common/data/notifiers/favorites/favorites_notifier.g.dart b/lib/src/features/common/presentation/notifiers/favorites/favorites_notifier.g.dart similarity index 100% rename from lib/src/features/common/data/notifiers/favorites/favorites_notifier.g.dart rename to lib/src/features/common/presentation/notifiers/favorites/favorites_notifier.g.dart diff --git a/lib/src/features/common/data/notifiers/notifiers.dart b/lib/src/features/common/presentation/notifiers/notifiers.dart similarity index 100% rename from lib/src/features/common/data/notifiers/notifiers.dart rename to lib/src/features/common/presentation/notifiers/notifiers.dart diff --git a/lib/src/features/common/presentation/presentation.dart b/lib/src/features/common/presentation/presentation.dart new file mode 100644 index 0000000..e91d9eb --- /dev/null +++ b/lib/src/features/common/presentation/presentation.dart @@ -0,0 +1,3 @@ +export 'notifiers/notifiers.dart'; +export 'providers/providers.dart'; +export 'ui/ui.dart'; diff --git a/lib/src/features/common/data/providers/database_provider.dart b/lib/src/features/common/presentation/providers/database_provider.dart similarity index 86% rename from lib/src/features/common/data/providers/database_provider.dart rename to lib/src/features/common/presentation/providers/database_provider.dart index a857438..850b515 100644 --- a/lib/src/features/common/data/providers/database_provider.dart +++ b/lib/src/features/common/presentation/providers/database_provider.dart @@ -1,4 +1,4 @@ -import 'package:flutter_ebook_app/src/features/common/database/database_config.dart'; +import 'package:flutter_ebook_app/src/features/features.dart'; import 'package:flutter_riverpod/flutter_riverpod.dart'; import 'package:sembast/sembast.dart'; diff --git a/lib/src/features/common/data/providers/dio_provider.dart b/lib/src/features/common/presentation/providers/dio_provider.dart similarity index 100% rename from lib/src/features/common/data/providers/dio_provider.dart rename to lib/src/features/common/presentation/providers/dio_provider.dart diff --git a/lib/src/features/common/data/providers/providers.dart b/lib/src/features/common/presentation/providers/providers.dart similarity index 100% rename from lib/src/features/common/data/providers/providers.dart rename to lib/src/features/common/presentation/providers/providers.dart diff --git a/lib/src/features/common/data/providers/shared_preferences_provider.dart b/lib/src/features/common/presentation/providers/shared_preferences_provider.dart similarity index 100% rename from lib/src/features/common/data/providers/shared_preferences_provider.dart rename to lib/src/features/common/presentation/providers/shared_preferences_provider.dart diff --git a/lib/src/features/common/presentation/ui/ui.dart b/lib/src/features/common/presentation/ui/ui.dart new file mode 100644 index 0000000..e691bba --- /dev/null +++ b/lib/src/features/common/presentation/ui/ui.dart @@ -0,0 +1 @@ +export 'widgets/widgets.dart'; diff --git a/lib/src/features/common/widgets/book_card.dart b/lib/src/features/common/presentation/ui/widgets/book_card.dart similarity index 100% rename from lib/src/features/common/widgets/book_card.dart rename to lib/src/features/common/presentation/ui/widgets/book_card.dart diff --git a/lib/src/features/common/widgets/book_item.dart b/lib/src/features/common/presentation/ui/widgets/book_item.dart similarity index 100% rename from lib/src/features/common/widgets/book_item.dart rename to lib/src/features/common/presentation/ui/widgets/book_item.dart diff --git a/lib/src/features/common/widgets/book_list_item.dart b/lib/src/features/common/presentation/ui/widgets/book_list_item.dart similarity index 100% rename from lib/src/features/common/widgets/book_list_item.dart rename to lib/src/features/common/presentation/ui/widgets/book_list_item.dart diff --git a/lib/src/features/common/widgets/description_text.dart b/lib/src/features/common/presentation/ui/widgets/description_text.dart similarity index 100% rename from lib/src/features/common/widgets/description_text.dart rename to lib/src/features/common/presentation/ui/widgets/description_text.dart diff --git a/lib/src/features/common/widgets/empty_view.dart b/lib/src/features/common/presentation/ui/widgets/empty_view.dart similarity index 100% rename from lib/src/features/common/widgets/empty_view.dart rename to lib/src/features/common/presentation/ui/widgets/empty_view.dart diff --git a/lib/src/features/common/widgets/error_widget.dart b/lib/src/features/common/presentation/ui/widgets/error_widget.dart similarity index 100% rename from lib/src/features/common/widgets/error_widget.dart rename to lib/src/features/common/presentation/ui/widgets/error_widget.dart diff --git a/lib/src/features/common/widgets/loading_widget.dart b/lib/src/features/common/presentation/ui/widgets/loading_widget.dart similarity index 100% rename from lib/src/features/common/widgets/loading_widget.dart rename to lib/src/features/common/presentation/ui/widgets/loading_widget.dart diff --git a/lib/src/features/common/widgets/modal_dialogs/custom_alert.dart b/lib/src/features/common/presentation/ui/widgets/modal_dialogs/custom_alert.dart similarity index 100% rename from lib/src/features/common/widgets/modal_dialogs/custom_alert.dart rename to lib/src/features/common/presentation/ui/widgets/modal_dialogs/custom_alert.dart diff --git a/lib/src/features/common/widgets/modal_dialogs/download_alert.dart b/lib/src/features/common/presentation/ui/widgets/modal_dialogs/download_alert.dart similarity index 100% rename from lib/src/features/common/widgets/modal_dialogs/download_alert.dart rename to lib/src/features/common/presentation/ui/widgets/modal_dialogs/download_alert.dart diff --git a/lib/src/features/common/widgets/modal_dialogs/exit_modal_dialog.dart b/lib/src/features/common/presentation/ui/widgets/modal_dialogs/exit_modal_dialog.dart similarity index 100% rename from lib/src/features/common/widgets/modal_dialogs/exit_modal_dialog.dart rename to lib/src/features/common/presentation/ui/widgets/modal_dialogs/exit_modal_dialog.dart diff --git a/lib/src/features/common/widgets/modal_dialogs/modal_dialogs.dart b/lib/src/features/common/presentation/ui/widgets/modal_dialogs/modal_dialogs.dart similarity index 100% rename from lib/src/features/common/widgets/modal_dialogs/modal_dialogs.dart rename to lib/src/features/common/presentation/ui/widgets/modal_dialogs/modal_dialogs.dart diff --git a/lib/src/features/common/widgets/responsive_widget.dart b/lib/src/features/common/presentation/ui/widgets/responsive_widget.dart similarity index 100% rename from lib/src/features/common/widgets/responsive_widget.dart rename to lib/src/features/common/presentation/ui/widgets/responsive_widget.dart diff --git a/lib/src/features/common/widgets/widgets.dart b/lib/src/features/common/presentation/ui/widgets/widgets.dart similarity index 100% rename from lib/src/features/common/widgets/widgets.dart rename to lib/src/features/common/presentation/ui/widgets/widgets.dart diff --git a/lib/src/features/downloads/downloads.dart b/lib/src/features/downloads/downloads.dart index 80f5a18..29b200c 100644 --- a/lib/src/features/downloads/downloads.dart +++ b/lib/src/features/downloads/downloads.dart @@ -1 +1 @@ -export 'screens/screens.dart'; +export 'presentation/presentation.dart'; diff --git a/lib/src/features/downloads/presentation/presentation.dart b/lib/src/features/downloads/presentation/presentation.dart new file mode 100644 index 0000000..2ea3a87 --- /dev/null +++ b/lib/src/features/downloads/presentation/presentation.dart @@ -0,0 +1 @@ +export 'ui/ui.dart'; diff --git a/lib/src/features/downloads/screens/download_screen.dart b/lib/src/features/downloads/presentation/ui/screens/download_screen.dart similarity index 100% rename from lib/src/features/downloads/screens/download_screen.dart rename to lib/src/features/downloads/presentation/ui/screens/download_screen.dart diff --git a/lib/src/features/downloads/screens/screens.dart b/lib/src/features/downloads/presentation/ui/screens/screens.dart similarity index 100% rename from lib/src/features/downloads/screens/screens.dart rename to lib/src/features/downloads/presentation/ui/screens/screens.dart diff --git a/lib/src/features/downloads/presentation/ui/ui.dart b/lib/src/features/downloads/presentation/ui/ui.dart new file mode 100644 index 0000000..80f5a18 --- /dev/null +++ b/lib/src/features/downloads/presentation/ui/ui.dart @@ -0,0 +1 @@ +export 'screens/screens.dart'; diff --git a/lib/src/features/explore/data/data.dart b/lib/src/features/explore/data/data.dart index a67d21b..d08598b 100644 --- a/lib/src/features/explore/data/data.dart +++ b/lib/src/features/explore/data/data.dart @@ -1,2 +1 @@ -export 'notifiers/notifiers.dart'; export 'repositories/repositories.dart'; diff --git a/lib/src/features/explore/data/repositories/explore_repository.dart b/lib/src/features/explore/data/repositories/explore_repository.dart index 344dfb4..c615a2b 100644 --- a/lib/src/features/explore/data/repositories/explore_repository.dart +++ b/lib/src/features/explore/data/repositories/explore_repository.dart @@ -1,6 +1,4 @@ -import 'package:flutter_ebook_app/src/features/common/constants/api.dart'; -import 'package:flutter_ebook_app/src/features/common/data/providers/dio_provider.dart'; -import 'package:flutter_ebook_app/src/features/common/data/repositories/book/book_repository.dart'; +import 'package:flutter_ebook_app/src/features/features.dart'; import 'package:flutter_riverpod/flutter_riverpod.dart'; class ExploreRepository extends BookRepository { diff --git a/lib/src/features/explore/explore.dart b/lib/src/features/explore/explore.dart index dd0d792..5a0d8b1 100644 --- a/lib/src/features/explore/explore.dart +++ b/lib/src/features/explore/explore.dart @@ -1,2 +1,2 @@ export 'data/data.dart'; -export 'screens/screens.dart'; +export 'presentation/presentation.dart'; diff --git a/lib/src/features/explore/data/notifiers/genre_feed/genre_feed_notifier.dart b/lib/src/features/explore/presentation/notifiers/genre_feed/genre_feed_notifier.dart similarity index 100% rename from lib/src/features/explore/data/notifiers/genre_feed/genre_feed_notifier.dart rename to lib/src/features/explore/presentation/notifiers/genre_feed/genre_feed_notifier.dart diff --git a/lib/src/features/explore/data/notifiers/genre_feed/genre_feed_notifier.g.dart b/lib/src/features/explore/presentation/notifiers/genre_feed/genre_feed_notifier.g.dart similarity index 100% rename from lib/src/features/explore/data/notifiers/genre_feed/genre_feed_notifier.g.dart rename to lib/src/features/explore/presentation/notifiers/genre_feed/genre_feed_notifier.g.dart diff --git a/lib/src/features/explore/data/notifiers/notifiers.dart b/lib/src/features/explore/presentation/notifiers/notifiers.dart similarity index 100% rename from lib/src/features/explore/data/notifiers/notifiers.dart rename to lib/src/features/explore/presentation/notifiers/notifiers.dart diff --git a/lib/src/features/tabs/data/data.dart b/lib/src/features/explore/presentation/presentation.dart similarity index 62% rename from lib/src/features/tabs/data/data.dart rename to lib/src/features/explore/presentation/presentation.dart index 2a2a3ee..fcbadf0 100644 --- a/lib/src/features/tabs/data/data.dart +++ b/lib/src/features/explore/presentation/presentation.dart @@ -1 +1,2 @@ export 'notifiers/notifiers.dart'; +export 'ui/ui.dart'; diff --git a/lib/src/features/explore/screens/explore_screen.dart b/lib/src/features/explore/presentation/ui/screens/explore_screen.dart similarity index 100% rename from lib/src/features/explore/screens/explore_screen.dart rename to lib/src/features/explore/presentation/ui/screens/explore_screen.dart diff --git a/lib/src/features/explore/screens/explore_screen_large.dart b/lib/src/features/explore/presentation/ui/screens/explore_screen_large.dart similarity index 100% rename from lib/src/features/explore/screens/explore_screen_large.dart rename to lib/src/features/explore/presentation/ui/screens/explore_screen_large.dart diff --git a/lib/src/features/explore/screens/explore_screen_small.dart b/lib/src/features/explore/presentation/ui/screens/explore_screen_small.dart similarity index 100% rename from lib/src/features/explore/screens/explore_screen_small.dart rename to lib/src/features/explore/presentation/ui/screens/explore_screen_small.dart diff --git a/lib/src/features/explore/screens/genre_screen.dart b/lib/src/features/explore/presentation/ui/screens/genre_screen.dart similarity index 100% rename from lib/src/features/explore/screens/genre_screen.dart rename to lib/src/features/explore/presentation/ui/screens/genre_screen.dart diff --git a/lib/src/features/explore/screens/screens.dart b/lib/src/features/explore/presentation/ui/screens/screens.dart similarity index 100% rename from lib/src/features/explore/screens/screens.dart rename to lib/src/features/explore/presentation/ui/screens/screens.dart diff --git a/lib/src/features/explore/presentation/ui/ui.dart b/lib/src/features/explore/presentation/ui/ui.dart new file mode 100644 index 0000000..80f5a18 --- /dev/null +++ b/lib/src/features/explore/presentation/ui/ui.dart @@ -0,0 +1 @@ +export 'screens/screens.dart'; diff --git a/lib/src/features/favorites/favourites.dart b/lib/src/features/favorites/favourites.dart index 80f5a18..29b200c 100644 --- a/lib/src/features/favorites/favourites.dart +++ b/lib/src/features/favorites/favourites.dart @@ -1 +1 @@ -export 'screens/screens.dart'; +export 'presentation/presentation.dart'; diff --git a/lib/src/features/favorites/presentation/presentation.dart b/lib/src/features/favorites/presentation/presentation.dart new file mode 100644 index 0000000..2ea3a87 --- /dev/null +++ b/lib/src/features/favorites/presentation/presentation.dart @@ -0,0 +1 @@ +export 'ui/ui.dart'; diff --git a/lib/src/features/favorites/screens/favorites_screen.dart b/lib/src/features/favorites/presentation/ui/screens/favorites_screen.dart similarity index 100% rename from lib/src/features/favorites/screens/favorites_screen.dart rename to lib/src/features/favorites/presentation/ui/screens/favorites_screen.dart diff --git a/lib/src/features/favorites/screens/screens.dart b/lib/src/features/favorites/presentation/ui/screens/screens.dart similarity index 100% rename from lib/src/features/favorites/screens/screens.dart rename to lib/src/features/favorites/presentation/ui/screens/screens.dart diff --git a/lib/src/features/favorites/presentation/ui/ui.dart b/lib/src/features/favorites/presentation/ui/ui.dart new file mode 100644 index 0000000..80f5a18 --- /dev/null +++ b/lib/src/features/favorites/presentation/ui/ui.dart @@ -0,0 +1 @@ +export 'screens/screens.dart'; diff --git a/lib/src/features/home/data/data.dart b/lib/src/features/home/data/data.dart index a67d21b..d08598b 100644 --- a/lib/src/features/home/data/data.dart +++ b/lib/src/features/home/data/data.dart @@ -1,2 +1 @@ -export 'notifiers/notifiers.dart'; export 'repositories/repositories.dart'; diff --git a/lib/src/features/home/data/repositories/home_repository.dart b/lib/src/features/home/data/repositories/home_repository.dart index fb2878f..47ec1f6 100644 --- a/lib/src/features/home/data/repositories/home_repository.dart +++ b/lib/src/features/home/data/repositories/home_repository.dart @@ -1,6 +1,4 @@ -import 'package:flutter_ebook_app/src/features/common/constants/api.dart'; -import 'package:flutter_ebook_app/src/features/common/data/providers/dio_provider.dart'; -import 'package:flutter_ebook_app/src/features/common/data/repositories/book/book_repository.dart'; +import 'package:flutter_ebook_app/src/features/features.dart'; import 'package:flutter_riverpod/flutter_riverpod.dart'; import 'package:riverpod_annotation/riverpod_annotation.dart'; diff --git a/lib/src/features/home/home.dart b/lib/src/features/home/home.dart index dd0d792..5a0d8b1 100644 --- a/lib/src/features/home/home.dart +++ b/lib/src/features/home/home.dart @@ -1,2 +1,2 @@ export 'data/data.dart'; -export 'screens/screens.dart'; +export 'presentation/presentation.dart'; diff --git a/lib/src/features/home/data/notifiers/home_feed_notifier.dart b/lib/src/features/home/presentation/notifiers/home_feed_notifier.dart similarity index 78% rename from lib/src/features/home/data/notifiers/home_feed_notifier.dart rename to lib/src/features/home/presentation/notifiers/home_feed_notifier.dart index 7e464cb..0632112 100644 --- a/lib/src/features/home/data/notifiers/home_feed_notifier.dart +++ b/lib/src/features/home/presentation/notifiers/home_feed_notifier.dart @@ -1,5 +1,4 @@ -import 'package:flutter_ebook_app/src/features/common/data/models/category_feed.dart'; -import 'package:flutter_ebook_app/src/features/home/data/repositories/home_repository.dart'; +import 'package:flutter_ebook_app/src/features/features.dart'; import 'package:riverpod_annotation/riverpod_annotation.dart'; part 'home_feed_notifier.g.dart'; @@ -13,7 +12,7 @@ class HomeFeedNotifier extends _$HomeFeedNotifier { @override Future build() async { state = const AsyncValue.loading(); - return await _fetch(); + return _fetch(); } Future fetch() async { @@ -25,8 +24,7 @@ class HomeFeedNotifier extends _$HomeFeedNotifier { final HomeRepository homeRepository = ref.read(homeRepositoryProvider); final popularFeedSuccessOrFailure = await homeRepository.getPopularHomeFeed(); - final recentFeedSuccessOrFailure = - await homeRepository.getRecentHomeFeed(); + final recentFeedSuccessOrFailure = await homeRepository.getRecentHomeFeed(); CategoryFeed? popularFeed = popularFeedSuccessOrFailure.feed; CategoryFeed? recentFeed = recentFeedSuccessOrFailure.feed; if (popularFeed == null) { diff --git a/lib/src/features/home/data/notifiers/home_feed_notifier.g.dart b/lib/src/features/home/presentation/notifiers/home_feed_notifier.g.dart similarity index 100% rename from lib/src/features/home/data/notifiers/home_feed_notifier.g.dart rename to lib/src/features/home/presentation/notifiers/home_feed_notifier.g.dart diff --git a/lib/src/features/home/data/notifiers/notifiers.dart b/lib/src/features/home/presentation/notifiers/notifiers.dart similarity index 100% rename from lib/src/features/home/data/notifiers/notifiers.dart rename to lib/src/features/home/presentation/notifiers/notifiers.dart diff --git a/lib/src/features/home/presentation/presentation.dart b/lib/src/features/home/presentation/presentation.dart new file mode 100644 index 0000000..fcbadf0 --- /dev/null +++ b/lib/src/features/home/presentation/presentation.dart @@ -0,0 +1,2 @@ +export 'notifiers/notifiers.dart'; +export 'ui/ui.dart'; diff --git a/lib/src/features/home/screens/home_screen.dart b/lib/src/features/home/presentation/ui/screens/home_screen.dart similarity index 100% rename from lib/src/features/home/screens/home_screen.dart rename to lib/src/features/home/presentation/ui/screens/home_screen.dart diff --git a/lib/src/features/home/screens/home_screen_large.dart b/lib/src/features/home/presentation/ui/screens/home_screen_large.dart similarity index 100% rename from lib/src/features/home/screens/home_screen_large.dart rename to lib/src/features/home/presentation/ui/screens/home_screen_large.dart diff --git a/lib/src/features/home/screens/home_screen_small.dart b/lib/src/features/home/presentation/ui/screens/home_screen_small.dart similarity index 100% rename from lib/src/features/home/screens/home_screen_small.dart rename to lib/src/features/home/presentation/ui/screens/home_screen_small.dart diff --git a/lib/src/features/home/screens/screens.dart b/lib/src/features/home/presentation/ui/screens/screens.dart similarity index 100% rename from lib/src/features/home/screens/screens.dart rename to lib/src/features/home/presentation/ui/screens/screens.dart diff --git a/lib/src/features/home/presentation/ui/ui.dart b/lib/src/features/home/presentation/ui/ui.dart new file mode 100644 index 0000000..80f5a18 --- /dev/null +++ b/lib/src/features/home/presentation/ui/ui.dart @@ -0,0 +1 @@ +export 'screens/screens.dart'; diff --git a/lib/src/features/settings/presentation/presentation.dart b/lib/src/features/settings/presentation/presentation.dart new file mode 100644 index 0000000..2ea3a87 --- /dev/null +++ b/lib/src/features/settings/presentation/presentation.dart @@ -0,0 +1 @@ +export 'ui/ui.dart'; diff --git a/lib/src/features/settings/screens/licenses_screen.dart b/lib/src/features/settings/presentation/ui/screens/licenses_screen.dart similarity index 100% rename from lib/src/features/settings/screens/licenses_screen.dart rename to lib/src/features/settings/presentation/ui/screens/licenses_screen.dart diff --git a/lib/src/features/settings/screens/screens.dart b/lib/src/features/settings/presentation/ui/screens/screens.dart similarity index 100% rename from lib/src/features/settings/screens/screens.dart rename to lib/src/features/settings/presentation/ui/screens/screens.dart diff --git a/lib/src/features/settings/screens/settings_screen.dart b/lib/src/features/settings/presentation/ui/screens/settings_screen.dart similarity index 100% rename from lib/src/features/settings/screens/settings_screen.dart rename to lib/src/features/settings/presentation/ui/screens/settings_screen.dart diff --git a/lib/src/features/settings/screens/settings_screen_large.dart b/lib/src/features/settings/presentation/ui/screens/settings_screen_large.dart similarity index 100% rename from lib/src/features/settings/screens/settings_screen_large.dart rename to lib/src/features/settings/presentation/ui/screens/settings_screen_large.dart diff --git a/lib/src/features/settings/screens/settings_screen_small.dart b/lib/src/features/settings/presentation/ui/screens/settings_screen_small.dart similarity index 100% rename from lib/src/features/settings/screens/settings_screen_small.dart rename to lib/src/features/settings/presentation/ui/screens/settings_screen_small.dart diff --git a/lib/src/features/settings/presentation/ui/ui.dart b/lib/src/features/settings/presentation/ui/ui.dart new file mode 100644 index 0000000..80f5a18 --- /dev/null +++ b/lib/src/features/settings/presentation/ui/ui.dart @@ -0,0 +1 @@ +export 'screens/screens.dart'; diff --git a/lib/src/features/settings/settings.dart b/lib/src/features/settings/settings.dart index 80f5a18..29b200c 100644 --- a/lib/src/features/settings/settings.dart +++ b/lib/src/features/settings/settings.dart @@ -1 +1 @@ -export 'screens/screens.dart'; +export 'presentation/presentation.dart'; diff --git a/lib/src/features/splash/presentation/presentation.dart b/lib/src/features/splash/presentation/presentation.dart new file mode 100644 index 0000000..2ea3a87 --- /dev/null +++ b/lib/src/features/splash/presentation/presentation.dart @@ -0,0 +1 @@ +export 'ui/ui.dart'; diff --git a/lib/src/features/splash/screens/screens.dart b/lib/src/features/splash/presentation/ui/screens/screens.dart similarity index 100% rename from lib/src/features/splash/screens/screens.dart rename to lib/src/features/splash/presentation/ui/screens/screens.dart diff --git a/lib/src/features/splash/screens/splash_screen.dart b/lib/src/features/splash/presentation/ui/screens/splash_screen.dart similarity index 100% rename from lib/src/features/splash/screens/splash_screen.dart rename to lib/src/features/splash/presentation/ui/screens/splash_screen.dart diff --git a/lib/src/features/splash/presentation/ui/ui.dart b/lib/src/features/splash/presentation/ui/ui.dart new file mode 100644 index 0000000..80f5a18 --- /dev/null +++ b/lib/src/features/splash/presentation/ui/ui.dart @@ -0,0 +1 @@ +export 'screens/screens.dart'; diff --git a/lib/src/features/splash/splash.dart b/lib/src/features/splash/splash.dart index 80f5a18..29b200c 100644 --- a/lib/src/features/splash/splash.dart +++ b/lib/src/features/splash/splash.dart @@ -1 +1 @@ -export 'screens/screens.dart'; +export 'presentation/presentation.dart'; diff --git a/lib/src/features/tabs/data/notifiers/current_tab_notifier.dart b/lib/src/features/tabs/presentation/notifiers/current_tab_notifier.dart similarity index 100% rename from lib/src/features/tabs/data/notifiers/current_tab_notifier.dart rename to lib/src/features/tabs/presentation/notifiers/current_tab_notifier.dart diff --git a/lib/src/features/tabs/data/notifiers/notifiers.dart b/lib/src/features/tabs/presentation/notifiers/notifiers.dart similarity index 100% rename from lib/src/features/tabs/data/notifiers/notifiers.dart rename to lib/src/features/tabs/presentation/notifiers/notifiers.dart diff --git a/lib/src/features/tabs/presentation/presentation.dart b/lib/src/features/tabs/presentation/presentation.dart new file mode 100644 index 0000000..fcbadf0 --- /dev/null +++ b/lib/src/features/tabs/presentation/presentation.dart @@ -0,0 +1,2 @@ +export 'notifiers/notifiers.dart'; +export 'ui/ui.dart'; diff --git a/lib/src/features/tabs/screens/screens.dart b/lib/src/features/tabs/presentation/ui/screens/screens.dart similarity index 100% rename from lib/src/features/tabs/screens/screens.dart rename to lib/src/features/tabs/presentation/ui/screens/screens.dart diff --git a/lib/src/features/tabs/screens/tabs_screen.dart b/lib/src/features/tabs/presentation/ui/screens/tabs_screen.dart similarity index 100% rename from lib/src/features/tabs/screens/tabs_screen.dart rename to lib/src/features/tabs/presentation/ui/screens/tabs_screen.dart diff --git a/lib/src/features/tabs/screens/tabs_screen_large.dart b/lib/src/features/tabs/presentation/ui/screens/tabs_screen_large.dart similarity index 100% rename from lib/src/features/tabs/screens/tabs_screen_large.dart rename to lib/src/features/tabs/presentation/ui/screens/tabs_screen_large.dart diff --git a/lib/src/features/tabs/screens/tabs_screen_small.dart b/lib/src/features/tabs/presentation/ui/screens/tabs_screen_small.dart similarity index 100% rename from lib/src/features/tabs/screens/tabs_screen_small.dart rename to lib/src/features/tabs/presentation/ui/screens/tabs_screen_small.dart diff --git a/lib/src/features/tabs/presentation/ui/ui.dart b/lib/src/features/tabs/presentation/ui/ui.dart new file mode 100644 index 0000000..80f5a18 --- /dev/null +++ b/lib/src/features/tabs/presentation/ui/ui.dart @@ -0,0 +1 @@ +export 'screens/screens.dart'; diff --git a/lib/src/features/tabs/tabs.dart b/lib/src/features/tabs/tabs.dart index dd0d792..29b200c 100644 --- a/lib/src/features/tabs/tabs.dart +++ b/lib/src/features/tabs/tabs.dart @@ -1,2 +1 @@ -export 'data/data.dart'; -export 'screens/screens.dart'; +export 'presentation/presentation.dart';