Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/terminatorover/rgstack
This UI attempts to capture the Quibi Card Stack and the associated User Interaction.
https://github.com/terminatorover/rgstack
card ios stack swift swiftui ui
Last synced: 2 months ago
JSON representation
This UI attempts to capture the Quibi Card Stack and the associated User Interaction.
- Host: GitHub
- URL: https://github.com/terminatorover/rgstack
- Owner: terminatorover
- License: mit
- Created: 2020-05-26T00:40:18.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2021-03-06T04:11:44.000Z (almost 4 years ago)
- Last Synced: 2024-03-16T05:35:11.215Z (9 months ago)
- Topics: card, ios, stack, swift, swiftui, ui
- Language: Swift
- Homepage:
- Size: 3.67 MB
- Stars: 112
- Watchers: 5
- Forks: 14
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# RGStack
This UI attempts to capture the Quibi Card Stack and the associated User Interaction.
![Demo](RGStack.gif)
### Required
A View that conforms to the `ConfigurableCard` protocolRGStack is available through [CocoaPods](http://cocoapods.org). To install it, simply add the following line to your Podfile:
```ruby
pod 'RGStack'
```### Simplest Setup
```swift
import RGStackstruct ContentView: View {
let demos: [Demo]
var body: some View {
RGStack(data: demos, size: .init(width: 320, height: 530))//convenience initializer
}
}
```### More configuration
Use the CardInfo, which is passed to the RGStack initializer, to control more aspects of the UI Layout
```swift
struct CardInfo {
let size: CGSize
let gapDistance: CGFloat
let minScaleForBackCard: CGFloat
let visibleFractionOfBottomCard: CGFloat
}
```A full Demo is included in the `ContentView` of the Project.
## License
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)