diff --git a/dist/bootstrap-native-v4.js b/dist/bootstrap-native-v4.js index 68121057..fdf315b4 100644 --- a/dist/bootstrap-native-v4.js +++ b/dist/bootstrap-native-v4.js @@ -518,13 +518,13 @@ var pauseHandler = function () { if ( self[interval] !==false && !hasClass(element,paused) ) { addClass(element,paused); - !isSliding && clearInterval( timer ); + !isSliding && ( clearInterval(timer), timer = null ); } }, resumeHandler = function() { if ( self[interval] !== false && hasClass(element,paused) ) { removeClass(element,paused); - !isSliding && clearInterval( timer ); + !isSliding && ( clearInterval(timer), timer = null ); !isSliding && self.cycle(); } }, @@ -583,6 +583,11 @@ // public methods this.cycle = function() { + if (timer) { + clearInterval(timer); + timer = null; + } + timer = setInterval(function() { isElementInScrollRange() && (index++, self.slideTo( index ) ); }, this[interval]); @@ -605,7 +610,7 @@ // find the right next index if ( next < 0 ) { next = total - 1; } - else if ( next === total ){ next = 0; } + else if ( next >= total ){ next = 0; } // update index index = next; @@ -615,6 +620,7 @@ isSliding = true; clearInterval(timer); + timer = null; setActivePage( next ); if ( supportTransitions && hasClass(element,'slide') ) { @@ -894,7 +900,7 @@ bootstrapCustomEvent.call(parent, showEvent, component, relatedTarget); addClass(menu,showClass); addClass(parent,showClass); - menu[setAttribute](ariaExpanded,true); + element[setAttribute](ariaExpanded,true); bootstrapCustomEvent.call(parent, shownEvent, component, relatedTarget); element[open] = true; off(element, clickEvent, clickHandler); @@ -907,7 +913,7 @@ bootstrapCustomEvent.call(parent, hideEvent, component, relatedTarget); removeClass(menu,showClass); removeClass(parent,showClass); - menu[setAttribute](ariaExpanded,false); + element[setAttribute](ariaExpanded,false); bootstrapCustomEvent.call(parent, hiddenEvent, component, relatedTarget); element[open] = false; toggleDismiss(); diff --git a/dist/bootstrap-native-v4.min.js b/dist/bootstrap-native-v4.min.js index fecb8e29..14bdaf74 100644 --- a/dist/bootstrap-native-v4.min.js +++ b/dist/bootstrap-native-v4.min.js @@ -1,2 +1,2 @@ // Native Javascript for Bootstrap 4 v2.0.24 | © dnp_theme | MIT-License -!function(t,e){if("function"==typeof define&&define.amd)define([],e);else if("object"==typeof module&&module.exports)module.exports=e();else{var n=e();t.Alert=n.Alert,t.Button=n.Button,t.Carousel=n.Carousel,t.Collapse=n.Collapse,t.Dropdown=n.Dropdown,t.Modal=n.Modal,t.Popover=n.Popover,t.ScrollSpy=n.ScrollSpy,t.Tab=n.Tab,t.Tooltip=n.Tooltip}}(this,function(){"use strict";var t="undefined"!=typeof global?global:this||window,e=document,n=e.documentElement,i="body",o=t.BSN={},a=o.supports=[],l="data-toggle",r="data-dismiss",c="data-spy",u="data-ride",s="Alert",f="Button",h="Carousel",d="Collapse",v="Dropdown",p="Modal",m="Popover",g="ScrollSpy",w="Tab",b="Tooltip",y="data-backdrop",T="data-keyboard",x="data-target",C="data-interval",A="data-height",k="data-pause",I="data-title",N="data-original-title",L="data-dismissible",E="data-trigger",S="data-animation",B="data-container",D="data-placement",M="data-delay",P="backdrop",H="keyboard",O="delay",W="content",j="target",q="interval",R="pause",U="animation",z="placement",F="container",X="offsetTop",Y="offsetLeft",G="scrollTop",J="scrollLeft",K="clientWidth",Q="clientHeight",V="offsetWidth",Z="offsetHeight",$="innerWidth",_="innerHeight",tt="scrollHeight",et="height",nt="aria-expanded",it="aria-hidden",ot="click",at="hover",lt="keydown",rt="keyup",ct="resize",ut="scroll",st="show",ft="shown",ht="hide",dt="hidden",vt="close",pt="closed",mt="slid",gt="slide",wt="change",bt="getAttribute",yt="setAttribute",Tt="hasAttribute",xt="createElement",Ct="appendChild",At="innerHTML",kt="getElementsByTagName",It="preventDefault",Nt="getBoundingClientRect",Lt="querySelectorAll",Et="getElementsByClassName",St="getComputedStyle",Bt="indexOf",Dt="parentNode",Mt="length",Pt="toLowerCase",Ht="Transition",Ot="Duration",Wt="Webkit",jt="style",qt="push",Rt="tabindex",Ut="contains",zt="active",Ft="show",Xt="collapsing",Yt="left",Gt="right",Jt="top",Kt="bottom",Qt="onmouseleave"in e?["mouseenter","mouseleave"]:["mouseover","mouseout"],Vt=/\b(top|bottom|left|right)+/,Zt=0,$t="fixed-top",_t="fixed-bottom",te=Wt+Ht in n[jt]||Ht[Pt]()in n[jt],ee=Wt+Ht in n[jt]?Wt[Pt]()+Ht+"End":Ht[Pt]()+"end",ne=Wt+Ot in n[jt]?Wt[Pt]()+Ht+Ot:Ht[Pt]()+Ot,ie=function(t){t.focus?t.focus():t.setActive()},oe=function(t,e){t.classList.add(e)},ae=function(t,e){t.classList.remove(e)},le=function(t,e){return t.classList[Ut](e)},re=function(t,e){return[].slice.call(t[Et](e))},ce=function(t,n){var i=n?n:e;return"object"==typeof t?t:i.querySelector(t)},ue=function(t,n){var i=n.charAt(0),o=n.substr(1);if("."===i){for(;t&&t!==e;t=t[Dt])if(null!==ce(n,t[Dt])&&le(t,o))return t}else if("#"===i)for(;t&&t!==e;t=t[Dt])if(t.id===o)return t;return!1},se=function(t,e,n){t.addEventListener(e,n,!1)},fe=function(t,e,n){t.removeEventListener(e,n,!1)},he=function(t,e,n){se(t,e,function i(o){n(o),fe(t,e,i)})},de=function(e){var n=t[St](e)[ne];return n=parseFloat(n),n="number"!=typeof n||isNaN(n)?0:1e3*n,n+50},ve=function(t,e){var n=0,i=de(t);te&&he(t,ee,function(t){e(t),n=1}),setTimeout(function(){!n&&e()},i)},pe=function(t,e,n){var i=new CustomEvent(t+".bs."+e);i.relatedTarget=n,this.dispatchEvent(i)},me=function(){return{y:t.pageYOffset||n[G],x:t.pageXOffset||n[J]}},ge=function(t,o,a,l){var r,c,u,s,f,h,d={w:o[V],h:o[Z]},v=n[K]||e[i][K],p=n[Q]||e[i][Q],m=t[Nt](),g=l===e[i]?me():{x:l[Y]+l[J],y:l[X]+l[G]},w={w:m[Gt]-m[Yt],h:m[Kt]-m[Jt]},b=le(o,"popover"),y=ce(".arrow",o),T=m[Jt]+w.h/2-d.h/2<0,x=m[Yt]+w.w/2-d.w/2<0,C=m[Yt]+d.w/2+w.w/2>=v,A=m[Jt]+d.h/2+w.h/2>=p,k=m[Jt]-d.h<0,I=m[Yt]-d.w<0,N=m[Jt]+d.h+w.h>=p,L=m[Yt]+d.w+w.w>=v;a=(a===Yt||a===Gt)&&I&&L?Jt:a,a=a===Jt&&k?Kt:a,a=a===Kt&&N?Jt:a,a=a===Yt&&I?Gt:a,a=a===Gt&&L?Yt:a,o.className[Bt](a)===-1&&(o.className=o.className.replace(Vt,a)),f=y[V],h=y[Z],a===Yt||a===Gt?(c=a===Yt?m[Yt]+g.x-d.w-(b?f:0):m[Yt]+g.x+w.w,T?(r=m[Jt]+g.y,u=w.h/2-f):A?(r=m[Jt]+g.y-d.h+w.h,u=d.h-w.h/2-f):(r=m[Jt]+g.y-d.h/2+w.h/2,u=d.h/2-(b?.9*h:h/2))):a!==Jt&&a!==Kt||(r=a===Jt?m[Jt]+g.y-d.h-(b?h:0):m[Jt]+g.y+w.h,x?(c=0,s=m[Yt]+w.w/2-f):C?(c=v-1.01*d.w,s=d.w-(v-m[Yt])+w.w/2-f/2):(c=m[Yt]+g.x-d.w/2+w.w/2,s=d.w/2-f/2)),o[jt][Jt]=r+"px",o[jt][Yt]=c+"px",u&&(y[jt][Jt]=u+"px"),s&&(y[jt][Yt]=s+"px")};o.version="2.0.24";var we=function(t){t=ce(t);var e=this,n="alert",i=ue(t,"."+n),o=function(){le(i,"fade")?ve(i,l):l()},a=function(o){i=ue(o[j],"."+n),t=ce("["+r+'="'+n+'"]',i),t&&i&&(t===o[j]||t[Ut](o[j]))&&e.close()},l=function(){pe.call(i,pt,n),fe(t,ot,a),i[Dt].removeChild(i)};this.close=function(){i&&t&&le(i,Ft)&&(pe.call(i,vt,n),ae(i,Ft),i&&o())},s in t||se(t,ot,a),t[s]=e};a[qt]([s,we,"["+r+'="alert"]']);var be=function(t){t=ce(t);var n=!1,i="button",o="checked",a="LABEL",l="INPUT",r=function(t){var n=t.which||t.keyCode;32===n&&t[j]===e.activeElement&&u(t)},c=function(t){var e=t.which||t.keyCode;32===e&&t[It]()},u=function(e){var r=e[j].tagName===a?e[j]:e[j][Dt].tagName===a?e[j][Dt]:null;if(r){var c=e[j],u=re(c[Dt],"btn"),s=r[kt](l)[0];if(s){if("checkbox"===s.type&&(s[o]?(ae(r,zt),s[bt](o),s.removeAttribute(o),s[o]=!1):(oe(r,zt),s[bt](o),s[yt](o,o),s[o]=!0),n||(n=!0,pe.call(s,wt,i),pe.call(t,wt,i))),"radio"===s.type&&!n&&!s[o]){oe(r,zt),s[yt](o,o),s[o]=!0,pe.call(s,wt,i),pe.call(t,wt,i),n=!0;for(var f=0,h=u[Mt];f=0},W=function(t){for(var e=0,n=E[Mt];et||o===x-1&&0===t)&&(A=m[d]=Gt),t<0?t=x-1:t===x&&(t=0),g=t,n=A===Yt?"next":"prev",pe.call(i,gt,s,y[t]),b=!0,clearInterval(w),W(t),te&&le(i,"slide")?(oe(y[t],v+"-"+n),y[t][V],oe(y[t],v+"-"+A),oe(y[o],v+"-"+A),he(y[t],ee,function(a){var l=a[j]!==y[t]?1e3*a.elapsedTime+100:20;b&&setTimeout(function(){b=!1,oe(y[t],zt),ae(y[o],zt),ae(y[t],v+"-"+n),ae(y[t],v+"-"+A),ae(y[o],v+"-"+A),pe.call(i,mt,s,y[t]),e.hidden||!m[q]||le(i,f)||m.cycle()},l)})):(oe(y[t],zt),y[t][V],ae(y[o],zt),setTimeout(function(){b=!1,m[q]&&!le(i,f)&&m.cycle(),pe.call(i,mt,s,y[t])},100)))}},this.getActiveIndex=function(){return y[Bt](re(i,v+" active")[0])||0},h in i||(m[R]&&m[q]&&(se(i,Qt[0],S),se(i,Qt[1],B),se(i,"touchstart",S),se(i,"touchend",B)),N&&se(N,ot,M),I&&se(I,ot,M),L&&se(L,ot,D),m[H]===!0&&se(t,lt,P)),m.getActiveIndex()<0&&(y[Mt]&&oe(y[0],zt),E[Mt]&&W(0)),m[q]&&m.cycle(),i[h]=m};a[qt]([h,ye,"["+u+'="carousel"]']);var Te=function(t,e){t=ce(t),e=e||{};var n,i,o=null,a=null,r=this,c=t[bt]("data-parent"),u="collapse",s="collapsed",f="isAnimating",h=function(t,e){pe.call(t,st,u),t[f]=!0,oe(t,Xt),ae(t,u),t[jt][et]=t[tt]+"px",ve(t,function(){t[f]=!1,t[yt](nt,"true"),e[yt](nt,"true"),ae(t,Xt),oe(t,u),oe(t,Ft),t[jt][et]="",pe.call(t,ft,u)})},v=function(t,e){pe.call(t,ht,u),t[f]=!0,t[jt][et]=t[tt]+"px",ae(t,u),ae(t,Ft),oe(t,Xt),t[V],t[jt][et]="0px",ve(t,function(){t[f]=!1,t[yt](nt,"false"),e[yt](nt,"false"),ae(t,Xt),oe(t,u),t[jt][et]="",pe.call(t,dt,u)})},p=function(){var e=t.href&&t[bt]("href"),n=t[bt](x),i=e||n&&"#"===n.charAt(0)&&n;return i&&ce(i)};this.toggle=function(t){t[It](),le(a,Ft)?r.hide():r.show()},this.hide=function(){a[f]||(v(a,t),oe(t,s))},this.show=function(){o&&(n=ce("."+u+"."+Ft,o),i=n&&(ce("["+l+'="'+u+'"]['+x+'="#'+n.id+'"]',o)||ce("["+l+'="'+u+'"][href="#'+n.id+'"]',o))),(!a[f]||n&&!n[f])&&(i&&n!==a&&(v(n,i),oe(i,s)),h(a,t),ae(t,s))},d in t||se(t,ot,r.toggle),a=p(),a[f]=!1,o=ce(e.parent)||c&&ue(t,c),t[d]=r};a[qt]([d,Te,"["+l+'="collapse"]']);var xe=function(t,n){t=ce(t),this.persist=n===!0||"true"===t[bt]("data-persist")||!1;var i=this,o="children",a=t[Dt],l="dropdown",r="open",c=null,u=ce(".dropdown-menu",a),s=function(){for(var t=u[o],e=[],n=0;n1?l-1:0:40===o&&ln[Q],b=S()},D=function(){s[jt][d]=!g&&w?b+"px":"",s[jt][v]=g&&!w?b+"px":""},M=function(){s[jt][d]="",s[jt][v]=""},O=function(){Zt=1;var t=e[xt]("div");C=ce("."+m),null===C&&(t[yt]("class",m+" fade"),C=t,e[i][Ct](C))},q=function(){C=ce("."+m),C&&null!==C&&"object"==typeof C&&(Zt=0,e[i].removeChild(C),C=null),pe.call(s,dt,f)},R=function(){le(s,Ft)?se(e,lt,G):fe(e,lt,G)},U=function(){le(s,Ft)?se(t,ct,A.update):fe(t,ct,A.update)},z=function(){le(s,Ft)?se(s,ot,J):fe(s,ot,J)},F=function(){ie(s),pe.call(s,ft,f,k)},X=function(){s[jt].display="",o&&ie(o),function(){re(e,f+" "+Ft)[0]||(M(),E(),ae(e[i],f+"-open"),C&&le(C,"fade")?(ae(C,Ft),ve(C,q)):q(),U(),z(),R())}()},Y=function(t){var e=t[j];e=e[Tt](x)||e[Tt]("href")?e:e[Dt],e!==o||le(s,Ft)||(s.modalTrigger=o,k=o,A.show(),t[It]())},G=function(t){A[H]&&27==t.which&&le(s,Ft)&&A.hide()},J=function(t){var e=t[j];le(s,Ft)&&(e[Dt][bt](r)===f||e[bt](r)===f||e===s&&A[P]!==h)&&(A.hide(),k=null,t[It]())};this.toggle=function(){le(s,Ft)?this.hide():this.show()},this.show=function(){pe.call(s,st,f,k);var t=re(e,f+" "+Ft)[0];t&&t!==s&&t.modalTrigger[p].hide(),this[P]&&!Zt&&O(),C&&Zt&&!le(C,Ft)&&(C[V],l=de(C),oe(C,Ft)),setTimeout(function(){s[jt].display="block",B(),L(),D(),oe(e[i],f+"-open"),oe(s,Ft),s[yt](it,!1),U(),z(),R(),le(s,"fade")?ve(s,F):F()},te&&C?l:0)},this.hide=function(){pe.call(s,ht,f),C=ce("."+m),l=C&&de(C),ae(s,Ft),s[yt](it,!0),setTimeout(function(){le(s,"fade")?ve(s,X):X()},te&&C?l:0)},this.setContent=function(t){ce("."+f+"-content",s)[At]=t},this.update=function(){le(s,Ft)&&(B(),L(),D())},!o||p in o||se(o,ot,Y),A[W]&&A.setContent(A[W]),!!o&&(o[p]=A)}};a[qt]([p,Ce,"["+l+'="modal"]']);var Ae=function(n,o){n=ce(n),o=o||{};var a=n[bt](E),l=n[bt](S),r=n[bt](D),c=n[bt](L),u=n[bt](M),s=n[bt](B),f="popover",h="template",d="trigger",v="class",p="div",g="fade",w="data-content",b="dismissible",y='',T=ce(o[F]),x=ce(s),C=ue(n,".modal"),A=ue(n,"."+$t),k=ue(n,"."+_t);this[h]=o[h]?o[h]:null,this[d]=o[d]?o[d]:a||at,this[U]=o[U]&&o[U]!==g?o[U]:l||g,this[z]=o[z]?o[z]:r||Jt,this[O]=parseInt(o[O]||u)||200,this[b]=!(!o[b]&&"true"!==c),this[F]=T?T:x?x:A?A:k?k:C?C:e[i];var N=this,P=n[bt](I)||null,H=n[bt](w)||null;if(H||this[h]){var W=null,q=0,R=this[z],X=function(t){null!==W&&t[j]===ce(".close",W)&&N.hide()},Y=function(){N[F].removeChild(W),q=null,W=null},G=function(){P=n[bt](I),H=n[bt](w),W=e[xt](p);var t=e[xt](p);if(t[yt](v,"arrow"),W[Ct](t),null!==H&&null===N[h]){if(W[yt]("role","tooltip"),null!==P){var i=e[xt]("h3");i[yt](v,f+"-header"),i[At]=N[b]?P+y:P,W[Ct](i)}var o=e[xt](p);o[yt](v,f+"-body"),o[At]=N[b]&&null===P?H+y:H,W[Ct](o)}else{var a=e[xt](p);a[At]=N[h],W[At]=a.firstChild[At]}N[F][Ct](W),W[jt].display="block",W[yt](v,f+" bs-"+f+"-"+R+" "+N[U])},J=function(){!le(W,Ft)&&oe(W,Ft)},K=function(){ge(n,W,R,N[F])},Q=function(i){ot!=N[d]&&"focus"!=N[d]||!N[b]&&i(n,"blur",N.hide),N[b]&&i(e,ot,X),i(t,ct,N.hide)},V=function(){Q(se),pe.call(n,ft,f)},Z=function(){Q(fe),Y(),pe.call(n,dt,f)};this.toggle=function(){null===W?N.show():N.hide()},this.show=function(){clearTimeout(q),q=setTimeout(function(){null===W&&(R=N[z],G(),K(),J(),pe.call(n,st,f),N[U]?ve(W,V):V())},20)},this.hide=function(){clearTimeout(q),q=setTimeout(function(){W&&null!==W&&le(W,Ft)&&(pe.call(n,ht,f),ae(W,Ft),N[U]?ve(W,Z):Z())},N[O])},m in n||(N[d]===at?(se(n,Qt[0],N.show),N[b]||se(n,Qt[1],N.hide)):ot!=N[d]&&"focus"!=N[d]||se(n,N[d],N.toggle)),n[m]=N}};a[qt]([m,Ae,"["+l+'="popover"]']);var ke=function(e,n){e=ce(e);var i=ce(e[bt](x)),o=e[bt]("data-offset");if(n=n||{},n[j]||i){for(var a,l=this,r=n[j]&&ce(n[j])||i,c=r&&r[kt]("A"),u=parseInt(o||n.offset)||10,s=[],f=[],h=e[Z]=h&&v>a;if(!c&&p)le(n,zt)||(oe(n,zt),l&&!le(l,zt)&&oe(l,zt),pe.call(e,"activate","scrollspy",s[t]));else if(p){if(!p&&!c||c&&p)return}else le(n,zt)&&(ae(n,zt),l&&le(l,zt)&&!re(n[Dt],zt).length&&ae(l,zt))},y=function(){a=d?me().y:e[G];for(var t=0,n=s[Mt];t1&&(t=e[e[Mt]-1]):t=e[0],t},k=function(){return ce(C()[bt]("href"))},I=function(t){var e=t[j][bt]("href");t[It](),c=t[j][bt](l)===i||e&&"#"===e.charAt(0)?t[j]:t[j][Dt],!m[r]&&!le(c,zt)&&p.show()};this.show=function(){c=c||t,f=ce(c[bt]("href")),u=C(),s=k(),m[r]=!0,ae(u,zt),oe(c,zt),b&&(le(t[Dt],"dropdown-menu")?le(b,zt)||oe(b,zt):le(b,zt)&&ae(b,zt)),pe.call(u,ht,i,c),le(s,"fade")?(ae(s,Ft),ve(s,x)):x()},w in t||se(t,ot,I),p[o]&&(g=k()[Dt]),t[w]=p}};a[qt]([w,Ie,"["+l+'="tab"]']);var Ne=function(n,o){n=ce(n),o=o||{};var a=n[bt](S),l=n[bt](D),r=n[bt](M),c=n[bt](B),u="tooltip",s="class",f="title",h="fade",d="div",v=ce(o[F]),p=ce(c),m=ue(n,".modal"),g=ue(n,"."+$t),w=ue(n,"."+_t);this[U]=o[U]&&o[U]!==h?o[U]:a||h,this[z]=o[z]?o[z]:l||Jt,this[O]=parseInt(o[O]||r)||200,this[F]=v?v:p?p:g?g:w?w:m?m:e[i];var y=this,T=0,x=this[z],C=null,A=n[bt](f)||n[bt](I)||n[bt](N);if(A&&""!=A){var k=function(){y[F].removeChild(C),C=null,T=null},L=function(){if(A=n[bt](f)||n[bt](I)||n[bt](N),!A||""==A)return!1;C=e[xt](d),C[yt]("role",u);var t=e[xt](d);t[yt](s,"arrow"),C[Ct](t);var i=e[xt](d);i[yt](s,u+"-inner"),C[Ct](i),i[At]=A,y[F][Ct](C),C[yt](s,u+" bs-"+u+"-"+x+" "+y[U])},E=function(){ge(n,C,x,y[F])},P=function(){!le(C,Ft)&&oe(C,Ft)},H=function(){se(t,ct,y.hide),pe.call(n,ft,u)},W=function(){fe(t,ct,y.hide),k(),pe.call(n,dt,u)};this.show=function(){clearTimeout(T),T=setTimeout(function(){if(null===C){if(x=y[z],0==L())return;E(),P(),pe.call(n,st,u),y[U]?ve(C,H):H()}},20)},this.hide=function(){clearTimeout(T),T=setTimeout(function(){C&&le(C,Ft)&&(pe.call(n,ht,u),ae(C,Ft),y[U]?ve(C,W):W())},y[O])},this.toggle=function(){C?y.hide():y.show()},b in n||(n[yt](N,A),n.removeAttribute(f),se(n,Qt[0],y.show),se(n,Qt[1],y.hide)),n[b]=y}};a[qt]([b,Ne,"["+l+'="tooltip"]']);var Le=function(t,e){for(var n=0,i=e[Mt];n=v,A=m[Jt]+d.h/2+w.h/2>=p,k=m[Jt]-d.h<0,I=m[Yt]-d.w<0,N=m[Jt]+d.h+w.h>=p,L=m[Yt]+d.w+w.w>=v;a=(a===Yt||a===Gt)&&I&&L?Jt:a,a=a===Jt&&k?Kt:a,a=a===Kt&&N?Jt:a,a=a===Yt&&I?Gt:a,a=a===Gt&&L?Yt:a,o.className[Bt](a)===-1&&(o.className=o.className.replace(Vt,a)),f=y[V],h=y[Z],a===Yt||a===Gt?(c=a===Yt?m[Yt]+g.x-d.w-(b?f:0):m[Yt]+g.x+w.w,T?(r=m[Jt]+g.y,u=w.h/2-f):A?(r=m[Jt]+g.y-d.h+w.h,u=d.h-w.h/2-f):(r=m[Jt]+g.y-d.h/2+w.h/2,u=d.h/2-(b?.9*h:h/2))):a!==Jt&&a!==Kt||(r=a===Jt?m[Jt]+g.y-d.h-(b?h:0):m[Jt]+g.y+w.h,x?(c=0,s=m[Yt]+w.w/2-f):C?(c=v-1.01*d.w,s=d.w-(v-m[Yt])+w.w/2-f/2):(c=m[Yt]+g.x-d.w/2+w.w/2,s=d.w/2-f/2)),o[jt][Jt]=r+"px",o[jt][Yt]=c+"px",u&&(y[jt][Jt]=u+"px"),s&&(y[jt][Yt]=s+"px")};o.version="2.0.24";var bn=function(t){t=un(t);var n=this,e="alert",i=sn(t,"."+e),o=function(){rn(i,"fade")?pn(i,l):l()},a=function(o){i=sn(o[j],"."+e),t=un("["+r+'="'+e+'"]',i),t&&i&&(t===o[j]||t[Ut](o[j]))&&n.close()},l=function(){mn.call(i,pt,e),hn(t,ot,a),i[Dt].removeChild(i)};this.close=function(){i&&t&&rn(i,Ft)&&(mn.call(i,vt,e),ln(i,Ft),i&&o())},s in t||fn(t,ot,a),t[s]=n};a[qt]([s,bn,"["+r+'="alert"]']);var yn=function(t){t=un(t);var e=!1,i="button",o="checked",a="LABEL",l="INPUT",r=function(t){var e=t.which||t.keyCode;32===e&&t[j]===n.activeElement&&u(t)},c=function(t){var n=t.which||t.keyCode;32===n&&t[It]()},u=function(n){var r=n[j].tagName===a?n[j]:n[j][Dt].tagName===a?n[j][Dt]:null;if(r){var c=n[j],u=cn(c[Dt],"btn"),s=r[kt](l)[0];if(s){if("checkbox"===s.type&&(s[o]?(ln(r,zt),s[bt](o),s.removeAttribute(o),s[o]=!1):(an(r,zt),s[bt](o),s[yt](o,o),s[o]=!0),e||(e=!0,mn.call(s,wt,i),mn.call(t,wt,i))),"radio"===s.type&&!e&&!s[o]){an(r,zt),s[yt](o,o),s[o]=!0,mn.call(s,wt,i),mn.call(t,wt,i),e=!0;for(var f=0,h=u[Mt];f=0},W=function(t){for(var n=0,e=E[Mt];nt||o===x-1&&0===t)&&(A=m[d]=Gt),t<0?t=x-1:t>=x&&(t=0),g=t,e=A===Yt?"next":"prev",mn.call(i,gt,s,y[t]),b=!0,clearInterval(w),w=null,W(t),tn&&rn(i,"slide")?(an(y[t],v+"-"+e),y[t][V],an(y[t],v+"-"+A),an(y[o],v+"-"+A),dn(y[t],nn,function(a){var l=a[j]!==y[t]?1e3*a.elapsedTime+100:20;b&&setTimeout(function(){b=!1,an(y[t],zt),ln(y[o],zt),ln(y[t],v+"-"+e),ln(y[t],v+"-"+A),ln(y[o],v+"-"+A),mn.call(i,mt,s,y[t]),n.hidden||!m[q]||rn(i,f)||m.cycle()},l)})):(an(y[t],zt),y[t][V],ln(y[o],zt),setTimeout(function(){b=!1,m[q]&&!rn(i,f)&&m.cycle(),mn.call(i,mt,s,y[t])},100)))}},this.getActiveIndex=function(){return y[Bt](cn(i,v+" active")[0])||0},h in i||(m[R]&&m[q]&&(fn(i,Qt[0],S),fn(i,Qt[1],B),fn(i,"touchstart",S),fn(i,"touchend",B)),N&&fn(N,ot,M),I&&fn(I,ot,M),L&&fn(L,ot,D),m[H]===!0&&fn(t,lt,P)),m.getActiveIndex()<0&&(y[Mt]&&an(y[0],zt),E[Mt]&&W(0)),m[q]&&m.cycle(),i[h]=m};a[qt]([h,Tn,"["+u+'="carousel"]']);var xn=function(t,n){t=un(t),n=n||{};var e,i,o=null,a=null,r=this,c=t[bt]("data-parent"),u="collapse",s="collapsed",f="isAnimating",h=function(t,n){mn.call(t,st,u),t[f]=!0,an(t,Xt),ln(t,u),t[jt][nt]=t[tt]+"px",pn(t,function(){t[f]=!1,t[yt](et,"true"),n[yt](et,"true"),ln(t,Xt),an(t,u),an(t,Ft),t[jt][nt]="",mn.call(t,ft,u)})},v=function(t,n){mn.call(t,ht,u),t[f]=!0,t[jt][nt]=t[tt]+"px",ln(t,u),ln(t,Ft),an(t,Xt),t[V],t[jt][nt]="0px",pn(t,function(){t[f]=!1,t[yt](et,"false"),n[yt](et,"false"),ln(t,Xt),an(t,u),t[jt][nt]="",mn.call(t,dt,u)})},p=function(){var n=t.href&&t[bt]("href"),e=t[bt](x),i=n||e&&"#"===e.charAt(0)&&e;return i&&un(i)};this.toggle=function(t){t[It](),rn(a,Ft)?r.hide():r.show()},this.hide=function(){a[f]||(v(a,t),an(t,s))},this.show=function(){o&&(e=un("."+u+"."+Ft,o),i=e&&(un("["+l+'="'+u+'"]['+x+'="#'+e.id+'"]',o)||un("["+l+'="'+u+'"][href="#'+e.id+'"]',o))),(!a[f]||e&&!e[f])&&(i&&e!==a&&(v(e,i),an(i,s)),h(a,t),ln(t,s))},d in t||fn(t,ot,r.toggle),a=p(),a[f]=!1,o=un(n.parent)||c&&sn(t,c),t[d]=r};a[qt]([d,xn,"["+l+'="collapse"]']);var Cn=function(t,e){t=un(t),this.persist=e===!0||"true"===t[bt]("data-persist")||!1;var i=this,o="children",a=t[Dt],l="dropdown",r="open",c=null,u=un(".dropdown-menu",a),s=function(){for(var t=u[o],n=[],e=0;e1?l-1:0:40===o&&le[Q],b=S()},D=function(){s[jt][d]=!g&&w?b+"px":"",s[jt][v]=g&&!w?b+"px":""},M=function(){s[jt][d]="",s[jt][v]=""},O=function(){Zt=1;var t=n[xt]("div");C=un("."+m),null===C&&(t[yt]("class",m+" fade"),C=t,n[i][Ct](C))},q=function(){C=un("."+m),C&&null!==C&&"object"==typeof C&&(Zt=0,n[i].removeChild(C),C=null),mn.call(s,dt,f)},R=function(){rn(s,Ft)?fn(n,lt,G):hn(n,lt,G)},U=function(){rn(s,Ft)?fn(t,ct,A.update):hn(t,ct,A.update)},z=function(){rn(s,Ft)?fn(s,ot,J):hn(s,ot,J)},F=function(){on(s),mn.call(s,ft,f,k)},X=function(){s[jt].display="",o&&on(o),function(){cn(n,f+" "+Ft)[0]||(M(),E(),ln(n[i],f+"-open"),C&&rn(C,"fade")?(ln(C,Ft),pn(C,q)):q(),U(),z(),R())}()},Y=function(t){var n=t[j];n=n[Tt](x)||n[Tt]("href")?n:n[Dt],n!==o||rn(s,Ft)||(s.modalTrigger=o,k=o,A.show(),t[It]())},G=function(t){A[H]&&27==t.which&&rn(s,Ft)&&A.hide()},J=function(t){var n=t[j];rn(s,Ft)&&(n[Dt][bt](r)===f||n[bt](r)===f||n===s&&A[P]!==h)&&(A.hide(),k=null,t[It]())};this.toggle=function(){rn(s,Ft)?this.hide():this.show()},this.show=function(){mn.call(s,st,f,k);var t=cn(n,f+" "+Ft)[0];t&&t!==s&&t.modalTrigger[p].hide(),this[P]&&!Zt&&O(),C&&Zt&&!rn(C,Ft)&&(C[V],l=vn(C),an(C,Ft)),setTimeout(function(){s[jt].display="block",B(),L(),D(),an(n[i],f+"-open"),an(s,Ft),s[yt](it,!1),U(),z(),R(),rn(s,"fade")?pn(s,F):F()},tn&&C?l:0)},this.hide=function(){mn.call(s,ht,f),C=un("."+m),l=C&&vn(C),ln(s,Ft),s[yt](it,!0),setTimeout(function(){rn(s,"fade")?pn(s,X):X()},tn&&C?l:0)},this.setContent=function(t){un("."+f+"-content",s)[At]=t},this.update=function(){rn(s,Ft)&&(B(),L(),D())},!o||p in o||fn(o,ot,Y),A[W]&&A.setContent(A[W]),!!o&&(o[p]=A)}};a[qt]([p,An,"["+l+'="modal"]']);var kn=function(e,o){e=un(e),o=o||{};var a=e[bt](E),l=e[bt](S),r=e[bt](D),c=e[bt](L),u=e[bt](M),s=e[bt](B),f="popover",h="template",d="trigger",v="class",p="div",g="fade",w="data-content",b="dismissible",y='',T=un(o[F]),x=un(s),C=sn(e,".modal"),A=sn(e,"."+$t),k=sn(e,"."+_t);this[h]=o[h]?o[h]:null,this[d]=o[d]?o[d]:a||at,this[U]=o[U]&&o[U]!==g?o[U]:l||g,this[z]=o[z]?o[z]:r||Jt,this[O]=parseInt(o[O]||u)||200,this[b]=!(!o[b]&&"true"!==c),this[F]=T?T:x?x:A?A:k?k:C?C:n[i];var N=this,P=e[bt](I)||null,H=e[bt](w)||null;if(H||this[h]){var W=null,q=0,R=this[z],X=function(t){null!==W&&t[j]===un(".close",W)&&N.hide()},Y=function(){N[F].removeChild(W),q=null,W=null},G=function(){P=e[bt](I),H=e[bt](w),W=n[xt](p);var t=n[xt](p);if(t[yt](v,"arrow"),W[Ct](t),null!==H&&null===N[h]){if(W[yt]("role","tooltip"),null!==P){var i=n[xt]("h3");i[yt](v,f+"-header"),i[At]=N[b]?P+y:P,W[Ct](i)}var o=n[xt](p);o[yt](v,f+"-body"),o[At]=N[b]&&null===P?H+y:H,W[Ct](o)}else{var a=n[xt](p);a[At]=N[h],W[At]=a.firstChild[At]}N[F][Ct](W),W[jt].display="block",W[yt](v,f+" bs-"+f+"-"+R+" "+N[U])},J=function(){!rn(W,Ft)&&an(W,Ft)},K=function(){wn(e,W,R,N[F])},Q=function(i){ot!=N[d]&&"focus"!=N[d]||!N[b]&&i(e,"blur",N.hide),N[b]&&i(n,ot,X),i(t,ct,N.hide)},V=function(){Q(fn),mn.call(e,ft,f)},Z=function(){Q(hn),Y(),mn.call(e,dt,f)};this.toggle=function(){null===W?N.show():N.hide()},this.show=function(){clearTimeout(q),q=setTimeout(function(){null===W&&(R=N[z],G(),K(),J(),mn.call(e,st,f),N[U]?pn(W,V):V())},20)},this.hide=function(){clearTimeout(q),q=setTimeout(function(){W&&null!==W&&rn(W,Ft)&&(mn.call(e,ht,f),ln(W,Ft),N[U]?pn(W,Z):Z())},N[O])},m in e||(N[d]===at?(fn(e,Qt[0],N.show),N[b]||fn(e,Qt[1],N.hide)):ot!=N[d]&&"focus"!=N[d]||fn(e,N[d],N.toggle)),e[m]=N}};a[qt]([m,kn,"["+l+'="popover"]']);var In=function(n,e){n=un(n);var i=un(n[bt](x)),o=n[bt]("data-offset");if(e=e||{},e[j]||i){for(var a,l=this,r=e[j]&&un(e[j])||i,c=r&&r[kt]("A"),u=parseInt(o||e.offset)||10,s=[],f=[],h=n[Z]=h&&v>a;if(!c&&p)rn(e,zt)||(an(e,zt),l&&!rn(l,zt)&&an(l,zt),mn.call(n,"activate","scrollspy",s[t]));else if(p){if(!p&&!c||c&&p)return}else rn(e,zt)&&(ln(e,zt),l&&rn(l,zt)&&!cn(e[Dt],zt).length&&ln(l,zt))},y=function(){a=d?gn().y:n[G];for(var t=0,e=s[Mt];t1&&(t=n[n[Mt]-1]):t=n[0],t},k=function(){return un(C()[bt]("href"))},I=function(t){var n=t[j][bt]("href");t[It](),c=t[j][bt](l)===i||n&&"#"===n.charAt(0)?t[j]:t[j][Dt],!m[r]&&!rn(c,zt)&&p.show()};this.show=function(){c=c||t,f=un(c[bt]("href")),u=C(),s=k(),m[r]=!0,ln(u,zt),an(c,zt),b&&(rn(t[Dt],"dropdown-menu")?rn(b,zt)||an(b,zt):rn(b,zt)&&ln(b,zt)),mn.call(u,ht,i,c),rn(s,"fade")?(ln(s,Ft),pn(s,x)):x()},w in t||fn(t,ot,I),p[o]&&(g=k()[Dt]),t[w]=p}};a[qt]([w,Nn,"["+l+'="tab"]']);var Ln=function(e,o){e=un(e),o=o||{};var a=e[bt](S),l=e[bt](D),r=e[bt](M),c=e[bt](B),u="tooltip",s="class",f="title",h="fade",d="div",v=un(o[F]),p=un(c),m=sn(e,".modal"),g=sn(e,"."+$t),w=sn(e,"."+_t);this[U]=o[U]&&o[U]!==h?o[U]:a||h,this[z]=o[z]?o[z]:l||Jt,this[O]=parseInt(o[O]||r)||200,this[F]=v?v:p?p:g?g:w?w:m?m:n[i];var y=this,T=0,x=this[z],C=null,A=e[bt](f)||e[bt](I)||e[bt](N);if(A&&""!=A){var k=function(){y[F].removeChild(C),C=null,T=null},L=function(){if(A=e[bt](f)||e[bt](I)||e[bt](N),!A||""==A)return!1;C=n[xt](d),C[yt]("role",u);var t=n[xt](d);t[yt](s,"arrow"),C[Ct](t);var i=n[xt](d);i[yt](s,u+"-inner"),C[Ct](i),i[At]=A,y[F][Ct](C),C[yt](s,u+" bs-"+u+"-"+x+" "+y[U])},E=function(){wn(e,C,x,y[F])},P=function(){!rn(C,Ft)&&an(C,Ft)},H=function(){fn(t,ct,y.hide),mn.call(e,ft,u)},W=function(){hn(t,ct,y.hide),k(),mn.call(e,dt,u)};this.show=function(){clearTimeout(T),T=setTimeout(function(){if(null===C){if(x=y[z],0==L())return;E(),P(),mn.call(e,st,u),y[U]?pn(C,H):H()}},20)},this.hide=function(){clearTimeout(T),T=setTimeout(function(){C&&rn(C,Ft)&&(mn.call(e,ht,u),ln(C,Ft),y[U]?pn(C,W):W())},y[O])},this.toggle=function(){C?y.hide():y.show()},b in e||(e[yt](N,A),e.removeAttribute(f),fn(e,Qt[0],y.show),fn(e,Qt[1],y.hide)),e[b]=y}};a[qt]([b,Ln,"["+l+'="tooltip"]']);var En=function(t,n){for(var e=0,i=n[Mt];e=u,A=p[w]+f.h/2+v.h/2>=h,L=p[w]-f.h<0,H=p[b]-f.w<0,I=p[w]+f.h+v.h>=h,B=p[b]+f.w+v.w>=u;a=(a===b||"right"===a)&&H&&B?w:a,a=a===w&&L?"bottom":a,a="bottom"===a&&I?w:a,a=a===b&&H?"right":a,a="right"===a&&B?b:a,a===b||"right"===a?(c=a===b?p[b]+m.x-f.w:p[b]+m.x+v.w,T?(r=p[w]+m.y,s=v.h/2):A?(r=p[w]+m.y-f.h+v.h,s=f.h-v.h/2):r=p[w]+m.y-f.h/2+v.h/2):a!==w&&"bottom"!==a||(r=a===w?p[w]+m.y-f.h:p[w]+m.y+v.h,k?(c=0,d=p[b]+v.w/2):C?(c=u-1.01*f.w,d=f.w-(u-p[b])+v.w/2):c=p[b]+m.x-f.w/2+v.w/2),o[g][w]=r+"px",o[g][b]=c+"px",s&&(y[g][w]=s+"px"),d&&(y[g][b]=d+"px"),-1===o.className.indexOf(a)&&(o.className=o.className.replace(x,a))};o.version="2.0.24";var X=function(o,a){o=M(o),a=a||{};var l=o[s]("data-target"),c=o[s]("data-offset-top"),d=o[s]("data-offset-bottom"),f="affix",u="function";if(this[r]=a[r]?M(a[r]):M(l)||null,this.offsetTop=a.offsetTop?a.offsetTop:parseInt(c)||0,this.offsetBottom=a.offsetBottom?a.offsetBottom:parseInt(d)||0,this[r]||this.offsetTop||this.offsetBottom){var h,p,g,m,v,b,T=this,x=!1,k=!1,C=function(){return Math.max(e[n].scrollHeight,e[n].offsetHeight,i.clientHeight,i.scrollHeight,i.offsetHeight)},A=function(){return null!==T[r]?T[r].getBoundingClientRect()[w]+m:T.offsetTop?parseInt(typeof T.offsetTop===u?T.offsetTop():T.offsetTop||0):void 0},L=function(){if(T.offsetBottom)return g-o.offsetHeight-parseInt(typeof T.offsetBottom===u?T.offsetBottom():T.offsetBottom||0)},H=function(){g=C(),m=parseInt(U().y,0),h=A(),p=L(),v=parseInt(h)-m<0&&m>parseInt(h),b=parseInt(p)-m<0&&m>parseInt(p)},I=function(){x||N(o,f)||(q.call(o,f,f),q.call(o,"affix-top",f),B(o,f),x=!0,q.call(o,"affixed",f),q.call(o,"affixed-top",f))},D=function(){x&&N(o,f)&&(E(o,f),x=!1)},S=function(){k||N(o,"affix-bottom")||(q.call(o,f,f),q.call(o,"affix-bottom",f),B(o,"affix-bottom"),k=!0,q.call(o,"affixed",f),q.call(o,"affixed-bottom",f))},R=function(){k&&N(o,"affix-bottom")&&(E(o,"affix-bottom"),k=!1)},P=function(){b?(v&&D(),S()):(R(),v?I():D())};this.update=function(){H(),P()},"Affix"in o||(W(t,"scroll",T.update),!y&&W(t,"resize",T.update)),o.Affix=T,T.update()}};a[m](["Affix",X,'[data-spy="affix"]']);var Y=function(t){t=M(t);var e=this,i=R(t,".alert"),n=function(){N(i,"fade")?j(i,a):a()},o=function(n){i=R(n[r],".alert"),(t=M('[data-dismiss="alert"]',i))&&i&&(t===n[r]||t.contains(n[r]))&&e.close()},a=function(){q.call(i,"closed","alert"),P(t,"click",o),i[f].removeChild(i)};this.close=function(){i&&t&&N(i,"in")&&(q.call(i,"close","alert"),E(i,"in"),i&&n())},"Alert"in t||W(t,"click",o),t.Alert=e};a[m](["Alert",Y,'[data-dismiss="alert"]']);var G=function(t,i){t=M(t),i=i||null;var n=!1,o="checked",a=function(t){32===(t.which||t.keyCode)&&t[r]===e.activeElement&&c(t)},l=function(t){32===(t.which||t.keyCode)&&t.preventDefault()},c=function(e){var i="LABEL"===e[r].tagName?e[r]:"LABEL"===e[r][f].tagName?e[r][f]:null;if(i){var a=e[r],l=S(a[f],"btn"),c=i.getElementsByTagName("INPUT")[0];if(c){if("checkbox"===c.type&&(c[o]?(E(i,v),c[s](o),c.removeAttribute(o),c[o]=!1):(B(i,v),c[s](o),c[d](o,o),c[o]=!0),n||(n=!0,q.call(c,"change","button"),q.call(t,"change","button"))),"radio"===c.type&&!n&&!c[o]){B(i,v),c[d](o,o),c[o]=!0,q.call(c,"change","button"),q.call(t,"change","button"),n=!0;for(var h=0,p=l[u];h=0},X=function(t){for(var e=0,i=D[u];et||n===y-1&&0===t)&&(x=f.direction="right"),t<0?t=y-1:t>=y&&(t=0),h=t,i=x===b?"next":"prev",q.call(e,"slide","carousel",m[t]),g=!0,clearInterval(p),p=null,X(t),A&&N(e,"slide")?(B(m[t],i),m[t].offsetWidth,B(m[t],x),B(m[n],x),z(m[t],L,function(o){var a=o[r]!==m[t]?1e3*o.elapsedTime+100:20;g&&setTimeout(function(){g=!1,B(m[t],v),E(m[n],v),E(m[t],i),E(m[t],x),E(m[n],x),q.call(e,"slid","carousel",m[t]),f.interval&&!N(e,"paused")&&f.cycle()},a)})):(B(m[t],v),m[t].offsetWidth,E(m[n],v),setTimeout(function(){g=!1,f.interval&&!N(e,"paused")&&f.cycle(),q.call(e,"slid","carousel",m[t])},100)))}},this.getActiveIndex=function(){return m.indexOf(S(e,"item active")[0])||0},"Carousel"in e||(f.pause&&f.interval&&(W(e,T[0],R),W(e,T[1],P),W(e,"touchstart",R),W(e,"touchend",P)),H&&W(H,"click",j),C&&W(C,"click",j),I&&W(I,"click",O),f.keyboard&&W(t,"keydown",U)),f.getActiveIndex()<0&&(m[u]&&B(m[0],v),D[u]&&X(0)),f.interval&&f.cycle(),e.Carousel=f};a[m](["Carousel",J,'[data-ride="carousel"]']);var K=function(t,e){t=M(t),e=e||{};var i,n,o=null,a=null,l=this,r=t[s]("data-parent"),c=function(t,e){q.call(t,"show","collapse"),t.isAnimating=!0,B(t,"collapsing"),E(t,"collapse"),t[g].height=t.scrollHeight+"px",j(t,function(){t.isAnimating=!1,t[d]("aria-expanded","true"),e[d]("aria-expanded","true"),E(t,"collapsing"),B(t,"collapse"),B(t,"in"),t[g].height="",q.call(t,"shown","collapse")})},f=function(t,e){q.call(t,"hide","collapse"),t.isAnimating=!0,t[g].height=t.scrollHeight+"px",E(t,"collapse"),E(t,"in"),B(t,"collapsing"),t.offsetWidth,t[g].height="0px",j(t,function(){t.isAnimating=!1,t[d]("aria-expanded","false"),e[d]("aria-expanded","false"),E(t,"collapsing"),B(t,"collapse"),t[g].height="",q.call(t,"hidden","collapse")})};this.toggle=function(t){t.preventDefault(),N(a,"in")?l.hide():l.show()},this.hide=function(){a.isAnimating||(f(a,t),B(t,"collapsed"))},this.show=function(){o&&(i=M(".collapse.in",o),n=i&&(M('[data-toggle="collapse"][data-target="#'+i.id+'"]',o)||M('[data-toggle="collapse"][href="#'+i.id+'"]',o))),(!a.isAnimating||i&&!i.isAnimating)&&(n&&i!==a&&(f(i,n),B(n,"collapsed")),c(a,t),E(t,"collapsed"))},"Collapse"in t||W(t,"click",l.toggle),a=function(){var e=t.href&&t[s]("href"),i=t[s]("data-target"),n=e||i&&"#"===i.charAt(0)&&i;return n&&M(n)}(),a.isAnimating=!1,o=M(e.parent)||r&&R(t,r),t.Collapse=l};a[m](["Collapse",K,'[data-toggle="collapse"]']);var Q=function(t,i){t=M(t),this.persist=!0===i||"true"===t[s]("data-persist")||!1;var n=this,o=t[f],a="open",l=null,c=M(".dropdown-menu",o),h=function(){for(var t=c.children,e=[],i=0;i1?s-1:0:40===o&&si.clientHeight,w=z()},F=function(){p[g].paddingLeft=!m&&v?w+"px":"",p[g].paddingRight=m&&!v?w+"px":""},X=function(){p[g].paddingLeft="",p[g].paddingRight=""},Y=function(){k=1;var t=e.createElement("div");null===(y=M(".modal-backdrop"))&&(t[d]("class","modal-backdrop fade"),y=t,e[n].appendChild(y))},G=function(){y=M(".modal-backdrop"),y&&null!==y&&"object"==typeof y&&(k=0,e[n].removeChild(y),y=null),q.call(p,"hidden","modal")},J=function(){N(p,"in")?W(e,"keydown",_):P(e,"keydown",_)},K=function(){N(p,"in")?W(t,"resize",T.update):P(t,"resize",T.update)},Q=function(){N(p,"in")?W(p,"click",tt):P(p,"click",tt)},V=function(){I(p),q.call(p,"shown","modal",x)},Z=function(){p[g].display="",o&&I(o),function(){S(e,"modal in")[0]||(X(),R(),E(e[n],"modal-open"),y&&N(y,"fade")?(E(y,"in"),j(y,G)):G(),K(),Q(),J())}()},$=function(t){var e=t[r];(e=e.hasAttribute("data-target")||e.hasAttribute("href")?e:e[f])!==o||N(p,"in")||(p.modalTrigger=o,x=o,T.show(),t.preventDefault())},_=function(t){var e=t.which||t.keyCode;T.keyboard&&27==e&&N(p,"in")&&T.hide()},tt=function(t){var e=t[r];N(p,"in")&&("modal"===e[f][s]("data-dismiss")||"modal"===e[s]("data-dismiss")||e===p&&"static"!==T.backdrop)&&(T.hide(),x=null,t.preventDefault())};this.toggle=function(){N(p,"in")?this.hide():this.show()},this.show=function(){q.call(p,"show","modal",x);var t=S(e,"modal in")[0];t&&t!==p&&t.modalTrigger.Modal.hide(),this.backdrop&&!k&&Y(),y&&k&&!N(y,"in")&&(y.offsetWidth,l=O(y),B(y,"in")),setTimeout(function(){p[g].display="block",U(),D(),F(),B(e[n],"modal-open"),B(p,"in"),p[d]("aria-hidden",!1),K(),Q(),J(),N(p,"fade")?j(p,V):V()},A&&y?l:0)},this.hide=function(){q.call(p,"hide","modal"),y=M(".modal-backdrop"),l=y&&O(y),E(p,"in"),p[d]("aria-hidden",!0),setTimeout(function(){N(p,"fade")?j(p,Z):Z()},A&&y?l:0)},this.setContent=function(t){M(".modal-content",p).innerHTML=t},this.update=function(){N(p,"in")&&(U(),D(),F())},!o||"Modal"in o||W(o,"click",$),T.content&&T.setContent(T.content),!!o&&(o.Modal=T)}};a[m](["Modal",V,'[data-toggle="modal"]']);var Z=function(i,o){i=M(i),o=o||{};var a=i[s]("data-trigger"),l=i[s]("data-animation"),f=i[s]("data-placement"),u=i[s]("data-dismissible"),h=i[s]("data-delay"),p=i[s]("data-container"),m='',v=M(o.container),b=M(p),x=R(i,".modal"),k=R(i,"."+C),A=R(i,".navbar-fixed-bottom");this.template=o.template?o.template:null,this.trigger=o.trigger?o.trigger:a||"hover",this[c]=o[c]&&"fade"!==o[c]?o[c]:l||"fade",this.placement=o.placement?o.placement:f||w,this.delay=parseInt(o.delay||h)||200,this.dismissible=!(!o.dismissible&&"true"!==u),this.container=v||(b||(k||(A||(x||e[n]))));var L=this,H=i[s]("data-title")||null,I=i[s]("data-content")||null;if(I||this.template){var D=null,S=0,z=this.placement,O=function(t){null!==D&&t[r]===M(".close",D)&&L.hide()},U=function(){L.container.removeChild(D),S=null,D=null},X=function(){if(H=i[s]("data-title"),I=i[s]("data-content"),D=e.createElement("div"),null!==I&&null===L.template){if(D[d]("role","tooltip"),null!==H){var t=e.createElement("h3");t[d]("class","popover-title"),t.innerHTML=L.dismissible?H+m:H,D.appendChild(t)}var n=e.createElement("div"),o=e.createElement("div");n[d]("class","arrow"),o[d]("class","popover-content"),D.appendChild(n),D.appendChild(o),o.innerHTML=L.dismissible&&null===H?I+m:I}else{var a=e.createElement("div");a.innerHTML=L.template,D.innerHTML=a.firstChild.innerHTML}L.container.appendChild(D),D[g].display="block",D[d]("class","popover "+z+" "+L[c])},Y=function(){!N(D,"in")&&B(D,"in")},G=function(){F(i,D,z,L.container)},J=function(n){"click"!=L.trigger&&"focus"!=L.trigger||!L.dismissible&&n(i,"blur",L.hide),L.dismissible&&n(e,"click",O),!y&&n(t,"resize",L.hide)},K=function(){J(W),q.call(i,"shown","popover")},Q=function(){J(P),U(),q.call(i,"hidden","popover")};this.toggle=function(){null===D?L.show():L.hide()},this.show=function(){clearTimeout(S),S=setTimeout(function(){null===D&&(z=L.placement,X(),G(),Y(),q.call(i,"show","popover"),L[c]?j(D,K):K())},20)},this.hide=function(){clearTimeout(S),S=setTimeout(function(){D&&null!==D&&N(D,"in")&&(q.call(i,"hide","popover"),E(D,"in"),L[c]?j(D,Q):Q())},L.delay)},"Popover"in i||("hover"===L.trigger?(W(i,T[0],L.show),L.dismissible||W(i,T[1],L.hide)):"click"!=L.trigger&&"focus"!=L.trigger||W(i,L.trigger,L.toggle)),i.Popover=L}};a[m](["Popover",Z,'[data-toggle="popover"]']);var $=function(e,i){e=M(e);var n=M(e[s]("data-target")),o=e[s]("data-offset");if(i=i||{},i[r]||n){for(var a,l=this,c=i[r]&&M(i[r])||n,d=c&&c.getElementsByTagName("A"),h=parseInt(o||i.offset)||10,p=[],g=[],b=e.offsetHeight=c&&s>a;if(!r&&d)"LI"!==i.tagName||N(i,v)||(B(i,v),o&&!N(o,v)&&B(o,v),q.call(e,"activate","scrollspy",p[t]));else if(d){if(!d&&!r||r&&d)return}else"LI"===i.tagName&&N(i,v)&&(E(i,v),o&&N(o,v)&&!S(i[f],v).length&&E(o,v))},H=function(){a=T?U().y:e.scrollTop;for(var t=0,i=p[u];t1&&(t=e[e[u]-1]):t=e[0],t.getElementsByTagName("A")[0]},H=function(){return M(L()[s]("href"))},I=function(t){var e=t[r][s]("href");t.preventDefault(),n="tab"===t[r][s](l)||e&&"#"===e.charAt(0)?t[r]:t[r][f],!w.isAnimating&&!N(n[f],v)&&m.show()};this.show=function(){n=n||t,c=M(n[s]("href")),o=L(),a=H(),w.isAnimating=!0,E(o[f],v),B(n[f],v),T&&(N(t[f][f],"dropdown-menu")?N(T,v)||B(T,v):N(T,v)&&E(T,v)),q.call(o,"hide","tab",n),N(a,"fade")?(E(a,"in"),j(a,C)):C()},"Tab"in t||W(t,"click",I),m.height&&(y=H()[f]),t.Tab=m}};a[m](["Tab",_,'[data-toggle="tab"]']);var tt=function(i,o){i=M(i),o=o||{};var a=i[s]("data-animation"),l=i[s]("data-placement"),r=i[s]("data-delay"),f=i[s]("data-container"),u=M(o.container),h=M(f),p=R(i,".modal"),g=R(i,"."+C),m=R(i,".navbar-fixed-bottom");this[c]=o[c]&&"fade"!==o[c]?o[c]:a||"fade",this.placement=o.placement?o.placement:l||w,this.delay=parseInt(o.delay||r)||200,this.container=u||(h||(g||(m||(p||e[n]))));var v=this,b=0,x=this.placement,k=null,A=i[s]("title")||i[s]("data-title")||i[s]("data-original-title");if(A&&""!=A){var L=function(){v.container.removeChild(k),k=null,b=null},H=function(){if(!(A=i[s]("title")||i[s]("data-title")||i[s]("data-original-title"))||""==A)return!1;k=e.createElement("div"),k[d]("role","tooltip");var t=e.createElement("div"),n=e.createElement("div");t[d]("class","tooltip-arrow"),n[d]("class","tooltip-inner"),k.appendChild(t),k.appendChild(n),n.innerHTML=A,v.container.appendChild(k),k[d]("class","tooltip "+x+" "+v[c])},I=function(){F(i,k,x,v.container)},D=function(){!N(k,"in")&&B(k,"in")},S=function(){q.call(i,"shown","tooltip"),!y&&W(t,"resize",v.hide)},z=function(){!y&&P(t,"resize",v.hide),L(),q.call(i,"hidden","tooltip")};this.show=function(){clearTimeout(b),b=setTimeout(function(){if(null===k){if(x=v.placement,0==H())return;I(),D(),q.call(i,"show","tooltip"),v[c]?j(k,S):S()}},20)},this.hide=function(){clearTimeout(b),b=setTimeout(function(){k&&N(k,"in")&&(q.call(i,"hide","tooltip"),E(k,"in"),v[c]?j(k,z):z())},v.delay)},this.toggle=function(){k?v.hide():v.show()},"Tooltip"in i||(i[d]("data-original-title",A),i.removeAttribute("title"),W(i,T[0],v.show),W(i,T[1],v.hide)),i.Tooltip=v}};a[m](["Tooltip",tt,'[data-toggle="tooltip"]']);var et=function(t,e){for(var i=0,n=e[u];i=d,x=p[tn]+s.h/2+m.h/2>=h,T=p[tn]-s.h<0,A=p[$t]-s.w<0,C=p[tn]+s.h+m.h>=h,I=p[$t]+s.w+m.w>=d;a=(a===$t||a===_t)&&A&&I?tn:a,a=a===tn&&T?nn:a,a=a===nn&&C?tn:a,a=a===$t&&A?_t:a,a=a===_t&&I?$t:a,a===$t||a===_t?(c=a===$t?p[$t]+v.x-s.w:p[$t]+v.x+m.w,b?(r=p[tn]+v.y,u=m.h/2):x?(r=p[tn]+v.y-s.h+m.h,u=s.h-m.h/2):r=p[tn]+v.y-s.h/2+m.h/2):a!==tn&&a!==nn||(r=a===tn?p[tn]+v.y-s.h:p[tn]+v.y+m.h,w?(c=0,f=p[$t]+m.w/2):y?(c=d-1.01*s.w,f=s.w-(d-p[$t])+m.w/2):c=p[$t]+v.x-s.w/2+m.w/2),o[Ft][tn]=r+"px",o[Ft][$t]=c+"px",u&&(g[Ft][tn]=u+"px"),f&&(g[Ft][$t]=f+"px"),o.className[Ot](a)===-1&&(o.className=o.className.replace(an,a))};o.version="2.0.24";var Ln=function(o,a){o=bn(o),a=a||{};var l=o[Ct](A),r=o[Ct](O),c=o[Ct](W),u="affix",s="affixed",d="function",h="update",p="affix-top",v="affixed-top",m="affix-bottom",g="affixed-bottom";if(this[U]=a[U]?bn(a[U]):bn(l)||null,this[K]=a[K]?a[K]:parseInt(r)||0,this[Q]=a[Q]?a[Q]:parseInt(c)||0,this[U]||this[K]||this[Q]){var b,w,y,x,T,C,I=this,k=!1,N=!1,L=function(){return Math.max(n[i][at],n[i][et],e[tt],e[at],e[et])},S=function(){return null!==I[U]?I[U][Mt]()[tn]+x:I[K]?parseInt(typeof I[K]===d?I[K]():I[K]||0):void 0},E=function(){if(I[Q])return y-o[et]-parseInt(typeof I[Q]===d?I[Q]():I[Q]||0)},B=function(){y=L(),x=parseInt(kn().y,0),b=S(),w=E(),T=parseInt(b)-x<0&&x>parseInt(b),C=parseInt(w)-x<0&&x>parseInt(w)},M=function(){k||vn(o,u)||(In.call(o,u,u),In.call(o,p,u),hn(o,u),k=!0,In.call(o,s,u),In.call(o,v,u))},D=function(){k&&vn(o,u)&&(pn(o,u),k=!1)},P=function(){N||vn(o,m)||(In.call(o,u,u),In.call(o,m,u),hn(o,m),N=!0,In.call(o,s,u),In.call(o,g,u))},H=function(){N&&vn(o,m)&&(pn(o,m),N=!1)},j=function(){C?(T&&D(),P()):(H(),T?M():D())};this[h]=function(){B(),j()},f in o||(yn(t,pt,I[h]),!en&&yn(t,ht,I[h])),o[f]=I,I[h]()}};a[Xt]([f,Ln,"["+c+'="affix"]']);var Sn=function(t){t=bn(t);var n=this,e="alert",i=wn(t,"."+e),o=function(){vn(i,"fade")?Cn(i,l):l()},a=function(o){i=wn(o[U],"."+e),t=bn("["+r+'="'+e+'"]',i),t&&i&&(t===o[U]||t[Gt](o[U]))&&n.close()},l=function(){In.call(i,yt,e),xn(t,ut,a),i[Wt].removeChild(i)};this.close=function(){i&&t&&vn(i,Kt)&&(In.call(i,wt,e),pn(i,Kt),i&&o())},s in t||yn(t,ut,a),t[s]=n};a[Xt]([s,Sn,"["+r+'="alert"]']);var En=function(t,e){t=bn(t),e=e||null;var i=!1,o="button",a="checked",l="reset",r="LABEL",c="INPUT",u=function(){e&&e!==l&&(e===Zt&&(hn(t,Vt),t[It](Vt,Vt),t[It](S,t[St].trim())),t[St]=t[Ct]("data-"+e+"-text"))},f=function(){t[Ct](S)&&((vn(t,Vt)||t[Ct](Vt)===Vt)&&(pn(t,Vt),t.removeAttribute(Vt)),t[St]=t[Ct](S))},s=function(t){var e=t.which||t.keyCode;32===e&&t[U]===n.activeElement&&p(t)},h=function(t){var n=t.which||t.keyCode;32===n&&t[Bt]()},p=function(n){var e=n[U].tagName===r?n[U]:n[U][Wt].tagName===r?n[U][Wt]:null;if(e){var l=n[U],u=gn(l[Wt],"btn"),f=e[Et](c)[0];if(f){if("checkbox"===f.type&&(f[a]?(pn(e,Jt),f[Ct](a),f.removeAttribute(a),f[a]=!1):(hn(e,Jt),f[Ct](a),f[It](a,a),f[a]=!0),i||(i=!0,In.call(f,At,o),In.call(t,At,o))),"radio"===f.type&&!i&&!f[a]){hn(e,Jt),f[It](a,a),f[a]=!0,In.call(f,At,o),In.call(t,At,o),i=!0;for(var s=0,d=u[jt];s=0},H=function(t){for(var n=0,e=L[jt];nt||i===w-1&&0===t)&&(y=p[s]=_t),t<0?t=w-1:t>=w&&(t=0),v=t,e=y===$t?"next":"prev",In.call(n,Tt,u,b[t]),g=!0,clearInterval(m),m=null,H(t),un&&vn(n,"slide")?(hn(b[t],e),b[t][nt],hn(b[t],y),hn(b[i],y),Tn(b[t],fn,function(o){var a=o[U]!==b[t]?1e3*o.elapsedTime+100:20;g&&setTimeout(function(){g=!1,hn(b[t],Jt),pn(b[i],Jt),pn(b[t],e),pn(b[t],y),pn(b[i],y),In.call(n,xt,u,b[t]),p[F]&&!vn(n,f)&&p.cycle()},a)})):(hn(b[t],Jt),b[t][nt],pn(b[i],Jt),setTimeout(function(){g=!1,p[F]&&!vn(n,f)&&p.cycle(),In.call(n,xt,u,b[t])},100)))}},this.getActiveIndex=function(){return b[Ot](gn(n,"item active")[0])||0},h in n||(p[X]&&p[F]&&(yn(n,on[0],S),yn(n,on[1],E),yn(n,"touchstart",S),yn(n,"touchend",E)),I&&yn(I,ut,M),A&&yn(A,ut,M),N&&yn(N,ut,B),p[q]&&yn(t,st,D)),p.getActiveIndex()<0&&(b[jt]&&hn(b[0],Jt),L[jt]&&H(0)),p[F]&&p.cycle(),n[h]=p};a[Xt]([h,Bn,"["+u+'="carousel"]']);var Mn=function(t,n){t=bn(t),n=n||{};var e,i,o=null,a=null,r=this,c=t[Ct]("data-parent"),u="collapse",f="collapsed",s="isAnimating",d=function(t,n){In.call(t,vt,u),t[s]=!0,hn(t,Qt),pn(t,u),t[Ft][lt]=t[at]+"px",Cn(t,function(){t[s]=!1,t[It](rt,"true"),n[It](rt,"true"),pn(t,Qt),hn(t,u),hn(t,Kt),t[Ft][lt]="",In.call(t,mt,u)})},h=function(t,n){In.call(t,gt,u),t[s]=!0,t[Ft][lt]=t[at]+"px",pn(t,u),pn(t,Kt),hn(t,Qt),t[nt],t[Ft][lt]="0px",Cn(t,function(){t[s]=!1,t[It](rt,"false"),n[It](rt,"false"),pn(t,Qt),hn(t,u),t[Ft][lt]="",In.call(t,bt,u)})},v=function(){var n=t.href&&t[Ct]("href"),e=t[Ct](A),i=n||e&&"#"===e.charAt(0)&&e;return i&&bn(i)};this.toggle=function(t){t[Bt](),vn(a,Kt)?r.hide():r.show()},this.hide=function(){a[s]||(h(a,t),hn(t,f))},this.show=function(){o&&(e=bn("."+u+"."+Kt,o),i=e&&(bn("["+l+'="'+u+'"]['+A+'="#'+e.id+'"]',o)||bn("["+l+'="'+u+'"][href="#'+e.id+'"]',o))),(!a[s]||e&&!e[s])&&(i&&e!==a&&(h(e,i),hn(i,f)),d(a,t),pn(t,f))},p in t||yn(t,ut,r.toggle),a=v(),a[s]=!1,o=bn(n.parent)||c&&wn(t,c),t[p]=r};a[Xt]([p,Mn,"["+l+'="collapse"]']);var Dn=function(t,e){t=bn(t),this.persist=e===!0||"true"===t[Ct]("data-persist")||!1;var i=this,o="children",a=t[Wt],l="dropdown",r="open",c=null,u=bn(".dropdown-menu",a),f=function(){for(var t=u[o],n=[],e=0;e1?s-1:0:40===a&&se[tt],w=E()},M=function(){f[Ft][h]=!g&&b?w+"px":"",f[Ft][p]=g&&!b?w+"px":""},D=function(){f[Ft][h]="",f[Ft][p]=""},P=function(){ln=1;var t=n[Nt]("div");y=bn("."+v),null===y&&(t[It]("class",v+" fade"),y=t,n[i][Lt](y))},H=function(){y=bn("."+v),y&&null!==y&&"object"==typeof y&&(ln=0,n[i].removeChild(y),y=null),In.call(f,bt,s)},O=function(){vn(f,Kt)?yn(n,st,G):xn(n,st,G)},W=function(){vn(f,Kt)?yn(t,ht,C.update):xn(t,ht,C.update)},z=function(){vn(f,Kt)?yn(f,ut,J):xn(f,ut,J)},F=function(){dn(f),In.call(f,mt,s,I)},X=function(){f[Ft].display="",o&&dn(o),function(){gn(n,s+" "+Kt)[0]||(D(),S(),pn(n[i],s+"-open"),y&&vn(y,"fade")?(pn(y,Kt),Cn(y,H)):H(),W(),z(),O())}()},Y=function(t){var n=t[U];n=n[kt](A)||n[kt]("href")?n:n[Wt],n!==o||vn(f,Kt)||(f.modalTrigger=o,I=o,C.show(),t[Bt]())},G=function(t){var n=t.which||t.keyCode;C[q]&&27==n&&vn(f,Kt)&&C.hide()},J=function(t){var n=t[U];vn(f,Kt)&&(n[Wt][Ct](r)===s||n[Ct](r)===s||n===f&&C[j]!==d)&&(C.hide(),I=null,t[Bt]())};this.toggle=function(){vn(f,Kt)?this.hide():this.show()},this.show=function(){In.call(f,vt,s,I);var t=gn(n,s+" in")[0];t&&t!==f&&t.modalTrigger[m].hide(),this[j]&&!ln&&P(),y&&ln&&!vn(y,Kt)&&(y[nt],l=An(y),hn(y,Kt)),setTimeout(function(){f[Ft].display="block",B(),L(),M(),hn(n[i],s+"-open"),hn(f,Kt),f[It](ct,!1),W(),z(),O(),vn(f,"fade")?Cn(f,F):F()},un&&y?l:0)},this.hide=function(){In.call(f,gt,s),y=bn("."+v),l=y&&An(y),pn(f,Kt),f[It](ct,!0),setTimeout(function(){vn(f,"fade")?Cn(f,X):X()},un&&y?l:0)},this.setContent=function(t){bn("."+s+"-content",f)[St]=t},this.update=function(){vn(f,Kt)&&(B(),L(),M())},!o||m in o||yn(o,ut,Y),C[R]&&C.setContent(C[R]),!!o&&(o[m]=C)}};a[Xt]([m,Pn,"["+l+'="modal"]']);var Hn=function(e,o){e=bn(e),o=o||{};var a=e[Ct](B),l=e[Ct](M),r=e[Ct](P),c=e[Ct](E),u=e[Ct](H),f=e[Ct](D),s="popover",d="template",h="trigger",p="class",v="div",m="fade",b="data-content",w="dismissible",y='',x=bn(o[J]),T=bn(f),A=wn(e,".modal"),C=wn(e,"."+rn),I=wn(e,"."+cn);this[d]=o[d]?o[d]:null,this[h]=o[h]?o[h]:a||ft,this[Y]=o[Y]&&o[Y]!==m?o[Y]:l||m,this[G]=o[G]?o[G]:r||tn,this[z]=parseInt(o[z]||u)||200,this[w]=!(!o[w]&&"true"!==c),this[J]=x?x:T?T:C?C:I?I:A?A:n[i];var k=this,L=e[Ct](N)||null,S=e[Ct](b)||null;if(S||this[d]){var O=null,W=0,j=this[G],q=function(t){null!==O&&t[U]===bn(".close",O)&&k.hide()},R=function(){k[J].removeChild(O),W=null,O=null},F=function(){if(L=e[Ct](N),S=e[Ct](b),O=n[Nt](v),null!==S&&null===k[d]){if(O[It]("role","tooltip"),null!==L){var t=n[Nt]("h3");t[It](p,s+"-title"),t[St]=k[w]?L+y:L,O[Lt](t)}var i=n[Nt](v),o=n[Nt](v);i[It](p,"arrow"),o[It](p,s+"-content"),O[Lt](i),O[Lt](o),o[St]=k[w]&&null===L?S+y:S}else{var a=n[Nt](v);a[St]=k[d],O[St]=a.firstChild[St]}k[J][Lt](O),O[Ft].display="block",O[It](p,s+" "+j+" "+k[Y])},X=function(){!vn(O,Kt)&&hn(O,Kt)},K=function(){Nn(e,O,j,k[J])},Q=function(i){ut!=k[h]&&"focus"!=k[h]||!k[w]&&i(e,"blur",k.hide),k[w]&&i(n,ut,q),!en&&i(t,ht,k.hide)},V=function(){Q(yn),In.call(e,mt,s)},Z=function(){Q(xn),R(),In.call(e,bt,s)};this.toggle=function(){null===O?k.show():k.hide()},this.show=function(){clearTimeout(W),W=setTimeout(function(){null===O&&(j=k[G],F(),K(),X(),In.call(e,vt,s),k[Y]?Cn(O,V):V())},20)},this.hide=function(){clearTimeout(W),W=setTimeout(function(){O&&null!==O&&vn(O,Kt)&&(In.call(e,gt,s),pn(O,Kt),k[Y]?Cn(O,Z):Z())},k[z])},g in e||(k[h]===ft?(yn(e,on[0],k.show),k[w]||yn(e,on[1],k.hide)):ut!=k[h]&&"focus"!=k[h]||yn(e,k[h],k.toggle)),e[g]=k}};a[Xt]([g,Hn,"["+l+'="popover"]']);var On=function(n,e){n=bn(n);var i=bn(n[Ct](A)),o=n[Ct]("data-offset");if(e=e||{},e[U]||i){for(var a,l=this,r=e[U]&&bn(e[U])||i,c=r&&r[Et]("A"),u=parseInt(o||e.offset)||10,f=[],s=[],d=n[et]=c&&d>a;if(!r&&p)"LI"!==e.tagName||vn(e,Jt)||(hn(e,Jt),o&&!vn(o,Jt)&&hn(o,Jt),In.call(n,"activate","scrollspy",f[t]));else if(p){if(!p&&!r||r&&p)return}else"LI"===e.tagName&&vn(e,Jt)&&(pn(e,Jt),o&&vn(o,Jt)&&!gn(e[Wt],Jt).length&&pn(o,Jt))},y=function(){a=h?kn().y:n[Z];for(var t=0,e=f[jt];t1&&(t=n[n[jt]-1]):t=n[0],t[Et]("A")[0]},C=function(){return bn(A()[Ct]("href"))},k=function(t){var n=t[U][Ct]("href");t[Bt](),c=t[U][Ct](l)===i||n&&"#"===n.charAt(0)?t[U]:t[U][Wt],!m[r]&&!vn(c[Wt],Jt)&&v.show()};this.show=function(){c=c||t,s=bn(c[Ct]("href")),u=A(),f=C(),m[r]=!0,pn(u[Wt],Jt),hn(c[Wt],Jt),b&&(vn(t[Wt][Wt],"dropdown-menu")?vn(b,Jt)||hn(b,Jt):vn(b,Jt)&&pn(b,Jt)),In.call(u,gt,i,c),vn(f,"fade")?(pn(f,Kt),Cn(f,T)):T()},w in t||yn(t,ut,k),v[o]&&(g=C()[Wt]),t[w]=v}};a[Xt]([w,Wn,"["+l+'="tab"]']);var jn=function(e,o){e=bn(e),o=o||{};var a=e[Ct](M),l=e[Ct](P),r=e[Ct](H),c=e[Ct](D),u="tooltip",f="class",s="title",d="fade",h="div",p=bn(o[J]),v=bn(c),m=wn(e,".modal"),g=wn(e,"."+rn),b=wn(e,"."+cn);this[Y]=o[Y]&&o[Y]!==d?o[Y]:a||d,this[G]=o[G]?o[G]:l||tn,this[z]=parseInt(o[z]||r)||200,this[J]=p?p:v?v:g?g:b?b:m?m:n[i];var w=this,x=0,T=this[G],A=null,C=e[Ct](s)||e[Ct](N)||e[Ct](L);if(C&&""!=C){var I=function(){w[J].removeChild(A),A=null,x=null},k=function(){if(C=e[Ct](s)||e[Ct](N)||e[Ct](L),!C||""==C)return!1;A=n[Nt](h),A[It]("role",u);var t=n[Nt](h),i=n[Nt](h);t[It](f,u+"-arrow"),i[It](f,u+"-inner"),A[Lt](t),A[Lt](i),i[St]=C,w[J][Lt](A),A[It](f,u+" "+T+" "+w[Y])},S=function(){Nn(e,A,T,w[J])},E=function(){!vn(A,Kt)&&hn(A,Kt)},B=function(){In.call(e,mt,u),!en&&yn(t,ht,w.hide)},O=function(){!en&&xn(t,ht,w.hide),I(),In.call(e,bt,u)};this.show=function(){clearTimeout(x),x=setTimeout(function(){if(null===A){if(T=w[G],0==k())return;S(),E(),In.call(e,vt,u),w[Y]?Cn(A,B):B()}},20)},this.hide=function(){clearTimeout(x),x=setTimeout(function(){A&&vn(A,Kt)&&(In.call(e,gt,u),pn(A,Kt),w[Y]?Cn(A,O):O())},w[z])},this.toggle=function(){A?w.hide():w.show()},y in e||(e[It](L,C),e.removeAttribute(s),yn(e,on[0],w.show),yn(e,on[1],w.hide)),e[y]=w}};a[Xt]([y,jn,"["+l+'="tooltip"]']);var qn=function(t,n){for(var e=0,i=n[jt];e