android: keep read ack strictly bounded by visible incoming messages
Some checks failed
Android CI / android (push) Failing after 4m58s
Android Release / release (push) Has started running
CI / test (push) Has been cancelled

This commit is contained in:
Codex
2026-03-09 23:32:22 +03:00
parent 5921215718
commit 15e80262e0
2 changed files with 5 additions and 4 deletions

View File

@@ -714,3 +714,8 @@
- Improved cross-device sync (web <-> android):
- `message_read` realtime event now parses `user_id` and `last_read_message_id`.
- on `message_read`, Android refreshes chat snapshot from backend to keep unread counters aligned across devices.
### Step 108 - Strict read boundary by visible incoming only
- Removed fallback read-pointer advancement in `ChatViewModel.acknowledgeLatestMessages(...)` that previously moved `lastReadMessageId` by latest loaded message id.
- Read pointer is now advanced only via `onVisibleIncomingMessageId(...)` from visible incoming rows in `ChatScreen`.
- This prevents read acknowledgements from overshooting beyond what user actually saw during refresh/recompose scenarios.