|
@@ -160,13 +160,17 @@ class MVBannerCell: UICollectionViewCell {
|
|
|
typeLab.text = "\(videoData?.categoryName ?? "")"
|
|
|
BFLog(message: "videoDatavideoData \(String(describing: videoData?.title))")
|
|
|
|
|
|
+ titleLabel.font = UIFont.systemFont(ofSize: 16, weight: .bold)
|
|
|
+
|
|
|
+ let boundingRect : CGRect = (videoData?.title?.boundingRect(with: CGSize(width: 200, height: 0), options: .usesLineFragmentOrigin, attributes: [NSAttributedString.Key.font: UIFont.systemFont(ofSize: 16, weight: .bold)], context: nil)) ?? CGRect.init()
|
|
|
+
|
|
|
titleLabel.snp.remakeConstraints { make in
|
|
|
-// make.width.equalTo(cScreenWidth - 80)
|
|
|
make.right.equalTo(reCreateBtn.snp_right)
|
|
|
- make.height.equalTo(videoData?.titleH ?? 0)
|
|
|
+ make.height.equalTo(boundingRect.height)
|
|
|
make.left.equalToSuperview().offset(12)
|
|
|
make.bottom.equalTo(musicContenView.snp_top).offset(-cDefaultMargin)
|
|
|
}
|
|
|
+ BFLog(message: "videoData?.title is \(String(describing: videoData?.title))")
|
|
|
titleLabel.text = videoData?.title ?? ""
|
|
|
|
|
|
|