refactor unread into controller - #2908
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
| Iterable<ItemPosition> itemPositions, { | ||
| required bool isAtBottom, | ||
| }) { | ||
| _hasLaidOut.value = true; |
There was a problem hiding this comment.
Should we maybe have the if (itemPositions.isEmpty) return; guard here as well? We currently only have this guard before calling handleItemPositionsChanged in the message_list_view, but maybe we could introduce it here as an additional safeguard in case we introduce a new scenario where this method is called.
| bool get needsAnchorResolution => _unreadBaseline != null && _unreadDivider.value.anchorId == null; | ||
|
|
||
| /// Debounced channel mark-read. | ||
| late final debouncedMarkRead = debounce( |
There was a problem hiding this comment.
I think this can be private? (also debouncedMarkThreadRead)
Submit a pull request
FLU-672
CLA
Description of the pull request
This is a follow up on #2871
That PR already has reviews, but unread logic was getting spread on a lot of places. Here we try to make the MLV clean again by extracting all the unread logic.