/CardCollection

CardCollectionView, MMCardView Swift 5

Primary LanguageSwiftMIT LicenseMIT

CardView, Swift 5

* 第 3 个例子,是 Drag, 拖动

Drag

* 第 2 个例子,是 Parallax

2.1 简化,黏住效果

easy

2.2 原版,小小改动

原版

基于 Custom UICollectionViewLayout Tutorial With Parallax

Parallax, 视差效果,

就是滚动的时候,cell 上面的图片 picture , 有一个纵向 ( y 轴 ) 的位移

上上下下的晃动


* 第一个例子,Demo

Latest Simple Card

new

tip

Origin Card

demo

from MillmanY/MMCardView

Use Card

1.Inherit your collectionView to MMCollectionView

@IBOutlet weak var cardCollection: MMCollectionView!

2.Create your Cell inherit "CardCell"

class CardACell: CardCell {

}

if let layout = cardCollection.collectionViewLayout as? CustomCardLayout {
     layout.titleHeight = 100.0
     layout.bottomShowCount = 3
     layout.cardHeight = 300
     layout.showStyle = .cover
}

Installation : Just DIY