UNPKG

ender-mink

Version:

Ender API bridge for mink

50 lines 92.3 kB
/*! * ============================================================= * Ender: open module JavaScript framework (https://enderjs.com) * Build: ender build bean bonzo@v1.4.0 qwery ender-mink@0.1.2 --sandbox ender * Packages: ender-core@2.0.0 ender-commonjs@1.0.7 bean@1.0.6 bonzo@1.4.0 qwery@4.0.0 ender-mink@0.1.2 * ============================================================= */ (function(){/*! * Ender: open module JavaScript framework (client-lib) * http://enderjs.com * License MIT */ function t(t,n){var r;if(this.length=0,"string"==typeof t&&(t=e._select(this.selector=t,n)),null==t)return this;if("function"==typeof t)e._closure(t,n);else if("object"!=typeof t||t.nodeType||(r=t.length)!==+r||t==t.window)this[this.length++]=t;else for(this.length=r=r>0?~~r:0;r--;)this[r]=t[r]}function e(e,n){return new t(e,n)}function n(t){if("$"+t in n._cache)return n._cache["$"+t];if("$"+t in n._modules)return n._cache["$"+t]=n._modules["$"+t]._load();if(t in window)return window[t];throw new Error('Requested module "'+t+'" has not been defined.')}function r(t,e){this.id=t,this.fn=e,n._modules["$"+t]=this}e.fn=e.prototype=t.prototype,e._reserved={reserved:1,ender:1,expose:1,noConflict:1,fn:1},t.prototype.$=e,t.prototype.splice=function(){throw new Error("Not implemented")},t.prototype.forEach=function(t,e){var n,r;for(n=0,r=this.length;r>n;++n)n in this&&t.call(e||this[n],this[n],n,this);return this},e.ender=function(n,r){var i=r?t.prototype:e;for(var o in n)!(o in e._reserved)&&(i[o]=n[o]);return i},e._select=function(t,e){return t?(e||document).querySelectorAll(t):[]},e._closure=function(t){t.call(document,e)},"undefined"!=typeof module&&module.exports&&(module.exports=e);var i=this;n._cache={},n._modules={},r.prototype.require=function(t){var e,r;if("."==t.charAt(0)){for(e=(this.id.replace(/\/.*?$/,"/")+t.replace(/\.js$/,"")).split("/");~(r=e.indexOf("."));)e.splice(r,1);for(;(r=e.lastIndexOf(".."))>0;)e.splice(r-1,2);t=e.join("/")}return n(t)},r.prototype._load=function(){var t=this;return t._loaded||(t._loaded=!0,t.exports={},t.fn.call(i,t,t.exports,function(e){return t.require(e)},i)),t.exports},r.createPackage=function(t,e,i){var o,u;for(o in e)new r(t+"/"+o,e[o]),(u=o.match(/^(.+)\/index$/))&&new r(t+"/"+u[1],e[o]);i&&(n._modules["$"+t]=n._modules["$"+t+"/"+i])},r.createPackage("bean",{bean:function(t){/*! * Bean - copyright (c) Jacob Thornton 2011-2012 * https://github.com/fat/bean * MIT license */ !function(e,n,r){"undefined"!=typeof t&&t.exports?t.exports=r():"function"==typeof define&&define.amd?define(r):n[e]=r()}("bean",this,function(t,e){t=t||"bean",e=e||this;var n,r=window,i=e[t],o=/[^\.]*(?=\..*)\.|.*/,u=/\..*/,s="addEventListener",a="removeEventListener",c=document||{},l=c.documentElement||{},f=l[s],h=f?s:"attachEvent",p={},d=Array.prototype.slice,g=function(t,e){return t.split(e||" ")},y=function(t){return"string"==typeof t},m=function(t){return"function"==typeof t},v="click dblclick mouseup mousedown contextmenu mousewheel mousemultiwheel DOMMouseScroll mouseover mouseout mousemove selectstart selectend keydown keypress keyup orientationchange focus blur change reset select submit load unload beforeunload resize move DOMContentLoaded readystatechange message error abort scroll ",b="show input invalid touchstart touchmove touchend touchcancel gesturestart gesturechange gestureend textinputreadystatechange pageshow pagehide popstate hashchange offline online afterprint beforeprint dragstart dragenter dragover dragleave drag drop dragend loadstart progress suspend emptied stalled loadmetadata loadeddata canplay canplaythrough playing waiting seeking seeked ended durationchange timeupdate play pause ratechange volumechange cuechange checking noupdate downloading cached updateready obsolete ",w=function(t,e,n){for(n=0;n<e.length;n++)e[n]&&(t[e[n]]=1);return t}({},g(v+(f?b:""))),x=function(){var t="compareDocumentPosition"in l?function(t,e){return e.compareDocumentPosition&&16===(16&e.compareDocumentPosition(t))}:"contains"in l?function(t,e){return e=9===e.nodeType||e===window?l:e,e!==t&&e.contains(t)}:function(t,e){for(;t=t.parentNode;)if(t===e)return 1;return 0},e=function(e){var n=e.relatedTarget;return n?n!==this&&"xul"!==n.prefix&&!/document/.test(this.toString())&&!t(n,this):null==n};return{mouseenter:{base:"mouseover",condition:e},mouseleave:{base:"mouseout",condition:e},mousewheel:{base:/Firefox/.test(navigator.userAgent)?"DOMMouseScroll":"mousewheel"}}}(),T=function(){var t=g("altKey attrChange attrName bubbles cancelable ctrlKey currentTarget detail eventPhase getModifierState isTrusted metaKey relatedNode relatedTarget shiftKey srcElement target timeStamp type view which propertyName"),e=t.concat(g("button buttons clientX clientY dataTransfer fromElement offsetX offsetY pageX pageY screenX screenY toElement")),n=e.concat(g("wheelDelta wheelDeltaX wheelDeltaY wheelDeltaZ axis")),i=t.concat(g("char charCode key keyCode keyIdentifier keyLocation location")),o=t.concat(g("data")),u=t.concat(g("touches targetTouches changedTouches scale rotation")),s=t.concat(g("data origin source")),a=t.concat(g("state")),f=/over|out/,h=[{reg:/key/i,fix:function(t,e){return e.keyCode=t.keyCode||t.which,i}},{reg:/click|mouse(?!(.*wheel|scroll))|menu|drag|drop/i,fix:function(t,n,r){return n.rightClick=3===t.which||2===t.button,n.pos={x:0,y:0},t.pageX||t.pageY?(n.clientX=t.pageX,n.clientY=t.pageY):(t.clientX||t.clientY)&&(n.clientX=t.clientX+c.body.scrollLeft+l.scrollLeft,n.clientY=t.clientY+c.body.scrollTop+l.scrollTop),f.test(r)&&(n.relatedTarget=t.relatedTarget||t[("mouseover"==r?"from":"to")+"Element"]),e}},{reg:/mouse.*(wheel|scroll)/i,fix:function(){return n}},{reg:/^text/i,fix:function(){return o}},{reg:/^touch|^gesture/i,fix:function(){return u}},{reg:/^message$/i,fix:function(){return s}},{reg:/^popstate$/i,fix:function(){return a}},{reg:/.*/,fix:function(){return t}}],p={},d=function(t,e,n){if(arguments.length&&(t=t||((e.ownerDocument||e.document||e).parentWindow||r).event,this.originalEvent=t,this.isNative=n,this.isBean=!0,t)){var i,o,u,s,a,c=t.type,l=t.target||t.srcElement;if(this.target=l&&3===l.nodeType?l.parentNode:l,n){if(a=p[c],!a)for(i=0,o=h.length;o>i;i++)if(h[i].reg.test(c)){p[c]=a=h[i].fix;break}for(s=a(t,this,c),i=s.length;i--;)!((u=s[i])in this)&&u in t&&(this[u]=t[u])}}};return d.prototype.preventDefault=function(){this.originalEvent.preventDefault?this.originalEvent.preventDefault():this.originalEvent.returnValue=!1},d.prototype.stopPropagation=function(){this.originalEvent.stopPropagation?this.originalEvent.stopPropagation():this.originalEvent.cancelBubble=!0},d.prototype.stop=function(){this.preventDefault(),this.stopPropagation(),this.stopped=!0},d.prototype.stopImmediatePropagation=function(){this.originalEvent.stopImmediatePropagation&&this.originalEvent.stopImmediatePropagation(),this.isImmediatePropagationStopped=function(){return!0}},d.prototype.isImmediatePropagationStopped=function(){return this.originalEvent.isImmediatePropagationStopped&&this.originalEvent.isImmediatePropagationStopped()},d.prototype.clone=function(t){var e=new d(this,this.element,this.isNative);return e.currentTarget=t,e},d}(),E=function(t,e){return f||e||t!==c&&t!==r?t:l},N=function(){var t=function(t,e,n,r){var i=function(n,i){return e.apply(t,r?d.call(i,n?0:1).concat(r):i)},o=function(n,r){return e.__beanDel?e.__beanDel.ft(n.target,t):r},u=n?function(t){var e=o(t,this);return n.apply(e,arguments)?(t&&(t.currentTarget=e),i(t,arguments)):void 0}:function(t){return e.__beanDel&&(t=t.clone(o(t))),i(t,arguments)};return u.__beanDel=e.__beanDel,u},e=function(e,n,r,i,o,u,s){var a,c=x[n];"unload"==n&&(r=$(D,e,n,r,i)),c&&(c.condition&&(r=t(e,r,c.condition,u)),n=c.base||n),this.isNative=a=w[n]&&!!e[h],this.customType=!f&&!a&&n,this.element=e,this.type=n,this.original=i,this.namespaces=o,this.eventType=f||a?n:"propertychange",this.target=E(e,a),this[h]=!!this.target[h],this.root=s,this.handler=t(e,r,null,u)};return e.prototype.inNamespaces=function(t){var e,n,r=0;if(!t)return!0;if(!this.namespaces)return!1;for(e=t.length;e--;)for(n=this.namespaces.length;n--;)t[e]==this.namespaces[n]&&r++;return t.length===r},e.prototype.matches=function(t,e,n){return!(this.element!==t||e&&this.original!==e||n&&this.handler!==n)},e}(),C=function(){var t={},e=function(n,r,i,o,u,s){var a=u?"r":"$";if(r&&"*"!=r){var c,l=0,f=t[a+r],h="*"==n;if(!f)return;for(c=f.length;c>l;l++)if((h||f[l].matches(n,i,o))&&!s(f[l],f,l,r))return}else for(var p in t)p.charAt(0)==a&&e(n,p.substr(1),i,o,u,s)},n=function(e,n,r,i){var o,u=t[(i?"r":"$")+n];if(u)for(o=u.length;o--;)if(!u[o].root&&u[o].matches(e,r,null))return!0;return!1},r=function(t,n,r,i){var o=[];return e(t,n,r,null,i,function(t){return o.push(t)}),o},i=function(e){var n=!e.root&&!this.has(e.element,e.type,null,!1),r=(e.root?"r":"$")+e.type;return(t[r]||(t[r]=[])).push(e),n},o=function(n){e(n.element,n.type,null,n.handler,n.root,function(e,n,r){return n.splice(r,1),e.removed=!0,0===n.length&&delete t[(e.root?"r":"$")+e.type],!1})},u=function(){var e,n=[];for(e in t)"$"==e.charAt(0)&&(n=n.concat(t[e]));return n};return{has:n,get:r,put:i,del:o,entries:u}}(),_=function(t){n=arguments.length?t:c.querySelectorAll?function(t,e){return e.querySelectorAll(t)}:function(){throw new Error("Bean: No selector engine installed")}},S=function(t,e){if(f||!e||!t||t.propertyName=="_on"+e){var n=C.get(this,e||t.type,null,!1),r=n.length,i=0;for(t=new T(t,this,!0),e&&(t.type=e);r>i&&!t.isImmediatePropagationStopped();i++)n[i].removed||n[i].handler.call(this,t)}},k=f?function(t,e,n){t[n?s:a](e,S,!1)}:function(t,e,n,r){var i;n?(C.put(i=new N(t,r||e,function(e){S.call(t,e,r)},S,null,null,!0)),r&&null==t["_on"+r]&&(t["_on"+r]=0),i.target.attachEvent("on"+i.eventType,i.handler)):(i=C.get(t,r||e,S,!0)[0],i&&(i.target.detachEvent("on"+i.eventType,i.handler),C.del(i)))},$=function(t,e,n,r,i){return function(){r.apply(this,arguments),t(e,n,i)}},D=function(t,e,n,r){var i,o,s=e&&e.replace(u,""),a=C.get(t,s,null,!1),c={};for(i=0,o=a.length;o>i;i++)n&&a[i].original!==n||!a[i].inNamespaces(r)||(C.del(a[i]),!c[a[i].eventType]&&a[i][h]&&(c[a[i].eventType]={t:a[i].eventType,c:a[i].type}));for(i in c)C.has(t,c[i].t,null,!1)||k(t,c[i].t,!1,c[i].c)},P=function(t,e){var r=function(e,r){for(var i,o=y(t)?n(t,r):t;e&&e!==r;e=e.parentNode)for(i=o.length;i--;)if(o[i]===e)return e},i=function(t){var n=r(t.target,this);n&&e.apply(n,arguments)};return i.__beanDel={ft:r,selector:t},i},L=f?function(t,e,n){var i=c.createEvent(t?"HTMLEvents":"UIEvents");i[t?"initEvent":"initUIEvent"](e,!0,!0,r,1),n.dispatchEvent(i)}:function(t,e,n){n=E(n,t),t?n.fireEvent("on"+e,c.createEventObject()):n["_on"+e]++},A=function(t,e,n){var r,i,s,a,c=y(e);if(c&&e.indexOf(" ")>0){for(e=g(e),a=e.length;a--;)A(t,e[a],n);return t}if(i=c&&e.replace(u,""),i&&x[i]&&(i=x[i].base),!e||c)(s=c&&e.replace(o,""))&&(s=g(s,".")),D(t,i,n,s);else if(m(e))D(t,null,e);else for(r in e)e.hasOwnProperty(r)&&A(t,r,e[r]);return t},O=function(t,e,r,i){var s,a,c,l,f,y,v;{if(void 0!==r||"object"!=typeof e){for(m(r)?(f=d.call(arguments,3),i=s=r):(s=i,f=d.call(arguments,4),i=P(r,s,n)),c=g(e),this===p&&(i=$(A,t,e,i,s)),l=c.length;l--;)v=C.put(y=new N(t,c[l].replace(u,""),i,s,g(c[l].replace(o,""),"."),f,!1)),y[h]&&v&&k(t,y.eventType,!0,y.customType);return t}for(a in e)e.hasOwnProperty(a)&&O.call(this,t,a,e[a])}},B=function(t,e,n,r){return O.apply(null,y(n)?[t,n,e,r].concat(arguments.length>3?d.call(arguments,5):[]):d.call(arguments))},z=function(){return O.apply(p,arguments)},M=function(t,e,n){var r,i,s,a,c,l=g(e);for(r=l.length;r--;)if(e=l[r].replace(u,""),(a=l[r].replace(o,""))&&(a=g(a,".")),a||n||!t[h])for(c=C.get(t,e,null,!1),n=[!1].concat(n),i=0,s=c.length;s>i;i++)c[i].inNamespaces(a)&&c[i].handler.apply(t,n);else L(w[e],e,t);return t},q=function(t,e,n){for(var r,i,o=C.get(e,n,null,!1),u=o.length,s=0;u>s;s++)o[s].original&&(r=[t,o[s].type],(i=o[s].handler.__beanDel)&&r.push(i.selector),r.push(o[s].original),O.apply(null,r));return t},H={on:O,add:B,one:z,off:A,remove:A,clone:q,fire:M,Event:T,setSelectorEngine:_,noConflict:function(){return e[t]=i,this}};if(r.attachEvent){var I=function(){var t,e=C.entries();for(t in e)e[t].type&&"unload"!==e[t].type&&A(e[t].element,e[t].type);r.detachEvent("onunload",I),r.CollectGarbage&&r.CollectGarbage()};r.attachEvent("onunload",I)}return _(),H})},"src/ender":function(t,n,r){!function(t){for(var e=r("bean"),n=function(t,n){var r=n?[n]:[];return function(){for(var i=0,o=this.length;o>i;i++)!arguments.length&&"on"==t&&n&&(t="fire"),e[t].apply(this,[this[i]].concat(r,Array.prototype.slice.call(arguments,0)));return this}},i=n("add"),o=n("on"),u=n("one"),s=n("off"),a=n("fire"),c=n("clone"),l=function(t,n,r){for(r=this.length;r--;)e.on.call(this,this[r],"mouseenter",t),e.on.call(this,this[r],"mouseleave",n);return this},f={on:o,addListener:o,bind:o,listen:o,delegate:i,one:u,off:s,unbind:s,unlisten:s,removeListener:s,undelegate:s,emit:a,trigger:a,cloneEvents:c,hover:l},h="blur change click dblclick error focus focusin focusout keydown keypress keyup load mousedown mouseenter mouseleave mouseout mouseover mouseup mousemove resize scroll select submit unload".split(" "),p=h.length;p--;)f[h[p]]=n("on",h[p]);e.setSelectorEngine(t),t.ender(f,!0)}(e)}},"bean"),r.createPackage("bonzo",{bonzo:function(t){/*! * Bonzo: DOM Utility (c) Dustin Diaz 2012 * https://github.com/ded/bonzo * License MIT */ !function(e,n,r){"undefined"!=typeof t&&t.exports?t.exports=r():"function"==typeof define&&define.amd?define(r):n[e]=r()}("bonzo",this,function(){function t(t){return t&&t.nodeName&&(1==t.nodeType||11==t.nodeType)}function e(e,n,r){var i,o,u;if("string"==typeof e)return x.create(e);if(t(e)&&(e=[e]),r){for(u=[],i=0,o=e.length;o>i;i++)u[i]=m(n,e[i]);return u}return e}function n(t){return new RegExp("(^|\\s+)"+t+"(\\s+|$)")}function r(t,e,n,r){for(var i,o=0,u=t.length;u>o;o++)i=r?t.length-o-1:o,e.call(n||t[i],t[i],i,t);return t}function i(e,n,r){for(var o=0,u=e.length;u>o;o++)t(e[o])&&(i(e[o].childNodes,n,r),n.call(r||e[o],e[o],o,e));return e}function o(t){return t.replace(/-(.)/g,function(t,e){return e.toUpperCase()})}function u(t){return t?t.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase():t}function s(t){t[j]("data-node-uid")||t[F]("data-node-uid",++I);var e=t[j]("data-node-uid");return H[e]||(H[e]={})}function a(t){var e=t[j]("data-node-uid");e&&delete H[e]}function c(t){var e;try{return null===t||void 0===t?void 0:"true"===t?!0:"false"===t?!1:"null"===t?null:(e=parseFloat(t))==t?e:t}catch(n){}return void 0}function l(t,e,n){for(var r=0,i=t.length;i>r;++r)if(e.call(n||null,t[r],r,t))return!0;return!1}function f(t){return"transform"==t&&(t=V.transform)||/^transform-?[Oo]rigin$/.test(t)&&(t=V.transform+"Origin")||"float"==t&&(t=V.cssFloat),t?o(t):null}function h(t,n,i,o){var u=0,s=n||this,a=[],c=G&&"string"==typeof t&&"<"!=t.charAt(0)?G(t):t;return r(e(c),function(t,e){r(s,function(n){i(t,a[u++]=e>0?m(s,n):n)},null,o)},this,o),s.length=u,r(a,function(t){s[--u]=t},null,!o),s}function p(t,e,n){var r=x(t),i=r.css("position"),o=r.offset(),u="relative",s=i==u,a=[parseInt(r.css("left"),10),parseInt(r.css("top"),10)];"static"==i&&(r.css("position",u),i=u),isNaN(a[0])&&(a[0]=s?0:t.offsetLeft),isNaN(a[1])&&(a[1]=s?0:t.offsetTop),null!=e&&(t.style.left=e-o.left+a[0]+Y),null!=n&&(t.style.top=n-o.top+a[1]+Y)}function d(t,e){return"function"==typeof e?e(t):e}function g(t,e,n){var r=this[0];return r?null==t&&null==e?(v(r)?b():{x:r.scrollLeft,y:r.scrollTop})[n]:(v(r)?C.scrollTo(t,e):(null!=t&&(r.scrollLeft=t),null!=e&&(r.scrollTop=e)),this):this}function y(t){if(this.length=0,t){t="string"==typeof t||t.nodeType||"undefined"==typeof t.length?[t]:t,this.length=t.length;for(var e=0;e<t.length;e++)this[e]=t[e]}}function m(t,e){var n,r,i,o=e.cloneNode(!0);if(t.$&&"function"==typeof t.cloneEvents)for(t.$(o).cloneEvents(e),n=t.$(o).find("*"),r=t.$(e).find("*"),i=0;i<r.length;i++)t.$(n[i]).cloneEvents(r[i]);return o}function v(t){return t===C||/^(?:body|html)$/i.test(t.tagName)}function b(){return{x:C.pageXOffset||S.scrollLeft,y:C.pageYOffset||S.scrollTop}}function w(t){var e=document.createElement("script"),n=t.match(P);return e.src=n[1],e}function x(t){return new y(t)}var T,E,N,C=window,_=C.document,S=_.documentElement,k="parentNode",$=/^(checked|value|selected|disabled)$/i,D=/^(select|fieldset|table|tbody|tfoot|td|tr|colgroup)$/i,P=/\s*<script +src=['"]([^'"]+)['"]>/,L=["<table>","</table>",1],A=["<table><tbody><tr>","</tr></tbody></table>",3],O=["<select>","</select>",1],B=["_","",0,1],z={thead:L,tbody:L,tfoot:L,colgroup:L,caption:L,tr:["<table><tbody>","</tbody></table>",2],th:A,td:A,col:["<table><colgroup>","</colgroup></table>",2],fieldset:["<form>","</form>",1],legend:["<form><fieldset>","</fieldset></form>",2],option:O,optgroup:O,script:B,style:B,link:B,param:B,base:B},M=/^(checked|selected|disabled)$/,q=/msie/i.test(navigator.userAgent),H={},I=0,W=/^-?[\d\.]+$/,X=/^data-(.+)$/,Y="px",F="setAttribute",j="getAttribute",K="getElementsByTagName",V=function(){var t=_.createElement("p");return t.innerHTML='<a href="#x">x</a><table style="float:left;"></table>',{hrefExtended:"#x"!=t[K]("a")[0][j]("href"),autoTbody:0!==t[K]("tbody").length,computedStyle:_.defaultView&&_.defaultView.getComputedStyle,cssFloat:t[K]("table")[0].style.styleFloat?"styleFloat":"cssFloat",transform:function(){var e,n=["transform","webkitTransform","MozTransform","OTransform","msTransform"];for(e=0;e<n.length;e++)if(n[e]in t.style)return n[e]}(),classList:"classList"in t,opasity:function(){return"undefined"!=typeof _.createElement("a").style.opacity}()}}(),U=/(^\s*|\s*$)/g,R=/\s+/,Q=String.prototype.toString,Z={lineHeight:1,zoom:1,zIndex:1,opacity:1,boxFlex:1,WebkitBoxFlex:1,MozBoxFlex:1},G=_.querySelectorAll&&function(t){return _.querySelectorAll(t)},J=String.prototype.trim?function(t){return t.trim()}:function(t){return t.replace(U,"")},te=V.computedStyle?function(t,e){var n=null,r=_.defaultView.getComputedStyle(t,"");return r&&(n=r[e]),t.style[e]||n}:q&&S.currentStyle?function(t,e){var n,r;if("opacity"==e&&!V.opasity){n=100;try{n=t.filters["DXImageTransform.Microsoft.Alpha"].opacity}catch(i){try{n=t.filters("alpha").opacity}catch(o){}}return n/100}return r=t.currentStyle?t.currentStyle[e]:null,t.style[e]||r}:function(t,e){return t.style[e]};return V.classList?(T=function(t,e){return t.classList.contains(e)},E=function(t,e){t.classList.add(e)},N=function(t,e){t.classList.remove(e)}):(T=function(t,e){return n(e).test(t.className)},E=function(t,e){t.className=J(t.className+" "+e)},N=function(t,e){t.className=J(t.className.replace(n(e)," "))}),y.prototype={get:function(t){return this[t]||null},each:function(t,e){return r(this,t,e)},deepEach:function(t,e){return i(this,t,e)},map:function(t,e){var n,r,i=[];for(r=0;r<this.length;r++)n=t.call(this,this[r],r),e?e(n)&&i.push(n):i.push(n);return i},html:function(t,n){var i=n?void 0===S.textContent?"innerText":"textContent":"innerHTML",o=this,u=function(n,i){r(e(t,o,i),function(t){n.appendChild(t)})},s=function(e,r){try{if(n||"string"==typeof t&&!D.test(e.tagName))return e[i]=t}catch(o){}u(e,r)};return"undefined"!=typeof t?this.empty().each(s):this[0]?this[0][i]:""},text:function(t){return this.html(t,!0)},append:function(t){var n=this;return this.each(function(i,o){r(e(t,n,o),function(t){i.appendChild(t)})})},prepend:function(t){var n=this;return this.each(function(i,o){var u=i.firstChild;r(e(t,n,o),function(t){i.insertBefore(t,u)})})},appendTo:function(t,e){return h.call(this,t,e,function(t,e){t.appendChild(e)})},prependTo:function(t,e){return h.call(this,t,e,function(t,e){t.insertBefore(e,t.firstChild)},1)},before:function(t){var n=this;return this.each(function(i,o){r(e(t,n,o),function(t){i[k].insertBefore(t,i)})})},after:function(t){var n=this;return this.each(function(i,o){r(e(t,n,o),function(t){i[k].insertBefore(t,i.nextSibling)},null,1)})},insertBefore:function(t,e){return h.call(this,t,e,function(t,e){t[k].insertBefore(e,t)})},insertAfter:function(t,e){return h.call(this,t,e,function(t,e){var n=t.nextSibling;n?t[k].insertBefore(e,n):t[k].appendChild(e)},1)},replaceWith:function(t){return x(this[0].parentNode.replaceChild(x(e(t))[0],this[0]))},clone:function(t){var e,n,r=[];for(n=0,e=this.length;e>n;n++)r[n]=m(t||this,this[n]);return x(r)},addClass:function(t){return t=Q.call(t).split(R),this.each(function(e){r(t,function(t){t&&!T(e,d(e,t))&&E(e,d(e,t))})})},removeClass:function(t){return t=Q.call(t).split(R),this.each(function(e){r(t,function(t){t&&T(e,d(e,t))&&N(e,d(e,t))})})},hasClass:function(t){return t=Q.call(t).split(R),l(this,function(e){return l(t,function(t){return t&&T(e,t)})})},toggleClass:function(t,e){return t=Q.call(t).split(R),this.each(function(n){r(t,function(t){t&&("undefined"!=typeof e?e?!T(n,t)&&E(n,t):N(n,t):T(n,t)?N(n,t):E(n,t))})})},show:function(t){return t="string"==typeof t?t:"",this.each(function(e){e.style.display=t})},hide:function(){return this.each(function(t){t.style.display="none"})},toggle:function(t,e){return e="string"==typeof e?e:"","function"!=typeof t&&(t=null),this.each(function(n){n.style.display=n.offsetWidth||n.offsetHeight?"none":e,t&&t.call(n)})},first:function(){return x(this.length?this[0]:[])},last:function(){return x(this.length?this[this.length-1]:[])},next:function(){return this.related("nextSibling")},previous:function(){return this.related("previousSibling")},parent:function(){return this.related(k)},related:function(t){return x(this.map(function(e){for(e=e[t];e&&1!==e.nodeType;)e=e[t];return e||0},function(t){return t}))},focus:function(){return this.length&&this[0].focus(),this},blur:function(){return this.length&&this[0].blur(),this},css:function(t,e){function n(t,e,n){for(var r in i)if(i.hasOwnProperty(r)){n=i[r],(e=f(r))&&W.test(n)&&!(e in Z)&&(n+=Y);try{t.style[e]=d(t,n)}catch(o){}}}var r,i=t;return void 0===e&&"string"==typeof t?(e=this[0],e?e===_||e===C?(r=e===_?x.doc():x.viewport(),"width"==t?r.width:"height"==t?r.height:""):(t=f(t))?te(e,t):null:null):("string"==typeof t&&(i={},i[t]=e),!V.opasity&&"opacity"in i&&(i.filter=null!=i.opacity&&""!==i.opacity?"alpha(opacity="+100*i.opacity+")":"",i.zoom=t.zoom||1,delete i.opacity),this.each(n))},offset:function(t,e){if(t&&"object"==typeof t&&("number"==typeof t.top||"number"==typeof t.left))return this.each(function(e){p(e,t.left,t.top)});if("number"==typeof t||"number"==typeof e)return this.each(function(n){p(n,t,e)});if(!this[0])return{top:0,left:0,height:0,width:0};var n=this[0],r=n.ownerDocument.documentElement,i=n.getBoundingClientRect(),o=b(),u=n.offsetWidth,s=n.offsetHeight,a=i.top+o.y-Math.max(0,r&&r.clientTop,_.body.clientTop),c=i.left+o.x-Math.max(0,r&&r.clientLeft,_.body.clientLeft);return{top:a,left:c,height:s,width:u}},dim:function(){if(!this.length)return{height:0,width:0};var t=this[0],e=9==t.nodeType&&t.documentElement,n=e||!t.style||t.offsetWidth||t.offsetHeight?null:function(e){var n={position:t.style.position||"",visibility:t.style.visibility||"",display:t.style.display||""};return e.first().css({position:"absolute",visibility:"hidden",display:"block"}),n}(this),r=e?Math.max(t.body.scrollWidth,t.body.offsetWidth,e.scrollWidth,e.offsetWidth,e.clientWidth):t.offsetWidth,i=e?Math.max(t.body.scrollHeight,t.body.offsetHeight,e.scrollHeight,e.offsetHeight,e.clientHeight):t.offsetHeight;return n&&this.first().css(n),{height:i,width:r}},attr:function(t,e){var n,r=this[0];if("string"!=typeof t&&!(t instanceof String)){for(n in t)t.hasOwnProperty(n)&&this.attr(n,t[n]);return this}return"undefined"==typeof e?r?$.test(t)?M.test(t)&&"string"==typeof r[t]?!0:r[t]:"href"!=t&&"src"!=t||!V.hrefExtended?r[j](t):r[j](t,2):null:this.each(function(n){$.test(t)?n[t]=d(n,e):n[F](t,d(n,e))})},removeAttr:function(t){return this.each(function(e){M.test(t)?e[t]=!1:e.removeAttribute(t)})},val:function(t){return"string"==typeof t||"number"==typeof t?this.attr("value",t):this.length?this[0].value:null},data:function(t,e){var n,i,a=this[0];return"undefined"==typeof e?a?(n=s(a),"undefined"==typeof t?(r(a.attributes,function(t){(i=(""+t.name).match(X))&&(n[o(i[1])]=c(t.value))}),n):("undefined"==typeof n[t]&&(n[t]=c(this.attr("data-"+u(t)))),n[t])):null:this.each(function(n){s(n)[t]=e})},remove:function(){return this.deepEach(a),this.detach()},empty:function(){return this.each(function(t){for(i(t.childNodes,a);t.firstChild;)t.removeChild(t.firstChild)})},detach:function(){return this.each(function(t){t[k]&&t[k].removeChild(t)})},scrollTop:function(t){return g.call(this,null,t,"y")},scrollLeft:function(t){return g.call(this,t,null,"x")}},x.setQueryEngine=function(t){G=t,delete x.setQueryEngine},x.aug=function(t,e){for(var n in t)t.hasOwnProperty(n)&&((e||y.prototype)[n]=t[n])},x.create=function(e){return"string"==typeof e&&""!==e?function(){if(P.test(e))return[w(e)];var t=e.match(/^\s*<([^\s>]+)/),n=_.createElement("div"),i=[],o=t?z[t[1].toLowerCase()]:null,u=o?o[2]+1:1,s=o&&o[3],a=k,c=V.autoTbody&&o&&"<table>"==o[0]&&!/<tbody/i.test(e);for(n.innerHTML=o?o[0]+e+o[1]:e;u--;)n=n.firstChild;s&&n&&1!==n.nodeType&&(n=n.nextSibling);do t&&1!=n.nodeType||c&&(!n.tagName||"TBODY"==n.tagName)||i.push(n);while(n=n.nextSibling);return r(i,function(t){t[a]&&t[a].removeChild(t)}),i}():t(e)?[e.cloneNode(!0)]:[]},x.doc=function(){var t=x.viewport();return{width:Math.max(_.body.scrollWidth,S.scrollWidth,t.width),height:Math.max(_.body.scrollHeight,S.scrollHeight,t.height)}},x.firstChild=function(t){for(var e,n=t.childNodes,r=0,i=n&&n.length||0;i>r;r++)1===n[r].nodeType&&(e=n[i=r]);return e},x.viewport=function(){return{width:q?S.clientWidth:C.innerWidth,height:q?S.clientHeight:C.innerHeight}},x.isAncestor="compareDocumentPosition"in S?function(t,e){return 16==(16&t.compareDocumentPosition(e))}:"contains"in S?function(t,e){return t!==e&&t.contains(e)}:function(t,e){for(;e=e[k];)if(e===t)return!0;return!1},x})},"src/ender":function(t,n,r){!function(t){function e(t,e){for(var n=0;n<t.length;n++)if(t[n]===e)return n;return-1}function n(t){for(var e,n,r,i=[],o=0,u=0;n=t[o];++o){for(r=!1,e=0;e<i.length;++e)if(i[e]===n){r=!0;break}r||(i[u++]=n)}return i}function i(t,e){return"undefined"==typeof e?o(this).dim()[t]:this.css(t,e)}var o=r("bonzo");o.setQueryEngine(t),t.ender(o),t.ender(o(),!0),t.ender({create:function(e){return t(o.create(e))}}),t.id=function(e){return t([document.getElementById(e)])},t.ender({parents:function(r,i){if(!this.length)return this;r||(r="*");var o,u,s,a=t(r),c=[];for(o=0,u=this.length;u>o;o++)for(s=this[o];(s=s.parentNode)&&(!~e(a,s)||(c.push(s),!i)););return t(n(c))},parent:function(){return t(n(o(this).parent()))},closest:function(t){return this.parents(t,!0)},first:function(){return t(this.length?this[0]:this)},last:function(){return t(this.length?this[this.length-1]:[])},next:function(){return t(o(this).next())},previous:function(){return t(o(this).previous())},related:function(e){return t(o(this).related(e))},appendTo:function(t){return o(this.selector).appendTo(t,this)},prependTo:function(t){return o(this.selector).prependTo(t,this)},insertAfter:function(t){return o(this.selector).insertAfter(t,this)},insertBefore:function(t){return o(this.selector).insertBefore(t,this)},clone:function(){return t(o(this).clone(this))},siblings:function(){var e,n,r,i=[];for(e=0,n=this.length;n>e;e++){for(r=this[e];r=r.previousSibling;)1==r.nodeType&&i.push(r);for(r=this[e];r=r.nextSibling;)1==r.nodeType&&i.push(r)}return t(i)},children:function(){var e,r,i,u=[];for(e=0,r=this.length;r>e;e++)if(i=o.firstChild(this[e]))for(u.push(i);i=i.nextSibling;)1==i.nodeType&&u.push(i);return t(n(u))},height:function(t){return i.call(this,"height",t)},width:function(t){return i.call(this,"width",t)}},!0)}(e)}},"bonzo"),r.createPackage("qwery",{qwery:function(t){/*! * @preserve Qwery - A selector engine * https://github.com/ded/qwery * (c) Dustin Diaz 2014 | License MIT */ !function(e,n,r){"undefined"!=typeof t&&t.exports?t.exports=r():"function"==typeof define&&define.amd?define(r):n[e]=r()}("qwery",this,function(){function t(t){return[].slice.call(t,0)}function e(t){var e;return t&&"object"==typeof t&&(e=t.nodeType)&&(1==e||9==e)}function n(t){return"object"==typeof t&&isFinite(t.length)}function r(t){for(var e=[],r=0,i=t.length;i>r;++r)n(t[r])?e=e.concat(t[r]):e[e.length]=t[r];return e}function i(t){var e,n,r=[];t:for(e=0;e<t.length;e++){for(n=0;n<r.length;n++)if(r[n]==t[e])continue t;r[r.length]=t[e]}return r}function o(t){return t?"string"==typeof t?u(t)[0]:!t[f]&&n(t)?t[0]:t:a}function u(i,u){var l,f=o(u);return f&&i?i===c||e(i)?!u||i!==c&&e(f)&&h(i,f)?[i]:[]:i&&n(i)?r(i):a.getElementsByClassName&&"string"==i&&(l=i.match(s))?t(f.getElementsByClassName(l[1])):i&&(i.document||i.nodeType&&9==i.nodeType)?u?[]:[i]:t(f.querySelectorAll(i)):[]}var s=/^\.([\w\-]+)$/,a=document,c=window,l=a.documentElement,f="nodeType",h="compareDocumentPosition"in l?function(t,e){return 16==(16&e.compareDocumentPosition(t))}:function(t,e){return e=e==a||e==window?l:e,e!==t&&e.contains(t)};return u.uniq=i,u},this)},"src/ender":function(t,n,r){!function(t){var e=r("qwery");t._select=function(n,i){return(t._select=function(){var n;if("function"==typeof t.create)return function(n,r){return/^\s*</.test(n)?t.create(n,r):e(n,r)};try{return n=r("bonzo"),function(t,r){return/^\s*</.test(t)?n.create(t,r):e(t,r)}}catch(i){}return e}())(n,i)},t.ender({find:function(n){var r,i,o,u,s,a=[];for(r=0,i=this.length;i>r;r++)for(s=e(n,this[r]),o=0,u=s.length;u>o;o++)a.push(s[o]);return t(e.uniq(a))},and:function(e){for(var n=t(e),r=this.length,i=0,o=this.length+n.length;o>r;r++,i++)this[r]=n[i];return this.length+=n.length,this}},!0)}(e)}},"qwery"),r.createPackage("ender-mink",{ender:function(t){/*! * ============================================================= * Ender: open module JavaScript framework (https://enderjs.com) * Build: ender build bean bonzo@v1.4.0 qwery ender-mink@0.1.2 --sandbox --output ender * Packages: ender-core@2.0.0 ender-commonjs@1.0.7 bean@1.0.6 bonzo@1.4.0 qwery@4.0.0 ender-mink@0.1.2 * ============================================================= */ (function(){/*! * Ender: open module JavaScript framework (client-lib) * http://enderjs.com * License MIT */ function e(t,e){var r;if(this.length=0,"string"==typeof t&&(t=n._select(this.selector=t,e)),null==t)return this;if("function"==typeof t)n._closure(t,e);else if("object"!=typeof t||t.nodeType||(r=t.length)!==+r||t==t.window)this[this.length++]=t;else for(this.length=r=r>0?~~r:0;r--;)this[r]=t[r]}function n(t,n){return new e(t,n)}function r(t){if("$"+t in r._cache)return r._cache["$"+t];if("$"+t in r._modules)return r._cache["$"+t]=r._modules["$"+t]._load();if(t in window)return window[t];throw new Error('Requested module "'+t+'" has not been defined.')}function i(t,e){this.id=t,this.fn=e,r._modules["$"+t]=this}n.fn=n.prototype=e.prototype,n._reserved={reserved:1,ender:1,expose:1,noConflict:1,fn:1},e.prototype.$=n,e.prototype.splice=function(){throw new Error("Not implemented")},e.prototype.forEach=function(t,e){var n,r;for(n=0,r=this.length;r>n;++n)n in this&&t.call(e||this[n],this[n],n,this);return this},n.ender=function(t,r){var i=r?e.prototype:n;for(var o in t)!(o in n._reserved)&&(i[o]=t[o]);return i},n._select=function(t,e){return t?(e||document).querySelectorAll(t):[]},n._closure=function(t){t.call(document,n)},"undefined"!=typeof t&&t.exports&&(t.exports=n);var o=this;r._cache={},r._modules={},i.prototype.require=function(t){var e,n;if("."==t.charAt(0)){for(e=(this.id.replace(/\/.*?$/,"/")+t.replace(/\.js$/,"")).split("/");~(n=e.indexOf("."));)e.splice(n,1);for(;(n=e.lastIndexOf(".."))>0;)e.splice(n-1,2);t=e.join("/")}return r(t)},i.prototype._load=function(){var t=this;return t._loaded||(t._loaded=!0,t.exports={},t.fn.call(o,t,t.exports,function(e){return t.require(e)},o)),t.exports},i.createPackage=function(t,e,n){var o,u;for(o in e)new i(t+"/"+o,e[o]),(u=o.match(/^(.+)\/index$/))&&new i(t+"/"+u[1],e[o]);n&&(r._modules["$"+t]=r._modules["$"+t+"/"+n])},i.createPackage("bean",{bean:function(t){/*! * Bean - copyright (c) Jacob Thornton 2011-2012 * https://github.com/fat/bean * MIT license */ !function(e,n,r){"undefined"!=typeof t&&t.exports?t.exports=r():"function"==typeof define&&define.amd?define(r):n[e]=r()}("bean",this,function(t,e){t=t||"bean",e=e||this;var n,r=window,i=e[t],o=/[^\.]*(?=\..*)\.|.*/,u=/\..*/,s="addEventListener",a="removeEventListener",c=document||{},l=c.documentElement||{},f=l[s],h=f?s:"attachEvent",p={},d=Array.prototype.slice,g=function(t,e){return t.split(e||" ")},y=function(t){return"string"==typeof t},m=function(t){return"function"==typeof t},v="click dblclick mouseup mousedown contextmenu mousewheel mousemultiwheel DOMMouseScroll mouseover mouseout mousemove selectstart selectend keydown keypress keyup orientationchange focus blur change reset select submit load unload beforeunload resize move DOMContentLoaded readystatechange message error abort scroll ",b="show input invalid touchstart touchmove touchend touchcancel gesturestart gesturechange gestureend textinputreadystatechange pageshow pagehide popstate hashchange offline online afterprint beforeprint dragstart dragenter dragover dragleave drag drop dragend loadstart progress suspend emptied stalled loadmetadata loadeddata canplay canplaythrough playing waiting seeking seeked ended durationchange timeupdate play pause ratechange volumechange cuechange checking noupdate downloading cached updateready obsolete ",w=function(t,e,n){for(n=0;n<e.length;n++)e[n]&&(t[e[n]]=1);return t}({},g(v+(f?b:""))),x=function(){var t="compareDocumentPosition"in l?function(t,e){return e.compareDocumentPosition&&16===(16&e.compareDocumentPosition(t))}:"contains"in l?function(t,e){return e=9===e.nodeType||e===window?l:e,e!==t&&e.contains(t)}:function(t,e){for(;t=t.parentNode;)if(t===e)return 1;return 0},e=function(e){var n=e.relatedTarget;return n?n!==this&&"xul"!==n.prefix&&!/document/.test(this.toString())&&!t(n,this):null==n};return{mouseenter:{base:"mouseover",condition:e},mouseleave:{base:"mouseout",condition:e},mousewheel:{base:/Firefox/.test(navigator.userAgent)?"DOMMouseScroll":"mousewheel"}}}(),T=function(){var t=g("altKey attrChange attrName bubbles cancelable ctrlKey currentTarget detail eventPhase getModifierState isTrusted metaKey relatedNode relatedTarget shiftKey srcElement target timeStamp type view which propertyName"),e=t.concat(g("button buttons clientX clientY dataTransfer fromElement offsetX offsetY pageX pageY screenX screenY toElement")),n=e.concat(g("wheelDelta wheelDeltaX wheelDeltaY wheelDeltaZ axis")),i=t.concat(g("char charCode key keyCode keyIdentifier keyLocation location")),o=t.concat(g("data")),u=t.concat(g("touches targetTouches changedTouches scale rotation")),s=t.concat(g("data origin source")),a=t.concat(g("state")),f=/over|out/,h=[{reg:/key/i,fix:function(t,e){return e.keyCode=t.keyCode||t.which,i}},{reg:/click|mouse(?!(.*wheel|scroll))|menu|drag|drop/i,fix:function(t,n,r){return n.rightClick=3===t.which||2===t.button,n.pos={x:0,y:0},t.pageX||t.pageY?(n.clientX=t.pageX,n.clientY=t.pageY):(t.clientX||t.clientY)&&(n.clientX=t.clientX+c.body.scrollLeft+l.scrollLeft,n.clientY=t.clientY+c.body.scrollTop+l.scrollTop),f.test(r)&&(n.relatedTarget=t.relatedTarget||t[("mouseover"==r?"from":"to")+"Element"]),e}},{reg:/mouse.*(wheel|scroll)/i,fix:function(){return n}},{reg:/^text/i,fix:function(){return o}},{reg:/^touch|^gesture/i,fix:function(){return u}},{reg:/^message$/i,fix:function(){return s}},{reg:/^popstate$/i,fix:function(){return a}},{reg:/.*/,fix:function(){return t}}],p={},d=function(t,e,n){if(arguments.length&&(t=t||((e.ownerDocument||e.document||e).parentWindow||r).event,this.originalEvent=t,this.isNative=n,this.isBean=!0,t)){var i,o,u,s,a,c=t.type,l=t.target||t.srcElement;if(this.target=l&&3===l.nodeType?l.parentNode:l,n){if(a=p[c],!a)for(i=0,o=h.length;o>i;i++)if(h[i].reg.test(c)){p[c]=a=h[i].fix;break}for(s=a(t,this,c),i=s.length;i--;)!((u=s[i])in this)&&u in t&&(this[u]=t[u])}}};return d.prototype.preventDefault=function(){this.originalEvent.preventDefault?this.originalEvent.preventDefault():this.originalEvent.returnValue=!1},d.prototype.stopPropagation=function(){this.originalEvent.stopPropagation?this.originalEvent.stopPropagation():this.originalEvent.cancelBubble=!0},d.prototype.stop=function(){this.preventDefault(),this.stopPropagation(),this.stopped=!0},d.prototype.stopImmediatePropagation=function(){this.originalEvent.stopImmediatePropagation&&this.originalEvent.stopImmediatePropagation(),this.isImmediatePropagationStopped=function(){return!0}},d.prototype.isImmediatePropagationStopped=function(){return this.originalEvent.isImmediatePropagationStopped&&this.originalEvent.isImmediatePropagationStopped()},d.prototype.clone=function(t){var e=new d(this,this.element,this.isNative);return e.currentTarget=t,e},d}(),E=function(t,e){return f||e||t!==c&&t!==r?t:l},N=function(){var t=function(t,e,n,r){var i=function(n,i){return e.apply(t,r?d.call(i,n?0:1).concat(r):i)},o=function(n,r){return e.__beanDel?e.__beanDel.ft(n.target,t):r},u=n?function(t){var e=o(t,this);return n.apply(e,arguments)?(t&&(t.currentTarget=e),i(t,arguments)):void 0}:function(t){return e.__beanDel&&(t=t.clone(o(t))),i(t,arguments)};return u.__beanDel=e.__beanDel,u},e=function(e,n,r,i,o,u,s){var a,c=x[n];"unload"==n&&(r=$(D,e,n,r,i)),c&&(c.condition&&(r=t(e,r,c.condition,u)),n=c.base||n),this.isNative=a=w[n]&&!!e[h],this.customType=!f&&!a&&n,this.element=e,this.type=n,this.original=i,this.namespaces=o,this.eventType=f||a?n:"propertychange",this.target=E(e,a),this[h]=!!this.target[h],this.root=s,this.handler=t(e,r,null,u)};return e.prototype.inNamespaces=function(t){var e,n,r=0;if(!t)return!0;if(!this.namespaces)return!1;for(e=t.length;e--;)for(n=this.namespaces.length;n--;)t[e]==this.namespaces[n]&&r++;return t.length===r},e.prototype.matches=function(t,e,n){return!(this.element!==t||e&&this.original!==e||n&&this.handler!==n)},e}(),C=function(){var t={},e=function(n,r,i,o,u,s){var a=u?"r":"$";if(r&&"*"!=r){var c,l=0,f=t[a+r],h="*"==n;if(!f)return;for(c=f.length;c>l;l++)if((h||f[l].matches(n,i,o))&&!s(f[l],f,l,r))return}else for(var p in t)p.charAt(0)==a&&e(n,p.substr(1),i,o,u,s)},n=function(e,n,r,i){var o,u=t[(i?"r":"$")+n];if(u)for(o=u.length;o--;)if(!u[o].root&&u[o].matches(e,r,null))return!0;return!1},r=function(t,n,r,i){var o=[];return e(t,n,r,null,i,function(t){return o.push(t)}),o},i=function(e){var n=!e.root&&!this.has(e.element,e.type,null,!1),r=(e.root?"r":"$")+e.type;return(t[r]||(t[r]=[])).push(e),n},o=function(n){e(n.element,n.type,null,n.handler,n.root,function(e,n,r){return n.splice(r,1),e.removed=!0,0===n.length&&delete t[(e.root?"r":"$")+e.type],!1})},u=function(){var e,n=[];for(e in t)"$"==e.charAt(0)&&(n=n.concat(t[e]));return n};return{has:n,get:r,put:i,del:o,entries:u}}(),_=function(t){n=arguments.length?t:c.querySelectorAll?function(t,e){return e.querySelectorAll(t)}:function(){throw new Error("Bean: No selector engine installed")}},S=function(t,e){if(f||!e||!t||t.propertyName=="_on"+e){var n=C.get(this,e||t.type,null,!1),r=n.length,i=0;for(t=new T(t,this,!0),e&&(t.type=e);r>i&&!t.isImmediatePropagationStopped();i++)n[i].removed||n[i].handler.call(this,t)}},k=f?function(t,e,n){t[n?s:a](e,S,!1)}:function(t,e,n,r){var i;n?(C.put(i=new N(t,r||e,function(e){S.call(t,e,r)},S,null,null,!0)),r&&null==t["_on"+r]&&(t["_on"+r]=0),i.target.attachEvent("on"+i.eventType,i.handler)):(i=C.get(t,r||e,S,!0)[0],i&&(i.target.detachEvent("on"+i.eventType,i.handler),C.del(i)))},$=function(t,e,n,r,i){return function(){r.apply(this,arguments),t(e,n,i)}},D=function(t,e,n,r){var i,o,s=e&&e.replace(u,""),a=C.get(t,s,null,!1),c={};for(i=0,o=a.length;o>i;i++)n&&a[i].original!==n||!a[i].inNamespaces(r)||(C.del(a[i]),!c[a[i].eventType]&&a[i][h]&&(c[a[i].eventType]={t:a[i].eventType,c:a[i].type}));for(i in c)C.has(t,c[i].t,null,!1)||k(t,c[i].t,!1,c[i].c)},P=function(t,e){var r=function(e,r){for(var i,o=y(t)?n(t,r):t;e&&e!==r;e=e.parentNode)for(i=o.length;i--;)if(o[i]===e)return e},i=function(t){var n=r(t.target,this);n&&e.apply(n,arguments)};return i.__beanDel={ft:r,selector:t},i},L=f?function(t,e,n){var i=c.createEvent(t?"HTMLEvents":"UIEvents");i[t?"initEvent":"initUIEvent"](e,!0,!0,r,1),n.dispatchEvent(i)}:function(t,e,n){n=E(n,t),t?n.fireEvent("on"+e,c.createEventObject()):n["_on"+e]++},A=function(t,e,n){var r,i,s,a,c=y(e);if(c&&e.indexOf(" ")>0){for(e=g(e),a=e.length;a--;)A(t,e[a],n);return t}if(i=c&&e.replace(u,""),i&&x[i]&&(i=x[i].base),!e||c)(s=c&&e.replace(o,""))&&(s=g(s,".")),D(t,i,n,s);else if(m(e))D(t,null,e);else for(r in e)e.hasOwnProperty(r)&&A(t,r,e[r]);return t},O=function(t,e,r,i){var s,a,c,l,f,y,v;{if(void 0!==r||"object"!=typeof e){for(m(r)?(f=d.call(arguments,3),i=s=r):(s=i,f=d.call(arguments,4),i=P(r,s,n)),c=g(e),this===p&&(i=$(A,t,e,i,s)),l=c.length;l--;)v=C.put(y=new N(t,c[l].replace(u,""),i,s,g(c[l].replace(o,""),"."),f,!1)),y[h]&&v&&k(t,y.eventType,!0,y.customType);return t}for(a in e)e.hasOwnProperty(a)&&O.call(this,t,a,e[a])}},B=function(t,e,n,r){return O.apply(null,y(n)?[t,n,e,r].concat(arguments.length>3?d.call(arguments,5):[]):d.call(arguments))},z=function(){return O.apply(p,arguments)},M=function(t,e,n){var r,i,s,a,c,l=g(e);for(r=l.length;r--;)if(e=l[r].replace(u,""),(a=l[r].replace(o,""))&&(a=g(a,".")),a||n||!t[h])for(c=C.get(t,e,null,!1),n=[!1].concat(n),i=0,s=c.length;s>i;i++)c[i].inNamespaces(a)&&c[i].handler.apply(t,n);else L(w[e],e,t);return t},q=function(t,e,n){for(var r,i,o=C.get(e,n,null,!1),u=o.length,s=0;u>s;s++)o[s].original&&(r=[t,o[s].type],(i=o[s].handler.__beanDel)&&r.push(i.selector),r.push(o[s].original),O.apply(null,r));return t},H={on:O,add:B,one:z,off:A,remove:A,clone:q,fire:M,Event:T,setSelectorEngine:_,noConflict:function(){return e[t]=i,this}};if(r.attachEvent){var I=function(){var t,e=C.entries();for(t in e)e[t].type&&"unload"!==e[t].type&&A(e[t].element,e[t].type);r.detachEvent("onunload",I),r.CollectGarbage&&r.CollectGarbage()};r.attachEvent("onunload",I)}return _(),H})},"src/ender":function(t,e,r){!function(t){for(var e=r("bean"),n=function(t,n){var r=n?[n]:[];return function(){for(var i=0,o=this.length;o>i;i++)!arguments.length&&"on"==t&&n&&(t="fire"),e[t].apply(this,[this[i]].concat(r,Array.prototype.slice.call(arguments,0)));return this}},i=n("add"),o=n("on"),u=n("one"),s=n("off"),a=n("fire"),c=n("clone"),l=function(t,n,r){for(r=this.length;r--;)e.on.call(this,this[r],"mouseenter",t),e.on.call(this,this[r],"mouseleave",n);return this},f={on:o,addListener:o,bind:o,listen:o,delegate:i,one:u,off:s,unbind:s,unlisten:s,removeListener:s,undelegate:s,emit:a,trigger:a,cloneEvents:c,hover:l},h="blur change click dblclick error focus focusin focusout keydown keypress keyup load mousedown mouseenter mouseleave mouseout mouseover mouseup mousemove resize scroll select submit unload".split(" "),p=h.length;p--;)f[h[p]]=n("on",h[p]);e.setSelectorEngine(t),t.ender(f,!0)}(n)}},"bean"),i.createPackage("bonzo",{bonzo:function(t){/*! * Bonzo: DOM Utility (c) Dustin Diaz 2012 * https://github.com/ded/bonzo * License MIT */ !function(e,n,r){"undefined"!=typeof t&&t.exports?t.exports=r():"function"==typeof define&&define.amd?define(r):n[e]=r()}("bonzo",this,function(){function t(t){return t&&t.nodeName&&(1==t.nodeType||11==t.nodeType)}function e(e,n,r){var i,o,u;if("string"==typeof e)return x.create(e);if(t(e)&&(e=[e]),r){for(u=[],i=0,o=e.length;o>i;i++)u[i]=m(n,e[i]);return u}return e}function n(t){return new RegExp("(^|\\s+)"+t+"(\\s+|$)")}function r(t,e,n,r){for(var i,o=0,u=t.length;u>o;o++)i=r?t.length-o-1:o,e.call(n||t[i],t[i],i,t);return t}function i(e,n,r){for(var o=0,u=e.length;u>o;o++)t(e[o])&&(i(e[o].childNodes,n,r),n.call(r||e[o],e[o],o,e));return e}function o(t){return t.replace(/-(.)/g,function(t,e){return e.toUpperCase()})}function u(t){return t?t.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase():t}function s(t){t[j]("data-node-uid")||t[F]("data-node-uid",++I);var e=t[j]("data-node-uid");return H[e]||(H[e]={})}function a(t){var e=t[j]("data-node-uid");e&&delete H[e]}function c(t){var e;try{return null===t||void 0===t?void 0:"true"===t?!0:"false"===t?!1:"null"===t?null:(e=parseFloat(t))==t?e:t}catch(n){}return void 0}function l(t,e,n){for(var r=0,i=t.length;i>r;++r)if(e.call(n||null,t[r],r,t))return!0;return!1}function f(t){return"transform"==t&&(t=V.transform)||/^transform-?[Oo]rigin$/.test(t)&&(t=V.transform+"Origin")||"float"==t&&(t=V.cssFloat),t?o(t):null}function h(t,n,i,o){var u=0,s=n||this,a=[],c=G&&"string"==typeof t&&"<"!=t.charAt(0)?G(t):t;return r(e(c),function(t,e){r(s,function(n){i(t,a[u++]=e>0?m(s,n):n)},null,o)},this,o),s.length=u,r(a,function(t){s[--u]=t},null,!o),s}function p(t,e,n){var r=x(t),i=r.css("position"),o=r.offset(),u="relative",s=i==u,a=[parseInt(r.css("left"),10),parseInt(r.css("top"),10)];"static"==i&&(r.css("position",u),i=u),isNaN(a[0])&&(a[0]=s?0:t.offsetLeft),isNaN(a[1])&&(a[1]=s?0:t.offsetTop),null!=e&&(t.style.left=e-o.left+a[0]+Y),null!=n&&(t.style.top=n-o.top+a[1]+Y)}function d(t,e){return"function"==typeof e?e(t):e}function g(t,e,n){var r=this[0];return r?null==t&&null==e?(v(r)?b():{x:r.scrollLeft,y:r.scrollTop})[n]:(v(r)?C.scrollTo(t,e):(null!=t&&(r.scrollLeft=t),null!=e&&(r.scrollTop=e)),this):this}function y(t){if(this.length=0,t){t="string"==typeof t||t.nodeType||"undefined"==typeof t.length?[t]:t,this.length=t.length;for(var e=0;e<t.length;e++)this[e]=t[e]}}function m(t,e){var n,r,i,o=e.cloneNode(!0);if(t.$&&"function"==typeof t.cloneEvents)for(t.$(o).cloneEvents(e),n=t.$(o).find("*"),r=t.$(e).find("*"),i=0;i<r.length;i++)t.$(n[i]).cloneEvents(r[i]);return o}function v(t){return t===C||/^(?:body|html)$/i.test(t.tagName)}function b(){return{x:C.pageXOffset||S.scrollLeft,y:C.pageYOffset||S.scrollTop}}function w(t){var e=document.createElement("script"),n=t.match(P);return e.src=n[1],e}function x(t){return new y(t)}var T,E,N,C=window,_=C.document,S=_.documentElement,k="parentNode",$=/^(checked|value|selected|disabled)$/i,D=/^(select|fieldset|table|tbody|tfoot|td|tr|colgroup)$/i,P=/\s*<script +src=['"]([^'"]+)['"]>/,L=["<table>","</table>",1],A=["<table><tbody><tr>","</tr></tbody></table>",3],O=["<select>","</select>",1],B=["_","",0,1],z={thead:L,tbody:L,tfoot:L,colgroup:L,caption:L,tr:["<table><tbody>","</tbody></table>",2],th:A,td:A,col:["<table><colgroup>","</colgroup></table>",2],fieldset:["<form>","</form>",1],legend:["<form><fieldset>","</fieldset></form>",2],option:O,optgroup:O,script:B,style:B,link:B,param:B,base:B},M=/^(checked|selected|disabled)$/,q=/msie/i.test(navigator.userAgent),H={},I=0,W=/^-?[\d\.]+$/,X=/^data-(.+)$/,Y="px",F="setAttribute",j="getAttribute",K="getElementsByTagName",V=function(){var t=_.createElement("p");return t.innerHTML='<a href="#x">x</a><table style="float:left;"></table>',{hrefExtended:"#x"!=t[K]("a")[0][j]("href"),autoTbody:0!==t[K]("tbody").length,computedStyle:_.defaultView&&_.defaultView.getComputedStyle,cssFloat:t[K]("table")[0].style.styleFloat?"styleFloat":"cssFloat",transform:function(){var e,n=["transform","webkitTransform","MozTransform","OTransform","msTransform"];for(e=0;e<n.length;e++)if(n[e]in t.style)return n[e]}(),classList:"classList"in t,opasity:function(){return"undefined"!=typeof _.createElement("a").style.opacity}()}}(),U=/(^\s*|\s*$)/g,R=/\s+/,Q=String.prototype.toString,Z={lineHeight:1,zoom:1,zIndex:1,opacity:1,boxFlex:1,WebkitBoxFlex:1,MozBoxFlex:1},G=_.querySelectorAll&&function(t){return _.querySelectorAll(t)},J=String.prototype.trim?function(t){return t.trim()}:function(t){return t.replace(U,"")},te=V.computedStyle?function(t,e){var n=null,r=_.defaultView.getComputedStyle(t,"");return r&&(n=r[e]),t.style[e]||n}:q&&S.currentStyle?function(t,e){var n,r;if("opacity"==e&&!V.opasity){n=100;try{n=t.filters["DXImageTransform.Microsoft.Alpha"].opacity}catch(i){try{n=t.filters("alpha").opacity}catch(o){}}return n/100}return r=t.currentStyle?t.currentStyle[e]:null,t.style[e]||r}:function(t,e){return t.style[e]};return V.classList?(T=function(t,e){return t.classList.contains(e)},E=function(t,e){t.classList.add(e)},N=function(t,e){t.classList.remove(e)}):(T=function(t,e){return n(e).test(t.className)},E=function(t,e){t.className=J(t.className+" "+e)},N=function(t,e){t.className=J(t.className.replace(n(e)," "))}),y.prototype={get:function(t){return this[t]||null},each:function(t,e){return r(this,t,e)},deepEach:function(t,e){return i(this,t,e)},map:function(t,e){var n,r,i=[];for(r=0;r<this.length;r++)n=t.call(this,this[r],r),e?e(n)&&i.push(n):i.push(n);return i},html:function(t,n){var i=n?void 0===S.textContent?"innerText":"textContent":"innerHTML",o=this,u=function(n,i){r(e(t,o,i),function(t){n.appendChild(t)})},s=function(e,r){try{if(n||"string"==typeof t&&!D.test(e.tagName))return e[i]=t}catch(o){}u(e,r)};return"undefined"!=typeof t?this.empty().each(s):this[0]?this[0][i]:""},text:function(t){return this.html(t,!0)},append:function(t){var n=this;return this.each(function(i,o){r(e(t,n,o),function(t){i.appendChild(t)})})},prepend:function(t){var n=this;return this.each(function(i,o){var u=i.firstChild;r(e(t,n,o),function(t){i.insertBefore(t,u)})})},appendTo:function(t,e){return h.call(this,t,e,function(t,e){t.appendChild(e)})},prependTo:function(t,e){return h.call(this,t,e,function(t,e){t.insertBefore(e,t.firstChild)},1)},before:function(t){var n=this;return this.each(function(i,o){r(e(t,n,o),function(t){i[k].insertBefore(t,i)})})},after:function(t){var n=this;return this.each(function(i,o){r(e(t,n,o),function(t){i[k].insertBefore(t,i.nextSibling)},null,1)})},insertBefore:function(t,e){return h.call(this,t,e,function(t,e){t[k].insertBefore(e,t)})},insertAfter:function(t,e){return h.call(this,t,e,function(t,e){var n=t.nextSibling;n?t[k].insertBefore(e,n):t[k].appendChild(e)},1