All Projects → miscavage → Alert

miscavage / Alert

Licence: mit
⚠️ Alert is a simple notification that appears on the top of the screen.

Projects that are alternatives of or similar to Alert

Spstorkcontroller
Now playing controller from Apple Music, Mail & Podcasts Apple's apps.
Stars: ✭ 2,494 (+2107.08%)
Mutual labels:  apple, alert
React Popup
React popup component
Stars: ✭ 198 (+75.22%)
Mutual labels:  component, alert
Alerttoast
Create Apple-like alerts & toasts using SwiftUI
Stars: ✭ 151 (+33.63%)
Mutual labels:  apple, alert
Nativepopup
Clone of Apple iOS App's feedback popup, and easily customizable.
Stars: ✭ 247 (+118.58%)
Mutual labels:  apple, alert
SPStorkController
Now playing controller from Apple Music, Mail & Podcasts Apple's apps.
Stars: ✭ 2,515 (+2125.66%)
Mutual labels:  apple, alert
Awloader
AWLoader is a UI Component that allows you to integrate loader that fits your needs within your app.
Stars: ✭ 11 (-90.27%)
Mutual labels:  apple, component
Statusalert
Display Apple system-like self-hiding status alerts. It is well suited for notifying user without interrupting user flow in iOS-like way.
Stars: ✭ 809 (+615.93%)
Mutual labels:  apple, alert
Spalert
Native alert from Apple Music & Feedback. Contains Done, Heart & Message and other presets.
Stars: ✭ 1,014 (+797.35%)
Mutual labels:  apple, alert
Conbini
Publishers, operators, and subscribers to supplement Combine.
Stars: ✭ 109 (-3.54%)
Mutual labels:  apple
React Multi Select
A Multi Select component built with and for React
Stars: ✭ 111 (-1.77%)
Mutual labels:  component
Polyfill Php56
This component provides functions unavailable in releases prior to PHP 5.6.
Stars: ✭ 1,470 (+1200.88%)
Mutual labels:  component
Var Exporter
The VarExporter component allows exporting any serializable PHP data structure to plain PHP code. While doing so, it preserves all the semantics associated with the serialization mechanism of PHP (__wakeup, __sleep, Serializable).
Stars: ✭ 1,616 (+1330.09%)
Mutual labels:  component
Ember Toggle
Checkbox based Toggle Switches for Ember
Stars: ✭ 111 (-1.77%)
Mutual labels:  component
Maz Ui
Stand-alone components library to build your interfaces with Vue.JS & Nuxt.JS
Stars: ✭ 109 (-3.54%)
Mutual labels:  component
Vue Highcharts
The Component of Vue 2.x for highcharts
Stars: ✭ 112 (-0.88%)
Mutual labels:  component
Net Core Push Notifications
Lightweight .NET Core Push Notifications for Android and iOS
Stars: ✭ 105 (-7.08%)
Mutual labels:  apple
Quist Ui
快应用UI组件库 https://jdsecretfe.github.io/quist-ui/
Stars: ✭ 108 (-4.42%)
Mutual labels:  component
React Lego
一种特别注重扩展和复用的 React 组件编写规则。
Stars: ✭ 112 (-0.88%)
Mutual labels:  component
Zhpopupcontroller
Help you pop up custom views easily. and support pop-up animation, layout position, mask effect and gesture interaction etc.
Stars: ✭ 1,481 (+1210.62%)
Mutual labels:  alert
Laravel Alert
A Bootstrap alert helper for Laravel
Stars: ✭ 110 (-2.65%)
Mutual labels:  alert

Alert

• Screenshots and Gifs

SS1 SS2 SS3

• Installation

Just drag and drop the "Alert" folder into your project, and make sure you check the "Copy items into destination group's folder" box. Then import Alert.h wherever you need it. If you want delegate methods such as AlertWillAppear or AlertDidDisappear then import the AlertDelegate wherever you need it as well.

#import "Alert.h"

@interface ViewController () <AlertDelegate>

• Creating Alerts

Creating an Alert is easy: Add a title, and a duration (in seconds) and that's it. If you want your alert to be endless you can simply put "0.0" in the duration and you can dismiss it manually.

    Alert *alert = [[Alert alloc] initWithTitle:@"I'm an alert!" duration:1.0 completion:^{
        //Custom code here after Alert disappears
    }];
    [alert setDelegate:self] //Optional - if you want delegate methods
    [alert showAlert];

• Setting Alert Visual Attributes

- Alert colors

You can set Alert's background and title color. Use AlertTypes if you want to use our custom colors.

[alert setBackgroundColor:[UIColor whiteColor]];
[alert setTitleColor:[UIColor blackColor]];

• Setting Incoming and Outgoing Transitions

- Incoming Transitions

Alert has 7 incoming transition types that can be used to add an animation while presenting your Alert.

[alert setIncomingTransition:AlertIncomingTransitionTypeFlip];
- Outgoing Transitions

Alert has 7 outgoing transition types that can be used to add an animation while dismissing your Alert.

[alert setOutgoingTransition:AlertOutgoingTransitionTypeSlideToTop];
- Bounces

Do you want your Alert to bounce when it is transitioning in or do you want smooth sliding? You can be the judge of that.

[alert setBounces:bounces];
- Status Bar

If you don't want the status bar to be shown when you show your Alert, you can easily hide it. If you chose to do this, you must set "View controller-based status bar appearance" = NO in your Info.plist

[alert setShowStatusBar:YES];
- Alert Types

Alert has 3 types that can be used to color the background of your Alert.

[alert setAlertType:AlertTypeError] //Red
[alert setAlertType:AlertTypeSuccess] //Blue
[alert setAlertType:AlertTypeWarning] //Yellow

• Delegate Methods

- Appear and Disappear

Set Alerts's delegate functions to tell when your Alert is appearing or disappearing.

- (void)alertWillAppear:(Alert *)alert;
- (void)alertDidAppear:(Alert *)alert;
- (void)alertWillDisappear:(Alert *)alert;
- (void)alertDidDisappear:(Alert *)alert;

• To-do

  • Add more transitions
  • Make transitions smoother
  • Fix some issues with the demo

• Say Hi

Tweet at me or something : @markmiscavage.

• License

The MIT License (MIT)

Copyright (c) 2015 Mark Miscavage

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].