-
Notifications
You must be signed in to change notification settings - Fork 24
feat: chat bubbles - reactively update sender name - WPB-19514 #3455
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
base: develop
Are you sure you want to change the base?
Conversation
…e/CB-4-update-sender-name # Conflicts: # WireMessaging/Sources/WireMessagingUI/Conversation/ConversationMessagesDataSource.swift
# Conflicts: # WireMessaging/Sources/WireMessagingDomain/Conversation/MessageModel.swift # WireMessaging/Sources/WireMessagingUI/Conversation/ConversationMessagesDataSource.swift # WireMessaging/Sources/WireMessagingUI/Conversation/ConversationMessagesViewController.swift # WireMessaging/Sources/WireMessagingUI/Conversation/ConversationMessagesViewModel.swift # WireMessaging/Sources/WireMessagingUI/Conversation/Message Views/TextMessageView/TextMessageViewModel.swift # WireMessaging/Sources/WireMessagingUI/Conversation/MessageType.swift # WireMessaging/Sources/WireMessagingUI/Conversation/MessageUpdateType.swift # WirePreviewApps/WIreChatBubbles/SceneDelegate.swift # WirePreviewApps/WirePreviewApps.xcodeproj/project.pbxproj # wire-ios/Wire-iOS/Sources/UserInterface/Conversation/ConversationViewController.swift
…B-3-handle-message-send-WPB-19373
…e/CB-4-update-sender-name
Test Results2 003 tests 1 976 ✅ 2m 20s ⏱️ Results for commit e12c337. ♻️ This comment has been updated with latest results. |
# Conflicts: # WireMessaging/Sources/WireMessagingAssembly/ConversationsAssembly.swift # WireMessaging/Sources/WireMessagingDomain/Conversation/LoadConversationMessagesUseCase.swift # WireMessaging/Sources/WireMessagingUI/Conversation/ConversationMessagesDataSource.swift # WireMessaging/Sources/WireMessagingUI/Conversation/ConversationMessagesViewController.swift # WireMessaging/Sources/WireMessagingUI/Conversation/ConversationMessagesViewModel.swift # wire-ios/Wire-iOS/Sources/UserInterface/Conversation/Content/LoadConversationMessagesRepository.swift # wire-ios/Wire-iOS/Sources/UserInterface/Conversation/ConversationViewController.swift
…e/CB-4-update-sender-name
wire-ios/Wire-iOS/Sources/UserInterface/Conversation/MessagesIndividualUpdatesFactory.swift
Show resolved
Hide resolved
# Conflicts: # WireMessaging/Sources/WireMessagingAssembly/ConversationsAssembly.swift # WireMessaging/Sources/WireMessagingUI/Conversation/ConversationDataSource.swift # WireMessaging/Sources/WireMessagingUI/Conversation/ConversationMessagesViewController.swift # wire-ios/Wire-iOS/Sources/UserInterface/Conversation/ConversationViewController.swift
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.
Nice work! left a question
self.state = state | ||
namePublisher?.sink { [weak self] name in | ||
self?.state = .exists(AttributedString(name)) | ||
}.store(in: &cancellables) |
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.
question: no risk of having a binding still active when a view is reused ? probably works differently in SwiftUI but on UIKit we could have these issues with reusable cells if we didn't clear out the subscriptions which could mess the UI.
Issue
Added logic to handle when user name changed, by introducing one publisher per user (one subject and sever cell's view models as subscribers.
Testing
Simulator.Screen.Recording.-.iPhone.16.Pro.-.2025-08-13.at.18.50.17.mp4