All Projects → atljeremy → Jfminimalnotifications

atljeremy / Jfminimalnotifications

Licence: mit
An iOS UIView for presenting a minimalistic notification that doesn't block the UI and is highly configurable.

Projects that are alternatives of or similar to Jfminimalnotifications

Lnnotificationsui
A framework for displaying notifications similar to Apple's iOS 8 and iOS 9 notifications.
Stars: ✭ 803 (-16.09%)
Mutual labels:  notifications
Noti
Receive Android notifications on your mac. (w/PushBullet) ⛺
Stars: ✭ 845 (-11.7%)
Mutual labels:  notifications
React Notie
Simple notifications for react
Stars: ✭ 27 (-97.18%)
Mutual labels:  notifications
Uuwaveview
[iOS]带有波形效果的UI控件,可自定义波形线条的数量、颜色、振幅、传播速度等各种参数。
Stars: ✭ 18 (-98.12%)
Mutual labels:  customizable
Shortstories
Interactive stories told through App Shortcuts and Notifications
Stars: ✭ 26 (-97.28%)
Mutual labels:  notifications
Just Read
A customizable read mode web extension.
Stars: ✭ 874 (-8.67%)
Mutual labels:  customizable
Burnttoast
Module for creating and displaying Toast Notifications on Microsoft Windows 10.
Stars: ✭ 796 (-16.82%)
Mutual labels:  notifications
React Forms
Form Rendering Library written in React
Stars: ✭ 29 (-96.97%)
Mutual labels:  customizable
Swifteventbus
A publish/subscribe EventBus optimized for iOS
Stars: ✭ 937 (-2.09%)
Mutual labels:  notifications
Huginn
Create agents that monitor and act on your behalf. Your agents are standing by!
Stars: ✭ 33,694 (+3420.79%)
Mutual labels:  notifications
Toot Relay
Relay that forwards web push notifications to APNs, built for Toot!.app but usable for anyone.
Stars: ✭ 18 (-98.12%)
Mutual labels:  notifications
Yii2 Slack Log
Pretty Slack log target for Yii 2
Stars: ✭ 24 (-97.49%)
Mutual labels:  notifications
Laravel Smsgateway Notification Channel
SMS Gateway notification channel for Laravel
Stars: ✭ 13 (-98.64%)
Mutual labels:  notifications
Angularfire
The official Angular library for Firebase.
Stars: ✭ 7,029 (+634.48%)
Mutual labels:  notifications
Announcementcenter
📢 Announcement Center for Nextcloud
Stars: ✭ 28 (-97.07%)
Mutual labels:  notifications
Animatedbottombar
A customizable and easy to use BottomBar navigation view with sleek animations, with support for ViewPager, ViewPager2, NavController, and badges.
Stars: ✭ 797 (-16.72%)
Mutual labels:  customizable
Noty
⛔️ DEPRECATED - Dependency-free notification library that makes it easy to create alert - success - error - warning - information - confirmation messages as an alternative the standard alert dialog.
Stars: ✭ 6,725 (+602.72%)
Mutual labels:  notifications
Autocrawler
Google, Naver multiprocess image web crawler (Selenium)
Stars: ✭ 957 (+0%)
Mutual labels:  customizable
Mako
A lightweight Wayland notification daemon
Stars: ✭ 944 (-1.36%)
Mutual labels:  notifications
Xmedianotificationtrackselector
Xposed module for Android that allows you to select next track from the MediaStyle Notification
Stars: ✭ 20 (-97.91%)
Mutual labels:  notifications

JFMinimalNotification

This is an iOS UIView for presenting a beautiful notification that is highly configurable and works for both iPhone and iPad. JFMinimalNotification is only available in ARC and targets iOS 7.0+.

CocoaPods CocoaPods CocoaPods CocoaPods CocoaPods

Looking for an Android version? Garrett Franks created one and it's awesome, check it out: https://github.com/gfranks/GFMinimalNotifications

What It Looks Like:

Example Example

See a short video of this control here: https://www.youtube.com/watch?v=jDYC-NYKl9A

Screen Shots

Examples

Installation:

CocoaPods

pod 'JFMinimalNotifications', '~> 0.0.8'

Directly include source into your projects

  • Simply copy the source files from the "JFMinimalNotification" folder into your project.
  • In your application's project app target settings, find the "Build Phases" section and open the "Link Binary With Libraries" block and click the "+" button and select the "CoreGraphics.framework".

How To Use It:

Basic Example

- (void)viewDidLoad
{
    [super viewDidLoad];
    
    /**
     * Create the notification
     */
    self.minimalNotification = [JFMinimalNotification notificationWithStyle:JFMinimalNotificationStyleDefault title:@"This is my awesome title" subTitle:@"This is my awesome sub-title"];
    
    /**
     * Set the desired font for the title and sub-title labels
     * Default is System Normal
     */
    UIFont* titleFont = [UIFont fontWithName:@"STHeitiK-Light" size:22];
    [self.minimalNotification setTitleFont:titleFont];
    UIFont* subTitleFont = [UIFont fontWithName:@"STHeitiK-Light" size:16];
    [self.minimalNotification setSubTitleFont:subTitleFont];

    /**
     * Set any necessary edge padding as needed
     */
    self.minimalNotification.edgePadding = UIEdgeInsetsMake(0, 0, 10, 0);

    /**
     * Add the notification to a view
     */
    [self.view addSubview:self.minimalNotification];
}

/**
 * Showing the notification from a button handler
 */
- (IBAction)show:(id)sender {
    [self.minimalNotification show];
}

/**
 * Hiding the notification from a button handler
 */
- (IBAction)dismiss:(id)sender {
    [self.minimalNotification dismiss];
}

Constructors / Options

/**
 * Note: passing a dismissalDelay of 0 means the notification will NOT be automatically dismissed, you will need to 
 * dismiss the notification yourself by calling -dismiss on the notification object. If you pass a dismissalDelay 
 * value greater than 0, this will be the length of time the notification will remain visisble before being 
 * automatically dismissed.
 */
 
// With dismissalDelay
self.minimalNotification = [JFMinimalNotification notificationWithStyle:JFMinimalNotificationStyleError title:@"This is my awesome title" subTitle:@"This is my awesome sub-title" dismissalDelay:3.0];
 
// Without dismissalDelay and with touchHandler
self.minimalNotification = [JFMinimalNotification notificationWithStyle:JFMinimalNotificationStyleError title:@"This is my awesome title" subTitle:@"This is my awesome sub-title" dismissalDelay:0.0 touchHandler:^{
    [self.minimalNotification dismiss];
}];
// Available Styles
typedef NS_ENUM(NSInteger, JFMinimalNotificationStyle) {
    JFMinimalNotificationStyleDefault,
    JFMinimalNotificationStyleError,
    JFMinimalNotificationStyleSuccess,
    JFMinimalNotificationStyleInfo,
    JFMinimalNotificationStyleWarning,
    
    /**
     * @return Used to get a title and subtitle, no accessory views, and white bg with black label text. Use the .bakgroundColor property on the notification to set the desired background color and .textColor property on the titleLabel and subTitleLabel UILabel's to change text color.
     */
    JFMinimalNotificationStyleCustom,
    
    /**
     * @return A dark blur with vibrancy effect in the bakground with white label text.
     */
    JFMinimalNotificationStyleBlurDark,
    
    /**
     * @return A light blur with vibrancy effect in the bakground with black label text.
     */
    JFMinimalNotificationStyleBlurLight
};

Please see the example project include in this repo for an example of how to use this notification.

Delegate Methods:

- (void)minimalNotificationWillShowNotification:(JFMinimalNotification*)notification;
- (void)minimalNotificationDidShowNotification:(JFMinimalNotification*)notification;
- (void)minimalNotificationWillDisimissNotification:(JFMinimalNotification*)notification;
- (void)minimalNotificationDidDismissNotification:(JFMinimalNotification*)notification;

License

Copyright (c) 2012 Jeremy Fox (jeremyfox.me). All rights reserved.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].