Swiftpack.co - EurekaCommunity/SplitRow as Swift Package

Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
EurekaCommunity/SplitRow
A row for Eureka to put two rows side by side into the same UITableViewCell
.package(url: "https://github.com/EurekaCommunity/SplitRow.git", from: "2.2.0")

SplitRow

A row for Eureka to put two rows side by side into the same UITableViewCell.

Platform iOS Swift 5 compatible Carthage compatible CocoaPods compatible License: MIT

Contents

Introduction

SplitRow is a custom row for Eureka designed to put two rows side by side into the same UITableViewCell.

Installation

CocoaPods

CocoaPods is a dependency manager for Cocoa projects.

Specify Eureka into your project's Podfile:

source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '9.3'
use_frameworks!

pod 'SplitRow'

Then run the following command:

$ pod install

Carthage

Carthage is a simple, decentralized dependency manager for Cocoa.

Specify SplitRow into your project's Cartfile:

github "EurekaCommunity/SplitRow" ~> 2.1.1

Then run the following command:

$ carthage bootstrap --platform iOS

Usage

import Eureka
import SplitRow

class ViewController: FormViewController {

    override func viewDidLoad() {
        super.viewDidLoad()

        form +++ Section()
            <<< SplitRow<PushRow<String>,TextRow>(){
                $0.rowLeft = PushRow<String>(){
                    $0.selectorTitle = "E-Mail"
                    $0.options = ["Private","Work","Others"]
                }

                $0.rowRight = TextRow(){
                    $0.placeholder = "E-Mail"
                }

            }.onChange{
                print("SplitRow.onChange:","left:",$0.value?.left,"right:",$0.value?.right)
            }
    }
}

Example by changing the percentage of the row on the right

import Eureka
import SplitRow

class ViewController: FormViewController {

    override func viewDidLoad() {
        super.viewDidLoad()

        form +++ Section()
            <<< SplitRow<PushRow<String>,TextRow>(){
                $0.rowLeftPercentage = 0.5

                $0.rowLeft = PushRow<String>(){
                    $0.selectorTitle = "E-Mail"
                    $0.options = ["Private","Work","Others"]
                }
				
                $0.rowRight = TextRow(){
                    $0.placeholder = "E-Mail"
                }

            }.onChange{
                print("SplitRow.onChange:","left:",$0.value?.left,"right:",$0.value?.right)
            }
    }
}

Requirements

  • iOS 9.3+
  • Xcode 9.0+
  • Eureka ~> 5.3.3

Getting involved

  • If you want to contribute please feel free to submit pull requests.
  • If you have a feature request please open an issue.

Authors

A-Z

GitHub

link
Stars: 54
Last commit: 1 week ago

Ad: Job Offers

iOS Software Engineer @ Perry Street Software
Perry Street Software is Jack’d and SCRUFF. We are two of the world’s largest gay, bi, trans and queer social dating apps on iOS and Android. Our brands reach more than 20 million members worldwide so members can connect, meet and express themselves on a platform that prioritizes privacy and security. We invest heavily into SwiftUI and using Swift Packages to modularize the codebase.

Submit a free job ad (while I'm testing this). The analytics numbers for this website are here.

Dependencies

Release Notes

2.2.0
22 weeks ago
  • Fixes #37: Add validation support to SplitRow - thanks @wimzee-rcheng :tada: :tada: :tada:
  • Fixes #50: Adds tagged to release for full support of Swift Package Manager

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics