From e801785ca5d7b4b14ae3aca8869ff2c400124d3e Mon Sep 17 00:00:00 2001 From: Ellet Hnewa <73608287+ellet0@users.noreply.github.com> Date: Thu, 21 Dec 2023 16:11:46 +0300 Subject: [PATCH] Re structure the folders of the example (#1640) * Re structure the folders of the example --- .../extensions/scaffold_messenger.dart | 0 example/lib/logic/empty.dart | 1 - example/lib/main.dart | 16 +++++----- .../home/widgets/example_item.dart | 0 .../home/widgets/home_screen.dart | 3 +- .../quill/embeds/timestamp_embed.dart | 0 .../quill/my_quill_editor.dart | 2 +- .../quill/my_quill_toolbar.dart | 30 +++++++++---------- .../quill/quill_screen.dart | 2 +- .../quill/samples/quill_default_sample.dart | 0 .../quill/samples/quill_images_sample.dart | 0 .../quill/samples/quill_text_sample.dart | 0 .../quill/samples/quill_videos_sample.dart | 0 .../settings/cubit/settings_cubit.dart | 0 .../cubit/settings_cubit.freezed.dart | 0 .../settings/cubit/settings_cubit.g.dart | 0 .../settings/cubit/settings_state.dart | 0 .../settings/widgets/settings_screen.dart | 0 .../shared/widgets/dialog_action.dart | 0 .../shared/widgets/home_screen_button.dart | 0 .../simple/simple_screen.dart | 0 21 files changed, 27 insertions(+), 27 deletions(-) rename example/lib/{presentation => }/extensions/scaffold_messenger.dart (100%) delete mode 100644 example/lib/logic/empty.dart rename example/lib/{presentation => screens}/home/widgets/example_item.dart (100%) rename example/lib/{presentation => screens}/home/widgets/home_screen.dart (99%) rename example/lib/{presentation => screens}/quill/embeds/timestamp_embed.dart (100%) rename example/lib/{presentation => screens}/quill/my_quill_editor.dart (99%) rename example/lib/{presentation => screens}/quill/my_quill_toolbar.dart (93%) rename example/lib/{presentation => screens}/quill/quill_screen.dart (98%) rename example/lib/{presentation => screens}/quill/samples/quill_default_sample.dart (100%) rename example/lib/{presentation => screens}/quill/samples/quill_images_sample.dart (100%) rename example/lib/{presentation => screens}/quill/samples/quill_text_sample.dart (100%) rename example/lib/{presentation => screens}/quill/samples/quill_videos_sample.dart (100%) rename example/lib/{presentation => screens}/settings/cubit/settings_cubit.dart (100%) rename example/lib/{presentation => screens}/settings/cubit/settings_cubit.freezed.dart (100%) rename example/lib/{presentation => screens}/settings/cubit/settings_cubit.g.dart (100%) rename example/lib/{presentation => screens}/settings/cubit/settings_state.dart (100%) rename example/lib/{presentation => screens}/settings/widgets/settings_screen.dart (100%) rename example/lib/{presentation => screens}/shared/widgets/dialog_action.dart (100%) rename example/lib/{presentation => screens}/shared/widgets/home_screen_button.dart (100%) rename example/lib/{presentation => screens}/simple/simple_screen.dart (100%) diff --git a/example/lib/presentation/extensions/scaffold_messenger.dart b/example/lib/extensions/scaffold_messenger.dart similarity index 100% rename from example/lib/presentation/extensions/scaffold_messenger.dart rename to example/lib/extensions/scaffold_messenger.dart diff --git a/example/lib/logic/empty.dart b/example/lib/logic/empty.dart deleted file mode 100644 index 8b137891..00000000 --- a/example/lib/logic/empty.dart +++ /dev/null @@ -1 +0,0 @@ - diff --git a/example/lib/main.dart b/example/lib/main.dart index 089042b0..fbca48eb 100644 --- a/example/lib/main.dart +++ b/example/lib/main.dart @@ -13,14 +13,14 @@ import 'package:hydrated_bloc/hydrated_bloc.dart' import 'package:path_provider/path_provider.dart' show getApplicationDocumentsDirectory; -import 'presentation/home/widgets/home_screen.dart'; -import 'presentation/quill/quill_screen.dart'; -import 'presentation/quill/samples/quill_default_sample.dart'; -import 'presentation/quill/samples/quill_images_sample.dart'; -import 'presentation/quill/samples/quill_text_sample.dart'; -import 'presentation/quill/samples/quill_videos_sample.dart'; -import 'presentation/settings/cubit/settings_cubit.dart'; -import 'presentation/settings/widgets/settings_screen.dart'; +import 'screens/home/widgets/home_screen.dart'; +import 'screens/quill/quill_screen.dart'; +import 'screens/quill/samples/quill_default_sample.dart'; +import 'screens/quill/samples/quill_images_sample.dart'; +import 'screens/quill/samples/quill_text_sample.dart'; +import 'screens/quill/samples/quill_videos_sample.dart'; +import 'screens/settings/cubit/settings_cubit.dart'; +import 'screens/settings/widgets/settings_screen.dart'; void main() async { WidgetsFlutterBinding.ensureInitialized(); diff --git a/example/lib/presentation/home/widgets/example_item.dart b/example/lib/screens/home/widgets/example_item.dart similarity index 100% rename from example/lib/presentation/home/widgets/example_item.dart rename to example/lib/screens/home/widgets/example_item.dart diff --git a/example/lib/presentation/home/widgets/home_screen.dart b/example/lib/screens/home/widgets/home_screen.dart similarity index 99% rename from example/lib/presentation/home/widgets/home_screen.dart rename to example/lib/screens/home/widgets/home_screen.dart index 2ea2a8c7..5d7a4369 100644 --- a/example/lib/presentation/home/widgets/home_screen.dart +++ b/example/lib/screens/home/widgets/home_screen.dart @@ -5,12 +5,13 @@ import 'package:file_picker/file_picker.dart' show FilePicker, FileType; import 'package:flutter/material.dart'; import 'package:flutter_quill/flutter_quill.dart'; -import '../../extensions/scaffold_messenger.dart'; +import '../../../extensions/scaffold_messenger.dart'; import '../../quill/quill_screen.dart'; import '../../quill/samples/quill_default_sample.dart'; import '../../quill/samples/quill_images_sample.dart'; import '../../quill/samples/quill_text_sample.dart'; import '../../quill/samples/quill_videos_sample.dart'; + import '../../settings/widgets/settings_screen.dart'; import 'example_item.dart'; diff --git a/example/lib/presentation/quill/embeds/timestamp_embed.dart b/example/lib/screens/quill/embeds/timestamp_embed.dart similarity index 100% rename from example/lib/presentation/quill/embeds/timestamp_embed.dart rename to example/lib/screens/quill/embeds/timestamp_embed.dart diff --git a/example/lib/presentation/quill/my_quill_editor.dart b/example/lib/screens/quill/my_quill_editor.dart similarity index 99% rename from example/lib/presentation/quill/my_quill_editor.dart rename to example/lib/screens/quill/my_quill_editor.dart index 61e4675b..f523edcd 100644 --- a/example/lib/presentation/quill/my_quill_editor.dart +++ b/example/lib/screens/quill/my_quill_editor.dart @@ -12,7 +12,7 @@ import 'package:flutter_quill_extensions/embeds/widgets/image.dart' import 'package:flutter_quill_extensions/flutter_quill_extensions.dart'; import 'package:path/path.dart' as path; -import '../extensions/scaffold_messenger.dart'; +import '../../extensions/scaffold_messenger.dart'; import 'embeds/timestamp_embed.dart'; class MyQuillEditor extends StatelessWidget { diff --git a/example/lib/presentation/quill/my_quill_toolbar.dart b/example/lib/screens/quill/my_quill_toolbar.dart similarity index 93% rename from example/lib/presentation/quill/my_quill_toolbar.dart rename to example/lib/screens/quill/my_quill_toolbar.dart index fc5cebaa..88651ed6 100644 --- a/example/lib/presentation/quill/my_quill_toolbar.dart +++ b/example/lib/screens/quill/my_quill_toolbar.dart @@ -204,21 +204,21 @@ class MyQuillToolbar extends StatelessWidget { multiRowsDisplay: true, buttonOptions: QuillSimpleToolbarButtonOptions( base: QuillToolbarBaseButtonOptions( - afterButtonPressed: focusNode.requestFocus - // globalIconSize: 20, - // iconTheme: QuillIconTheme( - // iconButtonSelectedData: IconButtonData( - // style: IconButton.styleFrom( - // foregroundColor: Colors.amberAccent, - // ), - // ), - // iconButtonUnselectedData: IconButtonData( - // style: IconButton.styleFrom( - // foregroundColor: Colors.amberAccent, - // ), - // ), - // ), - ), + afterButtonPressed: focusNode.requestFocus, + // globalIconSize: 20, + // iconTheme: QuillIconTheme( + // iconButtonSelectedData: IconButtonData( + // style: IconButton.styleFrom( + // foregroundColor: Colors.amberAccent, + // ), + // ), + // iconButtonUnselectedData: IconButtonData( + // style: IconButton.styleFrom( + // foregroundColor: Colors.amberAccent, + // ), + // ), + // ), + ), ), customButtons: [ QuillToolbarCustomButtonOptions( diff --git a/example/lib/presentation/quill/quill_screen.dart b/example/lib/screens/quill/quill_screen.dart similarity index 98% rename from example/lib/presentation/quill/quill_screen.dart rename to example/lib/screens/quill/quill_screen.dart index 991dd633..b4f7c489 100644 --- a/example/lib/presentation/quill/quill_screen.dart +++ b/example/lib/screens/quill/quill_screen.dart @@ -7,7 +7,7 @@ import 'package:flutter_quill_extensions/flutter_quill_extensions.dart' import 'package:quill_html_converter/quill_html_converter.dart'; import 'package:share_plus/share_plus.dart' show Share; -import '../extensions/scaffold_messenger.dart'; +import '../../extensions/scaffold_messenger.dart'; import '../shared/widgets/home_screen_button.dart'; import 'my_quill_editor.dart'; import 'my_quill_toolbar.dart'; diff --git a/example/lib/presentation/quill/samples/quill_default_sample.dart b/example/lib/screens/quill/samples/quill_default_sample.dart similarity index 100% rename from example/lib/presentation/quill/samples/quill_default_sample.dart rename to example/lib/screens/quill/samples/quill_default_sample.dart diff --git a/example/lib/presentation/quill/samples/quill_images_sample.dart b/example/lib/screens/quill/samples/quill_images_sample.dart similarity index 100% rename from example/lib/presentation/quill/samples/quill_images_sample.dart rename to example/lib/screens/quill/samples/quill_images_sample.dart diff --git a/example/lib/presentation/quill/samples/quill_text_sample.dart b/example/lib/screens/quill/samples/quill_text_sample.dart similarity index 100% rename from example/lib/presentation/quill/samples/quill_text_sample.dart rename to example/lib/screens/quill/samples/quill_text_sample.dart diff --git a/example/lib/presentation/quill/samples/quill_videos_sample.dart b/example/lib/screens/quill/samples/quill_videos_sample.dart similarity index 100% rename from example/lib/presentation/quill/samples/quill_videos_sample.dart rename to example/lib/screens/quill/samples/quill_videos_sample.dart diff --git a/example/lib/presentation/settings/cubit/settings_cubit.dart b/example/lib/screens/settings/cubit/settings_cubit.dart similarity index 100% rename from example/lib/presentation/settings/cubit/settings_cubit.dart rename to example/lib/screens/settings/cubit/settings_cubit.dart diff --git a/example/lib/presentation/settings/cubit/settings_cubit.freezed.dart b/example/lib/screens/settings/cubit/settings_cubit.freezed.dart similarity index 100% rename from example/lib/presentation/settings/cubit/settings_cubit.freezed.dart rename to example/lib/screens/settings/cubit/settings_cubit.freezed.dart diff --git a/example/lib/presentation/settings/cubit/settings_cubit.g.dart b/example/lib/screens/settings/cubit/settings_cubit.g.dart similarity index 100% rename from example/lib/presentation/settings/cubit/settings_cubit.g.dart rename to example/lib/screens/settings/cubit/settings_cubit.g.dart diff --git a/example/lib/presentation/settings/cubit/settings_state.dart b/example/lib/screens/settings/cubit/settings_state.dart similarity index 100% rename from example/lib/presentation/settings/cubit/settings_state.dart rename to example/lib/screens/settings/cubit/settings_state.dart diff --git a/example/lib/presentation/settings/widgets/settings_screen.dart b/example/lib/screens/settings/widgets/settings_screen.dart similarity index 100% rename from example/lib/presentation/settings/widgets/settings_screen.dart rename to example/lib/screens/settings/widgets/settings_screen.dart diff --git a/example/lib/presentation/shared/widgets/dialog_action.dart b/example/lib/screens/shared/widgets/dialog_action.dart similarity index 100% rename from example/lib/presentation/shared/widgets/dialog_action.dart rename to example/lib/screens/shared/widgets/dialog_action.dart diff --git a/example/lib/presentation/shared/widgets/home_screen_button.dart b/example/lib/screens/shared/widgets/home_screen_button.dart similarity index 100% rename from example/lib/presentation/shared/widgets/home_screen_button.dart rename to example/lib/screens/shared/widgets/home_screen_button.dart diff --git a/example/lib/presentation/simple/simple_screen.dart b/example/lib/screens/simple/simple_screen.dart similarity index 100% rename from example/lib/presentation/simple/simple_screen.dart rename to example/lib/screens/simple/simple_screen.dart