diff --git a/README.md b/README.md index 60c43b2..57fa022 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ ### About -As of Bootstrap 4.2, [toasts](https://getbootstrap.com/docs/4.2/components/toasts/) have been inroduced and the aim of this plugin is to make them easier to use. +As of Bootstrap 4.2, [toasts](https://getbootstrap.com/docs/4.2/components/toasts/) have been introduced and the aim of this plugin is to make them easier to use. ### Usage @@ -21,7 +21,7 @@ You can pass to the `$.toast` function an object with the settings for your toas | subtitle | Shows in the top right corner of the toast header | N/A | | | content | Shows in the toast body | N/A | | type | Determines the style of the toast based on Bootstrap styles | 'info' | 'info', 'success', 'warning', 'error' -| delay | Determines how the toast will show for | 3000 +| delay | Determines how the toast will show for. Set to -1 to prevent the Toast from closing automatically | 3000 **Note:** If content is omitted, the toast will not have a `.toast-body` and can be used as a small snack which will be shown below in the examples. By default toasts will be positioned in the top right corner and will in the future (hopefully) have other position options. diff --git a/dist/toast.min.js b/dist/toast.min.js index 93d744e..0fa9e61 100644 --- a/dist/toast.min.js +++ b/dist/toast.min.js @@ -1,3 +1 @@ -(function(b){b.toast=function(a,h,g,l,k){b("#toast-container").length||(b("body").prepend('
'),b("#toast-container").append(''));var c="",d="",e="text-muted",f="",m="object"===typeof a?a.title||"":a||"Notice!";h="object"===typeof a?a.subtitle||"":h||"";g="object"===typeof a?a.content||"":g||"";k="object"===typeof a?a.delay||3E3:k||3E3;switch("object"===typeof a?a.type||"":l||"info"){case "info":c="bg-info"; -f=e=d="text-white";break;case "success":c="bg-success";f=e=d="text-white";break;case "warning":case "warn":c="bg-warning";f=e=d="text-white";break;case "error":case "danger":c="bg-danger",f=e=d="text-white"}a='