-
Notifications
You must be signed in to change notification settings - Fork 25
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
Display read receipts next to each message as a row of Avatars for users who have seen that message #162
Display read receipts next to each message as a row of Avatars for users who have seen that message #162
Conversation
[WIP] Will try to change sequencer to follow GenUI's way of creating a list of widgets |
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.
A great start, thanks!
I suggested some minor API changes that will make things clearer and less error-prone. After those changes are made, it should be ready to merge.
Using the existing Alternatively, we can create a separate function (or further modify |
Co-authored-by: Kevin Boos <[email protected]>
Co-authored-by: Kevin Boos <[email protected]>
Co-authored-by: Kevin Boos <[email protected]>
…brix into read_receipt_display
Hmm, ok. Yeah, the only potential cause I could think of was a missing call to set the UI Signal, but if that's already there, then there might be a different cause for the delay. What I observed is a 10+ second delay between (1) a log statement that says the avatar/profile was fetched for a given user, and (2) the actual image being refreshed for the avatar. Another cause of this might be how we cache whether a given event was drawn in the timeline. We might need another variable that tracks the draw status of the read receipts separately from that of the event's content and the event's user profile details. In any case, we can make this improvement later and merge this in now, since the fundamental functionality appears to be working correctly. |
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.
Code looks good! I've tested everything locally and it works well.
However, the UI layout of the AvatarRow is a bit inconsistent for different message types. For example, the Avatars are not all vertically aligned, so it looks a bit weird.
There's also still a lot of wasted space on the right side of the RoomScreen.
I think you could fix both of these layout issues by setting the x
-alignment of the AvatarRow to the far right side of its parent view in the room screen, and then using a right-margin of 10 or 20.
The final issue would be that the AvatarRow should be displayed towards the bottom of each message, not towards the top of it. This is particularly noticeable on regular (non-Condensed) messages, like the ones from 8:59am, 10:02am, and 10:10am in this screenshot.
![image](https://private-user-images.githubusercontent.com/1139460/405399189-0ea85dc3-4e43-442f-8b05-eb4a4054a01f.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzk0NDI0MjcsIm5iZiI6MTczOTQ0MjEyNywicGF0aCI6Ii8xMTM5NDYwLzQwNTM5OTE4OS0wZWE4NWRjMy00ZTQzLTQ0MmYtOGIwNS1lYjRhNDA1NGEwMWYucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI1MDIxMyUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNTAyMTNUMTAyMjA3WiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9M2U5ZWI3ZTFkMDhiMTI4MDNlNDdiOTc4NDhiY2E4NjU5ZTViNDdkZmE0ZWM5NGI5NWM1NWFkMzhlYWNkMzlhZSZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QifQ.oDxeLZ72PUUx_YxTiN6sHSP0ZTnJJB_Po17vCziJUhw)
Oh, and also feel free to ignore the positioning of the Message action bar (the small Reply button that pops up when you hover over a message). I am in the process of removing that, so you don't need to reserve any space for it on the right side of the room screen. |
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.
Looking good, it's almost there!
It seems like there is a slight issue with the way you defined the new Views that wrap around the ReactionList and AvatarRow. It's causing weird whitespace gaps like this:
Seems like it's mostly a problem with CondensedMessage, CondensedImageMessage, and SmallStateEvent (more so than regular Message and ImageMessage views, but they might also need adjustment). Make sure you try it out with various different widths of the RoomScreen (which is easiest to do by making the RoomsList wider).
In general, the AvatarRow should go at the very bottom right of an event view, and the Reaction list should go directly beneath the content of the event (like it was previously, before this PR).
I made a small commit that adjusted some things.
…brix into read_receipt_display
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.
Fanstastic work, thanks so much! Can confirm that everything is working well.
Fixes #153