/*
* # Fomantic UI - 2.9.0-beta.311+116f84b
* https://github.com/fomantic/Fomantic-UI
* http://fomantic-ui.com/
*
* Copyright 2022 Contributors
* Released under the MIT license
* http://opensource.org/licenses/MIT
*
*/
!function(D,E,H,z){"use strict";D.isFunction=D.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")(),D.fn.toast=function(x){var k,e=D(this),T=e.selector||"",I=(new Date).getTime(),P=[],M=x,O="string"==typeof M,A=[].slice.call(arguments,1);return e.each(function(){var t,o,a,s,i,c,l,e,r=D.isPlainObject(x)?D.extend(!0,{},D.fn.toast.settings,x):D.extend({},D.fn.toast.settings),u=r.className,d=r.selector,p=r.error,n=r.namespace,f=r.fields,g="."+n,m=n+"-module",h=D(this),b=r.context?[E,H].indexOf(r.context)<0?D(H).find(r.context):D(r.context):D("body"),v=h.hasClass("toast")||h.hasClass("message")||h.hasClass("card"),C=this,y=v?h.data(m):z,w={initialize:function(){w.verbose("Initializing element"),w.create.id(),w.has.container()||w.create.container(),(v||""!==r.message||""!==r.title||""!==w.get.iconClass()||r.showImage||w.has.configActions())&&("string"==typeof r.showProgress&&-1!==[u.top,u.bottom].indexOf(r.showProgress)||(r.showProgress=!1),w.create.toast(),r.closeOnClick&&(r.closeIcon||0",{class:r.position+" "+u.container+" "+(r.horizontal?u.horizontal:"")+" "+(r.context&&"body"!==r.context?u.absolute:"")}))},id:function(){e=(Math.random().toString(16)+"000000000").slice(2,10),w.verbose("Creating unique id for element",e)},toast:function(){t=D("
",{class:u.box});var e,n=w.get.iconClass();v?(o=r.cloneModule?h.clone().removeAttr("id"):h,l=o.find("> i"+w.helpers.toClass(u.close)),r.closeIcon=0",{role:"alert"}),e=D("",{class:u.content}),""!==n&&o.append(D("",{class:n+" "+u.icon})),r.showImage&&o.append(D("",{class:u.image+" "+r.classImage,src:r.showImage})),""!==r.title&&(n="_"+w.get.id()+"title",o.attr("aria-labelledby",n),e.append(D("",{class:u.title,id:n,html:w.helpers.escape(r.title,r.preserveHTML)}))),n="_"+w.get.id()+"desc",o.attr("aria-describedby",n),e.append(D("",{class:u.message,id:n,html:w.helpers.escape(r.message,r.preserveHTML)})),o.addClass(r.class+" "+u.toast).append(e),o.css("opacity",r.opacity),r.closeIcon&&((l=D("",{class:u.close+" "+("string"==typeof r.closeIcon?r.closeIcon:""),role:"button",tabindex:0,"aria-label":r.text.close})).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"),w.has.configActions()&&(0===a.length&&(a=D("",{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),w.error(p.verticalCard))),r.actions.forEach(function(e){var n=e[f.icon]?"':"",t=w.helpers.escape(e[f.text]||"",r.preserveHTML),o=w.helpers.deQuote(e[f.class]||""),s=e[f.click]&&D.isFunction(e[f.click])?e[f.click]:function(){};a.append(D("",{html:n+t,"aria-label":(e[f.text]||e[f.icon]||"").replace(/<[^>]+(>|$)/g,""),class:u.button+" "+o,click:function(){var e=D(this);e.is(d.approve)||e.is(d.deny)||!1===s.call(C,h)||w.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))),h!==o&&(C=(h=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=D("",{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=D("",{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(w.get.container()):t.appendTo(w.get.container())}},bind:{events:function(){w.debug("Binding events to toast"),r.closeIcon&&l.on("click"+g,w.event.close),o.on("click"+g,w.event.click),c&&c.on("animationend"+g,w.event.close),t.on("click"+g,d.approve,w.event.approve).on("click"+g,d.deny,w.event.deny)}},unbind:{events:function(){w.debug("Unbinding events to toast"),r.closeIcon&&l.off("click"+g),o.off("click"+g),c&&c.off("animationend"+g),t.off("click"+g)}},animate:{show:function(e){e=D.isFunction(e)?e:function(){},r.transition&&w.can.useElement("transition")&&h.transition("is supported")&&(w.set.visible(),t.transition({animation:r.transition.showMethod+" in",queue:!1,debug:r.debug,verbose:r.verbose,silent:r.silent,duration:r.transition.showDuration,onComplete:function(){e.call(t,C),r.onVisible.call(t,C)}}))},close:function(e){e=D.isFunction(e)?e:function(){},r.transition&&D.fn.transition!==z&&h.transition("is supported")?t.transition({animation:r.transition.hideMethod+" out",queue:!1,duration:r.transition.hideDuration,debug:r.debug,verbose:r.verbose,silent:r.silent,interval:50,onBeforeHide:function(e){e=D.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,C),r.onHidden.call(t,C),w.destroy()}}):w.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 w.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 D.fn[e]!==z||(w.error(p.noElement.replace("{element}",e)),!1)}},setting:function(e,n){if(w.debug("Changing setting",e,n),D.isPlainObject(e))D.extend(!0,r,e);else{if(n===z)return r[e];D.isPlainObject(r[e])?D.extend(!0,r[e],n):r[e]=n}},internal:function(e,n){if(D.isPlainObject(e))D.extend(!0,w,e);else{if(n===z)return w[e];w[e]=n}},debug:function(){!r.silent&&r.debug&&(r.performance?w.performance.log(arguments):(w.debug=Function.prototype.bind.call(console.info,console,r.name+":"),w.debug.apply(console,arguments)))},verbose:function(){!r.silent&&r.verbose&&r.debug&&(r.performance?w.performance.log(arguments):(w.verbose=Function.prototype.bind.call(console.info,console,r.name+":"),w.verbose.apply(console,arguments)))},error:function(){r.silent||(w.error=Function.prototype.bind.call(console.error,console,r.name+":"),w.error.apply(console,arguments))},performance:{log:function(e){var n,t;r.performance&&(t=(n=(new Date).getTime())-(I||n),I=n,P.push({Name:e[0],Arguments:[].slice.call(e,1)||"",Element:C,"Execution Time":t})),clearTimeout(w.performance.timer),w.performance.timer=setTimeout(w.performance.display,500)},display:function(){var e=r.name+":",t=0;I=!1,clearTimeout(w.performance.timer),D.each(P,function(e,n){t+=n["Execution Time"]}),e+=" "+t+"ms",T&&(e+=" '"+T+"'"),(console.group!==z||console.table!==z)&&0 img.image, > .image > img",icon:"> i.icon",input:'input:not([type="hidden"]), textarea, select, button, .ui.button, ui.dropdown',clickable:"a, details, .ui.accordion",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(){}},D.extend(D.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,document);