-
-
Notifications
You must be signed in to change notification settings - Fork 4.5k
fix: v0.9.2 launch review issues #7898
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
Conversation
Reviewer's GuideThis pull request addresses several issues identified during the v0.9.2 launch review. It refines chat message loading and animations by implementing debounced loading for previous messages and adjusting scroll behavior. File block insertion in the editor is improved to replace empty paragraphs directly. Navigation is enhanced by automatically switching to a view's parent space upon opening. A UI glitch causing opacity on the locked page icon has been fixed. Finally, iOS pod dependencies have been updated. Class Diagram: Key Changes in v0.9.2 Launch Review FixesclassDiagram
class ChatAnimatedListState {
+Debounce _loadPreviousMessagesDebounce
+initState() void
+build(BuildContext context) Widget
+dispose() void
+_handleLoadPreviousMessages() void
+_onInserted(int position, Message data) void
+_handleToggleScrollToBottom() void
}
note for ChatAnimatedListState "Manages the animated list of chat messages.\n- Added Debounce _loadPreviousMessagesDebounce for fetching older messages.\n- initState() registers a listener to trigger _handleLoadPreviousMessages on scroll.\n- build() logic updated for initial scroll position and spacing.\n- _onInserted() updated for item insertion animation.\n- _handleToggleScrollToBottom() logic refined for showing/hiding scroll button."
class EditorStateExtension {
<<extension>>
+insertEmptyFileBlock(GlobalKey key) Future~void~
}
note for EditorStateExtension "Extension on EditorState for file block operations.\n- insertEmptyFileBlock() logic modified to replace an empty paragraph node with the file block, or insert it after the current node."
class DesktopHomeScreen {
+build(BuildContext context) Widget
-_switchToSpace(ViewPB view) Future~void~
}
note for DesktopHomeScreen "Main screen for desktop.\n- When a view is opened, it now calls _switchToSpace to potentially switch to the view's parent space.\n- Uses ViewBackendService to get view ancestors and switchToSpaceIdNotifier to trigger the space switch."
class _SpaceState {
+initState() void
+dispose() void
-_switchToSpace() void
}
note for _SpaceState "State for a space item in the sidebar.\n- initState() now listens to switchToSpaceIdNotifier.\n- _switchToSpace() is called when the notifier fires, triggering a SpaceBloc event to open the specified space."
class LockPageButtonWrapper {
+build(BuildContext context) Widget
}
note for LockPageButtonWrapper "Wrapper for the lock page button.\n- Removed Opacity widget to fix UI glitch where icon was semi-transparent when locked."
class GlobalNotifiers {
<<New>>
+ValueNotifier~ViewPB?~ switchToSpaceIdNotifier
}
note for GlobalNotifiers "New global ValueNotifier.\n- switchToSpaceIdNotifier is used to communicate the need to switch to a specific space (identified by ViewPB) from DesktopHomeScreen to _SpaceState."
ChatAnimatedListState ..> Debounce : uses
ChatAnimatedListState ..> Message : uses
DesktopHomeScreen ..> GlobalNotifiers : uses switchToSpaceIdNotifier
DesktopHomeScreen ..> ViewPB : uses
_SpaceState ..> GlobalNotifiers : listens to switchToSpaceIdNotifier
class Debounce {
+Debounce(Duration duration)
+call(Function callback) void
}
class ViewPB {
+String id
+isSpace() bool
}
class Message {
// Message properties
}
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
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.
Hey @LucasXu0 - I've reviewed your changes - here's some feedback:
_oldList
inChatAnimatedListState
may become outdated after inserts/removals, affecting subsequent_onUpdated
diffs.- Please clarify how list animations in
ChatAnimatedListState
are handled after_onInserted
/_onRemoved
/_onMoved
calls were removed from the event stream. - The
_onInserted
method inChatAnimatedListState
uses a hardcoded index 0 forinsertItem
while its logic also depends on theposition
argument; this seems inconsistent.
Here's what I looked at during the review
- 🟢 General issues: all looks good
- 🟢 Security: all looks good
- 🟢 Testing: all looks good
- 🟢 Complexity: all looks good
- 🟢 Documentation: all looks good
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
Feature Preview
PR Checklist
Summary by Sourcery
Address various UI and user experience issues in the AppFlowy application, focusing on chat, document editing, and workspace navigation
New Features:
Bug Fixes:
Enhancements:
Tests: