Skip to main content

Post Search Screen

LMFeedSearchPostScreen allows users to search for posts within the feed. It displays search results in a table view, supporting various post types including text, media, documents, links, and polls. The screen also handles post interactions such as liking, commenting, sharing, and saving.

LMFeedReportContentScreen

UI Elements

  • postList: A LMTableView for displaying search results
  • searchController: A UISearchController for handling search input
  • indicatorView: A UIActivityIndicatorView for loading states
  • noResultView: A LMFeedNoResultView displayed when no search results are found

Data Variables

  • posts: List of posts for search results

Customisation

CustomSearchPostScreen.swift
class CustomSearchPostScreen: LMFeedSearchPostScreen {
override func setupAppearance() {
super.setupAppearance()
tableView.backgroundColor = .lightGray
}
}
AppDelegate.swift
func application(_ application: UIApplication, willFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? = nil) -> Bool {
Components.shared.searchPostScreen = CustomSearchPostScreen.self
// ...
return true
}