2022-01-10 00:23:22 +00:00
|
|
|
//
|
|
|
|
// HomeCollectionViewCell.swift
|
|
|
|
// Reader
|
|
|
|
//
|
|
|
|
// Created by Shadowfacts on 1/9/22.
|
|
|
|
//
|
|
|
|
|
|
|
|
import UIKit
|
2022-06-19 18:56:56 +00:00
|
|
|
import Fervor
|
2022-01-10 00:23:22 +00:00
|
|
|
|
|
|
|
class HomeCollectionViewCell: UICollectionViewListCell {
|
|
|
|
|
2022-01-15 19:09:30 +00:00
|
|
|
#if !targetEnvironment(macCatalyst)
|
2022-01-10 00:23:22 +00:00
|
|
|
override func updateConfiguration(using state: UICellConfigurationState) {
|
|
|
|
var backgroundConfig = UIBackgroundConfiguration.listGroupedCell().updated(for: state)
|
2022-01-11 03:36:54 +00:00
|
|
|
if state.isHighlighted || state.isSelected {
|
|
|
|
backgroundConfig.backgroundColor = .appCellHighlightBackground
|
|
|
|
} else {
|
2022-01-10 00:23:22 +00:00
|
|
|
backgroundConfig.backgroundColor = .appBackground
|
|
|
|
}
|
|
|
|
self.backgroundConfiguration = backgroundConfig
|
|
|
|
}
|
2022-01-15 19:09:30 +00:00
|
|
|
#endif
|
2022-01-10 00:23:22 +00:00
|
|
|
|
|
|
|
}
|