https://github.com/kenanatmaca/kslidercard
Basic, animatable iOS slider card 🃏
https://github.com/kenanatmaca/kslidercard
ios ios-cardview ios-swift ios-ui swift tinder-swiper
Last synced: about 1 year ago
JSON representation
Basic, animatable iOS slider card 🃏
- Host: GitHub
- URL: https://github.com/kenanatmaca/kslidercard
- Owner: KenanAtmaca
- License: mit
- Created: 2019-09-10T13:05:23.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2019-09-14T12:43:13.000Z (over 6 years ago)
- Last Synced: 2025-05-01T12:13:12.911Z (about 1 year ago)
- Topics: ios, ios-cardview, ios-swift, ios-ui, swift, tinder-swiper
- Language: Swift
- Homepage:
- Size: 64.5 KB
- Stars: 11
- Watchers: 1
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# KSliderCard
## Requirements
- Xcode 9.0 +
- iOS 11.0 or greater
## Installation
### CocoaPods
1. Install [CocoaPods](http://cocoapods.org)
2. Add this repo to your `Podfile`
```ruby
platform :ios, '11.0'
target 'ProjectName' do
use_frameworks!
pod 'KSliderCard'
end
```
3. Run `pod install`
4. Open up the new `.xcworkspace` that CocoaPods generated
5. Whenever you want to use the library: `import KSliderCard`
### Manually
1. Simply download the `KSliderCard` source files and import them into your project.
## Usage
```Swift
import UIKit
import KSliderCard
class ViewController: UIViewController {
var sliderCard:KSliderCard!
override func viewDidLoad() {
super.viewDidLoad()
showSliderCard()
}
func showSliderCard() {
sliderCard = KSliderCard(items: [KSliderCardItem(image: UIImage(named: "img1"), title: "Hello 🎉", text: "..."),
KSliderCardItem(image: UIImage(named: "img2"), title: "Hii", text: "..."),
KSliderCardItem(image: UIImage(named: "img3"), title: "Heey", text: "...")])
sliderCard.options.isBlurImage = false
sliderCard.options.backgroundStyle = .dark
sliderCard.options.backAction = true
sliderCard.options.backButtonImage = UIImage(named: "back")
sliderCard.options.backButtonSize = CGSize(width: 64, height: 64)
sliderCard.options.backButtonBackgroundColor = .clear
sliderCard.options.backButtonColor = .white
sliderCard.show(to: self.view)
}
}
```
## Options
```Swift
titleColor:UIColor?
titleFont:UIFont?
textColor:UIColor?
textFont:UIFont?
isBlurImage:Bool = true
isAnimation:Bool = true
backgroundStyle:KSliderBackgroundStyle? // .dark, .light
blurStyle:KSliderBackgroundStyle? // .dark, .light
backAction:Bool = false
backButtonTitle:String?
backButtonImage:UIImage?
backButtonBackgroundColor:UIColor?
backButtonColor:UIColor?
backButtonTextColor:UIColor?
backButtonFont:UIFont?
backButtonSize:CGSize?
```
## License
Usage is provided under the [MIT License](http://http//opensource.org/licenses/mit-license.php). See LICENSE for the full details.