View Participant Screen
Overview
The LMChatParticipantListViewController
is responsible for displaying and managing a list of chat participants. It utilizes the LMChatParticipantListView
to present the participant data and includes search functionality for filtering participants.
Functionality
Protocols Implemented
LMParticipantListViewDelegate
: Manages user interactions with the participant list.
UI Components
searchController
: AUISearchController
for participant search functionality.containerView
: An instance ofLMChatParticipantListView
that displays the list of participants.
Methods
setupSearchBar()
: Configures the search bar in the navigation bar.
Customization
CustomParticipantListViewController.swift
class CustomParticipantListViewController: LMChatParticipantListViewController {
override func setupAppearance() {
super.setupAppearance()
containerView.backgroundColor = .lightGray
}
override func setupSearchBar() {
super.setupSearchBar()
searchController.searchBar.tintColor = .blue
}
}
AppDelegate.swift
func application(_ application: UIApplication, willFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? = nil) -> Bool {
LMUIComponents.shared.participantListScreen = CustomParticipantListViewController.self
// ...
return true
}