PaoloCuscela / Cards

Awesome iOS 11 appstore cards in swift 5.
MIT License
4.21k stars 275 forks source link

Using Cards in a CollectionView #49

Closed semih-akbas closed 6 years ago

semih-akbas commented 6 years ago

Hi Paolo,

First of all thanks for such a great work you've done. I'm considering using the cards in a collection view or tableview. How would you recommend to go on? I mean with the current implementation if I set the class of my CollectionViewCell main UIView to i.e. CardsHighlight and tap on one of the cells the Cards grow inside the Cell region, I want it to grow within the entire screen.

Thanks in advance, Semih

PaoloCuscela commented 6 years ago

I' ve done some testing right now with a TableView and seems to be allright. Could you upload an example project where you face that issue ?

zaccadams commented 6 years ago

I believe semih-akbas is talking about how CardHighlight when tapped fills up the entirety of the screen with the X button but when every other Card is tapped they show the content squeezed with a blurred background. I might be reading it wrong but thats the problem I'm facing. Is there any easy way to switch the likes of CardPlayer to fill the entire screen like CardHighlight. I can provide screenshots if need be. :)

zaccadams commented 6 years ago

Actually don't worry, I've just figured my own issue. I changed tableViewCell.cardView.shouldPresent(cardContent, from: self) to tableViewCell.cardView.shouldPresent(cardContent, from: self, fullscreen: true). Hope this answers the question.

PaoloCuscela commented 6 years ago

Great to know you've solved :D closing on this.