Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/snail-z/overlaycontroller
OverlayController easily pop your custom view and provide optional transition animation. written in swift 5.0
https://github.com/snail-z/overlaycontroller
actionsheet alert cocoapods drag elastic mask overlay popup-window share sidebar sina swift
Last synced: 3 months ago
JSON representation
OverlayController easily pop your custom view and provide optional transition animation. written in swift 5.0
- Host: GitHub
- URL: https://github.com/snail-z/overlaycontroller
- Owner: snail-z
- License: mit
- Created: 2017-02-27T02:33:05.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2020-08-19T08:16:21.000Z (over 4 years ago)
- Last Synced: 2024-09-26T08:33:47.065Z (5 months ago)
- Topics: actionsheet, alert, cocoapods, drag, elastic, mask, overlay, popup-window, share, sidebar, sina, swift
- Language: Swift
- Homepage:
- Size: 6.11 MB
- Stars: 125
- Watchers: 8
- Forks: 15
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[](https://developer.apple.com/swift/)

OverlayController can easily pop up any custom view. It supports layout positions, optional pop-up animations and user interaction gestures and more. If you need the Objective-C version, please see [here](https://github.com/snail-z/zhPopupController)
## Example
To run the example project, clone the repo, and run `pod install` from the Example directory first.
## Requirements
* Swift 5.0
* iOS 10 or higher## Installation
OverlayController is available through [CocoaPods](https://cocoapods.org). To install
it, simply add the following line to your Podfile:```ruby
pod 'OverlayController', '~> 1.0.1'
```## Usage
```swift
let ovc = OverlayController(view: self.publishView)
ovc.layoutPosition = .center
ovc.presentationStyle = .fade
ovc.willPresentClosure = { [unowned self] (sender) in
self.publishView.presentAnimate()
}
ovc.willDismissClosure = { [unowned self] (sender) in
self.publishView.dismissAnimate()
}
```Support following keyboard popup and hide
Set overlay view priority. default is OverlayLevel.normal by `windowLevel`
## Author
snail-z, [email protected]
## License
OverlayController is available under the MIT license. See the LICENSE file for more info.