-
-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Introducing Socialised Stories Updates #2537
base: main
Are you sure you want to change the base?
Conversation
Hey there 👋,
|
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2537 +/- ##
==========================================
- Coverage 33.20% 33.16% -0.05%
==========================================
Files 743 753 +10
Lines 48274 48660 +386
==========================================
+ Hits 16029 16136 +107
- Misses 32245 32524 +279
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
# Conflicts: # app/lib/l10n/app_en.arb
# Conflicts: # app/lib/features/news/providers/news_post_editor_providers.dart
# Conflicts: # app/lib/features/news/providers/news_post_editor_providers.dart # app/lib/features/news/widgets/news_grid_view.dart # app/lib/features/news/widgets/news_item/news_item.dart # app/lib/features/news/widgets/news_item_slide/image_slide.dart # app/lib/features/news/widgets/news_item_slide/news_slide_item.dart # app/lib/features/news/widgets/news_item_slide/video_slide.dart # app/lib/l10n/app_en.arb # app/test/features/update/image_slide_widget_test.dart # app/test/features/update/video_slide_widget_test.dart
@@ -33,16 +33,15 @@ extension ActerNews on ConvenientTest { | |||
} | |||
|
|||
Future<void> toggleBackgroundColor() async { | |||
final slideBackgroundColorKey = | |||
find.byKey(NewsUpdateKeys.slideBackgroundColor); | |||
final slideBackgroundColorKey = find.byKey(UpdateKeys.slideBackgroundColor); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Only name changes from NewsUpdateKeys
to UpdateKeys
@@ -72,39 +71,39 @@ extension ActerNews on ConvenientTest { | |||
final imageFile = await convertAssetImageToXFile( | |||
filepath ?? 'assets/images/update_onboard.png', | |||
); | |||
final slide = NewsSlideItem( | |||
type: NewsSlideType.image, | |||
final slide = UpdateSlideItem( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Only name changes from NewsSlideItem
to UpdateSlideItem
@@ -28,6 +28,7 @@ enum Routes { | |||
update('/updates/:updateId([^/]+)'), | |||
updateList('/updateList'), | |||
actionAddUpdate('/actions/addUpdate'), | |||
actionAddUpdatePostTo('/actions/addUpdate/PostTo'), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added new PostTo screen
as show-case in PR Description
@@ -57,11 +58,11 @@ extension TaskCommentsManagerProviderExtension on Task { | |||
TaskCommentsManagerProvider(this); | |||
} | |||
|
|||
class NewsEntryCommentsManagerProvider implements CommentsManagerProvider { | |||
final NewsEntry inner; | |||
class UpdateEntryCommentsManagerProvider implements CommentsManagerProvider { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Naming changes only.
import 'package:flutter_riverpod/flutter_riverpod.dart'; | ||
import 'package:mime/mime.dart'; | ||
|
||
Future<NewsSlideDraft> makeImageSlideForNews( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No logical changes. Just copied logic from previous implementation and used it based on the post type.
@@ -0,0 +1,65 @@ | |||
import 'package:acter_flutter_sdk/acter_flutter_sdk_ffi.dart'; | |||
|
|||
abstract class UpdateSlide { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Generalised abstract class creation.
|
||
enum PostTypeSelection { story, boost, none } | ||
|
||
class AddNewsPostToPage extends ConsumerStatefulWidget { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All new PostTo page for space selection and post type selection.
NewsSlideItem? selectedNewsSlide = state.currentNewsSlide; | ||
selectedNewsSlide?.backgroundColor = getRandomElement(newsPostColors); | ||
state = state.copyWith(currentNewsSlide: selectedNewsSlide); | ||
UpdateSlideItem? selectedUpdateSlide = state.currentUpdateSlide; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Naming changes only.
import 'package:riverpod/riverpod.dart'; | ||
|
||
//EVENT FILTERS | ||
enum UpdateFilters { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added filters for updates
import 'package:flutter_gen/gen_l10n/l10n.dart'; | ||
import 'package:flutter_riverpod/flutter_riverpod.dart'; | ||
|
||
class NewsFilterButtons extends ConsumerWidget { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixes, #2502
Note to reviewers :
Introducing new type of Acter Update which is called Stories
STORIES : "Everyone can see and It will disappears in 14 days",
BOOST : "Important News. Which also sends a push notification to space members",
Summary of changes
1) Removed space selection from post editor screen:
As Boost/Stories action items are independent from space selection, I have remove space selection option from editor window.
Space.selection.removal.from.editor.mov
2) Introducing all new
PostTo
screen:As now you there are two type of Updates which is Stories and Boost, so upon setting update different slides from post editor you will be navigating to new PostTo screen where you need to do,
Post.To.mov
3) Changes in View Updates:
Update.view.mov
Update.Grid.View.mov
4) Overview of key code changes: