Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/we-lib/popup

Popup your dialog
https://github.com/we-lib/popup

Last synced: about 1 month ago
JSON representation

Popup your dialog

Awesome Lists containing this project

README

        

# popup

Popup your dialog

> Fork of [t4t5/sweetalert](https://github.com/t4t5/sweetalert)

Demo:

## Features (vs sweetalert)

- More responsive, margins optimized
- Dialog and icon animation dropped
- SASS looks difficult to me, LESS instead
- Source code cut (748L to 106L), API cleared

## Usage

Popup a warn dialog:

```js
popup({
icon: 'warn',
title: 'Are you sure?',
text: 'You will not be able to recover this imaginary file!',
okBtn: 'Yes, delete it!',
cancelBtn: 'No, cancel plx!'
}, function(ok){ /**/ })
```

For more details:

- [Popup demo source](demo/index.html)
- [t4t5/sweetalert](https://github.com/t4t5/sweetalert)