{"version":3,"sources":["dot.pims.toastr-wrapper.js"],"names":["Toast","toastType","css","message","title","options","length","this","toastr","toastConstants","toastPositionCss","bottomRight","type","info","isSticky","closeButton","debug","newestOnTop","progressBar","positionClass","preventDuplicates","preventOpenDuplicates","tapToDismiss","onclick","showDuration","hideDuration","timeOut","extendedTimeOut","showEasing","hideEasing","showMethod","hideMethod","makeSticky","trueOrFalse","setDebugLogging","shownOrHiddenHandler","showToast","success","warning","error","topRight","bottomLeft","topLeft","topFullWidth","bottomFullWidth","topCenter","topCenterNoOverlap","bottomCenter"],"mappings":"AAAA,aA8BA,SAASA,MAAMC,EAAWC,EAAKC,EAASC,EAAOC,GAC9C,OAAKF,GAAYA,EAAQG,QAGzBC,KAAKH,MAAQA,EACbG,KAAKJ,QAAUA,EACfI,KAAKL,IAAMA,GAAOM,OAAOC,eAAeC,iBAAiBC,YACzDJ,KAAKK,KAAOX,GAAaO,OAAOC,eAAeR,UAAUY,KACzDN,KAAKO,UAAW,EAChBP,KAAKF,QAAUA,GAAW,CACzBU,aAAe,EACfC,OAAS,EACTC,aAAe,EACfC,aAAe,EACfC,cAAiBZ,KAAKL,IACtBkB,mBAAqB,EACrBC,uBAAyB,EACzBC,cAAgB,EAChBC,QAAWhB,KAAKgB,QAChBC,aAAgB,MAChBC,aAAgB,OAChBC,QAAWnB,KAAKO,SAAW,IAAM,OACjCa,gBAAmBpB,KAAKO,SAAW,IAAM,OACzCc,WAAc,QACdC,WAAc,SACdC,WAAc,SACdC,WAAc,WAEfxB,KAAKyB,WAAa,SAAUC,GAC3B1B,KAAKF,QAAQqB,QAAUO,EAAc,IAAM,OAC3C1B,KAAKF,QAAQsB,gBAAkBM,EAAc,IAAM,OACnD1B,KAAKF,QAAQiB,cAAgBW,EAC7B1B,KAAKO,SAAWmB,CACjB,EACA1B,KAAK2B,gBAAkB,SAASD,GAC/B1B,KAAKF,QAAQW,MAAQiB,CACtB,EACA1B,KAAK4B,qBAAuB,WAAY,EACxC5B,KAAKgB,QAAU,WAAa,EAC5BhB,KAAK6B,UAAY,WAIhB,OAAO5B,OAAOD,KAAKK,MAAML,KAAKJ,QAASI,KAAKH,MAAOG,KAAKF,QAEzD,EACOE,MA5CC,IA6CT,CA3EAC,OAAOC,eAAiB,CACvBR,UAAW,CACVoC,QAAS,UACTxB,KAAM,OACNyB,QAAS,UACTC,MAAO,SAER7B,iBAAkB,CACjB8B,SAAU,kBACV7B,YAAa,qBACb8B,WAAY,oBACZC,QAAS,iBACTC,aAAc,mBACdC,gBAAiB,0BACjBC,UAAW,mBACXC,mBAAoB,0CACpBC,aAAc","file":"dot.pims.toastr-wrapper.min.js","sourcesContent":["/// \r\n\r\ntoastr.toastConstants = {\r\n\ttoastType: {\r\n\t\tsuccess: \"success\",\r\n\t\tinfo: \"info\",\r\n\t\twarning: \"warning\",\r\n\t\terror: \"error\"\r\n\t},\r\n\ttoastPositionCss: {\r\n\t\ttopRight: \"toast-top-right\",\r\n\t\tbottomRight: \"toast-bottom-right\",\r\n\t\tbottomLeft: \"toast-bottom-left\",\r\n\t\ttopLeft: \"toast-top-left\",\r\n\t\ttopFullWidth: \"toast-full-width\",\r\n\t\tbottomFullWidth: \"toast-bottom-full-width\",\r\n\t\ttopCenter: \"toast-top-center\",\r\n\t\ttopCenterNoOverlap: \"toast-top-centered-horizontal-nooverlap\",\r\n\t\tbottomCenter: \"toast-bottom-center\"\r\n\t}\r\n};\r\n\r\n/**\r\n * A wrapper around the toastr JavaScript library: https://github.com/CodeSeven/toastr\r\n * @param {toastr.toastConstants} toastType the toastConstants value for the type of toast\r\n * @param {string} css string containing the position CSS or by default \"toast-bottom-right\". Valid values in toastr.toastConstants.toastPositionCss.\r\n * @param {string} message the toast message\r\n * @param {string} title the title for the toast\r\n * @param {object} options the options for creating the toast\r\n */\r\nfunction Toast(toastType, css, message, title, options) {\r\n\tif (!message || !message.length) {\r\n\t\treturn null;\r\n\t}\r\n\tthis.title = title;\r\n\tthis.message = message;\r\n\tthis.css = css || toastr.toastConstants.toastPositionCss.bottomRight;\r\n\tthis.type = toastType || toastr.toastConstants.toastType.info;\r\n\tthis.isSticky = false;\r\n\tthis.options = options || {\r\n\t\t\"closeButton\": false,\r\n\t\t\"debug\": false,\r\n\t\t\"newestOnTop\": true,\r\n\t\t\"progressBar\": true,\r\n\t\t\"positionClass\": this.css,\r\n\t\t\"preventDuplicates\": true,// prevent duplicates of the last toast\r\n\t\t\"preventOpenDuplicates\": true, // prevent duplicates of open toasts\r\n\t\t\"tapToDismiss\": true,\r\n\t\t\"onclick\": this.onclick,\r\n\t\t\"showDuration\": \"300\",\r\n\t\t\"hideDuration\": \"1000\",\r\n\t\t\"timeOut\": this.isSticky ? \"0\" : \"5000\",\r\n\t\t\"extendedTimeOut\": this.isSticky ? \"0\" : \"1000\",\r\n\t\t\"showEasing\": \"swing\",\r\n\t\t\"hideEasing\": \"linear\",\r\n\t\t\"showMethod\": \"fadeIn\",\r\n\t\t\"hideMethod\": \"fadeOut\"\r\n\t};\r\n\tthis.makeSticky = function (trueOrFalse) {\r\n\t\tthis.options.timeOut = trueOrFalse ? \"0\" : \"5000\";\r\n\t\tthis.options.extendedTimeOut = trueOrFalse ? \"0\" : \"5000\";\r\n\t\tthis.options.tapToDismiss = !trueOrFalse;\r\n\t\tthis.isSticky = trueOrFalse;\r\n\t};\r\n\tthis.setDebugLogging = function(trueOrFalse) {\r\n\t\tthis.options.debug = trueOrFalse;\r\n\t};\r\n\tthis.shownOrHiddenHandler = function() {}; // set to subscribe to toastr's published events\r\n\tthis.onclick = function() { };\r\n\tthis.showToast = function() {\r\n//\t\ttoastr.options = this.options;\r\n//\t\ttoastr.options = $.extend(true, {}, this.options);\r\n\t\t//toastr.options.onclick = this.onclick;\r\n\t\treturn toastr[this.type](this.message, this.title, this.options);\r\n\t\t//return toast === undefined ? false : toast; // duplicates return undefined\r\n\t};\r\n\treturn this;\r\n}\r\n"]}