/*
* # Fomantic UI - 2.8.8
* https://github.com/fomantic/Fomantic-UI
* http://fomantic-ui.com/
*
* Copyright 2022 Contributors
* Released under the MIT license
* http://opensource.org/licenses/MIT
*
*/
!function(A,e,D){"use strict";A.isFunction=A.isFunction||function(e){return"function"==typeof e&&"number"!=typeof e.nodeType},e=void 0!==e&&e.Math==Math?e:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")(),A.fn.toast=function(w){var k,e=A(this),T=e.selector||"",x=(new Date).getTime(),I=[],P=w,O="string"==typeof P,M=[].slice.call(arguments,1);return e.each(function(){var t,o,a,s,i,c,l,r=A.isPlainObject(w)?A.extend(!0,{},A.fn.toast.settings,w):A.extend({},A.fn.toast.settings),u=r.className,d=r.selector,p=r.error,e=r.namespace,f=r.fields,n="."+e,m=e+"-module",g=A(this),h=r.context?A(r.context):A("body"),v=g.hasClass("toast")||g.hasClass("message")||g.hasClass("card"),b=this,C=v?g.data(m):D,y={initialize:function(){y.verbose("Initializing element"),y.has.container()||y.create.container(),(v||""!==r.message||""!==r.title||""!==y.get.iconClass()||r.showImage||y.has.configActions())&&("string"==typeof r.showProgress&&-1!==[u.top,u.bottom].indexOf(r.showProgress)||(r.showProgress=!1),y.create.toast(),r.closeOnClick&&(r.closeIcon||0",{class:r.position+" "+u.container+" "+(r.horizontal?u.horizontal:"")}))},toast:function(){t=A("
",{class:u.box});var e,n=y.get.iconClass();v?(o=r.cloneModule?g.clone().removeAttr("id"):g,l=o.find("> i"+y.helpers.toClass(u.close)),r.closeIcon=0"),e=A("",{class:u.content}),""!==n&&o.append(A("",{class:n+" "+u.icon})),r.showImage&&o.append(A("",{class:u.image+" "+r.classImage,src:r.showImage})),""!==r.title&&e.append(A("",{class:u.title,text:r.title})),e.append(A("",{class:u.message,html:y.helpers.escape(r.message,r.preserveHTML)})),o.addClass(r.class+" "+u.toast).append(e),o.css("opacity",r.opacity),r.closeIcon&&((l=A("",{class:u.close+" "+("string"==typeof r.closeIcon?r.closeIcon:"")})).hasClass(u.left)?o.prepend(l):o.append(l))),o.hasClass(u.compact)&&(r.compact=!0),o.hasClass("card")&&(r.compact=!1),a=o.find(".actions"),y.has.configActions()&&(0===a.length&&(a=A("",{class:u.actions+" "+(r.classActions||"")}).appendTo(o)),o.hasClass("card")&&!a.hasClass(u.attached)&&(a.addClass(u.extraContent),a.hasClass(u.vertical)&&(a.removeClass(u.vertical),y.error(p.verticalCard))),r.actions.forEach(function(e){var n=e[f.icon]?'':"",t=y.helpers.escape(e[f.text]||"",r.preserveHTML),o=y.helpers.deQuote(e[f.class]||""),s=e[f.click]&&A.isFunction(e[f.click])?e[f.click]:function(){};a.append(A("",{html:n+t,class:u.button+" "+o,click:function(){!1!==s.call(b,g)&&y.close()}}))})),a&&a.hasClass(u.vertical)&&o.addClass(u.vertical),0",{class:u.vertical+" "+u.attached+" "+(r.compact?u.compact:"")})),a.hasClass(u.left)?o.addClass(u.left).parent().addClass(u.left).prepend(a):o.parent().append(a)):a.hasClass(u.top)?(t.prepend(a),o.addClass(u.bottom)):(t.append(a),o.addClass(u.top))),g!==o&&(b=(g=o)[0]),0",{class:u.progress+" "+(r.classProgress||r.class),"data-percent":""}),r.classProgress||(o.hasClass("toast")&&!o.hasClass(u.inverted)?s.addClass(u.inverted):s.removeClass(u.inverted)),i=A("",{class:"bar "+(r.progressUp?"up ":"down ")+n}),s.addClass(r.showProgress).append(i),s.hasClass(u.top)?t.prepend(s):t.append(s),i.css("animation-duration",r.displayTime/1e3+"s")),(c=A("",{class:"wait "+n})).css("animation-duration",r.displayTime/1e3+"s"),c.appendTo(o)),r.compact&&(t.addClass(u.compact),o.addClass(u.compact),s&&s.addClass(u.compact)),r.newestOnTop?t.prependTo(y.get.container()):t.appendTo(y.get.container())}},bind:{events:function(){y.debug("Binding events to toast"),(r.closeOnClick||r.closeIcon)&&(r.closeIcon?l:o).on("click"+n,y.event.click),c&&c.on("animationend"+n,y.close),t.on("click"+n,d.approve,y.event.approve).on("click"+n,d.deny,y.event.deny)}},unbind:{events:function(){y.debug("Unbinding events to toast"),(r.closeOnClick||r.closeIcon)&&(r.closeIcon?l:o).off("click"+n),c&&c.off("animationend"+n),t.off("click"+n)}},animate:{show:function(e){e=A.isFunction(e)?e:function(){},r.transition&&y.can.useElement("transition")&&g.transition("is supported")&&(y.set.visible(),t.transition({animation:r.transition.showMethod+" in",queue:!1,debug:r.debug,verbose:r.verbose,duration:r.transition.showDuration,onComplete:function(){e.call(t,b),r.onVisible.call(t,b)}}))},close:function(e){e=A.isFunction(e)?e:function(){},y.debug("Closing toast"),!1===r.onHide.call(t,b)?y.debug("onHide callback returned false, cancelling toast animation"):r.transition&&A.fn.transition!==D&&g.transition("is supported")?t.transition({animation:r.transition.hideMethod+" out",queue:!1,duration:r.transition.hideDuration,debug:r.debug,verbose:r.verbose,interval:50,onBeforeHide:function(e){e=A.isFunction(e)?e:function(){},""!==r.transition.closeEasing?t&&(t.css("opacity",0),t.wrap("").parent().hide(r.transition.closeDuration,r.transition.closeEasing,function(){t&&(t.parent().remove(),e.call(t))})):e.call(t)},onComplete:function(){e.call(t,b),r.onHidden.call(t,b),y.destroy()}}):y.error(p.noTransition)},pause:function(){c.css("animationPlayState","paused"),i&&i.css("animationPlayState","paused")},continue:function(){c.css("animationPlayState","running"),i&&i.css("animationPlayState","running")}},has:{container:function(){return y.verbose("Determining if there is already a container"),0":">",'"':""","'":"'","`":"`"};return/[&<>"'`]/.test(e)?(e=e.replace(/&(?![a-z0-9#]{1,6};)/,"&")).replace(/[<>"'`]/g,function(e){return t[e]}):e}},can:{useElement:function(e){return A.fn[e]!==D||(y.error(p.noElement.replace("{element}",e)),!1)}},setting:function(e,n){if(y.debug("Changing setting",e,n),A.isPlainObject(e))A.extend(!0,r,e);else{if(n===D)return r[e];A.isPlainObject(r[e])?A.extend(!0,r[e],n):r[e]=n}},internal:function(e,n){if(A.isPlainObject(e))A.extend(!0,y,e);else{if(n===D)return y[e];y[e]=n}},debug:function(){!r.silent&&r.debug&&(r.performance?y.performance.log(arguments):(y.debug=Function.prototype.bind.call(console.info,console,r.name+":"),y.debug.apply(console,arguments)))},verbose:function(){!r.silent&&r.verbose&&r.debug&&(r.performance?y.performance.log(arguments):(y.verbose=Function.prototype.bind.call(console.info,console,r.name+":"),y.verbose.apply(console,arguments)))},error:function(){r.silent||(y.error=Function.prototype.bind.call(console.error,console,r.name+":"),y.error.apply(console,arguments))},performance:{log:function(e){var n,t;r.performance&&(t=(n=(new Date).getTime())-(x||n),x=n,I.push({Name:e[0],Arguments:[].slice.call(e,1)||"",Element:b,"Execution Time":t})),clearTimeout(y.performance.timer),y.performance.timer=setTimeout(y.performance.display,500)},display:function(){var e=r.name+":",t=0;x=!1,clearTimeout(y.performance.timer),A.each(I,function(e,n){t+=n["Execution Time"]}),e+=" "+t+"ms",T&&(e+=" '"+T+"'"),(console.group!==D||console.table!==D)&&0 img.image, > .image > img",icon:"> i.icon",input:'input:not([type="hidden"]), textarea, select, button, .ui.button, ui.dropdown',approve:".actions .positive, .actions .approve, .actions .ok",deny:".actions .negative, .actions .deny, .actions .cancel"},fields:{class:"class",text:"text",icon:"icon",click:"click"},onShow:function(){},onVisible:function(){},onClick:function(){},onHide:function(){},onHidden:function(){},onRemove:function(){},onApprove:function(){},onDeny:function(){}},A.extend(A.easing,{easeOutBounce:function(e,n,t,o,s){return(n/=s)<1/2.75?o*(7.5625*n*n)+t:n<2/2.75?o*(7.5625*(n-=1.5/2.75)*n+.75)+t:n<2.5/2.75?o*(7.5625*(n-=2.25/2.75)*n+.9375)+t:o*(7.5625*(n-=2.625/2.75)*n+.984375)+t},easeOutCubic:function(e){return--e*e*e+1}})}(jQuery,window,void document);