OSCoachmarkView [Under Development]
A lightweight framework for displaying coachmarks in iOS apps. Built in pure Swift
Showcase
Standard List Coachmark
A compact coachmark which is generally used in list views. Here's a demo of what this looks like,
Appstore coachmark
A coachmark similar to the one used on the appstore product page.
Installation
TODO add cocoapods and carthage here
Usage
You can use any of the preset coachmarks using OSListCoachmarkGenerator or create any custom view in the same fashion. Here is how you would embed your custom view inside the coachmark.
let view = CustomCoachmarkView()
let coachmarkView = OSCoachmarkView()
coachmarkView.attachedView = viewSizing of the above custom coachmark will be based on autolayout subject to min/max constraints. To position the coachmark relative to the view, you can write your own logic to show/hide the coachmark or you can use OSCoachmarkPresenter to do this. Here's an example of what this might look like -
let coachmarkPresenter = OSCoachmarkPresenter()
coachmarkPresenter.view = coachmarkView
coachmarkPresenter.attachToView(self.view, anchor: .bottom)OSCoachmarkPresenter objects can attach a coachmark to a given view with two modes - top and bottom. All animation and presentation logic is taken care of with you only having to call show() and hide() based on any logic you choose.
// Show
self.coachmarkPresenter.show()
//Hide
self.coachmarkPresenter.hide()Checkout the example Xcode Project in the Example folder which has a demo with all three classes in action
Additional Features
- Added Blur support in OSListCoachmarkView
- Optional loader in OSListCoachmarkView
Documentation
You can find the reference docs under OSCoachmarkView/docs/index.html
Requirements
- iOS 11.0+
- Xcode 9
- Swift 4
Contributing
All help is welcome. Open an issue or even better submit a pull request
Author
Aamir Anwar @aamiranwarr Feel free to reach out to me on twitter!
License
OSListCoachmark is released under the MIT license. See LICENSE for more details.
Todo
- Abstract out presenter logic
- Add animation options to both top and bottom modes
- Add blur support
- Create example coachmarks using the Factory Pattern
- Add Cocoapod/Carthage support
- Polish README
- Add Travis Support
- Generate documentation



