Git Product home page Git Product logo

vkpopupview's Introduction

VKPopupView banner

Description

VKPopupView is lightweight and easy to use blurred popup view written in Swift. You will find it very similar to your iOS folders at Springboard (Home screen).

Installation

You can install VKPopupView manually only. Just add content of the VKPopupView folder into your project.

Example project and Live Demo

Example project shows how to you use VKPopupView in a different ways. To test it it, clone the repo and run it from the VKPopupViewExample directory.

Live demo is available at appetize.io

Usage

When I'm saying it is easy to use - it is always true. Please take a look on it:

//// Step 1: Prepare all the staff
// 1.a Init popup
let popup = VKPopupView()

// 1.b Prepare your content
let contentView = UIView(...)

// 1.c Specify initial frame. `VKPopupView` will start appearance from this frame
let rect = CGRect(...)

//// Step 2: Just show it
popup.show(contentView: contentView, withTitle: "My cool title", fromRect: rect)
//// Profit!

You can easily set blur styles for your VKPopupView. Just these two properties in order to get what you need:

var backgroundBlurStyle: UIBlurEffectStyle  = .light
var contentViewBlurStyle: UIBlurEffectStyle = .extraLight

VKPopupViewDelegate

You can handle all stages of VKPopupView appearance with VKPopupViewDelegate. It provides next functions:

@objc optional func popupViewWillShow(_ popupView: VKPopupView)
@objc optional func popupViewDidShow(_ popupView: VKPopupView)
@objc optional func popupViewWillHide(_ popupView: VKPopupView)
@objc optional func popupViewDidHide(_ popupView: VKPopupView)

TODO

  • Customization of the title label
  • Add full-size support for iPad

Author

Vladislav Kovalyov, http://woopss.com/

License

VKPopupView is available under the MIT License. See the LICENSE file for more info.

vkpopupview's People

Stargazers

Eric avatar James Frank avatar Antonio Zaitoun avatar  avatar Moonlight avatar Denis Tretyakov avatar  avatar MohsinAli avatar Carabineiro avatar Narcis avatar Maksim Kudriavtsev avatar samuele coppede avatar André Bohna avatar

Watchers

MohsinAli avatar Carabineiro avatar Maksim Kudriavtsev avatar Vladislav Kovalyov avatar

vkpopupview's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.