Remove UserPresence and default to showing online status#6251
Conversation
PR checklist ✅All required conditions are satisfied:
🎉 Great job! This PR is ready for review. |
SDK Size Comparison 📏
|
|
@coderabbitai review |
✅ Actions performedReview triggered.
|
WalkthroughThis pull request removes the Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches
🧪 Generate unit tests (beta)
📝 Coding Plan
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 Tip CodeRabbit can generate a title for your PR based on the changes.Add |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@stream-chat-android-compose/api/stream-chat-android-compose.api`:
- Line 3125: ChatTheme's signature has removed the UserPresence parameter
(breaking change); update the repository docs by adding an entry under the
stream-chat-android-compose section in CHANGELOG.md in the ❌ Removed subsection
describing that ChatTheme no longer accepts UserPresence and that callers should
use UserAvatar with the showIndicator parameter instead, and add a new
MIGRATION_TO_V7.md that gives concrete migration steps showing how to replace
code paths that passed UserPresence to ChatTheme with equivalent UserAvatar
configuration (reference symbol ChatTheme, previously-present UserPresence, and
replacement UserAvatar::showIndicator) so users upgrading know exactly how to
adapt their code.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID: 3bc22ca0-e9d1-4e59-b97f-19bc3471a373
📒 Files selected for processing (16)
stream-chat-android-compose/api/stream-chat-android-compose.apistream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui/channel/info/ChannelInfoMemberInfoModalSheet.ktstream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui/channel/info/DirectChannelInfoScreen.ktstream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui/channel/info/GroupChannelInfoScreen.ktstream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui/channels/info/SelectedChannelMenu.ktstream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui/channels/list/SearchResultItem.ktstream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui/components/channels/ChannelMembersItem.ktstream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui/messages/header/MessageListHeader.ktstream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui/messages/preview/internal/MessagePreviewItem.ktstream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui/theme/ChatTheme.ktstream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui/threads/ThreadItem.ktstream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui/util/ChannelUtils.ktstream-chat-android-ui-common/api/stream-chat-android-ui-common.apistream-chat-android-ui-common/src/main/kotlin/io/getstream/chat/android/ui/common/model/UserPresence.ktstream-chat-android-ui-common/src/main/kotlin/io/getstream/chat/android/ui/common/utils/extensions/User.ktstream-chat-android-ui-common/src/test/kotlin/io/getstream/chat/android/ui/common/utils/UserPresenceTest.kt
💤 Files with no reviewable changes (8)
- stream-chat-android-ui-common/src/main/kotlin/io/getstream/chat/android/ui/common/model/UserPresence.kt
- stream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui/util/ChannelUtils.kt
- stream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui/channels/info/SelectedChannelMenu.kt
- stream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui/messages/header/MessageListHeader.kt
- stream-chat-android-ui-common/src/test/kotlin/io/getstream/chat/android/ui/common/utils/UserPresenceTest.kt
- stream-chat-android-ui-common/api/stream-chat-android-ui-common.api
- stream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui/theme/ChatTheme.kt
- stream-chat-android-ui-common/src/main/kotlin/io/getstream/chat/android/ui/common/utils/extensions/User.kt
stream-chat-android-compose/api/stream-chat-android-compose.api
Outdated
Show resolved
Hide resolved
|



Goal
Remove
UserPresenceand default to showing online status. Integrators that want to hide the online status can override the relevant components, e.g. they would overrideUserAvatarand callsuper.UserAvatarpassingshowIndicator = false.Implementation
Basically what the title says: removed
UserPresenceand defaulted usages to showing online status.🎨 UI Changes
No changes
Testing
No changes in the sample
Summary by CodeRabbit
Breaking Changes
Changes