FUIListCardView
@MainActor
open class FUIListCardView<ItemIdentifier> : FUICardBaseContainer<FUICardHeaderView, FUIListCardContentView<ItemIdentifier>>, FUICardHeaderViewComponent where ItemIdentifier : Hashable, ItemIdentifier : Identifiable
extension FUIListCardView: FUIListCardComponent
Base container for showing business object header information.
Example Initialization and Configuration:
let view = FUIListCardView<ItemIdentifier>()
view.detailImageView.image = UIImage(named: "imageName")
view.title = "Title"
view.primaryButton.isHidden = false
view.primaryAction.setTitle("Primary", for: .normal)
view.secondaryAction.isHidden = false
view.secondaryAction.setTitle("Secondary", for: .normal)
view.overflowAction.isHidden = false
view.overflowAction.setImage(UIImage(systemName: "ellipsis"), for: .normal)
view.register(cellClass: AnyClass?, forCellReuseIdentifier: "reuseIdentifier")
view.cellProvider = ((UITableView, IndexPath, ItemIdentifier) -> UITableViewCell)
view.setItems([ItemIdentifier])
view.cellTappedHandler = ...
Skeleton
let view = FUIListCardView<ItemIdentifier>()
view.showSkeleton()
view.hideSkeleton()
Theming
Supported TEXT class paths:
fdlFUICardHeaderView_title {} fdlFUIListCardView_overflowAction {} fdlFUIListCardView_primaryAction {} fdlFUIListCardView_secondaryAction {}
Supported TEXT properties:
font-color: Color; font-style: UIFontTextStyle; text-align: NSTextAlignment;
Supported IMAGE class paths:
fdlFUIListCardView_detailImageView {}
Supported IMAGE properties:
tint-color: Color;
-
nodoc:
Declaration
Swift
@MainActor open override func prepareForReuse() -
UIImageViewdisplayingdetailImagecontent. Will be rendered in view hierarchy.Declaration
Swift
@MainActor public var detailImageView: FUIImageView { get } -
Multiline text property configuration for
titlecontent.Declaration
Swift
@MainActor public var title: FUIMultiLineText { get set } -
Container for list card content
Declaration
Swift
@MainActor public var tableView: UITableView { get } -
Cell tapped action closure
Declaration
Swift
@MainActor public var cellTappedHandler: ((IndexPath, ItemIdentifier) -> Void)? { get set } -
Diffable data source for list card table view
Declaration
Swift
@MainActor public var dataSource: UITableViewDiffableDataSource<Int, ItemIdentifier>! { get set } -
Cell provider for list card table view
Declaration
Swift
@MainActor public var cellProvider: ((UITableView, IndexPath, ItemIdentifier) -> UITableViewCell)? { get set } -
Registers a class to use in list card content table cells.
Declaration
Swift
@MainActor public func register(_ cellClass: AnyClass?, forCellReuseIdentifier identifier: String) -
Set the items with the specified identifiers to the snapshot.
Declaration
Swift
@MainActor public func setItems(_ items: [ItemIdentifier]) -
Adds the items with the specified identifiers to the snapshot.
Declaration
Swift
@MainActor public func appendItems(_ items: [ItemIdentifier]) -
Deletes the items with the specified identifiers from the snapshot.
Declaration
Swift
@MainActor public func deleteItems(_ items: [ItemIdentifier]) -
Deletes all of the items from the snapshot.
Declaration
Swift
@MainActor public func deleteAllItems() -
Inserts the provided items immediately before the item with the specified identifier in the snapshot.
Declaration
Swift
@MainActor public func insertItems(_ items: [ItemIdentifier], beforeItem: ItemIdentifier) -
Inserts the provided items immediately after the item with the specified identifier in the snapshot.
Declaration
Swift
@MainActor public func insertItems(_ items: [ItemIdentifier], afterItem: ItemIdentifier) -
Moves the item from its current position in the snapshot to the position immediately before the specified item.
Declaration
Swift
@MainActor public func moveItem(_ item: ItemIdentifier, beforeItem: ItemIdentifier) -
Moves the item from its current position in the snapshot to the position immediately after the specified item.
Declaration
Swift
@MainActor public func moveItem(_ item: ItemIdentifier, afterItem: ItemIdentifier) -
Reloads the data within the specified items in the snapshot.
Declaration
Swift
@MainActor public func reloadItems(_ items: [ItemIdentifier])