GithubHelp home page GithubHelp logo

kwokpingl / bryxbanner Goto Github PK

View Code? Open in Web Editor NEW

This project forked from bryx-inc/bryxbanner

0.0 2.0 0.0 796 KB

A lightweight dropdown notification for iOS 7+, in Swift.

License: MIT License

Ruby 1.77% Swift 75.31% Objective-C 1.52% Shell 21.40%

bryxbanner's Introduction

BRYXBanner

Version Carthage compatible License Platform

A lightweight dropdown banner for iOS 7+.

Example

Usage

Import BRYXBanner

import BRYXBanner

Create a banner using the designated initializer.

let banner = Banner(title: "Image Notification", subtitle: "Here's a great image notification.", image: UIImage(named: "Icon"), backgroundColor: UIColor(red:48.00/255.0, green:174.0/255.0, blue:51.5/255.0, alpha:1.000))
banner.dismissesOnTap = true
banner.show(duration: 3.0)

If you want the banner to persist until you call .dismiss(), leave the argument out of the call to .show()

To run the example project, clone the repo, and run pod install from the Example directory first.

Requirements

Demo project requires iOS 8, though BRYXBanner works on iOS 7+.

Installation

BRYXBanner is available through CocoaPods and Carthage.

Using CocoaPods

To install it, simply add the following line to your Podfile:

pod 'BRYXBanner'

If you need to support iOS 7, just copy Banner.swift into your Xcode project.

Using Carthage

Create a Cartfile in your project directory and add the following line.

github "bryx-inc/BRYXBanner"

Run carthage update from the command line. This will build the framework. The framework will be within Carthage/build/BRYXBanner.framework.

Add the framework to your project by going to your app's targets and selecting the General tab. Drag the built framework onto Linked Frameworks and Libraries

Go to the Build Phases tab, click the + sign and add a new run script phase. Then add the following:

/usr/local/bin/carthage copy-frameworks

to the box under Shell. Finally click + to add a new input file. Replace the default with:

$(SRCROOT)/Carthage/Build/iOS/BRYXBanner.framework

Now build and run. You're all set! More information on Carthage is available here.

Documentation

Docs are automatically generated and available right here.

Authors

Harlan Haskins (@harlanhaskins) Adam Binsz (@adambinsz)

License

BRYXBanner is available under the MIT license. See the LICENSE file for more info.

bryxbanner's People

Contributors

3x14 avatar adambinsz avatar alexpersian avatar amosavian avatar anthonymdev avatar ashishawaghad avatar askielboe avatar bennettsmith avatar drewg233 avatar guarani avatar harlanhaskins avatar iankeen avatar jettf avatar makoni avatar nmanoogian avatar promero-carecloud avatar vfuc avatar zntfdr avatar

Watchers

 avatar  avatar

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.