From ec1f23c295866bb372429cac588aa996287637cd Mon Sep 17 00:00:00 2001 From: thednp Date: Mon, 3 Dec 2018 16:04:12 +0200 Subject: [PATCH] Changelog: * V4 fixed missing `aria-selected` from Tab #254 * V3 fixed missing `aria-expanded` from Tab #254 * further updates for https://github.com/thednp/bootstrap.native/pull/253 * documentation fixes and updates --- assets/css/theme4.css | 4 +++- dist/bootstrap-native-v4.js | 9 +++++---- dist/bootstrap-native-v4.min.js | 2 +- dist/bootstrap-native.js | 8 ++++---- dist/bootstrap-native.min.js | 2 +- index.html | 8 ++++++-- v4.html | 22 ++++++++++++++++------ 7 files changed, 36 insertions(+), 19 deletions(-) diff --git a/assets/css/theme4.css b/assets/css/theme4.css index 474c3c3b..71e80b2d 100644 --- a/assets/css/theme4.css +++ b/assets/css/theme4.css @@ -51,4 +51,6 @@ h3:not(.popover-header) { .bg-bootstrap { background-color: #563d7c } .bg-pink { background-color: #E91E63 } .bg-indigo { background-color: #9c27b0 } - \ No newline at end of file + +/* SVG icons */ +.nav svg {vertical-align: text-top;} \ No newline at end of file diff --git a/dist/bootstrap-native-v4.js b/dist/bootstrap-native-v4.js index 71ab5526..737f7e0e 100644 --- a/dist/bootstrap-native-v4.js +++ b/dist/bootstrap-native-v4.js @@ -73,7 +73,7 @@ // option keys backdrop = 'backdrop', keyboard = 'keyboard', delay = 'delay', - content = 'content', target = 'target', + content = 'content', target = 'target', currentTarget = 'currentTarget', interval = 'interval', pause = 'pause', animation = 'animation', placement = 'placement', container = 'container', @@ -89,6 +89,7 @@ // aria ariaExpanded = 'aria-expanded', ariaHidden = 'aria-hidden', + ariaSelected = 'aria-selected', // event names clickEvent = 'click', @@ -1588,10 +1589,8 @@ }, // handler clickHandler = function(e) { - var href = e[target][getAttribute]('href'); e[preventDefault](); - next = e[target][getAttribute](dataToggle) === component || (href && href.charAt(0) === '#') - ? e[target] : e[target][parentNode]; // allow for child elements like icons to use the handler + next = e[currentTarget]; !tabs[isAnimating] && !hasClass(next,active) && self.show(); }; @@ -1604,7 +1603,9 @@ tabs[isAnimating] = true; removeClass(activeTab,active); + activeTab[setAttribute](ariaSelected,'false'); addClass(next,active); + next[setAttribute](ariaSelected,'true'); if ( dropdown ) { if ( !hasClass(element[parentNode],'dropdown-menu') ) { diff --git a/dist/bootstrap-native-v4.min.js b/dist/bootstrap-native-v4.min.js index ef3a1be3..bd1021d9 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.25 | © dnp_theme | MIT-License -!function(t,n){if("function"==typeof define&&define.amd)define([],n);else if("object"==typeof module&&module.exports)module.exports=n();else{var e=n();t.Alert=e.Alert,t.Button=e.Button,t.Carousel=e.Carousel,t.Collapse=e.Collapse,t.Dropdown=e.Dropdown,t.Modal=e.Modal,t.Popover=e.Popover,t.ScrollSpy=e.ScrollSpy,t.Tab=e.Tab,t.Tooltip=e.Tooltip}}(this,function(){"use strict";var t="undefined"!=typeof global?global:this||window,n=document,e=n.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",nt="height",et="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 n?["mouseenter","mouseleave"]:["mouseover","mouseout"],Vt=/\b(top|bottom|left|right)+/,Zt=0,$t="fixed-top",_t="fixed-bottom",tn=Wt+Ht in e[jt]||Ht[Pt]()in e[jt],nn=Wt+Ht in e[jt]?Wt[Pt]()+Ht+"End":Ht[Pt]()+"end",en=Wt+Ot in e[jt]?Wt[Pt]()+Ht+Ot:Ht[Pt]()+Ot,on=function(t){t.focus?t.focus():t.setActive()},an=function(t,n){t.classList.add(n)},ln=function(t,n){t.classList.remove(n)},rn=function(t,n){return t.classList[Ut](n)},cn=function(t,n){return[].slice.call(t[Et](n))},un=function(t,e){var i=e?e:n;return"object"==typeof t?t:i.querySelector(t)},sn=function(t,e){var i=e.charAt(0),o=e.substr(1);if("."===i){for(;t&&t!==n;t=t[Dt])if(null!==un(e,t[Dt])&&rn(t,o))return t}else if("#"===i)for(;t&&t!==n;t=t[Dt])if(t.id===o)return t;return!1},fn=function(t,n,e){t.addEventListener(n,e,!1)},hn=function(t,n,e){t.removeEventListener(n,e,!1)},dn=function(t,n,e){fn(t,n,function i(o){e(o),hn(t,n,i)})},vn=function(n){var e=tn?t[St](n)[en]:0;return e=parseFloat(e),e="number"!=typeof e||isNaN(e)?0:1e3*e,e+50},pn=function(t,n){var e=0,i=vn(t);tn&&dn(t,nn,function(t){n(t),e=1}),setTimeout(function(){!e&&n()},i)},mn=function(t,n,e){var i=new CustomEvent(t+".bs."+n);i.relatedTarget=e,this.dispatchEvent(i)},gn=function(){return{y:t.pageYOffset||e[G],x:t.pageXOffset||e[J]}},wn=function(t,o,a,l){var r,c,u,s,f,h,d={w:o[V],h:o[Z]},v=e[K]||n[i][K],p=e[Q]||n[i][Q],m=t[Nt](),g=l===n[i]?gn():{x:l[Y]+l[J],y:l[X]+l[G]},w={w:m[Gt]-m[Yt],h:m[Kt]-m[Jt]},b=rn(o,"popover"),y=un(".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.25";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(){U(),z(),R(),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),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=v,A=m[Qt]+d.h/2+w.h/2>=p,k=m[Qt]-d.h<0,I=m[Jt]-d.w<0,N=m[Qt]+d.h+w.h>=p,L=m[Jt]+d.w+w.w>=v;a=(a===Jt||a===Kt)&&I&&L?Qt:a,a=a===Qt&&k?Vt:a,a=a===Vt&&N?Qt:a,a=a===Jt&&I?Kt:a,a=a===Kt&&L?Jt:a,o.className[Mt](a)===-1&&(o.className=o.className.replace($t,a)),f=y[Z],h=y[$],a===Jt||a===Kt?(c=a===Jt?m[Jt]+g.x-d.w-(b?f:0):m[Jt]+g.x+w.w,T?(r=m[Qt]+g.y,u=w.h/2-f):A?(r=m[Qt]+g.y-d.h+w.h,u=d.h-w.h/2-f):(r=m[Qt]+g.y-d.h/2+w.h/2,u=d.h/2-(b?.9*h:h/2))):a!==Qt&&a!==Vt||(r=a===Qt?m[Qt]+g.y-d.h-(b?h:0):m[Qt]+g.y+w.h,x?(c=0,s=m[Jt]+w.w/2-f):C?(c=v-1.01*d.w,s=d.w-(v-m[Jt])+w.w/2-f/2):(c=m[Jt]+g.x-d.w/2+w.w/2,s=d.w/2-f/2)),o[Rt][Qt]=r+"px",o[Rt][Jt]=c+"px",u&&(y[Rt][Qt]=u+"px"),s&&(y[Rt][Jt]=s+"px")};o.version="2.0.25";var ye=function(t){t=se(t);var e=this,n="alert",i=fe(t,"."+n),o=function(){ce(i,"fade")?me(i,l):l()},a=function(o){i=fe(o[j],"."+n),t=se("["+r+'="'+n+'"]',i),t&&i&&(t===o[j]||t[Ft](o[j]))&&e.close()},l=function(){ge.call(i,gt,n),de(t,lt,a),i[Pt].removeChild(i)};this.close=function(){i&&t&&ce(i,Yt)&&(ge.call(i,mt,n),re(i,Yt),i&&o())},s in t||he(t,lt,a),t[s]=e};a[Ut]([s,ye,"["+r+'="alert"]']);var Te=function(t){t=se(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[Lt]()},u=function(e){var r=e[j].tagName===a?e[j]:e[j][Pt].tagName===a?e[j][Pt]:null;if(r){var c=e[j],u=ue(c[Pt],"btn"),s=r[Nt](l)[0];if(s){if("checkbox"===s.type&&(s[o]?(re(r,Xt),s[Tt](o),s.removeAttribute(o),s[o]=!1):(le(r,Xt),s[Tt](o),s[xt](o,o),s[o]=!0),n||(n=!0,ge.call(s,yt,i),ge.call(t,yt,i))),"radio"===s.type&&!n&&!s[o]){le(r,Xt),s[xt](o,o),s[o]=!0,ge.call(s,yt,i),ge.call(t,yt,i),n=!0;for(var f=0,h=u[Ht];f=0},W=function(t){for(var e=0,n=E[Ht];et||o===x-1&&0===t)&&(A=m[d]=Kt),t<0?t=x-1:t>=x&&(t=0),g=t,n=A===Jt?"next":"prev",ge.call(i,bt,s,y[t]),b=!0,clearInterval(w),w=null,W(t),ne&&ce(i,"slide")?(le(y[t],v+"-"+n),y[t][Z],le(y[t],v+"-"+A),le(y[o],v+"-"+A),ve(y[t],ie,function(a){var l=a[j]!==y[t]?1e3*a.elapsedTime+100:20;b&&setTimeout(function(){b=!1,le(y[t],Xt),re(y[o],Xt),re(y[t],v+"-"+n),re(y[t],v+"-"+A),re(y[o],v+"-"+A),ge.call(i,wt,s,y[t]),e.hidden||!m[R]||ce(i,f)||m.cycle()},l)})):(le(y[t],Xt),y[t][Z],re(y[o],Xt),setTimeout(function(){b=!1,m[R]&&!ce(i,f)&&m.cycle(),ge.call(i,wt,s,y[t])},100)))}},this.getActiveIndex=function(){return y[Mt](ue(i,v+" active")[0])||0},h in i||(m[U]&&m[R]&&(he(i,Zt[0],S),he(i,Zt[1],B),he(i,"touchstart",S),he(i,"touchend",B)),N&&he(N,lt,M),I&&he(I,lt,M),L&&he(L,lt,D),m[H]===!0&&he(t,ct,P)),m.getActiveIndex()<0&&(y[Ht]&&le(y[0],Xt),E[Ht]&&W(0)),m[R]&&m.cycle(),i[h]=m}};a[Ut]([h,xe,"["+u+'="carousel"]']);var Ce=function(t,e){t=se(t),e=e||{};var n,i,o=null,a=null,r=this,c=t[Tt]("data-parent"),u="collapse",s="collapsed",f="isAnimating",h=function(t,e){ge.call(t,ht,u),t[f]=!0,le(t,Gt),re(t,u),t[Rt][nt]=t[et]+"px",me(t,function(){t[f]=!1,t[xt](it,"true"),e[xt](it,"true"),re(t,Gt),le(t,u),le(t,Yt),t[Rt][nt]="",ge.call(t,dt,u)})},v=function(t,e){ge.call(t,vt,u),t[f]=!0,t[Rt][nt]=t[et]+"px",re(t,u),re(t,Yt),le(t,Gt),t[Z],t[Rt][nt]="0px",me(t,function(){t[f]=!1,t[xt](it,"false"),e[xt](it,"false"),re(t,Gt),le(t,u),t[Rt][nt]="",ge.call(t,pt,u)})},p=function(){var e=t.href&&t[Tt]("href"),n=t[Tt](x),i=e||n&&"#"===n.charAt(0)&&n;return i&&se(i)};this.toggle=function(t){t[Lt](),ce(a,Yt)?r.hide():r.show()},this.hide=function(){a[f]||(v(a,t),le(t,s))},this.show=function(){o&&(n=se("."+u+"."+Yt,o),i=n&&(se("["+l+'="'+u+'"]['+x+'="#'+n.id+'"]',o)||se("["+l+'="'+u+'"][href="#'+n.id+'"]',o))),(!a[f]||n&&!n[f])&&(i&&n!==a&&(v(n,i),le(i,s)),h(a,t),re(t,s))},d in t||he(t,lt,r.toggle),a=p(),a[f]=!1,o=se(e.parent)||c&&fe(t,c),t[d]=r};a[Ut]([d,Ce,"["+l+'="collapse"]']);var Ae=function(t,n){t=se(t),this.persist=n===!0||"true"===t[Tt]("data-persist")||!1;var i=this,o="children",a=t[Pt],l="dropdown",r="open",c=null,u=se(".dropdown-menu",a),s=function(){for(var t=u[o],e=[],n=0;n1?l-1:0:40===o&&ln[V],b=S()},D=function(){s[Rt][d]=!g&&w?b+"px":"",s[Rt][v]=g&&!w?b+"px":""},M=function(){s[Rt][d]="",s[Rt][v]=""},O=function(){_t=1;var t=e[At]("div");C=se("."+m),null===C&&(t[xt]("class",m+" fade"),C=t,e[i][kt](C))},q=function(){C=se("."+m),C&&null!==C&&"object"==typeof C&&(_t=0,e[i].removeChild(C),C=null),ge.call(s,pt,f)},R=function(){ce(s,Yt)?he(e,ct,G):de(e,ct,G)},U=function(){ce(s,Yt)?he(t,st,A.update):de(t,st,A.update)},z=function(){ce(s,Yt)?he(s,lt,J):de(s,lt,J)},F=function(){U(),z(),R(),ae(s),ge.call(s,dt,f,k)},X=function(){s[Rt].display="",o&&ae(o),function(){ue(e,f+" "+Yt)[0]||(M(),E(),re(e[i],f+"-open"),C&&ce(C,"fade")?(re(C,Yt),me(C,q)):q(),U(),z(),R())}()},Y=function(t){var e=t[j];e=e[Ct](x)||e[Ct]("href")?e:e[Pt],e!==o||ce(s,Yt)||(s.modalTrigger=o,k=o,A.show(),t[Lt]())},G=function(t){A[H]&&27==t.which&&ce(s,Yt)&&A.hide()},J=function(t){var e=t[j];ce(s,Yt)&&(e[Pt][Tt](r)===f||e[Tt](r)===f||e===s&&A[P]!==h)&&(A.hide(),k=null,t[Lt]())};this.toggle=function(){ce(s,Yt)?this.hide():this.show()},this.show=function(){ge.call(s,ht,f,k);var t=ue(e,f+" "+Yt)[0];t&&t!==s&&t.modalTrigger[p].hide(),this[P]&&!_t&&O(),C&&_t&&!ce(C,Yt)&&(C[Z],l=pe(C),le(C,Yt)),setTimeout(function(){s[Rt].display="block",B(),L(),D(),le(e[i],f+"-open"),le(s,Yt),s[xt](ot,!1),ce(s,"fade")?me(s,F):F()},ne&&C?l:0)},this.hide=function(){ge.call(s,vt,f),C=se("."+m),l=C&&pe(C),re(s,Yt),s[xt](ot,!0),setTimeout(function(){ce(s,"fade")?me(s,X):X()},ne&&C?l:0)},this.setContent=function(t){se("."+f+"-content",s)[It]=t},this.update=function(){ce(s,Yt)&&(B(),L(),D())},!o||p in o||he(o,lt,Y),A[W]&&A.setContent(A[W]),!!o&&(o[p]=A)}};a[Ut]([p,ke,"["+l+'="modal"]']);var Ie=function(n,o){n=se(n),o=o||{};var a=n[Tt](E),l=n[Tt](S),r=n[Tt](D),c=n[Tt](L),u=n[Tt](M),s=n[Tt](B),f="popover",h="template",d="trigger",v="class",p="div",g="fade",w="data-content",b="dismissible",y='',T=se(o[X]),x=se(s),C=fe(n,".modal"),A=fe(n,"."+te),k=fe(n,"."+ee);this[h]=o[h]?o[h]:null,this[d]=o[d]?o[d]:a||rt,this[z]=o[z]&&o[z]!==g?o[z]:l||g,this[F]=o[F]?o[F]:r||Qt,this[O]=parseInt(o[O]||u)||200,this[b]=!(!o[b]&&"true"!==c),this[X]=T?T:x?x:A?A:k?k:C?C:e[i];var N=this,P=n[Tt](I)||null,H=n[Tt](w)||null;if(H||this[h]){var W=null,q=0,R=this[F],U=function(t){null!==W&&t[j]===se(".close",W)&&N.hide()},Y=function(){N[X].removeChild(W),q=null,W=null},G=function(){P=n[Tt](I),H=n[Tt](w),W=e[At](p);var t=e[At](p);if(t[xt](v,"arrow"),W[kt](t),null!==H&&null===N[h]){if(W[xt]("role","tooltip"),null!==P){var i=e[At]("h3");i[xt](v,f+"-header"),i[It]=N[b]?P+y:P,W[kt](i)}var o=e[At](p);o[xt](v,f+"-body"),o[It]=N[b]&&null===P?H+y:H,W[kt](o)}else{var a=e[At](p);a[It]=N[h],W[It]=a.firstChild[It]}N[X][kt](W),W[Rt].display="block",W[xt](v,f+" bs-"+f+"-"+R+" "+N[z])},J=function(){!ce(W,Yt)&&le(W,Yt)},K=function(){be(n,W,R,N[X])},Q=function(i){lt!=N[d]&&"focus"!=N[d]||!N[b]&&i(n,"blur",N.hide),N[b]&&i(e,lt,U),i(t,st,N.hide)},V=function(){Q(he),ge.call(n,dt,f)},Z=function(){Q(de),Y(),ge.call(n,pt,f)};this.toggle=function(){null===W?N.show():N.hide()},this.show=function(){clearTimeout(q),q=setTimeout(function(){null===W&&(R=N[F],G(),K(),J(),ge.call(n,ht,f),N[z]?me(W,V):V())},20)},this.hide=function(){clearTimeout(q),q=setTimeout(function(){W&&null!==W&&ce(W,Yt)&&(ge.call(n,vt,f),re(W,Yt),N[z]?me(W,Z):Z())},N[O])},m in n||(N[d]===rt?(he(n,Zt[0],N.show),N[b]||he(n,Zt[1],N.hide)):lt!=N[d]&&"focus"!=N[d]||he(n,N[d],N.toggle)),n[m]=N}};a[Ut]([m,Ie,"["+l+'="popover"]']);var Ne=function(e,n){e=se(e);var i=se(e[Tt](x)),o=e[Tt]("data-offset");if(n=n||{},n[j]||i){for(var a,l=this,r=n[j]&&se(n[j])||i,c=r&&r[Nt]("A"),u=parseInt(o||n.offset)||10,s=[],f=[],h=e[$]=h&&v>a;if(!c&&p)ce(n,Xt)||(le(n,Xt),l&&!ce(l,Xt)&&le(l,Xt),ge.call(e,"activate","scrollspy",s[t]));else if(p){if(!p&&!c||c&&p)return}else ce(n,Xt)&&(re(n,Xt),l&&ce(l,Xt)&&!ue(n[Pt],Xt).length&&re(l,Xt))},y=function(){a=d?we().y:e[J];for(var t=0,n=s[Ht];t1&&(t=e[e[Ht]-1]):t=e[0],t},C=function(){return se(x()[Tt]("href"))},k=function(t){t[Lt](),r=t[q],!p[l]&&!ce(r,Xt)&&v.show()};this.show=function(){r=r||t,s=se(r[Tt]("href")),c=x(),u=C(),p[l]=!0,re(c,Xt),c[xt](at,"false"),le(r,Xt),r[xt](at,"true"),g&&(ce(t[Pt],"dropdown-menu")?ce(g,Xt)||le(g,Xt):ce(g,Xt)&&re(g,Xt)),ge.call(c,vt,i,r),ce(u,"fade")?(re(u,Yt),me(u,T)):T()},w in t||he(t,lt,k),v[o]&&(m=C()[Pt]),t[w]=v}};a[Ut]([w,Le,"["+l+'="tab"]']);var Ee=function(n,o){n=se(n),o=o||{};var a=n[Tt](S),l=n[Tt](D),r=n[Tt](M),c=n[Tt](B),u="tooltip",s="class",f="title",h="fade",d="div",v=se(o[X]),p=se(c),m=fe(n,".modal"),g=fe(n,"."+te),w=fe(n,"."+ee);this[z]=o[z]&&o[z]!==h?o[z]:a||h,this[F]=o[F]?o[F]:l||Qt,this[O]=parseInt(o[O]||r)||200,this[X]=v?v:p?p:g?g:w?w:m?m:e[i];var y=this,T=0,x=this[F],C=null,A=n[Tt](f)||n[Tt](I)||n[Tt](N);if(A&&""!=A){var k=function(){y[X].removeChild(C),C=null,T=null},L=function(){if(A=n[Tt](f)||n[Tt](I)||n[Tt](N),!A||""==A)return!1;C=e[At](d),C[xt]("role",u);var t=e[At](d);t[xt](s,"arrow"),C[kt](t);var i=e[At](d);i[xt](s,u+"-inner"),C[kt](i),i[It]=A,y[X][kt](C),C[xt](s,u+" bs-"+u+"-"+x+" "+y[z])},E=function(){be(n,C,x,y[X])},P=function(){!ce(C,Yt)&&le(C,Yt)},H=function(){he(t,st,y.hide),ge.call(n,dt,u)},W=function(){de(t,st,y.hide),k(),ge.call(n,pt,u)};this.show=function(){clearTimeout(T),T=setTimeout(function(){if(null===C){if(x=y[F],0==L())return;E(),P(),ge.call(n,ht,u),y[z]?me(C,H):H()}},20)},this.hide=function(){clearTimeout(T),T=setTimeout(function(){C&&ce(C,Yt)&&(ge.call(n,vt,u),re(C,Yt),y[z]?me(C,W):W())},y[O])},this.toggle=function(){C?y.hide():y.show()},b in n||(n[xt](N,A),n.removeAttribute(f),he(n,Zt[0],y.show),he(n,Zt[1],y.hide)),n[b]=y}};a[Ut]([b,Ee,"["+l+'="tooltip"]']);var Se=function(t,e){for(var n=0,i=e[Ht];n=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.25";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(){W(),z(),O(),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),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=d,x=p[nn]+s.h/2+m.h/2>=h,T=p[nn]-s.h<0,A=p[_t]-s.w<0,C=p[nn]+s.h+m.h>=h,I=p[_t]+s.w+m.w>=d;a=(a===_t||a===tn)&&A&&I?nn:a,a=a===nn&&T?en:a,a=a===en&&C?nn:a,a=a===_t&&A?tn:a,a=a===tn&&I?_t:a,a===_t||a===tn?(c=a===_t?p[_t]+v.x-s.w:p[_t]+v.x+m.w,b?(r=p[nn]+v.y,u=m.h/2):x?(r=p[nn]+v.y-s.h+m.h,u=s.h-m.h/2):r=p[nn]+v.y-s.h/2+m.h/2):a!==nn&&a!==en||(r=a===nn?p[nn]+v.y-s.h:p[nn]+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[Xt][nn]=r+"px",o[Xt][_t]=c+"px",u&&(g[Xt][nn]=u+"px"),f&&(g[Xt][_t]=f+"px"),o.className[Wt](a)===-1&&(o.className=o.className.replace(ln,a))};o.version="2.0.25";var Sn=function(o,a){o=wn(o),a=a||{};var l=o[It](A),r=o[It](O),c=o[It](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]?wn(a[U]):wn(l)||null,this[Q]=a[Q]?a[Q]:parseInt(r)||0,this[V]=a[V]?a[V]:parseInt(c)||0,this[U]||this[Q]||this[V]){var b,w,y,x,T,C,I=this,k=!1,N=!1,L=function(){return Math.max(n[i][lt],n[i][it],e[nt],e[lt],e[it])},S=function(){return null!==I[U]?I[U][Dt]()[nn]+x:I[Q]?parseInt(typeof I[Q]===d?I[Q]():I[Q]||0):void 0},E=function(){if(I[V])return y-o[it]-parseInt(typeof I[V]===d?I[V]():I[V]||0)},B=function(){y=L(),x=parseInt(Nn().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||mn(o,u)||(kn.call(o,u,u),kn.call(o,p,u),pn(o,u),k=!0,kn.call(o,s,u),kn.call(o,v,u))},D=function(){k&&mn(o,u)&&(vn(o,u),k=!1)},P=function(){N||mn(o,m)||(kn.call(o,u,u),kn.call(o,m,u),pn(o,m),N=!0,kn.call(o,s,u),kn.call(o,g,u))},H=function(){N&&mn(o,m)&&(vn(o,m),N=!1)},j=function(){C?(T&&D(),P()):(H(),T?M():D())};this[h]=function(){B(),j()},f in o||(xn(t,vt,I[h]),!on&&xn(t,pt,I[h])),o[f]=I,I[h]()}};a[Yt]([f,Sn,"["+c+'="affix"]']);var En=function(t){t=wn(t);var n=this,e="alert",i=yn(t,"."+e),o=function(){mn(i,"fade")?In(i,l):l()},a=function(o){i=yn(o[U],"."+e),t=wn("["+r+'="'+e+'"]',i),t&&i&&(t===o[U]||t[Jt](o[U]))&&n.close()},l=function(){kn.call(i,xt,e),Tn(t,ft,a),i[jt].removeChild(i)};this.close=function(){i&&t&&mn(i,Qt)&&(kn.call(i,yt,e),vn(i,Qt),i&&o())},s in t||xn(t,ft,a),t[s]=n};a[Yt]([s,En,"["+r+'="alert"]']);var Bn=function(t,e){t=wn(t),e=e||null;var i=!1,o="button",a="checked",l="reset",r="LABEL",c="INPUT",u=function(){e&&e!==l&&(e===$t&&(pn(t,Zt),t[kt](Zt,Zt),t[kt](S,t[Et].trim())),t[Et]=t[It]("data-"+e+"-text"))},f=function(){t[It](S)&&((mn(t,Zt)||t[It](Zt)===Zt)&&(vn(t,Zt),t.removeAttribute(Zt)),t[Et]=t[It](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[Mt]()},p=function(n){var e=n[U].tagName===r?n[U]:n[U][jt].tagName===r?n[U][jt]:null;if(e){var l=n[U],u=bn(l[jt],"btn"),f=e[Bt](c)[0];if(f){if("checkbox"===f.type&&(f[a]?(vn(e,Kt),f[It](a),f.removeAttribute(a),f[a]=!1):(pn(e,Kt),f[It](a),f[kt](a,a),f[a]=!0),i||(i=!0,kn.call(f,Ct,o),kn.call(t,Ct,o))),"radio"===f.type&&!i&&!f[a]){pn(e,Kt),f[kt](a,a),f[a]=!0,kn.call(f,Ct,o),kn.call(t,Ct,o),i=!0;for(var s=0,d=u[qt];s=0},H=function(t){for(var n=0,e=L[qt];nt||i===w-1&&0===t)&&(y=p[s]=tn),t<0?t=w-1:t>=w&&(t=0),v=t,e=y===_t?"next":"prev",kn.call(n,At,u,b[t]),g=!0,clearInterval(m),m=null,H(t),fn&&mn(n,"slide")?(pn(b[t],e),b[t][et],pn(b[t],y),pn(b[i],y),An(b[t],sn,function(o){var a=o[U]!==b[t]?1e3*o.elapsedTime+100:20;g&&setTimeout(function(){g=!1,pn(b[t],Kt),vn(b[i],Kt),vn(b[t],e),vn(b[t],y),vn(b[i],y),kn.call(n,Tt,u,b[t]),p[X]&&!mn(n,f)&&p.cycle()},a)})):(pn(b[t],Kt),b[t][et],vn(b[i],Kt),setTimeout(function(){g=!1,p[X]&&!mn(n,f)&&p.cycle(),kn.call(n,Tt,u,b[t])},100)))}},this.getActiveIndex=function(){return b[Wt](bn(n,"item active")[0])||0},h in n||(p[Y]&&p[X]&&(xn(n,an[0],S),xn(n,an[1],E),xn(n,"touchstart",S),xn(n,"touchend",E)),I&&xn(I,ft,M),A&&xn(A,ft,M),N&&xn(N,ft,B),p[q]&&xn(t,dt,D)),p.getActiveIndex()<0&&(b[qt]&&pn(b[0],Kt),L[qt]&&H(0)),p[X]&&p.cycle(),n[h]=p}};a[Yt]([h,Mn,"["+u+'="carousel"]']);var Dn=function(t,n){t=wn(t),n=n||{};var e,i,o=null,a=null,r=this,c=t[It]("data-parent"),u="collapse",f="collapsed",s="isAnimating",d=function(t,n){kn.call(t,mt,u),t[s]=!0,pn(t,Vt),vn(t,u),t[Xt][rt]=t[lt]+"px",In(t,function(){t[s]=!1,t[kt](ct,"true"),n[kt](ct,"true"),vn(t,Vt),pn(t,u),pn(t,Qt),t[Xt][rt]="",kn.call(t,gt,u)})},h=function(t,n){kn.call(t,bt,u),t[s]=!0,t[Xt][rt]=t[lt]+"px",vn(t,u),vn(t,Qt),pn(t,Vt),t[et],t[Xt][rt]="0px",In(t,function(){t[s]=!1,t[kt](ct,"false"),n[kt](ct,"false"),vn(t,Vt),pn(t,u),t[Xt][rt]="",kn.call(t,wt,u)})},v=function(){var n=t.href&&t[It]("href"),e=t[It](A),i=n||e&&"#"===e.charAt(0)&&e;return i&&wn(i)};this.toggle=function(t){t[Mt](),mn(a,Qt)?r.hide():r.show()},this.hide=function(){a[s]||(h(a,t),pn(t,f))},this.show=function(){o&&(e=wn("."+u+"."+Qt,o),i=e&&(wn("["+l+'="'+u+'"]['+A+'="#'+e.id+'"]',o)||wn("["+l+'="'+u+'"][href="#'+e.id+'"]',o))),(!a[s]||e&&!e[s])&&(i&&e!==a&&(h(e,i),pn(i,f)),d(a,t),vn(t,f))},p in t||xn(t,ft,r.toggle),a=v(),a[s]=!1,o=wn(n.parent)||c&&yn(t,c),t[p]=r};a[Yt]([p,Dn,"["+l+'="collapse"]']);var Pn=function(t,e){t=wn(t),this.persist=e===!0||"true"===t[It]("data-persist")||!1;var i=this,o="children",a=t[jt],l="dropdown",r="open",c=null,u=wn(".dropdown-menu",a),f=function(){for(var t=u[o],n=[],e=0;e1?s-1:0:40===a&&se[nt],w=E()},M=function(){f[Xt][h]=!g&&b?w+"px":"",f[Xt][p]=g&&!b?w+"px":""},D=function(){f[Xt][h]="",f[Xt][p]=""},P=function(){rn=1;var t=n[Lt]("div");y=wn("."+v),null===y&&(t[kt]("class",v+" fade"),y=t,n[i][St](y))},H=function(){y=wn("."+v),y&&null!==y&&"object"==typeof y&&(rn=0,n[i].removeChild(y),y=null),kn.call(f,wt,s)},O=function(){mn(f,Qt)?xn(n,dt,G):Tn(n,dt,G)},W=function(){mn(f,Qt)?xn(t,pt,C.update):Tn(t,pt,C.update)},z=function(){mn(f,Qt)?xn(f,ft,J):Tn(f,ft,J)},F=function(){W(),z(),O(),hn(f),kn.call(f,gt,s,I)},X=function(){f[Xt].display="",o&&hn(o),function(){bn(n,s+" "+Qt)[0]||(D(),S(),vn(n[i],s+"-open"),y&&mn(y,"fade")?(vn(y,Qt),In(y,H)):H(),W(),z(),O())}()},Y=function(t){var n=t[U];n=n[Nt](A)||n[Nt]("href")?n:n[jt],n!==o||mn(f,Qt)||(f.modalTrigger=o,I=o,C.show(),t[Mt]())},G=function(t){var n=t.which||t.keyCode;C[q]&&27==n&&mn(f,Qt)&&C.hide()},J=function(t){var n=t[U];mn(f,Qt)&&(n[jt][It](r)===s||n[It](r)===s||n===f&&C[j]!==d)&&(C.hide(),I=null,t[Mt]())};this.toggle=function(){mn(f,Qt)?this.hide():this.show()},this.show=function(){kn.call(f,mt,s,I);var t=bn(n,s+" in")[0];t&&t!==f&&t.modalTrigger[m].hide(),this[j]&&!rn&&P(),y&&rn&&!mn(y,Qt)&&(y[et],l=Cn(y),pn(y,Qt)),setTimeout(function(){f[Xt].display="block",B(),L(),M(),pn(n[i],s+"-open"),pn(f,Qt),f[kt](ut,!1),mn(f,"fade")?In(f,F):F()},fn&&y?l:0)},this.hide=function(){kn.call(f,bt,s),y=wn("."+v),l=y&&Cn(y),vn(f,Qt),f[kt](ut,!0),setTimeout(function(){mn(f,"fade")?In(f,X):X()},fn&&y?l:0)},this.setContent=function(t){wn("."+s+"-content",f)[Et]=t},this.update=function(){mn(f,Qt)&&(B(),L(),M())},!o||m in o||xn(o,ft,Y),C[R]&&C.setContent(C[R]),!!o&&(o[m]=C)}};a[Yt]([m,Hn,"["+l+'="modal"]']);var On=function(e,o){e=wn(e),o=o||{};var a=e[It](B),l=e[It](M),r=e[It](P),c=e[It](E),u=e[It](H),f=e[It](D),s="popover",d="template",h="trigger",p="class",v="div",m="fade",b="data-content",w="dismissible",y='',x=wn(o[K]),T=wn(f),A=yn(e,".modal"),C=yn(e,"."+cn),I=yn(e,"."+un);this[d]=o[d]?o[d]:null,this[h]=o[h]?o[h]:a||st,this[G]=o[G]&&o[G]!==m?o[G]:l||m,this[J]=o[J]?o[J]:r||nn,this[z]=parseInt(o[z]||u)||200,this[w]=!(!o[w]&&"true"!==c),this[K]=x?x:T?T:C?C:I?I:A?A:n[i];var k=this,L=e[It](N)||null,S=e[It](b)||null;if(S||this[d]){var O=null,W=0,j=this[J],q=function(t){null!==O&&t[U]===wn(".close",O)&&k.hide()},R=function(){k[K].removeChild(O),W=null,O=null},F=function(){if(L=e[It](N),S=e[It](b),O=n[Lt](v),null!==S&&null===k[d]){if(O[kt]("role","tooltip"),null!==L){var t=n[Lt]("h3");t[kt](p,s+"-title"),t[Et]=k[w]?L+y:L,O[St](t)}var i=n[Lt](v),o=n[Lt](v);i[kt](p,"arrow"),o[kt](p,s+"-content"),O[St](i),O[St](o),o[Et]=k[w]&&null===L?S+y:S}else{var a=n[Lt](v);a[Et]=k[d],O[Et]=a.firstChild[Et]}k[K][St](O),O[Xt].display="block",O[kt](p,s+" "+j+" "+k[G])},X=function(){!mn(O,Qt)&&pn(O,Qt)},Y=function(){Ln(e,O,j,k[K])},Q=function(i){ft!=k[h]&&"focus"!=k[h]||!k[w]&&i(e,"blur",k.hide),k[w]&&i(n,ft,q),!on&&i(t,pt,k.hide)},V=function(){Q(xn),kn.call(e,gt,s)},Z=function(){Q(Tn),R(),kn.call(e,wt,s)};this.toggle=function(){null===O?k.show():k.hide()},this.show=function(){clearTimeout(W),W=setTimeout(function(){null===O&&(j=k[J],F(),Y(),X(),kn.call(e,mt,s),k[G]?In(O,V):V())},20)},this.hide=function(){clearTimeout(W),W=setTimeout(function(){O&&null!==O&&mn(O,Qt)&&(kn.call(e,bt,s),vn(O,Qt),k[G]?In(O,Z):Z())},k[z])},g in e||(k[h]===st?(xn(e,an[0],k.show),k[w]||xn(e,an[1],k.hide)):ft!=k[h]&&"focus"!=k[h]||xn(e,k[h],k.toggle)),e[g]=k}};a[Yt]([g,On,"["+l+'="popover"]']);var Wn=function(n,e){n=wn(n);var i=wn(n[It](A)),o=n[It]("data-offset");if(e=e||{},e[U]||i){for(var a,l=this,r=e[U]&&wn(e[U])||i,c=r&&r[Bt]("A"),u=parseInt(o||e.offset)||10,f=[],s=[],d=n[it]=c&&d>a;if(!r&&p)"LI"!==e.tagName||mn(e,Kt)||(pn(e,Kt),o&&!mn(o,Kt)&&pn(o,Kt),kn.call(n,"activate","scrollspy",f[t]));else if(p){if(!p&&!r||r&&p)return}else"LI"===e.tagName&&mn(e,Kt)&&(vn(e,Kt),o&&mn(o,Kt)&&!bn(e[jt],Kt).length&&vn(o,Kt))},y=function(){a=h?Nn().y:n[$];for(var t=0,e=f[qt];t1&&(t=n[n[qt]-1]):t=n[0],t[Bt]("A")[0]},A=function(){return wn(T()[It]("href"))},C=function(t){t[Mt](),r=t[F]||this,!v[l]&&!mn(r[jt],Kt)&&p.show()};this.show=function(){r=r||t,f=wn(r[It]("href")),c=T(),u=A(),v[l]=!0,vn(c[jt],Kt),c[kt](ct,"false"),pn(r[jt],Kt),r[kt](ct,"true"),g&&(mn(t[jt][jt],"dropdown-menu")?mn(g,Kt)||pn(g,Kt):mn(g,Kt)&&vn(g,Kt)),kn.call(c,bt,i,r),mn(u,"fade")?(vn(u,Qt),In(u,x)):x()},w in t||xn(t,ft,C),p[o]&&(m=A()[jt]),t[w]=p}};a[Yt]([w,jn,"["+l+'="tab"]']);var qn=function(e,o){e=wn(e),o=o||{};var a=e[It](M),l=e[It](P),r=e[It](H),c=e[It](D),u="tooltip",f="class",s="title",d="fade",h="div",p=wn(o[K]),v=wn(c),m=yn(e,".modal"),g=yn(e,"."+cn),b=yn(e,"."+un);this[G]=o[G]&&o[G]!==d?o[G]:a||d,this[J]=o[J]?o[J]:l||nn,this[z]=parseInt(o[z]||r)||200,this[K]=p?p:v?v:g?g:b?b:m?m:n[i];var w=this,x=0,T=this[J],A=null,C=e[It](s)||e[It](N)||e[It](L);if(C&&""!=C){var I=function(){w[K].removeChild(A),A=null,x=null},k=function(){if(C=e[It](s)||e[It](N)||e[It](L),!C||""==C)return!1;A=n[Lt](h),A[kt]("role",u);var t=n[Lt](h),i=n[Lt](h);t[kt](f,u+"-arrow"),i[kt](f,u+"-inner"),A[St](t),A[St](i),i[Et]=C,w[K][St](A),A[kt](f,u+" "+T+" "+w[G])},S=function(){Ln(e,A,T,w[K])},E=function(){!mn(A,Qt)&&pn(A,Qt)},B=function(){kn.call(e,gt,u),!on&&xn(t,pt,w.hide)},O=function(){!on&&Tn(t,pt,w.hide),I(),kn.call(e,wt,u)};this.show=function(){clearTimeout(x),x=setTimeout(function(){if(null===A){if(T=w[J],0==k())return;S(),E(),kn.call(e,mt,u),w[G]?In(A,B):B()}},20)},this.hide=function(){clearTimeout(x),x=setTimeout(function(){A&&mn(A,Qt)&&(kn.call(e,bt,u),vn(A,Qt),w[G]?In(A,O):O())},w[z])},this.toggle=function(){A?w.hide():w.show()},y in e||(e[kt](L,C),e.removeAttribute(s),xn(e,an[0],w.show),xn(e,an[1],w.hide)),e[y]=w}};a[Yt]([y,qn,"["+l+'="tooltip"]']);var zn=function(t,n){for(var e=0,i=n[qt];eExample

OK now we're ready to put this component to the test. We'll use all Bootstrap .nav components in the pool.