(function(d){var h={callback:function(){},runOnLoad:!0,frequency:100,previousVisibility:null},g={checkVisibility:function(b,a){if(jQuery.contains(document,b[0])){var f=a.previousVisibility,c=b.is(":visible");a.previousVisibility=c;var e=null==f;e?a.runOnLoad&&a.callback(b,c,e):f!==c&&a.callback(b,c,e);setTimeout(function(){g.checkVisibility(b,a)},a.frequency)}}};d.fn.visibilityChanged=function(b){var a=d.extend({},h,b);return this.each(function(){g.checkVisibility(d(this),a)})}})(jQuery);
(function(e){"function"===typeof define&&define.amd?define(["jquery"],e):"object"===typeof exports?e(require("jquery")):e(jQuery)})(function(e){var b=function(a,c){this.$element=e(a);this.options=e.extend({},b.DEFAULTS,this.dataOptions(),c);this.init()};b.DEFAULTS={from:0,to:0,speed:1E3,refreshInterval:100,decimals:0,formatter:function(a,c){return a.toFixed(c.decimals)},onUpdate:null,onComplete:null};b.prototype.init=function(){this.value=this.options.from;this.loops=Math.ceil(this.options.speed/
this.options.refreshInterval);this.loopCount=0;this.increment=(this.options.to-this.options.from)/this.loops};b.prototype.dataOptions=function(){var a={from:this.$element.data("from"),to:this.$element.data("to"),speed:this.$element.data("speed"),refreshInterval:this.$element.data("refresh-interval"),decimals:this.$element.data("decimals")},c=Object.keys(a),d;for(d in c){var f=c[d];"undefined"===typeof a[f]&&delete a[f]}return a};b.prototype.update=function(){this.value+=this.increment;this.loopCount++;
this.render();"function"==typeof this.options.onUpdate&&this.options.onUpdate.call(this.$element,this.value);this.loopCount>=this.loops&&(clearInterval(this.interval),this.value=this.options.to,"function"==typeof this.options.onComplete&&this.options.onComplete.call(this.$element,this.value))};b.prototype.render=function(){var a=this.options.formatter.call(this.$element,this.value,this.options);this.$element.text(a)};b.prototype.restart=function(){this.stop();this.init();this.start()};b.prototype.start=
function(){this.stop();this.render();this.interval=setInterval(this.update.bind(this),this.options.refreshInterval)};b.prototype.stop=function(){this.interval&&clearInterval(this.interval)};b.prototype.toggle=function(){this.interval?this.stop():this.start()};e.fn.countTo=function(a){return this.each(function(){var c=e(this),d=c.data("countTo"),f="object"===typeof a?a:{},g="string"===typeof a?a:"start";d&&"object"!==typeof a||(d&&d.stop(),c.data("countTo",d=new b(this,f)));d[g].call(d)})}});
!function(t,e,a,n){var r="ajaxWizard",i={contentUrl:null,controlSelectors:{forward:".forward",backward:".backward"},beforeForward:function(){return!0},afterForward:function(){return!0},afterCachedForward:function(){return!0},beforeBackward:function(){return!0},afterBackward:function(){return!0}};function s(e,a){this.element=e,this.settings=t.extend({},i,a),this._defaults=i,this._name=r,this.init()}t.extend(s.prototype,{init:function(){t(this.element).find("fieldset:first-child").addClass("current"),this.eventListeners()},currentStep:function(){return t(this.element).find("fieldset.current")},getContentUrl:function(){if(null===this.settings.contentUrl)throw new Error("contentUrl not defined");return this.settings.contentUrl},getAcceptLanguage:function(){if(null===this.settings.AcceptLanguage)throw new Error("AcceptLanguage not defined");return this.settings.AcceptLanguage},generateUniqueKey:function(){return(Math.random()*Math.random()).toString(16).substr(2,16)},whenCallingNextStep:function(e){t(e).data("ajax-wizard-key")&&t(e).data("ajax-wizard-hash")===this.currentStep().serialize()?(this.animate(this.currentStep(),t("."+t(e).data("ajax-wizard-key"))),this.afterCachedForwardCallback(this.element)):(t("."+t(e).data("ajax-wizard-key")).remove(),this.forward(e))},beforeForwardCallback:function(){return this.settings.beforeForward.call(this,this.element)},afterForwardCallback:function(){return this.settings.afterForward.call(this,this.element)},afterCachedForwardCallback:function(){return this.settings.afterCachedForward.call(this,this.element)},beforeBackwardCallback:function(){return this.settings.beforeBackward.call(this,this.element)},afterBackwardCallback:function(){return this.settings.afterBackward.call(this,this.element)},ajaxRequest:function(e){var a=this,n=this.currentStep().find("input, select, textarea").serialize();t.ajax({url:a.getContentUrl(),dataType:"html",method:"post",data:n,headers:{"Accept-Language":a.getAcceptLanguage()},success:function(r){a.currentStep().after("<fieldset>"+r+"</fieldset>");var i=a.currentStep().next("fieldset");a.animate(a.currentStep(),i);var s=a.generateUniqueKey();t(e).data("ajax-wizard-key",s),t(e).data("ajax-wizard-hash",n),i.addClass(s),a.afterForwardCallback(this.element)}})},forward:function(t){!0===this.beforeForwardCallback()&&this.ajaxRequest(t)},backward:function(){!0===this.beforeBackwardCallback()&&(this.animate(this.currentStep(),this.currentStep().prev("fieldset")),this.afterBackwardCallback())},eventListeners:function(){var e=this;t(this.element).on("submit",function(t){t.preventDefault(),e.whenCallingNextStep(this)}),t(this.element).on("click",this.settings.controlSelectors.forward,function(){e.whenCallingNextStep(this)}),t(this.element).on("click",this.settings.controlSelectors.backward,function(){e.backward()})},animate:function(t,e){t.hide().removeClass("current"),e.fadeIn().addClass("current")}}),t.fn[r]=function(e){return this.each(function(){t.data(this,"plugin_"+r)||t.data(this,"plugin_"+r,new s(this,e))}),this}}(jQuery,window,document);
!function(d){var h=function(a,b){this.init("tooltip",a,b)};h.prototype={constructor:h,init:function(a,b,c){this.type=a;this.$element=d(b);this.options=this.getOptions(c);this.enabled=!0;b=this.options.trigger.split(" ");for(c=b.length;c--;){var e=b[c];if("click"==e)this.$element.on("click."+this.type,this.options.selector,d.proxy(this.toggle,this));else"manual"!=e&&(a="hover"==e?"mouseenter":"focus",e="hover"==e?"mouseleave":"blur",this.$element.on(a+"."+this.type,this.options.selector,d.proxy(this.enter,
this)),this.$element.on(e+"."+this.type,this.options.selector,d.proxy(this.leave,this)))}this.options.selector?this._options=d.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},getOptions:function(a){a=d.extend({},d.fn[this.type].defaults,this.$element.data(),a);a.delay&&"number"==typeof a.delay&&(a.delay={show:a.delay,hide:a.delay});return a},enter:function(a){var b=d.fn[this.type].defaults,c={};this._options&&d.each(this._options,function(f,g){b[f]!=g&&(c[f]=g)},this);var e=
d(a.currentTarget)[this.type](c).data(this.type);if(!e.options.delay||!e.options.delay.show)return e.show();clearTimeout(this.timeout);e.hoverState="in";this.timeout=setTimeout(function(){"in"==e.hoverState&&e.show()},e.options.delay.show)},leave:function(a){var b=d(a.currentTarget)[this.type](this._options).data(this.type);this.timeout&&clearTimeout(this.timeout);if(!b.options.delay||!b.options.delay.hide)return b.hide();b.hoverState="out";this.timeout=setTimeout(function(){"out"==b.hoverState&&
b.hide()},b.options.delay.hide)},show:function(){var a=d.Event("show");if(this.hasContent()&&this.enabled&&(this.$element.trigger(a),!a.isDefaultPrevented())){var b=this.tip();this.setContent();this.options.animation&&b.addClass("fade");var c="function"==typeof this.options.placement?this.options.placement.call(this,b[0],this.$element[0]):this.options.placement;b.detach().css({top:0,left:0,display:"block"});this.options.container?b.appendTo(this.options.container):b.insertAfter(this.$element);a=this.getPosition();
var e=b[0].offsetWidth;b=b[0].offsetHeight;switch(c){case "bottom":var f={top:a.top+a.height,left:a.left+a.width/2-e/2};break;case "top":f={top:a.top-b,left:a.left+a.width/2-e/2};break;case "left":f={top:a.top+a.height/2-b/2,left:a.left-e};break;case "right":f={top:a.top+a.height/2-b/2,left:a.left+a.width}}this.applyPlacement(f,c);this.$element.trigger("shown")}},applyPlacement:function(a,b){var c=this.tip(),e=c[0].offsetWidth,f=c[0].offsetHeight;c.offset(a).addClass(b).addClass("in");var g=c[0].offsetWidth;
var k=c[0].offsetHeight;if("top"==b&&k!=f){a.top=a.top+f-k;var l=!0}"bottom"==b||"top"==b?(b=0,0>a.left&&(b=-2*a.left,a.left=0,c.offset(a),g=c[0].offsetWidth),this.replaceArrow(b-e+g,g,"left")):this.replaceArrow(k-f,k,"top");l&&c.offset(a)},replaceArrow:function(a,b,c){this.arrow().css(c,a?50*(1-a/b)+"%":"")},setContent:function(){var a=this.tip(),b=this.getTitle();a.find(".tooltip-inner")[this.options.html?"html":"text"](b);a.removeClass("fade in top bottom left right")},hide:function(){function a(){var e=
setTimeout(function(){b.off(d.support.transition.end).detach()},500);b.one(d.support.transition.end,function(){clearTimeout(e);b.detach()})}var b=this.tip(),c=d.Event("hide");this.$element.trigger(c);if(!c.isDefaultPrevented())return b.removeClass("in"),d.support.transition&&this.$tip.hasClass("fade")?a():b.detach(),this.$element.trigger("hidden"),this},fixTitle:function(){var a=this.$element;(a.attr("title")||"string"!=typeof a.attr("data-original-title"))&&a.attr("data-original-title",a.attr("title")||
"").attr("title","")},hasContent:function(){return this.getTitle()},getPosition:function(){var a=this.$element[0];return d.extend({},"function"==typeof a.getBoundingClientRect?a.getBoundingClientRect():{width:a.offsetWidth,height:a.offsetHeight},this.$element.offset())},getTitle:function(){var a=this.$element,b=this.options;return a.attr("data-original-title")||("function"==typeof b.title?b.title.call(a[0]):b.title)},tip:function(){return this.$tip=this.$tip||d(this.options.template)},arrow:function(){return this.$arrow=
this.$arrow||this.tip().find(".tooltip-arrow")},validate:function(){this.$element[0].parentNode||(this.hide(),this.options=this.$element=null)},enable:function(){this.enabled=!0},disable:function(){this.enabled=!1},toggleEnabled:function(){this.enabled=!this.enabled},toggle:function(a){a=a?d(a.currentTarget)[this.type](this._options).data(this.type):this;a.tip().hasClass("in")?a.hide():a.show()},destroy:function(){this.hide().$element.off("."+this.type).removeData(this.type)}};var m=d.fn.tooltip;
d.fn.tooltip=function(a){return this.each(function(){var b=d(this),c=b.data("tooltip"),e="object"==typeof a&&a;c||b.data("tooltip",c=new h(this,e));if("string"==typeof a)c[a]()})};d.fn.tooltip.Constructor=h;d.fn.tooltip.defaults={animation:!0,placement:"top",selector:!1,template:'\x3cdiv class\x3d"tooltip"\x3e\x3cdiv class\x3d"tooltip-arrow"\x3e\x3c/div\x3e\x3cdiv class\x3d"tooltip-inner"\x3e\x3c/div\x3e\x3c/div\x3e',trigger:"hover focus",title:"",delay:0,html:!1,container:!1};d.fn.tooltip.noConflict=
function(){d.fn.tooltip=m;return this}}(window.jQuery);
!function(b){var e=function(a,c){this.init("popover",a,c)};e.prototype=b.extend({},b.fn.tooltip.Constructor.prototype,{constructor:e,setContent:function(){var a=this.tip(),c=this.getTitle(),d=this.getContent();a.find(".popover-title")[this.options.html?"html":"text"](c);a.find(".popover-content")[this.options.html?"html":"text"](d);a.removeClass("fade top bottom left right in")},hasContent:function(){return this.getTitle()||this.getContent()},getContent:function(){var a=this.$element,c=this.options;
return("function"==typeof c.content?c.content.call(a[0]):c.content)||a.attr("data-content")},tip:function(){this.$tip||(this.$tip=b(this.options.template));return this.$tip},destroy:function(){this.hide().$element.off("."+this.type).removeData(this.type)}});var f=b.fn.popover;b.fn.popover=function(a){return this.each(function(){var c=b(this),d=c.data("popover"),g="object"==typeof a&&a;d||c.data("popover",d=new e(this,g));if("string"==typeof a)d[a]()})};b.fn.popover.Constructor=e;b.fn.popover.defaults=
b.extend({},b.fn.tooltip.defaults,{placement:"right",trigger:"click",content:"",template:'\x3cdiv class\x3d"popover"\x3e\x3cdiv class\x3d"arrow"\x3e\x3c/div\x3e\x3ch3 class\x3d"popover-title"\x3e\x3c/h3\x3e\x3cdiv class\x3d"popover-content"\x3e\x3c/div\x3e\x3c/div\x3e'});b.fn.popover.noConflict=function(){b.fn.popover=f;return this}}(window.jQuery);
