Latest 1.0.5
Homepage https://github.com/IvanVorobei/SPLarkController
License MIT
Platforms ios 10.0
Authors

SPLarkController

Modal controller with custom tranition. Good variant for implement setting in your app.

Preview GIF is loading 3mb. Please, wait.

SPLarkController

You can download example from AppStore or see video preview. If you want to buy source code of the full app, please go to xcode-shop.com. Price: $200.

SPLarkController

I have a store where I sell applications and modules for Xcode projects. You can find source codes of applications or custom animations / UI. I regularly update the code. Visit my website to see all items for sale: xcode-shop.com. On the website you can find previews and for some items links to AppStore.

SPLarkController

Requirements

Swift 4.2. Ready for use on iOS 10+

Integration

Put Source/SPLarkController folder in your Xcode project. Make sure to enable Copy items if needed and Create groups.

Or via CocoaPods:

pod 'SPLarkController'

How to use

Create controller and call func presentAsLark:

import UIKit
import SPLarkController

class ViewController: UIViewController {

    override func viewDidAppear(_ animated: Bool) {
        super.viewDidAppear(animated)

        let controller = UIViewController()
        self.presentAsLark(controller)
    }
}

If you want customize controller (set custom height and other), create controller and set transitioningDelegate to SPLarkTransitioningDelegate object. Use present or dismiss functions:

let controller = UIViewController()
let transitionDelegate = SPLarkTransitioningDelegate()
controller.transitioningDelegate = transitionDelegate
controller.modalPresentationStyle = .custom
controller.modalPresentationCapturesStatusBarAppearance = true
self.present(controller, animated: true, completion: nil)

Please, do not init SPLarkTransitioningDelegate like this:

controller.transitioningDelegate = SPLarkTransitioningDelegate()

You will get an error about weak property.

Parameters

  • Parameter customHeight sets custom height for modal controller. Default is nil:
    transitionDelegate.customHeight = 350

Snapshots

The project uses a snapshot of the screen in order to avoid compatibility and customization issues. Before controller presentation, a snapshot of the parent view is made, and size and position are changed for the snapshot. Sometimes you will need to update the screenshot of the parent view, for that use static func:

SPLarkController.updatePresentingController(modal: controller)

and pass the controller, which is modal and uses SPLarkTransitioningDelegate

Modal presentation of different controller

If you want to present modal controller on SPLarkController, please set:

controller.modalPresentationStyle = .custom

It’s needed for correct presentation and dismissal of all modal controllers.

My projects

Here I would like to offer you my other projects.

SPStorkController

I created SPStorkController. It is a modal controller like in Mail or Apple Music application. Similar animation and transition. You can see an example of using controller in app in AppStore.

SPLarkController

You can buy source code of this app on xcode-shop.com. Price: $200.

SPPermission

Project SPPermission for managing permissions with customizable visual effects. Beautiful dialog increases the chance of approval (which is important when we request notification). Simple control of this module saves you hours of development. You can start using project with just two lines of code and easy customization!

SPLarkController

License

SPLarkController is released under the MIT license. Check LICENSE.md for details.

Contact

If you need any application or UI to be developed, message me at [email protected] I develop iOS apps and create designs, too. I use swift for development. To request more functionality, you should create a new issue.
Here are my apps in AppStore: first account & second account.

Latest podspec

{
    "name": "SPLarkController",
    "version": "1.0.5",
    "summary": "Modal controller with custom transition",
    "homepage": "https://github.com/IvanVorobei/SPLarkController",
    "source": {
        "git": "https://github.com/IvanVorobei/SPLarkController.git",
        "tag": "1.0.5"
    },
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "Ivan Vorobei": "[email protected]"
    },
    "swift_versions": [
        "4.2",
        "5.0"
    ],
    "platforms": {
        "ios": "10.0"
    },
    "ios": {
        "frameworks": "UIKit"
    },
    "source_files": "Source/SPLarkController/**/*.swift"
}

Pin It on Pinterest

Share This