text: !function(t){var e={};function n(o){if(e[o])return e[o].exports;var r=e[o]={i:o,l:!1,exports:{}};return t[o].call(r.exports,r,r.exports,n),r.l=!0,r.exports}n.m=t,n.c=e,n.d=function(t,e,o){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:o})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var r in t)n.d(o,r,function(e){return t[e]}.bind(null,r));return o},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="/",n(n.s=9)}({"8oxB":function(t,e){var n,o,r=t.exports={};function i(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function s(t){if(n===setTimeout)return setTimeout(t,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(t){n=i}try{o="function"==typeof clearTimeout?clearTimeout:a}catch(t){o=a}}();var l,c=[],u=!1,d=-1;function f(){u&&l&&(u=!1,l.length?c=l.concat(c):d=-1,c.length&&p())}function p(){if(!u){var t=s(f);u=!0;for(var e=c.length;e;){for(l=c,c=[];++d<e;)l&&l[d].run();d=-1,e=c.length}l=null,u=!1,function(t){if(o===clearTimeout)return clearTimeout(t);if((o===a||!o)&&clearTimeout)return o=clearTimeout,clearTimeout(t);try{o(t)}catch(e){try{return o.call(null,t)}catch(e){return o.call(this,t)}}}(t)}}function m(t,e){this.fun=t,this.array=e}function g(){}r.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)e[n-1]=arguments[n];c.push(new m(t,e)),1!==c.length||u||s(p)},m.prototype.run=function(){this.fun.apply(null,this.array)},r.title="browser",r.browser=!0,r.env={},r.argv=[],r.version="",r.versions={},r.on=g,r.addListener=g,r.once=g,r.off=g,r.removeListener=g,r.removeAllListeners=g,r.emit=g,r.prependListener=g,r.prependOnceListener=g,r.listeners=function(t){return[]},r.binding=function(t){throw new Error("process.binding is not supported")},r.cwd=function(){return"/"},r.chdir=function(t){throw new Error("process.chdir is not supported")},r.umask=function(){return 0}},9:function(t,e,n){t.exports=n("D6hk")},D6hk:function(t,e,n){var o=n("bquW");function r(t){var e=t.val(),n=$("textarea#html-template").val().replace("{{ CONTENT }}",e),o=t.closest(".row").find(".html-preview .content iframe")[0].contentWindow.document;o.open(),o.close(),$("body",o).html(n)}n("oBpX"),$.trumbowyg.svgPath="/trumbowyg/icons.svg",$(".trumbowyg").trumbowyg({autogrowOnEnter:!0,imageWidthModalEdit:!0}).on("tbwchange",function(){r($(this))}),$(document).ready(function(){$(".trumbowyg-modal-box input").each(function(){$(this).addClass("browser-default")}),$(".trumbowyg").each(function(){r($(this))});var t=$("#push_notification_form_schedule");t.change(function(){$(this).prop("checked")?($(".schedule").show(),$(".sendnow").hide()):($(".schedule").hide(),$(".sendnow").show())}),t.trigger("change");var e=$("#push_notification_form_test");function n(){$(".loader-container:not(.page-loader-container)").fadeIn(200);var t=translations.confirmationContent+"\n\n";$.ajax({url:notificationDeviceCountUrl,type:"post",data:{segment:$("#push_notification_form_segment").val(),test:$("#push_notification_form_test:checked").length>0,testDevices:$(".row.test table tbody input:checkbox:checked").map(function(){return $(this).val()}).get()},success:function(e){if($(".loader-container:not(.page-loader-container)").fadeOut(200),0==$("#push_notification_form_segment").val()||void 0===$("#push_notification_form_segment").val()){var n=$("#push_notification_form_test:checked").length>0?translations.selectedTestDevices:translations.allDevices;t+=translations.segment+": "+n+"\n"}else t+=translations.segment+": "+$("#push_notification_form_segment option:selected").text()+"\n";t+=translations.deviceCount+": "+e.data.recipients+"\n",o.confirm(translations.confirmTitle,t,function(){$(".loader-container:not(.page-loader-container)").fadeIn(200),$('form[name="push_notification_form"]').submit()})}})}function i(t){return $(t).filter(function(){return!$(this).val()}).length}e.change(function(){$(this).prop("checked")?$(".test").show():$(".test").hide()}),e.trigger("change"),$("#push_notification_form_sendNow, #push_notification_form_sendLater").click(function(){return forms.removeAlertsFromTabs(),function(){var t=!0;$("ul.validation-message:not(.message-inconsistent)").remove(),$("input.invalid").removeClass("invalid");var e=$(".is-fallback-language");""===e.find("input.title").val()&&(forms.markInvalid(e.find("input.title")),t=!1);$("input.title, input.content").each(function(){$(this).val().length>$(this).data("length")&&(forms.markInvalid($(this),translations.maximumCharacterCountExceeded),t=!1)});var n=$("select.click-action").val();1==n&&(""===e.find("input.click-action-url").val()&&(forms.markInvalid(e.find("input.click-action-url")),t=!1),$("input.click-action-url").each(function(){""===$(this).val()||/^https?:\/\//.test($(this).val())||$(this).val("http://"+$(this).val())}));2==n&&""===e.find("textarea.click-action-html").val()&&(forms.markInvalid(e.find(".trumbowyg-box")),t=!1);var o=$("#push_notification_form_segment");""===o.val()&&(forms.markInvalid(o.closest(".select-wrapper")),t=!1);if($("input#push_notification_form_schedule").is(":checked")){var r=$("input#push_notification_form_scheduledSending_date"),i=$("input#push_notification_form_scheduledSending_time");""===r.val()&&(forms.markInvalid(r),t=!1),""===i.val()&&(forms.markInvalid(i),t=!1);""===r.val()||/[0-3]{1}[0-9]{1}-[0-1]{1}[0-9]{1}-[2-9]{1}[0-9]{3}/.test(r.val())||(forms.markInvalid(r,translations.invalidFormat),t=!1),""===i.val()||/[0-2]{1}[0-9]{1}:[0-5]{1}[0-9]{1}/.test(i.val())||(forms.markInvalid(i,translations.invalidFormat),t=!1)}return t}()?(!function(){var t=!0;$("ul.message-inconsistent").remove();var e=$("li.tab").length,n=e-i("input.title");n>0&&n<e&&(forms.markInconsistent("input.title"),t=!1);var o=e-i("input.content");o>0&&o<e&&(forms.markInconsistent("input.content"),t=!1);var r=$("select.click-action").val();if(r>0){var a="1"===r?"input.click-action-url":"textarea.click-action-html",s="2"===r,l=e-i(a);if(l>0&&l<e){var c=s?".trumbowyg-box":a;forms.markInconsistent(c),t=!1}}return t}()?o.confirm(translations.inconsistentTitle,translations.inconsistentContent,function(){n()},void 0,translations.sendAnyway):n(),!1):(o.warning(translations.invalidFormTitle,translations.invalidFormContent),!1)})})},GUC0:function(t,e,n){(function(e,n){t.exports=function(t){function e(o){if(n[o])return n[o].exports;var r=n[o]={i:o,l:!1,exports:{}};return t[o].call(r.exports,r,r.exports,e),r.l=!0,r.exports}var n={};return e.m=t,e.c=n,e.d=function(t,n,o){e.o(t,n)||Object.defineProperty(t,n,{configurable:!1,enumerable:!0,get:o})},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=8)}([function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o="swal-button";e.CLASS_NAMES={MODAL:"swal-modal",OVERLAY:"swal-overlay",SHOW_MODAL:"swal-overlay--show-modal",MODAL_TITLE:"swal-title",MODAL_TEXT:"swal-text",ICON:"swal-icon",ICON_CUSTOM:"swal-icon--custom",CONTENT:"swal-content",FOOTER:"swal-footer",BUTTON_CONTAINER:"swal-button-container",BUTTON:o,CONFIRM_BUTTON:o+"--confirm",CANCEL_BUTTON:o+"--cancel",DANGER_BUTTON:o+"--danger",BUTTON_LOADING:o+"--loading",BUTTON_LOADER:o+"__loader"},e.default=e.CLASS_NAMES},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getNode=function(t){var e="."+t;return document.querySelector(e)},e.stringToNode=function(t){var e=document.createElement("div");return e.innerHTML=t.trim(),e.firstChild},e.insertAfter=function(t,e){var n=e.nextSibling;e.parentNode.insertBefore(t,n)},e.removeNode=function(t){t.parentElement.removeChild(t)},e.throwErr=function(t){throw"SweetAlert: "+(t=(t=t.replace(/ +(?= )/g,"")).trim())},e.isPlainObject=function(t){if("[object Object]"!==Object.prototype.toString.call(t))return!1;var e=Object.getPrototypeOf(t);return null===e||e===Object.prototype},e.ordinalSuffixOf=function(t){var e=t%10,n=t%100;return 1===e&&11!==n?t+"st":2===e&&12!==n?t+"nd":3===e&&13!==n?t+"rd":t+"th"}},function(t,e,n){"use strict";function o(t){for(var n in t)e.hasOwnProperty(n)||(e[n]=t[n])}Object.defineProperty(e,"__esModule",{value:!0}),o(n(25));var r=n(26);e.overlayMarkup=r.default,o(n(27)),o(n(28)),o(n(29));var i=n(0),a=i.default.MODAL_TITLE,s=i.default.MODAL_TEXT,l=i.default.ICON,c=i.default.FOOTER;e.iconMarkup='\n  <div class="'+l+'"></div>',e.titleMarkup='\n  <div class="'+a+'"></div>\n',e.textMarkup='\n  <div class="'+s+'"></div>',e.footerMarkup='\n  <div class="'+c+'"></div>\n'},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(1);e.CONFIRM_KEY="confirm",e.CANCEL_KEY="cancel";var r={visible:!0,text:null,value:null,className:"",closeModal:!0},i=Object.assign({},r,{visible:!1,text:"Cancel",value:null}),a=Object.assign({},r,{text:"OK",value:!0});e.defaultButtonList={cancel:i,confirm:a};var s=function(t){switch(t){case e.CONFIRM_KEY:return a;case e.CANCEL_KEY:return i;default:var n=t.charAt(0).toUpperCase()+t.slice(1);return Object.assign({},r,{text:n,value:t})}},l=function(t,e){var n=s(t);return!0===e?Object.assign({},n,{visible:!0}):"string"==typeof e?Object.assign({},n,{visible:!0,text:e}):o.isPlainObject(e)?Object.assign({visible:!0},n,e):Object.assign({},n,{visible:!1})},c=function(t){var n={};switch(t.length){case 1:n[e.CANCEL_KEY]=Object.assign({},i,{visible:!1});break;case 2:n[e.CANCEL_KEY]=l(e.CANCEL_KEY,t[0]),n[e.CONFIRM_KEY]=l(e.CONFIRM_KEY,t[1]);break;default:o.throwErr("Invalid number of 'buttons' in array ("+t.length+").\n      If you want more than 2 buttons, you need to use an object!")}return n};e.getButtonListOpts=function(t){var n=e.defaultButtonList;return"string"==typeof t?n[e.CONFIRM_KEY]=l(e.CONFIRM_KEY,t):Array.isArray(t)?n=c(t):o.isPlainObject(t)?n=function(t){for(var e={},n=0,o=Object.keys(t);n<o.length;n++){var r=o[n],a=t[r],s=l(r,a);e[r]=s}return e.cancel||(e.cancel=i),e}(t):!0===t?n=c([!0,!0]):!1===t?n=c([!1,!1]):void 0===t&&(n=e.defaultButtonList),n}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=n(2),i=n(0),a=i.default.MODAL,s=i.default.OVERLAY,l=n(30),c=n(31),u=n(32),d=n(33);e.injectElIntoModal=function(t){var e=o.getNode(a),n=o.stringToNode(t);return e.appendChild(n),n};var f=function(t,e){!function(t){t.className=a,t.textContent=""}(t);var n=e.className;n&&t.classList.add(n)};e.initModalContent=function(t){var e=o.getNode(a);f(e,t),l.default(t.icon),c.initTitle(t.title),c.initText(t.text),d.default(t.content),u.default(t.buttons,t.dangerMode)},e.default=function(){var t=o.getNode(s),e=o.stringToNode(r.modalMarkup);t.appendChild(e)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(3),r={isOpen:!1,promise:null,actions:{},timer:null},i=Object.assign({},r);e.resetState=function(){i=Object.assign({},r)},e.setActionValue=function(t){if("string"==typeof t)return a(o.CONFIRM_KEY,t);for(var e in t)a(e,t[e])};var a=function(t,e){i.actions[t]||(i.actions[t]={}),Object.assign(i.actions[t],{value:e})};e.setActionOptionsFor=function(t,e){var n=(void 0===e?{}:e).closeModal,o=void 0===n||n;Object.assign(i.actions[t],{closeModal:o})},e.default=i},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=n(3),i=n(0),a=i.default.OVERLAY,s=i.default.SHOW_MODAL,l=i.default.BUTTON,c=i.default.BUTTON_LOADING,u=n(5);e.openModal=function(){o.getNode(a).classList.add(s),u.default.isOpen=!0},e.onAction=function(t){void 0===t&&(t=r.CANCEL_KEY);var e=u.default.actions[t],n=e.value;if(!1===e.closeModal){var i=l+"--"+t;o.getNode(i).classList.add(c)}else o.getNode(a).classList.remove(s),u.default.isOpen=!1;u.default.promise.resolve(n)},e.getState=function(){var t=Object.assign({},u.default);return delete t.promise,delete t.timer,t},e.stopLoading=function(){for(var t=document.querySelectorAll("."+l),e=0;e<t.length;e++)t[e].classList.remove(c)}},function(t,e){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch(t){"object"==typeof window&&(n=window)}t.exports=n},function(t,e,n){(function(e){t.exports=e.sweetAlert=n(9)}).call(e,n(7))},function(t,e,n){(function(e){t.exports=e.swal=n(10)}).call(e,n(7))},function(t,e,n){"undefined"!=typeof window&&n(11),n(16);var o=n(23).default;t.exports=o},function(t,e,n){var o=n(12);"string"==typeof o&&(o=[[t.i,o,""]]);var r={insertAt:"top",transform:void 0};n(14)(o,r),o.locals&&(t.exports=o.locals)},function(t,e,n){(t.exports=n(13)(void 0)).push([t.i,'.swal-icon--error{border-color:#f27474;-webkit-animation:animateErrorIcon .5s;animation:animateErrorIcon .5s}.swal-icon--error__x-mark{position:relative;display:block;-webkit-animation:animateXMark .5s;animation:animateXMark .5s}.swal-icon--error__line{position:absolute;height:5px;width:47px;background-color:#f27474;display:block;top:37px;border-radius:2px}.swal-icon--error__line--left{-webkit-transform:rotate(45deg);transform:rotate(45deg);left:17px}.swal-icon--error__line--right{-webkit-transform:rotate(-45deg);transform:rotate(-45deg);right:16px}@-webkit-keyframes animateErrorIcon{0%{-webkit-transform:rotateX(100deg);transform:rotateX(100deg);opacity:0}to{-webkit-transform:rotateX(0deg);transform:rotateX(0deg);opacity:1}}@keyframes animateErrorIcon{0%{-webkit-transform:rotateX(100deg);transform:rotateX(100deg);opacity:0}to{-webkit-transform:rotateX(0deg);transform:rotateX(0deg);opacity:1}}@-webkit-keyframes animateXMark{0%{-webkit-transform:scale(.4);transform:scale(.4);margin-top:26px;opacity:0}50%{-webkit-transform:scale(.4);transform:scale(.4);margin-top:26px;opacity:0}80%{-webkit-transform:scale(1.15);transform:scale(1.15);margin-top:-6px}to{-webkit-transform:scale(1);transform:scale(1);margin-top:0;opacity:1}}@keyframes animateXMark{0%{-webkit-transform:scale(.4);transform:scale(.4);margin-top:26px;opacity:0}50%{-webkit-transform:scale(.4);transform:scale(.4);margin-top:26px;opacity:0}80%{-webkit-transform:scale(1.15);transform:scale(1.15);margin-top:-6px}to{-webkit-transform:scale(1);transform:scale(1);margin-top:0;opacity:1}}.swal-icon--warning{border-color:#f8bb86;-webkit-animation:pulseWarning .75s infinite alternate;animation:pulseWarning .75s infinite alternate}.swal-icon--warning__body{width:5px;height:47px;top:10px;border-radius:2px;margin-left:-2px}.swal-icon--warning__body,.swal-icon--warning__dot{position:absolute;left:50%;background-color:#f8bb86}.swal-icon--warning__dot{width:7px;height:7px;border-radius:50%;margin-left:-4px;bottom:-11px}@-webkit-keyframes pulseWarning{0%{border-color:#f8d486}to{border-color:#f8bb86}}@keyframes pulseWarning{0%{border-color:#f8d486}to{border-color:#f8bb86}}.swal-icon--success{border-color:#a5dc86}.swal-icon--success:after,.swal-icon--success:before{content:"";border-radius:50%;position:absolute;width:60px;height:120px;background:#fff;-webkit-transform:rotate(45deg);transform:rotate(45deg)}.swal-icon--success:before{border-radius:120px 0 0 120px;top:-7px;left:-33px;-webkit-transform:rotate(-45deg);transform:rotate(-45deg);-webkit-transform-origin:60px 60px;transform-origin:60px 60px}.swal-icon--success:after{border-radius:0 120px 120px 0;top:-11px;left:30px;-webkit-transform:rotate(-45deg);transform:rotate(-45deg);-webkit-transform-origin:0 60px;transform-origin:0 60px;-webkit-animation:rotatePlaceholder 4.25s ease-in;animation:rotatePlaceholder 4.25s ease-in}.swal-icon--success__ring{width:80px;height:80px;border:4px solid hsla(98,55%,69%,.2);border-radius:50%;box-sizing:content-box;position:absolute;left:-4px;top:-4px;z-index:2}.swal-icon--success__hide-corners{width:5px;height:90px;background-color:#fff;padding:1px;position:absolute;left:28px;top:8px;z-index:1;-webkit-transform:rotate(-45deg);transform:rotate(-45deg)}.swal-icon--success__line{height:5px;background-color:#a5dc86;display:block;border-radius:2px;position:absolute;z-index:2}.swal-icon--success__line--tip{width:25px;left:14px;top:46px;-webkit-transform:rotate(45deg);transform:rotate(45deg);-webkit-animation:animateSuccessTip .75s;animation:animateSuccessTip .75s}.swal-icon--success__line--long{width:47px;right:8px;top:38px;-webkit-transform:rotate(-45deg);transform:rotate(-45deg);-webkit-animation:animateSuccessLong .75s;animation:animateSuccessLong .75s}@-webkit-keyframes rotatePlaceholder{0%{-webkit-transform:rotate(-45deg);transform:rotate(-45deg)}5%{-webkit-transform:rotate(-45deg);transform:rotate(-45deg)}12%{-webkit-transform:rotate(-405deg);transform:rotate(-405deg)}to{-webkit-transform:rotate(-405deg);transform:rotate(-405deg)}}@keyframes rotatePlaceholder{0%{-webkit-transform:rotate(-45deg);transform:rotate(-45deg)}5%{-webkit-transform:rotate(-45deg);transform:rotate(-45deg)}12%{-webkit-transform:rotate(-405deg);transform:rotate(-405deg)}to{-webkit-transform:rotate(-405deg);transform:rotate(-405deg)}}@-webkit-keyframes animateSuccessTip{0%{width:0;left:1px;top:19px}54%{width:0;left:1px;top:19px}70%{width:50px;left:-8px;top:37px}84%{width:17px;left:21px;top:48px}to{width:25px;left:14px;top:45px}}@keyframes animateSuccessTip{0%{width:0;left:1px;top:19px}54%{width:0;left:1px;top:19px}70%{width:50px;left:-8px;top:37px}84%{width:17px;left:21px;top:48px}to{width:25px;left:14px;top:45px}}@-webkit-keyframes animateSuccessLong{0%{width:0;right:46px;top:54px}65%{width:0;right:46px;top:54px}84%{width:55px;right:0;top:35px}to{width:47px;right:8px;top:38px}}@keyframes animateSuccessLong{0%{width:0;right:46px;top:54px}65%{width:0;right:46px;top:54px}84%{width:55px;right:0;top:35px}to{width:47px;right:8px;top:38px}}.swal-icon--info{border-color:#c9dae1}.swal-icon--info:before{width:5px;height:29px;bottom:17px;border-radius:2px;margin-left:-2px}.swal-icon--info:after,.swal-icon--info:before{content:"";position:absolute;left:50%;background-color:#c9dae1}.swal-icon--info:after{width:7px;height:7px;border-radius:50%;margin-left:-3px;top:19px}.swal-icon{width:80px;height:80px;border-width:4px;border-style:solid;border-radius:50%;padding:0;position:relative;box-sizing:content-box;margin:20px auto}.swal-icon:first-child{margin-top:32px}.swal-icon--custom{width:auto;height:auto;max-width:100%;border:none;border-radius:0}.swal-icon img{max-width:100%;max-height:100%}.swal-title{color:rgba(0,0,0,.65);font-weight:600;text-transform:none;position:relative;display:block;padding:13px 16px;font-size:27px;line-height:normal;text-align:center;margin-bottom:0}.swal-title:first-child{margin-top:26px}.swal-title:not(:first-child){padding-bottom:0}.swal-title:not(:last-child){margin-bottom:13px}.swal-text{font-size:16px;position:relative;float:none;line-height:normal;vertical-align:top;text-align:left;display:inline-block;margin:0;padding:0 10px;font-weight:400;color:rgba(0,0,0,.64);max-width:calc(100% - 20px);overflow-wrap:break-word;box-sizing:border-box}.swal-text:first-child{margin-top:45px}.swal-text:last-child{margin-bottom:45px}.swal-footer{text-align:right;padding-top:13px;margin-top:13px;padding:13px 16px;border-radius:inherit;border-top-left-radius:0;border-top-right-radius:0}.swal-button-container{margin:5px;display:inline-block;position:relative}.swal-button{background-color:#7cd1f9;color:#fff;border:none;box-shadow:none;border-radius:5px;font-weight:600;font-size:14px;padding:10px 24px;margin:0;cursor:pointer}.swal-button:not([disabled]):hover{background-color:#78cbf2}.swal-button:active{background-color:#70bce0}.swal-button:focus{outline:none;box-shadow:0 0 0 1px #fff,0 0 0 3px rgba(43,114,165,.29)}.swal-button[disabled]{opacity:.5;cursor:default}.swal-button::-moz-focus-inner{border:0}.swal-button--cancel{color:#555;background-color:#efefef}.swal-button--cancel:not([disabled]):hover{background-color:#e8e8e8}.swal-button--cancel:active{background-color:#d7d7d7}.swal-button--cancel:focus{box-shadow:0 0 0 1px #fff,0 0 0 3px rgba(116,136,150,.29)}.swal-button--danger{background-color:#e64942}.swal-button--danger:not([disabled]):hover{background-color:#df4740}.swal-button--danger:active{background-color:#cf423b}.swal-button--danger:focus{box-shadow:0 0 0 1px #fff,0 0 0 3px rgba(165,43,43,.29)}.swal-content{padding:0 20px;margin-top:20px;font-size:medium}.swal-content:last-child{margin-bottom:20px}.swal-content__input,.swal-content__textarea{-webkit-appearance:none;background-color:#fff;border:none;font-size:14px;display:block;box-sizing:border-box;width:100%;border:1px solid rgba(0,0,0,.14);padding:10px 13px;border-radius:2px;transition:border-color .2s}.swal-content__input:focus,.swal-content__textarea:focus{outline:none;border-color:#6db8ff}.swal-content__textarea{resize:vertical}.swal-button--loading{color:transparent}.swal-button--loading~.swal-button__loader{opacity:1}.swal-button__loader{position:absolute;height:auto;width:43px;z-index:2;left:50%;top:50%;-webkit-transform:translateX(-50%) translateY(-50%);transform:translateX(-50%) translateY(-50%);text-align:center;pointer-events:none;opacity:0}.swal-button__loader div{display:inline-block;float:none;vertical-align:baseline;width:9px;height:9px;padding:0;border:none;margin:2px;opacity:.4;border-radius:7px;background-color:hsla(0,0%,100%,.9);transition:background .2s;-webkit-animation:swal-loading-anim 1s infinite;animation:swal-loading-anim 1s infinite}.swal-button__loader div:nth-child(3n+2){-webkit-animation-delay:.15s;animation-delay:.15s}.swal-button__loader div:nth-child(3n+3){-webkit-animation-delay:.3s;animation-delay:.3s}@-webkit-keyframes swal-loading-anim{0%{opacity:.4}20%{opacity:.4}50%{opacity:1}to{opacity:.4}}@keyframes swal-loading-anim{0%{opacity:.4}20%{opacity:.4}50%{opacity:1}to{opacity:.4}}.swal-overlay{position:fixed;top:0;bottom:0;left:0;right:0;text-align:center;font-size:0;overflow-y:auto;background-color:rgba(0,0,0,.4);z-index:10000;pointer-events:none;opacity:0;transition:opacity .3s}.swal-overlay:before{content:" ";display:inline-block;vertical-align:middle;height:100%}.swal-overlay--show-modal{opacity:1;pointer-events:auto}.swal-overlay--show-modal .swal-modal{opacity:1;pointer-events:auto;box-sizing:border-box;-webkit-animation:showSweetAlert .3s;animation:showSweetAlert .3s;will-change:transform}.swal-modal{width:478px;opacity:0;pointer-events:none;background-color:#fff;text-align:center;border-radius:5px;position:static;margin:20px auto;display:inline-block;vertical-align:middle;-webkit-transform:scale(1);transform:scale(1);-webkit-transform-origin:50% 50%;transform-origin:50% 50%;z-index:10001;transition:opacity .2s,-webkit-transform .3s;transition:transform .3s,opacity .2s;transition:transform .3s,opacity .2s,-webkit-transform .3s}@media (max-width:500px){.swal-modal{width:calc(100% - 20px)}}@-webkit-keyframes showSweetAlert{0%{-webkit-transform:scale(1);transform:scale(1)}1%{-webkit-transform:scale(.5);transform:scale(.5)}45%{-webkit-transform:scale(1.05);transform:scale(1.05)}80%{-webkit-transform:scale(.95);transform:scale(.95)}to{-webkit-transform:scale(1);transform:scale(1)}}@keyframes showSweetAlert{0%{-webkit-transform:scale(1);transform:scale(1)}1%{-webkit-transform:scale(.5);transform:scale(.5)}45%{-webkit-transform:scale(1.05);transform:scale(1.05)}80%{-webkit-transform:scale(.95);transform:scale(.95)}to{-webkit-transform:scale(1);transform:scale(1)}}',""])},function(t,e){function n(t,e){var n=t[1]||"",o=t[3];if(!o)return n;if(e&&"function"==typeof btoa){var r=function(t){return"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(t))))+" */"}(o);return[n].concat(o.sources.map(function(t){return"/*# sourceURL="+o.sourceRoot+t+" */"})).concat([r]).join("\n")}return[n].join("\n")}t.exports=function(t){var e=[];return e.toString=function(){return this.map(function(e){var o=n(e,t);return e[2]?"@media "+e[2]+"{"+o+"}":o}).join("")},e.i=function(t,n){"string"==typeof t&&(t=[[null,t,""]]);for(var o={},r=0;r<this.length;r++){var i=this[r][0];"number"==typeof i&&(o[i]=!0)}for(r=0;r<t.length;r++){var a=t[r];"number"==typeof a[0]&&o[a[0]]||(n&&!a[2]?a[2]=n:n&&(a[2]="("+a[2]+") and ("+n+")"),e.push(a))}},e}},function(t,e,n){function o(t,e){for(var n=0;n<t.length;n++){var o=t[n],r=f[o.id];if(r){r.refs++;for(var i=0;i<r.parts.length;i++)r.parts[i](o.parts[i]);for(;i<o.parts.length;i++)r.parts.push(u(o.parts[i],e))}else{for(var a=[],i=0;i<o.parts.length;i++)a.push(u(o.parts[i],e));f[o.id]={id:o.id,refs:1,parts:a}}}}function r(t,e){for(var n=[],o={},r=0;r<t.length;r++){var i=t[r],a=e.base?i[0]+e.base:i[0],s=i[1],l=i[2],c=i[3],u={css:s,media:l,sourceMap:c};o[a]?o[a].parts.push(u):n.push(o[a]={id:a,parts:[u]})}return n}function i(t,e){var n=m(t.insertInto);if(!n)throw new Error("Couldn't find a style target. This probably means that the value for the 'insertInto' parameter is invalid.");var o=b[b.length-1];if("top"===t.insertAt)o?o.nextSibling?n.insertBefore(e,o.nextSibling):n.appendChild(e):n.insertBefore(e,n.firstChild),b.push(e);else{if("bottom"!==t.insertAt)throw new Error("Invalid value for parameter 'insertAt'. Must be 'top' or 'bottom'.");n.appendChild(e)}}function a(t){if(null===t.parentNode)return!1;t.parentNode.removeChild(t);var e=b.indexOf(t);e>=0&&b.splice(e,1)}function s(t){var e=document.createElement("style");return t.attrs.type="text/css",c(e,t.attrs),i(t,e),e}function l(t){var e=document.createElement("link");return t.attrs.type="text/css",t.attrs.rel="stylesheet",c(e,t.attrs),i(t,e),e}function c(t,e){Object.keys(e).forEach(function(n){t.setAttribute(n,e[n])})}function u(t,e){var n,o,r,i;if(e.transform&&t.css){if(!(i=e.transform(t.css)))return function(){};t.css=i}if(e.singleton){var c=h++;n=g||(g=s(e)),o=d.bind(null,n,c,!1),r=d.bind(null,n,c,!0)}else t.sourceMap&&"function"==typeof URL&&"function"==typeof URL.createObjectURL&&"function"==typeof URL.revokeObjectURL&&"function"==typeof Blob&&"function"==typeof btoa?(n=l(e),o=function(t,e,n){var o=n.css,r=n.sourceMap,i=void 0===e.convertToAbsoluteUrls&&r;(e.convertToAbsoluteUrls||i)&&(o=v(o)),r&&(o+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(r))))+" */");var a=new Blob([o],{type:"text/css"}),s=t.href;t.href=URL.createObjectURL(a),s&&URL.revokeObjectURL(s)}.bind(null,n,e),r=function(){a(n),n.href&&URL.revokeObjectURL(n.href)}):(n=s(e),o=function(t,e){var n=e.css,o=e.media;if(o&&t.setAttribute("media",o),t.styleSheet)t.styleSheet.cssText=n;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(n))}}.bind(null,n),r=function(){a(n)});return o(t),function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap)return;o(t=e)}else r()}}function d(t,e,n,o){var r=n?"":o.css;if(t.styleSheet)t.styleSheet.cssText=w(e,r);else{var i=document.createTextNode(r),a=t.childNodes;a[e]&&t.removeChild(a[e]),a.length?t.insertBefore(i,a[e]):t.appendChild(i)}}var f={},p=function(t){var e;return function(){return void 0===e&&(e=function(){return window&&document&&document.all&&!window.atob}.apply(this,arguments)),e}}(),m=function(t){var e={};return function(t){return void 0===e[t]&&(e[t]=function(t){return document.querySelector(t)}.call(this,t)),e[t]}}(),g=null,h=0,b=[],v=n(15);t.exports=function(t,e){if("undefined"!=typeof DEBUG&&DEBUG&&"object"!=typeof document)throw new Error("The style-loader cannot be used in a non-browser environment");(e=e||{}).attrs="object"==typeof e.attrs?e.attrs:{},e.singleton||(e.singleton=p()),e.insertInto||(e.insertInto="head"),e.insertAt||(e.insertAt="bottom");var n=r(t,e);return o(n,e),function(t){for(var i=[],a=0;a<n.length;a++){var s=n[a],l=f[s.id];l.refs--,i.push(l)}t&&o(r(t,e),e);for(var a=0;a<i.length;a++){var l=i[a];if(0===l.refs){for(var c=0;c<l.parts.length;c++)l.parts[c]();delete f[l.id]}}}};var w=function(){var t=[];return function(e,n){return t[e]=n,t.filter(Boolean).join("\n")}}()},function(t,e){t.exports=function(t){var e="undefined"!=typeof window&&window.location;if(!e)throw new Error("fixUrls requires window.location");if(!t||"string"!=typeof t)return t;var n=e.protocol+"//"+e.host,o=n+e.pathname.replace(/\/[^\/]*$/,"/");return t.replace(/url\s*\(((?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)\)/gi,function(t,e){var r,i=e.trim().replace(/^"(.*)"$/,function(t,e){return e}).replace(/^'(.*)'$/,function(t,e){return e});return/^(#|data:|http:\/\/|https:\/\/|file:\/\/\/)/i.test(i)?t:(r=0===i.indexOf("//")?i:0===i.indexOf("/")?n+i:o+i.replace(/^\.\//,""),"url("+JSON.stringify(r)+")")})}},function(t,e,n){var o=n(17);"undefined"==typeof window||window.Promise||(window.Promise=o),n(21),String.prototype.includes||(String.prototype.includes=function(t,e){"use strict";return"number"!=typeof e&&(e=0),!(e+t.length>this.length)&&-1!==this.indexOf(t,e)}),Array.prototype.includes||Object.defineProperty(Array.prototype,"includes",{value:function(t,e){if(null==this)throw new TypeError('"this" is null or not defined');var n=Object(this),o=n.length>>>0;if(0===o)return!1;for(var r=0|e,i=Math.max(r>=0?r:o-Math.abs(r),0);i<o;){if(function(t,e){return t===e||"number"==typeof t&&"number"==typeof e&&isNaN(t)&&isNaN(e)}(n[i],t))return!0;i++}return!1}}),"undefined"!=typeof window&&function(t){t.forEach(function(t){t.hasOwnProperty("remove")||Object.defineProperty(t,"remove",{configurable:!0,enumerable:!0,writable:!0,value:function(){this.parentNode.removeChild(this)}})})}([Element.prototype,CharacterData.prototype,DocumentType.prototype])},function(t,e,n){(function(e){!function(n){function o(){}function r(t){if("object"!=typeof this)throw new TypeError("Promises must be constructed via new");if("function"!=typeof t)throw new TypeError("not a function");this._state=0,this._handled=!1,this._value=void 0,this._deferreds=[],u(t,this)}function i(t,e){for(;3===t._state;)t=t._value;0!==t._state?(t._handled=!0,r._immediateFn(function(){var n=1===t._state?e.onFulfilled:e.onRejected;if(null!==n){var o;try{o=n(t._value)}catch(t){return void s(e.promise,t)}a(e.promise,o)}else(1===t._state?a:s)(e.promise,t._value)})):t._deferreds.push(e)}function a(t,e){try{if(e===t)throw new TypeError("A promise cannot be resolved with itself.");if(e&&("object"==typeof e||"function"==typeof e)){var n=e.then;if(e instanceof r)return t._state=3,t._value=e,void l(t);if("function"==typeof n)return void u(function(t,e){return function(){t.apply(e,arguments)}}(n,e),t)}t._state=1,t._value=e,l(t)}catch(e){s(t,e)}}function s(t,e){t._state=2,t._value=e,l(t)}function l(t){2===t._state&&0===t._deferreds.length&&r._immediateFn(function(){t._handled||r._unhandledRejectionFn(t._value)});for(var e=0,n=t._deferreds.length;e<n;e++)i(t,t._deferreds[e]);t._deferreds=null}function c(t,e,n){this.onFulfilled="function"==typeof t?t:null,this.onRejected="function"==typeof e?e:null,this.promise=n}function u(t,e){var n=!1;try{t(function(t){n||(n=!0,a(e,t))},function(t){n||(n=!0,s(e,t))})}catch(t){if(n)return;n=!0,s(e,t)}}var d=setTimeout;r.prototype.catch=function(t){return this.then(null,t)},r.prototype.then=function(t,e){var n=new this.constructor(o);return i(this,new c(t,e,n)),n},r.all=function(t){var e=Array.prototype.slice.call(t);return new r(function(t,n){function o(i,a){try{if(a&&("object"==typeof a||"function"==typeof a)){var s=a.then;if("function"==typeof s)return void s.call(a,function(t){o(i,t)},n)}e[i]=a,0==--r&&t(e)}catch(t){n(t)}}if(0===e.length)return t([]);for(var r=e.length,i=0;i<e.length;i++)o(i,e[i])})},r.resolve=function(t){return t&&"object"==typeof t&&t.constructor===r?t:new r(function(e){e(t)})},r.reject=function(t){return new r(function(e,n){n(t)})},r.race=function(t){return new r(function(e,n){for(var o=0,r=t.length;o<r;o++)t[o].then(e,n)})},r._immediateFn="function"==typeof e&&function(t){e(t)}||function(t){d(t,0)},r._unhandledRejectionFn=function(t){"undefined"!=typeof console&&console&&console.warn("Possible Unhandled Promise Rejection:",t)},r._setImmediateFn=function(t){r._immediateFn=t},r._setUnhandledRejectionFn=function(t){r._unhandledRejectionFn=t},void 0!==t&&t.exports?t.exports=r:n.Promise||(n.Promise=r)}(this)}).call(e,n(18).setImmediate)},function(t,o,r){function i(t,e){this._id=t,this._clearFn=e}var a=Function.prototype.apply;o.setTimeout=function(){return new i(a.call(setTimeout,window,arguments),clearTimeout)},o.setInterval=function(){return new i(a.call(setInterval,window,arguments),clearInterval)},o.clearTimeout=o.clearInterval=function(t){t&&t.close()},i.prototype.unref=i.prototype.ref=function(){},i.prototype.close=function(){this._clearFn.call(window,this._id)},o.enroll=function(t,e){clearTimeout(t._idleTimeoutId),t._idleTimeout=e},o.unenroll=function(t){clearTimeout(t._idleTimeoutId),t._idleTimeout=-1},o._unrefActive=o.active=function(t){clearTimeout(t._idleTimeoutId);var e=t._idleTimeout;e>=0&&(t._idleTimeoutId=setTimeout(function(){t._onTimeout&&t._onTimeout()},e))},r(19),o.setImmediate=e,o.clearImmediate=n},function(t,e,n){(function(t,e){!function(t,n){"use strict";function o(t){delete s[t]}function r(t){if(l)setTimeout(r,0,t);else{var e=s[t];if(e){l=!0;try{!function(t){var e=t.callback,o=t.args;switch(o.length){case 0:e();break;case 1:e(o[0]);break;case 2:e(o[0],o[1]);break;case 3:e(o[0],o[1],o[2]);break;default:e.apply(n,o)}}(e)}finally{o(t),l=!1}}}}if(!t.setImmediate){var i,a=1,s={},l=!1,c=t.document,u=Object.getPrototypeOf&&Object.getPrototypeOf(t);u=u&&u.setTimeout?u:t,"[object process]"==={}.toString.call(t.process)?i=function(t){e.nextTick(function(){r(t)})}:function(){if(t.postMessage&&!t.importScripts){var e=!0,n=t.onmessage;return t.onmessage=function(){e=!1},t.postMessage("","*"),t.onmessage=n,e}}()?function(){var e="setImmediate$"+Math.random()+"$",n=function(n){n.source===t&&"string"==typeof n.data&&0===n.data.indexOf(e)&&r(+n.data.slice(e.length))};t.addEventListener?t.addEventListener("message",n,!1):t.attachEvent("onmessage",n),i=function(n){t.postMessage(e+n,"*")}}():t.MessageChannel?function(){var t=new MessageChannel;t.port1.onmessage=function(t){r(t.data)},i=function(e){t.port2.postMessage(e)}}():c&&"onreadystatechange"in c.createElement("script")?function(){var t=c.documentElement;i=function(e){var n=c.createElement("script");n.onreadystatechange=function(){r(e),n.onreadystatechange=null,t.removeChild(n),n=null},t.appendChild(n)}}():i=function(t){setTimeout(r,0,t)},u.setImmediate=function(t){"function"!=typeof t&&(t=new Function(""+t));for(var e=new Array(arguments.length-1),n=0;n<e.length;n++)e[n]=arguments[n+1];var o={callback:t,args:e};return s[a]=o,i(a),a++},u.clearImmediate=o}}("undefined"==typeof self?void 0===t?this:t:self)}).call(e,n(7),n(20))},function(t,e){function n(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function r(t){if(c===setTimeout)return setTimeout(t,0);if((c===n||!c)&&setTimeout)return c=setTimeout,setTimeout(t,0);try{return c(t,0)}catch(e){try{return c.call(null,t,0)}catch(e){return c.call(this,t,0)}}}function i(){m&&f&&(m=!1,f.length?p=f.concat(p):g=-1,p.length&&a())}function a(){if(!m){var t=r(i);m=!0;for(var e=p.length;e;){for(f=p,p=[];++g<e;)f&&f[g].run();g=-1,e=p.length}f=null,m=!1,function(t){if(u===clearTimeout)return clearTimeout(t);if((u===o||!u)&&clearTimeout)return u=clearTimeout,clearTimeout(t);try{u(t)}catch(e){try{return u.call(null,t)}catch(e){return u.call(this,t)}}}(t)}}function s(t,e){this.fun=t,this.array=e}function l(){}var c,u,d=t.exports={};!function(){try{c="function"==typeof setTimeout?setTimeout:n}catch(t){c=n}try{u="function"==typeof clearTimeout?clearTimeout:o}catch(t){u=o}}();var f,p=[],m=!1,g=-1;d.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)e[n-1]=arguments[n];p.push(new s(t,e)),1!==p.length||m||r(a)},s.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=l,d.addListener=l,d.once=l,d.off=l,d.removeListener=l,d.removeAllListeners=l,d.emit=l,d.prependListener=l,d.prependOnceListener=l,d.listeners=function(t){return[]},d.binding=function(t){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(t){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},function(t,e,n){"use strict";n(22).polyfill()},function(t,e,n){"use strict";function o(t,e){if(null==t)throw new TypeError("Cannot convert first argument to object");for(var n=Object(t),o=1;o<arguments.length;o++){var r=arguments[o];if(null!=r)for(var i=Object.keys(Object(r)),a=0,s=i.length;a<s;a++){var l=i[a],c=Object.getOwnPropertyDescriptor(r,l);void 0!==c&&c.enumerable&&(n[l]=r[l])}}return n}t.exports={assign:o,polyfill:function(){Object.assign||Object.defineProperty(Object,"assign",{enumerable:!1,configurable:!0,writable:!0,value:o})}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(24),r=n(6),i=n(5),a=n(36),s=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];if("undefined"!=typeof window){var n=a.getOpts.apply(void 0,t);return new Promise(function(t,e){i.default.promise={resolve:t,reject:e},o.default(n),setTimeout(function(){r.openModal()})})}};s.close=r.onAction,s.getState=r.getState,s.setActionValue=i.setActionValue,s.stopLoading=r.stopLoading,s.setDefaults=a.setDefaults,e.default=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=n(0),i=r.default.MODAL,a=n(4),s=n(34),l=n(35),c=n(1);e.init=function(t){o.getNode(i)||(document.body||c.throwErr("You can only use SweetAlert AFTER the DOM has loaded!"),s.default(),a.default()),a.initModalContent(t),l.default(t)},e.default=e.init},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(0),r=o.default.MODAL;e.modalMarkup='\n  <div class="'+r+'" role="dialog" aria-modal="true"></div>',e.default=e.modalMarkup},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(0),r=o.default.OVERLAY,i='<div \n    class="'+r+'"\n    tabIndex="-1">\n  </div>';e.default=i},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(0),r=o.default.ICON;e.errorIconMarkup=function(){var t=r+"--error",e=t+"__line";return'\n    <div class="'+t+'__x-mark">\n      <span class="'+e+" "+e+'--left"></span>\n      <span class="'+e+" "+e+'--right"></span>\n    </div>\n  '},e.warningIconMarkup=function(){var t=r+"--warning";return'\n    <span class="'+t+'__body">\n      <span class="'+t+'__dot"></span>\n    </span>\n  '},e.successIconMarkup=function(){var t=r+"--success";return'\n    <span class="'+t+"__line "+t+'__line--long"></span>\n    <span class="'+t+"__line "+t+'__line--tip"></span>\n\n    <div class="'+t+'__ring"></div>\n    <div class="'+t+'__hide-corners"></div>\n  '}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(0),r=o.default.CONTENT;e.contentMarkup='\n  <div class="'+r+'">\n\n  </div>\n'},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(0),r=o.default.BUTTON_CONTAINER,i=o.default.BUTTON,a=o.default.BUTTON_LOADER;e.buttonMarkup='\n  <div class="'+r+'">\n\n    <button\n      class="'+i+'"\n    ></button>\n\n    <div class="'+a+'">\n      <div></div>\n      <div></div>\n      <div></div>\n    </div>\n\n  </div>\n'},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(4),r=n(2),i=n(0),a=i.default.ICON,s=i.default.ICON_CUSTOM,l=["error","warning","success","info"],c={error:r.errorIconMarkup(),warning:r.warningIconMarkup(),success:r.successIconMarkup()};e.default=function(t){if(t){var e=o.injectElIntoModal(r.iconMarkup);l.includes(t)?function(t,e){var n=a+"--"+t;e.classList.add(n);var o=c[t];o&&(e.innerHTML=o)}(t,e):function(t,e){e.classList.add(s);var n=document.createElement("img");n.src=t,e.appendChild(n)}(t,e)}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(2),r=n(4),i=function(t){navigator.userAgent.includes("AppleWebKit")&&(t.style.display="none",t.offsetHeight,t.style.display="")};e.initTitle=function(t){if(t){var e=r.injectElIntoModal(o.titleMarkup);e.textContent=t,i(e)}},e.initText=function(t){if(t){var e=document.createDocumentFragment();t.split("\n").forEach(function(t,n,o){e.appendChild(document.createTextNode(t)),n<o.length-1&&e.appendChild(document.createElement("br"))});var n=r.injectElIntoModal(o.textMarkup);n.appendChild(e),i(n)}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=n(4),i=n(0),a=i.default.BUTTON,s=i.default.DANGER_BUTTON,l=n(3),c=n(2),u=n(6),d=n(5),f=function(t,e,n){var r=e.text,i=e.value,f=e.className,p=e.closeModal,m=o.stringToNode(c.buttonMarkup),g=m.querySelector("."+a),h=a+"--"+t;g.classList.add(h),f&&(Array.isArray(f)?f:f.split(" ")).filter(function(t){return t.length>0}).forEach(function(t){g.classList.add(t)}),n&&t===l.CONFIRM_KEY&&g.classList.add(s),g.textContent=r;var b={};return b[t]=i,d.setActionValue(b),d.setActionOptionsFor(t,{closeModal:p}),g.addEventListener("click",function(){return u.onAction(t)}),m};e.default=function(t,e){var n=r.injectElIntoModal(c.footerMarkup);for(var o in t){var i=t[o],a=f(o,i,e);i.visible&&n.appendChild(a)}0===n.children.length&&n.remove()}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(3),r=n(4),i=n(2),a=n(5),s=n(6),l=n(0),c=l.default.CONTENT,u=function(t){t.addEventListener("input",function(t){var e=t.target,n=e.value;a.setActionValue(n)}),t.addEventListener("keyup",function(t){if("Enter"===t.key)return s.onAction(o.CONFIRM_KEY)}),setTimeout(function(){t.focus(),a.setActionValue("")},0)};e.default=function(t){if(t){var e=r.injectElIntoModal(i.contentMarkup),n=t.element,o=t.attributes;"string"==typeof n?function(t,e,n){var o=document.createElement(e),r=c+"__"+e;for(var i in o.classList.add(r),n){var a=n[i];o[i]=a}"input"===e&&u(o),t.appendChild(o)}(e,n,o):e.appendChild(n)}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=n(2);e.default=function(){var t=o.stringToNode(r.overlayMarkup);document.body.appendChild(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(5),r=n(6),i=n(1),a=n(3),s=n(0),l=s.default.MODAL,c=s.default.BUTTON,u=s.default.OVERLAY,d=function(t){if(o.default.isOpen)switch(t.key){case"Escape":return r.onAction(a.CANCEL_KEY)}},f=function(t){if(o.default.isOpen)switch(t.key){case"Tab":return function(t){t.preventDefault(),m()}(t)}},p=function(t){if(o.default.isOpen)return"Tab"===t.key&&t.shiftKey?function(t){t.preventDefault(),g()}(t):void 0},m=function(){var t=i.getNode(c);t&&(t.tabIndex=0,t.focus())},g=function(){var t=i.getNode(l),e=t.querySelectorAll("."+c),n=e.length-1,o=e[n];o&&o.focus()},h=function(){var t=i.getNode(l),e=t.querySelectorAll("."+c);e.length&&(function(t){t[t.length-1].addEventListener("keydown",f)}(e),function(t){t[0].addEventListener("keydown",p)}(e))},b=function(t){if(i.getNode(u)===t.target)return r.onAction(a.CANCEL_KEY)};e.default=function(t){t.closeOnEsc?document.addEventListener("keyup",d):document.removeEventListener("keyup",d),t.dangerMode?m():g(),h(),function(t){var e=i.getNode(u);e.removeEventListener("click",b),t&&e.addEventListener("click",b)}(t.closeOnClickOutside),function(t){o.default.timer&&clearTimeout(o.default.timer),t&&(o.default.timer=window.setTimeout(function(){return r.onAction(a.CANCEL_KEY)},t))}(t.timer)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=n(3),i=n(37),a=n(38),s={title:null,text:null,icon:null,buttons:r.defaultButtonList,content:null,className:null,closeOnClickOutside:!0,closeOnEsc:!0,dangerMode:!1,timer:null},l=Object.assign({},s);e.setDefaults=function(t){l=Object.assign({},s,t)};var c=function(t){var e=t&&t.button,n=t&&t.buttons;return void 0!==e&&void 0!==n&&o.throwErr("Cannot set both 'button' and 'buttons' options!"),void 0!==e?{confirm:e}:n},u=function(t){return o.ordinalSuffixOf(t+1)},d=function(t,e){o.throwErr(u(e)+" argument ('"+t+"') is invalid")},f=function(t,e){var n=t+1,r=e[n];o.isPlainObject(r)||void 0===r||o.throwErr("Expected "+u(n)+" argument ('"+r+"') to be a plain object")},p=function(t,e,n,r){var i=typeof e,a="string"===i,s=e instanceof Element;if(a){if(0===n)return{text:e};if(1===n)return{text:e,title:r[0]};if(2===n)return f(n,r),{icon:e};d(e,n)}else{if(s&&0===n)return f(n,r),{content:e};if(o.isPlainObject(e))return function(t,e){var n=t+1,r=e[n];void 0!==r&&o.throwErr("Unexpected "+u(n)+" argument ("+r+")")}(n,r),e;d(e,n)}};e.getOpts=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];var n={};t.forEach(function(e,o){var r=p(0,e,o,t);Object.assign(n,r)});var o=c(n);n.buttons=r.getButtonListOpts(o),delete n.button,n.content=i.getContentOpts(n.content);var u=Object.assign({},s,l,n);return Object.keys(u).forEach(function(t){a.DEPRECATED_OPTS[t]&&a.logDeprecation(t)}),u}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r={element:"input",attributes:{placeholder:""}};e.getContentOpts=function(t){return o.isPlainObject(t)?Object.assign({},t):t instanceof Element?{element:t}:"input"===t?r:null}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.logDeprecation=function(t){var n=e.DEPRECATED_OPTS[t],o=n.onlyRename,r=n.replacement,i=n.subOption,a=n.link,s=o?"renamed":"deprecated",l='SweetAlert warning: "'+t+'" option has been '+s+".";r&&(l+=" Please use"+(i?' "'+i+'" in ':" ")+'"'+r+'" instead.');var c="https://sweetalert.js.org";l+=a?" More details: "+c+a:" More details: "+c+"/guides/#upgrading-from-1x",console.warn(l)},e.DEPRECATED_OPTS={type:{replacement:"icon",link:"/docs/#icon"},imageUrl:{replacement:"icon",link:"/docs/#icon"},customClass:{replacement:"className",onlyRename:!0,link:"/docs/#classname"},imageSize:{},showCancelButton:{replacement:"buttons",link:"/docs/#buttons"},showConfirmButton:{replacement:"button",link:"/docs/#button"},confirmButtonText:{replacement:"button",link:"/docs/#button"},confirmButtonColor:{},cancelButtonText:{replacement:"buttons",link:"/docs/#buttons"},closeOnConfirm:{replacement:"button",subOption:"closeModal",link:"/docs/#button"},closeOnCancel:{replacement:"buttons",subOption:"closeModal",link:"/docs/#buttons"},showLoaderOnConfirm:{replacement:"buttons"},animation:{},inputType:{replacement:"content",link:"/docs/#content"},inputValue:{replacement:"content",link:"/docs/#content"},inputPlaceholder:{replacement:"content",link:"/docs/#content"},html:{replacement:"content",link:"/docs/#content"},allowEscapeKey:{replacement:"closeOnEsc",onlyRename:!0,link:"/docs/#closeonesc"},allowClickOutside:{replacement:"closeOnClickOutside",onlyRename:!0,link:"/docs/#closeonclickoutside"}}}])}).call(this,n("URgk").setImmediate,n("URgk").clearImmediate)},URgk:function(t,e,n){(function(t){var o=void 0!==t&&t||"undefined"!=typeof self&&self||window,r=Function.prototype.apply;function i(t,e){this._id=t,this._clearFn=e}e.setTimeout=function(){return new i(r.call(setTimeout,o,arguments),clearTimeout)},e.setInterval=function(){return new i(r.call(setInterval,o,arguments),clearInterval)},e.clearTimeout=e.clearInterval=function(t){t&&t.close()},i.prototype.unref=i.prototype.ref=function(){},i.prototype.close=function(){this._clearFn.call(o,this._id)},e.enroll=function(t,e){clearTimeout(t._idleTimeoutId),t._idleTimeout=e},e.unenroll=function(t){clearTimeout(t._idleTimeoutId),t._idleTimeout=-1},e._unrefActive=e.active=function(t){clearTimeout(t._idleTimeoutId);var e=t._idleTimeout;e>=0&&(t._idleTimeoutId=setTimeout(function(){t._onTimeout&&t._onTimeout()},e))},n("YBdB"),e.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==t&&t.setImmediate||this&&this.setImmediate,e.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==t&&t.clearImmediate||this&&this.clearImmediate}).call(this,n("yLpj"))},YBdB:function(t,e,n){(function(t,e){!function(t,n){"use strict";if(!t.setImmediate){var o,r,i,a,s,l=1,c={},u=!1,d=t.document,f=Object.getPrototypeOf&&Object.getPrototypeOf(t);f=f&&f.setTimeout?f:t,"[object process]"==={}.toString.call(t.process)?o=function(t){e.nextTick(function(){m(t)})}:!function(){if(t.postMessage&&!t.importScripts){var e=!0,n=t.onmessage;return t.onmessage=function(){e=!1},t.postMessage("","*"),t.onmessage=n,e}}()?t.MessageChannel?((i=new MessageChannel).port1.onmessage=function(t){m(t.data)},o=function(t){i.port2.postMessage(t)}):d&&"onreadystatechange"in d.createElement("script")?(r=d.documentElement,o=function(t){var e=d.createElement("script");e.onreadystatechange=function(){m(t),e.onreadystatechange=null,r.removeChild(e),e=null},r.appendChild(e)}):o=function(t){setTimeout(m,0,t)}:(a="setImmediate$"+Math.random()+"$",s=function(e){e.source===t&&"string"==typeof e.data&&0===e.data.indexOf(a)&&m(+e.data.slice(a.length))},t.addEventListener?t.addEventListener("message",s,!1):t.attachEvent("onmessage",s),o=function(e){t.postMessage(a+e,"*")}),f.setImmediate=function(t){"function"!=typeof t&&(t=new Function(""+t));for(var e=new Array(arguments.length-1),n=0;n<e.length;n++)e[n]=arguments[n+1];var r={callback:t,args:e};return c[l]=r,o(l),l++},f.clearImmediate=p}function p(t){delete c[t]}function m(t){if(u)setTimeout(m,0,t);else{var e=c[t];if(e){u=!0;try{!function(t){var e=t.callback,o=t.args;switch(o.length){case 0:e();break;case 1:e(o[0]);break;case 2:e(o[0],o[1]);break;case 3:e(o[0],o[1],o[2]);break;default:e.apply(n,o)}}(e)}finally{p(t),u=!1}}}}}("undefined"==typeof self?void 0===t?this:t:self)}).call(this,n("yLpj"),n("8oxB"))},bquW:function(t,e,n){var o=n("GUC0");t.exports={confirm:function(t,e,n,r,i,a){var s={title:t,icon:"warning",text:e,dangerMode:!0,buttons:{cancel:{text:void 0!==a?a:translations.cancel,value:null,visible:!0,className:"",closeModal:!0},confirm:{text:void 0!==i?i:translations.ok,value:!0,visible:!0,className:"",closeModal:!0}}};return o(s).then(function(t){t?void 0!==n&&n():void 0!==r&&r()}),!1},info:function(t,e){o({title:t,text:e,icon:"info"})},warning:function(t,e){o({title:t,text:e,icon:"warning",dangerMode:!0})}}},oBpX:function(t,e){jQuery.trumbowyg={langs:{en:{viewHTML:"View HTML",undo:"Undo",redo:"Redo",formatting:"Formatting",p:"Paragraph",blockquote:"Quote",code:"Code",header:"Header",bold:"Bold",italic:"Italic",strikethrough:"Stroke",underline:"Underline",strong:"Strong",em:"Emphasis",del:"Deleted",superscript:"Superscript",subscript:"Subscript",unorderedList:"Unordered list",orderedList:"Ordered list",insertImage:"Insert Image",link:"Link",createLink:"Insert link",unlink:"Remove link",justifyLeft:"Align Left",justifyCenter:"Align Center",justifyRight:"Align Right",justifyFull:"Align Justify",horizontalRule:"Insert horizontal rule",removeformat:"Remove format",fullscreen:"Fullscreen",close:"Close",submit:"Confirm",reset:"Cancel",required:"Required",description:"Description",title:"Title",text:"Text",target:"Target",width:"Width"}},plugins:{},svgPath:null,hideButtonTexts:null},Object.defineProperty(jQuery.trumbowyg,"defaultOptions",{value:{lang:"en",fixedBtnPane:!1,fixedFullWidth:!1,autogrow:!1,autogrowOnEnter:!1,imageWidthModalEdit:!1,prefix:"trumbowyg-",semantic:!0,resetCss:!1,removeformatPasted:!1,tagsToRemove:[],tagsToKeep:["hr","img","embed","iframe","input"],btns:[["viewHTML"],["undo","redo"],["formatting"],["strong","em","del"],["superscript","subscript"],["link"],["insertImage"],["justifyLeft","justifyCenter","justifyRight","justifyFull"],["unorderedList","orderedList"],["horizontalRule"],["removeformat"],["fullscreen"]],btnsDef:{},inlineElementsSelector:"a,abbr,acronym,b,caption,cite,code,col,dfn,dir,dt,dd,em,font,hr,i,kbd,li,q,span,strikeout,strong,sub,sup,u",pasteHandlers:[],plugins:{},urlProtocol:!1,minimalLinks:!1},writable:!1,enumerable:!0,configurable:!1}),function(t,e,n,o){"use strict";o.fn.trumbowyg=function(t,e){if(t===Object(t)||!t)return this.each(function(){o(this).data("trumbowyg")||o(this).data("trumbowyg",new r(this,t))});if(1===this.length)try{var n=o(this).data("trumbowyg");switch(t){case"execCmd":return n.execCmd(e.cmd,e.param,e.forceCss);case"openModal":return n.openModal(e.title,e.content);case"closeModal":return n.closeModal();case"openModalInsert":return n.openModalInsert(e.title,e.fields,e.callback);case"saveRange":return n.saveRange();case"getRange":return n.range;case"getRangeText":return n.getRangeText();case"restoreRange":return n.restoreRange();case"enable":return n.setDisabled(!1);case"disable":return n.setDisabled(!0);case"toggle":return n.toggle();case"destroy":return n.destroy();case"empty":return n.empty();case"html":return n.html(e)}}catch(t){}return!1};var r=function(r,i){var a=this,s=o.trumbowyg;a.doc=r.ownerDocument||n,a.$ta=o(r),a.$c=o(r),null!=(i=i||{}).lang||null!=s.langs[i.lang]?a.lang=o.extend(!0,{},s.langs.en,s.langs[i.lang]):a.lang=s.langs.en,a.hideButtonTexts=null!=s.hideButtonTexts?s.hideButtonTexts:i.hideButtonTexts;var l=null!=s.svgPath?s.svgPath:i.svgPath;if(a.hasSvg=!1!==l,a.svgPath=a.doc.querySelector("base")?e.location.href.split("#")[0]:"",0===o("#trumbowyg-icons",a.doc).length&&!1!==l){if(null==l){for(var c=n.getElementsByTagName("script"),u=0;u<c.length;u+=1){var d=c[u].src,f=d.match("trumbowyg(.min)?.js");null!=f&&(l=d.substring(0,d.indexOf(f[0]))+"ui/icons.svg")}null==l&&console.warn("You must define svgPath: https://goo.gl/CfTY9U")}var p=a.doc.createElement("div");p.id="trumbowyg-icons",a.doc.body.insertBefore(p,a.doc.body.childNodes[0]),o.ajax({async:!0,type:"GET",contentType:"application/x-www-form-urlencoded; charset=UTF-8",dataType:"xml",crossDomain:!0,url:l,data:null,beforeSend:null,complete:null,success:function(t){p.innerHTML=(new XMLSerializer).serializeToString(t.documentElement)}})}var m=a.lang.header,g=function(){return(e.chrome||e.Intl&&Intl.v8BreakIterator)&&"CSS"in e};a.btnsDef={viewHTML:{fn:"toggle",class:"trumbowyg-not-disable"},undo:{isSupported:g,key:"Z"},redo:{isSupported:g,key:"Y"},p:{fn:"formatBlock"},blockquote:{fn:"formatBlock"},h1:{fn:"formatBlock",title:m+" 1"},h2:{fn:"formatBlock",title:m+" 2"},h3:{fn:"formatBlock",title:m+" 3"},h4:{fn:"formatBlock",title:m+" 4"},subscript:{tag:"sub"},superscript:{tag:"sup"},bold:{key:"B",tag:"b"},italic:{key:"I",tag:"i"},underline:{tag:"u"},strikethrough:{tag:"strike"},strong:{fn:"bold",key:"B"},em:{fn:"italic",key:"I"},del:{fn:"strikethrough"},createLink:{key:"K",tag:"a"},unlink:{},insertImage:{},justifyLeft:{tag:"left",forceCss:!0},justifyCenter:{tag:"center",forceCss:!0},justifyRight:{tag:"right",forceCss:!0},justifyFull:{tag:"justify",forceCss:!0},unorderedList:{fn:"insertUnorderedList",tag:"ul"},orderedList:{fn:"insertOrderedList",tag:"ol"},horizontalRule:{fn:"insertHorizontalRule"},removeformat:{},fullscreen:{class:"trumbowyg-not-disable"},close:{fn:"destroy",class:"trumbowyg-not-disable"},formatting:{dropdown:["p","blockquote","h1","h2","h3","h4"],ico:"p"},link:{dropdown:["createLink","unlink"]}},a.o=o.extend(!0,{},s.defaultOptions,i),a.o.hasOwnProperty("imgDblClickHandler")||(a.o.imgDblClickHandler=a.getDefaultImgDblClickHandler()),a.urlPrefix=a.setupUrlPrefix(),a.disabled=a.o.disabled||"TEXTAREA"===r.nodeName&&r.disabled,i.btns?a.o.btns=i.btns:a.o.semantic||(a.o.btns[3]=["bold","italic","underline","strikethrough"]),o.each(a.o.btnsDef,function(t,e){a.addBtnDef(t,e)}),a.eventNamespace="trumbowyg-event",a.keys=[],a.tagToButton={},a.tagHandlers=[],a.pasteHandlers=[].concat(a.o.pasteHandlers),a.isIE=-1!==t.userAgent.indexOf("MSIE")||-1!==t.appVersion.indexOf("Trident/"),a.init()};r.prototype={DEFAULT_SEMANTIC_MAP:{b:"strong",i:"em",s:"del",strike:"del",div:"p"},init:function(){var t=this;t.height=t.$ta.height(),t.initPlugins();try{t.doc.execCommand("enableObjectResizing",!1,!1),t.doc.execCommand("defaultParagraphSeparator",!1,"p")}catch(t){}t.buildEditor(),t.buildBtnPane(),t.fixedBtnPaneEvents(),t.buildOverlay(),setTimeout(function(){t.disabled&&t.setDisabled(!0),t.$c.trigger("tbwinit")})},addBtnDef:function(t,e){this.btnsDef[t]=e},setupUrlPrefix:function(){var t=this.o.urlProtocol;if(t)return"string"!=typeof t?"https://":/:\/\/$/.test(t)?t:t+"://"},buildEditor:function(){var t=this,n=t.o.prefix,r="";t.$box=o("<div/>",{class:n+"box "+n+"editor-visible "+n+t.o.lang+" trumbowyg"}),t.isTextarea=t.$ta.is("textarea"),t.isTextarea?(r=t.$ta.val(),t.$ed=o("<div/>"),t.$box.insertAfter(t.$ta).append(t.$ed,t.$ta)):(t.$ed=t.$ta,r=t.$ed.html(),t.$ta=o("<textarea/>",{name:t.$ta.attr("id"),height:t.height}).val(r),t.$box.insertAfter(t.$ed).append(t.$ta,t.$ed),t.syncCode()),t.$ta.addClass(n+"textarea").attr("tabindex",-1),t.$ed.addClass(n+"editor").attr({contenteditable:!0,dir:t.lang._dir||"ltr"}).html(r),t.o.tabindex&&t.$ed.attr("tabindex",t.o.tabindex),t.$c.is("[placeholder]")&&t.$ed.attr("placeholder",t.$c.attr("placeholder")),t.$c.is("[spellcheck]")&&t.$ed.attr("spellcheck",t.$c.attr("spellcheck")),t.o.resetCss&&t.$ed.addClass(n+"reset-css"),t.o.autogrow||t.$ta.add(t.$ed).css({height:t.height}),t.semanticCode(),t.o.autogrowOnEnter&&t.$ed.addClass(n+"autogrow-on-enter");var i,a=!1,s=!1;t.$ed.on("dblclick","img",t.o.imgDblClickHandler).on("keydown",function(e){if((e.ctrlKey||e.metaKey)&&!e.altKey){a=!0;var n=t.keys[String.fromCharCode(e.which).toUpperCase()];try{return t.execCmd(n.fn,n.param),!1}catch(t){}}}).on("compositionstart compositionupdate",function(){s=!0}).on("keyup compositionend",function(e){if("compositionend"===e.type)s=!1;else if(s)return;var n=e.which;if(!(n>=37&&n<=40)){if(!e.ctrlKey&&!e.metaKey||89!==n&&90!==n)if(a||17===n)void 0===e.which&&t.semanticCode(!1,!1,!0);else{var o=!t.isIE||"compositionend"===e.type;t.semanticCode(!1,o&&13===n),t.$c.trigger("tbwchange")}else t.semanticCode(!1,!0),t.$c.trigger("tbwchange");setTimeout(function(){a=!1},50)}}).on("mouseup keydown keyup",function(e){(!e.ctrlKey&&!e.metaKey||e.altKey)&&setTimeout(function(){a=!1},50),clearTimeout(i),i=setTimeout(function(){t.updateButtonPaneStatus()},50)}).on("focus blur",function(e){if(t.$c.trigger("tbw"+e.type),"blur"===e.type&&o("."+n+"active-button",t.$btnPane).removeClass(n+"active-button "+n+"active"),t.o.autogrowOnEnter){if(t.autogrowOnEnterDontClose)return;"focus"===e.type?(t.autogrowOnEnterWasFocused=!0,t.autogrowEditorOnEnter()):t.o.autogrow||(t.$ed.css({height:t.$ed.css("min-height")}),t.$c.trigger("tbwresize"))}}).on("cut drop",function(){setTimeout(function(){t.semanticCode(!1,!0),t.$c.trigger("tbwchange")},0)}).on("paste",function(n){if(t.o.removeformatPasted){n.preventDefault(),e.getSelection&&e.getSelection().deleteFromDocument&&e.getSelection().deleteFromDocument();try{var r=e.clipboardData.getData("Text");try{t.doc.selection.createRange().pasteHTML(r)}catch(e){t.doc.getSelection().getRangeAt(0).insertNode(t.doc.createTextNode(r))}t.$c.trigger("tbwchange",n)}catch(e){t.execCmd("insertText",(n.originalEvent||n).clipboardData.getData("text/plain"))}}o.each(t.pasteHandlers,function(t,e){e(n)}),setTimeout(function(){t.semanticCode(!1,!0),t.$c.trigger("tbwpaste",n),t.$c.trigger("tbwchange")},0)}),t.$ta.on("keyup",function(){t.$c.trigger("tbwchange")}).on("paste",function(){setTimeout(function(){t.$c.trigger("tbwchange")},0)}),t.$box.on("keydown",function(e){if(27===e.which&&1===o("."+n+"modal-box",t.$box).length)return t.closeModal(),!1})},autogrowEditorOnEnter:function(){var t=this;t.$ed.removeClass("autogrow-on-enter");var e=t.$ed[0].clientHeight;t.$ed.height("auto");var n=t.$ed[0].scrollHeight;t.$ed.addClass("autogrow-on-enter"),e!==n&&(t.$ed.height(e),setTimeout(function(){t.$ed.css({height:n}),t.$c.trigger("tbwresize")},0))},buildBtnPane:function(){var t=this,e=t.o.prefix,n=t.$btnPane=o("<div/>",{class:e+"button-pane"});o.each(t.o.btns,function(r,i){o.isArray(i)||(i=[i]);var a=o("<div/>",{class:e+"button-group "+(i.indexOf("fullscreen")>=0?e+"right":"")});o.each(i,function(e,n){try{t.isSupportedBtn(n)&&a.append(t.buildBtn(n))}catch(t){}}),a.html().trim().length>0&&n.append(a)}),t.$box.prepend(n)},buildBtn:function(t){var e=this,n=e.o.prefix,r=e.btnsDef[t],i=r.dropdown,a=null==r.hasIcon||r.hasIcon,s=e.lang[t]||t,l=o("<button/>",{type:"button",class:n+t+"-button "+(r.class||"")+(a?"":" "+n+"textual-button"),html:e.hasSvg&&a?'<svg><use xlink:href="'+e.svgPath+"#"+n+(r.ico||t).replace(/([A-Z]+)/g,"-$1").toLowerCase()+'"/></svg>':e.hideButtonTexts?"":r.text||r.title||e.lang[t]||t,title:(r.title||r.text||s)+(r.key?" (Ctrl + "+r.key+")":""),tabindex:-1,mousedown:function(){return i&&!o("."+t+"-"+n+"dropdown",e.$box).is(":hidden")||o("body",e.doc).trigger("mousedown"),!((e.$btnPane.hasClass(n+"disable")||e.$box.hasClass(n+"disabled"))&&!o(this).hasClass(n+"active")&&!o(this).hasClass(n+"not-disable"))&&(e.execCmd((!i?r.fn:"dropdown")||t,r.param||t,r.forceCss),!1)}});if(i){l.addClass(n+"open-dropdown");var c=n+"dropdown",u={class:c+"-"+t+" "+c+" "+n+"fixed-top"};u["data-"+c]=t;var d=o("<div/>",u);o.each(i,function(t,n){e.btnsDef[n]&&e.isSupportedBtn(n)&&d.append(e.buildSubBtn(n))}),e.$box.append(d.hide())}else r.key&&(e.keys[r.key]={fn:r.fn||t,param:r.param||t});return i||(e.tagToButton[(r.tag||t).toLowerCase()]=t),l},buildSubBtn:function(t){var e=this,n=e.o.prefix,r=e.btnsDef[t],i=null==r.hasIcon||r.hasIcon;return r.key&&(e.keys[r.key]={fn:r.fn||t,param:r.param||t}),e.tagToButton[(r.tag||t).toLowerCase()]=t,o("<button/>",{type:"button",class:n+t+"-dropdown-button"+(r.ico?" "+n+r.ico+"-button":""),html:e.hasSvg&&i?'<svg><use xlink:href="'+e.svgPath+"#"+n+(r.ico||t).replace(/([A-Z]+)/g,"-$1").toLowerCase()+'"/></svg>'+(r.text||r.title||e.lang[t]||t):r.text||r.title||e.lang[t]||t,title:r.key?" (Ctrl + "+r.key+")":null,style:r.style||null,mousedown:function(){return o("body",e.doc).trigger("mousedown"),e.execCmd(r.fn||t,r.param||t,r.forceCss),!1}})},isSupportedBtn:function(t){try{return this.btnsDef[t].isSupported()}catch(t){}return!0},buildOverlay:function(){var t=this;return t.$overlay=o("<div/>",{class:t.o.prefix+"overlay"}).appendTo(t.$box),t.$overlay},showOverlay:function(){var t=this;o(e).trigger("scroll"),t.$overlay.fadeIn(200),t.$box.addClass(t.o.prefix+"box-blur")},hideOverlay:function(){var t=this;t.$overlay.fadeOut(50),t.$box.removeClass(t.o.prefix+"box-blur")},fixedBtnPaneEvents:function(){var t=this,n=t.o.fixedFullWidth,r=t.$box;t.o.fixedBtnPane&&(t.isFixed=!1,o(e).on("scroll."+t.eventNamespace+" resize."+t.eventNamespace,function(){if(r){t.syncCode();var i=o(e).scrollTop(),a=r.offset().top+1,s=t.$btnPane,l=s.outerHeight()-2;i-a>0&&i-a-t.height<0?(t.isFixed||(t.isFixed=!0,s.css({position:"fixed",top:0,left:n?"0":"auto",zIndex:7}),o([t.$ta,t.$ed]).css({marginTop:s.height()})),s.css({width:n?"100%":r.width()-1+"px"}),o("."+t.o.prefix+"fixed-top",r).css({position:n?"fixed":"absolute",top:n?l:l+(i-a)+"px",zIndex:15})):t.isFixed&&(t.isFixed=!1,s.removeAttr("style"),o([t.$ta,t.$ed]).css({marginTop:0}),o("."+t.o.prefix+"fixed-top",r).css({position:"absolute",top:l}))}}))},setDisabled:function(t){var e=this,n=e.o.prefix;e.disabled=t,t?e.$ta.attr("disabled",!0):e.$ta.removeAttr("disabled"),e.$box.toggleClass(n+"disabled",t),e.$ed.attr("contenteditable",!t)},destroy:function(){var t=this,n=t.o.prefix;t.isTextarea?t.$box.after(t.$ta.css({height:""}).val(t.html()).removeClass(n+"textarea").show()):t.$box.after(t.$ed.css({height:""}).removeClass(n+"editor").removeAttr("contenteditable").removeAttr("dir").html(t.html()).show()),t.$ed.off("dblclick","img"),t.destroyPlugins(),t.$box.remove(),t.$c.removeData("trumbowyg"),o("body").removeClass(n+"body-fullscreen"),t.$c.trigger("tbwclose"),o(e).off("scroll."+t.eventNamespace+" resize."+t.eventNamespace)},empty:function(){this.$ta.val(""),this.syncCode(!0)},toggle:function(){var t=this,e=t.o.prefix;t.o.autogrowOnEnter&&(t.autogrowOnEnterDontClose=!t.$box.hasClass(e+"editor-hidden")),t.semanticCode(!1,!0),setTimeout(function(){t.doc.activeElement.blur(),t.$box.toggleClass(e+"editor-hidden "+e+"editor-visible"),t.$btnPane.toggleClass(e+"disable"),o("."+e+"viewHTML-button",t.$btnPane).toggleClass(e+"active"),t.$box.hasClass(e+"editor-visible")?t.$ta.attr("tabindex",-1):t.$ta.removeAttr("tabindex"),t.o.autogrowOnEnter&&!t.autogrowOnEnterDontClose&&t.autogrowEditorOnEnter()},0)},dropdown:function(t){var n=this,r=n.doc,i=n.o.prefix,a=o("[data-"+i+"dropdown="+t+"]",n.$box),s=o("."+i+t+"-button",n.$btnPane),l=a.is(":hidden");if(o("body",r).trigger("mousedown"),l){var c=s.offset().left;s.addClass(i+"active"),a.css({position:"absolute",top:s.offset().top-n.$btnPane.offset().top+s.outerHeight(),left:n.o.fixedFullWidth&&n.isFixed?c+"px":c-n.$btnPane.offset().left+"px"}).show(),o(e).trigger("scroll"),o("body",r).on("mousedown."+n.eventNamespace,function(t){a.is(t.target)||(o("."+i+"dropdown",n.$box).hide(),o("."+i+"active",n.$btnPane).removeClass(i+"active"),o("body",r).off("mousedown."+n.eventNamespace))})}},html:function(t){var e=this;return null!=t?(e.$ta.val(t),e.syncCode(!0),e.$c.trigger("tbwchange"),e):e.$ta.val()},syncTextarea:function(){var t=this;t.$ta.val(t.$ed.text().trim().length>0||t.$ed.find(t.o.tagsToKeep.join(",")).length>0?t.$ed.html():"")},syncCode:function(t){var e=this;if(!t&&e.$ed.is(":visible"))e.syncTextarea();else{var n=o("<div>").html(e.$ta.val()),r=o("<div>").append(n);o(e.o.tagsToRemove.join(","),r).remove(),e.$ed.html(r.contents().html())}if(e.o.autogrow&&(e.height=e.$ed.height(),e.height!==e.$ta.css("height")&&(e.$ta.css({height:e.height}),e.$c.trigger("tbwresize"))),e.o.autogrowOnEnter){e.$ed.height("auto");var i=e.autogrowOnEnterWasFocused?e.$ed[0].scrollHeight:e.$ed.css("min-height");i!==e.$ta.css("height")&&(e.$ed.css({height:i}),e.$c.trigger("tbwresize"))}},semanticCode:function(t,e,n){var r=this;if(r.saveRange(),r.syncCode(t),r.o.semantic){if(r.semanticTag("b"),r.semanticTag("i"),r.semanticTag("s"),r.semanticTag("strike"),e){var i=r.o.inlineElementsSelector,a=":not("+i+")";r.$ed.contents().filter(function(){return 3===this.nodeType&&this.nodeValue.trim().length>0}).wrap("<span data-tbw/>");var s=function(t){if(0!==t.length){var e=t.nextUntil(a).addBack().wrapAll("<p/>").parent(),n=e.nextAll(i).first();e.next("br").remove(),s(n)}};s(r.$ed.children(i).first()),r.semanticTag("div",!0),r.$ed.find("p").filter(function(){return(!r.range||this!==r.range.startContainer)&&(0===o(this).text().trim().length&&0===o(this).children().not("br,span").length)}).contents().unwrap(),o("[data-tbw]",r.$ed).contents().unwrap(),r.$ed.find("p:empty").remove()}n||r.restoreRange(),r.syncTextarea()}},semanticTag:function(t,e){var n;if(null!=this.o.semantic&&"object"==typeof this.o.semantic&&this.o.semantic.hasOwnProperty(t))n=this.o.semantic[t];else{if(!0!==this.o.semantic||!this.DEFAULT_SEMANTIC_MAP.hasOwnProperty(t))return;n=this.DEFAULT_SEMANTIC_MAP[t]}o(t,this.$ed).each(function(){var t=o(this);if(0===t.contents().length)return!1;t.wrap("<"+n+"/>"),e&&o.each(t.prop("attributes"),function(){t.parent().attr(this.name,this.value)}),t.contents().unwrap()})},createLink:function(){for(var t,e,n,r=this,i=r.doc.getSelection(),a=i.focusNode,s=(new XMLSerializer).serializeToString(i.getRangeAt(0).cloneContents());["A","DIV"].indexOf(a.nodeName)<0;)a=a.parentNode;if(a&&"A"===a.nodeName){var l=o(a);s=l.text(),t=l.attr("href"),r.o.minimalLinks||(e=l.attr("title"),n=l.attr("target"));var c=r.doc.createRange();c.selectNode(a),i.removeAllRanges(),i.addRange(c)}r.saveRange();var u={url:{label:"URL",required:!0,value:t},text:{label:r.lang.text,value:s}};r.o.minimalLinks||Object.assign(u,{title:{label:r.lang.title,value:e},target:{label:r.lang.target,value:n}}),r.openModalInsert(r.lang.createLink,u,function(t){var e=r.prependUrlPrefix(t.url);if(!e.length)return!1;var n=o(['<a href="',e,'">',t.text||t.url,"</a>"].join(""));return r.o.minimalLinks||(t.title.length>0&&n.attr("title",t.title),t.target.length>0&&n.attr("target",t.target)),r.range.deleteContents(),r.range.insertNode(n[0]),r.syncCode(),r.$c.trigger("tbwchange"),!0})},prependUrlPrefix:function(t){if(!this.urlPrefix)return t;if(/^([a-z][-+.a-z0-9]*:|\/|#)/i.test(t))return t;return/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(t)?"mailto:"+t:this.urlPrefix+t},unlink:function(){var t=this,e=t.doc.getSelection(),n=e.focusNode;if(e.isCollapsed){for(;["A","DIV"].indexOf(n.nodeName)<0;)n=n.parentNode;if(n&&"A"===n.nodeName){var o=t.doc.createRange();o.selectNode(n),e.removeAllRanges(),e.addRange(o)}}t.execCmd("unlink",void 0,void 0,!0)},insertImage:function(){var t=this;t.saveRange();var e={url:{label:"URL",required:!0},alt:{label:t.lang.description,value:t.getRangeText()}};t.o.imageWidthModalEdit&&(e.width={}),t.openModalInsert(t.lang.insertImage,e,function(e){t.execCmd("insertImage",e.url,!1,!0);var n=o('img[src="'+e.url+'"]:not([alt])',t.$box);return n.attr("alt",e.alt),t.o.imageWidthModalEdit&&n.attr({width:e.width}),t.syncCode(),t.$c.trigger("tbwchange"),!0})},fullscreen:function(){var t,n=this,r=n.o.prefix,i=r+"fullscreen";n.$box.toggleClass(i),t=n.$box.hasClass(i),o("body").toggleClass(r+"body-fullscreen",t),o(e).trigger("scroll"),n.$c.trigger("tbw"+(t?"open":"close")+"fullscreen")},execCmd:function(t,e,n,o){var r=this;o=!!o||"","dropdown"!==t&&r.$ed.focus();try{r.doc.execCommand("styleWithCSS",!1,n||!1)}catch(t){}try{r[t+o](e)}catch(n){try{t(e)}catch(n){"insertHorizontalRule"===t?e=void 0:"formatBlock"===t&&r.isIE&&(e="<"+e+">"),r.doc.execCommand(t,!1,e),r.syncCode(),r.semanticCode(!1,!0)}"dropdown"!==t&&(r.updateButtonPaneStatus(),r.$c.trigger("tbwchange"))}},openModal:function(t,n){var r=this,i=r.o.prefix;if(o("."+i+"modal-box",r.$box).length>0)return!1;r.o.autogrowOnEnter&&(r.autogrowOnEnterDontClose=!0),r.saveRange(),r.showOverlay(),r.$btnPane.addClass(i+"disable");var a=o("<div/>",{class:i+"modal "+i+"fixed-top"}).css({top:r.$box.offset().top+r.$btnPane.height(),zIndex:99999}).appendTo(o(r.doc.body));r.$overlay.one("click",function(){return a.trigger("tbwcancel"),!1});var s=o("<form/>",{action:"",html:n}).on("submit",function(){return a.trigger("tbwconfirm"),!1}).on("reset",function(){return a.trigger("tbwcancel"),!1}).on("submit reset",function(){r.o.autogrowOnEnter&&(r.autogrowOnEnterDontClose=!1)}),l=o("<div/>",{class:i+"modal-box",html:s}).css({top:"-"+r.$btnPane.outerHeight()+"px",opacity:0}).appendTo(a).animate({top:0,opacity:1},100);return o("<span/>",{text:t,class:i+"modal-title"}).prependTo(l),a.height(l.outerHeight()+10),o("input:first",l).focus(),r.buildModalBtn("submit",l),r.buildModalBtn("reset",l),o(e).trigger("scroll"),a},buildModalBtn:function(t,e){var n=this.o.prefix;return o("<button/>",{class:n+"modal-button "+n+"modal-"+t,type:t,text:this.lang[t]||t}).appendTo(o("form",e))},closeModal:function(){var t=this,e=t.o.prefix;t.$btnPane.removeClass(e+"disable"),t.$overlay.off();var r=o("."+e+"modal-box",o(n.body));r.animate({top:"-"+r.height()},100,function(){r.parent().remove(),t.hideOverlay()}),t.restoreRange()},openModalInsert:function(t,e,n){var r=this,i=r.o.prefix,a=r.lang,s="";return o.each(e,function(t,e){var n=e.label||t,o=e.name||t,r=e.attributes||{},l=Object.keys(r).map(function(t){return t+'="'+r[t]+'"'}).join(" ");s+='<label><input type="'+(e.type||"text")+'" name="'+o+'"'+("checkbox"===e.type&&e.value?' checked="checked"':' value="'+(e.value||"").replace(/"/g,"&quot;"))+'"'+l+'><span class="'+i+'input-infos"><span>'+(a[n]?a[n]:n)+"</span></span></label>"}),r.openModal(t,s).on("tbwconfirm",function(){var t=o("form",o(this)),i=!0,a={};o.each(e,function(e,n){var s=n.name||e,l=o('input[name="'+s+'"]',t);switch(l.attr("type").toLowerCase()){case"checkbox":a[s]=l.is(":checked");break;case"radio":a[s]=l.filter(":checked").val();break;default:a[s]=o.trim(l.val())}n.required&&""===a[s]?(i=!1,r.addErrorOnModalField(l,r.lang.required)):n.pattern&&!n.pattern.test(a[s])&&(i=!1,r.addErrorOnModalField(l,n.patternError))}),i&&(r.restoreRange(),n(a,e)&&(r.syncCode(),r.$c.trigger("tbwchange"),r.closeModal(),o(this).off("tbwconfirm")))}).one("tbwcancel",function(){o(this).off("tbwconfirm"),r.closeModal()})},addErrorOnModalField:function(t,e){var n=this.o.prefix,r=t.parent();t.on("change keyup",function(){r.removeClass(n+"input-error")}),r.addClass(n+"input-error").find("input+span").append(o("<span/>",{class:n+"msg-error",text:e}))},getDefaultImgDblClickHandler:function(){var t=this;return function(){var e=o(this),n=e.attr("src");0===n.indexOf("data:image")&&(n="(Base64)");var r={url:{label:"URL",value:n,required:!0},alt:{label:t.lang.description,value:e.attr("alt")}};return t.o.imageWidthModalEdit&&(r.width={value:e.attr("width")?e.attr("width"):""}),t.openModalInsert(t.lang.insertImage,r,function(n){return"(Base64)"!==n.url&&e.attr({src:n.url}),e.attr({alt:n.alt}),t.o.imageWidthModalEdit&&(parseInt(n.width)>0?e.attr({width:n.width}):e.removeAttr("width")),!0}),!1}},saveRange:function(){var t=this,e=t.doc.getSelection();if(t.range=null,e&&e.rangeCount){var n,o=t.range=e.getRangeAt(0),r=t.doc.createRange();r.selectNodeContents(t.$ed[0]),r.setEnd(o.startContainer,o.startOffset),n=(r+"").length,t.metaRange={start:n,end:n+(o+"").length}}},restoreRange:function(){var t,e=this,n=e.metaRange,o=e.range,r=e.doc.getSelection();if(o){if(n&&n.start!==n.end){var i,a=0,s=[e.$ed[0]],l=!1,c=!1;for(t=e.doc.createRange();!c&&(i=s.pop());)if(3===i.nodeType){var u=a+i.length;!l&&n.start>=a&&n.start<=u&&(t.setStart(i,n.start-a),l=!0),l&&n.end>=a&&n.end<=u&&(t.setEnd(i,n.end-a),c=!0),a=u}else for(var d=i.childNodes,f=d.length;f>0;)f-=1,s.push(d[f])}r.removeAllRanges(),r.addRange(t||o)}},getRangeText:function(){return this.range+""},updateButtonPaneStatus:function(){var t=this,e=t.o.prefix,n=t.getTagsRecursive(t.doc.getSelection().focusNode),r=e+"active-button "+e+"active";o("."+e+"active-button",t.$btnPane).removeClass(r),o.each(n,function(n,i){var a=t.tagToButton[i.toLowerCase()],s=o("."+e+a+"-button",t.$btnPane);if(s.length>0)s.addClass(r);else try{var l=(s=o("."+e+"dropdown ."+e+a+"-dropdown-button",t.$box)).parent().data("dropdown");o("."+e+l+"-button",t.$box).addClass(r)}catch(t){}})},getTagsRecursive:function(t,e){var n=this;if(e=e||(t&&t.tagName?[t.tagName]:[]),!t||!t.parentNode)return e;var r=(t=t.parentNode).tagName;return"DIV"===r?e:("P"===r&&""!==t.style.textAlign&&e.push(t.style.textAlign),o.each(n.tagHandlers,function(o,r){e=e.concat(r(t,n))}),e.push(r),n.getTagsRecursive(t,e).filter(function(t){return null!=t}))},initPlugins:function(){var t=this;t.loadedPlugins=[],o.each(o.trumbowyg.plugins,function(e,n){n.shouldInit&&!n.shouldInit(t)||(n.init(t),n.tagHandler&&t.tagHandlers.push(n.tagHandler),t.loadedPlugins.push(n))})},destroyPlugins:function(){o.each(this.loadedPlugins,function(t,e){e.destroy&&e.destroy()})}}}(navigator,window,document,jQuery)},yLpj:function(t,e){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(t){"object"==typeof window&&(n=window)}t.exports=n}});